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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
67fd71b159a22e60b64a07348a0a3e35c2a3b7e5 | 382 | py | Python | phyutil/__init__.py | frib-high-level-controls/phyhlc | 6486607e3aa0212054a12e9f2ad1a3ef15542f48 | [
"BSD-3-Clause"
] | 1 | 2018-03-22T15:18:54.000Z | 2018-03-22T15:18:54.000Z | phyutil/__init__.py | frib-high-level-controls/phyhlc | 6486607e3aa0212054a12e9f2ad1a3ef15542f48 | [
"BSD-3-Clause"
] | null | null | null | phyutil/__init__.py | frib-high-level-controls/phyhlc | 6486607e3aa0212054a12e9f2ad1a3ef15542f48 | [
"BSD-3-Clause"
] | null | null | null | # encoding: UTF-8
"""Physics Applications Utility"""
__copyright__ = "Copyright (c) 2015, Facility for Rare Isotope Beams"
__author__ = "Dylan Maxwell"
__version__ = "0.0.1"
import logging
import phylib
import machine
from machine import *
from phylib.libCore import *
# configure the root logger
logging.basicConfi... | 21.222222 | 79 | 0.740838 | 50 | 382 | 5.42 | 0.74 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.024169 | 0.133508 | 382 | 17 | 80 | 22.470588 | 0.794562 | 0.185864 | 0 | 0 | 0 | 0 | 0.388158 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.555556 | 0 | 0.555556 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 2 |
db15276b717208ef752639b4aaf944577ef66238 | 1,032 | py | Python | mportal/wsgi_start.py | auyeongwy/mportal | e406baea802093569c90c7206649c5afd9431dab | [
"Apache-2.0"
] | null | null | null | mportal/wsgi_start.py | auyeongwy/mportal | e406baea802093569c90c7206649c5afd9431dab | [
"Apache-2.0"
] | null | null | null | mportal/wsgi_start.py | auyeongwy/mportal | e406baea802093569c90c7206649c5afd9431dab | [
"Apache-2.0"
] | null | null | null | # Copyright 2014 Au Yeong Wing Yau
#
# 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... | 34.4 | 74 | 0.774225 | 156 | 1,032 | 5.032051 | 0.641026 | 0.076433 | 0.033121 | 0.040764 | 0.073885 | 0 | 0 | 0 | 0 | 0 | 0 | 0.010239 | 0.148256 | 1,032 | 29 | 75 | 35.586207 | 0.882821 | 0.749031 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0.428571 | 0 | 0.428571 | 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 | 0 | 0 | 0 | 0 | 2 |
db33adbcb92391813fa24af06e3df16ea1f77a19 | 236 | py | Python | pyvisdk/enums/virtual_machine_ht_sharing.py | Infinidat/pyvisdk | f2f4e5f50da16f659ccc1d84b6a00f397fa997f8 | [
"MIT"
] | null | null | null | pyvisdk/enums/virtual_machine_ht_sharing.py | Infinidat/pyvisdk | f2f4e5f50da16f659ccc1d84b6a00f397fa997f8 | [
"MIT"
] | null | null | null | pyvisdk/enums/virtual_machine_ht_sharing.py | Infinidat/pyvisdk | f2f4e5f50da16f659ccc1d84b6a00f397fa997f8 | [
"MIT"
] | null | null | null |
########################################
# Automatically generated, do not edit.
########################################
from pyvisdk.thirdparty import Enum
VirtualMachineHtSharing = Enum(
'any',
'internal',
'none',
)
| 15.733333 | 40 | 0.440678 | 15 | 236 | 6.933333 | 0.933333 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.152542 | 236 | 14 | 41 | 16.857143 | 0.52 | 0.15678 | 0 | 0 | 1 | 0 | 0.12931 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.166667 | 0 | 0.166667 | 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 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
e1d83fca2e1bb93962f5e57c6f7075495edf9d91 | 8,688 | py | Python | src/06_tool/regular_expression.py | edgardeng/python-advance-interview | 59fd7bee8e871acdc7fdfecf2a110db840c47ebb | [
"Apache-2.0"
] | 1 | 2022-03-06T13:03:56.000Z | 2022-03-06T13:03:56.000Z | src/06_tool/regular_expression.py | edgardeng/python-advance-interview | 59fd7bee8e871acdc7fdfecf2a110db840c47ebb | [
"Apache-2.0"
] | null | null | null | src/06_tool/regular_expression.py | edgardeng/python-advance-interview | 59fd7bee8e871acdc7fdfecf2a110db840c47ebb | [
"Apache-2.0"
] | null | null | null | '''
' Python Regular Expression 正则表达式
'
'''
import re
def test_match():
s = 'hello python Hello'
p = 'hello'
o = re.match(p, s)
print(o)
print(dir(o))
print(o.group()) # 返回匹配的字符串
print(o.span()) # 范围
print(o.start()) # 开始处
print('*' * 30, 'flags参数的使用')
o2 = re.match(p, s, re.L)
print(o2.grou... | 30.484211 | 111 | 0.536027 | 1,432 | 8,688 | 3.210894 | 0.155028 | 0.191823 | 0.292301 | 0.07351 | 0.610048 | 0.555241 | 0.446498 | 0.366464 | 0.332753 | 0.319704 | 0 | 0.09557 | 0.142495 | 8,688 | 284 | 112 | 30.591549 | 0.521611 | 0.05145 | 0 | 0.046512 | 0 | 0.013953 | 0.3446 | 0.057352 | 0 | 0 | 0 | 0 | 0 | 1 | 0.065116 | false | 0 | 0.004651 | 0 | 0.069767 | 0.860465 | 0 | 0 | 0 | null | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 2 |
e1ed3b48fe37cb69350c8b6542e4845c264e91f2 | 1,125 | py | Python | src/mist/api/poller/schedulers.py | vladimir-ilyashenko/mist.api | f77c451679732ac1cfdafa85ad023c7c170faec4 | [
"Apache-2.0"
] | null | null | null | src/mist/api/poller/schedulers.py | vladimir-ilyashenko/mist.api | f77c451679732ac1cfdafa85ad023c7c170faec4 | [
"Apache-2.0"
] | null | null | null | src/mist/api/poller/schedulers.py | vladimir-ilyashenko/mist.api | f77c451679732ac1cfdafa85ad023c7c170faec4 | [
"Apache-2.0"
] | null | null | null | from celerybeatmongo.schedulers import MongoScheduler
from mist.api.sharding.mixins import ShardManagerMixin
from mist.api.poller.models import PollingSchedule
from mist.api.poller.models import OwnerPollingSchedule
from mist.api.poller.models import CloudPollingSchedule
from mist.api.poller.models import MachinePoll... | 26.162791 | 74 | 0.826667 | 101 | 1,125 | 9.168317 | 0.316832 | 0.043197 | 0.059395 | 0.073434 | 0.319654 | 0.319654 | 0.194384 | 0 | 0 | 0 | 0 | 0.008048 | 0.116444 | 1,125 | 42 | 75 | 26.785714 | 0.923541 | 0 | 0 | 0.28 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0.12 | 0.28 | 0 | 0.88 | 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 | 0 | 1 | 0 | 0 | 1 | 0 | 0 | 2 |
c00233a09c18a5f027b1634d9d3dd63a23d04cbb | 1,009 | py | Python | morpfw/authn/pas/user/rulesprovider.py | morpframework/morpfw | b867e5809d6c52e8839586670a29fcd179ce64c7 | [
"Apache-2.0"
] | 8 | 2018-12-08T01:41:58.000Z | 2020-12-21T15:30:12.000Z | morpfw/authn/pas/user/rulesprovider.py | morpframework/morpfw | b867e5809d6c52e8839586670a29fcd179ce64c7 | [
"Apache-2.0"
] | 17 | 2019-02-05T15:01:32.000Z | 2020-04-28T16:17:42.000Z | morpfw/authn/pas/user/rulesprovider.py | morpframework/morpfw | b867e5809d6c52e8839586670a29fcd179ce64c7 | [
"Apache-2.0"
] | 2 | 2018-12-08T05:03:37.000Z | 2019-03-20T07:15:21.000Z | from ....crud.rulesprovider.base import RulesProvider
from .. import exc
from ..app import App
from ..utils import has_role
from .model import UserCollection, UserModel
class UserRulesProvider(RulesProvider):
context: UserModel
def change_password(self, password: str, new_password: str, secure: bool = True)... | 34.793103 | 87 | 0.718533 | 117 | 1,009 | 6.102564 | 0.376068 | 0.046218 | 0.042017 | 0.056022 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.189296 | 1,009 | 28 | 88 | 36.035714 | 0.872861 | 0 | 0 | 0.095238 | 0 | 0 | 0.023786 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.142857 | false | 0.285714 | 0.238095 | 0.047619 | 0.619048 | 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 | 0 | 1 | 0 | 0 | 1 | 0 | 0 | 2 |
c01048af256422693f245a8c170084866f81cf42 | 1,733 | py | Python | bin/plpproject.py | stefanct/pulp-tools | 63a05d59908534ad01133d0111e181fa69d00ce3 | [
"Apache-2.0"
] | 2 | 2018-02-09T08:12:34.000Z | 2020-06-16T17:45:33.000Z | bin/plpproject.py | stefanct/pulp-tools | 63a05d59908534ad01133d0111e181fa69d00ce3 | [
"Apache-2.0"
] | 2 | 2018-02-09T07:54:32.000Z | 2018-03-09T08:51:31.000Z | bin/plpproject.py | stefanct/pulp-tools | 63a05d59908534ad01133d0111e181fa69d00ce3 | [
"Apache-2.0"
] | 6 | 2018-03-08T11:12:22.000Z | 2019-12-05T12:36:47.000Z |
#
# Copyright (C) 2018 ETH Zurich and University of Bologna
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicab... | 23.739726 | 74 | 0.705713 | 240 | 1,733 | 4.883333 | 0.4 | 0.047782 | 0.075085 | 0.054608 | 0.227816 | 0.09215 | 0 | 0 | 0 | 0 | 0 | 0.005634 | 0.180612 | 1,733 | 72 | 75 | 24.069444 | 0.819718 | 0.332949 | 0 | 0.272727 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.272727 | false | 0 | 0.030303 | 0.030303 | 0.545455 | 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 | 0 | 0 | 1 | 0 | 0 | 2 |
c01466f2b1b58f8291be4e054c30cb12aa407427 | 326 | py | Python | string_30.py | Technicoryx/python_strings_inbuilt_functions | 78892d043c6c6d65affe3bd4906ba0162c5d6604 | [
"MIT"
] | null | null | null | string_30.py | Technicoryx/python_strings_inbuilt_functions | 78892d043c6c6d65affe3bd4906ba0162c5d6604 | [
"MIT"
] | null | null | null | string_30.py | Technicoryx/python_strings_inbuilt_functions | 78892d043c6c6d65affe3bd4906ba0162c5d6604 | [
"MIT"
] | null | null | null | """Below Python Programme demonstrate rpartition
functions in a string"""
string = "Python is fun"
# 'is' separator is found
print(string.rpartition('is '))
# 'not' separator is not found
print(string.rpartition('not '))
string = "Python is fun, isn't it"
# splits at last occurence of 'is'
print(string.rpartition('... | 21.733333 | 48 | 0.717791 | 47 | 326 | 4.978723 | 0.489362 | 0.141026 | 0.269231 | 0.145299 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.147239 | 326 | 14 | 49 | 23.285714 | 0.841727 | 0.472393 | 0 | 0.4 | 0 | 0 | 0.27439 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0 | 0 | 0 | 0.6 | 0 | 0 | 0 | null | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 2 |
c014e0fef503433734848ae3b6b9307338d2ae08 | 4,583 | py | Python | env/lib/python3.8/site-packages/unidecode/x054.py | avdhari/enigma | b7e965a91ca5f0e929c4c719d695f15ccb8b5a2c | [
"MIT"
] | 48 | 2021-11-20T08:17:53.000Z | 2022-03-19T13:57:15.000Z | venv/lib/python3.6/site-packages/unidecode/x054.py | mrsaicharan1/iiita-updates | a22a0157b90d29b946d0f020e5f76744f73a6bff | [
"Apache-2.0"
] | 392 | 2015-07-30T14:37:05.000Z | 2022-03-21T16:56:09.000Z | venv/lib/python3.6/site-packages/unidecode/x054.py | mrsaicharan1/iiita-updates | a22a0157b90d29b946d0f020e5f76744f73a6bff | [
"Apache-2.0"
] | 15 | 2015-10-01T21:31:08.000Z | 2020-05-05T00:03:27.000Z | data = (
'Mie ', # 0x00
'Xu ', # 0x01
'Mang ', # 0x02
'Chi ', # 0x03
'Ge ', # 0x04
'Xuan ', # 0x05
'Yao ', # 0x06
'Zi ', # 0x07
'He ', # 0x08
'Ji ', # 0x09
'Diao ', # 0x0a
'Cun ', # 0x0b
'Tong ', # 0x0c
'Ming ', # 0x0d
'Hou ', # 0x0e
'Li ', # 0x0f
'Tu ', # 0x10
'Xiang ... | 17.694981 | 19 | 0.382064 | 510 | 4,583 | 3.433333 | 0.805882 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.206674 | 0.391883 | 4,583 | 258 | 20 | 17.763566 | 0.4216 | 0.279075 | 0 | 0.616279 | 0 | 0 | 0.324253 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
c01a9c714b265a55e25bf66dffd00ac40d13d9db | 1,504 | py | Python | cnn/test2.py | INFINITSY/darts | 684f97e407ee044a14c375f4a3078398a4b802bc | [
"Apache-2.0"
] | null | null | null | cnn/test2.py | INFINITSY/darts | 684f97e407ee044a14c375f4a3078398a4b802bc | [
"Apache-2.0"
] | null | null | null | cnn/test2.py | INFINITSY/darts | 684f97e407ee044a14c375f4a3078398a4b802bc | [
"Apache-2.0"
] | null | null | null | import matplotlib.pyplot as plt
import numpy as np
# darts_025 = [0, 0, 0, 0, 2, 5, 6, 7, 8]
darts_025 = [0, 0, 0, 2, 3, 5, 7, 8]
darts_05 = [0, 0, 3, 3, 4, 4, 5, 7, 7]
adas_025_9 = [0, 0, 0, 0, 3, 5, 7]
adas_05_9 = [0, 0, 1, 4, 5, 6, 6, 7, 7, 7, 7]
adas_05_95 = []
adas_05_97 = [0, 0, 0, 2, 4, 4, 4, 4, 4, 6, 8]
mile ... | 44.235294 | 108 | 0.571809 | 346 | 1,504 | 2.361272 | 0.124277 | 0.063647 | 0.05508 | 0.159119 | 0.700122 | 0.603427 | 0.572827 | 0.46022 | 0.318237 | 0.19339 | 0 | 0.217774 | 0.169548 | 1,504 | 33 | 109 | 45.575758 | 0.436349 | 0.242686 | 0 | 0 | 0 | 0 | 0.183348 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.086957 | 0 | 0.086957 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
c02010efda9ce4c421135232fa4f140efb168b1f | 969 | py | Python | carbon0/carbon_quiz/migrations/0010_auto_20200909_0853.py | Carbon0-Games/carbon0-web-app | 068a7223b2717d602944ec561adcde39930cba85 | [
"MIT"
] | 2 | 2020-10-30T15:07:28.000Z | 2020-12-22T04:29:50.000Z | carbon0/carbon_quiz/migrations/0010_auto_20200909_0853.py | Carbon0-Games/carbon0-web-app | 068a7223b2717d602944ec561adcde39930cba85 | [
"MIT"
] | 45 | 2020-09-22T12:47:55.000Z | 2022-03-12T00:48:18.000Z | carbon0/carbon_quiz/migrations/0010_auto_20200909_0853.py | Carbon0-Games/carbon0-web-app | 068a7223b2717d602944ec561adcde39930cba85 | [
"MIT"
] | 1 | 2020-09-08T15:48:13.000Z | 2020-09-08T15:48:13.000Z | # Generated by Django 3.1.1 on 2020-09-09 12:53
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
("carbon_quiz", "0009_auto_20200908_2201"),
]
operations = [
migrations.RemoveField(
model_name="mission",
name="descr... | 25.5 | 79 | 0.522188 | 91 | 969 | 5.428571 | 0.626374 | 0.072874 | 0.129555 | 0.161943 | 0.319838 | 0.319838 | 0 | 0 | 0 | 0 | 0 | 0.057851 | 0.375645 | 969 | 37 | 80 | 26.189189 | 0.758678 | 0.04644 | 0 | 0.451613 | 1 | 0 | 0.18872 | 0.024946 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.032258 | 0 | 0.129032 | 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 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
c03b78905f8ecc14f0212e38dfa62f635acd9408 | 59,338 | py | Python | msgraph-cli-extensions/v1_0/sites_v1_0/azext_sites_v1_0/vendored_sdks/sites/models/_sites_enums.py | thewahome/msgraph-cli | 33127d9efa23a0e5f5303c93242fbdbb73348671 | [
"MIT"
] | null | null | null | msgraph-cli-extensions/v1_0/sites_v1_0/azext_sites_v1_0/vendored_sdks/sites/models/_sites_enums.py | thewahome/msgraph-cli | 33127d9efa23a0e5f5303c93242fbdbb73348671 | [
"MIT"
] | null | null | null | msgraph-cli-extensions/v1_0/sites_v1_0/azext_sites_v1_0/vendored_sdks/sites/models/_sites_enums.py | thewahome/msgraph-cli | 33127d9efa23a0e5f5303c93242fbdbb73348671 | [
"MIT"
] | null | null | null | # coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may ... | 30.259052 | 119 | 0.701945 | 5,592 | 59,338 | 7.164342 | 0.146102 | 0.044455 | 0.122208 | 0.132391 | 0.708609 | 0.656042 | 0.652597 | 0.622894 | 0.622894 | 0.613658 | 0 | 0.005631 | 0.200883 | 59,338 | 1,960 | 120 | 30.27449 | 0.839259 | 0.012134 | 0 | 0.717534 | 0 | 0 | 0.260326 | 0.017041 | 0 | 0 | 0 | 0 | 0 | 1 | 0.001197 | false | 0.000598 | 0.002394 | 0.000598 | 0.999402 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
c03be9166bd151ec0d6a3cb24a69aeb0b4160c8e | 456 | py | Python | evntbus/decorators.py | jmwri/eventbus | fe91ab2486b99bffb0232c23d45d0c5dedce1b42 | [
"MIT"
] | null | null | null | evntbus/decorators.py | jmwri/eventbus | fe91ab2486b99bffb0232c23d45d0c5dedce1b42 | [
"MIT"
] | null | null | null | evntbus/decorators.py | jmwri/eventbus | fe91ab2486b99bffb0232c23d45d0c5dedce1b42 | [
"MIT"
] | null | null | null | import typing
if typing.TYPE_CHECKING:
from evntbus.bus import Bus
def listen_decorator(evntbus: 'Bus'):
class ListenDecorator(object):
def __init__(self, event: typing.Type, priority: int = 5):
self.event = event
self.priority = priority
def __call__(self, f: typing.... | 25.333333 | 66 | 0.644737 | 53 | 456 | 5.358491 | 0.45283 | 0.09507 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.002985 | 0.265351 | 456 | 17 | 67 | 26.823529 | 0.844776 | 0 | 0 | 0 | 0 | 0 | 0.006579 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.25 | false | 0 | 0.166667 | 0 | 0.666667 | 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 | 0 | 0 | 1 | 0 | 0 | 2 |
c03c898e35d62712b812e780c7c19ccba395542b | 1,481 | py | Python | src/shortcircuit/model/crestprocessor.py | farshield/shortcircu | 87d45ea85b78e3e7da72b7b44755dc429b4fdf5a | [
"MIT"
] | 35 | 2016-06-22T20:07:31.000Z | 2021-04-07T11:02:08.000Z | src/shortcircuit/model/crestprocessor.py | farshield/shortcircu | 87d45ea85b78e3e7da72b7b44755dc429b4fdf5a | [
"MIT"
] | 15 | 2016-06-17T09:36:02.000Z | 2020-10-30T11:39:07.000Z | src/shortcircuit/model/crestprocessor.py | farshield/shortcircu | 87d45ea85b78e3e7da72b7b44755dc429b4fdf5a | [
"MIT"
] | 16 | 2016-10-02T16:09:18.000Z | 2021-05-29T02:51:14.000Z | # crestprocessor.py
import threading
from PySide import QtCore
from crest.crest import Crest
class CrestProcessor(QtCore.QObject):
"""
CREST Middle-ware
"""
login_response = QtCore.Signal(str)
logout_response = QtCore.Signal()
location_response = QtCore.Signal(str)
destination_response = ... | 29.62 | 107 | 0.704929 | 179 | 1,481 | 5.52514 | 0.251397 | 0.072801 | 0.08089 | 0.046512 | 0.271992 | 0.215369 | 0.091001 | 0.091001 | 0 | 0 | 0 | 0 | 0.197839 | 1,481 | 49 | 108 | 30.22449 | 0.832492 | 0.024308 | 0 | 0.121212 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.272727 | false | 0 | 0.090909 | 0.030303 | 0.545455 | 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 | 0 | 0 | 1 | 0 | 0 | 2 |
c04b151e636326dee485fc70fa9e09aa52af0717 | 2,319 | py | Python | OpenGLWrapper_JE/venv/Lib/site-packages/OpenGL/raw/GL/NV/geometry_program4.py | JE-Chen/je_old_repo | a8b2f1ac2eec25758bd15b71c64b59b27e0bcda5 | [
"MIT"
] | null | null | null | OpenGLWrapper_JE/venv/Lib/site-packages/OpenGL/raw/GL/NV/geometry_program4.py | JE-Chen/je_old_repo | a8b2f1ac2eec25758bd15b71c64b59b27e0bcda5 | [
"MIT"
] | null | null | null | OpenGLWrapper_JE/venv/Lib/site-packages/OpenGL/raw/GL/NV/geometry_program4.py | JE-Chen/je_old_repo | a8b2f1ac2eec25758bd15b71c64b59b27e0bcda5 | [
"MIT"
] | null | null | null | '''Autogenerated by xml_generate script, do not edit!'''
from OpenGL import platform as _p, arrays
# Code generation uses this
from OpenGL.raw.GL import _types as _cs
# End users want this...
from OpenGL.raw.GL._types import *
from OpenGL.raw.GL import _errors
from OpenGL.constant import Constant as _C
import... | 55.214286 | 118 | 0.850367 | 355 | 2,319 | 4.991549 | 0.278873 | 0.027088 | 0.044018 | 0.038375 | 0.564334 | 0.327878 | 0.168736 | 0.091986 | 0.077878 | 0.077878 | 0 | 0.026087 | 0.057784 | 2,319 | 41 | 119 | 56.560976 | 0.784897 | 0.043122 | 0 | 0.108108 | 1 | 0 | 0.256564 | 0.256564 | 0 | 0 | 0.044219 | 0 | 0 | 1 | 0.135135 | false | 0.108108 | 0.162162 | 0.027027 | 0.324324 | 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 | 1 | 0 | 0 | 0 | 0 | 0 | 2 |
c0556573b1b396000e337b73f3de0c54b4d2d005 | 374 | py | Python | src/viewer/abs/forms.py | ozacas/asxtrade | a3645ae526bfc7a546fdf2a39520feda99e3390a | [
"Apache-2.0"
] | 8 | 2021-03-20T13:12:25.000Z | 2022-02-07T11:17:40.000Z | src/viewer/abs/forms.py | ozacas/asxtrade | a3645ae526bfc7a546fdf2a39520feda99e3390a | [
"Apache-2.0"
] | 8 | 2021-03-07T03:23:46.000Z | 2021-06-01T10:49:56.000Z | src/viewer/abs/forms.py | ozacas/asxtrade | a3645ae526bfc7a546fdf2a39520feda99e3390a | [
"Apache-2.0"
] | 3 | 2020-12-08T10:22:23.000Z | 2021-08-04T01:59:24.000Z | from django import forms
from django.core.exceptions import ValidationError
from abs.models import dataflows
class ABSDataflowForm(forms.Form):
dataflow = forms.ChoiceField(choices=(), required=True)
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
self.fields["dataflow"... | 31.166667 | 83 | 0.71123 | 47 | 374 | 5.468085 | 0.638298 | 0.077821 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.157754 | 374 | 11 | 84 | 34 | 0.815873 | 0 | 0 | 0 | 0 | 0 | 0.02139 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.125 | false | 0 | 0.375 | 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 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 2 |
c058a47a9fcf9cced343a8955317d5594bcf17a7 | 734 | py | Python | pkgs/sdk-pkg/src/genie/libs/sdk/apis/iosxe/dot1x/clear.py | patrickboertje/genielibs | 61c37aacf3dd0f499944555e4ff940f92f53dacb | [
"Apache-2.0"
] | 1 | 2022-01-16T10:00:24.000Z | 2022-01-16T10:00:24.000Z | pkgs/sdk-pkg/src/genie/libs/sdk/apis/iosxe/dot1x/clear.py | patrickboertje/genielibs | 61c37aacf3dd0f499944555e4ff940f92f53dacb | [
"Apache-2.0"
] | null | null | null | pkgs/sdk-pkg/src/genie/libs/sdk/apis/iosxe/dot1x/clear.py | patrickboertje/genielibs | 61c37aacf3dd0f499944555e4ff940f92f53dacb | [
"Apache-2.0"
] | null | null | null | # Python
import logging
# Unicon
from unicon.core.errors import SubCommandFailure
# Logger
log = logging.getLogger(__name__)
def clear_access_session_intf(device, intf):
""" clear access-session interface {}
Args:
device (`obj`): Device object
intf('str'): Name of the interface ... | 24.466667 | 83 | 0.622616 | 78 | 734 | 5.769231 | 0.525641 | 0.122222 | 0.2 | 0.18 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.284741 | 734 | 29 | 84 | 25.310345 | 0.857143 | 0.280654 | 0 | 0 | 0 | 0 | 0.231441 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.090909 | false | 0 | 0.181818 | 0 | 0.272727 | 0 | 0 | 0 | 0 | null | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
c063c02a86fbd38bc9d19422a9222b6d2583e226 | 252 | py | Python | example/func_doc.py | tinashime/Python27 | b632918c7368a9bcfc5af8353e136247d954fb5e | [
"bzip2-1.0.6"
] | null | null | null | example/func_doc.py | tinashime/Python27 | b632918c7368a9bcfc5af8353e136247d954fb5e | [
"bzip2-1.0.6"
] | null | null | null | example/func_doc.py | tinashime/Python27 | b632918c7368a9bcfc5af8353e136247d954fb5e | [
"bzip2-1.0.6"
] | null | null | null | def printMax(x,y):
'''prints the maximum of two numbers.
The two values must be integers.'''
x = int(x)
y = int(y)
if x > y:
print x,'is maximun'
else:
print y,'is maximum'
printMax(3,5)
print printMax.__doc__
| 18 | 41 | 0.575397 | 40 | 252 | 3.525 | 0.575 | 0.042553 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.011364 | 0.301587 | 252 | 13 | 42 | 19.384615 | 0.789773 | 0 | 0 | 0 | 0 | 0 | 0.114943 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0 | null | null | 0.555556 | 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 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 2 |
fbe3b3f30ddf6f664ac393236c6cc50652de4531 | 9,893 | py | Python | argparser.py | geoff-smith/MCplotscripts | 16dd5fd849671bb082a71f08492676be876209d3 | [
"MIT"
] | null | null | null | argparser.py | geoff-smith/MCplotscripts | 16dd5fd849671bb082a71f08492676be876209d3 | [
"MIT"
] | null | null | null | argparser.py | geoff-smith/MCplotscripts | 16dd5fd849671bb082a71f08492676be876209d3 | [
"MIT"
] | null | null | null | # argParser
# this class generates a RunParams object from the args passed to the script
from runparams import *
import os.path
import string
## handles args passed to the program
#
class ArgParser(object):
def parsePtCutString(self, ptCutString):
return map(float, string.split(ptCutString,',') )
de... | 39.730924 | 153 | 0.574548 | 1,091 | 9,893 | 5.206233 | 0.208066 | 0.089261 | 0.05493 | 0.065845 | 0.276056 | 0.240493 | 0.207218 | 0.147359 | 0.147359 | 0.147359 | 0 | 0.007368 | 0.27292 | 9,893 | 248 | 154 | 39.891129 | 0.782288 | 0.067725 | 0 | 0.376289 | 1 | 0.010309 | 0.342534 | 0.067159 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.015464 | null | null | 0.201031 | 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 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
fbe8a390825becc2ff9eab5332457693f2473fbc | 3,606 | py | Python | pysnmp-with-texts/IANA-MALLOC-MIB.py | agustinhenze/mibs.snmplabs.com | 1fc5c07860542b89212f4c8ab807057d9a9206c7 | [
"Apache-2.0"
] | 8 | 2019-05-09T17:04:00.000Z | 2021-06-09T06:50:51.000Z | pysnmp-with-texts/IANA-MALLOC-MIB.py | agustinhenze/mibs.snmplabs.com | 1fc5c07860542b89212f4c8ab807057d9a9206c7 | [
"Apache-2.0"
] | 4 | 2019-05-31T16:42:59.000Z | 2020-01-31T21:57:17.000Z | pysnmp-with-texts/IANA-MALLOC-MIB.py | agustinhenze/mibs.snmplabs.com | 1fc5c07860542b89212f4c8ab807057d9a9206c7 | [
"Apache-2.0"
] | 10 | 2019-04-30T05:51:36.000Z | 2022-02-16T03:33:41.000Z | #
# PySNMP MIB module IANA-MALLOC-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/IANA-MALLOC-MIB
# Produced by pysmi-0.3.4 at Wed May 1 13:50:25 2019
# On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4
# Using Python version 3.7.3 (default, Mar 27... | 100.166667 | 537 | 0.781475 | 400 | 3,606 | 7.0375 | 0.495 | 0.049023 | 0.0373 | 0.060391 | 0.329663 | 0.259325 | 0.259325 | 0.218828 | 0.189698 | 0.189698 | 0 | 0.053428 | 0.102052 | 3,606 | 35 | 538 | 103.028571 | 0.815936 | 0.08985 | 0 | 0.08 | 0 | 0.08 | 0.423159 | 0.019859 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.24 | 0 | 0.64 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 2 |
fbf29fa665c3f19650fb43d520ce03961090f743 | 7,007 | py | Python | ovs/extensions/hypervisor/hypervisors/vmware.py | mflu/openvstorage_centos | 280a98d3e5d212d58297e0ffcecd325dfecef0f8 | [
"Apache-2.0"
] | 1 | 2015-08-29T16:36:40.000Z | 2015-08-29T16:36:40.000Z | ovs/extensions/hypervisor/hypervisors/vmware.py | rootfs-analytics/openvstorage | 6184822340faea1d2927643330a7aaa781d92d36 | [
"Apache-2.0"
] | null | null | null | ovs/extensions/hypervisor/hypervisors/vmware.py | rootfs-analytics/openvstorage | 6184822340faea1d2927643330a7aaa781d92d36 | [
"Apache-2.0"
] | null | null | null | # Copyright 2014 CloudFounders NV
#
# 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 writ... | 34.860697 | 123 | 0.628942 | 856 | 7,007 | 5.004673 | 0.251168 | 0.03268 | 0.01634 | 0.022176 | 0.347806 | 0.314426 | 0.289916 | 0.234127 | 0.226891 | 0.179272 | 0 | 0.00218 | 0.280006 | 7,007 | 200 | 124 | 35.035 | 0.846977 | 0.330241 | 0 | 0.210526 | 0 | 0 | 0.045298 | 0.006155 | 0 | 0 | 0 | 0 | 0 | 1 | 0.276316 | false | 0.026316 | 0.026316 | 0 | 0.605263 | 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 | 0 | 0 | 1 | 0 | 0 | 2 |
fbf4c0c322e799620006a7ec56b567282c3ba0ca | 226 | py | Python | checkTicTacToe/checkTicTacToe.py | nate-ar-williams/coding-questions | 24baa901a786e6e2c4e8ea823a26416bc51e1f6a | [
"MIT"
] | null | null | null | checkTicTacToe/checkTicTacToe.py | nate-ar-williams/coding-questions | 24baa901a786e6e2c4e8ea823a26416bc51e1f6a | [
"MIT"
] | null | null | null | checkTicTacToe/checkTicTacToe.py | nate-ar-williams/coding-questions | 24baa901a786e6e2c4e8ea823a26416bc51e1f6a | [
"MIT"
] | null | null | null | #!/usr/bin/python3
# let board be 3x3 bool array
def isWin(board):
start = board[0][0]
win = False
next = [(0, 1), (1, 1), (1, 0)]
while(!win):
while
return win
def main():
pass
if __name__ == '__main__':
main()
| 12.555556 | 32 | 0.588496 | 37 | 226 | 3.378378 | 0.621622 | 0.048 | 0.048 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.0625 | 0.221239 | 226 | 17 | 33 | 13.294118 | 0.647727 | 0.199115 | 0 | 0 | 0 | 0 | 0.044693 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0.090909 | 0 | null | null | 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 | 1 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 2 |
fbf52c7f3a9bab66d56f2bccbaf8974ecb5420d3 | 2,138 | py | Python | openerp/exceptions.py | ntiufalara/openerp7 | 903800da0644ec0dd9c1dcd34205541f84d45fe4 | [
"MIT"
] | 3 | 2016-01-29T14:39:49.000Z | 2018-12-29T22:42:00.000Z | openerp/exceptions.py | ntiufalara/openerp7 | 903800da0644ec0dd9c1dcd34205541f84d45fe4 | [
"MIT"
] | 2 | 2016-03-23T14:29:41.000Z | 2017-02-20T17:11:30.000Z | openerp/exceptions.py | ntiufalara/openerp7 | 903800da0644ec0dd9c1dcd34205541f84d45fe4 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2011 OpenERP s.a. (<http://openerp.com>).
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the G... | 37.508772 | 78 | 0.658092 | 273 | 2,138 | 5.106227 | 0.578755 | 0.023673 | 0.025825 | 0.04089 | 0.071736 | 0.071736 | 0.04878 | 0 | 0 | 0 | 0 | 0.005199 | 0.190365 | 2,138 | 56 | 79 | 38.178571 | 0.800116 | 0.713751 | 0 | 0 | 0 | 0 | 0.036269 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.181818 | false | 0.090909 | 0 | 0 | 0.545455 | 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 | 0 | 1 | 0 | 0 | 1 | 0 | 0 | 2 |
fbfb4b2b18ec51f6264b25bae8ef574c623943f4 | 810 | py | Python | utils/utilsFreq.py | geobook2015/magPy | af0f31fc931786ac6f8d69a5290366418035859d | [
"Apache-2.0"
] | 1 | 2021-05-19T18:29:15.000Z | 2021-05-19T18:29:15.000Z | utils/utilsFreq.py | geobook2015/magPy | af0f31fc931786ac6f8d69a5290366418035859d | [
"Apache-2.0"
] | null | null | null | utils/utilsFreq.py | geobook2015/magPy | af0f31fc931786ac6f8d69a5290366418035859d | [
"Apache-2.0"
] | 2 | 2021-06-03T01:59:02.000Z | 2021-07-03T07:47:10.000Z | # utility functions for frequency related stuff
import numpy as np
import numpy.fft as fft
import math
def getFrequencyArray(fs, samples):
# frequencies go from to nyquist
nyquist = fs/2
return np.linspace(0, nyquist, samples)
# use this function for all FFT calculations
# then if change FFT later (i.e. FFTW), j... | 27.931034 | 65 | 0.728395 | 127 | 810 | 4.645669 | 0.488189 | 0.061017 | 0.040678 | 0.047458 | 0.222034 | 0.222034 | 0.152542 | 0.152542 | 0.152542 | 0.152542 | 0 | 0.016012 | 0.151852 | 810 | 28 | 66 | 28.928571 | 0.842795 | 0.228395 | 0 | 0.111111 | 0 | 0 | 0.042071 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.222222 | false | 0 | 0.166667 | 0 | 0.722222 | 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 | 0 | 0 | 1 | 0 | 0 | 2 |
fbff951b3453445a7ed046dfadb09ce047c59a21 | 1,766 | py | Python | authentik/stages/password/migrations/0007_app_password.py | BeryJu/passbook | 350f0d836580f4411524614f361a76c4f27b8a2d | [
"MIT"
] | 15 | 2020-01-05T09:09:57.000Z | 2020-11-28T05:27:39.000Z | authentik/stages/password/migrations/0007_app_password.py | BeryJu/passbook | 350f0d836580f4411524614f361a76c4f27b8a2d | [
"MIT"
] | 302 | 2020-01-21T08:03:59.000Z | 2020-12-04T05:04:57.000Z | authentik/stages/password/migrations/0007_app_password.py | BeryJu/passbook | 350f0d836580f4411524614f361a76c4f27b8a2d | [
"MIT"
] | 3 | 2020-03-04T08:21:59.000Z | 2020-08-01T20:37:18.000Z | # Generated by Django 3.2.6 on 2021-08-23 14:34
import django.contrib.postgres.fields
from django.apps.registry import Apps
from django.db import migrations, models
from django.db.backends.base.schema import BaseDatabaseSchemaEditor
from authentik.stages.password import BACKEND_APP_PASSWORD, BACKEND_INBUILT
def upda... | 36.040816 | 100 | 0.625708 | 169 | 1,766 | 6.402367 | 0.52071 | 0.027726 | 0.063771 | 0.049908 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.015008 | 0.283126 | 1,766 | 48 | 101 | 36.791667 | 0.839652 | 0.025481 | 0 | 0.102564 | 1 | 0 | 0.225713 | 0.123328 | 0 | 0 | 0 | 0 | 0 | 1 | 0.025641 | false | 0.25641 | 0.128205 | 0 | 0.25641 | 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 | 1 | 0 | 0 | 0 | 0 | 0 | 2 |
220378f315f7e2f7d8cd6b8b856c000fc8a490f5 | 12,933 | py | Python | 2020/day11.py | asmeurer/advent-of-code | 3ba3edb0c29994487f1b3344383dc41dfea9bfcb | [
"MIT"
] | null | null | null | 2020/day11.py | asmeurer/advent-of-code | 3ba3edb0c29994487f1b3344383dc41dfea9bfcb | [
"MIT"
] | null | null | null | 2020/day11.py | asmeurer/advent-of-code | 3ba3edb0c29994487f1b3344383dc41dfea9bfcb | [
"MIT"
] | null | null | null | test_input = """
L.LL.LL.LL
LLLLLLL.LL
L.L.L..L..
LLLL.LL.LL
L.LL.LL.LL
L.LLLLL.LL
..L.L.....
LLLLLLLLLL
L.LLLLLL.L
L.LLLLL.LL
"""
test_input2 = """
.......#.
...#.....
.#.......
.........
..#L....#
....#....
.........
#........
...#.....
"""
test_input3 = """
.............
.L.L.#.#.#.#.
.............
"""
test_input... | 45.861702 | 91 | 0.718163 | 1,657 | 12,933 | 5.595051 | 0.069403 | 0.018984 | 0.016179 | 0.012944 | 0.59616 | 0.507604 | 0.424442 | 0.3155 | 0.178945 | 0.123827 | 0 | 0.008788 | 0.111343 | 12,933 | 281 | 92 | 46.024911 | 0.797877 | 0 | 0 | 0.335907 | 0 | 0.189189 | 0.722647 | 0.682518 | 0 | 0 | 0 | 0 | 0.011583 | 1 | 0.030888 | false | 0 | 0.003861 | 0.003861 | 0.065637 | 0.096525 | 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 | 1 | 1 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
2206a89728beed4abfd89a30818175cab85e95be | 825 | py | Python | P20-Stack Abstract Data Type/Stack - Reverse Stack.py | necrospiritus/Python-Working-Examples | 075d410673e470fc7c4ffc262e92109a3032132f | [
"MIT"
] | null | null | null | P20-Stack Abstract Data Type/Stack - Reverse Stack.py | necrospiritus/Python-Working-Examples | 075d410673e470fc7c4ffc262e92109a3032132f | [
"MIT"
] | null | null | null | P20-Stack Abstract Data Type/Stack - Reverse Stack.py | necrospiritus/Python-Working-Examples | 075d410673e470fc7c4ffc262e92109a3032132f | [
"MIT"
] | null | null | null | """Reverse stack is using a list where the top is at the beginning instead of at the end."""
class Reverse_Stack:
def __init__(self):
self.items = []
def is_empty(self): # test to see whether the stack is empty.
return self.items == []
def push(self, item): # adds a new item to the bas... | 22.916667 | 92 | 0.632727 | 138 | 825 | 3.717391 | 0.333333 | 0.105263 | 0.087719 | 0.05848 | 0.202729 | 0.148148 | 0.148148 | 0.148148 | 0.148148 | 0 | 0 | 0.006329 | 0.233939 | 825 | 35 | 93 | 23.571429 | 0.80538 | 0.346667 | 0 | 0.25 | 0 | 0 | 0.011342 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.25 | false | 0 | 0 | 0.166667 | 0.458333 | 0.25 | 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 | 0 | 1 | 0 | 0 | 0 | 2 |
220da7c8db31ca8e3ea4491d39c1e1bb6b8b46fe | 1,018 | py | Python | examples/cam.py | jtme/button-shim | 19b80a236866fad068e6d3aeb643a1270d6ae934 | [
"MIT"
] | null | null | null | examples/cam.py | jtme/button-shim | 19b80a236866fad068e6d3aeb643a1270d6ae934 | [
"MIT"
] | null | null | null | examples/cam.py | jtme/button-shim | 19b80a236866fad068e6d3aeb643a1270d6ae934 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
import signal
import buttonshim
print("""
Button SHIM: rainbow.py
Command on button press.
Press Ctrl+C to exit.
""")
import commands
@buttonshim.on_press(buttonshim.BUTTON_A)
def button_a(button, pressed):
buttonshim.set_pixel(0x94, 0x00, 0xd3)
s=commands.getstatusoutput("ra... | 19.960784 | 74 | 0.681729 | 142 | 1,018 | 4.746479 | 0.373239 | 0.089021 | 0.126113 | 0.200297 | 0.522255 | 0.329377 | 0.121662 | 0 | 0 | 0 | 0 | 0.055012 | 0.196464 | 1,018 | 50 | 75 | 20.36 | 0.768949 | 0 | 0 | 0 | 0 | 0 | 0.129388 | 0 | 0 | 0 | 0.060181 | 0 | 0 | 0 | null | null | 0 | 0.1 | null | null | 0.066667 | 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 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
2221af1a0ee8e71a36084e82816e4e484658018d | 1,245 | py | Python | api/voters/tests/test_models.py | citizenlabsgr/voter-engagement | 2d33eac1531471988543c6c3781b95ac73ec6dd9 | [
"MIT"
] | 6 | 2017-11-10T00:50:17.000Z | 2018-03-25T02:26:19.000Z | api/voters/tests/test_models.py | citizenlabsgr/voter-engagement | 2d33eac1531471988543c6c3781b95ac73ec6dd9 | [
"MIT"
] | 40 | 2017-10-25T16:16:55.000Z | 2018-08-15T05:27:36.000Z | api/voters/tests/test_models.py | citizenlabsgr/voter-engagement | 2d33eac1531471988543c6c3781b95ac73ec6dd9 | [
"MIT"
] | 3 | 2017-11-22T01:50:41.000Z | 2018-04-17T23:33:08.000Z | # pylint: disable=unused-variable,unused-argument,expression-not-assigned
from django.forms.models import model_to_dict
import arrow
import pytest
from expecter import expect
from api.elections.models import Election
from .. import models
@pytest.fixture
def info():
return models.Identity(
first_name=... | 18.863636 | 73 | 0.658635 | 157 | 1,245 | 5.012739 | 0.356688 | 0.09784 | 0.060991 | 0.038119 | 0.162643 | 0.162643 | 0.162643 | 0.096569 | 0.096569 | 0 | 0 | 0.012526 | 0.230522 | 1,245 | 65 | 74 | 19.153846 | 0.808977 | 0.057028 | 0 | 0.175 | 0 | 0 | 0.072526 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.35 | false | 0 | 0.15 | 0.075 | 0.575 | 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 | 0 | 0 | 1 | 0 | 0 | 2 |
222b145f8daf822353fc31ee9861239abfadffb3 | 11,613 | py | Python | dotmotif/parsers/v2/test_v2_parser.py | aplbrain/dotmotif | db093ddad7308756e9cf7ee01199f0dca1369872 | [
"Apache-2.0"
] | 28 | 2020-06-12T20:46:15.000Z | 2022-02-05T18:33:46.000Z | dotmotif/parsers/v2/test_v2_parser.py | aplbrain/dotmotif | db093ddad7308756e9cf7ee01199f0dca1369872 | [
"Apache-2.0"
] | 26 | 2020-06-09T20:09:32.000Z | 2022-02-01T18:22:20.000Z | dotmotif/parsers/v2/test_v2_parser.py | aplbrain/dotmotif | db093ddad7308756e9cf7ee01199f0dca1369872 | [
"Apache-2.0"
] | 4 | 2021-03-08T02:47:49.000Z | 2021-09-13T19:16:29.000Z | from . import ParserV2
import dotmotif
import unittest
_THREE_CYCLE = """A -> B\nB -> C\nC -> A\n"""
_THREE_CYCLE_NEG = """A !> B\nB !> C\nC !> A\n"""
_THREE_CYCLE_INH = """A -| B\nB -| C\nC -| A\n"""
_THREE_CYCLE_NEG_INH = """A !| B\nB !| C\nC !| A\n"""
_ABC_TO_D = """\nA -> D\nB -> D\nC -> D\n"""
_THREE_CYCLE_CSV ... | 26.819861 | 87 | 0.490313 | 1,418 | 11,613 | 3.868829 | 0.09732 | 0.021145 | 0.082027 | 0.075465 | 0.792016 | 0.744987 | 0.704703 | 0.655669 | 0.626322 | 0.553956 | 0 | 0.013016 | 0.351675 | 11,613 | 432 | 88 | 26.881944 | 0.715633 | 0.026953 | 0 | 0.634615 | 0 | 0 | 0.37372 | 0 | 0 | 0 | 0 | 0 | 0.142857 | 1 | 0.07967 | false | 0 | 0.008242 | 0 | 0.101648 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 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 | 2 |
223135074d80c82a77c3e9b47c439c7c3abe7792 | 632 | py | Python | brp/formutils.py | chop-dbhi/biorepo-portal | 7db13c40b2b9d62af43a28e4af08c2472b98fc96 | [
"BSD-2-Clause"
] | 6 | 2016-10-26T19:51:11.000Z | 2021-03-18T16:05:55.000Z | brp/formutils.py | chop-dbhi/biorepo-portal | 7db13c40b2b9d62af43a28e4af08c2472b98fc96 | [
"BSD-2-Clause"
] | 207 | 2015-09-24T17:41:37.000Z | 2021-05-18T18:14:08.000Z | brp/formutils.py | chop-dbhi/biorepo-portal | 7db13c40b2b9d62af43a28e4af08c2472b98fc96 | [
"BSD-2-Clause"
] | 8 | 2016-04-27T19:04:50.000Z | 2020-08-24T02:33:05.000Z | from django import template
from django.forms import widgets
register = template.Library()
@register.inclusion_tag('formfield.html')
def formfield(field):
widget = field.field.widget
type_ = None
if isinstance(widget, widgets.Input):
type_ = 'input'
elif isinstance(widget, widgets.Textarea):
... | 28.727273 | 62 | 0.675633 | 69 | 632 | 6.072464 | 0.42029 | 0.190931 | 0.274463 | 0.257757 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.208861 | 632 | 21 | 63 | 30.095238 | 0.838 | 0 | 0 | 0 | 0 | 0 | 0.093354 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.055556 | false | 0 | 0.111111 | 0 | 0.222222 | 0 | 0 | 0 | 0 | null | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
2237956981da3e82e0d6350f1b78b20897718d48 | 2,441 | py | Python | explicalib/distribution/multiclass_distribution.py | euranova/estimating_eces | 9bfa81dd7a39ebe069c5b11b8e7a9bf9017e9350 | [
"MIT"
] | 2 | 2021-11-30T18:44:11.000Z | 2021-11-30T18:44:19.000Z | explicalib/distribution/multiclass_distribution.py | euranova/estimating_eces | 9bfa81dd7a39ebe069c5b11b8e7a9bf9017e9350 | [
"MIT"
] | null | null | null | explicalib/distribution/multiclass_distribution.py | euranova/estimating_eces | 9bfa81dd7a39ebe069c5b11b8e7a9bf9017e9350 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
"""
@author: nicolas.posocco
"""
from abc import ABC
import numpy as np
class MulticlassDistribution(ABC):
def __init__(self):
"""
Initializes the distribution, allowing later sampling and posterior probabilities calculations.
"""
pass
def sample(sel... | 29.059524 | 116 | 0.643179 | 303 | 2,441 | 5.082508 | 0.280528 | 0.051948 | 0.035065 | 0.023377 | 0.271429 | 0.271429 | 0.271429 | 0.271429 | 0.271429 | 0.271429 | 0 | 0.003337 | 0.263417 | 2,441 | 84 | 117 | 29.059524 | 0.85317 | 0.166735 | 0 | 0.264706 | 0 | 0 | 0.261451 | 0.022645 | 0 | 0 | 0 | 0 | 0.323529 | 1 | 0.235294 | false | 0.058824 | 0.058824 | 0 | 0.441176 | 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 | 0 | 0 | 0 | 0 | 2 |
22574ae53ea97f421f17d51078183bbb695cb068 | 566 | py | Python | middleware/login_required.py | ahmetelgun/flask-boilerplate | 56bc0235b5f00a7aaca6a9536a1744442863b8b6 | [
"Apache-2.0"
] | 2 | 2021-12-01T20:48:44.000Z | 2022-02-04T16:33:33.000Z | middleware/login_required.py | ahmetelgun/flask_authentication_boilerplate | 56bc0235b5f00a7aaca6a9536a1744442863b8b6 | [
"Apache-2.0"
] | null | null | null | middleware/login_required.py | ahmetelgun/flask_authentication_boilerplate | 56bc0235b5f00a7aaca6a9536a1744442863b8b6 | [
"Apache-2.0"
] | null | null | null | from flask import request, make_response, jsonify, g
from datetime import datetime
from functools import wraps
import jwt
from models import DBContext, User
from settings import SECRET_KEY
from service import is_token_valid
def login_required(func):
@wraps(func)
def wrapper(*args, **kwargs):
not_auth... | 22.64 | 52 | 0.681979 | 69 | 566 | 5.449275 | 0.507246 | 0.06383 | 0.101064 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.007042 | 0.24735 | 566 | 24 | 53 | 23.583333 | 0.875587 | 0 | 0 | 0 | 0 | 0 | 0.037102 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.111111 | false | 0 | 0.388889 | 0 | 0.666667 | 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 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 2 |
2258e4decef3126cb93f24dd49680df54adc84dc | 243 | py | Python | config/environments/__init__.py | mihail-ivanov/flask-init | 47f634f70bb8bd02db8f0a0a3a1955b08a249254 | [
"MIT"
] | null | null | null | config/environments/__init__.py | mihail-ivanov/flask-init | 47f634f70bb8bd02db8f0a0a3a1955b08a249254 | [
"MIT"
] | null | null | null | config/environments/__init__.py | mihail-ivanov/flask-init | 47f634f70bb8bd02db8f0a0a3a1955b08a249254 | [
"MIT"
] | null | null | null |
from .development import DevelopmentConfig
from .testing import TestingConfig
from .production import ProductionConfig
app_config = {
'development': DevelopmentConfig,
'testing': TestingConfig,
'production': ProductionConfig,
}
| 20.25 | 42 | 0.773663 | 20 | 243 | 9.35 | 0.5 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.152263 | 243 | 11 | 43 | 22.090909 | 0.907767 | 0 | 0 | 0 | 0 | 0 | 0.115702 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.375 | 0 | 0.375 | 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 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 2 |
225d1d06e227d6a8a3242fe225e574042e91441e | 12,591 | py | Python | troposphere/kendra.py | marinpurgar/troposphere | ec35854000ddfd5e2eecd251d5ecaf31979bd2d1 | [
"BSD-2-Clause"
] | null | null | null | troposphere/kendra.py | marinpurgar/troposphere | ec35854000ddfd5e2eecd251d5ecaf31979bd2d1 | [
"BSD-2-Clause"
] | null | null | null | troposphere/kendra.py | marinpurgar/troposphere | ec35854000ddfd5e2eecd251d5ecaf31979bd2d1 | [
"BSD-2-Clause"
] | null | null | null | # Copyright (c) 2012-2020, Mark Peek <mark@peek.org>
# All rights reserved.
#
# See LICENSE file for full license.
#
# *** Do not modify - this file is autogenerated ***
# Resource specification version: 18.6.0
from . import AWSObject
from . import AWSProperty
from . import Tags
from .validators import boolean
from .... | 30.194245 | 76 | 0.669685 | 698 | 12,591 | 12.075931 | 0.224928 | 0.074742 | 0.024795 | 0.066437 | 0.266224 | 0.230158 | 0.221734 | 0.210108 | 0.20382 | 0.16372 | 0 | 0.002133 | 0.218013 | 12,591 | 416 | 77 | 30.266827 | 0.853951 | 0.015567 | 0 | 0.370253 | 1 | 0 | 0.212158 | 0.118673 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.031646 | 0 | 0.31962 | 0 | 0 | 0 | 1 | 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 | 0 | 0 | 0 | 0 | 0 | 2 |
226749a06c765ec39cc633d7c553b9c567992420 | 811 | py | Python | q.py | Akatsuki1910/tokuron | 2f5b05dc1c1395f30e738a0d5749ac32d46e5379 | [
"MIT"
] | null | null | null | q.py | Akatsuki1910/tokuron | 2f5b05dc1c1395f30e738a0d5749ac32d46e5379 | [
"MIT"
] | null | null | null | q.py | Akatsuki1910/tokuron | 2f5b05dc1c1395f30e738a0d5749ac32d46e5379 | [
"MIT"
] | null | null | null | """ Q learning """
import numpy as np
import plot
Q = np.array(np.zeros([11, 3]))
GAMMA = 0.9
ALPHA = 0.1
def action_select(s_s):
""" action select """
return np.random.choice([i for i in range(1, 4) if i + s_s < 11])
for i in range(10000):
S_STATE = 0
while S_STATE != 10:
a_state = acti... | 21.918919 | 69 | 0.557337 | 138 | 811 | 3.007246 | 0.289855 | 0.245783 | 0.216867 | 0.115663 | 0.260241 | 0.183133 | 0.081928 | 0 | 0 | 0 | 0 | 0.061372 | 0.316893 | 811 | 36 | 70 | 22.527778 | 0.687726 | 0.030826 | 0 | 0.083333 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.041667 | false | 0 | 0.083333 | 0 | 0.166667 | 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 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
22727c318ff129b6243d715f6523dbfa7a528208 | 769 | py | Python | NFCow/malls/migrations/0001_initial.py | jojoriveraa/titulacion-NFCOW | 643f7f2cbe9c68d9343f38d12629720b12e9ce1e | [
"Apache-2.0"
] | null | null | null | NFCow/malls/migrations/0001_initial.py | jojoriveraa/titulacion-NFCOW | 643f7f2cbe9c68d9343f38d12629720b12e9ce1e | [
"Apache-2.0"
] | 11 | 2016-01-09T06:27:02.000Z | 2016-01-10T05:21:05.000Z | NFCow/malls/migrations/0001_initial.py | jojoriveraa/titulacion-NFCOW | 643f7f2cbe9c68d9343f38d12629720b12e9ce1e | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
# Generated by Django 1.9 on 2015-12-23 08:44
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='Mall',
... | 27.464286 | 87 | 0.572172 | 73 | 769 | 5.890411 | 0.684932 | 0.104651 | 0.125581 | 0.167442 | 0.188372 | 0 | 0 | 0 | 0 | 0 | 0 | 0.04428 | 0.295189 | 769 | 27 | 88 | 28.481481 | 0.749077 | 0.084525 | 0 | 0 | 1 | 0 | 0.057061 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.105263 | 0 | 0.315789 | 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 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
97d3d479f4d7bb607ee11ef3af9de4bcb2b193c7 | 12,781 | py | Python | tests/helpers/test_file.py | Centaurioun/PyFunceble | 59b809f3322118f7824195752c6015220738d4a0 | [
"Apache-2.0"
] | null | null | null | tests/helpers/test_file.py | Centaurioun/PyFunceble | 59b809f3322118f7824195752c6015220738d4a0 | [
"Apache-2.0"
] | null | null | null | tests/helpers/test_file.py | Centaurioun/PyFunceble | 59b809f3322118f7824195752c6015220738d4a0 | [
"Apache-2.0"
] | null | null | null | """
The tool to check the availability or syntax of domain, IP or URL.
::
██████╗ ██╗ ██╗███████╗██╗ ██╗███╗ ██╗ ██████╗███████╗██████╗ ██╗ ███████╗
██╔══██╗╚██╗ ██╔╝██╔════╝██║ ██║████╗ ██║██╔════╝██╔════╝██╔══██╗██║ ██╔════╝
██████╔╝ ╚████╔╝ █████╗ ██║ ██║██╔██╗ ██║██║ █████╗ █... | 26.627083 | 88 | 0.606838 | 1,461 | 12,781 | 5.415469 | 0.140999 | 0.131446 | 0.125 | 0.157609 | 0.716507 | 0.692113 | 0.67366 | 0.665571 | 0.630308 | 0.617922 | 0 | 0.004941 | 0.271575 | 12,781 | 479 | 89 | 26.682672 | 0.8029 | 0.209999 | 0 | 0.76 | 0 | 0 | 0.039042 | 0.005164 | 0 | 0 | 0 | 0 | 0.2 | 1 | 0.071111 | false | 0 | 0.026667 | 0 | 0.102222 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
97dd106f5157a62375f9741a6b7c0edb0c3a8dee | 1,240 | py | Python | tests/test_util_matrix.py | PeerHerholz/pyrsa | 994007086c59de93d86b982f1fff73fe6a8ea929 | [
"MIT"
] | 4 | 2015-08-10T18:34:21.000Z | 2018-05-15T20:43:15.000Z | tests/test_util_matrix.py | PeerHerholz/pyrsa | 994007086c59de93d86b982f1fff73fe6a8ea929 | [
"MIT"
] | null | null | null | tests/test_util_matrix.py | PeerHerholz/pyrsa | 994007086c59de93d86b982f1fff73fe6a8ea929 | [
"MIT"
] | 2 | 2018-03-26T03:02:07.000Z | 2021-11-10T21:09:48.000Z | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
test_util_matrix
@author: jdiedrichsen
"""
import unittest
import pyrsa.util as rsu
import numpy as np
class TestIndicator(unittest.TestCase):
def test_indicator(self):
a = np.array(range(0, 5))
a = np.concatenate((a, a))
X = rsu.matrix... | 24.313725 | 50 | 0.592742 | 185 | 1,240 | 3.8 | 0.264865 | 0.234708 | 0.182077 | 0.045519 | 0.59744 | 0.571835 | 0.571835 | 0.544808 | 0.544808 | 0.544808 | 0 | 0.038589 | 0.268548 | 1,240 | 50 | 51 | 24.8 | 0.736494 | 0.066935 | 0 | 0.5 | 0 | 0 | 0.006969 | 0 | 0 | 0 | 0 | 0 | 0.323529 | 1 | 0.117647 | false | 0 | 0.088235 | 0 | 0.235294 | 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 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
97efd442d5baa89669000d346b5c499ecd9f4c0b | 203 | py | Python | qtapps/skrf_qtwidgets/analyzers/analyzer_rs_zva.py | mike0164/scikit-rf | 0af25754b097ee24089ea7e0eacde426a51df563 | [
"BSD-3-Clause"
] | 379 | 2015-01-25T12:19:19.000Z | 2022-03-29T14:01:07.000Z | qtapps/skrf_qtwidgets/analyzers/analyzer_rs_zva.py | mike0164/scikit-rf | 0af25754b097ee24089ea7e0eacde426a51df563 | [
"BSD-3-Clause"
] | 456 | 2015-01-06T19:15:55.000Z | 2022-03-31T06:42:57.000Z | qtapps/skrf_qtwidgets/analyzers/analyzer_rs_zva.py | mike0164/scikit-rf | 0af25754b097ee24089ea7e0eacde426a51df563 | [
"BSD-3-Clause"
] | 211 | 2015-01-06T17:14:06.000Z | 2022-03-31T01:36:00.000Z | from skrf.vi.vna import rs_zva
class Analyzer(rs_zva.ZVA):
DEFAULT_VISA_ADDRESS = "GPIB::16::INSTR"
NAME = "Rhode & Schwartz ZVA"
NPORTS = 4
NCHANNELS = 32
SCPI_VERSION_TESTED = ''
| 20.3 | 44 | 0.665025 | 29 | 203 | 4.448276 | 0.862069 | 0.077519 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.031847 | 0.226601 | 203 | 9 | 45 | 22.555556 | 0.789809 | 0 | 0 | 0 | 0 | 0 | 0.172414 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.142857 | 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 | 0 | 0 | 0 | 0 | 0 | 2 |
97fbc7c518483b22e3bd3fb0a4313e038f0a4e05 | 508 | py | Python | nanome/_internal/_network/_commands/_serialization/_open_url.py | rramji/nanome-lib | 2806598af31cfb4bb6e16366f0b300d2ddcc9c13 | [
"MIT"
] | null | null | null | nanome/_internal/_network/_commands/_serialization/_open_url.py | rramji/nanome-lib | 2806598af31cfb4bb6e16366f0b300d2ddcc9c13 | [
"MIT"
] | null | null | null | nanome/_internal/_network/_commands/_serialization/_open_url.py | rramji/nanome-lib | 2806598af31cfb4bb6e16366f0b300d2ddcc9c13 | [
"MIT"
] | null | null | null | from nanome._internal._util._serializers import _StringSerializer
from nanome._internal._util._serializers import _TypeSerializer
class _OpenURL(_TypeSerializer):
def __init__(self):
self.string = _StringSerializer()
def version(self):
return 0
def name(self):
return "OpenURL"
... | 25.4 | 65 | 0.720472 | 53 | 508 | 6.584906 | 0.509434 | 0.057307 | 0.103152 | 0.126075 | 0.223496 | 0.223496 | 0 | 0 | 0 | 0 | 0 | 0.002463 | 0.200787 | 508 | 19 | 66 | 26.736842 | 0.857143 | 0 | 0 | 0 | 0 | 0 | 0.01378 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.384615 | false | 0 | 0.153846 | 0.153846 | 0.769231 | 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 | 0 | 1 | 0 | 0 | 0 | 2 |
97fdbd42de4debdf4f69ae07026eb489c9f50129 | 2,772 | py | Python | CorpusToolkit/ply_parser/test.py | howl-anderson/tools_for_corpus_of_people_daily | 8178d9a62c356f83723d42ced60f8269eed84861 | [
"Apache-2.0"
] | 243 | 2018-09-12T01:05:03.000Z | 2022-03-30T11:25:59.000Z | CorpusToolkit/ply_parser/test.py | nkkkyyy/tools_for_corpus_of_people_daily | 8178d9a62c356f83723d42ced60f8269eed84861 | [
"Apache-2.0"
] | 3 | 2018-10-18T10:13:07.000Z | 2020-09-10T06:34:40.000Z | CorpusToolkit/ply_parser/test.py | nkkkyyy/tools_for_corpus_of_people_daily | 8178d9a62c356f83723d42ced60f8269eed84861 | [
"Apache-2.0"
] | 56 | 2018-09-11T12:56:20.000Z | 2021-11-09T04:02:00.000Z | import logging
from CorpusToolkit.ply_parser import make_parser, lexer
logging.basicConfig(
level=logging.DEBUG,
filename="parselog.txt",
filemode="w",
format="%(filename)10s:%(lineno)4d:%(message)s"
)
log = logging.getLogger()
test_data = (
"19980101-01-001-002/m 中共中央/nt 总书记/n 、/wu 国家/n 主席/... | 72.947368 | 1,579 | 0.533911 | 703 | 2,772 | 2.095306 | 0.41394 | 0.05499 | 0.027155 | 0.014257 | 0.033944 | 0.033944 | 0.020367 | 0.020367 | 0 | 0 | 0 | 0.040609 | 0.289322 | 2,772 | 37 | 1,580 | 74.918919 | 0.707107 | 0.00469 | 0 | 0 | 0 | 0.142857 | 0.783098 | 0.044251 | 0 | 0 | 0 | 0 | 0 | 1 | 0.071429 | false | 0 | 0.071429 | 0 | 0.142857 | 0.071429 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
3f05ec3f00a5d7d90f5ef0232521b059bc84d999 | 672 | py | Python | src/AuShadha/registry/icd10/aushadha.py | GosthMan/AuShadha | 3ab48825a0dba19bf880b6ac6141ab7a6adf1f3e | [
"PostgreSQL"
] | 46 | 2015-03-04T14:19:47.000Z | 2021-12-09T02:58:46.000Z | src/AuShadha/registry/icd10/aushadha.py | aytida23/AuShadha | 3ab48825a0dba19bf880b6ac6141ab7a6adf1f3e | [
"PostgreSQL"
] | 2 | 2015-06-05T10:29:04.000Z | 2015-12-06T16:54:10.000Z | src/AuShadha/registry/icd10/aushadha.py | aytida23/AuShadha | 3ab48825a0dba19bf880b6ac6141ab7a6adf1f3e | [
"PostgreSQL"
] | 24 | 2015-03-23T01:38:11.000Z | 2022-01-24T16:23:42.000Z | ################################################################################
# Create a Registration with the UI for a Role.
# Each module's aushadha.py is screened for this
#
# Each Class is registered for a Role in UI
# These can be used to generate Role based UI elements later.
#
# As of now string base role... | 37.333333 | 80 | 0.577381 | 83 | 672 | 4.674699 | 0.566265 | 0.07732 | 0.041237 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.129464 | 672 | 17 | 81 | 39.529412 | 0.663248 | 0.4375 | 0 | 0 | 0 | 0 | 0.167464 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0.4 | 0 | 0.4 | 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 | 0 | 0 | 0 | 0 | 2 |
3f2894b54d3e8597c52938f696795d8309755127 | 239 | py | Python | controllers/social_auth/kivyauth/__init__.py | richierh/SalesKivyMD | f445adc701946ff38865b4a1a00a03529142613e | [
"MIT"
] | 126 | 2020-06-12T15:02:19.000Z | 2022-03-31T10:13:29.000Z | controllers/social_auth/kivyauth/__init__.py | richierh/SalesKivyMD | f445adc701946ff38865b4a1a00a03529142613e | [
"MIT"
] | 13 | 2020-07-01T01:03:26.000Z | 2022-02-21T02:21:24.000Z | controllers/social_auth/kivyauth/__init__.py | richierh/SalesKivyMD | f445adc701946ff38865b4a1a00a03529142613e | [
"MIT"
] | 22 | 2020-06-12T22:24:27.000Z | 2022-03-10T13:24:33.000Z | from kivy.logger import Logger
from kivy.utils import platform
__version__ = "2.3.2"
_log_message = "KivyAuth:" + f" {__version__}" + f' (installed at "{__file__}")'
__all__ = ("login_providers", "auto_login")
Logger.info(_log_message)
| 23.9 | 80 | 0.723849 | 32 | 239 | 4.71875 | 0.65625 | 0.10596 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.014354 | 0.125523 | 239 | 9 | 81 | 26.555556 | 0.708134 | 0 | 0 | 0 | 0 | 0 | 0.338912 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.333333 | 0 | 0.333333 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 2 |
3f3537a4e2a9c606bd390358c783d299bde031c0 | 2,125 | py | Python | ooobuild/lo/smarttags/x_range_based_smart_tag_recognizer.py | Amourspirit/ooo_uno_tmpl | 64e0c86fd68f24794acc22d63d8d32ae05dd12b8 | [
"Apache-2.0"
] | null | null | null | ooobuild/lo/smarttags/x_range_based_smart_tag_recognizer.py | Amourspirit/ooo_uno_tmpl | 64e0c86fd68f24794acc22d63d8d32ae05dd12b8 | [
"Apache-2.0"
] | null | null | null | ooobuild/lo/smarttags/x_range_based_smart_tag_recognizer.py | Amourspirit/ooo_uno_tmpl | 64e0c86fd68f24794acc22d63d8d32ae05dd12b8 | [
"Apache-2.0"
] | null | null | null | # coding: utf-8
#
# Copyright 2022 :Barry-Thomas-Paul: Moss
#
# Licensed under the Apache License, Version 2.0 (the "License")
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http: // www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicab... | 42.5 | 215 | 0.777412 | 260 | 2,125 | 6.146154 | 0.561538 | 0.037547 | 0.025031 | 0.047559 | 0.0801 | 0.0801 | 0 | 0 | 0 | 0 | 0 | 0.035912 | 0.148235 | 2,125 | 49 | 216 | 43.367347 | 0.846961 | 0.449882 | 0 | 0 | 0 | 0 | 0.23049 | 0.168784 | 0 | 0 | 0 | 0 | 0 | 1 | 0.0625 | false | 0 | 0.4375 | 0 | 0.8125 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 2 |
3f3653bf5b35e045e2b4c2aeff6f681433eea55f | 924 | py | Python | apprest/plugins/icat/views/ICAT.py | acampsm/calipsoplus-backend | b66690124bd2f2541318ddb83b18e082b5df5676 | [
"MIT"
] | 4 | 2018-12-04T15:08:27.000Z | 2019-04-11T09:49:41.000Z | apprest/plugins/icat/views/ICAT.py | acampsm/calipsoplus-backend | b66690124bd2f2541318ddb83b18e082b5df5676 | [
"MIT"
] | 63 | 2018-11-22T13:07:56.000Z | 2021-06-10T20:55:58.000Z | apprest/plugins/icat/views/ICAT.py | AlexRogalskiy/calipsoplus-backend | 3f6b034f16668bc154b0f4b759ed62b055f41647 | [
"MIT"
] | 10 | 2018-11-23T08:17:28.000Z | 2022-01-15T23:41:59.000Z | from rest_framework import status
from rest_framework.authentication import SessionAuthentication, BasicAuthentication
from rest_framework.permissions import IsAuthenticated
from rest_framework.views import APIView
from apprest.plugins.icat.helpers.complex_encoder import JsonResponse
from apprest.plugins.icat.services... | 34.222222 | 100 | 0.787879 | 96 | 924 | 7.385417 | 0.458333 | 0.045134 | 0.09591 | 0.062059 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.003802 | 0.146104 | 924 | 26 | 101 | 35.538462 | 0.894804 | 0.050866 | 0 | 0 | 0 | 0 | 0.01867 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.066667 | false | 0 | 0.4 | 0 | 0.8 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 2 |
3f3f001f639e3ff68f19c91e138db8007658913f | 998 | py | Python | py/book/ShortestSubarrayLength.py | danyfang/SourceCode | 8168f6058648f2a330a7354daf3a73a4d8a4e730 | [
"MIT"
] | null | null | null | py/book/ShortestSubarrayLength.py | danyfang/SourceCode | 8168f6058648f2a330a7354daf3a73a4d8a4e730 | [
"MIT"
] | null | null | null | py/book/ShortestSubarrayLength.py | danyfang/SourceCode | 8168f6058648f2a330a7354daf3a73a4d8a4e730 | [
"MIT"
] | null | null | null | '''
Leetcode problem No 862 Shortest Subarray with Sum at Least K
Solution written by Xuqiang Fang on 1 July, 2018
'''
import collections
class Solution(object):
def shortestSubarray(self, A, K):
"""
:type A: List[int]
:type K: int
:rtype: int
"""
n = len(A)
B... | 28.514286 | 69 | 0.490982 | 164 | 998 | 2.987805 | 0.384146 | 0.061224 | 0.22449 | 0.187755 | 0.310204 | 0.261224 | 0.159184 | 0.04898 | 0.04898 | 0.04898 | 0 | 0.081241 | 0.321643 | 998 | 34 | 70 | 29.352941 | 0.642541 | 0.156313 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.083333 | false | 0 | 0.041667 | 0 | 0.208333 | 0.208333 | 0 | 0 | 0 | null | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
3f47e5cac2344784ba9a8fd0999bd621214986ec | 669 | py | Python | DesignPatterns/FactoryPattern/SimpleFactory/autoFactory.py | Py-Himanshu-Patel/Learn-Python | 47a50a934cabcce3b1cbdd4c88141a51f21d3a05 | [
"MIT"
] | null | null | null | DesignPatterns/FactoryPattern/SimpleFactory/autoFactory.py | Py-Himanshu-Patel/Learn-Python | 47a50a934cabcce3b1cbdd4c88141a51f21d3a05 | [
"MIT"
] | null | null | null | DesignPatterns/FactoryPattern/SimpleFactory/autoFactory.py | Py-Himanshu-Patel/Learn-Python | 47a50a934cabcce3b1cbdd4c88141a51f21d3a05 | [
"MIT"
] | null | null | null | from inspect import isclass, isabstract, getmembers
import autos
def isconcrete(obj):
return isclass(obj) and not isabstract(obj)
class AutoFactory:
vehicles = {} # { car model name: class for the car}
def __init__(self):
self.load_autos()
def load_autos(self):
classes = getme... | 25.730769 | 72 | 0.647235 | 78 | 669 | 5.410256 | 0.448718 | 0.085308 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.26009 | 669 | 25 | 73 | 26.76 | 0.852525 | 0.053812 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.235294 | false | 0 | 0.117647 | 0.058824 | 0.647059 | 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 | 0 | 0 | 1 | 0 | 0 | 2 |
3f4d396e7dff26260074f0fb74d95a3f3b759b61 | 7,358 | py | Python | dlkit/json_/authentication/queries.py | UOC/dlkit | a9d265db67e81b9e0f405457464e762e2c03f769 | [
"MIT"
] | 2 | 2018-02-23T12:16:11.000Z | 2020-10-08T17:54:24.000Z | dlkit/json_/authentication/queries.py | UOC/dlkit | a9d265db67e81b9e0f405457464e762e2c03f769 | [
"MIT"
] | 87 | 2017-04-21T18:57:15.000Z | 2021-12-13T19:43:57.000Z | dlkit/json_/authentication/queries.py | UOC/dlkit | a9d265db67e81b9e0f405457464e762e2c03f769 | [
"MIT"
] | 1 | 2018-03-01T16:44:25.000Z | 2018-03-01T16:44:25.000Z | """JSON implementations of authentication queries."""
# pylint: disable=no-init
# Numerous classes don't require __init__.
# pylint: disable=too-many-public-methods,too-few-public-methods
# Number of methods are defined in specification
# pylint: disable=protected-access
# Access to protected methods allow... | 36.425743 | 98 | 0.671786 | 838 | 7,358 | 5.706444 | 0.196897 | 0.025094 | 0.035132 | 0.040151 | 0.503555 | 0.451276 | 0.338561 | 0.319741 | 0.318695 | 0.29862 | 0 | 0 | 0.231177 | 7,358 | 201 | 99 | 36.606965 | 0.845324 | 0.574477 | 0 | 0.22 | 0 | 0 | 0.038735 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.26 | false | 0 | 0.12 | 0 | 0.52 | 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 | 0 | 0 | 1 | 0 | 0 | 2 |
3f731bc8d56706afd6b8d8a2244161c707b604bd | 6,047 | py | Python | manage/fuzzytranslation.py | Acidburn0zzz/browser-update | fed7b4c52deccd582fcf8b8cca4809607bbb32cd | [
"MIT"
] | 2 | 2017-10-06T15:53:23.000Z | 2017-10-06T15:53:38.000Z | manage/fuzzytranslation.py | Acidburn0zzz/browser-update | fed7b4c52deccd582fcf8b8cca4809607bbb32cd | [
"MIT"
] | null | null | null | manage/fuzzytranslation.py | Acidburn0zzz/browser-update | fed7b4c52deccd582fcf8b8cca4809607bbb32cd | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
"""
Created on Sun Jun 12 14:21:31 2016
@author: TH
"""
#%%
import polib
#%%
#old (translated) string
#new renamed string
pairs="""
An initiative by web designers to inform users about browser-updates
An initiative by websites to inform users to update their web browser
If you are on a comput... | 29.21256 | 197 | 0.599471 | 839 | 6,047 | 4.262217 | 0.197855 | 0.089485 | 0.041946 | 0.028523 | 0.737975 | 0.727349 | 0.685682 | 0.685682 | 0.685682 | 0.685682 | 0 | 0.013072 | 0.240946 | 6,047 | 207 | 198 | 29.21256 | 0.766013 | 0.105176 | 0 | 0.693431 | 0 | 0.021898 | 0.361421 | 0.119234 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.051095 | 0 | 0.051095 | 0.094891 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
58afa3b02632f4e434958664a87781b4ca073a2a | 394 | py | Python | python/0011. maxArea.py | whtahy/leetcode | a2955123d203b155455ceefe38514fd0077d6db9 | [
"CC0-1.0"
] | 1 | 2017-12-09T05:37:51.000Z | 2017-12-09T05:37:51.000Z | python/0011. maxArea.py | whtahy/leetcode | a2955123d203b155455ceefe38514fd0077d6db9 | [
"CC0-1.0"
] | null | null | null | python/0011. maxArea.py | whtahy/leetcode | a2955123d203b155455ceefe38514fd0077d6db9 | [
"CC0-1.0"
] | null | null | null | class Solution:
def maxArea(self, ls):
n = len(ls) - 1
v, left, right = [], 0, n
while 0 <= left < right <= n:
h = min(ls[left], ls[right])
v += [h * (right - left)]
while ls[left] <= h and left < right:
left += 1
while ls[right... | 30.307692 | 50 | 0.411168 | 51 | 394 | 3.176471 | 0.372549 | 0.222222 | 0.098765 | 0.160494 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.022936 | 0.446701 | 394 | 12 | 51 | 32.833333 | 0.720183 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.083333 | false | 0 | 0 | 0 | 0.25 | 0 | 0 | 0 | 0 | null | 1 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
58b676c8df734180c643826f2bc368889a0790b4 | 2,820 | py | Python | safe/geokdbush/kdbushTest.py | s-a-f-e/backend | 6018f51466df9abd58f25729d91856842eee9509 | [
"MIT"
] | 1 | 2019-05-06T19:40:43.000Z | 2019-05-06T19:40:43.000Z | safe/geokdbush/kdbushTest.py | s-a-f-e/backend | 6018f51466df9abd58f25729d91856842eee9509 | [
"MIT"
] | 9 | 2019-12-04T22:57:46.000Z | 2022-02-10T07:15:11.000Z | safe/geokdbush/kdbushTest.py | s-a-f-e/backend | 6018f51466df9abd58f25729d91856842eee9509 | [
"MIT"
] | 3 | 2019-05-01T20:41:33.000Z | 2019-10-03T20:57:00.000Z | from kdbush import KDBush
# test data
points = [
[54,1],[97,21],[65,35],[33,54],[95,39],[54,3],[53,54],[84,72],[33,34],[43,15],[52,83],[81,23],[1,61],[38,74],
[11,91],[24,56],[90,31],[25,57],[46,61],[29,69],[49,60],[4,98],[71,15],[60,25],[38,84],[52,38],[94,51],[13,25],
[77,73],[88,87],[6,27],[58,22],[53,28... | 46.229508 | 156 | 0.537234 | 693 | 2,820 | 2.186147 | 0.194805 | 0.031683 | 0.018482 | 0.034323 | 0.168977 | 0.126733 | 0.126733 | 0.126733 | 0.052805 | 0.052805 | 0 | 0.448117 | 0.152482 | 2,820 | 60 | 157 | 47 | 0.185774 | 0.045035 | 0 | 0.204082 | 0 | 0 | 0.034957 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.020408 | false | 0 | 0.020408 | 0 | 0.061224 | 0.122449 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
58b91dc41ea5155b61915a8cc460140b8ef148b0 | 15,872 | py | Python | hansberger/analysis/migrations/0001_initial.py | 097475/hansberger | bb4ba1cbc410e7242a12f841e447b4d68f4298f6 | [
"MIT"
] | 1 | 2019-04-03T13:44:38.000Z | 2019-04-03T13:44:38.000Z | hansberger/analysis/migrations/0001_initial.py | sebastianoverdolini/hansberger | bb4ba1cbc410e7242a12f841e447b4d68f4298f6 | [
"MIT"
] | 4 | 2019-05-22T09:43:09.000Z | 2019-05-29T12:22:00.000Z | hansberger/analysis/migrations/0001_initial.py | 097475/hansberger | bb4ba1cbc410e7242a12f841e447b4d68f4298f6 | [
"MIT"
] | 2 | 2019-04-17T09:23:32.000Z | 2019-05-03T10:38:16.000Z | # Generated by Django 2.0.13 on 2019-06-27 17:04
import django.contrib.postgres.fields.jsonb
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
('research', '0001_initial'),
('datasets', '0001_init... | 99.823899 | 951 | 0.599609 | 1,635 | 15,872 | 5.715596 | 0.223242 | 0.02397 | 0.017978 | 0.02825 | 0.5832 | 0.568539 | 0.520171 | 0.498769 | 0.498769 | 0.498769 | 0 | 0.007359 | 0.27224 | 15,872 | 158 | 952 | 100.455696 | 0.801662 | 0.002898 | 0 | 0.556291 | 1 | 0.072848 | 0.474406 | 0.033114 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.019868 | 0 | 0.046358 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
58bbe52ab96a55b367459bffd53e878ab429b0e4 | 1,019 | py | Python | env/lib/python3.6/site-packages/traits/util/tests/test_import_symbol.py | Raniac/NEURO-LEARN | 3c3acc55de8ba741e673063378e6cbaf10b64c7a | [
"Apache-2.0"
] | 8 | 2019-05-29T09:38:30.000Z | 2021-01-20T03:36:59.000Z | env/lib/python3.6/site-packages/traits/util/tests/test_import_symbol.py | Raniac/neurolearn_dev | 3c3acc55de8ba741e673063378e6cbaf10b64c7a | [
"Apache-2.0"
] | 12 | 2021-03-09T03:01:16.000Z | 2022-03-11T23:59:36.000Z | env/lib/python3.6/site-packages/traits/util/tests/test_import_symbol.py | Raniac/NEURO-LEARN | 3c3acc55de8ba741e673063378e6cbaf10b64c7a | [
"Apache-2.0"
] | 1 | 2020-07-17T12:49:49.000Z | 2020-07-17T12:49:49.000Z | """ Tests for the import manager. """
from traits.util.api import import_symbol
from traits.testing.unittest_tools import unittest
class TestImportSymbol(unittest.TestCase):
""" Tests for the import manager. """
def test_import_dotted_symbol(self):
""" import dotted symbol """
import tarfi... | 22.644444 | 79 | 0.614328 | 104 | 1,019 | 5.778846 | 0.288462 | 0.139767 | 0.14975 | 0.056572 | 0.366057 | 0.169717 | 0.169717 | 0.169717 | 0 | 0 | 0 | 0 | 0.221786 | 1,019 | 44 | 80 | 23.159091 | 0.757881 | 0.129539 | 0 | 0.263158 | 0 | 0 | 0.104859 | 0.049872 | 0 | 0 | 0 | 0 | 0.157895 | 1 | 0.157895 | false | 0 | 0.631579 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 2 |
58ceaafc2d2819124d87eef37b783e73dcf0c336 | 2,358 | py | Python | HanderCode/aidaiwangApp/aidaiwangApp/Login_aidaiwangApp.py | mocne/PycharmProjects | b009e530f4f01e5b1826bbe2364d86b65bcd66e3 | [
"MIT"
] | null | null | null | HanderCode/aidaiwangApp/aidaiwangApp/Login_aidaiwangApp.py | mocne/PycharmProjects | b009e530f4f01e5b1826bbe2364d86b65bcd66e3 | [
"MIT"
] | null | null | null | HanderCode/aidaiwangApp/aidaiwangApp/Login_aidaiwangApp.py | mocne/PycharmProjects | b009e530f4f01e5b1826bbe2364d86b65bcd66e3 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
import time
import xlrd
import Register_aidaiwangApp
import LogOut_aidiawangApp
def start_to_login(filename):
print(u'login')
driver = Register_aidaiwangApp.driver
driver.launch_app()
time.sleep(3)
try:
driver.find_element_by_id('cn.phaidai.loan:id/rb_mine')
... | 33.685714 | 98 | 0.636556 | 295 | 2,358 | 4.844068 | 0.294915 | 0.090973 | 0.154654 | 0.172848 | 0.494052 | 0.460462 | 0.445066 | 0.445066 | 0.445066 | 0.419874 | 0 | 0.005025 | 0.240458 | 2,358 | 69 | 99 | 34.173913 | 0.792853 | 0.008906 | 0 | 0.275862 | 0 | 0 | 0.208137 | 0.154176 | 0 | 0 | 0 | 0 | 0 | 1 | 0.017241 | false | 0.051724 | 0.068966 | 0 | 0.137931 | 0.12069 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 2 |
58cf698a07fcbc7df1f0d9ad44c0aa4f953a79ab | 2,565 | py | Python | tests/functional/test_uploads.py | jounile/nollanet | 7bea20934d3f5e09658a9d31c3b05c15416398a0 | [
"MIT"
] | 3 | 2019-10-13T08:37:13.000Z | 2020-02-16T12:24:11.000Z | tests/functional/test_uploads.py | jounile/nollanet | 7bea20934d3f5e09658a9d31c3b05c15416398a0 | [
"MIT"
] | 5 | 2019-11-13T15:56:52.000Z | 2021-04-30T20:58:19.000Z | tests/functional/test_uploads.py | jounile/nollanet | 7bea20934d3f5e09658a9d31c3b05c15416398a0 | [
"MIT"
] | 1 | 2020-04-08T21:09:52.000Z | 2020-04-08T21:09:52.000Z | import io
import pytest
from requests import get
from urllib.parse import urljoin
def test_my_uploads_page(wait_for_api, login_user):
"""
GIVEN a user has logged in (login_user)
WHEN the '/my/uploads' page is navigated to (GET)
THEN check the response is valid and page title is correct
"""
requ... | 40.078125 | 109 | 0.71384 | 387 | 2,565 | 4.534884 | 0.217054 | 0.039886 | 0.05698 | 0.037037 | 0.745299 | 0.725356 | 0.694017 | 0.692877 | 0.692877 | 0.611396 | 0 | 0.010536 | 0.185965 | 2,565 | 64 | 110 | 40.078125 | 0.829981 | 0.451852 | 0 | 0.461538 | 0 | 0 | 0.148006 | 0.021472 | 0 | 0 | 0 | 0 | 0.307692 | 1 | 0.153846 | false | 0 | 0.153846 | 0 | 0.307692 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
58d14d425be795bfa4409700edc4323d29494ae2 | 307 | py | Python | nicegui/elements/row.py | florianwittkamp/nicegui | 4c054f4e5b82e4ac56db93b73d5fb5ffcd480d06 | [
"MIT"
] | 30 | 2021-06-16T15:46:45.000Z | 2022-03-27T03:14:18.000Z | nicegui/elements/row.py | florianwittkamp/nicegui | 4c054f4e5b82e4ac56db93b73d5fb5ffcd480d06 | [
"MIT"
] | 11 | 2021-05-24T17:05:22.000Z | 2022-02-19T07:13:18.000Z | nicegui/elements/row.py | florianwittkamp/nicegui | 4c054f4e5b82e4ac56db93b73d5fb5ffcd480d06 | [
"MIT"
] | 7 | 2021-07-22T05:51:04.000Z | 2022-01-31T19:39:37.000Z | import justpy as jp
from .group import Group
class Row(Group):
def __init__(self):
'''Row Element
Provides a container which arranges its child in a row.
'''
view = jp.QDiv(classes='row items-start', style='gap: 1em', delete_flag=False)
super().__init__(view)
| 23.615385 | 86 | 0.628664 | 42 | 307 | 4.380952 | 0.761905 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.004405 | 0.260586 | 307 | 12 | 87 | 25.583333 | 0.806167 | 0.221498 | 0 | 0 | 0 | 0 | 0.106481 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.166667 | false | 0 | 0.333333 | 0 | 0.666667 | 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 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 2 |
58d37fec96977e11aa6010c2276ce5434c4fc6f8 | 452 | py | Python | tests/guinea-pigs/unittest/expected_failure.py | Tirzono/teamcity-messages | e7f7334e2956a9e707222e4c83de9ffeb15b8ac0 | [
"Apache-2.0"
] | 105 | 2015-06-24T15:40:41.000Z | 2022-02-04T10:30:34.000Z | tests/guinea-pigs/unittest/expected_failure.py | Tirzono/teamcity-messages | e7f7334e2956a9e707222e4c83de9ffeb15b8ac0 | [
"Apache-2.0"
] | 145 | 2015-06-24T15:26:28.000Z | 2022-03-22T20:04:19.000Z | tests/guinea-pigs/unittest/expected_failure.py | Tirzono/teamcity-messages | e7f7334e2956a9e707222e4c83de9ffeb15b8ac0 | [
"Apache-2.0"
] | 76 | 2015-07-20T08:18:21.000Z | 2022-03-18T20:03:53.000Z | # coding=utf-8
import sys
from teamcity.unittestpy import TeamcityTestRunner
if sys.version_info < (2, 7):
from unittest2 import main, TestCase, expectedFailure
else:
from unittest import main, TestCase, expectedFailure
class TestSkip(TestCase):
def test_expected_failure(self):
self.fail("this sh... | 26.588235 | 66 | 0.783186 | 53 | 452 | 6.54717 | 0.622642 | 0.103746 | 0.164265 | 0.190202 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.010363 | 0.146018 | 452 | 16 | 67 | 28.25 | 0.888601 | 0.026549 | 0 | 0 | 0 | 0 | 0.073059 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.090909 | false | 0 | 0.363636 | 0 | 0.636364 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 2 |
58eeedb6cd1adb5de820dbc349b434e1a3735952 | 425 | py | Python | wrappers/Python/sbmlsolver/__init__.py | gitter-badger/sbmlsolver | c92936832297ea1d2ad7f17223b68ada43c8f0b2 | [
"Apache-2.0"
] | null | null | null | wrappers/Python/sbmlsolver/__init__.py | gitter-badger/sbmlsolver | c92936832297ea1d2ad7f17223b68ada43c8f0b2 | [
"Apache-2.0"
] | null | null | null | wrappers/Python/sbmlsolver/__init__.py | gitter-badger/sbmlsolver | c92936832297ea1d2ad7f17223b68ada43c8f0b2 | [
"Apache-2.0"
] | null | null | null | """
The LibRoadRunner SBML Simulation Engine, (c) 2009-2014 Andy Somogyi and Herbert Sauro
LibRoadRunner is an SBML JIT compiler and simulation engine with a variety of analysis
functions. LibRoadRunner is a self contained library which is designed to be integrated
into existing simulation platforms or may be used a s... | 32.692308 | 87 | 0.807059 | 60 | 425 | 5.65 | 0.75 | 0.094395 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.022284 | 0.155294 | 425 | 12 | 88 | 35.416667 | 0.922006 | 0.844706 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.5 | 0 | 0.5 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 2 |
58f0dabb24cb5744c956fc257b97c051c5d3142b | 674 | py | Python | scronsole/widgets/main_screen.py | bastianh/screeps_console_mod | e093cc1e071fae5bdf106674b97e71902fbbb6ff | [
"MIT"
] | 2 | 2017-10-08T19:39:27.000Z | 2017-10-08T19:51:18.000Z | scronsole/widgets/main_screen.py | bastianh/screeps_console_mod | e093cc1e071fae5bdf106674b97e71902fbbb6ff | [
"MIT"
] | null | null | null | scronsole/widgets/main_screen.py | bastianh/screeps_console_mod | e093cc1e071fae5bdf106674b97e71902fbbb6ff | [
"MIT"
] | null | null | null | import urwid
from scronsole.config_manager import ConfigManager
from scronsole.plugin_manager import PluginManager
from scronsole.widgets.main_menu import MainMenu
from scronsole.widgets.server_screen import ServerScreen
class MainScreen(urwid.WidgetPlaceholder):
def __init__(self):
super().__init__(urwi... | 30.636364 | 62 | 0.746291 | 79 | 674 | 6.075949 | 0.392405 | 0.108333 | 0.083333 | 0.066667 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.172107 | 674 | 21 | 63 | 32.095238 | 0.860215 | 0 | 0 | 0 | 0 | 0 | 0.001484 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.1875 | false | 0 | 0.3125 | 0 | 0.5625 | 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 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 2 |
58f1e5bfcc6007b51ace335dfbea68c9b539583f | 436 | py | Python | sql/language.py | skylarkgit/sql2java | befd55180969b0ec68e242991c3260272d755cc9 | [
"MIT"
] | 2 | 2019-10-23T08:27:30.000Z | 2019-10-23T09:58:45.000Z | sql/language.py | skylarkgit/sql2java | befd55180969b0ec68e242991c3260272d755cc9 | [
"MIT"
] | null | null | null | sql/language.py | skylarkgit/sql2java | befd55180969b0ec68e242991c3260272d755cc9 | [
"MIT"
] | null | null | null | import re
from csv import reader
def splitEscaped(str, by, escapeChar):
infile = [str]
return reader(infile, delimiter=by, quotechar=escapeChar)
def removeComments(text):
p = r'/\*[^*]*\*+([^/*][^*]*\*+)*/|("(\\.|[^"\\])*"|\'(\\.|[^\'\\])*\'|.[^/"\'\\]*)'
return ''.join(m.group(2) for m in re.finditer... | 31.142857 | 88 | 0.53211 | 55 | 436 | 4.218182 | 0.527273 | 0.051724 | 0.060345 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.007958 | 0.135321 | 436 | 13 | 89 | 33.538462 | 0.607427 | 0 | 0 | 0 | 0 | 0 | 0.174312 | 0.107798 | 0 | 0 | 0 | 0 | 0 | 1 | 0.3 | false | 0 | 0.2 | 0.1 | 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 | 0 | 0 | 0 | 1 | 0 | 0 | 2 |
58f9aedfba7b25435acbe41455b6f6873bd36f40 | 2,768 | py | Python | tests/io/v3/base/test_csv_iterator.py | alpesh-te/pyTenable | 4b5381a7757561f7ac1e79c2e2679356dd533540 | [
"MIT"
] | null | null | null | tests/io/v3/base/test_csv_iterator.py | alpesh-te/pyTenable | 4b5381a7757561f7ac1e79c2e2679356dd533540 | [
"MIT"
] | 25 | 2021-11-16T18:41:36.000Z | 2022-03-25T05:43:31.000Z | tests/io/v3/base/test_csv_iterator.py | alpesh-te/pyTenable | 4b5381a7757561f7ac1e79c2e2679356dd533540 | [
"MIT"
] | 2 | 2022-03-02T12:24:40.000Z | 2022-03-29T05:12:04.000Z | '''
Testing the CSV iterators
'''
import responses
from tenable.io.v3.base.iterators.explore_iterator import CSVChunkIterator
USERS_BASE_URL = r'https://cloud.tenable.com/api/v3/assets/search'
CSV_TEXT = (
'created,display_ipv4_address,first_observed,id,'
'ipv4_addresses,ipv6_addresses,is_deleted,is_license... | 35.948052 | 74 | 0.695087 | 400 | 2,768 | 4.6725 | 0.37 | 0.038523 | 0.070626 | 0.083467 | 0.553772 | 0.553772 | 0.52381 | 0.52381 | 0.52381 | 0.52381 | 0 | 0.18 | 0.132948 | 2,768 | 76 | 75 | 36.421053 | 0.59875 | 0.009032 | 0 | 0.21875 | 0 | 0.109375 | 0.670932 | 0.513346 | 0 | 0 | 0 | 0 | 0.03125 | 1 | 0.015625 | false | 0 | 0.03125 | 0 | 0.046875 | 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 | 1 | 1 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
4507d40889bdeb2efc06f9fd94721d09e699f4c0 | 159 | py | Python | Asignacion2/App/main.py | HarambeGeek/uip-iq-pc3 | 6e9a0678a90c4bfd7499dfb5c71c9a3ea9effe1e | [
"Apache-2.0"
] | null | null | null | Asignacion2/App/main.py | HarambeGeek/uip-iq-pc3 | 6e9a0678a90c4bfd7499dfb5c71c9a3ea9effe1e | [
"Apache-2.0"
] | null | null | null | Asignacion2/App/main.py | HarambeGeek/uip-iq-pc3 | 6e9a0678a90c4bfd7499dfb5c71c9a3ea9effe1e | [
"Apache-2.0"
] | null | null | null | from App.numeros import numeros
if __name__ == "__main__":
x = int(input("Ingrese el número que desea evaluar: \n"))
pi = numeros(x)
pi.parImpar() | 26.5 | 61 | 0.660377 | 23 | 159 | 4.217391 | 0.826087 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.207547 | 159 | 6 | 62 | 26.5 | 0.769841 | 0 | 0 | 0 | 0 | 0 | 0.29375 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.2 | 0 | 0.2 | 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 | 0 | 0 | 0 | 0 | 0 | 2 |
451a01d6bf880434d082fec4bb6d94642deb72ee | 2,195 | py | Python | moex/tests/test_service.py | ChanTerelLy/broker-account-analist | a723c83fe9a924905eb0754b4acb1231b31f9c87 | [
"MIT"
] | null | null | null | moex/tests/test_service.py | ChanTerelLy/broker-account-analist | a723c83fe9a924905eb0754b4acb1231b31f9c87 | [
"MIT"
] | 11 | 2021-02-21T19:39:41.000Z | 2021-06-13T16:29:47.000Z | moex/tests/test_service.py | ChanTerelLy/broker-account-analist | a723c83fe9a924905eb0754b4acb1231b31f9c87 | [
"MIT"
] | 2 | 2021-11-16T16:31:37.000Z | 2022-02-11T02:55:37.000Z | import asyncio
import unittest
from moex.service import Cbr, Moex
class CbrTest(unittest.TestCase):
def setUp(self) -> None:
self.cbr = Cbr('01.01.2021')
def test_usd(self):
self.assertEqual(self.cbr.USD, 73.88)
def test_euro(self):
self.assertEqual(self.cbr.EUR, 90.79)
class... | 34.296875 | 119 | 0.655125 | 279 | 2,195 | 4.956989 | 0.236559 | 0.151844 | 0.164859 | 0.173536 | 0.666667 | 0.494577 | 0.345625 | 0.293565 | 0.293565 | 0.293565 | 0 | 0.109749 | 0.182232 | 2,195 | 64 | 120 | 34.296875 | 0.660724 | 0 | 0 | 0.044444 | 0 | 0 | 0.143898 | 0 | 0 | 0 | 0 | 0 | 0.333333 | 1 | 0.266667 | false | 0 | 0.066667 | 0 | 0.377778 | 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 | 0 | 0 | 0 | 0 | 2 |
45284a1d25fe21c81004bcc320ecfac7a3fe05f4 | 907 | py | Python | src/dask_awkward/tests/test_utils.py | douglasdavis/dask-awkward | e8829d32ed080d643c7e4242036ce64aee60eda6 | [
"BSD-3-Clause"
] | 21 | 2021-09-09T19:32:30.000Z | 2022-03-01T15:42:06.000Z | src/dask_awkward/tests/test_utils.py | douglasdavis/dask-awkward | e8829d32ed080d643c7e4242036ce64aee60eda6 | [
"BSD-3-Clause"
] | 14 | 2021-09-23T16:54:10.000Z | 2022-03-23T19:24:53.000Z | src/dask_awkward/tests/test_utils.py | douglasdavis/dask-awkward | e8829d32ed080d643c7e4242036ce64aee60eda6 | [
"BSD-3-Clause"
] | 3 | 2021-09-09T19:32:32.000Z | 2021-11-18T17:27:35.000Z | from __future__ import annotations
from ..utils import normalize_single_outer_inner_index
def test_normalize_single_outer_inner_index() -> None:
divisions = (0, 12, 14, 20, 23, 24)
indices = [0, 1, 2, 8, 12, 13, 14, 15, 17, 20, 21, 22]
results = [
(0, 0),
(0, 1),
(0, 2),
(... | 22.675 | 62 | 0.46527 | 126 | 907 | 3.18254 | 0.333333 | 0.149626 | 0.199501 | 0.249377 | 0.533666 | 0.38404 | 0.38404 | 0.38404 | 0.38404 | 0.38404 | 0 | 0.138053 | 0.377067 | 907 | 39 | 63 | 23.25641 | 0.571681 | 0.01323 | 0 | 0.4 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.057143 | 1 | 0.028571 | false | 0 | 0.057143 | 0 | 0.085714 | 0 | 0 | 0 | 0 | null | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
45288cac480034ff3c670253791c5dd9e04dcb61 | 16,413 | py | Python | core/client_socket.py | schalekamp/ibapipy | a9e02d604d9f4a2ad87e78089654b29305aa110d | [
"Apache-2.0"
] | 1 | 2020-08-13T05:45:48.000Z | 2020-08-13T05:45:48.000Z | core/client_socket.py | schalekamp/ibapipy | a9e02d604d9f4a2ad87e78089654b29305aa110d | [
"Apache-2.0"
] | null | null | null | core/client_socket.py | schalekamp/ibapipy | a9e02d604d9f4a2ad87e78089654b29305aa110d | [
"Apache-2.0"
] | null | null | null | """Implements the EClientSocket interface for the Interactive Brokers API."""
import threading
import ibapipy.config as config
from ibapipy.core.network_handler import NetworkHandler
class ClientSocket:
"""Provides methods for sending requests to TWS."""
def __init__(self):
"""Initialize a new instan... | 36.718121 | 79 | 0.628709 | 1,915 | 16,413 | 5.063708 | 0.21201 | 0.021141 | 0.0297 | 0.022791 | 0.37558 | 0.27524 | 0.233165 | 0.185212 | 0.167268 | 0.15149 | 0 | 0.002772 | 0.296716 | 16,413 | 446 | 80 | 36.800448 | 0.837304 | 0.180893 | 0 | 0.315018 | 0 | 0 | 0.014527 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.227106 | false | 0.069597 | 0.010989 | 0 | 0.263736 | 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 | 0 | 0 | 0 | 0 | 2 |
4529524b72ee8b6f655a486a5542d22fd69041be | 2,234 | py | Python | common.py | shawnau/DataScienceBowl2018 | 3c6f0f26dd86b71aad55fca52314e6432d0b3a82 | [
"MIT"
] | null | null | null | common.py | shawnau/DataScienceBowl2018 | 3c6f0f26dd86b71aad55fca52314e6432d0b3a82 | [
"MIT"
] | null | null | null | common.py | shawnau/DataScienceBowl2018 | 3c6f0f26dd86b71aad55fca52314e6432d0b3a82 | [
"MIT"
] | null | null | null | import os
from datetime import datetime
PROJECT_PATH = os.path.dirname(os.path.realpath(__file__))
IDENTIFIER = datetime.now().strftime('%Y-%m-%d_%H-%M-%S')
#numerical libs
import numpy as np
import random
import matplotlib
matplotlib.use('TkAgg')
import cv2
# torch libs
import torch
from torch.utils.data.sampler... | 26.282353 | 90 | 0.723814 | 314 | 2,234 | 5.015924 | 0.366242 | 0.030476 | 0.038095 | 0.045714 | 0.107937 | 0.073651 | 0 | 0 | 0 | 0 | 0 | 0.002138 | 0.162489 | 2,234 | 84 | 91 | 26.595238 | 0.839658 | 0.049687 | 0 | 0.061538 | 0 | 0 | 0.15715 | 0.064653 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.569231 | 0 | 0.569231 | 0.184615 | 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 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 2 |
452ce291eab1e58321278df273620d4a3c795783 | 678 | py | Python | zombieclusters.py | tnkteja/notthisagain | 85e2b2cbea1298a052986e9dfe5e73d022b537f3 | [
"MIT"
] | null | null | null | zombieclusters.py | tnkteja/notthisagain | 85e2b2cbea1298a052986e9dfe5e73d022b537f3 | [
"MIT"
] | null | null | null | zombieclusters.py | tnkteja/notthisagain | 85e2b2cbea1298a052986e9dfe5e73d022b537f3 | [
"MIT"
] | null | null | null | class cluster(object):
def __init__(self,members=[]):
self.s=set(members)
def merge(self, other):
self.s.union(other.s)
return self
class clusterManager(object):
def __init__(self,clusters={}):
self.c=clusters
def merge(self, i, j):
self.c[i]=self.c[j]=self.c[i... | 26.076923 | 86 | 0.59292 | 97 | 678 | 4.061856 | 0.329897 | 0.076142 | 0.06599 | 0.086294 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.001965 | 0.249263 | 678 | 25 | 87 | 27.12 | 0.772102 | 0 | 0 | 0 | 0 | 0 | 0.001475 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.3 | false | 0 | 0 | 0.05 | 0.55 | 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 | 0 | 0 | 1 | 0 | 0 | 2 |
4538624158b0321268253bb048733d15b3730192 | 873 | py | Python | mltoolkit/mldp/utils/helpers/nlp/token_matching.py | mancunian1792/FewSum | c2f9ef0ae7445bdb188b6ceb28e998b3fd12b78e | [
"MIT"
] | 28 | 2020-10-12T19:05:22.000Z | 2022-03-18T01:19:29.000Z | mltoolkit/mldp/utils/helpers/nlp/token_matching.py | mancunian1792/FewSum | c2f9ef0ae7445bdb188b6ceb28e998b3fd12b78e | [
"MIT"
] | 1 | 2022-01-30T01:52:59.000Z | 2022-02-19T08:04:54.000Z | mltoolkit/mldp/utils/helpers/nlp/token_matching.py | mancunian1792/FewSum | c2f9ef0ae7445bdb188b6ceb28e998b3fd12b78e | [
"MIT"
] | 7 | 2020-10-29T14:01:04.000Z | 2022-02-22T18:33:10.000Z | from .constants import SPECIAL_TOKENS
try:
import re2 as re
except ImportError:
import re
def twitter_sentiment_token_matching(token):
"""Special token matching function for twitter sentiment data."""
if 'URL_TOKEN' in SPECIAL_TOKENS and re.match(r'https?:\/\/[^\s]+', token):
return SPECIAL_TO... | 41.571429 | 79 | 0.651775 | 128 | 873 | 4.21875 | 0.320313 | 0.264815 | 0.12963 | 0.185185 | 0.294444 | 0.294444 | 0.294444 | 0.294444 | 0.122222 | 0 | 0 | 0.008357 | 0.177549 | 873 | 20 | 80 | 43.65 | 0.743733 | 0.067583 | 0 | 0 | 0 | 0.058824 | 0.253713 | 0.064356 | 0 | 0 | 0 | 0 | 0 | 1 | 0.058824 | false | 0 | 0.235294 | 0 | 0.588235 | 0 | 0 | 0 | 0 | null | 1 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
1892414a440ce9963c67565a93d5515f1867c2ed | 53 | py | Python | utils/__init__.py | Rfam/rfam-production | 36f3963380da2a08e9cf73c951691c4e95738ac4 | [
"Apache-2.0"
] | 7 | 2016-06-17T09:21:11.000Z | 2021-10-13T20:25:06.000Z | utils/__init__.py | mb1069/rfam-production | 10c76e249dc22d30862b3a873fd54f390e859ad8 | [
"Apache-2.0"
] | 82 | 2016-04-08T10:51:32.000Z | 2022-03-11T13:49:18.000Z | utils/__init__.py | mb1069/rfam-production | 10c76e249dc22d30862b3a873fd54f390e859ad8 | [
"Apache-2.0"
] | 3 | 2019-09-01T09:46:35.000Z | 2021-11-29T08:01:58.000Z | __all__ = ['db_utils', 'RfamDB', 'parse_taxbrowser']
| 26.5 | 52 | 0.698113 | 6 | 53 | 5.166667 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.09434 | 53 | 1 | 53 | 53 | 0.645833 | 0 | 0 | 0 | 0 | 0 | 0.566038 | 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 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
18a994a759d85007cf88e43e5353bf80d7ac9a5c | 3,055 | py | Python | src/onegov/core/datamanager.py | politbuero-kampagnen/onegov-cloud | 20148bf321b71f617b64376fe7249b2b9b9c4aa9 | [
"MIT"
] | null | null | null | src/onegov/core/datamanager.py | politbuero-kampagnen/onegov-cloud | 20148bf321b71f617b64376fe7249b2b9b9c4aa9 | [
"MIT"
] | null | null | null | src/onegov/core/datamanager.py | politbuero-kampagnen/onegov-cloud | 20148bf321b71f617b64376fe7249b2b9b9c4aa9 | [
"MIT"
] | null | null | null | import os
import tempfile
import transaction
from onegov.core import log
from onegov.core.utils import safe_move
class MailDataManager(object):
""" Takes a postman and an envelope and sends it when the transaction
is commited.
Since we can't really know if a mail can be sent until it happens, we
sim... | 24.637097 | 73 | 0.629133 | 345 | 3,055 | 5.472464 | 0.321739 | 0.103284 | 0.070445 | 0.069915 | 0.270127 | 0.221398 | 0.169492 | 0.119703 | 0.119703 | 0.119703 | 0 | 0 | 0.285106 | 3,055 | 123 | 74 | 24.837398 | 0.864469 | 0.080196 | 0 | 0.345679 | 0 | 0 | 0.04498 | 0 | 0 | 0 | 0 | 0 | 0.012346 | 1 | 0.259259 | false | 0.098765 | 0.061728 | 0.024691 | 0.407407 | 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 | 0 | 0 | 0 | 0 | 2 |
18ad36444d5128007b08506ac3f31875adc10b4d | 127 | py | Python | books/SystemProgramming/ch4_advanced/echo_command.py | zeroam/TIL | 43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1 | [
"MIT"
] | null | null | null | books/SystemProgramming/ch4_advanced/echo_command.py | zeroam/TIL | 43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1 | [
"MIT"
] | null | null | null | books/SystemProgramming/ch4_advanced/echo_command.py | zeroam/TIL | 43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1 | [
"MIT"
] | null | null | null | from subprocess import Popen, PIPE
cmd = "echo hello world"
p = Popen(cmd, shell=True, stdout=PIPE)
ret, err = p.communicate() | 25.4 | 39 | 0.724409 | 20 | 127 | 4.6 | 0.8 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.149606 | 127 | 5 | 40 | 25.4 | 0.851852 | 0 | 0 | 0 | 0 | 0 | 0.125 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.25 | 0 | 0.25 | 0 | 1 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
18be667bef982c766e8e51b2444d4138ae324879 | 7,182 | py | Python | mojo/public/tools/bindings/pylib/parse/mojo_lexer_unittest.py | Acidburn0zzz/chromium-1 | 4c08f442d2588a2c7cfaa117a55bd87d2ac32f9a | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | null | null | null | mojo/public/tools/bindings/pylib/parse/mojo_lexer_unittest.py | Acidburn0zzz/chromium-1 | 4c08f442d2588a2c7cfaa117a55bd87d2ac32f9a | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | null | null | null | mojo/public/tools/bindings/pylib/parse/mojo_lexer_unittest.py | Acidburn0zzz/chromium-1 | 4c08f442d2588a2c7cfaa117a55bd87d2ac32f9a | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | null | null | null | # Copyright 2014 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import mojo_lexer
import unittest
# Try to load the ply module, if not, then assume it is in the third_party
# directory.
try:
# Disable lint check which ... | 44.608696 | 80 | 0.632693 | 671 | 7,182 | 6.554396 | 0.314456 | 0.145521 | 0.181901 | 0.354707 | 0.362665 | 0.047749 | 0.026376 | 0.010914 | 0.010914 | 0.010914 | 0 | 0.010864 | 0.230994 | 7,182 | 160 | 81 | 44.8875 | 0.785443 | 0.151768 | 0 | 0.033058 | 0 | 0 | 0.089102 | 0 | 0 | 0 | 0.003312 | 0 | 0.338843 | 1 | 0.066116 | false | 0 | 0.057851 | 0.008264 | 0.173554 | 0 | 0 | 0 | 0 | null | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
18ceea954bda99122d17bf7b1a926a3bf8227da9 | 270 | py | Python | Main/apps.py | Naretto95/Django-Vault | 36fac69873c844bf72732ff635513f0204b7d61a | [
"MIT"
] | null | null | null | Main/apps.py | Naretto95/Django-Vault | 36fac69873c844bf72732ff635513f0204b7d61a | [
"MIT"
] | null | null | null | Main/apps.py | Naretto95/Django-Vault | 36fac69873c844bf72732ff635513f0204b7d61a | [
"MIT"
] | null | null | null | from django.apps import AppConfig
from django.contrib.admin.apps import AdminConfig
class AdminSiteConfig(AdminConfig):
default_site = 'Main.admin.MyAdminSite'
class MainConfig(AppConfig):
default_auto_field = 'django.db.models.BigAutoField'
name = 'Main'
| 27 | 56 | 0.781481 | 32 | 270 | 6.5 | 0.65625 | 0.096154 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.12963 | 270 | 9 | 57 | 30 | 0.885106 | 0 | 0 | 0 | 0 | 0 | 0.203704 | 0.188889 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.285714 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 2 |
18dd011d855404f1d1af53f818b57ec996f325ba | 1,060 | py | Python | examples/props.py | SandNerd/notional | ccab44bc4c5d19d4546156f0d72b22b93e28e2ed | [
"MIT"
] | 23 | 2021-08-03T08:13:14.000Z | 2022-03-27T13:13:54.000Z | examples/props.py | SandNerd/notional | ccab44bc4c5d19d4546156f0d72b22b93e28e2ed | [
"MIT"
] | 15 | 2021-08-03T04:04:23.000Z | 2022-03-31T14:27:26.000Z | examples/props.py | SandNerd/notional | ccab44bc4c5d19d4546156f0d72b22b93e28e2ed | [
"MIT"
] | 3 | 2021-08-08T04:47:48.000Z | 2022-03-06T23:13:52.000Z | #!/usr/bin/env python3
"""This script demonstrates setting properties on a page manually.
The script accepts a single command line option, which is a page ID. It will then
display information about the properties and update a few of them.
Note that this script assumes the database has already been created with requ... | 25.853659 | 82 | 0.756604 | 164 | 1,060 | 4.835366 | 0.591463 | 0.045397 | 0.037831 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.003297 | 0.141509 | 1,060 | 40 | 83 | 26.5 | 0.868132 | 0.568868 | 0 | 0 | 0 | 0 | 0.150562 | 0 | 0 | 0 | 0 | 0.025 | 0 | 1 | 0 | false | 0 | 0.357143 | 0 | 0.357143 | 0.142857 | 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 | 0 | 1 | 0 | 0 | 0 | 0 | 2 |
18f75103fffe006c35337768f20ad10b43a5b636 | 411 | py | Python | hack_today_2017/web/web_time_solver.py | runsel/CTF_Writeups | df3d8469b981265d4d43bfc90e75075a95acb1dd | [
"MIT"
] | 4 | 2019-01-07T03:15:45.000Z | 2021-01-10T04:58:15.000Z | hack_today_2017/web/web_time_solver.py | runsel/CTF_Writeups | df3d8469b981265d4d43bfc90e75075a95acb1dd | [
"MIT"
] | null | null | null | hack_today_2017/web/web_time_solver.py | runsel/CTF_Writeups | df3d8469b981265d4d43bfc90e75075a95acb1dd | [
"MIT"
] | 3 | 2018-10-21T19:17:34.000Z | 2020-07-07T08:58:25.000Z | import requests
charset = "abcdefghijklmnopqrstuvwxyz0123456789_{}"
password = "HackToday{"
url = "http://sawah.ittoday.web.id:40137/"
while(password[-1]!="}"):
for i in charset:
r = requests.get(url)
payload = {'password': password+i, 'submit': 'Submit+Query'}
r = requests.post(url, data=... | 27.4 | 68 | 0.615572 | 46 | 411 | 5.456522 | 0.652174 | 0.071713 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.060317 | 0.233577 | 411 | 14 | 69 | 29.357143 | 0.736508 | 0 | 0 | 0 | 0 | 0 | 0.26764 | 0.094891 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0.416667 | 0.083333 | null | null | 0.083333 | 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 | 1 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 2 |
7a0383028d6c513dd8786b4e28fcf20c534cff1a | 341 | py | Python | CS1/Ch11/Artwork.py | DoctorOac/SwosuCsPythonExamples | 07476b9b4ef9a6f8bd68921aef19e8f00183b1e7 | [
"Apache-2.0"
] | 1 | 2022-03-28T18:27:10.000Z | 2022-03-28T18:27:10.000Z | CS1/Ch11/Artwork.py | DoctorOac/SwosuCsPythonExamples | 07476b9b4ef9a6f8bd68921aef19e8f00183b1e7 | [
"Apache-2.0"
] | 1 | 2022-01-11T16:27:40.000Z | 2022-01-11T16:27:40.000Z | CS1/Ch11/Artwork.py | DoctorOac/SwosuCsPythonExamples | 07476b9b4ef9a6f8bd68921aef19e8f00183b1e7 | [
"Apache-2.0"
] | 7 | 2022-03-25T21:01:42.000Z | 2022-03-28T18:51:24.000Z | from Artist import Artist
class Artwork:
def __init__(self, title='None', year_created=0,\
artist=Artist()):
self.title = title
self.year_created = year_created
self.artist = artist
def print_info(self):
self.artist.print_info()
print('Title: %s, %d' % (self.title,... | 26.230769 | 64 | 0.630499 | 44 | 341 | 4.659091 | 0.386364 | 0.214634 | 0.126829 | 0.195122 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.003891 | 0.246334 | 341 | 12 | 65 | 28.416667 | 0.793774 | 0 | 0 | 0 | 0 | 0 | 0.049853 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.2 | false | 0 | 0.1 | 0 | 0.4 | 0.3 | 0 | 0 | 0 | null | 1 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
7a03cb031046f0f5a4ab04de791c5d2ae9f6699d | 2,249 | py | Python | nearproteins/__init__.py | audy/nearproteins | ed426a98004c7608894a63c6b445ff60ae251d05 | [
"MIT"
] | null | null | null | nearproteins/__init__.py | audy/nearproteins | ed426a98004c7608894a63c6b445ff60ae251d05 | [
"MIT"
] | 1 | 2019-07-10T05:47:01.000Z | 2019-07-10T17:23:52.000Z | nearproteins/__init__.py | audy/nearproteins | ed426a98004c7608894a63c6b445ff60ae251d05 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
from collections import defaultdict
from itertools import product
import json
import random
import sys
from annoy import AnnoyIndex
from Bio import SeqIO
import numpy as np
class FeatureGenerator:
def __init__(self, k=2):
''' '''
self.k = k
self.alphabet = [ 'A'... | 22.267327 | 85 | 0.578924 | 300 | 2,249 | 4.273333 | 0.343333 | 0.070203 | 0.018721 | 0.058502 | 0.126365 | 0.126365 | 0 | 0 | 0 | 0 | 0 | 0.0081 | 0.286349 | 2,249 | 100 | 86 | 22.49 | 0.790654 | 0.096043 | 0 | 0.113208 | 0 | 0 | 0.023571 | 0 | 0 | 0 | 0 | 0 | 0.018868 | 1 | 0.245283 | false | 0.018868 | 0.150943 | 0.037736 | 0.54717 | 0.018868 | 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 | 0 | 0 | 1 | 0 | 0 | 2 |
7a0b7b8522bbe2e3900e18756663a43a8ac174f7 | 2,765 | py | Python | functions/print_initial_values.py | CINPLA/edNEGmodel_analysis | be8854c563376a14ee7d15e51d98d0d82be96a35 | [
"MIT"
] | null | null | null | functions/print_initial_values.py | CINPLA/edNEGmodel_analysis | be8854c563376a14ee7d15e51d98d0d82be96a35 | [
"MIT"
] | null | null | null | functions/print_initial_values.py | CINPLA/edNEGmodel_analysis | be8854c563376a14ee7d15e51d98d0d82be96a35 | [
"MIT"
] | null | null | null | import numpy as np
def print_initial_values(init_cell):
phi_sn, phi_se, phi_sg, phi_dn, phi_de, phi_dg, phi_msn, phi_mdn, phi_msg, phi_mdg = init_cell.membrane_potentials()
E_Na_sn, E_Na_sg, E_Na_dn, E_Na_dg, E_K_sn, E_K_sg, E_K_dn, E_K_dg, E_Cl_sn, E_Cl_sg, E_Cl_dn, E_Cl_dg, E_Ca_sn, E_Ca_dn = init_... | 56.428571 | 158 | 0.637975 | 525 | 2,765 | 2.939048 | 0.08381 | 0.26442 | 0.064809 | 0.075826 | 0.202204 | 0.202204 | 0.202204 | 0.139987 | 0.139987 | 0 | 0 | 0.034221 | 0.143942 | 2,765 | 48 | 159 | 57.604167 | 0.617659 | 0 | 0 | 0.136364 | 0 | 0 | 0.173599 | 0.060759 | 0 | 0 | 0 | 0 | 0 | 1 | 0.022727 | false | 0 | 0.022727 | 0 | 0.045455 | 0.795455 | 0 | 0 | 0 | null | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 2 |
7a0f470f2ade1699e468a55aa0458f89b6b1d2f2 | 17,965 | py | Python | bddtests/peer/admin_pb2.py | hacera-jonathan/fabric | 3ba291e8fbb0246aa440e02cba54d16924649479 | [
"Apache-2.0"
] | null | null | null | bddtests/peer/admin_pb2.py | hacera-jonathan/fabric | 3ba291e8fbb0246aa440e02cba54d16924649479 | [
"Apache-2.0"
] | 1 | 2021-03-20T05:34:24.000Z | 2021-03-20T05:34:24.000Z | bddtests/peer/admin_pb2.py | hacera-jonathan/fabric | 3ba291e8fbb0246aa440e02cba54d16924649479 | [
"Apache-2.0"
] | null | null | null | # Generated by the protocol buffer compiler. DO NOT EDIT!
# source: peer/admin.proto
import sys
_b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1'))
from google.protobuf import descriptor as _descriptor
from google.protobuf import message as _message
from google.protobuf import reflection as _re... | 41.77907 | 1,109 | 0.74044 | 2,018 | 17,965 | 6.364222 | 0.142716 | 0.027408 | 0.018532 | 0.021802 | 0.581017 | 0.551662 | 0.517325 | 0.469594 | 0.431441 | 0.413922 | 0 | 0.02224 | 0.151517 | 17,965 | 429 | 1,110 | 41.876457 | 0.820311 | 0.092291 | 0 | 0.494118 | 1 | 0.002941 | 0.177841 | 0.092711 | 0 | 0 | 0 | 0 | 0 | 1 | 0.055882 | false | 0.002941 | 0.038235 | 0 | 0.111765 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
e1404a753371b136c19314c274ee0f8405dd2c32 | 1,598 | py | Python | docs/example/advanced/view.py | Kozea/Pynuts | f2eb1839f59d2e8a4ec96175726186e67f85c4b0 | [
"BSD-3-Clause"
] | 1 | 2016-06-16T15:31:30.000Z | 2016-06-16T15:31:30.000Z | docs/example/advanced/view.py | Kozea/Pynuts | f2eb1839f59d2e8a4ec96175726186e67f85c4b0 | [
"BSD-3-Clause"
] | null | null | null | docs/example/advanced/view.py | Kozea/Pynuts | f2eb1839f59d2e8a4ec96175726186e67f85c4b0 | [
"BSD-3-Clause"
] | null | null | null | from wtforms import TextField, IntegerField, PasswordField
from wtforms.ext.sqlalchemy.fields import (
QuerySelectField, QuerySelectMultipleField)
from wtforms.validators import Required
from pynuts.view import BaseForm
import database
from application import nuts
class EmployeeView(nuts.ModelView):
model = ... | 35.511111 | 76 | 0.682728 | 161 | 1,598 | 6.664596 | 0.341615 | 0.037279 | 0.033551 | 0.048462 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.194618 | 1,598 | 44 | 77 | 36.318182 | 0.833722 | 0 | 0 | 0.057143 | 0 | 0 | 0.137672 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0.085714 | 0.171429 | 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 | 0 | 1 | 0 | 0 | 1 | 0 | 0 | 2 |
e1414f639d12d9584079f8b303441fd98b73dfdd | 772 | py | Python | giosgappsdk/giosg_api.py | mentholi/giosgapp-python-sdk | 2a5ea25e223dc4a88a32e917dd393cc9a07f9999 | [
"MIT"
] | null | null | null | giosgappsdk/giosg_api.py | mentholi/giosgapp-python-sdk | 2a5ea25e223dc4a88a32e917dd393cc9a07f9999 | [
"MIT"
] | null | null | null | giosgappsdk/giosg_api.py | mentholi/giosgapp-python-sdk | 2a5ea25e223dc4a88a32e917dd393cc9a07f9999 | [
"MIT"
] | null | null | null | import json
import requests
class GiosgApiMixin(object):
URL_USERS = '/api/v3/customer/personnel'
URL_CHATS = '/api/v3/chat/chatsessions'
def build_request_url(self, base, page_size=25, page=1):
domain = self.data.get('sub')
return '%s://%s%s?page_size=%s&page=%s' % (self._protocol, domai... | 38.6 | 120 | 0.700777 | 115 | 772 | 4.495652 | 0.321739 | 0.108317 | 0.087041 | 0.110251 | 0.502901 | 0.502901 | 0.502901 | 0.502901 | 0.502901 | 0.502901 | 0 | 0.017002 | 0.161917 | 772 | 19 | 121 | 40.631579 | 0.782071 | 0 | 0 | 0.142857 | 0 | 0 | 0.108808 | 0.104922 | 0 | 0 | 0 | 0 | 0 | 1 | 0.214286 | false | 0 | 0.142857 | 0 | 0.785714 | 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 | 0 | 0 | 1 | 0 | 0 | 2 |
e15f87d69b9f385338407a9fb5c01c89ecaa7425 | 2,065 | py | Python | lib/utils/timeout.py | kustodian/aerospike-admin | 931ee55ccd65ba3e20e6611a0294c92b09e8cfcb | [
"Apache-2.0"
] | null | null | null | lib/utils/timeout.py | kustodian/aerospike-admin | 931ee55ccd65ba3e20e6611a0294c92b09e8cfcb | [
"Apache-2.0"
] | null | null | null | lib/utils/timeout.py | kustodian/aerospike-admin | 931ee55ccd65ba3e20e6611a0294c92b09e8cfcb | [
"Apache-2.0"
] | null | null | null | # Copyright 2013-2018 Aerospike, Inc.
#
# 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 writ... | 29.927536 | 88 | 0.701695 | 259 | 2,065 | 5.490347 | 0.455598 | 0.042194 | 0.042194 | 0.022504 | 0.084388 | 0 | 0 | 0 | 0 | 0 | 0 | 0.009852 | 0.213559 | 2,065 | 68 | 89 | 30.367647 | 0.865764 | 0.397094 | 0 | 0.0625 | 0 | 0 | 0.036394 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.21875 | false | 0.03125 | 0.0625 | 0.03125 | 0.53125 | 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 | 0 | 0 | 1 | 0 | 0 | 2 |
e171d508606a36edd465712b9674cad13c99de99 | 1,554 | py | Python | jsConsole/__init__.py | Animenosekai/jsConsole | e2604988f20a0d0d93578f786ee7beaf72b9afbc | [
"MIT"
] | null | null | null | jsConsole/__init__.py | Animenosekai/jsConsole | e2604988f20a0d0d93578f786ee7beaf72b9afbc | [
"MIT"
] | null | null | null | jsConsole/__init__.py | Animenosekai/jsConsole | e2604988f20a0d0d93578f786ee7beaf72b9afbc | [
"MIT"
] | null | null | null | """
pyJsConsole wrapper.
© Anime no Sekai - 2020
"""
from .internal.javascript import classes as JSClass
console = JSClass._Console()
document = JSClass._Document()
history = JSClass._History()
Math = JSClass._Math()
navigator = JSClass._Navigator()
screen = JSClass._Screen()
window = JSClass._Window()
browser = JSC... | 23.19403 | 71 | 0.70592 | 161 | 1,554 | 6.68323 | 0.397516 | 0.084572 | 0.042751 | 0.053903 | 0.120818 | 0.05948 | 0 | 0 | 0 | 0 | 0 | 0.004739 | 0.185328 | 1,554 | 66 | 72 | 23.545455 | 0.844392 | 0.028958 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.333333 | false | 0 | 0.037037 | 0.259259 | 0.62963 | 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 | 0 | 1 | 0 | 0 | 0 | 2 |
e17d136893ad674b6eda0ec3efee1f8fda058d2d | 341 | py | Python | Data Analysis/csv remove other label.py | byew/python-do-differernt-csv | 094b154834ee48210c2ee4a6a529d8fe76055fb7 | [
"MIT"
] | null | null | null | Data Analysis/csv remove other label.py | byew/python-do-differernt-csv | 094b154834ee48210c2ee4a6a529d8fe76055fb7 | [
"MIT"
] | null | null | null | Data Analysis/csv remove other label.py | byew/python-do-differernt-csv | 094b154834ee48210c2ee4a6a529d8fe76055fb7 | [
"MIT"
] | null | null | null | import pandas as pd
exa = pd.read_csv('en_dup.csv')
exa.loc[exa['label'] =='F', 'label']= 0
exa.loc[exa['label'] =='T', 'label']= 1
exa.loc[exa['label'] =='U', 'label']= 2
#不读取label2, 只读取0,1标签
exa0 = exa.loc[exa["label"] == 0]
exa1 = exa.loc[exa["label"] == 1]
exa = [exa0, exa1]
exa = pd.concat(exa)
exa.to_csv('... | 17.947368 | 39 | 0.595308 | 61 | 341 | 3.278689 | 0.42623 | 0.15 | 0.225 | 0.35 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.044218 | 0.13783 | 341 | 18 | 40 | 18.944444 | 0.636054 | 0.055718 | 0 | 0 | 0 | 0 | 0.193146 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.1 | 0 | 0.1 | 0 | 0 | 0 | 0 | null | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
e18273cb48126cd36d2e98bfcd448716a51f67d4 | 396 | py | Python | axicli.py | notpeter/AxiDraw_API | d9c35eb93fd85f96cf197908415822af9a725b41 | [
"MIT"
] | null | null | null | axicli.py | notpeter/AxiDraw_API | d9c35eb93fd85f96cf197908415822af9a725b41 | [
"MIT"
] | 3 | 2021-01-17T04:31:57.000Z | 2021-01-17T04:36:41.000Z | axicli.py | notpeter/AxiDraw_API | d9c35eb93fd85f96cf197908415822af9a725b41 | [
"MIT"
] | null | null | null | '''
axicli.py - Command line interface (CLI) for AxiDraw.
For quick help:
python axicli.py --help
Full user guide:
https://axidraw.com/doc/cli_api/
This script is a stand-alone version of AxiDraw Control, accepting
various options and providing a facility for setting default values.
'''
from axicli.a... | 19.8 | 68 | 0.729798 | 57 | 396 | 4.859649 | 0.719298 | 0.108303 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.184343 | 396 | 19 | 69 | 20.842105 | 0.857585 | 0.747475 | 0 | 0 | 0 | 0 | 0.087912 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0.333333 | 0 | 0.333333 | 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 | 0 | 0 | 0 | 0 | 2 |
e18d760e51cdf1f8ab9695881861681dcd4595c4 | 214 | py | Python | silver_bullet/contain_value.py | Hojung-Jeong/Silver-Bullet-Encryption-Tool | 5ea29b3cd78cf7488e0cbdcf4ea60d7c9151c2a7 | [
"Apache-2.0"
] | null | null | null | silver_bullet/contain_value.py | Hojung-Jeong/Silver-Bullet-Encryption-Tool | 5ea29b3cd78cf7488e0cbdcf4ea60d7c9151c2a7 | [
"Apache-2.0"
] | null | null | null | silver_bullet/contain_value.py | Hojung-Jeong/Silver-Bullet-Encryption-Tool | 5ea29b3cd78cf7488e0cbdcf4ea60d7c9151c2a7 | [
"Apache-2.0"
] | null | null | null | '''
>List of functions
1. contain(value,limit) - contains a value between 0 to limit
'''
def contain(value,limit):
if value<0:
return value+limit
elif value>=limit:
return value-limit
else:
return value | 16.461538 | 62 | 0.705607 | 33 | 214 | 4.575758 | 0.515152 | 0.331126 | 0.225166 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.017143 | 0.182243 | 214 | 13 | 63 | 16.461538 | 0.845714 | 0.439252 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.142857 | false | 0 | 0 | 0 | 0.571429 | 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 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
e195971c01d6f8dcda846bd7ff1f32bb1f7099e8 | 4,248 | py | Python | src/RosGazeboLibrary/Gazebo.py | hielsnoppe/robotframework-rosgazebolibrary | a91d48413d4af95856964644b149898b538c6724 | [
"Apache-2.0"
] | null | null | null | src/RosGazeboLibrary/Gazebo.py | hielsnoppe/robotframework-rosgazebolibrary | a91d48413d4af95856964644b149898b538c6724 | [
"Apache-2.0"
] | null | null | null | src/RosGazeboLibrary/Gazebo.py | hielsnoppe/robotframework-rosgazebolibrary | a91d48413d4af95856964644b149898b538c6724 | [
"Apache-2.0"
] | null | null | null | from robot.api.deco import keyword
from robot.libraries.BuiltIn import BuiltIn
class Gazebo(object):
"""Robot Framework test library for the Gazebo simulator
See also http://gazebosim.org/tutorials/?tut=ros_comm
== Table of contents ==
%TOC%
"""
ROBOT_LIBRARY_SCOPE = 'SUITE'
def __init... | 29.296552 | 94 | 0.638889 | 488 | 4,248 | 5.297131 | 0.25 | 0.045261 | 0.042553 | 0.061896 | 0.408124 | 0.389555 | 0.37795 | 0.350484 | 0.279304 | 0.169439 | 0 | 0.001852 | 0.237524 | 4,248 | 145 | 95 | 29.296552 | 0.796233 | 0.206686 | 0 | 0.474576 | 0 | 0 | 0.170784 | 0.083049 | 0 | 0 | 0 | 0.027586 | 0 | 1 | 0.186441 | false | 0 | 0.033898 | 0.118644 | 0.423729 | 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 | 0 | 0 | 1 | 0 | 0 | 0 | 2 |
e196eb274e00b4e5d8027a1161feb36eab5a1ff6 | 1,931 | py | Python | src/MainAPP/migrations/0030_auto_20181211_1246.py | mizamae/HomeAutomation | 8c462ee4c31c1fea6792cb19af66a4d2cf7bb2ca | [
"MIT"
] | null | null | null | src/MainAPP/migrations/0030_auto_20181211_1246.py | mizamae/HomeAutomation | 8c462ee4c31c1fea6792cb19af66a4d2cf7bb2ca | [
"MIT"
] | 9 | 2017-11-21T15:45:18.000Z | 2022-02-11T03:37:54.000Z | src/MainAPP/migrations/0030_auto_20181211_1246.py | mizamae/HomeAutomation | 8c462ee4c31c1fea6792cb19af66a4d2cf7bb2ca | [
"MIT"
] | 1 | 2020-07-22T02:24:17.000Z | 2020-07-22T02:24:17.000Z | # -*- coding: utf-8 -*-
# Generated by Django 1.11.4 on 2018-12-11 11:46
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('MainAPP', '0029_auto_20181211_1237'),
]
operations = [
migrat... | 47.097561 | 252 | 0.651476 | 215 | 1,931 | 5.697674 | 0.372093 | 0.081633 | 0.102041 | 0.118367 | 0.630204 | 0.630204 | 0.556735 | 0.425306 | 0.272653 | 0.272653 | 0 | 0.029352 | 0.241326 | 1,931 | 40 | 253 | 48.275 | 0.806826 | 0.035215 | 0 | 0.454545 | 1 | 0.030303 | 0.353297 | 0.024176 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0.060606 | 0.060606 | 0 | 0.151515 | 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 | 1 | 0 | 0 | 0 | 0 | 0 | 2 |
e198e752d01863b4604a77f7225e25fec572d794 | 623 | py | Python | src/evaluators/sample_evaluators/swd_sample_evaluator.py | gmum/cwae-pytorch | 7fb31a5d12a0a637be7dde76f0e11e80ec4a345d | [
"MIT"
] | 4 | 2020-08-20T20:51:24.000Z | 2022-01-26T23:56:35.000Z | src/evaluators/sample_evaluators/swd_sample_evaluator.py | gmum/cwae-pytorch | 7fb31a5d12a0a637be7dde76f0e11e80ec4a345d | [
"MIT"
] | null | null | null | src/evaluators/sample_evaluators/swd_sample_evaluator.py | gmum/cwae-pytorch | 7fb31a5d12a0a637be7dde76f0e11e80ec4a345d | [
"MIT"
] | 1 | 2021-12-24T14:13:40.000Z | 2021-12-24T14:13:40.000Z | import torch
from metrics.swd import sliced_wasserstein_distance
from evaluators.sample_evaluators.base_sample_evaluator import BaseSampleEvaluator
from noise_creator import NoiseCreator
class SWDSampleEvaluator(BaseSampleEvaluator):
def __init__(self, noise_creator: NoiseCreator):
self.__noise_... | 38.9375 | 89 | 0.781701 | 71 | 623 | 6.478873 | 0.464789 | 0.130435 | 0.104348 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.005714 | 0.157303 | 623 | 15 | 90 | 41.533333 | 0.870476 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.181818 | false | 0 | 0.363636 | 0 | 0.727273 | 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 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 2 |
e199bdb1802d5fdf8365414f161e96d1a070a7b9 | 899 | py | Python | utils/migrations/0002_alter_electricitybilling_unit_price_and_more.py | shumwe/rental-house-management-system | f97f22afa8bc2740ed08baa387c74b93e02fac0c | [
"MIT"
] | 1 | 2022-03-16T13:29:30.000Z | 2022-03-16T13:29:30.000Z | utils/migrations/0002_alter_electricitybilling_unit_price_and_more.py | shumwe/rental-house-management-system | f97f22afa8bc2740ed08baa387c74b93e02fac0c | [
"MIT"
] | null | null | null | utils/migrations/0002_alter_electricitybilling_unit_price_and_more.py | shumwe/rental-house-management-system | f97f22afa8bc2740ed08baa387c74b93e02fac0c | [
"MIT"
] | null | null | null | # Generated by Django 4.0.3 on 2022-04-02 17:24
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('utils', '0001_initial'),
]
operations = [
migrations.AlterField(
model_name='electricitybilling',
name='unit_price',... | 31 | 130 | 0.604004 | 93 | 899 | 5.698925 | 0.569892 | 0.113208 | 0.141509 | 0.164151 | 0.215094 | 0.215094 | 0.215094 | 0.215094 | 0.215094 | 0.215094 | 0 | 0.048338 | 0.263626 | 899 | 28 | 131 | 32.107143 | 0.752266 | 0.050056 | 0 | 0.363636 | 1 | 0 | 0.170188 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.045455 | 0 | 0.181818 | 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 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
e1b62639aea1ec0a6c6d66e1d90f5f610c374034 | 4,397 | py | Python | win/GUI/Configuration.py | WeAreAVP/mdqc | 3130a713c70017bc54d8e5da6bb5766ba9d97423 | [
"Apache-2.0"
] | 8 | 2019-01-18T08:58:02.000Z | 2021-05-20T16:51:14.000Z | osx/GUI/Configuration.py | WeAreAVP/mdqc | 3130a713c70017bc54d8e5da6bb5766ba9d97423 | [
"Apache-2.0"
] | 7 | 2016-02-25T21:50:03.000Z | 2017-12-13T14:27:29.000Z | osx/GUI/Configuration.py | WeAreAVP/mdqc | 3130a713c70017bc54d8e5da6bb5766ba9d97423 | [
"Apache-2.0"
] | 2 | 2020-02-13T16:00:07.000Z | 2020-08-12T16:31:49.000Z | # -*- coding: UTF-8 -*-
'''
Created on May 14, 2014
@author: Furqan Wasi <furqan@avpreserve.com>
'''
import os, datetime, sys, platform, base64
class Configuration(object):
def __init__(self):
# Constructor
if os.name == 'posix':
self.OsType = 'linux'
elif os.name == 'nt':
... | 31.407143 | 139 | 0.596771 | 439 | 4,397 | 5.856492 | 0.289294 | 0.021004 | 0.027227 | 0.039673 | 0.181641 | 0.143913 | 0.090237 | 0.090237 | 0.090237 | 0.063788 | 0 | 0.010503 | 0.285422 | 4,397 | 140 | 140 | 31.407143 | 0.807766 | 0.04776 | 0 | 0.267442 | 0 | 0 | 0.071168 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.162791 | false | 0.081395 | 0.011628 | 0.104651 | 0.255814 | 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 | 0 | 1 | 0 | 1 | 0 | 0 | 0 | 2 |
e1bdf0a5854ba7b15ac7f77144b26d66246bcec0 | 517 | py | Python | app/urlshortener.py | felixbade/minimal-url-shortener | 4f2b4e318fff4eab2b37f863230198a5116e7a7e | [
"MIT"
] | null | null | null | app/urlshortener.py | felixbade/minimal-url-shortener | 4f2b4e318fff4eab2b37f863230198a5116e7a7e | [
"MIT"
] | null | null | null | app/urlshortener.py | felixbade/minimal-url-shortener | 4f2b4e318fff4eab2b37f863230198a5116e7a7e | [
"MIT"
] | null | null | null | class URLShortener:
def __init__(self):
self.id_counter = 0
self.links = {}
def getURL(self, short_id):
return self.links.get(short_id)
def shorten(self, url):
short_id = self.getNextId()
self.links.update({short_id: url})
return short_id
def getNextId... | 25.85 | 75 | 0.611219 | 73 | 517 | 4.164384 | 0.479452 | 0.115132 | 0.128289 | 0.111842 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.00554 | 0.301741 | 517 | 19 | 76 | 27.210526 | 0.836565 | 0.199226 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.307692 | false | 0 | 0 | 0.076923 | 0.615385 | 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 | 0 | 0 | 1 | 0 | 0 | 2 |
e1cc98556e1e617de9737efeaed139473d56ebaf | 426 | py | Python | homeworks/vecutil.py | JediKoder/coursera-CodeMatrix | 1ac461d22ebaf2777eabdcf31d76d709c33f472a | [
"MIT"
] | 3 | 2018-01-11T07:48:06.000Z | 2020-04-27T20:49:02.000Z | homeworks/vecutil.py | JediKoder/coursera-CodeMatrix | 1ac461d22ebaf2777eabdcf31d76d709c33f472a | [
"MIT"
] | null | null | null | homeworks/vecutil.py | JediKoder/coursera-CodeMatrix | 1ac461d22ebaf2777eabdcf31d76d709c33f472a | [
"MIT"
] | 1 | 2021-01-26T07:25:48.000Z | 2021-01-26T07:25:48.000Z | # Copyright 2013 Philip N. Klein
from vec import Vec
def list2vec(L):
"""Given a list L of field elements, return a Vec with domain {0...len(L)-1}
whose entry i is L[i]
>>> list2vec([10, 20, 30])
Vec({0, 1, 2},{0: 10, 1: 20, 2: 30})
"""
return Vec(set(range(len(L))), {k:L[k] for k in range(len... | 25.058824 | 80 | 0.577465 | 78 | 426 | 3.141026 | 0.525641 | 0.04898 | 0.073469 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.080495 | 0.241784 | 426 | 16 | 81 | 26.625 | 0.678019 | 0.565728 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.4 | false | 0 | 0.2 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 2 |
e1cd563f597751eb051e125f9959363e2f96050c | 397 | py | Python | users/forms.py | kurosh-wss/Personal-Finance-Management | 9c7c467b95999974492df19a0f0286809f877c87 | [
"MIT"
] | null | null | null | users/forms.py | kurosh-wss/Personal-Finance-Management | 9c7c467b95999974492df19a0f0286809f877c87 | [
"MIT"
] | null | null | null | users/forms.py | kurosh-wss/Personal-Finance-Management | 9c7c467b95999974492df19a0f0286809f877c87 | [
"MIT"
] | null | null | null | from django import forms
from django.contrib.auth.forms import UserCreationForm
from crispy_bootstrap5.bootstrap5 import FloatingField
from crispy_forms.layout import Layout
from crispy_forms.helper import FormHelper
class CustomUserCreationForm(UserCreationForm):
email = forms.EmailField()
class Meta(UserCr... | 30.538462 | 58 | 0.806045 | 44 | 397 | 7.204545 | 0.431818 | 0.094637 | 0.094637 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.00578 | 0.128463 | 397 | 12 | 59 | 33.083333 | 0.910405 | 0 | 0 | 0 | 0 | 0 | 0.012594 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.555556 | 0 | 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 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 2 |
e1d05a453d3d0e33ff80baf493eec26c3cbe59f9 | 437 | py | Python | Extra kunskap/Kod/Farmen.py | abbindustrigymnasium/Programmering-1-Slutuppgift | 679069ebb632ee59f6b4ee3035c18ae204cde145 | [
"Apache-2.0"
] | null | null | null | Extra kunskap/Kod/Farmen.py | abbindustrigymnasium/Programmering-1-Slutuppgift | 679069ebb632ee59f6b4ee3035c18ae204cde145 | [
"Apache-2.0"
] | null | null | null | Extra kunskap/Kod/Farmen.py | abbindustrigymnasium/Programmering-1-Slutuppgift | 679069ebb632ee59f6b4ee3035c18ae204cde145 | [
"Apache-2.0"
] | 1 | 2020-03-09T12:04:31.000Z | 2020-03-09T12:04:31.000Z | import openpyxl
wb= openpyxl.load_workbook('Farmen.xlsx')
# sheet= wb.active
# print(wb.get_sheet_names())
# Deltagar_sheet= wb.get_sheet_by_name('Deltagare')
# artists=[{"Namn":sheet.cell(row=i, column=2).value,
# "Sång":sheet.cell(row=i, column=3).value,
# "Poäng":sheet.cell(row=i, column=6).... | 33.615385 | 54 | 0.649886 | 67 | 437 | 4.119403 | 0.507463 | 0.130435 | 0.173913 | 0.188406 | 0.275362 | 0 | 0 | 0 | 0 | 0 | 0 | 0.013624 | 0.160183 | 437 | 13 | 55 | 33.615385 | 0.73842 | 0.79405 | 0 | 0 | 0 | 0 | 0.15942 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.5 | 0 | 0.5 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 2 |
becbc66bb4d180935eed7f6a49ea9b7ed75ae703 | 998 | py | Python | plot_loss.py | ngachago/tabular_comp | 799a1e0dbf7a51bb04454f1f14a57f883dbd2da7 | [
"MIT"
] | null | null | null | plot_loss.py | ngachago/tabular_comp | 799a1e0dbf7a51bb04454f1f14a57f883dbd2da7 | [
"MIT"
] | null | null | null | plot_loss.py | ngachago/tabular_comp | 799a1e0dbf7a51bb04454f1f14a57f883dbd2da7 | [
"MIT"
] | null | null | null |
import matplotlib.pyplot as plt
def plot_loss_mae(history):
plt.plot(history.history['loss'])
plt.plot(history.history['val_loss'])
plt.title('Model loss')
plt.ylabel('Loss')
plt.xlabel('Epoch')
plt.legend(['Train', 'Validation'], loc='best')
plt.show()
plt.plot(history.history['mae']... | 26.972973 | 51 | 0.635271 | 131 | 998 | 4.778626 | 0.175573 | 0.089457 | 0.178914 | 0.268371 | 0.763578 | 0.686901 | 0.686901 | 0.686901 | 0.686901 | 0.686901 | 0 | 0 | 0.165331 | 998 | 36 | 52 | 27.722222 | 0.751501 | 0 | 0 | 0.645161 | 0 | 0 | 0.212638 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.064516 | false | 0 | 0.032258 | 0 | 0.096774 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 |
bed4073b9e79a28ea38d1cc06f6e14cb5d4efcb7 | 777 | py | Python | __determineTripplesSumToZeroFromList.py | simdevex/01.Basics | cf4f372384e66f4b26e4887d2f5d815a1f8e929c | [
"MIT"
] | null | null | null | __determineTripplesSumToZeroFromList.py | simdevex/01.Basics | cf4f372384e66f4b26e4887d2f5d815a1f8e929c | [
"MIT"
] | null | null | null | __determineTripplesSumToZeroFromList.py | simdevex/01.Basics | cf4f372384e66f4b26e4887d2f5d815a1f8e929c | [
"MIT"
] | null | null | null | '''
Python program to determine which triples sum to zero from a given list of lists.
Input: [[1343532, -2920635, 332], [-27, 18, 9], [4, 0, -4], [2, 2, 2], [-20, 16, 4]]
Output:
[False, True, True, False, True]
Input: [[1, 2, -3], [-4, 0, 4], [0, 1, -5], [1, 1, 1], [-2, 4, -1]]
Output:
[True, True, False, False, False... | 32.375 | 84 | 0.574003 | 139 | 777 | 3.208633 | 0.33813 | 0.026906 | 0.026906 | 0.161435 | 0.565022 | 0.565022 | 0.497758 | 0.497758 | 0.497758 | 0.497758 | 0 | 0.153125 | 0.176319 | 777 | 23 | 85 | 33.782609 | 0.54375 | 0.449163 | 0 | 0.4 | 0 | 0 | 0.285714 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.1 | false | 0 | 0 | 0.1 | 0.2 | 0.6 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 2 |
bed6c276e3757d89c0d4a20b188e77bced930a94 | 701 | py | Python | fastNLP/modules/encoder/lstm.py | h00Jiang/fastNLP | 79ddb469d81946c87a3d066122a8a3aba6e40f3a | [
"Apache-2.0"
] | null | null | null | fastNLP/modules/encoder/lstm.py | h00Jiang/fastNLP | 79ddb469d81946c87a3d066122a8a3aba6e40f3a | [
"Apache-2.0"
] | null | null | null | fastNLP/modules/encoder/lstm.py | h00Jiang/fastNLP | 79ddb469d81946c87a3d066122a8a3aba6e40f3a | [
"Apache-2.0"
] | null | null | null | import torch.nn as nn
class Lstm(nn.Module):
"""
LSTM module
Args:
input_size : input size
hidden_size : hidden size
num_layers : number of hidden layers. Default: 1
dropout : dropout rate. Default: 0.5
bidirectional : If True, becomes a bidirectional RNN. Default: False.
"""
... | 29.208333 | 98 | 0.636234 | 91 | 701 | 4.692308 | 0.428571 | 0.084309 | 0.131148 | 0.133489 | 0.107728 | 0 | 0 | 0 | 0 | 0 | 0 | 0.015564 | 0.266762 | 701 | 23 | 99 | 30.478261 | 0.815175 | 0.319544 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.222222 | false | 0 | 0.111111 | 0 | 0.555556 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 2 |
bed723c002fdd1ab37526c62f785025bbbd1fbd1 | 838 | py | Python | geoLocApp/signals.py | KKWaxy/geoLoc | 23e33b9fd7cb3b1031bd11475612dcc324680975 | [
"Apache-2.0"
] | null | null | null | geoLocApp/signals.py | KKWaxy/geoLoc | 23e33b9fd7cb3b1031bd11475612dcc324680975 | [
"Apache-2.0"
] | null | null | null | geoLocApp/signals.py | KKWaxy/geoLoc | 23e33b9fd7cb3b1031bd11475612dcc324680975 | [
"Apache-2.0"
] | null | null | null | from django.db.models.signals import pre_save,post_save
from django.dispatch import receiver
import geoLocApp.models
import geoLocApp.distance
# @receiver(post_save,sender=geoLocApp.models.Position,dispatch_uid="only_before_registered")
# def setDistance(sender, **kwargs):
# position = kwargs["instance"]
... | 39.904762 | 139 | 0.72673 | 92 | 838 | 6.5 | 0.434783 | 0.040134 | 0.06689 | 0.080268 | 0.214047 | 0.214047 | 0.214047 | 0.214047 | 0.214047 | 0.214047 | 0 | 0.001418 | 0.158711 | 838 | 21 | 140 | 39.904762 | 0.846809 | 0.768496 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 1 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 | 0 | 0 | 0 | 0 | 2 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.