hexsha
stringlengths
40
40
size
int64
6
782k
ext
stringclasses
7 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
237
max_stars_repo_name
stringlengths
6
72
max_stars_repo_head_hexsha
stringlengths
40
40
max_stars_repo_licenses
list
max_stars_count
int64
1
53k
⌀
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
⌀
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
⌀
max_issues_repo_path
stringlengths
4
184
max_issues_repo_name
stringlengths
6
72
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
list
max_issues_count
int64
1
27.1k
⌀
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
⌀
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
⌀
max_forks_repo_path
stringlengths
4
184
max_forks_repo_name
stringlengths
6
72
max_forks_repo_head_hexsha
stringlengths
40
40
max_forks_repo_licenses
list
max_forks_count
int64
1
12.2k
⌀
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
⌀
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
⌀
content
stringlengths
6
782k
avg_line_length
float64
2.75
664k
max_line_length
int64
5
782k
alphanum_fraction
float64
0
1
3932e6eb9aa4bfa623bd77834f1784a91f85204d
2,419
py
Python
_includes/snippets/python/monkey-patching/dynamic_init.py
MarauderXtreme/justus
229703abda2bd90d34232c97c64999c216d98239
[ "CC-BY-4.0" ]
1
2020-02-02T16:09:43.000Z
2020-02-02T16:09:43.000Z
_includes/snippets/python/monkey-patching/dynamic_init.py
MarauderXtreme/justus
229703abda2bd90d34232c97c64999c216d98239
[ "CC-BY-4.0" ]
1
2021-09-02T11:07:53.000Z
2021-09-02T11:07:53.000Z
_includes/snippets/python/monkey-patching/dynamic_init.py
MarauderXtreme/justus
229703abda2bd90d34232c97c64999c216d98239
[ "CC-BY-4.0" ]
null
null
null
#! /usr/bin/env python3 def auto_init(class_): def filter_func(fieldname): """ Return True if the field is not private and its value is a type """ if fieldname.startswith('_'): return False value = getattr(class_, fieldname) return isinstan...
24.19
76
0.54692
1a2fd60e4d1beee6888ddba7ed6af1def3c7d255
1,628
py
Python
src/onegov/form/__init__.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/form/__init__.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/form/__init__.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
import logging log = logging.getLogger('onegov.form') # noqa log.addHandler(logging.NullHandler()) # noqa from translationstring import TranslationStringFactory _ = TranslationStringFactory('onegov.form') # noqa from onegov.form.collection import ( FormCollection, FormSubmissionCollection, FormDefiniti...
25.4375
73
0.743857
649dc38cae305fdb7723c693fb8942a9684fcdf9
891
py
Python
Code/inv_func_2d.py
knirschl/Proseminar-Anthropomatik
0408e54cf220c40a6f3deae6ae8d38c5f1f4f387
[ "MIT" ]
null
null
null
Code/inv_func_2d.py
knirschl/Proseminar-Anthropomatik
0408e54cf220c40a6f3deae6ae8d38c5f1f4f387
[ "MIT" ]
null
null
null
Code/inv_func_2d.py
knirschl/Proseminar-Anthropomatik
0408e54cf220c40a6f3deae6ae8d38c5f1f4f387
[ "MIT" ]
null
null
null
import numpy as np import inv_func_1d as idf ''' Stack two arrays together as x, y value ''' def stack(L, L_): return np.stack((L, L_), axis=1) def expo_expo_inv(U): return stack(idf.expo_inv(U[:, 0]), idf.expo_inv(U[:, 1])) def expo_logistic_inv(U): return stack(idf.expo_inv(U[:, 0]), ...
26.205882
74
0.556678
207ac4d7788a46983ce4cbc10e24c993a788b6f1
368
py
Python
pws/keys.py
zamys/pws
b26ddb12cbbb00ef3a337d8b5a8ef7dc051d4b13
[ "MIT" ]
null
null
null
pws/keys.py
zamys/pws
b26ddb12cbbb00ef3a337d8b5a8ef7dc051d4b13
[ "MIT" ]
null
null
null
pws/keys.py
zamys/pws
b26ddb12cbbb00ef3a337d8b5a8ef7dc051d4b13
[ "MIT" ]
null
null
null
#imports import json #Twitter API Keys class GetKeys: def __init__(self): with open('pws/keys.json') as keys: key = json.load(keys) self.consumer = key['consumer'] self.consumer_secret = key['consumer_secret'] self.access_token = key['access_token'] self.ac...
23
61
0.63587
4452cbe3737b16947e82b62213d3dc770acaaee8
2,171
py
Python
gamedeals-bot-master/gamedealsbot.py
jaakaappi/archived-projects
be1f754eca7c1434f3a363b0ea8ebcd190a42436
[ "MIT" ]
null
null
null
gamedeals-bot-master/gamedealsbot.py
jaakaappi/archived-projects
be1f754eca7c1434f3a363b0ea8ebcd190a42436
[ "MIT" ]
3
2021-03-10T13:18:31.000Z
2021-05-11T09:20:11.000Z
gamedeals-bot-master/gamedealsbot.py
jaakaappi/archived-projects
be1f754eca7c1434f3a363b0ea8ebcd190a42436
[ "MIT" ]
null
null
null
import discord import os import json import models import traceback from sqlalchemy.orm import sessionmaker, exc from datetime import datetime def import_config(): try: with open(os.path.join(os.getcwd(), 'config.json')) as file: return json.loads(file.read()), file except OSError as erro...
38.087719
115
0.662368
a622f8018b4b36b5ba9c48bc3e1d186fa0809924
3,805
py
Python
DataProcess/tagPair/phase_tag_pair.py
zhangupkai/RFID_Script
9e05fad86e71dc6bd5dd12650d369f13d5a835c8
[ "MIT" ]
null
null
null
DataProcess/tagPair/phase_tag_pair.py
zhangupkai/RFID_Script
9e05fad86e71dc6bd5dd12650d369f13d5a835c8
[ "MIT" ]
null
null
null
DataProcess/tagPair/phase_tag_pair.py
zhangupkai/RFID_Script
9e05fad86e71dc6bd5dd12650d369f13d5a835c8
[ "MIT" ]
null
null
null
import matplotlib import numpy as np import pandas as pd import matplotlib.pyplot as plt from myunwrap import unwrap from filters import hampel from pre_purpose import deal_zero_phase import seaborn as sns from base_list import * import sys import math def deal_data(count): # if __name__ == '__main__': # count = ...
31.446281
108
0.567411
751697df24eeb7e44e3574766c8d56e069976f01
4,253
py
Python
research/cv/arcface/src/loss.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/cv/arcface/src/loss.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/cv/arcface/src/loss.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
24
2021-10-15T08:32:45.000Z
2022-03-24T18:45:20.000Z
# Copyright 2021 Huawei Technologies Co., Ltd # # 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...
34.298387
78
0.629908
fcaa9e951a468248b70cbbda530fcaf4e8377c9a
391
py
Python
Webpage/utils/keycloak_f/utils.py
ASV-Aachen/Website
bbfc02d71dde67fdf89a4b819b795a73435da7cf
[ "Apache-2.0" ]
null
null
null
Webpage/utils/keycloak_f/utils.py
ASV-Aachen/Website
bbfc02d71dde67fdf89a4b819b795a73435da7cf
[ "Apache-2.0" ]
46
2022-01-08T12:03:24.000Z
2022-03-30T08:51:05.000Z
Webpage/utils/keycloak_f/utils.py
ASV-Aachen/Website
bbfc02d71dde67fdf89a4b819b795a73435da7cf
[ "Apache-2.0" ]
null
null
null
def set_aktiv(id: str, keycloak_admin): try: keycloak_admin.update_user(user_id=id, payload={'enabled': 'True'}) except Exception as e: print(id) print(e) def sendPasswordToKeycloak(id: str, password: str, keycloak_admin): keycloak...
27.928571
83
0.616368
94acbdd92757e38ae511c2fee99d5d9cd33d3658
2,722
py
Python
scripts/mvb01_generate_validation.py
MahamadSalah/matbench
2d6d804ee8a43731feecf8ed90ad915c917ed790
[ "MIT" ]
15
2021-11-01T09:02:19.000Z
2022-03-19T10:59:41.000Z
scripts/mvb01_generate_validation.py
MahamadSalah/matbench
2d6d804ee8a43731feecf8ed90ad915c917ed790
[ "MIT" ]
62
2021-09-20T14:09:59.000Z
2022-03-30T19:03:22.000Z
scripts/mvb01_generate_validation.py
ardunn/matbench
7d11a2d63766339ec00e610e2255be29b81544d3
[ "MIT" ]
4
2021-03-22T10:37:42.000Z
2021-07-20T14:11:28.000Z
import os import json from monty.serialization import dumpfn from sklearn.model_selection import KFold, StratifiedKFold from matbench.data_ops import load from matbench.constants import REG_KEY, CLF_KEY, VALIDATION_METADATA_KEY, VALIDATION_SPLIT_KEY, TRAIN_KEY, TEST_KEY from matbench.metadata import mbv01_metadata i...
26.950495
115
0.59662
78697401f53d7f4f88ab69c2e41f79128232c984
1,859
py
Python
venv/Lib/site-packages/pynance/data/compare.py
LeonardoHMS/imobi
6b2b97a05df67ea7d493f7b601382f65c6629cc2
[ "MIT" ]
35
2015-03-12T04:16:14.000Z
2020-12-17T18:10:15.000Z
venv/Lib/site-packages/pynance/data/compare.py
LeonardoHMS/imobi
6b2b97a05df67ea7d493f7b601382f65c6629cc2
[ "MIT" ]
31
2015-03-16T21:31:04.000Z
2021-01-26T00:12:34.000Z
venv/Lib/site-packages/pynance/data/compare.py
LeonardoHMS/imobi
6b2b97a05df67ea7d493f7b601382f65c6629cc2
[ "MIT" ]
18
2015-09-30T10:40:26.000Z
2021-01-25T21:20:44.000Z
""" .. Copyright (c) 2016 Marshall Farrier license http://opensource.org/licenses/MIT Data - compare (:mod:`pynance.data.compare`) ================================================= .. currentmodule:: pynance.data.compare """ import numpy as np import pandas as pd def compare(eq_dfs, columns=None, selection='Clos...
29.507937
92
0.618612
1537b4a9fe558ffb912af8d0b9fff2babf4a563d
75
py
Python
rmpflow_using_class/n_test.py
YoshimitsuMatsutaIe/hoge_flow_test
22e2e2ce043a3107bd06449f6f9958641293e414
[ "MIT" ]
null
null
null
rmpflow_using_class/n_test.py
YoshimitsuMatsutaIe/hoge_flow_test
22e2e2ce043a3107bd06449f6f9958641293e414
[ "MIT" ]
null
null
null
rmpflow_using_class/n_test.py
YoshimitsuMatsutaIe/hoge_flow_test
22e2e2ce043a3107bd06449f6f9958641293e414
[ "MIT" ]
null
null
null
class A: def __init__(self, ): x = 1 a = A print(a.x)
9.375
26
0.426667
ecec11189299a2d843ca44ebe5df3217f738689b
406
py
Python
test_kazoeciao.py
luluci/gui_env
9c2ffe331c2dc8a7e128474ce9590498082de569
[ "MIT" ]
null
null
null
test_kazoeciao.py
luluci/gui_env
9c2ffe331c2dc8a7e128474ce9590498082de569
[ "MIT" ]
null
null
null
test_kazoeciao.py
luluci/gui_env
9c2ffe331c2dc8a7e128474ce9590498082de569
[ "MIT" ]
null
null
null
from ciaoutil import * kazoeciao_config.ciao_path("D:/home/Tools/kazoeciao158") kazoeciao_config.load_config_system() kazoeciao_config.load_config_autorun() if True: kazoeciao_config.compare_path( "D:/home/Python/python_sandbox/test/kazoeciao_cmp_test/before", "D:/home/Python/python_sandbox/test/kazoeciao_cmp_te...
27.066667
65
0.810345
01b93c907966b8a03f48827e7607c4139d5103e2
500
py
Python
7-assets/_SNIPPETS/bryan-guner-gists/_python/file_to_string.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
7-assets/_SNIPPETS/bryan-guner-gists/_python/file_to_string.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
7-assets/_SNIPPETS/bryan-guner-gists/_python/file_to_string.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
#!/usr/bin/env python import sys filename = sys.argv[1] # These do not remove \n with open(filename) as f: s = ''.join(f.readlines()) with open(filename) as f: s = ''.join(f) with open(filename) as f: s = f.read() # Fastest according to my tests. # These remove \n with open(filename) as f: s = ' ...
19.230769
54
0.602
01db8be11f9f236ded0863f3b2a86ba2b8a87b32
527
py
Python
crawlab/routes/schedules.py
anhilo/crawlab
363f4bf7a4ccc192a99850998c1bd0fc363832a1
[ "BSD-3-Clause" ]
1
2019-08-20T14:26:39.000Z
2019-08-20T14:26:39.000Z
crawlab/routes/schedules.py
anhilo/crawlab
363f4bf7a4ccc192a99850998c1bd0fc363832a1
[ "BSD-3-Clause" ]
9
2019-05-24T03:53:09.000Z
2022-02-26T10:53:48.000Z
crawlab/routes/schedules.py
anhilo/crawlab
363f4bf7a4ccc192a99850998c1bd0fc363832a1
[ "BSD-3-Clause" ]
1
2019-11-08T08:12:40.000Z
2019-11-08T08:12:40.000Z
import json import requests from constants.task import TaskStatus from db.manager import db_manager from routes.base import BaseApi from tasks.scheduler import scheduler from utils import jsonify from utils.spider import get_spider_col_fields class ScheduleApi(BaseApi): col_name = 'schedules' arguments = (...
20.269231
46
0.666034
bd55da687c3ff1c13edf681073a8631b8e6e5e84
3,605
py
Python
app/models/abtms/User.py
nucleo-de-telessaude-do-maranhao/abtms
8d1b1df223d9f07fc4447836011f3e3678625d59
[ "MIT" ]
null
null
null
app/models/abtms/User.py
nucleo-de-telessaude-do-maranhao/abtms
8d1b1df223d9f07fc4447836011f3e3678625d59
[ "MIT" ]
null
null
null
app/models/abtms/User.py
nucleo-de-telessaude-do-maranhao/abtms
8d1b1df223d9f07fc4447836011f3e3678625d59
[ "MIT" ]
1
2019-03-13T14:34:24.000Z
2019-03-13T14:34:24.000Z
from app.models.auth.DatabaseFactory import DatabaseFactory class User(): def __init__(self, code=0, name="", email="", password=""): self.code = code self.name = name self.email = email self.password = password self.connection = DatabaseFactory().getConnection() def getAllAdmins(self): wi...
24.691781
159
0.608599
da2bae94ac3cfe981506d6235438358cb02ee52b
3,283
py
Python
Beginner/03. Python/Tic-tac-toe.py
ankita080208/Hacktoberfest
2be849e89285260e7b6672f42979943ad6bbec78
[ "MIT" ]
1
2021-10-04T05:41:43.000Z
2021-10-04T05:41:43.000Z
Beginner/03. Python/Tic-tac-toe.py
ankita080208/Hacktoberfest
2be849e89285260e7b6672f42979943ad6bbec78
[ "MIT" ]
null
null
null
Beginner/03. Python/Tic-tac-toe.py
ankita080208/Hacktoberfest
2be849e89285260e7b6672f42979943ad6bbec78
[ "MIT" ]
null
null
null
#According to wikipidea Tic-tac-toe or Xs and Os, is a paper-and-pencil game for two players, #X and O, who take turns marking the spaces in a 3×3 grid. #The player who succeeds in placing three of their marks in a horizontal, vertical, or diagonal row is the winner. # print("Tic-Tac-Toe!") print("Welcome...") TicTacT...
26.909836
124
0.519647
da405e79be9c7a55e83472d1e84e082d11db3205
3,810
py
Python
dataprepare.py
PMingEli/FDSR
73563b5e148647fff2712602b1fc8720b8739589
[ "MIT" ]
null
null
null
dataprepare.py
PMingEli/FDSR
73563b5e148647fff2712602b1fc8720b8739589
[ "MIT" ]
null
null
null
dataprepare.py
PMingEli/FDSR
73563b5e148647fff2712602b1fc8720b8739589
[ "MIT" ]
null
null
null
import numpy as np import argparse import glob from imageio import imread parser = argparse.ArgumentParser() parser.add_argument('--train_rgb_files', default='./data/images/train/*.jpg', help='folder name of train rgb image') parser.add_argument('--test_rgb_files', default='./data/images/test/*.jpg', help='fo...
33.130435
122
0.684514
6b7b34639844955c3aebbf797a8a0b1ad4555353
220
py
Python
169-majority-element/169-majority-element.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
2
2021-12-05T14:29:06.000Z
2022-01-01T05:46:13.000Z
169-majority-element/169-majority-element.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
null
null
null
169-majority-element/169-majority-element.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
null
null
null
class Solution: def majorityElement(self, nums: List[int]) -> int: N = len(nums) uniq_Ns = set(nums[:int(N+1/2)]) for n in uniq_Ns: if nums.count(n)>(N/2): return n
31.428571
54
0.504545
6bcb87e805d0f10aaeedc187fd2c376a7390af2d
9,271
py
Python
setsolver/image_detection/card_recognition.py
vidagy/setsolver
1d69dc33768ddb5b2110b6321106947de87cb7ac
[ "Apache-2.0" ]
null
null
null
setsolver/image_detection/card_recognition.py
vidagy/setsolver
1d69dc33768ddb5b2110b6321106947de87cb7ac
[ "Apache-2.0" ]
null
null
null
setsolver/image_detection/card_recognition.py
vidagy/setsolver
1d69dc33768ddb5b2110b6321106947de87cb7ac
[ "Apache-2.0" ]
null
null
null
import math from typing import Any, List, Optional import cv2 import numpy as np from scipy.spatial import distance from setsolver.card import Card from setsolver.properties import Color, Count, Fill, Shape class CardRecognition: def __init__(self, img=None): self._img = img self._processed_imag...
37.686992
78
0.537914
2e61c895be180f69b2b42fbf6a8db98850e46942
16,310
py
Python
tests/test_ag.py
KingKevin23/agspiel-python-api
33e74ff6bee2f9ce353da757bdb99e929acc1a13
[ "MIT" ]
1
2021-03-09T21:37:41.000Z
2021-03-09T21:37:41.000Z
tests/test_ag.py
KingKevin23/agspiel-python-api
33e74ff6bee2f9ce353da757bdb99e929acc1a13
[ "MIT" ]
4
2020-11-13T19:34:58.000Z
2021-07-24T16:25:27.000Z
tests/test_ag.py
KingKevin23/agspiel-python-api
33e74ff6bee2f9ce353da757bdb99e929acc1a13
[ "MIT" ]
1
2020-08-24T14:38:18.000Z
2020-08-24T14:38:18.000Z
# Copyright (c) 2020 | KingKevin23 (@kingkevin023) import json from unittest import TestCase from datetime import datetime, date from agspiel.api.ag import Ag from agspiel.api.data import Data from agspiel.api.ceo import Ceo from agspiel.api.aktie import Aktie, Aktionaer from agspiel.api.kapitalmassnahme import Kapit...
41.291139
135
0.679644
d8be76b019c537e8f949871a810f8eb8deeb1d05
1,381
py
Python
simple-sklearn-demo/test1/standardizationTest.py
crackedcd/Intern.MT
36398837af377a7e1c4edd7cbb15eabecd2c3103
[ "MIT" ]
1
2019-07-05T03:42:17.000Z
2019-07-05T03:42:17.000Z
simple-sklearn-demo/test1/standardizationTest.py
crackedcd/Intern.MT
36398837af377a7e1c4edd7cbb15eabecd2c3103
[ "MIT" ]
null
null
null
simple-sklearn-demo/test1/standardizationTest.py
crackedcd/Intern.MT
36398837af377a7e1c4edd7cbb15eabecd2c3103
[ "MIT" ]
1
2019-06-24T05:56:55.000Z
2019-06-24T05:56:55.000Z
from sklearn.preprocessing import StandardScaler from pandas.core.frame import DataFrame def main(): """ 适合存在可能影响最大最小值的异常点的大量数据 归一化处理异常值偏差较大的情况时容易出问题, 需要使用标准化 标准化将原始数据处理到均值为0, 标准差为1的范围 x_final = (x - avg) / sigma 也即是, (x - 该列平均值) / 标准差 标准差的计算为: 1. 计算平均值 avg 2. 计算方差, 即该列所有值 (x1 - av...
28.183673
127
0.478639
2b2b7fa206d61b7ffaed305b5d8defec783bc47f
1,747
py
Python
python/odml/nix_odml.py
mpsonntag/snippets
fc3cc42ea49b885c1f29c0aef1379055a931a978
[ "BSD-3-Clause" ]
null
null
null
python/odml/nix_odml.py
mpsonntag/snippets
fc3cc42ea49b885c1f29c0aef1379055a931a978
[ "BSD-3-Clause" ]
null
null
null
python/odml/nix_odml.py
mpsonntag/snippets
fc3cc42ea49b885c1f29c0aef1379055a931a978
[ "BSD-3-Clause" ]
null
null
null
import nixio if __name__ == '__main__': filename = "/home/msonntag/Chaos/DL/nix/bla.h5" print("Writing file '%s'" % filename) nf = nixio.File(filename, nixio.FileMode.Overwrite) sec = nf.create_section(name="sec", type_="type") secref = "sec ref" sec.reference = secref pname = "prop" ...
31.763636
81
0.680023
5aff7555e5dd5025401c189cdbbcff74d0e21760
712
py
Python
modules/dqn.py
yerfor/Soft-DRGN
0c96d1ea295077b949229261c37d8dde25001a03
[ "MIT" ]
2
2022-02-24T08:21:49.000Z
2022-03-10T08:57:35.000Z
modules/dqn.py
yerfor/Soft-DRGN
0c96d1ea295077b949229261c37d8dde25001a03
[ "MIT" ]
1
2022-02-24T08:40:21.000Z
2022-02-24T12:01:58.000Z
modules/dqn.py
yerfor/Soft-DRGN
0c96d1ea295077b949229261c37d8dde25001a03
[ "MIT" ]
null
null
null
import torch import torch.nn as nn import torch.nn.functional as F class DQNNetwork(nn.Module): def __init__(self, in_dim, hidden_dim, action_dim): super(DQNNetwork, self).__init__() self.in_dim = in_dim self.hidden_dim = hidden_dim self.action_dim = action_dim self.encoder...
30.956522
56
0.643258
7494714e52c728e0431238e9dacf306d54a7b8f1
598
py
Python
Packs/Kafka/Integrations/Kafka_V2/Kafka_V2_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/Kafka/Integrations/Kafka_V2/Kafka_V2_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/Kafka/Integrations/Kafka_V2/Kafka_V2_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
from Kafka_V2 import create_certificate import os def test_create_certificate(): ca_cert = 'dummy_cert' client_cert = 'dummy_client' key = 'dummy_key' password = 'dummy_pass' res = create_certificate(ca_cert, client_cert, key, password) assert res.password == password with open(res.certfil...
28.47619
65
0.655518
77f09b46bec776bb34584d485cb6432b0be4e7ff
68
py
Python
biowardrobe_airflow_advanced/__init__.py
Barski-lab/biowardrobe-airflow-advanced
e43aa268fd05635e8356788b8e814279b698263f
[ "Apache-2.0" ]
null
null
null
biowardrobe_airflow_advanced/__init__.py
Barski-lab/biowardrobe-airflow-advanced
e43aa268fd05635e8356788b8e814279b698263f
[ "Apache-2.0" ]
1
2018-09-30T16:57:06.000Z
2018-09-30T16:57:06.000Z
biowardrobe_airflow_advanced/__init__.py
Barski-lab/biowardrobe-airflow-advanced
e43aa268fd05635e8356788b8e814279b698263f
[ "Apache-2.0" ]
null
null
null
from .create_advanced import create_advanced as biowardrobe_advanced
68
68
0.911765
565463994ea8fa8bb924599861db9cfbda109e8f
2,145
py
Python
beispielanwendungen/webkit2/main.py
pbouda/pyqt-und-pyside-buch
a4ec10663ccc8aeda075c9a06b9707ded52382c8
[ "CC-BY-4.0" ]
5
2017-03-11T13:27:27.000Z
2022-01-09T10:52:05.000Z
beispielanwendungen/webkit2/main.py
pbouda/pyqt-und-pyside-buch
a4ec10663ccc8aeda075c9a06b9707ded52382c8
[ "CC-BY-4.0" ]
2
2021-02-14T10:59:59.000Z
2021-10-30T21:46:32.000Z
beispielanwendungen/webkit2/main.py
pbouda/pyqt-und-pyside-buch
a4ec10663ccc8aeda075c9a06b9707ded52382c8
[ "CC-BY-4.0" ]
1
2019-08-07T03:08:18.000Z
2019-08-07T03:08:18.000Z
#!/usr/bin/env python import sys, os import pickle, base64 from PyQt4 import QtCore, QtGui, QtWebKit, QtNetwork def main(argv): app = QtGui.QApplication(argv) MainWindow = BrowserWindow() MainWindow.show() sys.exit(app.exec_()) class BrowserWindow(QtWebKit.QWebView): """Das Hauptfens...
34.596774
72
0.600466
3b13a89943df6c51784fd76f843071bf6a2a0926
2,966
py
Python
app/t1health_app/static/fusioncharts-suite-xt/integrations/django/samples/fusioncharts/samples/rendering_chart_with_different_language.py
siyaochen/Tier1Health
536591a7534bbb3fb27fe889bfed9de152ec1864
[ "MIT" ]
14
2016-11-03T19:06:21.000Z
2021-11-24T09:05:09.000Z
app/t1health_app/static/fusioncharts-suite-xt/integrations/django/samples/fusioncharts/samples/rendering_chart_with_different_language.py
siyaochen/Tier1Health
536591a7534bbb3fb27fe889bfed9de152ec1864
[ "MIT" ]
10
2022-02-16T07:17:49.000Z
2022-03-08T12:43:51.000Z
asset/integrations/django/samples/fusioncharts/samples/rendering_chart_with_different_language.py
Piusshungu/catherine-junior-school
5356f4ff5a5c8383849d32e22a60d638c35b1a48
[ "MIT" ]
17
2016-05-19T13:16:34.000Z
2021-04-30T14:38:42.000Z
from django.shortcuts import render from django.http import HttpResponse # Include the `fusioncharts.py` file which has required functions to embed the charts in html page from ..fusioncharts import FusionCharts # Loading Data from a Static JSON String # It is a example to show a different language other than english...
37.544304
130
0.373567
8dbc6dc0afecee3205fce227af695b309635afbe
1,677
py
Python
src/process_canny.py
Haus4/studienarbeit-stau
10921f8850df67c797cf174b42fbc5dcec257251
[ "MIT" ]
2
2018-10-16T08:09:13.000Z
2019-02-18T13:33:11.000Z
src/process_canny.py
Haus4/studienarbeit-stau
10921f8850df67c797cf174b42fbc5dcec257251
[ "MIT" ]
7
2019-02-28T18:10:44.000Z
2019-03-04T21:09:03.000Z
src/process_canny.py
Haus4/studienarbeit-stau
10921f8850df67c797cf174b42fbc5dcec257251
[ "MIT" ]
1
2020-04-05T08:53:13.000Z
2020-04-05T08:53:13.000Z
import os import cv2 import numpy import image_utils def parseImageWithMask(img, mask, show, name): target = img.copy() med = cv2.GaussianBlur(target, (5, 5), 1.2) image_utils.applyMask(med, mask) med = cv2.cvtColor(med, cv2.COLOR_BGR2GRAY) edges = cv2.Canny(med,100,200) #cv2.imshow("hi1", e...
27.491803
73
0.650566
a511af8d20f16611fa1384b1b7951eed9e099a4e
346
py
Python
storage/emulated/0/qpython/scripts3/speak.py
wangkaibiao/SettlersFinancialData3
498249e14f24bfa3186f07e8f66ee624d08c6ff1
[ "MIT" ]
null
null
null
storage/emulated/0/qpython/scripts3/speak.py
wangkaibiao/SettlersFinancialData3
498249e14f24bfa3186f07e8f66ee624d08c6ff1
[ "MIT" ]
null
null
null
storage/emulated/0/qpython/scripts3/speak.py
wangkaibiao/SettlersFinancialData3
498249e14f24bfa3186f07e8f66ee624d08c6ff1
[ "MIT" ]
null
null
null
"""Speak user generated text.""" __author__ = 'Damon Kohler <damonkohler@gmail.com>' __copyright__ = 'Copyright (c) 2009, Google Inc.' __license__ = 'Apache License, Version 2.0' import androidhelper droid = androidhelper.Android() message = droid.dialogGetInput('TTS', 'What would you like to say?').result ...
28.833333
76
0.725434
693d6a2934c578ed68554da968a3a1eaa20a29ea
1,048
py
Python
python/pyqt/LearnPyQt/grid_layout.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
python/pyqt/LearnPyQt/grid_layout.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
python/pyqt/LearnPyQt/grid_layout.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
import sys from PyQt5.QtWidgets import ( QApplication, QMainWindow, QWidget, QGridLayout, ) from PyQt5.QtGui import ( QPalette, QColor, ) class Color(QWidget): def __init__(self, color, *args, **kwargs): super(Color, self).__init__(*args, **kwargs) self.setAutoFillBackgrou...
21.833333
57
0.630725
cef155558596fc085024901579b95826a1787e10
2,680
py
Python
Prototype/main prototype/test/TestScript_023.py
fowado/BauphysikSE1
eb8805196c8fbf99a879c40c5e0725d740c5a0de
[ "CC-BY-4.0" ]
4
2019-12-03T16:13:09.000Z
2019-12-11T23:22:58.000Z
Prototype/main prototype/test/TestScript_023.py
fowado/BauphysikSE1
eb8805196c8fbf99a879c40c5e0725d740c5a0de
[ "CC-BY-4.0" ]
65
2019-12-08T17:43:59.000Z
2020-08-14T15:26:21.000Z
Prototype/main prototype/test/TestScript_023.py
fowado/BauphysikSE1
eb8805196c8fbf99a879c40c5e0725d740c5a0de
[ "CC-BY-4.0" ]
null
null
null
import unittest import Calculation from TabData import TabData from LayerData import LayerData class TestScript_023(unittest.TestCase): """ U-Berechnung 5 Schichten analog manuellem TestScript_011 """ def setUp(self): # erstelle erste Schicht self.layer_1 = LayerData() sel...
26.019417
59
0.580224
001b440b5091a0036820effd3aac951a8e91fc91
662
py
Python
webapp/dash_tutorial_plotly/layout/markdown.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
webapp/dash_tutorial_plotly/layout/markdown.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
webapp/dash_tutorial_plotly/layout/markdown.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
import dash import dash_core_components as dcc import dash_html_components as html external_stylesheets = ['https://codepen.io/chriddyp/pen/bWLwgP.css'] app = dash.Dash(__name__, external_scripts=external_stylesheets) markdown_text = """ ### Dash amd Markdown Dash apps can be written in Markdown. Dash u...
25.461538
76
0.73565
ae40e12d12b967f0638c2dcd5face270f1a6c58d
46
py
Python
account/test.py
m-atisa/Standard-Answer-App
28ad940925f794b1ca0cfd66f850f780aa43b4f8
[ "Apache-2.0" ]
null
null
null
account/test.py
m-atisa/Standard-Answer-App
28ad940925f794b1ca0cfd66f850f780aa43b4f8
[ "Apache-2.0" ]
null
null
null
account/test.py
m-atisa/Standard-Answer-App
28ad940925f794b1ca0cfd66f850f780aa43b4f8
[ "Apache-2.0" ]
null
null
null
name = "mathewabuya" print(name.split(".")[0])
23
25
0.652174
ae6a7504e07e91bc357e9549aa5594fcee52cf20
2,266
py
Python
addition_module/face_mask_adding/FMA-3D/utils/read_info.py
weihaoxie/FaceX-Zoo
db0b087e4f4d28152e172d6c8d3767a8870733b4
[ "Apache-2.0" ]
1,329
2021-01-13T07:06:30.000Z
2022-03-31T07:23:39.000Z
addition_module/face_mask_adding/FMA-3D/utils/read_info.py
weihaoxie/FaceX-Zoo
db0b087e4f4d28152e172d6c8d3767a8870733b4
[ "Apache-2.0" ]
115
2021-01-13T10:42:57.000Z
2022-03-28T03:57:52.000Z
addition_module/face_mask_adding/FMA-3D/utils/read_info.py
weihaoxie/FaceX-Zoo
db0b087e4f4d28152e172d6c8d3767a8870733b4
[ "Apache-2.0" ]
351
2021-01-13T07:21:00.000Z
2022-03-29T14:11:39.000Z
""" @author: Yinglu Liu, Jun Wang @date: 20201012 @contact: jun21wangustc@gmail.com """ import numpy as np def read_landmark_106_file(filepath): map = [[1,2],[3,4],[5,6],7,9,11,[12,13],14,16,18,[19,20],21,23,25,[26,27],[28,29],[30,31],33,34,35,36,37,42,43,44,45,46,51,52,53,54,58,59,60,61,62,66,67,69,70,71,7...
41.2
251
0.585613
ee5e3bb2cfb56899acc9082c8a0367f971dd4e91
364
py
Python
src/server/Automat.py
muenstermannmarius/ElectionSystem
a6e60d9147423787e869587b808def4771f89cb7
[ "RSA-MD" ]
null
null
null
src/server/Automat.py
muenstermannmarius/ElectionSystem
a6e60d9147423787e869587b808def4771f89cb7
[ "RSA-MD" ]
null
null
null
src/server/Automat.py
muenstermannmarius/ElectionSystem
a6e60d9147423787e869587b808def4771f89cb7
[ "RSA-MD" ]
null
null
null
class Automat(): """The implementation of a exemplary automat class. """ def __init__(self): self._current_state_id = 0 def get_state(self): """Reads out the state.""" return self._current_state_id def set_state(self, state_id): """Sets the state.""" ...
22.75
56
0.587912
11ab51e6c64384e5034f88eca2a2508dc52802c2
2,067
py
Python
packages/watchmen-data-kernel/src/watchmen_data_kernel/storage/shaper.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-data-kernel/src/watchmen_data_kernel/storage/shaper.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-data-kernel/src/watchmen_data_kernel/storage/shaper.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
from abc import abstractmethod from typing import Any, Dict from watchmen_data_kernel.topic_schema import TopicSchema from watchmen_model.pipeline_kernel import TopicDataColumnNames from watchmen_storage import EntityRow, EntityShaper from .factor_column_mapper import TopicFactorColumnMapper class TopicShaper(Entity...
39.75
94
0.803096
0118d85d97a44caf473d0d10461e872b0944ca5d
2,002
py
Python
Packs/MalwareInvestigationAndResponse/Scripts/InvestigationSummaryToTable/InvestigationSummaryToTable.py
jrauen/content
81a92be1cbb053a5f26a6f325eff3afc0ca840e0
[ "MIT" ]
1
2021-11-02T05:36:38.000Z
2021-11-02T05:36:38.000Z
Packs/MalwareInvestigationAndResponse/Scripts/InvestigationSummaryToTable/InvestigationSummaryToTable.py
jrauen/content
81a92be1cbb053a5f26a6f325eff3afc0ca840e0
[ "MIT" ]
61
2021-10-07T08:54:38.000Z
2022-03-31T10:25:35.000Z
Packs/MalwareInvestigationAndResponse/Scripts/InvestigationSummaryToTable/InvestigationSummaryToTable.py
jrauen/content
81a92be1cbb053a5f26a6f325eff3afc0ca840e0
[ "MIT" ]
null
null
null
from enum import Enum from CommonServerPython import * RESULT = 'Result' TACTIC = 'Tactic' class Result(Enum): SUSPICIOUS = 'Suspicious' NOT_DETECTED = 'Not Detected' RESULT_TO_COLOR = { Result.SUSPICIOUS: "🔴", Result.NOT_DETECTED: "🟢", } class Finding: tactic: str result: Result ...
29.014493
119
0.662837
6dc2003dbcd34d46cc121871a927b9e4cd9104f8
327
py
Python
2_Iterables/Strings/f-strings.py
felixdittrich92/Python3
16b767465e4bdf0adc652c195d15384bb9faa4cf
[ "MIT" ]
1
2022-03-02T07:16:30.000Z
2022-03-02T07:16:30.000Z
2_Iterables/Strings/f-strings.py
felixdittrich92/Python3
16b767465e4bdf0adc652c195d15384bb9faa4cf
[ "MIT" ]
null
null
null
2_Iterables/Strings/f-strings.py
felixdittrich92/Python3
16b767465e4bdf0adc652c195d15384bb9faa4cf
[ "MIT" ]
null
null
null
# Code im String ausführen - function String user_table = {1: 'Hans Meier', 2: "Max Mustermann"} def get_user_name(user_id): if user_id in user_table: return user_table[user_id] user_id = 2 string = f"Hello my name is {get_user_name(user_id)}" print(string) list1 = [1, 2, 3] print(f"text...{list1[1]}......
21.8
53
0.681957
09b4422cd126c943b564f95775aff0b850731054
196
py
Python
Language Proficiency/Python/Itertools/itertools.product()/cartesian_product.py
xuedong/hacker-rank
ce8a60f80c2c6935b427f9409d7e826ee0d26a89
[ "MIT" ]
1
2021-02-22T17:37:45.000Z
2021-02-22T17:37:45.000Z
Language Proficiency/Python/Itertools/itertools.product()/cartesian_product.py
xuedong/hacker-rank
ce8a60f80c2c6935b427f9409d7e826ee0d26a89
[ "MIT" ]
null
null
null
Language Proficiency/Python/Itertools/itertools.product()/cartesian_product.py
xuedong/hacker-rank
ce8a60f80c2c6935b427f9409d7e826ee0d26a89
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 from itertools import product if __name__ == "__main__": A = list(map(int, input().split())) B = list(map(int, input().split())) print(*list(product(A, B)))
17.818182
39
0.612245
fede66dc9149b0b72edfa0290b0680b7a596903e
90
py
Python
Python/Random/File-Handling/00-file-read.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
Python/Random/File-Handling/00-file-read.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
Python/Random/File-Handling/00-file-read.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
file = open("text.txt", 'r') print(type(file)) print(file.name, file.mode) file.close()
12.857143
28
0.655556
3af781dfa7669ad1df60a3cb9b6bca39bcf436f6
756
py
Python
leetcode/146-LRU-Cache/LRUCache_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2015-12-16T04:01:03.000Z
2015-12-16T04:01:03.000Z
leetcode/146-LRU-Cache/LRUCache_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-02-09T06:00:07.000Z
2016-02-09T07:20:13.000Z
leetcode/146-LRU-Cache/LRUCache_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
2
2019-06-27T09:07:26.000Z
2019-07-01T04:40:13.000Z
class LRUCache: # @param capacity, an integer def __init__(self, capacity): self.tb = {} self.capacity = capacity self.freq = {} self.tm = 0 # @return an integer def get(self, key): if key in self.tb: self.freq[key] = self.tm self.tm += 1...
24.387097
64
0.521164
a34d6ede8cd8c20c6de6bc54bb205c24642d59d1
788
py
Python
docs/Timetable/xml1.py
gradgrind/WZ
672d93a3c9d7806194d16d6d5b9175e4046bd068
[ "Apache-2.0" ]
null
null
null
docs/Timetable/xml1.py
gradgrind/WZ
672d93a3c9d7806194d16d6d5b9175e4046bd068
[ "Apache-2.0" ]
null
null
null
docs/Timetable/xml1.py
gradgrind/WZ
672d93a3c9d7806194d16d6d5b9175e4046bd068
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- from collections import OrderedDict def ordereddict_to_dict(value): for k, v in value.items(): if isinstance(v, OrderedDict): value[k] = ordereddict_to_dict(v) elif isinstance(v, list): i = 0 for el in v: if isinstance(el,...
23.176471
56
0.612944
6ed34a2ae8660b885d34af176c1b006ddbfe116b
1,256
py
Python
test.py
OPI-py/test_movie_data
2a741ef2dbd85fd60a464cbe60cd3052c1c768d6
[ "MIT" ]
null
null
null
test.py
OPI-py/test_movie_data
2a741ef2dbd85fd60a464cbe60cd3052c1c768d6
[ "MIT" ]
null
null
null
test.py
OPI-py/test_movie_data
2a741ef2dbd85fd60a464cbe60cd3052c1c768d6
[ "MIT" ]
null
null
null
from bs4 import BeautifulSoup import codecs from omdbapi.movie_search import GetMovie import csv f=codecs.open("imdb_most_popular_movies_dump.html", 'r', 'utf-8') document = BeautifulSoup(f.read(), 'html.parser') movies = document.select('td.titleColumn a') movie_list = [] for index in range(0, len(movies)): mo...
32.205128
86
0.711783
285a9f9a445861eacedfd809571f796e60246729
317
py
Python
fastapi/tutorial-1-3-router/main.py
pisitj/practice-python-web-framework
5f7f60737b1cf9618e73ad8047b6c4f556d1feb0
[ "MIT" ]
null
null
null
fastapi/tutorial-1-3-router/main.py
pisitj/practice-python-web-framework
5f7f60737b1cf9618e73ad8047b6c4f556d1feb0
[ "MIT" ]
null
null
null
fastapi/tutorial-1-3-router/main.py
pisitj/practice-python-web-framework
5f7f60737b1cf9618e73ad8047b6c4f556d1feb0
[ "MIT" ]
null
null
null
# https://fastapi.tiangolo.com/tutorial/bigger-applications/#include-the-apirouters-for-users-and-items from fastapi import FastAPI from routers import items, users app = FastAPI() app.include_router(users.router) app.include_router(items.router) @app.get("/") def hello(): return {"message": "Hello World."}
22.642857
103
0.753943
957c11206d28ed68699e42a211dcf13af78551a1
2,735
py
Python
sCRAPing/finn.no/jobb.py
wittrup/crap
a77474588fd54a5a998e24df7b1e6e2ab473ded1
[ "MIT" ]
1
2017-12-12T13:58:08.000Z
2017-12-12T13:58:08.000Z
sCRAPing/finn.no/jobb.py
wittrup/crap
a77474588fd54a5a998e24df7b1e6e2ab473ded1
[ "MIT" ]
null
null
null
sCRAPing/finn.no/jobb.py
wittrup/crap
a77474588fd54a5a998e24df7b1e6e2ab473ded1
[ "MIT" ]
1
2019-11-03T10:16:35.000Z
2019-11-03T10:16:35.000Z
from urllib.parse import urlparse import os.path import requests from time import sleep from random import randrange import glob import parsers import time import csv import cleaner AD_URL = 'http://m.finn.no/job/fulltime/ad.html?finnkode=' update = ['sqamlr1dlesu0qiarus6pvzjgh'] listdict = {} for line in open('list...
26.298077
94
0.56234
25350bda223b8a963799acdff623097dc2c93f81
3,085
py
Python
semantic.py
Peetee06/compilerbau_ws2122_hsbochum
9b71e33f7385ba946ce7f4d375b7ca68b21dd97f
[ "MIT" ]
null
null
null
semantic.py
Peetee06/compilerbau_ws2122_hsbochum
9b71e33f7385ba946ce7f4d375b7ca68b21dd97f
[ "MIT" ]
null
null
null
semantic.py
Peetee06/compilerbau_ws2122_hsbochum
9b71e33f7385ba946ce7f4d375b7ca68b21dd97f
[ "MIT" ]
2
2022-03-13T18:48:24.000Z
2022-03-20T16:45:19.000Z
# TODO class Semantic(object): UNDEFINED = 0x10000001 def f(t, v): """ Parameters ---------- t : SyntaxTree a Subtree of the Syntaxtree v : Any """ return UNDEFINED class Expression(Semantic): def f(tree, n): term = tree.ge...
26.826087
105
0.493355
c6ce17315606fa7f0c701059ee1270bb5bae6798
346
py
Python
checks/url_canonicalization.py
thegreenwebfoundation/green-spider
68f22886178bbe5b476a4591a6812ee25cb5651b
[ "Apache-2.0" ]
19
2018-04-20T11:03:41.000Z
2022-01-12T20:58:56.000Z
checks/url_canonicalization.py
thegreenwebfoundation/green-spider
68f22886178bbe5b476a4591a6812ee25cb5651b
[ "Apache-2.0" ]
160
2018-04-05T16:12:59.000Z
2022-03-01T13:01:27.000Z
checks/url_canonicalization.py
thegreenwebfoundation/green-spider
68f22886178bbe5b476a4591a6812ee25cb5651b
[ "Apache-2.0" ]
8
2018-11-05T13:07:57.000Z
2021-06-11T11:46:43.000Z
""" This check verifies whether there is a single URL or several variants left at this point. """ from checks.abstract_checker import AbstractChecker class Checker(AbstractChecker): def __init__(self, config, previous_results=None): super().__init__(config, previous_results) def run(self): ...
24.714286
54
0.731214
05a2c49461ceb32491a8fd7bd1e9109d762ecaa5
629
py
Python
frappe-bench/apps/erpnext/erpnext/patches/v7_0/remove_old_earning_deduction_doctypes.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
1
2021-04-29T14:55:29.000Z
2021-04-29T14:55:29.000Z
frappe-bench/apps/erpnext/erpnext/patches/v7_0/remove_old_earning_deduction_doctypes.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/patches/v7_0/remove_old_earning_deduction_doctypes.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
1
2021-04-29T14:39:01.000Z
2021-04-29T14:39:01.000Z
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors # License: GNU General Public License v3. See license.txt from __future__ import unicode_literals import frappe def execute(): if frappe.db.exists("DocType", "Salary Component"): for dt in ("Salary Structure Earning", "Salary Structure Deducti...
39.3125
94
0.707472
af0c26303e4751d7921d4029995eafe3fb472cd8
856
py
Python
Python/zzz_training_challenge/Python_Challenge/solutions/ch09_search_and_sort/solutions/ex04_insertion_sort.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
Python/zzz_training_challenge/Python_Challenge/solutions/ch09_search_and_sort/solutions/ex04_insertion_sort.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
Python/zzz_training_challenge/Python_Challenge/solutions/ch09_search_and_sort/solutions/ex04_insertion_sort.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
# Beispielprogramm für das Buch "Python Challenge" # # Copyright 2020 by Michael Inden def swap_positions_normal(list, pos1, pos2): tmp = list[pos1] list[pos2] = list[pos1] list[pos1] = tmp def insertion_sort(values): for i in range(1, len(values)): # Prüfe, ob aktuelles Element grösser als ...
22.526316
80
0.636682
a529be883a0c55bb0b58973fba27e36cc75f4192
4,075
py
Python
keras_fcn/decoders.py
li657835991/FCN
26bafeaf631a095d9d2befcc3b798a87c8d0fa7c
[ "MIT" ]
235
2017-03-01T14:34:29.000Z
2021-06-03T16:16:16.000Z
keras_fcn/decoders.py
li657835991/FCN
26bafeaf631a095d9d2befcc3b798a87c8d0fa7c
[ "MIT" ]
39
2017-03-25T01:20:25.000Z
2020-10-30T11:51:47.000Z
keras_fcn/decoders.py
li657835991/FCN
26bafeaf631a095d9d2befcc3b798a87c8d0fa7c
[ "MIT" ]
105
2017-04-13T21:31:46.000Z
2021-11-01T17:25:48.000Z
import keras import keras.backend as K from keras.models import Model from keras.layers import ( Input ) from keras.layers.convolutional import ( Conv2D ) from keras_fcn.layers import CroppingLike2D from keras_fcn.blocks import ( vgg_deconv, vgg_score, vgg_upsampling ) def Decoder(pyramid, bloc...
37.385321
79
0.573252
3c29438dd9d8deb86389c754dac468318f3ed173
1,687
py
Python
scripts/ssanova/palate-getter.py
jenniferxkuo/ultramisc
65bff53c97715eb9a24acc62b77460f22e0dabc6
[ "MIT" ]
1
2020-10-26T01:18:23.000Z
2020-10-26T01:18:23.000Z
scripts/ssanova/palate-getter.py
jenniferxkuo/ultramisc
65bff53c97715eb9a24acc62b77460f22e0dabc6
[ "MIT" ]
null
null
null
scripts/ssanova/palate-getter.py
jenniferxkuo/ultramisc
65bff53c97715eb9a24acc62b77460f22e0dabc6
[ "MIT" ]
3
2019-05-29T18:36:54.000Z
2021-09-07T02:53:51.000Z
# palate getter function - averages all palate traces in ET output .con file # outputs a text file that can be used in ssanova_palate.R # usage: python palate-getter.py [directory name] # where directory contains multiple subjects' palate-finding dirs # target files MUST end in "palates.con" import os, sys, argp...
36.673913
95
0.679905
3c656519aa0e8e869b1bc133c96f29a164d99ab2
1,156
py
Python
Problems/Depth-First Search/easy/SumRootToLeafBinaryNumber/sum_root_leaf_binary_number.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
1
2021-08-16T14:52:05.000Z
2021-08-16T14:52:05.000Z
Problems/Depth-First Search/easy/SumRootToLeafBinaryNumber/sum_root_leaf_binary_number.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
Problems/Depth-First Search/easy/SumRootToLeafBinaryNumber/sum_root_leaf_binary_number.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
from typing import Optional # Definition for a binary tree node. class TreeNode: def __init__(self, val=0, left=None, right=None): self.val = val self.left = left self.right = right # Recursive def sumRootToLeaf(self, root: Optional[TreeNode]) -> int: self.res = 0 def sum_binary(c...
29.641026
67
0.594291
3c7f520673c84b01d156932426c1d2b43f797bdf
313
py
Python
Problems/Two Pointers/easy/MergeStringAlternately/merge_string_alternately.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
1
2021-08-16T14:52:05.000Z
2021-08-16T14:52:05.000Z
Problems/Two Pointers/easy/MergeStringAlternately/merge_string_alternately.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
Problems/Two Pointers/easy/MergeStringAlternately/merge_string_alternately.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
def mergeAlternately(word1: str, word2: str) -> str: p1, p2, l1, l2 = 0, 0, len(word1), len(word2) result = "" while p1 < l1 or p2 < l2: if p1 < l1: result += word1[p1] p1 += 1 if p2 < l2: result += word2[p2] p2 += 1 return result
22.357143
52
0.450479
a7379ab6b029a8a283c7cd64ef6b2a68f323669a
186
py
Python
demos/Multiscale/uniswap/model/state_variables.py
w-ghub/demos
6382676fae89bd5a190626612712fcedf17bca6d
[ "MIT" ]
56
2020-07-08T23:23:15.000Z
2022-03-11T20:43:09.000Z
demos/Multiscale/uniswap/model/state_variables.py
w-ghub/demos
6382676fae89bd5a190626612712fcedf17bca6d
[ "MIT" ]
41
2020-07-11T23:24:06.000Z
2022-01-28T13:28:07.000Z
demos/Multiscale/uniswap/model/state_variables.py
w-ghub/demos
6382676fae89bd5a190626612712fcedf17bca6d
[ "MIT" ]
39
2020-07-15T11:35:04.000Z
2022-02-01T16:02:51.000Z
import pandas as pd genesis_states = { 'DAI_balance': 5900000000000000000000, 'ETH_balance': 30000000000000000000, 'UNI_supply': 30000000000000000000, 'price_ratio': 0 }
23.25
42
0.731183
e608fb34d1f7ceddcadf9118f836d9447c5b9cf1
7,688
py
Python
src/pss_receive/pss-receive/receive.py
ska-telescope/sdp-prototype
8c6cbda04a83b0e16987019406ed6ec7e1058a31
[ "BSD-3-Clause" ]
2
2019-07-15T09:49:34.000Z
2019-10-14T16:04:17.000Z
src/pss_receive/pss-receive/receive.py
ska-telescope/sdp-prototype
8c6cbda04a83b0e16987019406ed6ec7e1058a31
[ "BSD-3-Clause" ]
17
2019-07-15T14:51:50.000Z
2021-06-02T00:29:43.000Z
src/pss_receive/pss-receive/receive.py
ska-telescope/sdp-configuration-prototype
8c6cbda04a83b0e16987019406ed6ec7e1058a31
[ "BSD-3-Clause" ]
1
2019-10-10T08:16:48.000Z
2019-10-10T08:16:48.000Z
#/usr/bin/python from __future__ import print_function import argparse import logging import os import spead2.recv import spead2 # pylint: disable=C0116,W1202,R0201 # A module to receive data over UDP using the spead2 data exchange protocol # # Author: Benjamin Shaw # Email : benjamin.shaw@manchester.ac.uk class U...
34.630631
104
0.587149
0591f4ac8c351482aca073c4115588a086fe4d89
1,360
py
Python
src/test/tests/databases/imgvol.py
visit-dav/vis
c08bc6e538ecd7d30ddc6399ec3022b9e062127e
[ "BSD-3-Clause" ]
226
2018-12-29T01:13:49.000Z
2022-03-30T19:16:31.000Z
src/test/tests/databases/imgvol.py
visit-dav/vis
c08bc6e538ecd7d30ddc6399ec3022b9e062127e
[ "BSD-3-Clause" ]
5,100
2019-01-14T18:19:25.000Z
2022-03-31T23:08:36.000Z
src/test/tests/databases/imgvol.py
visit-dav/vis
c08bc6e538ecd7d30ddc6399ec3022b9e062127e
[ "BSD-3-Clause" ]
84
2019-01-24T17:41:50.000Z
2022-03-10T10:01:46.000Z
# ---------------------------------------------------------------------------- # CLASSES: nightly # # Test Case: imgvol.py # # Tests: imgvol reader # # Mark C. Miller, Fri Apr 23 23:01:06 PDT 2010 # # Modifications: # # Mark C. Miller, Sun Apr 25 21:30:29 PDT 2010 # Added missing Slice operator for c...
20.298507
78
0.666912
558743c7b2ca59881b090652b6cb0a430941a99e
5,534
py
Python
tools/inference.py
UESTC-Liuxin/SkmtSeg
1251de57fae967aca395644d1c70a9ba0bb52271
[ "Apache-2.0" ]
2
2020-12-22T08:40:05.000Z
2021-03-30T08:09:44.000Z
tools/inference.py
UESTC-Liuxin/SkmtSeg
1251de57fae967aca395644d1c70a9ba0bb52271
[ "Apache-2.0" ]
null
null
null
tools/inference.py
UESTC-Liuxin/SkmtSeg
1251de57fae967aca395644d1c70a9ba0bb52271
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- """ @description: @author: LiuXin @contact: xinliu1996@163.com @Created on: 2020/11/19 上午11:28 """ import argparse import time import numpy as np import skimage import torch import torch.nn as nn import torchvision.transforms as T from tqdm import tqdm import PIL.Image as Image from modeling im...
31.804598
111
0.619443
75b988c07c76f22c976ec4770d7c472bcaed127a
820
py
Python
tests/test_config.py
PlaidWeb/Publ
67efc5e32bf25dbac72a83d1167de038b79db5a7
[ "MIT" ]
27
2018-11-30T21:32:26.000Z
2022-03-20T19:46:25.000Z
tests/test_config.py
PlaidWeb/Publ
67efc5e32bf25dbac72a83d1167de038b79db5a7
[ "MIT" ]
249
2018-09-30T07:04:37.000Z
2022-03-29T04:31:00.000Z
tests/test_config.py
fluffy-critter/Publ
868c5a17c605707dde4d1a95d79405301bd12f05
[ "MIT" ]
4
2019-03-01T06:46:13.000Z
2019-06-30T17:45:46.000Z
""" tests of the config manager """ # pylint:disable=missing-docstring from publ import config from . import PublMock def test_config_defaults(): cfg = config.Config({}) dfl = config._Defaults # pylint:disable=protected-access for key, val in cfg.__dict__.items(): if key[0] != '_': ...
28.275862
78
0.680488
ddac337f7b7662e01f1c9ffc14ce190314935d05
14,778
py
Python
dcapy/cashflow/cashflow.py
scuervo91/dcapy
46c9277e607baff437e5707167476d5f7e2cf80c
[ "MIT" ]
4
2021-05-21T13:26:10.000Z
2021-11-15T17:17:01.000Z
dcapy/cashflow/cashflow.py
scuervo91/dcapy
46c9277e607baff437e5707167476d5f7e2cf80c
[ "MIT" ]
null
null
null
dcapy/cashflow/cashflow.py
scuervo91/dcapy
46c9277e607baff437e5707167476d5f7e2cf80c
[ "MIT" ]
null
null
null
from dcapy.dca.dca import ProbVar from pydantic import BaseModel, Field, validator from typing import Union, List, Optional from datetime import date import pandas as pd import numpy as np import numpy_financial as npf import matplotlib.pyplot as plt import seaborn as sns from enum import Enum from ..dca import conver...
34.608899
185
0.59751
34adf35a4d2917b6e27ccccd3f92fd8eba38ac46
3,231
py
Python
tests/onegov/onboarding/test_views.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/onboarding/test_views.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/onboarding/test_views.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
import morepath import onegov.onboarding from onegov.core.utils import Bunch, scan_morepath_modules from tests.shared import utils from onegov.town6 import TownApp from webtest import TestApp as Client def test_view_permissions(): utils.assert_explicit_permissions( onegov.onboarding, onegov.onboarding.On...
26.925
75
0.645002
32e69d06f47bc4343eeca32fa5d79cf2e62e2a33
1,661
py
Python
CheckMate/tcp_check.py
eaydin/checkmate
6a9cad7599c8c3e2087cb83b544368fdf69f6147
[ "MIT" ]
null
null
null
CheckMate/tcp_check.py
eaydin/checkmate
6a9cad7599c8c3e2087cb83b544368fdf69f6147
[ "MIT" ]
null
null
null
CheckMate/tcp_check.py
eaydin/checkmate
6a9cad7599c8c3e2087cb83b544368fdf69f6147
[ "MIT" ]
null
null
null
import socket import threading import time from CheckMate.log import logger def tcp_checker(address, port, close=2): s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) s.settimeout(close) try: s.connect((address, port)) s.close() logger.info("tcp - Success connecting to {addr}:{...
35.340426
125
0.606863
bd06b2c0ac404ca8309bf62fbe5ad9c88bc74304
4,977
py
Python
official/nlp/dgu/src/pretrainmodel_convert.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
official/nlp/dgu/src/pretrainmodel_convert.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
official/nlp/dgu/src/pretrainmodel_convert.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
24
2021-10-15T08:32:45.000Z
2022-03-24T18:45:20.000Z
# Copyright 2021 Huawei Technologies Co., Ltd # # 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...
52.389474
120
0.703034
1f9577cb06aa4febf38cb7f8b8571b07c1311e33
320
py
Python
Pythonjunior2020/Woche3/Aufgabe_3_2_3.py
Zeyecx/HPI-Potsdam
ed45ca471cee204dde74dd2c3efae3877ee71036
[ "MIT" ]
null
null
null
Pythonjunior2020/Woche3/Aufgabe_3_2_3.py
Zeyecx/HPI-Potsdam
ed45ca471cee204dde74dd2c3efae3877ee71036
[ "MIT" ]
null
null
null
Pythonjunior2020/Woche3/Aufgabe_3_2_3.py
Zeyecx/HPI-Potsdam
ed45ca471cee204dde74dd2c3efae3877ee71036
[ "MIT" ]
null
null
null
# 3.2.3, Woche 3, Block 2, Aufgabe 3 # Import from daten import punkte_liste from turtle import * # Funktionen def gehe_wenn_nah(pointer): if distance(pointer) < 100: goto(pointer) else: goto(0,0) # Main for i in range(0,len(punkte_liste)): gehe_wenn_nah(punkte_liste[i])
20
36
0.634375
85d8fd5418076095d54379aad03a4780ab053121
7,719
py
Python
autojail/commands/init.py
ekut-es/autojail
bc16e40e6df55c0a28a3059715851ffa59b14ba8
[ "MIT" ]
6
2020-08-12T08:16:15.000Z
2022-03-05T02:25:53.000Z
autojail/commands/init.py
ekut-es/autojail
bc16e40e6df55c0a28a3059715851ffa59b14ba8
[ "MIT" ]
1
2021-03-30T10:34:51.000Z
2021-06-09T11:24:00.000Z
autojail/commands/init.py
ekut-es/autojail
bc16e40e6df55c0a28a3059715851ffa59b14ba8
[ "MIT" ]
1
2021-11-21T09:30:58.000Z
2021-11-21T09:30:58.000Z
from pathlib import Path import ruamel.yaml from ..model import AutojailArch, AutojailConfig, AutojailLogin from .base import BaseCommand class InitCommand(BaseCommand): """ Initializes an autojail project init {--f|force : if set overwrites existing autojail.yml} {--name= : name of the proje...
33.415584
123
0.537116
c09d83e89e3e87579fe5964471000d9dd77062b1
1,589
py
Python
program/main.py
SimonSkade/BwKI_autonome_Verkehrslenkung
41d84ce2103a4338893dc610a46f7b115d584635
[ "MIT" ]
4
2019-08-22T19:16:28.000Z
2019-10-27T07:09:09.000Z
program/main.py
SimonSkade/BwKI_autonome_Verkehrslenkung
41d84ce2103a4338893dc610a46f7b115d584635
[ "MIT" ]
null
null
null
program/main.py
SimonSkade/BwKI_autonome_Verkehrslenkung
41d84ce2103a4338893dc610a46f7b115d584635
[ "MIT" ]
null
null
null
#!/home/simon/anaconda3/bin/python if __name__=='__main__': #kann man das auch noch anders kontrollieren, dass ein Teil nur ausgeführt wird, wenn die Datei von einer spezifischen anderen Datei aufgerufen/importiert wird? import environment #input_file_network = "../manual_example_data/test_Einlesedatei_netzwe...
51.258065
198
0.770925
c8a5ac24037b92d7fba1869abbc6254bccb14fb3
6,652
py
Python
Utils/py/RL_ActionSelection/env_0/actions.py
tarsoly/NaoTH
dcd2b67ef6bf9953c81d3e1b26e543b5922b7d52
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
Utils/py/RL_ActionSelection/env_0/actions.py
tarsoly/NaoTH
dcd2b67ef6bf9953c81d3e1b26e543b5922b7d52
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
Utils/py/RL_ActionSelection/env_0/actions.py
tarsoly/NaoTH
dcd2b67ef6bf9953c81d3e1b26e543b5922b7d52
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
########################## # # Actions used by world (with noise) and agent (without noise) # ########################## import math import copy import numpy as np from tools import action as act from state import State from naoth.math2d import Vector2 as Vec class Actions: """ all available actions p...
33.427136
119
0.657998
9e234b2f32ea5e6a0894ab0861880070483b37b7
1,407
py
Python
REWORK/src/py/wifiSpeed.py
JueK3y/Instagram-automated-commenting
7ecc4119d8e9ff0dfba620488018fbd9fce61606
[ "RSA-MD" ]
9
2021-06-22T14:01:24.000Z
2022-03-11T08:59:38.000Z
REWORK/src/py/wifiSpeed.py
JueK3y/Instagram-automated-commenting
7ecc4119d8e9ff0dfba620488018fbd9fce61606
[ "RSA-MD" ]
6
2021-01-15T09:12:11.000Z
2021-05-25T08:12:10.000Z
REWORK/src/py/wifiSpeed.py
JueK3y/Instagram-automated-commenting
7ecc4119d8e9ff0dfba620488018fbd9fce61606
[ "RSA-MD" ]
1
2021-12-27T18:58:53.000Z
2021-12-27T18:58:53.000Z
# ┌─────────────────────────────────────────────────────────────────────────┐ # │ Instagram Automated Commenting 2.0 │ # ├─────────────────────────────────────────────────────────────────────────┤ # │ DO NOT indicate used program sections as your own. │ # │ DO N...
50.25
77
0.438522
27f9813271d250849b020912c6f70a10cec5b2e5
713
py
Python
tests/onegov/form/test_utils.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/form/test_utils.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/form/test_utils.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from decimal import Decimal from onegov.form import decimal_range def test_decimal_range(): assert list(decimal_range('0', '2')) == [ Decimal('0'), Decimal('1') ] assert list(decimal_range('2', '0')) == [ Decimal('2'), Decimal('1') ] assert list(decimal_range('0',...
25.464286
75
0.528752
7e0b0dc277dde608c1e48c35637538f28601e353
3,151
py
Python
luechenbresse/text.py
turkishmaid/luechenbresse
2527b19eb2f961cef5ddb62e816b471e5d04847d
[ "MIT" ]
null
null
null
luechenbresse/text.py
turkishmaid/luechenbresse
2527b19eb2f961cef5ddb62e816b471e5d04847d
[ "MIT" ]
4
2020-05-12T07:26:52.000Z
2020-05-23T12:21:49.000Z
luechenbresse/text.py
turkishmaid/luechenbresse
2527b19eb2f961cef5ddb62e816b471e5d04847d
[ "MIT" ]
null
null
null
#!/usr/bin/env python # coding: utf-8 """ Tooling to deal with nested lists of strings (e.g. extracted from a web page), transform them to a list of words without decorations and then work with such list. """ _DECORATORS = '''+"'-.!?;:,|/“”()''' def undecorate(mixup): # get undecorated words # does not chang...
33.88172
88
0.565852
fd735267ee2afd651ae47b23f44dfe2114b29cc2
2,830
py
Python
test/test_npu/test_network_ops/test_multinomial.py
Ascend/pytorch
39849cf72dafe8d2fb68bd1679d8fd54ad60fcfc
[ "BSD-3-Clause" ]
1
2021-12-02T03:07:35.000Z
2021-12-02T03:07:35.000Z
test/test_npu/test_network_ops/test_multinomial.py
Ascend/pytorch
39849cf72dafe8d2fb68bd1679d8fd54ad60fcfc
[ "BSD-3-Clause" ]
1
2021-11-12T07:23:03.000Z
2021-11-12T08:28:13.000Z
test/test_npu/test_network_ops/test_multinomial.py
Ascend/pytorch
39849cf72dafe8d2fb68bd1679d8fd54ad60fcfc
[ "BSD-3-Clause" ]
null
null
null
# Copyright (c) 2020, Huawei Technologies.All rights reserved. # # Licensed under the BSD 3-Clause License (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://opensource.org/licenses/BSD-3-Clause # # Unless required by applicable law...
37.733333
84
0.596113
9a09751d048f993fae4794fe80c84a7a163e45c0
4,839
py
Python
Packs/FeedRSS/Integrations/FeedRSS/test_data/test_variables.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/FeedRSS/Integrations/FeedRSS/test_data/test_variables.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/FeedRSS/Integrations/FeedRSS/test_data/test_variables.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
import feedparser TEXT_EXCEEDED_MAX_SIZE = "<p> 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93...
59.740741
1,123
0.588758
d05e586c9d6de49644d9cc61637eaa28e0fdaab1
262
py
Python
exercises/ja/solution_02_02_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
2,085
2019-04-17T13:10:40.000Z
2022-03-30T21:51:46.000Z
exercises/ja/solution_02_02_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
79
2019-04-18T14:42:55.000Z
2022-03-07T08:15:43.000Z
exercises/ja/solution_02_02_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
361
2019-04-17T13:34:32.000Z
2022-03-28T04:42:45.000Z
from spacy.lang.ja import Japanese nlp = Japanese() doc = nlp("デヴィッド・ボウイはPERSONです") # ラベル「PERSON」のハッシュを引く person_hash = nlp.vocab.strings["PERSON"] print(person_hash) # person_hashを引いて文字列を取得 person_string = nlp.vocab.strings[person_hash] print(person_string)
20.153846
46
0.78626
d0c6852ca3c696f25e3244a4f64ab6f89e5c2211
37,171
py
Python
Packs/QuestKace/Integrations/QuestKace/test_module/RawData.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/QuestKace/Integrations/QuestKace/test_module/RawData.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/QuestKace/Integrations/QuestKace/test_module/RawData.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
MACHINES_LIST_COMMAND_RESPONSE = { 'Machines': [ {'Id': '1', 'Modified': '2020-03-11 08:21:38', 'Created': '2020-03-11 08:21:38', 'User': '', 'Name': 'Macbook Pro', 'Ip': '1.2.3.4', 'Os_name': '', 'Os_number': '', 'Last_inventory': '0000-00-00 0...
27.927122
85
0.32224
d0dd120cc6bcc050fdef5b00e242c8c57ab50a3a
7,099
py
Python
Packs/knowbe4Phisher/Integrations/knowbe4Phisher/test_data/mock_tests.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/knowbe4Phisher/Integrations/knowbe4Phisher/test_data/mock_tests.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/knowbe4Phisher/Integrations/knowbe4Phisher/test_data/mock_tests.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
create_request_test = [ ("""mutation {{ phisherCommentCreate(comment: \\"{}\\", id: \\"{}\\") {{ errors {{ field placeholders reason }} node {{ body createdAt }} }} }}""", 'mutation {{\\n phisherCommentCreate(comment: \\"{}\\", id: \\"{}\\") {{\\n errors {{...
33.966507
129
0.415411
ef61575089197f2715cb0ed90b20bcdb49b02397
1,255
py
Python
Interview Preparation Kits/Interview Preparation Kit/Graphs/BFS: Shortest Reach in a Graph/bfs2.py
xuedong/hacker-rank
ce8a60f80c2c6935b427f9409d7e826ee0d26a89
[ "MIT" ]
1
2021-02-22T17:37:45.000Z
2021-02-22T17:37:45.000Z
Interview Preparation Kits/Interview Preparation Kit/Graphs/BFS: Shortest Reach in a Graph/bfs2.py
xuedong/hacker-rank
ce8a60f80c2c6935b427f9409d7e826ee0d26a89
[ "MIT" ]
null
null
null
Interview Preparation Kits/Interview Preparation Kit/Graphs/BFS: Shortest Reach in a Graph/bfs2.py
xuedong/hacker-rank
ce8a60f80c2c6935b427f9409d7e826ee0d26a89
[ "MIT" ]
null
null
null
#!/bin/python3 import queue from collections import defaultdict class Graph: def __init__(self, nodes): self.nodes = nodes self.edges = defaultdict(set) def connect(self, node_x, node_y): self.edges[node_x].add(node_y) self.edges[node_y].add(node_x) def find_all_distances(...
26.702128
56
0.560956
9d250a1130ffa1a01f934c8a1ef70e5aa614d78f
7,455
py
Python
Bikecounter/get_data_daily.py
cfleschhut/virushack
2fe7ded0be8672b066edef7fed52573794db2ba5
[ "Apache-2.0" ]
29
2020-03-21T00:47:51.000Z
2021-07-17T15:50:33.000Z
Bikecounter/get_data_daily.py
cfleschhut/virushack
2fe7ded0be8672b066edef7fed52573794db2ba5
[ "Apache-2.0" ]
7
2020-03-21T14:04:26.000Z
2022-03-02T08:05:40.000Z
Bikecounter/get_data_daily.py
cfleschhut/virushack
2fe7ded0be8672b066edef7fed52573794db2ba5
[ "Apache-2.0" ]
13
2020-03-21T01:08:08.000Z
2020-04-08T17:21:11.000Z
#!/usr/bin/env python # coding: utf-8 # In[36]: import json import pandas as pd import numpy as np import boto3 import requests import os from datetime import datetime, timedelta # In[37]: pratiques_path = "pratiques.csv" locations_path = "Counterlist-DE.csv" pratiques_df = pd.read_csv(pratiques_path,sep='\t') l...
34.354839
215
0.536419
26524fcbe1407622295c3604bc875b0a36e581c4
2,939
py
Python
More-DL/ResidualNetwork_rebuild.py
felixdittrich92/DeepLearning-tensorflow-keras
2880d8ed28ba87f28851affa92b6fa99d2e47be9
[ "Apache-2.0" ]
null
null
null
More-DL/ResidualNetwork_rebuild.py
felixdittrich92/DeepLearning-tensorflow-keras
2880d8ed28ba87f28851affa92b6fa99d2e47be9
[ "Apache-2.0" ]
null
null
null
More-DL/ResidualNetwork_rebuild.py
felixdittrich92/DeepLearning-tensorflow-keras
2880d8ed28ba87f28851affa92b6fa99d2e47be9
[ "Apache-2.0" ]
null
null
null
import numpy as np import tensorflow as tf # Fix CuDnn problem gpus = tf.config.experimental.list_physical_devices('GPU') if gpus: try: tf.config.experimental.set_memory_growth(gpus[0], True) except RuntimeError as e: print(e) from tensorflow.keras.models import Model from tensorflow.keras.layers import *...
39.186667
77
0.628445
cd21195260b771fe0372d6bd4f472caad45dafa8
437
py
Python
dunder-demos/wrapper.py
gregjhansell97/sandbox
d565da5db2c10af404ce62aa747d5e682bc02a86
[ "MIT" ]
null
null
null
dunder-demos/wrapper.py
gregjhansell97/sandbox
d565da5db2c10af404ce62aa747d5e682bc02a86
[ "MIT" ]
null
null
null
dunder-demos/wrapper.py
gregjhansell97/sandbox
d565da5db2c10af404ce62aa747d5e682bc02a86
[ "MIT" ]
null
null
null
import inspect class Wrapper: def __init__(self, obj): self.obj = obj def __getattribute__(self, item): obj = super().__getattribute__("obj") return getattr(obj, item) class A: def run(self): print("WRAPPED IT BOI") async def stop(self): print("stopped") a =...
15.607143
45
0.627002
90414527bd0cbe90a0f7c39a4960a86027e03be1
275
py
Python
leetcode/053-Maximum-Subarray/MaxSubarray_003.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2015-12-16T04:01:03.000Z
2015-12-16T04:01:03.000Z
leetcode/053-Maximum-Subarray/MaxSubarray_003.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-02-09T06:00:07.000Z
2016-02-09T07:20:13.000Z
leetcode/053-Maximum-Subarray/MaxSubarray_003.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
2
2019-06-27T09:07:26.000Z
2019-07-01T04:40:13.000Z
class Solution: # @param {integer[]} nums # @return {integer} def maxSubArray(self, nums): res, tmp = nums[0], nums[0] for i in range(1, len(nums)): tmp = max(tmp + nums[i], nums[i]) res = max(res, tmp) return res
25
45
0.505455
8443b65a3c8bc99b7d7a69907db2f80e3bb34ad7
885
py
Python
data-pipeline/src/data_pipeline/datasets/exac/exac_constraint.py
broadinstitute/gnomadjs
00da72cdc2cb0753f822c51456ec15147c024a1d
[ "MIT" ]
38
2018-02-24T02:33:52.000Z
2020-03-03T23:17:04.000Z
data-pipeline/src/data_pipeline/datasets/exac/exac_constraint.py
broadinstitute/gnomadjs
00da72cdc2cb0753f822c51456ec15147c024a1d
[ "MIT" ]
385
2018-02-21T16:53:13.000Z
2020-03-04T00:52:40.000Z
data-pipeline/src/data_pipeline/datasets/exac/exac_constraint.py
broadinstitute/gnomadjs
00da72cdc2cb0753f822c51456ec15147c024a1d
[ "MIT" ]
13
2020-05-01T13:03:54.000Z
2022-02-28T13:12:57.000Z
import hail as hl def prepare_exac_constraint(path): ds = hl.import_table(path, force=True) ds = ds.repartition(32, shuffle=True) # Select relevant fields ds = ds.select( # Remove version number from transcript ID transcript_id=ds.transcript.split("\\.")[0], # Expected ...
25.285714
52
0.577401
fff95f879c11edb97da7acdc307bd88ad6f9fcdb
11,131
py
Python
PowerPWN/PowerPwn.py
Unam3dd/Train-2018-2020
afb6ae70fe338cbe55a21b74648d91996b818fa2
[ "MIT" ]
4
2021-04-23T15:39:17.000Z
2021-12-27T22:53:24.000Z
PowerPWN/PowerPwn.py
Unam3dd/Train-2018-2020
afb6ae70fe338cbe55a21b74648d91996b818fa2
[ "MIT" ]
null
null
null
PowerPWN/PowerPwn.py
Unam3dd/Train-2018-2020
afb6ae70fe338cbe55a21b74648d91996b818fa2
[ "MIT" ]
2
2021-04-19T08:28:54.000Z
2022-01-19T13:23:29.000Z
#!/usr/bin/python2 #-*- coding:utf-8 -*- import socket import subprocess import platform import sys import time import os import readline import logging import shlex import threading from base64 import b64encode try: import nclib except ImportError: print('\033[1;91m[!] Error NCLIB Not Found !') try: imp...
37.989761
501
0.534094
4b42f549d9eac97780122b03e5a3658b6231bca3
519
py
Python
leetcode/538-Convert-BST-to-Greater-Tree/ConvertBSTtoGreaterTree_recursion.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-04-07T15:08:53.000Z
2016-04-07T15:08:53.000Z
leetcode/538-Convert-BST-to-Greater-Tree/ConvertBSTtoGreaterTree_recursion.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-02-09T06:00:07.000Z
2016-02-09T07:20:13.000Z
leetcode/538-Convert-BST-to-Greater-Tree/ConvertBSTtoGreaterTree_recursion.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
2
2019-06-27T09:07:26.000Z
2019-07-01T04:40:13.000Z
# Definition for a binary tree node. # class TreeNode: # def __init__(self, x): # self.val = x # self.left = None # self.right = None class Solution: def convertBST(self, root: TreeNode) -> TreeNode: def traverse(node, prev_sum): if node: prev_sum = t...
27.315789
57
0.549133
8a64d2d8cc10583fd6d6663c34989b2cbf4a1157
13,170
py
Python
myems-aggregation/equipment_billing_output_category.py
guangyuzhang/myems
c88f0620d3e36154a500c755c805333b771d09c0
[ "MIT" ]
82
2021-02-19T10:24:31.000Z
2022-03-28T06:30:18.000Z
myems-aggregation/equipment_billing_output_category.py
guangyuzhang/myems
c88f0620d3e36154a500c755c805333b771d09c0
[ "MIT" ]
188
2021-02-22T07:08:30.000Z
2022-03-02T04:11:03.000Z
myems-aggregation/equipment_billing_output_category.py
guangyuzhang/myems
c88f0620d3e36154a500c755c805333b771d09c0
[ "MIT" ]
54
2021-02-19T08:48:46.000Z
2022-03-30T06:21:34.000Z
import time from datetime import datetime, timedelta from decimal import Decimal import mysql.connector import tariff import config ######################################################################################################################## # PROCEDURES # Step 1: get all equipments # for each equipment in...
48.777778
120
0.48284
76e9fdcb7506908a21cd17422dc86c8f26f075ee
239
py
Python
SoSe-21/Code-Vorlesungen/VL-8/dictio-beispiel.py
jonasrdt/Wirtschaftsinformatik2
30d5d896808b98664c55cb6fbb3b30a7f1904d9f
[ "MIT" ]
1
2022-03-23T09:40:39.000Z
2022-03-23T09:40:39.000Z
SoSe-21/Code-Vorlesungen/VL-8/dictio-beispiel.py
jonasrdt/Wirtschaftsinformatik2
30d5d896808b98664c55cb6fbb3b30a7f1904d9f
[ "MIT" ]
null
null
null
SoSe-21/Code-Vorlesungen/VL-8/dictio-beispiel.py
jonasrdt/Wirtschaftsinformatik2
30d5d896808b98664c55cb6fbb3b30a7f1904d9f
[ "MIT" ]
null
null
null
beispiel_dict = {"Jonas": 28, "Ilona": 26, "Rahmat": 23} # Sie stellen fest, dass Ilona doch erst 25 ist. Wie führen Sie eine Änderung durch? beispiel_dict.update({"Ilona": 25}) print(beispiel_dict)
19.916667
84
0.60251
76ec42c762eca03a2072d69dbd024d82f4641d41
4,482
py
Python
order/views.py
hhdMrLion/Product-System
e870225ab10c32688a87426d5943d922c47c4404
[ "MIT" ]
1
2021-06-18T03:03:42.000Z
2021-06-18T03:03:42.000Z
order/views.py
hhdMrLion/Product-System
e870225ab10c32688a87426d5943d922c47c4404
[ "MIT" ]
null
null
null
order/views.py
hhdMrLion/Product-System
e870225ab10c32688a87426d5943d922c47c4404
[ "MIT" ]
null
null
null
import datetime from django.core.paginator import Paginator, PageNotAnInteger, EmptyPage from django.db.models import Q from django.shortcuts import render, get_object_or_404, redirect # Create your views here. from django.views.generic import ListView from order.models import Order, OrderList, OrderBill f...
32.955882
105
0.675368
0a566ac58906caf25a3d56a636a033ffc899ae5a
2,102
py
Python
Interview Preparation Kits/Interview Preparation Kit/Graphs/BFS: Shortest Reach in a Graph/bfs1.py
xuedong/hacker-rank
ce8a60f80c2c6935b427f9409d7e826ee0d26a89
[ "MIT" ]
1
2021-02-22T17:37:45.000Z
2021-02-22T17:37:45.000Z
Interview Preparation Kits/Interview Preparation Kit/Graphs/BFS: Shortest Reach in a Graph/bfs1.py
xuedong/hacker-rank
ce8a60f80c2c6935b427f9409d7e826ee0d26a89
[ "MIT" ]
null
null
null
Interview Preparation Kits/Interview Preparation Kit/Graphs/BFS: Shortest Reach in a Graph/bfs1.py
xuedong/hacker-rank
ce8a60f80c2c6935b427f9409d7e826ee0d26a89
[ "MIT" ]
null
null
null
#!/bin/python3 import math import os import random import re import sys # Complete the findShortest function below. from collections import defaultdict # # For the weighted graph, <name>: # # 1. The number of nodes is <name>_nodes. # 2. The number of edges is <name>_edges. # 3. An edge exists between <name>_from[i] t...
28.026667
80
0.577069
0a9bc7efd625df7eadac7d10c87584a9505cf889
1,080
py
Python
Coursera/The Raspberry Pi Platform and Python Programming for the Raspberry Pi/Week-4/Assignment/LedWithRaspberryPi.py
rishav3101/Online-Courses-Learning
1e9356af331b27b6ee33d376d8d7104edaeac2fa
[ "MIT" ]
331
2019-10-22T09:06:28.000Z
2022-03-27T13:36:03.000Z
Coursera/The Raspberry Pi Platform and Python Programming for the Raspberry Pi/Week-4/Assignment/LedWithRaspberryPi.py
rishav3101/Online-Courses-Learning
1e9356af331b27b6ee33d376d8d7104edaeac2fa
[ "MIT" ]
8
2020-04-10T07:59:06.000Z
2022-02-06T11:36:47.000Z
Coursera/The Raspberry Pi Platform and Python Programming for the Raspberry Pi/Week-4/Assignment/LedWithRaspberryPi.py
rishav3101/Online-Courses-Learning
1e9356af331b27b6ee33d376d8d7104edaeac2fa
[ "MIT" ]
572
2019-07-28T23:43:35.000Z
2022-03-27T22:40:08.000Z
import RPi.GPIO as GPIO import time class Control: def __init__(self): self.LedPin = 13 self.Button = 12 def setup(self): GPIO.setmode(GPIO.BOARD) GPIO.setup(self.LedPin, GPIO.OUT) GPIO.setup(self.Button, GPIO.IN, pull_up_down=GPIO.PUD_UP) GPIO.output(se...
27.692308
66
0.512963
0ac708f37d9fdc16b2b89738d66bdb0f4dee00c9
12,023
py
Python
transonic/backends/cython.py
fluiddyn/transonic
a460e9f6d1139f79b668cb3306d1e8a7e190b72d
[ "BSD-3-Clause" ]
88
2019-01-08T16:39:08.000Z
2022-02-06T14:19:23.000Z
transonic/backends/cython.py
fluiddyn/transonic
a460e9f6d1139f79b668cb3306d1e8a7e190b72d
[ "BSD-3-Clause" ]
13
2019-06-20T15:53:10.000Z
2021-02-09T11:03:29.000Z
transonic/backends/cython.py
fluiddyn/transonic
a460e9f6d1139f79b668cb3306d1e8a7e190b72d
[ "BSD-3-Clause" ]
1
2019-11-05T03:03:14.000Z
2019-11-05T03:03:14.000Z
"""Cython Backend ================= Internal API ------------ .. autoclass:: HeaderFunction :members: :private-members: .. autoclass:: SubBackendJITCython :members: :private-members: .. autoclass:: CythonBackend :members: :private-members: """ import copy import inspect from warnings import warn...
30.592875
91
0.59303
e404362a9962289a9bbaf85840b229f6712195d0
301
py
Python
exercises/es/exc_02_02_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
2,085
2019-04-17T13:10:40.000Z
2022-03-30T21:51:46.000Z
exercises/es/exc_02_02_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
79
2019-04-18T14:42:55.000Z
2022-03-07T08:15:43.000Z
exercises/es/exc_02_02_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
361
2019-04-17T13:34:32.000Z
2022-03-28T04:42:45.000Z
import spacy nlp = spacy.load("es_core_news_sm") doc = nlp("David Bowie tiene el label PER") # Busca el hash para el label del string "PER" person_hash = ____.____.____[____] print(person_hash) # Busca el person_hash para obtener el string person_string = ____.____.____[____] print(person_string)
23.153846
46
0.76412
7c7f088e181bd57f5616a96142e867bcfc476401
434
py
Python
exercises/fr/test_02_09.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
2,085
2019-04-17T13:10:40.000Z
2022-03-30T21:51:46.000Z
exercises/fr/test_02_09.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
79
2019-04-18T14:42:55.000Z
2022-03-07T08:15:43.000Z
exercises/fr/test_02_09.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
361
2019-04-17T13:34:32.000Z
2022-03-28T04:42:45.000Z
def test(): assert ( 'spacy.load("fr_core_news_md")' in __solution__ ), "Charges-tu correctement le modèle moyen ?" assert "doc[1].vector" in __solution__, "Obtiens-tu le bon vecteur ?" __msg__.good( "Bien joué ! Dans l'exercice suivant, tu vas utiliser spaCy pour " "prédire des ...
39.454545
79
0.654378
7caefb619247c3da4b01cbfe4b98ccc93567e319
4,163
py
Python
paddlenlp/datasets/c3.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
paddlenlp/datasets/c3.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
paddlenlp/datasets/c3.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2021 PaddlePaddle Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appli...
38.906542
92
0.569061
6b2a160cee7b2a8618325b6f71bb4bd4dcef96a5
5,595
py
Python
Miscellaneous/BlenderExporter/ExportFudgeScene.py
bynikoala/FUDGE
4102008022dfe38d77d3aea3b13883553b5c80dd
[ "MIT" ]
26
2019-08-22T08:02:05.000Z
2022-03-05T10:41:31.000Z
Miscellaneous/BlenderExporter/ExportFudgeScene.py
bynikoala/FUDGE
4102008022dfe38d77d3aea3b13883553b5c80dd
[ "MIT" ]
184
2019-08-22T06:54:05.000Z
2022-03-31T08:41:34.000Z
Miscellaneous/BlenderExporter/ExportFudgeScene.py
bynikoala/FUDGE
4102008022dfe38d77d3aea3b13883553b5c80dd
[ "MIT" ]
37
2019-08-22T09:50:37.000Z
2022-03-17T11:04:45.000Z
# This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but ...
28.401015
93
0.612154
86ada208c24e2acf4f092a0863cbd008185eca43
2,790
py
Python
findMoviesByTerminal.py
WuNull/findmovie
29d3ef6fe2282f48be57780f5e8366de1d3479a6
[ "Apache-2.0" ]
1
2019-11-26T07:03:06.000Z
2019-11-26T07:03:06.000Z
findMoviesByTerminal.py
WuNull/findmovie
29d3ef6fe2282f48be57780f5e8366de1d3479a6
[ "Apache-2.0" ]
null
null
null
findMoviesByTerminal.py
WuNull/findmovie
29d3ef6fe2282f48be57780f5e8366de1d3479a6
[ "Apache-2.0" ]
null
null
null
""" python-version: 3.8.0 查找电影 小工具 实现思路: 1.实现电影资源网站的搜索功能 2.获取搜索结果的网页信息 3.进入电影详情页面获取播放和下载地址 """ # coding=utf-8 import requests from lxml import etree from time import time # 请求头信息 headers = { 'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3...
27.352941
136
0.618638
86b79b83668651257d8a84677c52f720ae506e90
74
py
Python
src/onegov/org/formats/__init__.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/org/formats/__init__.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/org/formats/__init__.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from onegov.org.formats.digirez import DigirezDB __all__ = ['DigirezDB']
18.5
48
0.783784
d490cc800bd0afa70ca1dd2baa2fbdb81706c3b5
645
py
Python
pyntcloud/scalar_fields/base.py
bernssolg/pyntcloud-master
84cf000b7a7f69a2c1b36f9624f05f65160bf992
[ "MIT" ]
1,142
2016-10-10T08:55:30.000Z
2022-03-30T04:46:16.000Z
pyntcloud/scalar_fields/base.py
bernssolg/pyntcloud-master
84cf000b7a7f69a2c1b36f9624f05f65160bf992
[ "MIT" ]
195
2016-10-10T08:30:37.000Z
2022-02-17T12:51:17.000Z
pyntcloud/scalar_fields/base.py
bernssolg/pyntcloud-master
84cf000b7a7f69a2c1b36f9624f05f65160bf992
[ "MIT" ]
215
2017-02-28T00:50:29.000Z
2022-03-22T17:01:31.000Z
from abc import ABC, abstractmethod from collections import OrderedDict class ScalarField(ABC): """Base class for scalar fields.""" def __init__(self, *, pyntcloud): self.pyntcloud = pyntcloud self.to_be_added = OrderedDict() def get_and_set(self): sf_added = [] for k, v ...
21.5
45
0.592248
d4ef614df2b96758d9e07e597e3f6ed6a8d10866
3,197
py
Python
project/api/schemas.py
DanielGrams/cityservice
c487c34b5ba6541dcb441fe903ab2012c2256893
[ "MIT" ]
null
null
null
project/api/schemas.py
DanielGrams/cityservice
c487c34b5ba6541dcb441fe903ab2012c2256893
[ "MIT" ]
35
2022-01-24T22:15:59.000Z
2022-03-31T15:01:35.000Z
project/api/schemas.py
DanielGrams/cityservice
c487c34b5ba6541dcb441fe903ab2012c2256893
[ "MIT" ]
null
null
null
from marshmallow import ValidationError, fields, missing, validate from marshmallow.decorators import pre_load from project.api import marshmallow class SQLAlchemyBaseSchema(marshmallow.SQLAlchemySchema): def __init__(self, *args, **kwargs): super().__init__(*args, **kwargs) def make_post_schema(sel...
31.038835
88
0.658743
be18167d42f7c6d4facf065dd338820b0761fc68
520
py
Python
bot/handlers/users/get_voice.py
YoshlikMedia/STT-uzbek-bot
fec5d6a7bec4135aeb35a86970193654637194f5
[ "MIT" ]
null
null
null
bot/handlers/users/get_voice.py
YoshlikMedia/STT-uzbek-bot
fec5d6a7bec4135aeb35a86970193654637194f5
[ "MIT" ]
null
null
null
bot/handlers/users/get_voice.py
YoshlikMedia/STT-uzbek-bot
fec5d6a7bec4135aeb35a86970193654637194f5
[ "MIT" ]
null
null
null
from aiogram import types from transformers import pipeline from loader import dp @dp.message_handler(content_types=types.ContentType.VOICE) async def get_voice(msg: types.Message): await msg.reply("<b>Qabul qildim. Iltimos, biroz kuting!</b>") with open('sample.flac', 'wb') as f: await msg.voice.do...
30.588235
80
0.698077
07a01fb881cc3a602222b8b7b45a955663c33e30
1,973
py
Python
src/cobalt/bin/download_report_client.py
opensource-assist/fuschia
66646c55b3d0b36aae90a4b6706b87f1a6261935
[ "BSD-3-Clause" ]
3
2020-08-02T04:46:18.000Z
2020-08-07T10:10:53.000Z
src/cobalt/bin/download_report_client.py
opensource-assist/fuschia
66646c55b3d0b36aae90a4b6706b87f1a6261935
[ "BSD-3-Clause" ]
null
null
null
src/cobalt/bin/download_report_client.py
opensource-assist/fuschia
66646c55b3d0b36aae90a4b6706b87f1a6261935
[ "BSD-3-Clause" ]
1
2020-08-07T10:11:49.000Z
2020-08-07T10:11:49.000Z
#!/usr/bin/env python2.7 # Copyright 2017 The Fuchsia Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Script to download Cobalt's report client binary from Google Cloud Storage. We detect the current platform and download the appro...
29.447761
78
0.747086
07af7129f656fcdaccd344683c480d19ef3b1266
1,667
py
Python
frappe-bench/apps/erpnext/erpnext/patches/v9_0/fix_subscription_next_date.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/patches/v9_0/fix_subscription_next_date.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/patches/v9_0/fix_subscription_next_date.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
# Copyright (c) 2017, Frappe and Contributors # License: GNU General Public License v3. See license.txt from __future__ import unicode_literals import frappe from frappe.utils import getdate from erpnext.accounts.doctype.subscription.subscription import get_next_schedule_date def execute(): frappe.reload_doctype('Su...
38.767442
101
0.746251
07b2e2781ec8feb53d88545d4b50042cd04645b5
247
py
Python
frappe-bench/apps/erpnext/erpnext/domains/retail.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/domains/retail.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/domains/retail.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
data = { 'desktop_icons': [ 'POS', 'Item', 'Customer', 'Sales Invoice', 'Purchase Order', 'Accounts', 'Task', 'ToDo' ], 'set_value': [ ['Stock Settings', None, 'show_barcode_field', 1] ], 'default_portal_role': 'Customer' }
14.529412
51
0.587045