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
mdavidsaver/pyDevSup
archApp/bplreport.py
1
4059
# -*- coding: utf-8 -*- import time, sched, urllib2, json from devsup.db import IOScanListBlock from devsup.hooks import initHook from devsup.util import StoppableThread class BPLReport(object): reports = {} def __init__(self, name, url, period): self.name = name self.url, self.period = url, ...
gpl-2.0
2,099,237,936,138,473,700
25.880795
82
0.539295
false
3.786381
false
false
false
Konubinix/weboob
modules/boursorama/pages/accounts_list.py
1
4273
# -*- coding: utf-8 -*- # Copyright(C) 2011 Gabriel Kerneis # Copyright(C) 2010-2011 Jocelyn Jaubert # # This file is part of weboob. # # weboob 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, eit...
agpl-3.0
8,497,556,090,955,697,000
42.161616
103
0.478352
false
4.877854
false
false
false
escattone/kuma
kuma/core/utils.py
1
8709
import logging import os from smtplib import SMTPConnectError, SMTPServerDisconnected from urllib.parse import parse_qsl, ParseResult, urlparse, urlsplit, urlunsplit import requests from django.conf import settings from django.core.mail import EmailMultiAlternatives, get_connection from django.http import QueryDict fr...
mpl-2.0
-7,837,640,281,456,378,000
32.114068
103
0.663452
false
3.900134
false
false
false
cycladesnz/chambersAndCreatures
src/effects/av_effects.py
1
3684
from pdcglobal import * from .effect import Effect from .dv_effects import DazzleEffect class StunEffect(Effect): def __init__(self, host, owner): dur = d(3) Effect.__init__(self, dur, host, owner) weaponinfotext = 'Stuns the enemy' def tick(self): self.host.timer += se...
gpl-2.0
3,554,105,722,189,327,400
33.754717
85
0.551031
false
3.225919
false
false
false
jusjusjus/Motiftoolbox
Leech_3-cell/network.py
1
1647
#!/usr/bin/env python import time import sys sys.path.insert(0, '../Tools') import network3N as netw import tools as tl import numpy as np class network(netw.network): title = "Neural Network Motif" def __init__(self, g_inh=0.01, info=None, position=None): netw.network.__init__(self, g_inh, info, position...
gpl-2.0
-6,949,641,564,638,452,000
19.085366
89
0.657559
false
2.529954
false
false
false
pcolmant/repanier
repanier_v2/models/notification.py
1
2466
from django.db import models from django.utils.html import escape, format_html from django.utils.safestring import mark_safe from django.utils.translation import ugettext_lazy as _ from djangocms_text_ckeditor.fields import HTMLField from repanier_v2.const import * from repanier_v2.tools import cap class Notificatio...
gpl-3.0
-5,168,390,665,867,534,000
34.228571
106
0.452555
false
4.912351
false
false
false
kbase/genome_annotation_api
lib/GenomeAnnotationAPI/utils.py
1
6580
import logging from collections import Counter class Utils: def __init__(self, workspace_client): self.ws = workspace_client @staticmethod def validate_params(params, expected, opt_param=set()): """Validates that required parameters are present. Warns if unexpected parameters appear""" ...
mit
-594,657,575,675,096,000
44.694444
99
0.539666
false
3.859238
false
false
false
lmazuel/azure-sdk-for-python
azure-mgmt-compute/azure/mgmt/compute/v2016_04_30_preview/models/virtual_machine.py
1
7652
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. # # Code generated by Microsoft (R) AutoRest Code Generator. # Changes ...
mit
-6,652,145,812,120,035,000
51.054422
170
0.674726
false
4.081067
false
false
false
sjkingo/fantail
fantail/cli.py
1
2628
""" Command-line interface to the fantail site generator. setuptools will create a console script pointing to cli:main """ import argparse import logging from fantail.staticsite import StaticSite def cmd_init_site(args): """ Creates a new site with default templates. """ site = StaticSite(args.site_d...
bsd-2-clause
4,335,352,993,930,072,600
31.444444
104
0.644977
false
3.842105
false
false
false
matroid/matroid-python
matroid/src/video_summary.py
1
4766
import requests from matroid import error from matroid.src.helpers import api_call # https://staging.dev.matroid.com/docs/api/index.html#api-Video_Summary-PostSummarize @api_call(error.InvalidQueryError) def create_video_summary(self, url=None, videoId=None, file=None): """Create an video summary with provided url ...
mit
2,356,276,802,457,178,000
35.661538
102
0.722619
false
3.706065
false
false
false
kennedyshead/home-assistant
homeassistant/components/analytics/const.py
1
1442
"""Constants for the analytics integration.""" from datetime import timedelta import logging import voluptuous as vol ANALYTICS_ENDPOINT_URL = "https://analytics-api.home-assistant.io/v1" ANALYTICS_ENDPOINT_URL_DEV = "https://analytics-api-dev.home-assistant.io/v1" DOMAIN = "analytics" INTERVAL = timedelta(days=1) ST...
apache-2.0
-1,498,860,972,275,028,000
26.730769
77
0.730929
false
3.016736
false
false
false
drayanaindra/monit-isp
monit_my_isp.py
1
1933
import os import re import smtplib from email.MIMEMultipart import MIMEMultipart from email.MIMEText import MIMEText from email.MIMEBase import MIMEBase from email import encoders # set your directory for log or anything when you wanna say fuck SET_DIR = os.path.dirname(os.path.abspath(' ')) NAME_FILE = 'log-myisp.txt...
gpl-3.0
-6,799,284,218,235,311,000
28.287879
93
0.700466
false
3.102729
false
false
false
C2SM/hymet_idealized
runsims_user.py
1
1464
# 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 distributed in the hope that it will be useful...
lgpl-3.0
-2,831,505,908,376,665,600
33.857143
77
0.696721
false
3.744246
false
false
false
aequitas/home-assistant
homeassistant/components/locative/device_tracker.py
1
2692
"""Support for the Locative platform.""" import logging from homeassistant.core import callback from homeassistant.components.device_tracker import SOURCE_TYPE_GPS from homeassistant.components.device_tracker.config_entry import ( DeviceTrackerEntity ) from homeassistant.helpers.dispatcher import async_dispatcher_...
apache-2.0
2,563,296,989,840,998,400
28.911111
76
0.647103
false
4.293461
false
false
false
baifendian/harpc
admin/manage/customdecorators.py
1
1412
# -*- coding: utf-8 -*- """ Copyright (C) 2015 Baifendian Corporation 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
2,894,816,251,340,241,400
25.403846
72
0.680758
false
3.582245
false
false
false
opena11y/fae2
fae2/fae2/context_processors.py
1
2101
""" Copyright 2014-2016 University of Illinois 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 writ...
apache-2.0
8,637,134,552,017,623,000
23.717647
72
0.729177
false
3.537037
false
false
false
lifemapper/LmQGIS
lifemapperTools/tools/ui_listExperimentDialog.py
1
7554
# -*- coding: utf-8 -*- """ @license: gpl2 @copyright: Copyright (C) 2014, University of Kansas Center for Research Lifemapper Project, lifemapper [at] ku [dot] edu, Biodiversity Institute, 1345 Jayhawk Boulevard, Lawrence, Kansas, 66045, USA This program is free software; ...
gpl-2.0
2,559,751,720,454,974,000
41.438202
107
0.658459
false
3.996825
false
false
false
isaacj87/unity
tests/autopilot/autopilot/tests/test_ibus.py
1
7160
# -*- Mode: Python; coding: utf-8; indent-tabs-mode: nil; tab-width: 4 -*- # Copyright 2012 Canonical # Author: Thomi Richards, Martin Mrazik # # 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 Fou...
gpl-3.0
1,277,520,508,238,889,500
34.270936
120
0.639385
false
3.325592
true
false
false
lcy-seso/Paddle
python/paddle/dataset/uci_housing.py
1
3748
# Copyright (c) 2016 PaddlePaddle Authors. 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 applic...
apache-2.0
941,708,143,566,697,000
28.984
91
0.670491
false
3.236615
true
false
false
obdg/plda
testdata/format.py
1
1245
#!/usr/bin/env python import io import sys def parseLine(line): l = line.strip().split() return int(l[0]), int(l[1]), int(l[2]) def convert(dataName, f): with open("docword." + dataName + ".txt", 'r') as doc, open("vocab." + dataName + ".txt", 'r') as voc: vocList = [] for w in voc: ...
apache-2.0
-9,169,616,368,775,824,000
22.942308
106
0.481124
false
3.200514
false
false
false
buzztroll/staccato
staccato/openstack/common/sslutils.py
1
2482
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright 2013 IBM Corp. # # 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 # # ...
apache-2.0
-8,596,725,972,665,908,000
30.025
78
0.617647
false
3.806748
false
false
false
bdang2012/taiga-back-casting
taiga/export_import/tasks.py
1
3191
# Copyright (C) 2014-2015 Andrey Antukh <niwi@niwi.be> # Copyright (C) 2014-2015 Jesús Espino <jespinog@gmail.com> # Copyright (C) 2014-2015 David Barragán <bameda@dbarragan.com> # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as # pub...
agpl-3.0
-436,636,526,584,997,570
32.568421
101
0.67482
false
3.729825
false
false
false
zqfan/leetcode
algorithms/304. Range Sum Query 2D - Immutable/solution.py
1
1184
class NumMatrix(object): def __init__(self, matrix): """ :type matrix: List[List[int]] """ m, n = len(matrix), len(matrix[0] if matrix else []) self._sum = [[0] * n for i in xrange(m)] col_sum = [0] * n for i in xrange(m): s = 0 for j ...
gpl-3.0
-5,383,911,250,569,336,000
28.6
69
0.460304
false
3.157333
false
false
false
dgoodwin/wuja
test/configTests.py
1
5142
# Wuja - Google Calendar (tm) notifications for the GNOME desktop. # # Copyright (C) 2006 Devan Goodwin <dgoodwin@dangerouslyinc.com> # Copyright (C) 2006 James Bowes <jbowes@dangerouslyinc.com> # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Pu...
gpl-2.0
-486,767,916,604,198,300
34.462069
79
0.648969
false
3.543763
true
false
false
Atihinen/ProjectUnchained
project_unchained/project_unchained/settings.py
1
2005
""" Django settings for project_unchained 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_DI...
mit
-2,116,393,972,507,239,200
23.45122
71
0.723691
false
3.218299
false
false
false
googleapis/python-spanner-django
tests/unit/django_spanner/test_compiler.py
1
6961
# Copyright 2021 Google LLC # # Use of this source code is governed by a BSD-style # license that can be found in the LICENSE file or at # https://developers.google.com/open-source/licenses/bsd from django.core.exceptions import EmptyResultSet from django.db.utils import DatabaseError from django_spanner.compiler impo...
bsd-3-clause
754,637,484,480,902,400
39.236994
79
0.596322
false
3.973174
true
false
false
Proactuary/ChessLearner
sunfish.py
1
19713
#!/usr/bin/env pypy # -*- coding: utf-8 -*- from __future__ import print_function import sys import random from itertools import count from collections import Counter, OrderedDict, namedtuple ARG_OUTPUTFILE = 2 GAMES_PLAYED = 10 # The table size is the maximum number of elements in the transposition table. TABLE_SI...
gpl-3.0
-5,456,293,336,961,989,000
37.203488
103
0.505504
false
3.130041
false
false
false
subodhchhabra/glances
glances/globals.py
1
1502
# -*- coding: utf-8 -*- # # This file is part of Glances. # # Copyright (C) 2015 Nicolargo <nicolas@nicolargo.com> # # Glances 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 Lic...
lgpl-3.0
-4,663,706,417,952,134,000
34.761905
77
0.740346
false
3.413636
false
false
false
fusioneng/gif2html5-app
tests/test_server.py
1
4198
import server import unittest import requests from unittest.mock import MagicMock, ANY, patch from flask import json from gif2html5.config_parser import get_config from gif2html5.s3_manager import S3Manager from tests.test_context import TestContext class JsonPayloadAttachmentIdMatcher(object): def __init__(sel...
mit
-7,445,330,195,105,273,000
40.564356
146
0.656503
false
3.323832
true
false
false
pmaxit/DJANGO_IOT
django_iot/settings/common.py
1
5065
""" Django settings for Django for IoT project on Heroku. For more info, see: https://github.com/aschn/cookiecutter-django-iot For more information on this file, see https://docs.djangoproject.com/en/1.9/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/1.9/ref/set...
mit
-8,899,186,612,826,330,000
29.14881
114
0.697137
false
3.433898
false
false
false
our-city-app/oca-backend
src/solutions/common/to/payments.py
1
1721
# -*- coding: utf-8 -*- # Copyright 2020 Green Valley Belgium NV # # 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 appl...
apache-2.0
-8,937,112,238,007,400,000
33.42
89
0.674608
false
4.021028
false
false
false
pity7736/olimpiadas
tasks/mutations.py
1
1169
from graphene import InputObjectType, String, Int, Mutation, Boolean, Field from graphene.types.datetime import DateTime from tasks.models import Task, Category from tasks.schemas import TaskNode, CategoryNode class NameInput(InputObjectType): name = String(required=True) description = String() class Creat...
gpl-3.0
-1,950,752,744,791,763,700
24.413043
75
0.711719
false
4.017182
false
false
false
nfletton/bvspca
bvspca/animals/petpoint.py
1
4840
import datetime import html import io import logging from lxml import etree logger = logging.getLogger('bvspca.animals.petpoint') error_logger = logging.getLogger('bvspca.animals.petpoint.errors') def extract_animal_ids(animal_summary_etree): animal_ids = [] for animal in animal_summary_etree.findall('.//ad...
mit
-7,226,197,578,575,516,000
32.846154
120
0.597727
false
3.793103
false
false
false
tboyce1/home-assistant
homeassistant/components/panel_iframe.py
2
1256
""" Register an iFrame front end panel. For more details about this component, please refer to the documentation at https://home-assistant.io/components/panel_iframe/ """ import asyncio import voluptuous as vol from homeassistant.const import (CONF_ICON, CONF_URL) import homeassistant.helpers.config_validation as cv...
apache-2.0
-8,715,024,929,982,392,000
27.545455
77
0.640924
false
3.64058
false
false
false
yarikoptic/NiPy-OLD
nipy/neurospin/register/realign4d.py
1
10220
from routines import cspline_transform, cspline_sample4d, slice_time from transform import Affine, apply_affine, BRAIN_RADIUS_MM import numpy as np from scipy import optimize DEFAULT_SPEEDUP = 4 DEFAULT_OPTIMIZER = 'powell' DEFAULT_WITHIN_LOOPS = 2 DEFAULT_BETWEEN_LOOPS = 5 def grid_coords(xyz, affine, fro...
bsd-3-clause
-338,591,949,903,743,800
32.074434
110
0.57593
false
3.490437
false
false
false
brene/slide-transition-detector
mediaoutput.py
1
6077
from abc import ABCMeta, abstractmethod import datetime import cv2 import math import os import errno class MediaWriter(object): """ Abstract class for all media outputs. Forcing each inheritance to have a write class. """ __metaclass__ = ABCMeta @abstractmethod def write(self, content, *...
mit
3,480,623,246,772,520,000
30.005102
101
0.61165
false
4.306875
false
false
false
vesellov/bitdust.devel
transport/http/http_node.py
1
13830
#!/usr/bin/python # http_node.py # # # Copyright (C) 2008-2018 Veselin Penev, https://bitdust.io # # This file (http_node.py) is part of BitDust Software. # # BitDust 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...
agpl-3.0
-5,036,903,023,932,048,000
31.088167
132
0.542878
false
3.933447
false
false
false
SteveDiamond/cvxpy
cvxpy/atoms/min.py
2
2912
""" Copyright 2013 Steven Diamond 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...
gpl-3.0
-3,086,104,830,396,706,000
26.733333
78
0.603365
false
3.841689
false
false
false
BlackHole/enigma2-obh10
lib/python/Components/Converter/EventName.py
2
10098
from enigma import eEPGCache from Components.Converter.Converter import Converter from Components.Element import cached from Components.Converter.genre import getGenreStringSub from Components.config import config from Tools.Directories import resolveFilename, SCOPE_CURRENT_SKIN from time import localtime, mktime, str...
gpl-2.0
6,620,502,956,419,688,000
32.326733
174
0.650426
false
2.959555
true
false
false
jtraver/dev
python/graphics/graph3.py
1
1381
#!/usr/bin/python # http://mcsp.wartburg.edu/zelle/python/graphics.py from graphics import * SCALE = 10 def test(): win = GraphWin() win.setCoords(0,0,10,10) t = Text(Point(5,5), "Centered Text") t.draw(win) p = Polygon(Point(1,1), Point(5,3), Point(2,7)) p.draw(win) e = Entry(Point(5,6)...
mit
-1,893,172,085,288,062,700
20.246154
57
0.548878
false
2.68677
false
false
false
daxm/fmcapi
fmcapi/api_objects/object_services/dnsservergroups.py
1
2479
"""DNS Server Groups Class.""" from fmcapi.api_objects.apiclasstemplate import APIClassTemplate import logging class DNSServerGroups(APIClassTemplate): """The DNSServerGroups Object in the FMC.""" VALID_JSON_DATA = [ "id", "name", "type", "retries", "timeout", ...
bsd-3-clause
5,905,963,153,461,864,000
32.958904
88
0.519968
false
4.411032
false
false
false
sigma-random/Win32_Shellcode
C-shellcode/remote_reverse_exploit.py
1
3240
#!/usr/bin/env python from socket import * from struct import * from time import * import sys def L32(val): return pack('<I',val) def ip_value(ip_str): ret = 0x00000000 str_list = ip_str.split('.') for i in xrange(len(str_list)): ret += int(str_list[i])<<(3-i)*8 return ret def exploit(ip,port,data): sockfd = ...
gpl-2.0
4,696,895,885,518,288,000
31.4
104
0.61821
false
1.880441
false
false
false
Whovian9369/OTPKeySplitter
OTPKeySplitter.py
1
15977
#!/usr/bin/env python3 import os, sys, zlib, binascii import codecs from Crypto.Cipher import AES otpbin = os.path.abspath("otp.bin") if not os.path.exists(otpbin): print("Put the otp.bin into this directory, please!") sys.exit(1) keytxt = open('Keys.txt', 'a') #Thank you Audiosurf for the initial directory cr...
mit
-5,033,038,418,475,891,000
29.374525
174
0.646304
false
2.425903
false
false
false
demiangomez/Parallel.GAMIT
stacker/pyNEQStack.py
1
6703
""" Project: Parallel.Stacker Date: 6/12/18 10:28 AM Author: Demian D. Gomez """ import dbConnection import pyOptions import argparse import pyETM import pyJobServer import numpy import pyDate from pyDate import Date from tqdm import tqdm import traceback from pprint import pprint import os import numpy as np from sci...
gpl-3.0
-5,775,745,574,475,761,000
27.52766
123
0.556766
false
3.077594
false
false
false
knz/slcore
slc/tools/slc/mt/mtsparc/asmproc/opc/mtsparc.py
1
38790
# This file was generated by decode.py. Do not edit! # For each instruction the information available is:' # re_parser, input_regs, output_regs, double_regs, long_latency, delayed, extra_phy_inputs, extra_phy_outputs' import re class insn_metadata(object): def __init__(self, info): self.inputs, self.outputs...
gpl-3.0
3,683,968,049,073,578,000
25.209459
183
0.426605
false
2.525062
false
false
false
LavaLabUSC/application-review
review/settings.py
1
2875
import os # Build paths inside the project like this: os.path.join(BASE_DIR, ...) BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) # Quick-start development settings - unsuitable for production # See https://docs.djangoproject.com/en/1.10/howto/deployment/checklist/ # SECURITY WARNING: keep th...
mit
4,462,475,505,393,296,000
24.669643
91
0.678609
false
3.54064
false
false
false
xiang12835/python_web
py2_web2py/web2py/gluon/debug.py
1
5583
#!/usr/bin/env python # -*- coding: utf-8 -*- """ | This file is part of the web2py Web Framework | Developed by Massimo Di Pierro <mdipierro@cs.depaul.edu>, | limodou <limodou@gmail.com> and srackham <srackham@gmail.com>. | License: LGPLv3 (http://www.gnu.org/licenses/lgpl.html) Debugger support classes ------------...
apache-2.0
-3,998,305,188,738,329,600
27.484694
86
0.605409
false
3.749496
false
false
false
ozak/BoundedConsumption
scripts/incomeprocs.py
1
2312
#!/usr/bin/env python # coding: utf-8 ''' ====================================================== Author: Ömer Özak, 2013--2014 (ozak at smu.edu) Website: http://omerozak.com GitHub: https://github.com/ozak/BoundedConsumption ====================================================== # This code Computes statistics for th...
gpl-3.0
-6,109,726,453,913,041,000
33.939394
173
0.588031
false
2.372428
false
false
false
matrix-org/synapse
synapse/crypto/event_signing.py
1
6136
# # Copyright 2014-2016 OpenMarket Ltd # Copyright 2020 The Matrix.org Foundation C.I.C. # # 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 # #...
apache-2.0
-8,759,924,720,279,790,000
32.530055
88
0.679596
false
3.752905
false
false
false
hammerlab/pyensembl
pyensembl/sequence_data.py
1
5420
# 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
-3,712,856,413,055,222,300
38.275362
97
0.621402
false
4.29137
false
false
false
aubreyli/hmmlearn
hmmlearn/base.py
1
23398
from __future__ import print_function import string import sys from collections import deque import numpy as np from scipy.misc import logsumexp from sklearn.base import BaseEstimator, _pprint from sklearn.utils import check_array, check_random_state from sklearn.utils.validation import check_is_fitted from . import...
bsd-3-clause
8,770,974,257,951,624,000
35.163833
79
0.588298
false
4.313791
false
false
false
wxwilcke/pakbon-ld
src/schema/vocab0102.py
1
10112
#!/usr/bin/python3 import rdflib import helpFunctions as hf import re class Vocabulary0102: def __init__(self, troot, namespace): self.troot = troot self.basens = namespace['base'] + '/voc/' self.nss = namespace self.ns = re.sub(r'(\{.*\})lookup', r'\1', troot.tag) types...
gpl-2.0
2,940,578,772,786,231,300
66.865772
118
0.572488
false
3.174882
false
false
false
Baymaxteam/SmartHomeDjango
SmartHome/users/migrations/0002_auto_20160129_1459.py
1
1042
# -*- coding: utf-8 -*- # Generated by Django 1.9 on 2016-01-29 06:59 from __future__ import unicode_literals import django.contrib.auth.models import django.core.validators from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('users', '0001_initial'), ] ...
bsd-3-clause
-2,031,301,591,925,869,300
36.214286
409
0.619962
false
4.151394
false
false
false
forkbong/qutebrowser
qutebrowser/completion/models/miscmodels.py
1
10499
# vim: ft=python fileencoding=utf-8 sts=4 sw=4 et: # Copyright 2014-2021 Florian Bruhin (The Compiler) <mail@qutebrowser.org> # # This file is part of qutebrowser. # # qutebrowser 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
8,726,302,838,719,023,000
33.536184
78
0.622059
false
4.005723
true
false
false
sjjhsjjh/blender-driver
diagnostic/analysis.py
1
3137
#!/usr/bin/python # (c) 2018 Jim Hawkins. MIT licensed, see https://opensource.org/licenses/MIT # Part of Blender Driver, see https://github.com/sjjhsjjh/blender-driver """Python module for the Blender Driver diagnostic. This module contains analytical utilities that are used in some diagnostic and demonstration Blend...
mit
-3,456,444,688,188,179,500
34.247191
78
0.603762
false
3.677608
false
false
false
jollychang/robotframework-appiumlibrary
AppiumLibrary/keywords/_logging.py
1
1979
# -*- coding: utf-8 -*- import os from robot.libraries.BuiltIn import BuiltIn from robot.libraries.BuiltIn import RobotNotRunningError from robot.api import logger from .keywordgroup import KeywordGroup class _LoggingKeywords(KeywordGroup): LOG_LEVEL_DEBUG = ['DEBUG'] LOG_LEVEL_INFO = ['DEBUG', 'I...
apache-2.0
3,333,785,420,948,168,700
29.412698
88
0.551794
false
3.769524
false
false
false
hazelcast/hazelcast-python-client
hazelcast/protocol/codec/sql_execute_codec.py
1
2438
from hazelcast.serialization.bits import * from hazelcast.protocol.builtin import FixSizedTypesCodec from hazelcast.protocol.client_message import OutboundMessage, REQUEST_HEADER_SIZE, create_initial_buffer, RESPONSE_HEADER_SIZE from hazelcast.protocol.builtin import StringCodec from hazelcast.protocol.builtin import L...
apache-2.0
9,091,394,537,390,006,000
54.409091
127
0.800656
false
3.348901
false
false
false
tailhook/amfy
amfy/core.py
1
15667
from io import BytesIO import struct import datetime, time from collections import OrderedDict from weakref import WeakKeyDictionary as weakdict class Undefined(object): __slots__ = () def __new__(cls): return undefined def __eq__(self, other): return self is other def __neq__(self, ...
mit
762,591,521,325,786,100
32.911255
83
0.495117
false
4.064073
false
false
false
EnvGen/BARM_web_server
migrations/versions/15045c53040_.py
1
4868
"""empty message Revision ID: 15045c53040 Revises: 80bab4f8ff Create Date: 2016-01-07 10:21:05.812275 """ # revision identifiers, used by Alembic. revision = '15045c53040' down_revision = '80bab4f8ff' from alembic import op import sqlalchemy as sa def upgrade(): ### commands auto generated by Alembic - please...
gpl-2.0
-2,371,235,589,855,736,000
40.965517
106
0.658381
false
3.408964
false
false
false
GrognardsFromHell/TemplePlus
tpdatasrc/tpgamefiles/rules/char_class/class014_ranger.py
1
2902
from toee import * import char_class_utils import char_editor ################################################### def GetConditionName(): # used by API return "Ranger" # def GetSpellCasterConditionName(): # return "Ranger Spellcasting" def GetCategory(): return "Core 3.5 Ed Classes" def GetClassDefinitionFlags(...
mit
5,280,413,577,871,603,000
21.858268
300
0.671606
false
2.501724
false
false
false
openstack/ironic-inspector
ironic_inspector/conductor/manager.py
1
8755
# 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 the...
apache-2.0
7,348,057,273,560,102,000
36.097458
79
0.615877
false
4.327731
false
false
false
rafaelnsantos/batfinancas
financas/migrations/0002_caixa_transacao.py
1
1399
# -*- coding: utf-8 -*- # Generated by Django 1.9.7 on 2017-05-30 05:35 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion import django.utils.timezone class Migration(migrations.Migration): dependencies = [ ('republica', '0001_initial'), ...
mit
-4,478,321,827,652,335,000
37.861111
138
0.596855
false
3.918768
false
false
false
Jakeable/Ralybot
plugins/twitch.py
1
3677
import re import html from ralybot import hook from ralybot.util import http twitch_re = re.compile(r'(.*:)//(twitch.tv|www.twitch.tv)(:[0-9]+)?(.*)', re.I) multitwitch_re = re.compile(r'(.*:)//(www.multitwitch.tv|multitwitch.tv)/(.*)', re.I) def test_name(s): valid = set('ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijk...
gpl-3.0
7,622,407,225,456,648,000
37.705263
152
0.567038
false
3.488615
false
false
false
atsaki/ansible-modules-extras
cloud/amazon/ec2_vpc_subnet_facts.py
1
3740
#!/usr/bin/python # # This is a 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 Ansible library is distributed in the hope that i...
gpl-3.0
8,756,107,837,508,010,000
28.92
203
0.666845
false
3.770161
false
false
false
stelund/bloggagratis_tools
wp_export.py
1
6401
import time import pytz import datetime UTC_TIMEZONE = pytz.timezone('UTC') def format_pubdate(date): # Mon, 02 Nov 2009 08:39:06 +0000 return date.astimezone(UTC_TIMEZONE).strftime(u'%a, %d %b %Y %H:%M:%S %z') def format_isodate(date): # 2009-11-02 09:39:06 return date.strftime(u'%Y-%m-%d %H:%M:%S'...
bsd-3-clause
-5,936,456,404,222,159,000
35.369318
196
0.582253
false
3.035088
false
false
false
gabrielmueller/aljebra-topo
src/backend_parkincpp/parkincppbackend.py
1
53170
from collections import OrderedDict import logging import math, time, sys import libsbml from basics.logging.stdoutwrapper import StdOutWrapper import backend from backend.basebackend import BaseBackend from backend.exceptions import InitError from backend import settingsandvalues import datamanagement.entitydata from ...
lgpl-3.0
6,877,674,015,434,271,000
44.678694
192
0.643596
false
4.308403
false
false
false
jkakavas/creepy
creepy/models/ProjectWizardPossibleTargetsTable.py
1
3572
#!/usr/bin/python # -*- coding: utf-8 -*- from PyQt4.QtCore import QVariant, QAbstractTableModel, Qt from PyQt4.Qt import QPixmap, QIcon, QMimeData, QByteArray, QDataStream, QIODevice import os from utilities import GeneralUtilities class ProjectWizardPossibleTargetsTable(QAbstractTableModel): def __init__(self, ...
gpl-3.0
-1,807,698,924,184,300,300
39.602273
111
0.555431
false
4.620957
false
false
false
fyookball/electrum
gui/qt/request_list.py
1
7117
#!/usr/bin/env python3 # # Electrum - lightweight Bitcoin client # Copyright (C) 2015 Thomas Voegtlin # # 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 withou...
mit
-1,929,781,626,192,813,300
43.761006
163
0.642968
false
3.908292
false
false
false
tobi-wan-kenobi/bumblebee-status
bumblebee_status/modules/contrib/thunderbird.py
1
2547
# pylint: disable=C0111,R0903 """ Displays the unread emails count for one or more Thunderbird inboxes Parameters: * thunderbird.home: Absolute path of your .thunderbird directory (e.g.: /home/pi/.thunderbird) * thunderbird.inboxes: Comma separated values for all MSF inboxes and their parent directory (accoun...
mit
-1,776,329,110,352,044,500
27.617978
170
0.566549
false
3.648997
false
false
false
conda/kapsel
conda_kapsel/verbose.py
1
1279
# -*- coding: utf-8 -*- # ---------------------------------------------------------------------------- # Copyright © 2016, Continuum Analytics, Inc. All rights reserved. # # The full license is in the file LICENSE.txt, distributed with this software. # -------------------------------------------------------------------...
bsd-3-clause
-7,881,255,207,816,083,000
27.4
82
0.593114
false
4.217822
false
false
false
aljim/deploymentmanager-samples
community/cloud-foundation/templates/cloud_function/cloud_function.py
1
6561
# Copyright 2018 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/LICENSE-2.0 # # Unless required by applicable law or a...
apache-2.0
2,122,977,178,188,396,800
31.969849
81
0.636336
false
4.397453
false
false
false
suyashphadtare/test
erpnext/accounts/report/accounts_payable/accounts_payable.py
1
5975
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors # License: GNU General Public License v3. See license.txt from __future__ import unicode_literals import frappe from frappe.utils import getdate, nowdate, flt, cstr from frappe import msgprint, _ from erpnext.accounts.report.accounts_receivable.ac...
agpl-3.0
-4,593,431,470,045,977,000
39.646259
144
0.671967
false
3.089452
false
false
false
dobbinx3/pythonScripts
digital_differential_analyzer.py
1
1758
import sys import math print("Welcome to the DDA's algorithm.") print("\nLet's begin setting the size of the matrix.\n") columns = int(input("How many columns does the matrix have?\n")) lines = int(input("How many lines does the matrix have?\n")) print("\nNow let's set the coordinates of two points, so we can draw ...
mit
-3,734,755,985,305,867,300
24.852941
103
0.661547
false
3.161871
false
false
false
zachjanicki/osf.io
website/routes.py
1
51186
# -*- coding: utf-8 -*- import os import httplib as http from flask import request from flask import send_from_directory from framework import status from framework import sentry from framework.auth import cas from framework.routing import Rule from framework.flask import redirect from framework.routing import WebRen...
apache-2.0
-6,358,533,792,708,472,000
30.363971
139
0.503575
false
4.254509
false
false
false
mistakes-consortium/igng
images/migrations/0003_auto_20141207_1907.py
1
1867
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations class Migration(migrations.Migration): dependencies = [ ('images', '0002_auto_20141201_0515'), ] operations = [ migrations.CreateModel( name='EXIFEntry', fiel...
bsd-3-clause
8,179,612,341,216,877,000
29.606557
114
0.50616
false
4.509662
false
false
false
jonashagstedt/django-jsx
django_jsx/templatetags/djangojs.py
1
1185
from django import template from django.conf import settings from django_jsx.template.backend import JsTemplate from django_jsx.template.loaders import JsLoader register = template.Library() loader = JsLoader(engine=None) class JsMissingTemplateDirException(Exception): pass def _get_template_dirs(): for t ...
bsd-3-clause
-1,721,959,321,510,596,600
29.384615
87
0.729114
false
3.885246
false
false
false
bowen0701/algorithms_data_structures
lc0695_max_area_of_island.py
1
4625
"""Leetcode 695. Max Area of Island Medium URL: https://leetcode.com/problems/max-area-of-island/ Given a non-empty 2D array grid of 0's and 1's, an island is a group of 1's (representing land) connected 4-directionally (horizontal or vertical.) You may assume all four edges of the grid are surrounded by water. Find...
bsd-2-clause
-5,161,163,467,805,236,000
27.20122
75
0.48627
false
2.588137
false
false
false
MaxTyutyunnikov/lino
lino/core/kernel.py
1
12433
# -*- coding: UTF-8 -*- ## Copyright 2009-2013 Luc Saffre ## This file is part of the Lino project. ## Lino 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 y...
gpl-3.0
7,710,695,352,416,538,000
34.567647
121
0.588193
false
3.843277
false
false
false
btbonval/DieStatistician
XdY.py
1
5433
''' Bryan Bonvallet 2009 XdY is standard nomenclature for taking X dice with Y faces, rolling them all, and adding the result. 'd' represents dice. The class XdY is defined to create a probability mass function for the result of rolling and adding X dice with Y faces. ''' from PMF import * class XdY(PMF,FiniteSequ...
mit
8,488,510,294,593,417,000
34.279221
103
0.652678
false
4.024444
false
false
false
nsgomez/FBGroupCommentCounter
prettyprint.py
1
1091
colorAvailable = False loglevel_colors = None verbose = False try: import colorama from colorama import Fore colorama.init() loglevel_colors = [Fore.RED, Fore.YELLOW, Fore.BLUE, Fore.MAGENTA] colorAvailable = True except: pass loglevel_sz = ["[!!]", "[??]", "[ii]", "[vv]"] class Logging: ...
mit
-8,068,261,839,044,515,000
16.046875
70
0.633364
false
3.452532
false
false
false
WaveBlocks/WaveBlocksND
WaveBlocksND/HyperCubicShape.py
1
9987
"""The WaveBlocks Project This file contains the class for representing the hypercubic basis shape which is the full dense basis set. @author: R. Bourquin @copyright: Copyright (C) 2012, 2013, 2014, 2015 R. Bourquin @license: Modified BSD License """ from numpy import array, eye, vstack, integer from WaveBlocksND.B...
bsd-3-clause
7,798,054,498,354,863,000
32.29
115
0.542105
false
3.991607
false
false
false
stvstnfrd/edx-platform
lms/djangoapps/grades/models.py
1
30802
""" Models used for robust grading. Robust grading allows student scores to be saved per-subsection independent of any changes that may occur to the course after the score is achieved. We also persist students' course-level grades, and update them whenever a student's score or the course grading policy changes. As the...
agpl-3.0
-3,658,550,487,341,594,600
39.002597
145
0.635218
false
4.126189
false
false
false
josephnavarro/kanji-radical-reading
constant.py
1
3287
#!usr/bin/env python import os ## Constants ## Constant values used in other files TITLE = "Kanji by Radical" ## Window caption SIZE = W,H = 800,600 ## Screen size SMALL = W*2//3, H*2//3 ## Small screen FPS = 60 ## Screen refresh rate FONTSIZE = 108...
mit
3,822,552,664,235,857,400
26.165289
75
0.613021
false
2.50916
false
false
false
manologomez/Vulcano
support/calculo_redes.py
1
2923
# -*- coding: utf-8 -*- import sys import re import clr from utilidades import * from System import DateTime, Guid from Vulcano.Engine import *#RepoGeneral, AppNotifier from Vulcano.App import * def evaluar_script(code, val, _data): data = _data hoy = DateTime.Now return eval(code) def match_valor(var, valor, da...
mit
8,565,035,509,269,657,000
24.867257
64
0.656175
false
2.541739
false
false
false
meejah/AutobahnPython
autobahn/websocket/util.py
1
5373
############################################################################### # # The MIT License (MIT) # # Copyright (c) Tavendo GmbH # # 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 with...
mit
3,172,701,543,002,705,000
34.582781
116
0.647869
false
4.064297
false
false
false
iemejia/incubator-beam
sdks/python/apache_beam/dataframe/convert_test.py
1
2180
# # 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 us...
apache-2.0
-7,303,798,384,914,836,000
33.0625
75
0.672018
false
3.499197
true
false
false
googleads/google-ads-python
google/ads/googleads/v7/services/services/customer_client_service/transports/grpc.py
1
10383
# -*- coding: utf-8 -*- # Copyright 2020 Google LLC # # 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...
apache-2.0
3,458,914,125,503,089,000
40.866935
94
0.605894
false
4.784793
false
false
false
NerdsvilleCEO/elections
tests/test_flask_simple_voting.py
1
9190
#!/usr/bin/python # -*- coding: utf-8 -*- """ (c) 2014 - Copyright Pierre-Yves Chibon Author: Pierre-Yves Chibon <pingou@pingoured.fr> # This copyrighted material is made available to anyone wishing to use, modify, # copy, or redistribute it subject to the terms and conditions of the GNU # General Public License v....
gpl-2.0
9,100,632,720,071,178,000
35.613546
79
0.54124
false
4.294393
true
false
false
Cesar0510/lbzproject
lbzproject/settings/base.py
1
3224
""" Django settings for lbzproject project. Generated by 'django-admin startproject' using Django 1.11. For more information on this file, see https://docs.djangoproject.com/en/1.11/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/1.11/ref/settings/ """ import o...
apache-2.0
-665,079,409,604,450,000
25.211382
91
0.688275
false
3.474138
false
false
false
manue1/connectivity-manager-agent
cm-agent/wsgi/application.py
1
3443
# Copyright 2015 Technische Universitaet Berlin # 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 # # Unle...
apache-2.0
7,927,272,825,957,574,000
26.99187
115
0.636945
false
3.899207
false
false
false
CCrypto/ccvpn3
ccvpn/settings.py
1
7026
""" Django settings for ccvpn project. Generated by 'django-admin startproject' using Django 1.8. For more information on this file, see https://docs.djangoproject.com/en/1.8/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/1.8/ref/settings/ """ # Build paths in...
mit
-5,602,495,552,386,245,000
26
129
0.67265
false
3.347639
false
false
false
nccgroup/Mortimer
importgoogle.py
1
5412
#!/usr/bin/python # A collection of scripts for processing network forensics type data and intel, mainly into a postgres database. # # Released as open source by NCC Group Plc - http://www.nccgroup.com/ # # Developed for John Green, cirt at nccgroup dot com # # https://github.com/nccgroup/mortimer # # Released under A...
agpl-3.0
2,277,434,971,933,669,600
24.771429
170
0.642831
false
2.85443
false
false
false
laanwj/deluge
win32/deluge-bbfreeze.py
1
2368
build_version = "1.3.1" python_path = "C:\\Python26\\" import os, glob import shutil shutil.copy(python_path + "Scripts\deluge-script.pyw", python_path + "Scripts\deluge.py") shutil.copy(python_path + "Scripts\deluge-script.pyw", python_path + "Scripts\deluge-debug.py") shutil.copy(python_path + "Scripts\deluged-scrip...
gpl-3.0
-6,369,595,552,446,803,000
51.622222
268
0.711993
false
2.763127
false
false
false
GoogleCloudPlatform/datacatalog-connectors
google-datacatalog-connectors-commons/src/google/datacatalog_connectors/commons/monitoring/metrics_processor.py
1
2132
#!/usr/bin/python # # Copyright 2020 Google LLC # # 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 ag...
apache-2.0
-4,256,730,824,790,819,000
35.758621
76
0.651501
false
4.1079
false
false
false
MattRijk/ebook_site
books/migrations/0011_auto_20160422_1235.py
1
1050
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations class Migration(migrations.Migration): dependencies = [ ('books', '0010_auto_20160422_1158'), ] operations = [ migrations.AddField( model_name='bookhasautho...
mit
-7,376,450,695,064,534,000
28.882353
108
0.55619
false
4.338843
false
false
false
willrp/willbuyer
backend/tests/functional/api/cart/test_order.py
1
1226
import requests from backend.util.response.error import ErrorSchema def test_order(domain_url, auth_session, es_create, willorders_ws_db_session): prod_list = es_create("products", 2) item_id = prod_list[0].meta["id"] item_id2 = prod_list[1].meta["id"] auth_session.post( domain_url + "/api/c...
mit
-2,006,155,102,493,854,700
23.52
78
0.628059
false
3.512894
false
false
false
RegulatoryGenomicsUPF/pyicoteo
pyicoteolib/enrichment.py
1
40209
""" Pyicoteo 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 the hope that it will be useful, but WITHOUT ANY...
gpl-3.0
5,883,346,573,406,230,000
46.64218
418
0.583999
false
3.757148
false
false
false
lyijin/working_with_dna_meth
parse_gff3.py
1
8333
#!/usr/bin/env python3 """ > parse_gff3.py < Python script intends to be a helper function that can be called by other scripts to handle gff annotations. Script requires a _file object_ (not filename). The output is in the form of: dict[seqid] = {five_prime_UTR: {ID001: (start_coord1, end_coord1), ...} ...
gpl-3.0
4,050,465,350,289,512,000
37.762791
85
0.572663
false
3.539932
false
false
false
tardis-sn/tardis
tardis/plasma/properties/nlte.py
1
10502
import logging import os import numpy as np import pandas as pd from tardis.plasma.properties.base import ( PreviousIterationProperty, ProcessingPlasmaProperty, ) from tardis.plasma.properties.ion_population import PhiSahaNebular __all__ = [ "PreviousElectronDensities", "PreviousBetaSobolev", "He...
bsd-3-clause
-4,974,188,119,503,110,000
32.552716
113
0.541516
false
3.659233
false
false
false
mkodekar/Fennece-Browser
base/widget/themed/generate_themed_views.py
1
2374
#!/bin/python # -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*- # 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/. ''' Script to generate Th...
mpl-2.0
-6,609,594,954,600,994,000
32.43662
79
0.669756
false
3.39628
false
false
false