repo_name stringlengths 5 92 | path stringlengths 4 232 | copies stringclasses 19
values | size stringlengths 4 7 | content stringlengths 721 1.04M | 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 15 997 | alpha_frac float64 0.25 0.97 | autogenerated bool 1
class |
|---|---|---|---|---|---|---|---|---|---|---|
prologic/kdb | kdb/plugins/rss.py | 1 | 7377 | from itertools import chain
from time import mktime, time
from pickle import dumps, loads
from traceback import format_exc
from circuits.protocols.irc import PRIVMSG
from circuits import handler, task, Event, Timer, Component
from feedparser import parse as parse_feed
from funcy import first, second
from html2text... | mit | -5,629,226,765,630,201,000 | 24.884211 | 77 | 0.459672 | false |
briancurtin/python-openstacksdk | openstack/tests/functional/network/v2/test_auto_allocated_topology.py | 1 | 2426 | # Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under t... | apache-2.0 | 3,718,609,966,521,981,400 | 38.770492 | 77 | 0.6892 | false |
gustavofonseca/packtools | packtools/domain.py | 1 | 20489 | # coding:utf-8
"""The domain-specific adapters.
An adapter is an object that provides domain-specific apis for another object,
called adaptee.
Examples are: XMLValidator and XMLPacker objects, which provide SciELO PS
validation behaviour and packaging functionality, respectively.
"""
from __future__ import unicode_li... | bsd-2-clause | -8,368,828,022,911,303,000 | 33.9046 | 136 | 0.61145 | false |
datamade/yournextmp-popit | candidates/tests/test_revert.py | 1 | 8163 | import json
from mock import patch
from string import Template
from django.db.models import F
from django_webtest import WebTest
from popolo.models import Identifier
from candidates.models import MembershipExtra, PersonExtra
from .auth import TestUserMixin
from . import factories
example_timestamp = '2014-09-29T10... | agpl-3.0 | 2,455,165,964,185,914,400 | 35.28 | 96 | 0.515252 | false |
hoondongkim/syntaxnet-kr | SJtoUD_POS.py | 1 | 10446 | import re
import codecs
import os
"""
[1] Main Function
"""
def main():
directory = os.getcwd() + '/InputDataType1'
filename = 'BTHO0437.txt'
filename = os.path.join(directory, filename)
f = open(filename, 'r', encoding='utf-16')
is_inside = False
line_counter = 0
OUT_FILENAME = "OutputDat... | apache-2.0 | -8,477,834,371,595,856,000 | 35.221402 | 152 | 0.45487 | false |
h3rucutu/weevely-old | core/vector.py | 1 | 1305 | import types
class VectorList(list):
def get_vectors_by_interpreters(self, shells):
vect=[]
for v in self:
if v.interpreter in shells:
vect.append(v)
return vect
def get_vector_by_name(self, name):
for v in self:
if ... | gpl-3.0 | 1,101,729,514,562,507,800 | 25.632653 | 76 | 0.524904 | false |
ianastewart/cwltc-admin | members/application_processor.py | 1 | 3702 | # Handle application process
from datetime import datetime
from members.models import Person, Membership, Subscription, TextBlock, AdultApplication
from members.services import (
subscription_create,
subscription_activate,
subscription_create_invoiceitems,
invoice_create,
)
from cardless.services impo... | mit | 7,603,111,895,722,632,000 | 36.77551 | 92 | 0.606699 | false |
iitis/PyLTEs | pyltes/network.py | 1 | 9084 | __author__ = 'Mariusz Slabicki, Konrad Polys'
from pyltes import devices
from pyltes import generator
from pyltes import printer
import math
import random
import pickle
import copy
class CellularNetwork:
"""Class describing cellular network"""
def __init__(self):
self.ue = []
self.bs = []
... | mit | -4,915,131,659,041,831,000 | 36.85 | 129 | 0.57882 | false |
hknyldz/pisitools | pisilinux/pisilinux/db/filesldb.py | 1 | 2686 | # -*- coding: utf-8 -*-
#
# Copyright (C) 2014, Marcin Bojara
#
# 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.
#
# Plea... | gpl-3.0 | -1,854,080,393,484,700,000 | 33.883117 | 105 | 0.616902 | false |
mouton5000/DiscreteEventApplicationEditor | test/testsArithmeticExpressions/MathFunctions/testATan.py | 1 | 2813 | __author__ = 'mouton'
from triggerExpressions import Evaluation
from unittest import TestCase
from math import pi, sqrt, atan
from arithmeticExpressions import ALitteral, Func, UndefinedLitteral, SelfLitteral
from database import Variable
class TestAtan(TestCase):
@classmethod
def setUpClass(cls):
i... | mit | 893,855,080,066,188,400 | 31.344828 | 82 | 0.629932 | false |
eliasrg/SURF2017 | code/separate/coding/PAM.py | 1 | 2567 | # Copyright (c) 2017 Elias Riedel Gรฅrding
# Licensed under the MIT License
from utilities import to_column_vector, int_to_bits, bits_to_int
import numpy as np
class Constellation:
"""A mapping m: โค2^n โ โ^K."""
@classmethod
def uniform(cls, n):
"Equidistant points (K = 1)."
# {-(2^n - 1... | mit | -9,088,709,460,113,332,000 | 31.405063 | 73 | 0.532813 | false |
popazerty/dvbapp2-gui | lib/python/Plugins/SystemPlugins/IniFanSetup/plugin.py | 1 | 3437 | # -*- coding: utf-8 -*-
from Screens.Screen import Screen
from Components.ConfigList import ConfigListScreen
from Components.config import config, ConfigSubsection, ConfigInteger, ConfigSelection, getConfigListEntry
modelist = {"0": _("Off"), "2": _("On"), "1": _("Auto")}
config.plugins.FanSetup = ConfigSubsection()
... | gpl-2.0 | 8,741,970,078,657,134,000 | 29.415929 | 158 | 0.697701 | false |
matrixjoeq/timus_solutions | 1327/slu.py | 1 | 2005 | #!/usr/bin/python
# -*- coding: utf-8 -*-
'''
1327. Fuses
Time limit: 1.0 second
Memory limit: 64 MB
[Description]
Sasha Privalov, a young programmer working in the SRITS (Scientific Research
Institute for Thaumaturgy and Spellcraft), finds his job rather enjoyable.
Indeed, he is the only programmer of such a wonderf... | mit | 8,483,938,644,643,850,000 | 35.981481 | 80 | 0.728092 | false |
elimence/edx-platform | lms/djangoapps/courseware/features/smart-accordion.py | 1 | 5762 | #pylint: disable=C0111
#pylint: disable=W0621
from lettuce import world, step
from re import sub
from nose.tools import assert_equals
from xmodule.modulestore.django import modulestore
from common import *
from logging import getLogger
logger = getLogger(__name__)
def check_for_errors():
e = world.browser.find_... | agpl-3.0 | -6,453,196,963,020,202,000 | 35.468354 | 131 | 0.599098 | false |
WalkingMachine/sara_commun | wm_robocup2016/src/inspection.py | 1 | 8680 | #!/usr/bin/env python
import rospy
import smach
from smach_ros import SimpleActionState
import wm_supervisor.srv
from move_base_msgs.msg import MoveBaseAction
from geometry_msgs.msg import PoseStamped, PoseWithCovarianceStamped
import threading
from std_msgs.msg import Float64, String, Bool
class InitRobot(smach.Sta... | apache-2.0 | -6,698,372,797,924,644,000 | 36.094017 | 120 | 0.575922 | false |
ZeusWPI/Haldis | app/models/order.py | 1 | 3454 | "Script for everything Order related in the database"
import typing
from datetime import datetime
from utils import first
from hlds.definitions import location_definitions
from .database import db
from .user import User
class Order(db.Model):
"Class used for configuring the Order model in the database"
id = ... | mit | -4,438,506,992,852,992,500 | 32.862745 | 82 | 0.583092 | false |
justinvforvendetta/electrum-pkb | lib/network.py | 1 | 18396 | import time
import Queue
import os
import sys
import random
import traceback
import socks
import socket
import json
import util
from bitcoin import *
import interface
from blockchain import Blockchain
DEFAULT_PORTS = {'t':'50001', 's':'50002', 'h':'8081', 'g':'8082'}
DEFAULT_SERVERS = {
'electrum-pkb.net': DEFA... | gpl-3.0 | 8,183,106,280,867,124,000 | 33.193309 | 138 | 0.570613 | false |
dstrohl/advanced_config_manager | AdvConfigMgr/utils/flag_manager.py | 1 | 2469 | __author__ = 'dstrohl'
from AdvConfigMgr.utils.base_utils import list_in_list
# ===============================================================================
# Flag Manager
# ===============================================================================
class FlagList(object):
def __init__(self):
se... | gpl-2.0 | -7,637,230,000,685,972,000 | 23.445545 | 81 | 0.45808 | false |
mapillary/OpenSfM | opensfm/test/test_rig.py | 1 | 4622 | """Test the rig module."""
import numpy as np
from opensfm import pygeometry, rig, types
def test_create_instances_with_patterns() -> None:
# A first rig model defined as left/right/top/bottom
# A complete instance
instance1 = [
"12345_left.jpg",
"12345_bottom.jpg",
"12345_top.jpg... | bsd-2-clause | -3,292,371,213,176,436,700 | 28.069182 | 80 | 0.540242 | false |
jnoortheen/nigandu | src/managebkm.py | 2 | 1697 | __author__ = 'noor'
from PySide.QtGui import (QDialog, QLabel, QIcon, QWidget, QVBoxLayout, QPushButton, QListWidget, QFont)
from PySide.QtCore import QRect
class managebkm(QDialog):
def __init__(self, parent=None):
super(managebkm, self).__init__(parent)
appicom = QIcon(":/icons/njnlogo.png")
self.setW... | gpl-2.0 | 2,093,781,256,533,425,200 | 35.711111 | 104 | 0.747201 | false |
sebastiansIT/RPI-Display-Backlight-Controller-for-Kodi | sources/screensaver.rpi-backlight-disabler/screensaver.py | 1 | 2345 | # Copyright 2016 Sebastian Spautz <sebastian@human-injection.de>
#
# This file is part of "RPI Display Backlight Control for Kodi".
#
# "RPI Display Backlight Control for Kodi" is free software: you can
# redistribute it and/or modify it under the terms of the GNU General
# Public License as publishe... | gpl-3.0 | -6,250,596,263,587,048,000 | 33.5 | 103 | 0.660128 | false |
mcanthony/oiio | testsuite/oiiotool-spi/run.py | 1 | 2476 | #!/usr/bin/env python
imagedir = parent + "spi-oiio-tests/"
refdir = imagedir + "ref/"
# Define a handy function that runs an oiiotool command, and
# also diffs the result against a reference image.
def oiiotool_and_test (inputfile, ops, outputfile, precommand="") :
cmd = oiiotool (precommand + " " + imagedir + ... | bsd-3-clause | 8,015,243,802,899,688,000 | 44.851852 | 122 | 0.588853 | false |
arcean/qtcontacts-tracker | tests/teststats.py | 1 | 10828 | #!/usr/bin/python
# This file is part of QtContacts tracker storage plugin
#
# Copyright (c) 2011 Nokia Corporation and/or its subsidiary(-ies).
#
# Contact: Nokia Corporation (info@qt.nokia.com)
#
# GNU Lesser General Public License Usage
# This file may be used under the terms of the GNU Lesser General Public Licen... | lgpl-2.1 | 5,286,435,379,430,205,000 | 32.627329 | 92 | 0.579608 | false |
spywhere/Javatar | commands/creates/create_class.py | 1 | 13833 | import sublime
import sublime_plugin
import os.path
from ...core import (
JavaClass,
JavaClassPath,
JavaUtils,
RE,
SnippetsManager,
StateProperty
)
from ...utils import (
ActionHistory,
StatusManager
)
EXTENDS_IMPLEMENTS_RE = "([:<])"
MAIN_TEMPLATE = "public static void main(String[] a... | mit | 719,629,061,234,050,600 | 32.01432 | 80 | 0.51247 | false |
meejah/pyobfsproxy | obfsproxy/common/log.py | 1 | 1094 | # obfsproxy logging code
import logging
import sys
# XXX Add Formatter!!!
our_logger = logging.getLogger('our_logger')
default_handler = logging.StreamHandler(sys.stdout)
our_logger.addHandler(default_handler)
our_logger.propagate = False
def set_log_file(filename):
"""Set up our logger so that it starts loggin... | bsd-3-clause | 8,584,981,672,234,394,000 | 27.051282 | 84 | 0.738574 | false |
buzz/volctl | volctl/osd.py | 1 | 7911 | """
OSD volume overlay
A transparent OSD volume indicator for the bottom-right corner.
Various code snippets taken from https://github.com/kozec/sc-controller
"""
import math
import cairo
from gi.repository import Gdk, Gtk, GdkX11, GLib
import volctl.xwrappers as X
class VolumeOverlay(Gtk.Window):
"""Window t... | gpl-2.0 | 1,739,896,336,297,428,500 | 32.100418 | 82 | 0.562761 | false |
classcat/cc-prism-nsm | main/webapp/ccp_conf.py | 1 | 1509 | #############################################################
# ClassCat(R) Prism for HIDS
# Copyright (C) 2015 ClassCat Co.,Ltd. All rights reseerved.
##############################################################
# === Notice ===
# all python scripts were written by masao (@classcat.com)
#
# === History ===
# 02-a... | agpl-3.0 | 7,328,809,626,072,071,000 | 22.578125 | 78 | 0.526839 | false |
shoopio/shoop | shuup/core/pricing/_price_display_options.py | 2 | 1631 | # This file is part of Shuup.
#
# Copyright (c) 2012-2019, Shoop Commerce Ltd. All rights reserved.
#
# This source code is licensed under the OSL-3.0 license found in the
# LICENSE file in the root directory of this source tree.
class PriceDisplayOptions(object):
"""
Price display options.
Parameters on... | agpl-3.0 | 3,897,043,345,657,898,500 | 27.614035 | 77 | 0.618639 | false |
mohjaba/Health-Activity-Monitoring | 1_code/interactive_map/Demo1/twitter_stream.py | 1 | 1207 | import tweepy
import json
from pymongo import Connection
from bson import json_util
from tweepy.utils import import_simplejson
json = import_simplejson()
mongocon = Connection()
db = mongocon.twiter_data
col = db.tweets_stream
consumer_key = 'AYh6x5HIt5ubprSXeEGVqmLnT'
consumer_secret = 'wx4wC2ttf3hS34iGPMeL6VAifwIZ... | gpl-2.0 | -1,814,583,310,914,595,000 | 25.822222 | 71 | 0.720795 | false |
EmrysChe/My_Python_practice | codes/extra/backup_script.py | 1 | 1043 | #!/usr/bin/python3
###################################
# for Linux #
###################################
import os
import time
source_dir = ['/root/data']
target_dir = '/root/backup'
today_log_dir = target_dir + os.sep + time.strftime('%y%m%d')
success_count = 0
fail_count = 0
if not os.path.exi... | gpl-2.0 | -5,788,582,095,096,189,000 | 31.59375 | 108 | 0.520614 | false |
theaeolianmachine/hokiefinder | hokiefinder/geolocator/google_geocoding.py | 1 | 1103 | import json
import requests
GEOCODING_URL = 'http://maps.googleapis.com/maps/api/geocode/json'
ZERO_RESULTS = 'ZERO_RESULTS'
OVER_QUERY_LIMIT = 'OVER_QUERY_LIMIT'
REQUEST_DENIED = 'REQUEST_DENIED'
INVALID_REQUEST = 'INVALID_REQUEST'
ERRORS = (ZERO_RESULTS, OVER_QUERY_LIMIT, REQUEST_DENIED, INVALID_REQUEST)
def get_l... | mit | 1,528,149,819,978,163,500 | 32.424242 | 74 | 0.596555 | false |
naturali/tensorflow | tensorflow/python/framework/tensor_shape.py | 1 | 26539 | # Copyright 2015 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 | -1,721,125,840,426,754,000 | 29.859302 | 95 | 0.637778 | false |
eharney/cinder | cinder/tests/unit/volume/drivers/dell_emc/vmax/test_vmax.py | 1 | 289881 | # Copyright (c) 2017 Dell Inc. or its subsidiaries.
# 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
#
# ... | apache-2.0 | -9,174,695,730,427,647,000 | 45.366123 | 79 | 0.586879 | false |
cloudmesh/cmd3light | setup.py | 1 | 6580 | #!/usr/bin/env python
# ----------------------------------------------------------------------- #
# Copyright 2008-2010, Gregor von Laszewski #
# Copyright 2010-2013, Indiana University #
# #
# Licensed under the Apache License, Version 2.0 (the "License"); ... | apache-2.0 | -2,251,012,706,917,116,200 | 33.270833 | 115 | 0.566109 | false |
Jawoll/automatchthreads | modules/obsolete/match_thread.py | 1 | 2766 | from threading import Thread
from config import data as config
from modules.overgg import Overgg
from modules.pasta import Pasta
from modules.reddit import Reddit
import time
class MatchThread(Thread):
def __init__(self, url, reddit_title):
self.url = url
self.reddit_title = reddit_title
se... | mit | -218,613,766,802,604,380 | 35.893333 | 101 | 0.564714 | false |
Salmista-94/Ninja_3.0_PyQt5 | ninja_ide/gui/tools_dock/plugin_preferences.py | 1 | 2404 | # -*- coding: utf-8 -*-
#
# This file is part of NINJA-IDE (http://ninja-ide.org).
#
# NINJA-IDE 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
# any later version.
#
# NIN... | gpl-3.0 | -8,308,359,762,363,824,000 | 35.424242 | 77 | 0.650582 | false |
yarikoptic/NiPy-OLD | nipy/neurospin/viz/activation_maps.py | 1 | 25526 | #!/usr/bin/env python
"""
Functions to do automatic visualization of activation-like maps.
For 2D-only visualization, only matplotlib is required.
For 3D visualization, Mayavi, version 3.0 or greater, is required.
"""
# Author: Gael Varoquaux <gael dot varoquaux at normalesup dot org>
# License: BSD
# Standard libr... | bsd-3-clause | -1,009,499,948,434,668,400 | 39.13522 | 80 | 0.53091 | false |
svebk/DeepSentiBank_memex | workflows/transform-ht-images-table-to-transition/transform-ht-images-table-to-transition.py | 1 | 5269 | import json
from datetime import datetime
import happybase
from pyspark import SparkContext, SparkConf
TTransportException = happybase._thriftpy.transport.TTransportException
def get_create_table(table_name, conn, families={'info': dict()}):
try:
# what exception would be raised if table does not exist, a... | bsd-2-clause | -8,967,046,424,435,025,000 | 36.906475 | 111 | 0.609224 | false |
fzimmermann89/pyload | module/plugins/crypter/SexuriaCom.py | 1 | 5089 | # -*- coding: utf-8 -*-
import re
from module.plugins.internal.Crypter import Crypter, create_getInfo
class SexuriaCom(Crypter):
__name__ = "SexuriaCom"
__type__ = "crypter"
__version__ = "0.11"
__status__ = "testing"
__pattern__ = r'http://(?:www\.)?sexuria\.com/(v1/)?(Pornos_Kostenlos_... | gpl-3.0 | 2,629,648,724,651,690,000 | 44.4375 | 141 | 0.538613 | false |
ptdtan/Ragout | ragout_api.py | 1 | 10365 |
"""
Ragout API interface for ancestral genome reconstruction
"""
import os
import sys
import shutil
import logging
import argparse
from collections import namedtuple
from copy import deepcopy
ragout_root = os.path.dirname(os.path.realpath(__file__))
lib_absolute = os.path.join(ragout_root, "lib")
sys.path.insert(0, l... | gpl-3.0 | 776,794,839,997,108,000 | 41.306122 | 145 | 0.612349 | false |
googleads/google-ads-python | google/ads/googleads/v8/errors/types/resource_count_limit_exceeded_error.py | 1 | 1486 | # -*- coding: utf-8 -*-
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or... | apache-2.0 | -3,917,095,316,855,932,000 | 29.958333 | 74 | 0.682369 | false |
LivingOn/xbmc-plugin.image.nachtschicht-bhv | addon.py | 1 | 2657 | # -*- coding=utf8 -*-
#******************************************************************************
# addon.py
#------------------------------------------------------------------------------
#
# Copyright (c) 2013 LivingOn <LivingOn@xmail.net>
#
# This program is free software; you can redistribute it and/or modify
#... | gpl-2.0 | -6,851,067,713,381,325,000 | 35.916667 | 90 | 0.590892 | false |
geodynamics/pylith | pylith/friction/obsolete/RateStateAgeing.py | 1 | 3306 | #!/usr/bin/env python
#
# ----------------------------------------------------------------------
#
# Brad T. Aagaard, U.S. Geological Survey
# Charles A. Williams, GNS Science
# Matthew G. Knepley, University of Chicago
#
# This code was developed as part of the Computational Infrastructure
# for Geodynamics (http://ge... | mit | 235,920,559,458,479,170 | 27.5 | 85 | 0.562311 | false |
apporc/nova | nova/compute/rpcapi.py | 1 | 45182 | # Copyright 2013 Red Hat, Inc.
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed... | apache-2.0 | 8,557,778,177,542,389,000 | 45.340513 | 79 | 0.595547 | false |
SkierPGP/Skier | db.py | 1 | 3077 | import datetime
from flask.ext.sqlalchemy import SQLAlchemy
from sqlalchemy.dialects.postgresql import ARRAY
from app import app
db = SQLAlchemy(app)
class Key(db.Model):
"""
The model for a PGP key.
"""
id = db.Column(db.Integer, primary_key=True)
uid = db.relationship("UID", backref="key")
... | agpl-3.0 | 7,163,609,061,429,038,000 | 27.5 | 123 | 0.626584 | false |
ndokter/dsmr_parser | dsmr_parser/clients/filereader.py | 1 | 6256 | import logging
import fileinput
import tailer
from dsmr_parser.clients.telegram_buffer import TelegramBuffer
from dsmr_parser.exceptions import ParseError, InvalidChecksumError
from dsmr_parser.objects import Telegram
from dsmr_parser.parsers import TelegramParser
logger = logging.getLogger(__name__)
class FileRead... | mit | -5,151,617,203,341,825,000 | 35.584795 | 103 | 0.596867 | false |
anshitag/Job-Cred-Meter | Python Files/datacollection.py | 1 | 3030 | import requests
import json
access_token='EAAMcWZCJ7Ui4BALHXjXKkizZANG5AhQZAL9buUS5KR6fX8YurTosJLmxTfP4WoZBiP8DFe8eqbJ2NplRPGLsve2xYIwwsbERTnX5pvsiRIvJ0So1TZAHmOHlUPVnzZCBjPdZBhkm8CBnYTV0eNjAwQiBVkroQGnaqgZD'
outfile=open("list.csv","w")
def text_cleaning(text):
text = text.encode('ascii', 'ignore').... | mit | -368,879,785,351,056,060 | 32.827586 | 180 | 0.542574 | false |
gitenberg-dev/pg-epubmaker | epubmaker/writers/RSTWriter.py | 1 | 1259 | #!/usr/bin/env python
# -*- mode: python; indent-tabs-mode: nil; -*- coding: iso-8859-1 -*-
"""
RSTWriter.py
Copyright 2009 by Marcello Perathoner
Distributable under the GNU General Public License Version 3 or newer.
Build an RST file. This is just the master RST with the PG license mixed in.
"""
from __future_... | gpl-3.0 | 4,966,281,297,831,469,000 | 25.787234 | 86 | 0.634631 | false |
fintura/pyPaaS | pypaas/checkout.py | 1 | 3420 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
import sys
import copy
import shutil
import os.path
import datetime
import subprocess
from configparser import ConfigParser
from . import options
class Checkout(object):
def __init__(self, branch, commit, name):
self.branch, self.commit, self.name ... | mit | 2,602,529,112,575,175,700 | 27.264463 | 76 | 0.521637 | false |
JakobGM/robotarm-optimization | tests/test_robot_arm.py | 1 | 1781 | import unittest
import numpy as np
from numpy import pi
from robot_arm import RobotArm
class TestRobotArm(unittest.TestCase):
def setUp(self):
self.lengths = (3, 2, 2,)
self.destinations = (
(5, 4, 6, 4, 5),
(0, 2, 0.5, -2, -1),
)
self.theta = (pi, pi / 2, ... | mit | 6,607,707,870,683,648,000 | 26.4 | 78 | 0.571028 | false |
taxigps/xbmc-addons-chinese | plugin.video.youku/default.py | 1 | 28143 | ๏ปฟ# -*- coding: utf-8 -*-
import xbmc, xbmcgui, xbmcplugin, xbmcaddon, urllib2, urllib, re, string, sys, os, gzip, StringIO, math, urlparse
import base64, time, cookielib
import simplejson
# Plugin constants
__addon__ = xbmcaddon.Addon()
__addonname__ = __addon__.getAddonInfo('name')
__profile__ = xbmc.translate... | gpl-2.0 | -6,283,709,938,491,380,000 | 38.605452 | 326 | 0.545481 | false |
dani-i/bachelor-project | session/test_session.py | 1 | 5751 | from controllers.data_set_controller import DataSetController
from controllers.session_controller import SessionController
from utils.train.session_details import SessionDetails
import constants.cnn_constants as cnn_const
import neural_networks.cnn as cnn
import tensorflow as tf
import threading
import math
class... | apache-2.0 | 4,908,201,968,194,576,000 | 30.255435 | 96 | 0.449661 | false |
quaddra/engage | python_pkg/engage/drivers/standard/postgres_database__9_x/driver.py | 1 | 5516 |
"""Resource manager for postgres-database 9.x
"""
# Common stdlib imports
import sys
import os
import os.path
## import commands
# fix path if necessary (if running from source or running as test)
try:
import engage.utils
except:
sys.exc_clear()
dir_to_add_to_python_path = os.path.abspath((os.path.join(... | apache-2.0 | -8,512,102,885,461,848,000 | 35.529801 | 105 | 0.613851 | false |
Teino1978-Corp/Teino1978-Corp-light_.gitignore | light_data_migrations_0008_fi_comparativo.py | 1 | 1169 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
class Migration(migrations.Migration):
dependencies = [
('master', '0019_periodo_tipoperiodo'),
('data', '0007_auto_20150216_0921'),
]
operations = [
migrations.CreateModel(
... | mit | -5,811,489,867,645,398,000 | 33.382353 | 114 | 0.521814 | false |
googleapis/python-talent | setup.py | 1 | 2740 | # Copyright 2019 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 agreed to in writing, s... | apache-2.0 | -6,588,985,584,347,073,000 | 29.10989 | 75 | 0.684307 | false |
cria/microSICol | py/modules/labels.py | 1 | 38937 | #! /usr/bin/env python
# -*- coding: utf-8 -*-
'''
This file contains a mapping from the labels found in the html
templates to translatable strings.
'''
label_dict = {
"label_Container": _("Container"),
"label_Rep_Division": _("Rep Division"),
#taxa
"label_Species_General_Comments": _("Comments"),
"label_Species_Ge... | gpl-2.0 | -7,150,550,810,199,151,000 | 45.968637 | 102 | 0.708016 | false |
mlperf/training_results_v0.7 | Fujitsu/benchmarks/resnet/implementations/implementation_open/mxnet/3rdparty/tvm/tests/python/unittest/test_codegen_device.py | 1 | 4204 | # Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not u... | apache-2.0 | 1,658,198,143,993,721,900 | 38.28972 | 74 | 0.622265 | false |
mic4ael/indico | bin/utils/create_module.py | 1 | 6792 | # This file is part of Indico.
# Copyright (C) 2002 - 2020 CERN
#
# Indico is free software; you can redistribute it and/or
# modify it under the terms of the MIT License; see the
# LICENSE file for more details.
from __future__ import unicode_literals
import os
import re
import textwrap
from collections import defau... | mit | -6,267,578,865,600,355,000 | 38.034483 | 120 | 0.604976 | false |
SCUEvals/scuevals-api | db/alembic/env.py | 1 | 2188 | from __future__ import with_statement
import os
import sys
from alembic import context
from sqlalchemy import engine_from_config, pool
from logging.config import fileConfig
sys.path.append(os.getcwd())
from scuevals_api.models import db # noqa
# this is the Alembic Config object, which provides
# access to the valu... | agpl-3.0 | -7,893,498,225,739,737,000 | 27.051282 | 94 | 0.70841 | false |
founders4schools/duedilv3 | duedil/resources/pro/company/__init__.py | 1 | 1180 | from __future__ import unicode_literals
from .accounts import Account
from .accounts.financial import AccountDetailsFinancial
from .accounts.gaap import AccountDetailsGAAP
from .accounts.ifrs import AccountDetailsIFRS
from .accounts.insurance import AccountDetailsInsurance
from .accounts.statutory import AccountDetail... | apache-2.0 | -554,486,124,231,948,900 | 41.142857 | 61 | 0.783898 | false |
michaelmurdock/mmlib | db_utils.py | 1 | 1578 | # db_utils.py
def execute_query_for_single_value(cursor, query):
'''
query is a string containing a well-formed query that is executed
against the specified cursor.
RETURNS: the following tripe: (results_flag, err_msg, value)
'''
try:
# Execute the query
cursor.exe... | bsd-2-clause | 2,520,249,092,786,609,700 | 26.178571 | 99 | 0.583016 | false |
DavidAwad/Quantum-Simulator | quantum.py | 1 | 5150 | #!/usr/bin/env python
# encoding: utf-8
from cmath import exp, pi, sqrt
from random import random
import itertools
def vectorflip(bitstring):
"""
returns flipped bits in a given string
"""
if not bitstring: raise TypeError("vectorflip passed None")
return ''.join('1' if x == '0' else '0' for x... | gpl-3.0 | 1,803,433,893,474,609,000 | 37.714286 | 90 | 0.58458 | false |
gpodder/mygpo | mygpo/administration/views.py | 1 | 13775 | import re
import socket
from itertools import count, chain
from collections import Counter
from datetime import datetime
import redis
import django
from django.db.models import Avg
from django.shortcuts import render
from django.contrib import messages
from django.urls import reverse
from django.core.cache import cac... | agpl-3.0 | -3,548,724,407,814,230,000 | 28.816017 | 87 | 0.607477 | false |
rjawor/concordia-server | tests/addAlignedLemmatizedTM.py | 1 | 3161 | #!/usr/bin/python
# -*- coding: utf-8 -*-
import unittest
import json
import urllib2
import sys
import host
import time
BUFFER_SIZE = 500
address = 'http://'+host.concordia_host
if len(host.concordia_port) > 0:
address += ':'+host.concordia_port
def file_len(fname):
with open(fname) as f:
for i, l ... | lgpl-3.0 | 7,864,143,049,183,775,000 | 27.736364 | 189 | 0.669092 | false |
derekjchow/models | research/object_detection/legacy/trainer.py | 1 | 17662 | # Copyright 2017 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 | -5,056,624,637,753,159,000 | 41.456731 | 80 | 0.678915 | false |
satyrius/cmsplugin-articles | cmsplugin_articles/south_migrations/0001_initial.py | 1 | 3016 | # -*- coding: utf-8 -*-
from south.utils import datetime_utils as datetime
from south.db import db
from south.v2 import SchemaMigration
from django.db import models
class Migration(SchemaMigration):
def forwards(self, orm):
# Adding model 'ArticlesPlugin'
db.create_table(u'cmsplugin_articles_arti... | mit | -4,347,444,621,616,893,000 | 55.924528 | 157 | 0.589191 | false |
alejolp/argentum-py-server | argentumserver/util.py | 1 | 2663 | # -*- coding: utf-8 -*-
"""
AONX Server - Pequeรฑo servidor de Argentum Online.
Copyright (C) 2011 Alejandro Santos <alejolp@alejolp.com.ar>
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 Fo... | gpl-3.0 | -5,969,421,147,287,314,000 | 25.356436 | 91 | 0.574756 | false |
SYSTRAN/nlp-api-python-client | tests/test_ner.py | 1 | 2741 | #!/usr/bin/env python
# coding: utf-8
import os
import unittest
import systran_nlp_api
import systran_nlp_api.configuration
class NerApiTests(unittest.TestCase):
def setUp(self):
api_key_file = os.path.join(os.path.dirname(__file__), "../", "api_key.txt")
systran_nlp_api.configuration.load_api_ke... | apache-2.0 | -1,255,574,166,305,409,500 | 51.711538 | 202 | 0.669464 | false |
magooos/KITT | interface.py | 1 | 2476 | __author__ = 'laurentmeyer'
# Set the command type to auto
import sys, telnetlib, time
MOCK_SERVER = "192.168.2.217"
MOCK_SERVER_PORT = 35000
def beginCommunication(telnetaddr = MOCK_SERVER, telnetport = MOCK_SERVER_PORT):
telnet = telnetlib.Telnet(telnetaddr, port=telnetport)
return telnet
def startInfiniteL... | apache-2.0 | 6,595,756,557,333,647,000 | 29.207317 | 95 | 0.656704 | false |
SociedadMartinez/ToolShare | registration/views.py | 1 | 31482 | """
@authors Tina Howard, Grant Gadomski, Nick Mattis, Laura Silva, Nils Sohn
"""
from django.shortcuts import render, get_object_or_404, redirect
from django.utils.datastructures import MultiValueDictKeyError
from django.http import Http404, HttpResponseRedirect, HttpResponse #TODO Take off HttpResponse after fig... | gpl-3.0 | -6,212,815,428,847,660,000 | 42.909344 | 245 | 0.61794 | false |
elimence/edx-platform | common/lib/xmodule/xmodule/contentstore/mongo.py | 1 | 4555 | from bson.son import SON
from pymongo import Connection
import gridfs
from gridfs.errors import NoFile
from xmodule.modulestore.mongo import location_to_query, Location
from xmodule.contentstore.content import XASSET_LOCATION_TAG
import logging
from .content import StaticContent, ContentStore
from xmodule.exceptions... | agpl-3.0 | 2,441,600,805,920,882,700 | 41.175926 | 125 | 0.626125 | false |
tyb0807/angr | angr/procedures/libc/fseek.py | 1 | 1124 | import angr
from . import io_file_data_for_arch
from ...errors import SimSolverError
######################################
# fseek
######################################
class fseek(angr.SimProcedure):
#pylint:disable=arguments-differ
def run(self, file_ptr, offset, whence):
# TODO: Support symboli... | bsd-2-clause | -4,569,895,961,317,021,700 | 34.125 | 115 | 0.580961 | false |
musicbrainz/picard | picard/webservice/api_helpers.py | 1 | 11716 | # -*- coding: utf-8 -*-
#
# Picard, the next-generation MusicBrainz tagger
#
# Copyright (C) 2017 Sambhav Kothari
# Copyright (C) 2018 Laurent Monin
# Copyright (C) 2018-2019 Philipp Wolfer
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# ... | gpl-2.0 | 2,615,057,318,125,829,600 | 38.986348 | 116 | 0.59662 | false |
sundhaug92/binwalk | src/binwalk/modules/entropy.py | 1 | 11569 | # Calculates and optionally plots the entropy of input files.
import os
import math
import zlib
import binwalk.core.common
from binwalk.core.compat import *
from binwalk.core.module import Module, Option, Kwarg
class Entropy(Module):
XLABEL = 'Offset'
YLABEL = 'Entropy'
XUNITS = 'B'
YUNITS = 'E'
... | mit | 1,616,502,433,162,220,500 | 34.271341 | 115 | 0.532112 | false |
flypy/flypy | flypy/runtime/obj/stringobject.py | 1 | 2309 | # -*- coding: utf-8 -*-
"""
String implementation.
"""
from __future__ import print_function, division, absolute_import
import flypy
from flypy import sjit, jit, typeof
from .bufferobject import Buffer, newbuffer, copyto
from .pointerobject import Pointer
@sjit
class String(object):
layout = [('buf', 'Buffer[ch... | bsd-2-clause | 564,705,248,364,372,860 | 24.384615 | 73 | 0.459939 | false |
mohclips/k5-ansible-modules | k5_inter_project_link.py | 1 | 9324 | #!/usr/bin/python
ANSIBLE_METADATA = {'status': ['preview'],
'supported_by': 'community',
'version': '1.0'}
DOCUMENTATION = '''
---
module: k5_inter_project_link
short_description: Create inter-project link on K5 in particular AZ
version_added: "1.0"
description:
- K5 call ... | gpl-3.0 | 5,519,801,665,012,305,000 | 30.5 | 134 | 0.604569 | false |
mdzhang/goodreads-api-client-python | goodreads_api_client/resources/review.py | 1 | 1247 | # -*- coding: utf-8 -*-
"""Module containing review resource class."""
from goodreads_api_client.exceptions import OauthEndpointNotImplemented
from goodreads_api_client.resources.base import Resource
class Review(Resource):
resource_name = 'review'
def create(self):
raise OauthEndpointNotImplemented... | mit | -8,722,092,569,328,240,000 | 30.175 | 71 | 0.635926 | false |
piensa/geonode | geonode/people/models.py | 1 | 7186 | # -*- 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 | -6,361,352,256,820,345,000 | 36.233161 | 120 | 0.662399 | false |
yeleman/snisi | snisi_reprohealth/migrations/0003_auto_20141022_1400.py | 1 | 1402 | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
class Migration(migrations.Migration):
dependencies = [
('snisi_reprohealth', '0002_auto_20141008_1709'),
]
operations = [
migrations.RenameField(
model_name='aggpfactivi... | mit | -234,128,467,318,790,200 | 30.863636 | 58 | 0.587019 | false |
tensorflow/tfx | tfx/components/example_gen/utils_test.py | 1 | 29481 | # Lint as: python2, python3
# Copyright 2019 Google LLC. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless req... | apache-2.0 | -5,650,820,876,118,375,000 | 36.893316 | 98 | 0.614599 | false |
jburel/openmicroscopy | components/tools/OmeroPy/src/omero/plugins/prefs.py | 1 | 21186 | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
prefs plugin
Plugin read by omero.cli.Cli during initialization. The method(s)
defined here will be added to the Cli class for later use.
The pref plugin makes use of prefs.class from the common component.
Copyright 2007-2013 Glencoe Software, Inc. All... | gpl-2.0 | -7,798,762,105,862,879,000 | 33.960396 | 78 | 0.544841 | false |
jardiacaj/finem_imperii | turn/test/test_turn.py | 1 | 7924 | from django.test import TestCase
from django.urls.base import reverse
from battle.models import Battle
from organization.models.organization import Organization
from turn.barbarians import do_settlement_barbarian_generation
from turn.battle import organizations_with_battle_ready_units, \
battle_ready_units_in_tile... | agpl-3.0 | 5,303,196,034,817,540,000 | 36.733333 | 101 | 0.652196 | false |
aakashrana1995/svnit-tnp | tnp/consent/migrations/0003_consentdeadline_userconsent_userdatafields.py | 1 | 1971 | # -*- coding: utf-8 -*-
# Generated by Django 1.10.5 on 2017-02-07 08:16
from __future__ import unicode_literals
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
migrations.swappable_depende... | mit | 4,100,357,406,943,850,000 | 41.847826 | 147 | 0.595637 | false |
OmeGak/indico-plugins | vc_vidyo/indico_vc_vidyo/zodbimport.py | 1 | 8102 | # This file is part of Indico.
# Copyright (C) 2002 - 2016 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; either version 3 of the
# License, or (a... | gpl-3.0 | 6,832,290,952,876,015,000 | 40.762887 | 116 | 0.608615 | false |
phraust1612/cifar100challenge | cnn_renet/init_param.py | 1 | 1166 | import numpy as np
import caffe
import os
def extract_caffe_model(model, weights, output_path):
"""extract caffe model's parameters to numpy array, and write them to files
Args:
model: path of '.prototxt'
weights: path of '.caffemodel'
output_path: output path of numpy params
Returns:
None
"""... | mit | 4,951,470,029,215,791,000 | 23.291667 | 77 | 0.614923 | false |
pignacio/python-nvd3 | examples/MultiBarChart.py | 1 | 1100 | #!/usr/bin/python
# -*- coding: utf-8 -*-
"""
Examples for Python-nvd3 is a Python wrapper for NVD3 graph library.
NVD3 is an attempt to build re-usable charts and chart components
for d3.js without taking away the power that d3.js gives you.
Project location : https://github.com/areski/python-nvd3
"""
from nvd3.mul... | mit | 5,690,117,570,469,445,000 | 29.555556 | 70 | 0.677273 | false |
bigswitch/nova | nova/tests/unit/objects/test_instance_pci_requests.py | 1 | 7650 | # 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
# d... | apache-2.0 | 5,847,374,360,693,659,000 | 44.535714 | 79 | 0.584314 | false |
wagnerand/olympia | src/olympia/addons/tests/test_decorators.py | 2 | 5258 | from django import http
import mock
from six.moves.urllib_parse import quote
from olympia.addons import decorators as dec
from olympia.addons.models import Addon
from olympia.amo.tests import TestCase, addon_factory
class TestAddonView(TestCase):
def setUp(self):
super(TestAddonView, self).setUp()
... | bsd-3-clause | -7,378,501,312,480,588,000 | 35.262069 | 75 | 0.618486 | false |
skosukhin/spack | var/spack/repos/builtin/packages/atompaw/package.py | 1 | 2376 | ##############################################################################
# Copyright (c) 2013-2017, Lawrence Livermore National Security, LLC.
# Produced at the Lawrence Livermore National Laboratory.
#
# This file is part of Spack.
# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved.
# LLNL-CODE-64... | lgpl-2.1 | 127,523,794,832,472,270 | 36.714286 | 78 | 0.638468 | false |
vivisect/synapse | synapse/lib/crypto/ecc.py | 1 | 6535 | import hashlib
import logging
import cryptography.hazmat.primitives.hashes as c_hashes
import cryptography.hazmat.primitives.kdf.hkdf as c_hkdf
import cryptography.hazmat.primitives.asymmetric.ec as c_ec
import cryptography.hazmat.primitives.serialization as c_ser
import cryptography.hazmat.primitives.asymmetric.utils... | apache-2.0 | 910,276,138,974,004,000 | 28.570136 | 81 | 0.57215 | false |
djsegal/ahab_legacy_ | pequod/readInput.py | 1 | 4463 | # -*- coding: utf-8 -*-
"""
Created on Thu Jul 4 17:53:55 2013
@author: dan
"""
from parseLine import parseLine
from findAndChar import findAndChar
from addScalarInput import addScalarInput
from addVectorInput import addVectorInput
def readInput( fileName ):
redInput =... | apache-2.0 | -4,641,275,776,112,193,000 | 29.575342 | 78 | 0.315259 | false |
Virako/Rocamgo-ng | rocamgo/detection/perspective.py | 1 | 2062 | #!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Rocamgo is recogniter of the go games by processing digital images with opencv.
# Copyright (C) 2012 Vรญctor Ramirez de la Corte <virako.9 at gmail dot com>
# Copyright (C) 2012 David Medina Velasco <cuidadoconeltecho at gmail dot com>
#
# This program is free software: you ... | gpl-3.0 | -8,436,673,398,612,741,000 | 35.803571 | 83 | 0.716642 | false |
drabastomek/practicalDataAnalysisCookbook | Codes/Chapter07/ts_detrendAndRemoveSeasonality.py | 1 | 2625 | import pandas as pd
import numpy as np
import matplotlib
import matplotlib.pyplot as plt
# change the font size
matplotlib.rc('xtick', labelsize=9)
matplotlib.rc('ytick', labelsize=9)
matplotlib.rc('font', size=14)
# time series tools
import statsmodels.api as sm
def period_mean(data, freq):
'''
Method t... | gpl-2.0 | 3,813,772,106,951,367,000 | 28.166667 | 61 | 0.684952 | false |
yarikoptic/NiPy-OLD | nipy/neurospin/datasets/volumes/tests/test_volume_field.py | 1 | 1076 | """
Testing data image interface.
"""
import numpy as np
# Local imports
from ..volume_field import VolumeField
from ...transforms.transform import Transform, CompositionError
################################################################################
# Tests
def test_interface():
img = VolumeField()
im... | bsd-3-clause | 3,817,453,609,082,468,400 | 30.647059 | 80 | 0.587361 | false |
mthh/geopy | test/geocoders/photon.py | 1 | 2704 | # -*- coding: UTF-8 -*-
import unittest
from geopy.compat import u
from geopy.point import Point
from geopy.geocoders import Photon
from test.geocoders.util import GeocoderTestBase
class PhotonTestCase(GeocoderTestBase): # pylint: disable=R0904,C0111
@classmethod
def setUpClass(cls):
cls.geocoder =... | mit | 4,715,647,223,500,360,000 | 26.591837 | 77 | 0.538092 | false |
bithinalangot/ecidadania-dev | src/apps/ecidadania/accounts/admin.py | 1 | 2246 | # -*- coding: utf-8 -*-
#
# Copyright (c) 2010-2012 Cidadania S. Coop. Galega
#
# This file is part of e-cidadania.
#
# e-cidadania 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 Licen... | gpl-3.0 | -7,367,780,527,825,596,000 | 39.836364 | 128 | 0.703918 | false |
PJUllrich/Complete-Bunq-API-Python-Wrapper | tests/endpoints/test_installation.py | 1 | 1623 | from apiwrapper.endpoints.installation import Installation
from tests.endpoints.test_endpoint import EndpointTest
class InstallationTest(EndpointTest):
__base_endpoint_url = "/installation"
@property
def _base_endpoint(self):
return self.__base_endpoint_url
def setUp(self):
super().s... | mit | 7,800,149,606,326,693,000 | 30.823529 | 81 | 0.68207 | false |
ouh-churchill/quod | quodsite/website/templatetags/quodsite_tags.py | 1 | 2483 | #!/usr/bin/python
# coding: utf-8
from __future__ import absolute_import, unicode_literals
from django import template
register = template.Library()
@register.simple_tag
def get_model_fields(object_to_query):
return dict(
(field.name, field.value_to_string(object_to_query)) for field in object_to_query._... | mit | 8,645,338,048,120,876,000 | 37.2 | 102 | 0.708417 | false |
ken-muturi/pombola | pombola/kenya/urls.py | 1 | 4552 | from django.conf.urls import patterns, url
from django.views.generic.base import TemplateView
from pombola.kenya.views import KEPersonDetail, KEPersonDetailAppearances
from pombola.experiments.views import ExperimentShare, ExperimentSurvey
from .views import (CountyPerformanceView, CountyPerformanceSenateSubmission,
... | agpl-3.0 | 6,573,117,379,751,098,000 | 38.582609 | 111 | 0.610281 | false |
linkhub-sdk/popbill.taxinvoice.example.py | getSendToNTSConfig.py | 1 | 1031 | # -*- coding: utf-8 -*-
# code for console Encoding difference. Dont' mind on it
import sys
import imp
imp.reload(sys)
try:
sys.setdefaultencoding('UTF8')
except Exception as E:
pass
import testValue
from popbill import TaxinvoiceService, PopbillException
taxinvoiceService = TaxinvoiceService(testValue.Link... | mit | -1,677,486,540,256,732,400 | 24.710526 | 76 | 0.752303 | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.