repo_name
stringlengths
5
92
path
stringlengths
4
221
copies
stringclasses
19 values
size
stringlengths
4
6
content
stringlengths
766
896k
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
32
997
alpha_frac
float64
0.25
0.96
autogenerated
bool
1 class
ratio
float64
1.5
13.6
config_test
bool
2 classes
has_no_keywords
bool
2 classes
few_assignments
bool
1 class
christiansandberg/canopen
canopen/emcy.py
1
4163
import struct import logging import threading import time # Error code, error register, vendor specific data EMCY_STRUCT = struct.Struct("<HB5s") logger = logging.getLogger(__name__) class EmcyConsumer(object): def __init__(self): #: Log of all received EMCYs for this node self.log = [] ...
mit
6,766,806,848,442,568,000
29.837037
63
0.554648
false
3.858202
false
false
false
benjsmith/mubiomics
MPSDemultiplexer/patricia.py
1
3563
#!/usr/local/bin/python #patrcia.py #Python class definitions for creating a radix-like trie. # Copyright (C) <2012> <Benjamin C. Smith> # # 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 Foun...
gpl-3.0
3,643,960,447,306,891,000
30.263158
75
0.386191
false
4.147846
false
false
false
Vaei/ModularChannelBox
jtChannelBox_Menu_Rigging.py
1
19478
# jtChannelBox - Modular / Customizeable Channel Box # Copyright (C) 2016 Jared Taylor # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as # published by the Free Software Foundation, either version 3 of the # License, or (at your ...
agpl-3.0
2,335,228,321,807,812,600
55.294118
118
0.595595
false
3.712217
false
false
false
iansealy/projecteuler
optimal/9.py
1
1324
#!/usr/bin/env python """This script solves the Project Euler problem "Special Pythagorean triplet". The problem is: There exists exactly one Pythagorean triplet for which a + b + c = 1000. Find the product abc. """ from __future__ import division import math def main(): """Special Pythagorean triplet""" #...
gpl-3.0
8,416,430,042,208,403,000
21.066667
78
0.428248
false
3.167464
false
false
false
JaneliaSciComp/janelia-parking-manager
ParkingPermit/models.py
1
11541
""" Holds all of the data models for the site for managing campus visitors. TODO: Triggers for history so we don't lose old data - document Load new data - Update to use user defined make/model Future: history Deploy notes: """ import datetime import re from django.contrib.auth.models import Group, User fr...
bsd-3-clause
6,460,956,195,560,898,000
40.071174
155
0.673858
false
3.742218
false
false
false
0x7678/binwalk
src/binwalk/modules/binvis.py
1
10370
# Generates 3D visualizations of input files. import os from binwalk.core.compat import * from binwalk.core.common import BlockFile from binwalk.core.module import Module, Option, Kwarg class Plotter(Module): ''' Base class for visualizing binaries in Qt. Other plotter classes are derived from this. '...
mit
-8,027,040,989,788,108,000
32.451613
117
0.539923
false
4.10368
false
false
false
dmilith/SublimeText3-dmilith
Packages/pymdownx/st3/pymdownx/mark.py
1
2825
""" Mark. pymdownx.mark Really simple plugin to add support for <mark>test</mark> tags as ==test== MIT license. Copyright (c) 2014 - 2017 Isaac Muse <isaacmuse@gmail.com> Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software")...
mit
-617,774,133,755,232,400
32.235294
111
0.662655
false
3.746684
false
false
false
agapow/egas
egas/models.py
1
2568
### IMPORTS from flask_appbuilder import Model from flask_appbuilder.models.mixins import AuditMixin from sqlalchemy import Table, ForeignKey, Column, Integer, String, Enum, Float, Text from sqlalchemy.orm import relationship #from sqlalchemy import UniqueConstraint from . import consts from . import utils ### C...
mit
7,409,194,600,156,728,000
24.425743
101
0.669782
false
3.542069
false
false
false
PalisadoesFoundation/switchmap-ng
switchmap/test/test_general.py
1
15337
#!/usr/bin/env python3 """Test the general module.""" import getpass import unittest import random import os import sys import string import tempfile import yaml import shutil # Try to create a working PYTHONPATH TEST_DIRECTORY = os.path.dirname(os.path.realpath(__file__)) SWITCHMAP_DIRECTORY = os.path.abspath(os.pat...
apache-2.0
-1,092,549,414,544,443,000
32.341304
78
0.569407
false
4.390782
true
false
false
edonyM/toolkitem
fileprocess/emgui/filebrowser.py
1
14274
#!/usr/bin/env python # -*- coding: utf-8 -*- r""" # .---. .----------- # / \ __ / ------ # / / \( )/ ----- (`-') _ _(`-') <-. (`-')_ # ////// '\/ ` --- ( OO).-/( (OO ).-> .-> \( OO) ) .-> # //// / // : : --- (,------....
mit
-9,219,411,283,376,683,000
41.230769
112
0.519756
false
3.684564
false
false
false
DoraemonShare/yuqing
src/utils/utils.py
1
4066
#-*-coding:utf-8 -*- cartypeMap = { '"******************"': '"******************"', '"******************"': '"******************"', '"******************"': '"******************"', '"******************"': '"******************"' } #目前舆情分析中关注的列,列名来自postgresql数据表 concern_colcumns = ['topic', 'publicationD...
bsd-3-clause
7,075,182,384,411,835,000
29.936
189
0.528712
false
3.034537
false
false
false
aewallin/openvoronoi
python_examples/offset/offset_2_ttt.py
1
8593
import openvoronoi as ovd # https://github.com/aewallin/openvoronoi import ovdvtk # for VTK visualization, https://github.com/aewallin/openvoronoi import truetypetracer as ttt # https://github.com/aewallin/truetype-tracer import offset2vtk # vtk visualization helper https://github.com/aewallin/openvoronoi import t...
lgpl-2.1
-6,805,446,223,300,510,000
33.23506
123
0.635285
false
3.004545
false
false
false
apmechev/GRID_LRT
docs/conf.py
1
5577
# -*- coding: utf-8 -*- # # GRID_LRT documentation build configuration file, created by # sphinx-quickstart on Mon Feb 5 09:40:38 2018. # # 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. # # ...
gpl-3.0
2,674,878,722,036,451,300
29.47541
90
0.671149
false
3.742953
true
false
false
xclaeys/ElastoPhi
postprocessing/graphes_output_err_decrease.py
1
2917
# -*-coding:Utf-8 -* import Vue.Figure as figure import Vue.Donnee as donnee import Lecture.FonctionLectureClassique as classique import numpy as np import sys ######################################################################################## #------------------------------- Input -----------...
lgpl-3.0
-2,422,340,530,487,132,000
27.598039
144
0.569421
false
2.829292
false
false
false
diffeo/Datawake
memex-datawake-stream/src/datawakeio/HBASEEntityDataConnector.py
1
1852
import happybase from datawakeio.data_connector import ExtractedDataConnector class HBASEDataConnector(ExtractedDataConnector): def __init__(self, hbase_host): ExtractedDataConnector.__init__(self) self.hbase_host = hbase_host self.hbase_conn = None def open(self): self.hbase...
apache-2.0
-8,978,908,006,801,545,000
33.962264
91
0.591793
false
3.481203
false
false
false
FrodeSolheim/fs-uae-launcher
amitools/vamos/lib/lexec/Pool.py
1
1784
from amitools.vamos.log import log_exec from amitools.vamos.error import * from .Puddle import Puddle class Pool: def __init__(self, mem, alloc, flags, size, thresh, poolid): self.alloc = alloc self.mem = mem self.minsize = size self.flags = flags self.thresh = thresh self.name =...
gpl-2.0
-7,964,768,728,106,835,000
29.237288
96
0.598094
false
3.081174
false
false
false
Kagami/shitsu
shitsu/utils/__init__.py
1
4409
################################################## # shitsu - tiny and flexible xmpp bot framework # Copyright (C) 2008-2012 Kagami Hiiragi <kagami@genshiken.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 So...
gpl-3.0
-3,346,007,296,900,773,400
30.492857
79
0.585167
false
3.488133
false
false
false
kevinconway/require.py
require/__init__.py
1
7262
"""Alternate import logic that provides for multiple dependency versions.""" from __future__ import division from __future__ import absolute_import from __future__ import print_function from __future__ import unicode_literals from collections import defaultdict import contextlib import inspect import os import sys fr...
apache-2.0
8,249,302,086,919,257,000
29.512605
79
0.623382
false
4.493812
false
false
false
Vrekrer/magdynlab
instruments/srs_ds335.py
1
4144
# coding=utf-8 # Author: Diego González Chávez # email : diegogch@cbpf.br / diego.gonzalez.chavez@gmail.com # # This class controls the: # Signal Generator # Stanford Research Systems : DS335 # # TODO: # Make documentation from .instruments_base import InstrumentBase as _InstrumentBase __all__ = ['SRS_DS335'] clas...
mit
5,892,871,699,193,613,000
29.681481
77
0.549734
false
3.30303
false
false
false
PALab/pyjamaseis
pyjamaseis/pyjamaseisv2.0.py
1
89157
#================================================================================================================= # Structure of PyjAmaseis # # - IMPORTS # - STATION INFORMATION USER INTERFACE CODE (class myFrame4) # - SECONDARY OPTIONS UI WINDOW CODE (class selectionWindow) # - CODE FOR FRAME WHICH APPEARS AT BOTTOM...
gpl-2.0
3,916,063,271,660,287,500
49.946857
281
0.582119
false
3.772883
true
false
false
luhn/pubsubclub
test2.py
1
1562
from twisted.internet import reactor from autobahn.wamp1 import protocol as wamp from autobahn.twisted.websocket import listenWS from pubsubclub import ( ConsumerMixin, ProducerMixin, ConsumerServer, ProducerClient, consul, ) class WampServerProtocol(wamp.WampServerProtocol): def onSessionOpen(self): ...
mit
-5,059,213,242,148,466,000
24.606557
78
0.638284
false
3.914787
false
false
false
Johnzero/OE7
OE-debug文件/PyWapFetion-master/PyWapFetion/Fetion.py
1
5245
#coding=utf-8 from cookielib import MozillaCookieJar from urllib2 import Request, build_opener, HTTPHandler, HTTPCookieProcessor from urllib import urlencode import base64 import os from Errors import * from re import compile from Cache import Cache from gzip import GzipFile try: from cStringIO import StringIO exce...
agpl-3.0
-1,393,321,632,573,504,300
31.13125
79
0.571873
false
3.656472
false
false
false
umangv/LitHub
LitHub/fbconnect/utils.py
1
5141
# Copyright 2011 Kalamazoo College Computer Science Club # <kzoo-cs-board@googlegroups.com> # This file is part of LitHub. # # LitHub 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 v...
gpl-3.0
-8,131,026,453,522,601,000
38.244275
76
0.613888
false
3.951576
false
false
false
georgejhunt/HaitiDictionary.activity
palettes.py
1
10881
# Copyright (C) 2008, One Laptop Per Child # Copyright (C) 2009, Tomeu Vizoso, Simon Schampijer # # 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 2 of the License, or # (at your o...
gpl-2.0
158,557,187,725,631,200
35.029801
79
0.602151
false
3.982796
false
false
false
mbohlool/client-python
kubernetes/client/models/v1beta2_stateful_set_list.py
1
6301
# coding: utf-8 """ Kubernetes No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) OpenAPI spec version: v1.8.2 Generated by: https://github.com/swagger-api/swagger-codegen.git """ from pprint import pformat from six import iteritems import re ...
apache-2.0
-815,164,855,839,261,300
29.439614
281
0.594509
false
4.164574
false
false
false
tkw1536/PythonCaseClass
case_class/case_class.py
1
8346
""" CaseClass implementation for the case_class module Copyright (c) 2016 Tom Wiesing -- licensed under MIT, see LICENSE """ import inspect from . import exceptions, clsutils, signature # # Meta-classes for the case class # class CaseClassMeta(type): """ Meta-Class for case classes. """ instance_keys = ...
mit
-7,552,289,889,035,847,000
25.495238
79
0.593937
false
4.385707
false
false
false
yakky/django-form-designer
form_designer/migrations/0011_auto__add_field_formdefinitionfield_choice_model_queryset.py
1
10609
# -*- coding: utf-8 -*- import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Adding field 'FormDefinitionField.choice_model_queryset' db.add_column(u'form_designer_formdefinitionfield...
bsd-3-clause
-4,493,967,210,291,561,500
81.248062
187
0.557923
false
3.62453
false
false
false
swharden/SWHLab
doc/uses/EPSCs-and-IPSCs/variance method/2016-12-16 tryout.py
1
3941
""" This script investigates how calculating phasic currents from voltage clamp recordings may benefit from subtracting-out the "noise" determined from a subset of the quietest pieces of the recording, rather than using smoothing or curve fitting to guess a guassian-like RMS noise function. """ import os import swhla...
mit
2,619,447,392,169,634,000
36.903846
85
0.698046
false
3.160385
false
false
false
gaasedelen/lighthouse
plugins/lighthouse/ui/coverage_settings.py
1
4506
import logging from lighthouse.util.qt import * from lighthouse.util.disassembler import disassembler logger = logging.getLogger("Lighthouse.UI.Settings") class TableSettingsMenu(QtWidgets.QMenu): """ A quick-access settings menu for Lighthouse. """ def __init__(self, parent=None): super(Tab...
mit
-7,577,214,251,421,822,000
41.509434
104
0.60253
false
4.461386
false
false
false
fatiherikli/komposto.org
sketches/views.py
1
5951
# -*- coding: utf-8 -*- from __future__ import unicode_literals import os import json import markdown import base64 from uuid import uuid4 from PIL import Image from django.shortcuts import render, get_object_or_404 from django.views.decorators.csrf import csrf_exempt from django.views.generic.list import ListView fr...
mit
-3,792,996,439,892,349,400
28.315271
74
0.625945
false
3.956782
false
false
false
dhuang/incubator-airflow
airflow/operators/jdbc_operator.py
1
1847
# -*- coding: utf-8 -*- # # 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 ...
apache-2.0
-3,436,255,019,614,622,700
34.519231
76
0.682729
false
3.921444
false
false
false
moriyoshi/payjp-python
payjp/error.py
1
1415
# coding: utf-8 class PayjpException(Exception): def __init__(self, message=None, http_body=None, http_status=None, json_body=None): super(PayjpException, self).__init__(message) if http_body and hasattr(http_body, 'decode'): try: http_body = http_body...
mit
-915,718,673,730,715,300
25.698113
74
0.587279
false
4.019886
false
false
false
wfpinedar/fpm_data_cube
src/installer/dc_tasks.py
1
62143
# -*- coding: utf-8 -*- """ Created on Wed Jun 24 14:01:33 2015 @author: jdh Tile task system for celery """ from datacube.api.query import SortType from matplotlib.mlab import PCA from datetime import datetime,timedelta import logging import os from osgeo import gdal import osr #agregado para exportar el archivo de ...
agpl-3.0
1,160,426,004,678,091,800
35.57681
182
0.593422
false
3.220011
false
false
false
vaginessa/inception
inception/argparsers/makers/submakers/submaker_property.py
1
1852
from .submaker import Submaker import collections import os class PropertySubmaker(Submaker): def make(self, workDir): props = self.getValue(".", {}) if "__make__" in props: del props["__make__"] if "__depend__" in props: del props["__depend__"] propsFlat =...
gpl-3.0
-1,622,258,097,428,729,000
30.931034
114
0.49568
false
4.008658
false
false
false
vmware/pyvmomi-community-samples
samples/sessions_list.py
1
2110
#!/usr/bin/env python # VMware vSphere Python SDK # Copyright (c) 2008-2021 VMware, 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/lic...
apache-2.0
6,791,903,590,379,356,000
36.017544
77
0.746919
false
3.296875
false
false
false
tallypokemap/PokeAlarm
PokeAlarm/Discord/DiscordAlarm.py
1
8686
# Standard Library Imports import logging import requests # 3rd Party Imports # Local Imports from ..Alarm import Alarm from ..Utils import parse_boolean, get_static_map_url, reject_leftover_parameters, require_and_remove_key log = logging.getLogger('Discord') try_sending = Alarm.try_sending replace = Alarm.replace #...
agpl-3.0
-7,167,528,100,492,597,000
46.206522
124
0.575869
false
3.87941
false
false
false
pfsmorigo/minecraft
overviewer_config.py
1
12108
#!/bin/python world_name = 'SmoWorld' worlds[world_name] = '/home/pfsmorigo/.minecraft/saves/'+world_name outputdir = '/mnt/disk/beirut/minecraft/overviewer/'+world_name rendermode = "smooth_lighting" MC_IDS = { 0: "air", 1: "stone", 2: "grass", 3: "dirt", 4: "cobblestone", 5: "planks", 6...
gpl-2.0
-4,839,259,828,219,592,000
23.811475
122
0.537248
false
2.793724
false
false
false
richbrowne/f5-openstack-agent
f5_openstack_agent/lbaasv2/drivers/bigip/vlan_binding.py
1
6094
# coding=utf-8 # Copyright 2014-2016 F5 Networks Inc. # # 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,098,282,063,651,757,000
42.528571
79
0.541516
false
4.844197
false
false
false
xArm-Developer/xArm-Python-SDK
example/wrapper/common/3002-record_trajectory.py
1
1366
#!/usr/bin/env python3 # Software License Agreement (BSD License) # # Copyright (c) 2019, UFACTORY, Inc. # All rights reserved. # # Author: Vinman <vinman.wen@ufactory.cc> <vinman.cub@gmail.com> """ Description: Record trajectory 1. requires firmware 1.2.0 and above support """ import os import sys import time s...
bsd-3-clause
-4,354,373,712,127,189,500
20.015385
68
0.60981
false
3.291566
false
false
false
dladd/pyFormex
pyformex/examples/TrussFrame.py
1
2483
# $Id$ ## ## This file is part of pyFormex 0.8.9 (Fri Nov 9 10:49:51 CET 2012) ## pyFormex is a tool for generating, manipulating and transforming 3D ## geometrical models by sequences of mathematical operations. ## Home page: http://pyformex.org ## Project page: http://savannah.nongnu.org/projects/pyformex/ ##...
gpl-3.0
-147,417,965,538,401,250
32.106667
89
0.631091
false
2.707743
false
false
false
BigEgg/LeetCode
Python/LeetCode/_051_100/_068_TextJustification.py
1
1097
class Solution: def fullJustify(self, words: [str], maxWidth: int) -> [str]: result = [] start_index, current_length = 0, 0 for i in range(len(words)): if current_length + len(words[i]) > maxWidth: space = maxWidth - current_length + (i - start_index) ...
mit
-1,006,641,651,837,325,300
35.566667
176
0.483136
false
3.756849
false
false
false
ehuelsmann/openipam
openIPAM/openipam/web/access.py
1
3170
import cherrypy from basepage import BasePage import framework from openipam.web.resource.submenu import submenu from openipam.config import frontend perms = frontend.perms class Access(BasePage): '''The access class. This includes all pages that are /access/*''' def __init__(self): BasePage.__init__(self) ...
gpl-3.0
1,357,530,256,039,712,000
24.15873
100
0.529022
false
3.573844
false
false
false
vtsuperdarn/davitpy
davitpy/pydarn/sdio/radDataRead.py
1
13124
# Copyright (C) 2012 VT SuperDARN Lab # Full license can be found in LICENSE.txt # # 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 la...
gpl-3.0
7,147,466,849,340,686,000
37.262391
80
0.639973
false
3.710489
false
false
false
mnr/rubberfish
unneeded_stuff/countSyllables.py
1
1467
def count_syllables(word): # thanks to https://github.com/akkana verbose = False #print debugging? vowels = ['a', 'e', 'i', 'o', 'u'] on_vowel = False in_diphthong = False minsyl = 0 maxsyl = 0 lastchar = None word = word.lower() for c in word: is_vowel = c in vowels ...
mit
3,068,843,860,149,435,000
27.764706
75
0.503749
false
3.6133
false
false
false
mcoughli/root_of_trust
operational_os/plot_data.py
1
4710
#!/usr/bin/python import pylab import matplotlib matplotlib.rcParams['pdf.fonttype'] = 42 matplotlib.rcParams['ps.fonttype'] = 42 import numpy import csv import os import sys # TIMESTAMPS = ["2017-03-30T06:35:54.726002", "2017-03-30T09:45:20.551204"] TIMESTAMPS = ["2017-04-02T03:35:32.431002"] # TIMESTAMP_LABELS = {...
gpl-3.0
8,308,318,929,500,350,000
40.681416
144
0.608068
false
3.45815
false
false
false
adafruit/Adafruit_Python_BluefruitLE
setup.py
1
1037
from setuptools import setup, find_packages import platform platform_install_requires = [] if platform.system() == 'Darwin': platform_install_requires += ['pyobjc-framework-CoreBluetooth'] # To use a consistent encoding from codecs import open from os import path here = path.abspath(path.dirname(__file__)) # G...
mit
-1,287,049,547,496,601,900
36.035714
125
0.642237
false
3.716846
false
false
false
silenteddie/Landsat8LST_SWA
modis_water_vapor_interface.py
1
5279
# coding=utf-8 from PyQt4.QtGui import QApplication import modis_extent_generator from qgis.core import * import l8_lst_swa_common_lib import processing import datetime from urllib2 import urlopen from ftplib import FTP import shutil from PyQt4.QtCore import QUrl from PyQt4.QtNetwork import QNetworkAccessManager, QNet...
gpl-2.0
4,448,369,078,451,487,000
36.707143
174
0.684599
false
3.817064
false
false
false
dwagon/pymoo
moo/moo/settings.py
1
2358
""" Django settings for moo project. For more information on this file, see https://docs.djangoproject.com/en/1.7/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/1.7/ref/settings/ """ # Build paths inside the project like this: os.path.join(BASE_DIR, ...) import...
gpl-2.0
-6,647,317,063,238,338,000
22.58
71
0.704411
false
3.243466
false
false
false
D-Vaillant/julius
setup.py
1
5140
""" setup.py: Real simple utility. No "install to command line" option, because nobody has requested one. """ from typing import Union from io import TextIOBase import string import argparse import julius # Some utilities. num_to_word = {'1': 'one', '2': 'two', '3': 'three', '4': 'four', '5': 'five'...
gpl-3.0
-5,746,411,298,161,874,000
31.948718
80
0.560506
false
4.04406
false
false
false
pmeier82/BOTMpy
botmpy/common/spike_alignment.py
1
7458
# -*- coding: utf-8 -*- #_____________________________________________________________________________ # # Copyright (c) 2012 Berlin Institute of Technology # All rights reserved. # # Developed by: Philipp Meier <pmeier82@gmail.com> # Neural Information Processing Group (NI) # School for Ele...
mit
-8,748,461,185,882,833,000
35.028986
90
0.61786
false
3.634503
false
false
false
ryansturmer/cuttlebug
cuttlebug/ui/views/runtime_view.py
1
29660
import view import wx import wx.gizmos as gizmos from cuttlebug.ui.controls import DictListCtrl from cuttlebug.util import ArtListMixin, has_icon, bidict, KeyTree, str2int from functools import partial import cuttlebug.gdb as gdb import os, threading import cuttlebug.ui.menu as menu import cuttlebug.settings a...
mit
3,711,950,667,816,855,000
41.050798
199
0.54973
false
3.742587
false
false
false
caveatemptors-2015/special-garbanzo
project/portfolioX/migrations/0001_initial.py
1
2621
# -*- coding: utf-8 -*- # Generated by Django 1.9.1 on 2016-01-09 23:49 from __future__ import unicode_literals from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ migration...
mit
-8,121,466,650,044,240,000
39.953125
121
0.581457
false
4.296721
false
false
false
polyaxon/polyaxon
platform/coredb/tests/test_create_e2e/test_create_jobs_e2e.py
1
3730
#!/usr/bin/python # # Copyright 2018-2021 Polyaxon, Inc. # # 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 ...
apache-2.0
-2,776,431,568,413,844,500
42.882353
88
0.694102
false
4.023732
true
false
false
ohsu-qin/qipipe
qipipe/helpers/logging.py
1
5667
# Absolute import (the default in a future Python release) resolves # the logging import as the Python standard logging module rather # than this module of the same name. from __future__ import absolute_import import os import sys from datetime import datetime import logging import qiutil NIPYPE_LOG_DIR_ENV_VAR = 'NIP...
bsd-2-clause
5,169,502,066,354,706,000
32.934132
73
0.627845
false
3.839431
true
false
false
briend/mypaint
lib/palette.py
1
31230
# This file is part of MyPaint. # Copyright (C) 2013-2018 by the MyPaint Development Team # # 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 2 of the License, or # (at your option)...
gpl-2.0
846,482,513,551,410,600
33.093886
91
0.535767
false
4.138616
false
false
false
enriquepablo/terms.server
setup.py
1
2240
# Copyright (c) 2007-2012 by Enrique Pérez Arnaud <enriquepablo@gmail.com> # # This file is part of the terms project. # https://github.com/enriquepablo/terms # # The terms project 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 S...
gpl-3.0
3,798,885,400,614,978,000
31.434783
75
0.60992
false
3.475155
false
false
false
dames57/multimarkdown_reader
mmd_reader.py
1
1283
import subprocess from pelican import signals from pelican.readers import BaseReader from pelican.utils import pelican_open class MmdReader(BaseReader): enabled = True file_extensions = ['md', 'markdown', 'mkd', 'mdown'] def read(self, filename): with pelican_open(filename) as fp: text...
agpl-3.0
-7,180,659,168,199,426,000
29.547619
77
0.56742
false
4.073016
false
false
false
beproud/bpcommons
beproud/django/commons/templatetags/compat.py
1
5776
import string import re import json import six from django.utils.encoding import force_text from django.core.serializers.json import DjangoJSONEncoder try: from django.utils.functional import keep_lazy # Django-1.8 doesn't have it. except ImportError: # allow_lazy has been deprecated at Django-1.10, will be r...
bsd-2-clause
-7,532,070,724,396,816,000
31.557576
537
0.609643
false
2.446266
false
false
false
maartenbreddels/vaex
packages/vaex-ui/vaex/ui/plugin/dispersions.py
1
11670
__author__ = 'maartenbreddels' import functools import matplotlib.patches as patches import numpy as np import matplotlib.artist as artist import vaex.ui.plugin from vaex.ui.qt import * import logging logger = logging.getLogger("plugin.dispersions") import matplotlib.transforms as transforms from matplotlib.path...
mit
1,899,751,465,761,447,200
38.0301
180
0.68329
false
3.020968
false
false
false
marionleborgne/nupic
tests/swarming/nupic/swarming/experiments/dummyV2/description.py
1
15299
# ---------------------------------------------------------------------- # Numenta Platform for Intelligent Computing (NuPIC) # Copyright (C) 2013, Numenta, Inc. Unless you have an agreement # with Numenta, Inc., for a separate license for this software code, the # following terms and conditions apply: # # This progra...
agpl-3.0
8,030,776,921,436,739,000
37.928753
110
0.589973
false
4.550565
true
false
false
aleosd/sfpy
client/gamedata.py
1
14314
# -*- coding: UTF-8 -*- import datetime import logging from .settings import LOGGER_NAME from .gameapi import APIManager class Resources: def __init__(self): self.wallet = {} def add(self, data): self.wallet = data.get('wallet', {}) def is_enough_for_mission(self, mission): for ...
mit
4,507,464,201,464,738,000
33.430412
80
0.601916
false
3.247994
false
false
false
UManPychron/pychron
pychron/dvc/tasks/actions.py
1
7897
# =============================================================================== # Copyright 2015 Jake Ross # # 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...
apache-2.0
155,290,666,617,389,280
29.141221
109
0.629859
false
3.998481
false
false
false
thombashi/DataProperty
dataproperty/_container.py
1
3704
""" .. codeauthor:: Tsuyoshi Hombashi <tsuyoshi.hombashi@gmail.com> """ import abc from typepy import RealNumber class AbstractContainer(metaclass=abc.ABCMeta): @abc.abstractproperty def min_value(self): # pragma: no cover pass @abc.abstractproperty def max_value(self): # pragma: no cover...
mit
-3,326,360,890,995,376,000
23.368421
92
0.560475
false
3.862357
false
false
false
CodyKochmann/generators
generators/inline_tools.py
1
2039
#!/usr/bin/env python from __future__ import print_function _print = print del print_function from inspect import getsource from strict_functions import strict_globals, noglobals __all__ = 'asserts', 'print', 'attempt' @strict_globals(getsource=getsource) def asserts(input_value, rule, message=''): """ this fu...
mit
-1,161,471,738,659,893,500
30.859375
111
0.659637
false
3.782931
false
false
false
njoubert/ardupilot
Tools/ardupilotwaf/px4.py
1
11068
#!/usr/bin/env python # encoding: utf-8 """ Waf tool for PX4 build """ from waflib import Errors, Logs, Task, Utils from waflib.TaskGen import after_method, before_method, feature import os import shutil import sys _dynamic_env_data = {} def _load_dynamic_env_data(bld): bldnode = bld.bldnode.make_node('modules/...
gpl-3.0
-3,635,688,299,489,346,600
31.84273
133
0.615287
false
3.007609
false
false
false
nicproulx/mne-python
mne/simulation/evoked.py
2
5502
# Authors: Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr> # Daniel Strohmeier <daniel.strohmeier@tu-ilmenau.de> # Martin Luessi <mluessi@nmr.mgh.harvard.edu> # # License: BSD (3-clause) import copy import warnings import numpy as np from ..io.pick import pick_channels_cov from ..forwar...
bsd-3-clause
-6,964,635,638,887,342,000
32.345455
77
0.613413
false
3.690141
false
false
false
okrt/horspool-string-matching
main.py
1
7710
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'main.ui' # # Created: Wed Apr 08 10:31:45 2015 # by: PyQt4 UI code generator 4.11.3 # # WARNING! All changes made in this file will be lost! from PyQt4 import QtCore, QtGui try: _fromUtf8 = QtCore.QString.fromUtf8 except Attribute...
gpl-2.0
-656,853,989,499,909,800
55.226277
163
0.704401
false
3.520567
false
false
false
repotvsupertuga/tvsupertuga.repository
script.module.streamtvsupertuga/lib/resources/lib/sources/it/ddown.py
1
2923
import re import requests import xbmc,xbmcaddon,time import urllib from ..common import get_rd_domains, filter_host,send_log,error_log from ..scraper import Scraper dev_log = xbmcaddon.Addon('script.module.universalscrapers').getSetting("dev_log") s = requests.session() User_Agent = 'Mozilla/5.0 (Windows NT 6.1; WOW6...
gpl-2.0
-5,524,192,560,469,390,000
36.974026
271
0.509408
false
3.649189
false
false
false
R2pChyou/starcheat
starcheat/assets/techs.py
1
1741
import os import logging from io import BytesIO from PIL import Image class Techs(): def __init__(self, assets): self.assets = assets self.starbound_folder = assets.starbound_folder def is_tech(self, key): return key.endswith(".tech") def index_data(self, asset): key = a...
mit
2,986,662,716,974,814,000
30.089286
89
0.563469
false
3.597107
false
false
false
h-hwang/octodns
tests/helpers.py
1
1328
# # # from __future__ import absolute_import, division, print_function, \ unicode_literals from shutil import rmtree from tempfile import mkdtemp class SimpleSource(object): def __init__(self, id='test'): pass class SimpleProvider(object): SUPPORTS_GEO = False SUPPORTS = set(('A',)) ...
mit
-6,261,348,014,156,640,000
17.971429
67
0.593373
false
3.905882
false
false
false
jonasjberg/autonameow
autonameow/util/text/regexbatch.py
1
3842
# -*- coding: utf-8 -*- # Copyright(c) 2016-2020 Jonas Sjöberg <autonameow@jonasjberg.com> # Source repository: https://github.com/jonasjberg/autonameow # # This file is part of autonameow. # # autonameow is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public L...
gpl-2.0
-8,631,422,745,035,632,000
30.227642
79
0.659984
false
4.134553
false
false
false
gios-asu/text-geolocator
docs/source/conf.py
1
9841
# -*- coding: utf-8 -*- # # Text-Geolocator documentation build configuration file, created by # sphinx-quickstart on Mon Mar 2 18:40:28 2015. # # 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 fil...
mit
-798,293,896,022,486,400
32.13468
79
0.700335
false
3.665177
true
false
false
wsmith323/frozenordereddict
frozenordereddict/__init__.py
1
1193
from collections import Mapping try: reduce except NameError: from functools import reduce try: from collections import OrderedDict except ImportError: from ordereddict import OrderedDict import operator import os with open(os.path.join(os.path.dirname(__file__), 'VERSION.txt')) as f: __version...
mit
-6,693,519,827,597,702,000
21.092593
81
0.582565
false
3.911475
false
false
false
opinkerfi/okconfig
tests/test_group.py
1
1924
# !/usr/bin/env python """Test adding objects""" from __future__ import absolute_import import os.path import sys # Make sure we import from working tree okconfig_base = os.path.dirname(os.path.realpath(__file__ + "/..")) sys.path.insert(0, okconfig_base) import unittest2 as unittest import okconfig from pynag impo...
gpl-3.0
6,050,673,122,055,601,000
26.5
69
0.608628
false
3.93456
true
false
false
TaliesinSkye/evennia
wintersoasis-master/objects/examples/object.py
1
7393
""" Template for Objects Copy this module up one level and name it as you like, then use it as a template to create your own Objects. To make the default commands default to creating objects of your new type (and also change the "fallback" object used when typeclass creation fails), change settings.BASE_OBJECT_TYPEC...
bsd-3-clause
5,246,995,477,435,459,000
59.105691
144
0.714324
false
4.114079
false
false
false
dennishuo/dataproc-initialization-actions
kafka/test_kafka.py
1
1443
import os import unittest from parameterized import parameterized from integration_tests.dataproc_test_case import DataprocTestCase class KafkaTestCase(DataprocTestCase): COMPONENT = 'kafka' INIT_ACTIONS = ['kafka/kafka.sh'] TEST_SCRIPT_FILE_NAME = 'validate.sh' def verify_instance(self, name): ...
apache-2.0
4,321,424,766,428,474,400
33.357143
76
0.568954
false
3.858289
true
false
false
rafaelvieiras/PseudoTV_Live
plugin.video.pseudotv.live/resources/lib/parsers/MKVParser.py
1
5919
# Copyright (C) 2020 Jason Anderson, Lunatixz # # # This file is part of PseudoTV Live. # # PseudoTV Live 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...
gpl-3.0
41,527,159,163,878,820
27.320574
96
0.497043
false
4.18896
false
false
false
koreyou/word_embedding_loader
setup.py
1
3965
import os from setuptools import setup from setuptools.extension import Extension from setuptools.command.sdist import sdist as _sdist cython_modules = [ ["word_embedding_loader", "loader", "word2vec_bin"], ["word_embedding_loader", "saver", "word2vec_bin"] ] def _cythonize(extensions, apply_cythonize): ...
mit
8,672,868,639,906,950,000
28.589552
84
0.590668
false
3.92186
false
false
false
umeboshi2/vignewton
vignewton/views/admin/sitetext.py
1
7950
from cStringIO import StringIO from datetime import datetime import transaction from pyramid.httpexceptions import HTTPFound, HTTPNotFound from pyramid.security import authenticated_userid from pyramid.renderers import render from pyramid.response import Response from trumpet.models.sitecontent import SiteText fro...
unlicense
-3,346,914,358,330,187,300
33.415584
76
0.588176
false
3.861098
false
false
false
silly-wacky-3-town-toon/SOURCE-COD
toontown/golf/GolfRewardDialog.py
1
13295
from panda3d.core import * from panda3d.direct import * from toontown.toonbase.ToonBaseGlobal import * from direct.interval.IntervalGlobal import * from direct.task import Task from direct.directnotify import DirectNotifyGlobal from math import * from direct.distributed.ClockDelta import * from toontown.golf import Gol...
apache-2.0
1,307,104,951,644,556,000
48.059041
225
0.581271
false
3.73665
false
false
false
openstack/oslo.vmware
oslo_vmware/service.py
1
18788
# Copyright (c) 2014-2020 VMware, 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 req...
apache-2.0
6,293,512,933,116,968,000
37.818182
79
0.568288
false
4.54585
false
false
false
dbiesecke/dbiesecke.github.io
repo/script.module.urlresolver/lib/urlresolver/lib/kodi.py
1
9725
""" URLResolver Addon for Kodi Copyright (C) 2016 t0mm0, tknorris 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 late...
mit
-4,834,126,515,700,619,000
30.070288
139
0.601028
false
3.792902
false
false
false
lcy-seso/models
fluid/face_detection/widerface_eval.py
1
11459
import os import time import numpy as np import argparse import functools from PIL import Image import paddle.fluid as fluid import reader from pyramidbox import PyramidBox from visualize import draw_bboxes from utility import add_arguments, print_arguments parser = argparse.ArgumentParser(description=__doc__) add_arg...
apache-2.0
9,215,710,945,514,166,000
35.964516
116
0.53242
false
3.167219
true
false
false
lukipuki/obnam
obnamlib/bag_store.py
1
3767
# Copyright 2015 Lars Wirzenius # # 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 program is distributed in th...
gpl-3.0
-8,144,014,369,732,960,000
27.976923
71
0.606849
false
3.510718
false
false
false
noba3/KoTos
addons/plugin.video.movie25/resources/libs/plugins/tvrelease.py
1
14043
import urllib, urllib2,re,string,sys,os import xbmc, xbmcgui, xbmcaddon, xbmcplugin from resources.libs import main from t0mm0.common.addon import Addon addon_id = 'plugin.video.movie25' selfAddon = xbmcaddon.Addon(id=addon_id) addon = Addon(addon_id, sys.argv) art = main.art error_logo = art+'/bigx.png' BASEURL...
gpl-2.0
-4,429,823,489,364,764,700
47.760417
324
0.552304
false
3.22161
false
false
false
QuantCrimAtLeeds/PredictCode
open_cp/prohotspot.py
1
11749
""" prohotspot ~~~~~~~~~~ Implements the "prospective hotspotting" technique from: 1. Bowers, Johnson, Pease, "Prospective hot-spotting: The future of crime mapping?", Brit. J. Criminol. (2004) 44 641--658. doi:10.1093/bjc/azh036 2. Johnson et al., "Prospective crime mapping in operational context", Home...
artistic-2.0
-8,806,066,455,696,376,000
41.568841
97
0.643204
false
3.770539
false
false
false
zionist/landing
landing/apps/core/migrations/0001_initial.py
1
2095
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations from django.conf import settings class Migration(migrations.Migration): dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ] operations = [ migrations.Create...
gpl-3.0
-2,710,787,936,435,316,700
41.755102
114
0.570883
false
4.419831
false
false
false
tbpmig/mig-website
corporate/views.py
1
17269
from django.core.urlresolvers import reverse from django.forms.models import modelformset_factory, modelform_factory from django.http import HttpResponse from django.shortcuts import redirect from django.template import loader from django_ajax.decorators import ajax from corporate.auxiliary_scripts import update_resume...
apache-2.0
-8,681,007,862,481,104,000
43.622739
128
0.642423
false
3.976284
false
false
false
Spiderlover/Toontown
toontown/battle/MovieDrop.py
1
17995
from direct.interval.IntervalGlobal import * from BattleBase import * from BattleProps import * from BattleSounds import * import MovieCamera from direct.directnotify import DirectNotifyGlobal import MovieUtil import MovieNPCSOS from MovieUtil import calcAvgSuitPos from direct.showutil import Effects notify = DirectNot...
mit
155,016,294,914,021,400
40.367816
350
0.62973
false
3.357276
false
false
false
bhaveshAn/crisscross
crisscross/__init__.py
1
3025
''' Crisscross ========== ''' __all__ = ('accelerometer', 'audio', 'barometer', 'battery', 'call', 'camera', 'compass', 'email', 'filechooser', 'flash', 'gps', 'gravity', 'gyroscope', 'irblaster', 'light', 'orientation', 'notification', 'proximity', 'sms', 'tts', 'uniqueid', 'vibrator...
mit
587,959,898,850,672,500
31.880435
78
0.727603
false
2.853774
false
false
false
Jozhogg/iris
lib/iris/fileformats/netcdf.py
1
69253
# (C) British Crown Copyright 2010 - 2015, Met Office # # This file is part of Iris. # # Iris 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 l...
lgpl-3.0
-8,139,096,805,184,263,000
37.797199
79
0.569073
false
4.284928
false
false
false
winking324/ngxtop_rtmp_hls
ngxtop/rtmptop.py
1
9398
""" Nginx-rtmp-module stat parser. Need to install nginx-rtmp-module first. """ import xml.dom.minidom import urllib2 if __package__ is None: from utils import error_exit else: from .utils import error_exit STAT_URL = "http://127.0.0.1:8080/stat" def pass_for_node_value(root, node_name): child = root....
mit
-818,754,363,569,974,100
38.991489
120
0.60183
false
3.485905
false
false
false
srgblnch/Rijndael
Testing/_FIPS197_AES192.py
1
9943
# ##### BEGIN GPL LICENSE BLOCK ##### # # 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 program is distrib...
gpl-3.0
6,142,322,919,003,080,000
43.788288
78
0.708941
false
2.141965
false
false
false
assencess/myshop
shop/views.py
1
2754
from django.shortcuts import render, get_object_or_404 from .models import Category, Product from .forms import EmailContactForm from cart.forms import CartAddProductForm from django.core.mail import send_mail from django.views import View from django.views.generic import DetailView, ListView class ProductListView(Lis...
gpl-3.0
-1,827,950,606,063,933,700
35.72
75
0.617284
false
4.230415
false
false
false
rmariano/dotfiles
git-hooks/branch_ticket_name.py
1
2784
#!/usr/bin/python3 """ From: https://git-scm.com/book/en/v2/Customizing-Git-Git-Hooks The commit-msg hook takes one parameter, which again is the path to a temporary file that contains the commit message written by the developer. If this script exits non-zero, Git aborts the commit process, so you can use it to valid...
mit
-6,879,392,724,612,010,000
26.564356
79
0.651221
false
3.746972
false
false
false
google-research/google-research
cfq/evaluate_main.py
1
2144
# coding=utf-8 # Copyright 2021 The Google Research 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 applicab...
apache-2.0
6,893,265,948,132,583,000
35.965517
79
0.680037
false
4.138996
false
false
false
jiwanlimbu/aura
keystone/token/persistence/backends/sql.py
1
12737
# Copyright 2012 OpenStack Foundation # # 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...
apache-2.0
6,549,671,619,302,245,000
40.488599
79
0.593546
false
4.154273
false
false
false
mattclark/osf.io
tests/test_webtests.py
1
50803
#!/usr/bin/env python # -*- coding: utf-8 -*- """Functional tests using WebTest.""" import datetime as dt import httplib as http import logging import unittest import markupsafe import mock import pytest from nose.tools import * # noqa: F403 import re from django.utils import timezone from addons.wiki.utils import t...
apache-2.0
6,935,636,752,297,277,000
38.716185
188
0.637931
false
3.671895
true
false
false
phalt/dj-twiml
tests/test_views.py
1
1400
#!/usr/bin/env python # -*- coding: utf-8 -*- """ test_dj-twiml-views ------------ Tests for `dj-twiml-views` views module. """ from hmac import new from hashlib import sha1 from base64 import encodestring from django.test import Client, TestCase, RequestFactory from django.conf import settings from dj_twiml imp...
bsd-3-clause
2,297,203,071,420,323,000
24.925926
64
0.628571
false
3.317536
true
false
false
klmitch/keystone
keystone/trust/controllers.py
1
11243
# Copyright 2013 OpenStack Foundation # # 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 ...
apache-2.0
7,273,288,418,649,957,000
40.640741
78
0.579383
false
3.999644
false
false
false