This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import multiprocessing | |
import os | |
import time | |
import Queue | |
def scoring_function_dummy(jobs, results): | |
while True: | |
try: | |
task = jobs.get(True, 1) | |
print '%s: working: %s' % (os.getpid(), task) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd ~ | |
sudo apt-get update | |
sudo apt-get install wget | |
wget --no-check-certificate https://raw.github.com/pypa/pip/master/contrib/get-pip.py | |
python get-pip.py | |
sudo apt-get install git | |
mkdir src | |
cd src | |
git clone http://github.com/datamade/dedupe | |
cd dedupe/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Line # Hits Time Per Hit % Time Line Contents | |
============================================================== | |
66 @profile | |
67 def apply(self, querytext, start=0, count=None): | |
68 8734 34597 4.0 0.3 parser = QueryParser(self.lexicon) | |
69 8734 1622182 185.7 14.1 tree = parser.parseQuery(querytext) | |
70 8645 2041557 236.2 17.7 results = tree.executeQuery(self.index) | |
71 8645 12093 1.4 0.1 if results: | |
72 8645 675324 78.1 5.9 qw = self.index.query_weight(tree.terms()) | |
73 |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
import re | |
import tempfile | |
from subprocess import Popen | |
from collections import OrderedDict | |
import xlrd | |
import xlwt | |
import xlutils | |
import openpyxl |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Html exposing (..) | |
import Html.App as Html | |
import Html.Attributes exposing (..) | |
import Html.Events exposing ( onClick ) | |
import Array exposing ( Array ) | |
-- Copied from elm-community/list-extra to remove the 3rd party | |
-- dependency so that the code can be pasted to: http://elm-lang.org/try |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-| This code will reproduce issue https://github.com/elm-lang/core/issues/749 | |
when the text from either div is cleared. | |
-} | |
import Html exposing (text) | |
import Html.App as App | |
import Html.Attributes exposing (contenteditable) | |
import Html.Events exposing (on) | |
import Json.Decode as Json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
LICENSE: MIT | |
This is an experiment. Use at your own risk. | |
""" | |
import sys | |
import time | |
import zlib | |
import pickle |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Threaded Load-balancing Broker | |
""" | |
from __future__ import print_function | |
from threading import Thread | |
import zmq |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
LICENSE | |
This Source Code Form is subject to the terms of the Mozilla Public | |
License, v. 2.0. If a copy of the MPL was not distributed with this | |
file, You can obtain one at http://mozilla.org/MPL/2.0/. | |
DESCRIPTION | |
This is a prototype, parsley implementation of a subset of a MySQL-like SQL syntax. |
OlderNewer