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
e8db7b8afe28efde2a5b3d53186f27fb42108a8d
1,912
py
Python
src/test/tests/hybrid/missingdata.py
visit-dav/vis
c08bc6e538ecd7d30ddc6399ec3022b9e062127e
[ "BSD-3-Clause" ]
226
2018-12-29T01:13:49.000Z
2022-03-30T19:16:31.000Z
src/test/tests/hybrid/missingdata.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/hybrid/missingdata.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: missingdata.py # # Tests: missing data # # Programmer: Brad Whitlock # Date: Thu Jan 19 09:49:15 PST 2012 # # Modifications: # # ------------------------------------------------------------...
26.555556
78
0.619247
33269c8198e5473d3ddda4bf83fff9637afee268
1,793
py
Python
src/graph2.py
gpu0/nnGraph
ae68af41804ce95dd4dbd6deeea57e377915acc9
[ "MIT" ]
null
null
null
src/graph2.py
gpu0/nnGraph
ae68af41804ce95dd4dbd6deeea57e377915acc9
[ "MIT" ]
null
null
null
src/graph2.py
gpu0/nnGraph
ae68af41804ce95dd4dbd6deeea57e377915acc9
[ "MIT" ]
null
null
null
# t = 2 * (x*y + max(z,w)) class Num: def __init__(self, val): self.val = val def forward(self): return self.val def backward(self, val): print val class Mul: def __init__(self, left, right): self.left = left self.right = right def forward(self): sel...
25.985507
57
0.572783
0421fc55c0cd9357dc4b4cf552bac0572d28cf55
1,609
py
Python
KnowledgeQuizTool/SummitMeeting/TitleBaidu.py
JianmingXia/StudyTest
66d688ad41bbce619f44359ea126ff07a923f97b
[ "MIT" ]
null
null
null
KnowledgeQuizTool/SummitMeeting/TitleBaidu.py
JianmingXia/StudyTest
66d688ad41bbce619f44359ea126ff07a923f97b
[ "MIT" ]
68
2020-09-05T04:22:49.000Z
2022-03-25T18:47:08.000Z
KnowledgeQuizTool/SummitMeeting/TitleBaidu.py
JianmingXia/StudyTest
66d688ad41bbce619f44359ea126ff07a923f97b
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # @Author : Skye # @Time : 2018/1/8 20:38 # @desc : python 3 , 答题闯关辅助,截屏 ,OCR 识别,百度搜索 import io import urllib.parse import webbrowser import requests import base64 import matplotlib.pyplot as plt import numpy as np from PIL import Image import os def pull_screenshot(): os.system('a...
26.377049
128
0.709758
acfbf91315ae8fa759e47178ec90f3b7a692cd5c
7,881
py
Python
warp/utils/config_parsing.py
j-helland/warp
2a71346f0ec4d4e6fd45ed3b5e972b683724287c
[ "Unlicense" ]
null
null
null
warp/utils/config_parsing.py
j-helland/warp
2a71346f0ec4d4e6fd45ed3b5e972b683724287c
[ "Unlicense" ]
null
null
null
warp/utils/config_parsing.py
j-helland/warp
2a71346f0ec4d4e6fd45ed3b5e972b683724287c
[ "Unlicense" ]
null
null
null
# std import datetime from copy import deepcopy from collections import deque import yaml # from .lazy_loader import LazyLoader as LL # yaml = LL('yaml', globals(), 'yaml') # json = LL('json', globals(), 'json') # types from typing import Dict, Any, Union, Tuple __all__ = [ 'load_config_file', 'save_config...
31.398406
112
0.597005
a87dc28a95aae4aa7718fabb0f98ba00c0f8f068
773
py
Python
word2vec_model/BagCentroids.py
wingedRuslan/Sentiment-Analysis
6dbc90175a2b42e33e0779f4a09b04ea99689534
[ "MIT" ]
null
null
null
word2vec_model/BagCentroids.py
wingedRuslan/Sentiment-Analysis
6dbc90175a2b42e33e0779f4a09b04ea99689534
[ "MIT" ]
null
null
null
word2vec_model/BagCentroids.py
wingedRuslan/Sentiment-Analysis
6dbc90175a2b42e33e0779f4a09b04ea99689534
[ "MIT" ]
null
null
null
def create_bag_of_centroids(wordlist, word_centroid_map): """ a function to create bags of centroids """ # The number of clusters is equal to the highest cluster index in the word / centroid map num_centroids = max( word_centroid_map.values() ) + 1 # Pre-allocate the bag of centro...
35.136364
93
0.676585
4ff048f6366944e28bb0e1aee471e8cd65282915
1,122
py
Python
数据结构/NowCode/37_Print.py
Blankwhiter/LearningNotes
83e570bf386a8e2b5aa699c3d38b83e5dcdd9cb0
[ "MIT" ]
null
null
null
数据结构/NowCode/37_Print.py
Blankwhiter/LearningNotes
83e570bf386a8e2b5aa699c3d38b83e5dcdd9cb0
[ "MIT" ]
3
2020-08-14T07:50:27.000Z
2020-08-14T08:51:06.000Z
数据结构/NowCode/37_Print.py
Blankwhiter/LearningNotes
83e570bf386a8e2b5aa699c3d38b83e5dcdd9cb0
[ "MIT" ]
2
2021-03-14T05:58:45.000Z
2021-08-29T17:25:52.000Z
class TreeNode: def __init__(self, x): self.val = x self.left = None self.right = None class Solution: # 返回二维列表[[1,2],[4,5]] def Print(self, pRoot): if pRoot == None: return [] queue1 = [pRoot] queue2 = [] ret = [] while queue1 or q...
29.526316
52
0.421569
ba193713f4e6daa42b6733b362bbc46c29b53357
10,391
py
Python
exercises/networking_selfpaced/networking-workshop/collections/ansible_collections/community/general/plugins/module_utils/utm_utils.py
tr3ck3r/linklight
5060f624c235ecf46cb62cefcc6bddc6bf8ca3e7
[ "MIT" ]
null
null
null
exercises/networking_selfpaced/networking-workshop/collections/ansible_collections/community/general/plugins/module_utils/utm_utils.py
tr3ck3r/linklight
5060f624c235ecf46cb62cefcc6bddc6bf8ca3e7
[ "MIT" ]
null
null
null
exercises/networking_selfpaced/networking-workshop/collections/ansible_collections/community/general/plugins/module_utils/utm_utils.py
tr3ck3r/linklight
5060f624c235ecf46cb62cefcc6bddc6bf8ca3e7
[ "MIT" ]
null
null
null
# This code is part of Ansible, but is an independent component. # This particular file snippet, and this file snippet only, is BSD licensed. # Modules you write using this snippet, which is embedded dynamically by Ansible # still belong to the author of the module, and may assign their own license # to the complete wo...
44.217021
119
0.626311
fa35fd9c4c3f40af307596284bdf4287e3dd908d
638
py
Python
Python/Buch_ATBS/Teil_2/Kapitel_17_Bildbearbeitung/04_texte_schreiben/04_texte_schreiben.py
Apop85/Scripts
e71e1c18539e67543e3509c424c7f2d6528da654
[ "MIT" ]
null
null
null
Python/Buch_ATBS/Teil_2/Kapitel_17_Bildbearbeitung/04_texte_schreiben/04_texte_schreiben.py
Apop85/Scripts
e71e1c18539e67543e3509c424c7f2d6528da654
[ "MIT" ]
6
2020-12-24T15:15:09.000Z
2022-01-13T01:58:35.000Z
Python/Buch_ATBS/Teil_2/Kapitel_17_Bildbearbeitung/04_texte_schreiben/04_texte_schreiben.py
Apop85/Scripts
1d8dad316c55e1f1343526eac9e4b3d0909e4873
[ "MIT" ]
null
null
null
# 04_texte_schreiben.py # In diesem Beispiel geht es darum Texte in ein Bild zu schreiben mittels ImageFont aus dem Modul PIL from PIL import Image, ImageFont, ImageDraw import os os.chdir(os.path.dirname(__file__)) target_file='.\\text_in_image.png' if os.path.exists(target_file): os.remove(target_file) windows_...
31.9
101
0.763323
fa5755c213e58345d8c0de7794177a485cfa6195
5,322
py
Python
Co-Simulation/Sumo/run_tracis_synchronization.py
uruzahe/carla
940c2ab23cce1eda1ef66de35f66b42d40865fb1
[ "MIT" ]
null
null
null
Co-Simulation/Sumo/run_tracis_synchronization.py
uruzahe/carla
940c2ab23cce1eda1ef66de35f66b42d40865fb1
[ "MIT" ]
null
null
null
Co-Simulation/Sumo/run_tracis_synchronization.py
uruzahe/carla
940c2ab23cce1eda1ef66de35f66b42d40865fb1
[ "MIT" ]
null
null
null
# coding: utf-8 import argparse import logging import os import sys from util.func import ( data_from_json, ) if 'SUMO_HOME' in os.environ: sys.path.append(os.path.join(os.environ['SUMO_HOME'], 'tools')) import traci else: sys.exit("Please declare environment variable 'SUMO_HOME'") # ----- GLOBAL_VA...
34.335484
153
0.599211
fa6e2940900591d9470ba01c2dd2e48f3b5615c8
1,136
py
Python
data-pipeline/src/data_pipeline/datasets/exac/exac_regional_missense_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_regional_missense_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_regional_missense_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_regional_missense_constraint(path): ds = hl.import_table( path, missing="", types={ "transcript": hl.tstr, "gene": hl.tstr, "chr": hl.tstr, "amino_acids": hl.tstr, "genomic_start": hl.tint, ...
29.894737
115
0.601232
ad1ab51f8499f1d4ded5f9bd2c0db3404d94ac2b
8,956
py
Python
apps/quiver/views.py
OpenAdaptronik/Rattler
c3bdde0ca56b6d77f49bc830fa2b8bb41a26bae4
[ "MIT" ]
2
2018-05-18T08:38:29.000Z
2018-05-22T08:26:09.000Z
apps/quiver/views.py
IT-PM-OpenAdaptronik/Webapp
c3bdde0ca56b6d77f49bc830fa2b8bb41a26bae4
[ "MIT" ]
118
2017-10-31T13:45:09.000Z
2018-02-24T20:51:42.000Z
apps/quiver/views.py
OpenAdaptronik/Rattler
c3bdde0ca56b6d77f49bc830fa2b8bb41a26bae4
[ "MIT" ]
null
null
null
from apps.quiver.models import AnalyticsService, AnalyticsServiceExecution from django.shortcuts import render, HttpResponseRedirect from django.core.exceptions import PermissionDenied from django.views.generic import FormView, CreateView, ListView, DetailView, UpdateView from django.contrib.auth.mixins import LoginRe...
41.082569
135
0.704891
7e38b53b5f4c4aae5647971334f2234e632edaa5
1,069
py
Python
chapter100/mongodb_04.py
thiagola92/learning-databases-with-python
cf23c34d7fd1ecd36dd3e7b30dc5916eb23eaf1e
[ "MIT" ]
null
null
null
chapter100/mongodb_04.py
thiagola92/learning-databases-with-python
cf23c34d7fd1ecd36dd3e7b30dc5916eb23eaf1e
[ "MIT" ]
null
null
null
chapter100/mongodb_04.py
thiagola92/learning-databases-with-python
cf23c34d7fd1ecd36dd3e7b30dc5916eb23eaf1e
[ "MIT" ]
null
null
null
import time from pymongo import MongoClient from datetime import datetime from threading import Thread, Lock start = datetime.now() client = MongoClient("mongodb://username:password@127.0.0.1") database = client["database_name"] collection = database["collection_name"] threads_count = 0 lock = Lock() package = [] ...
20.169811
72
0.656688
cbc2172760f370c3b4d7c60769a266040ec53d06
442
py
Python
BITs/2014/Abdrahmanova_G_I/task_3_1.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
BITs/2014/Abdrahmanova_G_I/task_3_1.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
BITs/2014/Abdrahmanova_G_I/task_3_1.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
#Задача 3. Вариант 1. #Напишите программу, которая выводит имя "Иво Ливи", и запрашивает его псевдоним. Программа должна сцеплять две эти строки и выводить полученную строку, разделяя имя и псевдоним с помощью тире. name=input('Герой нашей сегодняшней программы - Иво Ливи. \nПод каким же именем мы знаем этого человека?...
55.25
193
0.757919
3892d5674879bbcf71468a4b3b615df537552e19
729
py
Python
HackTheVote/2020/fileshare/cleaner.py
mystickev/ctf-archives
89e99a5cd5fb6b2923cad3fe1948d3ff78649b4e
[ "MIT" ]
1
2021-11-02T20:53:58.000Z
2021-11-02T20:53:58.000Z
HackTheVote/2020/fileshare/cleaner.py
ruhan-islam/ctf-archives
8c2bf6a608c821314d1a1cfaa05a6cccef8e3103
[ "MIT" ]
null
null
null
HackTheVote/2020/fileshare/cleaner.py
ruhan-islam/ctf-archives
8c2bf6a608c821314d1a1cfaa05a6cccef8e3103
[ "MIT" ]
1
2021-12-19T11:06:24.000Z
2021-12-19T11:06:24.000Z
import os, time, shutil def get_used_dirs(): pids = [p for p in os.listdir("/proc") if p.isnumeric()] res = set() for p in pids: try: path = os.path.realpath("/proc/%s/cwd"%p) if path.startswith("/tmp/fileshare."): res.add(path) except: pa...
25.137931
84
0.463649
2a145ab11f78cc5615c8d4ed402ea232a50a31a2
297
py
Python
exercises/ja/solution_01_03_02.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
2
2020-07-07T01:46:37.000Z
2021-04-20T03:19:43.000Z
exercises/ja/solution_01_03_02.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
exercises/ja/solution_01_03_02.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
# spaCyをインポートし、日本語のnlpオブジェクトを作成 import spacy nlp = spacy.blank("ja") # テキストを処理 doc = nlp("私はツリーカンガルーとイッカクが好きです。") # 「ツリーカンガルー」のスライスを選択 tree_kangaroos = doc[2:4] print(tree_kangaroos.text) # 「ツリーカンガルーとイッカク」のスライスを選択 tree_kangaroos_and_narwhals = doc[2:6] print(tree_kangaroos_and_narwhals.text)
18.5625
39
0.787879
4f080165a526d26946f0e9abfb0e9d778b0984e7
1,851
py
Python
research/recommend/Fat-DeepFFM/eval310.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/recommend/Fat-DeepFFM/eval310.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/recommend/Fat-DeepFFM/eval310.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...
31.913793
108
0.67477
355b54f8b2fba95e01f01d6e3b0468747cbcfa07
587
py
Python
Curso-Em-Video-Python/1Materias/08_Utilizando_Modulos/#08 - Utilizando Módulos C random.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
Curso-Em-Video-Python/1Materias/08_Utilizando_Modulos/#08 - Utilizando Módulos C random.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
Curso-Em-Video-Python/1Materias/08_Utilizando_Modulos/#08 - Utilizando Módulos C random.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
import random # num = random.random() para numeros de 0 e 1 num = random.randint(1, 10) print(num) '''import random 'choice' n1 = str(input('Primeiro aluno: ')) n2 = str(input('Segundo aluno: ')) n3 = str(input('Terceiro aluno: ')) n4 = str(input('Quarto aluno: ')) lista = [n1, n2, n3, n4] escolha = random.choice(lis...
24.458333
45
0.645656
57a8e223905afe0cac15558594f1c75596817567
15,208
py
Python
src/test/rebaseline-p.py
visit-dav/vis
c08bc6e538ecd7d30ddc6399ec3022b9e062127e
[ "BSD-3-Clause" ]
226
2018-12-29T01:13:49.000Z
2022-03-30T19:16:31.000Z
src/test/rebaseline-p.py
visit-dav/vis
c08bc6e538ecd7d30ddc6399ec3022b9e062127e
[ "BSD-3-Clause" ]
5,100
2019-01-14T18:19:25.000Z
2022-03-31T23:08:36.000Z
src/test/rebaseline-p.py
visit-dav/vis
c08bc6e538ecd7d30ddc6399ec3022b9e062127e
[ "BSD-3-Clause" ]
84
2019-01-24T17:41:50.000Z
2022-03-10T10:01:46.000Z
import filecmp import os import sys import shutil import subprocess import time import unittest if (sys.version_info > (3, 0)): import urllib.request, urllib.parse, urllib.error else: import urllib from optparse import OptionParser from PyQt4 import QtCore,QtGui parser = OptionParser() parser.add_option("-r",...
35.783529
81
0.647554
57dfafb9e8933dbd5e630eaa629e5d73f23115df
1,866
py
Python
tests/onegov/wtfs/test_fields.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/wtfs/test_fields.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/wtfs/test_fields.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from cgi import FieldStorage from datetime import date from io import BytesIO from onegov.core.utils import Bunch from onegov.form import Form from onegov.wtfs.fields import HintField from onegov.wtfs.fields import MunicipalityDataUploadField class PostData(dict): def getlist(self, key): v = self[key] ...
29.15625
76
0.663987
aa47d21c6ff69f1572502674f4acbedbda768571
2,371
py
Python
ex1/gerador.py
renzon/oo-inpe
1b33939974f998badbeebd7bfe182070e77ef98f
[ "MIT" ]
null
null
null
ex1/gerador.py
renzon/oo-inpe
1b33939974f998badbeebd7bfe182070e77ef98f
[ "MIT" ]
null
null
null
ex1/gerador.py
renzon/oo-inpe
1b33939974f998badbeebd7bfe182070e77ef98f
[ "MIT" ]
null
null
null
from random import randint from ex1.evento import Evento class Gerador(): def __init__(self, msg): self.msg = msg def gerar_evento(self, tempo): """ Método que gera evento levando em conta tempo de execução. :return: Instancia de Evento ou Nulo se não for para gerar envento ...
27.569767
95
0.660059
103175058f2fa208dcde4dafb16a9cb6d6a48a58
723
py
Python
Boot2Root/hackthebox/Tenten/files/exploit.py
Kan1shka9/CTFs
33ab33e094ea8b52714d5dad020c25730e91c0b0
[ "MIT" ]
21
2016-02-06T14:30:01.000Z
2020-09-11T05:39:17.000Z
Boot2Root/hackthebox/Tenten/files/exploit.py
Kan1shka9/CTFs
33ab33e094ea8b52714d5dad020c25730e91c0b0
[ "MIT" ]
null
null
null
Boot2Root/hackthebox/Tenten/files/exploit.py
Kan1shka9/CTFs
33ab33e094ea8b52714d5dad020c25730e91c0b0
[ "MIT" ]
7
2017-02-02T16:27:02.000Z
2021-04-30T17:14:53.000Z
import requests print """ CVE-2015-6668 Title: CV filename disclosure on Job-Manager WP Plugin Author: Evangelos Mourikis Blog: https://vagmour.eu Plugin URL: http://www.wp-jobmanager.com Versions: <=0.7.25 """ website = raw_input('Enter a vulnerable website: ') filename = raw_input('Enter a file nam...
30.125
124
0.593361
103fc50711d0b0de84f01f2724705c3318868eda
273
py
Python
src/aijack/attack/inversion/__init__.py
luoshenseeker/AIJack
4e871a5b3beb4b7c976d38060d6956efcebf880d
[ "MIT" ]
1
2022-03-17T21:17:44.000Z
2022-03-17T21:17:44.000Z
src/aijack/attack/inversion/__init__.py
luoshenseeker/AIJack
4e871a5b3beb4b7c976d38060d6956efcebf880d
[ "MIT" ]
null
null
null
src/aijack/attack/inversion/__init__.py
luoshenseeker/AIJack
4e871a5b3beb4b7c976d38060d6956efcebf880d
[ "MIT" ]
1
2022-03-17T21:17:46.000Z
2022-03-17T21:17:46.000Z
from .gan_attack import GAN_Attack # noqa: F401 from .generator_attack import Generator_Attack # noqa: F401 from .gradientinversion import GradientInversion_Attack # noqa: F401 from .mi_face import MI_FACE # noqa: F401 from .utils import DataRepExtractor # noqa: F401
45.5
69
0.798535
104022f80f0cfe30ed3aab519ac4eeadac303cfa
867
py
Python
INBa/2015/ZORIN_D_I/task_4_7.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
INBa/2015/ZORIN_D_I/task_4_7.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
INBa/2015/ZORIN_D_I/task_4_7.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
# Задача 4. Вариант 7. # Напишите программу, которая выводит имя, под которым скрывается Мария Луиза Чеччарелли. Дополнительно необходимо вывести область интересов указанной личности, место рождения, годы рождения и смерти (если человек умер), вычислить возраст на данный момент (или момент смерти). Для хранения всех не...
43.35
443
0.7797
eaa454aeb2637a676c1e50bb9a3b6f2eb3e45e6f
87
py
Python
main.py
spdir/sakf
9a07c5f90765201a42d524dc6d4554f4ccd3c750
[ "Apache-2.0" ]
null
null
null
main.py
spdir/sakf
9a07c5f90765201a42d524dc6d4554f4ccd3c750
[ "Apache-2.0" ]
null
null
null
main.py
spdir/sakf
9a07c5f90765201a42d524dc6d4554f4ccd3c750
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- from sakf.sakf import main if __name__ == '__main__': main()
17.4
26
0.62069
eaaee56b527744c35b0a2e71b0cf37879102767a
208
py
Python
python/course/leetcode/leetcode.py
TimVan1596/ACM-ICPC
07f7d728db1ecd09c5a3d0f05521930b14eb9883
[ "Apache-2.0" ]
1
2019-05-22T07:12:34.000Z
2019-05-22T07:12:34.000Z
python/course/leetcode/leetcode.py
TimVan1596/ACM-ICPC
07f7d728db1ecd09c5a3d0f05521930b14eb9883
[ "Apache-2.0" ]
3
2021-12-10T01:13:54.000Z
2021-12-14T21:18:42.000Z
python/course/leetcode/leetcode.py
TimVan1596/ACM-ICPC
07f7d728db1ecd09c5a3d0f05521930b14eb9883
[ "Apache-2.0" ]
null
null
null
# -*- coding:utf-8 -*- # @Time:2020/6/15 11:38 # @Author:TimVan # @File:leetcode.py # @Software:PyCharm # Definition for singly-linked list. # for j in range(10, 5, -1): # print(j) print('a'.find(' '))
17.333333
36
0.605769
21c5953806a590d303da60ce30af9e05c9ffcf7f
1,046
py
Python
client.py
Klark007/Selbstfahrendes-Auto-im-Modell
d7fe81392de2b29b7dbc7c9d929fa0031b89900b
[ "MIT" ]
null
null
null
client.py
Klark007/Selbstfahrendes-Auto-im-Modell
d7fe81392de2b29b7dbc7c9d929fa0031b89900b
[ "MIT" ]
null
null
null
client.py
Klark007/Selbstfahrendes-Auto-im-Modell
d7fe81392de2b29b7dbc7c9d929fa0031b89900b
[ "MIT" ]
null
null
null
import socket from ast import literal_eval import Yetiborg.Drive as Yetiborg HEADERSIZE = 2 s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) s.connect(("localhost", 12345)) # 192.168.0.11 / localhost / 192.168.0.108 # car always looks up at the beginning car = Yetiborg.Yetiborg((0, 1)) """ fs: finished "...
18.350877
75
0.637667
21d74dd97abbafbab41d2b79624c65a5587f6d58
3,134
py
Python
unsupervised_learning/kmeans.py
toorajtaraz/computational_intelligence_mini_projects
79d1782c3b61ee15ac01dcf377bdc369962adb18
[ "MIT" ]
3
2022-02-09T21:35:14.000Z
2022-02-10T15:31:43.000Z
unsupervised_learning/kmeans.py
toorajtaraz/computational_intelligence_mini_projects
79d1782c3b61ee15ac01dcf377bdc369962adb18
[ "MIT" ]
null
null
null
unsupervised_learning/kmeans.py
toorajtaraz/computational_intelligence_mini_projects
79d1782c3b61ee15ac01dcf377bdc369962adb18
[ "MIT" ]
null
null
null
from pathlib import Path import sys path = str(Path(Path(__file__).parent.absolute()).parent.absolute()) sys.path.insert(0, path) from mnist_utils.util import _x, _y_int from sklearn.cluster import MiniBatchKMeans from sklearn.metrics import accuracy_score, adjusted_rand_score import numpy as np from fast_pytorch_kmean...
35.613636
84
0.678685
10d1e06975d52bb7b5f8e0f3c90a9460e0d76260
12,674
py
Python
year_2/os_sem2/checkLab14/app.py
honchardev/KPI
f8425681857c02a67127ffb05c0af0563a8473e1
[ "MIT" ]
null
null
null
year_2/os_sem2/checkLab14/app.py
honchardev/KPI
f8425681857c02a67127ffb05c0af0563a8473e1
[ "MIT" ]
21
2020-03-24T16:26:04.000Z
2022-02-18T15:56:16.000Z
year_2/os_sem2/checkLab14/app.py
honchardev/KPI
f8425681857c02a67127ffb05c0af0563a8473e1
[ "MIT" ]
null
null
null
import sys import os import re def main(): # Check input for the program. checker = ArgsChecker() if not checker.checkInputArgsAreCorrect(): return 1 if checker.processMode == checker.PROCESS_FROM_DIR: dirProcesser = FromDirProcesser() dirProcesser.process(checker.csvFilePath)...
36.524496
110
0.566435
3385d0740834d136b94244297d0e01af822e4328
622
py
Python
Blatt1/src/script.py
lewis206/Computational_Physics
06ad6126685eaf65f5834bfe70ebd91b33314395
[ "MIT" ]
null
null
null
Blatt1/src/script.py
lewis206/Computational_Physics
06ad6126685eaf65f5834bfe70ebd91b33314395
[ "MIT" ]
null
null
null
Blatt1/src/script.py
lewis206/Computational_Physics
06ad6126685eaf65f5834bfe70ebd91b33314395
[ "MIT" ]
null
null
null
import numpy as np import matplotlib.pyplot as plt import matplotlib # Set fontsize larger for latex plots matplotlib.rcParams.update({'font.size': 20}) # Generate data from file x, y = np.genfromtxt("bin/python_Aufgabe2.txt", unpack=True) m, n = x[-1], y[-1] # Plotting plt.figure(figsize=(12,7)) plt.grid() plt.xla...
27.043478
70
0.680064
d51442e5802a7e7a7d3c8bda504b303ddbb541d1
483
py
Python
books/PythonAutomate/webscrap/using_bs4.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
books/PythonAutomate/webscrap/using_bs4.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
books/PythonAutomate/webscrap/using_bs4.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
import bs4 with open("example.html") as f: # 텍스트 파일로 부터 BeautifulSoup 객체 생성 soup = bs4.BeautifulSoup(f.read(), "lxml") print(type(soup)) # <class 'bs4.BeautifulSoup'> # id가 author인 태그 리스트 조회 elems = soup.select("#author") print(type(elems)) # <class 'list'> print(type(elems[0])) # <class 'bs4.element.Tag'...
19.32
50
0.654244
1d92705a0e03671b2fdc534d799cc8d39e832d40
3,889
py
Python
src/bo4e/com/angebotsteil.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
1
2022-03-02T12:49:44.000Z
2022-03-02T12:49:44.000Z
src/bo4e/com/angebotsteil.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
21
2022-02-04T07:38:46.000Z
2022-03-28T14:01:53.000Z
src/bo4e/com/angebotsteil.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
null
null
null
""" Contains Angebotsteil class and corresponding marshmallow schema for de-/serialization """ from typing import List, Optional import attr from marshmallow import fields from bo4e.bo.marktlokation import Marktlokation, MarktlokationSchema from bo4e.com.angebotsposition import Angebotsposition, AngebotspositionSche...
41.37234
179
0.750579
d5220e82bf5048293d79285d2100fa6124ce5c82
695
py
Python
Arrays and Strings/LongestSubstringWithoutRepeating.py
dileeppandey/hello-interview
78f6cf4e2da4106fd07f4bd86247026396075c69
[ "MIT" ]
null
null
null
Arrays and Strings/LongestSubstringWithoutRepeating.py
dileeppandey/hello-interview
78f6cf4e2da4106fd07f4bd86247026396075c69
[ "MIT" ]
null
null
null
Arrays and Strings/LongestSubstringWithoutRepeating.py
dileeppandey/hello-interview
78f6cf4e2da4106fd07f4bd86247026396075c69
[ "MIT" ]
1
2020-02-12T16:57:46.000Z
2020-02-12T16:57:46.000Z
""" https://leetcode.com/problems/longest-substring-without-repeating-characters/ Given a string, find the length of the longest substring without repeating characters. """ class Solution: def lengthOfLongestSubstring(self, s): longest = 0 longest_substr = "" for ch in s: if...
27.8
86
0.630216
d5675b3789a7238a94e6d0ec1c781776af8848b8
3,737
py
Python
products/admin.py
silver-whale-enterprises-llc/amzproduzer
25e63f64b0ef09241475c72af9a710dcb7d9e926
[ "Apache-2.0" ]
1
2019-07-22T14:03:11.000Z
2019-07-22T14:03:11.000Z
products/admin.py
silver-whale-enterprises-llc/amzproduzer
25e63f64b0ef09241475c72af9a710dcb7d9e926
[ "Apache-2.0" ]
null
null
null
products/admin.py
silver-whale-enterprises-llc/amzproduzer
25e63f64b0ef09241475c72af9a710dcb7d9e926
[ "Apache-2.0" ]
null
null
null
import csv from django.contrib import admin from django.forms import ModelForm from django.http import HttpRequest from products.models import AmazonCategory, AmazonProductListing from products.tasks import process_inventory_upload from products.utils import find_price_col_index, save_status, find_identifier_col_inde...
32.780702
113
0.613059
63456d2b7e536035a7766de0ff9f77efbb0f499a
357
py
Python
utils.py
cyborg00222/kowalsky.at
090778863625b67bce942fe85716941c3bf75a4b
[ "MIT" ]
null
null
null
utils.py
cyborg00222/kowalsky.at
090778863625b67bce942fe85716941c3bf75a4b
[ "MIT" ]
null
null
null
utils.py
cyborg00222/kowalsky.at
090778863625b67bce942fe85716941c3bf75a4b
[ "MIT" ]
null
null
null
# Peter Kowalsky - 10.06.19 import os def check_if_file_exists(path): exists = os.path.isfile(path) if exists: return 1 else: return 0 def list_all_files_in_dir(path, type): files = [] # r=root, d=directories, f = files for r, d, f in os.walk(path): for file in f: if type in file: ...
17.85
38
0.638655
7f29ba6ebc54ec3ef0a767a7c315061f9ee3a3ff
8,224
py
Python
year_3/comppi_1/managers/views.py
honchardev/KPI
f8425681857c02a67127ffb05c0af0563a8473e1
[ "MIT" ]
null
null
null
year_3/comppi_1/managers/views.py
honchardev/KPI
f8425681857c02a67127ffb05c0af0563a8473e1
[ "MIT" ]
21
2020-03-24T16:26:04.000Z
2022-02-18T15:56:16.000Z
year_3/comppi_1/managers/views.py
honchardev/KPI
f8425681857c02a67127ffb05c0af0563a8473e1
[ "MIT" ]
null
null
null
import json from django.contrib.auth import authenticate, login, logout from django.contrib.auth.models import User from django.http import JsonResponse from django.shortcuts import get_object_or_404 from django.utils.decorators import method_decorator from django.views.decorators.csrf import csrf_exempt from .models...
42.174359
102
0.678867
7f4616f095924fa5eac33a11190968db43cccd4e
261
py
Python
python/decorator/function_transform_with_decorator.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
python/decorator/function_transform_with_decorator.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
python/decorator/function_transform_with_decorator.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
def debug_transformer(func): def wrapper(): print(f'Function `{func.__name__}` called') func() print(f'Function `{func.__name__}` finished') return wrapper @debug_transformer def walkout(): print('Bye Felicia') walkout()
17.4
53
0.636015
7fa63fc07d4fb1ef716494e877960f58b0ca18d6
1,935
py
Python
year_3/databases_sem1/lab2/rdmslab2/api/dbmodels/payrolls.py
honchardev/KPI
f8425681857c02a67127ffb05c0af0563a8473e1
[ "MIT" ]
null
null
null
year_3/databases_sem1/lab2/rdmslab2/api/dbmodels/payrolls.py
honchardev/KPI
f8425681857c02a67127ffb05c0af0563a8473e1
[ "MIT" ]
21
2020-03-24T16:26:04.000Z
2022-02-18T15:56:16.000Z
year_3/databases_sem1/lab2/rdmslab2/api/dbmodels/payrolls.py
honchardev/KPI
f8425681857c02a67127ffb05c0af0563a8473e1
[ "MIT" ]
null
null
null
from api.models import Payroll class Payrolls(object): def __init__(self, cursor): """ :param cursor: MySQLdb.cursor.Cursor """ self.cursor = cursor cursor.execute('SET NAMES utf8;') cursor.execute('SET CHARACTER SET utf8;') cursor.execute('SET character_set...
23.888889
61
0.477519
63f0dcedfc927c0b523f3a53c332513bb2498eb2
8,977
py
Python
lib/util/ImageProcessing/homopgrahy.py
Thukor/MazeSolver
c953e193ce27a7348e8ec9c5592144426dfce193
[ "MIT" ]
5
2018-02-06T22:48:34.000Z
2020-01-07T20:19:05.000Z
lib/util/ImageProcessing/homopgrahy.py
Thukor/MazeSolver
c953e193ce27a7348e8ec9c5592144426dfce193
[ "MIT" ]
11
2018-01-31T21:47:49.000Z
2018-04-21T16:42:52.000Z
lib/util/ImageProcessing/homopgrahy.py
Thukor/MazeSolver
c953e193ce27a7348e8ec9c5592144426dfce193
[ "MIT" ]
2
2020-06-18T05:40:03.000Z
2022-02-02T03:46:30.000Z
import cv2 import numpy as np import imutils from collections import defaultdict # mouse callback function def define_points(target_img): corners = [] refPt = [] def draw_circle(event,x,y,flags,param): global refPt if event == cv2.EVENT_LBUTTONDBLCLK: cv2.circle(param,(x,y),5,(...
33.003676
102
0.614236
c3c622cc0704f66c0ca320f04b393a4ce95e43c7
13,856
py
Python
addition_module/DSDG/DUM/train.py
weihaoxie/FaceX-Zoo
db0b087e4f4d28152e172d6c8d3767a8870733b4
[ "Apache-2.0" ]
1
2022-02-07T02:03:37.000Z
2022-02-07T02:03:37.000Z
addition_module/DSDG/DUM/train.py
weihaoxie/FaceX-Zoo
db0b087e4f4d28152e172d6c8d3767a8870733b4
[ "Apache-2.0" ]
null
null
null
addition_module/DSDG/DUM/train.py
weihaoxie/FaceX-Zoo
db0b087e4f4d28152e172d6c8d3767a8870733b4
[ "Apache-2.0" ]
null
null
null
from __future__ import print_function, division import torch import matplotlib.pyplot as plt import argparse, os import numpy as np from torch.utils.data import DataLoader from torchvision import transforms from models.CDCNs_u import Conv2d_cd, CDCN_u from Load_OULUNPUcrop_train import Spoofing_train_g, Sep...
47.77931
152
0.58444
14007734f5d8729d94671298f144bda00fec3b3f
151
py
Python
src/third_party_module/upload_self_define_module/nester/nester.py
HuangHuaBingZiGe/GitHub-Demo
f3710f73b0828ef500343932d46c61d3b1e04ba9
[ "Apache-2.0" ]
null
null
null
src/third_party_module/upload_self_define_module/nester/nester.py
HuangHuaBingZiGe/GitHub-Demo
f3710f73b0828ef500343932d46c61d3b1e04ba9
[ "Apache-2.0" ]
null
null
null
src/third_party_module/upload_self_define_module/nester/nester.py
HuangHuaBingZiGe/GitHub-Demo
f3710f73b0828ef500343932d46c61d3b1e04ba9
[ "Apache-2.0" ]
null
null
null
def print_lol(arr): for row in arr: if (isinstance(row, list)): print_lol(row) else: print row
18.875
35
0.456954
d311f594d2a844e6d5e6617c53d3b5bdd083d897
2,665
py
Python
spotify_gender_ex/downloader.py
Theta-Dev/Spotify-Gender-Ex
4e5360f115cb3302397b8e1ad1b11ad96b887ad2
[ "MIT" ]
1
2022-02-05T16:40:13.000Z
2022-02-05T16:40:13.000Z
spotify_gender_ex/downloader.py
Theta-Dev/Spotify-Gender-Ex
4e5360f115cb3302397b8e1ad1b11ad96b887ad2
[ "MIT" ]
31
2021-06-17T11:59:33.000Z
2022-03-19T07:05:18.000Z
spotify_gender_ex/downloader.py
Theta-Dev/Spotify-Gender-Ex
4e5360f115cb3302397b8e1ad1b11ad96b887ad2
[ "MIT" ]
null
null
null
import os import re import urllib.request import click import requests from tqdm import tqdm URL_UPTODOWN = 'https://spotify.de.uptodown.com/android/download' URL_GHAPI = 'https://api.github.com/repos/Theta-Dev/Spotify-Gender-Ex/commits/master' URL_RTABLE = 'https://raw.githubusercontent.com/Theta-Dev/Spotify-Gender-...
31.72619
119
0.630394
d318c848b55117fd7c66c4af724183f8868ea105
436
py
Python
src/data_science/data_science/tools/time.py
viclule/api_models_deployment_framework
7595cf0b4f3e277925b968014102d7561547bcd4
[ "MIT" ]
null
null
null
src/data_science/data_science/tools/time.py
viclule/api_models_deployment_framework
7595cf0b4f3e277925b968014102d7561547bcd4
[ "MIT" ]
null
null
null
src/data_science/data_science/tools/time.py
viclule/api_models_deployment_framework
7595cf0b4f3e277925b968014102d7561547bcd4
[ "MIT" ]
null
null
null
from datetime import datetime, timezone def get_timestamp_isoformat(): """ Generate a timestampt in iso format. """ dt = datetime.utcnow().replace(microsecond=0).isoformat("T") + "Z" return dt def get_timestamp_unix(): """ Generate a timestampt in unix format. ########.### """ ...
21.8
70
0.637615
d35ae302dc71c9bbf5223948369169ce172e3f51
5,310
py
Python
utils/rtutil.py
RT-Team/RT-Lib
686c3632f4283c56b5983d2ddc20bd94f7ef2ba4
[ "MIT" ]
null
null
null
utils/rtutil.py
RT-Team/RT-Lib
686c3632f4283c56b5983d2ddc20bd94f7ef2ba4
[ "MIT" ]
null
null
null
utils/rtutil.py
RT-Team/RT-Lib
686c3632f4283c56b5983d2ddc20bd94f7ef2ba4
[ "MIT" ]
null
null
null
# RT Ext - Useful Util # 注意:普通のエクステンションとは違います。 import asyncio from json import dumps from time import time import discord from aiofile import async_open from discord.ext import commands, tasks class RtUtil(commands.Cog): def __init__(self, bot): self.bot = bot self.data = { "list_emb...
30.170455
79
0.56403
6cffbd65c3259cdce6bb8d63fcc07acc7911f4c6
5,733
py
Python
21-fs-ias-lec/13-RaptorCode/src/decoder.py
Kyrus1999/BACnet
5be8e1377252166041bcd0b066cce5b92b077d06
[ "MIT" ]
8
2020-03-17T21:12:18.000Z
2021-12-12T15:55:54.000Z
21-fs-ias-lec/13-RaptorCode/src/decoder.py
Kyrus1999/BACnet
5be8e1377252166041bcd0b066cce5b92b077d06
[ "MIT" ]
2
2021-07-19T06:18:43.000Z
2022-02-10T12:17:58.000Z
21-fs-ias-lec/13-RaptorCode/src/decoder.py
Kyrus1999/BACnet
5be8e1377252166041bcd0b066cce5b92b077d06
[ "MIT" ]
25
2020-03-20T09:32:45.000Z
2021-07-18T18:12:59.000Z
import numpy as np import utils from utils import NUMBER_OF_ENCODED_BITS, VECTORLENGTH, Z, TransmissionPackage class Decoder: def __init__(self): self._inputData = [] # [(informationID, [[(a, y)]] )] <-- Format, place in second Array is chunkID self._decodedData = [] # [(informationID, [decoded...
36.056604
120
0.568114
9f2096e503b1764311d574ee845445b547da7b73
453
py
Python
Django/ballon/admin.py
ballon3/GRAD
c630e32272fe34ead590c04d8360169e02be87f1
[ "MIT" ]
null
null
null
Django/ballon/admin.py
ballon3/GRAD
c630e32272fe34ead590c04d8360169e02be87f1
[ "MIT" ]
null
null
null
Django/ballon/admin.py
ballon3/GRAD
c630e32272fe34ead590c04d8360169e02be87f1
[ "MIT" ]
null
null
null
from django.contrib import admin from ballon.models import Pkg, Resume, Main, Education, Project, Work, Skill, Testimonial, Social, Address #admin.site.register(Category) admin.site.register(Resume) admin.site.register(Main) admin.site.register(Education) admin.site.register(Work) admin.site.register(Project) admin.si...
32.357143
106
0.81457
4cf469984a513806e0e1e0c8ae654d64324c3888
990
py
Python
euler-50.py
TFabijo/euler2
7da205ce02ae3bd12754f99c1fe69fbf20b1e3d0
[ "MIT" ]
null
null
null
euler-50.py
TFabijo/euler2
7da205ce02ae3bd12754f99c1fe69fbf20b1e3d0
[ "MIT" ]
null
null
null
euler-50.py
TFabijo/euler2
7da205ce02ae3bd12754f99c1fe69fbf20b1e3d0
[ "MIT" ]
null
null
null
def prastevila_do_n(n): pra = [2,3,5,7] for x in range(8,n+1): d = True for y in range(2,int(x ** 0.5) + 1): if d == False: break elif x % y == 0: d = False if d == True: pra.append(x) return pra def ...
26.052632
66
0.493939
646e3f798705f6b0c67f2b3094fafcabdb531a9a
2,283
py
Python
frappe-bench/apps/erpnext/erpnext/education/report/student_batch_wise_attendance/student_batch_wise_attendance.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/education/report/student_batch_wise_attendance/student_batch_wise_attendance.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/education/report/student_batch_wise_attendance/student_batch_wise_attendance.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
# Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors # License: GNU General Public License v3. See license.txt from __future__ import unicode_literals import frappe from frappe.utils import cstr, cint, getdate from frappe import msgprint, _ def execute(filters=None): if not filters: filters = {} if...
35.671875
109
0.750329
b3985f565a3b58ad025d4c71f174f2a90abe2aa7
12,172
py
Python
tests/test_main_window.py
Ceystyle/easyp2p
99c32e3ec0ff5a34733f157dd1b53d1aa9bc9edc
[ "MIT" ]
4
2019-07-18T10:58:28.000Z
2021-11-18T16:57:45.000Z
tests/test_main_window.py
Ceystyle/easyp2p
99c32e3ec0ff5a34733f157dd1b53d1aa9bc9edc
[ "MIT" ]
1
2019-07-05T09:21:47.000Z
2019-07-05T09:21:47.000Z
tests/test_main_window.py
Ceystyle/easyp2p
99c32e3ec0ff5a34733f157dd1b53d1aa9bc9edc
[ "MIT" ]
2
2019-07-05T08:56:34.000Z
2020-06-09T10:03:42.000Z
# -*- coding: utf-8 -*- # Copyright (c) 2018-2020 Niko Sandschneider """Module containing all tests for the main window of easyp2p.""" from datetime import date, timedelta import os import sys import unittest.mock from PyQt5.QtCore import QLocale from PyQt5.QtWidgets import QApplication, QCheckBox, QLineEdit impor...
41.684932
80
0.669898
b31a614e9fdad950b6103bf4c802c1acbca2334e
1,122
py
Python
Packs/ShiftLeft/Integrations/shiftleft/shiftleft_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/ShiftLeft/Integrations/shiftleft/shiftleft_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/ShiftLeft/Integrations/shiftleft/shiftleft_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
"""Base Integration for ShiftLeft CORE - Cortex XSOAR Extension """ import json import io from shiftleft import list_app_findings_command, ShiftLeftClient def util_load_json(path): with io.open(path, mode="r", encoding="utf-8") as f: return json.loads(f.read()) def test_list_app_findings_command(reques...
28.769231
114
0.682709
b336dfd4f06633eb05d75f4fdb5a06c0dcb65ff7
1,590
py
Python
python_experiments/paper_figures/tkde/data_legacy/eval_varying_eps_c_pcg.py
RapidsAtHKUST/SimRank
3a601b08f9a3c281e2b36b914e06aba3a3a36118
[ "MIT" ]
8
2020-04-14T23:17:00.000Z
2021-06-21T12:34:04.000Z
python_experiments/paper_figures/tkde/data_legacy/eval_varying_eps_c_pcg.py
RapidsAtHKUST/SimRank
3a601b08f9a3c281e2b36b914e06aba3a3a36118
[ "MIT" ]
null
null
null
python_experiments/paper_figures/tkde/data_legacy/eval_varying_eps_c_pcg.py
RapidsAtHKUST/SimRank
3a601b08f9a3c281e2b36b914e06aba3a3a36118
[ "MIT" ]
1
2021-01-17T16:26:50.000Z
2021-01-17T16:26:50.000Z
import json if __name__ == '__main__': with open('varying_eps_c.dicts') as ifs: pcg_varying_eps_cpu = eval(ifs.readline()) pcg_varying_eps_mem = eval(ifs.readline()) pcg_varying_c_cpu = eval(ifs.readline()) pcg_varying_c_mem = eval(ifs.readline()) pcg_tag = 'pcg' ...
27.894737
58
0.445283
b3539ffc66bede449c55231a9b0e75f5780ee2ee
128
py
Python
434-number-of-segments-in-a-string/434-number-of-segments-in-a-string.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
2
2021-12-05T14:29:06.000Z
2022-01-01T05:46:13.000Z
434-number-of-segments-in-a-string/434-number-of-segments-in-a-string.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
null
null
null
434-number-of-segments-in-a-string/434-number-of-segments-in-a-string.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
null
null
null
class Solution: def countSegments(self, s: str) -> int: return sum([1 for letter in s.strip().split(" ") if letter])
42.666667
68
0.625
446236fdcdb79bd05ce93e13267607c7ab6079e6
752
py
Python
leetcode/039-Combination-Sum/CombinationSum_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2017-05-18T06:11:02.000Z
2017-05-18T06:11:02.000Z
leetcode/039-Combination-Sum/CombinationSum_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-02-09T06:00:07.000Z
2016-02-09T07:20:13.000Z
leetcode/039-Combination-Sum/CombinationSum_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
2
2019-06-27T09:07:26.000Z
2019-07-01T04:40:13.000Z
class Solution: # @param {integer[]} candidates # @param {integer} target # @return {integer[][]} def combinationSum(self, candidates, target): candidates.sort() return self.combsum(candidates, target) def combsum(self, nums, target): if target == 0: return [[]] ...
27.851852
54
0.458777
928bbe7491fdbc0a0f928ea52f2ec3bc8d5bb842
323
py
Python
python/python.py
TimVan1596/ACM-ICPC
07f7d728db1ecd09c5a3d0f05521930b14eb9883
[ "Apache-2.0" ]
1
2019-05-22T07:12:34.000Z
2019-05-22T07:12:34.000Z
python/python.py
TimVan1596/ACM-ICPC
07f7d728db1ecd09c5a3d0f05521930b14eb9883
[ "Apache-2.0" ]
3
2021-12-10T01:13:54.000Z
2021-12-14T21:18:42.000Z
python/python.py
TimVan1596/ACM-ICPC
07f7d728db1ecd09c5a3d0f05521930b14eb9883
[ "Apache-2.0" ]
null
null
null
import xlwt if __name__ == '__main__': workbook = xlwt.Workbook(encoding='utf-8') # 创建workbook 对象 worksheet = workbook.add_sheet('sheet1') # 创建工作表sheet # 往表中写内容,第一各参数 行,第二个参数列,第三个参数内容 worksheet.write(0, 0, 'hello world') worksheet.write(0, 1, '你好') workbook.save('first.xls') # 保存表为students.x...
32.3
63
0.674923
5bc0cb9ffa299ad9d23aa50d9179c1903fd178ee
811
py
Python
PSA/modules/BroEventDispatcher.py
SECURED-FP7/secured-psa-nsm
20c8f790ebc2d2aa8c33bda1e047f8f29275a0be
[ "Apache-2.0" ]
null
null
null
PSA/modules/BroEventDispatcher.py
SECURED-FP7/secured-psa-nsm
20c8f790ebc2d2aa8c33bda1e047f8f29275a0be
[ "Apache-2.0" ]
null
null
null
PSA/modules/BroEventDispatcher.py
SECURED-FP7/secured-psa-nsm
20c8f790ebc2d2aa8c33bda1e047f8f29275a0be
[ "Apache-2.0" ]
null
null
null
# -*- Mode:Python;indent-tabs-mode:nil; -*- # # BroEventDispatcher.py # # A simple event dispatcher. # # Author: jju / VTT Technical Research Centre of Finland Ltd., 2016 # import logging callbacks = { } def init(): pass def register( key, obj ): """ Register a callback for key 'key' """ global ...
19.309524
76
0.588163
753fe1a1faf722bc2fb2591309f0654b5a03e396
3,615
py
Python
data_preprocessing/preprocessing_text.py
florianfricke/Bachelor_Thesis_Sentiment_Analyse
aa1fa95cfbc13115ee60baaf79eab0d1940998ab
[ "MIT" ]
1
2020-06-04T13:20:45.000Z
2020-06-04T13:20:45.000Z
data_preprocessing/preprocessing_text.py
florianfricke/Bachelor_Thesis_Sentiment_Analyse
aa1fa95cfbc13115ee60baaf79eab0d1940998ab
[ "MIT" ]
6
2020-06-03T18:45:11.000Z
2022-02-10T01:51:03.000Z
data_preprocessing/preprocessing_text.py
florianfricke/Bachelor_Thesis_Sentiment_Analyse
aa1fa95cfbc13115ee60baaf79eab0d1940998ab
[ "MIT" ]
null
null
null
""" Created by Florian Fricke. """ from ekphrasis.classes.preprocessor import TextPreProcessor from ekphrasis.classes.tokenizer import SocialTokenizer from ekphrasis.dicts.emoticons import emoticons from textblob_de.lemmatizers import PatternParserLemmatizer from tqdm import tqdm from nltk.corpus import stopwords from...
40.166667
116
0.569018
3436f635d8613460ab87260b18e59734a16de86f
826
py
Python
Algorithms/5_Searching/11.py
abphilip-codes/Hackerrank_DSA
bb9e233d9d45c5b14c138830602695ad4113fba4
[ "MIT" ]
1
2021-11-25T13:39:30.000Z
2021-11-25T13:39:30.000Z
Algorithms/5_Searching/11.py
abphilip-codes/Hackerrank_DSA
bb9e233d9d45c5b14c138830602695ad4113fba4
[ "MIT" ]
null
null
null
Algorithms/5_Searching/11.py
abphilip-codes/Hackerrank_DSA
bb9e233d9d45c5b14c138830602695ad4113fba4
[ "MIT" ]
null
null
null
# https://www.hackerrank.com/challenges/short-palindrome/problem #!/bin/python3 import math import os import random import re import sys # # Complete the 'shortPalindrome' function below. # # The function is expected to return an INTEGER. # The function accepts STRING s as parameter. # def shortPalindrome(s): a...
18.355556
64
0.531477
cad795ae9dd6135d51053b4f8de0331e4efd6df4
422
py
Python
prices/admin.py
KazuruK/FilmGetter
fd84bcaddf17d4b89ad6e5d27095535346c5f4a9
[ "BSD-3-Clause" ]
1
2021-06-23T13:06:11.000Z
2021-06-23T13:06:11.000Z
prices/admin.py
KazuruK/FilmGetter
fd84bcaddf17d4b89ad6e5d27095535346c5f4a9
[ "BSD-3-Clause" ]
1
2021-06-23T21:21:52.000Z
2021-06-23T21:21:52.000Z
prices/admin.py
KazuruK/FilmGetter
fd84bcaddf17d4b89ad6e5d27095535346c5f4a9
[ "BSD-3-Clause" ]
1
2021-06-28T19:14:19.000Z
2021-06-28T19:14:19.000Z
from django.contrib import admin # Register your models here. from prices.models import IdDB class IdDBAdmin(admin.ModelAdmin): list_display = ( 'kinopoisk_id', 'title', 'title_en', 'year', 'date_created', 'price',) search_fields = ('kinopoisk_id', 'title',) ...
19.181818
46
0.620853
1b4e40b3667a2b8543c968bbe653fc8de682b7a8
99
py
Python
packages/watchmen-pipeline-surface/src/watchmen_pipeline_surface/connectors/__init__.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-pipeline-surface/src/watchmen_pipeline_surface/connectors/__init__.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-pipeline-surface/src/watchmen_pipeline_surface/connectors/__init__.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
from .kafka import init_kafka, KafkaSettings from .rabbitmq import init_rabbitmq, RabbitmqSettings
33
53
0.858586
1ba5d06c5362ae2cf5a563053ad286ea87461d19
632
py
Python
frappe-bench/apps/erpnext/erpnext/buying/doctype/supplier_scorecard_standing/supplier_scorecard_standing.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/buying/doctype/supplier_scorecard_standing/supplier_scorecard_standing.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/buying/doctype/supplier_scorecard_standing/supplier_scorecard_standing.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
1
2021-04-29T14:39:01.000Z
2021-04-29T14:39:01.000Z
# -*- coding: utf-8 -*- # Copyright (c) 2017, Frappe Technologies Pvt. Ltd. and contributors # For license information, please see license.txt from __future__ import unicode_literals import frappe from frappe.model.document import Document class SupplierScorecardStanding(Document): pass @frappe.whitelist() def get...
21.793103
72
0.761076
941da2ff708ac753a5e6740d5eb4d1133bc1a2b2
120
py
Python
python/coursera_python/WESLEYAN/week1/1.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
16
2018-11-26T08:39:42.000Z
2019-05-08T10:09:52.000Z
python/coursera_python/WESLEYAN/week1/1.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
8
2020-05-04T06:29:26.000Z
2022-02-12T05:33:16.000Z
python/coursera_python/WESLEYAN/week1/1.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
5
2020-02-11T16:02:21.000Z
2021-02-05T07:48:30.000Z
def problem1_1(): print("Problem Set 1") pass # replace this pass (a do-nothing) statement with your code
20
68
0.658333
94228f07bd58a62807a2239f88f4d780e3989c40
5,892
py
Python
research/cv/StackedHourglass/src/dataset/DatasetGenerator.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
1
2021-11-18T08:17:44.000Z
2021-11-18T08:17:44.000Z
research/cv/StackedHourglass/src/dataset/DatasetGenerator.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
null
null
null
research/cv/StackedHourglass/src/dataset/DatasetGenerator.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
2
2019-09-01T06:17:04.000Z
2019-10-04T08:39:45.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...
36.37037
110
0.54888
ca1b5eb38de0a406ce502a3a1fd87938d360c350
3,498
py
Python
python/en/_numpy/python_numpy_tutorial/python_numpy_tutorial-python-containers_dictionary.py
aimldl/coding
70ddbfaa454ab92fd072ee8dc614ecc330b34a70
[ "MIT" ]
null
null
null
python/en/_numpy/python_numpy_tutorial/python_numpy_tutorial-python-containers_dictionary.py
aimldl/coding
70ddbfaa454ab92fd072ee8dc614ecc330b34a70
[ "MIT" ]
null
null
null
python/en/_numpy/python_numpy_tutorial/python_numpy_tutorial-python-containers_dictionary.py
aimldl/coding
70ddbfaa454ab92fd072ee8dc614ecc330b34a70
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ CS231n Convolutional Neural Networks for Visual Recognition http://cs231n.github.io/ Python Numpy Tutorial http://cs231n.github.io/python-numpy-tutorial/  ̄ python_numpy_tutorial-python-containers_dictionary.py 2019-07-03 (Wed) """ # Python Numpy Tutorial > Python > C...
26.70229
81
0.636078
b6209c445497bea1ab0c7570c19a91057e31a667
1,111
py
Python
Webpage/arbeitsstunden/migrations/0015_auto_20210718_1006.py
ASV-Aachen/Website
bbfc02d71dde67fdf89a4b819b795a73435da7cf
[ "Apache-2.0" ]
null
null
null
Webpage/arbeitsstunden/migrations/0015_auto_20210718_1006.py
ASV-Aachen/Website
bbfc02d71dde67fdf89a4b819b795a73435da7cf
[ "Apache-2.0" ]
46
2022-01-08T12:03:24.000Z
2022-03-30T08:51:05.000Z
Webpage/arbeitsstunden/migrations/0015_auto_20210718_1006.py
ASV-Aachen/Website
bbfc02d71dde67fdf89a4b819b795a73435da7cf
[ "Apache-2.0" ]
null
null
null
# Generated by Django 3.2.5 on 2021-07-18 10:06 import datetime from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('arbeitsstunden', '0014_auto_20210705_1948'), ] operations = [ migrations.AlterField( ...
30.861111
123
0.616562
b6831c245d2462543eceb355b1183fa96b6f48f9
2,759
py
Python
research/cv/ntsnet/data_prepare.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/cv/ntsnet/data_prepare.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/cv/ntsnet/data_prepare.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...
39.414286
101
0.576658
1531dbe5c427016a8df4fde2687fdccee363670d
428
py
Python
exercises/es/test_01_02_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
2,085
2019-04-17T13:10:40.000Z
2022-03-30T21:51:46.000Z
exercises/es/test_01_02_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
79
2019-04-18T14:42:55.000Z
2022-03-07T08:15:43.000Z
exercises/es/test_01_02_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
361
2019-04-17T13:34:32.000Z
2022-03-28T04:42:45.000Z
def test(): import spacy.tokens import spacy.lang.de assert isinstance( nlp, spacy.lang.de.German ), "El objeto nlp debería ser un instance de la clase de alemán." assert isinstance( doc, spacy.tokens.Doc ), "¿Procesaste el texto con el objeto nlp para crear un doc?" assert ...
30.571429
84
0.658879
17413695b385180e1c213696f5fde142687adead
421
py
Python
ProjectEuler_plus/euler_006.py
byung-u/HackerRank
4c02fefff7002b3af774b99ebf8d40f149f9d163
[ "MIT" ]
null
null
null
ProjectEuler_plus/euler_006.py
byung-u/HackerRank
4c02fefff7002b3af774b99ebf8d40f149f9d163
[ "MIT" ]
null
null
null
ProjectEuler_plus/euler_006.py
byung-u/HackerRank
4c02fefff7002b3af774b99ebf8d40f149f9d163
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import sys t = int(input().strip()) for a0 in range(t): n = int(input().strip()) # http://oeis.org/search?q=1%2C9%2C36%2C100%2C225&language=english&go=Search square_of_sum = (n ** 2 * (n + 1) ** 2) / 4 # http://oeis.org/search?q=1%2C5%2C14%2C30%2C55&sort=&language=english&go=Sea...
32.384615
84
0.612827
179d33a7638989f862bfe9250df35939c210d7ff
3,469
py
Python
scripts/component_graph/server/__main__.py
opensource-assist/fuschia
66646c55b3d0b36aae90a4b6706b87f1a6261935
[ "BSD-3-Clause" ]
3
2020-08-02T04:46:18.000Z
2020-08-07T10:10:53.000Z
scripts/component_graph/server/__main__.py
opensource-assist/fuschia
66646c55b3d0b36aae90a4b6706b87f1a6261935
[ "BSD-3-Clause" ]
null
null
null
scripts/component_graph/server/__main__.py
opensource-assist/fuschia
66646c55b3d0b36aae90a4b6706b87f1a6261935
[ "BSD-3-Clause" ]
1
2020-08-07T10:11:49.000Z
2020-08-07T10:11:49.000Z
#!/usr/bin/env python3 # Copyright 2019 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. """Entry point to start the server. Main will launch a root handler on port 8080 by default and start serving static files and api requ...
36.135417
121
0.65898
bd66aa54eb82c259a3905c51ba14621d46ff0be5
677
py
Python
frappe-bench/apps/erpnext/erpnext/accounts/doctype/purchase_taxes_and_charges_template/purchase_taxes_and_charges_template.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/accounts/doctype/purchase_taxes_and_charges_template/purchase_taxes_and_charges_template.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/accounts/doctype/purchase_taxes_and_charges_template/purchase_taxes_and_charges_template.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors # License: GNU General Public License v3. See license.txt from __future__ import unicode_literals import frappe from frappe.model.document import Document from erpnext.accounts.doctype.sales_taxes_and_charges_template.sales_ta...
35.631579
97
0.788774
e5d790bbdecf4b746b4b89c4021dcb6f8756d53d
269
py
Python
tests/test_router.py
Slanman3755/VERAS
07a6b26f9360e7bc605b767489cc86c683b57fae
[ "MIT" ]
null
null
null
tests/test_router.py
Slanman3755/VERAS
07a6b26f9360e7bc605b767489cc86c683b57fae
[ "MIT" ]
null
null
null
tests/test_router.py
Slanman3755/VERAS
07a6b26f9360e7bc605b767489cc86c683b57fae
[ "MIT" ]
null
null
null
import pytest from veras import router @pytest.mark.parametrize("origin, destination, expected", [ ("KLAX", "KSFO", "SUMMR2 STOKD SERFR SERFR4"), ]) def test_find_route(origin, destination, expected): assert router.find_route(origin, destination) == expected
26.9
61
0.739777
0072ca442e737b8e11066610d1ed02add4b4a830
920
py
Python
pocketthrone/managers/eventmanager.py
herrschr/pocket-throne
819ebae250f45b0a4b15a8320e2836c0b5113528
[ "BSD-2-Clause" ]
4
2016-06-05T16:48:04.000Z
2020-03-23T20:06:06.000Z
pocketthrone/managers/eventmanager.py
herrschr/pocket-throne
819ebae250f45b0a4b15a8320e2836c0b5113528
[ "BSD-2-Clause" ]
null
null
null
pocketthrone/managers/eventmanager.py
herrschr/pocket-throne
819ebae250f45b0a4b15a8320e2836c0b5113528
[ "BSD-2-Clause" ]
null
null
null
from pocketthrone.entities.event import * from weakref import WeakKeyDictionary class EventManager: _tag = "[EventManager] " listeners = WeakKeyDictionary() eventQueue= [] @classmethod def register(self, listener, tag="untagged"): '''registers an object for receiving game events''' self.listeners[listener] =...
31.724138
85
0.727174
da9a059c634fcea4a96216e4d1ee920ceb4dd1fd
1,581
py
Python
INBa/2015/SOSNOVY_M_S/task_9_26.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
INBa/2015/SOSNOVY_M_S/task_9_26.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
INBa/2015/SOSNOVY_M_S/task_9_26.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
# Задание 9. Вариант 26 # Создайте игру, в которой компьютер выбирает какое-либо слово, а игрок должен его отгадать. Компьютер сообщает игроку, сколько букв в слове, и дает пять попыток узнать, есть ли какая-либо буква в слове, причем программа может отвечать только "Да" и "Нет". Вслед за тем игрок должен попробовать о...
32.265306
310
0.726755
97ac51c2848f660af486a16579c5dc13497a5b73
160
py
Python
main.py
vehne/Maiwagen
fb385d840fee298d073ab07306277ed3d3c5fea8
[ "MIT" ]
null
null
null
main.py
vehne/Maiwagen
fb385d840fee298d073ab07306277ed3d3c5fea8
[ "MIT" ]
null
null
null
main.py
vehne/Maiwagen
fb385d840fee298d073ab07306277ed3d3c5fea8
[ "MIT" ]
null
null
null
import kivy kivy.require('1.10.0') # Aktuell verwendete Kivy Version from kivy.app import App meineAnwendung=App() print(meineAnwendung) meineAnwendung.run()
20
57
0.7875
c15a5e8403813ad9bc2916dbdbb786b43c935f5d
2,110
py
Python
src/onegov/town6/views/files.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/town6/views/files.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/town6/views/files.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from onegov.core.security import Private, Public from onegov.file import File from onegov.org.views.files import view_file_details, \ view_get_image_collection, view_upload_general_file, \ view_upload_image_file, view_file_digest, handle_sign,\ view_get_file_collection from onegov.town6 import TownApp from...
35.762712
78
0.770142
c1d8f07a8b9b9aaca2cbd2db6ceafab45b5fe90e
9,018
py
Python
web/controllers/food/Food.py
yao6891/FlaskOrdering
cbd24bd8d95afaba91ce4d6b1b3548c4e82e3807
[ "Apache-2.0" ]
1
2020-03-24T04:26:34.000Z
2020-03-24T04:26:34.000Z
web/controllers/food/Food.py
yao6891/FlaskOrdering
cbd24bd8d95afaba91ce4d6b1b3548c4e82e3807
[ "Apache-2.0" ]
null
null
null
web/controllers/food/Food.py
yao6891/FlaskOrdering
cbd24bd8d95afaba91ce4d6b1b3548c4e82e3807
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- from flask import Blueprint,request,jsonify,redirect from common.libs.Helper import ops_render,get_current_date,i_pagination,get_dict_filter_field from application import app,db from common.models.food.Food import Food from common.models.food.FoodCat import FoodCat from common.models.food.FoodS...
30.989691
114
0.594478
a9b1e5f530f1eb2e2c4155ee70c812905ec0376e
212
py
Python
Python/Courses/Python-Tutorials.Zulkarnine-Mahmud/00.Fundamentals/02.01-Complicated-Logic.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
Python/Courses/Python-Tutorials.Zulkarnine-Mahmud/00.Fundamentals/02.01-Complicated-Logic.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
Python/Courses/Python-Tutorials.Zulkarnine-Mahmud/00.Fundamentals/02.01-Complicated-Logic.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
def complicated_logic(first, second): print(f"You passed: {first}, {second}") # return first + second * 12 - 4 * 12 number1 = 10 number2 = 3 result = complicated_logic(number1, number2) print(result)
17.666667
44
0.679245
4142a722bde1ddff3f4dd78cd7f726007fba6f52
11,145
py
Python
IdeaProjects/matplotDev/matplotlibDev1.py
sinomiko/project
00fadb0033645f103692f5b06c861939a9d4aa0e
[ "BSD-3-Clause" ]
1
2018-12-30T14:07:42.000Z
2018-12-30T14:07:42.000Z
IdeaProjects/matplotDev/matplotlibDev1.py
sinomiko/project
00fadb0033645f103692f5b06c861939a9d4aa0e
[ "BSD-3-Clause" ]
null
null
null
IdeaProjects/matplotDev/matplotlibDev1.py
sinomiko/project
00fadb0033645f103692f5b06c861939a9d4aa0e
[ "BSD-3-Clause" ]
null
null
null
# encoding: utf-8 import numpy as np import matplotlib as mpl import matplotlib.pyplot as plt #matplotlib inline # 4.1. 一维数据集 # # 在下面的所有例子中,我们将按照存储在 NumPy ndarray 对象中的数据绘制图表。当然,matplotlib 也能够按照以不同的 Python 格式存储的数据(如列表对象)绘制图表。首先,我们需要用于绘制图表的数据。为此,我们生成20个标准正态分布(伪)随机数,保存在一个NumPy ndarray中: np.random.seed(1000) y = np.random....
27.518519
251
0.713863
41b57c0d33d477d09b1dd88ceeff4ea07dbdc75c
3,585
py
Python
tarefas-poo/lista-04/matriz_de_inteiros/model/matriz_de_inteiros.py
victoriaduarte/POO_UFSC
0c65b4f26383d1e3038d8469bd91fd2c0cb98c1a
[ "MIT" ]
null
null
null
tarefas-poo/lista-04/matriz_de_inteiros/model/matriz_de_inteiros.py
victoriaduarte/POO_UFSC
0c65b4f26383d1e3038d8469bd91fd2c0cb98c1a
[ "MIT" ]
null
null
null
tarefas-poo/lista-04/matriz_de_inteiros/model/matriz_de_inteiros.py
victoriaduarte/POO_UFSC
0c65b4f26383d1e3038d8469bd91fd2c0cb98c1a
[ "MIT" ]
null
null
null
# ------------------------------- # UFSC - CTC - INE - INE5663 # Exercício da Matriz de Inteiros # ------------------------------- # Classe que representa uma matriz de números inteiros. # class MatrizDeInteiros: def __init__(self, dimensoes_ou_numeros): '''Cria uma matriz de números inteiros. Há duas form...
33.504673
103
0.590237
6bbda07e389bf551e26624d26ca28aadcfbca0c4
217
py
Python
Curso_Python/Secao2-Python-Basico-Logica-Programacao/37_desempacotamento_listas/37_desempacotamento_listas.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
Curso_Python/Secao2-Python-Basico-Logica-Programacao/37_desempacotamento_listas/37_desempacotamento_listas.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
Curso_Python/Secao2-Python-Basico-Logica-Programacao/37_desempacotamento_listas/37_desempacotamento_listas.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
""" Desempacotamento de listas em python """ lista = ['Luiz', 'João', 'Maria', 1, 2, 3, 4, 5] n1, n2, *n3 = lista #todo: usando a * cria outra lista, e os valores que eu quiser mostrar, começa pelas ultimas print(n3)
31
112
0.663594
d882505a2c97d476d34d048ae6b4d15d1f7b44c1
4,623
py
Python
haas_lib_bundles/python/docs/examples/smart_panel/esp32/code/environment.py
wstong999/AliOS-Things
6554769cb5b797e28a30a4aa89b3f4cb2ef2f5d9
[ "Apache-2.0" ]
null
null
null
haas_lib_bundles/python/docs/examples/smart_panel/esp32/code/environment.py
wstong999/AliOS-Things
6554769cb5b797e28a30a4aa89b3f4cb2ef2f5d9
[ "Apache-2.0" ]
null
null
null
haas_lib_bundles/python/docs/examples/smart_panel/esp32/code/environment.py
wstong999/AliOS-Things
6554769cb5b797e28a30a4aa89b3f4cb2ef2f5d9
[ "Apache-2.0" ]
null
null
null
import lvgl as lv import utime # RESOURCES_ROOT = "S:/Users/liujuncheng/workspace/iot/esp32/solution/HaaSPython/solutions/smart_panel/" RESOURCES_ROOT = "S:/data/pyamp/" def drawOver(e): global g_clickTime if (g_clickTime != 0): currentTime = utime.ticks_ms() print("create Environment page us...
37.282258
110
0.669046
2b053c0e6b71e75465a34afd8fb4265916c8513c
1,023
py
Python
Kryptografie/Python/caesar.py
jneug/schule-projekte
4f1d56d6bb74a47ca019cf96d2d6cc89779803c9
[ "MIT" ]
2
2020-09-24T12:11:16.000Z
2022-03-31T04:47:24.000Z
Kryptografie/Python/caesar.py
jneug/schule-projekte
4f1d56d6bb74a47ca019cf96d2d6cc89779803c9
[ "MIT" ]
1
2021-02-27T15:06:27.000Z
2021-03-01T16:32:48.000Z
Kryptografie/Python/caesar.py
jneug/schule-projekte
4f1d56d6bb74a47ca019cf96d2d6cc89779803c9
[ "MIT" ]
1
2021-02-24T05:12:35.000Z
2021-02-24T05:12:35.000Z
def ceasear_encode( msg, key ): code = "" key = ord(key.upper())-ord("A") for c in msg.upper(): if c in "ABCDEFGHIJKLMNOPQRSTUVWXYZ": new_ord = ord(c)+key if new_ord > ord("Z"): new_ord -= 26 code += chr(new_ord) else: code +=...
24.95122
61
0.560117
2b3a2886cced8166d79a209e36b74c73cb5dec34
14,328
py
Python
Contrib-Inspur/openbmc/poky/bitbake/lib/toaster/tests/functional/test_functional_basic.py
opencomputeproject/Rack-Manager
e1a61d3eeeba0ff655fe9c1301e8b510d9b2122a
[ "MIT" ]
5
2019-11-11T07:57:26.000Z
2022-03-28T08:26:53.000Z
Contrib-Inspur/openbmc/poky/bitbake/lib/toaster/tests/functional/test_functional_basic.py
opencomputeproject/Rack-Manager
e1a61d3eeeba0ff655fe9c1301e8b510d9b2122a
[ "MIT" ]
3
2019-09-05T21:47:07.000Z
2019-09-17T18:10:45.000Z
Contrib-Inspur/openbmc/poky/bitbake/lib/toaster/tests/functional/test_functional_basic.py
opencomputeproject/Rack-Manager
e1a61d3eeeba0ff655fe9c1301e8b510d9b2122a
[ "MIT" ]
11
2019-07-20T00:16:32.000Z
2022-01-11T14:17:48.000Z
#! /usr/bin/env python # # BitBake Toaster functional tests implementation # # Copyright (C) 2017 Intel Corporation # # SPDX-License-Identifier: GPL-2.0-only # import time import re from tests.functional.functional_helpers import SeleniumFunctionalTestCase from orm.models import Project class FuntionalTestBasic(Selen...
61.758621
268
0.661991
2b40be95f80d31455cf6a2e3a51eb14f7aeb92a8
3,288
py
Python
src/Themes/TransformationTheme.py
LukasTinnes/VenturePainter
cb1f24fda2a43d402a9c5a401d713af0c950270b
[ "Unlicense" ]
1
2020-05-29T21:09:33.000Z
2020-05-29T21:09:33.000Z
src/Themes/TransformationTheme.py
LukasTinnes/VenturePainter
cb1f24fda2a43d402a9c5a401d713af0c950270b
[ "Unlicense" ]
3
2020-06-14T11:33:54.000Z
2022-01-13T03:31:06.000Z
src/Themes/TransformationTheme.py
LukasTinnes/VenturePainter
cb1f24fda2a43d402a9c5a401d713af0c950270b
[ "Unlicense" ]
null
null
null
from .Theme import Theme from src.Graph import Graph class TransformationTheme(Theme): def __init__(self): super().__init__() self.size_max = 0 self.size_min = 0 self.width_min = 0 self.width_max = 0 self.height_min = 0 self.height_max = 0 self.x...
36.94382
119
0.612226
99513706c29cd040b8e1f9c0d65abac5eadeb33f
491
py
Python
Problems/Dynamic Programming/Easy/BuySellStock1/buy_sell_stock_1.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
1
2021-08-16T14:52:05.000Z
2021-08-16T14:52:05.000Z
Problems/Dynamic Programming/Easy/BuySellStock1/buy_sell_stock_1.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
Problems/Dynamic Programming/Easy/BuySellStock1/buy_sell_stock_1.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
from typing import List def max_profit_1(prices: List[int]) -> int: min_price, max_profit = prices[0], 0 for price in prices: min_price = min(min_price, price) profit = price - min_price max_profit = max(max_profit, profit) return max_profit def max_profit_2(prices: List[int]) -> ...
27.277778
44
0.590631
9956e73164bd63500cea24e33dc9bcf6d9f73e4e
4,311
py
Python
scp.py
KvantPro/SCP
1304d03007992f223d319d41037e2b32c9fbf934
[ "Unlicense" ]
1
2021-11-12T19:28:16.000Z
2021-11-12T19:28:16.000Z
scp.py
KvantPro/SCP
1304d03007992f223d319d41037e2b32c9fbf934
[ "Unlicense" ]
null
null
null
scp.py
KvantPro/SCP
1304d03007992f223d319d41037e2b32c9fbf934
[ "Unlicense" ]
null
null
null
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'SCP.ui' # # Created by: PyQt5 UI code generator 5.15.2 # # WARNING: Any manual changes made to this file will be lost when pyuic5 is # run again. Do not edit this file unless you know what you are doing. from PyQt5 import QtCore...
31.23913
189
0.566922
512b0ff03116ecbbfa2490a86b31c8bef5a16fbc
2,630
py
Python
test/test_npu/test_ones_like.py
Ascend/pytorch
39849cf72dafe8d2fb68bd1679d8fd54ad60fcfc
[ "BSD-3-Clause" ]
1
2021-12-02T03:07:35.000Z
2021-12-02T03:07:35.000Z
test/test_npu/test_ones_like.py
Ascend/pytorch
39849cf72dafe8d2fb68bd1679d8fd54ad60fcfc
[ "BSD-3-Clause" ]
1
2021-11-12T07:23:03.000Z
2021-11-12T08:28:13.000Z
test/test_npu/test_ones_like.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...
32.469136
74
0.6
51482ecdf63ce79d790ef49cc3ab5fbfd053a0f3
9,861
py
Python
tests/test_aufabschlagregional.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
1
2022-03-02T12:49:44.000Z
2022-03-02T12:49:44.000Z
tests/test_aufabschlagregional.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
21
2022-02-04T07:38:46.000Z
2022-03-28T14:01:53.000Z
tests/test_aufabschlagregional.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
null
null
null
from datetime import datetime, timezone from decimal import Decimal import pytest # type:ignore[import] from bo4e.com.aufabschlagproort import AufAbschlagProOrt from bo4e.com.aufabschlagregional import AufAbschlagRegional, AufAbschlagRegionalSchema from bo4e.com.aufabschlagstaffelproort import AufAbschlagstaffelProO...
41.961702
108
0.434642
5ca7ea27b9a77f39ea73f7e2f5fb08e16ff975e2
951
py
Python
Python/zzz_training_challenge/Python_Challenge/solutions/tests/ch06_arrays/ex09_sudoku_checker_test.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
Python/zzz_training_challenge/Python_Challenge/solutions/tests/ch06_arrays/ex09_sudoku_checker_test.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
Python/zzz_training_challenge/Python_Challenge/solutions/tests/ch06_arrays/ex09_sudoku_checker_test.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
# Beispielprogramm für das Buch "Python Challenge" # # Copyright 2020 by Michael Inden from ch06_arrays.solutions.ex09_sudoku_checker import is_sudoku_valid def create_initialized_board(): return [[1, 2, 0, 4, 5, 0, 7, 8, 9], [0, 5, 6, 7, 0, 9, 0, 2, 3], [7, 8, 0, 1, 2, 3, 4, 5, 6], ...
25.026316
69
0.55836
7a2beccb20b101469add30621b17d27226afd39b
110
py
Python
Python/Books/Learning-Programming-with-Python.Tamim-Shahriar-Subeen/chapter-007/pg-7.4-local-variable.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
Python/Books/Learning-Programming-with-Python.Tamim-Shahriar-Subeen/chapter-007/pg-7.4-local-variable.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
Python/Books/Learning-Programming-with-Python.Tamim-Shahriar-Subeen/chapter-007/pg-7.4-local-variable.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
def myfnc(x): print("inside myfnc", x) x = 10 print("inside myfnc", x) x = 20 myfnc(x) print(x)
11
28
0.554545
8f08e54ff7cb184ad51af92f4e2cf2b7c71ef4d7
2,561
py
Python
hdg_test/anistropic/cg_test.py
BradHub/SL-SPH
7bc86253277d27cbb04a9b5935fd4fc056266371
[ "MIT" ]
1
2018-02-19T01:52:58.000Z
2018-02-19T01:52:58.000Z
hdg_test/anistropic/cg_test.py
BradHub/SL-SPH
7bc86253277d27cbb04a9b5935fd4fc056266371
[ "MIT" ]
null
null
null
hdg_test/anistropic/cg_test.py
BradHub/SL-SPH
7bc86253277d27cbb04a9b5935fd4fc056266371
[ "MIT" ]
null
null
null
import numpy as np import dolfin from dolfin import * from mpi4py import MPI as pyMPI comm = pyMPI.COMM_WORLD mpi_comm = MPI.comm_world #mark whole boundary, inflow and outflow will overwrite) class Noslip(SubDomain): def inside(self, x, on_boundary): return on_boundary class Left(SubDomain): def ins...
27.537634
126
0.679422
8f487ccac25c1f508943b7e960c4b0049246f6d5
1,483
py
Python
app.py
wbigger/2021-tris
381bea2788be2502b83aa7bc93610567acad0263
[ "MIT" ]
null
null
null
app.py
wbigger/2021-tris
381bea2788be2502b83aa7bc93610567acad0263
[ "MIT" ]
null
null
null
app.py
wbigger/2021-tris
381bea2788be2502b83aa7bc93610567acad0263
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 print("Gioco del tic tac toe") board = [ ['-','-','-'], ['-','-','-'], ['-','-','-'] ] symList = ['X','O'] def mostra_tabellone(): for i in range(3): for j in range(3): print(board[i][j], end=" ") print() def win(board): ...
21.185714
79
0.462576
706720f9584247fe1387ca09ddee93c7af47920a
2,024
py
Python
tead/event.py
JeFaProductions/TextAdventure2
4ae690a1e41f30a564a77015f76346d55466c325
[ "MIT" ]
2
2016-08-28T21:32:39.000Z
2016-09-02T05:56:53.000Z
tead/event.py
JeFaProductions/TextAdventure2
4ae690a1e41f30a564a77015f76346d55466c325
[ "MIT" ]
7
2016-09-01T22:03:13.000Z
2019-06-13T21:38:05.000Z
tead/event.py
JeFaProductions/TextAdventure2
4ae690a1e41f30a564a77015f76346d55466c325
[ "MIT" ]
null
null
null
import queue ROOM_ENTERED = 'roomEntered' class Event: def __init__(self, eventType='', userParam=dict()): self.type = eventType self.userParam = userParam class EventSystem: def __init__(self): self._eventQueue = queue.Queue() self._eventHandlers = dict() def registerE...
30.666667
80
0.651186
d98ba3c2b414703556864f30f4b3118522a3cc86
2,669
py
Python
examples/text_classification/ernie_doc/export_model.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
examples/text_classification/ernie_doc/export_model.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
examples/text_classification/ernie_doc/export_model.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2022 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...
46.824561
135
0.68003
7976f1055e26936d39c3f5a3f96886a541a291aa
2,704
py
Python
udm-bildungslogin/usr/lib/python2.7/dist-packages/univention/udm/modules/bildungslogin_license.py
univention/bildungslogin
29bebe858a5445dd5566aad594b33b9dd716eca4
[ "MIT" ]
null
null
null
udm-bildungslogin/usr/lib/python2.7/dist-packages/univention/udm/modules/bildungslogin_license.py
univention/bildungslogin
29bebe858a5445dd5566aad594b33b9dd716eca4
[ "MIT" ]
null
null
null
udm-bildungslogin/usr/lib/python2.7/dist-packages/univention/udm/modules/bildungslogin_license.py
univention/bildungslogin
29bebe858a5445dd5566aad594b33b9dd716eca4
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # # Copyright 2021 Univention GmbH # # https://www.univention.de/ # # All rights reserved. # # The source code of this program is made available # under the terms of the GNU Affero General Public License version 3 # (GNU AGPL V3) as published by the Free Software Foundation. # # Binary versions ...
32.578313
80
0.75037
30b9b62f9f4a4350440a91a6d9b63e96c38bdc8e
1,241
py
Python
py-td3-cinema/obj.py
HuguesGuilleus/istyPOO
f460665799be2b2f34a1ebaa9878e06bb028a410
[ "BSD-3-Clause" ]
null
null
null
py-td3-cinema/obj.py
HuguesGuilleus/istyPOO
f460665799be2b2f34a1ebaa9878e06bb028a410
[ "BSD-3-Clause" ]
null
null
null
py-td3-cinema/obj.py
HuguesGuilleus/istyPOO
f460665799be2b2f34a1ebaa9878e06bb028a410
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import os from storage.struct import Struct as Struct from storage.db import DB as DB if not os.path.exists("data/"): os.makedirs("data/") # Classes class Guest(Struct): def __init__(self, db): super(Guest, self).__init__({ "*Name": "", "tel": "", "mail": ...
20.016129
54
0.598711
ba94b8d454521a32f19d17bede93c216fb9a272e
148
py
Python
Python/BasicDataTypes/finding_the_percentage.py
rho2/HackerRank
4d9cdfcabeb20212db308d8e4f2ac1b8ebf7d266
[ "MIT" ]
null
null
null
Python/BasicDataTypes/finding_the_percentage.py
rho2/HackerRank
4d9cdfcabeb20212db308d8e4f2ac1b8ebf7d266
[ "MIT" ]
null
null
null
Python/BasicDataTypes/finding_the_percentage.py
rho2/HackerRank
4d9cdfcabeb20212db308d8e4f2ac1b8ebf7d266
[ "MIT" ]
null
null
null
l = {} for _ in range(int(input())): s = input().split() l[s[0]] = sum([float(a) for a in s[1:]])/(len(s)-1) print('%.2f' % l[input()])
24.666667
55
0.466216
30210087e33980eb24daf4d679f8868eeef662a7
294
py
Python
0000 hihoOnce/175 Robots Crossing River/main.py
SLAPaper/hihoCoder
3f64d678c5dd46db36345736eb56880fb2d2c5fe
[ "MIT" ]
null
null
null
0000 hihoOnce/175 Robots Crossing River/main.py
SLAPaper/hihoCoder
3f64d678c5dd46db36345736eb56880fb2d2c5fe
[ "MIT" ]
null
null
null
0000 hihoOnce/175 Robots Crossing River/main.py
SLAPaper/hihoCoder
3f64d678c5dd46db36345736eb56880fb2d2c5fe
[ "MIT" ]
null
null
null
from math import ceil z, y, x = sorted(int(x) for x in raw_input().split()) if x <= y + z: print int(ceil((x + y + z) / 20.0)) * 6 else: run = (y + z) / 10 xr = x - 10 * run nxr = (y + z) % 10 xr -= 15 - nxr if nxr < 8 else nxr print int(run + 1 + ceil(xr / 15.0)) * 6
24.5
53
0.486395
3066a68f25a0b8f12738cd73460642da98c0609a
2,832
py
Python
validproxy-master/proxyon.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-17T03:35:03.000Z
2021-12-08T06:00:31.000Z
validproxy-master/proxyon.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
null
null
null
validproxy-master/proxyon.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-05T18:07:48.000Z
2022-02-24T21:25:07.000Z
import requests import argparse import sys import os import urllib3 import random def user_agent(): useragent = [ "Mozilla/5.0 CK={ } (Windows NT 6.1; WOW64; Trident/7.0; rv:11.0) like Gecko", "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/7...
44.952381
173
0.610876
233ef9c92519a99521c52fd9bc198d3800045e8e
504
py
Python
rev/rev-verybabyrev/solve.py
NoXLaw/RaRCTF2021-Challenges-Public
1a1b094359b88f8ebbc83a6b26d27ffb2602458f
[ "MIT" ]
2
2021-08-09T17:08:12.000Z
2021-08-09T17:08:17.000Z
rev/rev-verybabyrev/solve.py
NoXLaw/RaRCTF2021-Challenges-Public
1a1b094359b88f8ebbc83a6b26d27ffb2602458f
[ "MIT" ]
null
null
null
rev/rev-verybabyrev/solve.py
NoXLaw/RaRCTF2021-Challenges-Public
1a1b094359b88f8ebbc83a6b26d27ffb2602458f
[ "MIT" ]
1
2021-10-09T16:51:56.000Z
2021-10-09T16:51:56.000Z
af = list(b"\x13\x13\x11\x17\x12\x1d\x48\x45\x45\x41\x0b\x26\x2c\x42\x5f\x09\x0b\x5f\x6c\x3d\x56\x56\x1b\x54\x5f\x41\x45\x29\x3c\x0b\x5c\x58\x00\x5f\x5d\x09\x54\x6c\x2a\x40\x06\x06\x6a\x27\x48\x42\x5f\x4b\x56\x42\x2d\x2c\x43\x5d\x5e\x6c\x2d\x41\x07\x47\x43\x5e\x31\x6b\x5a\x0a\x3b\x6e\x1c\x49\x54\x5e\x1a\x2b\x34\x05\x5e...
56
398
0.702381
aea9cacfd1d4f1a413d1bb430f1a08ee6761f9be
1,485
py
Python
src/Node.py
LukasTinnes/VenturePainter
cb1f24fda2a43d402a9c5a401d713af0c950270b
[ "Unlicense" ]
1
2020-05-29T21:09:33.000Z
2020-05-29T21:09:33.000Z
src/Node.py
LukasTinnes/VenturePainter
cb1f24fda2a43d402a9c5a401d713af0c950270b
[ "Unlicense" ]
3
2020-06-14T11:33:54.000Z
2022-01-13T03:31:06.000Z
src/Node.py
LukasTinnes/VenturePainter
cb1f24fda2a43d402a9c5a401d713af0c950270b
[ "Unlicense" ]
null
null
null
class Node: """ A node in a graph """ def __init__(self, identifier): """ :param identifier: Identifier is hash of given Shape Object """ self.identifier = identifier self.outgoing_pointers = [] self.incoming_pointers = [] def get_identifier(self): ...
28.018868
81
0.584512
aec4a874cf00905f1f3609980c64b8fe4ce94a76
245
bzl
Python
tools/rules/cu.bzl
vuanvin/pytorch
9267fd8d7395074001ad7cf2a8f28082dbff6b0b
[ "Intel" ]
5
2018-04-24T13:41:12.000Z
2019-07-09T07:32:09.000Z
tools/rules/cu.bzl
vuanvin/pytorch
9267fd8d7395074001ad7cf2a8f28082dbff6b0b
[ "Intel" ]
14
2021-10-14T06:58:50.000Z
2021-12-17T11:51:07.000Z
tools/rules/cu.bzl
vuanvin/pytorch
9267fd8d7395074001ad7cf2a8f28082dbff6b0b
[ "Intel" ]
7
2020-08-31T22:49:59.000Z
2020-09-15T14:29:07.000Z
load("@rules_cuda//cuda:defs.bzl", "cuda_library") NVCC_COPTS = ["--expt-relaxed-constexpr", "--expt-extended-lambda"] def cu_library(name, srcs, copts = [], **kwargs): cuda_library(name, srcs = srcs, copts = NVCC_COPTS + copts, **kwargs)
35
73
0.681633