hexsha
stringlengths
40
40
size
int64
2
1.02M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
245
max_stars_repo_name
stringlengths
6
130
max_stars_repo_head_hexsha
stringlengths
40
40
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
⌀
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
⌀
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
⌀
max_issues_repo_path
stringlengths
4
245
max_issues_repo_name
stringlengths
6
130
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
⌀
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
⌀
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
⌀
max_forks_repo_path
stringlengths
4
245
max_forks_repo_name
stringlengths
6
130
max_forks_repo_head_hexsha
stringlengths
40
40
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
⌀
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
⌀
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
⌀
content
stringlengths
2
1.02M
avg_line_length
float64
1
958k
max_line_length
int64
1
987k
alphanum_fraction
float64
0
1
content_no_comment
stringlengths
0
1.01M
is_comment_constant_removed
bool
2 classes
is_sharp_comment_removed
bool
1 class
f7511f68524d17306278ebd53d92567effd7ca7c
4,153
py
Python
tests/python/test_training_continuation.py
cnheider/xgboost
e7fbc8591fa7277ee4c474b7371c48c11b34cbde
[ "Apache-2.0" ]
769
2015-01-02T03:15:00.000Z
2022-03-30T11:22:52.000Z
tests/python/test_training_continuation.py
cnheider/xgboost
e7fbc8591fa7277ee4c474b7371c48c11b34cbde
[ "Apache-2.0" ]
54
2015-01-01T01:12:39.000Z
2017-05-21T02:56:14.000Z
tests/python/test_training_continuation.py
cnheider/xgboost
e7fbc8591fa7277ee4c474b7371c48c11b34cbde
[ "Apache-2.0" ]
372
2015-01-03T21:10:27.000Z
2022-03-03T03:46:36.000Z
import xgboost as xgb import testing as tm import numpy as np import unittest rng = np.random.RandomState(1337) class TestTrainingContinuation(unittest.TestCase): num_parallel_tree = 3 xgb_params_01 = { 'silent': 1, 'nthread': 1, } xgb_params_02 = { 'silent': 1, 'nth...
39.552381
113
0.696123
import xgboost as xgb import testing as tm import numpy as np import unittest rng = np.random.RandomState(1337) class TestTrainingContinuation(unittest.TestCase): num_parallel_tree = 3 xgb_params_01 = { 'silent': 1, 'nthread': 1, } xgb_params_02 = { 'silent': 1, 'nth...
true
true
f7512127ab64dbce8276dcc2b2dab1fb7e2e7e00
29,037
py
Python
runtest.py
ravenAtSafe/scons
ebe6e9b1b2fedbe3dd44c07aa2b6739d4079879e
[ "MIT" ]
null
null
null
runtest.py
ravenAtSafe/scons
ebe6e9b1b2fedbe3dd44c07aa2b6739d4079879e
[ "MIT" ]
null
null
null
runtest.py
ravenAtSafe/scons
ebe6e9b1b2fedbe3dd44c07aa2b6739d4079879e
[ "MIT" ]
null
null
null
#!/usr/bin/env python # # Copyright The SCons Foundation # # runtest.py - wrapper script for running SCons tests # # The SCons test suite consists of: # # - unit tests - included in *Tests.py files from SCons/ dir # - end-to-end tests - these are *.py files in test/ directory that # req...
33.14726
152
0.589868
import getopt import glob import os import re import stat import subprocess import sys import tempfile import threading import time from abc import ABC, abstractmethod from optparse import OptionParser, BadOptionError from queue import Queue cwd = os.getcwd() baseline = None external = 0 devmode = False debug = '' ...
true
true
f751216398cfa36014558e25485b351239c660c9
3,911
py
Python
witio/splitwise.py
dizzy54/munimji
2d6616b4924e12d465ec352119a1621c925adc81
[ "MIT" ]
null
null
null
witio/splitwise.py
dizzy54/munimji
2d6616b4924e12d465ec352119a1621c925adc81
[ "MIT" ]
null
null
null
witio/splitwise.py
dizzy54/munimji
2d6616b4924e12d465ec352119a1621c925adc81
[ "MIT" ]
null
null
null
from requests_oauthlib import OAuth1Session from django.conf import settings client_key = settings.SPLITWISE_CLIENT_KEY client_secret = settings.SPLITWISE_CLIENT_SECRET def get_request_token(): """ obtain generic resource owner key and secret from splitwise """ request_token_url = 'https://secure.splitw...
35.554545
107
0.695474
from requests_oauthlib import OAuth1Session from django.conf import settings client_key = settings.SPLITWISE_CLIENT_KEY client_secret = settings.SPLITWISE_CLIENT_SECRET def get_request_token(): request_token_url = 'https://secure.splitwise.com/api/v3.0/get_request_token' oauth = OAuth1Session(client_key, cl...
true
true
f751233cccdf9939537a4739717ad55b16a70944
1,016
py
Python
py-junos-eznc/tests/unit/factory/test_factory_cls.py
fostasha/pynet_test
99a23f64976dc4b9bae17f6f9330b1867a1e74a8
[ "Apache-2.0" ]
1
2021-01-18T09:00:36.000Z
2021-01-18T09:00:36.000Z
py-junos-eznc/tests/unit/factory/test_factory_cls.py
fostasha/pynet_test
99a23f64976dc4b9bae17f6f9330b1867a1e74a8
[ "Apache-2.0" ]
null
null
null
py-junos-eznc/tests/unit/factory/test_factory_cls.py
fostasha/pynet_test
99a23f64976dc4b9bae17f6f9330b1867a1e74a8
[ "Apache-2.0" ]
null
null
null
__author__ = "Rick Sherman" __credits__ = "Jeremy Schulman" import unittest from nose.plugins.attrib import attr from jnpr.junos.factory.factory_cls import FactoryCfgTable, FactoryOpTable from jnpr.junos.factory.factory_cls import FactoryTable, FactoryView @attr('unit') class TestFactoryCls(unittest.TestCase): ...
31.75
74
0.711614
__author__ = "Rick Sherman" __credits__ = "Jeremy Schulman" import unittest from nose.plugins.attrib import attr from jnpr.junos.factory.factory_cls import FactoryCfgTable, FactoryOpTable from jnpr.junos.factory.factory_cls import FactoryTable, FactoryView @attr('unit') class TestFactoryCls(unittest.TestCase): ...
true
true
f751246f2079539cc141ab9fdd4e240c1b12b703
890
py
Python
tutorial/tutorial/urls.py
zengjiapei3000/django_rest_tutorial
307723f68ff5e1f5ad75bfbeeb67e713f27bd846
[ "BSD-3-Clause" ]
null
null
null
tutorial/tutorial/urls.py
zengjiapei3000/django_rest_tutorial
307723f68ff5e1f5ad75bfbeeb67e713f27bd846
[ "BSD-3-Clause" ]
null
null
null
tutorial/tutorial/urls.py
zengjiapei3000/django_rest_tutorial
307723f68ff5e1f5ad75bfbeeb67e713f27bd846
[ "BSD-3-Clause" ]
1
2020-12-05T02:53:11.000Z
2020-12-05T02:53:11.000Z
"""tutorial URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/2.2/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: path('', views.home, name='home') Class-base...
35.6
77
0.706742
from django.contrib import admin from django.urls import path, include from django.conf.urls import include urlpatterns = [ path('admin/', admin.site.urls), path('', include('snippets.urls')), path('api-auth/', include('rest_framework.urls')) ]
true
true
f75124aac7250c49aa1ddaacc5669b0e85545f50
1,468
py
Python
salt/transport/__init__.py
MeAndTheFirefly/salt
77fc3ec3ee25c1b769cc66ddee09067d18080844
[ "Apache-2.0" ]
2
2016-11-14T15:08:53.000Z
2016-11-20T09:25:30.000Z
salt/transport/__init__.py
snetsystems/salt
6f8bedfc2453624e00037f80b8099ed010fad506
[ "Apache-2.0" ]
3
2021-03-31T19:53:24.000Z
2021-12-13T20:46:19.000Z
salt/transport/__init__.py
snetsystems/salt
6f8bedfc2453624e00037f80b8099ed010fad506
[ "Apache-2.0" ]
2
2020-11-04T06:32:02.000Z
2020-11-06T11:01:18.000Z
# -*- coding: utf-8 -*- """ Encapsulate the different transports available to Salt. """ # Import Python libs from __future__ import absolute_import, print_function, unicode_literals import logging # Import Salt libs import salt.utils.versions # Import third party libs from salt.ext import six from salt.ext.six.moves...
27.185185
84
0.642371
from __future__ import absolute_import, print_function, unicode_literals import logging import salt.utils.versions from salt.ext import six from salt.ext.six.moves import range log = logging.getLogger(__name__) def iter_transport_opts(opts): transports = set() for transport, opts_overrides in six.iterite...
true
true
f7512507ce68cbc943dd62b8260b359461bd408c
425
py
Python
force_displaying_website/force_displaying_website/wsgi.py
LeeviHok/force-displaying-website
792dd5dd1febe3cebade73e407a6145a7aeeef2f
[ "MIT" ]
null
null
null
force_displaying_website/force_displaying_website/wsgi.py
LeeviHok/force-displaying-website
792dd5dd1febe3cebade73e407a6145a7aeeef2f
[ "MIT" ]
3
2021-04-08T21:24:14.000Z
2021-06-10T19:49:18.000Z
force_displaying_website/force_displaying_website/wsgi.py
LeeviHok/force-displaying-website
792dd5dd1febe3cebade73e407a6145a7aeeef2f
[ "MIT" ]
null
null
null
""" WSGI config for force_displaying_website project. It exposes the WSGI callable as a module-level variable named ``application``. For more information on this file, see https://docs.djangoproject.com/en/3.0/howto/deployment/wsgi/ """ import os from django.core.wsgi import get_wsgi_application os.environ.setdefa...
25
84
0.802353
import os from django.core.wsgi import get_wsgi_application os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'force_displaying_website.settings') application = get_wsgi_application()
true
true
f75126124ddd0d761688abf0be3fd1efe56fa7b7
510
py
Python
meiduo_mall/meiduo_mall/apps/oauth/models.py
shenhaiyu0923/meiduo_project
0ba91533294c5bb6f8ca54f93eabdff007a3560f
[ "MIT" ]
4
2021-04-30T05:45:32.000Z
2021-04-30T05:56:03.000Z
meiduo_mall/meiduo_mall/apps/oauth/models.py
shenhaiyu0923/meiduo_project
0ba91533294c5bb6f8ca54f93eabdff007a3560f
[ "MIT" ]
null
null
null
meiduo_mall/meiduo_mall/apps/oauth/models.py
shenhaiyu0923/meiduo_project
0ba91533294c5bb6f8ca54f93eabdff007a3560f
[ "MIT" ]
null
null
null
from django.db import models # Create your models here. from django.db import models from meiduo_mall.utils.models import BaseModel # Create your models here.s class OAuthQQUser(BaseModel): """QQ登录用户数据""" user = models.ForeignKey('users.User', on_delete=models.CASCADE, verbose_name='用户') openid = models...
28.333333
87
0.72549
from django.db import models from django.db import models from meiduo_mall.utils.models import BaseModel class OAuthQQUser(BaseModel): user = models.ForeignKey('users.User', on_delete=models.CASCADE, verbose_name='用户') openid = models.CharField(max_length=64, verbose_name='openid', db_index=True) class...
true
true
f7512708c965e76060df90fcb1a090beca8092e1
1,223
py
Python
webapp/main/models.py
mign0n/super_budget
601f40da353d077496eea7806bb25ddb46ec9a36
[ "MIT" ]
null
null
null
webapp/main/models.py
mign0n/super_budget
601f40da353d077496eea7806bb25ddb46ec9a36
[ "MIT" ]
null
null
null
webapp/main/models.py
mign0n/super_budget
601f40da353d077496eea7806bb25ddb46ec9a36
[ "MIT" ]
null
null
null
from webapp.user.models import User from webapp.db import db class Category(db.Model): __tablename__ = 'categories' id = db.Column(db.Integer, primary_key=True) user_id = db.Column(db.Integer, db.ForeignKey(User.id)) name = db.Column(db.String(50), nullable=False) is_income = db.Column(db.Boolean,...
33.972222
86
0.644317
from webapp.user.models import User from webapp.db import db class Category(db.Model): __tablename__ = 'categories' id = db.Column(db.Integer, primary_key=True) user_id = db.Column(db.Integer, db.ForeignKey(User.id)) name = db.Column(db.String(50), nullable=False) is_income = db.Column(db.Boolean,...
true
true
f751277abcf46652bbbabd7f031535da80b64e40
3,737
py
Python
ops/ngs.py
feldman4/NatureProtocols
a0a6775b8edfc493ac6265b1844040c1ae29c33b
[ "MIT" ]
10
2019-03-21T20:23:38.000Z
2022-02-07T16:34:37.000Z
ops/ngs.py
feldman4/NatureProtocols
a0a6775b8edfc493ac6265b1844040c1ae29c33b
[ "MIT" ]
12
2019-08-03T01:35:18.000Z
2022-03-12T00:58:27.000Z
ops/ngs.py
feldman4/NatureProtocols
a0a6775b8edfc493ac6265b1844040c1ae29c33b
[ "MIT" ]
8
2019-02-18T14:00:25.000Z
2021-09-20T18:45:48.000Z
import pandas as pd import numpy as np from glob import glob from natsort import natsorted # TODO: from ops.constants import * from . import utils def load_hist(filename, threshold): try: return (pd.read_csv(filename, sep='\s+', header=None) .rename(columns={0: 'count', 1: 'seq'}) ...
36.637255
80
0.568906
import pandas as pd import numpy as np from glob import glob from natsort import natsorted from . import utils def load_hist(filename, threshold): try: return (pd.read_csv(filename, sep='\s+', header=None) .rename(columns={0: 'count', 1: 'seq'}) .query('count > @threshold') ...
true
true
f75127c9574731eb316b697deb0c4352e85c2885
806
py
Python
examples/converting_units.py
Rory-Sullivan/yrlocationforecast
26b66834cac4569704daf0009a9d2bba39dbfb75
[ "MIT" ]
13
2020-07-28T17:47:42.000Z
2022-03-30T13:35:12.000Z
examples/converting_units.py
Rory-Sullivan/yrlocationforecast
26b66834cac4569704daf0009a9d2bba39dbfb75
[ "MIT" ]
5
2020-10-14T11:10:13.000Z
2022-01-01T17:35:19.000Z
examples/converting_units.py
Rory-Sullivan/yrlocationforecast
26b66834cac4569704daf0009a9d2bba39dbfb75
[ "MIT" ]
6
2020-10-16T12:30:07.000Z
2022-02-18T07:13:21.000Z
"""How to change the units of certain variables.""" from metno_locationforecast import Place, Forecast USER_AGENT = "metno_locationforecast/1.0 https://github.com/Rory-Sullivan/yrlocationforecast" london = Place("London", 51.5, -0.1, 25) london_forecast = Forecast(london, USER_AGENT) london_forecast.update() # Itera...
33.583333
93
0.725806
from metno_locationforecast import Place, Forecast USER_AGENT = "metno_locationforecast/1.0 https://github.com/Rory-Sullivan/yrlocationforecast" london = Place("London", 51.5, -0.1, 25) london_forecast = Forecast(london, USER_AGENT) london_forecast.update() for interval in london_forecast.data.intervals: for var...
true
true
f75128c7207f99dac300ef6a42b9727400d18fc4
2,211
py
Python
gmprocess/metrics/reduction/arias.py
norfordb/groundmotion
3f714894a34d9d37e1ac236f26b4366e25a05056
[ "CC0-1.0" ]
null
null
null
gmprocess/metrics/reduction/arias.py
norfordb/groundmotion
3f714894a34d9d37e1ac236f26b4366e25a05056
[ "CC0-1.0" ]
null
null
null
gmprocess/metrics/reduction/arias.py
norfordb/groundmotion
3f714894a34d9d37e1ac236f26b4366e25a05056
[ "CC0-1.0" ]
null
null
null
# Third party imports import numpy as np from scipy import integrate # Local imports from gmprocess.constants import GAL_TO_PCTG from gmprocess.metrics.reduction.reduction import Reduction from gmprocess.stationstream import StationStream from gmprocess.stationtrace import StationTrace class Arias(Reduction): ""...
38.12069
81
0.637268
import numpy as np from scipy import integrate from gmprocess.constants import GAL_TO_PCTG from gmprocess.metrics.reduction.reduction import Reduction from gmprocess.stationstream import StationStream from gmprocess.stationtrace import StationTrace class Arias(Reduction): def __init__(self, reduction_data, bandw...
true
true
f75128ed515675fc763f11f0b69acdec3a32cda1
9,570
py
Python
app/util/stack.py
bahtiyarkaba/flamescope
64eb9ca37f9680f280e94c0953a3ed2da0576199
[ "Apache-2.0" ]
null
null
null
app/util/stack.py
bahtiyarkaba/flamescope
64eb9ca37f9680f280e94c0953a3ed2da0576199
[ "Apache-2.0" ]
null
null
null
app/util/stack.py
bahtiyarkaba/flamescope
64eb9ca37f9680f280e94c0953a3ed2da0576199
[ "Apache-2.0" ]
null
null
null
# This file is part of FlameScope, a performance analysis tool created by the # Netflix cloud performance team. See: # # https://github.com/Netflix/flamescope # # Copyright 2018 Netflix, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance wi...
32.886598
86
0.555172
from ..common import fileutil import os import gzip import collections from flask import abort from os import walk from os.path import abspath, join from app import config from math import ceil, floor from .regexp import event_regexp, idle_regexp, comm_regexp, frame_regexp stack_times = {} stack_mtimes = {} ...
true
true
f751290d5762858bd9016ddd6f26077a58a002ea
527
py
Python
ofagent/indigo/submodules/loxigen-artifacts/pyloxi/loxi/of13/__init__.py
lanpinguo/apple-sauce
b16e7b78e58d0d17ad7f05476f38704a6b519ece
[ "Apache-2.0" ]
1
2021-05-14T15:33:21.000Z
2021-05-14T15:33:21.000Z
ofagent/indigo/submodules/loxigen-artifacts/pyloxi/loxi/of13/__init__.py
lanpinguo/apple-sauce
b16e7b78e58d0d17ad7f05476f38704a6b519ece
[ "Apache-2.0" ]
null
null
null
ofagent/indigo/submodules/loxigen-artifacts/pyloxi/loxi/of13/__init__.py
lanpinguo/apple-sauce
b16e7b78e58d0d17ad7f05476f38704a6b519ece
[ "Apache-2.0" ]
2
2019-07-13T06:58:33.000Z
2022-03-23T03:02:57.000Z
# Copyright (c) 2008 The Board of Trustees of The Leland Stanford Junior University # Copyright (c) 2011, 2012 Open Networking Foundation # Copyright (c) 2012, 2013 Big Switch Networks, Inc. # See the file LICENSE.pyloxi which should have been included in the source distribution # Automatically generated by LOXI from ...
31
88
0.796964
import action, common, const, message import instruction import oxm import meter_band import bsn_tlv from const import * from common import * from loxi import ProtocolError
true
true
f75129205c26329f2fe548db2d4a04d0d5769e48
6,202
py
Python
src/information_value.py
icyyy/information_value
8d71ab742e285f452e1dc0dc7952a924a27167ec
[ "MIT" ]
115
2016-04-08T07:15:14.000Z
2020-12-30T14:10:45.000Z
src/information_value.py
dljnh66/information_value
8d71ab742e285f452e1dc0dc7952a924a27167ec
[ "MIT" ]
1
2018-12-17T12:33:25.000Z
2018-12-17T12:33:25.000Z
src/information_value.py
dljnh66/information_value
8d71ab742e285f452e1dc0dc7952a924a27167ec
[ "MIT" ]
87
2016-04-17T07:47:53.000Z
2021-12-27T13:47:18.000Z
import numpy as np import math from scipy import stats from sklearn.utils.multiclass import type_of_target class WOE: def __init__(self): self._WOE_MIN = -20 self._WOE_MAX = 20 def woe(self, X, y, event=1): ''' Calculate woe of each feature category and information value ...
36.482353
123
0.579652
import numpy as np import math from scipy import stats from sklearn.utils.multiclass import type_of_target class WOE: def __init__(self): self._WOE_MIN = -20 self._WOE_MAX = 20 def woe(self, X, y, event=1): self.check_target_binary(y) X1 = self.feature_discretion(X) re...
true
true
f7512a4bf11e41ab51e13899a31c284b98f867c2
4,804
py
Python
asposewordscloud/models/requests/get_runs_request.py
rizwanniazigroupdocs/aspose-words-cloud-python
b943384a1e3c0710cc84df74119e6edf7356037e
[ "MIT" ]
null
null
null
asposewordscloud/models/requests/get_runs_request.py
rizwanniazigroupdocs/aspose-words-cloud-python
b943384a1e3c0710cc84df74119e6edf7356037e
[ "MIT" ]
null
null
null
asposewordscloud/models/requests/get_runs_request.py
rizwanniazigroupdocs/aspose-words-cloud-python
b943384a1e3c0710cc84df74119e6edf7356037e
[ "MIT" ]
null
null
null
# coding: utf-8 # ----------------------------------------------------------------------------------- # <copyright company="Aspose" file="get_runs_request.py"> # Copyright (c) 2020 Aspose.Words for Cloud # </copyright> # <summary> # Permission is hereby granted, free of charge, to any person obtaining a copy # of ...
43.672727
127
0.630516
from six.moves.urllib.parse import quote class GetRunsRequest(object): def __init__(self, name, paragraph_path, folder=None, storage=None, load_encoding=None, password=None): self.name = name self.paragraph_path = paragraph_path self.folder = folder self.storage = storage ...
true
true
f7512a6d34da77db83dacda0bd4b23759e5ce626
493
py
Python
apps/users/migrations/0002_user_is_mp_user.py
chenyifaerfans/fafaer-apis
896db11116fc78c597ebc1a90f547dc15004438d
[ "MIT" ]
null
null
null
apps/users/migrations/0002_user_is_mp_user.py
chenyifaerfans/fafaer-apis
896db11116fc78c597ebc1a90f547dc15004438d
[ "MIT" ]
null
null
null
apps/users/migrations/0002_user_is_mp_user.py
chenyifaerfans/fafaer-apis
896db11116fc78c597ebc1a90f547dc15004438d
[ "MIT" ]
1
2019-03-17T12:46:20.000Z
2019-03-17T12:46:20.000Z
# -*- coding: utf-8 -*- # Generated by Django 1.11.15 on 2018-08-08 22:12 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('users', '0001_initial'), ] operations = [ migrations.AddField( ...
23.47619
104
0.600406
from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('users', '0001_initial'), ] operations = [ migrations.AddField( model_name='user', name='is_mp_user', field=model...
true
true
f7512b20d86ed15549783d605d6173d2a83d6a58
5,028
py
Python
keras_frcnn/vgg.py
Wall-ee/keras-fastcrnn-BCCD
b1e974bafc70d3324ca2efb613debeaa127779be
[ "Apache-2.0" ]
null
null
null
keras_frcnn/vgg.py
Wall-ee/keras-fastcrnn-BCCD
b1e974bafc70d3324ca2efb613debeaa127779be
[ "Apache-2.0" ]
1
2020-08-09T12:26:12.000Z
2020-08-09T12:26:12.000Z
keras_frcnn/vgg.py
Wall-ee/keras-fastcrnn-BCCD
b1e974bafc70d3324ca2efb613debeaa127779be
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- """VGG16 model for Keras. # Reference - [Very Deep Convolutional Networks for Large-Scale Image Recognition](https://arxiv.org/abs/1409.1556) """ from __future__ import print_function from __future__ import absolute_import from __future__ import division import warnings from keras.models impor...
39.590551
154
0.676213
from __future__ import print_function from __future__ import absolute_import from __future__ import division import warnings from keras.models import Model from keras.layers import Flatten, Dense, Input, Conv2D, MaxPooling2D, Dropout from keras.layers import GlobalAveragePooling2D, GlobalMaxPooling2D, TimeDistributed...
true
true
f7512bfaab7c55b6fd4ab8e830a0a594d5361c60
4,406
py
Python
src/testproject/sdk/internal/helpers/redact_helper.py
Fnckerpoi/python-opensdk
37e528ea613686975d58b230c16647324271a0bd
[ "Apache-2.0" ]
38
2021-02-04T06:38:13.000Z
2022-03-25T05:41:28.000Z
src/testproject/sdk/internal/helpers/redact_helper.py
A-b-i-lash/python-opensdk
1f950e1ae6f9977e5732f2b880e8bffd924b36e6
[ "Apache-2.0" ]
47
2020-07-08T05:13:03.000Z
2021-02-01T10:17:58.000Z
src/testproject/sdk/internal/helpers/redact_helper.py
A-b-i-lash/python-opensdk
1f950e1ae6f9977e5732f2b880e8bffd924b36e6
[ "Apache-2.0" ]
17
2021-02-28T23:46:17.000Z
2022-01-26T05:02:59.000Z
# Copyright 2020 TestProject (https://testproject.io) # # 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 ...
37.982759
104
0.660917
from selenium.webdriver.remote.command import Command class RedactHelper: def __init__(self, command_executor): self._command_executor = command_executor def redact_command(self, command: str, params: dict): if command == Command.SEND_KEYS_TO_ELEMENT or command == Command.SEND_KEYS_TO_ACTIV...
true
true
f7512c2208d2b87decfc0fad4d1de187a3b5101c
155,786
py
Python
dask/array/core.py
kylejn27/dask
4ab0b179cbd19645749a7dd294df9c2c362c256a
[ "BSD-3-Clause" ]
1
2020-09-10T15:23:57.000Z
2020-09-10T15:23:57.000Z
dask/array/core.py
adbmd/dask
3327b2e158dbadf2057685fdb51b74ce3129416e
[ "BSD-3-Clause" ]
null
null
null
dask/array/core.py
adbmd/dask
3327b2e158dbadf2057685fdb51b74ce3129416e
[ "BSD-3-Clause" ]
null
null
null
import math import operator import os import pickle import re import sys import traceback import uuid import warnings from bisect import bisect from collections.abc import Iterable, Iterator, Mapping from functools import partial, wraps, reduce from itertools import product, zip_longest from numbers import Number, Inte...
31.806043
95
0.58391
import math import operator import os import pickle import re import sys import traceback import uuid import warnings from bisect import bisect from collections.abc import Iterable, Iterator, Mapping from functools import partial, wraps, reduce from itertools import product, zip_longest from numbers import Number, Inte...
true
true
f7512c23e6063882a4dd6f080698e741e9815af8
13,986
py
Python
AI_Flappy.py
ShamimSuf/AI_FlappyBird_GeneticAlgo
438da76b1327ef3167dea42706dce4aaeccc8136
[ "MIT" ]
null
null
null
AI_Flappy.py
ShamimSuf/AI_FlappyBird_GeneticAlgo
438da76b1327ef3167dea42706dce4aaeccc8136
[ "MIT" ]
null
null
null
AI_Flappy.py
ShamimSuf/AI_FlappyBird_GeneticAlgo
438da76b1327ef3167dea42706dce4aaeccc8136
[ "MIT" ]
null
null
null
#This flappy will have 6 inputs (i1 to i6) : up, down, bird top-right to up-block-low-right, bird top-left to up-block-low-left, so on. import numpy as np import pygame import time import random from random import randint pygame.init() #6 input nodes i_ROW = 1 i_COL = 6 #3 hidden layer nodes #input to hidden laye...
31.358744
175
0.688832
import numpy as np import pygame import time import random from random import randint pygame.init() i_ROW = 1 i_COL = 6 w1_ROW = 6 w1_COL = 3 w2_ROW = 3 w2_COL = 1 class Colors: def __init__(self): self.black = (0,0,0) self.white = (255,255,255) self.cornflowerblue = (100,149,237) self.azure4 = (131,1...
true
true
f7512d38c0667331fffccd5a4e7a6dc2a1dc89d2
1,286
py
Python
fin_apis/alphavantage/ts.py
humdings/fin_apis
daffc9db782844b5895e013b4b41782a1b0cb24d
[ "MIT" ]
null
null
null
fin_apis/alphavantage/ts.py
humdings/fin_apis
daffc9db782844b5895e013b4b41782a1b0cb24d
[ "MIT" ]
null
null
null
fin_apis/alphavantage/ts.py
humdings/fin_apis
daffc9db782844b5895e013b4b41782a1b0cb24d
[ "MIT" ]
null
null
null
from alpha_vantage.timeseries import TimeSeries from fin_apis.utils import multicall from fin_apis.auth import AuthKeys class AVTimeSeries(TimeSeries): def __init__(self, key=None, output_format='pandas', treat_info_as_error=True, indexing_type='date', proxy=None, rapidapi=False): if ke...
38.969697
116
0.699067
from alpha_vantage.timeseries import TimeSeries from fin_apis.utils import multicall from fin_apis.auth import AuthKeys class AVTimeSeries(TimeSeries): def __init__(self, key=None, output_format='pandas', treat_info_as_error=True, indexing_type='date', proxy=None, rapidapi=False): if ke...
true
true
f7512eac7e1d635849c4db8670bde28b537e3f4f
563
py
Python
sstkdj/soundscapes/migrations/0006_auto_20191105_0128.py
kitefishlabs/sstkdj
dc51a644dd6d41ea212dedd53e277e526581c7a7
[ "BSD-3-Clause" ]
null
null
null
sstkdj/soundscapes/migrations/0006_auto_20191105_0128.py
kitefishlabs/sstkdj
dc51a644dd6d41ea212dedd53e277e526581c7a7
[ "BSD-3-Clause" ]
5
2020-06-06T00:36:25.000Z
2021-06-10T19:22:01.000Z
sstkdj/soundscapes/migrations/0006_auto_20191105_0128.py
kitefishlabs/sstkdj
dc51a644dd6d41ea212dedd53e277e526581c7a7
[ "BSD-3-Clause" ]
null
null
null
# Generated by Django 2.2.6 on 2019-11-05 01:28 from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('soundscapes', '0005_regioncircle_owner'), ] operations = [ migrations.Alte...
26.809524
152
0.678508
from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('soundscapes', '0005_regioncircle_owner'), ] operations = [ migrations.AlterField( model_name='regioncircle', ...
true
true
f7512f61b438ac0268041aef7a0a827a085a0e7b
7,933
py
Python
urilib/compose.py
masayuko/urilib
03de444f92fe9c3e03e71dde29c29c333e032e6c
[ "MIT" ]
null
null
null
urilib/compose.py
masayuko/urilib
03de444f92fe9c3e03e71dde29c29c333e032e6c
[ "MIT" ]
null
null
null
urilib/compose.py
masayuko/urilib
03de444f92fe9c3e03e71dde29c29c333e032e6c
[ "MIT" ]
null
null
null
import ipaddress import numbers import re from collections import Iterable, Mapping from .chars import SUB_DELIMS from .encoding import uriencode, uriencode_plus, idnencode from .split import uriunsplit # RFC 3986 3.1: scheme = ALPHA *( ALPHA / DIGIT / "+" / "-" / "." ) _SCHEME_RE = re.compile(r"\A[A-Za-z][A-Za-z0-9...
38.509709
78
0.643136
import ipaddress import numbers import re from collections import Iterable, Mapping from .chars import SUB_DELIMS from .encoding import uriencode, uriencode_plus, idnencode from .split import uriunsplit _SCHEME_RE = re.compile(r"\A[A-Za-z][A-Za-z0-9+.-]*\Z") _AUTHORITY_RE_STRING = re.compile(r"\A(?:(.*)@)?(.*?)(?::...
true
true
f7513008f912c6c94c90305579b72f5615da9120
3,533
py
Python
MPDA_decode/instance.py
Tesla2fox/MPDA-DE
0a27d59ceba16d292fade01d95b1c1f336e5f604
[ "MIT" ]
1
2019-06-21T02:54:18.000Z
2019-06-21T02:54:18.000Z
MPDA_decode/instance.py
Tesla2fox/MPDA-DE
0a27d59ceba16d292fade01d95b1c1f336e5f604
[ "MIT" ]
null
null
null
MPDA_decode/instance.py
Tesla2fox/MPDA-DE
0a27d59ceba16d292fade01d95b1c1f336e5f604
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Fri Sep 21 15:49:17 2018 @author: robot """ from readCfg import * import numpy as np from enum import Enum class TaskModelType(Enum): ExpModel = 1 LineModel = 2 class Instance(object): def __init__(self, insFileName = 'wtf'): self.insFileName = insFile...
32.412844
96
0.585338
from readCfg import * import numpy as np from enum import Enum class TaskModelType(Enum): ExpModel = 1 LineModel = 2 class Instance(object): def __init__(self, insFileName = 'wtf'): self.insFileName = insFileName readCfg = Read_Cfg(insFileName) self.robNum = int(readCfg.getSi...
true
true
f7513105e011dd0116f07ba32cf579d74fad046f
212
py
Python
Python/Tests/TestData/TestExplorerPytest/test_ut.py
techkey/PTVS
8355e67eedd8e915ca49bd38a2f36172696fd903
[ "Apache-2.0" ]
404
2019-05-07T02:21:57.000Z
2022-03-31T17:03:04.000Z
Python/Tests/TestData/TestExplorerPytest/test_ut.py
techkey/PTVS
8355e67eedd8e915ca49bd38a2f36172696fd903
[ "Apache-2.0" ]
1,672
2019-05-06T21:09:38.000Z
2022-03-31T23:16:04.000Z
Python/Tests/TestData/TestExplorerPytest/test_ut.py
techkey/PTVS
8355e67eedd8e915ca49bd38a2f36172696fd903
[ "Apache-2.0" ]
186
2019-05-13T03:17:37.000Z
2022-03-31T16:24:05.000Z
import unittest class TestClassUT(unittest.TestCase): def test__ut_fail(self): self.fail("Not implemented") def test__ut_pass(self): pass if __name__ == '__main__': unittest.main()
17.666667
37
0.669811
import unittest class TestClassUT(unittest.TestCase): def test__ut_fail(self): self.fail("Not implemented") def test__ut_pass(self): pass if __name__ == '__main__': unittest.main()
true
true
f75132750a663aa840d5e6ec2e0857d1c3b905c0
2,640
py
Python
habanero/crossref/workscontainer.py
sckott/pydoi
6052faaa7eba9e4447bc792b913ab434f15354a1
[ "MIT" ]
null
null
null
habanero/crossref/workscontainer.py
sckott/pydoi
6052faaa7eba9e4447bc792b913ab434f15354a1
[ "MIT" ]
1
2015-10-07T02:20:24.000Z
2015-10-07T02:20:24.000Z
habanero/crossref/workscontainer.py
sckott/pydoi
6052faaa7eba9e4447bc792b913ab434f15354a1
[ "MIT" ]
null
null
null
class WorksContainer(object): """ WorksContainer: Class for working with works results Usage:: from habanero import Crossref, WorksContainer cr = Crossref() res = cr.works(ids=['10.1136/jclinpath-2020-206745', '10.1136/esmoopen-2020-000776']) x = WorksConta...
32.195122
104
0.484091
class WorksContainer(object): def __init__(self, input): super(WorksContainer, self).__init__() if not input: raise ValueError("input len must be > zero") self.__input = input self.works = self.works_handler(self.__input) keys = list(self.works[0].keys()) ...
true
true
f751328765607ead45c009168e4edd7c11867731
1,197
py
Python
topic_tutorial_py/setup.py
JaehyunShim/ros2_tutorial_py
ed94477341ae6053dbd126fe5092b5cbf44ffa89
[ "Apache-2.0" ]
null
null
null
topic_tutorial_py/setup.py
JaehyunShim/ros2_tutorial_py
ed94477341ae6053dbd126fe5092b5cbf44ffa89
[ "Apache-2.0" ]
null
null
null
topic_tutorial_py/setup.py
JaehyunShim/ros2_tutorial_py
ed94477341ae6053dbd126fe5092b5cbf44ffa89
[ "Apache-2.0" ]
null
null
null
from setuptools import setup package_name = 'topic_tutorial_py' setup( name=package_name, version='0.0.0', packages=[package_name], data_files=[ ('share/ament_index/resource_index/packages', ['resource/' + package_name]), ('share/' + package_name, ['package.xml']), ], ...
35.205882
93
0.681704
from setuptools import setup package_name = 'topic_tutorial_py' setup( name=package_name, version='0.0.0', packages=[package_name], data_files=[ ('share/ament_index/resource_index/packages', ['resource/' + package_name]), ('share/' + package_name, ['package.xml']), ], ...
true
true
f75133c151c0513cc0c1bbb08864d1f124a4994b
9,886
py
Python
appendix/discrete_time_identification (Burgers)/Burgers_systematic.py
TianjieZhang1993/PINNs
9034ba7f4fef81c24954fa3cbf08a2d4a7fee85a
[ "MIT" ]
1,373
2018-01-24T01:47:11.000Z
2022-03-31T18:01:02.000Z
appendix/discrete_time_identification (Burgers)/Burgers_systematic.py
TianjieZhang1993/PINNs
9034ba7f4fef81c24954fa3cbf08a2d4a7fee85a
[ "MIT" ]
38
2019-04-24T14:22:17.000Z
2022-03-05T11:05:53.000Z
appendix/discrete_time_identification (Burgers)/Burgers_systematic.py
TianjieZhang1993/PINNs
9034ba7f4fef81c24954fa3cbf08a2d4a7fee85a
[ "MIT" ]
697
2018-03-05T17:23:44.000Z
2022-03-31T18:30:30.000Z
""" @author: Maziar Raissi """ import sys sys.path.insert(0, '../../Utilities/') import tensorflow as tf import numpy as np import time import scipy.io np.random.seed(1234) tf.set_random_seed(1234) class PhysicsInformedNN: # Initialize the class def __init__(self, x0, u0, x1, u1, layers, dt, lb, ub, q): ...
39.230159
132
0.539551
import sys sys.path.insert(0, '../../Utilities/') import tensorflow as tf import numpy as np import time import scipy.io np.random.seed(1234) tf.set_random_seed(1234) class PhysicsInformedNN: def __init__(self, x0, u0, x1, u1, layers, dt, lb, ub, q): self.lb = lb self.ub = ub ...
true
true
f75133e05e0ef311f37ea1ed0298632b9e5b461c
3,551
py
Python
gunbot_python/system.py
dgnsrekt/gunbot.py
5a3c01a329cc67c93b65a5bd2962b3df618f8cb5
[ "MIT" ]
1
2020-01-27T19:37:45.000Z
2020-01-27T19:37:45.000Z
gunbot_python/system.py
johnjdailey/gunbot.py
5a3c01a329cc67c93b65a5bd2962b3df618f8cb5
[ "MIT" ]
null
null
null
gunbot_python/system.py
johnjdailey/gunbot.py
5a3c01a329cc67c93b65a5bd2962b3df618f8cb5
[ "MIT" ]
2
2018-12-06T05:50:12.000Z
2020-01-25T22:53:33.000Z
# SYSTEM from pathlib import Path import shutil # THIRD-PARTY import luigi import structlog import toml import wget from zipfile import ZipFile # LOCAL from paths import ( GUNBOT_DOWNLOAD_PATH, GUNBOT_DOWNLOAD_URL, GUNBOT_PATH, TEMP_GUNBOT_EXTRACTION_PATH, ) from log import config_logger logger = str...
34.813725
98
0.649676
from pathlib import Path import shutil import luigi import structlog import toml import wget from zipfile import ZipFile from paths import ( GUNBOT_DOWNLOAD_PATH, GUNBOT_DOWNLOAD_URL, GUNBOT_PATH, TEMP_GUNBOT_EXTRACTION_PATH, ) from log import config_logger logger = structlog.get_logger(__file__) co...
true
true
f75133f5846e31c55dcba9fb29b9cf0c7bd744b7
9,309
py
Python
conf.py
kampusubl/laboratorium-n250
709b4f595e1f32c8ea4340b7026d9376ba096932
[ "Apache-2.0" ]
2
2016-08-29T10:28:46.000Z
2016-08-29T17:07:30.000Z
conf.py
kampusubl/laboratorium-n250
709b4f595e1f32c8ea4340b7026d9376ba096932
[ "Apache-2.0" ]
null
null
null
conf.py
kampusubl/laboratorium-n250
709b4f595e1f32c8ea4340b7026d9376ba096932
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Yoopa documentation build configuration file, created by # sphinx-quickstart on Mon Jul 4 22:43:48 2016. # # 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 # auto...
32.548951
79
0.718982
import sys import os import shlex extensions = [] templates_path = ['_templates'] source_suffix = '.rst' master_doc = 'index' project = 'Laboratorium N250' copyright = '2016, PSTI Universitas Bandar Lampung' author = 'PSTI Universitas Bandar Lampung' # |version| and |release|, also used in various other plac...
true
true
f75134cb976181aed7c8e137b0223c4b376f0a20
6,651
py
Python
bindings/python/ensmallen_graph/datasets/string/verticilliumdahliae.py
caufieldjh/ensmallen_graph
14e98b1cdbc73193a84a913d7d4f2b2b3eb2c43a
[ "MIT" ]
null
null
null
bindings/python/ensmallen_graph/datasets/string/verticilliumdahliae.py
caufieldjh/ensmallen_graph
14e98b1cdbc73193a84a913d7d4f2b2b3eb2c43a
[ "MIT" ]
null
null
null
bindings/python/ensmallen_graph/datasets/string/verticilliumdahliae.py
caufieldjh/ensmallen_graph
14e98b1cdbc73193a84a913d7d4f2b2b3eb2c43a
[ "MIT" ]
null
null
null
""" This file offers the methods to automatically retrieve the graph Verticillium dahliae. The graph is automatically retrieved from the STRING repository. Report --------------------- At the time of rendering these methods (please see datetime below), the graph had the following characteristics: Datetime: 2021-0...
35.190476
223
0.70215
from typing import Dict from ..automatic_graph_retrieval import AutomaticallyRetrievedGraph from ...ensmallen_graph import EnsmallenGraph def VerticilliumDahliae( directed: bool = False, verbose: int = 2, cache_path: str = "graphs/string", **additional_graph_kwargs: Dict ) -> EnsmallenGraph: ret...
true
true
f751353c0b0c5923e7aacece5817a028bf5b773b
379
py
Python
run_script.py
DiscombobulatedDrag/covid19-japan-web-api
a4a25998ad0c94a0ee3fc0fbae166132780e0dcd
[ "MIT" ]
1
2020-08-09T12:01:04.000Z
2020-08-09T12:01:04.000Z
run_script.py
akfurdk/covid19-japan-web-api
c55110df490376e3dfa03188c87e8dd3acf90291
[ "MIT" ]
null
null
null
run_script.py
akfurdk/covid19-japan-web-api
c55110df490376e3dfa03188c87e8dd3acf90291
[ "MIT" ]
null
null
null
from src.script import create_positive_detail from src.script import create_prefectures from src.script import create_total from src.script import create_statistics_positives if __name__ == '__main__': create_positive_detail.create_json_file() create_prefectures.create_json_file() create_total.create_json...
31.583333
50
0.833773
from src.script import create_positive_detail from src.script import create_prefectures from src.script import create_total from src.script import create_statistics_positives if __name__ == '__main__': create_positive_detail.create_json_file() create_prefectures.create_json_file() create_total.create_json...
true
true
f751360fea22cbe961784a41e49b1a154ce00bd6
176
py
Python
python2_template.py
Lgeu/snippet
02a027c6f06d21bcffb7d7585b7a4244ed20143a
[ "CC0-1.0" ]
12
2020-03-01T07:37:08.000Z
2021-06-14T02:52:45.000Z
python2_template.py
Lgeu/snippet
02a027c6f06d21bcffb7d7585b7a4244ed20143a
[ "CC0-1.0" ]
null
null
null
python2_template.py
Lgeu/snippet
02a027c6f06d21bcffb7d7585b7a4244ed20143a
[ "CC0-1.0" ]
2
2020-06-15T09:51:57.000Z
2020-06-28T05:43:32.000Z
from __future__ import division import sys PYTHON3 = sys.version_info.major == 3 if not PYTHON3: from itertools import izip as zip range = xrange input = raw_input
22
37
0.738636
from __future__ import division import sys PYTHON3 = sys.version_info.major == 3 if not PYTHON3: from itertools import izip as zip range = xrange input = raw_input
true
true
f7513652867535a7b6fb80a377a47847e2305284
8,849
py
Python
compiler_gym/envs/llvm/service/passes/extract_passes_from_llvm_source_tree.py
sahirgomez1/CompilerGym
9987fbdfcf8ac9af076baf0ffd695e48f0e804cf
[ "MIT" ]
562
2020-12-21T14:10:20.000Z
2022-03-31T21:23:55.000Z
compiler_gym/envs/llvm/service/passes/extract_passes_from_llvm_source_tree.py
sahirgomez1/CompilerGym
9987fbdfcf8ac9af076baf0ffd695e48f0e804cf
[ "MIT" ]
433
2020-12-22T03:40:41.000Z
2022-03-31T18:16:17.000Z
compiler_gym/envs/llvm/service/passes/extract_passes_from_llvm_source_tree.py
sahirgomez1/CompilerGym
9987fbdfcf8ac9af076baf0ffd695e48f0e804cf
[ "MIT" ]
88
2020-12-22T08:22:00.000Z
2022-03-20T19:00:40.000Z
# Copyright (c) Facebook, Inc. and its affiliates. # # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. """Extract a list of passes form the LLVM source tree. Usage: $ extract_passes_from_llvm_source_tree /path/to/llvm/source/root Optionall...
33.142322
138
0.592383
import codecs import csv import logging import os import re import subprocess import sys from pathlib import Path from typing import Dict, Iterable, List, Optional, Tuple from compiler_gym.envs.llvm.service.passes.common import Pass from compiler_gym.envs.llvm.service.passes.config import CREATE_PASS_NAME_MAP logger ...
true
true
f751368ef874b769127854a09d1a8663a715c4c1
19,967
py
Python
tensorboardX/summary.py
justusschock/tensorboardX
1c16e127f9a737c0b45d0447c20499dec666130c
[ "MIT" ]
null
null
null
tensorboardX/summary.py
justusschock/tensorboardX
1c16e127f9a737c0b45d0447c20499dec666130c
[ "MIT" ]
null
null
null
tensorboardX/summary.py
justusschock/tensorboardX
1c16e127f9a737c0b45d0447c20499dec666130c
[ "MIT" ]
1
2019-04-08T08:41:49.000Z
2019-04-08T08:41:49.000Z
# 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...
40.419028
119
0.645565
from __future__ import absolute_import from __future__ import division from __future__ import print_function import bisect import logging import numpy as np import os import re as _re from six import StringIO from six.moves import range from .proto.summary_pb2 import Summary from .proto.summary_pb2 import Histogram...
true
true
f75137270f2f40c4d203ac58094f4ba5163aed9a
1,191
py
Python
techminer2/collaboration_network_communities.py
jdvelasq/techminer2
ad64a49402749755798a18417c38a7ad10e83bad
[ "MIT" ]
null
null
null
techminer2/collaboration_network_communities.py
jdvelasq/techminer2
ad64a49402749755798a18417c38a7ad10e83bad
[ "MIT" ]
null
null
null
techminer2/collaboration_network_communities.py
jdvelasq/techminer2
ad64a49402749755798a18417c38a7ad10e83bad
[ "MIT" ]
null
null
null
""" Collaboration Network / Communities =============================================================================== >>> from techminer2 import * >>> directory = "data/" >>> collaboration_network_communities('authors', min_occ=2, directory=directory).head() cluster CL_00 ... CL_19 rn ...
30.538462
87
0.559194
from .co_occurrence_network_communities import co_occurrence_network_communities def collaboration_network_communities( column, min_occ=2, normalization="association", clustering_method="louvain", directory="./", ): if column not in ["authors", "institutions", "countries"]: raise Valu...
true
true
f75137542d5b7bee539ba4874326cc329e4b4334
824
py
Python
tests/test_create_table.py
alpreu/dynamodb-geo.py
1910368b020cddfe8275f94d7962cc48ca0ec9bd
[ "MIT" ]
25
2020-04-13T20:04:19.000Z
2022-03-18T12:34:06.000Z
tests/test_create_table.py
alpreu/dynamodb-geo.py
1910368b020cddfe8275f94d7962cc48ca0ec9bd
[ "MIT" ]
11
2020-04-18T10:45:39.000Z
2021-09-09T10:06:14.000Z
tests/test_create_table.py
alpreu/dynamodb-geo.py
1910368b020cddfe8275f94d7962cc48ca0ec9bd
[ "MIT" ]
14
2020-05-25T21:04:48.000Z
2021-11-08T17:37:42.000Z
import dynamodbgeo from vars import dynamodb import uuid def test_create_table(): try: table_name = str(uuid.uuid4()) config = dynamodbgeo.GeoDataManagerConfiguration( dynamodb, table_name) geoDataManager = dynamodbgeo.GeoDataManager(config) table_util = dynamodbgeo.Geo...
31.692308
76
0.669903
import dynamodbgeo from vars import dynamodb import uuid def test_create_table(): try: table_name = str(uuid.uuid4()) config = dynamodbgeo.GeoDataManagerConfiguration( dynamodb, table_name) geoDataManager = dynamodbgeo.GeoDataManager(config) table_util = dynamodbgeo.Geo...
true
true
f7513761a06800074ca2316b36ca1967570f5c68
876
py
Python
Tools/ROS/entity_storage/scripts/test.py
ToyotaResearchInstitute/rad-robot
9a47e4d88382719ab9bf142932fbcc83dcbcd665
[ "MIT" ]
null
null
null
Tools/ROS/entity_storage/scripts/test.py
ToyotaResearchInstitute/rad-robot
9a47e4d88382719ab9bf142932fbcc83dcbcd665
[ "MIT" ]
null
null
null
Tools/ROS/entity_storage/scripts/test.py
ToyotaResearchInstitute/rad-robot
9a47e4d88382719ab9bf142932fbcc83dcbcd665
[ "MIT" ]
2
2018-06-04T12:38:54.000Z
2018-09-22T10:31:27.000Z
#!/usr/bin/env python import roslib; roslib.load_manifest('entity_storage') from entity_storage.srv import * from entity_storage.msg import * import rospy def get_coordinates(name): rospy.wait_for_service('get_entity_coordinates') try: get_coords = rospy.ServiceProxy('get_entity_coordinates', entity_c...
31.285714
98
0.68379
import roslib; roslib.load_manifest('entity_storage') from entity_storage.srv import * from entity_storage.msg import * import rospy def get_coordinates(name): rospy.wait_for_service('get_entity_coordinates') try: get_coords = rospy.ServiceProxy('get_entity_coordinates', entity_coordinates) re...
false
true
f75137a1687a2d952b43328ed94705d40f02b126
20,601
py
Python
django/db/transaction.py
huicheese/Django-test
eb866b3c4c61eb990e68f4b6a02cb1b7d948adbd
[ "BSD-3-Clause" ]
118
2015-01-03T15:42:32.000Z
2022-02-01T02:58:38.000Z
django/db/transaction.py
huicheese/Django-test
eb866b3c4c61eb990e68f4b6a02cb1b7d948adbd
[ "BSD-3-Clause" ]
18
2015-01-14T07:51:48.000Z
2021-10-14T01:19:26.000Z
django/db/transaction.py
huicheese/Django-test
eb866b3c4c61eb990e68f4b6a02cb1b7d948adbd
[ "BSD-3-Clause" ]
70
2015-01-01T00:33:24.000Z
2021-12-10T03:43:07.000Z
""" This module implements a transaction manager that can be used to define transaction handling in a request or view function. It is used by transaction control middleware and decorators. The transaction manager can be in managed or in auto state. Auto state means the system is using a commit-on-save strategy (actual...
38.009225
80
0.638561
import warnings from functools import wraps from django.db import ( connections, DEFAULT_DB_ALIAS, DatabaseError, Error, ProgrammingError) from django.utils.decorators import available_attrs class TransactionManagementError(ProgrammingError): pass def get_connection(using=None): if using ...
true
true
f75138469a5021c5ac8bc51b9ca35653c708e66d
1,378
py
Python
crmapp/accounts/migrations/0001_initial.py
KristanArmstrong/CRM_Django_Project
cf446e04688b1b480fbd21a91703e524444b6753
[ "MIT" ]
1
2016-11-19T07:19:30.000Z
2016-11-19T07:19:30.000Z
crmapp/accounts/migrations/0001_initial.py
KristanArmstrong/CRM_Django_Project
cf446e04688b1b480fbd21a91703e524444b6753
[ "MIT" ]
null
null
null
crmapp/accounts/migrations/0001_initial.py
KristanArmstrong/CRM_Django_Project
cf446e04688b1b480fbd21a91703e524444b6753
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations import shortuuidfield.fields from django.conf import settings class Migration(migrations.Migration): dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ] operations ...
37.243243
119
0.591437
from __future__ import unicode_literals from django.db import models, migrations import shortuuidfield.fields from django.conf import settings class Migration(migrations.Migration): dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ] operations = [ migrations.C...
true
true
f75138efebaa641115f7d19fc17de6053f336761
83
py
Python
utils.py
bmanikan/SlowFast
97cb5d55cb211c362d585857aebacbdb372496ad
[ "MIT" ]
null
null
null
utils.py
bmanikan/SlowFast
97cb5d55cb211c362d585857aebacbdb372496ad
[ "MIT" ]
null
null
null
utils.py
bmanikan/SlowFast
97cb5d55cb211c362d585857aebacbdb372496ad
[ "MIT" ]
null
null
null
import os def safedirs(path): if not os.path.exists(path): os.makedirs(path)
16.6
30
0.698795
import os def safedirs(path): if not os.path.exists(path): os.makedirs(path)
true
true
f751390b8b17889b81e62cb54932ab09baf2b135
3,978
py
Python
robotender_kinova_flexbe_states/src/robotender_kinova_flexbe_states/finger_position_state.py
dcat52/ROS-robotender-flexbe-sm
e9eb218788403f467557e1c1e97750e910f0bf64
[ "BSD-3-Clause" ]
null
null
null
robotender_kinova_flexbe_states/src/robotender_kinova_flexbe_states/finger_position_state.py
dcat52/ROS-robotender-flexbe-sm
e9eb218788403f467557e1c1e97750e910f0bf64
[ "BSD-3-Clause" ]
null
null
null
robotender_kinova_flexbe_states/src/robotender_kinova_flexbe_states/finger_position_state.py
dcat52/ROS-robotender-flexbe-sm
e9eb218788403f467557e1c1e97750e910f0bf64
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python import rospy import actionlib from flexbe_core import EventState, Logger from flexbe_core.proxy import ProxyActionClient from flexbe_core.proxy import ProxySubscriberCached from moveit_msgs.msg import MoveGroupAction, MoveGroupGoal, Constraints, JointConstraint, MoveItErrorCodes from kinova...
36.495413
130
0.53645
import rospy import actionlib from flexbe_core import EventState, Logger from flexbe_core.proxy import ProxyActionClient from flexbe_core.proxy import ProxySubscriberCached from moveit_msgs.msg import MoveGroupAction, MoveGroupGoal, Constraints, JointConstraint, MoveItErrorCodes from kinova_msgs.msg import SetFi...
true
true
f75139142247acc0861fb98f05b65661cc244428
48
py
Python
python/testData/resolve/FStringLocalVariable.py
truthiswill/intellij-community
fff88cfb0dc168eea18ecb745d3e5b93f57b0b95
[ "Apache-2.0" ]
2
2019-04-28T07:48:50.000Z
2020-12-11T14:18:08.000Z
python/testData/resolve/FStringLocalVariable.py
truthiswill/intellij-community
fff88cfb0dc168eea18ecb745d3e5b93f57b0b95
[ "Apache-2.0" ]
173
2018-07-05T13:59:39.000Z
2018-08-09T01:12:03.000Z
python/testData/resolve/FStringLocalVariable.py
truthiswill/intellij-community
fff88cfb0dc168eea18ecb745d3e5b93f57b0b95
[ "Apache-2.0" ]
2
2020-03-15T08:57:37.000Z
2020-04-07T04:48:14.000Z
def f(): foo = 42 f"{foo}" <ref>
12
13
0.333333
def f(): foo = 42 f"{foo}" <ref>
false
true
f7513a01a5525215392c9c1f77ed8ff5b6fa5c46
2,800
py
Python
dateparser/data/date_translation_data/smn.py
Rodp63/dateparser
938a9573234679b603210bd47cc93eb258b1f1df
[ "BSD-3-Clause" ]
null
null
null
dateparser/data/date_translation_data/smn.py
Rodp63/dateparser
938a9573234679b603210bd47cc93eb258b1f1df
[ "BSD-3-Clause" ]
null
null
null
dateparser/data/date_translation_data/smn.py
Rodp63/dateparser
938a9573234679b603210bd47cc93eb258b1f1df
[ "BSD-3-Clause" ]
null
null
null
info = { "name": "smn", "date_order": "DMY", "january": [ "uđiv", "uđđâivemáánu" ], "february": [ "kuovâ", "kuovâmáánu" ], "march": [ "njuhčâ", "njuhčâmáánu" ], "april": [ "cuáŋui", "cuáŋuimáánu" ], "may": [ ...
15.819209
26
0.297143
info = { "name": "smn", "date_order": "DMY", "january": [ "uđiv", "uđđâivemáánu" ], "february": [ "kuovâ", "kuovâmáánu" ], "march": [ "njuhčâ", "njuhčâmáánu" ], "april": [ "cuáŋui", "cuáŋuimáánu" ], "may": [ ...
true
true
f7513aaa5c031812b18feaf6dc94d86cf81788f9
700
py
Python
todoist_colors/__init__.py
kquinsland/todoist-colors
dacc24503fd85c8a6a392edc3e13827ddde6c499
[ "MIT" ]
null
null
null
todoist_colors/__init__.py
kquinsland/todoist-colors
dacc24503fd85c8a6a392edc3e13827ddde6c499
[ "MIT" ]
null
null
null
todoist_colors/__init__.py
kquinsland/todoist-colors
dacc24503fd85c8a6a392edc3e13827ddde6c499
[ "MIT" ]
null
null
null
HIBISCUS = 30 RED = 31 ORANGE = 32 YELLOW = 33 EARLS_GREEN = 34 LIGHT_GREEN = 35 GREEN = 36 DOWNY = 37 EASTERN_BLUE = 38 DODGER_BLUE = 39 CORNFLOWER = 40 BLUE = 41 VIOLET = 42 PURPLE = 43 LIGHT_ROSE = 44 ROSE = 45 MONA_LISA = 46 GRAY = 47 LIGHT_GRAY = 48 SORREL_BROWN = 49 # Expressed as a map colors = { 'HIBISCUS'...
15.555556
23
0.581429
HIBISCUS = 30 RED = 31 ORANGE = 32 YELLOW = 33 EARLS_GREEN = 34 LIGHT_GREEN = 35 GREEN = 36 DOWNY = 37 EASTERN_BLUE = 38 DODGER_BLUE = 39 CORNFLOWER = 40 BLUE = 41 VIOLET = 42 PURPLE = 43 LIGHT_ROSE = 44 ROSE = 45 MONA_LISA = 46 GRAY = 47 LIGHT_GRAY = 48 SORREL_BROWN = 49 colors = { 'HIBISCUS': 30, 'RED': 31, ...
true
true
f7513b38a53d8118d1cf9129192d3eb8f2de5c28
20,215
py
Python
cirq/linalg/transformations.py
kunalq/Cirq
e73c9bef672e83143ab04e7f169988149055d630
[ "Apache-2.0" ]
null
null
null
cirq/linalg/transformations.py
kunalq/Cirq
e73c9bef672e83143ab04e7f169988149055d630
[ "Apache-2.0" ]
null
null
null
cirq/linalg/transformations.py
kunalq/Cirq
e73c9bef672e83143ab04e7f169988149055d630
[ "Apache-2.0" ]
null
null
null
# Copyright 2018 The Cirq Developers # # 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 # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in ...
43.010638
80
0.634776
from typing import Tuple, Optional, Sequence, List, Union, TypeVar import numpy as np from cirq.protocols.approximate_equality import approx_eq from cirq.linalg import predicates # user provides a different np.array([]) value. RaiseValueErrorIfNotProvided = np.array([]) # type: np.ndarray TDefault = TypeVar('TDe...
true
true
f7513b61c9caba7bdb7307088c83e15113899a19
416
py
Python
eval/util.py
jeffdshen/squad
61ed2120fc06f5e33204200ac0f8d86d1da6f361
[ "MIT" ]
null
null
null
eval/util.py
jeffdshen/squad
61ed2120fc06f5e33204200ac0f8d86d1da6f361
[ "MIT" ]
null
null
null
eval/util.py
jeffdshen/squad
61ed2120fc06f5e33204200ac0f8d86d1da6f361
[ "MIT" ]
null
null
null
"""Write submission to file in csv format Author: Chris Chute (chute@stanford.edu) """ import csv def write_submission(sub_path, sub_dict): with open(sub_path, "w", newline="", encoding="utf-8") as csv_fh: csv_writer = csv.writer(csv_fh, delimiter=",") csv_writer.writerow(["Id", "Predicted"]...
26
69
0.653846
import csv def write_submission(sub_path, sub_dict): with open(sub_path, "w", newline="", encoding="utf-8") as csv_fh: csv_writer = csv.writer(csv_fh, delimiter=",") csv_writer.writerow(["Id", "Predicted"]) for uuid in sorted(sub_dict): csv_writer.writerow([uuid, sub_dict[uuid...
true
true
f7513bf4aed116eaf9f67b4ca9f798d998c7dddd
98
py
Python
pytest/02_testdiscovery/test_invalid_test_name.py
dramasamy/training
af7b9352b56c10aaa957062f24f1302a7a4c5797
[ "Apache-2.0" ]
1
2022-03-22T22:31:32.000Z
2022-03-22T22:31:32.000Z
pytest/02_testdiscovery/test_invalid_test_name.py
dramasamy/training
af7b9352b56c10aaa957062f24f1302a7a4c5797
[ "Apache-2.0" ]
null
null
null
pytest/02_testdiscovery/test_invalid_test_name.py
dramasamy/training
af7b9352b56c10aaa957062f24f1302a7a4c5797
[ "Apache-2.0" ]
null
null
null
def int(): assert type(1) == type(int()) def int_test(): assert type(1) == type(int())
16.333333
35
0.540816
def int(): assert type(1) == type(int()) def int_test(): assert type(1) == type(int())
true
true
f7513bf9b94dda89f1ffa3fe13ad4b7d3c666159
3,474
py
Python
iqrm/core.py
v-morello/iqrm
9f90e43c003af5d248d08b65d52fc88a73e12bbd
[ "MIT" ]
8
2021-07-15T08:52:10.000Z
2021-12-20T09:56:46.000Z
iqrm/core.py
v-morello/iqrm
9f90e43c003af5d248d08b65d52fc88a73e12bbd
[ "MIT" ]
null
null
null
iqrm/core.py
v-morello/iqrm
9f90e43c003af5d248d08b65d52fc88a73e12bbd
[ "MIT" ]
1
2021-08-04T06:22:34.000Z
2021-08-04T06:22:34.000Z
import itertools import numpy as np from collections import defaultdict def lagged_diff(x, k): """ Returns the sequence of x[i] - x[i - k], as an array with the same size as x. Boundary conditions are handled as follows: x[i] = x[0] if i < 0 x[i] = x[n-1] if i >= n, where n = len(x) ...
32.166667
98
0.613126
import itertools import numpy as np from collections import defaultdict def lagged_diff(x, k): s = np.roll(x, k) if k >= 0: s[:k] = x[0] else: s[k:] = x[-1] return x - s def outlier_mask(x, threshold=3.0): q1, med, q3 = np.percentile(x, [25, 50, 75]) std = (q3 - q1) / 1.349 ...
true
true
f7513c540ab6a081b3334c7cf48d902bd3371df4
1,037
py
Python
ahoy/model/view.py
geekflow/ahoy
4cbcceed2d20cc162fbf54527a2cdbe9681cba17
[ "MIT" ]
1
2018-03-02T06:01:28.000Z
2018-03-02T06:01:28.000Z
ahoy/model/view.py
geekflow/ahoy
4cbcceed2d20cc162fbf54527a2cdbe9681cba17
[ "MIT" ]
null
null
null
ahoy/model/view.py
geekflow/ahoy
4cbcceed2d20cc162fbf54527a2cdbe9681cba17
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ View ~~~~~~~~~ :copyright: (c) 2018 by geeksaga. :license: MIT LICENSE 2.0, see license for more details. """ from sqlalchemy import Column, Integer, String from . import Base class View(Base): __tablename__ = 'gs_view' id = Column(Integer, primary_key=True) ...
27.289474
108
0.611379
from sqlalchemy import Column, Integer, String from . import Base class View(Base): __tablename__ = 'gs_view' id = Column(Integer, primary_key=True) name = Column(String(100), unique=True) parent_id = Column(Integer, nullable=False) depth = Column(Integer, nullable=False) sequence = Column(I...
true
true
f7513ce7ec5ff075bc78a63ce89e5a2f1c86f27c
1,744
py
Python
test/test_examples.py
SenneRosaer/habitat-lab
1f8fc3c8aaf2c4866fb1e063516f7730898e1cce
[ "MIT" ]
null
null
null
test/test_examples.py
SenneRosaer/habitat-lab
1f8fc3c8aaf2c4866fb1e063516f7730898e1cce
[ "MIT" ]
null
null
null
test/test_examples.py
SenneRosaer/habitat-lab
1f8fc3c8aaf2c4866fb1e063516f7730898e1cce
[ "MIT" ]
null
null
null
import itertools import multiprocessing import runpy import sys from os import path as osp import pytest def run_main(*args): # patch sys.args sys.argv = list(args) target = args[0] # run_path has one difference with invoking Python from command-line: # if the target is a file (rather than a dire...
27.68254
82
0.673165
import itertools import multiprocessing import runpy import sys from os import path as osp import pytest def run_main(*args): sys.argv = list(args) target = args[0] if osp.isfile(target): sys.path.insert(0, osp.dirname(target)) runpy.run_path(target, run_name="__main__") ...
true
true
f7513d3eb7083aff2e38a50fda0b52c2fcb93b4f
2,211
py
Python
tests_async/system/requests/conftest.py
renovate-bot/google-resumable-media-python
1f01b88d0ce05ca561359de1ad89b47c6c60c9b7
[ "Apache-2.0" ]
null
null
null
tests_async/system/requests/conftest.py
renovate-bot/google-resumable-media-python
1f01b88d0ce05ca561359de1ad89b47c6c60c9b7
[ "Apache-2.0" ]
null
null
null
tests_async/system/requests/conftest.py
renovate-bot/google-resumable-media-python
1f01b88d0ce05ca561359de1ad89b47c6c60c9b7
[ "Apache-2.0" ]
null
null
null
# Copyright 2019 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
35.66129
83
0.735414
from tests.system import utils from google.auth._default_async import default_async import google.auth.transport._aiohttp_requests as tr_requests import pytest async def ensure_bucket(transport): get_response = await transport.request("GET", utils.BUCKET_URL) if get_response.status == 404: credentia...
true
true
f7513da26dac76236d0eb9a19aa70324a661ec5c
893
py
Python
config/default.py
unifispot/unifispot-free
186c906aa79e8671e03d0808469a3f27d67e34e1
[ "MIT" ]
21
2015-11-10T11:40:39.000Z
2021-12-02T22:58:45.000Z
config/default.py
unifispot/unifispot-free
186c906aa79e8671e03d0808469a3f27d67e34e1
[ "MIT" ]
null
null
null
config/default.py
unifispot/unifispot-free
186c906aa79e8671e03d0808469a3f27d67e34e1
[ "MIT" ]
10
2016-02-03T14:45:41.000Z
2019-11-08T08:21:25.000Z
import os from passlib.hash import sha256_crypt #WTF CSRF_ENABLED = True #configure blue prints BLUEPRINTS = ('guest','admin') #Configure DB basedir = os.path.join(os.path.abspath(os.path.dirname(__file__)),'..','bluespot') SQLALCHEMY_MIGRATE_REPO = os.path.join(basedir, 'db_repository') SECRET_KEY = 'once-a-ca...
19
109
0.74692
import os from passlib.hash import sha256_crypt CSRF_ENABLED = True BLUEPRINTS = ('guest','admin') basedir = os.path.join(os.path.abspath(os.path.dirname(__file__)),'..','bluespot') SQLALCHEMY_MIGRATE_REPO = os.path.join(basedir, 'db_repository') SECRET_KEY = 'once-a-cat-went-to-talk' SQLALCHEMY_DATABASE_URI =...
true
true
f7513dc6424a566d349c8ee0405b1f659c900688
4,365
py
Python
examples/records_datasource.py
TheFenrisLycaon/mllaunchpad
9de65d1bee29c64f4c3dee536d036c4cfeb3f079
[ "Apache-2.0" ]
15
2019-07-20T17:23:29.000Z
2021-06-03T11:16:54.000Z
examples/records_datasource.py
TheFenrisLycaon/mllaunchpad
9de65d1bee29c64f4c3dee536d036c4cfeb3f079
[ "Apache-2.0" ]
97
2019-07-19T11:22:16.000Z
2022-03-22T14:17:25.000Z
examples/records_datasource.py
TheFenrisLycaon/mllaunchpad
9de65d1bee29c64f4c3dee536d036c4cfeb3f079
[ "Apache-2.0" ]
7
2019-07-25T09:26:25.000Z
2022-03-22T09:32:41.000Z
import logging from typing import Dict, Optional from mllaunchpad.resource import DataSource, get_user_pw logger = logging.getLogger(__name__) try: import records except ModuleNotFoundError: logger.warning("Please install the Records package to be able to use RecordsDbDataSource.") class RecordsDbDataSour...
33.837209
121
0.614891
import logging from typing import Dict, Optional from mllaunchpad.resource import DataSource, get_user_pw logger = logging.getLogger(__name__) try: import records except ModuleNotFoundError: logger.warning("Please install the Records package to be able to use RecordsDbDataSource.") class RecordsDbDataSour...
true
true
f7513dd1c1c2059e900bae5426683ca3b2dd6478
4,387
py
Python
tools/filters/uniq.py
ramezrawas/galaxy-1
c03748dd49c060a68d07bce56eae33e0ba154414
[ "CC-BY-3.0" ]
null
null
null
tools/filters/uniq.py
ramezrawas/galaxy-1
c03748dd49c060a68d07bce56eae33e0ba154414
[ "CC-BY-3.0" ]
7
2016-12-07T22:19:37.000Z
2019-01-30T15:04:26.000Z
tools/filters/uniq.py
ramezrawas/galaxy-1
c03748dd49c060a68d07bce56eae33e0ba154414
[ "CC-BY-3.0" ]
null
null
null
# Filename: uniq.py # Author: Ian N. Schenck # Version: 19/12/2005 # # This script accepts an input file, an output file, a column # delimiter, and a list of columns. The script then grabs unique # lines based on the columns, and returns those records with a count # of occurences of each unique column (ignoring traili...
31.113475
79
0.54935
from __future__ import print_function import re import subprocess import sys def getopts(argv): opts = {} while argv: if argv[0][0] == '-': opts[argv[0]] = argv[1] argv = argv[2:] else: argv = argv[1:] return opts def main(): args = sys.argv[1:] ...
true
true
f7513e52ecc6f93c7c2918e3ded0e42a11d3ac77
4,833
py
Python
pyggop/Tau.py
giacomov/pyggop
81f0307281d00e367ab632fa52de41a56877b048
[ "MIT" ]
1
2021-03-06T08:58:03.000Z
2021-03-06T08:58:03.000Z
pyggop/Tau.py
giacomov/pyggop
81f0307281d00e367ab632fa52de41a56877b048
[ "MIT" ]
null
null
null
pyggop/Tau.py
giacomov/pyggop
81f0307281d00e367ab632fa52de41a56877b048
[ "MIT" ]
1
2017-02-14T21:04:59.000Z
2017-02-14T21:04:59.000Z
import numpy as np from multiprocessing import Pool from grbod import * import os, sys import pickle import scipy.interpolate from math import log10 import matplotlib.pyplot as plt from pyggop.ParallelPool import ParallelPool #This is the actual computation def func(DRbar, R_0, b, m, a, xx, yy): R0_hat =...
30.018634
114
0.431616
import numpy as np from multiprocessing import Pool from grbod import * import os, sys import pickle import scipy.interpolate from math import log10 import matplotlib.pyplot as plt from pyggop.ParallelPool import ParallelPool def func(DRbar, R_0, b, m, a, xx, yy): R0_hat = 1.0 / ( 1.0 + 10**xx ) ...
true
true
f7513f85e878764983485fcadb79c03093352149
3,690
py
Python
nova/tests/functional/regressions/test_bug_1852458.py
MagnusR/nova
798b8d2d825fcf259279ba4370e734242598f76f
[ "Apache-2.0" ]
1
2021-11-05T06:26:27.000Z
2021-11-05T06:26:27.000Z
nova/tests/functional/regressions/test_bug_1852458.py
MagnusR/nova
798b8d2d825fcf259279ba4370e734242598f76f
[ "Apache-2.0" ]
3
2019-05-17T15:49:12.000Z
2019-11-21T10:49:54.000Z
nova/tests/functional/regressions/test_bug_1852458.py
MagnusR/nova
798b8d2d825fcf259279ba4370e734242598f76f
[ "Apache-2.0" ]
null
null
null
# 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...
47.922078
78
0.685908
from nova.compute import instance_actions from nova import test from nova.tests import fixtures as nova_fixtures from nova.tests.functional import fixtures as func_fixtures from nova.tests.functional import integrated_helpers from nova import utils class TestInstanceActionBuryInCell0(test.TestCase, ...
true
true
f7513fd6791b081e358d3b6ac3d680f337fe72cb
4,062
py
Python
definecompanies.py
jaric-thorning/ProjectCapital
1aea429d464720e84d8db34b527dc711990ac302
[ "MIT" ]
null
null
null
definecompanies.py
jaric-thorning/ProjectCapital
1aea429d464720e84d8db34b527dc711990ac302
[ "MIT" ]
null
null
null
definecompanies.py
jaric-thorning/ProjectCapital
1aea429d464720e84d8db34b527dc711990ac302
[ "MIT" ]
null
null
null
from googlefinance import getQuotes import json class Share: def __init__(self, market, name, symbol, catergory, pprice, units, commission): self._market = market self._name = name self._symbol = symbol self._catergory = catergory self._purchase_price = pprice self._...
35.631579
153
0.595766
from googlefinance import getQuotes import json class Share: def __init__(self, market, name, symbol, catergory, pprice, units, commission): self._market = market self._name = name self._symbol = symbol self._catergory = catergory self._purchase_price = pprice self._...
false
true
f7514153c94db5010bc5f06508faa61b3ab1f396
633
py
Python
algorithms/code/leetcode/lc172_factorial_trailing_zeroes/lc172_factorial_trailing_zeroes.py
altermarkive/training
6a13f5b2f466156ad5db0e25da0e601d2404b4c3
[ "MIT" ]
null
null
null
algorithms/code/leetcode/lc172_factorial_trailing_zeroes/lc172_factorial_trailing_zeroes.py
altermarkive/training
6a13f5b2f466156ad5db0e25da0e601d2404b4c3
[ "MIT" ]
1
2022-02-16T11:28:56.000Z
2022-02-16T11:28:56.000Z
algorithms/code/leetcode/lc172_factorial_trailing_zeroes/lc172_factorial_trailing_zeroes.py
altermarkive/training
6a13f5b2f466156ad5db0e25da0e601d2404b4c3
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # https://leetcode.com/problems/factorial-trailing-zeroes/ import unittest class Solution: def trailingZeroes(self, n: int) -> int: step = 5 count = 0 while step <= n: count += n // step step = step * 5 return count class TestCode(u...
24.346154
74
0.64139
import unittest class Solution: def trailingZeroes(self, n: int) -> int: step = 5 count = 0 while step <= n: count += n // step step = step * 5 return count class TestCode(unittest.TestCase): def test_5(self): self.assertEqual(1, Solution().tr...
true
true
f7514182df3b66d5d7f9ffb03bef89a0f55795be
1,161
py
Python
Master Node Files/clear_entries.py
xuruichenn/mean-a
4b266c339f3aebf3c8598ac191a0bf51fad1bc6b
[ "MIT" ]
1
2020-07-24T21:36:56.000Z
2020-07-24T21:36:56.000Z
Master Node Files/clear_entries.py
xuruichenn/mean-a
4b266c339f3aebf3c8598ac191a0bf51fad1bc6b
[ "MIT" ]
null
null
null
Master Node Files/clear_entries.py
xuruichenn/mean-a
4b266c339f3aebf3c8598ac191a0bf51fad1bc6b
[ "MIT" ]
1
2019-04-12T20:39:00.000Z
2019-04-12T20:39:00.000Z
import argparse import requests import json REST_URL = '/api/todos' def delete_posts(website_ip, all_ids): url = 'http://' + website_ip + REST_URL + '/' for ids in all_ids: requests.delete(url + ids) return 1 def GET_from_website(website_ip): url = 'http://' + website_ip + REST_URL r = re...
25.23913
51
0.658053
import argparse import requests import json REST_URL = '/api/todos' def delete_posts(website_ip, all_ids): url = 'http://' + website_ip + REST_URL + '/' for ids in all_ids: requests.delete(url + ids) return 1 def GET_from_website(website_ip): url = 'http://' + website_ip + REST_URL r = re...
true
true
f75141c287c75968966eed782961291c7e7a7614
609
py
Python
main.py
ElJaviLuki/betty365
7a41edbd8fe363e461fc68e4a28b9e54a2ad50b3
[ "MIT" ]
1
2022-02-05T16:30:36.000Z
2022-02-05T16:30:36.000Z
main.py
ElJaviLuki/betty365
7a41edbd8fe363e461fc68e4a28b9e54a2ad50b3
[ "MIT" ]
null
null
null
main.py
ElJaviLuki/betty365
7a41edbd8fe363e461fc68e4a28b9e54a2ad50b3
[ "MIT" ]
1
2022-02-05T16:30:39.000Z
2022-02-05T16:30:39.000Z
''' Fetch session ID and D_ token and use them for the WebSocket connection. Author: @ElJaviLuki ''' # DEPENDENCIES import asyncio from betty365 import SubscriptionStreamDataProcessor from utils.web_session_manager import WebSessionManager # CONSTANTS MAIN_PAGE_HOST = 'https://www.bet365.es' USER_AGENT = 'Mo...
32.052632
129
0.781609
import asyncio from betty365 import SubscriptionStreamDataProcessor from utils.web_session_manager import WebSessionManager MAIN_PAGE_HOST = 'https://www.bet365.es' USER_AGENT = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/89.0.4389.90 Safari/537.36' sm = WebSessionManag...
true
true
f75141d97a519dffe366fd03c6003d78000ac0ae
2,583
py
Python
apkdec/apkdec.py
FrUh/apkdec
8d9390c0dd4f01739e1ef01a8ae765692efbf789
[ "MIT" ]
1
2019-08-11T02:48:13.000Z
2019-08-11T02:48:13.000Z
apkdec/apkdec.py
fruh/apkdec
8d9390c0dd4f01739e1ef01a8ae765692efbf789
[ "MIT" ]
null
null
null
apkdec/apkdec.py
fruh/apkdec
8d9390c0dd4f01739e1ef01a8ae765692efbf789
[ "MIT" ]
1
2017-01-27T20:42:53.000Z
2017-01-27T20:42:53.000Z
#!/usr/bin/python from subprocess import call import sys import os from optparse import OptionParser DIR_APKDEC = sys.path[0] DIR_TOOLS = DIR_APKDEC + os.sep + "tools" TOOL_DEX2JAR = DIR_TOOLS + os.sep + "dex2jar-2.0" + os.sep + "d2j-dex2jar.sh" TOOL_APKTOOL = "java -jar " + DIR_TOOLS + os.sep + "apktool_2.2.1.jar" T...
33.986842
117
0.615176
from subprocess import call import sys import os from optparse import OptionParser DIR_APKDEC = sys.path[0] DIR_TOOLS = DIR_APKDEC + os.sep + "tools" TOOL_DEX2JAR = DIR_TOOLS + os.sep + "dex2jar-2.0" + os.sep + "d2j-dex2jar.sh" TOOL_APKTOOL = "java -jar " + DIR_TOOLS + os.sep + "apktool_2.2.1.jar" TOOL_PROCYON = "jav...
false
true
f751425b89ead7e665a16e0683a97271c02715f2
10,728
py
Python
isi_sdk_8_1_1/isi_sdk_8_1_1/models/quota_notification_create_params.py
mohitjain97/isilon_sdk_python
a371f438f542568edb8cda35e929e6b300b1177c
[ "Unlicense" ]
24
2018-06-22T14:13:23.000Z
2022-03-23T01:21:26.000Z
isi_sdk_8_1_1/isi_sdk_8_1_1/models/quota_notification_create_params.py
mohitjain97/isilon_sdk_python
a371f438f542568edb8cda35e929e6b300b1177c
[ "Unlicense" ]
46
2018-04-30T13:28:22.000Z
2022-03-21T21:11:07.000Z
isi_sdk_8_1_1/isi_sdk_8_1_1/models/quota_notification_create_params.py
mohitjain97/isilon_sdk_python
a371f438f542568edb8cda35e929e6b300b1177c
[ "Unlicense" ]
29
2018-06-19T00:14:04.000Z
2022-02-08T17:51:19.000Z
# coding: utf-8 """ Isilon SDK Isilon SDK - Language bindings for the OneFS API # noqa: E501 OpenAPI spec version: 6 Contact: sdk@isilon.com Generated by: https://github.com/swagger-api/swagger-codegen.git """ import pprint import re # noqa: F401 import six from isi_sdk_8_1_1.models.quota_n...
32.807339
190
0.629381
import pprint import re import six from isi_sdk_8_1_1.models.quota_notification import QuotaNotification class QuotaNotificationCreateParams(object): swagger_types = { 'action_alert': 'bool', 'action_email_address': 'str', 'action_email_owner': 'bool', 'email_template': 'st...
true
true
f7514529d6b58c302512ab42d70c3343efe1a145
650
py
Python
modules/qplan/task.py
fifoforlifo/pyqplan
5d4522285a1c78cecf35d92405232c3395072f4f
[ "Apache-2.0" ]
null
null
null
modules/qplan/task.py
fifoforlifo/pyqplan
5d4522285a1c78cecf35d92405232c3395072f4f
[ "Apache-2.0" ]
null
null
null
modules/qplan/task.py
fifoforlifo/pyqplan
5d4522285a1c78cecf35d92405232c3395072f4f
[ "Apache-2.0" ]
null
null
null
def _get_duration(cls): if hasattr(cls, 'estimate'): return cls.estimate else: return 0 class Task: def __init__(task, cls): task.cls = cls task.name = cls.__qualname__ task.duration = _get_duration(cls) task.children = set() # set of task.name task...
28.26087
54
0.518462
def _get_duration(cls): if hasattr(cls, 'estimate'): return cls.estimate else: return 0 class Task: def __init__(task, cls): task.cls = cls task.name = cls.__qualname__ task.duration = _get_duration(cls) task.children = set() task.deps = set() ...
true
true
f7514535271e4894bb4f7a73229a77d0c5b993cd
352
py
Python
ca_on_peterborough/people.py
djac/scrapers-ca
2e16a85ff8a05ea49031a11ede66fa452631f8da
[ "MIT" ]
null
null
null
ca_on_peterborough/people.py
djac/scrapers-ca
2e16a85ff8a05ea49031a11ede66fa452631f8da
[ "MIT" ]
null
null
null
ca_on_peterborough/people.py
djac/scrapers-ca
2e16a85ff8a05ea49031a11ede66fa452631f8da
[ "MIT" ]
null
null
null
from utils import CSVScraper from datetime import date class PeterboroughPersonScraper(CSVScraper): csv_url = 'https://docs.google.com/spreadsheets/d/146Ym9eJ624pHQLF0HAtoiCLfP2WyHVerla2rT1nbMsE/pub?gid=0&single=true&output=csv' updated_at = date(2016, 3, 16) contact_person = 'deva.nadesan@infinitom.com'...
32
132
0.784091
from utils import CSVScraper from datetime import date class PeterboroughPersonScraper(CSVScraper): csv_url = 'https://docs.google.com/spreadsheets/d/146Ym9eJ624pHQLF0HAtoiCLfP2WyHVerla2rT1nbMsE/pub?gid=0&single=true&output=csv' updated_at = date(2016, 3, 16) contact_person = 'deva.nadesan@infinitom.com'...
true
true
f75145f7802ea8fa5439c5ca6320073c022c1741
15,526
py
Python
recipes/recipe_modules/gclient/config.py
fanbojie/depot_tools
355e97e300e8baceae8353287ad59b915dbb8196
[ "BSD-3-Clause" ]
1
2019-12-03T03:03:48.000Z
2019-12-03T03:03:48.000Z
recipes/recipe_modules/gclient/config.py
fanbojie/depot_tools
355e97e300e8baceae8353287ad59b915dbb8196
[ "BSD-3-Clause" ]
null
null
null
recipes/recipe_modules/gclient/config.py
fanbojie/depot_tools
355e97e300e8baceae8353287ad59b915dbb8196
[ "BSD-3-Clause" ]
1
2020-03-07T16:07:25.000Z
2020-03-07T16:07:25.000Z
# Copyright 2013 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 types from recipe_engine.config import config_item_context, ConfigGroup, BadConf from recipe_engine.config import ConfigList, Dict, Single, Static, S...
34.048246
80
0.695543
import types from recipe_engine.config import config_item_context, ConfigGroup, BadConf from recipe_engine.config import ConfigList, Dict, Single, Static, Set, List from . import api as gclient_api def BaseConfig(USE_MIRROR=True, CACHE_DIR=None, BUILDSPEC_VERSION=None, **_kwargs): cache_dir = str(...
true
true
f751465d345a5f6160d76c9bcda84e467b54713a
6,322
py
Python
finsky/protos/preloads_pb2.py
mmcloughlin/finsky
f21ccdbebf86e55a542c658b6972cb1f3fb5f119
[ "MIT" ]
59
2015-07-11T18:53:59.000Z
2021-09-08T03:16:17.000Z
finsky/protos/preloads_pb2.py
mmcloughlin/finsky
f21ccdbebf86e55a542c658b6972cb1f3fb5f119
[ "MIT" ]
10
2015-07-01T08:09:29.000Z
2021-12-06T01:23:00.000Z
finsky/protos/preloads_pb2.py
mmcloughlin/finsky
f21ccdbebf86e55a542c658b6972cb1f3fb5f119
[ "MIT" ]
14
2015-08-15T22:04:02.000Z
2021-03-03T09:14:39.000Z
# Generated by the protocol buffer compiler. DO NOT EDIT! # source: preloads.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _refl...
38.084337
620
0.744543
import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection from google.protobuf import symbol_database as _symbol_database from google.p...
true
true
f75147248cbe8297b873dc60cd537544a4c45a77
672
py
Python
tests/test_validators_conditions.py
chishaku/dynaconf
f67cb3a93dfe7c7c61269b8a717f46568df27c06
[ "MIT" ]
1
2021-07-21T17:06:16.000Z
2021-07-21T17:06:16.000Z
tests/test_validators_conditions.py
chishaku/dynaconf
f67cb3a93dfe7c7c61269b8a717f46568df27c06
[ "MIT" ]
null
null
null
tests/test_validators_conditions.py
chishaku/dynaconf
f67cb3a93dfe7c7c61269b8a717f46568df27c06
[ "MIT" ]
null
null
null
import pytest from dynaconf import validator_conditions positive_conditions = [ ("eq", 1, 1), ("ne", 1, 2), ("gt", 4, 3), ("lt", 3, 4), ("gte", 5, 5), ("lte", 5, 5), ("identity", None, None), ("is_type_of", 42, int), ("is_in", 42, [42, 34]), ("is_not_in", 42, [55, 34]), ("...
24
67
0.5625
import pytest from dynaconf import validator_conditions positive_conditions = [ ("eq", 1, 1), ("ne", 1, 2), ("gt", 4, 3), ("lt", 3, 4), ("gte", 5, 5), ("lte", 5, 5), ("identity", None, None), ("is_type_of", 42, int), ("is_in", 42, [42, 34]), ("is_not_in", 42, [55, 34]), ("...
true
true
f7514886fdaf3343c779a873097b3a32378df7b5
1,015
py
Python
examples/repressilator.py
BDAthlon/2017-Salis_Lab-2
0c3f486cccdbf413ad577ab6941914589532075a
[ "MIT" ]
null
null
null
examples/repressilator.py
BDAthlon/2017-Salis_Lab-2
0c3f486cccdbf413ad577ab6941914589532075a
[ "MIT" ]
null
null
null
examples/repressilator.py
BDAthlon/2017-Salis_Lab-2
0c3f486cccdbf413ad577ab6941914589532075a
[ "MIT" ]
null
null
null
# Tackling a difficult Circuit-Glob puzzle with the repressilator import sys sys.path.append('../circuitglobs') import numpy as np import gcparser import model from animate import Puzzle, Graphics import random random.seed(12) if __name__ == "__main__": Puzzle1 = Puzzle(difficulty=6) # Puzzle1.plot() ...
22.065217
77
0.662069
import sys sys.path.append('../circuitglobs') import numpy as np import gcparser import model from animate import Puzzle, Graphics import random random.seed(12) if __name__ == "__main__": Puzzle1 = Puzzle(difficulty=6) species = ''' R1 60 10 R2 60 50 R3 60 10 GFP 120 0 ''' pr...
true
true
f751494d2c685e9ea95a6ed37b3475093ce2370b
676
py
Python
cap-3/17-select-join-on.py
igoradriano/manipulacao-dados-python-bd
e3e47f15529d98e5c5887ebbb93c48924fceb665
[ "MIT" ]
null
null
null
cap-3/17-select-join-on.py
igoradriano/manipulacao-dados-python-bd
e3e47f15529d98e5c5887ebbb93c48924fceb665
[ "MIT" ]
null
null
null
cap-3/17-select-join-on.py
igoradriano/manipulacao-dados-python-bd
e3e47f15529d98e5c5887ebbb93c48924fceb665
[ "MIT" ]
null
null
null
import sqlite3 as conector from ModeloQueries import Veiculo conexao = conector.connect("./meu_banco.db") cursor = conexao.cursor() comando = '''SELECT Veiculo.placa, Veiculo.ano, Veiculo.cor, Veiculo.motor, Veiculo.proprietario, Marca.nome FROM Veiculo JOIN Marca ON (Marca.i...
25.037037
97
0.692308
import sqlite3 as conector from ModeloQueries import Veiculo conexao = conector.connect("./meu_banco.db") cursor = conexao.cursor() comando = '''SELECT Veiculo.placa, Veiculo.ano, Veiculo.cor, Veiculo.motor, Veiculo.proprietario, Marca.nome FROM Veiculo JOIN Marca ON (Marca.i...
true
true
f7514a01ba6c2d2fd7eb5b11b8515fd03d8e044c
2,129
py
Python
src/alerts.py
mamoedo/social-alerts
82d63c561c76274eb1ee7fefc7f1a5968b1b3b5f
[ "MIT" ]
7
2020-03-23T11:33:59.000Z
2021-06-03T01:56:27.000Z
src/alerts.py
mamoedo/social-alerts
82d63c561c76274eb1ee7fefc7f1a5968b1b3b5f
[ "MIT" ]
null
null
null
src/alerts.py
mamoedo/social-alerts
82d63c561c76274eb1ee7fefc7f1a5968b1b3b5f
[ "MIT" ]
null
null
null
import json import re TYPE_TWITTER = "twitter" TYPE_INSTA = "instagram" TYPES = (TYPE_INSTA, TYPE_TWITTER) __alerts_list = [] def get_alerts_list(): if not __alerts_list: load_alerts() return __alerts_list def load_alerts(): with open("alerts.json", "r") as fp: for alert in json.load(fp...
29.985915
111
0.577266
import json import re TYPE_TWITTER = "twitter" TYPE_INSTA = "instagram" TYPES = (TYPE_INSTA, TYPE_TWITTER) __alerts_list = [] def get_alerts_list(): if not __alerts_list: load_alerts() return __alerts_list def load_alerts(): with open("alerts.json", "r") as fp: for alert in json.load(fp...
true
true
f7514b5df170dbebb862a239366a6d2ee635eb68
464
py
Python
alipay/aop/api/response/AlipayOpenAppSilanApigraytwoQueryResponse.py
snowxmas/alipay-sdk-python-all
96870ced60facd96c5bce18d19371720cbda3317
[ "Apache-2.0" ]
213
2018-08-27T16:49:32.000Z
2021-12-29T04:34:12.000Z
alipay/aop/api/response/AlipayOpenAppSilanApigraytwoQueryResponse.py
snowxmas/alipay-sdk-python-all
96870ced60facd96c5bce18d19371720cbda3317
[ "Apache-2.0" ]
29
2018-09-29T06:43:00.000Z
2021-09-02T03:27:32.000Z
alipay/aop/api/response/AlipayOpenAppSilanApigraytwoQueryResponse.py
snowxmas/alipay-sdk-python-all
96870ced60facd96c5bce18d19371720cbda3317
[ "Apache-2.0" ]
59
2018-08-27T16:59:26.000Z
2022-03-25T10:08:15.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- import json from alipay.aop.api.response.AlipayResponse import AlipayResponse class AlipayOpenAppSilanApigraytwoQueryResponse(AlipayResponse): def __init__(self): super(AlipayOpenAppSilanApigraytwoQueryResponse, self).__init__() def parse_response_cont...
29
114
0.790948
import json from alipay.aop.api.response.AlipayResponse import AlipayResponse class AlipayOpenAppSilanApigraytwoQueryResponse(AlipayResponse): def __init__(self): super(AlipayOpenAppSilanApigraytwoQueryResponse, self).__init__() def parse_response_content(self, response_content): response ...
true
true
f7514c3a3eaf678ce7d778ca6c7f72f18d562af5
3,134
py
Python
chapter12/djangoApplication/djangoApplication/settings.py
yangwawa0323/Learning-Python-Networking-Second-Edition
5460fe4fb6acc5d0df19bf36e52ac09e9a11eb8b
[ "MIT" ]
52
2018-12-17T19:33:06.000Z
2022-03-25T18:14:02.000Z
chapter12/djangoApplication/djangoApplication/settings.py
barretthugh/Learning-Python-Networking-Second-Edition
0f00b8b20c1c85e76754e47113dff8ca9e99d5ca
[ "MIT" ]
null
null
null
chapter12/djangoApplication/djangoApplication/settings.py
barretthugh/Learning-Python-Networking-Second-Edition
0f00b8b20c1c85e76754e47113dff8ca9e99d5ca
[ "MIT" ]
38
2018-12-18T09:08:43.000Z
2022-02-06T02:53:05.000Z
""" Django settings for djangoApplication project. Generated by 'django-admin startproject' using Django 2.1.7. For more information on this file, see https://docs.djangoproject.com/en/2.1/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/2.1/ref/settings/ """ im...
25.688525
91
0.700064
import os BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) SECRET_KEY = ')bi66w41j_fkm*(ec+)7cckw1-rw(s5yd#ctexaz4hnhxz!5_5' DEBUG = True ALLOWED_HOSTS = [] # Application definition INSTALLED_APPS = [ 'django.contrib.admin', 'django.contrib.auth', 'django.contrib.contenttypes...
true
true
f7514c6124fb36cc8612ad92c930ce98d4181da4
9,207
py
Python
sdk/python/pulumi_azure_native/network/v20190601/get_virtual_network_peering.py
sebtelko/pulumi-azure-native
711ec021b5c73da05611c56c8a35adb0ce3244e4
[ "Apache-2.0" ]
null
null
null
sdk/python/pulumi_azure_native/network/v20190601/get_virtual_network_peering.py
sebtelko/pulumi-azure-native
711ec021b5c73da05611c56c8a35adb0ce3244e4
[ "Apache-2.0" ]
null
null
null
sdk/python/pulumi_azure_native/network/v20190601/get_virtual_network_peering.py
sebtelko/pulumi-azure-native
711ec021b5c73da05611c56c8a35adb0ce3244e4
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi SDK Generator. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union, overload from ... import _utilities fro...
46.035
335
0.701966
import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union, overload from ... import _utilities from . import outputs __all__ = [ 'GetVirtualNetworkPeeringResult', 'AwaitableGetVirtualNetworkPeeringResult', 'get_virtual_network_peering', ] @pulumi.outpu...
true
true
f7514cc6829a6634ff3fe3333bda352ad549608e
1,791
py
Python
samples/generated_samples/dialogflow_generated_dialogflowcx_v3beta1_security_settings_service_update_security_settings_sync.py
nicain/python-dialogflow-cx
2292ff540aea24c3c831a5ffe1604c2c022ccb82
[ "Apache-2.0" ]
null
null
null
samples/generated_samples/dialogflow_generated_dialogflowcx_v3beta1_security_settings_service_update_security_settings_sync.py
nicain/python-dialogflow-cx
2292ff540aea24c3c831a5ffe1604c2c022ccb82
[ "Apache-2.0" ]
null
null
null
samples/generated_samples/dialogflow_generated_dialogflowcx_v3beta1_security_settings_service_update_security_settings_sync.py
nicain/python-dialogflow-cx
2292ff540aea24c3c831a5ffe1604c2c022ccb82
[ "Apache-2.0" ]
null
null
null
# -*- 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...
35.82
103
0.788945
from google.cloud import dialogflowcx_v3beta1 def sample_update_security_settings(): client = dialogflowcx_v3beta1.SecuritySettingsServiceClient() security_settings = dialogflowcx_v3beta1.SecuritySettings() security_settings.retention_window_days = 2271 security_settings.display_name = "di...
true
true
f7514cca8e4806bcb5ece1a3dcaf5ca2a8d7b600
357
py
Python
ejercicios/ejercicio18.py
Ironwilly/python
f6d42c685b4026b018089edb4ae8cc0ca9614e86
[ "CC0-1.0" ]
null
null
null
ejercicios/ejercicio18.py
Ironwilly/python
f6d42c685b4026b018089edb4ae8cc0ca9614e86
[ "CC0-1.0" ]
null
null
null
ejercicios/ejercicio18.py
Ironwilly/python
f6d42c685b4026b018089edb4ae8cc0ca9614e86
[ "CC0-1.0" ]
null
null
null
#Pedir el nombre y los dos apellidos de una persona # y mostrar las iniciales. nombre = input("Nombre: ") apellido1 = input("Primer apellido: ") apellido2 = input("Segundo apellido: ") inicial = nombre[0] inicial = inicial + apellido1[0] inicial = inicial + apellido2[0] inicial = inicial.upper() print("Las inicial...
22.3125
53
0.711485
nombre = input("Nombre: ") apellido1 = input("Primer apellido: ") apellido2 = input("Segundo apellido: ") inicial = nombre[0] inicial = inicial + apellido1[0] inicial = inicial + apellido2[0] inicial = inicial.upper() print("Las iniciales de tu nombre son: %s"%(inicial))
true
true
f7514fce0cccc812d1c0933acbcc9b734d8a1e5f
1,997
py
Python
core/models.py
aalmobin/profiles-rest-api
50851ef1dd6959d4d8ea4832ced9e68e456b8540
[ "MIT" ]
null
null
null
core/models.py
aalmobin/profiles-rest-api
50851ef1dd6959d4d8ea4832ced9e68e456b8540
[ "MIT" ]
null
null
null
core/models.py
aalmobin/profiles-rest-api
50851ef1dd6959d4d8ea4832ced9e68e456b8540
[ "MIT" ]
null
null
null
from django.db import models from django.contrib.auth.models import AbstractBaseUser, BaseUserManager, PermissionsMixin from django.conf import settings class UserProfileManager(BaseUserManager): """Manager for user profiles""" def create_user(self, email, name, password=None): """Create a new user p...
29.80597
90
0.682524
from django.db import models from django.contrib.auth.models import AbstractBaseUser, BaseUserManager, PermissionsMixin from django.conf import settings class UserProfileManager(BaseUserManager): def create_user(self, email, name, password=None): if not email: raise ValueError('User must have...
true
true
f7515029e3afa5a0ad3d0a8992f51d3cce54e091
3,936
py
Python
artview/core/variable_choose.py
savelov/artview
83c918757d6ae51cecc7589af4ab279e2c750bfe
[ "BSD-3-Clause" ]
40
2015-02-20T02:49:45.000Z
2021-09-10T09:00:49.000Z
artview/core/variable_choose.py
savelov/artview
83c918757d6ae51cecc7589af4ab279e2c750bfe
[ "BSD-3-Clause" ]
189
2015-02-20T03:21:31.000Z
2021-03-23T13:46:24.000Z
artview/core/variable_choose.py
savelov/artview
83c918757d6ae51cecc7589af4ab279e2c750bfe
[ "BSD-3-Clause" ]
19
2015-03-06T17:22:21.000Z
2022-02-08T17:30:30.000Z
""" variable_choose.py Class instance for finding and choosing shared variable from other components. """ # Load the needed packages from functools import partial from .core import componentsList, QtWidgets, QtCore from . import common class VariableChoose(QtWidgets.QDialog): ''' Class instance for fin...
32
75
0.597815
from functools import partial from .core import componentsList, QtWidgets, QtCore from . import common class VariableChoose(QtWidgets.QDialog): @classmethod def guiStart(self, parent=None): return self(parent=parent) def __init__(self, components=None, compSelect=False, varSelect=True, ...
true
true
f751527f4010db2178948021484f40185235157b
15,959
py
Python
egg/zoo/basic_games/play.py
schlevik/EGG
428d5aed3eb6fb0296f6856fb77b0a1cdceb33f1
[ "MIT" ]
null
null
null
egg/zoo/basic_games/play.py
schlevik/EGG
428d5aed3eb6fb0296f6856fb77b0a1cdceb33f1
[ "MIT" ]
null
null
null
egg/zoo/basic_games/play.py
schlevik/EGG
428d5aed3eb6fb0296f6856fb77b0a1cdceb33f1
[ "MIT" ]
1
2021-09-14T12:19:41.000Z
2021-09-14T12:19:41.000Z
# Copyright (c) Facebook, Inc. and its affiliates. # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. import argparse import numpy as np import torch import torch.nn.functional as F from torch.utils.data import DataLoader import egg.core as co...
48.655488
236
0.672348
import argparse import numpy as np import torch import torch.nn.functional as F from torch.utils.data import DataLoader import egg.core as core from egg.core import Callback, Interaction, PrintValidationEvents from egg.zoo.basic_games.architectures import DiscriReceiver, RecoReceiver, Sender from egg.zoo.basic_game...
true
true
f75152f7d1181f105ddb0b3362dd118a37414191
682
py
Python
youtube_podcast_gateway/util.py
Feuermurmel/youtube-podcast-gateway
41f85111a6fbdb36ab2ca2a765625a442b4fea99
[ "WTFPL" ]
39
2015-09-29T20:21:30.000Z
2022-02-02T07:14:50.000Z
youtube_podcast_gateway/util.py
Feuermurmel/youtube-podcast-gateway
41f85111a6fbdb36ab2ca2a765625a442b4fea99
[ "WTFPL" ]
25
2015-05-12T01:24:13.000Z
2021-08-02T09:58:19.000Z
youtube_podcast_gateway/util.py
Feuermurmel/youtube-podcast-gateway
41f85111a6fbdb36ab2ca2a765625a442b4fea99
[ "WTFPL" ]
9
2015-10-12T11:31:14.000Z
2021-07-29T19:19:31.000Z
import sys def freeze(obj): if isinstance(obj, dict): return frozenset(map(freeze, obj.items())) if isinstance(obj, (list, tuple)): return tuple(map(freeze, obj)) if isinstance(obj, set): return frozenset(obj) else: return obj def memorized(func): map = {} de...
18.432432
50
0.552786
import sys def freeze(obj): if isinstance(obj, dict): return frozenset(map(freeze, obj.items())) if isinstance(obj, (list, tuple)): return tuple(map(freeze, obj)) if isinstance(obj, set): return frozenset(obj) else: return obj def memorized(func): map = {} de...
true
true
f751538975ecdc8724f54492e2b4bcb0e708745b
746
py
Python
src/copyist/helpers.py
Polyconseil/copyist
ef6df5ba7296009b5fc46a69019965bb419de232
[ "MIT" ]
null
null
null
src/copyist/helpers.py
Polyconseil/copyist
ef6df5ba7296009b5fc46a69019965bb419de232
[ "MIT" ]
null
null
null
src/copyist/helpers.py
Polyconseil/copyist
ef6df5ba7296009b5fc46a69019965bb419de232
[ "MIT" ]
null
null
null
import tomlkit def fill_tool_section(previous_content, tool_name, section_text): """TOML Helper ensuring that a [tool.<tool_name>] section contains <section_text>""" current_state = tomlkit.parse(previous_content) tool_table = tomlkit.parse(section_text)["tool"][tool_name] if "tool" not in current_s...
33.909091
88
0.697051
import tomlkit def fill_tool_section(previous_content, tool_name, section_text): current_state = tomlkit.parse(previous_content) tool_table = tomlkit.parse(section_text)["tool"][tool_name] if "tool" not in current_state: tool_table = tomlkit.table() tool_table._is_super_table = T...
true
true
f75153a56539e5cd43f7d35d9a7b173414aa58e2
198
py
Python
tests/__init__.py
jonashellmann/informaticup21-team-chillow
f2e519af0a5d9a9368d62556703cfb1066ebb58f
[ "MIT" ]
3
2021-01-17T23:32:07.000Z
2022-01-30T14:49:16.000Z
tests/__init__.py
jonashellmann/informaticup21-team-chillow
f2e519af0a5d9a9368d62556703cfb1066ebb58f
[ "MIT" ]
2
2021-01-17T13:37:56.000Z
2021-04-14T12:28:49.000Z
tests/__init__.py
jonashellmann/informaticup21-team-chillow
f2e519af0a5d9a9368d62556703cfb1066ebb58f
[ "MIT" ]
2
2021-04-02T14:53:38.000Z
2021-04-20T11:10:17.000Z
import os def read_test_file(filename: str) -> str: file = open(os.path.join(os.path.dirname(__file__), 'test_data/' + filename)) content = file.read() file.close() return content
22
81
0.666667
import os def read_test_file(filename: str) -> str: file = open(os.path.join(os.path.dirname(__file__), 'test_data/' + filename)) content = file.read() file.close() return content
true
true
f75154c0f96287fe4623112f3de0cc0e61d931f4
4,357
py
Python
experiments/murtaza/multiworld/camera_ready/pusher/offline_vae2.py
Asap7772/railrl_evalsawyer
baba8ce634d32a48c7dfe4dc03b123e18e96e0a3
[ "MIT" ]
null
null
null
experiments/murtaza/multiworld/camera_ready/pusher/offline_vae2.py
Asap7772/railrl_evalsawyer
baba8ce634d32a48c7dfe4dc03b123e18e96e0a3
[ "MIT" ]
null
null
null
experiments/murtaza/multiworld/camera_ready/pusher/offline_vae2.py
Asap7772/railrl_evalsawyer
baba8ce634d32a48c7dfe4dc03b123e18e96e0a3
[ "MIT" ]
null
null
null
import rlkit.misc.hyperparameter as hyp from multiworld.envs.mujoco.cameras import sawyer_pusher_camera_upright_v3 from rlkit.launchers.launcher_util import run_experiment from rlkit.torch.grill.launcher import grill_her_td3_full_experiment if __name__ == "__main__": variant = dict( imsize=84, init...
35.713115
151
0.54992
import rlkit.misc.hyperparameter as hyp from multiworld.envs.mujoco.cameras import sawyer_pusher_camera_upright_v3 from rlkit.launchers.launcher_util import run_experiment from rlkit.torch.grill.launcher import grill_her_td3_full_experiment if __name__ == "__main__": variant = dict( imsize=84, init...
true
true
f7515539dd8ed33dc88a5d9a7d0d4c31f8704b13
3,205
py
Python
mindmeld/converter/converter.py
derekmpham/mindmeld
18189f956e4e3eb92df61fde95ec82f73b9efa91
[ "Apache-2.0" ]
null
null
null
mindmeld/converter/converter.py
derekmpham/mindmeld
18189f956e4e3eb92df61fde95ec82f73b9efa91
[ "Apache-2.0" ]
null
null
null
mindmeld/converter/converter.py
derekmpham/mindmeld
18189f956e4e3eb92df61fde95ec82f73b9efa91
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # # Copyright (c) 2015 Cisco Systems, Inc. and others. 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...
34.836957
84
0.678315
import logging import os from abc import ABC, abstractmethod logger = logging.getLogger(__name__) class Converter(ABC): def __init__(self): pass @abstractmethod def convert_project(self): pass @abstractmethod def create_mindmeld_directory(self): pass @abstractmet...
true
true
f751565273807ef64e34e16513b8f0dad828cb9d
3,246
py
Python
test/model.py
kasimte/Pytorch-pensieve
e550d9c36ed35b49592955fefbc17d1424d37b3b
[ "MIT" ]
null
null
null
test/model.py
kasimte/Pytorch-pensieve
e550d9c36ed35b49592955fefbc17d1424d37b3b
[ "MIT" ]
null
null
null
test/model.py
kasimte/Pytorch-pensieve
e550d9c36ed35b49592955fefbc17d1424d37b3b
[ "MIT" ]
null
null
null
from __future__ import division import torch import torch.nn as nn import torch.nn.functional as F from utils import norm_col_init, weights_init # class agentNET(torch.nn.Module): # def __init__(self, num_inputs = 1, num_outputs = 6): # super(agentNET, self).__init__() # # self.conv1 = nn.Conv1d(nu...
31.514563
72
0.579482
from __future__ import division import torch import torch.nn as nn import torch.nn.functional as F from utils import norm_col_init, weights_init class agentNET(torch.nn.Module): def __init__(self, num_inputs = 1, num_outputs = 6, S_LEN = 8): super(agentNET, self).__init__() self.conv1 = nn.Conv2d...
true
true
f75156d6f2a868ad6fe03fc38ac8dd074465cf88
7,529
py
Python
app/__init__.py
BoringBuffalo/throat
23d342b8ae293ed5de4d4bbdef090308d724df7a
[ "MIT" ]
null
null
null
app/__init__.py
BoringBuffalo/throat
23d342b8ae293ed5de4d4bbdef090308d724df7a
[ "MIT" ]
null
null
null
app/__init__.py
BoringBuffalo/throat
23d342b8ae293ed5de4d4bbdef090308d724df7a
[ "MIT" ]
null
null
null
# -*- coding: utf-8 """ Here is where all the good stuff happens """ from urllib.parse import urlparse import time import socket import datetime from bs4 import BeautifulSoup from flask import Flask, url_for, g, request, get_flashed_messages from flask_login import LoginManager, current_user from flask_webpack import ...
41.827778
118
0.679772
from urllib.parse import urlparse import time import socket import datetime from bs4 import BeautifulSoup from flask import Flask, url_for, g, request, get_flashed_messages from flask_login import LoginManager, current_user from flask_webpack import Webpack from flask_babel import Babel, _ from wheezy.html.utils impor...
true
true
f75157cd5708ffde6367a95b96d256f9053b4803
336
py
Python
5. WEB/app/external_sources/places/migrations/0002_remove_googleelement_price_level_missing.py
doyaguillo1997/Data2Gether
125e3e54060b342a473480f8cb1a913fc54f55ed
[ "MIT" ]
1
2021-10-03T10:19:14.000Z
2021-10-03T10:19:14.000Z
5. WEB/app/external_sources/places/migrations/0002_remove_googleelement_price_level_missing.py
doyaguillo1997/Data2Gether
125e3e54060b342a473480f8cb1a913fc54f55ed
[ "MIT" ]
null
null
null
5. WEB/app/external_sources/places/migrations/0002_remove_googleelement_price_level_missing.py
doyaguillo1997/Data2Gether
125e3e54060b342a473480f8cb1a913fc54f55ed
[ "MIT" ]
null
null
null
# Generated by Django 3.2.6 on 2021-08-24 10:45 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('places', '0001_initial'), ] operations = [ migrations.RemoveField( model_name='googleelement', name='price_level_missing', ...
18.666667
47
0.60119
from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('places', '0001_initial'), ] operations = [ migrations.RemoveField( model_name='googleelement', name='price_level_missing', ), ]
true
true
f75158b499dfb05fef535b2348c00c185ed59ba4
405
py
Python
sales/migrations/0008_auto_20200912_0910.py
zhou-en/turf_portal
2424ac15248c9f1c0fa4f65ca18fe0ea71d7ff4e
[ "MIT" ]
null
null
null
sales/migrations/0008_auto_20200912_0910.py
zhou-en/turf_portal
2424ac15248c9f1c0fa4f65ca18fe0ea71d7ff4e
[ "MIT" ]
47
2020-10-14T21:54:35.000Z
2022-02-25T05:21:39.000Z
sales/migrations/0008_auto_20200912_0910.py
zhou-en/turf_portal
2424ac15248c9f1c0fa4f65ca18fe0ea71d7ff4e
[ "MIT" ]
null
null
null
# Generated by Django 3.1.1 on 2020-09-12 09:10 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('sales', '0007_order_orderline'), ] operations = [ migrations.AlterField( model_name='orderline', name='price', ...
21.315789
72
0.6
from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('sales', '0007_order_orderline'), ] operations = [ migrations.AlterField( model_name='orderline', name='price', field=models.FloatField(blank=True, defau...
true
true
f75159ea5bfa07f759d0caec582a272efdb3a0aa
95
py
Python
jupyterlabpymolpysnips/MolecularRepresentation/saxsEnvelope.py
MooersLab/pymolpysnips
50a89c85adf8006d85c1d6cd3f8aad7e440a0b92
[ "MIT" ]
null
null
null
jupyterlabpymolpysnips/MolecularRepresentation/saxsEnvelope.py
MooersLab/pymolpysnips
50a89c85adf8006d85c1d6cd3f8aad7e440a0b92
[ "MIT" ]
null
null
null
jupyterlabpymolpysnips/MolecularRepresentation/saxsEnvelope.py
MooersLab/pymolpysnips
50a89c85adf8006d85c1d6cd3f8aad7e440a0b92
[ "MIT" ]
null
null
null
cmd.do('alter refine_A_Ave_SM_015_0_370-374-0r, vdw=3.0;') cmd.do('set solvent_radius = 3.0;')
31.666667
58
0.726316
cmd.do('alter refine_A_Ave_SM_015_0_370-374-0r, vdw=3.0;') cmd.do('set solvent_radius = 3.0;')
true
true
f7515a104f606d13442e2f97dc1cd61855469d4e
156
py
Python
201504/silsp3.py
conlee82/pythonstudy
c71bdd6404c0105a812043368f17b993a9d8a7c9
[ "Apache-2.0" ]
null
null
null
201504/silsp3.py
conlee82/pythonstudy
c71bdd6404c0105a812043368f17b993a9d8a7c9
[ "Apache-2.0" ]
null
null
null
201504/silsp3.py
conlee82/pythonstudy
c71bdd6404c0105a812043368f17b993a9d8a7c9
[ "Apache-2.0" ]
null
null
null
friends = ['john', 'pat', 'gary', 'michael'] for i, name in enumerate(friends): print ("no. {iteration} is {name}".format(iteration=i+1, name=name))
39
72
0.628205
friends = ['john', 'pat', 'gary', 'michael'] for i, name in enumerate(friends): print ("no. {iteration} is {name}".format(iteration=i+1, name=name))
true
true
f7515b5996d204f1739b35001a682bbd11b2cc6a
940
py
Python
src/ipcollector/setup.py
logdna/k8s-egress-networkpolicy-manager
3305ed30cbd07d1b549b743d02fde53a596780ca
[ "MIT" ]
null
null
null
src/ipcollector/setup.py
logdna/k8s-egress-networkpolicy-manager
3305ed30cbd07d1b549b743d02fde53a596780ca
[ "MIT" ]
null
null
null
src/ipcollector/setup.py
logdna/k8s-egress-networkpolicy-manager
3305ed30cbd07d1b549b743d02fde53a596780ca
[ "MIT" ]
1
2021-09-26T00:06:52.000Z
2021-09-26T00:06:52.000Z
from ipcollector import __version__ from setuptools import setup, find_packages from sys import path from os import environ path.insert(0, '.') NAME = 'ipcollector' if __name__ == '__main__': with open(environ.get('REQUIREMENTS_TXT', 'requirements.txt')) as f: requirements = f.read().splitlines() s...
29.375
162
0.669149
from ipcollector import __version__ from setuptools import setup, find_packages from sys import path from os import environ path.insert(0, '.') NAME = 'ipcollector' if __name__ == '__main__': with open(environ.get('REQUIREMENTS_TXT', 'requirements.txt')) as f: requirements = f.read().splitlines() s...
true
true
f7515bea754f9d8e8febae264558c46777f59659
6,214
py
Python
run_era5_rapid.py
BYU-Hydroinformatics/annual_era5_update
c283634891f956d02e24cc587cdfd6b196d24dc0
[ "BSD-3-Clause" ]
1
2020-07-09T16:56:40.000Z
2020-07-09T16:56:40.000Z
run_era5_rapid.py
BYU-Hydroinformatics/annual_era5_update
c283634891f956d02e24cc587cdfd6b196d24dc0
[ "BSD-3-Clause" ]
null
null
null
run_era5_rapid.py
BYU-Hydroinformatics/annual_era5_update
c283634891f956d02e24cc587cdfd6b196d24dc0
[ "BSD-3-Clause" ]
null
null
null
""" update_era5_workflow.py Author: Chris Edwards Copyright June 2020 License: BSD 3 Clause Updated: July 2020 Script to run ERA-5 RAPID simulation for one whole year of ERA-5 Runoff data. To run the script, give 6 additional arguments: 1. path to rapid executable 2. path to directory with LSM Grid (ERA-5 Run...
45.691176
115
0.683135
import os import sys from datetime import datetime, timedelta from RAPIDpy.inflow import run_lsm_rapid_process def run_era5_rapid_simulation(region, rapid_executable_location, lsm_data_location, master_input_location, master_output_location, prev_sim_end_date_str, simulation_start_dateti...
true
true
f7515c064b68faa71640151776b954a04b107cd6
2,079
py
Python
cogs/setInstructor.py
War-Keeper/TeachersPetBot
e2a730b8a97ef38323d2225ae5ada864d1c5968a
[ "MIT" ]
null
null
null
cogs/setInstructor.py
War-Keeper/TeachersPetBot
e2a730b8a97ef38323d2225ae5ada864d1c5968a
[ "MIT" ]
41
2021-10-13T03:02:40.000Z
2021-11-05T01:48:05.000Z
cogs/setInstructor.py
War-Keeper/TeachersPetBot
e2a730b8a97ef38323d2225ae5ada864d1c5968a
[ "MIT" ]
2
2021-11-12T00:03:13.000Z
2021-11-12T00:03:19.000Z
# Copyright (c) 2021 War-Keeper import discord from discord.utils import get from discord.ext import commands # ----------------------------------------------------------------------- # A basic "Hello World!" command, used to verify basic bot functionality # -----------------------------------------------------------...
39.226415
135
0.568062
import discord from discord.utils import get from discord.ext import commands class setInstructor(commands.Cog): def __init__(self, bot): self.bot = bot @commands.command(name='setInstructor', help='Set member to Instructor.') @commands.has_role('Instructor') ...
true
true
f7515cea53e07b59c37807f607acaba745ebe88a
407
py
Python
healthier/migrations/0006_auto_20200521_1246.py
paulgirmes/P11
a686dc1d1215d2067636498ec233aaf607d6979d
[ "MIT" ]
2
2020-05-19T08:19:45.000Z
2020-06-12T08:19:51.000Z
healthier/migrations/0006_auto_20200521_1246.py
paulgirmes/P11
a686dc1d1215d2067636498ec233aaf607d6979d
[ "MIT" ]
3
2021-03-30T14:41:20.000Z
2021-06-17T07:08:33.000Z
healthier/migrations/0006_auto_20200521_1246.py
paulgirmes/P11
a686dc1d1215d2067636498ec233aaf607d6979d
[ "MIT" ]
null
null
null
# Generated by Django 3.0.6 on 2020-05-21 10:46 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ("healthier", "0005_auto_20200521_1237"), ] operations = [ migrations.AlterField( model_name="food_item", name="id_ope...
21.421053
54
0.619165
from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ("healthier", "0005_auto_20200521_1237"), ] operations = [ migrations.AlterField( model_name="food_item", name="id_open_food_facts", field=models.BigInteg...
true
true
f7515cf8176d58efa94505c67cfe9a2d56dedebb
2,440
py
Python
pysparkling/sql/internal_utils/readers/textreader.py
ptallada/pysparkling
f0e8e8d039f3313c2693b7c7576cb1b7ba5a6d78
[ "Apache-2.0" ]
260
2015-05-11T18:08:44.000Z
2022-01-15T13:19:43.000Z
pysparkling/sql/internal_utils/readers/textreader.py
ptallada/pysparkling
f0e8e8d039f3313c2693b7c7576cb1b7ba5a6d78
[ "Apache-2.0" ]
79
2015-06-02T09:53:25.000Z
2021-09-26T11:18:18.000Z
pysparkling/sql/internal_utils/readers/textreader.py
ptallada/pysparkling
f0e8e8d039f3313c2693b7c7576cb1b7ba5a6d78
[ "Apache-2.0" ]
50
2015-06-06T17:00:58.000Z
2022-01-15T13:19:18.000Z
from functools import partial import itertools from ....fileio import TextFile from ...internal_utils.options import Options from ...internal_utils.readers.utils import resolve_partitions from ...types import create_row, StringType, StructField, StructType class TextReader: default_options = dict( lineSe...
29.756098
98
0.648361
from functools import partial import itertools from ....fileio import TextFile from ...internal_utils.options import Options from ...internal_utils.readers.utils import resolve_partitions from ...types import create_row, StringType, StructField, StructType class TextReader: default_options = dict( lineSe...
true
true
f7515ed8037ab9b592049b6f3b78d2a340a9ca23
16,135
py
Python
unittests/test_cli.py
pramodk/reframe
c18cde8fc856e5711e5a0cb621fbf6339066296c
[ "BSD-3-Clause" ]
null
null
null
unittests/test_cli.py
pramodk/reframe
c18cde8fc856e5711e5a0cb621fbf6339066296c
[ "BSD-3-Clause" ]
null
null
null
unittests/test_cli.py
pramodk/reframe
c18cde8fc856e5711e5a0cb621fbf6339066296c
[ "BSD-3-Clause" ]
null
null
null
# Copyright 2016-2020 Swiss National Supercomputing Centre (CSCS/ETH Zurich) # ReFrame Project Developers. See the top-level LICENSE file for details. # # SPDX-License-Identifier: BSD-3-Clause import itertools import os import pathlib import pytest import re import sys from contextlib import redirect_stdout, redirect_...
30.616698
79
0.648404
import itertools import os import pathlib import pytest import re import sys from contextlib import redirect_stdout, redirect_stderr, suppress from io import StringIO import reframe.core.config as config import reframe.core.environments as env import reframe.core.runtime as rt import reframe.utility.os_ext as os_ext ...
true
true
f751602415f6cc09ef81c271b8fc4cd7d7dc850e
348
py
Python
ex0077b.py
EwertonRosendo/PastaDeExercicios
68d23194b87ce1c8405c70fcceb3378955815d7d
[ "MIT" ]
null
null
null
ex0077b.py
EwertonRosendo/PastaDeExercicios
68d23194b87ce1c8405c70fcceb3378955815d7d
[ "MIT" ]
null
null
null
ex0077b.py
EwertonRosendo/PastaDeExercicios
68d23194b87ce1c8405c70fcceb3378955815d7d
[ "MIT" ]
null
null
null
palavras = ("aprender", "programar", "linguagem", "python", "python", "curso", "gratis", "estudar", "praticar", "trabalhar", "mercado", "programador", "futuro",) for p in palavras: print("\nNa palavra {} temos".format(p), end=" ") for letra in p: if letra in "aeiou": ...
38.666667
63
0.54023
palavras = ("aprender", "programar", "linguagem", "python", "python", "curso", "gratis", "estudar", "praticar", "trabalhar", "mercado", "programador", "futuro",) for p in palavras: print("\nNa palavra {} temos".format(p), end=" ") for letra in p: if letra in "aeiou": ...
true
true
f7516193dab249c0fba69e960382ce59b8ea7be3
3,733
py
Python
Challenges/chall_20.py
HKuz/PythonChallenge
e9d72616aa389483cab710bca3bccf708c0f99e0
[ "MIT" ]
null
null
null
Challenges/chall_20.py
HKuz/PythonChallenge
e9d72616aa389483cab710bca3bccf708c0f99e0
[ "MIT" ]
null
null
null
Challenges/chall_20.py
HKuz/PythonChallenge
e9d72616aa389483cab710bca3bccf708c0f99e0
[ "MIT" ]
null
null
null
#!/usr/local/bin/python3 # Python Challenge - 20 # http://www.pythonchallenge.com/pc/hex/idiot2.html # Username: butter; Password: fly # Keyword: invader, redavni import base64 import urllib.request import re def main(): ''' Hint: go away! Picture is fence with sign 'Private property beyond this fenc...
31.108333
76
0.64854
import base64 import urllib.request import re def main(): url = 'http://www.pythonchallenge.com/pc/hex/unreal.jpg' auth = base64.b64encode(b'butter:fly').decode() headers = {'Authorization': 'Basic {}'.format(auth)} request = urllib.request.Request(url, headers=headers) response = ur...
true
true
f751623283120cdddfbf77620a4ee5f0d3d038fa
2,628
py
Python
page_xml_draw/struct/json.py
GBN-DBP/page-xml-draw
ecf3123b385c58286649ba5b5bddc2a9d834daf8
[ "Apache-2.0" ]
6
2021-02-01T12:45:10.000Z
2021-02-03T14:14:28.000Z
page_xml_draw/struct/json.py
GBN-DBP/page-xml-draw
ecf3123b385c58286649ba5b5bddc2a9d834daf8
[ "Apache-2.0" ]
1
2021-02-17T02:02:08.000Z
2021-02-17T02:02:08.000Z
page_xml_draw/struct/json.py
GBN-DBP/page-xml-draw
ecf3123b385c58286649ba5b5bddc2a9d834daf8
[ "Apache-2.0" ]
null
null
null
from __future__ import annotations from typing import Any from copy import deepcopy from json import loads from jsonschema import RefResolver, validate from pkg_resources import resource_string class JsonSchema: data: dict resolver: RefResolver def __init__(self, data: dict, resolver: RefResolver = None...
26.28
79
0.608067
from __future__ import annotations from typing import Any from copy import deepcopy from json import loads from jsonschema import RefResolver, validate from pkg_resources import resource_string class JsonSchema: data: dict resolver: RefResolver def __init__(self, data: dict, resolver: RefResolver = None...
true
true