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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
4c741e64454909457a868627b67dab302441efd4 | 760 | py | Python | phase/jump_ge.py | ryos36/retro-for-FPGA | af26804759a98069c6af7f0e08a987b09c0ad4e3 | [
"MIT"
] | null | null | null | phase/jump_ge.py | ryos36/retro-for-FPGA | af26804759a98069c6af7f0e08a987b09c0ad4e3 | [
"MIT"
] | null | null | null | phase/jump_ge.py | ryos36/retro-for-FPGA | af26804759a98069c6af7f0e08a987b09c0ad4e3 | [
"MIT"
] | null | null | null | class JUMP_GE:
def __init__(self, stack):
self.phase = 0
self.ip = 0
self.stack = stack
self.a = 0
def exec(self, ip, data):
if (self.phase == 0):
self.ip = ip + 1
self.a = self.stack.pop()
self.phase = 1
return False
... | 25.333333 | 37 | 0.409211 | 88 | 760 | 3.477273 | 0.284091 | 0.294118 | 0.130719 | 0.091503 | 0.235294 | 0 | 0 | 0 | 0 | 0 | 0 | 0.036458 | 0.494737 | 760 | 29 | 38 | 26.206897 | 0.760417 | 0 | 0 | 0.357143 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.035714 | 1 | 0.071429 | false | 0 | 0 | 0 | 0.285714 | 0 | 0 | 0 | 0 | null | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
4c74cc9647b8aa8f29d772c6937910ee9560dccd | 591 | py | Python | tasks/migrations/0003_auto_20210813_1237.py | ichdamola/TodoList | 23b789ba2c9922a8312c3f566a39a124e7ba1cdb | [
"MIT"
] | null | null | null | tasks/migrations/0003_auto_20210813_1237.py | ichdamola/TodoList | 23b789ba2c9922a8312c3f566a39a124e7ba1cdb | [
"MIT"
] | null | null | null | tasks/migrations/0003_auto_20210813_1237.py | ichdamola/TodoList | 23b789ba2c9922a8312c3f566a39a124e7ba1cdb | [
"MIT"
] | null | null | null | # Generated by Django 2.0 on 2021-08-13 12:37
import datetime
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('tasks', '0002_auto_20210813_1230'),
]
operations = [
migrations.AddField(
model_name='project',
name='... | 23.64 | 70 | 0.602369 | 58 | 591 | 6.051724 | 0.62069 | 0.102564 | 0.131054 | 0.153846 | 0.501425 | 0.501425 | 0.2849 | 0 | 0 | 0 | 0 | 0.071259 | 0.287648 | 591 | 24 | 71 | 24.625 | 0.76247 | 0.072758 | 0 | 0.444444 | 1 | 0 | 0.102564 | 0.042125 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.111111 | 0 | 0.277778 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
4c7663218746a48954c04215a953804df631aebc | 641 | py | Python | src/midiutil/midimon.py | neonkingfr/VizBench | e41f559cb6e761d717f2f5b202482d5d8dacd2d8 | [
"MIT"
] | 7 | 2015-01-05T06:32:49.000Z | 2020-10-30T19:29:07.000Z | src/midiutil/midimon.py | neonkingfr/VizBench | e41f559cb6e761d717f2f5b202482d5d8dacd2d8 | [
"MIT"
] | null | null | null | src/midiutil/midimon.py | neonkingfr/VizBench | e41f559cb6e761d717f2f5b202482d5d8dacd2d8 | [
"MIT"
] | 4 | 2016-03-09T22:29:26.000Z | 2021-04-07T13:52:28.000Z | from nosuch.midiutil import *
from traceback import format_exc
from time import sleep
from nosuch.mididebug import *
from nosuch.midipypm import *
if __name__ == '__main__':
Midi.startup()
# m = MidiDebugHardware()
m = MidiPypmHardware()
a = m.input_devices()
for nm in a:
print "Opening input = ",nm
i = m.... | 17.805556 | 49 | 0.697348 | 89 | 641 | 4.865169 | 0.58427 | 0.069284 | 0.036952 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.003802 | 0.179407 | 641 | 35 | 50 | 18.314286 | 0.819392 | 0.035881 | 0 | 0 | 0 | 0 | 0.163961 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.2 | null | null | 0.28 | 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 | 0 | 0 | 1 |
4c7bce66ca3dccd22597ebfcfb955afc09d38a14 | 4,491 | py | Python | hard-gists/5106221/snippet.py | jjhenkel/dockerizeme | eaa4fe5366f6b9adf74399eab01c712cacaeb279 | [
"Apache-2.0"
] | 21 | 2019-07-08T08:26:45.000Z | 2022-01-24T23:53:25.000Z | hard-gists/5106221/snippet.py | jjhenkel/dockerizeme | eaa4fe5366f6b9adf74399eab01c712cacaeb279 | [
"Apache-2.0"
] | 5 | 2019-06-15T14:47:47.000Z | 2022-02-26T05:02:56.000Z | hard-gists/5106221/snippet.py | jjhenkel/dockerizeme | eaa4fe5366f6b9adf74399eab01c712cacaeb279 | [
"Apache-2.0"
] | 17 | 2019-05-16T03:50:34.000Z | 2021-01-14T14:35:12.000Z | #!/usr/bin/env python
'''
Uses SURF to match two images.
Based on the sample code from opencv:
samples/python2/find_obj.py
USAGE
find_obj.py <image1> <image2>
'''
import numpy
import cv2
import sys
###############################################################################
# Image Matching
###############... | 30.972414 | 112 | 0.505901 | 603 | 4,491 | 3.696517 | 0.266998 | 0.047106 | 0.022432 | 0.010767 | 0.195603 | 0.176761 | 0.117542 | 0.096904 | 0.096904 | 0.096904 | 0 | 0.073004 | 0.252728 | 4,491 | 145 | 113 | 30.972414 | 0.59118 | 0.06012 | 0 | 0.134831 | 0 | 0 | 0.036739 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.033708 | null | null | 0.05618 | 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 | 0 | 0 | 1 |
d5bbed6664b977a19a80eb772ebb6668db8a1515 | 517 | py | Python | doc/python_study_code/property.py | beiliwenxiao/vimrc | eb38fc769f3f5f78000060dac674b5c49d63c24c | [
"MIT"
] | null | null | null | doc/python_study_code/property.py | beiliwenxiao/vimrc | eb38fc769f3f5f78000060dac674b5c49d63c24c | [
"MIT"
] | null | null | null | doc/python_study_code/property.py | beiliwenxiao/vimrc | eb38fc769f3f5f78000060dac674b5c49d63c24c | [
"MIT"
] | null | null | null | #!/usr/bin/env python
# coding=utf-8
__metaclass__ = type
class Rectangle:
"""docstring for Rectangle"""
def __init__(self):
self.width = 0
self.height = 0
def setSize(self, size):
"""docstring for setSize"""
self.width, self.height = size
def getSize(self):
"""do... | 19.884615 | 38 | 0.62089 | 70 | 517 | 4.471429 | 0.428571 | 0.115016 | 0.083067 | 0.121406 | 0.146965 | 0 | 0 | 0 | 0 | 0 | 0 | 0.033592 | 0.251451 | 517 | 25 | 39 | 20.68 | 0.775194 | 0.06383 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0 | null | null | 0.117647 | 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 | 0 | 0 | 1 |
d5be0d6229eaeba8526bc452d7fe61844033d00d | 414 | py | Python | django_congen/backends/generic.py | night-crawler/django-congen | 6194c37c7eaf4e78ddb59c6ff43d63a59fc7734f | [
"MIT"
] | null | null | null | django_congen/backends/generic.py | night-crawler/django-congen | 6194c37c7eaf4e78ddb59c6ff43d63a59fc7734f | [
"MIT"
] | null | null | null | django_congen/backends/generic.py | night-crawler/django-congen | 6194c37c7eaf4e78ddb59c6ff43d63a59fc7734f | [
"MIT"
] | null | null | null | from django.template.loader import render_to_string
class GenericHandler(object):
template = 'django_congen/gunicorn_release.py'
pb = None
def __init__(self, path_builder_instance, template=None):
self.pb = path_builder_instance
if template:
self.template = template
def ... | 24.352941 | 61 | 0.676329 | 51 | 414 | 5.215686 | 0.509804 | 0.06015 | 0.105263 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.236715 | 414 | 16 | 62 | 25.875 | 0.841772 | 0 | 0 | 0 | 0 | 0 | 0.089372 | 0.07971 | 0 | 0 | 0 | 0 | 0 | 1 | 0.181818 | false | 0 | 0.090909 | 0 | 0.636364 | 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 | 0 | 0 | 1 | 0 | 0 | 1 |
d5c1445e2c0f15b1ba80b153fd6a0e93ef110b44 | 382 | py | Python | Medium/78. Subsets/solution (2).py | czs108/LeetCode-Solutions | 889f5b6a573769ad077a6283c058ed925d52c9ec | [
"MIT"
] | 3 | 2020-05-09T12:55:09.000Z | 2022-03-11T18:56:05.000Z | Medium/78. Subsets/solution (2).py | czs108/LeetCode-Solutions | 889f5b6a573769ad077a6283c058ed925d52c9ec | [
"MIT"
] | null | null | null | Medium/78. Subsets/solution (2).py | czs108/LeetCode-Solutions | 889f5b6a573769ad077a6283c058ed925d52c9ec | [
"MIT"
] | 1 | 2022-03-11T18:56:16.000Z | 2022-03-11T18:56:16.000Z | # 78. Subsets
# Runtime: 32 ms, faster than 85.43% of Python3 online submissions for Subsets.
# Memory Usage: 14.3 MB, less than 78.59% of Python3 online submissions for Subsets.
class Solution:
# Cascading
def subsets(self, nums: list[int]) -> list[list[int]]:
res = [[]]
for n in nums:
... | 27.285714 | 84 | 0.612565 | 56 | 382 | 4.178571 | 0.607143 | 0.076923 | 0.128205 | 0.222222 | 0.307692 | 0.307692 | 0 | 0 | 0 | 0 | 0 | 0.061372 | 0.274869 | 382 | 14 | 85 | 27.285714 | 0.783394 | 0.47644 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.166667 | false | 0 | 0 | 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 | 0 | 0 | 0 | 0 | 0 | 1 |
d5c1eef0651c31b2afdbe4464d7994278ddd6e3a | 549 | py | Python | pocs/state/states/default/parking.py | zacharyt20/POCS | 8f785eaf27178be7d72106cb82e5400a8b852ba8 | [
"MIT"
] | 1 | 2019-07-19T10:37:08.000Z | 2019-07-19T10:37:08.000Z | pocs/state/states/default/parking.py | zacharyt20/POCS | 8f785eaf27178be7d72106cb82e5400a8b852ba8 | [
"MIT"
] | null | null | null | pocs/state/states/default/parking.py | zacharyt20/POCS | 8f785eaf27178be7d72106cb82e5400a8b852ba8 | [
"MIT"
] | null | null | null | def on_enter(event_data):
""" """
pocs = event_data.model
# Clear any current observation
pocs.observatory.current_observation = None
pocs.observatory.current_offset_info = None
pocs.next_state = 'parked'
if pocs.observatory.has_dome:
pocs.say('Closing dome')
if not pocs.o... | 28.894737 | 57 | 0.661202 | 73 | 549 | 4.821918 | 0.534247 | 0.213068 | 0.09375 | 0.096591 | 0.136364 | 0.136364 | 0 | 0 | 0 | 0 | 0 | 0 | 0.227687 | 549 | 18 | 58 | 30.5 | 0.830189 | 0.052823 | 0 | 0 | 0 | 0 | 0.193738 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.083333 | false | 0 | 0 | 0 | 0.083333 | 0 | 0 | 0 | 0 | null | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
d5c25769d2633b03cbe365f00e5876b7221077bb | 17,419 | py | Python | mlonmcu/context.py | PhilippvK/mlonmcu | 6b5ed9b2abe8d3caa18c20a604547513e8097b49 | [
"Apache-2.0"
] | null | null | null | mlonmcu/context.py | PhilippvK/mlonmcu | 6b5ed9b2abe8d3caa18c20a604547513e8097b49 | [
"Apache-2.0"
] | null | null | null | mlonmcu/context.py | PhilippvK/mlonmcu | 6b5ed9b2abe8d3caa18c20a604547513e8097b49 | [
"Apache-2.0"
] | null | null | null | #
# Copyright (c) 2022 TUM Department of Electrical and Computer Engineering.
#
# This file is part of MLonMCU.
# See https://github.com/tum-ei-eda/mlonmcu.git for further info.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You m... | 36.983015 | 175 | 0.608875 | 2,107 | 17,419 | 4.933555 | 0.185572 | 0.025397 | 0.007504 | 0.007696 | 0.166138 | 0.116306 | 0.099375 | 0.08937 | 0.082828 | 0.072054 | 0 | 0.003464 | 0.303921 | 17,419 | 470 | 176 | 37.061702 | 0.853856 | 0.266031 | 0 | 0.189781 | 0 | 0 | 0.125325 | 0.002033 | 0 | 0 | 0 | 0.010638 | 0.032847 | 1 | 0.065693 | false | 0 | 0.058394 | 0 | 0.211679 | 0.040146 | 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 | 0 | 0 | 0 | 0 | 1 |
d5d24a91d9209453236647d1406484ee9fc13b9a | 1,252 | py | Python | lantz/core/__init__.py | jacobfeder/lantz-core | 09dd95d4a7be45aa1852154d07a87f75a6e2c2cb | [
"BSD-3-Clause"
] | 3 | 2019-05-04T00:10:47.000Z | 2021-06-11T15:51:14.000Z | lantz/core/__init__.py | jacobfeder/lantz-core | 09dd95d4a7be45aa1852154d07a87f75a6e2c2cb | [
"BSD-3-Clause"
] | 4 | 2019-01-08T18:30:51.000Z | 2020-09-22T03:19:05.000Z | lantz/core/__init__.py | jacobfeder/lantz-core | 09dd95d4a7be45aa1852154d07a87f75a6e2c2cb | [
"BSD-3-Clause"
] | 5 | 2019-09-23T16:26:32.000Z | 2021-07-21T19:24:38.000Z | # -*- coding: utf-8 -*-
"""
lantz.core
~~~~~~~~~~
An automation and instrumentation toolkit with a clean, well-designed and
consistent interface.
The lantz.core package provides basic definitions to build drivers, including
a Driver class and the Feat and Action decorators.
:copyright: 20... | 23.185185 | 81 | 0.720447 | 150 | 1,252 | 5.833333 | 0.546667 | 0.054857 | 0.050286 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.004869 | 0.179712 | 1,252 | 53 | 82 | 23.622642 | 0.847128 | 0.34345 | 0 | 0 | 0 | 0 | 0.081225 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.047619 | false | 0 | 0.52381 | 0 | 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 | 0 | 1 | 0 | 0 | 0 | 0 | 1 |
d5d33716b5c619026572c1fa9b2cf5ff572c6bbf | 10,573 | py | Python | python/graphs_3_time_query_len.py | mavlyutovrus/interval_index | 685254999d5af265a9802cc948929cda3b2806e7 | [
"Apache-2.0"
] | null | null | null | python/graphs_3_time_query_len.py | mavlyutovrus/interval_index | 685254999d5af265a9802cc948929cda3b2806e7 | [
"Apache-2.0"
] | null | null | null | python/graphs_3_time_query_len.py | mavlyutovrus/interval_index | 685254999d5af265a9802cc948929cda3b2806e7 | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
import matplotlib.pyplot as plt
import matplotlib
from pylab import *
import numpy
from copy_reg import remove_extension
from heapq import heappush
from mpl_toolkits.axes_grid1 import host_subplot
import mpl_toolkits.axisartist as AA
algo2index = []
def load_data(filename):
all_results = ... | 32.937695 | 151 | 0.603613 | 1,443 | 10,573 | 4.255717 | 0.189882 | 0.029963 | 0.041687 | 0.024752 | 0.467513 | 0.411497 | 0.369484 | 0.345383 | 0.307605 | 0.282202 | 0 | 0.042688 | 0.240045 | 10,573 | 320 | 152 | 33.040625 | 0.721344 | 0.064788 | 0 | 0.222222 | 0 | 0 | 0.079989 | 0.021587 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.05 | null | null | 0.027778 | 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 | 0 | 0 | 1 |
d5d92e7dbf4967cb1fce937adff6f702043833c5 | 6,495 | py | Python | schemes/longnames_autocheck.py | gold2718/ccpp-framework | 66f1a069b6b15748e08adbe940b8ceb9b39619ab | [
"Apache-2.0"
] | null | null | null | schemes/longnames_autocheck.py | gold2718/ccpp-framework | 66f1a069b6b15748e08adbe940b8ceb9b39619ab | [
"Apache-2.0"
] | 39 | 2019-01-25T21:50:33.000Z | 2021-09-03T16:57:43.000Z | schemes/longnames_autocheck.py | gold2718/ccpp-framework | 66f1a069b6b15748e08adbe940b8ceb9b39619ab | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python
# Standard modules
import os
# Local modules
from common import execute
from parse_fortran import parse_subroutine_call
from parse_scheme_table import parse_scheme_tables
from process_tables import scheme_type, subroutine_type, parse_xml_files, process_arguments, find_longname_conflicts
separa... | 38.892216 | 148 | 0.54719 | 728 | 6,495 | 4.690934 | 0.292582 | 0.026354 | 0.015227 | 0.008785 | 0.081406 | 0.061493 | 0.061493 | 0.061493 | 0.061493 | 0.061493 | 0 | 0.017924 | 0.338568 | 6,495 | 166 | 149 | 39.126506 | 0.777002 | 0.102079 | 0 | 0.090226 | 0 | 0.015038 | 0.24682 | 0.068065 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.037594 | null | null | 0.052632 | 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 | 0 | 0 | 1 |
d5dd2348df012ec68e747b0c7f0a7eb8e0455d7a | 4,110 | py | Python | loan/models.py | friskycodeur/django-authentication | 75b703c09e2b0c80c94bc3e71dd226f64d25701e | [
"MIT"
] | null | null | null | loan/models.py | friskycodeur/django-authentication | 75b703c09e2b0c80c94bc3e71dd226f64d25701e | [
"MIT"
] | null | null | null | loan/models.py | friskycodeur/django-authentication | 75b703c09e2b0c80c94bc3e71dd226f64d25701e | [
"MIT"
] | null | null | null | from django.db import models
from . import constants
# Create your models here.
class CustomerProfile(models.Model):
"""
Customer Profile Model , to be inherited by Customer Model.
"""
gender_choice_options = (("M", "Male"), ("F", "Female"), ("O", "Others"))
age = models.PositiveIntegerField()
... | 28.344828 | 83 | 0.693917 | 473 | 4,110 | 5.742072 | 0.247357 | 0.069588 | 0.112666 | 0.150221 | 0.571429 | 0.503682 | 0.409057 | 0.340943 | 0.313697 | 0.225331 | 0 | 0.01945 | 0.211922 | 4,110 | 144 | 84 | 28.541667 | 0.81908 | 0.090511 | 0 | 0.224719 | 0 | 0 | 0.012115 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.078652 | false | 0 | 0.022472 | 0.078652 | 0.696629 | 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 | 0 | 0 | 1 | 0 | 0 | 1 |
d5e198245d3ac1d367a84a972965f2c23c8ea545 | 360 | py | Python | yatube/posts/forms.py | S10dev/S10dev.ru_sources | 6d9b5e596080d9ed357e371ccf58de7c3174900b | [
"MIT"
] | null | null | null | yatube/posts/forms.py | S10dev/S10dev.ru_sources | 6d9b5e596080d9ed357e371ccf58de7c3174900b | [
"MIT"
] | null | null | null | yatube/posts/forms.py | S10dev/S10dev.ru_sources | 6d9b5e596080d9ed357e371ccf58de7c3174900b | [
"MIT"
] | null | null | null | from django.forms import ModelForm
from django import forms
from .models import Post, Comment
class PostForm(ModelForm):
class Meta:
model = Post
fields = {'group', 'text', 'image'}
class CommentForm(ModelForm):
text = forms.CharField(widget=forms.Textarea)
class Meta:
model = C... | 20 | 49 | 0.65 | 41 | 360 | 5.707317 | 0.512195 | 0.08547 | 0.119658 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.244444 | 360 | 17 | 50 | 21.176471 | 0.860294 | 0 | 0 | 0.166667 | 0 | 0 | 0.058333 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.25 | 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 | 0 | 0 | 1 | 0 | 0 | 1 |
d5e2dbd876c5aecbca72754b6c2f75453f2c95a4 | 462 | py | Python | wplay/utils/target_data.py | Simran-bhardwaj/whatsapp-play | 30ad0da7d5ccf1a34b7d2a5df6ad85821c5ef927 | [
"MIT"
] | 1 | 2020-03-04T17:55:51.000Z | 2020-03-04T17:55:51.000Z | wplay/utils/target_data.py | Simran-bhardwaj/whatsapp-play | 30ad0da7d5ccf1a34b7d2a5df6ad85821c5ef927 | [
"MIT"
] | null | null | null | wplay/utils/target_data.py | Simran-bhardwaj/whatsapp-play | 30ad0da7d5ccf1a34b7d2a5df6ad85821c5ef927 | [
"MIT"
] | null | null | null |
# region IMPORTS
from wplay.utils.helpers import whatsapp_selectors_dict
# endregion
# region FOR SCRIPTING
async def get_last_seen_from_focused_target(page):
#await page.waitForSelector(whatsapp_selectors_dict['status'], visible = True)
try:
status = await page.evaluate(f'document.querySelector("{wh... | 30.8 | 127 | 0.742424 | 55 | 462 | 6.018182 | 0.672727 | 0.154079 | 0.190332 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.158009 | 462 | 15 | 128 | 30.8 | 0.8509 | 0.285714 | 0 | 0 | 0 | 0 | 0.317901 | 0.265432 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.142857 | 0 | 0.428571 | 0 | 0 | 0 | 0 | null | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
d5e3d3bf26da873216f678cee39c4ba9421d4d2b | 742 | py | Python | plugins/base64_plugin/lib/Base64.py | MrT3acher/Android-Malware-Sandbox | a1b491ed6169fa2803c563dd3b9184b2c252fa8a | [
"Apache-2.0"
] | 218 | 2019-08-06T09:55:07.000Z | 2022-03-29T07:49:07.000Z | plugins/base64_plugin/lib/Base64.py | MrT3acher/Android-Malware-Sandbox | a1b491ed6169fa2803c563dd3b9184b2c252fa8a | [
"Apache-2.0"
] | 9 | 2019-09-12T02:28:05.000Z | 2022-03-22T20:59:22.000Z | plugins/base64_plugin/lib/Base64.py | MrT3acher/Android-Malware-Sandbox | a1b491ed6169fa2803c563dd3b9184b2c252fa8a | [
"Apache-2.0"
] | 35 | 2019-09-10T17:21:46.000Z | 2022-03-12T13:47:32.000Z | import datetime
from lib.model.database.Database import Database
from sqlalchemy import Column, Integer, String, Date, DateTime, ForeignKey
Base = Database.get_declarative_base()
class Base64(Base):
__tablename__ = 'base64'
id = Column(Integer, primary_key=True)
date = Column(DateTime, default=datetim... | 27.481481 | 82 | 0.696765 | 89 | 742 | 5.606742 | 0.404494 | 0.078156 | 0.06012 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.016556 | 0.185984 | 742 | 26 | 83 | 28.538462 | 0.809603 | 0 | 0 | 0 | 0 | 0.055556 | 0.113208 | 0.086253 | 0 | 0 | 0 | 0 | 0 | 1 | 0.111111 | false | 0 | 0.166667 | 0.055556 | 0.777778 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 1 |
d5e55e385f655ed077f9aec8608f05eabc086781 | 2,272 | py | Python | troposphere_mate/certificatemanager.py | MacHu-GWU/troposphere_mate-project | 426721170a46f0c6cdf4ca965efffdfdd8654189 | [
"MIT"
] | 10 | 2019-07-08T14:52:16.000Z | 2021-10-15T22:18:22.000Z | troposphere_mate/certificatemanager.py | MacHu-GWU/troposphere_mate-project | 426721170a46f0c6cdf4ca965efffdfdd8654189 | [
"MIT"
] | 1 | 2019-07-08T00:36:50.000Z | 2019-07-08T00:36:50.000Z | troposphere_mate/certificatemanager.py | MacHu-GWU/troposphere_mate-project | 426721170a46f0c6cdf4ca965efffdfdd8654189 | [
"MIT"
] | 2 | 2020-03-22T14:44:54.000Z | 2020-08-05T02:08:01.000Z | # -*- coding: utf-8 -*-
"""
This code is auto generated from troposphere_mate.code_generator.__init__.py scripts.
"""
import sys
if sys.version_info.major >= 3 and sys.version_info.minor >= 5: # pragma: no cover
from typing import Union, List, Any
import troposphere.certificatemanager
from troposphere.certific... | 36.063492 | 91 | 0.65493 | 196 | 2,272 | 7.387755 | 0.321429 | 0.051796 | 0.065608 | 0.063536 | 0.19337 | 0.15884 | 0.10221 | 0.10221 | 0.10221 | 0.10221 | 0 | 0.001799 | 0.265845 | 2,272 | 62 | 92 | 36.645161 | 0.866307 | 0.166373 | 0 | 0.297872 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.042553 | false | 0 | 0.148936 | 0 | 0.234043 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
d5e70dcc7bada85c211e262d314412175ed54a38 | 396 | py | Python | Dataset/Leetcode/train/12/606.py | kkcookies99/UAST | fff81885aa07901786141a71e5600a08d7cb4868 | [
"MIT"
] | null | null | null | Dataset/Leetcode/train/12/606.py | kkcookies99/UAST | fff81885aa07901786141a71e5600a08d7cb4868 | [
"MIT"
] | null | null | null | Dataset/Leetcode/train/12/606.py | kkcookies99/UAST | fff81885aa07901786141a71e5600a08d7cb4868 | [
"MIT"
] | null | null | null | class Solution:
def XXX(self, num: int) -> str:
values = [1000, 900, 500, 400, 100, 90, 50, 40, 10, 9, 5, 4, 1]
reps = ["M", "CM", "D", "CD", "C", "XC", "L", "XL", "X", "IX", "V", "IV", "I"]
roman_num = ''
for i in range(13):
while num >= values[i]:
num ... | 30.461538 | 86 | 0.416667 | 57 | 396 | 2.842105 | 0.754386 | 0.148148 | 0.111111 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.120968 | 0.373737 | 396 | 12 | 87 | 33 | 0.532258 | 0 | 0 | 0 | 0 | 0 | 0.048101 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 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 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
d5e736b69314bae6a13027b8cc07ee885b403790 | 456 | py | Python | src/app/database/model/Unfinisheds.py | william920429/repair_system | 27b5f4612a48a326943d23c2acce326070134228 | [
"MIT"
] | 1 | 2021-05-18T17:28:09.000Z | 2021-05-18T17:28:09.000Z | src/app/database/model/Unfinisheds.py | SiriusKoan/repair_system | 6524e7a8d5954b6e16b34b9d88db9d455ef3dd1d | [
"MIT"
] | 3 | 2021-05-02T06:00:47.000Z | 2021-05-05T11:42:58.000Z | src/app/database/model/Unfinisheds.py | SiriusKoan/repair_system | 6524e7a8d5954b6e16b34b9d88db9d455ef3dd1d | [
"MIT"
] | 3 | 2021-04-15T13:03:36.000Z | 2021-05-06T03:13:59.000Z | from .common import db
class Unfinisheds(db.Model):
"""
This TABLE is used to optimize query.
Do not need to backup.
"""
__tablename__ = "unfinisheds"
record_id = db.Column(db.ForeignKey("records.id"), primary_key=True)
def __init__(self, record_id):
self.record_id = record_id
... | 21.714286 | 72 | 0.611842 | 55 | 456 | 4.654545 | 0.618182 | 0.1875 | 0.148438 | 0.125 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.274123 | 456 | 20 | 73 | 22.8 | 0.773414 | 0.131579 | 0 | 0 | 0 | 0 | 0.146277 | 0.090426 | 0 | 0 | 0 | 0 | 0 | 1 | 0.181818 | false | 0 | 0.090909 | 0.090909 | 0.636364 | 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 | 0 | 0 | 1 | 0 | 0 | 1 |
d5e82406d972c5fb03d4bb814a9c0e95dd78d6ca | 1,968 | py | Python | DaVE/mLingua/examples_ncsim/serdes/sim_w_reflection/generate_eye.py | upscale-project/hslink_phy | 741f78da673d2e633da05d292aa6645125ebae32 | [
"BSD-3-Clause"
] | 6 | 2019-07-16T19:40:46.000Z | 2021-10-05T02:33:00.000Z | DaVE/mLingua/examples_ncsim/serdes/sim_w_reflection/generate_eye.py | upscale-project/hslink_phy | 741f78da673d2e633da05d292aa6645125ebae32 | [
"BSD-3-Clause"
] | 1 | 2019-06-06T02:15:54.000Z | 2019-07-19T23:32:40.000Z | DaVE/mLingua/examples_ncsim/serdes/sim_w_reflection/generate_eye.py | upscale-project/hslink_phy | 741f78da673d2e633da05d292aa6645125ebae32 | [
"BSD-3-Clause"
] | 3 | 2020-06-20T19:19:50.000Z | 2021-03-28T08:20:57.000Z | #! /usr/bin/env python
"""
Generate eyediagram and save it to eye.png
"""
import argparse
import numpy as np
from scipy.interpolate import interp1d
import matplotlib.pylab as plt
import matplotlib
from matplotlib.colors import Normalize
font = { 'size' : 19}
matplotlib.rc('font', **font)
def resample(data, time... | 28.114286 | 114 | 0.658537 | 337 | 1,968 | 3.738872 | 0.385757 | 0.047619 | 0.015873 | 0.019841 | 0.111111 | 0.111111 | 0.057143 | 0.057143 | 0.057143 | 0 | 0 | 0.043452 | 0.158028 | 1,968 | 69 | 115 | 28.521739 | 0.716958 | 0.069614 | 0 | 0 | 1 | 0 | 0.101704 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.056604 | false | 0 | 0.113208 | 0 | 0.207547 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
d5e831b221f975c820f1271709eb5b84d1bef05a | 3,358 | py | Python | v3io.py | yaronha/v3io-py-http | b66fd6fe837ce26e8a9c2fdbbfa07aa4a47db7fe | [
"Apache-2.0"
] | null | null | null | v3io.py | yaronha/v3io-py-http | b66fd6fe837ce26e8a9c2fdbbfa07aa4a47db7fe | [
"Apache-2.0"
] | null | null | null | v3io.py | yaronha/v3io-py-http | b66fd6fe837ce26e8a9c2fdbbfa07aa4a47db7fe | [
"Apache-2.0"
] | null | null | null |
__version__ = '0.1.0'
import requests
import base64
import json
import os
class V3io:
def __init__(self, address='', user='', password='', token='', container=''):
address = address or os.getenv('V3IO_API')
user = user or os.getenv('V3IO_USERNAME', 'iguazio')
password = password or os.ge... | 33.247525 | 119 | 0.564324 | 365 | 3,358 | 5.131507 | 0.282192 | 0.029899 | 0.05339 | 0.050721 | 0.279765 | 0.268553 | 0.268553 | 0.268553 | 0.268553 | 0.268553 | 0 | 0.013361 | 0.286778 | 3,358 | 100 | 120 | 33.58 | 0.768685 | 0.027099 | 0 | 0.246575 | 0 | 0 | 0.097733 | 0.00674 | 0 | 0 | 0 | 0 | 0 | 1 | 0.09589 | false | 0.054795 | 0.054795 | 0 | 0.246575 | 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 | 0 | 0 | 0 | 1 |
d5eb2eabd5be6ace4f7f0cce367c858325cef9bf | 2,829 | py | Python | djet/files.py | gradam/djet | be091d2a5c9f42888b493e22fcaf1f21e064ba3c | [
"MIT"
] | null | null | null | djet/files.py | gradam/djet | be091d2a5c9f42888b493e22fcaf1f21e064ba3c | [
"MIT"
] | null | null | null | djet/files.py | gradam/djet | be091d2a5c9f42888b493e22fcaf1f21e064ba3c | [
"MIT"
] | null | null | null | import os
import datetime
from django.core.files.storage import Storage, default_storage
from django.core.files.uploadedfile import InMemoryUploadedFile
from django.utils import six
class InMemoryStorage(Storage):
def __init__(self):
self.files = {}
def _open(self, name, mode):
return self.f... | 28.575758 | 102 | 0.640862 | 336 | 2,829 | 5.22619 | 0.282738 | 0.041002 | 0.039863 | 0.030752 | 0.144647 | 0.144647 | 0.144647 | 0.144647 | 0.07631 | 0.07631 | 0 | 0.008547 | 0.255567 | 2,829 | 98 | 103 | 28.867347 | 0.825261 | 0 | 0 | 0.144737 | 0 | 0 | 0.009897 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.210526 | false | 0.013158 | 0.078947 | 0.078947 | 0.473684 | 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 | 0 | 0 | 0 | 1 |
d5ebc5a6f2480036c3bff12e91a4c00b2e4bdf30 | 1,374 | py | Python | tests/test_objects.py | samkberry/prysm | 3c17cb7b6049a36a1f8b6a0035c216ca1078aee1 | [
"MIT"
] | null | null | null | tests/test_objects.py | samkberry/prysm | 3c17cb7b6049a36a1f8b6a0035c216ca1078aee1 | [
"MIT"
] | null | null | null | tests/test_objects.py | samkberry/prysm | 3c17cb7b6049a36a1f8b6a0035c216ca1078aee1 | [
"MIT"
] | null | null | null | """Tests for the various objects prysm knows how to synthesize."""
import pytest
from prysm import objects
@pytest.mark.parametrize('orientation', ['h', 'v', 'crossed', 'horizontal', 'vertical'])
def test_slit_renders_correctly_for_all_orientations(orientation):
slit = objects.Slit(1, orientation, 0.05, 19)
... | 29.234043 | 104 | 0.658661 | 180 | 1,374 | 4.844444 | 0.394444 | 0.018349 | 0.017202 | 0.013761 | 0.222477 | 0.126147 | 0.094037 | 0 | 0 | 0 | 0 | 0.032877 | 0.203057 | 1,374 | 46 | 105 | 29.869565 | 0.76347 | 0.043668 | 0 | 0 | 0 | 0 | 0.062691 | 0 | 0 | 0 | 0 | 0 | 0.233333 | 1 | 0.233333 | false | 0 | 0.066667 | 0 | 0.3 | 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 | 0 | 0 | 0 | 1 |
d5f3264b2173ce300277f7e4ed807b976d8363de | 5,449 | py | Python | extensions/cauchy/test_cauchy.py | NathanYanJing/state-spaces | 0d89b8fa4b534ff4fc295a03e4e3948907778b72 | [
"Apache-2.0"
] | 513 | 2021-11-03T23:08:23.000Z | 2022-03-31T16:29:18.000Z | extensions/cauchy/test_cauchy.py | NathanYanJing/state-spaces | 0d89b8fa4b534ff4fc295a03e4e3948907778b72 | [
"Apache-2.0"
] | 18 | 2021-11-05T12:42:59.000Z | 2022-03-27T19:49:55.000Z | extensions/cauchy/test_cauchy.py | NathanYanJing/state-spaces | 0d89b8fa4b534ff4fc295a03e4e3948907778b72 | [
"Apache-2.0"
] | 47 | 2021-11-04T01:32:54.000Z | 2022-03-30T18:24:26.000Z | import math
import torch
import pytest
from einops import rearrange
from cauchy import cauchy_mult_torch, cauchy_mult_keops, cauchy_mult
def generate_data(batch_size, N, L, symmetric=True, device='cuda'):
if not symmetric:
v = torch.randn(batch_size, N, dtype=torch.complex64, device=device, requires_gr... | 54.49 | 122 | 0.670215 | 896 | 5,449 | 3.868304 | 0.127232 | 0.019908 | 0.065782 | 0.031737 | 0.742354 | 0.677438 | 0.515868 | 0.388055 | 0.369879 | 0.33468 | 0 | 0.036153 | 0.162415 | 5,449 | 99 | 123 | 55.040404 | 0.723269 | 0.2951 | 0 | 0 | 1 | 0.101695 | 0.156127 | 0.102598 | 0 | 0 | 0 | 0 | 0.118644 | 1 | 0.050847 | false | 0 | 0.084746 | 0 | 0.169492 | 0.101695 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
d5fb7ff2bf1761db7ae9f70dec892e5cb831d346 | 502 | py | Python | cookbook/example.py | benmaier/komoog | 5b6613a5ba31c71be28f2642681cb01c2cb67e41 | [
"MIT"
] | 2 | 2021-10-05T20:03:42.000Z | 2021-10-07T12:13:19.000Z | cookbook/example.py | benmaier/komoog | 5b6613a5ba31c71be28f2642681cb01c2cb67e41 | [
"MIT"
] | null | null | null | cookbook/example.py | benmaier/komoog | 5b6613a5ba31c71be28f2642681cb01c2cb67e41 | [
"MIT"
] | null | null | null | from komoog.komoot import choose_downloaded_komoot_tour
from komoog.audio import convert_tour_to_audio, play_audio
tour = choose_downloaded_komoot_tour()
audio, sampling_rate = convert_tour_to_audio(tour,
tune='C#',
approximate_l... | 45.636364 | 82 | 0.551793 | 50 | 502 | 5.06 | 0.48 | 0.079051 | 0.173913 | 0.205534 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.003333 | 0.40239 | 502 | 10 | 83 | 50.2 | 0.84 | 0 | 0 | 0 | 0 | 0 | 0.003984 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.222222 | 0 | 0.222222 | 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 | 0 | 0 | 0 | 0 | 0 | 1 |
d5fe479daef2fd5b4ff0e01b9b678096c0f18463 | 1,154 | py | Python | django/contrib/gis/geos/__init__.py | bpeschier/django | f54c0ec06e390dc5bce95fdccbcb51d6423da4f9 | [
"BSD-3-Clause"
] | 39 | 2016-12-05T14:36:37.000Z | 2021-07-29T18:22:34.000Z | django/contrib/gis/geos/__init__.py | bpeschier/django | f54c0ec06e390dc5bce95fdccbcb51d6423da4f9 | [
"BSD-3-Clause"
] | 68 | 2016-12-12T20:38:47.000Z | 2020-07-26T18:28:49.000Z | django/contrib/gis/geos/__init__.py | bpeschier/django | f54c0ec06e390dc5bce95fdccbcb51d6423da4f9 | [
"BSD-3-Clause"
] | 120 | 2016-08-18T14:53:03.000Z | 2020-06-16T13:27:20.000Z | """
The GeoDjango GEOS module. Please consult the GeoDjango documentation
for more details:
http://geodjango.org/docs/geos.html
"""
__all__ = ['HAS_GEOS']
try:
from .libgeos import geos_version, geos_version_info # NOQA: flake8 detects only the last __all__
HAS_GEOS = True
__all__ += ['geos_version', '... | 36.0625 | 102 | 0.711438 | 121 | 1,154 | 6.53719 | 0.471074 | 0.035398 | 0.025284 | 0.055626 | 0.136536 | 0 | 0 | 0 | 0 | 0 | 0 | 0.001065 | 0.186308 | 1,154 | 31 | 103 | 37.225806 | 0.841321 | 0.147314 | 0 | 0 | 0 | 0 | 0.237705 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.434783 | 0 | 0.434783 | 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 | 0 | 0 | 0 | 1 |
91084098208e122d988997fdd16241e3cd0a4acb | 5,291 | py | Python | wick/tests/test_operators.py | msibaev/wick | 59f8a4b522f11875320e9e98b3af57fe7b7d8313 | [
"MIT"
] | 9 | 2020-09-24T15:59:27.000Z | 2022-01-26T16:25:29.000Z | wick/tests/test_operators.py | msibaev/wick | 59f8a4b522f11875320e9e98b3af57fe7b7d8313 | [
"MIT"
] | 1 | 2021-12-28T20:46:16.000Z | 2021-12-28T20:46:16.000Z | wick/tests/test_operators.py | msibaev/wick | 59f8a4b522f11875320e9e98b3af57fe7b7d8313 | [
"MIT"
] | 3 | 2021-09-12T08:37:52.000Z | 2021-11-30T23:25:47.000Z | import unittest
from wick.index import Idx
from wick.operator import FOperator, BOperator, Projector
from wick.operator import Delta, Tensor, Sigma
class OperatorTest(unittest.TestCase):
def test_foperator(self):
i = Idx(0, "occ")
j = Idx(1, "occ")
O1 = FOperator(i, False)
O2 = FO... | 27.994709 | 57 | 0.504253 | 684 | 5,291 | 3.846491 | 0.127193 | 0.303307 | 0.060813 | 0.023945 | 0.342835 | 0.260737 | 0.247815 | 0.22805 | 0.178639 | 0.171038 | 0 | 0.058206 | 0.334341 | 5,291 | 188 | 58 | 28.143617 | 0.688813 | 0.01134 | 0 | 0.316129 | 0 | 0 | 0.036179 | 0 | 0 | 0 | 0 | 0 | 0.380645 | 1 | 0.058065 | false | 0 | 0.025806 | 0 | 0.090323 | 0 | 0 | 0 | 0 | null | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
91087c7598d2b82107e9c0322b7cfcac440ce1ee | 11,947 | py | Python | corehq/apps/users/tests/test_location_assignment.py | rochakchauhan/commcare-hq | aa7ab3c2d0c51fe10f2b51b08101bb4b5a376236 | [
"BSD-3-Clause"
] | null | null | null | corehq/apps/users/tests/test_location_assignment.py | rochakchauhan/commcare-hq | aa7ab3c2d0c51fe10f2b51b08101bb4b5a376236 | [
"BSD-3-Clause"
] | 1 | 2021-06-02T04:45:16.000Z | 2021-06-02T04:45:16.000Z | corehq/apps/users/tests/test_location_assignment.py | rochakchauhan/commcare-hq | aa7ab3c2d0c51fe10f2b51b08101bb4b5a376236 | [
"BSD-3-Clause"
] | null | null | null | import copy
from datetime import datetime
from django.test import TestCase
from corehq.apps.commtrack.tests.util import make_loc
from corehq.apps.domain.shortcuts import create_domain
from corehq.apps.locations.tests.util import delete_all_locations
from corehq.apps.users.management.commands import add_multi_location... | 38.414791 | 100 | 0.691471 | 1,433 | 11,947 | 5.542917 | 0.099791 | 0.052373 | 0.038273 | 0.043057 | 0.744177 | 0.722271 | 0.684628 | 0.654161 | 0.612867 | 0.573083 | 0 | 0.007803 | 0.206244 | 11,947 | 310 | 101 | 38.53871 | 0.829801 | 0.072403 | 0 | 0.56746 | 0 | 0 | 0.028406 | 0.007599 | 0 | 0 | 0 | 0 | 0.246032 | 1 | 0.126984 | false | 0.011905 | 0.039683 | 0.003968 | 0.186508 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
911c339d6773fa98ab4395bf734afadd73002d1a | 1,818 | py | Python | code/graphics/histogram.py | liufuyang/Using_Python_Access_Web_Data | 630decbe749fef2ee8aa9d712d262e43ca7d5b1d | [
"MIT"
] | 41 | 2015-02-27T22:13:41.000Z | 2021-11-14T15:37:29.000Z | code/graphics/histogram.py | liufuyang/Using_Python_Access_Web_Data | 630decbe749fef2ee8aa9d712d262e43ca7d5b1d | [
"MIT"
] | 2 | 2015-12-15T04:03:15.000Z | 2017-01-13T15:29:47.000Z | code/graphics/histogram.py | liufuyang/Using_Python_Access_Web_Data | 630decbe749fef2ee8aa9d712d262e43ca7d5b1d | [
"MIT"
] | 45 | 2015-01-03T17:26:02.000Z | 2022-01-09T16:06:04.000Z | import string
from graphics import *
fname = raw_input("Enter file name:")
if len(fname) == 0 :
print "Assuming mbox-short.txt"
fname = "mbox-short.txt"
infile = open(fname, "r")
# Set up a 24 element list of zeros
totals = [0] * 24;
print totals;
# Accumulate the times
for line in infile:
if line[0:5] == "... | 21.642857 | 61 | 0.59626 | 316 | 1,818 | 3.427215 | 0.338608 | 0.024007 | 0.019391 | 0.022161 | 0.102493 | 0.035088 | 0.035088 | 0.035088 | 0 | 0 | 0 | 0.072767 | 0.236524 | 1,818 | 83 | 62 | 21.903614 | 0.707493 | 0.133113 | 0 | 0.125 | 0 | 0 | 0.097125 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.035714 | null | null | 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 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
912070d19b352e4f3e1b58c9d17fc20017e25e01 | 2,920 | py | Python | src/profile_sim.py | danhje/population-dynamics-simulator | 38d1b711ea9be4bd3009def8743c5522f8fd9f9b | [
"MIT"
] | null | null | null | src/profile_sim.py | danhje/population-dynamics-simulator | 38d1b711ea9be4bd3009def8743c5522f8fd9f9b | [
"MIT"
] | null | null | null | src/profile_sim.py | danhje/population-dynamics-simulator | 38d1b711ea9be4bd3009def8743c5522f8fd9f9b | [
"MIT"
] | null | null | null | '''
:mod:`profile_sim` runs a BioSim simulation
and illustrates how to use the resulting information.
Original code written by Hans E Plesser.
Slight modification by Aleksander Hykkerud and Daniel Hjertholm.
.. seealso::
- http://docs.python.org/library/profile.html
- http://www.doughellmann.com/PyMOTW/profile... | 29.2 | 81 | 0.596575 | 364 | 2,920 | 4.642857 | 0.387363 | 0.047337 | 0.052071 | 0.018935 | 0.292899 | 0.268639 | 0.233136 | 0.179882 | 0.179882 | 0.179882 | 0 | 0.038801 | 0.223288 | 2,920 | 99 | 82 | 29.494949 | 0.706349 | 0.280822 | 0 | 0.378378 | 0 | 0 | 0.309414 | 0.064294 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.108108 | null | null | 0.027027 | 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 | 0 | 0 | 1 |
912164972651a5ddfcc42638e786e1c10a206285 | 4,700 | py | Python | djangoecommerce/settings.py | jhonatanlteodoro/ecommerce-django | 931c70bba7658cdb982e5294e02c2b90d02b8c82 | [
"MIT"
] | 1 | 2020-01-07T20:50:48.000Z | 2020-01-07T20:50:48.000Z | djangoecommerce/settings.py | jhonatanlteodoro/ecommerce-django | 931c70bba7658cdb982e5294e02c2b90d02b8c82 | [
"MIT"
] | null | null | null | djangoecommerce/settings.py | jhonatanlteodoro/ecommerce-django | 931c70bba7658cdb982e5294e02c2b90d02b8c82 | [
"MIT"
] | null | null | null | """
Django settings for djangoecommerce project.
Generated by 'django-admin startproject' using Django 1.11.
For more information on this file, see
https://docs.djangoproject.com/en/1.11/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/1.11/ref/settings/
"""
imp... | 24.736842 | 91 | 0.703617 | 519 | 4,700 | 6.235067 | 0.416185 | 0.068294 | 0.042027 | 0.054079 | 0.163782 | 0.13288 | 0.084672 | 0.084672 | 0.03801 | 0 | 0 | 0.012002 | 0.166809 | 4,700 | 189 | 92 | 24.867725 | 0.814351 | 0.268511 | 0 | 0 | 1 | 0.009434 | 0.487941 | 0.386176 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0.04717 | 0.018868 | 0 | 0.018868 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
9126660c17b4d292106e7cb603f77e1890882456 | 406 | py | Python | Valid_palindrome.py | ankitagupta820/LeetCode | adecaecd27ffefddc34a0bc16488319e25e95580 | [
"MIT"
] | 2 | 2021-04-18T21:22:36.000Z | 2021-04-18T21:22:41.000Z | Valid_palindrome.py | ankitagupta820/LeetCode | adecaecd27ffefddc34a0bc16488319e25e95580 | [
"MIT"
] | null | null | null | Valid_palindrome.py | ankitagupta820/LeetCode | adecaecd27ffefddc34a0bc16488319e25e95580 | [
"MIT"
] | null | null | null | class Solution:
def isPalindrome(self, s: str) -> bool:
l,r = 0, len(s)-1
while l<r:
if not s[l].isalnum():
l+=1
elif not s[r].isalnum():
r-=1
elif s[l].lower() == s[r].lower():
l+=1
... | 22.555556 | 46 | 0.334975 | 47 | 406 | 2.893617 | 0.489362 | 0.029412 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.032258 | 0.541872 | 406 | 17 | 47 | 23.882353 | 0.698925 | 0 | 0 | 0.285714 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.071429 | false | 0 | 0 | 0 | 0.285714 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
9126bf7eeb35b7e0dec642633a48f896a26d2227 | 2,082 | py | Python | Portfolio/migrations/0001_initial.py | Shreya549/AchieveVIT | 4623f80a4e38914f2d759fc0c3591bd642486a5b | [
"MIT"
] | 3 | 2020-08-29T20:23:27.000Z | 2021-05-20T05:44:01.000Z | Portfolio/migrations/0001_initial.py | Shreya549/AchieveVIT | 4623f80a4e38914f2d759fc0c3591bd642486a5b | [
"MIT"
] | 1 | 2020-09-29T16:28:24.000Z | 2020-09-29T16:28:24.000Z | Portfolio/migrations/0001_initial.py | Shreya549/AchieveVIT | 4623f80a4e38914f2d759fc0c3591bd642486a5b | [
"MIT"
] | null | null | null | # Generated by Django 2.2 on 2020-09-24 14:40
from django.db import migrations, models
import django.db.models.deletion
import uuid
class Migration(migrations.Migration):
initial = True
dependencies = [
('Accounts', '0003_auto_20200924_1634'),
]
operations = [
migrations.CreateMode... | 43.375 | 154 | 0.600865 | 217 | 2,082 | 5.64977 | 0.322581 | 0.085644 | 0.097879 | 0.117455 | 0.668026 | 0.646003 | 0.619086 | 0.619086 | 0.534258 | 0.354812 | 0 | 0.034884 | 0.256484 | 2,082 | 47 | 155 | 44.297872 | 0.757106 | 0.020653 | 0 | 0.375 | 1 | 0 | 0.121748 | 0.011291 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.075 | 0 | 0.175 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
912763c8c37e35ff9ff8ee5d70de2574a3bf2eae | 948 | py | Python | UNIQ/data.py | aqui-tna/darts-UNIQ | 293a27b104bc0f53c6093829d1184686b788fba9 | [
"Apache-2.0"
] | 6 | 2019-04-28T05:30:00.000Z | 2020-01-21T08:16:13.000Z | UNIQ/data.py | aqui-tna/darts-UNIQ | 293a27b104bc0f53c6093829d1184686b788fba9 | [
"Apache-2.0"
] | null | null | null | UNIQ/data.py | aqui-tna/darts-UNIQ | 293a27b104bc0f53c6093829d1184686b788fba9 | [
"Apache-2.0"
] | 5 | 2019-04-29T05:57:04.000Z | 2021-04-21T00:19:11.000Z | from os.path import join
import torchvision.datasets as datasets
__DATASETS_DEFAULT_PATH = '/media/ssd/Datasets/'
def get_dataset(name, train, transform, target_transform=None, download=True, datasets_path=__DATASETS_DEFAULT_PATH):
root = datasets_path # '/mnt/ssd/ImageNet/ILSVRC/Data/CLS-LOC' #os.path.join(dat... | 37.92 | 133 | 0.71097 | 113 | 948 | 5.761062 | 0.327434 | 0.16129 | 0.258065 | 0.152074 | 0.384025 | 0.384025 | 0.310292 | 0.310292 | 0.310292 | 0.310292 | 0 | 0.01292 | 0.183544 | 948 | 24 | 134 | 39.5 | 0.828165 | 0.077004 | 0 | 0.117647 | 0 | 0 | 0.058486 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.058824 | false | 0 | 0.117647 | 0 | 0.352941 | 0 | 0 | 0 | 0 | null | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
91299689acf2cd73cb568e3c53162476c65ba213 | 9,771 | py | Python | examples/python/gen-py/v1/music/ttypes.py | brendanbartels-wf/frugal | b4086c85f30a38a12856cd76a8eaaea57ae00d0f | [
"Apache-2.0"
] | null | null | null | examples/python/gen-py/v1/music/ttypes.py | brendanbartels-wf/frugal | b4086c85f30a38a12856cd76a8eaaea57ae00d0f | [
"Apache-2.0"
] | null | null | null | examples/python/gen-py/v1/music/ttypes.py | brendanbartels-wf/frugal | b4086c85f30a38a12856cd76a8eaaea57ae00d0f | [
"Apache-2.0"
] | null | null | null | #
# Autogenerated by Frugal Compiler (3.8.2)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
from thrift.Thrift import TType, TMessageType, TException, TApplicationException
from frugal.util import make_hashable
from thrift.transport import TTransport
from thrift.protocol import TBinaryProtocol... | 31.317308 | 104 | 0.53188 | 995 | 9,771 | 5.057286 | 0.166834 | 0.019475 | 0.033386 | 0.050079 | 0.627583 | 0.569356 | 0.540938 | 0.515501 | 0.46721 | 0.46721 | 0 | 0.014139 | 0.363013 | 9,771 | 311 | 105 | 31.418006 | 0.794344 | 0.053526 | 0 | 0.581301 | 1 | 0 | 0.019077 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.101626 | false | 0 | 0.01626 | 0.04065 | 0.223577 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
912a177d83dd8bf3c339c2546f24d1b659b82044 | 7,214 | py | Python | heliosburn/django/hbproject/api/models/rule_model.py | thecodeteam/heliosburn | 513f6335c9788948d82e5c9285d7869f3ff4cc10 | [
"MIT"
] | null | null | null | heliosburn/django/hbproject/api/models/rule_model.py | thecodeteam/heliosburn | 513f6335c9788948d82e5c9285d7869f3ff4cc10 | [
"MIT"
] | null | null | null | heliosburn/django/hbproject/api/models/rule_model.py | thecodeteam/heliosburn | 513f6335c9788948d82e5c9285d7869f3ff4cc10 | [
"MIT"
] | 1 | 2020-09-17T18:19:05.000Z | 2020-09-17T18:19:05.000Z | # Validation model for a 'Rule'
from bson import ObjectId
def validate(rule):
"""
Validate a rule within a dictionary. Returns a validated copy of the `rule` dict, or None if validation fails.
NOTE: Type conversions are attempted(eg str-to-int), but incompatible data types will still cause a failure.
... | 42.686391 | 121 | 0.543111 | 837 | 7,214 | 4.473118 | 0.148148 | 0.138889 | 0.185096 | 0.071047 | 0.525107 | 0.433761 | 0.379808 | 0.379808 | 0.358173 | 0.325053 | 0 | 0.003512 | 0.328944 | 7,214 | 169 | 122 | 42.686391 | 0.769882 | 0.084003 | 0 | 0.373239 | 0 | 0 | 0.169883 | 0 | 0 | 0 | 0 | 0 | 0.056338 | 1 | 0.007042 | false | 0.007042 | 0.007042 | 0 | 0.028169 | 0 | 0 | 0 | 0 | null | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
912bb30dc402b075fbc24f1bfa9791dac57a10d0 | 834 | py | Python | userena/admin.py | matachi/django-userena | 0f8f545fbaef91477e5fe7b658cb99f6d39d7ffd | [
"BSD-3-Clause"
] | 3 | 2015-11-30T05:00:09.000Z | 2021-09-21T00:03:57.000Z | userena/admin.py | matachi/django-userena | 0f8f545fbaef91477e5fe7b658cb99f6d39d7ffd | [
"BSD-3-Clause"
] | null | null | null | userena/admin.py | matachi/django-userena | 0f8f545fbaef91477e5fe7b658cb99f6d39d7ffd | [
"BSD-3-Clause"
] | 2 | 2016-09-18T01:20:06.000Z | 2021-09-21T00:01:54.000Z | from django.contrib import admin
from django.contrib.auth.admin import UserAdmin
from django.utils.translation import ugettext as _
from guardian.admin import GuardedModelAdmin
from userena.models import UserenaSignup
from userena.utils import get_profile_model, get_user_model
class UserenaSignupInline(admin.StackedI... | 32.076923 | 67 | 0.76259 | 101 | 834 | 6.079208 | 0.49505 | 0.04886 | 0.058632 | 0.065147 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.001395 | 0.140288 | 834 | 25 | 68 | 33.36 | 0.854951 | 0 | 0 | 0 | 0 | 0 | 0.106715 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0.05 | 0.3 | 0 | 0.65 | 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 | 0 | 0 | 1 | 0 | 0 | 1 |
912d5be752c47086b6850e6e040902972ade4b23 | 973 | py | Python | accountingsubject/migrations/0001_initial.py | zwj12/accounting | 96678104ac7815da57f8f8c1a38c3138bc5ed0b6 | [
"Apache-2.0"
] | null | null | null | accountingsubject/migrations/0001_initial.py | zwj12/accounting | 96678104ac7815da57f8f8c1a38c3138bc5ed0b6 | [
"Apache-2.0"
] | null | null | null | accountingsubject/migrations/0001_initial.py | zwj12/accounting | 96678104ac7815da57f8f8c1a38c3138bc5ed0b6 | [
"Apache-2.0"
] | null | null | null | # Generated by Django 3.0.7 on 2020-07-18 04:06
from django.db import migrations, models
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='AccountingSubject',
fields=[
('id', models.... | 33.551724 | 114 | 0.593011 | 98 | 973 | 5.72449 | 0.622449 | 0.058824 | 0.081996 | 0.092692 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.02849 | 0.27852 | 973 | 28 | 115 | 34.75 | 0.770655 | 0.046249 | 0 | 0 | 1 | 0 | 0.143629 | 0.024838 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.047619 | 0 | 0.238095 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
912ef742b6e85eb801917e655606f8c469c361c3 | 4,019 | py | Python | supermarket_pricing/python/supermarket_abxsantos/tests/test_products.py | TijsDeBelie/codekatas-TDD | fff067b4089c7651630994bb938de4f54461b93d | [
"MIT"
] | null | null | null | supermarket_pricing/python/supermarket_abxsantos/tests/test_products.py | TijsDeBelie/codekatas-TDD | fff067b4089c7651630994bb938de4f54461b93d | [
"MIT"
] | null | null | null | supermarket_pricing/python/supermarket_abxsantos/tests/test_products.py | TijsDeBelie/codekatas-TDD | fff067b4089c7651630994bb938de4f54461b93d | [
"MIT"
] | null | null | null | import unittest
from datetime import datetime
from src.product import ProductBundleDiscount
from src.product.products import Product
param_name_sku_list = [(1), ([]), (''), ({})]
param_cost_price_list = [("abc"), ([]), (''), ({})]
class TestProduct(unittest.TestCase):
def test_product_must_raise_error_when_inst... | 50.873418 | 113 | 0.696193 | 554 | 4,019 | 4.732852 | 0.140794 | 0.034706 | 0.069413 | 0.086957 | 0.697941 | 0.697941 | 0.650648 | 0.631198 | 0.588482 | 0.568269 | 0 | 0.044858 | 0.184623 | 4,019 | 78 | 114 | 51.525641 | 0.755264 | 0 | 0 | 0.258065 | 0 | 0 | 0.034088 | 0 | 0 | 0 | 0 | 0 | 0.274194 | 1 | 0.209677 | false | 0 | 0.064516 | 0 | 0.290323 | 0.016129 | 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 | 0 | 0 | 0 | 1 |
9133b6c397a89e5d2556510920c279c31cf922a1 | 2,939 | py | Python | server/domain.py | j-be/laundry-dudes | 312f4fa2ca1a5c09f0fe421f61257ba39194d299 | [
"MIT"
] | null | null | null | server/domain.py | j-be/laundry-dudes | 312f4fa2ca1a5c09f0fe421f61257ba39194d299 | [
"MIT"
] | null | null | null | server/domain.py | j-be/laundry-dudes | 312f4fa2ca1a5c09f0fe421f61257ba39194d299 | [
"MIT"
] | null | null | null | from sqlobject import SQLObject, FloatCol, IntCol, DateTimeCol, connectionForURI, sqlhub, UnicodeCol
from sqlobject.sresults import SelectResults
#DATABASE_FILE = '/:memory:'
DATABASE_FILE = '/tmp/laundrydude.db'
class DataPoint(SQLObject):
timestamp = DateTimeCol(default=DateTimeCol.now)
class Humidity(DataPoint)... | 22.782946 | 100 | 0.717251 | 340 | 2,939 | 6.05 | 0.332353 | 0.042781 | 0.075839 | 0.09334 | 0.166262 | 0.14001 | 0.105007 | 0 | 0 | 0 | 0 | 0.0086 | 0.169105 | 2,939 | 128 | 101 | 22.960938 | 0.833743 | 0.018374 | 0 | 0.303371 | 0 | 0 | 0.029041 | 0 | 0 | 0 | 0 | 0.007813 | 0 | 0 | null | null | 0 | 0.022472 | null | null | 0.011236 | 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 | 0 | 0 | 1 |
913647966e948c26568205da25f21e0ea861bbba | 5,524 | py | Python | python/GafferUI/DotUI.py | Kthulhu/gaffer | 8995d579d07231988abc92c3ac2788c15c8bc75c | [
"BSD-3-Clause"
] | 1 | 2016-07-31T09:55:09.000Z | 2016-07-31T09:55:09.000Z | python/GafferUI/DotUI.py | Kthulhu/gaffer | 8995d579d07231988abc92c3ac2788c15c8bc75c | [
"BSD-3-Clause"
] | null | null | null | python/GafferUI/DotUI.py | Kthulhu/gaffer | 8995d579d07231988abc92c3ac2788c15c8bc75c | [
"BSD-3-Clause"
] | null | null | null | ##########################################################################
#
# Copyright (c) 2014, Image Engine Design Inc. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
#
# * Redistrib... | 31.20904 | 119 | 0.652245 | 566 | 5,524 | 6.340989 | 0.475265 | 0.015046 | 0.020061 | 0.012817 | 0.065756 | 0.037894 | 0.037894 | 0.037894 | 0.037894 | 0.037894 | 0 | 0.002378 | 0.162744 | 5,524 | 176 | 120 | 31.386364 | 0.773622 | 0.342505 | 0 | 0.15493 | 0 | 0 | 0.157258 | 0.02621 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.056338 | 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 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
913b6fea470bd083139a51965810902f53575983 | 2,185 | py | Python | tests/unit/test_metric.py | TiesWestendorp/MTG-Mana-Simulator | b77bb67dd732fa4416d52605d49d6eae3a50f840 | [
"MIT"
] | 10 | 2021-10-17T21:02:34.000Z | 2021-11-04T21:07:06.000Z | tests/unit/test_metric.py | TiesWestendorp/MTG-Mana-Simulator | b77bb67dd732fa4416d52605d49d6eae3a50f840 | [
"MIT"
] | 6 | 2021-10-04T18:30:08.000Z | 2021-10-04T19:57:21.000Z | tests/unit/test_metric.py | TiesWestendorp/MTG-Mana-Simulator | b77bb67dd732fa4416d52605d49d6eae3a50f840 | [
"MIT"
] | null | null | null | """
Unit tests for Metric class
"""
from sys import version_info
from statistics import StatisticsError
from pytest import raises
from mtg_mana_simulator.metric import Metric
def traces():
"""Example traces"""
trace1 = [1,2,3]
trace2 = [1,2,2]
trace3 = [0,0,1]
trace4 = [0,0,0]
return [trace1, ... | 35.819672 | 91 | 0.623341 | 329 | 2,185 | 4.069909 | 0.270517 | 0.019417 | 0.120986 | 0.161314 | 0.212845 | 0.150859 | 0.150859 | 0.070202 | 0 | 0 | 0 | 0.074352 | 0.20595 | 2,185 | 60 | 92 | 36.416667 | 0.69683 | 0.098398 | 0 | 0 | 0 | 0 | 0.018353 | 0 | 0 | 0 | 0 | 0 | 0.35 | 1 | 0.125 | false | 0 | 0.1 | 0 | 0.275 | 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 | 0 | 0 | 0 | 0 | 0 | 1 |
913ceefb50622188495e491947a825503da91156 | 2,990 | py | Python | src/cogite/checks/pre_merge.py | Polyconseil/cogite | dae4729dd3013f9a9a77961f6d1ab8dd26eec63f | [
"BSD-3-Clause"
] | 4 | 2021-05-11T14:55:15.000Z | 2022-01-07T14:23:09.000Z | src/cogite/checks/pre_merge.py | Polyconseil/cogite | dae4729dd3013f9a9a77961f6d1ab8dd26eec63f | [
"BSD-3-Clause"
] | null | null | null | src/cogite/checks/pre_merge.py | Polyconseil/cogite | dae4729dd3013f9a9a77961f6d1ab8dd26eec63f | [
"BSD-3-Clause"
] | null | null | null | #!/usr/bin/env python
"""Check that the commits that the user is about to push, do not look
like the user has forgotten to squash work-in-progress commits.
"""
import os
import subprocess
import sys
from cogite import interaction
# If the user pushes MAX_COMMITS or more, ask for confirmation.
MAX_COMMITS = 2
DISPLA... | 33.595506 | 88 | 0.653512 | 424 | 2,990 | 4.433962 | 0.386792 | 0.051064 | 0.047872 | 0.046809 | 0.241489 | 0.180319 | 0.166489 | 0.156383 | 0.092553 | 0.092553 | 0 | 0.00351 | 0.237793 | 2,990 | 88 | 89 | 33.977273 | 0.820097 | 0.225418 | 0 | 0.068966 | 0 | 0 | 0.268378 | 0.010874 | 0 | 0 | 0 | 0.011364 | 0 | 1 | 0.051724 | false | 0 | 0.068966 | 0 | 0.189655 | 0.103448 | 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 | 0 | 0 | 0 | 0 | 1 |
913ea392b2ff90d84d7994b958b9b2b33335a881 | 3,138 | py | Python | cobl/lexicon/migrations/0149_refill_romanisedsymbol.py | Bibiko/CoBL-public | 5092a0d01b7a13565c7da6bf2f6c52d648a2debe | [
"BSD-2-Clause"
] | 3 | 2017-05-30T04:40:43.000Z | 2019-04-25T14:54:54.000Z | cobl/lexicon/migrations/0149_refill_romanisedsymbol.py | Bibiko/CoBL-public | 5092a0d01b7a13565c7da6bf2f6c52d648a2debe | [
"BSD-2-Clause"
] | null | null | null | cobl/lexicon/migrations/0149_refill_romanisedsymbol.py | Bibiko/CoBL-public | 5092a0d01b7a13565c7da6bf2f6c52d648a2debe | [
"BSD-2-Clause"
] | 3 | 2018-07-02T13:42:12.000Z | 2019-05-17T13:11:13.000Z | # -*- coding: utf-8 -*-
from __future__ import unicode_literals, print_function
from django.db import migrations
def forwards_func(apps, schema_editor):
RomanisedSymbol = apps.get_model("lexicon", "RomanisedSymbol")
RomanisedSymbol.objects.all().delete()
approved = [b'a', b'\\u0101', b'\\u0103', b'\\xe1',... | 53.186441 | 79 | 0.4471 | 428 | 3,138 | 3.235981 | 0.495327 | 0.017329 | 0.017329 | 0.017329 | 0.150903 | 0.150903 | 0.150903 | 0.150903 | 0.144404 | 0.144404 | 0 | 0.166094 | 0.257489 | 3,138 | 58 | 80 | 54.103448 | 0.428326 | 0.006692 | 0 | 0.081633 | 0 | 0 | 0.343178 | 0.008026 | 0 | 0 | 0 | 0 | 0 | 1 | 0.040816 | false | 0 | 0.040816 | 0 | 0.142857 | 0.020408 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
9142d1bb87473c32321436e2598728fcc04bf66e | 1,652 | py | Python | apps/directoryentries/migrations/0009_boardpolicyadmin.py | iamjdcollins/districtwebsite | 89e2aea47ca3d221665bc23586a4374421be5800 | [
"MIT"
] | null | null | null | apps/directoryentries/migrations/0009_boardpolicyadmin.py | iamjdcollins/districtwebsite | 89e2aea47ca3d221665bc23586a4374421be5800 | [
"MIT"
] | null | null | null | apps/directoryentries/migrations/0009_boardpolicyadmin.py | iamjdcollins/districtwebsite | 89e2aea47ca3d221665bc23586a4374421be5800 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
# Generated by Django 1.11.6 on 2017-12-06 19:13
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('objects', '0003_node_has_permissions'),
('users', '... | 45.888889 | 272 | 0.660412 | 164 | 1,652 | 6.396341 | 0.518293 | 0.038132 | 0.053384 | 0.083889 | 0.126787 | 0.126787 | 0.126787 | 0.091516 | 0.091516 | 0 | 0 | 0.034056 | 0.217918 | 1,652 | 35 | 273 | 47.2 | 0.777864 | 0.041162 | 0 | 0 | 1 | 0 | 0.340923 | 0.190386 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.107143 | 0 | 0.214286 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
9149cd088c386d5d3f528a5ed6a3a0197282c910 | 1,447 | py | Python | bert_seq2seq/basic_bert.py | t-web/bert_seq2seq | 01a0ad8f255b4b9343b4727cdd437629225d206f | [
"Apache-2.0"
] | null | null | null | bert_seq2seq/basic_bert.py | t-web/bert_seq2seq | 01a0ad8f255b4b9343b4727cdd437629225d206f | [
"Apache-2.0"
] | null | null | null | bert_seq2seq/basic_bert.py | t-web/bert_seq2seq | 01a0ad8f255b4b9343b4727cdd437629225d206f | [
"Apache-2.0"
] | null | null | null |
import torch
import torch.nn as nn
from bert_seq2seq.tokenizer import load_chinese_base_vocab, Tokenizer
class BasicBert(nn.Module):
def __init__(self):
super().__init__()
#self.device = torch.device("cpu")
def load_pretrain_params(self, pretrain_model_path, keep_tokens=None):
check... | 33.651163 | 94 | 0.645473 | 175 | 1,447 | 5.062857 | 0.4 | 0.060948 | 0.057562 | 0.047404 | 0.115124 | 0 | 0 | 0 | 0 | 0 | 0 | 0.001854 | 0.254319 | 1,447 | 42 | 95 | 34.452381 | 0.819277 | 0.080857 | 0 | 0.074074 | 0 | 0 | 0.05291 | 0.028723 | 0 | 0 | 0 | 0 | 0 | 1 | 0.222222 | false | 0 | 0.111111 | 0 | 0.37037 | 0.074074 | 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 | 0 | 0 | 0 | 1 |
914a2a29b390daaf5ce073ac5991feb2a9fa9002 | 387 | py | Python | posts/models.py | edisnake/PythonDjangoPostApp | 7fb9894994dc350fd350573e4cb64d2de98cecb9 | [
"MIT"
] | 1 | 2018-09-15T17:31:36.000Z | 2018-09-15T17:31:36.000Z | posts/models.py | edisnake/PythonDjangoPostApp | 7fb9894994dc350fd350573e4cb64d2de98cecb9 | [
"MIT"
] | null | null | null | posts/models.py | edisnake/PythonDjangoPostApp | 7fb9894994dc350fd350573e4cb64d2de98cecb9 | [
"MIT"
] | null | null | null | from datetime import datetime
from django.db import models
# Create your models here.
class Posts(models.Model):
title = models.CharField(max_length=200)
body = models.TextField()
created_ts = models.DateTimeField(default=datetime.now, blank=True)
def __str__(self):
return s... | 29.769231 | 72 | 0.674419 | 47 | 387 | 5.382979 | 0.723404 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.010239 | 0.242894 | 387 | 12 | 73 | 32.25 | 0.853242 | 0.062016 | 0 | 0 | 0 | 0 | 0.014327 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.1 | false | 0 | 0.2 | 0.1 | 0.9 | 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 | 0 | 0 | 1 | 0 | 0 | 1 |
914ab93808c0509a7fce449166c556e0ee5a4878 | 1,515 | py | Python | wagtail_transfer/models.py | gasman/wagtail-transfer | 313e01eb95df0cd38d6c3cf8172f1479fcdbbecd | [
"BSD-3-Clause"
] | 55 | 2019-10-15T17:11:00.000Z | 2022-03-17T09:54:46.000Z | wagtail_transfer/models.py | gasman/wagtail-transfer | 313e01eb95df0cd38d6c3cf8172f1479fcdbbecd | [
"BSD-3-Clause"
] | 60 | 2019-11-15T11:44:20.000Z | 2022-03-25T00:03:39.000Z | wagtail_transfer/models.py | gasman/wagtail-transfer | 313e01eb95df0cd38d6c3cf8172f1479fcdbbecd | [
"BSD-3-Clause"
] | 10 | 2019-11-28T12:10:58.000Z | 2022-03-24T22:09:33.000Z | from django.db import models
from django.contrib.contenttypes.fields import GenericForeignKey
from django.contrib.contenttypes.models import ContentType
class IDMapping(models.Model):
uid = models.UUIDField(primary_key=True)
content_type = models.ForeignKey(ContentType, on_delete=models.CASCADE)
local_id... | 30.918367 | 86 | 0.732673 | 207 | 1,515 | 5.111111 | 0.400966 | 0.034026 | 0.034026 | 0.048204 | 0.241021 | 0.155955 | 0.130435 | 0.130435 | 0.130435 | 0.130435 | 0 | 0.007937 | 0.168317 | 1,515 | 48 | 87 | 31.5625 | 0.831746 | 0.194719 | 0 | 0 | 0 | 0 | 0.035163 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.12 | false | 0 | 0.16 | 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 | 0 | 0 | 0 | 1 | 0 | 0 | 1 |
9152c9aca547b4b05335eb466405fcd45b01618e | 2,937 | py | Python | apps/jsftpserver/jsftpserver.py | Jumpscale/jumpscale6_core | 0502ddc1abab3c37ed982c142d21ea3955d471d3 | [
"BSD-2-Clause"
] | 1 | 2015-10-26T10:38:13.000Z | 2015-10-26T10:38:13.000Z | apps/jsftpserver/jsftpserver.py | Jumpscale/jumpscale6_core | 0502ddc1abab3c37ed982c142d21ea3955d471d3 | [
"BSD-2-Clause"
] | null | null | null | apps/jsftpserver/jsftpserver.py | Jumpscale/jumpscale6_core | 0502ddc1abab3c37ed982c142d21ea3955d471d3 | [
"BSD-2-Clause"
] | null | null | null | #!/usr/bin/env python
# $Id: basic_ftpd.py 1174 2013-02-19 11:25:49Z g.rodola $
# pyftpdlib is released under the MIT license, reproduced below:
# ======================================================================
# Copyright (C) 2007-2013 Giampaolo Rodola' <g.rodola@gmail.com>
#
# All R... | 33 | 73 | 0.695608 | 387 | 2,937 | 5.232558 | 0.54522 | 0.043457 | 0.01284 | 0.022716 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.021277 | 0.183861 | 2,937 | 88 | 74 | 33.375 | 0.823529 | 0.686415 | 0 | 0 | 0 | 0 | 0.072082 | 0.02746 | 0 | 0 | 0 | 0 | 0 | 1 | 0.041667 | false | 0.125 | 0.208333 | 0 | 0.25 | 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 | 0 | 0 | 0 | 1 |
915332f1606c64df0ed6dba9c4e42dfe2ee9778c | 1,685 | py | Python | home/settings/prod.py | ARAldhafeeri/sary-task | 1fe1c091d397c09acc606d3dcb878e725725c506 | [
"MIT"
] | 2 | 2021-11-11T16:28:27.000Z | 2022-03-07T08:29:13.000Z | home/settings/prod.py | ARAldhafeeri/sary-task | 1fe1c091d397c09acc606d3dcb878e725725c506 | [
"MIT"
] | null | null | null | home/settings/prod.py | ARAldhafeeri/sary-task | 1fe1c091d397c09acc606d3dcb878e725725c506 | [
"MIT"
] | null | null | null | '''Use this for production'''
from .base import *
DEBUG = False
ALLOWED_HOSTS += ['http://domain.com']
WSGI_APPLICATION = 'home.wsgi.prod.application'
DATABASES = {
'default': {
'ENGINE': 'django.db.backends.postgresql_psycopg2',
'NAME': 'db_name',
'USER': 'db_user',
'PASSWORD': '... | 30.089286 | 89 | 0.633234 | 163 | 1,685 | 6.417178 | 0.576687 | 0.057361 | 0.06501 | 0.080306 | 0.202677 | 0.14914 | 0 | 0 | 0 | 0 | 0 | 0.003823 | 0.223739 | 1,685 | 55 | 90 | 30.636364 | 0.795872 | 0.187537 | 0 | 0.045455 | 0 | 0 | 0.532009 | 0.342163 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0.136364 | 0.022727 | 0 | 0.022727 | 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 | 0 | 0 | 0 | 1 |
e66c0e303dc8d6096469f679ce341ccc7f40243c | 641 | py | Python | conanfile.py | hinrikg/conan-spdlog | 40d0b8a4d37707aa001a28adb6e2f928a6899cb9 | [
"MIT"
] | 1 | 2016-08-11T12:11:38.000Z | 2016-08-11T12:11:38.000Z | conanfile.py | hinrikg/conan-spdlog | 40d0b8a4d37707aa001a28adb6e2f928a6899cb9 | [
"MIT"
] | null | null | null | conanfile.py | hinrikg/conan-spdlog | 40d0b8a4d37707aa001a28adb6e2f928a6899cb9 | [
"MIT"
] | null | null | null | from conans import ConanFile
from conans.tools import get
class SpdlogConan(ConanFile):
name = 'spdlog'
version = '0.9.0'
author = 'Hinrik Gylfason (hinrikg@gmail.com)'
url = 'http://github.com/hinrikg/conan-spdlog'
license = 'MIT'
settings = None
generators = 'cmake'
def source(self... | 29.136364 | 84 | 0.628705 | 91 | 641 | 4.406593 | 0.516484 | 0.024938 | 0.029925 | 0.082294 | 0.274314 | 0.244389 | 0.244389 | 0.244389 | 0.244389 | 0.244389 | 0 | 0.028902 | 0.190328 | 641 | 21 | 85 | 30.52381 | 0.743738 | 0 | 0 | 0 | 0 | 0 | 0.349454 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.125 | false | 0 | 0.125 | 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 | 0 | 0 | 1 | 0 | 0 | 1 |
e674678ee3b4f1592d2eaaf248535b51a4201410 | 5,276 | py | Python | test/animatedledstrip/test_strip_info.py | AnimatedLEDStrip/client-python | 0502b1b70faf6ce9b9ff7b53ee4740372fccb4c3 | [
"MIT"
] | null | null | null | test/animatedledstrip/test_strip_info.py | AnimatedLEDStrip/client-python | 0502b1b70faf6ce9b9ff7b53ee4740372fccb4c3 | [
"MIT"
] | null | null | null | test/animatedledstrip/test_strip_info.py | AnimatedLEDStrip/client-python | 0502b1b70faf6ce9b9ff7b53ee4740372fccb4c3 | [
"MIT"
] | null | null | null | # Copyright (c) 2019-2020 AnimatedLEDStrip
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, mer... | 32.368098 | 119 | 0.68442 | 717 | 5,276 | 4.880056 | 0.213389 | 0.060017 | 0.078022 | 0.108031 | 0.579308 | 0.566162 | 0.566162 | 0.566162 | 0.556445 | 0.509574 | 0 | 0.00835 | 0.228203 | 5,276 | 162 | 120 | 32.567901 | 0.850933 | 0.206785 | 0 | 0.632075 | 0 | 0.028302 | 0.189527 | 0.070622 | 0 | 0 | 0 | 0 | 0.311321 | 1 | 0.066038 | false | 0.056604 | 0.018868 | 0 | 0.084906 | 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 | 0 | 0 | 0 | 1 |
e677bf1d8a74e32194fc10e39e2afe29826077b9 | 3,969 | py | Python | data_structures/repeated_word/tests/test_repeated_word.py | joyliao07/data_structures_and_algorithms | bd595cca37d77e121056476dc12c1631d421100d | [
"MIT"
] | 1 | 2019-02-27T01:51:43.000Z | 2019-02-27T01:51:43.000Z | data_structures/repeated_word/tests/test_repeated_word.py | joyliao07/data_structures_and_algorithms | bd595cca37d77e121056476dc12c1631d421100d | [
"MIT"
] | 33 | 2018-11-28T03:40:11.000Z | 2019-01-24T06:15:56.000Z | data_structures/repeated_word/tests/test_repeated_word.py | joyliao07/data_structures_and_algorithms | bd595cca37d77e121056476dc12c1631d421100d | [
"MIT"
] | null | null | null | """This module will contain class Hash and its related methods."""
from ..repeated_word import Hash
import pytest
def test_class_exist():
"""To test that the class Graph exists."""
assert Hash
def test_str_method_empty():
"""To test the output of str method."""
h = Hash()
assert str(h) == 'Hash ... | 36.75 | 327 | 0.534643 | 492 | 3,969 | 4.113821 | 0.166667 | 0.049407 | 0.039526 | 0.063241 | 0.716403 | 0.642787 | 0.55583 | 0.366601 | 0.334486 | 0.271739 | 0 | 0.020655 | 0.207105 | 3,969 | 107 | 328 | 37.093458 | 0.622498 | 0.181658 | 0 | 0.344262 | 0 | 0.04918 | 0.371329 | 0 | 0 | 0 | 0 | 0 | 0.245902 | 1 | 0.245902 | false | 0 | 0.032787 | 0 | 0.278689 | 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 | 0 | 0 | 0 | 1 |
e681c46a78fb3e75f3e8782d89836360412c22a0 | 1,628 | py | Python | fpb/base/dask.py | cloudmercato/python-fpb | 5da2773e3bb7068bfb9cde920c5b754eecdf342e | [
"BSD-3-Clause"
] | 3 | 2021-12-29T20:39:53.000Z | 2021-12-29T23:53:02.000Z | fpb/base/dask.py | cloudspectatordevelopment/python-fpb | 5da2773e3bb7068bfb9cde920c5b754eecdf342e | [
"BSD-3-Clause"
] | null | null | null | fpb/base/dask.py | cloudspectatordevelopment/python-fpb | 5da2773e3bb7068bfb9cde920c5b754eecdf342e | [
"BSD-3-Clause"
] | null | null | null | import multiprocessing
import dask
import dask.array as da
import dask.dataframe as dd
from fpb.base import common
from fpb.base import numpy
class BaseDaskRunner(numpy.BaseNumpyRunner):
dd = dd
da = da
extra_data = {
'numpy_version': numpy.np.__version__,
'dask_version': dask.__version__,... | 28.561404 | 64 | 0.641278 | 187 | 1,628 | 5.454545 | 0.315508 | 0.023529 | 0.035294 | 0.061765 | 0.553922 | 0.506863 | 0.290196 | 0.247059 | 0.247059 | 0.247059 | 0 | 0.009039 | 0.252457 | 1,628 | 56 | 65 | 29.071429 | 0.829088 | 0.081081 | 0 | 0.380952 | 0 | 0 | 0.021622 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.119048 | false | 0.02381 | 0.142857 | 0 | 0.52381 | 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 | 0 | 0 | 1 | 0 | 0 | 1 |
e68307c37be584c6e4ecc3c4b1a4489883349a16 | 2,061 | py | Python | affo_user_service/settings.py | affoio/affo-user-service | 23a9cc868b39054fa599dbddf6a0b85a0921ea1b | [
"BSD-3-Clause"
] | null | null | null | affo_user_service/settings.py | affoio/affo-user-service | 23a9cc868b39054fa599dbddf6a0b85a0921ea1b | [
"BSD-3-Clause"
] | null | null | null | affo_user_service/settings.py | affoio/affo-user-service | 23a9cc868b39054fa599dbddf6a0b85a0921ea1b | [
"BSD-3-Clause"
] | 1 | 2019-11-25T14:21:58.000Z | 2019-11-25T14:21:58.000Z | import sys # noqa
from dynaconf import LazySettings, Validator
settings = LazySettings(ENVVAR_PREFIX_FOR_DYNACONF="AFFO_US", ENVVAR_FOR_DYNACONF="AFFO_US_SETTINGS")
# Register validators
settings.validators.register(
Validator(
"DATABASE_URI",
"CACHE_TYPE",
"ADMIN_EMAIL",
"ADMIN_... | 27.48 | 101 | 0.733624 | 217 | 2,061 | 6.599078 | 0.410138 | 0.027933 | 0.027933 | 0.027235 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.011034 | 0.164483 | 2,061 | 74 | 102 | 27.851351 | 0.820557 | 0.123726 | 0 | 0 | 0 | 0 | 0.224638 | 0.046265 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0.125 | 0.0625 | 0 | 0.0625 | 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 | 0 | 0 | 0 | 1 |
e68d19cf4edac111153e420a87a1a9c1e05e5123 | 811 | py | Python | examples/serial_to_tcp.py | rubund/enocean-python | 3524fecc4c5d6efbf342c5c57f6cb119258bfd2d | [
"MIT"
] | 65 | 2015-02-19T12:31:06.000Z | 2022-03-24T23:10:21.000Z | examples/serial_to_tcp.py | rubund/enocean-python | 3524fecc4c5d6efbf342c5c57f6cb119258bfd2d | [
"MIT"
] | 124 | 2015-06-18T15:17:15.000Z | 2022-02-26T17:22:12.000Z | examples/serial_to_tcp.py | rubund/enocean-python | 3524fecc4c5d6efbf342c5c57f6cb119258bfd2d | [
"MIT"
] | 92 | 2015-01-04T09:26:09.000Z | 2022-03-06T10:25:26.000Z | #!/usr/bin/env python
# -*- encoding: utf-8 -*-
from enocean.consolelogger import init_logging
from enocean.communicators.serialcommunicator import SerialCommunicator
from enocean.communicators.utils import send_to_tcp_socket
import sys
import traceback
try:
import queue
except ImportError:
import Queue as que... | 25.34375 | 71 | 0.727497 | 94 | 811 | 6.159574 | 0.574468 | 0.056995 | 0.082902 | 0.051813 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.009119 | 0.188656 | 811 | 31 | 72 | 26.16129 | 0.870821 | 0.087546 | 0 | 0.16 | 0 | 0 | 0.012212 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.32 | 0 | 0.32 | 0.04 | 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 | 0 | 0 | 0 | 1 |
e695ccbf321fde1b93bbef319eb21266c1017d11 | 1,819 | py | Python | src/main/python/passage_chunker.py | xeniaqian94/trec-cast-tools | b6bd151832f15758cfa14cc6b2c1dbb9c1a559b5 | [
"MIT"
] | null | null | null | src/main/python/passage_chunker.py | xeniaqian94/trec-cast-tools | b6bd151832f15758cfa14cc6b2c1dbb9c1a559b5 | [
"MIT"
] | null | null | null | src/main/python/passage_chunker.py | xeniaqian94/trec-cast-tools | b6bd151832f15758cfa14cc6b2c1dbb9c1a559b5 | [
"MIT"
] | null | null | null | import re
import spacy
nlp = spacy.load("en_core_web_sm",
exclude=["parser", "tagger", "ner", "attribute_ruler", "lemmatizer", "tok2vec"]) # ->senter
nlp.enable_pipe("senter")
print(nlp.pipe_names)
class SpacyPassageChunker:
def __init__(self):
self.document = None
self.sentenc... | 29.33871 | 109 | 0.593183 | 200 | 1,819 | 5.14 | 0.33 | 0.136187 | 0.070039 | 0.089494 | 0.262646 | 0.262646 | 0.202335 | 0.157588 | 0 | 0 | 0 | 0.009479 | 0.304013 | 1,819 | 61 | 110 | 29.819672 | 0.802528 | 0.004398 | 0 | 0.266667 | 0 | 0 | 0.048093 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.111111 | false | 0.355556 | 0.044444 | 0 | 0.244444 | 0.022222 | 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 | 0 | 0 | 0 | 1 |
e69a124dd4fc091b7af28a988991e2a88e76205f | 1,344 | py | Python | gopublish/db_models.py | mboudet/go-publish | f258878e8ee77711576c69d2a39e9398cea3fade | [
"MIT"
] | null | null | null | gopublish/db_models.py | mboudet/go-publish | f258878e8ee77711576c69d2a39e9398cea3fade | [
"MIT"
] | 5 | 2021-07-01T13:21:45.000Z | 2022-02-11T13:55:35.000Z | gopublish/db_models.py | mboudet/gopublish | f258878e8ee77711576c69d2a39e9398cea3fade | [
"MIT"
] | null | null | null | import uuid
from datetime import datetime
from sqlalchemy.dialects.postgresql import UUID
from .extensions import db
class PublishedFile(db.Model):
id = db.Column(UUID(as_uuid=True), primary_key=True, default=uuid.uuid4, unique=True)
task_id = db.Column(db.String(255), index=True)
# Maybe store it as te... | 44.8 | 89 | 0.712054 | 200 | 1,344 | 4.725 | 0.375 | 0.118519 | 0.137566 | 0.13545 | 0.369312 | 0.349206 | 0.349206 | 0.190476 | 0.190476 | 0.103704 | 0 | 0.024605 | 0.153274 | 1,344 | 29 | 90 | 46.344828 | 0.8058 | 0.104167 | 0 | 0 | 0 | 0 | 0.030833 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.047619 | false | 0 | 0.190476 | 0.047619 | 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 | 0 | 0 | 1 | 0 | 0 | 1 |
e69bd53b466959f799d66127440f7079885c064d | 21,390 | py | Python | argsloader/units/structure.py | HansBug/argsloader | 7737758de804ec81150382b1c76de9cf5f48c99d | [
"Apache-2.0"
] | null | null | null | argsloader/units/structure.py | HansBug/argsloader | 7737758de804ec81150382b1c76de9cf5f48c99d | [
"Apache-2.0"
] | null | null | null | argsloader/units/structure.py | HansBug/argsloader | 7737758de804ec81150382b1c76de9cf5f48c99d | [
"Apache-2.0"
] | null | null | null | from functools import reduce, partial
from operator import __rshift__
from typing import Mapping, Any, Union, Tuple, List
from hbutils.collection import nested_map
from hbutils.design import SingletonMark
from hbutils.string import truncate
from .base import BaseUnit, _to_unit, UnitProcessProxy, raw
from .build impor... | 34.444444 | 114 | 0.5554 | 2,661 | 21,390 | 4.368283 | 0.117625 | 0.019873 | 0.026153 | 0.034412 | 0.456641 | 0.419907 | 0.38085 | 0.352891 | 0.344116 | 0.323297 | 0 | 0.03368 | 0.294857 | 21,390 | 620 | 115 | 34.5 | 0.736989 | 0.632165 | 0 | 0.139241 | 0 | 0 | 0.042276 | 0.008015 | 0 | 0 | 0 | 0 | 0 | 1 | 0.196203 | false | 0 | 0.063291 | 0.031646 | 0.556962 | 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 | 0 | 0 | 1 | 0 | 0 | 1 |
e6a2adaadb97628b277c3871ce956a5630a2f979 | 820 | py | Python | wagtail/contrib/settings/tests/test_register.py | NKoech123/wagtail | c54f7852d04316279fe9d4a3ab2b3a751e5df18f | [
"BSD-3-Clause"
] | null | null | null | wagtail/contrib/settings/tests/test_register.py | NKoech123/wagtail | c54f7852d04316279fe9d4a3ab2b3a751e5df18f | [
"BSD-3-Clause"
] | null | null | null | wagtail/contrib/settings/tests/test_register.py | NKoech123/wagtail | c54f7852d04316279fe9d4a3ab2b3a751e5df18f | [
"BSD-3-Clause"
] | null | null | null | from django.test import TestCase
from django.urls import reverse
from wagtail.contrib.settings.registry import Registry
from wagtail.tests.testapp.models import NotYetRegisteredSetting
from wagtail.tests.utils import WagtailTestUtils
class TestRegister(TestCase, WagtailTestUtils):
def setUp(self):
self.r... | 35.652174 | 88 | 0.763415 | 83 | 820 | 7.493976 | 0.457831 | 0.07717 | 0.051447 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.156098 | 820 | 22 | 89 | 37.272727 | 0.898844 | 0 | 0 | 0 | 0 | 0 | 0.040244 | 0 | 0 | 0 | 0 | 0 | 0.235294 | 1 | 0.176471 | false | 0 | 0.294118 | 0 | 0.529412 | 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 | 0 | 0 | 1 | 0 | 0 | 1 |
e6a394a534223824e196e9f5b17b418dcb3bc925 | 838 | py | Python | Algo and DSA/LeetCode-Solutions-master/Python/binary-tree-coloring-game.py | Sourav692/FAANG-Interview-Preparation | f523e5c94d582328b3edc449ea16ac6ab28cdc81 | [
"Unlicense"
] | 3,269 | 2018-10-12T01:29:40.000Z | 2022-03-31T17:58:41.000Z | Algo and DSA/LeetCode-Solutions-master/Python/binary-tree-coloring-game.py | Sourav692/FAANG-Interview-Preparation | f523e5c94d582328b3edc449ea16ac6ab28cdc81 | [
"Unlicense"
] | 53 | 2018-12-16T22:54:20.000Z | 2022-02-25T08:31:20.000Z | Algo and DSA/LeetCode-Solutions-master/Python/binary-tree-coloring-game.py | Sourav692/FAANG-Interview-Preparation | f523e5c94d582328b3edc449ea16ac6ab28cdc81 | [
"Unlicense"
] | 1,236 | 2018-10-12T02:51:40.000Z | 2022-03-30T13:30:37.000Z | # Time: O(n)
# Space: O(h)
# Definition for a binary tree node.
class TreeNode(object):
def __init__(self, x):
self.val = x
self.left = None
self.right = None
class Solution(object):
def btreeGameWinningMove(self, root, n, x):
"""
:type root: TreeNode
:type n:... | 26.1875 | 91 | 0.522673 | 112 | 838 | 3.794643 | 0.339286 | 0.254118 | 0.117647 | 0.056471 | 0.089412 | 0 | 0 | 0 | 0 | 0 | 0 | 0.013011 | 0.357995 | 838 | 31 | 92 | 27.032258 | 0.776952 | 0.142005 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.166667 | false | 0 | 0 | 0 | 0.444444 | 0 | 0 | 0 | 0 | null | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
e6a502670be33a06b2731a9b7647f178773a98f9 | 307 | py | Python | OCR_bio/test.py | nchos88/OCR_DOC | a7c8a27bac9c9c801537e008763e14a7240ad845 | [
"Apache-2.0"
] | null | null | null | OCR_bio/test.py | nchos88/OCR_DOC | a7c8a27bac9c9c801537e008763e14a7240ad845 | [
"Apache-2.0"
] | null | null | null | OCR_bio/test.py | nchos88/OCR_DOC | a7c8a27bac9c9c801537e008763e14a7240ad845 | [
"Apache-2.0"
] | null | null | null | import pandas as pd
import numpy as np
import os
import csv
testpath = r"data\hangul-images-data\labels-map.csv"
path = "test.csv"
#res = np.loadtxt( path ,dtype = str )
res2 = pd.read_csv( testpath ,sep = ',' )
res3 = res2.iloc[: , 1]
print(res3.head())
res4 = list(res3.iloc[0:10])
print()
| 12.791667 | 52 | 0.648208 | 50 | 307 | 3.96 | 0.66 | 0.111111 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.040323 | 0.192182 | 307 | 23 | 53 | 13.347826 | 0.758065 | 0.123779 | 0 | 0 | 0 | 0 | 0.17803 | 0.143939 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.363636 | 0 | 0.363636 | 0.181818 | 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 | 0 | 0 | 0 | 1 |
e6a5be7ec77a57ca811ac7abe02cbab84ce3bf04 | 1,107 | py | Python | python/oneflow/compatible/single_client/layers.py | wangyuyue/oneflow | 0a71c22fe8355392acc8dc0e301589faee4c4832 | [
"Apache-2.0"
] | 3,285 | 2020-07-31T05:51:22.000Z | 2022-03-31T15:20:16.000Z | python/oneflow/compatible/single_client/layers.py | wangyuyue/oneflow | 0a71c22fe8355392acc8dc0e301589faee4c4832 | [
"Apache-2.0"
] | 2,417 | 2020-07-31T06:28:58.000Z | 2022-03-31T23:04:14.000Z | python/oneflow/compatible/single_client/layers.py | wangyuyue/oneflow | 0a71c22fe8355392acc8dc0e301589faee4c4832 | [
"Apache-2.0"
] | 520 | 2020-07-31T05:52:42.000Z | 2022-03-29T02:38:11.000Z | """
Copyright 2020 The OneFlow Authors. All rights reserved.
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 agr... | 33.545455 | 80 | 0.789521 | 159 | 1,107 | 5.358491 | 0.584906 | 0.070423 | 0.098592 | 0.126761 | 0.197183 | 0.197183 | 0.112676 | 0.112676 | 0 | 0 | 0 | 0.012807 | 0.153568 | 1,107 | 32 | 81 | 34.59375 | 0.896478 | 0.524842 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0.235294 | 0 | 0.235294 | 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 | 0 | 0 | 0 | 0 | 0 | 1 |
e6a86736df78a236637b8344b1d8767e3e076e53 | 10,125 | py | Python | externals/binaryen/auto_update_tests.py | cubetrain/CubeTrain | b930a3e88e941225c2c54219267f743c790e388f | [
"MIT"
] | null | null | null | externals/binaryen/auto_update_tests.py | cubetrain/CubeTrain | b930a3e88e941225c2c54219267f743c790e388f | [
"MIT"
] | null | null | null | externals/binaryen/auto_update_tests.py | cubetrain/CubeTrain | b930a3e88e941225c2c54219267f743c790e388f | [
"MIT"
] | null | null | null | #!/usr/bin/env python
import os, sys, subprocess, difflib
from scripts.test.support import run_command, split_wast
from scripts.test.shared import (
ASM2WASM, S2WASM, WASM_SHELL, WASM_OPT, WASM_AS, WASM_DIS, WASM_CTOR_EVAL)
print '[ processing and updating testcases... ]\n'
for asm in sorted(os.listdi... | 40.178571 | 155 | 0.566716 | 1,424 | 10,125 | 3.97823 | 0.16573 | 0.047661 | 0.068844 | 0.084025 | 0.449073 | 0.369285 | 0.310327 | 0.270256 | 0.249426 | 0.229303 | 0 | 0.005636 | 0.228938 | 10,125 | 251 | 156 | 40.338645 | 0.719995 | 0.031407 | 0 | 0.20098 | 0 | 0 | 0.209506 | 0.022047 | 0 | 0 | 0 | 0 | 0.02451 | 0 | null | null | 0.02451 | 0.014706 | null | null | 0.181373 | 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 | 0 | 0 | 1 |
e6a93279734fcab112594c02cd2c9feac4b383e9 | 1,524 | py | Python | sdk/compute/azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/operations/__init__.py | rsdoherty/azure-sdk-for-python | 6bba5326677468e6660845a703686327178bb7b1 | [
"MIT"
] | 2,728 | 2015-01-09T10:19:32.000Z | 2022-03-31T14:50:33.000Z | sdk/compute/azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/operations/__init__.py | rsdoherty/azure-sdk-for-python | 6bba5326677468e6660845a703686327178bb7b1 | [
"MIT"
] | 17,773 | 2015-01-05T15:57:17.000Z | 2022-03-31T23:50:25.000Z | sdk/compute/azure-mgmt-compute/azure/mgmt/compute/v2015_06_15/operations/__init__.py | rsdoherty/azure-sdk-for-python | 6bba5326677468e6660845a703686327178bb7b1 | [
"MIT"
] | 1,916 | 2015-01-19T05:05:41.000Z | 2022-03-31T19:36:44.000Z | # 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 ... | 50.8 | 97 | 0.77231 | 120 | 1,524 | 9.475 | 0.541667 | 0.126649 | 0.094987 | 0.040457 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.000723 | 0.091864 | 1,524 | 29 | 98 | 52.551724 | 0.820809 | 0.296588 | 0 | 0 | 0 | 0 | 0.25 | 0.235902 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.45 | 0 | 0.45 | 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 | 0 | 0 | 0 | 1 |
e6a998c256d9c6749e504a33815f7026488b53c2 | 3,675 | py | Python | src/TheLanguage/Parser/Statements/UnitTests/ImportStatementParserInfo_UnitTest.py | davidbrownell/DavidBrownell_TheLanguage | 07170b448a0ebd7fa2325c9ccd4cefdb3cf7eb98 | [
"BSL-1.0"
] | null | null | null | src/TheLanguage/Parser/Statements/UnitTests/ImportStatementParserInfo_UnitTest.py | davidbrownell/DavidBrownell_TheLanguage | 07170b448a0ebd7fa2325c9ccd4cefdb3cf7eb98 | [
"BSL-1.0"
] | null | null | null | src/TheLanguage/Parser/Statements/UnitTests/ImportStatementParserInfo_UnitTest.py | davidbrownell/DavidBrownell_TheLanguage | 07170b448a0ebd7fa2325c9ccd4cefdb3cf7eb98 | [
"BSL-1.0"
] | 1 | 2021-06-18T18:58:57.000Z | 2021-06-18T18:58:57.000Z | # ----------------------------------------------------------------------
# |
# | ImportStatementParserInfo_UnitTest.py
# |
# | David Brownell <db@DavidBrownell.com>
# | 2021-10-04 09:10:56
# |
# ----------------------------------------------------------------------
# |
# | Copyright David Brownell 2021... | 34.345794 | 86 | 0.529796 | 284 | 3,675 | 6.616197 | 0.306338 | 0.159127 | 0.111762 | 0.069186 | 0.403938 | 0.298563 | 0.232571 | 0.201171 | 0.187334 | 0.101118 | 0 | 0.017385 | 0.248707 | 3,675 | 106 | 87 | 34.669811 | 0.663166 | 0.230476 | 0 | 0.457143 | 0 | 0 | 0.030764 | 0 | 0 | 0 | 0 | 0 | 0.271429 | 1 | 0.028571 | false | 0 | 0.4 | 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 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 |
e6ac94deeecca639d59658cdbfc55e9da6576b67 | 6,064 | py | Python | coinExchange/trading/controller/coin_utils.py | biz2013/xwjy | 8f4b5e3e3fc964796134052ff34d58d31ed41904 | [
"Apache-2.0"
] | 1 | 2019-12-15T16:56:44.000Z | 2019-12-15T16:56:44.000Z | coinExchange/trading/controller/coin_utils.py | biz2013/xwjy | 8f4b5e3e3fc964796134052ff34d58d31ed41904 | [
"Apache-2.0"
] | 87 | 2018-01-06T10:18:31.000Z | 2022-03-11T23:32:30.000Z | coinExchange/trading/controller/coin_utils.py | biz2013/xwjy | 8f4b5e3e3fc964796134052ff34d58d31ed41904 | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/python
# -*- coding: utf-8 -*-
import json, subprocess, logging
from trading.controller.coinrpc import CoinProxy
from trading.models import Wallet
logger = logging.getLogger("site.coin_util")
# Sample config object: trading/tests/data/wallet_config.json
# config object is read from database, Wallet table, ... | 37.664596 | 336 | 0.723615 | 792 | 6,064 | 5.304293 | 0.200758 | 0.038086 | 0.043323 | 0.038562 | 0.375387 | 0.327303 | 0.251131 | 0.225184 | 0.217329 | 0.188289 | 0 | 0.022319 | 0.165073 | 6,064 | 160 | 337 | 37.9 | 0.807426 | 0.119558 | 0 | 0.2 | 0 | 0 | 0.221096 | 0.048611 | 0 | 0 | 0 | 0 | 0 | 1 | 0.066667 | false | 0.133333 | 0.025 | 0 | 0.15 | 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 | 0 | 0 | 0 | 1 |
e6b51f3fb51c04e9ee2471399ea69c5a70345b7e | 681 | py | Python | blogs/models.py | cyclades1/Social | 9dcb5a53b82c4b36fa27f7a406aa088a9796b6e7 | [
"MIT"
] | 2 | 2021-04-05T11:12:08.000Z | 2021-05-09T06:30:55.000Z | blogs/models.py | cyclades1/Social | 9dcb5a53b82c4b36fa27f7a406aa088a9796b6e7 | [
"MIT"
] | null | null | null | blogs/models.py | cyclades1/Social | 9dcb5a53b82c4b36fa27f7a406aa088a9796b6e7 | [
"MIT"
] | null | null | null | from django.db import models
# Create your models here.
class Blog(models.Model):
"""docstring for Blog_Model"""
genre_type = [
("Science and Technology","Science and Technology"),
("Literature","Literature"),
("Action","Action"),
("Personal Expierence","Personal Expierence"),
]
author = models.CharField(m... | 27.24 | 90 | 0.712188 | 86 | 681 | 5.511628 | 0.546512 | 0.094937 | 0.113924 | 0.151899 | 0.164557 | 0 | 0 | 0 | 0 | 0 | 0 | 0.010274 | 0.142438 | 681 | 24 | 91 | 28.375 | 0.80137 | 0.073421 | 0 | 0 | 0 | 0 | 0.184 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.0625 | false | 0 | 0.0625 | 0.0625 | 0.6875 | 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 | 0 | 0 | 1 | 0 | 0 | 1 |
e6ba6779189266e4f9c22b57689776505c297839 | 1,926 | py | Python | tools/build_file_list.py | CrazySherman/goodlife | 49f3c003d045370a0985ac934d4199b923e61237 | [
"BSD-2-Clause"
] | null | null | null | tools/build_file_list.py | CrazySherman/goodlife | 49f3c003d045370a0985ac934d4199b923e61237 | [
"BSD-2-Clause"
] | null | null | null | tools/build_file_list.py | CrazySherman/goodlife | 49f3c003d045370a0985ac934d4199b923e61237 | [
"BSD-2-Clause"
] | null | null | null | import argparse
import os
import sys
sys.path.append('.')
from pyActionRecog import parse_directory, build_split_list
from pyActionRecog import parse_split_file
parser = argparse.ArgumentParser()
parser.add_argument('--dataset', type=str, choices=['ucf101', 'hmdb51', 'activitynet_1.2', 'activitynet_1.3', 'armlc'])
pa... | 44.790698 | 119 | 0.748702 | 309 | 1,926 | 4.394822 | 0.265372 | 0.053019 | 0.100147 | 0.041237 | 0.302651 | 0.258468 | 0.20324 | 0.129602 | 0.129602 | 0.129602 | 0 | 0.012528 | 0.088266 | 1,926 | 42 | 120 | 45.857143 | 0.76082 | 0.004673 | 0 | 0 | 0 | 0 | 0.239164 | 0.051175 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.147059 | null | null | 0.058824 | 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 | 0 | 0 | 1 |
e6bfae28fec3f434f70fbab8ef812c8970aaabbb | 822 | py | Python | hfpy_code/chapter5/page168.py | leobarros/use_cabeca_python | 4e0897a68fb7ef669ec05eab7cba9412baa0e85e | [
"Apache-2.0"
] | 1 | 2016-04-01T04:31:52.000Z | 2016-04-01T04:31:52.000Z | hfpython_code/hfpy_code/chapter5/page168.py | tdean1995/HFPythonSandbox | dc72257e4353c5bca7a2c401d18587c6d799f9a1 | [
"Apache-2.0"
] | null | null | null | hfpython_code/hfpy_code/chapter5/page168.py | tdean1995/HFPythonSandbox | dc72257e4353c5bca7a2c401d18587c6d799f9a1 | [
"Apache-2.0"
] | 1 | 2020-06-02T17:47:22.000Z | 2020-06-02T17:47:22.000Z |
def sanitize(time_string):
if '-' in time_string:
splitter = '-'
elif ':' in time_string:
splitter = ':'
else:
return(time_string)
(mins, secs) = time_string.split(splitter)
return(mins + '.' + secs)
with open('james.txt') as jaf:
data = jaf.readline()
james = data.stri... | 25.6875 | 53 | 0.609489 | 123 | 822 | 4.03252 | 0.284553 | 0.100806 | 0.112903 | 0.177419 | 0.379032 | 0.245968 | 0.245968 | 0.245968 | 0.1875 | 0.1875 | 0 | 0.011958 | 0.186131 | 822 | 31 | 54 | 26.516129 | 0.729447 | 0 | 0 | 0 | 0 | 0 | 0.054811 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.04 | false | 0 | 0 | 0 | 0.04 | 0.16 | 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 | 0 | 0 | 1 |
e6c3d4643631722e2f1c3b6b97d34295b6732480 | 779 | py | Python | python算法/5.6如何对由大小写字母组成的字符数组排序.py | RobinYaoWenbin/Python-CommonCode | 1ee714541f2fd9c8b96d018d3d4eb94f4edc812a | [
"MIT"
] | 12 | 2020-09-28T03:25:03.000Z | 2022-03-20T07:44:09.000Z | python算法/5.6如何对由大小写字母组成的字符数组排序.py | RobinYaoWenbin/Python-CommonCode | 1ee714541f2fd9c8b96d018d3d4eb94f4edc812a | [
"MIT"
] | null | null | null | python算法/5.6如何对由大小写字母组成的字符数组排序.py | RobinYaoWenbin/Python-CommonCode | 1ee714541f2fd9c8b96d018d3d4eb94f4edc812a | [
"MIT"
] | 21 | 2020-03-19T00:44:35.000Z | 2022-01-30T03:46:18.000Z | # -*- coding: utf-8 -*-
"""
Created on Wed Feb 12 19:36:03 2020
@author: Administrator
"""
"""
有一个由大小写字母组成的字符串,请对它进行重新组合,使得其中的所有小写字母排在大写字母的前面
(大写字母或小写字母之间不要求保持原来的次序)
"""
def SortStr(s):
i = 0 ; j = len(s) - 1
while i < j:
if s[i].isupper():
pass
else:
... | 22.257143 | 62 | 0.418485 | 108 | 779 | 2.944444 | 0.398148 | 0.044025 | 0.037736 | 0.037736 | 0.075472 | 0.075472 | 0.075472 | 0.075472 | 0.075472 | 0.075472 | 0 | 0.054585 | 0.412067 | 779 | 35 | 63 | 22.257143 | 0.639738 | 0.105263 | 0 | 0.227273 | 0 | 0 | 0.077855 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.045455 | false | 0.090909 | 0 | 0 | 0.090909 | 0.045455 | 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 | 0 | 0 | 0 | 1 |
e6c90ee27ef9b8e2cd98d1153fb555805efba679 | 13,235 | py | Python | pipeline_plugins/tests/utils.py | manlucas/atom | 94963fc6fdfd0568473ee68e9d1631f421265359 | [
"Apache-2.0"
] | null | null | null | pipeline_plugins/tests/utils.py | manlucas/atom | 94963fc6fdfd0568473ee68e9d1631f421265359 | [
"Apache-2.0"
] | 8 | 2020-06-06T00:34:57.000Z | 2021-06-10T22:30:24.000Z | pipeline_plugins/tests/utils.py | manlucas/atom | 94963fc6fdfd0568473ee68e9d1631f421265359 | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
"""
Tencent is pleased to support the open source community by making 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community
Edition) available.
Copyright (C) 2017-2019 THL A29 Limited, a Tencent company. All rights reserved.
Licensed under the MIT License (the "License"); you may not use this file except in co... | 34.376623 | 115 | 0.345599 | 1,043 | 13,235 | 4.141898 | 0.211889 | 0.073843 | 0.081481 | 0.090509 | 0.537731 | 0.5 | 0.463657 | 0.39375 | 0.374074 | 0.326389 | 0 | 0.02035 | 0.550737 | 13,235 | 384 | 116 | 34.466146 | 0.706189 | 0.054552 | 0 | 0.450746 | 0 | 0 | 0.160096 | 0.001679 | 0 | 0 | 0 | 0 | 0 | 1 | 0.092537 | false | 0 | 0 | 0.065672 | 0.18209 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
e6cbcd153888320a385fd53af5d087e2c6d84d2d | 1,192 | py | Python | LVTUBEN/urls.py | metadeng/LVTUBEN_CD_TOOLKIL | 217e78974b171276d69fcc8f75719be44c218c9d | [
"MIT"
] | null | null | null | LVTUBEN/urls.py | metadeng/LVTUBEN_CD_TOOLKIL | 217e78974b171276d69fcc8f75719be44c218c9d | [
"MIT"
] | 11 | 2020-02-12T00:14:11.000Z | 2022-03-11T23:46:37.000Z | LVTUBEN/urls.py | metadeng/LVTUBEN_CD_TOOLKIL | 217e78974b171276d69fcc8f75719be44c218c9d | [
"MIT"
] | null | null | null | """LVTUBEN URL Configuration
The `urlpatterns` list routes URLs to views. For more information please see:
https://docs.djangoproject.com/en/2.2/topics/http/urls/
Examples:
Function views
1. Add an import: from my_app import views
2. Add a URL to urlpatterns: path('', views.home, name='home')
Class-based... | 33.111111 | 77 | 0.707215 | 171 | 1,192 | 4.877193 | 0.380117 | 0.071942 | 0.017986 | 0.028777 | 0.214628 | 0.214628 | 0.089928 | 0 | 0 | 0 | 0 | 0.010978 | 0.159396 | 1,192 | 35 | 78 | 34.057143 | 0.821357 | 0.522651 | 0 | 0 | 0 | 0 | 0.177936 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 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 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 |
e6cc9dd2cd61bd04f50a4b7052e261539e4716db | 14,380 | py | Python | MLlib/models.py | RidhimaKohli/ML-DL-implementation | 2bdb5abbb310a8cbc0547bb06ed7e176312a78d7 | [
"BSD-3-Clause"
] | null | null | null | MLlib/models.py | RidhimaKohli/ML-DL-implementation | 2bdb5abbb310a8cbc0547bb06ed7e176312a78d7 | [
"BSD-3-Clause"
] | null | null | null | MLlib/models.py | RidhimaKohli/ML-DL-implementation | 2bdb5abbb310a8cbc0547bb06ed7e176312a78d7 | [
"BSD-3-Clause"
] | null | null | null | from MLlib.optimizers import GradientDescent
from MLlib.activations import sigmoid
from MLlib.utils.misc_utils import generate_weights
from MLlib.utils.decision_tree_utils import partition, find_best_split
from MLlib.utils.decision_tree_utils import Leaf, Decision_Node
from MLlib.utils .knn_utils import get_neighbours
... | 29.287169 | 78 | 0.573853 | 1,727 | 14,380 | 4.712797 | 0.220614 | 0.022116 | 0.008601 | 0.011058 | 0.264529 | 0.229266 | 0.179015 | 0.138838 | 0.111562 | 0.093746 | 0 | 0.008366 | 0.335049 | 14,380 | 490 | 79 | 29.346939 | 0.842815 | 0.478025 | 0 | 0.106061 | 1 | 0 | 0.070702 | 0.02255 | 0 | 0 | 0 | 0 | 0 | 1 | 0.083333 | false | 0 | 0.098485 | 0 | 0.318182 | 0.128788 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
e6cdba62a61617f1513cef22b9d52ad4b13f0b6c | 403 | py | Python | apps/vue3pyj/xdict.py | ch-rigu/Elliot | 7c0690aa7befbd9f27c4684be312c4fa23581f17 | [
"BSD-3-Clause"
] | 10 | 2019-05-15T21:16:13.000Z | 2021-09-16T14:43:49.000Z | apps/vue3pyj/xdict.py | ch-rigu/Elliot | 7c0690aa7befbd9f27c4684be312c4fa23581f17 | [
"BSD-3-Clause"
] | 1 | 2019-07-23T10:33:15.000Z | 2019-07-25T19:06:16.000Z | apps/vue3pyj/xdict.py | ch-rigu/Elliot | 7c0690aa7befbd9f27c4684be312c4fa23581f17 | [
"BSD-3-Clause"
] | 2 | 2020-04-13T16:28:52.000Z | 2020-09-19T12:28:44.000Z |
__all__ = [ 'XDict' ]
class XDict(dict):
__slots__ = ()
__setattr__ = dict.__setitem__
__delattr__ = dict.__delitem__
__getitem__ = dict.get
__getattr__ = dict.get
__getnewargs__ = lambda self: getattr(dict,self).__getnewargs__(self)
__repr__ = lambda self: '<XDict %s>' % dict.__repr__(sel... | 26.866667 | 73 | 0.682382 | 43 | 403 | 5.093023 | 0.488372 | 0.182648 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.208437 | 403 | 14 | 74 | 28.785714 | 0.68652 | 0 | 0 | 0 | 0 | 0 | 0.037406 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0 | 0 | 0.909091 | 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 | 0 | 0 | 1 | 0 | 0 | 1 |
e6ce580764f28aa081027a754327405679d0d32a | 4,297 | py | Python | transform.py | rohieb/josm-tree-species-preset | 9331c61cd5592adc6011437766cf1a37a678e5ae | [
"CC0-1.0"
] | null | null | null | transform.py | rohieb/josm-tree-species-preset | 9331c61cd5592adc6011437766cf1a37a678e5ae | [
"CC0-1.0"
] | 1 | 2021-08-06T15:39:54.000Z | 2021-08-06T15:39:54.000Z | transform.py | rohieb/josm-tree-species-preset | 9331c61cd5592adc6011437766cf1a37a678e5ae | [
"CC0-1.0"
] | null | null | null | #!/usr/bin/env python3
import yaml
import sys
HEADER_TEMPLATE = """<?xml version="1.0"?>
<presets version="2.7.0" xmlns="http://josm.openstreetmap.de/tagging-preset-1.0">
<group name="Tree species" icon="natural_tree_24020.png">
<chunk id="common_keys">
<text key="height" text="Height (meters)" />
<text key... | 32.308271 | 84 | 0.547591 | 455 | 4,297 | 4.993407 | 0.294505 | 0.027729 | 0.043134 | 0.013204 | 0.132042 | 0.036092 | 0.036092 | 0.036092 | 0 | 0 | 0 | 0.007524 | 0.319525 | 4,297 | 132 | 85 | 32.55303 | 0.769494 | 0.008611 | 1 | 0.152381 | 0 | 0.009524 | 0.411226 | 0.056834 | 0 | 0 | 0 | 0 | 0 | 1 | 0.019048 | false | 0 | 0.019048 | 0.009524 | 0.047619 | 0.028571 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
e6ce93ccc19d24229c69dcad7e8bc866d21e5c46 | 1,350 | py | Python | app/models.py | ridhanf/python-fastapi-challenge | 041a2156c222dbd84805d6b6ee1d9b88b8227db3 | [
"MIT"
] | null | null | null | app/models.py | ridhanf/python-fastapi-challenge | 041a2156c222dbd84805d6b6ee1d9b88b8227db3 | [
"MIT"
] | null | null | null | app/models.py | ridhanf/python-fastapi-challenge | 041a2156c222dbd84805d6b6ee1d9b88b8227db3 | [
"MIT"
] | null | null | null | from typing import List
from sqlalchemy import Column, DateTime, ForeignKey, Integer, String, Enum
from sqlalchemy.orm import relationship
from sqlalchemy.sql import func
from app.constants import Role, Gender, Category
from app.database import Base
from app.utils.custom_type import ArrayOfEnum
# User Model Class
c... | 34.615385 | 75 | 0.735556 | 169 | 1,350 | 5.751479 | 0.349112 | 0.072016 | 0.065844 | 0.098765 | 0.339506 | 0.339506 | 0.216049 | 0.216049 | 0.216049 | 0.216049 | 0 | 0 | 0.15037 | 1,350 | 38 | 76 | 35.526316 | 0.847428 | 0.025926 | 0 | 0.142857 | 0 | 0 | 0.032012 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0.035714 | 0.25 | 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 | 0 | 0 | 1 | 0 | 0 | 1 |
e6d1414a007ef1a677b24acd9b3a3b984fbe96a1 | 617 | py | Python | blog/migrations/0004_blog_field1_squashed_0005_blog_field2.py | ht-90/django-blog | b7dd80a4066ecf3c288461e0c5785f953a1d2e5f | [
"MIT"
] | null | null | null | blog/migrations/0004_blog_field1_squashed_0005_blog_field2.py | ht-90/django-blog | b7dd80a4066ecf3c288461e0c5785f953a1d2e5f | [
"MIT"
] | 1 | 2021-02-23T11:25:37.000Z | 2021-02-23T11:25:37.000Z | blog/migrations/0004_blog_field1_squashed_0005_blog_field2.py | ht-90/django-blog | b7dd80a4066ecf3c288461e0c5785f953a1d2e5f | [
"MIT"
] | null | null | null | # Generated by Django 3.1.7 on 2021-03-05 08:40
from django.db import migrations, models
class Migration(migrations.Migration):
replaces = [('blog', '0004_blog_field1'), ('blog', '0005_blog_field2')]
dependencies = [
('blog', '0003_blog'),
]
operations = [
migrations.AddField(
... | 23.730769 | 75 | 0.564019 | 64 | 617 | 5.296875 | 0.578125 | 0.106195 | 0.135693 | 0.159292 | 0.436578 | 0.436578 | 0.230089 | 0 | 0 | 0 | 0 | 0.084862 | 0.293355 | 617 | 25 | 76 | 24.68 | 0.692661 | 0.072934 | 0 | 0.444444 | 1 | 0 | 0.12807 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.055556 | 0 | 0.277778 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
e6d25f836c1a52651d9a1aeabd51d86d1dd5acf9 | 2,538 | py | Python | view/SockTab.py | uname/PySockDebuger | 673939d55d842206735fec3bc6beb7c81920fcd4 | [
"Apache-2.0"
] | 8 | 2015-09-24T06:53:45.000Z | 2019-11-25T07:20:08.000Z | view/SockTab.py | uname/PySockDebuger | 673939d55d842206735fec3bc6beb7c81920fcd4 | [
"Apache-2.0"
] | null | null | null | view/SockTab.py | uname/PySockDebuger | 673939d55d842206735fec3bc6beb7c81920fcd4 | [
"Apache-2.0"
] | 5 | 2015-12-23T13:32:55.000Z | 2019-11-25T07:19:23.000Z | #-*- coding: utf-8 -*-
from PyQt4 import QtGui
from ui.AppIcons import *
import config
from net import socktypes
from form.SocketForm import SocketForm
class SockTab(QtGui.QTabWidget):
def __init__(self, parent=None):
QtGui.QTabWidget.__init__(self, parent)
self.setMovable(False)
self.forms =... | 32.126582 | 89 | 0.584712 | 282 | 2,538 | 5.117021 | 0.258865 | 0.074844 | 0.058212 | 0.060984 | 0.311157 | 0.257103 | 0.257103 | 0.257103 | 0.231462 | 0.162162 | 0 | 0.008441 | 0.299842 | 2,538 | 78 | 90 | 32.538462 | 0.803602 | 0.008274 | 0 | 0.172414 | 0 | 0 | 0.02345 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.086207 | 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 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
e6d60b304effa7093ea518e8b047d5f4889f3543 | 400 | py | Python | moneyed/utils.py | FractalWire/py-moneyed | ff66ce9be97219bcb09c78bef91cddf31ecacf83 | [
"BSD-3-Clause"
] | null | null | null | moneyed/utils.py | FractalWire/py-moneyed | ff66ce9be97219bcb09c78bef91cddf31ecacf83 | [
"BSD-3-Clause"
] | null | null | null | moneyed/utils.py | FractalWire/py-moneyed | ff66ce9be97219bcb09c78bef91cddf31ecacf83 | [
"BSD-3-Clause"
] | null | null | null | class cached_property(object):
"""
Decorator that creates converts a method with a single
self argument into a property cached on the instance.
"""
def __init__(self, func):
self.func = func
self.__doc__ = getattr(func, '__doc__')
def __get__(self, instance, type):
res =... | 30.769231 | 73 | 0.655 | 50 | 400 | 4.74 | 0.58 | 0.135021 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.25 | 400 | 12 | 74 | 33.333333 | 0.79 | 0.27 | 0 | 0 | 0 | 0 | 0.025735 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.285714 | false | 0 | 0 | 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 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
e6d9fda62391f1e41b3de5761049ebbdce8ab904 | 458 | py | Python | XCTF2020/lambda/make.py | Mem2019/MyCTFChallenges | cae1e7435739b9949610771cea7771014e896b18 | [
"MIT"
] | 6 | 2018-06-21T00:50:23.000Z | 2021-07-06T06:21:04.000Z | XCTF2020/lambda/make.py | Mem2019/MyCTFChallenges | cae1e7435739b9949610771cea7771014e896b18 | [
"MIT"
] | null | null | null | XCTF2020/lambda/make.py | Mem2019/MyCTFChallenges | cae1e7435739b9949610771cea7771014e896b18 | [
"MIT"
] | 3 | 2018-10-27T13:12:49.000Z | 2021-06-02T05:37:12.000Z | import os
for i in range(0,1):
# randomly generate flag and lambda expression
os.system("python3 compiler.py > expr.h")
# create directory
dir_name = "chall%u" % i
os.mkdir(dir_name)
# generate binary and move it to directory
os.system("gcc -Wall -s main.c -o lambda")
os.system("rm expr.h")
os.system("python3... | 32.714286 | 64 | 0.679039 | 80 | 458 | 3.8125 | 0.5125 | 0.157377 | 0.098361 | 0.098361 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.010336 | 0.155022 | 458 | 14 | 64 | 32.714286 | 0.777778 | 0.222707 | 0 | 0 | 1 | 0 | 0.399433 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.1 | 0 | 0.1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
e6dd75ad18669913f6e0d0ecfbd49070d07ba703 | 2,748 | py | Python | core/cache/base.py | prorevizor/noc | 37e44b8afc64318b10699c06a1138eee9e7d6a4e | [
"BSD-3-Clause"
] | 84 | 2017-10-22T11:01:39.000Z | 2022-02-27T03:43:48.000Z | core/cache/base.py | prorevizor/noc | 37e44b8afc64318b10699c06a1138eee9e7d6a4e | [
"BSD-3-Clause"
] | 22 | 2017-12-11T07:21:56.000Z | 2021-09-23T02:53:50.000Z | core/cache/base.py | prorevizor/noc | 37e44b8afc64318b10699c06a1138eee9e7d6a4e | [
"BSD-3-Clause"
] | 23 | 2017-12-06T06:59:52.000Z | 2022-02-24T00:02:25.000Z | # ----------------------------------------------------------------------
# BaseCache
# ----------------------------------------------------------------------
# Copyright (C) 2007-2017 The NOC Project
# See LICENSE for details
# ----------------------------------------------------------------------
# Python modules
imp... | 28.040816 | 92 | 0.532023 | 319 | 2,748 | 4.510972 | 0.288401 | 0.068798 | 0.093815 | 0.107019 | 0.211953 | 0.173732 | 0.134816 | 0.134816 | 0.065323 | 0.065323 | 0 | 0.004571 | 0.283479 | 2,748 | 97 | 93 | 28.329897 | 0.726257 | 0.209971 | 0 | 0.081633 | 0 | 0 | 0.040299 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.22449 | false | 0.020408 | 0.081633 | 0.081633 | 0.489796 | 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 | 0 | 0 | 0 | 1 |
e6e2b50e281e2643927b6e8395b1c7f990c0dc43 | 878 | py | Python | sensor.py | dscplatform/facesensor | fb13b92ef2335c84d62def3cfbde7f97524afab5 | [
"MIT"
] | null | null | null | sensor.py | dscplatform/facesensor | fb13b92ef2335c84d62def3cfbde7f97524afab5 | [
"MIT"
] | null | null | null | sensor.py | dscplatform/facesensor | fb13b92ef2335c84d62def3cfbde7f97524afab5 | [
"MIT"
] | null | null | null | import sys
import os
import asyncio
import dscframework
import json
import keras
from keras.models import load_model
from data import build_dataset
import numpy as np
version = 1
os.environ["TF_CPP_MIN_LOG_LEVEL"] = "2"
model = load_model(("export/mdl_v%d.h5")%(version))
async def on_facedetect(head, data):
print... | 24.388889 | 59 | 0.703872 | 131 | 878 | 4.519084 | 0.534351 | 0.040541 | 0.033784 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.015007 | 0.165148 | 878 | 35 | 60 | 25.085714 | 0.792633 | 0.158314 | 0 | 0 | 0 | 0 | 0.118852 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.375 | 0 | 0.375 | 0.125 | 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 | 0 | 0 | 0 | 1 |
e6e92ca333c6497da8fdab3208d695e600e0bef5 | 284 | py | Python | scenarios/debit_update/executable.py | trenton42/txbalanced | 9ee1b906d75b4b2fc3d2f5424dc3bbb9886c2b14 | [
"MIT"
] | null | null | null | scenarios/debit_update/executable.py | trenton42/txbalanced | 9ee1b906d75b4b2fc3d2f5424dc3bbb9886c2b14 | [
"MIT"
] | null | null | null | scenarios/debit_update/executable.py | trenton42/txbalanced | 9ee1b906d75b4b2fc3d2f5424dc3bbb9886c2b14 | [
"MIT"
] | null | null | null | import balanced
balanced.configure('ak-test-1o9QKwUCrwstHWO5sGxICtIJdQXFTjnrV')
debit = balanced.Debit.fetch('/debits/WD55Z5kh4Onm0x0NkeuovrEs')
debit.description = 'New description for debit'
debit.meta = {
'facebook.id': '1234567890',
'anykey': 'valuegoeshere',
}
debit.save() | 25.818182 | 64 | 0.767606 | 28 | 284 | 7.785714 | 0.714286 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.073643 | 0.091549 | 284 | 11 | 65 | 25.818182 | 0.771318 | 0 | 0 | 0 | 0 | 0 | 0.484211 | 0.25614 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.111111 | 0 | 0.111111 | 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 | 0 | 0 | 0 | 0 | 0 | 1 |
e6f86c356408f0f8812b03545fc7513586e96b2d | 2,347 | py | Python | Alignment/OfflineValidation/python/TkAlAllInOneTool/crabWrapper.py | nistefan/cmssw | ea13af97f7f2117a4f590a5e654e06ecd9825a5b | [
"Apache-2.0"
] | null | null | null | Alignment/OfflineValidation/python/TkAlAllInOneTool/crabWrapper.py | nistefan/cmssw | ea13af97f7f2117a4f590a5e654e06ecd9825a5b | [
"Apache-2.0"
] | null | null | null | Alignment/OfflineValidation/python/TkAlAllInOneTool/crabWrapper.py | nistefan/cmssw | ea13af97f7f2117a4f590a5e654e06ecd9825a5b | [
"Apache-2.0"
] | null | null | null | import sys
import os
import subprocess
from TkAlExceptions import AllInOneError
# script which needs to be sourced for use of crab
crabSourceScript = '/afs/cern.ch/cms/ccs/wm/scripts/Crab/crab.sh'
# source the environment variables needed for crab
sourceStr = ( 'cd $CMSSW_BASE/src;'
'source /afs/cern.ch... | 30.480519 | 73 | 0.640392 | 259 | 2,347 | 5.741313 | 0.46332 | 0.033625 | 0.06456 | 0.076664 | 0.108944 | 0.108944 | 0.069939 | 0.069939 | 0.069939 | 0.069939 | 0 | 0.00163 | 0.215594 | 2,347 | 76 | 74 | 30.881579 | 0.806084 | 0.077546 | 0 | 0.163934 | 0 | 0.016393 | 0.163889 | 0.059722 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.098361 | null | null | 0.016393 | 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 | 0 | 0 | 1 |
e6fa029aecd7bbbe549f1853b99933cd8579c03b | 1,315 | py | Python | py/tests/problems/arr/smallest_k1_test.py | bmoretz/Daily-Coding-Problem | f79e062e9f6e7b18b7e95c071fbe71ad104affcb | [
"MIT"
] | 1 | 2020-06-26T13:28:43.000Z | 2020-06-26T13:28:43.000Z | py/tests/problems/arr/smallest_k1_test.py | bmoretz/Daily-Coding-Problem | f79e062e9f6e7b18b7e95c071fbe71ad104affcb | [
"MIT"
] | 7 | 2021-11-18T19:46:08.000Z | 2022-03-12T01:03:01.000Z | py/tests/problems/arr/smallest_k1_test.py | bmoretz/Daily-Coding-Problem | f79e062e9f6e7b18b7e95c071fbe71ad104affcb | [
"MIT"
] | null | null | null | import unittest
from problems.arr import smallest_k1
class Test_SmallestK1(unittest.TestCase):
def setUp(self):
pass
def test_none(self):
arr = None
k = 3
actual = smallest_k1(arr, k)
expected = None
assert actual == expected
def test_case1(self):
... | 19.338235 | 54 | 0.469962 | 190 | 1,315 | 3.178947 | 0.194737 | 0.115894 | 0.15894 | 0.188742 | 0.720199 | 0.630795 | 0.630795 | 0.630795 | 0.478477 | 0.427152 | 0 | 0.134008 | 0.398479 | 1,315 | 68 | 55 | 19.338235 | 0.629583 | 0 | 0 | 0.536585 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.146341 | 1 | 0.170732 | false | 0.02439 | 0.04878 | 0 | 0.243902 | 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 | 0 | 0 | 0 | 0 | 0 | 1 |
e6fa4dfd2879f906cde8865c1e3aae6169901901 | 988 | py | Python | src/xleapp/templating/_partials/index.py | flamusdiu/xleapp | 27379a0a617cb31f12fad63dabcefd8793116c67 | [
"MIT"
] | 10 | 2021-09-25T20:52:39.000Z | 2022-02-24T15:29:09.000Z | src/xleapp/templating/_partials/index.py | flamusdiu/xleapp | 27379a0a617cb31f12fad63dabcefd8793116c67 | [
"MIT"
] | 1 | 2021-11-24T15:06:51.000Z | 2021-11-24T15:10:16.000Z | src/xleapp/templating/_partials/index.py | flamusdiu/xleapp | 27379a0a617cb31f12fad63dabcefd8793116c67 | [
"MIT"
] | null | null | null | from dataclasses import dataclass, field
import xleapp.templating as templating
from xleapp._authors import __authors__, __contributors__
from ..html import Contributor, HtmlPage, Template
@dataclass
class Index(HtmlPage):
"""Main index page for HTML report
Attributes:
authors (list): list of auth... | 25.333333 | 73 | 0.665992 | 102 | 988 | 6.215686 | 0.362745 | 0.089905 | 0.031546 | 0.07571 | 0.091483 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.247976 | 988 | 38 | 74 | 26 | 0.853297 | 0.194332 | 0 | 0 | 0 | 0 | 0.006729 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.111111 | false | 0 | 0.222222 | 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 | 0 | 0 | 1 | 0 | 0 | 1 |
fc04ae77bd6f194c325456760ad69e28843821b1 | 1,443 | py | Python | OutSideGATE2/02fetchdata/cleanup/zbackup.1getNumOfLinks.py | An1ndya/KnowledgeGraph | 568aa81781b8e3d6543f403281c8be5521425314 | [
"MIT"
] | 2 | 2022-02-06T11:04:56.000Z | 2022-03-23T09:42:14.000Z | OutSideGATE2/02fetchdata/cleanup/zbackup.1getNumOfLinks.py | An1ndya/KnowledgeGraph | 568aa81781b8e3d6543f403281c8be5521425314 | [
"MIT"
] | 2 | 2021-03-31T18:49:13.000Z | 2021-12-13T19:49:40.000Z | OutSideGATE2/02fetchdata/cleanup/zbackup.1getNumOfLinks.py | An1ndya/KnowledgeGraph | 568aa81781b8e3d6543f403281c8be5521425314 | [
"MIT"
] | 2 | 2019-04-19T08:40:59.000Z | 2019-06-21T15:10:39.000Z | import requests
import re
#data = requests.get('http://dbpedia.org/data/Alice_and_Bob.json').json()
#print(data)
def getNumberOfLinks(url):
ret = 0
try:
url_json = str(url)+".json"
data = requests.get(url_json).json()
datastr = str(data);
# print(datastr)
ret = datastr... | 22.546875 | 73 | 0.497574 | 161 | 1,443 | 4.341615 | 0.397516 | 0.030043 | 0.042918 | 0.051502 | 0.082976 | 0.082976 | 0.082976 | 0 | 0 | 0 | 0 | 0.005495 | 0.369369 | 1,443 | 64 | 74 | 22.546875 | 0.762637 | 0.096327 | 0 | 0.191489 | 0 | 0 | 0.065435 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.042553 | false | 0.06383 | 0.042553 | 0 | 0.148936 | 0.021277 | 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 | 0 | 0 | 0 | 1 |
fc0de21fdf46c73322cbf718bb8d9c8828e8f4b9 | 4,365 | py | Python | src/biokbase/narrative/tests/test_kbtypes.py | jmchandonia/narrative | 13895904956b31f2d51440d94473cd05ecca1e60 | [
"MIT"
] | null | null | null | src/biokbase/narrative/tests/test_kbtypes.py | jmchandonia/narrative | 13895904956b31f2d51440d94473cd05ecca1e60 | [
"MIT"
] | null | null | null | src/biokbase/narrative/tests/test_kbtypes.py | jmchandonia/narrative | 13895904956b31f2d51440d94473cd05ecca1e60 | [
"MIT"
] | null | null | null | """
Unit tests for kbtypes module.
"""
import unittest
import argparse
import StringIO
import os
import re
from biokbase.narrative.common import kbtypes
from traitlets import HasTraits
__author__ = "Dan Gunter <dkgunter@lbl.gov>"
__date__ = "2013-12-09"
class HasVersion(HasTraits):
ver = kbtypes.VersionNumber('0... | 31.630435 | 89 | 0.539748 | 532 | 4,365 | 4.302632 | 0.355263 | 0.02097 | 0.005242 | 0.012232 | 0.11446 | 0.093491 | 0.035824 | 0.035824 | 0.035824 | 0.035824 | 0 | 0.023501 | 0.327377 | 4,365 | 137 | 90 | 31.861314 | 0.756131 | 0.111798 | 0 | 0.166667 | 0 | 0 | 0.108186 | 0.018509 | 0 | 0 | 0 | 0 | 0.0625 | 1 | 0.135417 | false | 0.072917 | 0.072917 | 0 | 0.270833 | 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 | 0 | 0 | 0 | 1 |
fc11ae26f2d2331b72fa9626583d89c4b19fadc7 | 1,089 | py | Python | tests/formatters/iis.py | SamuelePilleri/plaso | f5687f12a89c7309797ccc285da78e855c120579 | [
"Apache-2.0"
] | null | null | null | tests/formatters/iis.py | SamuelePilleri/plaso | f5687f12a89c7309797ccc285da78e855c120579 | [
"Apache-2.0"
] | null | null | null | tests/formatters/iis.py | SamuelePilleri/plaso | f5687f12a89c7309797ccc285da78e855c120579 | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Tests for the Microsoft IIS log file event formatter."""
from __future__ import unicode_literals
import unittest
from plaso.formatters import iis
from tests.formatters import test_lib
class IISLogFileEventFormatterTest(test_lib.EventFormatterTestCase):
"""Tests f... | 27.923077 | 68 | 0.741965 | 114 | 1,089 | 6.780702 | 0.561404 | 0.108668 | 0.028461 | 0.051746 | 0.113842 | 0.113842 | 0.113842 | 0.113842 | 0.113842 | 0 | 0 | 0.001087 | 0.155188 | 1,089 | 38 | 69 | 28.657895 | 0.83913 | 0.236915 | 0 | 0.111111 | 0 | 0 | 0.152228 | 0 | 0 | 0 | 0 | 0.026316 | 0.055556 | 1 | 0.111111 | false | 0 | 0.222222 | 0 | 0.388889 | 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 | 0 | 0 | 0 | 0 | 1 |
fc1b4064289ede168c9da8da50b40d9d2c511477 | 320 | py | Python | auctions/migrations/0004_remove_bid_bidprice.py | huutrungrimp/commerce | 8a22ea44bfca69f96d721a3ebefd7729487db3cf | [
"MIT"
] | null | null | null | auctions/migrations/0004_remove_bid_bidprice.py | huutrungrimp/commerce | 8a22ea44bfca69f96d721a3ebefd7729487db3cf | [
"MIT"
] | null | null | null | auctions/migrations/0004_remove_bid_bidprice.py | huutrungrimp/commerce | 8a22ea44bfca69f96d721a3ebefd7729487db3cf | [
"MIT"
] | null | null | null | # Generated by Django 3.1.2 on 2020-10-29 20:05
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('auctions', '0003_bidlisting'),
]
operations = [
migrations.RemoveField(
model_name='bid',
name='bidprice',
),
]
| 17.777778 | 47 | 0.58125 | 33 | 320 | 5.575758 | 0.848485 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.085202 | 0.303125 | 320 | 17 | 48 | 18.823529 | 0.73991 | 0.140625 | 0 | 0 | 1 | 0 | 0.124542 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.090909 | 0 | 0.363636 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
fc1b513d10c9f203951e395f95e78064d5b351db | 9,940 | py | Python | server/server/users/api/views.py | Eyal-VR/connective | 46857dd79dc58f63c3afb9791ecf8adf853a6c57 | [
"MIT"
] | 1 | 2021-07-22T13:42:02.000Z | 2021-07-22T13:42:02.000Z | server/server/users/api/views.py | Eyal-VR/connective | 46857dd79dc58f63c3afb9791ecf8adf853a6c57 | [
"MIT"
] | 1 | 2021-07-28T05:14:19.000Z | 2021-07-28T05:14:19.000Z | server/server/users/api/views.py | Eyal-VR/connective | 46857dd79dc58f63c3afb9791ecf8adf853a6c57 | [
"MIT"
] | null | null | null | import csv
import io
import os
from django.contrib.auth import get_user_model
from rest_framework import filters, status
from rest_framework.decorators import action
from rest_framework.mixins import ListModelMixin, RetrieveModelMixin, UpdateModelMixin
from rest_framework.response import Response
from rest_framework.v... | 34.158076 | 96 | 0.666801 | 961 | 9,940 | 6.708637 | 0.164412 | 0.023887 | 0.032263 | 0.019544 | 0.671475 | 0.665891 | 0.630991 | 0.630991 | 0.619513 | 0.619513 | 0 | 0.005435 | 0.241046 | 9,940 | 290 | 97 | 34.275862 | 0.849152 | 0.007746 | 0 | 0.5625 | 0 | 0 | 0.043103 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.058333 | false | 0 | 0.054167 | 0.029167 | 0.454167 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 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 | 1 |
fc1f58d5e4dd6997b086361310fa0318affb06e3 | 11,116 | py | Python | python/lbann/core/util.py | samadejacobs/lbann | b0c5fb8658ba514a09f0de1e78158829abf754f3 | [
"Apache-2.0"
] | null | null | null | python/lbann/core/util.py | samadejacobs/lbann | b0c5fb8658ba514a09f0de1e78158829abf754f3 | [
"Apache-2.0"
] | null | null | null | python/lbann/core/util.py | samadejacobs/lbann | b0c5fb8658ba514a09f0de1e78158829abf754f3 | [
"Apache-2.0"
] | null | null | null | """Utility functions for core LBANN functionality.
This submodule mostly contains helper functions to generate classes
from Protobuf messages.
"""
import google.protobuf.descriptor
import google.protobuf.wrappers_pb2
from lbann import lbann_pb2, callbacks_pb2, layers_pb2, metrics_pb2, model_pb2, objective_functions_p... | 44.111111 | 133 | 0.63656 | 1,268 | 11,116 | 5.369085 | 0.220032 | 0.076087 | 0.084606 | 0.126028 | 0.337103 | 0.166863 | 0.125734 | 0.113396 | 0.106052 | 0.106052 | 0 | 0.012877 | 0.287424 | 11,116 | 251 | 134 | 44.286853 | 0.84661 | 0.308384 | 0 | 0.092199 | 1 | 0 | 0.048663 | 0 | 0 | 0 | 0 | 0.003984 | 0 | 1 | 0.035461 | false | 0 | 0.028369 | 0 | 0.092199 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
fc1f73f786e3591f306e127b141909b35b29ce76 | 2,363 | py | Python | main.py | metakirby5/jisho-to-anki | f67ac26621539eff2bc6ed2f69e9475008bbabe1 | [
"MIT"
] | null | null | null | main.py | metakirby5/jisho-to-anki | f67ac26621539eff2bc6ed2f69e9475008bbabe1 | [
"MIT"
] | null | null | null | main.py | metakirby5/jisho-to-anki | f67ac26621539eff2bc6ed2f69e9475008bbabe1 | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
A simple web server which redirects to generate an Anki entry on iOS.
"""
import argparse
import os
import sys
from urllib.parse import urlencode, quote
import argcomplete
import bottle
import termcolor
import jisho
from config import Config
HERE = os.path.abspath... | 22.504762 | 69 | 0.621667 | 288 | 2,363 | 4.920139 | 0.378472 | 0.056457 | 0.035992 | 0.02964 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.006166 | 0.245028 | 2,363 | 104 | 70 | 22.721154 | 0.788117 | 0.047821 | 0 | 0.146667 | 1 | 0 | 0.194556 | 0.033021 | 0 | 0 | 0 | 0 | 0 | 1 | 0.08 | false | 0 | 0.12 | 0.026667 | 0.266667 | 0.013333 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
fc21aa87135fbf2ebba1a48bf7f8da36d5ec02de | 929 | py | Python | intro/numpy/solutions/2_2_data_statistics.py | rossbar/scipy-lecture-notes | 7f74e6925721c43bd81bf0bee34b4805ac4a3b57 | [
"CC-BY-4.0"
] | 2,538 | 2015-01-01T04:58:41.000Z | 2022-03-31T21:06:05.000Z | intro/numpy/solutions/2_2_data_statistics.py | rossbar/scipy-lecture-notes | 7f74e6925721c43bd81bf0bee34b4805ac4a3b57 | [
"CC-BY-4.0"
] | 362 | 2015-01-18T14:16:23.000Z | 2021-11-18T16:24:34.000Z | intro/numpy/solutions/2_2_data_statistics.py | rossbar/scipy-lecture-notes | 7f74e6925721c43bd81bf0bee34b4805ac4a3b57 | [
"CC-BY-4.0"
] | 1,127 | 2015-01-05T14:39:29.000Z | 2022-03-25T08:38:39.000Z | import numpy as np
data = np.loadtxt('../../../data/populations.txt')
year, hares, lynxes, carrots = data.T
populations = data[:,1:]
print(" Hares, Lynxes, Carrots")
print("Mean:", populations.mean(axis=0))
print("Std:", populations.std(axis=0))
j_max_years = np.argmax(populations, axis=0)
print("Max. year:", ... | 28.151515 | 80 | 0.711518 | 146 | 929 | 4.424658 | 0.342466 | 0.03096 | 0.055728 | 0.071207 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.04222 | 0.107643 | 929 | 32 | 81 | 29.03125 | 0.737033 | 0 | 0 | 0 | 0 | 0 | 0.221744 | 0.031216 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.083333 | 0 | 0.083333 | 0.458333 | 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 | 0 | 0 | 0 | 1 | 0 | 1 |
fc21e6673ff3bb3de46812442ec7b05865251bc0 | 923 | py | Python | ca_on_oshawa/__init__.py | tor-councilmatic/scrapers-ca | 821be4ccfc4f5aef3f8272b626b031e225aef7ee | [
"MIT"
] | 2 | 2017-06-02T09:41:28.000Z | 2017-11-17T15:27:07.000Z | ca_on_oshawa/__init__.py | tor-councilmatic/scrapers-ca | 821be4ccfc4f5aef3f8272b626b031e225aef7ee | [
"MIT"
] | null | null | null | ca_on_oshawa/__init__.py | tor-councilmatic/scrapers-ca | 821be4ccfc4f5aef3f8272b626b031e225aef7ee | [
"MIT"
] | null | null | null | from __future__ import unicode_literals
from utils import CanadianJurisdiction
from pupa.scrape import Organization
class Oshawa(CanadianJurisdiction):
classification = 'legislature'
division_id = 'ocd-division/country:ca/csd:3518013'
division_name = 'Oshawa'
name = 'Oshawa City Council'
url = 'ht... | 40.130435 | 137 | 0.722644 | 111 | 923 | 5.81982 | 0.432432 | 0.108359 | 0.088235 | 0.106811 | 0.303406 | 0.303406 | 0.303406 | 0.303406 | 0.303406 | 0.303406 | 0 | 0.014342 | 0.169014 | 923 | 22 | 138 | 41.954545 | 0.827901 | 0 | 0 | 0 | 0 | 0 | 0.176598 | 0.03792 | 0 | 0 | 0 | 0 | 0 | 1 | 0.058824 | false | 0 | 0.176471 | 0 | 0.588235 | 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 | 0 | 0 | 1 | 0 | 0 | 1 |
fc2235b2210c965a511c2bd4509fb4685f127de6 | 598 | py | Python | leetcode/0133_Clone_Graph/result.py | theck17/notes | f32f0f4b8f821b1ed38d173ef0913efddd094b91 | [
"MIT"
] | null | null | null | leetcode/0133_Clone_Graph/result.py | theck17/notes | f32f0f4b8f821b1ed38d173ef0913efddd094b91 | [
"MIT"
] | null | null | null | leetcode/0133_Clone_Graph/result.py | theck17/notes | f32f0f4b8f821b1ed38d173ef0913efddd094b91 | [
"MIT"
] | null | null | null | # !/usr/bin/env python3
# Author: C.K
# Email: theck17@163.com
# DateTime:2021-09-03 16:21:08
# Description:
class Solution:
def cloneGraph(self, node: 'Node') -> 'Node':
if not node:
return node
m = {node: Node(node.val)}
stack = [node]
while stack:
n = sta... | 23 | 49 | 0.506689 | 75 | 598 | 3.933333 | 0.56 | 0.108475 | 0.081356 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.05291 | 0.367893 | 598 | 25 | 50 | 23.92 | 0.727513 | 0.16388 | 0 | 0 | 0 | 0 | 0.032389 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.0625 | false | 0.0625 | 0 | 0 | 0.25 | 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 | 0 | 0 | 0 | 1 |
fc24c54d369c53b162335119e085c1b00c3f5571 | 513 | py | Python | mindware/components/feature_engineering/transformations/generator/__init__.py | jhj0411jhj/soln-ml | 002ec06bf139b14bc059e0f0438501b31d9ed16a | [
"MIT"
] | 27 | 2021-07-19T09:03:34.000Z | 2022-03-31T06:19:23.000Z | mindware/components/feature_engineering/transformations/generator/__init__.py | jhj0411jhj/soln-ml | 002ec06bf139b14bc059e0f0438501b31d9ed16a | [
"MIT"
] | 4 | 2021-07-15T12:17:10.000Z | 2022-01-26T17:16:58.000Z | mindware/components/feature_engineering/transformations/generator/__init__.py | jhj0411jhj/soln-ml | 002ec06bf139b14bc059e0f0438501b31d9ed16a | [
"MIT"
] | 17 | 2020-05-12T20:24:50.000Z | 2021-07-11T03:31:38.000Z | import os
from mindware.components.feature_engineering.transformations.base_transformer import Transformer
from mindware.components.utils.class_loader import find_components, ThirdPartyComponents
"""
Load the buildin classifiers.
"""
generator_directory = os.path.split(__file__)[0]
_generator = find_components(__packa... | 27 | 96 | 0.826511 | 55 | 513 | 7.345455 | 0.581818 | 0.059406 | 0.108911 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.002137 | 0.087719 | 513 | 18 | 97 | 28.5 | 0.861111 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.125 | false | 0 | 0.375 | 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 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 |
fc26fb7e4f3902cc497c88badf5dc9eac5841bd7 | 8,629 | py | Python | owtf/proxy/main.py | nkrios/owtf | a481d856d2cfd32118d79c372e1ea777cb7035d9 | [
"BSD-3-Clause"
] | 3 | 2019-09-28T14:10:02.000Z | 2022-01-10T04:04:17.000Z | owtf/proxy/main.py | samhaxr/owtf | 5d24be34a8303bb7234e0154a91d0755c90533d2 | [
"BSD-3-Clause"
] | 2 | 2021-03-11T07:26:39.000Z | 2022-02-11T00:12:20.000Z | owtf/proxy/main.py | samhaxr/owtf | 5d24be34a8303bb7234e0154a91d0755c90533d2 | [
"BSD-3-Clause"
] | 2 | 2019-06-10T02:43:25.000Z | 2020-10-31T15:45:57.000Z | """
owtf.proxy.main
~~~~~~~~~~~~~~~
"""
import logging
import os
import re
import socket
import tornado
import tornado.httpserver
import tornado.ioloop
import tornado.options
import tornado.web
from owtf.lib.owtf_process import OWTFProcess
from owtf.proxy.proxy import ProxyHandler
from owtf.settings import (
BLAC... | 40.32243 | 119 | 0.667285 | 1,014 | 8,629 | 5.477318 | 0.260355 | 0.118833 | 0.053835 | 0.024847 | 0.202197 | 0.117213 | 0.044653 | 0.015844 | 0.015844 | 0 | 0 | 0.00263 | 0.250782 | 8,629 | 213 | 120 | 40.511737 | 0.856458 | 0.231313 | 0 | 0.096296 | 0 | 0 | 0.042042 | 0 | 0 | 0 | 0 | 0 | 0.037037 | 1 | 0.02963 | false | 0.059259 | 0.103704 | 0 | 0.140741 | 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 | 0 | 0 | 0 | 1 |
fc2f253773f8528ffdba60f502842a72a7810ae2 | 1,633 | py | Python | python/network/Foundations-of-Python-Network-Programming/foundations-of-python-network-programming/foundations-of-python-network-programming/python2/05/blocks.py | bosserbosser/codetest | 987563900d912e891b53eeda8e2cf36f3c769430 | [
"Apache-2.0"
] | 1 | 2018-01-15T08:38:09.000Z | 2018-01-15T08:38:09.000Z | python/network/Foundations-of-Python-Network-Programming/foundations-of-python-network-programming/foundations-of-python-network-programming/python2/05/blocks.py | bosserbosser/codetest | 987563900d912e891b53eeda8e2cf36f3c769430 | [
"Apache-2.0"
] | null | null | null | python/network/Foundations-of-Python-Network-Programming/foundations-of-python-network-programming/foundations-of-python-network-programming/python2/05/blocks.py | bosserbosser/codetest | 987563900d912e891b53eeda8e2cf36f3c769430 | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python
# Foundations of Python Network Programming - Chapter 5 - blocks.py
# Sending data one block at a time.
import socket, struct, sys
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
HOST = sys.argv.pop() if len(sys.argv) == 3 else '127.0.0.1'
PORT = 1060
format = struct.Struct('!I') # for me... | 28.649123 | 74 | 0.619106 | 232 | 1,633 | 4.331897 | 0.482759 | 0.027861 | 0.035821 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.016077 | 0.238212 | 1,633 | 56 | 75 | 29.160714 | 0.791801 | 0.097367 | 0 | 0.044444 | 0 | 0 | 0.169388 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.022222 | null | null | 0.088889 | 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 | 0 | 0 | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.