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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
cpdean/sqlalchemy-bigquery | sqlalchemy_bigquery/base.py | 1 | 2701 | """
Support for Google BigQuery.
Does not support actually connecting to BQ.
Directly derived from the mssql dialect with minor modifications
"""
import sqlalchemy.dialects.mssql.base as mssql_base
from sqlalchemy.dialects.mssql.base import MSDialect
from sqlalchemy.sql import compiler
from sqlalchemy.sql import sql... | mit | -109,448,852,808,508,160 | 27.135417 | 81 | 0.593484 | false | 4.055556 | false | false | false |
nickmeharry/django-mysql | django_mysql/models/fields/lists.py | 1 | 7795 | # -*- coding:utf-8 -*-
from __future__ import (
absolute_import, division, print_function, unicode_literals
)
from django.core import checks
from django.db.models import CharField, IntegerField, Lookup, TextField
from django.utils import six
from django.utils.translation import ugettext_lazy as _
from django_mysq... | bsd-3-clause | -5,785,116,181,025,149,000 | 32.170213 | 79 | 0.540475 | false | 4.31856 | false | false | false |
c4sc/arividam | arividam/djangocms_news/migrations/0003_auto_20170218_2159.py | 1 | 1393 | # -*- coding: utf-8 -*-
# Generated by Django 1.9.12 on 2017-02-18 16:29
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
import djangocms_text_ckeditor.fields
import filer.fields.image
class Migration(migrations.Migration):
dependencies = [
... | mit | 5,029,275,819,570,105,000 | 37.694444 | 218 | 0.643934 | false | 3.79564 | false | false | false |
guyemerson/pyphon | src/pyphon.py | 1 | 3033 | #!/usr/bin/env python2
import wx, os, sqlite3
import wxGUI
wx.USE_UNICODE = 1
SRC_DIR = os.getcwd()
DATA_DIR = os.path.join(os.path.split(SRC_DIR)[0], 'data')
def filepath(text):
""" If text contains no slashes, add the default data directory """
directory, filename = os.path.split(text)
if director... | gpl-3.0 | 8,069,458,571,730,618,000 | 28.656566 | 99 | 0.648863 | false | 3.482204 | false | false | false |
umass-forensics/Yapr-forensics | yapr/yapr_scan.py | 1 | 6163 | """
This script attempts to determine important characteristics of a Yaffs phone image.
Ideally, this functionality will be incorporated into a new version of the Yaffs parser.
"""
__author__ = 'wallsr'
import argparse
import os
from . import utilities
from .YaffsClasses.YaffsChunk import YaffsHeader
from .YaffsCla... | gpl-2.0 | -7,580,820,317,265,886,000 | 28.917476 | 108 | 0.602304 | false | 3.623163 | false | false | false |
nthall/pip | pip/index.py | 1 | 37111 | """Routines related to PyPI, indexes"""
from __future__ import absolute_import
import logging
import cgi
from collections import namedtuple
import itertools
import sys
import os
import re
import mimetypes
import posixpath
import warnings
from pip._vendor.six.moves.urllib import parse as urllib_parse
from pip._vendor.... | mit | -1,062,880,060,406,941,300 | 34.546935 | 79 | 0.554391 | false | 4.390795 | false | false | false |
kentaro0919/billing | app/entries/forms.py | 1 | 1990 | """doc."""
import wtforms
from wtforms.validators import DataRequired
from models import Entry, Tag
class ImageForm(wtforms.Form):
file = wtforms.FileField('Image file')
class TagField(wtforms.StringField):
"""doc."""
def _value(self):
"""doc."""
if self.data:
# Display tag... | mit | 1,626,705,362,889,400,300 | 26.638889 | 77 | 0.58392 | false | 3.98 | false | false | false |
chemelnucfin/tensorflow | tensorflow/python/keras/regularizers_test.py | 1 | 7803 | # Copyright 2016 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... | apache-2.0 | -3,927,156,256,061,779,000 | 37.438424 | 80 | 0.670768 | false | 3.639459 | true | false | false |
Ictp/indico | indico/MaKaC/common/log.py | 1 | 8114 | # -*- coding: utf-8 -*-
##
##
## This file is part of Indico.
## Copyright (C) 2002 - 2014 European Organization for Nuclear Research (CERN).
##
## Indico 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; eith... | gpl-3.0 | -8,128,992,374,017,895,000 | 30.449612 | 83 | 0.599704 | false | 3.902838 | false | false | false |
palankai/baluster | tests/test_nested.py | 1 | 1212 | from baluster import Baluster, placeholders
class CompositeRoot(Baluster):
@placeholders.factory
def value(self, root):
return 2
class subns(Baluster):
_closed = False
@placeholders.factory
def value(self, root):
return 1
@value.close
def cl... | mit | 7,758,543,138,161,990,000 | 19.896552 | 47 | 0.578383 | false | 3.823344 | false | false | false |
crossroadchurch/paul | openlp/core/ui/settingsdialog.py | 1 | 3292 | # -*- coding: utf-8 -*-
# vim: autoindent shiftwidth=4 expandtab textwidth=120 tabstop=4 softtabstop=4
###############################################################################
# OpenLP - Open Source Lyrics Projection #
# ------------------------------------------------------... | gpl-2.0 | -6,551,662,760,534,454,000 | 51.253968 | 92 | 0.559538 | false | 4.617111 | false | false | false |
icereval/scrapi | scrapi/base/__init__.py | 1 | 6929 | # Classes for scrAPI Harvesters
from __future__ import unicode_literals
import abc
import json
import logging
from datetime import timedelta, date
from lxml import etree
from scrapi import util
from scrapi import requests
from scrapi import registry
from scrapi import settings
from scrapi.base.schemas import OAISCHE... | apache-2.0 | -8,320,974,376,876,299,000 | 31.530516 | 102 | 0.625487 | false | 3.921336 | false | false | false |
tchellomello/home-assistant | homeassistant/components/template/trigger.py | 1 | 3430 | """Offer template automation rules."""
import logging
import voluptuous as vol
from homeassistant import exceptions
from homeassistant.const import CONF_FOR, CONF_PLATFORM, CONF_VALUE_TEMPLATE
from homeassistant.core import callback
from homeassistant.helpers import config_validation as cv, template
from homeassistan... | apache-2.0 | 9,030,021,066,005,904,000 | 28.568966 | 84 | 0.560933 | false | 4.330808 | false | false | false |
daniel-j/lutris | lutris/runners/__init__.py | 1 | 2119 | """Generic runner functions."""
# from lutris.util.log import logger
__all__ = (
# Native
"linux",
"steam",
"browser",
"web",
# Microsoft based
"wine",
"winesteam",
"dosbox",
# Multi-system
"mame",
"mess",
"mednafen",
"scummvm",
"residualvm",
"libretro",
... | gpl-3.0 | 6,627,909,325,748,285,000 | 19.375 | 80 | 0.583766 | false | 3.379585 | false | false | false |
Diti24/python-ivi | ivi/agilent/agilent3000A.py | 1 | 6792 | """
Python Interchangeable Virtual Instrument Library
Copyright (c) 2012-2016 Alex Forencich
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the... | mit | 3,845,266,033,228,307,500 | 34.375 | 100 | 0.633687 | false | 3.557884 | false | false | false |
HazyResearch/metal | metal/contrib/info_extraction/mentions.py | 1 | 6222 | import numpy as np
class EntityMention(object):
"""A mention of an entity (span of text) in a document
Args:
doc_id: a unique identifier for the document
text: a single string of text corresponding to the document
char_start: the integer offset of the first character in the entity
... | apache-2.0 | 566,391,379,007,993,200 | 33.759777 | 81 | 0.613468 | false | 4.06401 | false | false | false |
SnakeHunt2012/word2vec | word-word/word-word.py | 1 | 3317 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
from sys import stdout
from codecs import open
from json import loads
from numpy import zeros, dot, sqrt
from argparse import ArgumentParser
from heapq import nlargest
import cudamat as cm
def debug(debug_str):
stdout.write(debug_str)
stdout.flush()
def load_vec... | apache-2.0 | -9,172,534,614,930,218,000 | 32.505051 | 93 | 0.586675 | false | 3.582073 | false | false | false |
bearstech/modoboa | modoboa/lib/form_utils.py | 1 | 12669 | # coding: utf-8
"""Form management utilities."""
from __future__ import unicode_literals
import abc
from collections import OrderedDict
import re
from django.forms import TypedChoiceField
from django.forms.fields import Field
from django.forms.widgets import RadioSelect
from django.forms.widgets import RadioChoiceI... | isc | 2,693,508,765,597,406,000 | 28.462791 | 79 | 0.546926 | false | 4.155133 | false | false | false |
dnbaker/emp | python/hll_sketch.py | 1 | 1366 | import argparse
import os
import shlex
import subprocess
import multiprocessing
import sys
def sketch_call(tup):
ss, ks, paths = tup
cstr = "flashdans sketch -p1 -k%i -S%i %s" % (ss, ks, " ".join(paths))
subprocess.check_call(shlex.split(cstr))
if __name__ == "__main__":
sketch_range = range(10, 24,... | gpl-3.0 | 9,033,839,705,742,966,000 | 34.947368 | 78 | 0.606149 | false | 3.53886 | false | false | false |
tanghaibao/goatools | goatools/cli/docopt_parse.py | 1 | 3852 | """Run docopt in GOATOOLS."""
from __future__ import print_function
__copyright__ = "Copyright (C) 2016-present, DV Klopfenstein, H Tang, All rights reserved."
__author__ = "DV Klopfenstein"
import sys
import re
from docopt import docopt
from goatools.gosubdag.utils import get_kwargs
#pylint: disable=too-few-publi... | bsd-2-clause | 713,140,892,205,950,200 | 38.306122 | 100 | 0.570872 | false | 3.546961 | false | false | false |
uclapi/uclapi | backend/uclapi/roombookings/models.py | 1 | 8730 | from __future__ import unicode_literals
from django.db import models
models.options.DEFAULT_NAMES += ('_DATABASE',)
class Booking(models.Model):
setid = models.CharField(max_length=40, blank=True, null=True)
siteid = models.CharField(max_length=40, blank=True, null=True)
roomid = models.CharField(max_l... | mit | -4,850,903,556,800,862,000 | 46.967033 | 77 | 0.716266 | false | 3.279489 | false | false | false |
rogeriofalcone/treeio | services/forms.py | 1 | 24922 | # encoding: utf-8
# Copyright 2011 Tree.io Limited
# This file is part of Treeio.
# License www.tree.io/license
"""
Services module forms
"""
from django import forms
from django.db.models import Q
from django.core.urlresolvers import reverse
from django.utils.translation import ugettext as _
from django.utils.html im... | mit | -6,035,473,457,789,518,000 | 45.066543 | 128 | 0.566367 | false | 4.477542 | false | false | false |
mvo5/snapcraft | snapcraft/plugins/kbuild.py | 1 | 9392 | # -*- Mode:Python; indent-tabs-mode:nil; tab-width:4 -*-
#
# Copyright (C) 2016-2017 Canonical Ltd
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 3 as
# published by the Free Software Foundation.
#
# This program is distributed in ... | gpl-3.0 | 2,984,809,691,852,066,300 | 36.12253 | 88 | 0.627449 | false | 4.090592 | true | false | false |
sliwhu/UWHousingTeam | model/house_price_model.py | 1 | 6622 | """
Contains the house price model.
DON'T USE THIS MODEL! Use the HousePriceModel in house_price_model_2.py.
"""
import os
import numpy as np
import pandas as pd
from sklearn.ensemble import RandomForestRegressor
from sklearn.linear_model import RidgeCV
# Constants
BASE_DATE = pd.to_datetime('20140101', format='%Y%... | mit | 3,879,649,261,701,865,000 | 35.788889 | 92 | 0.663546 | false | 3.52797 | false | false | false |
elastic-event-components/e2c | source/python/e2c.examples/web_mud/contracts/token.py | 1 | 1166 | #
# Copyright 2017 The E2C Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable l... | apache-2.0 | -590,398,240,472,339,600 | 24.911111 | 80 | 0.598628 | false | 3.72524 | false | false | false |
ThomasZh/legend-league-portal | foo/auth/auth_newsup.py | 1 | 3243 | #!/usr/bin/env python
# _*_ coding: utf-8_*_
#
# Copyright 2016 7x24hs.com
# thomas@7x24hs.com
#
# 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... | apache-2.0 | 3,766,114,325,257,546,000 | 30.673267 | 108 | 0.66427 | false | 3.5783 | false | false | false |
renatopp/liac | liac/dataset/__init__.py | 1 | 3050 | # =============================================================================
# Federal University of Rio Grande do Sul (UFRGS)
# Connectionist Artificial Intelligence Laboratory (LIAC)
# Renato de Pontes Pereira - rppereira@inf.ufrgs.br
# =============================================================================
... | mit | -752,506,588,079,396,900 | 36.654321 | 79 | 0.644918 | false | 3.875476 | false | false | false |
thanatoskira/AndroGuard | elsim/elsim/elsim_db.py | 1 | 7471 | #!/usr/bin/env python
# This file is part of Elsim.
#
# Copyright (C) 2012, Anthony Desnos <desnos at t0t0.fr>
# All rights reserved.
#
# Elsim is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation, either ve... | lgpl-3.0 | -4,021,871,903,078,052,400 | 29.373984 | 148 | 0.504752 | false | 3.691206 | false | false | false |
Maaack/Silent-Night-API | game_api/migrations/0002_auto_20160207_1603.py | 1 | 1928 | # -*- coding: utf-8 -*-
# Generated by Django 1.9.2 on 2016-02-08 00:03
from __future__ import unicode_literals
import django.contrib.postgres.fields.jsonb
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('game_api', '0001... | gpl-3.0 | -5,922,265,363,484,232,000 | 36.803922 | 114 | 0.547718 | false | 4.432184 | false | false | false |
DBWangGroupUNSW/revs | revs/entity.py | 1 | 1871 | from elasticsearch.helpers import bulk
class EntityDoc:
def __init__(self, name, uri, num_occ):
self.name = name
self.uri = uri
self.num_occ = num_occ
class EntityIndexer:
def __init__(self, config, elastic_search):
self._config = config
self._elastic_search = elastic... | mit | 6,968,993,648,632,724,000 | 28.698413 | 89 | 0.377873 | false | 4.665835 | false | false | false |
racetted/maestro-utils | bin/task_setup.py | 1 | 50921 | #!/usr/bin/env python
#/* Part of the Maestro sequencer software package.
# * Copyright (C) 2011-2015 Canadian Meteorological Centre
# * Environment Canada
# *
# * Maestro is free software; you can redistribute it and/or
# * modify it under the terms of the GNU Lesser General Public
# * Licen... | lgpl-2.1 | -177,184,573,625,039,000 | 46.368372 | 184 | 0.50814 | false | 4.576757 | true | false | false |
jbmouret/limbo | src/tutorials/ros.py | 2 | 1325 | #! /usr/bin/env python
# encoding: utf-8
# to be put in your experiment's directory
import os
from waflib.Configure import conf
def options(opt):
opt.add_option('--ros', type='string', help='path to ros', dest='ros')
@conf
def check_ros(conf):
if conf.options.ros:
includes_check = [conf.options.ros + '/incl... | gpl-3.0 | 5,223,864,863,413,622,000 | 31.317073 | 132 | 0.643019 | false | 3.074246 | false | false | false |
ifiddes/pycbio | pycbio/sys/dbDict.py | 1 | 3316 | # Copyright 2006-2012 Mark Diekhans
# Copyright sebsauvage.net
"""
Code from:
http://sebsauvage.net/python/snyppets/index.html#dbdict
A dictionnary-like object for LARGE datasets
Python dictionnaries are very efficient objects for fast data access. But when data is too large to fit in memory, you're in trouble.
Here'... | bsd-3-clause | -6,402,318,023,815,042,000 | 43.810811 | 133 | 0.658625 | false | 3.763905 | false | false | false |
tdsimao/tt | algoritmos/algGenetico-backup.py | 1 | 12029 | # -*- coding: utf-8 -*-
from celulas.models import Celula, Encontro
from random import choice, random, sample
from time import time
from src.variaveisGlobais import pesos
class CelulaAlg(Celula):
"""
classe criada para acumular lista de encontros sem salva-los
e editar o metodo save() permitindo ... | gpl-2.0 | 9,191,960,471,433,302,000 | 32.157459 | 267 | 0.5994 | false | 3.144354 | false | false | false |
specify/specify7 | specifyweb/context/schema_localization.py | 1 | 2364 | from collections import defaultdict
import json
from django.conf import settings
from django.db import connection
from specifyweb.specify.models import (
Splocalecontainer as Container,
Splocalecontaineritem as Item,
Splocaleitemstr as SpString)
schema_localization_cache = {}
def get_schema_localization... | gpl-2.0 | -2,763,643,266,562,375,700 | 41.981818 | 122 | 0.713198 | false | 3.60916 | false | false | false |
sedouard/scaleio-flocker-driver | scaleio_flocker_driver/__init__.py | 1 | 1317 | # Copyright 2015 EMC Corporation
from flocker.node import BackendDescription, DeployerType
from .emc_sio import (
scaleio_from_configuration, DEFAULT_STORAGE_POOL,
DEFAULT_PROTECTION_DOMAIN, DEFAULT_PORT, DEBUG
)
def api_factory(cluster_id, **kwargs):
protection_domain = DEFAULT_PROTECTION_DOMAIN
if ... | apache-2.0 | -3,388,212,268,403,209,700 | 32.769231 | 90 | 0.678815 | false | 3.762857 | false | false | false |
larrylindsey/reconstructmergetool | build/lib.linux-x86_64-2.7/pyrecon/toolsgui/excelTool.py | 1 | 4104 | #!/usr/bin/env python
import sys, os
from pyrecon.tools import excelTool
from PySide import QtGui, QtCore
class excelToolWindow(QtGui.QWidget):
def __init__(self, parent = None):
QtGui.QWidget.__init__(self, parent)
self.parent = parent
self.setGeometry(0,0,500,200)
self.se... | gpl-3.0 | 3,869,149,202,501,233,000 | 35.327434 | 102 | 0.570906 | false | 4.261682 | false | false | false |
hjhsalo/reana-server | reana_server/api_client.py | 1 | 1852 | # -*- coding: utf-8 -*-
#
# This file is part of REANA.
# Copyright (C) 2017 CERN.
#
# REANA 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
# ver... | gpl-2.0 | 6,410,380,712,022,820,000 | 30.931034 | 79 | 0.692765 | false | 3.8826 | false | false | false |
dontnod/weblate | weblate/accounts/migrations/0012_auto_20190805_1248.py | 1 | 1517 | # Generated by Django 2.2.3 on 2019-08-05 12:48
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [("accounts", "0011_auto_20190721_1810")]
operations = [
migrations.AlterField(
model_name="subscription",
name="notification",
... | gpl-3.0 | -129,581,008,454,388,270 | 42.342857 | 83 | 0.54911 | false | 4.941368 | false | false | false |
samuto/ladybug | src/Ladybug_Open EPW Weather File.py | 1 | 1873 | # Open Weather data file
#
# Ladybug: A Plugin for Environmental Analysis (GPL) started by Mostapha Sadeghipour Roudsari
#
# This file is part of Ladybug.
#
# Copyright (c) 2013-2015, Mostapha Sadeghipour Roudsari <Sadeghipour@gmail.com>
# Ladybug is free software; you can redistribute it and/or modify
# it... | gpl-3.0 | 6,968,332,342,942,576,000 | 33.339623 | 93 | 0.697811 | false | 3.126878 | false | false | false |
taschik/ramcloud | scripts/log.py | 1 | 2528 | #!/usr/bin/env python
# Copyright (c) 2010 Stanford University
#
# Permission to use, copy, modify, and distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
#
# THE SOFTWARE IS PROVIDED "AS IS" AND T... | isc | 2,893,362,188,098,615,300 | 32.706667 | 76 | 0.615902 | false | 4.328767 | false | false | false |
lhfei/spark-in-action | spark-2.x/src/main/python/mllib/svd_example.py | 1 | 1821 | #
# 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 n... | apache-2.0 | 8,269,495,635,788,406,000 | 35.9375 | 77 | 0.666118 | false | 3.613095 | false | false | false |
JeroenZegers/Nabu-MSSS | nabu/neuralnetworks/loss_computers/pit_noise_loss.py | 1 | 1142 | """@file pit_noise_loss.py
contains the PITNoiseLoss"""
import loss_computer
from nabu.neuralnetworks.components import ops
class PITNoiseLoss(loss_computer.LossComputer):
"""A loss computer that calculates the loss"""
def __call__(self, targets, logits, seq_length):
"""
Compute the loss
Creates the operat... | mit | -1,165,106,504,995,643,600 | 29.052632 | 104 | 0.71979 | false | 3.481707 | false | false | false |
cmusatyalab/opendiamond | opendiamond/blaster/cache.py | 1 | 5375 | #
# The OpenDiamond Platform for Interactive Search
#
# Copyright (c) 2011-2012 Carnegie Mellon University
# All rights reserved.
#
# This software is distributed under the terms of the Eclipse Public
# License, Version 1.0 which can be found in the file named LICENSE.
# ANY USE, REPRODUCTION OR DISTRIBUTION OF T... | epl-1.0 | 6,612,470,580,327,325,000 | 30.617647 | 76 | 0.611535 | false | 3.814762 | false | false | false |
c4fcm/CivilServant | alembic/versions/960085fce39c_generating_migration_for_a_praw_object.py | 1 | 2408 | """Generating migration for a PRAW object
Revision ID: 960085fce39c
Revises: 4d46b88366fc
Create Date: 2016-06-13 17:30:49.056215
"""
# revision identifiers, used by Alembic.
revision = '960085fce39c'
down_revision = '4d46b88366fc'
branch_labels = None
depends_on = None
from alembic import op
import sqlalchemy as s... | mit | -8,745,198,961,622,810,000 | 27.329412 | 63 | 0.66113 | false | 3.5 | false | false | false |
TribeMedia/synapse | synapse/rest/media/v1/upload_resource.py | 2 | 3506 | # -*- coding: utf-8 -*-
# Copyright 2014-2016 OpenMarket Ltd
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicab... | apache-2.0 | 7,054,650,231,856,196,000 | 32.711538 | 79 | 0.625214 | false | 4.105386 | false | false | false |
kata-csc/ckanext-oaipmh | docs/conf.py | 1 | 8464 | # -*- coding: utf-8 -*-
#
# Kata documentation build configuration file, created by
# sphinx-quickstart on Tue Jul 15 10:01:47 2014.
#
# This file is execfile()d with the current directory set to its
# containing dir.
#
# Note that not all possible configuration values are present in this
# autogenerated file.
#
# All ... | agpl-3.0 | 1,165,127,676,307,662,300 | 29.890511 | 79 | 0.70345 | false | 3.662484 | true | false | false |
cgart/photobooth | mainapp/preview.py | 1 | 2172 | import piggyphoto
from kivy.uix.widget import Widget
from kivy.properties import StringProperty
from kivy.properties import NumericProperty
from kivy.properties import ListProperty, ObjectProperty
from kivy.core.image import Image as CoreImage
from kivy.uix.image import Image
# ------------------------------... | mit | -8,266,618,033,812,970,000 | 30.941176 | 75 | 0.445212 | false | 5.641558 | false | false | false |
HaroldMills/Vesper | vesper/mpg_ranch/nfc_bounding_interval_annotator_1_0/annotator.py | 1 | 7220 | """
Module containing NFC bounding interval annotator, version 1.0.
An NFC bounding interval annotator sets values for the `Call Start Index`
and `Call End Index` annotations for a clip containing a nocturnal flight
call (NFC). If the annotations already exist their values are overwritten,
and if they do not already e... | mit | -6,382,661,020,857,981,000 | 31.232143 | 79 | 0.571884 | false | 3.975771 | false | false | false |
sherpya/archiver | setup_all.py | 1 | 2040 | #!/usr/bin/env python
# -*- Mode: Python; tab-width: 4 -*-
#
# Netfarm Mail Archiver - release 2
#
# Copyright (C) 2005-2007 Gianluigi Tiesi <sherpya@netfarm.it>
# Copyright (C) 2005-2007 NetFarm S.r.l. [http://www.netfarm.it]
#
# This program is free software; you can redistribute it and/or modify
# it under the term... | gpl-2.0 | -6,462,490,321,913,439,000 | 27.732394 | 93 | 0.633333 | false | 3.238095 | false | false | false |
ragupta-git/ImcSdk | imcsdk/mometa/storage/StorageLocalDiskEp.py | 1 | 1913 | """This module contains the general information for StorageLocalDiskEp ManagedObject."""
from ...imcmo import ManagedObject
from ...imccoremeta import MoPropertyMeta, MoMeta
from ...imcmeta import VersionMeta
class StorageLocalDiskEpConsts:
pass
class StorageLocalDiskEp(ManagedObject):
"""This is StorageLo... | apache-2.0 | 8,475,116,203,333,382,000 | 34.425926 | 215 | 0.592263 | false | 3.503663 | false | false | false |
joharei/plasma-netctl | contents/code/netctl.py | 1 | 2541 | # -*- coding: utf-8 -*-
#
# Author: Johan Reitan <johan.reitan@gmail.com>
# Date: Sat Jan 18 2014, 17:03:40
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU Library General Public License as
# published by the Free Software Foundation; either version 2, or
# (at y... | gpl-3.0 | 5,458,483,675,457,180,000 | 32 | 73 | 0.706415 | false | 3.614509 | false | false | false |
rudhir-upretee/Sumo17_With_Netsim | tools/net/batch0103to0110.py | 1 | 1060 | #!/usr/bin/python
"""
@file batch0103to0110.py
@author Daniel Krajzewicz
@author Michael Behrisch
@date 2007
@version $Id: batch0103to0110.py 13811 2013-05-01 20:31:43Z behrisch $
Applies the transformation on all nets in the given folder or
- if no folder is given - in the base folder (../..).
SUMO, Simula... | gpl-3.0 | -8,821,300,692,409,846,000 | 31.121212 | 85 | 0.616981 | false | 3.028571 | false | false | false |
ejspina/Gene_expression_tools | Python/fasta_transcript2gene.py | 1 | 1865 | #-------------------------------------------------------------------------------
# Name: module1
# Purpose:
#
# Author: Eli
#
# Created: 18/12/2013
# Copyright: (c) Eli 2013
# Licence: <your licence>
#-------------------------------------------------------------------------------
def m... | gpl-2.0 | 1,572,774,385,450,864,000 | 30.155172 | 235 | 0.510456 | false | 3.685771 | false | false | false |
OpenDaisy/daisy-api | daisy/api/v1/config_sets.py | 1 | 17500 | # Copyright 2013 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.apache.org/licenses/LICENSE-2.0
#
# Unless requ... | apache-2.0 | -2,054,898,294,051,990,000 | 39.322581 | 107 | 0.571771 | false | 4.305043 | true | false | false |
fmonjalet/miasm | miasm2/ir/ir.py | 1 | 11474 | #!/usr/bin/env python
#-*- coding:utf-8 -*-
#
# Copyright (C) 2013 Fabrice Desclaux
#
# 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 ... | gpl-2.0 | 2,692,302,315,748,242,000 | 32.846608 | 81 | 0.531811 | false | 3.54464 | false | false | false |
OliverWalter/amdtk | amdtk/models/normal_gamma.py | 1 | 2962 |
""" Normal-Gamma density."""
import numpy as np
from scipy.special import gammaln, psi
class NormalGamma(object):
"""Normal-Gamma density.
Attributes
----------
mu : numpy.ndarray
Mean of the Gaussian density.
kappa : float
Factor of the precision matrix.
alpha : float
... | bsd-2-clause | 3,954,424,811,886,270,000 | 26.425926 | 83 | 0.540176 | false | 3.831824 | false | false | false |
jpwilliams/appenlight-client-python | appenlight_client/timing/__init__.py | 1 | 7630 | from __future__ import absolute_import
import logging
import time
import threading
from appenlight_client.utils import import_from_module
from datetime import datetime, timedelta
from functools import wraps
from operator import itemgetter
default_timer = time.time
class AppenlightLocalStorage(object):
def __in... | bsd-3-clause | 8,553,453,150,697,994,000 | 33.524887 | 82 | 0.554391 | false | 3.986416 | false | false | false |
marchon/flask-virtualenv | setup.py | 1 | 1029 | #!/usr/bin/env python
"""
https://github.com/imlucas/flask-virtualenv
"""
from setuptools import setup
setup(
name='Flask-Virtualenv',
version='0.2.0',
url='http://imlucas.com',
license='BSD',
author='Lucas Hrabovsky',
author_email='hrabovsky.lucas@gmail.com',
description='Manage a virtual... | bsd-3-clause | -7,406,923,368,084,122,000 | 27.583333 | 70 | 0.608358 | false | 3.897727 | false | false | false |
sonoble/fboss | fboss/agent/tools/fboss_route.py | 1 | 6527 | #!/usr/bin/env python
# Copyright (C) 2004-present Facebook. All Rights Reserved
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals
from __future__ import absolute_import
"""Add, change, or delete a route on FBOSS controller
"""
import contextlib
import ipad... | bsd-3-clause | -2,916,868,972,458,586,000 | 33.718085 | 77 | 0.655278 | false | 3.644333 | false | false | false |
drpaneas/linuxed.gr | plugins/simple_footnotes.py | 1 | 4382 | from pelican import signals
import re
import html5lib
RAW_FOOTNOTE_CONTAINERS = ["code"]
def getText(node, recursive = False):
"""Get all the text associated with this node.
With recursive == True, all text from child nodes is retrieved."""
L = ['']
for n in node.childNodes:
if n.nodeType i... | mit | -472,941,587,506,048,000 | 47.164835 | 126 | 0.527385 | false | 4.270955 | false | false | false |
piratos/ctfbulletin | ctfbulletin/settings.py | 1 | 2533 | """
Django settings for ctfbulletin project.
For more information on this file, see
https://docs.djangoproject.com/en/1.6/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/1.6/ref/settings/
"""
# Build paths inside the project like this: os.path.join(BASE_DIR, ...... | mit | 1,901,026,166,474,514,200 | 23.365385 | 74 | 0.684564 | false | 3.222646 | false | false | false |
davcastroruiz/boston-django-project | webSite/repo/migrations/0002_auto_20170224_1612.py | 1 | 1210 | # -*- coding: utf-8 -*-
# Generated by Django 1.10.5 on 2017-02-24 22:12
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('repo', '0001_initial'),
]
operations = [
m... | gpl-3.0 | -8,792,082,569,611,806,000 | 27.809524 | 114 | 0.538017 | false | 4.230769 | false | false | false |
slivkamiro/sample_kafka_producer | src/sample_source_props.py | 1 | 7278 | from random import randint
def random_movie():
return movies_list[randint(0, movies_list_length - 1)]
def random_series():
return seasons_list[randint(0, seasons_list_length - 1)]
def random_user():
user_data = user_list[randint(0, user_list_length - 1)]
return {'email': user_data[0], 'name': user_da... | apache-2.0 | 8,245,845,420,224,092,000 | 31.783784 | 111 | 0.590409 | false | 2.826408 | false | false | false |
freelancer/freelancer-sdk-python | examples/create_employer_review.py | 1 | 1087 | from freelancersdk.session import Session
from freelancersdk.resources.projects.projects import post_review
from freelancersdk.resources.projects.helpers import \
create_review_employer_object
from freelancersdk.resources.projects.exceptions import \
ReviewNotPostedException
import os
def sample_post_review()... | lgpl-3.0 | -388,278,904,186,106,100 | 26.871795 | 65 | 0.664213 | false | 3.575658 | false | false | false |
MCopperhead/city-building | object_layer.py | 1 | 2012 | import cocos as c
from cell import Cell
from shared_data import MAP_SIZE
from objects import TestCube, Wall
class DynamicBatch(c.batch.BatchNode):
"""
Batch modification, that allows to change Z level of child object dynamically.
"""
def change_z(self, child, z):
child.set_batch(None)
... | gpl-2.0 | -6,374,275,823,120,481,000 | 30.936508 | 82 | 0.553678 | false | 3.599284 | false | false | false |
satanas/libturpial | libturpial/api/models/column.py | 1 | 1346 | # -*- coding: utf-8 -*-
class Column(object):
"""
This model represents a column that holds
:class:`libturpial.api.models.status.Status` objects. You need to specify
to what *account_id* are they associated, as well as the column *slug*.
Available column slugs are available in
:class:`libturpi... | gpl-3.0 | -3,300,106,422,524,235,300 | 35.378378 | 77 | 0.618128 | false | 3.637838 | false | false | false |
crate/crate-python | src/crate/client/sqlalchemy/tests/dict_test.py | 1 | 16645 | # -*- coding: utf-8; -*-
#
# Licensed to CRATE Technology GmbH ("Crate") under one or more contributor
# license agreements. See the NOTICE file distributed with this work for
# additional information regarding copyright ownership. Crate licenses
# this file to you under the Apache License, Version 2.0 (the "License"... | apache-2.0 | 1,422,843,196,939,603,700 | 35.502193 | 77 | 0.584019 | false | 3.801096 | true | false | false |
mmcauliffe/linguistic-helper-functions | linghelper/representations/classes.py | 1 | 4708 | import re
import copy
from linghelper.representations.constants import ENGLISH_ONSETS as ONSETS,ENGLISH_VOWEL_PATTERN as VOWEL_PATTERN
class Word(object):
def __init__(self,orthography,transcription,frequency=0):
self.orthography = orthography
self.syllables = syllabify(transcription)
sel... | gpl-3.0 | -2,131,419,134,616,865,000 | 27.533333 | 113 | 0.540782 | false | 3.65528 | false | false | false |
jknebel/STEN | PostStat.py | 1 | 23533 | import numpy as np
import tables
import wx
import os
import itertools
# ClassMultiple testing correction using mathematical morphology
##Tables definition
##
##tables:
##/Shape # Keep the shape of the Data, to reshape after calculation # simple array
##/Data/All #using createEArray('/','AllData',tables.Float6... | bsd-3-clause | -558,887,679,184,231,500 | 44.785288 | 156 | 0.490248 | false | 4.362811 | true | false | false |
liamcurry/py3kwarn | py3kwarn2to3/fixes/fix_types.py | 1 | 1707 | # Copyright 2007 Google, Inc. All Rights Reserved.
# Licensed to PSF under a Contributor Agreement.
"""Fixer for removing uses of the types module.
These work for only the known names in the types module. The forms above
can include types. or not. ie, It is assumed the module is imported either as:
import type... | mit | -5,724,285,161,513,692,000 | 25.671875 | 80 | 0.598711 | false | 3.793333 | false | false | false |
embray/PyFITS | lib/pyfits/scripts/fitscheck.py | 1 | 6708 | """
``fitscheck`` is a command line script based on pyfits for verifying and
updating the CHECKSUM and DATASUM keywords of .fits files. ``fitscheck`` can
also detect and often fix other FITS standards violations. ``fitscheck``
facilitates re-writing the non-standard checksums originally generated by
pyfits with stand... | bsd-3-clause | -3,699,447,288,446,370,300 | 29.352941 | 79 | 0.642964 | false | 4.070388 | false | false | false |
poojavade/Genomics_Docker | Dockerfiles/gedlab-khmer-filter-abund/pymodules/python2.7/lib/python/Bio/Phylo/PAML/_parse_codeml.py | 1 | 21515 | # Copyright (C) 2011 by Brandon Invergo (b.invergo@gmail.com)
# This code is part of the Biopython distribution and governed by its
# license. Please see the LICENSE file that should have been included
# as part of this package.
import re
line_floats_re = re.compile("-*\d+\.\d+")
try:
float("nan")
_nan_float... | apache-2.0 | -3,771,134,222,919,070,000 | 43.452479 | 112 | 0.557193 | false | 3.730062 | false | false | false |
ly0/xxadmin | setup.py | 1 | 1788 | #!/usr/bin/env python
from setuptools import setup
# version_tuple = __import__('xadmin.version').VERSION
# version = ".".join([str(v) for v in version_tuple])
setup(
name='django-xadmin',
version='0.5.1',
description='Drop-in replacement of Django admin comes with lots of goodies, fully extensible with p... | bsd-3-clause | -3,786,214,088,761,634,300 | 37.042553 | 158 | 0.612416 | false | 3.820513 | false | false | false |
johncheetham/jcchess | jcchess/move_list.py | 1 | 9162 | #
# move_list.py - Display Move List Window
#
# This file is part of jcchess
#
# jcchess 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 l... | gpl-3.0 | -270,891,830,651,016,260 | 36.54918 | 115 | 0.56778 | false | 3.661871 | false | false | false |
vltr/star-wars-saga | ep5/cloud_city/darth_vader_vs_luke_skywalker.py | 1 | 3146 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
import sys
import logging
import language_typology as lang_typ
import star_wars as sw
class LogFactory(object):
"""
Helper class to provide standard logging
"""
logger = None
@classmethod
def get_logger(cls):
"""
... | unlicense | -4,721,615,349,197,400,000 | 30.777778 | 72 | 0.572473 | false | 3.449561 | false | false | false |
tdubourg/velov-unchained | web.py/update_warnings.py | 1 | 1984 | # -*- coding: utf-8 -*-
import psycopg2
#Connection to database
conn = psycopg2.connect("dbname=velovunchained user=velovunchained password=velovunchained")
#Cursor used to navigate through the database
cur = conn.cursor()
#Reads the id of the last reservation action tested for the warning rules application
last_act... | gpl-3.0 | 4,164,946,664,598,484,500 | 36.396226 | 121 | 0.697123 | false | 2.87936 | false | false | false |
ufieeehw/IEEE2015 | ros/ieee2015_simulator/scripts/end_effector_sim.py | 1 | 7301 | #!/usr/bin/python
## Math
import numpy as np
## Display
import pygame
import time
import math
## Ros
import rospy
from tf import transformations as tf_trans
## Ros Msgs
from std_msgs.msg import Header, Float64, Int64
from ieee2015_end_effector_servos.msg import Num
from geometry_msgs.msg import Point, PointStamped, Pos... | gpl-2.0 | 2,497,793,503,725,792,000 | 30.61039 | 111 | 0.553486 | false | 3.505041 | false | false | false |
pseudocubic/neutronpy | neutronpy/crystal/structure_factors.py | 1 | 4806 | # -*- coding: utf-8 -*-
r"""Structure Factors
NuclearStructureFactor
MagneticStructureFactor
MagneticFormFactor
"""
import numpy as np
from ..constants import magnetic_ion_j
class NuclearStructureFactor(object):
r"""Class containing nuclear structure factor calculator
Methods
-------
calc_nuc_str_... | mit | 3,583,450,151,458,712,000 | 27.270588 | 156 | 0.512901 | false | 3.386892 | false | false | false |
levilucio/SyVOLT | ECore_Copier_MM/transformation-Large/HepackagelefteAnnotationsSolveRefEPackageEAnnotationEPackageEAnnotation.py | 1 | 5043 |
from core.himesis import Himesis
class HepackagelefteAnnotationsSolveRefEPackageEAnnotationEPackageEAnnotation(Himesis):
def __init__(self):
"""
Creates the himesis graph representing the AToM3 model HepackagelefteAnnotationsSolveRefEPackageEAnnotationEPackageEAnnotation.
"""
# Fl... | mit | -5,931,338,714,505,986,000 | 47.961165 | 298 | 0.519532 | false | 3.005364 | false | false | false |
anntzer/seaborn | seaborn/_core.py | 1 | 44884 | import warnings
import itertools
from copy import copy
from functools import partial
from collections.abc import Iterable, Sequence, Mapping
from numbers import Number
from datetime import datetime
import numpy as np
import pandas as pd
import matplotlib as mpl
from ._decorators import (
share_init_params_with_ma... | bsd-3-clause | -8,576,295,906,422,801,000 | 33.552733 | 84 | 0.563586 | false | 4.477654 | false | false | false |
strogo/turbion | turbion/bits/utils/cache/utils.py | 1 | 2422 | from django.utils.functional import curry
from django.core.cache import cache
from django.utils.encoding import smart_str
from django.utils.itercompat import is_iterable
def to_list(arg):
"""Converts `arg` to list"""
if is_iterable(arg) and not isinstance(arg, dict):
return list(arg)
else:
... | bsd-3-clause | -4,414,260,199,410,681,000 | 31.293333 | 84 | 0.490917 | false | 4.630975 | false | false | false |
galeone/dynamic-training-bench | dytb/inputs/predefined/PASCALVOC2012Classification.py | 1 | 10931 | #Copyright (C) 2017 Paolo Galeone <nessuno@nerdz.eu>
#
#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/.
#Exhibit B is not attached; this software is compatible with the
#lic... | mpl-2.0 | 2,044,158,810,422,092,500 | 40.249057 | 117 | 0.519349 | false | 4.13583 | false | false | false |
Ecogenomics/CheckM | checkm/util/img.py | 1 | 23429 | ###############################################################################
# #
# 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 ... | gpl-3.0 | 3,703,315,242,581,544,000 | 37.777589 | 154 | 0.558539 | false | 4.222963 | false | false | false |
dhrone/pydKeg | displays/winstar_weg.py | 1 | 9885 | #!/usr/bin/python
# coding: UTF-8
# Driver for Winstar WEH001602A 16x2 OLED display on the RPi
# Written by: Ron Ritchey
# Derived from Lardconcepts
# https://gist.github.com/lardconcepts/4947360
# Which was also drived from Adafruit
# http://forums.adafruit.com/viewtopic.php?f=8&t=29207&start=15#p163445
#
# Ultimatel... | mit | 3,913,770,316,773,542,000 | 24.675325 | 126 | 0.666566 | false | 2.652267 | false | false | false |
redhat-openstack/heat | heat/db/sqlalchemy/migrate_repo/versions/021_resource_data.py | 1 | 1757 | #
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# ... | apache-2.0 | 5,780,820,065,338,006,000 | 35.604167 | 78 | 0.635743 | false | 4.493606 | false | false | false |
t-wissmann/qutebrowser | qutebrowser/browser/webengine/certificateerror.py | 2 | 1605 | # vim: ft=python fileencoding=utf-8 sts=4 sw=4 et:
# Copyright 2016-2020 Florian Bruhin (The Compiler) <mail@qutebrowser.org>
#
# This file is part of qutebrowser.
#
# qutebrowser is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free S... | gpl-3.0 | -561,993,302,736,005,100 | 32.4375 | 74 | 0.699688 | false | 4.032663 | false | false | false |
airtonix/cmsplugin-embedded-pages | cmsplugin_embeddedpages/models.py | 1 | 3826 | import os
from django.db import models
from cms.models.pluginmodel import CMSPlugin
from .lib.choices import (
DynamicTemplateChoices,
PlaceholdersDynamicChoices,
# PageIDsDynamicChoices,
# PageAttributeDynamicChoices,
)
TEMPLATE_PATH = os.path.join("cmsplugin_embeddedpages","layouts")
GROUP_TEMPLATE_PATH = ... | bsd-2-clause | 7,365,644,589,555,425,000 | 35.438095 | 78 | 0.607946 | false | 3.964767 | false | false | false |
dvorberg/movierip | movierip/__init__.py | 1 | 5281 | #!/usr/bin/env python
# -*- coding: utf-8; mode: python; -*-
## Copyright 2010–17 by Diedrich Vorberg <diedrich@tux4web.de>
##
## All Rights Reserved
##
## For more Information on orm see the README file.
##
## This program is free software; you can redistribute it and/or modify
## it under the terms of the GNU G... | gpl-3.0 | 2,584,131,944,249,580,500 | 28.446927 | 77 | 0.564599 | false | 3.756949 | false | false | false |
Azure/azure-storage-python | azure-storage-file/azure/storage/file/_download_chunking.py | 1 | 6685 | # -------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
# --------------------------------------------------------------------------
import thr... | mit | 1,599,597,774,716,400,000 | 41.044025 | 119 | 0.597457 | false | 4.566257 | false | false | false |
carljm/django-model-utils | docs/conf.py | 1 | 8114 | #
# django-model-utils documentation build configuration file, created by
# sphinx-quickstart on Wed Jul 31 22:27:07 2013.
#
# This file is execfile()d with the current directory set to its containing dir.
#
# Note that not all possible configuration values are present in this
# autogenerated file.
#
# All configuratio... | bsd-3-clause | 6,096,815,436,245,315,000 | 31.586345 | 80 | 0.707419 | false | 3.791589 | true | false | false |
lino-framework/lino | lino/core/actions.py | 1 | 42601 | # -*- coding: UTF-8 -*-
# Copyright 2009-2021 Rumma & Ko Ltd
# License: GNU Affero General Public License v3 (see file COPYING for details)
"""This defines the :class:`Action` class and the :func:`action`
decorator, and some of the standard actions. See :ref:`dev.actions`.
"""
import logging; logger = logging.getLo... | bsd-2-clause | -562,974,953,244,720,830 | 31.863426 | 117 | 0.600808 | false | 3.848468 | false | false | false |
MikeLx/open-source-search-engine | script/inject/inject.py | 1 | 1956 | #!/usr/bin/python
# -*- coding: utf-8 -*-
import requests
import json
import re
import subprocess
import multiprocessing
#Generate environment with:
#pex -r requests -r multiprocessing -e inject:main -o warc-inject -s '.' --no-wheel
#pex -r requests -r multiprocessing -o warc-inject
def injectItem(item):
metad... | apache-2.0 | 7,445,202,696,927,137,000 | 30.548387 | 177 | 0.642127 | false | 3.51167 | false | false | false |
kdheepak89/pelican-alias | pelican_alias.py | 1 | 1886 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
import os.path
import logging
from pelican import signals
logger = logging.getLogger(__name__)
class AliasGenerator(object):
TEMPLATE = """<!DOCTYPE html><html><head><meta charset="utf-8" />
<meta http-equiv="refresh" content="0;url=/{destination_... | mit | 8,837,711,083,222,607,000 | 28.46875 | 75 | 0.582715 | false | 3.987315 | false | false | false |
cmorgan/toyplot | docs/conf.py | 1 | 12462 | # Copyright 2014, Sandia Corporation. Under the terms of Contract
# DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government retains certain
# rights in this software.
# -*- coding: utf-8 -*-
#
# toyplot documentation build configuration file, created by
# sphinx-quickstart on Fri Apr 18 18:22:53 2014.
#
# This ... | bsd-3-clause | -7,070,915,137,279,565,000 | 30.233083 | 186 | 0.695153 | false | 3.697923 | false | false | false |
DouglasLeeTucker/DECam_PGCM | bin/rawdata_se_objects_split.py | 1 | 5996 | #!/usr/bin/env python
"""
rawdata_se_objects_split.py
Example:
rawdata_se_objects_split.py --help
rawdata_se_objects_split.py --inputFileListFile inputfilelist.csv
--outputFileListFile outputfilelist.csv
--verbose 2
"""
###... | gpl-3.0 | 670,206,658,665,338,400 | 32.497207 | 151 | 0.564376 | false | 4.261549 | false | false | false |
mablae/weblate | weblate/accounts/views.py | 1 | 14376 | # -*- coding: utf-8 -*-
#
# Copyright © 2012 - 2015 Michal Čihař <michal@cihar.com>
#
# This file is part of Weblate <http://weblate.org/>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, eithe... | gpl-3.0 | 3,484,964,092,832,657,000 | 25.715613 | 79 | 0.593683 | false | 4.195271 | false | false | false |
xinghai-sun/models | deep_speech_2/data_utils/speech.py | 1 | 5631 | """Contains the speech segment class."""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from data_utils.audio import AudioSegment
class SpeechSegment(AudioSegment):
"""Speech segment abstraction, a subclass of AudioSegment,
with an additional tran... | apache-2.0 | -7,060,951,834,344,462,000 | 38.377622 | 78 | 0.626887 | false | 4.735913 | false | false | false |
showerst/openstates | openstates/vt/__init__.py | 1 | 2574 | from billy.utils.fulltext import pdfdata_to_text, text_after_line_numbers
from .bills import VTBillScraper
from .legislators import VTLegislatorScraper
from .committees import VTCommitteeScraper
from .events import VTEventScraper
metadata = dict(
name='Vermont',
abbreviation='vt',
capitol_timezone='America... | gpl-3.0 | 2,855,948,928,439,591,400 | 39.857143 | 79 | 0.480575 | false | 4.098726 | false | false | false |
yfpeng/dcache | setup.py | 1 | 1810 | # Always prefer setuptools over distutils
# To use a consistent encoding
from codecs import open
from os import path
from setuptools import setup, find_packages
here = path.abspath(path.dirname(__file__))
# Get the long description from the README file
with open(path.join(here, 'README.rst'), encoding='utf-8') as f:... | bsd-3-clause | 1,978,977,201,031,246,300 | 29.166667 | 98 | 0.655249 | false | 4.040179 | false | false | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.