hexsha
string
size
int64
ext
string
lang
string
max_stars_repo_path
string
max_stars_repo_name
string
max_stars_repo_head_hexsha
string
max_stars_repo_licenses
list
max_stars_count
int64
max_stars_repo_stars_event_min_datetime
string
max_stars_repo_stars_event_max_datetime
string
max_issues_repo_path
string
max_issues_repo_name
string
max_issues_repo_head_hexsha
string
max_issues_repo_licenses
list
max_issues_count
int64
max_issues_repo_issues_event_min_datetime
string
max_issues_repo_issues_event_max_datetime
string
max_forks_repo_path
string
max_forks_repo_name
string
max_forks_repo_head_hexsha
string
max_forks_repo_licenses
list
max_forks_count
int64
max_forks_repo_forks_event_min_datetime
string
max_forks_repo_forks_event_max_datetime
string
content
string
avg_line_length
float64
max_line_length
int64
alphanum_fraction
float64
qsc_code_num_words_quality_signal
int64
qsc_code_num_chars_quality_signal
float64
qsc_code_mean_word_length_quality_signal
float64
qsc_code_frac_words_unique_quality_signal
float64
qsc_code_frac_chars_top_2grams_quality_signal
float64
qsc_code_frac_chars_top_3grams_quality_signal
float64
qsc_code_frac_chars_top_4grams_quality_signal
float64
qsc_code_frac_chars_dupe_5grams_quality_signal
float64
qsc_code_frac_chars_dupe_6grams_quality_signal
float64
qsc_code_frac_chars_dupe_7grams_quality_signal
float64
qsc_code_frac_chars_dupe_8grams_quality_signal
float64
qsc_code_frac_chars_dupe_9grams_quality_signal
float64
qsc_code_frac_chars_dupe_10grams_quality_signal
float64
qsc_code_frac_chars_replacement_symbols_quality_signal
float64
qsc_code_frac_chars_digital_quality_signal
float64
qsc_code_frac_chars_whitespace_quality_signal
float64
qsc_code_size_file_byte_quality_signal
float64
qsc_code_num_lines_quality_signal
float64
qsc_code_num_chars_line_max_quality_signal
float64
qsc_code_num_chars_line_mean_quality_signal
float64
qsc_code_frac_chars_alphabet_quality_signal
float64
qsc_code_frac_chars_comments_quality_signal
float64
qsc_code_cate_xml_start_quality_signal
float64
qsc_code_frac_lines_dupe_lines_quality_signal
float64
qsc_code_cate_autogen_quality_signal
float64
qsc_code_frac_lines_long_string_quality_signal
float64
qsc_code_frac_chars_string_length_quality_signal
float64
qsc_code_frac_chars_long_word_length_quality_signal
float64
qsc_code_frac_lines_string_concat_quality_signal
float64
qsc_code_cate_encoded_data_quality_signal
float64
qsc_code_frac_chars_hex_words_quality_signal
float64
qsc_code_frac_lines_prompt_comments_quality_signal
float64
qsc_code_frac_lines_assert_quality_signal
float64
qsc_codepython_cate_ast_quality_signal
float64
qsc_codepython_frac_lines_func_ratio_quality_signal
float64
qsc_codepython_cate_var_zero_quality_signal
bool
qsc_codepython_frac_lines_pass_quality_signal
float64
qsc_codepython_frac_lines_import_quality_signal
float64
qsc_codepython_frac_lines_simplefunc_quality_signal
float64
qsc_codepython_score_lines_no_logic_quality_signal
float64
qsc_codepython_frac_lines_print_quality_signal
float64
qsc_code_num_words
int64
qsc_code_num_chars
int64
qsc_code_mean_word_length
int64
qsc_code_frac_words_unique
null
qsc_code_frac_chars_top_2grams
int64
qsc_code_frac_chars_top_3grams
int64
qsc_code_frac_chars_top_4grams
int64
qsc_code_frac_chars_dupe_5grams
int64
qsc_code_frac_chars_dupe_6grams
int64
qsc_code_frac_chars_dupe_7grams
int64
qsc_code_frac_chars_dupe_8grams
int64
qsc_code_frac_chars_dupe_9grams
int64
qsc_code_frac_chars_dupe_10grams
int64
qsc_code_frac_chars_replacement_symbols
int64
qsc_code_frac_chars_digital
int64
qsc_code_frac_chars_whitespace
int64
qsc_code_size_file_byte
int64
qsc_code_num_lines
int64
qsc_code_num_chars_line_max
int64
qsc_code_num_chars_line_mean
int64
qsc_code_frac_chars_alphabet
int64
qsc_code_frac_chars_comments
int64
qsc_code_cate_xml_start
int64
qsc_code_frac_lines_dupe_lines
int64
qsc_code_cate_autogen
int64
qsc_code_frac_lines_long_string
int64
qsc_code_frac_chars_string_length
int64
qsc_code_frac_chars_long_word_length
int64
qsc_code_frac_lines_string_concat
null
qsc_code_cate_encoded_data
int64
qsc_code_frac_chars_hex_words
int64
qsc_code_frac_lines_prompt_comments
int64
qsc_code_frac_lines_assert
int64
qsc_codepython_cate_ast
int64
qsc_codepython_frac_lines_func_ratio
int64
qsc_codepython_cate_var_zero
int64
qsc_codepython_frac_lines_pass
int64
qsc_codepython_frac_lines_import
int64
qsc_codepython_frac_lines_simplefunc
int64
qsc_codepython_score_lines_no_logic
int64
qsc_codepython_frac_lines_print
int64
effective
string
hits
int64
db061ebed7905602f35d78915cc113c60793a2a1
50
py
Python
article/views/__init__.py
vyahello/newspaper-parser
ad986dfc43e089f376ffe96251cf6481df133329
[ "MIT" ]
null
null
null
article/views/__init__.py
vyahello/newspaper-parser
ad986dfc43e089f376ffe96251cf6481df133329
[ "MIT" ]
3
2020-08-20T10:19:16.000Z
2022-01-28T10:38:22.000Z
article/views/__init__.py
vyahello/newspaper-parser
ad986dfc43e089f376ffe96251cf6481df133329
[ "MIT" ]
null
null
null
"""Package contains API for application views."""
25
49
0.74
6
50
6.166667
1
0
0
0
0
0
0
0
0
0
0
0
0.12
50
1
50
50
0.840909
0.86
0
null
0
null
0
0
null
0
0
0
null
1
null
true
0
0
null
null
null
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
1
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
4
db0a14ef554bf2f0afd28a5dbf946d1d78e5a8d8
1,868
py
Python
statsmodels/tsa/tests/results/make_arma.py
jbrockmendel/statsmodels
61155fff1883ffb49d252ae22b2638f73b24ab21
[ "BSD-3-Clause" ]
null
null
null
statsmodels/tsa/tests/results/make_arma.py
jbrockmendel/statsmodels
61155fff1883ffb49d252ae22b2638f73b24ab21
[ "BSD-3-Clause" ]
null
null
null
statsmodels/tsa/tests/results/make_arma.py
jbrockmendel/statsmodels
61155fff1883ffb49d252ae22b2638f73b24ab21
[ "BSD-3-Clause" ]
null
null
null
import numpy as np from statsmodels.tsa.arima_process import arma_generate_sample from statsmodels.iolib import savetxt np.random.seed(12345) # no constant y_arma11 = arma_generate_sample([1., -.75],[1., .35], nsample=250) y_arma14 = arma_generate_sample([1., -.75],[1., .35, -.75, .1, .35], nsample=250) y_arma41 = arma_generate_sample([1., -.75, .25, .25, -.75], [1., .35], nsample=250) y_arma22 = arma_generate_sample([1., -.75, .45],[1., .35, -.9], nsample=250) y_arma50 = arma_generate_sample([1., -.75, .35, -.3, -.2, .1], [1.], nsample=250) y_arma02 = arma_generate_sample([1.], [1., .35, -.75], nsample=250) # constant constant = 4.5 y_arma11c = arma_generate_sample([1., -.75],[1., .35], nsample=250) + constant y_arma14c = arma_generate_sample([1., -.75],[1., .35, -.75, .1, .35], nsample=250) + constant y_arma41c = arma_generate_sample([1., -.75, .25, .25, -.75], [1., .35], nsample=250) + constant y_arma22c = arma_generate_sample([1., -.75, .45],[1., .35, -.9], nsample=250) + constant y_arma50c = arma_generate_sample([1., -.75, .35, -.3, -.2, .1], [1.], nsample=250) + constant y_arma02c = arma_generate_sample([1.], [1., .35, -.75], nsample=250) + constant savetxt( 'y_arma_data.csv', np.column_stack((y_arma11, y_arma14, y_arma41, y_arma22, y_arma50, y_arma02, y_arma11c,y_arma14c, y_arma41c, y_arma22c, y_arma50c, y_arma02c)), names=['y_arma11', 'y_arma14', 'y_arma41', 'y_arma22', 'y_arma50', 'y_arma02', 'y_arma11c', 'y_arma14c', 'y_arma41c', 'y_arma22c', 'y_arma50c', 'y_arma02c'], delimiter=",")
39.744681
79
0.545503
246
1,868
3.873984
0.203252
0.163694
0.24554
0.239244
0.700944
0.700944
0.697796
0.669465
0.669465
0.598111
0
0.1625
0.271949
1,868
46
80
40.608696
0.538235
0.010707
0
0.2
1
0
0.063957
0
0
0
0
0
0
1
0
false
0
0.085714
0
0.085714
0
0
0
0
null
0
1
1
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
db2c3be14d1cbff9d7b7f334e9777c4f0af1c6a2
211
py
Python
deid/experiment/random.py
KavishBhatia/deid-training-data
9d586cd7f52d929b2571028365587d3f96e44caa
[ "MIT" ]
15
2018-10-28T13:57:55.000Z
2022-01-03T07:25:04.000Z
deid/experiment/random.py
KavishBhatia/deid-training-data
9d586cd7f52d929b2571028365587d3f96e44caa
[ "MIT" ]
7
2019-04-29T13:55:52.000Z
2021-12-13T19:51:30.000Z
deid/experiment/random.py
KavishBhatia/deid-training-data
9d586cd7f52d929b2571028365587d3f96e44caa
[ "MIT" ]
3
2019-08-01T19:02:37.000Z
2021-01-08T09:12:25.000Z
def setup_random(): import os import random import numpy as np import tensorflow as tf os.environ['PYTHONHASHSEED'] = '0' np.random.seed(1) random.seed(2) tf.set_random_seed(3)
17.583333
38
0.64455
31
211
4.290323
0.580645
0.225564
0
0
0
0
0
0
0
0
0
0.025478
0.255924
211
11
39
19.181818
0.821656
0
0
0
0
0
0.07109
0
0
0
0
0
0
1
0.111111
true
0
0.444444
0
0.555556
0
0
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
4
db32196684e47f23caa853922a2532e33f93c3e8
205
py
Python
tests/app/views/test_errors.py
qateam123/eq
704757952323647d659c49a71975c56406ff4047
[ "MIT" ]
null
null
null
tests/app/views/test_errors.py
qateam123/eq
704757952323647d659c49a71975c56406ff4047
[ "MIT" ]
8
2020-03-24T15:24:18.000Z
2022-03-02T04:32:56.000Z
tests/app/views/test_errors.py
qateam123/eq
704757952323647d659c49a71975c56406ff4047
[ "MIT" ]
null
null
null
def test_errors_404(survey_runner): response = survey_runner.test_client().get('/hfjdskahfjdkashfsa') assert response.status_code == 404 assert '<title>Error</title' in response.get_data(True)
41
69
0.756098
27
205
5.481481
0.666667
0.162162
0
0
0
0
0
0
0
0
0
0.033333
0.121951
205
4
70
51.25
0.788889
0
0
0
0
0
0.185366
0
0
0
0
0
0.5
1
0.25
false
0
0
0
0.25
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
1
0
1
0
0
0
0
0
0
0
4
e1dbad727d86ad07d3aa90bf5313dbbbb9e267d7
174
py
Python
Bbox_3d/models/losses/__init__.py
Twizwei/maskrcnn_detector
095584f813acb40c937672ff5b63603d40095a2a
[ "MIT" ]
1
2020-11-17T08:34:08.000Z
2020-11-17T08:34:08.000Z
Bbox_3d/models/losses/__init__.py
Twizwei/maskrcnn_detector
095584f813acb40c937672ff5b63603d40095a2a
[ "MIT" ]
null
null
null
Bbox_3d/models/losses/__init__.py
Twizwei/maskrcnn_detector
095584f813acb40c937672ff5b63603d40095a2a
[ "MIT" ]
null
null
null
from .base_losses import * from .task_losses import * __all__ = [ 'BaseLoss', 'MSE', 'Smooth_L1', 'CrossEntropy', 'Cosine_Expansion', 'Dimension_Loss', 'Pose_Loss' ]
24.857143
71
0.689655
20
174
5.5
0.8
0.218182
0
0
0
0
0
0
0
0
0
0.006803
0.155172
174
7
72
24.857143
0.741497
0
0
0
0
0
0.405714
0
0
0
0
0
0
1
0
false
0
0.333333
0
0.333333
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
0
0
0
4
e1f61c359d1d511d99a9f36c0ade08e167c4de94
63
py
Python
singleton/simplelogger/__init__.py
cnsapril/python-design-pattern-tutorial
2a71ac5e47d7dc8fd319b6493ac063cbea6bae0f
[ "MIT" ]
null
null
null
singleton/simplelogger/__init__.py
cnsapril/python-design-pattern-tutorial
2a71ac5e47d7dc8fd319b6493ac063cbea6bae0f
[ "MIT" ]
null
null
null
singleton/simplelogger/__init__.py
cnsapril/python-design-pattern-tutorial
2a71ac5e47d7dc8fd319b6493ac063cbea6bae0f
[ "MIT" ]
null
null
null
from singleton.simplelogger.simple_logger import SimpleLogger
21
61
0.888889
7
63
7.857143
0.857143
0
0
0
0
0
0
0
0
0
0
0
0.079365
63
2
62
31.5
0.948276
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
4
c0053d5ebb3d512dcfe20ae5c65d7d8918522771
368
py
Python
Webhook/views.py
donorgrid/donorgrid
4139df3ceaf767b9696aa4208e3721472f03592a
[ "MIT" ]
8
2021-09-01T03:38:45.000Z
2021-12-23T20:00:37.000Z
Webhook/views.py
donorgrid/donorgrid
4139df3ceaf767b9696aa4208e3721472f03592a
[ "MIT" ]
41
2021-10-22T03:16:50.000Z
2022-03-28T03:13:24.000Z
Webhook/views.py
raunakhajela/DonorGrid
5218951d395bae9fd722835634a1998a6015d756
[ "MIT" ]
4
2021-08-13T15:05:41.000Z
2022-01-03T09:40:19.000Z
from django.http import HttpRequest, HttpResponse from django.views.decorators.csrf import csrf_exempt # Create your views here. @csrf_exempt def paypal(request: HttpRequest): return HttpResponse("OK") @csrf_exempt def stripe(request: HttpRequest): return HttpResponse("OK") @csrf_exempt def razorpay(request: HttpRequest): return HttpResponse("OK")
19.368421
52
0.771739
45
368
6.222222
0.444444
0.142857
0.139286
0.385714
0.5
0.364286
0.364286
0.364286
0
0
0
0
0.13587
368
18
53
20.444444
0.880503
0.0625
0
0.545455
0
0
0.017493
0
0
0
0
0
0
1
0.272727
false
0
0.181818
0.272727
0.727273
0
0
0
0
null
0
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
1
1
0
0
4
c02ed49b58ab260b665ca60d9b606c1862d5f70e
145
py
Python
tabu_search_pdptw.py
yuan-xin-9997/PDPTW_Code_PyCharm_Project_Github
639b2a5bf54a4ba7be8d16ab70ff36bdecfd492e
[ "Apache-2.0" ]
6
2020-11-29T05:47:48.000Z
2022-02-24T11:43:41.000Z
tabu_search_pdptw.py
yuan-xin-9997/PDPTW_Code_PyCharm_Project_Github
639b2a5bf54a4ba7be8d16ab70ff36bdecfd492e
[ "Apache-2.0" ]
3
2021-05-27T02:39:30.000Z
2021-07-07T06:32:07.000Z
tabu_search_pdptw.py
yuan-xin-9997/PDPTW_Code_PyCharm_Project_Github
639b2a5bf54a4ba7be8d16ab70ff36bdecfd492e
[ "Apache-2.0" ]
2
2022-02-24T11:43:44.000Z
2022-03-04T02:38:09.000Z
# -*- coding: utf-8 -*- """ @author: yuan_xin @contact: yuanxin9997@qq.com @file: tabu_search_pdptw.py @time: 2020/10/19 16:57 @description: """
16.111111
28
0.668966
22
145
4.272727
1
0
0
0
0
0
0
0
0
0
0
0.132813
0.117241
145
8
29
18.125
0.601563
0.931034
0
null
0
null
0
0
null
0
0
0
null
1
null
true
0
0
null
null
null
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
1
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
4
c04676ec53d1b99fa76d74b4a7a64e6cce03f1df
98
py
Python
steewi/products/apps.py
HardBite/steewi
b79d527843964ba3b8f56f554d56c4383db71640
[ "BSD-3-Clause" ]
null
null
null
steewi/products/apps.py
HardBite/steewi
b79d527843964ba3b8f56f554d56c4383db71640
[ "BSD-3-Clause" ]
null
null
null
steewi/products/apps.py
HardBite/steewi
b79d527843964ba3b8f56f554d56c4383db71640
[ "BSD-3-Clause" ]
null
null
null
from django.apps import AppConfig class ProductsConfig(AppConfig): name = 'steewi.products'
16.333333
33
0.765306
11
98
6.818182
0.909091
0
0
0
0
0
0
0
0
0
0
0
0.153061
98
5
34
19.6
0.903614
0
0
0
0
0
0.153061
0
0
0
0
0
0
1
0
false
0
0.333333
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
4
c054cfdd58231d6cd26e5ebf73b467fd45ebed74
436
py
Python
enchanter/tasks/__init__.py
khirotaka/enchanter
71faa51f998da5c8d9185a979a4f5849c9b5f9e6
[ "Apache-2.0" ]
8
2020-04-18T03:09:19.000Z
2021-05-05T17:57:27.000Z
enchanter/tasks/__init__.py
khirotaka/enchanter
71faa51f998da5c8d9185a979a4f5849c9b5f9e6
[ "Apache-2.0" ]
107
2020-02-12T11:35:06.000Z
2022-03-24T20:49:43.000Z
enchanter/tasks/__init__.py
khirotaka/enchanter
71faa51f998da5c8d9185a979a4f5849c9b5f9e6
[ "Apache-2.0" ]
2
2020-02-12T12:23:51.000Z
2021-07-19T11:41:04.000Z
from .classification import ClassificationRunner from .regression import RegressionRunner, AutoEncoderRunner from .ensemble import HardEnsemble, SoftEnsemble, BaseEnsembleEstimator from .ts_unsupervised import TimeSeriesUnsupervisedRunner __all__ = [ "ClassificationRunner", "RegressionRunner", "HardEnsemble", "SoftEnsemble", "BaseEnsembleEstimator", "TimeSeriesUnsupervisedRunner", "AutoEncoderRunner", ]
29.066667
71
0.793578
28
436
12.178571
0.535714
0.140762
0.26393
0
0
0
0
0
0
0
0
0
0.135321
436
14
72
31.142857
0.904509
0
0
0
0
0
0.288991
0.112385
0
0
0
0
0
1
0
false
0
0.307692
0
0.307692
0
1
0
1
null
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
0
0
0
4
2207a35205bdba84f040a1032e0ddeb9042e168e
65
py
Python
jobs/d0001.py
zingson/hddpy
2ed511dabe9eb63fd6798123475f8113ecf0ceb3
[ "Apache-2.0" ]
null
null
null
jobs/d0001.py
zingson/hddpy
2ed511dabe9eb63fd6798123475f8113ecf0ceb3
[ "Apache-2.0" ]
null
null
null
jobs/d0001.py
zingson/hddpy
2ed511dabe9eb63fd6798123475f8113ecf0ceb3
[ "Apache-2.0" ]
null
null
null
""" 1. 查询报表数据 2. 生成Excel文件 3. 打包为zip文件并加密 4. 邮件发送文件 5. 邮件发送密码 """
9.285714
14
0.661538
10
65
4.3
1
0
0
0
0
0
0
0
0
0
0
0.092593
0.169231
65
7
15
9.285714
0.703704
0.876923
0
null
0
null
0
0
null
0
0
0
null
1
null
true
0
0
null
null
null
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
1
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
4
22080dee9b3381a3288419c327e676908a944054
1,794
py
Python
quspin/operators/__init__.py
marcotav/QuSpin
ba3dbb9c8b4440ad7deba6412444489d45cb7349
[ "BSD-3-Clause" ]
1
2020-05-10T08:32:34.000Z
2020-05-10T08:32:34.000Z
quspin/operators/__init__.py
marcotav/QuSpin
ba3dbb9c8b4440ad7deba6412444489d45cb7349
[ "BSD-3-Clause" ]
null
null
null
quspin/operators/__init__.py
marcotav/QuSpin
ba3dbb9c8b4440ad7deba6412444489d45cb7349
[ "BSD-3-Clause" ]
null
null
null
""" ========================================== Operators module (:mod:`quspin.operators`) ========================================== Classes and functions for constructing and manipulating quantum operators, and implementing Schroedinger time evolution. Many-body operators in QuSpin are defined by a string of letters representing the operator types, together with a list which holds the indices for the sites that each operator acts at on, in the lattice. For example, in a spin-1/2 system we can represent any multi-spin operator as: .. math:: \\begin{array}{cccc} \\text{operator string} & \\text{site-coupling list} & & \\text{spin operator} \\newline \\mu_1,\\dots,\\mu_n & [J,i_1,\dots,i_n] & \\Leftrightarrow & J\\sigma_{i_1}^{\\mu_1}\\cdots\\sigma_{i_n}^{\\mu_n} \\newline \\end{array} where :math:`\\mu_i` can be "I", z", "+", "-", "x" or "y". Here, :math:`\\sigma_{i_n}^{\\mu_n}` is the Pauli spin operator acting on lattice site :math:`i_n`. This representation provides a way to conveniently define any multi-body spin-1/2 operator, and generalises to bosons and fermions in a natural way. To construct operators for different particle spieces, check out the `basis` constructor classes for the supported operator strings. classes -------- .. currentmodule:: quspin.operators .. autosummary:: :toctree: generated/ hamiltonian quantum_operator exp_op quantum_LinearOperator functions ---------- .. autosummary:: :toctree: generated/ commutator anti_commutator ishamiltonian isquantum_operator isexp_op isquantum_LinearOperator """ from .hamiltonian_core import * from .quantum_operator_core import * from .exp_op_core import * from .quantum_LinearOperator_core import *
32.035714
152
0.673913
233
1,794
5.064378
0.502146
0.00678
0.035593
0.015254
0.016949
0
0
0
0
0
0
0.00538
0.171126
1,794
55
153
32.618182
0.788164
0.906355
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
4
222648839400fcf0d645a3f19a2bc9242611a013
27
py
Python
requirements.py
Mathieu-Lala/Cute_Solar_System_-3
0bfe496991344709481995af348da2be37a19cac
[ "MIT" ]
4
2021-06-03T11:20:09.000Z
2022-02-11T06:52:54.000Z
requirements.py
Mathieu-Lala/Cute_Solar_System_-3
0bfe496991344709481995af348da2be37a19cac
[ "MIT" ]
35
2021-05-29T09:25:57.000Z
2021-06-28T04:49:22.000Z
requirements.py
Mathieu-Lala/Kawaii_Engine
0bfe496991344709481995af348da2be37a19cac
[ "MIT" ]
null
null
null
conan>=1.37 cmakelang>=0.6
9
14
0.703704
6
27
3.166667
1
0
0
0
0
0
0
0
0
0
0
0.2
0.074074
27
2
15
13.5
0.56
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0
0
0
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
4
223eb18b1652fa90cf58761da5a6667faba9b848
18
py
Python
aws_xray_sdk/version.py
jay-johnson/aws-xray-sdk-python
8d093b44521b6e6e0a6fd2ab6807c2dbcf4176b8
[ "Apache-2.0" ]
294
2017-10-10T19:01:04.000Z
2022-03-18T15:52:19.000Z
aws_xray_sdk/version.py
jay-johnson/aws-xray-sdk-python
8d093b44521b6e6e0a6fd2ab6807c2dbcf4176b8
[ "Apache-2.0" ]
285
2017-10-20T09:27:21.000Z
2022-03-29T15:33:45.000Z
aws_xray_sdk/version.py
jay-johnson/aws-xray-sdk-python
8d093b44521b6e6e0a6fd2ab6807c2dbcf4176b8
[ "Apache-2.0" ]
134
2017-10-11T13:55:17.000Z
2022-03-23T07:21:17.000Z
VERSION = '2.8.0'
9
17
0.555556
4
18
2.5
1
0
0
0
0
0
0
0
0
0
0
0.2
0.166667
18
1
18
18
0.466667
0
0
0
0
0
0.277778
0
0
0
0
0
0
1
0
false
0
0
0
0
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
1
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
2273c23f0a1beda525463ef4daa64e753e90d446
55
py
Python
remediation-functions/kinesis/__init__.py
Cloudneeti/aws-auto-remediation
d9dc91f1cacfdbc209b624bde9ca783cfadc4509
[ "MIT" ]
8
2019-09-26T12:53:01.000Z
2021-05-14T17:39:21.000Z
remediation-functions/kinesis/__init__.py
Cloudneeti/aws-auto-remediation
d9dc91f1cacfdbc209b624bde9ca783cfadc4509
[ "MIT" ]
1
2020-02-18T06:22:25.000Z
2020-02-18T06:22:25.000Z
remediation-functions/kinesis/__init__.py
Cloudneeti/aws-auto-remediation
d9dc91f1cacfdbc209b624bde9ca783cfadc4509
[ "MIT" ]
8
2020-01-08T13:16:26.000Z
2021-07-25T08:03:27.000Z
__all__ = ["kinesis_enhancedmonitoring", "kinesis_sse"]
55
55
0.8
5
55
7.6
0.8
0
0
0
0
0
0
0
0
0
0
0
0.054545
55
1
55
55
0.730769
0
0
0
0
0
0.660714
0.464286
0
0
0
0
0
1
0
false
0
0
0
0
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
1
1
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
2278353860378335ef2492d04779b4044f8979e2
61
py
Python
pyleaves/leavesdb/tf_utils/__init__.py
JacobARose/pyleaves
27b4016c850148981f3d021028c9272f18df121d
[ "MIT" ]
3
2019-11-25T14:50:54.000Z
2020-05-27T06:54:46.000Z
pyleaves/leavesdb/tf_utils/__init__.py
JacobARose/pyleaves
27b4016c850148981f3d021028c9272f18df121d
[ "MIT" ]
6
2019-11-21T06:24:37.000Z
2019-12-19T14:49:14.000Z
pyleaves/leavesdb/tf_utils/__init__.py
JacobARose/pyleaves
27b4016c850148981f3d021028c9272f18df121d
[ "MIT" ]
null
null
null
# from . import (create_tfrecords, # tf_utils)
30.5
34
0.557377
6
61
5.333333
1
0
0
0
0
0
0
0
0
0
0
0
0.344262
61
2
35
30.5
0.8
0.934426
0
null
0
null
0
0
null
0
0
0
null
1
null
true
0
0
null
null
null
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
1
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
4
97e797e2ded96485d103a0e7e49448e4268423f2
116
py
Python
SETUP/setup.py
1-1-1-1-1-1-1-1/LocalKey
46116eba765f16c85409006f1ab0182fc45658db
[ "Unlicense" ]
1
2020-07-18T12:45:57.000Z
2020-07-18T12:45:57.000Z
SETUP/setup.py
1-1-1-1-1-1-1-1/LocalKey
46116eba765f16c85409006f1ab0182fc45658db
[ "Unlicense" ]
null
null
null
SETUP/setup.py
1-1-1-1-1-1-1-1/LocalKey
46116eba765f16c85409006f1ab0182fc45658db
[ "Unlicense" ]
null
null
null
import os import sys os.system("pip install -r requirements.txt") sys.exit(input("\nDone. Exiting: press Enter"))
16.571429
47
0.732759
18
116
4.722222
0.833333
0
0
0
0
0
0
0
0
0
0
0
0.12069
116
6
48
19.333333
0.833333
0
0
0
0
0
0.508621
0
0
0
0
0
0
1
0
true
0
0.5
0
0.5
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
4
97ee74cffd34e19b86cdb9344f3923bb2065c11b
684
py
Python
oscar/lib/python2.7/site-packages/phonenumbers/shortdata/region_BO.py
AMuratTuran/mkn
557086426773ced10d82c969304bd349414a601e
[ "BSD-3-Clause" ]
4
2018-10-19T04:36:20.000Z
2020-02-13T16:14:09.000Z
oscar/lib/python2.7/site-packages/phonenumbers/shortdata/region_BO.py
AMuratTuran/mkn
557086426773ced10d82c969304bd349414a601e
[ "BSD-3-Clause" ]
5
2020-03-24T16:37:25.000Z
2021-06-10T21:24:54.000Z
upibo-venv/Lib/site-packages/phonenumbers/shortdata/region_BO.py
smbpgroup/upibo
625dcda9f9692c62aeb9fe8f7123a5d407c610ae
[ "BSD-3-Clause" ]
null
null
null
"""Auto-generated file, do not edit by hand. BO metadata""" from ..phonemetadata import NumberFormat, PhoneNumberDesc, PhoneMetadata PHONE_METADATA_BO = PhoneMetadata(id='BO', country_code=None, international_prefix=None, general_desc=PhoneNumberDesc(national_number_pattern='[14]\\d{2,4}', possible_length=(3, 5)), emergency=PhoneNumberDesc(national_number_pattern='11[089]', example_number='110', possible_length=(3,)), short_code=PhoneNumberDesc(national_number_pattern='11[089]|40404', example_number='110', possible_length=(3, 5)), sms_services=PhoneNumberDesc(national_number_pattern='40404', example_number='40404', possible_length=(5,)), short_data=True)
68.4
118
0.777778
87
684
5.850575
0.528736
0.180747
0.227898
0.282908
0.282908
0.282908
0
0
0
0
0
0.065183
0.080409
684
9
119
76
0.744038
0.077485
0
0
1
0
0.08
0
0
0
0
0
0
1
0
false
0
0.142857
0
0.142857
0
0
0
0
null
0
1
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
1
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
97ff377f2daab70ed1ecdf9837ce3a39af53400e
237
py
Python
pyobs/exceptions.py
Adirio/obs-websocket-py
56fd49e5aefaf3f7a560a9d8f286e0fb480f4a99
[ "MIT" ]
null
null
null
pyobs/exceptions.py
Adirio/obs-websocket-py
56fd49e5aefaf3f7a560a9d8f286e0fb480f4a99
[ "MIT" ]
10
2019-09-11T07:59:42.000Z
2019-09-12T06:30:43.000Z
pyobs/exceptions.py
Adirio/obs-websocket-py
56fd49e5aefaf3f7a560a9d8f286e0fb480f4a99
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- class PyobsException(Exception): pass class ConnectionFailure(PyobsException): pass class MessageTimeout(PyobsException): pass class ObjectError(PyobsException): pass
12.473684
40
0.708861
23
237
7.304348
0.608696
0.160714
0.27381
0
0
0
0
0
0
0
0
0.005155
0.181435
237
18
41
13.166667
0.860825
0.177215
0
0.5
0
0
0
0
0
0
0
0
0
1
0
true
0.5
0
0
0.5
0
1
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
1
0
0
0
0
0
4
3f01a246a2859efdc63581aff49c50b70c9539a0
272
py
Python
access/data/w3act_export_scripts/download_w3act_dump.py
ldbiz/ukwa-services
afa30cf631a3464e53f41244b989e32984c40294
[ "Apache-2.0" ]
2
2020-05-12T18:01:21.000Z
2021-05-18T21:47:32.000Z
access/data/w3act_export_scripts/download_w3act_dump.py
ldbiz/ukwa-services
afa30cf631a3464e53f41244b989e32984c40294
[ "Apache-2.0" ]
53
2020-01-23T16:10:53.000Z
2022-03-30T16:59:17.000Z
access/data/w3act_export_scripts/download_w3act_dump.py
ldbiz/ukwa-services
afa30cf631a3464e53f41244b989e32984c40294
[ "Apache-2.0" ]
5
2020-01-20T17:28:27.000Z
2022-02-08T21:30:12.000Z
import urllib.request import zipfile urllib.request.urlretrieve("http://hdfs.api.wa.bl.uk/webhdfs/v1/9_processing/w3act/w3act-db-csv.zip?user.name=access&op=OPEN", "w3act-db-csv.zip") with zipfile.ZipFile("w3act-db-csv.zip", 'r') as zip_ref: zip_ref.extractall(".")
34
146
0.746324
46
272
4.347826
0.630435
0.105
0.15
0.195
0
0
0
0
0
0
0
0.023622
0.066176
272
7
147
38.857143
0.76378
0
0
0
0
0.2
0.477941
0
0
0
0
0
0
1
0
true
0
0.4
0
0.4
0
0
0
0
null
0
0
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
4
3f426fc66926f81d47431092e2abf7fc38c9e35f
1,007
py
Python
demos/main_queues.py
taskcontrols/py-taskcontrols
0f3f8d64cafc77dfbf23e70b0c86a91fea858ce4
[ "MIT" ]
1
2020-04-17T07:15:14.000Z
2020-04-17T07:15:14.000Z
demos/main_queues.py
taskcontrols/py-taskcontrols
0f3f8d64cafc77dfbf23e70b0c86a91fea858ce4
[ "MIT" ]
14
2021-11-26T15:18:05.000Z
2021-12-12T03:05:31.000Z
demos/main_queues.py
taskcontrols/py-taskcontrols
0f3f8d64cafc77dfbf23e70b0c86a91fea858ce4
[ "MIT" ]
1
2021-11-26T15:05:52.000Z
2021-11-26T15:05:52.000Z
from taskcontrol.lib import QueuesBase config = {"name": "test", "maxsize": 10, "queue_type": "queue", "queue": None} queue = QueuesBase() q = queue.new(config) config["queue"] = q # print(config) c = queue.create(config) print(c, queue.validate_add) print(queue.add("test", "test1")) print(queue.add("test", "test2")) print(queue.add("test", "test3")) print(queue.add("test", "test4")) print(queue.add("test", "test5")) print(queue.add("test", "test6")) print(queue.add("test", "test7")) print(queue.add("test", "test8")) print(queue.add("test", "test9")) print(queue.add("test", "test10")) print(queue.add("test", "test11")) print(queue.add("test", "test10")) print(queue.get("test")) print(queue.get("test")) print(queue.get("test")) print(queue.get("test")) print(queue.get("test")) print(queue.get("test")) print(queue.get("test")) print(queue.get("test")) print(queue.get("test")) print(queue.get("test")) print(queue.get("test")) print(queue.get("test"))
28.771429
48
0.641509
143
1,007
4.503497
0.223776
0.372671
0.242236
0.31677
0.403727
0.403727
0.403727
0.31677
0.31677
0.31677
0
0.018973
0.110228
1,007
34
49
29.617647
0.699777
0.01291
0
0.4375
0
0
0.207724
0
0
0
0
0
0
1
0
false
0
0.03125
0
0.03125
0.78125
0
0
0
null
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
1
0
4
3f5abf537747f99017204aea4aa9f33ee5034649
6,618
py
Python
tests/test_photomeson_model_classes.py
afedynitch/AstroPhoMes
4ae35b51a083a7567b772feffd3b1555631b33ea
[ "CC-BY-4.0" ]
null
null
null
tests/test_photomeson_model_classes.py
afedynitch/AstroPhoMes
4ae35b51a083a7567b772feffd3b1555631b33ea
[ "CC-BY-4.0" ]
null
null
null
tests/test_photomeson_model_classes.py
afedynitch/AstroPhoMes
4ae35b51a083a7567b772feffd3b1555631b33ea
[ "CC-BY-4.0" ]
null
null
null
"""Automated tests for the photmeson model classes """ import numpy as np import sys import unittest sys.path.append('../') from config import * from photomeson_lib.photomeson_models import * class Test_SingleParticleModel(unittest.TestCase): def __init__(self, *args, **kwargs): super(Test_SingleParticleModel, self).__init__(*args, **kwargs) # creating class instance for testing self.pm = SingleParticleModel() def test_nonel_nucleons(self): """ Test that nonel works """ cs_proton = self.pm.cs_proton_grid cs_neutron = self.pm.cs_neutron_grid e, cs = self.pm.cs_nonel(101) self.assertTrue(np.all(cs == cs_proton)) e, cs = self.pm.cs_nonel(100) self.assertTrue(np.all(cs == cs_neutron)) def test_nonel_nuclei(self): """ Test that nonel works """ cs_proton = self.pm.cs_proton_grid cs_neutron = self.pm.cs_neutron_grid e, cs = self.pm.cs_nonel(1406) cs_mix = 6 * cs_proton + 8 * cs_neutron self.assertTrue(np.all(cs == cs_mix)) def test_incl_nucleons(self): """ Test that nonel works """ from scipy.integrate import trapz cs_proton = self.pm.cs_proton_grid cs_neutron = self.pm.cs_neutron_grid redist_p = self.pm.redist_proton redist_n = self.pm.redist_neutron for spec, cs_tot, redist in zip([100, 101], [cs_neutron, cs_proton], [redist_n, redist_p]): for prod in [2, 3, 4, 100, 101]: e, cs = self.pm.cs_incl(spec, prod) cs_val_diff = redist[prod].T * cs_tot cs_val = trapz(cs_val_diff, x=self.pm.xcenters, dx=bin_widths(self.pm.xbins), axis=0) if not np.all(cs == cs_val): print spec, prod self.assertTrue(np.all(cs == cs_val)) def test_incl_nuclei(self): """ Test that nonel works """ cs_proton = self.pm.cs_proton_grid cs_neutron = self.pm.cs_neutron_grid e, cs = self.pm.cs_incl(502, 402) cs_val = 3./5*(3 * cs_neutron + 2 * cs_proton) self.assertTrue(np.all(cs == cs_val)) e, cs = self.pm.cs_incl(704, 603) cs_val = 4./7*(3 * cs_neutron + 4 * cs_proton) self.assertTrue(np.all(cs == cs_val)) e, cs = self.pm.cs_incl(1407, 402) cs_val = np.zeros_like(cs) self.assertTrue(np.all(cs == cs_val)) def test_incl_diff_nucleons(self): """ Test that nonel works """ cs_proton = self.pm.cs_proton_grid cs_neutron = self.pm.cs_neutron_grid redist_p = self.pm.redist_proton redist_n = self.pm.redist_neutron for spec, cs_tot, redist in zip([100, 101], [cs_neutron, cs_proton], [redist_n, redist_p]): for prod in [2, 3, 4, 100, 101]: e, cs = self.pm.cs_incl_diff(spec, prod) cs_val = cs_tot * redist[prod].T self.assertTrue(np.all(cs == cs_val)) def test_incl_diff_nuclei(self) : """ Test that nonel works """ cs_proton = self.pm.cs_proton_grid cs_neutron = self.pm.cs_neutron_grid e, cs = self.pm.cs_incl_diff(1407, 100) cs_val = 7 * cs_neutron * self.pm.redist_neutron[100].T + \ 7 * cs_proton * self.pm.redist_proton[100].T self.assertTrue(np.all(cs == cs_val)) e, cs = self.pm.cs_incl(4018, 100) cs_val = np.zeros_like(self.pm.cs_proton_grid) self.assertTrue(np.all(cs.shape == cs_val.shape)) e, cs = self.pm.cs_incl_diff(1407, 402) cs_val = np.zeros_like(self.pm.redist_proton[2].T) self.assertTrue(np.all(cs == cs_val)) class Test_EmpiricalModel(Test_SingleParticleModel): def __init__(self, *args, **kwargs): super(Test_EmpiricalModel, self).__init__(*args, **kwargs) # creating class instance for testing self.pm = EmpiricalModel() def test_nonel_nuclei(self): """ Test that nonel works """ cs_proton = self.pm.cs_proton_grid cs_neutron = self.pm.cs_neutron_grid e, cs = self.pm.cs_nonel(1406) # cs_mix = 6 * cs_proton + 8 * cs_neutron egrid = self.pm.egrid cs_mix = 1e30 * self.pm.univ_spl(egrid) # universal function cs_mix *= 14.**self.pm.alpha(self.pm.egrid) # mass scaling idcs = np.argwhere((egrid > .3) * (egrid < 1.2)) # universal function range self.assertTrue(np.all(abs(cs[idcs] - cs_mix[idcs]) < 1e-10)) def test_incl_nuclei(self): cs_proton = self.pm.cs_proton_grid cs_neutron = self.pm.cs_neutron_grid e, cs = self.pm.cs_incl(502, 402) cs_val = 3 * cs_neutron self.assertTrue(np.all(cs != cs_val)) def test_incl_diff_nuclei(self) : """ Test that inclusive differential cross section work """ cs_proton = self.pm.cs_proton_grid cs_neutron = self.pm.cs_neutron_grid e, cs = self.pm.cs_incl_diff(1407, 3) cs_val = 7 * cs_neutron * self.pm.redist_neutron[3].T + \ 7 * cs_proton * self.pm.redist_proton[3].T self.assertTrue(np.any(cs != cs_val)) self.assertTrue(np.any(cs[-50:] == cs_val[-50:])) self.assertTrue(np.any(cs[:-50] != cs_val[-50])) e, cs = self.pm.cs_incl_diff(1407, 100) cs_val = 7 * cs_neutron * self.pm.redist_neutron[100].T + \ 7 * cs_proton * self.pm.redist_proton[100].T self.assertTrue(np.any(cs != cs_val)) e, cs = self.pm.cs_incl(4018, 101) cs_val = np.zeros_like(self.pm.cs_proton_grid) self.assertTrue(np.all(cs.shape == cs_val.shape)) e, cs = self.pm.cs_incl_diff(1407, 402) cs_val = np.zeros_like(self.pm.redist_proton[2].T) self.assertTrue(np.all(cs == cs_val)) class Test_ResidualDecayModel(Test_SingleParticleModel): def __init__(self, *args, **kwargs): super(Test_ResidualDecayModel, self).__init__(*args, **kwargs) # creating class instance for testing self.pm = ResidualDecayModel() def test_nonel_nuclei(self): pass def test_incl_nuclei(self): pass def test_incl_diff_nuclei(self): pass if __name__ == '__main__': unittest.main()
31.971014
84
0.579178
926
6,618
3.87797
0.13067
0.096909
0.082428
0.042607
0.76636
0.753829
0.710387
0.694514
0.669173
0.613478
0
0.037093
0.303415
6,618
207
85
31.971014
0.741866
0.030825
0
0.574803
0
0
0.001855
0
0
0
0
0
0.149606
0
null
null
0.023622
0.047244
null
null
0.007874
0
0
0
null
0
0
0
0
1
1
0
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
1
0
0
0
0
0
0
0
0
4
3f5e713ce92b47fc2b7a17350eed228626cafd2e
218
py
Python
data_as_code/__init__.py
Mikuana/data_as_code
339f0c6bcd4e318ad925ceb4ccd6149f980d4032
[ "MIT" ]
2
2021-05-18T22:04:22.000Z
2021-07-24T19:52:49.000Z
data_as_code/__init__.py
Mikuana/data_as_code
339f0c6bcd4e318ad925ceb4ccd6149f980d4032
[ "MIT" ]
1
2021-03-12T22:56:45.000Z
2021-03-12T22:56:45.000Z
data_as_code/__init__.py
Mikuana/data_as_code
339f0c6bcd4e318ad925ceb4ccd6149f980d4032
[ "MIT" ]
null
null
null
from data_as_code import premade from data_as_code._recipe import Recipe, Role from data_as_code._step import Step, ingredient, result __all__ = [ 'Recipe', 'Step', 'ingredient', 'result' ] __version__ = '0.0.0'
21.8
55
0.743119
32
218
4.5625
0.4375
0.164384
0.205479
0.287671
0
0
0
0
0
0
0
0.016129
0.146789
218
9
56
24.222222
0.768817
0
0
0
0
0
0.142202
0
0
0
0
0
0
1
0
false
0
0.428571
0
0.428571
0
0
0
0
null
0
1
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
0
0
0
4
58ceb4f326934388faf1c649bcd36d1eeae9485f
1,270
py
Python
invenio_rdm_records/resources/__init__.py
kprzerwa/invenio-rdm-records
d5919b5f1b5f453074fcb2b63929a60bfcb240ed
[ "MIT" ]
null
null
null
invenio_rdm_records/resources/__init__.py
kprzerwa/invenio-rdm-records
d5919b5f1b5f453074fcb2b63929a60bfcb240ed
[ "MIT" ]
null
null
null
invenio_rdm_records/resources/__init__.py
kprzerwa/invenio-rdm-records
d5919b5f1b5f453074fcb2b63929a60bfcb240ed
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # # Copyright (C) 2020 CERN. # # Invenio-RDM-Records is free software; you can redistribute it and/or modify # it under the terms of the MIT License; see LICENSE file for more details. """Invenio RDM module to create REST APIs.""" from .resources import BibliographicDraftActionResource, \ BibliographicDraftActionResourceConfig, BibliographicDraftResource, \ BibliographicDraftResourceConfig, BibliographicRecordFilesActionResource, \ BibliographicRecordFilesActionResourceConfig, \ BibliographicRecordFilesResource, BibliographicRecordFilesResourceConfig, \ BibliographicRecordResource, BibliographicRecordResourceConfig, \ BibliographicUserRecordsResource, BibliographicUserRecordsResourceConfig __all__ = ( "BibliographicDraftActionResource", "BibliographicDraftActionResourceConfig", "BibliographicDraftResource", "BibliographicDraftResourceConfig", "BibliographicRecordFilesResource", "BibliographicRecordFilesResourceConfig", "BibliographicRecordFilesActionResource", "BibliographicRecordFilesActionResourceConfig", "BibliographicRecordResource", "BibliographicRecordResourceConfig", "BibliographicUserRecordsResource", "BibliographicUserRecordsResourceConfig", )
39.6875
79
0.807874
69
1,270
14.811594
0.753623
0.019569
0.187867
0.250489
0
0
0
0
0
0
0
0.004492
0.123622
1,270
31
80
40.967742
0.913747
0.186614
0
0
0
0
0.401174
0.401174
0
0
0
0
0
1
0
false
0
0.047619
0
0.047619
0
0
0
1
null
0
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
58faa111efdaa92218477bbf8132ce6ccd7d7f53
1,291
py
Python
intents/language/entity_language_test.py
dario-chiappetta/dialogflow_agents
ecb03bdce491a3c9d6769816507f3027fd5a60d1
[ "Apache-2.0" ]
6
2021-06-24T12:22:21.000Z
2021-07-21T21:06:19.000Z
intents/language/entity_language_test.py
dario-chiappetta/dialogflow_agents
ecb03bdce491a3c9d6769816507f3027fd5a60d1
[ "Apache-2.0" ]
27
2021-06-05T10:41:08.000Z
2021-11-01T17:29:38.000Z
intents/language/entity_language_test.py
dariowho/intents
ecb03bdce491a3c9d6769816507f3027fd5a60d1
[ "Apache-2.0" ]
null
null
null
from intents.language.entity_language import make_language_data, EntityEntry def test_make_entity_language_string_entries(): entries = ["red", "green", "blue"] result = make_language_data(entries) expected = [ EntityEntry(value="red", synonyms=[]), EntityEntry(value="green", synonyms=[]), EntityEntry(value="blue", synonyms=[]) ] assert result == expected def test_make_entity_language_list_entries(): entries = [ ["red", "crimson", "scarlett"], ["green", "emerald"], ["blue", "cyan", "azure"] ] result = make_language_data(entries) expected = [ EntityEntry(value="red", synonyms=["crimson", "scarlett"]), EntityEntry(value="green", synonyms=["emerald"]), EntityEntry(value="blue", synonyms=["cyan", "azure"]) ] assert result == expected def test_make_entity_language_mixed_entries(): entries = [ ["red", "crimson", "scarlett"], "green", ["blue", "cyan", "azure"] ] result = make_language_data(entries) expected = [ EntityEntry(value="red", synonyms=["crimson", "scarlett"]), EntityEntry(value="green", synonyms=[]), EntityEntry(value="blue", synonyms=["cyan", "azure"]) ] assert result == expected
32.275
76
0.612703
124
1,291
6.185484
0.217742
0.187744
0.083442
0.066493
0.842243
0.809648
0.713168
0.713168
0.547588
0.398957
0
0
0.220759
1,291
39
77
33.102564
0.762425
0
0
0.583333
0
0
0.140976
0
0
0
0
0
0.083333
1
0.083333
false
0
0.027778
0
0.111111
0
0
0
0
null
0
0
0
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
451f5d4836d5dea13ffa423dc6f8630a2942d076
35
py
Python
modules/2.79/bpy/types/FreestyleSettings.py
cmbasnett/fake-bpy-module
acb8b0f102751a9563e5b5e5c7cd69a4e8aa2a55
[ "MIT" ]
null
null
null
modules/2.79/bpy/types/FreestyleSettings.py
cmbasnett/fake-bpy-module
acb8b0f102751a9563e5b5e5c7cd69a4e8aa2a55
[ "MIT" ]
null
null
null
modules/2.79/bpy/types/FreestyleSettings.py
cmbasnett/fake-bpy-module
acb8b0f102751a9563e5b5e5c7cd69a4e8aa2a55
[ "MIT" ]
null
null
null
FreestyleSettings.modules = None
8.75
32
0.8
3
35
9.333333
1
0
0
0
0
0
0
0
0
0
0
0
0.142857
35
3
33
11.666667
0.933333
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0
0
0
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
4
452dde35176dae2223bfe0fcd234933828362a1d
13,578
py
Python
fun.py
dantefurrybot/dantev4
7282e9466209e794b1e91234a0eb7aa83fd6e413
[ "CC-BY-4.0" ]
1
2020-08-17T15:59:40.000Z
2020-08-17T15:59:40.000Z
fun.py
dantefurrybot/dantev4
7282e9466209e794b1e91234a0eb7aa83fd6e413
[ "CC-BY-4.0" ]
null
null
null
fun.py
dantefurrybot/dantev4
7282e9466209e794b1e91234a0eb7aa83fd6e413
[ "CC-BY-4.0" ]
2
2020-08-08T19:02:27.000Z
2020-08-11T00:40:35.000Z
import discord async def msg(message, x, p, self): msg = x #Check if the message was sent by ourselves: if msg.author == self.user: print('Not a user message.') return #If not, we can execute commands, such as this simple ping! if message == p + "ping": ping = self.latency * 1000 embed = discord.Embed(title = "Pong!", description = '___Took {0}'.format(round(ping, 1)) + "ms___" , color=0x00ff00) await msg.channel.send(embed = embed) if message == "f": await msg.channel.send("<@" + str(msg.author.id) + "> has paid respects") if message == "x": await msg.channel.send("<@" + str(msg.author.id) + "> very much has doubts about this") if message == "make me a sandwich": await msg.channel.send("<@" + str(msg.author.id) + "> I can't... I have no condiments") if message == "what is the meaning of life?": await msg.channel.send("<@" + str(msg.author.id) + "> 42") if message == "kill yourself dante": await msg.channel.send("<@" + str(msg.author.id) + "> no u") cmd = message.split() validcommands = ["!kiss","!hug", "!hugs", "!glomp", "!lick", "!slap", "!nuzzle", "!rubs", "!boop", "!pat", "!throwdict", "!bite", "!bap", "!howl", "!growl", "!cuddle", "!snuggle", "!flop", "!nap", "!blep", "!rawr"] if not cmd[0].lower() in validcommands: return if message.startswith(p + "kiss"): for member in x.mentions: print(member) embed = discord.Embed(title = "Kiss!", description = "<@" + str(msg.author.id) + "> has given <@" + str(member.id) + "> a kiss on the cheek!" , color=0x00ff00) if member.id == msg.author.id: return embed.set_thumbnail(url = "https://external-preview.redd.it/Au9jfafmj8FSCgkzvu1odMbw7tLRaye5hWXv5z-Ezus.png?auto=webp&s=bdd727bc7ae09d71521e6d8cec18ef1f69d0a207") await msg.channel.send(embed = embed) if message.startswith(p + "hug"): for member in x.mentions: print(member) embed = discord.Embed(title = "Hug!", description = "<@" + str(msg.author.id) + "> has given <@" + str(member.id) + "> a hug!" , color=0x00ff00) if member.id == msg.author.id: embed.description = "<@" + str(msg.author.id) + "> has hugged themselves! \n\nWhat a loner.." embed.set_thumbnail(url = "https://pm1.narvii.com/6362/398e5e2edeed52fc23d9e85cbbbbe6e5b3951635_hq.jpg") await msg.channel.send(embed = embed) if message.startswith(p + "flop"): if not x.mentions: embed = discord.Embed(title = "Floppp!", description = "<@" + str(msg.author.id) + "> has flopped on the ground!", color=0x00ff00) embed.set_thumbnail(url = "https://i.redd.it/snul7u43bsm11.jpg") await msg.channel.send(embed = embed) for member in x.mentions: print(member) embed = discord.Embed(title = "Floppp!", description = "<@" + str(msg.author.id) + "> has flopped on <@" + str(member.id) + ">!" , color=0x00ff00) if member.id == msg.author.id: embed.description = "<@" + str(msg.author.id) + "> has flopped on the ground!" embed.set_thumbnail(url = "https://i.redd.it/snul7u43bsm11.jpg") await msg.channel.send(embed = embed) if message.startswith(p + "nap"): if not x.mentions: embed = discord.Embed(title = "Zzz!", description = "<@" + str(msg.author.id) + "> has took a nap!", color=0x00ff00) embed.set_thumbnail(url = "https://i.imgur.com/mZo6DnU.png") await msg.channel.send(embed = embed) for member in x.mentions: print(member) embed = discord.Embed(title = "Zzz!", description = "<@" + str(msg.author.id) + "> has decided to fall asleep on <@" + str(member.id) + ">!" , color=0x00ff00) if member.id == msg.author.id: return embed.set_thumbnail(url = "https://i.imgur.com/mZo6DnU.png") await msg.channel.send(embed = embed) if message.startswith(p + "cuddle"): for member in x.mentions: print(member) embed = discord.Embed(title = "Hug!", description = "<@" + str(msg.author.id) + "> has given <@" + str(member.id) + "> a hug!" , color=0x00ff00) if member.id == msg.author.id: embed.description = "<@" + str(msg.author.id) + "> has hugged themselves! \n\nWhat a loner.." embed.set_thumbnail(url = "https://pm1.narvii.com/6362/398e5e2edeed52fc23d9e85cbbbbe6e5b3951635_hq.jpg") await msg.channel.send(embed = embed) if message.startswith(p + "snuggle"): for member in x.mentions: print(member) embed = discord.Embed(title = "Snuggle!", description = "<@" + str(msg.author.id) + "> has snuggled <@" + str(member.id) + "> tightly!" , color=0x00ff00) if member.id == msg.author.id: embed.description = "<@" + str(msg.author.id) + "> has snuggled themselves! \n\nWhat a loner.." embed.set_thumbnail(url = "https://66.media.tumblr.com/e7cc512f3e136d610c0c0780e045dbe3/tumblr_p25tmi3fJg1wchqdto1_400.png") await msg.channel.send(embed = embed) if message.startswith(p + "slap"): for member in x.mentions: print(member) embed = discord.Embed(title = "Trout Slap!", description = "<@" + str(msg.author.id) + "> slaps <@" + str(member.id) + "> around a bit with a wet trout!" , color=0x00ff00) if member.id == msg.author.id: embed.description = "<@" + str(msg.author.id) + "> has slapped themselves with a wet trout! \n\nWut?" embed.set_thumbnail(url = "https://i.pinimg.com/600x315/c7/eb/77/c7eb77dfaa7628a6c3438cd0139bcb78.jpg") await msg.channel.send(embed = embed) if message.startswith(p + "nuzzle"): for member in x.mentions: print(member) embed = discord.Embed(title = "Nuzzle!", description = "<@" + str(msg.author.id) + "> has nuzzled <@" + str(member.id) + ">!" , color=0x00ff00) if member.id == msg.author.id: embed.description = "<@" + str(msg.author.id) + "> attempts to nuzzle themselves! \n\nUhhhh..??" embed.set_thumbnail(url = "https://pm1.narvii.com/6427/42cdd0b2870e26482cd6907bce2edca12a82286c_hq.jpg") await msg.channel.send(embed = embed) if message.startswith(p + "pat"): for member in x.mentions: print(member) embed = discord.Embed(title = "Pat!", description = "<@" + str(msg.author.id) + "> has pat <@" + str(member.id) + "> softly on the head!" , color=0x00ff00) if member.id == msg.author.id: return embed.set_thumbnail(url = "https://d.facdn.net/art/itsmekurisu/1550247117/1550247117.itsmekurisu_corrina.png") await msg.channel.send(embed = embed) if message.startswith(p + "throwdict"): for member in x.mentions: print(member) embed = discord.Embed(title = "Do u even knowledge?", description = "<@" + str(msg.author.id) + "> has thrown a dictionary at <@" + str(member.id) + ">, landing softly on their head!" , color=0x00ff00) if member.id == msg.author.id: return embed.set_thumbnail(url = "https://i.imgur.com/n58IlmY.png") await msg.channel.send(embed = embed) if message.startswith(p + "bap"): for member in x.mentions: print(member) embed = discord.Embed(title = "Bad furry!", description = "<@" + str(msg.author.id) + "> has bapped <@" + str(member.id) + "> on the nose with a newspaper!" , color=0x00ff00) if member.id == msg.author.id: return embed.set_thumbnail(url = "https://i.ytimg.com/vi/dNrwSeMY-bk/hqdefault.jpg") await msg.channel.send(embed = embed) if message.startswith(p + "rubs"): if not x.mentions: embed = discord.Embed(title = "Belly rubs!", description = "<@" + str(msg.author.id) + "> demands belly rubs!" , color=0x00ff00) embed.set_thumbnail(url = "https://cdn1.cloudcanvas.website/media/sites/119/2018/01/26063531/Belly-rub.jpg") await msg.channel.send(embed = embed) else: for member in x.mentions: embed = discord.Embed(title = "Belly rubs!", description = "<@" + str(msg.author.id) + "> has given <@" + str(member.id) + "> belly rubs!" , color=0x00ff00) if member.id == msg.author.id: embed.description = "<@" + str(msg.author.id) + "> demands belly rubs!" embed.set_thumbnail(url = "https://cdn1.cloudcanvas.website/media/sites/119/2018/01/26063531/Belly-rub.jpg") await msg.channel.send(embed = embed) if message.startswith(p + "howl"): if not x.mentions: embed = discord.Embed(title = "AwooooOooooo!", description = "<@" + str(msg.author.id) + "> has let out a big howl!" , color=0x00ff00) embed.set_thumbnail(url = "https://d.facdn.net/art/windwo1f/1484617505/1484617505.windwo1f_wintie_s_howl.png") await msg.channel.send(embed = embed) else: for member in x.mentions: embed = discord.Embed(title = "AwooooOooooo!", description = "<@" + str(msg.author.id) + "> howls at <@" + str(member.id) + ">" , color=0x00ff00) embed.set_thumbnail(url = "https://d.facdn.net/art/windwo1f/1484617505/1484617505.windwo1f_wintie_s_howl.png") await msg.channel.send(embed = embed) if message.startswith(p + "growl"): if not x.mentions: embed = discord.Embed(title = "A light growl was heard!", description = "<@" + str(msg.author.id) + "> has let out a growl!" , color=0x00ff00) embed.set_thumbnail(url = "https://pm1.narvii.com/6219/8faceb03db01e5c8e64b87dc8fa6d3e18a08011e_hq.jpg") await msg.channel.send(embed = embed) else: for member in x.mentions: embed = discord.Embed(title = "A light growl was heard!", description = "<@" + str(msg.author.id) + "> growls at <@" + str(member.id) +">! Better stay away!" , color=0x00ff00) if member.id == msg.author.id: embed.description = "<@" + str(msg.author.id) + "> has let out a growl!" embed.set_thumbnail(url = "https://pm1.narvii.com/6219/8faceb03db01e5c8e64b87dc8fa6d3e18a08011e_hq.jpg") await msg.channel.send(embed = embed) if message == p + "blep": embed = discord.Embed(title = "Blep!", description = "<@" + str(msg.author.id) + "> has done a blep!" , color=0x00ff00) embed.set_thumbnail(url = "https://i.redd.it/o49rv5hjacm21.png") await msg.channel.send(embed = embed) if message == p + "rawr": embed = discord.Embed(title = "X3!", description = "<@" + str(msg.author.id) + "> lets out a cute little rawr!" , color=0x00ff00) embed.set_thumbnail(url = "https://d.facdn.net/art/yereren/1492210128/1492210128.yereren_ja.png") await msg.channel.send(embed = embed) if message.startswith(p + "boop"): for member in x.mentions: print(member) embed = discord.Embed(title = "Boop!", description = "<@" + str(msg.author.id) + "> has booped <@" + str(member.id) + ">!" , color=0x00ff00) if member.id == msg.author.id: embed.description = "<@" + str(msg.author.id) + "> has booped themselves.. now their nose hurts!" embed.set_thumbnail(url = "https://i.pinimg.com/originals/4c/02/bd/4c02bdb8056ef9bb3883f38eb59d4b8e.jpg") await msg.channel.send(embed = embed) if message.startswith(p + "bite"): for member in x.mentions: print(member) embed = discord.Embed(title = "Bite!", description = "<@" + str(msg.author.id) + "> has nibbled at <@" + str(member.id) + ">'s ear!" , color=0x00ff00) if member.id == msg.author.id: embed.description = "<@" + str(msg.author.id) + "> has bit themselves.. now their hand hurts!" embed.set_thumbnail(url = "https://i.pinimg.com/originals/d3/83/57/d383575a560d2cdc413d5945ea608286.png") await msg.channel.send(embed = embed) if message.startswith(p + "glomp"): for member in x.mentions: print(member) embed = discord.Embed(title = "Glomp!", description = "<@" + str(msg.author.id) + "> has flopped on top of <@" + str(member.id) + ">!" , color=0x00ff00) if member.id == msg.author.id: embed.description = "<@" + str(msg.author.id) + "> has glomped themselves! \n\nWhat a loner.." embed.set_thumbnail(url = "https://d.facdn.net/art/zaezar/1502813432/1502813432.zaezar_glomp.png") await msg.channel.send(embed = embed) if message.startswith(p + "lick"): for member in x.mentions: print(member) embed = discord.Embed(title = "Slurp!", description = "<@" + str(msg.author.id) + "> has licked <@" + str(member.id) + ">, giving them a bath!" , color=0x00ff00) if member.id == msg.author.id: embed.description = "<@" + str(msg.author.id) + "> has gieven themselves a bath!" embed.set_thumbnail(url = "https://t2.ea.ltmcdn.com/en/images/0/7/5/why_do_cats_lick_each_other_2570_600_square.jpg") await msg.channel.send(embed = embed)
59.292576
218
0.590367
1,666
13,578
4.778511
0.166867
0.067831
0.081522
0.07386
0.759578
0.748398
0.723778
0.705941
0.655697
0.646024
0
0.05668
0.250258
13,578
228
219
59.552632
0.725344
0.007439
0
0.551546
0
0.020619
0.266642
0
0
0
0.015436
0
0
1
0
false
0
0.005155
0
0.041237
0.082474
0
0
0
null
0
0
0
0
1
1
1
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
453d1c6d64abc00374fe8f1ac4e5201bd290ea3e
1,618
py
Python
ouroboros/auxiliary/filesystem.py
pavel-kirienko/ouroboros
89365556b16069501c4bef9fd7386cb4f10f281c
[ "MIT" ]
null
null
null
ouroboros/auxiliary/filesystem.py
pavel-kirienko/ouroboros
89365556b16069501c4bef9fd7386cb4f10f281c
[ "MIT" ]
null
null
null
ouroboros/auxiliary/filesystem.py
pavel-kirienko/ouroboros
89365556b16069501c4bef9fd7386cb4f10f281c
[ "MIT" ]
null
null
null
# Copyright (C) 2020 UAVCAN Development Team <uavcan.org> # This software is distributed under the terms of the MIT License. # Author: Pavel Kirienko <pavel@uavcan.org> import os import sys import typing import pathlib AnyPath = typing.Union[str, pathlib.Path] def get_user_data_dir() -> pathlib.Path: if sys.platform.startswith('win32'): _appdata = pathlib.Path(os.getenv('LOCALAPPDATA') or os.getenv('APPDATA')) return _prepare(_appdata / 'UAVCAN' / 'Ouroboros') else: return _prepare(pathlib.Path('~/.uavcan/ouroboros').expanduser()) def get_log_dir() -> pathlib.Path: return _prepare(get_user_data_dir() / 'log') def get_version_specific_dir() -> pathlib.Path: from ouroboros import __version__ return _prepare(get_user_data_dir() / f'v{__version__}') def get_dsdl_generated_dir() -> pathlib.Path: return _prepare(get_version_specific_dir() / 'dsdl_generated') def get_package_root_dir() -> pathlib.Path: import ouroboros return pathlib.Path(ouroboros.__file__).parent def get_public_regulated_data_types_dir() -> pathlib.Path: # TODO: this currently only works when running from sources, obviously. return get_package_root_dir().parent / 'submodules' / 'public_regulated_data_types' def get_ipc_dsdl_dir() -> pathlib.Path: # TODO: this currently only works when running from sources, obviously. return get_package_root_dir().parent / 'ouroboros_ipc' def _prepare(directory: AnyPath) -> pathlib.Path: directory = pathlib.Path(directory).resolve() directory.mkdir(parents=True, exist_ok=True) return directory
29.962963
87
0.736094
212
1,618
5.320755
0.372642
0.126773
0.086879
0.037234
0.264184
0.264184
0.177305
0.177305
0.177305
0.177305
0
0.004386
0.154512
1,618
53
88
30.528302
0.820175
0.187886
0
0
0
0
0.106269
0.020642
0
0
0
0.018868
0
1
0.275862
false
0
0.206897
0.137931
0.793103
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
1
0
0
1
0
0
0
1
1
0
0
4
453dc9de7f6d79e14fafe7507a1f2ba03ceb5c81
122
py
Python
models/MeshCNN/models/__init__.py
devskroy1/ForkedBrainSurfaceTK
774035ab5eae6c0a40eb96eab43d489d3f722eaa
[ "MIT" ]
7
2020-08-04T19:27:33.000Z
2022-01-28T18:00:21.000Z
models/MeshCNN/models/__init__.py
devskroy1/ForkedBrainSurfaceTK
774035ab5eae6c0a40eb96eab43d489d3f722eaa
[ "MIT" ]
null
null
null
models/MeshCNN/models/__init__.py
devskroy1/ForkedBrainSurfaceTK
774035ab5eae6c0a40eb96eab43d489d3f722eaa
[ "MIT" ]
3
2020-12-31T17:26:21.000Z
2021-02-11T19:24:56.000Z
def create_model(opt): from .mesh_classifier import ClassifierModel model = ClassifierModel(opt) return model
24.4
48
0.754098
14
122
6.428571
0.714286
0
0
0
0
0
0
0
0
0
0
0
0.188525
122
4
49
30.5
0.909091
0
0
0
0
0
0
0
0
0
0
0
0
1
0.25
false
0
0.25
0
0.75
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
0
1
0
0
4
453dcb0a6246a6fdddc03be96e49cc2d4db80758
188
py
Python
policykit/integrations/slack/urls.py
mashton/policyk
623523d76d63c06b6d559ad7b477d80512fbd2e7
[ "MIT" ]
78
2020-05-08T17:25:38.000Z
2022-01-13T05:44:50.000Z
policykit/integrations/slack/urls.py
mashton/policyk
623523d76d63c06b6d559ad7b477d80512fbd2e7
[ "MIT" ]
302
2020-02-20T07:04:30.000Z
2022-02-25T17:44:23.000Z
policykit/integrations/slack/urls.py
mashton/policyk
623523d76d63c06b6d559ad7b477d80512fbd2e7
[ "MIT" ]
13
2020-04-17T19:44:26.000Z
2022-02-25T17:18:04.000Z
from django.urls import path from integrations.slack import views urlpatterns = [ path('install', views.slack_install), path('disable_integration', views.disable_integration) ]
18.8
58
0.760638
22
188
6.363636
0.545455
0.257143
0
0
0
0
0
0
0
0
0
0
0.143617
188
9
59
20.888889
0.869565
0
0
0
0
0
0.138298
0
0
0
0
0
0
1
0
false
0
0.333333
0
0.333333
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
0
0
0
4
18cd65454f6e730522d7230e33bdbd628b0787ba
755
py
Python
library/models.py
karmishin/library-app
9400cb0f658e1f9e24defe2600d97c73ae83c7cb
[ "MIT" ]
null
null
null
library/models.py
karmishin/library-app
9400cb0f658e1f9e24defe2600d97c73ae83c7cb
[ "MIT" ]
null
null
null
library/models.py
karmishin/library-app
9400cb0f658e1f9e24defe2600d97c73ae83c7cb
[ "MIT" ]
null
null
null
from django.db import models class Publisher(models.Model): name = models.CharField(max_length=40) def __str__(self): return "%s" % (self.name) class Author(models.Model): first_name = models.CharField(max_length=25) last_name = models.CharField(max_length=25) def __str__(self): return "%s %s" % (self.first_name, self.last_name) class Book(models.Model): title = models.CharField(max_length=40) genre = models.CharField(max_length=25) pub_date = models.IntegerField(default=0) publisher = models.ForeignKey(Publisher, on_delete=models.CASCADE) author = models.ForeignKey(Author, on_delete=models.CASCADE) def __str__(self): return "%s" % (self.title)
27.962963
71
0.671523
97
755
4.979381
0.350515
0.15528
0.186335
0.248447
0.416149
0.21118
0
0
0
0
0
0.018425
0.209272
755
27
72
27.962963
0.79062
0
0
0.166667
0
0
0.012329
0
0
0
0
0
0
1
0.166667
false
0
0.055556
0.166667
1
0
0
0
0
null
0
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
1
1
0
0
4
7a0745163f7034a8aa557744082b105e6db7875c
36
py
Python
user-login.py
cpeberwein/football
9db67aaad162ed42f5a378027762fd340a92c278
[ "Apache-2.0" ]
null
null
null
user-login.py
cpeberwein/football
9db67aaad162ed42f5a378027762fd340a92c278
[ "Apache-2.0" ]
null
null
null
user-login.py
cpeberwein/football
9db67aaad162ed42f5a378027762fd340a92c278
[ "Apache-2.0" ]
null
null
null
Mein neuer Code... New line of code
12
18
0.722222
7
36
3.714286
0.857143
0
0
0
0
0
0
0
0
0
0
0
0.194444
36
2
19
18
0.896552
0
0
0
0
0
0
0
0
0
0
0
0
0
null
null
0
0
null
null
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
1
0
0
0
0
0
0
0
0
4
7a0a2858f03dd5f5df93b7d2e98f9262ed71bc8d
937
py
Python
src/waldur_digitalocean/filters.py
opennode/nodeconductor-digitalocean
4a0f0dc8920c3f066ee8561db54e94e363d07cad
[ "MIT" ]
1
2017-08-16T07:25:53.000Z
2017-08-16T07:25:53.000Z
src/waldur_digitalocean/filters.py
opennode/nodeconductor-digitalocean
4a0f0dc8920c3f066ee8561db54e94e363d07cad
[ "MIT" ]
null
null
null
src/waldur_digitalocean/filters.py
opennode/nodeconductor-digitalocean
4a0f0dc8920c3f066ee8561db54e94e363d07cad
[ "MIT" ]
2
2017-09-24T03:10:31.000Z
2018-08-12T07:44:31.000Z
from django_filters import OrderingFilter from waldur_core.structure import filters as structure_filters from . import models class ImageFilter(structure_filters.BaseServicePropertyFilter): o = OrderingFilter(fields=('distribution', 'type')) class Meta(object): model = models.Image fields = structure_filters.BaseServicePropertyFilter.Meta.fields + ('distribution', 'type') class SizeFilter(structure_filters.BaseServicePropertyFilter): class Meta(object): model = models.Size fields = structure_filters.BaseServicePropertyFilter.Meta.fields + ('cores', 'ram', 'disk') class RegionFilter(structure_filters.BaseServicePropertyFilter): class Meta(structure_filters.BaseServicePropertyFilter.Meta): model = models.Region class DropletFilter(structure_filters.BaseResourceFilter): class Meta(structure_filters.BaseResourceFilter.Meta): model = models.Droplet
29.28125
99
0.765208
89
937
7.932584
0.348315
0.203966
0.348442
0.191218
0.364023
0.161473
0
0
0
0
0
0
0.149413
937
31
100
30.225806
0.885822
0
0
0.111111
0
0
0.046958
0
0
0
0
0
0
1
0
false
0
0.166667
0
0.666667
0
0
0
0
null
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
1
0
0
4
e14026671e95e6c7850769920d7608b09f2f110c
239
py
Python
qregexeditor/api/__init__.py
Giftcarder/QRegexEditor
f8f9fc66e62d77bed81bf9835f8d9769277b165c
[ "MIT" ]
6
2016-01-24T07:35:28.000Z
2021-03-18T12:26:10.000Z
qregexeditor/api/__init__.py
Giftcarder/QRegexEditor
f8f9fc66e62d77bed81bf9835f8d9769277b165c
[ "MIT" ]
1
2019-02-05T17:35:18.000Z
2019-02-05T17:35:18.000Z
qregexeditor/api/__init__.py
Giftcarder/QRegexEditor
f8f9fc66e62d77bed81bf9835f8d9769277b165c
[ "MIT" ]
7
2017-12-26T03:36:55.000Z
2020-12-10T07:12:48.000Z
""" This package contains the API. You may use it to embed the regex editor inside your own PyQt application. """ from .editor import RegexEditorWidget from .quick_ref import QuickRefWidget from .match_highlighter import MatchHighlighter
26.555556
71
0.811715
33
239
5.818182
0.818182
0
0
0
0
0
0
0
0
0
0
0
0.142259
239
8
72
29.875
0.936585
0.439331
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
4
e14f3aea46be09927f8efcac3879a2c49c1dcd93
999
py
Python
mapel/elections/not_in_the_package/__sp.py
kaszperro/mapel
d4e6486ee97f5d5a5a737c581ba3f9f874ebcef3
[ "MIT" ]
3
2020-02-15T11:37:30.000Z
2021-02-21T11:46:10.000Z
mapel/elections/not_in_the_package/__sp.py
kaszperro/mapel
d4e6486ee97f5d5a5a737c581ba3f9f874ebcef3
[ "MIT" ]
9
2020-03-24T11:08:57.000Z
2020-03-24T11:48:04.000Z
mapel/elections/not_in_the_package/__sp.py
kaszperro/mapel
d4e6486ee97f5d5a5a737c581ba3f9f874ebcef3
[ "MIT" ]
4
2020-04-21T17:47:50.000Z
2022-03-25T16:41:04.000Z
from math import * from random import * from sys import argv from scipy.special import binom # binom = comb # size = 20 # wal = walsh(size) # for i in range(size): # for j in range(size): # print(round(wal[j][i],3), end=' ') # print() # if len(argv) < 2: # print("Invocation:") # print(" python walsh.py conitzer|simconitzer|walsh m") # exit() # # m = int(argv[2]) # if argv[1] == "conitzer": # ff = conitzer # elif argv[1] == "simconitzer": # ff = simconitzer # elif argv[1] == "walsh": # ff = walsh # else: # print("unknown distribution") # exit() # P = ff(m) # # B = [0] * m # for j in range(m): # for i in range(m): # print(str(int(PRECISION * (P[i][j]))).rjust(DIGITS), end="") # B[i] += P[i][j] * (m - j - 1) # print() # # S = 0 # for i in range(m): # print(B[i], end=" ") # S += B[i] # print() # print(S) # print(" ") # for i in range(m - 1): # print(B[i + 1] - B[i], end=" ") # print() # # exit()
17.839286
70
0.506507
150
999
3.373333
0.32
0.083004
0.047431
0.086957
0.090909
0.067194
0
0
0
0
0
0.017956
0.275275
999
56
71
17.839286
0.680939
0.811812
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
4
e15fdc9e24d4a7a9cf9114deb211a5208d45f6a0
122
py
Python
back/restapi/models/backup_file.py
ramonakira/piclodio3
5b0365911b8ff3c71a094a8a352c4522b74e7b7d
[ "MIT" ]
120
2017-02-10T14:30:51.000Z
2022-01-12T21:17:56.000Z
back/restapi/models/backup_file.py
ramonakira/piclodio3
5b0365911b8ff3c71a094a8a352c4522b74e7b7d
[ "MIT" ]
28
2017-03-06T09:56:20.000Z
2022-02-27T02:52:38.000Z
back/restapi/models/backup_file.py
ramonakira/piclodio3
5b0365911b8ff3c71a094a8a352c4522b74e7b7d
[ "MIT" ]
24
2017-02-13T20:38:57.000Z
2020-12-21T23:51:00.000Z
from django.db import models class BackupFile(models.Model): backup_file = models.FileField(upload_to="backup_mp3")
20.333333
58
0.778689
17
122
5.411765
0.823529
0
0
0
0
0
0
0
0
0
0
0.009346
0.122951
122
5
59
24.4
0.850467
0
0
0
0
0
0.081967
0
0
0
0
0
0
1
0
false
0
0.333333
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
4
e1957d06e8919dc7ecd4f81066c07726b86dd986
85
py
Python
python/15.3sum.py
stavanmehta/leetcode
1224e43ce29430c840e65daae3b343182e24709c
[ "Apache-2.0" ]
null
null
null
python/15.3sum.py
stavanmehta/leetcode
1224e43ce29430c840e65daae3b343182e24709c
[ "Apache-2.0" ]
null
null
null
python/15.3sum.py
stavanmehta/leetcode
1224e43ce29430c840e65daae3b343182e24709c
[ "Apache-2.0" ]
null
null
null
class Solution: def threeSum(self, nums: List[int]) -> List[List[int]]:
21.25
59
0.588235
11
85
4.545455
0.727273
0.28
0
0
0
0
0
0
0
0
0
0
0.247059
85
3
60
28.333333
0.78125
0
0
0
0
0
0
0
0
0
0
0
0
0
null
null
0
0
null
null
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
1
0
0
0
0
0
0
0
0
4
e1b54d4dfc0727a5d177785c58caed393cb3f38a
52
py
Python
tests/__init__.py
farisachugthai/fatal_police_shootings
7c6e02184b08a39bd63b0eac14d41917056a5b90
[ "MIT" ]
null
null
null
tests/__init__.py
farisachugthai/fatal_police_shootings
7c6e02184b08a39bd63b0eac14d41917056a5b90
[ "MIT" ]
null
null
null
tests/__init__.py
farisachugthai/fatal_police_shootings
7c6e02184b08a39bd63b0eac14d41917056a5b90
[ "MIT" ]
null
null
null
"""Unit test package for fatal_police_shootings."""
26
51
0.769231
7
52
5.428571
1
0
0
0
0
0
0
0
0
0
0
0
0.096154
52
1
52
52
0.808511
0.865385
0
null
0
null
0
0
null
0
0
0
null
1
null
true
0
0
null
null
null
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
1
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
4
bee0c61cea7ad627e80a5f896ced5f151da8ea6b
84
py
Python
change-ethernet-card/secret.py
Haameed/VMWare_automation
8bf46fa5ba37ecc757d5e68983fdc85d96db1301
[ "MIT" ]
null
null
null
change-ethernet-card/secret.py
Haameed/VMWare_automation
8bf46fa5ba37ecc757d5e68983fdc85d96db1301
[ "MIT" ]
null
null
null
change-ethernet-card/secret.py
Haameed/VMWare_automation
8bf46fa5ba37ecc757d5e68983fdc85d96db1301
[ "MIT" ]
null
null
null
domain = 'mycompany.local' user = 'automation@vsphere.local' pwd = 'somepassword'
14
33
0.72619
9
84
6.777778
0.888889
0
0
0
0
0
0
0
0
0
0
0
0.130952
84
5
34
16.8
0.835616
0
0
0
0
0
0.621951
0.292683
0
0
0
0
0
1
0
false
0.333333
0
0
0
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
1
0
null
0
0
0
0
0
0
0
1
0
0
0
0
0
4
833f6437914f73c1d74cd4aae3e4530cd81e19ea
3,407
py
Python
modules/dataGenerators.py
Stsh4lson/TOM-2020
f98ba045aa3905f00412e99b6d979f4de534d126
[ "MIT" ]
4
2020-05-11T14:19:18.000Z
2021-02-23T06:09:09.000Z
modules/dataGenerators.py
Stsh4lson/TOM-2020
f98ba045aa3905f00412e99b6d979f4de534d126
[ "MIT" ]
null
null
null
modules/dataGenerators.py
Stsh4lson/TOM-2020
f98ba045aa3905f00412e99b6d979f4de534d126
[ "MIT" ]
1
2021-02-23T06:09:10.000Z
2021-02-23T06:09:10.000Z
from modules.preprocessing import preprocess_X, preprocess_y, scale from starter_code.utils import load_case import tensorflow as tf import time import numpy as np def trainGenerator(case_nums, batch_size): #takes data from begining of data set to while True: for case_num in case_nums: volume, segmentation = load_case(case_num) #preprocessing input X_file = preprocess_X(volume) y_file, begining_num, end_num = preprocess_y(segmentation) X_file = X_file[begining_num:end_num+1, :, :] y_file = y_file[begining_num:end_num+1, :, :] L = X_file.shape[0] batch_start = 0 batch_end = batch_size while batch_start < L: limit = min(batch_end, L) X = X_file[batch_start:limit, :, :, :] y = y_file[batch_start:limit, :, :, :] yield (tf.cast(X, dtype=tf.float16), tf.cast(y, dtype=tf.float16), [None]) batch_start += batch_size batch_end += batch_size if case_num == case_nums[-1]: break def validationGenerator(case_nums, batch_size): #takes data from begining of data set to while True: for case_num in case_nums: volume, segmentation = load_case(case_num) X_file = preprocess_X(volume) y_file, begining_num, end_num = preprocess_y(segmentation) X_file = X_file[begining_num:end_num+1, :, :] y_file = y_file[begining_num:end_num+1, :, :] L = X_file.shape[0] batch_start = 0 batch_end = batch_size print('Validation in progress: {:.2f}%'.format( ( (case_num-np.min(case_nums))/(np.max(case_nums)-np.min(case_nums)) )*100 )) while batch_start < L: limit = min(batch_end, L) X = X_file[batch_start:limit, :, :, :] y = y_file[batch_start:limit, :, :, :] #needs to yield (X, y, [None]) for some reason yield (tf.cast(X, dtype=tf.float16), tf.cast(y, dtype=tf.float16), [None]) batch_start += batch_size batch_end += batch_size if case_num == case_nums[-1]: # breaks loop so it starts again infinietly break # def validationGenerator(case_nums, batch_size): # #generates random index from given dataset (validation data is given) # while True: # random_val_index = case_nums[np.random.randint(0, len(case_nums))] # volume, segmentation = load_case(random_val_index) # #preprocessing input # X_file = preprocess_X(volume) # y_file = preprocess_y(segmentation) # L = X_file.shape[0] # batch_start = 0 # batch_end = batch_size # print('validation in progress please wait') # while batch_start < L: # limit = min(batch_end, L) # X = X_file[batch_start:limit, :, :, :] # y = y_file[batch_start:limit, :, :, :] # #needs to yield (X, y, [None]) for some reason # yield (X.astype(np.float32), y.astype(np.float32)) # batch_start += batch_size # batch_end += batch_size
41.048193
104
0.552392
423
3,407
4.196217
0.200946
0.084507
0.050704
0.060845
0.757183
0.757183
0.738028
0.698028
0.677746
0.642254
0
0.013016
0.346052
3,407
83
105
41.048193
0.783662
0.319049
0
0.791667
0
0
0.013519
0
0
0
0
0
0
1
0.041667
false
0
0.104167
0
0.145833
0.020833
0
0
0
null
0
0
0
0
1
1
0
0
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
834aacc1ec6024df3d4dbdd2aa19eed71c25d478
873
py
Python
composer/loggers/__init__.py
jacobfulano/composer
4ad81df2d2ca6e5f0b4922bb2db750cd76ba34e8
[ "Apache-2.0" ]
2
2022-03-17T04:48:04.000Z
2022-03-20T09:06:19.000Z
composer/loggers/__init__.py
jacobfulano/composer
4ad81df2d2ca6e5f0b4922bb2db750cd76ba34e8
[ "Apache-2.0" ]
null
null
null
composer/loggers/__init__.py
jacobfulano/composer
4ad81df2d2ca6e5f0b4922bb2db750cd76ba34e8
[ "Apache-2.0" ]
null
null
null
# Copyright 2021 MosaicML. All Rights Reserved. from composer.core.logging.base_backend import BaseLoggerBackend as BaseLoggerBackend from composer.core.logging.base_backend import RankZeroLoggerBackend as RankZeroLoggerBackend from composer.core.logging.logger import Logger as Logger from composer.core.logging.logger import LogLevel as LogLevel from composer.core.logging.logger import TLogData as TLogData from composer.core.logging.logger import TLogDataValue as TLogDataValue from composer.loggers.logger_hparams import BaseLoggerBackendHparams as BaseLoggerBackendHparams from composer.loggers.logger_hparams import FileLoggerBackendHparams as FileLoggerBackendHparams from composer.loggers.logger_hparams import TQDMLoggerBackendHparams as TQDMLoggerBackendHparams from composer.loggers.logger_hparams import WandBLoggerBackendHparams as WandBLoggerBackendHparams
67.153846
98
0.888889
98
873
7.857143
0.265306
0.155844
0.124675
0.179221
0.483117
0.483117
0.103896
0
0
0
0
0.004969
0.077892
873
12
99
72.75
0.951553
0.051546
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
0
0
0
null
0
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
4
8356c77f3ed6240b426faa6079ba48898b6ce591
41
py
Python
1059 - Even Numbers.py
Shah-Shishir/URI-Solutions
fde523e7eefc58e2c319ca1d83c2626e86e12e05
[ "Apache-2.0" ]
null
null
null
1059 - Even Numbers.py
Shah-Shishir/URI-Solutions
fde523e7eefc58e2c319ca1d83c2626e86e12e05
[ "Apache-2.0" ]
null
null
null
1059 - Even Numbers.py
Shah-Shishir/URI-Solutions
fde523e7eefc58e2c319ca1d83c2626e86e12e05
[ "Apache-2.0" ]
null
null
null
for i in range (2,101,2): print(i)
13.666667
26
0.536585
9
41
2.444444
0.777778
0
0
0
0
0
0
0
0
0
0
0.172414
0.292683
41
2
27
20.5
0.586207
0
0
0
0
0
0
0
0
0
0
0
0
1
0
false
0
0
0
0
0.5
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
1
0
4
835e8099f400befa076e28b7f84d587f0be6e335
1,044
py
Python
collide/test_event.py
GluonCollective/collisions
f65f9fd6cc950b8f22e6e4c67ff3d91e75f2ccbe
[ "MIT" ]
null
null
null
collide/test_event.py
GluonCollective/collisions
f65f9fd6cc950b8f22e6e4c67ff3d91e75f2ccbe
[ "MIT" ]
null
null
null
collide/test_event.py
GluonCollective/collisions
f65f9fd6cc950b8f22e6e4c67ff3d91e75f2ccbe
[ "MIT" ]
null
null
null
import pytest from event import Event def example_event(): particles = {'Event': [0, 0, 0, 0, 0, 0, 0], 'Id': [0, 1, 2, 3, 4, 5, 6], 'PdgCode': [0, 1, 1, 2, 2, 2, 2], 'E': [4., 2., 2., 1., 1., 1., 1.], 'Px': [0., 1., -1., 0.5, 0.5, -0.5, -0.5], 'Py': [0., -1., 1., -0.5, 0.5, -0.5, 0.5], 'Pz': [0., 0., 0., 0., 0., 0., 0.], 'Vx': [0., 0., 0., -1., -1, 1., 1.], 'Vy': [0., 0., 0., 0., 0., 0., 0.], 'Vz': [0., 0., 0., 0., 0., 0., 0.], 'Vt': [0., 0., 0., 0., 0., 0., 0.]} mothers = {'Event': [0, 0, 0, 0, 0, 0], 'Id': [1, 2, 3, 4, 5, 6], 'MotherId': [0, 0, 1, 1, 2, 2]} daughters = {'Event': [0, 0, 0, 0, 0, 0], 'Id': [0, 0, 1, 1, 2, 2], 'DaughterId': [1, 2, 3, 4, 5, 6]} return Event(particles, mothers, daughters) print(example_event().trajectories) def test_connect_vertexes(): pass
32.625
59
0.334291
164
1,044
2.103659
0.213415
0.255072
0.295652
0.301449
0.365217
0.350725
0.266667
0.168116
0.063768
0.063768
0
0.191759
0.395594
1,044
31
60
33.677419
0.354992
0
0
0
0
0
0.058429
0
0
0
0
0
0
1
0.083333
false
0.041667
0.083333
0
0.208333
0.041667
0
0
0
null
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
55ce7c0afea3ddf25766d091b65a9a4f55fee12a
6,762
py
Python
src/vaillant_netatmo_api/thermostat_program_test.py
dominikkarall/vaillant-netatmo-api
5da215ef7b2e26eac16950db8994b1af0987975f
[ "MIT" ]
9
2021-09-17T06:23:19.000Z
2022-02-19T21:49:30.000Z
src/vaillant_netatmo_api/thermostat_program_test.py
dominikkarall/vaillant-netatmo-api
5da215ef7b2e26eac16950db8994b1af0987975f
[ "MIT" ]
18
2021-09-20T05:14:10.000Z
2022-03-16T05:18:13.000Z
src/vaillant_netatmo_api/thermostat_program_test.py
dominikkarall/vaillant-netatmo-api
5da215ef7b2e26eac16950db8994b1af0987975f
[ "MIT" ]
1
2022-02-27T09:53:24.000Z
2022-02-27T09:53:24.000Z
import pytest from datetime import datetime from pytest_mock import MockerFixture from vaillant_netatmo_api.thermostat import Program @pytest.mark.parametrize( "current_time,expected_active_zone_id", [ # Monday (datetime(2021, 11, 22, 0, 0), 1), (datetime(2021, 11, 22, 0, 59), 1), (datetime(2021, 11, 22, 1, 0), 0), (datetime(2021, 11, 22, 1, 1), 0), (datetime(2021, 11, 22, 1, 59), 0), (datetime(2021, 11, 22, 2, 0), 2), (datetime(2021, 11, 22, 2, 1), 2), (datetime(2021, 11, 22, 23, 59), 2), # Tuesday (datetime(2021, 11, 23, 0, 0), 1), (datetime(2021, 11, 23, 0, 59), 1), (datetime(2021, 11, 23, 1, 0), 0), (datetime(2021, 11, 23, 1, 1), 0), (datetime(2021, 11, 23, 1, 59), 0), (datetime(2021, 11, 23, 2, 0), 2), (datetime(2021, 11, 23, 2, 1), 2), (datetime(2021, 11, 23, 23, 59), 2), # Wednesday (datetime(2021, 11, 24, 0, 0), 1), (datetime(2021, 11, 24, 0, 59), 1), (datetime(2021, 11, 24, 1, 0), 0), (datetime(2021, 11, 24, 1, 1), 0), (datetime(2021, 11, 24, 1, 59), 0), (datetime(2021, 11, 24, 2, 0), 2), (datetime(2021, 11, 24, 2, 1), 2), (datetime(2021, 11, 24, 23, 59), 2), # Thursday (datetime(2021, 11, 25, 0, 0), 1), (datetime(2021, 11, 25, 0, 59), 1), (datetime(2021, 11, 25, 1, 0), 0), (datetime(2021, 11, 25, 1, 1), 0), (datetime(2021, 11, 25, 1, 59), 0), (datetime(2021, 11, 25, 2, 0), 2), (datetime(2021, 11, 25, 2, 1), 2), (datetime(2021, 11, 25, 23, 59), 2), # Friday (datetime(2021, 11, 26, 0, 0), 1), (datetime(2021, 11, 26, 0, 59), 1), (datetime(2021, 11, 26, 1, 0), 0), (datetime(2021, 11, 26, 1, 1), 0), (datetime(2021, 11, 26, 1, 59), 0), (datetime(2021, 11, 26, 2, 0), 2), (datetime(2021, 11, 26, 2, 1), 2), (datetime(2021, 11, 26, 23, 59), 2), # Saturday (datetime(2021, 11, 27, 0, 0), 1), (datetime(2021, 11, 27, 0, 59), 1), (datetime(2021, 11, 27, 1, 0), 0), (datetime(2021, 11, 27, 1, 1), 0), (datetime(2021, 11, 27, 1, 59), 0), (datetime(2021, 11, 27, 2, 0), 2), (datetime(2021, 11, 27, 2, 1), 2), (datetime(2021, 11, 27, 23, 59), 2), # Sunday (datetime(2021, 11, 28, 0, 0), 1), (datetime(2021, 11, 28, 0, 59), 1), (datetime(2021, 11, 28, 1, 0), 0), (datetime(2021, 11, 28, 1, 1), 0), (datetime(2021, 11, 28, 1, 59), 0), (datetime(2021, 11, 28, 2, 0), 2), (datetime(2021, 11, 28, 2, 1), 2), (datetime(2021, 11, 28, 23, 59), 2), # Monday (datetime(2021, 11, 29, 0, 0), 1), (datetime(2021, 11, 29, 0, 59), 1), (datetime(2021, 11, 29, 1, 0), 0), (datetime(2021, 11, 29, 1, 1), 0), (datetime(2021, 11, 29, 1, 59), 0), (datetime(2021, 11, 29, 2, 0), 2), (datetime(2021, 11, 29, 2, 1), 2), (datetime(2021, 11, 29, 23, 59), 2), ] ) @pytest.mark.asyncio class TestProgramForZones: async def test_get_active_zone__timetable_with_three_slots_per_day__returns_correct_index_around_bounderies(self, current_time: datetime, expected_active_zone_id: int, mocker: MockerFixture): mocker.patch("vaillant_netatmo_api.thermostat.now", return_value=current_time) program = Program( zones=[ {"id": 0}, {"id": 1}, {"id": 2}, ], timetable=[ {"id": 1, "m_offset": 0}, {"id": 0, "m_offset": 60}, {"id": 2, "m_offset": 120}, {"id": 1, "m_offset": 1440}, {"id": 0, "m_offset": 1500}, {"id": 2, "m_offset": 1560}, {"id": 1, "m_offset": 2880}, {"id": 0, "m_offset": 2940}, {"id": 2, "m_offset": 3000}, {"id": 1, "m_offset": 4320}, {"id": 0, "m_offset": 4380}, {"id": 2, "m_offset": 4440}, {"id": 1, "m_offset": 5760}, {"id": 0, "m_offset": 5820}, {"id": 2, "m_offset": 5880}, {"id": 1, "m_offset": 7200}, {"id": 0, "m_offset": 7260}, {"id": 2, "m_offset": 7320}, {"id": 1, "m_offset": 8640}, {"id": 0, "m_offset": 8700}, {"id": 2, "m_offset": 8760}, ], ) active_zone = program.get_active_zone() assert active_zone.id == expected_active_zone_id @pytest.mark.asyncio class TestProgramForTimeslots: async def test_get_timeslots_for_today__timetable_with_alternating_zones__returns_monday_without_padding(self, mocker: MockerFixture): monday = datetime(2021, 11, 22, 1, 0) mocker.patch("vaillant_netatmo_api.thermostat.now", return_value=monday) program = Program( timetable=[ {"id": 2, "m_offset": 0}, {"id": 0, "m_offset": 60}, {"id": 1, "m_offset": 120}, {"id": 0, "m_offset": 1500}, {"id": 2, "m_offset": 1560}, {"id": 0, "m_offset": 2940}, {"id": 1, "m_offset": 3000}, ], ) time_slots = program.get_timeslots_for_today() assert len(time_slots) == 3 assert time_slots[0].id == 2 assert time_slots[0].m_offset == 0 assert time_slots[1].id == 0 assert time_slots[1].m_offset == 60 assert time_slots[2].id == 1 assert time_slots[2].m_offset == 120 async def test_get_timeslots_for_today__timetable_with_alternating_zones__returns_other_days_with_padding(self, mocker: MockerFixture): tuesday = datetime(2021, 11, 23, 1, 0) mocker.patch("vaillant_netatmo_api.thermostat.now", return_value=tuesday) program = Program( timetable=[ {"id": 2, "m_offset": 0}, {"id": 0, "m_offset": 60}, {"id": 1, "m_offset": 120}, {"id": 0, "m_offset": 1500}, {"id": 2, "m_offset": 1560}, {"id": 0, "m_offset": 2940}, {"id": 1, "m_offset": 3000}, ], ) time_slots = program.get_timeslots_for_today() assert len(time_slots) == 3 assert time_slots[0].id == 1 assert time_slots[0].m_offset == 1440 assert time_slots[1].id == 0 assert time_slots[1].m_offset == 1500 assert time_slots[2].id == 2 assert time_slots[2].m_offset == 1560
37.359116
195
0.488761
910
6,762
3.482418
0.10989
0.249921
0.291575
0.113601
0.70243
0.616914
0.255917
0.255917
0.255917
0.23225
0
0.211577
0.333185
6,762
180
196
37.566667
0.49124
0.009317
0
0.232258
0
0
0.07429
0.021076
0
0
0
0
0.096774
1
0
false
0
0.025806
0
0.03871
0
0
0
0
null
1
1
0
0
0
0
0
0
0
0
1
0
0
0
0
0
1
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
55f0d82a32c45c2027cb9097e5fa964dd41c40f2
213
py
Python
backend/storymanager/storymanager/urls.py
aliiae/foldoverstories
6cb22e1c793f22f7904aee221ac27b7eaf3b68bb
[ "MIT" ]
1
2019-11-01T16:59:56.000Z
2019-11-01T16:59:56.000Z
backend/storymanager/storymanager/urls.py
aliiae/foldoverstories
6cb22e1c793f22f7904aee221ac27b7eaf3b68bb
[ "MIT" ]
null
null
null
backend/storymanager/storymanager/urls.py
aliiae/foldoverstories
6cb22e1c793f22f7904aee221ac27b7eaf3b68bb
[ "MIT" ]
null
null
null
from django.urls import path, include urlpatterns = [ path('', include('websockets.urls')), path('', include('texts.urls')), path('', include('rooms.urls')), path('', include('accounts.urls')), ]
23.666667
41
0.610329
23
213
5.652174
0.478261
0.423077
0.346154
0
0
0
0
0
0
0
0
0
0.159624
213
8
42
26.625
0.726257
0
0
0
0
0
0.225352
0
0
0
0
0
0
1
0
false
0
0.142857
0
0.142857
0
1
0
0
null
1
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
55f959ad4c8b3f35252860353bbff60fdd131f8b
403
py
Python
aliyun/api/rest/Ecs20140526ModifyInstanceVncPasswdRequest.py
snowyxx/aliyun-python-demo
ed40887ddff440b85b77f9b2a1fcda11cca55c8b
[ "Apache-2.0" ]
null
null
null
aliyun/api/rest/Ecs20140526ModifyInstanceVncPasswdRequest.py
snowyxx/aliyun-python-demo
ed40887ddff440b85b77f9b2a1fcda11cca55c8b
[ "Apache-2.0" ]
null
null
null
aliyun/api/rest/Ecs20140526ModifyInstanceVncPasswdRequest.py
snowyxx/aliyun-python-demo
ed40887ddff440b85b77f9b2a1fcda11cca55c8b
[ "Apache-2.0" ]
null
null
null
''' Created by auto_sdk on 2015.03.24 ''' from aliyun.api.base import RestApi class Ecs20140526ModifyInstanceVncPasswdRequest(RestApi): def __init__(self,domain='ecs.aliyuncs.com',port=80): RestApi.__init__(self,domain, port) self.InstanceId = None self.RegionId = None self.VncPassword = None def getapiname(self): return 'ecs.aliyuncs.com.ModifyInstanceVncPasswd.2014-05-26'
28.785714
63
0.746898
51
403
5.72549
0.686275
0.054795
0.09589
0
0
0
0
0
0
0
0
0.074928
0.138958
403
13
64
31
0.766571
0.081886
0
0
0
0
0.191977
0.146132
0
0
0
0
0
1
0.222222
false
0.333333
0.111111
0.111111
0.555556
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
1
0
1
1
0
0
4
55fcb01400db1ee2233532c4352aaed8b3ee603b
2,941
py
Python
tests/test_parser_helpers.py
k8iechen/vcfpy
89f7097cb5bc7bfec198d8c02fe031b44786b14b
[ "MIT" ]
48
2016-09-25T16:07:53.000Z
2022-01-19T17:44:46.000Z
tests/test_parser_helpers.py
k8iechen/vcfpy
89f7097cb5bc7bfec198d8c02fe031b44786b14b
[ "MIT" ]
83
2016-09-16T12:20:02.000Z
2021-05-12T09:12:10.000Z
tests/test_parser_helpers.py
k8iechen/vcfpy
89f7097cb5bc7bfec198d8c02fe031b44786b14b
[ "MIT" ]
9
2016-10-04T15:10:06.000Z
2022-02-08T21:10:51.000Z
# -*- coding: utf-8 -*- """Test for the helper routines in the vcfpy.parser module""" import pytest from vcfpy import parser __author__ = "Manuel Holtgrewe <manuel.holtgrewe@bihealth.de>" # parser.split_quoted_string() ------------------------------------------------ def test_split_quoted_string_one_noquote(): INPUT = "foo=bar" EXPECTED = ["foo=bar"] assert EXPECTED == parser.split_quoted_string(INPUT) def test_split_quoted_string_two_noquote(): INPUT = "foo=bar,bar=baz" EXPECTED = ["foo=bar", "bar=baz"] assert EXPECTED == parser.split_quoted_string(INPUT) def test_split_quoted_string_one_quote(): INPUT = 'foo="bar,,"asdf' EXPECTED = ['foo="bar,,"asdf'] assert EXPECTED == parser.split_quoted_string(INPUT) def test_split_quoted_string_two_quote(): INPUT = 'foo="bar,,"asdf,"bar"=baz' EXPECTED = ['foo="bar,,"asdf', '"bar"=baz'] assert EXPECTED == parser.split_quoted_string(INPUT) def test_split_quoted_string_one_escape(): INPUT = 'foo="bar\\"asdf\\"asdf"' EXPECTED = ['foo="bar\\"asdf\\"asdf"'] assert EXPECTED == parser.split_quoted_string(INPUT) def test_split_quoted_string_two_escape(): INPUT = 'foo="bar\\",,asdf","bar"=baz' EXPECTED = ['foo="bar\\",,asdf"', '"bar"=baz'] assert EXPECTED == parser.split_quoted_string(INPUT) def test_split_quoted_string_array_syntax_simple(): INPUT = "foo=[1, 2, 3],bar=[baz, gnaa]" EXPECTED = ["foo=[1, 2, 3]", "bar=[baz, gnaa]"] assert EXPECTED == parser.split_quoted_string(INPUT) def test_split_quoted_string_array_syntax_recursion(): """Support for only one level, failure is OK here""" INPUT = "foo=[1, 2, 3],bar=[baz, [], gnaa]" EXPECTED = ["foo=[1, 2, 3]", "bar=[baz, []", " gnaa]"] assert EXPECTED == parser.split_quoted_string(INPUT) # parser.VCFheaderLineParser.parse_mapping() ---------------------------------- def test_vcf_header_line_parser_parse_mapping_simple(): INPUT = r"<key=value,key2=value2>" EXPECTED = (("key", "value"), ("key2", "value2")) assert EXPECTED == tuple(parser.parse_mapping(INPUT).items()) def test_vcf_header_line_parser_parse_mapping_flag(): INPUT = r"<key=value,key2=value,yay>" EXPECTED = (("key", "value"), ("key2", "value"), ("yay", True)) parser.MappingHeaderLineParser(None) assert EXPECTED == tuple(parser.parse_mapping(INPUT).items()) def test_vcf_header_line_parser_parse_mapping_quoted(): INPUT = r'<key=value,key2="value,value">' EXPECTED = (("key", "value"), ("key2", "value,value")) parser.MappingHeaderLineParser(None) assert EXPECTED == tuple(parser.parse_mapping(INPUT).items()) def test_vcf_header_line_parser_parse_mapping_escaped(): INPUT = r'<key=value,key2="value,value=\"asdf">' EXPECTED = (("key", "value"), ("key2", 'value,value="asdf')) parser.MappingHeaderLineParser(None) assert EXPECTED == tuple(parser.parse_mapping(INPUT).items())
32.318681
79
0.66576
377
2,941
4.93634
0.185676
0.100484
0.155293
0.111231
0.808705
0.724342
0.660935
0.630844
0.610425
0.610425
0
0.009095
0.140088
2,941
90
80
32.677778
0.726769
0.095546
0
0.277778
0
0
0.225538
0.092558
0
0
0
0
0.222222
1
0.222222
false
0
0.037037
0
0.259259
0
0
0
0
null
0
0
0
1
1
0
0
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
0
0
0
0
4
3604768564daf647df02fe4b7af293dbfe37443c
93
py
Python
site/projectLms/Faculdade/apps.py
GuiGusmao/LMSProjeto
2c1ffc302068c7d97a79a847b47640e0a6e3dde4
[ "Apache-2.0" ]
null
null
null
site/projectLms/Faculdade/apps.py
GuiGusmao/LMSProjeto
2c1ffc302068c7d97a79a847b47640e0a6e3dde4
[ "Apache-2.0" ]
null
null
null
site/projectLms/Faculdade/apps.py
GuiGusmao/LMSProjeto
2c1ffc302068c7d97a79a847b47640e0a6e3dde4
[ "Apache-2.0" ]
null
null
null
from django.apps import AppConfig class FaculdadeConfig(AppConfig): name = 'Faculdade'
15.5
33
0.763441
10
93
7.1
0.9
0
0
0
0
0
0
0
0
0
0
0
0.16129
93
5
34
18.6
0.910256
0
0
0
0
0
0.096774
0
0
0
0
0
0
1
0
false
0
0.333333
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
4
3606c96817ab3940a601735042682cb8f757c34d
315
py
Python
google/__init__.py
shrijaltamrakar/Descent_py
82cd89ebeca37d079fc5d072010d3a3120420b2a
[ "MIT" ]
2
2018-11-17T10:03:25.000Z
2019-01-24T08:40:10.000Z
google/__init__.py
shrijaltamrakar/Descent_py
82cd89ebeca37d079fc5d072010d3a3120420b2a
[ "MIT" ]
1
2021-06-02T00:16:58.000Z
2021-06-02T00:16:58.000Z
google/__init__.py
shrijaltamrakar/Descent_py
82cd89ebeca37d079fc5d072010d3a3120420b2a
[ "MIT" ]
1
2019-10-25T06:46:10.000Z
2019-10-25T06:46:10.000Z
""" _ __ _ ___ ___ __ _| | ___ / _` |/ _ \ / _ \ / _` | |/ _ \ | (_| | (_) | (_) | (_| | | __/ \__, |\___/ \___/ \__, |_|\___| |___/ |___/ Author: Aaditya Chapagain version: 1.0.1 description: scripts which will make google API's easy in python. """
22.5
65
0.419048
18
315
4.722222
0.944444
0
0
0
0
0
0
0
0
0
0
0.015625
0.390476
315
14
66
22.5
0.427083
0.885714
0
null
0
null
0
0
null
0
0
0
null
1
null
true
0
0
null
null
null
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
1
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
4
361b22233d3eb9aef769558b987ef402ff94e67b
145
py
Python
starter_code/api_keys.py
dsc55704973/python-api-challenge
7a2719ee01bdcc3022910d86db87830076f947cb
[ "ADSL" ]
null
null
null
starter_code/api_keys.py
dsc55704973/python-api-challenge
7a2719ee01bdcc3022910d86db87830076f947cb
[ "ADSL" ]
null
null
null
starter_code/api_keys.py
dsc55704973/python-api-challenge
7a2719ee01bdcc3022910d86db87830076f947cb
[ "ADSL" ]
null
null
null
# OpenWeatherMap API Key weather_api_key = "ea45174aae3e4fc5de1af5d14f74cd81" # Google API Key g_key = "AIzaSyCiyVKYg3FYX0fAR2S2RGR1m-kUN947W9s"
29
52
0.841379
14
145
8.5
0.642857
0.151261
0
0
0
0
0
0
0
0
0
0.19084
0.096552
145
5
53
29
0.717557
0.255172
0
0
0
0
0.669811
0.669811
0
0
0
0
0
1
0
false
0
0
0
0
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
1
1
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
363d5ed1f828d3f2fa60a8073d143216650e8354
98
py
Python
armine/__init__.py
pri22296/arm
33014a4d4bbd849e246675897d6c4a6d86d66328
[ "MIT" ]
7
2017-05-02T10:13:01.000Z
2020-12-07T02:24:02.000Z
armine/__init__.py
pri22296/arm
33014a4d4bbd849e246675897d6c4a6d86d66328
[ "MIT" ]
3
2017-05-12T10:13:18.000Z
2017-05-25T11:46:57.000Z
armine/__init__.py
pri22296/arm
33014a4d4bbd849e246675897d6c4a6d86d66328
[ "MIT" ]
3
2017-10-03T07:19:12.000Z
2020-05-07T18:31:38.000Z
from .armine import ARM from .classifier import ARMClassifier __all__ = ['ARM', 'ARMClassifier']
19.6
37
0.765306
11
98
6.454545
0.636364
0
0
0
0
0
0
0
0
0
0
0
0.132653
98
4
38
24.5
0.835294
0
0
0
0
0
0.163265
0
0
0
0
0
0
1
0
false
0
0.666667
0
0.666667
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
4
363e4ac9b3dde9ea41351cf75903bc21c1584732
29
py
Python
atcoder/corp/codefes2014f_a.py
knuu/competitive-programming
16bc68fdaedd6f96ae24310d697585ca8836ab6e
[ "MIT" ]
1
2018-11-12T15:18:55.000Z
2018-11-12T15:18:55.000Z
atcoder/corp/codefes2014f_a.py
knuu/competitive-programming
16bc68fdaedd6f96ae24310d697585ca8836ab6e
[ "MIT" ]
null
null
null
atcoder/corp/codefes2014f_a.py
knuu/competitive-programming
16bc68fdaedd6f96ae24310d697585ca8836ab6e
[ "MIT" ]
null
null
null
s = int(input()) print(50/s)
9.666667
16
0.586207
6
29
2.833333
0.833333
0
0
0
0
0
0
0
0
0
0
0.08
0.137931
29
2
17
14.5
0.6
0
0
0
0
0
0
0
0
0
0
0
0
1
0
false
0
0
0
0
0.5
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
1
0
4
3649cd234fc1ebf8ac99dfa30e859e123a6b81bc
992
py
Python
ex007-Tabuada.py
GuSilva20/Primeiros-Codigos
67deefb683b40c2c4fee1bb383730588635e9d85
[ "MIT" ]
null
null
null
ex007-Tabuada.py
GuSilva20/Primeiros-Codigos
67deefb683b40c2c4fee1bb383730588635e9d85
[ "MIT" ]
null
null
null
ex007-Tabuada.py
GuSilva20/Primeiros-Codigos
67deefb683b40c2c4fee1bb383730588635e9d85
[ "MIT" ]
null
null
null
t=int(input('Tabuada do : ')) r1 = t * 1 r2 = t * 2 r3 = t * 3 r4 = t * 4 r5 = t * 5 r6 = t * 6 r7 = t * 7 r8 = t * 8 r9 = t * 9 r10 = t * 10 print("RESUlTADO\n------------------------") print('{} x 1 = {}'.format(t,r1)) print('{} x 2 = {}'.format(t,r2)) print('{} x 3 = {}'.format(t,r3)) print('{} x 4 = {}'.format(t,r4)) print('{} x 5 = {}'.format(t,r5)) print('{} x 6 = {}'.format(t,r6)) print('{} x 7 = {}'.format(t,r7)) print('{} x 8 = {}'.format(t,r8)) print('{} x 9 = {}'.format(t,r9)) print('{} x 10 = {}'.format(t,r10)) #Gabarito print("-"*20) print('{} x {:2} = {}'.format(t, 1, t*1)) print('{} x {:2} = {}'.format(t, 2, t*2)) print('{} x {:2} = {}'.format(t, 3, t*3)) print('{} x {:2} = {}'.format(t, 4, t*4)) print('{} x {:2} = {}'.format(t, 5, t*5)) print('{} x {:2} = {}'.format(t, 6, t*6)) print('{} x {:2} = {}'.format(t, 7, t*7)) print('{} x {:2} = {}'.format(t, 8, t*8)) print('{} x {:2} = {}'.format(t, 9, t*9)) print('{} x {:2} = {}'.format(t, 10, t*10)) print("-"*20)
25.435897
44
0.434476
183
992
2.355191
0.174863
0.278422
0.178654
0.331787
0.357309
0
0
0
0
0
0
0.098644
0.18246
992
39
45
25.435897
0.432799
0.008065
0
0.058824
0
0
0.305894
0.035569
0
0
0
0
0
1
0
false
0
0
0
0
0.676471
0
0
0
null
1
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
1
0
4
365b68b64bbc7b13d4b0b966065f32f44c7c1cd3
4,698
py
Python
google_api_v3_helper/google_api_helper.py
sbi-rviot/google_api_helper
3435f3d24fcd293f38d36eea2218d91ca383d1d6
[ "MIT" ]
2
2020-05-18T19:05:56.000Z
2020-09-24T16:24:04.000Z
google_api_v3_helper/google_api_helper.py
sbi-rviot/google_api_helper
3435f3d24fcd293f38d36eea2218d91ca383d1d6
[ "MIT" ]
null
null
null
google_api_v3_helper/google_api_helper.py
sbi-rviot/google_api_helper
3435f3d24fcd293f38d36eea2218d91ca383d1d6
[ "MIT" ]
null
null
null
def get_google_folder_id(service, folder_name): """Get folder id of a folder in Google Drive Arguments: service: in order to use any of this library, the user needs to first build the service class using google ServiceAccountCredentials. see https://pypi.org/project/google-api-v3-helper/ or https://github.com/sbi-rviot/google_api_helper for a full example. folder_name: name of the folder you wish to get the ID of. """ page_token = None while True: children = service.files().list(q="mimeType='application/vnd.google-apps.folder'", spaces='drive',fields='nextPageToken, files(id, name)').execute() for i in children['files']: if i['name'] == folder_name: folder_id = i['id'] break page_token = children.get('nextPageToken', None) if page_token is None: break return folder_id def get_google_folders_in_folder(service, folder_id): """Get a list of folders in a folder in Google Drive Arguments: service: in order to use any of this library, the user needs to first build the service class using google ServiceAccountCredentials. see https://pypi.org/project/google-api-v3-helper/ or https://github.com/sbi-rviot/google_api_helper for a full example. folder_id: id of the folder you wish to get the folders list of. """ files_list = [] page_token = None while True: children = service.files().list(q="mimeType='application/vnd.google-apps.folder' and parents='"+folder_id+"' and trashed=false", spaces='drive', fields='nextPageToken, files(id, name)').execute() for file in children.get('files', []): files_list.append({'name':file.get('name'), 'id':file.get('id')}) page_token = children.get('nextPageToken', None) if page_token is None: break return files_list def get_google_files_in_folder(service, folder_id): """Get a list of files and folders in a folder in Google Drive Arguments: service: in order to use any of this library, the user needs to first build the service class using google ServiceAccountCredentials. see https://pypi.org/project/google-api-v3-helper/ or https://github.com/sbi-rviot/google_api_helper for a full example. folder_id: id of the folder you wish to get the folders list of. """ files_list = [] page_token = None while True: children = service.files().list(q="parents='"+folder_id+"' and trashed=false", spaces='drive', fields='nextPageToken, files(id, name)').execute() for file in children.get('files', []): files_list.append({'name':file.get('name'), 'id':file.get('id')}) page_token = children.get('nextPageToken', None) if page_token is None: break return files_list def uplaod_google_file(service, MediaFileUpload, parent_id, file_name): """Upload a file in a folder in Google Drive Arguments: service: in order to use any of this library, the user needs to first build the service class using google ServiceAccountCredentials. see https://pypi.org/project/google-api-v3-helper/ or https://github.com/sbi-rviot/google_api_helper for a full example. MediaFileUpload: function of oauth2client.service_account. see www.pypi.com for a full example. parent_id: id of the folder you wish to get the folders list of. file_name: local path to the file. If the file is in the same folder as your script, then you should only enter here the name of your file. """ file_metadata = { 'parents' : [parent_id], 'name': file_name} media = MediaFileUpload(file_name) file = service.files().create(body=file_metadata, media_body=media, fields='id').execute() return parent_id def find_google_fileid_tree(service, fileId): """Find the folder tree of a file Arguments: service: in order to use any of this library, the user needs to first build the service class using google ServiceAccountCredentials. see https://pypi.org/project/google-api-v3-helper/ or https://github.com/sbi-rviot/google_api_helper for a full example. fileId: id of the file you wish to get the tree for. """ file = service.files().get(fileId=fileId, fields='id, name, parents').execute() tree = [] parent = file.get('parents') if parent: while True: folder = service.files().get( fileId=parent[0], fields='id, name, parents').execute() parent = folder.get('parents') if parent is None: break tree.append({'id': parent[0], 'name': folder.get('name')}) return tree
46.058824
258
0.67433
679
4,698
4.571429
0.147275
0.025773
0.015464
0.028995
0.727771
0.706186
0.706186
0.706186
0.697809
0.660116
0
0.002177
0.217752
4,698
102
259
46.058824
0.842449
0.452533
0
0.517241
0
0
0.164729
0.036072
0
0
0
0
0
1
0.086207
false
0
0
0
0.172414
0
0
0
0
null
0
0
0
0
1
1
1
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
3668a65610e7b0d4aef8a4067f36bfe8d40089a6
949
py
Python
nanoscope/error.py
nnewman/nanoscope
d523edb60a11f773b0355a005ee9888316e0b92e
[ "MIT" ]
9
2016-03-10T11:18:23.000Z
2021-08-28T04:33:58.000Z
nanoscope/error.py
nnewman/nanoscope
d523edb60a11f773b0355a005ee9888316e0b92e
[ "MIT" ]
8
2015-02-12T05:06:13.000Z
2022-03-09T09:02:00.000Z
nanoscope/error.py
nnewman/nanoscope
d523edb60a11f773b0355a005ee9888316e0b92e
[ "MIT" ]
3
2016-03-10T11:20:16.000Z
2021-08-28T04:34:05.000Z
# -*- coding: utf-8 -*- from __future__ import absolute_import, unicode_literals class Error(Exception): """Base exception for nanoscope errors.""" pass class UnsupportedVersion(Error): """Error for unsupported SPM file version.""" def __init__(self, version): self.version = version def __str__(self): return 'Unsupported file version {}'.format(self.version) class MissingImageData(Error): """Error for missing data for defined image in header.""" def __init__(self, image): self.image = image def __str__(self): return ('Image type {} found in header ' 'but is missing data'.format(self.image)) class InvalidParameter(Error): """Error for incorrectly formatted Ciao parameter.""" def __init__(self, parameter): self.parameter = parameter def __str__(self): return '"{}" is not a valid Ciao parameter'.format(self.parameter)
24.333333
74
0.659642
109
949
5.46789
0.431193
0.050336
0.065436
0.080537
0
0
0
0
0
0
0
0.001364
0.227608
949
38
75
24.973684
0.811733
0.209694
0
0.157895
0
0
0.150892
0
0
0
0
0
0
1
0.315789
false
0.052632
0.052632
0.157895
0.736842
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
1
0
1
1
0
0
4
36bb07fd94c8a6f9ca9fea7acb8b71770d7cf35b
1,778
py
Python
test_autofit/unit/aggregator/test_numerical_filtering.py
arfon/PyAutoFit
5926b13eefd97e089ee468cbec33452766edbd22
[ "MIT" ]
1
2021-01-18T23:20:31.000Z
2021-01-18T23:20:31.000Z
test_autofit/unit/aggregator/test_numerical_filtering.py
arfon/PyAutoFit
5926b13eefd97e089ee468cbec33452766edbd22
[ "MIT" ]
null
null
null
test_autofit/unit/aggregator/test_numerical_filtering.py
arfon/PyAutoFit
5926b13eefd97e089ee468cbec33452766edbd22
[ "MIT" ]
null
null
null
import pytest @pytest.fixture(name="ages_for_predicate") def make_ages_for_predicate(path_aggregator): def ages_for_predicate(predicate): result = path_aggregator.filter(predicate) return [child.age for child in result.values("child")] return ages_for_predicate class TestNumericalFiltering: def test_equality(self, path_aggregator): predicate = path_aggregator.child.age == 17 result = path_aggregator.filter(predicate) assert len(result) == 1 assert list(result.values("child"))[0].age == 17 def test_greater_than(self, ages_for_predicate, path_aggregator): ages = ages_for_predicate(path_aggregator.child.age > 10) assert ages == [17] def test_greater_than_equal(self, ages_for_predicate, path_aggregator): ages = ages_for_predicate(path_aggregator.child.age >= 10) assert set(ages) == {10, 17} def test_less_than(self, ages_for_predicate, path_aggregator): ages = ages_for_predicate(path_aggregator.child.age < 11) assert ages == [10] def test_greater_than_rhs(self, ages_for_predicate, path_aggregator): ages = ages_for_predicate(10 < path_aggregator.child.age) assert ages == [17] def test_less_than_rhs(self, ages_for_predicate, path_aggregator): ages = ages_for_predicate(11 > path_aggregator.child.age) assert ages == [10] def test_aggregator_to_aggregator(self, path_aggregator): predicate = path_aggregator.child.age == path_aggregator.child.age assert len(path_aggregator.filter(predicate)) == 2 predicate = path_aggregator.child.age > path_aggregator.child.age assert len(path_aggregator.filter(predicate)) == 0
38.652174
76
0.694038
224
1,778
5.205357
0.174107
0.264151
0.19211
0.188679
0.755575
0.589194
0.534305
0.534305
0.476844
0.476844
0
0.021444
0.213161
1,778
45
77
39.511111
0.812009
0
0
0.181818
0
0
0.016157
0
0
0
0
0
0.272727
1
0.272727
false
0
0.030303
0
0.393939
0
0
0
0
null
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
0
0
0
0
4
7ff48baa70c160c1bc92e1739426b99206a3204e
21
py
Python
lib/python2.7/site-packages/setuptools/version.py
vipulkanade/EventbriteDjango
075036563db1fe41fa7c5a541eda3999be328be0
[ "MIT" ]
null
null
null
lib/python2.7/site-packages/setuptools/version.py
vipulkanade/EventbriteDjango
075036563db1fe41fa7c5a541eda3999be328be0
[ "MIT" ]
1
2016-02-29T01:35:27.000Z
2016-02-29T01:35:27.000Z
lib/python2.7/site-packages/setuptools/version.py
vipulkanade/EventbriteDjango
075036563db1fe41fa7c5a541eda3999be328be0
[ "MIT" ]
null
null
null
__version__ = '19.4'
10.5
20
0.666667
3
21
3.333333
1
0
0
0
0
0
0
0
0
0
0
0.166667
0.142857
21
1
21
21
0.388889
0
0
0
0
0
0.190476
0
0
0
0
0
0
1
0
false
0
0
0
0
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
1
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
3d1288ee855afb4ebad41b2d68945ea92ee79974
3,177
py
Python
Python/problem0372.py
1050669722/LeetCode-Answers
c8f4d1ccaac09cda63b60d75144335347b06dc81
[ "MIT" ]
null
null
null
Python/problem0372.py
1050669722/LeetCode-Answers
c8f4d1ccaac09cda63b60d75144335347b06dc81
[ "MIT" ]
null
null
null
Python/problem0372.py
1050669722/LeetCode-Answers
c8f4d1ccaac09cda63b60d75144335347b06dc81
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Fri Jun 21 10:17:27 2019 @author: Administrator """ #class Solution: # def superPow(self, a: int, b: list) -> int: # B = 0 # b.reverse() # for k in range(len(b)): # B += b[k] * 10 ** k # # A = a**B#self.pow(a, B)# # ## while A >= 1337: ## A -= 1337 ## return A ## return A - (A//1337) * 1337 # return A % 1337 # # def pow(self, p, q): # if q == 0: # return 1 # if q == 1: # return p # if q % 2 == 0: # tmp = self.pow(p, q//2) # return tmp**2 # else: # tmp = self.pow(p, q//2) # return tmp**2 * p class Solution: def superPow(self, a: int, b: list) -> int: sum = 0 for i in b: sum = sum * 10 + i return pow(a, sum, 1337) solu = Solution() a, b = 2, [3] a, b = 2, [1,0] #a, b = 2, [1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0] a, b = 78267, [1,7,7,4,3,1,7,0,1,4,4,9,2,8,5,0,0,9,3,1,2,5,9,6,0,9,9,0,9,6,0,5,3,7,9,8,8,9,8,2,5,4,1,9,3,8,0,5,9,5,6,1,1,8,9,3,7,8,5,8,5,5,3,0,4,3,1,5,4,1,7,9,6,8,8,9,8,0,6,7,8,3,1,1,1,0,6,8,1,1,6,6,9,1,8,5,6,9,0,0,1,7,1,7,7,2,8,5,4,4,5,2,9,6,5,0,8,1,0,9,5,8,7,6,0,6,1,8,7,2,9,8,1,0,7,9,4,7,6,9,2,3,1,3,9,9,6,8,0,8,9,7,7,7,3,9,5,5,7,4,9,8,3,0,1,2,1,5,0,8,4,4,3,8,9,3,7,5,3,9,4,4,9,3,3,2,4,8,9,3,3,8,2,8,1,3,2,2,8,4,2,5,0,6,3,0,9,0,5,4,1,1,8,0,4,2,5,8,2,4,2,7,5,4,7,6,9,0,8,9,6,1,4,7,7,9,7,8,1,4,4,3,6,4,5,2,6,0,1,1,5,3,8,0,9,8,8,0,0,6,1,6,9,6,5,8,7,4,8,9,9,2,4,7,7,9,9,5,2,2,6,9,7,7,9,8,5,9,8,5,5,0,3,5,8,9,5,7,3,4,6,4,6,2,3,5,2,3,1,4,5,9,3,3,6,4,1,3,3,2,0,0,4,4,7,2,3,3,9,8,7,8,5,5,0,8,3,4,1,4,0,9,5,5,4,4,9,7,7,4,1,8,7,5,2,4,9,7,9,1,7,8,9,2,4,1,1,7,6,4,3,6,5,0,2,1,4,3,9,2,0,0,2,9,8,4,5,7,3,5,8,2,3,9,5,9,1,8,8,9,2,3,7,0,4,1,1,8,7,0,2,7,3,4,6,1,0,3,8,5,8,9,8,4,8,3,5,1,1,4,2,5,9,0,5,3,1,7,4,8,9,6,7,2,3,5,5,3,9,6,9,9,5,7,3,5,2,9,9,5,5,1,0,6,3,8,0,5,5,6,5,6,4,5,1,7,0,6,3,9,4,4,9,1,3,4,7,7,5,8,2,0,9,2,7,3,0,9,0,7,7,7,4,1,2,5,1,3,3,6,4,8,2,5,9,5,0,8,2,5,6,4,8,8,8,7,3,1,8,5,0,5,2,4,8,5,1,1,0,7,9,6,5,1,2,6,6,4,7,0,9,5,6,9,3,7,8,8,8,6,5,8,3,8,5,4,5,8,5,7,5,7,3,2,8,7,1,7,1,8,7,3,3,6,2,9,3,3,9,3,1,5,1,5,5,8,1,2,7,8,9,2,5,4,5,4,2,6,1,3,6,0,6,9,6,1,0,1,4,0,4,5,5,8,2,2,6,3,4,3,4,3,8,9,7,5,5,9,1,8,5,9,9,1,8,7,2,1,1,8,1,5,6,8,5,8,0,2,4,4,7,8,9,5,9,8,0,5,0,3,5,5,2,6,8,3,4,1,4,7,1,7,2,7,5,8,8,7,2,2,3,9,2,2,7,3,2,9,0,2,3,6,9,7,2,8,0,8,1,6,5,2,3,0,2,0,0,0,9,2,2,2,3,6,6,0,9,1,0,0,3,5,8,3,2,0,3,5,1,4,1,6,8,7,6,0,9,8,0,1,0,4,5,6,0,2,8,2,5,0,2,8,5,2,3,0,2,6,7,3,0,0,2,1,9,0,1,9,9,2,0,1,6,7,7,9,9,6,1,4,8,5,5,6,7,0,6,1,7,3,5,9,3,9,0,5,9,2,4,8,6,6,2,2,3,9,3,5,7,4,1,6,9,8,2,6,9,0,0,8,5,7,7,0,6,0,5,7,4,9,6,0,7,8,4,3,9,8,8,7,4,1,5,6,0,9,4,1,9,4,9,4,1,8,6,7,8,2,5,2,3,3,4,3,3,1,6,4,1,6,1,5,7,8,1,9,7,6,0,8,0,1,4,4,0,1,1,8,3,8,3,8,3,9,1,6,0,7,1,3,3,4,9,3,5,2,4,2,0,7,3,3,8,7,7,8,8,0,9,3,1,2,2,4,3,3,3,6,1,6,9,6,2,0,1,7,5,6,2,5,3,5,0,3,2,7,2,3,0,3,6,1,7,8,7,0,4,0,6,7,6,6,3,9,8,5,8,3,3,0,9,6,7,1,9,2,1,3,5,1,6,3,4,3,4,1,6,8,4,2,5] print(solu.superPow(a, b)) #print(solu.pow(2,10)) #for k in range(10000): # k = [int(x) for x in str(k)] # print(solu.superPow(2, k))
59.943396
2,017
0.468052
1,187
3,177
1.252738
0.046335
0.03228
0.028245
0.03228
0.141224
0.094822
0.094822
0.094822
0.094822
0.063887
0
0.401993
0.147309
3,177
53
2,018
59.943396
0.146918
0.257476
0
0
0
0
0
0
0
0
0
0
0
1
0.090909
false
0
0
0
0.272727
0.090909
0
0
1
null
0
0
0
0
0
0
0
0
0
0
1
0
0
0
1
0
1
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
3d31da819ff725d5f4bd06da90bb30b235798e63
331
py
Python
deephyper/nas/run/quick.py
Z223I/deephyper
4fd1054dc22f15197567bdd93c6e7a95a614b8e2
[ "BSD-3-Clause" ]
1
2021-09-03T18:24:31.000Z
2021-09-03T18:24:31.000Z
deephyper/nas/run/quick.py
Z223I/deephyper
4fd1054dc22f15197567bdd93c6e7a95a614b8e2
[ "BSD-3-Clause" ]
null
null
null
deephyper/nas/run/quick.py
Z223I/deephyper
4fd1054dc22f15197567bdd93c6e7a95a614b8e2
[ "BSD-3-Clause" ]
1
2021-08-31T13:47:27.000Z
2021-08-31T13:47:27.000Z
"""The :func:`deephyper.nas.run.quick.run` function is a function used to check the good behaviour of a neural architecture search algorithm. It will simply return the sum of the scalar values encoding a neural architecture in the ``config["arch_seq"]`` key. """ def run(config: dict) -> float: return sum(config['arch_seq'])
55.166667
258
0.743202
53
331
4.603774
0.660377
0.057377
0.155738
0
0
0
0
0
0
0
0
0
0.148036
331
5
259
66.2
0.865248
0.770393
0
0
0
0
0.115942
0
0
0
0
0
0
1
0.5
false
0
0
0.5
1
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
1
1
0
0
4
e9ea2851a3d40d3c917bfe4f692cb4c92e0a3b26
69
py
Python
server/events.py
nagurumalab/unicards
8fb2a1e502048bd33ce0e6b6b9f6d412cfd7e28e
[ "MIT" ]
null
null
null
server/events.py
nagurumalab/unicards
8fb2a1e502048bd33ce0e6b6b9f6d412cfd7e28e
[ "MIT" ]
null
null
null
server/events.py
nagurumalab/unicards
8fb2a1e502048bd33ce0e6b6b9f6d412cfd7e28e
[ "MIT" ]
null
null
null
from typing import Dict class Event: name: str data: Dict
8.625
23
0.652174
10
69
4.5
0.9
0
0
0
0
0
0
0
0
0
0
0
0.304348
69
7
24
9.857143
0.9375
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.25
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
1
0
0
4
e9f5d489db2b2fb8835c76b4eea2e91d490593f7
629
py
Python
pysp2/io/__init__.py
ARM-DOE/PySP2
4f464d03bc4b2c20e123853b1465c266f485e05d
[ "BSD-2-Clause" ]
null
null
null
pysp2/io/__init__.py
ARM-DOE/PySP2
4f464d03bc4b2c20e123853b1465c266f485e05d
[ "BSD-2-Clause" ]
1
2022-02-28T22:48:04.000Z
2022-02-28T22:48:04.000Z
pysp2/io/__init__.py
ARM-DOE/PySP2
4f464d03bc4b2c20e123853b1465c266f485e05d
[ "BSD-2-Clause" ]
1
2022-02-25T14:07:21.000Z
2022-02-25T14:07:21.000Z
""" pysp2.io -------- This module contains all of the procedures for reading and writing SP2 data. .. autosummary:: :toctree: generated/ read_hk_file get_hk_variable_names read_sp2 read_config write_dat write_dat_concs write_dat_concs_arm read_dat read_arm_dat read_calibration """ from .read_hk import read_hk_file, get_hk_variable_names from .read_hk import read_multi_hk_file from .read_sp2b import read_sp2 from .read_ini import read_config from .write_dat import write_dat, write_dat_concs, write_dat_concs_arm from .read_dat import read_dat, read_arm_dat, read_calibration
21.689655
76
0.771065
100
629
4.42
0.35
0.126697
0.117647
0.058824
0.520362
0.438914
0.438914
0.167421
0.167421
0
0
0.009634
0.174881
629
28
77
22.464286
0.842004
0.508744
0
0
1
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
4
e9f7dfe8cc376f29cb1758c863499690503f18fe
3,427
py
Python
tests/test_user.py
larryTheGeek/ride_my_way_v2
b5f20095308a9230dc4fc63fcacae278c8f8ed71
[ "MIT" ]
null
null
null
tests/test_user.py
larryTheGeek/ride_my_way_v2
b5f20095308a9230dc4fc63fcacae278c8f8ed71
[ "MIT" ]
5
2021-03-18T20:54:03.000Z
2022-03-11T23:27:31.000Z
tests/test_user.py
LarryKarani/ride_my_way_v2
b5f20095308a9230dc4fc63fcacae278c8f8ed71
[ "MIT" ]
null
null
null
import json from .base_test import BaseTestCase class TestRegesterUser(BaseTestCase): def test_user_register(self): response = self.client.post('api/auth/v1/register', data=json.dumps( self.registerdata), content_type='application/json') self.assertTrue(json.loads(response.data) == { "message": "user successfully registered"}) self.assertTrue(response.status_code == 201) def test_register_empty_username(self): response = self.client.post('api/auth/v1/register', data=json.dumps( self.registerdata_no_username), content_type='application/json') self.assertTrue(json.loads(response.data) == { "message": "username cannot be empty"}) self.assertTrue(response.status_code == 400) def test_user_invalid_email(self): response = self.client.post('api/auth/v1/register', data=json.dumps( self.data_with_invalid_email), content_type='application/json') self.assertTrue(json.loads(response.data) == { "message": "Not a valid email address."}) self.assertTrue(response.status_code == 400) def test_user_short_Password(self): response = self.client.post('api/auth/v1/register', data=json.dumps( self.short_password), content_type='application/json') self.assertTrue(json.loads(response.data) == { "message": "password should be atlist 8 characters long"}) self.assertTrue(response.status_code == 400) def test_wrong_designation(self): response = self.client.post('api/auth/v1/register', data=json.dumps( self.wrong_designation), content_type='application/json') self.assertTrue(json.loads(response.data) == { "message": "designation can only be driver or passenger"}) self.assertTrue(response.status_code == 400) def test_register_user_twice(self): default_user = {"username": "james", "password": "hardpassword#", "email": "james@gmail.com", "designation": "driver"} response = self.client.post( 'api/auth/v1/register', data=json.dumps(default_user), content_type='application/json') self.assertTrue(response.status_code == 400) data = json.loads(response.data) self.assertTrue( data == {"message": "username james already exist"}) def test_register_email_twice(self): default_user = {"username": "pinto", "password": "hardpassword#", "email": "james@gmail.com", "designation": "driver"} new_user = { "username": "octo", "password": "hardpassword#", "email": "james@gmail.com", "designation": "driver"} self.client.post( 'api/auth/v1/register', data=json.dumps(default_user), content_type='application/json') response = self.client.post( 'api/auth/v1/register', data=json.dumps(new_user), content_type='application/json') self.assertTrue(response.status_code == 400) data = json.loads(response.data) print(json.loads(response.data)) self.assertTrue( data == {"message": "james@gmail.com is already registered"})
46.945205
99
0.605486
364
3,427
5.568681
0.197802
0.096695
0.055254
0.067094
0.75777
0.714356
0.714356
0.714356
0.556487
0.5111
0
0.011924
0.26583
3,427
72
100
47.597222
0.79372
0
0
0.532258
0
0
0.227021
0
0
0
0
0
0.225806
1
0.112903
false
0.112903
0.032258
0
0.16129
0.016129
0
0
0
null
0
0
0
0
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
1
0
0
0
0
0
4
1805a52e43d99394c2ee8c0ea4d57c6b59da310b
51
py
Python
v3.0_bundle_v7.2.4/code.py
CedarGroveStudios/Scale
c3ac07319f08790a8f6fe3b904f3adc93c2c94fd
[ "MIT-0" ]
1
2021-12-08T12:37:18.000Z
2021-12-08T12:37:18.000Z
v3.0_bundle_v7.2.4/code.py
CedarGroveStudios/Scale
c3ac07319f08790a8f6fe3b904f3adc93c2c94fd
[ "MIT-0" ]
null
null
null
v3.0_bundle_v7.2.4/code.py
CedarGroveStudios/Scale
c3ac07319f08790a8f6fe3b904f3adc93c2c94fd
[ "MIT-0" ]
null
null
null
import scale_code import touch_calibrator_built_in
17
32
0.921569
8
51
5.375
0.875
0
0
0
0
0
0
0
0
0
0
0
0.078431
51
2
33
25.5
0.914894
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
4
180fdecfa7e0b02c0e705edc797bf948bce05e22
51
py
Python
app/utils/__init__.py
FireFragment/memegen
f0a1b3ba465b8cd68a873951ab50eeaa91d57a35
[ "MIT" ]
1
2022-02-11T21:28:11.000Z
2022-02-11T21:28:11.000Z
app/utils/__init__.py
FireFragment/memegen
f0a1b3ba465b8cd68a873951ab50eeaa91d57a35
[ "MIT" ]
null
null
null
app/utils/__init__.py
FireFragment/memegen
f0a1b3ba465b8cd68a873951ab50eeaa91d57a35
[ "MIT" ]
null
null
null
from . import html, http, images, meta, text, urls
25.5
50
0.705882
8
51
4.5
1
0
0
0
0
0
0
0
0
0
0
0
0.176471
51
1
51
51
0.857143
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
4
1822f56cd609bf081743ac8feb079ba477e7282e
58
py
Python
main.py
duanyuluo/HelloWorld
c2195a05ce231d33c7f69ce32bda2b5a175f3a87
[ "Apache-2.0" ]
null
null
null
main.py
duanyuluo/HelloWorld
c2195a05ce231d33c7f69ce32bda2b5a175f3a87
[ "Apache-2.0" ]
null
null
null
main.py
duanyuluo/HelloWorld
c2195a05ce231d33c7f69ce32bda2b5a175f3a87
[ "Apache-2.0" ]
null
null
null
# encode = utf-8 print("Hello world.") print("Byebye...")
14.5
21
0.62069
8
58
4.5
0.875
0
0
0
0
0
0
0
0
0
0
0.019608
0.12069
58
4
22
14.5
0.686275
0.241379
0
0
0
0
0.488372
0
0
0
0
0
0
1
0
true
0
0
0
0
1
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
1
0
4
1824436d175a2b1f36f6890243f18bec0a2a5073
119
py
Python
src/__main__.py
ajk-hub/dtk
e300029196eda8c8b2cca3e854802306138f083f
[ "MIT" ]
1
2021-09-23T11:22:45.000Z
2021-09-23T11:22:45.000Z
src/__main__.py
ajk-hub/dtk
e300029196eda8c8b2cca3e854802306138f083f
[ "MIT" ]
null
null
null
src/__main__.py
ajk-hub/dtk
e300029196eda8c8b2cca3e854802306138f083f
[ "MIT" ]
null
null
null
from src.entrypoint import load_arg_parser def main(): load_arg_parser() if __name__ == '__main__': main()
11.9
42
0.689076
16
119
4.375
0.6875
0.2
0.371429
0
0
0
0
0
0
0
0
0
0.201681
119
9
43
13.222222
0.736842
0
0
0
0
0
0.067227
0
0
0
0
0
0
1
0.2
true
0
0.2
0
0.4
0
1
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
4
1841be61e6815f26f0e360e94a61c129d9684e41
2,079
py
Python
terrascript/data/vcd.py
hugovk/python-terrascript
08fe185904a70246822f5cfbdc9e64e9769ec494
[ "BSD-2-Clause" ]
4
2022-02-07T21:08:14.000Z
2022-03-03T04:41:28.000Z
terrascript/data/vcd.py
hugovk/python-terrascript
08fe185904a70246822f5cfbdc9e64e9769ec494
[ "BSD-2-Clause" ]
null
null
null
terrascript/data/vcd.py
hugovk/python-terrascript
08fe185904a70246822f5cfbdc9e64e9769ec494
[ "BSD-2-Clause" ]
2
2022-02-06T01:49:42.000Z
2022-02-08T14:15:00.000Z
# terrascript/data/vcd.py import terrascript class vcd_org(terrascript.Data): pass class vcd_org_vdc(terrascript.Data): pass class vcd_catalog(terrascript.Data): pass class vcd_catalog_media(terrascript.Data): pass class vcd_catalog_item(terrascript.Data): pass class vcd_edgegateway(terrascript.Data): pass class vcd_external_network(terrascript.Data): pass class vcd_independent_disk(terrascript.Data): pass class vcd_network_routed(terrascript.Data): pass class vcd_network_direct(terrascript.Data): pass class vcd_network_isolated(terrascript.Data): pass class vcd_vapp(terrascript.Data): pass class vcd_vapp_vm(terrascript.Data): pass class vcd_lb_service_monitor(terrascript.Data): pass class vcd_lb_server_pool(terrascript.Data): pass class vcd_lb_app_profile(terrascript.Data): pass class vcd_lb_app_rule(terrascript.Data): pass class vcd_lb_virtual_server(terrascript.Data): pass class vcd_nsxv_dnat(terrascript.Data): pass class vcd_nsxv_snat(terrascript.Data): pass class vcd_nsxv_firewall_rule(terrascript.Data): pass class vcd_nsxv_dhcp_relay(terrascript.Data): pass class vcd_nsxv_ip_set(terrascript.Data): pass class vcd_vapp_network(terrascript.Data): pass class vcd_vapp_org_network(terrascript.Data): pass class vcd_vm_affinity_rule(terrascript.Data): pass __all__ = [ "vcd_org", "vcd_org_vdc", "vcd_catalog", "vcd_catalog_media", "vcd_catalog_item", "vcd_edgegateway", "vcd_external_network", "vcd_independent_disk", "vcd_network_routed", "vcd_network_direct", "vcd_network_isolated", "vcd_vapp", "vcd_vapp_vm", "vcd_lb_service_monitor", "vcd_lb_server_pool", "vcd_lb_app_profile", "vcd_lb_app_rule", "vcd_lb_virtual_server", "vcd_nsxv_dnat", "vcd_nsxv_snat", "vcd_nsxv_firewall_rule", "vcd_nsxv_dhcp_relay", "vcd_nsxv_ip_set", "vcd_vapp_network", "vcd_vapp_org_network", "vcd_vm_affinity_rule", ]
15.175182
47
0.729197
279
2,079
5.003584
0.146953
0.290115
0.353868
0.429799
0.571633
0.51361
0.045845
0
0
0
0
0
0.179894
2,079
136
48
15.286765
0.818768
0.011063
0
0.320988
0
0
0.206426
0.031646
0
0
0
0
0
1
0
false
0.320988
0.012346
0
0.333333
0
0
0
0
null
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
1
0
0
0
0
0
4
187c0092c6614d7246c93132c7028797161e75f6
164
py
Python
backend/codexpose/interview/apps.py
naveenyenugula/codeXpose
e82b0573b5675c64939af31f1d14bf60f4067f1d
[ "Apache-2.0" ]
5
2018-01-12T08:10:47.000Z
2018-03-30T09:14:13.000Z
backend/codexpose/interview/apps.py
naveenyenugula/codeXpose
e82b0573b5675c64939af31f1d14bf60f4067f1d
[ "Apache-2.0" ]
44
2018-01-20T20:43:06.000Z
2018-04-05T13:09:03.000Z
backend/codexpose/interview/apps.py
naveenyenugula/codeXpose
e82b0573b5675c64939af31f1d14bf60f4067f1d
[ "Apache-2.0" ]
9
2017-12-21T11:51:59.000Z
2018-05-08T15:39:49.000Z
"""app.py to define apps for codexpose.""" from django.apps import AppConfig class InterviewConfig(AppConfig): """App config Class.""" name = 'interview'
20.5
42
0.695122
20
164
5.7
0.8
0
0
0
0
0
0
0
0
0
0
0
0.170732
164
7
43
23.428571
0.838235
0.329268
0
0
0
0
0.090909
0
0
0
0
0
0
1
0
false
0
0.333333
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
4
43e4a7b6057727de1e8477e98a2f5841e8963ad2
9,642
py
Python
tinytorch/fast/conv.py
aspfohl/tinytorch
99ac1847b798f755d12876667ec7c3a6c7149857
[ "MIT" ]
null
null
null
tinytorch/fast/conv.py
aspfohl/tinytorch
99ac1847b798f755d12876667ec7c3a6c7149857
[ "MIT" ]
null
null
null
tinytorch/fast/conv.py
aspfohl/tinytorch
99ac1847b798f755d12876667ec7c3a6c7149857
[ "MIT" ]
null
null
null
import numpy as np from numba import njit, prange from tinytorch.tensor.data import MAX_DIMS, broadcast_index, index_to_position, to_index from tinytorch.tensor.functions import Function # This code will JIT compile fast versions your tensor_data functions. # If you get an error, read the docs for NUMBA as to what is allowed # in these functions. j_to_index = njit(inline="always")(to_index) j_index_to_position = njit(inline="always")(index_to_position) j_broadcast_index = njit(inline="always")(broadcast_index) @njit(parallel=True) def tensor_conv1d( out, out_shape, out_strides, out_size, input, input_shape, input_strides, weight, weight_shape, weight_strides, reverse, ): """ 1D Convolution implementation. Given input tensor of `batch, in_channels, width` and weight tensor `out_channels, in_channels, k_width` Computes padded output of `batch, out_channels, width` `reverse` decides if weight is anchored left (False) or right. (See diagrams) Args: out (array): storage for `out` tensor. out_shape (array): shape for `out` tensor. out_strides (array): strides for `out` tensor. out_size (int): size of the `out` tensor. input (array): storage for `input` tensor. input_shape (array): shape for `input` tensor. input_strides (array): strides for `input` tensor. weight (array): storage for `input` tensor. weight_shape (array): shape for `input` tensor. weight_strides (array): strides for `input` tensor. reverse (bool): anchor weight at left or right """ batch_, out_channels, _ = out_shape batch, in_channels, width = input_shape out_channels_, in_channels_, kw = weight_shape assert ( batch == batch_ and in_channels == in_channels_ and out_channels == out_channels_ ) for o in prange(out_size): out_index = np.empty(MAX_DIMS, np.int32) j_to_index(o, out_shape, out_index) o0, o1, o2 = out_index[0], out_index[1], out_index[2] i_pos = j_index_to_position([o0, 0, o2], input_strides) w_pos = j_index_to_position([o1, 0, kw - 1 if reverse else 0], weight_strides) # iterate over in channels (from input) temp = 0 for _ in range(in_channels): temp_i_pos = i_pos temp_w_pos = w_pos # iterate over slider size (from weight) for w in range(kw): if not 0 <= o2 + ((w - kw + 1) if reverse else w) < width: continue temp += input[temp_i_pos] * weight[temp_w_pos] temp_i_pos += (1 if not reverse else -1) * input_strides[2] temp_w_pos += (1 if not reverse else -1) * weight_strides[2] i_pos += input_strides[1] w_pos += weight_strides[1] # save to output out[j_index_to_position(out_index, out_strides)] = temp class Conv1dFun(Function): @staticmethod def forward(ctx, input, weight): """ Compute a 1D Convolution Args: ctx : Context input (:class:`Tensor`) : batch x in_channel x h x w weight (:class:`Tensor`) : out_channel x in_channel x kh x kw Returns: (:class:`Tensor`) : batch x out_channel x h x w """ ctx.save_for_backward(input, weight) batch, in_channels, w = input.shape out_channels, in_channels2, kw = weight.shape assert in_channels == in_channels2 # Run convolution output = input.zeros((batch, out_channels, w)) tensor_conv1d( *output.tuple(), output.size, *input.tuple(), *weight.tuple(), False ) return output @staticmethod def backward(ctx, grad_output): input, weight = ctx.saved_values batch, in_channels, w = input.shape out_channels, in_channels, kw = weight.shape grad_weight = grad_output.zeros((in_channels, out_channels, kw)) new_input = input.permute(1, 0, 2) new_grad_output = grad_output.permute(1, 0, 2) tensor_conv1d( *grad_weight.tuple(), grad_weight.size, *new_input.tuple(), *new_grad_output.tuple(), False, ) grad_weight = grad_weight.permute(1, 0, 2) grad_input = input.zeros((batch, in_channels, w)) new_weight = weight.permute(1, 0, 2) tensor_conv1d( *grad_input.tuple(), grad_input.size, *grad_output.tuple(), *new_weight.tuple(), True, ) return grad_input, grad_weight conv1d = Conv1dFun.apply @njit(parallel=True, fastmath=True) def tensor_conv2d( out, out_shape, out_strides, out_size, input, input_shape, input_strides, weight, weight_shape, weight_strides, reverse, ): """ 2D Convolution implementation. Given input tensor of `batch, in_channels, height, width` and weight tensor `out_channels, in_channels, k_height, k_width` Computes padded output of `batch, out_channels, height, width` `Reverse` decides if weight is anchored top-left (False) or bottom-right. (See diagrams) Args: out (array): storage for `out` tensor. out_shape (array): shape for `out` tensor. out_strides (array): strides for `out` tensor. out_size (int): size of the `out` tensor. input (array): storage for `input` tensor. input_shape (array): shape for `input` tensor. input_strides (array): strides for `input` tensor. weight (array): storage for `input` tensor. weight_shape (array): shape for `input` tensor. weight_strides (array): strides for `input` tensor. reverse (bool): anchor weight at top-left or bottom-right """ batch_, out_channels, _, _ = out_shape batch, in_channels, height, width = input_shape out_channels_, in_channels_, kh, kw = weight_shape assert ( batch == batch_ and in_channels == in_channels_ and out_channels == out_channels_ ) for o in prange(out_size): out_index = np.empty(MAX_DIMS, np.int32) j_to_index(o, out_shape, out_index) o0, o1, o2, o3 = out_index[0], out_index[1], out_index[2], out_index[3] i_pos = j_index_to_position([o0, 0, o2, o3], input_strides) w_pos = j_index_to_position( [o1, 0, kh - 1 if reverse else 0, kw - 1 if reverse else 0], weight_strides, ) # iterate over in channels (from input) multiplier = 1 if not reverse else -1 temp = 0 for _ in range(in_channels): temp_i_pos = i_pos temp_w_pos = w_pos # iterate over slider size (from weight) for h in range(kh): temp2_i_pos = temp_i_pos temp2_w_pos = temp_w_pos for w in range(kw): # 2nd dimension if ( not reverse and 0 <= o2 + h < height and 0 <= o3 + w < width ) or ( reverse and 0 <= o2 - kh + h + 1 < height and 0 <= o3 - kw + w + 1 < width ): temp += input[temp2_i_pos] * weight[temp2_w_pos] temp2_i_pos += multiplier * input_strides[3] temp2_w_pos += multiplier * weight_strides[3] temp_i_pos += multiplier * input_strides[2] temp_w_pos += multiplier * weight_strides[2] i_pos += input_strides[1] w_pos += weight_strides[1] out[j_index_to_position(out_index, out_strides)] = temp class Conv2dFun(Function): @staticmethod def forward(ctx, input, weight): """ Compute a 2D Convolution Args: ctx : Context input (:class:`Tensor`) : batch x in_channel x h x w weight (:class:`Tensor`) : out_channel x in_channel x kh x kw Returns: (:class:`Tensor`) : batch x out_channel x h x w """ ctx.save_for_backward(input, weight) batch, in_channels, h, w = input.shape out_channels, in_channels2, kh, kw = weight.shape assert in_channels == in_channels2 output = input.zeros((batch, out_channels, h, w)) tensor_conv2d( *output.tuple(), output.size, *input.tuple(), *weight.tuple(), False ) return output @staticmethod def backward(ctx, grad_output): input, weight = ctx.saved_values batch, in_channels, h, w = input.shape out_channels, in_channels, kh, kw = weight.shape grad_weight = grad_output.zeros((in_channels, out_channels, kh, kw)) new_input = input.permute(1, 0, 2, 3) new_grad_output = grad_output.permute(1, 0, 2, 3) tensor_conv2d( *grad_weight.tuple(), grad_weight.size, *new_input.tuple(), *new_grad_output.tuple(), False, ) grad_weight = grad_weight.permute(1, 0, 2, 3) grad_input = input.zeros((batch, in_channels, h, w)) new_weight = weight.permute(1, 0, 2, 3) tensor_conv2d( *grad_input.tuple(), grad_input.size, *grad_output.tuple(), *new_weight.tuple(), True, ) return grad_input, grad_weight conv2d = Conv2dFun.apply
30.805112
88
0.587637
1,247
9,642
4.309543
0.115477
0.052103
0.031262
0.014886
0.827689
0.800521
0.777819
0.733904
0.695199
0.558243
0
0.018696
0.317673
9,642
312
89
30.903846
0.798146
0.264675
0
0.583333
0
0
0.002667
0
0
0
0
0
0.022222
1
0.033333
false
0
0.022222
0
0.088889
0
0
0
0
null
0
0
0
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
43e7b2e1a8afdac49bbf5e85f56b11a546e25035
431
py
Python
win32/install_win.py
ciena-blueplanet/git-fat
b6deb1f86b6f62e88e6bb6ea7656b72ce4ccc511
[ "BSD-2-Clause" ]
20
2016-01-31T01:49:44.000Z
2021-11-12T11:22:26.000Z
win32/install_win.py
mcanthony/git-fat
b6deb1f86b6f62e88e6bb6ea7656b72ce4ccc511
[ "BSD-2-Clause" ]
7
2016-08-04T14:20:46.000Z
2022-03-30T22:19:54.000Z
win32/install_win.py
mcanthony/git-fat
b6deb1f86b6f62e88e6bb6ea7656b72ce4ccc511
[ "BSD-2-Clause" ]
7
2016-03-29T09:20:33.000Z
2020-02-13T09:57:07.000Z
""" Install the latest Windows binary wheel package from PyPI """ def install_gitfat_win(): """ Install the latest Windows binary wheel package from PyPI """ # TODO: Parse all available packages through PyPI Simple: # https://pypi.python.org/simple/git-fat/ raise NotImplementedError("TODO: Installing pypi/git-fat on Windows") def main(): install_gitfat_win() if __name__ == "__main__": main()
25.352941
73
0.693735
55
431
5.218182
0.563636
0.069686
0.111498
0.160279
0.341463
0.341463
0.341463
0.341463
0.341463
0
0
0
0.197216
431
16
74
26.9375
0.82948
0.510441
0
0
0
0
0.243655
0
0
0
0
0.0625
0
1
0.333333
true
0
0
0
0.333333
0
0
0
0
null
0
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
1
0
0
1
1
0
0
0
0
0
0
4
a10f1ff34d5887ed779e23c7dd7d828d13e605d3
136
py
Python
helloworld/apps.py
B-Shreyas/djangoContainer
a3932daa3fb0d12566c90b038a8c97a5c7cd5254
[ "Apache-2.0" ]
null
null
null
helloworld/apps.py
B-Shreyas/djangoContainer
a3932daa3fb0d12566c90b038a8c97a5c7cd5254
[ "Apache-2.0" ]
2
2020-06-06T01:10:08.000Z
2021-06-10T22:51:24.000Z
helloworld/apps.py
B-Shreyas/djangoContainer
a3932daa3fb0d12566c90b038a8c97a5c7cd5254
[ "Apache-2.0" ]
null
null
null
from __future__ import unicode_literals from django.apps import AppConfig class HelloworldConfig(AppConfig): name = 'helloworld'
17
39
0.801471
15
136
6.933333
0.8
0
0
0
0
0
0
0
0
0
0
0
0.147059
136
7
40
19.428571
0.896552
0
0
0
0
0
0.073529
0
0
0
0
0
0
1
0
false
0
0.5
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
4
a1130518e85d78395c541d49b292b8f002d9b7a1
142
py
Python
semana-09/VPL-6/exceptions/elevadorJahNoUltimoAndarException.py
larissajusten/ufsc-object-oriented-programming
839e6abcc20580ea1a47479232c3ed3cb0153e4b
[ "MIT" ]
6
2021-11-29T05:43:19.000Z
2022-03-15T21:54:54.000Z
semana-09/VPL-6/exceptions/elevadorJahNoUltimoAndarException.py
larissajusten/ufsc-object-oriented-programming
839e6abcc20580ea1a47479232c3ed3cb0153e4b
[ "MIT" ]
3
2021-11-21T03:44:03.000Z
2021-11-21T03:44:05.000Z
semana-09/VPL-6/exceptions/elevadorJahNoUltimoAndarException.py
larissajusten/ufsc-object-oriented-programming
839e6abcc20580ea1a47479232c3ed3cb0153e4b
[ "MIT" ]
null
null
null
class ElevadorJahNoUltimoAndarException(Exception): def __init__(self): super().__init__("Elevador se encontra no último andar!")
35.5
65
0.746479
14
142
7
0.928571
0
0
0
0
0
0
0
0
0
0
0
0.15493
142
3
66
47.333333
0.816667
0
0
0
0
0
0.260563
0
0
0
0
0
0
1
0.333333
false
0
0
0
0.666667
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
0
1
0
0
4
a14694c7f62d06d59fd68aa86ecfcc2bcedb29cc
6,695
py
Python
src/utils/utility.py
dashayushman/AirScript
4a972dfa480cd96ccb5bd8e606c8c8a309b66edb
[ "MIT" ]
9
2017-07-18T21:41:04.000Z
2021-07-13T10:17:16.000Z
src/utils/utility.py
qwzhong1988/air-script-seq
4a972dfa480cd96ccb5bd8e606c8c8a309b66edb
[ "MIT" ]
null
null
null
src/utils/utility.py
qwzhong1988/air-script-seq
4a972dfa480cd96ccb5bd8e606c8c8a309b66edb
[ "MIT" ]
2
2017-09-25T12:54:43.000Z
2020-12-05T17:20:30.000Z
from tabulate import tabulate import numpy as np import os import markdown2 import csv # method to pad a vector with and normalize to a fixed length def padVector(vec, front, back, emg=False): if emg: return np.lib.pad(vec, (int(front), int(back)), 'constant', constant_values=(0, 0)) else: return np.lib.pad(vec, (int(front), int(back)), 'constant', constant_values=(vec[0], vec[-1])) def saveMatrixToCsvFile(filepath, mat): with open(filepath, "w", newline='') as f: writer = csv.writer(f) writer.writerows(mat) def createDir(dirPath): if not os.path.exists(dirPath): os.makedirs(dirPath) def appendClfReportToListSvm(fileContent, clf_rpt, cm, acc_scr, best_params, itr, n_train, n_test, labels): fileContent.append('### Best Params ' + str(best_params)) fileContent.append('\n') fileContent.append('### For nth fold where n = ' + str(itr)) fileContent.append('\n') fileContent.append('### Number of training instances = ' + str(n_train)) fileContent.append('\n') fileContent.append('### Number of validation instances = ' + str(n_test)) fileContent.append('\n') fileContent.append('### Accuracy Score : ' + str(acc_scr)) fileContent.append('\n\n') fileContent.append('## Classification Report') fileContent.append('\n\n') fileContent.append(clf_rpt) fileContent.append('\n') fileContent.append('## Confusion Matrix') fileContent.append('\n\n') # fileContent.append(tabulate(cm)) # print(joinMatrix(cm, '\n','\t')) fileContent.append( tabulate(np.insert(cm, 0, labels, axis=1), labels, tablefmt="html")) fileContent.append('\n\n') fileContent.append( '___________________________________________________________________________________') fileContent.append('\n\n') return fileContent def appendClfReportToListNB(fileContent, clf_rpt, cm, acc_scr, algo, itr, n_train, n_test, labels): fileContent.append('### Type ' + str(algo)) fileContent.append('\n') fileContent.append('### For nth fold where n = ' + str(itr)) fileContent.append('\n') fileContent.append('### Number of training instances = ' + str(n_train)) fileContent.append('\n') fileContent.append('### Number of validation instances = ' + str(n_test)) fileContent.append('\n') fileContent.append('### Accuracy Score : ' + str(acc_scr)) fileContent.append('\n\n') fileContent.append('## Classification Report') fileContent.append('\n\n') fileContent.append(clf_rpt) fileContent.append('\n') fileContent.append('## Confusion Matrix') fileContent.append('\n\n') # fileContent.append(tabulate(cm)) # print(joinMatrix(cm, '\n','\t')) fileContent.append( tabulate(np.insert(cm, 0, labels, axis=1), labels, tablefmt="html")) fileContent.append('\n\n') fileContent.append( '___________________________________________________________________________________') fileContent.append('\n\n') return fileContent def appendClfReportToListKnn(fileContent, clf_rpt, cm, acc_scr, n_neigh, itr, n_train, n_test, labels): fileContent.append('### Number of Neighbours ' + str(n_neigh)) fileContent.append('\n') fileContent.append('### For nth fold where n = ' + str(itr)) fileContent.append('\n') fileContent.append('### Number of training instances = ' + str(n_train)) fileContent.append('\n') fileContent.append('### Number of validation instances = ' + str(n_test)) fileContent.append('\n') fileContent.append('### Accuracy Score : ' + str(acc_scr)) fileContent.append('\n\n') fileContent.append('## Classification Report') fileContent.append('\n\n') fileContent.append(clf_rpt) fileContent.append('\n') fileContent.append('## Confusion Matrix') fileContent.append('\n\n') # fileContent.append(tabulate(cm)) # print(joinMatrix(cm, '\n','\t')) fileContent.append( tabulate(np.insert(cm, 0, labels, axis=1), labels, tablefmt="html")) fileContent.append('\n\n') fileContent.append( '___________________________________________________________________________________') fileContent.append('\n\n') return fileContent def appendClfReportToListHMM(fileContent, clf_rpt, cm, acc_scr, n_states, itr, n_train, n_test, labels): fileContent.append('### Number of States ' + str(n_states)) fileContent.append('\n') fileContent.append('### For nth fold where n = ' + str(itr)) fileContent.append('\n') fileContent.append('### Number of training instances = ' + str(n_train)) fileContent.append('\n') fileContent.append('### Number of validation instances = ' + str(n_test)) fileContent.append('\n') fileContent.append('### Accuracy Score : ' + str(acc_scr)) fileContent.append('\n\n') fileContent.append('## Classification Report') fileContent.append('\n\n') fileContent.append(clf_rpt) fileContent.append('\n') fileContent.append('## Confusion Matrix') fileContent.append('\n\n') # fileContent.append(tabulate(cm)) # print(joinMatrix(cm, '\n','\t')) fileContent.append( tabulate(np.insert(cm, 0, labels, axis=1), labels, tablefmt="html")) fileContent.append('\n\n') fileContent.append( '___________________________________________________________________________________') fileContent.append('\n\n') return fileContent def mrkdwn2html(mrkStr): return markdown2.markdown(mrkStr) def getStrFrmList(lst, separator): return separator.join(lst) def joinMatrix(matrix, r_separator, c_separator): str_rows = [] for row in matrix: str_rows.append(c_separator.join([str(v) for v in row])) return r_separator.join(str_rows) def appendHeaderToFcListHMM(fileContent, accuracies, header): fileContent_h = [] fileContent_h.append('# For ' + header) fileContent_h.append('\n\n') fileContent_h.append('## Accuracies for all the folds are as follows\n') fileContent_h.append(str(accuracies) + '\n\n') fileContent_h.append('## Average Accuracy\n') fileContent_h.append(str(np.mean(accuracies)) + '\n\n') fileContent_h.append( '_______________________________________________________________________________________________________') fileContent_h.append('\n\n') return fileContent_h + fileContent def writeToFile(filepath, filecontent): with open(filepath, "wt") as out_file: out_file.write(filecontent)
36.98895
114
0.665571
739
6,695
5.361299
0.169148
0.360424
0.181726
0.146391
0.751388
0.721353
0.693589
0.680464
0.661787
0.661787
0
0.002759
0.187901
6,695
180
115
37.194444
0.725952
0.048245
0
0.664336
0
0
0.221943
0.068375
0
0
0
0
0
1
0.083916
false
0
0.034965
0.013986
0.188811
0
0
0
0
null
1
1
0
0
1
0
0
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
a14d32bacdc4a26e8ba463e62bfe520988fa22c5
134
py
Python
cash_viz/style.py
PhiladelphiaController/cash_viz
2124d1d7859fc20e2a7f79754697fd5a41b2ee47
[ "MIT" ]
null
null
null
cash_viz/style.py
PhiladelphiaController/cash_viz
2124d1d7859fc20e2a7f79754697fd5a41b2ee47
[ "MIT" ]
null
null
null
cash_viz/style.py
PhiladelphiaController/cash_viz
2124d1d7859fc20e2a7f79754697fd5a41b2ee47
[ "MIT" ]
null
null
null
from phila_style.matplotlib import get_theme from phila_style import * palette = get_digital_standards() default_style = get_theme()
22.333333
44
0.828358
19
134
5.473684
0.578947
0.173077
0.269231
0
0
0
0
0
0
0
0
0
0.11194
134
5
45
26.8
0.87395
0
0
0
0
0
0
0
0
0
0
0
0
1
0
false
0
0.5
0
0.5
0
1
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
0
0
0
4
a182c1379519fad7ead456e50468497c39677c1c
261
py
Python
DQM/RPCMonitorClient/python/RPCDCSSummary_cfi.py
ckamtsikis/cmssw
ea19fe642bb7537cbf58451dcf73aa5fd1b66250
[ "Apache-2.0" ]
852
2015-01-11T21:03:51.000Z
2022-03-25T21:14:00.000Z
DQM/RPCMonitorClient/python/RPCDCSSummary_cfi.py
ckamtsikis/cmssw
ea19fe642bb7537cbf58451dcf73aa5fd1b66250
[ "Apache-2.0" ]
30,371
2015-01-02T00:14:40.000Z
2022-03-31T23:26:05.000Z
DQM/RPCMonitorClient/python/RPCDCSSummary_cfi.py
ckamtsikis/cmssw
ea19fe642bb7537cbf58451dcf73aa5fd1b66250
[ "Apache-2.0" ]
3,240
2015-01-02T05:53:18.000Z
2022-03-31T17:24:21.000Z
import FWCore.ParameterSet.Config as cms from DQMServices.Core.DQMEDHarvester import DQMEDHarvester rpcDCSSummary = DQMEDHarvester("RPCDCSSummary", NumberOfEndcapDisks = cms.untracked.int32(4), )
37.285714
77
0.632184
20
261
8.25
0.75
0.327273
0
0
0
0
0
0
0
0
0
0.016575
0.306513
261
6
78
43.5
0.895028
0
0
0
0
0
0.049808
0
0
0
0
0
0
1
0
false
0
0.4
0
0.4
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
0
0
0
4
a189616f1bd51fceb32759af871684bebddb4834
216
py
Python
giiit/logic/__init__.py
maizy/giiit
31d2cbbf4969e2330671382475e3423dd992bde1
[ "MIT" ]
2
2020-12-19T02:04:15.000Z
2021-03-29T19:48:53.000Z
giiit/logic/__init__.py
maizy/giiit
31d2cbbf4969e2330671382475e3423dd992bde1
[ "MIT" ]
null
null
null
giiit/logic/__init__.py
maizy/giiit
31d2cbbf4969e2330671382475e3423dd992bde1
[ "MIT" ]
null
null
null
# _*_ coding: utf-8 _*_ # Copyright (c) Nikita Kovaliov, maizy.ru, 2013 # See LICENSE.txt for details. from __future__ import unicode_literals, absolute_import from giiit import Error class Error(Error): pass
19.636364
56
0.75
30
216
5.066667
0.833333
0
0
0
0
0
0
0
0
0
0
0.027778
0.166667
216
10
57
21.6
0.816667
0.444444
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0.25
0.5
0
0.75
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
1
1
0
1
0
0
4
a1b46673a176331317a8732b2c053794af7af125
113
py
Python
my_lambdata/__init__.py
tatianaportsova/Lambdata_12
4cab1dc4f65d479b8f2919155c4bb6b58243d8db
[ "MIT" ]
null
null
null
my_lambdata/__init__.py
tatianaportsova/Lambdata_12
4cab1dc4f65d479b8f2919155c4bb6b58243d8db
[ "MIT" ]
null
null
null
my_lambdata/__init__.py
tatianaportsova/Lambdata_12
4cab1dc4f65d479b8f2919155c4bb6b58243d8db
[ "MIT" ]
null
null
null
# __init__.py # thissurrounding folder -treat it like a modul # so we can import thing from the files within
22.6
48
0.743363
18
113
4.444444
1
0
0
0
0
0
0
0
0
0
0
0
0.212389
113
4
49
28.25
0.898876
0.902655
0
null
0
null
0
0
null
0
0
0
null
1
null
true
0
0
null
null
null
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
1
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
4
a1ee75517c71e980435dc634b43186120c33b6e7
204
py
Python
plugins/hanlp_demo/hanlp_demo/block_windows.py
antfootAlex/HanLP
e8044b27ae1de54b9070db08549853d3ca8271e2
[ "Apache-2.0" ]
27,208
2015-03-27T10:25:45.000Z
2022-03-31T13:26:32.000Z
plugins/hanlp_demo/hanlp_demo/block_windows.py
hushaoyun/HanLP
967b52404c9d0adbc0cff2699690c127ecfca36e
[ "Apache-2.0" ]
1,674
2015-03-30T06:36:44.000Z
2022-03-16T01:52:56.000Z
plugins/hanlp_demo/hanlp_demo/block_windows.py
hushaoyun/HanLP
967b52404c9d0adbc0cff2699690c127ecfca36e
[ "Apache-2.0" ]
7,710
2015-03-27T08:07:57.000Z
2022-03-31T14:57:23.000Z
# -*- coding:utf-8 -*- # Author: hankcs # Date: 2021-07-28 21:38 from hanlp.utils.io_util import windows assert not windows(), 'Windows is not supported for this script. Please run it on Linux systems.'
29.142857
97
0.720588
34
204
4.294118
0.911765
0
0
0
0
0
0
0
0
0
0
0.075581
0.156863
204
6
98
34
0.773256
0.284314
0
0
0
0
0.514085
0
0
0
0
0
0.5
1
0
true
0
0.5
0
0.5
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
1
0
0
1
0
1
0
0
0
0
4
b802b91ca8ca83b999ab8bb8c0d48ec2f2cec5f2
25
py
Python
data/studio21_generated/introductory/2678/starter_code.py
vijaykumawat256/Prompt-Summarization
614f5911e2acd2933440d909de2b4f86653dc214
[ "Apache-2.0" ]
null
null
null
data/studio21_generated/introductory/2678/starter_code.py
vijaykumawat256/Prompt-Summarization
614f5911e2acd2933440d909de2b4f86653dc214
[ "Apache-2.0" ]
null
null
null
data/studio21_generated/introductory/2678/starter_code.py
vijaykumawat256/Prompt-Summarization
614f5911e2acd2933440d909de2b4f86653dc214
[ "Apache-2.0" ]
null
null
null
def no_order(equation):
12.5
23
0.76
4
25
4.5
1
0
0
0
0
0
0
0
0
0
0
0
0.12
25
2
24
12.5
0.818182
0
0
0
0
0
0
0
0
0
0
0
0
0
null
null
0
0
null
null
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
1
0
0
0
0
0
0
0
0
4
b81cdf690e7e22991d50dd8e450591de9c22ae31
2,755
py
Python
src/jk_svg/_AttrMixinX1Y1X2Y2.py
jkpubsrc/python-module-jk-svg
7cd9d874e4e01851ccc5a14599408743baaf77f6
[ "Apache-1.1" ]
null
null
null
src/jk_svg/_AttrMixinX1Y1X2Y2.py
jkpubsrc/python-module-jk-svg
7cd9d874e4e01851ccc5a14599408743baaf77f6
[ "Apache-1.1" ]
null
null
null
src/jk_svg/_AttrMixinX1Y1X2Y2.py
jkpubsrc/python-module-jk-svg
7cd9d874e4e01851ccc5a14599408743baaf77f6
[ "Apache-1.1" ]
null
null
null
import typing import jk_typing import jk_hwriter class _AttrMixinX1Y1X2Y2: ################################################################################################################################ ## Constructor ################################################################################################################################ def _init_AttrMixinX1Y1X2Y2(self): self._moveCallback = self.__move # ################################################################################################################################ ## Public Properties ################################################################################################################################ @property def _xy1(self) -> tuple: return self._attributes.get("x1", 0), self._attributes.get("y1", 0) # @_xy1.setter def _xy1(self, value:tuple): assert isinstance(value, (list,tuple)) assert len(value) >= 2 assert isinstance(value[0], (int,float)) assert isinstance(value[1], (int,float)) self._attributes["x1"] = value[0] self._attributes["y1"] = value[1] # @property def _xy2(self) -> tuple: return self._attributes.get("x2", 0), self._attributes.get("y2", 0) # @_xy2.setter def _xy2(self, value:tuple): assert isinstance(value, (list,tuple)) assert len(value) >= 2 assert isinstance(value[0], (int,float)) assert isinstance(value[1], (int,float)) self._attributes["x2"] = value[0] self._attributes["y2"] = value[1] # @property def x1(self) -> float: return self._attributes.get("x1", 0) # @x1.setter def x1(self, v:float): self._attributes["x1"] = v # @property def y1(self) -> float: return self._attributes.get("y1", 0) # @y1.setter def y1(self, v:float): self._attributes["y1"] = v # @property def x2(self) -> float: return self._attributes.get("x2", 0) # @x2.setter def x2(self, v:float): self._attributes["x2"] = v # @property def y2(self) -> float: return self._attributes.get("y2", 0) # @y2.setter def y2(self, v:float): self._attributes["y2"] = v # ################################################################################################################################ ## Helper Methods ################################################################################################################################ def __move(self, dx:float, dy:float): self.x1 += dx self.y1 += dy self.x2 += dx self.y2 += dy # ################################################################################################################################ ## Public Methods ################################################################################################################################ #
22.04
129
0.400363
240
2,755
4.4625
0.170833
0.20915
0.126984
0.128852
0.571429
0.438842
0.248366
0.248366
0.248366
0.248366
0
0.026446
0.121597
2,755
124
130
22.217742
0.416116
0.021416
0
0.245614
0
0
0.019584
0
0
0
0
0
0.140351
1
0.245614
false
0
0.052632
0.105263
0.421053
0
0
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
1
0
0
0
4
6297185b986dbaeff715729bd5c532b16c106408
215
py
Python
release/pyinstaller/picasso_pyinstaller.py
ajasja/picasso
ac0064fbc232caab1135ebd3c4cc55f439a1cd32
[ "MIT" ]
null
null
null
release/pyinstaller/picasso_pyinstaller.py
ajasja/picasso
ac0064fbc232caab1135ebd3c4cc55f439a1cd32
[ "MIT" ]
null
null
null
release/pyinstaller/picasso_pyinstaller.py
ajasja/picasso
ac0064fbc232caab1135ebd3c4cc55f439a1cd32
[ "MIT" ]
null
null
null
from multiprocessing import freeze_support if __name__ == "__main__": # This line is needed so that pyinstaller can handle multiprocessing freeze_support() from picasso.__main__ import main main()
23.888889
72
0.748837
26
215
5.653846
0.692308
0.176871
0
0
0
0
0
0
0
0
0
0
0.2
215
9
73
23.888889
0.854651
0.306977
0
0
0
0
0.054054
0
0
0
0
0
0
1
0
true
0
0.4
0
0.4
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
4
62a86a0a6999d675de6846f6d230e5be3f08bdc0
471
py
Python
config_training_hku0.py
JiazeWang/lung_nodule_detector
920e7caa95e2dfd2d95bf39113aacd65f7726a9b
[ "MIT" ]
null
null
null
config_training_hku0.py
JiazeWang/lung_nodule_detector
920e7caa95e2dfd2d95bf39113aacd65f7726a9b
[ "MIT" ]
null
null
null
config_training_hku0.py
JiazeWang/lung_nodule_detector
920e7caa95e2dfd2d95bf39113aacd65f7726a9b
[ "MIT" ]
null
null
null
config = {'luna_raw':'/root/ssd_data/LUNA/', 'luna_data':'/research/dept8/jzwang/dataset/LUNA16/combined/', 'preprocess_result_path':'/research/dept8/jzwang/dataset/HKU/preprocessed/numpy/', 'luna_abbr':'./labels/shorter.csv', 'luna_label':'./labels/lunaqualified_all.csv', 'luna_candidate_label':'./labels/luna_candidate_all.csv', 'lidc_xml':'./lidc_xml', 'preprocessing_backend':'python' }
47.1
92
0.632696
51
471
5.54902
0.607843
0.091873
0.134276
0.183746
0
0
0
0
0
0
0
0.010499
0.191083
471
9
93
52.333333
0.732283
0
0
0
0
0
0.690021
0.435244
0
0
0
0
0
1
0
false
0
0
0
0
0
0
0
0
null
0
0
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
1
1
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
62c6ba63505db8004a643f4379efa17d31d237fc
172
py
Python
tests/pylint_airflow/integration/scripts/test_modelsdag_filename.py
scribd/pylint-airflow
90cc4cb9d38cc846c64ebfec8cb9876d49980e4e
[ "MIT" ]
70
2019-05-18T21:57:44.000Z
2022-03-28T16:28:12.000Z
tests/pylint_airflow/integration/scripts/test_modelsdag_filename.py
scribd/pylint-airflow
90cc4cb9d38cc846c64ebfec8cb9876d49980e4e
[ "MIT" ]
7
2019-05-25T11:53:54.000Z
2022-01-20T20:09:11.000Z
tests/pylint_airflow/integration/scripts/test_modelsdag_filename.py
scribd/pylint-airflow
90cc4cb9d38cc846c64ebfec8cb9876d49980e4e
[ "MIT" ]
10
2019-07-08T02:28:24.000Z
2022-03-11T09:39:00.000Z
# [match-dagid-filename] """Explicit DAG assignment, checking models.DAG()""" # pylint: disable=invalid-name from airflow import models dag = models.DAG(dag_id="foobar")
21.5
52
0.738372
23
172
5.478261
0.73913
0.214286
0
0
0
0
0
0
0
0
0
0
0.110465
172
7
53
24.571429
0.823529
0.575581
0
0
0
0
0.090909
0
0
0
0
0
0
1
0
false
0
0.5
0
0.5
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
0
0
0
4
62ca481b929979c6b203219b94afc72421886bd5
915
py
Python
rev/rev-optimizeme/solve.py
NoXLaw/RaRCTF2021-Challenges-Public
1a1b094359b88f8ebbc83a6b26d27ffb2602458f
[ "MIT" ]
2
2021-08-09T17:08:12.000Z
2021-08-09T17:08:17.000Z
rev/rev-optimizeme/solve.py
NoXLaw/RaRCTF2021-Challenges-Public
1a1b094359b88f8ebbc83a6b26d27ffb2602458f
[ "MIT" ]
null
null
null
rev/rev-optimizeme/solve.py
NoXLaw/RaRCTF2021-Challenges-Public
1a1b094359b88f8ebbc83a6b26d27ffb2602458f
[ "MIT" ]
1
2021-10-09T16:51:56.000Z
2021-10-09T16:51:56.000Z
from Crypto.Util.number import long_to_bytes def optimizedlcg(b, p, state, rounds): # optimized LCG where a = 2 state = pow(2,rounds,p) * state + b * (pow(2,rounds,p) - 1) return state p = 48569718278242303506230209619975923780743060131772701186017298107559924284242635979759825505782161830376129653325924722665978898131985179210937191151223888128070809835310745199785794930057364029265229452480206055255713317889077410854999087437697415991657128058495524746236464800864688806069056279502078609163 a = 2 b = 3 rounds = p >> 3 state = 21168651249892365486136418125726362865327546384637160303310624426991883020070096339748008613139669972987435197171828010807801735363313790068442787546235698438618519181810304746021912309785611083417111013075787209062958230479598507954803956586021189590329762702913302100337042009595481240883581225904761204891 print(long_to_bytes(optimizedlcg(b,p,state,rounds) % p).decode())
70.384615
316
0.89071
55
915
14.745455
0.490909
0.034525
0.027127
0.046856
0.061652
0
0
0
0
0
0
0.724419
0.060109
915
12
317
76.25
0.218605
0.027322
0
0
0
0
0
0
0
1
0
0
0
1
0.1
false
0
0.1
0
0.3
0.1
0
0
1
null
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
1
0
0
0
0
0
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
4
62d427d04c077e2e4ca4ac8c5a013878a6bd2a7c
83
py
Python
boot/dupa/apps.py
micbuz/project2
1442ad4767b4fb3a3ed5d36108682f9d60c4eab8
[ "Apache-2.0" ]
null
null
null
boot/dupa/apps.py
micbuz/project2
1442ad4767b4fb3a3ed5d36108682f9d60c4eab8
[ "Apache-2.0" ]
null
null
null
boot/dupa/apps.py
micbuz/project2
1442ad4767b4fb3a3ed5d36108682f9d60c4eab8
[ "Apache-2.0" ]
null
null
null
from django.apps import AppConfig class DupaConfig(AppConfig): name = 'dupa'
13.833333
33
0.73494
10
83
6.1
0.9
0
0
0
0
0
0
0
0
0
0
0
0.180723
83
5
34
16.6
0.897059
0
0
0
0
0
0.048193
0
0
0
0
0
0
1
0
false
0
0.333333
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
4
62e7050821f1793d97d9b9fe8e04cc0a8ce555f6
86
py
Python
code/sherlock_helpers/setup.py
paxtonfitzpatrick/sherlock-topic-model-paper
ceda0ca82ec86aa716f668a2b9832c691f8d129f
[ "MIT" ]
null
null
null
code/sherlock_helpers/setup.py
paxtonfitzpatrick/sherlock-topic-model-paper
ceda0ca82ec86aa716f668a2b9832c691f8d129f
[ "MIT" ]
null
null
null
code/sherlock_helpers/setup.py
paxtonfitzpatrick/sherlock-topic-model-paper
ceda0ca82ec86aa716f668a2b9832c691f8d129f
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from setuptools import setup # reads from setup.cfg setup()
12.285714
28
0.662791
12
86
4.75
0.75
0
0
0
0
0
0
0
0
0
0
0.014286
0.186047
86
6
29
14.333333
0.8
0.488372
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.5
0
0.5
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
4
1a02d8f7e190d33ef178f7d53934619cbd06c374
242
py
Python
tinydb_bulk/errors.py
ppolxda/tinydb_bulk
44d856d68a7c0600019dfaadd255747bb64b4878
[ "MIT" ]
null
null
null
tinydb_bulk/errors.py
ppolxda/tinydb_bulk
44d856d68a7c0600019dfaadd255747bb64b4878
[ "MIT" ]
null
null
null
tinydb_bulk/errors.py
ppolxda/tinydb_bulk
44d856d68a7c0600019dfaadd255747bb64b4878
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ @create: 2019-05-30 22:19:12. @author: ppolxda @desc: """ class Error(Exception): pass class InputError(Error): pass class DuplicateError(Error): pass class IndexExpiredError(Error): pass
9.68
31
0.632231
29
242
5.275862
0.689655
0.176471
0.183007
0
0
0
0
0
0
0
0
0.078534
0.210744
242
24
32
10.083333
0.722513
0.322314
0
0.5
0
0
0
0
0
0
0
0
0
1
0
true
0.5
0
0
0.5
0
1
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
1
0
0
0
0
0
4
1a03ddf627777cf3a2f5bb955d01f48bfd72854b
144
py
Python
signals/signals/apps/entities/apps.py
gonzaloamadio/django-signals3
39bb2520cbeaeca3128a00e251f55b4b9ee5ad38
[ "MIT" ]
null
null
null
signals/signals/apps/entities/apps.py
gonzaloamadio/django-signals3
39bb2520cbeaeca3128a00e251f55b4b9ee5ad38
[ "MIT" ]
null
null
null
signals/signals/apps/entities/apps.py
gonzaloamadio/django-signals3
39bb2520cbeaeca3128a00e251f55b4b9ee5ad38
[ "MIT" ]
null
null
null
from django.apps import AppConfig class EntitiesConfig(AppConfig): name ='entities' def ready(self): import entities.signals
16
33
0.708333
16
144
6.375
0.8125
0
0
0
0
0
0
0
0
0
0
0
0.215278
144
8
34
18
0.902655
0
0
0
0
0
0.055556
0
0
0
0
0
0
1
0.2
false
0
0.4
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
4
1a19e10072dfbbd990340ee1cacc69750f324b41
47
py
Python
cryptocurrency_bot/configs/__init__.py
Hukyl/cryptocurrency_bot
5fd97056f1c88aea406571d1183e3ce1b7a50474
[ "MIT" ]
1
2021-06-02T06:13:56.000Z
2021-06-02T06:13:56.000Z
cryptocurrency_bot/configs/__init__.py
Hukyl/cryptocurrency_bot
5fd97056f1c88aea406571d1183e3ce1b7a50474
[ "MIT" ]
null
null
null
cryptocurrency_bot/configs/__init__.py
Hukyl/cryptocurrency_bot
5fd97056f1c88aea406571d1183e3ce1b7a50474
[ "MIT" ]
null
null
null
from . import settings __all__ = ['settings']
11.75
22
0.702128
5
47
5.8
0.8
0
0
0
0
0
0
0
0
0
0
0
0.170213
47
3
23
15.666667
0.74359
0
0
0
0
0
0.170213
0
0
0
0
0
0
1
0
false
0
0.5
0
0.5
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
0
0
0
4
c5121e3c62dbf0318aafe5d769b4cfa221bbb4b3
213
py
Python
pgx/Physical.py
tantiem/pgxtended
4f5c05ea0eebb3a6bebac1a35a74f0d161951772
[ "MIT" ]
null
null
null
pgx/Physical.py
tantiem/pgxtended
4f5c05ea0eebb3a6bebac1a35a74f0d161951772
[ "MIT" ]
null
null
null
pgx/Physical.py
tantiem/pgxtended
4f5c05ea0eebb3a6bebac1a35a74f0d161951772
[ "MIT" ]
null
null
null
from . import Transformable class Physical(Transformable.Transformable): def __init__(self,pos,image,group=None,layer=0): super().__init__(pos,image,group,layer) #Overload methods if needed
30.428571
53
0.723005
26
213
5.615385
0.730769
0.109589
0.178082
0
0
0
0
0
0
0
0
0.00565
0.169014
213
7
54
30.428571
0.819209
0.122066
0
0
0
0
0
0
0
0
0
0
0
1
0.25
false
0
0.25
0
0.75
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
0
1
0
0
4
c5162232fabeef8e42462c217f96bad06d04b47d
172
py
Python
InterviewTool/accounttree/forms.py
billcd/InterviewTool
dcb02fd3226259f76a1c405f43d1f665ab942750
[ "Apache-2.0" ]
null
null
null
InterviewTool/accounttree/forms.py
billcd/InterviewTool
dcb02fd3226259f76a1c405f43d1f665ab942750
[ "Apache-2.0" ]
null
null
null
InterviewTool/accounttree/forms.py
billcd/InterviewTool
dcb02fd3226259f76a1c405f43d1f665ab942750
[ "Apache-2.0" ]
null
null
null
from django.forms import ModelForm from .models import Account class AccountFormBasicOrg(ModelForm): class Meta: model = Account exclude = ('user', )
19.111111
37
0.686047
18
172
6.555556
0.722222
0
0
0
0
0
0
0
0
0
0
0
0.238372
172
8
38
21.5
0.900763
0
0
0
0
0
0.023256
0
0
0
0
0
0
1
0
false
0
0.333333
0
0.666667
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
4
c51ac7254b783b71aef7e673f1c40a1d5a9203ac
128
py
Python
catalog/urls.py
4470056464/locallibrary
a3cc25d4987c89bbb52bea670c531438faa6b104
[ "MIT" ]
null
null
null
catalog/urls.py
4470056464/locallibrary
a3cc25d4987c89bbb52bea670c531438faa6b104
[ "MIT" ]
null
null
null
catalog/urls.py
4470056464/locallibrary
a3cc25d4987c89bbb52bea670c531438faa6b104
[ "MIT" ]
null
null
null
from django.conf.urls import url # urlpatterns = [ # url('r^$/',view.), # url('catalog/', include('catalog.urls')), # ]
21.333333
47
0.578125
15
128
4.933333
0.733333
0
0
0
0
0
0
0
0
0
0
0
0.179688
128
6
48
21.333333
0.704762
0.671875
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
4
c51d65e52f281a02e312feb5da4abe882e26063c
5,283
py
Python
UnityEngine/ParticleSystem/EmitParams/__init__.py
Grim-es/udon-pie-auto-completion
c2cd86554ed615cdbbb01e19fa40665eafdfaedc
[ "MIT" ]
null
null
null
UnityEngine/ParticleSystem/EmitParams/__init__.py
Grim-es/udon-pie-auto-completion
c2cd86554ed615cdbbb01e19fa40665eafdfaedc
[ "MIT" ]
null
null
null
UnityEngine/ParticleSystem/EmitParams/__init__.py
Grim-es/udon-pie-auto-completion
c2cd86554ed615cdbbb01e19fa40665eafdfaedc
[ "MIT" ]
null
null
null
from UdonPie import System from UdonPie import UnityEngine from UdonPie.Undefined import * class EmitParams: def __new__(cls, arg1=None): ''' :returns: EmitParams :rtype: UnityEngine.ParticleSystem.EmitParams ''' pass @staticmethod def get_position(): ''' :returns: Vector3 :rtype: UnityEngine.Vector3 ''' pass @staticmethod def set_position(arg1): ''' :param arg1: Vector3 :type arg1: UnityEngine.Vector3 ''' pass @staticmethod def get_applyShapeToPosition(): ''' :returns: Boolean :rtype: System.Boolean ''' pass @staticmethod def set_applyShapeToPosition(arg1): ''' :param arg1: Boolean :type arg1: System.Boolean or bool ''' pass @staticmethod def get_velocity(): ''' :returns: Vector3 :rtype: UnityEngine.Vector3 ''' pass @staticmethod def set_velocity(arg1): ''' :param arg1: Vector3 :type arg1: UnityEngine.Vector3 ''' pass @staticmethod def get_startLifetime(): ''' :returns: Single :rtype: System.Single ''' pass @staticmethod def set_startLifetime(arg1): ''' :param arg1: Single :type arg1: System.Single or float ''' pass @staticmethod def get_startSize(): ''' :returns: Single :rtype: System.Single ''' pass @staticmethod def set_startSize(arg1): ''' :param arg1: Single :type arg1: System.Single or float ''' pass @staticmethod def get_startSize3D(): ''' :returns: Vector3 :rtype: UnityEngine.Vector3 ''' pass @staticmethod def set_startSize3D(arg1): ''' :param arg1: Vector3 :type arg1: UnityEngine.Vector3 ''' pass @staticmethod def get_axisOfRotation(): ''' :returns: Vector3 :rtype: UnityEngine.Vector3 ''' pass @staticmethod def set_axisOfRotation(arg1): ''' :param arg1: Vector3 :type arg1: UnityEngine.Vector3 ''' pass @staticmethod def get_rotation(): ''' :returns: Single :rtype: System.Single ''' pass @staticmethod def set_rotation(arg1): ''' :param arg1: Single :type arg1: System.Single or float ''' pass @staticmethod def get_rotation3D(): ''' :returns: Vector3 :rtype: UnityEngine.Vector3 ''' pass @staticmethod def set_rotation3D(arg1): ''' :param arg1: Vector3 :type arg1: UnityEngine.Vector3 ''' pass @staticmethod def get_angularVelocity(): ''' :returns: Single :rtype: System.Single ''' pass @staticmethod def set_angularVelocity(arg1): ''' :param arg1: Single :type arg1: System.Single or float ''' pass @staticmethod def get_angularVelocity3D(): ''' :returns: Vector3 :rtype: UnityEngine.Vector3 ''' pass @staticmethod def set_angularVelocity3D(arg1): ''' :param arg1: Vector3 :type arg1: UnityEngine.Vector3 ''' pass @staticmethod def get_startColor(): ''' :returns: Color32 :rtype: UnityEngine.Color32 ''' pass @staticmethod def set_startColor(arg1): ''' :param arg1: Color32 :type arg1: UnityEngine.Color32 ''' pass @staticmethod def get_randomSeed(): ''' :returns: UInt32 :rtype: System.UInt32 ''' pass @staticmethod def set_randomSeed(arg1): ''' :param arg1: UInt32 :type arg1: System.UInt32 ''' pass @staticmethod def ResetPosition(): pass @staticmethod def ResetVelocity(): pass @staticmethod def ResetAxisOfRotation(): pass @staticmethod def ResetRotation(): pass @staticmethod def ResetAngularVelocity(): pass @staticmethod def ResetStartSize(): pass @staticmethod def ResetStartColor(): pass @staticmethod def ResetRandomSeed(): pass @staticmethod def ResetStartLifetime(): pass @staticmethod def Equals(arg1): ''' :param arg1: Object :type arg1: System.Object :returns: Boolean :rtype: System.Boolean ''' pass @staticmethod def ToString(): ''' :returns: String :rtype: System.String ''' pass @staticmethod def GetHashCode(): ''' :returns: Int32 :rtype: System.Int32 ''' pass @staticmethod def GetType(): ''' :returns: Type :rtype: System.Type ''' pass
18.154639
53
0.508234
415
5,283
6.39759
0.142169
0.235028
0.279096
0.107721
0.557439
0.506215
0.506215
0.506215
0.467797
0.256121
0
0.029099
0.395041
5,283
290
54
18.217241
0.801627
0.286769
0
0.642276
0
0
0
0
0
0
0
0
0
1
0.325203
false
0.325203
0.02439
0
0.357724
0
0
0
0
null
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
1
0
0
0
0
0
4
c52942057b2469844f26cbd5c8c2a6a41122bec6
60
py
Python
python/testData/breadcrumbs/forElse.py
truthiswill/intellij-community
fff88cfb0dc168eea18ecb745d3e5b93f57b0b95
[ "Apache-2.0" ]
2
2019-04-28T07:48:50.000Z
2020-12-11T14:18:08.000Z
python/testData/breadcrumbs/forElse.py
truthiswill/intellij-community
fff88cfb0dc168eea18ecb745d3e5b93f57b0b95
[ "Apache-2.0" ]
173
2018-07-05T13:59:39.000Z
2018-08-09T01:12:03.000Z
python/testData/breadcrumbs/forElse.py
truthiswill/intellij-community
fff88cfb0dc168eea18ecb745d3e5b93f57b0b95
[ "Apache-2.0" ]
2
2020-03-15T08:57:37.000Z
2020-04-07T04:48:14.000Z
for i in range(10): print i else: print "a<caret>bc"
15
22
0.6
12
60
3
0.833333
0
0
0
0
0
0
0
0
0
0
0.045455
0.266667
60
4
22
15
0.772727
0
0
0
0
0
0.163934
0
0
0
0
0
0
0
null
null
0
0
null
null
0.5
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
1
0
0
0
0
0
0
1
0
4
c54ca499b8c8b3942ab285c522cbd63dc99de0b1
77
py
Python
abc/abc070/abc070b.py
c-yan/atcoder
940e49d576e6a2d734288fadaf368e486480a948
[ "MIT" ]
1
2019-08-21T00:49:34.000Z
2019-08-21T00:49:34.000Z
abc/abc070/abc070b.py
c-yan/atcoder
940e49d576e6a2d734288fadaf368e486480a948
[ "MIT" ]
null
null
null
abc/abc070/abc070b.py
c-yan/atcoder
940e49d576e6a2d734288fadaf368e486480a948
[ "MIT" ]
null
null
null
A, B, C, D = map(int, input().split()) print(max(min(B, D) - max(A, C), 0))
19.25
38
0.506494
17
77
2.294118
0.705882
0
0
0
0
0
0
0
0
0
0
0.015873
0.181818
77
3
39
25.666667
0.603175
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0
0
0
0.5
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
1
0
4
c55e9e18a5e8f494fa05c1d4229fce40ee761c45
321
py
Python
users/models.py
areebbeigh/greenspace-demo
0754f3b50e845bd5e50239361239f9b0b8aba42b
[ "Apache-2.0" ]
1
2020-07-06T05:53:12.000Z
2020-07-06T05:53:12.000Z
users/models.py
areebbeigh/greenspace-demo
0754f3b50e845bd5e50239361239f9b0b8aba42b
[ "Apache-2.0" ]
1
2020-06-11T15:51:49.000Z
2020-06-11T16:10:31.000Z
users/models.py
areebbeigh/greenspace-demo
0754f3b50e845bd5e50239361239f9b0b8aba42b
[ "Apache-2.0" ]
null
null
null
from django.db import models from django.conf import settings from django.contrib.auth.models import AbstractUser class CustomUser(AbstractUser): def __str__(self): return f'User<{self.username}>' def is_nursery_manager(self): return self.groups.filter(name=settings.NURSERY_MGR_GROUP).exists()
29.181818
75
0.757009
43
321
5.465116
0.651163
0.12766
0
0
0
0
0
0
0
0
0
0
0.149533
321
11
75
29.181818
0.860806
0
0
0
0
0
0.065217
0.065217
0
0
0
0
0
1
0.25
false
0
0.375
0.25
1
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
1
1
1
0
0
4
c5675332a20f13651c950223af1eefce83dac1c4
369
py
Python
webtext/api/views/user.py
stricoff92/webtext-analysis
9a6e5637e6695ee4ae68d182bb7a07c4beef7cca
[ "MIT" ]
null
null
null
webtext/api/views/user.py
stricoff92/webtext-analysis
9a6e5637e6695ee4ae68d182bb7a07c4beef7cca
[ "MIT" ]
null
null
null
webtext/api/views/user.py
stricoff92/webtext-analysis
9a6e5637e6695ee4ae68d182bb7a07c4beef7cca
[ "MIT" ]
null
null
null
from rest_framework.decorators import api_view, permission_classes from rest_framework.permissions import IsAuthenticated from rest_framework.response import Response from rest_framework import status @api_view(['GET']) @permission_classes([IsAuthenticated]) def get_user_details(request): return Response({'username':request.user.username}, status.HTTP_200_OK)
30.75
75
0.834688
47
369
6.297872
0.489362
0.108108
0.22973
0
0
0
0
0
0
0
0
0.008876
0.084011
369
11
76
33.545455
0.866864
0
0
0
0
0
0.029891
0
0
0
0
0
0
1
0.125
false
0
0.5
0.125
0.75
0
0
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
1
1
0
0
4
3da2f41d00945948fe9bf5f735e86c15396158b9
149
py
Python
telemetry-pi/model/Voltage.py
USCSolarCarStrategyTeam/driver-display
a9570f5c7ea98a966f95d6ddc32b88e22e29bd56
[ "Apache-2.0" ]
null
null
null
telemetry-pi/model/Voltage.py
USCSolarCarStrategyTeam/driver-display
a9570f5c7ea98a966f95d6ddc32b88e22e29bd56
[ "Apache-2.0" ]
2
2017-11-04T22:44:41.000Z
2018-03-23T02:14:20.000Z
telemetry-pi/model/Voltage.py
USCSolarCarStrategyTeam/telemetry-pi
a9570f5c7ea98a966f95d6ddc32b88e22e29bd56
[ "Apache-2.0" ]
5
2017-10-07T22:54:09.000Z
2018-01-27T21:20:51.000Z
from Metric import Metric class Voltage(Metric): def __init__(self, name, value): Metric.__init__(self, name) self.value = value
24.833333
36
0.671141
19
149
4.842105
0.526316
0.173913
0.26087
0
0
0
0
0
0
0
0
0
0.234899
149
5
37
29.8
0.807018
0
0
0
0
0
0
0
0
0
0
0
0
1
0.2
false
0
0.2
0
0.6
0
1
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
1
0
0
4
3da7a1817cd515873473ac43a15bbb29c4b261e1
73
py
Python
wagtailcommerce/dashboard/__init__.py
theplusagency/wagtail-commerce
6047170f29199ccaf2778534976ab0970c2877e7
[ "BSD-3-Clause" ]
3
2019-04-12T15:38:43.000Z
2019-09-22T10:23:20.000Z
wagtailcommerce/dashboard/__init__.py
wagtailcommerce/wagtailcommerce
308ed8348483806c16062d09a7e69ec44d9a2e73
[ "BSD-3-Clause" ]
null
null
null
wagtailcommerce/dashboard/__init__.py
wagtailcommerce/wagtailcommerce
308ed8348483806c16062d09a7e69ec44d9a2e73
[ "BSD-3-Clause" ]
null
null
null
default_app_config = 'wagtailcommerce.dashboard.apps.DashboardAppConfig'
36.5
72
0.876712
7
73
8.857143
1
0
0
0
0
0
0
0
0
0
0
0
0.041096
73
1
73
73
0.885714
0
0
0
0
0
0.671233
0.671233
0
0
0
0
0
1
0
false
0
0
0
0
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
1
1
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
3dae5b91a93e8a38c133fbef3b0acf5d7eecf7a7
145
py
Python
test/__init__.py
9999years/license
3650dc776222288042e9ae5f45e1cf187eda7524
[ "Apache-2.0", "BSD-2-Clause", "MIT", "Apache-1.0", "BSD-3-Clause" ]
19
2015-07-20T13:40:16.000Z
2021-04-10T01:21:20.000Z
test/__init__.py
9999years/license
3650dc776222288042e9ae5f45e1cf187eda7524
[ "Apache-2.0", "BSD-2-Clause", "MIT", "Apache-1.0", "BSD-3-Clause" ]
7
2017-08-18T09:13:43.000Z
2020-10-07T05:56:57.000Z
test/__init__.py
9999years/license
3650dc776222288042e9ae5f45e1cf187eda7524
[ "Apache-2.0", "BSD-2-Clause", "MIT", "Apache-1.0", "BSD-3-Clause" ]
10
2015-09-30T15:13:14.000Z
2021-12-08T15:05:12.000Z
import os import sys init = os.path.abspath(__file__) test = os.path.dirname(init) project = os.path.dirname(test) sys.path.insert(0, project)
16.111111
32
0.744828
24
145
4.333333
0.5
0.173077
0.25
0
0
0
0
0
0
0
0
0.007813
0.117241
145
8
33
18.125
0.804688
0
0
0
0
0
0
0
0
0
0
0
0
1
0
false
0
0.333333
0
0.333333
0
1
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
0
0
0
4