hexsha
stringlengths
40
40
size
int64
2
1.02M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
245
max_stars_repo_name
stringlengths
6
130
max_stars_repo_head_hexsha
stringlengths
40
40
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
245
max_issues_repo_name
stringlengths
6
130
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
245
max_forks_repo_name
stringlengths
6
130
max_forks_repo_head_hexsha
stringlengths
40
40
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
2
1.02M
avg_line_length
float64
1
958k
max_line_length
int64
1
987k
alphanum_fraction
float64
0
1
content_no_comment
stringlengths
0
1.01M
is_comment_constant_removed
bool
2 classes
is_sharp_comment_removed
bool
1 class
1c1ed4fceb76ccd14177d22c49851b207b3bc2b4
1,703
py
Python
romain_sings/player/views.py
gfavre/romainsings
2938dee21891fa9db4339ba078dc4a2dace72c24
[ "MIT" ]
null
null
null
romain_sings/player/views.py
gfavre/romainsings
2938dee21891fa9db4339ba078dc4a2dace72c24
[ "MIT" ]
null
null
null
romain_sings/player/views.py
gfavre/romainsings
2938dee21891fa9db4339ba078dc4a2dace72c24
[ "MIT" ]
null
null
null
from collections import OrderedDict from datetime import timedelta from django.db.models import Count, DateField from django.views.generic import TemplateView from django.db.models.functions import Trunc from romain_sings.songs.models import Song from .models import PlayedEvent class DashboardView(TemplateView): ...
48.657143
109
0.588373
from collections import OrderedDict from datetime import timedelta from django.db.models import Count, DateField from django.views.generic import TemplateView from django.db.models.functions import Trunc from romain_sings.songs.models import Song from .models import PlayedEvent class DashboardView(TemplateView): ...
true
true
1c1ed525a92e833ad3299914fb6f41951393a039
472
py
Python
plotly/validators/layout/polar/radialaxis/titlefont/_size.py
faezs/plotly.py
6009b5b9c746e5d2a2849ad255a4eb234b551ed7
[ "MIT" ]
2
2020-03-24T11:41:14.000Z
2021-01-14T07:59:43.000Z
plotly/validators/layout/polar/radialaxis/titlefont/_size.py
faezs/plotly.py
6009b5b9c746e5d2a2849ad255a4eb234b551ed7
[ "MIT" ]
null
null
null
plotly/validators/layout/polar/radialaxis/titlefont/_size.py
faezs/plotly.py
6009b5b9c746e5d2a2849ad255a4eb234b551ed7
[ "MIT" ]
4
2019-06-03T14:49:12.000Z
2022-01-06T01:05:12.000Z
import _plotly_utils.basevalidators class SizeValidator(_plotly_utils.basevalidators.NumberValidator): def __init__( self, plotly_name='size', parent_name='layout.polar.radialaxis.titlefont', **kwargs ): super(SizeValidator, self).__init__( plotly_name=plot...
23.6
66
0.584746
import _plotly_utils.basevalidators class SizeValidator(_plotly_utils.basevalidators.NumberValidator): def __init__( self, plotly_name='size', parent_name='layout.polar.radialaxis.titlefont', **kwargs ): super(SizeValidator, self).__init__( plotly_name=plot...
true
true
1c1ed756b5151d320ce2a6f51cf6764794af9db1
9,514
py
Python
histogram_matching.py
AKA-ZSZ/AI_Artistry
64384c8c7fd6f8db89d0fe918bf94bec81f18a7a
[ "MIT" ]
null
null
null
histogram_matching.py
AKA-ZSZ/AI_Artistry
64384c8c7fd6f8db89d0fe918bf94bec81f18a7a
[ "MIT" ]
null
null
null
histogram_matching.py
AKA-ZSZ/AI_Artistry
64384c8c7fd6f8db89d0fe918bf94bec81f18a7a
[ "MIT" ]
1
2021-04-25T19:00:07.000Z
2021-04-25T19:00:07.000Z
#!/usr/bin/env python ''' Welcome to the Histogram Matching Program! Given a source image and a reference image, this program returns a modified version of the source image that matches the histogram of the reference image. Image Requirements: - Source image must be color. - Reference image must be color. -...
34.596364
81
0.702333
from __future__ import print_function import cv2 import numpy as np import matplotlib.pyplot as plt import sys SOURCE_IMAGE = "Starry-Night-canvas-Vincent-van-Gogh-New-1889.jpg" REFERENCE_IMAGE = "main-image.jpg" MASK_IMAGE = "mask.jpg" OUTPUT_IMAGE = "aspens_in_fall_forest_output" OUTPUT_MASKED_IM...
true
true
1c1ed80b7ba308cf77dfb1316c17f7d6f158ec68
218
py
Python
setup.py
ColeKainz/example_repo_for_me
45fdf123e4435b1cf89f5200d647024a6c1c7bb8
[ "MIT" ]
null
null
null
setup.py
ColeKainz/example_repo_for_me
45fdf123e4435b1cf89f5200d647024a6c1c7bb8
[ "MIT" ]
null
null
null
setup.py
ColeKainz/example_repo_for_me
45fdf123e4435b1cf89f5200d647024a6c1c7bb8
[ "MIT" ]
null
null
null
from setuptools import find_packages, setup setup( name='src', packages=find_packages(), version='0.1.0', description='This is an example. EXAMPLE!!!!!!', author='Cole Kainz', license='MIT', )
19.818182
52
0.637615
from setuptools import find_packages, setup setup( name='src', packages=find_packages(), version='0.1.0', description='This is an example. EXAMPLE!!!!!!', author='Cole Kainz', license='MIT', )
true
true
1c1ed811993d35077e4b35811a44955dc67553d5
17,320
py
Python
openpeerpower/components/mqtt/vacuum/schema_legacy.py
pcaston/core
e74d946cef7a9d4e232ae9e0ba150d18018cfe33
[ "Apache-2.0" ]
1
2021-07-08T20:09:55.000Z
2021-07-08T20:09:55.000Z
openpeerpower/components/mqtt/vacuum/schema_legacy.py
pcaston/core
e74d946cef7a9d4e232ae9e0ba150d18018cfe33
[ "Apache-2.0" ]
47
2021-02-21T23:43:07.000Z
2022-03-31T06:07:10.000Z
openpeerpower/components/mqtt/vacuum/schema_legacy.py
OpenPeerPower/core
f673dfac9f2d0c48fa30af37b0a99df9dd6640ee
[ "Apache-2.0" ]
null
null
null
"""Support for Legacy MQTT vacuum.""" import json import voluptuous as vol from openpeerpower.components.vacuum import ( SUPPORT_BATTERY, SUPPORT_CLEAN_SPOT, SUPPORT_FAN_SPEED, SUPPORT_LOCATE, SUPPORT_PAUSE, SUPPORT_RETURN_HOME, SUPPORT_SEND_COMMAND, SUPPORT_STATUS, SUPPORT_STOP, ...
34.64
88
0.619804
import json import voluptuous as vol from openpeerpower.components.vacuum import ( SUPPORT_BATTERY, SUPPORT_CLEAN_SPOT, SUPPORT_FAN_SPEED, SUPPORT_LOCATE, SUPPORT_PAUSE, SUPPORT_RETURN_HOME, SUPPORT_SEND_COMMAND, SUPPORT_STATUS, SUPPORT_STOP, SUPPORT_TURN_OFF, SUPPORT_TURN_...
true
true
1c1ed9b9de14a519e699f1e1760cfff77e72fa13
434
py
Python
python_demos/linq.py
mikeckennedy/DevWeek2015
7cb77ecbae47fc71c62939524ad4f47e39516b29
[ "CC0-1.0" ]
null
null
null
python_demos/linq.py
mikeckennedy/DevWeek2015
7cb77ecbae47fc71c62939524ad4f47e39516b29
[ "CC0-1.0" ]
null
null
null
python_demos/linq.py
mikeckennedy/DevWeek2015
7cb77ecbae47fc71c62939524ad4f47e39516b29
[ "CC0-1.0" ]
null
null
null
class Person: def __init__(self, name, age, hobbies): self.hobbies = hobbies self.age = age self.name = name people = [ Person('Ted', 27, ['Sleeping']), Person('Jeff', 40, ['Biking', 'Surfing']), Person('Michael', 41, ['Biking', 'Rock climbing']), Person('Zoe', 30, ['Swimmi...
13.5625
55
0.548387
class Person: def __init__(self, name, age, hobbies): self.hobbies = hobbies self.age = age self.name = name people = [ Person('Ted', 27, ['Sleeping']), Person('Jeff', 40, ['Biking', 'Surfing']), Person('Michael', 41, ['Biking', 'Rock climbing']), Person('Zoe', 30, ['Swimmi...
true
true
1c1ed9fa54207a62a0843659d7f1bb594cd19638
752
pyw
Python
HelloWorld/Python01/Core Python Applications Programming 3rd/ch07/word.pyw
grtlinux/KieaPython
5539a9e3625864aa20624b8d684dbe5828dac3d1
[ "Apache-2.0" ]
1
2022-01-29T08:32:11.000Z
2022-01-29T08:32:11.000Z
HelloWorld/Python01/Core Python Applications Programming 3rd/ch07/word.pyw
grtlinux/KieaPython
5539a9e3625864aa20624b8d684dbe5828dac3d1
[ "Apache-2.0" ]
null
null
null
HelloWorld/Python01/Core Python Applications Programming 3rd/ch07/word.pyw
grtlinux/KieaPython
5539a9e3625864aa20624b8d684dbe5828dac3d1
[ "Apache-2.0" ]
1
2022-01-29T08:32:12.000Z
2022-01-29T08:32:12.000Z
#!/usr/bin/env python from Tkinter import Tk from time import sleep from tkMessageBox import showwarning import win32com.client as win32 warn = lambda app: showwarning(app, 'Exit?') RANGE = range(3, 8) def word(): app = 'Word' word = win32.gencache.EnsureDispatch('%s.Application' % app) doc ...
22.787879
65
0.606383
from Tkinter import Tk from time import sleep from tkMessageBox import showwarning import win32com.client as win32 warn = lambda app: showwarning(app, 'Exit?') RANGE = range(3, 8) def word(): app = 'Word' word = win32.gencache.EnsureDispatch('%s.Application' % app) doc = word.Documents.Add()...
true
true
1c1edb1e680b36c48a2955c8c930dbef9ee9d967
25,560
py
Python
resolwe/test_helpers/test_runner.py
plojyon/resolwe
1bee6f0860fdd087534adf1680e9350d79ab97cf
[ "Apache-2.0" ]
27
2015-12-07T18:29:12.000Z
2022-03-16T08:01:47.000Z
resolwe/test_helpers/test_runner.py
plojyon/resolwe
1bee6f0860fdd087534adf1680e9350d79ab97cf
[ "Apache-2.0" ]
681
2015-12-01T11:52:24.000Z
2022-03-21T07:43:37.000Z
resolwe/test_helpers/test_runner.py
plojyon/resolwe
1bee6f0860fdd087534adf1680e9350d79ab97cf
[ "Apache-2.0" ]
28
2015-12-01T08:32:57.000Z
2021-12-14T00:04:16.000Z
""".. Ignore pydocstyle D400. =================== Resolwe Test Runner =================== """ import asyncio import contextlib import errno import logging import os import re import shutil import subprocess import sys from pathlib import Path from unittest.mock import patch import yaml import zmq import zmq.asyncio ...
36.358464
108
0.603482
import asyncio import contextlib import errno import logging import os import re import shutil import subprocess import sys from pathlib import Path from unittest.mock import patch import yaml import zmq import zmq.asyncio from channels.db import database_sync_to_async from django.conf import settings from django.cor...
true
true
1c1edb416e3f1f2bad7c2b701733af95265b22ae
1,925
py
Python
day17/day17.py
chrisb87/advent_of_code_2016
668a7c5e3f2aac036dcf0091ca62a47cb0c54ba8
[ "Unlicense" ]
1
2016-12-07T20:28:12.000Z
2016-12-07T20:28:12.000Z
day17/day17.py
chrisb87/advent_of_code_2016
668a7c5e3f2aac036dcf0091ca62a47cb0c54ba8
[ "Unlicense" ]
null
null
null
day17/day17.py
chrisb87/advent_of_code_2016
668a7c5e3f2aac036dcf0091ca62a47cb0c54ba8
[ "Unlicense" ]
null
null
null
import pdb import md5 from Queue import PriorityQueue MOVES = ( ('U', (0, -1)), ('D', (0, 1)), ('L', (-1, 0)), ('R', (1, 0)), ) OPEN_DOORS = 'bcdef' def get_door_hash(passcode, path): return md5.new(passcode + path).hexdigest()[:4] def distance_from_goal(position, target_position): return sum(map(lambda p: ab...
25.666667
77
0.710649
import pdb import md5 from Queue import PriorityQueue MOVES = ( ('U', (0, -1)), ('D', (0, 1)), ('L', (-1, 0)), ('R', (1, 0)), ) OPEN_DOORS = 'bcdef' def get_door_hash(passcode, path): return md5.new(passcode + path).hexdigest()[:4] def distance_from_goal(position, target_position): return sum(map(lambda p: ab...
false
true
1c1edc1d617a385c7769528ba191a29f5005c0a9
5,797
py
Python
gsdl2/__init__.py
TiberiumN/gsdl2
f40f52887f127713cb8c922ce4ebb13183170bd8
[ "MIT" ]
2
2020-11-10T06:24:03.000Z
2021-01-01T18:14:26.000Z
gsdl2/__init__.py
Yardanico/gsdl2
f40f52887f127713cb8c922ce4ebb13183170bd8
[ "MIT" ]
null
null
null
gsdl2/__init__.py
Yardanico/gsdl2
f40f52887f127713cb8c922ce4ebb13183170bd8
[ "MIT" ]
null
null
null
import logging import _sdl __all__ = [ 'init', 'Clock', 'Color', 'GameClock', 'Font', 'Rect', 'Renderer', 'Surface', 'SysFont', 'Texture', 'Window', 'sdlconstants', 'color', 'colordict', 'display', 'draw', 'event', 'font', 'gameclock', 'gfx', 'image', 'joystick', 'mixer', 'mouse', 'music', 'pa...
30.510526
121
0.565465
import logging import _sdl __all__ = [ 'init', 'Clock', 'Color', 'GameClock', 'Font', 'Rect', 'Renderer', 'Surface', 'SysFont', 'Texture', 'Window', 'sdlconstants', 'color', 'colordict', 'display', 'draw', 'event', 'font', 'gameclock', 'gfx', 'image', 'joystick', 'mixer', 'mouse', 'music', 'pa...
true
true
1c1edd371a4dfcee915cf27efd078ad04cc622c2
116
py
Python
backend/wsgi.py
delosrogers/minimum
f10d61b400c05c09f7d9580e510afacf83eadb68
[ "MIT" ]
null
null
null
backend/wsgi.py
delosrogers/minimum
f10d61b400c05c09f7d9580e510afacf83eadb68
[ "MIT" ]
null
null
null
backend/wsgi.py
delosrogers/minimum
f10d61b400c05c09f7d9580e510afacf83eadb68
[ "MIT" ]
null
null
null
from minimum import init_app app = init_app() if __name__ == "__main__": app.run(host="0.0.0.0", debug=True)
14.5
39
0.663793
from minimum import init_app app = init_app() if __name__ == "__main__": app.run(host="0.0.0.0", debug=True)
true
true
1c1edd7517f3fa049c1bebdd7c848f5eb5239a3d
906
py
Python
ifaxbotcovid/config/utils/settings.py
a-sia-now/ifaxbotcovid
316273c26a81c466605e9c92a8b90b8e621249ea
[ "MIT" ]
null
null
null
ifaxbotcovid/config/utils/settings.py
a-sia-now/ifaxbotcovid
316273c26a81c466605e9c92a8b90b8e621249ea
[ "MIT" ]
null
null
null
ifaxbotcovid/config/utils/settings.py
a-sia-now/ifaxbotcovid
316273c26a81c466605e9c92a8b90b8e621249ea
[ "MIT" ]
null
null
null
from collections import namedtuple import logging import yaml file = 'ifaxbotcovid/config/settings.yml' with open(file, 'r') as stream: try: config = yaml.safe_load(stream) except yaml.YAMLError as exc: logging.error('Cannot get configuration file: %s', exc) base_vars = config['base_vars']...
21.069767
69
0.718543
from collections import namedtuple import logging import yaml file = 'ifaxbotcovid/config/settings.yml' with open(file, 'r') as stream: try: config = yaml.safe_load(stream) except yaml.YAMLError as exc: logging.error('Cannot get configuration file: %s', exc) base_vars = config['base_vars']...
true
true
1c1eddd151f8c6093f3d61b1a4a1215c775cbc32
2,118
py
Python
volf_bruter.py
volf52/black_hat_python
063c241db473d3ef25782efc17f651c3aa66b4f8
[ "MIT" ]
null
null
null
volf_bruter.py
volf52/black_hat_python
063c241db473d3ef25782efc17f651c3aa66b4f8
[ "MIT" ]
null
null
null
volf_bruter.py
volf52/black_hat_python
063c241db473d3ef25782efc17f651c3aa66b4f8
[ "MIT" ]
null
null
null
#!/usr/bin/env python """ @author : 'Muhammad Arslan <rslnrkmt2552@gmail.com>' """ import requests import threading import Queue import urllib import sys THREADS = 50 threads = [] target_url = "http://testphp.vulnweb.com" wordlist_file = "/root/wordlists/big.txt" resume = None user_agent = "Mozilla/5.0 (X11; Linux ...
25.518072
83
0.563739
""" @author : 'Muhammad Arslan <rslnrkmt2552@gmail.com>' """ import requests import threading import Queue import urllib import sys THREADS = 50 threads = [] target_url = "http://testphp.vulnweb.com" wordlist_file = "/root/wordlists/big.txt" resume = None user_agent = "Mozilla/5.0 (X11; Linux x86_64; rv:19.0) Geck...
false
true
1c1eddf6696a10233ff1c7e19414a6b5b6d5084b
3,481
py
Python
training_api/application/configuration/templates/faster_rcnn_resnet101_v1_1024x1024.py
hadikoub/BMW-TensorFlow-Training-GUI
0c18e65529b3fcb6a7ea9e57f8e4e2e5e6e93d5d
[ "Apache-2.0" ]
1
2020-06-22T12:56:58.000Z
2020-06-22T12:56:58.000Z
training_api/application/configuration/templates/faster_rcnn_resnet101_v1_1024x1024.py
hadikoub/BMW-TensorFlow-Training-GUI
0c18e65529b3fcb6a7ea9e57f8e4e2e5e6e93d5d
[ "Apache-2.0" ]
null
null
null
training_api/application/configuration/templates/faster_rcnn_resnet101_v1_1024x1024.py
hadikoub/BMW-TensorFlow-Training-GUI
0c18e65529b3fcb6a7ea9e57f8e4e2e5e6e93d5d
[ "Apache-2.0" ]
null
null
null
import os from domain.models.paths import Paths from shared.helpers.path_helper import get_path_configuration from domain.models import hyper_parameter_information from domain.services.contract.abstract_configure_network_service import AbstractConfigureNetworkService from object_detection.utils.config_util import get_...
53.553846
239
0.756105
import os from domain.models.paths import Paths from shared.helpers.path_helper import get_path_configuration from domain.models import hyper_parameter_information from domain.services.contract.abstract_configure_network_service import AbstractConfigureNetworkService from object_detection.utils.config_util import get_...
true
true
1c1ede5977e4f192ea375a0c3ae58189b392018a
1,548
py
Python
l2ex14.py
rafaelclemes81/Python
0e685b4e528a29bb23ecf11c9ccdbae8730b3ac3
[ "MIT" ]
null
null
null
l2ex14.py
rafaelclemes81/Python
0e685b4e528a29bb23ecf11c9ccdbae8730b3ac3
[ "MIT" ]
null
null
null
l2ex14.py
rafaelclemes81/Python
0e685b4e528a29bb23ecf11c9ccdbae8730b3ac3
[ "MIT" ]
null
null
null
'''Faça um programa que lê as duas notas parciais obtidas por um aluno numa disciplina ao longo de um semestre, e calcule a sua média. A atribuição de conceitos obedece à tabela abaixo: Média de Aproveitamento Conceito Entre 9.0 e 10.0 A Entre 7.5 e 9.0 B Entre 6.0 e 7.5 C Entre 4.0 e...
27.642857
115
0.56137
import os def cabecalho(c, t): print(f'-' * t) print(f'{c:^{t}}') print(f'-' * t) def resultado (r, t, nts): soma = 0 print(f'-' * t) print(f'{r:^{t}}') print(f'-' * t) for i in range(0, 2): soma += nts[i] media = soma / len(nts) for i, v in enumerate(nts): pri...
true
true
1c1edf38af473ac5a6107bd95834fcc27c23c87b
950
py
Python
alphatwirl/heppyresult/ReadVersionInfo.py
benkrikler/alphatwirl
cda7d12fec21291ea33af23234fc08be19430934
[ "BSD-3-Clause" ]
null
null
null
alphatwirl/heppyresult/ReadVersionInfo.py
benkrikler/alphatwirl
cda7d12fec21291ea33af23234fc08be19430934
[ "BSD-3-Clause" ]
7
2018-02-26T10:32:26.000Z
2018-03-19T12:27:12.000Z
alphatwirl/heppyresult/ReadVersionInfo.py
benkrikler/alphatwirl
cda7d12fec21291ea33af23234fc08be19430934
[ "BSD-3-Clause" ]
null
null
null
# Tai Sakuma <tai.sakuma@gmail.com> ##__________________________________________________________________|| import os.path from alphatwirl.misc.deprecation import atdeprecated ##__________________________________________________________________|| @atdeprecated(msg='heppyresult has been moved to https://github.com/alp...
36.538462
129
0.730526
alphatwirl/atheppy.') class ReadVersionInfo(object): def __call__(self, path): if not os.path.isfile(path): return None file = open(path) return self._readImp(file) def _readImp(self, file): full = file.read() tag = full.split(b'\n')[1] ...
true
true
1c1edf9bdbcaf0e7b4af48e044def1728ddbcb86
8,351
py
Python
imgprocessor.py
vishnuprasadh/flaskdynamicimgprocessor
2f70f8f1b399311b5b302720512d180fbb828ff1
[ "OLDAP-2.4", "Apache-2.0" ]
null
null
null
imgprocessor.py
vishnuprasadh/flaskdynamicimgprocessor
2f70f8f1b399311b5b302720512d180fbb828ff1
[ "OLDAP-2.4", "Apache-2.0" ]
null
null
null
imgprocessor.py
vishnuprasadh/flaskdynamicimgprocessor
2f70f8f1b399311b5b302720512d180fbb828ff1
[ "OLDAP-2.4", "Apache-2.0" ]
null
null
null
from flask import Flask from flask import request from flask import Response from flask import make_response from flask import send_file from werkzeug.datastructures import Headers import logging import logging.handlers from imagehandler import imagehandler app = Flask(__name__) mylogger = logging.getLogger("dynamici...
47.448864
179
0.663873
from flask import Flask from flask import request from flask import Response from flask import make_response from flask import send_file from werkzeug.datastructures import Headers import logging import logging.handlers from imagehandler import imagehandler app = Flask(__name__) mylogger = logging.getLogger("dynamici...
true
true
1c1edffda07a03e75740e4a35bb418d35dada917
8,231
py
Python
src/deutschland/handelsregister/publications.py
andreasbossard/deutschland
6f561256c707e21f81b54b139b9acb745b901298
[ "Apache-2.0" ]
445
2021-07-26T22:00:26.000Z
2022-03-31T08:31:08.000Z
src/deutschland/handelsregister/publications.py
andreasbossard/deutschland
6f561256c707e21f81b54b139b9acb745b901298
[ "Apache-2.0" ]
30
2021-07-27T15:42:23.000Z
2022-03-26T16:14:11.000Z
src/deutschland/handelsregister/publications.py
andreasbossard/deutschland
6f561256c707e21f81b54b139b9acb745b901298
[ "Apache-2.0" ]
28
2021-07-27T10:48:43.000Z
2022-03-26T14:31:30.000Z
from typing import Dict import dateparser import requests from bs4 import BeautifulSoup from deutschland.config import Config, module_config class Publications: def __init__(self, config: Config = None): if config is None: self._config = module_config else: self._config =...
32.278431
156
0.575264
from typing import Dict import dateparser import requests from bs4 import BeautifulSoup from deutschland.config import Config, module_config class Publications: def __init__(self, config: Config = None): if config is None: self._config = module_config else: self._config =...
true
true
1c1ee0047280b493955ea9b0be777130c2b49ccc
3,036
py
Python
SEIMF/epic_pkg_cmdline.py
ritviksahajpal/EPIC
47bfd9ecbe130667bd5e22efded95a612ea3fbd2
[ "MIT" ]
3
2015-11-08T10:34:31.000Z
2020-07-03T09:48:20.000Z
SEIMF/epic_pkg_cmdline.py
ritviksahajpal/EPIC
47bfd9ecbe130667bd5e22efded95a612ea3fbd2
[ "MIT" ]
null
null
null
SEIMF/epic_pkg_cmdline.py
ritviksahajpal/EPIC
47bfd9ecbe130667bd5e22efded95a612ea3fbd2
[ "MIT" ]
4
2015-04-24T23:40:05.000Z
2018-08-16T14:39:10.000Z
import sys,logging import getopt # command line parsing ## Command Line Options Processing ## opt_files_dir will return None if not on command line - alternate directory for import ## opt_testdb will return false if not on command line - used by Jeff to test db objects def usage(): print "Required parameters: " ...
36.142857
150
0.625165
import sys,logging import getopt numpkgs= <number_of_packages>" print " -o or --outdir= <pkg_build_folder>" print "rundir_directory is the directory where the Run programs and data are located." print "EPICRUN.dat is the directory and file name for the runs to be split. Usually EPICRUN.dat" print "...
false
true
1c1ee07b3bb324d23e168979508028c76ea000a3
1,754
py
Python
human_friction/utils/metric_generator.py
mesjou/human-frictions
2a5c919039bb29643a3e8dd36c0fa13ce7d93e0e
[ "MIT" ]
null
null
null
human_friction/utils/metric_generator.py
mesjou/human-frictions
2a5c919039bb29643a3e8dd36c0fa13ce7d93e0e
[ "MIT" ]
null
null
null
human_friction/utils/metric_generator.py
mesjou/human-frictions
2a5c919039bb29643a3e8dd36c0fa13ce7d93e0e
[ "MIT" ]
null
null
null
import collections from abc import ABC import matplotlib.pyplot as plt import pandas as pd from human_friction.rllib.rllib_env import RllibDiscrete class MetricGenerator(ABC): def __init__(self, env: RllibDiscrete): agent_metrics = ["wage", "budget", "consumption", "labor", "reward"] environment_...
35.08
94
0.593501
import collections from abc import ABC import matplotlib.pyplot as plt import pandas as pd from human_friction.rllib.rllib_env import RllibDiscrete class MetricGenerator(ABC): def __init__(self, env: RllibDiscrete): agent_metrics = ["wage", "budget", "consumption", "labor", "reward"] environment_...
true
true
1c1ee0fb80dc515c1124dd91c63b9bcf37149b09
5,967
py
Python
cmdb/api.py
sundog315/adminset
f08f222b9f8ebc76f396edc19b864edbfdab3c2c
[ "Apache-2.0" ]
null
null
null
cmdb/api.py
sundog315/adminset
f08f222b9f8ebc76f396edc19b864edbfdab3c2c
[ "Apache-2.0" ]
null
null
null
cmdb/api.py
sundog315/adminset
f08f222b9f8ebc76f396edc19b864edbfdab3c2c
[ "Apache-2.0" ]
null
null
null
#! /usr/bin/env python # -*- coding: utf-8 -*- # 2017.3 update by guohongze@126.com from django.http import HttpResponse from models import Host, HostGroup, ASSET_TYPE, ASSET_STATUS from django.core.paginator import Paginator, EmptyPage, InvalidPage from django.views.decorators.csrf import csrf_exempt from lib.common i...
29.984925
96
0.584046
from django.http import HttpResponse from models import Host, HostGroup, ASSET_TYPE, ASSET_STATUS from django.core.paginator import Paginator, EmptyPage, InvalidPage from django.views.decorators.csrf import csrf_exempt from lib.common import token_verify from lib.deploy_key import deploy_key import logging from lib....
false
true
1c1ee20749cb1026de62c0644328aec268903cc0
40,708
py
Python
models/2HDMtII_NLO/CT_vertices.py
Ceebs93/madgraph
82340bc97bcda1f510598d9f3d7819e22cb922f9
[ "NCSA" ]
null
null
null
models/2HDMtII_NLO/CT_vertices.py
Ceebs93/madgraph
82340bc97bcda1f510598d9f3d7819e22cb922f9
[ "NCSA" ]
null
null
null
models/2HDMtII_NLO/CT_vertices.py
Ceebs93/madgraph
82340bc97bcda1f510598d9f3d7819e22cb922f9
[ "NCSA" ]
null
null
null
# This file was automatically created by FeynRules 2.3.13 # Mathematica version: 10.1.0 for Mac OS X x86 (64-bit) (March 24, 2015) # Date: Tue 8 Dec 2015 11:44:25 from object_library import all_vertices, all_CTvertices, Vertex, CTVertex import particles as P import CT_couplings as C import lorentz as L V_1 = CTVer...
50.133005
1,709
0.441559
from object_library import all_vertices, all_CTvertices, Vertex, CTVertex import particles as P import CT_couplings as C import lorentz as L V_1 = CTVertex(name = 'V_1', type = 'R2', particles = [ P.g, P.g, P.g ], color = [ 'f(1,2,3)' ], lorentz = [ L.V...
true
true
1c1ee2c28ad45733aa1b4dd6cc706e251c02360b
8,262
py
Python
ska-tmc/ska-tmc-mccsmasterleafnode-low/src/ska_tmc_mccsmasterleafnode_low/mccs_master_leaf_node.py
ska-telescope/tmc-prototype
4138274e933d4b05f7fe9fc34a11c417b6d0d336
[ "BSD-3-Clause" ]
3
2019-01-10T11:49:36.000Z
2019-07-19T03:32:52.000Z
ska-tmc/ska-tmc-mccsmasterleafnode-low/src/ska_tmc_mccsmasterleafnode_low/mccs_master_leaf_node.py
ska-telescope/tmc-prototype
4138274e933d4b05f7fe9fc34a11c417b6d0d336
[ "BSD-3-Clause" ]
19
2019-01-07T14:50:26.000Z
2019-10-02T13:25:23.000Z
ska-tmc/ska-tmc-mccsmasterleafnode-low/src/ska_tmc_mccsmasterleafnode_low/mccs_master_leaf_node.py
ska-telescope/tmc-prototype
4138274e933d4b05f7fe9fc34a11c417b6d0d336
[ "BSD-3-Clause" ]
1
2018-12-21T13:39:23.000Z
2018-12-21T13:39:23.000Z
# -*- coding: utf-8 -*- # # This file is part of the MccsMasterLeafNode project # # # # Distributed under the terms of the BSD-3-Clause license. # See LICENSE.txt for more info. # PROTECTED REGION ID(MccsMasterLeafNode.import) ENABLED START # import threading # Tango imports import tango from tango import ApiUtil, Deb...
32.656126
101
0.643307
import threading import tango from tango import ApiUtil, DebugIt, AttrWriteType from tango.server import run, command, device_property, attribute from ska.base import SKABaseDevice from ska.base.commands import ResultCode from ska.base.control_model import HealthState, SimulationMode, TestMode from tmc.comm...
true
true
1c1ee2f6084fab2c6c38fb8020802418855de7c2
761
py
Python
required_files.py
mcglynnk/AdhereID_app
7e15f695f8f17afe588abb5f9dd3cc1fa9e3ede5
[ "MIT" ]
null
null
null
required_files.py
mcglynnk/AdhereID_app
7e15f695f8f17afe588abb5f9dd3cc1fa9e3ede5
[ "MIT" ]
null
null
null
required_files.py
mcglynnk/AdhereID_app
7e15f695f8f17afe588abb5f9dd3cc1fa9e3ede5
[ "MIT" ]
null
null
null
import pandas as pd X = pd.read_csv(r'C:\Users\Kelly\Documents\Python\AdhereID_app\files\X2.csv', index_col=0) plm = pd.read_csv(r'C:\Users\Kelly\Documents\Python\AdhereID_app\files\plm.csv') conditions_list_file = r'C:\Users\Kelly\Documents\Python\AdhereID_app\files\cond_list.txt' drugs_list_file = r'C:\Users\Kelly\D...
38.05
90
0.760841
import pandas as pd X = pd.read_csv(r'C:\Users\Kelly\Documents\Python\AdhereID_app\files\X2.csv', index_col=0) plm = pd.read_csv(r'C:\Users\Kelly\Documents\Python\AdhereID_app\files\plm.csv') conditions_list_file = r'C:\Users\Kelly\Documents\Python\AdhereID_app\files\cond_list.txt' drugs_list_file = r'C:\Users\Kelly\D...
true
true
1c1ee38c95d1c17e591b0bb098fb97a8633e1bcc
2,582
py
Python
vitamins/match/match.py
ericmburgess/ramen-and-vitamins
62548f30421cef0f3ed554cec5a95abb8e24c7b9
[ "MIT" ]
null
null
null
vitamins/match/match.py
ericmburgess/ramen-and-vitamins
62548f30421cef0f3ed554cec5a95abb8e24c7b9
[ "MIT" ]
null
null
null
vitamins/match/match.py
ericmburgess/ramen-and-vitamins
62548f30421cef0f3ed554cec5a95abb8e24c7b9
[ "MIT" ]
null
null
null
"""vitamins.match.match -- Class for representing the current match.""" from typing import List from rlbot.agents.base_agent import BaseAgent from rlbot.utils.structures.game_data_struct import GameTickPacket from vitamins.match.ball import Ball from vitamins.match.car import Car from vitamins.match.field import Fiel...
34.891892
86
0.656468
from typing import List from rlbot.agents.base_agent import BaseAgent from rlbot.utils.structures.game_data_struct import GameTickPacket from vitamins.match.ball import Ball from vitamins.match.car import Car from vitamins.match.field import Field from vitamins.match.prediction import BallPredictor class Match: ...
true
true
1c1ee3d2f5418f4df49deb4e8eebdbd7e0b84cac
16,974
py
Python
cogs/web_api.py
DiscordHackers/BetterBot
5b21c9b1280d205fa0b81c99f87626c1c8a24b81
[ "Apache-2.0" ]
null
null
null
cogs/web_api.py
DiscordHackers/BetterBot
5b21c9b1280d205fa0b81c99f87626c1c8a24b81
[ "Apache-2.0" ]
null
null
null
cogs/web_api.py
DiscordHackers/BetterBot
5b21c9b1280d205fa0b81c99f87626c1c8a24b81
[ "Apache-2.0" ]
null
null
null
from xmlrpc.client import Boolean from disnake import * from disnake.ext import commands import random from flask import Flask, jsonify, url_for, redirect, request, send_file, render_template, send_from_directory from werkzeug.exceptions import HTTPException import json from threading import Thread from functools impor...
36.581897
198
0.585012
from xmlrpc.client import Boolean from disnake import * from disnake.ext import commands import random from flask import Flask, jsonify, url_for, redirect, request, send_file, render_template, send_from_directory from werkzeug.exceptions import HTTPException import json from threading import Thread from functools impor...
true
true
1c1ee431aee850874e904a6fb1ce737417bafeca
8,289
py
Python
detectron/datasets/dataset_catalog.py
KittyLiou/PolygonRCNN
a6059d350c12d53ba8d4bc8a05fb18b120b99ed8
[ "Apache-2.0" ]
12
2018-09-18T12:28:46.000Z
2021-04-14T19:54:32.000Z
detectron/datasets/dataset_catalog.py
KittyLiou/PolygonRCNN
a6059d350c12d53ba8d4bc8a05fb18b120b99ed8
[ "Apache-2.0" ]
null
null
null
detectron/datasets/dataset_catalog.py
KittyLiou/PolygonRCNN
a6059d350c12d53ba8d4bc8a05fb18b120b99ed8
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2017-present, Facebook, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed...
30.814126
89
0.609603
_IM_DIR: _DATA_DIR + '/coco/coco_test2015', _ANN_FN: _DATA_DIR + '/coco/annotations/image_info_test-dev2017.json', _IM_PREFIX: 'COCO_test2015_' }, 'coco_stuff_train': { _IM_DIR: _DATA_DIR + '/coco/coco_train2014', ...
true
true
1c1ee4b7f26a43eb7ca7a91a13a644198da261cb
916
py
Python
debinix/api/greetings.py
berrak/debinix
64680c883357894e99ab9cf6362cbc8e6da06d61
[ "Apache-2.0" ]
null
null
null
debinix/api/greetings.py
berrak/debinix
64680c883357894e99ab9cf6362cbc8e6da06d61
[ "Apache-2.0" ]
null
null
null
debinix/api/greetings.py
berrak/debinix
64680c883357894e99ab9cf6362cbc8e6da06d61
[ "Apache-2.0" ]
null
null
null
# # Copyright Bertil Kronlund, 2017 # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writin...
25.444444
74
0.688865
class Greetings(object): def __init__(self, msg="Hello world!"): self.msg = msg def __str__(self): return self.msg def howdy_greeting(): return "Howdy cowboy!"
true
true
1c1ee664a99798917468dd2eaac048c1bca4838d
19,035
py
Python
emdenoise/build/main.py
danielsnider/mlcube_examples
0d273ffcf1ee7d791f1c4b01dbaf9d00c6876dd9
[ "Apache-2.0" ]
null
null
null
emdenoise/build/main.py
danielsnider/mlcube_examples
0d273ffcf1ee7d791f1c4b01dbaf9d00c6876dd9
[ "Apache-2.0" ]
null
null
null
emdenoise/build/main.py
danielsnider/mlcube_examples
0d273ffcf1ee7d791f1c4b01dbaf9d00c6876dd9
[ "Apache-2.0" ]
1
2022-03-03T19:24:05.000Z
2022-03-03T19:24:05.000Z
from __future__ import (absolute_import, division, print_function, unicode_literals) from abc import (abstractmethod, ABC) import time import h5py import tensorflow as tf import numpy as np from pathlib import Path import horovod.tensorflow.keras as hvd from tinydb import (TinyDB, Query) import yaml import os import lo...
33.690265
111
0.621539
from __future__ import (absolute_import, division, print_function, unicode_literals) from abc import (abstractmethod, ABC) import time import h5py import tensorflow as tf import numpy as np from pathlib import Path import horovod.tensorflow.keras as hvd from tinydb import (TinyDB, Query) import yaml import os import lo...
true
true
1c1ee6c3b97f58f6dd8dc67aba650d45bcd9726c
602
py
Python
docs/pyqt/widzety/gui_z1.py
damiankarol7/python101
1978a9402a8fb0f20c4ca7bd542cb8d7d4501b9b
[ "MIT" ]
44
2015-02-11T19:10:37.000Z
2021-11-11T09:45:43.000Z
docs/pyqt/widzety/gui_z1.py
damiankarol7/python101
1978a9402a8fb0f20c4ca7bd542cb8d7d4501b9b
[ "MIT" ]
9
2015-02-06T21:26:25.000Z
2022-03-31T10:44:22.000Z
docs/pyqt/widzety/gui_z1.py
damiankarol7/python101
1978a9402a8fb0f20c4ca7bd542cb8d7d4501b9b
[ "MIT" ]
172
2015-06-13T07:16:24.000Z
2022-03-30T20:41:11.000Z
#!/usr/bin/python # -*- coding: utf-8 -*- from __future__ import unicode_literals from ksztalty import Ksztalty, Ksztalt from PyQt5.QtWidgets import QHBoxLayout class Ui_Widget(object): """ Klasa definiująca GUI """ def setupUi(self, Widget): # widget rysujący kształty, instancja klasy Ksztalt ...
26.173913
70
0.69103
from __future__ import unicode_literals from ksztalty import Ksztalty, Ksztalt from PyQt5.QtWidgets import QHBoxLayout class Ui_Widget(object): def setupUi(self, Widget): self.ksztalt = Ksztalt(self, Ksztalty.Polygon) ukladH1 = QHBoxLayout() ukladH1.addWidget(self.k...
true
true
1c1ee801757c8ce064fe28b6e0b9a6411f90f417
4,625
py
Python
Taxonomy_Completion_Module/parse_config.py
QingkaiZeng/GenTaxo
10257a1714d14c6a4c49cbfa0b507408f718cdf0
[ "MIT" ]
28
2021-06-08T02:51:11.000Z
2021-11-29T09:33:17.000Z
parse_config.py
captify-dhordiiuk/TMN
143626237f22060fec5ccfa8451429cf42460a00
[ "Apache-2.0" ]
2
2021-04-08T07:35:15.000Z
2021-05-22T21:54:17.000Z
parse_config.py
minhaoJ2/TaxoEnrich
179104f09e73216aff04c502d4c7e6286c296ff4
[ "Apache-2.0" ]
8
2021-03-09T03:41:29.000Z
2022-03-27T05:35:48.000Z
import os import logging from pathlib import Path from functools import reduce from operator import getitem from datetime import datetime from logger import setup_logging from utils import read_json, write_json class ConfigParser: def __init__(self, args, options='', timestamp=True): # parse default and c...
36.417323
121
0.640865
import os import logging from pathlib import Path from functools import reduce from operator import getitem from datetime import datetime from logger import setup_logging from utils import read_json, write_json class ConfigParser: def __init__(self, args, options='', timestamp=True): for opt in o...
true
true
1c1ee8ac1bbf369aec857b13ed467b7b6c6932f9
6,159
py
Python
traffic/data/basic/airways.py
MichelKhalaf/traffic
84e315d84a4ab9d8711414e7c275733e27a089ed
[ "MIT" ]
null
null
null
traffic/data/basic/airways.py
MichelKhalaf/traffic
84e315d84a4ab9d8711414e7c275733e27a089ed
[ "MIT" ]
null
null
null
traffic/data/basic/airways.py
MichelKhalaf/traffic
84e315d84a4ab9d8711414e7c275733e27a089ed
[ "MIT" ]
null
null
null
from __future__ import annotations import logging from io import BytesIO from pathlib import Path from typing import Tuple, Union import pandas as pd from shapely.geometry.base import BaseGeometry from ...core.mixins import GeoDBMixin from ...core.structure import Navaid, Route __github_url = "https://raw.githubuse...
32.935829
80
0.547816
from __future__ import annotations import logging from io import BytesIO from pathlib import Path from typing import Tuple, Union import pandas as pd from shapely.geometry.base import BaseGeometry from ...core.mixins import GeoDBMixin from ...core.structure import Navaid, Route __github_url = "https://raw.githubuse...
true
true
1c1ee8eebb862c47575aa3f27fd6d8cd759b6f9e
61,514
py
Python
edexOsgi/com.raytheon.edex.plugin.gfe/utility/common_static/base/gfe/textproducts/templates/product/CWF.py
srcarter3/awips2
37f31f5e88516b9fd576eaa49d43bfb762e1d174
[ "Apache-2.0" ]
null
null
null
edexOsgi/com.raytheon.edex.plugin.gfe/utility/common_static/base/gfe/textproducts/templates/product/CWF.py
srcarter3/awips2
37f31f5e88516b9fd576eaa49d43bfb762e1d174
[ "Apache-2.0" ]
null
null
null
edexOsgi/com.raytheon.edex.plugin.gfe/utility/common_static/base/gfe/textproducts/templates/product/CWF.py
srcarter3/awips2
37f31f5e88516b9fd576eaa49d43bfb762e1d174
[ "Apache-2.0" ]
1
2021-10-30T00:03:05.000Z
2021-10-30T00:03:05.000Z
## # This software was developed and / or modified by Raytheon Company, # pursuant to Contract DG133W-05-CQ-1067 with the US Government. # # U.S. EXPORT CONTROLLED TECHNICAL DATA # This software product contains export-restricted data whose # export/transfer/disclosure is restricted by U.S. law. Dissemination # to ...
46.320783
104
0.510144
# Chance' or 'Isolated' weather types (ERH policy import TextRules import SampleAnalysis import ForecastN...
false
true
1c1ee92f9d0af6c02a5266ab7aa518a7a06dd38c
2,508
py
Python
leergramatica.py
AbeJLazaro/AutomataPushDownASA
28f4a75e8962a72cc14c9c8d9c1a670cab40a023
[ "MIT" ]
null
null
null
leergramatica.py
AbeJLazaro/AutomataPushDownASA
28f4a75e8962a72cc14c9c8d9c1a670cab40a023
[ "MIT" ]
null
null
null
leergramatica.py
AbeJLazaro/AutomataPushDownASA
28f4a75e8962a72cc14c9c8d9c1a670cab40a023
[ "MIT" ]
null
null
null
''' Autor: Lázaro Martínez Abraham Josué Titulo: leergramatica.py Versión: 1.0 Fecha: 6 de diciembre de 2020 ''' def informacion(nombre): '''Obtiene la información de la gramatica de los archivos Parámetros nombre: nombre del archivo que contiene la información de la gramática return ...
28.827586
74
0.5937
def informacion(nombre): import sys if sys.platform != "linux": sec = "->" else: sec = "→" archivo = open(nombre,"r") datos = archivo.readlines() archivo.close() info={} for linea in datos: if "No terminales:" in linea: N = linea.split("No terminales:")[1].strip().split(" ") ...
true
true
1c1ee9b5ddf283aa05c2a26411098b4690a74700
3,000
py
Python
main/views.py
Ritamwaura/one_minute-pitch
318c75b01d5128d42ececdbd7dfc6dcd9ea6b194
[ "MIT" ]
null
null
null
main/views.py
Ritamwaura/one_minute-pitch
318c75b01d5128d42ececdbd7dfc6dcd9ea6b194
[ "MIT" ]
null
null
null
main/views.py
Ritamwaura/one_minute-pitch
318c75b01d5128d42ececdbd7dfc6dcd9ea6b194
[ "MIT" ]
null
null
null
from flask import render_template,request,redirect,url_for,abort from . import main from .forms import ReviewForm,UpdateProfile,PitchForm from ..models import Review,User,Pitch from flask_login import login_required,current_user from .. import db,photos import markdown2 @main.route('/') def index(): ''' view...
25.210084
112
0.649
from flask import render_template,request,redirect,url_for,abort from . import main from .forms import ReviewForm,UpdateProfile,PitchForm from ..models import Review,User,Pitch from flask_login import login_required,current_user from .. import db,photos import markdown2 @main.route('/') def index(): title ...
true
true
1c1eea891c14a208222de9c41ad26f2fbf010557
6,515
py
Python
matrix_content_scanner/servlets/__init__.py
babolivier/matrix-content-scanner-python
3a9fe707467a551d06fedb94921d057f9177728f
[ "Apache-2.0" ]
1
2021-12-10T18:59:02.000Z
2021-12-10T18:59:02.000Z
matrix_content_scanner/servlets/__init__.py
babolivier/matrix-content-scanner-python
3a9fe707467a551d06fedb94921d057f9177728f
[ "Apache-2.0" ]
null
null
null
matrix_content_scanner/servlets/__init__.py
babolivier/matrix-content-scanner-python
3a9fe707467a551d06fedb94921d057f9177728f
[ "Apache-2.0" ]
null
null
null
# Copyright 2022 The Matrix.org Foundation C.I.C. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable la...
32.575
86
0.66109
import abc import json from typing import Any, Awaitable, Callable, Optional, Tuple from twisted.internet import defer from twisted.web.http import Request from twisted.web.resource import Resource from twisted.web.server import NOT_DONE_YET from matrix_content_scanner import logging from matrix_content_...
true
true
1c1eeb25dd46a474973a54a1d3f91d60ec6ea886
359
py
Python
connection.py
kjaymiller/elasticsearch_dcat_us_parser
9d552658e6f1bd3e7ac6e0b637c2bcef0bf9dc0f
[ "MIT" ]
null
null
null
connection.py
kjaymiller/elasticsearch_dcat_us_parser
9d552658e6f1bd3e7ac6e0b637c2bcef0bf9dc0f
[ "MIT" ]
2
2020-11-20T01:18:44.000Z
2020-11-20T01:29:53.000Z
connection.py
kjaymiller/elasticsearch_dcat_us_parser
9d552658e6f1bd3e7ac6e0b637c2bcef0bf9dc0f
[ "MIT" ]
null
null
null
from elasticsearch import Elasticsearch import os username, password = ( os.environ.get('ELASTIC_USERNAME','elastic'), os.environ.get('ELASTICSEARCH_PASSWORD'), ) client = Elasticsearch( cloud_id=os.environ['CLOUD_ID'], # hosts = ['localhost'], for local instance http_...
22.4375
53
0.635097
from elasticsearch import Elasticsearch import os username, password = ( os.environ.get('ELASTIC_USERNAME','elastic'), os.environ.get('ELASTICSEARCH_PASSWORD'), ) client = Elasticsearch( cloud_id=os.environ['CLOUD_ID'], http_auth=(username, password), )
true
true
1c1eeb31caf16772b0f27fa30c823c5f816694f9
80
py
Python
modulo 1/d021/audio.py
rafa-evangelista/PYTHON
761ec7e01f1617263bc023a6b82b599a936275ee
[ "MIT" ]
null
null
null
modulo 1/d021/audio.py
rafa-evangelista/PYTHON
761ec7e01f1617263bc023a6b82b599a936275ee
[ "MIT" ]
null
null
null
modulo 1/d021/audio.py
rafa-evangelista/PYTHON
761ec7e01f1617263bc023a6b82b599a936275ee
[ "MIT" ]
null
null
null
import webbrowser webbrowser.open('D:\Rafael\Músicas\David Bowie - Heroes.mp3')
26.666667
61
0.7875
import webbrowser webbrowser.open('D:\Rafael\Músicas\David Bowie - Heroes.mp3')
true
true
1c1eeb6e19a666ffa95f27a326589dccd6bfab98
425
py
Python
extractors/address.py
dexmo007/dexpenses-extract
d1077eb727b10cf9ae0a5086ba2f1059cce8cfab
[ "MIT" ]
null
null
null
extractors/address.py
dexmo007/dexpenses-extract
d1077eb727b10cf9ae0a5086ba2f1059cce8cfab
[ "MIT" ]
4
2021-03-18T22:31:23.000Z
2022-01-13T01:12:37.000Z
extractors/address.py
dexmo007/dexpenses-extract
d1077eb727b10cf9ae0a5086ba2f1059cce8cfab
[ "MIT" ]
null
null
null
import re import googlemaps from extractors import DependentExtractor from extractors.header import HeaderExtractor class AddressExtractor(DependentExtractor): def __init__(self, gmaps_key): super().__init__('address', after=HeaderExtractor) self.gmaps = googlemaps.Client(key=gmaps_key) def ...
28.333333
65
0.743529
import re import googlemaps from extractors import DependentExtractor from extractors.header import HeaderExtractor class AddressExtractor(DependentExtractor): def __init__(self, gmaps_key): super().__init__('address', after=HeaderExtractor) self.gmaps = googlemaps.Client(key=gmaps_key) def ...
true
true
1c1eebc4e2722c639704426fba7351e601bf724c
22,906
py
Python
keyboardHandler.py
shash7/controller
48aa0f9c3f35ec868311d5f1483ff2ae6ab6f1b7
[ "MIT" ]
null
null
null
keyboardHandler.py
shash7/controller
48aa0f9c3f35ec868311d5f1483ff2ae6ab6f1b7
[ "MIT" ]
null
null
null
keyboardHandler.py
shash7/controller
48aa0f9c3f35ec868311d5f1483ff2ae6ab6f1b7
[ "MIT" ]
null
null
null
import win32api import win32con import time import sys #Giant dictonary to hold key name and VK value VK_CODE = {'backspace':0x08, 'tab':0x09, 'clear':0x0C, 'enter':0x0D, 'shift':0x10, 'ctrl':0x11, 'alt':0x12, 'pause':0x13, 'caps_...
37.861157
86
0.555531
import win32api import win32con import time import sys VK_CODE = {'backspace':0x08, 'tab':0x09, 'clear':0x0C, 'enter':0x0D, 'shift':0x10, 'ctrl':0x11, 'alt':0x12, 'pause':0x13, 'caps_lock':0x14, 'esc':0x1B, ...
true
true
1c1eec0340faee0c1206cd3ae4fc036b04bac2c0
1,316
py
Python
src/day5.py
KraProgrammer/AdventOfCode2020
937e743bfab228449e6bad2d06267c9c999afd1d
[ "MIT" ]
1
2020-12-17T11:00:00.000Z
2020-12-17T11:00:00.000Z
src/day5.py
KraProgrammer/AdventOfCode2020
937e743bfab228449e6bad2d06267c9c999afd1d
[ "MIT" ]
null
null
null
src/day5.py
KraProgrammer/AdventOfCode2020
937e743bfab228449e6bad2d06267c9c999afd1d
[ "MIT" ]
null
null
null
from math import ceil, floor import numpy as np from aocd.models import Puzzle def solve_puzzle_one(input_array): ids = map(lambda bp: calc_id(bp, 7), input_array) print(max(ids)) def calc_id(bp, length_first=7): first = bp[0:length_first] sec = bp[length_first:] first_upper = pow(2, len(first)...
23.5
57
0.62766
from math import ceil, floor import numpy as np from aocd.models import Puzzle def solve_puzzle_one(input_array): ids = map(lambda bp: calc_id(bp, 7), input_array) print(max(ids)) def calc_id(bp, length_first=7): first = bp[0:length_first] sec = bp[length_first:] first_upper = pow(2, len(first)...
true
true
1c1eec5af30a1a95f1e2c7df117de5cedbfb3973
1,055
py
Python
src/server/Language.py
kestux75/RotorHazard
a8536f8589f38b99383010d2e012cf2741120436
[ "MIT" ]
null
null
null
src/server/Language.py
kestux75/RotorHazard
a8536f8589f38b99383010d2e012cf2741120436
[ "MIT" ]
null
null
null
src/server/Language.py
kestux75/RotorHazard
a8536f8589f38b99383010d2e012cf2741120436
[ "MIT" ]
null
null
null
# # Translation functions # import logging import json import Options logger = logging.getLogger(__name__) LANGUAGE_FILE_NAME = 'language.json' Languages = {} # Load language file try: with open(LANGUAGE_FILE_NAME, 'r') as f: Languages = json.load(f) logger.info('Language file imported') except IOEr...
21.530612
57
0.645498
import logging import json import Options logger = logging.getLogger(__name__) LANGUAGE_FILE_NAME = 'language.json' Languages = {} try: with open(LANGUAGE_FILE_NAME, 'r') as f: Languages = json.load(f) logger.info('Language file imported') except IOError: logger.warn('No language file found,...
true
true
1c1eed0e89d18c6bbc28ac1c3e77b53537c3fb3d
3,509
py
Python
homeassistant/components/yessssms/notify.py
tecknicaltom/home-assistant
5c50fa34056ba2cd0c91c06cbb6a9c894b4be92e
[ "Apache-2.0" ]
3
2020-10-23T14:39:11.000Z
2021-02-17T14:40:17.000Z
homeassistant/components/yessssms/notify.py
tecknicaltom/home-assistant
5c50fa34056ba2cd0c91c06cbb6a9c894b4be92e
[ "Apache-2.0" ]
3
2018-01-23T20:41:55.000Z
2018-01-23T20:42:12.000Z
homeassistant/components/yessssms/notify.py
tecknicaltom/home-assistant
5c50fa34056ba2cd0c91c06cbb6a9c894b4be92e
[ "Apache-2.0" ]
6
2020-04-10T06:21:11.000Z
2021-07-01T08:53:38.000Z
"""Support for the YesssSMS platform.""" import logging import voluptuous as vol from YesssSMS import YesssSMS from homeassistant.const import CONF_PASSWORD, CONF_RECIPIENT, CONF_USERNAME import homeassistant.helpers.config_validation as cv from homeassistant.components.notify import PLATFORM_SCHEMA, BaseNotificati...
33.103774
88
0.618125
import logging import voluptuous as vol from YesssSMS import YesssSMS from homeassistant.const import CONF_PASSWORD, CONF_RECIPIENT, CONF_USERNAME import homeassistant.helpers.config_validation as cv from homeassistant.components.notify import PLATFORM_SCHEMA, BaseNotificationService from .const import CONF_PROVI...
true
true
1c1eedcfe04a2b8fb2488ea302e28144a40fe7d6
1,241
py
Python
setup.py
srikiraju/rollbar-agent
23cf28d61732fd3f251bfdf9368b796dfa4b86e9
[ "MIT" ]
1
2021-06-14T18:05:42.000Z
2021-06-14T18:05:42.000Z
setup.py
srikiraju/rollbar-agent
23cf28d61732fd3f251bfdf9368b796dfa4b86e9
[ "MIT" ]
null
null
null
setup.py
srikiraju/rollbar-agent
23cf28d61732fd3f251bfdf9368b796dfa4b86e9
[ "MIT" ]
null
null
null
import os.path from setuptools import Command, find_packages, setup HERE = os.path.abspath(os.path.dirname(__file__)) README_PATH = os.path.join(HERE, 'README.rst') try: README = open(README_PATH).read() except IOError: README = '' setup( name='rollbar-agent', data_files=[('', ['rollbar-agent', 'roll...
27.577778
119
0.616438
import os.path from setuptools import Command, find_packages, setup HERE = os.path.abspath(os.path.dirname(__file__)) README_PATH = os.path.join(HERE, 'README.rst') try: README = open(README_PATH).read() except IOError: README = '' setup( name='rollbar-agent', data_files=[('', ['rollbar-agent', 'roll...
true
true
1c1eef2c401cb787cf436b4656e8373ea8f5fced
1,449
py
Python
practice/01/pygame_1.5_all_border_move_without_trace_rectangle_static.py
kolyasalubov/Lv-677.PythonCore
c9f9107c734a61e398154a90b8a3e249276c2704
[ "MIT" ]
null
null
null
practice/01/pygame_1.5_all_border_move_without_trace_rectangle_static.py
kolyasalubov/Lv-677.PythonCore
c9f9107c734a61e398154a90b8a3e249276c2704
[ "MIT" ]
null
null
null
practice/01/pygame_1.5_all_border_move_without_trace_rectangle_static.py
kolyasalubov/Lv-677.PythonCore
c9f9107c734a61e398154a90b8a3e249276c2704
[ "MIT" ]
6
2022-02-22T22:30:49.000Z
2022-03-28T12:51:19.000Z
import pygame # визначаємо константу затримки кадрів # та інші константи FPS = 60 WIDTH_DISPLAY=500 HEIGHT_DISPLAY=500 WHITE_COLOR = (255, 255, 255) ORANGE_COLOR = (255, 150, 100) BLACK_COLOR = (0,0,0) COORD_X=50 COORD_Y=50 WIDTH_RECTANGLE=40 HEIGHT_RECTANGLE=60 DELTA_STEP=5 # ініціалізація та створення об'єктів...
23.754098
86
0.663216
import pygame FPS = 60 WIDTH_DISPLAY=500 HEIGHT_DISPLAY=500 WHITE_COLOR = (255, 255, 255) ORANGE_COLOR = (255, 150, 100) BLACK_COLOR = (0,0,0) COORD_X=50 COORD_Y=50 WIDTH_RECTANGLE=40 HEIGHT_RECTANGLE=60 DELTA_STEP=5 pygame.init() # pygame.display.set_mode((600, 400)) gameDisplay=pygame.display.set_mode((WID...
true
true
1c1ef08fcb784ae54564c0a94d2add30d857e776
13,155
py
Python
data/coco.py
gpdsec/HSD
8abcf78db5f313266a3bb3f85b9424927fe59a2d
[ "MIT" ]
58
2019-10-15T07:21:50.000Z
2022-03-10T09:29:17.000Z
data/coco.py
tjulyz/HSD
42c8d1c338b09cb7b4f7bb2275253cb207fbce97
[ "MIT" ]
1
2019-11-18T03:51:48.000Z
2019-11-22T07:56:38.000Z
data/coco.py
tjulyz/HSD
42c8d1c338b09cb7b4f7bb2275253cb207fbce97
[ "MIT" ]
8
2019-10-21T03:44:54.000Z
2022-03-24T13:22:28.000Z
"""VOC Dataset Classes Original author: Francisco Massa https://github.com/fmassa/vision/blob/voc_dataset/torchvision/datasets/voc.py Updated by: Ellis Brown, Max deGroot """ import os import pickle import os.path import sys import torch import torch.utils.data as data import torchvision.transforms as transforms imp...
37.69341
84
0.568073
import os import pickle import os.path import sys import torch import torch.utils.data as data import torchvision.transforms as transforms import cv2 import numpy as np import json import uuid from pycocotools.coco import COCO from pycocotools.cocoeval import COCOeval from pycocotools import mask as COCOmask class...
true
true
1c1ef13e9bf89514f4fb9ce463e0f4e501859981
1,224
py
Python
experiments/taxi/taxi_td.py
lschw/rl-experiments
8b911b5d655288a60b12ffbacc123e3a3c78638c
[ "MIT" ]
null
null
null
experiments/taxi/taxi_td.py
lschw/rl-experiments
8b911b5d655288a60b12ffbacc123e3a3c78638c
[ "MIT" ]
null
null
null
experiments/taxi/taxi_td.py
lschw/rl-experiments
8b911b5d655288a60b12ffbacc123e3a3c78638c
[ "MIT" ]
null
null
null
import sys sys.path.insert(0, "../../") import numpy as np import gym import algorithms as alg from evaluate import * env = gym.make("Taxi-v3") print("\nSARSA") alg.utils.random_seed(env, 1) Q,history_sarsa = alg.sarsa( env, alpha=0.5, gamma=0.99, epsilon=0.5, N_episodes=10000, epsilon_decay=alg.utils.decay_l...
29.142857
63
0.74183
import sys sys.path.insert(0, "../../") import numpy as np import gym import algorithms as alg from evaluate import * env = gym.make("Taxi-v3") print("\nSARSA") alg.utils.random_seed(env, 1) Q,history_sarsa = alg.sarsa( env, alpha=0.5, gamma=0.99, epsilon=0.5, N_episodes=10000, epsilon_decay=alg.utils.decay_l...
true
true
1c1ef194dedf6009126190e569e7d7b43b0b9887
3,741
py
Python
tensorflow_recommenders/models/base.py
SamuelMarks/recommenders
49bdc88c939992b6eb431beddcaa24d1253971d7
[ "Apache-2.0" ]
1
2021-06-17T10:56:59.000Z
2021-06-17T10:56:59.000Z
tensorflow_recommenders/models/base.py
dmacjam/recommenders
17d2c6dc9e20a3bcbabff3d4edf0e054128a4a3e
[ "Apache-2.0" ]
null
null
null
tensorflow_recommenders/models/base.py
dmacjam/recommenders
17d2c6dc9e20a3bcbabff3d4edf0e054128a4a3e
[ "Apache-2.0" ]
null
null
null
# Copyright 2020 The TensorFlow Recommenders Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law ...
37.039604
80
0.735899
import tensorflow as tf class Model(tf.keras.Model): def compute_loss(self, inputs, training: bool = False) -> tf.Tensor: raise NotImplementedError( "Implementers must implement the `compute_loss` method.") def train_step(self, inputs): with tf.GradientTape() as tape: los...
true
true
1c1ef22d1789c69f8da3532a46effb88d5322b46
821
py
Python
qiskit/qasm/node/expressionlist.py
jagunnels/qiskit-sdk-py
153cdde972e65c0f23675bbe17c93e18be27bd51
[ "Apache-2.0" ]
null
null
null
qiskit/qasm/node/expressionlist.py
jagunnels/qiskit-sdk-py
153cdde972e65c0f23675bbe17c93e18be27bd51
[ "Apache-2.0" ]
null
null
null
qiskit/qasm/node/expressionlist.py
jagunnels/qiskit-sdk-py
153cdde972e65c0f23675bbe17c93e18be27bd51
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright 2017, IBM. # # This source code is licensed under the Apache License, Version 2.0 found in # the LICENSE.txt file in the root directory of this source tree. """Node for an OPENQASM expression list.""" from .node import Node class ExpressionList(Node): """Node for an OPENQASM...
26.483871
77
0.633374
from .node import Node class ExpressionList(Node): def __init__(self, children): super().__init__('expression_list', children, None) def size(self): return len(self.children) def qasm(self, prec=15): return ",".join([self.children[j].qasm(prec) f...
true
true
1c1ef30cfe6944b04435e66ccadfff98bac9f0a5
6,334
py
Python
binalyzer_core/binding.py
denisvasilik/binalyzer-core
38cdc5d7140ffd84e10059258face2f8b995171d
[ "MIT" ]
null
null
null
binalyzer_core/binding.py
denisvasilik/binalyzer-core
38cdc5d7140ffd84e10059258face2f8b995171d
[ "MIT" ]
null
null
null
binalyzer_core/binding.py
denisvasilik/binalyzer-core
38cdc5d7140ffd84e10059258face2f8b995171d
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ binalyzer_core.binding ~~~~~~~~~~~~~~~~~~~~~~ This module implements the binding engine that is used to bind templates to binary streams. :copyright: 2021 Denis Vasilík :license: MIT """ from .factory import TemplateFactory from .properties import ValueProperty from...
30.897561
84
0.649037
from .factory import TemplateFactory from .properties import ValueProperty from .template_provider import ( TemplateProviderBase, TemplateProvider, ) from .data_provider import ( DataProviderBase, ZeroedDataProvider, PinnedBufferedIODataProvider, ) from .utils import ( leftsiblings, rightsi...
true
true
1c1ef3536c47a06a65bcf64458a17ca3ad9b1073
6,885
py
Python
tests/test_cnn.py
SelmansThesis/stable-baselines3
0146c1d96237b84ce7e5d39022f40e583d7e262b
[ "MIT" ]
null
null
null
tests/test_cnn.py
SelmansThesis/stable-baselines3
0146c1d96237b84ce7e5d39022f40e583d7e262b
[ "MIT" ]
null
null
null
tests/test_cnn.py
SelmansThesis/stable-baselines3
0146c1d96237b84ce7e5d39022f40e583d7e262b
[ "MIT" ]
null
null
null
import os from copy import deepcopy import numpy as np import pytest import torch as th from stable_baselines3 import A2C, DQN, PPO, SAC, TD3 from stable_baselines3.common.identity_env import FakeImageEnv from stable_baselines3.common.utils import zip_strict @pytest.mark.parametrize("model_class", [A2C, PPO, SAC, T...
38.898305
124
0.731736
import os from copy import deepcopy import numpy as np import pytest import torch as th from stable_baselines3 import A2C, DQN, PPO, SAC, TD3 from stable_baselines3.common.identity_env import FakeImageEnv from stable_baselines3.common.utils import zip_strict @pytest.mark.parametrize("model_class", [A2C, PPO, SAC, T...
true
true
1c1ef3554618b034e55d21fe0311088e3340b30f
1,972
py
Python
hello/users/views.py
AwelEshetu/docker_django
6cf53805b725bd8fae7f5c946cf802d4c7a77fbc
[ "MIT" ]
null
null
null
hello/users/views.py
AwelEshetu/docker_django
6cf53805b725bd8fae7f5c946cf802d4c7a77fbc
[ "MIT" ]
null
null
null
hello/users/views.py
AwelEshetu/docker_django
6cf53805b725bd8fae7f5c946cf802d4c7a77fbc
[ "MIT" ]
null
null
null
from django.shortcuts import render from django.http import HttpResponseRedirect from django.urls import reverse # Create your views here. from django.contrib.auth import authenticate, login, logout from django.contrib.auth.forms import AuthenticationForm from django import forms class LoginForm(AuthenticationForm): ...
35.854545
88
0.623225
from django.shortcuts import render from django.http import HttpResponseRedirect from django.urls import reverse from django.contrib.auth import authenticate, login, logout from django.contrib.auth.forms import AuthenticationForm from django import forms class LoginForm(AuthenticationForm): username = forms.Char...
true
true
1c1ef35b9f8e093c7e1211670a970ca96150a317
7,141
py
Python
botstory/ast/story_context/reducers.py
botstory/bot-story
9c5b2fc7f7a14dbd467d70f60d5ba855ef89dac3
[ "MIT" ]
5
2017-01-14T13:42:13.000Z
2021-07-27T21:52:04.000Z
botstory/ast/story_context/reducers.py
botstory/bot-story
9c5b2fc7f7a14dbd467d70f60d5ba855ef89dac3
[ "MIT" ]
235
2016-11-07T23:33:28.000Z
2018-03-13T11:27:33.000Z
botstory/ast/story_context/reducers.py
hyzhak/bot-story
9c5b2fc7f7a14dbd467d70f60d5ba855ef89dac3
[ "MIT" ]
5
2017-01-14T13:42:14.000Z
2020-11-06T08:33:20.000Z
from botstory import matchers from botstory.ast import callable, loop, stack_utils, story_context import logging import inspect logger = logging.getLogger(__name__) def enter_new_scope(ctx): """ we inside new scope with it onw :param ctx: :return: """ ctx = ctx.clone() ctx.waiting_for = c...
34.834146
104
0.507772
from botstory import matchers from botstory.ast import callable, loop, stack_utils, story_context import logging import inspect logger = logging.getLogger(__name__) def enter_new_scope(ctx): ctx = ctx.clone() ctx.waiting_for = ctx.compiled_story().children_matcher() return ctx async def execute(ctx): ...
true
true
1c1ef3a487ed73998d863cdf39b8f205959f594b
1,175
py
Python
backend/config/urls.py
dokenzy/singlecolumn
5001a8a870775fb1c2ee5dcf7f92ee04208a696a
[ "MIT" ]
1
2017-07-03T20:43:52.000Z
2017-07-03T20:43:52.000Z
backend/config/urls.py
dokenzy/singlecolumn
5001a8a870775fb1c2ee5dcf7f92ee04208a696a
[ "MIT" ]
null
null
null
backend/config/urls.py
dokenzy/singlecolumn
5001a8a870775fb1c2ee5dcf7f92ee04208a696a
[ "MIT" ]
null
null
null
"""backend URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/1.10/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: url(r'^$', views.home, name='home') Class-ba...
33.571429
79
0.706383
from django.conf import settings from django.conf.urls import url, include from django.contrib import admin from rest_framework_jwt.views import obtain_jwt_token from vue import views urlpatterns = [ url(r'^admin/', admin.site.urls), url(r'^api/auth/token', obtain_jwt_token), url(r'^api/users/', include(...
true
true
1c1ef3a61d43d07fc389281ac28036a4e8ff8d6c
533
py
Python
kindling/templates/settings/development.py
radiosilence/django-kindling
85c4fa6abc678850a40790ec590635f2397de00b
[ "MIT" ]
null
null
null
kindling/templates/settings/development.py
radiosilence/django-kindling
85c4fa6abc678850a40790ec590635f2397de00b
[ "MIT" ]
1
2020-09-25T06:58:55.000Z
2020-09-28T06:50:23.000Z
kindling/templates/settings/development.py
radiosilence/django-kindling
85c4fa6abc678850a40790ec590635f2397de00b
[ "MIT" ]
null
null
null
from .base import * DATABASES['default']['NAME'] = '{{ app }}_test' DATABASES['default']['USER'] = '{{ app }}_test' DATABASES['default']['ENGINE'] = 'django.db.backends.mysql' DATABASES['default']['OPTIONS'] = {} DEBUG = True TEMPLATE_DEBUG = DEBUG REQUIRE_DEBUG = DEBUG CACHES = { 'default': { 'BACKEND':...
24.227273
65
0.679174
from .base import * DATABASES['default']['NAME'] = '{{ app }}_test' DATABASES['default']['USER'] = '{{ app }}_test' DATABASES['default']['ENGINE'] = 'django.db.backends.mysql' DATABASES['default']['OPTIONS'] = {} DEBUG = True TEMPLATE_DEBUG = DEBUG REQUIRE_DEBUG = DEBUG CACHES = { 'default': { 'BACKEND':...
true
true
1c1ef3e53c80da05d8e498e2dd38ee696b9b5fb7
4,259
py
Python
analysis/jaccard/kbias_analysis.py
commonsense-exception/commonsense-exception
ab83323a2d566f49b6de7b4b06c3c338ceec895f
[ "MIT" ]
null
null
null
analysis/jaccard/kbias_analysis.py
commonsense-exception/commonsense-exception
ab83323a2d566f49b6de7b4b06c3c338ceec895f
[ "MIT" ]
null
null
null
analysis/jaccard/kbias_analysis.py
commonsense-exception/commonsense-exception
ab83323a2d566f49b6de7b4b06c3c338ceec895f
[ "MIT" ]
null
null
null
import pandas as pd import argparse from tqdm import tqdm """ The goal of this file is to produce jaccard analysis to analyze to what extent the k-associative bias of one model coincides with that of another - across the different model pairs and different Ks """ def parse_args(): parser = argparse.ArgumentParser...
39.073394
103
0.640291
import pandas as pd import argparse from tqdm import tqdm def parse_args(): parser = argparse.ArgumentParser(description='arguments for analyzing the top-k bias generation') parser.add_argument('-top', help="Size of intersection of interest", default=10) parser.add_argument('-d', help="source data path (b...
true
true
1c1ef3f19a443458681a1ea16c7a5219b450235a
2,222
py
Python
src/stratis_cli/_actions/_utils.py
stratis-storage/stratis-cli
16efcfe50558785ff44a1570ca554edb2006f8d2
[ "Apache-2.0" ]
94
2017-02-06T11:01:02.000Z
2022-03-19T16:20:50.000Z
src/stratis_cli/_actions/_utils.py
stratis-storage/stratis-cli
16efcfe50558785ff44a1570ca554edb2006f8d2
[ "Apache-2.0" ]
564
2016-08-30T16:23:46.000Z
2022-03-31T01:41:16.000Z
src/stratis_cli/_actions/_utils.py
stratis-storage/stratis-cli
16efcfe50558785ff44a1570ca554edb2006f8d2
[ "Apache-2.0" ]
41
2016-09-13T12:31:42.000Z
2022-03-23T09:42:04.000Z
# Copyright 2020 Red Hat, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing...
29.626667
74
0.670567
import json from .._errors import ( StratisCliMissingClevisTangURLError, StratisCliMissingClevisThumbprintError, ) from .._stratisd_constants import ( CLEVIS_KEY_TANG_TRUST_URL, CLEVIS_KEY_THP, CLEVIS_KEY_URL, CLEVIS_PIN_TANG, CLEVIS_PIN_TPM2, ) def get_clevis_info(namespa...
true
true
1c1ef4e2d746234b0dd6ef08ee3a0dcc1aec90bb
19,005
py
Python
targetran/np/_np.py
bhky/targetran
ae836949448c383d58bb5b5ce70b3a4547f32102
[ "MIT" ]
13
2021-08-29T19:18:27.000Z
2022-03-22T02:21:30.000Z
targetran/np/_np.py
bhky/targetran
ae836949448c383d58bb5b5ce70b3a4547f32102
[ "MIT" ]
null
null
null
targetran/np/_np.py
bhky/targetran
ae836949448c383d58bb5b5ce70b3a4547f32102
[ "MIT" ]
2
2021-11-10T06:12:54.000Z
2021-11-10T20:16:14.000Z
""" API for NumPy usage. """ import functools from typing import Any, Callable, List, Optional, Sequence, Tuple import numpy as np from targetran._check import ( _check_shear_input, _check_translate_input, _check_crop_input, _check_input_range, ) from targetran._np_functional import ( _np_convert...
32.15736
82
0.61568
import functools from typing import Any, Callable, List, Optional, Sequence, Tuple import numpy as np from targetran._check import ( _check_shear_input, _check_translate_input, _check_crop_input, _check_input_range, ) from targetran._np_functional import ( _np_convert, _np_range, _np_cast...
true
true
1c1ef5d24827c9642b623f46ec56b48ed9fde119
4,572
py
Python
nxbt/web/app.py
wyatt3/nxbt
0c1a6be095fc4386d253c189f9566fa582df08db
[ "MIT" ]
null
null
null
nxbt/web/app.py
wyatt3/nxbt
0c1a6be095fc4386d253c189f9566fa582df08db
[ "MIT" ]
null
null
null
nxbt/web/app.py
wyatt3/nxbt
0c1a6be095fc4386d253c189f9566fa582df08db
[ "MIT" ]
null
null
null
import json import os from threading import RLock import time from socket import gethostname from .cert import generate_cert from ..nxbt import Nxbt, PRO_CONTROLLER from flask import Flask, render_template, request from flask_socketio import SocketIO, emit import eventlet app = Flask(__name__, static_url...
27.709091
93
0.582021
import json import os from threading import RLock import time from socket import gethostname from .cert import generate_cert from ..nxbt import Nxbt, PRO_CONTROLLER from flask import Flask, render_template, request from flask_socketio import SocketIO, emit import eventlet app = Flask(__name__, static_url...
true
true
1c1ef63fbc2d65c9f48d11beb3351c73a6876786
35,844
py
Python
virtapi/controller/host_ctrl.py
spiperac/virtapi
9dd27cf2347eac65b7300052cdf581b7c3ded2ff
[ "BSD-2-Clause" ]
11
2017-11-25T23:18:47.000Z
2022-01-17T13:17:25.000Z
virtapi/controller/host_ctrl.py
spiperac/virtapi
9dd27cf2347eac65b7300052cdf581b7c3ded2ff
[ "BSD-2-Clause" ]
2
2021-03-22T16:55:44.000Z
2021-03-25T21:45:59.000Z
virtapi/controller/host_ctrl.py
spiperac/virtapi
9dd27cf2347eac65b7300052cdf581b7c3ded2ff
[ "BSD-2-Clause" ]
1
2020-06-23T07:50:05.000Z
2020-06-23T07:50:05.000Z
""" Host methods and calls __author__ = Strahinja Piperac <spiperac@denkei.org> """ import xml.etree.ElementTree as ET import xmltodict, json, random, uuid, requests import libvirt, os, string, re import shutil, logging from virtapi import utilities import subprocess from time import sleep from lxml import etree from...
36.463886
160
0.527173
import xml.etree.ElementTree as ET import xmltodict, json, random, uuid, requests import libvirt, os, string, re import shutil, logging from virtapi import utilities import subprocess from time import sleep from lxml import etree from lxml.builder import E, ElementMaker from virtapi.settings import * from virtapi.mo...
true
true
1c1ef699a021d9259821535347f121549bb24e5d
2,569
py
Python
test/modules/http2/test_002_curl_basics.py
AlexAT/httpd
60a609e79a5821adba265ec93fc9cbff7bc925be
[ "Apache-2.0" ]
null
null
null
test/modules/http2/test_002_curl_basics.py
AlexAT/httpd
60a609e79a5821adba265ec93fc9cbff7bc925be
[ "Apache-2.0" ]
null
null
null
test/modules/http2/test_002_curl_basics.py
AlexAT/httpd
60a609e79a5821adba265ec93fc9cbff7bc925be
[ "Apache-2.0" ]
null
null
null
import pytest from h2_conf import HttpdConf class TestStore: @pytest.fixture(autouse=True, scope='class') def _class_scope(self, env): HttpdConf(env).add_vhost_test1().add_vhost_test2().install() assert env.apache_restart() == 0 # check that we see the correct documents when using the t...
37.231884
90
0.583106
import pytest from h2_conf import HttpdConf class TestStore: @pytest.fixture(autouse=True, scope='class') def _class_scope(self, env): HttpdConf(env).add_vhost_test1().add_vhost_test2().install() assert env.apache_restart() == 0 def test_002_01(self, env): url = env.mkurl("...
true
true
1c1ef82302b768816315ea35013fb7eb4a3c5d3d
3,924
py
Python
server/app/app/api/users/serializers.py
jphacks/NG_1912
e434d4a40eed67c06a5b977aa80d7fd080b3ee4f
[ "MIT" ]
1
2019-10-20T10:52:59.000Z
2019-10-20T10:52:59.000Z
server/app/app/api/users/serializers.py
jphacks/NG_1912
e434d4a40eed67c06a5b977aa80d7fd080b3ee4f
[ "MIT" ]
null
null
null
server/app/app/api/users/serializers.py
jphacks/NG_1912
e434d4a40eed67c06a5b977aa80d7fd080b3ee4f
[ "MIT" ]
1
2019-10-23T01:31:25.000Z
2019-10-23T01:31:25.000Z
import os import random import string import base64 from rest_auth.registration.serializers import RegisterSerializer from rest_auth.serializers import LoginSerializer, UserDetailsSerializer from rest_framework import serializers from app.users.models import User from django.conf import settings from ibm_watson import ...
38.470588
120
0.648828
import os import random import string import base64 from rest_auth.registration.serializers import RegisterSerializer from rest_auth.serializers import LoginSerializer, UserDetailsSerializer from rest_framework import serializers from app.users.models import User from django.conf import settings from ibm_watson import ...
true
true
1c1ef88c2eb27591fbc3e12836ee747aab076dba
18,877
py
Python
config/default.py
zhangzhw8/bk-nodeman
befda1dcb0fd137874d28f99fa9eaa0a5ba3ddac
[ "MIT" ]
null
null
null
config/default.py
zhangzhw8/bk-nodeman
befda1dcb0fd137874d28f99fa9eaa0a5ba3ddac
[ "MIT" ]
null
null
null
config/default.py
zhangzhw8/bk-nodeman
befda1dcb0fd137874d28f99fa9eaa0a5ba3ddac
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ TencentBlueKing is pleased to support the open source community by making 蓝鲸智云-节点管理(BlueKing-BK-NODEMAN) available. Copyright (C) 2017-2021 THL A29 Limited, a Tencent company. All rights reserved. Licensed under the MIT License (the "License"); you may not use this file except in compliance ...
35.819734
115
0.667585
import sys from blueapps.conf.default_settings import * from config import ENVIRONMENT from pipeline.celery.settings import CELERY_QUEUES as PIPELINE_CELERY_QUEUES from pipeline.celery.settings import CELERY_ROUTES as PIPELINE_CELERY_ROUTES BKAPP_RUN_ENV = os.getenv("BKAPP_RUN_ENV") REDIRECT_FIELD_NAME = "c_ur...
true
true
1c1efba449b225f21a3f0abd1669ee0aff806734
1,165
py
Python
clinicadl/quality_check/t1_linear/cli.py
Raelag0112/clinicadl
4b9508ea6bbe5498069b1d76ad2c3636f67e3184
[ "MIT" ]
null
null
null
clinicadl/quality_check/t1_linear/cli.py
Raelag0112/clinicadl
4b9508ea6bbe5498069b1d76ad2c3636f67e3184
[ "MIT" ]
null
null
null
clinicadl/quality_check/t1_linear/cli.py
Raelag0112/clinicadl
4b9508ea6bbe5498069b1d76ad2c3636f67e3184
[ "MIT" ]
null
null
null
import click from clinicadl.utils import cli_param @click.command(name="t1-linear") @cli_param.argument.caps_directory @click.argument( "output_tsv", type=str, ) @cli_param.option.participant_list @click.option( "--threshold", type=float, default=0.5, show_default=True, help="The threshol...
21.181818
74
0.687554
import click from clinicadl.utils import cli_param @click.command(name="t1-linear") @cli_param.argument.caps_directory @click.argument( "output_tsv", type=str, ) @cli_param.option.participant_list @click.option( "--threshold", type=float, default=0.5, show_default=True, help="The threshol...
true
true
1c1efbc3d8a1784d5092e9ca9b2f0ba548b4434f
3,423
py
Python
ecosound/core/metadata.py
xaviermouy/ecosound
25d333807e090e737b3ac910c2dcf8e5850b91b4
[ "BSD-3-Clause" ]
3
2020-06-05T19:09:05.000Z
2021-02-20T22:16:03.000Z
ecosound/core/metadata.py
xaviermouy/ecosound
25d333807e090e737b3ac910c2dcf8e5850b91b4
[ "BSD-3-Clause" ]
8
2020-09-02T17:27:45.000Z
2022-02-21T16:00:30.000Z
ecosound/core/metadata.py
xaviermouy/ecosound
25d333807e090e737b3ac910c2dcf8e5850b91b4
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Wed May 6 10:56:38 2020 @author: xavier.mouy """ import pandas as pd import os class DeploymentInfo(): """ A class to handle acoustic deployment metadadata . Object carrying deployment metadata that can be used for example to populate metadata fields in Annota...
28.289256
80
0.53754
import pandas as pd import os class DeploymentInfo(): def __init__(self): self.data =[] def write_template(self, filepath): if os.path.isfile(filepath): raise ValueError('File already exists.') metadata = pd.DataFrame({ 'audio_channel_number': [], ...
true
true
1c1efd9cbdce2dfaf220a72e64ac03f30b562942
3,696
py
Python
SampleBufferSonification/File.py
jcstucki/SampleBufferSonfication
d921bff5fc8e89894bd283c1cddcff2f43d4716b
[ "MIT" ]
null
null
null
SampleBufferSonification/File.py
jcstucki/SampleBufferSonfication
d921bff5fc8e89894bd283c1cddcff2f43d4716b
[ "MIT" ]
null
null
null
SampleBufferSonification/File.py
jcstucki/SampleBufferSonfication
d921bff5fc8e89894bd283c1cddcff2f43d4716b
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- #????? 'Copyright (c) 2019 Jacob Colin Stucki III, All Rights Reserved.' import time import ctcsound #kernel from ctcsound import * #The kernel from random import randint # :) import json import nltk #word processing from nltk import word_tokenize #tokens from strings import os import os.path #F...
40.173913
184
0.642316
t time import ctcsound from ctcsound import * from random import randint import json import nltk from nltk import word_tokenize import os import os.path import stat import subprocess import sys import logging from queue import Queue import uuid class File(object): def __init__(self, filePath): #...
true
true
1c1f0134f47df4f58d17c56dc23bd29556384740
189
py
Python
scripts/quest/q29939s.py
Snewmy/swordie
ae01ed4ec0eb20a18730e8cd209eea0b84a8dd17
[ "MIT" ]
9
2021-04-26T11:59:29.000Z
2021-12-20T13:15:27.000Z
scripts/quest/q29939s.py
Snewmy/swordie
ae01ed4ec0eb20a18730e8cd209eea0b84a8dd17
[ "MIT" ]
null
null
null
scripts/quest/q29939s.py
Snewmy/swordie
ae01ed4ec0eb20a18730e8cd209eea0b84a8dd17
[ "MIT" ]
6
2021-07-14T06:32:05.000Z
2022-02-06T02:32:56.000Z
# Dragon Master [100] (29939) medal = 1142157 if sm.canHold(medal): sm.chatScript("You obtained the <Dragon Master> medal.") sm.startQuest(parentID) sm.completeQuest(parentID)
23.625
60
0.708995
medal = 1142157 if sm.canHold(medal): sm.chatScript("You obtained the <Dragon Master> medal.") sm.startQuest(parentID) sm.completeQuest(parentID)
true
true
1c1f017a5bda80be45ce93740c9276eb3a5dfd3d
11,264
py
Python
compiler/compiler.py
omareddash/dnnweaverclone
a803ffb1f52e23595cedb8a6dc095c881d2c62ff
[ "Apache-2.0" ]
null
null
null
compiler/compiler.py
omareddash/dnnweaverclone
a803ffb1f52e23595cedb8a6dc095c881d2c62ff
[ "Apache-2.0" ]
null
null
null
compiler/compiler.py
omareddash/dnnweaverclone
a803ffb1f52e23595cedb8a6dc095c881d2c62ff
[ "Apache-2.0" ]
null
null
null
#!/usr/local/bin/python import argparse import json import caffe_pb2 from google.protobuf.text_format import Merge from DWlayer import DWlayer, ConvLayer, PoolLayer, FCLayer, ReluLayer, LRNLayer, DWMacroLayer, int_to_bin import sys from math import ceil, floor from openProtoBuf import readProtoBuf from dw_sim import Si...
40.085409
150
0.57413
import argparse import json import caffe_pb2 from google.protobuf.text_format import Merge from DWlayer import DWlayer, ConvLayer, PoolLayer, FCLayer, ReluLayer, LRNLayer, DWMacroLayer, int_to_bin import sys from math import ceil, floor from openProtoBuf import readProtoBuf from dw_sim import Simulator from openProtoB...
true
true
1c1f03170494616d79e934e32c2e8f22f57a5e65
284
py
Python
docs/core/benchmarks/banana.py
ioggstream/twisted
34f9b1e3f097685839000c656332c66ee85be5d8
[ "Unlicense", "MIT" ]
3
2020-04-02T06:23:44.000Z
2020-08-13T20:32:31.000Z
docs/core/benchmarks/banana.py
ioggstream/twisted
34f9b1e3f097685839000c656332c66ee85be5d8
[ "Unlicense", "MIT" ]
1
2020-08-02T15:40:49.000Z
2020-08-02T15:40:49.000Z
docs/core/benchmarks/banana.py
ioggstream/twisted
34f9b1e3f097685839000c656332c66ee85be5d8
[ "Unlicense", "MIT" ]
1
2020-07-25T17:56:39.000Z
2020-07-25T17:56:39.000Z
#!/usr/bin/python from timer import timeit from twisted.spread.banana import b1282int ITERATIONS = 100000 for length in (1, 5, 10, 50, 100): elapsed = timeit(b1282int, ITERATIONS, "\xff" * length) print "b1282int %3d byte string: %10d cps" % (length, ITERATIONS / elapsed)
25.818182
79
0.704225
from timer import timeit from twisted.spread.banana import b1282int ITERATIONS = 100000 for length in (1, 5, 10, 50, 100): elapsed = timeit(b1282int, ITERATIONS, "\xff" * length) print "b1282int %3d byte string: %10d cps" % (length, ITERATIONS / elapsed)
false
true
1c1f042fee77061aa9f24024d821d2406afe40c8
1,513
py
Python
fabrik/transfer/scp.py
Frojd/Fabrik
9f2edbba97a7fd236b72a9b3010f6e912ab5c001
[ "MIT" ]
12
2015-11-03T20:41:29.000Z
2019-02-15T17:13:27.000Z
fabrik/transfer/scp.py
Frojd/Fabrik
9f2edbba97a7fd236b72a9b3010f6e912ab5c001
[ "MIT" ]
35
2015-08-23T17:10:00.000Z
2017-05-10T12:08:57.000Z
fabrik/transfer/scp.py
Frojd/Fabrik
9f2edbba97a7fd236b72a9b3010f6e912ab5c001
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ fabrik.transfer.scp ------------------------- Transfer release by scp Params: env.local_app_path: Manually defined path to local app path env.scp_ignore_list: A list of paths that should be ignored on sync """ from fabric.state import env from fabric.operations import local, put f...
24.803279
77
0.658295
from fabric.state import env from fabric.operations import local, put from fabric.context_managers import lcd, cd from fabrik import paths from fabrik.hooks import hook from fabrik.utils.gitext import get_reverse_path def get_local_app_path(): if 'local_app_path' in env: return env.local_app_path ...
true
true
1c1f0439df796b244ee273455ed22b17d5f29323
3,614
py
Python
znail/netem/disciplines.py
Zenterio/znail
68cd3a4b5ae866f3a8846ce1d0fb5f89428a6b18
[ "Apache-2.0" ]
4
2019-02-20T09:40:49.000Z
2019-11-19T21:18:44.000Z
znail/netem/disciplines.py
Zenterio/znail
68cd3a4b5ae866f3a8846ce1d0fb5f89428a6b18
[ "Apache-2.0" ]
4
2019-03-11T15:24:17.000Z
2019-06-14T14:31:01.000Z
znail/netem/disciplines.py
Zenterio/znail
68cd3a4b5ae866f3a8846ce1d0fb5f89428a6b18
[ "Apache-2.0" ]
2
2019-03-05T19:04:06.000Z
2019-09-08T13:53:10.000Z
""" Queueing disciplines (qdisc in tc terminology) describes the flow of packets. For more information about "tc" queueing disciplines, please see: http://man7.org/linux/man-pages/man8/tc.8.html """ class QueueingDiscipline(object): """Base class for all queueing disciplines.""" def __init__(self, name, dis...
27.8
99
0.669618
class QueueingDiscipline(object): def __init__(self, name, discipline): self._name = name self._discipline = discipline @property def name(self): return self._name @property def discipline(self): return self._discipline def __eq__(self, other): for k...
true
true
1c1f04dbc34b892e3943278d85f11f0ef97785ca
2,221
py
Python
tutorials/zed_rgb_convert/launch/zed_rgb_convert.launch.py
stereolabs/zed-ros2-examples
06fdcc778432c0bddebfcbd63fc656853fc89a86
[ "MIT" ]
13
2020-11-15T16:37:31.000Z
2022-02-22T00:39:50.000Z
tutorials/zed_rgb_convert/launch/zed_rgb_convert.launch.py
stereolabs/zed-ros2-examples
06fdcc778432c0bddebfcbd63fc656853fc89a86
[ "MIT" ]
6
2021-03-02T12:46:49.000Z
2022-02-18T16:26:11.000Z
tutorials/zed_rgb_convert/launch/zed_rgb_convert.launch.py
stereolabs/zed-ros2-examples
06fdcc778432c0bddebfcbd63fc656853fc89a86
[ "MIT" ]
7
2020-11-27T22:15:53.000Z
2022-03-18T04:32:03.000Z
import os from launch import LaunchDescription from launch_ros.actions import Node from ament_index_python.packages import get_package_share_directory from launch.substitutions import Command def generate_launch_description(): # Define LaunchDescription variable ld = LaunchDescription() # use: # - ...
27.085366
90
0.605133
import os from launch import LaunchDescription from launch_ros.actions import Node from ament_index_python.packages import get_package_share_directory from launch.substitutions import Command def generate_launch_description(): ld = LaunchDescription() camera_model = 'zed2' ...
true
true
1c1f05165887fe5147d6a7788ab9120e99a8b22c
229
py
Python
frappe-bench/apps/erpnext/erpnext/accounts/doctype/share_type/test_share_type.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
1
2021-04-29T14:55:29.000Z
2021-04-29T14:55:29.000Z
frappe-bench/apps/erpnext/erpnext/accounts/doctype/share_type/test_share_type.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/accounts/doctype/share_type/test_share_type.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
1
2021-04-29T14:39:01.000Z
2021-04-29T14:39:01.000Z
# -*- coding: utf-8 -*- # Copyright (c) 2017, Frappe Technologies Pvt. Ltd. and Contributors # See license.txt from __future__ import unicode_literals import frappe import unittest class TestShareType(unittest.TestCase): pass
20.818182
68
0.768559
from __future__ import unicode_literals import frappe import unittest class TestShareType(unittest.TestCase): pass
true
true
1c1f07b68c0b87efa224471821d9aa838a94a750
11,206
py
Python
tests/test_metrics.py
abcnishant007/sklearn-evaluation
77ff2da43097b0451d8cf6f95c534409f612bf6a
[ "MIT" ]
null
null
null
tests/test_metrics.py
abcnishant007/sklearn-evaluation
77ff2da43097b0451d8cf6f95c534409f612bf6a
[ "MIT" ]
null
null
null
tests/test_metrics.py
abcnishant007/sklearn-evaluation
77ff2da43097b0451d8cf6f95c534409f612bf6a
[ "MIT" ]
null
null
null
from unittest import TestCase from sklearn_evaluation.metrics import (precision_at, labels_at, tp_at, fp_at) import numpy as np from numpy import nan class Test_precision_at(TestCase): def test_perfect_precision(self): labels = np.array([1, 1, 1, 1, 1, 0, 0, 0, 0,...
43.266409
81
0.576655
from unittest import TestCase from sklearn_evaluation.metrics import (precision_at, labels_at, tp_at, fp_at) import numpy as np from numpy import nan class Test_precision_at(TestCase): def test_perfect_precision(self): labels = np.array([1, 1, 1, 1, 1, 0, 0, 0, 0,...
true
true
1c1f07d8cfc68c222e698e87d8f81c0335c9f7b5
758
py
Python
Python/Other/18_ex.py
SitramSoft/programming_practice
5c4131582634b5dc5a586be891bf645ab7dc5f9a
[ "MIT" ]
null
null
null
Python/Other/18_ex.py
SitramSoft/programming_practice
5c4131582634b5dc5a586be891bf645ab7dc5f9a
[ "MIT" ]
null
null
null
Python/Other/18_ex.py
SitramSoft/programming_practice
5c4131582634b5dc5a586be891bf645ab7dc5f9a
[ "MIT" ]
null
null
null
import random def getAnswer(answerNumber): if answerNumber == 1: return 'It is certain' elif answerNumber == 2: return 'It is decidedly so' elif answerNumber == 3: return 'Yes' elif answerNumber == 4: return 'Reply hazy try again' elif answerNumber == 5: retu...
25.266667
43
0.630607
import random def getAnswer(answerNumber): if answerNumber == 1: return 'It is certain' elif answerNumber == 2: return 'It is decidedly so' elif answerNumber == 3: return 'Yes' elif answerNumber == 4: return 'Reply hazy try again' elif answerNumber == 5: retu...
true
true
1c1f086ee45707d7bef509d178697aecdd717b70
8,143
py
Python
downloader.py
Famous8/VDown
9993d0d006d9c90e2401963b265e5be0d5cc4e3c
[ "MIT" ]
null
null
null
downloader.py
Famous8/VDown
9993d0d006d9c90e2401963b265e5be0d5cc4e3c
[ "MIT" ]
null
null
null
downloader.py
Famous8/VDown
9993d0d006d9c90e2401963b265e5be0d5cc4e3c
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'C:/Users/Owner/AppData/Local/Temp/video_downloadereqbltk.ui' # # Created by: PyQt5 UI code generator 5.15.2 # # WARNING: Any manual changes made to this file will be lost when pyuic5 is # run again. Do not edit this file unless you k...
47.9
154
0.681813
from PyQt5 import QtCore, QtGui, QtWidgets class Ui_MainWindow(object): def setupUi(self, MainWindow): MainWindow.setObjectName("MainWindow") MainWindow.resize(730, 533) MainWindow.setStyleSheet("background-color: qlineargradient(x1:0, y0:2, x2:1, y1:0, stop:0.261364 rg...
true
true
1c1f08ac63ebe2cde597fe6f677e756d3bd46bef
2,643
py
Python
tests/reports/utils.py
ayuanty/superset
132a8ef2cb55fa6692ea31d5c278f102d6c2886b
[ "Apache-2.0" ]
19
2018-09-02T10:52:23.000Z
2022-03-24T09:43:48.000Z
tests/reports/utils.py
ayuanty/superset
132a8ef2cb55fa6692ea31d5c278f102d6c2886b
[ "Apache-2.0" ]
77
2020-02-02T07:54:13.000Z
2022-03-23T18:22:04.000Z
tests/reports/utils.py
ayuanty/superset
132a8ef2cb55fa6692ea31d5c278f102d6c2886b
[ "Apache-2.0" ]
15
2019-04-29T05:38:31.000Z
2022-02-12T10:47:54.000Z
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
33.0375
62
0.715475
from typing import List, Optional from flask_appbuilder.security.sqla.models import User from superset import db from superset.models.core import Database from superset.models.dashboard import Dashboard from superset.models.reports import ( ReportDataFormat, ReportExecutionLog, ReportReci...
true
true
1c1f08b317c354b81621b3df8d58fb0ab9752260
1,750
py
Python
main/forms.py
sapuri/srandom.com
e0a7843886a97329f9022d4889ffafa3de708448
[ "MIT" ]
3
2019-05-04T08:22:38.000Z
2019-12-14T13:07:49.000Z
main/forms.py
sapuri/srandom.com
e0a7843886a97329f9022d4889ffafa3de708448
[ "MIT" ]
49
2019-07-02T15:17:09.000Z
2022-03-21T20:11:59.000Z
main/forms.py
sapuri/srandom.com
e0a7843886a97329f9022d4889ffafa3de708448
[ "MIT" ]
null
null
null
from django import forms from django.forms.fields import BooleanField, ChoiceField, IntegerField from django.forms.models import ModelChoiceField from django.forms.widgets import Select from .models import Sran_Level, Medal, Bad_Count, Extra_Option MEDAL_CHOICES = ( (1, 'パーフェクト'), (2, 'フルコンボ ☆'), (3, 'フルコ...
26.119403
110
0.617714
from django import forms from django.forms.fields import BooleanField, ChoiceField, IntegerField from django.forms.models import ModelChoiceField from django.forms.widgets import Select from .models import Sran_Level, Medal, Bad_Count, Extra_Option MEDAL_CHOICES = ( (1, 'パーフェクト'), (2, 'フルコンボ ☆'), (3, 'フルコ...
true
true
1c1f08e40a6e73348401e107894b52805df46f60
392
py
Python
oi/Contest/self/2016-9/airstrike/datagen6.py
Riteme/test
b511d6616a25f4ae8c3861e2029789b8ee4dcb8d
[ "BSD-Source-Code" ]
3
2018-08-30T09:43:20.000Z
2019-12-03T04:53:43.000Z
oi/Contest/self/2016-9/airstrike/datagen6.py
Riteme/test
b511d6616a25f4ae8c3861e2029789b8ee4dcb8d
[ "BSD-Source-Code" ]
null
null
null
oi/Contest/self/2016-9/airstrike/datagen6.py
Riteme/test
b511d6616a25f4ae8c3861e2029789b8ee4dcb8d
[ "BSD-Source-Code" ]
null
null
null
#!/usr/bin/env pypy P = [] N = 250000 sx = -250150 sy = -231 for i in range(0, N): P.append((sx + i, sy - i)) sx = 233 sy = -250100 for i in range(0, N): P.append((sx + i, sy + i)) sx = 250200 sy = 0 for i in range(0, N): P.append((sx - i, sy + i)) sx = -100 sy = 250010 for i in range(0, N): P.app...
13.066667
30
0.497449
P = [] N = 250000 sx = -250150 sy = -231 for i in range(0, N): P.append((sx + i, sy - i)) sx = 233 sy = -250100 for i in range(0, N): P.append((sx + i, sy + i)) sx = 250200 sy = 0 for i in range(0, N): P.append((sx - i, sy + i)) sx = -100 sy = 250010 for i in range(0, N): P.append((sx - i, sy - i...
true
true
1c1f0a4050161caf96a2a67474840d5b9a8ba547
3,984
py
Python
cortex/_lib/__init__.py
tsirif/cortex
2837b220f9fb73279df3815bb18b274106412c08
[ "BSD-3-Clause" ]
109
2016-05-18T16:52:30.000Z
2021-12-22T12:57:31.000Z
cortex/_lib/__init__.py
tsirif/cortex
2837b220f9fb73279df3815bb18b274106412c08
[ "BSD-3-Clause" ]
52
2016-06-07T01:15:51.000Z
2022-03-20T02:24:05.000Z
cortex/_lib/__init__.py
tsirif/cortex
2837b220f9fb73279df3815bb18b274106412c08
[ "BSD-3-Clause" ]
37
2016-05-18T14:05:03.000Z
2021-11-18T10:09:28.000Z
'''Cortex setup ''' import copy import glob import logging import os import pprint from . import config, exp, log_utils, models from .parsing import default_args, parse_args, update_args from .viz import init as viz_init __author__ = 'R Devon Hjelm' __author_email__ = 'erroneus@gmail.com' logger = logging.getLogge...
27.475862
78
0.588353
import copy import glob import logging import os import pprint from . import config, exp, log_utils, models from .parsing import default_args, parse_args, update_args from .viz import init as viz_init __author__ = 'R Devon Hjelm' __author_email__ = 'erroneus@gmail.com' logger = logging.getLogger('cortex.init') de...
true
true
1c1f0b4c582d664c4d93e1ca976a0d7c9711b9d5
10,271
py
Python
tensorflow_model_analysis/evaluators/legacy_aggregate_test.py
Mikehem/tfx
e803ea6778d8550ec77dcc92bc8172f1a3a90f38
[ "Apache-2.0" ]
2
2021-05-29T10:51:27.000Z
2021-06-04T10:49:19.000Z
tensorflow_model_analysis/evaluators/legacy_aggregate_test.py
Saiprasad16/model-analysis
1617375dd35e72447653e54330484c3a2950e4c6
[ "Apache-2.0" ]
1
2021-02-24T00:48:35.000Z
2021-02-24T00:48:35.000Z
tensorflow_model_analysis/evaluators/legacy_aggregate_test.py
Saiprasad16/model-analysis
1617375dd35e72447653e54330484c3a2950e4c6
[ "Apache-2.0" ]
null
null
null
# Lint as: python3 # Copyright 2018 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agr...
38.040741
89
0.652322
from __future__ import absolute_import from __future__ import division from __future__ import print_function import os import apache_beam as beam from apache_beam.testing import util import tensorflow as tf from tensorflow_model_analysis import constants from tensorflow_model_analysis.eval_saved_model i...
true
true
1c1f0b604b3cd8e2d7409a510665bf4fcfda3d62
2,422
py
Python
resources/_buggycode-peer-review/cs09-01-Kevin_Villanueva/studentBuggyCode/lab06.py
VillanuevaK/w21
2f5a970905e62c9ae2de37526ea47c58044845e1
[ "MIT" ]
null
null
null
resources/_buggycode-peer-review/cs09-01-Kevin_Villanueva/studentBuggyCode/lab06.py
VillanuevaK/w21
2f5a970905e62c9ae2de37526ea47c58044845e1
[ "MIT" ]
16
2021-02-05T22:26:21.000Z
2021-03-08T17:51:43.000Z
resources/_buggycode-peer-review/cs09-01-Kevin_Villanueva/studentBuggyCode/lab06.py
VillanuevaK/w21
2f5a970905e62c9ae2de37526ea47c58044845e1
[ "MIT" ]
15
2021-02-04T17:16:50.000Z
2021-02-19T17:50:14.000Z
# lab06.py from Apartment import Apartment def mergesort(apartmentList): if len(apartmentList) > 1: mid = len(apartmentList) // 2 # uses additional space to create the left / right halves lefthalf = apartmentList[:mid] righthalf = apartmentList[mid:] # recursively sort the...
33.178082
179
0.583402
from Apartment import Apartment def mergesort(apartmentList): if len(apartmentList) > 1: mid = len(apartmentList) // 2 lefthalf = apartmentList[:mid] righthalf = apartmentList[mid:] mergesort(lefthalf) mergesort(righthalf) i = ...
true
true
1c1f0b7e15d54539fd9be095345386966b32ce1f
189
py
Python
tasks/__init__.py
blakev/python-eventide
ef547a622c52eec8acb9d7ca4cc01fae0ab7bad0
[ "MIT" ]
1
2021-01-14T18:35:44.000Z
2021-01-14T18:35:44.000Z
tasks/__init__.py
blakev/python-eventide
ef547a622c52eec8acb9d7ca4cc01fae0ab7bad0
[ "MIT" ]
null
null
null
tasks/__init__.py
blakev/python-eventide
ef547a622c52eec8acb9d7ca4cc01fae0ab7bad0
[ "MIT" ]
2
2021-04-20T22:09:02.000Z
2021-07-29T21:52:30.000Z
#! /usr/bin/env python # -*- coding: utf-8 -*- # # >> # python-eventide, 2020 # LiveViewTech # << from invoke import Collection from tasks import build ns = Collection(build=build,)
13.5
29
0.650794
from invoke import Collection from tasks import build ns = Collection(build=build,)
true
true
1c1f0d0e12e41cb2cc5c8db723a001711a2a42bc
2,762
py
Python
tests/view_tests/urls.py
andreip/django
c61d1361d027a729d07d277879950ff133c19f4c
[ "PSF-2.0", "BSD-3-Clause" ]
2
2020-09-25T04:02:25.000Z
2020-10-15T00:01:00.000Z
tests/view_tests/urls.py
andreip/django
c61d1361d027a729d07d277879950ff133c19f4c
[ "PSF-2.0", "BSD-3-Clause" ]
7
2018-06-18T17:56:50.000Z
2020-06-24T16:51:04.000Z
tests/view_tests/urls.py
andreip/django
c61d1361d027a729d07d277879950ff133c19f4c
[ "PSF-2.0", "BSD-3-Clause" ]
2
2019-08-19T20:41:48.000Z
2019-10-10T17:29:52.000Z
from functools import partial from os import path from django.conf.urls import include, url from django.conf.urls.i18n import i18n_patterns from django.utils.translation import gettext_lazy as _ from django.views import defaults, i18n, static from . import views base_dir = path.dirname(path.abspath(__file__)) media_...
40.617647
104
0.701303
from functools import partial from os import path from django.conf.urls import include, url from django.conf.urls.i18n import i18n_patterns from django.utils.translation import gettext_lazy as _ from django.views import defaults, i18n, static from . import views base_dir = path.dirname(path.abspath(__file__)) media_...
true
true
1c1f0d71dc004f6b4647e813178a3e40b84d43e2
6,902
py
Python
kubernetes/client/models/v1beta1_subject.py
pllsxyc/python
442ebc019056c2dc246be94f85cf61f1e1d26a88
[ "Apache-2.0" ]
1
2019-10-07T13:54:36.000Z
2019-10-07T13:54:36.000Z
kubernetes/client/models/v1beta1_subject.py
pllsxyc/python
442ebc019056c2dc246be94f85cf61f1e1d26a88
[ "Apache-2.0" ]
8
2020-10-28T01:18:36.000Z
2021-06-11T01:06:15.000Z
kubernetes/client/models/v1beta1_subject.py
pllsxyc/python
442ebc019056c2dc246be94f85cf61f1e1d26a88
[ "Apache-2.0" ]
1
2021-03-16T16:05:33.000Z
2021-03-16T16:05:33.000Z
# coding: utf-8 """ Kubernetes No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 The version of the OpenAPI document: release-1.16 Generated by: https://openapi-generator.tech """ import pprint import re # noqa: F401 import si...
33.023923
229
0.606636
import pprint import re import six from kubernetes.client.configuration import Configuration class V1beta1Subject(object): openapi_types = { 'api_group': 'str', 'kind': 'str', 'name': 'str', 'namespace': 'str' } attribute_map = { 'api_group': 'apiGroup', ...
true
true
1c1f0e936dec55e1689e9149d6f7b1ec8cc19a4e
2,250
py
Python
akshare/bond/bond_china_money.py
ghmole/akshare
eeeec96f90c6738bcd9ce92fcfa6b9c9176928a6
[ "MIT" ]
12
2020-12-30T02:50:01.000Z
2021-11-08T11:32:51.000Z
akshare/bond/bond_china_money.py
ghmole/akshare
eeeec96f90c6738bcd9ce92fcfa6b9c9176928a6
[ "MIT" ]
3
2021-01-26T09:31:43.000Z
2021-12-08T08:31:54.000Z
akshare/bond/bond_china_money.py
ghmole/akshare
eeeec96f90c6738bcd9ce92fcfa6b9c9176928a6
[ "MIT" ]
13
2020-07-08T08:48:33.000Z
2022-03-23T08:37:11.000Z
# -*- coding:utf-8 -*- # /usr/bin/env python """ Date: 2020/10/7 22:43 Desc: 收盘收益率曲线历史数据 http://www.chinamoney.com.cn/chinese/bkcurvclosedyhis/?bondType=CYCC000&reference=1 """ import pandas as pd import requests def bond_china_close_return_map() -> pd.DataFrame: """ 收盘收益率曲线历史数据 http://www.chinamoney.com....
26.785714
87
0.612444
import pandas as pd import requests def bond_china_close_return_map() -> pd.DataFrame: url = "http://www.chinamoney.com.cn/ags/ms/cm-u-bk-currency/ClsYldCurvCurvGO" r = requests.post(url) data_json = r.json() temp_df = pd.DataFrame(data_json["records"]) return temp_df def bond_china_close_retu...
true
true
1c1f10130aa5258f4d3563c28d13336a7af5ca3c
2,475
py
Python
tools/scons/scons-local-3.0.5/SCons/Tool/g77.py
arcilat-adsk/arnold-usd
34f1b091221f81d027a0c9fceec10f3cfa3ba141
[ "Apache-2.0" ]
2
2020-12-01T03:34:51.000Z
2021-03-06T01:49:44.000Z
tools/scons/scons-local-3.0.5/SCons/Tool/g77.py
arcilat-adsk/arnold-usd
34f1b091221f81d027a0c9fceec10f3cfa3ba141
[ "Apache-2.0" ]
null
null
null
tools/scons/scons-local-3.0.5/SCons/Tool/g77.py
arcilat-adsk/arnold-usd
34f1b091221f81d027a0c9fceec10f3cfa3ba141
[ "Apache-2.0" ]
null
null
null
"""engine.SCons.Tool.g77 Tool-specific initialization for g77. There normally shouldn't be any need to import this module directly. It will usually be imported through the generic SCons.Tool.Tool() selection method. """ # # Copyright (c) 2001 - 2019 The SCons Foundation # # Permission is hereby granted, free of cha...
33.445946
114
0.72202
__revision__ = "src/engine/SCons/Tool/g77.py a56bbd8c09fb219ab8a9673330ffcd55279219d0 2019-03-26 23:16:31 bdeegan" import SCons.Util from SCons.Tool.FortranCommon import add_all_to_env, add_f77_to_env compilers = ['g77', 'f77'] def generate(env): add_all_to_env(env) add_f77_to_env(env...
true
true
1c1f101edfcb79325632cf56f0818a159fc6f771
3,889
py
Python
tensorflow_federated/python/core/backends/native/compiler.py
j35tor/federated
d92bfa6b8e3c9ebbac51ff7a3a180c2baaa08730
[ "Apache-2.0" ]
1
2021-04-01T08:35:06.000Z
2021-04-01T08:35:06.000Z
tensorflow_federated/python/core/backends/native/compiler.py
j35tor/federated
d92bfa6b8e3c9ebbac51ff7a3a180c2baaa08730
[ "Apache-2.0" ]
null
null
null
tensorflow_federated/python/core/backends/native/compiler.py
j35tor/federated
d92bfa6b8e3c9ebbac51ff7a3a180c2baaa08730
[ "Apache-2.0" ]
null
null
null
# Copyright 2020, The TensorFlow Federated Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law o...
41.817204
88
0.778863
from absl import logging from tensorflow_federated.python.core.api import computation_base from tensorflow_federated.python.core.impl.compiler import building_blocks from tensorflow_federated.python.core.impl.compiler import transformations from tensorflow_federated.python.core.impl.computation import co...
true
true
1c1f10db1ee1034d424e68c4b48b425852b7f79f
14,703
py
Python
src/compas/plugins.py
XingxinHE/compas
d2901dbbacdaf4694e5adae78ba8f093f10532bf
[ "MIT" ]
null
null
null
src/compas/plugins.py
XingxinHE/compas
d2901dbbacdaf4694e5adae78ba8f093f10532bf
[ "MIT" ]
null
null
null
src/compas/plugins.py
XingxinHE/compas
d2901dbbacdaf4694e5adae78ba8f093f10532bf
[ "MIT" ]
null
null
null
# The COMPAS plugin system owes a lot to pluggy, the pytest plugin framework # There are portions of code loosely based on pluggy's # and while it is not strictly derivative work, we include # their license and copyright notice to give credit where credit is due. # # MIT license # Copyright (c) 2015 holger krekel (rath...
32.456954
144
0.621642
# and while it is not strictly derivative work, we include # their license and copyright notice to give credit where credit is due. # # MIT license # Copyright (c) 2015 holger krekel (rather uses bitbucket/hpk42) # # https://github.com/pytest-dev/pluggy from __future__ import absolute_import from __future__ import di...
true
true
1c1f1100b4ea2225ab930f1577d6c092989276e2
905
py
Python
src/test/test_simulation.py
4dnucleome/cog-abm
6f6450141a996b067d3a396d47f4386215a4042c
[ "BSD-3-Clause" ]
1
2015-09-27T18:39:11.000Z
2015-09-27T18:39:11.000Z
src/test/test_simulation.py
4dnucleome/cog-abm
6f6450141a996b067d3a396d47f4386215a4042c
[ "BSD-3-Clause" ]
null
null
null
src/test/test_simulation.py
4dnucleome/cog-abm
6f6450141a996b067d3a396d47f4386215a4042c
[ "BSD-3-Clause" ]
null
null
null
import sys sys.path.append('../') import unittest from cog_abm.core.simulation import * class TestSimulation(unittest.TestCase): def setUp(self): pass class TestMultiThreadSimulation(unittest.TestCase): def setUp(self): from cog_abm.extras.additional_tools import generate_network_with_ag...
25.857143
86
0.658564
import sys sys.path.append('../') import unittest from cog_abm.core.simulation import * class TestSimulation(unittest.TestCase): def setUp(self): pass class TestMultiThreadSimulation(unittest.TestCase): def setUp(self): from cog_abm.extras.additional_tools import generate_network_with_ag...
false
true
1c1f118178d15ae1a12cbdae59ada3fcf93d3961
6,063
py
Python
ux/form.py
jmcb/urwidx
88b9cb6e02d19bc4c21b1c2fe3ee008bb03931f2
[ "MIT", "Unlicense" ]
3
2016-07-20T00:15:08.000Z
2022-02-14T01:27:40.000Z
ux/form.py
jmcb/urwidx
88b9cb6e02d19bc4c21b1c2fe3ee008bb03931f2
[ "MIT", "Unlicense" ]
null
null
null
ux/form.py
jmcb/urwidx
88b9cb6e02d19bc4c21b1c2fe3ee008bb03931f2
[ "MIT", "Unlicense" ]
null
null
null
#!/usr/bin/env python import form, app, urwid BIND_TEXT_DEFAULT = True class Form: """ Form: a collection of widgets and associated functions. """ def __init__ (self, parent, top_widget=None): """ Build a new form. Expects to be passed an instance of UrwidApp as its parent. ...
30.315
332
0.622299
import form, app, urwid BIND_TEXT_DEFAULT = True class Form: """ Form: a collection of widgets and associated functions. """ def __init__ (self, parent, top_widget=None): """ Build a new form. Expects to be passed an instance of UrwidApp as its parent. parent: an intance o...
false
true
1c1f11a13d6f0fdc42721d67fffbb514d0af591d
1,530
py
Python
conftest.py
Okamille/mne-python
25df6b63ea3cc2eca1855fcafd8bfbcfd7199263
[ "BSD-3-Clause" ]
null
null
null
conftest.py
Okamille/mne-python
25df6b63ea3cc2eca1855fcafd8bfbcfd7199263
[ "BSD-3-Clause" ]
1
2019-02-14T14:47:17.000Z
2019-02-14T14:47:17.000Z
conftest.py
Okamille/mne-python
25df6b63ea3cc2eca1855fcafd8bfbcfd7199263
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- # Author: Eric Larson <larson.eric.d@gmail.com> # # License: BSD (3-clause) import pytest import warnings # For some unknown reason, on Travis-xenial there are segfaults caused on # the line pytest -> pdb.Pdb.__init__ -> "import readline". Forcing an # import here seems to prevent them (!?). Th...
34.772727
75
0.698039
import pytest import warnings # seems to happen on the Linux runs that install Mayavi. Anectodally, # @larsoner has had problems a couple of years ago where a mayavi import # seemed to corrupt SciPy linalg function results (!), likely due to the # associated VTK import, so this could be another manifestation o...
true
true
1c1f11d783b345d26e801f0f3ce6cd5003c582c4
5,495
py
Python
genre-synopsis-extraction/parse-genre-syn.py
sdruskat/toolbox-scripts
8b27c249706de22ee94525bd98cc922f56c3711c
[ "Apache-2.0" ]
null
null
null
genre-synopsis-extraction/parse-genre-syn.py
sdruskat/toolbox-scripts
8b27c249706de22ee94525bd98cc922f56c3711c
[ "Apache-2.0" ]
null
null
null
genre-synopsis-extraction/parse-genre-syn.py
sdruskat/toolbox-scripts
8b27c249706de22ee94525bd98cc922f56c3711c
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python # -*- coding: utf-8 -*- ############################################################################# # Copyright 2016 Humboldt-Universität zu Berlin # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may ...
41.007463
79
0.55232
false
true
1c1f11e7f0de2134f4a7f66916499cf7430b5c99
5,000
py
Python
HiveExampleBot/hivemind_clean.py
ViliamVadocz/Bots
092abc5bf92e9dab9d07499849d54a33b0b0c4f6
[ "MIT" ]
null
null
null
HiveExampleBot/hivemind_clean.py
ViliamVadocz/Bots
092abc5bf92e9dab9d07499849d54a33b0b0c4f6
[ "MIT" ]
null
null
null
HiveExampleBot/hivemind_clean.py
ViliamVadocz/Bots
092abc5bf92e9dab9d07499849d54a33b0b0c4f6
[ "MIT" ]
null
null
null
'''The Hivemind''' # This is a clean version of hivemind.py so it is easier to start your hivemind bot. import queue import time from rlbot.botmanager.agent_metadata import AgentMetadata from rlbot.botmanager.bot_helper_process import BotHelperProcess from rlbot.utils.logging_utils import get_logger from rlbot.utils....
35.714286
87
0.6586
import queue import time from rlbot.botmanager.agent_metadata import AgentMetadata from rlbot.botmanager.bot_helper_process import BotHelperProcess from rlbot.utils.logging_utils import get_logger from rlbot.utils.structures.bot_input_struct import PlayerInput from rlbot.utils.structures.game_data_struct import Game...
true
true
1c1f126ce94614ae02d701a4a15c8956e3dd4f2f
16,608
py
Python
tensorflow/python/training/checkpoint_utils_test.py
hoangt/tensorflow
f055fb23b726baef93b887d378f4539ad524146f
[ "Apache-2.0" ]
8
2017-03-20T12:04:21.000Z
2021-06-24T20:34:30.000Z
tensorflow/python/training/checkpoint_utils_test.py
hoangt/tensorflow
f055fb23b726baef93b887d378f4539ad524146f
[ "Apache-2.0" ]
null
null
null
tensorflow/python/training/checkpoint_utils_test.py
hoangt/tensorflow
f055fb23b726baef93b887d378f4539ad524146f
[ "Apache-2.0" ]
2
2018-11-03T01:19:26.000Z
2021-04-23T02:34:07.000Z
# Copyright 2016 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
41.728643
80
0.665884
from __future__ import absolute_import from __future__ import division from __future__ import print_function import os import numpy as np from tensorflow.python.framework import dtypes from tensorflow.python.framework import errors_impl from tensorflow.python.framework import ops from tensorflow.python...
true
true
1c1f13c6604130649c627180cd22d77e3cf3c163
27,231
py
Python
ate_run.py
ronaldseoh/GRACE
ab32a79677ed6dd5dfcfb14aaa4d6422ff48675c
[ "Apache-2.0" ]
null
null
null
ate_run.py
ronaldseoh/GRACE
ab32a79677ed6dd5dfcfb14aaa4d6422ff48675c
[ "Apache-2.0" ]
null
null
null
ate_run.py
ronaldseoh/GRACE
ab32a79677ed6dd5dfcfb14aaa4d6422ff48675c
[ "Apache-2.0" ]
null
null
null
from __future__ import absolute_import, division, print_function import argparse import logging import os import random import time import numpy as np import torch import torch.nn.functional as F from file_utils import PYTORCH_PRETRAINED_BERT_CACHE from ate_modeling import BertForSequenceLabeling from optimization im...
46.311224
205
0.65139
from __future__ import absolute_import, division, print_function import argparse import logging import os import random import time import numpy as np import torch import torch.nn.functional as F from file_utils import PYTORCH_PRETRAINED_BERT_CACHE from ate_modeling import BertForSequenceLabeling from optimization im...
true
true
1c1f13ccac79dbfdebcc06a20f52f92e99cb561e
15,921
py
Python
tensorflow/python/framework/dtypes.py
sebastiendazy/tensorflow
2edf3621622a0d2b2140a31d8030d826a82562e0
[ "Apache-2.0" ]
3
2017-03-05T01:56:21.000Z
2018-02-04T17:03:22.000Z
tensorflow/python/framework/dtypes.py
sebastiendazy/tensorflow
2edf3621622a0d2b2140a31d8030d826a82562e0
[ "Apache-2.0" ]
null
null
null
tensorflow/python/framework/dtypes.py
sebastiendazy/tensorflow
2edf3621622a0d2b2140a31d8030d826a82562e0
[ "Apache-2.0" ]
3
2017-02-23T03:20:29.000Z
2018-03-31T11:35:04.000Z
# Copyright 2015 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or a...
32.034205
95
0.704604
from __future__ import absolute_import from __future__ import division from __future__ import print_function import tensorflow.python.platform import numpy as np from tensorflow.core.framework import types_pb2 class DType(object): def __init__(self, type_enum): type_enum = int(type_...
true
true
1c1f1442309296ff64c4a7cfbd69d6a1759e3757
1,621
py
Python
cloudrail/knowledge/context/aws/secretsmanager/secrets_manager_secret.py
my-devops-info/cloudrail-knowledge
b7c1bbd6fe1faeb79c105a01c0debbe24d031a0e
[ "MIT" ]
null
null
null
cloudrail/knowledge/context/aws/secretsmanager/secrets_manager_secret.py
my-devops-info/cloudrail-knowledge
b7c1bbd6fe1faeb79c105a01c0debbe24d031a0e
[ "MIT" ]
null
null
null
cloudrail/knowledge/context/aws/secretsmanager/secrets_manager_secret.py
my-devops-info/cloudrail-knowledge
b7c1bbd6fe1faeb79c105a01c0debbe24d031a0e
[ "MIT" ]
null
null
null
from typing import List, Optional from cloudrail.knowledge.context.aws.kms.kms_key import KmsKey from cloudrail.knowledge.context.aws.secretsmanager.secrets_manager_secret_policy import SecretsManagerSecretPolicy from cloudrail.knowledge.context.aws.service_name import AwsServiceName from cloudrail.knowledge.context.a...
35.23913
115
0.655768
from typing import List, Optional from cloudrail.knowledge.context.aws.kms.kms_key import KmsKey from cloudrail.knowledge.context.aws.secretsmanager.secrets_manager_secret_policy import SecretsManagerSecretPolicy from cloudrail.knowledge.context.aws.service_name import AwsServiceName from cloudrail.knowledge.context.a...
true
true
1c1f15fca89f5c7f2bceda81293ffd0173a235ec
994
py
Python
src/lisptypes.py
jakubwro/lisp-in-python
380469c7303b448113dc7e54ced4bcd60be3e7aa
[ "MIT" ]
3
2020-01-30T08:55:50.000Z
2021-04-15T15:03:57.000Z
src/lisptypes.py
jakubwro/lisp-in-python
380469c7303b448113dc7e54ced4bcd60be3e7aa
[ "MIT" ]
null
null
null
src/lisptypes.py
jakubwro/lisp-in-python
380469c7303b448113dc7e54ced4bcd60be3e7aa
[ "MIT" ]
null
null
null
class Symbol(str): pass class LispException(BaseException): pass class Environment(): def __init__(self, outer, binds=[], exprs=[]): self.outer = outer self.data = {} for k,v in zip(binds, exprs): self.data[k] = v def set(self, key, value): self.data[key] = value ...
27.611111
71
0.577465
class Symbol(str): pass class LispException(BaseException): pass class Environment(): def __init__(self, outer, binds=[], exprs=[]): self.outer = outer self.data = {} for k,v in zip(binds, exprs): self.data[k] = v def set(self, key, value): self.data[key] = value ...
true
true
1c1f175940a3567c9e623e744ef375d12def15ba
3,647
py
Python
scripts/clam-update/push_clam_signatures.py
fahlmant/openshift-tools
dbb4f16ccde3404c36c23108c45ca7b67138ee12
[ "Apache-2.0" ]
164
2015-07-29T17:35:04.000Z
2021-12-16T16:38:04.000Z
scripts/clam-update/push_clam_signatures.py
fahlmant/openshift-tools
dbb4f16ccde3404c36c23108c45ca7b67138ee12
[ "Apache-2.0" ]
3,634
2015-06-09T13:49:15.000Z
2022-03-23T20:55:44.000Z
scripts/clam-update/push_clam_signatures.py
fahlmant/openshift-tools
dbb4f16ccde3404c36c23108c45ca7b67138ee12
[ "Apache-2.0" ]
250
2015-06-08T19:53:11.000Z
2022-03-01T04:51:23.000Z
#!/bin/env python # vim: expandtab:tabstop=4:shiftwidth=4 """ This script is used to sync clam config files from a container to an S3 bucket. Both the files to be synced and the destination bucket are specified as variables in /secrets/aws_config.yml """ from __future__ import print_function import os import tim...
31.439655
95
0.622704
from __future__ import print_function import os import time import yaml import botocore import boto3 class UpdateBucket(object): @staticmethod def get_config(config_path): config_settings = {} if os.path.isfile(config_path): with open(config_path, 'r') as clam_config: ...
true
true