text
stringlengths
6
947k
repo_name
stringlengths
5
100
path
stringlengths
4
231
language
stringclasses
1 value
license
stringclasses
15 values
size
int64
6
947k
score
float64
0
0.34
import pyaf.Bench.TS_datasets as tsds import tests.artificial.process_artificial_dataset as art art.process_dataset(N = 1024 , FREQ = 'D', seed = 0, trendtype = "PolyTrend", cycle_length = 7, transform = "RelativeDifference", sigma = 0.0, exog_count = 20, ar_order = 0);
antoinecarme/pyaf
tests/artificial/transf_RelativeDifference/trend_PolyTrend/cycle_7/ar_/test_artificial_1024_RelativeDifference_PolyTrend_7__20.py
Python
bsd-3-clause
274
0.083942
# -*- coding: utf-8 -*- from __future__ import print_function, unicode_literals import pytest from django import forms from django.http import QueryDict from test_project.one_to_one.models import Restaurant, Waiter from url_filter.backends.django import DjangoFilterBackend from url_filter.filters import Filter from u...
AlexandreProenca/django-url-filter
tests/filtersets/test_base.py
Python
mit
7,675
0.000782
# encoding: utf-8 # # # This Source Code Form is subject to the terms of the Mozilla Public # License, v. 2.0. If a copy of the MPL was not distributed with this file, # You can obtain one at http://mozilla.org/MPL/2.0/. # # Author: Kyle Lahnakoski (kyle@lahnakoski.com) # from __future__ import absolute_import from __f...
klahnakoski/esReplicate
pyLibrary/queries/namespace/typed.py
Python
mpl-2.0
4,356
0.002525
############################################################ # # Autogenerated by the KBase type compiler - # any changes made here will be overwritten # ############################################################ try: import json as _json except ImportError: import sys sys.path.append('simplejson-2.3.3')...
mdejongh/ModelComparison
lib/ModelComparison/ModelComparisonClient.py
Python
mit
7,099
0.001127
# -*- coding: utf-8 -*- # # Copyright © 2013 Red Hat, Inc. # # This software is licensed to you under the GNU General Public # License as published by the Free Software Foundation; either version # 2 of the License (GPLv2) or (at your option) any later version. # There is NO WARRANTY for this software, express or impli...
beav/pulp
server/test/unit/test_migration_0005.py
Python
gpl-2.0
2,511
0.001195
# coding=utf-8 # Copyright 2022 The Google Research Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicab...
google-research/google-research
multiple_user_representations/models/parametric_attention_test.py
Python
apache-2.0
1,915
0.001567
from maze_builder.sewer import MadLibs, Choice from maze_builder.lost_text.text_decorations import fix_sentence negative_status_sentence = MadLibs({ '{NEGATIVE_STATUS INTENSIFIED SENTENCE FIXED}': 1, '{NEGATIVE_STATUS SENTENCE FIXED}': 1, }, FIXED=fix_sentence, SENTENCE={ '{}.': 30...
kcsaff/maze-builder
maze_builder/lost_text/negative_status.py
Python
mit
5,360
0
# -*- encoding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>). # # ThinkOpen Solutions Brasil # Copyright (C) Thinkopen Solutions <http://www.tkobr.com>. # # This...
thinkopensolutions/tkobr-addons
tko_partner_multiple_phones/__manifest__.py
Python
agpl-3.0
2,154
0.000464
############################################################################# ## ## Copyright (C) 2016 The Qt Company Ltd. ## Contact: https://www.qt.io/licensing/ ## ## This file is part of the test suite of PySide2. ## ## $QT_BEGIN_LICENSE:GPL-EXCEPT$ ## Commercial License Usage ## Licensees holding valid commercial ...
qtproject/pyside-pyside
tests/QtGui/qcolor_test.py
Python
lgpl-2.1
3,949
0.006584
from os import walk files = [] for (dirpath, dirnames, filenames) in walk('./data/'): files.extend(filenames) break data = [] OFratio = None for file in files: t = [] with open('./data/' + file) as f: for i, line in enumerate(f): if i in [15, 24, 25, 29, 31, 34, 39]: ...
ferram4/ProcEngines
GameData/ProcEngines/PropellantMixtures/config_parser.py
Python
mit
928
0.003233
# -*- coding: utf-8 -*- # Style_Check:Python_Fragment (meaning no pyflakes check) # # GNAT build configuration file import sys import os import time import re sys.path.append('.') import ada_pygments import latex_elements # Some configuration values for the various documentation handled by # this conf.py DOCS = { ...
Gurgel100/gcc
gcc/ada/doc/share/conf.py
Python
gpl-2.0
3,966
0.000756
from django.db import models from fluxbb import FLUXBB_PREFIX class SearchWord(models.Model): """ FluxBB Search Word Fields on this model match exactly with those defined by fluxbb, see the [fluxbb dbstructure](http://fluxbb.org/docs/v1.5/dbstructure#users). """ id = models.AutoField(primary_...
kalhartt/django-fluxbb
fluxbb/models/search_word.py
Python
gpl-2.0
481
0
#!/usr/bin/python import smbus import time ''' retrieve data from wii ir camera. x = 0-1023 y = 0-720 size = 1-15? top right of scene = [0,0] ''' def getBlob(n,list): # return x,y,size for blob n (0-3) from list if len(list)<13: return [] x = list[1+(n*3)] y = list[2+(n*3)] s = list[3+(n*3)...
roving99/robot_pi
0mq/wii_ir_test.py
Python
gpl-2.0
966
0.030021
# Copyright (C) 2008 Canonical Ltd # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in ...
Distrotech/bzr
bzrlib/smart/message.py
Python
gpl-2.0
13,276
0
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may ...
Azure/azure-sdk-for-python
sdk/timeseriesinsights/azure-mgmt-timeseriesinsights/azure/mgmt/timeseriesinsights/aio/operations/_reference_data_sets_operations.py
Python
mit
19,516
0.00497
from setuptools import setup, find_packages import os description = "Make sure all source files have your standard licensing stub "\ "at the top." long_description = "" setup(name='plicense', version='0.2.1', description=description, long_description=long_description, classifier...
dsoprea/LicensePrepend
setup.py
Python
gpl-2.0
692
0.001445
# coding: utf-8 # pylint: disable = invalid-name, C0111, C0301 # pylint: disable = R0912, R0913, R0914, W0105, W0201, W0212 """Wrapper c_api of LightGBM""" from __future__ import absolute_import import ctypes import os from tempfile import NamedTemporaryFile import numpy as np import scipy.sparse from .compat import...
cbecker/LightGBM
python-package/lightgbm/basic.py
Python
mit
66,093
0.001407
"""Convert "arbitrary" sound files to AIFF (Apple and SGI's audio format). Input may be compressed. Uncompressed file type may be AIFF, WAV, VOC, 8SVX, NeXT/Sun, and others. An exception is raised if the file is not of a recognized type. Returned filename is either the input filename or a temporary filename; in the la...
MalloyPower/parsing-python
front-end/testsuite-python-lib/Python-2.2/Lib/toaiff.py
Python
mit
2,989
0.004015
# -*- coding: utf-8 -*- """ S3 Query Construction @copyright: 2009-2015 (c) Sahana Software Foundation @license: MIT 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 ...
ScottBuchanan/eden
modules/s3/s3query.py
Python
mit
82,174
0.001217
""" A collection of utility and helper modules. These differ from notary_utils in that they do not depend on or need to connect to the notary database. """
danwent/Perspectives-Server
util/__init__.py
Python
gpl-3.0
156
0.00641
__author__ = 'deevarvar' import string import random import os #generate a random string def string_generator(size=6, chars=string.ascii_letters+string.digits): return ''.join(random.choice(chars) for _ in range(size)) #emulate touch cmd def touchFile(fname, time=None): with open(fname, 'a'): os.uti...
deevarvar/myLab
book/tlpi_zhiye/utlib/ut_util.py
Python
mit
335
0.01194
#!/usr/bin/env python # -*- coding: iso-8859-15 -*- """ Raspymc is a multimedia centre exposed via a http server built with bottlepy Copyright (C) 2013 Giancarlo Fringuello This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as pub...
GiancarloF/raspymc_server
core/conf_manager.py
Python
gpl-3.0
4,528
0.023852
#!/usr/bin/env python from __future__ import print_function import sys import json import csv import StringIO import io from dictUtil import as_dict, merge_dicts import urllib # import jq from itertools import izip from logUtil import logging # for manifest introspection only import inspect from pyspark import SparkC...
usc-isi-i2/WEDC
spark_dependencies/python_lib/digSparkUtil/fileUtil.py
Python
apache-2.0
11,462
0.005496
''' This script is run as root by the osmc update module. ''' import apt import socket import sys from datetime import datetime import json import os import time import subprocess import traceback from CompLogger import comprehensive_logger as clog t = datetime class Logger(object): def __init__(self, filename="Def...
indie1982/osmc-fixes
package/mediacenter-addon-osmc/src/script.module.osmcsetting.updates/resources/lib/apt_cache_action.py
Python
gpl-2.0
11,354
0.035406
#!/usr/bin/env python # # This library is free software, distributed under the terms of # the GNU Lesser General Public License Version 3, or any later version. # See the COPYING file included in this archive # # The docstrings in this module contain epytext markup; API documentation # may be created by processing this...
tjgillies/distributed-draw
entangled/kademlia/constants.py
Python
lgpl-3.0
1,820
0.006593
from sqlalchemy import * from migrate import * from migrate.changeset import schema pre_meta = MetaData() post_meta = MetaData() task = Table('task', post_meta, Column('id', Integer, primary_key=True, nullable=False), Column('parent_id', Integer, default=ColumnDefault(0)), Column('body', String), Colu...
itJunky/web-tasker.py
db_repository/versions/028_migration.py
Python
gpl-2.0
1,041
0.000961
#!/usr/bin/env python3 # -*- coding: utf-8 -*- __author__ = 'zappyk' import sys, subprocess from gi.repository import Gtk, Gio from gi.repository import GLib ############################################################################### class MyWindow(Gtk.Window): def __init__(self): Gtk.Window.__init__...
zappyk-github/zappyk-python
src/src_zappyk/developing/test-gui-Gtk.py
Python
gpl-2.0
4,640
0.009483
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ ODB++ surface parser components """ import re from collections import namedtuple from .Decoder import DecoderOption from .Treeifier import TreeifierRule from .PolygonParser import Polygon from .Structures import Polarity, polarity_map from .Attributes import parse_attr...
ulikoehler/ODBPy
ODBPy/SurfaceParser.py
Python
apache-2.0
1,978
0.004044
# uncompyle6 version 2.9.10 # Python bytecode 2.7 (62211) # Decompiled from: Python 3.6.0b2 (default, Oct 11 2016, 05:27:10) # [GCC 6.2.0 20161005] # Embedded file name: type_Result.py from types import * RESULT_TYPE_PROCESS_HIDE = 0 RESULT_TYPE_PROCESS_UNHIDE = 1 class Result: def __init__(self): self._...
DarthMaulware/EquationGroupLeaks
Leak #5 - Lost In Translation/windows/Resources/Dsz/PyScripts/Lib/dsz/mca/security/cmd/hide/type_Result.py
Python
unlicense
1,899
0.002633
# -*- coding: utf-8 -*- # # TaskBuster documentation build configuration file, created by # sphinx-quickstart on Tue Jun 16 10:01:14 2015. # # 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. # ...
mazulo/taskbuster-boilerplate
docs/conf.py
Python
mit
8,303
0.006263
# -*- coding: utf-8 -*- """The plist event formatter.""" from plaso.formatters import interface from plaso.formatters import manager class PlistFormatter(interface.ConditionalEventFormatter): """Formatter for a plist key event.""" DATA_TYPE = u'plist:key' FORMAT_STRING_SEPARATOR = u'' FORMAT_STRING_PIECES...
ostree/plaso
plaso/formatters/plist.py
Python
apache-2.0
497
0.012072
import sublime, sublime_plugin import difflib import time import datetime import codecs import os def diff_changes(file_name, result): try: if "Body" in result: server = result["Body"].splitlines() elif "Markup" in result: server = result["Markup"].splitlines() loca...
xjsender/haoide
salesforce/lib/diff.py
Python
mit
2,098
0.005243
# posting to: http://localhost:3000/api/articles/update/:articleid with title, content # changes title, content # # id1: (darwinbot1 P@ssw0rd!! 57d748bc67d0eaf026dff431) <-- this will change with differing mongo instances import time # for testing, this is not good import requests # if not installed already, run python...
dubwub/F2016-UPE-AI
sample_AIs/darwinbot2.py
Python
mit
1,018
0.016699
from django.apps import AppConfig class AlarmConfig(AppConfig): name = 'alarm'
pythonvietnam/nms
apps/alarm/apps.py
Python
mit
85
0
# Copyright (c) 2012 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. import json import logging import socket import sys from telemetry.core import util from telemetry.core import exceptions from telemetry.core.chrome impo...
codenote/chromium-test
tools/telemetry/telemetry/core/chrome/inspector_backend.py
Python
bsd-3-clause
9,767
0.009727
#!/usr/bin/python3 import rem_backend.query_data as qd import rem_backend.propagation_model_estimation as pm import threading import _thread __author__ = "Daniel Denkovski", "Valentin Rakovic" __copyright__ = "Copyright (c) 2017, Faculty of Electrical Engineering and Information Technologies, UKIM, Skopje, Macedonia"...
danieldUKIM/controllers_dockers
rem_console/REM_console.py
Python
apache-2.0
2,275
0.037528
""" Support for Lutron lights. For more details about this platform, please refer to the documentation at https://home-assistant.io/components/light.lutron/ """ import logging from homeassistant.components.light import ( ATTR_BRIGHTNESS, SUPPORT_BRIGHTNESS, Light) from homeassistant.components.lutron import ( ...
PetePriority/home-assistant
homeassistant/components/lutron/light.py
Python
apache-2.0
2,793
0
import json as json_ # Template for code 200 requests so data can easily be added def ok(d=None, *, json=True): code = {'code': 200, 'status': 'OK', 'data': d} if json: code = json_.dumps(code) return code # The 400 codes shouldn't require any special aruments. def invalid_request(*, json=True):...
TacticAlpha/basic-lan-webserver
server/status.py
Python
agpl-3.0
938
0
from bank_CI import BankCI from bank_controller import BankController from settings import DB_NAME, CREATE_TABLES, DROP_DATABASE from sql_manager import BankDatabaseManager def main(): manager = BankDatabaseManager.create_from_db_and_sql(DB_NAME, CREATE_TABLES, DROP_DATABASE, create_if_exists=False) controlle...
pepincho/Python101-and-Algo1-Courses
Programming-101-v3/week9/1-Money-In-The-Bank/start.py
Python
mit
465
0.002151
# Major, Minor VERSION = (1, 4)
duointeractive/python-bluefin
bluefin/__init__.py
Python
bsd-3-clause
31
0.032258
# Copyright 2015 Internap. # # 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, so...
internap/netman
netman/core/objects/backward_compatible_switch_operations.py
Python
apache-2.0
3,375
0.003556
#!/usr/bin/python # # Script to send email notifications when a change in Galera cluster membership # occurs. # # Complies with http://www.codership.com/wiki/doku.php?id=notification_command # # Author: Gabe Guillen <gabeguillen@outlook.com> # Version: 1.5 # Release: 3/5/2015 # Use at your own risk. No warranties expr...
gguillen/galeranotify
galeranotify.py
Python
gpl-2.0
5,427
0.00387
# making a class callable: class a(object): def __init__(self, a): print "__init__" self.a = a def __call__(self, *args): print "__call__" self.a = args[0] # Based on this code, when we call a, the __init__ function gets called. My guess # is that we dont have an instance i...
mr-uuid/snippets
python/classes/init_vs_call.py
Python
mit
530
0.001887
# # The MIT License (MIT) # # Copyright (c) 2016 Robert Hammelrath # # 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 rights # to use, cop...
peterhinch/micropython-tft-gui
tft/driver/tft.py
Python
mit
32,591
0.010034
# -*- coding: utf-8 -*- from scrapy.spiders import Rule from scrapy.linkextractors import LinkExtractor from scrapy_redis.spiders import RedisCrawlSpider class BaiduSpider(RedisCrawlSpider): """Spider that reads urls from redis queue (myspider:start_urls).""" name = 'baidu' redis_key = 'crawler:start_keywo...
scrapycloud/scrapy-cluster
crawler/crawler/spiders/baidu.py
Python
mit
979
0.002043
# -*- coding: utf-8 -*- # # Copyright 2012-2015 Spotify AB # # 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...
torypages/luigi
luigi/lock.py
Python
apache-2.0
3,102
0.001289
#!/usr/bin/env python """alerts.py Classes for sendings alerts """ __author__ = "Jean-Martin Archer" __copyright__ = "Copyright 2013, MIT License." import smtplib from twilio.rest import TwilioRestClient from vendors.pushbullet.pushbullet import PushBullet import configuration class Alerts(object): """<ac:im...
j-martin/raspberry-gpio-zmq
raspzmq/alerts.py
Python
mit
3,371
0.00089
# coding=utf-8 # Copyright 2014 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). from __future__ import (absolute_import, division, generators, nested_scopes, print_function, unicode_literals, with_statement) import itertools imp...
kslundberg/pants
src/python/pants/backend/codegen/tasks/protobuf_gen.py
Python
apache-2.0
13,284
0.008883
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright 2012 Michael Still and Canonical Inc # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http:...
ntt-sic/nova
nova/virt/configdrive.py
Python
apache-2.0
6,518
0
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. # # Code generated by Microsoft (R) AutoRest Code Generator. # Changes ...
rjschwei/azure-sdk-for-python
azure-mgmt-web/azure/mgmt/web/models/conn_string_info.py
Python
mit
1,434
0
''' Created on Feb. 23, 2019 Utility functions to extract data from xarray Dataset or DataArray classes. @author: Andre R. Erler, GPL v3 ''' from warnings import warn from datetime import datetime import os import numpy as np import xarray as xr import netCDF4 as nc from dask.diagnostics import ProgressBar # intern...
aerler/HGS-Tools
Python/geospatial/xarray_tools.py
Python
gpl-3.0
40,502
0.015234
#!/usr/bin/env python3.7 # 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 "Li...
chrismattmann/drat
distribution/src/main/resources/bin/list-ghe-repos.py
Python
apache-2.0
1,171
0
from django_markup.filter import MarkupFilter class MarkdownMarkupFilter(MarkupFilter): """ Applies Markdown conversion to a string, and returns the HTML. """ title = 'Markdown' kwargs = {'safe_mode': True} def render(self, text, **kwargs): if kwargs: self.kwargs.update(k...
bartTC/django-markup
django_markup/filter/markdown_filter.py
Python
bsd-3-clause
1,360
0
''' This module is part of ngs_backbone. This module provide mapping related analyses Created on 15/03/2010 @author: peio ''' # Copyright 2009 Jose Blanca, Peio Ziarsolo, COMAV-Univ. Politecnica Valencia # This file is part of franklin. # franklin is free software: you can redistribute it and/or modify # it under the...
JoseBlanca/franklin
franklin/backbone/mapping.py
Python
agpl-3.0
16,787
0.005957
import os from setuptools import setup from setuptools import find_packages with open(os.path.join(os.path.dirname(__file__), 'README.md')) as readme: README = readme.read() # allow setup.py to be run from any path os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir))) setup( name='li...
mrexmelle/liblinesdk-py
setup.py
Python
mit
1,211
0.000826
#* This file is part of the MOOSE framework #* https://www.mooseframework.org #* #* All rights reserved, see COPYRIGHT for full restrictions #* https://github.com/idaholab/moose/blob/master/COPYRIGHT #* #* Licensed under LGPL 2.1, please see LICENSE for details #* https://www.gnu.org/licenses/lgpl-2.1.html import uuid...
nuclear-wizard/moose
python/MooseDocs/extensions/floats.py
Python
lgpl-2.1
8,900
0.004494
# Copyright (c) 2016 VMware, Inc. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required b...
openstack/congress
congress/db/db_ds_table_data.py
Python
apache-2.0
3,233
0
"""Automatic keyboard layout switcher""" import functools import logging import subprocess from typing import Iterable from typing import Set import xkbgroup import swytcher.settings as settings import swytcher.xwindow as xwindow from swytcher.util import suppress_err log = logging.getLogger(__name__) # pylint: dis...
eddie-dunn/swytcher
swytcher/swytcher.py
Python
mit
3,436
0
# -*- coding: utf-8 -*- import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Adding field 'Project.version_privacy_level' db.add_column('projects_project', 'version_privacy_level', ...
d0ugal/readthedocs.org
readthedocs/projects/migrations/0028_add_version_default_privacy.py
Python
mit
9,508
0.007678
"Yang/Wu's OEP implementation, in PyQuante." from math import sqrt import settings from PyQuante.NumWrap import zeros,matrixmultiply,transpose,dot,identity,\ array,solve from PyQuante.Ints import getbasis, getints, getJ,get2JmK,getK from PyQuante.LA2 import geigh,mkdens,trace2,simx from PyQuante.hartree_fock impo...
berquist/PyQuante
PyQuante/OEP.py
Python
bsd-3-clause
25,427
0.019664
import logging import time import os # will change these to specific imports once code is more final from PyQt5.QtCore import * from PyQt5.QtGui import * from PyQt5.QtWidgets import * from PyQt5 import uic BRUSH_WHITE = QBrush(QColor(255, 255, 255), Qt.SolidPattern) BRUSH_GREEN = QBrush(QColor(0, 255, 0), Qt.SolidPat...
missionpinball/mpf-monitor
mpfmonitor/core/devices.py
Python
mit
13,716
0.000948
#!/usr/bin/env python # -*- coding: utf-8 -*- # # ING UNI CT Telegram Bot from telegram.ext import Updater, CommandHandler, MessageHandler, Filters import logging from utils import utility from unidecode import unidecode import json #need load configuration from file ROOMS_FILE='utils/rooms.json' COURSES_FILE='utils...
gabrik/ingunict-bot
ingbot.py
Python
apache-2.0
9,550
0.030389
from setuptools import setup, find_packages with open('README.rst') as f: description = f.read() setup( name='knitty-gritty', version='0.0.2', description='A tool for managing knitting machine patterns', long_description=description, url='https://github.com/mhallin/knitty-gritty', author=...
mhallin/knitty-gritty
setup.py
Python
bsd-3-clause
918
0
from __future__ import absolute_import from __future__ import division from __future__ import unicode_literals __all__ = [ "__title__", "__summary__", "__uri__", "__version__", "__author__", "__email__", "__license__", "__copyright__", ] __title__ = "stockpile" __summary__ = "Generic file storage abstraction"...
pombredanne/stockpile
stockpile/__about__.py
Python
bsd-2-clause
539
0
''' Integration Test for scheduler reboot VM in HA mode. @author: Quarkonics ''' import zstackwoodpecker.test_util as test_util import zstackwoodpecker.test_state as test_state import zstackwoodpecker.test_lib as test_lib import zstackwoodpecker.operations.resource_operations as res_ops import zstackwoodp...
zstackio/zstack-woodpecker
integrationtest/vm/ha/test_one_node_shutdown_with_scheduler.py
Python
apache-2.0
2,920
0.004452
from datetime import date, datetime from dateutil import relativedelta import json import time from openerp.osv import fields, osv from openerp.tools import float_compare from openerp.tools.translate import _ from openerp.tools import DEFAULT_SERVER_DATETIME_FORMAT, DEFAULT_SERVER_DATE_FORMAT from openerp import SUPER...
dendyyangky/sgeede_b2b
sgeede_internal_transfer/stock_internal_transfer.py
Python
unlicense
4,237
0.029974
# -*- coding: utf-8 -*- # # Copyright (C) 2009-2015 Ben Kurtovic <ben.kurtovic@gmail.com> # # 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 ...
earwig/earwigbot
earwigbot/tasks/__init__.py
Python
mit
5,993
0.000167
from ... import Something from . import data try: from ... import Lala except ImportError: pass
arju88nair/projectCulminate
venv/lib/python3.5/site-packages/pylint/test/regrtest_data/beyond_top/__init__.py
Python
apache-2.0
108
0.009259
# pylint:disable-msg=R0201 """docstring""" __revision__ = '' class Interface: """base class for interfaces""" class IMachin(Interface): """docstring""" def truc(self): """docstring""" def troc(self, argument): """docstring""" class Correct1: """docstring""" __implemen...
dbbhattacharya/kitsune
vendor/packages/pylint/test/input/func_interfaces.py
Python
bsd-3-clause
1,802
0.010544
# -*- coding: utf-8 -*- # Generated by Django 1.11.6 on 2017-11-15 14:54 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('backend', '0008_auto_20171115_1443'), ] operations = [ migrations.AddField(...
Petrole/MaturePyRobots
WebPyRobot/backend/migrations/0009_userprofile_level.py
Python
gpl-3.0
460
0
from office import Office from bank import Bank bank = Bank("Open Bank") office = Office("Timisoara", bank) office.open()
vtemian/university_projects
practic_stage/hmw7/main.py
Python
apache-2.0
125
0
# # common.py # # Copyright (C) 2009 Justin Noah <justinnoah@gmail.com> # # Basic plugin template created by: # Copyright (C) 2008 Martijn Voncken <mvoncken@gmail.com> # Copyright (C) 2007-2009 Andrew Resch <andrewresch@gmail.com> # Copyright (C) 2009 Damien Churchill <damoxc@gmail.com> # # Deluge is free software. # #...
justinnoah/autobot
autobot/common.py
Python
apache-2.0
1,761
0.001136
# coding: utf-8 # emacs: -*- mode: python; py-indent-offset: 4; indent-tabs-mode: nil -*- # vi: set ft=python sts=4 ts=4 sw=4 et: """ =================== dMRI: Preprocessing =================== Introduction ============ This script, dmri_preprocessing.py, demonstrates how to prepare dMRI data for tractography and co...
BrainIntensive/OnlineBrainIntensive
resources/nipype/nipype/examples/dmri_preprocessing.py
Python
mit
5,464
0.000549
# Copyright (C) 2019 The Electrum developers # Distributed under the MIT software license, see the accompanying # file LICENCE or http://www.opensource.org/licenses/mit-license.php import asyncio import base64 from distutils.version import LooseVersion from PyQt5.QtCore import Qt, QThread, pyqtSignal from PyQt5.QtWid...
wakiyamap/electrum-mona
electrum_mona/gui/qt/update_checker.py
Python
mit
6,116
0.00327
"""Common code for Withings.""" import asyncio from dataclasses import dataclass import datetime from datetime import timedelta from enum import Enum, IntEnum import logging import re from typing import Any, Callable, Dict, List, Optional, Tuple, Union from aiohttp.web import Response import requests from withings_api...
turbokongen/home-assistant
homeassistant/components/withings/common.py
Python
apache-2.0
34,960
0.00083
""" QFileDialog objects can only be run in the main thread. """ ### imports ################################################################### import os import time from PySide2 import QtCore from PySide2 import QtWidgets from pycmds.project import project_globals as g from pycmds.project import classes as pc ...
wright-group/PyCMDS
pycmds/project/file_dialog_handler.py
Python
mit
4,481
0.000893
#!usr/bin/env python # # Copyright 2013 Matthew Wall # See the file LICENSE.txt for your full rights. # # Thanks to Kenneth Lavrsen for the Open2300 implementation: # http://www.lavrsen.dk/foswiki/bin/view/Open2300/WebHome # description of the station communication interface: # http://www.lavrsen.dk/foswiki/bin/vie...
knnniggett/weewx
bin/weewx/drivers/ws23xx.py
Python
gpl-3.0
77,294
0.004463
from __future__ import unicode_literals import logging import os import string import urllib import urlparse import glib logger = logging.getLogger(__name__) XDG_DIRS = { 'XDG_CACHE_DIR': glib.get_user_cache_dir(), 'XDG_CONFIG_DIR': glib.get_user_config_dir(), 'XDG_DATA_DIR': glib.get_user_data_dir(),...
abarisain/mopidy
mopidy/utils/path.py
Python
apache-2.0
5,006
0.0002
def First_Part(orbits): Orbits = dict() checksum = 0 for orbit in orbits: od, og = orbit.split(')') Orbits[og] = od for og in Orbits.keys(): while 1: try: og = Orbits[og] checksum += 1 except KeyError: break...
ImpregnableProgrammer/Advent-of-Code
2019/Day_06.py
Python
gpl-3.0
1,071
0.006536
#!/usr/bin/env python # -*- coding: utf-8 -*- # author: J.Y Han # start # spawn-fcgi -d /users/hanjiyun/project/geeksoho -f /users/hanjiyun/project/geeksoho/application.py -a 127.0.0.1 -p 9001 #stop # kill `pgrep -f "/users/hanjiyun/project/geeksoho/application.py"` import os import web import rediswebpy from web....
naoyeye/geeksoho
application.py
Python
mit
1,969
0.019457
from __future__ import with_statement from ofxclient.account import Account from configparser import ConfigParser import os import os.path try: import keyring KEYRING_AVAILABLE = True except: KEYRING_AVAILABLE = False try: DEFAULT_CONFIG = os.path.expanduser(os.path.join('~', 'ofxclient.ini')) except:...
jbms/ofxclient
ofxclient/config.py
Python
mit
9,882
0.000506
# -------------------------------------------------------------------------- # # Copyright (c) Microsoft Corporation. All rights reserved. # # The MIT License (MIT) # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the ""Software""),...
sharadagarwal/autorest
AutoRest/Generators/Python/Azure.Python.Tests/AcceptanceTests/paging_tests.py
Python
mit
6,270
0.003191
import os from threading import RLock from path import Path import mtt.config as base_config # noqa __all__ = ['config', 'lock'] class ConfigAccessor: def __init__(self, configuration_items): self.config = configuration_items def update(self, other): self.config.update(other.config if 'co...
halcy/MastodonToTwitter
mtt/__init__.py
Python
mit
1,421
0
import unittest from integration.thrift.test_thrift import ThriftTestCase from scales.thriftmux import ThriftMux class ThriftMuxTestCase(ThriftTestCase): BUILDER = ThriftMux if __name__ == '__main__': unittest.main()
steveniemitz/scales
test/integration/thrift/test_mux.py
Python
mit
224
0.017857
from mediadrop.lib.auth.group_based_policy import *
kgao/MediaDrop
mediacore/lib/auth/group_based_policy.py
Python
gpl-3.0
52
0
import os from queue import Queue from bears.python.requirements.PySafetyBear import PySafetyBear from coalib.settings.Section import Section from coalib.settings.Setting import Setting from coalib.testing.LocalBearTestHelper import LocalBearTestHelper from coalib.results.Result import Result from coalib.results.RESUL...
coala/coala-bears
tests/python/requirements/PySafetyBearWithoutMockTest.py
Python
agpl-3.0
5,749
0
import datetime import uuid from flask import current_app as app from flask import url_for from database import db from sqlalchemy import Column, DateTime, String, Text from sqlalchemy.dialects.postgresql import UUID class Poster(db.Model): __tablename__ = 'posters' id = Column(UUID(as_uuid=True), primary_...
TailorDev/pauling
api/models.py
Python
mit
2,935
0.001704
#!/usr/bin/python # -*- coding: utf-8 -*- # Copyright (c) 2013, 2014, Pyhrol, pyhrol@rambler.ru # GEO: N55.703431,E37.623324 .. N48.742359,E44.536997 # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistri...
dyomas/pyhrol
examples/example_0050.py
Python
bsd-3-clause
1,983
0.00706
#!/usr/bin/env python # # fdaemon.py # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License version 2 as # published by the Free Software Foundation. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; w...
Dennisparchkov/rumal
interface/management/commands/fdaemon.py
Python
gpl-2.0
10,312
0.001649
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations class Migration(migrations.Migration): dependencies = [ ('hhlregistrations', '0004_auto_20150411_1935'), ] operations = [ migrations.AddField( model_name='event', ...
hacklab-fi/hhlevents
hhlevents/apps/hhlregistrations/migrations/0005_auto_20150412_1806.py
Python
bsd-3-clause
592
0
#!/usr/bin/env python # # Electrum - lightweight Bitcoin client # Copyright (C) 2011 thomasv@gitorious # # 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 of the License, or # (at...
wozz/electrum-myr
lib/transaction.py
Python
gpl-3.0
30,650
0.006754
from django.apps import AppConfig class DocenteConfig(AppConfig): name = 'docente'
Bleno/sisgestor-django
docente/apps.py
Python
mit
89
0
import unittest import json from privacyidea.app import create_app from privacyidea.models import db from privacyidea.lib.resolver import (save_resolver) from privacyidea.lib.realm import (set_realm) from privacyidea.lib.user import User from privacyidea.lib.auth import create_db_admin from privacyidea.api.lib.postpoli...
woddx/privacyidea
tests/base.py
Python
agpl-3.0
4,803
0.000625
#------------------------------------------------------------------------------ __author__ = 'James T. Dietrich' __contact__ = 'james.t.dietrich@dartmouth.edu' __copyright__ = '(c) James Dietrich 2016' __license__ = 'MIT' __date__ = 'Wed Nov 16 11:33:39 2016' __version__ = '1.0' __status__ = "initial release" __url__ =...
geojames/Dart_EnvGIS
Week6-2_Matplotlib_Adv.py
Python
mit
3,114
0.008992
# -------------------------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # --------------------------------------------------------------------...
yugangw-msft/azure-cli
src/azure-cli/azure/cli/command_modules/vm/disk_encryption.py
Python
mit
27,499
0.004291
import tornado.web import traceback from plugins.bases.plugin import PluginBase import os import sys import gdata import gdata.youtube import gdata.youtube.service class HandlersBase(tornado.web.RequestHandler, PluginBase): # Every handler must have a web path, override this in this fashion WEB_PATH = r"/" ...
anzenehansen/wedding-photos
plugins/bases/handlers.py
Python
mpl-2.0
4,489
0.008911
"""Initial Revision ID: cfbd6d35cab Revises: Create Date: 2015-03-04 04:13:56.547992 """ # revision identifiers, used by Alembic. revision = 'cfbd6d35cab' down_revision = None branch_labels = None depends_on = None from alembic import op import sqlalchemy as sa def upgrade(): ### commands auto generated by A...
PEDSnet/pedsnetcdms
pedsnetcdms/pedsnetcdm/alembic/versions/cfbd6d35cab_initial.py
Python
bsd-2-clause
30,989
0.012101
# ------------------------------------ # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # ------------------------------------ from azure.core.exceptions import ServiceRequestError from azure.identity._internal.msal_client import MsalClient import pytest from helpers import mock, mock_response...
Azure/azure-sdk-for-python
sdk/identity/azure-identity/tests/test_msal_client.py
Python
mit
1,769
0.001131
from pattern import Pattern import copy import numpy as np import random import collections #from scipy.signal import convolve2d import time from collections import deque class SpiralOutFast(Pattern): def __init__(self): self.register_param("r_leak", 0, 3, 1.2) self.register_param("g_leak", 0, 3, ...
TheGentlemanOctopus/thegentlemanoctopus
octopus_code/core/octopus/patterns/spiralOutFast.py
Python
gpl-3.0
1,846
0.008667
# -*- coding: utf-8 -*- import math from kivy.uix.widget import Widget from kivy.graphics import Color, Line from kivy.vector import Vector from kivy.properties import StringProperty, DictProperty, BooleanProperty, BoundedNumericProperty, ListProperty class Painter(Widget): tools = DictProperty({'arrow': {'color...
octogene/hadaly
hadaly/painter.py
Python
gpl-3.0
3,680
0.00163