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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
86a8e1ed877d30bb9fe2c31cbcb8f214021f1ba6 | 2,006 | py | Python | setup.py | pasinskim/mender-python-client | d6f3dc86ec46b0b249a112c5037bea579266e649 | [
"Apache-2.0"
] | null | null | null | setup.py | pasinskim/mender-python-client | d6f3dc86ec46b0b249a112c5037bea579266e649 | [
"Apache-2.0"
] | 71 | 2020-12-21T05:08:13.000Z | 2022-01-31T02:04:26.000Z | setup.py | pasinskim/mender-python-client | d6f3dc86ec46b0b249a112c5037bea579266e649 | [
"Apache-2.0"
] | 11 | 2020-12-02T14:46:58.000Z | 2021-12-02T06:43:25.000Z | # Copyright 2021 Northern.tech AS
#
# 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 ag... | 37.849057 | 82 | 0.698903 | 254 | 2,006 | 5.413386 | 0.590551 | 0.043636 | 0.039273 | 0.023273 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.009014 | 0.170489 | 2,006 | 52 | 83 | 38.576923 | 0.817308 | 0.289133 | 0 | 0 | 0 | 0 | 0.378187 | 0.067989 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.055556 | 0 | 0.055556 | 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 | 0 | 0 | 1 | 0 |
86a985b6e0366a5f31612b64e590684791f59ced | 740 | py | Python | Q295-v2.py | Linchin/python_leetcode_git | 3d08ab04bbdbd2ce268f33c501fbb149662872c7 | [
"MIT"
] | null | null | null | Q295-v2.py | Linchin/python_leetcode_git | 3d08ab04bbdbd2ce268f33c501fbb149662872c7 | [
"MIT"
] | null | null | null | Q295-v2.py | Linchin/python_leetcode_git | 3d08ab04bbdbd2ce268f33c501fbb149662872c7 | [
"MIT"
] | null | null | null | """
295
find median from data stream
hard
"""
from heapq import *
class MedianFinder:
# max heap and min heap
def __init__(self):
"""
initialize your data structure here.
"""
self.hi = []
self.lo = []
def addNum(self, num: int) -> None:
heappush(self.lo,... | 18.5 | 53 | 0.558108 | 100 | 740 | 4.09 | 0.42 | 0.117359 | 0.066015 | 0.05379 | 0.161369 | 0.161369 | 0.161369 | 0.161369 | 0.161369 | 0.161369 | 0 | 0.018975 | 0.287838 | 740 | 40 | 54 | 18.5 | 0.757116 | 0.131081 | 0 | 0.105263 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.157895 | false | 0 | 0.052632 | 0 | 0.368421 | 0.105263 | 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 | 0 | 1 | 0 |
86a988c6aa7f35cfd3902d0931e8d87597572497 | 3,445 | py | Python | raisimPy/examples/newtonsCradle.py | mstoelzle/raisimLib | 81f33a1b82f296e9622f950bc292f61bee2d2c2f | [
"Apache-2.0"
] | null | null | null | raisimPy/examples/newtonsCradle.py | mstoelzle/raisimLib | 81f33a1b82f296e9622f950bc292f61bee2d2c2f | [
"Apache-2.0"
] | null | null | null | raisimPy/examples/newtonsCradle.py | mstoelzle/raisimLib | 81f33a1b82f296e9622f950bc292f61bee2d2c2f | [
"Apache-2.0"
] | null | null | null | import os
import numpy as np
import raisimpy as raisim
import math
import time
raisim.World.setLicenseFile(os.path.dirname(os.path.abspath(__file__)) + "/../../rsc/activation.raisim")
world = raisim.World()
ground = world.addGround()
world.setTimeStep(0.001)
world.setMaterialPairProp("steel", "steel", 0.1, 1.0, 0.0)
... | 32.196262 | 134 | 0.722787 | 565 | 3,445 | 4.369912 | 0.180531 | 0.024301 | 0.045362 | 0.051033 | 0.260024 | 0.214662 | 0.131227 | 0.0968 | 0.049413 | 0.049413 | 0 | 0.105179 | 0.092017 | 3,445 | 106 | 135 | 32.5 | 0.684143 | 0 | 0 | 0 | 0 | 0 | 0.051669 | 0.028447 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 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 | 0 | 0 | 0 | 0 | 0 | 1 | 0 |
86aa12779a6111083d5f447b8a7b523841c60e96 | 15,132 | py | Python | nova/virt/hyperv/volumeops.py | viveknandavanam/nova | 556377b6915936467436c9d5bb33bc0e22244e1e | [
"Apache-2.0"
] | 1 | 2019-07-29T10:30:24.000Z | 2019-07-29T10:30:24.000Z | nova/virt/hyperv/volumeops.py | viveknandavanam/nova | 556377b6915936467436c9d5bb33bc0e22244e1e | [
"Apache-2.0"
] | 11 | 2017-06-19T01:28:55.000Z | 2017-06-23T02:01:47.000Z | nova/virt/hyperv/volumeops.py | viveknandavanam/nova | 556377b6915936467436c9d5bb33bc0e22244e1e | [
"Apache-2.0"
] | 3 | 2018-04-04T15:15:01.000Z | 2018-04-19T18:14:25.000Z | # Copyright 2012 Pedro Navarro Perez
# Copyright 2013 Cloudbase Solutions Srl
# 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... | 41.231608 | 79 | 0.630849 | 1,727 | 15,132 | 5.161552 | 0.177186 | 0.098945 | 0.02827 | 0.037918 | 0.345075 | 0.292461 | 0.242876 | 0.229527 | 0.185102 | 0.148082 | 0 | 0.002074 | 0.298837 | 15,132 | 366 | 80 | 41.344262 | 0.838077 | 0.114063 | 0 | 0.249057 | 0 | 0 | 0.072011 | 0.003369 | 0 | 0 | 0 | 0 | 0 | 1 | 0.124528 | false | 0.015094 | 0.041509 | 0.015094 | 0.279245 | 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 | 0 | 0 | 1 | 0 |
86aa70a303cf42efa31de488c8f84aac08996583 | 1,326 | py | Python | -Loan-Approval-Analysis/code.py | lakshit-sharma/greyatom-python-for-data-science | 55a6e5a4c54a4f7135cc09fb287d2f2fa1d36413 | [
"MIT"
] | null | null | null | -Loan-Approval-Analysis/code.py | lakshit-sharma/greyatom-python-for-data-science | 55a6e5a4c54a4f7135cc09fb287d2f2fa1d36413 | [
"MIT"
] | null | null | null | -Loan-Approval-Analysis/code.py | lakshit-sharma/greyatom-python-for-data-science | 55a6e5a4c54a4f7135cc09fb287d2f2fa1d36413 | [
"MIT"
] | null | null | null | # --------------
# Importing header files
import numpy as np
import pandas as pd
from scipy.stats import mode
# code starts here
bank = pd.read_csv(path)
categorical_var = bank.select_dtypes(include = 'object')
print(categorical_var)
numerical_var = bank.select_dtypes(include = 'number')
print(numeric... | 24.109091 | 125 | 0.69457 | 185 | 1,326 | 4.713514 | 0.443243 | 0.045872 | 0.029817 | 0.043578 | 0.059633 | 0 | 0 | 0 | 0 | 0 | 0 | 0.015071 | 0.149321 | 1,326 | 54 | 126 | 24.555556 | 0.757979 | 0.082202 | 0 | 0 | 0 | 0 | 0.146932 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.12 | 0 | 0.12 | 0.24 | 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 | 0 | 1 | 0 |
86aa77866191f8899234ee88d0a38f765c6e8d3e | 7,673 | py | Python | others/train_RNN.py | jacobswan1/Video2Commonsense | 4dcef76360a29702fd90b7030a39a123da6db19e | [
"MIT"
] | 31 | 2021-01-07T00:42:05.000Z | 2022-01-18T16:44:09.000Z | others/train_RNN.py | jacobswan1/Video2Commonsense | 4dcef76360a29702fd90b7030a39a123da6db19e | [
"MIT"
] | 7 | 2021-01-07T00:41:28.000Z | 2021-12-01T09:29:49.000Z | others/train_RNN.py | jacobswan1/Video2Commonsense | 4dcef76360a29702fd90b7030a39a123da6db19e | [
"MIT"
] | 4 | 2021-02-04T04:55:20.000Z | 2021-07-25T06:50:44.000Z | ''' Training Scropt for V2C captioning task. '''
__author__ = 'Jacob Zhiyuan Fang'
import os
import numpy as np
from opts import *
from utils.utils import *
import torch.optim as optim
from model.Model import Model
from torch.utils.data import DataLoader
from utils.dataloader import VideoDataset
from model.transforme... | 41.475676 | 121 | 0.571224 | 975 | 7,673 | 4.208205 | 0.248205 | 0.021935 | 0.014623 | 0.015598 | 0.222033 | 0.1728 | 0.167926 | 0.140873 | 0.120887 | 0.066293 | 0 | 0.008246 | 0.304574 | 7,673 | 185 | 122 | 41.475676 | 0.760682 | 0.112472 | 0 | 0.104839 | 0 | 0.008065 | 0.160601 | 0.03212 | 0 | 0 | 0 | 0 | 0 | 1 | 0.016129 | false | 0 | 0.080645 | 0 | 0.096774 | 0.048387 | 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 | 0 | 1 | 0 |
86ab2a7a0d57050e80f3f20e1f2f61131ca45a9a | 487 | py | Python | new-influx-client.py | benlamonica/energy-monitor | 86714a365c91cc05c265de81bce191ff4ab585f8 | [
"MIT"
] | null | null | null | new-influx-client.py | benlamonica/energy-monitor | 86714a365c91cc05c265de81bce191ff4ab585f8 | [
"MIT"
] | null | null | null | new-influx-client.py | benlamonica/energy-monitor | 86714a365c91cc05c265de81bce191ff4ab585f8 | [
"MIT"
] | null | null | null | import influxdb_client
from influxdb_client import InfluxDBClient
bucket = "python-client-sandbox"
org = "Energy Monitor"
token = "miQdAvNXHiNDVVzPzV5FpkCaR_8qdQ-L1FlPCOXQPI325Kbrh1fgfhkcDUZ4FepaebDdpZ-A1gmtnnjU0_hViA=="
url = "http://localhost:9999"
client = InfluxDBClient(url=url, token=token, org=org)
writeApi = c... | 40.583333 | 148 | 0.755647 | 57 | 487 | 6.298246 | 0.649123 | 0.077994 | 0.072423 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.038117 | 0.084189 | 487 | 11 | 149 | 44.272727 | 0.766816 | 0 | 0 | 0 | 0 | 0 | 0.457906 | 0.223819 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.222222 | 0 | 0.222222 | 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 | 0 | 0 | 1 | 0 |
86acd0c8a74d48d7a1cf116cc0a40300ec411cd2 | 16,459 | py | Python | utils/thin.py | BnF-jadis/projet | 212b1e7b179a564650fb959d9c2565648178f6b6 | [
"CC-BY-3.0"
] | 5 | 2021-06-17T12:48:45.000Z | 2022-01-22T22:23:44.000Z | utils/thin.py | BnF-jadis/projet | 212b1e7b179a564650fb959d9c2565648178f6b6 | [
"CC-BY-3.0"
] | 7 | 2020-11-13T18:42:14.000Z | 2022-02-10T01:31:07.000Z | utils/thin.py | BnF-jadis/projet | 212b1e7b179a564650fb959d9c2565648178f6b6 | [
"CC-BY-3.0"
] | 1 | 2021-10-17T10:49:45.000Z | 2021-10-17T10:49:45.000Z | # 2020, BackThen Maps
# Coded by Remi Petitpierre https://github.com/RPetitpierre
# For Bibliothèque nationale de France (BnF)
import cv2, thinning, os
import numpy as np
import pandas as pd
import shapefile as shp
from skimage.measure import approximate_polygon
from PIL import Image, ImageDraw
from utils.utils im... | 37.663616 | 125 | 0.584118 | 2,137 | 16,459 | 4.361722 | 0.185307 | 0.005579 | 0.027036 | 0.028323 | 0.244609 | 0.215428 | 0.186032 | 0.145585 | 0.126381 | 0.11694 | 0 | 0.020471 | 0.305486 | 16,459 | 436 | 126 | 37.75 | 0.794944 | 0.178808 | 0 | 0.176471 | 0 | 0.007353 | 0.065613 | 0.001731 | 0 | 0 | 0 | 0 | 0.018382 | 1 | 0.040441 | false | 0 | 0.029412 | 0 | 0.110294 | 0.025735 | 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 | 0 | 1 | 0 |
86acd82b514b30458fa54cefc7db6d72f32e8646 | 875 | py | Python | easy2fa/tests/test_checkinput.py | lutostag/otp | 0792548fa51c489cdc5fcb01a3c6dad1cd453154 | [
"MIT"
] | 3 | 2018-01-22T13:45:12.000Z | 2022-01-27T04:17:52.000Z | easy2fa/tests/test_checkinput.py | lutostag/otp | 0792548fa51c489cdc5fcb01a3c6dad1cd453154 | [
"MIT"
] | 1 | 2017-01-24T23:57:51.000Z | 2017-12-11T14:33:32.000Z | easy2fa/tests/test_checkinput.py | lutostag/otp | 0792548fa51c489cdc5fcb01a3c6dad1cd453154 | [
"MIT"
] | null | null | null | from unittest import TestCase
from unittest.mock import patch
from easy2fa import cli
class TestCheckInput(TestCase):
@patch('builtins.input')
def test_default(self, mock_input):
mock_input.return_value = ''
self.assertEquals(cli.check_input('prompt', default='one'), 'one')
mock_input... | 33.653846 | 74 | 0.634286 | 106 | 875 | 5.075472 | 0.367925 | 0.083643 | 0.105948 | 0.133829 | 0.232342 | 0.232342 | 0.167286 | 0.167286 | 0 | 0 | 0 | 0.001495 | 0.235429 | 875 | 25 | 75 | 35 | 0.802691 | 0 | 0 | 0.1 | 0 | 0 | 0.150857 | 0 | 0 | 0 | 0 | 0 | 0.3 | 1 | 0.15 | false | 0 | 0.15 | 0 | 0.4 | 0.15 | 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 | 0 | 1 | 0 |
86ad342de7b5dfdb142a5dff63b155f6c655c5c6 | 2,845 | py | Python | bert_finetuning/data_loader.py | nps1ngh/adversarial-bert-german-attacks-defense | 3cca292ec4c3c07945f4198ae81e1f671462ed90 | [
"Apache-2.0"
] | null | null | null | bert_finetuning/data_loader.py | nps1ngh/adversarial-bert-german-attacks-defense | 3cca292ec4c3c07945f4198ae81e1f671462ed90 | [
"Apache-2.0"
] | null | null | null | bert_finetuning/data_loader.py | nps1ngh/adversarial-bert-german-attacks-defense | 3cca292ec4c3c07945f4198ae81e1f671462ed90 | [
"Apache-2.0"
] | null | null | null | from torch.utils.data import TensorDataset, DataLoader, RandomSampler, SequentialSampler
from bert_finetuning.data import GermanData
class GermanDataLoader:
def __init__(
self,
data_paths,
model_name,
do_cleansing,
max_sequence_length,
batch_size=8,
... | 31.966292 | 89 | 0.634798 | 284 | 2,845 | 5.96831 | 0.211268 | 0.076696 | 0.090855 | 0.088496 | 0.273746 | 0.218879 | 0.167552 | 0.167552 | 0.167552 | 0.167552 | 0 | 0.000489 | 0.281547 | 2,845 | 88 | 90 | 32.329545 | 0.828767 | 0.01406 | 0 | 0.078431 | 0 | 0 | 0.026147 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.039216 | false | 0 | 0.039216 | 0 | 0.098039 | 0.039216 | 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 | 0 | 1 | 0 |
86ae167dd0746f0077e0b0c327435fcca99f837b | 1,973 | py | Python | data/dirty_mnist.py | Karthik-Ragunath/DDU | b9daae9304bdeb222857884ef8cb3b6b3d004d33 | [
"MIT"
] | 43 | 2021-05-20T14:07:53.000Z | 2022-03-23T12:58:26.000Z | data/dirty_mnist.py | Karthik-Ragunath/DDU | b9daae9304bdeb222857884ef8cb3b6b3d004d33 | [
"MIT"
] | 3 | 2021-09-19T20:49:21.000Z | 2022-03-07T10:25:47.000Z | data/dirty_mnist.py | Karthik-Ragunath/DDU | b9daae9304bdeb222857884ef8cb3b6b3d004d33 | [
"MIT"
] | 8 | 2021-06-26T15:28:45.000Z | 2022-02-19T02:07:05.000Z | import torch
import numpy as np
import torch.utils.data as data
from torch.utils.data import Subset
from data.fast_mnist import create_MNIST_dataset
from data.ambiguous_mnist.ambiguous_mnist_dataset import AmbiguousMNIST
def get_train_valid_loader(root, batch_size, val_seed=1, val_size=0.1, **kwargs):
error_msg... | 34.017241 | 113 | 0.737456 | 276 | 1,973 | 5.007246 | 0.235507 | 0.052098 | 0.050651 | 0.062952 | 0.344428 | 0.254703 | 0.254703 | 0.254703 | 0.254703 | 0.193922 | 0 | 0.006035 | 0.160162 | 1,973 | 57 | 114 | 34.614035 | 0.828002 | 0.03852 | 0 | 0.111111 | 0 | 0 | 0.030111 | 0 | 0 | 0 | 0 | 0 | 0.027778 | 1 | 0.055556 | false | 0 | 0.166667 | 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 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 |
86b032b82ee76fccb3eab7e57dd8b06b6868e592 | 2,633 | py | Python | examples/basic_examples/aws_sns_sqs_middleware_service.py | tranvietanh1991/tomodachi | a815fc718b6cc42dc3fe241abb0e5a5829eba0e8 | [
"MIT"
] | 1 | 2021-11-01T02:18:55.000Z | 2021-11-01T02:18:55.000Z | examples/basic_examples/aws_sns_sqs_middleware_service.py | tranvietanh1991/tomodachi | a815fc718b6cc42dc3fe241abb0e5a5829eba0e8 | [
"MIT"
] | 1 | 2020-12-28T16:16:53.000Z | 2020-12-28T16:16:53.000Z | examples/basic_examples/aws_sns_sqs_middleware_service.py | tranvietanh1991/tomodachi | a815fc718b6cc42dc3fe241abb0e5a5829eba0e8 | [
"MIT"
] | null | null | null | import os
from typing import Any, Callable, Dict
import tomodachi
from tomodachi import aws_sns_sqs, aws_sns_sqs_publish
from tomodachi.discovery import AWSSNSRegistration
from tomodachi.envelope import JsonBase
async def middleware_function(
func: Callable, service: Any, message: Any, topic: str, context: Dict,... | 39.298507 | 122 | 0.692366 | 331 | 2,633 | 5.401813 | 0.404834 | 0.02349 | 0.030201 | 0.017897 | 0.128635 | 0.071588 | 0 | 0 | 0 | 0 | 0 | 0.009629 | 0.211166 | 2,633 | 66 | 123 | 39.893939 | 0.851228 | 0.399544 | 0 | 0 | 0 | 0 | 0.157289 | 0.030691 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.153846 | 0 | 0.384615 | 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 | 0 | 0 | 1 | 0 |
86b0a422c8bc9f85b86cb962da85b578f24f06e1 | 425 | py | Python | ex9.py | ThitsarAung/python-exercises | bca97875e25f9621fc5f58ab1d360426a21efc7f | [
"MIT"
] | null | null | null | ex9.py | ThitsarAung/python-exercises | bca97875e25f9621fc5f58ab1d360426a21efc7f | [
"MIT"
] | null | null | null | ex9.py | ThitsarAung/python-exercises | bca97875e25f9621fc5f58ab1d360426a21efc7f | [
"MIT"
] | null | null | null | types_of_people = 10
x = f"There are {types_of_people} types of people."
binary = "binary"
do_not = "don't"
y = f"Those who know {binary} and those who {do_not}."
print(x)
print(y)
print(f"I said: {x}")
print(f"I also said: '{y}'")
hilarious = False
joke_evaluation = "Isn't that joke so funny?! {}"
print(joke_eval... | 18.478261 | 54 | 0.672941 | 78 | 425 | 3.564103 | 0.538462 | 0.07554 | 0.140288 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.005634 | 0.164706 | 425 | 22 | 55 | 19.318182 | 0.777465 | 0 | 0 | 0 | 0 | 0 | 0.503529 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0 | 0 | 0 | 0.4 | 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 | 0 | 1 | 0 |
86b2f2b4446116811cbd5f27739dd93c92634c93 | 7,182 | py | Python | mmdnn/conversion/caffe/writer.py | 2yz/MMdnn | 13d909e4b591a5043b74b611e412c3c0a5eba0cc | [
"MIT"
] | 3,442 | 2017-11-20T08:39:51.000Z | 2019-05-06T10:51:19.000Z | mmdnn/conversion/caffe/writer.py | 2yz/MMdnn | 13d909e4b591a5043b74b611e412c3c0a5eba0cc | [
"MIT"
] | 430 | 2017-11-29T04:21:48.000Z | 2019-05-06T05:37:37.000Z | mmdnn/conversion/caffe/writer.py | 2yz/MMdnn | 13d909e4b591a5043b74b611e412c3c0a5eba0cc | [
"MIT"
] | 683 | 2017-11-20T08:50:34.000Z | 2019-05-04T04:25:14.000Z | import base64
from google.protobuf import json_format
from importlib import import_module
import json
import numpy as np
import os
import sys
from mmdnn.conversion.caffe.errors import ConversionError
from mmdnn.conversion.caffe.common_graph import fetch_attr_value
from mmdnn.conversion.caffe.utils import get_lower_cas... | 35.731343 | 92 | 0.589112 | 911 | 7,182 | 4.446762 | 0.212953 | 0.037028 | 0.027647 | 0.017773 | 0.152555 | 0.121945 | 0.082942 | 0.071094 | 0.056282 | 0.056282 | 0 | 0.005145 | 0.296436 | 7,182 | 201 | 93 | 35.731343 | 0.796557 | 0.048733 | 0 | 0.085366 | 0 | 0 | 0.082427 | 0.005877 | 0 | 0 | 0 | 0.004975 | 0.006098 | 1 | 0.115854 | false | 0 | 0.097561 | 0.036585 | 0.29878 | 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 | 0 | 0 | 1 | 0 |
86b35d8336f90b1f441624f230053b48e0260a33 | 1,258 | py | Python | week1/85-maximal-rectangle.py | LionTao/algo_weekend | d25756761d47491b8c78ecf8a857080497910c76 | [
"Unlicense"
] | null | null | null | week1/85-maximal-rectangle.py | LionTao/algo_weekend | d25756761d47491b8c78ecf8a857080497910c76 | [
"Unlicense"
] | null | null | null | week1/85-maximal-rectangle.py | LionTao/algo_weekend | d25756761d47491b8c78ecf8a857080497910c76 | [
"Unlicense"
] | null | null | null | """
leetcode-85
给定一个仅包含 0 和 1 , 大小为 rows x cols 的二维二进制矩阵, 找出只包含 1 的最大矩形, 并返回其面积。
"""
from typing import List
class Solution:
def maximalRectangle(self, matrix: List[List[str]]) -> int:
"""
统计直方图然后单调递增栈
"""
rows = len(matrix)
if rows == 0:
return 0
columns ... | 32.25641 | 81 | 0.509539 | 150 | 1,258 | 4.14 | 0.366667 | 0.10628 | 0.028986 | 0.05153 | 0.070853 | 0 | 0 | 0 | 0 | 0 | 0 | 0.028205 | 0.379968 | 1,258 | 39 | 82 | 32.25641 | 0.767949 | 0.075517 | 0 | 0.068966 | 0 | 0 | 0.000883 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.068966 | false | 0 | 0.034483 | 0 | 0.206897 | 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 | 0 | 0 | 1 | 0 |
86b3d8112beb6b385c29392912e1d48581db14c2 | 680 | py | Python | cookie_refresh.py | guoxianru/cookie_pool_lite | 02c4b2009b4c8aa3306ae1f5f7c5decde1eb5f3f | [
"Apache-2.0"
] | null | null | null | cookie_refresh.py | guoxianru/cookie_pool_lite | 02c4b2009b4c8aa3306ae1f5f7c5decde1eb5f3f | [
"Apache-2.0"
] | null | null | null | cookie_refresh.py | guoxianru/cookie_pool_lite | 02c4b2009b4c8aa3306ae1f5f7c5decde1eb5f3f | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
# @Author: GXR
# @CreateTime: 2022-01-20
# @UpdateTime: 2022-01-20
import redis
import config
import cookie_login
from cookie_api import app
red = redis.Redis(
host=config.REDIS_HOST,
port=config.REDIS_PORT,
db=config.REDIS_DB,
decode_responses=True,
)
# 刷新cookie数量
def cooki... | 18.888889 | 59 | 0.679412 | 91 | 680 | 4.758242 | 0.483516 | 0.101617 | 0.036952 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.034862 | 0.198529 | 680 | 35 | 60 | 19.428571 | 0.759633 | 0.136765 | 0 | 0 | 0 | 0 | 0.043029 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.095238 | false | 0 | 0.190476 | 0 | 0.285714 | 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 | 0 | 0 | 1 | 0 |
86b6adb997cbd21ec9e8e9a5843dcd2235408ae3 | 2,997 | py | Python | python/tvm/topi/hexagon/slice_ops/add_subtract_multiply.py | yangulei/tvm | d2cbdf381b68134951bfd7525c6a3a67838e5bdf | [
"Apache-2.0"
] | 4,640 | 2017-08-17T19:22:15.000Z | 2019-11-04T15:29:46.000Z | python/tvm/topi/hexagon/slice_ops/add_subtract_multiply.py | dmlc/tvm | 1e0e9548a6875241267481a4223b4dbf29fa1641 | [
"Apache-2.0"
] | 2,863 | 2017-08-17T19:55:50.000Z | 2019-11-04T17:18:41.000Z | python/tvm/topi/hexagon/slice_ops/add_subtract_multiply.py | yelite/tvm | 7ae919292d42f5858d4db04533bca67b4b5bb44f | [
"Apache-2.0"
] | 1,352 | 2017-08-17T19:30:38.000Z | 2019-11-04T16:09:29.000Z | # Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may ... | 34.056818 | 97 | 0.703704 | 461 | 2,997 | 4.362256 | 0.338395 | 0.038787 | 0.043759 | 0.047737 | 0.24366 | 0.165589 | 0.130781 | 0.052213 | 0 | 0 | 0 | 0.01296 | 0.201869 | 2,997 | 87 | 98 | 34.448276 | 0.827759 | 0.389389 | 0 | 0 | 0 | 0 | 0.053498 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.1 | false | 0 | 0.1 | 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 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 |
86b7ef11958dc926cec50bcec5a016a3d479c413 | 6,634 | py | Python | python_modules/automation/automation/docker/dagster_docker.py | jrouly/dagster | 2b3104db2fc6439050f7825d4b9ebaf39ddf6c0c | [
"Apache-2.0"
] | null | null | null | python_modules/automation/automation/docker/dagster_docker.py | jrouly/dagster | 2b3104db2fc6439050f7825d4b9ebaf39ddf6c0c | [
"Apache-2.0"
] | 1 | 2021-06-21T18:30:02.000Z | 2021-06-25T21:18:39.000Z | python_modules/automation/automation/docker/dagster_docker.py | jrouly/dagster | 2b3104db2fc6439050f7825d4b9ebaf39ddf6c0c | [
"Apache-2.0"
] | null | null | null | import contextlib
import os
from collections import namedtuple
import yaml
from dagster import __version__ as current_dagster_version
from dagster import check
from .ecr import ecr_image, get_aws_account_id, get_aws_region
from .utils import (
execute_docker_build,
execute_docker_push,
execute_docker_tag,... | 38.569767 | 100 | 0.655412 | 832 | 6,634 | 4.925481 | 0.182692 | 0.149097 | 0.039531 | 0.044412 | 0.395803 | 0.351147 | 0.310639 | 0.293558 | 0.255002 | 0.245974 | 0 | 0.002207 | 0.248568 | 6,634 | 171 | 101 | 38.795322 | 0.81986 | 0.162345 | 0 | 0.219298 | 0 | 0 | 0.08967 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.087719 | false | 0 | 0.070175 | 0.008772 | 0.219298 | 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 | 0 | 0 | 1 | 0 |
86b8aba13af33d7534f429cc7d5eda4e95f58299 | 13,716 | py | Python | chrome/test/telemetry/chromeos/login_unittest.py | Fusion-Rom/android_external_chromium_org | d8b126911c6ea9753e9f526bee5654419e1d0ebd | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | 231 | 2015-01-08T09:04:44.000Z | 2021-12-30T03:03:10.000Z | chrome/test/telemetry/chromeos/login_unittest.py | Fusion-Rom/android_external_chromium_org | d8b126911c6ea9753e9f526bee5654419e1d0ebd | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | 1 | 2018-02-10T21:00:08.000Z | 2018-03-20T05:09:50.000Z | chrome/test/telemetry/chromeos/login_unittest.py | Fusion-Rom/android_external_chromium_org | d8b126911c6ea9753e9f526bee5654419e1d0ebd | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | 268 | 2015-01-21T05:53:28.000Z | 2022-03-25T22:09:01.000Z | # Copyright (c) 2012 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import json
import logging
import os
import unittest
from telemetry.core import browser_finder
from telemetry.core import exceptions
from telemetry.core ... | 42.203077 | 80 | 0.646544 | 1,523 | 13,716 | 5.680893 | 0.266579 | 0.011327 | 0.024272 | 0.010633 | 0.196486 | 0.132224 | 0.067846 | 0.043227 | 0.026583 | 0.026583 | 0 | 0.002644 | 0.227763 | 13,716 | 324 | 81 | 42.333333 | 0.814199 | 0.091936 | 0 | 0.07722 | 0 | 0 | 0.269976 | 0.044956 | 0 | 0 | 0 | 0 | 0.092664 | 1 | 0.081081 | false | 0.023166 | 0.03861 | 0.011583 | 0.212355 | 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 | 0 | 0 | 1 | 0 |
86b8d88ae37a5647339fb11a5a98693e6a0c570d | 790 | py | Python | generator/database.py | Neotrinost/Neotrinost.ir | f501b8cf410c1e6ec6cc4e5fce935147b8be1e61 | [
"MIT"
] | 4 | 2021-05-02T17:35:30.000Z | 2021-11-08T12:55:14.000Z | generator/database.py | Neotrinost/Flask_Neotrinost | f501b8cf410c1e6ec6cc4e5fce935147b8be1e61 | [
"MIT"
] | 4 | 2021-07-12T19:08:01.000Z | 2021-08-13T19:37:50.000Z | generator/database.py | Neotrinost/Neotrinost.ir | f501b8cf410c1e6ec6cc4e5fce935147b8be1e61 | [
"MIT"
] | 2 | 2021-08-08T15:10:07.000Z | 2021-11-15T08:59:22.000Z | import sqlite3
class Database:
def get_connection(self):
return sqlite3.connect("./db.sqlite")
def add_card(self, card_title, card_text, card_link_text, card_link_url):
con = self.get_connection()
cur = con.cursor()
create_table_query = "CREATE TABLE IF NOT EXISTS cards('card... | 35.909091 | 106 | 0.596203 | 96 | 790 | 4.604167 | 0.458333 | 0.108597 | 0.135747 | 0.108597 | 0.180995 | 0.180995 | 0.180995 | 0.180995 | 0.180995 | 0.180995 | 0 | 0.00361 | 0.298734 | 790 | 21 | 107 | 37.619048 | 0.794224 | 0 | 0 | 0 | 0 | 0 | 0.316456 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.117647 | false | 0 | 0.058824 | 0.058824 | 0.294118 | 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 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 |
86babfbac8b5c2af0dd5e02e52be427fd0ffce35 | 3,688 | py | Python | crits/backdoors/forms.py | frbapolkosnik/crits | 1278c034f2238e2fe34e65e32ce241128a014df2 | [
"MIT"
] | 22 | 2015-01-14T19:49:32.000Z | 2022-01-26T12:18:52.000Z | crits/backdoors/forms.py | frbapolkosnik/crits | 1278c034f2238e2fe34e65e32ce241128a014df2 | [
"MIT"
] | null | null | null | crits/backdoors/forms.py | frbapolkosnik/crits | 1278c034f2238e2fe34e65e32ce241128a014df2 | [
"MIT"
] | 6 | 2015-01-22T21:25:52.000Z | 2021-04-12T23:24:14.000Z | from django import forms
from django.forms.utils import ErrorList
from crits.campaigns.campaign import Campaign
from crits.core.forms import add_bucketlist_to_form, add_ticket_to_form
from crits.core.handlers import get_item_names, get_source_names
from crits.core.user_tools import get_user_organization
from crits.cor... | 44.97561 | 117 | 0.629067 | 386 | 3,688 | 5.821244 | 0.240933 | 0.057855 | 0.080107 | 0.092123 | 0.274588 | 0.189141 | 0.091678 | 0.091678 | 0.091678 | 0.068536 | 0 | 0.00074 | 0.267354 | 3,688 | 81 | 118 | 45.530864 | 0.830866 | 0.011659 | 0 | 0.112903 | 0 | 0 | 0.063929 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.032258 | false | 0 | 0.129032 | 0 | 0.419355 | 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 | 0 | 0 | 1 | 0 |
86bb18dffc0306993885a2bc13f98c2bb5b4a5b0 | 7,471 | py | Python | src/aprl/agents/monte_carlo.py | fkamrani/adversarial-policies | 53e129c2083f6557ddc18dbb39e4e633a2d7ab9b | [
"MIT"
] | 211 | 2019-02-22T08:07:25.000Z | 2022-03-14T10:44:20.000Z | src/aprl/agents/monte_carlo.py | fkamrani/adversarial-policies | 53e129c2083f6557ddc18dbb39e4e633a2d7ab9b | [
"MIT"
] | 51 | 2019-02-08T01:39:49.000Z | 2022-02-15T21:21:46.000Z | src/aprl/agents/monte_carlo.py | fkamrani/adversarial-policies | 53e129c2083f6557ddc18dbb39e4e633a2d7ab9b | [
"MIT"
] | 41 | 2019-04-23T05:01:49.000Z | 2022-03-16T06:51:19.000Z | """Monte Carlo receding horizon control."""
from abc import ABC, abstractmethod
from multiprocessing import Pipe, Process
import gym
from stable_baselines.common.vec_env import CloudpickleWrapper
from aprl.common.mujoco import MujocoState, ResettableEnv
class MujocoResettableWrapper(ResettableEnv, gym.Wrapper):
... | 37.355 | 99 | 0.63191 | 923 | 7,471 | 5.010834 | 0.277356 | 0.018162 | 0.015568 | 0.012973 | 0.190054 | 0.154162 | 0.125622 | 0.111784 | 0.100973 | 0.081081 | 0 | 0.001293 | 0.275599 | 7,471 | 199 | 100 | 37.542714 | 0.853289 | 0.351492 | 0 | 0.241379 | 0 | 0 | 0.038158 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.146552 | false | 0.025862 | 0.043103 | 0 | 0.267241 | 0.008621 | 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 | 0 | 1 | 0 |
86bb2ac534bb948d97b846d6681e205945c4c9dd | 2,063 | py | Python | machineLearnInAction/bayes.py | xuwening/tensorflowDemo | 65687a61e16f947b7ec8a85d12213f954a71542b | [
"MIT"
] | null | null | null | machineLearnInAction/bayes.py | xuwening/tensorflowDemo | 65687a61e16f947b7ec8a85d12213f954a71542b | [
"MIT"
] | null | null | null | machineLearnInAction/bayes.py | xuwening/tensorflowDemo | 65687a61e16f947b7ec8a85d12213f954a71542b | [
"MIT"
] | null | null | null |
import numpy as np
def loadDataSet():
postingList = [['my', 'dog', 'has', 'flea', 'problems', 'help', 'please'], #[0,0,1,1,1......]
['maybe', 'not', 'take', 'him', 'to', 'dog', 'park', 'stupid'],
['my', 'dalmation', 'is', 'so', 'cute', 'I', 'love', 'him'],
... | 31.738462 | 97 | 0.573921 | 220 | 2,063 | 5.345455 | 0.413636 | 0.006803 | 0.005102 | 0.006803 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.031292 | 0.271934 | 2,063 | 65 | 98 | 31.738462 | 0.751664 | 0.042172 | 0 | 0.04 | 0 | 0 | 0.11404 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.08 | false | 0 | 0.02 | 0 | 0.18 | 0.06 | 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 | 0 | 1 | 0 |
86bd7ed417f64120a297b91ba487086bf72ccb3f | 2,328 | py | Python | cacheable/adapter/PeeweeAdapter.py | d1hotpep/cacheable | 9ea97d6504965179f8fe495b67e466c068719445 | [
"MIT"
] | null | null | null | cacheable/adapter/PeeweeAdapter.py | d1hotpep/cacheable | 9ea97d6504965179f8fe495b67e466c068719445 | [
"MIT"
] | null | null | null | cacheable/adapter/PeeweeAdapter.py | d1hotpep/cacheable | 9ea97d6504965179f8fe495b67e466c068719445 | [
"MIT"
] | null | null | null | import peewee
import playhouse.kv
from time import time
from . import CacheableAdapter
class PeeweeAdapter(CacheableAdapter, peewee.Model):
key = peewee.CharField(max_length=256, unique=True)
value = playhouse.kv.JSONField()
mtime = peewee.IntegerField(default=time)
ttl = peewee.IntegerField(default=... | 24.25 | 72 | 0.537371 | 287 | 2,328 | 4.170732 | 0.303136 | 0.030075 | 0.0401 | 0.028404 | 0.056809 | 0.056809 | 0.016708 | 0 | 0 | 0 | 0 | 0.006532 | 0.342354 | 2,328 | 95 | 73 | 24.505263 | 0.77531 | 0.027491 | 0 | 0.15873 | 0 | 0 | 0.002679 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.111111 | false | 0 | 0.063492 | 0.015873 | 0.333333 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 |
86bf8dc5885e11ca632362fcec2e79f7e5e74050 | 6,006 | py | Python | mmgen/models/architectures/arcface/helpers.py | plutoyuxie/mmgeneration | 0a7f5d16c970de1766ebf049d7a0264fe506504b | [
"Apache-2.0"
] | null | null | null | mmgen/models/architectures/arcface/helpers.py | plutoyuxie/mmgeneration | 0a7f5d16c970de1766ebf049d7a0264fe506504b | [
"Apache-2.0"
] | null | null | null | mmgen/models/architectures/arcface/helpers.py | plutoyuxie/mmgeneration | 0a7f5d16c970de1766ebf049d7a0264fe506504b | [
"Apache-2.0"
] | null | null | null | from collections import namedtuple
import torch
from torch.nn import (AdaptiveAvgPool2d, BatchNorm2d, Conv2d, MaxPool2d,
Module, PReLU, ReLU, Sequential, Sigmoid)
# yapf: disable
"""
ArcFace implementation from [TreB1eN](https://github.com/TreB1eN/InsightFace_Pytorch) # isort:skip # noqa
"""
# ... | 30.180905 | 106 | 0.585914 | 722 | 6,006 | 4.717452 | 0.202216 | 0.076629 | 0.057546 | 0.064886 | 0.534938 | 0.51145 | 0.502642 | 0.502642 | 0.469172 | 0.437463 | 0 | 0.041518 | 0.298202 | 6,006 | 198 | 107 | 30.333333 | 0.766548 | 0.241925 | 0 | 0.5 | 0 | 0 | 0.020306 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.096154 | false | 0 | 0.028846 | 0.009615 | 0.240385 | 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 | 0 | 0 | 1 | 0 |
86bfaf5a13f46371cddc52c365f2b99eb199e27e | 1,694 | py | Python | createplaylist.py | mahi0601/SpotifyPlaylist | 55e30bb4c13f291693b892d6eeccc70b4a769805 | [
"MIT"
] | 47 | 2020-09-21T11:35:10.000Z | 2022-01-17T21:25:39.000Z | createplaylist.py | mahi0601/SpotifyPlaylist | 55e30bb4c13f291693b892d6eeccc70b4a769805 | [
"MIT"
] | 2 | 2021-03-31T17:02:24.000Z | 2021-07-30T08:17:37.000Z | createplaylist.py | mahi0601/SpotifyPlaylist | 55e30bb4c13f291693b892d6eeccc70b4a769805 | [
"MIT"
] | 24 | 2020-09-21T16:45:38.000Z | 2022-03-02T10:50:47.000Z | import os
from spotifyclient import SpotifyClient
def main():
spotify_client = SpotifyClient(os.getenv("SPOTIFY_AUTHORIZATION_TOKEN"),
os.getenv("SPOTIFY_USER_ID"))
# get last played tracks
num_tracks_to_visualise = int(input("How many tracks would you like to visualis... | 42.35 | 118 | 0.725502 | 230 | 1,694 | 5.143478 | 0.36087 | 0.086221 | 0.067625 | 0.050719 | 0.145393 | 0.104818 | 0.065934 | 0.065934 | 0 | 0 | 0 | 0.002909 | 0.188312 | 1,694 | 40 | 119 | 42.35 | 0.857455 | 0.128099 | 0 | 0.083333 | 0 | 0.041667 | 0.366168 | 0.035326 | 0 | 0 | 0 | 0 | 0 | 1 | 0.041667 | false | 0 | 0.083333 | 0 | 0.125 | 0.25 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 |
86c23c7616ed380cf3c80ae082afe689a1c8e0b9 | 7,318 | py | Python | ConvDR/data/preprocess_cast19.py | blazejdolicki/CHEDAR | e4819775e7f6ffa2d6f1ad798ee262f01370b236 | [
"MIT"
] | 1 | 2021-11-10T13:39:16.000Z | 2021-11-10T13:39:16.000Z | ConvDR/data/preprocess_cast19.py | blazejdolicki/CHEDAR | e4819775e7f6ffa2d6f1ad798ee262f01370b236 | [
"MIT"
] | null | null | null | ConvDR/data/preprocess_cast19.py | blazejdolicki/CHEDAR | e4819775e7f6ffa2d6f1ad798ee262f01370b236 | [
"MIT"
] | null | null | null | import argparse
from trec_car import read_data
from tqdm import tqdm
import pickle
import os
import json
import copy
from utils.util import NUM_FOLD
def parse_sim_file(filename):
"""
Reads the deduplicated documents file and stores the
duplicate passage ids into a dictionary
"""
sim_dict = {}
... | 39.556757 | 104 | 0.562859 | 929 | 7,318 | 4.138859 | 0.190527 | 0.020806 | 0.023667 | 0.03381 | 0.261899 | 0.173472 | 0.159428 | 0.105072 | 0.081665 | 0.041092 | 0 | 0.013696 | 0.321536 | 7,318 | 184 | 105 | 39.771739 | 0.760725 | 0.048237 | 0 | 0.064935 | 0 | 0 | 0.101903 | 0.010378 | 0 | 0 | 0 | 0 | 0.006494 | 1 | 0.006494 | false | 0.006494 | 0.051948 | 0 | 0.064935 | 0.051948 | 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 | 0 | 1 | 0 |
86c253258ad8f50c39a576db2e17ac13da5ea1c7 | 15,207 | py | Python | coord_convert/geojson_utils.py | brandonxiang/example-pyQGIS | a61d0321d223d0b82e44bb809521965858fde857 | [
"MIT"
] | 3 | 2017-02-23T08:35:30.000Z | 2018-12-11T05:50:54.000Z | coord_convert/geojson_utils.py | brandonxiang/example-pyQGIS | a61d0321d223d0b82e44bb809521965858fde857 | [
"MIT"
] | null | null | null | coord_convert/geojson_utils.py | brandonxiang/example-pyQGIS | a61d0321d223d0b82e44bb809521965858fde857 | [
"MIT"
] | 2 | 2019-10-22T02:16:50.000Z | 2020-09-28T11:37:48.000Z | __doc__ = 'github: https://github.com/brandonxiang/geojson-python-utils'
import math
from coordTransform_utils import wgs84togcj02
from coordTransform_utils import gcj02tobd09
def linestrings_intersect(line1, line2):
"""
To valid whether linestrings from geojson are intersected with each other.
reference:... | 31.290123 | 125 | 0.572105 | 2,023 | 15,207 | 4.18784 | 0.158675 | 0.024551 | 0.008263 | 0.011213 | 0.283994 | 0.217068 | 0.180241 | 0.153447 | 0.128187 | 0.128187 | 0 | 0.046859 | 0.303939 | 15,207 | 485 | 126 | 31.354639 | 0.753519 | 0.260472 | 0 | 0.196154 | 0 | 0 | 0.069692 | 0 | 0 | 0 | 0 | 0.008247 | 0 | 1 | 0.073077 | false | 0 | 0.011538 | 0 | 0.176923 | 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 | 0 | 0 | 1 | 0 |
86c368ef733994c7aa8778c60fbe8e4bdf94dac9 | 347 | py | Python | 10_days_of_statistics_8_1.py | sercangul/HackerRank | e6d7056babe03baafee8d7f1cacdca7c28b72ded | [
"Apache-2.0"
] | null | null | null | 10_days_of_statistics_8_1.py | sercangul/HackerRank | e6d7056babe03baafee8d7f1cacdca7c28b72ded | [
"Apache-2.0"
] | null | null | null | 10_days_of_statistics_8_1.py | sercangul/HackerRank | e6d7056babe03baafee8d7f1cacdca7c28b72ded | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Mon Jun 3 19:26:47 2019
@author: sercangul
"""
n = 5
xy = [map(int, input().split()) for _ in range(n)]
sx, sy, sx2, sxy = map(sum, zip(*[(x, y, x**2, x * y) for x, y in xy]))
b = (n * sxy - sx * sy) / (n * sx2 - sx**2)
a = (sy / n) - b * (sx / n)
print('... | 24.785714 | 71 | 0.501441 | 68 | 347 | 2.544118 | 0.632353 | 0.034682 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.078358 | 0.227666 | 347 | 14 | 72 | 24.785714 | 0.567164 | 0.285303 | 0 | 0 | 0 | 0 | 0.025 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0 | 0 | 0 | 0.166667 | 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 | 0 | 1 | 0 |
86c4016c71680c25695f7a5d4e332b95ab4759b0 | 450 | py | Python | rlutils/gym/envs/reset_obs/hopper.py | vermouth1992/rl-util | 4c06ab8f5c96a44e58f88cf30146bcb837057112 | [
"Apache-2.0"
] | null | null | null | rlutils/gym/envs/reset_obs/hopper.py | vermouth1992/rl-util | 4c06ab8f5c96a44e58f88cf30146bcb837057112 | [
"Apache-2.0"
] | null | null | null | rlutils/gym/envs/reset_obs/hopper.py | vermouth1992/rl-util | 4c06ab8f5c96a44e58f88cf30146bcb837057112 | [
"Apache-2.0"
] | null | null | null | import gym.envs.mujoco.hopper as hopper
import numpy as np
class HopperEnv(hopper.HopperEnv):
def _get_obs(self):
return np.concatenate([
self.sim.data.qpos.flat[1:],
self.sim.data.qvel.flat,
])
def reset_obs(self, obs):
state = np.insert(obs, 0, 0.)
qp... | 25 | 40 | 0.591111 | 63 | 450 | 4.126984 | 0.460317 | 0.046154 | 0.084615 | 0.123077 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.009259 | 0.28 | 450 | 17 | 41 | 26.470588 | 0.79321 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.142857 | false | 0 | 0.142857 | 0.071429 | 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 | 0 | 0 | 0 | 0 | 1 | 0 |
86c692ea321aa5d6632c79b6a92f458cad0e5a70 | 2,723 | py | Python | ncm/api.py | SDhuangao/netease-cloud-music-dl | 4a970504e1fec0a9848f3920b392aa507d6b3879 | [
"MIT"
] | null | null | null | ncm/api.py | SDhuangao/netease-cloud-music-dl | 4a970504e1fec0a9848f3920b392aa507d6b3879 | [
"MIT"
] | null | null | null | ncm/api.py | SDhuangao/netease-cloud-music-dl | 4a970504e1fec0a9848f3920b392aa507d6b3879 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
import requests
from ncm.encrypt import encrypted_request
from ncm.constants import headers
from ncm.constants import song_download_url
from ncm.constants import get_song_url
from ncm.constants import get_album_url
from ncm.constants import get_artist_url
from ncm.constants import get_playlist... | 27.505051 | 84 | 0.589791 | 338 | 2,723 | 4.553254 | 0.218935 | 0.031189 | 0.062378 | 0.08577 | 0.289799 | 0.261209 | 0.188434 | 0.188434 | 0.092268 | 0.092268 | 0 | 0.019301 | 0.295997 | 2,723 | 98 | 85 | 27.785714 | 0.783516 | 0.136981 | 0 | 0.230769 | 0 | 0 | 0.066915 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.153846 | false | 0 | 0.153846 | 0 | 0.461538 | 0.038462 | 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 | 0 | 1 | 0 |
86c7301877ec46ff5d214d67d7d24373229e91aa | 15,337 | py | Python | book/trees/binary_search_tree.py | Web-Dev-Collaborative/algos | d280581d74ded382094283d931a202eb55fd8369 | [
"CC0-1.0"
] | 153 | 2015-12-24T00:32:23.000Z | 2022-02-24T06:00:29.000Z | book/trees/binary_search_tree.py | Web-Dev-Collaborative/algos | d280581d74ded382094283d931a202eb55fd8369 | [
"CC0-1.0"
] | 78 | 2015-11-17T11:46:15.000Z | 2021-06-28T18:37:58.000Z | book/trees/binary_search_tree.py | rhivent/algo-books-python | c4fa29616ca9a8a15ba40fa12d21fd8f35096d40 | [
"CC0-1.0"
] | 66 | 2015-11-02T03:38:02.000Z | 2022-03-05T17:36:26.000Z | # -*- coding: utf-8 -*-
"""
The `TreeNode` class provides many helper functions that make the work
done in the `BinarySearchTree` class methods much easier. The
constructor for a `TreeNode`, along with these helper functions, is
shown below. As you can see, many of these helper functions help to
classify a node acco... | 37.775862 | 78 | 0.684684 | 2,443 | 15,337 | 4.22718 | 0.16537 | 0.010652 | 0.016268 | 0.008909 | 0.165682 | 0.115716 | 0.071269 | 0.066428 | 0.038733 | 0.038733 | 0 | 0.002461 | 0.258134 | 15,337 | 405 | 79 | 37.869136 | 0.90508 | 0.097346 | 0 | 0.313333 | 0 | 0 | 0.004244 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.153333 | false | 0 | 0 | 0.06 | 0.32 | 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 | 0 | 0 | 1 | 0 |
86c7d4acbb62e0447380b9c4c68ef07bbf5ead1b | 28,677 | py | Python | fire/core.py | adamruth/python-fire | 6912ccd56f50e0f4bb30a0725d95858ef29f3bde | [
"Apache-2.0"
] | 1 | 2020-02-05T04:43:03.000Z | 2020-02-05T04:43:03.000Z | fire/core.py | chesnjak/python-fire | 72604f40314008e562ba47936dcc183b51166b72 | [
"Apache-2.0"
] | null | null | null | fire/core.py | chesnjak/python-fire | 72604f40314008e562ba47936dcc183b51166b72 | [
"Apache-2.0"
] | 1 | 2020-07-15T22:58:25.000Z | 2020-07-15T22:58:25.000Z | # Copyright (C) 2017 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, ... | 36.577806 | 80 | 0.706873 | 3,888 | 28,677 | 5.11214 | 0.147119 | 0.039243 | 0.004931 | 0.003874 | 0.211008 | 0.168897 | 0.133679 | 0.101529 | 0.092725 | 0.092725 | 0 | 0.002512 | 0.222687 | 28,677 | 783 | 81 | 36.624521 | 0.889148 | 0.453569 | 0 | 0.244216 | 0 | 0 | 0.040487 | 0 | 0 | 0 | 0 | 0.003831 | 0.002571 | 1 | 0.03856 | false | 0 | 0.046272 | 0 | 0.14653 | 0.033419 | 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 | 0 | 1 | 0 |
86c845d512d008bf07b10c93c9a059cfaa7474a0 | 1,668 | py | Python | app.py | AmirValeev/auto-ml-classifier | e803fe92d1ec71e87509845ea61ecc46b363bae6 | [
"Apache-2.0"
] | null | null | null | app.py | AmirValeev/auto-ml-classifier | e803fe92d1ec71e87509845ea61ecc46b363bae6 | [
"Apache-2.0"
] | null | null | null | app.py | AmirValeev/auto-ml-classifier | e803fe92d1ec71e87509845ea61ecc46b363bae6 | [
"Apache-2.0"
] | null | null | null | import os, ast
import pandas as pd
from sklearn.svm import SVC
from sklearn.model_selection import train_test_split
from sklearn.preprocessing import OneHotEncoder
from sklearn.compose import make_column_transformer
from sklearn.pipeline import make_pipeline
import pickle
def main():
# Get the dataset from the us... | 33.36 | 126 | 0.668465 | 220 | 1,668 | 4.895455 | 0.495455 | 0.051068 | 0.025998 | 0.038997 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.007331 | 0.182254 | 1,668 | 49 | 127 | 34.040816 | 0.782258 | 0.093525 | 0 | 0 | 0 | 0 | 0.239044 | 0.059761 | 0 | 0 | 0 | 0 | 0 | 1 | 0.027778 | false | 0.027778 | 0.222222 | 0 | 0.25 | 0.25 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 |
86c8b4810cb292d6be03cbb1ee7d68143bb6929f | 512 | py | Python | util/headers.py | giuseppe/quay | a1b7e4b51974edfe86f66788621011eef2667e6a | [
"Apache-2.0"
] | 2,027 | 2019-11-12T18:05:48.000Z | 2022-03-31T22:25:04.000Z | util/headers.py | giuseppe/quay | a1b7e4b51974edfe86f66788621011eef2667e6a | [
"Apache-2.0"
] | 496 | 2019-11-12T18:13:37.000Z | 2022-03-31T10:43:45.000Z | util/headers.py | giuseppe/quay | a1b7e4b51974edfe86f66788621011eef2667e6a | [
"Apache-2.0"
] | 249 | 2019-11-12T18:02:27.000Z | 2022-03-22T12:19:19.000Z | import base64
def parse_basic_auth(header_value):
"""
Attempts to parse the given header value as a Base64-encoded Basic auth header.
"""
if not header_value:
return None
parts = header_value.split(" ")
if len(parts) != 2 or parts[0].lower() != "basic":
return None
try:
... | 21.333333 | 83 | 0.599609 | 66 | 512 | 4.530303 | 0.469697 | 0.147157 | 0.100334 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.036212 | 0.298828 | 512 | 23 | 84 | 22.26087 | 0.796657 | 0.154297 | 0 | 0.285714 | 0 | 0 | 0.016787 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.071429 | false | 0 | 0.071429 | 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 | 0 | 0 | 0 | 0 | 1 | 0 |
86ca3287dbcbbef744a382d06122c372e95e738d | 3,294 | py | Python | cinder/tests/unit/volume/drivers/emc/scaleio/test_delete_volume.py | aarunsai81/netapp | 8f0f7bf9be7f4d9fb9c3846bfc639c90a05f86ba | [
"Apache-2.0"
] | 11 | 2015-08-25T13:11:18.000Z | 2020-10-15T11:29:20.000Z | cinder/tests/unit/volume/drivers/emc/scaleio/test_delete_volume.py | aarunsai81/netapp | 8f0f7bf9be7f4d9fb9c3846bfc639c90a05f86ba | [
"Apache-2.0"
] | 5 | 2018-01-25T11:31:56.000Z | 2019-05-06T23:13:35.000Z | cinder/tests/unit/volume/drivers/emc/scaleio/test_delete_volume.py | aarunsai81/netapp | 8f0f7bf9be7f4d9fb9c3846bfc639c90a05f86ba | [
"Apache-2.0"
] | 11 | 2015-02-20T18:48:24.000Z | 2021-01-30T20:26:18.000Z | # Copyright (c) 2013 - 2015 EMC Corporation.
# 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
#
# Unle... | 39.686747 | 78 | 0.610808 | 361 | 3,294 | 5.443213 | 0.409972 | 0.066158 | 0.045802 | 0.050891 | 0.316031 | 0.304326 | 0.242239 | 0.206616 | 0.206616 | 0 | 0 | 0.012554 | 0.298725 | 3,294 | 82 | 79 | 40.170732 | 0.838095 | 0.248634 | 0 | 0.259259 | 0 | 0 | 0.130095 | 0.091807 | 0 | 0 | 0 | 0 | 0.018519 | 1 | 0.055556 | false | 0 | 0.12963 | 0 | 0.203704 | 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 | 0 | 0 | 1 | 0 |
86ca3cb4e460e6fa964047e9d8e3d1c032b0dafb | 1,233 | py | Python | example-package/transportation_tutorials/__init__.py | chrisc20042001/python-for-transportation-modeling | 677129daa390fcaa6e5cde45960e27d9bd6ca4bf | [
"BSD-3-Clause"
] | null | null | null | example-package/transportation_tutorials/__init__.py | chrisc20042001/python-for-transportation-modeling | 677129daa390fcaa6e5cde45960e27d9bd6ca4bf | [
"BSD-3-Clause"
] | null | null | null | example-package/transportation_tutorials/__init__.py | chrisc20042001/python-for-transportation-modeling | 677129daa390fcaa6e5cde45960e27d9bd6ca4bf | [
"BSD-3-Clause"
] | null | null | null | # -*- coding: utf-8 -*-
__version__ = '1.0.2'
import os
import appdirs
import osmnx as ox
import joblib
import requests
from .files import load_vars, save_vars, cached, inflate_tar, download_zipfile
from .data import data, list_data, problematic
from .tools.view_code import show_file
from . import mapping
cache_dir ... | 20.55 | 79 | 0.721006 | 177 | 1,233 | 4.819209 | 0.480226 | 0.056272 | 0.049238 | 0.03517 | 0.044549 | 0 | 0 | 0 | 0 | 0 | 0 | 0.004859 | 0.16545 | 1,233 | 59 | 80 | 20.898305 | 0.824101 | 0.167883 | 0 | 0 | 0 | 0 | 0.097345 | 0.023599 | 0 | 0 | 0 | 0 | 0 | 1 | 0.030303 | false | 0 | 0.272727 | 0 | 0.30303 | 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 | 0 | 0 | 1 | 0 |
86ca8c2e422d5ab12a80680e14af6535e5befd05 | 2,146 | py | Python | common/common.py | czajowaty/curry-bot | 91bfbd884342a02c6defd057d27d5b1fcd78cb21 | [
"MIT"
] | 3 | 2019-10-09T23:17:55.000Z | 2022-02-01T17:34:27.000Z | common/common.py | czajowaty/curry-bot | 91bfbd884342a02c6defd057d27d5b1fcd78cb21 | [
"MIT"
] | 19 | 2019-10-09T20:42:05.000Z | 2022-02-01T08:22:25.000Z | common/common.py | czajowaty/curry-bot | 91bfbd884342a02c6defd057d27d5b1fcd78cb21 | [
"MIT"
] | 6 | 2020-08-09T20:17:13.000Z | 2022-01-27T23:59:28.000Z | from requests.models import PreparedRequest
def is_valid_url(url):
prepared_request = PreparedRequest()
try:
prepared_request.prepare_url(url, None)
return True
except Exception as e:
return False
class Timestamp: # a speedrun.com style timestamp e.g. "3h 53m 233s 380ms"
def... | 32.029851 | 152 | 0.56384 | 253 | 2,146 | 4.695652 | 0.27668 | 0.060606 | 0.037879 | 0.04798 | 0.176768 | 0.037037 | 0 | 0 | 0 | 0 | 0 | 0.036986 | 0.319664 | 2,146 | 66 | 153 | 32.515152 | 0.776712 | 0.025629 | 0 | 0.140351 | 0 | 0 | 0.010531 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.105263 | false | 0 | 0.017544 | 0.017544 | 0.350877 | 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 | 0 | 0 | 1 | 0 |
86cbceec04afe24550cbee582258380f822dc77d | 5,265 | py | Python | hendrix/test/test_ux.py | anthonyalmarza/hendrix | eebd2a2183cc18ec2267d96a53a70d41b1630ce6 | [
"MIT"
] | null | null | null | hendrix/test/test_ux.py | anthonyalmarza/hendrix | eebd2a2183cc18ec2267d96a53a70d41b1630ce6 | [
"MIT"
] | null | null | null | hendrix/test/test_ux.py | anthonyalmarza/hendrix | eebd2a2183cc18ec2267d96a53a70d41b1630ce6 | [
"MIT"
] | null | null | null | import os
import sys
from . import HendrixTestCase, TEST_SETTINGS
from hendrix.contrib import SettingsError
from hendrix.options import options as hx_options
from hendrix import ux
from mock import patch
class TestMain(HendrixTestCase):
def setUp(self):
super(TestMain, self).setUp()
self.DEFAULTS... | 35.816327 | 77 | 0.637607 | 584 | 5,265 | 5.60274 | 0.229452 | 0.057152 | 0.052262 | 0.039731 | 0.406174 | 0.397005 | 0.382946 | 0.342604 | 0.329768 | 0.260697 | 0 | 0.000768 | 0.25774 | 5,265 | 146 | 78 | 36.061644 | 0.836489 | 0.017094 | 0 | 0.338843 | 0 | 0 | 0.090414 | 0.04161 | 0 | 0 | 0 | 0 | 0.198347 | 1 | 0.132231 | false | 0 | 0.066116 | 0.008264 | 0.223141 | 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 | 0 | 0 | 1 | 0 |
86cc747c2e5f0caead634114a98e5f4a747d16ea | 15,163 | py | Python | local/local_sign.py | EVAyo/chaoxing_auto_sign | 7ae91a5e9aa4d15f57a5419ff3f5a455e151930a | [
"MIT"
] | null | null | null | local/local_sign.py | EVAyo/chaoxing_auto_sign | 7ae91a5e9aa4d15f57a5419ff3f5a455e151930a | [
"MIT"
] | null | null | null | local/local_sign.py | EVAyo/chaoxing_auto_sign | 7ae91a5e9aa4d15f57a5419ff3f5a455e151930a | [
"MIT"
] | null | null | null | # -*- coding: utf8 -*-
import os
import re
import time
import json
import random
import asyncio
from typing import Optional, List, Dict
from aiohttp import ClientSession
from aiohttp.cookiejar import SimpleCookie
from lxml import etree
from bs4 import BeautifulSoup
from config import *
from message import server_chan... | 33.770601 | 149 | 0.485722 | 1,482 | 15,163 | 4.879217 | 0.205128 | 0.023233 | 0.021574 | 0.03319 | 0.366063 | 0.327756 | 0.287097 | 0.277002 | 0.259024 | 0.244088 | 0 | 0.014211 | 0.396689 | 15,163 | 449 | 150 | 33.770601 | 0.776235 | 0.023214 | 0 | 0.394521 | 0 | 0.005479 | 0.130435 | 0.015829 | 0 | 0 | 0 | 0 | 0 | 1 | 0.013699 | false | 0.010959 | 0.035616 | 0 | 0.134247 | 0.008219 | 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 | 0 | 1 | 0 |
86ccfd65a1bb34c39113feed67502cda22587b34 | 4,240 | py | Python | build/scripts-3.6/fit_background_model.py | stahlberggroup/umierrorcorrect | 8ceabe30a87811dad467d04eb5a08d0213065946 | [
"MIT"
] | null | null | null | build/scripts-3.6/fit_background_model.py | stahlberggroup/umierrorcorrect | 8ceabe30a87811dad467d04eb5a08d0213065946 | [
"MIT"
] | null | null | null | build/scripts-3.6/fit_background_model.py | stahlberggroup/umierrorcorrect | 8ceabe30a87811dad467d04eb5a08d0213065946 | [
"MIT"
] | 1 | 2022-01-12T13:51:59.000Z | 2022-01-12T13:51:59.000Z | #!python
import numpy as np
from numpy import inf
from numpy import nan
from scipy.optimize import fmin
from scipy.stats import beta
from scipy.special import beta as B
from scipy.special import comb
import argparse
import sys
def parseArgs():
'''Function for parsing arguments'''
parser = argparse.ArgumentPars... | 35.932203 | 154 | 0.566274 | 567 | 4,240 | 4.151675 | 0.299824 | 0.027188 | 0.028887 | 0.018692 | 0.112999 | 0.039932 | 0 | 0 | 0 | 0 | 0 | 0.036208 | 0.283491 | 4,240 | 117 | 155 | 36.239316 | 0.738644 | 0.145047 | 0 | 0.022222 | 0 | 0 | 0.109136 | 0.00722 | 0 | 0 | 0 | 0 | 0 | 1 | 0.055556 | false | 0 | 0.1 | 0 | 0.155556 | 0.011111 | 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 | 0 | 1 | 0 |
86cdf766574c9c743ff631f5d4070feb9f763d2a | 7,654 | py | Python | caffe2/python/operator_test/partition_ops_test.py | KevinKecc/caffe2 | a2b6c6e2f0686358a84277df65e9489fb7d9ddb2 | [
"Apache-2.0"
] | 585 | 2015-08-10T02:48:52.000Z | 2021-12-01T08:46:59.000Z | caffe2/python/operator_test/partition_ops_test.py | mingzhe09088/caffe2 | 8f41717c46d214aaf62b53e5b3b9b308b5b8db91 | [
"Apache-2.0"
] | 27 | 2018-04-14T06:44:22.000Z | 2018-08-01T18:02:39.000Z | caffe2/python/operator_test/partition_ops_test.py | mingzhe09088/caffe2 | 8f41717c46d214aaf62b53e5b3b9b308b5b8db91 | [
"Apache-2.0"
] | 183 | 2015-08-10T02:49:04.000Z | 2021-12-01T08:47:13.000Z | # Copyright (c) 2016-present, Facebook, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed... | 38.852792 | 80 | 0.468774 | 831 | 7,654 | 4.200963 | 0.237064 | 0.029791 | 0.012031 | 0.022057 | 0.492409 | 0.47293 | 0.437124 | 0.437124 | 0.425666 | 0.425666 | 0 | 0.024627 | 0.42174 | 7,654 | 196 | 81 | 39.05102 | 0.764121 | 0.121505 | 0 | 0.486842 | 0 | 0 | 0.010717 | 0 | 0 | 0 | 0 | 0 | 0.019737 | 1 | 0.046053 | false | 0 | 0.052632 | 0 | 0.151316 | 0.019737 | 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 | 0 | 1 | 0 |
86ce2b47e96edc2e4a65e6684b182564c236c3d3 | 11,195 | py | Python | cisco-ios-xr/ydk/models/cisco_ios_xr/Cisco_IOS_XR_fib_common_cfg.py | Maikor/ydk-py | b86c4a7c570ae3b2c5557d098420446df5de4929 | [
"ECL-2.0",
"Apache-2.0"
] | null | null | null | cisco-ios-xr/ydk/models/cisco_ios_xr/Cisco_IOS_XR_fib_common_cfg.py | Maikor/ydk-py | b86c4a7c570ae3b2c5557d098420446df5de4929 | [
"ECL-2.0",
"Apache-2.0"
] | null | null | null | cisco-ios-xr/ydk/models/cisco_ios_xr/Cisco_IOS_XR_fib_common_cfg.py | Maikor/ydk-py | b86c4a7c570ae3b2c5557d098420446df5de4929 | [
"ECL-2.0",
"Apache-2.0"
] | null | null | null | """ Cisco_IOS_XR_fib_common_cfg
This module contains a collection of YANG definitions
for Cisco IOS\-XR fib\-common package configuration.
This module contains definitions
for the following management objects\:
fib\: CEF configuration
Copyright (c) 2013\-2018 by Cisco Systems, Inc.
All rights reserved.
"""
from ... | 34.875389 | 184 | 0.609915 | 1,190 | 11,195 | 5.430252 | 0.152941 | 0.050139 | 0.03714 | 0.032188 | 0.467812 | 0.427731 | 0.365831 | 0.325751 | 0.300371 | 0.294955 | 0 | 0.00869 | 0.280482 | 11,195 | 320 | 185 | 34.984375 | 0.793544 | 0.25958 | 0 | 0.40625 | 0 | 0.007813 | 0.201806 | 0.125996 | 0 | 0 | 0 | 0 | 0 | 1 | 0.085938 | false | 0 | 0.039063 | 0 | 0.234375 | 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 | 0 | 0 | 1 | 0 |
86ce2bcecdfa6edd6bc5db700d444829470b263a | 2,888 | py | Python | action/combo.py | dl-stuff/dl9 | 1cbe98afc53a1de9d413797fb130946acc4b6ba4 | [
"MIT"
] | null | null | null | action/combo.py | dl-stuff/dl9 | 1cbe98afc53a1de9d413797fb130946acc4b6ba4 | [
"MIT"
] | null | null | null | action/combo.py | dl-stuff/dl9 | 1cbe98afc53a1de9d413797fb130946acc4b6ba4 | [
"MIT"
] | null | null | null | """Series of actions that form a combo chain"""
from __future__ import annotations
from typing import Optional, Sequence, TYPE_CHECKING
from action import Action
from core.utility import Array
from core.constants import PlayerForm, SimActKind, MomentType
from core.database import FromDB
if TYPE_CHECKING:
from ent... | 42.470588 | 138 | 0.649584 | 390 | 2,888 | 4.541026 | 0.235897 | 0.057595 | 0.040655 | 0.024845 | 0.42349 | 0.39074 | 0.39074 | 0.367024 | 0.303783 | 0.257482 | 0 | 0.008965 | 0.227493 | 2,888 | 67 | 139 | 43.104478 | 0.78485 | 0.014197 | 0 | 0.150943 | 0 | 0 | 0.066174 | 0.014784 | 0 | 0 | 0 | 0 | 0 | 1 | 0.132075 | false | 0.037736 | 0.132075 | 0 | 0.415094 | 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 | 0 | 0 | 1 | 0 |
86ce9b178e942f833e8db993afdcf0aface18b4a | 3,845 | py | Python | sktime/forecasting/base/adapters/_statsmodels.py | tombh/sktime | 53df0b9ed9d1fd800539165c414cc5611bcc56b3 | [
"BSD-3-Clause"
] | 1 | 2020-06-02T22:24:44.000Z | 2020-06-02T22:24:44.000Z | sktime/forecasting/base/adapters/_statsmodels.py | abhishek-parashar/sktime | 1dfce6b41c2acdb576acfc04b09d11bf115c92d1 | [
"BSD-3-Clause"
] | 1 | 2020-11-20T13:51:20.000Z | 2020-11-20T13:51:20.000Z | sktime/forecasting/base/adapters/_statsmodels.py | abhishek-parashar/sktime | 1dfce6b41c2acdb576acfc04b09d11bf115c92d1 | [
"BSD-3-Clause"
] | 3 | 2020-10-18T04:54:30.000Z | 2021-02-15T18:04:18.000Z | #!/usr/bin/env python3 -u
# -*- coding: utf-8 -*-
__author__ = ["Markus Löning"]
__all__ = ["_StatsModelsAdapter"]
import numpy as np
import pandas as pd
from sktime.forecasting.base._base import DEFAULT_ALPHA
from sktime.forecasting.base._sktime import _OptionalForecastingHorizonMixin
from sktime.forecasting.base._... | 32.310924 | 79 | 0.628349 | 468 | 3,845 | 4.950855 | 0.333333 | 0.006905 | 0.027622 | 0.032369 | 0.145015 | 0.145015 | 0.113077 | 0.093224 | 0.093224 | 0.093224 | 0 | 0.006491 | 0.278804 | 3,845 | 118 | 80 | 32.584746 | 0.829066 | 0.352666 | 0 | 0 | 0 | 0 | 0.065723 | 0 | 0 | 0 | 0 | 0 | 0.039216 | 1 | 0.137255 | false | 0 | 0.098039 | 0 | 0.372549 | 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 | 0 | 0 | 1 | 0 |
86cfbb57e1ec13e6ae0711449af6c95612ae3139 | 2,268 | py | Python | jupytext/kernels.py | st--/jupytext | f8e8352859cc22e17b11154d0770fd946c4a430a | [
"MIT"
] | 5,378 | 2018-09-01T22:03:43.000Z | 2022-03-31T06:51:42.000Z | jupytext/kernels.py | st--/jupytext | f8e8352859cc22e17b11154d0770fd946c4a430a | [
"MIT"
] | 812 | 2018-08-31T08:26:13.000Z | 2022-03-30T18:12:11.000Z | jupytext/kernels.py | st--/jupytext | f8e8352859cc22e17b11154d0770fd946c4a430a | [
"MIT"
] | 380 | 2018-09-02T01:40:07.000Z | 2022-03-25T13:57:23.000Z | """Find kernel specifications for a given language"""
import os
import sys
from .languages import same_language
from .reraise import reraise
try:
# I prefer not to take a dependency on jupyter_client
from jupyter_client.kernelspec import find_kernel_specs, get_kernel_spec
except ImportError as err:
find_... | 36 | 116 | 0.622575 | 254 | 2,268 | 5.393701 | 0.291339 | 0.088321 | 0.043796 | 0.043796 | 0.30438 | 0.262774 | 0.208759 | 0.208759 | 0.208759 | 0.208759 | 0 | 0.000624 | 0.29321 | 2,268 | 62 | 117 | 36.580645 | 0.854024 | 0.147707 | 0 | 0.291667 | 0 | 0 | 0.153445 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.041667 | false | 0 | 0.125 | 0 | 0.229167 | 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 | 0 | 0 | 1 | 0 |
86d025f02ce51457ef476e760c051f7660045f69 | 5,333 | py | Python | scipy/sparse/_matrix_io.py | dhruv9vats/scipy | 48e1dd7e604df3ae57d104b407c5b7a2a6a3247d | [
"BSD-3-Clause"
] | 1 | 2021-08-16T09:32:42.000Z | 2021-08-16T09:32:42.000Z | scipy/sparse/_matrix_io.py | dhruv9vats/scipy | 48e1dd7e604df3ae57d104b407c5b7a2a6a3247d | [
"BSD-3-Clause"
] | 44 | 2019-06-27T15:56:14.000Z | 2022-03-15T22:21:10.000Z | scipy/sparse/_matrix_io.py | dhruv9vats/scipy | 48e1dd7e604df3ae57d104b407c5b7a2a6a3247d | [
"BSD-3-Clause"
] | 4 | 2020-06-13T10:32:25.000Z | 2021-12-03T15:48:16.000Z | import numpy as np
import scipy.sparse
__all__ = ['save_npz', 'load_npz']
# Make loading safe vs. malicious input
PICKLE_KWARGS = dict(allow_pickle=False)
def save_npz(file, matrix, compressed=True):
""" Save a sparse matrix to a file using ``.npz`` format.
Parameters
----------
file : str or file... | 35.553333 | 114 | 0.615976 | 698 | 5,333 | 4.614613 | 0.204871 | 0.126669 | 0.039118 | 0.007451 | 0.524992 | 0.488047 | 0.465073 | 0.44955 | 0.44955 | 0.44955 | 0 | 0.017241 | 0.249578 | 5,333 | 149 | 115 | 35.791946 | 0.787606 | 0.549409 | 0 | 0.111111 | 0 | 0 | 0.145654 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.044444 | false | 0 | 0.044444 | 0 | 0.155556 | 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 | 0 | 0 | 1 | 0 |
86d07b07d670dc9caa0bd92708721764a364d527 | 1,423 | py | Python | src/simulator/services/resources/atlas.py | ed741/PathBench | 50fe138eb1f824f49fe1a862705e435a1c3ec3ae | [
"BSD-3-Clause"
] | 46 | 2020-12-25T04:09:15.000Z | 2022-03-25T12:32:42.000Z | src/simulator/services/resources/atlas.py | ed741/PathBench | 50fe138eb1f824f49fe1a862705e435a1c3ec3ae | [
"BSD-3-Clause"
] | 36 | 2020-12-21T16:10:02.000Z | 2022-01-03T01:42:01.000Z | src/simulator/services/resources/atlas.py | judicaelclair/PathBenchURO | 101e67674efdfa8e27e1cf7787dac9fdf99552fe | [
"BSD-3-Clause"
] | 11 | 2021-01-06T23:34:12.000Z | 2022-03-21T17:21:47.000Z | from typing import Dict, List
from simulator.services.resources.directory import Directory
from simulator.services.services import Services
class Atlas(Directory):
def __init__(self, services: Services, name: str, parent: str, create: bool = False) -> None:
super().__init__(services, name, parent, create... | 29.040816 | 97 | 0.579761 | 169 | 1,423 | 4.668639 | 0.278107 | 0.04436 | 0.063371 | 0.091255 | 0.152091 | 0.08365 | 0.08365 | 0 | 0 | 0 | 0 | 0.004 | 0.297259 | 1,423 | 48 | 98 | 29.645833 | 0.785 | 0 | 0 | 0.111111 | 0 | 0 | 0.034434 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.194444 | false | 0 | 0.083333 | 0.027778 | 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 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 |
86d18fa6bf233db205e6db3a19952144dd79aa36 | 1,427 | py | Python | ingestion/src/metadata/great_expectations/builders/table/row_count_to_equal.py | ulixius9/OpenMetadata | f121698d968717f0932f685ef2a512c2a4d92438 | [
"Apache-2.0"
] | null | null | null | ingestion/src/metadata/great_expectations/builders/table/row_count_to_equal.py | ulixius9/OpenMetadata | f121698d968717f0932f685ef2a512c2a4d92438 | [
"Apache-2.0"
] | null | null | null | ingestion/src/metadata/great_expectations/builders/table/row_count_to_equal.py | ulixius9/OpenMetadata | f121698d968717f0932f685ef2a512c2a4d92438 | [
"Apache-2.0"
] | null | null | null | # Copyright 2022 Collate
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
# http://www.apache.org/licenses/LICENSE-2.0
# Unless required by applicable law or agreed to in writing, software... | 41.970588 | 86 | 0.756833 | 171 | 1,427 | 6.22807 | 0.590643 | 0.056338 | 0.059155 | 0.076056 | 0.060094 | 0 | 0 | 0 | 0 | 0 | 0 | 0.006734 | 0.167484 | 1,427 | 33 | 87 | 43.242424 | 0.889731 | 0.465312 | 0 | 0 | 0 | 0 | 0.039402 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.071429 | false | 0 | 0.285714 | 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 | 0 | 0 | 0 | 0 | 1 | 0 |
86d22671738e4b0cf43566c5aeec7cd2a5f04193 | 6,899 | py | Python | tensorflow/bbox/jrieke-tf-parse-v2/jrieke_tf_dataset.py | gustavovaliati/obj-det-experiments | e81774a18b34c22d971ad15d7ac6eb8663ac6f22 | [
"Apache-2.0"
] | null | null | null | tensorflow/bbox/jrieke-tf-parse-v2/jrieke_tf_dataset.py | gustavovaliati/obj-det-experiments | e81774a18b34c22d971ad15d7ac6eb8663ac6f22 | [
"Apache-2.0"
] | null | null | null | tensorflow/bbox/jrieke-tf-parse-v2/jrieke_tf_dataset.py | gustavovaliati/obj-det-experiments | e81774a18b34c22d971ad15d7ac6eb8663ac6f22 | [
"Apache-2.0"
] | null | null | null | '''
This code is based on https://github.com/jrieke/shape-detection/
'''
import matplotlib.pyplot as plt
import matplotlib
import numpy as np
import tensorflow as tf
import datetime
class JriekeBboxDataset:
def generate(self):
print('Generating...')
self.WIDTH = 8
self.HEIGHT = 8
... | 40.582353 | 142 | 0.59052 | 1,009 | 6,899 | 3.910803 | 0.193261 | 0.022808 | 0.022808 | 0.046123 | 0.46148 | 0.434617 | 0.413077 | 0.371515 | 0.341105 | 0.332489 | 0 | 0.032845 | 0.258588 | 6,899 | 169 | 143 | 40.822485 | 0.738612 | 0.101899 | 0 | 0.301724 | 0 | 0 | 0.098433 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.077586 | false | 0 | 0.043103 | 0 | 0.172414 | 0.043103 | 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 | 0 | 1 | 0 |
86d45952adaab5e1d25729182d1ca80f64803a29 | 8,103 | py | Python | census_data_downloader/core/tables.py | ian-r-rose/census-data-downloader | f8ac9d773e6d3f52be87bf916a2e32249391f966 | [
"MIT"
] | null | null | null | census_data_downloader/core/tables.py | ian-r-rose/census-data-downloader | f8ac9d773e6d3f52be87bf916a2e32249391f966 | [
"MIT"
] | null | null | null | census_data_downloader/core/tables.py | ian-r-rose/census-data-downloader | f8ac9d773e6d3f52be87bf916a2e32249391f966 | [
"MIT"
] | null | null | null | #! /usr/bin/env python
# -*- coding: utf-8 -*
"""
A base class that governs how to download and process tables from a Census API table.
"""
import os
import logging
import pathlib
from . import geotypes
from . import decorators
logger = logging.getLogger(__name__)
class BaseTableConfig(object):
"""
Configures... | 28.038062 | 96 | 0.60817 | 812 | 8,103 | 5.919951 | 0.270936 | 0.050343 | 0.100478 | 0.135428 | 0.189515 | 0.151654 | 0.06657 | 0.021635 | 0 | 0 | 0 | 0.007183 | 0.312724 | 8,103 | 288 | 97 | 28.135417 | 0.855989 | 0.214488 | 0 | 0.133758 | 0 | 0 | 0.093761 | 0.035875 | 0 | 0 | 0 | 0 | 0 | 1 | 0.152866 | false | 0.012739 | 0.031847 | 0 | 0.356688 | 0.006369 | 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 | 0 | 1 | 0 |
86d61d512c3c9d47b1f63fe91873604a549e077d | 5,422 | py | Python | sgf2ebook.py | loujine/sgf2ebook | 13c87056646cc6c06485b129221ab2028e67ef95 | [
"MIT"
] | null | null | null | sgf2ebook.py | loujine/sgf2ebook | 13c87056646cc6c06485b129221ab2028e67ef95 | [
"MIT"
] | null | null | null | sgf2ebook.py | loujine/sgf2ebook | 13c87056646cc6c06485b129221ab2028e67ef95 | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
import argparse
import os
from pathlib import Path
import shutil
import subprocess
import sys
from tempfile import TemporaryDirectory
from uuid import uuid4
from zipfile import ZipFile
import jinja2
import sente # type: ignore
__version__ = (1, 0, 0)
SGF_RENDER_EXECUTABLE = './sgf-render'
TE... | 34.75641 | 142 | 0.574511 | 614 | 5,422 | 4.949511 | 0.301303 | 0.016124 | 0.018427 | 0.032577 | 0.115169 | 0.096742 | 0 | 0 | 0 | 0 | 0 | 0.006584 | 0.299705 | 5,422 | 155 | 143 | 34.980645 | 0.793785 | 0.07322 | 0 | 0.08 | 0 | 0.008 | 0.151775 | 0.019745 | 0 | 0 | 0 | 0 | 0 | 1 | 0.016 | false | 0 | 0.088 | 0 | 0.12 | 0.08 | 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 | 0 | 1 | 0 |
86d6728bc96a31ea175e93ab91aadcc559c13053 | 1,788 | py | Python | vmis_sql_python/evaluation/metrics/popularity.py | bolcom/serenade-experiments-sigmod | 0a4c7f19d800d1c2784ea5536abb1a628cb12f7a | [
"Apache-2.0"
] | null | null | null | vmis_sql_python/evaluation/metrics/popularity.py | bolcom/serenade-experiments-sigmod | 0a4c7f19d800d1c2784ea5536abb1a628cb12f7a | [
"Apache-2.0"
] | null | null | null | vmis_sql_python/evaluation/metrics/popularity.py | bolcom/serenade-experiments-sigmod | 0a4c7f19d800d1c2784ea5536abb1a628cb12f7a | [
"Apache-2.0"
] | null | null | null | class Popularity:
'''
Popularity( length=20 )
Used to iteratively calculate the average overall popularity of an algorithm's recommendations.
Parameters
-----------
length : int
Coverage@length
training_df : dataframe
determines how many distinct item_ids there are in the ... | 33.735849 | 100 | 0.597315 | 221 | 1,788 | 4.742081 | 0.497738 | 0.040076 | 0.074427 | 0.032443 | 0.037214 | 0.037214 | 0 | 0 | 0 | 0 | 0 | 0.008907 | 0.309284 | 1,788 | 53 | 101 | 33.735849 | 0.839676 | 0.415548 | 0 | 0 | 0 | 0 | 0.021041 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.176471 | false | 0 | 0 | 0 | 0.294118 | 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 | 0 | 0 | 1 | 0 |
86d75a7478a79891b6baf0f18c7802c22b104725 | 918 | py | Python | dandeliondiary/household/urls.py | amberdiehl/dandeliondiary_project | e9bace5bd7980def6ca763840ab5b38f1e05cd3d | [
"FSFAP"
] | null | null | null | dandeliondiary/household/urls.py | amberdiehl/dandeliondiary_project | e9bace5bd7980def6ca763840ab5b38f1e05cd3d | [
"FSFAP"
] | 6 | 2020-04-29T23:54:15.000Z | 2022-03-11T23:25:24.000Z | dandeliondiary/household/urls.py | amberdiehl/dandeliondiary_project | e9bace5bd7980def6ca763840ab5b38f1e05cd3d | [
"FSFAP"
] | null | null | null | from django.conf.urls import include, url
from . import views
urlpatterns = [
url(r'^settings$', views.household_dashboard, name='household_dashboard'),
url(r'^myinfo$', views.my_info, name='my_info'),
url(r'^profile$', views.household_profile, name='maintain_household'),
url(r'^members$', views.househ... | 54 | 95 | 0.683007 | 142 | 918 | 4.211268 | 0.295775 | 0.073579 | 0.080268 | 0.053512 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.008424 | 0.094771 | 918 | 16 | 96 | 57.375 | 0.711191 | 0 | 0 | 0 | 0 | 0.133333 | 0.397603 | 0.237473 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.133333 | 0 | 0.133333 | 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 | 0 | 0 | 1 | 0 |
86d8ff6a04670083ea5d1c4de998cdc6916ada2c | 4,207 | py | Python | q2_qemistree/tests/test_fingerprint.py | tgroth97/q2-qemistree | 289c447a6c3a29478bb84212281ef0d7ffc1387a | [
"BSD-2-Clause"
] | null | null | null | q2_qemistree/tests/test_fingerprint.py | tgroth97/q2-qemistree | 289c447a6c3a29478bb84212281ef0d7ffc1387a | [
"BSD-2-Clause"
] | null | null | null | q2_qemistree/tests/test_fingerprint.py | tgroth97/q2-qemistree | 289c447a6c3a29478bb84212281ef0d7ffc1387a | [
"BSD-2-Clause"
] | null | null | null | # ----------------------------------------------------------------------------
# Copyright (c) 2016-2018, QIIME 2 development team.
#
# Distributed under the terms of the Modified BSD License.
#
# The full license is in the file LICENSE, distributed with this software.
# ------------------------------------------------... | 45.728261 | 78 | 0.548134 | 389 | 4,207 | 5.74036 | 0.326478 | 0.032244 | 0.022391 | 0.031348 | 0.403045 | 0.403045 | 0.34438 | 0.329601 | 0.290193 | 0.237797 | 0 | 0.011344 | 0.329451 | 4,207 | 91 | 79 | 46.230769 | 0.78022 | 0.103161 | 0 | 0.220588 | 0 | 0 | 0.069415 | 0.01516 | 0 | 0 | 0 | 0 | 0.117647 | 1 | 0.102941 | false | 0 | 0.088235 | 0 | 0.205882 | 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 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 |
86d90c692c5aa920f75d361edbf2de1c22109ec8 | 3,518 | py | Python | tempo/worker.py | rackerlabs/Tempo | 60c2adaf5b592ae171987b999e0b9cc46b80c54e | [
"Apache-2.0"
] | 4 | 2015-04-26T01:46:51.000Z | 2020-11-10T13:07:59.000Z | tempo/worker.py | rackerlabs/Tempo | 60c2adaf5b592ae171987b999e0b9cc46b80c54e | [
"Apache-2.0"
] | null | null | null | tempo/worker.py | rackerlabs/Tempo | 60c2adaf5b592ae171987b999e0b9cc46b80c54e | [
"Apache-2.0"
] | null | null | null | # vim: tabstop=4 shiftwidth=4 softtabstop=4
#
# Copyright 2012 Rackspace
# 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/licen... | 29.563025 | 77 | 0.673394 | 446 | 3,518 | 5.188341 | 0.38565 | 0.041487 | 0.032411 | 0.02809 | 0.123596 | 0.070873 | 0 | 0 | 0 | 0 | 0 | 0.004059 | 0.229676 | 3,518 | 118 | 78 | 29.813559 | 0.849816 | 0.212905 | 0 | 0.121622 | 0 | 0 | 0.146545 | 0 | 0 | 0 | 0 | 0.008475 | 0 | 1 | 0.067568 | false | 0 | 0.135135 | 0 | 0.22973 | 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 | 0 | 0 | 1 | 0 |
86d979010cd46ef001009b94be4cbd36b5242fa0 | 24,187 | py | Python | bin/basenji_motifs.py | AndyPJiang/basenji | 64e43570c8bece156b4ab926608014f489b7965e | [
"Apache-2.0"
] | 1 | 2020-05-22T20:53:37.000Z | 2020-05-22T20:53:37.000Z | bin/basenji_motifs.py | AndyPJiang/basenji | 64e43570c8bece156b4ab926608014f489b7965e | [
"Apache-2.0"
] | null | null | null | bin/basenji_motifs.py | AndyPJiang/basenji | 64e43570c8bece156b4ab926608014f489b7965e | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python
# Copyright 2017 Calico LLC
# 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
# https://www.apache.org/licenses/LICENSE-2.0
# Unless required by applicable law or agr... | 29.282082 | 99 | 0.585687 | 3,259 | 24,187 | 4.136545 | 0.168457 | 0.02893 | 0.016393 | 0.006528 | 0.270306 | 0.221719 | 0.18871 | 0.168237 | 0.151102 | 0.136414 | 0 | 0.014731 | 0.20573 | 24,187 | 825 | 100 | 29.317576 | 0.687002 | 0.187332 | 0 | 0.25 | 0 | 0.002193 | 0.105671 | 0.007983 | 0 | 0 | 0 | 0 | 0 | 1 | 0.032895 | false | 0.002193 | 0.028509 | 0 | 0.076754 | 0.065789 | 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 | 0 | 1 | 0 |
86db53b7a1cf34f8c926e78563b430e45842c3b8 | 1,337 | py | Python | apps/shop/urls.py | Joetib/jshop | 810ce5dcf2cf2d23b45536dd0c8806efd3b7fc91 | [
"MIT"
] | 1 | 2021-09-29T18:48:00.000Z | 2021-09-29T18:48:00.000Z | apps/shop/urls.py | Joetib/jshop | 810ce5dcf2cf2d23b45536dd0c8806efd3b7fc91 | [
"MIT"
] | null | null | null | apps/shop/urls.py | Joetib/jshop | 810ce5dcf2cf2d23b45536dd0c8806efd3b7fc91 | [
"MIT"
] | null | null | null | from django.urls import path
from . import views
app_name = "shop"
urlpatterns = [
path('', views.HomePage.as_view(), name="home-page"),
path('shop/', views.ProductListView.as_view(), name="product-list"),
path('shop/<int:category_pk>/', views.ProductListView.as_view(), name="product-list"),
path('sho... | 58.130435 | 109 | 0.691847 | 185 | 1,337 | 4.859459 | 0.243243 | 0.115684 | 0.133482 | 0.05673 | 0.313682 | 0.246941 | 0.246941 | 0.10901 | 0.10901 | 0 | 0 | 0 | 0.091249 | 1,337 | 22 | 110 | 60.772727 | 0.739918 | 0 | 0 | 0 | 0 | 0 | 0.350037 | 0.18175 | 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 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 |
86db5b39f7333cdce223e5a0be6e734eb216f5d2 | 11,028 | py | Python | surpyval/parametric/expo_weibull.py | dfm/SurPyval | 014fba8f1d4a0f43218a3713ce80a78191ad8be9 | [
"MIT"
] | null | null | null | surpyval/parametric/expo_weibull.py | dfm/SurPyval | 014fba8f1d4a0f43218a3713ce80a78191ad8be9 | [
"MIT"
] | null | null | null | surpyval/parametric/expo_weibull.py | dfm/SurPyval | 014fba8f1d4a0f43218a3713ce80a78191ad8be9 | [
"MIT"
] | null | null | null | import autograd.numpy as np
from scipy.stats import uniform
from autograd import jacobian
from numpy import euler_gamma
from scipy.special import gamma as gamma_func
from scipy.special import ndtri as z
from scipy import integrate
from scipy.optimize import minimize
from surpyval import parametric as para
from surpyva... | 32.151603 | 228 | 0.537087 | 1,428 | 11,028 | 4.126751 | 0.151261 | 0.059393 | 0.080774 | 0.137791 | 0.648566 | 0.628712 | 0.60784 | 0.597319 | 0.565077 | 0.541999 | 0 | 0.072981 | 0.336507 | 11,028 | 343 | 229 | 32.151604 | 0.732404 | 0.525118 | 0 | 0.020408 | 0 | 0 | 0.011711 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.153061 | false | 0 | 0.122449 | 0.010204 | 0.438776 | 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 | 0 | 0 | 1 | 0 |
86db8d66e4f0f969e4dab6cb93ed65e00e44883f | 3,292 | py | Python | tests/test_base_table.py | stjordanis/datar | 4e2b5db026ad35918954576badef9951928c0cb1 | [
"MIT"
] | 110 | 2021-03-09T04:10:40.000Z | 2022-03-13T10:28:20.000Z | tests/test_base_table.py | sthagen/datar | 1218a549e2f0547c7b5a824ca6d9adf1bf96ba46 | [
"MIT"
] | 54 | 2021-06-20T18:53:44.000Z | 2022-03-29T22:13:07.000Z | tests/test_base_table.py | sthagen/datar | 1218a549e2f0547c7b5a824ca6d9adf1bf96ba46 | [
"MIT"
] | 11 | 2021-06-18T03:03:14.000Z | 2022-02-25T11:48:26.000Z | import pytest
from datar import stats
from datar.base import *
from datar import f
from datar.datasets import warpbreaks, state_division, state_region, airquality
from .conftest import assert_iterable_equal
def test_table():
# https://www.rdocumentation.org/packages/base/versions/3.6.2/topics/table
z = stats... | 31.056604 | 79 | 0.564702 | 456 | 3,292 | 4.002193 | 0.225877 | 0.06137 | 0.093699 | 0.096438 | 0.531507 | 0.468493 | 0.404932 | 0.246027 | 0.200548 | 0.200548 | 0 | 0.025365 | 0.209599 | 3,292 | 105 | 80 | 31.352381 | 0.676018 | 0.085055 | 0 | 0.22973 | 0 | 0 | 0.029333 | 0 | 0 | 0 | 0 | 0 | 0.351351 | 1 | 0.027027 | false | 0 | 0.094595 | 0 | 0.121622 | 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 | 0 | 0 | 1 | 0 |
86dbc8be4491e9aac31a1a68443d62ca3e952415 | 1,922 | py | Python | cqlengine/tests/statements/test_update_statement.py | dokai/cqlengine | a080aff3a73351d37126b14eef606061b445aa37 | [
"BSD-3-Clause"
] | null | null | null | cqlengine/tests/statements/test_update_statement.py | dokai/cqlengine | a080aff3a73351d37126b14eef606061b445aa37 | [
"BSD-3-Clause"
] | null | null | null | cqlengine/tests/statements/test_update_statement.py | dokai/cqlengine | a080aff3a73351d37126b14eef606061b445aa37 | [
"BSD-3-Clause"
] | null | null | null | from unittest import TestCase
from cqlengine.statements import UpdateStatement, WhereClause, AssignmentClause
from cqlengine.operators import *
class UpdateStatementTests(TestCase):
def test_table_rendering(self):
""" tests that fields are properly added to the select statement """
us = UpdateSta... | 44.697674 | 104 | 0.648283 | 233 | 1,922 | 5.201717 | 0.253219 | 0.04538 | 0.086634 | 0.121287 | 0.622937 | 0.511551 | 0.511551 | 0.511551 | 0.459571 | 0.388614 | 0 | 0.010911 | 0.189386 | 1,922 | 42 | 105 | 45.761905 | 0.767009 | 0.031217 | 0 | 0.454545 | 0 | 0.060606 | 0.109552 | 0 | 0 | 0 | 0 | 0 | 0.212121 | 1 | 0.151515 | false | 0 | 0.090909 | 0 | 0.272727 | 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 | 0 | 0 | 1 | 0 |
86dd8cfba25399e11b5e6b0c69e97eec2cc7d779 | 1,590 | py | Python | course-code/imooc-tf-mnist-flask/mnist/module.py | le3t/ko-repo | 50eb0b4cadb9db9bf608a9e5d36376f38ff5cce5 | [
"Apache-2.0"
] | 30 | 2018-12-06T02:17:45.000Z | 2021-04-07T09:03:36.000Z | course-code/imooc-tf-mnist-flask/mnist/module.py | Artister/tutorials-java | 50eb0b4cadb9db9bf608a9e5d36376f38ff5cce5 | [
"Apache-2.0"
] | 3 | 2019-08-26T13:41:57.000Z | 2019-08-26T13:44:21.000Z | course-code/imooc-tf-mnist-flask/mnist/module.py | Artister/tutorials-java | 50eb0b4cadb9db9bf608a9e5d36376f38ff5cce5 | [
"Apache-2.0"
] | 20 | 2018-12-27T08:31:02.000Z | 2020-12-03T08:35:28.000Z | import tensorflow as tf
# y=ax+b linear model
def regression(x):
a = tf.Variable(tf.zeros([784, 10]), name="a")
b = tf.Variable(tf.zeros([10]), name="b")
y = tf.nn.softmax(tf.matmul(x, a) + b)
return y, [a, b]
# 定义卷积模型
def convolutional(x, keep_prob):
def conv2d(x, w):
return tf.nn.conv... | 30.576923 | 72 | 0.620755 | 278 | 1,590 | 3.327338 | 0.23741 | 0.034595 | 0.032432 | 0.036757 | 0.043243 | 0.043243 | 0 | 0 | 0 | 0 | 0 | 0.092742 | 0.220126 | 1,590 | 51 | 73 | 31.176471 | 0.653226 | 0.019497 | 0 | 0.055556 | 0 | 0 | 0.006431 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.166667 | false | 0 | 0.027778 | 0.055556 | 0.361111 | 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 | 0 | 0 | 1 | 0 |
86e1dc1697df65dd8302b1c8457579ff83a8e10d | 1,074 | py | Python | faceai/gender.py | dlzdy/faceai | 4b1e41d4c394c00da51533562b76306d86493f72 | [
"MIT"
] | 1 | 2021-05-18T07:31:14.000Z | 2021-05-18T07:31:14.000Z | faceai/gender.py | dlzdy/faceai | 4b1e41d4c394c00da51533562b76306d86493f72 | [
"MIT"
] | null | null | null | faceai/gender.py | dlzdy/faceai | 4b1e41d4c394c00da51533562b76306d86493f72 | [
"MIT"
] | null | null | null | #coding=utf-8
#性别识别
import cv2
from keras.models import load_model
import numpy as np
import chineseText
img = cv2.imread("img/gather.png")
face_classifier = cv2.CascadeClassifier(
"d:\Python36\Lib\site-packages\opencv-master\data\haarcascades\haarcascade_frontalface_default.xml"
)
gray = cv2.cvtColor(img, cv2.CO... | 30.685714 | 103 | 0.691806 | 164 | 1,074 | 4.420732 | 0.493902 | 0.024828 | 0.038621 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.068282 | 0.154562 | 1,074 | 34 | 104 | 31.588235 | 0.730176 | 0.014898 | 0 | 0 | 0 | 0.037037 | 0.157197 | 0.137311 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.148148 | 0 | 0.148148 | 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 | 0 | 0 | 1 | 0 |
86e1dfa0c33f00a823a44b2f6b5cc3f12ae76c76 | 5,872 | py | Python | csm_web/scheduler/tests/utils.py | mudit2103/csm_web | 3b7fd9ca7269ad4cb57bf264cf62a620e02d3780 | [
"MIT"
] | null | null | null | csm_web/scheduler/tests/utils.py | mudit2103/csm_web | 3b7fd9ca7269ad4cb57bf264cf62a620e02d3780 | [
"MIT"
] | null | null | null | csm_web/scheduler/tests/utils.py | mudit2103/csm_web | 3b7fd9ca7269ad4cb57bf264cf62a620e02d3780 | [
"MIT"
] | null | null | null | from django.test import TestCase
from os import path
from rest_framework import status
from rest_framework.test import APIClient
import random
from scheduler.models import Profile
from scheduler.factories import (
CourseFactory,
SpacetimeFactory,
UserFactory,
ProfileFactory,
SectionFactory,
Att... | 32.804469 | 88 | 0.647309 | 748 | 5,872 | 4.971925 | 0.270053 | 0.010756 | 0.018284 | 0.022587 | 0.258672 | 0.258672 | 0.242001 | 0.242001 | 0.226943 | 0.214036 | 0 | 0.009287 | 0.266519 | 5,872 | 178 | 89 | 32.988764 | 0.854191 | 0.290531 | 0 | 0.020408 | 0 | 0 | 0.018608 | 0 | 0 | 0 | 0 | 0 | 0.010204 | 1 | 0.142857 | false | 0.010204 | 0.071429 | 0.010204 | 0.346939 | 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 | 0 | 0 | 1 | 0 |
86e1fd3bf7ee00e117356675760b13ae01e5890a | 3,282 | py | Python | coldtype/beziers.py | tallpauley/coldtype | c1811e1d3713ff9c3c804511d6cd607b1d802065 | [
"Apache-2.0"
] | null | null | null | coldtype/beziers.py | tallpauley/coldtype | c1811e1d3713ff9c3c804511d6cd607b1d802065 | [
"Apache-2.0"
] | null | null | null | coldtype/beziers.py | tallpauley/coldtype | c1811e1d3713ff9c3c804511d6cd607b1d802065 | [
"Apache-2.0"
] | null | null | null | import math
from fontTools.pens.recordingPen import RecordingPen, replayRecording
from fontTools.misc.bezierTools import calcCubicArcLength, splitCubicAtT
from coldtype.geometry import Rect, Point
def raise_quadratic(start, a, b):
c0 = start
c1 = (c0[0] + (2/3)*(a[0] - c0[0]), c0[1] + (2/3)*(a[1] - c0[1]))
... | 31.557692 | 85 | 0.482937 | 404 | 3,282 | 3.806931 | 0.237624 | 0.013004 | 0.015605 | 0.018205 | 0.208713 | 0.137841 | 0.096229 | 0.096229 | 0.096229 | 0.096229 | 0 | 0.04004 | 0.391225 | 3,282 | 104 | 86 | 31.557692 | 0.72973 | 0.014321 | 0 | 0.182796 | 0 | 0 | 0.014538 | 0 | 0 | 0 | 0 | 0.009615 | 0 | 1 | 0.075269 | false | 0.021505 | 0.043011 | 0 | 0.225806 | 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 | 0 | 0 | 1 | 0 |
86e21cfc54ba4f492a89adb3a5ddc21c8d452d78 | 3,930 | py | Python | p1_navigation/train.py | nick0lay/deep-reinforcement-learning | 5af4daca9850b4e12aec5d8b0dad87f1e22a1f98 | [
"MIT"
] | null | null | null | p1_navigation/train.py | nick0lay/deep-reinforcement-learning | 5af4daca9850b4e12aec5d8b0dad87f1e22a1f98 | [
"MIT"
] | null | null | null | p1_navigation/train.py | nick0lay/deep-reinforcement-learning | 5af4daca9850b4e12aec5d8b0dad87f1e22a1f98 | [
"MIT"
] | null | null | null | """
Project for Udacity Danaodgree in Deep Reinforcement Learning
This script train an agent to navigate (and collect bananas!) in a large, square world.
A reward of +1 is provided for collecting a yellow banana, and a reward of -1 is provided for collecting a blue banana. Thus, the goal of your agent is to collect a... | 42.717391 | 279 | 0.689567 | 559 | 3,930 | 4.711986 | 0.363148 | 0.02126 | 0.031891 | 0.025816 | 0.22855 | 0.172741 | 0.100987 | 0.100987 | 0.071374 | 0.045558 | 0 | 0.029155 | 0.214504 | 3,930 | 92 | 280 | 42.717391 | 0.824101 | 0.362341 | 0 | 0.047619 | 0 | 0 | 0.08055 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.02381 | false | 0 | 0.119048 | 0 | 0.166667 | 0.071429 | 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 | 0 | 1 | 0 |
86e5087a507beef54f4930afdd98c56727fc0500 | 2,869 | py | Python | models/model_factory.py | jac99/Egonn | 075e00368a1676df741a35f42f6f38497da9d58f | [
"MIT"
] | 9 | 2021-10-31T07:11:58.000Z | 2022-03-29T14:06:49.000Z | models/model_factory.py | jac99/Egonn | 075e00368a1676df741a35f42f6f38497da9d58f | [
"MIT"
] | null | null | null | models/model_factory.py | jac99/Egonn | 075e00368a1676df741a35f42f6f38497da9d58f | [
"MIT"
] | 3 | 2021-11-12T17:42:41.000Z | 2022-03-11T00:41:47.000Z | # Warsaw University of Technology
from layers.eca_block import ECABasicBlock
from models.minkgl import MinkHead, MinkTrunk, MinkGL
from models.minkloc import MinkLoc
from third_party.minkloc3d.minkloc import MinkLoc3D
from misc.utils import ModelParams
def model_factory(model_params: ModelParams):
in_channels ... | 36.782051 | 100 | 0.694319 | 379 | 2,869 | 4.926121 | 0.245383 | 0.100161 | 0.041243 | 0.037493 | 0.113551 | 0.084628 | 0.065345 | 0.065345 | 0.039636 | 0.039636 | 0 | 0.025792 | 0.229697 | 2,869 | 78 | 101 | 36.782051 | 0.819005 | 0.037295 | 0 | 0.090909 | 0 | 0 | 0.029358 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.036364 | false | 0 | 0.090909 | 0 | 0.163636 | 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 | 0 | 0 | 1 | 0 |
86e596ecc94466fc1c8a56bb395c9ae7c14904e6 | 19,380 | py | Python | mdns/Phidget22Python/Phidget22/Phidget.py | rabarar/phidget_docker | ceca56c86d27f291a4300a1257c02096862335ec | [
"MIT"
] | null | null | null | mdns/Phidget22Python/Phidget22/Phidget.py | rabarar/phidget_docker | ceca56c86d27f291a4300a1257c02096862335ec | [
"MIT"
] | null | null | null | mdns/Phidget22Python/Phidget22/Phidget.py | rabarar/phidget_docker | ceca56c86d27f291a4300a1257c02096862335ec | [
"MIT"
] | null | null | null | import sys
import ctypes
from Phidget22.PhidgetSupport import PhidgetSupport
from Phidget22.Async import *
from Phidget22.ChannelClass import ChannelClass
from Phidget22.ChannelSubclass import ChannelSubclass
from Phidget22.DeviceClass import DeviceClass
from Phidget22.DeviceID import DeviceID
from Phidget22.ErrorEvent... | 26.083445 | 113 | 0.757482 | 2,223 | 19,380 | 6.250562 | 0.081871 | 0.061965 | 0.05009 | 0.120475 | 0.584167 | 0.547679 | 0.492191 | 0.297517 | 0.254192 | 0.220007 | 0 | 0.01436 | 0.144788 | 19,380 | 742 | 114 | 26.118598 | 0.824001 | 0 | 0 | 0.413462 | 0 | 0 | 0.006037 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.119231 | false | 0 | 0.019231 | 0.003846 | 0.230769 | 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 | 0 | 0 | 1 | 0 |
86e5ef7ddc4f844bf23ef6fa4d846ed9f0547af6 | 1,826 | py | Python | openprocurement/auctions/geb/tests/blanks/create.py | oleksiyVeretiuk/openprocurement.auctions.geb | 2965b52bf8826b9a8f8870c9a4d2052f945f5799 | [
"Apache-2.0"
] | null | null | null | openprocurement/auctions/geb/tests/blanks/create.py | oleksiyVeretiuk/openprocurement.auctions.geb | 2965b52bf8826b9a8f8870c9a4d2052f945f5799 | [
"Apache-2.0"
] | null | null | null | openprocurement/auctions/geb/tests/blanks/create.py | oleksiyVeretiuk/openprocurement.auctions.geb | 2965b52bf8826b9a8f8870c9a4d2052f945f5799 | [
"Apache-2.0"
] | null | null | null | def create_auction(self):
expected_http_status = '201 Created'
request_data = {"data": self.auction}
entrypoint = '/auctions'
response = self.app.post_json(entrypoint, request_data)
self.assertEqual(response.status, expected_http_status)
def create_auction_check_minNumberOfQualifiedBids(self):
... | 33.814815 | 71 | 0.728916 | 194 | 1,826 | 6.634021 | 0.190722 | 0.094017 | 0.06993 | 0.088578 | 0.57265 | 0.57265 | 0.57265 | 0.57265 | 0.57265 | 0.57265 | 0 | 0.008491 | 0.161555 | 1,826 | 53 | 72 | 34.45283 | 0.832136 | 0 | 0 | 0.526316 | 0 | 0 | 0.13253 | 0.035049 | 0 | 0 | 0 | 0 | 0.131579 | 1 | 0.131579 | false | 0 | 0 | 0 | 0.131579 | 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 | 0 | 0 | 1 | 0 |
86e649d303431093f68ab23ef3215809292e639b | 4,872 | py | Python | tests/integration/test_celery.py | crossscreenmedia/scout_apm_python | 5cd31bf21f5acd0be0df4f40ec0bd29ec050ec01 | [
"MIT"
] | null | null | null | tests/integration/test_celery.py | crossscreenmedia/scout_apm_python | 5cd31bf21f5acd0be0df4f40ec0bd29ec050ec01 | [
"MIT"
] | null | null | null | tests/integration/test_celery.py | crossscreenmedia/scout_apm_python | 5cd31bf21f5acd0be0df4f40ec0bd29ec050ec01 | [
"MIT"
] | null | null | null | # coding=utf-8
from __future__ import absolute_import, division, print_function, unicode_literals
from contextlib import contextmanager
import celery
import pytest
from celery.signals import setup_logging
import scout_apm.celery
from scout_apm.api import Config
# http://docs.celeryproject.org/en/latest/userguide/te... | 34.553191 | 82 | 0.70936 | 650 | 4,872 | 5.089231 | 0.252308 | 0.09734 | 0.059855 | 0.078597 | 0.571645 | 0.525998 | 0.485792 | 0.436518 | 0.436518 | 0.409915 | 0 | 0.009009 | 0.179803 | 4,872 | 140 | 83 | 34.8 | 0.818819 | 0.117406 | 0 | 0.373737 | 0 | 0 | 0.166706 | 0.086631 | 0 | 0 | 0 | 0 | 0.343434 | 1 | 0.080808 | false | 0.010101 | 0.070707 | 0.010101 | 0.161616 | 0.010101 | 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 | 0 | 1 | 0 |
86e79f3939b52fb2b048dd2d47804d7ba195c64a | 12,893 | py | Python | quapy/model_selection.py | OneToolsCollection/HLT-ISTI-QuaPy | 6a5c528154c2d6d38d9f3258e667727bf692fc8b | [
"BSD-3-Clause"
] | null | null | null | quapy/model_selection.py | OneToolsCollection/HLT-ISTI-QuaPy | 6a5c528154c2d6d38d9f3258e667727bf692fc8b | [
"BSD-3-Clause"
] | null | null | null | quapy/model_selection.py | OneToolsCollection/HLT-ISTI-QuaPy | 6a5c528154c2d6d38d9f3258e667727bf692fc8b | [
"BSD-3-Clause"
] | null | null | null | import itertools
import signal
from copy import deepcopy
from typing import Union, Callable
import numpy as np
import quapy as qp
from quapy.data.base import LabelledCollection
from quapy.evaluation import artificial_prevalence_prediction, natural_prevalence_prediction, gen_prevalence_prediction
from quapy.method.agg... | 48.65283 | 119 | 0.649732 | 1,629 | 12,893 | 5.014119 | 0.199509 | 0.01763 | 0.011998 | 0.007835 | 0.150343 | 0.113002 | 0.090475 | 0.090475 | 0.067826 | 0.067826 | 0 | 0.007948 | 0.277825 | 12,893 | 264 | 120 | 48.837121 | 0.869294 | 0.35973 | 0 | 0.08125 | 0 | 0.00625 | 0.185796 | 0.014711 | 0 | 0 | 0 | 0 | 0.025 | 1 | 0.075 | false | 0.00625 | 0.06875 | 0 | 0.21875 | 0.01875 | 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 | 0 | 1 | 0 |
86e7e28fd96ba38477835a4f1f9a0169efabb855 | 2,841 | py | Python | python/day09/smoke_basin.py | aesdeef/advent-of-code-2021 | 4561bcf12ac03d360f5b28c48ef80134f97613b9 | [
"MIT"
] | 2 | 2021-12-03T06:18:27.000Z | 2021-12-06T11:28:33.000Z | python/day09/smoke_basin.py | aesdeef/advent-of-code-2021 | 4561bcf12ac03d360f5b28c48ef80134f97613b9 | [
"MIT"
] | null | null | null | python/day09/smoke_basin.py | aesdeef/advent-of-code-2021 | 4561bcf12ac03d360f5b28c48ef80134f97613b9 | [
"MIT"
] | null | null | null | INPUT_FILE = "../../input/09.txt"
Point = tuple[int, int]
Heightmap = dict[Point, int]
Basin = set[Point]
def parse_input() -> Heightmap:
"""
Parses the input and returns a Heightmap
"""
with open(INPUT_FILE) as f:
heights = [[int(x) for x in line.strip()] for line in f]
heightmap: Heigh... | 27.852941 | 77 | 0.642027 | 362 | 2,841 | 4.861878 | 0.212707 | 0.081818 | 0.071591 | 0.047727 | 0.213068 | 0.135795 | 0.115909 | 0.057955 | 0.057955 | 0 | 0 | 0.008916 | 0.249912 | 2,841 | 101 | 78 | 28.128713 | 0.816987 | 0.12214 | 0 | 0.035088 | 0 | 0 | 0.010888 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.122807 | false | 0 | 0 | 0 | 0.245614 | 0.035088 | 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 | 0 | 1 | 0 |
86e856cc4992e6f53fef41d1cfe0de4271ac6642 | 1,667 | py | Python | playground.py | NHGmaniac/voctoconfig | 55a803a5f9bc81b48eaa72ced1fddd402aa7a2e9 | [
"MIT"
] | null | null | null | playground.py | NHGmaniac/voctoconfig | 55a803a5f9bc81b48eaa72ced1fddd402aa7a2e9 | [
"MIT"
] | null | null | null | playground.py | NHGmaniac/voctoconfig | 55a803a5f9bc81b48eaa72ced1fddd402aa7a2e9 | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
import signal
import logging
import sys
from gi.repository import GObject
GObject.threads_init()
import time
from lib.args import Args
from lib.loghandler import LogHandler
import lib.connection as Connection
def testCallback(args):
log = logging.getLogger("Test")
log.info(str(args... | 24.514706 | 67 | 0.644271 | 186 | 1,667 | 5.698925 | 0.44086 | 0.033019 | 0.031132 | 0.028302 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.004739 | 0.240552 | 1,667 | 68 | 68 | 24.514706 | 0.832543 | 0.012597 | 0 | 0 | 0 | 0 | 0.105103 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.098039 | false | 0 | 0.156863 | 0 | 0.27451 | 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 | 0 | 0 | 1 | 0 |
86e873cdab8920252696e3d917e54b578dd9f428 | 3,220 | py | Python | tianshou/utils/logger/tensorboard.py | Aceticia/tianshou | 6377dc5006ba1111adac42472447b9de4a021c2d | [
"MIT"
] | 4,714 | 2018-04-16T22:52:05.000Z | 2022-03-31T14:14:51.000Z | tianshou/utils/logger/tensorboard.py | Aceticia/tianshou | 6377dc5006ba1111adac42472447b9de4a021c2d | [
"MIT"
] | 529 | 2020-03-26T00:58:03.000Z | 2022-03-31T01:59:14.000Z | tianshou/utils/logger/tensorboard.py | Aceticia/tianshou | 6377dc5006ba1111adac42472447b9de4a021c2d | [
"MIT"
] | 798 | 2018-05-26T23:34:07.000Z | 2022-03-30T11:26:19.000Z | import warnings
from typing import Any, Callable, Optional, Tuple
from tensorboard.backend.event_processing import event_accumulator
from torch.utils.tensorboard import SummaryWriter
from tianshou.utils.logger.base import LOG_DATA_TYPE, BaseLogger
class TensorboardLogger(BaseLogger):
"""A logger that relies on ... | 37.011494 | 87 | 0.647205 | 412 | 3,220 | 4.822816 | 0.252427 | 0.042275 | 0.040262 | 0.032209 | 0.226975 | 0.114243 | 0 | 0 | 0 | 0 | 0 | 0.013825 | 0.258696 | 3,220 | 86 | 88 | 37.44186 | 0.818601 | 0.20559 | 0 | 0.135593 | 0 | 0 | 0.077015 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.084746 | false | 0 | 0.084746 | 0 | 0.220339 | 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 | 0 | 0 | 1 | 0 |
86e8affd139b8a4dffaf5cdc66c6797adccdf84b | 7,326 | py | Python | PythonAPI/pythonwrappers/jetfuel/gui/menu.py | InsightGit/JetfuelGameEngine | 3ea0bf2fb5e09aadf304b7b5a16882d72336c408 | [
"Apache-2.0"
] | 4 | 2018-02-05T03:40:10.000Z | 2021-06-18T16:22:13.000Z | PythonAPI/pythonwrappers/jetfuel/gui/menu.py | InsightGit/JetfuelGameEngine | 3ea0bf2fb5e09aadf304b7b5a16882d72336c408 | [
"Apache-2.0"
] | null | null | null | PythonAPI/pythonwrappers/jetfuel/gui/menu.py | InsightGit/JetfuelGameEngine | 3ea0bf2fb5e09aadf304b7b5a16882d72336c408 | [
"Apache-2.0"
] | null | null | null | # Jetfuel Game Engine- A SDL-based 2D game-engine
# Copyright (C) 2018 InfernoStudios
#
# 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... | 46.367089 | 81 | 0.590227 | 813 | 7,326 | 4.897909 | 0.163592 | 0.129834 | 0.165746 | 0.117529 | 0.559518 | 0.503516 | 0.414867 | 0.373682 | 0.279508 | 0.214716 | 0 | 0.001876 | 0.345072 | 7,326 | 157 | 82 | 46.66242 | 0.828053 | 0.083129 | 0 | 0.089109 | 0 | 0 | 0.004479 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.168317 | false | 0 | 0.069307 | 0 | 0.356436 | 0.009901 | 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 | 0 | 1 | 0 |
86ea235dbd8e630be7e48c8aa27ae5d388c7bc1d | 30,649 | py | Python | latent_programmer/decomposition_transformer_attention/train.py | ParikhKadam/google-research | 00a282388e389e09ce29109eb050491c96cfab85 | [
"Apache-2.0"
] | 2 | 2022-01-21T18:15:34.000Z | 2022-01-25T15:21:34.000Z | latent_programmer/decomposition_transformer_attention/train.py | ParikhKadam/google-research | 00a282388e389e09ce29109eb050491c96cfab85 | [
"Apache-2.0"
] | 110 | 2021-10-01T18:22:38.000Z | 2021-12-27T22:08:31.000Z | latent_programmer/decomposition_transformer_attention/train.py | admariner/google-research | 7cee4b22b925581d912e8d993625c180da2a5a4f | [
"Apache-2.0"
] | 1 | 2022-02-10T10:43:10.000Z | 2022-02-10T10:43:10.000Z | # coding=utf-8
# Copyright 2021 The Google Research Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicab... | 38.263421 | 96 | 0.661131 | 3,966 | 30,649 | 4.893343 | 0.159607 | 0.014737 | 0.01484 | 0.00541 | 0.278559 | 0.221054 | 0.170815 | 0.129077 | 0.093317 | 0.087597 | 0 | 0.009025 | 0.222683 | 30,649 | 800 | 97 | 38.31125 | 0.805574 | 0.181148 | 0 | 0.153025 | 0 | 0.001779 | 0.111071 | 0.00829 | 0 | 0 | 0 | 0.00125 | 0.003559 | 1 | 0.040925 | false | 0.001779 | 0.046263 | 0.003559 | 0.128114 | 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 | 0 | 0 | 1 | 0 |
86ebf47f1f35ac5baec5295be6bb6feebf67dc9a | 5,412 | py | Python | plot/profile_interpolation/plot_profile.py | ziyixi/SeisScripts | a484bc1747eae52b2441f0bfd47ac7e093150f1d | [
"MIT"
] | null | null | null | plot/profile_interpolation/plot_profile.py | ziyixi/SeisScripts | a484bc1747eae52b2441f0bfd47ac7e093150f1d | [
"MIT"
] | null | null | null | plot/profile_interpolation/plot_profile.py | ziyixi/SeisScripts | a484bc1747eae52b2441f0bfd47ac7e093150f1d | [
"MIT"
] | null | null | null | import matplotlib.pyplot as plt
import numpy as np
import pandas as pd
import click
import numba
def prepare_data(data_pd, parameter):
lon_set = set(data_pd["lon"])
lat_set = set(data_pd["lat"])
dep_set = set(data_pd["dep"])
lon_list = sorted(lon_set)
lat_list = sorted(lat_set)
dep_list = sor... | 34.037736 | 153 | 0.636179 | 879 | 5,412 | 3.715586 | 0.17975 | 0.038579 | 0.04899 | 0.017146 | 0.271586 | 0.181568 | 0.098592 | 0.098592 | 0.054501 | 0.03613 | 0 | 0.022911 | 0.201589 | 5,412 | 158 | 154 | 34.253165 | 0.731775 | 0.055617 | 0 | 0.05 | 0 | 0.008333 | 0.055664 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.066667 | false | 0 | 0.041667 | 0.025 | 0.166667 | 0.008333 | 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 | 0 | 1 | 0 |
86ebfc32e5da592e6e4c3fa48a02c7a3cbe0a2ce | 367 | py | Python | tests/test_heroku.py | edpaget/flask-appconfig | 5264719ac9229339070b219a4358a3203ffd05b0 | [
"MIT"
] | 61 | 2015-01-28T21:19:11.000Z | 2020-12-28T10:12:28.000Z | tests/test_heroku.py | edpaget/flask-appconfig | 5264719ac9229339070b219a4358a3203ffd05b0 | [
"MIT"
] | 3 | 2016-01-25T00:09:55.000Z | 2017-09-25T11:36:19.000Z | tests/test_heroku.py | edpaget/flask-appconfig | 5264719ac9229339070b219a4358a3203ffd05b0 | [
"MIT"
] | 14 | 2015-07-22T12:58:06.000Z | 2021-03-24T02:06:30.000Z | from flask import Flask
from flask_appconfig import HerokuConfig
def create_sample_app():
app = Flask('testapp')
HerokuConfig(app)
return app
def test_herokupostgres(monkeypatch):
monkeypatch.setenv('HEROKU_POSTGRESQL_ORANGE_URL', 'heroku-db-uri')
app = create_sample_app()
assert app.config... | 22.9375 | 71 | 0.746594 | 46 | 367 | 5.717391 | 0.543478 | 0.068441 | 0.114068 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.152589 | 367 | 15 | 72 | 24.466667 | 0.845659 | 0 | 0 | 0 | 0 | 0 | 0.228883 | 0.138965 | 0 | 0 | 0 | 0 | 0.1 | 1 | 0.2 | false | 0 | 0.2 | 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 | 0 | 0 | 0 | 0 | 1 | 0 |
86ec0f9bcbbfb50a7fe60cb1505775e1803a9dd4 | 396 | py | Python | flask/util/logger.py | Dev-Jahn/cms | 84ea115bdb865daff83d069502f6f0dd105fc4f0 | [
"RSA-MD"
] | null | null | null | flask/util/logger.py | Dev-Jahn/cms | 84ea115bdb865daff83d069502f6f0dd105fc4f0 | [
"RSA-MD"
] | 9 | 2021-01-05T07:48:28.000Z | 2021-05-14T06:38:27.000Z | flask/util/logger.py | Dev-Jahn/cms | 84ea115bdb865daff83d069502f6f0dd105fc4f0 | [
"RSA-MD"
] | 4 | 2021-01-05T06:46:09.000Z | 2021-05-06T01:44:28.000Z | import logging
"""
Formatter
"""
formatter = logging.Formatter('%(asctime)s - %(name)s - %(levelname)s - %(message)s', datefmt='%Y-%m-%d:%H:%M:%S')
"""
Set Flask logger
"""
logger = logging.getLogger('FLASK_LOG')
logger.setLevel(logging.DEBUG)
stream_log = logging.StreamHandler()
stream_log.setFormatter(form... | 20.842105 | 114 | 0.699495 | 50 | 396 | 5.46 | 0.54 | 0.098901 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.118687 | 396 | 18 | 115 | 22 | 0.782235 | 0.085859 | 0 | 0 | 0 | 0 | 0.251613 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.142857 | 0 | 0.142857 | 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 | 0 | 0 | 1 | 0 |
86ecab271dab8a62fddc0d43582d82c9d0efb150 | 1,592 | py | Python | utils/backups/backup_psql.py | Krovatkin/NewsBlur | 2a5b52984c9d29c864eb80e9c60c658b1f25f7c5 | [
"MIT"
] | null | null | null | utils/backups/backup_psql.py | Krovatkin/NewsBlur | 2a5b52984c9d29c864eb80e9c60c658b1f25f7c5 | [
"MIT"
] | null | null | null | utils/backups/backup_psql.py | Krovatkin/NewsBlur | 2a5b52984c9d29c864eb80e9c60c658b1f25f7c5 | [
"MIT"
] | null | null | null | #!/usr/bin/python3
import os
import sys
import socket
CURRENT_DIR = os.path.dirname(__file__)
NEWSBLUR_DIR = ''.join([CURRENT_DIR, '/../../'])
sys.path.insert(0, NEWSBLUR_DIR)
os.environ['DJANGO_SETTINGS_MODULE'] = 'newsblur_web.settings'
import threading
class ProgressPercentage(object):
def __init__(self, fil... | 34.608696 | 108 | 0.682161 | 220 | 1,592 | 4.609091 | 0.409091 | 0.039448 | 0.039448 | 0.051282 | 0.117357 | 0.04142 | 0 | 0 | 0 | 0 | 0 | 0.016204 | 0.18593 | 1,592 | 45 | 109 | 35.377778 | 0.766204 | 0.047739 | 0 | 0 | 0 | 0.028571 | 0.135403 | 0.090489 | 0 | 0 | 0 | 0 | 0 | 1 | 0.057143 | false | 0 | 0.2 | 0 | 0.285714 | 0.028571 | 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 | 0 | 1 | 0 |
86ecdb5499de55821a90a7d456c0a5f3e2bbff3c | 22,780 | py | Python | onap_tests/scenario/solution.py | Orange-OpenSource/xtesting-onap-tests | ce4237f49089a91c81f5fad552f78fec384fd504 | [
"Apache-2.0"
] | null | null | null | onap_tests/scenario/solution.py | Orange-OpenSource/xtesting-onap-tests | ce4237f49089a91c81f5fad552f78fec384fd504 | [
"Apache-2.0"
] | null | null | null | onap_tests/scenario/solution.py | Orange-OpenSource/xtesting-onap-tests | ce4237f49089a91c81f5fad552f78fec384fd504 | [
"Apache-2.0"
] | 2 | 2018-06-08T15:49:51.000Z | 2021-06-22T10:06:30.000Z | #!/usr/bin/python
#
# This program and the accompanying materials
# are made available under the terms of the Apache License, Version 2.0
# which accompanies this distribution, and is available at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# pylint: disable=missing-docstring
# pylint: disable=duplicate-c... | 42.342007 | 80 | 0.554478 | 2,474 | 22,780 | 4.785772 | 0.090946 | 0.069932 | 0.083446 | 0.041892 | 0.516892 | 0.425929 | 0.343159 | 0.28277 | 0.262922 | 0.240625 | 0 | 0.001187 | 0.334197 | 22,780 | 537 | 81 | 42.420857 | 0.779455 | 0.106234 | 0 | 0.251989 | 0 | 0 | 0.186011 | 0.054534 | 0 | 0 | 0 | 0.001862 | 0 | 1 | 0.047745 | false | 0 | 0.02122 | 0 | 0.106101 | 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 | 0 | 0 | 1 | 0 |
86ecf5f6a01c26c5389153d1137d146050eff0e3 | 3,262 | py | Python | tutorials/Controls4Docs/ControlEventsGraph.py | dominic-dev/pyformsd | 23e31ceff2943bc0f7286d25dd14450a14b986af | [
"MIT"
] | null | null | null | tutorials/Controls4Docs/ControlEventsGraph.py | dominic-dev/pyformsd | 23e31ceff2943bc0f7286d25dd14450a14b986af | [
"MIT"
] | null | null | null | tutorials/Controls4Docs/ControlEventsGraph.py | dominic-dev/pyformsd | 23e31ceff2943bc0f7286d25dd14450a14b986af | [
"MIT"
] | null | null | null | #!/usr/bin/python
# -*- coding: utf-8 -*-
__author__ = "Ricardo Ribeiro"
__credits__ = ["Ricardo Ribeiro"]
__license__ = "MIT"
__version__ = "0.0"
__maintainer__ = "Ricardo Ribeiro"
__email__ = "ricardojvr@gmail.com"
__status__ = "Development"
from __init__ import *
import random, time
f... | 27.183333 | 116 | 0.62477 | 388 | 3,262 | 4.920103 | 0.260309 | 0.056574 | 0.066003 | 0.059717 | 0.319539 | 0.319539 | 0.271346 | 0.271346 | 0.271346 | 0.2022 | 0 | 0.02726 | 0.14531 | 3,262 | 120 | 117 | 27.183333 | 0.657461 | 0.061925 | 0 | 0.181818 | 0 | 0 | 0.085883 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.090909 | false | 0 | 0.038961 | 0 | 0.142857 | 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 | 0 | 0 | 1 | 0 |
86eee025668f1ba4e581d9197ce7264211e57bc7 | 3,704 | py | Python | tempest/tests/lib/services/compute/test_security_group_default_rules_client.py | mail2nsrajesh/tempest | 1a3b3dc50b418d3a15839830d7d1ff88c8c76cff | [
"Apache-2.0"
] | 254 | 2015-01-05T19:22:52.000Z | 2022-03-29T08:14:54.000Z | tempest/tests/lib/services/compute/test_security_group_default_rules_client.py | mail2nsrajesh/tempest | 1a3b3dc50b418d3a15839830d7d1ff88c8c76cff | [
"Apache-2.0"
] | 13 | 2015-03-02T15:53:04.000Z | 2022-02-16T02:28:14.000Z | tempest/tests/lib/services/compute/test_security_group_default_rules_client.py | mail2nsrajesh/tempest | 1a3b3dc50b418d3a15839830d7d1ff88c8c76cff | [
"Apache-2.0"
] | 367 | 2015-01-07T15:05:39.000Z | 2022-03-04T09:50:35.000Z | # Copyright 2015 NEC Corporation. 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 ... | 41.617978 | 78 | 0.704644 | 469 | 3,704 | 5.149254 | 0.268657 | 0.113043 | 0.173913 | 0.119255 | 0.619462 | 0.537888 | 0.487785 | 0.375983 | 0.276605 | 0.164803 | 0 | 0.013803 | 0.217603 | 3,704 | 88 | 79 | 42.090909 | 0.819531 | 0.162797 | 0 | 0.229508 | 0 | 0 | 0.12504 | 0.086168 | 0 | 0 | 0 | 0 | 0 | 1 | 0.180328 | false | 0 | 0.04918 | 0 | 0.262295 | 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 | 0 | 0 | 1 | 0 |
86ef847c1cba2674adc29aa5bed41c18d23f595a | 24,723 | py | Python | memos/memos/models/Memo.py | iotexpert/docmgr | 735c7bcbaeb73bc44efecffb175f268f2438ac3a | [
"MIT"
] | null | null | null | memos/memos/models/Memo.py | iotexpert/docmgr | 735c7bcbaeb73bc44efecffb175f268f2438ac3a | [
"MIT"
] | null | null | null | memos/memos/models/Memo.py | iotexpert/docmgr | 735c7bcbaeb73bc44efecffb175f268f2438ac3a | [
"MIT"
] | null | null | null | """
The model file for a Memo
"""
import re
import os
import shutil
import json
from datetime import datetime
from flask import current_app
from memos import db
from memos.models.User import User
from memos.models.MemoState import MemoState
from memos.models.MemoFile import MemoFile
from memos.models.MemoSignature i... | 39.367834 | 190 | 0.582049 | 2,871 | 24,723 | 4.896203 | 0.110066 | 0.019919 | 0.032013 | 0.028456 | 0.452728 | 0.393825 | 0.35605 | 0.31358 | 0.291598 | 0.255389 | 0 | 0.003271 | 0.282692 | 24,723 | 628 | 191 | 39.367834 | 0.789388 | 0.118028 | 0 | 0.336516 | 0 | 0.002387 | 0.081437 | 0.02107 | 0 | 0 | 0 | 0.001592 | 0.009547 | 1 | 0.095465 | false | 0 | 0.0358 | 0.00716 | 0.338902 | 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 | 0 | 0 | 1 | 0 |
86f07721893f6c50f28bc8f37736be7b92dba3a5 | 8,850 | py | Python | juliaset/juliaset.py | PageotD/juliaset | 7c1f98020eeff291fcf040cfcdf25a89e72f46a9 | [
"BSD-3-Clause"
] | null | null | null | juliaset/juliaset.py | PageotD/juliaset | 7c1f98020eeff291fcf040cfcdf25a89e72f46a9 | [
"BSD-3-Clause"
] | null | null | null | juliaset/juliaset.py | PageotD/juliaset | 7c1f98020eeff291fcf040cfcdf25a89e72f46a9 | [
"BSD-3-Clause"
] | 1 | 2021-08-09T06:45:43.000Z | 2021-08-09T06:45:43.000Z | import numpy as np
import matplotlib.pyplot as plt
import matplotlib.cm as cm
import random
class JuliaSet:
def __init__(self):
"""
Constructor of the JuliaSet class
:param size: size in pixels (for both width and height)
:param dpi: dots per inch (default 300)
"""
... | 32.417582 | 89 | 0.566328 | 1,124 | 8,850 | 4.44395 | 0.268683 | 0.008008 | 0.014414 | 0.003203 | 0.204605 | 0.181381 | 0.151752 | 0.141742 | 0.122122 | 0.122122 | 0 | 0.027298 | 0.345989 | 8,850 | 272 | 90 | 32.536765 | 0.835695 | 0.418757 | 0 | 0.019802 | 0 | 0 | 0.03162 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.089109 | false | 0 | 0.039604 | 0 | 0.188119 | 0.009901 | 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 | 0 | 1 | 0 |
86f0877f437e0d2341e2d9c4fb9323bda9c076fe | 1,212 | py | Python | eye_detection.py | ShivanS93/VAtest_withOKN | 8da76f4c3ff526c9e16268194accfdc6221b0a66 | [
"MIT"
] | null | null | null | eye_detection.py | ShivanS93/VAtest_withOKN | 8da76f4c3ff526c9e16268194accfdc6221b0a66 | [
"MIT"
] | null | null | null | eye_detection.py | ShivanS93/VAtest_withOKN | 8da76f4c3ff526c9e16268194accfdc6221b0a66 | [
"MIT"
] | null | null | null | #!python3
# eye_detection.py - detect eyes using webcam
# tutorial: https://www.roytuts.com/real-time-eye-detection-in-webcam-using-python-3/
import cv2
import math
import numpy as np
def main():
faceCascade = cv2.CascadeClassifier("haarcascade_frontalface_alt.xml")
eyeCascade = cv2.CascadeClassifier("haarc... | 24.734694 | 86 | 0.575908 | 158 | 1,212 | 4.310127 | 0.525316 | 0.035242 | 0.091043 | 0.011747 | 0.017621 | 0.017621 | 0 | 0 | 0 | 0 | 0 | 0.029481 | 0.30033 | 1,212 | 48 | 87 | 25.25 | 0.773585 | 0.143564 | 0 | 0.071429 | 0 | 0 | 0.061955 | 0.03001 | 0 | 0 | 0.003872 | 0 | 0 | 1 | 0.035714 | false | 0 | 0.107143 | 0 | 0.142857 | 0.035714 | 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 | 0 | 1 | 0 |
86f19d8269d91051babd1a81669ee8409fe871bc | 1,328 | py | Python | demo/cnn_predict.py | huynhtnhut97/keras-video-classifier | 3ea6a8d671f3bd3cc8eddef64ad75abc2a2d593a | [
"MIT"
] | 108 | 2018-03-01T10:03:22.000Z | 2022-03-27T03:00:30.000Z | demo/cnn_predict.py | drsagitn/lstm-video-classifier | 3d1bce6773e493bdff5d623883d47ca68d45e890 | [
"MIT"
] | 18 | 2020-01-28T22:13:07.000Z | 2022-03-11T23:54:10.000Z | demo/cnn_predict.py | drsagitn/lstm-video-classifier | 3d1bce6773e493bdff5d623883d47ca68d45e890 | [
"MIT"
] | 56 | 2018-03-01T10:03:22.000Z | 2022-02-23T08:19:10.000Z | import numpy as np
from keras import backend as K
import os
import sys
K.set_image_dim_ordering('tf')
def patch_path(path):
return os.path.join(os.path.dirname(__file__), path)
def main():
sys.path.append(patch_path('..'))
data_dir_path = patch_path('very_large_data')
model_dir_path = patch_path('... | 30.883721 | 110 | 0.758283 | 191 | 1,328 | 4.848168 | 0.350785 | 0.12959 | 0.084233 | 0.055076 | 0.110151 | 0 | 0 | 0 | 0 | 0 | 0 | 0.007086 | 0.149849 | 1,328 | 43 | 111 | 30.883721 | 0.813109 | 0 | 0 | 0 | 0 | 0 | 0.045899 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.071429 | false | 0 | 0.214286 | 0.035714 | 0.321429 | 0.035714 | 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 | 0 | 1 | 0 |
86f3e8f2399f57967d9da67546eaf7a9b7b31fb7 | 2,139 | py | Python | backend/src/baserow/api/user/registries.py | ashishdhngr/baserow | b098678d2165eb7c42930ee24dc6753a3cb520c3 | [
"MIT"
] | 1 | 2022-01-24T15:12:02.000Z | 2022-01-24T15:12:02.000Z | backend/src/baserow/api/user/registries.py | rasata/baserow | c6e1d7842c53f801e1c96b49f1377da2a06afaa9 | [
"MIT"
] | null | null | null | backend/src/baserow/api/user/registries.py | rasata/baserow | c6e1d7842c53f801e1c96b49f1377da2a06afaa9 | [
"MIT"
] | null | null | null | from baserow.core.registry import Instance, Registry
class UserDataType(Instance):
"""
The user data type can be used to inject an additional payload to the API
JWT response. This is the response when a user authenticates or refreshes his
token. The returned dict of the `get_user_data` method is added... | 28.905405 | 85 | 0.633006 | 259 | 2,139 | 5.15444 | 0.305019 | 0.083895 | 0.041199 | 0.047191 | 0.318352 | 0.265169 | 0.224719 | 0.182772 | 0.182772 | 0.182772 | 0 | 0.000663 | 0.29453 | 2,139 | 73 | 86 | 29.30137 | 0.884029 | 0.614306 | 0 | 0 | 0 | 0 | 0.131261 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.142857 | false | 0 | 0.071429 | 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 | 0 | 0 | 0 | 0 | 1 | 0 |
86f4958fe557f64425c53fe4dff977306ba95b20 | 17,197 | py | Python | Week 2/code.py | aklsh/EE2703 | 546b70c9adac4a4de294d83affbb74e480c2f65d | [
"MIT"
] | null | null | null | Week 2/code.py | aklsh/EE2703 | 546b70c9adac4a4de294d83affbb74e480c2f65d | [
"MIT"
] | null | null | null | Week 2/code.py | aklsh/EE2703 | 546b70c9adac4a4de294d83affbb74e480c2f65d | [
"MIT"
] | 3 | 2020-07-15T08:02:05.000Z | 2021-03-07T06:50:07.000Z | '''
-------------------------------------
Assignment 2 - EE2703 (Jan-May 2020)
Done by Akilesh Kannan (EE18B122)
Created on 18/01/20
Last Modified on 04/02/20
-------------------------------------
'''
# importing necessary libraries
import sys
import cmath
import numpy as np
import pandas as pd
# To improve reada... | 53.241486 | 209 | 0.51823 | 1,700 | 17,197 | 5.214118 | 0.151176 | 0.060921 | 0.047157 | 0.041968 | 0.581115 | 0.562049 | 0.483529 | 0.446074 | 0.407604 | 0.378384 | 0 | 0.032548 | 0.365761 | 17,197 | 322 | 210 | 53.406832 | 0.780141 | 0.075536 | 0 | 0.338521 | 0 | 0.003891 | 0.04532 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.042802 | false | 0 | 0.015564 | 0 | 0.120623 | 0.011673 | 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 | 0 | 1 | 0 |
86f530cec67d3e933cfc6fd5269d65218a8b2c49 | 880 | py | Python | Lib/Co.py | M507/Guessing-passwords-using-machine-learning | da90cfa30ce2e7a5e08ee528f594fa047ecea75c | [
"Apache-2.0"
] | 6 | 2020-05-18T14:20:23.000Z | 2021-04-23T16:31:34.000Z | Lib/Co.py | M507/Guessing-passwords-using-machine-learning | da90cfa30ce2e7a5e08ee528f594fa047ecea75c | [
"Apache-2.0"
] | null | null | null | Lib/Co.py | M507/Guessing-passwords-using-machine-learning | da90cfa30ce2e7a5e08ee528f594fa047ecea75c | [
"Apache-2.0"
] | 1 | 2020-05-18T21:19:52.000Z | 2020-05-18T21:19:52.000Z | import subprocess
import os.path
"""
Stylish input()
"""
def s_input(string):
return input(string+">").strip("\n")
"""
Execute command locally
"""
def execute_command(command):
if len(command) > 0:
print(command)
proc = subprocess.Popen(command.split(" "), stdout=subprocess.PIPE, cwd="/tmp")... | 20.952381 | 87 | 0.619318 | 110 | 880 | 4.936364 | 0.481818 | 0.033149 | 0.014733 | 0.018416 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.001477 | 0.230682 | 880 | 41 | 88 | 21.463415 | 0.800591 | 0.088636 | 0 | 0 | 0 | 0 | 0.025074 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.190476 | false | 0 | 0.095238 | 0.047619 | 0.52381 | 0.047619 | 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 | 0 | 1 | 0 |
86f661785147d1c962908ad8a5f0840e9e70661d | 446 | py | Python | project3_code/part_0/main.py | rachelbrown347/CS294-26_code | 72a20a9ab75345091d2a743b13857d7a88adf9be | [
"MIT"
] | 1 | 2022-03-12T00:55:52.000Z | 2022-03-12T00:55:52.000Z | project3_code/part_0/main.py | rachelbrown347/CS294-26_code | 72a20a9ab75345091d2a743b13857d7a88adf9be | [
"MIT"
] | null | null | null | project3_code/part_0/main.py | rachelbrown347/CS294-26_code | 72a20a9ab75345091d2a743b13857d7a88adf9be | [
"MIT"
] | null | null | null | import numpy as np
import matplotlib.pyplot as plt
from skimage.exposure import rescale_intensity
from unsharp import *
# Load file and normalize to 0-1
fname = 'iguana.jpg'
im = plt.imread(fname)
if im.mean() >= 1:
im = im/255.
sigma = 5
amplitude = 1.5
imsharp = unsharp_mask(im, sigma, amplitude)
imsharp = re... | 23.473684 | 70 | 0.726457 | 73 | 446 | 4.328767 | 0.547945 | 0.018987 | 0.044304 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.036842 | 0.147982 | 446 | 19 | 71 | 23.473684 | 0.794737 | 0.067265 | 0 | 0 | 0 | 0 | 0.048193 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.285714 | 0 | 0.285714 | 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 | 0 | 0 | 1 | 0 |
86f7e1041ab1f4accc4c1f71bcc457ad4e75b7b3 | 6,672 | py | Python | tools/lucid/engine.py | Petr-By/qtpyvis | 0b9a151ee6b9a56b486c2bece9c1f03414629efc | [
"MIT"
] | 3 | 2017-10-04T14:51:26.000Z | 2017-10-22T09:35:50.000Z | tools/lucid/engine.py | CogSciUOS/DeepLearningToolbox | bf07578b9486d8c48e25df357bc4b9963b513b46 | [
"MIT"
] | 13 | 2017-09-05T12:56:11.000Z | 2017-11-22T10:38:27.000Z | tools/lucid/engine.py | CogSciUOS/DeepLearningToolbox | bf07578b9486d8c48e25df357bc4b9963b513b46 | [
"MIT"
] | 2 | 2017-09-24T21:39:42.000Z | 2017-10-04T15:29:54.000Z | import logging
logger = logging.getLogger(__name__)
print(f"!!!!!!!!!! getEffectiveLevel: {logger.getEffectiveLevel()} !!!!!!!!!!!!!")
from dltb.base.observer import Observable, change
from network import Network, loader
from network.lucid import Network as LucidNetwork
# lucid.modelzoo.vision_models:
# A module ... | 30.190045 | 82 | 0.590528 | 821 | 6,672 | 4.669915 | 0.16687 | 0.053991 | 0.067814 | 0.040167 | 0.370631 | 0.340636 | 0.284559 | 0.23422 | 0.214919 | 0.159624 | 0 | 0.000435 | 0.310402 | 6,672 | 220 | 83 | 30.327273 | 0.832862 | 0.22482 | 0 | 0.351563 | 0 | 0 | 0.078839 | 0.016056 | 0 | 0 | 0 | 0.004545 | 0 | 1 | 0.140625 | false | 0 | 0.085938 | 0 | 0.34375 | 0.007813 | 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 | 0 | 1 | 0 |
86f8485704c303133a8ffd7f513a5c4076214c94 | 87,649 | py | Python | synapse/storage/events.py | natamelo/synapse | 3d870ecfc5353e455917166cb5c2bb8ba48a6ebd | [
"Apache-2.0"
] | null | null | null | synapse/storage/events.py | natamelo/synapse | 3d870ecfc5353e455917166cb5c2bb8ba48a6ebd | [
"Apache-2.0"
] | null | null | null | synapse/storage/events.py | natamelo/synapse | 3d870ecfc5353e455917166cb5c2bb8ba48a6ebd | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
# Copyright 2014-2016 OpenMarket Ltd
# Copyright 2018-2019 New Vector Ltd
# Copyright 2019 The Matrix.org Foundation C.I.C.
#
# 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 Licens... | 39.339767 | 89 | 0.578455 | 10,183 | 87,649 | 4.718943 | 0.087892 | 0.022725 | 0.035731 | 0.007908 | 0.385616 | 0.307639 | 0.250328 | 0.200882 | 0.168501 | 0.147608 | 0 | 0.003698 | 0.355235 | 87,649 | 2,227 | 90 | 39.357432 | 0.846602 | 0.24686 | 0 | 0.312454 | 0 | 0 | 0.157629 | 0.024721 | 0 | 0 | 0 | 0.000449 | 0.000737 | 1 | 0.043478 | false | 0.000737 | 0.021371 | 0.000737 | 0.091378 | 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 | 0 | 0 | 1 | 0 |
86f92c20143e35ec634b684ad280aeb864a0957c | 3,074 | py | Python | dev/buildtool/metrics.py | premm1983/Spinnaker | 535f78b8f5402eea942c260cb9ca26682772a3e6 | [
"Apache-2.0"
] | null | null | null | dev/buildtool/metrics.py | premm1983/Spinnaker | 535f78b8f5402eea942c260cb9ca26682772a3e6 | [
"Apache-2.0"
] | null | null | null | dev/buildtool/metrics.py | premm1983/Spinnaker | 535f78b8f5402eea942c260cb9ca26682772a3e6 | [
"Apache-2.0"
] | null | null | null | # Copyright 2017 Google Inc. 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 a... | 39.410256 | 77 | 0.754717 | 357 | 3,074 | 6.285714 | 0.420168 | 0.049911 | 0.037879 | 0.042781 | 0.15508 | 0.096702 | 0 | 0 | 0 | 0 | 0 | 0.003896 | 0.164932 | 3,074 | 77 | 78 | 39.922078 | 0.870277 | 0.278139 | 0 | 0.204082 | 0 | 0 | 0.165901 | 0.011949 | 0 | 0 | 0 | 0 | 0 | 1 | 0.081633 | false | 0 | 0.102041 | 0 | 0.265306 | 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 | 0 | 0 | 1 | 0 |
86fafa9c771d30389c672ab69f2d0d2991d82592 | 4,967 | py | Python | fat/fat_bert_nq/ppr/apr_lib.py | kiss2u/google-research | 2cd66234656f9e2f4218ed90a2d8aa9cf3139093 | [
"Apache-2.0"
] | 1 | 2020-05-27T15:40:17.000Z | 2020-05-27T15:40:17.000Z | fat/fat_bert_nq/ppr/apr_lib.py | kiss2u/google-research | 2cd66234656f9e2f4218ed90a2d8aa9cf3139093 | [
"Apache-2.0"
] | 7 | 2021-08-25T16:15:53.000Z | 2022-02-10T03:26:55.000Z | fat/fat_bert_nq/ppr/apr_lib.py | kiss2u/google-research | 2cd66234656f9e2f4218ed90a2d8aa9cf3139093 | [
"Apache-2.0"
] | null | null | null | # coding=utf-8
# Copyright 2020 The Google Research Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicab... | 35.478571 | 80 | 0.684518 | 725 | 4,967 | 4.514483 | 0.32 | 0.050412 | 0.023831 | 0.025665 | 0.158265 | 0.150932 | 0.134128 | 0.117324 | 0.05194 | 0.05194 | 0 | 0.007849 | 0.230521 | 4,967 | 139 | 81 | 35.733813 | 0.848509 | 0.342259 | 0 | 0.16 | 0 | 0 | 0.065802 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.04 | false | 0 | 0.106667 | 0 | 0.186667 | 0.026667 | 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 | 0 | 1 | 0 |
86fc7c6a00ab6863dd9ce69648b4b5568994e8af | 6,941 | py | Python | src/optimal_gardening.py | evanlynch/optimal-gardening | 447ca8575efac1ad5cdd975091f3cbb67721e167 | [
"MIT"
] | null | null | null | src/optimal_gardening.py | evanlynch/optimal-gardening | 447ca8575efac1ad5cdd975091f3cbb67721e167 | [
"MIT"
] | null | null | null | src/optimal_gardening.py | evanlynch/optimal-gardening | 447ca8575efac1ad5cdd975091f3cbb67721e167 | [
"MIT"
] | null | null | null | import os
import sys
import time
from IPython.display import Image
import matplotlib.pyplot as plt
import numpy as np
import pandas as pd
import seaborn as sb
sb.set_style("dark")
#### Initial Setup ####
#plant info
plant_info = pd.read_csv('../data/plant_data.csv')
plant_info.index.name = 'plant_index'
plants = pla... | 39.662857 | 168 | 0.711713 | 1,089 | 6,941 | 4.341598 | 0.264463 | 0.02665 | 0.010998 | 0.020305 | 0.090102 | 0.018613 | 0 | 0 | 0 | 0 | 0 | 0.013751 | 0.172309 | 6,941 | 175 | 169 | 39.662857 | 0.809225 | 0.285406 | 0 | 0.018182 | 0 | 0 | 0.077034 | 0.004544 | 0 | 0 | 0 | 0 | 0 | 1 | 0.081818 | false | 0 | 0.072727 | 0 | 0.218182 | 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 | 0 | 0 | 1 | 0 |
86fca5740e3caf795c7b7090059ab5992cec0e59 | 9,453 | py | Python | adv_lib/utils/attack_utils.py | Daulbaev/adversarial-library | 6f979a511ad78908374cd55855a9e2c5a874be7d | [
"BSD-3-Clause"
] | 55 | 2020-11-25T10:47:48.000Z | 2022-03-21T12:11:31.000Z | adv_lib/utils/attack_utils.py | Daulbaev/adversarial-library | 6f979a511ad78908374cd55855a9e2c5a874be7d | [
"BSD-3-Clause"
] | 4 | 2021-03-10T19:25:31.000Z | 2021-08-06T00:10:49.000Z | adv_lib/utils/attack_utils.py | Daulbaev/adversarial-library | 6f979a511ad78908374cd55855a9e2c5a874be7d | [
"BSD-3-Clause"
] | 8 | 2020-11-26T08:42:04.000Z | 2022-01-13T02:55:47.000Z | import warnings
from collections import OrderedDict
from distutils.version import LooseVersion
from functools import partial
from inspect import isclass
from typing import Callable, Optional, Dict, Union
import numpy as np
import torch
import tqdm
from torch import Tensor, nn
from torch.nn import functional as F
from... | 41.643172 | 117 | 0.66307 | 1,226 | 9,453 | 4.914356 | 0.200653 | 0.012946 | 0.010954 | 0.014108 | 0.243651 | 0.190207 | 0.157344 | 0.13195 | 0.108382 | 0.075021 | 0 | 0.00965 | 0.210727 | 9,453 | 226 | 118 | 41.827434 | 0.797882 | 0.102507 | 0 | 0.086957 | 0 | 0.006211 | 0.091116 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.031056 | false | 0 | 0.080745 | 0 | 0.136646 | 0.049689 | 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 | 0 | 1 | 0 |
86fd1a571a9b46918806e9e8e71337c7e3431481 | 2,559 | py | Python | thawSlumpChangeDet/polygons_compare.py | Summer0328/ChangeDet_DL-1 | f2474ee4200d9ad093c0e5a27a94bfbd3bd038e7 | [
"MIT"
] | 3 | 2021-07-03T14:33:37.000Z | 2021-08-03T20:35:32.000Z | thawSlumpChangeDet/polygons_compare.py | Summer0328/ChangeDet_DL-1 | f2474ee4200d9ad093c0e5a27a94bfbd3bd038e7 | [
"MIT"
] | null | null | null | thawSlumpChangeDet/polygons_compare.py | Summer0328/ChangeDet_DL-1 | f2474ee4200d9ad093c0e5a27a94bfbd3bd038e7 | [
"MIT"
] | 2 | 2021-07-29T01:45:33.000Z | 2021-08-10T09:13:58.000Z | #!/usr/bin/env python
# Filename: polygons_cd
"""
introduction: compare two polygons in to shape file
authors: Huang Lingcao
email:huanglingcao@gmail.com
add time: 26 February, 2020
"""
import sys,os
from optparse import OptionParser
# added path of DeeplabforRS
sys.path.insert(0, os.path.expanduser('~/codes/Pychar... | 30.105882 | 108 | 0.709261 | 359 | 2,559 | 4.740947 | 0.350975 | 0.041128 | 0.029377 | 0.022914 | 0.199177 | 0.166863 | 0.058754 | 0.058754 | 0.058754 | 0.058754 | 0 | 0.014648 | 0.199687 | 2,559 | 84 | 109 | 30.464286 | 0.816406 | 0.208284 | 0 | 0 | 0 | 0 | 0.175412 | 0.031984 | 0 | 0 | 0 | 0 | 0.05 | 1 | 0.025 | false | 0 | 0.2 | 0 | 0.225 | 0.025 | 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 | 0 | 1 | 0 |
86fdb0073cd3ede47fd363784958394b48bca5e1 | 919 | py | Python | andela_labs/Car Class Lab (OOP)/car.py | brotich/andela_bootcamp_X | 19fc5bb66d3c930d4e6b9afeb45abc00bbc4c2ea | [
"MIT"
] | null | null | null | andela_labs/Car Class Lab (OOP)/car.py | brotich/andela_bootcamp_X | 19fc5bb66d3c930d4e6b9afeb45abc00bbc4c2ea | [
"MIT"
] | null | null | null | andela_labs/Car Class Lab (OOP)/car.py | brotich/andela_bootcamp_X | 19fc5bb66d3c930d4e6b9afeb45abc00bbc4c2ea | [
"MIT"
] | null | null | null | class Car(object):
"""
Car class that can be used to instantiate various vehicles.
It takes in arguments that depict the type, model, and name
of the vehicle
"""
def __init__(self, name="General", model="GM", car_type="saloon"):
num_of_wheels = 4
num_of_doors = 4
... | 24.837838 | 70 | 0.553863 | 122 | 919 | 3.97541 | 0.418033 | 0.082474 | 0.090722 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.021739 | 0.349293 | 919 | 36 | 71 | 25.527778 | 0.789298 | 0.145811 | 0 | 0 | 0 | 0 | 0.076101 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.136364 | false | 0 | 0 | 0.045455 | 0.272727 | 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 | 0 | 0 | 1 | 0 |
86ffc174e23653c3f067117004b1a24f8234310f | 711 | py | Python | basicapp/cron.py | shivamsinghal212/Url-Shortener | 4127a993272744f6f8592415314c8e8514d43153 | [
"MIT"
] | null | null | null | basicapp/cron.py | shivamsinghal212/Url-Shortener | 4127a993272744f6f8592415314c8e8514d43153 | [
"MIT"
] | 8 | 2020-06-05T18:23:15.000Z | 2022-03-11T23:23:57.000Z | basicapp/cron.py | shivamsinghal212/Url-Shortener | 4127a993272744f6f8592415314c8e8514d43153 | [
"MIT"
] | null | null | null | from django_cron import CronJobBase, Schedule
from .models import Link
from django.utils import timezone
class MyCronJob(CronJobBase):
RUN_EVERY_MINS = 1 # every 2 hours
schedule = Schedule(run_every_mins=RUN_EVERY_MINS)
code = 'basicapp.cron' # a unique code
def do(self):
current_time = t... | 30.913043 | 65 | 0.610408 | 90 | 711 | 4.711111 | 0.577778 | 0.056604 | 0.084906 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.008114 | 0.30661 | 711 | 22 | 66 | 32.318182 | 0.851927 | 0.037975 | 0 | 0 | 0 | 0 | 0.164706 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.055556 | false | 0 | 0.166667 | 0 | 0.444444 | 0.166667 | 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 | 0 | 1 | 0 |