hexsha
stringlengths
40
40
size
int64
4
1.02M
ext
stringclasses
8 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
209
max_stars_repo_name
stringlengths
5
121
max_stars_repo_head_hexsha
stringlengths
40
40
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
⌀
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
⌀
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
⌀
max_issues_repo_path
stringlengths
4
209
max_issues_repo_name
stringlengths
5
121
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
⌀
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
⌀
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
⌀
max_forks_repo_path
stringlengths
4
209
max_forks_repo_name
stringlengths
5
121
max_forks_repo_head_hexsha
stringlengths
40
40
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
⌀
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
⌀
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
⌀
content
stringlengths
4
1.02M
avg_line_length
float64
1.07
66.1k
max_line_length
int64
4
266k
alphanum_fraction
float64
0.01
1
54d795d51c5154079eaddc033a6037ab8810ee54
3,009
py
Python
gen_graph.py
tedzhouhk/SeDyT
39b842faa2d710fd74505ad2cb0389418d1c0973
[ "MIT" ]
3
2021-12-08T22:29:18.000Z
2022-03-21T20:47:03.000Z
gen_graph.py
tedzhouhk/SeDyT
39b842faa2d710fd74505ad2cb0389418d1c0973
[ "MIT" ]
null
null
null
gen_graph.py
tedzhouhk/SeDyT
39b842faa2d710fd74505ad2cb0389418d1c0973
[ "MIT" ]
1
2021-12-08T22:29:23.000Z
2021-12-08T22:29:23.000Z
import os import torch import pickle import numpy as np import scipy.sparse as sp from tqdm import tqdm from collections import Counter def to_normed_torch_sp(i0, i1, i2, cnt, nr, ne): v = list() for r, s, o in zip(i0, i1, i2): v.append(1 / (cnt[str(r) + str(o)])) i = torch.LongTensor([i0, i1, i2])...
38.088608
108
0.562978
0dd34855ab2fddbcf3358c5ff050fc151f4eae6f
10,747
py
Python
bnn_hmc/run_hmc.py
michaeljneely/google-research
8028769662d23426be6d316e4ab954e8c85cf8fe
[ "Apache-2.0" ]
1
2021-08-15T20:03:51.000Z
2021-08-15T20:03:51.000Z
bnn_hmc/run_hmc.py
michaeljneely/google-research
8028769662d23426be6d316e4ab954e8c85cf8fe
[ "Apache-2.0" ]
3
2021-05-09T07:24:30.000Z
2021-05-09T09:43:02.000Z
bnn_hmc/run_hmc.py
michaeljneely/google-research
8028769662d23426be6d316e4ab954e8c85cf8fe
[ "Apache-2.0" ]
1
2021-05-09T07:26:31.000Z
2021-05-09T07:26:31.000Z
# coding=utf-8 # Copyright 2021 The Google Research Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicab...
39.511029
80
0.71285
16e950569289a2afef4b67aeb3c1ba6f36ac4ffe
6,412
py
Python
tests/models/validators/v2_2_1/jsd_fd0ae0041dc59fb8aae545a8199d7b4.py
oboehmer/dnacentersdk
25c4e99900640deee91a56aa886874d9cb0ca960
[ "MIT" ]
32
2019-09-05T05:16:56.000Z
2022-03-22T09:50:38.000Z
tests/models/validators/v2_2_1/jsd_fd0ae0041dc59fb8aae545a8199d7b4.py
oboehmer/dnacentersdk
25c4e99900640deee91a56aa886874d9cb0ca960
[ "MIT" ]
35
2019-09-07T18:58:54.000Z
2022-03-24T19:29:36.000Z
tests/models/validators/v2_2_1/jsd_fd0ae0041dc59fb8aae545a8199d7b4.py
oboehmer/dnacentersdk
25c4e99900640deee91a56aa886874d9cb0ca960
[ "MIT" ]
18
2019-09-09T11:07:21.000Z
2022-03-25T08:49:59.000Z
# -*- coding: utf-8 -*- """Cisco DNA Center getDiscoveredDevicesByRange data model. Copyright (c) 2019-2021 Cisco Systems. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, inc...
30.679426
82
0.406269
c0215098c457ae09b11a5a02884acae03d465aea
11,784
py
Python
test_pgn_with_grabcut.py
ZhengZerong/CIHP_PGN
9036126e935236460592ca69a42935c29ac67227
[ "MIT" ]
null
null
null
test_pgn_with_grabcut.py
ZhengZerong/CIHP_PGN
9036126e935236460592ca69a42935c29ac67227
[ "MIT" ]
null
null
null
test_pgn_with_grabcut.py
ZhengZerong/CIHP_PGN
9036126e935236460592ca69a42935c29ac67227
[ "MIT" ]
null
null
null
from __future__ import print_function from utils import * from PIL import Image import numpy as np import tensorflow as tf import argparse from datetime import datetime import os import sys import time import scipy.misc import scipy.io as sio import cv2 from glob import glob os.environ["CUDA_VISIBLE_DEVICES"] = "0" N...
44.806084
125
0.630007
85d2025e1c9ad1f5d47749b10b651b1b15b863cc
6,368
py
Python
adafruit_hid/gamepad.py
tannewt/Adafruit_CircuitPython_HID
a23b80569f23ef109667dd8c595d319e8a30d620
[ "MIT" ]
1
2020-01-08T05:32:41.000Z
2020-01-08T05:32:41.000Z
adafruit_hid/gamepad.py
sureshk93/Adafruit_CircuitPython_HID
c9e07857dc10ff5e6c743e5e8c00e9b049800d09
[ "MIT" ]
null
null
null
adafruit_hid/gamepad.py
sureshk93/Adafruit_CircuitPython_HID
c9e07857dc10ff5e6c743e5e8c00e9b049800d09
[ "MIT" ]
null
null
null
# The MIT License (MIT) # # Copyright (c) 2018 Dan Halbert for Adafruit Industries # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the righ...
36.181818
92
0.630025
f85778a457537429283a95a91f26804c8b35c6b6
15,847
py
Python
lib/py/src/transport/TSSLSocket.py
zengqinglong/thrift
0293c3643b0075b510b9d92b2cc39b6d5e0fadb8
[ "Apache-2.0" ]
120
2017-10-24T12:20:02.000Z
2022-02-08T08:05:58.000Z
lib/py/src/transport/TSSLSocket.py
zengqinglong/thrift
0293c3643b0075b510b9d92b2cc39b6d5e0fadb8
[ "Apache-2.0" ]
37
2017-10-27T08:35:52.000Z
2019-05-28T18:32:53.000Z
lib/py/src/transport/TSSLSocket.py
zengqinglong/thrift
0293c3643b0075b510b9d92b2cc39b6d5e0fadb8
[ "Apache-2.0" ]
22
2017-10-26T14:21:44.000Z
2021-08-14T02:15:18.000Z
# # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
39.916877
100
0.607244
6c5db2966e13d7f2afe9c04d82d54b0b530f0dba
2,272
py
Python
users/migrations/0001_initial.py
arineto/twitter_monitor
c677c6983714bd44846883946176ac54e201c4d9
[ "MIT" ]
1
2020-03-13T04:39:59.000Z
2020-03-13T04:39:59.000Z
users/migrations/0001_initial.py
arineto/twitter_monitor
c677c6983714bd44846883946176ac54e201c4d9
[ "MIT" ]
3
2020-02-12T01:12:54.000Z
2021-06-10T20:36:15.000Z
users/migrations/0001_initial.py
arineto/twitter_monitor
c677c6983714bd44846883946176ac54e201c4d9
[ "MIT" ]
1
2017-06-09T21:21:51.000Z
2017-06-09T21:21:51.000Z
# -*- coding: utf-8 -*- # Generated by Django 1.11.1 on 2017-05-24 13:39 from __future__ import unicode_literals from django.db import migrations, models import django.utils.timezone import model_utils.fields class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0008_alte...
58.25641
266
0.676056
83c9f9709909c67adfeba7ed04702100745e7894
372
py
Python
src/fileIO.py
pannxe/ogogi
f1cd7d5c4d0eb0db13d2a71f4c1fc41bf1c6ee66
[ "MIT" ]
null
null
null
src/fileIO.py
pannxe/ogogi
f1cd7d5c4d0eb0db13d2a71f4c1fc41bf1c6ee66
[ "MIT" ]
null
null
null
src/fileIO.py
pannxe/ogogi
f1cd7d5c4d0eb0db13d2a71f4c1fc41bf1c6ee66
[ "MIT" ]
null
null
null
import codecs import os import abb def read(path): if os.path.exists(path): with codecs.open(path, "r", "utf-8") as f: return f.read().replace("\r", "") print(abb.error + "Cannot read " + path + "; File not found.") return "" def write(path, data): with codecs.open(path, "w", "ut...
21.882353
66
0.55914
d74e8a54976034c8c2ca127fd7cb782bc26c239f
454
py
Python
hc/api/migrations/0029_auto_20171102_2032.py
andela/healthchecks-7-horsemen
700476f1f46fcddb1a9cd31ec00d57f366951878
[ "BSD-3-Clause" ]
null
null
null
hc/api/migrations/0029_auto_20171102_2032.py
andela/healthchecks-7-horsemen
700476f1f46fcddb1a9cd31ec00d57f366951878
[ "BSD-3-Clause" ]
19
2017-10-18T09:58:19.000Z
2021-12-13T19:43:20.000Z
hc/api/migrations/0029_auto_20171102_2032.py
andela/healthchecks-7-horsemen
700476f1f46fcddb1a9cd31ec00d57f366951878
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.10 on 2017-11-02 20:32 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('api', '0028_auto_20171027_1048'), ] operations = [ migrations.AlterField( ...
21.619048
53
0.621145
f2ec09b74b3210daf05e1fa4d822e5585cfd29d6
649
py
Python
code/validation.py
Tom-a-Hawk/eve-building-restful-mongodb-backed-apis-course
844c1601d81aed85e5a3f5eddeb3ba299297dadc
[ "MIT" ]
66
2018-03-15T03:56:27.000Z
2021-12-13T14:36:31.000Z
code/validation.py
Tom-a-Hawk/eve-building-restful-mongodb-backed-apis-course
844c1601d81aed85e5a3f5eddeb3ba299297dadc
[ "MIT" ]
1
2020-11-27T07:15:28.000Z
2020-11-27T09:15:56.000Z
code/validation.py
Tom-a-Hawk/eve-building-restful-mongodb-backed-apis-course
844c1601d81aed85e5a3f5eddeb3ba299297dadc
[ "MIT" ]
37
2018-03-14T21:04:05.000Z
2021-11-29T11:43:48.000Z
import re from eve.io.mongo import Validator class MyValidator(Validator): """ You can extend or override the built-in validation rules easily by inheriting from the eve.io.mongo.Validator class """ def _validate_isodd(self, isodd, field, value): """ Define a brand new 'isodd' rule """ ...
38.176471
71
0.6302
1c6923b8df05120095c3eeaa0579b78a6fce8827
2,478
py
Python
mobile/urls.py
invinst/CPDB
c2d8ae8888b13d956cc1068742f18d45736d4121
[ "Apache-2.0" ]
16
2016-05-20T09:03:32.000Z
2020-09-13T14:23:06.000Z
mobile/urls.py
invinst/CPDB
c2d8ae8888b13d956cc1068742f18d45736d4121
[ "Apache-2.0" ]
2
2016-05-24T01:44:14.000Z
2016-06-17T22:19:45.000Z
mobile/urls.py
invinst/CPDB
c2d8ae8888b13d956cc1068742f18d45736d4121
[ "Apache-2.0" ]
2
2016-10-10T16:14:19.000Z
2020-10-26T00:17:02.000Z
from django.conf.urls import url, include from common.middleware.cache import orderless_cache_page from mobile.views.mobile_data_tool_view import MobileDataToolView from mobile.views.mobile_allegation_view import MobileAllegationView from mobile.views.mobile_document_request_view import MobileDocumentRequestView from ...
53.869565
111
0.72276
d4383627b5c46b7b5bf77ab78d2259f25f1ba70a
32,094
py
Python
speech/.ipynb_checkpoints/input_data-checkpoint.py
vihari/CSD
9902cdc8ea54f2650cd1396f904a06598a864a76
[ "MIT" ]
41
2020-05-01T10:08:26.000Z
2021-12-21T12:47:53.000Z
speech/.ipynb_checkpoints/input_data-checkpoint.py
kevinbro96/CSD
9902cdc8ea54f2650cd1396f904a06598a864a76
[ "MIT" ]
6
2020-07-10T03:48:16.000Z
2021-07-21T06:49:05.000Z
speech/.ipynb_checkpoints/input_data-checkpoint.py
kevinbro96/CSD
9902cdc8ea54f2650cd1396f904a06598a864a76
[ "MIT" ]
6
2020-06-07T13:57:36.000Z
2021-12-09T11:52:39.000Z
# Copyright 2017 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
43.37027
113
0.685611
4ad2acfdb6cfa9913c76f5481d76a4d1bd28df07
10,184
py
Python
cinder/api/v3/router.py
Mionsz/cinder
23494a6d6c51451688191e1847a458f1d3cdcaa5
[ "Apache-2.0" ]
571
2015-01-01T17:47:26.000Z
2022-03-23T07:46:36.000Z
cinder/api/v3/router.py
Mionsz/cinder
23494a6d6c51451688191e1847a458f1d3cdcaa5
[ "Apache-2.0" ]
37
2015-01-22T23:27:04.000Z
2021-02-05T16:38:48.000Z
cinder/api/v3/router.py
LightBitsLabs/cinder
b156b130e0dc7259a3fa7cae6eaaee8bc72f2fab
[ "Apache-2.0" ]
841
2015-01-04T17:17:11.000Z
2022-03-31T12:06:51.000Z
# Copyright 2011 OpenStack Foundation # Copyright 2011 United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance wi...
45.464286
78
0.578358
f7d16c1891e31a0eec2292406c69b07dd388c721
5,332
py
Python
test/functional/rpc_help.py
runcitadel/bitcoin
11ba1170e4e39e167901b8626a1395572e547a50
[ "MIT" ]
159
2016-07-09T13:02:19.000Z
2022-03-11T08:15:56.000Z
test/functional/rpc_help.py
runcitadel/bitcoin
11ba1170e4e39e167901b8626a1395572e547a50
[ "MIT" ]
40
2016-07-22T17:26:37.000Z
2022-03-22T19:37:32.000Z
test/functional/rpc_help.py
runcitadel/bitcoin
11ba1170e4e39e167901b8626a1395572e547a50
[ "MIT" ]
57
2016-10-21T23:57:47.000Z
2022-03-26T20:51:23.000Z
#!/usr/bin/env python3 # Copyright (c) 2018-2020 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Test RPC help output.""" from test_framework.test_framework import BitcoinTestFramework from test_fram...
40.090226
188
0.623218
05ac770a7e8762e26ff9c4557977cc928dd4b4fa
2,229
py
Python
library/setup.py
jtme/button-shim
19b80a236866fad068e6d3aeb643a1270d6ae934
[ "MIT" ]
33
2017-08-08T11:59:34.000Z
2022-03-09T09:50:29.000Z
library/setup.py
jtme/button-shim
19b80a236866fad068e6d3aeb643a1270d6ae934
[ "MIT" ]
17
2017-08-08T13:35:34.000Z
2020-08-05T09:34:08.000Z
library/setup.py
jtme/button-shim
19b80a236866fad068e6d3aeb643a1270d6ae934
[ "MIT" ]
14
2017-09-05T16:28:50.000Z
2020-07-20T15:33:22.000Z
#!/usr/bin/env python """ Copyright (c) 2017 Pimoroni Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, pub...
39.803571
86
0.664424
0d8000da1312d5b67eed1ebed702fd2d851247c2
3,540
py
Python
bindings/python/ensmallen/datasets/string/anaerovibriosprm50.py
AnacletoLAB/ensmallen_graph
b2c1b18fb1e5801712852bcc239f239e03076f09
[ "MIT" ]
5
2021-02-17T00:44:45.000Z
2021-08-09T16:41:47.000Z
bindings/python/ensmallen/datasets/string/anaerovibriosprm50.py
AnacletoLAB/ensmallen_graph
b2c1b18fb1e5801712852bcc239f239e03076f09
[ "MIT" ]
18
2021-01-07T16:47:39.000Z
2021-08-12T21:51:32.000Z
bindings/python/ensmallen/datasets/string/anaerovibriosprm50.py
AnacletoLAB/ensmallen
b2c1b18fb1e5801712852bcc239f239e03076f09
[ "MIT" ]
3
2021-01-14T02:20:59.000Z
2021-08-04T19:09:52.000Z
""" This file offers the methods to automatically retrieve the graph Anaerovibrio sp. RM50. The graph is automatically retrieved from the STRING repository. References --------------------- Please cite the following if you use the data: ```bib @article{szklarczyk2019string, title={STRING v11: protein--protein ...
32.777778
223
0.675141
4cd30991b18f5b6be7980be68cafad984083528c
558
py
Python
Day01-15/13_exercise_26.py
MaoningGuan/-Python-100-Days
d36e49d67a134278455438348efc41ffb28b778a
[ "MIT" ]
null
null
null
Day01-15/13_exercise_26.py
MaoningGuan/-Python-100-Days
d36e49d67a134278455438348efc41ffb28b778a
[ "MIT" ]
null
null
null
Day01-15/13_exercise_26.py
MaoningGuan/-Python-100-Days
d36e49d67a134278455438348efc41ffb28b778a
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import threading # 创建全局ThreadLocal对象: local_school = threading.local() def process_student(): # 获取当前线程关联的student: std = local_school.student print('Hello, %s (in %s)' % (std, threading.current_thread().name)) def process_thread(name): # 绑定ThreadLocal的student: local_schoo...
22.32
78
0.691756
7edaa9961c41e1f0f20f66077ee4e7980cf46fd8
2,115
py
Python
app/membership/services/account_service.py
yoshow/flask-quick-start
aa759d9eaee52a1a57ca82ebece492d96452157c
[ "MIT" ]
null
null
null
app/membership/services/account_service.py
yoshow/flask-quick-start
aa759d9eaee52a1a57ca82ebece492d96452157c
[ "MIT" ]
null
null
null
app/membership/services/account_service.py
yoshow/flask-quick-start
aa759d9eaee52a1a57ca82ebece492d96452157c
[ "MIT" ]
null
null
null
# coding:utf8 # !/usr/bin/python import sqlalchemy from ..models.account import Account as model, db from ...util.sqlalchemy_helper import set_entity_props class AccountService: def __init__(self): """ 初始化函数 """ self.query = model.query def save(self, args): """ 保存对象 ...
21.581633
86
0.535697
802adbece1b17012ddb7ff9a1d8f206ab5fd4793
47,729
py
Python
aiomwclient/client.py
Wadu436/aiomwclient
9f2750da52c67c219b028239ecc86d324f7f340c
[ "MIT" ]
1
2022-01-27T05:04:28.000Z
2022-01-27T05:04:28.000Z
aiomwclient/client.py
Wadu436/aiomwclient
9f2750da52c67c219b028239ecc86d324f7f340c
[ "MIT" ]
null
null
null
aiomwclient/client.py
Wadu436/aiomwclient
9f2750da52c67c219b028239ecc86d324f7f340c
[ "MIT" ]
null
null
null
# encoding=utf-8 import json import logging import ssl import warnings from collections import OrderedDict # import requests # from requests.auth import AuthBase, HTTPBasicAuth # from requests_oauthlib import OAuth1 import aiohttp import aiomwclient.errors as errors import aiomwclient.listing as listing from aiomwcli...
33.494035
99
0.526032
9df5d4eef1894439d8016cfb3aa45448777d79e4
6,885
py
Python
tests/lsp/test_document_symbol.py
kammoh/pygls
4772250f8ede25aee8e457dae5bca394aeccdd2f
[ "Apache-2.0" ]
239
2018-12-21T18:56:12.000Z
2022-03-30T20:20:16.000Z
tests/lsp/test_document_symbol.py
kammoh/pygls
4772250f8ede25aee8e457dae5bca394aeccdd2f
[ "Apache-2.0" ]
122
2018-12-28T17:35:37.000Z
2022-03-17T14:02:44.000Z
tests/lsp/test_document_symbol.py
kammoh/pygls
4772250f8ede25aee8e457dae5bca394aeccdd2f
[ "Apache-2.0" ]
63
2018-12-22T11:33:14.000Z
2022-03-29T05:34:29.000Z
############################################################################ # Copyright(c) Open Law Library. All rights reserved. # # See ThirdPartyNotices.txt in the project root for additional notices. # # # # Licensed u...
43.575949
100
0.537836
06d49bd59e3fde24c0352f8e180594987eb367b0
749
py
Python
sd/scripts/make_aishell4_test.py
DanBerrebbi/AISHELL-4
75ea24e547b671eae05aac365e32b3cd09bb3b3c
[ "Apache-2.0" ]
77
2021-06-08T11:16:53.000Z
2022-03-31T03:06:03.000Z
sd/scripts/make_aishell4_test.py
DanBerrebbi/AISHELL-4
75ea24e547b671eae05aac365e32b3cd09bb3b3c
[ "Apache-2.0" ]
5
2021-07-19T09:36:31.000Z
2022-01-21T13:27:34.000Z
sd/scripts/make_aishell4_test.py
DanBerrebbi/AISHELL-4
75ea24e547b671eae05aac365e32b3cd09bb3b3c
[ "Apache-2.0" ]
15
2021-07-02T03:02:29.000Z
2022-01-16T04:44:17.000Z
import argparse import os def main(args): init_wav_path = args.init_wav_path init_wav_scp_file = args.init_wav_scp_file with open(init_wav_scp_file, "w") as fw: for item in os.listdir(init_wav_path): print(item) if not str(item).endswith(".wav"): continue ...
29.96
91
0.656876
75462dc96d54b2a658dae4e938ba45d03630cf33
876
py
Python
tvsched/application/use_cases/actor/add_actor_use_case.py
astsu-dev/tv-schedule
1cea36147e66b7163df6f7098cfda4d43f3bdde2
[ "MIT" ]
null
null
null
tvsched/application/use_cases/actor/add_actor_use_case.py
astsu-dev/tv-schedule
1cea36147e66b7163df6f7098cfda4d43f3bdde2
[ "MIT" ]
null
null
null
tvsched/application/use_cases/actor/add_actor_use_case.py
astsu-dev/tv-schedule
1cea36147e66b7163df6f7098cfda4d43f3bdde2
[ "MIT" ]
null
null
null
from typing import Protocol from tvsched.application.interfaces import ILogger from tvsched.application.models.actor import ActorAdd class IAddActorUseCaseRepo(Protocol): async def add(self, actor: ActorAdd) -> None: """Adds actor to repo. Args: actor (ActorAdd): data for adding acto...
23.675676
76
0.63242
e84ce7359aba04ac06b7c913a736be1ce99f215b
9,453
py
Python
indico/modules/events/sessions/models/sessions.py
bkmgit/indico
d77ee121e35880a416b9b05e6098ea912d870b5c
[ "MIT" ]
1
2021-06-11T20:02:10.000Z
2021-06-11T20:02:10.000Z
indico/modules/events/sessions/models/sessions.py
bkmgit/indico
d77ee121e35880a416b9b05e6098ea912d870b5c
[ "MIT" ]
null
null
null
indico/modules/events/sessions/models/sessions.py
bkmgit/indico
d77ee121e35880a416b9b05e6098ea912d870b5c
[ "MIT" ]
null
null
null
# This file is part of Indico. # Copyright (C) 2002 - 2022 CERN # # Indico is free software; you can redistribute it and/or # modify it under the terms of the MIT License; see the # LICENSE file for more details. from datetime import timedelta from operator import attrgetter from sqlalchemy.event import listens_for f...
35.537594
103
0.666984
8c9050a595befbd324e28e3e89559e574ea9ebcc
5,754
py
Python
tests/profile/collector/test_stack.py
zhammer/dd-trace-py
4c30f6e36bfa34a63cd9b6884677c977f76d2a01
[ "Apache-2.0", "BSD-3-Clause" ]
5
2020-03-07T01:12:29.000Z
2021-04-21T00:53:19.000Z
tests/profile/collector/test_stack.py
zhammer/dd-trace-py
4c30f6e36bfa34a63cd9b6884677c977f76d2a01
[ "Apache-2.0", "BSD-3-Clause" ]
4
2019-11-22T20:58:01.000Z
2020-08-17T21:16:13.000Z
tests/profile/collector/test_stack.py
zhammer/dd-trace-py
4c30f6e36bfa34a63cd9b6884677c977f76d2a01
[ "Apache-2.0", "BSD-3-Clause" ]
3
2020-03-18T16:29:20.000Z
2020-07-20T16:05:10.000Z
import os import threading import time import timeit import pytest from ddtrace.vendor import six from ddtrace.vendor.six.moves import _thread from ddtrace.profile import recorder from ddtrace.profile.collector import stack from . import test_collector TESTING_GEVENT = os.getenv("DD_PROFILE_TEST_GEVENT", False) t...
26.273973
115
0.688217
b3497858cb7d0c21037eb6f824d7c4ad4bc335e8
1,331
py
Python
backend/app/app.py
jinnn-dev/patholearn
b4e6a18cfbf963e71640ed6cac3fc3a618a7ae15
[ "MIT" ]
1
2021-11-04T17:06:07.000Z
2021-11-04T17:06:07.000Z
backend/app/app.py
JamesNeumann/learning-by-annotations
c2b5e4b653eeb1c973aa5a7dad35ac8be18cb1ad
[ "MIT" ]
21
2021-11-01T10:13:56.000Z
2021-12-02T10:02:13.000Z
backend/app/app.py
jinnn-dev/patholearn
b4e6a18cfbf963e71640ed6cac3fc3a618a7ae15
[ "MIT" ]
1
2021-12-16T18:20:55.000Z
2021-12-16T18:20:55.000Z
import sentry_sdk from fastapi import FastAPI # from sentry_sdk import set_tag # from sentry_sdk.integrations.asgi import SentryAsgiMiddleware from starlette.middleware.cors import CORSMiddleware from starlette.middleware.gzip import GZipMiddleware from app.api.api import api_router from app.core.config impo...
24.648148
64
0.704733
a9058138efe170ed132b50e393f2a575426361ba
6,545
py
Python
napari/_vispy/overlays/interaction_box.py
MaksHess/napari
64a144607342c02177fc62fa83a3442ace0a98e7
[ "BSD-3-Clause" ]
1,345
2019-03-03T21:14:14.000Z
2022-03-31T19:46:39.000Z
napari/_vispy/overlays/interaction_box.py
MaksHess/napari
64a144607342c02177fc62fa83a3442ace0a98e7
[ "BSD-3-Clause" ]
3,904
2019-03-02T01:30:24.000Z
2022-03-31T20:17:27.000Z
napari/_vispy/overlays/interaction_box.py
MaksHess/napari
64a144607342c02177fc62fa83a3442ace0a98e7
[ "BSD-3-Clause" ]
306
2019-03-29T17:09:10.000Z
2022-03-30T09:54:11.000Z
import numpy as np from vispy.color.color_array import ColorArray from vispy.scene.visuals import Compound, Line, Markers from ...components._interaction_box_constants import Box class VispyInteractionBox: def __init__(self, viewer, parent=None, order=0): self._viewer = viewer self._interaction_...
34.267016
75
0.571123
b787fda0ffc58449066e50a1d6db2b2bc9245dfc
2,725
py
Python
pygmt/tests/test_blockmean.py
aliciaha1997/pygmt
a10af5d8deb3bf3090eab4b6492bcf8cf722cb71
[ "BSD-3-Clause" ]
1
2021-05-11T03:55:25.000Z
2021-05-11T03:55:25.000Z
pygmt/tests/test_blockmean.py
aliciaha1997/pygmt
a10af5d8deb3bf3090eab4b6492bcf8cf722cb71
[ "BSD-3-Clause" ]
2
2021-03-24T20:22:42.000Z
2021-03-25T01:02:41.000Z
pygmt/tests/test_blockmean.py
aliciaha1997/pygmt
a10af5d8deb3bf3090eab4b6492bcf8cf722cb71
[ "BSD-3-Clause" ]
null
null
null
""" Tests for blockmean. """ import os import numpy.testing as npt import pandas as pd import pytest from pygmt import blockmean from pygmt.datasets import load_sample_bathymetry from pygmt.exceptions import GMTInvalidInput from pygmt.helpers import GMTTempFile, data_kind @pytest.fixture(scope="module", name="datafr...
32.831325
86
0.68367
a3044e75b5e4de8a7eb97ff5c5ca9957d837e8d3
116
py
Python
backend/server/api/rest_models.py
jtucke2/Portfolio-Optimizer
25a94b24b50b6e6c9ef8421a8299fba78220b990
[ "MIT" ]
3
2019-03-10T18:51:42.000Z
2019-04-30T18:29:04.000Z
backend/server/api/rest_models.py
jtucke2/Portfolio-Optimizer
25a94b24b50b6e6c9ef8421a8299fba78220b990
[ "MIT" ]
37
2019-03-10T18:41:44.000Z
2022-03-02T03:36:29.000Z
backend/server/api/rest_models.py
jtucke2/Portfolio-Optimizer
25a94b24b50b6e6c9ef8421a8299fba78220b990
[ "MIT" ]
null
null
null
import enum class PriceIntervalEnum(enum.Enum): daily = 'daily' weekly = 'weekly' monthly = 'monthly'
14.5
35
0.655172
973175a19d1b242023113c8247c27c0ec5af286b
749
py
Python
downtime/main/migrations/0002_auto_20200303_2125.py
GSCrawley/downtime
57a1c8e00424c1948e1650cd980d541174febbd8
[ "MIT" ]
1
2020-05-03T03:57:26.000Z
2020-05-03T03:57:26.000Z
downtime/main/migrations/0002_auto_20200303_2125.py
GSCrawley/downtime
57a1c8e00424c1948e1650cd980d541174febbd8
[ "MIT" ]
null
null
null
downtime/main/migrations/0002_auto_20200303_2125.py
GSCrawley/downtime
57a1c8e00424c1948e1650cd980d541174febbd8
[ "MIT" ]
null
null
null
# Generated by Django 3.0.3 on 2020-03-04 05:25 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('main', '0001_initial'), ] operations = [ migrations.AddField( model_name='book', name='slug', field=mode...
25.827586
79
0.568758
c91e9cd7ee60d1eac23d121b4295f923180da4b2
598
py
Python
tests/test_output.py
domdfcoding/flake8-github-action
859a1075ee96031b27cdde05d9c654fc1c680c65
[ "MIT" ]
1
2021-03-01T07:02:41.000Z
2021-03-01T07:02:41.000Z
tests/test_output.py
domdfcoding/flake8-github-action
859a1075ee96031b27cdde05d9c654fc1c680c65
[ "MIT" ]
7
2021-08-11T09:25:47.000Z
2022-02-21T21:25:30.000Z
tests/test_output.py
domdfcoding/flake8-github-action
859a1075ee96031b27cdde05d9c654fc1c680c65
[ "MIT" ]
1
2022-01-14T17:36:46.000Z
2022-01-14T17:36:46.000Z
# 3rd party import pytest from coincidence.regressions import FileRegressionFixture, check_file_regression from domdf_python_tools.paths import PathPlus from flake8.main import cli # type: ignore bad_code = PathPlus(__file__).parent / "bad_code.py" def test_output(file_regression: FileRegressionFixture, capsys): w...
35.176471
89
0.784281
d5cacfe94fbb72a2350f9aac0c919e96a06d5f08
79
py
Python
dapiwrap/__init__.py
Trebek/DAPIWrap
7a4f7b418c882241a269881007e403fcf0380343
[ "MIT" ]
3
2015-08-01T10:03:56.000Z
2021-01-09T15:35:00.000Z
dapiwrap/__init__.py
Trebek/DAPIWrap
7a4f7b418c882241a269881007e403fcf0380343
[ "MIT" ]
null
null
null
dapiwrap/__init__.py
Trebek/DAPIWrap
7a4f7b418c882241a269881007e403fcf0380343
[ "MIT" ]
null
null
null
from dapiwrap import DAPIWrap from dapiwconst import * from dapiwtools import *
26.333333
29
0.835443
dfff972be1cd534e93ade6d7ea9a9dfa267153fb
1,847
py
Python
tools/c7n_azure/c7n_azure/constants.py
troylar/cloud-custodian
dd1b72bcdc2eef75ef88b9af3d88cb6e739b7293
[ "Apache-2.0" ]
null
null
null
tools/c7n_azure/c7n_azure/constants.py
troylar/cloud-custodian
dd1b72bcdc2eef75ef88b9af3d88cb6e739b7293
[ "Apache-2.0" ]
null
null
null
tools/c7n_azure/c7n_azure/constants.py
troylar/cloud-custodian
dd1b72bcdc2eef75ef88b9af3d88cb6e739b7293
[ "Apache-2.0" ]
null
null
null
""" Azure Functions """ # Docker version from https://hub.docker.com/r/microsoft/azure-functions/ FUNCTION_DOCKER_VERSION = 'DOCKER|mcr.microsoft.com/azure-functions/python:latest' FUNCTION_EXT_VERSION = '~2' FUNCTION_EVENT_TRIGGER_MODE = 'azure-event-grid' FUNCTION_TIME_TRIGGER_MODE = 'azure-periodic' FUNCTION_KEY_URL...
33.581818
87
0.815918
7379b77c643daf0a6ee5e6debc87795ab099ad1d
3,916
py
Python
gama/utilities/metrics.py
ElifCerenGok/gama
7906241c39e5ed3f335c305d02a37571e935d463
[ "Apache-2.0" ]
null
null
null
gama/utilities/metrics.py
ElifCerenGok/gama
7906241c39e5ed3f335c305d02a37571e935d463
[ "Apache-2.0" ]
null
null
null
gama/utilities/metrics.py
ElifCerenGok/gama
7906241c39e5ed3f335c305d02a37571e935d463
[ "Apache-2.0" ]
1
2022-01-22T13:37:36.000Z
2022-01-22T13:37:36.000Z
from enum import Enum from typing import Iterable, Tuple, Union from sklearn.metrics import get_scorer, make_scorer from sklearn.metrics._scorer import _ProbaScorer, _BaseScorer, SCORERS # scores that ground truth labels are not needed from sklearn.metrics import silhouette_score, calinski_harabasz_score, davies_boul...
36.598131
91
0.612615
6e6d582940d00a7d9a5b589aa51cb4d22e3caf89
46,699
py
Python
tensorflow/python/ops/ragged/ragged_array_ops.py
EricRemmerswaal/tensorflow
141ff27877579c81a213fa113bd1b474c1749aca
[ "Apache-2.0" ]
2
2021-09-30T20:13:09.000Z
2022-01-23T06:28:33.000Z
tensorflow/python/ops/ragged/ragged_array_ops.py
EricRemmerswaal/tensorflow
141ff27877579c81a213fa113bd1b474c1749aca
[ "Apache-2.0" ]
3
2022-02-06T00:10:55.000Z
2022-02-06T00:10:55.000Z
tensorflow/python/ops/ragged/ragged_array_ops.py
EricRemmerswaal/tensorflow
141ff27877579c81a213fa113bd1b474c1749aca
[ "Apache-2.0" ]
1
2021-11-21T02:32:27.000Z
2021-11-21T02:32:27.000Z
# Copyright 2018 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
40.785153
109
0.646245
528a7b613c435f3e7a339f9843dad77a07147873
533
py
Python
scripts/build_matrix.py
TuftsBCB/python-rwr
557f02dcd3dc1bbeb4859df5b88fe3542094dfd7
[ "MIT" ]
30
2017-02-13T02:02:27.000Z
2021-06-28T07:51:59.000Z
scripts/build_matrix.py
TuftsBCB/python-rwr
557f02dcd3dc1bbeb4859df5b88fe3542094dfd7
[ "MIT" ]
3
2017-06-19T09:25:39.000Z
2018-09-22T17:54:42.000Z
scripts/build_matrix.py
TuftsBCB/python-rwr
557f02dcd3dc1bbeb4859df5b88fe3542094dfd7
[ "MIT" ]
16
2017-04-07T14:27:16.000Z
2020-04-02T08:22:25.000Z
import sys import numpy as np def main(argv): file_prefix = argv[1] num_files = int(argv[2]) output_filename = argv[3] matrix = [] for idx in range(num_files): filename = '{}.{}.rwr'.format(file_prefix, idx) try: fp = open(filename, 'r') except IOError: ...
23.173913
64
0.592871
967a5ccae33b0e91cc8c5efa8ebcb1c706330f96
1,210
py
Python
django_facebook_auth/backends.py
pinetree408/django-facebook-auth
8524b31a31a47055ab960feb0e61678790e24bff
[ "MIT" ]
1
2016-02-16T01:59:48.000Z
2016-02-16T01:59:48.000Z
django_facebook_auth/backends.py
pinetree408/Django_Facebook_Auth
9de5996900a1e8e8c6a750dbe92523e5526bc865
[ "MIT" ]
1
2020-06-05T16:41:42.000Z
2020-06-05T16:41:42.000Z
django_facebook_auth/backends.py
pinetree408/Django_Facebook_Auth
9de5996900a1e8e8c6a750dbe92523e5526bc865
[ "MIT" ]
null
null
null
from django.conf import settings from django.contrib.auth import models as auth_models from models import FacebookSession import cgi import urllib class FacebookBackend: def authenticate(self, token=None): facebook_session = FacebookSession.objects.get( access_token=token, ) ...
26.888889
73
0.638843
048a9bcf77eabe9e5427de3422b02e80d7e1c915
6,298
py
Python
scattertext/termscoring/CredTFIDF.py
trajanov/scattertext
f77c25a42cd8bb204dceded9201b248c1e6e3780
[ "Apache-2.0" ]
null
null
null
scattertext/termscoring/CredTFIDF.py
trajanov/scattertext
f77c25a42cd8bb204dceded9201b248c1e6e3780
[ "Apache-2.0" ]
null
null
null
scattertext/termscoring/CredTFIDF.py
trajanov/scattertext
f77c25a42cd8bb204dceded9201b248c1e6e3780
[ "Apache-2.0" ]
null
null
null
import math import pandas as pd from scipy.stats import norm from scattertext.termscoring.CorpusBasedTermScorer import CorpusBasedTermScorer import numpy as np from scipy.sparse import csr_matrix class RunningStats: def __init__(self): self.n = 0 self.old_m = 0 self.new_m = 0 s...
39.610063
111
0.589076
ad794efd6b7589bf351ca408ec2752032b508fd6
2,346
py
Python
drakebot.py
M-D-M/drakebot
70cbe9f50597afeb673205d70ccc1494d2bcd35c
[ "MIT" ]
null
null
null
drakebot.py
M-D-M/drakebot
70cbe9f50597afeb673205d70ccc1494d2bcd35c
[ "MIT" ]
null
null
null
drakebot.py
M-D-M/drakebot
70cbe9f50597afeb673205d70ccc1494d2bcd35c
[ "MIT" ]
null
null
null
import re import logging import slack # constants MENTION_REGEX = r"^.*<@(|[WU].+?)>\W?(.*)" # global variables Drakebot_ID = '' Token = '' Message_Function = None class drakebot: def __init__(self, token: str, message_function): if (token is None or token == ''): raise Exception('No value found for token!') ...
29.696203
108
0.705882
b19a19636fefd7c6437edd86e125469927b49cfe
14,743
py
Python
hypercomplex.py
tallenglish/cayleydickenson
6bf9e016968801183adf697e872c405a0073239a
[ "Apache-2.0" ]
1
2022-03-12T00:42:34.000Z
2022-03-12T00:42:34.000Z
hypercomplex.py
tallenglish/cayleydickenson
6bf9e016968801183adf697e872c405a0073239a
[ "Apache-2.0" ]
null
null
null
hypercomplex.py
tallenglish/cayleydickenson
6bf9e016968801183adf697e872c405a0073239a
[ "Apache-2.0" ]
null
null
null
from functools import lru_cache from dunders import dunders, maths from numbers import Number import numpy as np class BaseNumber(Number): def copy(self): return self.__class__(self) def inverse(self): return self.conjugate() / self.square() def square(self): return (self.conjugate() * self).real def...
20.335172
121
0.655023
8e3bd06f65bb5b04efb90dce3263d3d63b7cc921
947
py
Python
pig-latin/pig_latin.py
ross-schlie/exercism-Python-track
4db690d11377377fc6f5cef6422da497272bbb31
[ "MIT" ]
null
null
null
pig-latin/pig_latin.py
ross-schlie/exercism-Python-track
4db690d11377377fc6f5cef6422da497272bbb31
[ "MIT" ]
null
null
null
pig-latin/pig_latin.py
ross-schlie/exercism-Python-track
4db690d11377377fc6f5cef6422da497272bbb31
[ "MIT" ]
null
null
null
"""exercism pig latin module.""" def translate(text): """ Translate text into pig latin. :param text string - text to translate. :return string = translated text. """ translated = "" vowels = "aeiou" vowel_sounds = ["xr", "yt"] for word in text.split(" "): translated_word...
27.852941
82
0.494192
7d24c5c6adf314d38630eecc504b98d7c54c4a09
13,695
py
Python
Cartwheel/lib/Python26/Lib/site-packages/OpenGL/raw/GLUT/constants.py
MontyThibault/centre-of-mass-awareness
58778f148e65749e1dfc443043e9fc054ca3ff4d
[ "MIT" ]
null
null
null
Cartwheel/lib/Python26/Lib/site-packages/OpenGL/raw/GLUT/constants.py
MontyThibault/centre-of-mass-awareness
58778f148e65749e1dfc443043e9fc054ca3ff4d
[ "MIT" ]
null
null
null
Cartwheel/lib/Python26/Lib/site-packages/OpenGL/raw/GLUT/constants.py
MontyThibault/centre-of-mass-awareness
58778f148e65749e1dfc443043e9fc054ca3ff4d
[ "MIT" ]
null
null
null
"""Constants for OpenGL.GLUT Automatically generated by the generateraw script, do not edit! """ from ctypes import * from OpenGL import platform, arrays from OpenGL.constant import Constant from OpenGL import constants as GLconstants GLvoid = GLconstants.GLvoid GLUT_ACCUM = Constant( 'GLUT_ACCUM', 4) GLUT_ACTIVE_...
39.466859
82
0.802775
df89ef504de05b9402187037391e45ae8b3cc7e1
25,029
py
Python
ASoP-Spectral/ASoP1_Spectral/ASoP1_spectral_cmec_workflow.py
nick-klingaman/ASoP
b3fe156194d02573af03cf3ef33bb0bdbc07fbcb
[ "Apache-2.0" ]
1
2018-04-20T10:01:28.000Z
2018-04-20T10:01:28.000Z
ASoP-Spectral/ASoP1_Spectral/ASoP1_spectral_cmec_workflow.py
nick-klingaman/ASoP
b3fe156194d02573af03cf3ef33bb0bdbc07fbcb
[ "Apache-2.0" ]
1
2021-12-02T22:17:40.000Z
2021-12-02T22:17:40.000Z
ASoP-Spectral/ASoP1_Spectral/ASoP1_spectral_cmec_workflow.py
nick-klingaman/ASoP
b3fe156194d02573af03cf3ef33bb0bdbc07fbcb
[ "Apache-2.0" ]
1
2022-02-21T06:25:38.000Z
2022-02-21T06:25:38.000Z
# Copyright 2021 Lawrence Livermore National Security, LLC """ This script is used by cmec-driver to run the ASoP-Spectral metrics. It is based on the workflow in ASoP1_spectral_main.py and can be called with the aruments listed below. Keys that can be set in the config or settings dictionary are: region, timescale-all...
43.079174
140
0.667066
4cde3f1dec7283a2bfa345ba6c0508c54bc98c1b
3,492
py
Python
bindings/python/ensmallen/datasets/string/streptococcusspcaviae.py
AnacletoLAB/ensmallen
b2c1b18fb1e5801712852bcc239f239e03076f09
[ "MIT" ]
5
2021-09-10T18:31:58.000Z
2022-03-24T04:28:04.000Z
bindings/python/ensmallen/datasets/string/streptococcusspcaviae.py
AnacletoLAB/ensmallen_graph
b2c1b18fb1e5801712852bcc239f239e03076f09
[ "MIT" ]
18
2021-01-07T16:47:39.000Z
2021-08-12T21:51:32.000Z
bindings/python/ensmallen/datasets/string/streptococcusspcaviae.py
AnacletoLAB/ensmallen
b2c1b18fb1e5801712852bcc239f239e03076f09
[ "MIT" ]
3
2021-01-14T02:20:59.000Z
2021-08-04T19:09:52.000Z
""" This file offers the methods to automatically retrieve the graph Streptococcus sp. caviae. The graph is automatically retrieved from the STRING repository. References --------------------- Please cite the following if you use the data: ```bib @article{szklarczyk2019string, title={STRING v11: protein--prote...
33.257143
223
0.677835
32f07efa73eceecffe37d4b24e35a276867582c8
8,776
py
Python
Computer Vision/CS131/HW3/test.py
bayeslabs/AiGym
30c126fc2e140f9f164ff3f20638242b230e7e52
[ "MIT" ]
22
2019-07-15T08:26:31.000Z
2022-01-17T06:29:17.000Z
Computer Vision/CS131/HW3/test.py
bayeslabs/AiGym
30c126fc2e140f9f164ff3f20638242b230e7e52
[ "MIT" ]
26
2020-03-24T17:18:21.000Z
2022-03-11T23:54:37.000Z
Computer Vision/CS131/HW3/test.py
bayeslabs/AiGym
30c126fc2e140f9f164ff3f20638242b230e7e52
[ "MIT" ]
8
2019-07-17T09:13:11.000Z
2021-04-16T11:20:51.000Z
# Setup from __future__ import print_function import numpy as np from skimage import filters from skimage.feature import corner_peaks from skimage.io import imread import matplotlib.pyplot as plt from time import time plt.rcParams['figure.figsize'] = (15.0, 12.0) # set default size of plots plt.rcParams['image.interpo...
27.510972
77
0.700091
377ffd4a5d18f514bb80674a399102c38507f570
2,206
py
Python
emol/emol/models/faux_user.py
lrt512/emol
e1dd3462632a525c3b9701d4fd9a332d19c93b85
[ "MIT" ]
null
null
null
emol/emol/models/faux_user.py
lrt512/emol
e1dd3462632a525c3b9701d4fd9a332d19c93b85
[ "MIT" ]
null
null
null
emol/emol/models/faux_user.py
lrt512/emol
e1dd3462632a525c3b9701d4fd9a332d19c93b85
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """A faux user for the purposes of user self-service.""" from flask import current_app from flask_login import AnonymousUserMixin class FauxUser(AnonymousUserMixin): """A proxy for the User class. This is specifically for allowing combatants to update their own information via se...
26.578313
80
0.643246
d70ab5b190e7dbf9384d4988e6dc38be805b6dd4
51
py
Python
lib/ctyEnge/OverallPerformance/__init__.py
JoshOrndorff/snippets
ef06e03de09897014f88d89a84b597aabde7edaa
[ "Unlicense" ]
null
null
null
lib/ctyEnge/OverallPerformance/__init__.py
JoshOrndorff/snippets
ef06e03de09897014f88d89a84b597aabde7edaa
[ "Unlicense" ]
null
null
null
lib/ctyEnge/OverallPerformance/__init__.py
JoshOrndorff/snippets
ef06e03de09897014f88d89a84b597aabde7edaa
[ "Unlicense" ]
null
null
null
from .OverallPerformance import OverallPerformance
25.5
50
0.901961
a15180cd483e8fd74215ef05afc9433489b94be6
8,595
py
Python
harvest/cli.py
ComplianceAsCode/auditree-harvest
b2b0c01ac5a9fd2dd7e673bd70ef638b6a623822
[ "Apache-2.0" ]
9
2020-08-06T22:56:04.000Z
2022-01-18T17:02:58.000Z
harvest/cli.py
ComplianceAsCode/auditree-harvest
b2b0c01ac5a9fd2dd7e673bd70ef638b6a623822
[ "Apache-2.0" ]
15
2020-08-14T13:29:59.000Z
2021-03-22T13:23:19.000Z
harvest/cli.py
ComplianceAsCode/auditree-harvest
b2b0c01ac5a9fd2dd7e673bd70ef638b6a623822
[ "Apache-2.0" ]
1
2021-07-16T08:18:20.000Z
2021-07-16T08:18:20.000Z
# -*- mode:python; coding:utf-8 -*- # Copyright (c) 2020 IBM Corp. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # ...
31.599265
79
0.562885
5547753ba92a6360aa744c6c7578d2399dde51f8
4,074
py
Python
pre_commit_hooks/sort_package_xml.py
tier4/pre-commit-hooks-ros
1a8353a2748fcd966b9044710dd127de78d84fa5
[ "Apache-2.0" ]
3
2021-08-23T08:44:40.000Z
2021-08-24T09:36:11.000Z
pre_commit_hooks/sort_package_xml.py
tier4/pre-commit-hooks-ros
1a8353a2748fcd966b9044710dd127de78d84fa5
[ "Apache-2.0" ]
28
2021-09-27T05:18:21.000Z
2022-03-25T05:06:36.000Z
pre_commit_hooks/sort_package_xml.py
tier4/pre-commit-hooks-ros
1a8353a2748fcd966b9044710dd127de78d84fa5
[ "Apache-2.0" ]
1
2021-08-24T09:00:09.000Z
2021-08-24T09:00:09.000Z
#!/usr/bin/env python # Copyright 2021 Tier IV, Inc. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless requir...
30.863636
79
0.67403
dc6a123abe61c2c719827327a155f20d7e1220eb
2,510
py
Python
erhsh/tools/cli.py
erhsh/erhsh-python
aeb04352948a2e1f8125a2681b80104b5146bff8
[ "Apache-2.0" ]
3
2021-04-20T11:23:58.000Z
2022-01-17T02:57:33.000Z
erhsh/tools/cli.py
erhsh/erhsh-python
aeb04352948a2e1f8125a2681b80104b5146bff8
[ "Apache-2.0" ]
null
null
null
erhsh/tools/cli.py
erhsh/erhsh-python
aeb04352948a2e1f8125a2681b80104b5146bff8
[ "Apache-2.0" ]
null
null
null
import click import erhsh from erhsh.tools.bash_helper import bash_helper from erhsh.tools.git_helper import git_helper from erhsh.tools.jupyter_helper import jupyter_helper from erhsh.tools.vim_helper import vim_helper from erhsh import utils as eut def print_version(ctx, param, value): if not value or ctx.res...
32.179487
89
0.703984
635956f3fd637f87d91dac9199346c0094c8b4c3
82
py
Python
tools/studio/cvra_studio/viewers/__init__.py
romainreignier/robot-software
9cd2ffedb5dec99e913d77b8b58b24d451510632
[ "MIT" ]
null
null
null
tools/studio/cvra_studio/viewers/__init__.py
romainreignier/robot-software
9cd2ffedb5dec99e913d77b8b58b24d451510632
[ "MIT" ]
null
null
null
tools/studio/cvra_studio/viewers/__init__.py
romainreignier/robot-software
9cd2ffedb5dec99e913d77b8b58b24d451510632
[ "MIT" ]
null
null
null
__all__ = [ 'LivePlotter', 'NestedDict', 'Selector', 'helpers', ]
11.714286
18
0.52439
77d064052b4f3f4c3c6d487501c7e1bece11ebf1
6,862
py
Python
InferenceSystem/src/model/fastai_inference.py
aayushmnit/aifororcas-livesystem
f99454f7fc3c98e86ddf4d7ea2ef8ec0877c9c9c
[ "MIT" ]
10
2020-11-23T14:40:18.000Z
2022-02-18T20:05:22.000Z
InferenceSystem/src/model/fastai_inference.py
aayushmnit/aifororcas-livesystem
f99454f7fc3c98e86ddf4d7ea2ef8ec0877c9c9c
[ "MIT" ]
47
2021-01-27T20:01:07.000Z
2022-03-14T06:10:07.000Z
InferenceSystem/src/model/fastai_inference.py
aayushmnit/aifororcas-livesystem
f99454f7fc3c98e86ddf4d7ea2ef8ec0877c9c9c
[ "MIT" ]
5
2020-12-03T14:33:56.000Z
2021-10-12T17:36:48.000Z
from fastai.basic_train import load_learner import pandas as pd from pydub import AudioSegment from librosa import get_duration from pathlib import Path from numpy import floor from audio.data import AudioConfig, SpectrogramConfig, AudioList import os import shutil import tempfile def load_model(mPath, mName="stg2-rn...
38.768362
142
0.609735
520dfd40e5ff5bc2d7f9d253f7cc33dc6322904b
2,626
py
Python
gammapy/makers/tests/test_safe.py
luca-giunti/gammapy
f5873caa3e0ec7175df4647fca83cd44d1ab8fcc
[ "BSD-3-Clause" ]
null
null
null
gammapy/makers/tests/test_safe.py
luca-giunti/gammapy
f5873caa3e0ec7175df4647fca83cd44d1ab8fcc
[ "BSD-3-Clause" ]
null
null
null
gammapy/makers/tests/test_safe.py
luca-giunti/gammapy
f5873caa3e0ec7175df4647fca83cd44d1ab8fcc
[ "BSD-3-Clause" ]
null
null
null
# Licensed under a 3-clause BSD style license - see LICENSE.rst import pytest from numpy.testing import assert_allclose from astropy import units as u from gammapy.data import DataStore from gammapy.datasets import MapDataset from gammapy.makers import MapDatasetMaker, SafeMaskMaker from gammapy.maps import MapAxis, Wc...
39.787879
102
0.739147
f42db0304af62dd68ce868cf09e532a6f4e8b64d
11,227
py
Python
exchangelib/version.py
Ozzyz/exchangelib
287f53b15fa5ff2f9b685b74c54f36828e03bdf5
[ "BSD-2-Clause" ]
null
null
null
exchangelib/version.py
Ozzyz/exchangelib
287f53b15fa5ff2f9b685b74c54f36828e03bdf5
[ "BSD-2-Clause" ]
null
null
null
exchangelib/version.py
Ozzyz/exchangelib
287f53b15fa5ff2f9b685b74c54f36828e03bdf5
[ "BSD-2-Clause" ]
null
null
null
# coding=utf-8 from __future__ import unicode_literals import logging import re from future.utils import python_2_unicode_compatible from six import text_type, string_types from .errors import TransportError, ErrorInvalidSchemaVersionForMailboxVersion, ErrorInvalidServerVersion, \ ErrorIncorrectSchemaVersion, Re...
43.684825
120
0.66732
c5e9d8396b1f1599dba5ade77b0673c8f4e8e40f
2,332
py
Python
tpdatasrc/co8infra/scr/Spell386 - Reduce.py
dolio/TemplePlus
37446bb3d1fcbf460e611a4fcb2caff167e9ac08
[ "MIT" ]
69
2015-05-05T14:09:25.000Z
2022-02-15T06:13:04.000Z
tpdatasrc/co8infra/scr/Spell386 - Reduce.py
anatoliy-savchak/TemplePlus
50922bb14cc2d7dcf8fceeccf45c3b905c1b512f
[ "MIT" ]
457
2015-05-01T22:07:45.000Z
2022-03-31T02:19:10.000Z
tpdatasrc/co8infra/scr/Spell386 - Reduce.py
anatoliy-savchak/TemplePlus
50922bb14cc2d7dcf8fceeccf45c3b905c1b512f
[ "MIT" ]
25
2016-02-04T21:19:53.000Z
2021-11-15T23:14:51.000Z
from toee import * def OnBeginSpellCast( spell ): print "Reduce OnBeginSpellCast" print "spell.target_list=", spell.target_list print "spell.caster=", spell.caster, " caster.level= ", spell.caster_level game.particles( "sp-transmutation-conjure", spell.caster ) def OnSpellEffect( spell ): print "Reduce OnSpellEf...
34.80597
116
0.739708
734b379a462b3874e25599250dde7f8bf1bb4d76
719
py
Python
tests/servers/gedis/test_actors/memory_profiler.py
zaibon/js-ng
8b63c04757d1432ed4aa588500a113610701de14
[ "Apache-2.0" ]
13
2020-09-02T09:05:08.000Z
2022-03-12T02:43:24.000Z
tests/servers/gedis/test_actors/memory_profiler.py
zaibon/js-ng
8b63c04757d1432ed4aa588500a113610701de14
[ "Apache-2.0" ]
1,998
2020-06-15T11:46:10.000Z
2022-03-24T22:12:41.000Z
tests/servers/gedis/test_actors/memory_profiler.py
zaibon/js-ng
8b63c04757d1432ed4aa588500a113610701de14
[ "Apache-2.0" ]
8
2020-09-29T06:50:35.000Z
2021-06-14T03:30:52.000Z
from jumpscale.servers.gedis.baseactor import BaseActor, actor_method from objgraph import count, show_most_common_types class MemoryProfiler(BaseActor): @actor_method def object_count(self, object_type: str) -> int: """Gets number of object with type object_type in memory Arguments: ...
24.793103
69
0.641168
df59ad6e07126a852141edf397a84b6ab720c6d0
99
py
Python
Python/Stepik/Beginner/Exam-loops/stars.py
SergeyOcheretenko/PythonLearning
2f84d730b00931b33188a2a831977f385b063c6c
[ "MIT" ]
null
null
null
Python/Stepik/Beginner/Exam-loops/stars.py
SergeyOcheretenko/PythonLearning
2f84d730b00931b33188a2a831977f385b063c6c
[ "MIT" ]
6
2021-12-27T18:27:57.000Z
2022-03-20T15:11:38.000Z
Python/Stepik/Beginner/Exam-loops/stars.py
SergeyOcheretenko/PythonLearning
2f84d730b00931b33188a2a831977f385b063c6c
[ "MIT" ]
1
2022-02-21T18:20:54.000Z
2022-02-21T18:20:54.000Z
n = int(input()) print('*' * 19) print(('*' + ' ' * 17 + '*\n') * (n - 2), end='') print('*' * 19)
19.8
49
0.363636
817c4dfd7827e4c93abf1977d282af592bd919db
1,013
py
Python
PC/utils/log.py
StanLei52/GEBD
5f7e722e0384f9877c75d116e1db72400d2bc58f
[ "MIT" ]
44
2021-03-24T07:10:57.000Z
2022-03-12T11:49:14.000Z
PC/utils/log.py
StanLei52/GEBD
5f7e722e0384f9877c75d116e1db72400d2bc58f
[ "MIT" ]
2
2021-05-26T09:31:55.000Z
2021-08-11T11:47:38.000Z
PC/utils/log.py
StanLei52/GEBD
5f7e722e0384f9877c75d116e1db72400d2bc58f
[ "MIT" ]
6
2021-04-07T00:51:51.000Z
2022-01-12T01:54:41.000Z
""" Logging helpers Hacked together by / Copyright 2020 Ross Wightman """ import logging import logging.handlers class FormatterNoInfo(logging.Formatter): def __init__(self, fmt='%(levelname)s: %(message)s'): logging.Formatter.__init__(self, fmt) def format(self, record): if record.levelno ==...
37.518519
110
0.716683
c008ac623d83e8b8e3d0e51b0ca7f93672ec41d9
53,666
py
Python
django/template/base.py
tomviner/django
87fed9444033533ad7105c4b1e4ffc5d7854a2c6
[ "BSD-3-Clause" ]
null
null
null
django/template/base.py
tomviner/django
87fed9444033533ad7105c4b1e4ffc5d7854a2c6
[ "BSD-3-Clause" ]
null
null
null
django/template/base.py
tomviner/django
87fed9444033533ad7105c4b1e4ffc5d7854a2c6
[ "BSD-3-Clause" ]
1
2022-03-26T09:05:09.000Z
2022-03-26T09:05:09.000Z
""" This is the Django template system. How it works: The Lexer.tokenize() function converts a template string (i.e., a string containing markup with custom template tags) to tokens, which can be either plain text (TOKEN_TEXT), variables (TOKEN_VAR) or block statements (TOKEN_BLOCK). The Parser() class takes a list ...
37.345859
106
0.583107
b6799faaa51f46ff40c9141ff41724e17528af54
10,049
py
Python
django_evolution/tests/delete_field.py
clones/django-evolution
34b1131873da463d22801d8b845a72f35cb367bd
[ "BSD-3-Clause" ]
1
2016-05-09T04:23:18.000Z
2016-05-09T04:23:18.000Z
django_evolution/tests/delete_field.py
clones/django-evolution
34b1131873da463d22801d8b845a72f35cb367bd
[ "BSD-3-Clause" ]
null
null
null
django_evolution/tests/delete_field.py
clones/django-evolution
34b1131873da463d22801d8b845a72f35cb367bd
[ "BSD-3-Clause" ]
null
null
null
from django_evolution.tests.utils import test_sql_mapping tests = r""" >>> from django.db import models >>> from django_evolution.mutations import DeleteField >>> from django_evolution.tests.utils import test_proj_sig, execute_test_sql, register_models, deregister_models >>> from django_evolution.diff import Diff >>...
37.356877
112
0.712509
f739be22973bf9b06e33d5e55a97e26be3aff193
2,574
py
Python
src/primaires/joueur/commandes/decrire/__init__.py
vlegoff/tsunami
36b3b974f6eefbf15cd5d5f099fc14630e66570b
[ "BSD-3-Clause" ]
14
2015-08-21T19:15:21.000Z
2017-11-26T13:59:17.000Z
src/primaires/joueur/commandes/decrire/__init__.py
vincent-lg/tsunami
36b3b974f6eefbf15cd5d5f099fc14630e66570b
[ "BSD-3-Clause" ]
20
2015-09-29T20:50:45.000Z
2018-06-21T12:58:30.000Z
src/primaires/joueur/commandes/decrire/__init__.py
vlegoff/tsunami
36b3b974f6eefbf15cd5d5f099fc14630e66570b
[ "BSD-3-Clause" ]
3
2015-05-02T19:42:03.000Z
2018-09-06T10:55:00.000Z
# -*-coding:Utf-8 -* # Copyright (c) 2010-2017 CORTIER Benoît # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # * Redistributions of source code must retain the above copyright notice, this # ...
44.37931
79
0.731546
7ff3da875796c1b50c908338cd77a33b7141c1f5
1,239
py
Python
main.py
playtodeath/apple
2bcf617e778b82da00cbce4980519ed4b3d712bf
[ "Apache-2.0" ]
1
2017-03-14T09:50:12.000Z
2017-03-14T09:50:12.000Z
main.py
playtodeath/apple
2bcf617e778b82da00cbce4980519ed4b3d712bf
[ "Apache-2.0" ]
null
null
null
main.py
playtodeath/apple
2bcf617e778b82da00cbce4980519ed4b3d712bf
[ "Apache-2.0" ]
null
null
null
#coding=utf-8 # 功能 # 1. 抓取苹果优惠信息 # 2. 推送 import requests import notify class Apple(object): """docstring for Apple""" specialdeals = \ "http://www.apple.com/cn/"\ "shop/browse/home/specialdeals/" url_mac = specialdeals + "mac" url_ipad = specialdeals + "ipad" def __init__(self, url): self.url = ...
15.683544
61
0.614205
2730c132e9bd67559d6fff2cda2992c806ef7a69
408
py
Python
packages/augur-core/tests/libraries/test_contract_exists.py
jalextowle/augur
821653823438fd9d20eced2221c8f99f21606a02
[ "MIT" ]
885
2015-01-11T20:51:30.000Z
2022-03-25T00:29:59.000Z
packages/augur-core/tests/libraries/test_contract_exists.py
jalextowle/augur
821653823438fd9d20eced2221c8f99f21606a02
[ "MIT" ]
7,347
2015-01-17T01:05:24.000Z
2021-11-02T17:28:19.000Z
packages/augur-core/tests/libraries/test_contract_exists.py
jalextowle/augur
821653823438fd9d20eced2221c8f99f21606a02
[ "MIT" ]
283
2015-01-30T02:16:53.000Z
2022-03-24T19:23:08.000Z
#!/usr/bin/env python from eth_tester.exceptions import TransactionFailed from pytest import fixture from utils import nullAddress def test_contract_exists(fixture): contractExistsHelper = fixture.upload('solidity_test_helpers/ContractExistsHelper.sol') assert contractExistsHelper.doesContractExist(contractE...
34
91
0.845588
7f222d193cd327a612dd2b69a7c9459c61d01ee4
548
py
Python
leetcode/680-valid-palindrome-3.py
ardakkk/Algorithms-and-Data-Structures
c428bb0bd7eeb6c34448630f88f13e1329b54636
[ "MIT" ]
null
null
null
leetcode/680-valid-palindrome-3.py
ardakkk/Algorithms-and-Data-Structures
c428bb0bd7eeb6c34448630f88f13e1329b54636
[ "MIT" ]
null
null
null
leetcode/680-valid-palindrome-3.py
ardakkk/Algorithms-and-Data-Structures
c428bb0bd7eeb6c34448630f88f13e1329b54636
[ "MIT" ]
null
null
null
# Time: 0(n) | Space: O(n) # Input: "aba" # Output: True # Input: "abca" # Output: True # Explanation: You could delete the character 'c'. def isPalindrom(s): i = 0 j = len(s)-1 while i < j and s[i] == s[j]: i+=1 j-=1 return i>=j class Solution: def validPalindrome(self, s: str...
18.896552
65
0.470803
b5d75ede14e6bb8d3ea532f393b0ecb22a0e8315
5,021
py
Python
Series2Visualizer/treemap/draw.py
vdweegen/UvA-Software_Evolution
15a7f4622963e1f154462dbf94e8e2fb75fdd8dd
[ "MIT" ]
null
null
null
Series2Visualizer/treemap/draw.py
vdweegen/UvA-Software_Evolution
15a7f4622963e1f154462dbf94e8e2fb75fdd8dd
[ "MIT" ]
null
null
null
Series2Visualizer/treemap/draw.py
vdweegen/UvA-Software_Evolution
15a7f4622963e1f154462dbf94e8e2fb75fdd8dd
[ "MIT" ]
null
null
null
from tkinter import * from random import randint import squarify import colorsys class TreeMap: canv = None values = None valuedetails = None colors = None def __init__(self, skip_initial=False, color_per_clone=False): self.height = 700 self.width = 700 self.y = 0 s...
31.186335
106
0.482175
9c69b64457f6292b0bf5835545efcb8bbac53a54
5,036
py
Python
pathfider.py
Kvello/BRAIN_Microsoft_Hackathon
f8efa7be2ce4d029e28e075f714d2be1c7d68eb0
[ "MIT" ]
null
null
null
pathfider.py
Kvello/BRAIN_Microsoft_Hackathon
f8efa7be2ce4d029e28e075f714d2be1c7d68eb0
[ "MIT" ]
null
null
null
pathfider.py
Kvello/BRAIN_Microsoft_Hackathon
f8efa7be2ce4d029e28e075f714d2be1c7d68eb0
[ "MIT" ]
null
null
null
from math import sqrt import sys import matplotlib.pyplot as plt # A class to represent a graph object class Graph: # Constructor to construct a graph def __init__(self, edges, nodes): self.nodes = nodes # A list of lists to represent an adjacency list self.adjList = dict() fo...
35.216783
131
0.628872
bcf89085da4d3f79eb7cef82eb630ae8494cd59e
1,504
py
Python
voxelflow/voxelflow_maml_config.py
myungsub/meta-interpolation
f7afee9d1786f67e6f548c2734f91858f803c5dc
[ "MIT" ]
74
2020-04-03T06:26:39.000Z
2022-03-25T16:51:28.000Z
voxelflow/voxelflow_maml_config.py
baiksung/meta-interpolation
72dd3b2e56054bb411ed20301583a0e67d9ea293
[ "MIT" ]
6
2020-07-09T20:09:23.000Z
2021-09-20T11:12:24.000Z
voxelflow/voxelflow_maml_config.py
baiksung/meta-interpolation
72dd3b2e56054bb411ed20301583a0e67d9ea293
[ "MIT" ]
19
2020-04-16T09:18:38.000Z
2021-12-28T08:25:12.000Z
# VoxelFlow model model = dict( name="VoxelFlow", syn_type="inter", bn_param=dict(momentum=0.9997), bn_training=False, bn_parallel=False, mult_conv_w=[1, 1], # lr, decay mult_conv_b=[2, 0], # lr, decay mult_bn=[1, 1], # lr, decay ) device = [0]#[0, 1, 2, 3, 4, 5, 6, 7] resume = 'outp...
24.655738
95
0.601064
fc559eff9625ca964e201eaf77915ee9353677ed
437
py
Python
jobs/migrations/0003_auto_20180408_1148.py
mkimartinez/Lyfey
8a27ef7fea92146f043c68c7ef5ee3672014c3fc
[ "MIT" ]
null
null
null
jobs/migrations/0003_auto_20180408_1148.py
mkimartinez/Lyfey
8a27ef7fea92146f043c68c7ef5ee3672014c3fc
[ "MIT" ]
null
null
null
jobs/migrations/0003_auto_20180408_1148.py
mkimartinez/Lyfey
8a27ef7fea92146f043c68c7ef5ee3672014c3fc
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.11.7 on 2018-04-08 03:48 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('jobs', '0002_auto_20180408_1144'), ] operations = [ migrations.AlterField( ...
20.809524
48
0.606407
a155336604f644ae5ff0cd87c56c45f769eca8ee
4,991
py
Python
src/tests/conftest.py
akhundMurad/fastapi-bigbluebutton
bfe94d87d8cb9768c17cf5513a05d2b46edf5b5c
[ "MIT" ]
1
2021-07-13T16:28:48.000Z
2021-07-13T16:28:48.000Z
src/tests/conftest.py
akhundMurad/fastapi-bigbluebutton
bfe94d87d8cb9768c17cf5513a05d2b46edf5b5c
[ "MIT" ]
1
2022-03-04T19:06:43.000Z
2022-03-05T06:15:47.000Z
src/tests/conftest.py
akhundMurad/fastapi-bigbluebutton
bfe94d87d8cb9768c17cf5513a05d2b46edf5b5c
[ "MIT" ]
null
null
null
import asyncio import datetime import os import random from random import choice from typing import Tuple import faker import pytest import sqlalchemy from fastapi.testclient import TestClient from loguru import logger from core.db import metadata from core.models.bigbluebutton import Meeting from core.models.schedul...
27.882682
73
0.721899
46035149f8829483dab56c85958ad270e360503f
14,083
py
Python
histo/HistokatController/scripts/histokat/backend/functions.py
muxiao1217/DeformableRegistration.jl
e3b2c7a7d5b15b8b34302ee62a4727fe5a63176f
[ "BSD-3-Clause" ]
4
2017-10-11T15:07:22.000Z
2019-11-15T06:26:07.000Z
histo/HistokatController/scripts/histokat/backend/functions.py
muxiao1217/DeformableRegistration.jl
e3b2c7a7d5b15b8b34302ee62a4727fe5a63176f
[ "BSD-3-Clause" ]
6
2017-10-06T20:06:58.000Z
2017-10-06T20:07:00.000Z
histo/HistokatController/scripts/histokat/backend/functions.py
muxiao1217/DeformableRegistration.jl
e3b2c7a7d5b15b8b34302ee62a4727fe5a63176f
[ "BSD-3-Clause" ]
2
2017-10-06T19:54:33.000Z
2019-07-29T07:57:57.000Z
import ctypes import shutil import tempfile import numpy as np from histokat.backend import (_HISTOKAT_LIB, HistokatException, InvalidIdException, NotInitializedException, _cfunc_cancellation_callback, _workspace_dir_generated) ...
37.65508
138
0.71739
a1deb544e74d7b843ee84f4d8485d1d16ad5e804
3,286
py
Python
examples/references/segmentation/pascal_voc2012/code/dataflow/vis.py
sparkingdark/ignite
e81767b594ec0609a2e0899923610c7e61f0327e
[ "BSD-3-Clause" ]
null
null
null
examples/references/segmentation/pascal_voc2012/code/dataflow/vis.py
sparkingdark/ignite
e81767b594ec0609a2e0899923610c7e61f0327e
[ "BSD-3-Clause" ]
null
null
null
examples/references/segmentation/pascal_voc2012/code/dataflow/vis.py
sparkingdark/ignite
e81767b594ec0609a2e0899923610c7e61f0327e
[ "BSD-3-Clause" ]
null
null
null
from typing import Callable, Optional, Union import numpy as np import torch from PIL import Image try: from image_dataset_viz import render_datapoint except ImportError: raise RuntimeError("Install it via pip install --upgrade git+https://github.com/vfdev-5/ImageDatasetViz.git") def _getvocpallete(num_cls)...
31.295238
113
0.568472
c5ad3a0c17207b13f4a2d89f5d78eda35cea422e
21,116
py
Python
tests/test_bip32.py
Rutrus/bip_utils
a8e2b56bd0039cccb21c6adf1ce71122af11ede8
[ "MIT" ]
1
2021-01-20T07:40:56.000Z
2021-01-20T07:40:56.000Z
tests/test_bip32.py
planetarium/bip_utils
7eafdc59aa510d96f9ad9f298d394189fa8b84e6
[ "MIT" ]
null
null
null
tests/test_bip32.py
planetarium/bip_utils
7eafdc59aa510d96f9ad9f298d394189fa8b84e6
[ "MIT" ]
null
null
null
# Copyright (c) 2020 Emanuele Bellocchia # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish,...
46.307018
154
0.577524
76819b6f180baa451240d5fa59fcbe7df3436285
28,610
py
Python
sympy/physics/mechanics/kane.py
utkarshdeorah/sympy
dcdf59bbc6b13ddbc329431adf72fcee294b6389
[ "BSD-3-Clause" ]
1
2022-01-31T16:02:46.000Z
2022-01-31T16:02:46.000Z
sympy/physics/mechanics/kane.py
utkarshdeorah/sympy
dcdf59bbc6b13ddbc329431adf72fcee294b6389
[ "BSD-3-Clause" ]
3
2022-02-04T14:45:16.000Z
2022-02-04T14:45:45.000Z
sympy/physics/mechanics/kane.py
utkarshdeorah/sympy
dcdf59bbc6b13ddbc329431adf72fcee294b6389
[ "BSD-3-Clause" ]
1
2022-02-04T13:50:29.000Z
2022-02-04T13:50:29.000Z
from sympy.core.backend import zeros, Matrix, diff, eye from sympy.core.sorting import default_sort_key from sympy.physics.vector import (ReferenceFrame, dynamicsymbols, partial_velocity) from sympy.physics.mechanics.method import _Methods from sympy.physics.mechanics.particle import P...
40.639205
83
0.58546
956446b49003f07a43f5d73490c0c258c08f6867
1,399
py
Python
apps/user/forms.py
nowindxdw/flask_base
44963513a3945ebf6cd7c4dcd7fbd67d6d8c5641
[ "MIT" ]
null
null
null
apps/user/forms.py
nowindxdw/flask_base
44963513a3945ebf6cd7c4dcd7fbd67d6d8c5641
[ "MIT" ]
2
2020-04-22T11:26:13.000Z
2020-04-22T11:26:20.000Z
apps/user/forms.py
nowindxdw/flask_base
44963513a3945ebf6cd7c4dcd7fbd67d6d8c5641
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- encoding: utf-8 -*- from flask_wtf import FlaskForm from wtforms import StringField, BooleanField, PasswordField, SelectField, SelectMultipleField, TextAreaField,SubmitField from wtforms.validators import DataRequired, Length, Email,ValidationError, DataRequired, Email, EqualTo from apps.u...
38.861111
121
0.7198
5a2433d6970a8f240e7e5bd7dae9d307a4edb823
3,873
py
Python
avalon/settings.py
tshlabs/avalonms
2291f8457ca86f2e963d518abbdce04af02d9054
[ "MIT" ]
1
2015-11-09T05:26:57.000Z
2015-11-09T05:26:57.000Z
avalon/settings.py
tshlabs/avalonms
2291f8457ca86f2e963d518abbdce04af02d9054
[ "MIT" ]
4
2015-02-08T20:14:54.000Z
2015-07-07T23:44:42.000Z
avalon/settings.py
tshlabs/avalonms
2291f8457ca86f2e963d518abbdce04af02d9054
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # # Avalon Music Server # # Copyright 2012-2015 TSH Labs <projects@tshlabs.org> # # Available under the MIT license. See LICENSE for details. # """Default configuration settings for the Avalon Music Server""" from __future__ import absolute_import, unicode_literals import logging from tempfil...
37.240385
81
0.759618
a75b694603324e74bcde4b709f32a340682a00e1
163
py
Python
venv/bin/django-admin.py
Stblacq/Xmailer
37cfd79f4c4b616fd449e78ef5587d1300090063
[ "bzip2-1.0.6" ]
null
null
null
venv/bin/django-admin.py
Stblacq/Xmailer
37cfd79f4c4b616fd449e78ef5587d1300090063
[ "bzip2-1.0.6" ]
null
null
null
venv/bin/django-admin.py
Stblacq/Xmailer
37cfd79f4c4b616fd449e78ef5587d1300090063
[ "bzip2-1.0.6" ]
null
null
null
#!/home/jerome/Documents/Xmailer-master/venv/bin/python3 from django.core import management if __name__ == "__main__": management.execute_from_command_line()
27.166667
56
0.791411
f474322c47c7644bf34dfd2855dc448bf4505612
2,869
py
Python
tests/test_filters.py
HazyResearch/pytorch_radon
bca1626c036e119896acd8c7eef0d08e8541c2c7
[ "MIT" ]
1
2021-03-26T00:16:14.000Z
2021-03-26T00:16:14.000Z
tests/test_filters.py
HazyResearch/pytorch_radon
bca1626c036e119896acd8c7eef0d08e8541c2c7
[ "MIT" ]
null
null
null
tests/test_filters.py
HazyResearch/pytorch_radon
bca1626c036e119896acd8c7eef0d08e8541c2c7
[ "MIT" ]
1
2021-11-15T17:09:03.000Z
2021-11-15T17:09:03.000Z
import unittest from pytorch_radon import Radon, IRadon from pytorch_radon.filters import RampFilter, HannFilter, LearnableFilter from pytorch_radon.filters import RampButterflyFilter, HannButterflyFilter import torch class TestStackgram(unittest.TestCase): def test_ramp_filter(self): img = torch.zeros(1,1...
42.191176
94
0.621819
990cf2a473e7555cf7d8f8f3906d190f46fb1318
472
py
Python
brewery/migrations/0011_timeseriesdatapoint_source.py
willjschmitt/joulia-webserver
712decb749c2d1bda71af49ecab245378bf30078
[ "FTL" ]
null
null
null
brewery/migrations/0011_timeseriesdatapoint_source.py
willjschmitt/joulia-webserver
712decb749c2d1bda71af49ecab245378bf30078
[ "FTL" ]
95
2016-08-04T01:59:37.000Z
2021-06-10T18:41:46.000Z
brewery/migrations/0011_timeseriesdatapoint_source.py
willjschmitt/joulia-webserver
712decb749c2d1bda71af49ecab245378bf30078
[ "FTL" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.10.5 on 2017-06-19 13:32 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('brewery', '0010_auto_20170613_2055'), ] operations = [ migrations.AddField(...
22.47619
60
0.627119
8a4ecac913e69a89e2c0dd94c7fe6a6a0e689ecb
12,440
py
Python
cryton_worker/lib/task.py
slashsec-edu/cryton-worker
fadd46f357df98c8e1807fbd570337e5bf27a7a4
[ "MIT" ]
null
null
null
cryton_worker/lib/task.py
slashsec-edu/cryton-worker
fadd46f357df98c8e1807fbd570337e5bf27a7a4
[ "MIT" ]
null
null
null
cryton_worker/lib/task.py
slashsec-edu/cryton-worker
fadd46f357df98c8e1807fbd570337e5bf27a7a4
[ "MIT" ]
null
null
null
from multiprocessing import Process import amqpstorm import json import traceback from schema import Schema, Or, SchemaError, Optional from utinni import EmpireLoginError import asyncio from cryton_worker.lib import event, empire from cryton_worker.lib.util import util, constants as co, logger class Task: def __...
39.871795
118
0.623151
05b442328f19635a2663c2cc756eea102835eb2b
784
py
Python
cfgs.py
vic9527/ViClassifier
fd6c4730e880f35a9429277a6025219315e067cc
[ "MIT" ]
1
2021-11-03T05:05:34.000Z
2021-11-03T05:05:34.000Z
cfgs.py
vic9527/viclassifier
fd6c4730e880f35a9429277a6025219315e067cc
[ "MIT" ]
null
null
null
cfgs.py
vic9527/viclassifier
fd6c4730e880f35a9429277a6025219315e067cc
[ "MIT" ]
null
null
null
archs = ['alexnet', 'vgg11', 'vgg11_bn', 'vgg13', 'vgg13_bn', 'vgg16', 'vgg16_bn','vgg19', 'vgg19_bn', 'resnet18', 'resnet34', 'resnet50', 'resnet101', 'resnet152', 'resnext50_32x4d', 'resnext101_32x8d', 'wide_resnet50_2', 'wide_resnet101_2', 'densenet121', 'densenet169', 'densenet161', 'dens...
35.636364
148
0.647959
54b908bedb122fe556e24cbec57d34c4538752a2
2,722
py
Python
setup.py
WuXuan374/graph4nlp
e7ad93f590b9399034d3ebfbd857cc5a4de977f0
[ "Apache-2.0" ]
null
null
null
setup.py
WuXuan374/graph4nlp
e7ad93f590b9399034d3ebfbd857cc5a4de977f0
[ "Apache-2.0" ]
null
null
null
setup.py
WuXuan374/graph4nlp
e7ad93f590b9399034d3ebfbd857cc5a4de977f0
[ "Apache-2.0" ]
null
null
null
import platform from setuptools import find_packages, setup from wheel.bdist_wheel import bdist_wheel as _bdist_wheel cuda_versions = {"1": "9.2", "2": "10.1", "3": "10.2", "4": "11.0", "5": "11.1", "6": "cpu"} class MyBdistWheel(_bdist_wheel): def finalize_options(self): _bdist_wheel.finalize_options(se...
33.604938
110
0.592212
1a770f3e1285c57cd74e3de3b2a097593009eec0
360
py
Python
src/FlaskTpp/App/models/model_constant.py
MaiXiaochai/flask
31547477ae17f263888f285a8e4c9d6bd473fdc9
[ "Apache-2.0" ]
null
null
null
src/FlaskTpp/App/models/model_constant.py
MaiXiaochai/flask
31547477ae17f263888f285a8e4c9d6bd473fdc9
[ "Apache-2.0" ]
null
null
null
src/FlaskTpp/App/models/model_constant.py
MaiXiaochai/flask
31547477ae17f263888f285a8e4c9d6bd473fdc9
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- """ -------------------------------------- @File : model_constant.py @Author : maixiaochai @Email : maixiaochai@outlook.com @Created on : 2020/5/10 15:47 -------------------------------------- """ # 权限值 USER_COMMON = 0 USER_BLACK = 1 USER_VIP = 2 ADMIN_NONE = 0 ADMIN_COMMON = 2 ...
17.142857
38
0.5
40915184c90c77dfbe8efffd691c1c86610d4ea1
4,860
py
Python
replacement-clock.py
sreinders/page-replacement
3398555ba064865fb4fe8c9dc028d5bb9bcbc4ab
[ "MIT" ]
null
null
null
replacement-clock.py
sreinders/page-replacement
3398555ba064865fb4fe8c9dc028d5bb9bcbc4ab
[ "MIT" ]
null
null
null
replacement-clock.py
sreinders/page-replacement
3398555ba064865fb4fe8c9dc028d5bb9bcbc4ab
[ "MIT" ]
null
null
null
import sys import pagerefgen def usage(): print(""" replacement-clock.py npages nrefs nframes This program generates a random sequence of page numbers and uses them to simulate the Clock page replacement algorithm. npages = the number of pages in the virtual address space ...
50.625
163
0.609877
f8188e1b7072e41dda8f4911a4a862329f82c4c6
138,887
py
Python
jodconverter-web/src/main/office/program/python-core-2.7.6/lib/lib-tk/turtle.py
huleigithup/filepreview
815fac0e21547301604bb5fd623a91d885cb4437
[ "Apache-2.0" ]
367
2019-02-15T16:08:29.000Z
2022-03-25T06:35:38.000Z
BitmessageKit/Vendor/static-python/Lib/lib-tk/turtle.py
VoluntaryLabs/BitmessageKit
dd634977a629ab4dec184e12bb6324cc01149ba3
[ "MIT" ]
10
2019-02-23T09:03:05.000Z
2021-07-06T12:24:23.000Z
BitmessageKit/Vendor/static-python/Lib/lib-tk/turtle.py
VoluntaryLabs/BitmessageKit
dd634977a629ab4dec184e12bb6324cc01149ba3
[ "MIT" ]
151
2019-03-04T09:49:56.000Z
2022-03-29T13:01:45.000Z
# # turtle.py: a Tkinter based turtle graphics module for Python # Version 1.0.1 - 24. 9. 2009 # # Copyright (C) 2006 - 2010 Gregor Lingl # email: glingl@aon.at # # This software is provided 'as-is', without any express or implied # warranty. In no event will the authors be held liable for any damages # arising from ...
34.412042
97
0.55584
010e812cd29424f4561078c3b89a8f7fbe4f9fba
3,279
py
Python
LotteryResult.py
xuetaolu/bilibili-live-tools
96d762f92480af6485f8fd328070b5ef10fc5625
[ "MIT" ]
null
null
null
LotteryResult.py
xuetaolu/bilibili-live-tools
96d762f92480af6485f8fd328070b5ef10fc5625
[ "MIT" ]
null
null
null
LotteryResult.py
xuetaolu/bilibili-live-tools
96d762f92480af6485f8fd328070b5ef10fc5625
[ "MIT" ]
null
null
null
from bilibili import bilibili import requests import asyncio import time class LotteryResult(): def __init__(self, bilibili): self.bilibili =bilibili async def query(self): while 1: # print(time.strftime('%Y-%m-%d %H:%M:%S', time.localtime(time.time())), "检查抽奖结果") ...
56.534483
191
0.519061
6339d878a803746613a009f752ecf75ebcc01007
4,707
py
Python
ansible/lib/ansible/module_utils/f5.py
kiv-box/kafka
debec1c4bc8c43776070ee447a53b55fef42bd52
[ "Apache-2.0" ]
null
null
null
ansible/lib/ansible/module_utils/f5.py
kiv-box/kafka
debec1c4bc8c43776070ee447a53b55fef42bd52
[ "Apache-2.0" ]
null
null
null
ansible/lib/ansible/module_utils/f5.py
kiv-box/kafka
debec1c4bc8c43776070ee447a53b55fef42bd52
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python # -*- coding: utf-8 -*- # This code is part of Ansible, but is an independent component. # This particular file snippet, and this file snippet only, is BSD licensed. # Modules you write using this snippet, which is embedded dynamically by Ansible # still belong to the author of the module, and may as...
43.990654
195
0.700021
ce84e717171d5fd009d039084ee5e5c356c42dad
6,276
py
Python
bot/cogs/moderating.py
kanelbullebot/kanelbulle
eab8168b6c1d3df31d7d8f28b43014ce970ac9e2
[ "MIT" ]
3
2018-12-18T20:56:38.000Z
2018-12-21T08:45:29.000Z
bot/cogs/moderating.py
trilleplay/old-kanelbulle
eab8168b6c1d3df31d7d8f28b43014ce970ac9e2
[ "MIT" ]
2
2018-12-01T13:59:02.000Z
2018-12-09T12:50:54.000Z
bot/cogs/moderating.py
trilleplay/old-kanelbulle
eab8168b6c1d3df31d7d8f28b43014ce970ac9e2
[ "MIT" ]
4
2018-11-09T14:42:18.000Z
2018-12-09T11:20:37.000Z
import discord from discord.ext import commands from utilities import translate, returncfg from discord.utils import escape_mentions, escape_markdown class ModCog(commands.Cog): """ModCog""" def __init__(self, bot): self.bot = bot @commands.has_permissions(ban_members=True) @commands.bot_has_...
56.540541
227
0.681166
7c5fad705c8bbd43a066d544961f5fa8c4d9e959
5,736
py
Python
packages/python/plotly/plotly/graph_objs/scatter3d/_projection.py
mastermind88/plotly.py
efa70710df1af22958e1be080e105130042f1839
[ "MIT" ]
null
null
null
packages/python/plotly/plotly/graph_objs/scatter3d/_projection.py
mastermind88/plotly.py
efa70710df1af22958e1be080e105130042f1839
[ "MIT" ]
null
null
null
packages/python/plotly/plotly/graph_objs/scatter3d/_projection.py
mastermind88/plotly.py
efa70710df1af22958e1be080e105130042f1839
[ "MIT" ]
null
null
null
from plotly.basedatatypes import BaseTraceHierarchyType as _BaseTraceHierarchyType import copy as _copy class Projection(_BaseTraceHierarchyType): # class properties # -------------------- _parent_path_str = "scatter3d" _path_str = "scatter3d.projection" _valid_props = {"x", "y", "z"} # x ...
28.969697
82
0.521618
dd0ec7b83e482ad02524748b4799f3c1865f5fb6
3,462
py
Python
security/rsa/src/MainWindow.py
Pridexs/dit
9135f09ef6449b48fc204f9540e8a2261ff16af4
[ "MIT" ]
null
null
null
security/rsa/src/MainWindow.py
Pridexs/dit
9135f09ef6449b48fc204f9540e8a2261ff16af4
[ "MIT" ]
null
null
null
security/rsa/src/MainWindow.py
Pridexs/dit
9135f09ef6449b48fc204f9540e8a2261ff16af4
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'MainWindow.ui' # # Created by: PyQt4 UI code generator 4.11.4 # # WARNING! All changes made in this file will be lost! from PyQt4 import QtCore, QtGui try: _fromUtf8 = QtCore.QString.fromUtf8 except AttributeError: def _fromUtf8(s)...
48.083333
97
0.712594
f354f6a80ba2626646a9a76c09efbff3e329a917
44,523
py
Python
bank_statement.py
CHVSAnirudh/Chitra_gupta-the-accounting-software
1c0237b78972c570632cc901a4c0d873725894fb
[ "MIT" ]
2
2021-07-06T05:22:43.000Z
2021-08-08T05:34:11.000Z
bank_statement.py
CHVSAnirudh/Chitra_gupta-the-accounting-software
1c0237b78972c570632cc901a4c0d873725894fb
[ "MIT" ]
null
null
null
bank_statement.py
CHVSAnirudh/Chitra_gupta-the-accounting-software
1c0237b78972c570632cc901a4c0d873725894fb
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'bank_statement.ui' # # Created by: PyQt5 UI code generator 5.15.4 # # WARNING: Any manual changes made to this file will be lost when pyuic5 is # run again. Do not edit this file unless you know what you are doing. from PyQt5 import QtCor...
50.479592
122
0.703322
d4d4f88620f96ea5ac4243e8cabf8f8cccca7d97
698
py
Python
September 2020/03-Multidimensional-Lists/05-Square-with-Maximum-Sum.py
eclipse-ib/Software-University-Professional-Advanced-Module
636385f9e5521840f680644824d725d074b93c9a
[ "MIT" ]
null
null
null
September 2020/03-Multidimensional-Lists/05-Square-with-Maximum-Sum.py
eclipse-ib/Software-University-Professional-Advanced-Module
636385f9e5521840f680644824d725d074b93c9a
[ "MIT" ]
null
null
null
September 2020/03-Multidimensional-Lists/05-Square-with-Maximum-Sum.py
eclipse-ib/Software-University-Professional-Advanced-Module
636385f9e5521840f680644824d725d074b93c9a
[ "MIT" ]
null
null
null
import itertools rows, cols = [int(_) for _ in input().split(", ")] matrix = [[int(_) for _ in input().split(", ")] for i in range(rows)] max_square = [] sum_square = 0 for i in range(len(matrix)-1): row = matrix[i] for j in range(len(row)-1): square = [ [matrix[i][j], matrix[i][j+1]], ...
30.347826
69
0.571633
24699d7f57b73001fff3139469b82f7323f0519f
546
py
Python
backend/home/migrations/0001_load_initial_data.py
crowdbotics-apps/wandering-lake-30246
25485d14c8d5372ff911a0589b2156b507d69e5d
[ "FTL", "AML", "RSA-MD" ]
null
null
null
backend/home/migrations/0001_load_initial_data.py
crowdbotics-apps/wandering-lake-30246
25485d14c8d5372ff911a0589b2156b507d69e5d
[ "FTL", "AML", "RSA-MD" ]
36
2021-09-01T12:37:47.000Z
2022-01-23T17:51:43.000Z
backend/home/migrations/0001_load_initial_data.py
crowdbotics-apps/wandering-lake-30246
25485d14c8d5372ff911a0589b2156b507d69e5d
[ "FTL", "AML", "RSA-MD" ]
null
null
null
from django.db import migrations def create_site(apps, schema_editor): Site = apps.get_model("sites", "Site") custom_domain = "wandering-lake-30246.botics.co" site_params = { "name": "Wandering Lake", } if custom_domain: site_params["domain"] = custom_domain Site.objects.upda...
21
61
0.659341
fc9128736c31b16b9dbad888f5d0f0941e1adf7c
11,925
py
Python
Test/PythonTCs/LTE_4G_IMSIHSSInitDetach.py
clstefi/ignite
042a30527c78dd329560d8ed49ad95eb7029ea4f
[ "Apache-2.0" ]
2
2021-03-03T12:41:31.000Z
2021-03-08T15:27:49.000Z
Test/PythonTCs/LTE_4G_IMSIHSSInitDetach.py
clstefi/ignite
042a30527c78dd329560d8ed49ad95eb7029ea4f
[ "Apache-2.0" ]
8
2020-03-30T04:58:00.000Z
2021-01-18T05:59:06.000Z
Test/PythonTCs/LTE_4G_IMSIHSSInitDetach.py
clstefi/ignite
042a30527c78dd329560d8ed49ad95eb7029ea4f
[ "Apache-2.0" ]
11
2020-03-27T06:52:37.000Z
2021-08-17T15:53:11.000Z
# # Copyright (c) 2019, Infosys Ltd. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in ...
60.532995
165
0.592956
30fe7e10551b02ecc8b37a996bf339dff0b73c9d
2,292
py
Python
snap-python/wikinet.py
kevinychen/snap2
c2c96bf07599bb947d832b968f118bbc6e46a0b9
[ "MIT" ]
13
2019-01-03T21:55:24.000Z
2022-01-16T06:22:28.000Z
snap-python/wikinet.py
kevinychen/snap2
c2c96bf07599bb947d832b968f118bbc6e46a0b9
[ "MIT" ]
12
2019-01-23T12:03:42.000Z
2022-02-27T19:31:42.000Z
snap-python/wikinet.py
kevinychen/snap2
c2c96bf07599bb947d832b968f118bbc6e46a0b9
[ "MIT" ]
2
2022-01-05T23:19:00.000Z
2022-01-17T04:53:01.000Z
""" Python convenience script with the same implementations of "find" and "directFind" in Wikinet.java. """ import collections import util NUM_PARTITIONS = 65536 Article = collections.namedtuple('Article', 'title redirect summary') def strip_from(s, mark): index = s.find(mark) if index != -1: s = s[...
32.742857
122
0.637435
441e060ef4900d81191b97fcde7ae79811d35922
546
py
Python
setup.py
RangelReale/pgtest
63112b7c39a6f92971ea5c398c85694afd4cc3b9
[ "MIT" ]
4
2016-10-05T05:52:56.000Z
2021-12-22T18:18:22.000Z
setup.py
RangelReale/pgtest
63112b7c39a6f92971ea5c398c85694afd4cc3b9
[ "MIT" ]
16
2015-08-14T13:25:08.000Z
2020-04-22T10:36:03.000Z
setup.py
jamesnunn/pgtest
417f0d89e66a9395db694a96122e0d5ac0097d59
[ "MIT" ]
3
2017-07-04T08:06:33.000Z
2020-02-19T16:41:14.000Z
# encoding: utf-8 from setuptools import setup setup( name='pgtest', version='1.3.2', description=('Creates a temporary, local PostgreSQL database cluster and ' 'server for unittesting, and cleans up after itself'), long_description=open('README.md').read(), long_description_conten...
32.117647
78
0.67033
6dc00ac5851f5c696d5c7a36b6e1433a343db69d
1,071
py
Python
mysite/jxl/forms.py
alex-gagnon/jxl_django
2060a686551f1ed22b96b3ae72572999557bf812
[ "MIT" ]
null
null
null
mysite/jxl/forms.py
alex-gagnon/jxl_django
2060a686551f1ed22b96b3ae72572999557bf812
[ "MIT" ]
5
2021-04-08T19:42:19.000Z
2022-02-10T12:10:02.000Z
mysite/jxl/forms.py
alex-gagnon/jxl_django
2060a686551f1ed22b96b3ae72572999557bf812
[ "MIT" ]
null
null
null
from django import forms from django.forms import ModelForm from .models import Filter, Project class JXLForm(ModelForm): title = 'Home' project_text = forms.ModelChoiceField(label='Project:', queryset=Project.objects.only('project_text'), ...
39.666667
93
0.521008
ecee75fb8685f24165fbb7ce0f2938d7afe00dd4
5,743
py
Python
tests/test_ext_inheritance_diagram.py
thomascherickal/sphinx
353c3e9fd6f35fb129dac61798ff1b09c14f6d85
[ "BSD-2-Clause" ]
1
2019-09-02T00:37:29.000Z
2019-09-02T00:37:29.000Z
tests/test_ext_inheritance_diagram.py
thomascherickal/sphinx
353c3e9fd6f35fb129dac61798ff1b09c14f6d85
[ "BSD-2-Clause" ]
null
null
null
tests/test_ext_inheritance_diagram.py
thomascherickal/sphinx
353c3e9fd6f35fb129dac61798ff1b09c14f6d85
[ "BSD-2-Clause" ]
1
2019-09-02T00:41:05.000Z
2019-09-02T00:41:05.000Z
""" test_ext_inheritance_diagram ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Test sphinx.ext.inheritance_diagram extension. :copyright: Copyright 2007-2019 by the Sphinx team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re import sys import pytest from sphinx.ext.inheritance_diagram import...
39.068027
95
0.634337
317cdc205637e984cea504ea2b94c2916b1db688
2,377
py
Python
fn_portal/filters/FN127_filters.py
AdamCottrill/FishNetPortal
4e58e05f52346ac1ab46698a03d4229c74828406
[ "MIT" ]
null
null
null
fn_portal/filters/FN127_filters.py
AdamCottrill/FishNetPortal
4e58e05f52346ac1ab46698a03d4229c74828406
[ "MIT" ]
null
null
null
fn_portal/filters/FN127_filters.py
AdamCottrill/FishNetPortal
4e58e05f52346ac1ab46698a03d4229c74828406
[ "MIT" ]
null
null
null
import django_filters from .common_filters import ValueInFilter, NumberInFilter from ..models import FN127 from .FishAttr_filters import FishAttrFilters class FN127Filter(FishAttrFilters): """A fitlerset that allows us to select subsets of FN127 table (age estimates/interpretations) by by attributes of the...
40.288136
101
0.726125
f932d1eab9ce7a3ce5ba4ef0111367531aaa37f9
3,180
py
Python
forum/tests/test_comments.py
pv8/vanhack-forum
c7ebf054f7ce8cf778e5e60948bfe04702d81ce6
[ "MIT" ]
1
2022-03-17T15:54:04.000Z
2022-03-17T15:54:04.000Z
forum/tests/test_comments.py
pv8/vanhack-forum
c7ebf054f7ce8cf778e5e60948bfe04702d81ce6
[ "MIT" ]
147
2019-02-11T17:00:56.000Z
2021-07-19T08:14:54.000Z
forum/tests/test_comments.py
pv8/vanhack-forum
c7ebf054f7ce8cf778e5e60948bfe04702d81ce6
[ "MIT" ]
null
null
null
from django.contrib.auth.models import User from django.test import TestCase from django.urls import reverse from forum.models import Comment, Post def create_comment(client, post): url = reverse('comment_create', kwargs={'post_pk': post.pk}) data = { 'message': 'The red one will take you to the real...
35.333333
88
0.620755
be47457d777bcf5d1b41b4bc1fcd17a72845c507
3,424
py
Python
msda/plot_clustermap.py
smkartik/msda
764fb632b90c820bc3235e4ad7a2e8c88c62e886
[ "MIT" ]
null
null
null
msda/plot_clustermap.py
smkartik/msda
764fb632b90c820bc3235e4ad7a2e8c88c62e886
[ "MIT" ]
null
null
null
msda/plot_clustermap.py
smkartik/msda
764fb632b90c820bc3235e4ad7a2e8c88c62e886
[ "MIT" ]
1
2019-11-18T23:09:19.000Z
2019-11-18T23:09:19.000Z
from matplotlib.colors import ListedColormap import seaborn as sns import pandas as pd from itertools import chain import os import numpy as np from msda import enrichr_api as ai import matplotlib.pyplot as plt def construct_color_dict(labels, scheme="husl"): colrs = sns.color_palette(scheme, len(labels)).as_hex(...
33.242718
71
0.625292
bad1bcd4124aa8a88400d750748866a5c30df823
8,273
py
Python
src/dataset.py
Wsine/deeppatch
a25037d39dcc7ef2c85e92224c938fd7ec210878
[ "MIT" ]
null
null
null
src/dataset.py
Wsine/deeppatch
a25037d39dcc7ef2c85e92224c938fd7ec210878
[ "MIT" ]
1
2021-09-09T05:03:16.000Z
2021-09-09T05:03:16.000Z
src/dataset.py
Wsine/deeppatch
a25037d39dcc7ef2c85e92224c938fd7ec210878
[ "MIT" ]
null
null
null
import math import random import torch import torch.utils.data import torchvision import torchvision.transforms as T from tqdm import tqdm from sklearn.model_selection import train_test_split from augmentor import GeneticAugmentor, NeighborAugmentor, RandomAugmentor from utils import cache_object class RandomApply(...
36.126638
98
0.623474