hexsha
stringlengths
40
40
size
int64
5
2.06M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
3
248
max_stars_repo_name
stringlengths
5
125
max_stars_repo_head_hexsha
stringlengths
40
78
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
3
248
max_issues_repo_name
stringlengths
5
125
max_issues_repo_head_hexsha
stringlengths
40
78
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
3
248
max_forks_repo_name
stringlengths
5
125
max_forks_repo_head_hexsha
stringlengths
40
78
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
5
2.06M
avg_line_length
float64
1
1.02M
max_line_length
int64
3
1.03M
alphanum_fraction
float64
0
1
count_classes
int64
0
1.6M
score_classes
float64
0
1
count_generators
int64
0
651k
score_generators
float64
0
1
count_decorators
int64
0
990k
score_decorators
float64
0
1
count_async_functions
int64
0
235k
score_async_functions
float64
0
1
count_documentation
int64
0
1.04M
score_documentation
float64
0
1
a502ec147157338573c2ac7095c41e2a9d21ad73
515
py
Python
titan/django_pkg/appmodule/__init__.py
mnieber/gen
65f8aa4fb671c4f90d5cbcb1a0e10290647a31d9
[ "MIT" ]
null
null
null
titan/django_pkg/appmodule/__init__.py
mnieber/gen
65f8aa4fb671c4f90d5cbcb1a0e10290647a31d9
[ "MIT" ]
null
null
null
titan/django_pkg/appmodule/__init__.py
mnieber/gen
65f8aa4fb671c4f90d5cbcb1a0e10290647a31d9
[ "MIT" ]
null
null
null
import moonleap.resource.props as P from moonleap import create, extend from moonleap.utils.case import kebab_to_camel, sn from moonleap.verbs import has from titan.django_pkg.djangoapp import DjangoApp from .resources import AppModule # noqa @create("app:module") def create_app_module(term): module = AppModule...
25.75
58
0.776699
81
0.157282
0
0
264
0.512621
0
0
30
0.058252
a506b736c248be3b528126847b39f395938649f3
11,437
py
Python
workload_auto/vsphere_helper.py
CiscoDevNet/dcnm-workload-automation
36d439f0351b88492d21160c534e1260b9d43ca8
[ "Apache-2.0" ]
null
null
null
workload_auto/vsphere_helper.py
CiscoDevNet/dcnm-workload-automation
36d439f0351b88492d21160c534e1260b9d43ca8
[ "Apache-2.0" ]
null
null
null
workload_auto/vsphere_helper.py
CiscoDevNet/dcnm-workload-automation
36d439f0351b88492d21160c534e1260b9d43ca8
[ "Apache-2.0" ]
1
2020-07-07T14:53:14.000Z
2020-07-07T14:53:14.000Z
# Copyright 2020 Cisco Systems, Inc. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable la...
40.129825
80
0.607677
10,606
0.927341
0
0
0
0
0
0
4,235
0.370289
a50784e85bfaff4fb71807d43ea79954cd711a55
23,041
py
Python
teste.py
dkpm/ES-17-2
b965400ab35dd0101c06cba14367090bf88a45a3
[ "Apache-2.0" ]
null
null
null
teste.py
dkpm/ES-17-2
b965400ab35dd0101c06cba14367090bf88a45a3
[ "Apache-2.0" ]
3
2019-08-05T23:08:42.000Z
2019-08-05T23:14:17.000Z
teste.py
dkpm/ES-17-2
b965400ab35dd0101c06cba14367090bf88a45a3
[ "Apache-2.0" ]
null
null
null
import pytest from principal import somar from principal import sub def test_somar(): assert somar(2,4) == 6 def test_sub(): assert sub(3,2) == 20 ...
1,772.384615
22,903
0.004731
0
0
0
0
0
0
0
0
0
0
a5083f8e81dde75a4b99510e59a13a9684a3d9d3
1,042
py
Python
TextureConversion/Scripts/InvertYellowNormal.py
Beatbox309/Unity-Texture-Conversion
19fd59c34b8d6c1e528db8f220700d5b1ccef5a1
[ "MIT" ]
null
null
null
TextureConversion/Scripts/InvertYellowNormal.py
Beatbox309/Unity-Texture-Conversion
19fd59c34b8d6c1e528db8f220700d5b1ccef5a1
[ "MIT" ]
null
null
null
TextureConversion/Scripts/InvertYellowNormal.py
Beatbox309/Unity-Texture-Conversion
19fd59c34b8d6c1e528db8f220700d5b1ccef5a1
[ "MIT" ]
null
null
null
from PIL import Image from PIL import ImageChops import pathlib import sys sys.path.append(str(pathlib.Path(__file__).parent.absolute())) import TextureConversionMain as tcm def Convert(normPath): # setup ogNorm = Image.open(normPath) normTuple = tcm.SplitImg(ogNorm) print("Images Loaded...
26.05
86
0.673704
0
0
0
0
0
0
0
0
134
0.128599
a508b46bb0fbec56198e8d643e6c23a47a292553
1,695
py
Python
mininet_scripts/simple_net.py
kulawczukmarcin/mypox
b6a0a3cbfc911f94d0ed2ba5c968025879691eab
[ "Apache-2.0" ]
null
null
null
mininet_scripts/simple_net.py
kulawczukmarcin/mypox
b6a0a3cbfc911f94d0ed2ba5c968025879691eab
[ "Apache-2.0" ]
null
null
null
mininet_scripts/simple_net.py
kulawczukmarcin/mypox
b6a0a3cbfc911f94d0ed2ba5c968025879691eab
[ "Apache-2.0" ]
null
null
null
__author__ = 'Ehsan' from mininet.node import CPULimitedHost from mininet.topo import Topo from mininet.net import Mininet from mininet.log import setLogLevel, info from mininet.node import RemoteController from mininet.cli import CLI """ Instructions to run the topo: 1. Go to directory where this fil is. 2. ru...
26.904762
79
0.635988
919
0.542183
0
0
0
0
0
0
576
0.339823
a509787b777a426526c085c8fcec56b5e9a290ec
5,806
py
Python
.ci/watchdog/MSTeamsCommunicator.py
NervanaSystems/ngraph-onnx
7fdb4e503a796ef3871927c550d1245e37cb6ffa
[ "Apache-2.0", "MIT" ]
47
2018-03-17T00:30:59.000Z
2021-11-14T17:18:57.000Z
.ci/watchdog/MSTeamsCommunicator.py
NervanaSystems/ngraph-onnx
7fdb4e503a796ef3871927c550d1245e37cb6ffa
[ "Apache-2.0", "MIT" ]
272
2018-03-22T14:31:09.000Z
2022-03-24T20:51:04.000Z
.ci/watchdog/MSTeamsCommunicator.py
NervanaSystems/ngraph-onnx
7fdb4e503a796ef3871927c550d1245e37cb6ffa
[ "Apache-2.0", "MIT" ]
20
2018-04-03T14:53:58.000Z
2021-03-13T01:21:26.000Z
#!/usr/bin/python3 # INTEL CONFIDENTIAL # Copyright 2018-2020 Intel Corporation # The source code contained or described herein and all documents related to the # source code ("Material") are owned by Intel Corporation or its suppliers or # licensors. Title to the Material remains with Intel Corporation or its # suppl...
40.319444
92
0.59783
4,183
0.720462
0
0
240
0.041337
0
0
3,590
0.618326
a50994e7a70e911cc583b9d0550f81e22ad4842b
4,301
py
Python
script/create_buy_point_data_window.py
AtlantixJJ/vnpy
28992c7d5391f6dd42a14b481d01ceafde048b5f
[ "MIT" ]
null
null
null
script/create_buy_point_data_window.py
AtlantixJJ/vnpy
28992c7d5391f6dd42a14b481d01ceafde048b5f
[ "MIT" ]
null
null
null
script/create_buy_point_data_window.py
AtlantixJJ/vnpy
28992c7d5391f6dd42a14b481d01ceafde048b5f
[ "MIT" ]
null
null
null
"""Create wave training data. Automatically annotate data by identifying waves. The begining, middle and ending are obtained. Windows around these points are collected as training data. They are organized in years. """ import sys, glob, os path = os.getcwd() sys.path.insert(0, ".") from datetime import datetime from v...
33.341085
81
0.56359
0
0
0
0
0
0
0
0
829
0.192746
a50a1a9c4d80a795f5268abc078ed222ed04076c
1,087
py
Python
python/plants/common.py
djcroissant/leds
dec0d963e7d325413d1fedde606039b8baee8c70
[ "BSD-2-Clause" ]
null
null
null
python/plants/common.py
djcroissant/leds
dec0d963e7d325413d1fedde606039b8baee8c70
[ "BSD-2-Clause" ]
null
null
null
python/plants/common.py
djcroissant/leds
dec0d963e7d325413d1fedde606039b8baee8c70
[ "BSD-2-Clause" ]
null
null
null
import time from neopixel import Adafruit_NeoPixel import argparse # Pixel class corresponds to a light strip # It stores the strip, characteristics, and state class Pix: # LED strip configuration: LED_COUNT = 594 # Number of LED pixels. LED_PIN = 18 # GPIO pin connected to the pixels (18 ...
38.821429
110
0.698252
922
0.848206
0
0
0
0
0
0
636
0.585097
a50bf5796e4acbc1519350c7c0f92a9d2b1f20f3
24
py
Python
aldryn_django_cms/__init__.py
vladimir-bezrukov/Aldryn-Django-cms
0edac2ee0d14fada9e960afe99750b343ceeb706
[ "BSD-3-Clause" ]
1
2021-11-04T17:46:35.000Z
2021-11-04T17:46:35.000Z
aldryn_django_cms/__init__.py
vladimir-bezrukov/Aldryn-Django-cms
0edac2ee0d14fada9e960afe99750b343ceeb706
[ "BSD-3-Clause" ]
null
null
null
aldryn_django_cms/__init__.py
vladimir-bezrukov/Aldryn-Django-cms
0edac2ee0d14fada9e960afe99750b343ceeb706
[ "BSD-3-Clause" ]
null
null
null
__version__ = '3.6.0.1'
12
23
0.625
0
0
0
0
0
0
0
0
9
0.375
a50bf6879a17e8768e2814595f2b630927b697b3
1,730
py
Python
sublime_cscope/settings.py
jgust/SublimeCscope
8ae008f4805ad6edad7c8bf0d258eb7947da26a0
[ "MIT" ]
7
2015-05-19T15:11:11.000Z
2019-10-22T19:16:39.000Z
sublime_cscope/settings.py
jgust/SublimeCscope
8ae008f4805ad6edad7c8bf0d258eb7947da26a0
[ "MIT" ]
2
2017-03-12T16:23:06.000Z
2021-08-24T18:53:29.000Z
sublime_cscope/settings.py
jgust/SublimeCscope
8ae008f4805ad6edad7c8bf0d258eb7947da26a0
[ "MIT" ]
1
2016-03-24T09:15:39.000Z
2016-03-24T09:15:39.000Z
import sublime from ..SublimeCscope import PACKAGE_NAME SETTING_DEFAULTS = { 'index_file_extensions': [ ".c", ".cc", ".cpp", ...
35.306122
77
0.402312
0
0
0
0
0
0
0
0
334
0.193064
a50c1f5e4892b6121f54443ad132dddd426c06de
1,393
py
Python
blog.py
robotoART/multi-user-blog
4078f913df9e6b5010d7a2144cca89550a8ee533
[ "BSD-3-Clause" ]
null
null
null
blog.py
robotoART/multi-user-blog
4078f913df9e6b5010d7a2144cca89550a8ee533
[ "BSD-3-Clause" ]
null
null
null
blog.py
robotoART/multi-user-blog
4078f913df9e6b5010d7a2144cca89550a8ee533
[ "BSD-3-Clause" ]
null
null
null
import os import re from string import letters import random import hashlib import hmac import webapp2 import jinja2 from jinja2 import Environment from google.appengine.ext import db from utils.Utils import Utils from models.Comment import Comment from models.Post import Post from models.User import User from han...
26.788462
52
0.725054
0
0
0
0
0
0
0
0
231
0.165829
a50cc4e2779045bd523e797e37d15a965dda09d9
5,784
py
Python
{{cookiecutter.dir_name}}/script.py
TAMU-CPT/cc_automated_drf_template
c538f01ea90bae98ee051a6a2fd977d3dd595cde
[ "BSD-3-Clause" ]
14
2016-10-07T21:59:03.000Z
2020-03-03T17:08:49.000Z
{{cookiecutter.dir_name}}/script.py
TAMU-CPT/cc_automated_drf_template
c538f01ea90bae98ee051a6a2fd977d3dd595cde
[ "BSD-3-Clause" ]
6
2016-10-07T19:48:21.000Z
2019-03-14T12:41:50.000Z
{{cookiecutter.dir_name}}/script.py
TAMU-CPT/drf_template
c538f01ea90bae98ee051a6a2fd977d3dd595cde
[ "BSD-3-Clause" ]
3
2017-03-15T08:32:04.000Z
2018-02-05T22:09:50.000Z
import ast, _ast, subprocess, os, argparse def write_files(app_name): models = {} # parse models.py with open('%s/models.py' % app_name) as models_file: m = ast.parse(models_file.read()) for i in m.body: if type(i) == _ast.ClassDef: models[i.name] = {} ...
45.1875
158
0.510028
0
0
0
0
0
0
0
0
2,055
0.35529
a50cd6a066649f21e84260aa02f2b64721a82778
1,188
py
Python
src/jemo/plugins/base.py
jazzycamel/jemo
172a28cb9c4f75efeaf7640ce6b77d720f6e713e
[ "MIT" ]
null
null
null
src/jemo/plugins/base.py
jazzycamel/jemo
172a28cb9c4f75efeaf7640ce6b77d720f6e713e
[ "MIT" ]
null
null
null
src/jemo/plugins/base.py
jazzycamel/jemo
172a28cb9c4f75efeaf7640ce6b77d720f6e713e
[ "MIT" ]
null
null
null
from abc import ABC, abstractmethod from typing import Callable class PluginBase(ABC): def __init__(self, *, name: str, port: int) -> None: self._name = name self._port = port self._latest_action = "off" def __getattribute__(self, name: str) -> Callable: if name in ("on", "off...
24.75
73
0.588384
1,121
0.943603
0
0
344
0.289562
0
0
95
0.079966
a50efc49b461946cdc6009e1f50501249fdfce34
2,038
py
Python
search/views.py
stefanilie/hashtag
2058f2514e06401e36ab254ba42b25bbd7558f19
[ "FTL" ]
null
null
null
search/views.py
stefanilie/hashtag
2058f2514e06401e36ab254ba42b25bbd7558f19
[ "FTL" ]
null
null
null
search/views.py
stefanilie/hashtag
2058f2514e06401e36ab254ba42b25bbd7558f19
[ "FTL" ]
null
null
null
import sys from django.shortcuts import render from django.shortcuts import render_to_response from django.http import Http404, HttpResponse, HttpResponseRedirect from .forms import SearchForm from .models import Search def home(request): if request.POST: arrTweets = getTweets(request.POST['search']) print arrTwe...
29.114286
203
0.762512
0
0
0
0
0
0
0
0
804
0.394504
a50f9f33df8927431578a0e644348f580030945d
975
py
Python
BackendAPI/customuser/utils.py
silvioramalho/django-startup-rest-api
b984ee6be27990d29ab3df7cdd446bb63ee3ee34
[ "MIT" ]
9
2020-05-23T14:42:00.000Z
2022-03-04T12:21:00.000Z
BackendAPI/customuser/utils.py
silvioramalho/django-startup-rest-api
b984ee6be27990d29ab3df7cdd446bb63ee3ee34
[ "MIT" ]
6
2020-05-14T21:34:09.000Z
2021-09-22T19:01:15.000Z
BackendAPI/customuser/utils.py
silvioramalho/django-startup-rest-api
b984ee6be27990d29ab3df7cdd446bb63ee3ee34
[ "MIT" ]
1
2022-03-04T12:20:52.000Z
2022-03-04T12:20:52.000Z
from datetime import datetime from calendar import timegm from rest_framework_jwt.compat import get_username, get_username_field from rest_framework_jwt.settings import api_settings def jwt_otp_payload(user, device = None): """ Opcionalmente inclui o Device TOP no payload do JWT """ username_field = ...
28.676471
70
0.683077
0
0
0
0
0
0
0
0
191
0.195897
a5107265c6aab9b94bc89f42e8734a161ea23572
1,361
py
Python
bayesvp_try.py
ais97/bayesvp
dedf38dd7236f040301a84e5578f7202a2da07aa
[ "MIT" ]
null
null
null
bayesvp_try.py
ais97/bayesvp
dedf38dd7236f040301a84e5578f7202a2da07aa
[ "MIT" ]
null
null
null
bayesvp_try.py
ais97/bayesvp
dedf38dd7236f040301a84e5578f7202a2da07aa
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Wed Sep 15 18:36:44 2021 @author: aiswarya """ #import sys #sys.path.append('/home/aiswarya/bayesvp') from bayesvp.scripts import bvp_write_config as wc from bayesvp.scripts import bvp_process_model as pm from bayesvp.scripts import bvpfit as fit from baye...
23.877193
66
0.714916
0
0
0
0
0
0
0
0
409
0.300514
a511699f0080c5e2bd9b9726e7f19dac525f2d43
3,781
py
Python
extras/tally_results_ucf24.py
salmank255/ROADSlowFast
e939d8f79fe3eb6f3dd32e967a34530d00f45c8e
[ "Apache-2.0" ]
null
null
null
extras/tally_results_ucf24.py
salmank255/ROADSlowFast
e939d8f79fe3eb6f3dd32e967a34530d00f45c8e
[ "Apache-2.0" ]
null
null
null
extras/tally_results_ucf24.py
salmank255/ROADSlowFast
e939d8f79fe3eb6f3dd32e967a34530d00f45c8e
[ "Apache-2.0" ]
null
null
null
""" This script load and tally the result of UCF24 dataset in latex format. """ import os import json def run_exp(cmd): return os.system(cmd) if __name__ == '__main__': base = '/mnt/mercury-alpha/ucf24/cache/resnet50' modes = [['frames',['frame_actions', 'action_ness', 'action']], ['video',...
47.860759
244
0.370008
0
0
0
0
0
0
0
0
714
0.188839
a5122092a80427855c3a9e857644775cb315bcb9
322
py
Python
sayhello/settings.py
wangnalin/test
cf721108983d824433af8afb507e602237533369
[ "MIT" ]
null
null
null
sayhello/settings.py
wangnalin/test
cf721108983d824433af8afb507e602237533369
[ "MIT" ]
null
null
null
sayhello/settings.py
wangnalin/test
cf721108983d824433af8afb507e602237533369
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ author:wnl date: 2018-12-7 """ import os from sayhello import app dev_db = 'mysql+pymysql://root:root.123@192.168.100.105:3306/sayhello2' SECRET_KEY = os.getenv('SECRRET','secret string') SQLALCHEMY_TRACK_MODIFICATIONS = False SQLALCHEMY_DATABASE_URI = os.getenv('DATABASE_URI',dev_db)...
20.125
71
0.726708
0
0
0
0
0
0
0
0
161
0.5
a5140c77514670cc1d68ea51faa3667ecc7cdf73
10,325
py
Python
src/acquisition/wiki/wiki_download.py
eujing/delphi-epidata
7281a7525b20e48147049229a9faa0cb97340427
[ "MIT" ]
1
2021-12-29T04:00:21.000Z
2021-12-29T04:00:21.000Z
src/acquisition/wiki/wiki_download.py
eujing/delphi-epidata
7281a7525b20e48147049229a9faa0cb97340427
[ "MIT" ]
1
2020-07-14T15:35:15.000Z
2020-07-16T17:56:30.000Z
src/acquisition/wiki/wiki_download.py
eujing/delphi-epidata
7281a7525b20e48147049229a9faa0cb97340427
[ "MIT" ]
4
2020-09-17T13:47:02.000Z
2020-10-27T19:40:11.000Z
""" =============== === Purpose === =============== Downloads wiki access logs and stores unprocessed article counts See also: wiki.py Note: for maximum portability, this program is compatible with both Python2 and Python3 and has no external dependencies (e.g. running on AWS) ================= === Changelog === =...
35.97561
144
0.644262
0
0
0
0
0
0
0
0
3,949
0.38247
a514a8f70721796a5a67c93ce02d723310bc48b4
1,166
py
Python
aiida_fleur/tests/tools/test_io_routines.py
Tseplyaev/aiida-fleur
5de36d8b235e4b4edd908e7a0cb594112a461eb5
[ "MIT" ]
null
null
null
aiida_fleur/tests/tools/test_io_routines.py
Tseplyaev/aiida-fleur
5de36d8b235e4b4edd908e7a0cb594112a461eb5
[ "MIT" ]
null
null
null
aiida_fleur/tests/tools/test_io_routines.py
Tseplyaev/aiida-fleur
5de36d8b235e4b4edd908e7a0cb594112a461eb5
[ "MIT" ]
null
null
null
# write_results_to_file def test_write_results_to_file_interface(): """ is the basic file writter wraper working as indended """ from aiida_fleur.tools.io_routines import write_results_to_file from os.path import isfile, abspath from os import remove #import os from numpy import array...
26.5
74
0.701544
0
0
0
0
0
0
0
0
421
0.361063
a51500997a9858263339a466d1f8dbc998e0d17e
851
py
Python
app/main.py
BloomTech-Labs/family-promise-service-tracker-ds-a
1190c1f5fce55ec265a8a42b968aa1f8aea52ac6
[ "MIT" ]
4
2021-08-02T20:45:37.000Z
2021-09-03T19:42:55.000Z
app/main.py
BloomTech-Labs/family-promise-service-tracker-ds-a
1190c1f5fce55ec265a8a42b968aa1f8aea52ac6
[ "MIT" ]
22
2021-06-02T19:28:21.000Z
2021-09-15T15:09:48.000Z
app/main.py
Lambda-School-Labs/family-promise-service-tracker-ds-a
1190c1f5fce55ec265a8a42b968aa1f8aea52ac6
[ "MIT" ]
12
2021-06-02T09:30:14.000Z
2021-09-27T20:21:00.000Z
from fastapi import FastAPI from fastapi.middleware.cors import CORSMiddleware from app import db, viz, eligibility, metrics, geocode app = FastAPI( title='DS API - Family Promise', docs_url='/', version='0.39.6', ) app.include_router(db.router, tags=['Database']) app.include_router(viz.router, tags=['V...
25.029412
60
0.703878
0
0
0
0
0
0
0
0
240
0.282021
a515480d246a94b3a03edbf99bee0fcd4f9d88f2
2,033
py
Python
scripts/make_binarized_masks.py
GUIEEN/acres
ed2ab521bbec866d1588216abfce8532ce28a5e9
[ "MIT" ]
10
2019-01-03T15:31:03.000Z
2020-03-19T06:14:50.000Z
scripts/make_binarized_masks.py
GUIEEN/acres
ed2ab521bbec866d1588216abfce8532ce28a5e9
[ "MIT" ]
3
2020-05-11T12:13:15.000Z
2021-01-03T02:13:10.000Z
scripts/make_binarized_masks.py
GUIEEN/acres
ed2ab521bbec866d1588216abfce8532ce28a5e9
[ "MIT" ]
3
2020-07-26T12:58:18.000Z
2021-04-09T10:56:23.000Z
""" Take a directory of images and their segmentation masks (which only contain two classes - inside and outside) and split the inside class into black and white. Save the resulting masks. """ import argparse import os import numpy as np import cv2 def show(img): cv2.namedWindow("image", cv2.WINDOW_NORMAL) c...
34.457627
109
0.638465
0
0
0
0
0
0
0
0
489
0.240531
a515c5bdd107724d285d97362ef20d1a0f5ac85d
1,097
py
Python
tests/syngenta_digital_dta/elasticsearch/test_es_connector.py
syngenta-digital/dta-python
2f313964bdc2b733b47c874b18bd72ebf5ed8817
[ "Apache-2.0" ]
null
null
null
tests/syngenta_digital_dta/elasticsearch/test_es_connector.py
syngenta-digital/dta-python
2f313964bdc2b733b47c874b18bd72ebf5ed8817
[ "Apache-2.0" ]
62
2020-12-02T02:59:14.000Z
2021-10-01T01:08:07.000Z
tests/syngenta_digital_dta/elasticsearch/test_es_connector.py
syngenta-digital/dta-python
2f313964bdc2b733b47c874b18bd72ebf5ed8817
[ "Apache-2.0" ]
null
null
null
import uuid import unittest import warnings import json from syngenta_digital_dta.elasticsearch.es_connector import ESConnector from tests.syngenta_digital_dta.elasticsearch.mocks import MockESAdapter class ESConnectorTest(unittest.TestCase): def setUp(self, *args, **kwargs): warnings.simplefilter('ignor...
36.566667
122
0.74567
893
0.814038
0
0
0
0
0
0
61
0.055606
a51637bfb757b0164488ef03723963eb419dd5ee
6,293
py
Python
initialize.py
WiseDoge/Text-Classification-PyTorch
9371eeed6bd7ecf1d529c8f2a6c997fcde67a559
[ "MIT" ]
6
2019-08-04T13:24:24.000Z
2020-09-28T12:12:21.000Z
initialize.py
WiseDoge/Text-Classification-PyTorch
9371eeed6bd7ecf1d529c8f2a6c997fcde67a559
[ "MIT" ]
null
null
null
initialize.py
WiseDoge/Text-Classification-PyTorch
9371eeed6bd7ecf1d529c8f2a6c997fcde67a559
[ "MIT" ]
null
null
null
from typing import List, Dict from collections import defaultdict from pathlib import Path from util import save_dataset, save_word_dict, save_embedding import torch import argparse import nltk import re import logging logging.basicConfig(level=logging.INFO, format='%(asctime)s - %(name)s - %(level...
37.458333
139
0.658033
1,013
0.160973
0
0
1,086
0.172573
0
0
1,101
0.174956
a517e42fabf9ac9063a6459d9056fdf167f23154
9,422
py
Python
src/BERT_NER/utils_preprocess/anntoconll.py
philippeitis/StackOverflowNER
2a1efd8d88356de4a04e510a5ccfe85992fc8d8c
[ "MIT" ]
null
null
null
src/BERT_NER/utils_preprocess/anntoconll.py
philippeitis/StackOverflowNER
2a1efd8d88356de4a04e510a5ccfe85992fc8d8c
[ "MIT" ]
null
null
null
src/BERT_NER/utils_preprocess/anntoconll.py
philippeitis/StackOverflowNER
2a1efd8d88356de4a04e510a5ccfe85992fc8d8c
[ "MIT" ]
null
null
null
#!/usr/bin/env python # Convert text and standoff annotations into CoNLL format. import re import sys from pathlib import Path # assume script in brat tools/ directory, extend path to find sentencesplit.py sys.path.append(str(Path(__file__).parent)) sys.path.append('.') from sentencesplit import sentencebreaks_to_...
29.628931
103
0.594884
0
0
0
0
0
0
0
0
2,646
0.280832
a51b1c0fe48c6f6a0c51d7e391fb9492bd28a19a
5,509
py
Python
EfficientObjectDetection/dataset/dataloader_ete.py
JunHyungKang/SAROD_ICIP
71585951f64dc1cc22ed72900eff81f747edec77
[ "MIT" ]
null
null
null
EfficientObjectDetection/dataset/dataloader_ete.py
JunHyungKang/SAROD_ICIP
71585951f64dc1cc22ed72900eff81f747edec77
[ "MIT" ]
null
null
null
EfficientObjectDetection/dataset/dataloader_ete.py
JunHyungKang/SAROD_ICIP
71585951f64dc1cc22ed72900eff81f747edec77
[ "MIT" ]
1
2020-12-27T05:24:19.000Z
2020-12-27T05:24:19.000Z
import pandas as pd import numpy as np import warnings import os from torch.utils.data.dataset import Dataset from PIL import Image Image.MAX_IMAGE_PIXELS = None warnings.simplefilter('ignore', Image.DecompressionBombWarning) class CustomDatasetFromImages(Dataset): def __init__(self, fine_data, coarse_data, tran...
34.217391
136
0.622254
5,272
0.956979
0
0
0
0
0
0
1,617
0.29352
a51c924df2a2764415545da28cdbfc63cde5829d
6,236
py
Python
tests/test.py
angstwad/datemike
da84df48022c4067a28182e9bb53434c8f5010bc
[ "Apache-2.0" ]
8
2015-01-30T01:42:02.000Z
2019-04-05T10:50:42.000Z
tests/test.py
angstwad/datemike
da84df48022c4067a28182e9bb53434c8f5010bc
[ "Apache-2.0" ]
null
null
null
tests/test.py
angstwad/datemike
da84df48022c4067a28182e9bb53434c8f5010bc
[ "Apache-2.0" ]
3
2016-06-27T11:23:38.000Z
2018-03-05T21:37:39.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- from collections import OrderedDict import unittest import yaml from datemike import ansible, base, utils from datemike.providers import rackspace desired_task_yaml = """name: Create Cloud Server(s) rax: exact_count: true flavor: performance1-1 image: image-ubuntu-...
32.821053
78
0.59814
5,106
0.818794
0
0
0
0
0
0
1,802
0.288967
a51d4b9577b8109ecc4fe05e8b1f90f8ad9d6edf
1,100
py
Python
update_others.py
XiaogangHe/cv
814fabeb93c6302526ad0fca79587bf3fbd2a0ea
[ "CC-BY-4.0" ]
null
null
null
update_others.py
XiaogangHe/cv
814fabeb93c6302526ad0fca79587bf3fbd2a0ea
[ "CC-BY-4.0" ]
null
null
null
update_others.py
XiaogangHe/cv
814fabeb93c6302526ad0fca79587bf3fbd2a0ea
[ "CC-BY-4.0" ]
1
2020-12-20T08:02:39.000Z
2020-12-20T08:02:39.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- from __future__ import division, print_function import re import json import requests def get_number_of_citations(url): r = requests.get(url) try: r.raise_for_status() except Exception as e: print(e) return None results = re.finda...
23.913043
76
0.571818
0
0
0
0
0
0
0
0
197
0.179091
eb47b43bc4e1a81b0b221c391bba44d51529910a
1,451
py
Python
haminfo/db/models/request.py
hemna/haminfo
86db93536075999afa086fda84f10c1911af0375
[ "Apache-2.0" ]
null
null
null
haminfo/db/models/request.py
hemna/haminfo
86db93536075999afa086fda84f10c1911af0375
[ "Apache-2.0" ]
null
null
null
haminfo/db/models/request.py
hemna/haminfo
86db93536075999afa086fda84f10c1911af0375
[ "Apache-2.0" ]
null
null
null
import sqlalchemy as sa import datetime from haminfo.db.models.modelbase import ModelBase class Request(ModelBase): __tablename__ = 'request' id = sa.Column(sa.Integer, sa.Sequence('request_id_seq'), primary_key=True) created = sa.Column(sa.Date) latitude = sa.Column(sa.Float) longitude = sa.Col...
30.87234
80
0.582357
1,357
0.935217
0
0
438
0.301861
0
0
335
0.230875
eb484101042d34d5df09759540c4072f649685da
720
py
Python
src/models/entities/user.py
lokaimoma/Flask-QR-Code-Web-APP
5789753757aa1939119a799cbc6bda023ea75bbc
[ "MIT" ]
2
2022-03-05T18:54:15.000Z
2022-03-24T12:19:22.000Z
src/models/entities/user.py
lokaimoma/Flask-QR-Code-Web-APP
5789753757aa1939119a799cbc6bda023ea75bbc
[ "MIT" ]
null
null
null
src/models/entities/user.py
lokaimoma/Flask-QR-Code-Web-APP
5789753757aa1939119a799cbc6bda023ea75bbc
[ "MIT" ]
null
null
null
# Created by Kelvin_Clark on 3/3/2022, 4:58 PM from src import database as db class User(db.Model): __tablename__ = "users" username: str = db.Column(db.String(200).with_variant(db.Text, "sqlite"), unique=True, primary_key=True) email: str = db.Column(db.String(200).with_variant(db.Text, "sqlite"), unique...
34.285714
108
0.679167
636
0.883333
0
0
0
0
0
0
77
0.106944
eb49b2cbd9ad1ebc523230ba0859acde197afa9b
1,166
py
Python
Box_Plot.py
johndunne2019/pands-project
4a544be7a4074dc8a277775981b3619239c45872
[ "Apache-2.0" ]
null
null
null
Box_Plot.py
johndunne2019/pands-project
4a544be7a4074dc8a277775981b3619239c45872
[ "Apache-2.0" ]
null
null
null
Box_Plot.py
johndunne2019/pands-project
4a544be7a4074dc8a277775981b3619239c45872
[ "Apache-2.0" ]
null
null
null
# 2019-04-24 # John Dunne # Box plot of the data set # pandas box plot documentation: https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DataFrame.boxplot.html print("The box plot will appear on the screen momentarily") import matplotlib.pyplot as pl import pandas as pd # imported the libraries needed an...
61.368421
150
0.779588
0
0
0
0
0
0
0
0
1,007
0.863636
eb4a3d4d9082fcac0d03dfdabc44cb8a2905e9b2
2,677
py
Python
myteam/migrations/0001_initial.py
raymundosaraiva/fifa_myteam
3b813cdffb63449dbfca96350529f9fde17b5025
[ "MIT" ]
null
null
null
myteam/migrations/0001_initial.py
raymundosaraiva/fifa_myteam
3b813cdffb63449dbfca96350529f9fde17b5025
[ "MIT" ]
null
null
null
myteam/migrations/0001_initial.py
raymundosaraiva/fifa_myteam
3b813cdffb63449dbfca96350529f9fde17b5025
[ "MIT" ]
null
null
null
# Generated by Django 2.1.7 on 2019-06-08 21:37 from django.db import migrations, models class Migration(migrations.Migration): initial = True dependencies = [ ] operations = [ migrations.CreateModel( name='Player', fields=[ ('id', models.AutoField(a...
43.885246
114
0.525215
2,584
0.96526
0
0
0
0
0
0
471
0.175943
eb4a80f052270cf773713e6f31e00575e901cca2
3,921
py
Python
tortoise/contrib/test/__init__.py
EtzelWu/tortoise-orm
6a79c87169c10ff25b0d84bca4db24f0c0737432
[ "Apache-2.0" ]
null
null
null
tortoise/contrib/test/__init__.py
EtzelWu/tortoise-orm
6a79c87169c10ff25b0d84bca4db24f0c0737432
[ "Apache-2.0" ]
null
null
null
tortoise/contrib/test/__init__.py
EtzelWu/tortoise-orm
6a79c87169c10ff25b0d84bca4db24f0c0737432
[ "Apache-2.0" ]
null
null
null
import asyncio as _asyncio import os as _os from unittest import SkipTest, expectedFailure, skip, skipIf, skipUnless # noqa from asynctest import TestCase as _TestCase from asynctest import _fail_on from tortoise import Tortoise as _Tortoise from tortoise.backends.base.client import BaseDBAsyncClient as _BaseDBAsync...
32.139344
97
0.678908
3,100
0.790615
0
0
0
0
828
0.211171
1,692
0.431523
eb4ad53306cf5e9ef12e757a378a6da18b7e9027
1,129
py
Python
streamkinect2/common.py
rjw57/streamkinect2
967fc9855cff1f980e75f5330530d9eb6dc37e5a
[ "BSD-2-Clause" ]
3
2015-09-19T06:55:22.000Z
2018-03-31T06:51:31.000Z
streamkinect2/common.py
rjw57/streamkinect2
967fc9855cff1f980e75f5330530d9eb6dc37e5a
[ "BSD-2-Clause" ]
null
null
null
streamkinect2/common.py
rjw57/streamkinect2
967fc9855cff1f980e75f5330530d9eb6dc37e5a
[ "BSD-2-Clause" ]
null
null
null
""" Common elements for both client and server ========================================== """ import enum import json class ProtocolError(RuntimeError): """Raised when some low-level error in the network protocol has been detected. """ class EndpointType(enum.Enum): """ Enumeration of endpoints e...
23.040816
91
0.616475
616
0.545616
0
0
0
0
0
0
574
0.508415
eb4b3a57c36fb29e43b2cced38581d7861670f8e
1,639
py
Python
utils.py
josslei/Gender-Detection
51c122eddeb33caf9350a3d974b0842fdc329527
[ "BSD-3-Clause" ]
null
null
null
utils.py
josslei/Gender-Detection
51c122eddeb33caf9350a3d974b0842fdc329527
[ "BSD-3-Clause" ]
null
null
null
utils.py
josslei/Gender-Detection
51c122eddeb33caf9350a3d974b0842fdc329527
[ "BSD-3-Clause" ]
null
null
null
import torch import torchvision.datasets as datasets import torchvision.transforms as transforms import os import sys def export_sample_images(amount:int, export_dir:str, dataset, shuffle=True): os.makedirs(export_dir, exist_ok=True) loader = torch.utils.data.DataLoader(dataset=dataset, batch_size=amount, shuf...
34.145833
99
0.633923
0
0
0
0
0
0
0
0
207
0.126297
eb4bd3ef93523276a029ce74696a58d6dbda7df8
1,791
py
Python
tests/infrastructure/test_hashing_clients.py
enchainte/enchainte-sdk-py
d7e6803cb941ae929bca9bb00584aa5b4853689a
[ "MIT" ]
1
2021-11-21T22:02:49.000Z
2021-11-21T22:02:49.000Z
tests/infrastructure/test_hashing_clients.py
enchainte/enchainte-sdk-py
d7e6803cb941ae929bca9bb00584aa5b4853689a
[ "MIT" ]
1
2021-09-16T20:19:04.000Z
2021-09-16T20:19:04.000Z
tests/infrastructure/test_hashing_clients.py
enchainte/enchainte-sdk-py
d7e6803cb941ae929bca9bb00584aa5b4853689a
[ "MIT" ]
1
2021-12-10T10:22:30.000Z
2021-12-10T10:22:30.000Z
from unittest import TestCase from bloock.infrastructure.hashing.blake2b import Blake2b from bloock.infrastructure.hashing.keccak import Keccak class Blake2bTestCase(TestCase): def setUp(self): self.blake = Blake2b() def test_blake_generate_hash_64_zeros_string(self): data = b'00000000000000...
38.106383
86
0.731993
1,641
0.916248
0
0
0
0
0
0
668
0.372976
eb4c777d1ec0e0f2de5615f741bc3013f401e213
7,395
py
Python
simscale_sdk/models/time_step_animation_output_settings_all_of.py
SimScaleGmbH/simscale-python-sdk
34c881ca0be87e2b0bb315a9fee1d73f0da61e78
[ "MIT" ]
8
2021-01-22T13:41:03.000Z
2022-01-03T09:00:10.000Z
simscale_sdk/models/time_step_animation_output_settings_all_of.py
eljoelopez/simscale-python-sdk
189f1337b2ab40feed123111ddead0cdecf83c93
[ "MIT" ]
null
null
null
simscale_sdk/models/time_step_animation_output_settings_all_of.py
eljoelopez/simscale-python-sdk
189f1337b2ab40feed123111ddead0cdecf83c93
[ "MIT" ]
3
2021-03-18T15:52:52.000Z
2022-01-03T08:59:30.000Z
# coding: utf-8 """ SimScale API The version of the OpenAPI document: 0.0.0 Generated by: https://openapi-generator.tech """ import pprint import re # noqa: F401 import six from simscale_sdk.configuration import Configuration class TimeStepAnimationOutputSettingsAllOf(object): """NOTE: This cla...
35.214286
142
0.640838
7,147
0.966464
0
0
4,061
0.549155
0
0
3,377
0.45666
eb4c825a43f6f758f6c0778489d3efdfec3dabf7
1,143
py
Python
metastore/configurations/repository.py
metastore-developers/metastore
56397e5c81f6b6b4b408b458bcfe09191945cff2
[ "BSD-3-Clause" ]
null
null
null
metastore/configurations/repository.py
metastore-developers/metastore
56397e5c81f6b6b4b408b458bcfe09191945cff2
[ "BSD-3-Clause" ]
null
null
null
metastore/configurations/repository.py
metastore-developers/metastore
56397e5c81f6b6b4b408b458bcfe09191945cff2
[ "BSD-3-Clause" ]
null
null
null
''' Repository configuration model. ''' from typing import Dict, List, Literal, Optional from .. import types from .configuration import Configuration class RepositoryConfiguration(Configuration): ''' Repository configuration model. ''' #: Configuration type. type: Optional[Literal['repository'...
25.4
60
0.695538
941
0.823272
0
0
0
0
0
0
439
0.384077
eb4d61456ea19420d3829d735a469004c45d21d0
970
py
Python
python/277.py
kylekanos/project-euler-1
af7089356a4cea90f8ef331cfdc65e696def6140
[ "BSD-2-Clause-FreeBSD" ]
null
null
null
python/277.py
kylekanos/project-euler-1
af7089356a4cea90f8ef331cfdc65e696def6140
[ "BSD-2-Clause-FreeBSD" ]
null
null
null
python/277.py
kylekanos/project-euler-1
af7089356a4cea90f8ef331cfdc65e696def6140
[ "BSD-2-Clause-FreeBSD" ]
1
2019-09-17T00:55:58.000Z
2019-09-17T00:55:58.000Z
#!/usr/bin/env python def modpow(a,n,m): ret=1 while n: if n&1: ret=(ret*a)%m n>>=1 a = (a*a)%m return ret def check(a1): checkstr='' for i in xrange(len(moves)): if a1%3==0: checkstr+='D' a1/=3 elif a1%3==1: checkstr+='U'...
19.4
61
0.43299
0
0
0
0
0
0
0
0
262
0.270103
eb4eec18185b7f1ef93165dd8d50086af9250306
4,708
py
Python
waveletcodec/wave.py
zenathark/jg.waveletcodec
7994dd18ef5472e7e4d6447062cf4dc3c2f6463f
[ "MIT" ]
1
2017-05-14T01:42:18.000Z
2017-05-14T01:42:18.000Z
waveletcodec/wave.py
zenathark/jg.waveletcodec
7994dd18ef5472e7e4d6447062cf4dc3c2f6463f
[ "MIT" ]
null
null
null
waveletcodec/wave.py
zenathark/jg.waveletcodec
7994dd18ef5472e7e4d6447062cf4dc3c2f6463f
[ "MIT" ]
null
null
null
"""Represent a Wavelet Coefficient Set. .. module::wave :platform: Unix, Windows .. modelauthor:: Juan C Galan-Hernandez <jcgalanh@gmail.com> """ import numpy as np import waveletcodec.tools as tools import waveletcodec.lwt as lwt import cv2 import math #Constant Section CDF97 = 1 #End class WCSet(np.ndarray...
26.301676
79
0.591334
2,455
0.521453
0
0
0
0
0
0
2,781
0.590697
eb500447316c707e8ab27d9672035cbf09dc6dee
972
py
Python
Easy/Paint_Cost.py
vinayvinu500/Sololearn
82ea8c41ae52c265cc37b8bf126ea3cfaf2c5500
[ "MIT" ]
null
null
null
Easy/Paint_Cost.py
vinayvinu500/Sololearn
82ea8c41ae52c265cc37b8bf126ea3cfaf2c5500
[ "MIT" ]
null
null
null
Easy/Paint_Cost.py
vinayvinu500/Sololearn
82ea8c41ae52c265cc37b8bf126ea3cfaf2c5500
[ "MIT" ]
null
null
null
""" Paint costs You are getting ready to paint a piece of art. The canvas and brushes that you want to use will cost 40.00. Each color of paint that you buy is an additional 5.00. Determine how much money you will need based on the number of colors that you want to buy if tax at this store is 10%. Task Given the to...
33.517241
282
0.748971
0
0
0
0
0
0
0
0
886
0.911523
eb5060a785cfcf182925ba2ff985ffd151afd8b7
1,598
py
Python
pr2roc/pr_curve.py
ameya98/roc2pr
ab19d7552e2e9ae32ca00a1be4a17b29a3f915fa
[ "MIT" ]
1
2020-09-08T14:51:48.000Z
2020-09-08T14:51:48.000Z
pr2roc/pr_curve.py
ameya98/pr2roc
ab19d7552e2e9ae32ca00a1be4a17b29a3f915fa
[ "MIT" ]
null
null
null
pr2roc/pr_curve.py
ameya98/pr2roc
ab19d7552e2e9ae32ca00a1be4a17b29a3f915fa
[ "MIT" ]
null
null
null
from __future__ import division from .curve import Curve from numpy import min, max, seterr seterr(all='raise') class PRCurve(Curve): def __init__(self, points, pos_neg_ratio, label=None): Curve.__init__(self, points, label) self.pos_neg_ratio = pos_neg_ratio if max([self.x_vals, self.y_v...
35.511111
110
0.615144
1,484
0.928661
0
0
0
0
0
0
223
0.139549
eb50a4e886b2a04a462c9218f1a0436f4b1e8244
3,384
py
Python
blg604ehw2/utils.py
cbekar/DRL_HW2
5ecb12ee1d5d545d5059afb4cf578881acb1f00e
[ "MIT" ]
null
null
null
blg604ehw2/utils.py
cbekar/DRL_HW2
5ecb12ee1d5d545d5059afb4cf578881acb1f00e
[ "MIT" ]
null
null
null
blg604ehw2/utils.py
cbekar/DRL_HW2
5ecb12ee1d5d545d5059afb4cf578881acb1f00e
[ "MIT" ]
null
null
null
""" Utilities for homework 2. Function "log_progress" is adapted from: https://github.com/kuk/log-progress """ import matplotlib.pyplot as plt import numpy as np import torch from ipywidgets import IntProgress, HTML, VBox from IPython.display import display from blg604ehw2.atari_wrapper import LazyFrames de...
31.333333
76
0.589835
1,129
0.333629
0
0
0
0
0
0
886
0.26182
eb51353e72618f1a090e46e7c1c65e0cc24ef776
17,982
py
Python
tests/lib/bes/archive/test_archive_util.py
reconstruir/bes
82ff54b2dadcaef6849d7de424787f1dedace85c
[ "Apache-2.0" ]
null
null
null
tests/lib/bes/archive/test_archive_util.py
reconstruir/bes
82ff54b2dadcaef6849d7de424787f1dedace85c
[ "Apache-2.0" ]
null
null
null
tests/lib/bes/archive/test_archive_util.py
reconstruir/bes
82ff54b2dadcaef6849d7de424787f1dedace85c
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python #-*- coding:utf-8; mode:python; indent-tabs-mode: nil; c-basic-offset: 2; tab-width: 2 -*- from bes.testing.unit_test import unit_test from bes.archive.archive_util import archive_util from bes.archive.archiver import archiver from bes.archive.temp_archive import temp_archive class test_archive_...
49.401099
108
0.638639
17,629
0.980369
0
0
0
0
0
0
6,610
0.36759
eb51468dffd54037005f28c7423bde948db98210
3,625
py
Python
yaleclient/cli.py
anderselton/yale-client
2c2ddd46bfada9ea0ec97022ec4bc46c8e062558
[ "Apache-2.0" ]
null
null
null
yaleclient/cli.py
anderselton/yale-client
2c2ddd46bfada9ea0ec97022ec4bc46c8e062558
[ "Apache-2.0" ]
null
null
null
yaleclient/cli.py
anderselton/yale-client
2c2ddd46bfada9ea0ec97022ec4bc46c8e062558
[ "Apache-2.0" ]
1
2021-04-16T16:43:23.000Z
2021-04-16T16:43:23.000Z
# -*- coding: utf-8 -*- import argparse import os from .client import YaleClient class EnvDefault(argparse.Action): def __init__(self, envvar, help, required=True, default=None, **kwargs): if envvar: if envvar in os.environ: value_default = os.getenv(key=envvar, default=default...
40.277778
120
0.589517
723
0.199448
0
0
0
0
0
0
629
0.173517
eb5195c7f53f58aed03e892f82a003ed8c0cede7
1,376
py
Python
backend/api/filters/filters.py
grallage/course-selection-system
d7db267befe8c1d91b9d1bc335397e3087466c96
[ "MIT" ]
null
null
null
backend/api/filters/filters.py
grallage/course-selection-system
d7db267befe8c1d91b9d1bc335397e3087466c96
[ "MIT" ]
null
null
null
backend/api/filters/filters.py
grallage/course-selection-system
d7db267befe8c1d91b9d1bc335397e3087466c96
[ "MIT" ]
null
null
null
from .. import models from django_filters import rest_framework as filters class MajorFilterSet(filters.FilterSet): name = filters.CharFilter(field_name="name", lookup_expr="contains") description = filters.CharFilter(field_name="description", lookup_expr="contains") id = filters.NumberFilter(field_name="...
32.761905
88
0.711483
1,289
0.936773
0
0
0
0
0
0
275
0.199855
eb51d6d53256cba70fc82a414f813c5e24351542
2,189
py
Python
proposals/management/commands/get_statistics.py
UiL-OTS-labs/etcl
a22df7ff78620b704a500354fb218fbe9bcabf5f
[ "MIT" ]
2
2017-04-22T11:07:13.000Z
2018-03-02T12:23:24.000Z
proposals/management/commands/get_statistics.py
UiL-OTS-labs/etcl
a22df7ff78620b704a500354fb218fbe9bcabf5f
[ "MIT" ]
6
2017-07-24T09:59:13.000Z
2019-04-01T15:15:57.000Z
proposals/management/commands/get_statistics.py
UiL-OTS-labs/etcl
a22df7ff78620b704a500354fb218fbe9bcabf5f
[ "MIT" ]
null
null
null
from django.contrib.auth.models import Group from django.core.management.base import BaseCommand from django.conf import settings from django.views.i18n import set_language from proposals.utils.statistics_utils import get_average_turnaround_time, \ get_qs_for_long_route_reviews, get_qs_for_short_route_reviews, \ ...
33.166667
77
0.600731
1,648
0.752855
0
0
0
0
0
0
212
0.096848
eb51ff6b9107cee84e763a4b3d50eade4083e26c
4,299
py
Python
src/latest.py
rharish101/dilbert-viewer-py
07492822b74e5b9242f47bdf756e147bf792e5c8
[ "MIT" ]
5
2018-12-08T12:06:29.000Z
2022-01-23T14:25:51.000Z
src/latest.py
rharish101/dilbert-viewer-py
07492822b74e5b9242f47bdf756e147bf792e5c8
[ "MIT" ]
3
2021-11-01T18:19:11.000Z
2021-11-01T18:23:08.000Z
src/latest.py
rharish101/dilbert-viewer-py
07492822b74e5b9242f47bdf756e147bf792e5c8
[ "MIT" ]
1
2020-05-16T19:16:00.000Z
2020-05-16T19:16:00.000Z
"""Scraper to get info on the latest Dilbert comic.""" from datetime import timedelta from typing import Optional from constants import LATEST_DATE_REFRESH, SRC_PREFIX from scraper import Scraper, ScrapingException from utils import curr_date, date_to_str, str_to_date class LatestDateScraper(Scraper[str, None]): ...
37.060345
79
0.586183
4,026
0.936497
0
0
0
0
3,676
0.855083
2,073
0.482205
eb53bbfae8b29bdd3c9940753f30c643697fe9d2
742
py
Python
tests/use_cases/test_fetch_playlists.py
eeng/montag
8362c4bc6621e23d3b9b43990f9cf28a9e1c1c8a
[ "MIT" ]
null
null
null
tests/use_cases/test_fetch_playlists.py
eeng/montag
8362c4bc6621e23d3b9b43990f9cf28a9e1c1c8a
[ "MIT" ]
null
null
null
tests/use_cases/test_fetch_playlists.py
eeng/montag
8362c4bc6621e23d3b9b43990f9cf28a9e1c1c8a
[ "MIT" ]
null
null
null
from montag.domain.entities import Provider from montag.use_cases.fetch_playlists import FetchPlaylists from montag.use_cases.support import Failure, Success from tests import factory def test_fetch_playlists(repos, spotify_repo): expected_playlists = factory.playlists(2) spotify_repo.find_playlists.return_va...
32.26087
68
0.801887
0
0
0
0
0
0
0
0
28
0.037736
eb548fb8cf15eb3f8798883ce250fd08789baca2
4,012
py
Python
tests/xmrswap/test_other.py
tecnovert/xmrswap
ad2983a4df03184453ff680c17602497acc75a87
[ "MIT" ]
2
2020-09-21T17:33:23.000Z
2020-10-03T08:54:01.000Z
tests/xmrswap/test_other.py
tecnovert/xmrswap
ad2983a4df03184453ff680c17602497acc75a87
[ "MIT" ]
2
2020-10-03T09:18:48.000Z
2020-10-13T19:58:34.000Z
tests/xmrswap/test_other.py
tecnovert/xmrswap
ad2983a4df03184453ff680c17602497acc75a87
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # Copyright (c) 2020 tecnovert # Distributed under the MIT software license, see the accompanying # file LICENSE.txt or http://www.opensource.org/licenses/mit-license.php. import unittest from xmrswap.interface_btc import ( testBTCInterface ) from xmrswap.util import...
33.714286
89
0.583998
3,424
0.85344
0
0
0
0
0
0
843
0.21012
eb57f9bf54428ecebf85880e23368e3618741a38
243
py
Python
V2RaycSpider1025/main.py
caicai166/V2RayCloudSpider
b263490407814c9e67e34fcce821af01a22405f1
[ "MIT" ]
4
2020-11-18T00:25:54.000Z
2022-03-14T11:54:13.000Z
V2RaycSpider1025/main.py
caicai166/V2RayCloudSpider
b263490407814c9e67e34fcce821af01a22405f1
[ "MIT" ]
null
null
null
V2RaycSpider1025/main.py
caicai166/V2RayCloudSpider
b263490407814c9e67e34fcce821af01a22405f1
[ "MIT" ]
3
2021-01-03T03:16:29.000Z
2021-06-02T04:09:59.000Z
from Panel.master_panel import * """欢迎使用V2Ray云彩姬""" if __name__ == '__main__': V2Rayc = V2RaycSpider_Master_Panel() try: V2Rayc.home_menu() except Exception as e: V2Rayc.debug(e) finally: V2Rayc.kill()
20.25
40
0.62963
0
0
0
0
0
0
0
0
42
0.163424
eb58c8c60f85a4934a55d96cc31bb7f46a9c0eae
289
py
Python
apps/toppage/urls.py
shimizukawa/django-multiple-type-user-auth
8fba1670ae2c5e7add9d9bfe39997c047f848582
[ "Apache-2.0" ]
29
2020-01-31T08:24:18.000Z
2022-03-24T18:39:11.000Z
apps/toppage/urls.py
shimizukawa/django-multiple-type-user-auth
8fba1670ae2c5e7add9d9bfe39997c047f848582
[ "Apache-2.0" ]
2
2021-03-18T21:30:27.000Z
2021-04-05T20:45:48.000Z
apps/toppage/urls.py
shimizukawa/django-multiple-type-user-auth
8fba1670ae2c5e7add9d9bfe39997c047f848582
[ "Apache-2.0" ]
5
2021-05-12T19:46:46.000Z
2022-03-03T16:06:41.000Z
from django.urls import path from .views import index, supporter_index, customer_index app_name = 'toppage' urlpatterns = [ path('', index, name='index'), path('supporter/', supporter_index, name='supporter_index'), path('customer/', customer_index, name='customer_index'), ]
28.9
64
0.719723
0
0
0
0
0
0
0
0
74
0.256055
eb598dc417f9c3b646b630ac18fa21625cf00654
443
py
Python
forest_calculations.py
mpolinski/python-forest
859238ab6a2e05e3479eda5d131f59b26a1f1a22
[ "MIT" ]
null
null
null
forest_calculations.py
mpolinski/python-forest
859238ab6a2e05e3479eda5d131f59b26a1f1a22
[ "MIT" ]
null
null
null
forest_calculations.py
mpolinski/python-forest
859238ab6a2e05e3479eda5d131f59b26a1f1a22
[ "MIT" ]
null
null
null
from forest_constants import (LEAFY, CONIFEROUS) def get_forest_dimensions(forest): rows_num = len(forest) cols_num = 0 if rows_num: cols_num = len(forest[0]) return rows_num, cols_num def get_tree_counts(forest): leafy_count = 0 coniferous_count = 0 for row in forest: l...
21.095238
49
0.688488
0
0
0
0
0
0
0
0
0
0
eb59a61061f97223ab1d4a63d1d6e26c9e3f3922
64
py
Python
tests/helpers/test_model_interface.py
sebastian-lapuschkin/Quantus
c3b8a9fb2018f34bd89ba38efa2b2b8c38128b3f
[ "MIT" ]
null
null
null
tests/helpers/test_model_interface.py
sebastian-lapuschkin/Quantus
c3b8a9fb2018f34bd89ba38efa2b2b8c38128b3f
[ "MIT" ]
null
null
null
tests/helpers/test_model_interface.py
sebastian-lapuschkin/Quantus
c3b8a9fb2018f34bd89ba38efa2b2b8c38128b3f
[ "MIT" ]
null
null
null
"""No identified need to test model interface functionality."""
32
63
0.765625
0
0
0
0
0
0
0
0
63
0.984375
eb5a1f1e207966227e8c201ab765ed8ba7bfef1e
1,923
py
Python
blocks/utils.py
vogonyo/SImulator
bd05c5bda376d9463b68b1b386e17be8ca393ea3
[ "MIT" ]
76
2016-09-16T21:04:56.000Z
2021-11-09T03:29:37.000Z
blocks/utils.py
vogonyo/SImulator
bd05c5bda376d9463b68b1b386e17be8ca393ea3
[ "MIT" ]
4
2019-01-06T08:53:29.000Z
2019-01-25T09:38:09.000Z
blocks/utils.py
vogonyo/SImulator
bd05c5bda376d9463b68b1b386e17be8ca393ea3
[ "MIT" ]
22
2016-09-20T11:06:02.000Z
2021-07-28T03:06:42.000Z
import sys import h5py import yaml import numpy as np from fuel.datasets import H5PYDataset from fuel.streams import DataStream from fuel.schemes import SequentialScheme, ShuffledScheme from fuel.transformers import Mapping from blocks.extensions import saveload, predicates from blocks.extensions.training import TrackT...
34.339286
97
0.73791
169
0.087884
0
0
209
0.108684
0
0
217
0.112845
eb5c1e3cdc51524fbf91bb29a9b75350d7e28939
13,580
py
Python
tests/test_locators.py
msabramo/distlib
8c201484821e7cdfd52c560eac98b45439402f39
[ "PSF-2.0" ]
null
null
null
tests/test_locators.py
msabramo/distlib
8c201484821e7cdfd52c560eac98b45439402f39
[ "PSF-2.0" ]
null
null
null
tests/test_locators.py
msabramo/distlib
8c201484821e7cdfd52c560eac98b45439402f39
[ "PSF-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # # Copyright (C) 2012-2013 Vinay Sajip. # Licensed to the Python Software Foundation under a contributor agreement. # See LICENSE.txt and CONTRIBUTORS.txt. # from __future__ import unicode_literals import os import sys from compat import unittest from distlib.compat import url2pathname, urlpa...
42.704403
82
0.583726
12,385
0.912003
0
0
4,662
0.343299
0
0
2,976
0.219146
eb5ccd73b62ac958c2eaef0bb0a5f829cbe6ee69
6,946
py
Python
aws_s3/main.py
mayurdhamecha-crest/ta_cloud_exchange_plugins
8d64c92909f28bcb2067587ec3361499de5d5723
[ "BSD-3-Clause" ]
null
null
null
aws_s3/main.py
mayurdhamecha-crest/ta_cloud_exchange_plugins
8d64c92909f28bcb2067587ec3361499de5d5723
[ "BSD-3-Clause" ]
null
null
null
aws_s3/main.py
mayurdhamecha-crest/ta_cloud_exchange_plugins
8d64c92909f28bcb2067587ec3361499de5d5723
[ "BSD-3-Clause" ]
null
null
null
"""AWS S3 Plugin.""" import os from typing import List from tempfile import NamedTemporaryFile from netskope.integrations.cls.plugin_base import ( PluginBase, ValidationResult, PushResult, ) from .utils.aws_s3_validator import ( AWSS3Validator, ) from .utils.aws_s3_client import AWSS3Client class AWS...
36.366492
100
0.565073
6,634
0.955082
0
0
0
0
0
0
2,522
0.363087
eb5d8a81de7fb8524c15daf24c0d23dffb316345
160
py
Python
database/tests/open_alchemy/package_database/test_models/spec/conftest.py
open-alchemy/OpenAlchemyPackage
8bf0ed62ed7f6c5015f1bf1c4658dc353395fe9b
[ "Apache-2.0" ]
null
null
null
database/tests/open_alchemy/package_database/test_models/spec/conftest.py
open-alchemy/OpenAlchemyPackage
8bf0ed62ed7f6c5015f1bf1c4658dc353395fe9b
[ "Apache-2.0" ]
79
2020-11-28T04:02:25.000Z
2021-01-06T08:52:30.000Z
database/tests/open_alchemy/package_database/test_models/spec/conftest.py
open-alchemy/Package
8bf0ed62ed7f6c5015f1bf1c4658dc353395fe9b
[ "Apache-2.0" ]
null
null
null
"""Database fixtures.""" import pytest @pytest.fixture(autouse=True) def _auto_clean_specs_table(_clean_specs_table): """Autouses _clean_specs_table."""
17.777778
48
0.7625
0
0
0
0
117
0.73125
0
0
58
0.3625
eb5f27f70e1b8021f877eebe2821bbbc7ca9a3c6
2,626
py
Python
cdr_plugin_folder_to_folder/api/Server.py
lucia15/cdr-plugin-folder-to-folder
6dc245086d613a07e0fc63057d1ca1da965feccd
[ "Apache-2.0" ]
null
null
null
cdr_plugin_folder_to_folder/api/Server.py
lucia15/cdr-plugin-folder-to-folder
6dc245086d613a07e0fc63057d1ca1da965feccd
[ "Apache-2.0" ]
null
null
null
cdr_plugin_folder_to_folder/api/Server.py
lucia15/cdr-plugin-folder-to-folder
6dc245086d613a07e0fc63057d1ca1da965feccd
[ "Apache-2.0" ]
1
2022-02-21T15:48:51.000Z
2022-02-21T15:48:51.000Z
import logging import uvicorn from fastapi_offline import FastAPIOffline as FastAPI #from cdr_plugin_folder_to_folder.api.users import router from osbot_utils.utils.Misc import to_int from cdr_plugin_folder_to_folder.api.routes.Processing import router as router_processing from cdr_plugin_folder_to_folder.api.routes...
44.508475
162
0.686976
1,273
0.484768
0
0
0
0
0
0
859
0.327113
eb6026d99e12af7beda1b40e5de9c9f9ef6b3948
751
py
Python
09 Evaluate the Performance of Machine Learning Algorithms with Resampling/shuffle_split.py
IshmaelAsabere/Machine_Learning-Various-Topics
2c663ab73e2631522dac0fa1ec49042aa2088da4
[ "MIT" ]
null
null
null
09 Evaluate the Performance of Machine Learning Algorithms with Resampling/shuffle_split.py
IshmaelAsabere/Machine_Learning-Various-Topics
2c663ab73e2631522dac0fa1ec49042aa2088da4
[ "MIT" ]
null
null
null
09 Evaluate the Performance of Machine Learning Algorithms with Resampling/shuffle_split.py
IshmaelAsabere/Machine_Learning-Various-Topics
2c663ab73e2631522dac0fa1ec49042aa2088da4
[ "MIT" ]
null
null
null
# Evaluate using Shuffle Split Cross Validation from pandas import read_csv from sklearn.model_selection import ShuffleSplit from sklearn.model_selection import cross_val_score from sklearn.linear_model import LogisticRegression filename = 'pima-indians-diabetes.data.csv' names = ['preg', 'plas', 'pres', 'skin', 'test'...
41.722222
80
0.747004
0
0
0
0
0
0
0
0
171
0.227696
eb61d5d7e4bf28a8a1ca4a73ac750956135f0ec5
4,178
py
Python
tests/test_s.py
Tygs/ww
6a4b85141c9b74026abe8f3fa9bc7021f3c99fd4
[ "MIT" ]
15
2016-10-15T10:15:08.000Z
2021-04-06T08:31:02.000Z
tests/test_s.py
Tygs/ww
6a4b85141c9b74026abe8f3fa9bc7021f3c99fd4
[ "MIT" ]
7
2016-10-14T08:53:29.000Z
2016-11-09T23:43:31.000Z
tests/test_s.py
Tygs/ww
6a4b85141c9b74026abe8f3fa9bc7021f3c99fd4
[ "MIT" ]
3
2016-10-13T11:44:46.000Z
2016-10-14T08:58:03.000Z
# coding: utf-8 from __future__ import ( unicode_literals, division, print_function, absolute_import ) import re import pytest from ww import s, g, f def test_lshift(): res = s >> """ This is a long text And it's not indented """ assert isinstance(res, s) s == "This is a long text\nA...
23.60452
78
0.514361
0
0
0
0
0
0
0
0
1,055
0.252272
eb61d97f58614f8c6747182079791a3edd418075
566
py
Python
sherlock/codelib/system_function/implements.py
Luavis/sherlock.py
6974244c5ddb2f5e41aea2fbc7f913917fd15532
[ "MIT" ]
55
2017-02-12T08:22:44.000Z
2022-01-08T12:34:53.000Z
sherlock/codelib/system_function/implements.py
Ronlin1/sherlock.py
6974244c5ddb2f5e41aea2fbc7f913917fd15532
[ "MIT" ]
3
2017-02-24T16:23:40.000Z
2022-02-05T19:54:26.000Z
sherlock/codelib/system_function/implements.py
Ronlin1/sherlock.py
6974244c5ddb2f5e41aea2fbc7f913917fd15532
[ "MIT" ]
7
2017-01-17T17:34:59.000Z
2022-02-15T15:23:17.000Z
import ast from sherlock.codelib.analyzer.variable import Type from sherlock.codelib.system_function import system_function @system_function('range', Type.LIST, Type.NUMBER, Type.NUMBER) def system_range(g, start, end): return '$(seq %s $(( %s - 1 )))' % (g.dispatch(start), g.dispatch(end)) @system_function('pri...
33.294118
75
0.706714
0
0
0
0
435
0.768551
0
0
63
0.111307
eb61e320d9b1fecbed0efae579b389e9a7594789
370
py
Python
drf_localize/commons/errors.py
ebs-integrator/DRF-Localize
85201157027770ff3859842f04ce8a3e302ab072
[ "MIT" ]
3
2022-03-10T12:34:18.000Z
2022-03-14T08:52:22.000Z
drf_localize/commons/errors.py
ebs-integrator/drf-localize
85201157027770ff3859842f04ce8a3e302ab072
[ "MIT" ]
null
null
null
drf_localize/commons/errors.py
ebs-integrator/drf-localize
85201157027770ff3859842f04ce8a3e302ab072
[ "MIT" ]
null
null
null
from rest_framework.exceptions import APIException from django.utils.translation import ugettext_lazy as _ from rest_framework.status import HTTP_423_LOCKED # Create your errors here. class LockedError(APIException): status_code = HTTP_423_LOCKED default_detail = _('You do not have permission to perform this...
30.833333
76
0.805405
182
0.491892
0
0
0
0
0
0
97
0.262162
eb62f7a6a5283024ec8152b88db4515eb8b7c676
1,373
py
Python
xos/tosca/resources/accessdevice.py
pan2za/olt
54f110f81849b6393f3055755876cd01b4c6dac5
[ "Apache-2.0" ]
null
null
null
xos/tosca/resources/accessdevice.py
pan2za/olt
54f110f81849b6393f3055755876cd01b4c6dac5
[ "Apache-2.0" ]
null
null
null
xos/tosca/resources/accessdevice.py
pan2za/olt
54f110f81849b6393f3055755876cd01b4c6dac5
[ "Apache-2.0" ]
null
null
null
from services.volt.models import AccessDevice, VOLTDevice from xosresource import XOSResource class XOSAccessDevice(XOSResource): provides = "tosca.nodes.AccessDevice" xos_model = AccessDevice copyin_props = ["uplink", "vlan"] name_field = None def get_xos_args(self, throw_exception=True): ...
40.382353
134
0.697014
1,276
0.929352
0
0
0
0
0
0
278
0.202476
eb63e2b82821e62051f86e67479c30cbd653b398
587
py
Python
1_Einstieg/passengers/naiveForecast.py
DavidStahl97/Predictive-Analytics
c607ef2a5fc2b6654122b0b5ef90cb1a23f88eb0
[ "MIT" ]
null
null
null
1_Einstieg/passengers/naiveForecast.py
DavidStahl97/Predictive-Analytics
c607ef2a5fc2b6654122b0b5ef90cb1a23f88eb0
[ "MIT" ]
null
null
null
1_Einstieg/passengers/naiveForecast.py
DavidStahl97/Predictive-Analytics
c607ef2a5fc2b6654122b0b5ef90cb1a23f88eb0
[ "MIT" ]
null
null
null
import pandas as pd import math from matplotlib import pyplot ts = pd.read_csv("airline-passengers.csv", header=0, index_col=0) nOfPassengers = ts["Passengers"] values = nOfPassengers.values.tolist() forecast = [math.nan] for i in range(0, len(values) - 1): forecast.append(values[i]) pyplot.plot(values) pyplot...
17.264706
65
0.664395
0
0
0
0
0
0
0
0
36
0.061329
eb64352202a6b429c03980e77f840c5767dfc418
513
py
Python
antalla/migrations/versions/bfa53193d3bf_create_exchange_table.py
sambacha/antalla
241f49058e4295aa9f5bc62efe517388d9256520
[ "MIT" ]
null
null
null
antalla/migrations/versions/bfa53193d3bf_create_exchange_table.py
sambacha/antalla
241f49058e4295aa9f5bc62efe517388d9256520
[ "MIT" ]
null
null
null
antalla/migrations/versions/bfa53193d3bf_create_exchange_table.py
sambacha/antalla
241f49058e4295aa9f5bc62efe517388d9256520
[ "MIT" ]
null
null
null
"""create exchange table Revision ID: bfa53193d3bf Revises: b97a89b20fa2 Create Date: 2019-09-22 01:17:06.735174 """ from alembic import op import sqlalchemy as sa # revision identifiers, used by Alembic. revision = 'bfa53193d3bf' down_revision = 'b97a89b20fa2' branch_labels = None depends_on = None def upgrade()...
17.689655
54
0.695906
0
0
0
0
0
0
0
0
218
0.424951
eb6486b781e8bb7e961d09b57c4d80fc18e300da
2,831
py
Python
rpeak_seg_simple_v1.0.py
ziyi-bear/ECG-ML-DL-Algorithm-Python
e1cc28c09fcd9330470b30c240ab7fb331c8ea0c
[ "Apache-2.0" ]
180
2018-05-18T12:18:53.000Z
2022-03-30T11:02:48.000Z
rpeak_seg_simple_v1.0.py
Aiwiscal/ECG-ML-DL-Algorithm-Python-version
23b24a965fdede3552d33943a26ad824a8c03325
[ "Apache-2.0" ]
null
null
null
rpeak_seg_simple_v1.0.py
Aiwiscal/ECG-ML-DL-Algorithm-Python-version
23b24a965fdede3552d33943a26ad824a8c03325
[ "Apache-2.0" ]
61
2018-06-08T08:19:34.000Z
2022-03-18T10:34:02.000Z
#!/usr/bin/python # -*- coding:utf-8 -*- import sys import time import logging import numpy as np from biosppy.signals import ecg from biosppy.storage import load_txt import matplotlib.pyplot as plt logging.basicConfig(level = logging.DEBUG,format = '%(asctime)s - %(name)s - %(levelname)s - %(message)s') ...
36.766234
107
0.657718
0
0
0
0
0
0
0
0
1,333
0.405044
eb6591f825c57a68f6992dbbedf4b1b854a25935
153
py
Python
book_store/book_outlet/apps.py
goulartdev/udemy-django-course
f39ab36aacdf47d19f8c286c317cc54d8358dadc
[ "MIT" ]
null
null
null
book_store/book_outlet/apps.py
goulartdev/udemy-django-course
f39ab36aacdf47d19f8c286c317cc54d8358dadc
[ "MIT" ]
null
null
null
book_store/book_outlet/apps.py
goulartdev/udemy-django-course
f39ab36aacdf47d19f8c286c317cc54d8358dadc
[ "MIT" ]
null
null
null
from django.apps import AppConfig class BookOutletConfig(AppConfig): default_auto_field = 'django.db.models.BigAutoField' name = 'book_outlet'
21.857143
56
0.771242
116
0.75817
0
0
0
0
0
0
44
0.287582
eb689c0f5ae5483dbf370934ef7f938d7073e716
1,076
py
Python
app/models/file.py
dhardtke/pyEncode
5db3813bfa2bae11a353dd63a10577413d41cdbe
[ "MIT" ]
5
2016-02-17T15:19:00.000Z
2020-01-22T06:10:39.000Z
app/models/file.py
dhardtke/pyEncode
5db3813bfa2bae11a353dd63a10577413d41cdbe
[ "MIT" ]
19
2016-02-18T00:26:37.000Z
2016-09-07T15:36:04.000Z
app/models/file.py
dhardtke/pyEncode
5db3813bfa2bae11a353dd63a10577413d41cdbe
[ "MIT" ]
1
2020-02-13T15:44:17.000Z
2020-02-13T15:44:17.000Z
from app import db from app.models.base_model import BaseModel class File(BaseModel): __tablename__ = "files" filename = db.Column(db.String(300)) # includes path! status = db.Column(db.Integer()) size = db.Column(db.Integer()) position = db.Column(db.Integer()) # foreign keys package_i...
28.315789
89
0.63197
1,010
0.938662
0
0
0
0
0
0
165
0.153346
eb68b9676e0d03d63bb33be1aab4650e1c5fefb7
3,126
py
Python
mediaire_toolbox/queue/tasks.py
mediaire/mediaire_toolbox
292a005247a25eb04eaa34fe5a8155422336d04b
[ "MIT" ]
null
null
null
mediaire_toolbox/queue/tasks.py
mediaire/mediaire_toolbox
292a005247a25eb04eaa34fe5a8155422336d04b
[ "MIT" ]
11
2019-09-27T15:19:28.000Z
2022-01-04T13:27:19.000Z
mediaire_toolbox/queue/tasks.py
mediaire/mediaire_toolbox
292a005247a25eb04eaa34fe5a8155422336d04b
[ "MIT" ]
3
2019-05-07T09:42:56.000Z
2022-01-27T13:14:59.000Z
import time import json from copy import deepcopy class Task(object): """Defines task objects that can be handled by the task manager.""" def __init__(self, t_id=None, user_id=None, product_id=None, tag=None, data=None, timestamp=None, update_timestamp=None, error=None): ...
30.950495
78
0.570377
3,072
0.982726
0
0
0
0
0
0
1,029
0.329175
eb69a63e704e44ba8a523693de06b874425f56d2
2,791
py
Python
torch/legacy/nn/Linear.py
UmaTaru/run
be29e4d41a4de3dee27cd6796801bfe51382d294
[ "MIT" ]
51
2020-01-26T23:32:57.000Z
2022-03-20T14:49:57.000Z
torch/legacy/nn/Linear.py
UmaTaru/run
be29e4d41a4de3dee27cd6796801bfe51382d294
[ "MIT" ]
2
2020-12-19T20:00:28.000Z
2021-03-03T20:22:45.000Z
torch/legacy/nn/Linear.py
UmaTaru/run
be29e4d41a4de3dee27cd6796801bfe51382d294
[ "MIT" ]
33
2020-02-18T16:15:48.000Z
2022-03-24T15:12:05.000Z
import math import torch from .Module import Module from .utils import clear class Linear(Module): def __init__(self, inputSize, outputSize, bias=True): super(Linear, self).__init__() self.weight = torch.Tensor(outputSize, inputSize) self.gradWeight = torch.Tensor(outputSize, inputSize) ...
31.715909
118
0.607668
2,711
0.971336
0
0
0
0
0
0
146
0.052311
eb6c5cabf7aff4e46d0f69f924e5ecdb4193cfdc
2,349
py
Python
tables_io/testUtils.py
LSSTDESC/tables_io
1c2f119c928d05d237b1c8509e340d29650ceb8b
[ "MIT" ]
1
2021-08-13T15:41:58.000Z
2021-08-13T15:41:58.000Z
tables_io/testUtils.py
LSSTDESC/tables_io
1c2f119c928d05d237b1c8509e340d29650ceb8b
[ "MIT" ]
18
2021-08-12T00:09:36.000Z
2022-02-24T21:11:18.000Z
tables_io/testUtils.py
LSSTDESC/tables_io
1c2f119c928d05d237b1c8509e340d29650ceb8b
[ "MIT" ]
null
null
null
""" Utilities for testing """ import numpy as np from astropy.table import Table as apTable from astropy.utils.diff import report_diff_values def compare_tables(t1, t2): """ Compare all the tables in two `astropy.table.Table`) Parameters ---------- t1 : `astropy.table.Table` One table t2 ...
27.964286
93
0.61175
0
0
0
0
0
0
0
0
982
0.41805
eb6cf5fe7c51c4edd9875792fb5d69a2d5f20030
185
py
Python
hello.py
khumphries/cs3240-labdemo
debc8fcb5d78ee5d8c5d3d809d2e57cac6c6762c
[ "MIT" ]
null
null
null
hello.py
khumphries/cs3240-labdemo
debc8fcb5d78ee5d8c5d3d809d2e57cac6c6762c
[ "MIT" ]
null
null
null
hello.py
khumphries/cs3240-labdemo
debc8fcb5d78ee5d8c5d3d809d2e57cac6c6762c
[ "MIT" ]
null
null
null
__author__ = '__knh4vu__' from helper import greeting from helper3 import greeting3 from helper2 import greeting2 if __name__ == '__main__': greeting('hello') greeting2('There')
14.230769
29
0.762162
0
0
0
0
0
0
0
0
36
0.194595
eb6e417ff1d33694d2432e18852dc6a0bbbf5837
746
py
Python
tests/inheritance/test_constructor.py
sco1/pylox
b4820828306c20cee3f8533c2547fafb92c6c1bd
[ "MIT" ]
2
2021-12-18T01:52:50.000Z
2022-01-17T19:41:52.000Z
tests/inheritance/test_constructor.py
sco1/pylox
b4820828306c20cee3f8533c2547fafb92c6c1bd
[ "MIT" ]
18
2021-11-30T04:05:53.000Z
2022-02-01T03:30:04.000Z
tests/inheritance/test_constructor.py
sco1/pylox
b4820828306c20cee3f8533c2547fafb92c6c1bd
[ "MIT" ]
null
null
null
from textwrap import dedent import pytest from pylox.lox import Lox # Base cases from https://github.com/munificent/craftinginterpreters/blob/master/test/inheritance/constructor.lox TEST_SRC = dedent( """\ class A { init(param) { this.field = param; } test() { print this.fi...
19.128205
113
0.648794
0
0
0
0
0
0
0
0
334
0.447721
eb70f9263d22391becf954191090f791229ce937
209
py
Python
byq_trial/__init__.py
huandzh/byq_trial
e0bede817654e17b48e8387ce1f6afce505e4602
[ "MIT" ]
null
null
null
byq_trial/__init__.py
huandzh/byq_trial
e0bede817654e17b48e8387ce1f6afce505e4602
[ "MIT" ]
1
2018-05-15T09:41:18.000Z
2018-05-15T09:44:49.000Z
byq_trial/__init__.py
huandzh/byq_trial
e0bede817654e17b48e8387ce1f6afce505e4602
[ "MIT" ]
null
null
null
#! -*- coding:utf-8 -*- """Shortcuts for yuqing trials .. moduleauthor:: Huan Di <hd@iamhd.top> """ from byq_trial.auth import SimpleAuth from byq_trial.call import APICall __all__ = [SimpleAuth, APICall]
17.416667
40
0.712919
0
0
0
0
0
0
0
0
100
0.478469
eb71982888d5f8510697907e9a0d0ca96fdd5ff9
1,196
py
Python
dugaire/util.py
tadeugr/dugaire
63e4964ed4b5016e9eb996612138c43fbcb81b53
[ "Apache-2.0" ]
4
2020-11-19T12:17:10.000Z
2020-12-15T19:34:04.000Z
dugaire/util.py
tadeugr/dugaire
63e4964ed4b5016e9eb996612138c43fbcb81b53
[ "Apache-2.0" ]
1
2020-11-26T01:25:28.000Z
2020-11-26T01:25:28.000Z
dugaire/util.py
tadeugr/dugaire
63e4964ed4b5016e9eb996612138c43fbcb81b53
[ "Apache-2.0" ]
1
2020-11-19T21:18:43.000Z
2020-11-19T21:18:43.000Z
#!/usr/bin/env python3 """ Import comunity modules. """ import os import sys import jinja2 import re HERE = os.path.dirname(os.path.realpath(__file__)) sys.path.insert(0, f"{HERE}") def string_is_latest_or_version(check_string): prog = re.compile("^(\d+\.)?(\d+\.)?(\*|\d+)$") result = prog.match(check_stri...
26
67
0.705686
0
0
0
0
0
0
0
0
358
0.299331
eb73593abc8f876baf0bf2e515008f8778305aa4
1,988
py
Python
exercicio07.py
Matheus2037/infosatc-lp-avaliativo-02
88121a8f4f294d1125492c085a15cf3a033fc919
[ "MIT" ]
null
null
null
exercicio07.py
Matheus2037/infosatc-lp-avaliativo-02
88121a8f4f294d1125492c085a15cf3a033fc919
[ "MIT" ]
null
null
null
exercicio07.py
Matheus2037/infosatc-lp-avaliativo-02
88121a8f4f294d1125492c085a15cf3a033fc919
[ "MIT" ]
null
null
null
lista_filmes = ['vingadores ultimato', 'star wars', 'as branquelas', 'vovó... zona']#Criando as 4 listas print("lista filmes: " ,lista_filmes) print("\n") lista_jogos = ['genshin impact', 'the witcher 3', 'dying light', 'destiny']#Criando as 4 listas print("lista jogos: " ,lista_jogos) print("\n") lista_livros = ['o ul...
41.416667
158
0.755533
0
0
0
0
0
0
0
0
1,237
0.620984
eb736abfcc0d07e773852cad1abeb9d44fd78b29
2,770
py
Python
ipaymu/tests.py
ekaputra07/django-ipaymu
7ea946eaeba720a002d20ad5579575951a979347
[ "BSD-3-Clause" ]
2
2018-11-14T16:25:01.000Z
2019-03-22T08:18:43.000Z
ipaymu/tests.py
ekaputra07/django-ipaymu
7ea946eaeba720a002d20ad5579575951a979347
[ "BSD-3-Clause" ]
1
2018-10-31T08:44:10.000Z
2018-11-03T08:37:35.000Z
ipaymu/tests.py
ekaputra07/django-ipaymu
7ea946eaeba720a002d20ad5579575951a979347
[ "BSD-3-Clause" ]
1
2018-10-16T09:18:20.000Z
2018-10-16T09:18:20.000Z
from django.test import TestCase from django.test.client import Client from django.core.urlresolvers import reverse from ipaymu.forms import IpaymuForm from ipaymu.models import IpaymuSessionID from ipaymu.utils import save_session, verify_session, IpaymuParamsBuilder class IpaymuTest(TestCase): fixtures = ['ip...
33.373494
157
0.642599
2,497
0.901444
0
0
0
0
0
0
916
0.330686
eb7466ed23ae7f0e3c3ac0530fad95b5be3ab94b
10,643
py
Python
notebooks/eppy_residential_archetypes.py
rdmolony/energyplus-archetypes
1270db12c9e4c32a2b1ea77ba578ecc9f6dbf76e
[ "MIT" ]
1
2021-02-01T09:25:42.000Z
2021-02-01T09:25:42.000Z
notebooks/eppy_residential_archetypes.py
rdmolony/energyplus-archetypes
1270db12c9e4c32a2b1ea77ba578ecc9f6dbf76e
[ "MIT" ]
1
2021-01-26T17:33:58.000Z
2021-01-26T17:33:58.000Z
notebooks/eppy_residential_archetypes.py
rdmolony/energyplus-archetypes
1270db12c9e4c32a2b1ea77ba578ecc9f6dbf76e
[ "MIT" ]
2
2021-01-13T15:31:50.000Z
2021-01-14T09:53:45.000Z
# --- # jupyter: # jupytext: # formats: ipynb,md # text_representation: # extension: .py # format_name: percent # format_version: '1.3' # jupytext_version: 1.10.1 # kernelspec: # display_name: Python 3 # language: python # name: python3 # --- # %% [markdown] # # Eppy is ...
47.513393
1,517
0.807855
0
0
0
0
0
0
0
0
3,983
0.374237
eb763354ab5b452fa95155e1fea3cdf2157a1123
2,535
py
Python
.local/bin/word-clock.py
hghann/osxrice
78f32f35dd68ee400025c0e61b22ab4cc78a8ac9
[ "MIT" ]
1
2021-12-25T10:57:55.000Z
2021-12-25T10:57:55.000Z
.local/bin/word-clock.py
hghann/osxrice
78f32f35dd68ee400025c0e61b22ab4cc78a8ac9
[ "MIT" ]
null
null
null
.local/bin/word-clock.py
hghann/osxrice
78f32f35dd68ee400025c0e61b22ab4cc78a8ac9
[ "MIT" ]
1
2021-12-25T10:57:54.000Z
2021-12-25T10:57:54.000Z
# MINUTES IT_IS = [[0,0],[0,1],[0,3],[0,4]] FIVE = [[3,i] for i in range(7,11)] TEN = [[1,i] for i in range(6,9)] QUARTER = [[2,i] for i in range(2,9)] TWENTY = [[3,i] for i in range(1,7)] HALF = [[1,i] for i in range(2,6)] TO = [[4,i] for i in range(1,3)] PAST = [[4,i] for i in range(3,7)] MINUTES = [ [], FI...
26.684211
101
0.50927
0
0
0
0
0
0
0
0
417
0.164497
eb772658ca94856431b34ba889686158bd95aa78
1,884
py
Python
qcdb/tests/nwchem_tests/test_tce_ccsd_pr_br_t.py
loriab/qccddb
d9e156ef8b313ac0633211fc6b841f84a3ddde24
[ "BSD-3-Clause" ]
8
2019-03-28T11:54:59.000Z
2022-03-19T03:31:37.000Z
qcdb/tests/nwchem_tests/test_tce_ccsd_pr_br_t.py
loriab/qccddb
d9e156ef8b313ac0633211fc6b841f84a3ddde24
[ "BSD-3-Clause" ]
39
2018-10-31T23:02:18.000Z
2021-12-12T22:11:37.000Z
qcdb/tests/nwchem_tests/test_tce_ccsd_pr_br_t.py
loriab/qccddb
d9e156ef8b313ac0633211fc6b841f84a3ddde24
[ "BSD-3-Clause" ]
9
2018-03-12T20:51:50.000Z
2022-02-28T15:18:34.000Z
# TCE CCSD(T) and CCSD[T] calculations import os import sys import qcdb from ..utils import * def check_ccsd_t_pr_br(return_value): ccsd_tot = -76.240077811301250 ccsd_corl = -0.213269954065481 t_br_corr = -0.003139909173705 t_br_corl = -0.216409863239186 ccsd_t_br = -76.243217720474960 t_pr...
34.254545
105
0.638004
0
0
0
0
688
0.36518
0
0
700
0.37155
eb7c5cbf4a4be6c62f0ee77abad0dd0ba1cedf55
6,246
py
Python
autoload/squeeze.py
sangjinhan/squeeze
0c1721724d181f146c4829afb58e78a596e38cb5
[ "BSD-3-Clause" ]
1
2018-07-08T10:39:51.000Z
2018-07-08T10:39:51.000Z
autoload/squeeze.py
sangjinhan/squeeze
0c1721724d181f146c4829afb58e78a596e38cb5
[ "BSD-3-Clause" ]
null
null
null
autoload/squeeze.py
sangjinhan/squeeze
0c1721724d181f146c4829afb58e78a596e38cb5
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python3 import time import multiprocessing import os import vim from async_worker import AsyncWorker import utils # Global map for host (source code) window ID -> Squeezer instance squeezers = {} # set of Squeezer instances that are waiting for updates polling_squeezers = set() def create_window(b...
30.468293
75
0.590618
4,322
0.691963
0
0
0
0
0
0
1,365
0.21854
eb8028a8b7b945f7ec2d911683799e73bf046fb9
1,781
py
Python
loopingTechniques.py
harish-kumar-97/Python-Exercises
c3966a75283dec335b83fea53160cf09ba93f9a6
[ "MIT" ]
null
null
null
loopingTechniques.py
harish-kumar-97/Python-Exercises
c3966a75283dec335b83fea53160cf09ba93f9a6
[ "MIT" ]
null
null
null
loopingTechniques.py
harish-kumar-97/Python-Exercises
c3966a75283dec335b83fea53160cf09ba93f9a6
[ "MIT" ]
null
null
null
# python code to demonstrate working of enumerate() for key, value in enumerate(['The', 'Big', 'Bang', 'Theory']): print(key, value) print('\n') # python code to demonstrate working of enumerate() for key, value in enumerate(['Geeks', 'for', 'Geeks', 'is', 'the', 'Best', 'Coding', 'Platform']): print(value, e...
30.186441
98
0.662549
0
0
0
0
0
0
0
0
1,094
0.614262
eb81a639415e736f223f1c5d8de1dac03d696391
131
py
Python
tests/test_a.py
keik/sandbox-python-structure
8a112b68ad6f42fdc2736553c4914e7ab59462fc
[ "MIT" ]
1
2016-08-15T08:19:43.000Z
2016-08-15T08:19:43.000Z
tests/test_a.py
keik/sandbox-python-structure
8a112b68ad6f42fdc2736553c4914e7ab59462fc
[ "MIT" ]
null
null
null
tests/test_a.py
keik/sandbox-python-structure
8a112b68ad6f42fdc2736553c4914e7ab59462fc
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from sandbox_python_structure import f def test_parse_no_subarg(): ret = f() assert ret == 'hi'
14.555556
38
0.633588
0
0
0
0
0
0
0
0
27
0.206107
eb821deb2b5a5317016e2098eafebee1b6e630ed
18,063
py
Python
alembic/versions/9e7ee952f6ae_initial_tables.py
SegFaulti4/lingvodoc
8b296b43453a46b814d3cd381f94382ebcb9c6a6
[ "Apache-2.0" ]
5
2017-03-30T18:02:11.000Z
2021-07-20T16:02:34.000Z
alembic/versions/9e7ee952f6ae_initial_tables.py
SegFaulti4/lingvodoc
8b296b43453a46b814d3cd381f94382ebcb9c6a6
[ "Apache-2.0" ]
15
2016-02-24T13:16:59.000Z
2021-09-03T11:47:15.000Z
alembic/versions/9e7ee952f6ae_initial_tables.py
Winking-maniac/lingvodoc
f037bf0e91ccdf020469037220a43e63849aa24a
[ "Apache-2.0" ]
22
2015-09-25T07:13:40.000Z
2021-08-04T18:08:26.000Z
"""initial tables Revision ID: 9e7ee952f6ae Revises: Create Date: 2016-10-21 17:20:27.709284 """ # revision identifiers, used by Alembic. revision = '9e7ee952f6ae' down_revision = None branch_labels = None depends_on = None from alembic import op from sqlalchemy.types import Text import sqlalchemy as sa from sqlalc...
55.75
172
0.716548
0
0
0
0
0
0
0
0
6,110
0.338261
eb823a3ab1cfe40fa4039cd8121d4b7741953f43
14,233
py
Python
sirius-pipeline/SAI/sai_api_gen.py
mmiele/DASH
30c65abc597b74a5794f9cc8f287f0febebc820c
[ "Apache-2.0" ]
18
2021-09-22T04:50:09.000Z
2022-03-26T03:54:26.000Z
sirius-pipeline/SAI/sai_api_gen.py
mmiele/DASH
30c65abc597b74a5794f9cc8f287f0febebc820c
[ "Apache-2.0" ]
62
2021-11-12T21:25:10.000Z
2022-03-31T22:41:17.000Z
sirius-pipeline/SAI/sai_api_gen.py
mmiele/DASH
30c65abc597b74a5794f9cc8f287f0febebc820c
[ "Apache-2.0" ]
19
2021-09-22T22:05:59.000Z
2022-03-29T04:37:54.000Z
#!/usr/bin/env python3 try: import os import json import argparse import shutil from git import Repo from jinja2 import Template, Environment, FileSystemLoader except ImportError as ie: print("Import failed for " + ie.name) exit(1) NAME_TAG = 'name' TABLES_TAG = 'tables' BITWIDTH_TAG =...
38.158177
140
0.644488
0
0
0
0
0
0
0
0
3,642
0.255884
eb85b2b61c540dec30a5ddbb7a6f5bca969046a6
399
py
Python
setup.py
mapogolions/pyreact-event-loop
6bfdf34c73a8ef1ce89adb3af69ac07314a0ae3e
[ "MIT" ]
null
null
null
setup.py
mapogolions/pyreact-event-loop
6bfdf34c73a8ef1ce89adb3af69ac07314a0ae3e
[ "MIT" ]
2
2019-05-21T14:46:25.000Z
2021-06-01T23:54:24.000Z
setup.py
mapogolions/pyreact
8d91f8397e6bec3fb02140015c68b50f6cb8ea62
[ "MIT" ]
null
null
null
from setuptools import setup def readme(): with open('./README.md') as f: return f.read() setup( name='event_loop', version='0.1', author='mapogolions', author_email='ivanovpavelalex45@gmail.com', description='Simple event loop', license='LICENSE.txt', long_description=readme...
19.95
47
0.646617
0
0
0
0
0
0
0
0
134
0.33584
eb85bad7014ffa6c1d37965f545f670fc38b8748
382
py
Python
essentials/oo-programming/simple_class.py
iomegak12/intel-training-usecase-1
0d1ab6f6076f46f7fbb290ceb41d6b851da1af3a
[ "MIT" ]
null
null
null
essentials/oo-programming/simple_class.py
iomegak12/intel-training-usecase-1
0d1ab6f6076f46f7fbb290ceb41d6b851da1af3a
[ "MIT" ]
null
null
null
essentials/oo-programming/simple_class.py
iomegak12/intel-training-usecase-1
0d1ab6f6076f46f7fbb290ceb41d6b851da1af3a
[ "MIT" ]
null
null
null
class Person: """ Representation of a person, which includes name, gender, date of birth """ def __init__(self, name, gender, age): self.name = name self.gender = gender self.age = age def __str__(self): return f'Name: {self.name}, Gender: {self.gender}, Age: {s...
21.222222
78
0.589005
329
0.861257
0
0
0
0
0
0
163
0.426702
eb865cf2e7668259a91927012b67adf757085745
1,121
py
Python
Python/ITChallenge/2011/3.py
TRex22/random
97d74c57bad4e2046d940a92d71f38f202cdb70b
[ "Unlicense" ]
2
2015-11-05T21:23:12.000Z
2019-12-03T07:02:41.000Z
Python/ITChallenge/2011/3.py
TRex22/random
97d74c57bad4e2046d940a92d71f38f202cdb70b
[ "Unlicense" ]
null
null
null
Python/ITChallenge/2011/3.py
TRex22/random
97d74c57bad4e2046d940a92d71f38f202cdb70b
[ "Unlicense" ]
null
null
null
#a = raw_input() num = input() def addone(): global t, qq t[qq-1] += 1 carry = 0 c = 0 ss = "" for j in range(qq): t[qq-1-j] += carry if (t[qq-1-j] > 1): t[qq-1-j] = 0 carry = 1 else: carry = 0 c += 1 ss += str(t[qq-1-j]) return ss def makestring(): s = "" ends = "" global t, b, l, qq ...
14.558442
66
0.486173
0
0
0
0
0
0
0
0
94
0.083854
eb87aab9a356ed1a7a06480dce0810bf77f27d97
1,658
py
Python
cytoscapeMaker.py
admar505/python-tools
743c0e41e6700efa3817fdb09c451f8fffccd1b3
[ "Apache-2.0" ]
null
null
null
cytoscapeMaker.py
admar505/python-tools
743c0e41e6700efa3817fdb09c451f8fffccd1b3
[ "Apache-2.0" ]
null
null
null
cytoscapeMaker.py
admar505/python-tools
743c0e41e6700efa3817fdb09c451f8fffccd1b3
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python import sys,os,re,fileinput,argparse import csv import random parser = argparse.ArgumentParser(description="takes a file of CYC data, and produces pairwise info for cytoscape network viewing" ) parser.add_argument("--fi",help="the file, must be headered as \"Pathway-id Pathway-name Gene-id Gene-nam...
23.027778
131
0.575392
0
0
0
0
0
0
0
0
684
0.412545
eb888ccd4d5150a074b0d771eabcba3d7b0bf69d
564
py
Python
src/util.py
abeakkas/ipho-unofficial.org
803ab3cc20670304f7be899ecc48b753765c2ddc
[ "MIT" ]
5
2020-04-10T19:32:43.000Z
2021-05-08T23:39:21.000Z
src/util.py
abeakkas/ipho-unofficial.org
803ab3cc20670304f7be899ecc48b753765c2ddc
[ "MIT" ]
5
2016-09-01T04:38:53.000Z
2019-01-31T15:51:39.000Z
src/util.py
abeakkas/ipho-unofficial.org
803ab3cc20670304f7be899ecc48b753765c2ddc
[ "MIT" ]
7
2016-08-10T10:30:59.000Z
2020-02-21T14:12:35.000Z
import os def makedirs(path): try: os.makedirs(path) except OSError: pass def readfile(path): with open(path, 'r') as file: return file.read() def writefile(path, content): with open(path, 'w') as file: return file.write(content) def copyfile(_from, to...
19.448276
35
0.526596
0
0
0
0
0
0
0
0
31
0.054965
eb88dcaec82b7d18b2e8efb0e331cee8cbb15f9e
7,873
py
Python
pysocksproto/tools.py
fkohs/py_socksproto
343ae1e2fee66cdb87c510d13e8d27db60991ab4
[ "MIT" ]
null
null
null
pysocksproto/tools.py
fkohs/py_socksproto
343ae1e2fee66cdb87c510d13e8d27db60991ab4
[ "MIT" ]
null
null
null
pysocksproto/tools.py
fkohs/py_socksproto
343ae1e2fee66cdb87c510d13e8d27db60991ab4
[ "MIT" ]
null
null
null
from .exceptions import UnexpectedValue from .constants import * import socket, struct, threading, time class Tools: atype2AF = { ATYP_IPV4:socket.AF_INET, ATYP_IPV6:socket.AF_INET6, ATYP_DOMAINNAME:socket.AF_INET } def recv2(conn:socket.socket, *args): ...
42.556757
150
0.585164
7,767
0.986536
0
0
0
0
0
0
2,068
0.26267
eb893239a685151332f8c8b4695d9a76a757792e
1,402
py
Python
algo/searching_and_sorting/binary_search.py
avi3tal/knowledgebase
fd30805aa94332a6c14c9d8631c7044673fb3e2c
[ "MIT" ]
null
null
null
algo/searching_and_sorting/binary_search.py
avi3tal/knowledgebase
fd30805aa94332a6c14c9d8631c7044673fb3e2c
[ "MIT" ]
null
null
null
algo/searching_and_sorting/binary_search.py
avi3tal/knowledgebase
fd30805aa94332a6c14c9d8631c7044673fb3e2c
[ "MIT" ]
1
2021-11-19T13:45:59.000Z
2021-11-19T13:45:59.000Z
def binary_search(search_num, sorted_arr): """ https://runestone.academy/runestone/books/published/pythonds/SortSearch/TheBinarySearch.html First Q at https://dev.to/javinpaul/20-basic-algorithms-problems-from-coding-interviews-4o76 """ if sorted_arr[0] == search_num: return True arr_l...
26.45283
96
0.617689
0
0
0
0
0
0
0
0
215
0.153352
eb89523d17723f3e6a6db454cea7c75b5abcf4eb
3,292
py
Python
axelrod/tests/test_resultset.py
DumisaniZA/Axelrod
e59fc40ebb705afe05cea6f30e282d1e9c621259
[ "MIT" ]
33
2015-02-20T11:36:48.000Z
2022-02-16T17:02:06.000Z
axelrod/tests/test_resultset.py
DumisaniZA/Axelrod
e59fc40ebb705afe05cea6f30e282d1e9c621259
[ "MIT" ]
108
2015-02-18T14:15:44.000Z
2020-05-08T10:39:58.000Z
axelrod/tests/test_resultset.py
DumisaniZA/Axelrod
e59fc40ebb705afe05cea6f30e282d1e9c621259
[ "MIT" ]
41
2015-02-18T13:40:04.000Z
2021-05-31T06:08:10.000Z
import unittest import axelrod class TestResultSet(unittest.TestCase): @classmethod def setUpClass(cls): cls.players = ('Player1', 'Player2', 'Player3') cls.test_results = [ [[0, 0], [10, 10], [21, 21]], [[10, 8], [0, 0], [16, 20]], [[16, 16], [16, 16], [0...
36.577778
89
0.59599
3,257
0.989368
0
0
974
0.295869
0
0
107
0.032503
eb89728654ff6fe0b167e3b43a91c36391a5c80e
814
py
Python
sparse_arrays.py
erjan/coding_exercises
53ba035be85f1e7a12b4d4dbf546863324740467
[ "Apache-2.0" ]
null
null
null
sparse_arrays.py
erjan/coding_exercises
53ba035be85f1e7a12b4d4dbf546863324740467
[ "Apache-2.0" ]
null
null
null
sparse_arrays.py
erjan/coding_exercises
53ba035be85f1e7a12b4d4dbf546863324740467
[ "Apache-2.0" ]
null
null
null
#There is a collection of #input strings and a collection of query strings. For each query string, determine how many times it occurs in the list of input strings def f(): strings = ['aba', 'baba', 'aba', 'xzxb'] queries = ['aba', 'xzxb', 'ab'] res = [] ''' for q in queries: tota...
20.35
136
0.503686
0
0
0
0
0
0
0
0
379
0.465602
eb8a1d7c0343c248c39a269df6093c8c26b1c2e1
1,494
py
Python
MAOL/personal_list/migrations/0001_initial.py
noxlock/my-anime-openings-list
4ab7660f226af5f06b941c657b8ff611ec8c63bc
[ "MIT" ]
null
null
null
MAOL/personal_list/migrations/0001_initial.py
noxlock/my-anime-openings-list
4ab7660f226af5f06b941c657b8ff611ec8c63bc
[ "MIT" ]
4
2021-12-31T07:56:10.000Z
2021-12-31T09:43:27.000Z
MAOL/personal_list/migrations/0001_initial.py
noxlock/my-anime-openings-list
4ab7660f226af5f06b941c657b8ff611ec8c63bc
[ "MIT" ]
null
null
null
# Generated by Django 3.2.4 on 2021-06-30 14:10 from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ ('home', '0001_initial'), migrations.swappable_dependency(setting...
41.5
248
0.595047
1,335
0.893574
0
0
0
0
0
0
311
0.208166
eb8c05f5a993f660ca7de8d026f690e8d7461195
4,658
py
Python
reactapp/FlowerBackend/strategies/FedOpt.py
ImperialAI-Blockchain-Team/group-project-decentralised
27b4242aa850c5c32d3bdbe6e4c9e3e3c226e7d3
[ "Apache-2.0" ]
1
2022-01-03T15:15:58.000Z
2022-01-03T15:15:58.000Z
reactapp/FlowerBackend/strategies/FedOpt.py
ImperialAI-Blockchain-Team/group-project-decentralised
27b4242aa850c5c32d3bdbe6e4c9e3e3c226e7d3
[ "Apache-2.0" ]
null
null
null
reactapp/FlowerBackend/strategies/FedOpt.py
ImperialAI-Blockchain-Team/group-project-decentralised
27b4242aa850c5c32d3bdbe6e4c9e3e3c226e7d3
[ "Apache-2.0" ]
null
null
null
'''Ref: https://arxiv.org/pdf/2003.00295.pdf''' from typing import Callable, Dict, List, Optional, Tuple import numpy as np from flwr.common import ( EvaluateIns, EvaluateRes, FitIns, FitRes, Weights, parameters_to_weights, weights_to_parameters, ) from flwr.server.strategy.aggregate imp...
34
160
0.607342
4,048
0.869043
0
0
0
0
0
0
247
0.053027
eb8c8d68ae724529208f6f7e11037b7998a2407e
48
py
Python
nsq/version.py
virtuald/pynsq
40a637b02c28edfb7723373b81f7e7b9d5e364ed
[ "MIT" ]
null
null
null
nsq/version.py
virtuald/pynsq
40a637b02c28edfb7723373b81f7e7b9d5e364ed
[ "MIT" ]
null
null
null
nsq/version.py
virtuald/pynsq
40a637b02c28edfb7723373b81f7e7b9d5e364ed
[ "MIT" ]
null
null
null
# also update in setup.py __version__ = '0.6.9'
16
25
0.6875
0
0
0
0
0
0
0
0
32
0.666667
eb8d0654d1d205d5f73cc68270c3fb56a4a831b9
786
py
Python
setup.py
alekordESA/package-template
c95a64bf125d41f1bcfd50494dbd0daeb0b27fca
[ "MIT" ]
null
null
null
setup.py
alekordESA/package-template
c95a64bf125d41f1bcfd50494dbd0daeb0b27fca
[ "MIT" ]
null
null
null
setup.py
alekordESA/package-template
c95a64bf125d41f1bcfd50494dbd0daeb0b27fca
[ "MIT" ]
null
null
null
import setuptools with open("README.md", "r") as fh: long_description = fh.read() long_description = """ Short description... """ setuptools.setup( name='test_package_kthdesa', version='1.0.0', author='Alexandros Korkovelos', author_email='alekor@desa.kth.se', description='This is a test pack...
27.103448
75
0.651399
0
0
0
0
0
0
0
0
391
0.497455
eb8d74b25be29cc19bd8b5df08384b2634717dc4
5,801
py
Python
gan/Generator.py
leogeier/dl-2020-prog-gan
12f28353548188af31cc14ee18a5444ad3d95a0c
[ "MIT" ]
null
null
null
gan/Generator.py
leogeier/dl-2020-prog-gan
12f28353548188af31cc14ee18a5444ad3d95a0c
[ "MIT" ]
null
null
null
gan/Generator.py
leogeier/dl-2020-prog-gan
12f28353548188af31cc14ee18a5444ad3d95a0c
[ "MIT" ]
null
null
null
import torch from torch.nn import LeakyReLU from torch.nn.functional import interpolate from gan.EqualizedLayers import EqualizedConv2d, EqualizedDeconv2d class PixelwiseNormalization(torch.nn.Module): """ Normalize feature vectors per pixel as suggested in section 4.2 of https://research.nvidia.com/site...
37.185897
119
0.651957
5,633
0.971039
0
0
99
0.017066
0
0
2,371
0.408723