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
3796aeeebdfefccb95189994b9d723808d418a1f
762
py
Python
setup.py
malma28/macord
325d1c14406e66dd2fba82889d9c50ff118ad6c0
[ "MIT" ]
null
null
null
setup.py
malma28/macord
325d1c14406e66dd2fba82889d9c50ff118ad6c0
[ "MIT" ]
null
null
null
setup.py
malma28/macord
325d1c14406e66dd2fba82889d9c50ff118ad6c0
[ "MIT" ]
null
null
null
import setuptools setuptools.setup( name='macord', version='0.0.1', description='a simple discord api for python', url='https://github.com/malma28/macord', author='Malma', author_email='adamakmal789@gmail.com', license='MIT', packages=[ 'macord' ], requires=[ 'aiohttp', 'requests' ], classifiers=[ 'Development Status :: Pre Alpha', 'License :: OSI Approved :: MIT License', 'Operating System :: Unix :: Windows', 'Programming Language :: Python :: 3', 'Programming Language :: Python :: 3.7', 'Programming Language :: Python :: 3.8', 'Programming Language :: Python :: 3.9', 'Programming Language :: Python :: 3.10' ] )
27.214286
50
0.568241
75
762
5.76
0.653333
0.219907
0.289352
0.300926
0
0
0
0
0
0
0
0.032787
0.279528
762
28
51
27.214286
0.754098
0
0
0.074074
0
0
0.542595
0.028834
0
0
0
0
0
1
0
true
0
0.037037
0
0.037037
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
1
0
0
0
0
0
0
4
37bbf0c0a402babdb72c6dbd0e755c674cc93bc3
443
py
Python
.environment/lib/python3.8/site-packages/docplex/mp/ds_utils.py
LuisMi1245/QPath-and-Snakes
48f784da67d9720c955890a28543c9863e02a455
[ "MIT" ]
null
null
null
.environment/lib/python3.8/site-packages/docplex/mp/ds_utils.py
LuisMi1245/QPath-and-Snakes
48f784da67d9720c955890a28543c9863e02a455
[ "MIT" ]
1
2019-11-14T09:30:19.000Z
2019-11-22T23:23:27.000Z
docplex/mp/ds_utils.py
ctzhu/docplex
783d2137bedfe8b01553cf31035803085fb8819a
[ "Apache-2.0" ]
null
null
null
# -------------------------------------------------------------------------- # Source file provided under Apache License, Version 2.0, January 2004, # http://www.apache.org/licenses/ # (c) Copyright IBM Corp. 2015, 2021 # -------------------------------------------------------------------------- # gendoc: ignore try: import scipy.sparse as sp except ImportError: sp = None def is_scipy_sparse(m): return sp and sp.issparse(m)
27.6875
76
0.462754
45
443
4.511111
0.844444
0.108374
0
0
0
0
0
0
0
0
0
0.036364
0.130926
443
16
77
27.6875
0.490909
0.679458
0
0
0
0
0
0
0
0
0
0
0
1
0.166667
false
0
0.333333
0.166667
0.666667
0
0
0
0
null
0
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
0
0
0
1
1
1
0
0
4
80815eec65ea9da134c0df6575a85cb822bc25df
179
py
Python
start.py
Cribstone/home-assistant
328b9a84c0169c8067f2aa8d07392519de8a5e35
[ "MIT" ]
1
2022-01-09T18:02:24.000Z
2022-01-09T18:02:24.000Z
start.py
jwveldhuis/home-assistant
f07622e0d77ceac236d631245a2486f249812666
[ "MIT" ]
null
null
null
start.py
jwveldhuis/home-assistant
f07622e0d77ceac236d631245a2486f249812666
[ "MIT" ]
null
null
null
#!/usr/bin/python2 """ Starts home assistant with all possible functionality. """ import homeassistant.bootstrap homeassistant.bootstrap.from_config_file("home-assistant.conf")
25.571429
63
0.798883
21
179
6.714286
0.809524
0.184397
0
0
0
0
0
0
0
0
0
0.006098
0.083799
179
6
64
29.833333
0.853659
0.407821
0
0
0
0
0.191919
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
80d3fa63c2a4410e6747ae715946aaa07f86803d
228
py
Python
packages/jet_bridge_base/jet_bridge_base/paginators/pagination.py
F2210/jet-bridge
72b1af5cd7df585a4026d65170d3607f8cdf6bea
[ "MIT" ]
1,247
2019-01-10T22:22:08.000Z
2022-03-29T20:54:32.000Z
packages/jet_bridge_base/jet_bridge_base/paginators/pagination.py
F2210/jet-bridge
72b1af5cd7df585a4026d65170d3607f8cdf6bea
[ "MIT" ]
12
2019-03-15T20:06:14.000Z
2022-01-07T10:28:20.000Z
packages/jet_bridge_base/jet_bridge_base/paginators/pagination.py
F2210/jet-bridge
72b1af5cd7df585a4026d65170d3607f8cdf6bea
[ "MIT" ]
130
2019-02-26T17:36:53.000Z
2022-03-17T22:46:27.000Z
class Pagination(object): count = None def paginate_queryset(self, request, queryset, handler): raise NotImplementedError def get_paginated_response(self, request, data): raise NotImplementedError
22.8
60
0.719298
23
228
7
0.73913
0.136646
0
0
0
0
0
0
0
0
0
0
0.214912
228
9
61
25.333333
0.899441
0
0
0.333333
0
0
0
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
80d8ceb0f3f0864e1ed718fa4a0dcf2a1584c071
134
py
Python
torcs-client/run.py
CinNec/torcs
15c71e3636d4c167d3297d381e7c053d8a18723e
[ "MIT" ]
null
null
null
torcs-client/run.py
CinNec/torcs
15c71e3636d4c167d3297d381e7c053d8a18723e
[ "MIT" ]
null
null
null
torcs-client/run.py
CinNec/torcs
15c71e3636d4c167d3297d381e7c053d8a18723e
[ "MIT" ]
null
null
null
#! /usr/bin/env python3 from pytocl.main import main from my_driver import MyDriver if __name__ == '__main__': main(MyDriver())
16.75
30
0.723881
19
134
4.631579
0.684211
0
0
0
0
0
0
0
0
0
0
0.008929
0.164179
134
7
31
19.142857
0.776786
0.164179
0
0
0
0
0.072072
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
80e95d23934edf9dcfda048536a22067a2d1c532
53
py
Python
src/knarrow/__init__.py
InCogNiTo124/knarrow
b0a19273a27e68899d982bcc0bf0938c60d3ec26
[ "Apache-2.0" ]
2
2021-10-10T11:12:53.000Z
2021-12-14T13:55:30.000Z
src/knarrow/__init__.py
InCogNiTo124/knarrow
b0a19273a27e68899d982bcc0bf0938c60d3ec26
[ "Apache-2.0" ]
17
2021-09-30T21:51:28.000Z
2022-03-27T23:33:17.000Z
src/knarrow/__init__.py
InCogNiTo124/knarrow
b0a19273a27e68899d982bcc0bf0938c60d3ec26
[ "Apache-2.0" ]
null
null
null
from .main import find_knee __all__ = ["find_knee"]
13.25
27
0.735849
8
53
4.125
0.75
0.484848
0
0
0
0
0
0
0
0
0
0
0.150943
53
3
28
17.666667
0.733333
0
0
0
0
0
0.169811
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
80ef7ec9cc419c3df64840b1a0c930211b5f3d93
64
py
Python
watchdog_kj_kultura/main/__init__.py
watchdogpolska/watchdog-kj-kultura
ea1a5c52ef2a174c012cc08eff5fdd7aa3b911b0
[ "MIT" ]
null
null
null
watchdog_kj_kultura/main/__init__.py
watchdogpolska/watchdog-kj-kultura
ea1a5c52ef2a174c012cc08eff5fdd7aa3b911b0
[ "MIT" ]
138
2016-12-10T19:18:18.000Z
2019-06-10T19:32:40.000Z
watchdog_kj_kultura/main/__init__.py
watchdogpolska/watchdog-kj-kultura
ea1a5c52ef2a174c012cc08eff5fdd7aa3b911b0
[ "MIT" ]
null
null
null
default_app_config = 'watchdog_kj_kultura.main.apps.MainConfig'
32
63
0.859375
9
64
5.666667
1
0
0
0
0
0
0
0
0
0
0
0
0.046875
64
1
64
64
0.836066
0
0
0
0
0
0.625
0.625
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
80fb052e49ac9c8cd9bbd5621238ef8ea2807b4d
192
py
Python
category/forms.py
Moisestuli/karrata
962ce0c573214bfc83720727c9cacae823a8c372
[ "MIT" ]
null
null
null
category/forms.py
Moisestuli/karrata
962ce0c573214bfc83720727c9cacae823a8c372
[ "MIT" ]
null
null
null
category/forms.py
Moisestuli/karrata
962ce0c573214bfc83720727c9cacae823a8c372
[ "MIT" ]
null
null
null
from django import forms from category.models import Category class CategoriaForm(forms.ModelForm): class Meta: model = Category fields = ('nome','descricao','upload')
19.2
46
0.6875
21
192
6.285714
0.714286
0
0
0
0
0
0
0
0
0
0
0
0.21875
192
9
47
21.333333
0.88
0
0
0
0
0
0.098958
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
80fc8504b29f6d34a034668feb50331ead6fcc58
414
py
Python
mp_sort/virtenv/lib/python3.6/site-packages/transcrypt/development/automated_tests/transcrypt/div_issues/issue387/__init__.py
ang-jason/fip_powerx_mini_projects-foxtrot
37e3671969b516369e2d1c7cab5890b75c489f56
[ "MIT" ]
2,200
2016-10-12T16:47:13.000Z
2022-03-30T16:40:35.000Z
mp_sort/virtenv/lib/python3.6/site-packages/transcrypt/development/automated_tests/transcrypt/div_issues/issue387/__init__.py
ang-jason/fip_powerx_mini_projects-foxtrot
37e3671969b516369e2d1c7cab5890b75c489f56
[ "MIT" ]
672
2016-10-12T16:36:48.000Z
2022-03-25T00:57:04.000Z
mp_sort/virtenv/lib/python3.6/site-packages/transcrypt/development/automated_tests/transcrypt/div_issues/issue387/__init__.py
ang-jason/fip_powerx_mini_projects-foxtrot
37e3671969b516369e2d1c7cab5890b75c489f56
[ "MIT" ]
230
2016-10-20T14:31:40.000Z
2022-03-16T15:57:15.000Z
import div_issues.issue387.test1 import div_issues.issue387.test1.test2 def run387 (autoTester): autoTester.check (div_issues.issue387.test1.getReport ()) autoTester.check ('From test: ', div_issues.issue387.test1.test2.C.__module__) autoTester.check (__name__) class D: pass autoTester.check ('From test:', D.__module__) autoTester.check (D.__name__)
24.352941
83
0.681159
48
414
5.458333
0.395833
0.28626
0.259542
0.335878
0.335878
0
0
0
0
0
0
0.064417
0.21256
414
16
84
25.875
0.739264
0
0
0
0
0
0.052897
0
0
0
0
0
0
1
0.1
false
0.1
0.2
0
0.4
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
0386c9960c429274be0e0da283b610ed1735af00
58
py
Python
ldapplugin/__init__.py
ScottWales/LdapPlugin
1c629689a47fee5dc4343efb5977badab761df3c
[ "BSD-3-Clause" ]
null
null
null
ldapplugin/__init__.py
ScottWales/LdapPlugin
1c629689a47fee5dc4343efb5977badab761df3c
[ "BSD-3-Clause" ]
null
null
null
ldapplugin/__init__.py
ScottWales/LdapPlugin
1c629689a47fee5dc4343efb5977badab761df3c
[ "BSD-3-Clause" ]
null
null
null
# Ldap Plugin python package from ldapplugin.api import *
19.333333
28
0.793103
8
58
5.75
1
0
0
0
0
0
0
0
0
0
0
0
0.155172
58
2
29
29
0.938776
0.448276
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
0399d68e56fa3499dfcecc64bfc6bd1999f6dc6f
745
py
Python
schema.py
Brotchu/DistributedDopingTest
50ba29eac3540b43b019ac75d0b2d0339b7b6767
[ "MIT" ]
null
null
null
schema.py
Brotchu/DistributedDopingTest
50ba29eac3540b43b019ac75d0b2d0339b7b6767
[ "MIT" ]
null
null
null
schema.py
Brotchu/DistributedDopingTest
50ba29eac3540b43b019ac75d0b2d0339b7b6767
[ "MIT" ]
null
null
null
from enum import unique from mongoengine import (DateTimeField, DictField, Document, EmbeddedDocument, StringField) class DateAvailability(EmbeddedDocument): date = DateTimeField(required=True) location = StringField(required=True) class Athlete(Document): name = StringField(required=True) email = StringField(required=True) password = StringField(required=True) # TODO: hash it!! nationality = StringField(required=True) location = StringField(required=True) # availability = db.ListField(db.EmbeddedDocumentField(DateAvailability)) availability = DictField() meta = {'collection': 'athlete'} class Emails(Document): email = StringField(required=True, unique=True)
28.653846
78
0.720805
69
745
7.782609
0.449275
0.178771
0.299814
0.115456
0.160149
0.160149
0
0
0
0
0
0
0.18255
745
25
79
29.8
0.881773
0.116779
0
0.125
0
0
0.025954
0
0
0
0
0.04
0
1
0
false
0.0625
0.125
0
0.9375
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
1
0
0
0
0
1
0
0
1
0
0
4
03b94b39b4fb4557a2f3c3ee807549e0e833cbdc
216
py
Python
treesearchsolverpy/__init__.py
fontanf/treesearchsolverpy
5e59eef3cac31ab67eb904de7d9733e36be737d8
[ "MIT" ]
null
null
null
treesearchsolverpy/__init__.py
fontanf/treesearchsolverpy
5e59eef3cac31ab67eb904de7d9733e36be737d8
[ "MIT" ]
null
null
null
treesearchsolverpy/__init__.py
fontanf/treesearchsolverpy
5e59eef3cac31ab67eb904de7d9733e36be737d8
[ "MIT" ]
null
null
null
from .greedy import greedy from .best_first_search import best_first_search from .iterative_beam_search import iterative_beam_search __all__ = [ 'greedy', 'best_first_search', 'iterative_beam_search', ]
21.6
56
0.782407
28
216
5.464286
0.321429
0.176471
0.294118
0
0
0
0
0
0
0
0
0
0.148148
216
9
57
24
0.831522
0
0
0
0
0
0.203704
0.097222
0
0
0
0
0
1
0
false
0
0.375
0
0.375
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
03e5ff502639b89e15828b8e07168aa0ff0b57ba
511
py
Python
gan_server_api/serializers.py
luojie1024/HACK_GAN_MB
a709cf7a88649584b05a4bd71bc3fbe8fa212646
[ "Apache-2.0" ]
6
2018-06-06T08:27:43.000Z
2019-12-11T04:23:14.000Z
gan_server_api/serializers.py
luojie1024/HACK_GAN_img2img
a709cf7a88649584b05a4bd71bc3fbe8fa212646
[ "Apache-2.0" ]
2
2018-10-23T07:11:51.000Z
2019-05-18T01:20:47.000Z
gan_server_api/serializers.py
luojie1024/HACK_GAN_MB
a709cf7a88649584b05a4bd71bc3fbe8fa212646
[ "Apache-2.0" ]
3
2018-06-06T11:32:56.000Z
2019-04-10T05:35:46.000Z
# -*- coding: utf-8 -*- ''' # @Time : 5/23/18 11:14 AM # @Author : luojie # @File : serializers.py.py # @Desc : ''' from django.contrib.auth.models import User, Group from rest_framework import serializers class UserSerializer(serializers.HyperlinkedModelSerializer): class Meta: model = User fields = ('url', 'username', 'email', 'groups') class GroupSerializer(serializers.HyperlinkedModelSerializer): class Meta: model = Group fields = ('url', 'name')
22.217391
62
0.641879
54
511
6.055556
0.703704
0.2263
0.256881
0.281346
0.311927
0
0
0
0
0
0
0.025126
0.221135
511
22
63
23.227273
0.796482
0.228963
0
0.2
0
0
0.07513
0
0
0
0
0
0
1
0
false
0
0.2
0
0.6
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
03f1f9c096fd8d1032ecc1fdde32673bb7cd25b6
98
py
Python
custom_components/ds_air/__init__.py
kamingchan/ha-dsair
097f32d4feb67f043f93bcc0b50bdb3f24f5d522
[ "MIT" ]
7
2021-01-20T09:59:10.000Z
2022-01-30T16:49:37.000Z
custom_components/ds_air/__init__.py
kamingchan/ha-dsair
097f32d4feb67f043f93bcc0b50bdb3f24f5d522
[ "MIT" ]
null
null
null
custom_components/ds_air/__init__.py
kamingchan/ha-dsair
097f32d4feb67f043f93bcc0b50bdb3f24f5d522
[ "MIT" ]
3
2021-02-04T09:48:28.000Z
2021-06-12T09:37:42.000Z
""" Platform for DS-AIR of Daikin https://www.daikin-china.com.cn/newha/products/4/19/DS-AIR/ """
19.6
59
0.704082
18
98
3.833333
0.833333
0.144928
0
0
0
0
0
0
0
0
0
0.033333
0.081633
98
4
60
24.5
0.733333
0.908163
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
2061b42f8d840fb0464c230c74ade9d1444bf495
1,064
py
Python
yinwei/L4/ling-psutil.py
qsyPython/Python_play_now
278b6d5d30082f8f93b26902c854737c4919405a
[ "MIT" ]
2
2018-03-29T08:26:17.000Z
2019-06-17T10:56:19.000Z
yinwei/L4/ling-psutil.py
qsyPython/Python_play_now
278b6d5d30082f8f93b26902c854737c4919405a
[ "MIT" ]
1
2022-03-22T20:26:08.000Z
2022-03-22T20:26:08.000Z
yinwei/L4/ling-psutil.py
qsyPython/Python_play_now
278b6d5d30082f8f93b26902c854737c4919405a
[ "MIT" ]
1
2019-02-18T10:44:20.000Z
2019-02-18T10:44:20.000Z
#psutil是一个跨平台库(http://code.google.com/p/psutil/),能够轻松实现获取系统运行的进程和系统利用率(包括CPU、内存、磁盘、网络等)信息。它主要应用于系统监控,分析和限制系统资源及进程的管理 import psutil #使用cpu_times获取cpu的完整信息 #print(psutil.cpu_times())#scputimes(user=6157.05, nice=0.0, system=3130.85, idle=177492.17) #psutil.cpu_count()#获取cpu的逻辑个数 #print(psutil.cpu_count()) #8 #获取cpu的所有逻辑信息 #print(psutil.cpu_times_percent())#scputimes(user=0.0, nice=0.0, system=0.0, idle=0.0) #获取内存的所有信息 #print(psutil.virtual_memory())#svmem(total=17179869184, available=6949957632, percent=59.5, used=10303217664, free=5019918336, active=6379835392, inactive=1930039296, wired=1993342976) #获取磁盘的详细信息 #print(psutil.disk_partitions())#[sdiskpart(device='/dev/disk1', mountpoint='/', fstype='hfs', opts='rw,local,rootfs,dovolfs,journaled,multilabel')] #返回当前登录系统的用户信息 print(psutil.users()) #suser(name='yinwei', terminal='console', host=None, started=1526260224.0, pid=100), suser(name='yinwei', terminal='ttys000', host=None, started=1526268416.0, pid=785), suser(name='yinwei', terminal='ttys002', host=None, started=1526278912.0, pid=2704)]
46.26087
253
0.768797
146
1,064
5.547945
0.643836
0.081481
0.051852
0.085185
0
0
0
0
0
0
0
0.154455
0.050752
1,064
22
254
48.363636
0.647525
0.929511
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.5
0
0.5
0.5
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
0
1
0
4
208b10ccbcfdc7225ca4b1e2124121609c595d53
132
py
Python
test.py
steerapi/line-sticker-data
8ca82e86b3093e2e1fe04a5e8826579ba0c1a139
[ "MIT" ]
null
null
null
test.py
steerapi/line-sticker-data
8ca82e86b3093e2e1fe04a5e8826579ba0c1a139
[ "MIT" ]
null
null
null
test.py
steerapi/line-sticker-data
8ca82e86b3093e2e1fe04a5e8826579ba0c1a139
[ "MIT" ]
null
null
null
from linestickerdata import get_image_paths paths = get_image_paths(folder="dataofficial", n=5, num_workers=1, seed=0) print(paths)
33
74
0.810606
21
132
4.857143
0.761905
0.156863
0.254902
0
0
0
0
0
0
0
0
0.024793
0.083333
132
4
75
33
0.818182
0
0
0
0
0
0.090226
0
0
0
0
0
0
1
0
false
0
0.333333
0
0.333333
0.333333
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
208f0c9e3aba0a81b5b26e35733e09f2a813bb22
313
py
Python
HackerRank/BasicCalculator_master/BasicCalculator.py
Naga-kalyan/competitive_programming
e9501b16ac327c7f6700a0970d0804e1f9ef5f1b
[ "MIT" ]
8
2020-09-02T13:30:41.000Z
2022-01-31T07:45:31.000Z
HackerRank/BasicCalculator_master/BasicCalculator.py
Naga-kalyan/competitive_programming
e9501b16ac327c7f6700a0970d0804e1f9ef5f1b
[ "MIT" ]
null
null
null
HackerRank/BasicCalculator_master/BasicCalculator.py
Naga-kalyan/competitive_programming
e9501b16ac327c7f6700a0970d0804e1f9ef5f1b
[ "MIT" ]
1
2021-02-15T13:44:22.000Z
2021-02-15T13:44:22.000Z
T = int(input()) a=list(map(int,input().split())) for i in range(0,T): b = input() if(b == '+'): print(a[0]+a[1]) elif(b == '-'): print(a[0]-a[1]) elif(b == '*'): print(a[0]*a[1]) elif(b == '/'): print(a[0]//a[1]) elif(b == '%'): print(a[0]%a[1])
20.866667
32
0.373802
52
313
2.25
0.326923
0.25641
0.299145
0.34188
0.564103
0.564103
0.564103
0.564103
0.564103
0.564103
0
0.050926
0.309904
313
14
33
22.357143
0.490741
0
0
0
0
0
0.015974
0
0
0
0
0
0
1
0
false
0
0
0
0
0.357143
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
20985d39e9f1c5a2c3e60c77442ba83bb27fdf44
111
py
Python
tests/test_tools.py
rpatil524/mcfly
1bfdd58ad3b01b31250487fc820a031e1cc57ff7
[ "Apache-2.0" ]
356
2016-05-31T15:23:30.000Z
2022-03-30T22:15:36.000Z
tests/test_tools.py
rpatil524/mcfly
1bfdd58ad3b01b31250487fc820a031e1cc57ff7
[ "Apache-2.0" ]
250
2016-05-24T12:30:41.000Z
2022-02-02T16:38:06.000Z
tests/test_tools.py
rpatil524/mcfly
1bfdd58ad3b01b31250487fc820a031e1cc57ff7
[ "Apache-2.0" ]
92
2016-12-23T13:50:23.000Z
2022-02-02T14:19:00.000Z
import os def safe_remove(path): try: os.remove(path) except FileNotFoundError: pass
12.333333
29
0.612613
13
111
5.153846
0.769231
0.298507
0
0
0
0
0
0
0
0
0
0
0.315315
111
8
30
13.875
0.881579
0
0
0
0
0
0
0
0
0
0
0
0
1
0.166667
false
0.166667
0.166667
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
1
0
0
0
0
0
4
20e997c9712caa9d3af6c65263fff1bf37ccff95
94
py
Python
states_app/apps.py
germapat/states
1e18afb3695bc7135a7f8142f9ff58bd9a81bb70
[ "MIT" ]
null
null
null
states_app/apps.py
germapat/states
1e18afb3695bc7135a7f8142f9ff58bd9a81bb70
[ "MIT" ]
3
2020-02-12T01:10:25.000Z
2021-06-10T21:45:01.000Z
states_app/apps.py
germapat/states
1e18afb3695bc7135a7f8142f9ff58bd9a81bb70
[ "MIT" ]
null
null
null
from django.apps import AppConfig class StatesAppConfig(AppConfig): name = 'states_app'
15.666667
33
0.765957
11
94
6.454545
0.909091
0
0
0
0
0
0
0
0
0
0
0
0.159574
94
5
34
18.8
0.898734
0
0
0
0
0
0.106383
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
4556f47479c4e2c53b821362e6bc84d5ce1cf926
179
py
Python
stats/management/commands/update_plots.py
openkamer/openkamer
732facf01f2bb4d1649b0c6892466ae9e0982bd6
[ "MIT" ]
33
2016-05-12T13:16:23.000Z
2022-03-11T10:21:26.000Z
stats/management/commands/update_plots.py
openkamer/openkamer
732facf01f2bb4d1649b0c6892466ae9e0982bd6
[ "MIT" ]
69
2016-05-23T15:35:39.000Z
2021-12-13T19:46:21.000Z
stats/management/commands/update_plots.py
openkamer/openkamer
732facf01f2bb4d1649b0c6892466ae9e0982bd6
[ "MIT" ]
5
2016-05-17T19:49:05.000Z
2020-06-09T13:37:25.000Z
from django.core.management.base import BaseCommand import stats.models class Command(BaseCommand): def handle(self, *args, **options): stats.models.Plot.create()
17.9
51
0.726257
22
179
5.909091
0.818182
0.169231
0
0
0
0
0
0
0
0
0
0
0.162011
179
9
52
19.888889
0.866667
0
0
0
0
0
0
0
0
0
0
0
0
1
0.2
false
0
0.4
0
0.8
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
456d4d7f04f366f6f8b543e1b26a7d4f2c3de725
175
py
Python
tests/Conveyor_test.py
kant/conveyr_py
1454c41add37bfc08f96113ec62e8d889c1f7db0
[ "Apache-2.0", "MIT" ]
null
null
null
tests/Conveyor_test.py
kant/conveyr_py
1454c41add37bfc08f96113ec62e8d889c1f7db0
[ "Apache-2.0", "MIT" ]
null
null
null
tests/Conveyor_test.py
kant/conveyr_py
1454c41add37bfc08f96113ec62e8d889c1f7db0
[ "Apache-2.0", "MIT" ]
null
null
null
import unittest from conveyr import Conveyor class ConveyrTest(unittest.TestCase): def test_1(self): conveyr = Conveyor() self.assertIsNotNone(conveyr)
17.5
37
0.714286
19
175
6.526316
0.684211
0
0
0
0
0
0
0
0
0
0
0.007246
0.211429
175
9
38
19.444444
0.891304
0
0
0
0
0
0
0
0
0
0
0
0.166667
1
0.166667
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
4570c81e2feaad256f36ee0a0fb9ffa91dc6e7e2
163
py
Python
problem0443.py
kmarcini/Project-Euler-Python
d644e8e1ec4fac70a9ab407ad5e1f0a75547c8d3
[ "BSD-3-Clause" ]
null
null
null
problem0443.py
kmarcini/Project-Euler-Python
d644e8e1ec4fac70a9ab407ad5e1f0a75547c8d3
[ "BSD-3-Clause" ]
null
null
null
problem0443.py
kmarcini/Project-Euler-Python
d644e8e1ec4fac70a9ab407ad5e1f0a75547c8d3
[ "BSD-3-Clause" ]
null
null
null
########################### # # #443 GCD sequence - Project Euler # https://projecteuler.net/problem=443 # # Code by Kevin Marciniak # ###########################
18.111111
38
0.466258
14
163
5.428571
0.928571
0
0
0
0
0
0
0
0
0
0
0.041667
0.116564
163
8
39
20.375
0.486111
0.570552
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
1
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
4
45896ad170203d7edf771d9c908c4da7b7223934
410
py
Python
switchbot_hub/switchbot/abstract_bot_controller.py
masato-ka/switchbot-hub
1bf5b07f25b6a668bd226aeafdea1e4531a5870c
[ "MIT" ]
1
2019-10-10T16:26:17.000Z
2019-10-10T16:26:17.000Z
switchbot_hub/switchbot/abstract_bot_controller.py
masato-ka/switchbot-hub
1bf5b07f25b6a668bd226aeafdea1e4531a5870c
[ "MIT" ]
null
null
null
switchbot_hub/switchbot/abstract_bot_controller.py
masato-ka/switchbot-hub
1bf5b07f25b6a668bd226aeafdea1e4531a5870c
[ "MIT" ]
null
null
null
#! /usr/bin/env python3 # -*- coding: utf-8 -*- from abc import ABCMeta, abstractmethod class AbstractBotController(metaclass=ABCMeta): @abstractmethod def press_switch(self): pass @abstractmethod def turn_on_switch(self): pass @abstractmethod def turn_off_switch(self): pass @abstractmethod def get_device_info(self): return (None, None)
17.083333
47
0.653659
45
410
5.8
0.622222
0.260536
0.16092
0.321839
0.386973
0.268199
0
0
0
0
0
0.006536
0.253659
410
23
48
17.826087
0.846405
0.107317
0
0.5
0
0
0
0
0
0
0
0
0
1
0.285714
false
0.214286
0.071429
0.071429
0.5
0
0
0
0
null
1
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
1
0
0
0
0
0
4
458ac923e91d74968aafd792f27445c11c2da736
85
py
Python
deep_vision/models_helpers/AbstractModel.py
sharpcodex/deep-vision
f9d87a9eccc927590ceb9e8a4dd15bc85c6fd43b
[ "MIT" ]
1
2020-04-20T21:40:58.000Z
2020-04-20T21:40:58.000Z
deep_vision/models_helpers/AbstractModel.py
sharpcodex/deep-vision
f9d87a9eccc927590ceb9e8a4dd15bc85c6fd43b
[ "MIT" ]
null
null
null
deep_vision/models_helpers/AbstractModel.py
sharpcodex/deep-vision
f9d87a9eccc927590ceb9e8a4dd15bc85c6fd43b
[ "MIT" ]
null
null
null
class AbstractModel: def predict(self, image): raise NotImplementedError
21.25
33
0.717647
8
85
7.625
1
0
0
0
0
0
0
0
0
0
0
0
0.223529
85
3
34
28.333333
0.924242
0
0
0
0
0
0
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
45cb8959f7efa455ac2b9eec34144a0b79376888
86
py
Python
sdp/course/apps.py
irsisyphus/sdp
8d7cf56a4f40458717d8796a3cfb1183fb6f7343
[ "MIT" ]
2
2017-02-27T07:58:09.000Z
2017-05-31T11:35:09.000Z
sdp/course/apps.py
irsisyphus/sdp
8d7cf56a4f40458717d8796a3cfb1183fb6f7343
[ "MIT" ]
null
null
null
sdp/course/apps.py
irsisyphus/sdp
8d7cf56a4f40458717d8796a3cfb1183fb6f7343
[ "MIT" ]
1
2018-08-24T23:21:09.000Z
2018-08-24T23:21:09.000Z
from django.apps import AppConfig class CourseConfig(AppConfig): name = 'course'
17.2
33
0.755814
10
86
6.5
0.9
0
0
0
0
0
0
0
0
0
0
0
0.162791
86
4
34
21.5
0.902778
0
0
0
0
0
0.069767
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
aff0ff450f0f6739bba0cf0d732ed148cc060905
276
py
Python
backend/server_delta/server_delta_app/services/customer/customer_consumer_service.py
dalmarcogd/challenge_ms
761f0a588b4c309cf6e226d306df3609c1179b4c
[ "MIT" ]
null
null
null
backend/server_delta/server_delta_app/services/customer/customer_consumer_service.py
dalmarcogd/challenge_ms
761f0a588b4c309cf6e226d306df3609c1179b4c
[ "MIT" ]
13
2020-06-05T18:26:43.000Z
2021-06-10T20:36:13.000Z
backend/server_delta/server_delta_app/services/customer/customer_consumer_service.py
dalmarcogd/challenge_ms
761f0a588b4c309cf6e226d306df3609c1179b4c
[ "MIT" ]
null
null
null
from .customer_consumer_thread import CustomerConsumerThread class CustomerConsumerService(): def proccess_in_background(self, cpf): CustomerConsumerThread(cpf).start() def proccess(self, cpf): CustomerConsumerThread(cpf).consumer_services(cpf)
27.6
60
0.757246
26
276
7.846154
0.615385
0.107843
0.284314
0.313725
0
0
0
0
0
0
0
0
0.163043
276
10
61
27.6
0.883117
0
0
0
0
0
0
0
0
0
0
0
0
1
0.333333
false
0
0.166667
0
0.666667
0
1
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
1
0
0
0
0
0
0
0
4
b339ac12f7b339ab07d3b4da541129d4ffe4ee0c
393
py
Python
BIZa/2014/Tskipu_a_k/task_2_28.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
BIZa/2014/Tskipu_a_k/task_2_28.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
BIZa/2014/Tskipu_a_k/task_2_28.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
# Задача 2. Вариант 28. #Напишите программу, которая будет выводить на экран наиболее понравившееся вам высказывание, автором которого является Эпикур. Не забудьте о том, что автор должен быть упомянут на отдельной строке. # Цкипуришвили Александр # 25.05.2016 print("Каждый уходит из жизни так, словно только что вошел.") print("\n\t\t\t\t\t Эпикур") input("нажимте Enter для выхода")
43.666667
199
0.765903
59
393
5.101695
0.864407
0.026578
0.0299
0.026578
0
0
0
0
0
0
0
0.032934
0.150127
393
9
200
43.666667
0.868263
0.648855
0
0
0
0
0.714286
0
0
0
0
0
0
1
0
true
0
0
0
0
0.666667
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
1
0
null
0
0
0
0
0
0
1
0
0
0
0
1
0
4
b346a81302a67d33f35fada15f299c7426624dbd
12,367
py
Python
tests/profiler/resources/profiler_config_parser_utils.py
sophiayue1116/sagemaker-debugger
34a74e55b94b056654c2f91c94d2943d2440a05d
[ "Apache-2.0" ]
null
null
null
tests/profiler/resources/profiler_config_parser_utils.py
sophiayue1116/sagemaker-debugger
34a74e55b94b056654c2f91c94d2943d2440a05d
[ "Apache-2.0" ]
1
2021-06-25T15:47:58.000Z
2021-06-25T15:47:58.000Z
tests/profiler/resources/profiler_config_parser_utils.py
sophiayue1116/sagemaker-debugger
34a74e55b94b056654c2f91c94d2943d2440a05d
[ "Apache-2.0" ]
null
null
null
# Standard Library import re import time # First Party from smdebug.profiler.profiler_constants import ( CPROFILE_NAME, PROFILING_NUM_STEPS_DEFAULT, PYINSTRUMENT_NAME, ) from smdebug.profiler.python_profiler import cProfileTimer current_step = 3 current_time = time.time() good_start_step = 3 bad_start_step = 1 bad_start_step_2 = 5 num_steps = 2 good_start_time = current_time bad_start_time = current_time - 1000 duration = 500 # These test cases will primarily test the various combinations of start step, num steps, start_time, duration for # detailed profiling. Each test case consists of (detailed_profiling_parameters, expected_enabled, # expected_can_profile, expected_values) where: # - detailed_profiling_parameters refers to fields (if they exist, `None` otherwise) in the detailed profiling config, # i.e. (start_step, num_steps, start_time, duration) # - expected_enabled refers to whether detailed profiling is enabled (no errors parsing config). # - expected_can_profile refers to the expected value of should_save_metrics for detailed profiling # - expected_values refers to expected values of the profile range after parsing, i.e. # (start_step, end_step, start_time, end_time) detailed_profiling_test_cases = [ # Valid case where both start_step and num_steps are provided. Profiler starts at start_step and profiles for # num_steps steps. Profiler will profile current step. ( (good_start_step, num_steps, None, None), True, True, (good_start_step, good_start_step + num_steps, None, None), ), # Valid case where only start_step is provided. Profiler starts at start_step and profiles for # PROFILER_NUM_STEPS_DEFAULT steps. Profiler will profile current step. ( (good_start_step, None, None, None), True, True, (good_start_step, good_start_step + PROFILING_NUM_STEPS_DEFAULT, None, None), ), # Valid case where only num_steps is provided. Profiler starts at current_step and profiles for num_steps steps. # Profiler will profile current step. ( (None, num_steps, None, None), True, True, (current_step, current_step + num_steps, None, None), ), # Valid case where start_time and duration are provided. Profiler starts at start_time and profiles for duration # seconds. Profiler will profile current step. ( (None, None, good_start_time, duration), True, True, (None, None, good_start_time, good_start_time + duration), ), # Valid case where only start_time is provided. Profiler starts at start_time and profiles until the next step. # Profiler will profile current step. ( (None, None, good_start_time, None), True, True, (None, current_step + 1, good_start_time, None), ), # Valid case where only duration is provided. Profiler starts immediately and profiles for duration seconds. # Profiler will profile current step. ((None, None, None, duration), True, True, (None, None, current_time, current_time + duration)), # Valid case where detailed_profiling_enabled is True, but start_step is too small. Profiler starts at # bad_start_step and profiles for PROFILER_NUM_STEPS_DEFAULT steps. because # bad_start_step + PROFILER_NUM_STEPS_DEFAULT < current_step, Profiler does not profile current step. ( (bad_start_step, None, None, None), True, False, (bad_start_step, bad_start_step + PROFILING_NUM_STEPS_DEFAULT, None, None), ), # Valid case where detailed_profiling_enabled is True, but start_time is too small. Profiler starts at start time # and profiles for duration seconds. because bad_start_time + duration is before the current time, Profiler does # not profile current step. ( (None, None, bad_start_time, duration), True, False, (None, None, bad_start_time, bad_start_time + duration), ), # Invalid case where both step and time fields are provided, which is not allowed. No detailed profiling takes # place. ( (good_start_step, num_steps, good_start_time, duration), False, False, (good_start_step, None, good_start_time, None), ), ] # These test cases will primarily test the various combinations of start step, metrics_regex and metrics_name for # dataloader profiling. Each test case consists of (dataloader_parameters, expected_enabled, expected_can_profile, # expected_values) where: # - dataloader_parameters refers to fields (if they exist, `None` otherwise) in the dataloader metrics config, # i.e. (start_step, metrics_regex, metrics__name) # - expected_enabled refers to whether dataloader metrics collection is enabled (no errors parsing config). # - expected_can_profile refers to the expected value should_save_metrics for dataloader # - expected_values refers to expected values of the profile range after parsing, i.e. # (start_step, end_step, metrics_regex) dataloader_test_cases = [ # Valid case where start step and metrics regex are provided. Metrics collection is done for the current step for # the given metrics name. ( (good_start_step, "Dataloader:Event", "Dataloader:Event1"), True, True, ( good_start_step, good_start_step + PROFILING_NUM_STEPS_DEFAULT, re.compile("dataloader:event"), ), ), # Valid case where start step and metrics regex are provided. Metrics collection is done for the current step, but # not for the given metrics name since the regex didn't match the name. ( (good_start_step, "Dataloader:Event2", "Dataloader:Event1"), True, False, (good_start_step, None, re.compile("dataloader:event2")), ), # Valid case where start step is provided. Metrics collection is done for the current step for the given metrics # name. ( (good_start_step, None, "Dataloader:Event1"), True, True, (good_start_step, good_start_step + PROFILING_NUM_STEPS_DEFAULT, re.compile(".*")), ), # Invalid case where start step and metrics regex are provided, but the metrics regex is invalid. No dataloader # metrics collection is done. ((good_start_step, "*", "Dataloader:Event1"), False, False, (None, None, None)), ] # These test cases will primarily test the various combinations of start step, num steps, profiler name and cprofile # timer for python profiling. Each test case consists of (python_profiling_parameters, expected_enabled, # expected_can_profile, expected_values) where: # - python_profiling_parameters refers to fields (if they exist, `None` otherwise) in the python profiling config, # i.e. (start_step, num_steps, profiler_name, cprofile_timer) # - expected_enabled refers to whether python profiling is enabled (no errors parsing config). # - expected_can_profile refers to the expected value hould_save_metrics for python profiling # - expected_values refers to expected values of the profile range after parsing, i.e. # (start_step, end_step, profiler_name, cprofile_timer) python_profiling_test_cases = [ # Valid case where step fields, profiler name and cprofile timer are specified. Profiler starts at start step and # profiles for num_steps steps with cProfile measuring off cpu time. Profiler will profile current step. ( (good_start_step, num_steps, CPROFILE_NAME, cProfileTimer.OFF_CPU_TIME.value), True, True, (good_start_step, good_start_step + num_steps, CPROFILE_NAME, cProfileTimer.OFF_CPU_TIME), ), # Valid case where only step fields are provided. Profiler starts at start_step and profiles for num_steps steps # with cProfile measuring total time. Profiler will profile current step. ( (good_start_step, num_steps, None, None), True, True, (good_start_step, good_start_step + num_steps, CPROFILE_NAME, cProfileTimer.TOTAL_TIME), ), # Valid case where step fields and cprofile timer are provided. Profiler starts at start_step and profiles for # num_steps steps with cProfile measuring cpu time. Profiler will profile current step. ( (good_start_step, num_steps, None, cProfileTimer.CPU_TIME.value), True, True, (good_start_step, good_start_step + num_steps, CPROFILE_NAME, cProfileTimer.CPU_TIME), ), # Valid case where step fields and profiler name are provided. Profiler starts at start_step and profiles for # num_steps steps with Pyinstrument. Profiler will profile current step. ( (good_start_step, num_steps, PYINSTRUMENT_NAME, None), True, True, (good_start_step, good_start_step + num_steps, PYINSTRUMENT_NAME, None), ), # Valid case where step fields, profiler name and cprofile timer are provided. Profiler starts at start_step and # profiles for num_steps steps with Pyinstrument (since use pyinstrument is True, cprofile timer is ignored). # Profiler will profile current step. ( (good_start_step, num_steps, PYINSTRUMENT_NAME, cProfileTimer.CPU_TIME.value), True, True, (good_start_step, good_start_step + num_steps, PYINSTRUMENT_NAME, None), ), # Invalid case where profiler name and cprofile timer are provided. No step or time range has been provided, so # profiler does not profile current step. ( (None, None, CPROFILE_NAME, cProfileTimer.CPU_TIME.value), True, False, (None, None, CPROFILE_NAME, cProfileTimer.CPU_TIME), ), # Invalid case where step fields and profiler name are provided, but the profiler name is invalid. No python # profiling takes place. ( (good_start_step, num_steps, "bad_profiler_name", None), False, False, (None, None, None, None), ), # Invalid case where step fields and cprofile timer are provided, but the cprofile timer is invalid. No python # profiling takes place. ( (good_start_step, num_steps, CPROFILE_NAME, "bad_cprofile_timer"), False, False, (None, None, None, None), ), ] # These test cases will primarily test the various combinations of start step, num steps that are unique to herring # profiling. Each test case consists of (herring_profiling_parameters, expected_profiling_enabled, # expected_can_profile, expected_values) where: # - smdataparallel_profiling_parameters refers to fields (if they exist, `None` otherwise) in the smdataparallel profiling config, # i.e. (start_step, num_steps) # - expected_profiling_enabled refers to whether herring profiling is enabled (no errors parsing config). # - expected_can_profile refers to the expected value of should_save_metrics for herring profiling # - expected_values refers to expected values of the profile range after parsing, i.e. # (start_step, end_step) smdataparallel_profiling_test_cases = [ # Valid case where both start_step and num_steps are provided. Profiler starts at start_step and profiles for # num_steps steps. Profiler will profile current step. ((good_start_step, num_steps), True, True, (good_start_step, good_start_step + num_steps)), # Valid case where only start_step is provided. Profiler starts at start_step and profiles for # PROFILER_NUM_STEPS_DEFAULT steps. Profiler will profile current step. ( (good_start_step, None), True, True, (good_start_step, good_start_step + PROFILING_NUM_STEPS_DEFAULT), ), # Valid case where only num_steps is provided. Profiler starts at current_step and profiles for num_steps steps. # Profiler will profile current step. ((None, num_steps), True, True, (current_step, current_step + num_steps)), # Valid case where detailed_profiling_enabled is True, but start_step is too small. Profiler starts at # bad_start_step and profiles for PROFILER_NUM_STEPS_DEFAULT steps. because # bad_start_step + PROFILING_NUM_STEPS_DEFAULT < current_step, Profiler does not profile current step. ( (bad_start_step_2, None), True, False, (bad_start_step_2, bad_start_step_2 + PROFILING_NUM_STEPS_DEFAULT), ), ]
47.749035
132
0.71715
1,665
12,367
5.101502
0.081081
0.089004
0.06275
0.046032
0.805274
0.750648
0.714151
0.686956
0.641983
0.61255
0
0.002371
0.215735
12,367
258
133
47.934109
0.873389
0.596588
0
0.440252
0
0
0.035131
0
0
0
0
0
0
1
0
false
0
0.025157
0
0.025157
0
0
0
0
null
0
0
0
1
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
0
0
0
0
0
0
0
0
0
4
2fa4eeea6a9139a5768dd5087fab241b402a5164
177
py
Python
spleeter.py
magemongo/my_karaoke
17c836769a17db303ac7bb4703fb11adc79e6fde
[ "MIT" ]
null
null
null
spleeter.py
magemongo/my_karaoke
17c836769a17db303ac7bb4703fb11adc79e6fde
[ "MIT" ]
null
null
null
spleeter.py
magemongo/my_karaoke
17c836769a17db303ac7bb4703fb11adc79e6fde
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Sun May 30 12:32:54 2021 @author: anton """ import os os.system('cmd /c spleeter separate audio/veu_de_flores.mp3 -o /output')
17.7
72
0.632768
29
177
3.793103
0.965517
0
0
0
0
0
0
0
0
0
0
0.099291
0.20339
177
10
72
17.7
0.680851
0.418079
0
0
0
0
0.678161
0.264368
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
0
0
0
0
0
0
0
0
0
1
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
4
2fe4654d874fd2edd55cfbcbc3d191bb4e519754
170
py
Python
Python diye Programming sekha 2nd/Tracking mails.py
mitul3737/My-Python-Programming-journey-from-Beginning-to-Data-Sciene-Machine-Learning-AI-Deep-Learning
ca2c15c597a64e5a7689ba3a44ce36a1c0828194
[ "MIT" ]
1
2021-05-02T20:30:33.000Z
2021-05-02T20:30:33.000Z
Python diye Programming sekha 2nd/Tracking mails.py
Mit382/My-Python-Programming-Journey-from-Beginning-to-Data-Sciene-Machine-Learning-AI-Deep-Learning
c19d84dfe6dcf496ff4527724f92e228579b6456
[ "MIT" ]
null
null
null
Python diye Programming sekha 2nd/Tracking mails.py
Mit382/My-Python-Programming-Journey-from-Beginning-to-Data-Sciene-Machine-Learning-AI-Deep-Learning
c19d84dfe6dcf496ff4527724f92e228579b6456
[ "MIT" ]
1
2021-05-02T20:30:29.000Z
2021-05-02T20:30:29.000Z
text="Email us for any feedback here: shahriyarmitul3737@gmail.com py.book@subeen.com book_py@subeen.com thank you" import re print(re.findall(r'[.\w]+@\w+[.]\w+',text))
56.666667
116
0.729412
30
170
4.1
0.7
0.146341
0
0
0
0
0
0
0
0
0
0.025641
0.082353
170
3
117
56.666667
0.762821
0
0
0
0
0.333333
0.730994
0.163743
0
0
0
0
0
1
0
false
0
0.333333
0
0.333333
0.333333
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
1
1
0
null
0
0
0
0
0
0
0
0
1
0
0
0
0
4
643bf3396ae5af0451074b67d9795716fbf55c42
192
py
Python
lib_rovpp/policies/rovpp_v2a_policy.py
iReynaldo/lib_rovpp
eb201adc948e9375123c2e2301ee524392dd7b0d
[ "BSD-3-Clause" ]
1
2021-12-05T07:42:35.000Z
2021-12-05T07:42:35.000Z
lib_rovpp/policies/rovpp_v2a_policy.py
iReynaldo/lib_rovpp
eb201adc948e9375123c2e2301ee524392dd7b0d
[ "BSD-3-Clause" ]
null
null
null
lib_rovpp/policies/rovpp_v2a_policy.py
iReynaldo/lib_rovpp
eb201adc948e9375123c2e2301ee524392dd7b0d
[ "BSD-3-Clause" ]
null
null
null
from .rovpp_v2a_lite_policy import ROVPPV2aLitePolicy class ROVPPV2aPolicy(ROVPPV2aLitePolicy): name = "ROV++V2a" from .lite_converter import _new_ann_is_better, _best_by_hole_size
24
70
0.8125
25
192
5.76
0.8
0
0
0
0
0
0
0
0
0
0
0.02994
0.130208
192
7
71
27.428571
0.832335
0
0
0
0
0
0.041667
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
ff5745da043e6666b643e1e6762d48d96cde2e43
1,142
py
Python
website/context.py
jomono/dmarc-viewer
0ae8af4c57387884541f5b49132dc598783dafbe
[ "MIT" ]
45
2018-05-28T19:55:51.000Z
2022-01-21T12:49:05.000Z
website/context.py
jomono/dmarc-viewer
0ae8af4c57387884541f5b49132dc598783dafbe
[ "MIT" ]
14
2018-05-28T19:14:18.000Z
2020-06-05T18:32:56.000Z
website/context.py
jomono/dmarc-viewer
0ae8af4c57387884541f5b49132dc598783dafbe
[ "MIT" ]
12
2018-07-19T10:20:47.000Z
2021-07-20T11:50:57.000Z
""" <Program Name> context.py <Author> Lukas Puehringer <luk.puehringer@gmail.com> <Started> Nov 19, 2015 <Copyright> See LICENSE for licensing information. <Purpose> A simple template context processor to add additional data to the template context. Once a context processor is registered in the settings file, e.g.: ``` # in settings.py TEMPLATES = [ { ... 'OPTIONS': { 'context_processors': [ ..., 'website.context.options' ], }, }, ] ``` you can access the variable returned by the context processor function in a template, e.g.: ``` <!-- in base.html --> {% if TEMPLATE_SETTINGS.use_minified %} ``` More info at: https://docs.djangoproject.com/en/1.11/ref/templates/api/#writing-your-own-context-processors """ from django.conf import settings def options(request): """Adds TEMPLATE_SETTINGS variable initialized in settings.py to the template context. """ return { "TEMPLATE_SETTINGS" : settings.TEMPLATE_SETTINGS}
22.392157
97
0.596322
125
1,142
5.4
0.616
0.094815
0.038519
0.059259
0
0
0
0
0
0
0
0.011166
0.294221
1,142
51
98
22.392157
0.826303
0.875657
0
0
0
0
0.136
0
0
0
0
0
0
1
0.333333
false
0
0.333333
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
1
0
0
1
0
1
0
0
4
ff580b553685c8c94d3f66bfd26d72ed90182996
77
py
Python
UI/__init__.py
Manon-des-sources/-
6b82012786089a95fd7e69082dd54d826197544a
[ "MIT" ]
2
2021-03-24T01:59:37.000Z
2021-12-08T09:35:03.000Z
UI/__init__.py
Manon-des-sources/-
6b82012786089a95fd7e69082dd54d826197544a
[ "MIT" ]
null
null
null
UI/__init__.py
Manon-des-sources/-
6b82012786089a95fd7e69082dd54d826197544a
[ "MIT" ]
1
2020-05-28T08:14:22.000Z
2020-05-28T08:14:22.000Z
#!/user/bin/env python3 # 为了让其他目录的代码可以调用本目录下的模块、 # 在本目录下需要建立一个空文件__init__.py
19.25
27
0.805195
8
77
7.25
1
0
0
0
0
0
0
0
0
0
0
0.014085
0.077922
77
4
27
19.25
0.802817
0.922078
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
ff78bc69ffc4d6033e87be9cb4bf7353ea9a30d4
2,318
py
Python
ssi_views/urls.py
dldevinc/ssi-views
ddbc06a8f85b2275e212cd4632eb450211d029f6
[ "BSD-3-Clause" ]
1
2021-05-12T06:51:04.000Z
2021-05-12T06:51:04.000Z
ssi_views/urls.py
dldevinc/ssi-views
ddbc06a8f85b2275e212cd4632eb450211d029f6
[ "BSD-3-Clause" ]
null
null
null
ssi_views/urls.py
dldevinc/ssi-views
ddbc06a8f85b2275e212cd4632eb450211d029f6
[ "BSD-3-Clause" ]
null
null
null
import django from .registry import registry from .views import router if django.VERSION >= (2, 2): # noqa from django.urls import URLPattern, ResolverMatch from django.urls.resolvers import RegexPattern class SSIURLPattern(URLPattern): def resolve(self, path): match = self.pattern.match(path) if match: new_path, args, kwargs = match name = kwargs.pop('name') if name not in registry: return view = registry[name] return ResolverMatch( view, args, kwargs, self.pattern.name, route=str(self.pattern) ) def ssi_url(regex, view, kwargs=None, name=None): pattern = RegexPattern(regex, name=name, is_endpoint=True) return SSIURLPattern(pattern, view, kwargs, name) elif django.VERSION >= (2, 0): from django.urls import URLPattern, ResolverMatch from django.urls.resolvers import RegexPattern class SSIURLPattern(URLPattern): # type: ignore def resolve(self, path): match = self.pattern.match(path) if match: new_path, args, kwargs = match name = kwargs.pop('name') if name not in registry: return view = registry[name] return ResolverMatch(view, args, kwargs, self.pattern.name) def ssi_url(regex, view, kwargs=None, name=None): pattern = RegexPattern(regex, name=name, is_endpoint=True) return SSIURLPattern(pattern, view, kwargs, name) else: from django.core.urlresolvers import RegexURLPattern, ResolverMatch class SSIURLPattern(RegexURLPattern): # type: ignore def resolve(self, path): match = self.regex.search(path) if match: kwargs = match.groupdict() name = kwargs.pop('name') if name not in registry: return view = registry[name] return ResolverMatch(view, (), kwargs, self.name) def ssi_url(regex, view, kwargs=None, name=None): return SSIURLPattern(regex, view, kwargs, name) app_name = 'ssi_views' urlpatterns = [ ssi_url(r'(?P<name>[-\w.]+)/', router, name='router'), ]
33.114286
82
0.587575
252
2,318
5.365079
0.222222
0.051775
0.04142
0.039941
0.733728
0.733728
0.733728
0.733728
0.698965
0.698965
0
0.002528
0.317515
2,318
69
83
33.594203
0.852086
0.012942
0
0.636364
0
0
0.019702
0
0
0
0
0
0
1
0.109091
false
0
0.145455
0.018182
0.472727
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
ff7a2b84087d93d1a2dec2d783de9e0c0b13e188
1,606
py
Python
cryptofolio/schema/user_account/__init__.py
JerryBeGood/Cryptofolio
7f09bdbb823e4aa70d8c83532264857e550d1c84
[ "MIT" ]
null
null
null
cryptofolio/schema/user_account/__init__.py
JerryBeGood/Cryptofolio
7f09bdbb823e4aa70d8c83532264857e550d1c84
[ "MIT" ]
2
2022-01-20T11:54:33.000Z
2022-01-21T07:13:30.000Z
cryptofolio/schema/user_account/__init__.py
JerryBeGood/Cryptofolio
7f09bdbb823e4aa70d8c83532264857e550d1c84
[ "MIT" ]
null
null
null
from ariadne import load_schema_from_path from ariadne.objects import ObjectType from cryptofolio.resolvers import user_account user_account_type_defs = load_schema_from_path( 'cryptofolio/schema/user_account') user_account_mutation = ObjectType("Mutation") user_account_mutation.set_field('signUp', user_account.sign_up_resolver) user_account_mutation.set_field('activateAccount', user_account.activate_account_resolver) user_account_mutation.set_field('generateActivationCode', user_account.generate_activation_code_resolver) user_account_mutation.set_field('signIn', user_account.sign_in_resolver) user_account_mutation.set_field('accountStatus', user_account.account_status_resolver) user_account_mutation.set_field('addExchange', user_account.add_exchange_resolver) user_account_mutation.set_field('generatePswdRecoveryCode', user_account.generate_pswd_recovery_code_resolver) user_account_mutation.set_field('recoverPassword', user_account.recover_password_resolver) user_account_mutation.set_field('deleteAccount', user_account.delete_account_resolver) user_account_mutation.set_field('changePassword', user_account.change_password_resolver) user_account_mutation.set_field('deleteExchange', user_account.delete_exchange_resolver)
48.666667
82
0.688667
159
1,606
6.440252
0.283019
0.279297
0.222656
0.236328
0.405273
0.378906
0.242188
0
0
0
0
0
0.25467
1,606
32
83
50.1875
0.855472
0
0
0
0
0
0.119626
0.047975
0
0
0
0
0
1
0
false
0.142857
0.107143
0
0.107143
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
ffb5c35d5e7685c15667eb25c482f4ac07fe8174
192
py
Python
venv/lib/python3.8/site-packages/crispy_forms/templates/bootstrap/uni_formset.html.py
Solurix/Flashcards-Django
03c863f6722936093927785a2b20b6b668bb743d
[ "MIT" ]
1
2021-05-16T03:20:23.000Z
2021-05-16T03:20:23.000Z
venv/lib/python3.8/site-packages/crispy_forms/templates/bootstrap/uni_formset.html.py
Solurix/Flashcards-Django
03c863f6722936093927785a2b20b6b668bb743d
[ "MIT" ]
4
2021-03-30T14:06:09.000Z
2021-09-22T19:26:31.000Z
venv/lib/python3.8/site-packages/crispy_forms/templates/bootstrap/uni_formset.html.py
Solurix/Flashcards-Django
03c863f6722936093927785a2b20b6b668bb743d
[ "MIT" ]
null
null
null
BBBB BBBBBBBBBBBBBBBBBBBBBBB BB BBBB BBBBBBB BBBBBBBBBBBBBBBBBBBBBBBBB BBBBBBB BBB BBBB BB BBBBBBB XXXX XXXXXXXXXXXXXXXXXXX BBBBBBB BBBBBBBBBBBBBBBBBBBBBBBBB XXXXXX BBBBBB
21.333333
41
0.807292
17
192
9.117647
0.588235
0.412903
0
0
0
0
0
0
0
0
0
0
0.192708
192
8
42
24
1
0
0
0.25
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
446901b4c52c0a9bfb62fe49f0b9989e911ead84
59
py
Python
pydsp/__main__.py
capn-freako/PyDSP
0a59dab4e2e2bd559fc3fbf8e0cd5376752ff7ed
[ "BSD-2-Clause" ]
null
null
null
pydsp/__main__.py
capn-freako/PyDSP
0a59dab4e2e2bd559fc3fbf8e0cd5376752ff7ed
[ "BSD-2-Clause" ]
null
null
null
pydsp/__main__.py
capn-freako/PyDSP
0a59dab4e2e2bd559fc3fbf8e0cd5376752ff7ed
[ "BSD-2-Clause" ]
3
2015-07-27T03:01:26.000Z
2022-02-13T11:00:17.000Z
from pydsp import * PyDSP().configure_traits(view=view1)
11.8
36
0.762712
8
59
5.5
0.875
0
0
0
0
0
0
0
0
0
0
0.019231
0.118644
59
4
37
14.75
0.826923
0
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
4484648eba7dc6f7215c3185e39edb309e2b1112
164
py
Python
tasks/_constants.py
webtweakers/deploy
59c1c95ca3e0efb6c228f6ad35937a29e28aa6ae
[ "MIT" ]
4
2021-07-01T15:39:09.000Z
2022-03-29T21:26:36.000Z
tasks/_constants.py
webtweakers/deploy
59c1c95ca3e0efb6c228f6ad35937a29e28aa6ae
[ "MIT" ]
null
null
null
tasks/_constants.py
webtweakers/deploy
59c1c95ca3e0efb6c228f6ad35937a29e28aa6ae
[ "MIT" ]
null
null
null
RED = '\033[1;91m' GREEN = '\033[1;92m' YELLOW = '\033[1;93m' BLUE = '\033[1;94m' BROWN = '\033[1;95m' CYAN = '\033[1;96m' WHITE = '\033[1;97m' COL_END = '\033[0m'
18.222222
21
0.567073
32
164
2.875
0.59375
0.304348
0
0
0
0
0
0
0
0
0
0.328571
0.146341
164
8
22
20.5
0.328571
0
0
0
0
0
0.469512
0
0
0
0
0
0
1
0
false
0
0
0
0
0
0
0
0
null
1
0
0
0
0
0
0
0
0
0
1
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
922aa68254f6d7d6532202c61b2f31eff7a47b69
184
py
Python
tests/test_controller.py
bigbirdcode/cliptools
992ddf2088462477992734af8eb00453bde3ce85
[ "MIT" ]
null
null
null
tests/test_controller.py
bigbirdcode/cliptools
992ddf2088462477992734af8eb00453bde3ce85
[ "MIT" ]
6
2019-04-02T18:25:35.000Z
2019-08-21T20:24:16.000Z
tests/test_controller.py
bigbirdcode/cliptools
992ddf2088462477992734af8eb00453bde3ce85
[ "MIT" ]
null
null
null
"""ClipTools clipboard manager and text processing tools with a lines based GUI interface Test Controller part, driving the GUI and the Data """ # Placeholder for future tests pass
16.727273
56
0.782609
27
184
5.333333
0.888889
0
0
0
0
0
0
0
0
0
0
0
0.173913
184
10
57
18.4
0.947368
0.918478
0
0
0
0
0
0
0
0
0
0
0
1
0
true
1
0
0
0
0
1
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
1
0
0
0
0
0
4
923693ed05b2f57559fdbff3b87d19451832c0e9
2,964
py
Python
api/db/models/user.py
bharadwaj-pendyala/opentestdata-api
ff388ff2dd6d43f45e11cb5689d06ba257b23f09
[ "MIT" ]
null
null
null
api/db/models/user.py
bharadwaj-pendyala/opentestdata-api
ff388ff2dd6d43f45e11cb5689d06ba257b23f09
[ "MIT" ]
null
null
null
api/db/models/user.py
bharadwaj-pendyala/opentestdata-api
ff388ff2dd6d43f45e11cb5689d06ba257b23f09
[ "MIT" ]
null
null
null
from werkzeug.security import generate_password_hash, check_password_hash from .. import db from .base import BaseModel from . import EmailConfirmationToken from sqlalchemy import exc class User(BaseModel): __tablename__ = 'users' # fields username = db.Column(db.String(80), unique=True, nullable=False) email = db.Column(db.String(120), unique=True, nullable=False) password_hash = db.Column(db.String(128)) bio = db.Column(db.String(220), nullable=False, default="") has_avatar = db.Column(db.Boolean(), default=False) # TODO if has_avatar is false, maybe we cache the gravatar image url? is_admin = db.Column(db.Boolean(), default=False) is_email_confirmed = db.Column(db.Boolean(), default=False) private_fields = ['is_admin', 'is_email_confirmed', 'created_at', 'updated_at'] public_fields = ['username', 'avatar_url', 'bio'] # relationships ec_token = db.relationship('EmailConfirmationToken', back_populates='user', uselist=False) data = db.relationship('Datum', back_populates='author', uselist=True) actions = db.relationship('Action', back_populates='user', uselist=True) def __repr__(self): return '<User %s>' % self.username @property def avatar_url(self): # TODO get url from cloud storage via id or maybe gravatar return "http://foo.com/img.png" def set_password(self, password): self.password_hash = generate_password_hash(password) def check_password(self, password): return check_password_hash(self.password_hash, password) def has_access_to_field(self, user, field): # users always have access to their own data if user.id == self.id: return True return False def to_obj(self, *args, **kwargs): obj = super().to_obj(*args, **kwargs) obj['data'] = list(map(lambda d: d.to_obj(*args, **kwargs), self.data)) return obj def update_email(self, email, commit=False): if self.ec_token: db.session.delete(self.ec_token) token = EmailConfirmationToken() token.generate_token() self.email = email self.is_email_confirmed = False self.ec_token = token if commit: db.session.commit() @staticmethod def create(username, email, password, bio, is_admin=False): # TODO add avatar upload here? token = EmailConfirmationToken() token.generate_token() user = User(username=username, email=email, is_admin=is_admin, ec_token=token, bio=bio) user.set_password(password) db.session.add(user) db.session.add(token) try: db.session.commit() except exc.IntegrityError as e: db.session.rollback() raise e # TODO email confirmation process should actually send an e-mail at this point! return user
34.870588
87
0.64946
372
2,964
5.018817
0.330645
0.044992
0.037493
0.03428
0.094805
0.046599
0
0
0
0
0
0.004904
0.243252
2,964
84
88
35.285714
0.827463
0.099528
0
0.096774
1
0
0.057873
0.008268
0
0
0
0.011905
0
1
0.129032
false
0.129032
0.080645
0.048387
0.548387
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
1
0
0
0
0
1
0
0
1
0
0
4
9236f5297281ae19756168b9e88975f013ae6e2f
103
py
Python
contentmanager/apps.py
x-risk/x-risk
b4fc0dd91bf98725f87dded5e535eba0166c18f2
[ "MIT" ]
5
2020-07-31T22:11:39.000Z
2022-02-10T17:50:34.000Z
contentmanager/apps.py
x-risk/x-risk
b4fc0dd91bf98725f87dded5e535eba0166c18f2
[ "MIT" ]
8
2020-07-21T12:54:01.000Z
2022-02-10T01:22:09.000Z
contentmanager/apps.py
x-risk/x-risk
b4fc0dd91bf98725f87dded5e535eba0166c18f2
[ "MIT" ]
null
null
null
from django.apps import AppConfig class ContentmanagerConfig(AppConfig): name = 'contentmanager'
17.166667
38
0.786408
10
103
8.1
0.9
0
0
0
0
0
0
0
0
0
0
0
0.145631
103
5
39
20.6
0.920455
0
0
0
0
0
0.135922
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
92377892c0a92a51fb2b6e13df5f252ed44bc537
578
py
Python
synthrl/common/value/value.py
kupl/synthrl
0cd9b523e7df66099a344e3307ad8c5517450a5f
[ "MIT" ]
7
2020-08-24T09:18:01.000Z
2021-12-13T04:30:10.000Z
synthrl/common/value/value.py
kupl/synthrl
0cd9b523e7df66099a344e3307ad8c5517450a5f
[ "MIT" ]
12
2020-08-31T09:51:32.000Z
2020-11-27T05:34:50.000Z
synthrl/common/value/value.py
kupl/synthrl
0cd9b523e7df66099a344e3307ad8c5517450a5f
[ "MIT" ]
2
2020-08-24T05:19:25.000Z
2020-11-24T07:44:00.000Z
from abc import ABC from abc import abstractmethod from synthrl.common.utils import classproperty class Value(ABC): @classproperty @classmethod @abstractmethod def N_VALUE(cls): pass def __init__(self, value): self.value = value @classmethod @abstractmethod def sample(cls): pass @abstractmethod def __eq__(self, other): pass def __ne__(self, other): return not self == other def __str__(self): return repr(self) def __repr__(self): return repr(self.value) @property @abstractmethod def index(self): pass
15.210526
46
0.690311
71
578
5.323944
0.380282
0.179894
0.068783
0.095238
0
0
0
0
0
0
0
0
0.224913
578
38
47
15.210526
0.84375
0
0
0.357143
0
0
0
0
0
0
0
0
0
1
0.285714
false
0.142857
0.107143
0.107143
0.535714
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
926c8c86068d9f21f744a07f24c9cc50bf86fbe3
10,164
py
Python
python/kwiver/vital/tests/test_covariance.py
mwoehlke-kitware/kwiver
614a488bd2b7fe551ac75eec979766d882709791
[ "BSD-3-Clause" ]
176
2015-07-31T23:33:37.000Z
2022-03-21T23:42:44.000Z
python/kwiver/vital/tests/test_covariance.py
mwoehlke-kitware/kwiver
614a488bd2b7fe551ac75eec979766d882709791
[ "BSD-3-Clause" ]
1,276
2015-05-03T01:21:27.000Z
2022-03-31T15:32:20.000Z
python/kwiver/vital/tests/test_covariance.py
mwoehlke-kitware/kwiver
614a488bd2b7fe551ac75eec979766d882709791
[ "BSD-3-Clause" ]
85
2015-01-25T05:13:38.000Z
2022-01-14T14:59:37.000Z
""" ckwg +31 Copyright 2016-2020 by Kitware, Inc. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither name of Kitware, Inc. nor the names of any contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ============================================================================== Tests for Vital python Covariance class """ from __future__ import print_function import unittest import nose.tools import numpy as np from kwiver.vital.types.covariance import Covar2d, Covar2f, Covar3d, Covar3f, Covar4d, Covar4f class TestVitalCovariance(unittest.TestCase): def test_new_identity(self): # Valid dimensions and types c = Covar2d() print("constructed matrix:\n", c.matrix()) c = Covar3d() print("constructed matrix:\n", c.matrix()) c = Covar4d() print("constructed matrix:\n", c.matrix()) c = Covar2f() print("constructed matrix:\n", c.matrix()) c = Covar3f() print("constructed matrix:\n", c.matrix()) c = Covar4f() print("constructed matrix:\n", c.matrix()) def test_new_scalar(self): c = Covar2d(2.0) print("constructed matrix:\n", c.matrix()) c = Covar3d(2.0) print("constructed matrix:\n", c.matrix()) c = Covar4d(2.0) print("constructed matrix:\n", c.matrix()) c = Covar2f(2.0) print("constructed matrix:\n", c.matrix()) c = Covar3f(2.0) print("constructed matrix:\n", c.matrix()) c = Covar4f(2.0) print("constructed matrix:\n", c.matrix()) c = Covar2d(14.675) print("constructed matrix:\n", c.matrix()) c = Covar3d(14.675) print("constructed matrix:\n", c.matrix()) c = Covar4d(14.675) print("constructed matrix:\n", c.matrix()) c = Covar2f(14.675) print("constructed matrix:\n", c.matrix()) c = Covar3f(14.675) print("constructed matrix:\n", c.matrix()) c = Covar4f(14.675) print("constructed matrix:\n", c.matrix()) def test_new_matrix(self): m = np.array([[1, 1], [1, 1]]) c = Covar2d(m) m_out = c.matrix() print("input matrix:\n", m) print("output matrix:\n", m_out) np.testing.assert_array_equal(m_out, m) # Type casting should be handled m = np.array([[1, 1], [1, 1]], dtype=np.float32) c = Covar2d(m) m_out = c.matrix() print("input matrix:\n", m) print("output matrix:\n", m_out) np.testing.assert_array_equal(m_out, m) # Any other numpy array of the correct shape should be acceptable m = np.ndarray((2, 2)) m[:] = 3.0 c = Covar2f(m) m_out = c.matrix() print("input matrix:\n", m) print("output matrix:\n", m_out) np.testing.assert_array_equal(m_out, m) # Diagonally congruent values should be averages when initializing with # matrix m = np.eye(3, dtype=np.double) m[0, 2] = 2.0 m_expected = m.copy() m_expected[0, 2] = 1.0 m_expected[2, 0] = 1.0 c = Covar3d(m) m_out = c.matrix() print("input matrix:\n", m) print("output matrix:\n", m_out) np.testing.assert_array_equal(m_out, m_expected) def test_get_value(self): m = np.ndarray((4, 4)) # [[ 0 2 4 6 ] [[ 0 5 10 15 ] # [ 8 10 12 14 ] -> should -> [ 5 10 15 20 ] # [ 16 18 20 22 ] [ 10 15 20 25 ] # [ 24 26 28 30 ]] [ 15 20 25 30 ]] m.reshape((16,))[:] = list(range(0, 32, 2)) c = Covar4d(m) # Test matrix upper triangle locations nose.tools.assert_equal(c[0, 0], 0) nose.tools.assert_equal(c[0, 1], 5) nose.tools.assert_equal(c[0, 2], 10) nose.tools.assert_equal(c[0, 3], 15) nose.tools.assert_equal(c[1, 1], 10) nose.tools.assert_equal(c[1, 2], 15) nose.tools.assert_equal(c[1, 3], 20) nose.tools.assert_equal(c[2, 2], 20) nose.tools.assert_equal(c[2, 3], 25) nose.tools.assert_equal(c[3, 3], 30) nose.tools.assert_equal(c[0, 1], c[1, 0]) nose.tools.assert_equal(c[0, 2], c[2, 0]) nose.tools.assert_equal(c[0, 3], c[3, 0]) nose.tools.assert_equal(c[1, 2], c[2, 1]) nose.tools.assert_equal(c[1, 3], c[3, 1]) nose.tools.assert_equal(c[2, 3], c[3, 2]) c = Covar4f(m) # Test matrix upper triangle locations nose.tools.assert_equal(c[0, 0], 0) nose.tools.assert_equal(c[0, 1], 5) nose.tools.assert_equal(c[0, 2], 10) nose.tools.assert_equal(c[0, 3], 15) nose.tools.assert_equal(c[1, 1], 10) nose.tools.assert_equal(c[1, 2], 15) nose.tools.assert_equal(c[1, 3], 20) nose.tools.assert_equal(c[2, 2], 20) nose.tools.assert_equal(c[2, 3], 25) nose.tools.assert_equal(c[3, 3], 30) nose.tools.assert_equal(c[0, 1], c[1, 0]) nose.tools.assert_equal(c[0, 2], c[2, 0]) nose.tools.assert_equal(c[0, 3], c[3, 0]) nose.tools.assert_equal(c[1, 2], c[2, 1]) nose.tools.assert_equal(c[1, 3], c[3, 1]) nose.tools.assert_equal(c[2, 3], c[3, 2]) def test_get_oob(self): # 2x2 covariance mat c = Covar2d() _ = c[0, 0] # Valid access nose.tools.assert_raises(IndexError, c.__getitem__, (0, 2)) nose.tools.assert_raises(IndexError, c.__getitem__, (-1, 0)) c = Covar2f() _ = c[0, 0] # Valid access nose.tools.assert_raises(IndexError, c.__getitem__, (0, 2)) nose.tools.assert_raises(IndexError, c.__getitem__, (-1, 0)) def test_set(self): m = np.ndarray((4, 4)) # [[ 0 2 4 6 ] [[ 0 5 10 15 ] # [ 8 10 12 14 ] -> should -> [ 5 10 15 20 ] # [ 16 18 20 22 ] [ 10 15 20 25 ] # [ 24 26 28 30 ]] [ 15 20 25 30 ]] m.reshape((16,))[:] = list(range(0, 32, 2)) c = Covar4d(m) # modify some locations c[0, 1] = 1 c[2, 2] = 3 # Test matrix upper triangle locations nose.tools.assert_equal(c[0, 0], 0) nose.tools.assert_equal(c[0, 1], 1) nose.tools.assert_equal(c[0, 2], 10) nose.tools.assert_equal(c[0, 3], 15) nose.tools.assert_equal(c[1, 1], 10) nose.tools.assert_equal(c[1, 2], 15) nose.tools.assert_equal(c[1, 3], 20) nose.tools.assert_equal(c[2, 2], 3) nose.tools.assert_equal(c[2, 3], 25) nose.tools.assert_equal(c[3, 3], 30) nose.tools.assert_equal(c[0, 1], c[1, 0]) nose.tools.assert_equal(c[0, 2], c[2, 0]) nose.tools.assert_equal(c[0, 3], c[3, 0]) nose.tools.assert_equal(c[1, 2], c[2, 1]) nose.tools.assert_equal(c[1, 3], c[3, 1]) nose.tools.assert_equal(c[2, 3], c[3, 2]) # Set in upper triangle and see it reflect in lower c[0, 2] = 42 nose.tools.assert_equal(c[2, 0], 42) # Change something in lower triangle and see it reflected in upper c[2, 1] = 43 nose.tools.assert_equal(c[1, 2], 43) # FLOAT c = Covar4f(m) # modify some locations c[0, 1] = 1 c[2, 2] = 3 # Test matrix upper triangle locations nose.tools.assert_equal(c[0, 0], 0) nose.tools.assert_equal(c[0, 1], 1) nose.tools.assert_equal(c[0, 2], 10) nose.tools.assert_equal(c[0, 3], 15) nose.tools.assert_equal(c[1, 1], 10) nose.tools.assert_equal(c[1, 2], 15) nose.tools.assert_equal(c[1, 3], 20) nose.tools.assert_equal(c[2, 2], 3) nose.tools.assert_equal(c[2, 3], 25) nose.tools.assert_equal(c[3, 3], 30) nose.tools.assert_equal(c[0, 1], c[1, 0]) nose.tools.assert_equal(c[0, 2], c[2, 0]) nose.tools.assert_equal(c[0, 3], c[3, 0]) nose.tools.assert_equal(c[1, 2], c[2, 1]) nose.tools.assert_equal(c[1, 3], c[3, 1]) nose.tools.assert_equal(c[2, 3], c[3, 2]) # Set in upper triangle and see it reflect in lower c[0, 2] = 42 nose.tools.assert_equal(c[2, 0], 42) # Change something in lower triangle and see it reflected in upper c[2, 1] = 43 nose.tools.assert_equal(c[1, 2], 43) def test_set_oob(self): # 2x2 covariance mat c = Covar2f() c[0, 0] = 1 # Valid set nose.tools.assert_raises(IndexError, c.__setitem__, (0, 2), 1) nose.tools.assert_raises(IndexError, c.__setitem__, (-1, 0), 1) c = Covar2d() c[0, 0] = 1 # Valid set nose.tools.assert_raises(IndexError, c.__setitem__, (0, 2), 1) nose.tools.assert_raises(IndexError, c.__setitem__, (-1, 0), 1)
37.505535
94
0.577922
1,557
10,164
3.675016
0.152858
0.121112
0.199231
0.237679
0.710066
0.696435
0.688046
0.683852
0.637539
0.557497
0
0.07708
0.276269
10,164
270
95
37.644444
0.700788
0.267513
0
0.769663
0
0
0.067774
0
0
0
0
0
0.449438
1
0.039326
false
0
0.02809
0
0.073034
0.151685
0
0
0
null
0
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
null
0
0
0
1
0
0
0
0
0
0
0
0
0
4
92999b1dcd2acbbe8626b303cfb74b75ded4f4d4
147
py
Python
examples/tpa2016_simpletest.py
sommersoft/Adafruit_CircuitPython_TPA2016
6571d0739df0c8f31414441706b2ee1082503716
[ "MIT" ]
null
null
null
examples/tpa2016_simpletest.py
sommersoft/Adafruit_CircuitPython_TPA2016
6571d0739df0c8f31414441706b2ee1082503716
[ "MIT" ]
null
null
null
examples/tpa2016_simpletest.py
sommersoft/Adafruit_CircuitPython_TPA2016
6571d0739df0c8f31414441706b2ee1082503716
[ "MIT" ]
null
null
null
import busio import board import adafruit_tpa2016 i2c = busio.I2C(board.SCL, board.SDA) tpa = adafruit_tpa2016.TPA2016(i2c) tpa.fixed_gain = -16
16.333333
37
0.782313
23
147
4.869565
0.521739
0.267857
0
0
0
0
0
0
0
0
0
0.131783
0.122449
147
8
38
18.375
0.736434
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
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
92a34517ec6eaed77214cb96e9fee02c8b563680
28
py
Python
homeassistant/components/yamaha/__init__.py
domwillcode/home-assistant
f170c80bea70c939c098b5c88320a1c789858958
[ "Apache-2.0" ]
30,023
2016-04-13T10:17:53.000Z
2020-03-02T12:56:31.000Z
homeassistant/components/yamaha/__init__.py
jagadeeshvenkatesh/core
1bd982668449815fee2105478569f8e4b5670add
[ "Apache-2.0" ]
31,101
2020-03-02T13:00:16.000Z
2022-03-31T23:57:36.000Z
homeassistant/components/yamaha/__init__.py
jagadeeshvenkatesh/core
1bd982668449815fee2105478569f8e4b5670add
[ "Apache-2.0" ]
11,956
2016-04-13T18:42:31.000Z
2020-03-02T09:32:12.000Z
"""The yamaha component."""
14
27
0.642857
3
28
6
1
0
0
0
0
0
0
0
0
0
0
0
0.107143
28
1
28
28
0.72
0.75
0
null
0
null
0
0
null
0
0
0
null
1
null
true
0
0
null
null
null
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
92acbec0dee8327a8954e718ced043083c7ceb07
66
py
Python
Python/CV/practice_image.py
vbsteja/code
0c8f4dc579f5de21b6c55fe6e65c3c8eb5473687
[ "Apache-2.0" ]
null
null
null
Python/CV/practice_image.py
vbsteja/code
0c8f4dc579f5de21b6c55fe6e65c3c8eb5473687
[ "Apache-2.0" ]
null
null
null
Python/CV/practice_image.py
vbsteja/code
0c8f4dc579f5de21b6c55fe6e65c3c8eb5473687
[ "Apache-2.0" ]
null
null
null
import cv2 as cv image = cv.imread("jurassic-park-tour-jeep.jpg")
22
48
0.742424
12
66
4.083333
0.916667
0
0
0
0
0
0
0
0
0
0
0.016949
0.106061
66
3
48
22
0.813559
0
0
0
0
0
0.402985
0.402985
0
0
0
0
0
1
0
false
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
1
null
0
0
0
0
0
0
0
0
1
0
0
0
0
4
2b7dcbd0ecfe534f8894fedfc77786e2f7267a8a
46
py
Python
29/02/5.py
pylangstudy/201705
c69de524faa67fa2d96267d5a51ed9794208f0e4
[ "CC0-1.0" ]
null
null
null
29/02/5.py
pylangstudy/201705
c69de524faa67fa2d96267d5a51ed9794208f0e4
[ "CC0-1.0" ]
38
2017-05-25T07:08:48.000Z
2017-05-31T01:42:41.000Z
29/02/5.py
pylangstudy/201705
c69de524faa67fa2d96267d5a51ed9794208f0e4
[ "CC0-1.0" ]
null
null
null
a = 'True!!' if True else 'False...' print(a)
15.333333
36
0.565217
8
46
3.25
0.75
0
0
0
0
0
0
0
0
0
0
0
0.173913
46
2
37
23
0.684211
0
0
0
0
0
0.304348
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
2bcc0807222452be5cdc5380f61055232032ec90
101
py
Python
auditlog_tests/apps.py
washdrop/django-auditlog
b0717a52d3883a03f0f0ddcc7b5329924a81c423
[ "MIT" ]
252
2020-09-23T13:32:49.000Z
2022-03-29T18:38:59.000Z
auditlog_tests/apps.py
washdrop/django-auditlog
b0717a52d3883a03f0f0ddcc7b5329924a81c423
[ "MIT" ]
121
2020-09-23T12:56:39.000Z
2022-03-31T06:59:09.000Z
auditlog_tests/apps.py
washdrop/django-auditlog
b0717a52d3883a03f0f0ddcc7b5329924a81c423
[ "MIT" ]
89
2020-09-25T07:22:52.000Z
2022-03-29T07:59:35.000Z
from django.apps import AppConfig class AuditlogTestConfig(AppConfig): name = "auditlog_tests"
16.833333
36
0.782178
11
101
7.090909
0.909091
0
0
0
0
0
0
0
0
0
0
0
0.148515
101
5
37
20.2
0.906977
0
0
0
0
0
0.138614
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
2bea204df6bbe0093583f0b468788cce6f4a0d33
412
py
Python
running_modes/transfer_learning/logging/transfer_learning_logger.py
marco-foscato/Lib-INVENT
fe6a65ab7165abd87b25752a6b4208c8703d11f7
[ "Apache-2.0" ]
26
2021-04-30T23:21:17.000Z
2022-03-10T06:33:11.000Z
running_modes/transfer_learning/logging/transfer_learning_logger.py
marco-foscato/Lib-INVENT
fe6a65ab7165abd87b25752a6b4208c8703d11f7
[ "Apache-2.0" ]
6
2021-10-03T08:35:48.000Z
2022-03-24T09:57:39.000Z
running_modes/transfer_learning/logging/transfer_learning_logger.py
marco-foscato/Lib-INVENT
fe6a65ab7165abd87b25752a6b4208c8703d11f7
[ "Apache-2.0" ]
10
2021-04-28T14:08:17.000Z
2022-03-04T04:18:13.000Z
from running_modes.transfer_learning.logging.local_transfer_learning_logger import LocalTransferLearningLogger from running_modes.transfer_learning.logging.base_transfer_learning_logger import BaseTransferLearningLogger class TransferLearningLogger: def __new__(cls, logging_path: str, weights: bool=False) -> BaseTransferLearningLogger: return LocalTransferLearningLogger(logging_path, weights)
41.2
110
0.86165
41
412
8.268293
0.560976
0.188791
0.094395
0.141593
0.230089
0.230089
0
0
0
0
0
0
0.089806
412
9
111
45.777778
0.904
0
0
0
0
0
0
0
0
0
0
0
0
1
0.2
false
0
0.4
0.2
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
0
0
1
1
1
0
0
4
920dbf71aec29dfad4e88ea2b95c4242c0bc06d6
27
py
Python
plugins/builtin/help/__init__.py
Alternative-Profit/Ubot
529514307c5431144fd56f6aba928dce1e880d93
[ "Apache-2.0" ]
1
2022-01-04T11:36:06.000Z
2022-01-04T11:36:06.000Z
plugins/builtin/help/__init__.py
Alternative-Profit/Ubot
529514307c5431144fd56f6aba928dce1e880d93
[ "Apache-2.0" ]
1
2022-01-08T20:18:50.000Z
2022-01-08T20:18:50.000Z
plugins/builtin/help/__init__.py
Alternative-Profit/Ubot
529514307c5431144fd56f6aba928dce1e880d93
[ "Apache-2.0" ]
3
2022-01-08T20:10:47.000Z
2022-03-12T08:09:32.000Z
"""docs of all commands"""
13.5
26
0.62963
4
27
4.25
1
0
0
0
0
0
0
0
0
0
0
0
0.148148
27
1
27
27
0.73913
0.740741
0
null
0
null
0
0
null
0
0
0
null
1
null
true
0
0
null
null
null
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
9212dec5bf8ac4d39ccfd338820ac3a49671c273
1,433
py
Python
src/camguard/bridge_impl.py
matt-hires/camguard
dde59289b8af105b8ed7ef1d8619747528c5b0a3
[ "MIT" ]
3
2021-12-06T18:26:12.000Z
2022-01-14T10:22:12.000Z
src/camguard/bridge_impl.py
matt-hires/camguard
dde59289b8af105b8ed7ef1d8619747528c5b0a3
[ "MIT" ]
null
null
null
src/camguard/bridge_impl.py
matt-hires/camguard
dde59289b8af105b8ed7ef1d8619747528c5b0a3
[ "MIT" ]
null
null
null
from abc import ABC, abstractmethod from typing import Any, Callable, List # Handler Bridge class MotionHandlerImpl(ABC): """abstract base class for motion handler implementations """ @abstractmethod def handle_motion(self) -> Any: pass @abstractmethod def shutdown(self) -> None: pass @property @abstractmethod def id(self) -> int: pass # Detector Bridge class MotionDetectorImpl(ABC): """abstract base class for motion detector implementations """ @abstractmethod def register_handler(self, handler: Callable[..., None]) -> None: pass @abstractmethod def shutdown(self) -> None: pass @property @abstractmethod def id(self) -> int: pass # FileStorage Bridge class FileStorageImpl(ABC): """abstract base class for file storage implementations """ @abstractmethod def authenticate(self) -> None: pass @abstractmethod def start(self) -> None: pass @abstractmethod def stop(self) -> None: pass @abstractmethod def enqueue_files(self, files: List[str]) -> None: pass @property @abstractmethod def id(self) -> int: pass class MailClientImpl(ABC): """abstract base class for mail notification implementations """ @abstractmethod def send_mail(self, files: List[str]) -> None: pass
18.139241
69
0.628053
145
1,433
6.17931
0.296552
0.227679
0.117188
0.089286
0.485491
0.337054
0.227679
0.227679
0.227679
0.176339
0
0
0.279135
1,433
78
70
18.371795
0.867377
0.203768
0
0.711111
0
0
0
0
0
0
0
0
0
1
0.266667
false
0.266667
0.044444
0
0.4
0
0
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
null
0
0
0
0
0
1
0
1
0
0
0
0
0
4
a63277f2a6f3b33c2f1f2f60d18be2a09728833e
123
py
Python
2. Implementation/19. The Hurdle Race.py
trentandraka/Hackerrank-Algorithm-Solutions
a352070b39589931d9ece35bac6b7680bdfee9eb
[ "MIT" ]
null
null
null
2. Implementation/19. The Hurdle Race.py
trentandraka/Hackerrank-Algorithm-Solutions
a352070b39589931d9ece35bac6b7680bdfee9eb
[ "MIT" ]
5
2018-10-19T05:43:42.000Z
2018-10-24T09:05:55.000Z
2. Implementation/19. The Hurdle Race.py
trentandraka/Hackerrank-Algorithm-Solutions
a352070b39589931d9ece35bac6b7680bdfee9eb
[ "MIT" ]
22
2018-10-19T06:06:28.000Z
2021-04-15T00:28:11.000Z
n, k = map(int, input().split(' ')) arr = list(map(int, input().split(' '))) print ("0" if max(arr)-k<=0 else max(arr)-k)
24.6
44
0.552846
23
123
2.956522
0.565217
0.176471
0.323529
0.470588
0
0
0
0
0
0
0
0.019048
0.146341
123
4
45
30.75
0.628571
0
0
0
0
0
0.02439
0
0
0
0
0
0
1
0
false
0
0
0
0
0.333333
1
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
0
0
0
0
0
4
a650216f18ede7b81c36d61bbea4e6a84c0c3bc5
77
py
Python
csie/10compiler/4a/test.py
dk00/old-stuff
e1184684c85fe9bbd1ceba58b94d4da84c67784e
[ "Unlicense" ]
null
null
null
csie/10compiler/4a/test.py
dk00/old-stuff
e1184684c85fe9bbd1ceba58b94d4da84c67784e
[ "Unlicense" ]
null
null
null
csie/10compiler/4a/test.py
dk00/old-stuff
e1184684c85fe9bbd1ceba58b94d4da84c67784e
[ "Unlicense" ]
null
null
null
print 'int ', for i in range(1,65538): print 'a%d = %d,' % (i,i*2), print
12.833333
30
0.532468
16
77
2.5625
0.6875
0
0
0
0
0
0
0
0
0
0
0.116667
0.220779
77
5
31
15.4
0.566667
0
0
0
0
0
0.171053
0
0
0
0
0
0
0
null
null
0
0
null
null
0.75
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
a65e7e5ac2a5a6aaff5ef556d0b3182ec6fd3319
135
py
Python
images/test.py
Dmendoza3/Phyton
e6c563609724b2dadcd767d2bfc291090ac2f58e
[ "MIT" ]
null
null
null
images/test.py
Dmendoza3/Phyton
e6c563609724b2dadcd767d2bfc291090ac2f58e
[ "MIT" ]
null
null
null
images/test.py
Dmendoza3/Phyton
e6c563609724b2dadcd767d2bfc291090ac2f58e
[ "MIT" ]
null
null
null
x = 344444444 b0,b1,b2,b3 = [c for c in x.to_bytes(4,"big")] y = b0 << 24 | b1 << 16 | b2 << 8 | b3 << 0 print(b0,b1,b2,b3) print(y)
16.875
46
0.533333
31
135
2.290323
0.612903
0.112676
0.169014
0.225352
0
0
0
0
0
0
0
0.269231
0.22963
135
8
47
16.875
0.413462
0
0
0
0
0
0.022059
0
0
0
0
0
0
1
0
false
0
0
0
0
0.4
0
0
0
null
0
0
1
0
0
0
0
0
0
0
1
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
a66b00b11daf14ea285ab106d536593da5f09407
123
py
Python
data_salmon/dataset/__init__.py
htryppcook/data_salmon
8fecbba5db4433fa8472cd156bebde854b5eb692
[ "MIT" ]
null
null
null
data_salmon/dataset/__init__.py
htryppcook/data_salmon
8fecbba5db4433fa8472cd156bebde854b5eb692
[ "MIT" ]
null
null
null
data_salmon/dataset/__init__.py
htryppcook/data_salmon
8fecbba5db4433fa8472cd156bebde854b5eb692
[ "MIT" ]
null
null
null
from .dataset import Dataset from .output_formats import output_formats __all__ = [ 'Dataset', 'output_formats' ]
15.375
42
0.731707
14
123
5.928571
0.428571
0.46988
0
0
0
0
0
0
0
0
0
0
0.186992
123
8
43
15.375
0.83
0
0
0
0
0
0.170732
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
a67aa6d23239792cf5a910d9ba28d6c6aecbe284
419
py
Python
locators/login.py
rokimaru/selenium_opencart
b0a4ec0405e05d874111b284e609f7806289b9c2
[ "Apache-2.0" ]
null
null
null
locators/login.py
rokimaru/selenium_opencart
b0a4ec0405e05d874111b284e609f7806289b9c2
[ "Apache-2.0" ]
null
null
null
locators/login.py
rokimaru/selenium_opencart
b0a4ec0405e05d874111b284e609f7806289b9c2
[ "Apache-2.0" ]
null
null
null
from selenium.webdriver.common.by import By class LoginPageLocators: INPUT_EMAIL = (By.CSS_SELECTOR, "#input-email") INPUT_PASS = (By.CSS_SELECTOR, "#input-password") LOGIN_BUTTON = (By.CSS_SELECTOR, "input.btn") FORGOTTEN_PASSWORD = (By.XPATH, "//a[@class='list-group-item' and text()='Forgotten Password']") TRANSACTIONS = (By.XPATH, "//a[@class='list-group-item' and text()='Transactions']")
41.9
101
0.692124
54
419
5.240741
0.481481
0.053004
0.137809
0.190813
0.233216
0.233216
0.233216
0.233216
0.233216
0
0
0
0.131265
419
9
102
46.555556
0.777473
0
0
0
0
0
0.367542
0.186158
0
0
0
0
0
1
0
false
0.285714
0.142857
0
1
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
0
1
0
0
1
0
0
4
a67e98a5e60d9385ad52b609abb58c21b0d4f786
195
py
Python
app/characterbuilder/views.py
mohit4/Saga
fa2b9e2b557e8222b2b72028a448a3bec6a85e80
[ "MIT" ]
null
null
null
app/characterbuilder/views.py
mohit4/Saga
fa2b9e2b557e8222b2b72028a448a3bec6a85e80
[ "MIT" ]
null
null
null
app/characterbuilder/views.py
mohit4/Saga
fa2b9e2b557e8222b2b72028a448a3bec6a85e80
[ "MIT" ]
null
null
null
from django.shortcuts import render from django.views.generic import TemplateView # Create your views here. class HomePageView(TemplateView): """Home Page""" template_name = 'index.html'
27.857143
45
0.764103
24
195
6.166667
0.791667
0.135135
0
0
0
0
0
0
0
0
0
0
0.14359
195
7
46
27.857143
0.886228
0.174359
0
0
0
0
0.064103
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
a68e7dccf0dbdbdfbcef2539ec0696c8f8b2bec7
9,695
py
Python
v0/aia_eis_v0/ml_sl/svm/svm_ovr_main.py
DreamBoatOve/aia_eis
458b4d29846669b10db4da1b3e86c0b394614ceb
[ "MIT" ]
1
2022-03-02T12:57:19.000Z
2022-03-02T12:57:19.000Z
v0/aia_eis_v0/ml_sl/svm/svm_ovr_main.py
DreamBoatOve/aia_eis
458b4d29846669b10db4da1b3e86c0b394614ceb
[ "MIT" ]
null
null
null
v0/aia_eis_v0/ml_sl/svm/svm_ovr_main.py
DreamBoatOve/aia_eis
458b4d29846669b10db4da1b3e86c0b394614ceb
[ "MIT" ]
null
null
null
import sys sys.path.append('../../') from ml_sl.ml_critrions import cal_accuracy, cal_kappa from utils.file_utils.filename_utils import get_date_prefix from utils.file_utils.dataset_reader_pack.ml_dataset_reader import get_T_V_T_dataset from ml_sl.svm.multiclass_svm_0 import Multiclass_SVM """ SVM Linear Adjustable parameters: C: 1e-5 ~ 1e5, step factor 10 tol, default 0.01 max_iter: 1000 ~ 9000, step size 2000 Poly Adjustable parameters: C: 1e-5 ~ 1e5, step factor 10 tol, default 0.01 max_iter: 1000 ~ 9000, step size 2000 power: 2 ~ 10, step size 1 constant: default 1 qua_coe: 1e-5 ~ 1e5, step factor 10 Rbf Adjustable parameters: C: 1e-5 ~ 1e5, step factor 10 tol: default 0.01 max_iter: 1000 ~ 9000, step size 2000 sigma: 1e-5 ~ 1e5, step factor 10 """ training_dataset, validation_dataset, test_dataset = get_T_V_T_dataset(file_path='../../datasets/ml_datasets/normed') # ---------------- casual test of Multiclass-SVM (linear kernel)---------------- def svm_ovr_linear_tr_va(svm_para_dict, kernel_para_dict): global training_dataset, validation_dataset vali_data_list = [] vali_label_list = [] for vali in validation_dataset: vali_label_list.append(vali[0]) vali_data_list.append(vali[1]) multi_svm = Multiclass_SVM(svm_para_dict=svm_para_dict, kernel_para_dict=kernel_para_dict,\ unlabeled_dataset_list=vali_data_list, labeled_dataset_list=training_dataset,\ label_list=[2,4,5,6,7,8,9]) svm_model_pickle_name = get_date_prefix()+'svm_ovr_linear_test_pickle.file' multi_svm.create_svm_ovr_classifer(svm_model_pickle_name) sample_label_prob_dict_list = multi_svm.classify_ovr(svm_model_pickle_name) acc = cal_accuracy(sample_label_prob_dict_list, vali_label_list) kappa = cal_kappa(sample_label_prob_dict_list, vali_label_list) print('Accuracy={0}, Kappa={1}'.format(acc, kappa)) # if __name__ == '__main__': # svm_para_dict = {'C': 10, 'max_iter':1000} # kernel_para_dict = {'type':'linear', 'paras':None} # svm_ovr_linear_tr_va(svm_para_dict, kernel_para_dict) # R(RC)_IS_lin-kk_res.txt: Accuracy=0.13829787234042554, Kappa=0.01957249549317538 # ---------------- casual test of Multiclass-SVM (linear kernel)---------------- # ---------------- casual test of Multiclass-SVM (Poly kernel)---------------- def svm_ovr_poly_tr_va(svm_para_dict, kernel_para_dict): global training_dataset, validation_dataset vali_data_list = [] vali_label_list = [] for vali in validation_dataset: vali_label_list.append(vali[0]) vali_data_list.append(vali[1]) multi_svm = Multiclass_SVM(svm_para_dict=svm_para_dict, kernel_para_dict=kernel_para_dict,\ unlabeled_dataset_list=vali_data_list, labeled_dataset_list=training_dataset,\ label_list=[2,4,5,6,7,8,9]) svm_model_pickle_name = get_date_prefix()+'svm_ovr_poly_test_pickle.file' multi_svm.create_svm_ovr_classifer(svm_model_pickle_name) sample_label_prob_dict_list = multi_svm.classify_ovr(svm_model_pickle_name) acc = cal_accuracy(sample_label_prob_dict_list, vali_label_list) kappa = cal_kappa(sample_label_prob_dict_list, vali_label_list) print('Accuracy={0}, Kappa={1}'.format(acc, kappa)) # if __name__ == '__main__': # svm_para_dict = {'C': 10, 'max_iter':1000} # kernel_para_dict = {'type':'poly', 'paras':[2,1,1]} # svm_ovr_poly_tr_va(svm_para_dict, kernel_para_dict) # R(RC)_IS_lin-kk_res.txt: Accuracy=0.1276595744680851, Kappa=-0.020251489080079454 # ---------------- casual test of Multiclass-SVM (Poly kernel)---------------- # ---------------- casual test of Multiclass-SVM (Rbf kernel)---------------- def svm_ovr_rbf_tr_va(svm_para_dict, kernel_para_dict): global training_dataset, validation_dataset vali_data_list = [] vali_label_list = [] for vali in validation_dataset: vali_label_list.append(vali[0]) vali_data_list.append(vali[1]) multi_svm = Multiclass_SVM(svm_para_dict=svm_para_dict, kernel_para_dict=kernel_para_dict,\ unlabeled_dataset_list=vali_data_list, labeled_dataset_list=training_dataset,\ label_list=[2,4,5,6,7,8,9]) svm_model_pickle_name = get_date_prefix() + 'svm_ovr_rbf_test_pickle.file' multi_svm.create_svm_ovr_classifer(svm_model_pickle_name) sample_label_prob_dict_list = multi_svm.classify_ovr(svm_model_pickle_name) acc = cal_accuracy(sample_label_prob_dict_list, vali_label_list) kappa = cal_kappa(sample_label_prob_dict_list, vali_label_list) print('Accuracy={0}, Kappa={1}'.format(acc, kappa)) # if __name__ == '__main__': # svm_para_dict = {'C': 10, 'max_iter':1000} # kernel_para_dict = {'type':'rbf', 'paras': 10} # svm_ovr_rbf_tr_va(svm_para_dict, kernel_para_dict) # R(RC)_IS_lin-kk_res.txt: Accuracy=0.22340425531914893, Kappa=0.1066267413097253 # ---------------- casual test of Multiclass-SVM (Rbf kernel)---------------- # ---------------- Train SVM on TV and Test on Test-dataset ---------------- def svm_ovr_TV_te(svm_para_dict, kernel_para_dict): global training_dataset, validation_dataset, test_dataset TV_dataset = training_dataset + validation_dataset te_data_list = [] te_label_list = [] for te in test_dataset: te_label_list.append(te[0]) te_data_list.append(te[1]) # Repeat for 10 times for i in range(10): """ 2020_05_08_svm_linear_C=1e-05_iter=1000_pickle_0.file 2020_05_08_svm_poly_C=0.01_iter=1000_P=2_q=1_pickle_0.file 2020_05_08_svm_rbf_C=0.0001_iter=1000_sigma=0.0001_pickle_9.file """ multi_svm = Multiclass_SVM(svm_para_dict=svm_para_dict, kernel_para_dict=kernel_para_dict, \ unlabeled_dataset_list=te_data_list, labeled_dataset_list=TV_dataset, \ label_list=[2, 4, 5, 6, 7, 8, 9]) kernel_type = kernel_para_dict['type'] svm_model_pickle_name = get_date_prefix() if kernel_type == 'linear': C_str = str(svm_para_dict['C']) iter_str = str(svm_para_dict['max_iter']) svm_model_pickle_name += 'svm_ovr_final_{0}_C={1}_iter={2}_pickle_{3}.file'.format(kernel_type, C_str, iter_str, str(i)) elif kernel_type == 'poly': C_str = str(svm_para_dict['C']) iter_str = str(svm_para_dict['max_iter']) para_list = kernel_para_dict['paras'] q_str = str(para_list[1]) svm_model_pickle_name += 'svm_ovr_final_{0}_C={1}_iter={2}_q={3}_pickle_{4}.file'.format(kernel_type, C_str, iter_str, q_str, str(i)) elif kernel_type == 'rbf': C_str = str(svm_para_dict['C']) iter_str = str(svm_para_dict['max_iter']) sigma_str = str(kernel_para_dict['paras']) svm_model_pickle_name += 'svm_ovr_final_{0}_C={1}_iter={2}_sigma={3}_pickle_{4}.file'.format(kernel_type, C_str, sigma_str, iter_str, str(i)) multi_svm.create_svm_ovr_classifer(svm_model_pickle_name) sample_label_prob_dict_list = multi_svm.classify_ovr(svm_model_pickle_name) acc = cal_accuracy(sample_label_prob_dict_list, te_label_list) kappa = cal_kappa(sample_label_prob_dict_list, te_label_list) print('Accuracy={0}, Kappa={1}'.format(acc, kappa)) if __name__ == '__wmain__': # ---------------------- SVM_OvR-Linear ---------------------- # ------------- iter = 5000, C = 0.1 ------------- # svm_para_dict = {'C': 0.1, 'max_iter': 5000} # kernel_para_dict = {'type':'linear', 'paras':None} # svm_ovr_TV_te(svm_para_dict, kernel_para_dict) # ------------- iter = 5000, C = 0.1 ------------- # ---------------------- SVM_OvR-Linear ---------------------- # ---------------------- SVM_OvR-Poly ---------------------- # ------------- iter = 3000, C = 1, q = 100 ------------- # In poly, the power is default as 2, () ** q(=2); and the constant is default as 1 # svm_para_dict = {'C': 1, 'max_iter' : 3000} # kernel_para_dict = {'type' : 'poly', 'paras' : [2, 1, 100]} # svm_ovr_TV_te(svm_para_dict, kernel_para_dict) # ------------- iter = 3000, C = 1, q = 100 ------------- # ---------------------- SVM_OvR-Poly ---------------------- # ---------------------- SVM_OvR-RBF ---------------------- # ------------- iter = 7000, C = 0.01, sigma = 100000 ------------- # svm_para_dict = {'C' : 0.01, 'max_iter' : 7000} # kernel_para_dict = {'type' : 'rbf', 'paras' : 100000} # svm_ovr_TV_te(svm_para_dict, kernel_para_dict) # ------------- iter = 7000, C = 0.01, sigma = 100000 ------------- # ------------- iter = 5000, C = 0.001, sigma = 10 ------------- # svm_para_dict = {'C': 0.001, 'max_iter': 5000} # kernel_para_dict = {'type': 'rbf', 'paras': 10} # svm_ovr_TV_te(svm_para_dict, kernel_para_dict) # ------------- iter = 5000, C = 0.001, sigma = 10 ------------- # ------------- iter = 5000, C = 0.01, sigma = 0.001 ------------- svm_para_dict = {'C': 0.01, 'max_iter': 5000} kernel_para_dict = {'type': 'rbf', 'paras': 0.001} svm_ovr_TV_te(svm_para_dict, kernel_para_dict) # ------------- iter = 5000, C = 0.01, sigma = 0.001 ------------- # ---------------------- SVM_OvR-RBF ---------------------- # python svm_ovr_main.py # ---------------- Train SVM on TV and Test on Test-dataset ----------------
49.213198
153
0.620113
1,371
9,695
3.954778
0.102845
0.095906
0.068978
0.066396
0.815013
0.796201
0.759867
0.691627
0.670232
0.614902
0
0.061602
0.196287
9,695
197
154
49.213198
0.63424
0.31738
0
0.569892
0
0.021505
0.081457
0.049437
0
0
0
0
0
1
0.043011
false
0
0.053763
0
0.096774
0.043011
0
0
0
null
0
0
0
1
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
0
0
0
0
0
0
0
0
0
4
a6abe108e25f70e9849b7f6c804af61e7f5c0c73
218
py
Python
profiles/forms/quota_form.py
LaudateCorpus1/squest
98304f20c1d966fb3678d348ffd7c5be438bb6be
[ "Apache-2.0" ]
null
null
null
profiles/forms/quota_form.py
LaudateCorpus1/squest
98304f20c1d966fb3678d348ffd7c5be438bb6be
[ "Apache-2.0" ]
null
null
null
profiles/forms/quota_form.py
LaudateCorpus1/squest
98304f20c1d966fb3678d348ffd7c5be438bb6be
[ "Apache-2.0" ]
1
2022-03-24T03:37:12.000Z
2022-03-24T03:37:12.000Z
from Squest.utils.squest_model_form import SquestModelForm from profiles.models import Quota class QuotaForm(SquestModelForm): class Meta: model = Quota fields = ["name", "attribute_definitions"]
24.222222
58
0.738532
24
218
6.583333
0.708333
0
0
0
0
0
0
0
0
0
0
0
0.188073
218
8
59
27.25
0.892655
0
0
0
0
0
0.114679
0.09633
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
a6b280b3a28a600b1a22e6682b826ae7a3b47f60
61
py
Python
prom2teams/__init__.py
cloudstrike/prom2teams
5fb387f97bb4e44677ae8d3efcfc7200a8041eea
[ "Apache-2.0" ]
180
2017-09-04T21:07:00.000Z
2022-03-10T11:05:02.000Z
prom2teams/__init__.py
cloudstrike/prom2teams
5fb387f97bb4e44677ae8d3efcfc7200a8041eea
[ "Apache-2.0" ]
162
2017-08-24T08:54:33.000Z
2022-03-26T20:08:04.000Z
prom2teams/__init__.py
cloudstrike/prom2teams
5fb387f97bb4e44677ae8d3efcfc7200a8041eea
[ "Apache-2.0" ]
75
2017-11-08T11:04:31.000Z
2022-03-04T12:34:37.000Z
import os root = os.path.abspath(os.path.dirname(__file__))
15.25
49
0.754098
10
61
4.2
0.7
0.285714
0
0
0
0
0
0
0
0
0
0
0.098361
61
3
50
20.333333
0.763636
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
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
a6d1ece4f824494efdd649c8c5b26dd370cafa1f
555
py
Python
meiduo_mall/utils/fastdfs/storage.py
zzZaida/meiduo_backend
c4f94ea7f9c47a08d3e37fb0ac2c1ec1dcf2c18b
[ "MIT" ]
null
null
null
meiduo_mall/utils/fastdfs/storage.py
zzZaida/meiduo_backend
c4f94ea7f9c47a08d3e37fb0ac2c1ec1dcf2c18b
[ "MIT" ]
4
2020-05-11T20:27:56.000Z
2021-11-02T15:46:08.000Z
meiduo_mall/utils/fastdfs/storage.py
zzZaida/meiduo_backend
c4f94ea7f9c47a08d3e37fb0ac2c1ec1dcf2c18b
[ "MIT" ]
null
null
null
from django.core.files.storage import Storage class FastDFSStorage(Storage): """自定义文件存储系统""" def _save(self, name, content, max_length=None): pass def _open(self, name, mode='rb'): pass def url(self, name): # name=Remote file_id #'Remote file_id': 'group1/M00/00/02/wKjllFzhEE6AFbTWAALd0X8OZb4408.jpg', #http://192.168.229.148:8888/+group1/M00/00/02/wKjllFzhEE6AFbTWAALd0X8OZb4408.jpg # return 'http://192.168.229.148:8888/' + name return 'http://image.meiduo.site:8888/' + name
30.833333
89
0.648649
71
555
5
0.577465
0.067606
0.067606
0.073239
0.371831
0.371831
0
0
0
0
0
0.144796
0.203604
555
18
90
30.833333
0.658371
0.409009
0
0.25
0
0
0.1
0
0
0
0
0
0
1
0.375
false
0.25
0.125
0.125
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
1
0
1
0
1
1
0
0
4
a6d55f92462c093fe73c53ea9214e4919d54db57
8,339
py
Python
ml/rl/common.py
xiaoshenxian/mlxsx
a20558482f0d71bdd099aaff8be16ac29d4b98e2
[ "Apache-2.0" ]
2
2019-06-16T03:06:52.000Z
2019-06-21T03:38:12.000Z
ml/rl/common.py
xiaoshenxian/mlxsx
a20558482f0d71bdd099aaff8be16ac29d4b98e2
[ "Apache-2.0" ]
null
null
null
ml/rl/common.py
xiaoshenxian/mlxsx
a20558482f0d71bdd099aaff8be16ac29d4b98e2
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- import sys import time import tensorflow as tf import numpy as np class RLComponent: def get_eval_op(self): raise NotImplementedError('RLComponent::get_eval_op is not implemented!') def get_target_op(self): raise NotImplementedError('RLComponent::get_target_op is not implemented!') def get_replace_target_op(self): raise NotImplementedError('RLComponent::get_replace_target_op is not implemented!') def get_trainable_variables(self): raise NotImplementedError('RLComponent::get_trainable_variables is not implemented!') class RL: def choose_action(self, sess, random_threshold=1, prob_random_threshold=1, random_sigma=None): action_prob_list, continuous_action_list, action_lower, action_upper=sess.run([self.discrete_action_op, self.continuous_action_op, [], []] if random_threshold>=1 or random_sigma is None else [self.discrete_action_op, self.continuous_action_op, self.get_continuous_lower_op(), self.get_continuous_upper_op()]) discrete_action_list=[] for action_prob, num_actions in zip(action_prob_list, self.discrete_action_num_list): shape=action_prob.shape action_shape=shape[:-1] rand_score=np.random.uniform() action=np.where(rand_score<random_threshold , np.argmax(action_prob, axis=-1) , np.where(rand_score<random_threshold+(1-random_threshold)*prob_random_threshold , np.array([np.random.choice(num_actions, p=probs) for probs in np.reshape(action_prob, (-1, num_actions))], dtype='int32').reshape(action_shape) , np.random.randint(num_actions, size=np.prod(action_shape)).reshape(action_shape))) discrete_action_list.append(action) if random_sigma is not None: actions=continuous_action_list[0] shape=actions.shape rand=np.random.uniform(0, 1, size=np.prod(shape)).reshape(shape) idx=np.where(rand>=random_threshold) actions[idx]=np.random.normal(actions[idx], random_sigma) actions=np.transpose(actions, axes=[-1]+list(range(len(shape)-1))) sh=actions.shape actions=np.clip(actions.reshape((sh[0], -1)), action_lower.reshape((sh[0], 1)), action_upper.reshape((sh[0], 1))) actions=np.transpose(actions.reshape(sh), axes=list(range(1, len(sh)))+[0]) continuous_action_list=[actions] return discrete_action_list+continuous_action_list, action_prob_list def get_discrete_prob(self, sess): return sess.run(self.discrete_action_op) def choose_action_for_placeholder(self, sess, feed_dict, random_threshold=1, prob_random_threshold=1, random_sigma=None): action_prob_list, continuous_action_list, action_lower, action_upper=sess.run([self.discrete_action_op, self.continuous_action_op, [], []] if random_threshold>=1 or random_sigma is None else [self.discrete_action_op, self.continuous_action_op, self.get_continuous_lower_op(), self.get_continuous_upper_op()], feed_dict=feed_dict) discrete_action_list=[] for action_prob, num_actions in zip(action_prob_list, self.discrete_action_num_list): shape=action_prob.shape action_shape=shape[:-1] rand_score=np.random.uniform() action=np.where(rand_score<random_threshold , np.argmax(action_prob, axis=-1) , np.where(rand_score<random_threshold+(1-random_threshold)*prob_random_threshold , np.array([np.random.choice(num_actions, p=probs) for probs in np.reshape(action_prob, (-1, num_actions))], dtype='int32').reshape(action_shape) , np.random.randint(num_actions, size=np.prod(action_shape)).reshape(action_shape))) discrete_action_list.append(action) if random_sigma is not None: actions=continuous_action_list[0] shape=actions.shape rand=np.random.uniform(0, 1, size=np.prod(shape)).reshape(shape) idx=np.where(rand>=random_threshold) actions[idx]=np.random.normal(actions[idx], random_sigma) actions=np.transpose(actions, axes=[-1]+list(range(len(shape)-1))) sh=actions.shape actions=np.clip(actions.reshape((sh[0], -1)), action_lower.reshape((sh[0], 1)), action_upper.reshape((sh[0], 1))) actions=np.transpose(actions.reshape(sh), axes=list(range(1, len(sh)))+[0]) continuous_action_list=[actions] return discrete_action_list+continuous_action_list, action_prob_list def get_discrete_prob_for_placeholder(self, sess, feed_dict): return sess.run(self.discrete_action_op, feed_dict=feed_dict) def get_continuous_lower_op(self): raise NotImplementedError('RL::get_continuous_lower_op is not implemented!') def get_continuous_upper_op(self): raise NotImplementedError('RL::get_continuous_upper_op is not implemented!') def set_summary(self, sess, log_dir, verbose): self.summary=tf.summary.merge_all() self.summary_writer=tf.summary.FileWriter(log_dir, sess.graph) self.summary_verbose=verbose self.total_step=0 def run_summary(self, sess): if self.summary is not None: if self.total_step%self.summary_verbose==0: summary_str=sess.run(self.summary) self.summary_writer.add_summary(summary_str, self.total_step) sys.stderr.write('summary wrote at total_step={}\n'.format(self.total_step)) self.total_step+=1 def run_summary_for_placeholder(self, sess, feed_dict): if self.summary is not None: if self.total_step%self.summary_verbose==0: summary_str=sess.run(self.summary, feed_dict=feed_dict) self.summary_writer.add_summary(summary_str, self.total_step) sys.stderr.write('summary wrote at total_step={}\n'.format(self.total_step)) self.total_step+=1 def run_sess_and_cost(self, sess, for_training, iters): self.replace_target(sess, iters) res=sess.run([self.cost, self.train_op] if for_training else [self.cost]) return res[0] def run_sess_and_cost_for_placeholder(self, sess, for_training, iters, feed_dict): self.replace_target(sess, iters) res=sess.run([self.cost, self.train_op] if for_training else [self.cost], feed_dict=feed_dict) return res[0] def replace_target(self, sess, iters): raise NotImplementedError('RL::replace_target is not implemented!') def run_epoch(self, sess, for_training, verbose=-1): start_time=time.time() costs=0.0 iters=0 try: while True: self.run_summary(sess) cost=self.run_sess_and_cost(sess, for_training, iters) costs+=cost iters+=1 if verbose>=0 and iters%verbose==0: sys.stderr.write('step {0} avg cost: {1:.3f} current cost: {2:.3f} speed: {3:.0f} sps\n'.format(iters, costs/iters, cost, iters*self.batch_size/max(time.time()-start_time, 1))) except tf.errors.OutOfRangeError: pass return costs/(iters if iters!=0 else 1) def run_training(self, sess, verbose=-1): return self.run_epoch(sess, self.train_op, verbose) def run_epoch_for_placeholder(self, sess, data_iterator, for_training, verbose=-1): start_time=time.time() costs=0.0 iters=0 for step, (feed_dict) in enumerate(data_iterator): self.run_summary(sess) cost=self.run_sess_and_cost_for_placeholder(sess, for_training, iters, feed_dict) costs+=cost iters+=1 if verbose>=0 and step%verbose==0: print("step {0} avg cost: {1:.3f} current cost: {2:.3f} speed: {3:.0f} sps".format(step, costs/iters, cost, iters*self.batch_size/(time.time()-start_time))) return costs/(iters if iters!=0 else 1) def run_training_for_placeholder(self, sess, data_iterator, verbose=-1): return self.run_epoch_for_placeholder(sess, self.train_op, data_iterator, verbose)
51.475309
337
0.665907
1,134
8,339
4.645503
0.116402
0.045558
0.02221
0.02164
0.835042
0.805619
0.729689
0.657555
0.646925
0.646925
0
0.013403
0.221609
8,339
161
338
51.795031
0.798182
0.002518
0
0.560606
0
0.015152
0.065176
0.020924
0
0
0
0
0
1
0.151515
false
0.007576
0.030303
0.030303
0.272727
0.007576
0
0
0
null
0
0
0
1
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
0
0
0
0
0
0
0
0
0
4
5b74ceabe1f5ec5b3b97bbc34a184430690d5e12
184
py
Python
dace/libraries/pblas/nodes/__init__.py
Walon1998/dace
95ddfd3e9a5c654f0f0d66d026e0b64ec0f028a0
[ "BSD-3-Clause" ]
227
2019-03-15T23:39:06.000Z
2022-03-30T07:49:08.000Z
dace/libraries/pblas/nodes/__init__.py
Walon1998/dace
95ddfd3e9a5c654f0f0d66d026e0b64ec0f028a0
[ "BSD-3-Clause" ]
834
2019-07-31T22:49:31.000Z
2022-03-28T14:01:32.000Z
dace/libraries/pblas/nodes/__init__.py
Walon1998/dace
95ddfd3e9a5c654f0f0d66d026e0b64ec0f028a0
[ "BSD-3-Clause" ]
64
2019-03-19T05:40:37.000Z
2022-03-11T15:02:42.000Z
# Copyright 2019-2021 ETH Zurich and the DaCe authors. All rights reserved. from .pgemm import Pgemm from .pgeadd import BlockCyclicScatter, BlockCyclicGather from .pgemv import Pgemv
36.8
75
0.820652
25
184
6.04
0.76
0
0
0
0
0
0
0
0
0
0
0.050314
0.13587
184
4
76
46
0.899371
0.396739
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
5b7f74ef8c6a9d44de2851d8b7f832671e9f73c3
1,855
py
Python
st_like.py
XDASADX/InstaStatPy
1454486bfd0674a87a7ab02240eabb038b8bce4b
[ "Apache-2.0" ]
null
null
null
st_like.py
XDASADX/InstaStatPy
1454486bfd0674a87a7ab02240eabb038b8bce4b
[ "Apache-2.0" ]
null
null
null
st_like.py
XDASADX/InstaStatPy
1454486bfd0674a87a7ab02240eabb038b8bce4b
[ "Apache-2.0" ]
null
null
null
import re import requests import os code_addr='https://instagram.com/p/' #os.mkdir(os.getcwd()+'\\data') id='natgeo' d_f=open(os.getcwd()+'\\data\\'+'stat_'+id+'.csv','w') d_f.write('Instagram上'+id+'的统计\n') d_f.write('like'+'\n') r=requests.get('https://www.instagram.com/'+id+'/?hl=en') con=r.content start_i=r'"start_cursor":"[0-9]*"' end_i=r'end_cursor":"[0-9]*"' like=r'"likes":{"count":[0-9]*},"' code_i=r'{"code":"[\w\-]+"' start_cursor=re.findall(start_i,con.decode()) end_cursor=re.findall(end_i,con.decode()) like_list=re.findall(like,con.decode()) code_list=re.findall(code_i,con.decode()) start_var=start_cursor[0] start_var=start_var[16:-1] end_var=end_cursor[0] end_var=end_var[13:-1] like_list_f=[] code_list_f=[] print(code_list) print(len(code_list)) for i in range(0,len(like_list)): a=like_list[i] a=a[17:-3] like_list_f.append(a) d_f.write(a+',') b=code_list[i] b=b[9:-1] code_list_f.append(b) d_f.write(code_addr+b+'\n') pagenum=1 while(start_var!=end_var): print("Page",(pagenum),"has been counted.") pagenum+=1 r=requests.get('https://www.instagram.com/'+id+'/?max_id='+end_var) con=r.content start_i=r'"start_cursor":"[0-9]*"' end_i=r'end_cursor":"[0-9]*"' like=r'"likes":{"count":[0-9]*},"' code_i=r'{"code":"[\w\-]+"' start_cursor=re.findall(start_i,con.decode()) end_cursor=re.findall(end_i,con.decode()) like_list=re.findall(like,con.decode()) code_list=re.findall(code_i,con.decode()) start_var=start_cursor[0] start_var=start_var[16:-1] end_var=end_cursor[0] end_var=end_var[13:-1] for i in range(0,len(like_list)): a=like_list[i] a=a[17:-3] like_list_f.append(a) d_f.write(a+',') b=code_list[i] b=b[9:-1] code_list_f.append(b) d_f.write(code_addr+b+'\n') print (len(like_list_f)) d_f.write('=AVERAGE(A3:A'+str(len(like_list_f)+2)+')') d_f.close()
18.737374
68
0.669003
363
1,855
3.195592
0.192837
0.075862
0.042241
0.02931
0.715517
0.715517
0.715517
0.715517
0.656897
0.656897
0
0.025898
0.084097
1,855
98
69
18.928571
0.656857
0.016173
0
0.676923
0
0
0.191886
0.053728
0
0
0
0
0
1
0
false
0
0.046154
0
0.046154
0.061538
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
5ba5834a837b3b864c5e141c71c18be7c64a3028
99
py
Python
code_all/day15/my_project02/main.py
testcg/python
4db4bd5d0e44af807d2df80cf8c8980b40cc03c4
[ "MIT" ]
null
null
null
code_all/day15/my_project02/main.py
testcg/python
4db4bd5d0e44af807d2df80cf8c8980b40cc03c4
[ "MIT" ]
null
null
null
code_all/day15/my_project02/main.py
testcg/python
4db4bd5d0e44af807d2df80cf8c8980b40cc03c4
[ "MIT" ]
null
null
null
# from 包 import 类 from skill_system import SkillManager manager = SkillManager() manager.func01()
16.5
37
0.787879
13
99
5.923077
0.692308
0.493506
0
0
0
0
0
0
0
0
0
0.023529
0.141414
99
5
38
19.8
0.882353
0.151515
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
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
5bccd7e61ca8c853abd861f9c680bdfb7ad1d36b
97
py
Python
misclientes/apps.py
mrbrazzi/django-misclientes
8017cc67e243e4384c3f52ae73d06e16f8fb8d5b
[ "Apache-2.0" ]
5
2019-11-12T20:35:37.000Z
2022-03-11T15:02:48.000Z
misclientes/apps.py
mrbrazzi/django-misclientes
8017cc67e243e4384c3f52ae73d06e16f8fb8d5b
[ "Apache-2.0" ]
4
2019-11-11T15:33:42.000Z
2022-01-13T01:50:23.000Z
misclientes/apps.py
mrbrazzi/django-misclientes
8017cc67e243e4384c3f52ae73d06e16f8fb8d5b
[ "Apache-2.0" ]
4
2019-11-11T16:13:20.000Z
2020-04-02T18:32:06.000Z
from django.apps import AppConfig class MisclientesConfig(AppConfig): name = 'misclientes'
16.166667
35
0.773196
10
97
7.5
0.9
0
0
0
0
0
0
0
0
0
0
0
0.154639
97
5
36
19.4
0.914634
0
0
0
0
0
0.113402
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
5bcdf409d6844e51f9183ca141abd6b4d33b102b
184
py
Python
tests/test_compass.py
IQTLabs/gamutRF
f9d248581066f0f5175e60de63430a7d9ac5c97f
[ "Apache-2.0" ]
6
2021-09-30T21:14:45.000Z
2022-03-08T21:59:47.000Z
tests/test_compass.py
IQTLabs/gamutRF
f9d248581066f0f5175e60de63430a7d9ac5c97f
[ "Apache-2.0" ]
109
2021-10-19T21:04:59.000Z
2022-03-31T09:41:33.000Z
tests/test_compass.py
IQTLabs/gamutRF
f9d248581066f0f5175e60de63430a7d9ac5c97f
[ "Apache-2.0" ]
4
2021-09-28T17:09:03.000Z
2021-11-24T16:51:04.000Z
import sys import fake_rpi sys.modules['smbus2'] = fake_rpi.smbus from gamutrf import compass def test_compass_heading(): heading = compass.Heading() heading.get_heading()
15.333333
38
0.75
25
184
5.32
0.56
0.105263
0.315789
0
0
0
0
0
0
0
0
0.006452
0.157609
184
11
39
16.727273
0.851613
0
0
0
0
0
0.032609
0
0
0
0
0
0
1
0.142857
false
0.428571
0.428571
0
0.571429
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
0
1
1
0
0
0
0
4
5bd159b148fd0f04b6ddfcc92e7eb5f395f4e67d
3,505
py
Python
cmdb/forms.py
bopopescu/sbdb_new
52d57f2dd6e553f60a06c97e7a8631d41f8f2ea6
[ "Apache-2.0" ]
1
2018-12-27T02:30:44.000Z
2018-12-27T02:30:44.000Z
cmdb/forms.py
Moniter123/adminOps
810fb1400584cdff98df5b0f26e6d4cc922b34f1
[ "Apache-2.0" ]
null
null
null
cmdb/forms.py
Moniter123/adminOps
810fb1400584cdff98df5b0f26e6d4cc922b34f1
[ "Apache-2.0" ]
1
2020-07-22T02:38:14.000Z
2020-07-22T02:38:14.000Z
#! /usr/bin/env python # -*- coding: utf-8 -*- from django import forms from django.forms.widgets import * from .models import Host, Idc, HostGroup class AssetForm(forms.ModelForm): class Meta: model = Host exclude = ("id",) widgets = { 'hostname': TextInput(attrs={'class': 'form-control', 'style': 'width:530px;', 'placeholder': u'必填项'}), 'ip': TextInput(attrs={'class': 'form-control', 'style': 'width:530px;', 'placeholder': u'必填项'}), 'other_ip': TextInput(attrs={'class': 'form-control', 'style': 'width:530px;'}), 'group': Select(attrs={'class': 'form-control', 'style': 'width:530px;'}), 'asset_no': TextInput(attrs={'class': 'form-control', 'style': 'width:530px;'}), 'asset_type': Select(attrs={'class': 'form-control', 'style': 'width:530px;'}), 'status': Select(attrs={'class': 'form-control', 'style': 'width:530px;'}), 'os': TextInput(attrs={'class': 'form-control', 'style': 'width:530px;'}), 'vendor': TextInput(attrs={'class': 'form-control', 'style': 'width:530px;'}), 'cpu_model': TextInput(attrs={'class': 'form-control', 'style': 'width:530px;'}), 'cpu_num': TextInput(attrs={'class': 'form-control', 'style': 'width:530px;'}), 'memory': TextInput(attrs={'class': 'form-control', 'style': 'width:530px;'}), 'disk': TextInput(attrs={'class': 'form-control', 'style': 'width:530px;'}), 'sn': TextInput(attrs={'class': 'form-control', 'style': 'width:530px;'}), 'idc': Select(attrs={'class': 'form-control', 'style': 'width:530px;'}), 'position': TextInput(attrs={'class': 'form-control', 'style': 'width:530px;', 'placeholder': u'物理机写位置,虚机写宿主'}), 'memo': Textarea(attrs={'class': 'form-control', 'style': 'width:530px;'}), } class IdcForm(forms.ModelForm): def clean(self): cleaned_data = super(IdcForm, self).clean() value = cleaned_data.get('name') try: Idc.objects.get(name=value) self._errors['name'] = self.error_class(["%s的信息已经存在" % value]) except Idc.DoesNotExist: pass return cleaned_data class Meta: model = Idc exclude = ("id",) widgets = { 'name': TextInput(attrs={'class': 'form-control','style': 'width:450px;'}), 'address': TextInput(attrs={'class': 'form-control','style': 'width:450px;'}), 'tel': TextInput(attrs={'class': 'form-control','style': 'width:450px;'}), 'contact': TextInput(attrs={'class': 'form-control','style': 'width:450px;'}), 'contact_phone': TextInput(attrs={'class': 'form-control','style': 'width:450px;'}), 'ip_range': TextInput(attrs={'class': 'form-control','style': 'width:450px;'}), 'jigui': TextInput(attrs={'class': 'form-control','style': 'width:450px;'}), 'bandwidth': TextInput(attrs={'class': 'form-control','style': 'width:450px;'}), } class GroupForm(forms.ModelForm): def clean(self): cleaned_data = super(GroupForm, self).clean() value = cleaned_data.get('name') try: HostGroup.objects.get(name=value) self._errors['name'] = self.error_class(["%s的信息已经存在" % value]) except HostGroup.DoesNotExist: pass return cleaned_data class Meta: model = HostGroup exclude = ("id", )
44.935897
124
0.564907
366
3,505
5.363388
0.224044
0.127356
0.178299
0.267448
0.794702
0.794702
0.794702
0.776363
0.284259
0.157412
0
0.028003
0.225678
3,505
78
125
44.935897
0.695284
0.012268
0
0.322581
0
0
0.316383
0
0
0
0
0
0
1
0.032258
false
0.032258
0.048387
0
0.209677
0
0
0
0
null
0
0
1
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
0
0
0
0
0
0
4
751a4a5d6529fdc793e07cf84c2e4760a7ecdf7d
131
py
Python
jes/jes-v5.020-linux/demos/fib.py
utv-teaching/foundations-computer-science
568e19fd83a3355dab2814229f335abf31bfd7e9
[ "MIT" ]
null
null
null
jes/jes-v5.020-linux/demos/fib.py
utv-teaching/foundations-computer-science
568e19fd83a3355dab2814229f335abf31bfd7e9
[ "MIT" ]
null
null
null
jes/jes-v5.020-linux/demos/fib.py
utv-teaching/foundations-computer-science
568e19fd83a3355dab2814229f335abf31bfd7e9
[ "MIT" ]
null
null
null
def fib(i): count = 0 x = 0 y = 1 while count < i: count = count + 1 x, y = y, x + y return y
13.1
25
0.389313
22
131
2.318182
0.454545
0.235294
0
0
0
0
0
0
0
0
0
0.061538
0.503817
131
9
26
14.555556
0.723077
0
0
0
0
0
0
0
0
0
0
0
0
1
0.125
false
0
0
0
0.25
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
1
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
751eaf407fdfca01030f161d0a85cac1edf1d0a4
88
py
Python
000403StepPyThin/000403_02_03_Task_02_other_02_20200106.py
SafonovMikhail/python_000577
739f764e80f1ca354386f00b8e9db1df8c96531d
[ "Apache-2.0" ]
null
null
null
000403StepPyThin/000403_02_03_Task_02_other_02_20200106.py
SafonovMikhail/python_000577
739f764e80f1ca354386f00b8e9db1df8c96531d
[ "Apache-2.0" ]
null
null
null
000403StepPyThin/000403_02_03_Task_02_other_02_20200106.py
SafonovMikhail/python_000577
739f764e80f1ca354386f00b8e9db1df8c96531d
[ "Apache-2.0" ]
null
null
null
x = [x for x in range(int(input()),int(input()) + 1) if x % 3 == 0] print(sum(x)/len(x))
44
67
0.545455
20
88
2.4
0.65
0.333333
0
0
0
0
0
0
0
0
0
0.041096
0.170455
88
2
68
44
0.616438
0
0
0
0
0
0
0
0
0
0
0
0
1
0
false
0
0
0
0
0.5
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
0
0
0
1
0
4
7547053c90304ec082b84ea351e30fcadb74f355
100
py
Python
login_history/apps.py
farhad0085/dj-user-login-history
3384ce977694c7b03c713a9dc0bc31490a140e87
[ "MIT" ]
null
null
null
login_history/apps.py
farhad0085/dj-user-login-history
3384ce977694c7b03c713a9dc0bc31490a140e87
[ "MIT" ]
null
null
null
login_history/apps.py
farhad0085/dj-user-login-history
3384ce977694c7b03c713a9dc0bc31490a140e87
[ "MIT" ]
null
null
null
from django.apps import AppConfig class LoginHistoryConfig(AppConfig): name = 'login_history'
16.666667
36
0.78
11
100
7
0.909091
0
0
0
0
0
0
0
0
0
0
0
0.15
100
5
37
20
0.905882
0
0
0
0
0
0.13
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
754dbc4cc65cfc22e5aee3d0c0757504a2dbf0c2
97
py
Python
electivapp/apps/actividades/apps.py
AlanSanchezP/ElectivappServer
1bbb3ccbf33c685fcc0e3298d4ad4ed4d9059ce4
[ "MIT" ]
null
null
null
electivapp/apps/actividades/apps.py
AlanSanchezP/ElectivappServer
1bbb3ccbf33c685fcc0e3298d4ad4ed4d9059ce4
[ "MIT" ]
10
2019-02-14T03:40:30.000Z
2019-05-20T22:55:15.000Z
actividades/apps.py
fabianabarca/horas
526c065803f1487a39644eb54f65b7b4f3a036ee
[ "MIT" ]
1
2021-10-14T22:40:39.000Z
2021-10-14T22:40:39.000Z
from django.apps import AppConfig class ActividadesConfig(AppConfig): name = 'actividades'
16.166667
35
0.773196
10
97
7.5
0.9
0
0
0
0
0
0
0
0
0
0
0
0.154639
97
5
36
19.4
0.914634
0
0
0
0
0
0.113402
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
f373642774d12f21cc23829ed93050f225d3ed9a
74
py
Python
{{cookiecutter.project_slug + '.git'}}/src/{{cookiecutter.package_name}}/_vendored/__init__.py
douglasdaly/cookiecutter-pypackage
7150d91c74eb01da69ff3a24447667bf643a5de5
[ "MIT" ]
null
null
null
{{cookiecutter.project_slug + '.git'}}/src/{{cookiecutter.package_name}}/_vendored/__init__.py
douglasdaly/cookiecutter-pypackage
7150d91c74eb01da69ff3a24447667bf643a5de5
[ "MIT" ]
null
null
null
{{cookiecutter.project_slug + '.git'}}/src/{{cookiecutter.package_name}}/_vendored/__init__.py
douglasdaly/cookiecutter-pypackage
7150d91c74eb01da69ff3a24447667bf643a5de5
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Vendored versions of required libraries. """
12.333333
40
0.608108
8
74
5.625
1
0
0
0
0
0
0
0
0
0
0
0.016393
0.175676
74
5
41
14.8
0.721311
0.851351
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
f3afaf9e9062d6dd90c48c593fe9091a1323543a
73
py
Python
applications/baseapp/mixins/__init__.py
ajitjasrotia/django-project-skeleton
70e3e06384dfb018f59b1af8c7c3febf2bbcd47c
[ "MIT" ]
48
2018-01-10T11:21:35.000Z
2021-09-08T23:28:07.000Z
applications/baseapp/mixins/__init__.py
ajitjasrotia/django-project-skeleton
70e3e06384dfb018f59b1af8c7c3febf2bbcd47c
[ "MIT" ]
26
2018-04-20T10:46:00.000Z
2019-09-21T06:47:13.000Z
applications/baseapp/mixins/__init__.py
ajitjasrotia/django-project-skeleton
70e3e06384dfb018f59b1af8c7c3febf2bbcd47c
[ "MIT" ]
20
2019-03-09T19:46:10.000Z
2022-03-27T14:57:03.000Z
# isort:skip_file # flake8: noqa from .html_debug import HtmlDebugMixin
14.6
38
0.794521
10
73
5.6
1
0
0
0
0
0
0
0
0
0
0
0.015873
0.136986
73
4
39
18.25
0.873016
0.383562
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
34680b7af5a24ff2ba091f8bfe4190aa269d5b51
108
py
Python
pygments_renderer/apps.py
c-bata/django-pygments-renderer
1e9f182c99e741f8c104e211592ca03e628f1363
[ "MIT" ]
null
null
null
pygments_renderer/apps.py
c-bata/django-pygments-renderer
1e9f182c99e741f8c104e211592ca03e628f1363
[ "MIT" ]
null
null
null
pygments_renderer/apps.py
c-bata/django-pygments-renderer
1e9f182c99e741f8c104e211592ca03e628f1363
[ "MIT" ]
null
null
null
from django.apps import AppConfig class PygmentsRendererConfig(AppConfig): name = 'pygments_renderer'
18
40
0.796296
11
108
7.727273
0.909091
0
0
0
0
0
0
0
0
0
0
0
0.138889
108
5
41
21.6
0.913978
0
0
0
0
0
0.157407
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
caa661a0d0340fb61a6b9d9f223de364d719f2ba
60
py
Python
src/cobra/apps/svnkit/__init__.py
lyoniionly/django-cobra
2427e5cf74b7739115b1224da3306986b3ee345c
[ "Apache-2.0" ]
1
2015-01-27T08:56:46.000Z
2015-01-27T08:56:46.000Z
src/cobra/apps/svnkit/__init__.py
lyoniionly/django-cobra
2427e5cf74b7739115b1224da3306986b3ee345c
[ "Apache-2.0" ]
null
null
null
src/cobra/apps/svnkit/__init__.py
lyoniionly/django-cobra
2427e5cf74b7739115b1224da3306986b3ee345c
[ "Apache-2.0" ]
null
null
null
default_app_config = 'cobra.apps.svnkit.config.SvnkitConfig'
60
60
0.85
8
60
6.125
0.875
0
0
0
0
0
0
0
0
0
0
0
0.033333
60
1
60
60
0.844828
0
0
0
0
0
0.606557
0.606557
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
cacd67b46feb99c405c2dfdce686d95f8074414e
87
py
Python
pytest/03_testrun/test_mark.py
dramasamy/training
af7b9352b56c10aaa957062f24f1302a7a4c5797
[ "Apache-2.0" ]
1
2022-03-22T22:31:32.000Z
2022-03-22T22:31:32.000Z
pytest/03_testrun/test_mark.py
dramasamy/training
af7b9352b56c10aaa957062f24f1302a7a4c5797
[ "Apache-2.0" ]
null
null
null
pytest/03_testrun/test_mark.py
dramasamy/training
af7b9352b56c10aaa957062f24f1302a7a4c5797
[ "Apache-2.0" ]
null
null
null
import pytest @pytest.mark.sanity def test_sample(): assert type(1) == type(int())
17.4
33
0.689655
13
87
4.538462
0.846154
0
0
0
0
0
0
0
0
0
0
0.013514
0.149425
87
4
34
21.75
0.783784
0
0
0
0
0
0
0
0
0
0
0
0.25
1
0.25
true
0
0.25
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
1
1
0
0
0
0
0
0
4
cad3545d87620b1e158d7e04a8277c3c27c46a38
627
py
Python
home/migrations/0002_auto_20200921_1020.py
1705095/HackNsu2_TEAM_RETURN_ZERO
eb5594619754f9ef98bc8383f7ed3f7f553ce703
[ "Apache-2.0" ]
1
2021-05-03T10:22:05.000Z
2021-05-03T10:22:05.000Z
home/migrations/0002_auto_20200921_1020.py
1705095/HackNsu2_TEAM_RETURN_ZERO
eb5594619754f9ef98bc8383f7ed3f7f553ce703
[ "Apache-2.0" ]
1
2021-03-19T04:27:58.000Z
2021-03-19T04:27:58.000Z
home/migrations/0002_auto_20200921_1020.py
ArifShariar/HackNsu2_TEAM_RETURN_ZERO
eb5594619754f9ef98bc8383f7ed3f7f553ce703
[ "Apache-2.0" ]
2
2020-10-20T12:58:43.000Z
2020-12-12T15:54:30.000Z
# Generated by Django 3.1.1 on 2020-09-21 04:20 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('home', '0001_initial'), ] operations = [ migrations.RemoveField( model_name='company_product', name='order_fk', ), migrations.DeleteModel( name='notification', ), migrations.DeleteModel( name='vendor_product', ), migrations.DeleteModel( name='company_product', ), migrations.DeleteModel( name='order', ), ]
20.9
47
0.53748
53
627
6.245283
0.603774
0.253776
0.302115
0.193353
0
0
0
0
0
0
0
0.046798
0.352472
627
29
48
21.62069
0.768473
0.07177
0
0.391304
1
0
0.146552
0
0
0
0
0
0
1
0
false
0
0.043478
0
0.173913
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
1
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
cae816abcbc67ce4240cf1b33df5e220fc4bf697
218
py
Python
mne_nirs/io/__init__.py
alexrockhill/mne-nirs
846d5f7dc5c7022d8b4a4af2911f1dff31e678d4
[ "BSD-3-Clause" ]
46
2020-04-17T20:27:13.000Z
2022-03-11T08:03:23.000Z
mne_nirs/io/__init__.py
alexrockhill/mne-nirs
846d5f7dc5c7022d8b4a4af2911f1dff31e678d4
[ "BSD-3-Clause" ]
324
2020-04-14T09:53:15.000Z
2022-03-14T15:26:40.000Z
mne_nirs/io/__init__.py
alexrockhill/mne-nirs
846d5f7dc5c7022d8b4a4af2911f1dff31e678d4
[ "BSD-3-Clause" ]
24
2020-04-14T10:44:27.000Z
2022-03-12T23:46:42.000Z
# Authors: Robert Luke <mail@robertluke.net> # # License: BSD (3-clause) from . import snirf from . import fold from .snirf import write_raw_snirf from .fold import fold_channel_specificity, fold_landmark_specificity
24.222222
69
0.793578
31
218
5.387097
0.612903
0.11976
0
0
0
0
0
0
0
0
0
0.005263
0.12844
218
8
70
27.25
0.873684
0.302752
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
1b667850264e7c098db11564a7744d502095777b
334
py
Python
mamba/core/msg/empty.py
ismaelJimenez/mamba_server
e6e2343291a0df24f226bde0d13e5bfa74cc3650
[ "MIT" ]
null
null
null
mamba/core/msg/empty.py
ismaelJimenez/mamba_server
e6e2343291a0df24f226bde0d13e5bfa74cc3650
[ "MIT" ]
null
null
null
mamba/core/msg/empty.py
ismaelJimenez/mamba_server
e6e2343291a0df24f226bde0d13e5bfa74cc3650
[ "MIT" ]
null
null
null
############################################################################ # # Copyright (c) Mamba Developers. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. # ############################################################################ class Empty: pass
27.833333
76
0.39521
25
334
5.28
0.88
0
0
0
0
0
0
0
0
0
0
0
0.110778
334
11
77
30.363636
0.444444
0.434132
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0.5
0
0
0.5
0
1
0
0
null
0
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
0
1
1
0
0
0
0
0
4
1b9be75848814559b7e7261b7be1d6d788d412d7
617
py
Python
cotr/ctrs_texts/migrations/0005_auto_20190731_0944.py
kingsdigitallab/cotr
4afbfdd36d4dd0ee9f56152d3c963453c81e440c
[ "MIT" ]
null
null
null
cotr/ctrs_texts/migrations/0005_auto_20190731_0944.py
kingsdigitallab/cotr
4afbfdd36d4dd0ee9f56152d3c963453c81e440c
[ "MIT" ]
27
2020-12-28T17:34:59.000Z
2022-03-12T00:25:43.000Z
ctrs_texts/migrations/0005_auto_20190731_0944.py
kingsdigitallab/ctrs-django
7170b4f15bd9d097d00f215d747a02a9b656768c
[ "MIT" ]
null
null
null
# Generated by Django 2.2.3 on 2019-07-31 08:44 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('ctrs_texts', '0004_auto_20190720_0019'), ] operations = [ migrations.AlterModelOptions( name='abstractedtext', options={'ordering': ['name']}, ), migrations.AlterModelOptions( name='abstractedtexttype', options={'ordering': ['name']}, ), migrations.AlterModelOptions( name='encodedtexttype', options={'ordering': ['name']}, ), ]
23.730769
50
0.562399
50
617
6.86
0.64
0.236152
0.271137
0.169096
0.291545
0.291545
0
0
0
0
0
0.072261
0.3047
617
25
51
24.68
0.727273
0.072934
0
0.473684
1
0
0.203509
0.040351
0
0
0
0
0
1
0
false
0
0.052632
0
0.210526
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
1
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
1bb525959cb409db77278939b5d4c81fee5bb6fa
88
py
Python
sample_config.py
Amarnathcdj/Lunachatbot
b560f2233cbbce4dca99868bb0f3cc85f5ad8717
[ "MIT" ]
null
null
null
sample_config.py
Amarnathcdj/Lunachatbot
b560f2233cbbce4dca99868bb0f3cc85f5ad8717
[ "MIT" ]
null
null
null
sample_config.py
Amarnathcdj/Lunachatbot
b560f2233cbbce4dca99868bb0f3cc85f5ad8717
[ "MIT" ]
1
2021-03-01T05:03:45.000Z
2021-03-01T05:03:45.000Z
owner_id = 1243703097 bot_token = "16901971:AAFqdM_SQE1PB2P1xLr67k" bot_id = 1663901971
22
45
0.829545
11
88
6.272727
0.818182
0
0
0
0
0
0
0
0
0
0
0.417722
0.102273
88
3
46
29.333333
0.455696
0
0
0
0
0
0.352273
0.352273
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
1
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
9429b346b6876e3d4f458e6e40ee3f6d02fc1474
201
py
Python
face_recognition_server/app.py
yoyota-pose-estimation/face-recognition-server
51edb78dd00b585461174fdcc31a95a5debcadca
[ "MIT" ]
null
null
null
face_recognition_server/app.py
yoyota-pose-estimation/face-recognition-server
51edb78dd00b585461174fdcc31a95a5debcadca
[ "MIT" ]
null
null
null
face_recognition_server/app.py
yoyota-pose-estimation/face-recognition-server
51edb78dd00b585461174fdcc31a95a5debcadca
[ "MIT" ]
null
null
null
from flask import Flask # pylint: disable=invalid-name app = Flask(__name__) @app.route("/healthz") def health(): return ("", 204) @app.route("/") def hello_world(): return "hello world!"
13.4
30
0.651741
26
201
4.846154
0.615385
0.111111
0
0
0
0
0
0
0
0
0
0.018072
0.174129
201
14
31
14.357143
0.740964
0.139303
0
0
0
0
0.122807
0
0
0
0
0
0
1
0.25
false
0
0.125
0.25
0.625
0
1
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
0
1
1
0
0
4
942cd5943c7d08829f01bbcca4c56eb34b79cb74
154
py
Python
Django_Server/raspberrypi_virtualenv/bin/django-admin.py
ManasUniyal/Friday
6e1ff6541cca98f073e3fd07218b22da165a613b
[ "MIT" ]
1
2021-03-01T11:25:32.000Z
2021-03-01T11:25:32.000Z
Django_Server/raspberrypi_virtualenv/bin/django-admin.py
ManasUniyal/Friday
6e1ff6541cca98f073e3fd07218b22da165a613b
[ "MIT" ]
null
null
null
Django_Server/raspberrypi_virtualenv/bin/django-admin.py
ManasUniyal/Friday
6e1ff6541cca98f073e3fd07218b22da165a613b
[ "MIT" ]
null
null
null
#!/home/manas/Desktop/raspberrypi_3/bin/python3 from django.core import management if __name__ == "__main__": management.execute_from_command_line()
25.666667
47
0.792208
20
154
5.5
0.9
0
0
0
0
0
0
0
0
0
0
0.014388
0.097403
154
5
48
30.8
0.776978
0.298701
0
0
0
0
0.074766
0
0
0
0
0
0
1
0
true
0
0.333333
0
0.333333
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
94372aceab65ce98fdc6289fc10f08aad45da226
747
py
Python
yard/skills/66-python/cookbook/yh_std_lib_demo.py
paser4se/bbxyard
d09bc6efb75618b2cef047bad9c8b835043446cb
[ "Apache-2.0" ]
1
2016-03-29T02:01:58.000Z
2016-03-29T02:01:58.000Z
yard/skills/66-python/cookbook/yh_std_lib_demo.py
paser4se/bbxyard
d09bc6efb75618b2cef047bad9c8b835043446cb
[ "Apache-2.0" ]
18
2019-02-13T09:15:25.000Z
2021-12-09T21:32:13.000Z
yard/skills/66-python/cookbook/yh_std_lib_demo.py
paser4se/bbxyard
d09bc6efb75618b2cef047bad9c8b835043446cb
[ "Apache-2.0" ]
2
2020-07-05T01:01:30.000Z
2020-07-08T22:33:06.000Z
#!/usr/bin/env python3 # 系统标准库测试 from yvhai.demo.std.os import OSDemo from yvhai.demo.std.misc import MiscDemo from yvhai.demo.std.shutil import ShUtilDemo from yvhai.demo.std.sys import SysDemo from yvhai.demo.std.datetime import DTDemo from yvhai.demo.std.re import RegexDemo from yvhai.demo.std.logging import LogerDemo from yvhai.demo.std.str import StrDemo from yvhai.demo.std.ds.deque import DequeDemo from yvhai.demo.std.ds.heapq import HeapqDemo from yvhai.demo.std.ds.dict import DictDemo if __name__ == '__main__': OSDemo.demo() MiscDemo.demo() ShUtilDemo.demo() SysDemo.demo() DTDemo.demo() RegexDemo.demo() LogerDemo.demo() StrDemo.demo() DequeDemo.demo() HeapqDemo.demo() DictDemo.demo()
26.678571
45
0.746988
110
747
5
0.327273
0.18
0.26
0.32
0.098182
0
0
0
0
0
0
0.001567
0.145917
747
27
46
27.666667
0.860502
0.038822
0
0
0
0
0.011173
0
0
0
0
0
0
1
0
true
0
0.478261
0
0.478261
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
1
0
1
0
0
0
0
4
947fb1784fe2b80f163016b8fde7f7007f737dfe
457
py
Python
app_ubigeo/api/serializers.py
softlabperu/app_ubigeo
270c588de4f01901aef0433f65b8452771e10d5e
[ "BSD-3-Clause" ]
null
null
null
app_ubigeo/api/serializers.py
softlabperu/app_ubigeo
270c588de4f01901aef0433f65b8452771e10d5e
[ "BSD-3-Clause" ]
null
null
null
app_ubigeo/api/serializers.py
softlabperu/app_ubigeo
270c588de4f01901aef0433f65b8452771e10d5e
[ "BSD-3-Clause" ]
null
null
null
from rest_framework import serializers from app_ubigeo.models import * class DepartamentoSerializer(serializers.ModelSerializer): class Meta: model = Departamento fields = '__all__' class ProvinciaSerializer(serializers.ModelSerializer): class Meta: model = Provincia fields = '__all__' class DistritoSerializer(serializers.ModelSerializer): class Meta: model = Distrito fields = '__all__'
20.772727
58
0.706783
40
457
7.725
0.5
0.252427
0.300971
0.339806
0.38835
0
0
0
0
0
0
0
0.229759
457
21
59
21.761905
0.877841
0
0
0.428571
0
0
0.045952
0
0
0
0
0
0
1
0
false
0
0.142857
0
0.571429
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
948a5a52475e167752e7d012fd230ee0ffd66fe0
1,498
py
Python
tests/v1/test_synthetics_test_options.py
MichaelTROEHLER/datadog-api-client-python
12c46626622fb1277bb1e172753b342c671348bd
[ "Apache-2.0" ]
null
null
null
tests/v1/test_synthetics_test_options.py
MichaelTROEHLER/datadog-api-client-python
12c46626622fb1277bb1e172753b342c671348bd
[ "Apache-2.0" ]
null
null
null
tests/v1/test_synthetics_test_options.py
MichaelTROEHLER/datadog-api-client-python
12c46626622fb1277bb1e172753b342c671348bd
[ "Apache-2.0" ]
null
null
null
# coding: utf-8 # Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. # This product includes software developed at Datadog (https://www.datadoghq.com/). # Copyright 2019-Present Datadog, Inc. from __future__ import absolute_import import sys import unittest import datadog_api_client.v1 try: from datadog_api_client.v1.model import synthetics_device_id except ImportError: synthetics_device_id = sys.modules[ 'datadog_api_client.v1.model.synthetics_device_id'] try: from datadog_api_client.v1.model import synthetics_test_options_retry except ImportError: synthetics_test_options_retry = sys.modules[ 'datadog_api_client.v1.model.synthetics_test_options_retry'] try: from datadog_api_client.v1.model import synthetics_tick_interval except ImportError: synthetics_tick_interval = sys.modules[ 'datadog_api_client.v1.model.synthetics_tick_interval'] from datadog_api_client.v1.model.synthetics_test_options import SyntheticsTestOptions class TestSyntheticsTestOptions(unittest.TestCase): """SyntheticsTestOptions unit test stubs""" def setUp(self): pass def tearDown(self): pass def testSyntheticsTestOptions(self): """Test SyntheticsTestOptions""" # FIXME: construct object with mandatory attributes with example values # model = SyntheticsTestOptions() # noqa: E501 pass if __name__ == '__main__': unittest.main()
30.571429
108
0.76502
182
1,498
6.010989
0.43956
0.073126
0.117002
0.131627
0.297989
0.297989
0.294333
0.294333
0.126143
0
0
0.014388
0.164887
1,498
48
109
31.208333
0.860112
0.280374
0
0.310345
0
0
0.155514
0.147974
0
0
0
0.020833
0
1
0.103448
false
0.103448
0.37931
0
0.517241
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
0
0
1
1
0
1
0
0
4
948c10f956f7e7e9df11c3a3507cc0020f781b6a
8,015
py
Python
test_tvmv.py
netfeed/tvmv
7f7885ce454f6d76ae0ffb0ccdf0b4baaee0ccdb
[ "MIT" ]
null
null
null
test_tvmv.py
netfeed/tvmv
7f7885ce454f6d76ae0ffb0ccdf0b4baaee0ccdb
[ "MIT" ]
null
null
null
test_tvmv.py
netfeed/tvmv
7f7885ce454f6d76ae0ffb0ccdf0b4baaee0ccdb
[ "MIT" ]
null
null
null
import imp import os import os.path import unittest tvmv = imp.load_source('tvmv', 'tvmv') tvmv.VERBOSE = False class TestSeasonParsing(unittest.TestCase): def test_s01e08(self): result = tvmv.parse_season("American.Dad.S01E08.HDTV.x264") self.assertEqual('01', result.group(1)) self.assertEqual('08', result.group(2)) def test_07e09(self): result = tvmv.parse_season("Cutthroat+Kitchen+07e09+hdtv+x264") self.assertEqual('07', result.group(1)) self.assertEqual('09', result.group(2)) def test_s11e23(self): result = tvmv.parse_season("American.Dad.S11E23.HDTV.x264") self.assertEqual('11', result.group(1)) self.assertEqual('23', result.group(2)) def test_parent(self): result = tvmv.parse_season("American.Dad.S11E23.HDTV.x264/episode.mp4") self.assertEqual('11', result.group(1)) self.assertEqual('23', result.group(2)) def test_1x10(self): result = tvmv.parse_season("American Dad 1x10 HDTV x264") self.assertEqual('1', result.group(1)) self.assertEqual('10', result.group(2)) def test_10x01(self): result = tvmv.parse_season("American Dad 10x01 HDTV x264") self.assertEqual('10', result.group(1)) self.assertEqual('01', result.group(2)) def test_110(self): result = tvmv.parse_season("American Dad 110 HDTV x264") self.assertEqual('1', result.group(1)) self.assertEqual('10', result.group(2)) def test_1001(self): result = tvmv.parse_season("American Dad 1001 HDTV x264") self.assertEqual('10', result.group(1)) self.assertEqual('01', result.group(2)) def test_none(self): result = tvmv.parse_season("American Dad HDTV x264") self.assertEqual(None, result) def test_slash_season(self): result = tvmv.parse_season("511 - Mac and Charlie Write a Movie.avi") self.assertEqual('5', result.group(1)) self.assertEqual('11', result.group(2)) def test_number_in_ep(self): result = tvmv.parse_season("205 - 100 Dollar Baby.avi") self.assertEqual('2', result.group(1)) self.assertEqual('05', result.group(2)) class TestNameParsing(unittest.TestCase): def test_s01e08(self): result = tvmv.parse_name("American.Dad.S01E08.HDTV.x264") self.assertEqual('American Dad', result) def test_1x10(self): result = tvmv.parse_name("American Dad 1x10 HDTV x264") self.assertEqual('American Dad', result) def test_110(self): result = tvmv.parse_name("American Dad 110 HDTV x264") self.assertEqual('American Dad', result) def test_sunny(self): result = tvmv.parse_name("It's Always Sunny in Philadelphia 1001 HDTV x264") self.assertEqual("It's Always Sunny in Philadelphia", result) def test_none(self): result = tvmv.parse_name("American Dad HDTV x264") self.assertEqual(None, result) def test_archer(self): result = tvmv.parse_name("Archer.2009.S06E11.HDTV.x264") self.assertEqual("Archer 2009", result) class TestTvParsing(unittest.TestCase): def test_name_single_number_season(self): parsed = tvmv.parse_path('files', "files/American.Dad.S01E08.HDTV.x264/American Dad - 108.mp4") check = tvmv.Show('American Dad', episode=tvmv.Episode(1, 8, '.mp4')) self.assertEqual(check, parsed) def test_name_single_number_season_x(self): parsed = tvmv.parse_path('files', "files/American.Dad.S01E08.HDTV.x264/American Dad - 1x08.mp4") check = tvmv.Show('American Dad', episode=tvmv.Episode(1, 8, '.mp4')) self.assertEqual(check, parsed) def test_check_dir(self): parsed = tvmv.parse_path('files', "files/American.Dad.S01E07.HDTV.x264/107.mp4") check = tvmv.Show('American Dad', episode=tvmv.Episode(1, 7, '.mp4')) self.assertEqual(check, parsed) def test_check_dir_no_files(self): parsed = tvmv.parse_path('files', "American.Dad.S01E07.HDTV.x264/107.mp4") check = tvmv.Show('American Dad', episode=tvmv.Episode(1, 7, '.mp4')) self.assertEqual(check, parsed) def test_name_double_digit_season(self): parsed = tvmv.parse_path('files', "files/American.Dad.S11E08.HDTV.x264/American Dad - 1108.mp4") check = tvmv.Show('American Dad', episode=tvmv.Episode(11, 8, '.mp4')) self.assertEqual(check, parsed) def test_am_good_filename(self): parsed = tvmv.parse_path('files', "files/American.Dad.S11E09.HDTV.x264/American.Dad.S11E09.HDTV.x264.mp4") check = tvmv.Show('American Dad', episode=tvmv.Episode(11, 9, '.mp4')) self.assertEqual(check, parsed) def test_bb_good_filename(self): parsed = tvmv.parse_path('files', "files/Bobs.Burgers.S05E15.HDTV.x264.mp4") check = tvmv.Show('Bobs Burgers', episode=tvmv.Episode(5, 15, '.mp4')) self.assertEqual(check, parsed) def test_spaced_name(self): parsed = tvmv.parse_path('files', "files/It's Always Sunny in Philadelphia S10E10 (1920x1080).mkv") check = tvmv.Show("It's Always Sunny in Philadelphia", episode=tvmv.Episode(10, 10, '.mkv')) self.assertEqual(check, parsed) def test_spaced_name_no_files(self): parsed = tvmv.parse_path('files', "It's Always Sunny in Philadelphia S10E10 (1920x1080).mkv") check = tvmv.Show("It's Always Sunny in Philadelphia", episode=tvmv.Episode(10, 10, '.mkv')) self.assertEqual(check, parsed) def test_one_up(self): parsed = tvmv.parse_path('files', "It's Always Sunny In Philadelphia/Season 3/309 - Sweet Dee's Dating A Retarted Person.avi") check = tvmv.Show("It's Always Sunny In Philadelphia", episode=tvmv.Episode(3, 9, '.avi')) self.assertEqual(check, parsed) def test_one_up_none(self): parsed = tvmv.parse_path('files', "files/Season 3/309 - Sweet Dee's Dating A Retarted Person.avi") self.assertEqual(None, parsed) def test_number_in_name(self): parsed = tvmv.parse_path('files', "files/It's Always Sunny In Philadelphia/Season 2/205 - 100 Dollar Baby.avi") check = tvmv.Show("It's Always Sunny In Philadelphia", episode=tvmv.Episode(2, 5, '.avi')) self.assertEqual(check, parsed) class TestFormatFromPath(unittest.TestCase): def test_name(self): parsed = tvmv.parse_path('files', "files/American.Dad.S01E08.HDTV.x264/American Dad - 108.mp4") result = parsed.format("{show}/{show}") self.assertEqual("American Dad/American Dad", result) def test_season(self): parsed = tvmv.parse_path('files', "files/American.Dad.S01E08.HDTV.x264/American Dad - 108.mp4") result = parsed.format("{season}") self.assertEqual("1", result) def test_padded_season(self): parsed = tvmv.parse_path('files', "files/American.Dad.S01E08.HDTV.x264/American Dad - 108.mp4") result = parsed.format("{season.pad(2)}") self.assertEqual("01", result) def test_episode(self): parsed = tvmv.parse_path('files', "files/American.Dad.S01E08.HDTV.x264/American Dad - 108.mp4") result = parsed.format("{episode}") self.assertEqual("8", result) def test_padded_episode(self): parsed = tvmv.parse_path('files', "files/American.Dad.S01E08.HDTV.x264/American Dad - 108.mp4") result = parsed.format("{episode.pad(2)}") self.assertEqual("08", result) def test_1x8_combo(self): parsed = tvmv.parse_path('files', "files/American.Dad.S01E08.HDTV.x264/American Dad - 108.mp4") result = parsed.format("{season}x{episode}") self.assertEqual("1x8", result) def test_padded_combo(self): parsed = tvmv.parse_path('files', "files/American.Dad.S01E08.HDTV.x264/American Dad - 108.mp4") result = parsed.format("s{season.pad(2)}e{episode.pad(2)}") self.assertEqual("s01e08", result) if __name__ == '__main__': unittest.main()
42.632979
134
0.663007
1,083
8,015
4.800554
0.116343
0.099442
0.051164
0.069436
0.841893
0.740527
0.715715
0.630698
0.595307
0.521831
0
0.069937
0.193637
8,015
187
135
42.860963
0.734489
0
0
0.337838
0
0.013514
0.28247
0.106051
0
0
0
0
0.310811
1
0.243243
false
0
0.027027
0
0.297297
0
0
0
0
null
0
0
0
1
1
1
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
84a12da679314b90e0d272c2c5df43f5e76f853b
288
py
Python
app/Fron_end/bd/models.py
IsaiRL/Proyecto-PS
588a72710f9b2742943e83b46fb101940a6ca52b
[ "MIT" ]
null
null
null
app/Fron_end/bd/models.py
IsaiRL/Proyecto-PS
588a72710f9b2742943e83b46fb101940a6ca52b
[ "MIT" ]
null
null
null
app/Fron_end/bd/models.py
IsaiRL/Proyecto-PS
588a72710f9b2742943e83b46fb101940a6ca52b
[ "MIT" ]
null
null
null
from django.db import models # Create your models here. class IPs(models.Model): ip = models.GenericIPAddressField(null=False, blank=False, unique=True) ultima_peticion = models.DateTimeField(null=False, blank=False) intentos = models.IntegerField(null=False, blank=False, default=0)
36
72
0.788194
39
288
5.794872
0.641026
0.119469
0.185841
0.252212
0
0
0
0
0
0
0
0.003861
0.100694
288
7
73
41.142857
0.868726
0.083333
0
0
0
0
0
0
0
0
0
0
0
1
0
false
0
0.2
0
1
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
0
0
1
0
0
4
84c44206df00eb1931caed2c776070ccb2d9abaf
47
py
Python
ex4-7.py
yiyidhuang/PythonCrashCrouse2nd
3512f9ab8fcf32c6145604a37e2a62feddf174d1
[ "MIT" ]
null
null
null
ex4-7.py
yiyidhuang/PythonCrashCrouse2nd
3512f9ab8fcf32c6145604a37e2a62feddf174d1
[ "MIT" ]
null
null
null
ex4-7.py
yiyidhuang/PythonCrashCrouse2nd
3512f9ab8fcf32c6145604a37e2a62feddf174d1
[ "MIT" ]
null
null
null
numbers = list(range(3, 31, 3)) print(numbers)
15.666667
31
0.680851
8
47
4
0.75
0
0
0
0
0
0
0
0
0
0
0.097561
0.12766
47
2
32
23.5
0.682927
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
84c8deab8f6125677768b52551f21022ce3a046a
242
py
Python
otp/distributed/ObjectServerAI.py
TheFamiliarScoot/open-toontown
678313033174ea7d08e5c2823bd7b473701ff547
[ "BSD-3-Clause" ]
99
2019-11-02T22:25:00.000Z
2022-02-03T03:48:00.000Z
otp/distributed/ObjectServerAI.py
TheFamiliarScoot/open-toontown
678313033174ea7d08e5c2823bd7b473701ff547
[ "BSD-3-Clause" ]
42
2019-11-03T05:31:08.000Z
2022-03-16T22:50:32.000Z
otp/distributed/ObjectServerAI.py
TheFamiliarScoot/open-toontown
678313033174ea7d08e5c2823bd7b473701ff547
[ "BSD-3-Clause" ]
57
2019-11-03T07:47:37.000Z
2022-03-22T00:41:49.000Z
from direct.directnotify import DirectNotifyGlobal from direct.distributed.DistributedObjectAI import DistributedObjectAI class ObjectServerAI(DistributedObjectAI): notify = DirectNotifyGlobal.directNotify.newCategory('ObjectServerAI')
34.571429
74
0.867769
19
242
11.052632
0.578947
0.095238
0
0
0
0
0
0
0
0
0
0
0.078512
242
6
75
40.333333
0.941704
0
0
0
0
0
0.057851
0
0
0
0
0
0
1
0
false
0
0.5
0
1
0
1
0
1
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
84df5b01533b8d32dfc55fb8f5bbf1ebfc07e8a4
80
py
Python
tests/test_files/async_def.py
cepbuch/flake8-class-attributes-order
8597c045fd576cb79fd2be3f10d95b92394e57c0
[ "MIT" ]
38
2019-02-15T18:09:08.000Z
2022-01-20T04:04:15.000Z
tests/test_files/async_def.py
cepbuch/flake8-class-attributes-order
8597c045fd576cb79fd2be3f10d95b92394e57c0
[ "MIT" ]
25
2019-04-21T12:58:09.000Z
2022-02-08T07:38:57.000Z
tests/test_files/async_def.py
cepbuch/flake8-class-attributes-order
8597c045fd576cb79fd2be3f10d95b92394e57c0
[ "MIT" ]
14
2019-04-21T13:00:05.000Z
2021-08-30T06:49:36.000Z
class A: def foo(self): pass async def bar(self): pass
11.428571
24
0.4875
11
80
3.545455
0.727273
0.410256
0
0
0
0
0
0
0
0
0
0
0.425
80
6
25
13.333333
0.847826
0
0
0.4
0
0
0
0
0
0
0
0
0
1
0.2
false
0.4
0
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
1
0
0
0
0
0
4
ca252e0c312a32945854be9ca7995fedcca7825e
67
py
Python
deduckt/main.py
metacraft-labs/python-deduckt
16f2b0419ba143131dd729f570158bb50288da90
[ "MIT" ]
20
2018-01-08T14:06:06.000Z
2021-08-25T03:02:02.000Z
deduckt/main.py
metacraft-labs/python-deduckt
16f2b0419ba143131dd729f570158bb50288da90
[ "MIT" ]
4
2018-05-22T06:55:54.000Z
2019-02-17T11:46:57.000Z
deduckt/main.py
metacraft-labs/python-deduckt
16f2b0419ba143131dd729f570158bb50288da90
[ "MIT" ]
6
2018-01-15T12:14:32.000Z
2019-10-15T14:19:13.000Z
if __name__ == '__main__': from deduckt import main main()
16.75
28
0.641791
8
67
4.375
0.75
0
0
0
0
0
0
0
0
0
0
0
0.253731
67
3
29
22.333333
0.7
0
0
0
0
0
0.119403
0
0
0
0
0
0
1
0
true
0
0.333333
0
0.333333
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
ca5cb5bdb085d847ab2f87fae741c07a98c66b17
80
py
Python
Phoster/compile.py
blueraspberrypi/phoster
67f961adf40e3251d79bc6e4b9bc9684b6ecc90b
[ "MIT" ]
1
2020-07-15T13:49:31.000Z
2020-07-15T13:49:31.000Z
Phoster/compile.py
blueraspberrypi/phoster
67f961adf40e3251d79bc6e4b9bc9684b6ecc90b
[ "MIT" ]
null
null
null
Phoster/compile.py
blueraspberrypi/phoster
67f961adf40e3251d79bc6e4b9bc9684b6ecc90b
[ "MIT" ]
null
null
null
from distutils.core import setup import py2exe setup(console=['phoster.py'])
20
33
0.7625
11
80
5.545455
0.818182
0
0
0
0
0
0
0
0
0
0
0.014286
0.125
80
4
34
20
0.857143
0
0
0
0
0
0.128205
0
0
0
0
0
0
1
0
true
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
1
0
1
0
0
0
0
4
ca78b422ef93fe886fcd5cd6f95c38d2bff95a25
771
py
Python
Scene.py
nemosupremo/Colosseum--Year-3XXX
93cd723e60f2f8fe57637cdabad2b1a644c9c279
[ "MIT" ]
1
2021-01-09T16:04:48.000Z
2021-01-09T16:04:48.000Z
Scene.py
nemosupremo/Colosseum--Year-3XXX
93cd723e60f2f8fe57637cdabad2b1a644c9c279
[ "MIT" ]
null
null
null
Scene.py
nemosupremo/Colosseum--Year-3XXX
93cd723e60f2f8fe57637cdabad2b1a644c9c279
[ "MIT" ]
null
null
null
class Scene(object): MAIN = None setup = False destroyed = False handles = [] handleFunc = {} def __init__(self, MainObj): self.MAIN = MainObj self.createHandleFunctions() def createHandleFunctions(self): pass def setUp(self): self.setup = True def mainLoop(self): pass def destroy(self): self.destroyed = True def isSetUp(self): return self.setup def isDestroyed(self): return self.destroyed def handlesCall(self, call): return call in self.handles def handleCall(self, call, args): return self.handleFunc[call](*args) def canChangeChar(self): return False def canLeaveGame(self): return False
18.357143
43
0.595331
81
771
5.617284
0.358025
0.087912
0.048352
0
0
0
0
0
0
0
0
0
0.317769
771
41
44
18.804878
0.865019
0
0
0.137931
0
0
0
0
0
0
0
0
0
1
0.37931
false
0.068966
0
0.206897
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
0
0
0
1
0
1
0
1
1
0
0
4
ca8b6b52ecc8b59e1365c0ea8d064f7b01b4c4e8
2,339
py
Python
Cartwheel/lib/Python26/Lib/site-packages/OpenGL/raw/GL/EXT/multisample.py
MontyThibault/centre-of-mass-awareness
58778f148e65749e1dfc443043e9fc054ca3ff4d
[ "MIT" ]
null
null
null
Cartwheel/lib/Python26/Lib/site-packages/OpenGL/raw/GL/EXT/multisample.py
MontyThibault/centre-of-mass-awareness
58778f148e65749e1dfc443043e9fc054ca3ff4d
[ "MIT" ]
null
null
null
Cartwheel/lib/Python26/Lib/site-packages/OpenGL/raw/GL/EXT/multisample.py
MontyThibault/centre-of-mass-awareness
58778f148e65749e1dfc443043e9fc054ca3ff4d
[ "MIT" ]
null
null
null
'''OpenGL extension EXT.multisample The official definition of this extension is available here: http://oss.sgi.com/projects/ogl-sample/registry/EXT/multisample.txt Automatically generated by the get_gl_extensions script, do not edit! ''' from OpenGL import platform, constants, constant, arrays from OpenGL import extensions from OpenGL.GL import glget import ctypes EXTENSION_NAME = 'GL_EXT_multisample' GL_MULTISAMPLE_EXT = constant.Constant( 'GL_MULTISAMPLE_EXT', 0x809D ) GL_SAMPLE_ALPHA_TO_MASK_EXT = constant.Constant( 'GL_SAMPLE_ALPHA_TO_MASK_EXT', 0x809E ) GL_SAMPLE_ALPHA_TO_ONE_EXT = constant.Constant( 'GL_SAMPLE_ALPHA_TO_ONE_EXT', 0x809F ) GL_SAMPLE_MASK_EXT = constant.Constant( 'GL_SAMPLE_MASK_EXT', 0x80A0 ) GL_1PASS_EXT = constant.Constant( 'GL_1PASS_EXT', 0x80A1 ) GL_2PASS_0_EXT = constant.Constant( 'GL_2PASS_0_EXT', 0x80A2 ) GL_2PASS_1_EXT = constant.Constant( 'GL_2PASS_1_EXT', 0x80A3 ) GL_4PASS_0_EXT = constant.Constant( 'GL_4PASS_0_EXT', 0x80A4 ) GL_4PASS_1_EXT = constant.Constant( 'GL_4PASS_1_EXT', 0x80A5 ) GL_4PASS_2_EXT = constant.Constant( 'GL_4PASS_2_EXT', 0x80A6 ) GL_4PASS_3_EXT = constant.Constant( 'GL_4PASS_3_EXT', 0x80A7 ) GL_SAMPLE_BUFFERS_EXT = constant.Constant( 'GL_SAMPLE_BUFFERS_EXT', 0x80A8 ) GL_SAMPLES_EXT = constant.Constant( 'GL_SAMPLES_EXT', 0x80A9 ) GL_SAMPLE_MASK_VALUE_EXT = constant.Constant( 'GL_SAMPLE_MASK_VALUE_EXT', 0x80AA ) GL_SAMPLE_MASK_INVERT_EXT = constant.Constant( 'GL_SAMPLE_MASK_INVERT_EXT', 0x80AB ) GL_SAMPLE_PATTERN_EXT = constant.Constant( 'GL_SAMPLE_PATTERN_EXT', 0x80AC ) GL_MULTISAMPLE_BIT_EXT = constant.Constant( 'GL_MULTISAMPLE_BIT_EXT', 0x20000000 ) glSampleMaskEXT = platform.createExtensionFunction( 'glSampleMaskEXT', dll=platform.GL, extension=EXTENSION_NAME, resultType=None, argTypes=(constants.GLclampf, constants.GLboolean,), doc = 'glSampleMaskEXT( GLclampf(value), GLboolean(invert) ) -> None', argNames = ('value', 'invert',), ) glSamplePatternEXT = platform.createExtensionFunction( 'glSamplePatternEXT', dll=platform.GL, extension=EXTENSION_NAME, resultType=None, argTypes=(constants.GLenum,), doc = 'glSamplePatternEXT( GLenum(pattern) ) -> None', argNames = ('pattern',), ) def glInitMultisampleEXT(): '''Return boolean indicating whether this extension is available''' return extensions.hasGLExtension( EXTENSION_NAME )
44.980769
88
0.80077
315
2,339
5.577778
0.295238
0.106431
0.183836
0.203187
0.385316
0.197496
0.11383
0.075128
0.075128
0.075128
0
0.04539
0.095767
2,339
51
89
45.862745
0.785343
0.129543
0
0.1
1
0
0.239783
0.081733
0
0
0.052191
0
0
1
0.025
false
0.175
0.1
0
0.15
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
1
0
0
0
null
0
0
0
0
0
0
0
1
0
0
0
0
0
4
ca96757218b3a2f3445c0ef6429030c1be6d1426
124
py
Python
src/__init__.py
heyhpython/desktop
e75ffddf9526e8fd1adaca69c315005e202bf84b
[ "MIT" ]
null
null
null
src/__init__.py
heyhpython/desktop
e75ffddf9526e8fd1adaca69c315005e202bf84b
[ "MIT" ]
null
null
null
src/__init__.py
heyhpython/desktop
e75ffddf9526e8fd1adaca69c315005e202bf84b
[ "MIT" ]
null
null
null
""" @author: yuhao.he @contact: <hawl.yuhao.he@gmail.com> @version: 0.0.1 @file: __init__.py.py @time: 2021/10/27 14:11 """
15.5
35
0.653226
23
124
3.347826
0.826087
0.181818
0
0
0
0
0
0
0
0
0
0.135135
0.104839
124
7
36
17.714286
0.558559
0.927419
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
045f00f5b6aaa9638f1ae95823077ee76ae94007
73
py
Python
salt/cli/__init__.py
markgras/salt
d66cd3c935533c63870b83228b978ce43e0ef70d
[ "Apache-2.0" ]
9,425
2015-01-01T05:59:24.000Z
2022-03-31T20:44:05.000Z
salt/cli/__init__.py
markgras/salt
d66cd3c935533c63870b83228b978ce43e0ef70d
[ "Apache-2.0" ]
33,507
2015-01-01T00:19:56.000Z
2022-03-31T23:48:20.000Z
salt/cli/__init__.py
markgras/salt
d66cd3c935533c63870b83228b978ce43e0ef70d
[ "Apache-2.0" ]
5,810
2015-01-01T19:11:45.000Z
2022-03-31T02:37:20.000Z
""" The management of salt command line utilities are stored in here """
18.25
64
0.739726
11
73
4.909091
1
0
0
0
0
0
0
0
0
0
0
0
0.178082
73
3
65
24.333333
0.9
0.876712
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
046a52ff392852c4ba1432020c4349f6fdb49103
434
py
Python
juq/service/group_service.py
inhzus/juq
2721f1361eed3d4e7da36d67f924942faef24650
[ "MIT" ]
14
2019-04-09T23:34:56.000Z
2022-01-17T14:19:51.000Z
juq/service/group_service.py
inhzus/juq
2721f1361eed3d4e7da36d67f924942faef24650
[ "MIT" ]
null
null
null
juq/service/group_service.py
inhzus/juq
2721f1361eed3d4e7da36d67f924942faef24650
[ "MIT" ]
4
2020-03-29T15:29:59.000Z
2022-01-17T14:19:44.000Z
# -*- coding: utf-8 -*- # created by inhzus from juq.handler import group_handler, repo_handler from .utils import filter_empty_params # noinspection PyShadowingBuiltins def info(id_: str, **_): return group_handler.get_group_info(id_=id_) # noinspection PyShadowingBuiltins def repos(group_id: str, type: str, offset: int, **_): return '\n'.join(map(repr, repo_handler.get_group_repos(**filter_empty_params(locals()))))
27.125
94
0.748848
59
434
5.20339
0.559322
0.078176
0.110749
0
0
0
0
0
0
0
0
0.002632
0.124424
434
15
95
28.933333
0.805263
0.241935
0
0
0
0
0.006173
0
0
0
0
0
0
1
0.333333
false
0
0.333333
0.333333
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
0472b745d5b6b80f8b4c4fbd40558659279d2a11
135
py
Python
main.py
quicksandznzn/text-correction-ernie
4813a8ad9ded375731c19db39dbae49e275d98a4
[ "Apache-2.0" ]
null
null
null
main.py
quicksandznzn/text-correction-ernie
4813a8ad9ded375731c19db39dbae49e275d98a4
[ "Apache-2.0" ]
null
null
null
main.py
quicksandznzn/text-correction-ernie
4813a8ad9ded375731c19db39dbae49e275d98a4
[ "Apache-2.0" ]
null
null
null
from paddlenlp import Taskflow text_correction = Taskflow("text_correction",home_path='./') res = text_correction('把我的收集拿来') print(res)
33.75
60
0.792593
17
135
6.058824
0.647059
0.407767
0.427184
0
0
0
0
0
0
0
0
0
0.074074
135
4
61
33.75
0.824
0
0
0
0
0
0.176471
0
0
0
0
0
0
1
0
false
0
0.25
0
0.25
0.25
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