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
61b59bd6953b5882224ae4180a0662ab506b4493
8,338
py
Python
app/rqalpha/views.py
sddthree/HHHH
5d6b876ead92db09e91b262a7b9b3c8cf947b7a8
[ "MIT" ]
1
2020-06-29T04:52:30.000Z
2020-06-29T04:52:30.000Z
app/rqalpha/views.py
sddthree/HHHH
5d6b876ead92db09e91b262a7b9b3c8cf947b7a8
[ "MIT" ]
null
null
null
app/rqalpha/views.py
sddthree/HHHH
5d6b876ead92db09e91b262a7b9b3c8cf947b7a8
[ "MIT" ]
1
2020-06-29T04:52:31.000Z
2020-06-29T04:52:31.000Z
import sys sys.path.insert(0, "Z:\Hello\Work\Data\QT") from .. import db name = None # noinspection PyGlobalUndefined
39.330189
166
0.595107
from flask import render_template, session, redirect, url_for, Flask, request, flash, jsonify from numpy.core.multiarray import ndarray from . import rqalpha import os from multiprocessing import Process import sys sys.path.insert(0, "Z:\Hello\Work\Data\QT") from rqalpha import run_code from .. import db from ..models...
588
6,513
0
0
0
959
0
121
424
6b11159fe08c9faa679e52125037dd3d213c4984
4,169
py
Python
src/sprint_webserver/views/live.py
langrenn-sprint/sprint-webserver
065a96d102a6658e5422ea6a0be5abde4b6558e1
[ "Apache-2.0" ]
null
null
null
src/sprint_webserver/views/live.py
langrenn-sprint/sprint-webserver
065a96d102a6658e5422ea6a0be5abde4b6558e1
[ "Apache-2.0" ]
15
2021-01-11T19:42:39.000Z
2021-04-19T21:09:58.000Z
src/sprint_webserver/views/live.py
langrenn-sprint/sprint-webserver
065a96d102a6658e5422ea6a0be5abde4b6558e1
[ "Apache-2.0" ]
null
null
null
"""Resource module for live view."""
32.570313
83
0.53562
"""Resource module for live view.""" import logging from aiohttp import web import aiohttp_jinja2 from sprint_webserver.services import ( DeltakereService, InnstillingerService, KjoreplanService, KlasserService, ResultatHeatService, StartListeService, ) class Live(web.View): """Class rep...
2
0
3,740
124
0
0
0
153
113
8835673acaaceac0726d62a70686959775168460
5,216
py
Python
scripts/search/DropNAS.py
zhengxiawu/XNAS
ea8f8ab31f67155482f5b9a9ad2a0b54c45f45d1
[ "MIT" ]
22
2020-07-01T02:12:01.000Z
2020-09-24T05:32:08.000Z
scripts/search/DropNAS.py
zhengxiawu/XNAS
ea8f8ab31f67155482f5b9a9ad2a0b54c45f45d1
[ "MIT" ]
null
null
null
scripts/search/DropNAS.py
zhengxiawu/XNAS
ea8f8ab31f67155482f5b9a9ad2a0b54c45f45d1
[ "MIT" ]
5
2020-07-09T06:53:18.000Z
2020-08-15T13:15:14.000Z
"""DropNAS searching""" import torch.nn as nn import xnas.core.config as config import xnas.logger.logging as logging import xnas.logger.meter as meter # DropNAS # Load config and check config.load_configs() logger = logging.get_logger(__name__) if __name__ == "__main__": main()
38.637037
124
0.653758
"""DropNAS searching""" from torch import device import torch.nn as nn import xnas.core.config as config import xnas.logger.logging as logging import xnas.logger.meter as meter from xnas.core.config import cfg from xnas.core.builder import * # DropNAS from xnas.algorithms.DropNAS import * from xnas.runner.trainer im...
0
0
0
2,718
0
1,931
0
97
179
8aa680d96036fbe70c9149414c6bb52189390211
3,334
py
Python
vendor/ansible-module-openshift/library/openshift_policy.py
appuio/ansible-role-openshift-haproxy
f1f0752cbbc67b33a0e533328d3f0cd4ece4b03b
[ "Apache-2.0" ]
null
null
null
vendor/ansible-module-openshift/library/openshift_policy.py
appuio/ansible-role-openshift-haproxy
f1f0752cbbc67b33a0e533328d3f0cd4ece4b03b
[ "Apache-2.0" ]
null
null
null
vendor/ansible-module-openshift/library/openshift_policy.py
appuio/ansible-role-openshift-haproxy
f1f0752cbbc67b33a0e533328d3f0cd4ece4b03b
[ "Apache-2.0" ]
1
2018-09-01T16:26:23.000Z
2018-09-01T16:26:23.000Z
#!/usr/bin/python if __name__ == "__main__": main()
31.752381
151
0.637672
#!/usr/bin/python import json class PolicyModule: def __init__(self, module): self.module = module self.changed = False self.msg = [] for key in module.params: setattr(self, key, module.params[key]) def update(self): if self.cluster_roles: (rc, stdout, stderr) = self.module.ru...
0
0
0
2,711
0
464
0
9
92
e91cfd35f65fbc83a61bfdd147a857bae1e095df
960
py
Python
LeetCode/weekly-contest-153-2019.10.18/makeArrayIncreasing_1187.py
Max-PJB/python-learning2
e8b05bef1574ee9abf8c90497e94ef20a7f4e3bd
[ "MIT" ]
null
null
null
LeetCode/weekly-contest-153-2019.10.18/makeArrayIncreasing_1187.py
Max-PJB/python-learning2
e8b05bef1574ee9abf8c90497e94ef20a7f4e3bd
[ "MIT" ]
null
null
null
LeetCode/weekly-contest-153-2019.10.18/makeArrayIncreasing_1187.py
Max-PJB/python-learning2
e8b05bef1574ee9abf8c90497e94ef20a7f4e3bd
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """ ------------------------------------------------- @ Author : pengj @ date : 2019/10/22 11:00 @ IDE : PyCharm @ GitHub : https://github.com/JackyPJB @ Contact : pengjianbiao@hotmail.com ---------------...
24.615385
134
0.486458
#!/usr/bin/env python # -*- coding: utf-8 -*- """ ------------------------------------------------- @ Author : pengj @ date : 2019/10/22 11:00 @ IDE : PyCharm @ GitHub : https://github.com/JackyPJB @ Contact : pengjianbiao@hotmail.com ---------------...
66
0
0
282
0
0
0
2
44
ab7cb840d2ccde935078d73cd40c92201d21147f
4,267
py
Python
Python/DLL.py
AlexandroM1234/DataStructures-Algorithms
1a8dd1be69928266da3f50d1c86ad7be5980e205
[ "MIT" ]
null
null
null
Python/DLL.py
AlexandroM1234/DataStructures-Algorithms
1a8dd1be69928266da3f50d1c86ad7be5980e205
[ "MIT" ]
null
null
null
Python/DLL.py
AlexandroM1234/DataStructures-Algorithms
1a8dd1be69928266da3f50d1c86ad7be5980e205
[ "MIT" ]
null
null
null
DLL = DoublyLinkedList() DLL.push("val") DLL.push("val2") DLL.push("val3") print(DLL.setNode(1,"newval")) while DLL.head: print(DLL.head.val) DLL.head = DLL.head.next
24.66474
85
0.483947
class Node: def __init__(self,val): self.val = val self.next = None class DoublyLinkedList: """ Time Complexity: Insertion = O(1) Removal = O(1) Searching = O(N) Access = O(N) Most of the logic is the same as the SLL except dealing with the extra prev po...
0
0
0
4,044
0
0
0
0
45
814c8136025e552852402cb37f5ee2ee78e8dbae
385
py
Python
tests/test_tushare_api.py
xuan-wang/funcat
c4b184942564ab8a4092acb4907ab069fc44683c
[ "Apache-2.0" ]
18
2019-05-30T01:00:38.000Z
2022-01-03T15:46:25.000Z
tests/test_tushare_api.py
xuan-wang/funcat
c4b184942564ab8a4092acb4907ab069fc44683c
[ "Apache-2.0" ]
5
2019-05-28T15:01:18.000Z
2021-11-24T14:08:39.000Z
tests/test_tushare_api.py
xuan-wang/funcat
c4b184942564ab8a4092acb4907ab069fc44683c
[ "Apache-2.0" ]
8
2020-10-30T10:03:02.000Z
2021-12-04T07:20:36.000Z
import tushare as ts import time start = time.time() df = ts.pro_bar(ts_code='300851.SZ', adj='qfq', start_date='20200714', end_date='20200716') t0 = time.time() - start print(t0) print(df) arr = df.to_records() start = time.time() df = ts.get_k_data("603488", start='2020-07-14', end='2020-07-16', index=False, ktype=...
22.647059
104
0.677922
import tushare as ts import time start = time.time() df = ts.pro_bar(ts_code='300851.SZ', adj='qfq', start_date='20200714', end_date='20200716') t0 = time.time() - start print(t0) print(df) arr = df.to_records() start = time.time() df = ts.get_k_data("603488", start='2020-07-14', end='2020-07-16', index=False, ktype=...
0
0
0
0
0
0
0
0
0
78828049aba38b64bd6be75f136de208bad3519a
3,750
py
Python
src/TheLanguage/Grammars/v0_0_1/Statements/TypeAliasStatement.py
davidbrownell/DavidBrownell_TheLanguage
07170b448a0ebd7fa2325c9ccd4cefdb3cf7eb98
[ "BSL-1.0" ]
null
null
null
src/TheLanguage/Grammars/v0_0_1/Statements/TypeAliasStatement.py
davidbrownell/DavidBrownell_TheLanguage
07170b448a0ebd7fa2325c9ccd4cefdb3cf7eb98
[ "BSL-1.0" ]
null
null
null
src/TheLanguage/Grammars/v0_0_1/Statements/TypeAliasStatement.py
davidbrownell/DavidBrownell_TheLanguage
07170b448a0ebd7fa2325c9ccd4cefdb3cf7eb98
[ "BSL-1.0" ]
1
2021-06-18T18:58:57.000Z
2021-06-18T18:58:57.000Z
# ---------------------------------------------------------------------- # | # | TypeAliasStatement.py # | # | David Brownell <db@DavidBrownell.com> # | 2021-10-14 13:22:30 # | # ---------------------------------------------------------------------- # | # | Copyright David Brownell 2021 # | Distribut...
30.737705
82
0.436533
# ---------------------------------------------------------------------- # | # | TypeAliasStatement.py # | # | David Brownell <db@DavidBrownell.com> # | 2021-10-14 13:22:30 # | # ---------------------------------------------------------------------- # | # | Copyright David Brownell 2021 # | Distribut...
0
1,026
0
997
0
0
0
397
213
ca2f427df7f70436052f6a3dad6d5dd3ff36e62f
4,832
py
Python
Basics/E02_Elements/E20_UseBorders.py
freder/PageBotExamples
eb4ced53a673b9376e8357afa9ea0795b022b13c
[ "Ruby", "MIT" ]
5
2020-06-20T22:01:23.000Z
2021-08-06T04:39:50.000Z
Basics/E02_Elements/E20_UseBorders.py
freder/PageBotExamples
eb4ced53a673b9376e8357afa9ea0795b022b13c
[ "Ruby", "MIT" ]
5
2020-05-17T09:32:27.000Z
2021-03-15T19:45:52.000Z
Basics/E02_Elements/E20_UseBorders.py
freder/PageBotExamples
eb4ced53a673b9376e8357afa9ea0795b022b13c
[ "Ruby", "MIT" ]
2
2021-02-25T19:07:45.000Z
2022-01-09T21:14:06.000Z
#!/usr/bin/env python3 # -*- coding: UTF-8 -*- # ----------------------------------------------------------------------------- # # P A G E B O T E X A M P L E S # # www.pagebot.io # Licensed under MIT conditions # # ----------------------------------------------------------------------------- # # E20_U...
39.284553
108
0.614031
#!/usr/bin/env python3 # -*- coding: UTF-8 -*- # ----------------------------------------------------------------------------- # # P A G E B O T E X A M P L E S # # www.pagebot.io # Licensed under MIT conditions # # ----------------------------------------------------------------------------- # # E20_U...
0
0
0
0
0
0
0
75
44
429f28d16735e254ac0ce64ef367c5668302a233
1,104
py
Python
setup.py
Jaimedlrm/entropytriangle
46076aa6e9e06777df4dcf885cd951afdf1de168
[ "MIT" ]
2
2019-08-07T07:13:38.000Z
2019-08-07T07:13:41.000Z
setup.py
Jaimedlrm/entropytriangle
46076aa6e9e06777df4dcf885cd951afdf1de168
[ "MIT" ]
null
null
null
setup.py
Jaimedlrm/entropytriangle
46076aa6e9e06777df4dcf885cd951afdf1de168
[ "MIT" ]
1
2021-03-13T18:24:14.000Z
2021-03-13T18:24:14.000Z
from setuptools import setup, find_packages classifiers = [ "Development Status :: 3 - Alpha", "Intended Audience :: Science/Research", "License :: OSI Approved :: MIT License", "Natural Language :: English", "Programming Language :: Python", "Programming Language :: Python :: 3", "Programm...
29.837838
68
0.696558
from setuptools import setup,find_packages classifiers = [ "Development Status :: 3 - Alpha", "Intended Audience :: Science/Research", "License :: OSI Approved :: MIT License", "Natural Language :: English", "Programming Language :: Python", "Programming Language :: Python :: 3", "Programmi...
0
0
0
0
0
0
0
-1
0
063699326fe17c0b5498a656ff0dc5e99dadd27d
841
py
Python
novice/03-03/kasus/app.py
blackjokie/praxis-academy
594d24fcf18cea4f76c9889030eba4aa3f834b7a
[ "MIT" ]
2
2019-08-11T16:58:04.000Z
2019-08-27T17:01:40.000Z
novice/03-03/kasus/app.py
blackjokie/praxis-academy
594d24fcf18cea4f76c9889030eba4aa3f834b7a
[ "MIT" ]
null
null
null
novice/03-03/kasus/app.py
blackjokie/praxis-academy
594d24fcf18cea4f76c9889030eba4aa3f834b7a
[ "MIT" ]
null
null
null
from flask import Flask app = Flask(__name__) if __name__ == '__main__': app.run(debug = True)
32.346154
154
0.62069
from flask import Flask, render_template, request import pymysql as asu app = Flask(__name__) @app.route('/') def list(): # Open database connection db = asu.connect("<hostname>","<username>","<password>","<db_name>") # prepare a cursor object using cursor() method cursor = db...
0
670
0
0
0
0
0
26
45
c5c6acefdfda2711c271d081ecd0efdbac1c3611
8,637
py
Python
lenspack/utils.py
sfarrens/lenspack
b7a8d6dfd8a1fd4d026a16c0f9f447964d3f0581
[ "MIT" ]
6
2019-11-06T15:51:52.000Z
2021-07-11T14:37:14.000Z
lenspack/utils.py
sfarrens/lenspack
b7a8d6dfd8a1fd4d026a16c0f9f447964d3f0581
[ "MIT" ]
1
2021-06-14T13:40:48.000Z
2021-06-14T13:40:48.000Z
lenspack/utils.py
sfarrens/lenspack
b7a8d6dfd8a1fd4d026a16c0f9f447964d3f0581
[ "MIT" ]
5
2019-11-14T15:32:46.000Z
2022-01-03T15:25:45.000Z
# -*- coding: utf-8 -*- """UTILS MODULE This module contains utility functions globally available to lenspack. """ import numpy as np from astropy.units.core import Unit from astropy.constants import G as G_newton from astropy.constants import c as c_light def round_up_to_odd(x): """Round up to the nearest od...
31.180505
79
0.555749
# -*- coding: utf-8 -*- """UTILS MODULE This module contains utility functions globally available to lenspack. """ import numpy as np from astropy.units.core import Unit from astropy.constants import G as G_newton from astropy.constants import c as c_light def round_up_to_odd(x): """Round up to the nearest od...
0
0
0
0
0
0
0
0
0
a4dfbe8bf3c713b2f61de253c0f1eb25783ea050
2,905
py
Python
rl_games/algos_torch/model_builder.py
yzqin/rl_games
6e09fec1e60d70c1dc1934ec65ed3265950a8c34
[ "MIT" ]
null
null
null
rl_games/algos_torch/model_builder.py
yzqin/rl_games
6e09fec1e60d70c1dc1934ec65ed3265950a8c34
[ "MIT" ]
null
null
null
rl_games/algos_torch/model_builder.py
yzqin/rl_games
6e09fec1e60d70c1dc1934ec65ed3265950a8c34
[ "MIT" ]
null
null
null
NETWORK_REGISTRY = {} MODEL_REGISTRY = {}
48.416667
118
0.687091
from rl_games.common import object_factory import rl_games.algos_torch from rl_games.algos_torch import network_builder, pn_network_builder from rl_games.algos_torch import models NETWORK_REGISTRY = {} MODEL_REGISTRY = {} def register_network(name, target_class): NETWORK_REGISTRY[name] = lambda **kwargs: target_c...
0
0
0
2,413
0
175
0
92
180
0a0173adfbd6865ffe8cdcab826239cb84836335
3,408
py
Python
win/devkit/other/pymel/extras/completion/py/pymel/util/mathutils.py
leegoonz/Maya-devkit
b81fe799b58e854e4ef16435426d60446e975871
[ "ADSL" ]
10
2018-03-30T16:09:02.000Z
2021-12-07T07:29:19.000Z
win/devkit/other/pymel/extras/completion/py/pymel/util/mathutils.py
leegoonz/Maya-devkit
b81fe799b58e854e4ef16435426d60446e975871
[ "ADSL" ]
null
null
null
win/devkit/other/pymel/extras/completion/py/pymel/util/mathutils.py
leegoonz/Maya-devkit
b81fe799b58e854e4ef16435426d60446e975871
[ "ADSL" ]
9
2018-06-02T09:18:49.000Z
2021-12-20T09:24:35.000Z
def clamp(x=0.0, min=0.0, max=1.0): """ Clamps the value x between min and max :rtype: float """ pass def gamma(c, g): """ Gamma color correction of c with a single scalar gamma value g :rtype: float """ pass def round(value, ndigits=0): """ round(number[...
21.167702
131
0.634977
import math from __builtin__ import round as _round def clamp(x=0.0, min=0.0, max=1.0): """ Clamps the value x between min and max :rtype: float """ pass def gamma(c, g): """ Gamma color correction of c with a single scalar gamma value g :rtype: float """ pass d...
0
0
0
0
0
0
0
8
45
3a1d246ea8433f7464347db25ad117f762fbd461
2,238
py
Python
algorithms/dfs/optimal_account_balancing.py
kevinshenyang07/Data-Structure-and-Algo
36b02feea04b892f1256de090c4fcf7b6aa98873
[ "MIT" ]
null
null
null
algorithms/dfs/optimal_account_balancing.py
kevinshenyang07/Data-Structure-and-Algo
36b02feea04b892f1256de090c4fcf7b6aa98873
[ "MIT" ]
null
null
null
algorithms/dfs/optimal_account_balancing.py
kevinshenyang07/Data-Structure-and-Algo
36b02feea04b892f1256de090c4fcf7b6aa98873
[ "MIT" ]
null
null
null
# Optimal Account Balancing # given a list of transactions between a group of people, with each transaction # as a tuple (x, y, z), meaining person x send person y amount z of money # assume x != y and z > 0, id x and y might not be linear # return the minimum number of transactions required to settle the debt # Optima...
39.263158
79
0.550045
# Optimal Account Balancing # given a list of transactions between a group of people, with each transaction # as a tuple (x, y, z), meaining person x send person y amount z of money # assume x != y and z > 0, id x and y might not be linear # return the minimum number of transactions required to settle the debt # Optima...
0
0
0
1,592
0
0
0
0
22
dc770c3c12eb279da2f1f44d53d4f054d75e3568
1,664
py
Python
btemu/install.py
pedersen/nerfgun
136b2b1448eee3f6cc9e0cb88a31eb9cf321fe49
[ "MIT" ]
null
null
null
btemu/install.py
pedersen/nerfgun
136b2b1448eee3f6cc9e0cb88a31eb9cf321fe49
[ "MIT" ]
null
null
null
btemu/install.py
pedersen/nerfgun
136b2b1448eee3f6cc9e0cb88a31eb9cf321fe49
[ "MIT" ]
null
null
null
if __name__ == '__main__': main()
35.404255
113
0.623798
import logging import os import shutil from importlib.resources import read_text from subprocess import check_call import btemu.resources def write_resource(fname, resource_module, resource_name): logging.info(f'(Re)Creating {fname}') data = read_text(resource_module, resource_name) f = open(fname, 'w') ...
0
0
0
0
0
1,437
0
6
179
983480b5218ad736d2b4e7dba40780990a35cd85
22,652
py
Python
uliweb/contrib/jsonql/__init__.py
timgates42/uliweb
80c0459c5e5d257b665eb2e1d0b5f68ad55c42f1
[ "BSD-2-Clause" ]
202
2015-01-12T08:10:48.000Z
2021-11-08T09:04:32.000Z
uliweb/contrib/jsonql/__init__.py
timgates42/uliweb
80c0459c5e5d257b665eb2e1d0b5f68ad55c42f1
[ "BSD-2-Clause" ]
30
2015-01-01T09:07:17.000Z
2021-06-03T12:58:45.000Z
uliweb/contrib/jsonql/__init__.py
timgates42/uliweb
80c0459c5e5d257b665eb2e1d0b5f68ad55c42f1
[ "BSD-2-Clause" ]
58
2015-01-12T03:28:54.000Z
2022-01-14T01:58:08.000Z
#coding=utf8 import logging DEBUG = False __schemas__ = {} __relations__ = None __default_limit__ = 10 log = logging.getLogger(__name__) __relations__ = Relations() def get_relation_condition(key): """ Get relation condition :param key: should be (schema_a, schema_b) :return: """ glob...
33.360825
136
0.50181
#coding=utf8 from uliweb import settings from uliweb.utils.common import safe_str, import_attr from uliweb.utils.storage import Storage from uliweb.orm import do_, get_model from uliweb.utils.sorteddict import SortedDict from sqlalchemy import __version__ as sa_version, select, true, text, literal import logging DEBU...
0
2,401
0
16,733
0
2,425
0
154
430
c3a1eff16ee4d748fa6ad17642207484a4f9e3b0
8,317
py
Python
Bayesian-HM-DenseED/test_BayesianNN_UP.py
zabaras/bayesmultiscale
c2f7d36e8ff08a28e5da0809029143a9dd0e2777
[ "MIT" ]
null
null
null
Bayesian-HM-DenseED/test_BayesianNN_UP.py
zabaras/bayesmultiscale
c2f7d36e8ff08a28e5da0809029143a9dd0e2777
[ "MIT" ]
null
null
null
Bayesian-HM-DenseED/test_BayesianNN_UP.py
zabaras/bayesmultiscale
c2f7d36e8ff08a28e5da0809029143a9dd0e2777
[ "MIT" ]
1
2021-09-20T16:25:43.000Z
2021-09-20T16:25:43.000Z
""" Stein Variational Gradient Descent for Deep ConvNet on GPU. Current implementation is mainly using for-loops over model instances. """ import torch import numpy as np from time import time from args import args, device from utils.mcs_data_upload import mcs_load_data import scipy.io as io n_out_pixels_train = ar...
37.129464
165
0.625105
""" Stein Variational Gradient Descent for Deep ConvNet on GPU. Current implementation is mainly using for-loops over model instances. """ import torch import numpy as np from time import time from args import args, device import h5py import os from models.model_det import DenseED from models.Bayesian_model_NN import ...
0
0
0
0
0
3,659
0
95
288
9cd182a154ad67bc80a62c610648170da0218fab
47,302
py
Python
src/action_handlers/manage_bill_handler.py
ZAFW/whopaybot
a2d51de69223efc10ae09f0a70962b8397a5dd93
[ "MIT" ]
null
null
null
src/action_handlers/manage_bill_handler.py
ZAFW/whopaybot
a2d51de69223efc10ae09f0a70962b8397a5dd93
[ "MIT" ]
null
null
null
src/action_handlers/manage_bill_handler.py
ZAFW/whopaybot
a2d51de69223efc10ae09f0a70962b8397a5dd93
[ "MIT" ]
null
null
null
import constants as const MODULE_ACTION_TYPE = const.TYPE_MANAGE_BILL ACTION_GET_MANAGE_BILL = 0 ACTION_GET_MANAGE_BILL_KB = 1 ACTION_SHARE_BILL = 2 ACTION_CALCULATE_SPLIT = 3 ACTION_REFRESH_BILL = 4 ACTION_SEND_DEBTS_BILL_ADMIN = 5 ACTION_GET_CONFIRM_PAYMENTS_KB = 6 ACTION_CONFIRM_BILL_PAYMENT = 7 ACTION_SEND_DEBTS_...
35.998478
239
0.586571
from action_handlers.action_handler import ActionHandler, Action from telegram.inlinekeyboardmarkup import InlineKeyboardMarkup from telegram.inlinekeyboardbutton import InlineKeyboardButton from telegram.ext import Filters from telegram.parsemode import ParseMode from telegram.error import BadRequest import constants ...
113
13,503
0
30,166
0
1,005
0
124
724
df422463a9f784dc2d6e065bfa91ba5deeaf0dbc
4,031
py
Python
tests/zoomus/components/webinar/test_register.py
karthikkommindala1995/zoomus
bf994aee5656c88a4f53e78fe8fb80c39fd737db
[ "Apache-2.0" ]
1
2019-11-05T06:02:20.000Z
2019-11-05T06:02:20.000Z
tests/zoomus/components/webinar/test_register.py
karthikkommindala1995/zoomus
bf994aee5656c88a4f53e78fe8fb80c39fd737db
[ "Apache-2.0" ]
null
null
null
tests/zoomus/components/webinar/test_register.py
karthikkommindala1995/zoomus
bf994aee5656c88a4f53e78fe8fb80c39fd737db
[ "Apache-2.0" ]
null
null
null
import unittest def suite(): """Define all the tests of the module.""" suite = unittest.TestSuite() suite.addTest(unittest.makeSuite(RegisterV1TestCase)) return suite if __name__ == '__main__': unittest.main()
31.248062
83
0.574051
from datetime import datetime import unittest from mock import patch from zoomus import components def suite(): """Define all the tests of the module.""" suite = unittest.TestSuite() suite.addTest(unittest.makeSuite(RegisterV1TestCase)) return suite class RegisterV1TestCase(unittest.TestCase): ...
0
1,657
0
2,007
0
0
0
17
114
cd5586552672028e366947fc3fccefd5d49c0394
10,942
py
Python
finctrl/__init__.py
aspyatkin/finctrl
df0b787065c7cff612a9bdfd0fed09880b73c571
[ "MIT" ]
null
null
null
finctrl/__init__.py
aspyatkin/finctrl
df0b787065c7cff612a9bdfd0fed09880b73c571
[ "MIT" ]
null
null
null
finctrl/__init__.py
aspyatkin/finctrl
df0b787065c7cff612a9bdfd0fed09880b73c571
[ "MIT" ]
null
null
null
from peewee import (SqliteDatabase) import os db = SqliteDatabase(os.path.join(os.getcwd(), 'finance.db')) if __name__ == '__main__': cli()
34.087227
200
0.677847
from peewee import ( SqliteDatabase, Model, CharField, ForeignKeyField, DateField, DecimalField, DateTimeField, IntegerField, TextField ) import os import click from datetime import date, datetime, timedelta from decimal import Decimal from enum import IntEnum db = SqliteDatabase(o...
0
9,155
0
778
0
82
0
163
594
46ade8070326db43ba877e4374ad5f10191c390f
2,429
py
Python
2021/2021-12-15.py
wac-/advent-of-code
19022fe5660b30125cd99054565b70edbf3a06a0
[ "BSD-3-Clause" ]
null
null
null
2021/2021-12-15.py
wac-/advent-of-code
19022fe5660b30125cd99054565b70edbf3a06a0
[ "BSD-3-Clause" ]
null
null
null
2021/2021-12-15.py
wac-/advent-of-code
19022fe5660b30125cd99054565b70edbf3a06a0
[ "BSD-3-Clause" ]
null
null
null
from queue import PriorityQueue Coordinate = tuple[int, int] map: list[list[int]] = [] PART_TWO = True # For each position, we store the lowest cost path to get there. lowest_cost: list[list[None | tuple[int, list[Coordinate]]]] = [] with open('2021-12-15.txt') as f: for line in (l.strip() for l in f): ...
32.386667
84
0.592425
from queue import PriorityQueue Coordinate = tuple[int, int] map: list[list[int]] = [] PART_TWO = True # For each position, we store the lowest cost path to get there. lowest_cost: list[list[None | tuple[int, list[Coordinate]]]] = [] with open('2021-12-15.txt') as f: for line in (l.strip() for l in f): ...
0
0
0
0
0
0
0
0
0
46b39cd3db3a390bf009f581a466407f58a570f1
6,446
py
Python
clusterlogs/training_corpus.py
micolocco/ClusterLog
d5cdf48288e943d77271f675958a535eb7dfe38d
[ "MIT" ]
1
2021-02-16T17:23:26.000Z
2021-02-16T17:23:26.000Z
clusterlogs/training_corpus.py
micolocco/ClusterLog
d5cdf48288e943d77271f675958a535eb7dfe38d
[ "MIT" ]
null
null
null
clusterlogs/training_corpus.py
micolocco/ClusterLog
d5cdf48288e943d77271f675958a535eb7dfe38d
[ "MIT" ]
null
null
null
#!/usr/bin/python import sys #from smart_open import open from pyspark.sql.functions import col from pyspark import SparkContext from pyspark.sql import SparkSession def spark_session(appName="log-parser"): """ Function to create new spark session """ sc = SparkContext(appName="log-parser") ret...
36.625
175
0.607198
#!/usr/bin/python import sys import getopt from gensim.models import Word2Vec import pprint from time import time from pyonmttok import Tokenizer #from smart_open import open import json from pyspark.sql import DataFrame from pyspark.sql.types import StructType, StructField, StringType,ArrayType from pyspark.sql.functi...
0
456
0
1,959
0
2,858
0
89
541
16d7bc475bce333c6dadc5fa01d18582b63193f4
2,185
py
Python
Z - Tool Box/x2john/vmx2john.py
dfirpaul/Active-Directory-Exploitation-Cheat-Sheet-1
1dcf54522e9d20711ff1114550dc2893ed3e9ed0
[ "MIT" ]
1,290
2020-05-28T21:24:43.000Z
2022-03-31T16:38:43.000Z
Z - Tool Box/x2john/vmx2john.py
asim06/Active-Directory-Exploitation-Cheat-Sheet
708f57c83aa99d80df22f4e50f21479a709fb359
[ "MIT" ]
1
2020-07-03T21:14:52.000Z
2020-07-03T21:14:52.000Z
Z - Tool Box/x2john/vmx2john.py
asim06/Active-Directory-Exploitation-Cheat-Sheet
708f57c83aa99d80df22f4e50f21479a709fb359
[ "MIT" ]
280
2020-05-29T17:28:38.000Z
2022-03-31T13:54:15.000Z
#!/usr/bin/env python # This software is Copyright (c) 2019 - Dhiru Kholia, Copyright (c) 2018 - # axcheron, and it is hereby released under the MIT License. # # Key parts of this program are borrowed from the pyvmx-cracker project. # # See https://github.com/axcheron/pyvmx-cracker for details. import sys PY3 = sys.v...
29.133333
96
0.62746
#!/usr/bin/env python # This software is Copyright (c) 2019 - Dhiru Kholia, Copyright (c) 2018 - # axcheron, and it is hereby released under the MIT License. # # Key parts of this program are borrowed from the pyvmx-cracker project. # # See https://github.com/axcheron/pyvmx-cracker for details. import os import re im...
0
0
0
0
0
1,442
0
-26
160
48ffb26072679d98b02cf4a876329ab8e109cd27
10,551
py
Python
examples/ewallet_example.py
jlodonia/xendit-python
d1148f6d736fee17e22a1432d337a94538505595
[ "MIT" ]
10
2020-10-31T23:34:34.000Z
2022-03-08T19:08:55.000Z
examples/ewallet_example.py
jlodonia/xendit-python
d1148f6d736fee17e22a1432d337a94538505595
[ "MIT" ]
22
2020-07-30T14:25:07.000Z
2022-03-31T03:55:46.000Z
examples/ewallet_example.py
jlodonia/xendit-python
d1148f6d736fee17e22a1432d337a94538505595
[ "MIT" ]
11
2020-07-28T08:09:40.000Z
2022-03-18T00:14:02.000Z
# Hackish method to import from another directory # Useful while xendit-python isn't released yet to the public import importlib.machinery loader = importlib.machinery.SourceFileLoader("xendit", "../xendit/__init__.py") xendit = loader.load_module("xendit")
33.709265
88
0.598711
from print_running_function import print_running_function import time # Hackish method to import from another directory # Useful while xendit-python isn't released yet to the public import importlib.machinery loader = importlib.machinery.SourceFileLoader("xendit", "../xendit/__init__.py") xendit = loader.load_module...
0
7,608
0
44
0
1,904
0
26
699
912ab713f612a5d3afa5649cae094ada2ef4d441
664
py
Python
Django/e-commerce-website/store/urls.py
piaochung/blog
3fc518c6b681e070e46dffaf64fae1086423a5e6
[ "MIT" ]
null
null
null
Django/e-commerce-website/store/urls.py
piaochung/blog
3fc518c6b681e070e46dffaf64fae1086423a5e6
[ "MIT" ]
null
null
null
Django/e-commerce-website/store/urls.py
piaochung/blog
3fc518c6b681e070e46dffaf64fae1086423a5e6
[ "MIT" ]
null
null
null
from django.urls import path from . import views urlpatterns = [ path('category/<int:category_slug>/', views.store, name='products_by_category'), path('category/<int:category_slug>/<int:subcategory_slug>/', views.store, name='products_by_subcategory'), path('category/<int:category_slug>/<...
33.2
84
0.680723
from django.urls import path from . import views urlpatterns = [ path('category/<int:category_slug>/', views.store, name='products_by_category'), path('category/<int:category_slug>/<int:subcategory_slug>/', views.store, name='products_by_subcategory'), path('category/<int:category_slug>/<...
0
0
0
0
0
0
0
0
0
d7db3bf9e380d300103425108f9bd77a08df6a4a
12,741
py
Python
fastNLP/modules/decoder/CRF.py
YanLiqi/fastNLP
a8c45796158a3b8dbc81e22412bd6e4e4b97539a
[ "Apache-2.0" ]
4
2019-01-19T13:58:10.000Z
2019-01-19T15:07:48.000Z
fastNLP/modules/decoder/CRF.py
YanLiqi/fastNLP
a8c45796158a3b8dbc81e22412bd6e4e4b97539a
[ "Apache-2.0" ]
null
null
null
fastNLP/modules/decoder/CRF.py
YanLiqi/fastNLP
a8c45796158a3b8dbc81e22412bd6e4e4b97539a
[ "Apache-2.0" ]
null
null
null
def allowed_transitions(id2label, encoding_type='bio'): """ :param dict id2label: keylabelindicesvaluestrtagtag-labelvaluetag, "B", "M"; "B-NN", "M-NN", taglabel"-"Vocabulary.get_id2word()id2label :param encoding_type: str, "bio", "bmes" :return: List[Tuple(int, int)]], Tuple(from_tag_id, ...
42.188742
122
0.566204
import torch from torch import nn from fastNLP.modules.utils import initial_parameter def log_sum_exp(x, dim=-1): max_value, _ = x.max(dim=dim, keepdim=True) res = torch.log(torch.sum(torch.exp(x - max_value), dim=dim, keepdim=True)) + max_value return res.squeeze(dim) def seq_len_to_byte_mask(seq_lens...
963
0
0
7,296
0
819
0
20
162
c62ff6985348eba85720ddafd2a35829d859a862
7,472
py
Python
tests/benchmark.py
imartinezl/cpab
d18692528f5ae2028e2deaf38def1562e595660d
[ "MIT" ]
null
null
null
tests/benchmark.py
imartinezl/cpab
d18692528f5ae2028e2deaf38def1562e595660d
[ "MIT" ]
null
null
null
tests/benchmark.py
imartinezl/cpab
d18692528f5ae2028e2deaf38def1562e595660d
[ "MIT" ]
null
null
null
# %% import sys sys.path.insert(0, "..") import timeit import numpy as np import torch import matplotlib.pyplot as plt import cpab import torch.autograd.profiler as profiler import torch.utils.benchmark as benchmark # %% SETUP tess_size = 50 backend = "pytorch" # ["pytorch", "numpy"] device = "gpu" # ["cpu", "gpu...
26.590747
184
0.632227
# %% import sys sys.path.insert(0, "..") import time import timeit import numpy as np import torch import matplotlib.pyplot as plt import cpab import torch.autograd.profiler as profiler import torch.utils.benchmark as benchmark # %% SETUP tess_size = 50 backend = "pytorch" # ["pytorch", "numpy"] device = "gpu" #...
0
0
0
0
0
0
0
-14
45
5f7fe7b5ac3f8175ed7329cfaae3957cb23f47d4
61,031
py
Python
home/osmc/DLP/dlp_lightcrafter-1.0.19/dlp_lightcrafter/dpp2607.py
bietiekay/TI_LightCrafter_DLP2000_OSMC_RaspberryPi
27f62f973f7d8c8cc3a49007599a7bf592d86289
[ "BSD-2-Clause" ]
3
2018-12-03T15:11:59.000Z
2021-07-17T16:25:16.000Z
home/osmc/DLP/dlp_lightcrafter-1.0.19/dlp_lightcrafter/dpp2607.py
bietiekay/TI_LightCrafter_DLP2000_OSMC_RaspberryPi
27f62f973f7d8c8cc3a49007599a7bf592d86289
[ "BSD-2-Clause" ]
1
2019-01-04T17:35:37.000Z
2019-01-04T17:35:37.000Z
home/osmc/DLP/dlp_lightcrafter-1.0.19/dlp_lightcrafter/dpp2607.py
bietiekay/TI_LightCrafter_DLP2000_OSMC_RaspberryPi
27f62f973f7d8c8cc3a49007599a7bf592d86289
[ "BSD-2-Clause" ]
1
2020-08-15T04:48:51.000Z
2020-08-15T04:48:51.000Z
# -*- coding: windows-1252 -*- # dpp2607.py # # sends commands to DPP2607 ASIC using I2C # # Copyright (C) 2017 Texas Instruments Incorporated - http://www.ti.com/ # # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # ...
30.964485
750
0.69527
# -*- coding: windows-1252 -*- # dpp2607.py # # sends commands to DPP2607 ASIC using I2C # # Copyright (C) 2017 Texas Instruments Incorporated - http://www.ti.com/ # # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # ...
0
0
0
4,099
0
313
0
0
506
bb36154f56427888e11879eca6ee7e98539750ca
5,089
py
Python
tests/test_cli.py
gercograndia/aws-iam-tester
555a868e8ccd44b81da18b94dbfaf2219d42eab5
[ "MIT" ]
15
2020-03-27T22:55:14.000Z
2022-02-12T04:22:41.000Z
tests/test_cli.py
gercograndia/aws-iam-tester
555a868e8ccd44b81da18b94dbfaf2219d42eab5
[ "MIT" ]
3
2020-07-31T19:41:33.000Z
2021-06-30T07:16:08.000Z
tests/test_cli.py
gercograndia/aws-iam-tester
555a868e8ccd44b81da18b94dbfaf2219d42eab5
[ "MIT" ]
6
2020-11-24T20:44:44.000Z
2021-06-03T02:56:23.000Z
""" Tests for the command module """ import pathlib # from aws-iam-tester import cli script_path = pathlib.Path(__file__).parent.absolute() # Keep this method last to avoid disrupting other methods
35.340278
157
0.647671
""" Tests for the command module """ import os import subprocess import pytest import pathlib from pyassert import assert_that # from aws-iam-tester import cli script_path = pathlib.Path(__file__).parent.absolute() def run_command(command_list, do_assert=True, show_debug=False): process = subprocess.Popen( ...
0
0
0
0
0
4,422
0
-13
479
bb2d7ee630e8e32809d8407270d93c95fb6f1e7b
7,645
py
Python
request-patch-review.py
hyunsik/incubator-tajo
fbc358c2030e78f6616b286cf0736afaa8a583f8
[ "BSD-3-Clause" ]
19
2015-01-22T14:46:11.000Z
2021-11-10T16:06:36.000Z
request-patch-review.py
gruter/tajo-cdh
7bd3efdc253fe7bffb42881065183e94a8a0a2ee
[ "BSD-3-Clause" ]
null
null
null
request-patch-review.py
gruter/tajo-cdh
7bd3efdc253fe7bffb42881065183e94a8a0a2ee
[ "BSD-3-Clause" ]
19
2015-01-11T20:04:49.000Z
2021-11-10T16:06:26.000Z
#!/usr/bin/env python # 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 # "L...
46.615854
393
0.708306
#!/usr/bin/env python # 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 # "L...
0
0
0
0
0
322
0
0
24
c15a73a25b6c01e22dddf80e2f1876a8c274118a
11,613
py
Python
babygraphics.py
kaiicheng/United-States-Population-Name-Dashboard
9019538fcb58c7e97a3dc67d3b27cb8ad180e448
[ "MIT" ]
null
null
null
babygraphics.py
kaiicheng/United-States-Population-Name-Dashboard
9019538fcb58c7e97a3dc67d3b27cb8ad180e448
[ "MIT" ]
null
null
null
babygraphics.py
kaiicheng/United-States-Population-Name-Dashboard
9019538fcb58c7e97a3dc67d3b27cb8ad180e448
[ "MIT" ]
null
null
null
""" SC101 Baby Names Project Adapted from Nick Parlante's Baby Names assignment by Jerry Liao. YOUR DESCRIPTION HERE """ import tkinter FILENAMES = [ 'data/full/baby-1900.txt', 'data/full/baby-1910.txt', 'data/full/baby-1920.txt', 'data/full/baby-1930.txt', 'data/full/baby-1940.txt', 'data/full/baby-1950...
40.463415
145
0.563765
""" SC101 Baby Names Project Adapted from Nick Parlante's Baby Names assignment by Jerry Liao. YOUR DESCRIPTION HERE """ import tkinter import babynames import babygraphicsgui as gui FILENAMES = [ 'data/full/baby-1900.txt', 'data/full/baby-1910.txt', 'data/full/baby-1920.txt', 'data/full/baby-1930.txt', ...
0
0
0
0
0
534
0
3
66
a88035b4dc8f36658950702134aeccfd01bff7ba
301
py
Python
helpers.py
Silve1ra/casting-agency-api
075ac2d465972b84a95fbd3e0eb0823ec33a867c
[ "MIT" ]
null
null
null
helpers.py
Silve1ra/casting-agency-api
075ac2d465972b84a95fbd3e0eb0823ec33a867c
[ "MIT" ]
null
null
null
helpers.py
Silve1ra/casting-agency-api
075ac2d465972b84a95fbd3e0eb0823ec33a867c
[ "MIT" ]
null
null
null
ITEMS_PER_PAGE = 10
23.153846
52
0.684385
ITEMS_PER_PAGE = 10 def paginate_items(request, selection): page = request.args.get('page', 1, type=int) start = (page - 1) * ITEMS_PER_PAGE end = start + ITEMS_PER_PAGE items = [item.serialize() for item in selection] current_items = items[start:end] return current_items
0
0
0
0
0
257
0
0
23
55e865bd9941f60900fd8edb25559a00824f8688
557
py
Python
Path_finding_visualization using bfs/bfs.py
arymandeshwal/Path-Finding-Visualization
9f79eb2b9cc9cf2e1515582a1bc71f5b4a657437
[ "MIT" ]
1
2020-06-30T15:13:14.000Z
2020-06-30T15:13:14.000Z
Path_finding_visualization using bfs/bfs.py
arymandeshwal/Path-Finding-Visualization
9f79eb2b9cc9cf2e1515582a1bc71f5b4a657437
[ "MIT" ]
null
null
null
Path_finding_visualization using bfs/bfs.py
arymandeshwal/Path-Finding-Visualization
9f79eb2b9cc9cf2e1515582a1bc71f5b4a657437
[ "MIT" ]
null
null
null
wall, goal = 1, 3 width_g, height_g = 28, 28
26.52381
107
0.479354
import collections wall, goal = 1, 3 width_g, height_g = 28, 28 def bfs_algo(grid,start): queue = collections.deque([[start]]) seen = set([start]) while queue: path = queue.popleft() x, y = path[-1] if grid[x][y] == goal: return path for x2, y2 in (...
0
0
0
0
0
457
0
-3
48
7c708ec1bf56a9b05c8cb0427ab9fe67a29e9919
17,436
py
Python
public/Python27/Lib/distutils/command/sdist.py
NingrumFadillah/cekmutasi
1fccb6cafb874c2a80ece9b71d7c682fd44dbd48
[ "MIT" ]
1
2020-11-26T18:53:46.000Z
2020-11-26T18:53:46.000Z
public/Python27/Lib/distutils/command/sdist.py
NingrumFadillah/cekmutasi
1fccb6cafb874c2a80ece9b71d7c682fd44dbd48
[ "MIT" ]
null
null
null
public/Python27/Lib/distutils/command/sdist.py
NingrumFadillah/cekmutasi
1fccb6cafb874c2a80ece9b71d7c682fd44dbd48
[ "MIT" ]
3
2017-04-07T12:02:22.000Z
2020-03-23T12:11:55.000Z
"""distutils.command.sdist Implements the Distutils 'sdist' command (create a source distribution).""" __revision__ = "$Id: sdist.py 81261 2010-05-17 10:54:43Z tarek.ziade $" def show_formats(): """Print all possible values for the 'formats' option (used by the "--help-formats" command-line option). """ ...
38.832962
78
0.582014
"""distutils.command.sdist Implements the Distutils 'sdist' command (create a source distribution).""" __revision__ = "$Id: sdist.py 81261 2010-05-17 10:54:43Z tarek.ziade $" import os import string import sys from glob import glob from warnings import warn from distutils.core import Command from distutils import d...
0
0
0
16,247
0
0
0
197
289
5294b56b586f084d81b078c81b47f955787e0b01
136
py
Python
h5py/tests/types/__init__.py
qsnake/h5py
45e77c3798032de2f740414a9e014fbca8c0ac18
[ "BSD-3-Clause" ]
null
null
null
h5py/tests/types/__init__.py
qsnake/h5py
45e77c3798032de2f740414a9e014fbca8c0ac18
[ "BSD-3-Clause" ]
null
null
null
h5py/tests/types/__init__.py
qsnake/h5py
45e77c3798032de2f740414a9e014fbca8c0ac18
[ "BSD-3-Clause" ]
8
2018-07-05T22:16:08.000Z
2021-08-19T06:07:45.000Z
""" Type and data-conversion test package. Tests the following: 1) HDF5 to NumPy type mapping 2) Data conversion """
13.6
42
0.639706
""" Type and data-conversion test package. Tests the following: 1) HDF5 to NumPy type mapping 2) Data conversion """
0
0
0
0
0
0
0
0
0
7b4436910fc762d59fcccf6a3d6b95104887537f
123
py
Python
Code/Python2.7/10one-n.py
nicholasz2510/General
e2783cad4da7f9b50c952c2b91ef311d22b1d56f
[ "MIT" ]
1
2019-11-21T15:56:03.000Z
2019-11-21T15:56:03.000Z
Code/Python2.7/10one-n.py
nicholasz2510/General
e2783cad4da7f9b50c952c2b91ef311d22b1d56f
[ "MIT" ]
12
2019-11-21T21:00:57.000Z
2022-02-27T01:46:56.000Z
Code/Python2.7/10one-n.py
nicholasz2510/General
e2783cad4da7f9b50c952c2b91ef311d22b1d56f
[ "MIT" ]
1
2019-11-21T20:49:18.000Z
2019-11-21T20:49:18.000Z
n = int(raw_input("What would you like to use for n? ")) answer = 0 for x in range(1, n+1): answer += x print answer
15.375
56
0.626016
n = int(raw_input("What would you like to use for n? ")) answer = 0 for x in range(1, n+1): answer += x print answer
0
0
0
0
0
0
0
0
0
273ad74acb2645b250bf948830ca59ebaea78cb2
2,770
py
Python
picture.py
Jacksonlakehhs/Picture
6a9ceefe659c17034b9a0b8c9e984d1a38fc3dd1
[ "MIT" ]
null
null
null
picture.py
Jacksonlakehhs/Picture
6a9ceefe659c17034b9a0b8c9e984d1a38fc3dd1
[ "MIT" ]
null
null
null
picture.py
Jacksonlakehhs/Picture
6a9ceefe659c17034b9a0b8c9e984d1a38fc3dd1
[ "MIT" ]
null
null
null
""" picture.py Author: Jackson Lake Credit: HHS page Github Tutorial Assignment: Use the ggame library to "paint" a graphical picture of something (e.g. a house, a face or landscape). Use at least: 1. Three different Color objects. 2. Ten different Sprite objects. 3. One (or more) RectangleAsset objects. 4. One (or ...
28.556701
104
0.720939
""" picture.py Author: Jackson Lake Credit: HHS page Github Tutorial Assignment: Use the ggame library to "paint" a graphical picture of something (e.g. a house, a face or landscape). Use at least: 1. Three different Color objects. 2. Ten different Sprite objects. 3. One (or more) RectangleAsset objects. 4. One (or ...
0
0
0
0
0
0
0
0
0
ed66809bed2e3426e2ba9136f081886e839ddd02
928
py
Python
project/migrations/0012_auto_20190505_1442.py
abhishekm47/restaurant-django
56993f2269e27c9b932b5f172cdf4db1e95292aa
[ "MIT" ]
null
null
null
project/migrations/0012_auto_20190505_1442.py
abhishekm47/restaurant-django
56993f2269e27c9b932b5f172cdf4db1e95292aa
[ "MIT" ]
null
null
null
project/migrations/0012_auto_20190505_1442.py
abhishekm47/restaurant-django
56993f2269e27c9b932b5f172cdf4db1e95292aa
[ "MIT" ]
null
null
null
# Generated by Django 2.0 on 2019-05-05 09:12
30.933333
141
0.59375
# Generated by Django 2.0 on 2019-05-05 09:12 import datetime from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('project', '0011_auto_20190425_1037'), ] operations = [ migrations.AlterField( model_name='menuitem', n...
0
0
0
800
0
0
0
13
68
918812d7ca13841d10ea04118a8e43bbf43c95de
391
py
Python
src/genie/libs/parser/iosxe/tests/ShowIpDhcpDatabase/cli/equal/golden1_expected.py
balmasea/genieparser
d1e71a96dfb081e0a8591707b9d4872decd5d9d3
[ "Apache-2.0" ]
204
2018-06-27T00:55:27.000Z
2022-03-06T21:12:18.000Z
src/genie/libs/parser/iosxe/tests/ShowIpDhcpDatabase/cli/equal/golden1_expected.py
balmasea/genieparser
d1e71a96dfb081e0a8591707b9d4872decd5d9d3
[ "Apache-2.0" ]
468
2018-06-19T00:33:18.000Z
2022-03-31T23:23:35.000Z
src/genie/libs/parser/iosxe/tests/ShowIpDhcpDatabase/cli/equal/golden1_expected.py
balmasea/genieparser
d1e71a96dfb081e0a8591707b9d4872decd5d9d3
[ "Apache-2.0" ]
309
2019-01-16T20:21:07.000Z
2022-03-30T12:56:41.000Z
expected_output = { "url": { "ftp://user:password@172.16.4.253/router-dhcp": { "read": "Dec 01 1997 12:01 AM", "written": "Never", "status": "Last read succeeded. Bindings have been loaded in RAM.", "delay_in_secs": 300, "timeout_in_secs": 300, ...
26.066667
79
0.475703
expected_output = { "url": { "ftp://user:password@172.16.4.253/router-dhcp": { "read": "Dec 01 1997 12:01 AM", "written": "Never", "status": "Last read succeeded. Bindings have been loaded in RAM.", "delay_in_secs": 300, "timeout_in_secs": 300, ...
0
0
0
0
0
0
0
0
0
042f2035facd42e8d86e6aafc24339ffb88e9749
3,656
py
Python
src/genie/libs/parser/iosxe/tests/ShowVlan/cli/equal/golden_output_vlan_2_expected.py
balmasea/genieparser
d1e71a96dfb081e0a8591707b9d4872decd5d9d3
[ "Apache-2.0" ]
204
2018-06-27T00:55:27.000Z
2022-03-06T21:12:18.000Z
src/genie/libs/parser/iosxe/tests/ShowVlan/cli/equal/golden_output_vlan_2_expected.py
balmasea/genieparser
d1e71a96dfb081e0a8591707b9d4872decd5d9d3
[ "Apache-2.0" ]
468
2018-06-19T00:33:18.000Z
2022-03-31T23:23:35.000Z
src/genie/libs/parser/iosxe/tests/ShowVlan/cli/equal/golden_output_vlan_2_expected.py
balmasea/genieparser
d1e71a96dfb081e0a8591707b9d4872decd5d9d3
[ "Apache-2.0" ]
309
2019-01-16T20:21:07.000Z
2022-03-30T12:56:41.000Z
expected_output = { "vlans": { "1": { "vlan_id": "1", "name": "default", "state": "active", "shutdown": False, "mtu": 1500, "said": 100001, "trans1": 0, "trans2": 0, "type": "enet", "inter...
32.936937
79
0.408643
expected_output = { "vlans": { "1": { "vlan_id": "1", "name": "default", "state": "active", "shutdown": False, "mtu": 1500, "said": 100001, "trans1": 0, "trans2": 0, "type": "enet", "inter...
0
0
0
0
0
0
0
0
0
296a16133fba9a356c755d1fd44a8d92f0ae6e1f
8,210
py
Python
scraping.py
seeeturtle/forest-watcher
e63d05ba35b66c7d5de2e6edb4d1562c4513dfff
[ "MIT" ]
null
null
null
scraping.py
seeeturtle/forest-watcher
e63d05ba35b66c7d5de2e6edb4d1562c4513dfff
[ "MIT" ]
null
null
null
scraping.py
seeeturtle/forest-watcher
e63d05ba35b66c7d5de2e6edb4d1562c4513dfff
[ "MIT" ]
null
null
null
from collections import namedtuple _alb_fields = [ "title", "link", "author", "pubDate", "description", "creator", "isbn", "isbn13", "itemId", "priceSales", "priceStandard", "stockStatus", "mileage", "cover", "categoryId", "categoryName", "publisher",...
23.25779
158
0.568088
import functools import json import operator import os from collections import Counter, namedtuple from multiprocessing import Pool, cpu_count from pprint import pprint import requests import xlrd import xmltodict from tqdm import tqdm _alb_fields = [ "title", "link", "author", "pubDate", "descrip...
513
0
0
0
0
5,340
0
-19
497
b9c712a7e566365d9ae6762ca6930fb2575830aa
2,755
py
Python
star_navi_backend/star_navi_backend/utils.py
Four-Velocity/star_navi_test
9765d23442b31ffbb2148c3ffab7c3b6b30214ae
[ "Unlicense" ]
null
null
null
star_navi_backend/star_navi_backend/utils.py
Four-Velocity/star_navi_test
9765d23442b31ffbb2148c3ffab7c3b6b30214ae
[ "Unlicense" ]
null
null
null
star_navi_backend/star_navi_backend/utils.py
Four-Velocity/star_navi_test
9765d23442b31ffbb2148c3ffab7c3b6b30214ae
[ "Unlicense" ]
null
null
null
import os from time import sleep import requests as r import yaml BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) def get_yaml(tp: str) -> dict: """ Convert YAML to python dict. Open dev_settings if exist. Other way open prod_settings. :param tp: category of settings which...
28.697917
87
0.62323
import os from time import sleep import requests as r import yaml BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) def get_yaml(tp: str) -> dict: """ Convert YAML to python dict. Open dev_settings if exist. Other way open prod_settings. :param tp: category of settings which...
0
0
0
0
0
398
0
0
26
e3a294384d04d671ba0596a94bb32835d7554db2
4,221
py
Python
fgclustering/forest_guided_clustering.py
HelmholtzAI-Consultants-Munich/forest_guided_clustering
3704047497d343417eee2a2f67dc3be201854b76
[ "MIT" ]
8
2021-11-04T11:44:18.000Z
2022-02-02T13:38:55.000Z
fgclustering/forest_guided_clustering.py
HelmholtzAI-Consultants-Munich/forest_guided_clustering
3704047497d343417eee2a2f67dc3be201854b76
[ "MIT" ]
4
2021-10-19T16:44:10.000Z
2021-11-08T14:33:35.000Z
fgclustering/forest_guided_clustering.py
HelmholtzAI-Consultants-Munich/forest_guided_clustering
3704047497d343417eee2a2f67dc3be201854b76
[ "MIT" ]
2
2021-09-13T08:26:59.000Z
2022-02-02T09:14:35.000Z
############################################ # imports ############################################ import fgclustering.utils as utils import fgclustering.optimizer as optimizer import fgclustering.plotting as plotting ############################################ # Forest-guided Clustering ###########################...
49.658824
144
0.697702
############################################ # imports ############################################ import fgclustering.utils as utils import fgclustering.optimizer as optimizer import fgclustering.plotting as plotting ############################################ # Forest-guided Clustering ###########################...
0
0
0
0
0
0
0
0
0
f4fd8478d10d669db73ec0483ef8530b8fdb54c7
851
py
Python
cdhweb/pages/context_processors.py
bwhicks/cdh-web
d6002dc1933a4d6e97f5459aafc9ab92cb1f8050
[ "Apache-2.0" ]
1
2017-11-21T16:02:33.000Z
2017-11-21T16:02:33.000Z
cdhweb/pages/context_processors.py
bwhicks/cdh-web
d6002dc1933a4d6e97f5459aafc9ab92cb1f8050
[ "Apache-2.0" ]
367
2017-08-14T16:05:41.000Z
2021-11-03T15:29:18.000Z
cdhweb/pages/context_processors.py
bwhicks/cdh-web
d6002dc1933a4d6e97f5459aafc9ab92cb1f8050
[ "Apache-2.0" ]
5
2017-09-08T21:08:49.000Z
2020-10-02T04:39:37.000Z
from cdhweb.pages.forms import SiteSearchForm from cdhweb.pages.models import PageIntro def page_intro(request): """Template context processor: if there is a PageIntro snippet for this page, add it to the context for display.""" # wagtail stores link url without leading and trailing slashes, # but req...
35.458333
76
0.723854
from cdhweb.pages.forms import SiteSearchForm from cdhweb.pages.models import PageIntro def page_intro(request): """Template context processor: if there is a PageIntro snippet for this page, add it to the context for display.""" # wagtail stores link url without leading and trailing slashes, # but req...
0
0
0
0
0
0
0
0
0
f20337c08370d886c3e94d9bb4e8f75308d8c4f7
399
py
Python
dangerfile.py
teastburn/danger-python
c943131b01558a6867218c7d91a4fa7a5ab3ec71
[ "MIT" ]
66
2020-01-23T15:31:34.000Z
2022-03-05T07:51:09.000Z
dangerfile.py
teastburn/danger-python
c943131b01558a6867218c7d91a4fa7a5ab3ec71
[ "MIT" ]
7
2020-01-23T16:37:03.000Z
2021-04-12T17:25:55.000Z
dangerfile.py
teastburn/danger-python
c943131b01558a6867218c7d91a4fa7a5ab3ec71
[ "MIT" ]
14
2020-01-23T15:17:39.000Z
2022-03-26T16:44:24.000Z
touched_files = danger.git.modified_files + danger.git.created_files has_source_changes = any(map(lambda f: f.startswith("danger_python"), touched_files)) has_changelog_entry = "CHANGELOG.md" in touched_files is_trivial = "#trivial" in danger.github.pr.title if has_source_changes and not has_changelog_entry and not is...
49.875
85
0.802005
touched_files = danger.git.modified_files + danger.git.created_files has_source_changes = any(map(lambda f: f.startswith("danger_python"), touched_files)) has_changelog_entry = "CHANGELOG.md" in touched_files is_trivial = "#trivial" in danger.github.pr.title if has_source_changes and not has_changelog_entry and not is...
0
0
0
0
0
0
0
0
0
83d5dcc0767d5e64221fcf3d14b33d0c2a0a7d9a
12,519
py
Python
vplexapi-7.0.0/vplexapi/models/engine.py
dell/python-vplex
02c5df5e7f9ed61a13a2838f21ca6467a25dd392
[ "Apache-2.0" ]
3
2020-12-01T11:22:13.000Z
2021-02-16T17:38:42.000Z
vplexapi-7.0.0/vplexapi/models/engine.py
dell/python-vplex
02c5df5e7f9ed61a13a2838f21ca6467a25dd392
[ "Apache-2.0" ]
null
null
null
vplexapi-7.0.0/vplexapi/models/engine.py
dell/python-vplex
02c5df5e7f9ed61a13a2838f21ca6467a25dd392
[ "Apache-2.0" ]
3
2021-01-01T21:07:55.000Z
2021-02-20T07:07:40.000Z
# coding: utf-8 """ VPlex REST API A definition for the next-gen VPlex API # noqa: E501 OpenAPI spec version: 0.1 Generated by: https://github.com/swagger-api/swagger-codegen.git """
27.57489
311
0.599728
# coding: utf-8 """ VPlex REST API A definition for the next-gen VPlex API # noqa: E501 OpenAPI spec version: 0.1 Generated by: https://github.com/swagger-api/swagger-codegen.git """ import pprint import re # noqa: F401 import six class Engine(object): """NOTE: This class is auto gene...
0
6,450
0
5,785
0
0
0
-31
105
07299342f9f59edd736455fe5cf8f959f8772d0f
616
py
Python
python/dynamic-programming/count-number-of-ways-to-cover-a-distance.py
fossabot/a-grim-loth
a6c8d549289a39ec981c1e0d0c754bb2708dfff9
[ "MIT" ]
4
2021-06-26T17:18:47.000Z
2022-02-02T15:02:27.000Z
python/dynamic-programming/count-number-of-ways-to-cover-a-distance.py
fossabot/a-grim-loth
a6c8d549289a39ec981c1e0d0c754bb2708dfff9
[ "MIT" ]
8
2021-06-29T07:00:32.000Z
2021-12-01T11:26:22.000Z
python/dynamic-programming/count-number-of-ways-to-cover-a-distance.py
fossabot/a-grim-loth
a6c8d549289a39ec981c1e0d0c754bb2708dfff9
[ "MIT" ]
3
2021-07-14T14:42:08.000Z
2021-12-07T19:36:53.000Z
# A Dynamic Programming based on Python3 # program to count number of ways to # cover a distance with 1, 2 and 3 steps # driver program dist = 4 print(printCountDP(dist))
21.241379
61
0.594156
# A Dynamic Programming based on Python3 # program to count number of ways to # cover a distance with 1, 2 and 3 steps def printCountDP(dist): count = [0] * (dist + 1) # Initialize base values. There is # one way to cover 0 and 1 distances # and two ways to cover 2 distance count[0] = 1 if di...
0
0
0
0
0
419
0
0
23
f6a467785c54771ef85fa13b6cb39f8aa6f71d70
1,425
py
Python
app/bot/main.py
ignatiy/zvonar-api
f471d5691e59b4d0d94877a4649069f782fd14f8
[ "MIT" ]
3
2021-04-28T04:52:27.000Z
2021-08-30T10:10:10.000Z
app/bot/main.py
ignatiy/zvonar-api
f471d5691e59b4d0d94877a4649069f782fd14f8
[ "MIT" ]
null
null
null
app/bot/main.py
ignatiy/zvonar-api
f471d5691e59b4d0d94877a4649069f782fd14f8
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- if __name__ == '__main__': main()
29.6875
111
0.748772
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import config import sys, traceback from datetime import datetime from telegram import Bot, Update, User, Message from telegram.ext import CommandHandler, Updater, MessageHandler, CallbackContext, Filters from telegram.utils.request import Request from telegram import Keyb...
144
0
0
0
0
922
0
172
177
d9b6984afb12d9fb4c8ffcaf41467860bbfab712
13,677
py
Python
NACA-foil-body-fitted/blockmeshdict.py
kaijunhuang1994/blockMeshDict-Python
1d640551980df6c66af057aad78d142e0cbae95e
[ "MIT" ]
null
null
null
NACA-foil-body-fitted/blockmeshdict.py
kaijunhuang1994/blockMeshDict-Python
1d640551980df6c66af057aad78d142e0cbae95e
[ "MIT" ]
null
null
null
NACA-foil-body-fitted/blockmeshdict.py
kaijunhuang1994/blockMeshDict-Python
1d640551980df6c66af057aad78d142e0cbae95e
[ "MIT" ]
null
null
null
#!/usr/bin/env python from __future__ import division, print_function import argparse import numpy as np from numpy import linspace, zeros, ones, sin, cos, arctan, pi def gen_blockmeshdict(foil="0012"): """ Write a `blockMeshDict` for a NACA foil at specified angle of attack. """ # Foil geometry c...
36.569519
141
0.455655
#!/usr/bin/env python from __future__ import division, print_function import argparse import numpy as np from numpy import linspace, zeros, ones, sin, cos, arctan, pi import os def gen_blockmeshdict(foil="0012"): """ Write a `blockMeshDict` for a NACA foil at specified angle of attack. """ # Foil geom...
0
0
0
0
0
0
0
-12
22
d399b88a18aecdddd170a1ff0ae5152520149d95
470
py
Python
pandayoda/common/serializer.py
wguanicedew/panda-yoda
df0860363818a219dd5bc2bfcda2659e598bd6bd
[ "Apache-2.0" ]
null
null
null
pandayoda/common/serializer.py
wguanicedew/panda-yoda
df0860363818a219dd5bc2bfcda2659e598bd6bd
[ "Apache-2.0" ]
null
null
null
pandayoda/common/serializer.py
wguanicedew/panda-yoda
df0860363818a219dd5bc2bfcda2659e598bd6bd
[ "Apache-2.0" ]
null
null
null
import logging logger = logging.getLogger(__name__)
21.363636
67
0.659574
import json,logging logger = logging.getLogger(__name__) def serialize(msg,pretty_print=False): try: if pretty_print: return json.dumps(msg,indent=2,sort_keys=True) else: return json.dumps(msg) except: logger.exception('failed to serialize the message: %s',msg) raise d...
0
0
0
0
0
365
0
5
46
4f8befee59e57e0c07b138ebb1f32b92934c4723
980
py
Python
Hard/Median_Of_Two_Sorted_Arrays.py
dianjiaogit/LeetCode_Python_solution
390693c839d1be8802c21ea81062443b6d5ea36f
[ "MIT" ]
null
null
null
Hard/Median_Of_Two_Sorted_Arrays.py
dianjiaogit/LeetCode_Python_solution
390693c839d1be8802c21ea81062443b6d5ea36f
[ "MIT" ]
null
null
null
Hard/Median_Of_Two_Sorted_Arrays.py
dianjiaogit/LeetCode_Python_solution
390693c839d1be8802c21ea81062443b6d5ea36f
[ "MIT" ]
null
null
null
# There are two sorted arrays nums1 and nums2 of size m and n respectively. # Find the median of the two sorted arrays. The overall run time complexity should be O(log (m+n)). # Example 1: # nums1 = [1, 3] # nums2 = [2] # The median is 2.0 # Example 2: # nums1 = [1, 2] # nums2 = [3, 4] # The median is (2 + 3)/2 = 2...
24.5
99
0.523469
# There are two sorted arrays nums1 and nums2 of size m and n respectively. # Find the median of the two sorted arrays. The overall run time complexity should be O(log (m+n)). # Example 1: # nums1 = [1, 3] # nums2 = [2] # The median is 2.0 # Example 2: # nums1 = [1, 2] # nums2 = [3, 4] # The median is (2 + 3)/2 = 2...
0
0
0
347
0
256
0
0
54
cb3441198ad038e40a02ae3b24dbdfc064616efb
2,428
py
Python
src/judge.py
Gomango999/codebreaker
407c4ac7a69c8db52cc7d2a57034cdda243c9134
[ "MIT" ]
1
2021-12-11T01:43:27.000Z
2021-12-11T01:43:27.000Z
src/judge.py
Gomango999/codebreaker
407c4ac7a69c8db52cc7d2a57034cdda243c9134
[ "MIT" ]
null
null
null
src/judge.py
Gomango999/codebreaker
407c4ac7a69c8db52cc7d2a57034cdda243c9134
[ "MIT" ]
1
2021-12-15T07:04:29.000Z
2021-12-15T07:04:29.000Z
# input sanity checker: prints 1 if valid # correct checker: prints 1 if valid # Returns score, status_message
36.238806
133
0.653213
import execute import random import traceback # input sanity checker: prints 1 if valid # correct checker: prints 1 if valid # Returns score, status_message async def run_judge(problem, user_input, user_output): box = execute.Box() sanity_exe = box.prepfile('sanity', problem.sanity_exe) try: resu...
0
0
2,247
0
0
0
0
-20
88
062605923e1edf65555afdc8134ca5a4fdc006fb
1,432
py
Python
Comparisoner.py
1970938138/LevelUper
2cbe9d61bdd0bc6d37a5e1fe8d2d9601132135f9
[ "MIT" ]
1
2020-08-08T19:32:43.000Z
2020-08-08T19:32:43.000Z
Comparisoner.py
1970938138/LevelUper
2cbe9d61bdd0bc6d37a5e1fe8d2d9601132135f9
[ "MIT" ]
null
null
null
Comparisoner.py
1970938138/LevelUper
2cbe9d61bdd0bc6d37a5e1fe8d2d9601132135f9
[ "MIT" ]
null
null
null
#/usr/bin/python3/ #coding=utf-8 #================ =================== # # NK1 # 20171210 13:37:11 # : _ #================ =================== Checking_Points1=r'<dt></dt>([\s\S]*?)</dd>' Checking_Points2=r'.+?\[(.*?)\].+?' Checking_Points_biology=r'...
29.833333
90
0.504888
#/usr/bin/python3/ #coding=utf-8 #================ 简介 =================== # 脚本: 伪·红石比较器 # 作者: 北方重工NK1 # 时间: 2017年12月10日 13:37:11 # 描述: 匹配元素_作业帮 #================ 简介 =================== import re Checking_Points1=r'<dt>考点:</dt>([\s\S]*?)</dd>' Checking_Poi...
422
0
0
0
0
821
0
-12
46
49dacf4bde624efc469d0f8d61220b29c7647828
1,199
py
Python
001. Add Two Numbers/solution.py
corkiwang1122/LeetCode
39b1680b58173e6ec23a475605c3450ce8f78a81
[ "MIT" ]
3,690
2015-01-03T03:40:23.000Z
2022-03-31T08:10:19.000Z
001. Add Two Numbers/solution.py
Windfall94/LeetCode
1756256d7e619164076bbf358c8f7ca68cd8bd79
[ "MIT" ]
21
2015-01-25T16:39:43.000Z
2021-02-26T05:28:22.000Z
001. Add Two Numbers/solution.py
Windfall94/LeetCode
1756256d7e619164076bbf358c8f7ca68cd8bd79
[ "MIT" ]
1,290
2015-01-09T01:28:20.000Z
2022-03-28T12:20:39.000Z
#!python3 # Definition for singly-linked list. if __name__ == "__main__": l1 = ListNode(2) l1.next = ListNode(4) l1.next.next = ListNode(3) l2 = ListNode(5) l2.next = ListNode(6) l2.next.next = ListNode(4) lsum = ListNode(7) lsum.next = ListNode(0) lsum.next.next = ListNode(8) ...
21.8
68
0.506255
#!python3 # Definition for singly-linked list. class ListNode: def __init__(self, x): self.val = x self.next = None class Solution: def addTwoNumbers(self, l1, l2): """ :type l1: ListNode :type l2: ListNode :rtype: ListNode """ head = ListNode(...
0
0
0
582
0
160
0
0
68
864473efccfc1e8c9a8b5879266e118d1d0fc8b1
1,165
py
Python
SAMBALoader/Transports/Transport.py
abcminiuser/sam-ba-loader
3154cb1cbc3c45d30438fafa8955a4c6e423c9d8
[ "MIT" ]
7
2016-03-21T18:31:17.000Z
2021-02-17T18:55:33.000Z
SAMBALoader/Transports/Transport.py
abcminiuser/sam-ba-loader
3154cb1cbc3c45d30438fafa8955a4c6e423c9d8
[ "MIT" ]
11
2016-03-20T20:33:58.000Z
2016-12-04T20:53:18.000Z
SAMBALoader/Transports/Transport.py
abcminiuser/sam-ba-loader
3154cb1cbc3c45d30438fafa8955a4c6e423c9d8
[ "MIT" ]
4
2016-03-21T18:31:31.000Z
2020-06-24T14:33:58.000Z
# # Open Source SAM-BA Programmer # Copyright (C) Dean Camera, 2016. # # dean [at] fourwalledcubicle [dot] com # www.fourwalledcubicle.com # # # Released under a MIT license, see LICENCE.txt.
20.803571
80
0.593133
# # Open Source SAM-BA Programmer # Copyright (C) Dean Camera, 2016. # # dean [at] fourwalledcubicle [dot] com # www.fourwalledcubicle.com # # # Released under a MIT license, see LICENCE.txt. import abc import logging class TimeoutError(Exception): """Exception thrown when a read operation times...
0
512
0
368
0
0
0
-18
91
a4c463bce1cc1ff7b6828d441bb881f6bbe7c1d7
2,624
py
Python
drafts/rebuild_frame.py
BrunoSanchez/capsule_N1
a5ee3b74afc27de1a954ae2f9f96c278a4723226
[ "BSD-3-Clause" ]
12
2017-04-13T06:49:42.000Z
2019-11-19T09:27:43.000Z
drafts/rebuild_frame.py
BrunoSanchez/capsule_N1
a5ee3b74afc27de1a954ae2f9f96c278a4723226
[ "BSD-3-Clause" ]
56
2017-09-05T16:00:57.000Z
2020-11-20T18:02:58.000Z
drafts/rebuild_frame.py
BrunoSanchez/capsule_N1
a5ee3b74afc27de1a954ae2f9f96c278a4723226
[ "BSD-3-Clause" ]
5
2017-10-08T16:55:40.000Z
2020-09-22T14:04:53.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- # # rebuild_frame.py # # Copyright 2016 Bruno S <bruno@oac.unc.edu.ar> # # This file is part of ProperImage (https://github.com/toros-astro/ProperImage) # License: BSD-3-Clause # Full Text: https://github.com/toros-astro/ProperImage/blob/master/LICENSE.txt # import os i...
28.835165
84
0.676829
#!/usr/bin/env python # -*- coding: utf-8 -*- # # rebuild_frame.py # # Copyright 2016 Bruno S <bruno@oac.unc.edu.ar> # # This file is part of ProperImage (https://github.com/toros-astro/ProperImage) # License: BSD-3-Clause # Full Text: https://github.com/toros-astro/ProperImage/blob/master/LICENSE.txt # import os im...
0
0
0
0
0
0
0
-24
66
8a8e45c6b2044b3b506b00abde61b8b723a2cc7e
1,035
py
Python
dataservices/migrations/0016_internetusage_country.py
uktrade/directory-api
45a9024a7ecc2842895201cbb51420ba9e57a168
[ "MIT" ]
2
2017-06-02T09:09:08.000Z
2021-01-18T10:26:53.000Z
dataservices/migrations/0016_internetusage_country.py
uktrade/directory-api
45a9024a7ecc2842895201cbb51420ba9e57a168
[ "MIT" ]
629
2016-10-10T09:35:52.000Z
2022-03-25T15:04:04.000Z
dataservices/migrations/0016_internetusage_country.py
uktrade/directory-api
45a9024a7ecc2842895201cbb51420ba9e57a168
[ "MIT" ]
5
2017-06-22T10:02:22.000Z
2022-03-14T17:55:21.000Z
# Generated by Django 2.2.13 on 2021-01-07 14:53
29.571429
120
0.681159
# Generated by Django 2.2.13 on 2021-01-07 14:53 from django.db import migrations, models import django.db.models.deletion def update_countries(apps, schema_editor): # We can't import the Person model directly as it may be a newer # version than this migration expects. We use the historical version. IU =...
0
0
0
412
0
427
0
30
114
3dcd550d074b7ec61777a55b7db45c0eded56dde
4,060
py
Python
applications/ibm_notebook/ibm_notebook.py
iostackproject/zoe-applications
94a1cfee2a45afcf7375af1f01502717ede3f9d7
[ "Apache-2.0" ]
null
null
null
applications/ibm_notebook/ibm_notebook.py
iostackproject/zoe-applications
94a1cfee2a45afcf7375af1f01502717ede3f9d7
[ "Apache-2.0" ]
null
null
null
applications/ibm_notebook/ibm_notebook.py
iostackproject/zoe-applications
94a1cfee2a45afcf7375af1f01502717ede3f9d7
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # Copyright (c) 2016, Francesco Pace # # 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...
43.655914
128
0.678079
#!/usr/bin/env python # Copyright (c) 2016, Francesco Pace # # 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...
0
0
0
0
0
1,905
0
27
68
d265bb95061be140a2fbade4620ead7c273e06d0
6,600
py
Python
nornir_salt/plugins/processors/SaltEventProcessor.py
dmulyalin/nornir-salt
184002995515dddc802b578400370c2219e94957
[ "MIT" ]
5
2021-01-22T09:34:55.000Z
2021-12-22T08:12:34.000Z
nornir_salt/plugins/processors/SaltEventProcessor.py
dmulyalin/nornir-salt
184002995515dddc802b578400370c2219e94957
[ "MIT" ]
2
2022-01-27T14:46:40.000Z
2022-02-28T16:59:01.000Z
nornir_salt/plugins/processors/SaltEventProcessor.py
dmulyalin/nornir-salt
184002995515dddc802b578400370c2219e94957
[ "MIT" ]
1
2021-01-10T04:37:08.000Z
2021-01-10T04:37:08.000Z
""" SaltEventProcessor Plugin ######################### Processor plugin to emit events on task execution progress, used by Nornir Proxy Runner modules to track tasks flow. SaltEventProcessor does not work outside of SaltStack environment. SaltEventProcessor reference ============================ .. autofunction:: ...
35.869565
91
0.591212
""" SaltEventProcessor Plugin ######################### Processor plugin to emit events on task execution progress, used by Nornir Proxy Runner modules to track tasks flow. SaltEventProcessor does not work outside of SaltStack environment. SaltEventProcessor reference ============================ .. autofunction:: ...
0
0
0
5,524
0
0
0
75
120
3716bae826c7763b2b5a647b070f06460590a0f5
371
py
Python
umb/__about__.py
fadhiilrachman/ReverseUMB
19cab7e50471a8002354d91ebb9a97e3f51f1906
[ "MIT" ]
1
2019-02-19T11:15:31.000Z
2019-02-19T11:15:31.000Z
umb/__about__.py
fadhiilrachman/UMBPrivateAPI
19cab7e50471a8002354d91ebb9a97e3f51f1906
[ "MIT" ]
null
null
null
umb/__about__.py
fadhiilrachman/UMBPrivateAPI
19cab7e50471a8002354d91ebb9a97e3f51f1906
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from __future__ import unicode_literals __copyright__ = 'Copyright 2018 by Fadhiil Rachman' __version__ = '1.0.1' __license__ = 'MIT' __author__ = 'Fadhiil Rachman' __author_email__ = 'fadhiilrachman@gmail.com' __url__ = 'https://github.com/fadhiilr...
28.538462
71
0.657682
# -*- coding: utf-8 -*- from __future__ import unicode_literals __copyright__ = 'Copyright 2018 by Fadhiil Rachman' __version__ = '1.0.1' __license__ = 'MIT' __author__ = 'Fadhiil Rachman' __author_email__ = 'fadhiilrachman@gmail.com' __url__ = 'https://github.com/fadhiilr...
0
0
0
0
0
0
0
0
0
3194320ee57bad0e6e337a87b5b963094566107d
2,517
py
Python
util/fuzz/dbcopy.py
umarcor/prjtrellis
9b3db7ba9a02e7d2f49c52ce062d5b22e320004c
[ "MIT" ]
93
2020-06-26T10:01:31.000Z
2022-03-30T03:01:23.000Z
util/fuzz/dbcopy.py
umarcor/prjtrellis
9b3db7ba9a02e7d2f49c52ce062d5b22e320004c
[ "MIT" ]
29
2020-06-26T10:12:03.000Z
2022-03-31T14:45:51.000Z
util/fuzz/dbcopy.py
umarcor/prjtrellis
9b3db7ba9a02e7d2f49c52ce062d5b22e320004c
[ "MIT" ]
20
2020-06-26T10:01:33.000Z
2022-03-18T22:36:39.000Z
import pytrellis """ Database copy utilities This is used where there are several tiles with different types but the same or similar bit databases - such as all the CIB tiles, some IO tiles, etc. """ def dbcopy(family, device, source, dest, copy_muxes=True, copy_words=True, copy_enums=True, copy_conns=True): ""...
32.269231
119
0.67064
import pytrellis """ Database copy utilities This is used where there are several tiles with different types but the same or similar bit databases - such as all the CIB tiles, some IO tiles, etc. """ def dbcopy(family, device, source, dest, copy_muxes=True, copy_words=True, copy_enums=True, copy_conns=True): ""...
0
0
0
0
0
827
0
0
46
284a914f4a42ea03047f7887872d097a591d2a0d
3,035
py
Python
plotsky.py
hagabbar/VItamin
c1ae6dfa27b8ab77193caacddd477fde0dece1c2
[ "MIT" ]
13
2019-06-26T01:51:54.000Z
2021-12-15T07:01:28.000Z
plotsky.py
hagabbar/VItamin
c1ae6dfa27b8ab77193caacddd477fde0dece1c2
[ "MIT" ]
12
2020-02-19T13:32:07.000Z
2022-03-12T00:00:52.000Z
plotsky.py
hagabbar/VItamin
c1ae6dfa27b8ab77193caacddd477fde0dece1c2
[ "MIT" ]
5
2019-10-23T01:23:56.000Z
2022-03-01T14:12:24.000Z
import matplotlib matplotlib.use('Agg') #matplotlib.rc('text', usetex=True)
39.934211
154
0.61944
import numpy as np from ligo.skymap import kde import matplotlib matplotlib.use('Agg') from matplotlib.colors import to_rgb from matplotlib import pyplot as plt from mpl_toolkits.basemap import Basemap #matplotlib.rc('text', usetex=True) def greedy(density): i,j = np.shape(density) idx = np.argsort(density.fla...
0
0
0
0
0
2,747
0
52
156
8c7e4cea5e9a1f974ea00d3262c69bbdf4f0e3cb
468
py
Python
Curso Udemy 2022/Curso_Luiz_Otavio/77_aula_count.py
Matheusfarmaceutico/Exercicios-Python
d1821bd9d11ea0707074c5fe11dead2e85476ebd
[ "MIT" ]
null
null
null
Curso Udemy 2022/Curso_Luiz_Otavio/77_aula_count.py
Matheusfarmaceutico/Exercicios-Python
d1821bd9d11ea0707074c5fe11dead2e85476ebd
[ "MIT" ]
null
null
null
Curso Udemy 2022/Curso_Luiz_Otavio/77_aula_count.py
Matheusfarmaceutico/Exercicios-Python
d1821bd9d11ea0707074c5fe11dead2e85476ebd
[ "MIT" ]
null
null
null
"""count - itertools""" # Apresentao do count from itertools import count # aceita nmero de ponto flutuante como step, mas n aceita um limite. contador = count(start=5, step=0.05) for v in contador: print(round(v, 2)) # arredonda em duas casas decimais if v > 10: break print(separador()) contador = co...
26
69
0.668803
def separador(): return "-="*30 """count - itertools""" # Apresentação do count from itertools import count # aceita número de ponto flutuante como step, mas n aceita um limite. contador = count(start=5, step=0.05) for v in contador: print(round(v, 2)) # arredonda em duas casas decimais if v > 10: ...
8
0
0
0
0
14
0
0
22
87032d2863af5326c2d522426973813601f385f1
2,817
py
Python
turbo_palm_tree/utility/parse_subreddit_list.py
jtara1/turbo_palm_tree
96ebe40aa176f1bb4acd036be8581666aa47ca17
[ "Apache-2.0" ]
4
2016-10-16T21:39:47.000Z
2019-11-12T05:56:17.000Z
turbo_palm_tree/utility/parse_subreddit_list.py
jtara1/turbo_palm_tree
96ebe40aa176f1bb4acd036be8581666aa47ca17
[ "Apache-2.0" ]
17
2017-12-31T08:43:09.000Z
2018-06-12T19:24:40.000Z
turbo_palm_tree/utility/parse_subreddit_list.py
jtara1/turbo_palm_tree
96ebe40aa176f1bb4acd036be8581666aa47ca17
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Tue Aug 30 15:26:13 2016 @author: jtara1 General syntax for subreddits.txt: : (colon character) denotes folder name subreddit url or word denotes subreddit For more examples see https://github.com/jtara1/RedditImageGrab/commit/8e4787ef9ac43ca694fc663be026f69a568bb622 Example o...
29.968085
111
0.648562
# -*- coding: utf-8 -*- """ Created on Tue Aug 30 15:26:13 2016 @author: jtara1 General syntax for subreddits.txt: : (colon character) denotes folder name subreddit url or word denotes subreddit For more examples see https://github.com/jtara1/RedditImageGrab/commit/8e4787ef9ac43ca694fc663be026f69a568bb622 Example o...
0
0
0
0
0
0
0
0
0
73788cb6f0857ad4d9db4996d005b5a40c26d508
2,609
py
Python
jmm/scripts/entry_point.py
zqmillet/japanese_media_manager
7f7c9ba9f48e67c5f68f80b6fe09675aded05858
[ "MIT" ]
null
null
null
jmm/scripts/entry_point.py
zqmillet/japanese_media_manager
7f7c9ba9f48e67c5f68f80b6fe09675aded05858
[ "MIT" ]
null
null
null
jmm/scripts/entry_point.py
zqmillet/japanese_media_manager
7f7c9ba9f48e67c5f68f80b6fe09675aded05858
[ "MIT" ]
null
null
null
if __name__ == '__main__': main() # pragma: no cover
33.448718
142
0.684553
from argparse import ArgumentParser from jmm.scripts.generate_configuration import generate_configuration from jmm.scripts.scrape import scrape from jmm.scripts.valid_configuration import valid_configuration from jmm.scripts.show_version import show_version from jmm.scripts import command as COMMAND def main() -> Non...
0
0
0
0
0
2,225
0
169
156
150ff69ccf3f48a574d3df803edbed10977201dd
3,168
py
Python
test/v4.1/06_rat_to_rel_test.py
gavinIRL/RHBot
1e22ae5ca7b67ebd6a72c23d9f46d5a8eb6e99cf
[ "MIT" ]
null
null
null
test/v4.1/06_rat_to_rel_test.py
gavinIRL/RHBot
1e22ae5ca7b67ebd6a72c23d9f46d5a8eb6e99cf
[ "MIT" ]
60
2021-03-29T14:29:49.000Z
2021-05-03T06:06:19.000Z
test/v4/06_rat_to_rel_test.py
gavinIRL/RHBot
1e22ae5ca7b67ebd6a72c23d9f46d5a8eb6e99cf
[ "MIT" ]
null
null
null
# This file is for testing and verifying the ratio-to-true calculation # It will be done in real-time rather than as part of test 5 # As it will be much quicker to debug for #54 print('Press Ctrl-C to quit.') if __name__ == "__main__": ct = ConvertTest() ct.start()
39.111111
78
0.57197
# This file is for testing and verifying the ratio-to-true calculation # It will be done in real-time rather than as part of test 5 # As it will be much quicker to debug for #54 import pyautogui import sys import time from windowcapture import WindowCapture import os print('Press Ctrl-C to quit.') class ConvertTest(...
0
0
0
2,777
0
0
0
-20
134
f30c69b7f172c3e2a035ed0d520b8882438ecaf2
1,426
py
Python
python/pyclaw/evolve/rp/rp_advection.py
rypjones/D-Claw
6eed8cc5270bf53768e25fa20fa5259cb3c1532e
[ "BSD-3-Clause" ]
7
2016-11-13T03:11:51.000Z
2021-09-07T18:59:48.000Z
python/pyclaw/evolve/rp/rp_advection.py
rypjones/D-Claw
6eed8cc5270bf53768e25fa20fa5259cb3c1532e
[ "BSD-3-Clause" ]
11
2020-01-14T18:00:37.000Z
2022-03-29T14:25:24.000Z
python/pyclaw/evolve/rp/rp_advection.py
rypjones/D-Claw
6eed8cc5270bf53768e25fa20fa5259cb3c1532e
[ "BSD-3-Clause" ]
6
2020-01-14T17:15:42.000Z
2021-12-03T17:28:44.000Z
#!/usr/bin/env python # encoding: utf-8 r""" Simple advection Riemann solvers Basic advection Riemann solvers of the form (1d) .. math:: q_t + A q_x = 0. :Authors: Kyle T. Mandli (2008-2-20): Initial version """ # ============================================================================ # Copyrig...
25.017544
78
0.517532
#!/usr/bin/env python # encoding: utf-8 r""" Simple advection Riemann solvers Basic advection Riemann solvers of the form (1d) .. math:: q_t + A q_x = 0. :Authors: Kyle T. Mandli (2008-2-20): Initial version """ # ============================================================================ # Copyrig...
0
0
0
0
0
0
0
0
0
49ee7d7222697c5b890a55e3050851794cb913ba
410
py
Python
bezman_shop/accounts/migrations/0002_customer_phone.py
baiztheprogrammer/bezman
2be9415fa5a6c74ec4922dc5d898f8fb17927be5
[ "MIT" ]
null
null
null
bezman_shop/accounts/migrations/0002_customer_phone.py
baiztheprogrammer/bezman
2be9415fa5a6c74ec4922dc5d898f8fb17927be5
[ "MIT" ]
null
null
null
bezman_shop/accounts/migrations/0002_customer_phone.py
baiztheprogrammer/bezman
2be9415fa5a6c74ec4922dc5d898f8fb17927be5
[ "MIT" ]
null
null
null
# Generated by Django 3.1.3 on 2020-12-02 06:26
20.5
49
0.585366
# Generated by Django 3.1.3 on 2020-12-02 06:26 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('accounts', '0001_initial'), ] operations = [ migrations.AddField( model_name='customer', name='phone', f...
0
0
0
296
0
0
0
19
46
e40b6cb20eca84551c1c82862d4948b634c023ca
147
py
Python
citylocations/views.py
minaelee/django_cityloc_pkg_minaelee
24aac64007cfd64f5a464005986b5b2bb1c7d3c0
[ "MIT" ]
2
2022-01-19T02:33:11.000Z
2022-01-19T02:33:13.000Z
citylocations/views.py
minaelee/django_cityloc_pkg_minaelee
24aac64007cfd64f5a464005986b5b2bb1c7d3c0
[ "MIT" ]
null
null
null
citylocations/views.py
minaelee/django_cityloc_pkg_minaelee
24aac64007cfd64f5a464005986b5b2bb1c7d3c0
[ "MIT" ]
1
2022-03-04T12:47:45.000Z
2022-03-04T12:47:45.000Z
# Create your views here.
21
60
0.748299
from django.shortcuts import render # Create your views here. def loc_nyc(request): return render(request, 'citylocations/loc_nyc.html', {})
0
0
0
0
0
61
0
14
44
40b3d7567dcaf95a2cec3ebf7551fe018259b5fa
10,289
py
Python
aim_va/train.py
sisl/neat
42758d910f453686366eddfd1aed440e34c94828
[ "MIT" ]
183
2021-08-18T13:22:37.000Z
2022-03-31T08:40:48.000Z
aim_va/train.py
sisl/neat
42758d910f453686366eddfd1aed440e34c94828
[ "MIT" ]
10
2021-09-24T15:30:06.000Z
2022-03-25T11:19:23.000Z
aim_va/train.py
sisl/neat
42758d910f453686366eddfd1aed440e34c94828
[ "MIT" ]
21
2021-09-11T13:32:54.000Z
2022-03-23T16:55:53.000Z
import argparse import json import os import numpy as np import torch import torch.nn as nn import torch.optim as optim from torch.utils.data import DataLoader torch.backends.cudnn.benchmark = True from model import MultiTaskImageNetwork from data import CARLA_Data from class_converter import sub_classes parser = a...
32.977564
151
0.712411
import argparse import json import os import numpy as np import torch import torch.nn as nn import torch.optim as optim from torch.utils.data import DataLoader import torch.nn.functional as F torch.backends.cudnn.benchmark = True from model import MultiTaskImageNetwork from data import CARLA_Data from class_converter...
0
0
0
5,519
0
0
0
10
45
b4efd4a90ea51089667b34a662653fecb46ca69a
4,575
py
Python
demo/2D/air_conditioning.py
Mopolino8/pylbm
b457ccdf1e7a1009807bd1136a276886f81a9e7d
[ "BSD-3-Clause" ]
null
null
null
demo/2D/air_conditioning.py
Mopolino8/pylbm
b457ccdf1e7a1009807bd1136a276886f81a9e7d
[ "BSD-3-Clause" ]
null
null
null
demo/2D/air_conditioning.py
Mopolino8/pylbm
b457ccdf1e7a1009807bd1136a276886f81a9e7d
[ "BSD-3-Clause" ]
1
2019-11-24T17:13:26.000Z
2019-11-24T17:13:26.000Z
import numpy as np import sympy as sp import pylbm X, Y, LA = sp.symbols('X, Y, LA') rho, qx, qy, T = sp.symbols('rho, qx, qy, T') def run(dx, Tf, generator="cython", sorder=None, withPlot=True): """ Parameters ---------- dx: double spatial step Tf: double final time genera...
28.416149
137
0.459672
import numpy as np import sympy as sp import mpi4py.MPI as mpi import pylbm X, Y, LA = sp.symbols('X, Y, LA') rho, qx, qy, T = sp.symbols('rho, qx, qy, T') def init_T(x, y, T0): return T0 def bc(f, m, x, y, T0): m[qx] = 0. m[qy] = 0. m[T] = T0 def bc_in(f, m, x, y, T0, Tin, ymax, rhoo, uo): m[q...
0
0
0
0
0
591
0
3
145
c7c34fe453581fe316f348a07f2451f2d0cde38b
338
py
Python
bsff/actors/migrations/0002_auto_20210517_0212.py
ErikSeguinte/BSFF_Django
a4dde02b2af233bbcf0c625c20a5f2814a8ca214
[ "MIT" ]
null
null
null
bsff/actors/migrations/0002_auto_20210517_0212.py
ErikSeguinte/BSFF_Django
a4dde02b2af233bbcf0c625c20a5f2814a8ca214
[ "MIT" ]
null
null
null
bsff/actors/migrations/0002_auto_20210517_0212.py
ErikSeguinte/BSFF_Django
a4dde02b2af233bbcf0c625c20a5f2814a8ca214
[ "MIT" ]
null
null
null
# Generated by Django 3.1.11 on 2021-05-17 02:12
18.777778
48
0.579882
# Generated by Django 3.1.11 on 2021-05-17 02:12 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('actors', '0001_initial'), ] operations = [ migrations.AlterModelOptions( name='actor', options={'ordering': ['full_name']},...
0
0
0
231
0
0
0
11
46
005e22a20ac5fadd1b8f8ad254b24fcf4dcaa32e
2,301
py
Python
networktoolkit/arpspoof.py
mokytis/networktoolkit
22f2facbb948a30eb63c8cdb2797a98ad771cfde
[ "MIT" ]
1
2021-12-15T22:55:16.000Z
2021-12-15T22:55:16.000Z
networktoolkit/arpspoof.py
mokytis/networktoolkit
22f2facbb948a30eb63c8cdb2797a98ad771cfde
[ "MIT" ]
null
null
null
networktoolkit/arpspoof.py
mokytis/networktoolkit
22f2facbb948a30eb63c8cdb2797a98ad771cfde
[ "MIT" ]
1
2022-02-25T07:04:29.000Z
2022-02-25T07:04:29.000Z
import time import click import scapy.all as scapy from networktoolkit import networkscan def gen_arp_response(target_ip, spoof_ip): """Generates an ARP Response packet :param target_ip: ip address to send packet to :param spoof_ip: ip address to spoof :return: A scapy packet """ if scan_...
30.68
124
0.65189
import time import click import scapy.all as scapy from networktoolkit import networkscan def gen_arp_response(target_ip, spoof_ip): """Generates an ARP Response packet :param target_ip: ip address to send packet to :param spoof_ip: ip address to spoof :return: A scapy packet """ if scan_...
0
370
0
0
0
0
0
0
23
817067682d486b5c02eeb1fa01201094f32b22f1
1,832
py
Python
simpleTicket/siteEngine/entities_utils.py
abogeorge/simpleTicket
ca550f4e9817e13e5723ad2483baddc036e435f5
[ "MIT" ]
null
null
null
simpleTicket/siteEngine/entities_utils.py
abogeorge/simpleTicket
ca550f4e9817e13e5723ad2483baddc036e435f5
[ "MIT" ]
null
null
null
simpleTicket/siteEngine/entities_utils.py
abogeorge/simpleTicket
ca550f4e9817e13e5723ad2483baddc036e435f5
[ "MIT" ]
null
null
null
# Retrieving user profile for the specified user # Retrieving tickets for the specificied user profile # Retrieving orders for the specified user profile # Retrieving the total number of subalterns for a specific user profile # Retrieving a list of all subalterns for a specific user profile # Returns the type of ...
32.714286
75
0.720524
from .models import Ticket, UserProfile, Order, TicketType, OrderType # Retrieving user profile for the specified user def get_profile_for_user(user): try: user_profile = user.userprofile return user_profile except UserProfile.DoesNotExist: return None # Retrieving tickets for the spec...
0
0
0
0
0
1,119
0
48
198
da7ed9ea4c2133be2c1a9db446d0ee720683a339
961
py
Python
scheduler/migrations/0004_auto_20181108_1604.py
gijzelaerr/buis
9878919fe58f600634306da78ce3c5ddba8388c1
[ "Apache-2.0" ]
null
null
null
scheduler/migrations/0004_auto_20181108_1604.py
gijzelaerr/buis
9878919fe58f600634306da78ce3c5ddba8388c1
[ "Apache-2.0" ]
18
2018-09-28T15:42:15.000Z
2019-12-17T08:56:28.000Z
scheduler/migrations/0004_auto_20181108_1604.py
gijzelaerr/buis
9878919fe58f600634306da78ce3c5ddba8388c1
[ "Apache-2.0" ]
null
null
null
# Generated by Django 2.1.1 on 2018-11-08 16:04
34.321429
148
0.631634
# Generated by Django 2.1.1 on 2018-11-08 16:04 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('scheduler', '0003_auto_20181108_1124'), ] operations = [ migrations.CreateModel( name='Workflow...
0
0
0
814
0
0
0
30
68
b7c4c865ea08866f15cac2e1cf22972cf9599e7a
794
py
Python
database.py
ngmhprogramming/Contact-Book
664a76087e8b35e1dfbb1f8fd33b1866c81849fb
[ "MIT" ]
4
2018-09-24T18:29:07.000Z
2019-03-04T13:58:19.000Z
database.py
ngmhprogramming/Contact-Book
664a76087e8b35e1dfbb1f8fd33b1866c81849fb
[ "MIT" ]
null
null
null
database.py
ngmhprogramming/Contact-Book
664a76087e8b35e1dfbb1f8fd33b1866c81849fb
[ "MIT" ]
null
null
null
#Database setup file #Useful when setting up for first time import sqlite3 conn = sqlite3.connect("/home/contactbook/website/storage.db") c = conn.cursor() #Create tables for users and books c.execute("DROP TABLE IF EXISTS users;") c.execute(""" CREATE TABLE IF NOT EXISTS users( id integer PRIMARY KE...
23.352941
64
0.680101
#Database setup file #Useful when setting up for first time import sqlite3 conn = sqlite3.connect("/home/contactbook/website/storage.db") c = conn.cursor() #Create tables for users and books c.execute("DROP TABLE IF EXISTS users;") c.execute(""" CREATE TABLE IF NOT EXISTS users( id integer PRIMARY KE...
0
0
0
0
0
0
0
0
0
140a2bed33d4c40bd9b60cc12d01904376b73824
1,665
py
Python
powergate/deals-POW-to-db.py
deplatformr/open-images
3726c9802bda1d7ecbbbd9920d5566daaecc9faa
[ "MIT" ]
2
2020-10-12T02:37:54.000Z
2020-10-14T15:16:49.000Z
powergate/deals-POW-to-db.py
deplatformr/open-images
3726c9802bda1d7ecbbbd9920d5566daaecc9faa
[ "MIT" ]
null
null
null
powergate/deals-POW-to-db.py
deplatformr/open-images
3726c9802bda1d7ecbbbd9920d5566daaecc9faa
[ "MIT" ]
null
null
null
import os import sqlite3 from datetime import datetime from pygate_grpc.client import PowerGateClient api = os.getenv('POWERGATE_API') token = os.getenv('POWERGATE_TOKEN') powergate = PowerGateClient(api, False) # get final storage deals info storage_deals = powergate.deals.storage_deal_records( include_pending=...
37.840909
305
0.678078
import os import sqlite3 from datetime import datetime from pygate_grpc.client import PowerGateClient api = os.getenv('POWERGATE_API') token = os.getenv('POWERGATE_TOKEN') powergate = PowerGateClient(api, False) # get final storage deals info storage_deals = powergate.deals.storage_deal_records( include_pending=...
0
0
0
0
0
0
0
0
0
8fd90e04dbe2c00d88ef581ceaa121652977d3e3
4,981
py
Python
sqlany_django/introspection.py
TheProjecter/sqlany-django
363be27eab819d879135422a78623b6ed487799a
[ "BSD-3-Clause" ]
null
null
null
sqlany_django/introspection.py
TheProjecter/sqlany-django
363be27eab819d879135422a78623b6ed487799a
[ "BSD-3-Clause" ]
null
null
null
sqlany_django/introspection.py
TheProjecter/sqlany-django
363be27eab819d879135422a78623b6ed487799a
[ "BSD-3-Clause" ]
null
null
null
import re foreign_key_re = re.compile(r"\sCONSTRAINT `[^`]*` FOREIGN KEY \(`([^`]*)`\) REFERENCES `([^`]*)` \(`([^`]*)`\)")
47.894231
114
0.566754
from django.db.backends import BaseDatabaseIntrospection from sqlanydb import ProgrammingError, OperationalError import re import sqlanydb foreign_key_re = re.compile(r"\sCONSTRAINT `[^`]*` FOREIGN KEY \(`([^`]*)`\) REFERENCES `([^`]*)` \(`([^`]*)`\)") class DatabaseIntrospection(BaseDatabaseIntrospection): data...
0
0
0
4,703
0
0
0
63
89
6124b4133af3c7aa4d43412211a0b2674e595a90
635
py
Python
test/cross_check_sklearn.py
Anselmoo/python-neuralnetwork
0c2d1e457f065b7f1a505f8a8182b134d6a8d3a0
[ "MIT" ]
null
null
null
test/cross_check_sklearn.py
Anselmoo/python-neuralnetwork
0c2d1e457f065b7f1a505f8a8182b134d6a8d3a0
[ "MIT" ]
null
null
null
test/cross_check_sklearn.py
Anselmoo/python-neuralnetwork
0c2d1e457f065b7f1a505f8a8182b134d6a8d3a0
[ "MIT" ]
null
null
null
if __name__ == '__main__': sklearn_reference_XOR()
35.277778
82
0.63622
from sklearn.neural_network import MLPClassifier from sklearn.model_selection import cross_validate def sklearn_reference_XOR(): X = [[0., 0.], [0., 1.], [1., 0.], [1., 1.]] y = [0., 1., 1., 0. ] clf = MLPClassifier(solver='lbfgs', alpha=1e-5, hidden_layer_sizes=(2, ), random_state=4...
0
0
0
0
0
457
0
57
67
2d7d85f85898bc2dd76286805e3dc6b7cdaca0f7
632
py
Python
src/py/bundle.py
iTNTPiston/celer-compiler
af9c1175eab3ee44eecd78f54f4e38e6d6475045
[ "MIT" ]
null
null
null
src/py/bundle.py
iTNTPiston/celer-compiler
af9c1175eab3ee44eecd78f54f4e38e6d6475045
[ "MIT" ]
1
2022-03-07T20:17:50.000Z
2022-03-07T20:17:50.000Z
src/py/bundle.py
iTNTPiston/celer-compiler
af9c1175eab3ee44eecd78f54f4e38e6d6475045
[ "MIT" ]
null
null
null
# This is a standalone bundler. You can use this script by itself # The output is a minimized JSON, which can be distributed # Usage: py gbundle.py <inputPath> # Output: bundle.json # PY_INJECT __main__()
23.407407
66
0.65981
# This is a standalone bundler. You can use this script by itself # The output is a minimized JSON, which can be distributed # Usage: py gbundle.py <inputPath> # Output: bundle.json # PY_INJECT def __main__(): if len(sys.argv) < 2: print(f"Usage: {sys.argv[0]} <input> ") sys.exit(1) ...
0
0
0
0
0
334
0
0
75
dfba76ff816591f4dcdb97195c8669ae29966c72
569
py
Python
04_TreesAndGraphs/Graph/class_Node.py
Chipdelmal/DataStructures
426e30b91e8f27843be1d9385dc800e5d0dc8d3f
[ "MIT" ]
1
2019-07-11T22:31:15.000Z
2019-07-11T22:31:15.000Z
04_TreesAndGraphs/Graph/class_Node.py
Chipdelmal/DataStructures
426e30b91e8f27843be1d9385dc800e5d0dc8d3f
[ "MIT" ]
null
null
null
04_TreesAndGraphs/Graph/class_Node.py
Chipdelmal/DataStructures
426e30b91e8f27843be1d9385dc800e5d0dc8d3f
[ "MIT" ]
null
null
null
############################################################################## # Node Class ##############################################################################
21.884615
78
0.42355
############################################################################## # Node Class ############################################################################## class Node(object): def __init__(self, data, links=None): self.__data = data self.__links = links @property def data(s...
0
170
0
204
0
0
0
0
23
450f23a1a2007d7e44f1b7e317ae1cae7a8ed2e1
5,133
py
Python
gimmemotifs/config.py
kipkurui/gimmemotifs
51bd0c6700877f79179f08e5bab7de70fc2eab94
[ "MIT" ]
1
2019-07-14T08:28:25.000Z
2019-07-14T08:28:25.000Z
gimmemotifs/config.py
kipkurui/gimmemotifs
51bd0c6700877f79179f08e5bab7de70fc2eab94
[ "MIT" ]
null
null
null
gimmemotifs/config.py
kipkurui/gimmemotifs
51bd0c6700877f79179f08e5bab7de70fc2eab94
[ "MIT" ]
null
null
null
# Copyright (c) 2009-2013 Simon van Heeringen <s.vanheeringen@ncmls.ru.nl> # # This module is free software. You can redistribute it and/or modify it under # the terms of the MIT License, see the file COPYING included with this # distribution. """ Configuration for GimmeMotifs """ ### CONSTANTS ### GM_VERSION = "0....
32.08125
79
0.606078
# Copyright (c) 2009-2013 Simon van Heeringen <s.vanheeringen@ncmls.ru.nl> # # This module is free software. You can redistribute it and/or modify it under # the terms of the MIT License, see the file COPYING included with this # distribution. """ Configuration for GimmeMotifs """ import ConfigParser import distutil...
0
0
0
4,383
0
0
0
-9
89
3daae4c1808fd8866972b8fbcba8e9f6495ccb2a
2,914
py
Python
MODULES/Persistence_RegistryRunKeys_SharpHide.py
evi1hack/viperpython
04bf8e31e21385edb58ea9d25296df062197df39
[ "BSD-3-Clause" ]
null
null
null
MODULES/Persistence_RegistryRunKeys_SharpHide.py
evi1hack/viperpython
04bf8e31e21385edb58ea9d25296df062197df39
[ "BSD-3-Clause" ]
null
null
null
MODULES/Persistence_RegistryRunKeys_SharpHide.py
evi1hack/viperpython
04bf8e31e21385edb58ea9d25296df062197df39
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- # @File : SimpleRewMsfModule.py # @Date : 2019/1/11 # @Desc :
38.853333
107
0.578243
# -*- coding: utf-8 -*- # @File : SimpleRewMsfModule.py # @Date : 2019/1/11 # @Desc : from Lib.ModuleAPI import * class PostModule(PostMSFCSharpModule): NAME_ZH = "Windows注册表Run键值持久化(C#)" DESC_ZH = "模块通过调用SharpHide.exe写入隐藏的注册表键值,实现持久化.\n" \ "SharpHide.exe会将目标exe路径写入到注册表Run键值中.\n" NAME_E...
351
0
0
2,655
0
0
0
6
46
68dcb0dea54dfb7d43b1ba7318299abe0fbf09ba
12,135
py
Python
Inference.py
Charlottecuc/Glow_TTS
bb2bd6384cc4ee13e61496c5f380f06d434f168b
[ "MIT" ]
31
2020-07-29T08:02:52.000Z
2022-03-19T12:57:53.000Z
Inference.py
Charlottecuc/Glow_TTS
bb2bd6384cc4ee13e61496c5f380f06d434f168b
[ "MIT" ]
3
2020-11-02T20:14:26.000Z
2021-04-08T01:12:33.000Z
Inference.py
CODEJIN/Glow_TTS
bb2bd6384cc4ee13e61496c5f380f06d434f168b
[ "MIT" ]
9
2020-09-09T03:48:44.000Z
2022-03-24T13:15:21.000Z
import torch import logging, yaml, os, sys, argparse import matplotlib matplotlib.use('agg') from Arg_Parser import Recursive_Parse hp = Recursive_Parse(yaml.load( open('Hyper_Parameters.yaml', encoding='utf-8'), Loader=yaml.Loader )) if not hp.Device is None: os.environ['CUDA_VISIBLE_DEVICES']= hp.De...
38.769968
248
0.602802
import torch import numpy as np import logging, yaml, os, sys, argparse, time, math from tqdm import tqdm import matplotlib matplotlib.use('agg') import matplotlib.pyplot as plt from scipy.io import wavfile from random import sample from Modules import GlowTTS from Datasets import Text_to_Token, Token_Stack, Mel_Stack...
6
3,990
0
5,960
0
0
0
202
300
75f57034047c546f47d90812c02bf87a3533167e
728
py
Python
corehq/sql_proxy_accessors/migrations/0035_livequery_sql.py
dimagilg/commcare-hq
ea1786238eae556bb7f1cbd8d2460171af1b619c
[ "BSD-3-Clause" ]
471
2015-01-10T02:55:01.000Z
2022-03-29T18:07:18.000Z
corehq/sql_proxy_accessors/migrations/0035_livequery_sql.py
dimagilg/commcare-hq
ea1786238eae556bb7f1cbd8d2460171af1b619c
[ "BSD-3-Clause" ]
14,354
2015-01-01T07:38:23.000Z
2022-03-31T20:55:14.000Z
corehq/sql_proxy_accessors/migrations/0035_livequery_sql.py
dimagilg/commcare-hq
ea1786238eae556bb7f1cbd8d2460171af1b619c
[ "BSD-3-Clause" ]
175
2015-01-06T07:16:47.000Z
2022-03-29T13:27:01.000Z
# Generated by Django 1.10.7 on 2017-07-03 21:23 from django.conf import settings from corehq.sql_db.operations import RawSQLMigration migrator = RawSQLMigration(('corehq', 'sql_proxy_accessors', 'sql_templates'), { 'PL_PROXY_CLUSTER_NAME': settings.PL_PROXY_CLUSTER_NAME })
26
80
0.696429
# Generated by Django 1.10.7 on 2017-07-03 21:23 from django.conf import settings from django.db import migrations from corehq.sql_db.operations import RawSQLMigration migrator = RawSQLMigration(('corehq', 'sql_proxy_accessors', 'sql_templates'), { 'PL_PROXY_CLUSTER_NAME': settings.PL_PROXY_CLUSTER_NAME }) cl...
0
0
0
388
0
0
0
11
45
df4317f0c3c77e1436e79549c46cfdffd452373a
5,772
py
Python
lib/services/vpc/ncloud_vpc/model/route_parameter.py
NaverCloudPlatform/ncloud-sdk-python
5976dfabd205c615fcf57ac2f0ab67313ee6953c
[ "MIT" ]
12
2018-11-20T04:30:49.000Z
2021-11-09T12:34:26.000Z
lib/services/vpc/ncloud_vpc/model/route_parameter.py
NaverCloudPlatform/ncloud-sdk-python
5976dfabd205c615fcf57ac2f0ab67313ee6953c
[ "MIT" ]
1
2019-01-24T15:56:15.000Z
2019-05-31T07:56:55.000Z
lib/services/vpc/ncloud_vpc/model/route_parameter.py
NaverCloudPlatform/ncloud-sdk-python
5976dfabd205c615fcf57ac2f0ab67313ee6953c
[ "MIT" ]
6
2018-06-29T03:45:50.000Z
2022-03-18T01:51:45.000Z
# coding: utf-8 """ vpc Generated by: https://github.com/swagger-api/swagger-codegen.git """
29.151515
123
0.602044
# coding: utf-8 """ vpc Generated by: https://github.com/swagger-api/swagger-codegen.git """ import pprint import re # noqa: F401 import six class RouteParameter(object): """NOTE: This class is auto generated by the swagger code generator program. Do not edit the class manually. """ ...
132
2,544
0
3,000
0
0
0
-31
105
d25d20d59baab1a7b7b3a00000bbbf30e1321af4
406
py
Python
src/morpyengine/Systems/Render.py
Morgiver/morpyengine
c02cb575edfb4d4cec3e09cec5869c53ef9772ab
[ "MIT" ]
null
null
null
src/morpyengine/Systems/Render.py
Morgiver/morpyengine
c02cb575edfb4d4cec3e09cec5869c53ef9772ab
[ "MIT" ]
null
null
null
src/morpyengine/Systems/Render.py
Morgiver/morpyengine
c02cb575edfb4d4cec3e09cec5869c53ef9772ab
[ "MIT" ]
null
null
null
import sdl2
23.882353
66
0.628079
import sdl2 import sdl2.ext def line(surface, x1, y1, x2, y2, color): color = sdl2.ext.Color(color[0], color[1], color[2], color[3]) sdl2.ext.line(surface, color, (x1, y1, x2, y2)) def rect(surface, x, y, w, h, color): color = sdl2.ext.Color(color[0], color[1], color[2], color[3]) sdl2.ext.fill(surf...
0
0
0
0
0
306
0
-6
91
507fea8ae32e927570bfb219cf5df38fee51a960
801
py
Python
algo/binary_search.py
xta0/Python-Playground
513ebd2ad7f0a8c69f2f04b4f7524b31e76fa5bc
[ "MIT" ]
null
null
null
algo/binary_search.py
xta0/Python-Playground
513ebd2ad7f0a8c69f2f04b4f7524b31e76fa5bc
[ "MIT" ]
null
null
null
algo/binary_search.py
xta0/Python-Playground
513ebd2ad7f0a8c69f2f04b4f7524b31e76fa5bc
[ "MIT" ]
null
null
null
import random array = random.sample(range(1,100),10) print(array) array.sort() print(array) print(binary_search(array,array[3]) == 3) print(binary_search_recursive(array,array[3],0,9) == 3)
23.558824
58
0.58427
import random def binary_search(array, num): first = 0 last = len(array)-1 while first <= last: mid = int((first+last)/2) if array[mid] == num: return mid elif array[mid] > num: last = mid - 1 else: first = mid + 1 return -1 def...
0
0
0
0
0
563
0
0
46
484cf743c24ab1fbee7284ccc093c584638eaedf
3,381
py
Python
standard-training/utils/figure_3_plotter.py
kaustubhsridhar/PoE-robustness
878bd94c64534afc4fdff04ada9e12aab6ed4b28
[ "MIT" ]
null
null
null
standard-training/utils/figure_3_plotter.py
kaustubhsridhar/PoE-robustness
878bd94c64534afc4fdff04ada9e12aab6ed4b28
[ "MIT" ]
null
null
null
standard-training/utils/figure_3_plotter.py
kaustubhsridhar/PoE-robustness
878bd94c64534afc4fdff04ada9e12aab6ed4b28
[ "MIT" ]
1
2022-03-10T05:28:58.000Z
2022-03-10T05:28:58.000Z
import matplotlib.pyplot as plt plt.style.use('seaborn') plt.rc('font', size=24) # controls default text sizes plt.rc('axes', titlesize=24) # fontsize of the axes title plt.rc('axes', labelsize=24) # fontsize of the x and y labels plt.rc('xtick', labelsize=24) # fontsize of the tick labels plt.rc('yt...
41.740741
97
0.598639
import numpy as np import matplotlib.pyplot as plt plt.style.use('seaborn') plt.rc('font', size=24) # controls default text sizes plt.rc('axes', titlesize=24) # fontsize of the axes title plt.rc('axes', labelsize=24) # fontsize of the x and y labels plt.rc('xtick', labelsize=24) # fontsize of the ti...
0
0
0
0
0
2,780
0
-3
115
d2a704e29e850f8c185306db4f5217c7f428ffa9
8,393
py
Python
app.py
brand-fabian/ood-xdmod
0d232bed6905e66ccc270f8e96af6bc0c7fbc425
[ "MIT" ]
null
null
null
app.py
brand-fabian/ood-xdmod
0d232bed6905e66ccc270f8e96af6bc0c7fbc425
[ "MIT" ]
null
null
null
app.py
brand-fabian/ood-xdmod
0d232bed6905e66ccc270f8e96af6bc0c7fbc425
[ "MIT" ]
null
null
null
import urllib3 from flask import Flask urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning) xdmod = Flask(__name__) OOD_URL = "https://ood.example.org/pun/dev/xdmod" XDMOD_URL = "https://xdmod.example.org" EXCL_HEADERS = ['content-encoding', 'content-length', 'transfer-encoding', 'connection'] VERIFY=Fa...
35.264706
109
0.577028
import requests import base64 import zlib import re from urllib.parse import quote, unquote import urllib3 from flask import Flask, redirect, request, Response from uuid import uuid4 from textwrap import wrap from lxml import etree urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning) xdmod = Flask(__name...
0
143
0
0
0
7,396
0
17
383
fe6b21eaf265ba3e318f32fa7935241ff691cad5
364
py
Python
source code samples/Network/client.py
NelsonBilber/python-overview
7438eddebaf33b534eb8a06da7769744e54052b1
[ "MIT" ]
null
null
null
source code samples/Network/client.py
NelsonBilber/python-overview
7438eddebaf33b534eb8a06da7769744e54052b1
[ "MIT" ]
null
null
null
source code samples/Network/client.py
NelsonBilber/python-overview
7438eddebaf33b534eb8a06da7769744e54052b1
[ "MIT" ]
null
null
null
# echo server - client # source code from here -> https://realpython.com/python-sockets/ import socket HOST = '127.0.0.1' PORT = 65432 with socket.socket(socket.AF_INET, socket.SOCK_STREAM) as s: s.connect((HOST, PORT)) s.sendall(b'Hello from client script') data = s.recv(1024) print ('Rece...
26
66
0.67033
# echo server - client # source code from here -> https://realpython.com/python-sockets/ import socket HOST = '127.0.0.1' PORT = 65432 with socket.socket(socket.AF_INET, socket.SOCK_STREAM) as s: s.connect((HOST, PORT)) s.sendall(b'Hello from client script') data = s.recv(1024) print ('Rece...
0
0
0
0
0
0
0
0
0
f04935366d11084ad6a2d168289b83338e9f447a
6,500
py
Python
scale/ingest/triggers/configuration/ingest_trigger_rule_1_0.py
stevevarner/scale
9623b261db4ddcf770f00df16afc91176142bb7c
[ "Apache-2.0" ]
null
null
null
scale/ingest/triggers/configuration/ingest_trigger_rule_1_0.py
stevevarner/scale
9623b261db4ddcf770f00df16afc91176142bb7c
[ "Apache-2.0" ]
null
null
null
scale/ingest/triggers/configuration/ingest_trigger_rule_1_0.py
stevevarner/scale
9623b261db4ddcf770f00df16afc91176142bb7c
[ "Apache-2.0" ]
null
null
null
"""Defines the configuration for an ingest trigger""" from __future__ import unicode_literals import logging logger = logging.getLogger(__name__) INGEST_TRIGGER_SCHEMA = { "type": "object", "required": ["data"], "additionalProperties": False, "properties": { "version": { "descript...
36.111111
124
0.638154
"""Defines the configuration for an ingest trigger""" from __future__ import unicode_literals import logging from jsonschema import validate from jsonschema.exceptions import ValidationError from ingest.triggers.ingest_trigger_condition import IngestTriggerCondition from job.configuration.data.job_connection import ...
0
0
0
4,068
0
0
0
312
201
daa5713f591bda079dae43ed4b025ec5547d445b
166
py
Python
scripts/portal/timeSeal02.py
G00dBye/YYMS
1de816fc842b6598d5b4b7896b6ab0ee8f7cdcfb
[ "MIT" ]
54
2019-04-16T23:24:48.000Z
2021-12-18T11:41:50.000Z
scripts/portal/timeSeal02.py
G00dBye/YYMS
1de816fc842b6598d5b4b7896b6ab0ee8f7cdcfb
[ "MIT" ]
3
2019-05-19T15:19:41.000Z
2020-04-27T16:29:16.000Z
scripts/portal/timeSeal02.py
G00dBye/YYMS
1de816fc842b6598d5b4b7896b6ab0ee8f7cdcfb
[ "MIT" ]
49
2020-11-25T23:29:16.000Z
2022-03-26T16:20:24.000Z
SEAL_CHECKER = 9300535 SEAL_OF_TIME = 2159367 if not sm.hasQuest(25672): sm.createQuestWithQRValue(25672, "1") sm.showFieldEffect("lightning/screenMsg/6", 0)
27.666667
50
0.753012
SEAL_CHECKER = 9300535 SEAL_OF_TIME = 2159367 if not sm.hasQuest(25672): sm.createQuestWithQRValue(25672, "1") sm.showFieldEffect("lightning/screenMsg/6", 0)
0
0
0
0
0
0
0
0
0
6be40d46faaa138af2d309cdb15bbfccb0f0f64f
475
py
Python
Templates/Template-1.py
CodeKnight626/codeBot
d56224b79193c17f949e9e99b7ab0b990dfd6c92
[ "Apache-2.0" ]
null
null
null
Templates/Template-1.py
CodeKnight626/codeBot
d56224b79193c17f949e9e99b7ab0b990dfd6c92
[ "Apache-2.0" ]
null
null
null
Templates/Template-1.py
CodeKnight626/codeBot
d56224b79193c17f949e9e99b7ab0b990dfd6c92
[ "Apache-2.0" ]
null
null
null
import discord #Libreria de discord client = discord.Client() # Evento que se llama cuando el bot inicia sesin # Evento que se llama cuando se recibe un mensaje client.run("Tu token aqui")
25
57
0.711579
import discord #Libreria de discord client = discord.Client() # Evento que se llama cuando el bot inicia sesión @client.event async def on_ready(): print('We have logged in as {0.user}'.format(client)) # Evento que se llama cuando se recibe un mensaje @client.event async def on_message(message): if message.a...
2
238
0
0
0
0
0
0
44
12a18aea017ffa0a14958524f458897493e2bfdf
539
py
Python
src/functions.py
zefe/python
8373130bbfa35f2d1328288523db23c20ea4f55a
[ "MIT" ]
null
null
null
src/functions.py
zefe/python
8373130bbfa35f2d1328288523db23c20ea4f55a
[ "MIT" ]
null
null
null
src/functions.py
zefe/python
8373130bbfa35f2d1328288523db23c20ea4f55a
[ "MIT" ]
null
null
null
# Divisas if __name__ == '__main__': run()
24.5
93
0.671614
# Divisas def run(): print('C A L C U L A D O R A D E D I V I S A S') print('Convietr de pesos mexicanos a pesos colombianos') print('') amount = float(input('Ingreasa la cantidad de pesos mexicanos que quieres convertir: ')) result = foreing_exchange_calculator(amount) print('${} pesos mex...
0
0
0
0
0
444
0
0
46
41f729f5fd23ec704d6194684d719cbc5c40b89a
10,532
py
Python
which.py
WeiFoo/WHICH
df8dbc50b219aefc54ba6371ef6788095b46a948
[ "MIT" ]
null
null
null
which.py
WeiFoo/WHICH
df8dbc50b219aefc54ba6371ef6788095b46a948
[ "MIT" ]
20
2015-04-29T01:13:27.000Z
2015-05-29T01:27:25.000Z
which.py
WeiFoo/WHICH
df8dbc50b219aefc54ba6371ef6788095b46a948
[ "MIT" ]
null
null
null
# __author__ = 'WeiFu' from __future__ import print_function, division import numpy as np import weka.core.jvm as jvm def XY(t, mydata, flag=False): '''generate X, Y coordinates for plotting''' if len(mydata) == 0: return [np.array([]), np.array([])] data = sorted(mydata, key=lambda z: z[the.DATA.loc], rev...
33.864952
120
0.636346
# __author__ = 'WeiFu' from __future__ import print_function, division import sys, pdb, random from ruler import * from Abcd import * import numpy as np import matplotlib.pyplot as plt from sklearn.tree import DecisionTreeRegressor from tuner import * from processarff import * from sk import rdivDemo import weka.core.j...
0
275
0
0
0
8,317
0
80
747
7d1f1ec839e6ec50e8a4a860444246ac22141aca
4,062
py
Python
logster-parsers/SlapdLogster.py
kalaksi/sensu-plugins
a3121010cddd46fc5a5566fb9bd7938c1f9f2405
[ "MIT" ]
null
null
null
logster-parsers/SlapdLogster.py
kalaksi/sensu-plugins
a3121010cddd46fc5a5566fb9bd7938c1f9f2405
[ "MIT" ]
null
null
null
logster-parsers/SlapdLogster.py
kalaksi/sensu-plugins
a3121010cddd46fc5a5566fb9bd7938c1f9f2405
[ "MIT" ]
null
null
null
#!/usr/bin/env python2 # -*- coding: utf-8 -*- # # Copyright (c) 2016 kalaksi@users.noreply.github.com # ...
50.148148
208
0.55613
#!/usr/bin/env python2 # -*- coding: utf-8 -*- # # Copyright (c) 2016 kalaksi@users.noreply.github.com # ...
0
0
0
2,081
0
0
0
56
112
6a3a039cf8076b41b5f4a96777e26a62ab17cca2
240
py
Python
tests/context.py
RonaldTheodoro/ygoprodeck-api-client
2a64411e08f1b7e32cc60aca5ccd5b5369a4b380
[ "MIT" ]
1
2020-04-09T22:55:05.000Z
2020-04-09T22:55:05.000Z
tests/context.py
RonaldTheodoro/ygoprodeck-api-client
2a64411e08f1b7e32cc60aca5ccd5b5369a4b380
[ "MIT" ]
10
2018-12-08T02:48:47.000Z
2021-10-02T20:18:10.000Z
tests/context.py
RonaldTheodoro/ygoprodeck-api-client
2a64411e08f1b7e32cc60aca5ccd5b5369a4b380
[ "MIT" ]
2
2018-12-08T05:46:54.000Z
2021-05-24T23:25:59.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- """ tests.context ~~~~~~~~~~~~~~~~~~~~~~ Add the ygoprodeck module to the tests context. """ import sys from settings import settings sys.path.append(settings.base_dir)
12.631579
47
0.65
#!/usr/bin/env python # -*- coding: utf-8 -*- """ tests.context ~~~~~~~~~~~~~~~~~~~~~~ Add the ygoprodeck module to the tests context. """ import sys from settings import settings sys.path.append(settings.base_dir) import ygoprodeck
0
0
0
0
0
0
0
-4
23
acabde74e58123908bb6db7007a6aa06d198218d
793
py
Python
ctpbee/json/__init__.py
yutiansut/ctpbee
02ceb3d4456a54b1b4f8066a2662c4b8fac1027f
[ "MIT" ]
null
null
null
ctpbee/json/__init__.py
yutiansut/ctpbee
02ceb3d4456a54b1b4f8066a2662c4b8fac1027f
[ "MIT" ]
null
null
null
ctpbee/json/__init__.py
yutiansut/ctpbee
02ceb3d4456a54b1b4f8066a2662c4b8fac1027f
[ "MIT" ]
3
2019-11-21T03:38:14.000Z
2022-02-14T08:09:11.000Z
from ctpbee.json.pollen import Pollen loads = Pollen.loads dumps = Pollen.dumps if __name__ == '__main__': t = SubscribeRequest(symbol='1', exchange=Status.ALLTRADED, datetime=datetime.now()) tick = {'float2': 53.12321, 'int': (123, "123", t, Status.ALLTRADED, 23432), ' ': None, ...
29.37037
88
0.510719
from ctpbee.json.pollen import Pollen loads = Pollen.loads dumps = Pollen.dumps if __name__ == '__main__': from ctpbee.constant import * t = SubscribeRequest(symbol='1', exchange=Status.ALLTRADED, datetime=datetime.now()) tick = {'float2': 53.12321, 'int': (123, "123", t, Status.ALLTRADED, 2...
0
0
0
0
0
0
0
8
26