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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
stepuncius/vk_mutual_friends_finder | vk_mutual_friends_finder/get_names_of_users.py | 1 | 1027 | import pyvkontakte
from collections import namedtuple
def get_names_of_users(set_of_users):
"""Takes set of user's ids and returns namedtuple
with their names, last names and link on their pages.
Caution: It can't work with more than 1000 people,
it's vkapi's feauture.
"""
VK_ADRE... | bsd-2-clause | -5,208,632,784,300,567,000 | 33.233333 | 69 | 0.59591 | false | 3.16 | false | false | false |
motmot/flytrax | motmot/flytrax/trax_udp_sender.py | 1 | 4075 | import pkg_resources
import socket, threading
import wx
from wx import xrc
RESFILE = pkg_resources.resource_filename(__name__,"trax_udp_sender.xrc") # trigger extraction
RES = xrc.EmptyXmlResource()
RES.LoadFromString(open(RESFILE).read())
class UDPSender(object):
"""A base class for keeping track of a list of ... | bsd-3-clause | -2,490,107,922,923,382,000 | 33.533898 | 94 | 0.547485 | false | 3.929605 | false | false | false |
mmclenna/engine | sky/build/template.py | 1 | 1665 | #!/usr/bin/env python
#
# Copyright 2016 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
'''Renders a single template file using the Jinga templating engine.'''
import argparse
import sys
import os
import itertools
sys.p... | bsd-3-clause | 4,045,351,747,393,844,700 | 27.220339 | 80 | 0.679279 | false | 3.75 | false | false | false |
pyfa-org/eos | eos/eve_obj/effect/dmg_dealer/fighter/missiles.py | 1 | 1879 | # ==============================================================================
# Copyright (C) 2011 Diego Duclos
# Copyright (C) 2011-2018 Anton Vorobyov
#
# This file is part of Eos.
#
# Eos is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as publi... | lgpl-3.0 | -1,862,110,855,468,433,400 | 42.697674 | 80 | 0.662586 | false | 3.403986 | false | false | false |
aaiijmrtt/MUSICALQA | code/language.py | 1 | 3650 | import pyparsing
literals = lambda literallist: pyparsing.Or([pyparsing.Literal(literal) for literal in literallist])
times = literals(['breve', 'breves', 'semibreve','semibreves', 'minim', 'minims', 'crotchets', 'crotchet', 'quavers', 'quaver', 'semiquaver','semiquavers', 'demisemiquaver', 'demisemiquavers'])
augment... | mit | -770,983,344,402,978,700 | 22.101266 | 193 | 0.629041 | false | 2.853792 | false | false | false |
doshaq/Doshabot | cogs/game.py | 1 | 1090 | from discord.ext import commands
import sqlite3
class game :
conn = sqlite3.connect('bot_game.db')
c = conn.cursor()
def __init__(self, bot):
self.bot = bot
conn = sqlite3.connect('bot_game.db')
c = conn.cursor()
@commands.command(pass_context=True, no_pm=True)
async def join_game(self, ctx, *keywords):
se... | gpl-3.0 | 7,310,226,834,112,171,000 | 39.653846 | 150 | 0.700758 | false | 2.721649 | false | false | false |
tgquintela/pySpatialTools | pySpatialTools/utils/perturbations/perturbations.py | 1 | 23997 |
"""
Perturbations
-------------
Module oriented to perform a perturbation of the system in order to carry out
with statistical testing of models.
The main function of this module is grouping functions which are able to
change the system to other statistically probable options in order to explore
the sample space.
TO... | mit | -2,054,015,461,161,471,700 | 30.124514 | 79 | 0.535817 | false | 4.616583 | false | false | false |
mattvonrocketstein/smash | tests/units/test_utils.py | 1 | 1228 | """ tests/test_utils
"""
import os
from smashlib.testing import TestCase, hijack_ipython_module, main
from smashlib.plugins.smash_completer import SmashCompleter, smash_env_complete
from smashlib.overrides import SmashTerminalInteractiveShell
from mock import Mock
hijack_ipython_module()
from IPython.testing.tools impo... | mit | -5,957,990,363,373,603,000 | 31.315789 | 79 | 0.668567 | false | 3.813665 | true | false | false |
hlzz/dotfiles | graphics/VTK-7.0.0/Examples/DataManipulation/Python/FinancialField.py | 1 | 8881 | #!/usr/bin/env python
# This example demonstrates the use of fields and use of
# vtkProgrammableDataObjectSource. It creates fields the hard way (as
# compared to reading a vtk field file), but shows you how to
# interface to your own raw data.
import os
import re
import vtk
from vtk.util.misc import vtkGet... | bsd-3-clause | -383,774,845,512,799,740 | 29.492908 | 73 | 0.695079 | false | 3.275913 | false | false | false |
nickgentoo/scikit-learn-graph | skgraph/kernel/WLOrthoGraphKernel.py | 1 | 15954 | # -*- coding: utf-8 -*-
"""
Created on Fri Jul 3 12:04:44 2015
Copyright 2015 Nicolo' Navarin
This file is part of scikit-learn-graph.
scikit-learn-graph 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 ... | gpl-3.0 | 6,825,893,100,655,079,000 | 41.772118 | 160 | 0.521938 | false | 3.715417 | false | false | false |
stroucki/tashi | src/zoni/hardware/ipmi.py | 2 | 3580 | # Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not u... | apache-2.0 | 2,151,156,001,504,405,200 | 29.084034 | 101 | 0.705866 | false | 3.228133 | false | false | false |
georgthegreat/dancebooks-bibtex | scripts/lib.py | 1 | 31786 | #!/usr/bin/env python3
import functools
import http.client
import json
import math
import os
import subprocess
import shutil
import time
import uuid
from xml.etree import ElementTree
import bs4
import opster
import requests
#NOTE: if the website is protected by cloudflare, removing User-Agent header will help to pas... | gpl-3.0 | 1,744,960,985,823,110,000 | 31.074672 | 137 | 0.693922 | false | 2.857425 | false | false | false |
bczmufrn/frequencia | frequencia/urls.py | 1 | 2221 | """frequencia URL Configuration
The `urlpatterns` list routes URLs to views. For more information please see:
https://docs.djangoproject.com/en/1.11/topics/http/urls/
Examples:
Function views
1. Add an import: from my_app import views
2. Add a URL to urlpatterns: url(r'^$', views.home, name='home')
Class... | mit | 7,764,757,986,167,539,000 | 47.304348 | 99 | 0.70869 | false | 3.354985 | false | false | false |
AlexanderFabisch/cythonwrapper | test/test_type_conversions.py | 1 | 4159 | import numpy as np
from pywrap.testing import cython_extension_from
from nose.tools import assert_equal, assert_raises
def test_bool_in_bool_out():
with cython_extension_from("boolinboolout.hpp"):
from boolinboolout import A
a = A()
b = False
assert_equal(not b, a.neg(b))
def tes... | bsd-3-clause | -8,130,951,337,650,966,000 | 31.24031 | 79 | 0.613369 | false | 3.645048 | true | false | false |
kotoroshinoto/TCGA_MAF_Analysis | gooch_maf_tools/util/MAFcounters.py | 1 | 4909 | import os
import sys
from ..formats import MAF
__author__ = 'mgooch'
class FeatureCounter:
def __init__(self):
self.counts = dict()
self.name = None
def count(self, entry: MAF.Entry):
return 0
def __appendcount__(self, keystring):
if keystring is None:
return
if keystring in self.counts:
self.co... | unlicense | 4,157,340,140,636,658,700 | 30.06962 | 232 | 0.657975 | false | 2.722684 | false | false | false |
repotvsupertuga/tvsupertuga.repository | plugin.video.youtube/resources/lib/youtube_plugin/kodion/utils/monitor.py | 1 | 2946 | import threading
from ..utils import get_proxy_server, is_proxy_live
import xbmc
import xbmcaddon
_addon = xbmcaddon.Addon('plugin.video.youtube')
class YouTubeMonitor(xbmc.Monitor):
def __init__(self, *args, **kwargs):
self._proxy_port = int(_addon.getSetting('kodion.mpd.proxy.port'))
self._o... | gpl-2.0 | -6,832,723,828,920,644,000 | 34.493976 | 135 | 0.590631 | false | 3.570909 | false | false | false |
jkandasa/integration_tests | cfme/infrastructure/networking.py | 1 | 1954 | from navmazing import NavigateToAttribute
from widgetastic.widget import View
from widgetastic_patternfly import Dropdown
from cfme.base.ui import BaseLoggedInPage
from cfme.utils.appliance import Navigatable
from cfme.utils.appliance.implementations.ui import navigator, CFMENavigateStep
from widgetastic_manageiq impo... | gpl-2.0 | 3,075,071,980,845,760,000 | 30.015873 | 91 | 0.716991 | false | 3.947475 | false | false | false |
rdkls/django-audit-mongodb | djangoaudit/forms.py | 1 | 1925 | # -*- coding: utf-8 -*-
##############################################################################
#
# Copyright (c) 2010, 2degrees Limited <egoddard@tech.2degreesnetwork.com>.
# All Rights Reserved.
#
# This file is part of djangoaudit <https://launchpad.net/django-audit/>,
# which is subject to the provisions of ... | bsd-3-clause | -479,323,673,763,812,700 | 36.764706 | 79 | 0.622338 | false | 4.487179 | false | false | false |
FabriceSalvaire/PyOpenGLng | PyOpenGLng/Wrapper/CtypeWrapper.py | 1 | 33545 | ####################################################################################################
#
# PyOpenGLng - An OpenGL Python Wrapper with a High Level API.
# Copyright (C) 2014 Fabrice Salvaire
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Pub... | gpl-3.0 | 1,990,613,322,482,558,700 | 36.606502 | 122 | 0.515397 | false | 4.786672 | false | false | false |
LocutusOfPenguin/picochess | uci/engine.py | 1 | 9818 | # Copyright (C) 2013-2018 Jean-Francois Romang (jromang@posteo.de)
# Shivkumar Shivaji ()
# Jürgen Précour (LocutusOfPenguin@posteo.de)
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as publi... | gpl-3.0 | 5,526,358,255,197,360,000 | 33.321678 | 120 | 0.590261 | false | 3.964459 | false | false | false |
schlos/OIPA-V2.1 | OIPA/iati/management/commands/total_budget_updater.py | 1 | 1856 | import datetime
# Django specific
from django.core.management.base import BaseCommand
from django.db import connection
from iati.models import Activity, Budget
import logging
logger = logging.getLogger(__name__)
class Command(BaseCommand):
option_list = BaseCommand.option_list
counter = 0
def handle(sel... | agpl-3.0 | 7,268,961,908,031,832,000 | 28.47619 | 147 | 0.587823 | false | 3.982833 | false | false | false |
philouc/pyhrf | python/pyhrf/sandbox/physio.py | 1 | 30326 | import os.path as op
import numpy as np
from pyhrf import Condition
from pyhrf.paradigm import Paradigm
from pyhrf.tools import Pipeline
import pyhrf.boldsynth.scenarios as simbase
PHY_PARAMS_FRISTON00 = {
'model_name' : 'Friston00',
'tau_s' : 1/.8,
'eps' : .5,
'eps_max': 10., #TODO: check this
'... | gpl-3.0 | 5,536,194,127,172,453,000 | 35.581423 | 235 | 0.563246 | false | 3.173171 | false | false | false |
snim2/nxt-turtle | tests/test-sensors.py | 1 | 1224 | """
Test the sensors on the Lego NXT.
Copyright (C) Sarah Mount, 2008.
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) any later version.
This p... | gpl-2.0 | -2,247,795,392,501,042,400 | 33 | 78 | 0.694444 | false | 3.754601 | false | false | false |
gdsfactory/gdsfactory | pp/drc/test_width.py | 1 | 1250 | from typing import Tuple
import pp
from pp.drc import check_width
def test_wmin_failing(layer: Tuple[int, int] = (1, 0)) -> None:
w = 50
min_width = 50 + 10 # component edges are smaller than min_width
c = pp.components.rectangle(size=(w, w), layer=layer)
gdspath = c.write_gds("wmin.gds")
# r =... | mit | 7,011,641,545,974,468,000 | 35.764706 | 75 | 0.6608 | false | 2.97619 | false | false | false |
rguillebert/CythonCTypesBackend | Cython/Compiler/TypeSlots.py | 1 | 30865 | #
# Tables describing slots in the CPython type object
# and associated know-how.
#
import Naming
import PyrexTypes
import StringEncoding
invisible = ['__cinit__', '__dealloc__', '__richcmp__',
'__nonzero__', '__bool__']
class Signature(object):
# Method slot signature descriptor.
#
# ... | apache-2.0 | 73,553,137,307,292,590 | 39.293734 | 133 | 0.573692 | false | 3.754866 | false | false | false |
volodymyrss/3ML | threeML/plugins/spectrum/binned_spectrum.py | 1 | 20977 | import numpy as np
import pandas as pd
from threeML.utils.histogram import Histogram
from threeML.utils.interval import Interval, IntervalSet
from threeML.plugins.OGIP.response import InstrumentResponse
from threeML.utils.stats_tools import sqrt_sum_of_squares
class Channel(Interval):
@property
def channel_w... | bsd-3-clause | 6,971,004,834,332,659,000 | 27.194892 | 155 | 0.550794 | false | 4.486099 | false | false | false |
drankye/kerb-token | krb5/src/tests/t_general.py | 1 | 2018 | #!/usr/bin/python
from k5test import *
for realm in multipass_realms(create_host=False):
# Check that kinit fails appropriately with the wrong password.
output = realm.run([kinit, realm.user_princ], input='wrong\n',
expected_code=1)
if 'Password incorrect while getting initial creden... | apache-2.0 | -8,659,719,704,759,129,000 | 36.37037 | 76 | 0.654113 | false | 3.335537 | true | false | false |
dhp-denero/LibrERP | sale_order_version/sale.py | 1 | 6008 | # -*- coding: utf-8 -*-
##############################################################################
#
# Copyright (C) 2004-2012 Pexego Sistemas Informáticos. All Rights Reserved
# $Alejandro Núñez Liz$
# $Omar Castiñeira Saavedra$
#
# Copyright (C) 2014 Didotech srl (<http://www.didotech.com>).
#
# Th... | agpl-3.0 | 3,669,966,839,879,994,000 | 41.274648 | 231 | 0.558387 | false | 3.758923 | false | false | false |
epinna/weevely3 | modules/backdoor/tcp.py | 1 | 3727 | from core.vectors import PhpCode, ShellCmd, ModuleExec, Os
from core.module import Module
from core.loggers import log
from core import messages
import urllib.parse
import telnetlib
import time
class Tcp(Module):
"""Spawn a shell on a TCP port."""
def init(self):
self.register_info(
{
... | gpl-3.0 | -6,986,358,487,308,145,000 | 32.881818 | 270 | 0.473303 | false | 4.10011 | false | false | false |
ds-hwang/deeplearning_udacity | cs224d_nlp/assignment2_dev/q2_NER.py | 1 | 15598 | import os
import getpass
import sys
import time
import numpy as np
import tensorflow as tf
from q2_initialization import xavier_weight_init
import data_utils.utils as du
import data_utils.ner as ner
from utils import data_iterator
from model import LanguageModel
class Config(object):
"""Holds model hyperparams and ... | mit | -2,195,417,113,203,144,000 | 37.136919 | 93 | 0.652904 | false | 3.674441 | true | false | false |
fortyninemaps/karta | tests/vector_predicate_tests.py | 1 | 11300 | """ Unit tests for vector geometry predicate methods """
from __future__ import division
import unittest
import numpy as np
from karta.vector.geometry import (Point, Line, Polygon,
Multipoint, Multiline, Multipolygon)
from karta.crs import (Cartesian, SphericalEarth, LonLatWGS84)
fr... | mit | 7,244,258,512,799,947,000 | 38.788732 | 90 | 0.524071 | false | 3.049933 | true | false | false |
ChrisCooper/pipeline-nanny | taskmaster/models.py | 1 | 3179 | from django.db import models
class JobGroup(models.Model):
name = models.TextField()
nanny_creation_date = models.DateTimeField('date created', auto_now_add=True)
def new_job(self, **args):
return Job.objects.create(group=self, **args)
def __repr__(self):
return "<Job group: {name} ({n_jobs} jobs)>".format(n... | mit | 4,321,678,611,756,257,300 | 34.322222 | 164 | 0.705253 | false | 3.211111 | false | false | false |
explorerwjy/jw_anly502 | PS03/join3.py | 1 | 1856 | #!/usr/bin/env python2
# To get started with the join,
# try creating a new directory in HDFS that has both the fwiki data AND the maxmind data.
import mrjob
from mrjob.job import MRJob
from mrjob.step import MRStep
from weblog import Weblog # imports class defined in weblog.py
import os
import re
import heapq... | cc0-1.0 | 5,963,624,779,465,666,000 | 26.701493 | 89 | 0.651401 | false | 2.979133 | false | false | false |
jni/cellom2tif | cellom2tif/tifffile.py | 1 | 173408 |
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# tifffile.py
# Copyright (c) 2008-2014, Christoph Gohlke
# Copyright (c) 2008-2014, The Regents of the University of California
# Produced at the Laboratory for Fluorescence Dynamics
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or w... | bsd-3-clause | 771,240,095,069,591,600 | 34.651316 | 79 | 0.537928 | false | 3.695429 | false | false | false |
mvaled/sentry | src/sentry/integrations/gitlab/search.py | 2 | 2359 | from __future__ import absolute_import
import six
from rest_framework.response import Response
from sentry.api.bases.integration import IntegrationEndpoint
from sentry.integrations.exceptions import ApiError
from sentry.models import Integration
class GitlabIssueSearchEndpoint(IntegrationEndpoint):
def get(self... | bsd-3-clause | 6,474,268,268,709,563,000 | 34.742424 | 97 | 0.539635 | false | 4.884058 | false | false | false |
samuelctabor/ardupilot | Tools/autotest/arducopter.py | 1 | 288681 | #!/usr/bin/env python
'''
Fly Copter in SITL
AP_FLAKE8_CLEAN
'''
from __future__ import print_function
import copy
import math
import os
import shutil
import time
import numpy
from pymavlink import mavutil
from pymavlink import mavextra
from pymavlink import rotmat
from pysim import util
from pysim import vehiclei... | gpl-3.0 | 940,847,501,828,778,200 | 37.953043 | 127 | 0.537486 | false | 3.739827 | true | false | false |
gforsyth/doctr_testing | doctr/travis.py | 1 | 12160 | """
The code that should be run on Travis
"""
import os
import shlex
import shutil
import subprocess
import sys
import glob
from cryptography.fernet import Fernet
def decrypt_file(file, key):
"""
Decrypts the file ``file``.
The encrypted file is assumed to end with the ``.enc`` extension. The
decryp... | mit | -1,302,443,846,925,126,700 | 33.842407 | 145 | 0.616283 | false | 3.577523 | false | false | false |
cvandeplas/plaso | plaso/parsers/mac_securityd.py | 1 | 9467 | #!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Copyright 2014 The Plaso Project Authors.
# Please see the AUTHORS file for details on individual 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 L... | apache-2.0 | 7,085,151,202,668,476,000 | 33.300725 | 80 | 0.680046 | false | 3.961088 | false | false | false |
selboo/starl-mangle | Agent/Server/s.py | 1 | 4397 | #!/usr/bin/env python
#_*_encoding:utf-8_*_
# encoding:utf-8
import socket, os, subprocess, sys
import time,select,threading
import rsa,base64
import l_command
PRIVATE = os.getcwd()+"/private.pem"
def exchengx_text(text):
Result_Text = []
for i in range(len(text)):
Result_Text.append(''.join(text[i]))
... | apache-2.0 | -6,994,118,043,903,329,000 | 27.006369 | 125 | 0.549011 | false | 3.526063 | false | false | false |
wiredrive/wtframework | generate_examples.py | 1 | 2872 | ##########################################################################
# This file is part of WTFramework.
#
# WTFramework 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 ... | gpl-3.0 | -365,536,399,557,576,400 | 38.888889 | 103 | 0.587396 | false | 4.391437 | false | false | false |
2014c2g5/2014cadp | wsgi/local_data/brython_programs/fourbar1.py | 1 | 1463 | # need yen_fourbar.js
from javascript import JSConstructor
import math
from browser import doc
import browser.timer
# convert Javascript function object into Brython object
point = JSConstructor(Point)
line = JSConstructor(Line)
link = JSConstructor(Link)
triangle = JSConstructor(Triangle)
def draw():
global th... | gpl-3.0 | -3,730,226,384,178,324,500 | 23.813559 | 60 | 0.688312 | false | 2.719331 | false | false | false |
hydroshare/django_docker_processes | migrations/0001_initial.py | 1 | 9489 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import jsonfield.fields
import django_docker_processes.models
from django.conf import settings
class Migration(migrations.Migration):
dependencies = [
migrations.swappable_dependency(settings.AUTH_US... | bsd-3-clause | 3,178,048,872,036,171,000 | 45.743842 | 219 | 0.562125 | false | 4.520724 | false | false | false |
TexZK/pywolf | bin/export_ql_pk3.py | 1 | 62849 | # TODO: create Exporter class(es)
# TODO: break export loops into single item calls with wrapping loop
# TODO: allow export to normal file, PK3 being an option (like with open(file_object|path))
import argparse
import collections
import io
import logging
import os
import sys
import zipfile
from PIL import Image
impo... | gpl-3.0 | 7,717,207,670,447,818,000 | 39.547742 | 116 | 0.571163 | false | 3.404789 | false | false | false |
frerepoulet/ZeroNet | src/Test/TestSiteDownload.py | 1 | 15361 | import time
import pytest
import mock
import gevent
from Connection import ConnectionServer
from Config import config
from File import FileRequest
from File import FileServer
from Site import Site
import Spy
@pytest.mark.usefixtures("resetTempSettings")
@pytest.mark.usefixtures("resetSettings")
class TestSiteDownlo... | gpl-2.0 | -2,810,019,909,871,408,600 | 50.720539 | 173 | 0.679643 | false | 3.386464 | true | false | false |
UB-info/estructura-datos | RafaelArqueroGimeno_S6/ABBInterface.py | 1 | 1812 | import copy
from itertools import cycle, islice
from model import *
import view
import parserLastFM
__author__ = "Rafael Arquero Gimeno"
def add(users, parser):
"""
:type users: ABB
:param parser: File parser
:return: A Binary Search Tree containing old + parsed values
"""
for user in isli... | mit | -3,641,968,380,993,265,000 | 23.16 | 92 | 0.674393 | false | 3.736082 | false | false | false |
stuarteberg/lazyflow | lazyflow/operators/ioOperators/opTiffReader.py | 1 | 7430 | import numpy
# Note: tifffile can also be imported from skimage.external.tifffile.tifffile_local,
# but we can't use that module because it is based on a version of tifffile that has a bug.
# (It doesn't properly import the tifffile.c extension module.)
#import skimage.external.tifffile.tifffile_local as t... | lgpl-3.0 | 642,158,149,604,213,600 | 42.964497 | 125 | 0.577793 | false | 3.746848 | false | false | false |
sharadagarwal/autorest | AutoRest/Generators/Python/Azure.Python.Tests/Expected/AcceptanceTests/StorageManagementClient/storagemanagementclient/models/check_name_availability_result.py | 1 | 1683 | # 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,416,804,943,986,815,000 | 39.071429 | 77 | 0.630422 | false | 4.585831 | false | false | false |
akhilaananthram/nupic.research | sequence_prediction/continuous_sequence/swarm_sine/description.py | 1 | 12630 | # ----------------------------------------------------------------------
# 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... | gpl-3.0 | -6,689,820,296,016,079,000 | 35.293103 | 157 | 0.611876 | false | 4.38694 | true | false | false |
mcxiaoke/python-labs | scripts/youqian2toshl.py | 1 | 1237 | #!/bin/env python3
import csv
import sys
from datetime import datetime
rows = []
with open(sys.argv[1]) as f:
fc = csv.reader(f)
headers = next(fc)
for r in fc:
di = datetime.strptime(r[0], '%Y-%m-%d')
r_date = datetime.strftime(di, '%m/%d/%y')
r_account = '现金'
r_cate = r[3... | apache-2.0 | -8,167,431,639,492,582,000 | 27.447368 | 83 | 0.454209 | false | 2.140594 | false | false | false |
rivelo/portal | gallery/views.py | 1 | 4808 | # -*- coding: utf-8 -*-
from django.http import HttpResponse
#from django.shortcuts import render_to_response
from django.shortcuts import render, redirect
from django.template import RequestContext
from django.http import HttpResponseRedirect, HttpRequest, HttpResponseNotFound
from django.conf import settings
from p... | gpl-2.0 | 6,949,792,971,498,934,000 | 43.388889 | 300 | 0.664581 | false | 3.329167 | false | false | false |
vmrob/needy | needy/generators/pkgconfig_jam.py | 1 | 6825 | from ..generator import Generator
import logging
import os
import subprocess
import textwrap
import hashlib
class PkgConfigJamGenerator(Generator):
@staticmethod
def identifier():
return 'pkgconfig-jam'
def generate(self, needy):
path = os.path.join(needy.needs_directory(), 'pkgconfig.j... | mit | 410,549,216,565,586,900 | 44.5 | 207 | 0.572161 | false | 4.113924 | true | false | false |
jammon/gemeinde | gottesdienste/migrations/0004_auto__add_field_gottesdienst_dauer__add_field_gottesdienst_ort.py | 1 | 2642 | # -*- coding: utf-8 -*-
from south.utils import datetime_utils as 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 'Gottesdienst.dauer'
db.add_column(u'gottesdienste_gottesd... | mit | 1,991,793,960,841,552,400 | 48.867925 | 154 | 0.571537 | false | 3.440104 | false | false | false |
katharine-kinn/django-sql-debugger | sql_debugger/middleware.py | 1 | 1318 | import json
from django.db import connections, connection
from django.conf import settings
__all__ = ['SQLDebugMiddleware']
class SQLDebugMiddleware(object):
def process_response(self, request, response):
if not settings.DEBUG:
return response
if request.is_ajax():
if r... | mit | 3,783,446,745,468,610,600 | 28.954545 | 73 | 0.455994 | false | 4.827839 | false | false | false |
ajgrah2000/pytari2600 | pytari2600/cpu_gen/core.py | 1 | 34536 | from . import addressing
from . import instructions
from . import pc_state
class OpDecoder(object):
def __init__(self, pc_state, memory, instruction_lookup):
self.pc_state = pc_state
self.memory = memory
self.instruction_lookup = instruction_lookup
pass
def execute(self):
... | mit | -1,423,468,789,650,102,000 | 94.933333 | 197 | 0.734132 | false | 3.081096 | false | false | false |
GNOME/gom | examples/gom.py | 1 | 2292 | #!/usr/bin/python3
from gi.types import GObjectMeta
from gi.repository import GLib
from gi.repository import GObject
from gi.repository import Gom
# Need a metaclass until we get something like _gclass_init_
# https://bugzilla.gnome.org/show_bug.cgi?id=701843
class ItemResourceMeta(GObjectMeta):
def __init_... | lgpl-2.1 | -4,386,300,202,051,084,300 | 26.614458 | 75 | 0.654014 | false | 3.603774 | false | false | false |
eayunstack/neutron | neutron/services/auto_allocate/db.py | 1 | 16534 | # Copyright 2015-2016 Hewlett Packard Enterprise Development Company, LP
#
# 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/li... | apache-2.0 | 3,746,684,057,430,448,000 | 42.740741 | 79 | 0.610016 | false | 4.374074 | false | false | false |
min2209/dwt | WTN/depth_model.py | 1 | 6876 | import numpy as np
from math import ceil
import tensorflow as tf
import math
import scipy.io as sio
VGG_MEAN = [103.939, 116.779, 123.68]
class Network:
def __init__(self, params, wd=5e-5, modelWeightPaths=None):
self._params = params
self._images = tf.placeholder("float")
self._batch_imag... | mit | -6,771,102,239,200,756,000 | 41.98125 | 111 | 0.5605 | false | 3.531587 | false | false | false |
ngageoint/scale | scale/storage/move_files_job.py | 1 | 4159 | """Defines the functions necessary to move a file to a different workspace/uri"""
from __future__ import unicode_literals
import logging
import os
import sys
from error.exceptions import ScaleError, get_error_by_exception
from messaging.manager import CommandMessageManager
from storage.brokers.broker import FileDownl... | apache-2.0 | -5,702,555,513,659,372,000 | 40.178218 | 120 | 0.605674 | false | 4.150699 | false | false | false |
cuducos/filterss | filterss/helpers.py | 1 | 4366 | import re
from .forms import FilterForm
from email.utils import parsedate_tz
from filterss import app
from flask import request
from textwrap import wrap
from urllib.parse import urlencode
from urllib.request import Request, urlopen
from werkzeug.local import LocalProxy
from xml.dom.minidom import parse
def set_filte... | mit | 3,528,421,072,841,698,000 | 26.446541 | 79 | 0.601971 | false | 3.670311 | true | false | false |
uprm-research-resto/coliform-project | Coliform/GUI.py | 1 | 42197 | #!/usr/bin/env python3
#
# This is the main GUI function for Coliform Project
#
# This file is part of Coliform. https://github.com/Regendor/coliform-project
# (C) 2016
# Author: Osvaldo E Duran
# Licensed under the GNU General Public License version 3.0 (GPL-3.0)
import os
import time
import sys
try:
import matplo... | gpl-3.0 | 4,477,484,512,611,405,000 | 34.548441 | 156 | 0.614324 | false | 3.81519 | false | false | false |
andersonresende/django | django/test/client.py | 2 | 24532 | from __future__ import unicode_literals
import sys
import os
import re
import mimetypes
from copy import copy
from importlib import import_module
from io import BytesIO
from django.apps import apps
from django.conf import settings
from django.core import urlresolvers
from django.core.handlers.base import BaseHandler
... | bsd-3-clause | -1,923,242,841,704,961,000 | 37.451411 | 112 | 0.587111 | false | 4.484826 | false | false | false |
silverapp/silver | silver/models/payment_methods.py | 1 | 8577 | # Copyright (c) 2017 Presslabs SRL
#
# 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 | -5,897,001,218,787,682,000 | 32.244186 | 97 | 0.647779 | false | 4.393955 | false | false | false |
Goldcap/django-selenium-testing | ppfa/selenium_tests/webdriver.py | 1 | 8427 | import os
import json
import redis
import shutil
import datetime
from ws4redis.redis_store import RedisMessage
from ws4redis.publisher import RedisPublisher
from pyvirtualdisplay import Display
from selenium import webdriver
from django.test import TestCase
from django.conf import settings
from sele... | mit | 5,567,993,571,545,259,000 | 36.959459 | 103 | 0.568055 | false | 4.003325 | true | false | false |
F5Networks/f5-common-python | f5/bigip/tm/asm/policies/parameters.py | 1 | 4409 | # coding=utf-8
#
# Copyright 2017 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 or a... | apache-2.0 | -8,019,605,598,075,704,000 | 37.304348 | 106 | 0.664018 | false | 4.120674 | false | false | false |
ivbeg/lazyscraper | docs/conf.py | 1 | 8502 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# lazyscraper documentation build configuration file
#
# 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.
#
# All configuration values have a defa... | apache-2.0 | -2,493,372,146,225,627,600 | 29.693141 | 84 | 0.705834 | false | 3.728947 | true | false | false |
cheery/essence | essence2/graphics/patch9.py | 1 | 1727 | from surface import Surface
def borders(surface):
width, height = surface.size
y0 = 0
y1 = 0
x0 = 0
x1 = 0
i = 0
while i < height:
r,g,b,a = surface.at((0,i))
if a > 0:
y0 = i
break
i += 1
while i < height:
r,g,b,a = surface.at((0,... | gpl-3.0 | -2,912,530,288,493,200,000 | 25.984375 | 65 | 0.437174 | false | 2.922166 | false | false | false |
oinume/tomahawk | tomahawk/base.py | 1 | 13671 | # -*- coding: utf-8 -*-
import multiprocessing
import os
import re
import platform
from six import print_
import six
import string
import sys
from tomahawk import (
__version__,
TimeoutError,
)
from tomahawk.color import (
create_coloring_object
)
from tomahawk.constants import (
DEFAULT_TIMEOUT,
D... | lgpl-2.1 | 3,294,858,065,523,848,700 | 35.849057 | 113 | 0.526443 | false | 4.383136 | false | false | false |
ThreatConnect-Inc/tcex | tcex/threat_intelligence/mappings/indicator/indicator_types/url.py | 1 | 1845 | """ThreatConnect TI URL"""
# standard library
from urllib.parse import quote_plus
from ..indicator import Indicator
class URL(Indicator):
"""Unique API calls for URL API Endpoints"""
def __init__(self, ti: 'ThreatIntelligenc', **kwargs):
"""Initialize Class Properties.
Args:
tex... | apache-2.0 | -6,489,890,639,290,726,000 | 40 | 95 | 0.62168 | false | 4.002169 | false | false | false |
MenschMarcus/master_HistoGlobe | HistoGlobe_server/models/Hivent.py | 1 | 4233 | # ==============================================================================
# Hivent represents a significant historical happening (historical event).
# It is the only representation of the temporal dimension in the data model
# and therefore the main organisational dimension.
# An Hivent may contain one or many E... | gpl-2.0 | -4,437,588,823,208,093,000 | 41.33 | 104 | 0.550201 | false | 4.581169 | false | false | false |
proversity-org/edx-platform | lms/djangoapps/verify_student/views.py | 1 | 49530 | """
Views for the verification flow
"""
import datetime
import decimal
import json
import logging
import urllib
import analytics
from django.conf import settings
from django.contrib.auth.decorators import login_required
from django.contrib.staticfiles.storage import staticfiles_storage
from django.core.mail import se... | agpl-3.0 | -2,058,498,461,421,042,700 | 39.008078 | 155 | 0.633919 | false | 4.369266 | false | false | false |
cherrypy/magicbus | magicbus/plugins/loggers.py | 1 | 1912 | """Logging plugins for magicbus."""
from magicbus.compat import ntob, unicodestr
import datetime
import sys
from magicbus.plugins import SimplePlugin
class StreamLogger(SimplePlugin):
default_format = '[%(timestamp)s] (Bus %(bus)s) %(message)s\n'
def __init__(self, bus, stream, level=None, format=None, enc... | bsd-3-clause | 5,570,195,874,519,741,000 | 30.866667 | 79 | 0.599895 | false | 4.059448 | false | false | false |
nlgranger/LazyProc | seqtools/indexing.py | 1 | 12939 | from numbers import Integral
import itertools
import bisect
from array import array
from future.builtins import range
from .utils import isint, basic_getitem, basic_setitem, normalize_slice, \
get_logger
class Arange:
def __init__(self, start, stop=None, step=None):
if stop is None and step is None:
... | mpl-2.0 | 9,185,350,080,690,769,000 | 28.076404 | 79 | 0.515341 | false | 4.02082 | false | false | false |
tuanvu216/udacity-course | full_stack_foundations/full_stack_foundations_master/lesson_3/15_delete_menu_item_solution/project.py | 1 | 2369 | from flask import Flask, render_template, request, redirect, url_for
app = Flask(__name__)
from sqlalchemy import create_engine
from sqlalchemy.orm import sessionmaker
from database_setup import Base, Restaurant, MenuItem
engine = create_engine('sqlite:///restaurantmenu.db')
Base.metadata.bind = engine
DBSession = s... | mit | -4,962,088,156,317,859,000 | 36.015625 | 187 | 0.726889 | false | 3.254121 | false | false | false |
openai/universe | universe/envs/diagnostics.py | 1 | 24197 | import collections
import fastzbarlight
import itertools
import logging
from multiprocessing import pool
import numpy as np
import time
import threading
# import psutil
import sys
from collections import namedtuple
from gym.utils import reraise
import re
from universe import error, pyprofile, spaces
# TODO: prefix th... | mit | 3,990,940,570,749,999,000 | 40.081494 | 229 | 0.598008 | false | 3.795013 | false | false | false |
ujjwalgulecha/AdventOfCode | 2015/Day_18/Part_1.py | 1 | 1072 | from copy import copy, deepcopy
lights = []
with open("Day_18.input") as f:
for line in f:
data = line.strip()
light_temp = list(data)
lights.append(light_temp)
def getNeighbours(j, k, lights):
dx = [0, 1, -1]
dy = [0, 1, -1]
neighbours = 0
for x in dx:
for y in dy:
if j+x >= 0 and j+x < len(lights[0]... | mit | -6,348,467,895,201,080,000 | 22.844444 | 97 | 0.608209 | false | 2.504673 | false | false | false |
breedlun/clearplot | doc/source/examples/curve_and_image_sequence/curve_and_image_sequence.py | 1 | 1576 | # -*- coding: utf-8 -*-
"""
Created on Sat Apr 18 15:43:55 2015
@author: Ben
"""
import clearplot.plot_functions as pf
import matplotlib.pyplot
import os
import numpy as np
#Load global response
data_dir = os.path.join(os.path.dirname(pf.__file__), os.pardir, 'doc', \
'source', 'data')
path = os.path.join(data_di... | mit | -1,595,391,377,537,425,700 | 34.044444 | 76 | 0.647843 | false | 2.703259 | false | false | false |
uw-it-aca/spotseeker_server | spotseeker_server/test/spot_caching.py | 1 | 1190 | # Copyright 2021 UW-IT, University of Washington
# SPDX-License-Identifier: Apache-2.0
from django.test import TestCase
from django.core.cache import cache
from spotseeker_server.models import Spot
class SpotCacheTest(TestCase):
def test_spot_caching(self):
spot = Spot.objects.create(name='foo')
... | apache-2.0 | -5,387,262,768,862,895,000 | 31.162162 | 63 | 0.652941 | false | 3.801917 | false | false | false |
restful-open-annotation/eve-restoa | oaeve.py | 1 | 13383 | #!/usr/bin/env python
"""Open Annotation JSON-LD support functions for Eve."""
__author__ = 'Sampo Pyysalo'
__license__ = 'MIT'
import json
import urlparse
import hashlib
import re
import flask
import mimeparse
import oajson
import seqid
from settings import TARGET_RESOURCE
# whether to expand @id values to abso... | mit | 7,361,483,527,524,593,000 | 36.805085 | 80 | 0.661063 | false | 3.793367 | false | false | false |
thesgc/chembiohub_ws | chembl_business_model/models/mechanismAnnotation.py | 1 | 1567 | __author__ = 'mnowotka'
import chembl_core_model.models as core
#-----------------------------------------------------------------------------------------------------------------------
class PredictedBindingDomains(core.PredictedBindingDomains):
#api_exclude = []
class Meta:
proxy = True
ap... | gpl-3.0 | 8,144,624,463,717,007,000 | 28.584906 | 120 | 0.333121 | false | 5.556738 | false | false | false |
mathiasmch/Krypton | lib/basisset.py | 1 | 4258 | #! /usr/bin/env python3.4
# -*- coding:utf-8 -*-
#
# Krypton - A little tool for GAMESS (US) users
#
# Copyright (C) 2012-20.. Mathias M.
#
# 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... | gpl-3.0 | 104,122,611,344,023,140 | 28.365517 | 80 | 0.536637 | false | 3.990628 | false | false | false |
reinforceio/tensorforce | tensorforce/core/parameters/exponential.py | 1 | 2429 | # Copyright 2020 Tensorforce Team. 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 la... | apache-2.0 | -670,260,956,132,704,100 | 45.711538 | 100 | 0.641005 | false | 3.943182 | false | false | false |
sdgdsffdsfff/jumpserver | apps/assets/serializers/node.py | 1 | 1482 | # -*- coding: utf-8 -*-
from rest_framework import serializers
from django.utils.translation import ugettext as _
from orgs.mixins.serializers import BulkOrgResourceModelSerializer
from ..models import Asset, Node
__all__ = [
'NodeSerializer', "NodeAddChildrenSerializer",
"NodeAssetsSerializer",
]
class No... | gpl-2.0 | -4,152,244,283,092,600,300 | 26.962264 | 75 | 0.644399 | false | 4.295652 | false | false | false |
SINGROUP/pycp2k | pycp2k/classes/_restart_averages1.py | 1 | 1738 | from pycp2k.inputsection import InputSection
class _restart_averages1(InputSection):
def __init__(self):
InputSection.__init__(self)
self.Itimes_start = None
self.Avecpu = None
self.Avehugoniot = None
self.Avetemp_baro = None
self.Avepot = None
self.Avekin =... | lgpl-3.0 | 1,865,731,093,727,188,500 | 47.277778 | 735 | 0.587457 | false | 2.544656 | false | false | false |
saullocastro/pyNastran | pyNastran/bdf/dev_vectorized/cards/loads/static/grav.py | 1 | 4585 | from six.moves import zip
import numpy as np
from numpy import zeros, unique
from pyNastran.bdf.field_writer_8 import print_card_8
from pyNastran.bdf.field_writer_16 import print_card_16
from pyNastran.bdf.bdf_interface.assign_type import (integer, integer_or_blank,
double, double_or_blank)
from pyNastran.bdf.dev... | lgpl-3.0 | 771,074,946,562,571,900 | 32.467153 | 89 | 0.499891 | false | 3.363903 | false | false | false |
lenarother/moderna | moderna/modifications/ModificationAdder.py | 1 | 3806 | """
Add modifications to a residue
"""
from ResidueEditor import ResidueEditor
from BaseExchanger import BaseExchanger
from ModificationRemover import ModificationRemover
from moderna.util.Errors import AddModificationError
from moderna.util.LogFile import log
from moderna.Constants import ANY_RESIDUE, MISSING_RESIDUE... | gpl-3.0 | 1,377,465,879,723,447,600 | 39.063158 | 139 | 0.607199 | false | 4.083691 | false | false | false |
jessicachung/rna_seq_pipeline | pipeline_config.py | 1 | 8036 | #---------------------------------
# PIPELINE RUN
#---------------------------------
# The configuration settings to run the pipeline. These options are overwritten
# if a new setting is specified as an argument when running the pipeline.
# These settings include:
# - logDir: The directory where the batch queue scripts... | mit | -6,517,727,467,118,857,000 | 39.791878 | 146 | 0.697113 | false | 3.297497 | false | false | false |
HunterBaines/sudb | setup.py | 1 | 1155 | # Author: Hunter Baines <0x68@protonmail.com>
# Copyright: (C) 2017 Hunter Baines
# License: GNU GPL version 3
import sys
from distutils.core import setup
import sudb
FAILURE = '\033[1;31m' + 'Install cannot proceed.' + '\033[00m'
if len(sys.argv) > 1 and sys.argv[1] == 'install':
# Check python version
i... | gpl-3.0 | -9,102,236,818,809,176,000 | 28.615385 | 77 | 0.592208 | false | 3.737864 | false | true | false |
gersteinlab/AlleleDB | alleledb_pipeline/CombineSnpCounts.py | 1 | 5465 |
import gc, os, sys, string, re, pdb, scipy.stats, cPickle
import Mapping2, getNewer1000GSNPAnnotations, Bowtie, binom, GetCNVAnnotations, dictmerge, utils, InBindingSite
TABLE=string.maketrans('ACGTacgt', 'TGCAtgca')
USAGE="%s mindepth snpfile readfiletmplt maptmplt bindingsites cnvfile outfile logfile ksfile"
def r... | cc0-1.0 | -3,136,855,795,635,907,600 | 30.959064 | 220 | 0.598536 | false | 2.785423 | false | false | false |
mschwager/CTFd | CTFd/admin/teams.py | 1 | 9765 | from flask import current_app as app, render_template, request, redirect, jsonify, url_for, Blueprint
from CTFd.utils import admins_only, is_admin, unix_time, get_config, \
set_config, sendmail, rmdir, create_image, delete_image, run_image, container_status, container_ports, \
container_stop, container_start, g... | apache-2.0 | -7,619,913,300,284,369,000 | 34.769231 | 143 | 0.611162 | false | 3.341889 | false | false | false |
pmoleri/memorize-accesible | score.py | 1 | 2642 | # Copyright (C) 2006, 2007, 2008 One Laptop Per Child
#
# 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) any later version.
#... | gpl-2.0 | -4,537,865,268,180,813,000 | 36.211268 | 79 | 0.589326 | false | 4.021309 | false | false | false |
pythonbyexample/PBE | dbe/social/views.py | 1 | 3177 | # Imports {{{
from PIL import Image as PImage
from dbe.settings import MEDIA_ROOT, MEDIA_URL
from dbe.social.models import *
from dbe.shared.utils import *
from dbe.classviews.list_custom import ListView, ListRelated
from dbe.classviews.edit_custom import CreateView, UpdateView2
from forms import ProfileForm, PostFo... | bsd-3-clause | 5,048,343,791,437,051,000 | 28.691589 | 109 | 0.619452 | false | 3.681344 | false | false | false |
rplevka/robottelo | tests/foreman/endtoend/test_cli_endtoend.py | 1 | 12904 | """Smoke tests for the ``CLI`` end-to-end scenario.
:Requirement: Cli Endtoend
:CaseAutomation: Automated
:CaseLevel: Acceptance
:CaseComponent: Hammer
:Assignee: gtalreja
:TestType: Functional
:CaseImportance: High
:Upstream: No
"""
import random
import pytest
from fauxfactory import gen_alphanumeric
from fau... | gpl-3.0 | 8,062,769,473,121,014,000 | 32.957895 | 99 | 0.629572 | false | 3.873912 | true | false | false |
icoz/pysymo | config.py | 1 | 1684 | # -*- coding: utf-8 -*-
import sys
import os
__author__ = 'ilya-il'
# ==================================================
# PROGRAM CONFIG SECTION. DO NOT EDIT!
# ==================================================
# WTF forms
CSRF_ENABLED = True
SECRET_KEY = 'sifdjncs-dcqodicnpdscn[osncpas#vaidcjnsajcacbqisbcc... | gpl-2.0 | 3,612,526,265,983,320,600 | 25.730159 | 95 | 0.595606 | false | 3.118519 | false | false | false |
MrJohz/K-Eight | ircutils/client.py | 1 | 13416 | """ This module provides a direct client interface for managing an IRC
connection. If you are trying to build a bot, :class:`ircutils.bot.SimpleBot`
inherits from :class:`SimpleClient` so it has the methods listed below.
"""
from __future__ import absolute_import
import collections
import pprint
from . import con... | bsd-2-clause | 5,246,288,881,876,310,000 | 34.401055 | 96 | 0.599583 | false | 4.204325 | false | false | false |
akrherz/iem | scripts/climodat/precip_days.py | 1 | 1747 | """
Generate a map of Number of days with precip
"""
import sys
import datetime
from pyiem.plot import MapPlot
from pyiem.network import Table as NetworkTable
from pyiem.util import get_dbconn
import psycopg2.extras
def runYear(year):
"""Do as I say"""
# Grab the data
now = datetime.datetime.now()
n... | mit | 4,895,807,264,595,162,000 | 24.318841 | 73 | 0.557527 | false | 3.283835 | false | false | false |
SurfasJones/icecream-info | icecream/lib/python2.7/site-packages/model_utils/choices.py | 1 | 4990 | from __future__ import unicode_literals
class Choices(object):
"""
A class to encapsulate handy functionality for lists of choices
for a Django model field.
Each argument to ``Choices`` is a choice, represented as either a
string, a two-tuple, or a three-tuple.
If a single string is provided... | mit | -3,453,485,655,542,937,000 | 33.652778 | 78 | 0.591383 | false | 4.628942 | false | false | false |
donbright/piliko | experiment/experiment2.py | 1 | 3122 | from fractions import Fraction
import sys
# this program explores patterns of pythagorean triples
# in the stern brocot tree... or more specifically,
# the stern diamotic sequence, aka the 'denominators' of the
# stern brocot sequence aka, the farey sequence denominators
# aka 2*sqrt(radius) of the ford circles
# it... | bsd-3-clause | 7,146,669,838,024,524,000 | 20.531034 | 77 | 0.614029 | false | 2.226819 | false | false | false |
Jucyio/Jucy | web/github_mixins.py | 1 | 13786 | import json
import urlparse
kwargs_issues_filters = {
'duplicates': { 'state': 'closed', 'label': 'duplicate' },
'rejected': { 'state': 'closed', 'label': 'rejected' },
'done': { 'state': 'closed', 'label': '-rejected,duplicate' },
'ready': { 'state': 'open', 'label': 'ready' },
'new': { 'state': '... | apache-2.0 | -6,902,052,481,229,804,000 | 35.762667 | 109 | 0.58204 | false | 4.203049 | false | false | false |
cikelengfeng/HTTPIDL | Sources/Compiler/antlr4/tree/RuleTagToken.py | 2 | 1972 | #
# Copyright (c) 2012-2017 The ANTLR Project. All rights reserved.
# Use of this file is governed by the BSD 3-clause license that
# can be found in the LICENSE.txt file in the project root.
#
#
# A {@link Token} object representing an entire subtree matched by a parser
# rule; e.g., {@code <expr>}. These tokens are ... | mit | 460,632,960,464,036,600 | 39.244898 | 99 | 0.653144 | false | 3.90495 | false | false | false |
kieranrimmer/vec_hsqc | vec_hsqc/post_proc.py | 1 | 2620 |
from __future__ import division
import numpy as np
import os
import vec_hsqc
import nmrglue as ng
class DataOut( object ):
def __init__(self):
self.master_array = None
def generate_master_peak_list( self, y, legend_array, cs_array, legend_columns = [0,5], cs_columns = [0,1] ):
predind = np.nonzero( y... | bsd-3-clause | -1,594,254,006,062,670,600 | 33.025974 | 129 | 0.630534 | false | 2.698249 | false | false | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.