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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
msimacek/prettyxmldiff | prettyxmldiff/compare.py | 1 | 8987 | #!/usr/bin/python
# Copyright (C) 2013 Red Hat, Inc
#
# 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 program i... | gpl-2.0 | 8,487,164,973,005,130,000 | 32.533582 | 80 | 0.572494 | false | 3.766555 | false | false | false |
liquidvapour/pythonGameOfLife | gameOfLife.py | 1 | 3012 | #-----------------------------------------------------------------------------
# Copyright 2013 Ra-el Peters
#-----------------------------------------------------------------------------
# This file is part of pythonGameOfLife.
#
# pythonGameOfLife is free software: you can redistribute it and/or modify
# it ... | gpl-3.0 | 8,199,686,377,463,315,000 | 36.185185 | 92 | 0.633134 | false | 3.51049 | false | false | false |
alexandr-kriptonov/contacts | db.py | 1 | 3880 | # -*- coding: utf-8 -*-
import sqlalchemy as sa
from sqlalchemy.orm import mapper, sessionmaker
from PyQt4.QtCore import *
import logging
from classes.mainclass import MainClass
from classes.emitclass import EmitClass
engine = sa.create_engine("sqlite:///database.db", echo=True)
metadata = sa.MetaData()
contacts_tabl... | gpl-2.0 | 302,199,627,067,678,200 | 33.336283 | 79 | 0.53866 | false | 3.75969 | false | false | false |
alirizakeles/tendenci | tendenci/apps/base/management/commands/update_tendenci.py | 1 | 4243 | import os, subprocess, xmlrpclib
from optparse import make_option
from django.conf import settings
from django.contrib.auth.models import User
from django.core.mail.message import EmailMessage
from django.core.management.base import BaseCommand
from django.core.management import call_command, CommandError
from django.... | gpl-3.0 | -7,011,941,566,810,618,000 | 36.219298 | 121 | 0.596276 | false | 4.285859 | false | false | false |
gaiusm/pge | examples/matchsticks/matchsticks.py | 1 | 5215 | #!/usr/bin/env python3
import pge, sys, time
from pygame.locals import *
print("starting matchsticks")
# pge.batch ()
pge.interactive ()
pge.record ()
t = pge.rgb (1.0/2.0, 2.0/3.0, 3.0/4.0)
wood_light = pge.rgb (166.0/256.0, 124.0/256.0, 54.0/256.0)
wood_dark = pge.rgb (76.0/256.0, 47.0/256.0, 0.0)
red = pge.rgb (... | gpl-3.0 | 7,268,900,339,077,757,000 | 28.8 | 105 | 0.552637 | false | 2.545144 | false | false | false |
marsja/psypy | C-M_Oddball/oddball.py | 1 | 5895 | #Cross-modal oddball experiment
#Erik Marsja, erik at marsja.se (http://www.marsja.se)
#Import the modules needed
import time, os, re, random
from datetime import datetime
from sgen import trialCreator#My custom made randomzation script
#Psychopy stuff
from psychopy import visual, core, data, event, logging, gui, sou... | gpl-2.0 | 1,992,753,899,436,810,200 | 33.682353 | 116 | 0.673791 | false | 2.978777 | false | false | false |
knowledgepoint-devs/askbot-devel | askbot/migrations/0184_add_site_values_to_threads.py | 1 | 40719 | # -*- coding: utf-8 -*-
import datetime
from south.db import db
from south.v2 import DataMigration
from django.db import models
from django.conf import settings as django_settings
from askbot.utils.console import ProgressBar
class Migration(DataMigration):
def forwards(self, orm):
"Write your forwards met... | gpl-3.0 | -5,176,686,922,756,893,000 | 87.327549 | 644 | 0.553967 | false | 3.669039 | false | false | false |
wwj718/edx-video | common/djangoapps/terrain/course_helpers.py | 1 | 2265 | # pylint: disable=C0111
# pylint: disable=W0621
from lettuce import world
from .factories import *
from django.conf import settings
from django.http import HttpRequest
from django.contrib.auth.models import User
from django.contrib.auth import authenticate, login
from django.contrib.auth.middleware import Authenticati... | agpl-3.0 | -7,404,900,224,381,252,000 | 31.357143 | 83 | 0.723179 | false | 3.885077 | false | false | false |
maestrano/allocpsa | bin/alloccli/view.py | 1 | 1277 | """alloccli subcommand for viewing the details of a single entity."""
from alloc import alloc
class view(alloc):
"""View an entity."""
# Setup the options that this cli can accept
ops = []
ops.append(('' , 'help ', 'Show this help.'))
ops.append(('t:', 'task=ID ', 'An existing task\'s ID.'... | agpl-3.0 | -8,691,960,315,358,108,000 | 26.170213 | 78 | 0.602193 | false | 3.577031 | false | false | false |
frankosan/pypers | pypers/steps/mapping/bowtie2.py | 1 | 6829 | from pypers.core.step import Step
import os
import re
class bowtie2(Step):
spec = {
"version": "2015.11.20",
"descr": [
"Run bowtie2 mapping for fastq reads, paired or unpaired"
],
"args":
{
"inputs": [
{
"name" ... | gpl-3.0 | 8,922,500,932,495,515,000 | 35.913514 | 132 | 0.378679 | false | 4.017059 | false | false | false |
aarora79/sb_study | sb/sb.py | 1 | 12855 | # -*- coding: utf-8 -*-
import requests as req
import pandas as pd
#import json
import os
import sys
from . import sb_check_quality as cq
from common import utils
from common import globals as glob
# dictionary to hold country to continent mapping, will be filled in
# get_country_to_continent_mapping function invokve... | mit | -5,316,986,291,895,120,000 | 44.264085 | 140 | 0.629716 | false | 3.721772 | false | false | false |
chrislit/abydos | tests/distance/test_distance_sift4_extended.py | 1 | 4433 | # Copyright 2019-2020 by Christopher C. Little.
# This file is part of Abydos.
#
# Abydos 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 versio... | gpl-3.0 | 1,515,637,506,521,325,800 | 40.429907 | 79 | 0.662757 | false | 3.360879 | true | false | false |
topix-hackademy/contact-tools | contacts/views_company.py | 1 | 4402 | from django.http import HttpResponse
from .models import Company, CompanyType
from .serializers_company import CompanySerializer
from .helper import auth_decorator
from rest_framework import status
from rest_framework.response import Response
from rest_framework.decorators import api_view
from django.db.models import ... | mit | 9,131,559,408,307,777,000 | 33.124031 | 274 | 0.659019 | false | 4.068392 | false | false | false |
d-Rickyy-b/Python-BlackJackBot | gamehandler.py | 1 | 2940 | # -*- coding: utf-8 -*-
import random
import string
from typing import Optional
from game.blackJackGame_old import BlackJackGame
__author__ = 'Rico'
# game_handler handles the blackJack-game-objects. When a new game is created, it is saved in the "game_list"
class GameHandler(object):
class __GameHandler(objec... | gpl-3.0 | 5,582,049,146,560,249,000 | 32.033708 | 109 | 0.55068 | false | 4.021888 | false | false | false |
srguiwiz/nrvr-commander | src/nrvr/distros/common/gnome.py | 1 | 2253 | #!/usr/bin/python
"""nrvr.distros.common.gnome - Manipulate Linux distribution GNOME
Class provided by this module is Gnome.
Idea and first implementation - Leo Baschy <srguiwiz12 AT nrvr DOT com>
Public repository - https://github.com/srguiwiz/nrvr-commander
Copyright (c) Nirvana Research 2006-2015.
Simplified BS... | bsd-2-clause | -1,849,727,835,712,705,000 | 30.732394 | 112 | 0.644918 | false | 3.891192 | false | false | false |
johntfoster/bspline | test/demo.py | 1 | 6029 | # -*- coding: utf-8 -*-
"""Demonstration / usage example for the new features.
Created on Fri Mar 24 13:58:36 2017
@author: Juha Jeronen, juha.jeronen@tut.fi
"""
from __future__ import division, print_function, absolute_import
import numpy as np
import matplotlib.pyplot as plt
import matplotlib.cm
import matplotli... | mit | 7,585,581,558,529,574,000 | 34.25731 | 129 | 0.567922 | false | 3.599403 | false | false | false |
sciapp/pyMolDyn | src/gui/gl_stack.py | 1 | 1026 | # -*- coding: utf-8 -*-
from PyQt5 import QtWidgets
from gui.gl_widget import GLWidget
from gui.pdf_widget import PDFWidget
from gui.histogram_widget import HistogramWidget
class GLStack(QtWidgets.QStackedWidget):
def __init__(self, parent, main_window):
QtWidgets.QStackedWidget.__init__(self, parent)
... | mit | -6,717,588,012,170,526,000 | 30.090909 | 92 | 0.67154 | false | 4.007813 | false | false | false |
adityahase/frappe | frappe/core/doctype/log_settings/log_settings.py | 1 | 1517 | # -*- coding: utf-8 -*-
# Copyright (c) 2020, Frappe Technologies and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe import _
from frappe.model.document import Document
class LogSettings(Document):
def clear_logs(self):
self.clear_er... | mit | -4,292,996,593,591,362,600 | 28.764706 | 103 | 0.709954 | false | 3.07085 | false | false | false |
seerjk/reboot06 | 04/homework01-nginx_log_v1.py | 1 | 1496 | # coding:utf-8
__author__ = "seerjk"
# 简单的nginx日志分析
# 日志文件在/home/shre/www_access_20140823.log
# 61.159.140.123 - - [23/Aug/2014:00:01:42 +0800] "GET /favicon.ico HTTP/1.1" 404 \ "-" "Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/29.0.1547.66 Safari/537.36 LBBROWSER" "-"
# 期望输出一个list,分别存储这h... | mit | -5,169,566,209,551,516,000 | 27.918367 | 205 | 0.599576 | false | 2.627087 | false | false | false |
jpbottaro/anna | anna/data/dataset/glove.py | 1 | 2177 | """Reads the GloVe word embeddings
Visit: https://nlp.stanford.edu/projects/glove/"""
import os
import numpy as np
import anna.data.utils as utils
DESTINATION = "glove"
NAME = "glove.840B.300d"
TXT_NAME = NAME + ".txt"
ZIP_NAME = NAME + ".zip"
URL = "http://nlp.stanford.edu/data/" + ZIP_NAME
def fetch_and_parse(da... | mit | -1,309,686,555,006,965,200 | 28.026667 | 77 | 0.615985 | false | 3.396256 | false | false | false |
nickburlett/pennyblack | pennyblack/views.py | 1 | 4631 | import types
from urlparse import urlparse, urlunparse, parse_qs
from urllib import urlencode
from django.contrib.auth.decorators import login_required
from django.core.exceptions import ObjectDoesNotExist
from django.core.urlresolvers import reverse
from django.http import HttpResponse, HttpResponseRedirect
from djan... | bsd-3-clause | -2,097,198,708,699,133,400 | 33.559701 | 122 | 0.682574 | false | 3.859167 | false | false | false |
seanjtaylor/out-for-justice | app/osm.py | 1 | 4883 | # borrowed most of this from: https://gist.github.com/aflaxman/287370
import xml.sax
import copy
import networkx as nx
from geojson import MultiPoint, Point, Polygon, MultiPolygon, GeometryCollection, LineString
def graph_to_geojson(g):
geoms = []
for node_id, node in g.node.iteritems():
geoms.append... | mit | 4,767,870,622,850,726,000 | 29.141975 | 103 | 0.48802 | false | 4.025556 | false | false | false |
leriomaggio/async-ipython-magic | run_async/utils.py | 1 | 2673 | """
"""
# Author: Valerio Maggio <valeriomaggio@gmail.com>
# Copyright (c) 2015 Valerio Maggio <valeriomaggio@gmail.com>
# License: BSD 3 clause
from IPython.utils.coloransi import TermColors, color_templates
from .settings import SERVER_ADDR, SERVER_PORT, CONNECTION_ID_SEP
COLORS = [color[1] for color in color_templ... | mit | 5,232,306,123,375,729,000 | 27.446809 | 89 | 0.639731 | false | 4.068493 | false | false | false |
reviewboard/rbtools | rbtools/utils/process.py | 1 | 7092 | from __future__ import print_function, unicode_literals
import logging
import os
import subprocess
import sys
import six
from rbtools.utils.encoding import force_unicode
def log_command_line(fmt, command):
"""Log a command line.
Args:
fmt (unicode):
A format string to use for the log m... | mit | -4,278,651,614,417,538,000 | 33.096154 | 79 | 0.577693 | false | 4.557841 | false | false | false |
MDSLab/s4t-iotronic | iotronic/objects/board.py | 1 | 9081 | # coding=utf-8
#
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writi... | apache-2.0 | -1,196,548,980,012,195,300 | 36.524793 | 79 | 0.601476 | false | 4.059455 | false | false | false |
masskonfuzion/falldown_low_rez | src/game_state_settings.py | 1 | 13017 | #############################################################################
# Copyright 2016 Mass KonFuzion Games
#
# 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... | apache-2.0 | -5,924,731,298,892,768,000 | 54.866953 | 337 | 0.629561 | false | 4.05514 | false | false | false |
EiNSTeiN-/pbl | pollers/pastebay.py | 1 | 2617 |
import re
import time
import requests
import pbl.pollers
from pbl.pollers.baseentry import BaseEntry
from pbl.pollers.recentitemspoller import RecentItemsDownloader
from pbl.pollers.recentitemspoller import RecentItemsPoller
class PastebayEntry(BaseEntry):
def __init__(self, data, metadata):
BaseEntry.... | gpl-2.0 | -6,959,741,460,352,032,000 | 28.404494 | 117 | 0.612151 | false | 3.639777 | false | false | false |
DMzda/cann-tables | migrations/versions/18e9538995d_.py | 1 | 1270 | """empty message
Revision ID: 18e9538995d
Revises: None
Create Date: 2014-04-17 21:39:03.528681
"""
# revision identifiers, used by Alembic.
revision = '18e9538995d'
down_revision = None
from alembic import op
import sqlalchemy as sa
def upgrade():
### commands auto generated by Alembic - please adjust! ###
... | gpl-3.0 | -4,959,337,881,366,482,000 | 28.534884 | 63 | 0.655118 | false | 3.441734 | false | false | false |
adviti/melange | thirdparty/google_appengine/google/appengine/api/logservice/logservice_stub.py | 1 | 15653 | #!/usr/bin/env python
#
# Copyright 2007 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law o... | apache-2.0 | -8,944,458,214,170,931,000 | 30.686235 | 80 | 0.676228 | false | 3.824334 | false | false | false |
hoosteeno/bedrock | bedrock/settings/base.py | 1 | 48232 | # -*- coding: utf-8 -*-
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
import json
import platform
import socket
import struct
import sys
from os.path import abspath
... | mpl-2.0 | -5,188,924,430,018,638,000 | 30.310995 | 114 | 0.57253 | false | 3.153463 | true | false | false |
jordipons/EUSIPCO2017 | src/lasagne/layers/merge.py | 1 | 15000 | import theano.tensor as T
from .base import MergeLayer
__all__ = [
"autocrop",
"autocrop_array_shapes",
"ConcatLayer",
"concat",
"ElemwiseMergeLayer",
"ElemwiseSumLayer",
]
def autocrop(inputs, cropping):
"""
Crops the given input arrays.
Cropping takes a sequence of inputs and... | mit | 3,404,150,105,843,822,600 | 36.313433 | 79 | 0.587467 | false | 4.179437 | false | false | false |
bit0001/chumme | controller/chumme_root.py | 1 | 2328 | from kivy.properties import ObjectProperty
from kivy.uix.boxlayout import BoxLayout
from controller.add_update_form.add_form import AddFriendForm
from controller.add_update_form.friend_form import ImageChooser
from controller.friend_info.friend_carousel import FriendInfoCarousel
from model.friend import Friend
from .a... | apache-2.0 | -3,045,278,634,186,235,000 | 35.952381 | 73 | 0.700601 | false | 3.576037 | false | false | false |
weidou/OCLR-Check | evaluation/trace-generators/between-and/trace_generator_between_one_various_lengths.py | 1 | 34260 | #!/usr/bin/python
from abc import abstractmethod
from random import randrange, sample
from bisect import insort
from math import ceil, floor
import sys, os, argparse, traceback
"""
A synthesized event trace generator
@author: Wei Dou
@date created: 27 July 2014
@date modified: 20 April 2015
@version: 1.3
@input: an Te... | epl-1.0 | -4,995,239,573,637,865,000 | 35.408077 | 204 | 0.65216 | false | 3.524691 | false | false | false |
simonneuville/runamic_server | djangoserver/server/logic/distance/util.py | 1 | 2274 | """
Various distance functions.
"""
from server.logic.projection.util import Projection, Coordinate
from collections import namedtuple
def distance_to_edge_sqr(point, edge_start, edge_end):
""" Retrieves the distance between a segment (edge) and a point.
Function args:
point -- a Vector of... | mit | -3,361,105,691,118,453,000 | 32.940299 | 107 | 0.622691 | false | 3.399103 | false | false | false |
esquires/linux-config | clang_install.py | 1 | 3383 | import os
import subprocess as sp
import multiprocessing as mp
import argparse
import lvdb
THIS_FILE_PATH = os.path.dirname(os.path.realpath(__file__))
def llvm_repo(suffix):
return 'https://git.llvm.org/git/' + suffix
def patch(patch_file):
lvdb.set_trace()
sp.call(['git', 'stash'])
sp.check_call([... | mit | 2,813,206,662,171,030,000 | 26.504065 | 77 | 0.581437 | false | 3.069873 | false | false | false |
simpleapples/light-blog | app/auth/controllers/login.py | 1 | 1239 | from .. import auth
from ..forms.login_form import LoginForm
from ..models.user import User
from ..errors import UserError
from flask import redirect, url_for, request, render_template
from flask.ext.login import login_user, logout_user, login_required
@auth.route('/login', methods=['GET', 'POST'])
def login():
re... | mit | 2,072,898,551,730,911,000 | 36.575758 | 77 | 0.619048 | false | 4.075658 | false | false | false |
badloop/SickRage | sickrage/show/Show.py | 1 | 5537 | # This file is part of SickRage.
#
# URL: https://www.sickrage.tv
# Git: https://github.com/SickRage/SickRage.git
#
# SickRage 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, o... | gpl-3.0 | -2,168,956,686,308,889,000 | 32.969325 | 114 | 0.610439 | false | 4.4296 | false | false | false |
geomf/omf-fork | omf/models/gridlabMulti.py | 1 | 26721 | # Portions Copyright (C) 2015 Intel Corporation
''' Powerflow results for one Gridlab instance. '''
import sys
import shutil
import os
import datetime
import multiprocessing
import pprint
import json
import math
import traceback
import __metaModel__
import logging
from os.path import join as pJoin
from os.path import ... | gpl-2.0 | 2,901,034,312,881,296,000 | 47.407609 | 151 | 0.546986 | false | 3.858628 | false | false | false |
Adrimel/pdb-tools | pdb_splitseg.py | 1 | 2656 | #!/usr/bin/env python
"""
Extracts each segment of a PDB file to a separate file.
usage: python pdb_splitseg.py <pdb file>
example: python pdb_splitseg.py 1CTF.pdb
Author: {0} ({1})
This program is part of the PDB tools distributed with HADDOCK
or with the HADDOCK tutorial. The utilities in this package
can be used... | mit | -4,667,274,138,186,394,000 | 28.511111 | 95 | 0.573419 | false | 3.527224 | false | false | false |
mikkokeskinen/tunnistamo | scopes/api.py | 1 | 3870 | from django.conf import settings
from django.utils import translation
from django.utils.functional import cached_property
from django.utils.translation.trans_real import translation as trans_real_translation
from rest_framework import serializers
from rest_framework.schemas import AutoSchema
from rest_framework.views i... | mit | 42,444,641,574,669,290 | 33.247788 | 113 | 0.660207 | false | 4.16577 | false | false | false |
Pathel/deuterium | src/server/serversession.py | 1 | 12159 | """
This defines a the Server's generic session object. This object represents
a connection to the outside world but don't know any details about how the
connection actually happens (so it's the same for telnet, web, ssh etc).
It is stored on the Server side (as opposed to protocol-specific sessions which
are stored o... | bsd-3-clause | 1,319,670,371,899,397,600 | 35.295522 | 91 | 0.595115 | false | 4.290402 | false | false | false |
JessWalters/VinnyBot | Core/Reddit.py | 1 | 4282 | import praw
import random
import itertools
from prawcore import NotFound
from Config import getToken
from nsfw import isEnabled
def initReddit():
global r
r = praw.Reddit(user_agent='Discord Bot', client_id='byorb8K1SwaO1g', client_secret=getToken('Reddit'))
def random_hot_post(subreddit, limit, message):
... | mit | 54,814,307,992,087,690 | 28.328767 | 154 | 0.625409 | false | 3.717014 | false | false | false |
probcomp/bayeslite | shell/src/main.py | 1 | 3443 | # -*- coding: utf-8 -*-
# Copyright (c) 2010-2016, MIT Probabilistic Computing Project
#
# 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/LICENS... | apache-2.0 | -6,293,375,024,919,978,000 | 36.423913 | 79 | 0.607029 | false | 3.796031 | false | false | false |
scottdanesi/earthshaker-aftershock | utilities.py | 1 | 19294 | #################################################################################
## _________ ____ ________ _______ __ _____ __ __ __________ __
## / ____/ | / __ \/_ __/ / / / ___// / / / | / //_// ____/ __ \/ /
## / __/ / /| | / /_/ / / / / /_/ /\__ \/ /_/ / /| | / ,< / __/ / /_/ / /
## ... | gpl-3.0 | -6,575,208,469,274,433,000 | 38.135903 | 152 | 0.653519 | false | 2.928214 | false | false | false |
hpcloud-mon/monasca-events-api | monasca_events_api/common/repositories/mysql/streams_repository.py | 1 | 12836 | # Copyright 2015 Hewlett-Packard
#
# 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, ... | apache-2.0 | 7,464,351,899,179,540,000 | 36.205797 | 107 | 0.507557 | false | 4.784197 | false | false | false |
pddring/minecraft-quiz | connection.py | 1 | 1621 | """
This file has been taken from http://pi.minecraft.net/
"""
import socket
import select
import sys
from util import flatten_parameters_to_string
""" @author: Aron Nieminen, Mojang AB"""
class RequestError(Exception):
pass
class Connection:
"""Connection to a Minecraft Pi game"""
RequestFailed = "Fail... | gpl-2.0 | -4,872,935,801,496,703,000 | 29.018519 | 75 | 0.574337 | false | 3.726437 | false | false | false |
dc217863/CarND-Behavioral-Cloning-P3 | model.py | 1 | 5873 | import csv
import matplotlib.pyplot as plt
import cv2
import numpy as np
from sklearn.utils import shuffle
from keras.models import Sequential
from keras.layers import Flatten, Dense, Lambda, Convolution2D, Cropping2D, Dropout, SpatialDropout2D
IMAGE_HEIGHT, IMAGE_WIDTH, IMAGE_CHANNELS = 160, 320, 3
INPUT_SHAPE = (IMA... | apache-2.0 | 796,869,352,137,948,900 | 32.947977 | 176 | 0.599523 | false | 3.58547 | false | false | false |
tsl143/addons-server | src/olympia/ratings/forms.py | 1 | 2739 | import re
from urllib2 import unquote
from django import forms
from django.utils.translation import ugettext, ugettext_lazy as _
from bleach import TLDS
from olympia.amo.utils import raise_required
from .models import RatingFlag
class RatingReplyForm(forms.Form):
form_id = 'review-reply-edit'
title = for... | bsd-3-clause | 6,666,693,121,271,457,000 | 28.138298 | 70 | 0.550566 | false | 3.656876 | false | false | false |
dladd/pyFormex | pyformex/gui/viewport.py | 1 | 63284 | ## $Id$
##
## This file is part of pyFormex 0.8.9 (Fri Nov 9 10:49:51 CET 2012)
## pyFormex is a tool for generating, manipulating and transforming 3D
## geometrical models by sequences of mathematical operations.
## Home page: http://pyformex.org
## Project page: http://savannah.nongnu.org/projects/pyformex/
#... | gpl-3.0 | 3,934,186,993,234,160,600 | 34.23608 | 140 | 0.573115 | false | 3.943174 | false | false | false |
antkillerfarm/antkillerfarm_crazy | python/ml/keras/hello_gan1.py | 1 | 8363 | #!/usr/bin/python
# -*- coding: utf-8 -*-
import os
import matplotlib.pyplot as plt
import keras.backend as K
from keras.datasets import mnist
from keras.layers import *
from keras.models import *
from keras.optimizers import *
from keras.initializers import *
from keras.utils.generic_utils import Progbar
GPU = "0"... | gpl-3.0 | -1,700,461,807,342,339,000 | 28.038194 | 97 | 0.578261 | false | 3.051076 | true | false | false |
valohai/valohai-cli | valohai_cli/ctx.py | 1 | 1590 | import click
from valohai_cli.exceptions import NoProject
from valohai_cli.messages import success
from valohai_cli.settings import settings
from valohai_cli.utils import get_project_directory
from typing import Optional, Union, overload
from typing_extensions import Literal
from valohai_cli.models.project import Proj... | mit | -6,120,279,898,257,508,000 | 31.44898 | 112 | 0.716352 | false | 3.767773 | false | false | false |
ravikiranj/mcc-mnc-csv | getMccDataFromWiki.py | 1 | 2777 | #!/usr/bin/env python
import requests
import traceback
import sys
from bs4 import BeautifulSoup
import csv
## getHTML
def getHTML():
url = "http://en.wikipedia.org/wiki/Mobile_country_code"
html = ""
try :
r = requests.get(url)
html = r.text.encode("utf-8")
except:
traceback.p... | bsd-2-clause | 6,452,967,797,920,541,000 | 27.336735 | 88 | 0.579402 | false | 3.564827 | false | false | false |
shaon/emis | install-emis.py | 1 | 15926 | # Software License Agreement (BSD License)
#
# Copyright (c) 2009-2014, Eucalyptus Systems, Inc.
# All rights reserved.
#
# Redistribution and use of this software in source and binary forms, with or
# without modification, are permitted provided that the following conditions
# are met:
#
# Redistributions of source ... | gpl-3.0 | -6,562,772,192,289,267,000 | 36.561321 | 98 | 0.516577 | false | 3.865534 | true | false | false |
muravjov/ReVo-utilities | revo-export/utilities.py | 1 | 11197 | # -*- coding: utf-8 -*-
import re
def clean_string(string):
r"""Discard newlines, remove multiple spaces and remove leading or
trailing whitespace. We also replace quotation mark characters
since we've decided to use a different style (though usually
quotes are marked with <ctl>).
Note since this ... | agpl-3.0 | -5,069,846,169,969,987,000 | 43.979757 | 306 | 0.632403 | false | 2.570569 | false | false | false |
EventBuck/EventBuck | shop/handlers/profile/login_logout_handler.py | 1 | 1582 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
'''
Created on 4 juin 2013
@author: Aristote Diasonama
'''
import logging
from shop.handlers.base_handler import BaseHandler, no_user_required
import helper_functions as helpers
from webapp2_extras.auth import InvalidAuthIdError, InvalidPasswordError
class LoginHandle... | mit | -7,810,934,695,890,455,000 | 29.423077 | 86 | 0.611884 | false | 3.964912 | false | false | false |
shopkick/flawless | flawless/lib/data_structures/prefix_tree.py | 1 | 4999 | #!/usr/bin/env python
#
# Copyright (c) 2011-2013, Shopkick Inc.
# All rights reserved.
#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
# ---
# Author: John Egan <jw... | mpl-2.0 | -158,620,203,498,834,050 | 33.475862 | 97 | 0.59912 | false | 3.830651 | false | false | false |
HumanExposure/factotum | dashboard/tasks.py | 1 | 2430 | import logging
from celery.schedules import crontab
from django.apps import apps
from django.conf import settings
from django.utils.timezone import now
from factotum.celery import app
logger = logging.getLogger("django")
@app.on_after_finalize.connect
def setup_periodic_tasks(sender, **kwargs):
sender.add_peri... | gpl-3.0 | -2,566,582,072,204,947,500 | 32.287671 | 117 | 0.62716 | false | 3.552632 | false | false | false |
saskartt/P4UL | pyPlot/csv2anim.py | 1 | 2263 | #!/usr/bin/python
import sys
import subprocess as sb
import pylab as pl
import argparse
from utilities import filesFromList
from plotTools import userLabels, plotCSV
'''
Description:
Author: Mikko Auvinen
mikko.auvinen@helsinki.fi
University of Helsinki &
Finnish Meteorological Institute
''... | mit | -7,194,529,233,507,562,000 | 32.279412 | 102 | 0.63544 | false | 3.223647 | false | false | false |
rwl/muntjac | muntjac/ui/expand_layout.py | 1 | 2653 | # @MUNTJAC_COPYRIGHT@
# @MUNTJAC_LICENSE@
"""Defines a layout that will give one of it's components as much space as
possible, while still showing the other components in the layout."""
from warnings import warn
from muntjac.ui.ordered_layout import OrderedLayout
class ExpandLayout(OrderedLayout):
"""A layout ... | apache-2.0 | 2,814,814,136,527,497,000 | 31.353659 | 78 | 0.651338 | false | 4.436455 | false | false | false |
tuukka/booki-old | lib/booki/reader/views.py | 1 | 5426 | import os
from django.shortcuts import render_to_response
from django.http import Http404, HttpResponse,HttpResponseRedirect
from django.contrib.auth.models import User
from booki.editor import models
from booki.utils import pages
from booki.editor.views import getVersion
from django.conf import settings
# this is j... | gpl-2.0 | -5,515,667,327,163,834,000 | 38.318841 | 118 | 0.562108 | false | 4.252351 | false | false | false |
fire-rs-laas/fire-rs-saop | python/fire_rs/planning/demo_plan_and_execution.py | 1 | 4925 | # Copyright (c) 2017, CNRS-LAAS
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# * Redistributions of source code must retain the above copyright notice, this
# list of conditions and the f... | bsd-2-clause | -4,998,780,280,342,906,000 | 43.772727 | 101 | 0.650964 | false | 3.667163 | false | false | false |
n0x5/scripts | youtube_api_uploads.py | 1 | 4183 | # command: python3 download_yt.py <uploads_playlistid>
# example: python3 download_yt.py UUcD1pbEB9HNFIVwJih_ZWAA
import json
import urllib.request
import requests
import subprocess
import os
import re
import argparse
parser = argparse.ArgumentParser()
parser.add_argument('channel')
args = parser.parse_args()
strea... | gpl-2.0 | -149,347,667,429,327,780 | 33.286885 | 214 | 0.620846 | false | 3.381568 | false | false | false |
tensorflow/probability | tensorflow_probability/python/distributions/matrix_normal_linear_operator.py | 1 | 9742 | # Copyright 2020 The TensorFlow Probability Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law o... | apache-2.0 | 769,635,890,983,546,600 | 35.350746 | 81 | 0.668651 | false | 3.648689 | false | false | false |
sidmanu/myDistrict | dashboard/models.py | 1 | 1564 | from django.db import models
# Create your models here.
#basics of myDistrict
class District(models.Model):
name = models.CharField(max_length=40)
username = models.CharField(max_length=30)
password = models.CharField(max_length=30)
def __unicode__(self):
return "<District: %s id: %d>"%(self.name, self.id)
... | gpl-2.0 | 6,504,899,937,338,209,000 | 25.508475 | 61 | 0.725703 | false | 3.115538 | false | false | false |
JulyKikuAkita/PythonPrac | ThreadPrac/ConsumerProducerWithQueue.py | 1 | 3590 | __author__ = 'July'
import threading
import time
import logging
import random
import Queue
'''
from redis import Redis
from rq import Queue
'''
from functools import partial
from multiprocessing.pool import Pool
# Below example implement P-C using Queue.Queue - a sync queue class
# Queue encapsulates the behaviour of ... | apache-2.0 | 1,396,125,213,075,386,600 | 32.240741 | 122 | 0.647911 | false | 3.919214 | false | false | false |
texastribune/ipeds_reporter | csv_downloader/csv_downloader.py | 1 | 5353 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
Thing to automate getting custom reports from IPEDS.
Usage:
./csv_downloader.py test
./csv_downloader.py --uid=<uid_path> --mvl=<mvl_path>
Options:
--uid=FILE Path to .uid file
--mvl=PATH Path to .mvl file or directory containing .mvl files
You also need ... | apache-2.0 | -3,510,928,483,671,983,600 | 38.360294 | 138 | 0.668597 | false | 3.364551 | false | false | false |
DarthMaulware/EquationGroupLeaks | Leak #5 - Lost In Translation/windows/Resources/Python/Core/Lib/xml/etree/ElementTree.py | 1 | 29152 | # uncompyle6 version 2.9.10
# Python bytecode 2.7 (62211)
# Decompiled from: Python 3.6.0b2 (default, Oct 11 2016, 05:27:10)
# [GCC 6.2.0 20161005]
# Embedded file name: ElementTree.py
__all__ = [
'Comment',
'dump',
'Element', 'ElementTree',
'fromstring', 'fromstringlist',
'iselement', 'iterparse',
'parse', 'Par... | unlicense | -3,380,690,511,043,542,000 | 28.992798 | 291 | 0.533342 | false | 4.193929 | false | false | false |
fluxid/pyhaa | pyhaa/utils/__init__.py | 1 | 5731 | # -*- coding: utf-8 -*-
# Pyhaa - Templating system for Python 3
# Copyright (c) 2011 Tomasz Kowalczyk
# Contact e-mail: code@fluxid.pl
#
# This library is free software: you can redistribute it and/or modify it under
# the terms of the GNU Lesser General Public License as published by the Free
# Software Foundation, ... | lgpl-3.0 | -8,585,758,655,486,231,000 | 25.906103 | 80 | 0.597452 | false | 3.775362 | false | false | false |
Wikia/sparrow | apps/testrunner/tasks/deploy.py | 1 | 3950 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from contextlib import closing
from django.conf import settings
from celery.utils.log import get_task_logger
from .base_task import BaseTask
from testrunner.ssh import SSHConnection
logger = get_task_logger(__name__)
class Deploy(BaseTask):
PACKAG... | mit | -2,210,757,906,912,180,000 | 36.980769 | 109 | 0.606076 | false | 3.876349 | false | false | false |
spudsdude/XBMC-Flicks | resources/lib/Netflix.py | 1 | 32044 | #
# Library for accessing the REST API from Netflix
# Represents each resource in an object-oriented way
#
import sys
import os.path
import re
import oauth as oauth
import httplib
import time
from xml.dom.minidom import parseString
import simplejson
from urlparse import urlparse
HOST = 'api-public.netfli... | gpl-3.0 | 5,885,189,597,736,362,000 | 39.105131 | 129 | 0.536013 | false | 4.596758 | false | false | false |
FunkySayu/PowerSpikeGG | powerspikegg/rawdata/fetcher/server.py | 1 | 3781 | import gflags
import grpc
import logging
import riotwatcher
import sys
import time
import threading
from concurrent import futures
from powerspikegg.rawdata.public import match_pb2
from powerspikegg.rawdata.public import constants_pb2
from powerspikegg.rawdata.fetcher import cache
from powerspikegg.rawdata.fetcher im... | gpl-3.0 | 2,809,475,328,792,825,000 | 30.508333 | 78 | 0.672838 | false | 4.001058 | false | false | false |
ejolly/pymer4 | pymer4/utils.py | 1 | 22036 | """Utility functions"""
__all__ = [
"get_resource_path",
"_check_random_state",
"_sig_stars",
"_robust_estimator",
"_chunk_boot_ols_coefs",
"_chunk_perm_ols",
"_permute_sign",
"_ols",
"_ols_group",
"_corr_group",
"_perm_find",
"_mean_diff",
"_return_t",
"_get_para... | mit | 7,664,235,127,400,273,000 | 32.901538 | 324 | 0.608686 | false | 3.485055 | false | false | false |
dotting/Pysnip-documentation | pyspades/server.py | 1 | 65302 | # Copyright (c) Mathias Kaerlev 2011-2012.
# This file is part of pyspades.
# pyspades 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... | gpl-3.0 | 2,578,209,004,928,243,000 | 36.315429 | 84 | 0.512664 | false | 4.17052 | false | false | false |
googleapis/googleapis-gen | google/ads/googleads/v7/googleads-py/google/ads/googleads/v7/errors/types/header_error.py | 1 | 1165 | # -*- 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 | 281,543,209,548,216,900 | 29.657895 | 74 | 0.692704 | false | 3.976109 | false | false | false |
SilentCircle/iap-local-receipt | iap_local_receipt/iap_pkcs7_verifier.py | 1 | 3089 | from OpenSSL import crypto
from cffi import FFI
ffi = FFI()
class PKCS7VerifyError(Exception):
def __init__(self, message=None, **kwargs):
super(PKCS7VerifyError, self).__init__(
message or ffi.string(crypto._lib.ERR_error_string(crypto._lib.ERR_get_error(), ffi.NULL)),
**kwargs
... | bsd-3-clause | -5,711,755,667,869,927,000 | 34.918605 | 120 | 0.625769 | false | 3.575231 | false | false | false |
ntt-sic/taskflow | taskflow/utils/lock_utils.py | 1 | 6103 | # vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright 2011 OpenStack Foundation.
# 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.apac... | apache-2.0 | -689,152,063,237,627,100 | 32.349727 | 79 | 0.624775 | false | 4.258897 | false | false | false |
xiaoleihuang/Books | Data Science from Scratch/chapter9/scrapebook.py | 1 | 1361 | """This code does not work as for it will raise connection error"""
import requests
from bs4 import BeautifulSoup
import re
from time import sleep
def is_video(td):
"""it is a video if two prerequisites"""
pricelabels = td('span', 'pricelabel')
return(len(pricelabels) == 1 and
pricelabels[0].text.strip().startwi... | gpl-2.0 | -4,252,689,506,675,432,000 | 30.651163 | 98 | 0.668626 | false | 2.90812 | false | false | false |
gem/geonode | geonode/services/views.py | 1 | 53592 | # -*- coding: utf-8 -*-
#########################################################################
#
# Copyright (C) 2016 OSGeo
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 ... | gpl-3.0 | 7,382,064,013,415,639,000 | 37.947674 | 120 | 0.532244 | false | 4.419959 | false | false | false |
jorik041/plaso | plaso/parsers/winreg.py | 1 | 12037 | # -*- coding: utf-8 -*-
"""Parser for Windows NT Registry (REGF) files."""
import logging
from plaso.lib import errors
from plaso.lib import specification
from plaso.parsers import interface
from plaso.parsers import manager
from plaso.winregistry import cache
from plaso.winregistry import registry as winregistry
#... | apache-2.0 | -5,360,867,950,847,436,000 | 32.34349 | 80 | 0.667193 | false | 4.110997 | false | false | false |
Microvellum/Fluid-Designer | win64-vc/2.78/Python/bin/2.78/scripts/addons_contrib/io_export_md3.py | 1 | 23208 | # ##### BEGIN GPL LICENSE BLOCK #####
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distrib... | gpl-3.0 | 5,669,525,010,439,375,000 | 32.537572 | 198 | 0.5745 | false | 3.118517 | false | false | false |
adamrvfisher/TechnicalAnalysisLibrary | NCAdviceColumn.py | 1 | 1677 | # -*- coding: utf-8 -*-
"""
Created on Thu Apr 6 16:04:32 2017
@author: AmatVictoriaCuramIII
"""
from DefNCAdviceGiver import DefNCAdviceGiver
import numpy as np
import pandas as pd
from pandas_datareader import data
Aggregate = pd.read_pickle('SP500NCAGGSHARPE0205')
Aggregate = Aggregate.loc[:,~Aggregat... | apache-2.0 | -4,202,027,649,153,246,000 | 32.979167 | 84 | 0.630888 | false | 2.61215 | false | false | false |
simondlevy/m021v4l2 | opencv/python/m021v4l2/__init__.py | 1 | 3226 | '''
Python classes for Leopard Imaging LI-USB30-M021 on Linux
Copyright (C) 2016 Simon D. Levy
This file is part of M021_V4L2.
M021_V4L2 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 L... | gpl-3.0 | -8,628,522,154,335,589,000 | 32.257732 | 106 | 0.695288 | false | 3.790834 | false | false | false |
lmazuel/azure-sdk-for-python | azure-mgmt-network/azure/mgmt/network/v2017_09_01/models/application_gateway_ssl_policy.py | 1 | 2629 | # 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 | 7,507,148,752,622,347,000 | 45.946429 | 83 | 0.658806 | false | 3.866176 | false | false | false |
smartinov/fennec | fennec/apps/repository/migrations/0001_initial.py | 1 | 6535 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
from django.conf import settings
class Migration(migrations.Migration):
dependencies = [
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
]
operations = [
migrations.Create... | gpl-3.0 | -4,922,901,982,481,357,000 | 50.456693 | 177 | 0.579342 | false | 4.451635 | false | false | false |
3dfxsoftware/cbss-addons | account_general_ledger_report/report/account_general_ledger_report.py | 1 | 15271 | #-*- coding:utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>). All Rights Reserved
# d$
#
# This program is free software: you can redistribute it and/or modify
# it ... | gpl-2.0 | 6,951,791,868,092,733,000 | 46.721875 | 177 | 0.509528 | false | 4.727864 | false | false | false |
aprokop/dotfiles | .vim/.ycm_extra_conf.py | 1 | 4951 | import os
import ycm_core
import re
import commands
# These are the compilation flags that will be used in case there's no
# compilation database set (by default, one is not set).
# CHANGE THIS LIST OF FLAGS. YES, THIS IS THE DROID YOU HAVE BEEN LOOKING FOR.
flags = [
'-Wall',
'-Wextra',
'-Werror',
'-Wc++98-co... | gpl-3.0 | 6,985,004,689,908,136,000 | 33.381944 | 144 | 0.681075 | false | 3.546562 | false | false | false |
blurrcat/detalytics-util | util/celery_utils.py | 1 | 1143 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
from celery import Celery
from raven.contrib.celery import CeleryFilter, register_signal
from raven.handlers.logging import SentryHandler
def create_celery(app, name=None):
celery = Celery(name or app.name, broker=app.config['CELERY_BROKER_URL'])
for k in app.conf... | gpl-2.0 | 1,802,113,471,490,336,000 | 29.891892 | 77 | 0.653543 | false | 3.848485 | false | false | false |
rosenvladimirov/addons | hw_BA6xVFD_display/controllers/main.py | 1 | 8028 | # -*- encoding: utf-8 -*-
##############################################################################
#
# Hardware Customer Display module for Odoo
# Copyright (C) 2014 Akretion (http://www.akretion.com)
# @author Alexis de Lattre <alexis.delattre@akretion.com>
#
# This program is free software: you can ... | agpl-3.0 | -433,307,929,389,242,700 | 37.596154 | 123 | 0.569756 | false | 3.939156 | false | false | false |
CiscoSystems/project-config-third-party | playbooks/roles/configure-ucsm/files/configure_ucsm.py | 1 | 1924 | import argparse
import sys
from ucsmsdk.ucshandle import UcsHandle
from ucsmsdk.mometa.ls.LsServer import LsServer
from ucsmsdk.mometa.vnic.VnicEther import VnicEther
from ucsmsdk.mometa.vnic.VnicEtherIf import VnicEtherIf
from ucsmsdk.mometa.vnic.VnicFcNode import VnicFcNode
parser = argparse.ArgumentParser()
parser... | apache-2.0 | -1,921,369,147,331,768,300 | 28.151515 | 77 | 0.665281 | false | 3.029921 | false | false | false |
rdio/sentry | src/sentry/utils/javascript.py | 1 | 6098 | """
sentry.utils.javascript
~~~~~~~~~~~~~~~~~~~~~~~
:copyright: (c) 2010-2013 by the Sentry Team, see AUTHORS for more details.
:license: BSD, see LICENSE for more details.
"""
import time
from collections import defaultdict
from django.core.urlresolvers import reverse
from django.utils.html import escape
from sent... | bsd-3-clause | -8,828,484,508,649,032,000 | 33.647727 | 97 | 0.575927 | false | 4.07893 | false | false | false |
couchbase/couchbase-python-client | couchbase/tests_v3/cases/cluster_t.py | 1 | 17520 | # -*- coding:utf-8 -*-
#
# Copyright 2020, Couchbase, 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 re... | apache-2.0 | 589,502,191,120,723,800 | 44.154639 | 107 | 0.650457 | false | 4.118477 | true | false | false |
SCSSoftware/BlenderTools | addon/io_scs_tools/internals/shaders/flavors/blend_add.py | 1 | 2792 | # ##### BEGIN GPL LICENSE BLOCK #####
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed ... | gpl-2.0 | -924,679,898,934,089,100 | 34.794872 | 87 | 0.708095 | false | 3.451174 | false | false | false |
blabla1337/skf-flask | skf/api/chatbot/scripts/entity_classifier1.py | 1 | 1927 | import re
from skf.api.chatbot.scripts import entity_reco
vulndict=entity_reco.entity_data()
vulndict = {k.lower(): v for k, v in vulndict.items()}
punctuations = '''!()-[]{};:'"\,<>./?@#$%^&*_~'''
def entity_recognizer(sentence):
listofWords = re.findall(r"[\w']+|[.,!?;]", sentence)
copyofWords=[... | agpl-3.0 | 678,272,518,559,147,500 | 29.622951 | 74 | 0.512714 | false | 3.063593 | false | false | false |
HeraldStudio/HeraldAppApi | mod/huati/TopicHandler.py | 1 | 5097 | # -*- coding: utf-8 -*-
''' hxc 5-29 20:00 查询所有活动'''
import json
from sqlalchemy import desc
#import timestamp
from mod.databases.tables import Tcomment
from mod.Basehandler import BaseHandler
from TopicFuncs import TopicFuncs
from mod.huati.getUserInfo import User_info_handler
class TopicHandler(BaseHandler): # 处... | mpl-2.0 | -709,010,849,681,809,900 | 34.183206 | 101 | 0.530484 | false | 2.9338 | false | false | false |
xerxii/Python_Toolbox | python_tools.py | 1 | 6643 | #! /usr/bin/env python3.6
# -*- coding: utf-8 -*-
# This file was never intended for use in a production based program
# It is a collection of functions/classes to use in an interpreter such as iPython
#
# Some modules such as aiohttp have C implementations not under GPL
# Anything which is GPL compatible assumes GPL ... | agpl-3.0 | 2,441,320,779,249,936,000 | 32.720812 | 161 | 0.652868 | false | 3.470742 | false | false | false |
mypinballs/whirlwind | moonlight.py | 1 | 19768 | #Moonlight Madness Mode
import procgame
import locale
import random
import logging
import audits
from procgame import *
from drops import *
from tornado import *
from cellar import *
base_path = config.value_for_key_path('base_path')
game_path = base_path+"games/whirlwind/"
speech_path = game_path +"speech/"
sound_pa... | gpl-3.0 | 8,515,016,986,676,374,000 | 36.36862 | 217 | 0.576639 | false | 3.711603 | false | false | false |
OCA/connector-interfaces | connector_importer/utils/report_html.py | 1 | 4331 | # Author: Simone Orsi
# Copyright 2018 Camptocamp SA
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
import json
EXAMPLEDATA = {
"last_summary": {
"updated": 0, "skipped": 584, "errors": 0, "created": 414
},
"errors": [],
"last_start": "08/03/2018 13:46",
"skipped": [
... | agpl-3.0 | 2,341,606,606,350,058,000 | 29.935714 | 76 | 0.516971 | false | 3.766087 | false | false | false |
trendelkampschroer/PyEMMA | pyemma/coordinates/tests/test_stride.py | 1 | 5322 |
# Copyright (c) 2015, 2014 Computational Molecular Biology Group, Free University
# Berlin, 14195 Berlin, Germany.
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# * Redistributions of source... | bsd-2-clause | 180,143,960,535,788,700 | 39.318182 | 107 | 0.623826 | false | 3.769122 | true | false | false |
thunderox/Minaton | build/c4che/_cache.py | 1 | 1477 | AR = ['/usr/bin/ar']
ARFLAGS = ['rcs']
BINDIR = '/usr/local/bin'
CC = ['/usr/bin/gcc']
CCLNK_SRC_F = []
CCLNK_TGT_F = ['-o']
CC_NAME = 'gcc'
CC_SRC_F = []
CC_TGT_F = ['-c', '-o']
CC_VERSION = ('4', '8', '4')
CFLAGS = ['-I/home/cypher-thor/nicks/audio-programming/Minaton', '-DNDEBUG', '-fshow-column', '-std=c99']
CFLAGS... | gpl-2.0 | -6,613,923,642,623,569,000 | 26.867925 | 105 | 0.628301 | false | 2.275809 | false | true | false |
ComputerNetworksExp2016/weibo-exp | getFollowers.py | 1 | 1080 | from pathlib import Path
import pickle
from weibo.weibo import Weibo
DATA_FILE = 'followers.pickle'
if Path(DATA_FILE).exists():
followers = pickle.load(open(DATA_FILE, 'rb'))
# for l in data:
# print(l)
else:
exit()
count = {
'location': {},
'age': {},
'gender': {}
}
for i in followers:
user ... | mit | -7,608,866,785,385,554,000 | 14.428571 | 50 | 0.584259 | false | 2.559242 | false | false | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.