repo_name
stringlengths
5
92
path
stringlengths
4
232
copies
stringclasses
19 values
size
stringlengths
4
7
content
stringlengths
721
1.04M
license
stringclasses
15 values
hash
int64
-9,223,277,421,539,062,000
9,223,102,107B
line_mean
float64
6.51
99.9
line_max
int64
15
997
alpha_frac
float64
0.25
0.97
autogenerated
bool
1 class
xuru/pyvisdk
pyvisdk/do/task_reason_alarm.py
1
1024
import logging from pyvisdk.exceptions import InvalidArgumentError ######################################## # Automatically generated, do not edit. ######################################## log = logging.getLogger(__name__) def TaskReasonAlarm(vim, *args, **kwargs): '''Indicates that the task was queued by an al...
mit
4,373,901,051,778,541,000
30.060606
124
0.589844
false
vsfs/vsfs-bench
vsbench/slurm.py
1
10482
#!/usr/bin/env python #SBATCH --time=12:00:00 #SBATCH --mem-per-cpu=1024 #SBATCH --partition=guest #SBATCH --error=job.%J.err #SBATCH --output=job.%J.out #SBATCH --cpus-per-task=1 # # Author: Lei Xu <eddyxu@gmail.com> # # TODO(eddyxu): generalize this to all drivers from __future__ import print_function from subproces...
apache-2.0
4,452,980,237,569,532,400
35.778947
78
0.60103
false
dgisser/mapio
calendar_sample.py
1
1577
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Copyright 2014 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICEN...
mit
-1,054,553,263,972,978,800
32.553191
81
0.710843
false
kyleabeauchamp/EnsemblePaper
code/model_building/benchmark_ALA.py
1
8769
import experiment_loader import ALA3 import numpy as np from fitensemble import lvbp from fitensemble.utils import validate_pandas_columns num_threads = 2 num_samples = 20000 # Generate 20,000 MCMC samples thin = 25 # Subsample (i.e. thin) the MCMC traces by 25X to ensure independent samples burn = 5000 # Discard t...
gpl-3.0
-1,653,505,764,016,225,800
52.797546
117
0.635306
false
nadenislamarre/recalbox-configgen
configgen/generators/dosbox/dosboxGenerator.py
1
1197
#!/usr/bin/env python import Command import recalboxFiles from generators.Generator import Generator import os.path import glob class DosBoxGenerator(Generator): def getResolution(self, config): return 'default' # Main entry of the module # Return command def generate(self, system, rom, ...
mit
604,286,931,525,195,000
33.2
103
0.629073
false
jeroanan/GameCollection
Tests/Interactors/TestSearchInteractor.py
1
1059
from Interactors.Interactor import Interactor from Interactors.Search.Params.SearchInteractorParams import SearchInteractorParams from Interactors.Search.SearchInteractor import SearchInteractor from Tests.Interactors.InteractorTestBase import InteractorTestBase class TestSearchInteractor(InteractorTestBase): de...
gpl-3.0
-8,598,317,548,667,415,000
38.222222
126
0.708215
false
abeconnelly/untap
scripts/collect_samples_from_profile_data.py
1
2707
#!/usr/bin/python import subprocess as sp import sys import json import re import csv import os debug=False header=False URL="https://my.pgp-hms.org" if len(sys.argv)<2: print "provide HTML file to parse" sys.exit(1) fn = sys.argv[1] if debug: print "# processing:", fn if len(sys.argv)<3: print "provid...
agpl-3.0
6,023,896,672,139,526,000
23.169643
133
0.531954
false
edeposit/marcxml2mods
setup.py
1
1723
#! /usr/bin/env python # -*- coding: utf-8 -*- # # Interpreter version: python 2.7 # # Imports ===================================================================== from setuptools import setup, find_packages from docs import getVersion # Variables =================================================================== ...
mit
-1,199,779,438,846,476,800
23.971014
79
0.506674
false
buffer/thug
thug/Classifier/URLClassifier.py
1
2222
#!/usr/bin/env python # # URLClassifier.py # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License version 2 as # published by the Free Software Foundation. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRA...
gpl-2.0
-949,605,761,486,316,300
31.676471
78
0.653015
false
ntim/g4sipm
sample/run/luigi/dynamic_range_simulation_bretz.py
1
2691
#!/usr/bin/env python # -*- coding: utf-8 -*- import luigi import sqlite3 import glob import numpy as np import json from simulation_meta_task import * class DynamicRangeSimulation(SimulationDynamicMetaTask, luigi.Task): name = luigi.Parameter("dynamic-range-simulation-bretz") n_repititions = luigi.IntParamete...
gpl-3.0
-3,709,466,599,450,708,000
46.210526
151
0.599034
false
jcabdala/fades
tests/test_main.py
1
9135
# Copyright 2015-2019 Facundo Batista, Nicolás Demarchi # # This program is free software: you can redistribute it and/or modify it # under the terms of the GNU General Public License version 3, as published # by the Free Software Foundation. # # This program is distributed in the hope that it will be useful, but # WIT...
gpl-3.0
6,745,923,289,832,959,000
40.707763
97
0.617802
false
kivy/plyer
plyer/facades/spatialorientation.py
1
1652
# coding=utf-8 class SpatialOrientation: '''Spatial Orientation facade. Computes the device's orientation based on the rotation matrix. .. versionadded:: 1.3.1 ''' @property def orientation(self): '''Property that returns values of the current device orientation as a (azimut...
mit
2,274,473,714,694,799,000
29.481481
79
0.64277
false
RedFantom/ttkwidgets
ttkwidgets/linklabel.py
1
4045
""" Author: RedFantom License: GNU GPLv3 Source: This repository """ # Based on an idea by Nelson Brochado (https://www.github.com/nbrol/tkinter-kit) import tkinter as tk from tkinter import ttk import webbrowser class LinkLabel(ttk.Label): """ A :class:`ttk.Label` that can be clicked to open a link with a de...
gpl-3.0
-3,760,860,831,437,255,700
34.482456
127
0.596292
false
DStauffman/dstauffman2
dstauffman2/archery/tournaments/scripts/script_testing.py
1
5404
""" Main test script for running the code. Created on Mon Dec 15 13:21:07 2014 @author: DStauffman """ #%% Imports import os from dstauffman import setup_dir import dstauffman2.archery.tournaments as arch #%% Variables # simulate stuff? SIMULATE = True # folder and file locations folder = arch.get_roo...
lgpl-3.0
382,572,098,133,474,240
38.15942
121
0.725944
false
klahnakoski/esReplicate
pyLibrary/queries/expression_compiler.py
1
1182
# encoding: utf-8 # # # 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/. # # Author: Kyle Lahnakoski (kyle@lahnakoski.com) # from __future__ import absolute_import from __f...
mpl-2.0
-7,833,379,894,178,711,000
21.730769
122
0.652284
false
ywangd/stash
bin/grep.py
1
2282
# -*- coding: utf-8 -*- """Search a regular expression pattern in one or more files""" from __future__ import print_function import argparse import collections import fileinput import os import re import sys def main(args): global _stash ap = argparse.ArgumentParser() ap.add_argument('pattern', help='th...
mit
-3,807,069,574,870,944,300
34.65625
122
0.574934
false
wkoszek/puzzles
pattern_search/woogle_index.py
1
1936
#!/usr/bin/env python3 import getopt import sys import re import random import sqlite3 def main(): g_input_fn = False g_do_search = False g_dict_fn = False g_words = [] try: opts, args = getopt.getopt(sys.argv[1:], "hi:d:s:v", ["help", "input=", "dict=", "search="]) except getopt.GetoptError as err: ...
bsd-2-clause
6,192,522,204,303,101,000
21.776471
88
0.594008
false
tengqm/senlin-container
senlin/engine/service.py
1
95655
# Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed unde...
apache-2.0
-2,164,811,942,441,370,400
41.933124
79
0.569212
false
shoopio/shoop
shuup_tests/admin/test_shipment_creator.py
2
7442
# -*- coding: utf-8 -*- # This file is part of Shuup. # # Copyright (c) 2012-2019, Shoop Commerce Ltd. All rights reserved. # # This source code is licensed under the OSL-3.0 license found in the # LICENSE file in the root directory of this source tree. import re import pytest from bs4 import BeautifulSoup from djang...
agpl-3.0
8,639,049,885,013,082,000
39.89011
106
0.688793
false
Joacchim/Comix
src/archive.py
1
20550
# coding=utf-8 """archive.py - Archive handling (extract/create) for Comix.""" from __future__ import absolute_import import cStringIO import os import re import sys import tarfile import threading import zipfile import gtk try: from py7zlib import Archive7z except ImportError: Archive7z = None # ignore it....
gpl-2.0
2,014,588,338,973,242,000
37.555347
107
0.522238
false
debjyoti385/dartnews
crawling/newsParser.py
1
2286
from HTMLParser import HTMLParser import sys, re,os from os import listdir import Levenshtein class MLStripper(HTMLParser): def __init__(self): self.reset() self.fed = [] def handle_data(self, d): self.fed.append(d) def get_data(self): return ''.join(self.fed) def strip_tag...
bsd-2-clause
-7,346,165,303,894,431,000
25.581395
93
0.628171
false
ExaScience/smurff
data/jaak/make.py
1
3536
#!/usr/bin/env python import smurff.matrix_io as mio import urllib.request import scipy.io as sio import os from hashlib import sha256 import smurff urls = [ ( "http://homes.esat.kuleuven.be/~jsimm/chembl-IC50-346targets.mm", "10c3e1f989a7a415a585a175ed59eeaa33eff66272d47580374f26342cd...
mit
2,601,276,451,595,209,000
41.095238
145
0.680147
false
liorsion/django-backlinks
src/backlinks/pingback/client.py
1
4452
import re import xmlrpclib import urllib from backlinks.exceptions import fault_code_to_client_error, \ BacklinkClientError, BacklinkClientRemoteError, \ BacklinkClientConnectionError, BacklinkClientServerDoesNotExist,\ BacklinkClientAccessDenied, BacklinkClientInvalidResponse from backlinks.conf import se...
bsd-3-clause
-388,211,051,411,919,940
33.511628
85
0.621968
false
haystack/eyebrowse-server
notifications/views.py
1
6176
import datetime from django.http import HttpResponseRedirect from django.utils.decorators import method_decorator from django.views.generic import TemplateView from django.contrib.auth.decorators import login_required from django.contrib.auth.models import User from django.shortcuts import get_object_or_404 from dja...
mit
3,723,686,512,894,883,300
31.505263
82
0.622733
false
vanossj/pyAtlasBoneSegmentation
src/ICP.py
1
22312
''' Created on Feb 15, 2012 @author: Jeff ''' import numpy import numpyTransform from scipy.spatial import cKDTree as KDTree # from scipy.spatial import Delaunay from scipy.spatial.distance import cdist import scipy.optimize import time from math import pi from MatlabFunctions import MatlabFmincon import...
mit
-712,446,531,366,426,000
37.842857
176
0.551273
false
YuxuanLing/trunk
trunk/code/study/python/Fluent-Python-example-code/17-futures/countries/flags2_common.py
1
5430
"""Utilities for second set of flag examples. """ import os import time import sys import string import argparse from collections import namedtuple from enum import Enum Result = namedtuple('Result', 'status data') HTTPStatus = Enum('Status', 'ok not_found error') POP20_CC = ('CN IN US ID BR PK NG ...
gpl-3.0
4,697,844,028,749,351,000
34.442953
75
0.573849
false
sandygiuliani/drug_repo2
config.py
1
7501
# Copyright 2014 Sandra Giuliani # config.py # Configuration file for drug_repo.py ############################################################################ ### PERSONAL INFO ############################################################################ # what is your name? your_name = "Sandra" # what is your emai...
mit
6,203,926,662,967,334,000
32.19469
78
0.503933
false
blackshirt/simpletrain
models.py
1
1532
''' Database Models Models defined here =================== 1. User 2. Employee 3. Workplace 4. Training 5. Letter 6. LearningAssignment ''' import os from datetime import date, datetime from pony.orm import Database, sql_debug from pony.orm import Required, Optional, Set __all__ = ['db', 'User', 'Employee', 'Wor...
mit
-565,255,332,013,163,500
17.238095
71
0.673629
false
belatrix/BackendAllStars
activities/urls.py
1
1168
from .views import send_message_all, send_message_to, send_message_location, send_message_event from .views import get_activities, get_messages, get_messages_from, get_messages_from_all, get_notifications from django.conf.urls import url urlpatterns = [ url(r'^send/message/all/$', send_message_all, name='send_mes...
apache-2.0
4,920,638,106,448,543,000
72
111
0.696062
false
hansonrobotics/chatbot
test/test_chatbot.py
1
7163
#!/usr/bin/env python import unittest import os import sys import time import subprocess import signal RCFILE = os.environ.get('COVERAGE_RCFILE', '.coveragerc') from chatbot.client import Client class ChatbotTest(unittest.TestCase): @classmethod def setUpClass(self): self.port = '8002' self...
mit
1,190,334,528,366,401,300
39.931429
416
0.629066
false
jktubs/ctSESAM-python-memorizing
Crypter.py
1
1892
#!/usr/bin/python3 # -*- coding: utf-8 -*- """ Encryption and decryption module. """ from Crypto.Cipher import AES from hashlib import pbkdf2_hmac class Crypter: """ Encrypt and decrypt with AES in CBC mode with PKCS7 padding. The constructor calculates the key from the given password and salt with PBKDF...
gpl-3.0
-7,594,151,041,902,287,000
28.5625
114
0.609937
false
stormi/tsunami
src/secondaires/familier/fiche.py
1
5370
# -*-coding:Utf-8 -* # Copyright (c) 2014 LE GOFF Vincent # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # * Redistributions of source code must retain the above copyright notice, this # lis...
bsd-3-clause
-3,066,334,919,988,521,500
35.868966
79
0.674336
false
fernandog/Medusa
lib/tmdbsimple/tv.py
1
18419
# -*- coding: utf-8 -*- """ tmdbsimple.tv ~~~~~~~~~~~~~ This module implements the TV, TV Seasons, TV Episodes, and Networks functionality of tmdbsimple. Created by Celia Oakley on 2013-10-31. :copyright: (c) 2013-2018 by Celia Oakley :license: GPLv3, see LICENSE for more details """ from .base import TMDB class T...
gpl-3.0
-6,584,255,332,790,810,000
28.708065
80
0.569846
false
oskgeek/liftpass
config.py
1
2493
import sys import os # ------------------------------------------------------------------------------ # User Authentication - Liftpass is a single user application (for now) # ------------------------------------------------------------------------------ UserKey = b'd759214482924d10ac159b794e9424e7' UserSecret = b'4bf...
apache-2.0
-6,309,304,441,272,448,000
37.953125
80
0.349779
false
Paulloz/godot
glsl_builders.py
3
7347
"""Functions used to generate source files during build time All such functions are invoked in a subprocess on Windows to prevent build flakiness. """ from platform_methods import subprocess_main class RDHeaderStruct: def __init__(self): self.vertex_lines = [] self.fragment_lines = [] se...
mit
-8,014,658,679,955,484,000
31.653333
116
0.559412
false
jgmanzanas/CMNT_004_15
project-addons/vies_timestamp/fiscal_position.py
1
1201
# -*- coding: utf-8 -*- ############################################################################## # # Copyright (C) 2016 Comunitea Servicios Tecnológicos <www.comunitea.com> # $Omar Castiñeira Saavedra <omar@comunitea.com>$ # # This program is free software: you can redistribute it and/or modify # it u...
agpl-3.0
8,867,831,660,095,343,000
40.344828
78
0.633862
false
lionaneesh/sugarlabs-calculate
toolbars.py
1
14126
# -*- coding: utf-8 -*- # toolbars.py, see CalcActivity.py for info import pygtk pygtk.require('2.0') import gtk from mathlib import MathLib from sugar.graphics.palette import Palette from sugar.graphics.menuitem import MenuItem from sugar.graphics.toolbutton import ToolButton from sugar.graphics.toggletoolbutton imp...
gpl-2.0
-3,756,317,717,864,053,000
35.677922
84
0.569436
false
babelsberg/babelsberg-r
tests/constraints/test_midpoint.py
1
1511
import py from ..base import BaseTopazTest E = 0.00000000000001 class TestConstraintVariableObject(BaseTopazTest): def execute(self, space, code, *libs): return [space.execute(""" require "%s" %s """ % (lib, code)) for lib in libs] def test_midpoint(s...
bsd-3-clause
-4,466,466,756,293,176,000
21.552239
65
0.433488
false
LawrenceK/fs_monitor
fs_monitor.py
1
5649
#!/usr/bin/python # (C)opyright L.P.Klyne 2013 sw_topleft = 13 sw_topright = 7 sw_bottomleft = 12 sw_bottomright = 11 led_topleft = 22 led_topright = 18 led_bottomleft = 15 led_bottomright = 16 import logging import os import os.path import time import subprocess import RPi.GPIO as GPIO _log = logging.getLogger() log...
bsd-3-clause
-5,335,742,982,079,361,000
26.691176
86
0.582404
false
coxmediagroup/dolphin
dolphin/tests/templatetags.py
1
2824
import re from django.contrib.auth.models import User from django.template import Context, Template from dolphin.middleware import LocalStoreMiddleware from dolphin.tests.flipper import BaseTest class ActiveTagTest(BaseTest): fixtures = ['dolphin_base_flags.json'] def check_res(self, text, expected): ...
mit
-5,243,593,176,856,959,000
27.24
91
0.554178
false
jprovaznik/tripleo-common
tripleo_common/tests/test_updates.py
1
3507
# Copyright 2015 Red Hat, Inc. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law o...
apache-2.0
6,384,612,201,289,550,000
37.966667
79
0.57485
false
arokem/scipy
scipy/sparse/linalg/eigen/lobpcg/tests/test_lobpcg.py
1
12773
""" Test functions for the sparse.linalg.eigen.lobpcg module """ from __future__ import division, print_function, absolute_import import itertools import platform import numpy as np from numpy.testing import (assert_almost_equal, assert_equal, assert_allclose, assert_array_less) import pyt...
bsd-3-clause
-3,813,003,098,075,375,000
31.092965
82
0.581148
false
docusign/docusign-python-client
docusign_esign/models/id_check_configuration.py
1
4802
# coding: utf-8 """ DocuSign REST API The DocuSign REST API provides you with a powerful, convenient, and simple Web services API for interacting with DocuSign. # noqa: E501 OpenAPI spec version: v2.1 Contact: devcenter@docusign.com Generated by: https://github.com/swagger-api/swagger-codegen.gi...
mit
8,359,876,280,570,722,000
26.757225
140
0.557268
false
Undo1/Torch
script.py
1
1147
from BeautifulSoup import BeautifulSoup import mysql.connector import config #Where we keep our passwords and stuff import tldextract import itertools cnx = mysql.connector.connect(user=config.MySQLUsername(), password=config.MySQLPassword(), host=config.MySQLHost(), database=config.MySQLDatabase()) cursor = cnx.curso...
mit
-2,881,982,992,902,040,000
27
149
0.72973
false
mistercrunch/panoramix
superset/databases/api.py
1
34612
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
apache-2.0
-2,846,362,746,387,505,000
33.405567
88
0.53649
false
jonathf/chaospy
chaospy/distributions/collection/wald.py
1
2480
"""Wald distribution.""" import numpy from scipy import special import chaospy from ..baseclass import SimpleDistribution, ShiftScaleDistribution class wald(SimpleDistribution): """Wald distribution.""" def __init__(self, mu): super(wald, self).__init__(dict(mu=mu)) def _pdf(self, x, mu): ...
mit
-2,990,161,795,545,608,000
26.865169
83
0.522177
false
crchemist/scioncc
src/ion/util/preload.py
1
24501
#!/usr/bin/env python """Utility to bulk load resources into the system, e.g. for initial preload""" __author__ = 'Michael Meisinger' import yaml import re import os from pyon.core import MSG_HEADER_ACTOR, MSG_HEADER_ROLES, MSG_HEADER_VALID from pyon.core.bootstrap import get_service_registry from pyon.core.governa...
bsd-2-clause
-1,043,299,870,787,946,800
44.288355
135
0.572303
false
stormi/tsunami
outils/gestionnaire_module/commande.py
1
3556
# -*-coding:Utf-8 -* # Copyright (c) 2011 DAVY Guillaume # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # * Redistributions of source code must retain the above copyright notice, this # li...
bsd-3-clause
6,856,015,116,057,477,000
31.605505
79
0.664603
false
catapult-project/catapult
common/py_vulcanize/third_party/rjsmin/bench/write.py
3
10657
#!/usr/bin/env python # -*- coding: ascii -*- r""" ========================= Write benchmark results ========================= Write benchmark results. :Copyright: Copyright 2014 - 2015 Andr\xe9 Malo or his licensors, as applicable :License: Licensed under the Apache License, Version 2.0 (the "License"); you ...
bsd-3-clause
-5,912,417,761,413,347,000
29.800578
77
0.449282
false
Funjando/Birthday-quiz
birthday.py
1
2316
""" birthday.py Author: Andreas Credit: Dan, Payton, tiggerntatie Assignment: Your program will ask the user the following questions, in this order: 1. Their name. 2. The name of the month they were born in (e.g. "September"). 3. The year they were born in (e.g. "1962"). 4. The day they were born on (e.g. "11"). If ...
mit
3,509,998,420,052,973,000
22.876289
90
0.667962
false
bndl/bndl
bndl/net/watchdog.py
1
7044
# Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under th...
apache-2.0
-6,064,973,426,037,575,000
32.542857
109
0.59753
false
madgik/exareme
Exareme-Docker/src/exareme/exareme-tools/madis/src/functions/vtable/sqlite.py
1
1466
""" .. function:: sqlite(dbfilename, query:None) Connects to an SQLite DB and returns the results of query. Examples: >>> sql("select * from (sqlite 'testdb.db' select 5 as num, 'test' as text);") num | text ----------- 5 | test """ import functions import os import vtbase registered = True ext...
mit
839,091,539,181,260,900
19.647887
99
0.583902
false
shibanis1/spark-tk
python/sparktk/frame/ops/drop_rows.py
1
1541
from sparktk.frame.row import Row def drop_rows(self, predicate): """ Erase any row in the current frame which qualifies. Parameters ---------- :param predicate: (UDF) Function which evaluates a row to a boolean; rows that answer True are dropped from the frame. Examples...
apache-2.0
887,973,931,321,488,600
33.244444
111
0.447761
false
qix/tooler
tooler/command.py
1
1233
import io from typing import Dict, Optional from .exceptions import CommandHelpException from .parser import DefaultParser class Command: def __init__(self): pass def run(self, selector, argv): raise Exception("not implemented") class DecoratorCommand(Command): def __init__(self, fn, doc=None, parse...
mit
-8,756,057,895,321,486,000
24.6875
93
0.632603
false
felixmatt/shyft
shyft/repository/service/yaml_geo_location_repository.py
1
1391
# -*- coding: utf-8 -*- from __future__ import absolute_import import yaml from .ssa_geo_ts_repository import GeoLocationRepository from os import path class YamlGeoLocationError(Exception): pass class YamlGeoLocationRepository(GeoLocationRepository): """ Provide a yaml-based key-location map for gis-i...
lgpl-3.0
-733,572,491,415,712,300
27.979167
85
0.608196
false
UNINETT/nav
python/nav/portadmin/handlers.py
1
11747
# # Copyright (C) 2011-2015, 2020 UNINETT # # This file is part of Network Administration Visualized (NAV). # # NAV is free software: you can redistribute it and/or modify it under # the terms of the GNU General Public License version 3 as published by # the Free Software Foundation. # # This program is distributed in ...
gpl-2.0
7,145,446,863,028,580,000
38.026578
88
0.660935
false
demonchild2112/travis-test
grr/server/grr_response_server/databases/db_clients_test.py
1
71030
#!/usr/bin/env python # -*- encoding: utf-8 -*- from __future__ import absolute_import from __future__ import division from __future__ import unicode_literals from future.builtins import range from future.utils import iteritems from future.utils import iterkeys import mock from typing import Text from grr_response_co...
apache-2.0
-512,624,584,033,677,000
38.0011
80
0.688537
false
botify-labs/simpleflow
swf/querysets/history.py
1
2268
from swf.models import History from swf.querysets.base import BaseQuerySet class HistoryQuerySet(BaseQuerySet): """WorkflowExecution history queryset""" def __init__(self, domain, *args, **kwargs): super(HistoryQuerySet, self).__init__(*args, **kwargs) self.domain = domain def get(self, ...
mit
-425,559,705,143,165,500
36.180328
95
0.592152
false
ic-hep/DIRAC
Core/Utilities/ClassAd/ClassAdLight.py
1
8864
######################################################################## # $HeadURL$ ######################################################################## """ ClassAd Class - a light purely Python representation of the Condor ClassAd library. """ __RCSID__ = "$Id$" class ClassAd: def __init__( self, jdl ):...
gpl-3.0
-481,757,788,879,941,700
26.027439
95
0.525496
false
google-research/robel
robel/scripts/check_mujoco_deps.py
1
1290
# Copyright 2019 The ROBEL Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in wr...
apache-2.0
-2,726,141,442,768,360,400
29
74
0.723256
false
shgo/baixa_camara
obter_inteiro_teor.py
1
7140
#!/usr/bin/python3 #-*- encoding: utf-8 -*- #Copyright (C) 2016 Saullo Oliveira # #This program is free software: you can redistribute it and/or modify #it under the terms of the GNU General Public License as published by #the Free Software Foundation, either version 3 of the License, or #(at your option) any later ve...
gpl-3.0
-8,356,535,699,134,562,000
41.795181
103
0.562922
false
StartTheShift/thunderdome
thunderdome/properties.py
1
13707
# Copyright (c) 2012-2013 SHIFT.com # # Permission is hereby granted, free of charge, to any person obtaining a copy of # this software and associated documentation files (the "Software"), to deal in # the Software without restriction, including without limitation the rights to # use, copy, modify, merge, publish, dist...
mit
-7,597,682,304,716,384,000
28.540948
115
0.607208
false
tps12/freezing-shame
freezing/shame/tests/views/test_cart.py
1
5789
from django.test import TestCase class CartTest(TestCase): from django.test.client import Client Client = staticmethod(Client) from shame.models import Store Store = staticmethod(Store) from shame.models import Product Product = staticmethod(Product) from xml.etree import ElementTree ...
gpl-3.0
6,249,128,531,331,405,000
29.308901
80
0.564346
false
isaacyeaton/global-dyn-non-equil-gliding
Code/script_airfoil_snake.py
1
18626
# -*- coding: utf-8 -*- """ Created on Thu Aug 14 14:16:45 2014 %reset -f %clear %pylab %load_ext autoreload %autoreload 2 @author: isaac """ from __future__ import division import numpy as np import matplotlib.pyplot as plt from scipy.interpolate import UnivariateSpline from scipy.io import loadmat # setup better...
mit
-5,088,139,220,984,201,000
26.925037
80
0.633953
false
brain-tec/partner-contact
partner_multi_relation_tabs/tests/test_tab.py
1
1766
# Copyright 2018 Therp BV <https://therp.nl>. # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). from . import common from ..tablib import Tab class TestTab(common.TestCommon): def test_create_page(self): self.assertTrue(bool(self.tab_board)) tab_obj = Tab(self.tab_board) ...
agpl-3.0
360,778,801,671,219,900
44.282051
78
0.660815
false
bb111189/CryptoKnocker
CryptoKnocker/CryptoKnocker/settings.py
1
2239
""" Django settings for CryptoKnocker project. For more information on this file, see https://docs.djangoproject.com/en/1.6/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/1.6/ref/settings/ """ # Build paths inside the project like this: os.path.join(BASE_DIR, ....
mit
2,499,307,004,532,393,000
23.075269
71
0.714605
false
peragro/peragro-at
src/damn_at/metadatastore.py
1
2111
""" The MetaDataStore handler. """ from __future__ import absolute_import import os from damn_at.utilities import is_existing_file, pretty_print_file_description from damn_at.bld import hash_to_dir from damn_at.serialization import SerializeThriftMsg, DeserializeThriftMsg from damn_at import FileDescription from io i...
bsd-3-clause
1,144,821,180,542,708,000
30.984848
106
0.636191
false
moyaproject/moya
moya/settings.py
1
10368
from __future__ import unicode_literals from __future__ import print_function from __future__ import absolute_import from .containers import OrderedDict from . import iniparse from .compat import text_type, string_types, PY2, implements_to_string, implements_bool from . import errors from .tools import textual_list f...
mit
-4,349,579,899,935,977,000
29.404692
92
0.53559
false
Macainian/BaseDjangoProject
website/management/commands/create_admin_account_migration.py
1
1751
import os from django.core.management.base import BaseCommand from website.settings import BASE_DIR class Command(BaseCommand): def handle(self, *args, **options): migrations_folder = os.path.join(BASE_DIR, "website", "migrations") admin_account_migration_text = self.get_admin_account_migration_...
mit
-4,347,252,034,574,000,600
32.692308
112
0.682467
false
rpdillon/wikid
wikid/__init__.py
1
3539
#!/usr/bin/env python # wikid, Copyright (c) 2010, R. P. Dillon <rpdillon@etherplex.org> # This file is part of wikid. # # wikid is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License...
gpl-3.0
-6,462,069,072,412,644,000
31.768519
99
0.658378
false
ngokevin/zamboni
mkt/translations/tests/test_helpers.py
1
4925
from django.conf import settings from django.utils import translation import jingo from mock import Mock, patch from nose.tools import eq_ import amo import amo.tests from mkt.translations import helpers from mkt.translations.fields import save_signal from mkt.translations.models import PurifiedTranslation from mkt.t...
bsd-3-clause
3,741,023,886,050,559,500
33.683099
78
0.633503
false
jjdmol/LOFAR
CEP/Pipeline/framework/lofarpipe/support/xmllogging.py
1
5594
""" xml based logging constructs and helpers functions """ import xml.dom.minidom as _xml def add_child(head, name): """ Create a node with name. And append it to the node list of the supplied node. (This function allows duplicate head names as specified by xml) return the create node. ...
gpl-3.0
-4,474,977,738,795,691,000
35.046358
78
0.63157
false
markstoehr/structured_gaussian_mixtures
lstm_gaussian_mixtures/test_negative_loglikelihood.py
1
2280
%autoindent import numpy import theano from theano import tensor def numpy_floatX(data): return numpy.asarray(data, dtype=theano.config.floatX) num_timesteps = 10 num_sequences = 3 num_dim = 2 num_components = 3 x_n = (numpy.arange(num_timesteps * num_sequences * num_dim, dtype=th...
apache-2.0
-6,745,985,951,908,591,000
29.4
71
0.571053
false
Star2Billing/did-control
docs/source/conf.py
1
7294
# -*- coding: utf-8 -*- # # django-admin-tools-stats documentation build configuration file, created by # sphinx-quickstart on Wed Sep 7 13:28:47 2011. # # This file is execfile()d with the current directory set to its containing dir. # # Note that not all possible configuration values are present in this # autogenera...
agpl-3.0
6,974,228,185,238,109,000
32.154545
84
0.70935
false
tensorflow/graphics
tensorflow_graphics/nn/layer/pointnet.py
1
8675
# Copyright 2020 The TensorFlow Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to i...
apache-2.0
-210,864,469,539,070,560
34.264228
81
0.69487
false
cfelton/minnesota
mn/cores/fifo/_fifo_sync.py
1
3380
# Copyright (c) 2014 Christopher L. Felton # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Lesser General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is...
gpl-3.0
8,068,396,567,377,177,000
28.4
78
0.557692
false
njantrania/osf.io
scripts/refresh_box_tokens.py
1
1487
#!/usr/bin/env python # encoding: utf-8 import sys import logging import datetime from modularodm import Q from dateutil.relativedelta import relativedelta from scripts import utils as scripts_utils from website.app import init_app from website.oauth.models import ExternalAccount from website.addons.base.exceptions ...
apache-2.0
3,008,566,150,502,636,000
26.537037
69
0.63618
false
denversc/cligen
cligen/target_python.py
1
1177
# Copyright 2015 Denver Coneybeare <denver@sleepydragon.org> # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This ...
gpl-3.0
-7,476,964,423,816,049,000
31.694444
71
0.68819
false
chimkentec/KodiMODo_rep
plugin.video.torrenter/resources/scrapers/net.py
1
9741
# -*- coding: utf-8 -*- import os import time import re import urllib import urllib2 import cookielib import base64 import mimetools import itertools import xbmc import xbmcgui import xbmcvfs RE = { 'content-disposition': re.compile('attachment;\sfilename="*([^"\s]+)"|\s') } # ################################ #...
gpl-3.0
6,977,368,259,031,119,000
31.79798
119
0.539267
false
inveniosoftware-contrib/json-merger
json_merger/conflict.py
1
4958
# -*- coding: utf-8 -*- # # This file is part of Inspirehep. # Copyright (C) 2016 CERN. # # Inspirehep is free software; you can redistribute it # and/or modify it under the terms of the GNU General Public License as # published by the Free Software Foundation; either version 2 of the # License, or (at your option) any...
gpl-2.0
-1,570,750,061,068,503,300
33.430556
79
0.635942
false
theworldbright/mainsite
aspc/courses/models.py
1
9654
from django.db import models from django.conf import settings from datetime import date, datetime, timedelta import json from django.core.serializers.json import DjangoJSONEncoder CAMPUSES = ( (1, u'PO'), (2, u'SC'), (3, u'CMC'), (4, u'HM'), (5, u'PZ'), (6, u'CGU'), (7, u'CU'), (8, u'KS'), (-1, u'?')) CAMPUSES_FUL...
mit
-5,253,931,363,524,595,000
33.355872
120
0.610317
false
3324fr/spinalcordtoolbox
dev/control_points/make_centerline.py
1
3765
# Main fonction return the centerline of the mifti image fname as a nifti binary file # Centerline is generated using sct_nurbs with nbControl = size/div from sct_nurbs_v2 import * import nibabel import splines_approximation_v2 as spline_app from scipy import ndimage import numpy import commands import linear_fitting...
mit
7,278,184,712,280,968,000
31.188034
114
0.592297
false
ceibal-tatu/sugar-toolkit-gtk3
src/sugar3/graphics/window.py
1
10947
# Copyright (C) 2007, Red Hat, Inc. # Copyright (C) 2009, Aleksey Lim, Sayamindu Dasgupta # # This library is free software; you can redistribute it and/or # modify it under the terms of the GNU Lesser General Public # License as published by the Free Software Foundation; either # version 2 of the License, or (at your ...
lgpl-2.1
-8,212,694,695,301,188,000
32.787037
77
0.603636
false
YuepengGuo/backtrader
docs/observers-and-statistics/observers-default.py
1
1323
#!/usr/bin/env python # -*- coding: utf-8; py-indent-offset:4 -*- ############################################################################### # # Copyright (C) 2015 Daniel Rodriguez # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as pub...
gpl-3.0
-4,085,089,415,937,773,000
36.8
79
0.628118
false
mic4ael/indico
indico/util/suggestions.py
1
5843
# This file is part of Indico. # Copyright (C) 2002 - 2020 CERN # # Indico is free software; you can redistribute it and/or # modify it under the terms of the MIT License; see the # LICENSE file for more details. from __future__ import division, print_function, unicode_literals from collections import defaultdict fro...
mit
1,942,233,109,239,338,800
45.007874
114
0.655827
false
coreequip/xbmc-addon-service-watchedlist
service.py
1
62979
""" This file contains the class of the addon Settings for this addon: w_movies 'true', 'false': save watched state of movies w_episodes 'true', 'false': save watched state of movies autostart delay delay after startup in minutes: '0', '5', '10', ... starttype '0' = No autostart '1' = One Execution...
gpl-3.0
-5,481,094,405,210,845,000
53.060086
337
0.529812
false
wadobo/timebank
tinymce/views.py
1
4408
# Copyright (c) 2008 Joost Cassee # Licensed under the terms of the MIT License (see LICENSE.txt) import json import logging from django.core import urlresolvers from django.http import HttpResponse from django.shortcuts import render_to_response from django.template import RequestContext, loader from django.utils.tra...
agpl-3.0
2,562,349,873,354,733,000
33.170543
79
0.667877
false
Gentux/etalage
docs/conf.py
1
8704
# -*- coding: utf-8 -*- # # Etalage documentation build configuration file, created by # sphinx-quickstart on Mon Sep 29 17:01:04 2014. # # This file is execfile()d with the current directory set to its # containing dir. # # Note that not all possible configuration values are present in this # autogenerated file. # # A...
agpl-3.0
101,110,575,252,617,650
31
82
0.707835
false
markokr/sysca
tests/helpers.py
1
1213
import binascii import os.path from sysca import api as sysca _FDIR = os.path.join(os.path.dirname(__file__), "files") def demo_fn(basename): return os.path.join(_FDIR, basename) def demo_data(basename, mode="rb"): if "b" in mode: with open(demo_fn(basename), mode) as f: return f.read...
isc
-8,735,806,898,496,008,000
25.955556
88
0.619126
false
onitake/Uranium
examples/definition_viewer/main.py
1
2450
# Copyright (c) 2016 Ultimaker B.V. # Uranium is released under the terms of the AGPLv3 or higher. import sys import os.path import signal import traceback from PyQt5.QtCore import QObject, QUrl, pyqtSlot, pyqtProperty, pyqtSignal from PyQt5.QtQml import QQmlApplicationEngine, qmlRegisterType from PyQt5.QtWidgets imp...
agpl-3.0
3,755,217,824,218,569,000
30.410256
96
0.677959
false
yeon3683/handpose
util/handdetector.py
1
18839
"""Provides a basic hand detector in depth images. HandDetector provides interface for detecting hands in depth image, by using the center of mass. Copyright 2015 Markus Oberweger, ICG, Graz University of Technology <oberweger@icg.tugraz.at> This file is part of DeepPrior. DeepPrior is free software: you can redistribu...
gpl-3.0
4,676,184,767,098,701,000
39.86551
136
0.524019
false
ytsarev/rally
rally/deploy/serverprovider/providers/existing.py
1
2084
# Copyright 2013: Mirantis Inc. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required b...
apache-2.0
-183,121,135,223,786,270
32.612903
78
0.545106
false
odicraig/kodi2odi
addons/plugin.video.teevee/default.py
1
19931
from __future__ import unicode_literals from resources.lib.modules.addon import Addon import sys,os,re import urlparse,urllib import xbmc, xbmcgui, xbmcplugin, xbmcaddon from resources.lib.modules import control,client,teevee2,metadata,cache from resources.lib.modules.log_utils import log meta_enabled = contro...
gpl-3.0
4,522,614,937,469,297,000
37.315582
212
0.558928
false
ooici/coi-services
ion/core/function/transform_function.py
1
2817
#!/usr/bin/env python ''' @author: Tim Giguere <tgiguere@asascience.com> @description: New Implementation for TransformFunction classes ''' from pyon.public import log from pyon.core.exception import BadRequest from interface.objects import Granule class TransformFunction(object): """ The execute function r...
bsd-2-clause
-3,256,532,145,519,457,300
32.951807
114
0.672346
false
mandeepdhami/neutron
neutron/tests/unit/agent/test_securitygroups_rpc.py
1
142446
# Copyright 2012, Nachi Ueno, NTT MCL, Inc. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unles...
apache-2.0
7,476,213,703,544,293,000
45.627169
79
0.550896
false
timj/scons
src/engine/SCons/Tool/rpm.py
1
4470
"""SCons.Tool.rpm Tool-specific initialization for rpm. There normally shouldn't be any need to import this module directly. It will usually be imported through the generic SCons.Tool.Tool() selection method. The rpm tool calls the rpmbuild command. The first and only argument should a tar.gz consisting of the sourc...
mit
5,327,432,468,304,638,000
32.863636
92
0.650783
false
svieira/Flask-HipPocket
flask_hippocket/tasks.py
1
3301
# -*- coding: utf-8 -*- """ flask.ext.hippocket.tasks ~~~~~~~~~~~~~~~~~~~~~~~~~ :copyright: (c) 2013 by Sean Vieira. :license: MIT, see LICENSE for more details. """ from flask import Blueprint, Markup, request, render_template from itertools import chain from os import path from pkgutil import walk_p...
mit
-5,610,174,353,615,824,000
37.383721
105
0.604059
false
mscherer/rpmlint
InitScriptCheck.py
1
11946
# -*- coding: utf-8 -*- ############################################################################# # Project : Mandriva Linux # Module : rpmlint # File : InitScriptCheck.py # Author : Frederic Lepied # Created On : Fri Aug 25 09:26:37 2000 # Purpose : check init scri...
gpl-2.0
-7,705,326,315,198,297,000
40.915789
90
0.536665
false
westurner/opengov
docs/conf.py
1
14116
#!/usr/bin/env python # -*- coding: utf-8 -*- # # complexity documentation build configuration file, created by # sphinx-quickstart on Tue Jul 9 22:26:36 2013. # # This file is execfile()d with the current directory set to its containing dir. # # Note that not all possible configuration values are present in this # au...
bsd-3-clause
-5,590,527,293,191,413,000
30.368889
82
0.680929
false
olsonse/python-vxi11
doc/conf.py
1
8582
# -*- coding: utf-8 -*- # # VXI-11 for Python documentation build configuration file, created by # sphinx-quickstart on Fri Jul 7 11:57:43 2017. # # This file is execfile()d with the current directory set to its # containing dir. # # Note that not all possible configuration values are present in this # autogenerated f...
gpl-2.0
6,429,391,774,352,015,000
30.785185
99
0.706246
false