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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
c01922655ec41e4d6fc3470bad1df3adf182d0aa
| 126
|
py
|
Python
|
cryptofeed_werks/exchanges/ftx/__init__.py
|
globophobe/crypto-tick-data
|
7ec5d1e136b9bc27ae936f55cf6ab7fe5e37bda4
|
[
"MIT"
] | null | null | null |
cryptofeed_werks/exchanges/ftx/__init__.py
|
globophobe/crypto-tick-data
|
7ec5d1e136b9bc27ae936f55cf6ab7fe5e37bda4
|
[
"MIT"
] | null | null | null |
cryptofeed_werks/exchanges/ftx/__init__.py
|
globophobe/crypto-tick-data
|
7ec5d1e136b9bc27ae936f55cf6ab7fe5e37bda4
|
[
"MIT"
] | null | null | null |
from .constants import BTCMOVE
from .controllers import ftx_move, ftx_trades
__all__ = ["BTCMOVE", "ftx_trades", "ftx_move"]
| 25.2
| 47
| 0.769841
| 17
| 126
| 5.235294
| 0.529412
| 0.157303
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.119048
| 126
| 4
| 48
| 31.5
| 0.801802
| 0
| 0
| 0
| 0
| 0
| 0.198413
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.666667
| 0
| 0.666667
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
|
0
| 4
|
c0205242039181a756652c0ddd7b0a4d20c1f7f3
| 3,111
|
py
|
Python
|
test/test_analytics_api.py
|
billforward/bf-python
|
d2b812329ca3ed1fd94364d7f46f69ad74665596
|
[
"Apache-2.0"
] | 2
|
2016-11-23T17:32:37.000Z
|
2022-02-24T05:13:20.000Z
|
test/test_analytics_api.py
|
billforward/bf-python
|
d2b812329ca3ed1fd94364d7f46f69ad74665596
|
[
"Apache-2.0"
] | null | null | null |
test/test_analytics_api.py
|
billforward/bf-python
|
d2b812329ca3ed1fd94364d7f46f69ad74665596
|
[
"Apache-2.0"
] | 1
|
2016-12-30T20:02:48.000Z
|
2016-12-30T20:02:48.000Z
|
# coding: utf-8
"""
BillForward REST API
OpenAPI spec version: 1.0.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 billforward
from billforward.rest import ApiException
from billforward.apis.analytics_api import AnalyticsApi
class TestAnalyticsApi(unittest.TestCase):
""" AnalyticsApi unit test stubs """
def setUp(self):
self.api = billforward.apis.analytics_api.AnalyticsApi()
def tearDown(self):
pass
def test_get_account_debts(self):
"""
Test case for get_account_debts
Gets outstanding debts per account, within a date range.
"""
pass
def test_get_account_ltv(self):
"""
Test case for get_account_ltv
Gets an account's life-time value, as of a given end date.
"""
pass
def test_get_account_payments(self):
"""
Test case for get_account_payments
Gets hourly payments per product, within a date range.
"""
pass
def test_get_billforward_managed_payments(self):
"""
Test case for get_billforward_managed_payments
Gets all payments managed by BillForward, within a date range.
"""
pass
def test_get_churn(self):
"""
Test case for get_churn
Gets churn, within a date range.
"""
pass
def test_get_debts(self):
"""
Test case for get_debts
Gets debts within a date range.
"""
pass
def test_get_payments(self):
"""
Test case for get_payments
Gets payments within a date range.
"""
pass
def test_get_product_payments(self):
"""
Test case for get_product_payments
Gets hourly payments per product, within a date range.
"""
pass
def test_get_product_rate_plan_payments(self):
"""
Test case for get_product_rate_plan_payments
Gets hourly payments per product, within a date range.
"""
pass
def test_get_subscription_ltv(self):
"""
Test case for get_subscription_ltv
Gets a subscription's life-time value, as of a given end date.
"""
pass
def test_get_upgrades(self):
"""
Test case for get_upgrades
Gets upgrades, within a date range.
"""
pass
if __name__ == '__main__':
unittest.main()
| 23.044444
| 76
| 0.634201
| 397
| 3,111
| 4.798489
| 0.319899
| 0.04042
| 0.063517
| 0.08084
| 0.426247
| 0.370079
| 0.271916
| 0.23727
| 0.174278
| 0.151181
| 0
| 0.003676
| 0.300546
| 3,111
| 134
| 77
| 23.216418
| 0.871783
| 0.514626
| 0
| 0.333333
| 1
| 0
| 0.007253
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.361111
| false
| 0.333333
| 0.194444
| 0
| 0.583333
| 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
| 0
| 1
| 0
|
0
| 4
|
c0233718f62cfd225ac746308d100ae4c4eb96c3
| 391
|
py
|
Python
|
tests/test_testprog.py
|
DavinderJolly/pytest-testprog
|
2b0e39bb0eb072bfc12993a388a80a8b51ac96c4
|
[
"MIT"
] | null | null | null |
tests/test_testprog.py
|
DavinderJolly/pytest-testprog
|
2b0e39bb0eb072bfc12993a388a80a8b51ac96c4
|
[
"MIT"
] | null | null | null |
tests/test_testprog.py
|
DavinderJolly/pytest-testprog
|
2b0e39bb0eb072bfc12993a388a80a8b51ac96c4
|
[
"MIT"
] | null | null | null |
# -*- coding: utf-8 -*-
import time
def test_foo():
"""Test.
First test
"""
time.sleep(2)
assert True
def test_bar():
"""Test.
Second test
"""
time.sleep(2)
assert True
def test_baz():
"""Test.
Third test
"""
time.sleep(2)
assert False
def test_buz():
"""Test.
Fourth test
"""
time.sleep(2)
assert True
| 11.171429
| 23
| 0.508951
| 49
| 391
| 3.979592
| 0.408163
| 0.14359
| 0.266667
| 0.287179
| 0.54359
| 0.441026
| 0.317949
| 0.317949
| 0
| 0
| 0
| 0.019231
| 0.335038
| 391
| 34
| 24
| 11.5
| 0.730769
| 0.235294
| 0
| 0.538462
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.307692
| 1
| 0.307692
| true
| 0
| 0.076923
| 0
| 0.384615
| 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
| 1
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
c0309bcb6cf5cdf33fe5481194347cbc0e76d4ac
| 102
|
py
|
Python
|
smartystreets_python_sdk_version/__init__.py
|
jasonrfarkas/smartystreets-python-sdk
|
bcb94efc09c795222eb1bd85544073a6cc063a46
|
[
"Apache-2.0"
] | 19
|
2017-01-20T16:34:19.000Z
|
2021-12-09T15:56:09.000Z
|
smartystreets_python_sdk_version/__init__.py
|
jasonrfarkas/smartystreets-python-sdk
|
bcb94efc09c795222eb1bd85544073a6cc063a46
|
[
"Apache-2.0"
] | 25
|
2016-12-11T01:20:19.000Z
|
2022-03-24T19:59:25.000Z
|
smartystreets_python_sdk_version/__init__.py
|
jasonrfarkas/smartystreets-python-sdk
|
bcb94efc09c795222eb1bd85544073a6cc063a46
|
[
"Apache-2.0"
] | 28
|
2016-12-31T17:06:07.000Z
|
2022-02-17T00:09:02.000Z
|
__version__ = '0.0.0' # DO NOT EDIT (this is updated by a build job when a new release is published)
| 51
| 101
| 0.715686
| 20
| 102
| 3.45
| 0.8
| 0.057971
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.037037
| 0.205882
| 102
| 1
| 102
| 102
| 0.814815
| 0.745098
| 0
| 0
| 1
| 0
| 0.208333
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
c035b072727964bbafb393e63911ac8fa5dacbc9
| 159
|
py
|
Python
|
processing.py
|
Qwinpin/NeuroDemo
|
52220dd2904e96485ce92adb171e68522915a1fb
|
[
"MIT"
] | 1
|
2021-03-09T22:59:55.000Z
|
2021-03-09T22:59:55.000Z
|
processing.py
|
Qwinpin/NeuroDemo
|
52220dd2904e96485ce92adb171e68522915a1fb
|
[
"MIT"
] | null | null | null |
processing.py
|
Qwinpin/NeuroDemo
|
52220dd2904e96485ce92adb171e68522915a1fb
|
[
"MIT"
] | null | null | null |
import numpy as np
import loader
import responser
def processing(data):
data = loader.load(data)
# perform something
return responser.save(data)
| 15.9
| 31
| 0.72956
| 21
| 159
| 5.52381
| 0.666667
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.201258
| 159
| 9
| 32
| 17.666667
| 0.913386
| 0.106918
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.166667
| false
| 0
| 0.5
| 0
| 0.833333
| 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
|
c03756a16758d98d8cd8aacec7780bbd24b33179
| 1,204
|
py
|
Python
|
dataprofiler/labelers/__init__.py
|
gautomdas/DataProfiler
|
7afaa61a814c1bf24c51272dc2aa657397d9f1e5
|
[
"Apache-2.0"
] | 690
|
2021-02-19T19:57:31.000Z
|
2022-03-29T23:08:39.000Z
|
dataprofiler/labelers/__init__.py
|
gautomdas/DataProfiler
|
7afaa61a814c1bf24c51272dc2aa657397d9f1e5
|
[
"Apache-2.0"
] | 179
|
2021-02-17T20:49:16.000Z
|
2022-03-21T18:49:49.000Z
|
dataprofiler/labelers/__init__.py
|
gautomdas/DataProfiler
|
7afaa61a814c1bf24c51272dc2aa657397d9f1e5
|
[
"Apache-2.0"
] | 48
|
2021-02-19T19:25:32.000Z
|
2022-03-21T17:36:50.000Z
|
"""
The following will list the built-in models, processors, and data labelers.
Models:
1. CharacterLevelCnnModel - character classification of text.
2. RegexModel - character classification of text.
Processors:
Preprocessors
1. CharPreprocessor
2. StructCharPreprocessor
3. DirectPassPreprocessor
PostProcessors
1. CharPreprocessor
2. StructCharPostprocessor
3. RegexPostProcessor
Data Labelers:
Classes
1. UnstructuredDataLabeler
2. StructuredDataLabeler
Files to load from disk using `BaseDataLabeler.load_from_library(<NAME>)`
1. unstructured_model
2. structured_model
3. regex_model
"""
# import models
from .base_data_labeler import BaseDataLabeler
# import data processors
from .data_processing import CharPreprocessor, CharPostprocessor, \
StructCharPreprocessor, StructCharPostprocessor, \
DirectPassPreprocessor, RegexPostProcessor
# import data labelers
from .base_data_labeler import BaseDataLabeler, TrainableDataLabeler
from .data_labelers import DataLabeler, StructuredDataLabeler, \
UnstructuredDataLabeler
| 29.365854
| 79
| 0.7201
| 105
| 1,204
| 8.152381
| 0.47619
| 0.056075
| 0.058411
| 0.067757
| 0.093458
| 0.093458
| 0
| 0
| 0
| 0
| 0
| 0.0141
| 0.234219
| 1,204
| 40
| 80
| 30.1
| 0.914317
| 0.630399
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0.142857
| 0.571429
| 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
|
c05a2b49b31692e02c080d4cb26b6221aa7bec8f
| 1,805
|
py
|
Python
|
DBMan.py
|
Alux-Alpha/Encr_Pass_Repo
|
8b7218b2e4695eff8b1253bdc224dcc8a43cd330
|
[
"MIT"
] | null | null | null |
DBMan.py
|
Alux-Alpha/Encr_Pass_Repo
|
8b7218b2e4695eff8b1253bdc224dcc8a43cd330
|
[
"MIT"
] | null | null | null |
DBMan.py
|
Alux-Alpha/Encr_Pass_Repo
|
8b7218b2e4695eff8b1253bdc224dcc8a43cd330
|
[
"MIT"
] | null | null | null |
# MIT License
# Copyright (c) 2020 Nehal Gowrish (Alias: Alanthiel)
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
# The above copyright notice and this permission notice shall be included in all
# copies or substantial portions of the Software.
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.
from dataclasses import dataclass, asdict, astuple
import Auth
# TODO: Deploy JSON based Encrypted Store using Auth module
# TODO: Deploy sqlcipher based Encrypted Store
@dataclass(repr=False, unsafe_hash=True)
class Bundle:
dbid: str = None
platform: str = None
userid: str = None
password: str = None
backup_codes: list = None
serectkey: str = None
def __repr__(self):
return "Credentials (Platform: {}, User Id: {}".format(self.platform, self.userid)
def check_codes(self):
if self.backup_codes is None:
return False
class DataBase:
def __init__(self, db_path="store.sql"):
return NotImplemented
| 34.056604
| 90
| 0.741828
| 258
| 1,805
| 5.139535
| 0.565891
| 0.066365
| 0.019608
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.002755
| 0.195568
| 1,805
| 52
| 91
| 34.711538
| 0.910468
| 0.657618
| 0
| 0
| 0
| 0
| 0.078727
| 0
| 0
| 0
| 0
| 0.019231
| 0
| 1
| 0.166667
| false
| 0.055556
| 0.111111
| 0.111111
| 0.888889
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 1
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 1
| 0
|
0
| 4
|
fbe4bbb9bd38d8c11456d7278b8b0fab29cd97b2
| 469
|
py
|
Python
|
test/creational/test_abstract_factory.py
|
BruceWW/python_designer_pattern
|
c5f8b5ee32c8984401b4a217fa35364170331063
|
[
"Apache-2.0"
] | 1
|
2020-08-29T09:17:12.000Z
|
2020-08-29T09:17:12.000Z
|
test/creational/test_abstract_factory.py
|
BruceWW/python_design_pattern
|
c5f8b5ee32c8984401b4a217fa35364170331063
|
[
"Apache-2.0"
] | null | null | null |
test/creational/test_abstract_factory.py
|
BruceWW/python_design_pattern
|
c5f8b5ee32c8984401b4a217fa35364170331063
|
[
"Apache-2.0"
] | null | null | null |
#!/usr/bin/python3
# -*- coding: utf-8 -*-
# @Date : 2020/8/10
# @Author : Bruce Liu /Lin Luo
# @Mail : 15869300264@163.com
from unittest import TestCase
class TestCreation(TestCase):
def test_abstract_factory(self):
pass
def test_builder(self):
pass
def test_factory_method(self):
pass
def test_factory_prototype(self):
pass
def test_singleton(self):
pass
def test_example(self):
pass
| 17.37037
| 37
| 0.622601
| 59
| 469
| 4.79661
| 0.59322
| 0.14841
| 0.194346
| 0.265018
| 0.155477
| 0
| 0
| 0
| 0
| 0
| 0
| 0.067449
| 0.272921
| 469
| 26
| 38
| 18.038462
| 0.762463
| 0.251599
| 0
| 0.428571
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.428571
| false
| 0.428571
| 0.071429
| 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
| 1
| 0
| 1
| 0
| 0
| 0
| 0
|
0
| 4
|
2238b8b0d086d0c0e496cc174258d132dfbd557d
| 1,605
|
py
|
Python
|
JumpToClass.py
|
kanarinios/JumpToClass
|
173d320f7768a439d27400c81e73771f4c0d664f
|
[
"MIT"
] | null | null | null |
JumpToClass.py
|
kanarinios/JumpToClass
|
173d320f7768a439d27400c81e73771f4c0d664f
|
[
"MIT"
] | null | null | null |
JumpToClass.py
|
kanarinios/JumpToClass
|
173d320f7768a439d27400c81e73771f4c0d664f
|
[
"MIT"
] | null | null | null |
import sublime
import sublime_plugin
import re
class JumpToClassCommand(sublime_plugin.TextCommand):
def run(self, edit):
settings = self.view.settings()
separator = settings.get("jump_to_class_separator")
old_word_separators = settings.get("word_separators")
jump_to_class_word_separators = settings.get("jump_to_class_word_separators")
settings.set("word_separators", jump_to_class_word_separators)
for sel in self.view.sel():
if sel.empty():
sel = self.view.word(sel)
word_sel = self.view.substr(sel)
word_sel = word_sel.replace(separator, ' ')
self.view.window().run_command("show_overlay", {"overlay": "goto", "text": word_sel})
self.view.window().run_command("insert", {"characters": " "})
settings.set("word_separators", old_word_separators)
class SearchForWord(sublime_plugin.TextCommand):
def run(self, edit):
settings = self.view.settings()
old_word_separators = settings.get("word_separators")
jump_to_class_word_separators = settings.get("jump_to_class_word_separators")
settings.set("word_separators", jump_to_class_word_separators)
for sel in self.view.sel():
if sel.empty():
sel = self.view.word(sel)
word_sel = self.view.substr(sel)
self.view.window().run_command("show_panel", { 'panel': 'find_in_files' } )
self.view.window().run_command("insert", {"characters": word_sel})
settings.set("word_separators", old_word_separators)
| 40.125
| 97
| 0.65919
| 195
| 1,605
| 5.128205
| 0.205128
| 0.224
| 0.077
| 0.09
| 0.817
| 0.795
| 0.736
| 0.572
| 0.572
| 0.572
| 0
| 0
| 0.219315
| 1,605
| 39
| 98
| 41.153846
| 0.798085
| 0
| 0
| 0.645161
| 0
| 0
| 0.161994
| 0.050467
| 0
| 0
| 0
| 0
| 0
| 1
| 0.064516
| false
| 0
| 0.096774
| 0
| 0.225806
| 0
| 0
| 0
| 0
| null | 1
| 0
| 0
| 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
223d854e3deb817d73bbf88f5c2ad880e7dc066e
| 199
|
py
|
Python
|
textX-LS/core/textx_ls_core/languages/textx/__init__.py
|
goto40/textX-LS
|
a6b357186f7adaf7c30aed4d543ae8d149c80a25
|
[
"MIT"
] | null | null | null |
textX-LS/core/textx_ls_core/languages/textx/__init__.py
|
goto40/textX-LS
|
a6b357186f7adaf7c30aed4d543ae8d149c80a25
|
[
"MIT"
] | null | null | null |
textX-LS/core/textx_ls_core/languages/textx/__init__.py
|
goto40/textX-LS
|
a6b357186f7adaf7c30aed4d543ae8d149c80a25
|
[
"MIT"
] | null | null | null |
from .. import LanguageTemplate
class TextXLang(LanguageTemplate):
@property
def extensions(self):
return ['tx']
@property
def language_name(self):
return 'TextX'
| 15.307692
| 34
| 0.643216
| 19
| 199
| 6.684211
| 0.736842
| 0.173228
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.261307
| 199
| 12
| 35
| 16.583333
| 0.863946
| 0
| 0
| 0.25
| 0
| 0
| 0.035176
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.25
| false
| 0
| 0.125
| 0.25
| 0.75
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 1
| 1
| 0
|
0
| 4
|
223ff98a520f088c06f0054f026fe756043c5be7
| 81
|
py
|
Python
|
Init.py
|
furti/FreeCAD-Lithophane
|
5b6de36a20ecb49d26e27154788117f1e9785f40
|
[
"MIT"
] | 21
|
2018-06-10T04:00:06.000Z
|
2022-02-20T12:20:00.000Z
|
Init.py
|
furti/FreeCAD-Lithophane
|
5b6de36a20ecb49d26e27154788117f1e9785f40
|
[
"MIT"
] | 37
|
2018-06-24T06:49:23.000Z
|
2021-11-05T13:49:15.000Z
|
Init.py
|
furti/FreeCAD-Lithophane
|
5b6de36a20ecb49d26e27154788117f1e9785f40
|
[
"MIT"
] | 4
|
2018-09-28T00:05:26.000Z
|
2022-01-15T21:18:10.000Z
|
# Setup Preferences
from utils import preferences
preferences.setupParameters()
| 16.2
| 29
| 0.839506
| 8
| 81
| 8.5
| 0.75
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.111111
| 81
| 5
| 30
| 16.2
| 0.944444
| 0.209877
| 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
|
224cd58e54e427d325b66f9920bfda8af5b3fc56
| 66
|
py
|
Python
|
tests/modules/__init__.py
|
RecursionSpace/OpenPod
|
92fefd23ea76aadee3b7b243d1a65c1170e6a2e4
|
[
"MIT"
] | 1
|
2022-02-18T06:30:32.000Z
|
2022-02-18T06:30:32.000Z
|
tests/modules/__init__.py
|
RecursionSpace/OpenPod
|
92fefd23ea76aadee3b7b243d1a65c1170e6a2e4
|
[
"MIT"
] | null | null | null |
tests/modules/__init__.py
|
RecursionSpace/OpenPod
|
92fefd23ea76aadee3b7b243d1a65c1170e6a2e4
|
[
"MIT"
] | null | null | null |
''' Required for tests to recognize folder and perform tests. '''
| 33
| 65
| 0.727273
| 9
| 66
| 5.333333
| 0.888889
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.166667
| 66
| 1
| 66
| 66
| 0.872727
| 0.863636
| 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
|
2256575f1f30721f9593a1989e83c4cdd4d4e0d1
| 126
|
py
|
Python
|
utils/box/__init__.py
|
pzheng2018/MutualGuide
|
e0ea62abf128925836e4337a7fef400b135b7cbe
|
[
"MIT"
] | 124
|
2020-10-01T13:37:02.000Z
|
2022-03-25T13:31:03.000Z
|
utils/box/__init__.py
|
pzheng2018/MutualGuide
|
e0ea62abf128925836e4337a7fef400b135b7cbe
|
[
"MIT"
] | 4
|
2020-10-09T06:20:42.000Z
|
2021-12-19T22:28:50.000Z
|
utils/box/__init__.py
|
pzheng2018/MutualGuide
|
e0ea62abf128925836e4337a7fef400b135b7cbe
|
[
"MIT"
] | 18
|
2020-10-03T13:32:48.000Z
|
2021-12-21T06:13:42.000Z
|
from .box_utils import *
from .seq_matcher import SeqBoxMatcher
from .detection import Detect
from .prior_box import PriorBox
| 25.2
| 38
| 0.833333
| 18
| 126
| 5.666667
| 0.611111
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.126984
| 126
| 4
| 39
| 31.5
| 0.927273
| 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
|
3f0e8348e5072e2c6d48a56d4c5e348a51b733dd
| 550
|
py
|
Python
|
challenges/breadth_first_traversal/test_breadth_first_traversal.py
|
asakatida/data-structures-and-algorithms.py
|
587d1a66a6c15a3c7d7786275608f065687e1810
|
[
"MIT"
] | null | null | null |
challenges/breadth_first_traversal/test_breadth_first_traversal.py
|
asakatida/data-structures-and-algorithms.py
|
587d1a66a6c15a3c7d7786275608f065687e1810
|
[
"MIT"
] | 2
|
2020-09-24T13:13:49.000Z
|
2021-06-25T15:15:35.000Z
|
challenges/breadth_first_traversal/test_breadth_first_traversal.py
|
grandquista/data-structures-and-algorithms.py
|
587d1a66a6c15a3c7d7786275608f065687e1810
|
[
"MIT"
] | null | null | null |
from .breadth_first_traversal import breadth_first_traversal
def test_empty_bst_breadth_first(new_bst):
breadth_first_traversal(new_bst)
def test_filled_bst_breadth_first(filled_bst):
breadth_first_traversal(filled_bst)
def test_left_bst_breadth_first(left_bst):
breadth_first_traversal(left_bst)
def test_right_bst_breadth_first(right_bst):
breadth_first_traversal(right_bst)
def test_right_bst_breadth_first_ordering(right_bst):
lst = []
right_bst.breadth_first(lst.append)
assert lst == list(range(-9, 9, 3))
| 22.916667
| 60
| 0.807273
| 83
| 550
| 4.819277
| 0.253012
| 0.36
| 0.375
| 0.24
| 0.15
| 0.15
| 0.15
| 0
| 0
| 0
| 0
| 0.006198
| 0.12
| 550
| 23
| 61
| 23.913043
| 0.820248
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.076923
| 1
| 0.384615
| false
| 0
| 0.076923
| 0
| 0.461538
| 0
| 0
| 0
| 0
| null | 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
3f100a4f4d874496148e59cb0d296361e179b64c
| 173
|
py
|
Python
|
tests/test_tutorial/test_settings/test_app02.py
|
parampavar/fastapi
|
4e77737a3f7bf2608132ea170e9ff013b5af6732
|
[
"MIT"
] | 2
|
2020-07-17T21:33:28.000Z
|
2020-07-17T21:33:38.000Z
|
tests/test_tutorial/test_settings/test_app02.py
|
parampavar/fastapi
|
4e77737a3f7bf2608132ea170e9ff013b5af6732
|
[
"MIT"
] | 1
|
2021-07-24T15:25:13.000Z
|
2021-07-24T15:25:13.000Z
|
tests/test_tutorial/test_settings/test_app02.py
|
parampavar/fastapi
|
4e77737a3f7bf2608132ea170e9ff013b5af6732
|
[
"MIT"
] | 1
|
2020-04-19T17:43:43.000Z
|
2020-04-19T17:43:43.000Z
|
from fastapi.testclient import TestClient
from settings.app02 import main, test_main
client = TestClient(main.app)
def test_setting_override():
test_main.test_app()
| 17.3
| 42
| 0.791908
| 24
| 173
| 5.5
| 0.541667
| 0.121212
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.013333
| 0.132948
| 173
| 9
| 43
| 19.222222
| 0.866667
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 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
|
3f3f7a4179b554aabf2e22bdaac01ec61e68b68d
| 192
|
py
|
Python
|
challenges/2020/19-monsterMessages/python/partOne.py
|
codemicro/adventOfCode
|
53574532ece1d19e5f5ba2f39e8e183c4c6225a1
|
[
"MIT"
] | 9
|
2020-12-06T23:18:30.000Z
|
2021-12-19T22:31:26.000Z
|
challenges/2020/19-monsterMessages/python/partOne.py
|
codemicro/adventOfCode
|
53574532ece1d19e5f5ba2f39e8e183c4c6225a1
|
[
"MIT"
] | null | null | null |
challenges/2020/19-monsterMessages/python/partOne.py
|
codemicro/adventOfCode
|
53574532ece1d19e5f5ba2f39e8e183c4c6225a1
|
[
"MIT"
] | 3
|
2020-12-08T09:45:44.000Z
|
2020-12-15T19:20:20.000Z
|
from common import *
import re
def partOne(instr: str) -> int:
rules, messages = parse(instr)
rule_regex = re.compile(make_ruleset_regex(rules))
return run(messages, rule_regex)
| 21.333333
| 54
| 0.713542
| 27
| 192
| 4.925926
| 0.703704
| 0.135338
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.182292
| 192
| 8
| 55
| 24
| 0.847134
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 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
|
3f57751b32845ff9a7c18dd2dfbde89e5a38e8c2
| 145
|
py
|
Python
|
meteo/db/engine.py
|
bpptkg/bpptkg-meteo
|
8b554c58ffa5bc41377e8bdde7434abaaae49c27
|
[
"MIT"
] | null | null | null |
meteo/db/engine.py
|
bpptkg/bpptkg-meteo
|
8b554c58ffa5bc41377e8bdde7434abaaae49c27
|
[
"MIT"
] | 2
|
2021-11-22T03:42:28.000Z
|
2022-01-13T09:26:06.000Z
|
meteo/db/engine.py
|
bpptkg/bpptkg-meteo
|
8b554c58ffa5bc41377e8bdde7434abaaae49c27
|
[
"MIT"
] | null | null | null |
def prepare(base_class, engine):
"""
Reflect base class to current database engine.
"""
base_class.prepare(engine, reflect=True)
| 24.166667
| 50
| 0.682759
| 18
| 145
| 5.388889
| 0.555556
| 0.278351
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.206897
| 145
| 5
| 51
| 29
| 0.843478
| 0.317241
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.5
| false
| 0
| 0
| 0
| 0.5
| 0
| 1
| 0
| 0
| null | 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
3f6efe1f991880527e3683966ca7f0ce6cd60c4b
| 27
|
py
|
Python
|
import_export/__init__.py
|
arpesanif/django-import-export
|
0bfe9c79a6825c1246bc79d0d7903b2e9bcb179f
|
[
"BSD-2-Clause"
] | null | null | null |
import_export/__init__.py
|
arpesanif/django-import-export
|
0bfe9c79a6825c1246bc79d0d7903b2e9bcb179f
|
[
"BSD-2-Clause"
] | null | null | null |
import_export/__init__.py
|
arpesanif/django-import-export
|
0bfe9c79a6825c1246bc79d0d7903b2e9bcb179f
|
[
"BSD-2-Clause"
] | null | null | null |
__version__ = '2.7.1.dev0'
| 13.5
| 26
| 0.666667
| 5
| 27
| 2.8
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.166667
| 0.111111
| 27
| 1
| 27
| 27
| 0.416667
| 0
| 0
| 0
| 0
| 0
| 0.37037
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
58cc237098b520ea246387f9622dae98c37e6a71
| 177
|
py
|
Python
|
diversity_filters/diversity_filter_parameters.py
|
marco-foscato/Lib-INVENT
|
fe6a65ab7165abd87b25752a6b4208c8703d11f7
|
[
"Apache-2.0"
] | 26
|
2021-04-30T23:21:17.000Z
|
2022-03-10T06:33:11.000Z
|
diversity_filters/diversity_filter_parameters.py
|
marco-foscato/Lib-INVENT
|
fe6a65ab7165abd87b25752a6b4208c8703d11f7
|
[
"Apache-2.0"
] | 6
|
2021-10-03T08:35:48.000Z
|
2022-03-24T09:57:39.000Z
|
diversity_filters/diversity_filter_parameters.py
|
marco-foscato/Lib-INVENT
|
fe6a65ab7165abd87b25752a6b4208c8703d11f7
|
[
"Apache-2.0"
] | 10
|
2021-04-28T14:08:17.000Z
|
2022-03-04T04:18:13.000Z
|
from dataclasses import dataclass
@dataclass
class DiversityFilterParameters:
name: str
minscore: float = 0.4
bucket_size: int = 25
minsimilarity: float = 0.4
| 17.7
| 33
| 0.717514
| 21
| 177
| 6
| 0.809524
| 0.095238
| 0.111111
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.043478
| 0.220339
| 177
| 9
| 34
| 19.666667
| 0.869565
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.142857
| 0
| 0.857143
| 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
|
58e68ead61afc8f64764972b7c4077c171239611
| 87
|
py
|
Python
|
docarray/__init__.py
|
delgermurun/docarray
|
7a868d3b37744ba9618912657198fc5b29532f06
|
[
"Apache-2.0"
] | null | null | null |
docarray/__init__.py
|
delgermurun/docarray
|
7a868d3b37744ba9618912657198fc5b29532f06
|
[
"Apache-2.0"
] | null | null | null |
docarray/__init__.py
|
delgermurun/docarray
|
7a868d3b37744ba9618912657198fc5b29532f06
|
[
"Apache-2.0"
] | null | null | null |
__version__ = '0.4.4'
from .document import Document
from .array import DocumentArray
| 17.4
| 32
| 0.781609
| 12
| 87
| 5.333333
| 0.666667
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.04
| 0.137931
| 87
| 4
| 33
| 21.75
| 0.813333
| 0
| 0
| 0
| 0
| 0
| 0.057471
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.666667
| 0
| 0.666667
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
|
0
| 4
|
45012263e47c153a5c9d9f7a0deabca424471151
| 1,747
|
py
|
Python
|
tests/elf/test_section_header.py
|
drazisil/dasm-python
|
571f1a030de92a4626b77f9ead76d60dc91efe25
|
[
"Apache-2.0"
] | 1
|
2021-08-14T12:07:19.000Z
|
2021-08-14T12:07:19.000Z
|
tests/elf/test_section_header.py
|
drazisil/dasm-python
|
571f1a030de92a4626b77f9ead76d60dc91efe25
|
[
"Apache-2.0"
] | null | null | null |
tests/elf/test_section_header.py
|
drazisil/dasm-python
|
571f1a030de92a4626b77f9ead76d60dc91efe25
|
[
"Apache-2.0"
] | null | null | null |
from dasm.elf.section_header import parse_section_header, get_sh_type
def test_parse_section_header():
bytes = (b'\x01\x02\x03\x04\x05\x02\x07\x03'
+ b'\x09\x0A\x0B\x0c\x0d\x0e\x0f'
+ b'\x10\x11\x12\x03\x00\x15\x15'
+ b'\x15\x15\x15\x15\x15\x15\x15'
+ b'\x15\x15\x15\x15\x15\x15\x15'
+ b'\x15\x15\x15\x15\x15\x15\x15'
+ b'\x15\x15\x15\x15\x15\x15\x15'
+ b'\x15\x15\x15\x15\x15\x15\x15'
+ b'\x15\x15\x15\x15\x15\x15\x15')
parse_section_header(bytes, 64)
try:
parse_section_header(bytes, 32)
assert False
except NotImplementedError:
assert True
try:
parse_section_header(bytes, 128)
assert False
except ValueError:
assert True
def test_get_sh_type():
assert get_sh_type(0) == 'SHT_NULL'
assert get_sh_type(1) == 'SHT_PROGBITS'
assert get_sh_type(2) == 'SHT_SYMTAB'
assert get_sh_type(3) == 'SHT_STRTAB'
assert get_sh_type(4) == 'SHT_RELA'
assert get_sh_type(5) == 'SHT_HASH'
assert get_sh_type(6) == 'SHT_DYNAMIC'
assert get_sh_type(7) == 'SHT_NOTE'
assert get_sh_type(8) == 'SHT_NOBITS'
assert get_sh_type(9) == 'SHT_REL'
assert get_sh_type(10) == 'SHT_SHLIB'
assert get_sh_type(11) == 'SHT_DYNSYM'
assert get_sh_type(14) == 'SHT_INIT_ARRAY'
assert get_sh_type(15) == 'SHT_FINI_ARRAY'
assert get_sh_type(16) == 'SHT_PREINIT_ARRAY'
assert get_sh_type(17) == 'SHT_GROUP'
assert get_sh_type(18) == 'SHT_SYMTAB_SHNDX'
assert get_sh_type(19) == 'SHT_NUM'
assert get_sh_type(1610612736) == 'SHT_LOOS'
try:
get_sh_type(12)
assert False
except ValueError:
assert True
| 33.596154
| 69
| 0.626216
| 273
| 1,747
| 3.714286
| 0.304029
| 0.218935
| 0.266272
| 0.284024
| 0.319527
| 0.209073
| 0.136095
| 0.136095
| 0.136095
| 0.136095
| 0
| 0.125848
| 0.240412
| 1,747
| 51
| 70
| 34.254902
| 0.638282
| 0
| 0
| 0.340426
| 0
| 0
| 0.258729
| 0.146537
| 0
| 0
| 0
| 0
| 0.531915
| 1
| 0.042553
| false
| 0
| 0.021277
| 0
| 0.06383
| 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
|
189e64943b599e54c1ff2a9c62a26dff22ec1c15
| 69
|
py
|
Python
|
EduNLP/SIF/parser/__init__.py
|
karin0018/EduNLP
|
172c36a2cd2c41a1f1c5833d7b1abcbc5e3bbd5f
|
[
"Apache-2.0"
] | 18
|
2021-02-15T13:10:42.000Z
|
2022-03-17T12:57:34.000Z
|
EduNLP/SIF/parser/__init__.py
|
karin0018/EduNLP
|
172c36a2cd2c41a1f1c5833d7b1abcbc5e3bbd5f
|
[
"Apache-2.0"
] | 81
|
2021-06-02T07:45:20.000Z
|
2022-03-29T15:21:32.000Z
|
EduNLP/SIF/parser/__init__.py
|
karin0018/EduNLP
|
172c36a2cd2c41a1f1c5833d7b1abcbc5e3bbd5f
|
[
"Apache-2.0"
] | 29
|
2021-05-18T08:34:58.000Z
|
2022-03-12T00:19:09.000Z
|
# coding: utf-8
# 2021/6/02 @ fannazya
from .parser import (Parser)
| 13.8
| 28
| 0.681159
| 11
| 69
| 4.272727
| 0.909091
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.140351
| 0.173913
| 69
| 4
| 29
| 17.25
| 0.684211
| 0.492754
| 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
|
18ec27a6ce6c2507f1b26f174d181afd45507904
| 360
|
py
|
Python
|
SimTracker/TrackerMaterialAnalysis/python/trackingMaterialAnalyser_cff.py
|
ckamtsikis/cmssw
|
ea19fe642bb7537cbf58451dcf73aa5fd1b66250
|
[
"Apache-2.0"
] | 852
|
2015-01-11T21:03:51.000Z
|
2022-03-25T21:14:00.000Z
|
SimTracker/TrackerMaterialAnalysis/python/trackingMaterialAnalyser_cff.py
|
ckamtsikis/cmssw
|
ea19fe642bb7537cbf58451dcf73aa5fd1b66250
|
[
"Apache-2.0"
] | 30,371
|
2015-01-02T00:14:40.000Z
|
2022-03-31T23:26:05.000Z
|
SimTracker/TrackerMaterialAnalysis/python/trackingMaterialAnalyser_cff.py
|
ckamtsikis/cmssw
|
ea19fe642bb7537cbf58451dcf73aa5fd1b66250
|
[
"Apache-2.0"
] | 3,240
|
2015-01-02T05:53:18.000Z
|
2022-03-31T17:24:21.000Z
|
import FWCore.ParameterSet.Config as cms
# Define arbitrary tracker material groups
from RecoTracker.GeometryESProducer.TrackerRecoGeometryESProducer_cfi import *
from SimTracker.TrackerMaterialAnalysis.trackingMaterialGroups_cff import *
# Analyze and plot the tracking material
from SimTracker.TrackerMaterialAnalysis.trackingMaterialAnalyser_cfi import *
| 40
| 78
| 0.877778
| 35
| 360
| 8.942857
| 0.742857
| 0.057508
| 0.236422
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.086111
| 360
| 8
| 79
| 45
| 0.951368
| 0.219444
| 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
|
18f1f071bf35c87367b1382fd3e2e1d765bb3112
| 149
|
py
|
Python
|
Mundo 1_Fundamentos/Desafio_14.py
|
VictorOliveira02/Desafios-Python3-Curso-em-Video
|
53ee8bd814b816f3a21936677ef3f155b582843f
|
[
"MIT"
] | null | null | null |
Mundo 1_Fundamentos/Desafio_14.py
|
VictorOliveira02/Desafios-Python3-Curso-em-Video
|
53ee8bd814b816f3a21936677ef3f155b582843f
|
[
"MIT"
] | null | null | null |
Mundo 1_Fundamentos/Desafio_14.py
|
VictorOliveira02/Desafios-Python3-Curso-em-Video
|
53ee8bd814b816f3a21936677ef3f155b582843f
|
[
"MIT"
] | null | null | null |
c = float(input('Digite a temperatura em Celsius: '))
f = (c * 1.8) + 32
print(f'A temperatura de {c} Grau Celsius em fahrenheit equivale a {f}F')
| 24.833333
| 73
| 0.66443
| 27
| 149
| 3.666667
| 0.62963
| 0.242424
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.033058
| 0.187919
| 149
| 5
| 74
| 29.8
| 0.785124
| 0
| 0
| 0
| 0
| 0
| 0.644295
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0
| 0
| 0
| 0.333333
| 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
| 1
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
18fab4f103b78b7acaa645dd1abb0f7fe1286ea9
| 569
|
py
|
Python
|
python/Alura/data science/pandas/selecao_tuplas.py
|
alifoliveira/rep-estudos
|
73ffb7cfe77890f6cca8b5447db332f88454ef7e
|
[
"MIT"
] | null | null | null |
python/Alura/data science/pandas/selecao_tuplas.py
|
alifoliveira/rep-estudos
|
73ffb7cfe77890f6cca8b5447db332f88454ef7e
|
[
"MIT"
] | null | null | null |
python/Alura/data science/pandas/selecao_tuplas.py
|
alifoliveira/rep-estudos
|
73ffb7cfe77890f6cca8b5447db332f88454ef7e
|
[
"MIT"
] | null | null | null |
# seleção simples
nome_carros = tuple(['Jetta Variant', 'Passat', 'Crossfox', 'DS5'])
print(nome_carros[0]) # selecionando indice 0
print(nome_carros[1]) # selecionando indice 1
print(nome_carros[-1]) # selecionando indice -1 (ultimo)
print(nome_carros[1:3]) # slice do indice 1 ao 3-1(2)
# seleção interna
nome_carros_2 = ('Jetta Variant', 'Passat', 'Crossfox', 'DS5',('Fusca', 'Gol', 'C4'))
print(nome_carros_2[-1]) # tupla interna
print(nome_carros_2[-1][1]) # elemento 1 da tupla interna
print(nome_carros_2[-1][-1]) # ultimo elemento da tupla interna
| 37.933333
| 85
| 0.699473
| 87
| 569
| 4.425287
| 0.321839
| 0.233766
| 0.272727
| 0.124675
| 0.532468
| 0.337662
| 0.337662
| 0.155844
| 0
| 0
| 0
| 0.050813
| 0.135325
| 569
| 14
| 86
| 40.642857
| 0.731707
| 0.369069
| 0
| 0
| 0
| 0
| 0.200573
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0.222222
| 0
| 0
| 0
| 0.777778
| 0
| 0
| 0
| null | 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 1
|
0
| 4
|
e130896161fc8761918afa77c9338bf8e1a1a2fa
| 50
|
py
|
Python
|
shop/admin.py
|
PeterTP/Keysight-Spectrum-Analyzer
|
20be5b82bff69b2fb37a97ded16f355d4f31e4c8
|
[
"Apache-2.0"
] | null | null | null |
shop/admin.py
|
PeterTP/Keysight-Spectrum-Analyzer
|
20be5b82bff69b2fb37a97ded16f355d4f31e4c8
|
[
"Apache-2.0"
] | null | null | null |
shop/admin.py
|
PeterTP/Keysight-Spectrum-Analyzer
|
20be5b82bff69b2fb37a97ded16f355d4f31e4c8
|
[
"Apache-2.0"
] | null | null | null |
# shop/admin.py
from django.contrib import admin
| 12.5
| 32
| 0.78
| 8
| 50
| 4.875
| 0.875
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.14
| 50
| 3
| 33
| 16.666667
| 0.906977
| 0.26
| 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
|
e13488a40921e9ca215989812adc5f510ede01d5
| 138
|
py
|
Python
|
ucwallet/udfs/__init__.py
|
UlordChain/Ulord-Sidechain-SDK-py-
|
c3c56da1bbae0dca453da869b9cfaa11e0b437d4
|
[
"MIT"
] | 17
|
2018-08-20T12:30:23.000Z
|
2019-08-01T18:27:42.000Z
|
ucwallet/udfs/__init__.py
|
UlordChain/Ulord-Sidechain-SDK-py-
|
c3c56da1bbae0dca453da869b9cfaa11e0b437d4
|
[
"MIT"
] | 1
|
2021-06-01T22:23:55.000Z
|
2021-06-01T22:23:55.000Z
|
ucwallet/udfs/__init__.py
|
UlordChain/Ulord-Sidechain-SDK-py-
|
c3c56da1bbae0dca453da869b9cfaa11e0b437d4
|
[
"MIT"
] | 1
|
2019-01-02T01:03:11.000Z
|
2019-01-02T01:03:11.000Z
|
# coding=utf-8
# Copyright (c) 2016-2018 The Ulord Core Developers
# @File : __init__.py
# @Author: Ulord_PuJi
# @Date : 2018/5/19 0019
| 23
| 51
| 0.688406
| 22
| 138
| 4.090909
| 0.909091
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.175439
| 0.173913
| 138
| 5
| 52
| 27.6
| 0.614035
| 0.92029
| 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
|
e19de2c782a1df578b9e42edcfbfca9c51e7a8bb
| 91
|
py
|
Python
|
src/oscar/apps/dashboard/partners/__init__.py
|
akiyoko/oscar_sandbox
|
b384f1c0b5f297fd4b84509a575f6766a48630a5
|
[
"BSD-3-Clause"
] | 68
|
2016-11-06T05:07:57.000Z
|
2021-12-17T09:17:38.000Z
|
src/oscar/apps/dashboard/partners/__init__.py
|
akiyoko/oscar_sandbox
|
b384f1c0b5f297fd4b84509a575f6766a48630a5
|
[
"BSD-3-Clause"
] | 10
|
2020-05-11T20:33:31.000Z
|
2022-03-12T00:24:28.000Z
|
src/oscar/apps/dashboard/partners/__init__.py
|
akiyoko/oscar_sandbox
|
b384f1c0b5f297fd4b84509a575f6766a48630a5
|
[
"BSD-3-Clause"
] | 28
|
2016-12-04T07:12:50.000Z
|
2021-02-06T21:13:15.000Z
|
default_app_config = (
'oscar.apps.dashboard.partners.config.PartnersDashboardConfig')
| 30.333333
| 67
| 0.802198
| 9
| 91
| 7.888889
| 0.888889
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.087912
| 91
| 2
| 68
| 45.5
| 0.855422
| 0
| 0
| 0
| 0
| 0
| 0.659341
| 0.659341
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
e1b9e6a05915e6ae50ea276947bdb55ac43cf549
| 410
|
py
|
Python
|
ScriptRunner/exceptions.py
|
mag-id/ScriptRunner
|
cb45e52e0f35c50a305da2c36e176b65d1836ffc
|
[
"MIT"
] | null | null | null |
ScriptRunner/exceptions.py
|
mag-id/ScriptRunner
|
cb45e52e0f35c50a305da2c36e176b65d1836ffc
|
[
"MIT"
] | 1
|
2021-01-24T23:22:53.000Z
|
2021-01-24T23:24:04.000Z
|
ScriptRunner/exceptions.py
|
mag-id/ScriptRunner
|
cb45e52e0f35c50a305da2c36e176b65d1836ffc
|
[
"MIT"
] | null | null | null |
"""ScriptRunner custom exceptions."""
class ScriptRunnerException(BaseException):
"""Base ScriptRunner exception."""
class FailuresException(ScriptRunnerException):
"""Failures parent exception."""
class StopKeywordFailures(FailuresException):
"""ScriptRunner `"stop"` keyword exception."""
class UnknownKeywordFailures(FailuresException):
"""ScriptRunner unknown keyword exception."""
| 22.777778
| 50
| 0.756098
| 29
| 410
| 10.689655
| 0.551724
| 0.135484
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.119512
| 410
| 17
| 51
| 24.117647
| 0.858726
| 0.409756
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 1
| 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
| 0
| 0
| 0
| 1
| 0
|
0
| 4
|
bed3510eb0c4584c747cc472f46f221d8441689a
| 89
|
py
|
Python
|
coreAPI/apps.py
|
agriev/DjangoPostGISCanvas
|
17b149a60ab9a8c59c653e920c89f4feeb1f5e43
|
[
"MIT"
] | null | null | null |
coreAPI/apps.py
|
agriev/DjangoPostGISCanvas
|
17b149a60ab9a8c59c653e920c89f4feeb1f5e43
|
[
"MIT"
] | null | null | null |
coreAPI/apps.py
|
agriev/DjangoPostGISCanvas
|
17b149a60ab9a8c59c653e920c89f4feeb1f5e43
|
[
"MIT"
] | null | null | null |
from django.apps import AppConfig
class CoreapiConfig(AppConfig):
name = 'coreAPI'
| 14.833333
| 33
| 0.752809
| 10
| 89
| 6.7
| 0.9
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.168539
| 89
| 5
| 34
| 17.8
| 0.905405
| 0
| 0
| 0
| 0
| 0
| 0.078652
| 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
|
bed51edddb3df88d9425aabc23811bb6fa97f483
| 89
|
py
|
Python
|
compute/apps.py
|
pockemon/Loan-emi-calculator
|
18086183cccf043133d34070ace07eccb7a0aae1
|
[
"Apache-2.0"
] | null | null | null |
compute/apps.py
|
pockemon/Loan-emi-calculator
|
18086183cccf043133d34070ace07eccb7a0aae1
|
[
"Apache-2.0"
] | 3
|
2021-03-10T20:35:07.000Z
|
2021-03-30T14:05:30.000Z
|
backend/compute/apps.py
|
FrederikBanke/map-granted-applications
|
efa9d9d2ab4dda4d5982c929e7dedbbb956cf674
|
[
"MIT"
] | null | null | null |
from django.apps import AppConfig
class ComputeConfig(AppConfig):
name = 'compute'
| 14.833333
| 33
| 0.752809
| 10
| 89
| 6.7
| 0.9
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.168539
| 89
| 5
| 34
| 17.8
| 0.905405
| 0
| 0
| 0
| 0
| 0
| 0.078652
| 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
|
831abb0a96d1bba177a01fe981f02bd30a68cce9
| 121
|
py
|
Python
|
acmicpc/14753.py
|
juseongkr/BOJ
|
8f10a2bf9a7d695455493fbe7423347a8b648416
|
[
"Apache-2.0"
] | 7
|
2020-02-03T10:00:19.000Z
|
2021-11-16T11:03:57.000Z
|
acmicpc/14753.py
|
juseongkr/Algorithm-training
|
8f10a2bf9a7d695455493fbe7423347a8b648416
|
[
"Apache-2.0"
] | 1
|
2021-01-03T06:58:24.000Z
|
2021-01-03T06:58:24.000Z
|
acmicpc/14753.py
|
juseongkr/Algorithm-training
|
8f10a2bf9a7d695455493fbe7423347a8b648416
|
[
"Apache-2.0"
] | 1
|
2020-01-22T14:34:03.000Z
|
2020-01-22T14:34:03.000Z
|
input()
l = [*map(int, input().split())]
l.sort()
print(max(l[0]*l[1], l[0]*l[1]*l[-1], l[-1]*l[-2]*l[-3], l[-1]*l[-2]))
| 24.2
| 70
| 0.454545
| 30
| 121
| 1.833333
| 0.4
| 0.181818
| 0.272727
| 0.145455
| 0.236364
| 0
| 0
| 0
| 0
| 0
| 0
| 0.09009
| 0.082645
| 121
| 4
| 71
| 30.25
| 0.405405
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0
| 0
| 0
| 0.25
| 0
| 0
| 1
| null | 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
83419c45c9dbc51f726b588b0ea849d33d2ea524
| 72
|
py
|
Python
|
chat_test.py
|
Nalin-2005/The2020CoderBot
|
f4521e488dc7963cb16140b737d2dd25f4ff30c2
|
[
"MIT"
] | 4
|
2021-04-28T04:07:20.000Z
|
2021-06-12T12:36:47.000Z
|
chat_test.py
|
NrdyBhu1/The2020CoderBot
|
ef3f9c79d6ba1c5755be49e5ec7aa85072a28a8a
|
[
"MIT"
] | 2
|
2021-06-14T06:47:10.000Z
|
2021-06-15T14:10:14.000Z
|
chat_test.py
|
NrdyBhu1/The2020CoderBot
|
ef3f9c79d6ba1c5755be49e5ec7aa85072a28a8a
|
[
"MIT"
] | 1
|
2021-06-12T12:29:19.000Z
|
2021-06-12T12:29:19.000Z
|
from ext.chat import predict
while True:
print(predict(input(">> ")))
| 18
| 30
| 0.694444
| 10
| 72
| 5
| 0.9
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.138889
| 72
| 4
| 30
| 18
| 0.806452
| 0
| 0
| 0
| 0
| 0
| 0.054795
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.333333
| 0
| 0.333333
| 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
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
834602b2c098809ea21e567b6ae8990bfd3f3f17
| 213
|
py
|
Python
|
todclean/use_cases/task/checker.py
|
marioidival/todclean
|
75be8ccdaaa443ebdeb6a7ef270cd92eb693afe4
|
[
"MIT"
] | null | null | null |
todclean/use_cases/task/checker.py
|
marioidival/todclean
|
75be8ccdaaa443ebdeb6a7ef270cd92eb693afe4
|
[
"MIT"
] | null | null | null |
todclean/use_cases/task/checker.py
|
marioidival/todclean
|
75be8ccdaaa443ebdeb6a7ef270cd92eb693afe4
|
[
"MIT"
] | null | null | null |
from todclean import repo_manager as manager
class TaskCheck:
def __init__(self):
self.repository = manager('task')
def check_task(self, task_id):
return self.repository.check(task_id)
| 19.363636
| 45
| 0.699531
| 28
| 213
| 5.035714
| 0.571429
| 0.198582
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.215962
| 213
| 10
| 46
| 21.3
| 0.844311
| 0
| 0
| 0
| 0
| 0
| 0.018779
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.333333
| false
| 0
| 0.166667
| 0.166667
| 0.833333
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 1
| 1
| 0
|
0
| 4
|
83689931b9ba77fc3225a7845eaaf77a38af9aca
| 243
|
py
|
Python
|
python-flask/wordcount/hello_world/__init__.py
|
getconvey/interview-boilerplates
|
236ffdc3e421a9a6e39a382a39512c809fc9104d
|
[
"MIT"
] | null | null | null |
python-flask/wordcount/hello_world/__init__.py
|
getconvey/interview-boilerplates
|
236ffdc3e421a9a6e39a382a39512c809fc9104d
|
[
"MIT"
] | 31
|
2020-03-12T18:11:15.000Z
|
2022-03-01T17:55:32.000Z
|
python-flask/wordcount/hello_world/__init__.py
|
getconvey/interview-boilerplates
|
236ffdc3e421a9a6e39a382a39512c809fc9104d
|
[
"MIT"
] | 5
|
2019-05-23T19:16:11.000Z
|
2021-08-16T16:38:52.000Z
|
from flask import Blueprint, current_app, jsonify
from typing import Any
hello_world = Blueprint('hello_world', __name__)
@hello_world.route("/helloworld")
def reply() -> Any:
return jsonify({"text": current_app.config['HELLO_WORLD']})
| 24.3
| 63
| 0.748971
| 32
| 243
| 5.375
| 0.59375
| 0.232558
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.119342
| 243
| 9
| 64
| 27
| 0.803738
| 0
| 0
| 0
| 0
| 0
| 0.152263
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.166667
| false
| 0
| 0.333333
| 0.166667
| 0.666667
| 0.333333
| 0
| 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
| 1
| 0
| 0
|
0
| 4
|
55f8405835e0c62209c4bab8a29f6542c8f94b11
| 105
|
py
|
Python
|
meiduo_mall/meiduo_mall/__init__.py
|
yy12950906/meiduo_project
|
e49f9a784cfb2f35ff0cae6b947ce2eb178d7c29
|
[
"MIT"
] | null | null | null |
meiduo_mall/meiduo_mall/__init__.py
|
yy12950906/meiduo_project
|
e49f9a784cfb2f35ff0cae6b947ce2eb178d7c29
|
[
"MIT"
] | null | null | null |
meiduo_mall/meiduo_mall/__init__.py
|
yy12950906/meiduo_project
|
e49f9a784cfb2f35ff0cae6b947ce2eb178d7c29
|
[
"MIT"
] | null | null | null |
import pymysql
pymysql.install_as_MySQLdb() # 因为MySQLdb只适用于Python2.x的版本,Python3.x的版本中使用PyMySQL替代MySQLdb
| 35
| 89
| 0.87619
| 10
| 105
| 9
| 0.9
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.020202
| 0.057143
| 105
| 3
| 89
| 35
| 0.888889
| 0.542857
| 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
|
361727b962e031de1b50da6bc9423275a3848b41
| 593
|
py
|
Python
|
jetavator_databricks_client/jetavator_databricks_client/config/DatabricksConfig.py
|
jetavator/jetavator_databricks
|
719c934b6391f6f41ca34b4d4df8c697c1a25283
|
[
"Apache-2.0"
] | null | null | null |
jetavator_databricks_client/jetavator_databricks_client/config/DatabricksConfig.py
|
jetavator/jetavator_databricks
|
719c934b6391f6f41ca34b4d4df8c697c1a25283
|
[
"Apache-2.0"
] | null | null | null |
jetavator_databricks_client/jetavator_databricks_client/config/DatabricksConfig.py
|
jetavator/jetavator_databricks
|
719c934b6391f6f41ca34b4d4df8c697c1a25283
|
[
"Apache-2.0"
] | null | null | null |
from typing import List
from jetavator.config import ComputeServiceConfig
import wysdom
DatabricksLibraryConfig = wysdom.SchemaDict(wysdom.SchemaAnything())
class DatabricksConfig(ComputeServiceConfig):
type: str = wysdom.UserProperty(wysdom.SchemaConst('remote_databricks'))
host: str = wysdom.UserProperty(str)
cluster_id: str = wysdom.UserProperty(str)
org_id: str = wysdom.UserProperty(str)
token: str = wysdom.UserProperty(str)
libraries: List[DatabricksLibraryConfig] = wysdom.UserProperty(
wysdom.SchemaArray(DatabricksLibraryConfig), default=[{}])
| 32.944444
| 76
| 0.772344
| 58
| 593
| 7.844828
| 0.465517
| 0.237363
| 0.230769
| 0.210989
| 0.114286
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.131535
| 593
| 17
| 77
| 34.882353
| 0.883495
| 0
| 0
| 0
| 0
| 0
| 0.028668
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.25
| 0
| 0.833333
| 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
|
362261a572573073e702bb379793470816186c93
| 68
|
py
|
Python
|
subcommander/__init__.py
|
7tupel/subcommander
|
54f6bf6bccc4344dacb6434b479f502be649cef6
|
[
"Apache-2.0"
] | null | null | null |
subcommander/__init__.py
|
7tupel/subcommander
|
54f6bf6bccc4344dacb6434b479f502be649cef6
|
[
"Apache-2.0"
] | null | null | null |
subcommander/__init__.py
|
7tupel/subcommander
|
54f6bf6bccc4344dacb6434b479f502be649cef6
|
[
"Apache-2.0"
] | null | null | null |
from .command import Command
from .subcommander import Subcommander
| 22.666667
| 38
| 0.852941
| 8
| 68
| 7.25
| 0.5
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.117647
| 68
| 2
| 39
| 34
| 0.966667
| 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
|
363f985fa741f05813e5faac6614b568c468def9
| 298
|
py
|
Python
|
component/speed.py
|
ywchiao/shot
|
4b7c55bdcca44d05e07fffa59fe4e23364032cb5
|
[
"MIT"
] | null | null | null |
component/speed.py
|
ywchiao/shot
|
4b7c55bdcca44d05e07fffa59fe4e23364032cb5
|
[
"MIT"
] | null | null | null |
component/speed.py
|
ywchiao/shot
|
4b7c55bdcca44d05e07fffa59fe4e23364032cb5
|
[
"MIT"
] | 1
|
2020-03-27T02:07:27.000Z
|
2020-03-27T02:07:27.000Z
|
class Speed:
def __init__(self):
self._cache = {}
def get_value(self, entity):
value = 0
if entity in self._cache:
value = self._cache[entity]
return value
def update(self, entity, value):
self._cache[entity] = value
# speed.py
| 16.555556
| 39
| 0.560403
| 36
| 298
| 4.388889
| 0.416667
| 0.227848
| 0.189873
| 0.253165
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.005076
| 0.338926
| 298
| 17
| 40
| 17.529412
| 0.796954
| 0.026846
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.3
| false
| 0
| 0
| 0
| 0.5
| 0
| 0
| 0
| 0
| null | 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
36415eca57e8fe4d8cef834832800eb07a6bfb7d
| 18,593
|
py
|
Python
|
pykinect_azure/k4arecord/_k4arecord.py
|
necoxt/pyKinectAzure
|
1e1fa845bd8299b7534a647f12ca0b49c5bc57d4
|
[
"MIT"
] | 170
|
2020-06-29T05:37:49.000Z
|
2022-03-30T01:09:16.000Z
|
pykinect_azure/k4arecord/_k4arecord.py
|
necoxt/pyKinectAzure
|
1e1fa845bd8299b7534a647f12ca0b49c5bc57d4
|
[
"MIT"
] | 49
|
2020-06-29T06:30:58.000Z
|
2022-03-31T04:04:35.000Z
|
pykinect_azure/k4arecord/_k4arecord.py
|
necoxt/pyKinectAzure
|
1e1fa845bd8299b7534a647f12ca0b49c5bc57d4
|
[
"MIT"
] | 52
|
2020-06-29T11:15:03.000Z
|
2022-03-24T08:53:24.000Z
|
import ctypes
import sys
import traceback
from ._k4arecordTypes import *
from ..k4a._k4atypes import *
record_dll = None
def setup_library(module_k4arecord_path):
global record_dll
try:
record_dll = ctypes.CDLL(module_k4arecord_path)
except Exception as e:
print("Failed to load library", e)
sys.exit(1)
def k4a_record_create(file_path, device, device_config, recording_handle):
"""
K4ARECORD_EXPORT k4a_result_t k4a_record_create(const char *path,
k4a_device_t device,
const k4a_device_configuration_t device_config,
k4a_record_t *recording_handle);
"""
_k4a_record_create = record_dll.k4a_record_create
_k4a_record_create.restype = k4a_result_t
_k4a_record_create.argtypes = (ctypes.POINTER(ctypes.c_char), \
k4a_device_t, \
k4a_device_configuration_t, \
ctypes.POINTER(k4a_record_t),\
)
return _k4a_record_create(file_path, device, device_config, recording_handle)
def k4a_record_write_header(recording_handle):
# K4ARECORD_EXPORT k4a_result_t k4a_record_write_header(k4a_record_t recording_handle);
_k4a_record_write_header = record_dll.k4a_record_write_header
_k4a_record_write_header.restype = k4a_result_t
_k4a_record_write_header.argtypes = (k4a_record_t,)
return _k4a_record_write_header(recording_handle)
def k4a_record_write_capture(recording_handle, capture_handle):
# K4ARECORD_EXPORT k4a_result_t k4a_record_write_capture(k4a_record_t recording_handle, k4a_capture_t capture_handle);
_k4a_record_write_capture = record_dll.k4a_record_write_capture
_k4a_record_write_capture.restype = k4a_result_t
_k4a_record_write_capture.argtypes = (k4a_record_t, \
k4a_capture_t)
return _k4a_record_write_capture(recording_handle, capture_handle)
def k4a_record_flush(recording_handle):
# K4ARECORD_EXPORT k4a_result_t k4a_record_flush(k4a_record_t recording_handle);
_k4a_record_flush = record_dll.k4a_record_flush
_k4a_record_flush.restype = k4a_result_t
_k4a_record_flush.argtypes = (k4a_record_t,)
return _k4a_record_flush(recording_handle)
def k4a_record_close(recording_handle):
# K4ARECORD_EXPORT void k4a_record_close(k4a_record_t recording_handle);
_k4a_record_close = record_dll.k4a_record_close
_k4a_record_close.restype = None
_k4a_record_close.argtypes = (k4a_record_t,)
_k4a_record_close(recording_handle)
###########################
### Playback ###
###########################
def k4a_playback_open(file_path, playback_handle):
# K4ARECORD_EXPORT k4a_result_t k4a_playback_open(const char *path, k4a_playback_t *playback_handle);
_k4a_playback_open = record_dll.k4a_playback_open
_k4a_playback_open.restype = k4a_result_t
_k4a_playback_open.argtypes = (ctypes.POINTER(ctypes.c_char), \
ctypes.POINTER(k4a_playback_t),)
return _k4a_playback_open(file_path, playback_handle)
def k4a_playback_close(playback_handle):
# K4ARECORD_EXPORT void k4a_playback_close(k4a_playback_t playback_handle);
_k4a_playback_close = record_dll.k4a_playback_close
_k4a_playback_close.restype = None
_k4a_playback_close.argtypes = (k4a_playback_t,)
_k4a_playback_close(playback_handle)
def k4a_playback_get_raw_calibration(playback_handle, data, data_size):
"""
K4ARECORD_EXPORT k4a_buffer_result_t k4a_playback_get_raw_calibration(k4a_playback_t playback_handle,
uint8_t *data,
size_t *data_size);
"""
_k4a_playback_get_raw_calibration = record_dll.k4a_playback_get_raw_calibration
_k4a_playback_get_raw_calibration.restype = k4a_buffer_result_t
_k4a_playback_get_raw_calibration.argtypes = (k4a_playback_t, \
ctypes.POINTER(ctypes.c_uint8),\
ctypes.POINTER(ctypes.c_size_t))
return _k4a_playback_get_raw_calibration(playback_handle, data, data_size)
def k4a_playback_get_calibration(playback_handle, calibration):
"""
K4ARECORD_EXPORT k4a_result_t k4a_playback_get_calibration(k4a_playback_t playback_handle,
k4a_calibration_t *calibration);
"""
_k4a_playback_get_calibration = record_dll.k4a_playback_get_calibration
_k4a_playback_get_calibration.restype = k4a_result_t
_k4a_playback_get_calibration.argtypes = (k4a_playback_t, \
ctypes.POINTER(k4a_calibration_t))
return _k4a_playback_get_calibration(playback_handle, calibration)
def k4a_playback_get_record_configuration(playback_handle, config):
"""
K4ARECORD_EXPORT k4a_result_t k4a_playback_get_record_configuration(k4a_playback_t playback_handle,
k4a_record_configuration_t *config);
"""
_k4a_playback_get_record_configuration = record_dll.k4a_playback_get_record_configuration
_k4a_playback_get_record_configuration.restype = k4a_result_t
_k4a_playback_get_record_configuration.argtypes = (k4a_playback_t, \
ctypes.POINTER(k4a_record_configuration_t))
return _k4a_playback_get_record_configuration(playback_handle, config)
def k4a_playback_check_track_exists(playback_handle, track_name):
"""
K4ARECORD_EXPORT bool k4a_playback_check_track_exists(k4a_playback_t playback_handle, const char *track_name);
"""
_k4a_playback_check_track_exists = record_dll.k4a_playback_check_track_exists
_k4a_playback_check_track_exists.restype = ctypes.c_bool
_k4a_playback_check_track_exists.argtypes = (k4a_playback_t, \
ctypes.POINTER(ctypes.c_char))
return _k4a_playback_check_track_exists(playback_handle, track_name)
def k4a_playback_get_track_count(playback_handle):
"""
K4ARECORD_EXPORT size_t k4a_playback_get_track_count(k4a_playback_t playback_handle);
"""
_k4a_playback_get_track_count = record_dll.k4a_playback_get_track_count
_k4a_playback_get_track_count.restype = ctypes.c_size_t
_k4a_playback_get_track_count.argtypes = (k4a_playback_t,)
return _k4a_playback_get_track_count(playback_handle)
def k4a_playback_get_track_name(playback_handle, track_index, track_name, track_name_size):
"""
K4ARECORD_EXPORT k4a_buffer_result_t k4a_playback_get_track_name(k4a_playback_t playback_handle,
size_t track_index,
char *track_name,
size_t *track_name_size);
"""
_k4a_playback_get_track_name = record_dll.k4a_playback_get_track_name
_k4a_playback_get_track_name.restype = k4a_buffer_result_t
_k4a_playback_get_track_name.argtypes = (k4a_playback_t,\
ctypes.c_size_t,\
ctypes.POINTER(ctypes.c_char),\
ctypes.POINTER(ctypes.c_size_t))
return _k4a_playback_get_track_name(playback_handle, track_index, track_name, track_name_size)
def k4a_playbk4a_playback_track_is_builtinack_get_track_name(playback_handle, track_name):
"""
K4ARECORD_EXPORT bool k4a_playback_track_is_builtin(k4a_playback_t playback_handle, const char *track_name);;
"""
_k4a_playback_track_is_builtin = record_dll.k4a_playback_track_is_builtin
_k4a_playback_track_is_builtin.restype = ctypes.c_bool
_k4a_playback_track_is_builtin.argtypes = (k4a_playback_t,\
ctypes.POINTER(ctypes.c_char))
return _k4a_playback_track_is_builtin(playback_handle, track_name)
def k4a_playback_track_get_video_settings(playback_handle, track_name, video_settings):
"""
K4ARECORD_EXPORT k4a_result_t k4a_playback_track_get_video_settings(k4a_playback_t playback_handle,
const char *track_name,
k4a_record_video_settings_t *video_settings);
"""
_k4a_playback_track_get_video_settings = record_dll.k4a_playback_track_get_video_settings
_k4a_playback_track_get_video_settings.restype = k4a_result_t
_k4a_playback_track_get_video_settings.argtypes = (k4a_playback_t,\
ctypes.POINTER(ctypes.c_char),\
ctypes.POINTER(k4a_record_video_settings_t))
return _k4a_playback_track_get_video_settings(playback_handle, track_name, video_settings)
def k4a_playback_track_get_codec_id(playback_handle, track_name, codec_id, codec_id_size):
"""
K4ARECORD_EXPORT k4a_buffer_result_t k4a_playback_track_get_codec_id(k4a_playback_t playback_handle,
const char *track_name,
char *codec_id,
size_t *codec_id_size);
"""
_k4a_playback_track_get_codec_id = record_dll.k4a_playback_track_get_codec_id
_k4a_playback_track_get_codec_id.restype = k4a_buffer_result_t
_k4a_playback_track_get_codec_id.argtypes = (k4a_playback_t,\
ctypes.POINTER(ctypes.c_char),\
ctypes.POINTER(ctypes.c_char),\
ctypes.POINTER(ctypes.c_size_t))
return _k4a_playback_track_get_codec_id(playback_handle, track_name, codec_id, codec_id_size)
def k4a_playback_track_get_codec_context(playback_handle, track_name, codec_context, codec_context_size):
"""
K4ARECORD_EXPORT k4a_buffer_result_t k4a_playback_track_get_codec_context(k4a_playback_t playback_handle,
const char *track_name,
uint8_t *codec_context,
size_t *codec_context_size);
"""
_k4a_playback_track_get_codec_context = record_dll.k4a_playback_track_get_codec_context
_k4a_playback_track_get_codec_context.restype = k4a_buffer_result_t
_k4a_playback_track_get_codec_context.argtypes = (k4a_playback_t,\
ctypes.POINTER(ctypes.c_char),\
ctypes.POINTER(ctypes.c_uint8),\
ctypes.POINTER(ctypes.c_size_t))
return _k4a_playback_track_get_codec_context(playback_handle, track_name, codec_context, codec_context_size)
def k4a_playback_get_tag(playback_handle, name, value, value_size):
"""
K4ARECORD_EXPORT k4a_buffer_result_t k4a_playback_get_tag(k4a_playback_t playback_handle,
const char *name,
char *value,
size_t *value_size);
"""
_k4a_playback_get_tag = record_dll.k4a_playback_get_tag
_k4a_playback_get_tag.restype = k4a_buffer_result_t
_k4a_playback_get_tag.argtypes = (k4a_playback_t,\
ctypes.POINTER(ctypes.c_char),\
ctypes.POINTER(ctypes.c_char),\
ctypes.POINTER(ctypes.c_size_t))
return _k4a_playback_get_tag(playback_handle, name, value, value_size)
def k4a_playback_set_color_conversion(playback_handle, target_format):
"""
K4ARECORD_EXPORT k4a_result_t k4a_playback_set_color_conversion(k4a_playback_t playback_handle,
k4a_image_format_t target_format);
"""
_k4a_playback_set_color_conversion = record_dll.k4a_playback_set_color_conversion
_k4a_playback_set_color_conversion.restype = k4a_result_t
_k4a_playback_set_color_conversion.argtypes = (k4a_playback_t,\
k4a_image_format_t)
return _k4a_playback_set_color_conversion(playback_handle, target_format)
def k4a_playback_get_attachment(playback_handle, file_name, data, data_size):
"""
K4ARECORD_EXPORT k4a_buffer_result_t k4a_playback_get_attachment(k4a_playback_t playback_handle,
const char *file_name,
uint8_t *data,
size_t *data_size);
"""
_k4a_playback_get_attachment = record_dll.k4a_playback_get_attachment
_k4a_playback_get_attachment.restype = k4a_buffer_result_t
_k4a_playback_get_attachment.argtypes = (k4a_playback_t,\
ctypes.POINTER(ctypes.c_char),\
ctypes.POINTER(ctypes.c_uint8),\
ctypes.POINTER(ctypes.c_size_t))
return _k4a_playback_get_attachment(playback_handle, file_name, data, data_size)
def k4a_playback_get_next_capture(playback_handle, capture_handle):
"""
K4ARECORD_EXPORT k4a_stream_result_t k4a_playback_get_next_capture(k4a_playback_t playback_handle,
k4a_capture_t *capture_handle);
"""
_k4a_playback_get_next_capture = record_dll.k4a_playback_get_next_capture
_k4a_playback_get_next_capture.restype = k4a_stream_result_t
_k4a_playback_get_next_capture.argtypes = (k4a_playback_t, \
ctypes.POINTER(k4a_capture_t),)
return _k4a_playback_get_next_capture(playback_handle, capture_handle)
def k4a_playback_get_previous_capture(playback_handle, capture_handle):
"""
K4ARECORD_EXPORT k4a_stream_result_t k4a_playback_get_previous_capture(k4a_playback_t playback_handle,
k4a_capture_t *capture_handle);
"""
_k4a_playback_get_previous_capture = record_dll.k4a_playback_get_previous_capture
_k4a_playback_get_previous_capture.restype = k4a_stream_result_t
_k4a_playback_get_previous_capture.argtypes = (k4a_playback_t, \
ctypes.POINTER(k4a_capture_t),)
return _k4a_playback_get_previous_capture(playback_handle, capture_handle)
def k4a_playback_get_next_imu_sample(playback_handle, imu_sample):
"""
K4ARECORD_EXPORT k4a_stream_result_t k4a_playback_get_next_imu_sample(k4a_playback_t playback_handle,
k4a_imu_sample_t *imu_sample);
"""
_k4a_playback_get_next_imu_sample = record_dll.k4a_playback_get_next_imu_sample
_k4a_playback_get_next_imu_sample.restype = k4a_stream_result_t
_k4a_playback_get_next_imu_sample.argtypes = (k4a_playback_t, \
ctypes.POINTER(k4a_imu_sample_t),)
return _k4a_playback_get_next_imu_sample(playback_handle, imu_sample)
def k4a_playback_get_previous_imu_sample(playback_handle, imu_sample):
"""
K4ARECORD_EXPORT k4a_stream_result_t k4a_playback_get_previous_imu_sample(k4a_playback_t playback_handle,
k4a_imu_sample_t *imu_sample);
"""
_k4a_playback_get_previous_imu_sample = record_dll.k4a_playback_get_previous_imu_sample
_k4a_playback_get_previous_imu_sample.restype = k4a_stream_result_t
_k4a_playback_get_previous_imu_sample.argtypes = (k4a_playback_t, \
ctypes.POINTER(k4a_imu_sample_t),)
return _k4a_playback_get_previous_imu_sample(playback_handle, imu_sample)
def k4a_playback_get_next_data_block(playback_handle, track_name, data_block_handle):
"""
K4ARECORD_EXPORT k4a_stream_result_t k4a_playback_get_next_data_block(k4a_playback_t playback_handle,
const char *track_name,
k4a_playback_data_block_t *data_block_handle);
"""
_k4a_playback_get_next_data_block = record_dll.k4a_playback_get_next_data_block
_k4a_playback_get_next_data_block.restype = k4a_stream_result_t
_k4a_playback_get_next_data_block.argtypes = (k4a_playback_t, \
ctypes.POINTER(ctypes.c_char),
ctypes.POINTER(k4a_playback_data_block_t),)
return _k4a_playback_get_next_data_block(playback_handle, track_name, data_block_handle)
def k4a_playback_get_previous_data_block(playback_handle, track_name, data_block_handle):
"""
K4ARECORD_EXPORT k4a_stream_result_t k4a_playback_get_previous_data_block(k4a_playback_t playback_handle,
const char *track_name,
k4a_playback_data_block_t *data_block_handle);
"""
_k4a_playback_get_previous_data_block = record_dll.k4a_playback_get_previous_data_block
_k4a_playback_get_previous_data_block.restype = k4a_stream_result_t
_k4a_playback_get_previous_data_block.argtypes = (k4a_playback_t, \
ctypes.POINTER(ctypes.c_char),
ctypes.POINTER(k4a_playback_data_block_t),)
return _k4a_playback_get_previous_data_block(playback_handle, track_name, data_block_handle)
def k4a_playback_data_block_get_device_timestamp_usec(data_block_handle):
"""
K4ARECORD_EXPORT uint64_t k4a_playback_data_block_get_device_timestamp_usec(k4a_playback_data_block_t data_block_handle);
"""
_k4a_playback_data_block_get_device_timestamp_usec = record_dll.k4a_playback_data_block_get_device_timestamp_usec
_k4a_playback_data_block_get_device_timestamp_usec.restype = ctypes.c_uint64
_k4a_playback_data_block_get_device_timestamp_usec.argtypes = (k4a_playback_data_block_t,)
return _k4a_playback_data_block_get_device_timestamp_usec(data_block_handle)
def k4a_playback_data_block_get_buffer_size(data_block_handle):
"""
K4ARECORD_EXPORT size_t k4a_playback_data_block_get_buffer_size(k4a_playback_data_block_t data_block_handle);
"""
_k4a_playback_data_block_get_buffer_size = record_dll.k4a_playback_data_block_get_buffer_size
_k4a_playback_data_block_get_buffer_size.restype = ctypes.c_size_t
_k4a_playback_data_block_get_buffer_size.argtypes = (k4a_playback_data_block_t,)
return _k4a_playback_data_block_get_buffer_size(data_block_handle)
def k4a_playback_data_block_get_buffer(data_block_handle):
"""
K4ARECORD_EXPORT uint8_t *k4a_playback_data_block_get_buffer(k4a_playback_data_block_t data_block_handle);
"""
_k4a_playback_data_block_get_buffer = record_dll.k4a_playback_data_block_get_buffer
_k4a_playback_data_block_get_buffer.restype = ctypes.POINTER(ctypes.c_uint8)
_k4a_playback_data_block_get_buffer.argtypes = (k4a_playback_data_block_t,)
return _k4a_playback_data_block_get_buffer(data_block_handle)
def k4a_playback_data_block_release(data_block_handle):
"""
K4ARECORD_EXPORT void k4a_playback_data_block_release(k4a_playback_data_block_t data_block_handle);
"""
_k4a_playback_data_block_release = record_dll.k4a_playback_data_block_release
_k4a_playback_data_block_release.restype = None
_k4a_playback_data_block_release.argtypes = (k4a_playback_data_block_t,)
return _k4a_playback_data_block_release(data_block_handle)
def k4a_playback_seek_timestamp(playback_handle, offset_usec, origin):
"""
K4ARECORD_EXPORT k4a_result_t k4a_playback_seek_timestamp(k4a_playback_t playback_handle,
int64_t offset_usec,
k4a_playback_seek_origin_t origin);
"""
_k4a_playback_seek_timestamp = record_dll.k4a_playback_seek_timestamp
_k4a_playback_seek_timestamp.restype = k4a_result_t
_k4a_playback_seek_timestamp.argtypes = (k4a_playback_t,\
ctypes.c_int64,\
k4a_playback_seek_origin_t)
return _k4a_playback_seek_timestamp(playback_handle, offset_usec, origin)
def k4a_playback_get_recording_length_usec(playback_handle):
"""
K4ARECORD_EXPORT uint64_t k4a_playback_get_recording_length_usec(k4a_playback_t playback_handle);
"""
_k4a_playback_get_recording_length_usec = record_dll.k4a_playback_get_recording_length_usec
_k4a_playback_get_recording_length_usec.restype = ctypes.c_uint64
_k4a_playback_get_recording_length_usec.argtypes = (k4a_playback_t,)
return _k4a_playback_get_recording_length_usec(playback_handle)
def k4a_playback_get_last_timestamp_usec(playback_handle):
"""
K4ARECORD_DEPRECATED_EXPORT uint64_t k4a_playback_get_last_timestamp_usec(k4a_playback_t playback_handle);
"""
_k4a_playback_get_last_timestamp_usec = record_dll.k4a_playback_get_last_timestamp_usec
_k4a_playback_get_last_timestamp_usec.restype = ctypes.c_uint64
_k4a_playback_get_last_timestamp_usec.argtypes = (k4a_playback_t,)
return _k4a_playback_get_last_timestamp_usec(playback_handle)
def VERIFY(result, error):
if result != K4A_RESULT_SUCCEEDED:
print(error)
traceback.print_stack()
sys.exit(1)
| 43.441589
| 122
| 0.81251
| 2,638
| 18,593
| 5.062926
| 0.041319
| 0.211665
| 0.110063
| 0.059898
| 0.911575
| 0.839997
| 0.750674
| 0.623839
| 0.504268
| 0.395927
| 0
| 0.026705
| 0.123918
| 18,593
| 427
| 123
| 43.543326
| 0.793235
| 0.451191
| 0
| 0.130045
| 0
| 0
| 0.001627
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.156951
| false
| 0
| 0.022422
| 0
| 0.318386
| 0.013453
| 0
| 0
| 0
| null | 1
| 0
| 0
| 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
3645db9d7372b70149e5e8eba4a66effadb89d6a
| 124
|
py
|
Python
|
Views/shortcuts/get_object_or_404/models.py
|
looking-for-a-job/django-examples
|
dfafa450668cac5c0351f6c7238b8886511229bf
|
[
"Unlicense"
] | null | null | null |
Views/shortcuts/get_object_or_404/models.py
|
looking-for-a-job/django-examples
|
dfafa450668cac5c0351f6c7238b8886511229bf
|
[
"Unlicense"
] | null | null | null |
Views/shortcuts/get_object_or_404/models.py
|
looking-for-a-job/django-examples
|
dfafa450668cac5c0351f6c7238b8886511229bf
|
[
"Unlicense"
] | null | null | null |
#!/usr/bin/env python
from django.db import models
class Model(models.Model):
title = models.CharField(max_length=30)
| 17.714286
| 43
| 0.741935
| 19
| 124
| 4.789474
| 0.842105
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.018692
| 0.137097
| 124
| 6
| 44
| 20.666667
| 0.831776
| 0.16129
| 0
| 0
| 0
| 0
| 0
| 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
|
36608193628f3b138f6ce69b9e83ed0377864c1b
| 157
|
py
|
Python
|
example/ex5.py
|
stotubalina/lab.2.13
|
80f60f26486073c9523fa8da9e9fa5071ca341f5
|
[
"MIT"
] | null | null | null |
example/ex5.py
|
stotubalina/lab.2.13
|
80f60f26486073c9523fa8da9e9fa5071ca341f5
|
[
"MIT"
] | null | null | null |
example/ex5.py
|
stotubalina/lab.2.13
|
80f60f26486073c9523fa8da9e9fa5071ca341f5
|
[
"MIT"
] | null | null | null |
#! /usr/bin/env python3
# -*- coding: utf-8 -*-
from math import *
if __name__ == '__main__':
print(cos(pi))
print(sin(pi))
print(factorial(2))
| 17.444444
| 26
| 0.592357
| 22
| 157
| 3.863636
| 0.863636
| 0.164706
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.024
| 0.203822
| 157
| 8
| 27
| 19.625
| 0.656
| 0.280255
| 0
| 0
| 0
| 0
| 0.072072
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.2
| 0
| 0.2
| 0.6
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 1
|
0
| 4
|
36a7c4f7823c3799f4c570261a0f26d9beea792c
| 286
|
py
|
Python
|
towerdefense/engine/map.py
|
nurrix/LexTowerDefense
|
40b9c29cd7c0c6f150b18562995f6c15eb43435d
|
[
"Apache-2.0"
] | null | null | null |
towerdefense/engine/map.py
|
nurrix/LexTowerDefense
|
40b9c29cd7c0c6f150b18562995f6c15eb43435d
|
[
"Apache-2.0"
] | null | null | null |
towerdefense/engine/map.py
|
nurrix/LexTowerDefense
|
40b9c29cd7c0c6f150b18562995f6c15eb43435d
|
[
"Apache-2.0"
] | null | null | null |
import tkinter as tk
from abc import ABC
import towerdefense.engine.engine as engine
class Map(ABC):
def __init__(self):
pass
def update(self):
""" Update game object. """
def paint(self, canvas: tk.Canvas):
""" Paint game object. """
| 20.428571
| 43
| 0.597902
| 36
| 286
| 4.638889
| 0.527778
| 0.107784
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.293706
| 286
| 14
| 44
| 20.428571
| 0.826733
| 0.136364
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.375
| false
| 0.125
| 0.375
| 0
| 0.875
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 1
| 0
| 1
| 0
|
0
| 4
|
36bc541b66cd5fcb7119de5ee7cab9808e3d1774
| 2,822
|
py
|
Python
|
backend/polzyFunctions/ConnectionFactory.py
|
Athos1972/PoLZy
|
794eb152cfa2ad3d02c1c5110bd106b7486ff615
|
[
"MIT"
] | null | null | null |
backend/polzyFunctions/ConnectionFactory.py
|
Athos1972/PoLZy
|
794eb152cfa2ad3d02c1c5110bd106b7486ff615
|
[
"MIT"
] | 4
|
2020-12-30T11:01:08.000Z
|
2021-06-29T15:41:23.000Z
|
backend/polzyFunctions/ConnectionFactory.py
|
Athos1972/PoLZy
|
794eb152cfa2ad3d02c1c5110bd106b7486ff615
|
[
"MIT"
] | null | null | null |
from requests import Session
from dataclasses import dataclass
from polzyFunctions.GlobalSystemConstants import GlobalSystemConstants
globalSystemConstants = GlobalSystemConstants()
@dataclass
class BackendSystemConnectorClasses():
backendDict = {}
class SessionBuffer(object):
# This class must be a singleton class, but due to conflict in overriding methods of subclass we can't make this
# base class as singleton. Hence, wherever this class is inherited the sub class should be a singleton class
# See the sample code of a subclass below:
#
# class SessionBufferSubClass(SessionBuffer):
# __instance__ = None
#
# def __init__(self):
# super().__init__()
# if SessionBuffer.__instance__ is None:
# SessionBuffer.__instance__ = self
# else:
# raise UserWarning("Session-Klasse schon initialisiert")
#
# @staticmethod
# def getInstance():
# if not SessionBuffer.__instance__:
# SessionBuffer()
# return SessionBuffer.__instance__
#
# Make sure to have __instance__ as class attribute, condition in __init__ to assign self to __instance__ if not
# their & a staticmethod getInstance which you will call where ever you need this class instance.
def __init__(self):
self.sessionDict = {}
def getSession(self, stage, sapClient):
return
class ConnectorMeta:
"""
Meta class for connections. Needs to be implemented and subclassed in each installation
"""
def __init__(self, *args, **kwargs):
"""
Needs to be implemented for each backend system to connect to in an installation
:param args:
:param kwargs:
"""
pass
def connectionSetup(self) -> Session:
"""
This method must be impleemented for each system. It should provide a Session object
which can be used for all GET, PUT, POST, etc. requests.
:return:
"""
pass
def executeGetRequestToURL(self, url: str, headers=None):
return
class ConnectionFactory:
"""
Connection factory should reply with an instance of ConnectorMeta
"""
availableStages = globalSystemConstants.getAllStages()
def __init__(self, stage):
return
def getConnector(self, endpointSystem: str, *args, **kwargs) -> ConnectorMeta:
"""
The parameters are needed to identify which backend connector should be returned. This is only needed when
there are more than one backend systems. Otherwise you can simply always return the same
ConnectorMeta-Implementation
:param endpointSystem:
:param args:
:param kwargs:
:return:
"""
return ConnectorMeta()
| 32.068182
| 116
| 0.658044
| 297
| 2,822
| 6.077441
| 0.468013
| 0.058172
| 0.024377
| 0.018837
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.2764
| 2,822
| 87
| 117
| 32.436782
| 0.883937
| 0.57158
| 0
| 0.2
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.28
| false
| 0.08
| 0.12
| 0.12
| 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
| 1
| 0
| 1
| 0
| 1
| 1
| 0
|
0
| 4
|
36be8cbb0e46dca2b0fed13e62322ea5aa017538
| 141
|
py
|
Python
|
fastapi_crudrouter/core/utils.py
|
agallant/fastapi-crudrouter
|
99321b9b98146b3a3dc2c6d230b25311dc81e25e
|
[
"MIT"
] | null | null | null |
fastapi_crudrouter/core/utils.py
|
agallant/fastapi-crudrouter
|
99321b9b98146b3a3dc2c6d230b25311dc81e25e
|
[
"MIT"
] | null | null | null |
fastapi_crudrouter/core/utils.py
|
agallant/fastapi-crudrouter
|
99321b9b98146b3a3dc2c6d230b25311dc81e25e
|
[
"MIT"
] | null | null | null |
def get_pk_type(schema, pk_field) -> type:
try:
return schema.__fields__[pk_field].type_
except KeyError:
return int
| 23.5
| 48
| 0.659574
| 19
| 141
| 4.421053
| 0.631579
| 0.166667
| 0.261905
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.255319
| 141
| 5
| 49
| 28.2
| 0.8
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.2
| false
| 0
| 0
| 0
| 0.6
| 0
| 1
| 0
| 0
| null | 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
|
0
| 4
|
36c48f8233004d32dbb5d12369252a2065ae8ce3
| 63
|
py
|
Python
|
beantools/teardrops/__init__.py
|
beanjs-kicad/beantools
|
3fa82ba92ba97d7aac80ee6898f3168596498a56
|
[
"MIT"
] | 9
|
2021-06-19T11:14:18.000Z
|
2021-11-16T09:33:25.000Z
|
beantools/teardrops/__init__.py
|
beanjs-kicad/beantools
|
3fa82ba92ba97d7aac80ee6898f3168596498a56
|
[
"MIT"
] | 4
|
2021-09-30T10:07:04.000Z
|
2022-03-31T10:44:24.000Z
|
beantools/teardrops/__init__.py
|
beanjs-kicad/beantools
|
3fa82ba92ba97d7aac80ee6898f3168596498a56
|
[
"MIT"
] | 2
|
2021-10-06T19:46:45.000Z
|
2022-03-31T12:45:03.000Z
|
from .plugin import TeardropPlugin
TeardropPlugin().register()
| 21
| 34
| 0.825397
| 6
| 63
| 8.666667
| 0.833333
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.079365
| 63
| 3
| 35
| 21
| 0.896552
| 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
|
36c4ddea46ac26671a2343940fa860690c5d9139
| 141
|
py
|
Python
|
functions_example.py/sibling_folder/file_D.py
|
Tommy3121173/tommy
|
429aefb377f84a1d49e85f825a32ac2c160ebc85
|
[
"MIT"
] | null | null | null |
functions_example.py/sibling_folder/file_D.py
|
Tommy3121173/tommy
|
429aefb377f84a1d49e85f825a32ac2c160ebc85
|
[
"MIT"
] | null | null | null |
functions_example.py/sibling_folder/file_D.py
|
Tommy3121173/tommy
|
429aefb377f84a1d49e85f825a32ac2c160ebc85
|
[
"MIT"
] | null | null | null |
# -*- coding: utf-8 -*-
"""
Created on Wed May 23 14:55:00 2018
@author: tommy_mizuki
"""
import sys
sys.path.append('../')
import file_B
| 11.75
| 35
| 0.631206
| 23
| 141
| 3.782609
| 0.913043
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.111111
| 0.170213
| 141
| 11
| 36
| 12.818182
| 0.632479
| 0.574468
| 0
| 0
| 0
| 0
| 0.058824
| 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
| 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
|
36ce7ea99bf50012b3e233414401b64cfe0ff9d6
| 95
|
py
|
Python
|
django_sourcebook/sourcebook/apps.py
|
maxblee/django_sourcebook
|
f90ca62cfe43c875a485f783ca1a06be40d9bbc5
|
[
"MIT"
] | null | null | null |
django_sourcebook/sourcebook/apps.py
|
maxblee/django_sourcebook
|
f90ca62cfe43c875a485f783ca1a06be40d9bbc5
|
[
"MIT"
] | null | null | null |
django_sourcebook/sourcebook/apps.py
|
maxblee/django_sourcebook
|
f90ca62cfe43c875a485f783ca1a06be40d9bbc5
|
[
"MIT"
] | null | null | null |
from django.apps import AppConfig
class SourcebookConfig(AppConfig):
name = "sourcebook"
| 15.833333
| 34
| 0.768421
| 10
| 95
| 7.3
| 0.9
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.157895
| 95
| 5
| 35
| 19
| 0.9125
| 0
| 0
| 0
| 0
| 0
| 0.105263
| 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
|
36f675600a81cb37446c1aafd724ff2c2b40c6ff
| 66
|
py
|
Python
|
tests/utils/__init__.py
|
Nikolay-Lysenko/rl-musician
|
559be64fbbe19fd82c591ddd4208c6327c3dfa57
|
[
"MIT"
] | 32
|
2019-10-06T19:59:44.000Z
|
2022-02-09T02:18:37.000Z
|
tests/utils/__init__.py
|
Nikolay-Lysenko/rl-musician
|
559be64fbbe19fd82c591ddd4208c6327c3dfa57
|
[
"MIT"
] | 7
|
2019-12-16T22:17:23.000Z
|
2021-12-13T18:34:33.000Z
|
tests/utils/__init__.py
|
Nikolay-Lysenko/rl-musician
|
559be64fbbe19fd82c591ddd4208c6327c3dfa57
|
[
"MIT"
] | 7
|
2019-11-10T04:55:43.000Z
|
2021-07-10T19:14:11.000Z
|
"""
Test `rlmusician.utils` package.
Author: Nikolay Lysenko
"""
| 11
| 32
| 0.69697
| 7
| 66
| 6.571429
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.136364
| 66
| 5
| 33
| 13.2
| 0.807018
| 0.863636
| 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
|
7ffc0202cec9e5ab02bd01401aa0b08478b196ef
| 184
|
py
|
Python
|
test/wsgi_flask_test.py
|
prprprus/viola
|
63cce05f8b393f6166278d9361823ca1a3544545
|
[
"MIT"
] | 6
|
2019-02-12T16:22:15.000Z
|
2020-05-30T11:14:51.000Z
|
test/wsgi_flask_test.py
|
hsxhr-10/viola
|
63cce05f8b393f6166278d9361823ca1a3544545
|
[
"MIT"
] | 1
|
2019-02-19T06:22:04.000Z
|
2019-02-23T04:47:38.000Z
|
test/wsgi_flask_test.py
|
hsxhr-10/viola
|
63cce05f8b393f6166278d9361823ca1a3544545
|
[
"MIT"
] | 1
|
2019-02-19T06:15:00.000Z
|
2019-02-19T06:15:00.000Z
|
from flask import Flask, render_template
# from flask import request
app = Flask(__name__)
@app.route('/')
def hello_world():
return render_template("hello.tpl", name="tiger")
| 16.727273
| 53
| 0.722826
| 25
| 184
| 5.04
| 0.6
| 0.142857
| 0.238095
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.146739
| 184
| 10
| 54
| 18.4
| 0.802548
| 0.13587
| 0
| 0
| 0
| 0
| 0.095541
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.2
| false
| 0
| 0.2
| 0.2
| 0.6
| 0
| 1
| 0
| 0
| null | 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
|
0
| 4
|
3d0282eadf6c40b67b20b09eb6c9eb3da82602cf
| 12,503
|
py
|
Python
|
model_sparse_bert_hf.py
|
playing-code/fairseq2
|
ac97b18c0aecca9eb36146492a1e95e521cb345a
|
[
"MIT"
] | null | null | null |
model_sparse_bert_hf.py
|
playing-code/fairseq2
|
ac97b18c0aecca9eb36146492a1e95e521cb345a
|
[
"MIT"
] | null | null | null |
model_sparse_bert_hf.py
|
playing-code/fairseq2
|
ac97b18c0aecca9eb36146492a1e95e521cb345a
|
[
"MIT"
] | null | null | null |
import torch
from torch import nn
# import torch_blocksparse as tbs
# from deepscale.pt.deepscale_constants import ROUTE_TRAIN
# import types
# from base.base_model import BaseModel
# from models.bert.masked_lm_loss import MaskedLMLoss
#from models.bert.modeling_bert import BertOnlyMLMHead, BertModel
from transformers.modeling_bert import BertModel, BertConfig, BertForMaskedLM, BertOnlyMLMHead
# from models.rankbertv2.modeling_v2 import RankBERTV2Model
# from sparse_transformers import SparseBert, SparseBertForSequenceClassification
#from models.bert.modeling_bert import BertLayerNorm
from transformers.modeling_roberta import RobertaConfig, RobertaForSequenceClassification
import torch.nn.functional as F
import torch
from torch import nn
import torch_blocksparse as tbs
import numpy as np
import types
#from models.bert.modeling_bert import BertOnlyMLMHead, BertModel
#from transformers.modeling_bert import BertModel, BertConfig, BertForMaskedLM, BertOnlyMLMHead
from sparse_transformers import SparseBert, SparseRobertaForSequenceClassification
class Plain_bert(nn.Module):#
def __init__(self,args):
super().__init__()
embedding_dim=768
self.roberta=RobertaForSequenceClassification.from_pretrained('roberta-base', return_dict=True,output_hidden_states=True)
#self.bert.config = sm.config
#self.roberta.resize_token_embeddings(119567)
#self.tie_weights()
self.dense = nn.Linear(embedding_dim, embedding_dim)
self.layer_norm = nn.LayerNorm(768)
self.init_weights(self.dense)
field=args.field
if field=='sparse_16_title':
self.his_len=16
self.set_len=32
elif field=='sparse_60_title':
self.his_len=60
self.set_len=32
elif field=='sparse_60_cat':
self.his_len=60
self.set_len=32
elif field=='sparse_20_cat_abs':
self.his_len=20
self.set_len=96
elif field=='sparse_120_title':
self.his_len=120
self.set_len=32
elif field=='sparse_120_cat':
self.his_len=120
self.set_len=32
elif field=='sparse_40_cat_abs':
self.his_len=40
self.set_len=96
elif field=='sparse_60_cat_abs':
self.his_len=60
self.set_len=96
elif field=='sparse_60_title_last':
self.his_len=60
self.set_len=32
elif field=='sparse_60_cat_last':
self.his_len=60
self.set_len=32
elif field=='sparse_80_title_reverse':
self.his_len=80
self.set_len=32
elif field=='sparse_80_title_non_reverse':
self.his_len=80
self.set_len=32
elif field=='sparse_16_title_reverse':
self.his_len=16
self.set_len=32
elif field=='sparse_16_title_non_reverse':
self.his_len=16
self.set_len=32
sm = SparseRobertaForSequenceClassification.from_pretrained('roberta-base', return_dict=True,output_hidden_states=True)
if 'reverse' in field:
sm.make_long_and_sparse(self.his_len*self.set_len, "variable", 16, False,[32]*int(self.set_len*self.his_len/512),[0])
self.atten_mask=torch.zeros((self.his_len*self.set_len,self.his_len*self.set_len))
elif 'last' in field:
sm.make_long_and_sparse(self.his_len*self.set_len+10*64, "longformer", 16, True,self.set_len,list(range(0,int(self.set_len/16)*self.his_len,int(self.set_len/16))))
self.atten_mask=torch.zeros((self.his_len*self.set_len+10*64,self.his_len*self.set_len+10*64))
else:
sm.make_long_and_sparse(self.his_len*self.set_len, "longformer", 16, True,self.set_len,list(range(0,int(self.set_len/16)*self.his_len,int(self.set_len/16))))
self.atten_mask=torch.zeros((self.his_len*self.set_len,self.his_len*self.set_len))
self.sparse_roberta = sm.roberta
self.atten_mask[0,:]=1
if 'non_reverse' in field:
self.atten_mask[:,0]=1
# self.atten_mask[0:512,0:512]=1
# self.atten_mask[512:1024,512:1024]=1
# self.atten_mask[1024:1536,1024:1536]=1
# self.atten_mask[1536:2048,1536:2048]=1
# self.atten_mask[2048:2560,2048:2560]=1
for item in range(0,self.set_len*self.his_len,512):
self.atten_mask[item:item+512,item:item+512]=1
elif 'reverse' in field:
self.atten_mask=None
# if 'reverse' in field:
# self.atten_mask[:,0]=1
# for item in range(0,self.set_len*self.his_len,512):
# self.atten_mask[item:item+512,item:item+512]=1
elif 'last' not in field:
self.atten_mask[:,1]=1
for item in range(0,int(self.set_len/16)*self.his_len,int(self.set_len/16)):
start=item*16
# self.atten_mask[start,:]=1#global
self.atten_mask[:,start]=1
for item in range(self.his_len):
self.atten_mask[item*self.set_len:(item+1)*self.set_len,item*self.set_len:(item+1)*self.set_len]=1
else:
self.atten_mask[:,1]=1
for item in range(0,int(self.set_len/16)*(self.his_len-10),int(self.set_len/16)):
start=item*16
self.atten_mask[:,start]=1
for item in range(int(self.set_len/16)*(self.his_len-10),int(self.set_len/16)*(self.his_len-10)+int((self.set_len+64)/16)*10,int((self.set_len+64)/16)):
start=item*16
self.atten_mask[:,start]=1
for item in range(self.his_len-10):
self.atten_mask[item*self.set_len:(item+1)*self.set_len,item*self.set_len:(item+1)*self.set_len]=1
for item in range(self.his_len-10,self.his_len):
start=50*self.set_len+(item-50)*(self.set_len+64)
end=start+(self.set_len+64)
self.atten_mask[start:end,start:end]=1
#print('????',start,end,self.atten_mask[start:end,start:end])
self.field=field
# torch.set_printoptions(profile="full")
# w=open('atten_mask.txt','w')
# w.write(str(self.atten_mask.cpu()))
# w.close()
def init_weights(self, module):
""" Initialize the weights.
"""
if isinstance(module, (nn.Linear, nn.Embedding)):
# Slightly different from the TF version which uses truncated_normal for initialization
# cf https://github.com/pytorch/pytorch/pull/5617
module.weight.data.normal_(mean=0.0, std=0.02)
# elif isinstance(module, BertLayerNorm):
# module.bias.data.zero_()
# module.weight.data.fill_(1.0)
# if isinstance(module, nn.Linear) and module.bias is not None:
# module.bias.data.zero_()
def forward(self,his_id , candidate_id,label,mode='train'):
#print('???',self.atten_mask)
# his_id=his_id[:,:,:1024]
# print('his_id: ',his_id[:,:1024].shape)
batch_size,can_num,can_legth=candidate_id.shape
batch_size,_,his_length=his_id.shape
if 'last' not in self.field:
#print('???',his_length)
assert his_length==self.his_len*self.set_len
else:
#print('???',his_length)
assert his_length==self.his_len*self.set_len+10*64
sample_size=candidate_id.shape[0]
his_id=his_id.reshape(-1,his_id.shape[-1])
candidate_id=candidate_id.reshape(-1,can_legth)
his_padding_mask = 1-his_id.eq(1).type_as(his_id)#
#print('???',his_padding_mask.shape,self.atten_mask.shape)
if self.atten_mask!=None:
#print('....mask....')
his_padding_mask=his_padding_mask.unsqueeze(1)
attn_mask=self.atten_mask.unsqueeze(0).repeat(batch_size,1,1)
attn_mask=attn_mask.cuda()
his_padding_mask=his_padding_mask*attn_mask
# print('???',his_padding_mask.dim())
# his_atten_mask[:,self.global_mask:]=0#除local size之外的是不能看见的
# his_atten_mask[:,self.global_mask:]=0#block里面的token除第一个之外是不能看见其他的
# his_atten_mask[self.global_mask,:]=0#和上一行对称的mask
# his_atten_mask[self.local_mask,:]=0#对每一个token mask掉local size中超出本篇文档的部分
# his_atten_mask[self.local_mask,:]=0#和上一条对称
can_padding_mask=1-candidate_id.eq(1).type_as(candidate_id)
#print('???',his_id.shape,his_padding_mask.shape)
outputs_his = self.sparse_roberta(input_ids=his_id, attention_mask=his_padding_mask)
# print('sparse_roberta: ', self.sparse_roberta.config.use_return_dict)
# print('???',outputs_his,len(outputs_his))#,[x.shape for x in outputs_his])
his_features=outputs_his.last_hidden_state[:,0,:]#[-1][:,0,:]
outputs_can = self.roberta(input_ids=candidate_id, attention_mask=can_padding_mask, labels=None)
can_features=outputs_can.hidden_states[-1][:,0,:]
his_features=his_features.reshape(batch_size,1,his_features.shape[-1])
can_features=can_features.reshape(batch_size,can_num,can_features.shape[-1])
his_features = self.dense(his_features)
his_features = self.layer_norm(his_features)
can_features = self.dense(can_features)
can_features = self.layer_norm(can_features)
res=torch.matmul(his_features,can_features.transpose(1,2))
if mode !='train':
return res.reshape(-1)#,label.view(-1)
res=res.reshape(-1,2)
#print('???',res,sample_size)
loss = F.nll_loss(
F.log_softmax(
res.view(-1, res.size(-1)),
dim=-1,
dtype=torch.float32,
),
label.view(-1),
reduction='sum',
#ignore_index=self.padding_idx,
)
#print('loss: ',loss)
return loss
def predict(self,his_id , candidate_id):
batch_size,can_num,can_legth=candidate_id.shape
batch_size,_,his_length=his_id.shape
if 'last' not in self.field:
#print('???',his_length)
assert his_length==self.his_len*self.set_len
else:
#print('???',his_length)
assert his_length==self.his_len*self.set_len+10*64
sample_size=candidate_id.shape[0]
his_id=his_id.reshape(-1,his_id.shape[-1])
candidate_id=candidate_id.reshape(-1,can_legth)
his_padding_mask = 1-his_id.eq(1).type_as(his_id)#
#print('???',his_padding_mask.shape,self.atten_mask.shape)
if self.atten_mask!=None:
#print('....mask....')
his_padding_mask=his_padding_mask.unsqueeze(1)
attn_mask=self.atten_mask.unsqueeze(0).repeat(batch_size,1,1)
attn_mask=attn_mask.cuda()
his_padding_mask=his_padding_mask*attn_mask
# print('???',his_padding_mask.dim())
# his_atten_mask[:,self.global_mask:]=0#除local size之外的是不能看见的
# his_atten_mask[:,self.global_mask:]=0#block里面的token除第一个之外是不能看见其他的
# his_atten_mask[self.global_mask,:]=0#和上一行对称的mask
# his_atten_mask[self.local_mask,:]=0#对每一个token mask掉local size中超出本篇文档的部分
# his_atten_mask[self.local_mask,:]=0#和上一条对称
can_padding_mask=1-candidate_id.eq(1).type_as(candidate_id)
#print('???',his_id.shape,his_padding_mask.shape)
outputs_his = self.sparse_roberta(input_ids=his_id, attention_mask=his_padding_mask)
# print('sparse_roberta: ', self.sparse_roberta.config.use_return_dict)
# print('???',outputs_his,len(outputs_his))#,[x.shape for x in outputs_his])
his_features=outputs_his.last_hidden_state[:,0,:]#[-1][:,0,:]
outputs_can = self.roberta(input_ids=candidate_id, attention_mask=can_padding_mask, labels=None)
can_features=outputs_can.hidden_states[-1][:,0,:]
his_features=his_features.reshape(batch_size,1,his_features.shape[-1])
can_features=can_features.reshape(batch_size,can_num,can_features.shape[-1])
his_features = self.dense(his_features)
his_features = self.layer_norm(his_features)
can_features = self.dense(can_features)
can_features = self.layer_norm(can_features)
res=torch.matmul(his_features,can_features.transpose(1,2))
res=res.squeeze(1)
return res
| 37.659639
| 175
| 0.639447
| 1,749
| 12,503
| 4.305317
| 0.126358
| 0.051129
| 0.073041
| 0.026029
| 0.765073
| 0.730279
| 0.721647
| 0.70239
| 0.682603
| 0.673838
| 0
| 0.041327
| 0.235543
| 12,503
| 331
| 176
| 37.773414
| 0.746495
| 0.247061
| 0
| 0.556818
| 0
| 0
| 0.039578
| 0.010755
| 0
| 0
| 0
| 0
| 0.022727
| 1
| 0.022727
| false
| 0
| 0.0625
| 0
| 0.107955
| 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
|
3d3883150d9541ca4b7584d12d3cd0e6d92b76c7
| 361
|
py
|
Python
|
commands/leaderboards.py
|
Dabomstew/goldenrod
|
36c4f9e5321788779840371b09a78cc6b26b38b1
|
[
"MIT"
] | 2
|
2015-05-20T00:42:03.000Z
|
2015-05-23T04:18:42.000Z
|
commands/leaderboards.py
|
Dabomstew/goldenrod
|
36c4f9e5321788779840371b09a78cc6b26b38b1
|
[
"MIT"
] | null | null | null |
commands/leaderboards.py
|
Dabomstew/goldenrod
|
36c4f9e5321788779840371b09a78cc6b26b38b1
|
[
"MIT"
] | null | null | null |
# coding=utf-8
import random
import time
import goldenrod, config
def execute(parser, bot, user, args):
bot.sendInfoMessage("leaderboards", user, "For more detailed leaderboards go here - http://twitchbot.dabomstew.com/goldenrod/leaderboards.php")
def requiredPerm():
return "anyone"
def canUseByWhisper():
return True
| 24.066667
| 148
| 0.695291
| 41
| 361
| 6.121951
| 0.756098
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.003484
| 0.204986
| 361
| 14
| 149
| 25.785714
| 0.87108
| 0.033241
| 0
| 0
| 0
| 0
| 0.349398
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.333333
| false
| 0
| 0.333333
| 0.222222
| 0.888889
| 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
|
3d39ce3a564de6d32433112bbcf131e6f03b9068
| 196
|
py
|
Python
|
docs/source/plots/logical_systems/dombi_with_p_0_dot_1.py
|
Parowicz/Yvain
|
e6caba0ef0c5bd030250a4ab67381aff4d653ba6
|
[
"Apache-2.0"
] | null | null | null |
docs/source/plots/logical_systems/dombi_with_p_0_dot_1.py
|
Parowicz/Yvain
|
e6caba0ef0c5bd030250a4ab67381aff4d653ba6
|
[
"Apache-2.0"
] | null | null | null |
docs/source/plots/logical_systems/dombi_with_p_0_dot_1.py
|
Parowicz/Yvain
|
e6caba0ef0c5bd030250a4ab67381aff4d653ba6
|
[
"Apache-2.0"
] | null | null | null |
from docs.source.plots.logical_systems.draw_logic import draw_system
from yvain.logical_systems import Dombi
if __name__ == '__main__':
draw_system(Dombi(0.1), "Dombi system with $p = 0.1$")
| 32.666667
| 68
| 0.765306
| 31
| 196
| 4.419355
| 0.612903
| 0.20438
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.023256
| 0.122449
| 196
| 5
| 69
| 39.2
| 0.773256
| 0
| 0
| 0
| 0
| 0
| 0.178571
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.5
| 0
| 0.5
| 0
| 0
| 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
| 1
| 0
| 0
| 0
|
0
| 4
|
3d5faea45d847105024b917262a74bfcd2547c15
| 404
|
py
|
Python
|
kiekie/middleware/cors.py
|
walterl/kiekie-server
|
30fad74e007d6331d4107d354571477bed0537d2
|
[
"MIT"
] | null | null | null |
kiekie/middleware/cors.py
|
walterl/kiekie-server
|
30fad74e007d6331d4107d354571477bed0537d2
|
[
"MIT"
] | null | null | null |
kiekie/middleware/cors.py
|
walterl/kiekie-server
|
30fad74e007d6331d4107d354571477bed0537d2
|
[
"MIT"
] | null | null | null |
from corsheaders.middleware import CorsMiddleware
from django.utils.deprecation import MiddlewareMixin
class UpgradedCorsMiddleware(MiddlewareMixin, CorsMiddleware):
"""
Middleware changed in Django 1.10, so this class with the
``MiddlewareMixin`` is now necessary.
:seealso:
https://docs.djangoproject.com/en/1.10/topics/http/middleware/#upgrading-middleware
"""
pass
| 28.857143
| 91
| 0.75
| 44
| 404
| 6.886364
| 0.727273
| 0.019802
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.017699
| 0.160891
| 404
| 13
| 92
| 31.076923
| 0.876106
| 0.480198
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0.25
| 0.5
| 0
| 0.75
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 1
| 0
| 1
| 0
|
0
| 4
|
3d629bd77859ddf5f404cda55c7d1392a99dab24
| 139
|
py
|
Python
|
breeze/backend/accounts/models.py
|
fmdzimin13/Breeze
|
10603b3828ce196eb6b97d63e386e06bd33029a4
|
[
"MIT"
] | null | null | null |
breeze/backend/accounts/models.py
|
fmdzimin13/Breeze
|
10603b3828ce196eb6b97d63e386e06bd33029a4
|
[
"MIT"
] | null | null | null |
breeze/backend/accounts/models.py
|
fmdzimin13/Breeze
|
10603b3828ce196eb6b97d63e386e06bd33029a4
|
[
"MIT"
] | null | null | null |
from django.db import models
from django.contrib.auth.models import AbstractUser
class User(AbstractUser):
token = models.TextField()
| 23.166667
| 51
| 0.791367
| 18
| 139
| 6.111111
| 0.666667
| 0.181818
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.129496
| 139
| 6
| 52
| 23.166667
| 0.909091
| 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
|
e9f5b33fb51fd39fb1501be1833bb2040a84da2b
| 453
|
py
|
Python
|
coalescence/exception.py
|
sterfield/coalescence
|
e9b1a786fc7cd42785afca50a1ee3a3c67cccca7
|
[
"MIT"
] | null | null | null |
coalescence/exception.py
|
sterfield/coalescence
|
e9b1a786fc7cd42785afca50a1ee3a3c67cccca7
|
[
"MIT"
] | null | null | null |
coalescence/exception.py
|
sterfield/coalescence
|
e9b1a786fc7cd42785afca50a1ee3a3c67cccca7
|
[
"MIT"
] | null | null | null |
class CoalescenceException(Exception):
def __init__(self, msg=''):
self.msg = msg
class NoSuchSourceException(CoalescenceException):
pass
class NotAnElementException(CoalescenceException):
pass
class NotAValueException(CoalescenceException):
pass
class NoValueException(CoalescenceException):
pass
class SerializationException(CoalescenceException):
pass
class CoercetionException(CoalescenceException):
pass
| 18.875
| 51
| 0.779249
| 34
| 453
| 10.264706
| 0.411765
| 0.412607
| 0.415473
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.154525
| 453
| 24
| 52
| 18.875
| 0.911227
| 0
| 0
| 0.4
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.066667
| false
| 0.4
| 0
| 0
| 0.533333
| 0
| 0
| 0
| 1
| null | 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
|
0
| 4
|
181cd59b3cc07de091518a8746ae035e850f8ebf
| 2,935
|
py
|
Python
|
generator/scripts/lextab.py
|
daewoong-jang/androidjnipp
|
0b87adb4c80ea817bceceb54a42e82e14f6d9bb6
|
[
"BSD-3-Clause"
] | 10
|
2016-12-08T16:48:34.000Z
|
2021-09-06T15:01:19.000Z
|
generator/scripts/lextab.py
|
daewoong-jang/androidjnipp
|
0b87adb4c80ea817bceceb54a42e82e14f6d9bb6
|
[
"BSD-3-Clause"
] | null | null | null |
generator/scripts/lextab.py
|
daewoong-jang/androidjnipp
|
0b87adb4c80ea817bceceb54a42e82e14f6d9bb6
|
[
"BSD-3-Clause"
] | 6
|
2016-12-06T13:06:11.000Z
|
2021-09-07T02:15:21.000Z
|
# lextab.py. This file automatically created by PLY (version 3.4). Don't edit!
_tabversion = '3.4'
_lextokens = {'DO': 1, 'REMAINDER_ASSIGN': 1, 'RSHIFT': 1, 'SYNCHRONIZED': 1, 'GTEQ': 1, 'MINUS_ASSIGN': 1, 'OR_ASSIGN': 1, 'VOID': 1, 'STRING_LITERAL': 1, 'ABSTRACT': 1, 'CHAR': 1, 'LSHIFT_ASSIGN': 1, 'WHILE': 1, 'SHORT': 1, 'STATIC': 1, 'PRIVATE': 1, 'LSHIFT': 1, 'CONTINUE': 1, 'THROWS': 1, 'NULL': 1, 'TRUE': 1, 'BYTE': 1, 'NEQ': 1, 'CASE': 1, 'TIMES_ASSIGN': 1, 'THROW': 1, 'NEW': 1, 'SWITCH': 1, 'LONG': 1, 'FINAL': 1, 'PROTECTED': 1, 'STRICTFP': 1, 'IF': 1, 'NUM': 1, 'CATCH': 1, 'ELLIPSIS': 1, 'NATIVE': 1, 'CLASS': 1, 'BLOCK_COMMENT': 1, 'IMPLEMENTS': 1, 'TRANSIENT': 1, 'LINE_COMMENT': 1, 'FOR': 1, 'PACKAGE': 1, 'PLUSPLUS': 1, 'AND_ASSIGN': 1, 'RRSHIFT_ASSIGN': 1, 'ENUM': 1, 'ELSE': 1, 'TRY': 1, 'FINALLY': 1, 'DIVIDE_ASSIGN': 1, 'PUBLIC': 1, 'MINUSMINUS': 1, 'EQ': 1, 'RRSHIFT': 1, 'AND': 1, 'ASSERT': 1, 'RETURN': 1, 'FALSE': 1, 'NAME': 1, 'XOR_ASSIGN': 1, 'THIS': 1, 'DOUBLE': 1, 'LTEQ': 1, 'RSHIFT_ASSIGN': 1, 'CHAR_LITERAL': 1, 'DEFAULT': 1, 'FLOAT': 1, 'BREAK': 1, 'INT': 1, 'BOOLEAN': 1, 'VOLATILE': 1, 'IMPORT': 1, 'PLUS_ASSIGN': 1, 'INTERFACE': 1, 'EXTENDS': 1, 'INSTANCEOF': 1, 'SUPER': 1, 'OR': 1}
_lexreflags = 0
_lexliterals = '()+-*/=?:,.^|&~!=[]{};<>@%'
_lexstateinfo = {'INITIAL': 'inclusive'}
_lexstatere = {'INITIAL': [('(?P<t_BLOCK_COMMENT>/\\*(.|\\n)*?\\*/)|(?P<t_NAME>[A-Za-z_$][A-Za-z0-9_$]*)|(?P<t_newline>\\n+)|(?P<t_newline2>(\\r\\n)+)|(?P<t_NUM>\\.?[0-9][0-9eE_lLdDa-fA-F.xXpP]*)|(?P<t_STRING_LITERAL>\\"([^\\\\\\n]|(\\\\.))*?\\")|(?P<t_CHAR_LITERAL>\\\'([^\\\\\\n]|(\\\\.))*?\\\')|(?P<t_ELLIPSIS>\\.\\.\\.)|(?P<t_ignore_LINE_COMMENT>//.*)|(?P<t_PLUSPLUS>\\+\\+)|(?P<t_MINUSMINUS>\\-\\-)|(?P<t_OR>\\|\\|)|(?P<t_RRSHIFT_ASSIGN>>>>=)|(?P<t_XOR_ASSIGN>\\^=)|(?P<t_RSHIFT_ASSIGN>>>=)|(?P<t_LSHIFT_ASSIGN><<=)|(?P<t_OR_ASSIGN>\\|=)|(?P<t_PLUS_ASSIGN>\\+=)|(?P<t_RRSHIFT>>>>)|(?P<t_TIMES_ASSIGN>\\*=)|(?P<t_LTEQ><=)|(?P<t_RSHIFT>>>)|(?P<t_AND_ASSIGN>&=)|(?P<t_DIVIDE_ASSIGN>/=)|(?P<t_GTEQ>>=)|(?P<t_MINUS_ASSIGN>-=)|(?P<t_EQ>==)|(?P<t_AND>&&)|(?P<t_REMAINDER_ASSIGN>%=)|(?P<t_NEQ>!=)|(?P<t_LSHIFT><<)', [None, ('t_BLOCK_COMMENT', 'BLOCK_COMMENT'), None, ('t_NAME', 'NAME'), ('t_newline', 'newline'), ('t_newline2', 'newline2'), None, (None, 'NUM'), (None, 'STRING_LITERAL'), None, None, (None, 'CHAR_LITERAL'), None, None, (None, 'ELLIPSIS'), (None, None), (None, 'PLUSPLUS'), (None, 'MINUSMINUS'), (None, 'OR'), (None, 'RRSHIFT_ASSIGN'), (None, 'XOR_ASSIGN'), (None, 'RSHIFT_ASSIGN'), (None, 'LSHIFT_ASSIGN'), (None, 'OR_ASSIGN'), (None, 'PLUS_ASSIGN'), (None, 'RRSHIFT'), (None, 'TIMES_ASSIGN'), (None, 'LTEQ'), (None, 'RSHIFT'), (None, 'AND_ASSIGN'), (None, 'DIVIDE_ASSIGN'), (None, 'GTEQ'), (None, 'MINUS_ASSIGN'), (None, 'EQ'), (None, 'AND'), (None, 'REMAINDER_ASSIGN'), (None, 'NEQ'), (None, 'LSHIFT')])]}
_lexstateignore = {'INITIAL': ' \t\x0c'}
_lexstateerrorf = {'INITIAL': 't_error'}
| 293.5
| 1,523
| 0.57138
| 427
| 2,935
| 3.709602
| 0.283372
| 0.039141
| 0.055556
| 0.012626
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.035768
| 0.09506
| 2,935
| 9
| 1,524
| 326.111111
| 0.560617
| 0.025894
| 0
| 0
| 0
| 0.25
| 0.587329
| 0.273014
| 0
| 0
| 0
| 0
| 0.125
| 1
| 0
| false
| 0
| 0.125
| 0
| 0.125
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
18302010bbec67f854b19d2d121973d6cca2bbbc
| 66
|
py
|
Python
|
src/core/distancematrix/__init__.py
|
wei200/intelli-trip-planner
|
dbeb7829497731f32b59547cc69dcb90dbf80794
|
[
"BSD-3-Clause"
] | 3
|
2020-05-02T11:51:49.000Z
|
2020-05-09T14:46:43.000Z
|
src/core/distancematrix/__init__.py
|
wei200/intelli-trip-planner
|
dbeb7829497731f32b59547cc69dcb90dbf80794
|
[
"BSD-3-Clause"
] | 344
|
2020-06-10T02:37:32.000Z
|
2022-03-31T00:12:33.000Z
|
src/core/distancematrix/__init__.py
|
dongskyler/RouteOptimization
|
06dd2d002692fb35ba8af75a60c1c8df2aa64a3d
|
[
"BSD-3-Clause"
] | 4
|
2020-05-02T18:07:49.000Z
|
2020-05-31T11:35:09.000Z
|
"""
Get and manipulate distance matrices from Google Maps API
"""
| 16.5
| 57
| 0.742424
| 9
| 66
| 5.444444
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.166667
| 66
| 3
| 58
| 22
| 0.890909
| 0.863636
| 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
|
184388b14fe6c4d1081dec28ade94743c5e20741
| 52
|
py
|
Python
|
src/foursquare_swarm_ical/__main__.py
|
liskin/foursquare-swarm-ical
|
2497f496f6430059c2cc5fc13be0ce4aeaa643e6
|
[
"MIT"
] | 6
|
2021-03-20T07:32:05.000Z
|
2022-03-13T00:22:54.000Z
|
src/foursquare_swarm_ical/__main__.py
|
liskin/foursquare-swarm-ical
|
2497f496f6430059c2cc5fc13be0ce4aeaa643e6
|
[
"MIT"
] | null | null | null |
src/foursquare_swarm_ical/__main__.py
|
liskin/foursquare-swarm-ical
|
2497f496f6430059c2cc5fc13be0ce4aeaa643e6
|
[
"MIT"
] | 1
|
2022-03-13T00:21:39.000Z
|
2022-03-13T00:21:39.000Z
|
from foursquare_swarm_ical.main import main
main()
| 13
| 43
| 0.826923
| 8
| 52
| 5.125
| 0.75
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.115385
| 52
| 3
| 44
| 17.333333
| 0.891304
| 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
|
184b51794453bd8462d75ad272836b0f30feb6d9
| 59
|
py
|
Python
|
problem/01000~09999/01252/1252.py3.py
|
njw1204/BOJ-AC
|
1de41685725ae4657a7ff94e413febd97a888567
|
[
"MIT"
] | 1
|
2019-04-19T16:37:44.000Z
|
2019-04-19T16:37:44.000Z
|
problem/01000~09999/01252/1252.py3.py
|
njw1204/BOJ-AC
|
1de41685725ae4657a7ff94e413febd97a888567
|
[
"MIT"
] | 1
|
2019-04-20T11:42:44.000Z
|
2019-04-20T11:42:44.000Z
|
problem/01000~09999/01252/1252.py3.py
|
njw1204/BOJ-AC
|
1de41685725ae4657a7ff94e413febd97a888567
|
[
"MIT"
] | 3
|
2019-04-19T16:37:47.000Z
|
2021-10-25T00:45:00.000Z
|
a,b=[int(i,2) for i in input().split()]
print(bin(a+b)[2:])
| 29.5
| 39
| 0.576271
| 15
| 59
| 2.266667
| 0.733333
| 0.117647
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.037037
| 0.084746
| 59
| 2
| 40
| 29.5
| 0.592593
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0
| 0
| 0
| 0.5
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 1
|
0
| 4
|
185ee4264430b2f615dfc9500e637734b28fea7a
| 50
|
py
|
Python
|
custom_components/hive/switch.py
|
rjenx/HomeAssistant_Public
|
97701f4b8b41beefd87350149f347704fe51df0b
|
[
"MIT"
] | null | null | null |
custom_components/hive/switch.py
|
rjenx/HomeAssistant_Public
|
97701f4b8b41beefd87350149f347704fe51df0b
|
[
"MIT"
] | null | null | null |
custom_components/hive/switch.py
|
rjenx/HomeAssistant_Public
|
97701f4b8b41beefd87350149f347704fe51df0b
|
[
"MIT"
] | null | null | null |
from homeassistant.components.hive.switch import *
| 50
| 50
| 0.86
| 6
| 50
| 7.166667
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.06
| 50
| 1
| 50
| 50
| 0.914894
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 1
| 0
| 1
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
186d4171adbb49fa2bca577340d9322cc150a238
| 145
|
py
|
Python
|
api/serializers.py
|
mkeller3/django_celery_redis
|
193e550644ef79b5f12d51aa8866c20f1a7a2a3a
|
[
"Apache-2.0"
] | null | null | null |
api/serializers.py
|
mkeller3/django_celery_redis
|
193e550644ef79b5f12d51aa8866c20f1a7a2a3a
|
[
"Apache-2.0"
] | null | null | null |
api/serializers.py
|
mkeller3/django_celery_redis
|
193e550644ef79b5f12d51aa8866c20f1a7a2a3a
|
[
"Apache-2.0"
] | null | null | null |
from rest_framework import serializers
from .models import *
class taskSerializer(serializers.Serializer):
task_id = serializers.CharField()
| 29
| 45
| 0.813793
| 16
| 145
| 7.25
| 0.75
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.117241
| 145
| 5
| 46
| 29
| 0.90625
| 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
|
1876f90433b82dc1312d2eeaceac50e780eea60e
| 900
|
py
|
Python
|
wepy/resampling/distances/randomwalk.py
|
fabian-paul/wepy
|
3a470f364a5ffbefcdb5d17a12cd08d90f4944e4
|
[
"MIT"
] | null | null | null |
wepy/resampling/distances/randomwalk.py
|
fabian-paul/wepy
|
3a470f364a5ffbefcdb5d17a12cd08d90f4944e4
|
[
"MIT"
] | null | null | null |
wepy/resampling/distances/randomwalk.py
|
fabian-paul/wepy
|
3a470f364a5ffbefcdb5d17a12cd08d90f4944e4
|
[
"MIT"
] | null | null | null |
"""
This module here is part of RandomWalk object that implements computing
distance between pairs of positions of RandomWalk walkers.
"""
import numpy as np
from wepy.resampling.distances.distance import Distance
class RandomWalkDistance(Distance):
"""
Computes the distance between pairs of positions and returns a distance matrix
where the element (d_ij) is the average of the difference between posiotion of
walker i and j.
"""
def __init__(self):
pass
def image(self, state):
return state['positions']
def image_distance(self, image_a, image_b):
"""Compute the distance between posiotion of two states.
:param position_a: posiotion of first state
:param position_b: posiotion of second state
:returns: a distance value
:rtype: float
"""
return np.average(np.abs(image_a - image_b))
| 26.470588
| 82
| 0.691111
| 119
| 900
| 5.12605
| 0.512605
| 0.072131
| 0.065574
| 0.072131
| 0.101639
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.242222
| 900
| 33
| 83
| 27.272727
| 0.894428
| 0.543333
| 0
| 0
| 0
| 0
| 0.026946
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.333333
| false
| 0.111111
| 0.222222
| 0.111111
| 0.888889
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
| 1
| 1
| 0
|
0
| 4
|
a113e0bd2a0b1f7ed0916b842ea1b2d543fa5399
| 74
|
py
|
Python
|
src/InstPyr/MyDevices/helpers.py
|
soodsidd/instpyr
|
138d0a8164dc388187fde58329b9ff770af77af4
|
[
"MIT"
] | null | null | null |
src/InstPyr/MyDevices/helpers.py
|
soodsidd/instpyr
|
138d0a8164dc388187fde58329b9ff770af77af4
|
[
"MIT"
] | null | null | null |
src/InstPyr/MyDevices/helpers.py
|
soodsidd/instpyr
|
138d0a8164dc388187fde58329b9ff770af77af4
|
[
"MIT"
] | null | null | null |
from dataclasses import dataclass,fields
@dataclass
class Sensor:
pass
| 14.8
| 40
| 0.810811
| 9
| 74
| 6.666667
| 0.888889
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.148649
| 74
| 5
| 41
| 14.8
| 0.952381
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 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
| 0
| 1
| 1
| 0
| 0
| 0
| 0
|
0
| 4
|
a12648775682d874b9b4dd999713691642fa5bf7
| 65
|
py
|
Python
|
userbot/config.py
|
TAMILVIP007/javes-3.0
|
d9238785fa2d79740bbb526aca92455dbccb3838
|
[
"MIT"
] | 1
|
2021-05-06T18:30:50.000Z
|
2021-05-06T18:30:50.000Z
|
userbot/config.py
|
hellboi-atul/javes-3.0
|
8777d482bd1ee877a96332a2cd84d880c151fa43
|
[
"MIT"
] | null | null | null |
userbot/config.py
|
hellboi-atul/javes-3.0
|
8777d482bd1ee877a96332a2cd84d880c151fa43
|
[
"MIT"
] | null | null | null |
from userbot.javes_main.heroku_var import config
Config = config
| 21.666667
| 48
| 0.846154
| 10
| 65
| 5.3
| 0.8
| 0.45283
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.107692
| 65
| 2
| 49
| 32.5
| 0.913793
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.5
| 0
| 0.5
| 0
| 1
| 0
| 0
| null | 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
a155b5e4cfcbb29e0ce942f23f4ebfd994f7e92f
| 377
|
py
|
Python
|
numba/cuda/initialize.py
|
luk-f-a/numba
|
3a682bd827e416335e3574bc7b10f0ec69adb701
|
[
"BSD-2-Clause",
"BSD-3-Clause"
] | 3
|
2017-08-11T13:05:44.000Z
|
2021-08-10T07:47:13.000Z
|
numba/cuda/initialize.py
|
luk-f-a/numba
|
3a682bd827e416335e3574bc7b10f0ec69adb701
|
[
"BSD-2-Clause",
"BSD-3-Clause"
] | null | null | null |
numba/cuda/initialize.py
|
luk-f-a/numba
|
3a682bd827e416335e3574bc7b10f0ec69adb701
|
[
"BSD-2-Clause",
"BSD-3-Clause"
] | 1
|
2021-01-31T18:58:54.000Z
|
2021-01-31T18:58:54.000Z
|
def init_jit():
from numba.cuda.compiler import Dispatcher
return Dispatcher
def initialize_all():
# Import models to register them with the data model manager
import numba.cuda.models # noqa: F401
from numba.core.registry import dispatcher_registry
dispatcher_registry.ondemand['gpu'] = init_jit
dispatcher_registry.ondemand['cuda'] = init_jit
| 29
| 64
| 0.748011
| 49
| 377
| 5.612245
| 0.55102
| 0.076364
| 0.189091
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.009709
| 0.180371
| 377
| 12
| 65
| 31.416667
| 0.880259
| 0.183024
| 0
| 0
| 0
| 0
| 0.022951
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.25
| true
| 0
| 0.375
| 0
| 0.75
| 0
| 0
| 0
| 0
| null | 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
a188882f4befae3b8e008f7a1615a212f3f2cc40
| 73
|
py
|
Python
|
example/__init__.py
|
Tunnel-vision/LambdaLog
|
b68e67b14f0c9afd0497495ae43354f4dc28e034
|
[
"MIT"
] | 1
|
2020-01-01T07:29:51.000Z
|
2020-01-01T07:29:51.000Z
|
example/__init__.py
|
Tunnel-vision/LambdaLog
|
b68e67b14f0c9afd0497495ae43354f4dc28e034
|
[
"MIT"
] | null | null | null |
example/__init__.py
|
Tunnel-vision/LambdaLog
|
b68e67b14f0c9afd0497495ae43354f4dc28e034
|
[
"MIT"
] | null | null | null |
# -*- coding:utf-8 -*-
__author__ = '10029'
__time__ = '2019/12/31 10:10'
| 24.333333
| 29
| 0.616438
| 11
| 73
| 3.363636
| 0.909091
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.285714
| 0.136986
| 73
| 3
| 29
| 24.333333
| 0.301587
| 0.273973
| 0
| 0
| 0
| 0
| 0.403846
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 1
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
a1c282d5dd5726c07e2ea6e7a03d9bca6b9a2b0f
| 27
|
py
|
Python
|
mkdocs/__init__.py
|
samhatfield/mkdocs
|
4948ef9a3a4fb0b3f17f6037ffa9c9062821d2ee
|
[
"BSD-2-Clause"
] | null | null | null |
mkdocs/__init__.py
|
samhatfield/mkdocs
|
4948ef9a3a4fb0b3f17f6037ffa9c9062821d2ee
|
[
"BSD-2-Clause"
] | 1
|
2022-02-17T04:10:43.000Z
|
2022-02-17T04:10:43.000Z
|
mkdocs/__init__.py
|
samhatfield/mkdocs
|
4948ef9a3a4fb0b3f17f6037ffa9c9062821d2ee
|
[
"BSD-2-Clause"
] | null | null | null |
__version__ = '0.14.0.dev'
| 13.5
| 26
| 0.666667
| 5
| 27
| 2.8
| 0.8
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.166667
| 0.111111
| 27
| 1
| 27
| 27
| 0.416667
| 0
| 0
| 0
| 0
| 0
| 0.37037
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
a1f08e85d361108fc0afd6c10be549fcba931c6f
| 63,870
|
py
|
Python
|
my_server/dist/ba_root/mods/BsTextOnMap.py
|
FireFighter1027/ba_1.6
|
8e0460c4d7228102726578fb4acd4ff081e12fc3
|
[
"MIT"
] | 6
|
2021-04-16T14:25:25.000Z
|
2021-11-18T17:20:19.000Z
|
my_server/dist/ba_root/mods/BsTextOnMap.py
|
FireFighter1027/ba_1.6
|
8e0460c4d7228102726578fb4acd4ff081e12fc3
|
[
"MIT"
] | 1
|
2021-08-30T10:09:06.000Z
|
2021-09-21T10:44:15.000Z
|
my_server/dist/ba_root/mods/BsTextOnMap.py
|
FireFighter1027/ba_1.6
|
8e0460c4d7228102726578fb4acd4ff081e12fc3
|
[
"MIT"
] | 2
|
2021-04-20T15:39:27.000Z
|
2021-07-18T08:45:56.000Z
|
texts = []
#texts = ["\ue00cPlay 2 Games to Get Registered\ue00c", "Only Top 5 Players of this server can only use custom Tag\n Create a profile with '/tag<space>' as prefix\n Ex : '/tag MyCustomTag'", "\ue046DO NOT ASK FOR ADMINSHIP\ue046", "Visit eoni.ml website or join Discord @ \nhttp://discord.io/EoniOfficial \ngroup to know more about us !"]
# Released under the MIT License. See LICENSE for details.
#
"""Map related functionality."""
import ba,_ba,random,mysettings
from mysettings import settings, uni, screenTextColor, multicolor
from bastd.gameutils import SharedObjects
from typing import Any, List, Dict
from bastd import maps as bastd_maps
from bastd.maps import *
our_texts = texts if texts else mysettings.texts
myscript = '''
def showtext(tex, c):
for k,v in uni.items():
if k in tex:
tex = tex.replace(k,v)
t = ba.newnode('text',attrs={'text':tex.encode('utf-8').decode('unicode-escape'),'color': screenTextColor if screenTextColor else (1,1,1),'maxwidth':0,'position':(0,140),'shadow':0.4,'flatness':0.8,'h_align':'center','v_attach':'bottom'})
ba.animate(t,'opacity',{0:0,c-1001:0,c-1000:0.5,c:1.0}, timetype=ba.TimeType.SIM, timeformat=ba.TimeFormat.MILLISECONDS)
ba.animate(t,'scale',{0:0,c-1001:0,c-1000:0.5,c:0.8}, timetype=ba.TimeType.SIM, timeformat=ba.TimeFormat.MILLISECONDS)
if not screenTextColor:
ba.animate_array(t,'color',3,multicolor,True,timetype=ba.TimeType.SIM,timeformat=ba.TimeFormat.MILLISECONDS)
d_timer = ba.timer(((c+13000) / 1000),t.delete)
mytext = showtext
def startShowing():
b = 1000
for text in our_texts:
mytext(text, b)
b += 15000
if settings['screenTexts']:
starter = ba.Timer(500, ba.Call(startShowing), timeformat=ba.TimeFormat.MILLISECONDS)
runner = ba.Timer(len(our_texts)*15500, ba.Call(startShowing), timeformat=ba.TimeFormat.MILLISECONDS, repeat = True)
def checkSettingsFile():
global starter
global runner
global mytext
if not settings['screenTexts']:
starter = None
runner = None
if (settings['screenTexts']) and (None in [starter, runner]):
starter = ba.Timer(500, ba.Call(startShowing), timeformat=ba.TimeFormat.MILLISECONDS)
runner = ba.Timer(len(our_texts)*15500, ba.Call(startShowing), timeformat=ba.TimeFormat.MILLISECONDS, repeat = True)
checkSettingsFileTimer = ba.Timer(10, ba.Call(checkSettingsFile), repeat = True)'''
#############################################################################################################################################
class myHockeyStadium(ba.Map):
"""Stadium map used for ice hockey games."""
from bastd.mapdata import hockey_stadium as defs
name = 'Hockey Stadium'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
return ['melee', 'hockey', 'team_flag', 'keep_away']
@classmethod
def get_preview_texture_name(cls) -> str:
return 'hockeyStadiumPreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'models': (ba.getmodel('hockeyStadiumOuter'),
ba.getmodel('hockeyStadiumInner'),
ba.getmodel('hockeyStadiumStands')),
'vr_fill_model': ba.getmodel('footballStadiumVRFill'),
'collide_model': ba.getcollidemodel('hockeyStadiumCollide'),
'tex': ba.gettexture('hockeyStadium'),
'stands_tex': ba.gettexture('footballStadium')
}
mat = ba.Material()
mat.add_actions(actions=('modify_part_collision', 'friction', 0.01))
data['ice_material'] = mat
return data
def __init__(self) -> None:
super().__init__()
shared = SharedObjects.get()
self.node = ba.newnode('terrain',
delegate=self,
attrs={
'model':
self.preloaddata['models'][0],
'collide_model':
self.preloaddata['collide_model'],
'color_texture':
self.preloaddata['tex'],
'materials': [
shared.footing_material,
self.preloaddata['ice_material']
]
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['vr_fill_model'],
'vr_only': True,
'lighting': False,
'background': True,
'color_texture': self.preloaddata['stands_tex']
})
mats = [shared.footing_material, self.preloaddata['ice_material']]
self.floor = ba.newnode('terrain',
attrs={
'model': self.preloaddata['models'][1],
'color_texture': self.preloaddata['tex'],
'opacity': 0.92,
'opacity_in_low_or_medium_quality': 1.0,
'materials': mats
})
self.stands = ba.newnode(
'terrain',
attrs={
'model': self.preloaddata['models'][2],
'visible_in_reflections': False,
'color_texture': self.preloaddata['stands_tex']
})
gnode = ba.getactivity().globalsnode
gnode.floor_reflection = True
gnode.debris_friction = 0.3
gnode.debris_kill_height = -0.3
gnode.tint = (1.2, 1.3, 1.33)
gnode.ambient_color = (1.15, 1.25, 1.6)
gnode.vignette_outer = (0.66, 0.67, 0.73)
gnode.vignette_inner = (0.93, 0.93, 0.95)
gnode.vr_camera_offset = (0, -0.8, -1.1)
gnode.vr_near_clip = 0.5
self.is_hockey = True
exec(myscript)
bastd_maps.HockeyStadium = myHockeyStadium
class myFootballStadium(ba.Map):
"""Stadium map for football games."""
from bastd.mapdata import football_stadium as defs
name = 'Football Stadium'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
return ['melee', 'football', 'team_flag', 'keep_away']
@classmethod
def get_preview_texture_name(cls) -> str:
return 'footballStadiumPreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'model': ba.getmodel('footballStadium'),
'vr_fill_model': ba.getmodel('footballStadiumVRFill'),
'collide_model': ba.getcollidemodel('footballStadiumCollide'),
'tex': ba.gettexture('footballStadium')
}
return data
def __init__(self) -> None:
super().__init__()
shared = SharedObjects.get()
self.node = ba.newnode(
'terrain',
delegate=self,
attrs={
'model': self.preloaddata['model'],
'collide_model': self.preloaddata['collide_model'],
'color_texture': self.preloaddata['tex'],
'materials': [shared.footing_material]
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['vr_fill_model'],
'lighting': False,
'vr_only': True,
'background': True,
'color_texture': self.preloaddata['tex']
})
gnode = ba.getactivity().globalsnode
gnode.tint = (1.3, 1.2, 1.0)
gnode.ambient_color = (1.3, 1.2, 1.0)
gnode.vignette_outer = (0.57, 0.57, 0.57)
gnode.vignette_inner = (0.9, 0.9, 0.9)
gnode.vr_camera_offset = (0, -0.8, -1.1)
gnode.vr_near_clip = 0.5
exec(myscript)
def is_point_near_edge(self,
point: ba.Vec3,
running: bool = False) -> bool:
box_position = self.defs.boxes['edge_box'][0:3]
box_scale = self.defs.boxes['edge_box'][6:9]
xpos = (point.x - box_position[0]) / box_scale[0]
zpos = (point.z - box_position[2]) / box_scale[2]
return xpos < -0.5 or xpos > 0.5 or zpos < -0.5 or zpos > 0.5
bastd_maps.FootballStadium = myFootballStadium
class myBridgit(ba.Map):
"""Map with a narrow bridge in the middle."""
from bastd.mapdata import bridgit as defs
name = 'Bridgit'
dataname = 'bridgit'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
# print('getting playtypes', cls._getdata()['play_types'])
return ['melee', 'team_flag', 'keep_away']
@classmethod
def get_preview_texture_name(cls) -> str:
return 'bridgitPreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'model_top': ba.getmodel('bridgitLevelTop'),
'model_bottom': ba.getmodel('bridgitLevelBottom'),
'model_bg': ba.getmodel('natureBackground'),
'bg_vr_fill_model': ba.getmodel('natureBackgroundVRFill'),
'collide_model': ba.getcollidemodel('bridgitLevelCollide'),
'tex': ba.gettexture('bridgitLevelColor'),
'model_bg_tex': ba.gettexture('natureBackgroundColor'),
'collide_bg': ba.getcollidemodel('natureBackgroundCollide'),
'railing_collide_model':
(ba.getcollidemodel('bridgitLevelRailingCollide')),
'bg_material': ba.Material()
}
data['bg_material'].add_actions(actions=('modify_part_collision',
'friction', 10.0))
return data
def __init__(self) -> None:
super().__init__()
shared = SharedObjects.get()
self.node = ba.newnode(
'terrain',
delegate=self,
attrs={
'collide_model': self.preloaddata['collide_model'],
'model': self.preloaddata['model_top'],
'color_texture': self.preloaddata['tex'],
'materials': [shared.footing_material]
})
self.bottom = ba.newnode('terrain',
attrs={
'model': self.preloaddata['model_bottom'],
'lighting': False,
'color_texture': self.preloaddata['tex']
})
self.background = ba.newnode(
'terrain',
attrs={
'model': self.preloaddata['model_bg'],
'lighting': False,
'background': True,
'color_texture': self.preloaddata['model_bg_tex']
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['bg_vr_fill_model'],
'lighting': False,
'vr_only': True,
'background': True,
'color_texture': self.preloaddata['model_bg_tex']
})
self.railing = ba.newnode(
'terrain',
attrs={
'collide_model': self.preloaddata['railing_collide_model'],
'materials': [shared.railing_material],
'bumper': True
})
self.bg_collide = ba.newnode('terrain',
attrs={
'collide_model':
self.preloaddata['collide_bg'],
'materials': [
shared.footing_material,
self.preloaddata['bg_material'],
shared.death_material
]
})
gnode = ba.getactivity().globalsnode
gnode.tint = (1.1, 1.2, 1.3)
gnode.ambient_color = (1.1, 1.2, 1.3)
gnode.vignette_outer = (0.65, 0.6, 0.55)
gnode.vignette_inner = (0.9, 0.9, 0.93)
exec(myscript)
bastd_maps.Bridgit = myBridgit
class myBigG(ba.Map):
"""Large G shaped map for racing"""
from bastd.mapdata import big_g as defs
name = 'Big G'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
return [
'race', 'melee', 'keep_away', 'team_flag', 'king_of_the_hill',
'conquest'
]
@classmethod
def get_preview_texture_name(cls) -> str:
return 'bigGPreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'model_top': ba.getmodel('bigG'),
'model_bottom': ba.getmodel('bigGBottom'),
'model_bg': ba.getmodel('natureBackground'),
'bg_vr_fill_model': ba.getmodel('natureBackgroundVRFill'),
'collide_model': ba.getcollidemodel('bigGCollide'),
'tex': ba.gettexture('bigG'),
'model_bg_tex': ba.gettexture('natureBackgroundColor'),
'collide_bg': ba.getcollidemodel('natureBackgroundCollide'),
'bumper_collide_model': ba.getcollidemodel('bigGBumper'),
'bg_material': ba.Material()
}
data['bg_material'].add_actions(actions=('modify_part_collision',
'friction', 10.0))
return data
def __init__(self) -> None:
super().__init__()
shared = SharedObjects.get()
self.node = ba.newnode(
'terrain',
delegate=self,
attrs={
'collide_model': self.preloaddata['collide_model'],
'color': (0.7, 0.7, 0.7),
'model': self.preloaddata['model_top'],
'color_texture': self.preloaddata['tex'],
'materials': [shared.footing_material]
})
self.bottom = ba.newnode('terrain',
attrs={
'model': self.preloaddata['model_bottom'],
'color': (0.7, 0.7, 0.7),
'lighting': False,
'color_texture': self.preloaddata['tex']
})
self.background = ba.newnode(
'terrain',
attrs={
'model': self.preloaddata['model_bg'],
'lighting': False,
'background': True,
'color_texture': self.preloaddata['model_bg_tex']
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['bg_vr_fill_model'],
'lighting': False,
'vr_only': True,
'background': True,
'color_texture': self.preloaddata['model_bg_tex']
})
self.railing = ba.newnode(
'terrain',
attrs={
'collide_model': self.preloaddata['bumper_collide_model'],
'materials': [shared.railing_material],
'bumper': True
})
self.bg_collide = ba.newnode('terrain',
attrs={
'collide_model':
self.preloaddata['collide_bg'],
'materials': [
shared.footing_material,
self.preloaddata['bg_material'],
shared.death_material
]
})
gnode = ba.getactivity().globalsnode
gnode.tint = (1.1, 1.2, 1.3)
gnode.ambient_color = (1.1, 1.2, 1.3)
gnode.vignette_outer = (0.65, 0.6, 0.55)
gnode.vignette_inner = (0.9, 0.9, 0.93)
exec(myscript)
bastd_maps.BigG = myBigG
class myRoundabout(ba.Map):
"""CTF map featuring two platforms and a long way around between them"""
from bastd.mapdata import roundabout as defs
name = 'Roundabout'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
return ['melee', 'keep_away', 'team_flag']
@classmethod
def get_preview_texture_name(cls) -> str:
return 'roundaboutPreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'model': ba.getmodel('roundaboutLevel'),
'model_bottom': ba.getmodel('roundaboutLevelBottom'),
'model_bg': ba.getmodel('natureBackground'),
'bg_vr_fill_model': ba.getmodel('natureBackgroundVRFill'),
'collide_model': ba.getcollidemodel('roundaboutLevelCollide'),
'tex': ba.gettexture('roundaboutLevelColor'),
'model_bg_tex': ba.gettexture('natureBackgroundColor'),
'collide_bg': ba.getcollidemodel('natureBackgroundCollide'),
'railing_collide_model':
(ba.getcollidemodel('roundaboutLevelBumper')),
'bg_material': ba.Material()
}
data['bg_material'].add_actions(actions=('modify_part_collision',
'friction', 10.0))
return data
def __init__(self) -> None:
super().__init__(vr_overlay_offset=(0, -1, 1))
shared = SharedObjects.get()
self.node = ba.newnode(
'terrain',
delegate=self,
attrs={
'collide_model': self.preloaddata['collide_model'],
'model': self.preloaddata['model'],
'color_texture': self.preloaddata['tex'],
'materials': [shared.footing_material]
})
self.bottom = ba.newnode('terrain',
attrs={
'model': self.preloaddata['model_bottom'],
'lighting': False,
'color_texture': self.preloaddata['tex']
})
self.background = ba.newnode(
'terrain',
attrs={
'model': self.preloaddata['model_bg'],
'lighting': False,
'background': True,
'color_texture': self.preloaddata['model_bg_tex']
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['bg_vr_fill_model'],
'lighting': False,
'vr_only': True,
'background': True,
'color_texture': self.preloaddata['model_bg_tex']
})
self.bg_collide = ba.newnode('terrain',
attrs={
'collide_model':
self.preloaddata['collide_bg'],
'materials': [
shared.footing_material,
self.preloaddata['bg_material'],
shared.death_material
]
})
self.railing = ba.newnode(
'terrain',
attrs={
'collide_model': self.preloaddata['railing_collide_model'],
'materials': [shared.railing_material],
'bumper': True
})
gnode = ba.getactivity().globalsnode
gnode.tint = (1.0, 1.05, 1.1)
gnode.ambient_color = (1.0, 1.05, 1.1)
gnode.shadow_ortho = True
gnode.vignette_outer = (0.63, 0.65, 0.7)
gnode.vignette_inner = (0.97, 0.95, 0.93)
exec(myscript)
bastd_maps.Roundabout = myRoundabout
class myMonkeyFace(ba.Map):
"""Map sorta shaped like a monkey face; teehee!"""
from bastd.mapdata import monkey_face as defs
name = 'Monkey Face'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
return ['melee', 'keep_away', 'team_flag']
@classmethod
def get_preview_texture_name(cls) -> str:
return 'monkeyFacePreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'model': ba.getmodel('monkeyFaceLevel'),
'bottom_model': ba.getmodel('monkeyFaceLevelBottom'),
'model_bg': ba.getmodel('natureBackground'),
'bg_vr_fill_model': ba.getmodel('natureBackgroundVRFill'),
'collide_model': ba.getcollidemodel('monkeyFaceLevelCollide'),
'tex': ba.gettexture('monkeyFaceLevelColor'),
'model_bg_tex': ba.gettexture('natureBackgroundColor'),
'collide_bg': ba.getcollidemodel('natureBackgroundCollide'),
'railing_collide_model':
(ba.getcollidemodel('monkeyFaceLevelBumper')),
'bg_material': ba.Material()
}
data['bg_material'].add_actions(actions=('modify_part_collision',
'friction', 10.0))
return data
def __init__(self) -> None:
super().__init__()
shared = SharedObjects.get()
self.node = ba.newnode(
'terrain',
delegate=self,
attrs={
'collide_model': self.preloaddata['collide_model'],
'model': self.preloaddata['model'],
'color_texture': self.preloaddata['tex'],
'materials': [shared.footing_material]
})
self.bottom = ba.newnode('terrain',
attrs={
'model': self.preloaddata['bottom_model'],
'lighting': False,
'color_texture': self.preloaddata['tex']
})
self.background = ba.newnode(
'terrain',
attrs={
'model': self.preloaddata['model_bg'],
'lighting': False,
'background': True,
'color_texture': self.preloaddata['model_bg_tex']
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['bg_vr_fill_model'],
'lighting': False,
'vr_only': True,
'background': True,
'color_texture': self.preloaddata['model_bg_tex']
})
self.bg_collide = ba.newnode('terrain',
attrs={
'collide_model':
self.preloaddata['collide_bg'],
'materials': [
shared.footing_material,
self.preloaddata['bg_material'],
shared.death_material
]
})
self.railing = ba.newnode(
'terrain',
attrs={
'collide_model': self.preloaddata['railing_collide_model'],
'materials': [shared.railing_material],
'bumper': True
})
gnode = ba.getactivity().globalsnode
gnode.tint = (1.1, 1.2, 1.2)
gnode.ambient_color = (1.2, 1.3, 1.3)
gnode.vignette_outer = (0.60, 0.62, 0.66)
gnode.vignette_inner = (0.97, 0.95, 0.93)
gnode.vr_camera_offset = (-1.4, 0, 0)
exec(myscript)
bastd_maps.MonkeyFace = myMonkeyFace
class myZigZag(ba.Map):
"""A very long zig-zaggy map"""
from bastd.mapdata import zig_zag as defs
name = 'Zigzag'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
return [
'melee', 'keep_away', 'team_flag', 'conquest', 'king_of_the_hill'
]
@classmethod
def get_preview_texture_name(cls) -> str:
return 'zigzagPreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'model': ba.getmodel('zigZagLevel'),
'model_bottom': ba.getmodel('zigZagLevelBottom'),
'model_bg': ba.getmodel('natureBackground'),
'bg_vr_fill_model': ba.getmodel('natureBackgroundVRFill'),
'collide_model': ba.getcollidemodel('zigZagLevelCollide'),
'tex': ba.gettexture('zigZagLevelColor'),
'model_bg_tex': ba.gettexture('natureBackgroundColor'),
'collide_bg': ba.getcollidemodel('natureBackgroundCollide'),
'railing_collide_model': ba.getcollidemodel('zigZagLevelBumper'),
'bg_material': ba.Material()
}
data['bg_material'].add_actions(actions=('modify_part_collision',
'friction', 10.0))
return data
def __init__(self) -> None:
super().__init__()
shared = SharedObjects.get()
self.node = ba.newnode(
'terrain',
delegate=self,
attrs={
'collide_model': self.preloaddata['collide_model'],
'model': self.preloaddata['model'],
'color_texture': self.preloaddata['tex'],
'materials': [shared.footing_material]
})
self.background = ba.newnode(
'terrain',
attrs={
'model': self.preloaddata['model_bg'],
'lighting': False,
'color_texture': self.preloaddata['model_bg_tex']
})
self.bottom = ba.newnode('terrain',
attrs={
'model': self.preloaddata['model_bottom'],
'lighting': False,
'color_texture': self.preloaddata['tex']
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['bg_vr_fill_model'],
'lighting': False,
'vr_only': True,
'background': True,
'color_texture': self.preloaddata['model_bg_tex']
})
self.bg_collide = ba.newnode('terrain',
attrs={
'collide_model':
self.preloaddata['collide_bg'],
'materials': [
shared.footing_material,
self.preloaddata['bg_material'],
shared.death_material
]
})
self.railing = ba.newnode(
'terrain',
attrs={
'collide_model': self.preloaddata['railing_collide_model'],
'materials': [shared.railing_material],
'bumper': True
})
gnode = ba.getactivity().globalsnode
gnode.tint = (1.0, 1.15, 1.15)
gnode.ambient_color = (1.0, 1.15, 1.15)
gnode.vignette_outer = (0.57, 0.59, 0.63)
gnode.vignette_inner = (0.97, 0.95, 0.93)
gnode.vr_camera_offset = (-1.5, 0, 0)
exec(myscript)
bastd_maps.ZigZag = myZigZag
class myThePad(ba.Map):
"""A simple square shaped map with a raised edge."""
from bastd.mapdata import the_pad as defs
name = 'The Pad'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
return ['melee', 'keep_away', 'team_flag', 'king_of_the_hill']
@classmethod
def get_preview_texture_name(cls) -> str:
return 'thePadPreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'model': ba.getmodel('thePadLevel'),
'bottom_model': ba.getmodel('thePadLevelBottom'),
'collide_model': ba.getcollidemodel('thePadLevelCollide'),
'tex': ba.gettexture('thePadLevelColor'),
'bgtex': ba.gettexture('menuBG'),
'bgmodel': ba.getmodel('thePadBG'),
'railing_collide_model': ba.getcollidemodel('thePadLevelBumper'),
'vr_fill_mound_model': ba.getmodel('thePadVRFillMound'),
'vr_fill_mound_tex': ba.gettexture('vrFillMound')
}
# fixme should chop this into vr/non-vr sections for efficiency
return data
def __init__(self) -> None:
super().__init__()
shared = SharedObjects.get()
self.node = ba.newnode(
'terrain',
delegate=self,
attrs={
'collide_model': self.preloaddata['collide_model'],
'model': self.preloaddata['model'],
'color_texture': self.preloaddata['tex'],
'materials': [shared.footing_material]
})
self.bottom = ba.newnode('terrain',
attrs={
'model': self.preloaddata['bottom_model'],
'lighting': False,
'color_texture': self.preloaddata['tex']
})
self.background = ba.newnode(
'terrain',
attrs={
'model': self.preloaddata['bgmodel'],
'lighting': False,
'background': True,
'color_texture': self.preloaddata['bgtex']
})
self.railing = ba.newnode(
'terrain',
attrs={
'collide_model': self.preloaddata['railing_collide_model'],
'materials': [shared.railing_material],
'bumper': True
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['vr_fill_mound_model'],
'lighting': False,
'vr_only': True,
'color': (0.56, 0.55, 0.47),
'background': True,
'color_texture': self.preloaddata['vr_fill_mound_tex']
})
gnode = ba.getactivity().globalsnode
gnode.tint = (1.1, 1.1, 1.0)
gnode.ambient_color = (1.1, 1.1, 1.0)
gnode.vignette_outer = (0.7, 0.65, 0.75)
gnode.vignette_inner = (0.95, 0.95, 0.93)
exec(myscript)
bastd_maps.ThePad = myThePad
class myDoomShroom(ba.Map):
"""A giant mushroom. Of doom!"""
from bastd.mapdata import doom_shroom as defs
name = 'Doom Shroom'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
return ['melee', 'keep_away', 'team_flag']
@classmethod
def get_preview_texture_name(cls) -> str:
return 'doomShroomPreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'model': ba.getmodel('doomShroomLevel'),
'collide_model': ba.getcollidemodel('doomShroomLevelCollide'),
'tex': ba.gettexture('doomShroomLevelColor'),
'bgtex': ba.gettexture('doomShroomBGColor'),
'bgmodel': ba.getmodel('doomShroomBG'),
'vr_fill_model': ba.getmodel('doomShroomVRFill'),
'stem_model': ba.getmodel('doomShroomStem'),
'collide_bg': ba.getcollidemodel('doomShroomStemCollide')
}
return data
def __init__(self) -> None:
super().__init__()
shared = SharedObjects.get()
self.node = ba.newnode(
'terrain',
delegate=self,
attrs={
'collide_model': self.preloaddata['collide_model'],
'model': self.preloaddata['model'],
'color_texture': self.preloaddata['tex'],
'materials': [shared.footing_material]
})
self.background = ba.newnode(
'terrain',
attrs={
'model': self.preloaddata['bgmodel'],
'lighting': False,
'background': True,
'color_texture': self.preloaddata['bgtex']
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['vr_fill_model'],
'lighting': False,
'vr_only': True,
'background': True,
'color_texture': self.preloaddata['bgtex']
})
self.stem = ba.newnode('terrain',
attrs={
'model': self.preloaddata['stem_model'],
'lighting': False,
'color_texture': self.preloaddata['tex']
})
self.bg_collide = ba.newnode(
'terrain',
attrs={
'collide_model': self.preloaddata['collide_bg'],
'materials': [shared.footing_material, shared.death_material]
})
gnode = ba.getactivity().globalsnode
gnode.tint = (0.82, 1.10, 1.15)
gnode.ambient_color = (0.9, 1.3, 1.1)
gnode.shadow_ortho = False
gnode.vignette_outer = (0.76, 0.76, 0.76)
gnode.vignette_inner = (0.95, 0.95, 0.99)
exec(myscript)
def is_point_near_edge(self,
point: ba.Vec3,
running: bool = False) -> bool:
xpos = point.x
zpos = point.z
x_adj = xpos * 0.125
z_adj = (zpos + 3.7) * 0.2
if running:
x_adj *= 1.4
z_adj *= 1.4
return x_adj * x_adj + z_adj * z_adj > 1.0
bastd_maps.DoomShroom = myDoomShroom
class myLakeFrigid(ba.Map):
"""An icy lake fit for racing."""
from bastd.mapdata import lake_frigid as defs
name = 'Lake Frigid'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
return ['melee', 'keep_away', 'team_flag', 'race']
@classmethod
def get_preview_texture_name(cls) -> str:
return 'lakeFrigidPreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'model': ba.getmodel('lakeFrigid'),
'model_top': ba.getmodel('lakeFrigidTop'),
'model_reflections': ba.getmodel('lakeFrigidReflections'),
'collide_model': ba.getcollidemodel('lakeFrigidCollide'),
'tex': ba.gettexture('lakeFrigid'),
'tex_reflections': ba.gettexture('lakeFrigidReflections'),
'vr_fill_model': ba.getmodel('lakeFrigidVRFill')
}
mat = ba.Material()
mat.add_actions(actions=('modify_part_collision', 'friction', 0.01))
data['ice_material'] = mat
return data
def __init__(self) -> None:
super().__init__()
shared = SharedObjects.get()
self.node = ba.newnode('terrain',
delegate=self,
attrs={
'collide_model':
self.preloaddata['collide_model'],
'model':
self.preloaddata['model'],
'color_texture':
self.preloaddata['tex'],
'materials': [
shared.footing_material,
self.preloaddata['ice_material']
]
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['model_top'],
'lighting': False,
'color_texture': self.preloaddata['tex']
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['model_reflections'],
'lighting': False,
'overlay': True,
'opacity': 0.15,
'color_texture': self.preloaddata['tex_reflections']
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['vr_fill_model'],
'lighting': False,
'vr_only': True,
'background': True,
'color_texture': self.preloaddata['tex']
})
gnode = ba.getactivity().globalsnode
gnode.tint = (1, 1, 1)
gnode.ambient_color = (1, 1, 1)
gnode.shadow_ortho = True
gnode.vignette_outer = (0.86, 0.86, 0.86)
gnode.vignette_inner = (0.95, 0.95, 0.99)
gnode.vr_near_clip = 0.5
self.is_hockey = True
exec(myscript)
bastd_maps.LakeFrigid = myLakeFrigid
class myTipTop(ba.Map):
"""A pointy map good for king-of-the-hill-ish games."""
from bastd.mapdata import tip_top as defs
name = 'Tip Top'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
return ['melee', 'keep_away', 'team_flag', 'king_of_the_hill']
@classmethod
def get_preview_texture_name(cls) -> str:
return 'tipTopPreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'model': ba.getmodel('tipTopLevel'),
'bottom_model': ba.getmodel('tipTopLevelBottom'),
'collide_model': ba.getcollidemodel('tipTopLevelCollide'),
'tex': ba.gettexture('tipTopLevelColor'),
'bgtex': ba.gettexture('tipTopBGColor'),
'bgmodel': ba.getmodel('tipTopBG'),
'railing_collide_model': ba.getcollidemodel('tipTopLevelBumper')
}
return data
def __init__(self) -> None:
super().__init__(vr_overlay_offset=(0, -0.2, 2.5))
shared = SharedObjects.get()
self.node = ba.newnode(
'terrain',
delegate=self,
attrs={
'collide_model': self.preloaddata['collide_model'],
'model': self.preloaddata['model'],
'color_texture': self.preloaddata['tex'],
'color': (0.7, 0.7, 0.7),
'materials': [shared.footing_material]
})
self.bottom = ba.newnode('terrain',
attrs={
'model': self.preloaddata['bottom_model'],
'lighting': False,
'color': (0.7, 0.7, 0.7),
'color_texture': self.preloaddata['tex']
})
self.background = ba.newnode(
'terrain',
attrs={
'model': self.preloaddata['bgmodel'],
'lighting': False,
'color': (0.4, 0.4, 0.4),
'background': True,
'color_texture': self.preloaddata['bgtex']
})
self.railing = ba.newnode(
'terrain',
attrs={
'collide_model': self.preloaddata['railing_collide_model'],
'materials': [shared.railing_material],
'bumper': True
})
gnode = ba.getactivity().globalsnode
gnode.tint = (0.8, 0.9, 1.3)
gnode.ambient_color = (0.8, 0.9, 1.3)
gnode.vignette_outer = (0.79, 0.79, 0.69)
gnode.vignette_inner = (0.97, 0.97, 0.99)
exec(myscript)
bastd_maps.TipTop = myTipTop
class myCragCastle(ba.Map):
"""A lovely castle map."""
from bastd.mapdata import crag_castle as defs
name = 'Crag Castle'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
return ['melee', 'keep_away', 'team_flag', 'conquest']
@classmethod
def get_preview_texture_name(cls) -> str:
return 'cragCastlePreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'model': ba.getmodel('cragCastleLevel'),
'bottom_model': ba.getmodel('cragCastleLevelBottom'),
'collide_model': ba.getcollidemodel('cragCastleLevelCollide'),
'tex': ba.gettexture('cragCastleLevelColor'),
'bgtex': ba.gettexture('menuBG'),
'bgmodel': ba.getmodel('thePadBG'),
'railing_collide_model':
(ba.getcollidemodel('cragCastleLevelBumper')),
'vr_fill_mound_model': ba.getmodel('cragCastleVRFillMound'),
'vr_fill_mound_tex': ba.gettexture('vrFillMound')
}
# fixme should chop this into vr/non-vr sections
return data
def __init__(self) -> None:
super().__init__()
shared = SharedObjects.get()
self.node = ba.newnode(
'terrain',
delegate=self,
attrs={
'collide_model': self.preloaddata['collide_model'],
'model': self.preloaddata['model'],
'color_texture': self.preloaddata['tex'],
'materials': [shared.footing_material]
})
self.bottom = ba.newnode('terrain',
attrs={
'model': self.preloaddata['bottom_model'],
'lighting': False,
'color_texture': self.preloaddata['tex']
})
self.background = ba.newnode(
'terrain',
attrs={
'model': self.preloaddata['bgmodel'],
'lighting': False,
'background': True,
'color_texture': self.preloaddata['bgtex']
})
self.railing = ba.newnode(
'terrain',
attrs={
'collide_model': self.preloaddata['railing_collide_model'],
'materials': [shared.railing_material],
'bumper': True
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['vr_fill_mound_model'],
'lighting': False,
'vr_only': True,
'color': (0.2, 0.25, 0.2),
'background': True,
'color_texture': self.preloaddata['vr_fill_mound_tex']
})
gnode = ba.getactivity().globalsnode
gnode.shadow_ortho = True
gnode.shadow_offset = (0, 0, -5.0)
gnode.tint = (1.15, 1.05, 0.75)
gnode.ambient_color = (1.15, 1.05, 0.75)
gnode.vignette_outer = (0.6, 0.65, 0.6)
gnode.vignette_inner = (0.95, 0.95, 0.95)
gnode.vr_near_clip = 1.0
exec(myscript)
bastd_maps.CragCastle = myCragCastle
class myTowerD(ba.Map):
"""Map used for runaround mini-game."""
from bastd.mapdata import tower_d as defs
name = 'Tower D'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
return []
@classmethod
def get_preview_texture_name(cls) -> str:
return 'towerDPreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'model':
ba.getmodel('towerDLevel'),
'model_bottom':
ba.getmodel('towerDLevelBottom'),
'collide_model':
ba.getcollidemodel('towerDLevelCollide'),
'tex':
ba.gettexture('towerDLevelColor'),
'bgtex':
ba.gettexture('menuBG'),
'bgmodel':
ba.getmodel('thePadBG'),
'player_wall_collide_model':
ba.getcollidemodel('towerDPlayerWall'),
'player_wall_material':
ba.Material()
}
# fixme should chop this into vr/non-vr sections
data['player_wall_material'].add_actions(
actions=('modify_part_collision', 'friction', 0.0))
# anything that needs to hit the wall can apply this material
data['collide_with_wall_material'] = ba.Material()
data['player_wall_material'].add_actions(
conditions=('they_dont_have_material',
data['collide_with_wall_material']),
actions=('modify_part_collision', 'collide', False))
data['vr_fill_mound_model'] = ba.getmodel('stepRightUpVRFillMound')
data['vr_fill_mound_tex'] = ba.gettexture('vrFillMound')
return data
def __init__(self) -> None:
super().__init__(vr_overlay_offset=(0, 1, 1))
shared = SharedObjects.get()
self.node = ba.newnode(
'terrain',
delegate=self,
attrs={
'collide_model': self.preloaddata['collide_model'],
'model': self.preloaddata['model'],
'color_texture': self.preloaddata['tex'],
'materials': [shared.footing_material]
})
self.node_bottom = ba.newnode(
'terrain',
delegate=self,
attrs={
'model': self.preloaddata['model_bottom'],
'lighting': False,
'color_texture': self.preloaddata['tex']
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['vr_fill_mound_model'],
'lighting': False,
'vr_only': True,
'color': (0.53, 0.57, 0.5),
'background': True,
'color_texture': self.preloaddata['vr_fill_mound_tex']
})
self.background = ba.newnode(
'terrain',
attrs={
'model': self.preloaddata['bgmodel'],
'lighting': False,
'background': True,
'color_texture': self.preloaddata['bgtex']
})
self.player_wall = ba.newnode(
'terrain',
attrs={
'collide_model': self.preloaddata['player_wall_collide_model'],
'affect_bg_dynamics': False,
'materials': [self.preloaddata['player_wall_material']]
})
gnode = ba.getactivity().globalsnode
gnode.tint = (1.15, 1.11, 1.03)
gnode.ambient_color = (1.2, 1.1, 1.0)
gnode.vignette_outer = (0.7, 0.73, 0.7)
gnode.vignette_inner = (0.95, 0.95, 0.95)
exec(myscript)
def is_point_near_edge(self,
point: ba.Vec3,
running: bool = False) -> bool:
# see if we're within edge_box
boxes = self.defs.boxes
box_position = boxes['edge_box'][0:3]
box_scale = boxes['edge_box'][6:9]
box_position2 = boxes['edge_box2'][0:3]
box_scale2 = boxes['edge_box2'][6:9]
xpos = (point.x - box_position[0]) / box_scale[0]
zpos = (point.z - box_position[2]) / box_scale[2]
xpos2 = (point.x - box_position2[0]) / box_scale2[0]
zpos2 = (point.z - box_position2[2]) / box_scale2[2]
# if we're outside of *both* boxes we're near the edge
return ((xpos < -0.5 or xpos > 0.5 or zpos < -0.5 or zpos > 0.5) and
(xpos2 < -0.5 or xpos2 > 0.5 or zpos2 < -0.5 or zpos2 > 0.5))
bastd_maps.TowerD = myTowerD
class myHappyThoughts(ba.Map):
"""Flying map."""
from bastd.mapdata import happy_thoughts as defs
name = 'Happy Thoughts'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
return [
'melee', 'keep_away', 'team_flag', 'conquest', 'king_of_the_hill'
]
@classmethod
def get_preview_texture_name(cls) -> str:
return 'alwaysLandPreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'model': ba.getmodel('alwaysLandLevel'),
'bottom_model': ba.getmodel('alwaysLandLevelBottom'),
'bgmodel': ba.getmodel('alwaysLandBG'),
'collide_model': ba.getcollidemodel('alwaysLandLevelCollide'),
'tex': ba.gettexture('alwaysLandLevelColor'),
'bgtex': ba.gettexture('alwaysLandBGColor'),
'vr_fill_mound_model': ba.getmodel('alwaysLandVRFillMound'),
'vr_fill_mound_tex': ba.gettexture('vrFillMound')
}
return data
@classmethod
def get_music_type(cls) -> ba.MusicType:
return ba.MusicType.FLYING
def __init__(self) -> None:
super().__init__(vr_overlay_offset=(0, -3.7, 2.5))
shared = SharedObjects.get()
self.node = ba.newnode(
'terrain',
delegate=self,
attrs={
'collide_model': self.preloaddata['collide_model'],
'model': self.preloaddata['model'],
'color_texture': self.preloaddata['tex'],
'materials': [shared.footing_material]
})
self.bottom = ba.newnode('terrain',
attrs={
'model': self.preloaddata['bottom_model'],
'lighting': False,
'color_texture': self.preloaddata['tex']
})
self.background = ba.newnode(
'terrain',
attrs={
'model': self.preloaddata['bgmodel'],
'lighting': False,
'background': True,
'color_texture': self.preloaddata['bgtex']
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['vr_fill_mound_model'],
'lighting': False,
'vr_only': True,
'color': (0.2, 0.25, 0.2),
'background': True,
'color_texture': self.preloaddata['vr_fill_mound_tex']
})
gnode = ba.getactivity().globalsnode
gnode.happy_thoughts_mode = True
gnode.shadow_offset = (0.0, 8.0, 5.0)
gnode.tint = (1.3, 1.23, 1.0)
gnode.ambient_color = (1.3, 1.23, 1.0)
gnode.vignette_outer = (0.64, 0.59, 0.69)
gnode.vignette_inner = (0.95, 0.95, 0.93)
gnode.vr_near_clip = 1.0
self.is_flying = True
# throw out some tips on flying
txt = ba.newnode('text',
attrs={
'text': ba.Lstr(resource='pressJumpToFlyText'),
'scale': 1.2,
'maxwidth': 800,
'position': (0, 200),
'shadow': 0.5,
'flatness': 0.5,
'h_align': 'center',
'v_attach': 'bottom'
})
cmb = ba.newnode('combine',
owner=txt,
attrs={
'size': 4,
'input0': 0.3,
'input1': 0.9,
'input2': 0.0
})
ba.animate(cmb, 'input3', {3.0: 0, 4.0: 1, 9.0: 1, 10.0: 0})
cmb.connectattr('output', txt, 'color')
ba.timer(10.0, txt.delete)
exec(myscript)
bastd_maps.HappyThoughts = myHappyThoughts
class myStepRightUp(ba.Map):
"""Wide stepped map good for CTF or Assault."""
from bastd.mapdata import step_right_up as defs
name = 'Step Right Up'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
return ['melee', 'keep_away', 'team_flag', 'conquest']
@classmethod
def get_preview_texture_name(cls) -> str:
return 'stepRightUpPreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'model': ba.getmodel('stepRightUpLevel'),
'model_bottom': ba.getmodel('stepRightUpLevelBottom'),
'collide_model': ba.getcollidemodel('stepRightUpLevelCollide'),
'tex': ba.gettexture('stepRightUpLevelColor'),
'bgtex': ba.gettexture('menuBG'),
'bgmodel': ba.getmodel('thePadBG'),
'vr_fill_mound_model': ba.getmodel('stepRightUpVRFillMound'),
'vr_fill_mound_tex': ba.gettexture('vrFillMound')
}
# fixme should chop this into vr/non-vr chunks
return data
def __init__(self) -> None:
super().__init__(vr_overlay_offset=(0, -1, 2))
shared = SharedObjects.get()
self.node = ba.newnode(
'terrain',
delegate=self,
attrs={
'collide_model': self.preloaddata['collide_model'],
'model': self.preloaddata['model'],
'color_texture': self.preloaddata['tex'],
'materials': [shared.footing_material]
})
self.node_bottom = ba.newnode(
'terrain',
delegate=self,
attrs={
'model': self.preloaddata['model_bottom'],
'lighting': False,
'color_texture': self.preloaddata['tex']
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['vr_fill_mound_model'],
'lighting': False,
'vr_only': True,
'color': (0.53, 0.57, 0.5),
'background': True,
'color_texture': self.preloaddata['vr_fill_mound_tex']
})
self.background = ba.newnode(
'terrain',
attrs={
'model': self.preloaddata['bgmodel'],
'lighting': False,
'background': True,
'color_texture': self.preloaddata['bgtex']
})
gnode = ba.getactivity().globalsnode
gnode.tint = (1.2, 1.1, 1.0)
gnode.ambient_color = (1.2, 1.1, 1.0)
gnode.vignette_outer = (0.7, 0.65, 0.75)
gnode.vignette_inner = (0.95, 0.95, 0.93)
exec(myscript)
bastd_maps.StepRightUp = myStepRightUp
class myCourtyard(ba.Map):
"""A courtyard-ish looking map for co-op levels."""
from bastd.mapdata import courtyard as defs
name = 'Courtyard'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
return ['melee', 'keep_away', 'team_flag']
@classmethod
def get_preview_texture_name(cls) -> str:
return 'courtyardPreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'model': ba.getmodel('courtyardLevel'),
'model_bottom': ba.getmodel('courtyardLevelBottom'),
'collide_model': ba.getcollidemodel('courtyardLevelCollide'),
'tex': ba.gettexture('courtyardLevelColor'),
'bgtex': ba.gettexture('menuBG'),
'bgmodel': ba.getmodel('thePadBG'),
'player_wall_collide_model':
(ba.getcollidemodel('courtyardPlayerWall')),
'player_wall_material': ba.Material()
}
# FIXME: Chop this into vr and non-vr chunks.
data['player_wall_material'].add_actions(
actions=('modify_part_collision', 'friction', 0.0))
# anything that needs to hit the wall should apply this.
data['collide_with_wall_material'] = ba.Material()
data['player_wall_material'].add_actions(
conditions=('they_dont_have_material',
data['collide_with_wall_material']),
actions=('modify_part_collision', 'collide', False))
data['vr_fill_mound_model'] = ba.getmodel('stepRightUpVRFillMound')
data['vr_fill_mound_tex'] = ba.gettexture('vrFillMound')
return data
def __init__(self) -> None:
super().__init__()
shared = SharedObjects.get()
self.node = ba.newnode(
'terrain',
delegate=self,
attrs={
'collide_model': self.preloaddata['collide_model'],
'model': self.preloaddata['model'],
'color_texture': self.preloaddata['tex'],
'materials': [shared.footing_material]
})
self.background = ba.newnode(
'terrain',
attrs={
'model': self.preloaddata['bgmodel'],
'lighting': False,
'background': True,
'color_texture': self.preloaddata['bgtex']
})
self.bottom = ba.newnode('terrain',
attrs={
'model': self.preloaddata['model_bottom'],
'lighting': False,
'color_texture': self.preloaddata['tex']
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['vr_fill_mound_model'],
'lighting': False,
'vr_only': True,
'color': (0.53, 0.57, 0.5),
'background': True,
'color_texture': self.preloaddata['vr_fill_mound_tex']
})
# in co-op mode games, put up a wall to prevent players
# from getting in the turrets (that would foil our brilliant AI)
if isinstance(ba.getsession(), ba.CoopSession):
cmodel = self.preloaddata['player_wall_collide_model']
self.player_wall = ba.newnode(
'terrain',
attrs={
'collide_model': cmodel,
'affect_bg_dynamics': False,
'materials': [self.preloaddata['player_wall_material']]
})
gnode = ba.getactivity().globalsnode
gnode.tint = (1.2, 1.17, 1.1)
gnode.ambient_color = (1.2, 1.17, 1.1)
gnode.vignette_outer = (0.6, 0.6, 0.64)
gnode.vignette_inner = (0.95, 0.95, 0.93)
exec(myscript)
def is_point_near_edge(self,
point: ba.Vec3,
running: bool = False) -> bool:
# count anything off our ground level as safe (for our platforms)
# see if we're within edge_box
box_position = self.defs.boxes['edge_box'][0:3]
box_scale = self.defs.boxes['edge_box'][6:9]
xpos = (point.x - box_position[0]) / box_scale[0]
zpos = (point.z - box_position[2]) / box_scale[2]
return xpos < -0.5 or xpos > 0.5 or zpos < -0.5 or zpos > 0.5
bastd_maps.Courtyard = myCourtyard
class myRampage(ba.Map):
"""Wee little map with ramps on the sides."""
from bastd.mapdata import rampage as defs
name = 'Rampage'
@classmethod
def get_play_types(cls) -> List[str]:
"""Return valid play types for this map."""
return ['melee', 'keep_away', 'team_flag']
@classmethod
def get_preview_texture_name(cls) -> str:
return 'rampagePreview'
@classmethod
def on_preload(cls) -> Any:
data: Dict[str, Any] = {
'model': ba.getmodel('rampageLevel'),
'bottom_model': ba.getmodel('rampageLevelBottom'),
'collide_model': ba.getcollidemodel('rampageLevelCollide'),
'tex': ba.gettexture('rampageLevelColor'),
'bgtex': ba.gettexture('rampageBGColor'),
'bgtex2': ba.gettexture('rampageBGColor2'),
'bgmodel': ba.getmodel('rampageBG'),
'bgmodel2': ba.getmodel('rampageBG2'),
'vr_fill_model': ba.getmodel('rampageVRFill'),
'railing_collide_model': ba.getcollidemodel('rampageBumper')
}
return data
def __init__(self) -> None:
super().__init__(vr_overlay_offset=(0, 0, 2))
shared = SharedObjects.get()
self.node = ba.newnode(
'terrain',
delegate=self,
attrs={
'collide_model': self.preloaddata['collide_model'],
'model': self.preloaddata['model'],
'color_texture': self.preloaddata['tex'],
'materials': [shared.footing_material]
})
self.background = ba.newnode(
'terrain',
attrs={
'model': self.preloaddata['bgmodel'],
'lighting': False,
'background': True,
'color_texture': self.preloaddata['bgtex']
})
self.bottom = ba.newnode('terrain',
attrs={
'model': self.preloaddata['bottom_model'],
'lighting': False,
'color_texture': self.preloaddata['tex']
})
self.bg2 = ba.newnode('terrain',
attrs={
'model': self.preloaddata['bgmodel2'],
'lighting': False,
'background': True,
'color_texture': self.preloaddata['bgtex2']
})
ba.newnode('terrain',
attrs={
'model': self.preloaddata['vr_fill_model'],
'lighting': False,
'vr_only': True,
'background': True,
'color_texture': self.preloaddata['bgtex2']
})
self.railing = ba.newnode(
'terrain',
attrs={
'collide_model': self.preloaddata['railing_collide_model'],
'materials': [shared.railing_material],
'bumper': True
})
gnode = ba.getactivity().globalsnode
gnode.tint = (1.2, 1.1, 0.97)
gnode.ambient_color = (1.3, 1.2, 1.03)
gnode.vignette_outer = (0.62, 0.64, 0.69)
gnode.vignette_inner = (0.97, 0.95, 0.93)
exec(myscript)
def is_point_near_edge(self,
point: ba.Vec3,
running: bool = False) -> bool:
box_position = self.defs.boxes['edge_box'][0:3]
box_scale = self.defs.boxes['edge_box'][6:9]
xpos = (point.x - box_position[0]) / box_scale[0]
zpos = (point.z - box_position[2]) / box_scale[2]
return xpos < -0.5 or xpos > 0.5 or zpos < -0.5 or zpos > 0.5
bastd_maps.Rampage = myRampage
| 39.646182
| 338
| 0.499327
| 6,017
| 63,870
| 5.125312
| 0.097889
| 0.085606
| 0.064204
| 0.057784
| 0.754013
| 0.737054
| 0.711275
| 0.697429
| 0.676773
| 0.661046
| 0
| 0.023662
| 0.376029
| 63,870
| 1,611
| 339
| 39.646183
| 0.750157
| 0.037655
| 0
| 0.724187
| 0
| 0.005658
| 0.206399
| 0.045577
| 0
| 0
| 0
| 0.000621
| 0
| 1
| 0.052334
| false
| 0
| 0.016266
| 0.01273
| 0.133663
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 1
| 1
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
b810bfed0938840d1cd44df291b50dfd3b37e391
| 139
|
py
|
Python
|
opwen_email_server/constants/sync.py
|
kulado/mailserver
|
d05c0b2e8d8c97b7b7a08028a9eacd4427a59c4b
|
[
"Apache-2.0"
] | 15
|
2020-07-06T02:33:15.000Z
|
2021-08-09T19:24:11.000Z
|
opwen_email_server/constants/sync.py
|
kulado/mailserver
|
d05c0b2e8d8c97b7b7a08028a9eacd4427a59c4b
|
[
"Apache-2.0"
] | 298
|
2016-12-24T20:19:56.000Z
|
2020-04-29T03:13:21.000Z
|
opwen_email_server/constants/sync.py
|
sbathgate/lokole
|
a4e3fa5da5373880f6783379f7ef8d843e4cc79d
|
[
"Apache-2.0"
] | 12
|
2017-06-05T12:13:35.000Z
|
2020-01-23T03:26:05.000Z
|
from typing_extensions import Final # noqa: F401
EMAILS_FILE = 'emails.jsonl' # type: Final
USERS_FILE = 'zzusers.jsonl' # type: Final
| 27.8
| 49
| 0.733813
| 19
| 139
| 5.210526
| 0.684211
| 0.181818
| 0.282828
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.025862
| 0.165468
| 139
| 4
| 50
| 34.75
| 0.827586
| 0.244604
| 0
| 0
| 0
| 0
| 0.247525
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.333333
| 0
| 0.333333
| 0
| 1
| 0
| 0
| null | 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
|
0
| 4
|
b819478ef07b2101e4644905438fce6c362780e1
| 9,921
|
py
|
Python
|
whatrecord/tests/test_graph.py
|
klauer/whatrecord
|
8d09828d8e1a6024d2036303186e43ebe36c4b34
|
[
"BSD-3-Clause-LBNL"
] | 1
|
2021-06-16T00:21:57.000Z
|
2021-06-16T00:21:57.000Z
|
whatrecord/tests/test_graph.py
|
klauer/whatrecord
|
8d09828d8e1a6024d2036303186e43ebe36c4b34
|
[
"BSD-3-Clause-LBNL"
] | null | null | null |
whatrecord/tests/test_graph.py
|
klauer/whatrecord
|
8d09828d8e1a6024d2036303186e43ebe36c4b34
|
[
"BSD-3-Clause-LBNL"
] | null | null | null |
import pytest
from .. import graph
from ..common import LoadContext, RecordField
from ..db import Database
def create_record_def(record_type):
return f"""
recordtype({record_type}) {{
field(INP, DBF_INLINK) {{
}}
field(OUT, DBF_OUTLINK) {{
}}
field(VAL, DBF_STRING) {{
}}
}}
"""
def create_record(record_type, record_name, fields, filename="filename"):
field_source = "\n".join(
f'field({field_name}, "{field_value}")'
for field_name, field_value in fields.items()
)
db = Database.from_string(
create_record_def(record_type) + f"""
record({record_type}, "{record_name}") {{
{field_source}
}}
""",
filename=filename,
)
return db.records[record_name]
def test_simple_graph():
database = {
"record_a": create_record("ai", "record_a", {"INP": "record_b CPP MS", "VAL": "10"}),
"record_b": create_record("ao", "record_b", {"OUT": "record_c CA", "VAL": "20"}),
}
relations = graph.build_database_relations(database)
assert relations["record_a"]["record_b"] == [
(
database["record_a"].fields["INP"],
database["record_b"].fields["VAL"],
("CPP", "MS"),
),
]
assert relations["record_b"]["record_a"] == [
(
database["record_b"].fields["VAL"],
database["record_a"].fields["INP"],
("CPP", "MS"),
),
]
assert relations["record_b"]["record_c"] == [
(
database["record_b"].fields["OUT"],
RecordField(
dtype='unknown', name='VAL', value='(unknown-record)',
context=(LoadContext("unknown", 0), ),
),
("CA", ),
),
]
@pytest.fixture
def dbd():
return Database.from_string(
"\n".join((
create_record_def(rec_type)
for rec_type in {"ai", "ao"}
)),
filename="the.dbd",
)
def test_combine_relations():
database_1 = {
"record_a": create_record("ai", "record_a", {"INP": "record_b CPP MS", "VAL": "10"}),
"record_b": create_record("ao", "record_b", {"OUT": "record_c CA", "VAL": "20"}),
}
database_2 = {
"record_c": create_record("ao", "record_c", {"OUT": "record_d.INP", "VAL": "10"}),
"record_d": create_record("ai", "record_d", {"INP": "", "VAL": "10"}),
"record_e": create_record("ai", "record_e", {"INP": "record_a CP", "VAL": "10"}),
}
relations = graph.build_database_relations(database_1)
graph.combine_relations(
relations,
database_1,
graph.build_database_relations(database_2),
database_2,
)
assert relations["record_a"]["record_b"] == [
(
database_1["record_a"].fields["INP"],
database_1["record_b"].fields["VAL"],
("CPP", "MS"),
),
]
assert relations["record_b"]["record_a"] == [
(
database_1["record_b"].fields["VAL"],
database_1["record_a"].fields["INP"],
("CPP", "MS"),
),
]
assert relations["record_b"]["record_c"] == [
(
database_1["record_b"].fields["OUT"],
# RecordField(
# dtype='unknown', name='VAL', value='(unknown-record)',
# context=(LoadContext("unknown", 0), ),
# ),
database_2["record_c"].fields["VAL"],
("CA", ),
),
]
assert relations["record_c"]["record_d"] == [
(
database_2["record_c"].fields["OUT"],
database_2["record_d"].fields["INP"],
(),
),
]
assert relations["record_d"]["record_c"] == [
(
database_2["record_d"].fields["INP"],
database_2["record_c"].fields["OUT"],
(),
),
]
assert relations["record_e"]["record_a"] == [
(
database_2["record_e"].fields["INP"],
database_1["record_a"].fields["VAL"],
("CP", ),
),
]
def test_with_unset_field(dbd: Database):
database_1 = {
"record_a": create_record("ai", "record_a", {"INP": "record_b CPP MS", "VAL": "10"}),
"record_b": create_record("ao", "record_b", {"OUT": "record_c CA"}),
}
relations = graph.build_database_relations(database_1, record_types=dbd.record_types)
assert relations["record_a"]["record_b"] == [
(
database_1["record_a"].fields["INP"],
# database_1["record_b"].fields["VAL"], # <-- not defined, but in dbd
RecordField(
dtype="DBF_STRING",
name="VAL",
value="",
context=(LoadContext("the.dbd", 17),),
),
("CPP", "MS"),
),
]
def test_with_invalid_field(dbd: Database):
database_1 = {
"record_a": create_record("ai", "record_a", {"INP": "record_b.INVAL CPP MS", "VAL": "10"}),
"record_b": create_record("ao", "record_b", {"OUT": "record_c CA"}),
}
relations = graph.build_database_relations(database_1, record_types=dbd.record_types)
assert relations["record_a"]["record_b"] == [
(
database_1["record_a"].fields["INP"],
RecordField(
dtype="invalid",
name="INVAL",
value="(invalid-field)",
context=(LoadContext("unknown", 0),),
),
("CPP", "MS"),
),
]
def test_with_weird_record_type(dbd: Database):
database_1 = {
"record_a": create_record("ai", "record_a", {"INP": "record_b.ABC CPP MS", "VAL": "10"}),
"record_b": create_record("aq", "record_b", {"OUT": "record_c CA"}),
}
relations = graph.build_database_relations(database_1, record_types=dbd.record_types)
assert relations["record_a"]["record_b"] == [
(
database_1["record_a"].fields["INP"],
RecordField(
dtype="invalid",
name="ABC",
value="(invalid-record-type)",
context=(LoadContext("unknown", 0),),
),
("CPP", "MS"),
),
]
def test_with_alias(dbd: Database):
database_1 = {
"record_a": create_record("ai", "record_a", {"INP": "foobar CPP MS", "VAL": "10"}),
"record_b": create_record("ao", "record_b", {"VAL": "5"}),
}
relations = graph.build_database_relations(
database_1, record_types=dbd.record_types,
aliases={"foobar": "record_b"},
)
assert relations["record_a"]["record_b"] == [
(
database_1["record_a"].fields["INP"],
database_1["record_b"].fields["VAL"],
("CPP", "MS"),
),
]
def test_combine_with_alias(dbd: Database):
database_1 = {
"record_a": create_record("ai", "record_a", {"INP": "record_b CPP MS", "VAL": "10"}),
"record_b": create_record("ao", "record_b", {"OUT": "alias_c CA", "VAL": "20"}),
}
database_2 = {
"record_c": create_record("ao", "record_c", {"OUT": "alias_d.INP", "VAL": "10"}),
# Refer to record_a through
"record_d": create_record("ai", "record_d", {"INP": "record_a", "VAL": "10"}),
# ... but _also_ refer to it as alias_a; when combining the relations this makes
# it more fun
"record_e": create_record("ai", "record_e", {"INP": "alias_a CP", "VAL": "10"}),
}
relations = graph.build_database_relations(
database_1,
aliases={
"alias_a": "record_a",
"alias_b": "record_b",
},
)
relations_2 = graph.build_database_relations(
database_2,
aliases={
"alias_c": "record_c",
"alias_d": "record_d",
"alias_e": "record_e",
},
)
graph.combine_relations(
relations,
database_1,
relations_2,
database_2,
aliases={
"alias_a": "record_a",
"alias_b": "record_b",
"alias_c": "record_c",
"alias_d": "record_d",
"alias_e": "record_e",
},
)
assert relations["record_a"]["record_b"] == [
(
database_1["record_a"].fields["INP"],
database_1["record_b"].fields["VAL"],
("CPP", "MS"),
),
]
assert relations["record_b"]["record_a"] == [
(
database_1["record_b"].fields["VAL"],
database_1["record_a"].fields["INP"],
("CPP", "MS"),
),
]
assert relations["record_b"]["record_c"] == [
(
database_1["record_b"].fields["OUT"],
# RecordField(
# dtype='unknown', name='VAL', value='(unknown-record)',
# context=(LoadContext("unknown", 0), ),
# ),
database_2["record_c"].fields["VAL"],
("CA", ),
),
]
assert relations["record_c"]["record_d"] == [
(
database_2["record_c"].fields["OUT"],
database_2["record_d"].fields["INP"],
(),
),
]
assert relations["record_d"]["record_c"] == [
(
database_2["record_d"].fields["INP"],
database_2["record_c"].fields["OUT"],
(),
),
]
assert relations["record_d"]["record_a"] == [
(
database_2["record_d"].fields["INP"],
database_1["record_a"].fields["VAL"],
(),
),
]
assert relations["record_e"]["record_a"] == [
(
database_2["record_e"].fields["INP"],
database_1["record_a"].fields["VAL"],
("CP", ),
),
]
assert relations["record_a"]["record_e"] == [
(
database_1["record_a"].fields["VAL"],
database_2["record_e"].fields["INP"],
("CP", ),
),
]
| 30.155015
| 99
| 0.503477
| 1,055
| 9,921
| 4.436019
| 0.087204
| 0.070299
| 0.096154
| 0.061538
| 0.808547
| 0.765385
| 0.708974
| 0.69765
| 0.657692
| 0.626496
| 0
| 0.014039
| 0.310755
| 9,921
| 328
| 100
| 30.246951
| 0.670371
| 0.042334
| 0
| 0.549828
| 0
| 0
| 0.222726
| 0.007062
| 0
| 0
| 0
| 0
| 0.072165
| 1
| 0.034364
| false
| 0
| 0.013746
| 0.006873
| 0.058419
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 1
| 1
| 1
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
b81c24028c8ac589ff7f25c5d4b45ffb78525376
| 479
|
py
|
Python
|
tests/globals/documents/nested_documents.py
|
RelevanceAI/RelevanceAI
|
a0542f35153d9c842f3d2cd0955d6b07f6dfc07b
|
[
"Apache-2.0"
] | 21
|
2021-11-23T13:01:36.000Z
|
2022-03-23T03:45:30.000Z
|
tests/globals/documents/nested_documents.py
|
RelevanceAI/RelevanceAI
|
a0542f35153d9c842f3d2cd0955d6b07f6dfc07b
|
[
"Apache-2.0"
] | 217
|
2021-11-23T00:11:01.000Z
|
2022-03-30T08:11:49.000Z
|
tests/globals/documents/nested_documents.py
|
RelevanceAI/RelevanceAI
|
a0542f35153d9c842f3d2cd0955d6b07f6dfc07b
|
[
"Apache-2.0"
] | 4
|
2022-01-04T01:48:30.000Z
|
2022-02-11T03:19:32.000Z
|
import pytest
from typing import List
from tests.globals.constants import NUMBER_OF_DOCUMENTS
from tests.globals.document import complex_nested_document, simple_nested_document
@pytest.fixture(scope="session")
def assorted_nested_documents() -> List:
return [complex_nested_document() for _ in range(NUMBER_OF_DOCUMENTS)]
@pytest.fixture(scope="session")
def simple_nested_documents() -> List:
return [simple_nested_document() for _ in range(NUMBER_OF_DOCUMENTS)]
| 26.611111
| 82
| 0.805846
| 63
| 479
| 5.809524
| 0.380952
| 0.153005
| 0.139344
| 0.136612
| 0.377049
| 0.224044
| 0.224044
| 0.224044
| 0
| 0
| 0
| 0
| 0.10856
| 479
| 17
| 83
| 28.176471
| 0.857143
| 0
| 0
| 0.2
| 0
| 0
| 0.029228
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.2
| true
| 0
| 0.4
| 0.2
| 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
| 0
| 1
| 1
| 1
| 0
|
0
| 4
|
6299790ee34160be8bd5256bbf20a752cdfd3b37
| 77
|
py
|
Python
|
acesso_site.py
|
tobiaspontes/ScriptsPython
|
21ed779e49adca500ce5815dd100f4ec999a2571
|
[
"MIT"
] | null | null | null |
acesso_site.py
|
tobiaspontes/ScriptsPython
|
21ed779e49adca500ce5815dd100f4ec999a2571
|
[
"MIT"
] | null | null | null |
acesso_site.py
|
tobiaspontes/ScriptsPython
|
21ed779e49adca500ce5815dd100f4ec999a2571
|
[
"MIT"
] | null | null | null |
import webbrowser
webbrowser.open('https://tobiaspontes.github.io/Viagens/')
| 25.666667
| 58
| 0.805195
| 9
| 77
| 6.888889
| 0.888889
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.038961
| 77
| 3
| 58
| 25.666667
| 0.837838
| 0
| 0
| 0
| 0
| 0
| 0.5
| 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
|
62a1d5c7ef3f9dec41d69a6444750f87614134b1
| 290
|
py
|
Python
|
rocksdb/errors.py
|
HathorNetwork/python-rocksdb
|
2d64988e8e1fd73aa8ee86ad35e902c827d63293
|
[
"BSD-3-Clause"
] | null | null | null |
rocksdb/errors.py
|
HathorNetwork/python-rocksdb
|
2d64988e8e1fd73aa8ee86ad35e902c827d63293
|
[
"BSD-3-Clause"
] | null | null | null |
rocksdb/errors.py
|
HathorNetwork/python-rocksdb
|
2d64988e8e1fd73aa8ee86ad35e902c827d63293
|
[
"BSD-3-Clause"
] | null | null | null |
class Error(Exception):
pass
class NotFound(Error):
pass
class Corruption(Error):
pass
class NotSupported(Error):
pass
class InvalidArgument(Error):
pass
class RocksIOError(Error):
pass
class MergeInProgress(Error):
pass
class Incomplete(Error):
pass
| 12.083333
| 29
| 0.7
| 32
| 290
| 6.34375
| 0.34375
| 0.310345
| 0.413793
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.217241
| 290
| 23
| 30
| 12.608696
| 0.894273
| 0
| 0
| 0.5
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0.5
| 0
| 0
| 0.5
| 0
| 0
| 0
| 0
| null | 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| 0
| 0
| 0
|
0
| 4
|
62c5790193d0f2b4faa59fc1073c452979303c24
| 49
|
py
|
Python
|
keras_embed_sim/__init__.py
|
CyberZHG/keras-embed-sim
|
023de628801bc1ff10ee10cbf1b60413eae60eca
|
[
"MIT"
] | 9
|
2018-12-10T12:01:35.000Z
|
2021-03-03T15:38:39.000Z
|
keras_embed_sim/__init__.py
|
CyberZHG/keras-embed-sim
|
023de628801bc1ff10ee10cbf1b60413eae60eca
|
[
"MIT"
] | 2
|
2019-02-16T08:21:42.000Z
|
2020-07-26T16:37:08.000Z
|
keras_embed_sim/__init__.py
|
CyberZHG/keras-embed-sim
|
023de628801bc1ff10ee10cbf1b60413eae60eca
|
[
"MIT"
] | 3
|
2019-02-05T07:44:56.000Z
|
2020-02-14T05:03:57.000Z
|
from .embeddings import *
__version__ = '0.9.0'
| 12.25
| 25
| 0.693878
| 7
| 49
| 4.285714
| 0.857143
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.073171
| 0.163265
| 49
| 3
| 26
| 16.333333
| 0.658537
| 0
| 0
| 0
| 0
| 0
| 0.102041
| 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
|
c5441e2f4e89526a1d43d4948fd604fd23f6d720
| 198
|
py
|
Python
|
ppy_terminal/sketches_yaco/test_A/test_import.py
|
TechnologyClassroom/generative_art
|
eb1730d90e438327edaa53375765a9690b968d2b
|
[
"MIT"
] | 1
|
2022-03-03T19:41:02.000Z
|
2022-03-03T19:41:02.000Z
|
ppy_terminal/sketches_yaco/test_A/test_import.py
|
TechnologyClassroom/generative_art
|
eb1730d90e438327edaa53375765a9690b968d2b
|
[
"MIT"
] | null | null | null |
ppy_terminal/sketches_yaco/test_A/test_import.py
|
TechnologyClassroom/generative_art
|
eb1730d90e438327edaa53375765a9690b968d2b
|
[
"MIT"
] | null | null | null |
def print_something():
print('something')
def get_git_hash(filepath):
import subprocess
return subprocess.check_output(["git", "rev-list", "-1", "--abbrev-commit", "HEAD", filepath]).strip()
| 28.285714
| 104
| 0.70202
| 25
| 198
| 5.4
| 0.76
| 0.207407
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.00565
| 0.106061
| 198
| 6
| 105
| 33
| 0.757062
| 0
| 0
| 0
| 0
| 0
| 0.207071
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.4
| false
| 0
| 0.2
| 0
| 0.8
| 0.4
| 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
|
c55419e4a132f30629b9eb776b6ebbae91040801
| 38
|
py
|
Python
|
Problem146.py
|
Cleancode404/ProjectEuler
|
2f93b256b107bfb6a395b8aa197cfeacc599b00b
|
[
"MIT"
] | null | null | null |
Problem146.py
|
Cleancode404/ProjectEuler
|
2f93b256b107bfb6a395b8aa197cfeacc599b00b
|
[
"MIT"
] | null | null | null |
Problem146.py
|
Cleancode404/ProjectEuler
|
2f93b256b107bfb6a395b8aa197cfeacc599b00b
|
[
"MIT"
] | null | null | null |
"""
Investigating a Prime Pattern
"""
| 12.666667
| 30
| 0.684211
| 4
| 38
| 6.5
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.157895
| 38
| 3
| 31
| 12.666667
| 0.8125
| 0.763158
| 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
|
c56330a2a072bda92482d674aea2c16f266073e9
| 195
|
py
|
Python
|
utils.py
|
jroimartin/androguard_plugins
|
1cfb73d7347e1729a8f6ff52e51fd0bfe0081ed2
|
[
"BSD-3-Clause"
] | null | null | null |
utils.py
|
jroimartin/androguard_plugins
|
1cfb73d7347e1729a8f6ff52e51fd0bfe0081ed2
|
[
"BSD-3-Clause"
] | null | null | null |
utils.py
|
jroimartin/androguard_plugins
|
1cfb73d7347e1729a8f6ff52e51fd0bfe0081ed2
|
[
"BSD-3-Clause"
] | null | null | null |
#!/usr/bin/env python
import string
def str_to_filename(ustr):
safechars = '_' + string.digits + string.ascii_letters
return "".join(x for x in ustr.replace("/","_") if x in safechars)
| 24.375
| 70
| 0.682051
| 29
| 195
| 4.413793
| 0.758621
| 0.046875
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.169231
| 195
| 7
| 71
| 27.857143
| 0.790123
| 0.102564
| 0
| 0
| 0
| 0
| 0.017241
| 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
|
3d73f9a9d137eb23cd8fb8bad50753c7803445fb
| 316
|
py
|
Python
|
thinkutils_plus/common/StringBuilder.py
|
ThinkmanWang/thinkutils_plus
|
65d56a1a0cfce22dff08a4f0baea6b4eb08a2e35
|
[
"MIT"
] | null | null | null |
thinkutils_plus/common/StringBuilder.py
|
ThinkmanWang/thinkutils_plus
|
65d56a1a0cfce22dff08a4f0baea6b4eb08a2e35
|
[
"MIT"
] | null | null | null |
thinkutils_plus/common/StringBuilder.py
|
ThinkmanWang/thinkutils_plus
|
65d56a1a0cfce22dff08a4f0baea6b4eb08a2e35
|
[
"MIT"
] | null | null | null |
#!/usr/bin/python
#coding=utf-8
from cStringIO import StringIO
class StringBuilder:
_file_str = None
def __init__(self):
self._file_str = StringIO()
def append(self, str):
self._file_str.write(str)
def __str__(self):
return self._file_str.getvalue()
| 19.75
| 41
| 0.613924
| 39
| 316
| 4.564103
| 0.564103
| 0.157303
| 0.185393
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.004425
| 0.28481
| 316
| 16
| 41
| 19.75
| 0.783186
| 0.088608
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.333333
| false
| 0
| 0.111111
| 0.111111
| 0.777778
| 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
| 0
| 0
| 1
| 1
| 0
|
0
| 4
|
3d86036df107acd7de09b8e15a154072d93fc931
| 48
|
py
|
Python
|
pufsim/__init__.py
|
gregschmit/django-pufsim
|
5578cdbd2ced5b897868ca6a84217f0843c1269b
|
[
"MIT"
] | null | null | null |
pufsim/__init__.py
|
gregschmit/django-pufsim
|
5578cdbd2ced5b897868ca6a84217f0843c1269b
|
[
"MIT"
] | null | null | null |
pufsim/__init__.py
|
gregschmit/django-pufsim
|
5578cdbd2ced5b897868ca6a84217f0843c1269b
|
[
"MIT"
] | null | null | null |
default_app_config = 'pufsim.apps.CustomConfig'
| 24
| 47
| 0.833333
| 6
| 48
| 6.333333
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.0625
| 48
| 1
| 48
| 48
| 0.844444
| 0
| 0
| 0
| 0
| 0
| 0.5
| 0.5
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
3db0b5e924fae1112fbbab0ea8b5762fb54b2696
| 94
|
py
|
Python
|
django_ops/apps.py
|
alan404/django-ops
|
799128cdc24e98838a7cb88d4dd717a71dd4b85c
|
[
"Apache-2.0"
] | null | null | null |
django_ops/apps.py
|
alan404/django-ops
|
799128cdc24e98838a7cb88d4dd717a71dd4b85c
|
[
"Apache-2.0"
] | null | null | null |
django_ops/apps.py
|
alan404/django-ops
|
799128cdc24e98838a7cb88d4dd717a71dd4b85c
|
[
"Apache-2.0"
] | null | null | null |
from django.apps import AppConfig
class DjangoOpsConfig(AppConfig):
name = 'django_ops'
| 15.666667
| 33
| 0.765957
| 11
| 94
| 6.454545
| 0.818182
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.159574
| 94
| 5
| 34
| 18.8
| 0.898734
| 0
| 0
| 0
| 0
| 0
| 0.106383
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 0
| 0.333333
| 0
| 1
| 0
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 1
| 0
|
0
| 4
|
3dbdefa94209cf8fc6e044873121bd2a1dd6495a
| 202
|
py
|
Python
|
yolo/config.py
|
robsonzagrejr/computer_vision_project
|
3caf7bb724058465b1037035dd26e8d3162e7a21
|
[
"MIT"
] | null | null | null |
yolo/config.py
|
robsonzagrejr/computer_vision_project
|
3caf7bb724058465b1037035dd26e8d3162e7a21
|
[
"MIT"
] | null | null | null |
yolo/config.py
|
robsonzagrejr/computer_vision_project
|
3caf7bb724058465b1037035dd26e8d3162e7a21
|
[
"MIT"
] | null | null | null |
coco_file = 'yolo/darknet/coco.names'
yolo_cfg_file = 'yolo/darknet/yolov3-tiny.cfg'
yolo_weights_file = 'yolo/darknet/yolov3-tiny.weights'
img_size = (320,320)
conf_threshold = 0.5
nms_threshold = 0.3
| 28.857143
| 54
| 0.772277
| 34
| 202
| 4.352941
| 0.529412
| 0.162162
| 0.304054
| 0.283784
| 0.337838
| 0
| 0
| 0
| 0
| 0
| 0
| 0.065217
| 0.089109
| 202
| 7
| 55
| 28.857143
| 0.73913
| 0
| 0
| 0
| 0
| 0
| 0.408867
| 0.408867
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| false
| 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
| 1
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
3dd15d494701e2b295c4edd9e99921f126b72de4
| 110
|
py
|
Python
|
nhl/raw/stats/enumerations.py
|
devinsba/py-nhl
|
d6f560d9a43cd2b7183ba465e03ee7871365814c
|
[
"Apache-2.0"
] | null | null | null |
nhl/raw/stats/enumerations.py
|
devinsba/py-nhl
|
d6f560d9a43cd2b7183ba465e03ee7871365814c
|
[
"Apache-2.0"
] | null | null | null |
nhl/raw/stats/enumerations.py
|
devinsba/py-nhl
|
d6f560d9a43cd2b7183ba465e03ee7871365814c
|
[
"Apache-2.0"
] | null | null | null |
# Includes:
# Game Types
# Game Status
# Play Types
# Standings Types
# Stats Types
# Event Types
| 13.75
| 19
| 0.636364
| 13
| 110
| 5.384615
| 0.615385
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.290909
| 110
| 7
| 20
| 15.714286
| 0.897436
| 0.863636
| 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
|
3def1b29e37a332d4d958bd4bd88114812ae6bb1
| 119
|
py
|
Python
|
crawlab/tasks/celery.py
|
anhilo/crawlab
|
363f4bf7a4ccc192a99850998c1bd0fc363832a1
|
[
"BSD-3-Clause"
] | 1
|
2019-08-20T14:26:39.000Z
|
2019-08-20T14:26:39.000Z
|
crawlab/tasks/celery.py
|
anhilo/crawlab
|
363f4bf7a4ccc192a99850998c1bd0fc363832a1
|
[
"BSD-3-Clause"
] | 9
|
2019-05-24T03:53:09.000Z
|
2022-02-26T10:53:48.000Z
|
crawlab/tasks/celery.py
|
anhilo/crawlab
|
363f4bf7a4ccc192a99850998c1bd0fc363832a1
|
[
"BSD-3-Clause"
] | 1
|
2019-11-08T08:12:40.000Z
|
2019-11-08T08:12:40.000Z
|
from celery import Celery
# celery app instance
celery_app = Celery(__name__)
celery_app.config_from_object('config')
| 19.833333
| 39
| 0.815126
| 17
| 119
| 5.235294
| 0.470588
| 0.303371
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.109244
| 119
| 5
| 40
| 23.8
| 0.839623
| 0.159664
| 0
| 0
| 0
| 0
| 0.061224
| 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
|
9a71bbf8372c982b1bfab2518ea48cf8110c10fb
| 30
|
py
|
Python
|
modules/2.79/bpy/types/UserPreferences.py
|
cmbasnett/fake-bpy-module
|
acb8b0f102751a9563e5b5e5c7cd69a4e8aa2a55
|
[
"MIT"
] | null | null | null |
modules/2.79/bpy/types/UserPreferences.py
|
cmbasnett/fake-bpy-module
|
acb8b0f102751a9563e5b5e5c7cd69a4e8aa2a55
|
[
"MIT"
] | null | null | null |
modules/2.79/bpy/types/UserPreferences.py
|
cmbasnett/fake-bpy-module
|
acb8b0f102751a9563e5b5e5c7cd69a4e8aa2a55
|
[
"MIT"
] | null | null | null |
UserPreferences.view = None
| 7.5
| 27
| 0.766667
| 3
| 30
| 7.666667
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.166667
| 30
| 3
| 28
| 10
| 0.92
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
9a77914b283ea4c8bce4e4303f20f579eaa82d19
| 2,466
|
py
|
Python
|
bank.py
|
chulpyo/simple-atm-controller
|
18bd0243f267a7bbb0226adc927773fcbe040acc
|
[
"MIT"
] | null | null | null |
bank.py
|
chulpyo/simple-atm-controller
|
18bd0243f267a7bbb0226adc927773fcbe040acc
|
[
"MIT"
] | null | null | null |
bank.py
|
chulpyo/simple-atm-controller
|
18bd0243f267a7bbb0226adc927773fcbe040acc
|
[
"MIT"
] | null | null | null |
from __future__ import annotations
from typing import List, Dict, Optional
from abc import ABCMeta, abstractmethod
class AbstractBank(metaclass=ABCMeta):
def __init__(self, name: str) -> None:
self.name = name
self.card_numbers = dict()
@abstractmethod
def add_account(
self, card_number: str, pin: str, account: str, balance: int
) -> bool:
pass
@abstractmethod
def check_pin(self, card_number: str, pin: str) -> Optional[Dict[str, int]]:
pass
@abstractmethod
def control_balance(self, card_number: str, account: str, delta: int) -> int:
pass
@abstractmethod
def get_balance(self, card_number: str, account: str) -> int:
pass
class Bank(AbstractBank):
def add_account(self, card_number: str, pin: str, account: str, balance: int) -> bool:
if card_number in self.card_numbers:
if self.card_numbers[card_number][0] != pin:
return False
if account not in self.card_numbers[card_number][1]:
self.card_numbers[card_number][1][account] = balance
else:
return False
else:
self.card_numbers[card_number] = [pin, {account: balance}]
return True
def check_pin(self, card_number: str, pin: str) -> Optional[Dict[str, int]]:
if card_number in self.card_numbers:
if self.card_numbers[card_number][0] != pin:
return None
else:
return self.card_numbers[card_number][1].keys()
else:
return None
def control_balance(self, card_number: str, account: str, delta: int) -> int:
if card_number in self.card_numbers:
if account in self.card_numbers[card_number][1]:
if self.card_numbers[card_number][1][account] + delta >= 0:
self.card_numbers[card_number][1][account] += delta
return self.card_numbers[card_number][1][account]
else:
return -1
else:
return -1
else:
return -1
def get_balance(self, card_number: str, account: str) -> Optional[int]:
if card_number in self.card_numbers:
if account in self.card_numbers[card_number][1]:
return self.card_numbers[card_number][1][account]
else:
return -1
else:
return -1
| 33.324324
| 90
| 0.58678
| 301
| 2,466
| 4.61794
| 0.149502
| 0.143885
| 0.183453
| 0.164029
| 0.726619
| 0.708633
| 0.699281
| 0.632374
| 0.577698
| 0.520144
| 0
| 0.010083
| 0.316302
| 2,466
| 73
| 91
| 33.780822
| 0.814354
| 0
| 0
| 0.655738
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.147541
| false
| 0.065574
| 0.04918
| 0
| 0.442623
| 0
| 0
| 0
| 0
| null | 0
| 1
| 1
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
|
0
| 4
|
9a7c0ba9aee433fb27cd8cfaae086ce4f514ddc9
| 47
|
py
|
Python
|
Flask-todolist-Sqlite3-master/venv/lib/python3.6/bisect.py
|
IncredibleDraco/MyScholar
|
272aafa33f7227d1bc0d937d046788cbabede453
|
[
"Apache-2.0"
] | null | null | null |
Flask-todolist-Sqlite3-master/venv/lib/python3.6/bisect.py
|
IncredibleDraco/MyScholar
|
272aafa33f7227d1bc0d937d046788cbabede453
|
[
"Apache-2.0"
] | null | null | null |
Flask-todolist-Sqlite3-master/venv/lib/python3.6/bisect.py
|
IncredibleDraco/MyScholar
|
272aafa33f7227d1bc0d937d046788cbabede453
|
[
"Apache-2.0"
] | 1
|
2019-11-25T10:25:21.000Z
|
2019-11-25T10:25:21.000Z
|
/home/sheldon/anaconda3/lib/python3.6/bisect.py
| 47
| 47
| 0.829787
| 8
| 47
| 4.875
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.06383
| 0
| 47
| 1
| 47
| 47
| 0.765957
| 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
|
9aa663dd66eb65dc5504ad9c0809ae33ff35a8db
| 69
|
py
|
Python
|
rec/download_wordnet.py
|
semodi/arxiv_app
|
e33e8e1eae96e25cf41d4169dca82d88615e5d08
|
[
"BSD-3-Clause"
] | 1
|
2022-02-08T19:55:19.000Z
|
2022-02-08T19:55:19.000Z
|
rec/download_wordnet.py
|
semodi/paper-scraper
|
e33e8e1eae96e25cf41d4169dca82d88615e5d08
|
[
"BSD-3-Clause"
] | null | null | null |
rec/download_wordnet.py
|
semodi/paper-scraper
|
e33e8e1eae96e25cf41d4169dca82d88615e5d08
|
[
"BSD-3-Clause"
] | null | null | null |
import nltk
if __name__ == '__main__':
nltk.download('wordnet')
| 13.8
| 28
| 0.681159
| 8
| 69
| 4.875
| 0.875
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.173913
| 69
| 4
| 29
| 17.25
| 0.684211
| 0
| 0
| 0
| 0
| 0
| 0.217391
| 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
|
9aad2c4d86396aa96863863ce7e7f9a448a93f35
| 845
|
py
|
Python
|
aiotdlib/api/types/group_call_id.py
|
jraylan/aiotdlib
|
4528fcfca7c5c69b54a878ce6ce60e934a2dcc73
|
[
"MIT"
] | 37
|
2021-05-04T10:41:41.000Z
|
2022-03-30T13:48:05.000Z
|
aiotdlib/api/types/group_call_id.py
|
jraylan/aiotdlib
|
4528fcfca7c5c69b54a878ce6ce60e934a2dcc73
|
[
"MIT"
] | 13
|
2021-07-17T19:54:51.000Z
|
2022-02-26T06:50:00.000Z
|
aiotdlib/api/types/group_call_id.py
|
jraylan/aiotdlib
|
4528fcfca7c5c69b54a878ce6ce60e934a2dcc73
|
[
"MIT"
] | 7
|
2021-09-22T21:27:11.000Z
|
2022-02-20T02:33:19.000Z
|
# =============================================================================== #
# #
# This file has been generated automatically!! Do not change this manually! #
# #
# =============================================================================== #
from __future__ import annotations
from pydantic import Field
from ..base_object import BaseObject
class GroupCallId(BaseObject):
"""
Contains the group call identifier
:param id: Group call identifier
:type id: :class:`int`
"""
ID: str = Field("groupCallId", alias="@type")
id: int
@staticmethod
def read(q: dict) -> GroupCallId:
return GroupCallId.construct(**q)
| 30.178571
| 83
| 0.4
| 59
| 845
| 5.644068
| 0.661017
| 0.054054
| 0.114114
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.346746
| 845
| 27
| 84
| 31.296296
| 0.603261
| 0.586982
| 0
| 0
| 1
| 0
| 0.052288
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.111111
| false
| 0
| 0.333333
| 0.111111
| 0.888889
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 1
| 1
| 0
|
0
| 4
|
9ad7243ed045a4290e7c611afefcf5eb50e8ddff
| 796
|
py
|
Python
|
pyminder/python.py
|
HaydenMacDonald/pyminder
|
0717a8b84145ee5bb44f9da9959b26f5d54488ee
|
[
"MIT"
] | 19
|
2019-09-05T15:28:25.000Z
|
2022-03-06T23:37:28.000Z
|
pyminder/python.py
|
HaydenMacDonald/pyminder
|
0717a8b84145ee5bb44f9da9959b26f5d54488ee
|
[
"MIT"
] | 8
|
2019-12-15T22:41:32.000Z
|
2021-04-20T08:16:45.000Z
|
pyminder/python.py
|
HaydenMacDonald/pyminder
|
0717a8b84145ee5bb44f9da9959b26f5d54488ee
|
[
"MIT"
] | 3
|
2019-12-16T13:39:58.000Z
|
2021-07-13T05:47:49.000Z
|
import time
import random
import datetime
import os
class Python:
@staticmethod
def print(*lines):
if not lines:
print('')
for line in lines:
print(line)
@staticmethod
def input(prompt):
return input(prompt)
@staticmethod
def sleep(secs):
time.sleep(secs)
@staticmethod
def random_choice(items):
return random.choice(items)
@staticmethod
def time_now():
return time.time()
@staticmethod
def date_now():
return datetime.datetime.now()
def open_file(self, rel_path):
return open(os.path.join(self.get_base_dir(), rel_path), 'rb')
@staticmethod
def get_base_dir():
return os.path.dirname(os.path.dirname(os.path.realpath(__file__)))
| 18.952381
| 75
| 0.615578
| 96
| 796
| 4.958333
| 0.385417
| 0.220588
| 0.071429
| 0.063025
| 0.067227
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.281407
| 796
| 41
| 76
| 19.414634
| 0.832168
| 0
| 0
| 0.225806
| 0
| 0
| 0.002513
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.258065
| false
| 0
| 0.129032
| 0.193548
| 0.612903
| 0.096774
| 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
| 1
| 0
| 0
| 0
| 1
| 1
| 0
|
0
| 4
|
9adc697a788eaf072c23c9b8f263644ac54f17da
| 15,058
|
py
|
Python
|
angr/engines/pcode/arch/ArchPcode_MIPS_LE_32_default.py
|
matthewpruett/angr
|
bfba2af1ea2eb941001339f47a1264a685c60eec
|
[
"BSD-2-Clause"
] | 6,132
|
2015-08-06T23:24:47.000Z
|
2022-03-31T21:49:34.000Z
|
angr/engines/pcode/arch/ArchPcode_MIPS_LE_32_default.py
|
matthewpruett/angr
|
bfba2af1ea2eb941001339f47a1264a685c60eec
|
[
"BSD-2-Clause"
] | 2,272
|
2015-08-10T08:40:07.000Z
|
2022-03-31T23:46:44.000Z
|
angr/engines/pcode/arch/ArchPcode_MIPS_LE_32_default.py
|
matthewpruett/angr
|
bfba2af1ea2eb941001339f47a1264a685c60eec
|
[
"BSD-2-Clause"
] | 1,155
|
2015-08-06T23:37:39.000Z
|
2022-03-31T05:54:11.000Z
|
###
### This file was automatically generated
###
from archinfo.arch import register_arch, Endness, Register
from .common import ArchPcode
class ArchPcode_MIPS_LE_32_default(ArchPcode):
name = 'MIPS:LE:32:default'
pcode_arch = 'MIPS:LE:32:default'
description = 'MIPS32 32-bit addresses, little endian, with mips16e'
bits = 32
ip_offset = 0x80
sp_offset = 0x74
bp_offset = sp_offset
instruction_endness = Endness.LE
register_list = [
Register('zero', 4, 0x0),
Register('at', 4, 0x4),
Register('v0', 4, 0x8),
Register('v1', 4, 0xc),
Register('a0', 4, 0x10),
Register('a1', 4, 0x14),
Register('a2', 4, 0x18),
Register('a3', 4, 0x1c),
Register('t0', 4, 0x20),
Register('t1', 4, 0x24),
Register('t2', 4, 0x28),
Register('t3', 4, 0x2c),
Register('t4', 4, 0x30),
Register('t5', 4, 0x34),
Register('t6', 4, 0x38),
Register('t7', 4, 0x3c),
Register('s0', 4, 0x40),
Register('s1', 4, 0x44),
Register('s2', 4, 0x48),
Register('s3', 4, 0x4c),
Register('s4', 4, 0x50),
Register('s5', 4, 0x54),
Register('s6', 4, 0x58),
Register('s7', 4, 0x5c),
Register('t8', 4, 0x60),
Register('t9', 4, 0x64),
Register('k0', 4, 0x68),
Register('k1', 4, 0x6c),
Register('gp', 4, 0x70),
Register('sp', 4, 0x74),
Register('s8', 4, 0x78),
Register('ra', 4, 0x7c),
Register('pc', 4, 0x80, alias_names=('ip',)),
Register('f0_1', 8, 0x1000),
Register('f1', 4, 0x1000),
Register('f0', 4, 0x1004),
Register('f2_3', 8, 0x1008),
Register('f3', 4, 0x1008),
Register('f2', 4, 0x100c),
Register('f4_5', 8, 0x1010),
Register('f5', 4, 0x1010),
Register('f4', 4, 0x1014),
Register('f6_7', 8, 0x1018),
Register('f7', 4, 0x1018),
Register('f6', 4, 0x101c),
Register('f8_9', 8, 0x1020),
Register('f9', 4, 0x1020),
Register('f8', 4, 0x1024),
Register('f10_11', 8, 0x1028),
Register('f11', 4, 0x1028),
Register('f10', 4, 0x102c),
Register('f12_13', 8, 0x1030),
Register('f13', 4, 0x1030),
Register('f12', 4, 0x1034),
Register('f14_15', 8, 0x1038),
Register('f15', 4, 0x1038),
Register('f14', 4, 0x103c),
Register('f16_17', 8, 0x1040),
Register('f17', 4, 0x1040),
Register('f16', 4, 0x1044),
Register('f18_19', 8, 0x1048),
Register('f19', 4, 0x1048),
Register('f18', 4, 0x104c),
Register('f20_21', 8, 0x1050),
Register('f21', 4, 0x1050),
Register('f20', 4, 0x1054),
Register('f22_23', 8, 0x1058),
Register('f23', 4, 0x1058),
Register('f22', 4, 0x105c),
Register('f24_25', 8, 0x1060),
Register('f25', 4, 0x1060),
Register('f24', 4, 0x1064),
Register('f26_27', 8, 0x1068),
Register('f27', 4, 0x1068),
Register('f26', 4, 0x106c),
Register('f28_29', 8, 0x1070),
Register('f29', 4, 0x1070),
Register('f28', 4, 0x1074),
Register('f30_31', 8, 0x1078),
Register('f31', 4, 0x1078),
Register('f30', 4, 0x107c),
Register('fir', 4, 0x1200),
Register('fccr', 4, 0x1204),
Register('fexr', 4, 0x1208),
Register('fenr', 4, 0x120c),
Register('fcsr', 4, 0x1210),
Register('index', 4, 0x2000),
Register('random', 4, 0x2004),
Register('entrylo0', 4, 0x2008),
Register('entrylo1', 4, 0x200c),
Register('context', 4, 0x2010),
Register('pagemask', 4, 0x2014),
Register('wired', 4, 0x2018),
Register('hwrena', 4, 0x201c),
Register('badvaddr', 4, 0x2020),
Register('count', 4, 0x2024),
Register('entryhi', 4, 0x2028),
Register('compare', 4, 0x202c),
Register('status', 4, 0x2030),
Register('cause', 4, 0x2034),
Register('epc', 4, 0x2038),
Register('prid', 4, 0x203c),
Register('config', 4, 0x2040),
Register('lladdr', 4, 0x2044),
Register('watchlo', 4, 0x2048),
Register('watchhi', 4, 0x204c),
Register('xcontext', 4, 0x2050),
Register('cop0_reg21', 4, 0x2054),
Register('cop0_reg22', 4, 0x2058),
Register('debug', 4, 0x205c),
Register('depc', 4, 0x2060),
Register('perfcnt', 4, 0x2064),
Register('errctl', 4, 0x2068),
Register('cacheerr', 4, 0x206c),
Register('taglo', 4, 0x2070),
Register('taghi', 4, 0x2074),
Register('errorepc', 4, 0x2078),
Register('desave', 4, 0x207c),
Register('mvpcontrol', 4, 0x2100),
Register('vpecontrol', 4, 0x2104),
Register('tcstatus', 4, 0x2108),
Register('cop0_reg3.1', 4, 0x210c),
Register('contextconfig', 4, 0x2110),
Register('pagegrain', 4, 0x2114),
Register('srsconf0', 4, 0x2118),
Register('cop0_reg7.1', 4, 0x211c),
Register('cop0_reg8.1', 4, 0x2120),
Register('cop0_reg9.1', 4, 0x2124),
Register('cop0_reg10.1', 4, 0x2128),
Register('cop0_reg11.1', 4, 0x212c),
Register('intctl', 4, 0x2130),
Register('cop0_reg13.1', 4, 0x2134),
Register('cop0_reg14.1', 4, 0x2138),
Register('ebase', 4, 0x213c),
Register('config1', 4, 0x2140),
Register('cop0_reg17.1', 4, 0x2144),
Register('watchlo.1', 4, 0x2148),
Register('watchhi.1', 4, 0x214c),
Register('cop0_reg20.1', 4, 0x2150),
Register('cop0_reg21.1', 4, 0x2154),
Register('cop0_reg22.1', 4, 0x2158),
Register('tracecontrol', 4, 0x215c),
Register('cop0_reg24.1', 4, 0x2160),
Register('perfcnt.1', 4, 0x2164),
Register('cop0_reg26.1', 4, 0x2168),
Register('cacheerr.1', 4, 0x216c),
Register('datalo.1', 4, 0x2170),
Register('datahi.1', 4, 0x2174),
Register('cop0_reg30.1', 4, 0x2178),
Register('cop0_reg31.1', 4, 0x217c),
Register('mvpconf0', 4, 0x2200),
Register('vpeconf0', 4, 0x2204),
Register('tcbind', 4, 0x2208),
Register('cop0_reg3.2', 4, 0x220c),
Register('cop0_reg4.2', 4, 0x2210),
Register('cop0_reg5.2', 4, 0x2214),
Register('srsconf1', 4, 0x2218),
Register('cop0_reg7.2', 4, 0x221c),
Register('cop0_reg8.2', 4, 0x2220),
Register('cop0_reg9.2', 4, 0x2224),
Register('cop0_reg10.2', 4, 0x2228),
Register('cop0_reg11.2', 4, 0x222c),
Register('srsctl', 4, 0x2230),
Register('cop0_reg13.2', 4, 0x2234),
Register('cop0_reg14.2', 4, 0x2238),
Register('cop0_reg15.2', 4, 0x223c),
Register('config2', 4, 0x2240),
Register('cop0_reg17.2', 4, 0x2244),
Register('watchlo.2', 4, 0x2248),
Register('watchhi.2', 4, 0x224c),
Register('cop0_reg20.2', 4, 0x2250),
Register('cop0_reg21.2', 4, 0x2254),
Register('cop0_reg22.2', 4, 0x2258),
Register('tracecontrol2', 4, 0x225c),
Register('cop0_reg24.2', 4, 0x2260),
Register('perfcnt.2', 4, 0x2264),
Register('cop0_reg26.2', 4, 0x2268),
Register('cacheerr.2', 4, 0x226c),
Register('taglo.2', 4, 0x2270),
Register('taghi.2', 4, 0x2274),
Register('cop0_reg30.2', 4, 0x2278),
Register('cop0_reg31.2', 4, 0x227c),
Register('mvpconf1', 4, 0x2300),
Register('vpeconf1', 4, 0x2304),
Register('tcrestart', 4, 0x2308),
Register('cop0_reg3.3', 4, 0x230c),
Register('cop0_reg4.3', 4, 0x2310),
Register('cop0_reg5.3', 4, 0x2314),
Register('srsconf2', 4, 0x2318),
Register('cop0_reg7.3', 4, 0x231c),
Register('cop0_reg8.3', 4, 0x2320),
Register('cop0_reg9.3', 4, 0x2324),
Register('cop0_reg10.3', 4, 0x2328),
Register('cop0_reg11.3', 4, 0x232c),
Register('srsmap', 4, 0x2330),
Register('cop0_reg13.3', 4, 0x2334),
Register('cop0_reg14.3', 4, 0x2338),
Register('cop0_reg15.3', 4, 0x233c),
Register('config3', 4, 0x2340),
Register('cop0_reg17.3', 4, 0x2344),
Register('watchlo.3', 4, 0x2348),
Register('watchhi.3', 4, 0x234c),
Register('cop0_reg20.3', 4, 0x2350),
Register('cop0_reg21.3', 4, 0x2354),
Register('cop0_reg22.3', 4, 0x2358),
Register('usertracedata', 4, 0x235c),
Register('cop0_reg24.3', 4, 0x2360),
Register('perfcnt.3', 4, 0x2364),
Register('cop0_reg26.3', 4, 0x2368),
Register('cacheerr.3', 4, 0x236c),
Register('datalo.3', 4, 0x2370),
Register('datahi.3', 4, 0x2374),
Register('cop0_reg30.3', 4, 0x2378),
Register('cop0_reg31.3', 4, 0x237c),
Register('cop0_reg0.4', 4, 0x2400),
Register('yqmask', 4, 0x2404),
Register('tchalt', 4, 0x2408),
Register('cop0_reg3.4', 4, 0x240c),
Register('cop0_reg4.4', 4, 0x2410),
Register('cop0_reg5.4', 4, 0x2414),
Register('srsconf3', 4, 0x2418),
Register('cop0_reg7.4', 4, 0x241c),
Register('cop0_reg8.4', 4, 0x2420),
Register('cop0_reg9.4', 4, 0x2424),
Register('cop0_reg10.4', 4, 0x2428),
Register('cop0_reg11.4', 4, 0x242c),
Register('cop0_reg12.4', 4, 0x2430),
Register('cop0_reg13.4', 4, 0x2434),
Register('cop0_reg14.4', 4, 0x2438),
Register('cop0_reg15.4', 4, 0x243c),
Register('cop0_reg16.4', 4, 0x2440),
Register('cop0_reg17.4', 4, 0x2444),
Register('watchlo.4', 4, 0x2448),
Register('watchhi.4', 4, 0x244c),
Register('cop0_reg20.4', 4, 0x2450),
Register('cop0_reg21.4', 4, 0x2454),
Register('cop0_reg22.4', 4, 0x2458),
Register('tracebpc', 4, 0x245c),
Register('cop0_reg24.4', 4, 0x2460),
Register('perfcnt.4', 4, 0x2464),
Register('cop0_reg26.4', 4, 0x2468),
Register('cacheerr.4', 4, 0x246c),
Register('taglo.4', 4, 0x2470),
Register('taghi.4', 4, 0x2474),
Register('cop0_reg30.4', 4, 0x2478),
Register('cop0_reg31.4', 4, 0x247c),
Register('cop0_reg0.5', 4, 0x2500),
Register('vpeschedule', 4, 0x2504),
Register('tccontext', 4, 0x2508),
Register('cop0_reg3.5', 4, 0x250c),
Register('cop0_reg4.5', 4, 0x2510),
Register('cop0_reg5.5', 4, 0x2514),
Register('srsconf4', 4, 0x2518),
Register('cop0_reg7.5', 4, 0x251c),
Register('cop0_reg8.5', 4, 0x2520),
Register('cop0_reg9.5', 4, 0x2524),
Register('cop0_reg10.5', 4, 0x2528),
Register('cop0_reg11.5', 4, 0x252c),
Register('cop0_reg12.5', 4, 0x2530),
Register('cop0_reg13.5', 4, 0x2534),
Register('cop0_reg14.5', 4, 0x2538),
Register('cop0_reg15.5', 4, 0x253c),
Register('cop0_reg16.5', 4, 0x2540),
Register('cop0_reg17.5', 4, 0x2544),
Register('watchlo.5', 4, 0x2548),
Register('watchhi.5', 4, 0x254c),
Register('cop0_reg20.5', 4, 0x2550),
Register('cop0_reg21.5', 4, 0x2554),
Register('cop0_reg22.5', 4, 0x2558),
Register('cop0_reg23.5', 4, 0x255c),
Register('cop0_reg24.5', 4, 0x2560),
Register('perfcnt.5', 4, 0x2564),
Register('cop0_reg26.5', 4, 0x2568),
Register('cacheerr.5', 4, 0x256c),
Register('datalo.5', 4, 0x2570),
Register('datahi.5', 4, 0x2574),
Register('cop0_reg30.5', 4, 0x2578),
Register('cop0_reg31.5', 4, 0x257c),
Register('cop0_reg0.6', 4, 0x2600),
Register('vpeschefback', 4, 0x2604),
Register('tcschedule', 4, 0x2608),
Register('cop0_reg3.6', 4, 0x260c),
Register('cop0_reg4.6', 4, 0x2610),
Register('cop0_reg5.6', 4, 0x2614),
Register('cop0_reg6.6', 4, 0x2618),
Register('cop0_reg7.6', 4, 0x261c),
Register('cop0_reg8.6', 4, 0x2620),
Register('cop0_reg9.6', 4, 0x2624),
Register('cop0_reg10.6', 4, 0x2628),
Register('cop0_reg11.6', 4, 0x262c),
Register('cop0_reg12.6', 4, 0x2630),
Register('cop0_reg13.6', 4, 0x2634),
Register('cop0_reg14.6', 4, 0x2638),
Register('cop0_reg15.6', 4, 0x263c),
Register('cop0_reg16.6', 4, 0x2640),
Register('cop0_reg17.6', 4, 0x2644),
Register('watchlo.6', 4, 0x2648),
Register('watchhi.6', 4, 0x264c),
Register('cop0_reg20.6', 4, 0x2650),
Register('cop0_reg21.6', 4, 0x2654),
Register('cop0_reg22.6', 4, 0x2658),
Register('cop0_reg23.6', 4, 0x265c),
Register('cop0_reg24.6', 4, 0x2660),
Register('perfcnt.6', 4, 0x2664),
Register('cop0_reg26.6', 4, 0x2668),
Register('cacheerr.6', 4, 0x266c),
Register('taglo.6', 4, 0x2670),
Register('taghi.6', 4, 0x2674),
Register('cop0_reg30.6', 4, 0x2678),
Register('cop0_reg31.6', 4, 0x267c),
Register('cop0_reg0.7', 4, 0x2700),
Register('vpeopt', 4, 0x2704),
Register('tcschefback', 4, 0x2708),
Register('cop0_reg3.7', 4, 0x270c),
Register('cop0_reg4.7', 4, 0x2710),
Register('cop0_reg5.7', 4, 0x2714),
Register('cop0_reg6.7', 4, 0x2718),
Register('cop0_reg7.7', 4, 0x271c),
Register('cop0_reg8.7', 4, 0x2720),
Register('cop0_reg9.7', 4, 0x2724),
Register('cop0_reg10.7', 4, 0x2728),
Register('cop0_reg11.7', 4, 0x272c),
Register('cop0_reg12.7', 4, 0x2730),
Register('cop0_reg13.7', 4, 0x2734),
Register('cop0_reg14.7', 4, 0x2738),
Register('cop0_reg15.7', 4, 0x273c),
Register('cop0_reg16.7', 4, 0x2740),
Register('cop0_reg17.7', 4, 0x2744),
Register('watchlo.7', 4, 0x2748),
Register('watchhi.7', 4, 0x274c),
Register('cop0_reg20.7', 4, 0x2750),
Register('cop0_reg21.7', 4, 0x2754),
Register('cop0_reg22.7', 4, 0x2758),
Register('cop0_reg23.7', 4, 0x275c),
Register('cop0_reg24.7', 4, 0x2760),
Register('perfcnt.7', 4, 0x2764),
Register('cop0_reg26.7', 4, 0x2768),
Register('cacheerr.7', 4, 0x276c),
Register('datalo.7', 4, 0x2770),
Register('datahi.7', 4, 0x2774),
Register('cop0_reg30.7', 4, 0x2778),
Register('cop0_reg31.7', 4, 0x277c),
Register('hi', 4, 0x3000),
Register('lo', 4, 0x3004),
Register('hi1', 4, 0x3008),
Register('lo1', 4, 0x300c),
Register('hi2', 4, 0x3010),
Register('lo2', 4, 0x3014),
Register('hi3', 4, 0x3018),
Register('lo3', 4, 0x301c),
Register('tsp', 4, 0x3020),
Register('isamodeswitch', 1, 0x3f00),
Register('contextreg', 4, 0x4000)
]
register_arch(['mips:le:32:default'], 32, Endness.LE, ArchPcode_MIPS_LE_32_default)
| 40.047872
| 83
| 0.554456
| 1,845
| 15,058
| 4.426016
| 0.306775
| 0.218957
| 0.016654
| 0.009184
| 0.010531
| 0
| 0
| 0
| 0
| 0
| 0
| 0.247132
| 0.264776
| 15,058
| 375
| 84
| 40.154667
| 0.490471
| 0.002457
| 0
| 0
| 1
| 0
| 0.199987
| 0
| 0
| 0
| 0.136966
| 0
| 0
| 1
| 0
| false
| 0
| 0.00545
| 0
| 0.032698
| 0
| 0
| 0
| 0
| null | 1
| 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
|
9add0e864e8d8e7f68f6524284539a24935e307c
| 724
|
py
|
Python
|
node_exec/table_nodes.py
|
compix/NodeGraphQt
|
511c02aef02a7e16a9f40aa368c2f560bd3bbdff
|
[
"MIT"
] | null | null | null |
node_exec/table_nodes.py
|
compix/NodeGraphQt
|
511c02aef02a7e16a9f40aa368c2f560bd3bbdff
|
[
"MIT"
] | null | null | null |
node_exec/table_nodes.py
|
compix/NodeGraphQt
|
511c02aef02a7e16a9f40aa368c2f560bd3bbdff
|
[
"MIT"
] | null | null | null |
from node_exec.base_nodes import defNode, defInlineNode
TABLE_IDENTIFIER = 'Table'
@defNode(name='Row Values', returnNames=['row values'], identifier=TABLE_IDENTIFIER)
def getRowValues(table, rowIndex):
return table.getRowValues(rowIndex)
@defInlineNode(name='Number Of Columns', returnNames=['value'], identifier=TABLE_IDENTIFIER)
def getNumberOfColumns(table):
return f'{table}.ncols'
@defInlineNode(name='Number Of Rows', returnNames=['value'], identifier=TABLE_IDENTIFIER)
def getNumberOfRows(table):
return f'{table}.nrows'
@defNode(name='Get Cell Value', returnNames=['value'], identifier=TABLE_IDENTIFIER)
def getCellValue(table, rowIndex, colIndex):
return table.getCellValue(rowIndex, colIndex)
| 38.105263
| 92
| 0.777624
| 83
| 724
| 6.698795
| 0.385542
| 0.134892
| 0.179856
| 0.201439
| 0.23741
| 0.23741
| 0
| 0
| 0
| 0
| 0
| 0
| 0.093923
| 724
| 19
| 93
| 38.105263
| 0.847561
| 0
| 0
| 0
| 0
| 0
| 0.153103
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.285714
| false
| 0
| 0.071429
| 0.285714
| 0.642857
| 0
| 0
| 0
| 0
| null | 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 1
| 1
| 0
|
0
| 4
|
9aedf445aec88daa7a1586c072d0fcc239fb7b6d
| 60
|
py
|
Python
|
utils/loss.py
|
chansoopark98/CSNet-colorization
|
071fbd95f58bafb9991720f73b3b51cddd5e234c
|
[
"MIT"
] | 3
|
2021-11-29T05:30:12.000Z
|
2022-01-23T11:06:56.000Z
|
utils/loss.py
|
chansoopark98/CSNet-colorization
|
071fbd95f58bafb9991720f73b3b51cddd5e234c
|
[
"MIT"
] | null | null | null |
utils/loss.py
|
chansoopark98/CSNet-colorization
|
071fbd95f58bafb9991720f73b3b51cddd5e234c
|
[
"MIT"
] | null | null | null |
import tensorflow as tf
def ssim_loss(y_true, y_pred):
| 15
| 30
| 0.733333
| 11
| 60
| 3.727273
| 0.909091
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.2
| 60
| 4
| 31
| 15
| 0.854167
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | null | 0
| 0.5
| 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
|
9afe89b0bcd96642f21e80e15ece0207747e7790
| 1,294
|
py
|
Python
|
src/systemmanager.py
|
WinterLicht/Chaos-Projectile
|
3fffb788b241b7baa4247c1e630d83a7210ddc2e
|
[
"CC-BY-4.0"
] | 59
|
2015-03-25T21:29:06.000Z
|
2022-01-17T22:48:05.000Z
|
src/systemmanager.py
|
WinterLicht/Chaos-Projectile
|
3fffb788b241b7baa4247c1e630d83a7210ddc2e
|
[
"CC-BY-4.0"
] | 11
|
2015-07-07T07:10:42.000Z
|
2021-11-21T12:47:42.000Z
|
src/systemmanager.py
|
WinterLicht/Chaos-Projectile
|
3fffb788b241b7baa4247c1e630d83a7210ddc2e
|
[
"CC-BY-4.0"
] | 19
|
2015-07-13T06:44:44.000Z
|
2022-02-05T03:09:27.000Z
|
"""
.. module:: systemmanager
:Platform: Unix, Windows
:Synopsis: system manager contains all game systems.
"""
import rendersystem
import collisionsystem
import inputsystem
import animationsystem
import combatsystem
import statesystem
import soundsystem
class SystemManager(object):
"""System manager is a container of all game systems.
:Attributes:
- *systems* (systems list): all systems are stored here
"""
def __init__(self, event_manager, gameWorld):
"""
:param event_manager: event manager
:type event_manager: events.EventManager
:param gameWorld: game world
:type gameWorld: gameWorld.GameWorld
"""
self.systems = list()
self.systems.append(collisionsystem.CollisionSystem(event_manager, gameWorld))
self.systems.append(animationsystem.AnimationSystem(event_manager, gameWorld))
self.systems.append(inputsystem.InputSystem(event_manager, gameWorld))
self.systems.append(statesystem.StateSystem(event_manager, gameWorld))
self.systems.append(rendersystem.RenderSystem(event_manager, gameWorld))
self.systems.append(combatsystem.CombatSystem(event_manager, gameWorld))
#self.systems.append(soundsystem.SoundSystem(event_manager, gameWorld))
| 34.972973
| 86
| 0.729521
| 130
| 1,294
| 7.153846
| 0.323077
| 0.141935
| 0.180645
| 0.16129
| 0.245161
| 0.245161
| 0
| 0
| 0
| 0
| 0
| 0
| 0.180835
| 1,294
| 36
| 87
| 35.944444
| 0.877358
| 0.346213
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.0625
| false
| 0
| 0.4375
| 0
| 0.5625
| 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
|
9afea5c52e54a880a31bb5169e3b9b5252a54f03
| 976
|
py
|
Python
|
setup.py
|
AlexisLeon/read_env
|
c5784207d880bdb8d1add36e275895f752ba6166
|
[
"MIT"
] | null | null | null |
setup.py
|
AlexisLeon/read_env
|
c5784207d880bdb8d1add36e275895f752ba6166
|
[
"MIT"
] | null | null | null |
setup.py
|
AlexisLeon/read_env
|
c5784207d880bdb8d1add36e275895f752ba6166
|
[
"MIT"
] | null | null | null |
from setuptools import setup
setup(
name='read_env',
version='1.0',
py_modules=['read_env'],
description='Read .env files for your python project',
author='Alexis Leon',
author_email='alexis.leon@icloud.com',
url='https://github.com/AlexisLeon/read_env',
install_requires=[],
license='MIT',
zip_safe=False,
keywords='env environment variables',
classifiers=[
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Natural Language :: English',
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: Implementation :: PyPy',
]
)
| 34.857143
| 70
| 0.614754
| 100
| 976
| 5.93
| 0.56
| 0.256324
| 0.337268
| 0.175379
| 0.091062
| 0
| 0
| 0
| 0
| 0
| 0
| 0.016194
| 0.240779
| 976
| 28
| 71
| 34.857143
| 0.784076
| 0
| 0
| 0
| 0
| 0
| 0.599795
| 0.022518
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0.037037
| 0
| 0.037037
| 0
| 0
| 0
| 0
| null | 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
b127bf3f6b4ad86b3ae7ca3fd5fb8d9e1c2de683
| 370
|
py
|
Python
|
__init__.py
|
CCapelini/limpeza-de-alimentos-skill
|
a97f1fa468c783c0637d37cc400aa490a67df6b3
|
[
"Apache-2.0"
] | null | null | null |
__init__.py
|
CCapelini/limpeza-de-alimentos-skill
|
a97f1fa468c783c0637d37cc400aa490a67df6b3
|
[
"Apache-2.0"
] | null | null | null |
__init__.py
|
CCapelini/limpeza-de-alimentos-skill
|
a97f1fa468c783c0637d37cc400aa490a67df6b3
|
[
"Apache-2.0"
] | null | null | null |
from mycroft import MycroftSkill, intent_file_handler
class LimpezaDeAlimentos(MycroftSkill):
def __init__(self):
MycroftSkill.__init__(self)
@intent_file_handler('alimentos.de.limpeza.intent')
def handle_alimentos_de_limpeza(self, message):
self.speak_dialog('alimentos.de.limpeza')
def create_skill():
return LimpezaDeAlimentos()
| 23.125
| 55
| 0.754054
| 41
| 370
| 6.390244
| 0.536585
| 0.125954
| 0.206107
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.154054
| 370
| 15
| 56
| 24.666667
| 0.837061
| 0
| 0
| 0
| 0
| 0
| 0.127371
| 0.073171
| 0
| 0
| 0
| 0
| 0
| 1
| 0.333333
| false
| 0
| 0.111111
| 0.111111
| 0.666667
| 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
| 0
| 0
| 1
| 1
| 0
|
0
| 4
|
b1335a92c378fca669a39091e38a586a48973b93
| 307
|
py
|
Python
|
Robot.py
|
rhester5/robot_sim
|
9d715911f5ff08c6b325ff71fa8ee51586e6aee8
|
[
"MIT"
] | 1
|
2022-02-16T08:50:07.000Z
|
2022-02-16T08:50:07.000Z
|
Robot.py
|
rhester5/robot_sim
|
9d715911f5ff08c6b325ff71fa8ee51586e6aee8
|
[
"MIT"
] | null | null | null |
Robot.py
|
rhester5/robot_sim
|
9d715911f5ff08c6b325ff71fa8ee51586e6aee8
|
[
"MIT"
] | 1
|
2022-02-16T08:50:16.000Z
|
2022-02-16T08:50:16.000Z
|
import numpy as np
from Polygon import Polygon
class Robot(Polygon):
"""docstring for Robot"""
def __init__(self, pose):
super(Robot, self).__init__(pose)
self.pose = pose
def get_pose(self):
return self.pose
def set_pose(self, pose):
self.pose = pose
if __name__ == '__main__':
main()
| 15.35
| 35
| 0.690554
| 45
| 307
| 4.311111
| 0.466667
| 0.206186
| 0.185567
| 0.164948
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.185668
| 307
| 20
| 36
| 15.35
| 0.776
| 0.061889
| 0
| 0.166667
| 0
| 0
| 0.028369
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0.25
| false
| 0
| 0.166667
| 0.083333
| 0.583333
| 0
| 0
| 0
| 0
| null | 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
b134c44efd263e19e4279f4e43dd337c6579b4f1
| 110
|
py
|
Python
|
personal_portfolio/apps.py
|
js0823/portfolio
|
3be6b4731d4ce3376e67bdca5def1dd32c363a17
|
[
"MIT"
] | 1
|
2021-08-04T19:44:20.000Z
|
2021-08-04T19:44:20.000Z
|
personal_portfolio/apps.py
|
js0823/portfolio
|
3be6b4731d4ce3376e67bdca5def1dd32c363a17
|
[
"MIT"
] | null | null | null |
personal_portfolio/apps.py
|
js0823/portfolio
|
3be6b4731d4ce3376e67bdca5def1dd32c363a17
|
[
"MIT"
] | null | null | null |
from django.apps import AppConfig
class PersonalPortfolioConfig(AppConfig):
name = 'personal_portfolio'
| 18.333333
| 41
| 0.8
| 11
| 110
| 7.909091
| 0.909091
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.136364
| 110
| 5
| 42
| 22
| 0.915789
| 0
| 0
| 0
| 0
| 0
| 0.163636
| 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
|
b13c65380ccf8c0d9baa37cacdc35a4f7069975a
| 37,191
|
py
|
Python
|
tfne/visualizer/codeepneat/tfnev_codeepneat_mainwindow_ui.py
|
githealthy18/Tensorflow-Neuroevolution
|
15f6e906e8000c64f5c9a60907f53fe835f0b28c
|
[
"Apache-2.0"
] | 121
|
2019-06-27T17:30:52.000Z
|
2022-03-24T07:32:42.000Z
|
tfne/visualizer/codeepneat/tfnev_codeepneat_mainwindow_ui.py
|
githealthy18/Tensorflow-Neuroevolution
|
15f6e906e8000c64f5c9a60907f53fe835f0b28c
|
[
"Apache-2.0"
] | 10
|
2021-01-03T19:52:13.000Z
|
2022-02-10T00:15:26.000Z
|
tfne/visualizer/codeepneat/tfnev_codeepneat_mainwindow_ui.py
|
githealthy18/Tensorflow-Neuroevolution
|
15f6e906e8000c64f5c9a60907f53fe835f0b28c
|
[
"Apache-2.0"
] | 31
|
2019-07-31T10:45:53.000Z
|
2022-03-21T08:31:09.000Z
|
# -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'tfnev_codeepneat_mainwindow_ui.ui'
#
# Created by: PyQt5 UI code generator 5.15.0
#
# WARNING: Any manual changes made to this file will be lost when pyuic5 is
# run again. Do not edit this file unless you know what you are doing.
from PyQt5 import QtCore, QtGui, QtWidgets
class Ui_MainWindow(object):
def setupUi(self, MainWindow):
MainWindow.setObjectName("MainWindow")
MainWindow.resize(1000, 700)
self.centralwidget = QtWidgets.QWidget(MainWindow)
self.centralwidget.setEnabled(True)
self.centralwidget.setObjectName("centralwidget")
self.widget_genome_analysis = QtWidgets.QWidget(self.centralwidget)
self.widget_genome_analysis.setGeometry(QtCore.QRect(60, 10, 930, 660))
self.widget_genome_analysis.setObjectName("widget_genome_analysis")
self.ga_vline_1 = QtWidgets.QFrame(self.widget_genome_analysis)
self.ga_vline_1.setGeometry(QtCore.QRect(450, 0, 20, 660))
self.ga_vline_1.setFrameShape(QtWidgets.QFrame.VLine)
self.ga_vline_1.setFrameShadow(QtWidgets.QFrame.Sunken)
self.ga_vline_1.setObjectName("ga_vline_1")
self.ga_hline_1 = QtWidgets.QFrame(self.widget_genome_analysis)
self.ga_hline_1.setGeometry(QtCore.QRect(0, 320, 460, 20))
self.ga_hline_1.setFrameShape(QtWidgets.QFrame.HLine)
self.ga_hline_1.setFrameShadow(QtWidgets.QFrame.Sunken)
self.ga_hline_1.setObjectName("ga_hline_1")
self.ga_list_generations = QtWidgets.QListWidget(self.widget_genome_analysis)
self.ga_list_generations.setGeometry(QtCore.QRect(10, 370, 440, 290))
self.ga_list_generations.setVerticalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOn)
self.ga_list_generations.setObjectName("ga_list_generations")
self.ga_lbl_list_heading = QtWidgets.QLabel(self.widget_genome_analysis)
self.ga_lbl_list_heading.setGeometry(QtCore.QRect(60, 340, 340, 20))
font = QtGui.QFont()
font.setPointSize(12)
self.ga_lbl_list_heading.setFont(font)
self.ga_lbl_list_heading.setObjectName("ga_lbl_list_heading")
self.ga_widget_genome_visualization = QtWidgets.QWidget(self.widget_genome_analysis)
self.ga_widget_genome_visualization.setGeometry(QtCore.QRect(470, 0, 460, 460))
self.ga_widget_genome_visualization.setObjectName("ga_widget_genome_visualization")
self.ga_lbl_genome_id = QtWidgets.QLabel(self.widget_genome_analysis)
self.ga_lbl_genome_id.setGeometry(QtCore.QRect(470, 465, 460, 20))
font = QtGui.QFont()
font.setPointSize(12)
self.ga_lbl_genome_id.setFont(font)
self.ga_lbl_genome_id.setAlignment(QtCore.Qt.AlignCenter)
self.ga_lbl_genome_id.setObjectName("ga_lbl_genome_id")
self.ga_lbl_genome_fitness = QtWidgets.QLabel(self.widget_genome_analysis)
self.ga_lbl_genome_fitness.setGeometry(QtCore.QRect(470, 490, 170, 20))
self.ga_lbl_genome_fitness.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.ga_lbl_genome_fitness.setObjectName("ga_lbl_genome_fitness")
self.ga_lbl_genome_bp_id = QtWidgets.QLabel(self.widget_genome_analysis)
self.ga_lbl_genome_bp_id.setGeometry(QtCore.QRect(470, 515, 170, 20))
self.ga_lbl_genome_bp_id.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.ga_lbl_genome_bp_id.setObjectName("ga_lbl_genome_bp_id")
self.ga_lbl_genome_assign_mod = QtWidgets.QLabel(self.widget_genome_analysis)
self.ga_lbl_genome_assign_mod.setGeometry(QtCore.QRect(470, 540, 170, 20))
self.ga_lbl_genome_assign_mod.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.ga_lbl_genome_assign_mod.setObjectName("ga_lbl_genome_assign_mod")
self.ga_lbl_genome_out_layers = QtWidgets.QLabel(self.widget_genome_analysis)
self.ga_lbl_genome_out_layers.setGeometry(QtCore.QRect(470, 565, 170, 20))
self.ga_lbl_genome_out_layers.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.ga_lbl_genome_out_layers.setObjectName("ga_lbl_genome_out_layers")
self.ga_lbl_genome_input_shape = QtWidgets.QLabel(self.widget_genome_analysis)
self.ga_lbl_genome_input_shape.setGeometry(QtCore.QRect(470, 590, 170, 20))
self.ga_lbl_genome_input_shape.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.ga_lbl_genome_input_shape.setObjectName("ga_lbl_genome_input_shape")
self.ga_lbl_genome_dtype = QtWidgets.QLabel(self.widget_genome_analysis)
self.ga_lbl_genome_dtype.setGeometry(QtCore.QRect(470, 615, 170, 20))
self.ga_lbl_genome_dtype.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.ga_lbl_genome_dtype.setObjectName("ga_lbl_genome_dtype")
self.ga_lbl_genome_orig_gen = QtWidgets.QLabel(self.widget_genome_analysis)
self.ga_lbl_genome_orig_gen.setGeometry(QtCore.QRect(470, 640, 170, 20))
self.ga_lbl_genome_orig_gen.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.ga_lbl_genome_orig_gen.setObjectName("ga_lbl_genome_orig_gen")
self.ga_lbl_genome_fitness_value = QtWidgets.QLabel(self.widget_genome_analysis)
self.ga_lbl_genome_fitness_value.setGeometry(QtCore.QRect(640, 490, 290, 20))
self.ga_lbl_genome_fitness_value.setText("")
self.ga_lbl_genome_fitness_value.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.ga_lbl_genome_fitness_value.setObjectName("ga_lbl_genome_fitness_value")
self.ga_lbl_genome_assign_mod_area = QtWidgets.QScrollArea(self.widget_genome_analysis)
self.ga_lbl_genome_assign_mod_area.setGeometry(QtCore.QRect(640, 540, 290, 25))
self.ga_lbl_genome_assign_mod_area.setFrameShape(QtWidgets.QFrame.NoFrame)
self.ga_lbl_genome_assign_mod_area.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
self.ga_lbl_genome_assign_mod_area.setWidgetResizable(True)
self.ga_lbl_genome_assign_mod_area.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.ga_lbl_genome_assign_mod_area.setObjectName("ga_lbl_genome_assign_mod_area")
self.ga_lbl_genome_assign_mod_widget = QtWidgets.QWidget()
self.ga_lbl_genome_assign_mod_widget.setGeometry(QtCore.QRect(0, 0, 290, 25))
self.ga_lbl_genome_assign_mod_widget.setObjectName("ga_lbl_genome_assign_mod_widget")
self.ga_lbl_genome_assign_mod_layout = QtWidgets.QVBoxLayout(self.ga_lbl_genome_assign_mod_widget)
self.ga_lbl_genome_assign_mod_layout.setContentsMargins(0, 2, 10, 0)
self.ga_lbl_genome_assign_mod_layout.setObjectName("ga_lbl_genome_assign_mod_layout")
self.ga_lbl_genome_assign_mod_value = QtWidgets.QLabel(self.ga_lbl_genome_assign_mod_widget)
self.ga_lbl_genome_assign_mod_value.setText("")
self.ga_lbl_genome_assign_mod_value.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.ga_lbl_genome_assign_mod_value.setWordWrap(True)
self.ga_lbl_genome_assign_mod_value.setObjectName("ga_lbl_genome_assign_mod_value")
self.ga_lbl_genome_assign_mod_layout.addWidget(self.ga_lbl_genome_assign_mod_value)
self.ga_lbl_genome_assign_mod_area.setWidget(self.ga_lbl_genome_assign_mod_widget)
self.ga_lbl_genome_bp_id_value = QtWidgets.QLabel(self.widget_genome_analysis)
self.ga_lbl_genome_bp_id_value.setGeometry(QtCore.QRect(640, 515, 290, 20))
self.ga_lbl_genome_bp_id_value.setText("")
self.ga_lbl_genome_bp_id_value.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.ga_lbl_genome_bp_id_value.setObjectName("ga_lbl_genome_bp_id_value")
self.ga_lbl_genome_out_layers_area = QtWidgets.QScrollArea(self.widget_genome_analysis)
self.ga_lbl_genome_out_layers_area.setGeometry(QtCore.QRect(640, 565, 290, 25))
self.ga_lbl_genome_out_layers_area.setFrameShape(QtWidgets.QFrame.NoFrame)
self.ga_lbl_genome_out_layers_area.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
self.ga_lbl_genome_out_layers_area.setWidgetResizable(True)
self.ga_lbl_genome_out_layers_area.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.ga_lbl_genome_out_layers_area.setObjectName("ga_lbl_genome_out_layers_area")
self.ga_lbl_genome_out_layers_widget = QtWidgets.QWidget()
self.ga_lbl_genome_out_layers_widget.setGeometry(QtCore.QRect(0, 0, 290, 25))
self.ga_lbl_genome_out_layers_widget.setObjectName("ga_lbl_genome_out_layers_widget")
self.ga_lbl_genome_out_layers_layout = QtWidgets.QVBoxLayout(self.ga_lbl_genome_out_layers_widget)
self.ga_lbl_genome_out_layers_layout.setContentsMargins(0, 3, 10, 0)
self.ga_lbl_genome_out_layers_layout.setObjectName("ga_lbl_genome_out_layers_layout")
self.ga_lbl_genome_out_layers_value = QtWidgets.QLabel(self.ga_lbl_genome_out_layers_widget)
self.ga_lbl_genome_out_layers_value.setText("")
self.ga_lbl_genome_out_layers_value.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.ga_lbl_genome_out_layers_value.setWordWrap(True)
self.ga_lbl_genome_out_layers_value.setObjectName("ga_lbl_genome_out_layers_value")
self.ga_lbl_genome_out_layers_layout.addWidget(self.ga_lbl_genome_out_layers_value)
self.ga_lbl_genome_out_layers_area.setWidget(self.ga_lbl_genome_out_layers_widget)
self.ga_lbl_genome_input_shape_value = QtWidgets.QLabel(self.widget_genome_analysis)
self.ga_lbl_genome_input_shape_value.setGeometry(QtCore.QRect(640, 590, 290, 20))
self.ga_lbl_genome_input_shape_value.setText("")
self.ga_lbl_genome_input_shape_value.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.ga_lbl_genome_input_shape_value.setObjectName("ga_lbl_genome_input_shape_value")
self.ga_lbl_genome_dtype_value = QtWidgets.QLabel(self.widget_genome_analysis)
self.ga_lbl_genome_dtype_value.setGeometry(QtCore.QRect(640, 615, 290, 20))
self.ga_lbl_genome_dtype_value.setText("")
self.ga_lbl_genome_dtype_value.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.ga_lbl_genome_dtype_value.setObjectName("ga_lbl_genome_dtype_value")
self.ga_lbl_genome_orig_gen_value = QtWidgets.QLabel(self.widget_genome_analysis)
self.ga_lbl_genome_orig_gen_value.setGeometry(QtCore.QRect(640, 640, 290, 20))
self.ga_lbl_genome_orig_gen_value.setText("")
self.ga_lbl_genome_orig_gen_value.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.ga_lbl_genome_orig_gen_value.setObjectName("ga_lbl_genome_orig_gen_value")
self.widget_mod_bp_analysis = QtWidgets.QWidget(self.centralwidget)
self.widget_mod_bp_analysis.setGeometry(QtCore.QRect(60, 10, 930, 660))
self.widget_mod_bp_analysis.setObjectName("widget_mod_bp_analysis")
self.mba_hline_1 = QtWidgets.QFrame(self.widget_mod_bp_analysis)
self.mba_hline_1.setGeometry(QtCore.QRect(0, 300, 460, 20))
self.mba_hline_1.setFrameShape(QtWidgets.QFrame.HLine)
self.mba_hline_1.setFrameShadow(QtWidgets.QFrame.Sunken)
self.mba_hline_1.setObjectName("mba_hline_1")
self.mba_vline_1 = QtWidgets.QFrame(self.widget_mod_bp_analysis)
self.mba_vline_1.setGeometry(QtCore.QRect(450, 0, 20, 660))
self.mba_vline_1.setFrameShape(QtWidgets.QFrame.VLine)
self.mba_vline_1.setFrameShadow(QtWidgets.QFrame.Sunken)
self.mba_vline_1.setObjectName("mba_vline_1")
self.mba_list_generations = QtWidgets.QListWidget(self.widget_mod_bp_analysis)
self.mba_list_generations.setGeometry(QtCore.QRect(10, 30, 215, 270))
self.mba_list_generations.setVerticalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOn)
self.mba_list_generations.setObjectName("mba_list_generations")
self.mba_list_members = QtWidgets.QListWidget(self.widget_mod_bp_analysis)
self.mba_list_members.setGeometry(QtCore.QRect(235, 30, 215, 270))
self.mba_list_members.setVerticalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOn)
self.mba_list_members.setObjectName("mba_list_members")
self.mba_lbl_heading_generations = QtWidgets.QLabel(self.widget_mod_bp_analysis)
self.mba_lbl_heading_generations.setGeometry(QtCore.QRect(10, 0, 215, 20))
font = QtGui.QFont()
font.setPointSize(12)
self.mba_lbl_heading_generations.setFont(font)
self.mba_lbl_heading_generations.setObjectName("mba_lbl_heading_generations")
self.mba_lbl_heading_members = QtWidgets.QLabel(self.widget_mod_bp_analysis)
self.mba_lbl_heading_members.setGeometry(QtCore.QRect(235, 0, 215, 20))
font = QtGui.QFont()
font.setPointSize(12)
self.mba_lbl_heading_members.setFont(font)
self.mba_lbl_heading_members.setObjectName("mba_lbl_heading_members")
self.mba_widget_module = QtWidgets.QWidget(self.widget_mod_bp_analysis)
self.mba_widget_module.setGeometry(QtCore.QRect(470, 0, 460, 660))
self.mba_widget_module.setObjectName("mba_widget_module")
self.mba_lbl_module_heading = QtWidgets.QLabel(self.mba_widget_module)
self.mba_lbl_module_heading.setGeometry(QtCore.QRect(0, 0, 460, 20))
font = QtGui.QFont()
font.setPointSize(12)
self.mba_lbl_module_heading.setFont(font)
self.mba_lbl_module_heading.setAlignment(QtCore.Qt.AlignCenter)
self.mba_lbl_module_heading.setObjectName("mba_lbl_module_heading")
self.mba_lbl_module_summary = QtWidgets.QLabel(self.mba_widget_module)
self.mba_lbl_module_summary.setGeometry(QtCore.QRect(0, 30, 460, 630))
self.mba_lbl_module_summary.setText("")
self.mba_lbl_module_summary.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_module_summary.setWordWrap(True)
self.mba_lbl_module_summary.setObjectName("mba_lbl_module_summary")
self.mba_widget_blueprint = QtWidgets.QWidget(self.widget_mod_bp_analysis)
self.mba_widget_blueprint.setGeometry(QtCore.QRect(470, 0, 460, 660))
self.mba_widget_blueprint.setObjectName("mba_widget_blueprint")
self.mba_widget_blueprint_visualization = QtWidgets.QWidget(self.mba_widget_blueprint)
self.mba_widget_blueprint_visualization.setGeometry(QtCore.QRect(0, 0, 460, 460))
self.mba_widget_blueprint_visualization.setObjectName("mba_widget_blueprint_visualization")
self.mba_lbl_blueprint_heading = QtWidgets.QLabel(self.mba_widget_blueprint)
self.mba_lbl_blueprint_heading.setGeometry(QtCore.QRect(0, 465, 460, 20))
font = QtGui.QFont()
font.setPointSize(12)
self.mba_lbl_blueprint_heading.setFont(font)
self.mba_lbl_blueprint_heading.setAlignment(QtCore.Qt.AlignCenter)
self.mba_lbl_blueprint_heading.setObjectName("mba_lbl_blueprint_heading")
self.mba_lbl_bp_parent_mut = QtWidgets.QLabel(self.mba_widget_blueprint)
self.mba_lbl_bp_parent_mut.setGeometry(QtCore.QRect(0, 490, 110, 20))
self.mba_lbl_bp_parent_mut.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.mba_lbl_bp_parent_mut.setObjectName("mba_lbl_bp_parent_mut")
self.mba_lbl_bp_optimizer = QtWidgets.QLabel(self.mba_widget_blueprint)
self.mba_lbl_bp_optimizer.setGeometry(QtCore.QRect(0, 540, 110, 20))
self.mba_lbl_bp_optimizer.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.mba_lbl_bp_optimizer.setObjectName("mba_lbl_bp_optimizer")
self.mba_lbl_bp_parent_mut_area = QtWidgets.QScrollArea(self.mba_widget_blueprint)
self.mba_lbl_bp_parent_mut_area.setGeometry(QtCore.QRect(110, 490, 350, 45))
self.mba_lbl_bp_parent_mut_area.setFrameShape(QtWidgets.QFrame.NoFrame)
self.mba_lbl_bp_parent_mut_area.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
self.mba_lbl_bp_parent_mut_area.setWidgetResizable(True)
self.mba_lbl_bp_parent_mut_area.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_bp_parent_mut_area.setObjectName("mba_lbl_bp_parent_mut_area")
self.mba_lbl_bp_parent_mut_widget = QtWidgets.QWidget()
self.mba_lbl_bp_parent_mut_widget.setGeometry(QtCore.QRect(0, 0, 350, 45))
self.mba_lbl_bp_parent_mut_widget.setObjectName("mba_lbl_bp_parent_mut_widget")
self.mba_lbl_bp_parent_mut_layout = QtWidgets.QVBoxLayout(self.mba_lbl_bp_parent_mut_widget)
self.mba_lbl_bp_parent_mut_layout.setContentsMargins(0, 3, 10, 0)
self.mba_lbl_bp_parent_mut_layout.setObjectName("mba_lbl_bp_parent_mut_layout")
self.mba_lbl_bp_parent_mut_value = QtWidgets.QLabel(self.mba_lbl_bp_parent_mut_widget)
self.mba_lbl_bp_parent_mut_value.setText("")
self.mba_lbl_bp_parent_mut_value.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_bp_parent_mut_value.setWordWrap(True)
self.mba_lbl_bp_parent_mut_value.setObjectName("mba_lbl_bp_parent_mut_value")
self.mba_lbl_bp_parent_mut_layout.addWidget(self.mba_lbl_bp_parent_mut_value)
self.mba_lbl_bp_parent_mut_area.setWidget(self.mba_lbl_bp_parent_mut_widget)
self.mba_lbl_bp_optimizer_area = QtWidgets.QScrollArea(self.mba_widget_blueprint)
self.mba_lbl_bp_optimizer_area.setGeometry(QtCore.QRect(110, 540, 350, 45))
self.mba_lbl_bp_optimizer_area.setFrameShape(QtWidgets.QFrame.NoFrame)
self.mba_lbl_bp_optimizer_area.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
self.mba_lbl_bp_optimizer_area.setWidgetResizable(True)
self.mba_lbl_bp_optimizer_area.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_bp_optimizer_area.setObjectName("mba_lbl_bp_optimizer_area")
self.mba_lbl_bp_optimizer_widget = QtWidgets.QWidget()
self.mba_lbl_bp_optimizer_widget.setGeometry(QtCore.QRect(0, 0, 350, 45))
self.mba_lbl_bp_optimizer_widget.setObjectName("mba_lbl_bp_optimizer_widget")
self.mba_lbl_bp_optimizer_layout = QtWidgets.QVBoxLayout(self.mba_lbl_bp_optimizer_widget)
self.mba_lbl_bp_optimizer_layout.setContentsMargins(0, 3, 10, 0)
self.mba_lbl_bp_optimizer_layout.setObjectName("mba_lbl_bp_optimizer_layout")
self.mba_lbl_bp_optimizer_value = QtWidgets.QLabel(self.mba_lbl_bp_optimizer_widget)
self.mba_lbl_bp_optimizer_value.setText("")
self.mba_lbl_bp_optimizer_value.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_bp_optimizer_value.setWordWrap(True)
self.mba_lbl_bp_optimizer_value.setObjectName("mba_lbl_bp_optimizer_value")
self.mba_lbl_bp_optimizer_layout.addWidget(self.mba_lbl_bp_optimizer_value)
self.mba_lbl_bp_optimizer_area.setWidget(self.mba_lbl_bp_optimizer_widget)
self.mba_lbl_gen_summary_heading = QtWidgets.QLabel(self.widget_mod_bp_analysis)
self.mba_lbl_gen_summary_heading.setGeometry(QtCore.QRect(10, 320, 440, 20))
font = QtGui.QFont()
font.setPointSize(12)
self.mba_lbl_gen_summary_heading.setFont(font)
self.mba_lbl_gen_summary_heading.setAlignment(QtCore.Qt.AlignCenter)
self.mba_lbl_gen_summary_heading.setObjectName("mba_lbl_gen_summary_heading")
self.mba_lbl_gen_mod_spec = QtWidgets.QLabel(self.widget_mod_bp_analysis)
self.mba_lbl_gen_mod_spec.setGeometry(QtCore.QRect(10, 350, 160, 20))
self.mba_lbl_gen_mod_spec.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.mba_lbl_gen_mod_spec.setObjectName("mba_lbl_gen_mod_spec")
self.mba_lbl_gen_mod_spec_repr = QtWidgets.QLabel(self.widget_mod_bp_analysis)
self.mba_lbl_gen_mod_spec_repr.setGeometry(QtCore.QRect(10, 400, 160, 20))
self.mba_lbl_gen_mod_spec_repr.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.mba_lbl_gen_mod_spec_repr.setObjectName("mba_lbl_gen_mod_spec_repr")
self.mba_lbl_gen_mod_spec_fit_hist = QtWidgets.QLabel(self.widget_mod_bp_analysis)
self.mba_lbl_gen_mod_spec_fit_hist.setGeometry(QtCore.QRect(10, 450, 160, 20))
self.mba_lbl_gen_mod_spec_fit_hist.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.mba_lbl_gen_mod_spec_fit_hist.setObjectName("mba_lbl_gen_mod_spec_fit_hist")
self.mba_lbl_gen_bp_spec_fit_hist = QtWidgets.QLabel(self.widget_mod_bp_analysis)
self.mba_lbl_gen_bp_spec_fit_hist.setGeometry(QtCore.QRect(10, 600, 160, 20))
self.mba_lbl_gen_bp_spec_fit_hist.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.mba_lbl_gen_bp_spec_fit_hist.setObjectName("mba_lbl_gen_bp_spec_fit_hist")
self.mba_lbl_gen_bp_spec_repr = QtWidgets.QLabel(self.widget_mod_bp_analysis)
self.mba_lbl_gen_bp_spec_repr.setGeometry(QtCore.QRect(10, 550, 160, 20))
self.mba_lbl_gen_bp_spec_repr.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.mba_lbl_gen_bp_spec_repr.setObjectName("mba_lbl_gen_bp_spec_repr")
self.mba_lbl_gen_bp_spec = QtWidgets.QLabel(self.widget_mod_bp_analysis)
self.mba_lbl_gen_bp_spec.setGeometry(QtCore.QRect(10, 500, 160, 20))
self.mba_lbl_gen_bp_spec.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter)
self.mba_lbl_gen_bp_spec.setObjectName("mba_lbl_gen_bp_spec")
self.mba_lbl_gen_mod_spec_area = QtWidgets.QScrollArea(self.widget_mod_bp_analysis)
self.mba_lbl_gen_mod_spec_area.setGeometry(QtCore.QRect(170, 350, 280, 45))
self.mba_lbl_gen_mod_spec_area.setFrameShape(QtWidgets.QFrame.NoFrame)
self.mba_lbl_gen_mod_spec_area.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
self.mba_lbl_gen_mod_spec_area.setWidgetResizable(True)
self.mba_lbl_gen_mod_spec_area.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_gen_mod_spec_area.setObjectName("mba_lbl_gen_mod_spec_area")
self.mba_lbl_gen_mod_spec_widget = QtWidgets.QWidget()
self.mba_lbl_gen_mod_spec_widget.setGeometry(QtCore.QRect(0, 0, 280, 45))
self.mba_lbl_gen_mod_spec_widget.setObjectName("mba_lbl_gen_mod_spec_widget")
self.mba_lbl_gen_mod_spec_layout = QtWidgets.QVBoxLayout(self.mba_lbl_gen_mod_spec_widget)
self.mba_lbl_gen_mod_spec_layout.setContentsMargins(0, 3, 10, 0)
self.mba_lbl_gen_mod_spec_layout.setObjectName("mba_lbl_gen_mod_spec_layout")
self.mba_lbl_gen_mod_spec_value = QtWidgets.QLabel(self.mba_lbl_gen_mod_spec_widget)
self.mba_lbl_gen_mod_spec_value.setText("")
self.mba_lbl_gen_mod_spec_value.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_gen_mod_spec_value.setWordWrap(True)
self.mba_lbl_gen_mod_spec_value.setObjectName("mba_lbl_gen_mod_spec_value")
self.mba_lbl_gen_mod_spec_layout.addWidget(self.mba_lbl_gen_mod_spec_value)
self.mba_lbl_gen_mod_spec_area.setWidget(self.mba_lbl_gen_mod_spec_widget)
self.mba_lbl_gen_mod_spec_repr_area = QtWidgets.QScrollArea(self.widget_mod_bp_analysis)
self.mba_lbl_gen_mod_spec_repr_area.setGeometry(QtCore.QRect(170, 400, 280, 45))
self.mba_lbl_gen_mod_spec_repr_area.setFrameShape(QtWidgets.QFrame.NoFrame)
self.mba_lbl_gen_mod_spec_repr_area.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
self.mba_lbl_gen_mod_spec_repr_area.setWidgetResizable(True)
self.mba_lbl_gen_mod_spec_repr_area.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_gen_mod_spec_repr_area.setObjectName("mba_lbl_gen_mod_spec_repr_area")
self.mba_lbl_gen_mod_spec_repr_widget = QtWidgets.QWidget()
self.mba_lbl_gen_mod_spec_repr_widget.setGeometry(QtCore.QRect(0, 0, 280, 45))
self.mba_lbl_gen_mod_spec_repr_widget.setObjectName("mba_lbl_gen_mod_spec_repr_widget")
self.mba_lbl_gen_mod_spec_repr_layout = QtWidgets.QVBoxLayout(self.mba_lbl_gen_mod_spec_repr_widget)
self.mba_lbl_gen_mod_spec_repr_layout.setContentsMargins(0, 3, 10, 0)
self.mba_lbl_gen_mod_spec_repr_layout.setObjectName("mba_lbl_gen_mod_spec_repr_layout")
self.mba_lbl_gen_mod_spec_repr_value = QtWidgets.QLabel(self.mba_lbl_gen_mod_spec_repr_widget)
self.mba_lbl_gen_mod_spec_repr_value.setText("")
self.mba_lbl_gen_mod_spec_repr_value.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_gen_mod_spec_repr_value.setWordWrap(True)
self.mba_lbl_gen_mod_spec_repr_value.setObjectName("mba_lbl_gen_mod_spec_repr_value")
self.mba_lbl_gen_mod_spec_repr_layout.addWidget(self.mba_lbl_gen_mod_spec_repr_value)
self.mba_lbl_gen_mod_spec_repr_area.setWidget(self.mba_lbl_gen_mod_spec_repr_widget)
self.mba_lbl_gen_mod_spec_fit_hist_area = QtWidgets.QScrollArea(self.widget_mod_bp_analysis)
self.mba_lbl_gen_mod_spec_fit_hist_area.setGeometry(QtCore.QRect(170, 450, 280, 45))
self.mba_lbl_gen_mod_spec_fit_hist_area.setFrameShape(QtWidgets.QFrame.NoFrame)
self.mba_lbl_gen_mod_spec_fit_hist_area.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
self.mba_lbl_gen_mod_spec_fit_hist_area.setWidgetResizable(True)
self.mba_lbl_gen_mod_spec_fit_hist_area.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_gen_mod_spec_fit_hist_area.setObjectName("mba_lbl_gen_mod_spec_fit_hist_area")
self.mba_lbl_gen_mod_spec_fit_hist_widget = QtWidgets.QWidget()
self.mba_lbl_gen_mod_spec_fit_hist_widget.setGeometry(QtCore.QRect(0, 0, 280, 45))
self.mba_lbl_gen_mod_spec_fit_hist_widget.setObjectName("mba_lbl_gen_mod_spec_fit_hist_widget")
self.mba_lbl_gen_mod_spec_fit_hist_layout = QtWidgets.QVBoxLayout(self.mba_lbl_gen_mod_spec_fit_hist_widget)
self.mba_lbl_gen_mod_spec_fit_hist_layout.setContentsMargins(0, 3, 10, 0)
self.mba_lbl_gen_mod_spec_fit_hist_layout.setObjectName("mba_lbl_gen_mod_spec_fit_hist_layout")
self.mba_lbl_gen_mod_spec_fit_hist_value = QtWidgets.QLabel(self.mba_lbl_gen_mod_spec_fit_hist_widget)
self.mba_lbl_gen_mod_spec_fit_hist_value.setText("")
self.mba_lbl_gen_mod_spec_fit_hist_value.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_gen_mod_spec_fit_hist_value.setWordWrap(True)
self.mba_lbl_gen_mod_spec_fit_hist_value.setObjectName("mba_lbl_gen_mod_spec_fit_hist_value")
self.mba_lbl_gen_mod_spec_fit_hist_layout.addWidget(self.mba_lbl_gen_mod_spec_fit_hist_value)
self.mba_lbl_gen_mod_spec_fit_hist_area.setWidget(self.mba_lbl_gen_mod_spec_fit_hist_widget)
self.mba_lbl_gen_bp_spec_area = QtWidgets.QScrollArea(self.widget_mod_bp_analysis)
self.mba_lbl_gen_bp_spec_area.setGeometry(QtCore.QRect(170, 500, 280, 45))
self.mba_lbl_gen_bp_spec_area.setFrameShape(QtWidgets.QFrame.NoFrame)
self.mba_lbl_gen_bp_spec_area.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
self.mba_lbl_gen_bp_spec_area.setWidgetResizable(True)
self.mba_lbl_gen_bp_spec_area.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_gen_bp_spec_area.setObjectName("mba_lbl_gen_bp_spec_area")
self.mba_lbl_gen_bp_spec_widget = QtWidgets.QWidget()
self.mba_lbl_gen_bp_spec_widget.setGeometry(QtCore.QRect(0, 0, 280, 45))
self.mba_lbl_gen_bp_spec_widget.setObjectName("mba_lbl_gen_bp_spec_widget")
self.mba_lbl_gen_bp_spec_layout = QtWidgets.QVBoxLayout(self.mba_lbl_gen_bp_spec_widget)
self.mba_lbl_gen_bp_spec_layout.setContentsMargins(0, 3, 10, 0)
self.mba_lbl_gen_bp_spec_layout.setObjectName("mba_lbl_gen_bp_spec_layout")
self.mba_lbl_gen_bp_spec_value = QtWidgets.QLabel(self.mba_lbl_gen_bp_spec_widget)
self.mba_lbl_gen_bp_spec_value.setText("")
self.mba_lbl_gen_bp_spec_value.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_gen_bp_spec_value.setWordWrap(True)
self.mba_lbl_gen_bp_spec_value.setObjectName("mba_lbl_gen_bp_spec_value")
self.mba_lbl_gen_bp_spec_layout.addWidget(self.mba_lbl_gen_bp_spec_value)
self.mba_lbl_gen_bp_spec_area.setWidget(self.mba_lbl_gen_bp_spec_widget)
self.mba_lbl_gen_bp_spec_repr_area = QtWidgets.QScrollArea(self.widget_mod_bp_analysis)
self.mba_lbl_gen_bp_spec_repr_area.setGeometry(QtCore.QRect(170, 550, 280, 45))
self.mba_lbl_gen_bp_spec_repr_area.setFrameShape(QtWidgets.QFrame.NoFrame)
self.mba_lbl_gen_bp_spec_repr_area.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
self.mba_lbl_gen_bp_spec_repr_area.setWidgetResizable(True)
self.mba_lbl_gen_bp_spec_repr_area.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_gen_bp_spec_repr_area.setObjectName("mba_lbl_gen_bp_spec_repr_area")
self.mba_lbl_gen_bp_spec_repr_widget = QtWidgets.QWidget()
self.mba_lbl_gen_bp_spec_repr_widget.setGeometry(QtCore.QRect(0, 0, 280, 45))
self.mba_lbl_gen_bp_spec_repr_widget.setObjectName("mba_lbl_gen_bp_spec_repr_widget")
self.mba_lbl_gen_bp_spec_repr_layout = QtWidgets.QVBoxLayout(self.mba_lbl_gen_bp_spec_repr_widget)
self.mba_lbl_gen_bp_spec_repr_layout.setContentsMargins(0, 3, 10, 0)
self.mba_lbl_gen_bp_spec_repr_layout.setObjectName("mba_lbl_gen_bp_spec_repr_layout")
self.mba_lbl_gen_bp_spec_repr_value = QtWidgets.QLabel(self.mba_lbl_gen_bp_spec_repr_widget)
self.mba_lbl_gen_bp_spec_repr_value.setText("")
self.mba_lbl_gen_bp_spec_repr_value.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_gen_bp_spec_repr_value.setWordWrap(True)
self.mba_lbl_gen_bp_spec_repr_value.setObjectName("mba_lbl_gen_bp_spec_repr_value")
self.mba_lbl_gen_bp_spec_repr_layout.addWidget(self.mba_lbl_gen_bp_spec_repr_value)
self.mba_lbl_gen_bp_spec_repr_area.setWidget(self.mba_lbl_gen_bp_spec_repr_widget)
self.mba_lbl_gen_bp_spec_fit_hist_area = QtWidgets.QScrollArea(self.widget_mod_bp_analysis)
self.mba_lbl_gen_bp_spec_fit_hist_area.setGeometry(QtCore.QRect(170, 600, 280, 45))
self.mba_lbl_gen_bp_spec_fit_hist_area.setFrameShape(QtWidgets.QFrame.NoFrame)
self.mba_lbl_gen_bp_spec_fit_hist_area.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
self.mba_lbl_gen_bp_spec_fit_hist_area.setWidgetResizable(True)
self.mba_lbl_gen_bp_spec_fit_hist_area.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_gen_bp_spec_fit_hist_area.setObjectName("mba_lbl_gen_bp_spec_fit_hist_area")
self.mba_lbl_gen_bp_spec_fit_hist_widget = QtWidgets.QWidget()
self.mba_lbl_gen_bp_spec_fit_hist_widget.setGeometry(QtCore.QRect(0, 0, 280, 45))
self.mba_lbl_gen_bp_spec_fit_hist_widget.setObjectName("mba_lbl_gen_bp_spec_fit_hist_widget")
self.mba_lbl_gen_bp_spec_fit_hist_layout = QtWidgets.QVBoxLayout(self.mba_lbl_gen_bp_spec_fit_hist_widget)
self.mba_lbl_gen_bp_spec_fit_hist_layout.setContentsMargins(0, 3, 10, 0)
self.mba_lbl_gen_bp_spec_fit_hist_layout.setObjectName("mba_lbl_gen_bp_spec_fit_hist_layout")
self.mba_lbl_gen_bp_spec_fit_hist_value = QtWidgets.QLabel(self.mba_lbl_gen_bp_spec_fit_hist_widget)
self.mba_lbl_gen_bp_spec_fit_hist_value.setText("")
self.mba_lbl_gen_bp_spec_fit_hist_value.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignTop)
self.mba_lbl_gen_bp_spec_fit_hist_value.setWordWrap(True)
self.mba_lbl_gen_bp_spec_fit_hist_value.setObjectName("mba_lbl_gen_bp_spec_fit_hist_value")
self.mba_lbl_gen_bp_spec_fit_hist_layout.addWidget(self.mba_lbl_gen_bp_spec_fit_hist_value)
self.mba_lbl_gen_bp_spec_fit_hist_area.setWidget(self.mba_lbl_gen_bp_spec_fit_hist_widget)
self.widget_mod_species_analysis = QtWidgets.QWidget(self.centralwidget)
self.widget_mod_species_analysis.setGeometry(QtCore.QRect(60, 10, 930, 660))
self.widget_mod_species_analysis.setObjectName("widget_mod_species_analysis")
self.widget_bp_species_analysis = QtWidgets.QWidget(self.centralwidget)
self.widget_bp_species_analysis.setGeometry(QtCore.QRect(60, 10, 930, 660))
self.widget_bp_species_analysis.setObjectName("widget_bp_species_analysis")
MainWindow.setCentralWidget(self.centralwidget)
self.menubar = QtWidgets.QMenuBar(MainWindow)
self.menubar.setGeometry(QtCore.QRect(0, 0, 1000, 20))
self.menubar.setObjectName("menubar")
self.menu_help = QtWidgets.QMenu(self.menubar)
self.menu_help.setObjectName("menu_help")
self.menu_file = QtWidgets.QMenu(self.menubar)
self.menu_file.setObjectName("menu_file")
MainWindow.setMenuBar(self.menubar)
self.action_documentation = QtWidgets.QAction(MainWindow)
self.action_documentation.setObjectName("action_documentation")
self.action_close = QtWidgets.QAction(MainWindow)
self.action_close.setObjectName("action_close")
self.action_exit = QtWidgets.QAction(MainWindow)
self.action_exit.setObjectName("action_exit")
self.menu_help.addAction(self.action_documentation)
self.menu_file.addAction(self.action_close)
self.menu_file.addSeparator()
self.menu_file.addAction(self.action_exit)
self.menubar.addAction(self.menu_file.menuAction())
self.menubar.addAction(self.menu_help.menuAction())
self.retranslateUi(MainWindow)
QtCore.QMetaObject.connectSlotsByName(MainWindow)
def retranslateUi(self, MainWindow):
_translate = QtCore.QCoreApplication.translate
MainWindow.setWindowTitle(_translate("MainWindow", "Tensorflow-Neuroevolution Visualizer"))
self.ga_lbl_list_heading.setText(_translate("MainWindow", "List of generations and their best genome"))
self.ga_lbl_genome_id.setText(_translate("MainWindow", "Genome ID "))
self.ga_lbl_genome_fitness.setText(_translate("MainWindow", "Genome fitness: "))
self.ga_lbl_genome_bp_id.setText(_translate("MainWindow", "Genome blueprint ID:"))
self.ga_lbl_genome_assign_mod.setText(_translate("MainWindow", "Genome assigned modules:"))
self.ga_lbl_genome_out_layers.setText(_translate("MainWindow", "Genome output layers:"))
self.ga_lbl_genome_input_shape.setText(_translate("MainWindow", "Genome input shape:"))
self.ga_lbl_genome_dtype.setText(_translate("MainWindow", "Genome dtype:"))
self.ga_lbl_genome_orig_gen.setText(_translate("MainWindow", "Genome origin generation:"))
self.mba_lbl_heading_generations.setText(_translate("MainWindow", "Select Generation:"))
self.mba_lbl_heading_members.setText(_translate("MainWindow", "Select Member:"))
self.mba_lbl_module_heading.setText(_translate("MainWindow", "Summary of Module ID"))
self.mba_lbl_blueprint_heading.setText(_translate("MainWindow", "Blueprint ID "))
self.mba_lbl_bp_parent_mut.setText(_translate("MainWindow", "Parent Mutation:"))
self.mba_lbl_bp_optimizer.setText(_translate("MainWindow", "Optimizer:"))
self.mba_lbl_gen_summary_heading.setText(_translate("MainWindow", "Summary of Generation "))
self.mba_lbl_gen_mod_spec.setText(_translate("MainWindow", "Mod Species:"))
self.mba_lbl_gen_mod_spec_repr.setText(_translate("MainWindow", "Mod Species Repr:"))
self.mba_lbl_gen_mod_spec_fit_hist.setText(_translate("MainWindow", "Mod Species Fitness Hist:"))
self.mba_lbl_gen_bp_spec_fit_hist.setText(_translate("MainWindow", "BP Species Fitness Hist:"))
self.mba_lbl_gen_bp_spec_repr.setText(_translate("MainWindow", "BP Species Repr:"))
self.mba_lbl_gen_bp_spec.setText(_translate("MainWindow", "BP Species:"))
self.menu_help.setTitle(_translate("MainWindow", "Help"))
self.menu_file.setTitle(_translate("MainWindow", "File"))
self.action_documentation.setText(_translate("MainWindow", "Documentation"))
self.action_close.setText(_translate("MainWindow", "Close TFNE Backup"))
self.action_exit.setText(_translate("MainWindow", "Exit"))
| 79.298507
| 124
| 0.787852
| 5,398
| 37,191
| 4.952946
| 0.039644
| 0.070018
| 0.099491
| 0.087522
| 0.880685
| 0.804945
| 0.715552
| 0.600239
| 0.534448
| 0.462373
| 0
| 0.022111
| 0.124439
| 37,191
| 468
| 125
| 79.467949
| 0.798944
| 0.007932
| 0
| 0.030837
| 1
| 0
| 0.081165
| 0.051426
| 0
| 0
| 0
| 0
| 0
| 1
| 0.004405
| false
| 0
| 0.002203
| 0
| 0.008811
| 0.037445
| 0
| 0
| 0
| null | 0
| 0
| 0
| 1
| 1
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
|
0
| 4
|
b15c63cc1f38853136810b336da30d86ce243826
| 50
|
py
|
Python
|
python/1 - Intro to Python for Data Science/1- Python Basics/2- Any comments.py
|
Gabriela-Santos/datacamp
|
f2dd595a39f35ae558411d92aaa97a11398a5bb1
|
[
"MIT"
] | null | null | null |
python/1 - Intro to Python for Data Science/1- Python Basics/2- Any comments.py
|
Gabriela-Santos/datacamp
|
f2dd595a39f35ae558411d92aaa97a11398a5bb1
|
[
"MIT"
] | null | null | null |
python/1 - Intro to Python for Data Science/1- Python Basics/2- Any comments.py
|
Gabriela-Santos/datacamp
|
f2dd595a39f35ae558411d92aaa97a11398a5bb1
|
[
"MIT"
] | null | null | null |
# Division
print(5 / 8)
# Addition
print(7 + 10)
| 8.333333
| 13
| 0.62
| 8
| 50
| 3.875
| 0.875
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0.128205
| 0.22
| 50
| 5
| 14
| 10
| 0.666667
| 0.34
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| true
| 0
| 0
| 0
| 0
| 1
| 1
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| 0
| null | 0
| 0
| 0
| 0
| 0
| 0
| 1
| 0
| 0
| 0
| 0
| 1
|
0
| 4
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.