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
c599aa29798e4d07df0488603542e4a45cc49cf4
812
py
Python
docsim/utils/text.py
tarohi24/docsim
4879bcc889c32470a27094eb183c2ce15ae2f1fb
[ "MIT" ]
1
2020-04-29T13:52:29.000Z
2020-04-29T13:52:29.000Z
docsim/utils/text.py
tarohi24/docsim
4879bcc889c32470a27094eb183c2ce15ae2f1fb
[ "MIT" ]
136
2019-09-19T03:36:21.000Z
2019-11-28T08:50:45.000Z
docsim/utils/text.py
tarohi24/docsim
4879bcc889c32470a27094eb183c2ce15ae2f1fb
[ "MIT" ]
null
null
null
from collections import Counter import re from typing import List, Pattern, Set from nltk.corpus import stopwords from nltk.tokenize import word_tokenize pat_token_non_alphabet: Pattern = re.compile('^[^a-z]+$') stop_words: Set[str] = set(stopwords.words('english')) def tokenize(text: str) -> List[str]: return word_tokenize(text) def remove_stopwords(tokens: List[str]) -> List[str]: return [w for w in tokens if w not in stop_words] def remove_nonalphabet_tokens(tokens: List[str]) -> List[str]: """ it requires `lower` in advance """ return [w for w in tokens if pat_token_non_alphabet.match(w) is None] def extract_toptf_tokens(tokens: List[str], n_words: int) -> List[str]: return [token for token, _ in Counter(tokens).most_common(n_words)]
26.193548
73
0.698276
122
812
4.491803
0.401639
0.089416
0.054745
0.069343
0.149635
0.076642
0.076642
0
0
0
0
0
0.185961
812
30
74
27.066667
0.829047
0.036946
0
0
0
0
0.020888
0
0
0
0
0
0
1
0.25
false
0
0.3125
0.1875
0.8125
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
c5b0e559e678c389244be8dd999e15c18f6e5063
295
py
Python
depricated/oop-in-python/multi_sided_die.py
Umuzi-org/tech-department
de5b714a6e706aca8d78a8f76a6562bbf935d5b3
[ "MIT" ]
1
2019-05-17T05:13:24.000Z
2019-05-17T05:13:24.000Z
depricated/oop-in-python/multi_sided_die.py
Umuzi-org/tech-department
de5b714a6e706aca8d78a8f76a6562bbf935d5b3
[ "MIT" ]
278
2019-03-12T08:43:08.000Z
2020-09-17T05:57:11.000Z
depricated/oop-in-python/multi_sided_die.py
Umuzi-org/tech-department
de5b714a6e706aca8d78a8f76a6562bbf935d5b3
[ "MIT" ]
18
2019-03-14T12:51:00.000Z
2020-08-03T09:21:40.000Z
#class definition for an n-sided die #import packages class MultiSidedDie: #constructor here #define method 'roll' to roll the MultiSidedDie #define method 'get_value' to return the current value of the MultiSidedDie #define method 'set_value' to set the die to a particular value
21.071429
77
0.766102
44
295
5.090909
0.568182
0.160714
0.196429
0.25
0
0
0
0
0
0
0
0
0.186441
295
13
78
22.692308
0.933333
0.840678
0
0
0
0
0
0
0
0
0
0
0
0
null
null
0
0
null
null
0
0
0
0
null
0
1
1
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
1
0
0
0
0
0
0
0
0
4
c5c62b67a6b24c242fc1cf561231dfe64b050ae8
25
py
Python
data/studio21_generated/introductory/4469/starter_code.py
vijaykumawat256/Prompt-Summarization
614f5911e2acd2933440d909de2b4f86653dc214
[ "Apache-2.0" ]
null
null
null
data/studio21_generated/introductory/4469/starter_code.py
vijaykumawat256/Prompt-Summarization
614f5911e2acd2933440d909de2b4f86653dc214
[ "Apache-2.0" ]
null
null
null
data/studio21_generated/introductory/4469/starter_code.py
vijaykumawat256/Prompt-Summarization
614f5911e2acd2933440d909de2b4f86653dc214
[ "Apache-2.0" ]
null
null
null
def is_narcissistic(i):
12.5
23
0.76
4
25
4.5
1
0
0
0
0
0
0
0
0
0
0
0
0.12
25
2
24
12.5
0.818182
0
0
0
0
0
0
0
0
0
0
0
0
0
null
null
0
0
null
null
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
1
0
0
0
0
0
0
0
0
4
a83e7ad0e1065d307212385f0813844e4a5c4ab8
162
py
Python
python/tHome/sma/test/real/energy.py
ZigmundRat/T-Home
5dc8689f52d87dac890051e540b338b009293ced
[ "BSD-2-Clause" ]
18
2016-04-17T19:39:28.000Z
2020-11-19T06:55:20.000Z
python/tHome/sma/test/real/energy.py
ZigmundRat/T-Home
5dc8689f52d87dac890051e540b338b009293ced
[ "BSD-2-Clause" ]
6
2016-10-31T13:53:45.000Z
2019-03-20T20:47:03.000Z
python/tHome/sma/test/real/energy.py
ZigmundRat/T-Home
5dc8689f52d87dac890051e540b338b009293ced
[ "BSD-2-Clause" ]
12
2016-10-31T12:29:08.000Z
2021-12-28T12:18:28.000Z
#!/usr/bin/env python import tHome as T #T.util.log.get( 'sma', 10, 'stdout' ) r = T.sma.report.energy( ip="192.168.1.14" ) print "==================" print r
16.2
44
0.555556
28
162
3.214286
0.821429
0
0
0
0
0
0
0
0
0
0
0.079137
0.141975
162
9
45
18
0.568345
0.351852
0
0
0
0
0.291262
0
0
0
0
0
0
0
null
null
0
0.25
null
null
0.5
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
1
0
0
0
0
0
0
1
0
4
a87b5edf283155b61cbd60f4d6403530f5a33271
339
py
Python
tests/domain/cost/test_cost_factory.py
cdaksha/parametrization_clean
702243d87c2045cf8155f3c18134665871f3b170
[ "MIT" ]
5
2020-12-05T06:29:08.000Z
2022-03-28T16:23:46.000Z
tests/domain/cost/test_cost_factory.py
chemshift/parametrization_clean
702243d87c2045cf8155f3c18134665871f3b170
[ "MIT" ]
2
2021-08-25T16:12:30.000Z
2022-02-10T02:23:06.000Z
tests/domain/cost/test_cost_factory.py
chemshift/parametrization_clean
702243d87c2045cf8155f3c18134665871f3b170
[ "MIT" ]
1
2020-12-05T06:22:49.000Z
2020-12-05T06:22:49.000Z
# Standard library # 3rd party packages # Local source from parametrization_clean.domain.cost.factory import ErrorFactory from parametrization_clean.domain.cost.reax_error import ReaxError def test_get_reax_error(): reax_error_calculator = ErrorFactory.create_executor('reax_error') assert reax_error_calculator == ReaxError
22.6
70
0.820059
42
339
6.333333
0.595238
0.169173
0.180451
0.225564
0.255639
0
0
0
0
0
0
0.003356
0.120944
339
14
71
24.214286
0.889262
0.141593
0
0
0
0
0.035088
0
0
0
0
0
0.2
1
0.2
false
0
0.4
0
0.6
0
0
0
0
null
0
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
4
a8b1405dfba3b52ef378e2817dc5170467c5ddaf
242
py
Python
hood/admin.py
Cian747/neighborhood
f84ef4f24b21f8b5489df2e97c649a42b1f9a8fd
[ "MIT" ]
null
null
null
hood/admin.py
Cian747/neighborhood
f84ef4f24b21f8b5489df2e97c649a42b1f9a8fd
[ "MIT" ]
null
null
null
hood/admin.py
Cian747/neighborhood
f84ef4f24b21f8b5489df2e97c649a42b1f9a8fd
[ "MIT" ]
null
null
null
from django.contrib import admin from .models import Neighborhood,Profile,Business,Meeting # Register your models here. admin.site.register(Neighborhood) admin.site.register(Profile) admin.site.register(Business) admin.site.register(Meeting)
30.25
57
0.834711
32
242
6.3125
0.4375
0.178218
0.336634
0
0
0
0
0
0
0
0
0
0.070248
242
8
58
30.25
0.897778
0.107438
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.333333
0
0.333333
0
0
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
4
a8d1f196b82bdbdf69e0ca4489cb7d5278ca41e7
4,536
py
Python
test/test_image_folder_member_api.py
tweak-com-public/tweak-api-client-python
019f86da11fdb12683d516f8f37db5d717380bcc
[ "Apache-2.0" ]
null
null
null
test/test_image_folder_member_api.py
tweak-com-public/tweak-api-client-python
019f86da11fdb12683d516f8f37db5d717380bcc
[ "Apache-2.0" ]
null
null
null
test/test_image_folder_member_api.py
tweak-com-public/tweak-api-client-python
019f86da11fdb12683d516f8f37db5d717380bcc
[ "Apache-2.0" ]
null
null
null
# coding: utf-8 """ tweak-api Tweak API to integrate with all the Tweak services. You can find out more about Tweak at <a href='https://www.tweak.com'>https://www.tweak.com</a>, #tweak. OpenAPI spec version: 1.0.8-beta.0 Generated by: https://github.com/swagger-api/swagger-codegen.git Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. """ from __future__ import absolute_import import os import sys import unittest import TweakApi from TweakApi.rest import ApiException from TweakApi.apis.image_folder_member_api import ImageFolderMemberApi class TestImageFolderMemberApi(unittest.TestCase): """ ImageFolderMemberApi unit test stubs """ def setUp(self): self.api = TweakApi.apis.image_folder_member_api.ImageFolderMemberApi() def tearDown(self): pass def test_image_folder_members_change_stream_get(self): """ Test case for image_folder_members_change_stream_get Create a change stream. """ pass def test_image_folder_members_change_stream_post(self): """ Test case for image_folder_members_change_stream_post Create a change stream. """ pass def test_image_folder_members_count_get(self): """ Test case for image_folder_members_count_get Count instances of the model matched by where from the data source. """ pass def test_image_folder_members_find_one_get(self): """ Test case for image_folder_members_find_one_get Find first instance of the model matched by filter from the data source. """ pass def test_image_folder_members_get(self): """ Test case for image_folder_members_get Find all instances of the model matched by filter from the data source. """ pass def test_image_folder_members_id_delete(self): """ Test case for image_folder_members_id_delete Delete a model instance by {{id}} from the data source. """ pass def test_image_folder_members_id_exists_get(self): """ Test case for image_folder_members_id_exists_get Check whether a model instance exists in the data source. """ pass def test_image_folder_members_id_folder_get(self): """ Test case for image_folder_members_id_folder_get Fetches belongsTo relation folder. """ pass def test_image_folder_members_id_get(self): """ Test case for image_folder_members_id_get Find a model instance by {{id}} from the data source. """ pass def test_image_folder_members_id_head(self): """ Test case for image_folder_members_id_head Check whether a model instance exists in the data source. """ pass def test_image_folder_members_id_member_get(self): """ Test case for image_folder_members_id_member_get Fetches belongsTo relation member. """ pass def test_image_folder_members_id_patch(self): """ Test case for image_folder_members_id_patch Patch attributes for a model instance and persist it into the data source. """ pass def test_image_folder_members_id_put(self): """ Test case for image_folder_members_id_put Replace attributes for a model instance and persist it into the data source. """ pass def test_image_folder_members_id_replace_post(self): """ Test case for image_folder_members_id_replace_post Replace attributes for a model instance and persist it into the data source. """ pass def test_image_folder_members_post(self): """ Test case for image_folder_members_post Create a new instance of the model and persist it into the data source. """ pass if __name__ == '__main__': unittest.main()
27
165
0.669092
606
4,536
4.737624
0.244224
0.122605
0.188088
0.125392
0.629746
0.611634
0.546151
0.524556
0.37931
0.295019
0
0.002729
0.272928
4,536
167
166
27.161677
0.867799
0.533069
0
0.363636
0
0
0.005054
0
0
0
0
0
0
1
0.386364
false
0.363636
0.159091
0
0.568182
0
0
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
1
0
0
1
0
0
4
764d0904e8efa18d48daf7c7da132867bee88e3e
362
py
Python
app/encryption.py
uk-gov-mirror/alphagov.digitalmarketplace-api
5a1db63691d0c4a435714837196ab6914badaf62
[ "MIT" ]
25
2015-01-14T10:45:13.000Z
2021-05-26T17:21:41.000Z
app/encryption.py
uk-gov-mirror/alphagov.digitalmarketplace-api
5a1db63691d0c4a435714837196ab6914badaf62
[ "MIT" ]
641
2015-01-15T11:10:50.000Z
2021-06-15T22:18:42.000Z
app/encryption.py
uk-gov-mirror/alphagov.digitalmarketplace-api
5a1db63691d0c4a435714837196ab6914badaf62
[ "MIT" ]
22
2015-06-13T15:37:45.000Z
2021-08-19T23:40:49.000Z
from flask_bcrypt import generate_password_hash, check_password_hash def authenticate_user(password, user): return checkpw(password, user.password) and not user.locked def hashpw(password): return generate_password_hash(password, 10).decode('utf-8') def checkpw(password, hashed_password): return check_password_hash(hashed_password, password)
25.857143
68
0.801105
48
362
5.791667
0.458333
0.172662
0.143885
0
0
0
0
0
0
0
0
0.009404
0.118785
362
13
69
27.846154
0.862069
0
0
0
1
0
0.013812
0
0
0
0
0
0
1
0.428571
false
1
0.142857
0.428571
1
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
null
0
0
0
0
0
1
0
1
0
1
0
0
0
4
765212fcfadc9a1f280d22179e1495cbe431a3d5
352
py
Python
libs/yowsup/yowsup/yowsup/layers/protocol_iq/protocolentities/__init__.py
akshitpradhan/TomHack
837226e7b38de1140c19bc2d478eeb9e379ed1fd
[ "MIT" ]
22
2017-07-14T20:01:17.000Z
2022-03-08T14:22:39.000Z
libs/yowsup/yowsup/yowsup/layers/protocol_iq/protocolentities/__init__.py
akshitpradhan/TomHack
837226e7b38de1140c19bc2d478eeb9e379ed1fd
[ "MIT" ]
6
2017-07-14T21:03:50.000Z
2021-06-10T19:08:32.000Z
libs/yowsup/yowsup/yowsup/layers/protocol_iq/protocolentities/__init__.py
akshitpradhan/TomHack
837226e7b38de1140c19bc2d478eeb9e379ed1fd
[ "MIT" ]
13
2017-07-14T20:13:14.000Z
2020-11-12T08:06:05.000Z
from .iq import IqProtocolEntity from .iq_result import ResultIqProtocolEntity from .iq_ping import PingIqProtocolEntity from .iq_result_pong import PongResultIqProtocolEntity from .iq_error import ErrorIqProtocolEntity from .iq_push import PushIqProtocolEntity from .iq_props import PropsIqProtocolEntity from .iq_crypto import CryptoIqProtocolEntity
39.111111
54
0.886364
40
352
7.6
0.45
0.157895
0.078947
0
0
0
0
0
0
0
0
0
0.090909
352
8
55
44
0.95
0
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
769d2b5bb79ca64edefc54d7ead011339edc3cbe
275
py
Python
isdigit.py
aash-gates/aash-python-babysteps
cb88b02b0d33ac74acb183d4f11f6baad0ad3db9
[ "Unlicense" ]
7
2020-11-16T18:23:21.000Z
2021-12-18T14:08:54.000Z
isdigit.py
aash-gates/aash-python-babysteps
cb88b02b0d33ac74acb183d4f11f6baad0ad3db9
[ "Unlicense" ]
null
null
null
isdigit.py
aash-gates/aash-python-babysteps
cb88b02b0d33ac74acb183d4f11f6baad0ad3db9
[ "Unlicense" ]
1
2020-12-21T15:59:44.000Z
2020-12-21T15:59:44.000Z
#checking the string for digit IBM Digital Nation only_digits ="1234567890" print(only_digits.isdigit()) #returns True has_digit = "AfG89K" print(has_digit.isdigit()) #returns False no_digit = "Onlyfans" print(no_digit.isdigit()) #returns false #end of the Program
14.473684
49
0.752727
39
275
5.153846
0.589744
0.208955
0.189055
0.238806
0
0
0
0
0
0
0
0.050847
0.141818
275
18
50
15.277778
0.800847
0.378182
0
0
0
0
0.147239
0
0
0
0
0
0
1
0
false
0
0
0
0
0.5
0
0
0
null
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
1
0
4
76c2c96f15e85d2e79081659d351811d69261cf6
1,907
py
Python
bananas/transformers/__init__.py
owahltinez/bananas
4d37af1713b7f166ead3459a7004748f954d336e
[ "MIT" ]
null
null
null
bananas/transformers/__init__.py
owahltinez/bananas
4d37af1713b7f166ead3459a7004748f954d336e
[ "MIT" ]
null
null
null
bananas/transformers/__init__.py
owahltinez/bananas
4d37af1713b7f166ead3459a7004748f954d336e
[ "MIT" ]
null
null
null
""" Extensions of `Learner` objects whose object is to transform data. Transformers are `Learner` objects that *may* modify the data in some way and, instead of the usual `predict`, implement the method `transform`. Transformers are typically used as part of a [Pipeline](../core/index.md#pipeline), serving as a data processing step. While users are encouraged to write their own, custom transformers, this library aims to provide the majority of the most commonly used transformers. ## Shape change handling The main benefit of using one of the built-in transformers is that they all properly handle changes of input shape, as well as firing of the corresponding output shape events. When implementing our own custom transformers, we should consider extending `ColumnHandlingTransformer` rather than the base `BaseTransformer` class. ## Initialization All of the built-in transformers inherit from `ColumnHandlingTransformer`. They all accept an argument `columns` in the constructor which describes the features that we wish to transform. This is so we can leave the other features unmodified, without having to split our data. The `columns` argument can be a list of indices of the features that we wish to transform, or a dictionary where the keys are the indices that we wish to transform and the values are the potential values that the feature may take. This is done so we can accommodate for potential unseen samples ahead of time, and avoid additional shape changes. If no arguments `columns` is given, it defaults to applying the transformation to all columns. We can also pass an empty list `[]` to explicitly tell the transformer that no features should be transformed. """ from .base import BaseTransformer from .encoders import LabelEncoder, OneHotEncoder from .scalers import MinMaxScaler, StandardScaler from .running_stats import RunningStats from .threshold import VarianceThreshold
56.088235
100
0.806502
287
1,907
5.355401
0.522648
0.019519
0.019519
0.023422
0.086532
0.04164
0.04164
0
0
0
0
0
0.152071
1,907
33
101
57.787879
0.950526
0.882014
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
4
76c3d0a2a07e226e58670610d923bbfdd1802eff
5,368
py
Python
wagl/modtran_profiles.py
ASVincent/wagl
cf3a72e53e53f3a7b2f2b5308068069b1b714f2a
[ "Apache-2.0" ]
null
null
null
wagl/modtran_profiles.py
ASVincent/wagl
cf3a72e53e53f3a7b2f2b5308068069b1b714f2a
[ "Apache-2.0" ]
null
null
null
wagl/modtran_profiles.py
ASVincent/wagl
cf3a72e53e53f3a7b2f2b5308068069b1b714f2a
[ "Apache-2.0" ]
1
2019-01-23T00:51:56.000Z
2019-01-23T00:51:56.000Z
#!/usr/bin/env python # pragma pylint: disable=line-too-long from __future__ import absolute_import, print_function """ These are the templates for the inputs into MODTRAN. Parameters to be inserted are: * albedo * water vapour; units: g/cm^2 * ozone; units: ATM-cm * filter function (spectral response of sensor) * aerosol visibility; optical depth at 550 nm (negative); units: km * elevation (sourced from a DSM); units: km above sea level * satellite height; units: km * satellite view angle (zenith); corrected (180 - angle); units: degrees * julian day of year * latitude; units: degrees * longitude; corrected (360 - angle); units: degrees * time; units: decimal hours in UTC * satellite azimuth angle; corrected (angle + 180); units: degrees * satellite view offset; (180 - angle); units: degrees """ MIDLAT_SUMMER_ALBEDO = ("""\ TM{binary} 2 2 2 1 2 2 2 2 2 2 1 1 0 10.000{albedo:7.2f} TFF 8 0 375.000 g{water:7.5f} a{ozone:5.3f} T f f t 0.3 0 0.70 0 0 {filter_function:<75} 1 0 0 0 0 0{visibility:10.3f} 0.000 0.000 0.000{elevation:10.3f} {sat_height:10.3f}{elevation:10.3f}{sat_view:10.3f} 0.000 0.000 0.000 0 0.000 1 0{doy:5d} 0 {lat:10.3f}{lon:10.3f} 0.000 0.000{time:10.3f}{sat_azimuth:10.3f} 0.000 0.667 350.0 2600.0 1.0 1.0RN# NT T 0 """) TROPICAL_ALBEDO = ("""\ TM{binary} 1 2 2 1 1 1 1 1 1 1 1 1 0 10.000{albedo:7.2f} TFF 8 0 375.000 g{water:7.5f} a{ozone:5.3f} T f f t 0.3 0 0.70 0 0 {filter_function:<75} 1 0 0 0 0 0{visibility:10.3f} 0.000 0.000 0.000{elevation:10.3f} {sat_height:10.3f}{elevation:10.3f}{sat_view:10.3f} 0.000 0.000 0.000 0 0.000 1 0{doy:5d} 0 {lat:10.3f}{lon:10.3f} 0.000 0.000{time:10.3f}{sat_azimuth:10.3f} 0.000 0.667 350.0 2600.0 1.0 1.0RN# NT T 0 """) MIDLAT_SUMMER_TRANSMITTANCE = ("""\ TM{binary} 2 2 2 1 2 2 2 2 2 2 1 1 0 10.000{albedo:7.2f} TFF 8 0 375.000 g{water:7.5f} a{ozone:5.3f} T f f t 0.3 0 0.70 0 0 {filter_function:<75} 1 0 0 0 0 0{visibility:10.5f} 0.000 0.000 0.000{elevation:10.3f} {sat_height:10.3f}{elevation:10.3f}{sat_view:10.3f} 0.000 0.000 0.000 0 0.000 2 0{doy:5d} 0 0.000{sat_view_offset:10.3f} 0.667 350.0 2600.0 1.0 1.0RN# NT T 0 """) TROPICAL_TRANSMITTANCE = ("""\ TM{binary} 1 2 2 1 1 1 1 1 1 1 1 1 0 10.000{albedo:7.2f} TFF 8 0 375.000 g{water:7.5f} a{ozone:5.3f} T f f t 0.3 0 0.70 0 0 {filter_function:<75} 1 0 0 0 0 0{visibility:10.5f} 0.000 0.000 0.000{elevation:10.3f} {sat_height:10.3f}{elevation:10.3f}{sat_view:10.3f} 0.000 0.000 0.000 0 0.000 2 0{doy:5d} 0 0.000{sat_view_offset:10.3f} 0.667 350.0 2600.0 1.0 1.0RN# NT T 0 """) THERMAL_TRANSMITTANCE = ("""\ T {binary} 7 2 1 0 2 2 2 2 2 2 1 1 0 10.000 0.00 F 0F 0 375.000 1.0 a{ozone:5.3f} 4 T {filter_function:<75} 1 0 0 0 0 0{visibility:10.3f} 0.000 0.000 0.000{gpheight:10.3f} {n:5d} 0 0 {atmospheric_profile} 50.000 9.510E-01 2.550E+00 7.127E-05 0.000E+00 0.000E+00ABH 55.000 5.150E-01-3.850E+00 5.991E-05 0.000E+00 0.000E+00ABH 60.000 2.720E-01-1.605E+01 7.753E-05 0.000E+00 0.000E+00ABH 70.000 6.700E-02-5.505E+01 7.083E-04 0.000E+00 0.000E+00ABH 80.000 1.200E-02-9.905E+01 7.237E-02 0.000E+00 0.000E+00ABH 100.000 0.100E-03-8.265E+01 1.461E-05 0.000E+00 0.000E+00ABH {sat_height:10.3f}{gpheight:10.3f}{sat_view:10.3f} 7000.0 14100.0 10.0 20.0TN NT 3 {gpheight:10.3f}{sat_height:10.3f} 55.770 0 """) SBT_FORMAT = '\n{gpheight:10.3f}{pressure:10.3E}{airtemp:10.3E}{humidity:10.3E}{zero:10.3E}{zero:10.3E}ABH'
58.347826
122
0.4307
805
5,368
2.826087
0.204969
0.068571
0.057143
0.07033
0.556484
0.547692
0.518681
0.485275
0.485275
0.485275
0
0.300452
0.463674
5,368
91
123
58.989011
0.489753
0.010618
0
0.59375
0
0.421875
0.946076
0.172512
0
0
0
0
0
1
0
false
0
0.015625
0
0.015625
0.015625
0
0
0
null
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
1
0
0
0
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
76c73408cb56005eefcecf6f0e93572acd255942
615
py
Python
tests/test_configs.py
vkottler/datazen
e493a0427b0686811f8aeb719bae035f999c8a57
[ "MIT" ]
2
2021-02-17T00:16:07.000Z
2022-02-27T00:14:12.000Z
tests/test_configs.py
vkottler/datazen
e493a0427b0686811f8aeb719bae035f999c8a57
[ "MIT" ]
53
2020-11-02T07:10:21.000Z
2022-03-29T09:04:01.000Z
tests/test_configs.py
vkottler/datazen
e493a0427b0686811f8aeb719bae035f999c8a57
[ "MIT" ]
null
null
null
""" datazen - Tests for the 'configs' API. """ # internal from . import ENV def test_load_configs(): """Test that the configuration data can be loaded.""" config_data = ENV.get_configs(True) expected = {"a": "a", "b": "b", "c": "c"} assert config_data["a"] == expected assert config_data["b"] == expected assert config_data["c"] == expected assert config_data["d"]["d"] == "d" assert config_data["d"]["d"] == "d" assert config_data["e"]["e"] == "e" assert config_data["f"]["f"] == "f" assert config_data["yaml"] == "yaml" assert config_data["json"] == "json"
22.777778
57
0.58374
84
615
4.119048
0.380952
0.289017
0.416185
0.208092
0.156069
0.156069
0.156069
0.156069
0.156069
0
0
0
0.20813
615
26
58
23.653846
0.710472
0.156098
0
0.153846
0
0
0.073123
0
0
0
0
0
0.692308
1
0.076923
false
0
0.076923
0
0.153846
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
1
0
0
0
0
0
0
0
0
0
4
76cc02dffd84454f4749c0b80ea41d945ddd3d69
77
py
Python
src/pytest_pypi_gateway/plugin.py
uranusjr/pytest-pypi-gateway
1a326f8db6d24b13e827169843f76553581a9f5e
[ "0BSD" ]
null
null
null
src/pytest_pypi_gateway/plugin.py
uranusjr/pytest-pypi-gateway
1a326f8db6d24b13e827169843f76553581a9f5e
[ "0BSD" ]
null
null
null
src/pytest_pypi_gateway/plugin.py
uranusjr/pytest-pypi-gateway
1a326f8db6d24b13e827169843f76553581a9f5e
[ "0BSD" ]
null
null
null
import pytest @pytest.fixture(scope='session') def pypi(request): pass
11
32
0.714286
10
77
5.5
0.9
0
0
0
0
0
0
0
0
0
0
0
0.155844
77
6
33
12.833333
0.846154
0
0
0
0
0
0.090909
0
0
0
0
0
0
1
0.25
false
0.25
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
0
1
0
0
0
0
0
4
4f17c85d7dbfa4ebf4751de457c76bb7f0704862
126
py
Python
AtC_Beg_Con_051-060/ABC059/B.py
yosho-18/AtCoder
50f6d5c92a01792552c31ac912ce1cd557b06fb0
[ "MIT" ]
null
null
null
AtC_Beg_Con_051-060/ABC059/B.py
yosho-18/AtCoder
50f6d5c92a01792552c31ac912ce1cd557b06fb0
[ "MIT" ]
null
null
null
AtC_Beg_Con_051-060/ABC059/B.py
yosho-18/AtCoder
50f6d5c92a01792552c31ac912ce1cd557b06fb0
[ "MIT" ]
null
null
null
a = int(input()) b = int(input()) if a > b: print("GREATER") elif a == b: print("EQUAL") elif a < b: print("LESS")
15.75
20
0.515873
21
126
3.095238
0.47619
0.092308
0.323077
0.338462
0
0
0
0
0
0
0
0
0.253968
126
8
21
15.75
0.691489
0
0
0
0
0
0.125984
0
0
0
0
0
0
1
0
false
0
0
0
0
0.375
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
4f3cb74fb1c9e1d164e03e294b78ae08075cc902
103
py
Python
space_manager/qrcodes/apps.py
yoojat/Space-Manager
dd482eb8a3ac8b5d4d06c63e5a5d9ccaeb3ce7b9
[ "MIT" ]
null
null
null
space_manager/qrcodes/apps.py
yoojat/Space-Manager
dd482eb8a3ac8b5d4d06c63e5a5d9ccaeb3ce7b9
[ "MIT" ]
1
2018-02-27T15:21:53.000Z
2018-02-27T15:21:53.000Z
space_manager/qrcodes/apps.py
yoojat/Space-Manager
dd482eb8a3ac8b5d4d06c63e5a5d9ccaeb3ce7b9
[ "MIT" ]
1
2018-02-16T08:31:30.000Z
2018-02-16T08:31:30.000Z
from django.apps import AppConfig class QrcodesConfig(AppConfig): name = 'space_manager.qrcodes'
17.166667
34
0.776699
12
103
6.583333
0.916667
0
0
0
0
0
0
0
0
0
0
0
0.145631
103
5
35
20.6
0.897727
0
0
0
0
0
0.203884
0.203884
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
96d60df24d449f1d1c908404ea3ae1d5c1c9407a
98
py
Python
codeforces/anirudhak47/1354/C1.py
anirudhakulkarni/codes
d7a907951033b57314dfc0b837123aaa5c25a39a
[ "MIT" ]
3
2020-07-09T16:15:42.000Z
2020-07-17T13:19:42.000Z
codeforces/anirudhak47/1354/C1.py
anirudhakulkarni/codes
d7a907951033b57314dfc0b837123aaa5c25a39a
[ "MIT" ]
null
null
null
codeforces/anirudhak47/1354/C1.py
anirudhakulkarni/codes
d7a907951033b57314dfc0b837123aaa5c25a39a
[ "MIT" ]
1
2020-07-17T13:19:48.000Z
2020-07-17T13:19:48.000Z
import math for _ in range(int(input())): n=int(input()) n=2*n print(1/math.tan(math.pi/n))
19.6
30
0.622449
20
98
3
0.65
0.266667
0.3
0
0
0
0
0
0
0
0
0.024096
0.153061
98
5
31
19.6
0.698795
0
0
0
0
0
0
0
0
0
0
0
0
1
0
false
0
0.2
0
0.2
0.2
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
96eb570d97740c3963f2cc6425fe32a4cdc76174
195
py
Python
django_echarts/views/__init__.py
aldslvda/django-echarts
835032def8c67c5ff81824be0c9a6a776334c3e9
[ "MIT" ]
181
2017-07-30T04:37:41.000Z
2022-03-27T04:58:04.000Z
django_echarts/views/__init__.py
aldslvda/django-echarts
835032def8c67c5ff81824be0c9a6a776334c3e9
[ "MIT" ]
22
2017-07-30T11:49:34.000Z
2022-03-28T12:44:07.000Z
django_echarts/views/__init__.py
aldslvda/django-echarts
835032def8c67c5ff81824be0c9a6a776334c3e9
[ "MIT" ]
57
2017-08-12T09:47:09.000Z
2022-03-28T07:20:53.000Z
# coding=utf8 from .base import EChartsMixin from .backend import EChartsBackendView from .frontend import EChartsFrontView __all__ = ['EChartsMixin', 'EChartsBackendView', 'EChartsFrontView']
24.375
68
0.810256
18
195
8.555556
0.611111
0
0
0
0
0
0
0
0
0
0
0.005747
0.107692
195
7
69
27.857143
0.87931
0.05641
0
0
0
0
0.252747
0
0
0
0
0
0
1
0
false
0
0.75
0
0.75
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
4
8c267f770de0eb203816def145424a2c32b9956c
169
py
Python
custom/nic_compliance/const.py
dimagilg/commcare-hq
ea1786238eae556bb7f1cbd8d2460171af1b619c
[ "BSD-3-Clause" ]
471
2015-01-10T02:55:01.000Z
2022-03-29T18:07:18.000Z
custom/nic_compliance/const.py
dimagilg/commcare-hq
ea1786238eae556bb7f1cbd8d2460171af1b619c
[ "BSD-3-Clause" ]
14,354
2015-01-01T07:38:23.000Z
2022-03-31T20:55:14.000Z
custom/nic_compliance/const.py
dimagilg/commcare-hq
ea1786238eae556bb7f1cbd8d2460171af1b619c
[ "BSD-3-Clause" ]
175
2015-01-06T07:16:47.000Z
2022-03-29T13:27:01.000Z
REDIS_USED_PASSWORDS_LIST_PREFIX = 'used_passwords_' RESTRICT_USED_PASSWORDS_NUM = 3 # passwords inclusive of current password EXPIRE_PASSWORD_ATTEMPTS_IN = 10 # days
42.25
74
0.846154
23
169
5.695652
0.73913
0.29771
0
0
0
0
0
0
0
0
0
0.02
0.112426
169
3
75
56.333333
0.853333
0.260355
0
0
0
0
0.122951
0
0
0
0
0
0
1
0
false
1
0
0
0
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
8c38488e4a66ee96d82672fcc7c069d1f2c21308
36
py
Python
testsuite/modulegraph-dir/circular_from_c.py
xoviat/modulegraph2
766d00bdb40e5b2fe206b53a87b1bce3f9dc9c2a
[ "MIT" ]
9
2020-03-22T14:48:01.000Z
2021-05-30T12:18:12.000Z
testsuite/modulegraph-dir/circular_from_c.py
xoviat/modulegraph2
766d00bdb40e5b2fe206b53a87b1bce3f9dc9c2a
[ "MIT" ]
15
2020-01-06T10:02:32.000Z
2021-05-28T12:22:44.000Z
testsuite/modulegraph-dir/circular_from_c.py
ronaldoussoren/modulegraph2
b6ab1766b0098651b51083235ff8a18a5639128b
[ "MIT" ]
4
2020-05-10T18:51:41.000Z
2021-04-07T14:03:12.000Z
a = 1 from circular_from_a import a
12
29
0.777778
8
36
3.25
0.625
0
0
0
0
0
0
0
0
0
0
0.034483
0.194444
36
2
30
18
0.862069
0
0
0
0
0
0
0
0
0
0
0
0
1
0
false
0
0.5
0
0.5
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
0
0
0
4
8c5d9b72bf06170295fd8f401a12a4dc8871d536
28,369
py
Python
omega_miya/utils/Omega_Base/model/user.py
58563528/omega-miya
9dc822e8f768ac58dccfe7e3e03a29a2cf8766db
[ "MIT" ]
null
null
null
omega_miya/utils/Omega_Base/model/user.py
58563528/omega-miya
9dc822e8f768ac58dccfe7e3e03a29a2cf8766db
[ "MIT" ]
null
null
null
omega_miya/utils/Omega_Base/model/user.py
58563528/omega-miya
9dc822e8f768ac58dccfe7e3e03a29a2cf8766db
[ "MIT" ]
null
null
null
from typing import List, Optional from datetime import date, datetime from dataclasses import dataclass from omega_miya.utils.Omega_Base.database import NBdb from omega_miya.utils.Omega_Base.class_result import Result from omega_miya.utils.Omega_Base.tables import User, UserFavorability, UserSignIn, Skill, UserSkill, Vacation from .skill import DBSkill from sqlalchemy.future import select from sqlalchemy.orm.exc import NoResultFound, MultipleResultsFound class DBUser(object): def __init__(self, user_id: int): self.qq = user_id @dataclass class DateListResult(Result.AnyResult): result: List[date] def __repr__(self): return f'<DateListResult(error={self.error}, info={self.info}, result={self.result})>' async def id(self) -> Result.IntResult: async_session = NBdb().get_async_session() async with async_session() as session: async with session.begin(): try: session_result = await session.execute( select(User.id).where(User.qq == self.qq) ) user_table_id = session_result.scalar_one() result = Result.IntResult(error=False, info='Success', result=user_table_id) except NoResultFound: result = Result.IntResult(error=True, info='NoResultFound', result=-1) except MultipleResultsFound: result = Result.IntResult(error=True, info='MultipleResultsFound', result=-1) except Exception as e: result = Result.IntResult(error=True, info=repr(e), result=-1) return result async def exist(self) -> bool: result = await self.id() return result.success() async def nickname(self) -> Result.TextResult: async_session = NBdb().get_async_session() async with async_session() as session: async with session.begin(): try: session_result = await session.execute( select(User.nickname).where(User.qq == self.qq) ) user_nickname = session_result.scalar_one() result = Result.TextResult(error=False, info='Success', result=user_nickname) except NoResultFound: result = Result.TextResult(error=True, info='NoResultFound', result='') except MultipleResultsFound: result = Result.TextResult(error=True, info='MultipleResultsFound', result='') except Exception as e: result = Result.TextResult(error=True, info=repr(e), result='') return result async def add(self, nickname: str, aliasname: str = None) -> Result.IntResult: async_session = NBdb().get_async_session() async with async_session() as session: try: async with session.begin(): try: # 用户已存在则更新成员表昵称 session_result = await session.execute( select(User).where(User.qq == self.qq) ) exist_user = session_result.scalar_one() if exist_user.nickname == nickname: result = Result.IntResult(error=False, info='Nickname not change', result=0) else: exist_user.nickname = nickname exist_user.aliasname = aliasname exist_user.updated_at = datetime.now() result = Result.IntResult(error=False, info='Success upgraded', result=0) except NoResultFound: # 不存在则成员表中添加新成员 new_user = User(qq=self.qq, nickname=nickname, aliasname=aliasname, created_at=datetime.now()) session.add(new_user) result = Result.IntResult(error=False, info='Success added', result=0) await session.commit() except MultipleResultsFound: await session.rollback() result = Result.IntResult(error=True, info='MultipleResultsFound', result=-1) except Exception as e: await session.rollback() result = Result.IntResult(error=True, info=repr(e), result=-1) return result async def delete(self) -> Result.IntResult: id_result = await self.id() if id_result.error: return Result.IntResult(error=True, info='User not exist', result=-1) async_session = NBdb().get_async_session() async with async_session() as session: try: async with session.begin(): # 删除用户表中用户 session_result = await session.execute( select(User).where(User.qq == self.qq) ) exist_user = session_result.scalar_one() await session.delete(exist_user) await session.commit() result = Result.IntResult(error=False, info='Success Delete', result=0) except NoResultFound: await session.rollback() result = Result.IntResult(error=True, info='NoResultFound', result=-1) except MultipleResultsFound: await session.rollback() result = Result.IntResult(error=True, info='MultipleResultsFound', result=-1) except Exception as e: await session.rollback() result = Result.IntResult(error=True, info=repr(e), result=-1) return result async def skill_list(self) -> Result.ListResult: id_result = await self.id() if id_result.error: return Result.ListResult(error=True, info='User not exist', result=[]) async_session = NBdb().get_async_session() async with async_session() as session: async with session.begin(): try: session_result = await session.execute( select(Skill.name, UserSkill.skill_level). join(UserSkill). where(Skill.id == UserSkill.skill_id). where(UserSkill.user_id == id_result.result) ) res = [(x[0], x[1]) for x in session_result.all()] result = Result.ListResult(error=False, info='Success', result=res) except Exception as e: result = Result.ListResult(error=True, info=repr(e), result=[]) return result async def skill_add(self, skill: DBSkill, skill_level: int) -> Result.IntResult: user_id_result = await self.id() if user_id_result.error: return Result.IntResult(error=True, info='User not exist', result=-1) skill_id_result = await skill.id() if skill_id_result.error: return Result.IntResult(error=True, info='Skill not exist', result=-1) async_session = NBdb().get_async_session() async with async_session() as session: try: async with session.begin(): # 查询用户已有技能 try: # 已有技能, 更新等级 session_result = await session.execute( select(UserSkill). where(UserSkill.skill_id == skill_id_result.result). where(UserSkill.user_id == user_id_result.result) ) exist_skill = session_result.scalar_one() exist_skill.skill_level = skill_level exist_skill.updated_at = datetime.now() result = Result.IntResult(error=False, info='Success upgraded', result=0) except NoResultFound: new_skill = UserSkill(user_id=user_id_result.result, skill_id=skill_id_result.result, skill_level=skill_level, created_at=datetime.now()) session.add(new_skill) result = Result.IntResult(error=False, info='Success added', result=0) await session.commit() except MultipleResultsFound: await session.rollback() result = Result.IntResult(error=True, info='MultipleResultsFound', result=-1) except Exception as e: await session.rollback() result = Result.IntResult(error=True, info=repr(e), result=-1) return result async def skill_del(self, skill: DBSkill) -> Result.IntResult: user_id_result = await self.id() if user_id_result.error: return Result.IntResult(error=True, info='User not exist', result=-1) skill_id_result = await skill.id() if skill_id_result.error: return Result.IntResult(error=True, info='Skill not exist', result=-1) async_session = NBdb().get_async_session() async with async_session() as session: try: async with session.begin(): session_result = await session.execute( select(UserSkill). where(UserSkill.skill_id == skill_id_result.result). where(UserSkill.user_id == user_id_result.result) ) exist_skill = session_result.scalar_one() await session.delete(exist_skill) await session.commit() result = Result.IntResult(error=False, info='Success', result=0) except NoResultFound: await session.rollback() result = Result.IntResult(error=True, info='NoResultFound', result=-1) except MultipleResultsFound: await session.rollback() result = Result.IntResult(error=True, info='MultipleResultsFound', result=-1) except Exception as e: await session.rollback() result = Result.IntResult(error=True, info=repr(e), result=-1) return result async def skill_clear(self) -> Result.IntResult: user_id_result = await self.id() if user_id_result.error: return Result.IntResult(error=True, info='User not exist', result=-1) async_session = NBdb().get_async_session() async with async_session() as session: try: async with session.begin(): session_result = await session.execute( select(UserSkill).where(UserSkill.user_id == user_id_result.result) ) for exist_skill in session_result.scalars().all(): await session.delete(exist_skill) await session.commit() result = Result.IntResult(error=False, info='Success', result=0) except Exception as e: await session.rollback() result = Result.IntResult(error=True, info=repr(e), result=-1) return result async def status(self) -> Result.IntResult: user_id_result = await self.id() if user_id_result.error: return Result.IntResult(error=True, info='User not exist', result=-1) async_session = NBdb().get_async_session() async with async_session() as session: async with session.begin(): try: session_result = await session.execute( select(Vacation.status).where(Vacation.user_id == user_id_result.result) ) res = session_result.scalar_one() result = Result.IntResult(error=False, info='Success', result=res) except Exception as e: result = Result.IntResult(error=True, info=repr(e), result=-1) return result async def vacation_status(self) -> Result.ListResult: user_id_result = await self.id() if user_id_result.error: return Result.ListResult(error=True, info='User not exist', result=[-1, None]) async_session = NBdb().get_async_session() async with async_session() as session: async with session.begin(): try: session_result = await session.execute( select(Vacation.status, Vacation.stop_at). where(Vacation.user_id == user_id_result.result) ) res = session_result.one() result = Result.ListResult(error=False, info='Success', result=[res[0], res[1]]) except Exception as e: result = Result.ListResult(error=True, info=repr(e), result=[-1, None]) return result async def status_set(self, status: int) -> Result.IntResult: user_id_result = await self.id() if user_id_result.error: return Result.IntResult(error=True, info='User not exist', result=-1) async_session = NBdb().get_async_session() async with async_session() as session: try: async with session.begin(): try: session_result = await session.execute( select(Vacation).where(Vacation.user_id == user_id_result.result) ) exist_status = session_result.scalar_one() exist_status.status = status exist_status.stop_at = None exist_status.reason = None exist_status.updated_at = datetime.now() result = Result.IntResult(error=False, info='Success upgraded', result=0) except NoResultFound: new_status = Vacation(user_id=user_id_result.result, status=status, created_at=datetime.now()) session.add(new_status) result = Result.IntResult(error=False, info='Success set', result=0) await session.commit() except MultipleResultsFound: await session.rollback() result = Result.IntResult(error=True, info='MultipleResultsFound', result=-1) except Exception as e: await session.rollback() result = Result.IntResult(error=True, info=repr(e), result=-1) return result async def vacation_set(self, stop_time: datetime, reason: str = None) -> Result.IntResult: user_id_result = await self.id() if user_id_result.error: return Result.IntResult(error=True, info='User not exist', result=-1) async_session = NBdb().get_async_session() async with async_session() as session: try: async with session.begin(): try: session_result = await session.execute( select(Vacation).where(Vacation.user_id == user_id_result.result) ) exist_status = session_result.scalar_one() exist_status.status = 1 exist_status.stop_at = stop_time exist_status.reason = reason exist_status.updated_at = datetime.now() result = Result.IntResult(error=False, info='Success upgraded', result=0) except NoResultFound: new_status = Vacation(user_id=user_id_result.result, status=1, stop_at=stop_time, reason=reason, created_at=datetime.now()) session.add(new_status) result = Result.IntResult(error=False, info='Success set', result=0) await session.commit() except MultipleResultsFound: await session.rollback() result = Result.IntResult(error=True, info='MultipleResultsFound', result=-1) except Exception as e: await session.rollback() result = Result.IntResult(error=True, info=repr(e), result=-1) return result async def status_del(self) -> Result.IntResult: user_id_result = await self.id() if user_id_result.error: return Result.IntResult(error=True, info='User not exist', result=-1) async_session = NBdb().get_async_session() async with async_session() as session: try: async with session.begin(): session_result = await session.execute( select(Vacation).where(Vacation.user_id == user_id_result.result) ) exist_status = session_result.scalar_one() await session.delete(exist_status) await session.commit() result = Result.IntResult(error=False, info='Success', result=0) except Exception as e: await session.rollback() result = Result.IntResult(error=True, info=repr(e), result=-1) return result async def sign_in(self, *, sign_in_info: Optional[str] = 'Normal sign in') -> Result.IntResult: """ 签到 :param sign_in_info: 签到信息 :return: IntResult 1: 已签到 0: 签到成功 -1: 错误 """ user_id_result = await self.id() if user_id_result.error: return Result.IntResult(error=True, info='User not exist', result=-1) datetime_now = datetime.now() date_now = datetime_now.date() async_session = NBdb().get_async_session() async with async_session() as session: try: async with session.begin(): try: session_result = await session.execute( select(UserSignIn). where(UserSignIn.user_id == user_id_result.result). where(UserSignIn.sign_in_date == date_now) ) # 已有签到记录 exist_sign_in = session_result.scalar_one() exist_sign_in.sign_in_info = 'Duplicate sign in' exist_sign_in.updated_at = datetime.now() result = Result.IntResult(error=False, info='Success upgraded', result=1) except NoResultFound: sign_in = UserSignIn(user_id=user_id_result.result, sign_in_date=date_now, sign_in_info=sign_in_info, created_at=datetime.now()) session.add(sign_in) result = Result.IntResult(error=False, info='Success added', result=0) await session.commit() except MultipleResultsFound: await session.rollback() result = Result.IntResult(error=True, info='MultipleResultsFound', result=-1) except Exception as e: await session.rollback() result = Result.IntResult(error=True, info=repr(e), result=-1) return result async def sign_in_statistics(self) -> DateListResult: """ 查询所有签到记录 :return: Result: List[sign_in_date] """ user_id_result = await self.id() if user_id_result.error: return self.DateListResult(error=True, info='User not exist', result=[]) async_session = NBdb().get_async_session() async with async_session() as session: async with session.begin(): try: session_result = await session.execute( select(UserSignIn.sign_in_date). where(UserSignIn.user_id == user_id_result.result) ) res = [x for x in session_result.scalars().all()] result = self.DateListResult(error=False, info='Success', result=res) except Exception as e: result = self.DateListResult(error=True, info=repr(e), result=[]) return result async def sign_in_continuous_days(self) -> Result.IntResult: """ 查询到目前为止最长连续签到日数 """ sign_in_statistics_result = await self.sign_in_statistics() if sign_in_statistics_result.error: return Result.IntResult(error=True, info=sign_in_statistics_result.info, result=-1) # 还没有签到过 if not sign_in_statistics_result.result: return Result.IntResult(error=False, info='Success with sign in not found', result=0) datetime_now = datetime.now() date_now = datetime_now.date() date_now_toordinal = date_now.toordinal() # 先将签到记录中的日期转化为整数便于比较 all_sign_in_list = list(set([x.toordinal() for x in sign_in_statistics_result.result])) # 去重后由大到小排序 all_sign_in_list.sort(reverse=True) # 如果今日日期不等于已签到日期最大值, 说明今日没有签到, 则连签日数为0 if date_now_toordinal != all_sign_in_list[0]: return Result.IntResult(error=False, info='Success with not sign in today', result=0) # 从大到小检查(即日期从后向前检查), 如果当日序号大小大于与今日日期之差, 说明在这里断签了 for index, value in enumerate(all_sign_in_list): if index != date_now_toordinal - value: return Result.IntResult(error=False, info='Success with found interrupt', result=index) else: # 如果全部遍历完了那就说明全部没有断签 return Result.IntResult(error=False, info='Success with all continuous', result=len(all_sign_in_list)) async def favorability_status(self) -> Result.TupleResult: """ 查询好感度记录 :return: Result: Tuple[status: str, mood: float, favorability: float, energy: float, currency: float, response_threshold: float] """ user_id_result = await self.id() if user_id_result.error: return Result.TupleResult(error=True, info='User not exist', result=()) async_session = NBdb().get_async_session() async with async_session() as session: async with session.begin(): try: session_result = await session.execute( select(UserFavorability.status, UserFavorability.mood, UserFavorability.favorability, UserFavorability.energy, UserFavorability.currency, UserFavorability.response_threshold). where(UserFavorability.user_id == user_id_result.result) ) res = session_result.one() result = Result.TupleResult(error=False, info='Success', result=res) except NoResultFound: result = Result.TupleResult(error=True, info='NoResultFound', result=()) except MultipleResultsFound: result = Result.TupleResult(error=True, info='MultipleResultsFound', result=()) except Exception as e: result = Result.TupleResult(error=True, info=repr(e), result=()) return result async def favorability_reset( self, *, status: str = 'normal', mood: float = 0, favorability: float = 0, energy: float = 0, currency: float = 0, response_threshold: float = 0 ) -> Result.IntResult: user_id_result = await self.id() if user_id_result.error: return Result.IntResult(error=True, info='User not exist', result=-1) async_session = NBdb().get_async_session() async with async_session() as session: try: async with session.begin(): try: session_result = await session.execute( select(UserFavorability). where(UserFavorability.user_id == user_id_result.result) ) # 已有好感度记录条目 exist_favorability = session_result.scalar_one() exist_favorability.status = status exist_favorability.mood = mood exist_favorability.favorability = favorability exist_favorability.energy = energy exist_favorability.currency = currency exist_favorability.response_threshold = response_threshold exist_favorability.updated_at = datetime.now() result = Result.IntResult(error=False, info='Success upgraded', result=0) except NoResultFound: favorability = UserFavorability( user_id=user_id_result.result, status=status, mood=mood, favorability=favorability, energy=energy, currency=currency, response_threshold=response_threshold, created_at=datetime.now()) session.add(favorability) result = Result.IntResult(error=False, info='Success added', result=0) await session.commit() except MultipleResultsFound: await session.rollback() result = Result.IntResult(error=True, info='MultipleResultsFound', result=-1) except Exception as e: await session.rollback() result = Result.IntResult(error=True, info=repr(e), result=-1) return result async def favorability_add( self, *, status: Optional[str] = None, mood: Optional[float] = None, favorability: Optional[float] = None, energy: Optional[float] = None, currency: Optional[float] = None, response_threshold: Optional[float] = None ) -> Result.IntResult: user_id_result = await self.id() if user_id_result.error: return Result.IntResult(error=True, info='User not exist', result=-1) async_session = NBdb().get_async_session() async with async_session() as session: try: async with session.begin(): session_result = await session.execute( select(UserFavorability). where(UserFavorability.user_id == user_id_result.result) ) # 已有好感度记录条目 exist_favorability = session_result.scalar_one() if status: exist_favorability.status = status if mood: exist_favorability.mood += mood if favorability: exist_favorability.favorability += favorability if energy: exist_favorability.energy += energy if currency: exist_favorability.currency += currency if response_threshold: exist_favorability.response_threshold += response_threshold exist_favorability.updated_at = datetime.now() result = Result.IntResult(error=False, info='Success upgraded', result=0) await session.commit() except NoResultFound: await session.rollback() result = Result.IntResult(error=True, info='NoResultFound', result=-1) except MultipleResultsFound: await session.rollback() result = Result.IntResult(error=True, info='MultipleResultsFound', result=-1) except Exception as e: await session.rollback() result = Result.IntResult(error=True, info=repr(e), result=-1) return result
47.920608
119
0.553809
2,814
28,369
5.422886
0.057569
0.065269
0.08519
0.080079
0.777326
0.756029
0.728244
0.715793
0.686894
0.66789
0
0.004346
0.35923
28,369
591
120
48.001692
0.83513
0.007861
0
0.643137
0
0.001961
0.038816
0.002058
0
0
0
0
0
1
0.003922
false
0
0.017647
0.001961
0.107843
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
4fd52c874a0800f1732a327c2df4275120e6cb4e
25
py
Python
homeassistant/components/nad/__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/nad/__init__.py
jagadeeshvenkatesh/core
1bd982668449815fee2105478569f8e4b5670add
[ "Apache-2.0" ]
31,101
2020-03-02T13:00:16.000Z
2022-03-31T23:57:36.000Z
homeassistant/components/nad/__init__.py
jagadeeshvenkatesh/core
1bd982668449815fee2105478569f8e4b5670add
[ "Apache-2.0" ]
11,956
2016-04-13T18:42:31.000Z
2020-03-02T09:32:12.000Z
"""The nad component."""
12.5
24
0.6
3
25
5
1
0
0
0
0
0
0
0
0
0
0
0
0.12
25
1
25
25
0.681818
0.72
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
4ff14795db3e8f522c97d09e3b423cf4eeb50abe
13,908
py
Python
protos/convnet_pb2.py
ChenCongGit/Chinese-aster
3e4ad7e1cc36ad071e4e5dd1017d7d415d686d8d
[ "MIT" ]
6
2019-08-05T08:54:46.000Z
2021-06-29T08:36:58.000Z
protos/convnet_pb2.py
ChenCongGit/Chinese-aster
3e4ad7e1cc36ad071e4e5dd1017d7d415d686d8d
[ "MIT" ]
null
null
null
protos/convnet_pb2.py
ChenCongGit/Chinese-aster
3e4ad7e1cc36ad071e4e5dd1017d7d415d686d8d
[ "MIT" ]
null
null
null
# Generated by the protocol buffer compiler. DO NOT EDIT! # source: Chinese_aster/protos/convnet.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection from google.protobuf import symbol_database as _symbol_database from google.protobuf import descriptor_pb2 # @@protoc_insertion_point(imports) _sym_db = _symbol_database.Default() import Chinese_aster.protos.hyperparams_pb2 DESCRIPTOR = _descriptor.FileDescriptor( name='Chinese_aster/protos/convnet.proto', package='Chinese_aster.protos', serialized_pb=_b('\n\"Chinese_aster/protos/convnet.proto\x12\x14\x43hinese_aster.protos\x1a&Chinese_aster/protos/hyperparams.proto\"\xb6\x01\n\x07\x43onvnet\x12\x31\n\x08\x63rnn_net\x18\x01 \x01(\x0b\x32\x1d.Chinese_aster.protos.CrnnNetH\x00\x12.\n\x06resnet\x18\x02 \x01(\x0b\x32\x1c.Chinese_aster.protos.ResNetH\x00\x12\x37\n\x0bstn_convnet\x18\x03 \x01(\x0b\x32 .Chinese_aster.protos.StnConvnetH\x00\x42\x0f\n\rconvnet_oneof\"\x8d\x02\n\x07\x43rnnNet\x12\x46\n\x08net_type\x18\x01 \x01(\x0e\x32%.Chinese_aster.protos.CrnnNet.NetType:\rSINGLE_BRANCH\x12;\n\x10\x63onv_hyperparams\x18\x02 \x01(\x0b\x32!.Chinese_aster.protos.Hyperparams\x12$\n\x15summarize_activations\x18\x03 \x01(\x08:\x05\x66\x61lse\x12\x13\n\x04tiny\x18\x04 \x01(\x08:\x05\x66\x61lse\"B\n\x07NetType\x12\x11\n\rSINGLE_BRANCH\x10\x00\x12\x10\n\x0cTWO_BRANCHES\x10\x01\x12\x12\n\x0eTHREE_BRANCHES\x10\x02\"\xf5\x02\n\x06ResNet\x12\x45\n\x08net_type\x18\x01 \x01(\x0e\x32$.Chinese_aster.protos.ResNet.NetType:\rSINGLE_BRANCH\x12\x43\n\tnet_depth\x18\x02 \x01(\x0e\x32%.Chinese_aster.protos.ResNet.NetDepth:\tRESNET_50\x12;\n\x10\x63onv_hyperparams\x18\x03 \x01(\x0b\x32!.Chinese_aster.protos.Hyperparams\x12$\n\x15summarize_activations\x18\x04 \x01(\x08:\x05\x66\x61lse\"B\n\x07NetType\x12\x11\n\rSINGLE_BRANCH\x10\x00\x12\x10\n\x0cTWO_BRANCHES\x10\x01\x12\x12\n\x0eTHREE_BRANCHES\x10\x02\"8\n\x08NetDepth\x12\r\n\tRESNET_30\x10\x00\x12\r\n\tRESNET_50\x10\x01\x12\x0e\n\nRESNET_100\x10\x02\"\x84\x01\n\nStnConvnet\x12;\n\x10\x63onv_hyperparams\x18\x01 \x01(\x0b\x32!.Chinese_aster.protos.Hyperparams\x12$\n\x15summarize_activations\x18\x02 \x01(\x08:\x05\x66\x61lse\x12\x13\n\x04tiny\x18\x03 \x01(\x08:\x05\x66\x61lse') , dependencies=[Chinese_aster.protos.hyperparams_pb2.DESCRIPTOR,]) _sym_db.RegisterFileDescriptor(DESCRIPTOR) _CRNNNET_NETTYPE = _descriptor.EnumDescriptor( name='NetType', full_name='Chinese_aster.protos.CrnnNet.NetType', filename=None, file=DESCRIPTOR, values=[ _descriptor.EnumValueDescriptor( name='SINGLE_BRANCH', index=0, number=0, options=None, type=None), _descriptor.EnumValueDescriptor( name='TWO_BRANCHES', index=1, number=1, options=None, type=None), _descriptor.EnumValueDescriptor( name='THREE_BRANCHES', index=2, number=2, options=None, type=None), ], containing_type=None, options=None, serialized_start=489, serialized_end=555, ) _sym_db.RegisterEnumDescriptor(_CRNNNET_NETTYPE) _RESNET_NETTYPE = _descriptor.EnumDescriptor( name='NetType', full_name='Chinese_aster.protos.ResNet.NetType', filename=None, file=DESCRIPTOR, values=[ _descriptor.EnumValueDescriptor( name='SINGLE_BRANCH', index=0, number=0, options=None, type=None), _descriptor.EnumValueDescriptor( name='TWO_BRANCHES', index=1, number=1, options=None, type=None), _descriptor.EnumValueDescriptor( name='THREE_BRANCHES', index=2, number=2, options=None, type=None), ], containing_type=None, options=None, serialized_start=489, serialized_end=555, ) _sym_db.RegisterEnumDescriptor(_RESNET_NETTYPE) _RESNET_NETDEPTH = _descriptor.EnumDescriptor( name='NetDepth', full_name='Chinese_aster.protos.ResNet.NetDepth', filename=None, file=DESCRIPTOR, values=[ _descriptor.EnumValueDescriptor( name='RESNET_30', index=0, number=0, options=None, type=None), _descriptor.EnumValueDescriptor( name='RESNET_50', index=1, number=1, options=None, type=None), _descriptor.EnumValueDescriptor( name='RESNET_100', index=2, number=2, options=None, type=None), ], containing_type=None, options=None, serialized_start=875, serialized_end=931, ) _sym_db.RegisterEnumDescriptor(_RESNET_NETDEPTH) _CONVNET = _descriptor.Descriptor( name='Convnet', full_name='Chinese_aster.protos.Convnet', filename=None, file=DESCRIPTOR, containing_type=None, fields=[ _descriptor.FieldDescriptor( name='crnn_net', full_name='Chinese_aster.protos.Convnet.crnn_net', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, options=None), _descriptor.FieldDescriptor( name='resnet', full_name='Chinese_aster.protos.Convnet.resnet', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, options=None), _descriptor.FieldDescriptor( name='stn_convnet', full_name='Chinese_aster.protos.Convnet.stn_convnet', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, options=None), ], extensions=[ ], nested_types=[], enum_types=[ ], options=None, is_extendable=False, extension_ranges=[], oneofs=[ _descriptor.OneofDescriptor( name='convnet_oneof', full_name='Chinese_aster.protos.Convnet.convnet_oneof', index=0, containing_type=None, fields=[]), ], serialized_start=101, serialized_end=283, ) _CRNNNET = _descriptor.Descriptor( name='CrnnNet', full_name='Chinese_aster.protos.CrnnNet', filename=None, file=DESCRIPTOR, containing_type=None, fields=[ _descriptor.FieldDescriptor( name='net_type', full_name='Chinese_aster.protos.CrnnNet.net_type', index=0, number=1, type=14, cpp_type=8, label=1, has_default_value=True, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, options=None), _descriptor.FieldDescriptor( name='conv_hyperparams', full_name='Chinese_aster.protos.CrnnNet.conv_hyperparams', index=1, number=2, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, options=None), _descriptor.FieldDescriptor( name='summarize_activations', full_name='Chinese_aster.protos.CrnnNet.summarize_activations', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=True, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, options=None), _descriptor.FieldDescriptor( name='tiny', full_name='Chinese_aster.protos.CrnnNet.tiny', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=True, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, options=None), ], extensions=[ ], nested_types=[], enum_types=[ _CRNNNET_NETTYPE, ], options=None, is_extendable=False, extension_ranges=[], oneofs=[ ], serialized_start=286, serialized_end=555, ) _RESNET = _descriptor.Descriptor( name='ResNet', full_name='Chinese_aster.protos.ResNet', filename=None, file=DESCRIPTOR, containing_type=None, fields=[ _descriptor.FieldDescriptor( name='net_type', full_name='Chinese_aster.protos.ResNet.net_type', index=0, number=1, type=14, cpp_type=8, label=1, has_default_value=True, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, options=None), _descriptor.FieldDescriptor( name='net_depth', full_name='Chinese_aster.protos.ResNet.net_depth', index=1, number=2, type=14, cpp_type=8, label=1, has_default_value=True, default_value=1, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, options=None), _descriptor.FieldDescriptor( name='conv_hyperparams', full_name='Chinese_aster.protos.ResNet.conv_hyperparams', index=2, number=3, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, options=None), _descriptor.FieldDescriptor( name='summarize_activations', full_name='Chinese_aster.protos.ResNet.summarize_activations', index=3, number=4, type=8, cpp_type=7, label=1, has_default_value=True, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, options=None), ], extensions=[ ], nested_types=[], enum_types=[ _RESNET_NETTYPE, _RESNET_NETDEPTH, ], options=None, is_extendable=False, extension_ranges=[], oneofs=[ ], serialized_start=558, serialized_end=931, ) _STNCONVNET = _descriptor.Descriptor( name='StnConvnet', full_name='Chinese_aster.protos.StnConvnet', filename=None, file=DESCRIPTOR, containing_type=None, fields=[ _descriptor.FieldDescriptor( name='conv_hyperparams', full_name='Chinese_aster.protos.StnConvnet.conv_hyperparams', index=0, number=1, type=11, cpp_type=10, label=1, has_default_value=False, default_value=None, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, options=None), _descriptor.FieldDescriptor( name='summarize_activations', full_name='Chinese_aster.protos.StnConvnet.summarize_activations', index=1, number=2, type=8, cpp_type=7, label=1, has_default_value=True, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, options=None), _descriptor.FieldDescriptor( name='tiny', full_name='Chinese_aster.protos.StnConvnet.tiny', index=2, number=3, type=8, cpp_type=7, label=1, has_default_value=True, default_value=False, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, options=None), ], extensions=[ ], nested_types=[], enum_types=[ ], options=None, is_extendable=False, extension_ranges=[], oneofs=[ ], serialized_start=934, serialized_end=1066, ) _CONVNET.fields_by_name['crnn_net'].message_type = _CRNNNET _CONVNET.fields_by_name['resnet'].message_type = _RESNET _CONVNET.fields_by_name['stn_convnet'].message_type = _STNCONVNET _CONVNET.oneofs_by_name['convnet_oneof'].fields.append( _CONVNET.fields_by_name['crnn_net']) _CONVNET.fields_by_name['crnn_net'].containing_oneof = _CONVNET.oneofs_by_name['convnet_oneof'] _CONVNET.oneofs_by_name['convnet_oneof'].fields.append( _CONVNET.fields_by_name['resnet']) _CONVNET.fields_by_name['resnet'].containing_oneof = _CONVNET.oneofs_by_name['convnet_oneof'] _CONVNET.oneofs_by_name['convnet_oneof'].fields.append( _CONVNET.fields_by_name['stn_convnet']) _CONVNET.fields_by_name['stn_convnet'].containing_oneof = _CONVNET.oneofs_by_name['convnet_oneof'] _CRNNNET.fields_by_name['net_type'].enum_type = _CRNNNET_NETTYPE _CRNNNET.fields_by_name['conv_hyperparams'].message_type = Chinese_aster.protos.hyperparams_pb2._HYPERPARAMS _CRNNNET_NETTYPE.containing_type = _CRNNNET _RESNET.fields_by_name['net_type'].enum_type = _RESNET_NETTYPE _RESNET.fields_by_name['net_depth'].enum_type = _RESNET_NETDEPTH _RESNET.fields_by_name['conv_hyperparams'].message_type = Chinese_aster.protos.hyperparams_pb2._HYPERPARAMS _RESNET_NETTYPE.containing_type = _RESNET _RESNET_NETDEPTH.containing_type = _RESNET _STNCONVNET.fields_by_name['conv_hyperparams'].message_type = Chinese_aster.protos.hyperparams_pb2._HYPERPARAMS DESCRIPTOR.message_types_by_name['Convnet'] = _CONVNET DESCRIPTOR.message_types_by_name['CrnnNet'] = _CRNNNET DESCRIPTOR.message_types_by_name['ResNet'] = _RESNET DESCRIPTOR.message_types_by_name['StnConvnet'] = _STNCONVNET Convnet = _reflection.GeneratedProtocolMessageType('Convnet', (_message.Message,), dict( DESCRIPTOR = _CONVNET, __module__ = 'Chinese_aster.protos.convnet_pb2' # @@protoc_insertion_point(class_scope:Chinese_aster.protos.Convnet) )) _sym_db.RegisterMessage(Convnet) CrnnNet = _reflection.GeneratedProtocolMessageType('CrnnNet', (_message.Message,), dict( DESCRIPTOR = _CRNNNET, __module__ = 'Chinese_aster.protos.convnet_pb2' # @@protoc_insertion_point(class_scope:Chinese_aster.protos.CrnnNet) )) _sym_db.RegisterMessage(CrnnNet) ResNet = _reflection.GeneratedProtocolMessageType('ResNet', (_message.Message,), dict( DESCRIPTOR = _RESNET, __module__ = 'Chinese_aster.protos.convnet_pb2' # @@protoc_insertion_point(class_scope:Chinese_aster.protos.ResNet) )) _sym_db.RegisterMessage(ResNet) StnConvnet = _reflection.GeneratedProtocolMessageType('StnConvnet', (_message.Message,), dict( DESCRIPTOR = _STNCONVNET, __module__ = 'Chinese_aster.protos.convnet_pb2' # @@protoc_insertion_point(class_scope:Chinese_aster.protos.StnConvnet) )) _sym_db.RegisterMessage(StnConvnet) # @@protoc_insertion_point(module_scope)
38.740947
1,690
0.75302
1,819
13,908
5.446949
0.105003
0.047638
0.089019
0.05107
0.761102
0.714473
0.658761
0.627876
0.611526
0.611526
0
0.042933
0.122448
13,908
358
1,691
38.849162
0.768865
0.03178
0
0.654321
1
0.003086
0.247083
0.201234
0
0
0
0
0
1
0
false
0
0.021605
0
0.021605
0
0
0
0
null
0
0
0
0
1
0
0
0
1
0
0
0
0
0
1
0
0
0
0
0
1
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
8b1b3b0ef896044bd57762bbe98148d97a3d06ae
35
py
Python
user_login.py
sebka1012/football
d63f001f53efec1e8b01751b89e69bd0287c2a8f
[ "Apache-2.0" ]
null
null
null
user_login.py
sebka1012/football
d63f001f53efec1e8b01751b89e69bd0287c2a8f
[ "Apache-2.0" ]
null
null
null
user_login.py
sebka1012/football
d63f001f53efec1e8b01751b89e69bd0287c2a8f
[ "Apache-2.0" ]
null
null
null
Mein neuer Code XY Neue Zeile Code
11.666667
18
0.8
7
35
4
0.857143
0
0
0
0
0
0
0
0
0
0
0
0.2
35
2
19
17.5
1
0
0
0
0
0
0
0
0
0
0
0
0
0
null
null
0
0
null
null
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
1
0
0
0
0
0
0
0
0
4
8b381ea288e269037d54cdb3eb87890931bb904e
98
py
Python
DForurm/app/admin.py
hydrospanner/DForurm
b8e9f4b37db8e2b02462976a11e9cd3fe76984d7
[ "MIT" ]
null
null
null
DForurm/app/admin.py
hydrospanner/DForurm
b8e9f4b37db8e2b02462976a11e9cd3fe76984d7
[ "MIT" ]
null
null
null
DForurm/app/admin.py
hydrospanner/DForurm
b8e9f4b37db8e2b02462976a11e9cd3fe76984d7
[ "MIT" ]
null
null
null
""" Customizations for the Django administration interface. """ from django.contrib import admin
16.333333
55
0.785714
11
98
7
0.909091
0
0
0
0
0
0
0
0
0
0
0
0.132653
98
5
56
19.6
0.905882
0.561224
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
8b4a211306105ebf381e8a71c01d00963459ad2a
217
py
Python
tests/django/test_graphql_test_client.py
TheVinhLuong102/Strawberry
3c442dc19d17bc55c4e26de1db7a9eedc0a228f5
[ "MIT" ]
null
null
null
tests/django/test_graphql_test_client.py
TheVinhLuong102/Strawberry
3c442dc19d17bc55c4e26de1db7a9eedc0a228f5
[ "MIT" ]
128
2021-05-02T20:38:20.000Z
2022-03-29T23:31:37.000Z
tests/django/test_graphql_test_client.py
TheVinhLuong102/Strawberry
3c442dc19d17bc55c4e26de1db7a9eedc0a228f5
[ "MIT" ]
1
2021-12-13T10:59:05.000Z
2021-12-13T10:59:05.000Z
def test_assertion_error_not_raised_when_asserts_errors_is_false(graphql_client): query = "{ }" try: graphql_client.query(query, asserts_errors=False) except AssertionError: assert False
27.125
81
0.732719
26
217
5.653846
0.692308
0.176871
0.244898
0
0
0
0
0
0
0
0
0
0.198157
217
7
82
31
0.844828
0
0
0
0
0
0.018433
0
0
0
0
0
0.666667
1
0.166667
false
0
0
0
0.166667
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
1
0
0
0
0
0
0
0
0
0
4
8c7f2d2b87e7a921e60e95ccaa75f6ba05a8f8c8
245
py
Python
backend/depot/views/commodity_view.py
mrader1248/depocalypse
0662e7a096fdb68b6e5cc55be4e17c7fb1ed8241
[ "MIT" ]
null
null
null
backend/depot/views/commodity_view.py
mrader1248/depocalypse
0662e7a096fdb68b6e5cc55be4e17c7fb1ed8241
[ "MIT" ]
9
2021-11-30T17:31:57.000Z
2022-01-03T18:47:09.000Z
backend/depot/views/commodity_view.py
mrader1248/depocalypse
0662e7a096fdb68b6e5cc55be4e17c7fb1ed8241
[ "MIT" ]
null
null
null
from rest_framework import viewsets from ..models import Commodity from ..serializers import CommoditySerializer class CommodityViewSet(viewsets.ModelViewSet): queryset = Commodity.objects.all() serializer_class = CommoditySerializer
24.5
46
0.816327
24
245
8.25
0.666667
0
0
0
0
0
0
0
0
0
0
0
0.126531
245
9
47
27.222222
0.925234
0
0
0
0
0
0
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
8c8834d2ffd2685b156cb584f6e52b31935c5a51
153
py
Python
Python/Strings/What's Your Name.py
abhi-kuks/HackerRank
f40d805b639f0371b118f067cbd81ca74a369757
[ "MIT" ]
null
null
null
Python/Strings/What's Your Name.py
abhi-kuks/HackerRank
f40d805b639f0371b118f067cbd81ca74a369757
[ "MIT" ]
null
null
null
Python/Strings/What's Your Name.py
abhi-kuks/HackerRank
f40d805b639f0371b118f067cbd81ca74a369757
[ "MIT" ]
null
null
null
Question : https://www.hackerrank.com/challenges/whats-your-name/ def print_full_name(a, b): print(f"Hello {a} {b}! You just delved into python.")
25.5
65
0.705882
25
153
4.24
0.84
0.037736
0
0
0
0
0
0
0
0
0
0
0.130719
153
5
66
30.6
0.796992
0
0
0
0
0
0.282895
0
0
0
0
0
0
0
null
null
0
0
null
null
0.666667
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
8c9b74d3588c6e816a721eef96a1504826fed625
78
py
Python
setup.py
NafisHandoko/Nlang
020a1145777bde5385e0a089ce185091191ce4a5
[ "MIT" ]
1
2021-10-18T05:40:04.000Z
2021-10-18T05:40:04.000Z
setup.py
NafisHandoko/Nlang
020a1145777bde5385e0a089ce185091191ce4a5
[ "MIT" ]
null
null
null
setup.py
NafisHandoko/Nlang
020a1145777bde5385e0a089ce185091191ce4a5
[ "MIT" ]
null
null
null
from distutils.core import setup import py2exe setup(console=['nlang.py'])
19.5
33
0.75641
11
78
5.363636
0.818182
0
0
0
0
0
0
0
0
0
0
0.014706
0.128205
78
3
34
26
0.852941
0
0
0
0
0
0.106667
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
8ca8c461f530baf8952a366dad50e5d59bf2c342
221
py
Python
executor/meta/__init__.py
asyre/bachelor_degree
274415a32dc642ecde53935d6b9c8bb23d21cf29
[ "MIT" ]
null
null
null
executor/meta/__init__.py
asyre/bachelor_degree
274415a32dc642ecde53935d6b9c8bb23d21cf29
[ "MIT" ]
null
null
null
executor/meta/__init__.py
asyre/bachelor_degree
274415a32dc642ecde53935d6b9c8bb23d21cf29
[ "MIT" ]
null
null
null
from .connection import * from .description import * from .env import * from .env_var import * from .meta import * from .name import * from .node import * from .order import * from .scheduler import * from .skip import *
20.090909
26
0.728507
31
221
5.16129
0.387097
0.5625
0.1625
0
0
0
0
0
0
0
0
0
0.180995
221
10
27
22.1
0.883978
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
0
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
4
8ca9be3878dab670cb6a05d0d41ef9afb347f424
2,302
py
Python
pysaintcoinach/xiv/gc_scrip_shop_item.py
icykoneko/saintcoinach-py
66898385e1198203a7ec9da83787427bf6fe5c83
[ "MIT" ]
7
2019-11-20T17:24:49.000Z
2022-03-29T04:17:53.000Z
pysaintcoinach/xiv/gc_scrip_shop_item.py
icykoneko/saintcoinach-py
66898385e1198203a7ec9da83787427bf6fe5c83
[ "MIT" ]
7
2019-04-08T07:36:46.000Z
2022-01-17T22:51:54.000Z
pysaintcoinach/xiv/gc_scrip_shop_item.py
icykoneko/saintcoinach-py
66898385e1198203a7ec9da83787427bf6fe5c83
[ "MIT" ]
3
2019-04-08T08:24:22.000Z
2021-06-27T22:19:15.000Z
from ..ex.relational import IRelationalRow from . import xivrow, XivSubRow, IXivSheet from .interfaces import IShopListing, IShopListingItem from .shop_listing_item import ShopListingItem @xivrow class GCScripShopItem(XivSubRow, IShopListing, IShopListingItem): @property def gc_shop(self) -> 'GCShop': return self.__gc_shop @property def cost(self) -> ShopListingItem: return self.__cost @property def gc_scrip_shop_category(self) -> 'GCScripShopCategory': return self.__gc_scrip_shop_category @property def item(self) -> 'Item': from .item import Item return self.as_T(Item) @property def required_grand_company_rank(self) -> 'GrandCompanyRank': # TODO: Use `GrandCompanyRank` type. return self['Required{GrandCompanyRank}'] @property def gc_seals_cost(self) -> int: return self.as_int32('Cost{GCSeals}') @property def sort_key(self) -> int: return self.get_raw('SortKey') & 0xFF def __init__(self, sheet: IXivSheet, source_row: IRelationalRow): from .gc_shop import GCShop from .gc_scrip_shop_category import GCScripShopCategory super(GCScripShopItem, self).__init__(sheet, source_row) self.__gc_scrip_shop_category = self.sheet.collection.get_sheet(GCScripShopCategory)[self.parent_key] self.__gc_shop = next(filter(lambda _: _.grand_company.key == self.gc_scrip_shop_category.grand_company.key, self.sheet.collection.get_sheet(GCShop))) seal_item = self.gc_shop.grand_company.seal_item self.__cost = ShopListingItem(self, seal_item, self.gc_seals_cost, False, 0) def __str__(self): return str(self.item) @property def rewards(self) -> 'Iterable[IShopListingItem]': yield self @property def costs(self) -> 'Iterable[IShopListingItem]': yield self.cost @property def shops(self) -> 'Iterable[IShop]': yield self.gc_shop @property def is_hq(self) -> bool: return False @property def shop_item(self) -> 'IShopListing': return self @property def collectability_rating(self) -> int: return 0 @property def count(self) -> int: return 1
28.419753
116
0.668983
264
2,302
5.55303
0.280303
0.105048
0.037517
0.064802
0.178718
0
0
0
0
0
0
0.003411
0.235882
2,302
80
117
28.775
0.830017
0.01477
0
0.233333
0
0
0.075022
0.034422
0
0
0.001765
0.0125
0
1
0.266667
false
0
0.116667
0.183333
0.6
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
1
0
0
1
0
0
0
1
1
0
0
4
8cc221e5f361ded0663ae14cfac422059d0e7e93
585
py
Python
pip_services_runtime/data/IdGenerator.py
pip-services-archive/pip-services-runtime-python
70eca1ffc44bfdc45c9c65b0ee347fa578368849
[ "MIT" ]
null
null
null
pip_services_runtime/data/IdGenerator.py
pip-services-archive/pip-services-runtime-python
70eca1ffc44bfdc45c9c65b0ee347fa578368849
[ "MIT" ]
null
null
null
pip_services_runtime/data/IdGenerator.py
pip-services-archive/pip-services-runtime-python
70eca1ffc44bfdc45c9c65b0ee347fa578368849
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ pip_services_runtime.data.IdGenerator ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ID generator implementation. :copyright: Digital Living Software Corp. 2015-2016, see AUTHORS for more details. :license: MIT, see LICENSE for more details. """ import random import uuid class IdGenerator(object): """ Generates random keys and unique ids """ @staticmethod def short(): return str(random.randint(100000000, 999999999)) @staticmethod def uuid(): return str(uuid.uuid4()).replace("-", "")
21.666667
86
0.596581
60
585
5.783333
0.75
0.040346
0.080692
0
0
0
0
0
0
0
0
0.062084
0.22906
585
26
87
22.5
0.707317
0.502564
0
0.222222
0
0
0.004167
0
0
0
0
0
0
1
0.222222
true
0
0.222222
0.222222
0.777778
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
1
0
0
1
1
0
0
4
8cc53462b1e6923316b6500a44575cbe084657d9
207
py
Python
src1/src.py
elduha/python_ass2
4e0bfc6ce12de976fe58b4f99d15cd7bea9e1df6
[ "MIT" ]
null
null
null
src1/src.py
elduha/python_ass2
4e0bfc6ce12de976fe58b4f99d15cd7bea9e1df6
[ "MIT" ]
null
null
null
src1/src.py
elduha/python_ass2
4e0bfc6ce12de976fe58b4f99d15cd7bea9e1df6
[ "MIT" ]
1
2021-10-10T19:56:58.000Z
2021-10-10T19:56:58.000Z
from bs4 import BeautifulSoup from selenium import webdriver z = input("- Choose any crypto here: ") url = f'https://coinmarketcap.com/currencies/{z}/news/' driver = webdriver.Firefox()
34.5
64
0.676329
25
207
5.6
0.84
0
0
0
0
0
0
0
0
0
0
0.006098
0.207729
207
5
65
41.4
0.847561
0
0
0
0
0
0.356436
0
0
0
0
0
0
0
null
null
0
0.4
null
null
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
1
0
0
0
1
0
0
0
0
4
8cd9c359cd081b943c5a41d38b790fd928748960
101
py
Python
visual_helper_be/imgcaptioning/apps.py
HwangJohn/visual-helper
e4b0358c51ed2e14804d800a6ed454f36d103a20
[ "MIT" ]
null
null
null
visual_helper_be/imgcaptioning/apps.py
HwangJohn/visual-helper
e4b0358c51ed2e14804d800a6ed454f36d103a20
[ "MIT" ]
3
2021-03-30T13:46:50.000Z
2021-06-10T19:39:39.000Z
visual_helper_be/imgcaptioning/apps.py
HwangJohn/visual-helper
e4b0358c51ed2e14804d800a6ed454f36d103a20
[ "MIT" ]
null
null
null
from django.apps import AppConfig class ImgcaptioningConfig(AppConfig): name = 'imgcaptioning'
16.833333
37
0.782178
10
101
7.9
0.9
0
0
0
0
0
0
0
0
0
0
0
0.148515
101
5
38
20.2
0.918605
0
0
0
0
0
0.128713
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
8cda7dc2e9225b015680fbce8d374da83ae70011
153
py
Python
config.py
King-Amda/Song-Bot
fd28a97b81fca28624d5630f1a576e8c0e04ac6c
[ "Apache-2.0" ]
1
2021-10-08T03:18:23.000Z
2021-10-08T03:18:23.000Z
config.py
King-Amda/Song-Bot
fd28a97b81fca28624d5630f1a576e8c0e04ac6c
[ "Apache-2.0" ]
null
null
null
config.py
King-Amda/Song-Bot
fd28a97b81fca28624d5630f1a576e8c0e04ac6c
[ "Apache-2.0" ]
null
null
null
#SDBOTs <https://t.me/SDBOTs_Inifinity> import os API_ID = int(os.getenv("API_ID")) API_HASH = os.getenv("API_HASH") BOT_TOKEN = os.getenv("BOT_TOKEN")
21.857143
39
0.72549
27
153
3.851852
0.518519
0.230769
0.211538
0
0
0
0
0
0
0
0
0
0.091503
153
6
40
25.5
0.748201
0.248366
0
0
0
0
0.201754
0
0
0
0
0
0
1
0
false
0
0.25
0
0.25
0
1
0
0
null
1
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
8cf89a44ced8abce4f128db4c49db816a9a78fd7
86
py
Python
test2.py
liubaishuo-github/peening-post-processor
61f4c2d2385469bc1e9d1b7a692b72eb6afd7f75
[ "MIT" ]
null
null
null
test2.py
liubaishuo-github/peening-post-processor
61f4c2d2385469bc1e9d1b7a692b72eb6afd7f75
[ "MIT" ]
null
null
null
test2.py
liubaishuo-github/peening-post-processor
61f4c2d2385469bc1e9d1b7a692b72eb6afd7f75
[ "MIT" ]
null
null
null
def haha(): print('haha111') return 3,2 def mm(): haha() mm()
8.6
21
0.44186
11
86
3.454545
0.727273
0
0
0
0
0
0
0
0
0
0
0.09434
0.383721
86
9
22
9.555556
0.622642
0
0
0
0
0
0.090909
0
0
0
0
0
0
1
0.333333
true
0
0
0
0.5
0.166667
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
506f44c94ca7a54c2840105bd73f89cee6fcf85f
72
py
Python
driver.py
hyjoong/alien-invasion_
a8291d9c1d6177d0357bafe313048d3415a13257
[ "MIT" ]
null
null
null
driver.py
hyjoong/alien-invasion_
a8291d9c1d6177d0357bafe313048d3415a13257
[ "MIT" ]
null
null
null
driver.py
hyjoong/alien-invasion_
a8291d9c1d6177d0357bafe313048d3415a13257
[ "MIT" ]
null
null
null
from alien_invasion import AlienInvasion AlienInvasion().run_game()
10.285714
40
0.805556
8
72
7
0.875
0
0
0
0
0
0
0
0
0
0
0
0.125
72
6
41
12
0.888889
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
50732a571e7539bcf8baed6e3621eb01035feddf
494
py
Python
transonic/_version.py
fluiddyn/transonic
a460e9f6d1139f79b668cb3306d1e8a7e190b72d
[ "BSD-3-Clause" ]
88
2019-01-08T16:39:08.000Z
2022-02-06T14:19:23.000Z
transonic/_version.py
fluiddyn/transonic
a460e9f6d1139f79b668cb3306d1e8a7e190b72d
[ "BSD-3-Clause" ]
13
2019-06-20T15:53:10.000Z
2021-02-09T11:03:29.000Z
transonic/_version.py
fluiddyn/transonic
a460e9f6d1139f79b668cb3306d1e8a7e190b72d
[ "BSD-3-Clause" ]
1
2019-11-05T03:03:14.000Z
2019-11-05T03:03:14.000Z
__version__ = "0.4.11" try: from pyfiglet import figlet_format __about__ = figlet_format("transonic", font="big") except ImportError: __about__ = r""" _ _ | | (_) | |_ _ __ __ _ _ __ ___ ___ _ __ _ ___ | __| '__/ _` | '_ \/ __|/ _ \| '_ \| |/ __| | |_| | | (_| | | | \__ \ (_) | | | | | (__ \__|_| \__,_|_| |_|___/\___/|_| |_|_|\___| """ __about__ = __about__.rstrip() + f"{17 * ' '} v. {__version__}\n"
26
65
0.44332
28
494
4.571429
0.785714
0.1875
0
0
0
0
0
0
0
0
0
0.018634
0.348178
494
18
66
27.444444
0.378882
0
0
0
0
0.214286
0.619433
0
0
0
0
0
0
1
0
false
0
0.142857
0
0.142857
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
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
50a00672fac5ca2445d0ab9651c1fa782d264c65
405
py
Python
setting_render.py
korombus/blender_firework_py
4faccc3c7acac8c4a668c4735e7d7ec601c86d81
[ "MIT" ]
null
null
null
setting_render.py
korombus/blender_firework_py
4faccc3c7acac8c4a668c4735e7d7ec601c86d81
[ "MIT" ]
null
null
null
setting_render.py
korombus/blender_firework_py
4faccc3c7acac8c4a668c4735e7d7ec601c86d81
[ "MIT" ]
null
null
null
if __name__ == '__main__': # レンダリング設定 bpy.data.scenes["Scene"].render.filepath = "FILE_ROOT_PATH" bpy.data.scenes["Scene"].render.fps = 30 bpy.data.scenes["Scene"].render.image_settings.file_format = "FFMPEG" bpy.data.scenes["Scene"].render.ffmpeg.format = "MPEG4" bpy.data.scenes["Scene"].render.ffmpeg.codec = "H264" bpy.data.scenes["Scene"].render.ffmpeg.audio_codec = "AAC"
50.625
73
0.691358
55
405
4.854545
0.436364
0.157303
0.292135
0.404494
0.606742
0.337079
0
0
0
0
0
0.016949
0.125926
405
8
74
50.625
0.737288
0.019753
0
0
0
0
0.176768
0
0
0
0
0
0
1
0
true
0
0
0
0
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
1
0
0
0
0
0
0
4
50abbe99be00b02ec4e95b82fd2eee67518fd1c9
54
py
Python
python/tests/__init__.py
dfrankow/data_sync
23ff91392e2e4dee8cab4c732ed1b856bc246971
[ "MIT" ]
null
null
null
python/tests/__init__.py
dfrankow/data_sync
23ff91392e2e4dee8cab4c732ed1b856bc246971
[ "MIT" ]
null
null
null
python/tests/__init__.py
dfrankow/data_sync
23ff91392e2e4dee8cab4c732ed1b856bc246971
[ "MIT" ]
null
null
null
# required for "python setup.py test" to import tests
27
53
0.759259
9
54
4.555556
1
0
0
0
0
0
0
0
0
0
0
0
0.166667
54
1
54
54
0.911111
0.944444
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
50b53061b4358077a8aa75e5a68fce5c2e699a78
2,173
py
Python
app/home/db_router.py
Monxun/monxun-code
35ce6d4aaf3a8afa0b80dde1dae9a1e7603a1f84
[ "MIT" ]
null
null
null
app/home/db_router.py
Monxun/monxun-code
35ce6d4aaf3a8afa0b80dde1dae9a1e7603a1f84
[ "MIT" ]
null
null
null
app/home/db_router.py
Monxun/monxun-code
35ce6d4aaf3a8afa0b80dde1dae9a1e7603a1f84
[ "MIT" ]
null
null
null
from .models import ( # BIZ MODELS TableCharts, TableForecasts, #DATA HolidaysEventsModel, OilModel, SampleSubmissionModel, StoresModel, TestModel, TrainModel, TransactionsModel, # MUS MODELS TableSongs, # VBT MODELS TableBacktests, TableCompanyInfo, TableCurrencyuInfo, # SYMBOL MODELS # LOGS MODELS # TableLogsMus, # TableLogsBiz, # TableLogsVbt, ) # (Uncomment) # SCHEMA / MODELS LIST BIZ_MODELS = [ TableCharts, TableForecasts, HolidaysEventsModel, OilModel, SampleSubmissionModel, StoresModel, TestModel, TrainModel, TransactionsModel, ] MUS_MODELS = [ TableSongs, ] SYMBOL_MODELS = [ ] VBT_MODELS = [ TableBacktests, TableCompanyInfo, TableCurrencyuInfo, ] # LOGS_MODELS = [ # TableLogsMus, # TableLogsBiz, # TableLogsVbt, # ] # (Uncomment) class MyDBRouter(object): #BIZ ###################################### def db_for_read(self, model, **hints): if model in BIZ_MODELS: return 'biz' return None def db_for_write(self, model, **hints): if model in BIZ_MODELS: return 'biz' return None #MUS ###################################### def db_for_read(self, model, **hints): if model in MUS_MODELS: return 'mus' return None def db_for_write(self, model, **hints): if model in MUS_MODELS: return 'mus' return None #VBT ###################################### def db_for_read(self, model, **hints): if model in VBT_MODELS: return 'vbt' return None def db_for_write(self, model, **hints): if model in VBT_MODELS: return 'vbt' return None #LOGS (Uncomment) ###################################### # def db_for_read(self, model, **hints): # if model in LOGS_MODELS: # return 'logs' # return None # def db_for_write(self, model, **hints): # if model in LOGS_MODELS: # return 'logs' # return None
18.57265
45
0.535665
197
2,173
5.761421
0.218274
0.035242
0.056388
0.112775
0.849339
0.748899
0.651982
0.651982
0.651982
0.651982
0
0
0.316613
2,173
117
46
18.57265
0.76431
0.216751
0
0.819672
0
0
0.011834
0
0
0
0
0
0
1
0.098361
false
0
0.016393
0
0.327869
0
0
0
0
null
0
0
0
1
1
0
0
0
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
e86d1062f6ec9597510c9a3a7af4c32dd84c4df5
675
py
Python
splunk_eventgen/lib/logutils_src/tests/logutil_tests.py
hyacker/eventgen
2d33536e5b830b4bccb620b5239f25609c647c1a
[ "Apache-2.0" ]
5
2017-09-01T22:48:30.000Z
2022-03-06T05:04:05.000Z
splunk_eventgen/lib/logutils_src/tests/logutil_tests.py
hyacker/eventgen
2d33536e5b830b4bccb620b5239f25609c647c1a
[ "Apache-2.0" ]
null
null
null
splunk_eventgen/lib/logutils_src/tests/logutil_tests.py
hyacker/eventgen
2d33536e5b830b4bccb620b5239f25609c647c1a
[ "Apache-2.0" ]
1
2022-03-06T05:04:14.000Z
2022-03-06T05:04:14.000Z
# # Copyright (C) 2008-2017 Vinay Sajip. See LICENSE.txt for details. # import sys from test_testing import LoggingTest from test_dictconfig import ConfigDictTest from test_queue import QueueTest from test_formatter import FormatterTest from test_messages import MessageTest from test_colorize import ColorizeTest try: from test_redis import RedisQueueTest except ImportError: pass # The adapter won't work in < 2.5 because the "extra" parameter used by it # only appeared in 2.5 :-( if sys.version_info[:2] >= (2, 5): from test_adapter import AdapterTest else: print("LoggerAdapter won't work in Python < 2.5, so its tests are being " "skipped.")
29.347826
77
0.76
100
675
5.04
0.63
0.126984
0.031746
0.039683
0
0
0
0
0
0
0
0.030521
0.174815
675
22
78
30.681818
0.874327
0.241481
0
0
0
0
0.144269
0
0
0
0
0
0
1
0
true
0.0625
0.625
0
0.625
0.0625
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
1
1
0
1
0
0
4
e8733222ef332635c10f5d9f63d9232e8c19ff56
92
py
Python
ajax_helpers/apps.py
jonesim/ajax-helpers
63bf22470deba94a61892dbbc2408ca658479d15
[ "MIT" ]
null
null
null
ajax_helpers/apps.py
jonesim/ajax-helpers
63bf22470deba94a61892dbbc2408ca658479d15
[ "MIT" ]
null
null
null
ajax_helpers/apps.py
jonesim/ajax-helpers
63bf22470deba94a61892dbbc2408ca658479d15
[ "MIT" ]
null
null
null
from django.apps import AppConfig class ModalConfig(AppConfig): name = 'ajax_helpers'
15.333333
33
0.76087
11
92
6.272727
0.909091
0
0
0
0
0
0
0
0
0
0
0
0.163043
92
5
34
18.4
0.896104
0
0
0
0
0
0.130435
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
e89004986bb6ad3f369bc72d4b91496a8897b7d6
309
py
Python
src/odin_sequencer/__init__.py
stfc-aeg/odin-sequencer
38e5984259cc85edc177d0a3a09ade54f4ec4fe0
[ "Apache-2.0" ]
null
null
null
src/odin_sequencer/__init__.py
stfc-aeg/odin-sequencer
38e5984259cc85edc177d0a3a09ade54f4ec4fe0
[ "Apache-2.0" ]
22
2020-07-10T15:26:39.000Z
2021-09-17T15:07:39.000Z
src/odin_sequencer/__init__.py
stfc-aeg/odin-sequencer
38e5984259cc85edc177d0a3a09ade54f4ec4fe0
[ "Apache-2.0" ]
null
null
null
"""Top-level package for odin-sequencer.""" __author__ = """Tim Nicholls""" __email__ = 'tim.nicholls@stfc.ac.uk' __version__ = '0.1.0' from .exceptions import * # noqa: F401,F403 from .manager import * # noqa: F401,F403 from .watcher import * # noqa: F401,F403 from .process_queue import process_queue
25.75
44
0.711974
43
309
4.790698
0.604651
0.145631
0.203884
0.262136
0.320388
0
0
0
0
0
0
0.079545
0.145631
309
11
45
28.090909
0.700758
0.278317
0
0
0
0
0.186047
0.106977
0
0
0
0
0
1
0
false
0
0.571429
0
0.571429
0
0
0
0
null
0
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
4
e8c660a34577399fc3e0bbf2d11199541bbe2272
311
py
Python
Curso/ExMundo2/Ex039ElIf4Alistamento.py
DavidBitner/Aprendizado-Python
e1dcf18f9473c697fc2302f34a2d3e025ca6c969
[ "MIT" ]
null
null
null
Curso/ExMundo2/Ex039ElIf4Alistamento.py
DavidBitner/Aprendizado-Python
e1dcf18f9473c697fc2302f34a2d3e025ca6c969
[ "MIT" ]
null
null
null
Curso/ExMundo2/Ex039ElIf4Alistamento.py
DavidBitner/Aprendizado-Python
e1dcf18f9473c697fc2302f34a2d3e025ca6c969
[ "MIT" ]
null
null
null
a = int(input('Digite o ano de nascimento: ')) n = 2002 - a if n < 0: n = n * -1 print('Ainda faltam {} anos para o alistamento militar!'.format(n)) elif n > 0: print('Já se passaram {} anos para o alistamento militar!'.format(n)) else: print('Este é o ano para efetuar o alistamento militar!')
31.1
73
0.639871
52
311
3.826923
0.557692
0.180905
0.286432
0.201005
0.341709
0.341709
0.341709
0
0
0
0
0.028926
0.221865
311
9
74
34.555556
0.793388
0
0
0
0
0
0.559486
0
0
0
0
0
0
1
0
false
0.111111
0
0
0
0.333333
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
1
0
0
0
0
0
4
e8d5e7141099eb418df2dfa5d66f2065292846bc
203
py
Python
jobboard/serializers/KeywordSerializer.py
OnGridSystems/RobotVeraWebApp
01cee658a3983fcaf128b40bb99c1a4272e90c07
[ "MIT" ]
11
2018-06-13T10:10:11.000Z
2021-06-05T08:23:43.000Z
jobboard/serializers/KeywordSerializer.py
OnGridSystems/RobotVeraWebApp
01cee658a3983fcaf128b40bb99c1a4272e90c07
[ "MIT" ]
5
2021-03-19T23:41:21.000Z
2022-03-12T00:37:18.000Z
jobboard/serializers/KeywordSerializer.py
OnGridSystems/RobotVeraWebApp
01cee658a3983fcaf128b40bb99c1a4272e90c07
[ "MIT" ]
5
2018-08-17T16:09:33.000Z
2021-06-06T05:32:10.000Z
from rest_framework import serializers from jobboard.models import Keyword class KeywordSerializer(serializers.ModelSerializer): class Meta: model = Keyword fields = ('id', 'word')
22.555556
53
0.724138
21
203
6.952381
0.761905
0
0
0
0
0
0
0
0
0
0
0
0.20197
203
8
54
25.375
0.901235
0
0
0
0
0
0.029557
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
2ce33b9ca8fd2f6071b3b83e2de7aa27f21617a8
363
py
Python
pytpp/attributes/symantec_lhk_ca.py
Venafi/pytpp
42af655b2403b8c9447c86962abd4aaa0201f646
[ "MIT" ]
4
2022-02-04T23:58:55.000Z
2022-02-15T18:53:08.000Z
pytpp/attributes/symantec_lhk_ca.py
Venafi/pytpp
42af655b2403b8c9447c86962abd4aaa0201f646
[ "MIT" ]
null
null
null
pytpp/attributes/symantec_lhk_ca.py
Venafi/pytpp
42af655b2403b8c9447c86962abd4aaa0201f646
[ "MIT" ]
null
null
null
from pytpp.attributes._helper import IterableMeta, Attribute from pytpp.attributes.http_ca_base import HTTPCABaseAttributes from pytpp.attributes.proxy import ProxyAttributes class SymantecLHKCAAttributes(HTTPCABaseAttributes, ProxyAttributes, metaclass=IterableMeta): __config_class__ = "Symantec LHK CA" fields = Attribute('Fields') uri = Attribute('URI')
36.3
93
0.837466
38
363
7.789474
0.552632
0.091216
0.192568
0
0
0
0
0
0
0
0
0
0.090909
363
9
94
40.333333
0.89697
0
0
0
0
0
0.066116
0
0
0
0
0
0
1
0
false
0
0.428571
0
1
0
0
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
1
0
0
4
2ce5f994fceccf034ded7a7801b6ff75a94e3f01
333
py
Python
server/rtracker/mainapp/serializers.py
Aqudei/RTrackerv3
17d769d33a64b56680c046359489f16304293d0c
[ "Apache-2.0" ]
null
null
null
server/rtracker/mainapp/serializers.py
Aqudei/RTrackerv3
17d769d33a64b56680c046359489f16304293d0c
[ "Apache-2.0" ]
null
null
null
server/rtracker/mainapp/serializers.py
Aqudei/RTrackerv3
17d769d33a64b56680c046359489f16304293d0c
[ "Apache-2.0" ]
null
null
null
from rest_framework import serializers from . import models class ReportSerializer(serializers.ModelSerializer): class Meta: model = models.Report fields = '__all__' class ROUserSerializer(serializers.ModelSerializer): class Meta: model = models.ROUser fields = '__all__' depth = 1
22.2
52
0.687688
32
333
6.875
0.5625
0.236364
0.281818
0.318182
0.418182
0.418182
0
0
0
0
0
0.003984
0.246246
333
15
53
22.2
0.87251
0
0
0.363636
0
0
0.041916
0
0
0
0
0
0
1
0
false
0
0.181818
0
0.545455
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
2cfda55404a7990e1289f0abff4cba8d9d81ce1e
67
py
Python
packages/meerkat/src/meerkat/domain/post/value_objects/__init__.py
0mars/ektebly-api
79e77c73d39e30cf37ec08097d5d3a7fec7a7c54
[ "Apache-2.0" ]
2
2019-08-19T06:57:46.000Z
2021-06-02T06:10:24.000Z
packages/meerkat/src/meerkat/domain/post/value_objects/__init__.py
0mars/ektebly-api
79e77c73d39e30cf37ec08097d5d3a7fec7a7c54
[ "Apache-2.0" ]
1
2019-09-26T11:20:50.000Z
2019-09-26T11:20:50.000Z
packages/meerkat/src/meerkat/domain/post/value_objects/__init__.py
0mars/ektebly-api
79e77c73d39e30cf37ec08097d5d3a7fec7a7c54
[ "Apache-2.0" ]
1
2019-09-24T07:42:21.000Z
2019-09-24T07:42:21.000Z
from .title import Title from .body import Body from .id import Id
16.75
24
0.776119
12
67
4.333333
0.416667
0
0
0
0
0
0
0
0
0
0
0
0.179104
67
3
25
22.333333
0.945455
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
4
fa2459578791b9fc7f21a0c21bfc3d46028c56be
167
py
Python
spec/main_spec.py
pmareke/python-starter
2b460870e03f5961e66a19989184b1de6f251d13
[ "MIT" ]
null
null
null
spec/main_spec.py
pmareke/python-starter
2b460870e03f5961e66a19989184b1de6f251d13
[ "MIT" ]
null
null
null
spec/main_spec.py
pmareke/python-starter
2b460870e03f5961e66a19989184b1de6f251d13
[ "MIT" ]
null
null
null
from mamba import description, it from expects import expect, be_true with description('DummyClass') as self: with it('#dummy'): expect(True).to(be_true)
23.857143
39
0.712575
24
167
4.875
0.625
0.102564
0
0
0
0
0
0
0
0
0
0
0.179641
167
6
40
27.833333
0.854015
0
0
0
0
0
0.095808
0
0
0
0
0
0
1
0
true
0
0.4
0
0.4
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
4
d70be285786de9d5eb5fee7bda3c49d391b71558
7,824
py
Python
tests/test_hd_wallet.py
isabella232/aepp-sdk-python
58ac2d12e0062896a473c254781ee397e3da318e
[ "0BSD" ]
22
2018-02-20T02:39:34.000Z
2021-12-17T12:12:00.000Z
tests/test_hd_wallet.py
aeternity/aepp-sdk-python
58ac2d12e0062896a473c254781ee397e3da318e
[ "0BSD" ]
284
2018-02-12T11:50:39.000Z
2021-07-27T04:55:15.000Z
tests/test_hd_wallet.py
isabella232/aepp-sdk-python
58ac2d12e0062896a473c254781ee397e3da318e
[ "0BSD" ]
17
2018-02-20T17:17:12.000Z
2022-03-06T08:36:26.000Z
import os from aeternity.hdwallet import HDWallet from aeternity.signing import Account from nacl.signing import SigningKey def test_hdwallet_generate_wallet(): mnemonic = HDWallet.generate_mnemonic() assert mnemonic is not None hdwallet = HDWallet(mnemonic) assert hdwallet.master_key is not None def test_hdwallet_generate_wallet_without_mnemonic(): hdwallet = HDWallet() assert hdwallet.mnemonic is not None def test_hdwallet_keystore_save_load_pass(tempdir): hdwallet = HDWallet() password = "testpassword" saved_filename = hdwallet.save_mnemonic_to_keystore(tempdir, password) path = os.path.join(tempdir, saved_filename) print(f"\nAccount keystore is {path}") hdwallet_decrypted = HDWallet.from_keystore(path, password) assert hdwallet_decrypted.mnemonic == hdwallet.mnemonic def test_hdwallet_keystore_save_load_wrong_pwd(tempdir): try: hdwallet = HDWallet() password_original = "testpassword" password_wrong = "whateverpassword" saved_filename = hdwallet.save_mnemonic_to_keystore(tempdir, password_original) path = os.path.join(tempdir, saved_filename) print(f"\nAccount keystore is {path}") hdwallet_decrypted = HDWallet.from_keystore(path, password_wrong) except Exception as e: assert str(e) == "Decryption failed. Ciphertext failed verification" def test_hdwallet_keystore_save_load_wrong_type(tempdir): try: original_account = Account.generate() filename = original_account.save_to_keystore(tempdir, "whatever") path = os.path.join(tempdir, filename) print(f"\nAccount keystore is {path}") hdwallet_decrypted = HDWallet.from_keystore(path, "whatever") except Exception as e: assert str(e) == "Invalid keystore. Expected keystore of type ed25519-bip39-mnemonic" def test_hdwallet_path_derivation(): mnemonic = "energy pass install genuine sell enroll wear announce brother marble test cruise" hdwallet = HDWallet(mnemonic) expected_path = "m/44'/457'/0'/0'/0'" expected_address = "ak_anBY5wEamzK1L1L3f4gZr8RrUMEfgSEmRpAJKTETTETA9k6Kp" expected_private_key = "40a0dc9b6be8ca58ec3b6773a118f8237092d0b5f3d48d4c08a6cfbde258aa3d4cb307d4f30e35ea50ddf29043f2827d8c129cd7c03d981a9b0cc79703160e17" path, child_account = hdwallet.derive_child() assert expected_path == path assert child_account.address == expected_address assert child_account.get_secret_key() == expected_private_key expected_path = "m/44'/457'/12'/0'/0'" expected_address = "ak_2FZU4teXWLyHWVbvf1ajejzKrcuyXffP4jaoedRDvv579mEjiY" expected_private_key = "032374e3b7c11cb2e5dd62a633d13af7de7f231e721b6f797423978e5e4a7faaa4c17e635de2171a515dc4f049b63957ef8778b4b02533f6791554def9ceda97" path, child_account = hdwallet.derive_child(account_index=12) assert expected_path == path assert child_account.address == expected_address assert child_account.get_secret_key() == expected_private_key expected_path = "m/44'/457'/12'/0'/1'" expected_address = "ak_hPd6XVrLFxBGcKwBbeVA3PWNqE5YJk2NrPuUNp9Lp5q4KHvUX" expected_private_key = "96bab5642835618383a48bb759d4179dbc9a0e9bbd79424c973cdfa694fc5c485bb5e51e9d1d7fcf3bd17cd7ae3af549addf1dd4fe66365c72757796e47d5639" path, child_account = hdwallet.derive_child(account_index=12, address_index=1) assert expected_path == path assert child_account.address == expected_address assert child_account.get_secret_key() == expected_private_key # ref: https://github.com/satoshilabs/slips/blob/master/slip-0010.md def test_hdwallet_slip0010(): test_data = [{ "seed": "000102030405060708090a0b0c0d0e0f", "tests": [{ "path": "m", "chain": "90046a93de5380a72b5e45010748567d5ea02bbf6522f979e05c0d8d8ca9fffb", "prv": "2b4be7f19ee27bbf30c667b642d5f4aa69fd169872f8fc3059c08ebae2eb19e7", "pub": "00a4b2856bfec510abab89753fac1ac0e1112364e7d250545963f135f2a33188ed" }, { "path": "m/0'", "chain": "8b59aa11380b624e81507a27fedda59fea6d0b779a778918a2fd3590e16e9c69", "prv": "68e0fe46dfb67e368c75379acec591dad19df3cde26e63b93a8e704f1dade7a3", "pub": "008c8a13df77a28f3445213a0f432fde644acaa215fc72dcdf300d5efaa85d350c" }, { "path": "m/0'/1'", "chain": "a320425f77d1b5c2505a6b1b27382b37368ee640e3557c315416801243552f14", "prv": "b1d0bad404bf35da785a64ca1ac54b2617211d2777696fbffaf208f746ae84f2", "pub": "001932a5270f335bed617d5b935c80aedb1a35bd9fc1e31acafd5372c30f5c1187" }, { "path": "m/0'/1'/2'", "chain": "2e69929e00b5ab250f49c3fb1c12f252de4fed2c1db88387094a0f8c4c9ccd6c", "prv": "92a5b23c0b8a99e37d07df3fb9966917f5d06e02ddbd909c7e184371463e9fc9", "pub": "00ae98736566d30ed0e9d2f4486a64bc95740d89c7db33f52121f8ea8f76ff0fc1" }, { "path": "m/0'/1'/2'/2'", "chain": "8f6d87f93d750e0efccda017d662a1b31a266e4a6f5993b15f5c1f07f74dd5cc", "prv": "30d1dc7e5fc04c31219ab25a27ae00b50f6fd66622f6e9c913253d6511d1e662", "pub": "008abae2d66361c879b900d204ad2cc4984fa2aa344dd7ddc46007329ac76c429c" }, { "path": "m/0'/1'/2'/2'/1000000000'", "chain": "68789923a0cac2cd5a29172a475fe9e0fb14cd6adb5ad98a3fa70333e7afa230", "prv": "8f94d394a8e8fd6b1bc2f3f49f5c47e385281d5c17e65324b0f62483e37e8793", "pub": "003c24da049451555d51a7014a37337aa4e12d41e485abccfa46b47dfb2af54b7a" }] }, { "seed": "fffcf9f6f3f0edeae7e4e1dedbd8d5d2cfccc9c6c3c0bdbab7b4b1aeaba8a5a29f9c999693908d8a8784817e7b7875726f6c696663605d5a5754514e4b484542", "tests": [{ "path": "m", "chain": "ef70a74db9c3a5af931b5fe73ed8e1a53464133654fd55e7a66f8570b8e33c3b", "prv": "171cb88b1b3c1db25add599712e36245d75bc65a1a5c9e18d76f9f2b1eab4012", "pub": "008fe9693f8fa62a4305a140b9764c5ee01e455963744fe18204b4fb948249308a" }, { "path": "m/0'", "chain": "0b78a3226f915c082bf118f83618a618ab6dec793752624cbeb622acb562862d", "prv": "1559eb2bbec5790b0c65d8693e4d0875b1747f4970ae8b650486ed7470845635", "pub": "0086fab68dcb57aa196c77c5f264f215a112c22a912c10d123b0d03c3c28ef1037" }, { "path": "m/0'/2147483647'", "chain": "138f0b2551bcafeca6ff2aa88ba8ed0ed8de070841f0c4ef0165df8181eaad7f", "prv": "ea4f5bfe8694d8bb74b7b59404632fd5968b774ed545e810de9c32a4fb4192f4", "pub": "005ba3b9ac6e90e83effcd25ac4e58a1365a9e35a3d3ae5eb07b9e4d90bcf7506d" }, { "path": "m/0'/2147483647'/1'", "chain": "73bd9fff1cfbde33a1b846c27085f711c0fe2d66fd32e139d3ebc28e5a4a6b90", "prv": "3757c7577170179c7868353ada796c839135b3d30554bbb74a4b1e4a5a58505c", "pub": "002e66aa57069c86cc18249aecf5cb5a9cebbfd6fadeab056254763874a9352b45" }, { "path": "m/0'/2147483647'/1'/2147483646'", "chain": "0902fe8a29f9140480a00ef244bd183e8a13288e4412d8389d140aac1794825a", "prv": "5837736c89570de861ebc173b1086da4f505d4adb387c6a1b1342d5e4ac9ec72", "pub": "00e33c0f7d81d843c572275f287498e8d408654fdf0d1e065b84e2e6f157aab09b" }, { "path": "m/0'/2147483647'/1'/2147483646'/2'", "chain": "5d70af781f3a37b829f0d060924d5e960bdc02e85423494afc0b1a41bbe196d4", "prv": "551d333177df541ad876a60ea71f00447931c0a9da16f227c11ea080d7391b8d", "pub": "0047150c75db263559a70d5778bf36abbab30fb061ad69f69ece61a72b0cfa4fc0" }] }] for x in test_data: master_key = HDWallet._master_key_from_seed(x["seed"]) for test in x["tests"]: key = HDWallet._from_path(test["path"], master_key)[-1] assert test["chain"] == key["chain_code"].hex() assert test["prv"] == key["secret_key"].hex() assert test["pub"] == "00"+ SigningKey(key["secret_key"]).verify_key._key.hex()
50.153846
157
0.747572
577
7,824
9.928943
0.268631
0.013091
0.010473
0.004887
0.231803
0.206668
0.17682
0.154477
0.154477
0.117123
0
0.297363
0.156697
7,824
155
158
50.477419
0.570931
0.008436
0
0.309353
1
0
0.495358
0.404977
0
0
0
0
0.129496
1
0.05036
false
0.064748
0.028777
0
0.079137
0.021583
0
0
0
null
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
1
0
0
1
null
0
0
0
0
0
0
0
1
0
0
0
0
0
4
d7269c3f127d72ebcfff8dff10f091096ab0810d
110
py
Python
import_data.py
kevin-klein/101wiki
8647271c00e8e9d954df2e43ddbf12f5f3d062be
[ "MIT" ]
null
null
null
import_data.py
kevin-klein/101wiki
8647271c00e8e9d954df2e43ddbf12f5f3d062be
[ "MIT" ]
1
2020-02-12T00:17:34.000Z
2020-02-12T00:17:34.000Z
import_data.py
kevin-klein/101wiki
8647271c00e8e9d954df2e43ddbf12f5f3d062be
[ "MIT" ]
null
null
null
import json from pages.models import * with open('db.json') as f: data = json.load(f) import_data(data)
13.75
26
0.690909
19
110
3.947368
0.631579
0
0
0
0
0
0
0
0
0
0
0
0.181818
110
7
27
15.714286
0.833333
0
0
0
0
0
0.063636
0
0
0
0
0
0
1
0
false
0
0.6
0
0.6
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
d7401c1bd02084d362f5c2fdac9b889ddd6d8ef5
138
py
Python
Modulo-01/ex003/ex003.py
Matheus-Henrique-Burey/Curso-de-Python
448aebaab96527affa1e45897a662bb0407c11c6
[ "MIT" ]
null
null
null
Modulo-01/ex003/ex003.py
Matheus-Henrique-Burey/Curso-de-Python
448aebaab96527affa1e45897a662bb0407c11c6
[ "MIT" ]
null
null
null
Modulo-01/ex003/ex003.py
Matheus-Henrique-Burey/Curso-de-Python
448aebaab96527affa1e45897a662bb0407c11c6
[ "MIT" ]
null
null
null
num1 = int(input('Digite o primeiro numero: ')) num2 = int(input('Digite outro: ')) print(f'a soma entre {num1} e {num2} é: {num1+num2}')
34.5
53
0.652174
23
138
3.913043
0.695652
0.177778
0.311111
0
0
0
0
0
0
0
0
0.050847
0.144928
138
3
54
46
0.711864
0
0
0
0
0
0.601449
0
0
0
0
0
0
1
0
false
0
0
0
0
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
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
d747d643062ba995a632c30a96f7435763889f4a
32
py
Python
test2/generated/structures/20170528165346_rtype.py
nm-wu/RAMLFlask
003ceb0f0b68d0d80d8fb8fcd6d5b329a1608dd0
[ "BSD-3-Clause" ]
4
2017-11-30T10:23:12.000Z
2020-06-07T01:05:12.000Z
test2/generated/structures/20170601093553_rtype.py
nm-wu/RAMLFlask
003ceb0f0b68d0d80d8fb8fcd6d5b329a1608dd0
[ "BSD-3-Clause" ]
null
null
null
test2/generated/structures/20170601093553_rtype.py
nm-wu/RAMLFlask
003ceb0f0b68d0d80d8fb8fcd6d5b329a1608dd0
[ "BSD-3-Clause" ]
1
2017-12-14T17:11:05.000Z
2017-12-14T17:11:05.000Z
{'GET /stream/<int:n>': set([])}
32
32
0.5
5
32
3.2
1
0
0
0
0
0
0
0
0
0
0
0
0.0625
32
1
32
32
0.533333
0
0
0
0
0
0.575758
0
0
0
0
0
0
1
0
true
0
0
0
0
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
4
d7481bc45f8e29bb77666b9ca3a7cadf7a737de1
6,584
py
Python
sota_extractor/commands/scrapers.py
zeke/sota-extractor
c65c3ee6864683f144de03913a7e16ed9fb60a9b
[ "Apache-2.0" ]
null
null
null
sota_extractor/commands/scrapers.py
zeke/sota-extractor
c65c3ee6864683f144de03913a7e16ed9fb60a9b
[ "Apache-2.0" ]
null
null
null
sota_extractor/commands/scrapers.py
zeke/sota-extractor
c65c3ee6864683f144de03913a7e16ed9fb60a9b
[ "Apache-2.0" ]
null
null
null
import click from sota_extractor import scrapers from sota_extractor.consts import Format from sota_extractor import serialization from sota_extractor.commands.cli import cli from sota_extractor.errors import catch_errors @cli.command() @click.option( "-o", "--output", type=click.Path(exists=False), required=False, default="data/tasks/eff.json", help="Output filename.", ) @click.option( "-f", "--fmt", type=click.Choice(Format), default=Format.json, help="Output format.", ) @catch_errors def eff(output, fmt): """Extract EFF SOTA tables.""" serialization.dump(tdb=scrapers.eff(), output=output, fmt=fmt) @cli.command() @click.option( "-o", "--output", type=click.Path(exists=False), required=False, default="data/tasks/redditsota.json", help="Output filename.", ) @click.option( "-f", "--fmt", type=click.Choice(Format), default=Format.json, help="Output format.", ) @catch_errors def reddit(output, fmt): """Extract Reddit SOTA tables.""" serialization.dump(tdb=scrapers.reddit(), output=output, fmt=fmt) @cli.command() @click.option( "-o", "--output", type=click.Path(exists=False), required=False, default="data/tasks/snli.json", help="Output filename.", ) @click.option( "-f", "--fmt", type=click.Choice(Format), default=Format.json, help="Output format.", ) @catch_errors def snli(output, fmt): """Extract SNLI SOTA tables.""" serialization.dump(tdb=scrapers.snli(), output=output, fmt=fmt) @cli.command() @click.option( "-o", "--output", type=click.Path(exists=False), required=False, default="data/tasks/squad.json", help="Output filename.", ) @click.option( "-f", "--fmt", type=click.Choice(Format), default=Format.json, help="Output format.", ) @catch_errors def squad(output, fmt): """Extract SQUAD SOTA tables.""" serialization.dump(tdb=scrapers.squad(), output=output, fmt=fmt) @cli.command() @click.option( "-o", "--output", type=click.Path(exists=False), required=False, default="data/tasks/cityscapes.json", help="Output filename.", ) @click.option( "-f", "--fmt", type=click.Choice(Format), default=Format.json, help="Output format.", ) @catch_errors def cityscapes(output, fmt): """Extract Cityscapes SOTA tables.""" serialization.dump(tdb=scrapers.cityscapes(), output=output, fmt=fmt) @cli.command("nlp-progress") @click.option( "-o", "--output", type=click.Path(exists=False), required=False, default="data/tasks/nlp-progress.json", help="Output filename.", ) @click.option( "-f", "--fmt", type=click.Choice(Format), default=Format.json, help="Output format.", ) @catch_errors def nlp_progress(output, fmt): """Extract NLP Progress SOTA tables.""" serialization.dump(tdb=scrapers.nlp_progress(), output=output, fmt=fmt) @cli.command() @click.option( "-o", "--output", type=click.Path(exists=False), required=False, default="data/tasks/smcalflow.json", help="Output filename.", ) @click.option( "-f", "--fmt", type=click.Choice(Format), default=Format.json, help="Output format.", ) @catch_errors def smcalflow(output, fmt): """Extract Smcalflow SOTA tables.""" serialization.dump(tdb=scrapers.smcalflow(), output=output, fmt=fmt) @cli.command() @click.option( "-o", "--output", type=click.Path(exists=False), required=False, default="data/tasks/record.json", help="Output filename.", ) @click.option( "-f", "--fmt", type=click.Choice(Format), default=Format.json, help="Output format.", ) @catch_errors def record(output, fmt): """Extract Record SOTA tables.""" serialization.dump(tdb=scrapers.record(), output=output, fmt=fmt) @cli.command() @click.option( "-o", "--output", type=click.Path(exists=False), required=False, default="data/tasks/hotpotqa.json", help="Output filename.", ) @click.option( "-f", "--fmt", type=click.Choice(Format), default=Format.json, help="Output format.", ) @catch_errors def hotpotqa(output, fmt): """Extract hotpotqa SOTA tables.""" serialization.dump(tdb=scrapers.hotpotqa(), output=output, fmt=fmt) @cli.command() @click.option( "-o", "--output", type=click.Path(exists=False), required=False, default="data/tasks/coqa.json", help="Output filename.", ) @click.option( "-f", "--fmt", type=click.Choice(Format), default=Format.json, help="Output format.", ) @catch_errors def coqa(output, fmt): """Extract coqa SOTA tables.""" serialization.dump(tdb=scrapers.coqa(), output=output, fmt=fmt) @cli.command() @click.option( "-o", "--output", type=click.Path(exists=False), required=False, default="data/tasks/chexpert.json", help="Output filename.", ) @click.option( "-f", "--fmt", type=click.Choice(Format), default=Format.json, help="Output format.", ) @catch_errors def chexpert(output, fmt): """Extract chexpert SOTA tables.""" serialization.dump(tdb=scrapers.chexpert(), output=output, fmt=fmt) @cli.command() @click.option( "-o", "--output", type=click.Path(exists=False), required=False, default="data/tasks/cmrc.json", help="Output filename.", ) @click.option( "-f", "--fmt", type=click.Choice(Format), default=Format.json, help="Output format.", ) @catch_errors def cmrc(output, fmt): """Extract cmrc SOTA tables.""" serialization.dump(tdb=scrapers.cmrc(), output=output, fmt=fmt) @cli.command() @click.option( "-o", "--output", type=click.Path(exists=False), required=False, default="data/tasks/xtreme.json", help="Output filename.", ) @click.option( "-f", "--fmt", type=click.Choice(Format), default=Format.json, help="Output format.", ) @catch_errors def xtreme(output, fmt): """Extract Xtreme SOTA tables.""" serialization.dump(tdb=scrapers.xtreme(), output=output, fmt=fmt) @cli.command() @click.option( "-o", "--output", type=click.Path(exists=False), required=False, default="data/tasks/ogb.json", help="Output filename.", ) @click.option( "-f", "--fmt", type=click.Choice(Format), default=Format.json, help="Output format.", ) @catch_errors def ogb(output, fmt): """Extract OGB SOTA tables.""" serialization.dump(tdb=scrapers.ogb(), output=output, fmt=fmt)
20.901587
75
0.635936
794
6,584
5.245592
0.065491
0.07395
0.094118
0.060504
0.809124
0.809124
0.67467
0.67467
0.67467
0.67467
0
0
0.179982
6,584
314
76
20.968153
0.771439
0.059994
0
0.716912
0
0
0.161164
0.035633
0
0
0
0
0
1
0.051471
false
0
0.022059
0
0.073529
0
0
0
0
null
0
0
0
1
1
0
0
0
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
d75d15e70a7d35033bd3c852de93444754cc95d8
256
py
Python
onir/modules/__init__.py
Georgetown-IR-Lab/OpenNIR
7d93e8643fe311e3e9c7a0678efe9775fd80485e
[ "MIT" ]
140
2020-02-05T23:48:53.000Z
2022-03-29T03:47:31.000Z
onir/modules/__init__.py
Georgetown-IR-Lab/OpenNIR
7d93e8643fe311e3e9c7a0678efe9775fd80485e
[ "MIT" ]
33
2020-03-19T22:07:58.000Z
2022-02-23T15:18:29.000Z
onir/modules/__init__.py
Georgetown-IR-Lab/OpenNIR
7d93e8643fe311e3e9c7a0678efe9775fd80485e
[ "MIT" ]
16
2020-03-19T19:01:04.000Z
2021-12-12T04:18:57.000Z
from onir.modules.interaction_matrix import InteractionMatrix, cos_simmat, binmat from onir.modules.bert import CustomBertModel, CustomBertModelWrapper from onir.modules.prettr_bert import PrettrBertModel from onir.modules.rbf_kernels import RbfKernelBank
51.2
81
0.882813
31
256
7.16129
0.580645
0.144144
0.27027
0
0
0
0
0
0
0
0
0
0.074219
256
4
82
64
0.936709
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
0
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
4
d7662d306f7406a7c672b4875db5008de9d74a3c
199
py
Python
commands/utils/checks.py
KangasZ/SuzuBot
5384f5ddcf0b36e516bf6f442ca2dda1d9d7c7ff
[ "MIT" ]
null
null
null
commands/utils/checks.py
KangasZ/SuzuBot
5384f5ddcf0b36e516bf6f442ca2dda1d9d7c7ff
[ "MIT" ]
null
null
null
commands/utils/checks.py
KangasZ/SuzuBot
5384f5ddcf0b36e516bf6f442ca2dda1d9d7c7ff
[ "MIT" ]
null
null
null
from discord.ext import commands def is_mod(): async def pred(ctx): #return await check_guild_permissions(ctx, {'manage_guild': True}) return True return commands.check(pred)
28.428571
74
0.693467
27
199
4.962963
0.666667
0.149254
0
0
0
0
0
0
0
0
0
0
0.211055
199
7
75
28.428571
0.853503
0.326633
0
0
0
0
0
0
0
0
0
0
0
1
0.2
true
0
0.2
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
1
0
0
0
1
0
0
4
d786941e43ec86b9370fed37daaf65b586a682f2
311
py
Python
yodatools/yodaparser/samplefiles/prototypes/iUTAH_MultiTimeSeriesExample_ParseYaml.py
ODM2/YODAParser
274a1fc5ed1810bc748a4ab108855254f8b9fc46
[ "BSD-3-Clause" ]
3
2015-12-14T19:54:08.000Z
2018-11-30T04:05:06.000Z
yodatools/yodaparser/samplefiles/prototypes/iUTAH_MultiTimeSeriesExample_ParseYaml.py
ODM2/YODAParser
274a1fc5ed1810bc748a4ab108855254f8b9fc46
[ "BSD-3-Clause" ]
37
2015-12-23T18:32:06.000Z
2019-05-30T17:17:43.000Z
yodatools/yodaparser/samplefiles/prototypes/iUTAH_MultiTimeSeriesExample_ParseYaml.py
ODM2/ODM2YODAParser
274a1fc5ed1810bc748a4ab108855254f8b9fc46
[ "BSD-3-Clause" ]
1
2017-07-06T18:42:22.000Z
2017-07-06T18:42:22.000Z
import yaml longHeaderStream = file('iUTAH_MultiTimeSeriesExample_LongHeader.yaml', 'r') longHeaderObject = yaml.load(longHeaderStream) compactHeaderStream = file('iUTAH_MultiTimeSeriesExample_CompactHeader.yaml', 'r') compactHeaderObject = yaml.load(compactHeaderStream) print yaml.dump(compactHeaderObject)
34.555556
82
0.842444
28
311
9.214286
0.535714
0.069767
0.24031
0
0
0
0
0
0
0
0
0
0.064309
311
9
83
34.555556
0.886598
0
0
0
0
0
0.298077
0.291667
0
0
0
0
0
0
null
null
0
0.166667
null
null
0.166667
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
1
0
0
0
0
0
0
0
0
4
ad00d7d30af70a67feae3130c254d5d11255abb5
498
py
Python
dsatools/frequency.py
diarmaidocualain/dsatools
50b9259e2846b5fdd3dc52206967b0ee8d0144de
[ "MIT" ]
31
2020-09-14T16:12:01.000Z
2022-03-30T01:44:18.000Z
frequency.py
Jimmy-INL/dsatools
5c811838bb3fb8ae00195d5f68e451bd23b3448c
[ "MIT" ]
4
2021-09-24T17:47:42.000Z
2022-03-04T08:06:43.000Z
frequency.py
Jimmy-INL/dsatools
5c811838bb3fb8ae00195d5f68e451bd23b3448c
[ "MIT" ]
11
2020-12-06T08:18:56.000Z
2022-03-20T13:28:22.000Z
from ._base._frequency import(fitz_r, kay, mcrb, m_and_m, fitz, f_and_k, tretter_f, ml_fft, barycenter_fft, barycenter_general_gauss_fft, maxcorfreq, maxcorfreq_real)
38.307692
59
0.277108
28
498
4.428571
0.714286
0.209677
0
0
0
0
0
0
0
0
0
0
0.692771
498
12
60
41.5
0.810458
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.083333
0
0.083333
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
1
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
ad18bd227379deb494d6f153f22dde9941587d40
331
py
Python
market/checkout/async.py
katomaso/django-market
84c4fa10aefbd792a956cef3d727623ca78cb5fd
[ "MIT" ]
null
null
null
market/checkout/async.py
katomaso/django-market
84c4fa10aefbd792a956cef3d727623ca78cb5fd
[ "MIT" ]
null
null
null
market/checkout/async.py
katomaso/django-market
84c4fa10aefbd792a956cef3d727623ca78cb5fd
[ "MIT" ]
null
null
null
#import calery def send_proforma_to_seller(order_id): print("Sending proforma to seller") def send_proforma_to_buyer(order_id): print("Sending proforma to buyer") def send_invoice_to_seller(order_id): print("Sending invoice to seller") def send_invoice_to_buyer(order_id): print("Sending invoice to buyer")
18.388889
39
0.761329
50
331
4.72
0.26
0.118644
0.20339
0.322034
0.610169
0.610169
0
0
0
0
0
0
0.151057
331
17
40
19.470588
0.839858
0.039275
0
0
0
0
0.315457
0
0
0
0
0
0
1
0.5
false
0
0
0
0.5
0.5
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
1
0
0
0
0
0
1
0
4
ad1eb67ef08dc804d6d97ca2d4aa70c59c4288cd
91
py
Python
importpath_field/db/__init__.py
Apkawa/django-import-path-field
16e45621b519f13147ed9e980ffaefd1c79d0940
[ "MIT" ]
null
null
null
importpath_field/db/__init__.py
Apkawa/django-import-path-field
16e45621b519f13147ed9e980ffaefd1c79d0940
[ "MIT" ]
1
2020-01-08T11:18:34.000Z
2020-01-08T11:18:34.000Z
importpath_field/db/__init__.py
Apkawa/django-import-path-field
16e45621b519f13147ed9e980ffaefd1c79d0940
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from .fields import ImportPathField __all__ = ['ImportPathField']
18.2
35
0.692308
9
91
6.555556
0.888889
0
0
0
0
0
0
0
0
0
0
0.012821
0.142857
91
4
36
22.75
0.74359
0.230769
0
0
0
0
0.220588
0
0
0
0
0
0
1
0
false
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
0
0
1
0
1
0
0
4
ad1f9cdfed72f8200eea1946ac2cbd8300e74ed9
381
py
Python
augmentation/src/transformers/__init__.py
anonymous-nips2021/ASRGLUE
c532351ad90182aa095b1fce49b01c4e4fa9469b
[ "CC-BY-4.0" ]
null
null
null
augmentation/src/transformers/__init__.py
anonymous-nips2021/ASRGLUE
c532351ad90182aa095b1fce49b01c4e4fa9469b
[ "CC-BY-4.0" ]
null
null
null
augmentation/src/transformers/__init__.py
anonymous-nips2021/ASRGLUE
c532351ad90182aa095b1fce49b01c4e4fa9469b
[ "CC-BY-4.0" ]
null
null
null
from .tokenization_gpt2 import GPT2Tokenizer from .configuration_gpt2 import GPT2Config, GPT2_PRETRAINED_CONFIG_ARCHIVE_MAP from .modeling_gpt2 import (GPT2PreTrainedModel, GPT2Model, GPT2LMHeadModel, GPT2DoubleHeadsModel, #load_tf_weights_in_gpt2, GPT2_PRETRAINED_MODEL_ARCHIVE_MAP)
54.428571
78
0.666667
33
381
7.242424
0.636364
0.125523
0
0
0
0
0
0
0
0
0
0.045113
0.301837
381
6
79
63.5
0.853383
0.062992
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.6
0
0.6
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
ad2de18bda79ce848a0f8429a0ede6a3a571dc84
96
py
Python
files/database-delete.py
opus-codium/puppet-odoo
319cd1360a568e8272743ca67897fecc88147677
[ "Apache-2.0" ]
null
null
null
files/database-delete.py
opus-codium/puppet-odoo
319cd1360a568e8272743ca67897fecc88147677
[ "Apache-2.0" ]
9
2020-06-29T16:02:34.000Z
2021-12-02T17:46:58.000Z
files/database-delete.py
opus-codium/puppet-odoo
319cd1360a568e8272743ca67897fecc88147677
[ "Apache-2.0" ]
null
null
null
import os odoo.tools.config['list_db'] = True odoo.service.db.exp_drop(os.environ['PT_name'])
16
47
0.739583
17
96
4
0.823529
0
0
0
0
0
0
0
0
0
0
0
0.083333
96
5
48
19.2
0.772727
0
0
0
0
0
0.145833
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
ad75d83761645f2904d1c6663262c88f56f9a0fc
219
py
Python
tql/utils/reg_expr/__init__.py
Jie-Yuan/1_DataMining
f5338388b4f883233f350d4fb9c5903180883430
[ "Apache-2.0" ]
14
2019-06-25T13:46:32.000Z
2020-10-27T02:04:59.000Z
tql/utils/reg_expr/__init__.py
Jie-Yuan/2_DataMining
f5338388b4f883233f350d4fb9c5903180883430
[ "Apache-2.0" ]
null
null
null
tql/utils/reg_expr/__init__.py
Jie-Yuan/2_DataMining
f5338388b4f883233f350d4fb9c5903180883430
[ "Apache-2.0" ]
7
2019-06-25T13:26:16.000Z
2020-10-27T02:05:03.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- """ __title__ = '__init__.py' __author__ = 'JieYuan' __mtime__ = '19-1-2' """ import re chinese = re.compile('[\u4e00-\u9fa5]+') _chinese = re.compile('[^\u4e00-\u9fa5]+')
18.25
42
0.616438
28
219
4.214286
0.785714
0.152542
0.271186
0.355932
0.440678
0
0
0
0
0
0
0.078125
0.123288
219
11
43
19.909091
0.536458
0.511416
0
0
0
0
0.336735
0
0
0
0
0
0
1
0
false
0
0.333333
0
0.333333
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
0
0
0
1
0
0
0
0
4
ad916bf76d0d1704c2973cf6c838c2710af9a85e
518
py
Python
CeV - Gustavo Guanabara/exerc008.py
us19861229c/Meu-aprendizado-Python
575c0714ac5377ff3122f4cb57952969e07ba89b
[ "Unlicense" ]
1
2021-12-11T19:53:41.000Z
2021-12-11T19:53:41.000Z
CeV - Gustavo Guanabara/exerc008.py
us19861229c/Meu-aprendizado-Python
575c0714ac5377ff3122f4cb57952969e07ba89b
[ "Unlicense" ]
null
null
null
CeV - Gustavo Guanabara/exerc008.py
us19861229c/Meu-aprendizado-Python
575c0714ac5377ff3122f4cb57952969e07ba89b
[ "Unlicense" ]
null
null
null
#crie um programa que leia um valor (metro) e converta para centímetros (cm) e milimetro (mm) metro = float(input("Digite o valor em metros: ")) print(f"o valor em metros é {metro} m, sua correspondencia em centímetros é {metro * 100} cm, e sua correspondencia em milimetros é {metro * 1000} mm") print(f" TABELA DE KM HM DAM M DM CM MM \n>>> {metro / 1000} KM; \n>>> {metro / 100} HM;\n>>> {metro / 10} DAM;\n>>> {metro} M;" f"\n>>> {metro * 10:0f} DM;\n>>> {metro * 100:0f} CM;\n>>> {metro * 1000:.0f} MM")
57.555556
151
0.631274
92
518
3.554348
0.413043
0.12844
0.04893
0.085627
0
0
0
0
0
0
0
0.066667
0.189189
518
8
152
64.75
0.711905
0.177606
0
0
0
0.75
0.858491
0
0
0
0
0
0
1
0
false
0
0
0
0
0.5
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
0
0
0
1
0
4
a8e26dc7b3c13683a93f426f71a3264863710437
4,427
py
Python
pincer/objects/events/message.py
shivamdurgbuns/Pincer
aa27d6d65023ea62a2d0c09c1e9bc0fe4763e0c3
[ "MIT" ]
null
null
null
pincer/objects/events/message.py
shivamdurgbuns/Pincer
aa27d6d65023ea62a2d0c09c1e9bc0fe4763e0c3
[ "MIT" ]
null
null
null
pincer/objects/events/message.py
shivamdurgbuns/Pincer
aa27d6d65023ea62a2d0c09c1e9bc0fe4763e0c3
[ "MIT" ]
null
null
null
# Copyright Pincer 2021-Present # Full MIT License can be found in `LICENSE` at the project root. from __future__ import annotations from dataclasses import dataclass from typing import TYPE_CHECKING from ...utils.api_object import APIObject from ...utils.types import APINullable, MISSING if TYPE_CHECKING: from typing import List from ..message.emoji import Emoji from ..guild.member import GuildMember from ...utils.snowflake import Snowflake @dataclass(repr=False) class MessageDeleteEvent(APIObject): """Sent when a message is deleted. Attributes ---------- id: :class:`~pincer.utils.snowflake.Snowflake` The id of the message channel_id: :class:`~pincer.utils.snowflake.Snowflake` The id of the channel guild_id: APIObject[:class:`~pincer.utils.snowflake.Snowflake`] The id of the guild """ id: Snowflake channel_id: Snowflake guild_id: APINullable[Snowflake] = MISSING @dataclass(repr=False) class MessageDeleteBulkEvent(APIObject): """Sent when multiple messages are deleted at once. Attributes ---------- ids: List[:class:`~pincer.utils.snowflake.Snowflake`] The ids of the messages channel_id: :class:`~pincer.utils.snowflake.Snowflake` The id of the channel guild_id: APIObject[:class:`~pincer.utils.snowflake.Snowflake`] The id of the guild """ ids: List[Snowflake] channel_id: Snowflake guild_id: APINullable[Snowflake] = MISSING @dataclass(repr=False) class MessageReactionAddEvent(APIObject): """Sent when a user adds a reaction to a message. Attributes ---------- user_id: :class:`~pincer.utils.snowflake.Snowflake` The id of the user channel_id: :class:`~pincer.utils.snowflake.Snowflake` The id of the channel message_id: :class:`~pincer.utils.snowflake.Snowflake` The id of the message emoji: :class:`~pincer.objects.message.emoji.Emoji` The emoji used to react guild_id: APINullable[:class:`~pincer.utils.snowflake.Snowflake`] The id of the guild member: :class:`~pincer.objects.guild.member.GuildMember` The member who reacted if this happened in a guild """ user_id: Snowflake channel_id: Snowflake message_id: Snowflake emoji: Emoji guild_id: APINullable[Snowflake] = MISSING member: APINullable[GuildMember] = MISSING @dataclass(repr=False) class MessageReactionRemoveEvent(APIObject): """Sent when a user removes a reaction from a message. Attributes ---------- user_id: :class:`~pincer.utils.snowflake.Snowflake` The id of the user channel_id: :class:`~pincer.utils.snowflake.Snowflake` The id of the channel message_id: :class:`~pincer.utils.snowflake.Snowflake` The id of the message emoji: :class:`~pincer.objects.message.emoji.Emoji` The emoji used to react guild_id: APINullable[:class:`~pincer.utils.snowflake.Snowflake`] The id of the guild """ user_id: Snowflake channel_id: Snowflake message_id: Snowflake emoji: Emoji guild_id: APINullable[Snowflake] = MISSING @dataclass(repr=False) class MessageReactionRemoveAllEvent(APIObject): """Sent when a user explicitly removes all reactions from a message. Attributes ---------- channel_id: :class:`~pincer.utils.snowflake.Snowflake` The id of the channel message_id: :class:`~pincer.utils.snowflake.Snowflake` The id of the message guild_id: APINullable[:class:`~pincer.utils.snowflake.Snowflake`] The id of the guild """ channel_id: Snowflake message_id: Snowflake guild_id: APINullable[Snowflake] = MISSING @dataclass(repr=False) class MessageReactionRemoveEmojiEvent(APIObject): """Sent when a bot removes all instances of a given emoji from the reactions of a message. Attributes ---------- channel_id: :class:`~pincer.utils.snowflake.Snowflake` The id of the channel message_id: :class:`~pincer.utils.snowflake.Snowflake` The id of the message emoji: :class:`~pincer.objects.message.emoji.Emoji` The emoji that was removed guild_id: APINullable[:class:`~pincer.utils.snowflake.Snowflake`] The id of the guild """ channel_id: Snowflake message_id: Snowflake emoji: Emoji guild_id: APINullable[Snowflake] = MISSING
29.513333
72
0.690987
546
4,427
5.52381
0.152015
0.087533
0.106101
0.165782
0.693302
0.660809
0.648541
0.648541
0.648541
0.640915
0
0.00114
0.207138
4,427
149
73
29.711409
0.85812
0.581206
0
0.586957
0
0
0
0
0
0
0
0
0
1
0
true
0
0.195652
0
0.847826
0
0
0
0
null
0
0
1
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
1
0
0
4
d109c3a3fbb25bdd2502c36ed1cfbb061977675e
126
py
Python
wordgoal/__main__.py
cariad/wordgoal
46478f176e1947443107bc8eb2aa254b9c569d2d
[ "MIT" ]
null
null
null
wordgoal/__main__.py
cariad/wordgoal
46478f176e1947443107bc8eb2aa254b9c569d2d
[ "MIT" ]
4
2021-03-14T18:05:56.000Z
2021-03-16T14:41:32.000Z
wordgoal/__main__.py
cariad/wordgoal
46478f176e1947443107bc8eb2aa254b9c569d2d
[ "MIT" ]
null
null
null
from wordgoal.invoke import invoke def cli_entry() -> None: exit(invoke()) if __name__ == "__main__": cli_entry()
12.6
34
0.65873
16
126
4.5625
0.75
0.219178
0
0
0
0
0
0
0
0
0
0
0.206349
126
9
35
14
0.73
0
0
0
0
0
0.063492
0
0
0
0
0
0
1
0.2
true
0
0.2
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
1
0
0
0
0
0
0
4
d10aa6b94a1dc67f8165d868129d599201b6cacf
61
py
Python
cmsplugin_blog_to_multilingual_news/models.py
bitmazk/cmsplugin-blog-to-multilingual-news
d23ad209b540fbfce6b0bd55ad5194b1804ea38f
[ "MIT" ]
null
null
null
cmsplugin_blog_to_multilingual_news/models.py
bitmazk/cmsplugin-blog-to-multilingual-news
d23ad209b540fbfce6b0bd55ad5194b1804ea38f
[ "MIT" ]
null
null
null
cmsplugin_blog_to_multilingual_news/models.py
bitmazk/cmsplugin-blog-to-multilingual-news
d23ad209b540fbfce6b0bd55ad5194b1804ea38f
[ "MIT" ]
null
null
null
"""Just an empty models file. Nothing to see. Move along."""
30.5
60
0.688525
10
61
4.2
1
0
0
0
0
0
0
0
0
0
0
0
0.163934
61
1
61
61
0.823529
0.885246
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
d10de7cc86a7528237f942e31248fdc39ef9910d
57
py
Python
train.py
TropComplique/U-GAT-IT
ac8d896f545ce9805ab4c0727bff4bebf8936abf
[ "MIT" ]
2
2021-01-25T15:55:56.000Z
2021-04-19T11:44:55.000Z
train.py
TropComplique/U-GAT-IT
ac8d896f545ce9805ab4c0727bff4bebf8936abf
[ "MIT" ]
null
null
null
train.py
TropComplique/U-GAT-IT
ac8d896f545ce9805ab4c0727bff4bebf8936abf
[ "MIT" ]
1
2020-03-30T23:24:30.000Z
2020-03-30T23:24:30.000Z
from model import UGATIT model = UGATIT() model.train()
11.4
24
0.736842
8
57
5.25
0.625
0.52381
0
0
0
0
0
0
0
0
0
0
0.157895
57
4
25
14.25
0.875
0
0
0
0
0
0
0
0
0
0
0
0
1
0
false
0
0.333333
0
0.333333
0
1
0
0
null
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
d136ad381e0ef498517f49f90c959af5725dd463
230
py
Python
Python/Recursion/string_reverse.py
aquib-sh/DSA-C-PY
0cc9e874d5310762edd7b6c12dee07e351668c17
[ "CC0-1.0" ]
null
null
null
Python/Recursion/string_reverse.py
aquib-sh/DSA-C-PY
0cc9e874d5310762edd7b6c12dee07e351668c17
[ "CC0-1.0" ]
null
null
null
Python/Recursion/string_reverse.py
aquib-sh/DSA-C-PY
0cc9e874d5310762edd7b6c12dee07e351668c17
[ "CC0-1.0" ]
null
null
null
def reverse_string(string): if len(string) == 1: print(string) return reverse_string(string[1:]) print(string[0]) if __name__ == "__main__": string = input("String: ") reverse_string(string)
17.692308
30
0.608696
27
230
4.777778
0.444444
0.302326
0.44186
0.27907
0
0
0
0
0
0
0
0.017442
0.252174
230
12
31
19.166667
0.732558
0
0
0
0
0
0.069565
0
0
0
0
0
0
1
0.111111
false
0
0
0
0.222222
0.222222
1
0
0
null
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
d139bdf4ff02571934864d9743eb62c47247cbf4
5,795
py
Python
footnotes/import_parsers.py
uktrade/tamato
4ba2ffb25eea2887e4e081c81da7634cd7b4f9ca
[ "MIT" ]
14
2020-03-25T11:11:29.000Z
2022-03-08T20:41:33.000Z
footnotes/import_parsers.py
uktrade/tamato
4ba2ffb25eea2887e4e081c81da7634cd7b4f9ca
[ "MIT" ]
352
2020-03-25T10:42:09.000Z
2022-03-30T15:32:26.000Z
footnotes/import_parsers.py
uktrade/tamato
4ba2ffb25eea2887e4e081c81da7634cd7b4f9ca
[ "MIT" ]
3
2020-08-06T12:22:41.000Z
2022-01-16T11:51:12.000Z
import logging from importer.namespaces import Tag from importer.parsers import ConstantElement from importer.parsers import ElementParser from importer.parsers import IntElement from importer.parsers import TextElement from importer.parsers import ValidityMixin from importer.parsers import ValidityStartMixin from importer.parsers import Writable from importer.taric import RecordParser logger = logging.getLogger(__name__) @RecordParser.register_child("footnote_type") class FootnoteTypeParser(ValidityMixin, Writable, ElementParser): """ Example XML: .. code-block:: XML <xs:element name="footnote.type" substitutionGroup="abstract.record"> <xs:complexType> <xs:sequence> <xs:element name="footnote.type.id" type="FootnoteTypeId"/> <xs:element name="validity.start.date" type="Date"/> <xs:element name="validity.end.date" type="Date" minOccurs="0"/> <xs:element name="application.code" type="ApplicationCodeFootnote"/> </xs:sequence> </xs:complexType> </xs:element> """ record_code = "100" subrecord_code = "00" tag = Tag("footnote.type") footnote_type_id = TextElement(Tag("footnote.type.id")) valid_between_lower = ValidityMixin.valid_between_lower valid_between_upper = ValidityMixin.valid_between_upper application_code = TextElement(Tag("application.code")) @RecordParser.register_child("footnote_type_description") class FootnoteTypeDescriptionParser(Writable, ElementParser): """ Example XML: .. code-block:: XML <xs:element name="footnote.type.description" substitutionGroup="abstract.record"> <xs:complexType> <xs:sequence> <xs:element name="footnote.type.id" type="FootnoteTypeId"/> <xs:element name="language.id" type="LanguageId"/> <xs:element name="description" type="ShortDescription" minOccurs="0"/> </xs:sequence> </xs:complexType> </xs:element> """ record_code = "100" subrecord_code = "05" tag = Tag("footnote.type.description") footnote_type_id = TextElement(Tag("footnote.type.id")) language_id = ConstantElement(Tag("language.id"), value="EN") description = TextElement(Tag("description")) @RecordParser.register_child("footnote") class FootnoteParser(ValidityMixin, Writable, ElementParser): """ Example XML: .. code-block:: XML <xs:element name="footnote" substitutionGroup="abstract.record"> <xs:complexType> <xs:sequence> <xs:element name="footnote.type.id" type="FootnoteTypeId"/> <xs:element name="footnote.id" type="FootnoteId"/> <xs:element name="validity.start.date" type="Date"/> <xs:element name="validity.end.date" type="Date" minOccurs="0"/> </xs:sequence> </xs:complexType> </xs:element> """ record_code = "200" subrecord_code = "00" tag = Tag("footnote") footnote_type__footnote_type_id = TextElement(Tag("footnote.type.id")) footnote_id = TextElement(Tag("footnote.id")) valid_between_lower = ValidityMixin.valid_between_lower valid_between_upper = ValidityMixin.valid_between_upper @RecordParser.register_child("footnote_description") class FootnoteDescriptionParser(Writable, ElementParser): """ Example XML: .. code-block:: XML <xs:element name="footnote.description" substitutionGroup="abstract.record"> <xs:complexType> <xs:sequence> <xs:element name="footnote.description.period.sid" type="SID"/> <xs:element name="language.id" type="LanguageId"/> <xs:element name="footnote.type.id" type="FootnoteTypeId"/> <xs:element name="footnote.id" type="FootnoteId"/> <xs:element name="description" type="LongDescription" minOccurs="0"/> </xs:sequence> </xs:complexType> </xs:element> """ record_code = "200" subrecord_code = "10" tag = Tag("footnote.description") sid = IntElement(Tag("footnote.description.period.sid")) language_id = ConstantElement(Tag("language.id"), value="EN") described_footnote__footnote_type__footnote_type_id = TextElement( Tag("footnote.type.id"), ) described_footnote__footnote_id = TextElement(Tag("footnote.id")) description = TextElement(Tag("description")) @RecordParser.register_child("footnote_description_period") class FootnoteDescriptionPeriodParser(ValidityStartMixin, Writable, ElementParser): """ Example XML: .. code-block:: XML <xs:element name="footnote.description.period" substitutionGroup="abstract.record"> <xs:complexType> <xs:sequence> <xs:element name="footnote.description.period.sid" type="SID"/> <xs:element name="footnote.type.id" type="FootnoteTypeId"/> <xs:element name="footnote.id" type="FootnoteId"/> <xs:element name="validity.start.date" type="Date"/> </xs:sequence> </xs:complexType> </xs:element> """ record_code = "200" subrecord_code = "05" tag = Tag("footnote.description.period") sid = IntElement(Tag("footnote.description.period.sid")) described_footnote__footnote_type__footnote_type_id = TextElement( Tag("footnote.type.id"), ) described_footnote__footnote_id = TextElement(Tag("footnote.id")) validity_start = ValidityStartMixin.validity_start
34.494048
91
0.641242
576
5,795
6.3125
0.123264
0.074257
0.089384
0.086634
0.791254
0.742849
0.719197
0.694995
0.620737
0.620737
0
0.006532
0.233822
5,795
167
92
34.700599
0.812387
0.463158
0
0.45
0
0
0.159858
0.05897
0
0
0
0
0
1
0
false
0
0.166667
0
0.833333
0
0
0
0
null
0
0
0
0
1
1
0
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
1
0
0
4
0f287ecf81ea293ead9702e32eaa6f141f046740
93
py
Python
importers/apps.py
GROCCAD/groccad
1d461043030bebe277d74b1c9df9877436baa270
[ "MIT" ]
1
2022-03-05T03:11:51.000Z
2022-03-05T03:11:51.000Z
importers/apps.py
rocdata/rocserver
1d461043030bebe277d74b1c9df9877436baa270
[ "MIT" ]
null
null
null
importers/apps.py
rocdata/rocserver
1d461043030bebe277d74b1c9df9877436baa270
[ "MIT" ]
null
null
null
from django.apps import AppConfig class ImportersConfig(AppConfig): name = 'importers'
15.5
33
0.763441
10
93
7.1
0.9
0
0
0
0
0
0
0
0
0
0
0
0.16129
93
5
34
18.6
0.910256
0
0
0
0
0
0.096774
0
0
0
0
0
0
1
0
false
0
1
0
1.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
0f3fb8ffc868788771b982db84884d2977f444e4
186
py
Python
tests/test_application.py
gselzer/magicgui
0ac480957a96cfe1d0e689b56830cc95cddef0f9
[ "MIT" ]
185
2020-02-20T21:28:03.000Z
2022-03-30T22:42:28.000Z
tests/test_application.py
gselzer/magicgui
0ac480957a96cfe1d0e689b56830cc95cddef0f9
[ "MIT" ]
356
2020-02-19T02:16:28.000Z
2022-03-30T18:14:47.000Z
tests/test_application.py
gselzer/magicgui
0ac480957a96cfe1d0e689b56830cc95cddef0f9
[ "MIT" ]
32
2020-02-19T23:05:44.000Z
2022-03-05T18:46:41.000Z
from magicgui import use_app from magicgui.application import APPLICATION_NAME def test_app_name(): app = use_app("qt") assert app.native.applicationName() == APPLICATION_NAME
23.25
59
0.774194
25
186
5.52
0.52
0.173913
0
0
0
0
0
0
0
0
0
0
0.145161
186
7
60
26.571429
0.867925
0
0
0
0
0
0.010753
0
0
0
0
0
0.2
1
0.2
false
0
0.4
0
0.6
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
7e2e207267e91a45bd2997cabd95b973fe71fb11
69
py
Python
Benchmarks/benchmark/__init__.py
Vulthil/Logprocessor
b0611254e6e6a5739e0a14e4e1785ec5dfbef56c
[ "MIT" ]
null
null
null
Benchmarks/benchmark/__init__.py
Vulthil/Logprocessor
b0611254e6e6a5739e0a14e4e1785ec5dfbef56c
[ "MIT" ]
null
null
null
Benchmarks/benchmark/__init__.py
Vulthil/Logprocessor
b0611254e6e6a5739e0a14e4e1785ec5dfbef56c
[ "MIT" ]
null
null
null
from sessionMessageBenchmark import main from config import getArgs
17.25
40
0.869565
8
69
7.5
0.75
0
0
0
0
0
0
0
0
0
0
0
0.130435
69
3
41
23
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
4
7e43935e7df53417719749ef4444d0201a0404ee
694
py
Python
src/sellix/resources/blacklist.py
Sellix/python-sdk
dbfd203c73d9aa7e91eb4ce25a9ab0eb8ea7dc69
[ "MIT" ]
null
null
null
src/sellix/resources/blacklist.py
Sellix/python-sdk
dbfd203c73d9aa7e91eb4ce25a9ab0eb8ea7dc69
[ "MIT" ]
null
null
null
src/sellix/resources/blacklist.py
Sellix/python-sdk
dbfd203c73d9aa7e91eb4ce25a9ab0eb8ea7dc69
[ "MIT" ]
null
null
null
def get_blacklists(self): return self.handle_response( self.request("/blacklists"), "blacklists" ) def create_blacklist(self, **kwargs): return self.handle_response( self.request("/blacklists", "POST", kwargs), "uniqid" ) def get_blacklist(self, uniqid): return self.handle_response( self.request(f"/blacklists/{uniqid}"), "blacklist" ) def update_blacklist(self, uniqid, **kwargs): return self.handle_response( self.request(f"/blacklists/{uniqid}", "PUT", kwargs) ) def delete_blacklist(self, uniqid): return self.handle_response( self.request(f"/blacklists/{uniqid}", "DELETE") )
21.6875
60
0.635447
74
694
5.824324
0.22973
0.116009
0.185615
0.278422
0.686775
0.686775
0.686775
0.450116
0.450116
0.329466
0
0
0.223343
694
31
61
22.387097
0.799629
0
0
0.217391
0
0
0.172911
0
0
0
0
0
0
1
0.217391
false
0
0
0.217391
0.434783
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
1
0
0
0
1
0
0
0
4
7e5a18d597a5816941d84a42f85c07169d8832ba
248
py
Python
src/ZEO/asyncio/compat.py
azmeuk/ZEO
8de475763467b054d87ad310f1696cc713db9135
[ "ZPL-2.1" ]
40
2015-11-26T18:40:29.000Z
2022-03-15T06:45:43.000Z
src/ZEO/asyncio/compat.py
azmeuk/ZEO
8de475763467b054d87ad310f1696cc713db9135
[ "ZPL-2.1" ]
138
2015-01-05T16:05:09.000Z
2022-03-31T14:02:40.000Z
src/ZEO/asyncio/compat.py
azmeuk/ZEO
8de475763467b054d87ad310f1696cc713db9135
[ "ZPL-2.1" ]
24
2015-04-03T07:05:13.000Z
2021-12-24T06:10:54.000Z
from .._compat import PY3 if PY3: import asyncio try: from uvloop import new_event_loop except ImportError: from asyncio import new_event_loop else: import trollius as asyncio from trollius import new_event_loop
22.545455
42
0.717742
34
248
5.029412
0.470588
0.157895
0.245614
0.315789
0
0
0
0
0
0
0
0.01087
0.258065
248
10
43
24.8
0.918478
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.7
0
0.7
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
7e5dc1601337de2d51e4d5e1cd9568ed2103caa5
274
py
Python
tests/training_tests/test_training.py
buypolarbear/ChatterBot
ebfd4be9a7a4402fbbce2399af7758c347e2f567
[ "BSD-3-Clause" ]
9
2021-08-08T22:42:55.000Z
2021-11-23T06:50:30.000Z
tests/training_tests/test_training.py
jungle-cat/ChatterBot
ebfd4be9a7a4402fbbce2399af7758c347e2f567
[ "BSD-3-Clause" ]
1
2020-04-27T00:53:53.000Z
2020-04-27T00:53:53.000Z
tests/training_tests/test_training.py
jungle-cat/ChatterBot
ebfd4be9a7a4402fbbce2399af7758c347e2f567
[ "BSD-3-Clause" ]
7
2018-01-04T10:02:11.000Z
2019-06-18T14:24:04.000Z
from tests.base_case import ChatBotTestCase from chatterbot.trainers import ListTrainer class TrainingTests(ChatBotTestCase): def test_trainer_not_set(self): with self.assertRaises(ListTrainer.TrainerInitializationException): self.chatbot.train()
27.4
75
0.784672
28
274
7.535714
0.785714
0
0
0
0
0
0
0
0
0
0
0
0.153285
274
9
76
30.444444
0.909483
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
7e94d948fe7168903e35c67d88d2fd3448e228df
742
py
Python
ticketshop/tests/e2e/test_1ticket.py
gdetrez/fscons-ticketshop
a237339748dfdcef1b1b6e84cfc3342ce2dea8cd
[ "MIT" ]
null
null
null
ticketshop/tests/e2e/test_1ticket.py
gdetrez/fscons-ticketshop
a237339748dfdcef1b1b6e84cfc3342ce2dea8cd
[ "MIT" ]
null
null
null
ticketshop/tests/e2e/test_1ticket.py
gdetrez/fscons-ticketshop
a237339748dfdcef1b1b6e84cfc3342ce2dea8cd
[ "MIT" ]
null
null
null
from django.test import LiveServerTestCase from selenium.webdriver.firefox.webdriver import WebDriver from time import sleep class E2ETests(LiveServerTestCase): pass # @classmethod # def setUpClass(cls): # cls.selenium = WebDriver() # super(E2ETests, cls).setUpClass() # # @classmethod # def tearDownClass(cls): # super(E2ETests, cls).tearDownClass() # cls.selenium.quit() # # def test_abc(self): # self.selenium.get(self.live_server_url + '/') # self.selenium.find_element_by_id('id_name').send_keys('Bruce Wayne') # self.selenium.find_element_by_id('id_email').send_keys('bruce@wayne.com') # self.selenium.find_element_by_id('checkout').click() # sleep(2)
30.916667
82
0.680593
88
742
5.556818
0.454545
0.09816
0.09816
0.141104
0.173824
0.173824
0.118609
0
0
0
0
0.006634
0.187332
742
23
83
32.26087
0.804312
0.719677
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0.2
0.6
0
0.8
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
1
1
0
1
0
0
4
0e3468688aba4c0efbb39ae2d3907fe5927da265
314
py
Python
Ex_Python/Exercicios-Tuplas/num_aleatorio_Tuplas.py
Matheus-Soares2003/Python
7495d70f14650ce058085426da01418c706f15c7
[ "MIT" ]
null
null
null
Ex_Python/Exercicios-Tuplas/num_aleatorio_Tuplas.py
Matheus-Soares2003/Python
7495d70f14650ce058085426da01418c706f15c7
[ "MIT" ]
null
null
null
Ex_Python/Exercicios-Tuplas/num_aleatorio_Tuplas.py
Matheus-Soares2003/Python
7495d70f14650ce058085426da01418c706f15c7
[ "MIT" ]
null
null
null
from random import randint numeros = (randint(0, 10), randint(0, 10), randint(0, 10), randint(0, 10), randint(0, 10)) print(f'OS valores sorteados foram: {numeros}') print(f'O maior valor é {sorted(numeros)[len(numeros) - 1]}!') print(f'O menor valor é {sorted(numeros)[0]}!') sair = input("ENTER para sair... ")
39.25
90
0.675159
52
314
4.076923
0.480769
0.188679
0.235849
0.320755
0.235849
0.235849
0.235849
0.235849
0.235849
0.235849
0
0.062044
0.127389
314
7
91
44.857143
0.711679
0
0
0
0
0
0.461783
0.159236
0
0
0
0
0
1
0
false
0
0.166667
0
0.166667
0.5
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
0
1
0
4
0e39f5d7544fe703cd3a1fa8c73bd0506fa14850
72
py
Python
Design Scripts/EX.py
JY-Xie/Road-design-
91c6be84f029ab5a24ccbc5211621a71c40c69d7
[ "Apache-2.0" ]
null
null
null
Design Scripts/EX.py
JY-Xie/Road-design-
91c6be84f029ab5a24ccbc5211621a71c40c69d7
[ "Apache-2.0" ]
null
null
null
Design Scripts/EX.py
JY-Xie/Road-design-
91c6be84f029ab5a24ccbc5211621a71c40c69d7
[ "Apache-2.0" ]
null
null
null
for i in range(140, 1001, 20): b = 'K5+' + str(i) + '.00' print(b)
18
31
0.486111
14
72
2.5
0.857143
0
0
0
0
0
0
0
0
0
0
0.226415
0.263889
72
3
32
24
0.433962
0
0
0
0
0
0.086957
0
0
0
0
0
0
1
0
false
0
0
0
0
0.333333
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
0e5d4dd2d6e5108efb49d0a29d63958df84769e6
75
py
Python
test_hello.py
aasolmaz/pynet_testz
5c07d737d070adbea8b9930d1594cd5f7c924551
[ "Apache-2.0" ]
null
null
null
test_hello.py
aasolmaz/pynet_testz
5c07d737d070adbea8b9930d1594cd5f7c924551
[ "Apache-2.0" ]
null
null
null
test_hello.py
aasolmaz/pynet_testz
5c07d737d070adbea8b9930d1594cd5f7c924551
[ "Apache-2.0" ]
null
null
null
print "Hello All" print "Something more" for i in range(10): print i
15
22
0.666667
13
75
3.846154
0.769231
0
0
0
0
0
0
0
0
0
0
0.035088
0.24
75
4
23
18.75
0.842105
0
0
0
0
0
0.306667
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
0e6b239925e1ed11ee7d688612691b7b3d1b86c2
19,699
py
Python
jets/compiler/JetRuleLexer.py
artisoft-io/jetstore
84f8b5d82bbc8fa309571c431a7674ef3ff0e9c2
[ "Apache-2.0" ]
null
null
null
jets/compiler/JetRuleLexer.py
artisoft-io/jetstore
84f8b5d82bbc8fa309571c431a7674ef3ff0e9c2
[ "Apache-2.0" ]
61
2021-12-29T15:02:53.000Z
2022-03-31T14:53:40.000Z
jets/compiler/JetRuleLexer.py
artisoft-io/jetstore
84f8b5d82bbc8fa309571c431a7674ef3ff0e9c2
[ "Apache-2.0" ]
null
null
null
# Generated from JetRule.g4 by ANTLR 4.10.1 from antlr4 import * from io import StringIO import sys if sys.version_info[1] > 5: from typing import TextIO else: from typing.io import TextIO def serializedATN(): return [ 4,0,66,586,6,-1,2,0,7,0,2,1,7,1,2,2,7,2,2,3,7,3,2,4,7,4,2,5,7,5, 2,6,7,6,2,7,7,7,2,8,7,8,2,9,7,9,2,10,7,10,2,11,7,11,2,12,7,12,2, 13,7,13,2,14,7,14,2,15,7,15,2,16,7,16,2,17,7,17,2,18,7,18,2,19,7, 19,2,20,7,20,2,21,7,21,2,22,7,22,2,23,7,23,2,24,7,24,2,25,7,25,2, 26,7,26,2,27,7,27,2,28,7,28,2,29,7,29,2,30,7,30,2,31,7,31,2,32,7, 32,2,33,7,33,2,34,7,34,2,35,7,35,2,36,7,36,2,37,7,37,2,38,7,38,2, 39,7,39,2,40,7,40,2,41,7,41,2,42,7,42,2,43,7,43,2,44,7,44,2,45,7, 45,2,46,7,46,2,47,7,47,2,48,7,48,2,49,7,49,2,50,7,50,2,51,7,51,2, 52,7,52,2,53,7,53,2,54,7,54,2,55,7,55,2,56,7,56,2,57,7,57,2,58,7, 58,2,59,7,59,2,60,7,60,2,61,7,61,2,62,7,62,2,63,7,63,2,64,7,64,2, 65,7,65,2,66,7,66,2,67,7,67,2,68,7,68,1,0,1,0,1,1,1,1,1,2,1,2,1, 3,1,3,1,4,1,4,1,5,1,5,1,5,1,6,1,6,1,7,1,7,1,8,1,8,1,8,1,9,1,9,1, 10,1,10,1,11,1,11,1,12,1,12,1,12,1,12,1,12,1,12,1,12,1,12,1,12,1, 12,1,12,1,12,1,12,1,12,1,12,1,12,1,12,1,12,1,12,1,12,1,12,1,12,1, 13,1,13,1,13,1,13,1,13,1,13,1,14,1,14,1,14,1,14,1,14,1,14,1,14,1, 14,1,14,1,14,1,14,1,14,1,14,1,14,1,15,1,15,1,15,1,15,1,15,1,15,1, 15,1,15,1,15,1,15,1,16,1,16,1,16,1,16,1,16,1,16,1,16,1,16,1,16,1, 16,1,16,1,16,1,16,1,16,1,16,1,16,1,16,1,17,1,17,1,17,1,17,1,17,1, 17,1,17,1,17,1,17,1,18,1,18,1,18,1,18,1,18,1,18,1,18,1,18,1,18,1, 18,1,18,1,18,1,18,1,18,1,18,1,18,1,19,1,19,1,19,1,19,1,19,1,19,1, 19,1,19,1,19,1,19,1,19,1,19,1,19,1,20,1,20,1,20,1,20,1,20,1,20,1, 20,1,20,1,20,1,20,1,20,1,20,1,20,1,20,1,20,1,21,1,21,1,21,1,21,1, 21,1,21,1,21,1,21,1,21,1,21,1,21,1,21,1,21,1,21,1,22,1,22,1,22,1, 22,1,22,1,22,1,22,1,22,1,22,1,22,1,22,1,22,1,22,1,22,1,22,1,22,1, 23,1,23,1,23,1,23,1,23,1,23,1,23,1,24,1,24,1,24,1,24,1,25,1,25,1, 25,1,25,1,25,1,26,1,26,1,26,1,26,1,26,1,27,1,27,1,27,1,27,1,27,1, 27,1,28,1,28,1,28,1,28,1,28,1,28,1,28,1,29,1,29,1,29,1,29,1,29,1, 30,1,30,1,30,1,30,1,30,1,31,1,31,1,31,1,31,1,31,1,31,1,31,1,31,1, 31,1,32,1,32,1,32,1,32,1,32,1,33,1,33,1,33,1,33,1,33,1,33,1,33,1, 33,1,33,1,34,1,34,1,34,1,34,1,34,1,34,1,34,1,34,1,34,1,34,1,34,1, 34,1,34,1,34,1,34,1,34,1,34,1,34,1,35,1,35,1,35,1,35,1,35,1,35,1, 35,1,35,1,35,1,35,1,35,1,35,1,35,1,35,1,35,1,35,1,35,1,35,1,35,1, 35,1,35,1,35,1,35,1,36,1,36,1,36,1,36,1,36,1,36,1,36,1,36,1,36,1, 36,1,36,1,36,1,36,1,37,1,37,1,37,1,37,1,37,1,37,1,37,1,37,1,37,1, 37,1,37,1,37,1,38,1,38,1,38,1,38,1,38,1,38,1,38,1,38,1,38,1,38,1, 39,1,39,1,39,1,39,1,39,1,40,1,40,1,40,1,40,1,40,1,40,1,40,1,40,1, 40,1,41,1,41,1,41,1,41,1,41,1,42,1,42,1,42,1,42,1,42,1,42,1,43,1, 43,1,43,1,43,1,43,1,44,1,44,1,44,1,44,1,45,1,45,1,45,1,45,1,45,1, 45,1,45,1,46,1,46,1,46,1,47,1,47,1,48,1,48,1,48,1,49,1,49,1,50,1, 50,1,50,1,51,1,51,1,51,1,52,1,52,1,52,1,53,1,53,1,54,1,54,1,55,1, 55,1,56,1,56,1,57,1,57,1,57,1,58,1,58,1,58,1,58,1,59,1,59,1,60,1, 60,1,61,1,61,1,61,5,61,543,8,61,10,61,12,61,546,9,61,1,62,1,62,1, 63,4,63,551,8,63,11,63,12,63,552,1,64,1,64,1,64,5,64,558,8,64,10, 64,12,64,561,9,64,1,64,1,64,1,65,1,65,1,65,1,65,3,65,569,8,65,1, 66,1,66,5,66,573,8,66,10,66,12,66,576,9,66,1,67,1,67,1,68,4,68,581, 8,68,11,68,12,68,582,1,68,1,68,1,559,0,69,1,1,3,2,5,3,7,4,9,5,11, 6,13,7,15,8,17,9,19,10,21,11,23,12,25,13,27,14,29,15,31,16,33,17, 35,18,37,19,39,20,41,21,43,22,45,23,47,24,49,25,51,26,53,27,55,28, 57,29,59,30,61,31,63,32,65,33,67,34,69,35,71,36,73,37,75,38,77,39, 79,40,81,41,83,42,85,43,87,44,89,45,91,46,93,47,95,48,97,49,99,50, 101,51,103,52,105,53,107,54,109,55,111,56,113,57,115,58,117,59,119, 60,121,61,123,62,125,0,127,63,129,64,131,0,133,65,135,0,137,66,1, 0,4,3,0,65,90,95,95,97,122,1,0,48,57,2,0,10,10,13,13,3,0,9,10,13, 13,32,32,590,0,1,1,0,0,0,0,3,1,0,0,0,0,5,1,0,0,0,0,7,1,0,0,0,0,9, 1,0,0,0,0,11,1,0,0,0,0,13,1,0,0,0,0,15,1,0,0,0,0,17,1,0,0,0,0,19, 1,0,0,0,0,21,1,0,0,0,0,23,1,0,0,0,0,25,1,0,0,0,0,27,1,0,0,0,0,29, 1,0,0,0,0,31,1,0,0,0,0,33,1,0,0,0,0,35,1,0,0,0,0,37,1,0,0,0,0,39, 1,0,0,0,0,41,1,0,0,0,0,43,1,0,0,0,0,45,1,0,0,0,0,47,1,0,0,0,0,49, 1,0,0,0,0,51,1,0,0,0,0,53,1,0,0,0,0,55,1,0,0,0,0,57,1,0,0,0,0,59, 1,0,0,0,0,61,1,0,0,0,0,63,1,0,0,0,0,65,1,0,0,0,0,67,1,0,0,0,0,69, 1,0,0,0,0,71,1,0,0,0,0,73,1,0,0,0,0,75,1,0,0,0,0,77,1,0,0,0,0,79, 1,0,0,0,0,81,1,0,0,0,0,83,1,0,0,0,0,85,1,0,0,0,0,87,1,0,0,0,0,89, 1,0,0,0,0,91,1,0,0,0,0,93,1,0,0,0,0,95,1,0,0,0,0,97,1,0,0,0,0,99, 1,0,0,0,0,101,1,0,0,0,0,103,1,0,0,0,0,105,1,0,0,0,0,107,1,0,0,0, 0,109,1,0,0,0,0,111,1,0,0,0,0,113,1,0,0,0,0,115,1,0,0,0,0,117,1, 0,0,0,0,119,1,0,0,0,0,121,1,0,0,0,0,123,1,0,0,0,0,127,1,0,0,0,0, 129,1,0,0,0,0,133,1,0,0,0,0,137,1,0,0,0,1,139,1,0,0,0,3,141,1,0, 0,0,5,143,1,0,0,0,7,145,1,0,0,0,9,147,1,0,0,0,11,149,1,0,0,0,13, 152,1,0,0,0,15,154,1,0,0,0,17,156,1,0,0,0,19,159,1,0,0,0,21,161, 1,0,0,0,23,163,1,0,0,0,25,165,1,0,0,0,27,187,1,0,0,0,29,193,1,0, 0,0,31,207,1,0,0,0,33,217,1,0,0,0,35,234,1,0,0,0,37,243,1,0,0,0, 39,259,1,0,0,0,41,272,1,0,0,0,43,287,1,0,0,0,45,301,1,0,0,0,47,317, 1,0,0,0,49,324,1,0,0,0,51,328,1,0,0,0,53,333,1,0,0,0,55,338,1,0, 0,0,57,344,1,0,0,0,59,351,1,0,0,0,61,356,1,0,0,0,63,361,1,0,0,0, 65,370,1,0,0,0,67,375,1,0,0,0,69,384,1,0,0,0,71,402,1,0,0,0,73,425, 1,0,0,0,75,438,1,0,0,0,77,450,1,0,0,0,79,460,1,0,0,0,81,465,1,0, 0,0,83,474,1,0,0,0,85,479,1,0,0,0,87,485,1,0,0,0,89,490,1,0,0,0, 91,494,1,0,0,0,93,501,1,0,0,0,95,504,1,0,0,0,97,506,1,0,0,0,99,509, 1,0,0,0,101,511,1,0,0,0,103,514,1,0,0,0,105,517,1,0,0,0,107,520, 1,0,0,0,109,522,1,0,0,0,111,524,1,0,0,0,113,526,1,0,0,0,115,528, 1,0,0,0,117,531,1,0,0,0,119,535,1,0,0,0,121,537,1,0,0,0,123,539, 1,0,0,0,125,547,1,0,0,0,127,550,1,0,0,0,129,554,1,0,0,0,131,568, 1,0,0,0,133,570,1,0,0,0,135,577,1,0,0,0,137,580,1,0,0,0,139,140, 5,123,0,0,140,2,1,0,0,0,141,142,5,125,0,0,142,4,1,0,0,0,143,144, 5,44,0,0,144,6,1,0,0,0,145,146,5,91,0,0,146,8,1,0,0,0,147,148,5, 93,0,0,148,10,1,0,0,0,149,150,5,97,0,0,150,151,5,115,0,0,151,12, 1,0,0,0,152,153,5,46,0,0,153,14,1,0,0,0,154,155,5,58,0,0,155,16, 1,0,0,0,156,157,5,45,0,0,157,158,5,62,0,0,158,18,1,0,0,0,159,160, 5,40,0,0,160,20,1,0,0,0,161,162,5,41,0,0,162,22,1,0,0,0,163,164, 5,63,0,0,164,24,1,0,0,0,165,166,5,64,0,0,166,167,5,74,0,0,167,168, 5,101,0,0,168,169,5,116,0,0,169,170,5,67,0,0,170,171,5,111,0,0,171, 172,5,109,0,0,172,173,5,112,0,0,173,174,5,105,0,0,174,175,5,108, 0,0,175,176,5,101,0,0,176,177,5,114,0,0,177,178,5,68,0,0,178,179, 5,105,0,0,179,180,5,114,0,0,180,181,5,101,0,0,181,182,5,99,0,0,182, 183,5,116,0,0,183,184,5,105,0,0,184,185,5,118,0,0,185,186,5,101, 0,0,186,26,1,0,0,0,187,188,5,99,0,0,188,189,5,108,0,0,189,190,5, 97,0,0,190,191,5,115,0,0,191,192,5,115,0,0,192,28,1,0,0,0,193,194, 5,36,0,0,194,195,5,98,0,0,195,196,5,97,0,0,196,197,5,115,0,0,197, 198,5,101,0,0,198,199,5,95,0,0,199,200,5,99,0,0,200,201,5,108,0, 0,201,202,5,97,0,0,202,203,5,115,0,0,203,204,5,115,0,0,204,205,5, 101,0,0,205,206,5,115,0,0,206,30,1,0,0,0,207,208,5,36,0,0,208,209, 5,97,0,0,209,210,5,115,0,0,210,211,5,95,0,0,211,212,5,116,0,0,212, 213,5,97,0,0,213,214,5,98,0,0,214,215,5,108,0,0,215,216,5,101,0, 0,216,32,1,0,0,0,217,218,5,36,0,0,218,219,5,100,0,0,219,220,5,97, 0,0,220,221,5,116,0,0,221,222,5,97,0,0,222,223,5,95,0,0,223,224, 5,112,0,0,224,225,5,114,0,0,225,226,5,111,0,0,226,227,5,112,0,0, 227,228,5,101,0,0,228,229,5,114,0,0,229,230,5,116,0,0,230,231,5, 105,0,0,231,232,5,101,0,0,232,233,5,115,0,0,233,34,1,0,0,0,234,235, 5,97,0,0,235,236,5,114,0,0,236,237,5,114,0,0,237,238,5,97,0,0,238, 239,5,121,0,0,239,240,5,32,0,0,240,241,5,111,0,0,241,242,5,102,0, 0,242,36,1,0,0,0,243,244,5,106,0,0,244,245,5,101,0,0,245,246,5,116, 0,0,246,247,5,115,0,0,247,248,5,116,0,0,248,249,5,111,0,0,249,250, 5,114,0,0,250,251,5,101,0,0,251,252,5,95,0,0,252,253,5,99,0,0,253, 254,5,111,0,0,254,255,5,110,0,0,255,256,5,102,0,0,256,257,5,105, 0,0,257,258,5,103,0,0,258,38,1,0,0,0,259,260,5,36,0,0,260,261,5, 109,0,0,261,262,5,97,0,0,262,263,5,120,0,0,263,264,5,95,0,0,264, 265,5,108,0,0,265,266,5,111,0,0,266,267,5,111,0,0,267,268,5,112, 0,0,268,269,5,105,0,0,269,270,5,110,0,0,270,271,5,103,0,0,271,40, 1,0,0,0,272,273,5,36,0,0,273,274,5,109,0,0,274,275,5,97,0,0,275, 276,5,120,0,0,276,277,5,95,0,0,277,278,5,114,0,0,278,279,5,117,0, 0,279,280,5,108,0,0,280,281,5,101,0,0,281,282,5,95,0,0,282,283,5, 101,0,0,283,284,5,120,0,0,284,285,5,101,0,0,285,286,5,99,0,0,286, 42,1,0,0,0,287,288,5,114,0,0,288,289,5,117,0,0,289,290,5,108,0,0, 290,291,5,101,0,0,291,292,5,95,0,0,292,293,5,115,0,0,293,294,5,101, 0,0,294,295,5,113,0,0,295,296,5,117,0,0,296,297,5,101,0,0,297,298, 5,110,0,0,298,299,5,99,0,0,299,300,5,101,0,0,300,44,1,0,0,0,301, 302,5,36,0,0,302,303,5,109,0,0,303,304,5,97,0,0,304,305,5,105,0, 0,305,306,5,110,0,0,306,307,5,95,0,0,307,308,5,114,0,0,308,309,5, 117,0,0,309,310,5,108,0,0,310,311,5,101,0,0,311,312,5,95,0,0,312, 313,5,115,0,0,313,314,5,101,0,0,314,315,5,116,0,0,315,316,5,115, 0,0,316,46,1,0,0,0,317,318,5,116,0,0,318,319,5,114,0,0,319,320,5, 105,0,0,320,321,5,112,0,0,321,322,5,108,0,0,322,323,5,101,0,0,323, 48,1,0,0,0,324,325,5,105,0,0,325,326,5,110,0,0,326,327,5,116,0,0, 327,50,1,0,0,0,328,329,5,117,0,0,329,330,5,105,0,0,330,331,5,110, 0,0,331,332,5,116,0,0,332,52,1,0,0,0,333,334,5,108,0,0,334,335,5, 111,0,0,335,336,5,110,0,0,336,337,5,103,0,0,337,54,1,0,0,0,338,339, 5,117,0,0,339,340,5,108,0,0,340,341,5,111,0,0,341,342,5,110,0,0, 342,343,5,103,0,0,343,56,1,0,0,0,344,345,5,100,0,0,345,346,5,111, 0,0,346,347,5,117,0,0,347,348,5,98,0,0,348,349,5,108,0,0,349,350, 5,101,0,0,350,58,1,0,0,0,351,352,5,116,0,0,352,353,5,101,0,0,353, 354,5,120,0,0,354,355,5,116,0,0,355,60,1,0,0,0,356,357,5,100,0,0, 357,358,5,97,0,0,358,359,5,116,0,0,359,360,5,101,0,0,360,62,1,0, 0,0,361,362,5,100,0,0,362,363,5,97,0,0,363,364,5,116,0,0,364,365, 5,101,0,0,365,366,5,116,0,0,366,367,5,105,0,0,367,368,5,109,0,0, 368,369,5,101,0,0,369,64,1,0,0,0,370,371,5,98,0,0,371,372,5,111, 0,0,372,373,5,111,0,0,373,374,5,108,0,0,374,66,1,0,0,0,375,376,5, 114,0,0,376,377,5,101,0,0,377,378,5,115,0,0,378,379,5,111,0,0,379, 380,5,117,0,0,380,381,5,114,0,0,381,382,5,99,0,0,382,383,5,101,0, 0,383,68,1,0,0,0,384,385,5,118,0,0,385,386,5,111,0,0,386,387,5,108, 0,0,387,388,5,97,0,0,388,389,5,116,0,0,389,390,5,105,0,0,390,391, 5,108,0,0,391,392,5,101,0,0,392,393,5,95,0,0,393,394,5,114,0,0,394, 395,5,101,0,0,395,396,5,115,0,0,396,397,5,111,0,0,397,398,5,117, 0,0,398,399,5,114,0,0,399,400,5,99,0,0,400,401,5,101,0,0,401,70, 1,0,0,0,402,403,5,99,0,0,403,404,5,114,0,0,404,405,5,101,0,0,405, 406,5,97,0,0,406,407,5,116,0,0,407,408,5,101,0,0,408,409,5,95,0, 0,409,410,5,117,0,0,410,411,5,117,0,0,411,412,5,105,0,0,412,413, 5,100,0,0,413,414,5,95,0,0,414,415,5,114,0,0,415,416,5,101,0,0,416, 417,5,115,0,0,417,418,5,111,0,0,418,419,5,117,0,0,419,420,5,114, 0,0,420,421,5,99,0,0,421,422,5,101,0,0,422,423,5,40,0,0,423,424, 5,41,0,0,424,72,1,0,0,0,425,426,5,108,0,0,426,427,5,111,0,0,427, 428,5,111,0,0,428,429,5,107,0,0,429,430,5,117,0,0,430,431,5,112, 0,0,431,432,5,95,0,0,432,433,5,116,0,0,433,434,5,97,0,0,434,435, 5,98,0,0,435,436,5,108,0,0,436,437,5,101,0,0,437,74,1,0,0,0,438, 439,5,36,0,0,439,440,5,116,0,0,440,441,5,97,0,0,441,442,5,98,0,0, 442,443,5,108,0,0,443,444,5,101,0,0,444,445,5,95,0,0,445,446,5,110, 0,0,446,447,5,97,0,0,447,448,5,109,0,0,448,449,5,101,0,0,449,76, 1,0,0,0,450,451,5,36,0,0,451,452,5,99,0,0,452,453,5,115,0,0,453, 454,5,118,0,0,454,455,5,95,0,0,455,456,5,102,0,0,456,457,5,105,0, 0,457,458,5,108,0,0,458,459,5,101,0,0,459,78,1,0,0,0,460,461,5,36, 0,0,461,462,5,107,0,0,462,463,5,101,0,0,463,464,5,121,0,0,464,80, 1,0,0,0,465,466,5,36,0,0,466,467,5,99,0,0,467,468,5,111,0,0,468, 469,5,108,0,0,469,470,5,117,0,0,470,471,5,109,0,0,471,472,5,110, 0,0,472,473,5,115,0,0,473,82,1,0,0,0,474,475,5,116,0,0,475,476,5, 114,0,0,476,477,5,117,0,0,477,478,5,101,0,0,478,84,1,0,0,0,479,480, 5,102,0,0,480,481,5,97,0,0,481,482,5,108,0,0,482,483,5,115,0,0,483, 484,5,101,0,0,484,86,1,0,0,0,485,486,5,110,0,0,486,487,5,117,0,0, 487,488,5,108,0,0,488,489,5,108,0,0,489,88,1,0,0,0,490,491,5,110, 0,0,491,492,5,111,0,0,492,493,5,116,0,0,493,90,1,0,0,0,494,495,5, 116,0,0,495,496,5,111,0,0,496,497,5,84,0,0,497,498,5,101,0,0,498, 499,5,120,0,0,499,500,5,116,0,0,500,92,1,0,0,0,501,502,5,61,0,0, 502,503,5,61,0,0,503,94,1,0,0,0,504,505,5,60,0,0,505,96,1,0,0,0, 506,507,5,60,0,0,507,508,5,61,0,0,508,98,1,0,0,0,509,510,5,62,0, 0,510,100,1,0,0,0,511,512,5,62,0,0,512,513,5,61,0,0,513,102,1,0, 0,0,514,515,5,33,0,0,515,516,5,61,0,0,516,104,1,0,0,0,517,518,5, 114,0,0,518,519,5,63,0,0,519,106,1,0,0,0,520,521,5,43,0,0,521,108, 1,0,0,0,522,523,5,45,0,0,523,110,1,0,0,0,524,525,5,42,0,0,525,112, 1,0,0,0,526,527,5,47,0,0,527,114,1,0,0,0,528,529,5,111,0,0,529,530, 5,114,0,0,530,116,1,0,0,0,531,532,5,97,0,0,532,533,5,110,0,0,533, 534,5,100,0,0,534,118,1,0,0,0,535,536,5,59,0,0,536,120,1,0,0,0,537, 538,5,61,0,0,538,122,1,0,0,0,539,544,3,125,62,0,540,543,3,125,62, 0,541,543,3,127,63,0,542,540,1,0,0,0,542,541,1,0,0,0,543,546,1,0, 0,0,544,542,1,0,0,0,544,545,1,0,0,0,545,124,1,0,0,0,546,544,1,0, 0,0,547,548,7,0,0,0,548,126,1,0,0,0,549,551,7,1,0,0,550,549,1,0, 0,0,551,552,1,0,0,0,552,550,1,0,0,0,552,553,1,0,0,0,553,128,1,0, 0,0,554,559,5,34,0,0,555,558,3,131,65,0,556,558,9,0,0,0,557,555, 1,0,0,0,557,556,1,0,0,0,558,561,1,0,0,0,559,560,1,0,0,0,559,557, 1,0,0,0,560,562,1,0,0,0,561,559,1,0,0,0,562,563,5,34,0,0,563,130, 1,0,0,0,564,565,5,92,0,0,565,569,5,34,0,0,566,567,5,92,0,0,567,569, 5,92,0,0,568,564,1,0,0,0,568,566,1,0,0,0,569,132,1,0,0,0,570,574, 5,35,0,0,571,573,3,135,67,0,572,571,1,0,0,0,573,576,1,0,0,0,574, 572,1,0,0,0,574,575,1,0,0,0,575,134,1,0,0,0,576,574,1,0,0,0,577, 578,8,2,0,0,578,136,1,0,0,0,579,581,7,3,0,0,580,579,1,0,0,0,581, 582,1,0,0,0,582,580,1,0,0,0,582,583,1,0,0,0,583,584,1,0,0,0,584, 585,6,68,0,0,585,138,1,0,0,0,9,0,542,544,552,557,559,568,574,582, 1,6,0,0 ] class JetRuleLexer(Lexer): atn = ATNDeserializer().deserialize(serializedATN()) decisionsToDFA = [ DFA(ds, i) for i, ds in enumerate(atn.decisionToState) ] T__0 = 1 T__1 = 2 T__2 = 3 T__3 = 4 T__4 = 5 T__5 = 6 T__6 = 7 T__7 = 8 T__8 = 9 T__9 = 10 T__10 = 11 T__11 = 12 JetCompilerDirective = 13 CLASS = 14 BaseClasses = 15 AsTable = 16 DataProperties = 17 ARRAY = 18 JETSCONFIG = 19 MaxLooping = 20 MaxRuleExec = 21 RULESEQ = 22 MainRuleSets = 23 TRIPLE = 24 Int32Type = 25 UInt32Type = 26 Int64Type = 27 UInt64Type = 28 DoubleType = 29 StringType = 30 DateType = 31 DatetimeType = 32 BoolType = 33 ResourceType = 34 VolatileResourceType = 35 CreateUUIDResource = 36 LookupTable = 37 TableName = 38 CSVFileName = 39 Key = 40 Columns = 41 TRUE = 42 FALSE = 43 NULL = 44 NOT = 45 TOTEXT = 46 EQ = 47 LT = 48 LE = 49 GT = 50 GE = 51 NE = 52 REGEX2 = 53 PLUS = 54 MINUS = 55 MUL = 56 DIV = 57 OR = 58 AND = 59 SEMICOLON = 60 ASSIGN = 61 Identifier = 62 DIGITS = 63 STRING = 64 COMMENT = 65 WS = 66 channelNames = [ u"DEFAULT_TOKEN_CHANNEL", u"HIDDEN" ] modeNames = [ "DEFAULT_MODE" ] literalNames = [ "<INVALID>", "'{'", "'}'", "','", "'['", "']'", "'as'", "'.'", "':'", "'->'", "'('", "')'", "'?'", "'@JetCompilerDirective'", "'class'", "'$base_classes'", "'$as_table'", "'$data_properties'", "'array of'", "'jetstore_config'", "'$max_looping'", "'$max_rule_exec'", "'rule_sequence'", "'$main_rule_sets'", "'triple'", "'int'", "'uint'", "'long'", "'ulong'", "'double'", "'text'", "'date'", "'datetime'", "'bool'", "'resource'", "'volatile_resource'", "'create_uuid_resource()'", "'lookup_table'", "'$table_name'", "'$csv_file'", "'$key'", "'$columns'", "'true'", "'false'", "'null'", "'not'", "'toText'", "'=='", "'<'", "'<='", "'>'", "'>='", "'!='", "'r?'", "'+'", "'-'", "'*'", "'/'", "'or'", "'and'", "';'", "'='" ] symbolicNames = [ "<INVALID>", "JetCompilerDirective", "CLASS", "BaseClasses", "AsTable", "DataProperties", "ARRAY", "JETSCONFIG", "MaxLooping", "MaxRuleExec", "RULESEQ", "MainRuleSets", "TRIPLE", "Int32Type", "UInt32Type", "Int64Type", "UInt64Type", "DoubleType", "StringType", "DateType", "DatetimeType", "BoolType", "ResourceType", "VolatileResourceType", "CreateUUIDResource", "LookupTable", "TableName", "CSVFileName", "Key", "Columns", "TRUE", "FALSE", "NULL", "NOT", "TOTEXT", "EQ", "LT", "LE", "GT", "GE", "NE", "REGEX2", "PLUS", "MINUS", "MUL", "DIV", "OR", "AND", "SEMICOLON", "ASSIGN", "Identifier", "DIGITS", "STRING", "COMMENT", "WS" ] ruleNames = [ "T__0", "T__1", "T__2", "T__3", "T__4", "T__5", "T__6", "T__7", "T__8", "T__9", "T__10", "T__11", "JetCompilerDirective", "CLASS", "BaseClasses", "AsTable", "DataProperties", "ARRAY", "JETSCONFIG", "MaxLooping", "MaxRuleExec", "RULESEQ", "MainRuleSets", "TRIPLE", "Int32Type", "UInt32Type", "Int64Type", "UInt64Type", "DoubleType", "StringType", "DateType", "DatetimeType", "BoolType", "ResourceType", "VolatileResourceType", "CreateUUIDResource", "LookupTable", "TableName", "CSVFileName", "Key", "Columns", "TRUE", "FALSE", "NULL", "NOT", "TOTEXT", "EQ", "LT", "LE", "GT", "GE", "NE", "REGEX2", "PLUS", "MINUS", "MUL", "DIV", "OR", "AND", "SEMICOLON", "ASSIGN", "Identifier", "NONDIGIT", "DIGITS", "STRING", "ESC", "COMMENT", "Cchar", "WS" ] grammarFileName = "JetRule.g4" def __init__(self, input=None, output:TextIO = sys.stdout): super().__init__(input, output) self.checkVersion("4.10.1") self._interp = LexerATNSimulator(self, self.atn, self.decisionsToDFA, PredictionContextCache()) self._actions = None self._predicates = None
56.933526
103
0.543073
5,353
19,699
1.983747
0.138053
0.166871
0.084754
0.087767
0.220171
0.171956
0.170826
0.164516
0.164516
0.153593
0
0.516696
0.162343
19,699
345
104
57.098551
0.126841
0.002081
0
0.006079
1
0
0.071334
0.00346
0.00304
0
0
0
0
1
0.006079
false
0
0.015198
0.00304
0.25228
0
0
0
1
null
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
1
0
0
0
1
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
0ea2e2a10794484c419e0db23efcbd099c34b1a4
196
py
Python
src/cocoa/toga_cocoa/font.py
jrwdunham/toga
db343c99d0f174aea86c4656849ea25ffb7bfe7a
[ "BSD-3-Clause" ]
null
null
null
src/cocoa/toga_cocoa/font.py
jrwdunham/toga
db343c99d0f174aea86c4656849ea25ffb7bfe7a
[ "BSD-3-Clause" ]
null
null
null
src/cocoa/toga_cocoa/font.py
jrwdunham/toga
db343c99d0f174aea86c4656849ea25ffb7bfe7a
[ "BSD-3-Clause" ]
null
null
null
from toga.interface import Font as FontInterface from .libs import NSFont class Font(FontInterface): def create(self): self._impl = NSFont.fontWithName_size_(self.family, self.size)
24.5
70
0.755102
26
196
5.576923
0.653846
0
0
0
0
0
0
0
0
0
0
0
0.163265
196
7
71
28
0.884146
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
7ec4a8ebd2ed81bb04cff6b1bf229bb87348335a
103
py
Python
src/utils/utils.py
gyz0807-ai/facial_keypoints_detection
0bddf20b7cc17a0cfe5bfe7fc0c5201880ce9b84
[ "MIT" ]
null
null
null
src/utils/utils.py
gyz0807-ai/facial_keypoints_detection
0bddf20b7cc17a0cfe5bfe7fc0c5201880ce9b84
[ "MIT" ]
null
null
null
src/utils/utils.py
gyz0807-ai/facial_keypoints_detection
0bddf20b7cc17a0cfe5bfe7fc0c5201880ce9b84
[ "MIT" ]
null
null
null
import matplotlib.pyplot as plt def plt_keypoints(image, keypoints): plt.imshow(image) return
17.166667
36
0.747573
14
103
5.428571
0.714286
0
0
0
0
0
0
0
0
0
0
0
0.174757
103
5
37
20.6
0.894118
0
0
0
0
0
0
0
0
0
0
0
0
1
0.25
false
0
0.25
0
0.75
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
0
1
0
0
4
7edf98cf1e032e49ca4c565dc7af2f5c3d9cf481
22,767
py
Python
tests/test_requests.py
rocketgram/rocketgram
b94d8f83e577c0618a650c113d688ef8689ac3f5
[ "MIT" ]
35
2019-09-19T22:56:22.000Z
2022-03-12T10:49:47.000Z
tests/test_requests.py
rocketgram/rocketgram
b94d8f83e577c0618a650c113d688ef8689ac3f5
[ "MIT" ]
2
2020-10-20T05:24:25.000Z
2021-03-27T18:21:23.000Z
tests/test_requests.py
rocketgram/rocketgram
b94d8f83e577c0618a650c113d688ef8689ac3f5
[ "MIT" ]
4
2020-06-26T01:12:30.000Z
2022-01-16T13:55:47.000Z
# Copyright (C) 2015-2021 by Vd. # This file is part of Rocketgram, the modern Telegram bot framework. # Rocketgram is released under the MIT License (see LICENSE). from io import BytesIO from rocketgram import api def test_GetUpdates(): req = api.GetUpdates() assert req.render() == {} assert req.render(with_method=True) == {'method': 'GetUpdates'} assert req.files() == [] req = api.GetUpdates(offset=1000, limit=10, timeout=30, allowed_updates=[api.UpdateType.message, api.UpdateType.channel_post]) assert req.render() == {'allowed_updates': ['message', 'channel_post'], 'limit': 10, 'offset': 1000, 'timeout': 30} def test_SetWebhook(): req = api.SetWebhook(url='https://www.example.com/bot') assert req.render() == {'url': 'https://www.example.com/bot'} assert req.render(with_method=True) == {'method': 'SetWebhook', 'url': 'https://www.example.com/bot'} assert req.files() == [] req = api.SetWebhook(url='https://www.example.com/bot', certificate='https://www.example.com/cert/cert.crt', max_connections=10, allowed_updates=[api.UpdateType.message, api.UpdateType.channel_post]) assert req.render() == {'url': 'https://www.example.com/bot', 'allowed_updates': ['message', 'channel_post'], 'max_connections': 10, 'certificate': 'https://www.example.com/cert/cert.crt'} file = api.InputFile('cert.crt', 'application/x-x509-ca-cert', BytesIO()) req = api.SetWebhook(url='https://www.example.com/bot', certificate=file) assert req.render() == {'url': 'https://www.example.com/bot', 'certificate': 'attach://cert.crt'} assert req.files() == [file] def test_DeleteWebhook(): req = api.DeleteWebhook() assert req.render() == {} assert req.render(with_method=True) == {'method': 'DeleteWebhook'} assert req.files() == [] def test_GetWebhookInfo(): req = api.GetWebhookInfo() assert req.render() == {} assert req.render(with_method=True) == {'method': 'GetWebhookInfo'} assert req.files() == [] def test_GetMe(): req = api.GetMe() assert req.render() == {} assert req.render(with_method=True) == {'method': 'GetMe'} assert req.files() == [] def test_SendMessage(): req = api.SendMessage(1000, "Hello, World!") assert req.render() == {'chat_id': 1000, 'text': 'Hello, World!'} assert req.render(with_method=True) == {'method': 'SendMessage', 'chat_id': 1000, 'text': 'Hello, World!'} assert req.files() == [] kb = api.InlineKeyboardMarkup([[api.InlineKeyboardButton('Button', callback_data='data')]]) req = api.SendMessage(1000, "Hello, World!", parse_mode=api.ParseModeType.html, disable_web_page_preview=True, disable_notification=True, reply_to_message_id=100, reply_markup=kb) assert req.render() == {'chat_id': 1000, 'text': 'Hello, World!', 'disable_notification': True, 'disable_web_page_preview': True, 'parse_mode': 'html', 'reply_to_message_id': 100, 'reply_markup': {'inline_keyboard': [[{'callback_data': 'data', 'text': 'Button'}]]}} assert req.files() == [] def test_ForwardMessage(): req = api.ForwardMessage(1000, 1234, 100) assert req.render() == {'chat_id': 1000, 'from_chat_id': 1234, 'message_id': 100} assert req.render(with_method=True) == {'method': 'ForwardMessage', 'chat_id': 1000, 'from_chat_id': 1234, 'message_id': 100} assert req.files() == [] req = api.ForwardMessage(1000, 1234, 100, disable_notification=True) assert req.render() == {'chat_id': 1000, 'from_chat_id': 1234, 'message_id': 100, 'disable_notification': True} assert req.files() == [] def test_SendPhoto(): req = api.SendPhoto(1000, "ABCDEFGHIJKLMNOPQRSTUVWXYZ") assert req.render() == {'chat_id': 1000, 'photo': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'} assert req.render(with_method=True) == {'method': 'SendPhoto', 'chat_id': 1000, 'photo': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'} assert req.files() == [] photo_file = api.InputFile('photo.jpg', 'image/jpeg', BytesIO()) kb = api.InlineKeyboardMarkup([[api.InlineKeyboardButton('Button', callback_data='data')]]) req = api.SendPhoto(1000, photo_file, caption="Hello, World!", parse_mode=api.ParseModeType.html, disable_notification=True, reply_to_message_id=100, reply_markup=kb) assert req.render() == {'chat_id': 1000, 'photo': 'attach://photo.jpg', 'disable_notification': True, 'caption': 'Hello, World!', 'parse_mode': 'html', 'reply_to_message_id': 100, 'reply_markup': {'inline_keyboard': [[{'callback_data': 'data', 'text': 'Button'}]]}} assert req.files() == [photo_file] def test_SendAudio(): req = api.SendAudio(1000, "ABCDEFGHIJKLMNOPQRSTUVWXYZ") assert req.render() == {'chat_id': 1000, 'audio': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'} assert req.render(with_method=True) == {'method': 'SendAudio', 'chat_id': 1000, 'audio': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'} assert req.files() == [] audio_file = api.InputFile('audio.mp3', 'audio/mpeg', BytesIO()) thumb_file = api.InputFile('thumb.jpg', 'image/jpeg', BytesIO()) kb = api.InlineKeyboardMarkup([[api.InlineKeyboardButton('Button', callback_data='data')]]) req = api.SendAudio(1000, audio_file, duration=300, performer="Beethoven", title="Symphony No. 5", thumb=thumb_file, caption="Hello, World!", parse_mode=api.ParseModeType.html, disable_notification=True, reply_to_message_id=100, reply_markup=kb) assert req.render() == {'chat_id': 1000, 'audio': 'attach://audio.mp3', 'duration': 300, 'performer': "Beethoven", 'title': "Symphony No. 5", 'thumb': 'attach://thumb.jpg', 'caption': 'Hello, World!', 'parse_mode': 'html', 'disable_notification': True, 'reply_to_message_id': 100, 'reply_markup': {'inline_keyboard': [[{'callback_data': 'data', 'text': 'Button'}]]}} assert req.files() == [audio_file, thumb_file] def test_SendDocument(): req = api.SendDocument(1000, "ABCDEFGHIJKLMNOPQRSTUVWXYZ") assert req.render() == {'chat_id': 1000, 'document': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'} assert req.render(with_method=True) == {'method': 'SendDocument', 'chat_id': 1000, 'document': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'} assert req.files() == [] document_file = api.InputFile('document.pdf', 'application/pdf', BytesIO()) thumb_file = api.InputFile('thumb.jpg', 'image/jpeg', BytesIO()) kb = api.InlineKeyboardMarkup([[api.InlineKeyboardButton('Button', callback_data='data')]]) req = api.SendDocument(1000, document_file, thumb=thumb_file, caption="Hello, World!", parse_mode=api.ParseModeType.html, disable_notification=True, reply_to_message_id=100, reply_markup=kb) assert req.render() == {'chat_id': 1000, 'document': 'attach://document.pdf', 'thumb': 'attach://thumb.jpg', 'caption': 'Hello, World!', 'parse_mode': 'html', 'disable_notification': True, 'reply_to_message_id': 100, 'reply_markup': {'inline_keyboard': [[{'callback_data': 'data', 'text': 'Button'}]]}} assert req.files() == [document_file, thumb_file] def test_SendVideo(): req = api.SendVideo(1000, "ABCDEFGHIJKLMNOPQRSTUVWXYZ") assert req.render() == {'chat_id': 1000, 'video': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'} assert req.render(with_method=True) == {'method': 'SendVideo', 'chat_id': 1000, 'video': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'} assert req.files() == [] video_file = api.InputFile('video.mp4', 'video/mp4', BytesIO()) thumb_file = api.InputFile('thumb.jpg', 'image/jpeg', BytesIO()) kb = api.InlineKeyboardMarkup([[api.InlineKeyboardButton('Button', callback_data='data')]]) req = api.SendVideo(1000, video_file, duration=300, width=640, height=480, supports_streaming=True, thumb=thumb_file, caption="Hello, World!", parse_mode=api.ParseModeType.html, disable_notification=True, reply_to_message_id=100, reply_markup=kb) assert req.render() == {'chat_id': 1000, 'video': 'attach://video.mp4', 'duration': 300, 'width': 640, 'height': 480, 'supports_streaming': True, 'thumb': 'attach://thumb.jpg', 'caption': 'Hello, World!', 'parse_mode': 'html', 'disable_notification': True, 'reply_to_message_id': 100, 'reply_markup': {'inline_keyboard': [[{'callback_data': 'data', 'text': 'Button'}]]}} assert req.files() == [video_file, thumb_file] def test_SendAnimation(): req = api.SendAnimation(1000, "ABCDEFGHIJKLMNOPQRSTUVWXYZ") assert req.render() == {'chat_id': 1000, 'animation': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'} assert req.render(with_method=True) == {'method': 'SendAnimation', 'chat_id': 1000, 'animation': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'} assert req.files() == [] animation_file = api.InputFile('animation.mp4', 'video/mp4', BytesIO()) thumb_file = api.InputFile('thumb.jpg', 'image/jpeg', BytesIO()) kb = api.InlineKeyboardMarkup([[api.InlineKeyboardButton('Button', callback_data='data')]]) req = api.SendAnimation(1000, animation_file, duration=300, width=640, height=480, thumb=thumb_file, caption="Hello, World!", parse_mode=api.ParseModeType.html, disable_notification=True, reply_to_message_id=100, reply_markup=kb) assert req.render() == {'chat_id': 1000, 'animation': 'attach://animation.mp4', 'duration': 300, 'width': 640, 'height': 480, 'thumb': 'attach://thumb.jpg', 'caption': 'Hello, World!', 'parse_mode': 'html', 'disable_notification': True, 'reply_to_message_id': 100, 'reply_markup': {'inline_keyboard': [[{'callback_data': 'data', 'text': 'Button'}]]}} assert req.files() == [animation_file, thumb_file] def test_SendVoice(): req = api.SendVoice(1000, "ABCDEFGHIJKLMNOPQRSTUVWXYZ") assert req.render() == {'chat_id': 1000, 'voice': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'} assert req.render(with_method=True) == {'method': 'SendVoice', 'chat_id': 1000, 'voice': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'} assert req.files() == [] voice_file = api.InputFile('voice.opus', 'audio/ogg', BytesIO()) kb = api.InlineKeyboardMarkup([[api.InlineKeyboardButton('Button', callback_data='data')]]) req = api.SendVoice(1000, voice_file, duration=300, caption="Hello, World!", parse_mode=api.ParseModeType.html, disable_notification=True, reply_to_message_id=100, reply_markup=kb) assert req.render() == {'chat_id': 1000, 'voice': 'attach://voice.opus', 'duration': 300, 'caption': 'Hello, World!', 'parse_mode': 'html', 'disable_notification': True, 'reply_to_message_id': 100, 'reply_markup': {'inline_keyboard': [[{'callback_data': 'data', 'text': 'Button'}]]}} assert req.files() == [voice_file] def test_SendVideoNote(): req = api.SendVideoNote(1000, "ABCDEFGHIJKLMNOPQRSTUVWXYZ") assert req.render() == {'chat_id': 1000, 'video_note': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'} assert req.render(with_method=True) == {'method': 'SendVideoNote', 'chat_id': 1000, 'video_note': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'} assert req.files() == [] note_file = api.InputFile('voice.opus', 'audio/ogg', BytesIO()) thumb_file = api.InputFile('thumb.jpg', 'image/jpeg', BytesIO()) kb = api.InlineKeyboardMarkup([[api.InlineKeyboardButton('Button', callback_data='data')]]) req = api.SendVideoNote(1000, note_file, duration=300, length=500, thumb=thumb_file, disable_notification=True, reply_to_message_id=100, reply_markup=kb) assert req.render() == {'chat_id': 1000, 'video_note': 'attach://voice.opus', 'duration': 300, 'length': 500, 'thumb': 'attach://thumb.jpg', 'disable_notification': True, 'reply_to_message_id': 100, 'reply_markup': {'inline_keyboard': [[{'callback_data': 'data', 'text': 'Button'}]]}} assert req.files() == [note_file, thumb_file] def test_SendMediaGroupe(): photo = api.InputMediaPhoto("ABCDEFGHIJKLMNOPQRSTUVWXYZ") req = api.SendMediaGroup(1000, [photo]) assert req.render() == {'chat_id': 1000, 'media': [{'media': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'type': 'photo'}]} assert req.render(with_method=True) == {'method': 'SendMediaGroup', 'chat_id': 1000, 'media': [{'media': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'type': 'photo'}]} assert req.files() == [] photo_file_1 = api.InputFile('photo1.jpg', 'image/jpeg', BytesIO()) photo1 = api.InputMediaPhoto(photo_file_1, caption="Hello, World!", parse_mode=api.ParseModeType.html) photo_file_2 = api.InputFile('photo2.jpg', 'image/jpeg', BytesIO()) photo2 = api.InputMediaPhoto(photo_file_2, caption="Hello, World!", parse_mode=api.ParseModeType.html) req = api.SendMediaGroup(1000, [photo1, photo2], disable_notification=True, reply_to_message_id=100) assert req.render() == {'chat_id': 1000, 'media': [{'media': 'attach://photo1.jpg', 'type': 'photo', 'caption': 'Hello, World!', 'parse_mode': 'html'}, {'media': 'attach://photo2.jpg', 'type': 'photo', 'caption': 'Hello, World!', 'parse_mode': 'html'}], 'disable_notification': True, 'reply_to_message_id': 100} assert req.files() == [photo_file_1, photo_file_2] def test_SendLocation(): req = api.SendLocation(1000, latitude=31.7767, longitude=35.2345) assert req.render() == {'chat_id': 1000, 'latitude': 31.7767, 'longitude': 35.2345} assert req.render(with_method=True) == {'method': 'SendLocation', 'chat_id': 1000, 'latitude': 31.7767, 'longitude': 35.2345} assert req.files() == [] kb = api.InlineKeyboardMarkup([[api.InlineKeyboardButton('Button', callback_data='data')]]) req = api.SendLocation(1000, latitude=31.7767, longitude=35.2345, live_period=300, disable_notification=True, reply_to_message_id=100, reply_markup=kb) assert req.render() == {'chat_id': 1000, 'latitude': 31.7767, 'longitude': 35.2345, 'disable_notification': True, 'live_period': 300, 'reply_to_message_id': 100, 'reply_markup': {'inline_keyboard': [[{'callback_data': 'data', 'text': 'Button'}]]}} assert req.files() == [] def test_EditMessageLiveLocation(): req = api.EditMessageLiveLocation(chat_id=1000, message_id=300, latitude=31.7767, longitude=35.2345) assert req.render() == {'chat_id': 1000, 'message_id': 300, 'latitude': 31.7767, 'longitude': 35.2345} assert req.render(with_method=True) == {'method': 'EditMessageLiveLocation', 'chat_id': 1000, 'message_id': 300, 'latitude': 31.7767, 'longitude': 35.2345} assert req.files() == [] req = api.EditMessageLiveLocation(inline_message_id='ABCDEFGHIJKLMNOPQRSTUVWXYZ', latitude=31.7767, longitude=35.2345) assert req.render() == {'inline_message_id': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'latitude': 31.7767, 'longitude': 35.2345} assert req.render(with_method=True) == {'method': 'EditMessageLiveLocation', 'inline_message_id': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'latitude': 31.7767, 'longitude': 35.2345} assert req.files() == [] kb = api.InlineKeyboardMarkup([[api.InlineKeyboardButton('Button', callback_data='data')]]) req = api.EditMessageLiveLocation(chat_id=1000, message_id=300, latitude=31.7767, longitude=35.2345, reply_markup=kb) assert req.render() == {'chat_id': 1000, 'message_id': 300, 'latitude': 31.7767, 'longitude': 35.2345, 'reply_markup': {'inline_keyboard': [[{'callback_data': 'data', 'text': 'Button'}]]}} assert req.files() == [] def test_StopMessageLiveLocation(): req = api.StopMessageLiveLocation(chat_id=1000, message_id=300) assert req.render() == {'chat_id': 1000, 'message_id': 300} assert req.render(with_method=True) == {'method': 'StopMessageLiveLocation', 'chat_id': 1000, 'message_id': 300} assert req.files() == [] req = api.StopMessageLiveLocation(inline_message_id='ABCDEFGHIJKLMNOPQRSTUVWXYZ') assert req.render() == {'inline_message_id': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'} assert req.render(with_method=True) == {'method': 'StopMessageLiveLocation', 'inline_message_id': 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'} assert req.files() == [] kb = api.InlineKeyboardMarkup([[api.InlineKeyboardButton('Button', callback_data='data')]]) req = api.StopMessageLiveLocation(chat_id=1000, message_id=300, reply_markup=kb) assert req.render() == {'chat_id': 1000, 'message_id': 300, 'reply_markup': {'inline_keyboard': [[{'callback_data': 'data', 'text': 'Button'}]]}} assert req.files() == [] def test_SendVenue(): req = api.SendVenue(1000, latitude=31.7767, longitude=35.2345, title='Earth', address='Solar system') assert req.render() == {'chat_id': 1000, 'latitude': 31.7767, 'longitude': 35.2345, 'title': 'Earth', 'address': 'Solar system'} assert req.render(with_method=True) == {'method': 'SendVenue', 'chat_id': 1000, 'latitude': 31.7767, 'longitude': 35.2345, 'title': 'Earth', 'address': 'Solar system'} assert req.files() == [] kb = api.InlineKeyboardMarkup([[api.InlineKeyboardButton('Button', callback_data='data')]]) req = api.SendVenue(1000, latitude=31.7767, longitude=35.2345, title='Earth', address='Solar system', foursquare_id='ABCDE123', foursquare_type='food/icecream', disable_notification=True, reply_to_message_id=100, reply_markup=kb) assert req.render() == {'chat_id': 1000, 'latitude': 31.7767, 'longitude': 35.2345, 'title': 'Earth', 'address': 'Solar system', 'foursquare_id': 'ABCDE123', 'foursquare_type': 'food/icecream', 'disable_notification': True, 'reply_to_message_id': 100, 'reply_markup': {'inline_keyboard': [[{'callback_data': 'data', 'text': 'Button'}]]}} assert req.files() == [] def test_SendContact(): req = api.SendContact(1000, phone_number='+1234567890', first_name='John') assert req.render() == {'chat_id': 1000, 'phone_number': '+1234567890', 'first_name': 'John'} assert req.render(with_method=True) == {'method': 'SendContact', 'chat_id': 1000, 'phone_number': '+1234567890', 'first_name': 'John'} assert req.files() == [] vcard = "BEGIN:VCARD\nVERSION:4.0\nN:Gump;Forrest;;Mr.;\nFN:Forrest Gump\n" \ "EMAIL:forrestgump@example.com\nEND:VCARD" kb = api.InlineKeyboardMarkup([[api.InlineKeyboardButton('Button', callback_data='data')]]) req = api.SendContact(1000, phone_number='+1234567890', first_name='Forrest', last_name='Gump', vcard=vcard, disable_notification=True, reply_to_message_id=100, reply_markup=kb) assert req.render() == {'chat_id': 1000, 'phone_number': '+1234567890', 'first_name': 'Forrest', 'last_name': 'Gump', 'vcard': vcard, 'disable_notification': True, 'reply_to_message_id': 100, 'reply_markup': {'inline_keyboard': [[{'callback_data': 'data', 'text': 'Button'}]]}} assert req.files() == [] def test_SendPoll(): req = api.SendPoll(1000, question='Do it?', options=['Yes', 'No']) assert req.render() == {'chat_id': 1000, 'question': 'Do it?', 'options': ['Yes', 'No']} assert req.render(with_method=True) == {'method': 'SendPoll', 'chat_id': 1000, 'question': 'Do it?', 'options': ['Yes', 'No']} assert req.files() == [] kb = api.InlineKeyboardMarkup([[api.InlineKeyboardButton('Button', callback_data='data')]]) req = api.SendPoll(1000, question='Do it?', options=['Yes', 'No'], disable_notification=True, reply_to_message_id=100, reply_markup=kb) assert req.render() == {'chat_id': 1000, 'question': 'Do it?', 'options': ['Yes', 'No'], 'disable_notification': True, 'reply_to_message_id': 100, 'reply_markup': {'inline_keyboard': [[{'callback_data': 'data', 'text': 'Button'}]]}} assert req.files() == [] def test_SendChatAction(): req = api.SendChatAction(1000, action=api.ChatActionType.typing) assert req.render() == {'chat_id': 1000, 'action': 'typing'} assert req.render(with_method=True) == {'method': 'SendChatAction', 'chat_id': 1000, 'action': 'typing'} assert req.files() == [] def test_GetUserProfilePhotos(): req = api.GetUserProfilePhotos(10000, offset=10, limit=20) assert req.render() == {'user_id': 10000, 'offset': 10, 'limit': 20} assert req.render(with_method=True) == {'method': 'GetUserProfilePhotos', 'user_id': 10000, 'offset': 10, 'limit': 20} assert req.files() == [] def test_GetFile(): req = api.GetFile('ABCDEFG12345') assert req.render() == {'file_id': 'ABCDEFG12345'} assert req.render(with_method=True) == {'method': 'GetFile', 'file_id': 'ABCDEFG12345'} assert req.files() == []
53.695755
119
0.601397
2,406
22,767
5.516209
0.086035
0.077306
0.080244
0.047242
0.842224
0.79566
0.778556
0.709765
0.61513
0.553195
0
0.052138
0.231695
22,767
423
120
53.822695
0.706609
0.00694
0
0.359477
0
0.003268
0.264455
0.047025
0
0
0
0
0.372549
1
0.078431
false
0
0.006536
0
0.084967
0
0
0
0
null
0
0
0
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
7ee420af721ecca46e8d6e07600a7909f5d7a37b
124
py
Python
app/projects/__init__.py
larsertoff/pwp
1f156e3efc7b93345197329425e2928a470d3092
[ "MIT" ]
null
null
null
app/projects/__init__.py
larsertoff/pwp
1f156e3efc7b93345197329425e2928a470d3092
[ "MIT" ]
null
null
null
app/projects/__init__.py
larsertoff/pwp
1f156e3efc7b93345197329425e2928a470d3092
[ "MIT" ]
null
null
null
import flask projects = flask.Blueprint('projects', __name__, template_folder='templates') from app.projects import routes
24.8
77
0.806452
15
124
6.333333
0.733333
0
0
0
0
0
0
0
0
0
0
0
0.096774
124
5
78
24.8
0.848214
0
0
0
0
0
0.136
0
0
0
0
0
0
1
0
false
0
0.666667
0
0.666667
0.333333
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
7d0fb06b8b7805ef1f88f673328644ba4999bbb4
186
py
Python
image_captioning/__init__.py
shibing624/cvnet
5b9032a6d4be731cca92392a6779d56635781169
[ "Apache-2.0" ]
2
2020-10-27T01:35:32.000Z
2020-12-07T19:09:51.000Z
image_captioning/__init__.py
shibing624/imagefun
5c5c688b530f07688cda85705591634286f0b848
[ "Apache-2.0" ]
1
2020-12-01T14:24:06.000Z
2020-12-01T14:24:06.000Z
image_captioning/__init__.py
shibing624/imagefun
5c5c688b530f07688cda85705591634286f0b848
[ "Apache-2.0" ]
1
2021-05-19T02:41:40.000Z
2021-05-19T02:41:40.000Z
# -*- coding: utf-8 -*- """ @author:XuMing(xuming624@qq.com) @description: reference: https://github.com/yunjey/pytorch-tutorial/blob/master/tutorials/03-advanced/image_captioning """
20.666667
104
0.731183
23
186
5.869565
0.956522
0
0
0
0
0
0
0
0
0
0
0.034682
0.069892
186
8
105
23.25
0.745665
0.94086
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
7d2647dab4313bf289a275aa2e83a8b44519da68
42
py
Python
aiida_kkr/tests/__init__.py
markusstruckmann/aiida-kkr
5ce20a61a667787aeb68fa0c8b81e73aa3cf94a5
[ "MIT" ]
6
2018-11-16T10:44:06.000Z
2021-02-09T15:38:51.000Z
aiida_kkr/tests/__init__.py
RubelMozumder/aiida-kkr
1db3d57626c27f2a7105d587dfb8543269ce6c00
[ "MIT" ]
63
2018-11-27T10:43:49.000Z
2022-02-10T11:10:16.000Z
aiida_kkr/tests/__init__.py
RubelMozumder/aiida-kkr
1db3d57626c27f2a7105d587dfb8543269ce6c00
[ "MIT" ]
9
2018-11-09T09:52:16.000Z
2021-12-10T18:09:11.000Z
# -*- coding: utf-8 -*- ''' AiiDA-KKR '''
8.4
23
0.428571
5
42
3.6
1
0
0
0
0
0
0
0
0
0
0
0.029412
0.190476
42
4
24
10.5
0.5
0.761905
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
7d3df4fde121ec35181138cd63ba41f074006b81
182
py
Python
backend/garpix_page/apps.py
AlexandrMikhailovich/garpix_page
7d1123e7da35773551fd808228700c77c578b957
[ "MIT" ]
18
2021-05-12T09:56:56.000Z
2022-02-09T07:15:50.000Z
backend/garpix_page/apps.py
AlexandrMikhailovich/garpix_page
7d1123e7da35773551fd808228700c77c578b957
[ "MIT" ]
9
2021-08-30T07:56:11.000Z
2022-02-16T08:44:46.000Z
backend/garpix_page/apps.py
AlexandrMikhailovich/garpix_page
7d1123e7da35773551fd808228700c77c578b957
[ "MIT" ]
6
2021-03-18T08:20:19.000Z
2021-12-27T08:25:58.000Z
from django.apps import AppConfig from django.utils.translation import ugettext_lazy as _ class GarpixPageConfig(AppConfig): name = 'garpix_page' verbose_name = _('Pages')
22.75
55
0.769231
22
182
6.136364
0.772727
0.148148
0
0
0
0
0
0
0
0
0
0
0.153846
182
7
56
26
0.876623
0
0
0
0
0
0.087912
0
0
0
0
0
0
1
0
false
0
0.4
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
4
7d45d823f0cae1c2b64c05ff70a015c21edcaf00
1,614
py
Python
LibRadar/db_dumping.py
chubbymaggie/LibRadar
54ecdde5ec54cfb0fce5f1ab816380ec36756434
[ "Apache-2.0" ]
196
2015-09-04T09:23:49.000Z
2022-03-21T10:19:36.000Z
LibRadar/db_dumping.py
chubbymaggie/LibRadar
54ecdde5ec54cfb0fce5f1ab816380ec36756434
[ "Apache-2.0" ]
56
2016-07-29T12:11:55.000Z
2021-11-09T12:14:39.000Z
LibRadar/db_dumping.py
chubbymaggie/LibRadar
54ecdde5ec54cfb0fce5f1ab816380ec36756434
[ "Apache-2.0" ]
49
2016-01-18T09:05:49.000Z
2022-02-07T17:26:04.000Z
# -*- coding: utf-8 -*- # Copyright 2017 Zachary Marv (马子昂) # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # Dumping features in database into file for LibRadar Lite (Instant Detection.) # # created at 2017/01/09 import binascii import redis from _settings import * # deprecated 2017-04-09 def dump_database(): pass """ db_feature_count = redis.StrictRedis(host=DB_HOST, port=DB_PORT, db=DB_FEATURE_COUNT) db_feature_weight = redis.StrictRedis(host=DB_HOST, port=DB_PORT, db=DB_FEATURE_WEIGHT) db_un_ob_pn = redis.StrictRedis(host=DB_HOST, port=DB_PORT, db=DB_UN_OB_PN) dump_file = open(SCRIPT_PATH + "/Data/IntermediateData/db_dump.csv", "w") # Run once, so do not care the complexity. for key in db_feature_count.keys(): count = db_feature_count.get(key) if int(count) <= 4: continue weight = db_feature_weight.get(key) package_name = db_un_ob_pn.get(key) dump_file.write("%s;%s;%s;%s\n" % (binascii.hexlify(key), count, weight, package_name)) """ if __name__ == "__main__": dump_database()
35.086957
95
0.701983
243
1,614
4.473251
0.514403
0.057958
0.051518
0.060718
0.123275
0.123275
0.123275
0.123275
0.123275
0.123275
0
0.020077
0.197646
1,614
45
96
35.866667
0.819305
0.447955
0
0
0
0
0.050314
0
0
0
0
0
0
1
0.142857
true
0.142857
0.428571
0
0.571429
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
1
1
0
1
0
0
4
add732e6997a1e1189f22c752754a5bbe36c6fb7
198
py
Python
core/admin.py
AxioDL/axiodl-www
f5011f3ee3ad8e45b72884c6ea238fb4cea7929c
[ "MIT" ]
null
null
null
core/admin.py
AxioDL/axiodl-www
f5011f3ee3ad8e45b72884c6ea238fb4cea7929c
[ "MIT" ]
7
2021-03-18T23:27:44.000Z
2022-03-11T23:52:23.000Z
core/admin.py
AxioDL/axiodl-www
f5011f3ee3ad8e45b72884c6ea238fb4cea7929c
[ "MIT" ]
null
null
null
from django.contrib import admin from .models import Page, Link from .forms.PageForm import PageFormAdmin fields = ['image_tag'] admin.site.register(Page, PageFormAdmin) admin.site.register(Link)
22
41
0.79798
27
198
5.814815
0.592593
0.11465
0.216561
0
0
0
0
0
0
0
0
0
0.106061
198
8
42
24.75
0.887006
0
0
0
0
0
0.045455
0
0
0
0
0
0
1
0
false
0
0.5
0
0.5
0
1
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
0
0
0
4
bc34e9e4604d3c003e81ce52945ea06456e8187d
126
py
Python
kriegspiel_api_server/kriegspiel/models/move_result.py
Kriegspiel/python-api
f25107d5ebc8810af622c66960c153c43a1ffb03
[ "MIT" ]
1
2016-12-30T10:11:11.000Z
2016-12-30T10:11:11.000Z
kriegspiel_api_server/kriegspiel/models/move_result.py
Kriegspiel/python-api
f25107d5ebc8810af622c66960c153c43a1ffb03
[ "MIT" ]
null
null
null
kriegspiel_api_server/kriegspiel/models/move_result.py
Kriegspiel/python-api
f25107d5ebc8810af622c66960c153c43a1ffb03
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from django.db import models class MoveResult(models.Model): move = models.ForeignKey('Move')
14
36
0.666667
16
126
5.25
0.8125
0
0
0
0
0
0
0
0
0
0
0.009615
0.174603
126
8
37
15.75
0.798077
0.166667
0
0
0
0
0.039216
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
70b71ae76220ba18c6fec654422b5acfe4bb6c28
457
py
Python
src/work-about-work/environment_service/utilities.py
praecipula/google_cloud_apps
e35cfae68e2ab5d3e9902c324104960d6b49f457
[ "BSD-2-Clause" ]
null
null
null
src/work-about-work/environment_service/utilities.py
praecipula/google_cloud_apps
e35cfae68e2ab5d3e9902c324104960d6b49f457
[ "BSD-2-Clause" ]
null
null
null
src/work-about-work/environment_service/utilities.py
praecipula/google_cloud_apps
e35cfae68e2ab5d3e9902c324104960d6b49f457
[ "BSD-2-Clause" ]
null
null
null
"""This module is for utilities that are useful across environments - for instance, we don't know what timezone our environments will be in, so this module contains a method to work with Unix timestamps exclusively in UTC.""" from datetime import datetime import pytz def utc_now(): return datetime.utcnow().replace(tzinfo=pytz.utc) def utc_from_epoch_ms(unix_timestamp): return datetime.utcfromtimestamp(unix_timestamp).replace(tzinfo=pytz.utc)
41.545455
225
0.792123
69
457
5.15942
0.666667
0.05618
0.095506
0.11236
0
0
0
0
0
0
0
0
0.135667
457
10
226
45.7
0.901266
0.479212
0
0
0
0
0
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
cb015d8669fd9d6b062656046f7f1aaef05dc96a
1,832
py
Python
Legacy/legacy/L_2D.py
puat133/MCMC-MultiSPDE
2beca39f32c0cdd7664baeacd495b193850d8e7d
[ "Apache-2.0" ]
1
2020-06-23T09:32:43.000Z
2020-06-23T09:32:43.000Z
Legacy/legacy/L_2D.py
puat133/MCMC-MultiSPDE
2beca39f32c0cdd7664baeacd495b193850d8e7d
[ "Apache-2.0" ]
null
null
null
Legacy/legacy/L_2D.py
puat133/MCMC-MultiSPDE
2beca39f32c0cdd7664baeacd495b193850d8e7d
[ "Apache-2.0" ]
null
null
null
import numpy as np import numba as nb import mcmc.L as L import mcmc.util_2D as u2 import mcmc.util as util import mcmc.fourier_2D as f2 # fourier_type = nb.deferred_type() # fourier_type.define(f2.FourierAnalysis_2D.class_type.instance_type) # spec = [ # ('fourier',fourier_type), # ('sqrt_beta',nb.float64), # ('current_L',nb.complex128[:,:]), # ('latest_computed_L',nb.complex128[:,:]), # ] # @nb.jitclass(spec) # # class Lmatrix_2D(L.Lmatrix): # class Lmatrix_2D: # def __init__(self,f,sqrt_beta): # self.fourier = f # self.sqrt_beta = sqrt_beta # #initialize self.lastComputedL as zero # self.current_L = np.zeros(((2*self.fourier.fourier_basis_number-1)**2,(2*self.fourier.fourier_basis_number-1)**2),dtype=np.complex128) # self.latest_computed_L = self.current_L # def construct_from(self,uHalf): # assert uHalf.shape[0] == self.fourier.fourier_basis_number # Ku_pow_min_nu = self.fourier.constructMatexplicit(uHalf,u2.kappa_pow_min_nu) # Ku_pow_half = self.fourier.constructMatexplicit(uHalf,u2.kappa_pow_half) # L = ( util.matMulti(Ku_pow_min_nu,self.fourier.Dmatrix) - Ku_pow_half)/self.sqrt_beta # #set LatestComputedL as L, but dont change currentL # self.latest_computed_L = L # return L # def logDet(self): # """ # # The determinant of a Hermitian matrix is real;the determinant is the product of the matrix's eigenvalues # # L^dagger L is Hermitian # """ # return (np.linalg.slogdet(self.current_L)[1]) # def set_current_L_to_latest(self): # self.current_L = self.latest_computed_L.copy() # def is_current_L_equals_to_the_latest(self): # return np.all(self.current_L == self.latest_computed_L)
35.921569
144
0.666485
260
1,832
4.434615
0.319231
0.055507
0.065048
0.065915
0.24111
0.215958
0.189072
0.055507
0
0
0
0.020083
0.21179
1,832
51
145
35.921569
0.778393
0.865721
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
4
cb8942c06dd1d6297739bd8485625f76b776756d
209
py
Python
application/summary/kg/dbpedia/DBpediaEN.py
librairy/extractiveQA-over-KG
31107fe16e642ceac06c0fbb0a73ad04ba196655
[ "Apache-2.0" ]
1
2022-02-07T16:56:36.000Z
2022-02-07T16:56:36.000Z
application/summary/kg/dbpedia/DBpediaEN.py
librairy/extractiveQA-over-KG
31107fe16e642ceac06c0fbb0a73ad04ba196655
[ "Apache-2.0" ]
5
2021-11-30T11:25:47.000Z
2021-11-30T12:15:59.000Z
application/summary/kg/dbpedia/DBpediaEN.py
librairy/extractiveQA-over-KG
31107fe16e642ceac06c0fbb0a73ad04ba196655
[ "Apache-2.0" ]
null
null
null
import application.summary.kg.dbpedia.DBpedia as dbpedia class DBpediaEN(dbpedia.DBpedia): def __init__(self,url="http://dbpedia.org/sparql",rules=True): super().__init__("en",url,rules)
26.125
67
0.703349
27
209
5.148148
0.703704
0.201439
0
0
0
0
0
0
0
0
0
0
0.148325
209
7
68
29.857143
0.780899
0
0
0
0
0
0.133663
0
0
0
0
0
0
1
0.25
false
0
0.25
0
0.75
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
1
0
0
0
0
0
0
0
4
cba4cf5051d4563e567eb5098da90fff2c0b7786
306
py
Python
HelloWorld.py
SaharaPalacios/NegShifting
a2f6dd0d60a3d8375d9a96f678009654f1c85936
[ "MIT" ]
null
null
null
HelloWorld.py
SaharaPalacios/NegShifting
a2f6dd0d60a3d8375d9a96f678009654f1c85936
[ "MIT" ]
2
2020-07-14T17:45:33.000Z
2020-07-28T16:51:33.000Z
HelloWorld.py
SaharaPalacios/NegShifting
a2f6dd0d60a3d8375d9a96f678009654f1c85936
[ "MIT" ]
1
2020-07-13T17:20:19.000Z
2020-07-13T17:20:19.000Z
#################################################################################### # # HelloWorld.py # # Practice for git push and pull # # M. Brinkerhoff * UCSC, SIP2020 * 2020 July 14 (Tu) # #################################################################################### print("Hello World!")
27.818182
84
0.284314
19
306
4.578947
1
0
0
0
0
0
0
0
0
0
0
0.036496
0.104575
306
11
85
27.818182
0.281022
0.316993
0
0
0
0
0.375
0
0
0
0
0
0
1
0
true
0
0
0
0
1
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
1
0
4
cbc8d4e55d616755dbc203b5d4f5c8dc6947050d
197
py
Python
trojsten/settings/kms.py
MvonK/web
b701a6ea8fb6f0bdfb720e66d0a430db13db8bff
[ "MIT" ]
5
2018-04-22T22:44:02.000Z
2021-04-26T20:44:44.000Z
trojsten/settings/kms.py
MvonK/web
b701a6ea8fb6f0bdfb720e66d0a430db13db8bff
[ "MIT" ]
250
2018-04-24T12:04:11.000Z
2022-03-09T06:56:47.000Z
trojsten/settings/kms.py
MvonK/web
b701a6ea8fb6f0bdfb720e66d0a430db13db8bff
[ "MIT" ]
8
2019-04-28T11:33:03.000Z
2022-02-26T13:30:36.000Z
from trojsten.settings.production import * SITE_ID = 4 NAVBAR_SITES = [9, 1, 3, 11, 5] SUBMIT_DESCRIPTION_ALLOWED_EXTENSIONS = [".pdf"] SUBMIT_DESCRIPTION_ALLOWED_MIMETYPES = ["application/pdf"]
24.625
58
0.771574
26
197
5.538462
0.846154
0.236111
0.333333
0
0
0
0
0
0
0
0
0.04
0.111675
197
7
59
28.142857
0.782857
0
0
0
0
0
0.096447
0
0
0
0
0
0
1
0
false
0
0.2
0
0.2
0
1
0
0
null
1
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
4
cbd93b8ebf6fd0fd2bea6c0e69c9e9af98c57bb0
3,176
py
Python
labs/lab02/lab02Tests.py
tntptntp/CMPTGCS-20
f9fbb32199c2b415614e914a84560a2080949965
[ "MIT" ]
null
null
null
labs/lab02/lab02Tests.py
tntptntp/CMPTGCS-20
f9fbb32199c2b415614e914a84560a2080949965
[ "MIT" ]
null
null
null
labs/lab02/lab02Tests.py
tntptntp/CMPTGCS-20
f9fbb32199c2b415614e914a84560a2080949965
[ "MIT" ]
null
null
null
# lab02Tests.py Tests for lab02, UCSB CMPTGCS 20, T. Penebaker, 04/14/2016 import unittest # this is so we can set up testing of functions # the imports below import the functions we want to test from lab02Funcs import * class TestLab02Functions(unittest.TestCase): # This is how you do testing in Python # Every test case should be a function definition # The name should start with test_ and the parameter should be "self". # Then, you can write tests using self.assertEqual(actual, expected) and # self.assertAlmostEquals(actual, expected, numberOfDecimalPlaces) # # If an answer should be exact (e.g. integer math), use assertEqual # If an answer is approximate (floating pt math, square roots, pi, etc.) # use assertAlmostEqual # Test perimRect def test_perimRect1(self): self.assertEqual(perimRect(2,3), 10) def test_perimRect2(self): self.assertAlmostEqual(perimRect(4,2.5), 13.0, 2) # accurate to two decimal places def test_perimRect3(self): self.assertEqual(perimRect(3,3), 12) # Test areaRect def test_areaRect1(self): self.assertEqual(areaRect(2,3), 6) def test_areaRect2(self): self.assertAlmostEqual(areaRect(4,2.5), 10) def test_areaRect3(self): self.assertEqual(areaRect(3,3), 9) # Test isList def test_isList1(self): self.assertEqual( isList(3), False) def test_isList2(self): self.assertEqual( isList([3]), True) def test_isList3(self): self.assertEqual( isList([5,10,15,20]), True) def test_isList4(self): self.assertEqual( isList("foo"), False) def test_isList5(self): self.assertEqual( isList(["John","Paul","Ringo","George"]), True) def test_isList6(self): self.assertEqual( isList([]), True) # Test isString def test_isString1(self): self.assertEqual(isString(""),True) def test_isString2(self): self.assertEqual(isString("derp"),True) def test_isString3(self): self.assertEqual(isString(["derp"]),False) def test_isString4(self): self.assertEqual(isString(42),False) # tests for isPrimaryColor def test_isPrimaryColor1(self): self.assertEqual( isAdditivePrimaryColor("blue"), True) def test_isPrimaryColor2(self): self.assertEqual( isAdditivePrimaryColor("black"), False) def test_isPrimaryColor3(self): self.assertEqual( isAdditivePrimaryColor(42), False) # tests for isSimpleNumeric def test_isSimpleNumeric1(self): self.assertEqual( isSimpleNumeric(5), True) def test_isSimpleNumeric2(self): self.assertEqual( isSimpleNumeric(3.5), True) def test_isSimpleNumeric3(self): self.assertEqual( isSimpleNumeric("5"), False) def test_isSimpleNumeric4(self): self.assertEqual( isSimpleNumeric([5]), False) def test_isSimpleNumeric5(self): self.assertEqual( isSimpleNumeric(6.0221415E23), True) # This code says: when you run this file, run the tests! if __name__ == '__main__': unittest.main(exit=False)
29.682243
85
0.668136
381
3,176
5.48294
0.380577
0.080421
0.200096
0.071805
0.116324
0.044998
0.044998
0.044998
0
0
0
0.039056
0.226071
3,176
106
86
29.962264
0.810822
0.258186
0
0
0
0
0.020557
0
0
0
0
0
0.45283
1
0.45283
false
0
0.037736
0
0.509434
0
0
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
1
0
1
0
0
0
0
1
0
0
4
1db93604584d9835fd0fb16311461a0c46d9dc1c
245
py
Python
goflow/graphics/urls_admin.py
mikewolfli/django2-goflow
136afbfd90205ee83b2d50ac1be6a6b207fbcdf8
[ "MIT" ]
10
2018-08-10T15:07:29.000Z
2021-11-05T23:14:47.000Z
goflow/graphics/urls_admin.py
mikewolfli/django2-goflow
136afbfd90205ee83b2d50ac1be6a6b207fbcdf8
[ "MIT" ]
5
2019-11-20T06:09:00.000Z
2022-03-11T23:26:40.000Z
goflow/graphics/urls_admin.py
mikewolfli/django2-goflow
136afbfd90205ee83b2d50ac1be6a6b207fbcdf8
[ "MIT" ]
1
2018-08-10T15:07:37.000Z
2018-08-10T15:07:37.000Z
from django.urls import path from django.conf.urls.defaults import * from goflow.graphics import views as goflow_graphics_views urlpatterns = [ path('processimage/<int:process_id>/pos_activity/', goflow_graphics_views.pos_activity), ]
35
93
0.787755
33
245
5.636364
0.545455
0.225806
0.204301
0
0
0
0
0
0
0
0
0
0.122449
245
6
94
40.833333
0.865116
0
0
0
0
0
0.179916
0.179916
0
0
0
0
0
1
0
false
0
0.5
0
0.5
0
0
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
1
0
0
0
0
4
381091678bae3d07cc9b486c81cba8495a15ee23
162
py
Python
problem0213.py
kmarcini/Project-Euler-Python
d644e8e1ec4fac70a9ab407ad5e1f0a75547c8d3
[ "BSD-3-Clause" ]
null
null
null
problem0213.py
kmarcini/Project-Euler-Python
d644e8e1ec4fac70a9ab407ad5e1f0a75547c8d3
[ "BSD-3-Clause" ]
null
null
null
problem0213.py
kmarcini/Project-Euler-Python
d644e8e1ec4fac70a9ab407ad5e1f0a75547c8d3
[ "BSD-3-Clause" ]
null
null
null
########################### # # #213 Flea Circus - Project Euler # https://projecteuler.net/problem=213 # # Code by Kevin Marciniak # ###########################
18
38
0.462963
14
162
5.357143
0.928571
0
0
0
0
0
0
0
0
0
0
0.041958
0.117284
162
8
39
20.25
0.482517
0.567901
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