hexsha
stringlengths
40
40
size
int64
4
1.02M
ext
stringclasses
8 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
209
max_stars_repo_name
stringlengths
5
121
max_stars_repo_head_hexsha
stringlengths
40
40
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
209
max_issues_repo_name
stringlengths
5
121
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
209
max_forks_repo_name
stringlengths
5
121
max_forks_repo_head_hexsha
stringlengths
40
40
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
4
1.02M
avg_line_length
float64
1.07
66.1k
max_line_length
int64
4
266k
alphanum_fraction
float64
0.01
1
522ffb6fe0b4c3f9c1d46796a54983ebbc2182c3
438
py
Python
thinkpython_allen_downey/exercise_6_5.py
alirkaya/programming-textbook-solutions
7362dce474b8a881d654f95604e09d1d0e76aec2
[ "MIT" ]
null
null
null
thinkpython_allen_downey/exercise_6_5.py
alirkaya/programming-textbook-solutions
7362dce474b8a881d654f95604e09d1d0e76aec2
[ "MIT" ]
null
null
null
thinkpython_allen_downey/exercise_6_5.py
alirkaya/programming-textbook-solutions
7362dce474b8a881d654f95604e09d1d0e76aec2
[ "MIT" ]
null
null
null
def ack(m, n): if m < 0 or n < 0: return -1 elif m == 0: return n+1 elif n == 0: return ack(m-1, 1) else: return ack(m-1, ack(m, n-1)) print(ack(3, 4)) # For large values of m and n, the function gives RecursionError. Because, # by default, there is a fixed number of re...
27.375
81
0.614155
69419c4414e47f7c862e377d3dfa69a12df5b5d0
10,480
py
Python
openscad_libraries/NopSCADlib/scripts/bom.py
hongming/feixingchuan
3e3420fe401dfd2385594bd0da11caf01eb753d3
[ "MIT" ]
null
null
null
openscad_libraries/NopSCADlib/scripts/bom.py
hongming/feixingchuan
3e3420fe401dfd2385594bd0da11caf01eb753d3
[ "MIT" ]
null
null
null
openscad_libraries/NopSCADlib/scripts/bom.py
hongming/feixingchuan
3e3420fe401dfd2385594bd0da11caf01eb753d3
[ "MIT" ]
null
null
null
#!/usr/bin/env python # # NopSCADlib Copyright Chris Palmer 2018 # nop.head@gmail.com # hydraraptor.blogspot.com # # This file is part of NopSCADlib. # # NopSCADlib 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 Software Foundatio...
35.167785
132
0.489504
36db47ef1c58b68b89f4cbef735f01acd3170c7a
1,188
py
Python
Analysis_software/marspy/stats.py
duderstadt-lab/Born-to-slide
00f3a7ef4aaefff636ae7ddbb9e1c9947b284967
[ "BSD-2-Clause" ]
null
null
null
Analysis_software/marspy/stats.py
duderstadt-lab/Born-to-slide
00f3a7ef4aaefff636ae7ddbb9e1c9947b284967
[ "BSD-2-Clause" ]
null
null
null
Analysis_software/marspy/stats.py
duderstadt-lab/Born-to-slide
00f3a7ef4aaefff636ae7ddbb9e1c9947b284967
[ "BSD-2-Clause" ]
null
null
null
import numpy as np from sklearn.utils import resample def bootstrap(data, n_boot=10000, sample_size=1, estimator=np.mean): """ :param data: array with data :param n_boot: number for bootstrapping iterations (default 10000) :param sample_size: sample coverage ]0;1] (default 1) :param estimator: def...
27.627907
102
0.643098
851f1f1ca5d658f8a88669a24c4094e400005ad4
4,627
py
Python
source/app/simple_cfar_clustering.py
WinterWinds-Robotics/pymmw
3e2841f24a6cd98ccbee10a0ee7479f394417708
[ "MIT" ]
null
null
null
source/app/simple_cfar_clustering.py
WinterWinds-Robotics/pymmw
3e2841f24a6cd98ccbee10a0ee7479f394417708
[ "MIT" ]
null
null
null
source/app/simple_cfar_clustering.py
WinterWinds-Robotics/pymmw
3e2841f24a6cd98ccbee10a0ee7479f394417708
[ "MIT" ]
null
null
null
# # Copyright (c) 2019, Manfred Constapel # This file is licensed under the terms of the MIT license. # # # super-simple CFAR clustering # import os import sys try: import numpy as np import matplotlib as mpl import matplotlib.pyplot as plt __base__ = os.path.dirname(os.path.abspath...
28.213415
141
0.494489
6983d44e76e06a201faf18d1e3f8e8d0d78ffd34
572
py
Python
sacred/__about__.py
ssudholt/sacred
6fb05b1ee1b7706b44c3ebd852e1e234841ea2ce
[ "MIT" ]
1
2019-06-12T00:31:12.000Z
2019-06-12T00:31:12.000Z
sacred/__about__.py
ssudholt/sacred
6fb05b1ee1b7706b44c3ebd852e1e234841ea2ce
[ "MIT" ]
null
null
null
sacred/__about__.py
ssudholt/sacred
6fb05b1ee1b7706b44c3ebd852e1e234841ea2ce
[ "MIT" ]
null
null
null
#!/usr/bin/env python # coding=utf-8 """ This module contains meta-information about the Sacred package. It is kept simple and separate from the main module, because this information is also read by the setup.py. And during installation the sacred module cannot yet be imported. """ from __future__ import division, pri...
28.6
78
0.767483
2734c265a97e11d0eb2ccdba85cda7564e3ad825
1,878
py
Python
azure-mgmt-monitor/azure/mgmt/monitor/models/rule_email_action_py3.py
lmazuel/azure-sdk-for-python
b40e0e36cc00a82b7f8ca2fa599b1928240c98b5
[ "MIT" ]
1
2022-03-30T22:39:15.000Z
2022-03-30T22:39:15.000Z
azure-mgmt-monitor/azure/mgmt/monitor/models/rule_email_action_py3.py
lmazuel/azure-sdk-for-python
b40e0e36cc00a82b7f8ca2fa599b1928240c98b5
[ "MIT" ]
54
2016-03-25T17:25:01.000Z
2018-10-22T17:27:54.000Z
azure-mgmt-monitor/azure/mgmt/monitor/models/rule_email_action_py3.py
lmazuel/azure-sdk-for-python
b40e0e36cc00a82b7f8ca2fa599b1928240c98b5
[ "MIT" ]
2
2017-01-20T18:25:46.000Z
2017-05-12T21:31:47.000Z
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. # # Code generated by Microsoft (R) AutoRest Code Generator. # Changes ...
39.957447
99
0.651225
b6235d10ebec1f9027bac36f296e4a6f6b9bc605
2,739
py
Python
dadvisor/datatypes/container_info.py
dadvisor/core
31d59707eb9bf33f5bea4a8fb6fb1f0de9a37eba
[ "MIT" ]
null
null
null
dadvisor/datatypes/container_info.py
dadvisor/core
31d59707eb9bf33f5bea4a8fb6fb1f0de9a37eba
[ "MIT" ]
null
null
null
dadvisor/datatypes/container_info.py
dadvisor/core
31d59707eb9bf33f5bea4a8fb6fb1f0de9a37eba
[ "MIT" ]
null
null
null
import json import subprocess import time from prometheus_client import Info from dadvisor.config import IP INFO = Info('docker_container', 'Container info', ['hash']) class ContainerInfo(object): """ Creates a ContainerInfo object with several properties. Note that the ip property is added later (in :...
33.814815
110
0.490325
6276c9a9fa86d34a675e1e3ba15c8bb55e54480a
2,359
py
Python
take_screenshots.py
ClaudeMetz/FactorioScripts
5aab7569acdf86ff65167584638a3dd7323d2d0b
[ "MIT" ]
2
2020-12-26T12:21:33.000Z
2022-02-06T23:25:10.000Z
take_screenshots.py
ClaudeMetz/FactorioScripts
5aab7569acdf86ff65167584638a3dd7323d2d0b
[ "MIT" ]
null
null
null
take_screenshots.py
ClaudeMetz/FactorioScripts
5aab7569acdf86ff65167584638a3dd7323d2d0b
[ "MIT" ]
null
null
null
import json import shutil import subprocess import sys from pathlib import Path import git # type: ignore from PIL import Image # type: ignore # Script config MODNAME = sys.argv[1] FACTORIO_PATH = sys.argv[2] USERDATA_PATH = sys.argv[3] cwd = Path.cwd() repo = git.Repo(cwd) def take_screenshots(): screenshott...
32.315068
92
0.647732
de192b6a2eebb68253930a5fae2bb136a8fa0d9a
71,252
py
Python
tensor2tensor/utils/t2t_model.py
Zhangyantsing/tensor2tensor
b6abf28a1a903c91eb75d7a102945a780899d6e9
[ "Apache-2.0" ]
1
2018-12-12T18:50:28.000Z
2018-12-12T18:50:28.000Z
tensor2tensor/utils/t2t_model.py
Zhangyantsing/tensor2tensor
b6abf28a1a903c91eb75d7a102945a780899d6e9
[ "Apache-2.0" ]
null
null
null
tensor2tensor/utils/t2t_model.py
Zhangyantsing/tensor2tensor
b6abf28a1a903c91eb75d7a102945a780899d6e9
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # Copyright 2018 The Tensor2Tensor Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable...
38.473002
84
0.662648
948a57feb5e8d5dd6bff822d8b929adbc9214049
461
py
Python
CreateMasks.py
genigarus/CreateImageOverlaysandDepthMask
90aa3362970c6e27459995dfb71134691fc10220
[ "Apache-2.0" ]
null
null
null
CreateMasks.py
genigarus/CreateImageOverlaysandDepthMask
90aa3362970c6e27459995dfb71134691fc10220
[ "Apache-2.0" ]
null
null
null
CreateMasks.py
genigarus/CreateImageOverlaysandDepthMask
90aa3362970c6e27459995dfb71134691fc10220
[ "Apache-2.0" ]
null
null
null
import glob from PIL import Image out = r"D:\Development\TSAI\EVA\MaskRCNN Dataset\Foreground\masks\{}" path = r"D:\Development\TSAI\EVA\MaskRCNN Dataset\Foreground\resize\*.*" for file in glob.glob(path): im = Image.open(file, 'r') file_name = file.split("\\")[-1] rgb_data = im.tobytes("raw", "RGB") ...
30.733333
72
0.678959
abee95fdaf26f13b273ab160923ce0be64258f09
1,406
py
Python
Solver/FDM/VectorGenerater.py
atily17/research
0e762e03747995c8a7d1d8a2ec42be31a17209dc
[ "BSD-3-Clause" ]
null
null
null
Solver/FDM/VectorGenerater.py
atily17/research
0e762e03747995c8a7d1d8a2ec42be31a17209dc
[ "BSD-3-Clause" ]
null
null
null
Solver/FDM/VectorGenerater.py
atily17/research
0e762e03747995c8a7d1d8a2ec42be31a17209dc
[ "BSD-3-Clause" ]
1
2022-02-25T06:38:29.000Z
2022-02-25T06:38:29.000Z
import numpy as np class VectorGenerater(object): def generate(self, problem, grid): nodes = grid.node.nodes vector = np.zeros(len(nodes)) for i in range(len(nodes)): if nodes[i]["position"][0] == "i": vector[i] = problem.source.source(nodes[i]["point"]) ...
54.076923
96
0.495021
4decbf4240689040244d9296583939d60a9dcd59
2,499
py
Python
azure-mgmt-web/azure/mgmt/web/models/operation.py
JonathanGailliez/azure-sdk-for-python
f0f051bfd27f8ea512aea6fc0c3212ee9ee0029b
[ "MIT" ]
1
2021-09-07T18:36:04.000Z
2021-09-07T18:36:04.000Z
azure-mgmt-web/azure/mgmt/web/models/operation.py
JonathanGailliez/azure-sdk-for-python
f0f051bfd27f8ea512aea6fc0c3212ee9ee0029b
[ "MIT" ]
2
2019-10-02T23:37:38.000Z
2020-10-02T01:17:31.000Z
azure-mgmt-web/azure/mgmt/web/models/operation.py
JonathanGailliez/azure-sdk-for-python
f0f051bfd27f8ea512aea6fc0c3212ee9ee0029b
[ "MIT" ]
1
2019-06-17T22:18:23.000Z
2019-06-17T22:18:23.000Z
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. # # Code generated by Microsoft (R) AutoRest Code Generator. # Changes ...
43.086207
82
0.62425
f59c3e593d31f3f4d336a2c5a8e7a5bd01c60561
3,941
py
Python
appengine/integration_tests/deploy_check.py
JonathanRRogers/runtimes-common
6b69050bed4389763ddff8e1b9ec48f12ac32fc5
[ "Apache-2.0" ]
95
2016-09-09T23:36:36.000Z
2022-03-05T20:06:00.000Z
appengine/integration_tests/deploy_check.py
JonathanRRogers/runtimes-common
6b69050bed4389763ddff8e1b9ec48f12ac32fc5
[ "Apache-2.0" ]
392
2016-09-13T15:15:57.000Z
2022-02-22T01:18:23.000Z
appengine/integration_tests/deploy_check.py
JonathanRRogers/runtimes-common
6b69050bed4389763ddff8e1b9ec48f12ac32fc5
[ "Apache-2.0" ]
73
2016-09-08T19:27:03.000Z
2021-07-08T13:28:18.000Z
#!/usr/bin/python # Copyright 2017 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 applica...
33.974138
75
0.639685
07c18fd20821623e5214aa901eaf2ca4ccdd8c1e
1,504
py
Python
nginx/tests/test_vts.py
mchelen-gov/integrations-core
81281600b3cc7025a7a32148c59620c9592a564f
[ "BSD-3-Clause" ]
663
2016-08-23T05:23:45.000Z
2022-03-29T00:37:23.000Z
nginx/tests/test_vts.py
mchelen-gov/integrations-core
81281600b3cc7025a7a32148c59620c9592a564f
[ "BSD-3-Clause" ]
6,642
2016-06-09T16:29:20.000Z
2022-03-31T22:24:09.000Z
nginx/tests/test_vts.py
mchelen-gov/integrations-core
81281600b3cc7025a7a32148c59620c9592a564f
[ "BSD-3-Clause" ]
1,222
2017-01-27T15:51:38.000Z
2022-03-31T18:17:51.000Z
# (C) Datadog, Inc. 2018-present # All rights reserved # Licensed under a 3-clause BSD style license (see LICENSE) import pytest from datadog_checks.nginx import VTS_METRIC_MAP from .common import TAGS, USING_VTS pytestmark = pytest.mark.skipif(not USING_VTS, reason='Not using VTS') @pytest.mark.usefixtures('dd_en...
33.422222
72
0.684176
6af110291a019161aa7987ab19e03fdb618b7e3f
8,161
py
Python
package_control/deps/oscrypto/_win/trust_list.py
tower000/sublime_package_control
db53090bd0920ca2c58ef27f0361a4d7b096df0e
[ "MIT", "Unlicense" ]
3
2019-06-06T00:13:44.000Z
2020-08-16T20:11:13.000Z
package_control/deps/oscrypto/_win/trust_list.py
Allyn69/package_control
f78578ed67529e263fb1f4e4f90f92295830560f
[ "MIT", "Unlicense" ]
null
null
null
package_control/deps/oscrypto/_win/trust_list.py
Allyn69/package_control
f78578ed67529e263fb1f4e4f90f92295830560f
[ "MIT", "Unlicense" ]
1
2021-07-26T00:35:53.000Z
2021-07-26T00:35:53.000Z
# coding: utf-8 from __future__ import unicode_literals, division, absolute_import, print_function import datetime import hashlib import struct from ...asn1crypto.x509 import Certificate from .._ffi import ( array_from_pointer, buffer_from_bytes, bytes_from_buffer, cast, deref, is_null, n...
35.79386
98
0.591349
52aa4a9fcec34db7fdcc3bca4a48e2d59cdc3e72
3,130
py
Python
mjrl/utils/logger.py
xtwentian3/mjrl
e403c67c165e37d933a4bee8f80771d1046b51f3
[ "Apache-2.0" ]
null
null
null
mjrl/utils/logger.py
xtwentian3/mjrl
e403c67c165e37d933a4bee8f80771d1046b51f3
[ "Apache-2.0" ]
null
null
null
mjrl/utils/logger.py
xtwentian3/mjrl
e403c67c165e37d933a4bee8f80771d1046b51f3
[ "Apache-2.0" ]
null
null
null
import matplotlib matplotlib.use('Agg') import matplotlib.pyplot as plt import numpy as np import scipy import pickle import os import csv class DataLog: def __init__(self): self.log = {} self.max_len = 0 def log_kv(self, key, value): # logs the (key, value) pair # TODO: This...
35.168539
100
0.554633
156b4c21bd77fad235ddb2847e6906beb5ea5256
5,581
py
Python
superset/importexport/api.py
Human-Security-Insights/superset
a8e7624eb5635ed9b84f1454d35029e1c18ebdee
[ "Apache-2.0" ]
1
2022-02-10T11:30:05.000Z
2022-02-10T11:30:05.000Z
superset/importexport/api.py
Human-Security-Insights/superset
a8e7624eb5635ed9b84f1454d35029e1c18ebdee
[ "Apache-2.0" ]
10
2022-01-05T01:31:07.000Z
2022-03-16T01:09:46.000Z
superset/importexport/api.py
Human-Security-Insights/superset
a8e7624eb5635ed9b84f1454d35029e1c18ebdee
[ "Apache-2.0" ]
1
2022-03-09T02:57:17.000Z
2022-03-09T02:57:17.000Z
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
34.030488
89
0.576778
073523ae945b3f906234434ebcd14e86b8e4a8ef
2,450
py
Python
case/__final__/02_concrete1.py
BlockResearchGroup/WS_structural-design
9a1222e728f5f2ea32d40624b61440fe97f1f9b8
[ "MIT" ]
1
2021-01-12T15:36:53.000Z
2021-01-12T15:36:53.000Z
case/__final__/02_concrete1.py
compas-Workshops/WS_structural-design
9a1222e728f5f2ea32d40624b61440fe97f1f9b8
[ "MIT" ]
null
null
null
case/__final__/02_concrete1.py
compas-Workshops/WS_structural-design
9a1222e728f5f2ea32d40624b61440fe97f1f9b8
[ "MIT" ]
2
2019-05-10T16:05:26.000Z
2019-06-11T16:24:48.000Z
from __future__ import absolute_import from __future__ import division from __future__ import print_function from compas.utilities import pairwise from compas.datastructures import mesh_flip_cycles from compas.datastructures import Mesh from compas_rhino.artists import MeshArtist mesh = Mesh.from_json('cablenet.jso...
28.823529
80
0.58
1aee9bc4a882e5281a9be9f475238a390c5e8785
174
py
Python
ewah_bool_utils/__init__.py
neutrinoceros/ewah_bool_utils
54e7a3c00c538dfd9d3d02df2f4a271907cd212c
[ "BSD-3-Clause" ]
null
null
null
ewah_bool_utils/__init__.py
neutrinoceros/ewah_bool_utils
54e7a3c00c538dfd9d3d02df2f4a271907cd212c
[ "BSD-3-Clause" ]
null
null
null
ewah_bool_utils/__init__.py
neutrinoceros/ewah_bool_utils
54e7a3c00c538dfd9d3d02df2f4a271907cd212c
[ "BSD-3-Clause" ]
null
null
null
"""Top-level package for EWAH Bool Utils.""" __author__ = """Navaneeth Suresh""" __email__ = 'navaneeths1998@gmail.com' __version__ = '0.1.0' from .ewah_bool_wrap import *
21.75
44
0.718391
0eb77234ad47a6dd5dea13b1109681afaca694e4
297
py
Python
meridian/tst/acupoints/test_jinmen12.py
sinotradition/meridian
8c6c1762b204b72346be4bbfb74dedd792ae3024
[ "Apache-2.0" ]
5
2015-12-14T15:14:23.000Z
2022-02-09T10:15:33.000Z
meridian/tst/acupoints/test_jinmen12.py
sinotradition/meridian
8c6c1762b204b72346be4bbfb74dedd792ae3024
[ "Apache-2.0" ]
null
null
null
meridian/tst/acupoints/test_jinmen12.py
sinotradition/meridian
8c6c1762b204b72346be4bbfb74dedd792ae3024
[ "Apache-2.0" ]
3
2015-11-27T05:23:49.000Z
2020-11-28T09:01:56.000Z
#!/usr/bin/python #coding=utf-8 ''' @author: sheng @license: ''' import unittest from meridian.acupoints import jinmen12 class TestJinmen12Functions(unittest.TestCase): def setUp(self): pass def test_xxx(self): pass if __name__ == '__main__': unittest.main()
11.88
47
0.659933
0d9d74f1a6e59a1389ccb3cbf61a17c097debbd0
596
py
Python
sphinx_gallery/tests/tinybuild/examples/future/plot_future_imports.py
andriyor/sphinx-gallery
cc53540162613850c5bb19fa1172a1be960b1484
[ "BSD-3-Clause" ]
309
2015-01-18T23:00:29.000Z
2022-03-24T15:27:51.000Z
sphinx_gallery/tests/tinybuild/examples/future/plot_future_imports.py
andriyor/sphinx-gallery
cc53540162613850c5bb19fa1172a1be960b1484
[ "BSD-3-Clause" ]
891
2015-01-04T19:45:44.000Z
2022-03-31T02:36:49.000Z
sphinx_gallery/tests/tinybuild/examples/future/plot_future_imports.py
andriyor/sphinx-gallery
cc53540162613850c5bb19fa1172a1be960b1484
[ "BSD-3-Clause" ]
197
2015-01-27T13:14:14.000Z
2022-03-28T20:16:39.000Z
""" Test __future__ imports across cells ------------------------------------ This example tests that __future__ imports works across cells. """ from __future__ import division from __future__ import print_function import matplotlib #################### # Dummy section, with :func:`sphinx_gallery.backreferences.Name...
25.913043
75
0.684564
e226afcedde04a1a49d46925fbb066d93955db0e
7,012
py
Python
src/pyFun/main.py
hardikparwana/segway_sim
792c8ed9e6e26e3e28e5f120be6822f178f17bf2
[ "MIT" ]
10
2020-10-08T03:16:25.000Z
2021-10-19T02:58:53.000Z
src/pyFun/main.py
hardikparwana/segway_sim
792c8ed9e6e26e3e28e5f120be6822f178f17bf2
[ "MIT" ]
null
null
null
src/pyFun/main.py
hardikparwana/segway_sim
792c8ed9e6e26e3e28e5f120be6822f178f17bf2
[ "MIT" ]
5
2020-10-07T22:14:12.000Z
2022-02-21T01:22:21.000Z
import sys import pdb import scipy.io as sio import numpy as np import pickle from utils import * from MOMDP import MOMDP, MOMDP_TOQ, MOMDP_TO, MOMDP_Q import os def main(): load = 1 # 0 = compute policy and save policy object, 1 = load policy object, -1 = compute policy but DO NOT save it digitsResults = ...
43.283951
126
0.700656
fc66218f6e4aadb48cbabc589260e2859e1f6ff6
409
py
Python
selenium/zadania/zadanie_1.py
lblaszkowski/jaktestowac
e8f0af228792a5a2cfa7c7845c9e70869a275a5b
[ "Apache-2.0" ]
null
null
null
selenium/zadania/zadanie_1.py
lblaszkowski/jaktestowac
e8f0af228792a5a2cfa7c7845c9e70869a275a5b
[ "Apache-2.0" ]
null
null
null
selenium/zadania/zadanie_1.py
lblaszkowski/jaktestowac
e8f0af228792a5a2cfa7c7845c9e70869a275a5b
[ "Apache-2.0" ]
null
null
null
# Rekruter chce sprawdzić, że nie tylko potrafisz przepisać kod z tutoriala więc prosi Ciebie # abyś przetestował stronę wylosowaną przez https://www.discuvver.com/ (kliknij Take me to a useful website!). from selenium import webdriver driver = webdriver.Chrome() driver.get('http://e.ggtimer.com/') title = driver.titl...
34.083333
110
0.762836
e3f62008a5ec6599b27eff3201c75d80ba919a56
791
py
Python
client/sources/scheme_test/__init__.py
akshitdewan/ok-client
3c5eca17100eed808023a815654cfe1c95179080
[ "Apache-2.0" ]
30
2018-07-10T17:32:49.000Z
2022-01-03T16:50:56.000Z
client/sources/scheme_test/__init__.py
akshitdewan/ok-client
3c5eca17100eed808023a815654cfe1c95179080
[ "Apache-2.0" ]
62
2018-08-07T18:43:33.000Z
2022-02-17T20:53:03.000Z
client/sources/scheme_test/__init__.py
akshitdewan/ok-client
3c5eca17100eed808023a815654cfe1c95179080
[ "Apache-2.0" ]
26
2018-11-13T22:12:47.000Z
2022-03-20T00:42:26.000Z
from client import exceptions as ex from client.sources.scheme_test import models import os def load(file, _, assign): """Loads Scheme tests from a specified filepath. PARAMETERS: file -- str; a filepath to a Scheme file. RETURNS: Test """ if not os.path.isfile(file) or not file.endswith(...
29.296296
85
0.610619
228bd0d2dc82d566181dc14633ce494804d50e6e
3,507
py
Python
tests/data/test_topology.py
vasp-dev/py4vasp
576c5c23d740b11687e37b6dd332165bc339cf16
[ "Apache-2.0" ]
27
2022-02-18T18:43:17.000Z
2022-03-29T22:05:41.000Z
tests/data/test_topology.py
vasp-dev/py4vasp
576c5c23d740b11687e37b6dd332165bc339cf16
[ "Apache-2.0" ]
3
2022-02-18T18:52:33.000Z
2022-03-28T13:26:59.000Z
tests/data/test_topology.py
vasp-dev/py4vasp
576c5c23d740b11687e37b6dd332165bc339cf16
[ "Apache-2.0" ]
4
2022-02-07T12:21:23.000Z
2022-03-13T21:36:03.000Z
# Copyright © VASP Software GmbH, # Licensed under the Apache License 2.0 (http://www.apache.org/licenses/LICENSE-2.0) from py4vasp.data import Topology from py4vasp.data._selection import Selection import py4vasp.exceptions as exception import py4vasp._util.selection as selection import pytest import numpy as np impor...
33.4
87
0.629598
4ac7b77e5fbd5ae28e5ce8671da533db0767e31e
13,603
py
Python
hubtraf/user.py
dfeddema/hubtraf
379ddc1fd747d9a6658965462da458c571d4aef8
[ "BSD-3-Clause" ]
null
null
null
hubtraf/user.py
dfeddema/hubtraf
379ddc1fd747d9a6658965462da458c571d4aef8
[ "BSD-3-Clause" ]
null
null
null
hubtraf/user.py
dfeddema/hubtraf
379ddc1fd747d9a6658965462da458c571d4aef8
[ "BSD-3-Clause" ]
null
null
null
from enum import Enum, auto import aiohttp import socket import uuid import random from yarl import URL import asyncio import async_timeout import structlog import time import colorama logger = structlog.get_logger() class User: class States(Enum): CLEAR = 1 LOGGED_IN = 2 SERVER_STARTED =...
42.642633
141
0.556936
81cba28dcd0c68cc57e928cf586de92b228bc2a3
1,027
py
Python
pytudes/_2021/educative/grokking_the_coding_interview/sliding_window/_1__maximum_sum_subarray_of_size_k__easy.py
TeoZosa/pytudes
4f01ab20f936bb4b3f42d1946180d4a20fd95fbf
[ "Apache-2.0" ]
1
2022-02-08T09:47:35.000Z
2022-02-08T09:47:35.000Z
pytudes/_2021/educative/grokking_the_coding_interview/sliding_window/_1__maximum_sum_subarray_of_size_k__easy.py
TeoZosa/pytudes
4f01ab20f936bb4b3f42d1946180d4a20fd95fbf
[ "Apache-2.0" ]
62
2021-04-02T23:41:16.000Z
2022-03-25T13:16:10.000Z
pytudes/_2021/educative/grokking_the_coding_interview/sliding_window/_1__maximum_sum_subarray_of_size_k__easy.py
TeoZosa/pytudes
4f01ab20f936bb4b3f42d1946180d4a20fd95fbf
[ "Apache-2.0" ]
null
null
null
"""https://www.educative.io/courses/grokking-the-coding-interview/JPKr0kqLGNP """ def max_sum_sub_array_of_size_k(arr: list[int], K: int) -> int: """ Examples: >>> max_sum_sub_array_of_size_k([2, 1, 5, 1, 3, 2],3) 9 >>> max_sum_sub_array_of_size_k([2, 3, 4, 1, 5],2) 7 ...
24.452381
77
0.561831
9af7f0283f1278f8ba473d09841de13190ec3dc0
12,362
py
Python
cinder/volume/targets/iet.py
yanheven/cinder
89797971f30d547acbf715fea099c52d90966d1f
[ "Apache-2.0" ]
null
null
null
cinder/volume/targets/iet.py
yanheven/cinder
89797971f30d547acbf715fea099c52d90966d1f
[ "Apache-2.0" ]
null
null
null
cinder/volume/targets/iet.py
yanheven/cinder
89797971f30d547acbf715fea099c52d90966d1f
[ "Apache-2.0" ]
null
null
null
# Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # d...
38.996845
79
0.523783
afc7a293ca9c9dd3c95230cef935d914469caa7b
14,752
py
Python
cisco-ios-xr/ydk/models/cisco_ios_xr/_meta/_Cisco_IOS_XR_ha_eem_policy_oper.py
tkamata-test/ydk-py
b637e7853a8edbbd31fbc05afa3aa4110b31c5f9
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
cisco-ios-xr/ydk/models/cisco_ios_xr/_meta/_Cisco_IOS_XR_ha_eem_policy_oper.py
tkamata-test/ydk-py
b637e7853a8edbbd31fbc05afa3aa4110b31c5f9
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
cisco-ios-xr/ydk/models/cisco_ios_xr/_meta/_Cisco_IOS_XR_ha_eem_policy_oper.py
tkamata-test/ydk-py
b637e7853a8edbbd31fbc05afa3aa4110b31c5f9
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
import re import collections from enum import Enum from ydk._core._dm_meta_info import _MetaInfoClassMember, _MetaInfoClass, _MetaInfoEnum from ydk.types import Empty, YList, YLeafList, DELETE, Decimal64, FixedBitsDict from ydk._core._dm_meta_info import ATTRIBUTE, REFERENCE_CLASS, REFERENCE_LIST, REFERENCE_LEAFLI...
43.260997
183
0.487866
05e70589e9212165d8740953ce916c8bbafd5fac
373
py
Python
tests/api/models.py
TralahM/drf-generators
0b4b79ae25ddc02aa2f5e9bc9f62be16a9ab028a
[ "MIT" ]
340
2015-04-07T20:32:30.000Z
2022-03-28T12:54:38.000Z
tests/api/models.py
TralahM/drf-generators
0b4b79ae25ddc02aa2f5e9bc9f62be16a9ab028a
[ "MIT" ]
37
2015-04-07T22:56:00.000Z
2021-05-19T09:36:47.000Z
tests/api/models.py
TralahM/drf-generators
0b4b79ae25ddc02aa2f5e9bc9f62be16a9ab028a
[ "MIT" ]
82
2015-04-11T06:18:12.000Z
2022-03-20T18:26:05.000Z
from django.db import models class Category(models.Model): name = models.CharField(max_length=64) class Post(models.Model): title = models.CharField(max_length=128) slug = models.SlugField(default='', blank=True, max_length=128) content = models.TextField() category = models.ForeignKey('Category...
28.692308
94
0.734584
073f8c97213afe4a0b568ebba42d3cd2cfdc6b74
14,304
py
Python
madoka/report/renderer/tree.py
korepwx/madoka
56675bd8220935c6a9c1571a886a84bed235fd3b
[ "MIT" ]
null
null
null
madoka/report/renderer/tree.py
korepwx/madoka
56675bd8220935c6a9c1571a886a84bed235fd3b
[ "MIT" ]
null
null
null
madoka/report/renderer/tree.py
korepwx/madoka
56675bd8220935c6a9c1571a886a84bed235fd3b
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import io import mimetypes import os from PIL import Image from .base import ReportRenderer, ATTACHMENT_CONTENT_TYPE from .resources import ReportResourcesManager __all__ = [ 'ReportElementType', 'ReportElement', 'ReportBlock', 'ReportText', 'ReportInternalLink', 'ReportImage', 'Repor...
28.213018
78
0.591443
e7793b475a2df4e24c9c899af3f4038f36ee4ba0
1,262
py
Python
pycode/tinyflow/GetPredictResults.py
GIS-PuppetMaster/TENSILE
e19f973bb30fba69a23644389c82a4471ee5a241
[ "MIT" ]
null
null
null
pycode/tinyflow/GetPredictResults.py
GIS-PuppetMaster/TENSILE
e19f973bb30fba69a23644389c82a4471ee5a241
[ "MIT" ]
null
null
null
pycode/tinyflow/GetPredictResults.py
GIS-PuppetMaster/TENSILE
e19f973bb30fba69a23644389c82a4471ee5a241
[ "MIT" ]
1
2020-09-27T07:27:47.000Z
2020-09-27T07:27:47.000Z
import os from tensorflow.python.eager import executor os.environ['CUDA_VISIBLE_DEVICES'] = f'{0}' from VGG16_test_leo import VGG16 from Inceptionv3_test_leo import Inceptionv3 from Inceptionv4_test_leo import Inceptionv4 from ResNet50_test_leo import ResNet50 from DenseNet_test_leo import DenseNet121 import pickle a...
37.117647
101
0.706815
72ffd6093d22dfa993f523ed425bcec8d3320b02
18,936
py
Python
tools/gn/bootstrap/bootstrap.py
Wzzzx/chromium-crosswalk
768dde8efa71169f1c1113ca6ef322f1e8c9e7de
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
2
2019-01-28T08:09:58.000Z
2021-11-15T15:32:10.000Z
tools/gn/bootstrap/bootstrap.py
Wzzzx/chromium-crosswalk
768dde8efa71169f1c1113ca6ef322f1e8c9e7de
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
null
null
null
tools/gn/bootstrap/bootstrap.py
Wzzzx/chromium-crosswalk
768dde8efa71169f1c1113ca6ef322f1e8c9e7de
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
6
2020-09-23T08:56:12.000Z
2021-11-18T03:40:49.000Z
#!/usr/bin/env python # Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. # This file isn't officially supported by the Chromium project. It's maintained # on a best-effort basis by volunteers, so some things ...
35.328358
80
0.654943
a9ff40e8441994dda413e3bde545d9838d1035cb
59,831
py
Python
efinance/stock/getter.py
vensentzhou/efinance
f76f77155e90b8738f7ed3ccec577837c60e075d
[ "MIT" ]
null
null
null
efinance/stock/getter.py
vensentzhou/efinance
f76f77155e90b8738f7ed3ccec577837c60e075d
[ "MIT" ]
null
null
null
efinance/stock/getter.py
vensentzhou/efinance
f76f77155e90b8738f7ed3ccec577837c60e075d
[ "MIT" ]
null
null
null
import json import calendar import numpy as np from ..utils import (search_quote, to_type) from datetime import datetime, timedelta from ..utils import process_dataframe_and_series import rich from jsonpath import jsonpath from retry import retry import pandas as pd import requests import multitasking import signal fr...
42.951184
245
0.529391
c0cf66ec52a04f18062ad91f6fe257d0b452a650
4,595
py
Python
examples/document_conversion_v1.py
wkddnjset/K-Global-Starthon
081db0127d23c0039f1a3fea73ee4af3bb176bbf
[ "Apache-2.0" ]
null
null
null
examples/document_conversion_v1.py
wkddnjset/K-Global-Starthon
081db0127d23c0039f1a3fea73ee4af3bb176bbf
[ "Apache-2.0" ]
2
2020-02-12T00:05:29.000Z
2020-06-05T17:51:24.000Z
examples/document_conversion_v1.py
wkddnjset/K-Global-Starthon
081db0127d23c0039f1a3fea73ee4af3bb176bbf
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 import json from os.path import join, dirname from io import open from watson_developer_cloud import DocumentConversionV1 ''' { "url" : "https://gateway.aibril-watson.kr/document-conversion/api", "username" : "61d34a43-4105-42a0-9ec8-01774c3ce1a6", "password" : "ydCaaRag3Um5" } ''' document_conversion ...
33.057554
79
0.558651
3bbc5a00164415b31ed94573a839e6472f49dc7f
403
py
Python
statzcw/zmode.py
ZCW-Data1dot2/python-basic-stats-amanda-wink
b3db8db0e30feda598dea0fc77204420d1bbeafd
[ "MIT" ]
null
null
null
statzcw/zmode.py
ZCW-Data1dot2/python-basic-stats-amanda-wink
b3db8db0e30feda598dea0fc77204420d1bbeafd
[ "MIT" ]
null
null
null
statzcw/zmode.py
ZCW-Data1dot2/python-basic-stats-amanda-wink
b3db8db0e30feda598dea0fc77204420d1bbeafd
[ "MIT" ]
null
null
null
def mode(list_in): """ Calculate the mode :param list_in: A list :return: float """ value = [] count = [] for val in list_in: if val in value: ind = value.index(val) count[ind] += 1 else: value.append(val) count.append(1)...
19.190476
35
0.496278
f88a9cecda3cb450f4612e7f5742399cfb57248a
3,817
py
Python
modules/song.py
sushantgirdhar/song-bot
3dd8b39d09c62340b5e344cbd463e48a957f4b90
[ "MIT" ]
null
null
null
modules/song.py
sushantgirdhar/song-bot
3dd8b39d09c62340b5e344cbd463e48a957f4b90
[ "MIT" ]
null
null
null
modules/song.py
sushantgirdhar/song-bot
3dd8b39d09c62340b5e344cbd463e48a957f4b90
[ "MIT" ]
null
null
null
from pyrogram import Client, filters import youtube_dl from youtube_search import YoutubeSearch import requests import os import time from config import Config from pyrogram.types import InlineKeyboardMarkup, InlineKeyboardButton ABS="Developer" APPER="shamilhabeeb" OWNER="Owner" GITCLONE="sushantgirdhar.github.io" ...
36.009434
179
0.59235
cf470a7b4c62da1895f273461a73fa83a511ab53
1,377
py
Python
settings.py
mattmc318/django-socketio-example
31d393af57966d32509176362d1cfb1a8eb53a7a
[ "BSD-3-Clause" ]
23
2015-01-18T02:53:19.000Z
2021-12-04T09:12:20.000Z
settings.py
mattmc318/django-socketio-example
31d393af57966d32509176362d1cfb1a8eb53a7a
[ "BSD-3-Clause" ]
3
2016-07-13T17:36:56.000Z
2018-03-24T21:18:08.000Z
settings.py
mattmc318/django-socketio-example
31d393af57966d32509176362d1cfb1a8eb53a7a
[ "BSD-3-Clause" ]
16
2015-03-18T05:41:07.000Z
2021-07-08T21:20:13.000Z
import os BASE_PATH = os.path.dirname(__file__) DEBUG = True TEMPLATE_DEBUG = DEBUG TIME_ZONE = 'America/Chicago' LANGUAGE_CODE = 'en-us' SITE_ID = 1 USE_I18N = True USE_L10N = True MEDIA_ROOT = '' MEDIA_URL = '' ADMIN_MEDIA_PREFIX = '/media/' SECRET_KEY = 'aysxjo#0vhu3=%(49r_3xri@hv3y8tk_2s4jnhowp-9u7eo+tl' TEMPLA...
24.157895
65
0.740015
ed625a2737f43604845e16ca76828b40867728e6
3,105
py
Python
integration/tests/integration/tests/api/instances_states.py
sapcc/trove
c03ec0827687fba202f72f4d264ab70158604857
[ "Apache-2.0" ]
1
2019-09-20T08:31:54.000Z
2019-09-20T08:31:54.000Z
integration/tests/integration/tests/api/instances_states.py
sapcc/trove
c03ec0827687fba202f72f4d264ab70158604857
[ "Apache-2.0" ]
5
2019-08-14T06:46:03.000Z
2021-12-13T20:01:25.000Z
integration/tests/integration/tests/api/instances_states.py
sapcc/trove
c03ec0827687fba202f72f4d264ab70158604857
[ "Apache-2.0" ]
2
2020-03-15T01:24:15.000Z
2020-07-22T20:34:26.000Z
# Copyright 2012 OpenStack LLC. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required b...
40.324675
78
0.667955
1fc9539d00e760ead2c87c83f83c1bdc87e9140c
5,816
py
Python
ros/src/waypoint_updater/waypoint_updater.py
Eudie/CarND-Capstone
cffb07c3a4d8f55da90f6161e161baca8a5ecd18
[ "MIT" ]
null
null
null
ros/src/waypoint_updater/waypoint_updater.py
Eudie/CarND-Capstone
cffb07c3a4d8f55da90f6161e161baca8a5ecd18
[ "MIT" ]
null
null
null
ros/src/waypoint_updater/waypoint_updater.py
Eudie/CarND-Capstone
cffb07c3a4d8f55da90f6161e161baca8a5ecd18
[ "MIT" ]
null
null
null
#!/usr/bin/env python import rospy from geometry_msgs.msg import PoseStamped from styx_msgs.msg import Lane, Waypoint import math from std_msgs.msg import Int32 from sensor_msgs.msg import PointCloud2 from scipy.spatial import KDTree import numpy as np ''' This node will publish waypoints from the car's current po...
34.619048
133
0.66489
32999b7e450d436f1f61071e2de975f75dd0549f
1,833
py
Python
Integration/integrate.py
Abdus-Samee/CSE-218
154b0d8abe56bf4e11f2d86c5043f7c022baf7f2
[ "MIT" ]
null
null
null
Integration/integrate.py
Abdus-Samee/CSE-218
154b0d8abe56bf4e11f2d86c5043f7c022baf7f2
[ "MIT" ]
null
null
null
Integration/integrate.py
Abdus-Samee/CSE-218
154b0d8abe56bf4e11f2d86c5043f7c022baf7f2
[ "MIT" ]
null
null
null
import math def func_val(x): return (2000*math.log(140000/(140000-2100*x)))-9.8*x def trapezoidIntegration(n, a, b): h = (b-a)/n first = func_val(a) second = func_val(b) s = 0 for i in range(1, n): s += func_val(a+i*h) ans = ((b-a) * (first + second + 2*s))/(2*n) ...
25.816901
83
0.509002
ebc11ab89f21b21b1081275014f633ed9f1dccd3
353
py
Python
django/inclusion/migrations/0011_remove_structurereport_reporter.py
betagouv/data-inclusion
3423c55cb760899abe61125966e2053d8089fec7
[ "MIT" ]
null
null
null
django/inclusion/migrations/0011_remove_structurereport_reporter.py
betagouv/data-inclusion
3423c55cb760899abe61125966e2053d8089fec7
[ "MIT" ]
null
null
null
django/inclusion/migrations/0011_remove_structurereport_reporter.py
betagouv/data-inclusion
3423c55cb760899abe61125966e2053d8089fec7
[ "MIT" ]
null
null
null
# Generated by Django 4.0.3 on 2022-05-03 15:08 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ("inclusion", "0010_remove_structure_code_safir_pe"), ] operations = [ migrations.RemoveField( model_name="structurereport", n...
19.611111
61
0.620397
9e615c32bec20430127529276766e2b998c6651e
1,781
py
Python
entrenandoRF.py
Flashstacks/facial-recognition
93998bc17819ff8862603cd2660f2abc5c356d24
[ "MIT" ]
null
null
null
entrenandoRF.py
Flashstacks/facial-recognition
93998bc17819ff8862603cd2660f2abc5c356d24
[ "MIT" ]
null
null
null
entrenandoRF.py
Flashstacks/facial-recognition
93998bc17819ff8862603cd2660f2abc5c356d24
[ "MIT" ]
null
null
null
import cv2 import os import numpy as np dataPath = 'C:/Users/carl2/Desktop/Reconocimiento/Datos' #Cambia a la ruta donde hayas almacenado Data peopleList = os.listdir(dataPath) #Lleva a la carpeta Datos print('Lista de personas: ', peopleList) #Imprime los nombres de las carpetas con los nombres labels = [] ...
41.418605
129
0.735542
9c502951101e778409b546c7d866ebaaac2fe7ed
805
py
Python
var/spack/repos/builtin/packages/hydra/package.py
kkauder/spack
6ae8d5c380c1f42094b05d38be26b03650aafb39
[ "ECL-2.0", "Apache-2.0", "MIT-0", "MIT" ]
2
2021-03-05T10:54:32.000Z
2021-03-05T14:14:52.000Z
var/spack/repos/builtin/packages/hydra/package.py
kkauder/spack
6ae8d5c380c1f42094b05d38be26b03650aafb39
[ "ECL-2.0", "Apache-2.0", "MIT-0", "MIT" ]
32
2020-12-15T17:29:20.000Z
2022-03-21T15:08:31.000Z
var/spack/repos/builtin/packages/hydra/package.py
kkauder/spack
6ae8d5c380c1f42094b05d38be26b03650aafb39
[ "ECL-2.0", "Apache-2.0", "MIT-0", "MIT" ]
2
2021-04-07T18:27:09.000Z
2022-03-31T22:52:38.000Z
# Copyright 2013-2021 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 Hydra(AutotoolsPackage): """Hydra is a process management system for starting parallel job...
38.333333
93
0.732919
9460ca4fec02f7d76bc92af5d1c6d8b1ca346fc8
1,050
py
Python
Observer/property_observers.py
NachoCP/python-design-patterns
76a7834ff3f8d5c759935f3f5bd3c7c2a57ea112
[ "MIT" ]
null
null
null
Observer/property_observers.py
NachoCP/python-design-patterns
76a7834ff3f8d5c759935f3f5bd3c7c2a57ea112
[ "MIT" ]
null
null
null
Observer/property_observers.py
NachoCP/python-design-patterns
76a7834ff3f8d5c759935f3f5bd3c7c2a57ea112
[ "MIT" ]
null
null
null
class Event(list): def __call__(self, *args, **kwargs): for item in self: item(*args, **kwargs) class PropertyObservable: def __init__(self): self.property_changed = Event() class Person(PropertyObservable): def __init__(self, age=0): super().__init__() self._age = age @property def...
21
55
0.634286
95b2c681e482c50a10df43838a3de2531293aae3
501
py
Python
app/tech_dict/tech_dict/wsgi.py
duoduo369/TechDict
82fbac72f2dcb24f12d185ea43cc7a6b9887f53b
[ "MIT" ]
1
2016-06-29T23:55:00.000Z
2016-06-29T23:55:00.000Z
app/tech_dict/tech_dict/wsgi.py
duoduo369/TechDict
82fbac72f2dcb24f12d185ea43cc7a6b9887f53b
[ "MIT" ]
null
null
null
app/tech_dict/tech_dict/wsgi.py
duoduo369/TechDict
82fbac72f2dcb24f12d185ea43cc7a6b9887f53b
[ "MIT" ]
null
null
null
#!/usr/bin/env python # coding: utf-8 """ WSGI config for tech_dict project. It exposes the WSGI callable as a module-level variable named ``application``. For more information on this file, see https://docs.djangoproject.com/en/1.6/howto/deployment/wsgi/ """ import sys # 将系统的编码设置为UTF8 reload(sys) sys.setdefaultenco...
23.857143
78
0.782435
fbbd61cd07ae6a3df18ee24449256507ee4a33e8
2,346
py
Python
src/typhoonae/tests/test_init.py
sprymak/typhoonae
fe31bcc7b21fc14f8aa97b36d66cd7671974543b
[ "Apache-2.0" ]
1
2018-12-02T10:36:07.000Z
2018-12-02T10:36:07.000Z
src/typhoonae/tests/test_init.py
sprymak/typhoonae
fe31bcc7b21fc14f8aa97b36d66cd7671974543b
[ "Apache-2.0" ]
null
null
null
src/typhoonae/tests/test_init.py
sprymak/typhoonae
fe31bcc7b21fc14f8aa97b36d66cd7671974543b
[ "Apache-2.0" ]
1
2018-12-02T10:36:08.000Z
2018-12-02T10:36:08.000Z
# -*- coding: utf-8 -*- # # Copyright 2009, 2010 Tobias Rodäbel # # 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 appli...
32.136986
83
0.631287
b60f1738b3a657723b66b568f27ccc89a2b212ad
4,614
py
Python
team_most_per.py
handshakinglemma/cwhlstatbot
fcb9fa8d27aafecc09845326935a2ddd18c21368
[ "MIT" ]
null
null
null
team_most_per.py
handshakinglemma/cwhlstatbot
fcb9fa8d27aafecc09845326935a2ddd18c21368
[ "MIT" ]
null
null
null
team_most_per.py
handshakinglemma/cwhlstatbot
fcb9fa8d27aafecc09845326935a2ddd18c21368
[ "MIT" ]
null
null
null
# team_most_per # Selects two random stats and returns the team with the most stat # per the other stat. It recalculates if more than two teams are tied # for most stat. Formats and returns a tweet. import random from decimal import * # team_most_per # Caluclates the most stat per stat. # INPUT: stats, player_dicts #...
37.209677
227
0.587126
eec954a5fb777a920b3689466a40b726008164f7
343
py
Python
projects/learning-journal/brain-bit-ingestor/tests/event_hub/test_send_event.py
DEV3L/archive
652e37bf949cfcb2174b97ed5b7dbb6285a8dbe8
[ "Beerware" ]
null
null
null
projects/learning-journal/brain-bit-ingestor/tests/event_hub/test_send_event.py
DEV3L/archive
652e37bf949cfcb2174b97ed5b7dbb6285a8dbe8
[ "Beerware" ]
null
null
null
projects/learning-journal/brain-bit-ingestor/tests/event_hub/test_send_event.py
DEV3L/archive
652e37bf949cfcb2174b97ed5b7dbb6285a8dbe8
[ "Beerware" ]
null
null
null
from azure.eventhub import EventData from ingestor.builders.build_sender_client import build_sender_client message = "Hello, World!" def test_send(): expected_outcome = 'Ok' client, sender = build_sender_client() send_result = sender.send(EventData(message)) client.stop() assert expected_outco...
21.4375
69
0.752187
79766b2042464683cf452bad747d99c7a3f5f3e0
97
py
Python
genhmm1d/__init__.py
mamadouyamar/GenHMM1d
dc76946938b53be32e26218c21a373bc6663b13a
[ "MIT" ]
null
null
null
genhmm1d/__init__.py
mamadouyamar/GenHMM1d
dc76946938b53be32e26218c21a373bc6663b13a
[ "MIT" ]
null
null
null
genhmm1d/__init__.py
mamadouyamar/GenHMM1d
dc76946938b53be32e26218c21a373bc6663b13a
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Tue Sep 22 20:56:14 2020 @author: 49009427 """
10.777778
36
0.525773
79acce0e33a3d421696697b9ff0a24aca0da26be
1,700
py
Python
pommermanLearn/params.py
FrankPfirmann/playground
9379cbfd57d98eadcaf7b00d777434490a536540
[ "Apache-2.0" ]
null
null
null
pommermanLearn/params.py
FrankPfirmann/playground
9379cbfd57d98eadcaf7b00d777434490a536540
[ "Apache-2.0" ]
null
null
null
pommermanLearn/params.py
FrankPfirmann/playground
9379cbfd57d98eadcaf7b00d777434490a536540
[ "Apache-2.0" ]
2
2021-12-01T12:03:50.000Z
2022-03-22T16:37:34.000Z
from datetime import datetime import torch # train_dqn.py num_iterations = 500 episodes_per_iter = 1 gradient_steps_per_iter = 100 batch_size = 128 episodes_per_eval = 50 intermediate_test = 100 centralize_planes = False render_tests = False env = 'PommeRadio-v2' # PommeFFACompetition-v0, OneVsOne-v0. PommeTeamCompet...
22.077922
140
0.754118
dbead757a82e48ed720ac509837be907e1c84ca5
29,199
py
Python
src/tests/ftest/util/dmg_utils_base.py
zalsader/daos
38ec717e8380758dce844ae905719c225f8884d6
[ "BSD-2-Clause-Patent" ]
null
null
null
src/tests/ftest/util/dmg_utils_base.py
zalsader/daos
38ec717e8380758dce844ae905719c225f8884d6
[ "BSD-2-Clause-Patent" ]
null
null
null
src/tests/ftest/util/dmg_utils_base.py
zalsader/daos
38ec717e8380758dce844ae905719c225f8884d6
[ "BSD-2-Clause-Patent" ]
null
null
null
#!/usr/bin/python """ (C) Copyright 2020-2022 Intel Corporation. SPDX-License-Identifier: BSD-2-Clause-Patent """ from socket import gethostname from command_utils_base import \ FormattedParameter, CommandWithParameters from command_utils import CommandWithSubCommand, YamlCommand class DmgCommandBase(YamlCo...
46.127962
80
0.568924
0fee08732c5ecdc0064f501763a1486fbf9963ea
1,170
py
Python
xidplus/numpyro_fit/misc.py
MCarmenCampos/XID_plus
c031366b48486d229ac96d4eb4f547faf5227c25
[ "MIT" ]
null
null
null
xidplus/numpyro_fit/misc.py
MCarmenCampos/XID_plus
c031366b48486d229ac96d4eb4f547faf5227c25
[ "MIT" ]
null
null
null
xidplus/numpyro_fit/misc.py
MCarmenCampos/XID_plus
c031366b48486d229ac96d4eb4f547faf5227c25
[ "MIT" ]
null
null
null
import jax import pickle import functools from xidplus.numpyro_fit.neuralnet_models import CIGALE_emulator, CIGALE_emulator_kasia import numpy as np @functools.partial(jax.jit, static_argnums=(2)) def sp_matmul(A, B, shape): """ http://gcucurull.github.io/deep-learning/2020/06/03/jax-sparse-matrix-multiplicati...
30.789474
89
0.688034
23d5d455f36f59d5f4aa798163329fbe27f7a6e5
13,299
py
Python
edr_explorer/interface.py
informatics-lab/edr_explorer
80b0572e73569e5106d0a80ca44cc28c22f15974
[ "BSD-3-Clause" ]
null
null
null
edr_explorer/interface.py
informatics-lab/edr_explorer
80b0572e73569e5106d0a80ca44cc28c22f15974
[ "BSD-3-Clause" ]
31
2021-11-12T16:54:05.000Z
2022-03-25T14:10:07.000Z
edr_explorer/interface.py
informatics-lab/edr_explorer
80b0572e73569e5106d0a80ca44cc28c22f15974
[ "BSD-3-Clause" ]
null
null
null
import re from edr_explorer.data import DataHandler from .data import DataHandler from .lookup import CRS_LOOKUP, TRS_LOOKUP from .util import dict_list_search, get_request, ISO8601Expander class EDRInterface(object): """ An interface to an EDR Server that can navigate the query structure to return data...
40.057229
103
0.629295
59ab9d70d8fa277834b377071381b3c6387ccd67
2,854
py
Python
seed/seed.py
julianadecarvalho/HearTrans-front-end
b72b0d3337fca30276102b73c5dee1e1f1342db1
[ "MIT" ]
1
2022-01-24T09:34:41.000Z
2022-01-24T09:34:41.000Z
seed/seed.py
julianadecarvalho/HearTrans-front-end
b72b0d3337fca30276102b73c5dee1e1f1342db1
[ "MIT" ]
null
null
null
seed/seed.py
julianadecarvalho/HearTrans-front-end
b72b0d3337fca30276102b73c5dee1e1f1342db1
[ "MIT" ]
1
2021-08-10T16:30:04.000Z
2021-08-10T16:30:04.000Z
# # import requests # # import json # # url = "http://heartrans-back.herokuapp.com/providers/" # # payload = json.dumps({ # # "fullName": "Sydney Woolston", # # "otherNames": [ # # "Sydney Woolston" # # ], # # "titles": [ # # "License Mental Health Counselor Associate" # # ], # # ...
25.256637
75
0.564121
1789495f361718add91af2ef1aecdbbec90f4e80
1,260
py
Python
tools/gcp-org-hierarchy-viewer/setup.py
ruchirjain86/professional-services
739ac0f5ffc8237f750804fa9f0f14d4d918a0fa
[ "Apache-2.0" ]
24
2019-03-05T19:23:23.000Z
2022-01-24T18:21:33.000Z
tools/gcp-org-hierarchy-viewer/setup.py
ruchirjain86/professional-services
739ac0f5ffc8237f750804fa9f0f14d4d918a0fa
[ "Apache-2.0" ]
6
2020-01-28T22:42:21.000Z
2021-10-30T05:50:15.000Z
tools/gcp-org-hierarchy-viewer/setup.py
ruchirjain86/professional-services
739ac0f5ffc8237f750804fa9f0f14d4d918a0fa
[ "Apache-2.0" ]
13
2019-10-27T18:49:32.000Z
2022-03-06T00:02:21.000Z
# Copyright 2019 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, so...
36
79
0.674603
5a6e877b423eff9a936242404288c3f901894adb
8,936
py
Python
kmip/tests/unit/core/factories/payloads/test_response.py
ondrap/PyKMIP
c8ea17d8faf827e0f9d004972835128a1a71569f
[ "Apache-2.0" ]
179
2015-03-20T06:08:59.000Z
2022-03-14T02:24:38.000Z
kmip/tests/unit/core/factories/payloads/test_response.py
imharshr/PyKMIP
9403ff3d2aa83de4c786b8eedeb85d169fd4a594
[ "Apache-2.0" ]
600
2015-04-08T14:14:48.000Z
2022-03-28T13:49:47.000Z
kmip/tests/unit/core/factories/payloads/test_response.py
imharshr/PyKMIP
9403ff3d2aa83de4c786b8eedeb85d169fd4a594
[ "Apache-2.0" ]
131
2015-03-30T12:51:49.000Z
2022-03-23T04:34:34.000Z
# Copyright (c) 2014 The Johns Hopkins University/Applied Physics Laboratory # 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/LICEN...
35.320158
79
0.709266
67495efd734724bf6dc756a782ea39d10a510407
4,192
py
Python
UServer/http_api_no_auth/api/api_msg.py
soybean217/lora-python
9c4324f81bae8b20f6c353447189f724a5cf54c6
[ "MIT" ]
null
null
null
UServer/http_api_no_auth/api/api_msg.py
soybean217/lora-python
9c4324f81bae8b20f6c353447189f724a5cf54c6
[ "MIT" ]
null
null
null
UServer/http_api_no_auth/api/api_msg.py
soybean217/lora-python
9c4324f81bae8b20f6c353447189f724a5cf54c6
[ "MIT" ]
null
null
null
import json from binascii import hexlify from flask import Response, request from userver.object.device import Device from userver.object.group import Group from .decorators import msg_filter_valid from userver.object.application import Application from ..http_auth import auth from userver.object.message import MsgUp...
48.744186
121
0.605439
3e42ce74f923bbc56ab82a808b31b619030b0971
633
py
Python
oops_fhir/r4/value_set/push_type_available.py
Mikuana/oops_fhir
77963315d123756b7d21ae881f433778096a1d25
[ "MIT" ]
null
null
null
oops_fhir/r4/value_set/push_type_available.py
Mikuana/oops_fhir
77963315d123756b7d21ae881f433778096a1d25
[ "MIT" ]
null
null
null
oops_fhir/r4/value_set/push_type_available.py
Mikuana/oops_fhir
77963315d123756b7d21ae881f433778096a1d25
[ "MIT" ]
null
null
null
from pathlib import Path from fhir.resources.valueset import ValueSet as _ValueSet from oops_fhir.utils import ValueSet from oops_fhir.r4.code_system.push_type_available import ( pushtypeavailable as pushtypeavailable_, ) __all__ = ["pushtypeavailable"] _resource = _ValueSet.parse_file(Path(__file__).with_su...
20.419355
71
0.747235
cd42264e36d415ac5f4a3d2630edb7684ce1eca6
4,120
py
Python
venv/Lib/site-packages/falcon/cmd/print_routes.py
RafaelHMachado/Cioffis_Automation
07965ca71c3d4e78f5cee1fce4ba0bbfe2db9811
[ "MIT" ]
2
2020-12-09T17:26:25.000Z
2021-05-07T02:21:57.000Z
venv/Lib/site-packages/falcon/cmd/print_routes.py
RafaelHMachado/Cioffis_Automation
07965ca71c3d4e78f5cee1fce4ba0bbfe2db9811
[ "MIT" ]
5
2021-06-29T18:34:13.000Z
2021-06-29T18:34:44.000Z
venv/Lib/site-packages/falcon/cmd/print_routes.py
RafaelHMachado/Cioffis_Automation
07965ca71c3d4e78f5cee1fce4ba0bbfe2db9811
[ "MIT" ]
1
2021-08-18T14:45:19.000Z
2021-08-18T14:45:19.000Z
#!/usr/bin/env python # Copyright 2013 by Rackspace Hosting, 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 appl...
34.621849
79
0.586893
d9e7654c2378d91c551b3f6a019e6906234fd664
6,779
py
Python
np_ml/decision_tree/decision_tree.py
wwwy-binary/NP_ML
a51b2f3cd753e4a8b5a67bec343c3e75b3fe52d8
[ "MIT" ]
237
2018-03-17T08:50:18.000Z
2022-02-24T12:57:46.000Z
np_ml/decision_tree/decision_tree.py
pawopawo/NP_ML
a4cba12f191348526a6f6cc94df5084658fcfdea
[ "MIT" ]
2
2019-01-28T03:30:31.000Z
2021-03-03T01:47:38.000Z
np_ml/decision_tree/decision_tree.py
pawopawo/NP_ML
a4cba12f191348526a6f6cc94df5084658fcfdea
[ "MIT" ]
79
2018-03-21T12:22:09.000Z
2021-12-17T02:39:09.000Z
import numpy as np def entropy(col): _, cnts = np.unique(col, return_counts=True) cnts = np.array(cnts)/len(col) return -np.sum(cnts*np.log2(cnts)) # For ID3 def calcInforGain(col_x, col_y): HD = entropy(col_y) HDA = 0 unique, cnts = np.unique(col_x, return_counts=True) cnts = np.array(cnt...
36.446237
139
0.526036
3ea878e62e085722c30ee317f265a685067baf7d
1,650
py
Python
pkg/codegen/internal/test/testdata/simple-resource-schema/python/pulumi_example/arg_function.py
followben/pulumi
db6c4b88cbee47332bc305f594b1c15eb6803bd7
[ "Apache-2.0" ]
null
null
null
pkg/codegen/internal/test/testdata/simple-resource-schema/python/pulumi_example/arg_function.py
followben/pulumi
db6c4b88cbee47332bc305f594b1c15eb6803bd7
[ "Apache-2.0" ]
null
null
null
pkg/codegen/internal/test/testdata/simple-resource-schema/python/pulumi_example/arg_function.py
followben/pulumi
db6c4b88cbee47332bc305f594b1c15eb6803bd7
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # *** WARNING: this file was generated by test. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union, overload from . import _utilities, _tables from .resource i...
30
109
0.684242
806bf3f8e5b1281568b02bc1d0510ff34daba816
1,161
py
Python
implementation/scripts/base/visualize_mesh.py
saurabbhsp/mesh-3d-reconstruction
c52312bce7e3121643189f6b67192ffe28b08565
[ "Apache-2.0" ]
null
null
null
implementation/scripts/base/visualize_mesh.py
saurabbhsp/mesh-3d-reconstruction
c52312bce7e3121643189f6b67192ffe28b08565
[ "Apache-2.0" ]
null
null
null
implementation/scripts/base/visualize_mesh.py
saurabbhsp/mesh-3d-reconstruction
c52312bce7e3121643189f6b67192ffe28b08565
[ "Apache-2.0" ]
null
null
null
import tensorflow as tf import argparse import configparser from model.templateFFD.templateFFDBuilder import TemplateFFDBuilder from configReader import config_reader as configReader """ This script initialized the training process. For training process a single parameter specifying the path to configuration file is ...
31.378378
73
0.810508
f61993ab283a16b72f5ae643c4a89753a918796c
5,350
py
Python
encoding/models/cifarresnet.py
pansiyuan123/PyTorch-Encoding
7463e5938fb824b8eddbffdf53f55308464252d3
[ "MIT" ]
4
2020-03-26T11:05:08.000Z
2020-12-22T08:37:20.000Z
encoding/models/cifarresnet.py
pansiyuan123/PyTorch-Encoding
7463e5938fb824b8eddbffdf53f55308464252d3
[ "MIT" ]
null
null
null
encoding/models/cifarresnet.py
pansiyuan123/PyTorch-Encoding
7463e5938fb824b8eddbffdf53f55308464252d3
[ "MIT" ]
3
2020-03-26T11:05:09.000Z
2022-01-28T11:29:00.000Z
##+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ ## Created by: Hang Zhang ## ECE Department, Rutgers University ## Email: zhang.hang@rutgers.edu ## Copyright (c) 2017 ## ## This source code is licensed under the MIT-style license found in the ## LICENSE file in the root directory of this sou...
38.214286
96
0.566542
5371e7d3e16dac4b4cfcc48be9a352d77db96ce4
244
py
Python
c3po.py
PtspluS/Isensei
b6a8a02461868a65d9be43a3c44a2df7f63a3c26
[ "MIT" ]
null
null
null
c3po.py
PtspluS/Isensei
b6a8a02461868a65d9be43a3c44a2df7f63a3c26
[ "MIT" ]
null
null
null
c3po.py
PtspluS/Isensei
b6a8a02461868a65d9be43a3c44a2df7f63a3c26
[ "MIT" ]
null
null
null
from random import * # Init your variables here # Put your bot name here name = "C3PO" # C3PO strategy : return random available celle def play(board, available_cells, player): return available_cells[randint(0,len(available_cells)-1)]
22.181818
61
0.745902
f0928fd400bc64e9e1405215b11e4a9d6a033b69
4,767
py
Python
boa3_test/tests/compiler_tests/test_none.py
DanPopa46/neo3-boa
e4ef340744b5bd25ade26f847eac50789b97f3e9
[ "Apache-2.0" ]
null
null
null
boa3_test/tests/compiler_tests/test_none.py
DanPopa46/neo3-boa
e4ef340744b5bd25ade26f847eac50789b97f3e9
[ "Apache-2.0" ]
null
null
null
boa3_test/tests/compiler_tests/test_none.py
DanPopa46/neo3-boa
e4ef340744b5bd25ade26f847eac50789b97f3e9
[ "Apache-2.0" ]
null
null
null
from boa3.boa3 import Boa3 from boa3.exception.CompilerError import MismatchedTypes from boa3.neo.vm.opcode.Opcode import Opcode from boa3_test.tests.boa_test import BoaTest from boa3_test.tests.test_classes.testengine import TestEngine class TestNone(BoaTest): default_folder: str = 'test_sc/none_test' def ...
33.335664
70
0.575414
672f1a2113d145c08a444911b9899567d3529e25
158
py
Python
src/bd103/__init__.py
BD103/Package
c1f62b156713c68ac85362f0eae1560fbcca94f0
[ "Apache-2.0" ]
2
2020-12-09T00:00:16.000Z
2021-04-21T00:12:24.000Z
src/bd103/__init__.py
BD103/BD103-Python
dea7c71d72eac16bcc5b98e8e5c0d5bcfb5da82f
[ "Apache-2.0" ]
2
2021-12-14T22:08:10.000Z
2021-12-18T12:23:47.000Z
src/bd103/__init__.py
BD103/BD103-Python
dea7c71d72eac16bcc5b98e8e5c0d5bcfb5da82f
[ "Apache-2.0" ]
null
null
null
"""Collection a various utilities and modules that do random stuff. This is an all-in-one package that contains assorted code that does assorted things. """
31.6
84
0.778481
7e4f13a20817767c2c3467a493edbce9002e2b35
3,481
py
Python
lib/surface/pubsub/topics/list_subscriptions.py
bopopescu/SDK
e6d9aaee2456f706d1d86e8ec2a41d146e33550d
[ "Apache-2.0" ]
null
null
null
lib/surface/pubsub/topics/list_subscriptions.py
bopopescu/SDK
e6d9aaee2456f706d1d86e8ec2a41d146e33550d
[ "Apache-2.0" ]
null
null
null
lib/surface/pubsub/topics/list_subscriptions.py
bopopescu/SDK
e6d9aaee2456f706d1d86e8ec2a41d146e33550d
[ "Apache-2.0" ]
2
2020-11-04T03:08:21.000Z
2020-11-05T08:14:41.000Z
# Copyright 2015 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ag...
33.152381
100
0.717897
79893abeef2f88502b81f8bb05397b97cfe6101e
7,959
py
Python
QQAlbumDownloader/util/SlideVerfication.py
graysonwp/QQAlbumDownloader
29e8b71c5b46a8084b80e81179454e92b9058c1a
[ "MIT" ]
5
2019-09-26T04:11:45.000Z
2021-08-17T12:05:48.000Z
QQAlbumDownloader/util/SlideVerfication.py
graysonwp/QQAlbumDownloader
29e8b71c5b46a8084b80e81179454e92b9058c1a
[ "MIT" ]
20
2021-09-04T10:40:51.000Z
2022-03-12T00:52:48.000Z
QQAlbumDownloader/util/SlideVerfication.py
wpwbb510582246/QQAlbumDownloader
29e8b71c5b46a8084b80e81179454e92b9058c1a
[ "MIT" ]
null
null
null
#!/usr/bin/python3 # -*- coding: utf-8 -*- # @Author : Grayson # @Time : 2020-12-18 21:34 # @Email : weipengweibeibei@163.com # @Description : """ 本模块专门用来处理滑动验证码的问题, """ from selenium.webdriver import ActionChains import random, time, os import cv2 from PIL import Image as Im import numpy as np import req...
32.353659
97
0.590903
b18c2f63bb3f3a4e0c6fd5b848afb087dccba289
2,472
py
Python
deepxml/models/mlp.py
svanschalkwyk/deepxml
17a357904d100ed14bb70392b20fc8809e9ea2c7
[ "MIT" ]
41
2021-03-11T22:15:53.000Z
2022-03-29T00:53:09.000Z
deepxml/models/mlp.py
svanschalkwyk/deepxml
17a357904d100ed14bb70392b20fc8809e9ea2c7
[ "MIT" ]
9
2021-06-16T02:05:56.000Z
2022-01-18T08:41:25.000Z
deepxml/models/mlp.py
svanschalkwyk/deepxml
17a357904d100ed14bb70392b20fc8809e9ea2c7
[ "MIT" ]
9
2021-06-11T09:34:21.000Z
2022-01-23T01:50:44.000Z
import torch import torch.nn as nn __author__ = 'KD' class MLP(nn.Module): """ A multi-layer perceptron with flexibility for non-liearity * no non-linearity after last layer * support for 2D or 3D inputs Parameters: ----------- input_size: int input size of embeddings hidden...
31.692308
79
0.580502
c396a25090c8a3301520eb55cef07244ae76fa41
688
py
Python
cwitune/cwitune/main.py
trujunzhang/djzhang-targets
c2e327acde9d51f0455e7243f17d93d74b579501
[ "MIT" ]
2
2018-12-03T16:30:55.000Z
2019-04-03T13:29:20.000Z
cwitune/cwitune/main.py
trujunzhang/djzhang-targets
c2e327acde9d51f0455e7243f17d93d74b579501
[ "MIT" ]
null
null
null
cwitune/cwitune/main.py
trujunzhang/djzhang-targets
c2e327acde9d51f0455e7243f17d93d74b579501
[ "MIT" ]
1
2019-04-03T13:29:25.000Z
2019-04-03T13:29:25.000Z
from scrapy import cmdline import os class Crawler: ## get input ## filename = "results.json" def prepare(self): ## delete only if file exists ## if os.path.exists(self.filename): os.remove(self.filename) else: print("Sorry, I can not remove %s file." % sel...
22.933333
69
0.604651
3a45febe4fb25c3c14bc1d3a37e960cb3abc1217
4,531
py
Python
ocu/cache.py
albertoleal/open-conference-url
b38e8cc8015913eb8562f9ab8970ac3cfd066a43
[ "MIT" ]
null
null
null
ocu/cache.py
albertoleal/open-conference-url
b38e8cc8015913eb8562f9ab8970ac3cfd066a43
[ "MIT" ]
null
null
null
ocu/cache.py
albertoleal/open-conference-url
b38e8cc8015913eb8562f9ab8970ac3cfd066a43
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- from __future__ import unicode_literals import json import os import os.path import re import subprocess from datetime import datetime from ocu.prefs import prefs # Manages storage and retrieval of cached data for this workflow (e.g. calendar # events, date/time of la...
35.124031
79
0.625028
b719f8ebdc3daa1201d97e728fbd0749494ba94e
21
py
Python
TEST3D/GUI/0010300_page_active/cleanup.py
usnistgov/OOF3D
4fd423a48aea9c5dc207520f02de53ae184be74c
[ "X11" ]
31
2015-04-01T15:59:36.000Z
2022-03-18T20:21:47.000Z
TEST3D/GUI/0010300_page_active/cleanup.py
usnistgov/OOF3D
4fd423a48aea9c5dc207520f02de53ae184be74c
[ "X11" ]
3
2015-02-06T19:30:24.000Z
2017-05-25T14:14:31.000Z
TEST3D/GUI/0010300_page_active/cleanup.py
usnistgov/OOF3D
4fd423a48aea9c5dc207520f02de53ae184be74c
[ "X11" ]
7
2015-01-23T15:19:22.000Z
2021-06-09T09:03:59.000Z
removefile('aa.log')
10.5
20
0.714286
4eff7dafc406c6584618fb03ccc49ee9b17f03dc
4,540
py
Python
QR-code-Genrator/main.py
dsrao711/Amazing-Python-Scripts
4a8bf7bc3d0c6f2c7838d1380c7f9ddbfce766b7
[ "MIT" ]
1
2021-04-17T08:33:25.000Z
2021-04-17T08:33:25.000Z
QR-code-Genrator/main.py
dsrao711/Amazing-Python-Scripts
4a8bf7bc3d0c6f2c7838d1380c7f9ddbfce766b7
[ "MIT" ]
null
null
null
QR-code-Genrator/main.py
dsrao711/Amazing-Python-Scripts
4a8bf7bc3d0c6f2c7838d1380c7f9ddbfce766b7
[ "MIT" ]
1
2021-07-22T07:06:09.000Z
2021-07-22T07:06:09.000Z
from tkinter import * # import os import qrcode from PIL import Image, ImageTk from resizeimage import resizeimage # QR Code Generator | Designed by Jay Gohel class Qr_Genrator(): def __init__(self, root): self.root=root self.root.title("QR Code Generator") self.root.geometry('900x500+200+...
50.444444
188
0.627974
e16eab733ff9d39964f8785ec4e9d1d14366fc0b
10,720
py
Python
python/modelparsing/gem5.py
OleJohanBerg/riscv-custom-extension
53d63233bd3c9b7a01bea99916efea63f7ff677f
[ "BSD-3-Clause" ]
2
2019-08-21T07:19:35.000Z
2021-11-12T05:40:02.000Z
python/modelparsing/gem5.py
OleJohanBerg/riscv-custom-extension
53d63233bd3c9b7a01bea99916efea63f7ff677f
[ "BSD-3-Clause" ]
null
null
null
python/modelparsing/gem5.py
OleJohanBerg/riscv-custom-extension
53d63233bd3c9b7a01bea99916efea63f7ff677f
[ "BSD-3-Clause" ]
1
2019-11-28T21:08:50.000Z
2019-11-28T21:08:50.000Z
# Copyright (c) 2018 TU Dresden # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: redistributions of source code must retain the above copyright # notice, this list of conditions and the following...
30.197183
78
0.61903
5d716c52ab99682825fe3e3a37dcf9a558cc3543
17,362
py
Python
bodyfetcher.py
Draakonraev/SmokeDetector
a1a1f769eb309d71c6d4869a7a1ddf2220389d6c
[ "Apache-2.0", "MIT" ]
null
null
null
bodyfetcher.py
Draakonraev/SmokeDetector
a1a1f769eb309d71c6d4869a7a1ddf2220389d6c
[ "Apache-2.0", "MIT" ]
null
null
null
bodyfetcher.py
Draakonraev/SmokeDetector
a1a1f769eb309d71c6d4869a7a1ddf2220389d6c
[ "Apache-2.0", "MIT" ]
null
null
null
# coding=utf-8 from spamhandling import handle_spam, check_if_spam from datahandling import (add_or_update_api_data, clear_api_data, store_bodyfetcher_queue, store_bodyfetcher_max_ids, store_queue_timings) from chatcommunicate import tell_rooms_with from globalvars import GlobalVars from opera...
45.810026
119
0.548439
2e060fa9fb4b208dccd6c75dfc83d52e9f5aad4e
3,943
py
Python
radnlp/split.py
chapmanbe/RadNLP
7d27b53a75ed7c4498a649c94d2eed11f3024054
[ "Apache-2.0" ]
10
2015-08-17T14:51:36.000Z
2021-04-27T03:49:23.000Z
radnlp/split.py
chapmanbe/RadNLP
7d27b53a75ed7c4498a649c94d2eed11f3024054
[ "Apache-2.0" ]
null
null
null
radnlp/split.py
chapmanbe/RadNLP
7d27b53a75ed7c4498a649c94d2eed11f3024054
[ "Apache-2.0" ]
6
2016-12-02T22:06:53.000Z
2020-08-31T14:33:34.000Z
""" Tools for splitting report and recognizing sections """ import re from textblob import TextBlob r_headings = re.compile(r"""(?P<heading>([A-Z ]+\s)?[A-Z()]+:)""") r_digits = re.compile(r"""\d\.""") r_enumerate = re.compile(r"""((\d(.|:|\))\s)(.+)(?=\n))""") canned_phrases = ("if you have any question about this r...
29.207407
112
0.632767
941069669f890523139642f64c081ec9cc0b5711
1,163
py
Python
tests/permifrost_test_utils/snowflake_connector.py
kouk/permifrost
713aee06c287ba128032c03eead3469a79d90560
[ "MIT" ]
null
null
null
tests/permifrost_test_utils/snowflake_connector.py
kouk/permifrost
713aee06c287ba128032c03eead3469a79d90560
[ "MIT" ]
null
null
null
tests/permifrost_test_utils/snowflake_connector.py
kouk/permifrost
713aee06c287ba128032c03eead3469a79d90560
[ "MIT" ]
null
null
null
from typing import Dict, List, Any class MockSnowflakeConnector: def show_databases(self) -> List[str]: return [] def show_warehouses(self) -> List[str]: return [] def show_roles(self) -> Dict[str, str]: return {} def show_users(self) -> List[str]: return [] def...
25.282609
88
0.600172
c18fbac0413798c0a6e8f510b382979a64a63ffa
3,268
py
Python
tests/storages_tests/rdb_tests/test_with_server.py
Jeyhooon/optuna
0a5560cd0c8e83fe03f63ab431a513bf893f7d4d
[ "MIT" ]
1
2019-05-28T07:29:49.000Z
2019-05-28T07:29:49.000Z
tests/storages_tests/rdb_tests/test_with_server.py
nabenabe0928/optuna
aa505125de8515518fe19ba227edf7a1d3f8ebda
[ "MIT" ]
null
null
null
tests/storages_tests/rdb_tests/test_with_server.py
nabenabe0928/optuna
aa505125de8515518fe19ba227edf7a1d3f8ebda
[ "MIT" ]
2
2020-03-03T00:40:28.000Z
2021-01-28T11:54:32.000Z
from multiprocessing import Pool import os from typing import Sequence from typing import Tuple import numpy as np import pytest import optuna _STUDY_NAME = "_test_multiprocess" def f(x: float, y: float) -> float: return (x - 3) ** 2 + y def objective(trial: optuna.Trial) -> float: x = trial.suggest_floa...
28.172414
96
0.662791
d526a43cb308fbf6437ad3f2d89855cc791a7b27
2,017
py
Python
deepchem/feat/tests/test_one_hot_featurizer.py
cjgalvin/deepchem
64993a129e7f0f78fed9500298b1828ac8a0757a
[ "MIT" ]
3
2019-05-29T19:18:25.000Z
2021-01-25T05:44:05.000Z
deepchem/feat/tests/test_one_hot_featurizer.py
cjgalvin/deepchem
64993a129e7f0f78fed9500298b1828ac8a0757a
[ "MIT" ]
10
2017-02-23T19:39:22.000Z
2017-08-31T22:21:18.000Z
deepchem/feat/tests/test_one_hot_featurizer.py
cjgalvin/deepchem
64993a129e7f0f78fed9500298b1828ac8a0757a
[ "MIT" ]
2
2019-11-20T03:21:14.000Z
2020-03-21T17:26:33.000Z
import unittest import numpy as np from deepchem.feat import OneHotFeaturizer from deepchem.feat.molecule_featurizers.one_hot_featurizer import ZINC_CHARSET class TestOneHotFeaturizert(unittest.TestCase): """ Test OneHotFeaturizer. """ def test_onehot_featurizer(self): """ Test simple one hot encod...
31.030769
78
0.653446
6a71757ab10c02ed703536b4da39a7a31ae4d827
536
py
Python
photos/urls.py
NDOLIC/Gallery
697719df6f49b1220ff8ca17a65d757553d7421a
[ "MIT" ]
null
null
null
photos/urls.py
NDOLIC/Gallery
697719df6f49b1220ff8ca17a65d757553d7421a
[ "MIT" ]
null
null
null
photos/urls.py
NDOLIC/Gallery
697719df6f49b1220ff8ca17a65d757553d7421a
[ "MIT" ]
null
null
null
from django.conf.urls import url from . import views from django.conf import settings from django.conf.urls.static import static urlpatterns=[ # url('^$',views.photos_of_day,name = 'welcome'), url('^$',views.photos_of_day,name='photosToday'), url(r'^search/', views.search_results, name='search_results'), ...
35.733333
81
0.70709
89f32f93a32459c89f13285a3cc96e46bba81509
8,110
py
Python
contrib/devtools/update-translations.py
coiner7/whatcoin
a99fbb704ef0b370da4896256bacd04def1a6d0c
[ "MIT" ]
10
2021-07-04T03:27:19.000Z
2021-10-02T07:41:50.000Z
contrib/devtools/update-translations.py
coiner7/whatcoin
a99fbb704ef0b370da4896256bacd04def1a6d0c
[ "MIT" ]
2
2021-08-07T10:09:49.000Z
2021-10-01T04:45:07.000Z
contrib/devtools/update-translations.py
coiner7/whatcoin
a99fbb704ef0b370da4896256bacd04def1a6d0c
[ "MIT" ]
7
2021-07-06T13:22:31.000Z
2021-11-29T21:44:49.000Z
#!/usr/bin/env python3 # Copyright (c) 2014 Wladimir J. van der Laan # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. ''' Run this script from the root of the repository to update all translations from transifex. It will do the foll...
38.436019
124
0.632306
2c3d86c73a1148cac5cfa355cac9beed927688bf
723
py
Python
AsciiBot_Example/dots/getchar.py
naturecodevoid/RLBotAsciiDotsExample
b73f9b55bd907b66dc0ef21ce33ee421f19d95d6
[ "MIT" ]
3
2019-07-03T15:11:17.000Z
2019-07-26T03:18:47.000Z
AsciiBot_Example/dots/getchar.py
naturecodevoid/RLBotAsciiDotsExample
b73f9b55bd907b66dc0ef21ce33ee421f19d95d6
[ "MIT" ]
1
2019-08-04T20:17:53.000Z
2019-08-04T20:17:53.000Z
AsciiBot_Example/dots/getchar.py
naturecodevoid/RLBotAsciiDotsExample
b73f9b55bd907b66dc0ef21ce33ee421f19d95d6
[ "MIT" ]
2
2019-08-04T20:09:11.000Z
2019-08-04T20:13:38.000Z
def _find_getch(): try: import termios except ImportError: # Non-POSIX. Return msvcrt's (Windows') getch. import msvcrt return msvcrt.getch # POSIX system. Create and return a getch that manipulates the tty. import sys, tty def _getch(): fd = sys.stdin.fileno...
25.821429
71
0.568465
cbb933282a395d82060f6fb9e981c05d8d376f10
19,426
py
Python
io_import_vmf/import_qc.py
lasa01/io_import_vmf
3341b8e2d0be77cba8f3ec30812f6c859f9b9a83
[ "MIT" ]
153
2020-04-19T20:57:00.000Z
2022-03-30T18:36:27.000Z
io_import_vmf/import_qc.py
lasa01/io_import_vmf
3341b8e2d0be77cba8f3ec30812f6c859f9b9a83
[ "MIT" ]
112
2020-04-20T08:20:30.000Z
2022-03-14T00:59:33.000Z
io_import_vmf/import_qc.py
lasa01/io_import_vmf
3341b8e2d0be77cba8f3ec30812f6c859f9b9a83
[ "MIT" ]
23
2020-04-28T18:41:00.000Z
2022-03-28T12:58:09.000Z
from io_scene_valvesource import import_smd, utils from .utils import find_armature_modifier, truncate_name from vmfpy.fs import VMFFileSystem, vmf_path from vmfpy.vmt import VMT import re from collections import defaultdict from typing import DefaultDict, Dict, Any, NamedTuple, Tuple, Set, Optional, Callable, TYPE_CHE...
45.071926
118
0.61186
0d096586571f75aff232b1fb0e0b477f50081a66
1,649
py
Python
src/io_utils/path_configs/ascat/paths_hsaf_ascat_ssmcdr.py
wpreimes/io_utils
9ef4161a5bc65ab2fabee0e2c7cf873f19cf7a17
[ "MIT" ]
null
null
null
src/io_utils/path_configs/ascat/paths_hsaf_ascat_ssmcdr.py
wpreimes/io_utils
9ef4161a5bc65ab2fabee0e2c7cf873f19cf7a17
[ "MIT" ]
4
2021-07-09T09:03:12.000Z
2021-12-20T17:24:32.000Z
src/io_utils/path_configs/ascat/paths_hsaf_ascat_ssmcdr.py
wpreimes/io_utils
9ef4161a5bc65ab2fabee0e2c7cf873f19cf7a17
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from collections import OrderedDict import os import getpass import io_utils.root_path as root_path path_settings = \ { ('HSAF_ASCAT', 'SSM', 'H115+H116'): # paths will be tried in this order, there is no limit to the potential pathes here OrderedDict([ ...
39.261905
91
0.306246
769113c44a336e1b05826450b2bbf8b425386016
943
py
Python
WEEKS/CD_Sata-Structures/_RESOURCES/Whiteboard-Pairing/ReverseSubList/model_solution/model_solution.py
webdevhub42/Lambda
b04b84fb5b82fe7c8b12680149e25ae0d27a0960
[ "MIT" ]
13
2021-03-11T00:25:22.000Z
2022-03-19T00:19:23.000Z
WEEKS/CD_Sata-Structures/_RESOURCES/Whiteboard-Pairing/ReverseSubList/model_solution/model_solution.py
webdevhub42/Lambda
b04b84fb5b82fe7c8b12680149e25ae0d27a0960
[ "MIT" ]
162
2021-03-09T01:52:11.000Z
2022-03-12T01:09:07.000Z
WEEKS/CD_Sata-Structures/_RESOURCES/Whiteboard-Pairing/ReverseSubList/model_solution/model_solution.py
webdevhub42/Lambda
b04b84fb5b82fe7c8b12680149e25ae0d27a0960
[ "MIT" ]
12
2021-04-26T19:43:01.000Z
2022-01-31T08:36:29.000Z
def reverseLinkedList(node): current = node nextNode = None prevNode = None while current: # store a reference to the next list node # before we overwrite current.next nextNode = current.next # reverse the 'next' pointer current.next = prevNode # step f...
18.490196
52
0.611877
541d619388abbdc2c29d87bf8de59743a507e46d
5,242
py
Python
ginga/gw/ColorBar.py
saimn/ginga
9daf1875b4c1b0fad0a053c5f258bf7d4c0f3455
[ "BSD-3-Clause" ]
null
null
null
ginga/gw/ColorBar.py
saimn/ginga
9daf1875b4c1b0fad0a053c5f258bf7d4c0f3455
[ "BSD-3-Clause" ]
null
null
null
ginga/gw/ColorBar.py
saimn/ginga
9daf1875b4c1b0fad0a053c5f258bf7d4c0f3455
[ "BSD-3-Clause" ]
null
null
null
# # ColorBar.py -- color bar widget # # This is open-source software licensed under a BSD license. # Please see the file LICENSE.txt for details. # from ginga.misc import Callback from ginga import RGBMap from ginga.gw import Viewers from ginga.canvas.types import utils class ColorBarError(Exception): pass class...
30.126437
74
0.611599
1ef75af2b56f3747ecc191d58535312a305b5629
290
py
Python
visualize.py
Phillyclause89/Minecraft-Terrain-AI
1afb2e16164e022c92074511115eb1a2f2167930
[ "MIT" ]
null
null
null
visualize.py
Phillyclause89/Minecraft-Terrain-AI
1afb2e16164e022c92074511115eb1a2f2167930
[ "MIT" ]
null
null
null
visualize.py
Phillyclause89/Minecraft-Terrain-AI
1afb2e16164e022c92074511115eb1a2f2167930
[ "MIT" ]
null
null
null
import numpy as np import cv2 import pickle pickle_in = open("training_data.pickle", "rb") training_data = pickle.load(pickle_in) for data in training_data: img = data[0] choise = data[1] cv2.imshow("test", img) if cv2.waitKey(25) & 0xFF == ord('q'): cv2.destroyAllWindows() break
20.714286
46
0.710345
c02b63a4ad0a03043c4e6ed007fcf31f5767deeb
2,430
py
Python
app/main/forms.py
Unicomcat/flask_test
c5951842092157966c536dcafff537c9509c9881
[ "MIT" ]
null
null
null
app/main/forms.py
Unicomcat/flask_test
c5951842092157966c536dcafff537c9509c9881
[ "MIT" ]
null
null
null
app/main/forms.py
Unicomcat/flask_test
c5951842092157966c536dcafff537c9509c9881
[ "MIT" ]
null
null
null
from flask.ext.wtf import Form from wtforms import StringField, TextAreaField, BooleanField, SelectField,\ SubmitField from wtforms.validators import Required, Length, Email, Regexp from wtforms import ValidationError from ..models import Role, User from flask.ext.pagedown.fields import PageDownField class NameFor...
39.836066
78
0.636626
3e85fb3d89316cd6d540a775d56831e36eb9292a
1,249
py
Python
{{cookiecutter.prefix}}_{{cookiecutter.project_slug|lower}}/{{cookiecutter.project_slug|lower}}/extern/qtawesome/animation.py
melMass/pyvfx-boilerplate
a4df88a6e272514205a5bf34a88f4a27daa66f9c
[ "MIT" ]
null
null
null
{{cookiecutter.prefix}}_{{cookiecutter.project_slug|lower}}/{{cookiecutter.project_slug|lower}}/extern/qtawesome/animation.py
melMass/pyvfx-boilerplate
a4df88a6e272514205a5bf34a88f4a27daa66f9c
[ "MIT" ]
null
null
null
{{cookiecutter.prefix}}_{{cookiecutter.project_slug|lower}}/{{cookiecutter.project_slug|lower}}/extern/qtawesome/animation.py
melMass/pyvfx-boilerplate
a4df88a6e272514205a5bf34a88f4a27daa66f9c
[ "MIT" ]
null
null
null
from Qt.QtCore import QTimer class Spin: def __init__(self, parent_widget, interval=10, step=1): self.parent_widget = parent_widget self.interval, self.step = interval, step self.info = {} def _update(self): if self.parent_widget in self.info: timer, angle, step =...
29.738095
67
0.592474
e2014d5359501b972b70c4ffcf2d05d8c9ea9fb3
3,228
py
Python
malepierre/characters/models.py
EliotBerriot/malepierre
34a11beae528242c062fcc308c2d98c28fa61fd1
[ "BSD-3-Clause" ]
null
null
null
malepierre/characters/models.py
EliotBerriot/malepierre
34a11beae528242c062fcc308c2d98c28fa61fd1
[ "BSD-3-Clause" ]
null
null
null
malepierre/characters/models.py
EliotBerriot/malepierre
34a11beae528242c062fcc308c2d98c28fa61fd1
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- from django.db import models from django.utils import timezone from django.core.urlresolvers import reverse class CodeMixin(models.Model): code = models.CharField(max_length=255, unique=True) class Meta: abstract = True class NameMixin(models.Model): name = models.CharFie...
31.038462
97
0.695477
578fb9b6b50ad50e03cad4b76a93a76bb7f64c0c
2,380
py
Python
MultiRoom.py
dannywen2/bilibili-live-tools
99f34daec567c3ec1d315ebbfd36350ea8a0513e
[ "MIT" ]
1
2021-10-02T09:30:49.000Z
2021-10-02T09:30:49.000Z
MultiRoom.py
dannywen2/bilibili-live-tools
99f34daec567c3ec1d315ebbfd36350ea8a0513e
[ "MIT" ]
null
null
null
MultiRoom.py
dannywen2/bilibili-live-tools
99f34daec567c3ec1d315ebbfd36350ea8a0513e
[ "MIT" ]
null
null
null
import random import asyncio from bilibili import bilibili from printer import Printer async def get_area_list(): response = await bilibili().req_area_list() json_response = await response.json(content_type=None) return [ area_info['id'] for area_info in json_response['data'] ] async def area2room(area_...
41.754386
107
0.627731
d9628590d40c80b269f815f75a9eda5f9c8783bf
1,767
py
Python
format_type.py
jmp75/CPPDebuggerVisualizers
46d64f255e98e2d6fe6d3562855b93bb55c93fb4
[ "BSL-1.0" ]
141
2015-04-29T10:17:06.000Z
2022-01-24T12:45:34.000Z
format_type.py
x-santiaga-x/CPPDebuggerVisualizers
b6852c74bd7eff1347a9dcb748633e957cad2e54
[ "BSL-1.0" ]
28
2016-09-23T14:03:46.000Z
2022-01-10T14:26:36.000Z
format_type.py
x-santiaga-x/CPPDebuggerVisualizers
b6852c74bd7eff1347a9dcb748633e957cad2e54
[ "BSL-1.0" ]
40
2015-11-23T01:45:35.000Z
2021-12-16T14:33:56.000Z
'''Tools that format C++ type for reading''' cpp_type = input("Please enter type: ") if not cpp_type: cpp_type = "boost::gil::variant<boost::mpl::vector<boost::gil::image<boost::gil::pixel<unsigned char,boost::gil::layout<boost::mpl::vector1<boost::gil::gray_color_t>,boost::mpl::range_c<int,0,1> > >,0,std::allocato...
80.318182
1,311
0.642332
c11737200d4e22668c9c2b011f5ac152a1da9583
1,272
py
Python
ProxyCrawl/ProxyCrawl/migrate.py
Time1ess/ProxyPool
c44e74e8045fc560e5fe905aa41135ecb3e6da98
[ "MIT" ]
18
2017-04-25T09:39:08.000Z
2022-03-09T08:07:28.000Z
ProxyCrawl/ProxyCrawl/migrate.py
ghosttyq/ProxyPool
c44e74e8045fc560e5fe905aa41135ecb3e6da98
[ "MIT" ]
null
null
null
ProxyCrawl/ProxyCrawl/migrate.py
ghosttyq/ProxyPool
c44e74e8045fc560e5fe905aa41135ecb3e6da98
[ "MIT" ]
10
2017-05-29T00:53:41.000Z
2021-05-08T09:07:52.000Z
#!/usr/local/bin/python3 # coding: UTF-8 # Author: David # Email: youchen.du@gmail.com # Created: 2017-04-27 09:12 # Last modified: 2017-04-27 09:36 # Filename: migrate.py # Description: labels = ('name', 'url_fmt', 'row_xpath', 'host_xpath', 'port_xpath', 'addr_xpath', 'mode_xpath', 'proto_xpath', 'vt_xpath'...
41.032258
76
0.52673
dd01106f50de9d597c66e9d0ed3c5b74dd7852a6
24
py
Python
src/Protractor3D/__init__.py
SvenKratz/Protractor3D
39b6c877cc88cae028ca938e994034b83fcccb68
[ "MIT" ]
4
2018-02-06T14:41:26.000Z
2020-03-19T14:16:05.000Z
src/Protractor3D/__init__.py
SvenKratz/Protractor3D
39b6c877cc88cae028ca938e994034b83fcccb68
[ "MIT" ]
null
null
null
src/Protractor3D/__init__.py
SvenKratz/Protractor3D
39b6c877cc88cae028ca938e994034b83fcccb68
[ "MIT" ]
null
null
null
__all__=["Protractor3D"]
24
24
0.791667
691e2bc03c8380b89a2a41d53775315d820a3654
2,520
py
Python
venv/lib/python3.5/site-packages/bears/matlab/MatlabIndentationBear.py
prashant0598/CoffeeApp
4fa006aebf06e12ed34766450ddcfa548ee63307
[ "MIT" ]
null
null
null
venv/lib/python3.5/site-packages/bears/matlab/MatlabIndentationBear.py
prashant0598/CoffeeApp
4fa006aebf06e12ed34766450ddcfa548ee63307
[ "MIT" ]
null
null
null
venv/lib/python3.5/site-packages/bears/matlab/MatlabIndentationBear.py
prashant0598/CoffeeApp
4fa006aebf06e12ed34766450ddcfa548ee63307
[ "MIT" ]
null
null
null
import re from coalib.bearlib import deprecate_settings from coalib.bears.LocalBear import LocalBear from coalib.results.Diff import Diff from coalib.results.Result import Result from coalib.results.RESULT_SEVERITY import RESULT_SEVERITY class MatlabIndentationBear(LocalBear): LANGUAGES = {'Matlab', 'Octave'} ...
38.769231
79
0.599206
4e8d735c3fb9e5f02a33e77136bc4d6b884815d2
2,540
py
Python
artmap_fuzzy.py
DavidVinicius/artmap-fuzzy-tcc
1ff039ca2ade7a2a96137c75feaa9509e401e387
[ "MIT" ]
null
null
null
artmap_fuzzy.py
DavidVinicius/artmap-fuzzy-tcc
1ff039ca2ade7a2a96137c75feaa9509e401e387
[ "MIT" ]
null
null
null
artmap_fuzzy.py
DavidVinicius/artmap-fuzzy-tcc
1ff039ca2ade7a2a96137c75feaa9509e401e387
[ "MIT" ]
null
null
null
import numpy as np from src.utils.functions import * from src.neural_networks.art_fuzzy import ARTFUZZY A = np.array([ [0.25, 0.25], [0.25, 0.75], [0.75, 0.25], [0.75, 0.75] ]) B = np.array([ [0.25], [0.75], [0.75], [0.25] ]) AC = layerF0(A, 1) BC = layerF0(B, 1) WAB = np.ones...
27.608696
110
0.487008
53087f8a8ddf754046d208f79a9869511f596629
481
py
Python
Python/XGBoost/pipeline-dict-vectorizer.py
James-McNeill/Learning
3c4fe1a64240cdf5614db66082bd68a2f16d2afb
[ "MIT" ]
null
null
null
Python/XGBoost/pipeline-dict-vectorizer.py
James-McNeill/Learning
3c4fe1a64240cdf5614db66082bd68a2f16d2afb
[ "MIT" ]
null
null
null
Python/XGBoost/pipeline-dict-vectorizer.py
James-McNeill/Learning
3c4fe1a64240cdf5614db66082bd68a2f16d2afb
[ "MIT" ]
null
null
null
# Aim is to combine the LabelEncoder and OneHotEncoder methods into one step # Import DictVectorizer from sklearn.feature_extraction import DictVectorizer # Convert df into a dictionary: df_dict df_dict = df.to_dict("records") # Create the DictVectorizer object: dv dv = DictVectorizer(sparse=False) # Apply dv on df...
24.05
76
0.787942
c8a3a37c77e77a6c95cd195a41b0811c67a74883
31,691
py
Python
skymodel/snr/SNR.py
GiovanniPiano/cta-gps-simulation-paper
90b9fbadf364d11cdc7b1a5bfea27bbeb2a28a83
[ "BSD-3-Clause" ]
null
null
null
skymodel/snr/SNR.py
GiovanniPiano/cta-gps-simulation-paper
90b9fbadf364d11cdc7b1a5bfea27bbeb2a28a83
[ "BSD-3-Clause" ]
null
null
null
skymodel/snr/SNR.py
GiovanniPiano/cta-gps-simulation-paper
90b9fbadf364d11cdc7b1a5bfea27bbeb2a28a83
[ "BSD-3-Clause" ]
null
null
null
# Define the Supernova class and SNR class and connected procedures import numpy as np import matplotlib.pyplot as plt import math import pylab as pl from matplotlib.ticker import ScalarFormatter import matplotlib.ticker as mticker import matplotlib.ticker as ticker from itertools import zip_longest import os import cs...
33.570975
368
0.608154
2d701408adb738669772c582b17bed3dd27b02a2
589
py
Python
AC/IntroPython/functions/h1.py
samirsaravia/ubiquitous-octo-fortnigh
c197945e7e849ddfece02e34e0c6b8f03e50c7dd
[ "MIT" ]
null
null
null
AC/IntroPython/functions/h1.py
samirsaravia/ubiquitous-octo-fortnigh
c197945e7e849ddfece02e34e0c6b8f03e50c7dd
[ "MIT" ]
1
2021-03-04T22:03:05.000Z
2021-03-04T22:03:05.000Z
AC/IntroPython/functions/h1.py
samirsaravia/ubiquitous-octo-fortnight
c197945e7e849ddfece02e34e0c6b8f03e50c7dd
[ "MIT" ]
null
null
null
# criando funções (def) # def diga_oi(nome='Mundo', comprimentar=None): # if comprimentar is None: # print(f'Olá {nome}!!!') # else: # print(f'{comprimentar}, {nome}!!') # # # diga_oi('Zé mané') # com argumento, modifica o padrão # diga_oi() # sem argumento, executa o padrão # # diga_oi('pudi...
22.653846
79
0.65365