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
b599964bb08598cc6fa04b30d376ce24e77977e4
27,830
py
Python
Packs/CadoResponse/Integrations/CadoResponse/CadoResponse_test.py
cstone112/content
7f039931b8cfc20e89df52d895440b7321149a0d
[ "MIT" ]
2
2021-12-06T21:38:24.000Z
2022-01-13T08:23:36.000Z
Packs/CadoResponse/Integrations/CadoResponse/CadoResponse_test.py
cstone112/content
7f039931b8cfc20e89df52d895440b7321149a0d
[ "MIT" ]
87
2022-02-23T12:10:53.000Z
2022-03-31T11:29:05.000Z
Packs/CadoResponse/Integrations/CadoResponse/CadoResponse_test.py
cstone112/content
7f039931b8cfc20e89df52d895440b7321149a0d
[ "MIT" ]
2
2022-01-05T15:27:01.000Z
2022-02-01T19:27:43.000Z
''' Tests for the Cado Response API Integration for the Cortex XSOAR Platform ''' from typing import Any, Dict, List, Union from CommonServerPython import CommandResults, DemistoException from pytest import raises def test_module_command_success(requests_mock: Any) -> None: ''' Successful test for the tes...
31.234568
97
0.520086
a9903db9b21a0b6ff5861d72b506236d7658d780
1,690
py
Python
classification/scripts/configs_hyperparameter_tuning/BoW_non_binary_best_f1.py
s-santoro/lunch-crawler
1e39b1d35d76067a55b2c034d0488a6ec53f8a45
[ "Apache-2.0" ]
1
2020-07-11T04:24:40.000Z
2020-07-11T04:24:40.000Z
classification/scripts/configs_hyperparameter_tuning/BoW_non_binary_best_f1.py
s-santoro/lunch-crawler
1e39b1d35d76067a55b2c034d0488a6ec53f8a45
[ "Apache-2.0" ]
null
null
null
classification/scripts/configs_hyperparameter_tuning/BoW_non_binary_best_f1.py
s-santoro/lunch-crawler
1e39b1d35d76067a55b2c034d0488a6ec53f8a45
[ "Apache-2.0" ]
null
null
null
class Configurations: configs = [ # # Configurations for Machine-Learning Pipeline # {# bow non binary best f1 # basic preprocessing "textToLowerCase": True, "textReplaceUmlaut": True, "textRemoveSpecialCharacters": True, "...
30.727273
102
0.480473
1939d50954dcaabe88d64e7b445215908ac0ae4c
3,207
py
Python
pyramid-creator/app/persistance/custom_minio_client.py
jinnn-dev/patholearn
b4e6a18cfbf963e71640ed6cac3fc3a618a7ae15
[ "MIT" ]
1
2021-11-04T17:06:07.000Z
2021-11-04T17:06:07.000Z
pyramid-creator/app/persistance/custom_minio_client.py
JamesNeumann/learning-by-annotations
c2b5e4b653eeb1c973aa5a7dad35ac8be18cb1ad
[ "MIT" ]
21
2021-11-01T10:13:56.000Z
2021-12-02T10:02:13.000Z
pyramid-creator/app/persistance/custom_minio_client.py
jinnn-dev/patholearn
b4e6a18cfbf963e71640ed6cac3fc3a618a7ae15
[ "MIT" ]
1
2021-12-16T18:20:55.000Z
2021-12-16T18:20:55.000Z
import json import os from typing import Any from minio import Minio from minio.deleteobjects import DeleteObject from loguru import logger logger.add("minio_client.log", retention="1 week") def policy(bucket_name): return { "Version": "2012-10-17", "Statement": [ { ...
34.483871
89
0.571874
d0ad1b3df97748390bfd2d57ab914543e85215b4
339
py
Python
Curso_Python/Secao9-Django-Projeto-Agenda-163-183/projeto_agenda/accounts/models.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
Curso_Python/Secao9-Django-Projeto-Agenda-163-183/projeto_agenda/accounts/models.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
Curso_Python/Secao9-Django-Projeto-Agenda-163-183/projeto_agenda/accounts/models.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
from django.db import models from contatos.models import Contato # importar Contato de contato/views from django import forms #importa os formularios que vai ser utilizado no dashboard class FormContato(forms.ModelForm): class Meta: model = Contato # representar os campos contato exclu...
30.818182
86
0.722714
4bedb90255fb6d174708c5b00b68b248ea215571
3,334
py
Python
ppyt/rules/exit_rules/__init__.py
yusukemurayama/ppytrading
9804d0de870d77bf8a1c847736a636b1342d4600
[ "MIT" ]
4
2016-08-16T07:47:15.000Z
2017-12-11T10:08:47.000Z
ppyt/rules/exit_rules/__init__.py
yusukemurayama/ppytrading
9804d0de870d77bf8a1c847736a636b1342d4600
[ "MIT" ]
null
null
null
ppyt/rules/exit_rules/__init__.py
yusukemurayama/ppytrading
9804d0de870d77bf8a1c847736a636b1342d4600
[ "MIT" ]
2
2018-06-15T04:43:15.000Z
2020-05-02T07:47:15.000Z
# coding: utf-8 import logging import abc from ppyt import const from ppyt.rules import RuleBase from ppyt.decorators import handle_nodataerror from ppyt.exceptions import OrderTypeError logger = logging.getLogger(__name__) class ExitBase(RuleBase, metaclass=abc.ABCMeta): """exit_ruleの親クラスです。""" _rule_type ...
27.327869
108
0.625975
3239f9107e0b41afa4327165c26fe1cc0348f926
13,010
py
Python
src/onegov/search/integration.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/search/integration.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/search/integration.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
import certifi import morepath import ssl from concurrent.futures import ThreadPoolExecutor from datetime import datetime from elasticsearch import ConnectionError # shadows a python builtin! from elasticsearch import Elasticsearch from elasticsearch import Transport from elasticsearch import TransportError from elas...
31.731707
79
0.601384
3240909f0d0d6d92bea3adce0aeded1888a6668e
935
py
Python
dict.py
GShamian/ExamInf
81f521d0b137eee0a4c7f53443303f419e7c33ef
[ "MIT" ]
2
2017-12-22T20:03:30.000Z
2017-12-24T20:55:38.000Z
dict.py
GShamian/ExamInf
81f521d0b137eee0a4c7f53443303f419e7c33ef
[ "MIT" ]
null
null
null
dict.py
GShamian/ExamInf
81f521d0b137eee0a4c7f53443303f419e7c33ef
[ "MIT" ]
null
null
null
class Dict(): def __init__(self): self.data = [] def check(self, k): for i in range(len(self.data)): if k == self.data[i][0]: return i + 1 return False def append(self, key, val): pos = self.check(key) if not pos: self.data.ap...
21.744186
43
0.530481
08ea74adf5a0e22f3b9febe2ae09a040d5dc1b1d
1,787
py
Python
PYTHON/Regex_and_Parsing/html_parser_part1.py
byung-u/HackerRank
4c02fefff7002b3af774b99ebf8d40f149f9d163
[ "MIT" ]
null
null
null
PYTHON/Regex_and_Parsing/html_parser_part1.py
byung-u/HackerRank
4c02fefff7002b3af774b99ebf8d40f149f9d163
[ "MIT" ]
null
null
null
PYTHON/Regex_and_Parsing/html_parser_part1.py
byung-u/HackerRank
4c02fefff7002b3af774b99ebf8d40f149f9d163
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 from html.parser import HTMLParser class MyHTMLParser(HTMLParser): def handle_starttag(self, tag, attrs): print('Start :', tag) for ele in attrs: print('->', ele[0], '>', ele[1]) def handle_endtag(self, tag): print('End :', tag) def handle_sta...
29.295082
81
0.429211
261d72c47120ff61540fd90e11140ccb999b076c
383
py
Python
Contests/CCC/CCC '05 J3 - Returning Home.py
MastaCoder/Projects
ebb0a3134522b12f052fec8d753005f384adf1b1
[ "MIT" ]
5
2018-10-11T01:55:40.000Z
2021-12-25T23:38:22.000Z
Contests/CCC/CCC '05 J3 - Returning Home.py
MastaCoder/mini_projects
ebb0a3134522b12f052fec8d753005f384adf1b1
[ "MIT" ]
null
null
null
Contests/CCC/CCC '05 J3 - Returning Home.py
MastaCoder/mini_projects
ebb0a3134522b12f052fec8d753005f384adf1b1
[ "MIT" ]
1
2019-02-22T14:42:50.000Z
2019-02-22T14:42:50.000Z
info = [] t = 0 while True: info.append(input()) if info[t] == "SCHOOL": break t += 1 for a in range(len(info) - 2, -1, -2): print("Turn ", end = "") if info[a] == "R": print("LEFT ", end = "") else: print("RIGHT ", end = "") if a == 0: print("into your HOME...
20.157895
49
0.43342
cd07552a407c10b2d2c6b40c2b944b60f4308486
588
py
Python
leetcode/494-Target-Sum/TargetSum.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2015-12-16T04:01:03.000Z
2015-12-16T04:01:03.000Z
leetcode/494-Target-Sum/TargetSum.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-02-09T06:00:07.000Z
2016-02-09T07:20:13.000Z
leetcode/494-Target-Sum/TargetSum.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
2
2019-06-27T09:07:26.000Z
2019-07-01T04:40:13.000Z
class Solution(object): def findTargetSumWays(self, nums, S): """ :type nums: List[int] :type S: int :rtype: int """ res = 0 ma = sum(nums) tmp = [0] * (2 * ma + 1) cnt = tmp[:] cnt[ma] = 1 for num in nums: for i in ...
25.565217
42
0.353741
26fcefad87f0f270474af7c938dd087ed8a36f39
2,893
py
Python
Packs/MalwareInvestigationAndResponse/Scripts/ReadProcessesFileXDR/ReadProcessesFileXDR.py
jrauen/content
81a92be1cbb053a5f26a6f325eff3afc0ca840e0
[ "MIT" ]
null
null
null
Packs/MalwareInvestigationAndResponse/Scripts/ReadProcessesFileXDR/ReadProcessesFileXDR.py
jrauen/content
81a92be1cbb053a5f26a6f325eff3afc0ca840e0
[ "MIT" ]
40
2022-03-03T07:34:00.000Z
2022-03-31T07:38:35.000Z
Packs/MalwareInvestigationAndResponse/Scripts/ReadProcessesFileXDR/ReadProcessesFileXDR.py
jrauen/content
81a92be1cbb053a5f26a6f325eff3afc0ca840e0
[ "MIT" ]
null
null
null
import demistomock as demisto # noqa: F401 from CommonServerPython import * # noqa: F401 from typing import Union import re CONTEXT_PATH_TO_READ_PROCESS_FILE_NAME_FROM_XDR_DATA = "PaloAltoNetworksXDR.ScriptResult" def read_xdr_context(): script_results = demisto.get(demisto.context(), CONTEXT_PATH_TO_READ_PROC...
29.222222
105
0.654338
6ef69e53f6eabb0cf94c5f6aed87cc810bb004b5
9,833
py
Python
official/nlp/tinybert/run_general_distill.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
official/nlp/tinybert/run_general_distill.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
official/nlp/tinybert/run_general_distill.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
24
2021-10-15T08:32:45.000Z
2022-03-24T18:45:20.000Z
# Copyright 2020 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...
47.502415
114
0.641818
3e6c1fd805993d26a14ddc2a29231b8e60107c39
7,534
py
Python
Dockerfiles/gedlab-khmer-filter-abund/pymodules/python2.7/lib/python/pybedtools-0.7.6-py2.7-linux-x86_64.egg/pybedtools/contrib/intersection_matrix.py
poojavade/Genomics_Docker
829b5094bba18bbe03ae97daf925fee40a8476e8
[ "Apache-2.0" ]
1
2019-07-29T02:53:51.000Z
2019-07-29T02:53:51.000Z
Dockerfiles/gedlab-khmer-filter-abund/pymodules/python2.7/lib/python/pybedtools-0.7.6-py2.7-linux-x86_64.egg/pybedtools/contrib/intersection_matrix.py
poojavade/Genomics_Docker
829b5094bba18bbe03ae97daf925fee40a8476e8
[ "Apache-2.0" ]
1
2021-09-11T14:30:32.000Z
2021-09-11T14:30:32.000Z
Dockerfiles/gedlab-khmer-filter-abund/pymodules/python2.7/lib/python/pybedtools-0.7.6-py2.7-linux-x86_64.egg/pybedtools/contrib/intersection_matrix.py
poojavade/Genomics_Docker
829b5094bba18bbe03ae97daf925fee40a8476e8
[ "Apache-2.0" ]
2
2016-12-19T02:27:46.000Z
2019-07-29T02:53:54.000Z
import os import sys import sqlite3 import pybedtools import time import collections def now(): return time.time() def get_name(fname): return os.path.splitext(os.path.basename(fname))[0] class IntersectionMatrix(object): """ Class to handle many pairwise comparisons of interval files """ ...
29.896825
79
0.510486
3e8e8d3d490faca2969c8eb532c777051e6aebde
1,700
py
Python
controller/clock1m.py
huberthoegl/tsgrain
405d0ba8b98c2afa950d27294e55cd1e07506db4
[ "Apache-2.0" ]
1
2021-06-15T08:59:02.000Z
2021-06-15T08:59:02.000Z
controller/clock1m.py
huberthoegl/tsgrain
405d0ba8b98c2afa950d27294e55cd1e07506db4
[ "Apache-2.0" ]
null
null
null
controller/clock1m.py
huberthoegl/tsgrain
405d0ba8b98c2afa950d27294e55cd1e07506db4
[ "Apache-2.0" ]
null
null
null
# https://schedule.readthedocs.io by Dan Bader import schedule import threading import time handler_list = [] def add_handler(f): global handler_list handler_list.append(f) def _call_handler(): for f in handler_list: f() def start(): schedule.every().minute.at(":00").do(_call_handler)...
24.285714
76
0.631176
4bb7807ba5a773c8b884f852c3d576cae2a1bcbd
1,120
py
Python
scripts/ue01_turtlesim_richtung_zum_ziel/ue01_dir_to_goal.py
ProfJust/Ruhr-TurtleBot-Competition-RTC-
5c2425bee331b4d5033757a9425676932d111775
[ "Unlicense", "MIT" ]
null
null
null
scripts/ue01_turtlesim_richtung_zum_ziel/ue01_dir_to_goal.py
ProfJust/Ruhr-TurtleBot-Competition-RTC-
5c2425bee331b4d5033757a9425676932d111775
[ "Unlicense", "MIT" ]
null
null
null
scripts/ue01_turtlesim_richtung_zum_ziel/ue01_dir_to_goal.py
ProfJust/Ruhr-TurtleBot-Competition-RTC-
5c2425bee331b4d5033757a9425676932d111775
[ "Unlicense", "MIT" ]
null
null
null
#!/usr/bin/env python # --- ue01_dir_to_goal.py ------ # Version vom 11.10.2021 by OJ # Weg zum Ziel in der TurtleSim berechnen # --------------------------------------- # Import math Library wegen atan2() import math print(" Weg zum Ziel berechnen \n") # --- Eingabe Pose ------ eingabe = input(" Pose x ? >:") # st...
24.888889
55
0.6
2997b0878b5e21cf97a7d1a64074fbf56bdb9fed
102
py
Python
Python/Books/Learning-Programming-with-Python.Tamim-Shahriar-Subeen/chapter-003/pg-3.2-variable-more-value.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
Python/Books/Learning-Programming-with-Python.Tamim-Shahriar-Subeen/chapter-003/pg-3.2-variable-more-value.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
Python/Books/Learning-Programming-with-Python.Tamim-Shahriar-Subeen/chapter-003/pg-3.2-variable-more-value.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
number1 = 10 print(number1) number1 = 15 number1 = 18 print(number1) number1 = "hello" print(number1)
12.75
17
0.735294
4b177d9fbd6f139a542c4bc55243d7d1e1e43367
523
py
Python
01.DataStructure/Tree/NY/B9934_NY.py
SP2021-2/Algorithm
2e629eb5234212fad8bbc11491aad068e5783780
[ "MIT" ]
1
2021-11-21T06:03:06.000Z
2021-11-21T06:03:06.000Z
01.DataStructure/Tree/NY/B9934_NY.py
SP2021-2/Algorithm
2e629eb5234212fad8bbc11491aad068e5783780
[ "MIT" ]
2
2021-10-13T07:21:09.000Z
2021-11-14T13:53:08.000Z
01.DataStructure/Tree/NY/B9934_NY.py
SP2021-2/Algorithm
2e629eb5234212fad8bbc11491aad068e5783780
[ "MIT" ]
null
null
null
#백준 - 완전 이진 트리 9934 import sys k = int(input()) numOrder = sys.stdin.readline().split() bt = [] for i in range (k) : bt.append([]) #재귀함수 def binaryArr (arr, lev) : if len(arr) == 1 : bt[lev].append(arr[0]) return bt else : #배열의 중간을 뽑아냄 middle = len(arr) // 2 bt[le...
16.870968
42
0.521989
6aab5b7b87cbb40fcf269f18a3f6109c4984345f
665
py
Python
demo/cnn_lstm_predict.py
Adrimeov/keras-malicious-url-detector
22b8d075b41117f016100bb5ebff14a77907dacb
[ "MIT" ]
23
2018-03-06T07:13:08.000Z
2022-03-15T15:13:01.000Z
demo/cnn_lstm_predict.py
aligeekk/keras-malicious-url-detector
ccf316e1f7b1714cdfc34ff4dec4dd938b6e703c
[ "MIT" ]
null
null
null
demo/cnn_lstm_predict.py
aligeekk/keras-malicious-url-detector
ccf316e1f7b1714cdfc34ff4dec4dd938b6e703c
[ "MIT" ]
21
2018-03-06T07:40:14.000Z
2022-03-13T18:53:33.000Z
from keras_malicious_url_detector.library.cnn_lstm import CnnLstmPredictor from keras_malicious_url_detector.library.utility.url_data_loader import load_url_data def main(): data_dir_path = './data' model_dir_path = './models' predictor = CnnLstmPredictor() predictor.load_model(model_dir_path) ...
27.708333
86
0.682707
0afa9cdf2937f69be5d350bb1429390cf9554133
350
py
Python
DataStructure/U9/U9_59.py
qiaw99/Data-Structure
3b1cdce96d4f35329ccfec29c03de57378ef0552
[ "MIT" ]
1
2019-10-29T08:21:41.000Z
2019-10-29T08:21:41.000Z
DataStructure/U9/U9_59.py
qiaw99/Data-Structure
3b1cdce96d4f35329ccfec29c03de57378ef0552
[ "MIT" ]
null
null
null
DataStructure/U9/U9_59.py
qiaw99/Data-Structure
3b1cdce96d4f35329ccfec29c03de57378ef0552
[ "MIT" ]
null
null
null
def hashfunction(): t_values = [0, 1, 2, 3, 4, 5, 13, 20] res = {} for t in t_values: temp = [0 for i in range(1024)] for i in range(1024): temp[ (t*i) % 1024] += 1 m = max(temp) print(m) res[t] = m print(res) return res hashfunction() print("Perm...
21.875
41
0.482857
7c22d796f081259e67e14003deb2d9af90b2d3a4
11,466
py
Python
Integrations/python/deephaven/npy/table2numpy.py
devinrsmith/deephaven-core
3a6930046faf1cd556f62a914ce1cfd7860147b9
[ "MIT" ]
null
null
null
Integrations/python/deephaven/npy/table2numpy.py
devinrsmith/deephaven-core
3a6930046faf1cd556f62a914ce1cfd7860147b9
[ "MIT" ]
1
2022-03-03T21:24:40.000Z
2022-03-03T21:24:54.000Z
Integrations/python/deephaven/npy/table2numpy.py
devinrsmith/deephaven-core
3a6930046faf1cd556f62a914ce1cfd7860147b9
[ "MIT" ]
null
null
null
# # Copyright (c) 2016-2021 Deephaven Data Labs and Patent Pending # """Utilities for converting between Deephaven tables and numpy arrays.""" import collections import jpy import wrapt import numpy as np __all__ = ['numpy_sample', 'numpy_slice'] _class_name_ = "io.deephaven.integrations.numpy.Java2NumpyCopy" _Ja...
35.171779
125
0.674865
7ca1d9416a773c518cb6783de20a08281b47975b
1,447
py
Python
listings/chapter06/bag_of_words.py
SaschaKersken/Daten-Prozessanalyse
370f07a75b9465329deb3671adbfbef8483f76f6
[ "Apache-2.0" ]
2
2021-09-20T06:16:41.000Z
2022-01-17T14:24:43.000Z
listings/chapter06/bag_of_words.py
SaschaKersken/Daten-Prozessanalyse
370f07a75b9465329deb3671adbfbef8483f76f6
[ "Apache-2.0" ]
null
null
null
listings/chapter06/bag_of_words.py
SaschaKersken/Daten-Prozessanalyse
370f07a75b9465329deb3671adbfbef8483f76f6
[ "Apache-2.0" ]
null
null
null
from sklearn.feature_extraction.text import CountVectorizer import numpy as np # Eine Bag of Words ausgeben def print_bag(vectorizer, bag_of_words): features = vectorizer.get_feature_names() print("Wörter:", features) print("Daten:") stats = bag_of_words.toarray() print(stats) print("Angewandt:...
34.452381
69
0.724257
7cb42bb7b3df80fbda47803c4a64a43c9cda501a
623
py
Python
books/PythonCleanCode/ch9_design_pattern/monostate_1.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
books/PythonCleanCode/ch9_design_pattern/monostate_1.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
books/PythonCleanCode/ch9_design_pattern/monostate_1.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
"""Clean Code in Python - Chatper 9: Common Design Patterns > Monostate Pattern """ from log import logger class GitFetcher: _current_tag = None def __init__(self, tag): self.current_tag = tag @property def current_tag(self): if self._current_tag is None: ...
23.074074
60
0.634029
86e6e2f675826d43338982a6de392353eb3c11e3
2,868
py
Python
8_DeepLearning-Autoencoder/Variational_Autoencoder/Variational_Autoencoder.py
felixdittrich92/DeepLearning-tensorflow-keras
2880d8ed28ba87f28851affa92b6fa99d2e47be9
[ "Apache-2.0" ]
null
null
null
8_DeepLearning-Autoencoder/Variational_Autoencoder/Variational_Autoencoder.py
felixdittrich92/DeepLearning-tensorflow-keras
2880d8ed28ba87f28851affa92b6fa99d2e47be9
[ "Apache-2.0" ]
null
null
null
8_DeepLearning-Autoencoder/Variational_Autoencoder/Variational_Autoencoder.py
felixdittrich92/DeepLearning-tensorflow-keras
2880d8ed28ba87f28851affa92b6fa99d2e47be9
[ "Apache-2.0" ]
null
null
null
''' ähnlich zum GAN bzw. selbe "Funktion" -> aber GANs nutzen, da genauer bzw. "besser" ''' import numpy as np import matplotlib.pyplot as plt import tensorflow as tf tf.compat.v1.disable_eager_execution() from tensorflow.keras.layers import * from tensorflow.keras.models import * from tensorflow.keras.optimizers im...
29.56701
91
0.723849
be0c427d2fc718420acf65a8f529b8f67151e332
7,176
py
Python
model_zoo/electra/deploy/lite/prepare.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
model_zoo/electra/deploy/lite/prepare.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
model_zoo/electra/deploy/lite/prepare.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
import argparse import time import numpy as np import os import io import shutil import fileinput from paddlenlp.transformers import ElectraTokenizer def parse_args(): parser = argparse.ArgumentParser() parser.add_argument("--lite_lib_path", type=str, required=...
36.612245
111
0.589047
07feaf7cb84f9a6dc5718377313e81180e679ed2
9,635
py
Python
src/onegov/user/collections/user.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/user/collections/user.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/user/collections/user.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from collections.abc import Iterable from onegov.core.crypto import random_token from onegov.core.utils import toggle from onegov.user import log from onegov.user.models import User from onegov.user.errors import ( AlreadyActivatedError, ExistingUserError, InsecurePasswordError, InvalidActivationTokenEr...
29.375
79
0.598028
ed017604138eef80cb59a780f438879d9922f363
3,465
py
Python
UAS/UAS 7.py
Archedar/UAS
3237d9304026340acc93c8f36b358578dc0ae66f
[ "BSD-Source-Code" ]
null
null
null
UAS/UAS 7.py
Archedar/UAS
3237d9304026340acc93c8f36b358578dc0ae66f
[ "BSD-Source-Code" ]
null
null
null
UAS/UAS 7.py
Archedar/UAS
3237d9304026340acc93c8f36b358578dc0ae66f
[ "BSD-Source-Code" ]
null
null
null
#Alpro uas no 7 wadah1, wadah2, wadah3, benar = [ 1, 2, 3, 4, 5 ], [ ' ', ' ', ' ', ' ', ' ' ], [ ' ', ' ', ' ', ' ', ' ' ], [ 1, 2, 3, 4, 5 ] langkah = 0 while True: print('') for i in range(len(wadah1)): print(f'|{wadah1[i]} {wadah2[i]} {wadah3[i]}|') print(' a b c ') input...
25.477941
83
0.492063
1361b86ce11cfbad9570e38da40190d5d10f9819
25,607
py
Python
tests/onegov/ballot/models/test_election.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/ballot/models/test_election.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/ballot/models/test_election.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from datetime import date from freezegun import freeze_time from onegov.ballot import Candidate from onegov.ballot import CandidateResult from onegov.ballot import Election from onegov.ballot import ElectionAssociation from onegov.ballot import ElectionResult from uuid import uuid4 def majorz_election(): eid = uu...
27.713203
79
0.62643
136d93f6c1aed951f8d6717290e1697f8d28bbb6
3,092
py
Python
Packs/FeedRSS/Integrations/FeedRSS/FeedRSS_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/FeedRSS/Integrations/FeedRSS/FeedRSS_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/FeedRSS/Integrations/FeedRSS/FeedRSS_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
import pytest from FeedRSS import * from requests.models import Response from test_data.test_variables import HTML_CONTENT, FEED_DATA, TEST_DATA_MAX_SIZE def side_effect_feed_url(mocker, client): feed_content_res = Response() type(feed_content_res).status_code = mocker.PropertyMock(return_value=200) type(...
37.707317
120
0.722186
137032fd274045cb25558a8f3d17450f9004bfa8
1,151
py
Python
exercises/python/data-types/collections/pilling-up-recursive.py
rogeriosantosf/hacker-rank-profile
d4b9c131524d138c415e5c5de4e38c6b8c35dd77
[ "MIT" ]
null
null
null
exercises/python/data-types/collections/pilling-up-recursive.py
rogeriosantosf/hacker-rank-profile
d4b9c131524d138c415e5c5de4e38c6b8c35dd77
[ "MIT" ]
null
null
null
exercises/python/data-types/collections/pilling-up-recursive.py
rogeriosantosf/hacker-rank-profile
d4b9c131524d138c415e5c5de4e38c6b8c35dd77
[ "MIT" ]
null
null
null
from collections import deque def grab_a_cube(cubes): if len(cubes) == 1: return cubes.pop() else: leftmost = cubes.popleft() rightmost = cubes.pop() if leftmost > rightmost: cubes.append(rightmost) return leftmost else: cubes.appendl...
25.021739
74
0.592528
e06560c9814c3f9f424ae935c9a031b772554c8f
3,604
py
Python
pyBarcode-0.6/barcode/isxn.py
fau-fablab/etiketten
5f4fcdd14001807e183164ae66df48d86c8f7a3e
[ "Unlicense" ]
1
2018-12-15T04:07:38.000Z
2018-12-15T04:07:38.000Z
pyBarcode-0.6/barcode/isxn.py
fau-fablab/etiketten
5f4fcdd14001807e183164ae66df48d86c8f7a3e
[ "Unlicense" ]
14
2015-01-02T10:37:33.000Z
2021-10-03T13:42:15.000Z
pyBarcode-0.6/barcode/isxn.py
fau-fablab/etiketten
5f4fcdd14001807e183164ae66df48d86c8f7a3e
[ "Unlicense" ]
1
2018-12-15T04:07:40.000Z
2018-12-15T04:07:40.000Z
# -*- coding: utf-8 -*- from __future__ import unicode_literals """barcode.isxn This module provides some special codes, which are no standalone barcodes. All codes where transformed to EAN-13 barcodes. In every case, the checksum is new calculated. Example:: >>> from barcode import get_barcode >>> ISBN = ...
28.377953
79
0.619312
16922565252667c1b18734e5b4f99af40102f4f0
1,052
py
Python
source/pkgsrc/databases/py-sqlite3/files/setup.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
1
2021-11-20T22:46:39.000Z
2021-11-20T22:46:39.000Z
source/pkgsrc/databases/py-sqlite3/files/setup.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
null
null
null
source/pkgsrc/databases/py-sqlite3/files/setup.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
null
null
null
# $NetBSD: setup.py,v 1.2 2010/02/19 17:15:11 joerg Exp $ from distutils.core import setup, Extension sqlite_prefix = '@SQLITE_PREFIX@' sqlite_incdir = sqlite_prefix + '/include' sqlite_libdir = sqlite_prefix + '/lib' sqlite_defines = [('MODULE_NAME', '"sqlite3"')] sqlite_srcs = ['_sqlite/cache.c', '...
30.941176
57
0.542776
16cbdd118c88224a3bce763a70dccfe6ad0685a4
4,813
py
Python
CGR/T2/castle.py
joao-frohlich/BCC
9ed74eb6d921d1280f48680677a2140c5383368d
[ "Apache-2.0" ]
10
2020-12-08T20:18:15.000Z
2021-06-07T20:00:07.000Z
CGR/T2/castle.py
joao-frohlich/BCC
9ed74eb6d921d1280f48680677a2140c5383368d
[ "Apache-2.0" ]
2
2021-06-28T03:42:13.000Z
2021-06-28T16:53:13.000Z
CGR/T2/castle.py
joao-frohlich/BCC
9ed74eb6d921d1280f48680677a2140c5383368d
[ "Apache-2.0" ]
2
2021-01-14T19:59:20.000Z
2021-06-15T11:53:21.000Z
from OpenGL.GL import * from OpenGL.GLUT import * from OpenGL.GLU import * from colors import * from math import pi, sin, cos from shapes import ( SolidRectangle, SolidCylinder, SolidPrismaTriangular, DrawTower, DrawWall, ) scale = 8.0 angle_h = 300.0 angle_v = 0 spin = True turn_h = 1 turn_v = 0 r...
22.077982
65
0.640972
16ed431324157c3dbc26f980bdb61920eff02e28
582
py
Python
listings/chapter04/dirs.py
SaschaKersken/Daten-Prozessanalyse
370f07a75b9465329deb3671adbfbef8483f76f6
[ "Apache-2.0" ]
2
2021-09-20T06:16:41.000Z
2022-01-17T14:24:43.000Z
listings/chapter04/dirs.py
SaschaKersken/Daten-Prozessanalyse
370f07a75b9465329deb3671adbfbef8483f76f6
[ "Apache-2.0" ]
null
null
null
listings/chapter04/dirs.py
SaschaKersken/Daten-Prozessanalyse
370f07a75b9465329deb3671adbfbef8483f76f6
[ "Apache-2.0" ]
null
null
null
from os import listdir from os.path import isfile, isdir from sys import argv def print_dir(directory, indent = 0): for entry in listdir(directory): path = f"{directory}/{entry}" if isdir(path): prefix = 'D' elif isfile(path): prefix = 'F' else: p...
24.25
48
0.536082
bc8af235ccade967ed47922a5bb66565a88187d6
3,507
py
Python
CC8130-SegurancaDaInformacao/Atv-Criptografia/Atv.py
phdomingues/FEI-CS
e1dc19c190d61f5f13492ba5179f5d41295f1b50
[ "MIT" ]
null
null
null
CC8130-SegurancaDaInformacao/Atv-Criptografia/Atv.py
phdomingues/FEI-CS
e1dc19c190d61f5f13492ba5179f5d41295f1b50
[ "MIT" ]
null
null
null
CC8130-SegurancaDaInformacao/Atv-Criptografia/Atv.py
phdomingues/FEI-CS
e1dc19c190d61f5f13492ba5179f5d41295f1b50
[ "MIT" ]
null
null
null
import json FILE_NAME = 'Chaves de Criptografia 2021.S2.txt' DEBUG = True class bcolors: GREEN = '\033[92m' RED = '\033[91m' BOLD = '\033[1m' ENDC = '\033[0m' def monobit_test(bin_string): # Conta zeros X = bin_string.count("1") # Verifica se esta no range valido approved = X > 9654 a...
32.775701
136
0.53493
4c68d29975650d5be2ffd770e3bde1622afc1862
923
py
Python
nachmittags/blatt2_2.py
dotKuro/vorsemesterWISE19-20
436c6d1846b6c1bfb087652e8ca179bd1b12c28e
[ "CC0-1.0" ]
1
2019-09-27T13:47:20.000Z
2019-09-27T13:47:20.000Z
nachmittags/blatt2_2.py
dotKuro/vorsemesterWISE19-20
436c6d1846b6c1bfb087652e8ca179bd1b12c28e
[ "CC0-1.0" ]
null
null
null
nachmittags/blatt2_2.py
dotKuro/vorsemesterWISE19-20
436c6d1846b6c1bfb087652e8ca179bd1b12c28e
[ "CC0-1.0" ]
null
null
null
from math import inf # eigene Funktion impotieren from test import frage_passwort def square_number(number): """f(x) = x^2 (x hoch 2)""" return number * number # Aufgabe 2a.2 def get_smallest_number(numbers): """a)""" smallest_number = inf for number in numbers: if number < smallest_num...
20.065217
47
0.653304
d5c0f6fa8d7303d8f9a3fdc2f3f8c00f87ed43d5
513
py
Python
scripts/csvToJson.py
iisisrael/readium-desktop
17c866a684fe3ac2ef6dcd46723856fb8315507e
[ "BSD-3-Clause" ]
null
null
null
scripts/csvToJson.py
iisisrael/readium-desktop
17c866a684fe3ac2ef6dcd46723856fb8315507e
[ "BSD-3-Clause" ]
null
null
null
scripts/csvToJson.py
iisisrael/readium-desktop
17c866a684fe3ac2ef6dcd46723856fb8315507e
[ "BSD-3-Clause" ]
null
null
null
import json import csv import sys path = sys.argv[1] resultPath = sys.argv[2] languageNameId = int(sys.argv[3]) codeId = int(sys.argv[4]) resultObj = {} with open(path) as csv_file: csv_reader = csv.reader(csv_file, delimiter=',') line_count = 0 for row in csv_reader: if line_count != 0: ...
20.52
65
0.660819
5dcdbf3e1992687a754097c448269886db940bcb
21,481
py
Python
Packs/CortexXDR/Scripts/XDRSyncScript_5_9_9/XDRSyncScript_5_9_9.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/CortexXDR/Scripts/XDRSyncScript_5_9_9/XDRSyncScript_5_9_9.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/CortexXDR/Scripts/XDRSyncScript_5_9_9/XDRSyncScript_5_9_9.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
import dateparser import demistomock as demisto from CommonServerPython import * from CommonServerUserPython import * from dateutil import parser import copy from typing import Optional, Dict import traceback # XDR_FIELDS INCIDENT_ID_XDR_FIELD = "incident_id" MANUAL_SEVERITY_XDR_FIELD = "manual_severity" MANUAL_DESCR...
45.414376
120
0.676784
b90a78728b66875a177e1b7cba04566c867a4f1e
2,379
py
Python
pureflood3-master/pureflood.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-17T03:35:03.000Z
2021-12-08T06:00:31.000Z
pureflood3-master/pureflood.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
null
null
null
pureflood3-master/pureflood.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 os import sys import socket import random import threading """ Educational purpose only I'm not responsible for your actions ----------------------------------------------------- Created By: TheTechHacker SUBSCRIBE: https://www.youtube.com/channel/UCKAmv8p_TRvUNrJlfiB8qBQ """ if sys.platform == ...
33.041667
117
0.618327
5d51683ab72a2ccd4f3f9301b90c4052b25a21ce
5,472
py
Python
research/cv/STGAN/infer/sdk/main.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/cv/STGAN/infer/sdk/main.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/cv/STGAN/infer/sdk/main.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...
33.987578
95
0.607456
071aa2018b625e12244b0d29a054e918f15e219b
25,352
py
Python
python/oneflow/compatible/single_client/test/ops/test_unary_elementwise_ops.py
wangyuyue/oneflow
0a71c22fe8355392acc8dc0e301589faee4c4832
[ "Apache-2.0" ]
3,285
2020-07-31T05:51:22.000Z
2022-03-31T15:20:16.000Z
python/oneflow/compatible/single_client/test/ops/test_unary_elementwise_ops.py
wangyuyue/oneflow
0a71c22fe8355392acc8dc0e301589faee4c4832
[ "Apache-2.0" ]
2,417
2020-07-31T06:28:58.000Z
2022-03-31T23:04:14.000Z
python/oneflow/compatible/single_client/test/ops/test_unary_elementwise_ops.py
wangyuyue/oneflow
0a71c22fe8355392acc8dc0e301589faee4c4832
[ "Apache-2.0" ]
520
2020-07-31T05:52:42.000Z
2022-03-29T02:38:11.000Z
""" Copyright 2020 The OneFlow Authors. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agr...
40.824477
86
0.646142
4acdb1db44edda195b55acf9aa63f99693ed0a3f
260
py
Python
app.py
limazix/analytica-ms-service1
6e4fa7a5af7a3621dc246e37f16c2ec4ea37c6d8
[ "Apache-2.0" ]
null
null
null
app.py
limazix/analytica-ms-service1
6e4fa7a5af7a3621dc246e37f16c2ec4ea37c6d8
[ "Apache-2.0" ]
null
null
null
app.py
limazix/analytica-ms-service1
6e4fa7a5af7a3621dc246e37f16c2ec4ea37c6d8
[ "Apache-2.0" ]
null
null
null
from flask import Flask from markupsafe import escape app = Flask(__name__) @app.route("/") def root(): return "Service 1" @app.route("/hello/<username>") def hello(username): return "Hello {} from Service 1".format( escape(username) )
16.25
44
0.657692
db5fc62ffc4238c09d4925b97940976ec799bf9b
741
py
Python
tests/numbatest.py
metxchris/MMM-Explorer
251b4d7af56241882611bc47e94ec2923e4be8da
[ "MIT" ]
null
null
null
tests/numbatest.py
metxchris/MMM-Explorer
251b4d7af56241882611bc47e94ec2923e4be8da
[ "MIT" ]
null
null
null
tests/numbatest.py
metxchris/MMM-Explorer
251b4d7af56241882611bc47e94ec2923e4be8da
[ "MIT" ]
null
null
null
import numpy as np import numba from numba import jit from timeit import timeit, repeat print(numba.__version__) @jit(nopython=True) def go_fast(a): # Function is compiled to machine code when called the first time trace = 0.0 # assuming square input matrix for i in range(a.shape[0]): # Numba likes loop...
27.444444
81
0.678812
dbcf983aae3fe7701545e1acaac8bcae8b1438aa
1,199
py
Python
python/Stepper.py
thomas-trendsoft/BeerBot
9ac9bfcede3f37dc8aaa3ee09e06272a1b43a9e9
[ "MIT" ]
null
null
null
python/Stepper.py
thomas-trendsoft/BeerBot
9ac9bfcede3f37dc8aaa3ee09e06272a1b43a9e9
[ "MIT" ]
null
null
null
python/Stepper.py
thomas-trendsoft/BeerBot
9ac9bfcede3f37dc8aaa3ee09e06272a1b43a9e9
[ "MIT" ]
1
2020-12-31T01:22:19.000Z
2020-12-31T01:22:19.000Z
import RPi.GPIO as GPIO import time # Base class for 28BYJ-48 stepper motor # should have 2038 steps a round for this sequence class Stepper: # init driver class def __init__(self): self.pins = [22,23,24,25] self.seq = [[1,1,0,0],[0,1,1,0],[0,0,1,1],[1,0,0,1]] self.seqsize = len...
30.74359
64
0.504587
72646a33c918c62fa3cbd18fb4027f0eb35f4913
2,839
py
Python
research/cv/tgcn/src/metrics.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/cv/tgcn/src/metrics.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/cv/tgcn/src/metrics.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.898876
120
0.649877
f4221948b966eb4f95457d23e7ddbc67cc864084
92
py
Python
2014/06/table-alcohol-deaths/graphic_config.py
nprapps/graphics-archive
97b0ef326b46a959df930f5522d325e537f7a655
[ "FSFAP" ]
14
2015-05-08T13:41:51.000Z
2021-02-24T12:34:55.000Z
2014/06/table-alcohol-deaths/graphic_config.py
nprapps/graphics-archive
97b0ef326b46a959df930f5522d325e537f7a655
[ "FSFAP" ]
null
null
null
2014/06/table-alcohol-deaths/graphic_config.py
nprapps/graphics-archive
97b0ef326b46a959df930f5522d325e537f7a655
[ "FSFAP" ]
7
2015-04-04T04:45:54.000Z
2021-02-18T11:12:48.000Z
#!/usr/bin/env python COPY_GOOGLE_DOC_KEY = '1yUF_0zeHyloc8_c0NYJh3Mej81JdVl6VVYkhmKlcm7c'
23
68
0.847826
f44b8e28027a6451decce185c30c1f7c3d5074e4
162
py
Python
Programming Languages/Python/Theory/100_Python_Exercises/Exercises/Exercise 23/23.py
jaswinder9051998/Resources
fd468af37bf24ca57555d153ee64693c018e822e
[ "MIT" ]
101
2021-12-20T11:57:11.000Z
2022-03-23T09:49:13.000Z
50-Python-Exercises/Exercises/Exercise 23/23.py
kuwarkapur/Hacktoberfest-2022
efaafeba5ce51d8d2e2d94c6326cc20bff946f17
[ "MIT" ]
4
2022-01-12T11:55:56.000Z
2022-02-12T04:53:33.000Z
50-Python-Exercises/Exercises/Exercise 23/23.py
kuwarkapur/Hacktoberfest-2022
efaafeba5ce51d8d2e2d94c6326cc20bff946f17
[ "MIT" ]
38
2022-01-12T11:56:16.000Z
2022-03-23T10:07:52.000Z
#Access the third value of key b. from pprint import pprint d = dict(a = list(range(1, 11)), b = list(range(11, 21)), c = list(range(21, 31))) pprint(d['b'][2])
27
82
0.62963
f46ad30f132d181e120eab3b54c0c7780a3ef72b
1,372
py
Python
home-assistant/custom_components/nodered/const.py
Adamvg/SmartHouse
740b010260f6f6b38a19e2a75d431446abd54253
[ "MIT" ]
null
null
null
home-assistant/custom_components/nodered/const.py
Adamvg/SmartHouse
740b010260f6f6b38a19e2a75d431446abd54253
[ "MIT" ]
null
null
null
home-assistant/custom_components/nodered/const.py
Adamvg/SmartHouse
740b010260f6f6b38a19e2a75d431446abd54253
[ "MIT" ]
null
null
null
"""Constants for Node-RED.""" # Base component constants DOMAIN = "nodered" DOMAIN_DATA = f"{DOMAIN}_data" VERSION = "0.4.3" REQUIRED_FILES = [ "translations/en.json", "binary_sensor.py", "config_flow.py", "const.py", "discovery.py", "manifest.json", "sensor.py", "services.y...
26.384615
62
0.715015
beb3589fa9afbf08be89e07996f0d3a491107bb0
760
py
Python
books/PythonAutomate/excel_spreadsheets/blank_row_inserter.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
books/PythonAutomate/excel_spreadsheets/blank_row_inserter.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
books/PythonAutomate/excel_spreadsheets/blank_row_inserter.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
"""blank_row_inserter.py 명령행 매개변수로 두 개의 정수와 파일 이름을 문자열로 받는 프로그램 ex) python blank_row_inserter.py 3 2 <*.xlsx> """ import sys import openpyxl if len(sys.argv) != 4: print(f"python {__file__} <start_row> <blank_size> <excel file>") sys.exit(1) start_row = int(sys.argv[1]) blank_size = int(sys.argv[2]) file_name...
24.516129
78
0.694737
fe2a7a2263cadc7ffe81d0b4b656cee2312d97ea
33
py
Python
Locker_Pro_V3/main.py
huynhquoc1990/Locker_Pro_V3
190173c5b183b227e18e42a9a36a428c1206e3c1
[ "MIT" ]
null
null
null
Locker_Pro_V3/main.py
huynhquoc1990/Locker_Pro_V3
190173c5b183b227e18e42a9a36a428c1206e3c1
[ "MIT" ]
null
null
null
Locker_Pro_V3/main.py
huynhquoc1990/Locker_Pro_V3
190173c5b183b227e18e42a9a36a428c1206e3c1
[ "MIT" ]
null
null
null
def Hi(name): print('Hi',name)
11
18
0.606061
feb4eb1d4d50ffa5fcfb54ef582ee824cf2dccd5
1,868
py
Python
figure2.py
aafaquerk/Solar_ML_Group
4e7121eb2f86899754553e2031de0c3656f79cd9
[ "MIT" ]
null
null
null
figure2.py
aafaquerk/Solar_ML_Group
4e7121eb2f86899754553e2031de0c3656f79cd9
[ "MIT" ]
null
null
null
figure2.py
aafaquerk/Solar_ML_Group
4e7121eb2f86899754553e2031de0c3656f79cd9
[ "MIT" ]
null
null
null
""" Purpose: To generate Figure 2 in Bobra & Illonidis (2016). Inputs: Figure 2 was generated by running the cme_svm.ipynb code with different values for the timedelayvariable, ranging from 48 to 4 hours before the GOES X-ray flare peak time, in 4 hour intervals. The plot will not be exactly the same as the pape...
50.486486
464
0.752677
6073cce52845575c7b958a60ed656dcfc9d17989
88
py
Python
CS205/assignment4/testdata/test.py
Wycers/Codelib
86d83787aa577b8f2d66b5410e73102411c45e46
[ "MIT" ]
22
2018-08-07T06:55:10.000Z
2021-06-12T02:12:19.000Z
CS205/assignment4/testdata/test.py
Wycers/Codelib
86d83787aa577b8f2d66b5410e73102411c45e46
[ "MIT" ]
28
2020-03-04T23:47:22.000Z
2022-02-26T18:50:00.000Z
CS205/assignment4/testdata/test.py
Wycers/Codelib
86d83787aa577b8f2d66b5410e73102411c45e46
[ "MIT" ]
4
2019-11-09T15:41:26.000Z
2021-10-10T08:56:57.000Z
with open('test.txt', 'rb') as f: data = f.read() for i in data: print(bin(i))
14.666667
33
0.545455
880671549d4c04b5d27e549879a16a8543f057a8
9,107
py
Python
rfvision/components/keypoint_head/topdown_heatmap_simple_head_3d.py
mvig-robotflow/rfvision
cc662f213dfe5a3e8864a6b5685a668a4436e397
[ "Apache-2.0" ]
6
2021-09-25T03:53:06.000Z
2022-02-19T03:25:11.000Z
rfvision/components/keypoint_head/topdown_heatmap_simple_head_3d.py
mvig-robotflow/rfvision
cc662f213dfe5a3e8864a6b5685a668a4436e397
[ "Apache-2.0" ]
1
2021-07-21T13:14:54.000Z
2021-07-21T13:14:54.000Z
rfvision/components/keypoint_head/topdown_heatmap_simple_head_3d.py
mvig-robotflow/rfvision
cc662f213dfe5a3e8864a6b5685a668a4436e397
[ "Apache-2.0" ]
2
2021-07-16T03:25:04.000Z
2021-11-22T06:04:01.000Z
# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import torch import torch.nn as nn from rfvision.components.keypoint_head import Heatmap3DHead, Heatmap1DHead, MultilabelClassificationHead from rfvision.core.evaluation_pose.top_down_eval import ( keypoints_from_heatmaps3d, multilabel_classificatio...
39.595652
164
0.596245
4603153d8a07c8b448a7663697769d82774f2128
2,896
py
Python
Backend/views/osm.py
dbvis-ukon/coronavis
f00374ac655c9d68541183d28ede6fe5536581dc
[ "Apache-2.0" ]
15
2020-04-24T20:18:11.000Z
2022-01-31T21:05:05.000Z
Backend/views/osm.py
dbvis-ukon/coronavis
f00374ac655c9d68541183d28ede6fe5536581dc
[ "Apache-2.0" ]
2
2021-05-19T07:15:09.000Z
2022-03-07T08:29:34.000Z
Backend/views/osm.py
dbvis-ukon/coronavis
f00374ac655c9d68541183d28ede6fe5536581dc
[ "Apache-2.0" ]
4
2020-04-27T16:20:13.000Z
2021-02-23T10:39:42.000Z
import json from flask import Blueprint, Response from cache import cache from db import db routes = Blueprint('osm', __name__, url_prefix='/osm') @routes.route('/hospitals', methods=['GET']) @cache.cached() def get_osm_hospitals(): """ Return all Hospitals """ sql_stmt = ''' SELECT ...
27.320755
115
0.55076
460b2eb45b5f31230811212c2fcbab1991156e35
1,088
py
Python
test/attack/inversion/test_m1face.py
luoshenseeker/AIJack
4e871a5b3beb4b7c976d38060d6956efcebf880d
[ "MIT" ]
1
2022-03-17T21:17:44.000Z
2022-03-17T21:17:44.000Z
test/attack/inversion/test_m1face.py
luoshenseeker/AIJack
4e871a5b3beb4b7c976d38060d6956efcebf880d
[ "MIT" ]
null
null
null
test/attack/inversion/test_m1face.py
luoshenseeker/AIJack
4e871a5b3beb4b7c976d38060d6956efcebf880d
[ "MIT" ]
1
2022-03-17T21:17:46.000Z
2022-03-17T21:17:46.000Z
def test_m1face(): import torch.nn as nn from aijack.attack import MI_FACE class LeNet(nn.Module): def __init__(self, channel=3, hideen=768, num_classes=10): super(LeNet, self).__init__() act = nn.Sigmoid self.body = nn.Sequential( nn.Conv2d(chan...
32
80
0.528493
1cca3574b5e24563e5285fc41e3bcb077f913b4c
1,181
py
Python
python_project/python/VisitFile.py
sinomiko/project
00fadb0033645f103692f5b06c861939a9d4aa0e
[ "BSD-3-Clause" ]
1
2018-12-30T14:07:42.000Z
2018-12-30T14:07:42.000Z
python_project/python/VisitFile.py
sinomiko/project
00fadb0033645f103692f5b06c861939a9d4aa0e
[ "BSD-3-Clause" ]
null
null
null
python_project/python/VisitFile.py
sinomiko/project
00fadb0033645f103692f5b06c861939a9d4aa0e
[ "BSD-3-Clause" ]
null
null
null
import os, sys listonly = False skipexts = ['.gif', '.exe', '.pyc', '.o', '.a','.dll','.lib','.pdb','.mdb'] # ignore binary files def visitfile(fname, searchKey): # for each non-dir file global fcount, vcount try: if not listonly: ...
35.787879
104
0.538527
98e076e060e37f0b013b43e6a439eb842a4ce549
460
py
Python
frappe-bench/apps/erpnext/erpnext/patches/v7_2/move_dates_from_salary_structure_to_employee.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/patches/v7_2/move_dates_from_salary_structure_to_employee.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/patches/v7_2/move_dates_from_salary_structure_to_employee.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
import frappe def execute(): frappe.reload_doc('hr', 'doctype', 'salary_structure_employee') salary_structures = frappe.db.sql("""select name, to_date, from_date from `tabSalary Structure`""", as_dict=True) for salary_structure in salary_structures: frappe.db.sql(""" update `tabSalary Structure Employee` set fro...
51.111111
114
0.754348
c728add72ed6a3c7e7a22d0dd5c2d28795629874
70,636
py
Python
paddlenlp/transformers/albert/modeling.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
paddlenlp/transformers/albert/modeling.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
paddlenlp/transformers/albert/modeling.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2021 PaddlePaddle Authors. All Rights Reserved. # Copyright 2018 Google AI, Google Brain and the HuggingFace Inc. team. # # 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 # # ...
38.305857
140
0.597641
c774342508651302ada9fdf0c1b47ad621db96d4
355
py
Python
Quizzes/QQUiz3/quiz3/code/server.py
robots-make-art-too/Donglin_yu
95eede21e94baf16db1770337234668a816a8056
[ "MIT" ]
null
null
null
Quizzes/QQUiz3/quiz3/code/server.py
robots-make-art-too/Donglin_yu
95eede21e94baf16db1770337234668a816a8056
[ "MIT" ]
null
null
null
Quizzes/QQUiz3/quiz3/code/server.py
robots-make-art-too/Donglin_yu
95eede21e94baf16db1770337234668a816a8056
[ "MIT" ]
null
null
null
import http.server import socketserver PORT = 8000 #8080, 8887, 8898, Handler = http.server.SimpleHTTPRequestHandler with socketserver.TCPServer(("", PORT), Handler) as httpd: print("Hi you are at PORT: ", PORT) httpd.serve_forever() # to run>: python3 server.py # might have to install the imports # pip/pip3 in...
22.1875
58
0.740845
4001f71b3bba515bc0b8fe1d9a7e7914ace5b61e
32,139
py
Python
tests/test_ownfunctions.py
S0S-90/geocachingTooly
a6ed356d0187dd517a9436a83bded3752d488db5
[ "MIT" ]
null
null
null
tests/test_ownfunctions.py
S0S-90/geocachingTooly
a6ed356d0187dd517a9436a83bded3752d488db5
[ "MIT" ]
null
null
null
tests/test_ownfunctions.py
S0S-90/geocachingTooly
a6ed356d0187dd517a9436a83bded3752d488db5
[ "MIT" ]
null
null
null
#!/usr/bin/python # -*- coding: utf-8 -*- """tests for ownfunctions.py""" import unittest import datetime import sys from io import StringIO import xml.etree.ElementTree as ElementTree import test_frame import ownfunctions class TestReplaceSigns(unittest.TestCase): def test_find_cp1252(self): test_fra...
46.713663
123
0.64081
4004c08df87b42e135938b32d01f2779da49ef8a
458
py
Python
leetcode/560-Subarray-Sum-Equals-K/cum_sum_1d_hash.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2017-05-18T06:11:02.000Z
2017-05-18T06:11:02.000Z
leetcode/560-Subarray-Sum-Equals-K/cum_sum_1d_hash.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-02-09T06:00:07.000Z
2016-02-09T07:20:13.000Z
leetcode/560-Subarray-Sum-Equals-K/cum_sum_1d_hash.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
2
2019-06-27T09:07:26.000Z
2019-07-01T04:40:13.000Z
class Solution: def subarraySum(self, nums: List[int], k: int) -> int: for i in range(1, len(nums)): nums[i] += nums[i - 1] cum_sums = [0] + nums cnt = 0 val_cnts = {0: 1} for i in range(1, len(cum_sums)): diff = cum_sums[i] - k if diff in...
28.625
68
0.484716
d3b55a3b9a85b07daf77ad362f949e4f868a29df
595
py
Python
src/using_tips/decorator/dec5.py
HuangHuaBingZiGe/GitHub-Demo
f3710f73b0828ef500343932d46c61d3b1e04ba9
[ "Apache-2.0" ]
null
null
null
src/using_tips/decorator/dec5.py
HuangHuaBingZiGe/GitHub-Demo
f3710f73b0828ef500343932d46c61d3b1e04ba9
[ "Apache-2.0" ]
null
null
null
src/using_tips/decorator/dec5.py
HuangHuaBingZiGe/GitHub-Demo
f3710f73b0828ef500343932d46c61d3b1e04ba9
[ "Apache-2.0" ]
null
null
null
def log1(func): def wrapper(area): print 'call %s():' % func.__name__ return func(area) return wrapper @log1 def now1(area): print area, '2016-01-23' now1('Beijing') print 'The name of function now1() is:', now1.__name__ print "=" * 25 def log2(func): def wrapper(a...
14.512195
48
0.583193
310167c13adc3d5c02434d2a61b90452bea65451
267
py
Python
euler-28.py
TFabijo/euler
58dc07b9adb236890556ccd5d75ca9dbd2b50df9
[ "MIT" ]
null
null
null
euler-28.py
TFabijo/euler
58dc07b9adb236890556ccd5d75ca9dbd2b50df9
[ "MIT" ]
null
null
null
euler-28.py
TFabijo/euler
58dc07b9adb236890556ccd5d75ca9dbd2b50df9
[ "MIT" ]
null
null
null
def vsota_diagonal_spirale_nxn(n): najvecje = n * n element = 1 vsota = 1 korak = 0 while element != najvecje: korak += 2 for x in range(4): element += korak vsota += element return vsota
19.071429
35
0.498127
3114c9827e2d211a3d26e14d0c79052ce02e2aff
1,373
py
Python
test/log_graph.py
saeyoung/tslb
5f52646260e14f44c61a670cfc75509951e5e794
[ "MIT" ]
null
null
null
test/log_graph.py
saeyoung/tslb
5f52646260e14f44c61a670cfc75509951e5e794
[ "MIT" ]
3
2020-03-24T18:18:21.000Z
2021-08-23T20:37:09.000Z
test/log_graph.py
saeyoung/tslb
5f52646260e14f44c61a670cfc75509951e5e794
[ "MIT" ]
null
null
null
############################################################# # # Log(k*i) graph # ############################################################# import sys, os sys.path.append("../..") sys.path.append("..") sys.path.append(os.getcwd()) import numpy as np import pandas as pd import copy import pickle from math import l...
24.517857
68
0.443554
48eb5cfd171034762ec496e3d2bb28db3761c892
5,602
py
Python
marsyas-vamp/marsyas/scripts/large-evaluators/tempo-reference-implementation/tempo_stem_file.py
jaouahbi/VampPlugins
27c2248d1c717417fe4d448cdfb4cb882a8a336a
[ "Apache-2.0" ]
null
null
null
marsyas-vamp/marsyas/scripts/large-evaluators/tempo-reference-implementation/tempo_stem_file.py
jaouahbi/VampPlugins
27c2248d1c717417fe4d448cdfb4cb882a8a336a
[ "Apache-2.0" ]
null
null
null
marsyas-vamp/marsyas/scripts/large-evaluators/tempo-reference-implementation/tempo_stem_file.py
jaouahbi/VampPlugins
27c2248d1c717417fe4d448cdfb4cb882a8a336a
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python SHORT_DEBUG = 0 import sys import os import pickle import numpy import scipy.io.wavfile import scipy.signal import pylab import mar_collection import onset_strength import beat_histogram import beat_phase import late_heuristic import evaluate_bpms def load_wavfile(filename): sample_rat...
29.329843
87
0.598715
d2a53e8b43770851648a1da5303a76c619a39020
6,516
py
Python
paddlenlp/datasets/conll2002.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
paddlenlp/datasets/conll2002.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
paddlenlp/datasets/conll2002.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...
36.813559
119
0.477594
960b64430cdac1e0ef8505107509dab6848ace29
591
py
Python
Python/Buch_ATBS/Teil_2/Kapitel_11_Webscraping/06_scraping_mit_beatifulsoup.py
Apop85/Scripts
e71e1c18539e67543e3509c424c7f2d6528da654
[ "MIT" ]
null
null
null
Python/Buch_ATBS/Teil_2/Kapitel_11_Webscraping/06_scraping_mit_beatifulsoup.py
Apop85/Scripts
e71e1c18539e67543e3509c424c7f2d6528da654
[ "MIT" ]
6
2020-12-24T15:15:09.000Z
2022-01-13T01:58:35.000Z
Python/Buch_ATBS/Teil_2/Kapitel_11_Webscraping/06_scraping_mit_beatifulsoup.py
Apop85/Scripts
1d8dad316c55e1f1343526eac9e4b3d0909e4873
[ "MIT" ]
null
null
null
# 06_scraping_mit_beatifulsoup.py # Dies ist ein Beispiel wie man mit BeautifullSoup eine Webseite durchforsten kann. # Dazu muss das Modul beautifullsoup4 installiert sein. Ggf mit pip3 install beautifulsoup4 nachinstallieren import requests, bs4 url_name='https://de.wikipedia.org/wiki/Aspirin' url_content=requests....
31.105263
108
0.800338
82db146c18e96e0d188dae9a1bca11de4cc27d22
120
py
Python
quant/tool/email_test.py
doubleDragon/QuantBot
53a1d6c62ecece47bf777da0c0754430b706b7fd
[ "MIT" ]
7
2017-10-22T15:00:09.000Z
2019-09-19T11:45:43.000Z
quant/tool/email_test.py
doubleDragon/QuantBot
53a1d6c62ecece47bf777da0c0754430b706b7fd
[ "MIT" ]
1
2018-01-19T16:19:40.000Z
2018-01-19T16:19:40.000Z
quant/tool/email_test.py
doubleDragon/QuantBot
53a1d6c62ecece47bf777da0c0754430b706b7fd
[ "MIT" ]
5
2017-12-11T15:10:29.000Z
2018-12-21T17:40:58.000Z
#!/usr/bin/env python # -*- coding: UTF-8 -*- from .email_box import send_mail send_mail('test content ssl success')
15
37
0.691667
c4d728f33da80049ac2fedb84ad629f8ddd9f504
514
py
Python
leetcode/322-Coin-Change/CoinChange_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2015-12-16T04:01:03.000Z
2015-12-16T04:01:03.000Z
leetcode/322-Coin-Change/CoinChange_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-02-09T06:00:07.000Z
2016-02-09T07:20:13.000Z
leetcode/322-Coin-Change/CoinChange_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
2
2019-06-27T09:07:26.000Z
2019-07-01T04:40:13.000Z
class Solution(object): def coinChange(self, coins, amount): """ :type coins: List[int] :type amount: int :rtype: int """ coins.sort() dp = [amount + 1 for i in range(amount + 1)] dp[0] = 0 for i in xrange(1, amount + 1): for c in c...
27.052632
53
0.406615
c4f5434164e058b88f10b4269ee3fbde1660f56a
13,908
py
Python
fhirclient/r4models/composition.py
Healthedata1/Flask-PL
88a2f40ca430c4cbb9fbded7fc92fdc166ebb9f1
[ "MIT" ]
null
null
null
fhirclient/r4models/composition.py
Healthedata1/Flask-PL
88a2f40ca430c4cbb9fbded7fc92fdc166ebb9f1
[ "MIT" ]
null
null
null
fhirclient/r4models/composition.py
Healthedata1/Flask-PL
88a2f40ca430c4cbb9fbded7fc92fdc166ebb9f1
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Generated from FHIR 4.0.0-a53ec6ee1b (http://hl7.org/fhir/StructureDefinition/Composition) on 2019-05-07. # 2019, SMART Health IT. from . import domainresource class Composition(domainresource.DomainResource): """ A set of resources composed into a si...
40.430233
109
0.604976
f208857a3833206f286d8456620ddf219c9ee140
71
py
Python
python/tutlibs/tree.py
Obarads/Point_Cloud_Tutorial
faf7ae8abf962ecea414cc7557dc35f4fca0e406
[ "MIT" ]
1
2021-11-22T10:32:49.000Z
2021-11-22T10:32:49.000Z
python/tutlibs/tree.py
Obarads/Point_Cloud_Tutorial
faf7ae8abf962ecea414cc7557dc35f4fca0e406
[ "MIT" ]
1
2021-12-09T14:39:51.000Z
2021-12-09T14:39:51.000Z
python/tutlibs/tree.py
Obarads/Point_Cloud_Tutorial
faf7ae8abf962ecea414cc7557dc35f4fca0e406
[ "MIT" ]
null
null
null
import numpy as np def kdtree(): pass def octree(): return
7.1
18
0.605634
d250bd143e49c782b0eed2896a6d4559de248fa3
3,414
py
Python
Contrib-Inspur/openbmc/poky/bitbake/lib/toaster/tests/browser/test_new_project_page.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/browser/test_new_project_page.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/browser/test_new_project_page.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 Implementation # # Copyright (C) 2013-2016 Intel Corporation # # SPDX-License-Identifier: GPL-2.0-only # from django.core.urlresolvers import reverse from tests.browser.selenium_helpers import SeleniumTestCase from selenium.webdriver.support.ui import Select from selenium.com...
33.470588
76
0.591095
96bcd1882fc2a648e05916dea07e2036d6cfdb59
1,155
py
Python
kts/ui/dashboard.py
konodyuk/kts
3af5ccbf1d2089cb41d171626fcde4b0ba5aa8a7
[ "MIT" ]
18
2019-02-14T13:10:07.000Z
2021-11-26T07:10:13.000Z
kts/ui/dashboard.py
konodyuk/kts
3af5ccbf1d2089cb41d171626fcde4b0ba5aa8a7
[ "MIT" ]
2
2019-02-17T14:06:42.000Z
2019-09-15T18:05:54.000Z
kts/ui/dashboard.py
konodyuk/kts
3af5ccbf1d2089cb41d171626fcde4b0ba5aa8a7
[ "MIT" ]
2
2019-09-15T13:12:42.000Z
2020-04-15T14:05:54.000Z
from IPython.display import display from kts.settings import cfg from kts.ui.components import Column, Pool, HTMLRepr, Title, Annotation, CSS, Raw, Field class Dashboard(HTMLRepr): def __init__(self): from kts.core.lists import feature_list, helper_list self.features = feature_list self.h...
37.258065
115
0.651082
7365494339fa5ebfc1223188e38130f75bdbb4a1
1,781
py
Python
tarefas-poo/lista-03/prefeitura/view/paineis/painel_cria_prefeitura.py
victoriaduarte/POO_UFSC
0c65b4f26383d1e3038d8469bd91fd2c0cb98c1a
[ "MIT" ]
null
null
null
tarefas-poo/lista-03/prefeitura/view/paineis/painel_cria_prefeitura.py
victoriaduarte/POO_UFSC
0c65b4f26383d1e3038d8469bd91fd2c0cb98c1a
[ "MIT" ]
null
null
null
tarefas-poo/lista-03/prefeitura/view/paineis/painel_cria_prefeitura.py
victoriaduarte/POO_UFSC
0c65b4f26383d1e3038d8469bd91fd2c0cb98c1a
[ "MIT" ]
null
null
null
# -------------------------- # UFSC - CTC - INE - INE5663 # Exercício da Prefeitura # -------------------------- # Classe que permite a criação de uma prefeitura # from model.gera_populacao import gera_populacao_aleatoria, gera_populacao_fixa from model.prefeitura import Prefeitura from model.cidadao import Cidadao c...
38.717391
78
0.617631
73ce8eb0cd79a7f2e813e116f699f3ce7efc533a
734
py
Python
zencad/examples/1.GeomPrim/2.prim2d/circle.py
Spiritdude/zencad
4e63b1a6306dd235f4daa2791b10249f7546c95b
[ "MIT" ]
5
2018-04-11T14:11:40.000Z
2018-09-12T19:03:36.000Z
zencad/examples/1.GeomPrim/2.prim2d/circle.py
Spiritdude/zencad
4e63b1a6306dd235f4daa2791b10249f7546c95b
[ "MIT" ]
null
null
null
zencad/examples/1.GeomPrim/2.prim2d/circle.py
Spiritdude/zencad
4e63b1a6306dd235f4daa2791b10249f7546c95b
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 """ ZenCad API example: circle last update: 04.10.2019 """ from zencad import * m0 = circle(r=10) m1 = circle(r=10, angle=deg(90)) m2 = circle(r=10, angle=(deg(45), deg(90))) m3 = circle(r=10, wire=True) m4 = circle(r=10, angle=deg(90), wire=True) m5 = circle(r=10, angle=(deg(45), deg(90)), wi...
22.242424
54
0.656676
f774a591067741353b230217c694759cfc9db504
272,398
py
Python
spam-smsv2-main/sms.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-17T03:35:03.000Z
2021-12-08T06:00:31.000Z
spam-smsv2-main/sms.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
null
null
null
spam-smsv2-main/sms.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-05T18:07:48.000Z
2022-02-24T21:25:07.000Z
# Compile by Sanz # Youtube : FREE TUTORIAL # Github : https://github.com/Sxp-ID # Mau recode ya? Izin dulu Slur >_< sanz=((lambda _____, ______ : ______(eval((lambda ____,__,_ : ____.join([_(___) for ___ in __]))('',[95, 95, 105, 109, 112, 111, 114, 116, 95, 95, 40, 34, 122, 108, 105, 98, 34, 41, 46, 100, 101, 99, 11...
45,399.666667
272,279
0.73531
54757b97e584c7e8d5d8fad446c6b3796a0a7e91
574
py
Python
models/hr_employee_note.py
aroodooteam/aro_hr
bf26f026593493486b4b5c13b26b9b47b9fe3825
[ "BSD-2-Clause" ]
null
null
null
models/hr_employee_note.py
aroodooteam/aro_hr
bf26f026593493486b4b5c13b26b9b47b9fe3825
[ "BSD-2-Clause" ]
null
null
null
models/hr_employee_note.py
aroodooteam/aro_hr
bf26f026593493486b4b5c13b26b9b47b9fe3825
[ "BSD-2-Clause" ]
3
2017-09-11T08:02:11.000Z
2020-04-04T08:13:23.000Z
# -*- coding: utf-8 -*- from openerp import api, exceptions, fields, models class HrEmployeeNote(models.Model): """Gestion des notes des employes""" _name = 'hr.employee.note' _description = "Employee Note" employee_id = fields.Many2one(comodel_name='hr.employee', string='Employe') annee = field...
35.875
120
0.606272
b77b640cb760a84323bac90b3f56823f8785208c
3,875
py
Python
examples/language_model/moe/dygraph/checkpointing.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
examples/language_model/moe/dygraph/checkpointing.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
examples/language_model/moe/dygraph/checkpointing.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 applic...
37.621359
79
0.653935
423dceb7be42eb1e04361bca1188e323bf3a1163
2,241
py
Python
Chapter9_AdvancedDL/Chapter9_5_RegressionProblems/taxiRoutingDnn.py
thisisjako/UdemyTF
ee4102391ed6bd50f764955f732f5740425a9209
[ "MIT" ]
null
null
null
Chapter9_AdvancedDL/Chapter9_5_RegressionProblems/taxiRoutingDnn.py
thisisjako/UdemyTF
ee4102391ed6bd50f764955f732f5740425a9209
[ "MIT" ]
null
null
null
Chapter9_AdvancedDL/Chapter9_5_RegressionProblems/taxiRoutingDnn.py
thisisjako/UdemyTF
ee4102391ed6bd50f764955f732f5740425a9209
[ "MIT" ]
null
null
null
import os import tensorflow as tf from tensorflow.keras.layers import Activation from tensorflow.keras.layers import Dense from tensorflow.keras.models import Sequential from tensorflow.keras.optimizers import Adam from tf_utils.taxiRoutingDataAdvanced import TAXIROUTING EXCEL_FILE_PATH = os.path.abspath("C:/Users/...
27
102
0.701473
673b572a195c42c274eba40f32daaf583dfd94cf
2,580
py
Python
autoLogin.py
pchaos/wanggejiaoyi
60242d465bf10d4be46ee6eafc99557affc2a52e
[ "MIT" ]
15
2018-05-16T02:39:01.000Z
2021-05-22T13:12:55.000Z
autoLogin.py
pchaos/wanggejiaoyi
60242d465bf10d4be46ee6eafc99557affc2a52e
[ "MIT" ]
null
null
null
autoLogin.py
pchaos/wanggejiaoyi
60242d465bf10d4be46ee6eafc99557affc2a52e
[ "MIT" ]
9
2018-05-16T00:47:34.000Z
2021-11-26T05:39:48.000Z
# -*- coding: utf-8 -*- """ ------------------------------------------------- @File : autoLogin.py Description : 自动登录华泰客户端 @Author : pchaos date: 18-4-16 ------------------------------------------------- Change Activity: 18-4-16: @Contact : p19992003#gmail.com ---...
30.714286
116
0.628295
db2d1e5ee8999153d3d8652d45bc17e16a4930d4
1,520
py
Python
ebenezer/atencion/migrations/0002_auto_20181005_0031.py
davrv93/ebenezer-backend
d3db4dafd9a8c35bea9f32afe2be1dd451f64298
[ "Apache-2.0" ]
null
null
null
ebenezer/atencion/migrations/0002_auto_20181005_0031.py
davrv93/ebenezer-backend
d3db4dafd9a8c35bea9f32afe2be1dd451f64298
[ "Apache-2.0" ]
3
2020-02-11T23:15:00.000Z
2021-06-10T20:52:17.000Z
ebenezer/atencion/migrations/0002_auto_20181005_0031.py
davrv93/ebenezer-backend
d3db4dafd9a8c35bea9f32afe2be1dd451f64298
[ "Apache-2.0" ]
null
null
null
# Generated by Django 2.1.2 on 2018-10-05 00:31 from django.db import migrations, models import django.db.models.deletion import uuid class Migration(migrations.Migration): dependencies = [ ('atencion', '0001_initial'), ] operations = [ migrations.CreateModel( name='Clase', ...
37.073171
237
0.580921
c04af8e419b996092094b83928cc9193afd8cc39
15,214
py
Python
Python/Courses/LearnToCodeInPython3ProgrammingBeginnerToAdvancedYourProgress/python_course/Section4Modules/30Requests.py
JamieBort/LearningDirectory
afca79c5f1333c079d0e96202ff44ca21b2ceb81
[ "Info-ZIP" ]
1
2022-02-02T21:56:08.000Z
2022-02-02T21:56:08.000Z
Python/Courses/LearnToCodeInPython3ProgrammingBeginnerToAdvancedYourProgress/python_course/Section4Modules/30Requests.py
JamieBort/LearningDirectory
afca79c5f1333c079d0e96202ff44ca21b2ceb81
[ "Info-ZIP" ]
27
2020-06-27T23:25:59.000Z
2022-02-27T20:40:56.000Z
Python/Courses/LearnToCodeInPython3ProgrammingBeginnerToAdvancedYourProgress/python_course/Section4Modules/30Requests.py
JamieBort/LearningDirectory
afca79c5f1333c079d0e96202ff44ca21b2ceb81
[ "Info-ZIP" ]
null
null
null
# NOTE: The files # ./LearningDirectory/Python/LearnToCodeInPython3ProgrammingBeginnerToAdvancedYourProgress/python_course/Section4Modules/30Requests.py # ./LearningDirectory/Python/LearnToCodeInPython3ProgrammingBeginnerToAdvancedYourProgress/python_course/Section4Modules/31SendingHTTPRequestsToAPIs.py # and # ./Learn...
353.813953
12,721
0.729854
222e049d4149be84ebb4208d313ad06fd83d1127
5,132
py
Python
convertor.py
FlyingFishBird/msmt
1278d4a6af3d54aa477d7c99d053549b1b80b2fa
[ "MIT" ]
null
null
null
convertor.py
FlyingFishBird/msmt
1278d4a6af3d54aa477d7c99d053549b1b80b2fa
[ "MIT" ]
null
null
null
convertor.py
FlyingFishBird/msmt
1278d4a6af3d54aa477d7c99d053549b1b80b2fa
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from functools import partial import json import sys from datetime import datetime _ISPY2 = sys.version_info.major == 2 def _encode(data): if _ISPY2 and isinstance(data, unicode): return data.encode('utf-8') return data def _convert(src_parser, dst_parser, data): return ...
22.910714
78
0.533905
3f358298ab201dd0041538d0b62ed4a8df31fdb9
86
py
Python
packages/watchmen-inquiry-kernel/src/watchmen_inquiry_kernel/meta/__init__.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-inquiry-kernel/src/watchmen_inquiry_kernel/meta/__init__.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-inquiry-kernel/src/watchmen_inquiry_kernel/meta/__init__.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
from .report_service import ReportService from .subject_service import SubjectService
28.666667
43
0.883721
452a91dad76c1ad3a2539b4d6af801a9c96bfe73
4,003
py
Python
server/objects/driver.py
khaledelemam/routescc-matching-app
81cb0665e08f6608176060f5d768c673fed15398
[ "MIT" ]
null
null
null
server/objects/driver.py
khaledelemam/routescc-matching-app
81cb0665e08f6608176060f5d768c673fed15398
[ "MIT" ]
null
null
null
server/objects/driver.py
khaledelemam/routescc-matching-app
81cb0665e08f6608176060f5d768c673fed15398
[ "MIT" ]
null
null
null
import csv from datetime import datetime from server.data.address_store import AddressStore from server.maps_api import get_coordinates, google_api_key from server.objects.person import Person from server.objects.rides import Ride class Driver(Person): def __init__(self, first_name: str, last_name: str, phone: ...
38.12381
118
0.642018
7a08de6de30cda029a9a8dd75693e3589937db4b
8,662
py
Python
EX5/CNN.py
CSUpengyuyan/DLExperiment
4b4d8384215da85cca1915b5630dbf3fbb381b38
[ "MIT" ]
null
null
null
EX5/CNN.py
CSUpengyuyan/DLExperiment
4b4d8384215da85cca1915b5630dbf3fbb381b38
[ "MIT" ]
null
null
null
EX5/CNN.py
CSUpengyuyan/DLExperiment
4b4d8384215da85cca1915b5630dbf3fbb381b38
[ "MIT" ]
1
2021-05-11T09:29:28.000Z
2021-05-11T09:29:28.000Z
import matplotlib.pyplot as plt import tensorflow as tf import numpy as np import math import keras import h5py from keras.models import Sequential from keras.layers import InputLayer,Input,MaxPooling2D,Conv2D,Dense,Flatten,Reshape,Convolution2D from keras.optimizers import adam from keras.utils import to_categorical f...
28.214984
97
0.667975
e14a07e7cf898ec7c19236d8370d82398950d5cd
452
py
Python
roman-to-integer/roman-to-integer.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
2
2021-12-05T14:29:06.000Z
2022-01-01T05:46:13.000Z
roman-to-integer/roman-to-integer.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
null
null
null
roman-to-integer/roman-to-integer.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
null
null
null
class Solution: def romanToInt(self, s: str) -> int: roman2int={"I":1, "V": 5, "X": 10, "L": 50, "C":100, "D": 500, "M":1000} output = 0 cur_int = roman2int[s[0]] for next_str in s[1:]: if cur_int>=roman2int[next_str]: output+=cur_int else: ...
32.285714
80
0.482301
83319e0f72e47fbfaae22c7e59d6939d3cd61eb1
2,277
py
Python
Python/Sonstige_Uebungen/fractal_like/spiral_fractal_turtle.py
Apop85/Scripts
e71e1c18539e67543e3509c424c7f2d6528da654
[ "MIT" ]
null
null
null
Python/Sonstige_Uebungen/fractal_like/spiral_fractal_turtle.py
Apop85/Scripts
e71e1c18539e67543e3509c424c7f2d6528da654
[ "MIT" ]
6
2020-12-24T15:15:09.000Z
2022-01-13T01:58:35.000Z
Python/Sonstige_Uebungen/fractal_like/spiral_fractal_turtle.py
Apop85/Scripts
1d8dad316c55e1f1343526eac9e4b3d0909e4873
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding:utf-8 -*- ### # File: spiral_fractal_turtle.py # Project: Sonstige_Uebungen # Created Date: Thursday 28.02.2019, 13:39 # Author: Apop85 # ----- # Last Modified: Thursday 28.02.2019, 19:27 # ----- # Copyright (c) 2019 Apop85 # This software is published under the MIT license. # Check ...
23
82
0.543698
833a2df2777fb2574e6a30daee0f6a7f9c41914d
195
py
Python
Online-Judges/CodingBat/Python/Logic-01/Logic_1-08-in1to10.py
shihab4t/Competitive-Programming
e8eec7d4f7d86bfa1c00b7fbbedfd6a1518f19be
[ "Unlicense" ]
3
2021-06-15T01:19:23.000Z
2022-03-16T18:23:53.000Z
Online-Judges/CodingBat/Python/Logic-01/Logic_1-08-in1to10.py
shihab4t/Competitive-Programming
e8eec7d4f7d86bfa1c00b7fbbedfd6a1518f19be
[ "Unlicense" ]
null
null
null
Online-Judges/CodingBat/Python/Logic-01/Logic_1-08-in1to10.py
shihab4t/Competitive-Programming
e8eec7d4f7d86bfa1c00b7fbbedfd6a1518f19be
[ "Unlicense" ]
null
null
null
def in1to10(n, outside_mode): if outside_mode is True and (n <= 1 or n >= 10): return True elif outside_mode is False and n <= 10 and n >= 1: return True return False
27.857143
54
0.605128
8345a459052f67e75d629cd93afc33854d17a070
1,669
py
Python
writing prompts/script.py
graylion-wa/world-anvil-generators
f9718517b95997b6dfbc9ab6370d03ab87e40601
[ "MIT" ]
1
2021-06-08T17:34:24.000Z
2021-06-08T17:34:24.000Z
writing prompts/script.py
graylion-wa/world-anvil-generators
f9718517b95997b6dfbc9ab6370d03ab87e40601
[ "MIT" ]
2
2021-06-23T07:58:38.000Z
2021-06-28T18:00:18.000Z
writing prompts/script.py
graylion-wa/world-anvil-generators
f9718517b95997b6dfbc9ab6370d03ab87e40601
[ "MIT" ]
1
2021-06-19T10:03:06.000Z
2021-06-19T10:03:06.000Z
import csv import json from typing import Any def write_file(data: Any, filename: str): with open(f'{filename}.json', 'w') as fp: json.dump(data, fp, ensure_ascii=False, indent=' ') def create_payload_dict(variable: str): router = dict() router[variable] = dict() return router, router[var...
39.738095
112
0.680048
8349336c0a5ac26f2ec195bf1ae69aeb1cae29bb
1,264
py
Python
deutschland/ladestationen/models/__init__.py
kiranmusze/deutschland
86d8ead3f38ad88ad66bb338b9f5a8db06992344
[ "Apache-2.0" ]
null
null
null
deutschland/ladestationen/models/__init__.py
kiranmusze/deutschland
86d8ead3f38ad88ad66bb338b9f5a8db06992344
[ "Apache-2.0" ]
null
null
null
deutschland/ladestationen/models/__init__.py
kiranmusze/deutschland
86d8ead3f38ad88ad66bb338b9f5a8db06992344
[ "Apache-2.0" ]
null
null
null
# flake8: noqa # import all models into this package # if you have many models here with many references from one model to another this may # raise a RecursionError # to avoid this, import only the models that you directly need like: # from from deutschland.ladestationen.model.pet import Pet # or import this package, ...
38.30303
88
0.837816
3614ca2551cc223c2fb1ff7fb6102fe7dcf4bf0a
172
py
Python
basics/booleans.py
karinakozarova/Learning-Python
217dfc8ca6931a238445daf0b84e188c02916c52
[ "MIT" ]
1
2019-04-07T23:14:29.000Z
2019-04-07T23:14:29.000Z
basics/booleans.py
karinakozarova/Learning-Python
217dfc8ca6931a238445daf0b84e188c02916c52
[ "MIT" ]
null
null
null
basics/booleans.py
karinakozarova/Learning-Python
217dfc8ca6931a238445daf0b84e188c02916c52
[ "MIT" ]
null
null
null
# Hi! I'm Maria and I live in script.py. # I'm an expert Python coder. # I'm 21 years old and I plan to program cool stuff forever. age_is_12 = False name_is_maria = True
24.571429
60
0.72093
7fe4b785629e9c5769c878b7b732c2ba8d8f49c1
2,497
py
Python
pocketthrone/tools/unitmovementhelper.py
herrschr/pocket-throne
819ebae250f45b0a4b15a8320e2836c0b5113528
[ "BSD-2-Clause" ]
4
2016-06-05T16:48:04.000Z
2020-03-23T20:06:06.000Z
pocketthrone/tools/unitmovementhelper.py
herrschr/pocket-throne
819ebae250f45b0a4b15a8320e2836c0b5113528
[ "BSD-2-Clause" ]
null
null
null
pocketthrone/tools/unitmovementhelper.py
herrschr/pocket-throne
819ebae250f45b0a4b15a8320e2836c0b5113528
[ "BSD-2-Clause" ]
null
null
null
from pocketthrone.entities.tile import Tile from pocketthrone.entities.tilemap import TileMap from pocketthrone.entities.unit import Unit class UnitMovementHelper: unit = None tilemap = None ingore_lds = False def __init__(self, unit, tilemap, ignore_lds=False): self.unit = unit self.tilemap = tilemap self....
26.56383
73
0.681217
7ff333ecc85c2f4d23ec50ee9a1eff2b63fe3e61
109
py
Python
nz_crawl_demo/day11/first_celery/apps/task2.py
gaohj/nzflask_bbs
36a94c380b78241ed5d1e07edab9618c3e8d477b
[ "Apache-2.0" ]
null
null
null
nz_crawl_demo/day11/first_celery/apps/task2.py
gaohj/nzflask_bbs
36a94c380b78241ed5d1e07edab9618c3e8d477b
[ "Apache-2.0" ]
27
2020-02-12T07:55:58.000Z
2022-03-12T00:19:09.000Z
nz_crawl_demo/day11/first_celery/django_celery/first_celery/apps/task2.py
gaohj/nzflask_bbs
36a94c380b78241ed5d1e07edab9618c3e8d477b
[ "Apache-2.0" ]
2
2020-02-18T01:54:55.000Z
2020-02-21T11:36:28.000Z
from apps import app # @app.task(queue='task2_add3') @app.task def add3(x,y): print(x-y) return x-y
13.625
31
0.642202
629e6a981a2819e2db9629f05300981bbc071739
1,077
py
Python
ppyt/indicators/direction_indicators.py
yusukemurayama/ppytrading
9804d0de870d77bf8a1c847736a636b1342d4600
[ "MIT" ]
4
2016-08-16T07:47:15.000Z
2017-12-11T10:08:47.000Z
ppyt/indicators/direction_indicators.py
yusukemurayama/ppytrading
9804d0de870d77bf8a1c847736a636b1342d4600
[ "MIT" ]
null
null
null
ppyt/indicators/direction_indicators.py
yusukemurayama/ppytrading
9804d0de870d77bf8a1c847736a636b1342d4600
[ "MIT" ]
2
2018-06-15T04:43:15.000Z
2020-05-02T07:47:15.000Z
# coding: utf-8 import logging import numpy as np from ppyt.indicators import IndicatorBase from ppyt.indicators.basic_indicators import MovingAverageIndicator from ppyt import const logger = logging.getLogger(__name__) class MADirectionIndicator(IndicatorBase): """移動平均線の向きを表す指標です。""" _findkey = '移動平均線の向き' ...
29.916667
67
0.608171
9aa54b3839f98e9ef37acdbf3e72599be44fa8ba
2,246
py
Python
test/test_npu/test_network_ops/test_pooling.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_pooling.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_pooling.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...
39.403509
88
0.709706
b112c9aefebe3afda5277aeb086fe4f10a8d6227
1,470
py
Python
loesungsvorschlaege/python_wiederholung/praxis/wdh_1.py
severinhaller/einf-machinelearning
4dfc8f1da0d81c5aa800d1459f81b72d1bf6dd9b
[ "MIT" ]
null
null
null
loesungsvorschlaege/python_wiederholung/praxis/wdh_1.py
severinhaller/einf-machinelearning
4dfc8f1da0d81c5aa800d1459f81b72d1bf6dd9b
[ "MIT" ]
null
null
null
loesungsvorschlaege/python_wiederholung/praxis/wdh_1.py
severinhaller/einf-machinelearning
4dfc8f1da0d81c5aa800d1459f81b72d1bf6dd9b
[ "MIT" ]
null
null
null
# Lösungen zu den Kurzaufgaben (Abschnitt 3) # Aufgabe 1 t1 = type(42) print(f"Der Typ von 42 lautet: {t1}") t2 = type(4.2) print(f"Der Typ von 4.2 lautet: {t2}") t3 = type("42") print(f"Der Typ von \"42\" lautet: {t3}") # Es gibt hier einen Fehler. Die Funktion type erwartet ein Argument (Übergabewert). # Durch das K...
23.709677
84
0.663946
b8c7b02dc9e41de4269d2455545ae26fef7cfd58
1,145
py
Python
quant/api/bitflyer.py
doubleDragon/QuantBot
53a1d6c62ecece47bf777da0c0754430b706b7fd
[ "MIT" ]
7
2017-10-22T15:00:09.000Z
2019-09-19T11:45:43.000Z
quant/api/bitflyer.py
doubleDragon/QuantBot
53a1d6c62ecece47bf777da0c0754430b706b7fd
[ "MIT" ]
1
2018-01-19T16:19:40.000Z
2018-01-19T16:19:40.000Z
quant/api/bitflyer.py
doubleDragon/QuantBot
53a1d6c62ecece47bf777da0c0754430b706b7fd
[ "MIT" ]
5
2017-12-11T15:10:29.000Z
2018-12-21T17:40:58.000Z
import requests class PublicClient(object): """ document: https://lightning.bitflyer.jp/docs """ def __init__(self): self.public_url = "https://api.bitflyer.com/v1" def url_for(self, path): url = "%s/%s" % (self.public_url, path) return url @classmethod def _get(...
26.627907
66
0.561572
6263c07c7bfb27caa4fb8d0d5ff82117a2cedc5b
4,078
py
Python
Apps/Dalphi Service/lib/iteration_processing.py
RGreinacher/bachelor-thesis
60dbc03ce40e3ec42f2538d67a6aabfea6fbbfc8
[ "MIT" ]
1
2021-04-13T10:00:46.000Z
2021-04-13T10:00:46.000Z
Apps/Dalphi Service/lib/iteration_processing.py
RGreinacher/bachelor-thesis
60dbc03ce40e3ec42f2538d67a6aabfea6fbbfc8
[ "MIT" ]
null
null
null
Apps/Dalphi Service/lib/iteration_processing.py
RGreinacher/bachelor-thesis
60dbc03ce40e3ec42f2538d67a6aabfea6fbbfc8
[ "MIT" ]
null
null
null
#!/usr/local/bin/python3.5 # -*- coding: utf-8 -*- # import python libs from pprint import pprint as pp import base64 import json import logging import copy # import project libs # - # defining globals & constants SUBJECTS_TABEL_JSON = '/Users/rg/Nextcloud/Uni/Bachelorarbeit/Apps/Vorverarbeitung/subjects_table.jso...
31.369231
127
0.628985
6571bf344543943d5cc62e560e59a131ded80365
3,489
py
Python
haas_lib_bundles/python/docs/examples/tap_detection/esp32/code/tap_detection.py
wstong999/AliOS-Things
6554769cb5b797e28a30a4aa89b3f4cb2ef2f5d9
[ "Apache-2.0" ]
null
null
null
haas_lib_bundles/python/docs/examples/tap_detection/esp32/code/tap_detection.py
wstong999/AliOS-Things
6554769cb5b797e28a30a4aa89b3f4cb2ef2f5d9
[ "Apache-2.0" ]
null
null
null
haas_lib_bundles/python/docs/examples/tap_detection/esp32/code/tap_detection.py
wstong999/AliOS-Things
6554769cb5b797e28a30a4aa89b3f4cb2ef2f5d9
[ "Apache-2.0" ]
null
null
null
import utime # 延时函数在utime ITER_NUM = 100 class tap_detection: def __init__(self, mpu6886Dev): self.mpu6886Dev = mpu6886Dev self.ax_offset = 0.0 self.ay_offset = 0.0 self.az_offset = 0.0 self.triggercount = 0 self.untriggercount = 0 self.tapcount = 0 ...
34.89
121
0.567498
659f04ad0c01d4e877d92c06bbb881411cd9e6be
4,773
py
Python
7-assets/past-student-repos/Graphs-Notes-master/graphs.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
7-assets/past-student-repos/Graphs-Notes-master/graphs.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
7-assets/past-student-repos/Graphs-Notes-master/graphs.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
def bfs(self, starting_vertex, destination_vertex): #Create an empty set to store the visited vertices visited = set() # Create an empty Queue and enqueue & PATH TO the starting vertex q = Queue() q.enqueue( [starting_vertex] ) # While the queue is not empty... while q.size() > 0: # ...
35.887218
140
0.588519