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
5dcf6a3f4ee83e62e50cab062484c07078e09b36
19,822
py
Python
archived_lectures/Fall_2019/common_python/common_python/tellurium/model_fitting.py
ModelEngineering/topics-course
cd0d73e4056663d170465669ecd699e8e74e35a0
[ "MIT" ]
2
2018-10-24T21:31:30.000Z
2019-10-23T20:29:22.000Z
archived_lectures/Fall_2019/common_python/common_python/tellurium/model_fitting.py
ModelEngineering/topics-course
cd0d73e4056663d170465669ecd699e8e74e35a0
[ "MIT" ]
1
2019-05-31T21:59:30.000Z
2019-05-31T21:59:30.000Z
archived_lectures/Fall_2019/common_python/common_python/tellurium/model_fitting.py
ModelEngineering/topics-course
cd0d73e4056663d170465669ecd699e8e74e35a0
[ "MIT" ]
9
2018-10-31T20:48:42.000Z
2019-11-20T21:47:43.000Z
'''Cross validation codes.''' """ kwargs: keyword arguments to runSimulation order of positional arguments: obs_data, model, parameters """ from collections import namedtuple import lmfit # Fitting lib import matplotlib.pyplot as plt import numpy as np import pandas as pd import tellurium as te TIME = "time" ME_LE...
33.314286
118
0.710372
'''Cross validation codes.''' """ kwargs: keyword arguments to runSimulation order of positional arguments: obs_data, model, parameters """ from collections import namedtuple import lmfit # Fitting lib import matplotlib.pyplot as plt import math import numpy as np import pandas as pd import random import tellurium...
0
0
0
0
676
579
0
-18
140
a209637e4afe6ddf32c6879c7f16d6eef2526e3f
3,912
py
Python
Marine.py
ti-lei/iphone11
f69e7050ecdc87651eab5e8fdb38e4f305a9257f
[ "bzip2-1.0.6" ]
null
null
null
Marine.py
ti-lei/iphone11
f69e7050ecdc87651eab5e8fdb38e4f305a9257f
[ "bzip2-1.0.6" ]
null
null
null
Marine.py
ti-lei/iphone11
f69e7050ecdc87651eab5e8fdb38e4f305a9257f
[ "bzip2-1.0.6" ]
null
null
null
import requests import json import pandas as pd import platform # : # 'ID': port_ID_map = {'87':'Los Angeles','2727':'longBeach','93':'Oakland','1253':'Shanhi','1006':'Yantian', '290':'Singapore','172':'Hamburg','2036':'Rotterdam','199':'Felixstowe'} # ship_type = ['CONTAINER SHIPS','DRY BREAKBULK','DRY...
31.548387
134
0.63318
import requests import json import datetime import pandas as pd import numpy as np import platform # 有時候的登入狀態會抓不到資料: # 要抓的港口 'ID': 港口名稱 port_ID_map = {'87':'Los Angeles','2727':'longBeach','93':'Oakland','1253':'Shanhi','1006':'Yantian', '290':'Singapore','172':'Hamburg','2036':'Rotterdam','199':'Felixsto...
747
250
0
0
0
581
0
-9
89
904d30cd99990d5d94752bedb14891ba59f015b1
2,606
py
Python
tools/remoteserver/test/unit/test_robotremoteserver.py
gdw2/robot-framework
f25068edf1502e76ba8664d4b5ed1aebe0ee2434
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
tools/remoteserver/test/unit/test_robotremoteserver.py
gdw2/robot-framework
f25068edf1502e76ba8664d4b5ed1aebe0ee2434
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
tools/remoteserver/test/unit/test_robotremoteserver.py
gdw2/robot-framework
f25068edf1502e76ba8664d4b5ed1aebe0ee2434
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
#!/usr/bin/env python import unittest import sys import os.path remotedir = os.path.dirname(os.path.dirname(os.path.dirname((__file__)))) sys.path.insert(0, remotedir) if __name__ == '__main__': unittest.main()
34.289474
79
0.658864
#!/usr/bin/env python import unittest import sys import os.path remotedir = os.path.dirname(os.path.dirname(os.path.dirname((__file__)))) sys.path.insert(0, remotedir) from robotremoteserver import RobotRemoteServer class NonServingRemoteServer(RobotRemoteServer): def __init__(self, library): self._lib...
0
0
0
2,196
0
0
0
26
138
31d368a09d53f7ef06a05986d7659e338c8d3ccd
1,149
py
Python
resources/lib/utils/jsonrpc.py
EnigmaNox/script.service.sponsorblock
a1ac5eb950b11803635f7174e94eacaab6784040
[ "MIT" ]
61
2020-03-02T04:51:02.000Z
2022-03-26T18:29:53.000Z
resources/lib/utils/jsonrpc.py
EnigmaNox/script.service.sponsorblock
a1ac5eb950b11803635f7174e94eacaab6784040
[ "MIT" ]
26
2020-03-02T14:17:58.000Z
2022-03-12T06:08:05.000Z
resources/lib/utils/jsonrpc.py
EnigmaNox/script.service.sponsorblock
a1ac5eb950b11803635f7174e94eacaab6784040
[ "MIT" ]
9
2020-03-02T04:51:34.000Z
2021-11-09T11:17:25.000Z
import logging logger = logging.getLogger(__name__) _JSONRPC_TEMPLATE = """{{"jsonrpc":"2.0","id":0,"method":"{method}","params":{params}}}""" PLAYER_MUSIC = 0 PLAYER_VIDEO = 1 PLAYER_PICTURE = 2 LIST_FIELD_ART = "art" LIST_FIELD_UNIQUEID = "uniqueid"
23.9375
101
0.665796
import json import logging import xbmc logger = logging.getLogger(__name__) class JSONRPCError(Exception): def __init__(self, code, message): # type: (int, str) -> None self.code = code self.message = message super(JSONRPCError, self).__init__(message) _JSONRPC_TEMPLATE = """{{"jsonr...
0
0
0
185
0
609
0
-20
114
d37d1db4d55dfafb01538b15343cd30825bd02af
23,951
py
Python
venv/lib/python3.6/site-packages/ansible_collections/netapp/ontap/plugins/modules/na_ontap_fpolicy_scope.py
usegalaxy-no/usegalaxy
75dad095769fe918eb39677f2c887e681a747f3a
[ "MIT" ]
1
2020-01-22T13:11:23.000Z
2020-01-22T13:11:23.000Z
venv/lib/python3.6/site-packages/ansible_collections/netapp/ontap/plugins/modules/na_ontap_fpolicy_scope.py
usegalaxy-no/usegalaxy
75dad095769fe918eb39677f2c887e681a747f3a
[ "MIT" ]
12
2020-02-21T07:24:52.000Z
2020-04-14T09:54:32.000Z
venv/lib/python3.6/site-packages/ansible_collections/netapp/ontap/plugins/modules/na_ontap_fpolicy_scope.py
usegalaxy-no/usegalaxy
75dad095769fe918eb39677f2c887e681a747f3a
[ "MIT" ]
null
null
null
#!/usr/bin/python # (c) 2021, NetApp, Inc # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type DOCUMENTATION = ''' module: na_ontap_fpolicy_scope short_description: NetApp ONTAP - Create, del...
46.148362
155
0.655296
#!/usr/bin/python # (c) 2021, NetApp, Inc # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type DOCUMENTATION = ''' module: na_ontap_fpolicy_scope short_description: NetApp ONTAP - Create, del...
0
0
0
19,155
0
0
0
318
179
5d9c85392bfe9bb4243e8f4af19e27ff3c31b32d
13,346
py
Python
src/codebots/cli/cli.py
franaudo/codebots
f45ee9f665cadc4627d397ae74eefca226269656
[ "MIT" ]
5
2021-05-06T21:51:30.000Z
2022-01-10T17:53:00.000Z
src/codebots/cli/cli.py
franaudo/codebots
f45ee9f665cadc4627d397ae74eefca226269656
[ "MIT" ]
10
2021-04-03T12:00:27.000Z
2021-11-04T16:27:48.000Z
src/codebots/cli/cli.py
franaudo/codebots
f45ee9f665cadc4627d397ae74eefca226269656
[ "MIT" ]
null
null
null
"""Console script for codebots. You can get detaled information about each of the bots with the :code:`--help` option. .. code-block:: bash codebots --help emailbot --help telebot --help slackbot --help sshbot --help deploybot --help latexbot --help drivebot ...
29.592018
144
0.629852
"""Console script for codebots. You can get detaled information about each of the bots with the :code:`--help` option. .. code-block:: bash codebots --help emailbot --help telebot --help slackbot --help sshbot --help deploybot --help latexbot --help drivebot ...
0
10,982
0
0
0
0
0
269
972
fd3021eed51e3ea874759c0958b45aa99639a905
2,020
py
Python
broker/src/ave/broker/resource.py
yiu31802/ave
e46fc357f9464d5beaf42568a74bb95e6b1b8037
[ "BSD-3-Clause" ]
17
2016-11-16T08:09:49.000Z
2021-08-12T06:38:09.000Z
broker/src/ave/broker/resource.py
yiu31802/ave
e46fc357f9464d5beaf42568a74bb95e6b1b8037
[ "BSD-3-Clause" ]
null
null
null
broker/src/ave/broker/resource.py
yiu31802/ave
e46fc357f9464d5beaf42568a74bb95e6b1b8037
[ "BSD-3-Clause" ]
12
2016-11-20T15:34:03.000Z
2020-08-04T00:26:11.000Z
# Copyright (C) 2013 Sony Mobile Communications AB. # All rights, including trade secret rights, reserved.
37.407407
69
0.676238
# Copyright (C) 2013 Sony Mobile Communications AB. # All rights, including trade secret rights, reserved. from ave.broker.session import RemoteSession class RemoteWorkspace(RemoteSession): def __init__(self, address, authkey, profile): if not profile['type'] == 'workspace': raise Exception('...
0
0
0
1,706
0
0
0
23
184
322d586f934f92e70aa2df7d8cd7b0ee18656cda
244
py
Python
Q5.py
BoffinZhang/Files-for-Summer-School
43ebe8ff7c7f8287b6cf80466d1a52633d1f9831
[ "MIT" ]
null
null
null
Q5.py
BoffinZhang/Files-for-Summer-School
43ebe8ff7c7f8287b6cf80466d1a52633d1f9831
[ "MIT" ]
null
null
null
Q5.py
BoffinZhang/Files-for-Summer-School
43ebe8ff7c7f8287b6cf80466d1a52633d1f9831
[ "MIT" ]
null
null
null
# Add zip code import pymongo myclient = pymongo.MongoClient("mongodb://localhost:27017/") mydb = myclient["mydatabase"] mycol = mydb["restaurant"] myquery = {"borough":{"$regex":"Bronx"}} for x in mycol.find(myquery): print(x)
22.181818
61
0.668033
# Add zip code import pymongo myclient = pymongo.MongoClient("mongodb://localhost:27017/") mydb = myclient["mydatabase"] mycol = mydb["restaurant"] myquery = {"borough":{"$regex":"Bronx"}} for x in mycol.find(myquery): print(x)
0
0
0
0
0
0
0
0
0
d2180f20dde51c9f90b616cceaa687af3eafce6f
2,133
py
Python
backend/publish-simulator.py
jpmens/zabbix-owntracks-lld
f0a456745604da2c4f90c4e5e9b7b37da7b766e5
[ "MIT" ]
null
null
null
backend/publish-simulator.py
jpmens/zabbix-owntracks-lld
f0a456745604da2c4f90c4e5e9b7b37da7b766e5
[ "MIT" ]
null
null
null
backend/publish-simulator.py
jpmens/zabbix-owntracks-lld
f0a456745604da2c4f90c4e5e9b7b37da7b766e5
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 -B import paho.mqtt.publish as mqtt # pip install --upgrade paho-mqtt import json from collections import namedtuple import time import random import base64 import os Loc = namedtuple('Loc', 'imei lat lon alt vel cog plate tid') positions = [ Loc("516081298750081", 59.373399, 17.946690, ...
27.701299
84
0.508673
#!/usr/bin/env python3 -B import paho.mqtt.publish as mqtt # pip install --upgrade paho-mqtt import json from collections import namedtuple import time import random import base64 import os Loc = namedtuple('Loc', 'imei lat lon alt vel cog plate tid') positions = [ Loc("516081298750081", 59.373399, 17.946690, ...
0
0
0
0
0
0
0
0
0
029b5ad7aa1bc0f1f2748b4db33453d89c1639d8
1,632
py
Python
var/spack/repos/builtin/packages/julea/package.py
carlabguillen/spack
7070bb892f9bdb5cf9e76e0eecd64f6cc5f4695c
[ "ECL-2.0", "Apache-2.0", "MIT-0", "MIT" ]
1
2020-05-24T15:23:12.000Z
2020-05-24T15:23:12.000Z
var/spack/repos/builtin/packages/julea/package.py
carlabguillen/spack
7070bb892f9bdb5cf9e76e0eecd64f6cc5f4695c
[ "ECL-2.0", "Apache-2.0", "MIT-0", "MIT" ]
6
2022-02-26T11:44:34.000Z
2022-03-12T12:14:50.000Z
var/spack/repos/builtin/packages/julea/package.py
carlabguillen/spack
7070bb892f9bdb5cf9e76e0eecd64f6cc5f4695c
[ "ECL-2.0", "Apache-2.0", "MIT-0", "MIT" ]
1
2019-10-29T09:08:17.000Z
2019-10-29T09:08:17.000Z
# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT)
37.953488
75
0.700368
# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) from spack import * class Julea(MesonPackage): """JULEA is a flexible storage framework that allows offering arbitra...
0
0
0
1,390
0
0
0
-2
46
9c502410375e710cc49e0805e11f9a804dc41ebb
511
py
Python
app/models/images.py
FabioCassimiro/API-FacialRecognition
16b7ffb9a668ca9056daa86b85b05862b272b9a9
[ "MIT" ]
null
null
null
app/models/images.py
FabioCassimiro/API-FacialRecognition
16b7ffb9a668ca9056daa86b85b05862b272b9a9
[ "MIT" ]
null
null
null
app/models/images.py
FabioCassimiro/API-FacialRecognition
16b7ffb9a668ca9056daa86b85b05862b272b9a9
[ "MIT" ]
1
2020-11-07T23:44:06.000Z
2020-11-07T23:44:06.000Z
# converte os bytes em imagem e salva no path especificado # remove o cabealho do base64 enviado na requisio pelo JS
34.066667
65
0.731898
import base64 def image(byte_image, path_image): convert_to_image(adjust_bytes(byte_image),path_image) # converte os bytes em imagem e salva no path especificado def convert_to_image(byte_image,path_image='"./face/image.jpeg'): with open(path_image,'wb') as image: image.write(base64.b64decode(by...
6
0
0
0
0
295
0
-8
89
585a62862768c57591c5253322a5d7f7cc30eff0
6,972
py
Python
conductor/conductor/common/rest.py
aalsudais/optf-has
c3e070b6ebc713a571c10d7a5cd87e5053047136
[ "Apache-2.0" ]
null
null
null
conductor/conductor/common/rest.py
aalsudais/optf-has
c3e070b6ebc713a571c10d7a5cd87e5053047136
[ "Apache-2.0" ]
null
null
null
conductor/conductor/common/rest.py
aalsudais/optf-has
c3e070b6ebc713a571c10d7a5cd87e5053047136
[ "Apache-2.0" ]
null
null
null
# # ------------------------------------------------------------------------- # Copyright (c) 2015-2017 AT&T Intellectual Property # # 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 # # ...
38.949721
138
0.595382
# # ------------------------------------------------------------------------- # Copyright (c) 2015-2017 AT&T Intellectual Property # # 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 # # ...
0
0
0
5,768
0
0
0
27
274
2cff7ca1e7f35bf4321272f734cc7d4f03541065
1,023
py
Python
pipeline/utils/task_utils.py
enterstudio/artman
b9b2e6c0d42a0698b6ee59f4e755e7f2e603f8aa
[ "Apache-2.0" ]
2
2019-11-30T23:42:09.000Z
2021-08-30T19:54:48.000Z
pipeline/utils/task_utils.py
enterstudio/artman
b9b2e6c0d42a0698b6ee59f4e755e7f2e603f8aa
[ "Apache-2.0" ]
null
null
null
pipeline/utils/task_utils.py
enterstudio/artman
b9b2e6c0d42a0698b6ee59f4e755e7f2e603f8aa
[ "Apache-2.0" ]
1
2017-03-30T00:28:15.000Z
2017-03-30T00:28:15.000Z
# Copyright 2016 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agree...
34.1
74
0.718475
# Copyright 2016 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agree...
0
0
0
0
0
346
0
-4
46
0be7b0c2cb7839914cc971ec6aec845982497db2
406
py
Python
examples/file_manager/suds_client.py
infoxchange/spyne
60ed622b088c13f4f84c81f1f43302edbc7f6027
[ "BSD-3-Clause" ]
786
2015-01-04T10:46:28.000Z
2022-03-31T19:24:35.000Z
examples/file_manager/suds_client.py
infoxchange/spyne
60ed622b088c13f4f84c81f1f43302edbc7f6027
[ "BSD-3-Clause" ]
248
2015-01-01T21:52:47.000Z
2022-03-09T08:55:04.000Z
examples/file_manager/suds_client.py
infoxchange/spyne
60ed622b088c13f4f84c81f1f43302edbc7f6027
[ "BSD-3-Clause" ]
210
2015-01-10T14:20:31.000Z
2022-03-09T08:38:43.000Z
#!/usr/bin/env python from suds.client import Client import base64 # Suds does not support base64binary type, so we do the encoding manually. file_data = base64.b64encode('file_data') c=Client('http://localhost:9000/filemgr/?wsdl') c.service.add('x', 'y', 'file_name', file_data) print('file written.') print() prin...
22.555556
74
0.738916
#!/usr/bin/env python from suds.client import Client import base64 # Suds does not support base64binary type, so we do the encoding manually. file_data = base64.b64encode('file_data') c=Client('http://localhost:9000/filemgr/?wsdl') c.service.add('x', 'y', 'file_name', file_data) print('file written.') print() prin...
0
0
0
0
0
0
0
0
0
c2c459171d9b2ef000ef3bcfb30b6970bec36cb1
1,609
py
Python
LoopStructural/analysis/_fault_intersection.py
wgorczyk/LoopStructural
bedc7abd4c1868fdbd6ed659c8d72ef19f793875
[ "MIT" ]
null
null
null
LoopStructural/analysis/_fault_intersection.py
wgorczyk/LoopStructural
bedc7abd4c1868fdbd6ed659c8d72ef19f793875
[ "MIT" ]
null
null
null
LoopStructural/analysis/_fault_intersection.py
wgorczyk/LoopStructural
bedc7abd4c1868fdbd6ed659c8d72ef19f793875
[ "MIT" ]
null
null
null
from LoopStructural.utils import getLogger logger = getLogger(__name__)
35.755556
90
0.556246
from skimage.measure import marching_cubes import pandas as pd import numpy as np from LoopStructural.utils import getLogger logger = getLogger(__name__) def calculate_fault_intersections(model): fault_names = [] for f in model.features: if f.type == 'fault': fault_names.append(f.name) ...
0
0
0
0
0
1,432
0
16
89
d8093f41c8c35c15b5fb26fa79a3e71366424290
3,041
py
Python
class_05.py
Pallavidighe2/python_201901
48696f34df9747edbecf2551c07aefab5078d664
[ "MIT" ]
null
null
null
class_05.py
Pallavidighe2/python_201901
48696f34df9747edbecf2551c07aefab5078d664
[ "MIT" ]
null
null
null
class_05.py
Pallavidighe2/python_201901
48696f34df9747edbecf2551c07aefab5078d664
[ "MIT" ]
1
2019-02-02T07:48:59.000Z
2019-02-02T07:48:59.000Z
""" 1 comprehension 2 user defined function # ASSIGNMENT: 1 WRITE list comprehension to create 15 random number 2 write list comprehensioon to create prime number till user defined number 3 write dictionary comprehension with 5 key value paiir 4 convert all assignmnent into user defined function """ ### COMPREHENS...
18.656442
122
0.628412
""" 1 comprehension 2 user defined function # ASSIGNMENT: 1 WRITE list comprehension to create 15 random number 2 write list comprehensioon to create prime number till user defined number 3 write dictionary comprehension with 5 key value paiir 4 convert all assignmnent into user defined function """ ### COMPREHENS...
0
0
0
0
0
76
0
0
46
fb2fd19d087f08ddfe4ef3e22ce9e7064203ecb4
613
py
Python
test/test_version_cmd.py
PunicaSuite/punica-python
dfcd50de4452454b96d0c252c2db994e3bad38c0
[ "MIT" ]
6
2018-11-01T23:39:32.000Z
2020-03-25T13:39:46.000Z
test/test_version_cmd.py
PunicaSuite/punica-python
dfcd50de4452454b96d0c252c2db994e3bad38c0
[ "MIT" ]
3
2018-10-26T12:53:16.000Z
2019-06-21T13:22:56.000Z
test/test_version_cmd.py
PunicaSuite/punica-python
dfcd50de4452454b96d0c252c2db994e3bad38c0
[ "MIT" ]
7
2018-10-11T07:03:10.000Z
2019-06-26T02:38:58.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import unittest if __name__ == '__main__': unittest.main()
21.892857
55
0.660685
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import unittest from punica.cli import main from click.testing import CliRunner class TestVersion(unittest.TestCase): def setUp(self): self.runner = CliRunner() def check_result(self, result): self.assertEqual(0, result.exit_code) self...
0
0
0
410
0
0
0
20
69
d902ef78f16854eb35693929ba0cdee382700b8d
318
py
Python
examples/run_intent.py
whksmo/deep-intent
2617373cf94fccbe9fc37d50ee010a5c2b8418b0
[ "MIT" ]
null
null
null
examples/run_intent.py
whksmo/deep-intent
2617373cf94fccbe9fc37d50ee010a5c2b8418b0
[ "MIT" ]
7
2019-12-16T22:03:26.000Z
2022-02-10T00:17:03.000Z
examples/run_intent.py
whksmo/deep-intent
2617373cf94fccbe9fc37d50ee010a5c2b8418b0
[ "MIT" ]
null
null
null
model = dm.DSCN(task=6723) model.compile("adam", "sparse_categorical_crossentropy", metrics=['accuracy']) print('start training...') history = model.fit(train_model_input, data[target].values, batch_size=256, epochs=20, verbose=2, validation_data=(test_model_input, test_data[target].values)) model.save('./dscn.h5')
45.428571
159
0.764151
model = dm.DSCN(task=6723) model.compile("adam", "sparse_categorical_crossentropy", metrics=['accuracy']) print('start training...') history = model.fit(train_model_input, data[target].values, batch_size=256, epochs=20, verbose=2, validation_data=(test_model_input, test_data[target].values)) model.save('./dscn.h5')
0
0
0
0
0
0
0
0
0
1751ba4092f07008ee12697a031ae468288af2c1
444
py
Python
connect_mssql.py
gventuraagramonte/python-connect-with-mssql-from-ubuntu
85d74d956de4b824721027a3ed9eeb6f2d12b3cc
[ "MIT" ]
null
null
null
connect_mssql.py
gventuraagramonte/python-connect-with-mssql-from-ubuntu
85d74d956de4b824721027a3ed9eeb6f2d12b3cc
[ "MIT" ]
null
null
null
connect_mssql.py
gventuraagramonte/python-connect-with-mssql-from-ubuntu
85d74d956de4b824721027a3ed9eeb6f2d12b3cc
[ "MIT" ]
null
null
null
import pyodbc server = 'localhost' database = 'testDB' username = 'SA' password = 'giorgio$1' cnxn = pyodbc.connect('DRIVER={ODBC Driver 17 for SQL Server};SERVER='+server+';DATABASE='+database+';UID='+username+';PWD='+ password) cursor = cnxn.cursor() print('Inserting a new row into table') tsql = "INSERT INTO Empl...
29.6
135
0.704955
import pyodbc server = 'localhost' database = 'testDB' username = 'SA' password = 'giorgio$1' cnxn = pyodbc.connect('DRIVER={ODBC Driver 17 for SQL Server};SERVER='+server+';DATABASE='+database+';UID='+username+';PWD='+ password) cursor = cnxn.cursor() print('Inserting a new row into table') tsql = "INSERT INTO Empl...
0
0
0
0
0
0
0
0
0
1d99c6fff28687e1343c252d347b468d4e49a849
6,995
py
Python
permuted_sequential_mnist/tf_permuted_mnist_lstm_rcst.py
201528014227051/ARNet
e7779d6af1a8990712d8e8e4a72e4c1ed138f60e
[ "MIT" ]
9
2018-07-11T11:34:09.000Z
2021-11-21T15:37:18.000Z
permuted_sequential_mnist/tf_permuted_mnist_lstm_rcst.py
201528014227051/ARNet
e7779d6af1a8990712d8e8e4a72e4c1ed138f60e
[ "MIT" ]
null
null
null
permuted_sequential_mnist/tf_permuted_mnist_lstm_rcst.py
201528014227051/ARNet
e7779d6af1a8990712d8e8e4a72e4c1ed138f60e
[ "MIT" ]
2
2018-10-19T03:57:51.000Z
2018-12-01T17:13:36.000Z
#! encoding: UTF-8 import os import opts from six.moves import cPickle if __name__ == '__main__': opt = opts.parse_opt() opt_dict = vars(opt) for k, v in opt_dict.items(): print(k + ': \t' + str(v)) with open('permuted_mnist_110.pkl', 'rb') as f: permuted_mnist = cPickle.load(f) ...
39.744318
139
0.639314
#! encoding: UTF-8 import os import opts import ipdb import time import random import numpy as np from six.moves import cPickle import keras from keras.datasets import mnist import tensorflow as tf class LSTM(): def __init__(self, opt): self.lstm_step = opt.lstm_step self.batch_size = opt.batch_...
36
0
0
2,311
0
3,801
0
-27
201
608f96ac7a63f382be1cfbe5dc84f36a2e3f47b0
43,726
py
Python
utils/env/tools/scripts/cmds/cmd_package.py
msrLi/targe_ejdStm32F407
65e462f98bd299c42b2c2f42d58a22135d6c27de
[ "Apache-2.0" ]
null
null
null
utils/env/tools/scripts/cmds/cmd_package.py
msrLi/targe_ejdStm32F407
65e462f98bd299c42b2c2f42d58a22135d6c27de
[ "Apache-2.0" ]
null
null
null
utils/env/tools/scripts/cmds/cmd_package.py
msrLi/targe_ejdStm32F407
65e462f98bd299c42b2c2f42d58a22135d6c27de
[ "Apache-2.0" ]
null
null
null
# -*- coding:utf-8 -*- # # File : cmd_package.py # This file is part of RT-Thread RTOS # COPYRIGHT (C) 2006 - 2018, RT-Thread Development Team # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Softwa...
38.42355
230
0.590976
# -*- coding:utf-8 -*- # # File : cmd_package.py # This file is part of RT-Thread RTOS # COPYRIGHT (C) 2006 - 2018, RT-Thread Development Team # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Softwa...
426
0
0
0
0
5,240
0
0
200
53750f2285a1bcd26140297e9d44271d2a64462b
255
py
Python
Curso_de_Python/Mundo_01/Aula_08/Aula/aula08b.py
tarcisioribeiro/Python
69b8fee218a6c9b93ae7a6ea36eb903d5ac36955
[ "MIT" ]
null
null
null
Curso_de_Python/Mundo_01/Aula_08/Aula/aula08b.py
tarcisioribeiro/Python
69b8fee218a6c9b93ae7a6ea36eb903d5ac36955
[ "MIT" ]
null
null
null
Curso_de_Python/Mundo_01/Aula_08/Aula/aula08b.py
tarcisioribeiro/Python
69b8fee218a6c9b93ae7a6ea36eb903d5ac36955
[ "MIT" ]
null
null
null
# Corrigido # Bloco de importaes import random # Bloco de entrada print() n = int(input('Informe um nmero maior que zero: ')) print() # Bloco de clculos num = random.randint(0, n) # Bloco de sada print('Numro de sada: {}.'.format(num)) print()
15
52
0.690196
# Corrigido # Bloco de importações import random # Bloco de entrada print() n = int(input('Informe um número maior que zero: ')) print() # Bloco de cálculos num = random.randint(0, n) # Bloco de saída print('Numéro de saída: {}.'.format(num)) print()
14
0
0
0
0
0
0
0
0
f6320902b7466c2c80a03e97cf19b3b44f2d06c0
2,500
py
Python
scielomanager/scielomanager/urls.py
jamilatta/scielo-manager
d506c6828ba9b1089faa164bc42ba29a0f228e61
[ "BSD-2-Clause" ]
null
null
null
scielomanager/scielomanager/urls.py
jamilatta/scielo-manager
d506c6828ba9b1089faa164bc42ba29a0f228e61
[ "BSD-2-Clause" ]
null
null
null
scielomanager/scielomanager/urls.py
jamilatta/scielo-manager
d506c6828ba9b1089faa164bc42ba29a0f228e61
[ "BSD-2-Clause" ]
null
null
null
# -*- encoding: utf-8 -*- from django.contrib import admin from django.conf import settings from tastypie.api import Api from journalmanager import views, models from api import resources admin.autodiscover() # RESTful API config v1_api = Api(api_name='v1') v1_api_resources = [ resources.JournalResource(), r...
31.25
105
0.6764
# -*- encoding: utf-8 -*- from django.conf.urls.defaults import * from django.contrib import admin from django.conf import settings from tastypie.api import Api from journalmanager import views, models from api import resources admin.autodiscover() # RESTful API config v1_api = Api(api_name='v1') v1_api_resources = ...
0
0
0
0
0
0
0
18
22
88f379d6a1015c60b323a42fb79bebb3410e21fd
4,185
py
Python
examples/mri/p_mri_non_cartesian_reconstruction.py
starcksophie/pysap
c50b128039a54b6b26dcc3c7bd13fda304b8388c
[ "CECILL-B" ]
null
null
null
examples/mri/p_mri_non_cartesian_reconstruction.py
starcksophie/pysap
c50b128039a54b6b26dcc3c7bd13fda304b8388c
[ "CECILL-B" ]
null
null
null
examples/mri/p_mri_non_cartesian_reconstruction.py
starcksophie/pysap
c50b128039a54b6b26dcc3c7bd13fda304b8388c
[ "CECILL-B" ]
null
null
null
""" Neuroimaging cartesian reconstruction ===================================== Credit: L Elgueddari In this tutorial we will reconstruct an MRI image from the sparse kspace measurments. """ # Package import import pysap from pysap.data import get_sample_data from mri.numerics.linear import Wavelet2 from mri.numeric...
31.466165
78
0.669534
""" Neuroimaging cartesian reconstruction ===================================== Credit: L Elgueddari In this tutorial we will reconstruct an MRI image from the sparse kspace measurments. """ # Package import import pysap from pysap.data import get_sample_data from mri.numerics.linear import Wavelet2 from mri.numeric...
0
0
0
0
0
0
0
5
0
d3ecaa81e69157b4941a47504e3fa553b9731f4a
67
py
Python
webpie/Version.py
imandr/webpie
ee86d0230e5a1c102c2169d95d681292eb022c40
[ "BSD-3-Clause" ]
null
null
null
webpie/Version.py
imandr/webpie
ee86d0230e5a1c102c2169d95d681292eb022c40
[ "BSD-3-Clause" ]
null
null
null
webpie/Version.py
imandr/webpie
ee86d0230e5a1c102c2169d95d681292eb022c40
[ "BSD-3-Clause" ]
null
null
null
Version = "4.5.2" if __name__ == "__main__": print (Version)
11.166667
26
0.597015
Version = "4.5.2" if __name__ == "__main__": print (Version)
0
0
0
0
0
0
0
0
0
dc0f1b2715779a89523968c8d6a94839e2ea3d90
3,277
py
Python
guardian/models.py
auvipy/django-guardian
19884c24b7a51a359e9b52dbfa9f5d72df03558c
[ "MIT" ]
2
2020-05-28T03:45:09.000Z
2020-08-10T10:27:46.000Z
guardian/models.py
auvipy/django-guardian
19884c24b7a51a359e9b52dbfa9f5d72df03558c
[ "MIT" ]
7
2020-06-06T01:06:19.000Z
2022-02-10T11:15:14.000Z
guardian/models.py
auvipy/django-guardian
19884c24b7a51a359e9b52dbfa9f5d72df03558c
[ "MIT" ]
1
2019-09-10T11:14:04.000Z
2019-09-10T11:14:04.000Z
from django.contrib.auth.models import Group setattr(Group, 'add_obj_perm', lambda self, perm, obj: GroupObjectPermission.objects.assign_perm(perm, self, obj)) setattr(Group, 'del_obj_perm', lambda self, perm, obj: GroupObjectPermission.objects.remove_perm(perm, self, obj))
36.010989
96
0.712237
from django.contrib.auth.models import Group, Permission from django.contrib.contenttypes.fields import GenericForeignKey from django.contrib.contenttypes.models import ContentType from django.core.exceptions import ValidationError from django.db import models from django.utils.translation import ugettext_lazy as _ fro...
0
0
0
2,390
0
0
0
274
314
7b961d390f09a4e9d6d2f625b1bd5f3b5a16bab8
149
py
Python
test_usercrawler.py
coolspiderghy/sina_weibo_crawler
950c1c3f6d3a6a955f1c305993ef67f559bab7b6
[ "Apache-2.0" ]
4
2016-03-26T14:01:01.000Z
2019-08-22T12:17:16.000Z
test_usercrawler.py
coolspiderghy/weibo_scrawler_app
950c1c3f6d3a6a955f1c305993ef67f559bab7b6
[ "Apache-2.0" ]
null
null
null
test_usercrawler.py
coolspiderghy/weibo_scrawler_app
950c1c3f6d3a6a955f1c305993ef67f559bab7b6
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- from usercrawler import UserCrawler uid = u'0423' crawler = UserCrawler() userinfo = crawler.scratch(uid) print userinfo
24.833333
35
0.744966
# -*- coding: utf-8 -*- from usercrawler import UserCrawler uid = u'小鱼游啊游0423' crawler = UserCrawler() userinfo = crawler.scratch(uid) print userinfo
15
0
0
0
0
0
0
0
0
83e95b878465aca88217865c0760fb25dfe65b9b
3,860
py
Python
utils/gan_utils.py
AlexKbit/draw-ai
1d5941587aa0503b649fd0ff22820e9a2e163645
[ "Apache-2.0" ]
3
2020-06-02T09:19:20.000Z
2020-09-26T09:15:24.000Z
utils/gan_utils.py
AlexKbit/draw-ai
1d5941587aa0503b649fd0ff22820e9a2e163645
[ "Apache-2.0" ]
7
2020-11-13T19:03:43.000Z
2022-03-12T00:46:09.000Z
utils/gan_utils.py
AlexKbit/draw-ai
1d5941587aa0503b649fd0ff22820e9a2e163645
[ "Apache-2.0" ]
2
2020-08-18T16:00:52.000Z
2020-11-27T16:36:36.000Z
from tensorflow.keras import layers import tensorflow as tf def make_generator_model(): ''' Create GAN generator :return: Generator ''' model = tf.keras.Sequential() model.add(layers.Dense(7*7*256, use_bias=False, input_shape=(100,))) model.add(layers.BatchNormalization()) model.add(l...
35.412844
115
0.709067
from tensorflow.keras import layers import time import tensorflow as tf def make_generator_model(): ''' Create GAN generator :return: Generator ''' model = tf.keras.Sequential() model.add(layers.Dense(7*7*256, use_bias=False, input_shape=(100,))) model.add(layers.BatchNormalization()) ...
0
988
0
0
0
705
0
-10
91
90f65af61cebb27179023fa75caf415afdf62972
2,908
py
Python
slack_bolt/middleware/authorization/internals.py
korymath/bolt-python
67e0286d756ba92510315d044303f43b03380b52
[ "MIT" ]
null
null
null
slack_bolt/middleware/authorization/internals.py
korymath/bolt-python
67e0286d756ba92510315d044303f43b03380b52
[ "MIT" ]
null
null
null
slack_bolt/middleware/authorization/internals.py
korymath/bolt-python
67e0286d756ba92510315d044303f43b03380b52
[ "MIT" ]
null
null
null
# # NOTE: this source file intentionally avoids having a reference to # AsyncBoltRequest, AsyncSlackResponse, and whatever Async-prefixed. # # The reason why we do so is to enable developers use sync version of Bolt # without installing aiohttp library (or any others we may use for async things) #
34.619048
104
0.70564
from typing import Optional, Union from slack_sdk.web import SlackResponse from slack_bolt.authorization import AuthorizeResult from slack_bolt.request.request import BoltRequest from slack_bolt.response import BoltResponse # # NOTE: this source file intentionally avoids having a reference to # AsyncBoltRequest, Asy...
0
0
0
0
0
2,166
0
114
319
f862d0e1c346f9e7a2364127a4beb70a9a983d12
431
py
Python
celeryconfig.py
langzeyu/book-crawler
e2d96648384658c7775bd02d94eab086c9ece677
[ "MIT" ]
5
2019-04-02T05:00:03.000Z
2021-04-21T11:03:50.000Z
celeryconfig.py
langzeyu/book-crawler
e2d96648384658c7775bd02d94eab086c9ece677
[ "MIT" ]
null
null
null
celeryconfig.py
langzeyu/book-crawler
e2d96648384658c7775bd02d94eab086c9ece677
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding:utf-8 -*- BROKER_BACKEND = "mongodb" BROKER_HOST = "localhost" BROKER_PORT = 7680 CELERY_RESULT_BACKEND = "mongodb" CELERY_MONGODB_BACKEND_SETTINGS = { "host": "localhost", "port": 7680, "database": "books", "taskmeta_collection": "celerytasks", } CELERYD_CONCURRENC...
19.590909
41
0.693735
#!/usr/bin/env python # -*- coding:utf-8 -*- BROKER_BACKEND = "mongodb" BROKER_HOST = "localhost" BROKER_PORT = 7680 CELERY_RESULT_BACKEND = "mongodb" CELERY_MONGODB_BACKEND_SETTINGS = { "host": "localhost", "port": 7680, "database": "books", "taskmeta_collection": "celerytasks", } CELERYD_CONCURRENC...
0
0
0
0
0
0
0
0
0
98a98aa43e09c8a83d94f802833ebc081dbed6d0
14,331
py
Python
packages/fetchai/protocols/http/http_pb2.py
ejfitzgerald/agents-aea
6411fcba8af2cdf55a3005939ae8129df92e8c3e
[ "Apache-2.0" ]
null
null
null
packages/fetchai/protocols/http/http_pb2.py
ejfitzgerald/agents-aea
6411fcba8af2cdf55a3005939ae8129df92e8c3e
[ "Apache-2.0" ]
null
null
null
packages/fetchai/protocols/http/http_pb2.py
ejfitzgerald/agents-aea
6411fcba8af2cdf55a3005939ae8129df92e8c3e
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by the protocol buffer compiler. DO NOT EDIT! # source: http.proto from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection from google.protobuf import symbol_database as _symbol_data...
32.79405
964
0.588514
# -*- coding: utf-8 -*- # Generated by the protocol buffer compiler. DO NOT EDIT! # source: http.proto from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection from google.protobuf import symbol_database as _symbol_data...
0
0
0
0
0
0
0
0
0
f9c8cac28b80d2d7a406bcd270bb5066c3caef1d
1,771
py
Python
main.py
j12r12/Premier-League-Red-Cards
31d0f602087e6fd3bccafe4f279d961970de6892
[ "CC0-1.0" ]
1
2021-05-19T10:46:54.000Z
2021-05-19T10:46:54.000Z
main.py
j12r12/Premier-League-Red-Cards
31d0f602087e6fd3bccafe4f279d961970de6892
[ "CC0-1.0" ]
null
null
null
main.py
j12r12/Premier-League-Red-Cards
31d0f602087e6fd3bccafe4f279d961970de6892
[ "CC0-1.0" ]
null
null
null
from function_file import line_graph, normal_curve if __name__ == "__main__": # Create dataframe df2 = pd.read_csv("../input/english-premier-league-data-for-10-seasons/epldat10seasons/epl-allseasons-matchstats.csv") # Create dataframe to summarise cards given by season and create...
40.25
122
0.690006
from function_file import best_fit, line_graph, normal_curve if __name__ == "__main__": # Create dataframe df2 = pd.read_csv("../input/english-premier-league-data-for-10-seasons/epldat10seasons/epl-allseasons-matchstats.csv") # Create dataframe to summarise cards given by season ...
0
0
0
0
0
0
0
10
0
a78fccdaa80b9805f870c6926eb82a75851b19c0
1,617
py
Python
privex/helpers/setuppy/__init__.py
Privex/python-helpers
1c976ce5b0e2c5241ea0bdf330bd6701b5e31153
[ "X11" ]
12
2019-06-18T11:17:41.000Z
2021-09-13T23:00:21.000Z
privex/helpers/setuppy/__init__.py
Privex/python-helpers
1c976ce5b0e2c5241ea0bdf330bd6701b5e31153
[ "X11" ]
1
2019-10-13T07:34:44.000Z
2019-10-13T07:34:44.000Z
privex/helpers/setuppy/__init__.py
Privex/python-helpers
1c976ce5b0e2c5241ea0bdf330bd6701b5e31153
[ "X11" ]
4
2019-10-10T10:15:09.000Z
2021-05-16T01:55:48.000Z
""" Helpers for setup.py, e.g. requirements.txt parsing, version bumping, custom setup.py commands Inside of :py:mod:`privex.helpers.setuppy.common` there's a variety of functions related to generating requirements.txt files, parsing requirements.txt files which recursively import other requirements.txt files, and ha...
47.558824
119
0.769944
""" Helpers for setup.py, e.g. requirements.txt parsing, version bumping, custom setup.py commands Inside of :py:mod:`privex.helpers.setuppy.common` there's a variety of functions related to generating requirements.txt files, parsing requirements.txt files which recursively import other requirements.txt files, and ha...
0
0
0
0
0
0
0
66
78
083abf4fa2fc9f0cc4b24322867f2871a7ac1d31
3,577
py
Python
Lib/site-packages/celerid/support.py
raychorn/svn_Python-2.5.1
425005b1b489ba44ec0bb989e077297e8953d9be
[ "PSF-2.0" ]
null
null
null
Lib/site-packages/celerid/support.py
raychorn/svn_Python-2.5.1
425005b1b489ba44ec0bb989e077297e8953d9be
[ "PSF-2.0" ]
null
null
null
Lib/site-packages/celerid/support.py
raychorn/svn_Python-2.5.1
425005b1b489ba44ec0bb989e077297e8953d9be
[ "PSF-2.0" ]
null
null
null
__all__ = ('setup', 'Extension') from distutils.core import setup
44.160494
88
0.592116
__all__ = ('setup', 'Extension') from celerid import patch_distutils # Cause distutils to be hot-patched. from distutils.core import setup, Extension as std_Extension from distutils.errors import DistutilsOptionError class Extension(std_Extension): def __init__(self, *args, **kwargs): if 'define_macros' ...
0
0
0
3,334
0
0
0
70
105
13c050bbf547cc4ea9f0e89f90983ca56124279a
30,448
py
Python
databricks/koalas/tests/test_groupby.py
WeichenXu123/koalas
224cbe4a1c7a2b12976069762379d0e77e46750b
[ "Apache-2.0" ]
null
null
null
databricks/koalas/tests/test_groupby.py
WeichenXu123/koalas
224cbe4a1c7a2b12976069762379d0e77e46750b
[ "Apache-2.0" ]
null
null
null
databricks/koalas/tests/test_groupby.py
WeichenXu123/koalas
224cbe4a1c7a2b12976069762379d0e77e46750b
[ "Apache-2.0" ]
null
null
null
# # Copyright (C) 2019 Databricks, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to i...
55.562044
100
0.493727
# # Copyright (C) 2019 Databricks, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to i...
0
0
0
29,404
0
0
0
254
201
ab538b22cb0660b172d6a23870426c8e7981ab71
27,245
py
Python
short-read-mngs/idseq-dag/idseq_dag/steps/run_alignment.py
chanzuckerberg/idseq-workflows
b1e7c91e5d9f0d9a05f97f240211fcc16d33225b
[ "MIT" ]
30
2020-05-23T21:23:38.000Z
2022-03-24T17:18:47.000Z
short-read-mngs/idseq-dag/idseq_dag/steps/run_alignment.py
grunwaldlab/idseq-workflows
cacfaa02f014ba06b8fb69e62911ab7fd5d88d9a
[ "MIT" ]
65
2020-05-27T14:21:26.000Z
2021-11-18T17:58:56.000Z
short-read-mngs/idseq-dag/idseq_dag/steps/run_alignment.py
chanzuckerberg/czid-workflows
916a4feb195bbf37157ec224f3ffc9d3e6d3ea04
[ "MIT" ]
12
2020-08-24T12:00:28.000Z
2022-02-03T08:28:02.000Z
from urllib.parse import urlparse from botocore.exceptions import ClientError import idseq_dag.util.command as command import idseq_dag.util.command_patterns as command_patterns import idseq_dag.util.count as count import idseq_dag.util.log as log import idseq_dag.util.m8 as m8 MAX_CHUNKS_IN_FLIGHT = 16 CHUNK_MAX_ATTE...
42.24031
157
0.594311
import multiprocessing import os import random import shutil import threading import time import traceback import json import re import tempfile from subprocess import run, PIPE from urllib.parse import urlparse from botocore.exceptions import ClientError import boto3 import requests from idseq_dag.engine.pipeline_st...
0
2,357
0
22,970
0
284
0
124
491
92195b036a039f3bef566528fe4dc52bd33884d1
3,976
py
Python
cflearn/modules/extractors/rnn/custom.py
SaizhuoWang/carefree-learn
3bf7b00286cdef556cc00fa2fcba5c390b5b9d20
[ "MIT" ]
null
null
null
cflearn/modules/extractors/rnn/custom.py
SaizhuoWang/carefree-learn
3bf7b00286cdef556cc00fa2fcba5c390b5b9d20
[ "MIT" ]
null
null
null
cflearn/modules/extractors/rnn/custom.py
SaizhuoWang/carefree-learn
3bf7b00286cdef556cc00fa2fcba5c390b5b9d20
[ "MIT" ]
null
null
null
import torch import torch.nn as nn import torch.jit as jit from typing import Tuple from collections import namedtuple state_type = Tuple[torch.Tensor, torch.Tensor] return_type = Tuple[torch.Tensor, Tuple[torch.Tensor, torch.Tensor]] LSTMState = namedtuple("LSTMState", ["hx", "cx"]) __all__ = [ "LSTM", ]
30.121212
80
0.594819
import torch import torch.nn as nn import torch.jit as jit from typing import Any from typing import List from typing import Tuple from typing import Optional from collections import namedtuple state_type = Tuple[torch.Tensor, torch.Tensor] return_type = Tuple[torch.Tensor, Tuple[torch.Tensor, torch.Tensor]] LSTMSta...
0
1,578
0
1,935
0
0
0
9
136
fec833942e263f2974eed59513e2ad64d7927cdc
34,938
py
Python
WNBA/main.py
rafaelgreca/Web-Scraping-Projects
a273bd1ecd48e66887730f69761c8bf5ae84077a
[ "MIT" ]
null
null
null
WNBA/main.py
rafaelgreca/Web-Scraping-Projects
a273bd1ecd48e66887730f69761c8bf5ae84077a
[ "MIT" ]
null
null
null
WNBA/main.py
rafaelgreca/Web-Scraping-Projects
a273bd1ecd48e66887730f69761c8bf5ae84077a
[ "MIT" ]
null
null
null
if __name__ == "__main__": wrapper = WNBAWrapper() wrapper.getBoxScore()
74.974249
466
0.437432
import requests from bs4 import BeautifulSoup from _datetime import date import progressbar import time import os import pandas as pd class WNBAWrapper: def __init__(self): self.url = 'https://www.basketball-reference.com' self.full_url = '' self.folder_location = os.getcwd() + '/Data/' ...
0
0
0
34,700
0
0
0
-20
177
7ad8587f6b0dee0fab2978c5b885c60af77e3a69
1,025
py
Python
chapter2/code/subprocess/PingScanNetWork.py
abbbhucho/Mastering-Python-for-Networking-and-Security
f4fb1131253e9daad8da501c297758fdcedfbac3
[ "MIT" ]
98
2018-05-13T20:41:43.000Z
2022-03-31T00:24:01.000Z
chapter2/code/subprocess/PingScanNetWork.py
Cyb3rid10ts/Mastering-Python-for-Networking-and-Security
4cf04d1758f17ae378b5e3422404e5b7a174a243
[ "MIT" ]
null
null
null
chapter2/code/subprocess/PingScanNetWork.py
Cyb3rid10ts/Mastering-Python-for-Networking-and-Security
4cf04d1758f17ae378b5e3422404e5b7a174a243
[ "MIT" ]
62
2018-06-19T13:46:34.000Z
2022-02-11T05:47:24.000Z
#!/usr/bin/env python from subprocess import Popen, PIPE import sys import argparse parser = argparse.ArgumentParser(description='Ping Scan Network') # Main arguments parser.add_argument("-network", dest="network", help="NetWork segment[For example 192.168.56]", required=True) parser.add_argument("-machines", des...
37.962963
110
0.720976
#!/usr/bin/env python from subprocess import Popen, PIPE import sys import argparse parser = argparse.ArgumentParser(description='Ping Scan Network') # Main arguments parser.add_argument("-network", dest="network", help="NetWork segment[For example 192.168.56]", required=True) parser.add_argument("-machines", des...
0
0
0
0
0
0
0
0
0
572eaa85b3bcca3c02e23e74b52d981d59fe3faa
648
py
Python
hoofball/models.py
leo-holanda/Hoofball
ccf4399d33a6381acd2ff41efce3dbf0dca6a092
[ "MIT" ]
1
2021-07-30T10:05:43.000Z
2021-07-30T10:05:43.000Z
hoofball/models.py
leo-holanda/Hoofball
ccf4399d33a6381acd2ff41efce3dbf0dca6a092
[ "MIT" ]
null
null
null
hoofball/models.py
leo-holanda/Hoofball
ccf4399d33a6381acd2ff41efce3dbf0dca6a092
[ "MIT" ]
null
null
null
# Create your models here.
34.105263
62
0.746914
from django.db import models from django.utils import timezone # Create your models here. class Player(models.Model): name = models.CharField(max_length=50) gameID = models.IntegerField() age = models.IntegerField() position = models.CharField(max_length=25) wage = models.DecimalField(max_digits=9...
0
0
0
512
0
0
0
19
90
36329d773dc605b92612372d4e43c90065c02c87
3,953
py
Python
bot_module.py
Ygor-J/nucleo_bot
a8d2665211f5fccee73f8b87078155d3b5143bda
[ "MIT" ]
null
null
null
bot_module.py
Ygor-J/nucleo_bot
a8d2665211f5fccee73f8b87078155d3b5143bda
[ "MIT" ]
null
null
null
bot_module.py
Ygor-J/nucleo_bot
a8d2665211f5fccee73f8b87078155d3b5143bda
[ "MIT" ]
1
2021-07-02T22:33:02.000Z
2021-07-02T22:33:02.000Z
from selenium import webdriver from selenium.webdriver.common.by import By from selenium.webdriver.common.keys import Keys from selenium.common.exceptions import ElementNotInteractableException, NoSuchElementException WPP_URL = "https://web.whatsapp.com/" def le_arquivo(nome_arquivo): ''' Funo que l o arquivo...
31.879032
115
0.668353
from selenium import webdriver from selenium.webdriver.common.by import By from selenium.webdriver.common.keys import Keys from selenium.common.exceptions import ElementNotInteractableException, NoSuchElementException import csv import time WPP_URL = "https://web.whatsapp.com/" def le_arquivo(nome_arquivo): ''' ...
38
0
0
0
0
159
0
-21
67
ec546f607153bc3ea6231abc353d158a99494027
508
py
Python
video_to_frame.py
cayl-crypto/video-captioning
a1ec0d72e2279d4700d32ce17d8229865539c537
[ "Apache-2.0" ]
null
null
null
video_to_frame.py
cayl-crypto/video-captioning
a1ec0d72e2279d4700d32ce17d8229865539c537
[ "Apache-2.0" ]
null
null
null
video_to_frame.py
cayl-crypto/video-captioning
a1ec0d72e2279d4700d32ce17d8229865539c537
[ "Apache-2.0" ]
null
null
null
## ADD 'Frames' folder to file path before running code. if __name__ == "__main__": main()
21.166667
86
0.718504
import cv2 import numpy as np import os import math from utils import * ## ADD 'Frames' folder to file path before running code. def Video_to_Frames(): # Run the above function and store its results in a variable. video_path="C:\\Users\\pc\\PycharmProjects\\video-captioning\\YouTubeClips" path_to_save = ...
0
0
0
0
0
290
0
-38
156
f38217a6e6495a1e7c7210e0d457b2cee503f0ed
632
py
Python
Q671.py
Linchin/python_leetcode_git
3d08ab04bbdbd2ce268f33c501fbb149662872c7
[ "MIT" ]
null
null
null
Q671.py
Linchin/python_leetcode_git
3d08ab04bbdbd2ce268f33c501fbb149662872c7
[ "MIT" ]
null
null
null
Q671.py
Linchin/python_leetcode_git
3d08ab04bbdbd2ce268f33c501fbb149662872c7
[ "MIT" ]
null
null
null
""" 671 easy second minimum node in a binary tree """ # Definition for a binary tree node.
19.151515
61
0.547468
""" 671 easy second minimum node in a binary tree """ # Definition for a binary tree node. class TreeNode: def __init__(self, val=0, left=None, right=None): self.val = val self.left = left self.right = right class Solution: def findSecondMinimumValue(self, root: TreeNode) -> int: ...
0
0
0
490
0
0
0
0
45
b0651dfc337865eacfcfe94ab90eb299120875c2
2,726
py
Python
run.py
DiamondBrook/arrhythmia_project
7236d9c3ba0ff4b089111049236c956b45900571
[ "MIT" ]
1
2021-04-01T08:12:21.000Z
2021-04-01T08:12:21.000Z
run.py
DiamondBrook/arrhythmia_project
7236d9c3ba0ff4b089111049236c956b45900571
[ "MIT" ]
12
2020-11-19T00:51:36.000Z
2021-04-27T18:43:50.000Z
run.py
DiamondBrook/arrhythmia_project
7236d9c3ba0ff4b089111049236c956b45900571
[ "MIT" ]
12
2020-10-29T20:05:41.000Z
2021-04-13T18:54:41.000Z
#!/usr/bin/env python3 ################################################################################ # This script will run the Arrythmia Web App from the command line. This # script should be used for developing builds only. ################################################################################ import sub...
35.868421
80
0.644534
#!/usr/bin/env python3 ################################################################################ # This script will run the Arrythmia Web App from the command line. This # script should be used for developing builds only. ################################################################################ import sub...
0
0
0
0
0
0
0
0
0
1dc926fdc95eed08b2ad435012437c145a513a3a
2,990
py
Python
doc/Programs/MassMLP.py
kylegodbey/MachineLearningMSU
a6580d3a61e9b8c332683e5e14ed3bdd7a1ecff0
[ "CC0-1.0" ]
12
2019-04-12T16:51:07.000Z
2021-04-30T00:59:47.000Z
doc/Programs/MassMLP.py
kylegodbey/MachineLearningMSU
a6580d3a61e9b8c332683e5e14ed3bdd7a1ecff0
[ "CC0-1.0" ]
null
null
null
doc/Programs/MassMLP.py
kylegodbey/MachineLearningMSU
a6580d3a61e9b8c332683e5e14ed3bdd7a1ecff0
[ "CC0-1.0" ]
32
2019-04-10T02:31:00.000Z
2019-11-21T03:47:04.000Z
# Regression analysis using scikit-learn functions # Common imports import numpy as np import pandas as pd import matplotlib.pyplot as plt import os # Where to save the figures and data files PROJECT_ROOT_DIR = "Results" FIGURE_ID = "Results/FigureFiles" DATA_ID = "DataFiles/" if not os.path.exists(PROJECT_ROOT_DIR):...
30.20202
88
0.696321
# Regression analysis using scikit-learn functions # Common imports import numpy as np import pandas as pd import matplotlib.pyplot as plt import sklearn.linear_model as skl from sklearn.model_selection import train_test_split from sklearn.metrics import mean_squared_error, r2_score, mean_absolute_error import os # Wh...
0
0
0
0
0
146
0
121
157
87fa1d0539983ab50bd6765615d073fc6e57ec13
2,555
py
Python
Homework/2019/Task7/4/Code/train_LSTM.py
ohhuola/Data-Mining-for-Cybersecurity
7c04b2519810970227777fc1a1a29bb87d47a41e
[ "MIT" ]
null
null
null
Homework/2019/Task7/4/Code/train_LSTM.py
ohhuola/Data-Mining-for-Cybersecurity
7c04b2519810970227777fc1a1a29bb87d47a41e
[ "MIT" ]
null
null
null
Homework/2019/Task7/4/Code/train_LSTM.py
ohhuola/Data-Mining-for-Cybersecurity
7c04b2519810970227777fc1a1a29bb87d47a41e
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # assitantstudent import getData from keras.models import Sequential from keras.layers import LSTM, Dense, Dropout from gensim.models import Word2Vec import numpy as np dim_num_feature = 120 # w2v_model = Word2Vec.load("./data/120features_20minwords_10context") train_com...
25.808081
69
0.643444
# -*- coding: utf-8 -*- # 句向量训练者称为出题者assitant,标签训练者称为student import getData from keras.models import Sequential from keras.layers import LSTM, Dense, Dropout from gensim.models import Word2Vec import numpy as np from keras import metrics dim_num_feature = 120 # 用于限制长度 def magicFit(List, n): L =...
87
0
0
0
0
480
0
4
73
6baf2077d6aa7e3c4e4a813d2c30fad37027191c
41
py
Python
fulltext/process/__init__.py
arXiv/arxiv-fulltext
36008457022cde245d78b3ad91e0a95aa21bc420
[ "MIT" ]
18
2019-03-01T02:51:45.000Z
2021-11-05T12:26:12.000Z
fulltext/process/__init__.py
arXiv/arxiv-fulltext
36008457022cde245d78b3ad91e0a95aa21bc420
[ "MIT" ]
6
2019-05-06T15:25:16.000Z
2019-07-31T20:11:36.000Z
fulltext/process/__init__.py
arXiv/arxiv-fulltext
36008457022cde245d78b3ad91e0a95aa21bc420
[ "MIT" ]
8
2019-01-10T22:01:58.000Z
2021-11-05T12:26:01.000Z
"""Provides methods for text cleanup."""
20.5
40
0.707317
"""Provides methods for text cleanup."""
0
0
0
0
0
0
0
0
0
75b13da89526de6c22179b763d7048ebfcb6a711
11,450
py
Python
trackmania/club.py
NottCurious/py-tmio
c908bfcef7f2cb603464dc762b5dcd8b35711167
[ "MIT" ]
null
null
null
trackmania/club.py
NottCurious/py-tmio
c908bfcef7f2cb603464dc762b5dcd8b35711167
[ "MIT" ]
13
2022-03-08T09:47:07.000Z
2022-03-29T05:29:35.000Z
trackmania/club.py
NottCurious/py-tmio
c908bfcef7f2cb603464dc762b5dcd8b35711167
[ "MIT" ]
null
null
null
import logging _log = logging.getLogger(__name__) __all__ = ( "ClubMember", "ClubActivity", "Club", )
26.201373
100
0.558952
import logging from contextlib import suppress from datetime import datetime from typing_extensions import Self from ._util import _regex_it from .api import _APIClient from .base import ClubObject from .config import get_from_cache, set_in_cache from .constants import _TMIO from .errors import TMIOException from .pl...
0
4,468
2,849
3,621
0
0
0
102
291
4fa7305d7c169f2333c4e1dd0dd584745cc304d9
587
py
Python
txtrader/__main__.py
rstms/txTrader
3120eb47f10979e90c48cb66543378084bae624a
[ "MIT" ]
43
2015-03-30T15:20:00.000Z
2022-02-15T18:25:54.000Z
txtrader/__main__.py
rstms/txTrader
3120eb47f10979e90c48cb66543378084bae624a
[ "MIT" ]
12
2015-08-05T17:36:28.000Z
2020-05-03T23:23:42.000Z
txtrader/__main__.py
rstms/txTrader
3120eb47f10979e90c48cb66543378084bae624a
[ "MIT" ]
25
2015-11-04T03:08:57.000Z
2021-08-07T09:47:37.000Z
if __name__ == '__main__': main()
25.521739
83
0.76661
from twisted.application import internet, service from twisted.internet import reactor from txtrader.tcpserver import serverFactory from txtrader.webserver import webServerFactory from txtrader.rtx import RTX def main(): msvc = service.MultiService() api = RTX() internet.TCPServer(api.http_port, webSer...
0
0
0
0
0
312
0
99
135
c76e6d535659dda04e01bff2aae4c9ec07afb901
466
py
Python
python/Chapter2/change_date.py
wboswall/academia
1571e8f9aceb21564f601cb79120ae56068fe3dd
[ "MIT" ]
null
null
null
python/Chapter2/change_date.py
wboswall/academia
1571e8f9aceb21564f601cb79120ae56068fe3dd
[ "MIT" ]
null
null
null
python/Chapter2/change_date.py
wboswall/academia
1571e8f9aceb21564f601cb79120ae56068fe3dd
[ "MIT" ]
null
null
null
import csv with open('tooldesc.csv') as td: rdr = csv.reader(td) items = list(rdr) items = [convertDate(item) for item in items] with open('tooldesc2.csv', 'w', newline='') as td: wrt = csv.writer(td) for item in items: wrt.writerow(item)
23.3
51
0.628755
import csv, datetime def convertDate(item): theDate = item[-1] dateObj = datetime.strptime(theDate,'%Y-%m-%d') dateStr = datetime.strftime(dateObj,'%m/%d/%Y') item[-1] = dateStr return item with open('tooldesc.csv') as td: rdr = csv.reader(td) items = list(rdr) items = [convertDate(item) ...
0
0
0
0
0
167
0
10
23
00622afd5811d7d269533439388b68d1407bb2ea
4,302
py
Python
my/tools/geo_convert.py
jovahe/Mask_RCNN_RS
9c6c28392ad35786523b3c5c0b9e509c07d84dc5
[ "MIT" ]
null
null
null
my/tools/geo_convert.py
jovahe/Mask_RCNN_RS
9c6c28392ad35786523b3c5c0b9e509c07d84dc5
[ "MIT" ]
null
null
null
my/tools/geo_convert.py
jovahe/Mask_RCNN_RS
9c6c28392ad35786523b3c5c0b9e509c07d84dc5
[ "MIT" ]
null
null
null
""" mask rcnnshapefile """ from osgeo import ogr, gdal, osr def create_geom(): """wkt""" multipolygon = ogr.Geometry(ogr.wkbMultiPolygon) polygon = ogr.Geometry(ogr.wkbPolygon) ring = ogr.Geometry(ogr.wkbLinearRing) ring.AddPoint(1179091.1646903288, 712782.8838459781) ring.AddPoint(1161053.02...
35.262295
109
0.680149
""" 将mask rcnn转成shapefile的一些函数 """ from osgeo import ogr, gdal, osr import cv2 import numpy as np def create_geom(): """用于测试,生成一个wkt""" multipolygon = ogr.Geometry(ogr.wkbMultiPolygon) polygon = ogr.Geometry(ogr.wkbPolygon) ring = ogr.Geometry(ogr.wkbLinearRing) ring.AddPoint(1179091.1646903288, ...
453
0
0
0
0
1,036
0
-14
67
059bf2f72bf5aa02f39a0c6fe3c001cbb311443b
318
py
Python
samples/notification/webhook-events/resend.py
Hey-Marvelous/PayPal-Python-SDK
c56069f8971877e0632c1d58fdf240de9320ece3
[ "BSD-Source-Code" ]
653
2015-01-07T21:40:11.000Z
2022-03-07T18:25:27.000Z
samples/notification/webhook-events/resend.py
sucithrashanu/PayPal-Python-SDK
a129190dc105941b11340659c028385cdceea192
[ "BSD-Source-Code" ]
214
2015-01-05T15:42:18.000Z
2020-05-05T13:15:12.000Z
samples/notification/webhook-events/resend.py
sucithrashanu/PayPal-Python-SDK
a129190dc105941b11340659c028385cdceea192
[ "BSD-Source-Code" ]
300
2015-01-05T07:29:23.000Z
2022-03-22T14:25:02.000Z
from paypalrestsdk import WebhookEvent import logging logging.basicConfig(level=logging.INFO) webhook_event = WebhookEvent.find("8PT597110X687430LKGECATA") if webhook_event.resend(): # return True or False print("webhook event[%s] resend successfully" % (webhook_event.id)) else: print(webhook_event.error)
28.909091
71
0.789308
from paypalrestsdk import WebhookEvent import logging logging.basicConfig(level=logging.INFO) webhook_event = WebhookEvent.find("8PT597110X687430LKGECATA") if webhook_event.resend(): # return True or False print("webhook event[%s] resend successfully" % (webhook_event.id)) else: print(webhook_event.error)
0
0
0
0
0
0
0
0
0
dd5529752580885e45680e99d277416b2da8ff22
947
py
Python
public-engines/product-classifier-engine/tests/data_handler/test_acquisitor_and_cleaner.py
tallandroid/incubator-marvin
2ff33b26d5d362b6541125a400146ccf6153f83b
[ "Apache-2.0" ]
101
2018-10-12T20:33:43.000Z
2022-03-04T08:48:08.000Z
public-engines/product-classifier-engine/tests/data_handler/test_acquisitor_and_cleaner.py
tallandroid/incubator-marvin
2ff33b26d5d362b6541125a400146ccf6153f83b
[ "Apache-2.0" ]
54
2018-11-05T23:39:59.000Z
2022-01-18T01:16:12.000Z
public-engines/product-classifier-engine/tests/data_handler/test_acquisitor_and_cleaner.py
tallandroid/incubator-marvin
2ff33b26d5d362b6541125a400146ccf6153f83b
[ "Apache-2.0" ]
69
2018-10-17T06:02:25.000Z
2022-03-04T08:48:09.000Z
#!/usr/bin/env python # coding=utf-8 try: import mock except ImportError: import unittest.mock as mock
35.074074
147
0.778247
#!/usr/bin/env python # coding=utf-8 try: import mock except ImportError: import unittest.mock as mock from marvin_product_classifier_engine.data_handler import AcquisitorAndCleaner import pandas as pd @mock.patch('marvin_product_classifier_engine.data_handler.acquisitor_and_cleaner.pd.read_csv') @mock.pat...
0
710
0
0
0
0
0
55
68
3f8f2b71ea55cff87e17615fa2ee661772479115
15,807
py
Python
tcex/testing/test_case_service_common.py
kdeltared/tcex
818c0d09256764f871e42d9ca5916f92d941d882
[ "Apache-2.0" ]
18
2017-01-09T22:17:49.000Z
2022-01-24T20:46:42.000Z
tcex/testing/test_case_service_common.py
kdeltared/tcex
818c0d09256764f871e42d9ca5916f92d941d882
[ "Apache-2.0" ]
84
2017-04-11T13:47:49.000Z
2022-03-21T20:12:57.000Z
tcex/testing/test_case_service_common.py
kdeltared/tcex
818c0d09256764f871e42d9ca5916f92d941d882
[ "Apache-2.0" ]
43
2017-01-05T20:40:26.000Z
2022-03-31T19:18:02.000Z
"""TcEx Service Common Module""" # standard library
37.018735
100
0.613462
"""TcEx Service Common Module""" # standard library import base64 import json import os import subprocess import sys import time import uuid from multiprocessing import Process from random import randint from threading import Event, Lock, Thread from typing import Any, Optional from ..services import MqttMessageBroker...
0
2,097
0
13,303
0
0
0
44
310
01ddefef38c00baca510900b46bd257b39da6414
324
py
Python
ignorancia zero/aulas 87-102/aula 87.py
KenzoDezotti/cursoemvideo
6eba03e67192f7384092192ed2cc1a8e59efd9b9
[ "MIT" ]
null
null
null
ignorancia zero/aulas 87-102/aula 87.py
KenzoDezotti/cursoemvideo
6eba03e67192f7384092192ed2cc1a8e59efd9b9
[ "MIT" ]
null
null
null
ignorancia zero/aulas 87-102/aula 87.py
KenzoDezotti/cursoemvideo
6eba03e67192f7384092192ed2cc1a8e59efd9b9
[ "MIT" ]
null
null
null
'''aula de tkinter I''' #d nome ao quadro principal quadro = Tk() #d um tamanho ao quadro quadro.geometry("800x600") #d o titulo na janela do programa quadro.title("primeiro programa pos retorno!") #faz o quadro iniciar # sem isso o programa no abre quadro.mainloop()
7.902439
46
0.679012
'''aula de tkinter I''' from tkinter import * #dá nome ao quadro principal quadro = Tk() #dá um tamanho ao quadro quadro.geometry("800x600") #dá o titulo na janela do programa quadro.title("primeiro programa pos retorno!") #faz o quadro iniciar # sem isso o programa não abre quadro.mainloop() ...
8
0
0
0
0
0
0
0
23
160586a7f083f1efa16456b4bf747dcafc4be695
7,851
py
Python
GamesGetter.py
JamescMcE/BasketBet
f87719ac793ea50822e8c52fc23191dba9ad6418
[ "CC0-1.0" ]
null
null
null
GamesGetter.py
JamescMcE/BasketBet
f87719ac793ea50822e8c52fc23191dba9ad6418
[ "CC0-1.0" ]
null
null
null
GamesGetter.py
JamescMcE/BasketBet
f87719ac793ea50822e8c52fc23191dba9ad6418
[ "CC0-1.0" ]
null
null
null
#This script Imports Game Data from ESPN, and Odds from the ODDS-API, and then imports them into a MySQL table, example in workbench here https://puu.sh/HOKCj/ce199eec8e.png import mysql.connector import datetime import time #Connection to the MYSQL Server. mydb = mysql.connector.connect( host="", user="...
42.668478
257
0.584639
#This script Imports Game Data from ESPN, and Odds from the ODDS-API, and then imports them into a MySQL table, example in workbench here https://puu.sh/HOKCj/ce199eec8e.png import mysql.connector import requests import json import datetime import time #Connection to the MYSQL Server. mydb = mysql.connector....
0
0
0
0
0
4,360
0
-16
92
692959bca4a35e14e41b554f367efb825930cf94
8,282
py
Python
src/pytools/data/_simulation.py
BCG-Gamma/pytools
d7be703e0665917cd75b671564d5c0163f13b77b
[ "Apache-2.0" ]
17
2021-01-12T08:07:11.000Z
2022-03-03T22:59:04.000Z
src/pytools/data/_simulation.py
BCG-Gamma/pytools
d7be703e0665917cd75b671564d5c0163f13b77b
[ "Apache-2.0" ]
10
2021-01-08T17:04:39.000Z
2022-01-18T13:21:52.000Z
src/pytools/data/_simulation.py
BCG-Gamma/pytools
d7be703e0665917cd75b671564d5c0163f13b77b
[ "Apache-2.0" ]
1
2021-11-06T00:16:43.000Z
2021-11-06T00:16:43.000Z
""" Utilities for creating simulated data sets. """ from typing import Optional, Sequence import numpy as np import pandas as pd from scipy.linalg import toeplitz from ..api import AllTracker __all__ = ["sim_data"] __tracker = AllTracker(globals()) def sim_data( n: int = 100, intercept: float = -5, t...
36.646018
88
0.637769
""" Utilities for creating simulated data sets. """ from typing import Optional, Sequence import numpy as np import pandas as pd from scipy.linalg import toeplitz from ..api import AllTracker __all__ = ["sim_data"] __tracker = AllTracker(globals()) def sim_data( n: int = 100, intercept: float = -5, t...
0
0
0
0
0
0
0
0
0
b9f2d2d035a42477222d50abe0075ed5e223296f
15,565
py
Python
src/sparseml/sparsification/model_info.py
zjzh/sparseml
b92df81257d47eb5aab731bc9929da7339f34667
[ "Apache-2.0" ]
922
2021-02-04T17:51:54.000Z
2022-03-31T20:49:26.000Z
src/sparseml/sparsification/model_info.py
zjzh/sparseml
b92df81257d47eb5aab731bc9929da7339f34667
[ "Apache-2.0" ]
197
2021-02-04T22:17:21.000Z
2022-03-31T13:58:55.000Z
src/sparseml/sparsification/model_info.py
zjzh/sparseml
b92df81257d47eb5aab731bc9929da7339f34667
[ "Apache-2.0" ]
80
2021-02-04T22:20:14.000Z
2022-03-30T19:36:15.000Z
# Copyright (c) 2021 - present / Neuralmagic, Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required b...
33.258547
88
0.633794
# Copyright (c) 2021 - present / Neuralmagic, Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required b...
0
5,381
0
8,076
0
565
0
116
385
5a2596d1d51c1ec9caef0f4693ca0bcdfa061f9b
877
py
Python
invenio_cesnet_proxyidp/models.py
CESNET/invenio-cesnet-proxyidp
30d9d8338116f755fda89384c64e97e668584059
[ "MIT" ]
null
null
null
invenio_cesnet_proxyidp/models.py
CESNET/invenio-cesnet-proxyidp
30d9d8338116f755fda89384c64e97e668584059
[ "MIT" ]
null
null
null
invenio_cesnet_proxyidp/models.py
CESNET/invenio-cesnet-proxyidp
30d9d8338116f755fda89384c64e97e668584059
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # # Copyright (C) 2019 CESNET z.s.p.o.. # # OARepo is free software; you can redistribute it and/or modify it # under the terms of the MIT License; see LICENSE file for more details. """ Models used by the ProxyIDP Remote application """
24.361111
72
0.621437
# -*- coding: utf-8 -*- # # Copyright (C) 2019 CESNET z.s.p.o.. # # OARepo is free software; you can redistribute it and/or modify it # under the terms of the MIT License; see LICENSE file for more details. """ Models used by the ProxyIDP Remote application """ class UserInfo(object): sub: str = None name: st...
0
171
0
420
0
0
0
0
23
04d82150bb79c8da7a6fceeb2f6284063036a2d1
1,339
py
Python
stanCode_projects/weather_master/weather_master.py
tyw4622/sc-project
9af0aac090f34436ccce7761b9e4b9595089eaa9
[ "MIT" ]
null
null
null
stanCode_projects/weather_master/weather_master.py
tyw4622/sc-project
9af0aac090f34436ccce7761b9e4b9595089eaa9
[ "MIT" ]
null
null
null
stanCode_projects/weather_master/weather_master.py
tyw4622/sc-project
9af0aac090f34436ccce7761b9e4b9595089eaa9
[ "MIT" ]
null
null
null
""" File: weather_master.py Name: Karen Wong ----------------------- This program should implement a console program that asks weather data from user to compute the average, highest, lowest, cold days among the inputs. Output format should match what is shown in the sample run in the Assignment 2 Handout. """ EXIT = -...
24.796296
149
0.643017
""" File: weather_master.py Name: Karen Wong ----------------------- This program should implement a console program that asks weather data from user to compute the average, highest, lowest, cold days among the inputs. Output format should match what is shown in the sample run in the Assignment 2 Handout. """ EXIT = -...
0
0
0
0
0
0
0
0
0
3cc084e3982d5bb70dc5ab74d2e802153ba6faa8
439
py
Python
tueplots/cycler.py
SirRob1997/tueplots
83c6bfabe83b58bd38b6e361a85fd1b33bfd063c
[ "MIT" ]
null
null
null
tueplots/cycler.py
SirRob1997/tueplots
83c6bfabe83b58bd38b6e361a85fd1b33bfd063c
[ "MIT" ]
null
null
null
tueplots/cycler.py
SirRob1997/tueplots
83c6bfabe83b58bd38b6e361a85fd1b33bfd063c
[ "MIT" ]
null
null
null
"""Color cycler.""" from matplotlib import cycler as mpl_cycler def cycler(**kwargs): """Wrap a matplotlib.cycler object into a parameter-dictionary compatible with plt.rcParams. Please refer to https://matplotlib.org/cycler/ and https://matplotlib.org/stable/tutorials/intermediate/color...
27.4375
96
0.70615
"""Color cycler.""" from matplotlib import cycler as mpl_cycler def cycler(**kwargs): """Wrap a matplotlib.cycler object into a parameter-dictionary compatible with plt.rcParams. Please refer to https://matplotlib.org/cycler/ and https://matplotlib.org/stable/tutorials/intermediate/color...
0
0
0
0
0
0
0
0
0
a4aabad16286b60a5d720711afea1d3dc95e091b
76
py
Python
test/__init__.py
continental/hybrid_learning
37b9fc83d7b14902dfe92e0c45071c150bcf3779
[ "MIT" ]
3
2020-10-19T12:47:03.000Z
2021-03-02T11:26:00.000Z
test/__init__.py
continental/hybrid_learning
37b9fc83d7b14902dfe92e0c45071c150bcf3779
[ "MIT" ]
null
null
null
test/__init__.py
continental/hybrid_learning
37b9fc83d7b14902dfe92e0c45071c150bcf3779
[ "MIT" ]
1
2022-01-02T10:50:53.000Z
2022-01-02T10:50:53.000Z
# Copyright (c) 2020 Continental Automotive GmbH """Testing functions."""
19
49
0.723684
# Copyright (c) 2020 Continental Automotive GmbH """Testing functions."""
0
0
0
0
0
0
0
0
0
f745cd4946f48dd0fae6848f226b80a6166a1f5f
21,621
py
Python
riptable/tests/test_accum2.py
972d5defe3218bd62b741e6a2f11f5b3/riptable
bb928c11752e831ec701f91964979b31db53826a
[ "BSD-2-Clause-Patent" ]
307
2020-08-27T20:25:11.000Z
2022-03-08T15:51:19.000Z
riptable/tests/test_accum2.py
972d5defe3218bd62b741e6a2f11f5b3/riptable
bb928c11752e831ec701f91964979b31db53826a
[ "BSD-2-Clause-Patent" ]
206
2020-08-17T19:07:15.000Z
2022-03-18T11:53:55.000Z
riptable/tests/test_accum2.py
972d5defe3218bd62b741e6a2f11f5b3/riptable
bb928c11752e831ec701f91964979b31db53826a
[ "BSD-2-Clause-Patent" ]
10
2020-08-28T00:22:05.000Z
2021-04-30T20:22:28.000Z
import unittest # N.B. TL;DR We have to import the actual implementation module to override the module global # variable "tm.N" and "tm.K". # In pandas 1.0 they move the code from pandas/util/testing.py to pandas/_testing.py. # The "import pandas.util.testing" still works but because it doesn't conta...
39.027076
175
0.542019
import unittest import pandas as pd import pytest import riptable as rt # N.B. TL;DR We have to import the actual implementation module to override the module global # variable "tm.N" and "tm.K". # In pandas 1.0 they move the code from pandas/util/testing.py to pandas/_testing.py. # The "import ...
0
6,929
0
13,418
0
0
0
163
265
8674fe6e4ff0a7a0d1ff39489a45165712137342
4,129
py
Python
src/sqlfluff/core/parser/segments/meta.py
amardeep/sqlfluff
7951f4f349f47c250c8bbb768da02408fa794ec3
[ "MIT" ]
3,024
2020-10-01T11:03:51.000Z
2022-03-31T16:42:00.000Z
src/sqlfluff/core/parser/segments/meta.py
amardeep/sqlfluff
7951f4f349f47c250c8bbb768da02408fa794ec3
[ "MIT" ]
2,395
2020-09-30T12:59:21.000Z
2022-03-31T22:05:29.000Z
src/sqlfluff/core/parser/segments/meta.py
amardeep/sqlfluff
7951f4f349f47c250c8bbb768da02408fa794ec3
[ "MIT" ]
246
2020-10-02T17:08:03.000Z
2022-03-30T17:43:51.000Z
"""Indent and Dedent classes."""
35.594828
88
0.677646
"""Indent and Dedent classes.""" from sqlfluff.core.parser.match_wrapper import match_wrapper from sqlfluff.core.parser.segments.raw import RawSegment from sqlfluff.core.parser.context import ParseContext from typing import Optional, List class MetaSegment(RawSegment): """A segment which is empty but indicates w...
0
858
0
2,935
0
0
0
118
181
e48abadfedd490282f6f93a8ddaa2ed4547c2067
622
py
Python
EbfWriterLib.py
fermi-lat/EbfWriter
ede39be090864de859e21103bd862839cbf4116a
[ "BSD-3-Clause" ]
null
null
null
EbfWriterLib.py
fermi-lat/EbfWriter
ede39be090864de859e21103bd862839cbf4116a
[ "BSD-3-Clause" ]
null
null
null
EbfWriterLib.py
fermi-lat/EbfWriter
ede39be090864de859e21103bd862839cbf4116a
[ "BSD-3-Clause" ]
null
null
null
#$Header: /nfs/slac/g/glast/ground/cvs/GlastRelease-scons/EbfWriter/EbfWriterLib.py,v 1.3 2009/11/13 23:20:55 jrb Exp $
36.588235
119
0.646302
#$Header: /nfs/slac/g/glast/ground/cvs/GlastRelease-scons/EbfWriter/EbfWriterLib.py,v 1.3 2009/11/13 23:20:55 jrb Exp $ def generate(env, **kw): if not kw.get('depsOnly', 0): env.Tool('addLibrary', library = ['EbfWriter']) if env['PLATFORM']=='win32' and env.get('CONTAINERNAME','')=='GlastRelease': ...
0
0
0
0
0
458
0
0
44
3f090c825452547dfa25b58d3c0bf2f6280faf90
826
py
Python
source_code/3-2-download.py
VickyMin1994/easy-scraping-tutorial
75b7ffc79da397afa95342022c29cd72520f155f
[ "MIT" ]
708
2017-12-29T05:32:34.000Z
2022-03-25T14:29:05.000Z
source_code/3-2-download.py
VickyMin1994/easy-scraping-tutorial
75b7ffc79da397afa95342022c29cd72520f155f
[ "MIT" ]
6
2018-01-06T07:58:31.000Z
2020-10-26T15:57:46.000Z
source_code/3-2-download.py
VickyMin1994/easy-scraping-tutorial
75b7ffc79da397afa95342022c29cd72520f155f
[ "MIT" ]
609
2017-12-29T10:04:20.000Z
2022-03-23T18:32:37.000Z
import os os.makedirs('./img/', exist_ok=True) IMAGE_URL = "https://mofanpy.com/static/img/description/learning_step_flowchart.png" urllib_download() print('download image1') request_download() print('download image2') chunk_download() print('download image3')
23.6
84
0.670702
import os os.makedirs('./img/', exist_ok=True) IMAGE_URL = "https://mofanpy.com/static/img/description/learning_step_flowchart.png" def urllib_download(): from urllib.request import urlretrieve urlretrieve(IMAGE_URL, './img/image1.png') # whole document def request_download(): import requests ...
0
0
0
0
0
489
0
0
69
f618f30d898e855661bab363571158a5c6d1619b
1,448
py
Python
test/test_basic.py
ajnelson-nist/OWL-RL
a77e1791b88b54aace609bc6000aac14c7add4ff
[ "W3C-20150513" ]
94
2015-01-12T15:37:57.000Z
2022-02-16T15:29:20.000Z
test/test_basic.py
ajnelson-nist/OWL-RL
a77e1791b88b54aace609bc6000aac14c7add4ff
[ "W3C-20150513" ]
44
2015-10-05T15:12:12.000Z
2022-02-23T11:57:19.000Z
test/test_basic.py
ajnelson-nist/OWL-RL
a77e1791b88b54aace609bc6000aac14c7add4ff
[ "W3C-20150513" ]
24
2015-02-16T15:06:00.000Z
2022-01-18T22:35:36.000Z
from rdflib import Namespace import sys from pathlib import Path sys.path.append(str(Path(__file__).parent.parent)) RELS = Namespace("http://example.org/relatives#")
29.55102
95
0.68163
from rdflib import Graph, Namespace from rdflib.namespace import RDF import sys from pathlib import Path sys.path.append(str(Path(__file__).parent.parent)) import owlrl RELS = Namespace("http://example.org/relatives#") def test_basic(): # create an RDF graph, load a simple OWL ontology and data g = Graph() ...
0
0
0
0
0
1,203
0
9
67
6ea45be4843a9d0b375de22e509a1fc5e871aee5
404
py
Python
test/test_add_contact_to_group.py
dmatveev-issart/python_training
fd88d11ded7e3e591899aa3ceaa99d0f0193e0c8
[ "Apache-2.0" ]
null
null
null
test/test_add_contact_to_group.py
dmatveev-issart/python_training
fd88d11ded7e3e591899aa3ceaa99d0f0193e0c8
[ "Apache-2.0" ]
null
null
null
test/test_add_contact_to_group.py
dmatveev-issart/python_training
fd88d11ded7e3e591899aa3ceaa99d0f0193e0c8
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*-
33.666667
64
0.737624
# -*- coding: utf-8 -*- from model.contact import Contact import random def test_add_contact_to_group(app, db): contacts_list = db.get_contact_list() index = len(contacts_list) contact = random.choice(contacts_list) app.contact.add_contact_to_group_by_id(contact.id) #print("added = ", db.get_conta...
0
0
0
0
0
309
0
4
67
63f105f4ce40e1dfa2fcab6b3de4699cbf199fe8
1,598
py
Python
survey/features/page_objects/accounts.py
ericazhou7/uSurvey
1236f33355662957e7e1e769dde1811b910673a5
[ "BSD-3-Clause" ]
5
2016-08-25T12:48:54.000Z
2018-08-16T22:49:43.000Z
survey/features/page_objects/accounts.py
ericazhou7/uSurvey
1236f33355662957e7e1e769dde1811b910673a5
[ "BSD-3-Clause" ]
2
2016-08-11T06:43:56.000Z
2016-12-08T09:11:36.000Z
survey/features/page_objects/accounts.py
ericazhou7/uSurvey
1236f33355662957e7e1e769dde1811b910673a5
[ "BSD-3-Clause" ]
7
2016-09-16T11:03:44.000Z
2020-10-28T22:01:20.000Z
# vim: ai ts=4 sts=4 et sw=4 encoding=utf-8
30.730769
80
0.69587
# vim: ai ts=4 sts=4 et sw=4 encoding=utf-8 from survey.features.page_objects.base import PageObject from survey.features.page_objects.root import AboutPage, HomePage from lettuce.django import django_url class ResetPasswordPage(PageObject): url = '/accounts/reset_password/' def is_change_password_form_visb...
0
0
0
1,320
0
0
0
95
136
1ccbbad3d2e24da899bb1e19744c8c8cb1aae1c3
6,655
py
Python
happ.py
yethranayeh/Daily-Mood-Rater
0bf2ee688d066dd01bb388e00172a2d9e15ec043
[ "MIT" ]
null
null
null
happ.py
yethranayeh/Daily-Mood-Rater
0bf2ee688d066dd01bb388e00172a2d9e15ec043
[ "MIT" ]
null
null
null
happ.py
yethranayeh/Daily-Mood-Rater
0bf2ee688d066dd01bb388e00172a2d9e15ec043
[ "MIT" ]
1
2021-10-04T10:18:04.000Z
2021-10-04T10:18:04.000Z
# Credits # "faces" icon created by Vector Valley, PK from the Noun Project # https://thenounproject.com/term/faces/4127357/ import sys, json from PyQt5.QtWidgets import QApplication from pathlib import Path cur_dir = Path.cwd() with open(cur_dir / "src/config.json", "r", encoding="utf-8") as cfg: config = json.l...
39.378698
252
0.632006
# Credits # "faces" icon created by Vector Valley, PK from the Noun Project # https://thenounproject.com/term/faces/4127357/ import sys, mood_db, json from datetime import datetime from PyQt5.QtWidgets import QApplication, QMainWindow, QMessageBox, QWidget from PyQt5.QtGui import QIcon, QPalette, QColor from interfac...
0
0
0
5,537
0
0
0
98
120
ac69101e3fa1b98949a2121985c8eb222eafe06e
15,564
py
Python
samples/digitrec/digitrec_main.py
zzzDavid/heterocl
977aae575d54a30c5bf6d869e8f71bdc815cf7e9
[ "Apache-2.0" ]
236
2019-05-19T01:48:11.000Z
2022-03-31T09:03:54.000Z
samples/digitrec/digitrec_main.py
zzzDavid/heterocl
977aae575d54a30c5bf6d869e8f71bdc815cf7e9
[ "Apache-2.0" ]
248
2019-05-17T19:18:36.000Z
2022-03-30T21:25:47.000Z
samples/digitrec/digitrec_main.py
AlgaPeng/heterocl-2
b5197907d1fe07485466a63671a2a906a861c939
[ "Apache-2.0" ]
85
2019-05-17T20:09:27.000Z
2022-02-28T20:19:00.000Z
# -*- coding: utf-8 -*- """ HeteroCL Tutorial : K-Nearest-Neighbor Digit Recognition ======================================================== **Author**: Yi-Hsiang Lai (seanlatias@github) HeteroCL is a domain-specific language (DSL) based on TVM that supports heterogeneous backend devices. Moreover, HeteroCL also sup...
37.960976
83
0.587831
# -*- coding: utf-8 -*- """ HeteroCL Tutorial : K-Nearest-Neighbor Digit Recognition ======================================================== **Author**: Yi-Hsiang Lai (seanlatias@github) HeteroCL is a domain-specific language (DSL) based on TVM that supports heterogeneous backend devices. Moreover, HeteroCL also sup...
26
0
0
0
0
3,186
0
0
45
363f7c40b5d9c31f1a5a5d929926532b5504ef4e
1,072
py
Python
Project 1/Codes/main2.py
snehanyk05/Statistical-Pattern-Recognition
da457705a11713782a4522e0f2cfb801d5287e64
[ "MIT" ]
null
null
null
Project 1/Codes/main2.py
snehanyk05/Statistical-Pattern-Recognition
da457705a11713782a4522e0f2cfb801d5287e64
[ "MIT" ]
null
null
null
Project 1/Codes/main2.py
snehanyk05/Statistical-Pattern-Recognition
da457705a11713782a4522e0f2cfb801d5287e64
[ "MIT" ]
null
null
null
import pca import lda from sklearn.neighbors import KNeighborsClassifier Xtrain_m, Ytrain = load_mnist('data/fashion', kind='train') Xtest_m, Ytest = load_mnist('data/fashion', kind='t10k') classifier = KNeighborsClassifier(n_neighbors=1) classifier.fit(Xtrain_m, Ytrain) print("Test accur...
26.8
102
0.716418
from utils.mnist_reader import * import pca import lda import numpy as np from sklearn.neighbors import KNeighborsClassifier def score(classifier, X, Y, type1): P = classifier.predict(X) return np.round(np.mean(P == Y),4) Xtrain_m, Ytrain = load_mnist('data/fashion', kind='tra...
0
0
0
0
0
91
0
9
68
f6bdfba3beb10ee1c632bff22572c7d8363a6a89
1,051
py
Python
projetinhos/ex#45 - GAME pedra papel tesoura.py
dani-fn/Projetinhos_Python
692ff0a7f57d8f8f2e28f7b2c38bb6401e013bdb
[ "MIT" ]
null
null
null
projetinhos/ex#45 - GAME pedra papel tesoura.py
dani-fn/Projetinhos_Python
692ff0a7f57d8f8f2e28f7b2c38bb6401e013bdb
[ "MIT" ]
null
null
null
projetinhos/ex#45 - GAME pedra papel tesoura.py
dani-fn/Projetinhos_Python
692ff0a7f57d8f8f2e28f7b2c38bb6401e013bdb
[ "MIT" ]
null
null
null
from random import choice from time import sleep from sys import exit print('''Suas opes: \033[30m[ 1 ] PEDRA [ 2 ] PAPEL [ 3 ] TESOURA\33[m''') jogada = int(input('Qual a sua jogada? ')) if jogada == 1: jogada = 'PEDRA' elif jogada == 2: jogada = 'PAPEL' elif jogada == 3: jogada = 'TESOURA' e...
29.194444
72
0.602284
from random import choice from time import sleep from sys import exit print('''Suas opções: \033[30m[ 1 ] PEDRA [ 2 ] PAPEL [ 3 ] TESOURA\33[m''') jogada = int(input('Qual a sua jogada? ')) if jogada == 1: jogada = 'PEDRA' elif jogada == 2: jogada = 'PAPEL' elif jogada == 3: jogada = 'TESOURA' ...
28
0
0
0
0
0
0
0
0
a42fa9f0cfa3541087006e749001845830cb5828
1,588
py
Python
Medium/Palendrome/main.py
darthjamil/LeetStuff
e32bcb180f2a36cbd12d97998680929c593573d0
[ "CC0-1.0" ]
null
null
null
Medium/Palendrome/main.py
darthjamil/LeetStuff
e32bcb180f2a36cbd12d97998680929c593573d0
[ "CC0-1.0" ]
null
null
null
Medium/Palendrome/main.py
darthjamil/LeetStuff
e32bcb180f2a36cbd12d97998680929c593573d0
[ "CC0-1.0" ]
null
null
null
chars_to_remove = [',', '.', '!', ':', ';', '-', ' ', '?'] if __name__ == '__main__': tests = [ "", # false "lotion", # false "racecar", # true "Racecar", # true "Step on no p ets", # true "No lemon no melons", # false "Eva - can I see bees in a cave?", #...
26.915254
82
0.554156
chars_to_remove = [',', '.', '!', ':', ';', '-', ' ', '?'] def get_longest_palendromes(text): if not text: return [] if len(text) <= 2: return [text] palendromes = [] for window_size in range(len(text), 1, -1): num_shifts = len(text) - window_size for start_index in range(0, num_shif...
0
0
0
0
0
694
0
0
92
05a28ae40a3d94b62f58af8eb1973a1e1d7d3bac
34,199
py
Python
debt_manager_backend/debt_manager_backend_api/tests.py
GeorgeS1995/debt_manager_backend
b7dad55e5a86a87619ab528eea81a2e59f9ffbaf
[ "MIT" ]
null
null
null
debt_manager_backend/debt_manager_backend_api/tests.py
GeorgeS1995/debt_manager_backend
b7dad55e5a86a87619ab528eea81a2e59f9ffbaf
[ "MIT" ]
7
2020-11-19T19:55:24.000Z
2021-09-22T18:47:38.000Z
debt_manager_backend/debt_manager_backend_api/tests.py
GeorgeS1995/debt_manager_backend
b7dad55e5a86a87619ab528eea81a2e59f9ffbaf
[ "MIT" ]
null
null
null
from django.contrib.auth import get_user_model User = get_user_model() # Create your tests here.
38.125975
120
0.584695
import json from django.contrib.auth import get_user_model from rest_framework.test import APITestCase, APIClient from oauth2_provider.models import AccessToken, Application from django.utils import timezone from .models import Currency, Debtor, Transaction, CurrencyOwner from rest_framework.reverse import reverse from...
60
3,305
0
30,066
0
0
0
159
534
74eba63c8e0962eba857ab3f9dc8dde68140756b
1,656
py
Python
Search/DStarGrid.py
jabbala/AI-for-Robotics
8fdb2549138f470baf4ecf61d74752622389d222
[ "MIT" ]
1
2022-01-29T10:25:28.000Z
2022-01-29T10:25:28.000Z
Search/DStarGrid.py
jabbala/AI-for-Robotics
8fdb2549138f470baf4ecf61d74752622389d222
[ "MIT" ]
2
2022-01-29T16:20:27.000Z
2022-01-29T19:30:08.000Z
Search/DStarGrid.py
jabbala/AI-for-Robotics
8fdb2549138f470baf4ecf61d74752622389d222
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """Localization_1D.py: Localizing robot in Two dimensional space""" __author__ ="Gunasekar Jabbala" __credits__ =["Daniel Ingram", "Udacity", " AtsushiSakai"] import numpy as np import matplotlib.pyplot as plt import matplotlib.animation as animation # Rows and C...
29.571429
84
0.520531
#!/usr/bin/env python # -*- coding: utf-8 -*- """Localization_1D.py: Localizing robot in Two dimensional space""" __author__ ="Gunasekar Jabbala" __credits__ =["Daniel Ingram", "Udacity", " AtsushiSakai"] import random import numpy as np import matplotlib.pyplot as plt import matplotlib.animation as animatio...
0
0
0
0
0
716
0
-8
45
d04a77a78c1f367bfaf7d3b3e933407afd2256ec
39,105
py
Python
SUAVE/Tutorials-2.5.0/tut_mission_B737.py
Vinicius-Tanigawa/Undergraduate-Research-Project
e92372f07882484b127d7affe305eeec2238b8a9
[ "MIT" ]
null
null
null
SUAVE/Tutorials-2.5.0/tut_mission_B737.py
Vinicius-Tanigawa/Undergraduate-Research-Project
e92372f07882484b127d7affe305eeec2238b8a9
[ "MIT" ]
null
null
null
SUAVE/Tutorials-2.5.0/tut_mission_B737.py
Vinicius-Tanigawa/Undergraduate-Research-Project
e92372f07882484b127d7affe305eeec2238b8a9
[ "MIT" ]
null
null
null
# tut_mission_B737.py # # Created: Aug 2014, SUAVE Team # Modified: Aug 2017, SUAVE Team # Mar 2020, E. Botero # ---------------------------------------------------------------------- # Imports # ---------------------------------------------------------------------- # General Python Imports import numpy...
40.314433
100
0.554763
# tut_mission_B737.py # # Created: Aug 2014, SUAVE Team # Modified: Aug 2017, SUAVE Team # Mar 2020, E. Botero # ---------------------------------------------------------------------- # Imports # ---------------------------------------------------------------------- # General Python Imports import numpy...
0
0
0
0
0
0
0
36
22
f7a587abc392d6fc3e8aa9b34ccf761cac91630c
7,048
py
Python
python/ccxt/static_dependencies/ecdsa/der.py
orikalinski/ccxt_new
318caa4f8db7ffb719edab2c060a0989d2a9cd28
[ "MIT" ]
26
2018-12-10T07:16:35.000Z
2022-03-15T03:15:54.000Z
python/ccxt/static_dependencies/ecdsa/der.py
orikalinski/ccxt_new
318caa4f8db7ffb719edab2c060a0989d2a9cd28
[ "MIT" ]
4
2020-09-07T14:47:15.000Z
2021-05-10T17:47:05.000Z
python/ccxt/static_dependencies/ecdsa/der.py
orikalinski/ccxt_new
318caa4f8db7ffb719edab2c060a0989d2a9cd28
[ "MIT" ]
13
2019-03-13T14:54:30.000Z
2021-10-14T10:11:49.000Z
from __future__ import division # SEQUENCE([1, STRING(secexp), cont[0], OBJECT(curvename), cont[1], BINTSTRING) # signatures: (from RFC3279) # ansi-X9-62 OBJECT IDENTIFIER ::= { # iso(1) member-body(2) us(840) 10045 } # # id-ecSigType OBJECT IDENTIFIER ::= { # ansi-X9-62 signatures(...
31.605381
97
0.617054
from __future__ import division import binascii import base64 from six import int2byte, b, integer_types, text_type class UnexpectedDER(Exception): pass def encode_constructed(tag, value): return int2byte(0xa0+tag) + encode_length(len(value)) + value def encode_integer(r): assert r >= 0 # can't supp...
0
0
0
19
0
5,542
0
18
504
557230df224a88d7d7ea836b63a9e13606869a07
45
py
Python
app/core/enums.py
behibobo/openvpn_monitoring
a2b7b2c440ddd1a94f6c3a21d41e847498364e3d
[ "MIT" ]
null
null
null
app/core/enums.py
behibobo/openvpn_monitoring
a2b7b2c440ddd1a94f6c3a21d41e847498364e3d
[ "MIT" ]
null
null
null
app/core/enums.py
behibobo/openvpn_monitoring
a2b7b2c440ddd1a94f6c3a21d41e847498364e3d
[ "MIT" ]
1
2021-11-20T19:30:29.000Z
2021-11-20T19:30:29.000Z
# add your enums here
11.25
21
0.755556
# add your enums here from enum import Enum
0
0
0
0
0
0
0
0
23
810a2b09dcfd4d9a59685a2093ec4bd2cb86493d
8,250
py
Python
fst/romanian/operations.py
ytsvetko/loanwords
dfe83ef9ccc5b6d70b87a9da0414e6737b922ab3
[ "Apache-2.0" ]
null
null
null
fst/romanian/operations.py
ytsvetko/loanwords
dfe83ef9ccc5b6d70b87a9da0414e6737b922ab3
[ "Apache-2.0" ]
null
null
null
fst/romanian/operations.py
ytsvetko/loanwords
dfe83ef9ccc5b6d70b87a9da0414e6737b922ab3
[ "Apache-2.0" ]
1
2019-01-15T03:34:27.000Z
2019-01-15T03:34:27.000Z
# -*- coding: utf-8 -*- import phone_transducer as pt import itertools def phone_substitution_transducer(add_meta_arc=True): """Substitute similar phones (optionally).""" max_node = 0 t = pt.Transducer() for l in pt.abc.ALL_SYMS: t.add_arc(0, 0, l, l) for s_ar, s_sw, subst_cost in pt.abc.AR_SW_SIMILA...
32.868526
107
0.658303
# -*- coding: utf-8 -*- import phone_transducer as pt import itertools def phone_substitution_transducer(add_meta_arc=True): """Substitute similar phones (optionally).""" def DetectViolation(l_ar, l_sw, group): if l_ar == pt.abc.EPSILON or l_sw == pt.abc.EPSILON: return False if group[l_ar] != group...
0
0
0
0
0
164
0
0
24
43837eef051b992f7a3209fc2a3a764a3e2dc1d2
626
py
Python
2-Work_queues/new_task.py
MaiconMares/RabbitMQ-Distributed-Programming
de7e8192847fc3afd9234b113eb7d88c275d1e25
[ "MIT" ]
null
null
null
2-Work_queues/new_task.py
MaiconMares/RabbitMQ-Distributed-Programming
de7e8192847fc3afd9234b113eb7d88c275d1e25
[ "MIT" ]
null
null
null
2-Work_queues/new_task.py
MaiconMares/RabbitMQ-Distributed-Programming
de7e8192847fc3afd9234b113eb7d88c275d1e25
[ "MIT" ]
null
null
null
import pika, sys # Inicia a conexo e cria o canal de conexao connection = pika.BlockingConnection(pika.ConnectionParameters('localhost')) channel = connection.channel() # Cria a fila se ela no existir channel.queue_declare(queue='task_queue', durable=True) message = ' '.join(sys.argv[1:]) or 'Hello World...' channe...
28.454545
76
0.645367
import pika, sys # Inicia a conexão e cria o canal de conexao connection = pika.BlockingConnection(pika.ConnectionParameters('localhost')) channel = connection.channel() # Cria a fila se ela não existir channel.queue_declare(queue='task_queue', durable=True) message = ' '.join(sys.argv[1:]) or 'Hello World...' chan...
4
0
0
0
0
0
0
0
0
6a37fd58b3ae0d0d668d59059a6bb1a2aec10c05
4,301
py
Python
tests/components/version/test_sensor.py
learn-home-automation/core
c5d8792c3487e9b418b1e7d623bf59e7dbddd6b7
[ "Apache-2.0" ]
22,481
2020-03-02T13:09:59.000Z
2022-03-31T23:34:28.000Z
tests/components/version/test_sensor.py
learn-home-automation/core
c5d8792c3487e9b418b1e7d623bf59e7dbddd6b7
[ "Apache-2.0" ]
31,101
2020-03-02T13:00:16.000Z
2022-03-31T23:57:36.000Z
tests/components/version/test_sensor.py
learn-home-automation/core
c5d8792c3487e9b418b1e7d623bf59e7dbddd6b7
[ "Apache-2.0" ]
11,411
2020-03-02T14:19:20.000Z
2022-03-31T22:46:07.000Z
"""The test for the version sensor platform.""" from __future__ import annotations
31.859259
78
0.656126
"""The test for the version sensor platform.""" from __future__ import annotations from typing import Any from unittest.mock import patch from pyhaversion import HaVersionChannel, HaVersionSource from pyhaversion.exceptions import HaVersionException import pytest from homeassistant.components.version.const import ( ...
0
1,731
1,616
0
0
0
0
529
338
8c7cbbd7dace0cec34238f26bec2d9cc4b8fb586
685
py
Python
String Manipulation/SpecialStringAgain.py
WinterSoldier13/interview-preparation-kit
64e56725c1a8af17c209bb3191227935b05f6227
[ "MIT" ]
175
2019-12-08T19:48:20.000Z
2022-03-24T07:38:08.000Z
String Manipulation/SpecialStringAgain.py
WinterSoldier13/interview-preparation-kit
64e56725c1a8af17c209bb3191227935b05f6227
[ "MIT" ]
40
2019-12-07T08:11:41.000Z
2020-10-09T08:11:22.000Z
String Manipulation/SpecialStringAgain.py
WinterSoldier13/interview-preparation-kit
64e56725c1a8af17c209bb3191227935b05f6227
[ "MIT" ]
95
2019-12-07T06:25:31.000Z
2022-03-03T20:12:45.000Z
#!/bin/python3 import os # Complete the substrCount function below. if __name__ == '__main__': fptr = open(os.environ['OUTPUT_PATH'], 'w') n = int(input()) s = input() result = substrCount(n, s) fptr.write(str(result) + '\n') fptr.close()
21.40625
54
0.491971
#!/bin/python3 import os import itertools as it # Complete the substrCount function below. def substrCount(n, s): if n == 1: return 1 s = [list(g) for k, g in it.groupby(s)] res = sum([int(len(i)*(len(i)+1)/2) for i in s]) for i in range(len(s)): if i == 0 or i == l...
0
0
0
0
0
349
0
1
46
a3f0273346a8278f04244a2c77ce314bff0cac57
1,586
py
Python
tests/kiss_test_classes.py
xssfox/kiss
3d8b39f3e0dbf866b2530dcfac2df177c6fd07e3
[ "Apache-2.0" ]
76
2015-01-18T01:45:47.000Z
2022-02-01T00:04:02.000Z
tests/kiss_test_classes.py
xssfox/kiss
3d8b39f3e0dbf866b2530dcfac2df177c6fd07e3
[ "Apache-2.0" ]
10
2015-04-04T02:19:30.000Z
2021-08-30T18:27:34.000Z
tests/kiss_test_classes.py
xssfox/kiss
3d8b39f3e0dbf866b2530dcfac2df177c6fd07e3
[ "Apache-2.0" ]
38
2015-03-12T04:14:30.000Z
2022-03-20T14:03:45.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- """Tests for KISS Classes.""" __author__ = 'Greg Albrecht W2GMD <oss@undef.net>' # NOQA pylint: disable=R0801 __copyright__ = 'Copyright 2017 Greg Albrecht and Contributors' # NOQA pylint: disable=R0801 __license__ = 'Apache License, Version 2.0' # NOQA pylint: disable...
32.367347
93
0.688525
#!/usr/bin/env python # -*- coding: utf-8 -*- """Tests for KISS Classes.""" import logging import random import unittest import aprs from .context import kiss from . import constants __author__ = 'Greg Albrecht W2GMD <oss@undef.net>' # NOQA pylint: disable=R0801 __copyright__ = 'Copyright 2017 Greg Albrecht and ...
0
433
0
691
0
0
0
-25
159
ae8d6e961774823174c508eb00e995d52646126f
3,166
py
Python
cpp_linter/__init__.py
DingXuefeng/cpp-linter-action
9a09cb0d0c17a3c9e074afe31560261590053721
[ "MIT" ]
20
2021-04-28T16:01:18.000Z
2022-03-27T09:39:02.000Z
cpp_linter/__init__.py
DingXuefeng/cpp-linter-action
9a09cb0d0c17a3c9e074afe31560261590053721
[ "MIT" ]
39
2021-08-15T09:52:02.000Z
2022-03-31T14:57:42.000Z
cpp_linter/__init__.py
2bndy5/cpp-linter-action
b5962ce34397bce2b0f88772b22b65b5a5295fe5
[ "MIT" ]
9
2021-05-18T19:46:35.000Z
2022-03-21T21:59:05.000Z
"""The Base module of the `cpp_linter` package. This holds the objects shared by multiple modules.""" import io import os import logging FOUND_RICH_LIB = False try: from rich.logging import RichHandler FOUND_RICH_LIB = True logging.basicConfig( format="%(name)s: %(message)s", handlers=[Ri...
31.66
84
0.659823
"""The Base module of the `cpp_linter` package. This holds the objects shared by multiple modules.""" import io import os import logging FOUND_RICH_LIB = False try: from rich.logging import RichHandler FOUND_RICH_LIB = True logging.basicConfig( format="%(name)s: %(message)s", handlers=[Ri...
0
0
0
1,006
0
0
0
0
46
68f66e3580307c10734ba594d88113b536300087
1,530
py
Python
my_pygame/count_down.py
francis-clairicia/Py-Game-Case
af2da857f2ef758051ad3c174d77f5a2deab935d
[ "MIT" ]
6
2022-02-10T09:07:56.000Z
2022-02-10T10:36:18.000Z
my_pygame/count_down.py
francis-clairicia/Py-Game-Case
af2da857f2ef758051ad3c174d77f5a2deab935d
[ "MIT" ]
null
null
null
my_pygame/count_down.py
francis-clairicia/Py-Game-Case
af2da857f2ef758051ad3c174d77f5a2deab935d
[ "MIT" ]
null
null
null
# -*- coding: Utf-8 -*
28.867925
83
0.596078
# -*- coding: Utf-8 -* from .text import Text from .window import Window class CountDown(Text): __slots__ = ("__seconds", "__master", "__callback") def __init__(self, master: Window, seconds: int, format="{seconds}", **kwargs): Text.__init__(self, **kwargs) self.__seconds = int(seconds) ...
0
0
0
1,433
0
0
0
6
68
aec52a7bf75a868b756e99d1088d88e4bc17b122
1,475
py
Python
aioftx/options/stats/schemas.py
metta-team/aioftx
f5bd028e8bf40c55c1d4632802b792be113e0978
[ "MIT" ]
null
null
null
aioftx/options/stats/schemas.py
metta-team/aioftx
f5bd028e8bf40c55c1d4632802b792be113e0978
[ "MIT" ]
null
null
null
aioftx/options/stats/schemas.py
metta-team/aioftx
f5bd028e8bf40c55c1d4632802b792be113e0978
[ "MIT" ]
null
null
null
""" Option Volume """ """ Option Interest """
21.071429
85
0.776271
import datetime from aioftx.http import PaginatedRequest, PaginatedResponse from pydantic import BaseModel, Field """ Option Volume """ class OptionVolume(BaseModel): contracts: float underlying_total: float class Get24hrOptionVolumeRequest(PaginatedRequest): path = "/options/24hr_options_volumes" c...
0
0
0
1,023
0
0
0
48
343
fb28cc7206b054d20152f2e4309c053d11766a3f
12,557
py
Python
ecg/deprecated/scrape_metagenomes_from_jgi.py
ELIFE-ASU/ecg
f41f1374be638e85974b8443584dbf3378d59979
[ "MIT" ]
2
2019-08-15T09:57:10.000Z
2021-06-03T00:52:50.000Z
ecg/deprecated/scrape_metagenomes_from_jgi.py
ELIFE-ASU/ecg
f41f1374be638e85974b8443584dbf3378d59979
[ "MIT" ]
20
2019-06-12T09:09:52.000Z
2020-02-04T20:57:26.000Z
ecg/deprecated/scrape_metagenomes_from_jgi.py
ELIFE-ASU/ecg
f41f1374be638e85974b8443584dbf3378d59979
[ "MIT" ]
2
2019-07-18T06:11:42.000Z
2019-09-05T00:07:00.000Z
## jgi_metagenome_scraping """ Scrape individual metagenome EC numbers from JGI. `scrape_metagenomes_from_jgi` is the only function meant to be called directly. Usage: scrape_metagenomes_from_jgi.py SAVE_DIR scrape_metagenomes_from_jgi.py SAVE_DIR [--database=<db>] scrape_metagenomes_from_jgi.py SAVE_DIR [--home...
36.18732
200
0.720076
## jgi_metagenome_scraping """ Scrape individual metagenome EC numbers from JGI. `scrape_metagenomes_from_jgi` is the only function meant to be called directly. Usage: scrape_metagenomes_from_jgi.py SAVE_DIR scrape_metagenomes_from_jgi.py SAVE_DIR [--database=<db>] scrape_metagenomes_from_jgi.py SAVE_DIR [--home...
0
0
0
0
0
2,149
0
0
23
b589448870108b8384d02ffae142be9ddd6ea762
932
py
Python
2018/25a.py
msullivan/advent-of-code
ba4b0c3e229bca0f632d51d18ad72ecddd2405da
[ "MIT" ]
8
2016-12-01T19:41:50.000Z
2021-12-21T18:50:55.000Z
2018/25a.py
msullivan/advent-of-code
ba4b0c3e229bca0f632d51d18ad72ecddd2405da
[ "MIT" ]
null
null
null
2018/25a.py
msullivan/advent-of-code
ba4b0c3e229bca0f632d51d18ad72ecddd2405da
[ "MIT" ]
3
2018-12-23T06:58:47.000Z
2021-12-20T10:09:15.000Z
#!/usr/bin/env python3 import sys #from dataclasses import dataclass if __name__ == '__main__': sys.exit(main(sys.argv))
25.189189
84
0.522532
#!/usr/bin/env python3 from collections import defaultdict, deque import sys import re #from dataclasses import dataclass def extract(s): return [int(x) for x in re.findall(r'-?\d+', s)] def dist(x, y): return abs(x[0] - y[0]) + abs(x[1] - y[1]) + abs(x[2] - y[2]) + abs(x[3] - y[3]) def main(args): data...
0
0
0
0
0
683
0
9
114
a7a47765269246e3ee6f028960d3264b45404abc
1,729
py
Python
demo/demo/views.py
dresl/django-fullcalendar
4ba0bf0c207cad306ae7a14a324fa06f7a4e9f25
[ "MIT" ]
48
2015-01-10T08:01:27.000Z
2021-03-12T06:16:43.000Z
demo/demo/views.py
dresl/django-fullcalendar
4ba0bf0c207cad306ae7a14a324fa06f7a4e9f25
[ "MIT" ]
4
2015-02-13T23:02:31.000Z
2021-05-02T19:18:49.000Z
demo/demo/views.py
dresl/django-fullcalendar
4ba0bf0c207cad306ae7a14a324fa06f7a4e9f25
[ "MIT" ]
48
2015-01-07T11:37:27.000Z
2022-02-23T20:17:04.000Z
# This is just an example for this demo. You may get this value # from a separate file or anywhere you want OPTIONS = """{ timeFormat: "H:mm", header: { left: 'prev,next today', center: 'title', right: 'month,agendaWeek,agendaDay', ...
39.295455
112
0.522846
from django.shortcuts import render from django.http import HttpResponse from fullcalendar.models import CalendarEvent from fullcalendar.util import events_to_json, calendar_options # This is just an example for this demo. You may get this value # from a separate file or anywhere you want OPTIONS = """{ timeFormat:...
0
0
0
0
0
270
0
94
134
530c2f9293926aa63cfcce49afc28e2239fcd4aa
1,587
py
Python
module/passive/certificate.py
b1ackc4t/getdomain
0d1d31c9abf1d3293d113bff46c400b246434807
[ "Apache-2.0" ]
null
null
null
module/passive/certificate.py
b1ackc4t/getdomain
0d1d31c9abf1d3293d113bff46c400b246434807
[ "Apache-2.0" ]
null
null
null
module/passive/certificate.py
b1ackc4t/getdomain
0d1d31c9abf1d3293d113bff46c400b246434807
[ "Apache-2.0" ]
1
2021-11-24T09:22:38.000Z
2021-11-24T09:22:38.000Z
import urllib.request if __name__ == '__main__': main('hubu.edu.cn')
31.74
157
0.563327
import urllib.request import urllib.parse import re import asyncio import aiohttp from lib.base import * class Certificate(): def __init__(self, domain): self.domain_list = [] self.domain = domain self.headers = request_headers async def get_crtsh(self): timeout = aiohttp.Clie...
18
0
874
301
0
200
0
-27
156
ae308e8e420aba056d73d23e2f934b06bd7ba0d8
3,180
py
Python
optimizers/JAYA.py
VicZH/Evolutionary-Algorithm-Racing
e14eba3e5a2ea63cbbbd0ce4b7df514853cc6d22
[ "MIT" ]
null
null
null
optimizers/JAYA.py
VicZH/Evolutionary-Algorithm-Racing
e14eba3e5a2ea63cbbbd0ce4b7df514853cc6d22
[ "MIT" ]
null
null
null
optimizers/JAYA.py
VicZH/Evolutionary-Algorithm-Racing
e14eba3e5a2ea63cbbbd0ce4b7df514853cc6d22
[ "MIT" ]
null
null
null
""" JAYA Algorithm """
35.730337
85
0.556604
""" JAYA Algorithm """ import random import numpy from solution import solution class JAYA(solution): def __init__(self, objf, sol_shift, lb, ub, dim, PopSize, EvlNum): # Worst position initialization self.Worst_pos = numpy.zeros(dim) self.Worst_score = float(0) self.dim = dim ...
0
0
0
3,076
0
0
0
-9
90
ec4662db7a4542545474574d7ddb566d0e09dd09
1,830
py
Python
news_providers/rtve.py
zlotny/memorias-del-olvido
28d56626196f098ca9a24192776be176d3fcc92b
[ "MIT" ]
null
null
null
news_providers/rtve.py
zlotny/memorias-del-olvido
28d56626196f098ca9a24192776be176d3fcc92b
[ "MIT" ]
null
null
null
news_providers/rtve.py
zlotny/memorias-del-olvido
28d56626196f098ca9a24192776be176d3fcc92b
[ "MIT" ]
null
null
null
""" News provider for the site rtve.es Checks specifically the Alzheimer tag. Only checks news, not videos or audios """ from datetime import datetime from textwrap import dedent from lxml import html from lxml.cssselect import CSSSelector import requests URL = 'http://www.rtve.es/temas/alzheimer/1060/' SITE...
29.047619
100
0.636066
""" News provider for the site rtve.es Checks specifically the Alzheimer tag. Only checks news, not videos or audios """ from datetime import datetime from textwrap import dedent from lxml import html from lxml.cssselect import CSSSelector import requests URL = 'http://www.rtve.es/temas/alzheimer/1060/' SITE...
0
0
0
0
0
0
0
0
0
5468d3f3d83ae8dd42338b73c251c1856f9d5005
3,870
py
Python
CalcMIRExtinction.py
rclevy/Scripts
ca169bfc437e9cfa81e37a8f7e0c68a8f58b972e
[ "MIT" ]
1
2021-03-02T03:36:21.000Z
2021-03-02T03:36:21.000Z
CalcMIRExtinction.py
rclevy/Scripts
ca169bfc437e9cfa81e37a8f7e0c68a8f58b972e
[ "MIT" ]
null
null
null
CalcMIRExtinction.py
rclevy/Scripts
ca169bfc437e9cfa81e37a8f7e0c68a8f58b972e
[ "MIT" ]
null
null
null
#calculate the extinction between two bands #from Rieke & Lebofsky 1985 Table 3 import argparse parser=argparse.ArgumentParser( prog = 'CalcMIRExtinction', formatter_class=argparse.RawDescriptionHelpFormatter, description='''Calculate the MIR extinction and flux ratios between two wavelengths or bands based on Rie...
41.612903
174
0.721447
#calculate the extinction between two bands #from Rieke & Lebofsky 1985 Table 3 import argparse parser=argparse.ArgumentParser( prog = 'CalcMIRExtinction', formatter_class=argparse.RawDescriptionHelpFormatter, description='''Calculate the MIR extinction and flux ratios between two wavelengths or bands based on Rie...
0
0
0
0
0
0
0
0
0
78fe3893c2d308f27b4e60a715c468bf051b4e78
1,075
py
Python
bach/tests/unit/sql_models/test_model_escape_format.py
objectiv/objectiv-analytics
86ec1508f71c2d61ea7d67479800e4dc417a46e1
[ "Apache-2.0" ]
23
2021-11-10T21:37:42.000Z
2022-03-30T11:46:19.000Z
bach/tests/unit/sql_models/test_model_escape_format.py
objectiv/objectiv-analytics
86ec1508f71c2d61ea7d67479800e4dc417a46e1
[ "Apache-2.0" ]
163
2021-11-10T10:11:26.000Z
2022-03-31T16:04:27.000Z
bach/tests/unit/sql_models/test_model_escape_format.py
objectiv/objectiv-analytics
86ec1508f71c2d61ea7d67479800e4dc417a46e1
[ "Apache-2.0" ]
null
null
null
""" Copyright 2022 Objectiv B.V. """ import pytest from sql_models.model import escape_format_string pytestmark = [pytest.mark.db_independent] # mark all tests here as database independent. def assert_escape_compare_value(value): """ helper for test__escape_value. Assert that the escaped value, after formatting...
37.068966
109
0.72186
""" Copyright 2022 Objectiv B.V. """ import pytest from sql_models.model import escape_format_string pytestmark = [pytest.mark.db_independent] # mark all tests here as database independent. def assert_escape_compare_value(value): """ helper for test__escape_value. Assert that the escaped value, after formatting...
0
0
0
0
0
517
0
0
23
88f7d4f26d1f59e448d93c7d68d03b86631a3b13
14,038
py
Python
agent_configs.py
davidlarcher/WindAI
129941f4a3eb1d632d326cd90b7a244ae1cc558e
[ "Apache-2.0" ]
null
null
null
agent_configs.py
davidlarcher/WindAI
129941f4a3eb1d632d326cd90b7a244ae1cc558e
[ "Apache-2.0" ]
null
null
null
agent_configs.py
davidlarcher/WindAI
129941f4a3eb1d632d326cd90b7a244ae1cc558e
[ "Apache-2.0" ]
null
null
null
number_of_workers = 4 config_SAC = { # "gamma": 0.5, # === Model === # Use two Q-networks (instead of one) for action-value estimation. # Note: Each Q-network will have its own target network. "twin_q": True, # Use a e.g. conv2D state preprocessing network before concatenating the # result...
43.732087
95
0.683146
number_of_workers = 4 config_SAC = { # "gamma": 0.5, # === Model === # Use two Q-networks (instead of one) for action-value estimation. # Note: Each Q-network will have its own target network. "twin_q": True, # Use a e.g. conv2D state preprocessing network before concatenating the # result...
0
0
0
0
0
0
0
0
0
4a10c6af6f00d1fbef221397bb0f2553d1e966c5
4,251
py
Python
server/catgenome/demo_scripts/reg_file.py
ismael-dev88/NGB
7d5e74489968d3ec6edfbf65e1599b982d49141c
[ "MIT" ]
1
2017-08-22T09:42:22.000Z
2017-08-22T09:42:22.000Z
server/catgenome/demo_scripts/reg_file.py
react-dev26/NGB-master
b3646f92d7d9802d5bb83ac4b7a59031b2fe71a7
[ "MIT" ]
null
null
null
server/catgenome/demo_scripts/reg_file.py
react-dev26/NGB-master
b3646f92d7d9802d5bb83ac4b7a59031b2fe71a7
[ "MIT" ]
null
null
null
base_url = "http://localhost:8080/catgenome/restapi/{0}/register" file_types = { 'vcf': "vcf", 'vcf.gz': "vcf", 'gff': "gene", 'gtf': "gene", 'gff.gz': "gene", 'gtf.gz': "gene", 'gff3': "gene", 'gff3.gz': "gene", 'bam':"bam", 'seg':'seg', 'seg.gz':'seg', 'bw':'wig', 'bed':'bed', 'bed.gz':"bed", 'vg': "v...
28.530201
133
0.677252
import requests import json import argparse import sys import os.path import urlparse import urllib base_url = "http://localhost:8080/catgenome/restapi/{0}/register" file_types = { 'vcf': "vcf", 'vcf.gz': "vcf", 'gff': "gene", 'gtf': "gene", 'gff.gz': "gene", 'gtf.gz': "gene", 'gff3': "gene", 'gff3.gz': "gene"...
0
0
0
0
0
3,640
0
-54
269
416ea2402ef33ccc2bafa752d77c2a9d40e6a93c
5,354
py
Python
Python/keithley2400_old.py
ultpnml/ult_instruments
3c9dd6b26e993bba3e20c7f91af6510152850cfd
[ "BSD-3-Clause" ]
null
null
null
Python/keithley2400_old.py
ultpnml/ult_instruments
3c9dd6b26e993bba3e20c7f91af6510152850cfd
[ "BSD-3-Clause" ]
null
null
null
Python/keithley2400_old.py
ultpnml/ult_instruments
3c9dd6b26e993bba3e20c7f91af6510152850cfd
[ "BSD-3-Clause" ]
null
null
null
#keithley2400.py #Controls Keithley 2400 SourceMeter through RS232 #Assumes COM3, 9600 Baud, line feed as termination character #Uses pyserial #Dillon Wong 11/03/2018
37.180556
77
0.541651
#keithley2400.py #Controls Keithley 2400 SourceMeter through RS232 #Assumes COM3, 9600 Baud, line feed as termination character #Uses pyserial #Dillon Wong 11/03/2018 import serial import time class keithley2400: def __init__(self, com_port = 'COM3'): self.keithley = serial.Serial(com_port, 9600, timeout...
0
0
0
5,137
0
0
0
-18
68
8e7f45cb933884793bd562624866fb1a0f206505
2,940
py
Python
src/KENN2/parsers.py
DanieleAlessandro/KENN2
949620ca1734e85239115954b88370393d97a42e
[ "BSD-3-Clause" ]
6
2020-12-23T11:56:14.000Z
2022-02-10T10:28:09.000Z
src/KENN2/parsers.py
DanieleAlessandro/KENN2
949620ca1734e85239115954b88370393d97a42e
[ "BSD-3-Clause" ]
null
null
null
src/KENN2/parsers.py
DanieleAlessandro/KENN2
949620ca1734e85239115954b88370393d97a42e
[ "BSD-3-Clause" ]
1
2021-03-20T16:18:34.000Z
2021-03-20T16:18:34.000Z
from KENN2.layers.residual.KnowledgeEnhancer import KnowledgeEnhancer from KENN2.layers.Kenn import Kenn from KENN2.layers.RelationalKENN import RelationalKENN def unary_parser(knowledge_file, activation=lambda x: x, initial_clause_weight=0.5, save_training_data=False, **kwargs): """ Takes in input the knowle...
36.296296
120
0.671088
from KENN2.layers.residual.KnowledgeEnhancer import KnowledgeEnhancer from KENN2.layers.Kenn import Kenn from KENN2.layers.RelationalKENN import RelationalKENN def unary_parser(knowledge_file, activation=lambda x: x, initial_clause_weight=0.5, save_training_data=False, **kwargs): """ Takes in input the knowle...
0
0
0
0
0
0
0
0
0
46de5f09dfad2ee5f6d5bb815bcf5b31b7fbb004
11,983
py
Python
deprecated/symbolic_regression/environment.py
jfrfonseca/symbolic_regression
4639fafd92796df2f0696e04c354289915819d5e
[ "MIT" ]
null
null
null
deprecated/symbolic_regression/environment.py
jfrfonseca/symbolic_regression
4639fafd92796df2f0696e04c354289915819d5e
[ "MIT" ]
null
null
null
deprecated/symbolic_regression/environment.py
jfrfonseca/symbolic_regression
4639fafd92796df2f0696e04c354289915819d5e
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: UTF-8 -*- """__init__.py: Basic requirements for the module.""" __license__ = "MIT" __author__ = "Jos Fonseca" __copyright__ = "Copyright (c) 2020 Jos F. R. Fonseca" # =====================================================================================================...
49.110656
137
0.64241
#!/usr/bin/env python # -*- coding: UTF-8 -*- """__init__.py: Basic requirements for the module.""" __license__ = "MIT" __author__ = "José Fonseca" __copyright__ = "Copyright (c) 2020 José F. R. Fonseca" # ===================================================================================================...
4
49
0
11,091
0
0
0
134
224