hexsha
stringlengths
40
40
size
int64
6
1.04M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
247
max_stars_repo_name
stringlengths
4
130
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
368k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
247
max_issues_repo_name
stringlengths
4
130
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
116k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
247
max_forks_repo_name
stringlengths
4
130
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
1
1.04M
avg_line_length
float64
1.53
618k
max_line_length
int64
1
1.02M
alphanum_fraction
float64
0
1
original_content
stringlengths
6
1.04M
filtered:remove_non_ascii
int64
0
538k
filtered:remove_decorators
int64
0
917k
filtered:remove_async
int64
0
722k
filtered:remove_classes
int64
-45
1M
filtered:remove_generators
int64
0
814k
filtered:remove_function_no_docstring
int64
-102
850k
filtered:remove_class_no_docstring
int64
-3
5.46k
filtered:remove_unused_imports
int64
-1,350
52.4k
filtered:remove_delete_markers
int64
0
59.6k
c932b089de02896cbcd7df96e727a2b3221201a0
3,213
py
Python
openff/system/utils.py
mattwthompson/openff-system
3cb43d3236304ebc0304c4e691d9101dc1773f22
[ "MIT" ]
null
null
null
openff/system/utils.py
mattwthompson/openff-system
3cb43d3236304ebc0304c4e691d9101dc1773f22
[ "MIT" ]
11
2021-05-12T05:45:02.000Z
2022-03-01T09:07:56.000Z
openff/system/utils.py
mattwthompson/openff-system
3cb43d3236304ebc0304c4e691d9101dc1773f22
[ "MIT" ]
null
null
null
import pathlib from collections import OrderedDict from typing import List from openff.toolkit.typing.engines.smirnoff import ForceField from openff.toolkit.utils import unit_to_string from pkg_resources import resource_filename from simtk import openmm from simtk import unit as omm_unit from openff.system import uni...
32.13
106
0.744164
import pathlib from collections import OrderedDict from typing import List from openff.toolkit.typing.engines.smirnoff import ForceField from openff.toolkit.utils import unit_to_string from pkg_resources import resource_filename from simtk import openmm from simtk import unit as omm_unit from openff.system import uni...
0
0
0
0
0
216
0
0
23
383255aadb0a4f30a2dc93b8d3cdf2942c4e0940
888
py
Python
routes/huc.py
ua-snap/data-api
a4d34858b70b90a1dc70bd65a0fc95e45a82fbdf
[ "MIT" ]
null
null
null
routes/huc.py
ua-snap/data-api
a4d34858b70b90a1dc70bd65a0fc95e45a82fbdf
[ "MIT" ]
109
2021-07-30T01:29:16.000Z
2022-03-30T17:49:00.000Z
routes/huc.py
ua-snap/data-api
a4d34858b70b90a1dc70bd65a0fc95e45a82fbdf
[ "MIT" ]
null
null
null
from flask import (Blueprint) # local imports huc_api = Blueprint("huc_api", __name__)
18.5
64
0.670045
import asyncio from flask import ( abort, Blueprint, Response, render_template, request, current_app as app, ) # local imports from . import routes from luts import huc8_gdf huc_api = Blueprint("huc_api", __name__) @routes.route("/huc/") @routes.route("/huc/abstract/") def huc_about(): ...
0
574
0
0
0
0
0
86
135
196be76e941f8559099b1eec1c19e1897f52498b
4,936
py
Python
python/snapy/netsnmp/unittests/test_netsnmp.py
marineam/nagcat
445d0efe1fb2ec93c31d1f9d8fa0c0563189ffaf
[ "Apache-2.0" ]
null
null
null
python/snapy/netsnmp/unittests/test_netsnmp.py
marineam/nagcat
445d0efe1fb2ec93c31d1f9d8fa0c0563189ffaf
[ "Apache-2.0" ]
null
null
null
python/snapy/netsnmp/unittests/test_netsnmp.py
marineam/nagcat
445d0efe1fb2ec93c31d1f9d8fa0c0563189ffaf
[ "Apache-2.0" ]
null
null
null
# snapy - a python snmp library # # Copyright (C) 2009 ITA Software, Inc. # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # version 2 as published by the Free Software Foundation. # # This program is distributed in the hope that it will be ...
29.915152
77
0.601904
# snapy - a python snmp library # # Copyright (C) 2009 ITA Software, Inc. # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # version 2 as published by the Free Software Foundation. # # This program is distributed in the hope that it will be ...
0
0
0
4,055
0
34
0
67
273
77065ca8eeb28083cb6ab38da2d7882ed69c641e
49
py
Python
tests/__init__.py
UltiRequiem/python-playground
cb17138df7ce5a21f107ded5a97019491d37c8b2
[ "MIT" ]
4
2021-08-15T03:20:04.000Z
2021-09-24T03:26:23.000Z
tests/__init__.py
UltiRequiem/python-playground
cb17138df7ce5a21f107ded5a97019491d37c8b2
[ "MIT" ]
null
null
null
tests/__init__.py
UltiRequiem/python-playground
cb17138df7ce5a21f107ded5a97019491d37c8b2
[ "MIT" ]
3
2021-08-15T03:20:05.000Z
2021-08-18T13:26:51.000Z
""" This tells Python that this is a module. """
12.25
40
0.653061
""" This tells Python that this is a module. """
0
0
0
0
0
0
0
0
0
285e5badd7bc28f47f98206c35e143077e5c010b
6,966
py
Python
python_redux/create_store.py
ebrakke/python-redux
744fbdafe2a546a000285256ffd492add9adeeeb
[ "MIT" ]
32
2016-07-08T17:17:31.000Z
2021-07-07T02:06:57.000Z
python_redux/create_store.py
ebrakke/python-redux
744fbdafe2a546a000285256ffd492add9adeeeb
[ "MIT" ]
2
2016-08-09T15:18:18.000Z
2016-10-26T12:17:52.000Z
python_redux/create_store.py
ebrakke/python-redux
744fbdafe2a546a000285256ffd492add9adeeeb
[ "MIT" ]
4
2017-04-14T12:07:12.000Z
2018-11-06T15:16:57.000Z
ACTION_TYPES = { 'INIT': '@@redux/INIT' } """ * Creates a Redux store that holds the state tree. * The only way to change the data in the store is to call `dispatch()` on it. * * There should only be a single store in your app. To specify how different * parts of the state tree respond to actions, you may combin...
38.7
107
0.737439
ACTION_TYPES = { 'INIT': '@@redux/INIT' } """ * Creates a Redux store that holds the state tree. * The only way to change the data in the store is to call `dispatch()` on it. * * There should only be a single store in your app. To specify how different * parts of the state tree respond to actions, you may combin...
0
0
0
0
0
5,686
0
0
22
e8e6bd70369d9b4d22fc312ee9111d08452ada88
4,377
py
Python
anicon.py
NevGi-cpu/anicon
a9092a9bdf5524dd3f4ed8da760637bc7764134f
[ "MIT" ]
null
null
null
anicon.py
NevGi-cpu/anicon
a9092a9bdf5524dd3f4ed8da760637bc7764134f
[ "MIT" ]
null
null
null
anicon.py
NevGi-cpu/anicon
a9092a9bdf5524dd3f4ed8da760637bc7764134f
[ "MIT" ]
null
null
null
from warnings import filterwarnings from PIL import Image, ImageOps from jikanpy import Jikan from requests import get from time import sleep import re import os print('''Run this in your anime folder For help, info and memes, check out https://github.com/notdedsec/anicon ''') sleep(1) jikan = Jikan() filterwarnings(...
33.159091
148
0.587846
from warnings import filterwarnings from PIL import Image, ImageOps from jikanpy import Jikan from requests import get from time import sleep import re import os print('''Run this in your anime folder For help, info and memes, check out https://github.com/notdedsec/anicon ''') sleep(1) jikan = Jikan() filterwarnings(...
0
0
0
0
0
1,848
0
0
69
2d7c8c3e7f12b4918d898b8410558a4f529cb1b7
495
py
Python
cafeteria/images/migrations/0005_auto_20190608_2217.py
devGW/PostApp
fda99fbc838ee809b1ff28445d66cbd48e2b5016
[ "MIT" ]
null
null
null
cafeteria/images/migrations/0005_auto_20190608_2217.py
devGW/PostApp
fda99fbc838ee809b1ff28445d66cbd48e2b5016
[ "MIT" ]
1
2019-08-31T01:07:46.000Z
2019-09-01T15:10:42.000Z
cafeteria/images/migrations/0005_auto_20190608_2217.py
devGW/PostApp
fda99fbc838ee809b1ff28445d66cbd48e2b5016
[ "MIT" ]
null
null
null
# Generated by Django 2.2.1 on 2019-06-08 13:17
20.625
47
0.547475
# Generated by Django 2.2.1 on 2019-06-08 13:17 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('images', '0004_auto_20190607_2340'), ] operations = [ migrations.RenameField( model_name='comment', old_name='Image', ...
0
0
0
389
0
0
0
11
46
93368abbf091c6ddf0ece731e948fa5ed0e5673d
2,741
py
Python
pylith/meshio/DataWriterHDF5Ext.py
cehanagan/pylith
cf5c1c34040460a82f79b6eb54df894ed1b1ee93
[ "MIT" ]
93
2015-01-08T16:41:22.000Z
2022-02-25T13:40:02.000Z
pylith/meshio/DataWriterHDF5Ext.py
sloppyjuicy/pylith
ac2c1587f87e45c948638b19560813d4d5b6a9e3
[ "MIT" ]
277
2015-02-20T16:27:35.000Z
2022-03-30T21:13:09.000Z
pylith/meshio/DataWriterHDF5Ext.py
sloppyjuicy/pylith
ac2c1587f87e45c948638b19560813d4d5b6a9e3
[ "MIT" ]
71
2015-03-24T12:11:08.000Z
2022-03-03T04:26:02.000Z
# ---------------------------------------------------------------------- # # Brad T. Aagaard, U.S. Geological Survey # Charles A. Williams, GNS Science # Matthew G. Knepley, University at Buffalo # # This code was developed as part of the Computational Infrastructure # for Geodynamics (http://geodynamics.org). # # Copy...
29.473118
102
0.59066
# ---------------------------------------------------------------------- # # Brad T. Aagaard, U.S. Geological Survey # Charles A. Williams, GNS Science # Matthew G. Knepley, University at Buffalo # # This code was developed as part of the Computational Infrastructure # for Geodynamics (http://geodynamics.org). # # Copy...
0
0
0
1,763
0
0
0
56
68
63cbb36cd3f5d7cfecfe9d1002837f0045e786ca
1,844
py
Python
src/neopixel_timer_chaser.py
tobiasbp/micropython
d1c3108f1ab81c70e048eb21b57f3b2f43571b90
[ "MIT" ]
null
null
null
src/neopixel_timer_chaser.py
tobiasbp/micropython
d1c3108f1ab81c70e048eb21b57f3b2f43571b90
[ "MIT" ]
null
null
null
src/neopixel_timer_chaser.py
tobiasbp/micropython
d1c3108f1ab81c70e048eb21b57f3b2f43571b90
[ "MIT" ]
null
null
null
# A timer based LED chaser using adressable LEDs of type WS2812/NeoPixel # Tested on a an ESP32 running MicroPython import machine, neopixel from machine import Timer # Pin to use for controlling LEDs LED_STRIP_PIN = 14 # Number of LEDs on LED strip LED_STRIP_LENGTH = 42 # How many times a second (HZ) to advance the L...
24.263158
84
0.699566
# A timer based LED chaser using adressable LEDs of type WS2812/NeoPixel # Tested on a an ESP32 running MicroPython import machine, neopixel from machine import Timer # Pin to use for controlling LEDs LED_STRIP_PIN = 14 # Number of LEDs on LED strip LED_STRIP_LENGTH = 42 # How many times a second (HZ) to advance the L...
0
0
0
0
0
0
0
0
0
26208baa0b4c094c9044ed8a1870a25f4fc0b1cf
36,599
py
Python
robot-resources/libraries/pybot_jrouter.py
Juniper/nita-robot
4c7e2514b10f22619532e4368a80b6ebd0545f85
[ "Apache-2.0" ]
8
2020-12-09T18:37:56.000Z
2022-01-17T00:50:40.000Z
robot-resources/libraries/pybot_jrouter.py
Juniper/nita-robot
4c7e2514b10f22619532e4368a80b6ebd0545f85
[ "Apache-2.0" ]
null
null
null
robot-resources/libraries/pybot_jrouter.py
Juniper/nita-robot
4c7e2514b10f22619532e4368a80b6ebd0545f85
[ "Apache-2.0" ]
2
2021-01-04T10:58:55.000Z
2021-06-09T17:43:22.000Z
#!/usr/bin/env python3 # ******************************************************** # # Project: ...
44.095181
442
0.564606
#!/usr/bin/env python3 # ******************************************************** # # Project: ...
0
0
0
33,555
0
0
0
175
1,038
5cd7c5f922a241072fc7a9059182d39d3ad7a58d
1,610
py
Python
SemanticCube.py
AndresGalaviz/Riper
70c78259f98ba8f25d4ad6a365a6b494b3ee22f2
[ "MIT" ]
1
2021-06-22T07:38:39.000Z
2021-06-22T07:38:39.000Z
SemanticCube.py
AndresGalaviz/Riper
70c78259f98ba8f25d4ad6a365a6b494b3ee22f2
[ "MIT" ]
2
2016-11-14T21:09:07.000Z
2018-02-08T21:01:07.000Z
SemanticCube.py
AndresGalaviz/Riper
70c78259f98ba8f25d4ad6a365a6b494b3ee22f2
[ "MIT" ]
null
null
null
from collections import defaultdict operMap = { '+' : 0, '-' : 1, '*' : 2, '/' : 3, '%' : 4, '=' : 5, '<' : 6, '>' : 7, '<=' : 8, ...
22.676056
67
0.471429
from collections import defaultdict operMap = { '+' : 0, '-' : 1, '*' : 2, '/' : 3, '%' : 4, '=' : 5, '<' : 6, '>' : 7, '<=' : 8, ...
0
0
0
0
0
104
0
0
23
4c0522a7d8ac663b9787c83c087c0a0943adba83
24,624
py
Python
pyspark/bigdl/util/common.py
qiuxin2012/BigDL
e3cd7499c0f850eb003163df8f090e7e92841ad0
[ "Apache-2.0" ]
null
null
null
pyspark/bigdl/util/common.py
qiuxin2012/BigDL
e3cd7499c0f850eb003163df8f090e7e92841ad0
[ "Apache-2.0" ]
1
2017-09-19T06:18:17.000Z
2017-09-19T06:18:17.000Z
pyspark/bigdl/util/common.py
qiuxin2012/BigDL
e3cd7499c0f850eb003163df8f090e7e92841ad0
[ "Apache-2.0" ]
1
2022-02-23T07:56:23.000Z
2022-02-23T07:56:23.000Z
# # Copyright 2016 The BigDL 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 or agreed to in ...
34.977273
136
0.625487
# # Copyright 2016 The BigDL 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 or agreed to in ...
0
8,056
0
5,478
0
4,167
0
92
660
f7cb9be055f18ca194ecae99d1870fe80ea55f5b
1,109
py
Python
tests/functional_tests/run_functional_tests.py
EuroPOND/deformetrica
29cb3a4ecd40d6a19b3ee2a1c5827c4ebab54062
[ "BSD-3-Clause" ]
1
2020-10-27T07:30:56.000Z
2020-10-27T07:30:56.000Z
tests/functional_tests/run_functional_tests.py
EuroPOND/deformetrica
29cb3a4ecd40d6a19b3ee2a1c5827c4ebab54062
[ "BSD-3-Clause" ]
null
null
null
tests/functional_tests/run_functional_tests.py
EuroPOND/deformetrica
29cb3a4ecd40d6a19b3ee2a1c5827c4ebab54062
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python # -*- encoding: utf-8 -*- from functional_tests.data.atlas.skulls.run import AtlasSkulls from functional_tests.data.atlas.brain_structures.run import AtlasBrainStructures from functional_tests.data.atlas.digits.run import AtlasDigits from functional_tests.data.regression.skulls.run import Regress...
28.435897
96
0.717764
#!/usr/bin/env python # -*- encoding: utf-8 -*- import os import unittest from functional_tests.data.atlas.skulls.run import AtlasSkulls from functional_tests.data.atlas.brain_structures.run import AtlasBrainStructures from functional_tests.data.atlas.digits.run import AtlasDigits from functional_tests.data.regressio...
0
0
0
0
0
580
0
-18
91
f58acb41a8e89d1fd42a86732c8baea2aaa858cd
1,538
py
Python
py/decorator_ex.py
armundle/scratch
a4c0ecdc2661e59ef8f378644324edb7a9680b37
[ "MIT" ]
null
null
null
py/decorator_ex.py
armundle/scratch
a4c0ecdc2661e59ef8f378644324edb7a9680b37
[ "MIT" ]
null
null
null
py/decorator_ex.py
armundle/scratch
a4c0ecdc2661e59ef8f378644324edb7a9680b37
[ "MIT" ]
null
null
null
if __name__ == "__main__": func1("test", "multiple", "args") print '\n' func1("another", "round", "of args") print '\n' func2() print '\n' func3() print '\n' print "end of example"
23.30303
80
0.640442
def decoratorFunction(f): def newFunc(): print "inside decorator function" print "entering", f.__name__ f() print "exited", f.__name__ return newFunc class decoratorWithoutArguments(object): ''' If there are no decorator arguments, the function to be decorated is pass...
0
203
0
830
0
170
0
0
114
ac5abfce774cc29f2045d6524242cc65405f6117
1,163
py
Python
aitextgen/cli.py
artificial-podcast/aitextgen
6e07361a2f15de7925a3cdefc91d32390b7489c9
[ "MIT" ]
1,416
2020-05-18T15:41:34.000Z
2022-03-31T09:39:55.000Z
aitextgen/cli.py
artificial-podcast/aitextgen
6e07361a2f15de7925a3cdefc91d32390b7489c9
[ "MIT" ]
165
2020-05-19T00:14:32.000Z
2022-03-30T16:56:36.000Z
aitextgen/cli.py
artificial-podcast/aitextgen
6e07361a2f15de7925a3cdefc91d32390b7489c9
[ "MIT" ]
156
2020-05-18T16:28:17.000Z
2022-03-24T14:50:31.000Z
from .aitextgen import aitextgen from .TokenDataset import TokenDataset from .tokenizers import train_tokenizer import fire def aitextgen_cli(**kwargs): """Entrypoint for the CLI""" fire.Fire( { "encode": encode_cli, "train": train_cli, "generate": generate_cli, ...
24.744681
72
0.648323
from .aitextgen import aitextgen from .TokenDataset import TokenDataset from .tokenizers import train_tokenizer import fire def aitextgen_cli(**kwargs): """Entrypoint for the CLI""" fire.Fire( { "encode": encode_cli, "train": train_cli, "generate": generate_cli, ...
0
0
0
0
0
0
0
0
0
4feb1591835f34dd864a6548fe3da65c2fa4cd1b
977
py
Python
tests/test_0088-read-with-http.py
eic/uproot4
deb8d88c2643521f372bf5005c51af8926016c7e
[ "BSD-3-Clause" ]
133
2020-05-08T21:34:11.000Z
2022-03-07T18:12:58.000Z
tests/test_0088-read-with-http.py
eic/uproot4
deb8d88c2643521f372bf5005c51af8926016c7e
[ "BSD-3-Clause" ]
269
2020-05-13T02:42:24.000Z
2022-03-24T20:24:16.000Z
tests/test_0088-read-with-http.py
eic/uproot4
deb8d88c2643521f372bf5005c51af8926016c7e
[ "BSD-3-Clause" ]
45
2020-05-15T17:48:04.000Z
2022-03-18T19:23:07.000Z
# BSD 3-Clause License; see https://github.com/scikit-hep/uproot4/blob/main/LICENSE from __future__ import absolute_import
27.138889
93
0.657114
# BSD 3-Clause License; see https://github.com/scikit-hep/uproot4/blob/main/LICENSE from __future__ import absolute_import import pytest import uproot @pytest.mark.network def test_issue176(): with uproot.open( "https://starterkit.web.cern.ch/starterkit/data/advanced-python-2019/dalitzdata.root" ) ...
0
751
0
0
0
0
0
-16
115
cd9ff6717c93c6515ce432df8655c8e7c488c943
476
py
Python
2019/day1/day1.py
st--/advent-of-code
b01ca4502820c972015e940024dbd482f7bc69c2
[ "MIT" ]
null
null
null
2019/day1/day1.py
st--/advent-of-code
b01ca4502820c972015e940024dbd482f7bc69c2
[ "MIT" ]
null
null
null
2019/day1/day1.py
st--/advent-of-code
b01ca4502820c972015e940024dbd482f7bc69c2
[ "MIT" ]
null
null
null
module_masses = load_inputs("input.txt") module_fuels = map(get_fuel_v2, module_masses) total = sum(module_fuels) print("Total: ", total)
22.666667
48
0.653361
import numpy as np def get_fuel_v1(mass): return int(np.floor(mass / 3) - 2) def get_fuel_v2(mass): fuel = int(np.floor(mass / 3) - 2) if fuel <= 0: return 0 else: return fuel + get_fuel_v2(fuel) def load_inputs(filename): with open(filename) as f: return [int(line.strip()...
0
0
0
0
0
249
0
-3
91
c24f80e8efcacbe920de67d48e1906505b7cea23
11,190
py
Python
src/prog_track.py
sungheeyun/WikiConverter
1f1d6f9f5e03a4f30770859c07f2af3adba64f32
[ "Unlicense" ]
null
null
null
src/prog_track.py
sungheeyun/WikiConverter
1f1d6f9f5e03a4f30770859c07f2af3adba64f32
[ "Unlicense" ]
null
null
null
src/prog_track.py
sungheeyun/WikiConverter
1f1d6f9f5e03a4f30770859c07f2af3adba64f32
[ "Unlicense" ]
null
null
null
#!/Users/sunyun/anaconda3/bin/python import sys sys.path.append("/Users/sunyun/software/python") if __name__ == "__main__": team = Team("MRE") team.add_member("Caroline", "McQuatt") team.add_member("Dmitry", "Serpakov") team.add_member("James", "Roland") team.add_member("Jan", "Duzinkiwicz")...
37.17608
106
0.603843
#!/Users/sunyun/anaconda3/bin/python import sys import time import utils sys.path.append("/Users/sunyun/software/python") class Member(object): DateFormat = "%m/%d/%y" # CONSTRUCTOR def __init__(self, firstName, lastName): assert isinstance(firstName, str), firstName.__class__ assert ...
0
129
0
5,487
0
0
0
-19
90
a824eb435244e6a72f7ebcfdeca66c141db54231
790
py
Python
src/emutils/geometry/utils.py
emanuele-albini/emutils
d5e3939da8a14b629879f06d87d4bd371e7117ab
[ "MIT" ]
null
null
null
src/emutils/geometry/utils.py
emanuele-albini/emutils
d5e3939da8a14b629879f06d87d4bd371e7117ab
[ "MIT" ]
null
null
null
src/emutils/geometry/utils.py
emanuele-albini/emutils
d5e3939da8a14b629879f06d87d4bd371e7117ab
[ "MIT" ]
null
null
null
import numpy as np from sklearn.base import BaseEstimator def scaled_linspace(x: np.ndarray, y: np.ndarray, num: int, scaler: BaseEstimator) -> np.ndarray: """Generate a linspace, evenly spaced according to the normalization Args: x (np.ndarray): First point y (np.ndarray): Sencon...
28.214286
97
0.629114
import numpy as np from sklearn.base import BaseEstimator def scaled_linspace(x: np.ndarray, y: np.ndarray, num: int, scaler: BaseEstimator) -> np.ndarray: """Generate a linspace, evenly spaced according to the normalization Args: x (np.ndarray): First point y (np.ndarray): Sencon...
0
0
0
0
0
0
0
0
0
3f5153f104031ac88200f645c7d7c5298dd2a17f
516
py
Python
train_eval_all.py
jake-g/urban-sound-classification
9d505732e7ba66d3a9e67ed97d956a7c67814503
[ "MIT" ]
null
null
null
train_eval_all.py
jake-g/urban-sound-classification
9d505732e7ba66d3a9e67ed97d956a7c67814503
[ "MIT" ]
null
null
null
train_eval_all.py
jake-g/urban-sound-classification
9d505732e7ba66d3a9e67ed97d956a7c67814503
[ "MIT" ]
1
2018-10-11T07:13:59.000Z
2018-10-11T07:13:59.000Z
from sklearn_classifiers import train_and_evaluate_all import utils as u print('\n\nEvaluating DNN Classifiers') # train_and_evaluate(cnn1, u.FEATURE_SET_SPECS) # train_and_evaluate(cnn2, u.FEATURE_SET_SPECS) # train_and_evaluate(ffn1, u.FEATURE_SET_MEANS) # train_and_evaluate(ffn2, u.FEATURE_SET_SPECS_NORM) print('...
36.857143
72
0.843023
from keras_classifiers import ffn1, ffn2, cnn1, cnn2, train_and_evaluate from sklearn_classifiers import train_and_evaluate_all import utils as u print('\n\nEvaluating DNN Classifiers') # train_and_evaluate(cnn1, u.FEATURE_SET_SPECS) # train_and_evaluate(cnn2, u.FEATURE_SET_SPECS) # train_and_evaluate(ffn1, u.FEATURE...
0
0
0
0
0
0
0
51
22
aec74b45141ca131949f6cb261503fcacbc2a87e
449
py
Python
userhandling/migrations/0002_auto_20180301_2333.py
staxx6/helloworldsite
f27916828276d1b963a908065b95b33d46971855
[ "MIT" ]
null
null
null
userhandling/migrations/0002_auto_20180301_2333.py
staxx6/helloworldsite
f27916828276d1b963a908065b95b33d46971855
[ "MIT" ]
null
null
null
userhandling/migrations/0002_auto_20180301_2333.py
staxx6/helloworldsite
f27916828276d1b963a908065b95b33d46971855
[ "MIT" ]
null
null
null
# Generated by Django 2.0.2 on 2018-03-01 22:33
22.45
86
0.632517
# Generated by Django 2.0.2 on 2018-03-01 22:33 from django.db import migrations, models import django.utils.timezone class Migration(migrations.Migration): dependencies = [ ('userhandling', '0001_initial'), ] operations = [ migrations.AlterField( model_name='profile', ...
0
0
0
306
0
0
0
26
68
f42f6c353bd59dc76888c331de8dd573115ec720
36,175
py
Python
tfx/extensions/google_cloud_ai_platform/runner_test.py
BACtaki/tfx
29db845200beccbb0ffa1e1e1a091e314a3a470f
[ "Apache-2.0" ]
1,813
2019-02-04T17:17:30.000Z
2022-03-29T13:39:30.000Z
tfx/extensions/google_cloud_ai_platform/runner_test.py
BACtaki/tfx
29db845200beccbb0ffa1e1e1a091e314a3a470f
[ "Apache-2.0" ]
2,710
2019-02-14T00:41:00.000Z
2022-03-31T07:23:00.000Z
tfx/extensions/google_cloud_ai_platform/runner_test.py
BACtaki/tfx
29db845200beccbb0ffa1e1e1a091e314a3a470f
[ "Apache-2.0" ]
731
2019-02-04T17:59:18.000Z
2022-03-31T06:45:51.000Z
# Copyright 2019 Google LLC. 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...
38.320975
89
0.666731
# Copyright 2019 Google LLC. 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...
0
10,922
0
23,602
0
0
0
455
465
dbb151e47ad33560056932ad894d00c51fab46ec
20,997
py
Python
tests/test_decision_maker/test_default.py
bryanchriswhite/agents-aea
d3f177a963eb855d9528555167255bf2b478f4ba
[ "Apache-2.0" ]
1
2022-01-23T22:28:43.000Z
2022-01-23T22:28:43.000Z
tests/test_decision_maker/test_default.py
salman6049/agents-aea
d3f177a963eb855d9528555167255bf2b478f4ba
[ "Apache-2.0" ]
null
null
null
tests/test_decision_maker/test_default.py
salman6049/agents-aea
d3f177a963eb855d9528555167255bf2b478f4ba
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # ------------------------------------------------------------------------------ # # Copyright 2018-2019 Fetch.AI Limited # # 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 ...
42.676829
100
0.655665
# -*- coding: utf-8 -*- # ------------------------------------------------------------------------------ # # Copyright 2018-2019 Fetch.AI Limited # # 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 ...
0
3,416
0
15,542
0
0
0
740
447
ef1d58f9d80944f576f527aa5ef04b18763b93eb
4,114
py
Python
testing/test.py
kyclark/configcode
ca060d5a6a00d64a277165302f90691067a9925e
[ "MIT" ]
null
null
null
testing/test.py
kyclark/configcode
ca060d5a6a00d64a277165302f90691067a9925e
[ "MIT" ]
null
null
null
testing/test.py
kyclark/configcode
ca060d5a6a00d64a277165302f90691067a9925e
[ "MIT" ]
null
null
null
import algorithm_rgb as al import os import osgeo.gdal as gdal import numpy as np import json input1 = './test_input/rgb_1_2_E.tif' input2 = './test_input/rgb_40_11_W.tif' meta = './meta.json' # -------------------------------------------------- def test_input_files(): """Test input files exist""" assert os...
27.610738
79
0.533301
import algorithm_rgb as al import os import osgeo.gdal as gdal import numpy as np import json input1 = './test_input/rgb_1_2_E.tif' input2 = './test_input/rgb_40_11_W.tif' meta = './meta.json' # -------------------------------------------------- def test_input_files(): """Test input files exist""" assert os...
0
0
0
0
0
0
0
0
0
63ca05b5723b47440172f0ab0ee76d26a865837b
5,161
py
Python
fasta2db.py
tzom/yHydra
094714069302d0f5ce1913346d8cde8e24c7a59c
[ "MIT" ]
null
null
null
fasta2db.py
tzom/yHydra
094714069302d0f5ce1913346d8cde8e24c7a59c
[ "MIT" ]
null
null
null
fasta2db.py
tzom/yHydra
094714069302d0f5ce1913346d8cde8e24c7a59c
[ "MIT" ]
1
2022-01-11T11:30:00.000Z
2022-01-11T11:30:00.000Z
from load_config import CONFIG MAX_DATABASE_SIZE=100000000 DB_PEPTIDE_MINIMUM_LENGTH=CONFIG['DB_PEPTIDE_MINIMUM_LENGTH']#7 DB_PEPTIDE_MAXIMUM_LENGTH=CONFIG['DB_PEPTIDE_MAXIMUM_LENGTH']#42 MAX_MISSED_CLEAVAGES=CONFIG['MAX_MISSED_CLEAVAGES']#args.MAX_MISSED_CLEAVAGES ENZYME=CONFIG['ENZYME'] SEMI_SPECIFIC_CLEAVAGE=CONFI...
34.871622
184
0.668863
import Bio,gzip from Bio import SeqIO import pyteomics from pyteomics import mass,fasta import pyteomics.parser as pyt_parser import pandas as pd import numpy as np import json,os from tqdm import tqdm from load_config import CONFIG MAX_DATABASE_SIZE=100000000 DB_PEPTIDE_MINIMUM_LENGTH=CONFIG['DB_PEPTIDE_MINIMUM_LENG...
0
0
0
0
0
4,267
0
18
316
966ac5c04b9427719a495ab99943f542cbdf6e3b
1,329
py
Python
w2e2_telnet.py
ibyt32/pynet_test
3b05d907fa0077d793b47dae36466a56d4ee3ef0
[ "Apache-2.0" ]
null
null
null
w2e2_telnet.py
ibyt32/pynet_test
3b05d907fa0077d793b47dae36466a56d4ee3ef0
[ "Apache-2.0" ]
null
null
null
w2e2_telnet.py
ibyt32/pynet_test
3b05d907fa0077d793b47dae36466a56d4ee3ef0
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python ''' Python and Ansible for Network Engineers Week 2, Exercise 2 Write a script that connects using telnet to the pynet-rtr1 router. Execute the 'show ip int brief' command on the router and return the output. ''' import telnetlib import time import sys TELNET_PORT = 23 TELNET_TIMEOUT = 6 ...
21.786885
77
0.68924
#!/usr/bin/env python ''' Python and Ansible for Network Engineers Week 2, Exercise 2 Write a script that connects using telnet to the pynet-rtr1 router. Execute the 'show ip int brief' command on the router and return the output. ''' import telnetlib import time import sys TELNET_PORT = 23 TELNET_TIMEOUT = 6 def...
0
0
0
0
0
343
0
0
77
82f12b6e70d344705bdf183ca639845ee55f0e9f
59,067
py
Python
src/main.py
simonenicf/Escape-from-Narlilia
cd512860e74d5df81504cccbcb667fdf794c8dda
[ "MIT" ]
null
null
null
src/main.py
simonenicf/Escape-from-Narlilia
cd512860e74d5df81504cccbcb667fdf794c8dda
[ "MIT" ]
1
2020-11-03T13:41:49.000Z
2020-11-03T14:05:22.000Z
src/main.py
simonenicf/Escape-from-Narlilia
cd512860e74d5df81504cccbcb667fdf794c8dda
[ "MIT" ]
null
null
null
from menu import Menu from game_engine import Console, Player console = Console() player = Player() start = True basement_suprise = ["demon", "open", "closed", "bear"] sus_building = ["enemy_trap", "human_traffic", "smuggler"] boat_stuff = ["tip over", "fight", "safe"] truck_survive = ["no", "yes"] # I know I don't ne...
37.502857
176
0.593089
import sys import time import random from menu import Menu from game_engine import Console, Player console = Console() player = Player() start = True basement_suprise = ["demon", "open", "closed", "bear"] sus_building = ["enemy_trap", "human_traffic", "smuggler"] boat_stuff = ["tip over", "fight", "safe"] truck_surviv...
2
0
0
0
0
55,894
0
-29
797
b5446fa1a409f1ddfa87ca3a6582e45a0ba26a81
958
py
Python
src/sms_gateway/send_message_service.py
RBEGamer/SMSGateway
d2fbba78a8103c338bf6ec0cdc49ee2e42f92b49
[ "MIT" ]
null
null
null
src/sms_gateway/send_message_service.py
RBEGamer/SMSGateway
d2fbba78a8103c338bf6ec0cdc49ee2e42f92b49
[ "MIT" ]
null
null
null
src/sms_gateway/send_message_service.py
RBEGamer/SMSGateway
d2fbba78a8103c338bf6ec0cdc49ee2e42f92b49
[ "MIT" ]
null
null
null
#!/usr/bin/python import MySQLdb import serial import time try: con = _mysql.connect('localhost', 'sms_gat', 'sms_gat', 'sms_gateway') con.query("SELECT VERSION()") result = con.use_result() print "MySQL version: %s" % \ result.fetch_row()[0] except _mysql.Error, e: ...
17.107143
74
0.632568
#!/usr/bin/python import MySQLdb import serial import time try: con = _mysql.connect('localhost', 'sms_gat', 'sms_gat', 'sms_gateway') con.query("SELECT VERSION()") result = con.use_result() print "MySQL version: %s" % \ result.fetch_row()[0] except _mysql.Error, e: ...
0
0
0
0
0
0
0
0
0
c35cc9241de308bf4411c4f47a3dcfe2d577eb0f
39,542
py
Python
domains/wartime/freedonia.py
richardyang/psychsim
191497d72077fe95cde94a2004a8be6e926c121f
[ "MIT" ]
23
2016-04-08T08:21:12.000Z
2022-03-15T02:49:12.000Z
domains/wartime/freedonia.py
richardyang/psychsim
191497d72077fe95cde94a2004a8be6e926c121f
[ "MIT" ]
3
2019-07-22T16:29:07.000Z
2020-11-06T07:00:16.000Z
domains/wartime/freedonia.py
richardyang/psychsim
191497d72077fe95cde94a2004a8be6e926c121f
[ "MIT" ]
12
2015-06-07T00:41:31.000Z
2020-01-10T15:04:43.000Z
""" Example scenario for wartime negotiation. Provides use cases for both modeling and simulating scenarios. """ import sys from ConfigParser import SafeConfigParser from argparse import ArgumentParser import StringIO from psychsim.world import World, stateKey, actionKey, binaryKey, modelKey from psychsim.agent import ...
49.120497
143
0.583987
""" Example scenario for wartime negotiation. Provides use cases for both modeling and simulating scenarios. """ import sys from ConfigParser import SafeConfigParser from argparse import ArgumentParser import StringIO from psychsim.pwl import * from psychsim.reward import * from psychsim.action import * from psychsim....
0
0
0
0
0
311
0
17
90
eb985f55700f2a265775dd46a40eb883b614da8d
9,835
py
Python
dysart/messages/messages.py
mcncm/Dysart
35af07816be7910d6d178d8aa53a291bfbc8d5f6
[ "MIT" ]
null
null
null
dysart/messages/messages.py
mcncm/Dysart
35af07816be7910d6d178d8aa53a291bfbc8d5f6
[ "MIT" ]
8
2018-11-29T18:53:20.000Z
2019-04-27T18:09:09.000Z
dysart/messages/messages.py
mcncm/Dysart
35af07816be7910d6d178d8aa53a291bfbc8d5f6
[ "MIT" ]
1
2019-07-01T17:06:10.000Z
2019-07-01T17:06:10.000Z
""" Author: mcncm, 2019 Standard output messages for displaying hierarchically-organized data such as recursively-called status lines. """ import os import getpass import logging import platform import textwrap import toplevel.conf as conf DEFAULT_COL = 48 TAB = ' ' * 4 def cstr_ansi(s: str, status: str = 'normal...
31.321656
80
0.597458
""" Author: mcncm, 2019 Standard output messages for displaying hierarchically-organized data such as recursively-called status lines. """ import os import sys import datetime as dt from functools import wraps import getpass import inspect from io import StringIO import logging import platform import textwrap import ...
12
1,291
0
2,508
0
50
0
15
228
866be4f8d7b5d8776a303296eb74a792deda64dc
2,208
py
Python
udiskie/depend.py
fbriere/udiskie
d7b95ae94cdce5d175e8a49fab1c94f7c8d75961
[ "MIT" ]
null
null
null
udiskie/depend.py
fbriere/udiskie
d7b95ae94cdce5d175e8a49fab1c94f7c8d75961
[ "MIT" ]
1
2020-11-16T10:31:57.000Z
2020-11-16T10:31:57.000Z
udiskie/depend.py
dxcSithLord/udiskie
286700e9eb50ffd5e1a8f2c93bdf66e99901f672
[ "MIT" ]
null
null
null
""" Make sure that the correct versions of gobject introspection dependencies are installed. """ import os import logging from gi import require_version from .locale import _ require_version('Gio', '2.0') require_version('GLib', '2.0') _in_X = bool(os.environ.get('DISPLAY')) _has_Gtk = (3 if check_version('Gtk...
25.976471
76
0.695652
""" Make sure that the correct versions of gobject introspection dependencies are installed. """ import os import logging from gi import require_version from .locale import _ require_version('Gio', '2.0') require_version('GLib', '2.0') def check_call(exc_type, func, *args): try: func(*args) re...
0
0
0
0
0
747
0
0
161
1bf710d88ae1cd28b88adf24c063c44a5aa069d0
280
py
Python
backend/config/settings/local.py
naaligai/naaligai
8e3e7bf7f049401701a690cda8cb5cafdc99030a
[ "MIT" ]
null
null
null
backend/config/settings/local.py
naaligai/naaligai
8e3e7bf7f049401701a690cda8cb5cafdc99030a
[ "MIT" ]
null
null
null
backend/config/settings/local.py
naaligai/naaligai
8e3e7bf7f049401701a690cda8cb5cafdc99030a
[ "MIT" ]
null
null
null
import dj_database_url from decouple import config SECRET_KEY = 'django-insecure-ibi@xb(j2k@r&%*(*&(^%$%^$%^^&)))5_niq9erpkv%*!&!m9hp' DEBUG = True ALLOWED_HOSTS = [] DATABASES = { 'default': dj_database_url.config(default=config('SQLITE_DB')) }
23.333333
83
0.685714
import dj_database_url from decouple import config from .base import * # noqa SECRET_KEY = 'django-insecure-ibi@xb(j2k@r&%*(*&(^%$%^$%^^&)))5_niq9erpkv%*!&!m9hp' DEBUG = True ALLOWED_HOSTS = [] DATABASES = { 'default': dj_database_url.config(default=config('SQLITE_DB')) }
0
0
0
0
0
0
0
-2
30
c264e283773c2df0a3f863fee30309a907451cc6
884
py
Python
AoC_2020_Python/day15.py
nlantau/Codewars_2020_2021
055fbf8785ddd52b9f8e8c2b59294ead01852467
[ "MIT" ]
null
null
null
AoC_2020_Python/day15.py
nlantau/Codewars_2020_2021
055fbf8785ddd52b9f8e8c2b59294ead01852467
[ "MIT" ]
null
null
null
AoC_2020_Python/day15.py
nlantau/Codewars_2020_2021
055fbf8785ddd52b9f8e8c2b59294ead01852467
[ "MIT" ]
null
null
null
# nlantau, 2020-12-15 # STARTING_NUMBERS = [2, 0, 6, 12, 1, 3] STARTING_NUMBERS = [0, 3, 6] if __name__ == "__main__": main()
22.666667
49
0.524887
# nlantau, 2020-12-15 import copy import os # STARTING_NUMBERS = [2, 0, 6, 12, 1, 3] STARTING_NUMBERS = [0, 3, 6] def memory_builder(): mem_list = copy.deepcopy(STARTING_NUMBERS) for i in range(len(mem_list) - 1, 8, 1): num = 0 prev_index = i + 1 index = 0 spoken = mem_list[i...
0
0
0
0
0
681
0
-22
90
efe7d8868b0e3081326fc3777f919fed2a1331e2
504
py
Python
Python/Warmup_2/last2.py
RCoon/CodingBat
c5004c03e668c62751dc7f13154c79e25ea34339
[ "MIT" ]
1
2015-11-06T02:26:50.000Z
2015-11-06T02:26:50.000Z
Python/Warmup_2/last2.py
RCoon/CodingBat
c5004c03e668c62751dc7f13154c79e25ea34339
[ "MIT" ]
null
null
null
Python/Warmup_2/last2.py
RCoon/CodingBat
c5004c03e668c62751dc7f13154c79e25ea34339
[ "MIT" ]
null
null
null
# Given a string, return the count of the number of times that a substring # length 2 appears in the string and also as the last 2 chars of the string, # so "hixxxhi" yields 1 (we won't count the end substring). # last2('hixxhi') --> 1 # last2('xaxxaxaxx') --> 1 # last2('axxxaaxx') --> 2 print(last2('hixxhi')) print...
25.2
76
0.642857
# Given a string, return the count of the number of times that a substring # length 2 appears in the string and also as the last 2 chars of the string, # so "hixxxhi" yields 1 (we won't count the end substring). # last2('hixxhi') --> 1 # last2('xaxxaxaxx') --> 1 # last2('axxxaaxx') --> 2 def last2(str): last = str...
0
0
0
0
0
115
0
0
23
4b639d10e09c20f70524740017f7d90f82be23d6
257
py
Python
bot.py
lcarotenuto/XPensesBot
49545da41a6f70b9fc686b406ced40ba47815b43
[ "MIT" ]
null
null
null
bot.py
lcarotenuto/XPensesBot
49545da41a6f70b9fc686b406ced40ba47815b43
[ "MIT" ]
null
null
null
bot.py
lcarotenuto/XPensesBot
49545da41a6f70b9fc686b406ced40ba47815b43
[ "MIT" ]
null
null
null
if __name__ == '__main__': main()
18.357143
71
0.712062
from config import * from gdocument import GDocument def main(): spreadsheet = GDocument(spreadsheet_id=CONSTANTS['SPREADSHEET_ID']) result = spreadsheet.write_expense("Nuovo Test", 15.5) print(result) if __name__ == '__main__': main()
0
0
0
0
0
140
0
9
67
f095b15e36d512ee4a9c390ed703961526864b88
132
py
Python
PyTrinamic/ic/TMC2225/TMC2225_register_variant.py
trinamic-AA/PyTrinamic
b054f4baae8eb6d3f5d2574cf69c232f66abb4ee
[ "MIT" ]
37
2019-01-13T11:08:45.000Z
2022-03-25T07:18:15.000Z
PyTrinamic/ic/TMC2225/TMC2225_register_variant.py
trinamic-AA/PyTrinamic
b054f4baae8eb6d3f5d2574cf69c232f66abb4ee
[ "MIT" ]
56
2019-02-25T02:48:27.000Z
2022-03-31T08:45:34.000Z
PyTrinamic/ic/TMC2225/TMC2225_register_variant.py
trinamic-AA/PyTrinamic
b054f4baae8eb6d3f5d2574cf69c232f66abb4ee
[ "MIT" ]
26
2019-01-14T05:20:16.000Z
2022-03-08T13:27:35.000Z
''' Created on 17.10.2019 @author: JM '''
13.2
45
0.583333
''' Created on 17.10.2019 @author: JM ''' class TMC2225_register_variant: " ===== TMC2225 register variants ===== " "..."
0
0
0
67
0
0
0
0
23
b366016944742e959dd7b14ac6a1c3948d1b0fd6
2,242
py
Python
pyqt/qt_main.py
dldldlfma/py_tutorial
efb3ddb4d2fcd26e7086198fe42144d896623ed7
[ "MIT" ]
null
null
null
pyqt/qt_main.py
dldldlfma/py_tutorial
efb3ddb4d2fcd26e7086198fe42144d896623ed7
[ "MIT" ]
null
null
null
pyqt/qt_main.py
dldldlfma/py_tutorial
efb3ddb4d2fcd26e7086198fe42144d896623ed7
[ "MIT" ]
1
2019-10-08T09:07:38.000Z
2019-10-08T09:07:38.000Z
import sys Calui ='./ui.ui' if __name__ =='__main__': app = QApplication(sys.argv) main_dialog=MainDialog() main_dialog.show() app.exec_() #event loop
27.012048
104
0.620874
import sys import PyQt5 from PyQt5.QtGui import * from PyQt5.QtCore import * from PyQt5.QtWidgets import * from PyQt5 import uic from pprint import pprint import cv2 as cv Calui ='./ui.ui' class MainDialog(QDialog): def __init__(self): QDialog.__init__(self, None) uic.loadUi(Calui,self) ...
6
0
0
1,882
0
0
0
7
181
82beae2102ce4d483ab3149453053290c8cd4268
463
py
Python
otx_epub/migrations/0005_auto_20161103_0228.py
NYULibraries/dlts-enm-tct-backend
07455a660fb2cb8bc91a54f7f12d150923678157
[ "Apache-2.0" ]
null
null
null
otx_epub/migrations/0005_auto_20161103_0228.py
NYULibraries/dlts-enm-tct-backend
07455a660fb2cb8bc91a54f7f12d150923678157
[ "Apache-2.0" ]
2
2017-10-30T21:19:07.000Z
2017-10-31T18:06:30.000Z
otx_epub/migrations/0005_auto_20161103_0228.py
NYULibraries/dlts-enm-tct-backend
07455a660fb2cb8bc91a54f7f12d150923678157
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.10 on 2016-11-03 06:28 from __future__ import unicode_literals
22.047619
63
0.62203
# -*- coding: utf-8 -*- # Generated by Django 1.10 on 2016-11-03 06:28 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('otx_epub', '0004_auto_20161102_1547'), ] operations = [ migrations.AlterField...
0
0
0
286
0
0
0
19
46
b991c836cd1efdb1cd46d20df8cd246babb4832d
5,090
py
Python
src/sv-pipeline/04_variant_resolution/scripts/merge_vcfs.py
talkowski-lab/gnomad-sv-v3-qc
db23760af7bc21a776e14f6ca1fbc213ff0ff9a1
[ "BSD-3-Clause" ]
null
null
null
src/sv-pipeline/04_variant_resolution/scripts/merge_vcfs.py
talkowski-lab/gnomad-sv-v3-qc
db23760af7bc21a776e14f6ca1fbc213ff0ff9a1
[ "BSD-3-Clause" ]
null
null
null
src/sv-pipeline/04_variant_resolution/scripts/merge_vcfs.py
talkowski-lab/gnomad-sv-v3-qc
db23760af7bc21a776e14f6ca1fbc213ff0ff9a1
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Copyright 2018 Matthew Stone <mstone5@mgh.harvard.edu> # Distributed under terms of the MIT license. """ """ def records_match(record, other): """ Test if two records are same SV: check chromosome, position, stop, SVTYPE, SVLEN (for insertions), STRANDS ...
38.270677
172
0.65501
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Copyright © 2018 Matthew Stone <mstone5@mgh.harvard.edu> # Distributed under terms of the MIT license. """ """ import argparse import heapq from collections import deque import pysam import svtk.utils as svu def records_match(record, other): """ Test if two ...
2
0
0
299
2,144
872
0
-13
203
ec0b5a658527f89982886e3eb9289615a64a45ea
3,783
py
Python
ngs_utils/jsontemplate/formatters.py
pdiakumis/NGS_Utils
9eae9f8d5f0e408118d429fde90e297dbac9ae15
[ "MIT" ]
3
2018-06-06T01:41:51.000Z
2020-08-20T11:36:06.000Z
ngs_utils/jsontemplate/formatters.py
pdiakumis/NGS_Utils
9eae9f8d5f0e408118d429fde90e297dbac9ae15
[ "MIT" ]
4
2019-11-28T03:34:54.000Z
2021-06-24T23:04:55.000Z
ngs_utils/jsontemplate/formatters.py
pdiakumis/NGS_Utils
9eae9f8d5f0e408118d429fde90e297dbac9ae15
[ "MIT" ]
5
2018-03-15T12:43:38.000Z
2021-06-24T23:12:48.000Z
#!/usr/bin/python -S """ formatters.py This module should implement the standard list of formatters. It also provides a method LookupChain for *composing lookup chains* for formatters. Formatter lookup chaining is not to be confused with plain formatter chaining, e.g.: {variable|html|json} If anyone has any bett...
25.389262
80
0.706846
#!/usr/bin/python -S """ formatters.py This module should implement the standard list of formatters. It also provides a method LookupChain for *composing lookup chains* for formatters. Formatter lookup chaining is not to be confused with plain formatter chaining, e.g.: {variable|html|json} If anyone has any bett...
0
0
0
1,335
0
422
0
-9
188
9420f75a4f51fd3a07373d2089ce37f6fd2bcf7f
1,519
py
Python
src/adobe/pdfservices/operation/internal/api/dto/request/extract_pdf_outputs.py
hvntravel/pdfservices-python-sdk
af2511604dc2558e43c6be44692fb9faa0e3e8d8
[ "Apache-2.0" ]
2
2021-11-19T10:00:53.000Z
2022-01-30T21:19:50.000Z
src/adobe/pdfservices/operation/internal/api/dto/request/extract_pdf_outputs.py
hvntravel/pdfservices-python-sdk
af2511604dc2558e43c6be44692fb9faa0e3e8d8
[ "Apache-2.0" ]
1
2021-06-26T15:17:21.000Z
2021-06-26T15:17:21.000Z
src/adobe/pdfservices/operation/internal/api/dto/request/extract_pdf_outputs.py
hvntravel/pdfservices-python-sdk
af2511604dc2558e43c6be44692fb9faa0e3e8d8
[ "Apache-2.0" ]
2
2022-01-02T16:01:02.000Z
2022-03-24T01:23:14.000Z
# Copyright 2021 Adobe. All rights reserved. # This file is licensed to you 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...
44.676471
98
0.761027
# Copyright 2021 Adobe. All rights reserved. # This file is licensed to you 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...
0
0
0
572
0
0
0
168
134
70e8006c645a188c493a251606a2b7455927ab7a
324
py
Python
scripts/gen_small.py
jaistark/sp
911933c65f950e6bc51451840068ca9249554846
[ "BSD-2-Clause" ]
28
2015-03-04T08:34:40.000Z
2022-02-13T05:59:11.000Z
scripts/gen_small.py
jaistark/sp
911933c65f950e6bc51451840068ca9249554846
[ "BSD-2-Clause" ]
null
null
null
scripts/gen_small.py
jaistark/sp
911933c65f950e6bc51451840068ca9249554846
[ "BSD-2-Clause" ]
14
2015-03-04T08:34:42.000Z
2020-12-08T16:13:37.000Z
import snap import numpy as np G = snap.PNGraph.New() for i in range(6): G.AddNode(i) G.AddEdge(0, 1) G.AddEdge(1, 2) G.AddEdge(2, 0) G.AddEdge(3, 4) G.AddEdge(4, 5) G.AddEdge(5, 3) G.AddEdge(4, 3) G.AddEdge(5, 4) G.AddEdge(3, 5) out_file = '../data/small.txt' print 'data:', out_file snap.SaveEdgeList(G, out_fi...
14.727273
30
0.657407
import snap import numpy as np G = snap.PNGraph.New() for i in range(6): G.AddNode(i) G.AddEdge(0, 1) G.AddEdge(1, 2) G.AddEdge(2, 0) G.AddEdge(3, 4) G.AddEdge(4, 5) G.AddEdge(5, 3) G.AddEdge(4, 3) G.AddEdge(5, 4) G.AddEdge(3, 5) out_file = '../data/small.txt' print 'data:', out_file snap.SaveEdgeList(G, out_fi...
0
0
0
0
0
0
0
0
0
2800eb1fa749d4331920a1ff2abd56ea0c5117a5
3,186
py
Python
web/web/config.py
wellcometrust/reach
1aa42c7d8aaf0a91d033af8448a33f37563b0365
[ "MIT" ]
11
2019-11-04T08:24:00.000Z
2021-12-16T23:11:47.000Z
web/web/config.py
wellcometrust/reach
1aa42c7d8aaf0a91d033af8448a33f37563b0365
[ "MIT" ]
274
2019-10-30T15:37:17.000Z
2021-03-25T16:13:36.000Z
web/web/config.py
wellcometrust/reference-parser
1aa42c7d8aaf0a91d033af8448a33f37563b0365
[ "MIT" ]
3
2019-11-12T13:38:14.000Z
2020-04-16T07:49:04.000Z
def _or(val_a, val_b, default=None): """ Used to allow specifying config values through os.environ Args: val_a: val_b: """ if val_a is not None: return val_a elif val_b is not None: return val_b else: return default
26.114754
93
0.514124
import os import toml def _or(val_a, val_b, default=None): """ Used to allow specifying config values through os.environ Args: val_a: val_b: """ if val_a is not None: return val_a elif val_b is not None: return val_b else: return default class Con...
0
0
0
2,787
0
42
0
-22
91
23af53260bd3539d33274ebeb87ea1d255057d8b
2,235
py
Python
tests/test_pages.py
morden35/spatula
cdbcc3231696890af236064a6082232af9d4d407
[ "MIT" ]
209
2017-02-22T16:38:23.000Z
2022-03-26T02:07:39.000Z
tests/test_pages.py
morden35/spatula
cdbcc3231696890af236064a6082232af9d4d407
[ "MIT" ]
23
2017-02-24T06:13:02.000Z
2022-02-10T21:25:35.000Z
tests/test_pages.py
morden35/spatula
cdbcc3231696890af236064a6082232af9d4d407
[ "MIT" ]
7
2017-02-24T02:54:23.000Z
2021-08-05T18:37:14.000Z
SOURCE = "https://example.com"
24.56044
76
0.620134
import json from dataclasses import dataclass from spatula import ( HtmlPage, XmlPage, JsonPage, CsvListPage, HtmlListPage, XmlListPage, JsonListPage, XPath, URL, ) SOURCE = "https://example.com" @dataclass class Response: content: bytes @property def text(self): ...
0
148
0
0
0
1,662
0
135
250
248892a38a80ac161701d0cdcd65f5d39a6a5009
18,274
py
Python
src/azure-cli/azure/cli/command_modules/servicebus/tests/latest/test_servicebus_queue_commands.py
zjpjack/azure-cli
818a0aa958203131d1fc9a43ecda75bbf5adf8f3
[ "MIT" ]
null
null
null
src/azure-cli/azure/cli/command_modules/servicebus/tests/latest/test_servicebus_queue_commands.py
zjpjack/azure-cli
818a0aa958203131d1fc9a43ecda75bbf5adf8f3
[ "MIT" ]
null
null
null
src/azure-cli/azure/cli/command_modules/servicebus/tests/latest/test_servicebus_queue_commands.py
zjpjack/azure-cli
818a0aa958203131d1fc9a43ecda75bbf5adf8f3
[ "MIT" ]
null
null
null
# -------------------------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # --------------------------------------------------------------------...
51.914773
181
0.656123
# -------------------------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # --------------------------------------------------------------------...
0
16,128
0
1,539
0
0
0
57
90
02ac88ad6695c765e9cecca611e77607225378d0
1,197
py
Python
scripts/contributor_counts.py
navgurukul-shivani18/kitsune
a7cf49ab1bfcf4e770938116968824b2b0fa5bb1
[ "BSD-3-Clause" ]
4
2021-05-17T11:38:08.000Z
2021-08-19T06:42:39.000Z
scripts/contributor_counts.py
navgurukul-shivani18/kitsune
a7cf49ab1bfcf4e770938116968824b2b0fa5bb1
[ "BSD-3-Clause" ]
32
2021-04-15T22:35:58.000Z
2022-01-04T21:30:05.000Z
scripts/contributor_counts.py
navgurukul-shivani18/kitsune
a7cf49ab1bfcf4e770938116968824b2b0fa5bb1
[ "BSD-3-Clause" ]
3
2020-06-14T06:59:46.000Z
2020-06-15T14:45:56.000Z
# Shows top posters and percentage of posts from top posters for the # last 14 days. You need recent data to run this. # # Run this with ./manage.py runscript run_contributor_counts.py from collections import defaultdict from datetime import datetime, timedelta from kitsune.forums.models import Post if __name__ =...
25.468085
78
0.692565
# Shows top posters and percentage of posts from top posters for the # last 14 days. You need recent data to run this. # # Run this with ./manage.py runscript run_contributor_counts.py from collections import defaultdict from datetime import datetime, timedelta from kitsune.forums.models import Post def run(): ...
0
0
0
0
0
776
0
0
23
8f71d0b7f1f5f348b6bc0d3d81216b11dc4a07f6
1,337
py
Python
fast_reconcile_app/lib/query_parser.py
birkin/fast_reconcile_project
de086e312aae9cd4d2eb847c3a5a5ba94cd68de7
[ "BSD-3-Clause" ]
null
null
null
fast_reconcile_app/lib/query_parser.py
birkin/fast_reconcile_project
de086e312aae9cd4d2eb847c3a5a5ba94cd68de7
[ "BSD-3-Clause" ]
null
null
null
fast_reconcile_app/lib/query_parser.py
birkin/fast_reconcile_project
de086e312aae9cd4d2eb847c3a5a5ba94cd68de7
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- import json, logging log = logging.getLogger(__name__) def parse_query( request ): """ Preps and returns three data-elements. Called by views.reconcile_v2() """ ( query, query_type, callback ) = ( request.POST.get('query', None), request.POST.get('query_type', None), request...
35.184211
147
0.585639
# -*- coding: utf-8 -*- import json, logging log = logging.getLogger(__name__) def parse_query( request ): """ Preps and returns three data-elements. Called by views.reconcile_v2() """ ( query, query_type, callback ) = ( request.POST.get('query', None), request.POST.get('query_type', None), request...
0
0
0
0
0
0
0
0
0
d3c1f453a11937d08cbe712f78cc03cc5dfc1fc8
646
py
Python
setup.py
Imperial-CMTH/koala
cd05b11be402295468be709db13a957530f66578
[ "MIT" ]
null
null
null
setup.py
Imperial-CMTH/koala
cd05b11be402295468be709db13a957530f66578
[ "MIT" ]
9
2021-12-13T10:16:03.000Z
2022-03-28T10:39:16.000Z
setup.py
Imperial-CMTH/koala
cd05b11be402295468be709db13a957530f66578
[ "MIT" ]
null
null
null
from setuptools import setup, find_packages setup( name="koala", version='0.0', description='Topological Amorphous quantum system simulations', long_description='', author="Peru D'Ornellas, Gino Cassella, Tom Hodson", author_email='', license='Apache Software License', home_page='', ...
23.925926
67
0.586687
from setuptools import setup, find_packages setup( name="koala", version='0.0', description='Topological Amorphous quantum system simulations', long_description='', author="Peru D'Ornellas, Gino Cassella, Tom Hodson", author_email='', license='Apache Software License', home_page='', ...
0
0
0
0
0
0
0
0
0
6eab78bbc612df07c843ed5785bdecb5c317b639
1,119
py
Python
test/testPhiGradx.py
EmoryMLIP/OT-Flow
c1851a4da3aa131df1df6132b83d5186c154087e
[ "MIT" ]
31
2020-06-18T10:51:03.000Z
2022-03-10T19:58:36.000Z
test/testPhiGradx.py
EmoryMLIP/OT-Flow
c1851a4da3aa131df1df6132b83d5186c154087e
[ "MIT" ]
null
null
null
test/testPhiGradx.py
EmoryMLIP/OT-Flow
c1851a4da3aa131df1df6132b83d5186c154087e
[ "MIT" ]
8
2020-09-09T23:52:50.000Z
2022-03-11T21:19:20.000Z
# testPhiGradx.py # test the grad wrt x returned by trHess when nTh > 2 import matplotlib matplotlib.use('TkAgg') import matplotlib.pyplot as plt import torch.nn.utils doPlots = True d = 2 m = 5 nTh = 4 net = Phi(nTh=nTh, m=m, d=d) net.double() # vecParams = nn.utils.convert_parameters.parameters_to_vector(net.par...
18.65
86
0.580876
# testPhiGradx.py # test the grad wrt x returned by trHess when nTh > 2 import matplotlib matplotlib.use('TkAgg') import matplotlib.pyplot as plt from src.Phi import * import torch.nn.utils doPlots = True d = 2 m = 5 nTh = 4 net = Phi(nTh=nTh, m=m, d=d) net.double() # vecParams = nn.utils.convert_parameters.parame...
0
0
0
0
0
0
0
0
22
a660a6550f4dfbea6c622a3907992cd131a52dfb
608
py
Python
CubeNet/__init__.py
Billy-Chen0327/CubeNet
7df1758b12f0e561d57f1367d9279ea1b0bcc358
[ "MIT" ]
null
null
null
CubeNet/__init__.py
Billy-Chen0327/CubeNet
7df1758b12f0e561d57f1367d9279ea1b0bcc358
[ "MIT" ]
null
null
null
CubeNet/__init__.py
Billy-Chen0327/CubeNet
7df1758b12f0e561d57f1367d9279ea1b0bcc358
[ "MIT" ]
null
null
null
import os import torch import CubeNet.net import CubeNet.Picker import CubeNet.config network = CubeNet.net.UNet(); network.load_state_dict(torch.load(os.path.join(os.path.split(CubeNet.__file__)[0],'Para.pt'))); picker = CubeNet.Picker.IrrPicker(arr_info=CubeNet.config.arr_info, para...
46.769231
126
0.605263
import os import torch import CubeNet.net import CubeNet.Picker import CubeNet.config network = CubeNet.net.UNet(); network.load_state_dict(torch.load(os.path.join(os.path.split(CubeNet.__file__)[0],'Para.pt'))); picker = CubeNet.Picker.IrrPicker(arr_info=CubeNet.config.arr_info, para...
0
0
0
0
0
0
0
0
0
5e6b2448983c0f9de7f4ca47156c2801fef30890
12,703
py
Python
async_pokepy/types/move.py
PendragonLore/async_pokepy
9982505fbc360eae349086bfa8f6faad0133f5fa
[ "MIT" ]
5
2019-05-30T21:45:24.000Z
2021-11-07T20:35:40.000Z
async_pokepy/types/move.py
PendragonLore/async_pokepy
9982505fbc360eae349086bfa8f6faad0133f5fa
[ "MIT" ]
null
null
null
async_pokepy/types/move.py
PendragonLore/async_pokepy
9982505fbc360eae349086bfa8f6faad0133f5fa
[ "MIT" ]
1
2019-05-10T19:21:51.000Z
2019-05-10T19:21:51.000Z
# -*- coding: utf-8 -*- """ The MIT License (MIT) Copyright (c) 2019 Lorenzo Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, ...
38.847095
120
0.666929
# -*- coding: utf-8 -*- """ The MIT License (MIT) Copyright (c) 2019 Lorenzo Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, ...
6
0
0
11,101
0
0
0
92
228
39a1a8cc5e43dabfe72f249a0919d5b4a9544d01
305
py
Python
Chapter 09/Chap9_2.py
bpbpublications/Building-Machine-Learning-Systems-Using-Python
42df3c10b92fceba49d89afe7610ee075a79f0c3
[ "MIT" ]
null
null
null
Chapter 09/Chap9_2.py
bpbpublications/Building-Machine-Learning-Systems-Using-Python
42df3c10b92fceba49d89afe7610ee075a79f0c3
[ "MIT" ]
null
null
null
Chapter 09/Chap9_2.py
bpbpublications/Building-Machine-Learning-Systems-Using-Python
42df3c10b92fceba49d89afe7610ee075a79f0c3
[ "MIT" ]
1
2021-11-30T03:55:51.000Z
2021-11-30T03:55:51.000Z
#!/usr/bin/env python # coding: utf-8 # In[8]: import numpy as np import matplotlib.pyplot as plt import seaborn as sns; sns.set() ranstat = np.random.RandomState(1) P = np.dot(ranstat.rand(2, 2), ranstat.randn(2, 600)).T plt.scatter(P[:, 0], P[:, 1]) plt.axis('equal'); # In[ ]: # In[ ]:
11.296296
55
0.613115
#!/usr/bin/env python # coding: utf-8 # In[8]: import numpy as np import matplotlib.pyplot as plt import seaborn as sns; sns.set() ranstat = np.random.RandomState(1) P = np.dot(ranstat.rand(2, 2), ranstat.randn(2, 600)).T plt.scatter(P[:, 0], P[:, 1]) plt.axis('equal'); # In[ ]: # In[ ]:
0
0
0
0
0
0
0
0
0
58e7fe168632890239c09de539821e02be580e50
4,024
py
Python
firepy/vm.py
gamgi/firepy
fea859de4a8eaff78d4cf1ee7c3fe1b0467a77c6
[ "MIT" ]
null
null
null
firepy/vm.py
gamgi/firepy
fea859de4a8eaff78d4cf1ee7c3fe1b0467a77c6
[ "MIT" ]
null
null
null
firepy/vm.py
gamgi/firepy
fea859de4a8eaff78d4cf1ee7c3fe1b0467a77c6
[ "MIT" ]
null
null
null
def handle_errors(func): """Decorator that humanizes exceptions. It - parses firecracker HTTP responses - checks instance stderr for error messages """ return wrapper
30.717557
106
0.605616
from typing import Optional from functools import wraps from io import StringIO from sh import RunningCommand from requests.exceptions import ConnectionError, HTTPError from firepy.connection import Connection from firepy.exceptions import err_from_stderr, FirecrackerApiError from firepy.utils.network_utils import netw...
0
2,383
0
945
0
0
0
232
269
7f76cdc498d8ee42a21ab0dd328e6c52f1a68666
3,115
py
Python
guacamol/assess_goal_directed_generation.py
jcheminform/guacamol
dd7f7b12e1ab59151394aba5f4a95ee204fd0203
[ "MIT" ]
242
2018-11-29T13:34:13.000Z
2022-03-26T19:35:17.000Z
guacamol/assess_goal_directed_generation.py
jcheminform/guacamol
dd7f7b12e1ab59151394aba5f4a95ee204fd0203
[ "MIT" ]
13
2019-01-31T03:33:36.000Z
2022-01-03T07:03:19.000Z
guacamol/assess_goal_directed_generation.py
jcheminform/guacamol
dd7f7b12e1ab59151394aba5f4a95ee204fd0203
[ "MIT" ]
68
2018-11-26T10:03:41.000Z
2022-03-28T20:58:20.000Z
import datetime import json import logging from collections import OrderedDict from typing import List, Any, Dict import guacamol from guacamol.goal_directed_benchmark import GoalDirectedBenchmark, GoalDirectedBenchmarkResult from guacamol.goal_directed_generator import GoalDirectedGenerator from guacamol.benchmark_su...
42.094595
103
0.727127
import datetime import json import logging from collections import OrderedDict from typing import List, Any, Dict import guacamol from guacamol.goal_directed_benchmark import GoalDirectedBenchmark, GoalDirectedBenchmarkResult from guacamol.goal_directed_generator import GoalDirectedGenerator from guacamol.benchmark_su...
0
0
0
0
0
0
0
0
0
facca4b14c67e4e1d8ac316092e1291cd1b25954
41,540
py
Python
icebox/icebox_asc2hlc.py
sandeepmistry/icestorm
8f61acd0556c8afee83ec2e77dedb03e700333d9
[ "0BSD" ]
6
2017-11-11T18:05:30.000Z
2020-02-24T11:21:03.000Z
icebox/icebox_asc2hlc.py
sandeepmistry/icestorm
8f61acd0556c8afee83ec2e77dedb03e700333d9
[ "0BSD" ]
null
null
null
icebox/icebox_asc2hlc.py
sandeepmistry/icestorm
8f61acd0556c8afee83ec2e77dedb03e700333d9
[ "0BSD" ]
null
null
null
#!/usr/bin/env python3 # Copyright (C) 2017 Roland Lutz # # Permission to use, copy, modify, and/or distribute this software for any # purpose with or without fee is hereby granted, provided that the above # copyright notice and this permission notice appear in all copies. # # THE SOFTWARE IS PROVIDED "AS IS" AND THE ...
36.599119
80
0.489769
#!/usr/bin/env python3 # Copyright (C) 2017 Roland Lutz # # Permission to use, copy, modify, and/or distribute this software for any # purpose with or without fee is hereby granted, provided that the above # copyright notice and this permission notice appear in all copies. # # THE SOFTWARE IS PROVIDED "AS IS" AND THE ...
0
0
0
16,526
0
20,488
0
-3
459
05d92b04d413dacbb9211204082fc281df9cc64b
753
py
Python
tests/streamer/test_encoder.py
Hikki12/remio
17942bffe3c0619d3435b1a12399b116d4c800e3
[ "Apache-2.0" ]
null
null
null
tests/streamer/test_encoder.py
Hikki12/remio
17942bffe3c0619d3435b1a12399b116d4c800e3
[ "Apache-2.0" ]
null
null
null
tests/streamer/test_encoder.py
Hikki12/remio
17942bffe3c0619d3435b1a12399b116d4c800e3
[ "Apache-2.0" ]
null
null
null
import time import numpy as np from remio import MJPEGEncoder encoderParams = { "quality": 60, "colorspace": "bgr", "colorsubsampling": "422", "fastdct": True, } def test_encoder(): """Test socket encoder class.""" max_encoding_time = 0.02 # seconds encoder = MJPEGEncoder(**encoderPara...
24.290323
77
0.641434
import time import numpy as np from remio import MJPEGEncoder encoderParams = { "quality": 60, "colorspace": "bgr", "colorsubsampling": "422", "fastdct": True, } def read_frame(): return np.random.randint(255, size=(1024, 720, 3), dtype=np.uint8) def test_encoder(): """Test socket encoder ...
0
0
0
0
0
67
0
0
23
ae128645d44c35a30a1735da1aacecba7280f741
5,833
py
Python
minesweeper.py
snow-apple/AoPS-games
ff6f922e77e64c8a3f83e2191c8435b2d28660b3
[ "Apache-2.0" ]
null
null
null
minesweeper.py
snow-apple/AoPS-games
ff6f922e77e64c8a3f83e2191c8435b2d28660b3
[ "Apache-2.0" ]
null
null
null
minesweeper.py
snow-apple/AoPS-games
ff6f922e77e64c8a3f83e2191c8435b2d28660b3
[ "Apache-2.0" ]
1
2020-09-16T19:37:37.000Z
2020-09-16T19:37:37.000Z
# Python Class 2344 # Lesson 10 Problem 1 # Author: snowapple (471208) import tkinter.messagebox as messagebox play_minesweeper(12, 10, 15)
32.405556
101
0.547917
# Python Class 2344 # Lesson 10 Problem 1 # Author: snowapple (471208) import random from tkinter import * import tkinter.messagebox as messagebox class MinesweeperCell(Label): def __init__(self, master, coord): Label.__init__( self, master, height=1, width=2, text="", bg="white", font=("Aria...
0
0
0
5,438
0
143
0
-8
114
4e515cc5b2a6e9d930b1ae6c2b6836567c9b41c6
1,231
py
Python
casepro/msg_board/migrations/0004_alter_messageboardcomment_content_type_and_more.py
rapidpro/ureport-partners
16e5b95eae36ecbbe8ab2a59f34a2f5fd32ceacd
[ "BSD-3-Clause" ]
null
null
null
casepro/msg_board/migrations/0004_alter_messageboardcomment_content_type_and_more.py
rapidpro/ureport-partners
16e5b95eae36ecbbe8ab2a59f34a2f5fd32ceacd
[ "BSD-3-Clause" ]
null
null
null
casepro/msg_board/migrations/0004_alter_messageboardcomment_content_type_and_more.py
rapidpro/ureport-partners
16e5b95eae36ecbbe8ab2a59f34a2f5fd32ceacd
[ "BSD-3-Clause" ]
null
null
null
# Generated by Django 4.0.1 on 2022-01-12 15:28
30.775
66
0.583266
# Generated by Django 4.0.1 on 2022-01-12 15:28 import django.db.models.deletion from django.conf import settings from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ("contenttypes", "0002_remove_content_type_name"), migrations.swappable_dependency(se...
0
0
0
1,051
0
0
0
41
90
49b502f6bf9afc0b6f3a4c3df18f489fc992d0f8
4,153
py
Python
Video_to_Image.py
Neutrino3316/First-Impression
00b7cebe8391c7c30b36de9c4ce5d9732daaf34d
[ "MIT" ]
24
2018-12-07T13:53:37.000Z
2022-01-11T11:54:34.000Z
Video_to_Image.py
Neutrino3316/First-Impression
00b7cebe8391c7c30b36de9c4ce5d9732daaf34d
[ "MIT" ]
6
2018-02-27T09:28:57.000Z
2020-09-08T15:37:56.000Z
Video_to_Image.py
Neutrino3316/First-Impression
00b7cebe8391c7c30b36de9c4ce5d9732daaf34d
[ "MIT" ]
21
2018-05-25T10:56:44.000Z
2022-02-24T08:06:24.000Z
''' Extract all the 6 training zipped files and 2 validation zipped files into data folder and then run this script ''' import cv2 import os import zipfile ## Runnin a loop throught all the zipped training file to extract all video and then extract 100 frames from each. for i in range(1,76): if i<10: zipfi...
38.453704
114
0.603419
''' Extract all the 6 training zipped files and 2 validation zipped files into data folder and then run this script ''' import cv2 import numpy as np import os import zipfile ## Runnin a loop throught all the zipped training file to extract all video and then extract 100 frames from each. for i in range(1,76): if ...
0
0
0
0
0
0
0
-3
22
d9209983fe3230c55c6541ed80c5107adddb2a90
393
py
Python
aos_vs_soa/plot.py
christopher-besch/cpp_go_fast
1f9090a70e4e15882334aa92ba021c5103ae7a33
[ "MIT" ]
3
2021-08-03T12:33:04.000Z
2021-10-29T18:58:13.000Z
aos_vs_soa/plot.py
christopher-besch/cpp_go_fast
1f9090a70e4e15882334aa92ba021c5103ae7a33
[ "MIT" ]
null
null
null
aos_vs_soa/plot.py
christopher-besch/cpp_go_fast
1f9090a70e4e15882334aa92ba021c5103ae7a33
[ "MIT" ]
null
null
null
import pandas as pd import matplotlib.pyplot as plt aos_data = pd.read_csv("aos.csv") soa_data = pd.read_csv("soa.csv") plt.loglog(aos_data["n"],aos_data["time"],"o",markersize=1,label="aos") plt.loglog(soa_data["n"],soa_data["time"],"o",markersize=1,label="soa") plt.title("aos vs soa") plt.legend() plt.xlabel("n") plt...
28.071429
71
0.715013
import pandas as pd import matplotlib.pyplot as plt import glob, os aos_data = pd.read_csv("aos.csv") soa_data = pd.read_csv("soa.csv") plt.loglog(aos_data["n"],aos_data["time"],"o",markersize=1,label="aos") plt.loglog(soa_data["n"],soa_data["time"],"o",markersize=1,label="soa") plt.title("aos vs soa") plt.legend() plt...
0
0
0
0
0
0
0
-6
22
50c3be7c7f58a98919788b196f8130825769342b
3,472
py
Python
setup.py
isislovecruft/txtorcon
9523319cecbc1d0aa8fdb4d6874f0debc22d0432
[ "MIT" ]
null
null
null
setup.py
isislovecruft/txtorcon
9523319cecbc1d0aa8fdb4d6874f0debc22d0432
[ "MIT" ]
null
null
null
setup.py
isislovecruft/txtorcon
9523319cecbc1d0aa8fdb4d6874f0debc22d0432
[ "MIT" ]
null
null
null
try: import pypissh except: print "WARNING: not using PyPi over SSH!" import sys import os import shutil import re from setuptools import setup ## can't just naively import these from txtorcon, as that will only ## work if you already installed the dependencies :( __version__ = '0.13.0' __author__ = 'meejah' _...
42.864198
277
0.575461
try: import pypissh except: print "WARNING: not using PyPi over SSH!" import sys import os import shutil import re from setuptools import setup ## can't just naively import these from txtorcon, as that will only ## work if you already installed the dependencies :( __version__ = '0.13.0' __author__ = 'meejah' _...
0
0
0
0
0
0
0
0
0
df6b1c0fb9ac1a4e25419b4ad34f691009e681fb
420
py
Python
packages/pyright-internal/src/tests/samples/unusedVariable1.py
martindemello/pyright
4fe3f1f7c08f139715701fdf746183062b5165ff
[ "MIT" ]
4,391
2019-05-07T01:18:57.000Z
2022-03-31T20:45:44.000Z
packages/pyright-internal/src/tests/samples/unusedVariable1.py
martindemello/pyright
4fe3f1f7c08f139715701fdf746183062b5165ff
[ "MIT" ]
2,740
2019-05-07T03:29:30.000Z
2022-03-31T12:57:46.000Z
packages/pyright-internal/src/tests/samples/unusedVariable1.py
martindemello/pyright
4fe3f1f7c08f139715701fdf746183062b5165ff
[ "MIT" ]
455
2019-05-07T12:55:14.000Z
2022-03-31T17:09:15.000Z
# This sample tests the reportUnusedVariable diagnostic check.
19.090909
75
0.619048
# This sample tests the reportUnusedVariable diagnostic check. def func1(a: int): x = 4 # This should generate an error if reportUnusedVariable is enabled. y = x _z = 4 _ = 2 __z__ = 5 if x + 1: # This should generate an error if reportUnusedVariable is enabled. z = 3 ...
0
0
0
0
0
333
0
0
23
b3d857944d0e5a13fa7cbc6cbf18f73987689aa2
6,200
py
Python
utils.py
Julienbeaulieu/Deeplearing-Image-Classifier-with-Pytorch
0c7274ce3d864800f083ba884039771b96d020e0
[ "MIT" ]
null
null
null
utils.py
Julienbeaulieu/Deeplearing-Image-Classifier-with-Pytorch
0c7274ce3d864800f083ba884039771b96d020e0
[ "MIT" ]
null
null
null
utils.py
Julienbeaulieu/Deeplearing-Image-Classifier-with-Pytorch
0c7274ce3d864800f083ba884039771b96d020e0
[ "MIT" ]
null
null
null
# Imports import matplotlib.pyplot as plt import torch from PIL import Image import numpy as np import json import pandas as pd # Import for keeping our session alive # Label Mapping with open('cat_to_name.json', 'r') as f: cat_to_name = json.load(f) # Quick check of data in json file df = pd.DataFrame({'flower...
28.054299
89
0.61871
# Imports import matplotlib.pyplot as plt import seaborn as sns import torch from torch import nn from torch import optim import torch.nn.functional as F from torchvision import datasets, transforms, models from PIL import Image import numpy as np import json import pandas as pd # Import for keeping our session aliv...
0
0
0
867
0
1,855
0
64
221
5e418feda0e0beca1b1898921200f56ed7648535
483
py
Python
user/urls.py
fobiero/InstagramClone_DJ_02
e99c65699997e20f98442159b01bc9d382f90b82
[ "MIT" ]
null
null
null
user/urls.py
fobiero/InstagramClone_DJ_02
e99c65699997e20f98442159b01bc9d382f90b82
[ "MIT" ]
null
null
null
user/urls.py
fobiero/InstagramClone_DJ_02
e99c65699997e20f98442159b01bc9d382f90b82
[ "MIT" ]
null
null
null
from django.urls import path from user.views import ProfileView, ProfileEditView, AllProfilesView from django.contrib.auth.decorators import login_required urlpatterns = [ # dynamic URL path('in/<str:username>/',login_required(ProfileView.as_view()),name='profile_view'), path('in/<str:username>/edit/',logi...
37.153846
103
0.761905
from django.urls import path from user.views import ProfileView,ProfileEditView,AllProfilesView from django.contrib.auth.decorators import login_required urlpatterns = [ # dynamic URL path('in/<str:username>/',login_required(ProfileView.as_view()),name='profile_view'), path('in/<str:username>/edit/',login_...
0
0
0
0
0
0
0
-2
0
f326b9679284bce6470da5c2ec0ec289c29e0ed3
5,798
py
Python
piso/docstrings/interval.py
venaturum/piso
54fd20443efb84d7a9982c92caf492b12206eaef
[ "MIT" ]
5
2021-10-10T04:17:17.000Z
2022-03-01T06:23:25.000Z
piso/docstrings/interval.py
venaturum/piso
54fd20443efb84d7a9982c92caf492b12206eaef
[ "MIT" ]
35
2021-10-09T13:22:04.000Z
2022-01-29T08:38:15.000Z
piso/docstrings/interval.py
staircase-dev/piso
2e6ac861f7166195e2fe67e2665c29e36b4ff12e
[ "MIT" ]
null
null
null
union_examples = """ Examples ----------- >>> import pandas as pd >>> import piso.interval >>> piso.interval.union( ... pd.Interval(0, 3), ... pd.Interval(2, 4), ... ) Interval(0.0, 4.0, closed='right') >>> piso.interval.union( ... pd.Interval(0, 3), ... pd.Interval(2, 4), ... squeeze=False, ... ) <In...
20.560284
89
0.624181
union_examples = """ Examples ----------- >>> import pandas as pd >>> import piso.interval >>> piso.interval.union( ... pd.Interval(0, 3), ... pd.Interval(2, 4), ... ) Interval(0.0, 4.0, closed='right') >>> piso.interval.union( ... pd.Interval(0, 3), ... pd.Interval(2, 4), ... squeeze=False, ... ) <In...
0
0
0
0
0
0
0
0
0
0e77dececbe73353a54fdfea2a502e9ede998856
285
py
Python
content/tampers/urlencodeall.py
officialhocc/WhatWaf
0ca5c7f1ffc6dfba05e2d0a29799c023c4c6337f
[ "MIT" ]
null
null
null
content/tampers/urlencodeall.py
officialhocc/WhatWaf
0ca5c7f1ffc6dfba05e2d0a29799c023c4c6337f
[ "MIT" ]
null
null
null
content/tampers/urlencodeall.py
officialhocc/WhatWaf
0ca5c7f1ffc6dfba05e2d0a29799c023c4c6337f
[ "MIT" ]
1
2018-12-27T23:18:44.000Z
2018-12-27T23:18:44.000Z
__example_payload__ = "SELECT * FROM information_schema.tables" __type__ = "encoding all characters in the payload into their URL encoding equivalent"
28.5
86
0.698246
__example_payload__ = "SELECT * FROM information_schema.tables" __type__ = "encoding all characters in the payload into their URL encoding equivalent" def tamper(payload, **kwargs): retval = "" for char in payload: retval += "%{}".format(ord(char)) return retval
0
0
0
0
0
110
0
0
23
2ccf9cae31016b266b5a8a656b3aea0c3e571fc9
361
py
Python
uvloop/includes/__init__.py
Psycojoker/uvloop
03487c80a508ea92e66f976fa196e64514894205
[ "Apache-2.0", "MIT" ]
9,084
2016-04-04T10:42:42.000Z
2022-03-30T22:53:22.000Z
uvloop/includes/__init__.py
Psycojoker/uvloop
03487c80a508ea92e66f976fa196e64514894205
[ "Apache-2.0", "MIT" ]
382
2016-04-02T19:19:09.000Z
2022-03-22T08:39:18.000Z
uvloop/includes/__init__.py
Psycojoker/uvloop
03487c80a508ea92e66f976fa196e64514894205
[ "Apache-2.0", "MIT" ]
562
2016-04-01T19:42:12.000Z
2022-03-30T22:40:40.000Z
# flake8: noqa # These have to be synced with the stdlib.pxi
15.041667
45
0.839335
# flake8: noqa # These have to be synced with the stdlib.pxi import asyncio import collections import concurrent.futures import errno import functools import gc import inspect import itertools import os import signal import socket import subprocess import ssl import stat import sys import threading import traceback im...
0
0
0
0
0
0
0
-141
440
1c8ec33bd6590fc7464361b859e4510f1751e325
1,638
py
Python
program/google/protobuf/internal/import_test_package/import_public_pb2.py
Addision/ProtoExcelTool
17eaa08c08312e59c5a8f6114a121177ca65508a
[ "MIT" ]
null
null
null
program/google/protobuf/internal/import_test_package/import_public_pb2.py
Addision/ProtoExcelTool
17eaa08c08312e59c5a8f6114a121177ca65508a
[ "MIT" ]
null
null
null
program/google/protobuf/internal/import_test_package/import_public_pb2.py
Addision/ProtoExcelTool
17eaa08c08312e59c5a8f6114a121177ca65508a
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by the protocol buffer compiler. DO NOT EDIT! # source: google/protobuf/internal/import_test_package/import_public.proto """Generated protocol buffer code.""" from google.protobuf import descriptor as _descriptor from google.protobuf import symbol_database as _symbol_database # @@pr...
45.5
236
0.856532
# -*- coding: utf-8 -*- # Generated by the protocol buffer compiler. DO NOT EDIT! # source: google/protobuf/internal/import_test_package/import_public.proto """Generated protocol buffer code.""" from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf i...
0
0
0
0
0
0
0
120
67
fef38ca47668163b162c207f959688da2177c198
776
py
Python
pomdpy/util/console.py
wecacuee/POMDPy
c23ebf90f5815db4326564110487779961736b60
[ "MIT" ]
210
2015-04-23T17:05:50.000Z
2022-03-14T08:00:00.000Z
pomdpy/util/console.py
wecacuee/POMDPy
c23ebf90f5815db4326564110487779961736b60
[ "MIT" ]
15
2015-04-13T05:36:14.000Z
2019-05-06T19:14:50.000Z
pomdpy/util/console.py
wecacuee/POMDPy
c23ebf90f5815db4326564110487779961736b60
[ "MIT" ]
76
2016-08-18T03:54:08.000Z
2022-01-26T09:08:23.000Z
""" CONSOLE LOGGING VERBOSITY LEVELS --------------------------------- 0 - FATAL 1 - CRITICAL 2 - INFO 3 - LOUD 4 - DEBUG """ from __future__ import print_function VERBOSITY = 3 # Pass a function that handles printing
20.421053
87
0.489691
""" CONSOLE LOGGING VERBOSITY LEVELS --------------------------------- 0 - FATAL 1 - CRITICAL 2 - INFO 3 - LOUD 4 - DEBUG """ from __future__ import print_function VERBOSITY = 3 def print_divider(size): if size == "large": print("======================================================================") ...
0
0
0
0
0
485
0
0
68
44ed70cbfc3304e7e67ef97dda862a36beaab64b
6,182
py
Python
scripts/download_objectron_shards.py
yycho0108/ai604-video-object-pose
7067f36281038272b0e39166d8f9718076bb6e75
[ "MIT" ]
null
null
null
scripts/download_objectron_shards.py
yycho0108/ai604-video-object-pose
7067f36281038272b0e39166d8f9718076bb6e75
[ "MIT" ]
13
2021-04-13T04:58:38.000Z
2021-06-17T04:58:07.000Z
scripts/download_objectron_shards.py
yycho0108/ai604-video-object-pose
7067f36281038272b0e39166d8f9718076bb6e75
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import logging from pathlib import Path from google.cloud import storage bucket = None def download_shard(shard: str, out_dir: str, bucket_local=None): """Download a single shard into `out_dir`. NOTE(ycho): The output file is automatically named according to the base-name of `shar...
34.926554
103
0.573924
#!/usr/bin/env python3 import multiprocessing as mp import functools import logging import time from typing import List from tqdm.auto import tqdm from dataclasses import dataclass from simple_parsing import Serializable from pathlib import Path from google.cloud import storage from top.data.objectron_detection impo...
0
255
0
0
0
4,012
0
90
270
0893a71e0f5da806a8a314e41845ca5a36b8b9a3
1,231
py
Python
scripts/text_analysis.py
Lukas-Justen/Airbnb-Price-Evaluator
8759e32e94510520984223d18f0f9b09396aa448
[ "MIT" ]
null
null
null
scripts/text_analysis.py
Lukas-Justen/Airbnb-Price-Evaluator
8759e32e94510520984223d18f0f9b09396aa448
[ "MIT" ]
null
null
null
scripts/text_analysis.py
Lukas-Justen/Airbnb-Price-Evaluator
8759e32e94510520984223d18f0f9b09396aa448
[ "MIT" ]
3
2019-02-05T03:09:38.000Z
2020-01-30T02:55:37.000Z
import pandas as pd import re from keras.models import Sequential from keras.layers import Dense from nltk.corpus import stopwords from sklearn.feature_extraction.text import TfidfVectorizer data = pd.read_csv('data/seattle/3/listings_texts.csv') corpus = data['description'] y = data['price'] X=[] for i,line in enum...
31.564103
109
0.718115
import pandas as pd import re from keras.models import Sequential from keras.layers import Dense from keras.wrappers.scikit_learn import KerasRegressor from sklearn.preprocessing import StandardScaler from nltk.corpus import stopwords import nltk from sklearn.feature_extraction.text import TfidfVectorizer data = pd.r...
0
0
0
0
0
0
0
50
66
af623b00cd842370a410852427b7895cb98e73bd
1,591
py
Python
data/plot_produced_events_frequency.py
lpraat/scep2019
f120ee20397648e708cce41a7949c70b523b6e56
[ "MIT" ]
1
2021-11-02T20:34:22.000Z
2021-11-02T20:34:22.000Z
data/plot_produced_events_frequency.py
lpraat/scep2019
f120ee20397648e708cce41a7949c70b523b6e56
[ "MIT" ]
null
null
null
data/plot_produced_events_frequency.py
lpraat/scep2019
f120ee20397648e708cce41a7949c70b523b6e56
[ "MIT" ]
1
2021-11-02T20:34:29.000Z
2021-11-02T20:34:29.000Z
if __name__ == '__main__': plot_events_produced_frequency('first_half.txt')
25.253968
103
0.540541
import time import matplotlib.pyplot as plt from confluent_kafka import Producer def delivery_report(err, msg): if err is not None: print('Message delivery failed: {}'.format(err)) def plot_events_produced_frequency(data): second = 0 seconds = [] num_events = [] producer = Producer({'bo...
0
0
0
0
0
1,379
0
15
113
c441282bcbc825edec262db51bb98fc861239dc2
10,372
py
Python
postcipes/unstructured_channel_flow.py
Mopolino8/postcipes
5d67b383aa3e314b581b5262ba95f734ecb6369f
[ "MIT" ]
null
null
null
postcipes/unstructured_channel_flow.py
Mopolino8/postcipes
5d67b383aa3e314b581b5262ba95f734ecb6369f
[ "MIT" ]
null
null
null
postcipes/unstructured_channel_flow.py
Mopolino8/postcipes
5d67b383aa3e314b581b5262ba95f734ecb6369f
[ "MIT" ]
1
2019-11-24T17:11:16.000Z
2019-11-24T17:11:16.000Z
# This file is part of postcipes # (c) Timofey Mukha # The code is released under the MIT Licence. # See LICENCE.txt and the Legal section in the README for more information from __future__ import absolute_import from __future__ import division from __future__ import print_function __all__ = ["UnstructuredChannelFlow...
40.515625
100
0.558427
# This file is part of postcipes # (c) Timofey Mukha # The code is released under the MIT Licence. # See LICENCE.txt and the Legal section in the README for more information from __future__ import absolute_import from __future__ import division from __future__ import print_function from .postcipe import Postcipe impor...
0
0
0
9,757
0
0
0
70
221
d92f467975214762a809181706879ef56dad667e
290
py
Python
web/impact/impact/v1/views/judging_round_detail_view.py
masschallenge/impact-api
81075ced8fcc95de9390dd83c15e523e67fc48c0
[ "MIT" ]
5
2017-10-19T15:11:52.000Z
2020-03-08T07:16:21.000Z
web/impact/impact/v1/views/judging_round_detail_view.py
masschallenge/impact-api
81075ced8fcc95de9390dd83c15e523e67fc48c0
[ "MIT" ]
182
2017-06-21T19:32:13.000Z
2021-03-22T13:38:16.000Z
web/impact/impact/v1/views/judging_round_detail_view.py
masschallenge/impact-api
81075ced8fcc95de9390dd83c15e523e67fc48c0
[ "MIT" ]
1
2018-06-23T11:53:18.000Z
2018-06-23T11:53:18.000Z
# MIT License # Copyright (c) 2017 MassChallenge, Inc.
26.363636
59
0.813793
# MIT License # Copyright (c) 2017 MassChallenge, Inc. from impact.v1.helpers import JudgingRoundHelper from impact.v1.views.base_detail_view import BaseDetailView class JudgingRoundDetailView(BaseDetailView): view_name = "judging_round_detail" helper_class = JudgingRoundHelper
0
0
0
101
0
0
0
65
68
9ccb8028ad0763b4db88db48c471d0ce6a4d0c23
443
py
Python
ecr_list.py
willfong/aws-helper
21708044fbf95b76393e9b5f0e86c5e74ff11c77
[ "MIT" ]
null
null
null
ecr_list.py
willfong/aws-helper
21708044fbf95b76393e9b5f0e86c5e74ff11c77
[ "MIT" ]
null
null
null
ecr_list.py
willfong/aws-helper
21708044fbf95b76393e9b5f0e86c5e74ff11c77
[ "MIT" ]
null
null
null
import boto3 aws_ecr_client = boto3.client('ecr') response = aws_ecr_client.describe_repositories() for repo in response['repositories']: response = aws_ecr_client.get_authorization_token(registryIds=[repo['registryId']]) print(f"{repo['repositoryName']}\t{repo['repositoryArn']}") #print(f" {response['a...
34.076923
87
0.742664
import boto3 import base64 aws_ecr_client = boto3.client('ecr') response = aws_ecr_client.describe_repositories() for repo in response['repositories']: response = aws_ecr_client.get_authorization_token(registryIds=[repo['registryId']]) print(f"{repo['repositoryName']}\t{repo['repositoryArn']}") #print(f"...
0
0
0
0
0
0
0
-8
22
941d365262555a8c34051404c843d63f740f4d10
3,915
py
Python
tests/constants.py
acutaia/goeasy-ublox_reader
f4662389667c9087ca73dd33e5122891bd05db8a
[ "Apache-2.0" ]
null
null
null
tests/constants.py
acutaia/goeasy-ublox_reader
f4662389667c9087ca73dd33e5122891bd05db8a
[ "Apache-2.0" ]
null
null
null
tests/constants.py
acutaia/goeasy-ublox_reader
f4662389667c9087ca73dd33e5122891bd05db8a
[ "Apache-2.0" ]
null
null
null
""" Test constants :author: Angelo Cutaia :copyright: Copyright 2021, LINKS Foundation :version: 1.0.0 .. Copyright 2021 LINKS Foundation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the Lice...
18.294393
88
0.516731
""" Test constants :author: Angelo Cutaia :copyright: Copyright 2021, LINKS Foundation :version: 1.0.0 .. Copyright 2021 LINKS Foundation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the Lice...
0
0
0
0
0
0
0
0
0
d827fc4c0960176a711a9d9d10c251e11d8975fa
239
py
Python
tests/test_base.py
FlorianLudwig/datamodel-code-generator
052882f7c5bd883fac0f42916a5a8fc9623f37ce
[ "MIT" ]
null
null
null
tests/test_base.py
FlorianLudwig/datamodel-code-generator
052882f7c5bd883fac0f42916a5a8fc9623f37ce
[ "MIT" ]
null
null
null
tests/test_base.py
FlorianLudwig/datamodel-code-generator
052882f7c5bd883fac0f42916a5a8fc9623f37ce
[ "MIT" ]
null
null
null
from datamodel_code_generator.parser.base import snake_to_upper_camel def test_snake_to_upper_camel_underscore(): """In case a name starts with a underline, we should keep it.""" assert snake_to_upper_camel('_hello') == '_Hello'
34.142857
69
0.778243
from datamodel_code_generator.parser.base import snake_to_upper_camel def test_snake_to_upper_camel_underscore(): """In case a name starts with a underline, we should keep it.""" assert snake_to_upper_camel('_hello') == '_Hello'
0
0
0
0
0
0
0
0
0
05407402a2ccd8b744694eeb09b18264ced17222
5,580
py
Python
Lay_dataset.py
sixduck/Sorting-robot-using-Opencv-Tensorflow-Arduino
54f58d8899b3c29dcb12eb4843f3418d36824c8a
[ "MIT" ]
null
null
null
Lay_dataset.py
sixduck/Sorting-robot-using-Opencv-Tensorflow-Arduino
54f58d8899b3c29dcb12eb4843f3418d36824c8a
[ "MIT" ]
null
null
null
Lay_dataset.py
sixduck/Sorting-robot-using-Opencv-Tensorflow-Arduino
54f58d8899b3c29dcb12eb4843f3418d36824c8a
[ "MIT" ]
null
null
null
import cv2 import numpy as np import dk_ardruino import serial cam_mtx=np.load('utils/cam_mtx.npy') dist=np.load('utils/dist.npy') newcam_mtx=np.load('utils/newcam_mtx.npy') roi=np.load('utils/roi.npy') matrix = np.load('utils/abc.npy') area1 = int(open('utils/Resolution.txt').read().split('\n')[2]) width = i...
36.953642
123
0.507706
import cv2 import numpy as np import dk_ardruino import serial cam_mtx=np.load('utils/cam_mtx.npy') dist=np.load('utils/dist.npy') newcam_mtx=np.load('utils/newcam_mtx.npy') roi=np.load('utils/roi.npy') matrix = np.load('utils/abc.npy') area1 = int(open('utils/Resolution.txt').read().split('\n')[2]) width = i...
0
0
0
0
0
650
0
0
48
0be1ea82fa002a548d8dd7062260cae15d0d9942
2,791
py
Python
backend/tournesol/urls.py
sigmike/tournesol
9d92ff9c552c3b2923b3222f5f32d6b7e558de29
[ "CC0-1.0" ]
null
null
null
backend/tournesol/urls.py
sigmike/tournesol
9d92ff9c552c3b2923b3222f5f32d6b7e558de29
[ "CC0-1.0" ]
null
null
null
backend/tournesol/urls.py
sigmike/tournesol
9d92ff9c552c3b2923b3222f5f32d6b7e558de29
[ "CC0-1.0" ]
null
null
null
# coding: utf-8 """ Defines Tournesol's backend API routes """ from django.urls import include, path from rest_framework import routers from .views import ComparisonDetailApi, ComparisonListApi, ComparisonListFilteredApi from .views.email_domains import EmailDomainsList from .views.exports import ExportAllView, Expo...
26.580952
92
0.654246
# coding: utf-8 """ Defines Tournesol's backend API routes """ from django.urls import include, path from rest_framework import routers from .views import ComparisonDetailApi, ComparisonListApi, ComparisonListFilteredApi from .views.email_domains import EmailDomainsList from .views.exports import ExportAllView, Expo...
0
0
0
0
0
0
0
15
0
5b8a078ff34f1d035aa62e9f50a56a993be2958b
1,678
py
Python
src/utils/live-view/WindowCapture.py
soyuka/botty
cc1670ea1db72c5e0ac91685897bf63c89b18896
[ "MIT" ]
1
2021-11-13T23:23:25.000Z
2021-11-13T23:23:25.000Z
src/utils/live-view/WindowCapture.py
soyuka/botty
cc1670ea1db72c5e0ac91685897bf63c89b18896
[ "MIT" ]
null
null
null
src/utils/live-view/WindowCapture.py
soyuka/botty
cc1670ea1db72c5e0ac91685897bf63c89b18896
[ "MIT" ]
null
null
null
import mss sct = mss.mss()
41.95
135
0.681764
import numpy as np import win32gui, win32api import ctypes import mss sct = mss.mss() class WindowCapture: w = 0 h = 0 hwnd = None cropped_x = 0 cropped_y = 0 offset_x = 0 offset_y = 0 def __init__(self): window_handle = win32gui.FindWindow('OsWindow', 'Diablo II: Resurrected') ...
0
0
0
1,571
0
0
0
-7
88
e8635a64531764fac2692b44d3e7d7ab7842efa8
1,594
py
Python
pyohio/schedule.py
tylerdave/pyohio
f4d5c4a06f02afdf2f7a326b6072f2e95a9fdcb8
[ "MIT" ]
null
null
null
pyohio/schedule.py
tylerdave/pyohio
f4d5c4a06f02afdf2f7a326b6072f2e95a9fdcb8
[ "MIT" ]
null
null
null
pyohio/schedule.py
tylerdave/pyohio
f4d5c4a06f02afdf2f7a326b6072f2e95a9fdcb8
[ "MIT" ]
null
null
null
import requests import requests_cache from collections import OrderedDict from datetime import datetime from dateutil import parser from operator import itemgetter from tabulate import tabulate SCHEDULE_URL = "http://pyohio.org/schedule/json/" def get_schedule(cache_ttl=3600): """ Get the schedule from the confer...
41.947368
95
0.707026
import requests import requests_cache from collections import OrderedDict from datetime import datetime from dateutil import parser from operator import itemgetter from tabulate import tabulate SCHEDULE_URL = "http://pyohio.org/schedule/json/" def get_schedule(cache_ttl=3600): """ Get the schedule from the confer...
0
0
0
0
0
0
0
0
0
7995d4c1e1bb63d1840f0a19cb868618116f6f6c
575
py
Python
app/app/migrations/0003_auto_20210109_0016.py
maszaa/remote-desktop-software-controller
270176b46ce23620e3811a24498f7425df98f396
[ "MIT" ]
1
2022-01-29T13:44:47.000Z
2022-01-29T13:44:47.000Z
app/app/migrations/0003_auto_20210109_0016.py
maszaa/remote-desktop-software-controller
270176b46ce23620e3811a24498f7425df98f396
[ "MIT" ]
5
2021-01-16T16:19:16.000Z
2021-01-29T12:59:29.000Z
app/app/migrations/0003_auto_20210109_0016.py
maszaa/remote-desktop-software-controller
270176b46ce23620e3811a24498f7425df98f396
[ "MIT" ]
1
2021-01-10T14:45:38.000Z
2021-01-10T14:45:38.000Z
# Generated by Django 3.1.5 on 2021-01-08 22:16
25
99
0.598261
# Generated by Django 3.1.5 on 2021-01-08 22:16 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('app', '0002_auto_20210108_2129'), ] operations = [ migrations.AlterModelOptions( name='command', options={'ordering'...
0
0
0
461
0
0
0
19
46
1ef431b4957d4a5e8c47ddae3802f8694f92521e
2,684
py
Python
haystack/utils/app_loading.py
atn9/django-haystack
bd60745ce82318b1819768c9a31db0579228654d
[ "BSD-3-Clause" ]
null
null
null
haystack/utils/app_loading.py
atn9/django-haystack
bd60745ce82318b1819768c9a31db0579228654d
[ "BSD-3-Clause" ]
null
null
null
haystack/utils/app_loading.py
atn9/django-haystack
bd60745ce82318b1819768c9a31db0579228654d
[ "BSD-3-Clause" ]
null
null
null
# encoding: utf-8 from __future__ import absolute_import, division, print_function, unicode_literals from django import VERSION as DJANGO_VERSION from django.conf import settings from django.utils.importlib import import_module __all__ = ['haystack_get_models', 'haystack_load_apps'] APP = 'app' MODEL = 'model' if...
31.209302
132
0.632265
# encoding: utf-8 from __future__ import absolute_import, division, print_function, unicode_literals from django import VERSION as DJANGO_VERSION from django.conf import settings from django.core.exceptions import ImproperlyConfigured from django.db.models.loading import get_app, get_model, get_models from django.util...
0
0
0
0
0
1,533
0
80
151
474b914f97e6aa9059538049c5d4fc6346792ce1
859
py
Python
recipe_modules/futures/examples/background_helper.resources/helper.py
engeg/recipes-py
9dac536b55887262b4ce846f3db7a7f596542e5e
[ "Apache-2.0" ]
null
null
null
recipe_modules/futures/examples/background_helper.resources/helper.py
engeg/recipes-py
9dac536b55887262b4ce846f3db7a7f596542e5e
[ "Apache-2.0" ]
null
null
null
recipe_modules/futures/examples/background_helper.resources/helper.py
engeg/recipes-py
9dac536b55887262b4ce846f3db7a7f596542e5e
[ "Apache-2.0" ]
null
null
null
# Copyright 2019 The LUCI Authors. All rights reserved. # Use of this source code is governed under the Apache License, Version 2.0 # that can be found in the LICENSE file. import json import os import sys import time import signal signal.signal( ( signal.SIGBREAK # pylint: disable=no-member if sys.p...
23.216216
76
0.663562
# Copyright 2019 The LUCI Authors. All rights reserved. # Use of this source code is governed under the Apache License, Version 2.0 # that can be found in the LICENSE file. import json import os import sys import time import signal signal.signal( ( signal.SIGBREAK # pylint: disable=no-member if sys.p...
0
0
0
0
0
0
0
0
0
8d81e53036950dba7774071b6973aff11f1ed3ef
1,752
py
Python
core_dev/animations/progress.py
alexzanderr/_core-dev
831f69dad524e450c4243b1dd88f26de80e1d444
[ "MIT" ]
null
null
null
core_dev/animations/progress.py
alexzanderr/_core-dev
831f69dad524e450c4243b1dd88f26de80e1d444
[ "MIT" ]
null
null
null
core_dev/animations/progress.py
alexzanderr/_core-dev
831f69dad524e450c4243b1dd88f26de80e1d444
[ "MIT" ]
null
null
null
from time import sleep from animations import progress_bar from threading import Thread # for i in range(100): # time.sleep(0.1) # sys.stdout.write(f'salutare-{i}\n') # sys.stdout.write(f'andrew-{i}\n') # sys.stdout.write("\x1b[1A") # cursor up one line # sys.stdout.write("\x1b[2K") # delete t...
21.9
85
0.638699
from time import sleep import os from animations import progress_bar from threading import Thread import sys import time # for i in range(100): # time.sleep(0.1) # sys.stdout.write(f'salutare-{i}\n') # sys.stdout.write(f'andrew-{i}\n') # sys.stdout.write("\x1b[1A") # cursor up one line # sys.s...
0
0
0
0
0
403
0
-21
181
093cc965f02f52c91f22af862a09e4f2efc576ab
3,743
py
Python
GarbleExecutable.py
greshje-nachc/data-owner-tools
771a6fbcd24af8b9d3861e337f4dbd213ead9dc8
[ "Apache-2.0" ]
null
null
null
GarbleExecutable.py
greshje-nachc/data-owner-tools
771a6fbcd24af8b9d3861e337f4dbd213ead9dc8
[ "Apache-2.0" ]
null
null
null
GarbleExecutable.py
greshje-nachc/data-owner-tools
771a6fbcd24af8b9d3861e337f4dbd213ead9dc8
[ "Apache-2.0" ]
1
2021-09-28T16:58:36.000Z
2021-09-28T16:58:36.000Z
from multiprocessing import freeze_support import sys import os # pyinstaller GarbleExecutable.py --onefile -w --add-data ./venv/Lib/site-packages/clkhash/data;clkhash/data --add-data ./venv/Lib/site-packages/clkhash/schemas;clkhash/schemas --add-data ./example-schema;example-schema if getattr(sys, 'frozen', False)...
33.419643
220
0.635052
import garble import wx from multiprocessing import freeze_support import sys import os from pathlib import Path # pyinstaller GarbleExecutable.py --onefile -w --add-data ./venv/Lib/site-packages/clkhash/data;clkhash/data --add-data ./venv/Lib/site-packages/clkhash/schemas;clkhash/schemas --add-data ./example-schema;...
0
0
0
3,137
0
70
0
-17
112
d5aa27298b18cea6f7b3bd1d6baded26a49d8045
3,807
py
Python
main.py
ashtedroid/Test-Cases-Prioritization-and-Analysis
70a6997f3764ea39c51fdc8cd6806e430088f8a7
[ "MIT" ]
1
2020-04-24T08:08:49.000Z
2020-04-24T08:08:49.000Z
main.py
ashtedroid/Test-Cases-Prioritization-and-Analysis
70a6997f3764ea39c51fdc8cd6806e430088f8a7
[ "MIT" ]
null
null
null
main.py
ashtedroid/Test-Cases-Prioritization-and-Analysis
70a6997f3764ea39c51fdc8cd6806e430088f8a7
[ "MIT" ]
null
null
null
''' ================================================================= @version 2.0 @author Ashwin Ramadevanahalli @title Testing. Main module. ================================================================= ''' import os import sys import subprocess import testset_parse import gcov_parse import rand_pr...
25.897959
141
0.67192
''' ================================================================= @version 2.0 @author Ashwin Ramadevanahalli @title Testing. Main module. ================================================================= ''' import os import sys import subprocess import testset_parse import gcov_parse import rand_pr...
0
0
0
0
0
0
0
0
0
892ddbf9761a9ac75a73aa7d4771197be4dee5a9
10,730
py
Python
internalScripts/analysis-scripts/GeneratePhenotypeROCCurve.py
kbase/probabilistic_annotation
2454925ca98c80c73bda327a0eff8aed94c5a48d
[ "MIT" ]
null
null
null
internalScripts/analysis-scripts/GeneratePhenotypeROCCurve.py
kbase/probabilistic_annotation
2454925ca98c80c73bda327a0eff8aed94c5a48d
[ "MIT" ]
null
null
null
internalScripts/analysis-scripts/GeneratePhenotypeROCCurve.py
kbase/probabilistic_annotation
2454925ca98c80c73bda327a0eff8aed94c5a48d
[ "MIT" ]
null
null
null
#!/usr/bin/python -u import argparse import sys import re import os import traceback from operator import itemgetter, attrgetter from biokbase.probabilistic_annotation.Client import _read_inifile desc = ''' Given a JSON object calculate the false positive, negative rates. Optionally omit everything that isn't in the ...
54.191919
170
0.656198
#!/usr/bin/python -u import argparse import sys import re import os import traceback from operator import itemgetter, attrgetter from biokbase.probabilistic_annotation.Client import _read_inifile from biokbase.workspaceService.Client import * desc = ''' Given a JSON object calculate the false positive, negative rates...
0
0
0
0
0
0
0
25
22
fd0f329ab7fc7ffe7339fd4bccaa6df4c6149391
836
py
Python
modules/sentiment.py
jsamar1/wtfthisarticle
e0ed4ff0e70822339d9b8c6bed49ac165f2f97a2
[ "MIT" ]
null
null
null
modules/sentiment.py
jsamar1/wtfthisarticle
e0ed4ff0e70822339d9b8c6bed49ac165f2f97a2
[ "MIT" ]
7
2021-03-18T21:01:21.000Z
2022-03-11T23:28:59.000Z
modules/sentiment.py
jsamar1/wtfthisarticle
e0ed4ff0e70822339d9b8c6bed49ac165f2f97a2
[ "MIT" ]
1
2018-09-30T10:09:53.000Z
2018-09-30T10:09:53.000Z
# Imports the Google Cloud client library
27.866667
78
0.696172
# Imports the Google Cloud client library from google.cloud import language from google.cloud.language import enums from google.cloud.language import types import json import re def analyze(text): # Instantiates a client client = language.LanguageServiceClient() # The text to analyze document = types...
0
0
0
0
0
634
0
26
134
13fa97be4cc3d64f3acac671d8fd28e7569d6f67
64
py
Python
Dangerous/Golismero/thirdparty_libs/requests_ntlm/__init__.py
JeyZeta/Dangerous-
824ea6b571eda98bb855f176361e9b35dfda578e
[ "MIT" ]
null
null
null
Dangerous/Golismero/thirdparty_libs/requests_ntlm/__init__.py
JeyZeta/Dangerous-
824ea6b571eda98bb855f176361e9b35dfda578e
[ "MIT" ]
null
null
null
Dangerous/Golismero/thirdparty_libs/requests_ntlm/__init__.py
JeyZeta/Dangerous-
824ea6b571eda98bb855f176361e9b35dfda578e
[ "MIT" ]
1
2018-07-04T18:35:16.000Z
2018-07-04T18:35:16.000Z
from requests_ntlm import HttpNtlmAuth __all__ = [HttpNtlmAuth]
21.333333
38
0.84375
from requests_ntlm import HttpNtlmAuth __all__ = [HttpNtlmAuth]
0
0
0
0
0
0
0
0
0
b9440083d88705c3693e34c4cc54c50c8df8fe7f
634
py
Python
liliput/migrations/0002_verify_and_count.py
strassan/www.kaifeck.de
b54698e8e57eaedbc4cb4ea3335fc719df92108f
[ "MIT" ]
2
2020-07-29T17:35:31.000Z
2021-06-06T11:37:49.000Z
liliput/migrations/0002_verify_and_count.py
strassan/www.kaifeck.de
b54698e8e57eaedbc4cb4ea3335fc719df92108f
[ "MIT" ]
4
2020-10-28T19:06:02.000Z
2021-01-11T16:06:46.000Z
liliput/migrations/0002_verify_and_count.py
strassan/www.kaifeck.de
b54698e8e57eaedbc4cb4ea3335fc719df92108f
[ "MIT" ]
null
null
null
# Generated by Django 3.0.7 on 2020-06-30 14:42
24.384615
65
0.585174
# Generated by Django 3.0.7 on 2020-06-30 14:42 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('liliput', '0001_initial'), ] operations = [ migrations.AddField( model_name='shortlink', name='number_of_requests', ...
0
0
0
520
0
0
0
19
46
c361e3d7e233b7a9094e7596ce0361df9cd3aa9d
946
py
Python
src/gamesbyexample/tutorialguess1.py
RedStarfish/PythonStdioGames
0fa4d42f1a0c2dde403e70cdd47e7a9e81430efe
[ "MIT" ]
null
null
null
src/gamesbyexample/tutorialguess1.py
RedStarfish/PythonStdioGames
0fa4d42f1a0c2dde403e70cdd47e7a9e81430efe
[ "MIT" ]
null
null
null
src/gamesbyexample/tutorialguess1.py
RedStarfish/PythonStdioGames
0fa4d42f1a0c2dde403e70cdd47e7a9e81430efe
[ "MIT" ]
null
null
null
"""Tutorial: Guess the Number, by Al Sweigart al@inventwithpython.com Part 1 of a tutorial to make a "Guess the Number" game, bit by bit.""" # Try copying the code in this program on your own and running the # program before moving on to part 2. (You don't have to copy the # comments.) # Everything after a # is a "c...
36.384615
72
0.739958
"""Tutorial: Guess the Number, by Al Sweigart al@inventwithpython.com Part 1 of a tutorial to make a "Guess the Number" game, bit by bit.""" # Try copying the code in this program on your own and running the # program before moving on to part 2. (You don't have to copy the # comments.) # Everything after a # is a "c...
0
0
0
0
0
0
0
0
0
f5ce58a0e4e3e74a06b00a176dd1ef7357320590
4,710
py
Python
ptranking/ltr_adhoc/listwise/lambdarank.py
ii-research-ranking/ptranking
2794e6e086bcd87ce177f40194339e9b825e9f4c
[ "MIT" ]
64
2018-09-19T17:04:04.000Z
2020-04-30T07:54:04.000Z
ptranking/ltr_adhoc/listwise/lambdarank.py
ii-research-ranking/ptranking
2794e6e086bcd87ce177f40194339e9b825e9f4c
[ "MIT" ]
4
2018-09-27T06:59:02.000Z
2020-01-05T12:35:12.000Z
ptranking/ltr_adhoc/listwise/lambdarank.py
ii-research-ranking/ptranking
2794e6e086bcd87ce177f40194339e9b825e9f4c
[ "MIT" ]
11
2018-09-28T07:17:51.000Z
2020-03-12T06:28:35.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- """Description Christopher J.C. Burges, Robert Ragno, and Quoc Viet Le. 2006. Learning to Rank with Nonsmooth Cost Functions. In Proceedings of NIPS conference. 193200. """ ###### Parameter of LambdaRank ######
44.018692
149
0.661146
#!/usr/bin/env python # -*- coding: utf-8 -*- """Description Christopher J.C. Burges, Robert Ragno, and Quoc Viet Le. 2006. Learning to Rank with Nonsmooth Cost Functions. In Proceedings of NIPS conference. 193–200. """ import torch import torch.nn.functional as F from ptranking.data.data_utils import LABEL_TYPE fro...
6
0
0
4,055
0
0
0
191
202
78d1e28cfc697d589decfb83ba1a7618a037e58a
1,928
py
Python
dash_extra_components/TableOfContents.py
plotly/dash-extra-components
947b13e045806b4f158d77d84bd5ade938fce96e
[ "MIT" ]
12
2019-01-03T21:13:59.000Z
2021-08-10T22:55:52.000Z
dash_extra_components/TableOfContents.py
plotly/dash-extra-components
947b13e045806b4f158d77d84bd5ade938fce96e
[ "MIT" ]
7
2018-12-20T22:08:23.000Z
2021-05-07T23:54:50.000Z
dash_extra_components/TableOfContents.py
plotly/dash-extra-components
947b13e045806b4f158d77d84bd5ade938fce96e
[ "MIT" ]
1
2021-06-18T19:12:40.000Z
2021-06-18T19:12:40.000Z
# AUTO GENERATED FILE - DO NOT EDIT
49.435897
222
0.695539
# AUTO GENERATED FILE - DO NOT EDIT from dash.development.base_component import Component, _explicitize_args class TableOfContents(Component): """A TableOfContents component. Build a table of contents list with links to the headers tag. Keyword arguments: - id (string; optional): Unique identifier for the compo...
0
1,095
0
699
0
0
0
51
46
feb7dbf6b94b36b4b780077450bb6fc7721e7421
1,191
py
Python
tests/integration/models/test_front.py
Lordshinjo/asyncpraw
d94d89a992d9b5b300439ea6884a9df1d95511e2
[ "BSD-2-Clause" ]
72
2020-07-14T02:02:21.000Z
2022-03-15T13:10:02.000Z
tests/integration/models/test_front.py
Lordshinjo/asyncpraw
d94d89a992d9b5b300439ea6884a9df1d95511e2
[ "BSD-2-Clause" ]
68
2020-07-16T05:29:43.000Z
2022-03-14T12:04:56.000Z
tests/integration/models/test_front.py
Lordshinjo/asyncpraw
d94d89a992d9b5b300439ea6884a9df1d95511e2
[ "BSD-2-Clause" ]
19
2020-07-22T15:34:30.000Z
2022-03-27T20:28:46.000Z
"""Test asyncpraw.models.front.""" from .. import IntegrationTest
34.028571
82
0.648195
"""Test asyncpraw.models.front.""" from .. import IntegrationTest class TestFront(IntegrationTest): async def test_best(self): with self.use_cassette(): submissions = await self.async_list(self.reddit.front.best()) assert len(submissions) == 100 async def test_controversial(self):...
0
0
928
12
0
0
0
0
184
eeae97e3e1918c205fa4325233b0d7d25463308e
3,303
py
Python
app/routes.py
kasztp/Scrabble
6d97044a539a76271f8540709efa332a92362c84
[ "MIT" ]
1
2020-11-18T20:05:43.000Z
2020-11-18T20:05:43.000Z
app/routes.py
kasztp/Scrabble
6d97044a539a76271f8540709efa332a92362c84
[ "MIT" ]
1
2021-12-11T15:43:27.000Z
2021-12-11T15:48:51.000Z
app/routes.py
kasztp/Scrabble
6d97044a539a76271f8540709efa332a92362c84
[ "MIT" ]
4
2020-04-01T16:53:12.000Z
2021-01-14T10:19:02.000Z
tile_draw = [] grouped = {} hasblank = 0
39.795181
92
0.536482
from flask import render_template, flash, redirect, request, url_for from app import app from .forms import ConfigForm from .scrabble_logic import Scrabble tile_draw = [] grouped = {} hasblank = 0 @app.route('/') def root(): return render_template('index.html', title='Home', scores=grouped, ...
0
3,009
0
0
0
0
0
68
180
1f8b2985369841e17a42d01d25ee774e67366b41
754
py
Python
Rasp_Pi_2018/should_i_water/send_mail_task.py
BitKnitting/should_I_water
8d849671892b7bbc9e947e0ba041c4c3527b6bbd
[ "MIT" ]
2
2018-05-20T00:26:31.000Z
2018-06-13T16:22:48.000Z
Rasp_Pi_2018/should_i_water/send_mail_task.py
BitKnitting/should_I_water
8d849671892b7bbc9e947e0ba041c4c3527b6bbd
[ "MIT" ]
null
null
null
Rasp_Pi_2018/should_i_water/send_mail_task.py
BitKnitting/should_I_water
8d849671892b7bbc9e947e0ba041c4c3527b6bbd
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import os import sys LIB_PATH = os.environ['LADYBUG_LIB_PATH'] sys.path.append(LIB_PATH) from build_message_lib import BuildMessage from plot_weather_lib import PlotWeather from send_message_lib import SendMessage # TODO: Error checking needs improvement. # plot_weather() returns True (could cre...
34.272727
77
0.777188
#!/usr/bin/env python3 import os import sys LIB_PATH = os.environ['LADYBUG_LIB_PATH'] sys.path.append(LIB_PATH) from build_message_lib import BuildMessage from plot_weather_lib import PlotWeather from send_message_lib import SendMessage # TODO: Error checking needs improvement. # plot_weather() returns True (could cre...
0
0
0
0
0
0
0
0
0
a938390837c72c215ad582ed7f13afb2eb5ac461
9,644
py
Python
autocompletion.py
giladbarnea/autocompletion
2e67ba64951754c34348756d5790714f04725ed7
[ "MIT" ]
1
2020-10-23T05:22:04.000Z
2020-10-23T05:22:04.000Z
autocompletion.py
giladbarnea/autocompletion
2e67ba64951754c34348756d5790714f04725ed7
[ "MIT" ]
null
null
null
autocompletion.py
giladbarnea/autocompletion
2e67ba64951754c34348756d5790714f04725ed7
[ "MIT" ]
null
null
null
''':' autocomplete() { if [ $# != 2 ] then echo "USAGE: autocomplete <command> <config-path>" return 1 fi local COMMAND="$1" local CONFIG_PATH="$(readlink -f "$2")" eval " _complete_$COMMAND() { local THIS_FILE=\"\$(readlink -f \"\${BASH_SOURCE[0]}\")\...
35.586716
120
0.579013
''':' autocomplete() { if [ $# != 2 ] then echo "USAGE: autocomplete <command> <config-path>" return 1 fi local COMMAND="$1" local CONFIG_PATH="$(readlink -f "$2")" eval " _complete_$COMMAND() { local THIS_FILE=\"\$(readlink -f \"\${BASH_SOURCE[0]}\")\...
0
0
0
6,208
0
1,916
0
-38
341
bb0cca9978a14262fdad4a5cb740fe6cfea8d3e5
576
py
Python
abc229/abc229_d.py
Vermee81/practice-coding-contests
78aada60fa75f208ee0eef337b33b27b1c260d18
[ "MIT" ]
null
null
null
abc229/abc229_d.py
Vermee81/practice-coding-contests
78aada60fa75f208ee0eef337b33b27b1c260d18
[ "MIT" ]
null
null
null
abc229/abc229_d.py
Vermee81/practice-coding-contests
78aada60fa75f208ee0eef337b33b27b1c260d18
[ "MIT" ]
null
null
null
# https://atcoder.jp/contests/abc229/tasks/abc229_d S = input() K = int(input()) ans = 0 tail_idx = 0 cum_dot = [0] * (len(S) + 1) for i in range(len(S)): if S[i] == '.': cum_dot[i + 1] = cum_dot[i] + 1 else: cum_dot[i + 1] = cum_dot[i] for head_idx in range(len(S)): while tail_idx <= l...
20.571429
75
0.581597
# https://atcoder.jp/contests/abc229/tasks/abc229_d S = input() K = int(input()) ans = 0 tail_idx = 0 cum_dot = [0] * (len(S) + 1) for i in range(len(S)): if S[i] == '.': cum_dot[i + 1] = cum_dot[i] + 1 else: cum_dot[i + 1] = cum_dot[i] def can_swap_to_x(start: int, end: int) -> bool: if...
0
0
0
0
0
106
0
0
23
0fadf45c92b0a0910501554f2fdcc4259660a3ab
3,513
py
Python
c7n/resources/shield.py
fadiguezel/cloud-custodian
147fffcf9a109ffd4248a746775b55def5a727c5
[ "Apache-2.0" ]
null
null
null
c7n/resources/shield.py
fadiguezel/cloud-custodian
147fffcf9a109ffd4248a746775b55def5a727c5
[ "Apache-2.0" ]
1
2021-02-24T04:42:37.000Z
2021-02-24T04:42:37.000Z
c7n/resources/shield.py
fadiguezel/cloud-custodian
147fffcf9a109ffd4248a746775b55def5a727c5
[ "Apache-2.0" ]
1
2021-01-26T10:03:21.000Z
2021-01-26T10:03:21.000Z
# Copyright 2015-2017 Capital One Services, LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed ...
34.441176
83
0.652149
# Copyright 2015-2017 Capital One Services, LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed ...
0
670
0
1,837
0
0
0
104
225