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
7f81cad269f4920002d56c47d0f77925f13fbaea
1,164
py
Python
Abiturklassen/Python/queue.py
jneug/schule-projekte
4f1d56d6bb74a47ca019cf96d2d6cc89779803c9
[ "MIT" ]
2
2020-09-24T12:11:16.000Z
2022-03-31T04:47:24.000Z
Abiturklassen/Python/queue.py
jneug/schule-projekte
4f1d56d6bb74a47ca019cf96d2d6cc89779803c9
[ "MIT" ]
1
2021-02-27T15:06:27.000Z
2021-03-01T16:32:48.000Z
Abiturklassen/Python/queue.py
jneug/schule-projekte
4f1d56d6bb74a47ca019cf96d2d6cc89779803c9
[ "MIT" ]
1
2021-02-24T05:12:35.000Z
2021-02-24T05:12:35.000Z
# -*- coding: utf-8 -*- class Queue(object): class QueueNode(object): def __init__(self, pContent): self._content = pContent self._nextNode = None def setNext(self, pNext): self._nextNode = pNext def getNext(self): return self._nextNode ...
24.25
46
0.515464
63fd495745a6172d50f8b9bec2eadfbe20720422
1,313
py
Python
preprocessing/normalization.py
mWollenhaupt/Mask_R-CNN_3D-Buildings
220f20b41a7290a01c0bb47672453e646254f8fc
[ "MIT" ]
2
2021-05-20T22:49:28.000Z
2021-06-16T06:35:07.000Z
preprocessing/normalization.py
mWollenhaupt/Mask_R-CNN_3D-Buildings
220f20b41a7290a01c0bb47672453e646254f8fc
[ "MIT" ]
null
null
null
preprocessing/normalization.py
mWollenhaupt/Mask_R-CNN_3D-Buildings
220f20b41a7290a01c0bb47672453e646254f8fc
[ "MIT" ]
null
null
null
import skimage.io import skimage.filters import numpy as np def normalize(image, norm="uint8", kernel_size=3): def normalize_to_uint16(image, steps_per_meter=3.): # No effect on training performance image *= steps_per_meter return image.astype(np.uint16) def normalize_to_uint8(image): # 8 bit s...
34.552632
91
0.643564
12041a8fb8071127366d271ce541a9754d588ecb
862
py
Python
02_Turtle/turtle_grafik.py
kilian-funk/Python-Kurs
f5ef5a2fb2a875d2e80d77c1a6c3596a0e577d7f
[ "MIT" ]
null
null
null
02_Turtle/turtle_grafik.py
kilian-funk/Python-Kurs
f5ef5a2fb2a875d2e80d77c1a6c3596a0e577d7f
[ "MIT" ]
null
null
null
02_Turtle/turtle_grafik.py
kilian-funk/Python-Kurs
f5ef5a2fb2a875d2e80d77c1a6c3596a0e577d7f
[ "MIT" ]
null
null
null
from turtle import * import time stift = Turtle() time.sleep(2) for _ in range(4): stift.forward(200) stift.left(90) stift.dot(20) time.sleep(2) stift.up() stift.goto(0,-100) stift.color("red") stift.width(5) stift.down() for _ in range(9): stift.forward(100) stift.right(160) time.sleep(2...
15.962963
92
0.596288
f66b35a47301edcccf0f56558569efa7aedfc724
400
py
Python
Chapter2_Python/NumpyIntro.py
derfabs/UdemyGAN_Template
1c7d263d22ccf1ba580c71befe71e3bf6e2facb6
[ "MIT" ]
null
null
null
Chapter2_Python/NumpyIntro.py
derfabs/UdemyGAN_Template
1c7d263d22ccf1ba580c71befe71e3bf6e2facb6
[ "MIT" ]
null
null
null
Chapter2_Python/NumpyIntro.py
derfabs/UdemyGAN_Template
1c7d263d22ccf1ba580c71befe71e3bf6e2facb6
[ "MIT" ]
null
null
null
import numpy as np noten_py_list = [100, 89, 44, 78, 45, 23, 17] noten_np_array = np.array(noten_py_list, dtype=np.int8) print(noten_py_list) print(noten_np_array) noten_max = np.max(noten_np_array) noten_min = np.min(noten_np_array) print(noten_max) print(noten_min) noten_arg_max = np.argmax(noten_np_array) noten...
20
55
0.7875
143e9623d715579770f0c6edc763e5c4ade75e6d
134
py
Python
data_tests/assign_func_boost.py
fluiddyn/transonic
a460e9f6d1139f79b668cb3306d1e8a7e190b72d
[ "BSD-3-Clause" ]
88
2019-01-08T16:39:08.000Z
2022-02-06T14:19:23.000Z
data_tests/assign_func_boost.py
fluiddyn/transonic
a460e9f6d1139f79b668cb3306d1e8a7e190b72d
[ "BSD-3-Clause" ]
13
2019-06-20T15:53:10.000Z
2021-02-09T11:03:29.000Z
data_tests/assign_func_boost.py
fluiddyn/transonic
a460e9f6d1139f79b668cb3306d1e8a7e190b72d
[ "BSD-3-Clause" ]
1
2019-11-05T03:03:14.000Z
2019-11-05T03:03:14.000Z
from transonic import boost def func(x: int): return x ** 2 def func2(x: int): return x ** 2 func_boosted = boost(func)
10.307692
27
0.626866
146866d37ae1a54202745da3964e44bb4063bfc8
8,567
py
Python
pyntcloud/plot/voxelgrid.py
bernssolg/pyntcloud-master
84cf000b7a7f69a2c1b36f9624f05f65160bf992
[ "MIT" ]
1,142
2016-10-10T08:55:30.000Z
2022-03-30T04:46:16.000Z
pyntcloud/plot/voxelgrid.py
bernssolg/pyntcloud-master
84cf000b7a7f69a2c1b36f9624f05f65160bf992
[ "MIT" ]
195
2016-10-10T08:30:37.000Z
2022-02-17T12:51:17.000Z
pyntcloud/plot/voxelgrid.py
bernssolg/pyntcloud-master
84cf000b7a7f69a2c1b36f9624f05f65160bf992
[ "MIT" ]
215
2017-02-28T00:50:29.000Z
2022-03-22T17:01:31.000Z
import os import shutil import numpy as np try: import matplotlib.pyplot as plt except ImportError: plt = None try: import pythreejs except ImportError: pythreejs = None try: from IPython.display import display except ImportError: display = None try: from IPython.display import IFrame exce...
35.110656
85
0.566593
210facd79f4dce2bf693c427abe932d38ebc5513
4,055
py
Python
python_experiments/paper_figures/legacy/draw_dynamic_exp.py
RapidsAtHKUST/SimRank
3a601b08f9a3c281e2b36b914e06aba3a3a36118
[ "MIT" ]
8
2020-04-14T23:17:00.000Z
2021-06-21T12:34:04.000Z
python_experiments/paper_figures/legacy/draw_dynamic_exp.py
RapidsAtHKUST/SimRank
3a601b08f9a3c281e2b36b914e06aba3a3a36118
[ "MIT" ]
null
null
null
python_experiments/paper_figures/legacy/draw_dynamic_exp.py
RapidsAtHKUST/SimRank
3a601b08f9a3c281e2b36b914e06aba3a3a36118
[ "MIT" ]
1
2021-01-17T16:26:50.000Z
2021-01-17T16:26:50.000Z
import json import matplotlib import numpy as np matplotlib.use("pdf") import matplotlib.pyplot as plt import os from paper_figures.legacy.experimental_config import * def ICDE_get_data_file(g_name, number_of_updates): return ICDE14_DIR + g_name + "_%d.txt" % number_of_updates def parse_dynamic_local_pushfil...
34.65812
99
0.61307
2c285943e98c8fef8fd2e0ccd2f9d708379482a9
1,294
py
Python
src/bo4e/com/externereferenz.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
1
2022-03-02T12:49:44.000Z
2022-03-02T12:49:44.000Z
src/bo4e/com/externereferenz.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
21
2022-02-04T07:38:46.000Z
2022-03-28T14:01:53.000Z
src/bo4e/com/externereferenz.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
null
null
null
""" Contains ExterenzeReferenz class and corresponding marshmallow schema for de-/serialization """ import attr from marshmallow import fields from bo4e.com.com import COM, COMSchema # pylint: disable=too-few-public-methods @attr.s(auto_attribs=True, kw_only=True) class ExterneReferenz(COM): """ Viele Dateno...
34.052632
185
0.746522
25ddc691c5119f50ec6f7dbe08bc144d058ceebb
424
py
Python
verify/787.py
cbarnson/UVa
0dd73fae656613e28b5aaf5880c5dad529316270
[ "Unlicense", "MIT" ]
2
2019-09-07T17:00:26.000Z
2020-08-05T02:08:35.000Z
verify/787.py
cbarnson/UVa
0dd73fae656613e28b5aaf5880c5dad529316270
[ "Unlicense", "MIT" ]
null
null
null
verify/787.py
cbarnson/UVa
0dd73fae656613e28b5aaf5880c5dad529316270
[ "Unlicense", "MIT" ]
null
null
null
# Problem # : 787 # Created on : 2018-11-01 00:54:22 def Main(): while True: x = [] x = list(map(int, input().split())) # try: # except: # return del x[-1] mx = x[0] for i in range(len(x)): s = x[i] for j in range(i, len(x)): if i == j: s = x[j] ...
17.666667
39
0.424528
b397aaace0b118d8936161acd71043b34558322d
112
py
Python
Pythonjunior2020/Woche1/Aufgabe_1_2_2.py
Zeyecx/HPI-Potsdam
ed45ca471cee204dde74dd2c3efae3877ee71036
[ "MIT" ]
null
null
null
Pythonjunior2020/Woche1/Aufgabe_1_2_2.py
Zeyecx/HPI-Potsdam
ed45ca471cee204dde74dd2c3efae3877ee71036
[ "MIT" ]
null
null
null
Pythonjunior2020/Woche1/Aufgabe_1_2_2.py
Zeyecx/HPI-Potsdam
ed45ca471cee204dde74dd2c3efae3877ee71036
[ "MIT" ]
null
null
null
# 1.2.2, Woche 1, Block 2, Aufgabe 2 print("Hallo \n Stella") # Alternative # print("Hallo") # print("Stella")
18.666667
36
0.642857
b3adfa0c1fdbcc0da68f598ad82dac3341bc03ad
9,760
py
Python
pythonProj/FZPython/pyquant/strategies/fzstrategy.py
iHamburg/FZQuant
86b750ec33d01badfd3f324d6f1599118b9bf8ff
[ "MIT" ]
null
null
null
pythonProj/FZPython/pyquant/strategies/fzstrategy.py
iHamburg/FZQuant
86b750ec33d01badfd3f324d6f1599118b9bf8ff
[ "MIT" ]
null
null
null
pythonProj/FZPython/pyquant/strategies/fzstrategy.py
iHamburg/FZQuant
86b750ec33d01badfd3f324d6f1599118b9bf8ff
[ "MIT" ]
2
2019-04-10T10:05:00.000Z
2021-11-24T17:17:23.000Z
# coding: utf8 import backtrader as bt import backtrader.indicators as btind import datetime import argparse import pandas as pd from backtrader.analyzers import (SQN, AnnualReturn, TimeReturn, SharpeRatio, TradeAnalyzer) import pyquant.utils.utils as utils import backtrader.analyzer...
29.575758
129
0.555123
03d4934976be66855e4b76ac5123c723e4f48504
208
py
Python
tests/onegov/qrcode/test_qrcode.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/qrcode/test_qrcode.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/qrcode/test_qrcode.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from onegov.qrcode import QrCode def test_qr_code_image(): img = QrCode.from_payload('https://seantis.ch') path = '/tmp/qrcode.png' with open(path, 'wb') as f: f.write(img.getvalue())
18.909091
51
0.644231
ff0b64c9b66b8379b2bb292f37653994a8afedf8
1,284
py
Python
src/mitglieder/funktions.py
Sumarbrander/Stura-Mitgliederdatenbank
691dbd33683b2c2d408efe7a3eb28e083ebcd62a
[ "MIT" ]
1
2021-12-20T20:15:26.000Z
2021-12-20T20:15:26.000Z
src/mitglieder/funktions.py
Sumarbrander/Stura-Mitgliederdatenbank
691dbd33683b2c2d408efe7a3eb28e083ebcd62a
[ "MIT" ]
null
null
null
src/mitglieder/funktions.py
Sumarbrander/Stura-Mitgliederdatenbank
691dbd33683b2c2d408efe7a3eb28e083ebcd62a
[ "MIT" ]
null
null
null
# Attribut attr (string) wird aus request (POST-Request) entnommen und zurueckgegeben # bei einem KeyError oder leerem String wird None zurueckgegeben def getValue(request, attr): """ Entnimmt das Attribut attr aus request und verwendet dieses als Rückgabewert. Aufgaben: * Entnehmen des Attributs ...
32.923077
143
0.696262
4586b3c6bca00842af67b0c090fa060f7648b12f
634
py
Python
V1/utils/filter.py
marsXyr/GESRL
3d60dfd4ffa1e0ae24d64b09f431d8ee0a9b5c01
[ "Apache-2.0" ]
null
null
null
V1/utils/filter.py
marsXyr/GESRL
3d60dfd4ffa1e0ae24d64b09f431d8ee0a9b5c01
[ "Apache-2.0" ]
null
null
null
V1/utils/filter.py
marsXyr/GESRL
3d60dfd4ffa1e0ae24d64b09f431d8ee0a9b5c01
[ "Apache-2.0" ]
null
null
null
import numpy as np """ State Filter: normalizes the input state """ class Filter(object): def __init__(self, state_dim): self.num = np.zeros(state_dim) self.mean = np.zeros(state_dim) self.mean_diff = np.zeros(state_dim) self.var = np.zeros(state_dim) def push(self, x): ...
25.36
61
0.588328
affb96f55b4d5268f3bc2b643c023d950ef15454
7,219
py
Python
main.py
roeetal/D.W.A
352049c7e36b716c6344f95c0e369004646adaf4
[ "MIT" ]
null
null
null
main.py
roeetal/D.W.A
352049c7e36b716c6344f95c0e369004646adaf4
[ "MIT" ]
null
null
null
main.py
roeetal/D.W.A
352049c7e36b716c6344f95c0e369004646adaf4
[ "MIT" ]
null
null
null
from flask import Flask, render_template, request from flask_cors import CORS from subprocess import Popen, PIPE from collections import deque, defaultdict from pattern.en import conjugate import json question_lists = [] answer_dict = defaultdict(list) app = Flask(__name__) CORS(app) class Token: def __init__(se...
29.830579
89
0.583876
b31b5500f03e2e9a216504ecb8cc6364173c585d
4,293
py
Python
test/TestBase.py
Berserker66/ALttPEntranceRandomizer
9c681cc65d7281ccded03484b050e8f80ea65dc6
[ "MIT" ]
null
null
null
test/TestBase.py
Berserker66/ALttPEntranceRandomizer
9c681cc65d7281ccded03484b050e8f80ea65dc6
[ "MIT" ]
5
2020-01-18T21:10:46.000Z
2020-01-25T20:58:19.000Z
test/TestBase.py
Berserker66/ALttPEntranceRandomizer
9c681cc65d7281ccded03484b050e8f80ea65dc6
[ "MIT" ]
2
2020-01-18T17:36:50.000Z
2020-01-22T16:52:08.000Z
import unittest from BaseClasses import CollectionState, World from Items import ItemFactory class TestBase(unittest.TestCase): world: World _state_cache = {} def get_state(self, items): if (self.world, tuple(items)) in self._state_cache: return self._state_cache[self.world, tuple(it...
48.235955
116
0.630096
2ff713591998e2ed72eead48f9f439b6ddfb161d
792
py
Python
docs/API/Users_Guide/scripts/Authentication_Tokens.py
ZhenyuZ/gdc-docs
f024d5d4cd86dfa2c9e7d63850eee94d975b7948
[ "Apache-2.0" ]
null
null
null
docs/API/Users_Guide/scripts/Authentication_Tokens.py
ZhenyuZ/gdc-docs
f024d5d4cd86dfa2c9e7d63850eee94d975b7948
[ "Apache-2.0" ]
null
null
null
docs/API/Users_Guide/scripts/Authentication_Tokens.py
ZhenyuZ/gdc-docs
f024d5d4cd86dfa2c9e7d63850eee94d975b7948
[ "Apache-2.0" ]
null
null
null
import requests import json import re # This script will not work until $TOKEN_FILE_PATH is replaced with an actual path. with open("$TOKEN_FILE_PATH","r") as token: token_string = str(token.read().strip()) headers = { 'X-Auth-Token': token_string } data_endpt = 'https://api.gdc.cancer.gov...
29.333333
84
0.708333
ff8e79d216adbf5b28b094f8894254d48b8922c1
345
py
Python
src/Util.py
florianletsch/kinect-juggling
f320cc0b55adf65d338d25986a03106a7e3f46ef
[ "Unlicense", "MIT" ]
7
2015-11-27T09:53:32.000Z
2021-01-13T17:35:54.000Z
src/Util.py
florianletsch/kinect-juggling
f320cc0b55adf65d338d25986a03106a7e3f46ef
[ "Unlicense", "MIT" ]
null
null
null
src/Util.py
florianletsch/kinect-juggling
f320cc0b55adf65d338d25986a03106a7e3f46ef
[ "Unlicense", "MIT" ]
null
null
null
''' Util.py --- utility functions ''' import cv colours = [cv.RGB(0, 0, 255), cv.RGB(0, 255, 0), cv.RGB(255, 0, 0), cv.RGB(0, 255, 255), cv.RGB(255, 0, 255)] util_color_index = 0 def getcolour(): global util_color_index colour = colours[util_color_index] util_color_index = (util_color_index + 1) % len(co...
20.294118
109
0.655072
44647fadd27c060448c16afc11b51293d48859f7
2,643
py
Python
Opt/Functions.py
leoatchina/MachineLearning
071f2c0fc6f5af3d9550cfbeafe8d537c35a76d3
[ "MIT" ]
1,107
2016-09-21T02:18:36.000Z
2022-03-29T02:52:12.000Z
Opt/Functions.py
leoatchina/MachineLearning
071f2c0fc6f5af3d9550cfbeafe8d537c35a76d3
[ "MIT" ]
18
2016-12-22T10:24:47.000Z
2022-03-11T23:18:43.000Z
Opt/Functions.py
leoatchina/MachineLearning
071f2c0fc6f5af3d9550cfbeafe8d537c35a76d3
[ "MIT" ]
776
2016-12-21T12:08:08.000Z
2022-03-21T06:12:08.000Z
import numpy as np class Function: """ The framework of target functions """ def __init__(self, n, **kwargs): """ :param n : Dimension of input vector :param kwargs : May contain 'grad_eps' which will be used to calculate numerical gradient """ self.n = n ...
37.225352
104
0.529323
446c4a22fb47373617262099242d9b2886c71a06
4,257
py
Python
Liquid-experiments/batch/launcher.py
PasaLab/YAO
2e70203197cd79f9522d65731ee5dc0eb236b005
[ "Apache-2.0" ]
2
2021-08-30T14:12:09.000Z
2022-01-20T02:14:22.000Z
Liquid-experiments/batch/launcher.py
PasaLab/YAO
2e70203197cd79f9522d65731ee5dc0eb236b005
[ "Apache-2.0" ]
null
null
null
Liquid-experiments/batch/launcher.py
PasaLab/YAO
2e70203197cd79f9522d65731ee5dc0eb236b005
[ "Apache-2.0" ]
null
null
null
import random def train(jm=None, api=None, seed=2020, case=None): pass def test(jm=None, api=None, seed=2020, case=''): cases = [ "multi-random", "multi-spread", "multi-pack", "multi-topology-aware", "multi-batch", "multi-k8s-default", "multi-k8s-affinity", "multi-k8s-kubeflow","multi-k8s-hived" ]...
23.39011
87
0.563073
2be219b4e4440503f8cac9e5397a483183360726
6,042
py
Python
1_DeepLearning-Basics/07_MNIST_Dataset_Klassifikation/network.py
felixdittrich92/DeepLearning-tensorflow-keras
2880d8ed28ba87f28851affa92b6fa99d2e47be9
[ "Apache-2.0" ]
null
null
null
1_DeepLearning-Basics/07_MNIST_Dataset_Klassifikation/network.py
felixdittrich92/DeepLearning-tensorflow-keras
2880d8ed28ba87f28851affa92b6fa99d2e47be9
[ "Apache-2.0" ]
null
null
null
1_DeepLearning-Basics/07_MNIST_Dataset_Klassifikation/network.py
felixdittrich92/DeepLearning-tensorflow-keras
2880d8ed28ba87f28851affa92b6fa99d2e47be9
[ "Apache-2.0" ]
null
null
null
import os import numpy as np import matplotlib.pyplot as plt import tensorflow as tf from tensorflow.keras.datasets import mnist from tensorflow.keras.utils import to_categorical from plotting import * # Dataset (x_train, y_train), (x_test, y_test) = mnist.load_data() # in float32 casten x_train = x_train.astype(n...
40.013245
109
0.643165
2bf95616ad5657f72c5d7d48f87fe2efa34c2d5f
100
pyde
Python
sketches/cuteplanet00/cuteplanet00.pyde
kantel/processingpy
74aae222e46f68d1c8f06307aaede3cdae65c8ec
[ "MIT" ]
4
2018-06-03T02:11:46.000Z
2021-08-18T19:55:15.000Z
sketches/cuteplanet00/cuteplanet00.pyde
kantel/processingpy
74aae222e46f68d1c8f06307aaede3cdae65c8ec
[ "MIT" ]
null
null
null
sketches/cuteplanet00/cuteplanet00.pyde
kantel/processingpy
74aae222e46f68d1c8f06307aaede3cdae65c8ec
[ "MIT" ]
3
2019-12-23T19:12:51.000Z
2021-04-30T14:00:31.000Z
# Processing.py Grundgerüst def setup(): size(640, 480) def draw(): background(0, 80, 125)
14.285714
27
0.64
a637224355165b1ce0ec456da591d04d437103a3
224
py
Python
official_examples/Reinforcement_Learning_GameSolution_Examples/vizdoom/async_multi/env_config.py
RuichunWang/ModelArts-Lab
cfa9a853e3a76a21eac2818f055b36978ac2bb69
[ "Apache-2.0" ]
1,045
2019-05-09T02:50:43.000Z
2022-03-31T06:22:11.000Z
official_examples/Reinforcement_Learning_GameSolution_Examples/vizdoom/async_multi/env_config.py
RuichunWang/ModelArts-Lab
cfa9a853e3a76a21eac2818f055b36978ac2bb69
[ "Apache-2.0" ]
1,468
2019-05-16T00:48:18.000Z
2022-03-08T04:12:44.000Z
official_examples/Reinforcement_Learning_GameSolution_Examples/vizdoom/async_multi/env_config.py
RuichunWang/ModelArts-Lab
cfa9a853e3a76a21eac2818f055b36978ac2bb69
[ "Apache-2.0" ]
1,077
2019-05-09T02:50:53.000Z
2022-03-27T11:05:32.000Z
import numpy as np from gym.spaces import Discrete,Box,Dict,MultiBinary action_space=Discrete(3) observation_space=Dict({ "obs":Box(-np.inf,np.inf,shape=(6,9,3),dtype=np.float32), "valid_action":MultiBinary(3) })
20.363636
61
0.732143
a6fbb60bf5a7ecbf68632f2edff5c18be51a4336
11,460
py
Python
Python/turnierkurier.py
Tamwyn/Turniermanagment
489b3169f4d73ebe3fe68158befff82bf20fa80b
[ "MIT" ]
null
null
null
Python/turnierkurier.py
Tamwyn/Turniermanagment
489b3169f4d73ebe3fe68158befff82bf20fa80b
[ "MIT" ]
null
null
null
Python/turnierkurier.py
Tamwyn/Turniermanagment
489b3169f4d73ebe3fe68158befff82bf20fa80b
[ "MIT" ]
null
null
null
#coding=utf-8 #Setze das encoding auf utf-8 um spaetere Probleme umgehen zu koennen mit Sonderzeichen #Importiere die Bibliotheken zur Darstellung von Daten und fuer MySQL import mysql.connector import datetime import formatize #Formatiere die Ausgaben der SQL Query in eine nuetzliches Dateiformat (siehe formatize.py...
41.978022
256
0.678621
5be73ccf708385f630ab57065c2a5025a3958652
628
py
Python
539-minimum-time-difference/539-minimum-time-difference.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
2
2021-12-05T14:29:06.000Z
2022-01-01T05:46:13.000Z
539-minimum-time-difference/539-minimum-time-difference.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
null
null
null
539-minimum-time-difference/539-minimum-time-difference.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
null
null
null
class Solution: def findMinDifference(self, timePoints: List[str]) -> int: timePoints.sort() output = 1440 # maximum minutes (24-hours) first_h, first_m = timePoints[0].split(":") prev = 60*int(first_h)+int(first_m) for timePoint in timePoints[1:]: h, m = timePoin...
39.25
62
0.547771
5bf779d707766c352290925384dc4db1353c8e95
151
py
Python
python/concurrency/tutorial/deadlock.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
python/concurrency/tutorial/deadlock.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
python/concurrency/tutorial/deadlock.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
import threading l = threading.Lock() print('before first acquire') l.acquire() print('before second acquire') l.acquire() print('acquire lock twice')
18.875
30
0.748344
1bc2ce92220db7220606e45269a5365f7f183ae6
4,724
py
Python
sphinx/source/conf.py
devinrsmith/deephaven-core
3a6930046faf1cd556f62a914ce1cfd7860147b9
[ "MIT" ]
null
null
null
sphinx/source/conf.py
devinrsmith/deephaven-core
3a6930046faf1cd556f62a914ce1cfd7860147b9
[ "MIT" ]
1
2022-03-03T21:24:40.000Z
2022-03-03T21:24:54.000Z
sphinx/source/conf.py
devinrsmith/deephaven-core
3a6930046faf1cd556f62a914ce1cfd7860147b9
[ "MIT" ]
null
null
null
# Configuration file for the Sphinx documentation builder. # # This file only contains a selection of the most common options. For a full # list see the documentation: # https://www.sphinx-doc.org/en/master/usage/configuration.html # -- Path setup -------------------------------------------------------------- # If ex...
27.788235
190
0.614945
944130b4b33b159971365a511fb6022665dda79d
867
py
Python
src/bo4e/enum/oekolabel.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
1
2022-03-02T12:49:44.000Z
2022-03-02T12:49:44.000Z
src/bo4e/enum/oekolabel.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
21
2022-02-04T07:38:46.000Z
2022-03-28T14:01:53.000Z
src/bo4e/enum/oekolabel.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
null
null
null
# pylint: disable=missing-module-docstring from bo4e.enum.strenum import StrEnum class Oekolabel(StrEnum): """ Aufzählung der Labels für Öko-Strom von verschiedenen Herausgebern. """ ENERGREEN = "ENERGREEN" #: ENERGREEN GASGREEN_GRUENER_STROM = "GASGREEN_GRUENER_STROM" #: GASGREEN_GRUENER_STROM...
39.409091
80
0.732411
9460134a3dd7acc8187950613a043c807642953c
987
py
Python
backtest.py
millsmgb/cfdBacktester
1958c401f189b90f3d106cb63c872b1aac925569
[ "MIT" ]
null
null
null
backtest.py
millsmgb/cfdBacktester
1958c401f189b90f3d106cb63c872b1aac925569
[ "MIT" ]
null
null
null
backtest.py
millsmgb/cfdBacktester
1958c401f189b90f3d106cb63c872b1aac925569
[ "MIT" ]
null
null
null
# Author: Matthew Mills # Copyright 2016 # Backtester # Import date and time from datetime import date, timedelta as td # Import for oracle from marketPriceOracle import PriceOracle from webAPIOracle import WebAPIOracle # Import CFD from cfd import CFD # Import Tests from cfdTests import CFDTests # Main method d...
19.352941
148
0.725431
849ac234a7f24bb2a0ff6f716193f17aba14ba20
624
py
Python
utest/curve3_test.py
Spiritdude/zencad
4e63b1a6306dd235f4daa2791b10249f7546c95b
[ "MIT" ]
5
2018-04-11T14:11:40.000Z
2018-09-12T19:03:36.000Z
utest/curve3_test.py
Spiritdude/zencad
4e63b1a6306dd235f4daa2791b10249f7546c95b
[ "MIT" ]
null
null
null
utest/curve3_test.py
Spiritdude/zencad
4e63b1a6306dd235f4daa2791b10249f7546c95b
[ "MIT" ]
null
null
null
import unittest import zencad import numpy import math class Curve3(unittest.TestCase): def setUp(self): zencad.lazy.encache = False zencad.lazy.decache = False zencad.lazy.fastdo = True def test_api(self): a = zencad.interpolate([(0, 0, 0), (0, 0, 1)], [ ...
29.714286
68
0.567308
edf1be13e3e622d24a93cccdd6d15034a96c236d
7,598
py
Python
pizza/pizza.py
gray-adeyi/pizza
659db6e85492903374416295cc3ca3a78584eccb
[ "MIT" ]
null
null
null
pizza/pizza.py
gray-adeyi/pizza
659db6e85492903374416295cc3ca3a78584eccb
[ "MIT" ]
null
null
null
pizza/pizza.py
gray-adeyi/pizza
659db6e85492903374416295cc3ca3a78584eccb
[ "MIT" ]
1
2022-03-17T00:54:27.000Z
2022-03-17T00:54:27.000Z
from typing import Type import os import json import logging from dataclasses import dataclass import enum logging.basicConfig( level=logging.DEBUG, format="[%(levelname)s] => `%(message)s` @ %(asctime)s" ) logger = logging.getLogger(__name__) logger.info("Logger is initialized...") class Gender(enum.Enum):...
25.843537
134
0.590419
fca9d04f1afe42d288b78cb66f7077c2a0e8a38e
316
py
Python
autojail/config/__init__.py
ekut-es/autojail
bc16e40e6df55c0a28a3059715851ffa59b14ba8
[ "MIT" ]
6
2020-08-12T08:16:15.000Z
2022-03-05T02:25:53.000Z
autojail/config/__init__.py
ekut-es/autojail
bc16e40e6df55c0a28a3059715851ffa59b14ba8
[ "MIT" ]
1
2021-03-30T10:34:51.000Z
2021-06-09T11:24:00.000Z
autojail/config/__init__.py
ekut-es/autojail
bc16e40e6df55c0a28a3059715851ffa59b14ba8
[ "MIT" ]
1
2021-11-21T09:30:58.000Z
2021-11-21T09:30:58.000Z
from .configurator import JailhouseConfigurator # noqa from .wizard import ( # noqa InmateConfigArgs, InmateConfigWizard, RootConfigArgs, RootConfigWizard, ) __all__ = [ "JailhouseConfigurator", "RootConfigWizard", "RootConfigArgs", "InmateConfigArgs", "InmateConfigWizard", ]
19.75
55
0.705696
94eca0142d4910f38179a3f34a4828df54c5e72f
3,099
py
Python
7-assets/past-student-repos/_DS-Python/Algorithms-I-Notes-master/day2_work.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
7-assets/past-student-repos/_DS-Python/Algorithms-I-Notes-master/day2_work.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
7-assets/past-student-repos/_DS-Python/Algorithms-I-Notes-master/day2_work.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
def add_list(l): # The sum of an empty list is 0 if l == []: return 0 # print(f'Add {l[0]} to the sum of {l[1:]}.') return l[0] + add_list(l[1:]) l = [1,2,3,4] print(add_list(l)) # Should print 10 # add_list := element 0 + add_list(rest_of_list) # Quick sort sample = [5, 3, 9, 4, 8, 1, 7...
28.694444
155
0.595999
7838407552c25d9c94dd94bbc708df886569b82a
76
py
Python
python/python_backup/PRAC_PYTHON/ra.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
16
2018-11-26T08:39:42.000Z
2019-05-08T10:09:52.000Z
python/python_backup/PRAC_PYTHON/ra.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
8
2020-05-04T06:29:26.000Z
2022-02-12T05:33:16.000Z
python/python_backup/PRAC_PYTHON/ra.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
5
2020-02-11T16:02:21.000Z
2021-02-05T07:48:30.000Z
c=input("enter a celsius temp") f=((9*c)+160)/5 print "farenheit temp",f
19
32
0.644737
1790c2d93c828dcb2eb630f91c4a863e5c1abf28
3,263
py
Python
test/test_npu/test_network_ops/test_addr.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_addr.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_addr.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...
42.934211
109
0.645418
17a3a5c9f7af43d3bb156c2168867f01316ccd91
16,094
py
Python
tests/onegov/notice/test_collections.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/notice/test_collections.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/notice/test_collections.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from datetime import datetime from datetime import timezone from onegov.notice import OfficialNoticeCollection from onegov.user import UserCollection from onegov.user import UserGroupCollection from transaction import commit def test_notice_collection(session): notices = OfficialNoticeCollection(session) asse...
32.912065
79
0.571331
bdc9bd308ed8f3ea85366697d021bf0c65213de7
2,495
py
Python
spider/test1/test1/spiders/testmovie.py
shyorange/MovieWebsite
aaf3be332b9f944ea93fbd841e1758b4a11d4581
[ "Apache-2.0" ]
null
null
null
spider/test1/test1/spiders/testmovie.py
shyorange/MovieWebsite
aaf3be332b9f944ea93fbd841e1758b4a11d4581
[ "Apache-2.0" ]
null
null
null
spider/test1/test1/spiders/testmovie.py
shyorange/MovieWebsite
aaf3be332b9f944ea93fbd841e1758b4a11d4581
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- import scrapy import copy; from ..items import Test1Item; """爬取电影天堂的爬虫""" class TestmovieSpider(scrapy.Spider): name = 'testmovie' allowed_domains = ['dytt8.net','ygdy8.net'] start_urls = ['http://www.ygdy8.net/html/gndy/dyzz/index.html','http://www.ygdy8.net/html/gndy/china/index....
39.603175
314
0.56513
e5485d5611c23574756698819310419850f476fe
11,544
py
Python
hihope_neptune-oh_hid/00_src/v0.1/test/xts/tools/lite/build/suite.py
dawmlight/vendor_oh_fun
bc9fb50920f06cd4c27399f60076f5793043c77d
[ "Apache-2.0" ]
1
2022-02-15T08:51:55.000Z
2022-02-15T08:51:55.000Z
hihope_neptune-oh_hid/00_src/v0.3/test/xts/tools/lite/build/suite.py
dawmlight/vendor_oh_fun
bc9fb50920f06cd4c27399f60076f5793043c77d
[ "Apache-2.0" ]
null
null
null
hihope_neptune-oh_hid/00_src/v0.3/test/xts/tools/lite/build/suite.py
dawmlight/vendor_oh_fun
bc9fb50920f06cd4c27399f60076f5793043c77d
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Copyright (c) 2021 Huawei Device 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 requ...
40.222997
79
0.592429
f9282f4c87cd4d966b67de32c6488c0b1b84ca47
11,630
py
Python
wz/tables/simple_ods_reader.py
gradgrind/WZ
672d93a3c9d7806194d16d6d5b9175e4046bd068
[ "Apache-2.0" ]
null
null
null
wz/tables/simple_ods_reader.py
gradgrind/WZ
672d93a3c9d7806194d16d6d5b9175e4046bd068
[ "Apache-2.0" ]
null
null
null
wz/tables/simple_ods_reader.py
gradgrind/WZ
672d93a3c9d7806194d16d6d5b9175e4046bd068
[ "Apache-2.0" ]
null
null
null
### python >= 3.7 # -*- coding: utf-8 -*- """ tables/simple_ods_reader.py Last updated: 2021-01-05 OdsReader: Read the data from the sheets of an ods-file ignoring all formatting and style information. An ods-file is a zipped archive, the content is found in the file member file "content.xml". =+LICENCE===========...
35.565749
80
0.538435
dad69803e4e1ae0502525fe5fa268e81ded404eb
2,655
py
Python
frappe-bench/env/lib/python2.7/site-packages/stdnum/ee/registrikood.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/env/lib/python2.7/site-packages/stdnum/ee/registrikood.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/env/lib/python2.7/site-packages/stdnum/ee/registrikood.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
# registrikood.py - functions for handling the Estonian Registrikood # coding: utf-8 # # Copyright (C) 2017 Holvi Payment Services # Copyright (C) 2017 Arthur de Jong # # This library is free software; you can redistribute it and/or # modify it under the terms of the GNU Lesser General Public # License as published by ...
31.987952
74
0.732957
97b3e369a251e806d83b9b3b6c46fd63d8c52cad
551
py
Python
IVTa/2014/MOSHKOV_Y_O/task_6_23.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
IVTa/2014/MOSHKOV_Y_O/task_6_23.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
IVTa/2014/MOSHKOV_Y_O/task_6_23.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
# Задача 6. Вариант 23 # Создайте игру, в которой компьютер загадывает название одного # из семи дней недели, а игрок должен его угадать. # Moshkov Y. O. # 31.03.2016 import random week = ["Понедельник", "Вторник", "Среда", "Четверг", "Пятница", "Суббота", "Воскресенье"] number = random.randint(0, 6) day = week[num...
27.55
64
0.678766
416e98934c1642e339cb27dc425f66bd0138f74e
4,589
py
Python
python_lib/hucon/EventSystem.py
SaschaMzH/hucon
830b6c5e21c2c7316c61e8afdf708066374b9b62
[ "BSD-3-Clause" ]
2
2019-09-25T13:39:22.000Z
2019-09-26T10:06:13.000Z
python_lib/hucon/EventSystem.py
SaschaMzH/hucon
830b6c5e21c2c7316c61e8afdf708066374b9b62
[ "BSD-3-Clause" ]
44
2019-09-25T14:35:48.000Z
2021-08-20T17:26:12.000Z
python_lib/hucon/EventSystem.py
SaschaMzH/hucon
830b6c5e21c2c7316c61e8afdf708066374b9b62
[ "BSD-3-Clause" ]
8
2019-09-25T13:53:07.000Z
2022-02-24T19:23:44.000Z
#!/usr/bin/env python """ __init__.py - The event system is using SIGRT signals from linux. Copyright (C) 2019 Basler AG All rights reserved. This software may be modified and distributed under the terms of the BSD license. See the LICENSE file for details. """ import signal import tempfile import o...
33.014388
161
0.579429
6b517fa5d9308c88ee26de9e6cf56bc9455c8948
13,161
py
Python
respiratory/Processed Datasets/Processed Datasets/uptoweek9.py
easyCZ/SLIP-A-2015
ad386df9c438d93ec89f68c63d3deda12d27d1ed
[ "MIT" ]
2
2020-06-08T19:17:10.000Z
2020-06-08T20:45:07.000Z
respiratory/Processed Datasets/Processed Datasets/uptoweek9.py
easyCZ/SLIP-A-2015
ad386df9c438d93ec89f68c63d3deda12d27d1ed
[ "MIT" ]
14
2015-10-07T09:31:50.000Z
2022-02-23T07:34:10.000Z
respiratory/Processed Datasets/Processed Datasets/uptoweek9.py
easyCZ/SLIP-A-2015
ad386df9c438d93ec89f68c63d3deda12d27d1ed
[ "MIT" ]
null
null
null
# Finding coefficients in ranking algorithm by comparing results to actual ranking # Improvements to make # 1) use enumerate to remove arguments from functions. # 2) *Consider exercises that were completed more often to be easier and others more difficult (a lot of error here).* # 3) Implement householder QR decomp...
31.713253
214
0.673733
6b980199e25046a17ca3c04b222ae4fbbab2d3eb
1,582
py
Python
deutschland/bundesnetzagentur/rufzeichen.py
kiranmusze/deutschland
86d8ead3f38ad88ad66bb338b9f5a8db06992344
[ "Apache-2.0" ]
445
2021-07-26T22:00:26.000Z
2022-03-31T08:31:08.000Z
deutschland/bundesnetzagentur/rufzeichen.py
kiranmusze/deutschland
86d8ead3f38ad88ad66bb338b9f5a8db06992344
[ "Apache-2.0" ]
30
2021-07-27T15:42:23.000Z
2022-03-26T16:14:11.000Z
deutschland/bundesnetzagentur/rufzeichen.py
kiranmusze/deutschland
86d8ead3f38ad88ad66bb338b9f5a8db06992344
[ "Apache-2.0" ]
28
2021-07-27T10:48:43.000Z
2022-03-26T14:31:30.000Z
import requests from bs4 import BeautifulSoup class Rufzeichen(object): def get(self, callsign): """ Gibt informationen über den Inhaber sowie Lizenzklasse und Betriebsort eines Amateurfunkrufzeichens zurück. """ r = requests.get("https://ans.bundesnetzagentur.de/amateurfun...
36.790698
88
0.513906
d406ea1c592fb9f9509957fb0a5a92a74bb5e4ec
2,934
py
Python
models/hr_holidays_status.py
aroodooteam/aro_hr
bf26f026593493486b4b5c13b26b9b47b9fe3825
[ "BSD-2-Clause" ]
null
null
null
models/hr_holidays_status.py
aroodooteam/aro_hr
bf26f026593493486b4b5c13b26b9b47b9fe3825
[ "BSD-2-Clause" ]
null
null
null
models/hr_holidays_status.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 models, api, fields import logging _logger = logging.getLogger(__name__) class HrHolidaysStatus(models.Model): _inherit = "hr.holidays.status" @api.multi def get_days(self, employee_id, context=None): result = dict((holiday.id, ...
43.791045
78
0.566803
2e0959f2b06efe25e0345b03d1ca90f32f6e9293
1,442
py
Python
py-basics/src/lectures/tuples-sets/duplicates.py
AndrasTarlos/s4f
bfe2d631a9a2715953d8ac5ddc8ef97d3cefb426
[ "CC0-1.0" ]
null
null
null
py-basics/src/lectures/tuples-sets/duplicates.py
AndrasTarlos/s4f
bfe2d631a9a2715953d8ac5ddc8ef97d3cefb426
[ "CC0-1.0" ]
null
null
null
py-basics/src/lectures/tuples-sets/duplicates.py
AndrasTarlos/s4f
bfe2d631a9a2715953d8ac5ddc8ef97d3cefb426
[ "CC0-1.0" ]
4
2021-12-13T15:52:00.000Z
2022-03-28T13:54:53.000Z
# 6kyu | Duplicates. Duplicates Everywhere. # https://www.codewars.com/kata/5e8dd197c122f6001a8637ca/python def remove_duplicate_ids(obj): def convert_to_int(text): return int(text) def sort_keys(keys): # https://www.w3schools.com/python/ref_func_sorted.asp return sorted(keys, key=con...
30.680851
128
0.462552
2e2e25602afdaf837f013eaeff47527c63f134f6
1,723
py
Python
Python Stuff/LCD_Funktionen/BOOT.py
Hyperfluff/tic_motion
b7856bc2a14f7683c8cacdafda32ebaff8be8e5b
[ "MIT" ]
1
2020-12-07T09:39:20.000Z
2020-12-07T09:39:20.000Z
Python Stuff/LCD_Funktionen/BOOT.py
Hyperfluff/tic_motion
b7856bc2a14f7683c8cacdafda32ebaff8be8e5b
[ "MIT" ]
null
null
null
Python Stuff/LCD_Funktionen/BOOT.py
Hyperfluff/tic_motion
b7856bc2a14f7683c8cacdafda32ebaff8be8e5b
[ "MIT" ]
null
null
null
from Adafruit_CharLCD import Adafruit_CharLCD import Adafruit_GPIO.PCF8574 as PCF import RPi.GPIO as GPIO import time LCD = PCF.PCF8574(address=0x27) LCD.setup(5,0) LCD.output(5,0) # Deklariert welche PCF-Pins mit welchem LCD-Pin verbunden sind. lcd_rs = 4 # RegisterSelect Pin des LCDs ist an GPIO4 lcd_en = 7 # Enable ...
31.907407
76
0.761463
5ac066b809e824760ba6236112c5c53487cc5d29
609
py
Python
exercises/fr/solution_01_11.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
2,085
2019-04-17T13:10:40.000Z
2022-03-30T21:51:46.000Z
exercises/fr/solution_01_11.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
79
2019-04-18T14:42:55.000Z
2022-03-07T08:15:43.000Z
exercises/fr/solution_01_11.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
361
2019-04-17T13:34:32.000Z
2022-03-28T04:42:45.000Z
import spacy # Importe le Matcher from spacy.matcher import Matcher nlp = spacy.load("fr_core_news_sm") doc = nlp("Le constructeur Citröen présente la e-Méhari Courrèges au public.") # Initialise le matcher avec le vocabulaire partagé matcher = Matcher(nlp.vocab) # Crée un motif qui recherche les deux tokens : "e-M...
29
79
0.737274
51f78b82296caf731714b2cc780b8b0da112cd5b
1,033
py
Python
CodeStatistics/settings.py
zhangyafeii/Flask
9c9a5ea282f77aabcda838796dad2411af9b519f
[ "MIT" ]
null
null
null
CodeStatistics/settings.py
zhangyafeii/Flask
9c9a5ea282f77aabcda838796dad2411af9b519f
[ "MIT" ]
null
null
null
CodeStatistics/settings.py
zhangyafeii/Flask
9c9a5ea282f77aabcda838796dad2411af9b519f
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ @Datetime: 2018/12/25 @Author: Zhang Yafei """ from DBUtils.PooledDB import PooledDB import pymysql SALT = 'zhang' SECRET_KEY = 'sdasdadsadsfsdsds' MAX_CONTENT_LENGTH = 1024 * 1024 * 7 POOL = PooledDB( creator=pymysql, # 使用链接数据库的模块 maxconnections=6, # 连接池允许的最大连接数,0和None表示不限制连接数 ...
32.28125
161
0.692159
56b8f45937e9b4bafd2f0ff855bc05e2a6232322
105,027
py
Python
Python/pyBitwiseAutomation/autogenPela.py
jimwaschura/Automation
f655feeea74ff22ebe44d8b68374ba6983748f60
[ "BSL-1.0" ]
null
null
null
Python/pyBitwiseAutomation/autogenPela.py
jimwaschura/Automation
f655feeea74ff22ebe44d8b68374ba6983748f60
[ "BSL-1.0" ]
null
null
null
Python/pyBitwiseAutomation/autogenPela.py
jimwaschura/Automation
f655feeea74ff22ebe44d8b68374ba6983748f60
[ "BSL-1.0" ]
null
null
null
# autogenPega.py # ================================================================================ # BOOST SOFTWARE LICENSE # # Copyright 2020 BitWise Laboratories Inc. # Original Author.......Jim Waschura # Contact...............info@bitwiselabs.com # # Permission is hereby granted, free of charge, to any person or o...
32.216871
98
0.579946
85a4eddd422dc862024afd3aafaf0a6a0f5d810c
891
py
Python
PMIa/2015/ANDROS_D_A/task_4_2.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
PMIa/2015/ANDROS_D_A/task_4_2.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
PMIa/2015/ANDROS_D_A/task_4_2.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
# Задача 4.Вариант 2. # Напишите программу, которая выводит имя, под которым скрывается Михаил Евграфович Салтыков. Дополнительно необходимо вывести область интересов указанной личности, место рождения, годы рождения и смерти (если человек умер), вычислить возраст на данный момент (или момент смерти). Для хранения все...
63.642857
447
0.813692
77a35929c836f8735df8589942e920aa85713bf9
3,739
py
Python
packages/watchmen-meta/src/watchmen_meta/admin/user_group_service.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-meta/src/watchmen_meta/admin/user_group_service.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-meta/src/watchmen_meta/admin/user_group_service.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
from typing import List, Optional from watchmen_meta.common import TupleService, TupleShaper from watchmen_model.admin import UserGroup from watchmen_model.common import DataPage, Pageable, TenantId, UserGroupId from watchmen_storage import ColumnNameLiteral, EntityCriteriaExpression, EntityCriteriaJoint, \ EntityCri...
40.204301
113
0.779353
7076a6ef4df00169ed37a1b94520e9949774da9e
1,057
py
Python
Nucleo/smain_Debug.py
Jonatan966/SODA
046d8c1e7b9bac3a555526c9fe2f365c2b338aca
[ "MIT" ]
null
null
null
Nucleo/smain_Debug.py
Jonatan966/SODA
046d8c1e7b9bac3a555526c9fe2f365c2b338aca
[ "MIT" ]
null
null
null
Nucleo/smain_Debug.py
Jonatan966/SODA
046d8c1e7b9bac3a555526c9fe2f365c2b338aca
[ "MIT" ]
null
null
null
from .smain_Variaveis import * variaveis = vars() def soda_DEBUG(): sMain_Avisos().Resposta('Voce esta agora no menu DEBUG') while True: q = sMain_Saidas().Prompt('DEBUG') if q == 'SAIR' or q == 'VOLTAR' or q == 'QUIT': break elif q == 'SYS.PATH' or q == '0': ...
30.2
102
0.561022
565c0d68cc28c52416c150e94db876f922de9ff2
1,395
py
Python
src/onegov/town6/views/event.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/town6/views/event.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/town6/views/event.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from onegov.core.security import Public from onegov.event import Event, OccurrenceCollection from onegov.org.views.event import event_form as org_event_form, \ handle_new_event, view_event, handle_edit_event from onegov.town6 import TownApp from onegov.town6.forms.event import EventForm from onegov.town6.layout im...
24.473684
66
0.731183
8ee9890462be7f2ea9f6d311b1682b61f754428c
2,690
py
Python
test/unit/group_wavelet_test.py
hdkai/Raw-IO
f0fa928d7ef59a363c6f4c876d642af6dede6ae4
[ "Apache-2.0" ]
null
null
null
test/unit/group_wavelet_test.py
hdkai/Raw-IO
f0fa928d7ef59a363c6f4c876d642af6dede6ae4
[ "Apache-2.0" ]
null
null
null
test/unit/group_wavelet_test.py
hdkai/Raw-IO
f0fa928d7ef59a363c6f4c876d642af6dede6ae4
[ "Apache-2.0" ]
null
null
null
# # RawIO # Copyright (c) 2021 Yusuf Olokoba. # from pathlib import Path from PIL import Image from pytest import fixture, mark from rawio.grouping import group_exposures, wavelet_similarity def test_group_wavelet_ambient_a (): # fails, on brightest exposure exposure_paths = [ "test/media/group/6.jp...
33.209877
110
0.651673
79de0e36cd71e68ca4096aa234243e276982458d
1,307
py
Python
Python/Buch_ATBS/Teil_2/Kapitel_12_Arbeiten_mit_Excel-Sheets/08_vertikale_zu_horizontale_anordnung/08_vertikale_zu_horizontale_anordnung.py
Apop85/Scripts
e71e1c18539e67543e3509c424c7f2d6528da654
[ "MIT" ]
null
null
null
Python/Buch_ATBS/Teil_2/Kapitel_12_Arbeiten_mit_Excel-Sheets/08_vertikale_zu_horizontale_anordnung/08_vertikale_zu_horizontale_anordnung.py
Apop85/Scripts
e71e1c18539e67543e3509c424c7f2d6528da654
[ "MIT" ]
6
2020-12-24T15:15:09.000Z
2022-01-13T01:58:35.000Z
Python/Buch_ATBS/Teil_2/Kapitel_12_Arbeiten_mit_Excel-Sheets/08_vertikale_zu_horizontale_anordnung/08_vertikale_zu_horizontale_anordnung.py
Apop85/Scripts
1d8dad316c55e1f1343526eac9e4b3d0909e4873
[ "MIT" ]
null
null
null
# 08_uebung_einträge_vertikale_zu_hotizontale_anordnung.py # In dieser Übung geht es darum Einträge einer Tabelle die Vertikal geordnet # sind horizontal auszurichten import openpyxl, os os.chdir(os.path.dirname(__file__)) example_file='.\\example.xlsx' target_file='.\\output.xlsx' if os.path.exists(target_file): ...
31.119048
88
0.776588
5c0774af2cb26c36d3e0be56585b14cccbc94ec5
1,269
py
Python
bridges/models/crnn/utils.py
ChristianKitte/Textextraktion-und-Einordnung-mit-Hilfe-neuronaler-Netze
53d3fc6b1c17f31146741cdebd743f4aa12a09e0
[ "MIT" ]
null
null
null
bridges/models/crnn/utils.py
ChristianKitte/Textextraktion-und-Einordnung-mit-Hilfe-neuronaler-Netze
53d3fc6b1c17f31146741cdebd743f4aa12a09e0
[ "MIT" ]
16
2020-01-28T23:04:13.000Z
2022-03-12T00:02:40.000Z
bridges/models/crnn/utils.py
ChristianKitte/Textextraktion-und-Einordnung-mit-Hilfe-neuronaler-Netze
53d3fc6b1c17f31146741cdebd743f4aa12a09e0
[ "MIT" ]
null
null
null
""" This file contains source code from another GitHub project. The comments made there apply. The used source code is licensed under the MIT License. The license text and a detailed reference can be found in the license subfolder. Many thanks to the author of the code. For reasons of clarity unneeded parts of the ori...
38.454545
119
0.692671
d69b440d29d47ebdb0e600b81260d9da5378e3fa
1,864
py
Python
packages/watchmen-rest-doll/src/watchmen_rest_doll/meta_import/pipeline_import_router.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-rest-doll/src/watchmen_rest_doll/meta_import/pipeline_import_router.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-rest-doll/src/watchmen_rest_doll/meta_import/pipeline_import_router.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
from typing import List from fastapi import APIRouter, Depends from starlette.responses import Response from watchmen_auth import PrincipalService from watchmen_meta.admin import PipelineService from watchmen_meta.common import ask_meta_storage, ask_snowflake_generator from watchmen_model.admin import Pipeline, Pipel...
39.659574
109
0.821352
ba3d38e768a732d154e297b7eec01e19b3e6da61
1,806
py
Python
Python/Programação_em_Python_Essencial/6- Funções/args.py
vdonoladev/aprendendo-programacao
83abbcd6701b2105903b28fd549738863418cfb8
[ "MIT" ]
null
null
null
Python/Programação_em_Python_Essencial/6- Funções/args.py
vdonoladev/aprendendo-programacao
83abbcd6701b2105903b28fd549738863418cfb8
[ "MIT" ]
null
null
null
Python/Programação_em_Python_Essencial/6- Funções/args.py
vdonoladev/aprendendo-programacao
83abbcd6701b2105903b28fd549738863418cfb8
[ "MIT" ]
null
null
null
""" Entendendo o *args - O *args é um parâmetro, como outro qualquer. Isso significa que você poderá chamar de qualquer coisa, desde que começe com asterísco *. Exemplo: *xis Mas por convenção, utilizamos *args para definí-lo. Mas o que é o *args? O parâmetro *args utilizado em uma função, coloca os valores extr...
23.454545
86
0.723699
ba5f24fa1c737c5a44b60eee6f400685c1be9ad6
421
py
Python
exercises/pt/exc_03_09_01.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
exercises/pt/exc_03_09_01.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
exercises/pt/exc_03_09_01.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
import spacy from spacy.tokens import Token nlp = spacy.blank("pt") # Definir o atributo "is_country" com o valor padrão como falso (False) ____.____(____, ____=____) # Processar o texto e atribuir o atributo is_country com valor verdadeiro (True) para o token "Spain" doc = nlp("Eu moro na Espanha.") ____ = True # ...
28.066667
101
0.743468
aeaeecd417748763895f40dd98dc35dd01169d4f
2,553
py
Python
official/cv/east/export.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
official/cv/east/export.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
official/cv/east/export.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.759036
91
0.663925
ae5a7094e20490e641f0e7d1d6e30443c8818f1e
2,325
py
Python
official/gnn/gat/export.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
official/gnn/gat/export.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
official/gnn/gat/export.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...
34.191176
112
0.67914
4e9dde2a43666fc451abfc4295fe7ad150bf53ab
91
py
Python
Shivani/sum of two no.py
63Shivani/Python-BootCamp
2ed0ef95af35d35c0602031670fecfc92d8cea0a
[ "MIT" ]
null
null
null
Shivani/sum of two no.py
63Shivani/Python-BootCamp
2ed0ef95af35d35c0602031670fecfc92d8cea0a
[ "MIT" ]
null
null
null
Shivani/sum of two no.py
63Shivani/Python-BootCamp
2ed0ef95af35d35c0602031670fecfc92d8cea0a
[ "MIT" ]
null
null
null
a=int(input("enter first number\n")) b=int(input("enter second number\n")) c=a+b print(c)
15.166667
37
0.681319
e103291640486742c26e6c0ccbaba322c3c38ae4
31,283
py
Python
src/pfun/mypy_plugin.py
suned/pfun
46c460646487abfef897bd9627891f6cf7870774
[ "MIT" ]
126
2019-09-16T15:28:20.000Z
2022-03-20T10:57:53.000Z
src/pfun/mypy_plugin.py
suned/pfun
46c460646487abfef897bd9627891f6cf7870774
[ "MIT" ]
54
2019-09-30T08:44:01.000Z
2022-03-20T11:10:00.000Z
src/pfun/mypy_plugin.py
suned/pfun
46c460646487abfef897bd9627891f6cf7870774
[ "MIT" ]
11
2020-01-02T08:32:46.000Z
2022-03-20T11:10:24.000Z
# type: ignore import typing as t from mypy import checkmember, infer from mypy.argmap import map_actuals_to_formals from mypy.checker import TypeChecker from mypy.expandtype import freshen_function_type_vars from mypy.mro import MroError, calculate_mro from mypy.nodes import (ARG_NAMED, ARG_NAMED_OPT, ARG_OPT, ARG_...
36.040323
79
0.60755
0132307520b30ed591066bf37b85f70a2bc8099b
2,394
py
Python
2-resources/_External-learning-resources/02-pyth/python-patterns-master/tests/structural/test_adapter.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
2-resources/_External-learning-resources/02-pyth/python-patterns-master/tests/structural/test_adapter.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
2-resources/_External-learning-resources/02-pyth/python-patterns-master/tests/structural/test_adapter.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
1
2021-11-05T07:48:26.000Z
2021-11-05T07:48:26.000Z
import unittest from patterns.structural.adapter import Adapter, Car, Cat, Dog, Human class ClassTest(unittest.TestCase): def setUp(self): self.dog = Dog() self.cat = Cat() self.human = Human() self.car = Car() def test_dog_shall_bark(self): noise = self.dog.bark() ...
31.92
69
0.654553
09a43988b48e8c7b729bfb877677673a4f4d44e1
4,541
py
Python
webshells/laudanum/helpers/shell.py
0x307845/Dotfiles
26a9126aee891d8353e1e59a96e4ef469310c74f
[ "MIT" ]
3
2020-09-26T16:14:37.000Z
2020-12-27T23:42:17.000Z
webshells/laudanum/helpers/shell.py
0x307845/Dotfiles
26a9126aee891d8353e1e59a96e4ef469310c74f
[ "MIT" ]
null
null
null
webshells/laudanum/helpers/shell.py
0x307845/Dotfiles
26a9126aee891d8353e1e59a96e4ef469310c74f
[ "MIT" ]
1
2021-01-13T11:58:45.000Z
2021-01-13T11:58:45.000Z
#!/usr/bin/env python3 ''' ******************************************************************************* *** *** Laudanum Project *** A Collection of Injectable Files used during a Penetration Test *** *** More information is available at: *** http://laudanum.professionallyevil.com/ *** laudanum@secureideas.net **...
31.10274
163
0.640608
3a18e4d563abc624822700535f2156a3957933cc
3,098
py
Python
routes/misc.py
AuxiliumCDNG/MET-Bot
7e00d878c92ad4f68b0b2920235019e14c9ea2fa
[ "MIT" ]
null
null
null
routes/misc.py
AuxiliumCDNG/MET-Bot
7e00d878c92ad4f68b0b2920235019e14c9ea2fa
[ "MIT" ]
null
null
null
routes/misc.py
AuxiliumCDNG/MET-Bot
7e00d878c92ad4f68b0b2920235019e14c9ea2fa
[ "MIT" ]
null
null
null
import importlib import threading import requests from discord_interactions import verify_key_decorator from flask import Blueprint, abort, send_file, request, jsonify from globals import tokens, running_interactions, client from statics import config views = Blueprint("misc", __name__) @views.route("/pictures/<gui...
36.447059
169
0.575855
3ac640770209bcf14e9b31ec80c9b85b8c5d8a0a
2,612
py
Python
deprecated/benchmark/ps/semantic_matching/simnet_bow_benchmark.py
hutuxian/FleetX
843c7aa33f5a14680becf058a3aaf0327eefafd4
[ "Apache-2.0" ]
170
2020-08-12T12:07:01.000Z
2022-03-07T02:38:26.000Z
deprecated/benchmark/ps/semantic_matching/simnet_bow_benchmark.py
hutuxian/FleetX
843c7aa33f5a14680becf058a3aaf0327eefafd4
[ "Apache-2.0" ]
195
2020-08-13T03:22:15.000Z
2022-03-30T07:40:25.000Z
deprecated/benchmark/ps/semantic_matching/simnet_bow_benchmark.py
hutuxian/FleetX
843c7aa33f5a14680becf058a3aaf0327eefafd4
[ "Apache-2.0" ]
67
2020-08-14T02:07:46.000Z
2022-03-28T10:05:33.000Z
# Copyright (c) 2019 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 app...
30.729412
75
0.661562
c977d5d29db1a4081175092bb5e78c05e6bde956
398
py
Python
2-resources/_PYTHON/code-examples-master/mongodb/python/insert-document-mongodb.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
2-resources/_PYTHON/code-examples-master/mongodb/python/insert-document-mongodb.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
2-resources/_PYTHON/code-examples-master/mongodb/python/insert-document-mongodb.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
1
2021-11-05T07:48:26.000Z
2021-11-05T07:48:26.000Z
from pymongo import MongoClient import datetime client = MongoClient('mongodb://localhost:27017/') mydb = client['mydb'] myrecord = { "author": "James", "title" : "PyMongo 101", "tags" : ["MongoDB", "PyMongo", "Tutorial"], "date" : datetime.datetime.utcnow() } record_id = mydb...
22.111111
52
0.648241
a31953d05d08d1cf6e100d86487703888982f265
1,017
py
Python
tests/onegov/activity/test_utils.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/activity/test_utils.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/activity/test_utils.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from onegov.activity.utils import merge_ranges from onegov.activity.utils import extract_municipality def test_merge_ranges(): assert merge_ranges([[1, 2]]) == [(1, 2)] assert merge_ranges([[1, 2], [2, 3]]) == [(1, 3)] assert merge_ranges([[1, 2], [2, 3]]) == [(1, 3)] assert merge_ranges([[1, 2], [3, ...
33.9
74
0.610619
a360b0fdf5508e12688e0394905ca3452e080ca1
1,476
py
Python
generate_sample.py
StanislavVolodarskiy/trie
fd3c462a0338f9cfdca45d7ddeb6647a9b6b5a57
[ "MIT" ]
null
null
null
generate_sample.py
StanislavVolodarskiy/trie
fd3c462a0338f9cfdca45d7ddeb6647a9b6b5a57
[ "MIT" ]
null
null
null
generate_sample.py
StanislavVolodarskiy/trie
fd3c462a0338f9cfdca45d7ddeb6647a9b6b5a57
[ "MIT" ]
null
null
null
import string import random # В файле порядка 50'000 уникальных искомых подстрок # В каждом файле порядка 700'000 уникальных строк # средняя длина строк в файлах, где проводится поиск - от 18 символов до 500, на вскидку. # cредняя длина искомых строк (подстрок) порядка 65-72 символов. Доля # Пример искомых подстрок ...
26.357143
89
0.724255
6e9fe600e0c213ce43741f7722dd49f4a5312952
2,426
py
Python
src/hdf5to_pb.py
misogil0116/Biscotti
010ef0f29fbd5d33c9870ce249f1a9824f3471c4
[ "Apache-2.0" ]
10
2018-01-11T01:15:15.000Z
2020-06-22T15:03:31.000Z
src/hdf5to_pb.py
misogil0116/Biscotti
010ef0f29fbd5d33c9870ce249f1a9824f3471c4
[ "Apache-2.0" ]
null
null
null
src/hdf5to_pb.py
misogil0116/Biscotti
010ef0f29fbd5d33c9870ce249f1a9824f3471c4
[ "Apache-2.0" ]
null
null
null
""" this script help you to convert hdf5 into .pb """ import argparse import os import tensorflow as tf from keras.models import load_model from keras import backend as K from tensorflow.python.framework import graph_util from tensorflow.python.framework import graph_io """ def generator_loss_yuv444(y_true, y_pred...
42.561404
208
0.716406
6ebe9d93100d5e479edcf862acca440f760b0185
778
py
Python
skill/LightsController/LightsController.py
th-koeln-intia/ip-sprachassistent-team5
cef8fded78261f2e838e45af11c2e74d34b85682
[ "MIT" ]
null
null
null
skill/LightsController/LightsController.py
th-koeln-intia/ip-sprachassistent-team5
cef8fded78261f2e838e45af11c2e74d34b85682
[ "MIT" ]
null
null
null
skill/LightsController/LightsController.py
th-koeln-intia/ip-sprachassistent-team5
cef8fded78261f2e838e45af11c2e74d34b85682
[ "MIT" ]
null
null
null
from core.base.model.AliceSkill import AliceSkill from core.dialog.model.DialogSession import DialogSession from core.util.Decorators import IntentHandler class LightsController(AliceSkill): """ Author: Team5 Description: A skill to control your zigbee lights """ @IntentHandler('toggleLightOn') def toggleOnI...
31.12
72
0.787918
42eb6672d56af047368c2e51c88eb2e6aa26218b
623
py
Python
webinterface/management/commands/send_daily_emails.py
monoclecat/Cleaning-Schedule-generator
b12fa8a6f834a89b805bf062a0df45279a7a8796
[ "MIT" ]
2
2021-11-28T23:04:00.000Z
2022-01-13T19:47:45.000Z
webinterface/management/commands/send_daily_emails.py
monoclecat/Cleaning-Schedule-generator
b12fa8a6f834a89b805bf062a0df45279a7a8796
[ "MIT" ]
25
2020-03-29T14:40:46.000Z
2021-09-22T17:37:15.000Z
webinterface/management/commands/send_daily_emails.py
monoclecat/cleaning-schedule-management-system
b12fa8a6f834a89b805bf062a0df45279a7a8796
[ "MIT" ]
1
2020-07-04T11:42:17.000Z
2020-07-04T11:42:17.000Z
from django.core.management.base import BaseCommand from webinterface.email_sending import send_email__assignment_coming_up, send_email__warn_admin_tasks_forgotten class Command(BaseCommand): help = 'Call multiple functions which may send emails if their conditions are met. ' \ 'Calls the send_email__a...
47.923077
111
0.778491
6e105b54ac417dbf388a40e0854cf3d9b7653593
55
py
Python
Algorithms/Implementation/extra-long-factorials.py
rho2/HackerRank
4d9cdfcabeb20212db308d8e4f2ac1b8ebf7d266
[ "MIT" ]
null
null
null
Algorithms/Implementation/extra-long-factorials.py
rho2/HackerRank
4d9cdfcabeb20212db308d8e4f2ac1b8ebf7d266
[ "MIT" ]
null
null
null
Algorithms/Implementation/extra-long-factorials.py
rho2/HackerRank
4d9cdfcabeb20212db308d8e4f2ac1b8ebf7d266
[ "MIT" ]
null
null
null
import math n = int(input()) print(math.factorial(n))
11
24
0.690909
2547414876299da47a63285781398f1f60d3beaf
231
py
Python
exercises/en/exc_01_02_03.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
2,085
2019-04-17T13:10:40.000Z
2022-03-30T21:51:46.000Z
exercises/en/exc_01_02_03.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
79
2019-04-18T14:42:55.000Z
2022-03-07T08:15:43.000Z
exercises/en/exc_01_02_03.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
361
2019-04-17T13:34:32.000Z
2022-03-28T04:42:45.000Z
# Import the Spanish language class from spacy.lang.____ import ____ # Create the nlp object nlp = ____ # Process a text (this is Spanish for: "How are you?") doc = nlp("¿Cómo estás?") # Print the document text print(____.text)
19.25
54
0.718615
b0ade1e572f71a104926fb6f53a0818d0c3d3646
1,633
py
Python
games/rpg/testbed.py
etigerstudio/zilong-on-fire
5144a471b2d39ea38a47d394e648de00dd13cd8b
[ "MIT" ]
2
2021-01-07T01:10:49.000Z
2022-01-21T09:37:16.000Z
games/rpg/testbed.py
etigerstudio/zilong-on-fire
5144a471b2d39ea38a47d394e648de00dd13cd8b
[ "MIT" ]
null
null
null
games/rpg/testbed.py
etigerstudio/zilong-on-fire
5144a471b2d39ea38a47d394e648de00dd13cd8b
[ "MIT" ]
null
null
null
from envs.base import StateFormat from envs.rpg.rpg import RPGEnvironment from envs.rpg.levels.teasure_tutorial import TreasureTutorial from envs.rpg.levels.medium_tutorial import MediumTutorial from envs.rpg.levels.large_tutorial import LargeTutorial from envs.rpg.levels.small_tutorial import SmallTutorial from envs.r...
34.020833
62
0.630741
b018468672ccf9528c4e5e9ac1eceed81e8e4b63
486
py
Python
constant.py
ChristianKitte/Textextraktion-und-Einordnung-mit-Hilfe-neuronaler-Netze
53d3fc6b1c17f31146741cdebd743f4aa12a09e0
[ "MIT" ]
null
null
null
constant.py
ChristianKitte/Textextraktion-und-Einordnung-mit-Hilfe-neuronaler-Netze
53d3fc6b1c17f31146741cdebd743f4aa12a09e0
[ "MIT" ]
16
2020-01-28T23:04:13.000Z
2022-03-12T00:02:40.000Z
constant.py
ChristianKitte/Textextraktion-und-Einordnung-mit-Hilfe-neuronaler-Netze
53d3fc6b1c17f31146741cdebd743f4aa12a09e0
[ "MIT" ]
null
null
null
"""Defines global constants of the program. """ INPUT_DIR = 'income' """input directory""" OUTPUT_DIR = 'outcome' """output directory""" EVALUATION_DIR = 'evaluation' """evaluation directory""" DATABASE_JSON = 'data/ingrediens.json' """Location of the JSON database of ingredients""" DATABASE_EXCEL = 'data...
27
53
0.711934
b051c7372732852cd6e01f7e7671d8e24e49e8ce
4,149
py
Python
tests/view/test_console_view.py
jonashellmann/informaticup21-team-chillow
f2e519af0a5d9a9368d62556703cfb1066ebb58f
[ "MIT" ]
3
2021-01-17T23:32:07.000Z
2022-01-30T14:49:16.000Z
tests/view/test_console_view.py
jonashellmann/informaticup21-team-chillow
f2e519af0a5d9a9368d62556703cfb1066ebb58f
[ "MIT" ]
2
2021-01-17T13:37:56.000Z
2021-04-14T12:28:49.000Z
tests/view/test_console_view.py
jonashellmann/informaticup21-team-chillow
f2e519af0a5d9a9368d62556703cfb1066ebb58f
[ "MIT" ]
2
2021-04-02T14:53:38.000Z
2021-04-20T11:10:17.000Z
import io import unittest from datetime import datetime from unittest.mock import patch from chillow.model.action import Action from chillow.model.cell import Cell from chillow.model.direction import Direction from chillow.model.game import Game from chillow.model.player import Player from chillow.view.console_view i...
43.673684
101
0.683056
bbf3e896b7303b4a3b4ff04290605f01e5e0af6f
1,884
py
Python
Packs/CortexXDR/Scripts/CortexXDRRemediationActionsWidget/CortexXDRRemediationActionsWidget.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/CortexXDR/Scripts/CortexXDRRemediationActionsWidget/CortexXDRRemediationActionsWidget.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/CortexXDR/Scripts/CortexXDRRemediationActionsWidget/CortexXDRRemediationActionsWidget.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
from CommonServerPython import * import traceback ''' STANDALONE FUNCTION ''' def get_remediation_info() -> Dict: remediation_actions = demisto.get(demisto.context(), 'RemediationActions') if not remediation_actions: raise DemistoException('RemediationActions not in context') blocked_ip_addresse...
37.68
116
0.737261
3c4cabdf27673e89b8248ee25bf6d3f2f39a5adf
2,896
py
Python
test/demonst_1_sleep_data.py
saeyoung/tslb
5f52646260e14f44c61a670cfc75509951e5e794
[ "MIT" ]
null
null
null
test/demonst_1_sleep_data.py
saeyoung/tslb
5f52646260e14f44c61a670cfc75509951e5e794
[ "MIT" ]
3
2020-03-24T18:18:21.000Z
2021-08-23T20:37:09.000Z
test/demonst_1_sleep_data.py
saeyoung/tslb
5f52646260e14f44c61a670cfc75509951e5e794
[ "MIT" ]
null
null
null
############################################################# # # Real-world Data 1. Sleep Data # ############################################################# 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 fro...
27.065421
91
0.530387
f950670fb2860124a09ff1c48f2028ca18e28f9f
99
py
Python
hello/hello-eve/run.py
East196/hello-py
a77c7a0c8e5e2b5e8cefaf0fda335ab0c3b1da21
[ "Apache-2.0" ]
1
2017-10-23T14:58:47.000Z
2017-10-23T14:58:47.000Z
hello/hello-eve/run.py
East196/hello-py
a77c7a0c8e5e2b5e8cefaf0fda335ab0c3b1da21
[ "Apache-2.0" ]
null
null
null
hello/hello-eve/run.py
East196/hello-py
a77c7a0c8e5e2b5e8cefaf0fda335ab0c3b1da21
[ "Apache-2.0" ]
1
2018-04-06T07:49:18.000Z
2018-04-06T07:49:18.000Z
from eve import Eve app = Eve() if __name__ == '__main__': print("start eve~~~") app.run()
16.5
26
0.59596
f9559b713c36b3ae34aa277641c10a100ff3a755
700
py
Python
restful04/app.py
gaohj/nzflask_bbs
36a94c380b78241ed5d1e07edab9618c3e8d477b
[ "Apache-2.0" ]
null
null
null
restful04/app.py
gaohj/nzflask_bbs
36a94c380b78241ed5d1e07edab9618c3e8d477b
[ "Apache-2.0" ]
27
2020-02-12T07:55:58.000Z
2022-03-12T00:19:09.000Z
restful04/app.py
gaohj/nzflask_bbs
36a94c380b78241ed5d1e07edab9618c3e8d477b
[ "Apache-2.0" ]
2
2020-02-18T01:54:55.000Z
2020-02-21T11:36:28.000Z
from flask import Flask import config from extensions import db from article_view import bp from users import user_bp from models import User,Article,Tag app = Flask(__name__) app.config.from_object(config) app.register_blueprint(bp) app.register_blueprint(user_bp) db.init_app(app) @app.route('/') def hello_world(): ...
23.333333
53
0.717143
34fe6ef106b09daf23dcc571bc2fa8cc3ed318c4
562
py
Python
source/pkgsrc/lang/python27/patches/patch-Lib_distutils_util.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
1
2021-11-20T22:46:39.000Z
2021-11-20T22:46:39.000Z
source/pkgsrc/lang/python27/patches/patch-Lib_distutils_util.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
null
null
null
source/pkgsrc/lang/python27/patches/patch-Lib_distutils_util.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
null
null
null
$NetBSD: patch-Lib_distutils_util.py,v 1.1 2018/06/17 19:21:21 adam Exp $ --- Lib/distutils/util.py.orig 2014-12-10 15:59:35.000000000 +0000 +++ Lib/distutils/util.py @@ -101,6 +101,8 @@ def get_platform (): osname, release, machine = _osx_support.get_platform_osx( dis...
40.142857
79
0.565836
9bb1eaeaa06ee5abe06a0d209def7279a5e450fe
1,386
py
Python
py_projects/image_to_sketch/image_to_sketch.py
Anwesha-dash811/hacktober-1
188c859864f06f94a94cb91e63979366db62b9ac
[ "MIT" ]
1
2020-10-04T12:36:45.000Z
2020-10-04T12:36:45.000Z
py_projects/image_to_sketch/image_to_sketch.py
Anwesha-dash811/hacktober-1
188c859864f06f94a94cb91e63979366db62b9ac
[ "MIT" ]
1
2021-09-30T16:20:57.000Z
2021-09-30T16:20:57.000Z
py_projects/image_to_sketch/image_to_sketch.py
Anwesha-dash811/hacktober-1
188c859864f06f94a94cb91e63979366db62b9ac
[ "MIT" ]
3
2020-10-04T10:07:10.000Z
2020-10-25T15:21:15.000Z
pip install imageio //to install imageio package import imageio import requests import numpy as np import matplotlib.pyplot as plt import IPython.display as dp //to read the image using imread() img="flower.jpg" source_img=imageio.imread(img) //making the image black and white by applying greyscale def ...
34.65
106
0.769841
b5f91119f76ebc167d300efe1f15d48506aef5f7
1,568
py
Python
python/fastcampus/chapter03_02.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
python/fastcampus/chapter03_02.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
python/fastcampus/chapter03_02.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
"""Dict""" from typing import List source = [ ("k1", "val1"), ("k1", "val2"), ("k2", "val3"), ("k2", "val4"), ("k2", "val5"), ] # No use setdefault d1 = {} for k, v in source: if k in d1: d1[k].append(v) else: d1[k] = [v] print(d1) # Use setdefault d2 = {} for k, v in sour...
18.232558
51
0.583546
23dca1fc441093582b31e42a108b69e078736287
1,005
py
Python
src/utils/serialportreader.py
muhammedtiftikci/Proje-A
363ddb8e03afe0387d144621479ed742d2d40dc6
[ "MIT" ]
null
null
null
src/utils/serialportreader.py
muhammedtiftikci/Proje-A
363ddb8e03afe0387d144621479ed742d2d40dc6
[ "MIT" ]
null
null
null
src/utils/serialportreader.py
muhammedtiftikci/Proje-A
363ddb8e03afe0387d144621479ed742d2d40dc6
[ "MIT" ]
null
null
null
import RPi.GPIO as GPIO from time import sleep import serial from direction import Coordinate from clientsocket import ClientSocket client_socket = ClientSocket("192.168.1.8", 37037, 1024) serial_port_reader = serial.Serial( port='/dev/ttyS0', baudrate=9600, timeout=1 ) def dmm2dd(dmm): dmm_str = str(dmm) ...
18.962264
68
0.711443
7b92755c74c266e5704efd50648bf56c96fc29c6
834
py
Python
INBa/2015/Shemenev_A_V/task_4_30.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
INBa/2015/Shemenev_A_V/task_4_30.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
INBa/2015/Shemenev_A_V/task_4_30.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
# Задача 4. Вариант 30. #Напишите программу, которая выводит имя, под которым скрывается Вильгельм Аполлинарий Костровицкий. Дополнительно необходимо вывести область интересов указанной личности, место рождения, годы рождения и смерти (если человек умер), вычислить возраст на данный момент (или момент смерти). Для хран...
49.058824
454
0.805755
7b9937e5e3b6819c6b0d560356e5650b5934e072
4,368
py
Python
rrcf_anomaly_detection.py
JoelHaubold/NzmLabeling
363c027ce6584899025f79ea4758e1808b2aa96a
[ "MIT" ]
null
null
null
rrcf_anomaly_detection.py
JoelHaubold/NzmLabeling
363c027ce6584899025f79ea4758e1808b2aa96a
[ "MIT" ]
null
null
null
rrcf_anomaly_detection.py
JoelHaubold/NzmLabeling
363c027ce6584899025f79ea4758e1808b2aa96a
[ "MIT" ]
null
null
null
import os from pathlib import Path import matplotlib.pyplot as plt import numpy as np import pandas as pd import rrcf plot_directory = Path("../rrcf_plots") def get_file_names(file_directory): file_names = os.listdir(file_directory) file_names = list(filter(lambda f_path: os.path.isdir(file_directory / f_pat...
33.860465
140
0.669414
cdcd45279dbf5ca79abf715f67cc054dab1726d4
1,005
py
Python
python/en/_numpy/organize_this/test_numpy.fftshift_example_01.py
aimldl/coding
70ddbfaa454ab92fd072ee8dc614ecc330b34a70
[ "MIT" ]
null
null
null
python/en/_numpy/organize_this/test_numpy.fftshift_example_01.py
aimldl/coding
70ddbfaa454ab92fd072ee8dc614ecc330b34a70
[ "MIT" ]
null
null
null
python/en/_numpy/organize_this/test_numpy.fftshift_example_01.py
aimldl/coding
70ddbfaa454ab92fd072ee8dc614ecc330b34a70
[ "MIT" ]
null
null
null
""" test_numpy.fftshift_example_01.py This is an example code for numpy.fft.fftshift https://docs.scipy.org/doc/numpy/reference/generated/numpy.fft.fftshift.html#numpy.fft.fftshift More in general, Discrete Fourier Transform (numpy.fft) https://docs.scipy.org/doc/numpy/reference/routines.fft.html """ import numpy as...
27.916667
95
0.587065
b52f55929f251139f1b2851ff936e0580a3133f0
3,373
py
Python
tools/vasp_fix_layer_v2.0.py
cwandtj/A2P2
a5999f6dbcd7da194fbded8b8c113affdb419c3b
[ "MIT" ]
1
2017-08-25T07:46:30.000Z
2017-08-25T07:46:30.000Z
tools/vasp_fix_layer_v2.0.py
cwandtj/A2P2
a5999f6dbcd7da194fbded8b8c113affdb419c3b
[ "MIT" ]
null
null
null
tools/vasp_fix_layer_v2.0.py
cwandtj/A2P2
a5999f6dbcd7da194fbded8b8c113affdb419c3b
[ "MIT" ]
null
null
null
#!/usr/bin/env python import time, sys, os, copy, subprocess from datetime import datetime import numpy as np from ase.io import vasp, read, write import NanoCore as nc version = 20171211 now_time = datetime.now() usage = ' Usage: %s [POSCAR or CONTCAR] \n ' % sys.argv[0] foottext = '\n Thank you\n## Yoon Su Shim <...
22.637584
109
0.505485
a5f2336f0ee0a0211ff6e96a4b65550a648f287c
554
py
Python
app/models/category.py
kalbe09/Kicards
ad64cfa808307b10f98f95dbb8cf0350995c3afd
[ "MIT" ]
null
null
null
app/models/category.py
kalbe09/Kicards
ad64cfa808307b10f98f95dbb8cf0350995c3afd
[ "MIT" ]
null
null
null
app/models/category.py
kalbe09/Kicards
ad64cfa808307b10f98f95dbb8cf0350995c3afd
[ "MIT" ]
null
null
null
from .. import db from datetime import datetime class Category(db.Model): __tablename__ = 'category' id = db.Column(db.Integer, primary_key=True) name = db.Column(db.String(64), index=True) duedate = db.Column(db.Date) # Datefield # datetime.strptime('09.19.2018', '%m.%d.%Y').date()) prio = ...
30.777778
84
0.66065
93fe5da693b5b7c4fae75faaa39e5b15f3d8983f
862
py
Python
frappe-bench/apps/erpnext/erpnext/portal/utils.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/portal/utils.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/portal/utils.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
import frappe def set_default_role(doc, method): '''Set customer, supplier, student, guardian based on email''' if frappe.flags.setting_role or frappe.flags.in_migrate: return roles = frappe.get_roles(doc.name) contact_name = frappe.get_value('Contact', dict(email_id=doc.email)) if contact_name: contact = f...
37.478261
95
0.7471
f59b43ff5a3f6bd0781be49a4c8b274c9c904a0b
1,996
py
Python
Co-Simulation/Sumo/sumo-1.7.0/tools/import/visum/visum_convertEdgeTypes.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/import/visum/visum_convertEdgeTypes.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/import/visum/visum_convertEdgeTypes.py
uruzahe/carla
940c2ab23cce1eda1ef66de35f66b42d40865fb1
[ "MIT" ]
1
2020-11-20T19:31:26.000Z
2020-11-20T19:31:26.000Z
#!/usr/bin/env python # Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo # Copyright (C) 2009-2020 German Aerospace Center (DLR) and others. # This program and the accompanying materials are made available under the # terms of the Eclipse Public License 2.0 which is available at # https://www.ec...
34.413793
77
0.650802
193780b6e401a0b1cbe9e0e0d6abde97fdb76fac
9,856
py
Python
Packs/CyberTotal/Integrations/CyberTotal/CyberTotal_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/CyberTotal/Integrations/CyberTotal/CyberTotal_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/CyberTotal/Integrations/CyberTotal/CyberTotal_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
"""CyberTotal Integration for Cortex XSOAR - Unit Tests file This file contains the Unit Tests for the CyberTotal Integration based on pytest. Cortex XSOAR contribution requirements mandate that every integration should have a proper set of unit tests to automatically verify that the integration is behaving as expected...
34.582456
112
0.691863
27219675efcb887f3cf2f887ccefd0e30da413a7
7,193
py
Python
scripts/feedforwardness_data.py
tliu68/maggot_connectome
ef4bbd2011fa9e03da187fcca8c8c1ca79209a36
[ "MIT" ]
1
2021-01-20T00:37:31.000Z
2021-01-20T00:37:31.000Z
scripts/feedforwardness_data.py
tliu68/maggot_connectome
ef4bbd2011fa9e03da187fcca8c8c1ca79209a36
[ "MIT" ]
17
2021-03-03T14:48:54.000Z
2021-09-08T15:52:50.000Z
scripts/feedforwardness_data.py
tliu68/maggot_connectome
ef4bbd2011fa9e03da187fcca8c8c1ca79209a36
[ "MIT" ]
2
2021-03-05T12:23:20.000Z
2021-03-29T11:49:53.000Z
#%% [markdown] # # One-sample feedforwardness testing: data # Here we apply the test statistic $p_{upper}$ (see {doc}`./bilateral_symmetry`) to our # four observed networks and compare to randomly sampled networks from null models. #%% [markdown] # ## Preliminaries #%% from pkg.utils import set_warnings import dateti...
31.687225
88
0.65105
27e9797e7f85b8aee3fe439c92ccea057fd8c567
7,984
py
Python
tests/onegov/gazette/conftest.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/gazette/conftest.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/gazette/conftest.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from datetime import date from datetime import datetime from tests.shared.utils import create_app from onegov.core.crypto import hash_password from onegov.gazette import GazetteApp from onegov.gazette.collections import CategoryCollection from onegov.gazette.collections import IssueCollection from onegov.gazette.collec...
31.309804
78
0.651428
e37c8d8eadd51ba3df5b778ac22d177d9bfc14a3
1,651
py
Python
teams/team_snapback/Website/main.py
AbinMM/PYNQ_Hackathon_2017
711c75e8590b02f313295cef712188691690c948
[ "BSD-3-Clause" ]
19
2017-10-08T03:18:38.000Z
2020-07-07T02:34:18.000Z
teams/team_snapback/Website/main.py
AbinMM/PYNQ_Hackathon_2017
711c75e8590b02f313295cef712188691690c948
[ "BSD-3-Clause" ]
2
2017-10-08T03:15:10.000Z
2017-10-10T16:10:32.000Z
teams/team_snapback/Website/main.py
AbinMM/PYNQ_Hackathon_2017
711c75e8590b02f313295cef712188691690c948
[ "BSD-3-Clause" ]
28
2017-10-07T23:24:36.000Z
2022-03-29T08:03:40.000Z
from flask import Flask from flask import render_template from flask import abort, redirect, url_for from flask import request, send_from_directory import requests import dropbox import updown import json import config TOKEN = config.dropbox_key dbx = dropbox.Dropbox(TOKEN) fileLists = updown.list_folder(dbx, "SnapBac...
23.253521
73
0.691096
7beedc415c8d3752a78244dab994e3e8e276a046
124
py
Python
scripts/hello_world_tj.py
breezage/Hacktoberfest-1
6f6d52248c79c0e72fd13b599500318fce3f9ab0
[ "MIT" ]
null
null
null
scripts/hello_world_tj.py
breezage/Hacktoberfest-1
6f6d52248c79c0e72fd13b599500318fce3f9ab0
[ "MIT" ]
null
null
null
scripts/hello_world_tj.py
breezage/Hacktoberfest-1
6f6d52248c79c0e72fd13b599500318fce3f9ab0
[ "MIT" ]
1
2019-10-24T06:45:21.000Z
2019-10-24T06:45:21.000Z
// LANGUAGE: python // ENV: notepad++ // AUTHOR: TJ Bollerman // GITHUB: https://github.com/tjboller print("hello world")
15.5
38
0.677419
7bf58884d0afdf73b1d03817d6fd90d18311d422
1,032
py
Python
angstrom/2021/misc/TI-1337_Nspire/ti1337nspire.py
mystickev/ctf-archives
89e99a5cd5fb6b2923cad3fe1948d3ff78649b4e
[ "MIT" ]
1
2021-11-02T20:53:58.000Z
2021-11-02T20:53:58.000Z
angstrom/2021/misc/TI-1337_Nspire/ti1337nspire.py
ruhan-islam/ctf-archives
8c2bf6a608c821314d1a1cfaa05a6cccef8e3103
[ "MIT" ]
null
null
null
angstrom/2021/misc/TI-1337_Nspire/ti1337nspire.py
ruhan-islam/ctf-archives
8c2bf6a608c821314d1a1cfaa05a6cccef8e3103
[ "MIT" ]
1
2021-12-19T11:06:24.000Z
2021-12-19T11:06:24.000Z
#!/run/cpython/python from multiprocessing import Process, Queue def sandbox(calculation, result): from sys import addaudithook from os import _exit import constants code = compile(calculation, '<math>', 'exec') def audit(name, args): if not audit.calculated and name == 'exec': audit.calculuated = True els...
27.157895
64
0.638566