hexsha
stringlengths
40
40
size
int64
7
1.04M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
247
max_stars_repo_name
stringlengths
4
125
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
368k
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
247
max_issues_repo_name
stringlengths
4
125
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
116k
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
247
max_forks_repo_name
stringlengths
4
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
1
1.04M
avg_line_length
float64
1.77
618k
max_line_length
int64
1
1.02M
alphanum_fraction
float64
0
1
original_content
stringlengths
7
1.04M
filtered:remove_function_no_docstring
int64
-102
942k
filtered:remove_class_no_docstring
int64
-354
977k
filtered:remove_delete_markers
int64
0
60.1k
2617cb2e73b14895dfae1fd3fe2018b9394d74fd
825
py
Python
monapay/management/commands/initaccounts.py
monapayjp/monapay
c896b104b5bea328d119f009710589ffd174386a
[ "BSD-3-Clause" ]
4
2015-02-12T18:54:44.000Z
2021-04-15T05:21:06.000Z
monapay/management/commands/initaccounts.py
monapayjp/monapay
c896b104b5bea328d119f009710589ffd174386a
[ "BSD-3-Clause" ]
1
2018-02-03T17:35:36.000Z
2018-02-03T17:35:36.000Z
monapay/management/commands/initaccounts.py
monapayjp/monapay
c896b104b5bea328d119f009710589ffd174386a
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- from django.conf import settings from django.core.management.base import BaseCommand, CommandError from monapay.rpc import make_rpc_connection
35.869565
72
0.646061
# -*- coding: utf-8 -*- from django.conf import settings from django.core.management.base import BaseCommand, CommandError from monapay.rpc import make_rpc_connection class Command(BaseCommand): def __init__(self, *args, **kwargs): super(Command, self).__init__(*args, **kwargs) def handle(self, *args...
575
6
76
de7dbbbaf0bfc916c7c7f590fcfc3589933d6da2
163
py
Python
data/typing/pandas.api.types.py
vfdev-5/python-record-api
006faf0bba9cd4cb55fbacc13d2bbda365f5bf0b
[ "MIT" ]
67
2020-08-17T11:53:26.000Z
2021-11-08T20:16:06.000Z
data/typing/pandas.api.types.py
vfdev-5/python-record-api
006faf0bba9cd4cb55fbacc13d2bbda365f5bf0b
[ "MIT" ]
36
2020-08-17T11:09:51.000Z
2021-12-15T18:09:47.000Z
data/typing/pandas.api.types.py
pydata-apis/python-api-record
684cffbbb6dc6e81f9de4e02619c8b0ebc557b2b
[ "MIT" ]
7
2020-08-19T05:06:47.000Z
2020-11-04T05:10:38.000Z
from typing import * # usage.dask: 8 # usage.sklearn: 9 CategoricalDtype: object # usage.dask: 2 is_categorical_dtype: object # usage.dask: 3 is_sparse: object
13.583333
28
0.748466
from typing import * # usage.dask: 8 # usage.sklearn: 9 CategoricalDtype: object # usage.dask: 2 is_categorical_dtype: object # usage.dask: 3 is_sparse: object
0
0
0
ac8e698132504eb73e69452ac813966d0ee22822
8,425
py
Python
architect/orms/decorators.py
portcast/architect
0cc6374d718855837ab3073b708c9765feb046cb
[ "Apache-2.0" ]
null
null
null
architect/orms/decorators.py
portcast/architect
0cc6374d718855837ab3073b708c9765feb046cb
[ "Apache-2.0" ]
null
null
null
architect/orms/decorators.py
portcast/architect
0cc6374d718855837ab3073b708c9765feb046cb
[ "Apache-2.0" ]
null
null
null
""" Defines decorators that Architect provides. """ import inspect import functools from .bases import BaseFeature from .registry import registry, Registrar from ..exceptions import ( ORMError, FeatureInstallError, FeatureUninstallError, MethodAutoDecorateError ) from copy import deepcopy class ins...
41.502463
118
0.622077
""" Defines decorators that Architect provides. """ import inspect import functools from .bases import BaseFeature from .registry import registry, Registrar from ..exceptions import ( ORMError, FeatureInstallError, FeatureUninstallError, MethodAutoDecorateError ) from copy import deepcopy def set_li...
1,483
3
122
9c1d726650bd473804e5a039a8c9a56480255dc6
1,144
py
Python
Machine-Learning-A-Z-Udemy-master/Machine Learning A-Z Template Folder/Part 1 - Data Preprocessing/Mpython_working.py
CT83/Independent-Coursework
5c7f93a7e05e64b13cb821f603efc54c92ad96c6
[ "Apache-2.0" ]
null
null
null
Machine-Learning-A-Z-Udemy-master/Machine Learning A-Z Template Folder/Part 1 - Data Preprocessing/Mpython_working.py
CT83/Independent-Coursework
5c7f93a7e05e64b13cb821f603efc54c92ad96c6
[ "Apache-2.0" ]
null
null
null
Machine-Learning-A-Z-Udemy-master/Machine Learning A-Z Template Folder/Part 1 - Data Preprocessing/Mpython_working.py
CT83/Independent-Coursework
5c7f93a7e05e64b13cb821f603efc54c92ad96c6
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Importing the Libraries import numpy as np import matplotlib.pyplot as plt import pandas as pd # Importing the Data dataset=pd.read_csv('Data.csv') X = dataset.iloc[:,:-1].values y = dataset.iloc[:,3].values # Taking care of missing Data from sklearn.preprocessing import Imputer imputer = I...
30.918919
92
0.768357
# -*- coding: utf-8 -*- # Importing the Libraries import numpy as np import matplotlib.pyplot as plt import pandas as pd # Importing the Data dataset=pd.read_csv('Data.csv') X = dataset.iloc[:,:-1].values y = dataset.iloc[:,3].values # Taking care of missing Data from sklearn.preprocessing import Imputer imputer = I...
0
0
0
18411d6cbef85b0fa08f04f819e453cb8daf0028
13,542
py
Python
tzdealer/tzdealer/report/customer_age/customer_age.py
Lewinta/tzdealer
3e6a8f39e16029b217ae84bed806cb79bbc89dbf
[ "MIT" ]
null
null
null
tzdealer/tzdealer/report/customer_age/customer_age.py
Lewinta/tzdealer
3e6a8f39e16029b217ae84bed806cb79bbc89dbf
[ "MIT" ]
null
null
null
tzdealer/tzdealer/report/customer_age/customer_age.py
Lewinta/tzdealer
3e6a8f39e16029b217ae84bed806cb79bbc89dbf
[ "MIT" ]
null
null
null
# Copyright (c) 2013, TZCODE SRL and contributors # For license information, please see license.txt from __future__ import unicode_literals import frappe from frappe import _ from frappe.utils import cstr, flt, date_diff, nowdate def get_data(filters): """ Return the data that needs to be rendered """ fields = ge...
30.431461
172
0.628563
# Copyright (c) 2013, TZCODE SRL and contributors # For license information, please see license.txt from __future__ import unicode_literals import frappe from frappe import _ from frappe.utils import cstr, flt, date_diff, nowdate def execute(filters=None): return get_columns(filters), get_data(filters) def get_colu...
2,287
0
92
6469e5d0d5c80ef3183e5f71c4afdb4b3f3f36a4
934
py
Python
setup.py
bertsky/ocrd_vandalize
0cb84fb387d0145d386c2a425f20beee5d355b3d
[ "Apache-2.0" ]
8
2021-12-15T14:45:11.000Z
2022-02-09T16:51:20.000Z
setup.py
bertsky/ocrd_vandalize
0cb84fb387d0145d386c2a425f20beee5d355b3d
[ "Apache-2.0" ]
1
2022-01-14T10:58:27.000Z
2022-01-14T10:58:27.000Z
setup.py
bertsky/ocrd_vandalize
0cb84fb387d0145d386c2a425f20beee5d355b3d
[ "Apache-2.0" ]
2
2022-01-14T11:06:54.000Z
2022-01-21T14:54:10.000Z
# -*- coding: utf-8 -*- import codecs import json from setuptools import setup, find_packages # with codecs.open('README.md', encoding='utf-8') as f: README = f.read() with open('./ocrd-tool.json', 'r') as f: version = json.load(f)['version'] setup( name='ocrd_vandalize', version=version, descri...
26.685714
68
0.638116
# -*- coding: utf-8 -*- import codecs import json from setuptools import setup, find_packages # with codecs.open('README.md', encoding='utf-8') as f: README = f.read() with open('./ocrd-tool.json', 'r') as f: version = json.load(f)['version'] setup( name='ocrd_vandalize', version=version, descri...
0
0
0
77f7cfaaa0a25a3602dcfef15eb55e962868b137
142
py
Python
exercise/test4.py
LeeBeral/python
9f0d360d69ee5245e3ef13a9dc9fc666374587a4
[ "MIT" ]
null
null
null
exercise/test4.py
LeeBeral/python
9f0d360d69ee5245e3ef13a9dc9fc666374587a4
[ "MIT" ]
null
null
null
exercise/test4.py
LeeBeral/python
9f0d360d69ee5245e3ef13a9dc9fc666374587a4
[ "MIT" ]
null
null
null
dic = {'name':'lili','age':12} print(dic) del dic['name'] print(dic) dic2 ={'name':'mam'} print(dic2) dic.update(dic2) print(dic)
12.909091
31
0.584507
dic = {'name':'lili','age':12} print(dic) del dic['name'] print(dic) dic2 ={'name':'mam'} print(dic2) dic.update(dic2) print(dic)
0
0
0
084a7a4364ba109593d9c831baac3d5b551aa8da
3,182
py
Python
hacktheback/rest/forms/serializers/form.py
hackthevalley/hack-the-back
a418f2d2751656fed76d0b8c95c8e2a060525e78
[ "MIT" ]
null
null
null
hacktheback/rest/forms/serializers/form.py
hackthevalley/hack-the-back
a418f2d2751656fed76d0b8c95c8e2a060525e78
[ "MIT" ]
null
null
null
hacktheback/rest/forms/serializers/form.py
hackthevalley/hack-the-back
a418f2d2751656fed76d0b8c95c8e2a060525e78
[ "MIT" ]
null
null
null
from django.db import transaction from rest_framework import serializers from hacktheback.forms.models import Form, Question, QuestionOption
29.738318
79
0.562539
from django.db import transaction from rest_framework import serializers from hacktheback.forms.models import Form, Question, QuestionOption class QuestionOptionSerializer(serializers.ModelSerializer): class Meta: model = QuestionOption exclude = ("question",) def create(self, validated_data...
0
2,968
69
e49d30b97a80af7ec73993c80fa023f88465b849
298
py
Python
data/kids/nofz/delta_z_correlated_to_uncorrelated.py
KiDS-WL/Cat_to_Obs_K1000_P1
0de7f79cab150416859ffe58ac2d0f5659aedb5d
[ "MIT" ]
7
2020-11-18T12:58:03.000Z
2021-07-01T08:54:29.000Z
data/kids/nofz/delta_z_correlated_to_uncorrelated.py
KiDS-WL/Cat_to_Obs_K1000_P1
0de7f79cab150416859ffe58ac2d0f5659aedb5d
[ "MIT" ]
null
null
null
data/kids/nofz/delta_z_correlated_to_uncorrelated.py
KiDS-WL/Cat_to_Obs_K1000_P1
0de7f79cab150416859ffe58ac2d0f5659aedb5d
[ "MIT" ]
3
2020-12-09T13:30:22.000Z
2022-03-02T01:40:13.000Z
import numpy as np filename='deltaz.asc' file=open(filename) delta_z=np.loadtxt(file,comments='#') filename='SOM_cov_multiplied.asc' file=open(filename) cov_z=np.loadtxt(file,comments='#') L = np.linalg.cholesky(cov_z) inv_L = np.linalg.inv(L) delta_x = np.dot(inv_L,delta_z) print(delta_x)
16.555556
37
0.744966
import numpy as np filename='deltaz.asc' file=open(filename) delta_z=np.loadtxt(file,comments='#') filename='SOM_cov_multiplied.asc' file=open(filename) cov_z=np.loadtxt(file,comments='#') L = np.linalg.cholesky(cov_z) inv_L = np.linalg.inv(L) delta_x = np.dot(inv_L,delta_z) print(delta_x)
0
0
0
69d6b18ed07e94f12372de95034df57e7fe40895
12,986
py
Python
Main/fase_1.py
DouglasAndC/GAME-COLORANDO-PYGAME
b96cc8df2dcfeb5e8a2ed0abb72c7dfb5bde2a00
[ "MIT" ]
null
null
null
Main/fase_1.py
DouglasAndC/GAME-COLORANDO-PYGAME
b96cc8df2dcfeb5e8a2ed0abb72c7dfb5bde2a00
[ "MIT" ]
null
null
null
Main/fase_1.py
DouglasAndC/GAME-COLORANDO-PYGAME
b96cc8df2dcfeb5e8a2ed0abb72c7dfb5bde2a00
[ "MIT" ]
null
null
null
import pygame from pygame.locals import * from pygame import * import globals import pygame as pg from pygame.mixer import Sound import time pg.init() # definindo cores BLACK = (0, 0, 0) WHITE = (255, 255, 255) BLUE = (0, 0, 255) GREEN = (0, 255, 0) RED = (255, 0, 0) ROXO = (127,0,127) LARANJA = (255, 127, 0) AMARELO...
38.306785
110
0.495303
import pygame from pygame.locals import * from pygame import * import globals import pygame as pg from pygame.mixer import Sound import time pg.init() # definindo cores BLACK = (0, 0, 0) WHITE = (255, 255, 255) BLUE = (0, 0, 255) GREEN = (0, 255, 0) RED = (255, 0, 0) ROXO = (127,0,127) LARANJA = (255, 127, 0) AMARELO...
10,312
0
365
146fddc89ca4117d40b10362d56eec7e35ad4254
2,442
py
Python
rescale_baseline_density.py
sjforeman/RadioFisher
fe25f969de9a700c5697168ba9e0d2645c55ed81
[ "AFL-3.0" ]
3
2020-12-05T11:28:47.000Z
2021-07-09T02:42:21.000Z
rescale_baseline_density.py
sjforeman/RadioFisher
fe25f969de9a700c5697168ba9e0d2645c55ed81
[ "AFL-3.0" ]
null
null
null
rescale_baseline_density.py
sjforeman/RadioFisher
fe25f969de9a700c5697168ba9e0d2645c55ed81
[ "AFL-3.0" ]
2
2021-07-09T02:42:23.000Z
2021-11-30T06:37:47.000Z
#!/usr/bin/python """ Rescale baseline density files, Nring(u), into n(x) = n(u=d/lambda) / lambda^2, which is approx. const. with frequency (and x = u / nu). Phil Bull (2014) """ import numpy as np import pylab as P import scipy.integrate import os, sys try: Ndish = int(sys.argv[1]) infile = sys.argv[2] ...
30.148148
83
0.581081
#!/usr/bin/python """ Rescale baseline density files, Nring(u), into n(x) = n(u=d/lambda) / lambda^2, which is approx. const. with frequency (and x = u / nu). Phil Bull (2014) """ import numpy as np import pylab as P import scipy.integrate import os, sys try: Ndish = int(sys.argv[1]) infile = sys.argv[2] ...
0
0
0
8adf03f135b35749475e53a47a588a4b9f8f0a62
1,275
py
Python
lesson26.py
pingstech/Opencv_Examples2
05327af3dbf40e2b8e9f651c8154f45e018518e4
[ "MIT" ]
1
2021-09-05T13:14:19.000Z
2021-09-05T13:14:19.000Z
lesson26.py
pingstech/Opencv_Examples2
05327af3dbf40e2b8e9f651c8154f45e018518e4
[ "MIT" ]
null
null
null
lesson26.py
pingstech/Opencv_Examples2
05327af3dbf40e2b8e9f651c8154f45e018518e4
[ "MIT" ]
null
null
null
import cv2 cap=cv2.VideoCapture(0) ret,frame1=cap.read() ret,frame2=cap.read() print(cap.get(cv2.CAP_PROP_FRAME_WIDTH)) print(cap.get(cv2.CAP_PROP_FRAME_HEIGHT)) while (cap.isOpened()): diff=cv2.absdiff(frame1,frame2) diff=doContour(setFrame(diff),frame1) cv2.imshow('Detection',frame1) frame1=frame2 ...
30.357143
80
0.682353
import cv2 def setFrame(frame): grayFrame=cv2.cvtColor(frame,cv2.COLOR_BGR2GRAY) blurFrame=cv2.GaussianBlur(grayFrame,(5,5),0) _,threshFrame=cv2.threshold(blurFrame,20,255,cv2.THRESH_BINARY) dilatedFrame=cv2.dilate(threshFrame,None,iterations=3) return dilatedFrame def doContour(frame,orgFrame,are...
785
0
46
6a9b4be7df6137a1ebf46f6a4b6479a4ae5b8614
3,444
py
Python
api/g6trayreturn.py
smu-iot20-g7/beocrescent-dashboard
93776c7cba76e5c57fc2eed8c35584e7541557fe
[ "MIT" ]
null
null
null
api/g6trayreturn.py
smu-iot20-g7/beocrescent-dashboard
93776c7cba76e5c57fc2eed8c35584e7541557fe
[ "MIT" ]
null
null
null
api/g6trayreturn.py
smu-iot20-g7/beocrescent-dashboard
93776c7cba76e5c57fc2eed8c35584e7541557fe
[ "MIT" ]
1
2020-12-05T06:48:25.000Z
2020-12-05T06:48:25.000Z
from flask import Flask, jsonify, request import pymongo from flask_cors import CORS from os import environ from bson.json_util import dumps import json app = Flask(__name__) client = pymongo.MongoClient( "mongodb+srv://iotadmin:iotadminpassword@cluster0.cowqf.mongodb.net/iotTest?retryWrites=true&w=majority&ssl=t...
33.764706
142
0.574042
from flask import Flask, jsonify, request import pymongo from flask_cors import CORS from os import environ from bson.json_util import dumps import json app = Flask(__name__) client = pymongo.MongoClient( "mongodb+srv://iotadmin:iotadminpassword@cluster0.cowqf.mongodb.net/iotTest?retryWrites=true&w=majority&ssl=t...
2,578
0
66
374f44188164e9d4772b1935cff59220da10b3cd
4,782
py
Python
calc.py
bryli/AKParser
ebecc471458b54a272134dc0f9b35f5da35a6257
[ "MIT" ]
1
2020-03-01T15:14:18.000Z
2020-03-01T15:14:18.000Z
calc.py
bryli/AKParser
ebecc471458b54a272134dc0f9b35f5da35a6257
[ "MIT" ]
null
null
null
calc.py
bryli/AKParser
ebecc471458b54a272134dc0f9b35f5da35a6257
[ "MIT" ]
null
null
null
import json from collections import Counter ALLSKL = 'allSkillLvlup' # Key for character dictionary to get 2-7 level up mats LVCOST = 'lvlUpCost' MCOSTC = 'levelUpCostCond' # Key for mastery level cost upgrades. MCOST = 'levelUpCost' SKILLS = 'skills' ELITE = 'phases' PROMOTE = 'evolveCost' RARE = 'rarity' ID = 'id' C...
37.069767
114
0.604559
import json from collections import Counter ALLSKL = 'allSkillLvlup' # Key for character dictionary to get 2-7 level up mats LVCOST = 'lvlUpCost' MCOSTC = 'levelUpCostCond' # Key for mastery level cost upgrades. MCOST = 'levelUpCost' SKILLS = 'skills' ELITE = 'phases' PROMOTE = 'evolveCost' RARE = 'rarity' ID = 'id' C...
4,108
0
138
dcb02e7452a985e2c94a463cfd5bbd8aea8b03f9
583
py
Python
backend/__init__.py
allenai/twentyquestions
48f0de26d2dca963cdae1263245d3b267ae7a771
[ "Apache-2.0" ]
9
2020-07-23T03:36:26.000Z
2022-03-03T15:20:36.000Z
backend/__init__.py
allenai/twentyquestions
48f0de26d2dca963cdae1263245d3b267ae7a771
[ "Apache-2.0" ]
null
null
null
backend/__init__.py
allenai/twentyquestions
48f0de26d2dca963cdae1263245d3b267ae7a771
[ "Apache-2.0" ]
2
2021-12-21T18:36:43.000Z
2022-03-30T07:28:52.000Z
"""A backend for playing twenty questions.""" import logging import flask from backend.views import ( twentyquestions, socketio) logger = logging.getLogger(__name__) app = flask.Flask(__name__) @app.route('/') def root(): """A root page for twentyquestions.""" return ( 'This server is u...
16.657143
67
0.682676
"""A backend for playing twenty questions.""" import logging import flask from backend.views import ( twentyquestions, socketio) logger = logging.getLogger(__name__) app = flask.Flask(__name__) @app.route('/') def root(): """A root page for twentyquestions.""" return ( 'This server is u...
0
0
0
6f2ae1ff62c113ac8412a10c9d0e89f76b2b9b99
1,665
py
Python
telegram_handler.py
anant-j/API-Toolkit
ced92c711fcb93f96b81a87e57bb4e5dd647224c
[ "CC0-1.0" ]
1
2019-12-27T17:05:52.000Z
2019-12-27T17:05:52.000Z
telegram_handler.py
anant-j/API-Toolkit
ced92c711fcb93f96b81a87e57bb4e5dd647224c
[ "CC0-1.0" ]
2
2021-02-09T03:25:59.000Z
2021-06-02T00:51:13.000Z
telegram_handler.py
anant-j/API-Toolkit
ced92c711fcb93f96b81a87e57bb4e5dd647224c
[ "CC0-1.0" ]
null
null
null
import json import requests import os my_directory = os.path.dirname(os.path.abspath(__file__)) with open(f'{my_directory}/secrets/keys.json') as f: api_keys = json.load(f) TGKEY = api_keys["Telegram"]["Key"] DEVID = api_keys["Telegram"]["DeviceID"] def send_analytics(req, fingerprint): """Sends analytics da...
36.195652
268
0.681081
import json import requests import os my_directory = os.path.dirname(os.path.abspath(__file__)) with open(f'{my_directory}/secrets/keys.json') as f: api_keys = json.load(f) TGKEY = api_keys["Telegram"]["Key"] DEVID = api_keys["Telegram"]["DeviceID"] def send_analytics(req, fingerprint): """Sends analytics da...
109
0
23
c46beeec7b11c4abe6e2db62dfaeed8601291fe1
73,322
py
Python
topobank/manager/views.py
ComputationalMechanics/TopoBank
3e598d4b98cbffa43764e335f026efcbe7580c8a
[ "MIT" ]
1
2020-06-04T23:18:53.000Z
2020-06-04T23:18:53.000Z
topobank/manager/views.py
ComputationalMechanics/TopoBank
3e598d4b98cbffa43764e335f026efcbe7580c8a
[ "MIT" ]
168
2020-06-02T14:46:45.000Z
2021-03-19T12:11:07.000Z
topobank/manager/views.py
ComputationalMechanics/TopoBank
3e598d4b98cbffa43764e335f026efcbe7580c8a
[ "MIT" ]
null
null
null
import datetime import logging import os.path import traceback from io import BytesIO import django_tables2 as tables import numpy as np from bokeh.embed import components from bokeh.models import DataRange1d, LinearColorMapper, ColorBar, LabelSet, FuncTickFormatter, TapTool, OpenURL from bokeh.plotting import figure...
37.485685
122
0.610526
import datetime import logging import os.path import traceback from io import BytesIO import django_tables2 as tables import numpy as np from bokeh.embed import components from bokeh.models import DataRange1d, LinearColorMapper, ColorBar, LabelSet, FuncTickFormatter, TapTool, OpenURL from bokeh.plotting import figure...
45,573
8,545
782
bbd02b18aafbd116aa8ea088f0e6678bdd955802
851
py
Python
server/main.py
yuweiliandrew/openrtist
4b6b17e77587751593d5e529b154e60513de3236
[ "Apache-2.0" ]
null
null
null
server/main.py
yuweiliandrew/openrtist
4b6b17e77587751593d5e529b154e60513de3236
[ "Apache-2.0" ]
null
null
null
server/main.py
yuweiliandrew/openrtist
4b6b17e77587751593d5e529b154e60513de3236
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 from gabriel_server.network_engine import server_runner import logging import argparse import importlib DEFAULT_PORT = 9099 DEFAULT_NUM_TOKENS = 2 INPUT_QUEUE_MAXSIZE = 60 logging.basicConfig(level=logging.INFO) logger = logging.getLogger(__name__) if __name__ == "__main__": main()
25.029412
99
0.720329
#!/usr/bin/env python3 from gabriel_server.network_engine import server_runner import logging import argparse import importlib DEFAULT_PORT = 9099 DEFAULT_NUM_TOKENS = 2 INPUT_QUEUE_MAXSIZE = 60 logging.basicConfig(level=logging.INFO) logger = logging.getLogger(__name__) def main(): parser = argparse.ArgumentP...
512
0
23
4845208dc2008cff6748df7a14a9be766a0ca341
891
py
Python
tests/models/product/product_relation_types/test_model.py
simonsobs/acondbs
6ca11c2889d827ecdb2b54d0cf3b94b8cdd281e6
[ "MIT" ]
null
null
null
tests/models/product/product_relation_types/test_model.py
simonsobs/acondbs
6ca11c2889d827ecdb2b54d0cf3b94b8cdd281e6
[ "MIT" ]
24
2020-04-02T19:29:07.000Z
2022-03-08T03:05:43.000Z
tests/models/product/product_relation_types/test_model.py
simonsobs/acondbs
6ca11c2889d827ecdb2b54d0cf3b94b8cdd281e6
[ "MIT" ]
1
2020-04-08T15:48:28.000Z
2020-04-08T15:48:28.000Z
from acondbs.db.sa import sa from acondbs.models import ProductRelationType ##__________________________________________________________________|| ##__________________________________________________________________||
28.741935
74
0.65881
from acondbs.db.sa import sa from acondbs.models import ProductRelationType ##__________________________________________________________________|| def test_column(app_empty): app = app_empty with app.app_context(): model = ProductRelationType( name="parent", indef_article="a",...
647
0
22
1c9ae6c11296e6a1e6f7c38c20040bce04faf76f
2,330
py
Python
examples/my_line_rules.py
l0nax/gitlint
df84afed929af588191aa93534842fab80e117dd
[ "MIT" ]
null
null
null
examples/my_line_rules.py
l0nax/gitlint
df84afed929af588191aa93534842fab80e117dd
[ "MIT" ]
null
null
null
examples/my_line_rules.py
l0nax/gitlint
df84afed929af588191aa93534842fab80e117dd
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from gitlint.rules import LineRule, RuleViolation, CommitMessageTitle from gitlint.options import ListOption """ Full details on user-defined rules: https://jorisroovers.com/gitlint/user_defined_rules The SpecialChars class below is an example of a user-defined LineRule. Line rules are gitlin...
44.807692
118
0.704292
# -*- coding: utf-8 -*- from gitlint.rules import LineRule, RuleViolation, CommitMessageTitle from gitlint.options import ListOption """ Full details on user-defined rules: https://jorisroovers.com/gitlint/user_defined_rules The SpecialChars class below is an example of a user-defined LineRule. Line rules are gitlin...
492
0
27
4581b4010635dca053e4b3dabc1023c2a4d1faf8
2,117
py
Python
src/subsystems/backarm.py
quis345/DeepSpace2019
917d120c4173e8085578c3fc7f98ecfffd8b6e5b
[ "MIT" ]
null
null
null
src/subsystems/backarm.py
quis345/DeepSpace2019
917d120c4173e8085578c3fc7f98ecfffd8b6e5b
[ "MIT" ]
null
null
null
src/subsystems/backarm.py
quis345/DeepSpace2019
917d120c4173e8085578c3fc7f98ecfffd8b6e5b
[ "MIT" ]
null
null
null
import ctre from wpilib import SmartDashboard as Dash from wpilib.command import Subsystem from constants import Constants from utils import singleton, units, lazytalonsrx, pidf class BackArm(Subsystem, metaclass=singleton.Singleton): """The back arm subsystem controls the back arm motors and encoders.""" d...
36.5
146
0.66462
import ctre from wpilib import SmartDashboard as Dash from wpilib.command import Subsystem from constants import Constants from utils import singleton, units, lazytalonsrx, pidf class BackArm(Subsystem, metaclass=singleton.Singleton): """The back arm subsystem controls the back arm motors and encoders.""" d...
290
0
108
cd830753bb5761a968e2d3653e6ef40be79f29eb
11,760
py
Python
layers/densenet.py
IlikeBB/Object-Detection-for-M-NBI
650fa1ca7b8860785f0a838dab0301a9cba121d6
[ "MIT" ]
null
null
null
layers/densenet.py
IlikeBB/Object-Detection-for-M-NBI
650fa1ca7b8860785f0a838dab0301a9cba121d6
[ "MIT" ]
null
null
null
layers/densenet.py
IlikeBB/Object-Detection-for-M-NBI
650fa1ca7b8860785f0a838dab0301a9cba121d6
[ "MIT" ]
null
null
null
import re import torch import torch.nn as nn import torch.nn.functional as F import torch.utils.checkpoint as cp from collections import OrderedDict import torch.utils.model_zoo as model_zoo __all__ = ['DenseNet', 'densenet50', 'densenet121', 'densenet169', 'densenet201', 'densenet161'] model_urls = { 'densenet1...
44.714829
192
0.63835
import re import torch import torch.nn as nn import torch.nn.functional as F import torch.utils.checkpoint as cp from collections import OrderedDict import torch.utils.model_zoo as model_zoo __all__ = ['DenseNet', 'densenet50', 'densenet121', 'densenet169', 'densenet201', 'densenet161'] model_urls = { 'densenet1...
6,645
20
260
4aae359bb47d841d355e338ca35c46c6de27cdca
2,782
py
Python
rfdmovie/models.py
Microndgt/rfdmovies
befba9ac7667d8234976b7fda7fa800beb5f05c7
[ "MIT" ]
18
2018-02-12T04:11:17.000Z
2019-10-10T01:44:31.000Z
rfdmovie/models.py
Microndgt/rfdmovies
befba9ac7667d8234976b7fda7fa800beb5f05c7
[ "MIT" ]
1
2021-06-01T21:46:26.000Z
2021-06-01T21:46:26.000Z
rfdmovie/models.py
tangzhoutz/rfdmovies-client
befba9ac7667d8234976b7fda7fa800beb5f05c7
[ "MIT" ]
null
null
null
from sqlalchemy import ARRAY from sqlalchemy import Column from sqlalchemy.types import String, Integer, BigInteger, Float, Date, Text from rfdmovie.db import BaseModel from rfdmovie.utils import generate_timestamp
33.518072
90
0.626887
from sqlalchemy import ARRAY from sqlalchemy import Column from sqlalchemy.types import String, Integer, BigInteger, Float, Date, Text from rfdmovie.db import BaseModel from rfdmovie.utils import generate_timestamp class Movie(BaseModel): __tablename__ = 'movie' id = Column(Integer, primary_key=True) na...
1,183
1,335
46
87fdd5cc0a847ca325cf3cc9964514e6fe985f25
5,539
py
Python
track/centroidtracker.py
yxtj/VideoServing
52d1c1c97021f11cc4d77c181ac1144fe3a789ce
[ "MIT" ]
null
null
null
track/centroidtracker.py
yxtj/VideoServing
52d1c1c97021f11cc4d77c181ac1144fe3a789ce
[ "MIT" ]
null
null
null
track/centroidtracker.py
yxtj/VideoServing
52d1c1c97021f11cc4d77c181ac1144fe3a789ce
[ "MIT" ]
null
null
null
# modified from: # https://www.pyimagesearch.com/2018/07/23/simple-object-tracking-with-opencv/ from scipy.spatial import distance as dist import numpy as np
40.727941
78
0.608955
# modified from: # https://www.pyimagesearch.com/2018/07/23/simple-object-tracking-with-opencv/ from scipy.spatial import distance as dist import numpy as np class CentroidTracker(): def __init__(self, maxDisappeared=50): # initialize the next unique object ID along with two ordered # dictionaries ...
4,998
3
363
5e9c4f1b493d16c09e4c154dee47c2a179feb368
2,371
py
Python
trader/messaging/bus.py
9600dev/mmr
b08e63b7044f2b2061d8679b216822c82d309c86
[ "Apache-2.0" ]
12
2021-09-22T21:19:23.000Z
2022-01-03T21:38:47.000Z
trader/messaging/bus.py
9600dev/mmr
b08e63b7044f2b2061d8679b216822c82d309c86
[ "Apache-2.0" ]
null
null
null
trader/messaging/bus.py
9600dev/mmr
b08e63b7044f2b2061d8679b216822c82d309c86
[ "Apache-2.0" ]
3
2021-09-05T23:26:13.000Z
2022-03-25T01:01:22.000Z
import lightbus from lightbus.api import Api, Event from dataclasses import dataclass from ib_insync.objects import Position, PortfolioItem from ib_insync.contract import Contract from ib_insync.order import Order, Trade from trader.container import Container from trader.trading.trading_runtime import Action, Trader fr...
38.241935
101
0.716997
import lightbus from lightbus.api import Api, Event from dataclasses import dataclass from ib_insync.objects import Position, PortfolioItem from ib_insync.contract import Contract from ib_insync.order import Order, Trade from trader.container import Container from trader.trading.trading_runtime import Action, Trader fr...
1,012
758
23
d5080d8c67c0d3338d1a3b44c3d780a559c00923
9,169
py
Python
sdk/tests/router/config/resource_request_test.py
LeonLnj/turing
93817f5cfb40d056a707bd85e9265b5cafdaeb94
[ "Apache-2.0" ]
1
2021-12-26T09:04:13.000Z
2021-12-26T09:04:13.000Z
sdk/tests/router/config/resource_request_test.py
LeonLnj/turing
93817f5cfb40d056a707bd85e9265b5cafdaeb94
[ "Apache-2.0" ]
null
null
null
sdk/tests/router/config/resource_request_test.py
LeonLnj/turing
93817f5cfb40d056a707bd85e9265b5cafdaeb94
[ "Apache-2.0" ]
null
null
null
import pytest from turing.generated.exceptions import ApiValueError from turing.router.config.resource_request import (ResourceRequest, InvalidReplicaCountException) @pytest.mark.parametrize( "min_replica,max_replica,cpu_request,memory_request,expected", [ pytest.param( 1, 3, ...
23.450128
97
0.583815
import pytest from turing.generated.exceptions import ApiValueError from turing.router.config.resource_request import (ResourceRequest, InvalidReplicaCountException) @pytest.mark.parametrize( "min_replica,max_replica,cpu_request,memory_request,expected", [ pytest.param( 1, 3, ...
5,029
0
308
3bf7e94c85fcc3d67cebd0e19a84bfc00aa8605f
13,001
py
Python
bs_align/bs_align_utils.py
huboqiang/BSseeker2
385f88cf78b3efced75798c00f0e7185ac064047
[ "MIT" ]
null
null
null
bs_align/bs_align_utils.py
huboqiang/BSseeker2
385f88cf78b3efced75798c00f0e7185ac064047
[ "MIT" ]
null
null
null
bs_align/bs_align_utils.py
huboqiang/BSseeker2
385f88cf78b3efced75798c00f0e7185ac064047
[ "MIT" ]
1
2021-11-01T03:21:47.000Z
2021-11-01T03:21:47.000Z
from bs_utils.utils import * import re BAM_MATCH = 0 BAM_INS = 1 BAM_DEL = 2 BAM_SOFTCLIP = 4 CIGAR_OPS = {'M' : BAM_MATCH, 'I' : BAM_INS, 'D' : BAM_DEL, 'S' : BAM_SOFTCLIP} #---------------------------------------------------------------- """ Exmaple: ======== Read : ACCGCGTTGATCGAGTACGTACGTGGGTC Adapter ...
32.748111
133
0.515576
from bs_utils.utils import * import re BAM_MATCH = 0 BAM_INS = 1 BAM_DEL = 2 BAM_SOFTCLIP = 4 CIGAR_OPS = {'M' : BAM_MATCH, 'I' : BAM_INS, 'D' : BAM_DEL, 'S' : BAM_SOFTCLIP} def N_MIS(r,g): mismatches = 0 if len(r)==len(g): for i in xrange(len(r)): if r[i] != g[i] and r[i] != "N" and g[...
10,727
0
205
c3579c902cbdded2585c8b7a27020a60e348e6c2
160
py
Python
scripts/portal/evantalk02.py
G00dBye/YYMS
1de816fc842b6598d5b4b7896b6ab0ee8f7cdcfb
[ "MIT" ]
54
2019-04-16T23:24:48.000Z
2021-12-18T11:41:50.000Z
scripts/portal/evantalk02.py
G00dBye/YYMS
1de816fc842b6598d5b4b7896b6ab0ee8f7cdcfb
[ "MIT" ]
3
2019-05-19T15:19:41.000Z
2020-04-27T16:29:16.000Z
scripts/portal/evantalk02.py
G00dBye/YYMS
1de816fc842b6598d5b4b7896b6ab0ee8f7cdcfb
[ "MIT" ]
49
2020-11-25T23:29:16.000Z
2022-03-26T16:20:24.000Z
if not "mo02=o" in sm.getQRValue(22013): sm.avatarOriented("Effect/OnUserEff.img/guideEffect/evanTutorial/evanBalloon02") sm.addQRValue(22013, "mo02=o")
53.333333
84
0.75625
if not "mo02=o" in sm.getQRValue(22013): sm.avatarOriented("Effect/OnUserEff.img/guideEffect/evanTutorial/evanBalloon02") sm.addQRValue(22013, "mo02=o")
0
0
0
534e4c177b3b875055cf3bc8aa81353837994a24
1,285
py
Python
CS596/code04_lr/mglearn/plot_knn_regression.py
ko-takahashi/college
c333f1e1767f1206687f5e9b0fb3f0145b2d5d6a
[ "MIT" ]
52
2019-02-15T16:37:13.000Z
2022-02-17T18:34:30.000Z
Data Exploring/Data Exploring 12-25-17/mglearn/plot_knn_regression.py
RodeoBlues/Complete-Data-Science-Toolkits
c5e83889e24af825ec3baed6e8198debb135f1ff
[ "MIT" ]
2
2021-06-19T08:04:01.000Z
2021-06-20T16:01:21.000Z
Data Exploring/Data Exploring 12-25-17/mglearn/plot_knn_regression.py
RodeoBlues/Complete-Data-Science-Toolkits
c5e83889e24af825ec3baed6e8198debb135f1ff
[ "MIT" ]
35
2019-02-08T02:00:31.000Z
2022-03-01T23:17:00.000Z
import numpy as np import matplotlib.pyplot as plt from sklearn.neighbors import KNeighborsRegressor from sklearn.metrics import euclidean_distances from .datasets import make_wave from .plot_helpers import cm3
32.948718
76
0.60856
import numpy as np import matplotlib.pyplot as plt from sklearn.neighbors import KNeighborsRegressor from sklearn.metrics import euclidean_distances from .datasets import make_wave from .plot_helpers import cm3 def plot_knn_regression(n_neighbors=1): X, y = make_wave(n_samples=40) X_test = np.array([[-1.5],...
1,048
0
23
e5d4fa5bda36ea06fdffa442436c6a00ebf6be36
165
py
Python
gravis/_internal/plotting/__init__.py
robert-haas/gravis
3e63b606141bf78617b1247048a9e3ccca6d5824
[ "Apache-2.0" ]
3
2022-01-19T15:57:29.000Z
2022-03-06T02:36:44.000Z
gravis/_internal/plotting/__init__.py
robert-haas/gravis
3e63b606141bf78617b1247048a9e3ccca6d5824
[ "Apache-2.0" ]
2
2022-03-01T19:29:49.000Z
2022-03-01T19:31:08.000Z
gravis/_internal/plotting/__init__.py
robert-haas/gravis
3e63b606141bf78617b1247048a9e3ccca6d5824
[ "Apache-2.0" ]
null
null
null
"""A subpackage containing plotting functions.""" __all__ = [ 'd3', 'three', 'vis', ] from .d3 import d3 from .three import three from .vis import vis
13.75
49
0.636364
"""A subpackage containing plotting functions.""" __all__ = [ 'd3', 'three', 'vis', ] from .d3 import d3 from .three import three from .vis import vis
0
0
0
b74a21a3a4baee8e1ace1d4298da7847fa61cc93
68
py
Python
src/obfuscapk/obfuscators/random_manifest/__init__.py
Elyorbe/Obfuscapk
2ba18df4b5efe44b4fab271ab5ccfe51488fa693
[ "MIT" ]
688
2019-08-23T16:43:10.000Z
2022-03-29T19:35:07.000Z
src/obfuscapk/obfuscators/random_manifest/__init__.py
Ktm2590/Obfuscapk
4072b6dea88e91b75064a84c7d3adebe005e8207
[ "MIT" ]
124
2019-09-07T13:10:59.000Z
2022-03-17T16:47:29.000Z
src/obfuscapk/obfuscators/random_manifest/__init__.py
Ktm2590/Obfuscapk
4072b6dea88e91b75064a84c7d3adebe005e8207
[ "MIT" ]
204
2019-08-23T14:43:52.000Z
2022-03-30T21:04:50.000Z
#!/usr/bin/env python3 from .random_manifest import RandomManifest
17
43
0.808824
#!/usr/bin/env python3 from .random_manifest import RandomManifest
0
0
0
7fc69e8d42affa4c0554d5794c970f2092f0c828
2,152
py
Python
subtest/test_coal_mine.py
RuneSkovrupHansen/python-testing
318d082d1100877dea93cabca1c727199bc6416e
[ "MIT" ]
null
null
null
subtest/test_coal_mine.py
RuneSkovrupHansen/python-testing
318d082d1100877dea93cabca1c727199bc6416e
[ "MIT" ]
null
null
null
subtest/test_coal_mine.py
RuneSkovrupHansen/python-testing
318d082d1100877dea93cabca1c727199bc6416e
[ "MIT" ]
null
null
null
#!/bin/bash from mimetypes import init import unittest import coal_mine class TestCoalMine(unittest.TestCase): # Test that worker property sets values in range correctly # Test that worker property sets negative values to zero # Test that worker property sets values exceeding threshold to t...
37.103448
95
0.640335
#!/bin/bash from mimetypes import init import unittest import coal_mine class TestCoalMine(unittest.TestCase): def setUp(self): self.cm = coal_mine.CoalMine() # Test that worker property sets values in range correctly def test_workers_in_range(self): for workers in range(self.cm.WORK...
768
0
163
c2a7b745461abcec5d3d58cd180c360982e7bdb3
19,014
py
Python
testing/scripts/test_rolling_updates.py
pravingadakh/seldon-core
a72257fa851033ee09513a0b6b310087eb625e85
[ "Apache-2.0" ]
null
null
null
testing/scripts/test_rolling_updates.py
pravingadakh/seldon-core
a72257fa851033ee09513a0b6b310087eb625e85
[ "Apache-2.0" ]
null
null
null
testing/scripts/test_rolling_updates.py
pravingadakh/seldon-core
a72257fa851033ee09513a0b6b310087eb625e85
[ "Apache-2.0" ]
null
null
null
import os import time import logging import pytest from subprocess import run from seldon_e2e_utils import ( wait_for_status, wait_for_rollout, rest_request_ambassador, initial_rest_request, retry_run, API_AMBASSADOR, API_ISTIO_GATEWAY, ) with_api_gateways = pytest.mark.parametrize( "...
47.181141
88
0.591143
import os import time import logging import pytest from subprocess import run from seldon_e2e_utils import ( wait_for_status, wait_for_rollout, rest_request_ambassador, initial_rest_request, retry_run, API_AMBASSADOR, API_ISTIO_GATEWAY, ) def to_resources_path(file_name): return os.pat...
17,179
1,164
68
4ce4e405b09d9027494a202ab8deb07dfb728805
1,078
py
Python
ingenico/connect/sdk/domain/mandates/definitions/create_mandate_with_return_url.py
festicket/connect-sdk-python3
c399c6443789dd978f319c89e1ebd387c812a77b
[ "MIT" ]
12
2016-09-26T21:46:31.000Z
2020-12-23T18:44:54.000Z
ingenico/connect/sdk/domain/mandates/definitions/create_mandate_with_return_url.py
festicket/connect-sdk-python3
c399c6443789dd978f319c89e1ebd387c812a77b
[ "MIT" ]
3
2020-05-02T16:53:02.000Z
2020-06-02T12:49:51.000Z
ingenico/connect/sdk/domain/mandates/definitions/create_mandate_with_return_url.py
festicket/connect-sdk-python3
c399c6443789dd978f319c89e1ebd387c812a77b
[ "MIT" ]
11
2017-07-16T00:55:28.000Z
2021-09-24T17:00:49.000Z
# -*- coding: utf-8 -*- # # This class was auto-generated from the API references found at # https://epayments-api.developer-ingenico.com/s2sapi/v1/ # from ingenico.connect.sdk.domain.mandates.definitions.create_mandate_base import CreateMandateBase
29.135135
98
0.681818
# -*- coding: utf-8 -*- # # This class was auto-generated from the API references found at # https://epayments-api.developer-ingenico.com/s2sapi/v1/ # from ingenico.connect.sdk.domain.mandates.definitions.create_mandate_base import CreateMandateBase class CreateMandateWithReturnUrl(CreateMandateBase): __return_u...
446
358
23
68a2657034c704483c93720e0fd358d8d19b0d25
13,534
py
Python
VIGA_METALICA_VERIFICA - Copy.py
wmpjrufg/RASD-ALGORITMOS
1bdc2c4271c8019733c34333e5e91b70bc3c7604
[ "MIT" ]
null
null
null
VIGA_METALICA_VERIFICA - Copy.py
wmpjrufg/RASD-ALGORITMOS
1bdc2c4271c8019733c34333e5e91b70bc3c7604
[ "MIT" ]
null
null
null
VIGA_METALICA_VERIFICA - Copy.py
wmpjrufg/RASD-ALGORITMOS
1bdc2c4271c8019733c34333e5e91b70bc3c7604
[ "MIT" ]
null
null
null
################################################################################ # UNIVERSIDADE FEDERAL DE CATALÃO (UFCAT) # WANDERLEI MALAQUIAS PEREIRA JUNIOR, ENG. CIVIL / PROF (UFCAT) # DONIZETTI SOUZA JUNIOR, ENG. CIVIL (UFCAT) ###################################...
36.479784
115
0.504064
################################################################################ # UNIVERSIDADE FEDERAL DE CATALÃO (UFCAT) # WANDERLEI MALAQUIAS PEREIRA JUNIOR, ENG. CIVIL / PROF (UFCAT) # DONIZETTI SOUZA JUNIOR, ENG. CIVIL (UFCAT) ###################################...
1,056
0
46
368b9cd21ed0d5c389fc6e20d0fcc7a3b567992b
1,671
py
Python
main.py
unpamplemoussemignon/e314-music-visualization
38fe1f97bfd35751867a51af330148f65b6f21bf
[ "CC0-1.0" ]
null
null
null
main.py
unpamplemoussemignon/e314-music-visualization
38fe1f97bfd35751867a51af330148f65b6f21bf
[ "CC0-1.0" ]
null
null
null
main.py
unpamplemoussemignon/e314-music-visualization
38fe1f97bfd35751867a51af330148f65b6f21bf
[ "CC0-1.0" ]
null
null
null
#!/usr/bin/env python # ================================= # Music Visualizer # ------------ # Reference to -> [May 2020] - Mina PECHEUX # # Based on the work by Yu-Jie Lin # (Public Domain) # Github: https://gist.github.com/manugarri/1c0fcfe9619b775bb82de0790ccb88da import wave import click from compute import plt, c...
32.764706
112
0.653501
#!/usr/bin/env python # ================================= # Music Visualizer # ------------ # Reference to -> [May 2020] - Mina PECHEUX # # Based on the work by Yu-Jie Lin # (Public Domain) # Github: https://gist.github.com/manugarri/1c0fcfe9619b775bb82de0790ccb88da import wave import click from compute import plt, c...
601
0
22
df2176e417c138b40a9dee3721b7d6cc7dbf0916
1,663
py
Python
gerar_inscricaoestadual.py
andrellmagalhaes/Open-development
718fb1815fbd6dd194f1ec2049f56aa2a533b88e
[ "MIT" ]
1
2021-09-13T00:55:08.000Z
2021-09-13T00:55:08.000Z
gerar_inscricaoestadual.py
andrellmagalhaes/Open-development
718fb1815fbd6dd194f1ec2049f56aa2a533b88e
[ "MIT" ]
null
null
null
gerar_inscricaoestadual.py
andrellmagalhaes/Open-development
718fb1815fbd6dd194f1ec2049f56aa2a533b88e
[ "MIT" ]
null
null
null
# IMPORTAÇÕES import random import string # FUNÇÃO QUE GERA NÚMEROS DE INSCRIÇÃO ESTADUAL
31.980769
79
0.629585
# IMPORTAÇÕES import random import string # FUNÇÃO QUE GERA NÚMEROS DE INSCRIÇÃO ESTADUAL def gerar_inscricaoestadual(quantidade=1, tamanho=9): # VERIFICA SE "QUANTIDADE" OU "TAMANHO" NÃO SÃO DO TIPO INTEIRO if not type(quantidade) == int or not type(tamanho) == int: raise TypeError("Os par...
1,567
0
23
fa7b1e632b12afb4a0c70898ec7ee11e52a3402e
2,160
py
Python
tests/tests_unit/test_cdp_client.py
cognitedata/cognite-model-hosting
89f58e25f0e3c3a37006e60f52246da0b00a0066
[ "Apache-2.0" ]
4
2019-05-27T12:51:45.000Z
2020-02-26T08:16:30.000Z
tests/tests_unit/test_cdp_client.py
cognitedata/cognite-model-hosting
89f58e25f0e3c3a37006e60f52246da0b00a0066
[ "Apache-2.0" ]
26
2019-03-18T15:10:20.000Z
2021-06-21T05:47:24.000Z
tests/tests_unit/test_cdp_client.py
cognitedata/cognite-model-hosting
89f58e25f0e3c3a37006e60f52246da0b00a0066
[ "Apache-2.0" ]
null
null
null
import pandas as pd import pytest from cognite.client.data_classes import Datapoints, DatapointsList from cognite.client.testing import monkeypatch_cognite_client from cognite.model_hosting.data_fetcher._cdp_client import CdpClient, DatapointsFrameQuery @pytest.fixture @pytest.fixture @pytest.fixture
31.304348
110
0.659259
import pandas as pd import pytest from cognite.client.data_classes import Datapoints, DatapointsList from cognite.client.testing import monkeypatch_cognite_client from cognite.model_hosting.data_fetcher._cdp_client import CdpClient, DatapointsFrameQuery @pytest.fixture def mock_cogcli_datapoints_retrieve_single(): ...
1,713
0
135
55d1d3e1e8c91e15987eee3a0c33503376cce60d
9,287
py
Python
pygame_project/split_balloon/split_balloon_game.py
bbjoite09/PythonProject
f0ab7a4e6b23758612012ebf7989029e88edf204
[ "MIT" ]
1
2021-04-29T08:18:50.000Z
2021-04-29T08:18:50.000Z
pygame_project/split_balloon/split_balloon_game.py
bbjoite09/PythonProject
f0ab7a4e6b23758612012ebf7989029e88edf204
[ "MIT" ]
1
2021-05-23T16:05:29.000Z
2021-05-23T16:05:29.000Z
pygame_project/split_balloon/split_balloon_game.py
bbjoite09/PythonProject
f0ab7a4e6b23758612012ebf7989029e88edf204
[ "MIT" ]
null
null
null
''' 오락실 pang 게임 만들기 [게임 조건] 1. 캐릭터는 화면 아래에 위치, 좌우로만 이동 가능 2. 스페이스를 누르면 무기를 쏘아 올림 3. 큰 공 1개가 나타나서 바운스 4. 무기에 닿으면 공은 작은 크기 2개로 분할, 가장 작은 크기의 공은 사라짐 5. 모든 공을 없애면 게임 종료(성공) 6. 캐릭터는 공에 닿으면 게임 종료(실패) 7. 시간 제한 99초 초과시 게임 종료(실패) 8. FPS는 30으로 고정(필요시 speed 값을 조정) [게임 이미지] 1. 배경 : 640 * 480(가로, 세로) - background.png 2. 무대 : 640 ...
31.588435
110
0.604824
''' 오락실 pang 게임 만들기 [게임 조건] 1. 캐릭터는 화면 아래에 위치, 좌우로만 이동 가능 2. 스페이스를 누르면 무기를 쏘아 올림 3. 큰 공 1개가 나타나서 바운스 4. 무기에 닿으면 공은 작은 크기 2개로 분할, 가장 작은 크기의 공은 사라짐 5. 모든 공을 없애면 게임 종료(성공) 6. 캐릭터는 공에 닿으면 게임 종료(실패) 7. 시간 제한 99초 초과시 게임 종료(실패) 8. FPS는 30으로 고정(필요시 speed 값을 조정) [게임 이미지] 1. 배경 : 640 * 480(가로, 세로) - background.png 2. 무대 : 640 ...
0
0
0
6738ee449dfe6c373584329dd36f71a082590223
1,845
py
Python
src/roadlr/vgg_post.py
deepguider/RoadGPS
7db4669a54da98a854886b89b6922fb8c7a60f33
[ "Apache-2.0", "BSD-3-Clause" ]
2
2019-05-22T12:47:34.000Z
2019-05-23T15:43:47.000Z
src/roadlr/vgg_post.py
deepguider/RoadGPS
7db4669a54da98a854886b89b6922fb8c7a60f33
[ "Apache-2.0", "BSD-3-Clause" ]
null
null
null
src/roadlr/vgg_post.py
deepguider/RoadGPS
7db4669a54da98a854886b89b6922fb8c7a60f33
[ "Apache-2.0", "BSD-3-Clause" ]
1
2019-08-09T06:50:46.000Z
2019-08-09T06:50:46.000Z
'''VGG11/13/16/19 in Pytorch.''' import torch import torch.nn as nn import torchvision.models as models import torch.nn.functional as F from ipdb import set_trace as bp cfg = { 'VGG16_POST': [512, 512, 'M'] }
38.4375
118
0.552304
'''VGG11/13/16/19 in Pytorch.''' import torch import torch.nn as nn import torchvision.models as models import torch.nn.functional as F from ipdb import set_trace as bp cfg = { 'VGG16_POST': [512, 512, 'M'] } class VGG_POST(nn.Module): def __init__(self, height, width): super(VGG_POST, self).__init__...
1,522
5
103
db034706bef1d18d60d07c19f08ed0864ca128c0
9,352
py
Python
vafator/tests/test_annotator.py
TRON-Bioinformatics/vafator
032b9daeba52b6f560b9b3d428b3eceff541d0ee
[ "MIT" ]
2
2021-10-17T12:50:13.000Z
2021-11-19T06:00:57.000Z
vafator/tests/test_annotator.py
TRON-Bioinformatics/vafator
032b9daeba52b6f560b9b3d428b3eceff541d0ee
[ "MIT" ]
8
2021-10-14T10:25:04.000Z
2022-02-15T21:14:10.000Z
vafator/tests/test_annotator.py
TRON-Bioinformatics/vafator
032b9daeba52b6f560b9b3d428b3eceff541d0ee
[ "MIT" ]
null
null
null
import os import pkg_resources from unittest import TestCase from cyvcf2 import VCF from vafator.annotator import Annotator import vafator.tests.utils as test_utils import time from logzero import logger
53.747126
120
0.710543
import os import pkg_resources from unittest import TestCase from cyvcf2 import VCF from vafator.annotator import Annotator import vafator.tests.utils as test_utils import time from logzero import logger class TestAnnotator(TestCase): def test_annotator(self): input_file = pkg_resources.reso...
8,901
9
228
817c9d802649e5563674be39ac0c3499f6cde805
4,358
py
Python
orio-0.1.0/src/main/tuner/search/exhaustive/exhaustive.py
nn4ip/pluto
92ace2441b6b8d6b66d1bb7ef3e893df4ff23a4d
[ "MIT" ]
183
2017-01-28T17:23:29.000Z
2022-03-25T08:58:56.000Z
orio-0.1.0/src/main/tuner/search/exhaustive/exhaustive.py
nn4ip/pluto
92ace2441b6b8d6b66d1bb7ef3e893df4ff23a4d
[ "MIT" ]
70
2017-03-29T09:51:04.000Z
2021-12-28T07:00:44.000Z
orio-0.1.0/src/main/tuner/search/exhaustive/exhaustive.py
nn4ip/pluto
92ace2441b6b8d6b66d1bb7ef3e893df4ff23a4d
[ "MIT" ]
57
2017-03-29T07:27:58.000Z
2022-01-14T03:13:39.000Z
# # Implementation of the exhaustive search algorithm # import sys, time import main.tuner.search.search #----------------------------------------------------- class Exhaustive(main.tuner.search.search.Search): '''The search engine that uses an exhaustive search approach''' def __init__(self, cfrags, axis_...
36.621849
101
0.544516
# # Implementation of the exhaustive search algorithm # import sys, time import main.tuner.search.search #----------------------------------------------------- class Exhaustive(main.tuner.search.search.Search): '''The search engine that uses an exhaustive search approach''' def __init__(self, cfrags, axis_...
0
0
0
f2dc1850d674cc25fd856fe2c9f15426cb04a079
1,010
py
Python
app.py
Manasi2001/Smart-Irrigation-System
9de4b44256e6f998f7dde0c721ce34bf0000f360
[ "MIT" ]
null
null
null
app.py
Manasi2001/Smart-Irrigation-System
9de4b44256e6f998f7dde0c721ce34bf0000f360
[ "MIT" ]
null
null
null
app.py
Manasi2001/Smart-Irrigation-System
9de4b44256e6f998f7dde0c721ce34bf0000f360
[ "MIT" ]
null
null
null
import os import joblib classifier = joblib.load(r'smartirrigation.pkl') # importing Flask and other modules from flask import Flask, request, render_template import numpy as np # Flask constructor app = Flask(__name__) # A decorator used to tell the application # which URL is associated function...
31.5625
67
0.622772
import os import joblib classifier = joblib.load(r'smartirrigation.pkl') # importing Flask and other modules from flask import Flask, request, render_template import numpy as np # Flask constructor app = Flask(__name__) # A decorator used to tell the application # which URL is associated function...
507
0
23
4f076ea07d8ac8daa548c2e9e7e0dff9a07548bd
4,761
py
Python
bebotPlatform/settings.py
ElitosGon/bebotPlatform
f10b37ecc6cc748a719efc639faa9a2907357682
[ "Apache-2.0" ]
null
null
null
bebotPlatform/settings.py
ElitosGon/bebotPlatform
f10b37ecc6cc748a719efc639faa9a2907357682
[ "Apache-2.0" ]
6
2020-06-05T17:08:29.000Z
2022-03-11T23:14:15.000Z
bebotPlatform/settings.py
ElitosGon/bebotPlatform
f10b37ecc6cc748a719efc639faa9a2907357682
[ "Apache-2.0" ]
null
null
null
""" Django settings for bebotPlatform project. Generated by 'django-admin startproject' using Django 2.0.1. For more information on this file, see https://docs.djangoproject.com/en/2.0/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/2.0/ref/settings/ """ from dj...
26.45
118
0.705944
""" Django settings for bebotPlatform project. Generated by 'django-admin startproject' using Django 2.0.1. For more information on this file, see https://docs.djangoproject.com/en/2.0/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/2.0/ref/settings/ """ from dj...
0
0
0
e19efff62172edb798c2b0bad7a319dbf88a5318
3,862
py
Python
flowsa/Census_CBP.py
cchiq/flowsa
fc21e8da7c3ba66ca4ae4a0c72f568af7ef5e6c0
[ "CC0-1.0" ]
null
null
null
flowsa/Census_CBP.py
cchiq/flowsa
fc21e8da7c3ba66ca4ae4a0c72f568af7ef5e6c0
[ "CC0-1.0" ]
null
null
null
flowsa/Census_CBP.py
cchiq/flowsa
fc21e8da7c3ba66ca4ae4a0c72f568af7ef5e6c0
[ "CC0-1.0" ]
null
null
null
# Census_CBP.py (flowsa) # !/usr/bin/env python3 # coding=utf-8 """ Pulls County Business Patterns data in NAICS from the Census Bureau Writes out to various FlowBySector class files for these data items EMP = Number of employees, Class = Employment PAYANN = Annual payroll ($1,000), Class = Money ESTAB = Number of esta...
38.62
86
0.631538
# Census_CBP.py (flowsa) # !/usr/bin/env python3 # coding=utf-8 """ Pulls County Business Patterns data in NAICS from the Census Bureau Writes out to various FlowBySector class files for these data items EMP = Number of employees, Class = Employment PAYANN = Annual payroll ($1,000), Class = Money ESTAB = Number of esta...
3,124
0
69
5dcd64d4cbce7570663b74758a9b37abc2510d4e
1,363
py
Python
packages/pyright-internal/src/tests/samples/variadicTypeVar2.py
sasano8/pyright
e804f324ee5dbd25fd37a258791b3fd944addecd
[ "MIT" ]
4,391
2019-05-07T01:18:57.000Z
2022-03-31T20:45:44.000Z
packages/pyright-internal/src/tests/samples/variadicTypeVar2.py
sasano8/pyright
e804f324ee5dbd25fd37a258791b3fd944addecd
[ "MIT" ]
2,740
2019-05-07T03:29:30.000Z
2022-03-31T12:57:46.000Z
packages/pyright-internal/src/tests/samples/variadicTypeVar2.py
sasano8/pyright
e804f324ee5dbd25fd37a258791b3fd944addecd
[ "MIT" ]
455
2019-05-07T12:55:14.000Z
2022-03-31T17:09:15.000Z
# This sample tests various conditions under which Unpack # can and cannot be used. # pyright: reportMissingModuleSource=false from typing import Generic, List, Tuple, TypeVar, Union from typing_extensions import TypeVarTuple, Unpack _T = TypeVar("_T") _Xs = TypeVarTuple("_Xs") # This should generate an error. x...
21.296875
63
0.62876
# This sample tests various conditions under which Unpack # can and cannot be used. # pyright: reportMissingModuleSource=false from typing import Generic, List, Tuple, TypeVar, Union from typing_extensions import TypeVarTuple, Unpack _T = TypeVar("_T") _Xs = TypeVarTuple("_Xs") class ClassA(Generic[_T, Unpack[_Xs...
295
411
68
b3129c41be6df0f67c689237bce862f41d0f6489
12,097
py
Python
dockeroo/docker/gentoo_bootstrap.py
dockeroo/dockeroo
6395b4008d0d3d6cabdfec9d52ce448b095fdae1
[ "Apache-2.0" ]
4
2016-07-25T09:21:32.000Z
2022-02-11T19:11:23.000Z
dockeroo/docker/gentoo_bootstrap.py
dockeroo/dockeroo
6395b4008d0d3d6cabdfec9d52ce448b095fdae1
[ "Apache-2.0" ]
null
null
null
dockeroo/docker/gentoo_bootstrap.py
dockeroo/dockeroo
6395b4008d0d3d6cabdfec9d52ce448b095fdae1
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # # Copyright (c) 2016, Giacomo Cariello. 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 # # Un...
42.745583
182
0.630322
# -*- coding: utf-8 -*- # # Copyright (c) 2016, Giacomo Cariello. 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 # # Un...
3,999
84
131
bc5473086318e86d614755dbb30522dfe789f2a8
10,298
py
Python
Apollo.py
heitorsampaio/ApolloAI
c2983ce51c52641453fb1f6e0d7598bdd47ed66d
[ "MIT" ]
null
null
null
Apollo.py
heitorsampaio/ApolloAI
c2983ce51c52641453fb1f6e0d7598bdd47ed66d
[ "MIT" ]
null
null
null
Apollo.py
heitorsampaio/ApolloAI
c2983ce51c52641453fb1f6e0d7598bdd47ed66d
[ "MIT" ]
null
null
null
#!/usr/bin python3 #importing stuffs import speech_recognition as sr import os import sys import re import webbrowser import smtplib import requests import subprocess from pyowm import OWM import youtube_dl import vlc import urllib import urllib3 import json from bs4 import BeautifulSoup as soup from urllib.request i...
32.588608
158
0.578171
#!/usr/bin python3 #importing stuffs import speech_recognition as sr import os import sys import re import webbrowser import smtplib import requests import subprocess from pyowm import OWM import youtube_dl import vlc import urllib import urllib3 import json from bs4 import BeautifulSoup as soup from urllib.request i...
8,734
26
414
77402bae8e8b2c3ce234d1baa57bbcf8550c4e85
1,094
py
Python
lib/xos-synchronizer/xos-synchronizer-tests/test_event_steps/event_step.py
mary-grace/xos
3e269834d29f936757f5091183c9b5188ed5cb9e
[ "Apache-2.0" ]
66
2015-01-29T20:56:45.000Z
2021-07-01T09:56:44.000Z
lib/xos-synchronizer/xos-synchronizer-tests/test_event_steps/event_step.py
mary-grace/xos
3e269834d29f936757f5091183c9b5188ed5cb9e
[ "Apache-2.0" ]
112
2015-01-30T19:59:09.000Z
2017-04-08T16:43:40.000Z
lib/xos-synchronizer/xos-synchronizer-tests/test_event_steps/event_step.py
mary-grace/xos
3e269834d29f936757f5091183c9b5188ed5cb9e
[ "Apache-2.0" ]
66
2015-02-09T17:35:36.000Z
2021-03-24T12:31:19.000Z
# Copyright 2017-present Open Networking Foundation # # 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 agr...
35.290323
81
0.756856
# Copyright 2017-present Open Networking Foundation # # 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 agr...
170
135
23
40ad6cc077d9a49f51d8967b96d2c30ae64493ca
484
py
Python
modules/joinall.py
JohnBishop95/MirahezeBots
4408c65cabac750cd9771f4ed0889f530253bfff
[ "EFL-2.0" ]
null
null
null
modules/joinall.py
JohnBishop95/MirahezeBots
4408c65cabac750cd9771f4ed0889f530253bfff
[ "EFL-2.0" ]
null
null
null
modules/joinall.py
JohnBishop95/MirahezeBots
4408c65cabac750cd9771f4ed0889f530253bfff
[ "EFL-2.0" ]
null
null
null
"""This module implements .joinall.""" from __future__ import ( unicode_literals, absolute_import, print_function, division ) from sopel import module import time @module.require_admin @module.commands('joinall') @module.thread(True) def handle_joins(bot, trigger): """Join some channels.""" ...
19.36
39
0.669421
"""This module implements .joinall.""" from __future__ import ( unicode_literals, absolute_import, print_function, division ) from sopel import module import time @module.require_admin @module.commands('joinall') @module.thread(True) def handle_joins(bot, trigger): """Join some channels.""" ...
0
0
0
2c158777c33cf24c011d63203509380559f6719a
2,052
py
Python
application/py/crolling.py
MaengJowan/bookshare
aee23df229e67961a2cb92526ac74d2563287fb0
[ "MIT" ]
null
null
null
application/py/crolling.py
MaengJowan/bookshare
aee23df229e67961a2cb92526ac74d2563287fb0
[ "MIT" ]
null
null
null
application/py/crolling.py
MaengJowan/bookshare
aee23df229e67961a2cb92526ac74d2563287fb0
[ "MIT" ]
null
null
null
import requests import json from bs4 import BeautifulSoup import sys word = sys.argv[1] word = word.strip().replace("&", "+") main()
31.569231
142
0.634016
import requests import json from bs4 import BeautifulSoup import sys word = sys.argv[1] word = word.strip().replace("&", "+") def get_coverImg(url): result=requests.get(url) soup = BeautifulSoup(result.text, 'html.parser') div = soup.find("div", {"id":"divDetailInfo"}) if(div == None): imgUrl = "http://...
1,824
0
92
b247dcd44831854f5cf0ba67245c72b96e7ebb14
1,597
py
Python
WGALP/blocks/load_krakendb_ramdisk.py
redsnic/WGA-LP
1d8f4a85843b4220559e3e5cccaaee8c78e1b452
[ "MIT" ]
5
2021-08-03T17:09:19.000Z
2021-12-14T18:11:02.000Z
WGALP/blocks/load_krakendb_ramdisk.py
redsnic/WGA-LP
1d8f4a85843b4220559e3e5cccaaee8c78e1b452
[ "MIT" ]
null
null
null
WGALP/blocks/load_krakendb_ramdisk.py
redsnic/WGA-LP
1d8f4a85843b4220559e3e5cccaaee8c78e1b452
[ "MIT" ]
null
null
null
# --- default imports --- # --- load utils --- from WGALP.utils.commandLauncher import run_sp from WGALP.step import Step description = """ load kraken_db in a ramdisk """ input_description = """ the position (on disk) of the kraken2 database """ output_description = """ the mounting point of the newly created ramdis...
28.017544
87
0.65623
# --- default imports --- # --- load utils --- from WGALP.utils.commandLauncher import run_sp from WGALP.step import Step description = """ load kraken_db in a ramdisk """ input_description = """ the position (on disk) of the kraken2 database """ output_description = """ the mounting point of the newly created ramdis...
342
0
22
c40972a4bff7bb3ccdd36b0d87f0b2f304adfe8b
1,166
py
Python
src/toil/utils/toilDestroyCluster.py
YeoLab/toil
9837c396b946bc4a0cf97e7c2705e5892b88707b
[ "Apache-2.0" ]
null
null
null
src/toil/utils/toilDestroyCluster.py
YeoLab/toil
9837c396b946bc4a0cf97e7c2705e5892b88707b
[ "Apache-2.0" ]
1
2017-07-31T23:47:25.000Z
2017-07-31T23:47:25.000Z
src/toil/utils/toilDestroyCluster.py
lexentbio/toil
6ad3813af4450962d0899aa6c821189f86472ef9
[ "Apache-2.0" ]
1
2020-09-17T17:49:32.000Z
2020-09-17T17:49:32.000Z
# Copyright (C) 2015 UCSC Computational Genomics Lab # # 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 o...
35.333333
74
0.766724
# Copyright (C) 2015 UCSC Computational Genomics Lab # # 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 o...
268
0
23
0c4337a0ad68810e4d3b72feb11fc8e929ff526c
778
py
Python
Muzact/app.py
Vikash-Kothary/hackathon-project-muzact
f5fdc8537faeda691dccdccc79d45a153c2dbab6
[ "MIT" ]
null
null
null
Muzact/app.py
Vikash-Kothary/hackathon-project-muzact
f5fdc8537faeda691dccdccc79d45a153c2dbab6
[ "MIT" ]
null
null
null
Muzact/app.py
Vikash-Kothary/hackathon-project-muzact
f5fdc8537faeda691dccdccc79d45a153c2dbab6
[ "MIT" ]
null
null
null
from flask import Flask, request import requests, json app = Flask(__name__) @app.route('/shazam', methods=['GET', 'POST']) @app.route('/') if __name__ == '__main__': app.run('0.0.0.0', debug = 'True')
28.814815
74
0.661954
from flask import Flask, request import requests, json app = Flask(__name__) @app.route('/shazam', methods=['GET', 'POST']) @app.route('/') def index(): if request.method == 'POST': return "{'artist':'Taylor Swift', 'song':'style'}" # return shazam_request(request.data) return 'Hello World' def shazam_reque...
523
0
46
ed5972ed81f4bea34843be0060bc2e8cdc364c2f
2,287
py
Python
Decimal_to_Binary_Converter.py
jerryhcooke/Decimal-Binary-Converter
6ee6d47b33418f65dbcbbaa67b7e2da3c94f9063
[ "MIT" ]
null
null
null
Decimal_to_Binary_Converter.py
jerryhcooke/Decimal-Binary-Converter
6ee6d47b33418f65dbcbbaa67b7e2da3c94f9063
[ "MIT" ]
null
null
null
Decimal_to_Binary_Converter.py
jerryhcooke/Decimal-Binary-Converter
6ee6d47b33418f65dbcbbaa67b7e2da3c94f9063
[ "MIT" ]
null
null
null
# A converter that takes a denary number and converts it, using comparison # rather than recursion, to binary import sys from colorama import init from termcolor import cprint from pyfiglet import figlet_format init(strip=not sys.stdout.isatty()) cprint(figlet_format('Binary / Decimal Converter', font='doom'), 'whit...
31.763889
79
0.615216
# A converter that takes a denary number and converts it, using comparison # rather than recursion, to binary import sys from colorama import init from termcolor import cprint from pyfiglet import figlet_format init(strip=not sys.stdout.isatty()) cprint(figlet_format('Binary / Decimal Converter', font='doom'), 'whit...
847
0
69
0fc69002b14a34c3e184479e98b73ecbe4f4b141
2,341
py
Python
appliedpy_ecourse/class7/ex2_models.py
fallenfuzz/pynet
9624d83cca160fd325a34e838e4474c9b80fe2ab
[ "Apache-2.0" ]
528
2015-01-07T15:28:51.000Z
2022-03-27T09:45:37.000Z
appliedpy_ecourse/class7/ex2_models.py
fallenfuzz/pynet
9624d83cca160fd325a34e838e4474c9b80fe2ab
[ "Apache-2.0" ]
19
2015-07-01T23:52:27.000Z
2021-09-22T04:30:34.000Z
appliedpy_ecourse/class7/ex2_models.py
fallenfuzz/pynet
9624d83cca160fd325a34e838e4474c9b80fe2ab
[ "Apache-2.0" ]
555
2015-01-18T07:21:43.000Z
2022-03-20T21:25:22.000Z
''' Add an SnmpCredentials model to the models.py file. This model should support both SNMPv3 and SNMPv1/v2c. Add a foreign key reference in the NetworkDevice model pointing to the SnmpCredentials model. ''' from django.db import models
48.770833
80
0.699701
''' Add an SnmpCredentials model to the models.py file. This model should support both SNMPv3 and SNMPv1/v2c. Add a foreign key reference in the NetworkDevice model pointing to the SnmpCredentials model. ''' from django.db import models class Credentials(models.Model): username = models.CharField(max_le...
126
1,905
69
d168eea59a42d588125683162b3e1f7ba5c1b21c
988
py
Python
epics/devices/ad_image.py
juanfem/pyepics
6ced9237aa51e306a48057be0f80b08e44dbf0ae
[ "OML" ]
55
2015-05-09T14:42:51.000Z
2022-02-21T19:53:06.000Z
epics/devices/ad_image.py
juanfem/pyepics
6ced9237aa51e306a48057be0f80b08e44dbf0ae
[ "OML" ]
192
2015-01-22T16:36:41.000Z
2022-02-09T17:19:17.000Z
epics/devices/ad_image.py
juanfem/pyepics
6ced9237aa51e306a48057be0f80b08e44dbf0ae
[ "OML" ]
43
2015-09-15T20:55:02.000Z
2022-02-21T19:53:07.000Z
from .. import Device class AD_ImagePlugin(Device): """ AreaDetector Image Plugin """ attrs = ('ArrayData', 'UniqueId', 'UniqueId_RBV', 'NDimensions', 'NDimensions_RBV', 'ArraySize0', 'ArraySize0_RBV', 'ArraySize1', 'ArraySize1_RBV', 'Arr...
30.875
69
0.572874
from .. import Device class AD_ImagePlugin(Device): """ AreaDetector Image Plugin """ attrs = ('ArrayData', 'UniqueId', 'UniqueId_RBV', 'NDimensions', 'NDimensions_RBV', 'ArraySize0', 'ArraySize0_RBV', 'ArraySize1', 'ArraySize1_RBV', 'Arr...
111
0
27
6327f2a9bb703904fc001768cbf7a0f87cd749ea
4,196
py
Python
script/tazerUtil/serverUtil.py
jstrube/tazer
18a6d66ad2c20376609f1af7940e43b2031e4fd0
[ "BSD-3-Clause" ]
null
null
null
script/tazerUtil/serverUtil.py
jstrube/tazer
18a6d66ad2c20376609f1af7940e43b2031e4fd0
[ "BSD-3-Clause" ]
null
null
null
script/tazerUtil/serverUtil.py
jstrube/tazer
18a6d66ad2c20376609f1af7940e43b2031e4fd0
[ "BSD-3-Clause" ]
null
null
null
import subprocess as sp from . import util # This is a Tazer Server class. It is here to help wrap several functions that # exist across the Tazer source. The Commands listed in the arguments are the # equivalent commands (and arguments) as if run from the build tree. # The path is the path to the build director...
41.137255
99
0.637274
import subprocess as sp from . import util # This is a Tazer Server class. It is here to help wrap several functions that # exist across the Tazer source. The Commands listed in the arguments are the # equivalent commands (and arguments) as if run from the build tree. class TazerServer: # The path is the path to...
2,419
-3
230
903d6526666ce50546bae687fd6815485193c917
915
py
Python
altstreamfield/utils.py
didorothy/wagtailaltstreamfield
00b6be4420e031036f1d2d6c0122969df7fb3900
[ "BSD-2-Clause" ]
null
null
null
altstreamfield/utils.py
didorothy/wagtailaltstreamfield
00b6be4420e031036f1d2d6c0122969df7fb3900
[ "BSD-2-Clause" ]
20
2019-11-12T16:49:32.000Z
2021-03-09T23:04:20.000Z
altstreamfield/utils.py
didorothy/wagtailaltstreamfield
00b6be4420e031036f1d2d6c0122969df7fb3900
[ "BSD-2-Clause" ]
null
null
null
from django.forms.widgets import Media def get_class_media(base, instance): '''Convenience function to be used when overriding the `media` property. This function maintains the tasks of the media property set up by `MediaDefiningClass` but allows you to extend the normal behavior. Use: class MyCl...
31.551724
76
0.571585
from django.forms.widgets import Media def get_class_media(base, instance): '''Convenience function to be used when overriding the `media` property. This function maintains the tasks of the media property set up by `MediaDefiningClass` but allows you to extend the normal behavior. Use: class MyCl...
0
0
0
b553b1daf5dcad704f72c521e15d5d3492a81839
1,158
py
Python
tests/functional_tests/pool/open_pool_ledger_with_valid_data_test.py
wYaobiz/indy-test-suite
7b4a3f9bb73e5830fea17a158dc0fc96ab29ac32
[ "Apache-2.0" ]
1
2021-07-26T14:19:07.000Z
2021-07-26T14:19:07.000Z
tests/functional_tests/pool/open_pool_ledger_with_valid_data_test.py
wYaobiz/indy-test-suite
7b4a3f9bb73e5830fea17a158dc0fc96ab29ac32
[ "Apache-2.0" ]
null
null
null
tests/functional_tests/pool/open_pool_ledger_with_valid_data_test.py
wYaobiz/indy-test-suite
7b4a3f9bb73e5830fea17a158dc0fc96ab29ac32
[ "Apache-2.0" ]
null
null
null
from indy import pool from utilities import utils from utilities import common, constant from test_scripts.functional_tests.pool.pool_test_base import PoolTestBase import pytest
39.931034
75
0.662349
from indy import pool from utilities import utils from utilities import common, constant from test_scripts.functional_tests.pool.pool_test_base import PoolTestBase import pytest class TestOpenPoolLedgerConfig(PoolTestBase): @pytest.mark.asyncio async def test(self): # 1. Create pool ledger configura...
879
76
23
d9fe82a160d5b6f40eb7f848610280b2b907fd7b
1,213
py
Python
examples/reference/models/select_server.py
g-parki/bokeh
664ead5306bba64609e734d4105c8aa8cfb76d81
[ "BSD-3-Clause" ]
15,193
2015-01-01T05:11:45.000Z
2022-03-31T19:30:20.000Z
examples/reference/models/select_server.py
g-parki/bokeh
664ead5306bba64609e734d4105c8aa8cfb76d81
[ "BSD-3-Clause" ]
9,554
2015-01-01T03:16:54.000Z
2022-03-31T22:59:39.000Z
examples/reference/models/select_server.py
g-parki/bokeh
664ead5306bba64609e734d4105c8aa8cfb76d81
[ "BSD-3-Clause" ]
4,829
2015-01-02T03:35:32.000Z
2022-03-30T16:40:26.000Z
## Bokeh server for Select import pandas as pd from bokeh.io import curdoc from bokeh.layouts import row from bokeh.models import ColumnDataSource, Select from bokeh.plotting import figure x=[3,4,6,12,10,1,5,6,3,8] y=[7,1,3,4,1,6,10,4,10,3] label=['Red', 'Orange', 'Red', 'Orange','Red', 'Orange','Red', 'Orange','Red'...
29.585366
93
0.695796
## Bokeh server for Select import pandas as pd from bokeh.io import curdoc from bokeh.layouts import row from bokeh.models import ColumnDataSource, Select from bokeh.plotting import figure x=[3,4,6,12,10,1,5,6,3,8] y=[7,1,3,4,1,6,10,4,10,3] label=['Red', 'Orange', 'Red', 'Orange','Red', 'Orange','Red', 'Orange','Red'...
319
0
23
da1d50a4f230ab93ab71b745cfeb7b321c903875
1,055
py
Python
src/sample/corpus_extraction_sklearn.py
humanist96/kmorph
0fc9ccdf77847de9602ca0c7f428e9dbb813b984
[ "Apache-2.0" ]
null
null
null
src/sample/corpus_extraction_sklearn.py
humanist96/kmorph
0fc9ccdf77847de9602ca0c7f428e9dbb813b984
[ "Apache-2.0" ]
null
null
null
src/sample/corpus_extraction_sklearn.py
humanist96/kmorph
0fc9ccdf77847de9602ca0c7f428e9dbb813b984
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- from sklearn.feature_extraction.text import CountVectorizer from natto import MeCab _morpheme_type = ['NNG', 'NNP'] _escape_pattern = ['\n'] _nm = MeCab() corpus = generate_corpus2('news.txt') print('corpus : ', corpus) _cv = CountVectorizer() word_matrix = _cv.fit_transform(corpus) inde...
23.977273
59
0.627488
# -*- coding: utf-8 -*- from sklearn.feature_extraction.text import CountVectorizer from natto import MeCab _morpheme_type = ['NNG', 'NNP'] _escape_pattern = ['\n'] _nm = MeCab() def filter_by_type(text): terms = [] for term_info in str(_nm.parse(text)).split('\n'): _term_info = term_info.split('\t...
573
0
46
03eae6ce95f068bc2d9cb82135f48b30fa2fa332
2,894
py
Python
UIBox/item.py
yemenPython/TheBossBaby
86e447b3fa360646a179e62c70b1750da5427541
[ "MIT" ]
1
2021-12-16T16:31:29.000Z
2021-12-16T16:31:29.000Z
UIBox/item.py
yemenPython/TheBossBaby
86e447b3fa360646a179e62c70b1750da5427541
[ "MIT" ]
null
null
null
UIBox/item.py
yemenPython/TheBossBaby
86e447b3fa360646a179e62c70b1750da5427541
[ "MIT" ]
1
2021-12-16T16:31:35.000Z
2021-12-16T16:31:35.000Z
#!/usr/bin/python3 from PyQt5 import QtCore, QtGui, QtWidgets
36.632911
104
0.653766
#!/usr/bin/python3 from PyQt5 import QtCore, QtGui, QtWidgets class UIBUi_Item(QtWidgets.QWidget): def __init__(self): super(UIBUi_Item, self).__init__() self.setObjectName("Form") self.setMouseTracking(True) self.gridLayout_2 = QtWidgets.QGridLayout(self) self.gridLayout...
2,740
15
76
64abab9832222fe0a8a6331f331b74645977e71e
5,313
py
Python
sentenceSpliter.py
neerbek/taboo-mon
3dc74fd38b112531db8b5f696ed92b894cc0a3b3
[ "MIT" ]
1
2021-05-10T00:27:10.000Z
2021-05-10T00:27:10.000Z
sentenceSpliter.py
neerbek/taboo-mon
3dc74fd38b112531db8b5f696ed92b894cc0a3b3
[ "MIT" ]
null
null
null
sentenceSpliter.py
neerbek/taboo-mon
3dc74fd38b112531db8b5f696ed92b894cc0a3b3
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on April 12, 2018 @author: neerbek """ import os import getopt import sys import io import monUtil import monsantoData import textClean import server_rnn_helper from similarity import load_trees from importlib import reload reload(textClean) # from backends import PDFMinerBack...
31.070175
153
0.652174
# -*- coding: utf-8 -*- """ Created on April 12, 2018 @author: neerbek """ import os import getopt import sys import io import monUtil import monsantoData import textClean import server_rnn_helper from similarity import load_trees from importlib import reload reload(textClean) # from backends import PDFMinerBack...
143
0
23
c11bc4ddc779cc37ccba80a70677f0703b4a7cf3
7,182
py
Python
scoring/fields.py
stkrizh/otus
6bff5cf62661bb7bab6eac6cb563a63a52a56423
[ "MIT" ]
1
2021-07-25T11:11:55.000Z
2021-07-25T11:11:55.000Z
scoring/fields.py
stkrizh/otus
6bff5cf62661bb7bab6eac6cb563a63a52a56423
[ "MIT" ]
3
2020-03-24T17:33:29.000Z
2021-08-23T20:20:31.000Z
scoring/fields.py
stkrizh/otus
6bff5cf62661bb7bab6eac6cb563a63a52a56423
[ "MIT" ]
null
null
null
import datetime as dt import re class Field(object): """Base class for fields validation. Attributes ---------- allowed_type : Optional[type or Tuple[type]] Allowed field's type. Parameters ---------- label: Optional[unicode] Name of the field. required : bool ...
25.378092
79
0.574353
import datetime as dt import re class ValidationError(Exception): pass class Field(object): """Base class for fields validation. Attributes ---------- allowed_type : Optional[type or Tuple[type]] Allowed field's type. Parameters ---------- label: Optional[unicode] N...
2,662
21
372
b2dc8eb7563fbeae7c3260ea4983e67be1ebdf31
974
py
Python
Ex028.py
andrade-lcs/ex_curso_em_video_python
f2d029efe7a20cdf0fcb5b602f9992e27d37c263
[ "MIT" ]
null
null
null
Ex028.py
andrade-lcs/ex_curso_em_video_python
f2d029efe7a20cdf0fcb5b602f9992e27d37c263
[ "MIT" ]
null
null
null
Ex028.py
andrade-lcs/ex_curso_em_video_python
f2d029efe7a20cdf0fcb5b602f9992e27d37c263
[ "MIT" ]
null
null
null
#t=int(input('Quantos anos tem seu carro?')) #if t <=3: # print('Carro novo') #else: # print('Carro velho') #print('Carro novo' if t<=3 else 'Carro velho') #print('fim') # print('Que nome lindo') #print('Bom dia, {}'.format(n)) #print('fim') #_____________________________ import random from time import sleep c ...
30.4375
90
0.616016
#t=int(input('Quantos anos tem seu carro?')) #if t <=3: # print('Carro novo') #else: # print('Carro velho') #print('Carro novo' if t<=3 else 'Carro velho') #print('fim') # print('Que nome lindo') #print('Bom dia, {}'.format(n)) #print('fim') #_____________________________ import random from time import sleep c ...
0
0
0
eb225baa26daf67586d587e4ced2d1f3464104dc
5,232
py
Python
daluke/plot/plot_finetune_ner.py
peleiden/daluke
d2c85ba6b80021b2959b369381c447d18b058576
[ "MIT" ]
10
2021-07-06T08:31:45.000Z
2021-12-17T09:13:33.000Z
daluke/plot/plot_finetune_ner.py
peleiden/daLUKE
d2c85ba6b80021b2959b369381c447d18b058576
[ "MIT" ]
70
2021-03-26T13:30:39.000Z
2021-06-10T15:06:36.000Z
daluke/plot/plot_finetune_ner.py
peleiden/daluke
d2c85ba6b80021b2959b369381c447d18b058576
[ "MIT" ]
null
null
null
from __future__ import annotations import os import click from pelutils.logger import log from pelutils.ds.plot import figsize_std, tab_colours, update_rc_params, rc_params import matplotlib.pyplot as plt from matplotlib.lines import Line2D import numpy as np from daluke.ner.training import TrainResults from daluke....
37.106383
183
0.661888
from __future__ import annotations import os import click from pelutils.logger import log from pelutils.ds.plot import figsize_std, tab_colours, update_rc_params, rc_params import matplotlib.pyplot as plt from matplotlib.lines import Line2D import numpy as np from daluke.ner.training import TrainResults from daluke....
4,613
0
114
06fdf5dfdb4933696507f332998511229cae25be
833
py
Python
VSCode_work/chapter10/chapter10_10_10.py
yangyahu-1994/Python-Crash-Course
6f8ef7fe8466d88931a0d3cc423ba5d966663b9d
[ "MIT" ]
12
2020-10-22T14:03:27.000Z
2022-03-28T08:14:22.000Z
VSCode_work/chapter10/chapter10_10_10.py
yangyahu-1994/Python-Crash-Course
6f8ef7fe8466d88931a0d3cc423ba5d966663b9d
[ "MIT" ]
null
null
null
VSCode_work/chapter10/chapter10_10_10.py
yangyahu-1994/Python-Crash-Course
6f8ef7fe8466d88931a0d3cc423ba5d966663b9d
[ "MIT" ]
9
2020-12-22T10:22:12.000Z
2022-03-28T08:14:53.000Z
# 定义函数 def count_numbers(filename): """获取指定的文件,并计算单词'the'在每个文件中出现的次数""" try: with open(filename) as file_object: contents = file_object.read() except FileNotFoundError: print(f"Sorry, the file {filename} does not exits.") else: # 计算出现的次数 numbers = contents.low...
41.65
115
0.683073
# 定义函数 def count_numbers(filename): """获取指定的文件,并计算单词'the'在每个文件中出现的次数""" try: with open(filename) as file_object: contents = file_object.read() except FileNotFoundError: print(f"Sorry, the file {filename} does not exits.") else: # 计算出现的次数 numbers = contents.low...
0
0
0
01db368e89b0bf8334c4f381333f9897fa93f294
793
py
Python
apps/article/tests/article/test_article_list.py
magocod/django_repository
660664ba2321499e92c3c5c23719756db2569e90
[ "MIT" ]
1
2019-10-01T01:39:29.000Z
2019-10-01T01:39:29.000Z
apps/article/tests/article/test_article_list.py
magocod/django_repository
660664ba2321499e92c3c5c23719756db2569e90
[ "MIT" ]
7
2019-12-04T21:40:40.000Z
2020-06-26T21:49:51.000Z
apps/article/tests/article/test_article_list.py
magocod/django_repository
660664ba2321499e92c3c5c23719756db2569e90
[ "MIT" ]
1
2020-04-08T02:46:31.000Z
2020-04-08T02:46:31.000Z
# standard library import json # local Django from apps.article.models import Article from apps.article.serializers.article import ArticleHeavySerializer from apps.tests.fixtures import RepositoryTestCase class ListArticleTest(RepositoryTestCase): """ ... """ serializer = ArticleHeavySerializer
29.37037
71
0.727617
# standard library import json # local Django from apps.article.models import Article from apps.article.serializers.article import ArticleHeavySerializer from apps.tests.fixtures import RepositoryTestCase class ListArticleTest(RepositoryTestCase): """ ... """ serializer = ArticleHeavySerializer ...
423
0
54
93787bb0da83949daeb1c9f0fd9a21dd757d69bd
275
py
Python
ai/games/random_ai_game.py
JonKruger/checkers
8cc1390fcb69c1af15ac740fb3321aea7357f5d0
[ "MIT" ]
null
null
null
ai/games/random_ai_game.py
JonKruger/checkers
8cc1390fcb69c1af15ac740fb3321aea7357f5d0
[ "MIT" ]
null
null
null
ai/games/random_ai_game.py
JonKruger/checkers
8cc1390fcb69c1af15ac740fb3321aea7357f5d0
[ "MIT" ]
null
null
null
from ai.players.random_ai_player import RandomAIPlayer from ai.games.ai_game import AIGame from checkers.game import Game import random
30.555556
70
0.781818
from ai.players.random_ai_player import RandomAIPlayer from ai.games.ai_game import AIGame from checkers.game import Game import random class RandomAIGame(AIGame): def __init__(self, verbose=False): super().__init__(RandomAIPlayer(), RandomAIPlayer(), verbose)
83
6
50
e3fac1b3c3b5a1717c6d26e6cb738d1ed4d5e6c2
8,281
py
Python
syne_tune/optimizer/schedulers/transfer_learning/zero_shot.py
awslabs/syne-tune
1dd8e157477b86db01047a9a7821780ea04389bc
[ "ECL-2.0", "Apache-2.0" ]
97
2021-11-18T17:14:30.000Z
2022-03-29T00:33:12.000Z
syne_tune/optimizer/schedulers/transfer_learning/zero_shot.py
awslabs/syne-tune
1dd8e157477b86db01047a9a7821780ea04389bc
[ "ECL-2.0", "Apache-2.0" ]
54
2021-11-18T17:14:12.000Z
2022-03-22T08:11:48.000Z
syne_tune/optimizer/schedulers/transfer_learning/zero_shot.py
awslabs/syne-tune
1dd8e157477b86db01047a9a7821780ea04389bc
[ "ECL-2.0", "Apache-2.0" ]
9
2021-11-29T11:47:32.000Z
2022-02-24T15:28:11.000Z
# Copyright 2021 Amazon.com, Inc. or its affiliates. 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. # A copy of the License is located at # # http://www.apache.org/licenses/LICENSE-2.0 # # or in the "license...
44.762162
120
0.662601
# Copyright 2021 Amazon.com, Inc. or its affiliates. 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. # A copy of the License is located at # # http://www.apache.org/licenses/LICENSE-2.0 # # or in the "license...
1,129
6,085
23
5a21299c7960ef147aa799e8ad8d4e56f46263b8
423
py
Python
copymaks.py
LittleQBerry/sklearn-logist
4ed208547b9d93171a8da14d3d010ec721cd17fa
[ "MIT" ]
null
null
null
copymaks.py
LittleQBerry/sklearn-logist
4ed208547b9d93171a8da14d3d010ec721cd17fa
[ "MIT" ]
null
null
null
copymaks.py
LittleQBerry/sklearn-logist
4ed208547b9d93171a8da14d3d010ec721cd17fa
[ "MIT" ]
null
null
null
import os from shutil import copyfile from os import listdir save_dir =r'J:/game/seg_classification/data/' imgs_dir =r'J:/game/seg_classification/_ouput_dir_/' if not os.path.isdir(save_dir): os.makedirs(save_dir) for files in listdir(imgs_dir): if files[-5] =='0': source_file=os.path.join(imgs_dir ...
22.263158
52
0.718676
import os from shutil import copyfile from os import listdir save_dir =r'J:/game/seg_classification/data/' imgs_dir =r'J:/game/seg_classification/_ouput_dir_/' if not os.path.isdir(save_dir): os.makedirs(save_dir) for files in listdir(imgs_dir): if files[-5] =='0': source_file=os.path.join(imgs_dir ...
0
0
0
c313d884667195d72422dcbdf27ccb9ddfa77912
3,927
py
Python
haiku/_src/random_test.py
rushic24/dm-haiku
8ee1a2125587831783ae7ae1e74baacec23ae56d
[ "Apache-2.0" ]
null
null
null
haiku/_src/random_test.py
rushic24/dm-haiku
8ee1a2125587831783ae7ae1e74baacec23ae56d
[ "Apache-2.0" ]
null
null
null
haiku/_src/random_test.py
rushic24/dm-haiku
8ee1a2125587831783ae7ae1e74baacec23ae56d
[ "Apache-2.0" ]
null
null
null
# Copyright 2019 DeepMind Technologies Limited. 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 ...
32.188525
80
0.66794
# Copyright 2019 DeepMind Technologies Limited. 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 ...
2,625
33
269
6a6b82dcc5b09f38955912cdd231dfc079e2215b
319
py
Python
csf_tz/after_sales_services/doctype/requested_payments/requested_payments_dashboard.py
Craftint/CSF_TZ
b5cb2d59d8f4e958ad7d4cb89421cfbec992abc5
[ "MIT" ]
null
null
null
csf_tz/after_sales_services/doctype/requested_payments/requested_payments_dashboard.py
Craftint/CSF_TZ
b5cb2d59d8f4e958ad7d4cb89421cfbec992abc5
[ "MIT" ]
null
null
null
csf_tz/after_sales_services/doctype/requested_payments/requested_payments_dashboard.py
Craftint/CSF_TZ
b5cb2d59d8f4e958ad7d4cb89421cfbec992abc5
[ "MIT" ]
1
2022-03-17T22:49:40.000Z
2022-03-17T22:49:40.000Z
from frappe import _
16.789474
50
0.579937
from frappe import _ def get_data(): return { 'fieldname': 're', 'non_standard_fieldnames': { 'Payment Entry': 'reference_name' }, 'internal_links': { 'Sales Order': ['references', 'reference_name'] }, 'transactions': [ { 'label': _('Payments'), 'items': ['Payment Entry'] } ] }
275
0
23
d7b4ca7a20b08e02e79aa7bd12cd25a873780374
3,180
py
Python
najdisi_sms/cli.py
brodul/najdi-si-sms
a73c2bfb55bcf7e2bfb4a75f50adff166873c6ed
[ "BSD-3-Clause" ]
5
2016-01-08T21:35:21.000Z
2018-10-11T08:59:21.000Z
najdisi_sms/cli.py
brodul/najdi-si-sms
a73c2bfb55bcf7e2bfb4a75f50adff166873c6ed
[ "BSD-3-Clause" ]
4
2016-01-09T14:30:33.000Z
2017-09-16T17:39:49.000Z
najdisi_sms/cli.py
brodul/najdi-si-sms
a73c2bfb55bcf7e2bfb4a75f50adff166873c6ed
[ "BSD-3-Clause" ]
2
2017-09-08T21:45:25.000Z
2018-10-16T11:55:13.000Z
from argparse import ArgumentParser import os import sys from six.moves.configparser import ConfigParser from najdisi_sms import utils from .api import SMSSender log = utils.get_logger() class SettingParser(object): """docstring for SettingParser""" def merge_settings(self, parser_space): """ ...
27.179487
70
0.545597
from argparse import ArgumentParser import os import sys from six.moves.configparser import ConfigParser from najdisi_sms import utils from .api import SMSSender log = utils.get_logger() class SettingParser(object): """docstring for SettingParser""" def __init__(self, args=None): self.args = args o...
2,108
0
134
93045327b67530baa933c410a2531ed53bd0fbbd
6,484
py
Python
utils/metrics.py
Hua-YS/Multi-Scene-Recognition
5c3db2a893221a1b49482675ac5f03532edd4f85
[ "MIT" ]
5
2021-06-28T12:49:38.000Z
2021-09-07T11:21:29.000Z
utils/metrics.py
Hua-YS/Multi-Scene-Recognition
5c3db2a893221a1b49482675ac5f03532edd4f85
[ "MIT" ]
null
null
null
utils/metrics.py
Hua-YS/Multi-Scene-Recognition
5c3db2a893221a1b49482675ac5f03532edd4f85
[ "MIT" ]
2
2021-07-19T09:19:11.000Z
2021-11-07T20:25:04.000Z
""" Modified from ML-GCN/util.py: * adding calculations: OP, OR, OF1, CP, CR, CF1, EP, ER, EF1 * removing args: difficult_examples """ import math import torch from PIL import Image from tqdm import tqdm import numpy as np import random import torch.nn.functional as F
35.048649
111
0.549352
""" Modified from ML-GCN/util.py: * adding calculations: OP, OR, OF1, CP, CR, CF1, EP, ER, EF1 * removing args: difficult_examples """ import math import torch from PIL import Image from tqdm import tqdm import numpy as np import random import torch.nn.functional as F class AveragePrecisionMeter(object): def __i...
1,316
4,872
24
c8983a64630f30f7f21c9bbdaa9a782c0bbb3db8
3,862
py
Python
compmatscipy/MyStats.py
YunyeongChoi/compmatscipy
44d0fe9f4d3806a21ee3bfcbca24b42120d91193
[ "MIT" ]
5
2019-08-19T14:48:31.000Z
2022-03-24T20:08:31.000Z
compmatscipy/MyStats.py
YunyeongChoi/compmatscipy
44d0fe9f4d3806a21ee3bfcbca24b42120d91193
[ "MIT" ]
1
2019-08-24T16:51:29.000Z
2019-08-24T16:51:29.000Z
compmatscipy/MyStats.py
YunyeongChoi/compmatscipy
44d0fe9f4d3806a21ee3bfcbca24b42120d91193
[ "MIT" ]
5
2019-07-16T19:15:28.000Z
2021-03-29T04:49:54.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Tue Aug 6 12:05:46 2019 @author: chrisbartel """ import numpy as np from sklearn.metrics import confusion_matrix, r2_score
31.145161
95
0.56318
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Tue Aug 6 12:05:46 2019 @author: chrisbartel """ import numpy as np from sklearn.metrics import confusion_matrix, r2_score def _make_binary_labels(data, thresh): return [1 if v <= thresh else 0 for v in data] class MyStats(object): def __ini...
2,860
770
46
471a892d7e1469bc55d6a5fb681247474418f271
2,531
py
Python
ceph_deploy/hosts/suse/install.py
zidarsk8/ceph-deploy
e286d7d0cf6e161708909c91ea7f99aacf08c7c4
[ "MIT" ]
1
2018-01-03T03:13:24.000Z
2018-01-03T03:13:24.000Z
ceph_deploy/hosts/suse/install.py
zidarsk8/ceph-deploy
e286d7d0cf6e161708909c91ea7f99aacf08c7c4
[ "MIT" ]
null
null
null
ceph_deploy/hosts/suse/install.py
zidarsk8/ceph-deploy
e286d7d0cf6e161708909c91ea7f99aacf08c7c4
[ "MIT" ]
null
null
null
from ceph_deploy.util import templates from ceph_deploy.lib.remoto import process
25.31
112
0.453971
from ceph_deploy.util import templates from ceph_deploy.lib.remoto import process def install(distro, version_kind, version, adjust_repos): release = distro.release machine = distro.machine_type if version_kind in ['stable', 'testing']: key = 'release' else: key = 'autobuild' if ...
2,401
0
46
74891ac87248010c5d11d2a67dbd35f68b342069
29
py
Python
examples/class_trivial.py
doboy/Underscore
d98273db3144cda79191d2c90f45d81b6d700b1f
[ "MIT" ]
7
2016-09-23T00:44:05.000Z
2021-10-04T21:19:12.000Z
examples/class_trivial.py
jameswu1991/Underscore
d98273db3144cda79191d2c90f45d81b6d700b1f
[ "MIT" ]
1
2016-09-23T00:45:05.000Z
2019-02-16T19:05:37.000Z
examples/class_trivial.py
jameswu1991/Underscore
d98273db3144cda79191d2c90f45d81b6d700b1f
[ "MIT" ]
3
2016-09-23T01:13:15.000Z
2018-07-20T21:22:17.000Z
Bar()
5.8
12
0.517241
class Bar(): pass Bar()
0
0
22
983347675b3f89295d6d1c7b7c4125a61b2ca029
771
py
Python
project_euler/problem_13/sol1.py
ming-nju/Python_learn
a0d31fe79310ed636047b1595da04a824394f3bc
[ "MIT" ]
2
2019-07-19T07:45:01.000Z
2019-07-19T07:45:09.000Z
project_euler/problem_13/sol1.py
ming-nju/Python_learn
a0d31fe79310ed636047b1595da04a824394f3bc
[ "MIT" ]
null
null
null
project_euler/problem_13/sol1.py
ming-nju/Python_learn
a0d31fe79310ed636047b1595da04a824394f3bc
[ "MIT" ]
3
2019-04-29T02:36:37.000Z
2019-10-05T12:17:59.000Z
""" Problem Statement: Work out the first ten digits of the sum of the following one-hundred 50-digit numbers. """ from __future__ import print_function import os try: raw_input # Python 2 except NameError: raw_input = input # Python 3 def solution(array): """Returns the first ten digits of the sum of ...
20.837838
78
0.594034
""" Problem Statement: Work out the first ten digits of the sum of the following one-hundred 50-digit numbers. """ from __future__ import print_function import os try: raw_input # Python 2 except NameError: raw_input = input # Python 3 def solution(array): """Returns the first ten digits of the sum of ...
0
0
0
06be20eddfdbb8f127ad0de90c3d9e742d293f5a
2,275
py
Python
extensions/music.py
ggoncalopereira/JBB.py
e66419466cc6d35e134cceb8c8ad48102556658b
[ "MIT" ]
null
null
null
extensions/music.py
ggoncalopereira/JBB.py
e66419466cc6d35e134cceb8c8ad48102556658b
[ "MIT" ]
null
null
null
extensions/music.py
ggoncalopereira/JBB.py
e66419466cc6d35e134cceb8c8ad48102556658b
[ "MIT" ]
1
2020-12-10T23:08:52.000Z
2020-12-10T23:08:52.000Z
import discord from discord.ext import commands import json import subprocess class Music(commands.Cog): """Play all great classics""" @commands.command(name='play', description="play a given music", brief="play a given music") @commands.command(name='stop'...
39.224138
119
0.565714
import discord from discord.ext import commands import json import subprocess class Music(commands.Cog): """Play all great classics""" def __init__(self, bot): self.bot = bot @commands.command(name='play', description="play a given music", brief="play a ...
1,738
0
101
1af70b5c74ac9c6f87ca8ab4ea3b051aa0ade4f9
2,313
py
Python
dmscripts/bulk_upload_documents.py
alphagov-mirror/digitalmarketplace-scripts
8a7ef9b2b5f5fffea6e012bd676b095a27d35101
[ "MIT" ]
1
2020-06-23T01:55:31.000Z
2020-06-23T01:55:31.000Z
dmscripts/bulk_upload_documents.py
alphagov-mirror/digitalmarketplace-scripts
8a7ef9b2b5f5fffea6e012bd676b095a27d35101
[ "MIT" ]
267
2015-10-12T12:43:52.000Z
2021-08-19T10:38:55.000Z
dmscripts/bulk_upload_documents.py
alphagov-mirror/digitalmarketplace-scripts
8a7ef9b2b5f5fffea6e012bd676b095a27d35101
[ "MIT" ]
7
2015-11-11T16:47:41.000Z
2021-04-10T18:03:04.000Z
import re import csv from dmutils.documents import get_document_path, generate_download_filename
36.714286
119
0.707739
import re import csv from dmutils.documents import get_document_path, generate_download_filename def upload_file(bucket, dry_run, file_path, framework_slug, bucket_category, supplier_name_dict=None): # Retrieve the supplier ID from the filepath supplier_id = get_supplier_id_from_framework_file_path(file_path...
2,119
0
92
042b8109e2f671dcb6a5528205ba2a23432c656d
1,200
py
Python
SUAVE/SUAVE-2.5.0/trunk/SUAVE/Methods/Flight_Dynamics/Dynamic_Stability/Full_Linearized_Equations/Supporting_Functions/cm_alphadot.py
Vinicius-Tanigawa/Undergraduate-Research-Project
e92372f07882484b127d7affe305eeec2238b8a9
[ "MIT" ]
null
null
null
SUAVE/SUAVE-2.5.0/trunk/SUAVE/Methods/Flight_Dynamics/Dynamic_Stability/Full_Linearized_Equations/Supporting_Functions/cm_alphadot.py
Vinicius-Tanigawa/Undergraduate-Research-Project
e92372f07882484b127d7affe305eeec2238b8a9
[ "MIT" ]
null
null
null
SUAVE/SUAVE-2.5.0/trunk/SUAVE/Methods/Flight_Dynamics/Dynamic_Stability/Full_Linearized_Equations/Supporting_Functions/cm_alphadot.py
Vinicius-Tanigawa/Undergraduate-Research-Project
e92372f07882484b127d7affe305eeec2238b8a9
[ "MIT" ]
null
null
null
## @ingroup Methods-Flight_Dynamics-Dynamic_Stability-Full_Linearized_Equations-Supporting_Functions # cm_alphadot.py # # Created: Jun 2014, A. Wendorff # Modified: Jan 2016, E. Botero # ---------------------------------------------------------------------- # Method # ----------------------------------------------...
30.769231
100
0.55
## @ingroup Methods-Flight_Dynamics-Dynamic_Stability-Full_Linearized_Equations-Supporting_Functions # cm_alphadot.py # # Created: Jun 2014, A. Wendorff # Modified: Jan 2016, E. Botero # ---------------------------------------------------------------------- # Method # ----------------------------------------------...
0
0
0
d171c4fc232b86e1fa3960aaaa0c13f95e31ee4a
1,697
py
Python
test/application/test_request_assertion_model.py
Ashaba/API-Monitor
533eb6698fcb5decb48f746784af6894844b3c69
[ "MIT" ]
null
null
null
test/application/test_request_assertion_model.py
Ashaba/API-Monitor
533eb6698fcb5decb48f746784af6894844b3c69
[ "MIT" ]
22
2018-02-06T19:53:11.000Z
2021-04-30T20:35:01.000Z
test/application/test_request_assertion_model.py
Ashaba/API-Monitor
533eb6698fcb5decb48f746784af6894844b3c69
[ "MIT" ]
null
null
null
from test.base import BaseTestCase from application.models import RequestAssertion
41.390244
95
0.831467
from test.base import BaseTestCase from application.models import RequestAssertion class TestRequestAssertionModel(BaseTestCase): def setUp(self): super(TestRequestAssertionModel, self).setUp() self.test_request_assertion = RequestAssertion( request_id="1", assertion_type="Status Code", comparison="equ...
1,467
25
121
59a020e72f267e4924a4e2b3801e624ac28cb564
539
py
Python
regex/count_smiley_faces.py
ahmedelq/PythonicAlgorithms
ce10dbb6e1fd0ea5c922a932b0f920236aa411bf
[ "MIT" ]
null
null
null
regex/count_smiley_faces.py
ahmedelq/PythonicAlgorithms
ce10dbb6e1fd0ea5c922a932b0f920236aa411bf
[ "MIT" ]
null
null
null
regex/count_smiley_faces.py
ahmedelq/PythonicAlgorithms
ce10dbb6e1fd0ea5c922a932b0f920236aa411bf
[ "MIT" ]
null
null
null
#Author: ahmelq - github.com/ahmedelq/ #License: MIT #This is a solution of https://www.codewars.com/kata/583203e6eb35d7980400002a if __name__ == "__main__": print( countSmileys([':)', ';(', ';}', ':-D']), # should return 2 countSmileys([';D', ':-(', ':-)', ';~)']), # should return ...
26.95
77
0.489796
#Author: ahmelq - github.com/ahmedelq/ #License: MIT #This is a solution of https://www.codewars.com/kata/583203e6eb35d7980400002a def countSmileys(arr): import re return len( re.compile(r'[:;][-~]?[\)D]') .findall(' '.join(arr)) ) if __name__ == "__main__": print( coun...
111
0
23
10d104b9b64fc13f624cb8a75615a586496f8dc6
6,984
py
Python
plastron/commands/export.py
dsteelma-umd/plastron
d0e344c65ee2dfeba4fd78df3f73a1ae5f42b1d0
[ "Apache-2.0" ]
null
null
null
plastron/commands/export.py
dsteelma-umd/plastron
d0e344c65ee2dfeba4fd78df3f73a1ae5f42b1d0
[ "Apache-2.0" ]
null
null
null
plastron/commands/export.py
dsteelma-umd/plastron
d0e344c65ee2dfeba4fd78df3f73a1ae5f42b1d0
[ "Apache-2.0" ]
null
null
null
import json import logging import os from argparse import Namespace from datetime import datetime from tempfile import NamedTemporaryFile from time import sleep from plastron import pcdm from plastron.stomp import Message from plastron.exceptions import FailureException, DataReadException, RESTAPIException from plast...
36.375
113
0.507016
import json import logging import os from argparse import Namespace from datetime import datetime from tempfile import NamedTemporaryFile from time import sleep from plastron import pcdm from plastron.stomp import Message from plastron.exceptions import FailureException, DataReadException, RESTAPIException from plast...
6,339
-7
149
2d0af0d7fb0d233d7cf933b498df9ce8898f7a13
8,312
py
Python
helpers/ResNet.py
kchare/advex_notbugs_features
0ec0578a1aba2bdb86854676c005488091b64123
[ "MIT" ]
2
2022-02-08T11:51:12.000Z
2022-02-23T00:30:07.000Z
helpers/ResNet.py
kchare/advex_notbugs_features
0ec0578a1aba2bdb86854676c005488091b64123
[ "MIT" ]
null
null
null
helpers/ResNet.py
kchare/advex_notbugs_features
0ec0578a1aba2bdb86854676c005488091b64123
[ "MIT" ]
2
2021-12-21T20:31:28.000Z
2022-01-21T17:06:34.000Z
<<<<<<< HEAD '''Implements ResNet9,..56 dynamically for CIFAR-10 Description of implementation can be found here: https://arxiv.org/pdf/1512.03385.pdf''' import tensorflow as class ResNetBlock(tf.keras.layers.Layer): '''See official RStudio/Keras documentation here: https://github.com/rstudio/keras/blob/main/vigne...
45.922652
131
0.664461
<<<<<<< HEAD '''Implements ResNet9,..56 dynamically for CIFAR-10 Description of implementation can be found here: https://arxiv.org/pdf/1512.03385.pdf''' import tensorflow as class ResNetBlock(tf.keras.layers.Layer): '''See official RStudio/Keras documentation here: https://github.com/rstudio/keras/blob/main/vigne...
5,904
466
172
55b78c2012898f4fe86987d78fcabcd324b3ffd9
558
py
Python
src/ram/service/__init__.py
bootforce-dev/ram-framework
b39c43cbe3b6e76db73dfd65c38da4fa578b032f
[ "MIT" ]
1
2019-03-01T10:19:34.000Z
2019-03-01T10:19:34.000Z
src/ram/service/__init__.py
ram-framework/ram-framework
b39c43cbe3b6e76db73dfd65c38da4fa578b032f
[ "MIT" ]
null
null
null
src/ram/service/__init__.py
ram-framework/ram-framework
b39c43cbe3b6e76db73dfd65c38da4fa578b032f
[ "MIT" ]
null
null
null
import pkgutil from ram.classes import Service
27.9
62
0.625448
import pkgutil from ram.classes import Service class __api__(object): def __iter__(self): for _, srvname, _ in pkgutil.iter_modules(__path__): yield srvname def __getitem__(self, srvname): if not srvname: raise ImportError("Service name cannot be empty.") srvp...
432
1
76
8cf872b6a3c803c792ca79410991edaca09c12a3
19,959
py
Python
src/test_chess.py
liyiran/adversarial-search
8346cec55e9872409e0e6714cf8bce5e8d82bc8d
[ "Apache-2.0" ]
null
null
null
src/test_chess.py
liyiran/adversarial-search
8346cec55e9872409e0e6714cf8bce5e8d82bc8d
[ "Apache-2.0" ]
null
null
null
src/test_chess.py
liyiran/adversarial-search
8346cec55e9872409e0e6714cf8bce5e8d82bc8d
[ "Apache-2.0" ]
null
null
null
from unittest import TestCase, skip from hw1cs561s2018 import Chess, Configuration, alphabeta_cutoff_search, minimax_decision
35.201058
200
0.651486
from unittest import TestCase, skip from hw1cs561s2018 import Chess, Configuration, alphabeta_cutoff_search, minimax_decision class TestChess(TestCase): def test_evaluation(self): configuration2 = Configuration(path=None) configuration2.generate_configuration_from_string( """Circle AL...
19,076
732
23
ab8bb7e5f5c38a866610aeab2dfd90be6b13a3ea
44,907
py
Python
redun/backends/db/dataflow.py
cclauss/redun
55792921b42b430571eafc30ab21eb50eb4f64b3
[ "Apache-2.0" ]
null
null
null
redun/backends/db/dataflow.py
cclauss/redun
55792921b42b430571eafc30ab21eb50eb4f64b3
[ "Apache-2.0" ]
null
null
null
redun/backends/db/dataflow.py
cclauss/redun
55792921b42b430571eafc30ab21eb50eb4f64b3
[ "Apache-2.0" ]
null
null
null
""" Dataflow visualization. An upstream dataflow visualization explains the derivation of a value. Take for example this dataflow visualization of the derivation of a VCF file from a bioinformatic analysis: ``` value = File(path=sample4.vcf, hash=********) value <-- <********> call_variants(bam, ref_genome) bam ...
31.939545
99
0.628944
""" Dataflow visualization. An upstream dataflow visualization explains the derivation of a value. Take for example this dataflow visualization of the derivation of a VCF file from a bioinformatic analysis: ``` value = File(path=sample4.vcf, hash=********) value <-- <********> call_variants(bam, ref_genome) bam ...
616
0
81
b0c91e83a9b74bb222678d78da749bca5e26d7a9
1,131
py
Python
visualization_scripts/depth_distributions.py
crmauceri/pytorch-deeplab-xception
aec2cb7b0c09c346519c6bf22c2cbf419021fdc7
[ "MIT" ]
1
2021-12-11T08:21:19.000Z
2021-12-11T08:21:19.000Z
visualization_scripts/depth_distributions.py
crmauceri/rgbd_deeplab
aec2cb7b0c09c346519c6bf22c2cbf419021fdc7
[ "MIT" ]
null
null
null
visualization_scripts/depth_distributions.py
crmauceri/rgbd_deeplab
aec2cb7b0c09c346519c6bf22c2cbf419021fdc7
[ "MIT" ]
null
null
null
import matplotlib.pyplot as plt import scipy.stats import numpy as np from tqdm import tqdm from PIL import Image from deeplab3.config.defaults import get_cfg_defaults from dataloaders.utils import sample_distribution from dataloaders.datasets.cityscapes import CityscapesSegmentation from dataloaders.datasets.coco i...
37.7
99
0.821397
import matplotlib.pyplot as plt import scipy.stats import numpy as np from tqdm import tqdm from PIL import Image from deeplab3.config.defaults import get_cfg_defaults from dataloaders.utils import sample_distribution from dataloaders.datasets.cityscapes import CityscapesSegmentation from dataloaders.datasets.coco i...
0
0
0
3934a4a0ed4d91e9682e7a523fecefc8304cc24f
7,933
py
Python
src/cc_catalog_airflow/dags/provider_api_scripts/test_walters_art_museum.py
gauravahlawat81/cccatalog
cabfa11c4e1d68c66390ed46649282b7d33e2c58
[ "MIT" ]
65
2018-05-25T00:47:18.000Z
2021-11-30T05:58:43.000Z
src/cc_catalog_airflow/dags/provider_api_scripts/test_walters_art_museum.py
cc-archive/cccatalog
bc95ccc159ed7f1444d44e1db08d9a11a16c6d12
[ "MIT" ]
463
2018-05-01T14:35:42.000Z
2021-06-11T20:32:50.000Z
src/cc_catalog_airflow/dags/provider_api_scripts/test_walters_art_museum.py
cc-archive/cccatalog
bc95ccc159ed7f1444d44e1db08d9a11a16c6d12
[ "MIT" ]
81
2018-05-05T20:33:12.000Z
2021-04-28T02:23:10.000Z
import os import json import logging import requests from unittest.mock import patch, MagicMock import walters_art_museum as wam RESOURCES = os.path.join( os.path.abspath(os.path.dirname(__file__)), 'tests/resources/waltersartmuseum' ) logging.basicConfig( format='%(asctime)s - %(name)s - %(levelname)s: ...
32.646091
101
0.708307
import os import json import logging import requests from unittest.mock import patch, MagicMock import walters_art_museum as wam RESOURCES = os.path.join( os.path.abspath(os.path.dirname(__file__)), 'tests/resources/waltersartmuseum' ) logging.basicConfig( format='%(asctime)s - %(name)s - %(levelname)s: ...
6,889
0
385
61df26516d0787ba8bcc1bd61f1621598a533158
89
py
Python
program_files/__init__.py
Vinxenx/SESMG
ca8616ee2b175f949de737890d6f5cd4533f6ee7
[ "MIT" ]
13
2020-12-01T08:41:40.000Z
2021-12-01T22:07:12.000Z
program_files/__init__.py
Vinxenx/SESMG
ca8616ee2b175f949de737890d6f5cd4533f6ee7
[ "MIT" ]
66
2020-08-07T10:34:12.000Z
2022-03-31T13:07:07.000Z
program_files/__init__.py
Vinxenx/SESMG
ca8616ee2b175f949de737890d6f5cd4533f6ee7
[ "MIT" ]
6
2020-08-07T10:26:35.000Z
2022-01-12T09:36:54.000Z
# -*- coding: utf-8 -*- """ Created on Tue Jan 14 09:35:53 2020 @author: Christian """
11.125
35
0.58427
# -*- coding: utf-8 -*- """ Created on Tue Jan 14 09:35:53 2020 @author: Christian """
0
0
0
73716934c248a6b00656fef6bc54f715e7c1296c
12,778
py
Python
scripts/convert.py
kumasento/deacon
d9bf1adfc93d176930ddc43757eb039714c92657
[ "MIT" ]
2
2021-04-11T11:01:34.000Z
2021-04-12T09:18:02.000Z
scripts/convert.py
kumasento/deacon
d9bf1adfc93d176930ddc43757eb039714c92657
[ "MIT" ]
3
2021-04-10T21:06:42.000Z
2021-04-10T21:06:42.000Z
scripts/convert.py
kumasento/maxdeep
d9bf1adfc93d176930ddc43757eb039714c92657
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 """ Convert from pre-trained models. """ import argparse import math import os import sys from collections import OrderedDict from dataclasses import dataclass from typing import Dict import numpy as np import onnx import toml from onnx import shape_inference from pydeacon.graph import ( D...
36.824207
121
0.487792
#!/usr/bin/env python3 """ Convert from pre-trained models. """ import argparse import math import os import sys from collections import OrderedDict from dataclasses import dataclass from typing import Dict import numpy as np import onnx import toml from onnx import shape_inference from pydeacon.graph import ( D...
11,919
90
275
47312b896ce1ded775eb5694ed034f119703f054
3,999
py
Python
pma_api/utils.py
joeflack4/pma-api
de213833c93ad0c90b127188526c9eced31edc75
[ "MIT" ]
2
2018-08-24T14:27:25.000Z
2020-05-11T18:59:24.000Z
pma_api/utils.py
joeflack4/pma-api
de213833c93ad0c90b127188526c9eced31edc75
[ "MIT" ]
36
2018-07-13T15:49:50.000Z
2019-07-17T18:29:28.000Z
pma_api/utils.py
joeflack4/pma-api
de213833c93ad0c90b127188526c9eced31edc75
[ "MIT" ]
4
2018-07-12T19:24:52.000Z
2021-03-09T16:08:38.000Z
"""Assortment of utilities for application.""" import itertools import operator import os import random from typing import List from flask_sqlalchemy import Model, SQLAlchemy from pma_api.app import PmaApiFlask B64_CHAR_SET = ''.join(('abcdefghijklmnopqrstuvwxyz', 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'...
23.946108
76
0.628657
"""Assortment of utilities for application.""" import itertools import operator import os import random from typing import List from flask_sqlalchemy import Model, SQLAlchemy from pma_api.app import PmaApiFlask B64_CHAR_SET = ''.join(('abcdefghijklmnopqrstuvwxyz', 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'...
0
0
0
dce593f083f710d9b47b53386014bb2642bc2023
1,084
py
Python
Projects/Online Workouts/w3resource/Basic - Part-I/program-81.py
ivenpoker/Python-Projects
2975e1bd687ec8dbcc7a4842c13466cb86292679
[ "MIT" ]
1
2019-09-23T15:51:45.000Z
2019-09-23T15:51:45.000Z
Projects/Online Workouts/w3resource/Basic - Part-I/program-81.py
ivenpoker/Python-Projects
2975e1bd687ec8dbcc7a4842c13466cb86292679
[ "MIT" ]
5
2021-02-08T20:47:19.000Z
2022-03-12T00:35:44.000Z
Projects/Online Workouts/w3resource/Basic - Part-I/program-81.py
ivenpoker/Python-Projects
2975e1bd687ec8dbcc7a4842c13466cb86292679
[ "MIT" ]
null
null
null
# !/usr/bin/env python3 ####################################################################################### # # # Program purpose: Concatenates N-strings. # # Program Author : Happi...
40.148148
87
0.350554
# !/usr/bin/env python3 ####################################################################################### # # # Program purpose: Concatenates N-strings. # # Program Author : Happi...
188
0
23
83cdf744bb4105c7bd913cf6fac47cf20ff9faa7
1,741
py
Python
python/test.py
MorenoJoshua/freeswitchManager
b1488f6c9e2a2e3008e758dde46ea9ca22fdec26
[ "MIT" ]
null
null
null
python/test.py
MorenoJoshua/freeswitchManager
b1488f6c9e2a2e3008e758dde46ea9ca22fdec26
[ "MIT" ]
null
null
null
python/test.py
MorenoJoshua/freeswitchManager
b1488f6c9e2a2e3008e758dde46ea9ca22fdec26
[ "MIT" ]
null
null
null
import requests import hmac import hashlib import datetime as dt import simplejson as json access_key = '80473469' # example secret_key = 'GhDzk8Lc00xUzUjHFJqDqLztMNq5KMgU' # example # Generate the X-Timestamp t = dt.datetime.utcnow().replace(microsecond=0) timestamp = t.isoformat() timestamp = '2015-10-29T14:33:46' ...
32.240741
129
0.731189
import requests import hmac import hashlib import datetime as dt import simplejson as json access_key = '80473469' # example secret_key = 'GhDzk8Lc00xUzUjHFJqDqLztMNq5KMgU' # example # Generate the X-Timestamp t = dt.datetime.utcnow().replace(microsecond=0) timestamp = t.isoformat() timestamp = '2015-10-29T14:33:46' ...
0
0
0
366c1976344b76f7e0aa3018661a6d511956da45
4,053
py
Python
oecp/proxy/requests_proxy.py
openeuler-mirror/oecp
967ed6b9e53f2da5f795f49bb5b5fc0423372863
[ "MulanPSL-1.0" ]
null
null
null
oecp/proxy/requests_proxy.py
openeuler-mirror/oecp
967ed6b9e53f2da5f795f49bb5b5fc0423372863
[ "MulanPSL-1.0" ]
null
null
null
oecp/proxy/requests_proxy.py
openeuler-mirror/oecp
967ed6b9e53f2da5f795f49bb5b5fc0423372863
[ "MulanPSL-1.0" ]
null
null
null
# -*- encoding=utf-8 -*- """ # ********************************************************************************** # Copyright (c) Huawei Technologies Co., Ltd. 2020-2020. All rights reserved. # [oecp] is licensed under the Mulan PSL v1. # You can use this software according to the terms and conditions of the Mulan PSL ...
30.022222
118
0.564767
# -*- encoding=utf-8 -*- """ # ********************************************************************************** # Copyright (c) Huawei Technologies Co., Ltd. 2020-2020. All rights reserved. # [oecp] is licensed under the Mulan PSL v1. # You can use this software according to the terms and conditions of the Mulan PSL ...
0
0
0
de17091d3df24d73c76bf0f93b09db5b447175d3
1,946
py
Python
.vim/plugged/after/pythonx/my_snippet_helpers.py
sharils/home
bccac132b68d8d7cc46f21cae343b9ce99af6e01
[ "Unlicense" ]
3
2018-08-03T11:58:44.000Z
2019-12-12T14:44:36.000Z
.vim/plugged/after/pythonx/my_snippet_helpers.py
sharils/home
bccac132b68d8d7cc46f21cae343b9ce99af6e01
[ "Unlicense" ]
1
2020-08-02T01:14:37.000Z
2020-08-02T01:15:27.000Z
.vim/plugged/after/pythonx/my_snippet_helpers.py
sharils/home
bccac132b68d8d7cc46f21cae343b9ce99af6e01
[ "Unlicense" ]
1
2019-03-02T10:08:10.000Z
2019-03-02T10:08:10.000Z
import re import os import vim
27.408451
112
0.666495
import re import os import vim def around_assign(snip): return '=' in snip.buffer[snip.line] def around_catch(snip): return 'catch' in snip.buffer[snip.line - 1] def around_class(snip): return 'class' in snip.buffer[snip.line] def around_const_let_var(snip): return re.search('const|let|var', snip.bu...
1,432
0
483
681bb0f26e4f2b6b3ed857eda5a41e22243ccaba
3,488
py
Python
angr/procedures/definitions/win32_api-ms-win-wsl-api-l1-1-0.py
r4b3rt/angr
c133cfd4f83ffea2a1d9e064241e9459eaabc55f
[ "BSD-2-Clause" ]
null
null
null
angr/procedures/definitions/win32_api-ms-win-wsl-api-l1-1-0.py
r4b3rt/angr
c133cfd4f83ffea2a1d9e064241e9459eaabc55f
[ "BSD-2-Clause" ]
null
null
null
angr/procedures/definitions/win32_api-ms-win-wsl-api-l1-1-0.py
r4b3rt/angr
c133cfd4f83ffea2a1d9e064241e9459eaabc55f
[ "BSD-2-Clause" ]
null
null
null
# pylint:disable=line-too-long import logging from ...sim_type import SimTypeFunction, SimTypeShort, SimTypeInt, SimTypeLong, SimTypeLongLong, SimTypeDouble, SimTypeFloat, SimTypePointer, SimTypeChar, SimStruct, SimTypeFixedSizeArray, SimTypeBottom, SimUnion, SimTypeBool from ...calling...
96.888889
706
0.746273
# pylint:disable=line-too-long import logging from ...sim_type import SimTypeFunction, SimTypeShort, SimTypeInt, SimTypeLong, SimTypeLongLong, SimTypeDouble, SimTypeFloat, SimTypePointer, SimTypeChar, SimStruct, SimTypeFixedSizeArray, SimTypeBottom, SimUnion, SimTypeBool from ...calling...
0
0
0