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
17b328f0e82744b91ceb1e856b4c428328eebbbd
569
py
Python
leetcode/665-Non-decreasing-Array/NonDecreasingArr.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2015-12-16T04:01:03.000Z
2015-12-16T04:01:03.000Z
leetcode/665-Non-decreasing-Array/NonDecreasingArr.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-02-09T06:00:07.000Z
2016-02-09T07:20:13.000Z
leetcode/665-Non-decreasing-Array/NonDecreasingArr.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
2
2019-06-27T09:07:26.000Z
2019-07-01T04:40:13.000Z
class Solution(object): def checkPossibility(self, nums): """ :type nums: List[int] :rtype: bool """ is_modified = False for i in xrange(len(nums) - 1): if nums[i] > nums[i + 1]: if is_modified: return False ...
28.45
60
0.379613
35019a8cdcdc4bd46aae8b294cf7d088d7c2a1b4
6,727
py
Python
pyScript_NodeManager/NodeInput.py
Shirazbello/Pyscriptining
0f2c80a9bb10477d65966faeccc7783f20385c1b
[ "MIT" ]
null
null
null
pyScript_NodeManager/NodeInput.py
Shirazbello/Pyscriptining
0f2c80a9bb10477d65966faeccc7783f20385c1b
[ "MIT" ]
null
null
null
pyScript_NodeManager/NodeInput.py
Shirazbello/Pyscriptining
0f2c80a9bb10477d65966faeccc7783f20385c1b
[ "MIT" ]
null
null
null
from PySide2.QtWidgets import QWidget, QPlainTextEdit, QRadioButton, QGridLayout, QPushButton, QComboBox, QLineEdit, QMessageBox, QGroupBox, QVBoxLayout class NodeInput(QWidget): def __init__(self, content_widget): super(NodeInput, self).__init__() self.content_widget = content_widget sel...
42.04375
152
0.704326
dcb7dde46743662af9ff8f47290bed7f12d2002c
3,199
py
Python
exercises/networking_selfpaced/networking-workshop/collections/ansible_collections/community/general/tests/unit/plugins/lookup/test_avi.py
tr3ck3r/linklight
5060f624c235ecf46cb62cefcc6bddc6bf8ca3e7
[ "MIT" ]
null
null
null
exercises/networking_selfpaced/networking-workshop/collections/ansible_collections/community/general/tests/unit/plugins/lookup/test_avi.py
tr3ck3r/linklight
5060f624c235ecf46cb62cefcc6bddc6bf8ca3e7
[ "MIT" ]
null
null
null
exercises/networking_selfpaced/networking-workshop/collections/ansible_collections/community/general/tests/unit/plugins/lookup/test_avi.py
tr3ck3r/linklight
5060f624c235ecf46cb62cefcc6bddc6bf8ca3e7
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # (c) 2019, Sandeep Bandi <sandeepb@avinetworks.com> # # This file is part of Ansible # # Ansible is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (...
34.397849
89
0.727727
87721dc837cfcc46d6cb41435ab729954799560c
541
py
Python
exercises/es/test_02_05_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
2,085
2019-04-17T13:10:40.000Z
2022-03-30T21:51:46.000Z
exercises/es/test_02_05_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
79
2019-04-18T14:42:55.000Z
2022-03-07T08:15:43.000Z
exercises/es/test_02_05_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
361
2019-04-17T13:34:32.000Z
2022-03-28T04:42:45.000Z
def test(): assert ( "from spacy.tokens import Doc" in __solution__ ), "¿Estás importando la clase Doc correctamente?" assert ( len(spaces) == 5 ), "Parece que el número de espacios no concuerda con el número de palabras." assert all(isinstance(s, bool) for s in spaces), "Los espacio...
45.083333
93
0.645102
df185f518b1ffb96918cba7daa6cf65f80a3bf83
598
py
Python
serve.py
lurch/Pinout2
bd3b39de2c053607b9415dd9eb0297a401ba7162
[ "CC-BY-4.0" ]
null
null
null
serve.py
lurch/Pinout2
bd3b39de2c053607b9415dd9eb0297a401ba7162
[ "CC-BY-4.0" ]
null
null
null
serve.py
lurch/Pinout2
bd3b39de2c053607b9415dd9eb0297a401ba7162
[ "CC-BY-4.0" ]
null
null
null
#!/usr/bin/env python from flask import Flask, send_from_directory import sys app = Flask(__name__) lang = 'en' @app.route('/') def show_index(): return send_from_directory(basedir,'index.html') @app.route("/resources/<path:filename>") def custom_static(filename): return send_from_directory(basedir + 'resources/',...
21.357143
61
0.70903
df812269ac879c53fb5ed863c8c091f330f4846f
228
py
Python
personal-files/python-test/test.py
lyf0327/PycharmProjects
ce6507f04a33156a0d6c3f732856dcb655bc2351
[ "Apache-2.0" ]
null
null
null
personal-files/python-test/test.py
lyf0327/PycharmProjects
ce6507f04a33156a0d6c3f732856dcb655bc2351
[ "Apache-2.0" ]
null
null
null
personal-files/python-test/test.py
lyf0327/PycharmProjects
ce6507f04a33156a0d6c3f732856dcb655bc2351
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python # -*- coding:UTF-8 -*- from sys import argv script, filename = argv txt=open(filename) print txt.read() file_again=raw_input("> ") txg_again=open(file_again) print txg_again.read() txt.close() txg_again.close()
20.727273
26
0.72807
63733bb1acddaa24e368933c4cfe58bd56e53809
212
py
Python
Theories/Algorithms/Recursion1/ReverseString/reverse_string.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
1
2021-08-16T14:52:05.000Z
2021-08-16T14:52:05.000Z
Theories/Algorithms/Recursion1/ReverseString/reverse_string.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
Theories/Algorithms/Recursion1/ReverseString/reverse_string.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
from typing import List def reverseString(s: List[str]) -> None: """ Do not return anything, modify s in-place instead. """ for i in range(len(s) // 2): s[i], s[-i - 1] = s[-i - 1], s[i]
23.555556
54
0.537736
8967e17c2b719b250094aa362ace32622a48bc56
1,067
py
Python
00 Calculus Operations in SymPy.py
Verma314/Experiments-in-Symbolic-Computation
baf800c5ff69cc125df8c84ab93c4f40a7aba725
[ "MIT" ]
null
null
null
00 Calculus Operations in SymPy.py
Verma314/Experiments-in-Symbolic-Computation
baf800c5ff69cc125df8c84ab93c4f40a7aba725
[ "MIT" ]
null
null
null
00 Calculus Operations in SymPy.py
Verma314/Experiments-in-Symbolic-Computation
baf800c5ff69cc125df8c84ab93c4f40a7aba725
[ "MIT" ]
null
null
null
from sympy import * #define sympy symbols for x , t , z , nu = symbols ('x t z nu') #for pretty printing: init_printing ( use_unicode=True) #take a derivative of [ sin (x) e ^ x ] print (" Diffrentiating sin (x) e ^ x ") print ( diff ( sin ( x ) * exp (x), x)) #integration: print ( "\n Integrating t...
27.358974
69
0.56701
98730936a520d6e0bb3dfcfd99ec7be3b5175c16
2,796
py
Python
kts/core/backend/signal.py
konodyuk/kts
3af5ccbf1d2089cb41d171626fcde4b0ba5aa8a7
[ "MIT" ]
18
2019-02-14T13:10:07.000Z
2021-11-26T07:10:13.000Z
kts/core/backend/signal.py
konodyuk/kts
3af5ccbf1d2089cb41d171626fcde4b0ba5aa8a7
[ "MIT" ]
2
2019-02-17T14:06:42.000Z
2019-09-15T18:05:54.000Z
kts/core/backend/signal.py
konodyuk/kts
3af5ccbf1d2089cb41d171626fcde4b0ba5aa8a7
[ "MIT" ]
2
2019-09-15T13:12:42.000Z
2020-04-15T14:05:54.000Z
import os from collections import defaultdict from typing import Union, Tuple, List, Any import ray from kts.core.run_id import RunID try: from ray.experimental import get_actor # ray<=0.8.1 except ImportError: from ray.util import get_actor # ray>=0.8.2 def _get_task_id(source): if type(sour...
24.103448
73
0.64628
7f83f70ca09f602baaa5bde57979658c4e48db88
583
py
Python
products/migrations/0002_amazoncategory_sales_rank.py
silver-whale-enterprises-llc/amzproduzer
25e63f64b0ef09241475c72af9a710dcb7d9e926
[ "Apache-2.0" ]
1
2019-07-22T14:03:11.000Z
2019-07-22T14:03:11.000Z
products/migrations/0002_amazoncategory_sales_rank.py
silver-whale-enterprises-llc/amzproduzer
25e63f64b0ef09241475c72af9a710dcb7d9e926
[ "Apache-2.0" ]
null
null
null
products/migrations/0002_amazoncategory_sales_rank.py
silver-whale-enterprises-llc/amzproduzer
25e63f64b0ef09241475c72af9a710dcb7d9e926
[ "Apache-2.0" ]
null
null
null
# Generated by Django 2.1.7 on 2019-03-16 14:58 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('configurations', '0001_initial'), ('products', '0001_initial'), ] operations = [ migrations.AddFiel...
27.761905
170
0.658662
63e277177ce2004787ea9567977b39099b96ebe7
1,066
bzl
Python
tools/platforms/toolchain_config_suite_spec.bzl
wcalandro/kythe
64969a853711c228b4e3cfc3ce91b84b5bb853d7
[ "Apache-2.0" ]
703
2018-11-05T22:51:58.000Z
2022-03-31T21:54:22.000Z
tools/platforms/toolchain_config_suite_spec.bzl
wcalandro/kythe
64969a853711c228b4e3cfc3ce91b84b5bb853d7
[ "Apache-2.0" ]
720
2018-11-05T21:29:49.000Z
2022-03-29T19:43:50.000Z
tools/platforms/toolchain_config_suite_spec.bzl
wcalandro/kythe
64969a853711c228b4e3cfc3ce91b84b5bb853d7
[ "Apache-2.0" ]
99
2018-11-06T22:20:08.000Z
2022-03-16T12:50:35.000Z
# Copyright 2020 The Kythe Authors. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law...
39.481481
79
0.754221
89e684f23e912f35b1d93b1cf51a643243c6a207
10,538
py
Python
examples/model_interpretation/rationale_extraction/newp_text_generate.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
examples/model_interpretation/rationale_extraction/newp_text_generate.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
examples/model_interpretation/rationale_extraction/newp_text_generate.py
mukaiu/PaddleNLP
0315365dbafa6e3b1c7147121ba85e05884125a5
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2022 PaddlePaddle Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by app...
33.138365
80
0.638546
89fe1e6c6b51baaffbd930436027c6f14a2b82ee
210
py
Python
etc/ipcdemo/B.py
huberthoegl/tsgrain
405d0ba8b98c2afa950d27294e55cd1e07506db4
[ "Apache-2.0" ]
1
2021-06-15T08:59:02.000Z
2021-06-15T08:59:02.000Z
etc/ipcdemo/B.py
huberthoegl/tsgrain
405d0ba8b98c2afa950d27294e55cd1e07506db4
[ "Apache-2.0" ]
null
null
null
etc/ipcdemo/B.py
huberthoegl/tsgrain
405d0ba8b98c2afa950d27294e55cd1e07506db4
[ "Apache-2.0" ]
null
null
null
import time import ipc ipc.open() ab = ipc.AtoB() ba = ipc.BtoA() n = 0 while True: msg = ab.getb() # blocking get ba.put("bla") time.sleep(1) n = n + 1 if n % 50 == 0: print(n)
12.352941
35
0.514286
d61ce7ba203e31ce62c99595e2c5ae79bee8369c
814
py
Python
pythonProj/FZPython/datas/datas.py
iHamburg/FZQuant
86b750ec33d01badfd3f324d6f1599118b9bf8ff
[ "MIT" ]
null
null
null
pythonProj/FZPython/datas/datas.py
iHamburg/FZQuant
86b750ec33d01badfd3f324d6f1599118b9bf8ff
[ "MIT" ]
null
null
null
pythonProj/FZPython/datas/datas.py
iHamburg/FZQuant
86b750ec33d01badfd3f324d6f1599118b9bf8ff
[ "MIT" ]
2
2019-04-10T10:05:00.000Z
2021-11-24T17:17:23.000Z
#!/usr/bin/env python # coding: utf8 import tushare as ts import backtrader as bt import pandas as pd #下载上证综指 20年的数据 codeList = [] df = ts.get_k_data('000002',index=False,start='1990-01-01') # df = ts.get_k_data('600435',index=True,start='2016-01-01') df = df.set_index('date') # df.to_csv('index/399006.csv', column...
24.666667
79
0.59828
61a6a97a3a0e8481d6750c4a618a7570c7281e48
849
py
Python
system/withdraw.py
billalxcode/ATM-cli
68e295b1e3c152ee5c35913af84d72468cab06e0
[ "MIT" ]
null
null
null
system/withdraw.py
billalxcode/ATM-cli
68e295b1e3c152ee5c35913af84d72468cab06e0
[ "MIT" ]
null
null
null
system/withdraw.py
billalxcode/ATM-cli
68e295b1e3c152ee5c35913af84d72468cab06e0
[ "MIT" ]
null
null
null
from .database import Database class Withdraw: def __init__(self) -> None: self.connection = Database("database/database.db") self.connection.connect() def get(self, card, nominal=0): if int(nominal) <= 10000: print ("[INFO]: Minimal penarikan 10 ribu") return F...
38.590909
100
0.552415
4eeaf58a17ac8c23669f9ce4e5b6c9559977c847
516
py
Python
tensorflow/2.1-gpu/save.py
newnius/YAO-Dockerfiles
eb0e494f20dcc0959ef550e4bf55e2015baf45ec
[ "Apache-2.0" ]
2
2020-07-29T08:57:40.000Z
2020-07-31T06:38:25.000Z
tensorflow/1.14-gpu/save.py
newnius/YAO-Dockerfiles
eb0e494f20dcc0959ef550e4bf55e2015baf45ec
[ "Apache-2.0" ]
null
null
null
tensorflow/1.14-gpu/save.py
newnius/YAO-Dockerfiles
eb0e494f20dcc0959ef550e4bf55e2015baf45ec
[ "Apache-2.0" ]
2
2020-07-29T09:01:59.000Z
2020-12-17T13:07:34.000Z
from hdfs import * import os import time if __name__ == '__main__': os.environ["TZ"] = 'Asia/Shanghai' if hasattr(time, 'tzset'): time.tzset() try: hdfs_address = os.environ['hdfs_address'] hdfs_dir = os.environ['hdfs_dir'] output_dir = os.environ['output_dir'] client = Client(hdfs_addr...
24.571429
71
0.653101
f624bb6227580bc61e0e6a8eb43dfd9747bc731f
230
py
Python
Licence 2/I33/TP 2/ex_2.py
axelcoezard/licence
1ed409c4572dea080169171beb7e8571159ba071
[ "MIT" ]
8
2020-11-26T20:45:12.000Z
2021-11-29T15:46:22.000Z
Licence 2/I33/TP 2/ex_2.py
axelcoezard/licence
1ed409c4572dea080169171beb7e8571159ba071
[ "MIT" ]
null
null
null
Licence 2/I33/TP 2/ex_2.py
axelcoezard/licence
1ed409c4572dea080169171beb7e8571159ba071
[ "MIT" ]
6
2020-10-23T15:29:24.000Z
2021-05-05T19:10:45.000Z
def euclide_e(a, n): u, v = 1, 0 u1, v1 = 0, 1 while n > 0: u1_t = u - a // n * u1 v1_t = v - a // n * v1 u, v = u1, v1 u1, v1 = u1_t, v1_t a, n = n, a - a // n * n; return [u, v, a] print(euclide_e(39, 5))
16.428571
27
0.434783
9c95e15bffddf566c840fe27327f41749dc01a86
541
py
Python
Coursera/Interfacing with the Raspberry Pi/Week-2/Excercise/Server.py
rishav3101/Online-Courses-Learning
1e9356af331b27b6ee33d376d8d7104edaeac2fa
[ "MIT" ]
331
2019-10-22T09:06:28.000Z
2022-03-27T13:36:03.000Z
Coursera/Interfacing with the Raspberry Pi/Week-2/Excercise/Server.py
rishav3101/Online-Courses-Learning
1e9356af331b27b6ee33d376d8d7104edaeac2fa
[ "MIT" ]
8
2020-04-10T07:59:06.000Z
2022-02-06T11:36:47.000Z
Coursera/Interfacing with the Raspberry Pi/Week-2/Excercise/Server.py
rishav3101/Online-Courses-Learning
1e9356af331b27b6ee33d376d8d7104edaeac2fa
[ "MIT" ]
572
2019-07-28T23:43:35.000Z
2022-03-27T22:40:08.000Z
import socket import sys #b if __name__ == '__main__': ip = 'x.x.x.x' port = 1234 mysocket = socket.socket(socket.AF_INET, socket.SOCK_STREAM) try: mysocket.bind((ip, 1234)) except socket.error: print("Failed to bind") sys.exit() mysocket.listen(5) while True:...
19.321429
64
0.57671
14a80c4e214db0e123a0dab4bd743d4715183091
979
py
Python
DataStructures/BalancedTrees/Median.py
baby5/HackerRank
1e68a85f40499adb9b52a4da16936f85ac231233
[ "MIT" ]
null
null
null
DataStructures/BalancedTrees/Median.py
baby5/HackerRank
1e68a85f40499adb9b52a4da16936f85ac231233
[ "MIT" ]
null
null
null
DataStructures/BalancedTrees/Median.py
baby5/HackerRank
1e68a85f40499adb9b52a4da16936f85ac231233
[ "MIT" ]
null
null
null
#coding:utf-8 import bisect N = int(raw_input()) array = [] for _ in range(N): operation, x = raw_input().split() if operation == 'a': #array.append(int(x)) #array.sort() bisect.insort(array, int(x)) length = len(array) if length % 2 == 0: index = length / 2...
26.459459
61
0.443309
2ecb9a5df6a2384cb617dc9d5d10bdedab19dae6
2,547
py
Python
demos/process-results.py
allprojects/thesis-consyst-operation-types
fbed2cabadd96958e11f6f60f531081cee44ad91
[ "Apache-2.0" ]
1
2021-03-30T19:36:13.000Z
2021-03-30T19:36:13.000Z
demos/process-results.py
allprojects/thesis-consyst-operation-types
fbed2cabadd96958e11f6f60f531081cee44ad91
[ "Apache-2.0" ]
null
null
null
demos/process-results.py
allprojects/thesis-consyst-operation-types
fbed2cabadd96958e11f6f60f531081cee44ad91
[ "Apache-2.0" ]
null
null
null
import csv import sys import argparse import os # import plotly.graph_objects as go # import plotly.express as px import pandas as pd import numpy as np, scipy.stats as st arg_parser = argparse.ArgumentParser(description='Process benchmark outputs.') arg_parser.add_argument('output', metavar='Output', help='Name of ...
31.060976
133
0.704751
d33cd300bb9b9d781ad3a18a1eca6b9212de6c31
1,324
py
Python
Source/09_Chat_Industrial/publisher.py
rbiotblbk/WBS_T9_2022
533156db88ff2fe676564b0e5d6e84e888ab0916
[ "MIT" ]
1
2022-02-28T09:49:35.000Z
2022-02-28T09:49:35.000Z
Source/09_Chat_Industrial/publisher.py
rbiotblbk/WBS_T9_2022
533156db88ff2fe676564b0e5d6e84e888ab0916
[ "MIT" ]
null
null
null
Source/09_Chat_Industrial/publisher.py
rbiotblbk/WBS_T9_2022
533156db88ff2fe676564b0e5d6e84e888ab0916
[ "MIT" ]
null
null
null
# pip install pubnub from pubnub.callbacks import SubscribeCallback from pubnub.enums import PNStatusCategory from pubnub.pnconfiguration import PNConfiguration from pubnub.pubnub import PubNub import os from pathlib import Path import json os.chdir(Path(__file__).parent) # Read Config with open("./pubnub.json...
22.440678
86
0.719789
d36912d73bfaa1f71d5eda5b2b7cafb0ba626d2c
322
py
Python
Licence 1/I22/TP 5/tp_5_3.py
axelcoezard/licence
1ed409c4572dea080169171beb7e8571159ba071
[ "MIT" ]
8
2020-11-26T20:45:12.000Z
2021-11-29T15:46:22.000Z
Licence 1/I22/TP 5/tp_5_3.py
axelcoezard/licence
1ed409c4572dea080169171beb7e8571159ba071
[ "MIT" ]
null
null
null
Licence 1/I22/TP 5/tp_5_3.py
axelcoezard/licence
1ed409c4572dea080169171beb7e8571159ba071
[ "MIT" ]
6
2020-10-23T15:29:24.000Z
2021-05-05T19:10:45.000Z
def majuscule(chaine): whitelist = "abcdefghijklmnopqrstuvwxyz" chrs = [chr(ord(c) - 32) if c in whitelist else c for c in chaine] return "".join(chrs) print(majuscule("axel coezard")) def val2ascii(entier): ch = "" for i in range(entier): ch = chr(ord(ch) + 1) print(ch) val2ascii(355...
21.466667
70
0.630435
d3b049472c8a20a967c5e9b77793036d8612972a
419
py
Python
source/blog/migrations/0003_blogpost_author.py
JakubGutowski/PersonalBlog
96122b36486f7e874c013e50d939732a43db309f
[ "BSD-3-Clause" ]
null
null
null
source/blog/migrations/0003_blogpost_author.py
JakubGutowski/PersonalBlog
96122b36486f7e874c013e50d939732a43db309f
[ "BSD-3-Clause" ]
null
null
null
source/blog/migrations/0003_blogpost_author.py
JakubGutowski/PersonalBlog
96122b36486f7e874c013e50d939732a43db309f
[ "BSD-3-Clause" ]
null
null
null
# Generated by Django 2.0.5 on 2018-06-23 18:44 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('blog', '0002_auto_20180616_1236'), ] operations = [ migrations.AddField( model_name='blogpost', name='...
22.052632
69
0.575179
9f2a1cbf98036ecfa33762b217555321b413ef81
1,215
py
Python
src/logging/test/tango_test.py
ska-telescope/sdp-prototype
8c6cbda04a83b0e16987019406ed6ec7e1058a31
[ "BSD-3-Clause" ]
2
2019-07-15T09:49:34.000Z
2019-10-14T16:04:17.000Z
src/logging/test/tango_test.py
ska-telescope/sdp-prototype
8c6cbda04a83b0e16987019406ed6ec7e1058a31
[ "BSD-3-Clause" ]
17
2019-07-15T14:51:50.000Z
2021-06-02T00:29:43.000Z
src/logging/test/tango_test.py
ska-telescope/sdp-configuration-prototype
8c6cbda04a83b0e16987019406ed6ec7e1058a31
[ "BSD-3-Clause" ]
1
2019-10-10T08:16:48.000Z
2019-10-10T08:16:48.000Z
# -*- coding: utf-8 -*- # pylint: disable=invalid-name # pylint: disable=too-few-public-methods # pylint: disable-msg=E0611 # pylint: disable-msg=E0401 # pylint: disable-msg=R0201 # pylint: disable-msg=E1120 # pylint: disable-msg=C0111 # pylint: disable-msg=W0621 # pylint: disable-msg=W0613 # pylint: disable=fixme imp...
25.851064
79
0.704527
e2940c70e0b67269ae269c3ff5a70c9c8fb20cf9
12,191
py
Python
Packs/NetscoutArborSightline/Integrations/NetscoutArborSightline/NetscoutArborSightline_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/NetscoutArborSightline/Integrations/NetscoutArborSightline/NetscoutArborSightline_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/NetscoutArborSightline/Integrations/NetscoutArborSightline/NetscoutArborSightline_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
import json import io from copy import deepcopy import pytest from NetscoutArborSightline import NetscoutClient, \ fetch_incidents_command, list_alerts_command, alert_annotation_list_command, mitigation_list_command, \ mitigation_template_list_command, router_list_command, tms_group_list_command, managed_objec...
41.75
119
0.684357
2c33352508590e61164c232379f14d63d7be6d86
62
py
Python
test Text implementieren.py
abbashan03/Kinduino
292be35053763ee593b5721bf7ce450ec4dc1603
[ "MIT" ]
null
null
null
test Text implementieren.py
abbashan03/Kinduino
292be35053763ee593b5721bf7ce450ec4dc1603
[ "MIT" ]
null
null
null
test Text implementieren.py
abbashan03/Kinduino
292be35053763ee593b5721bf7ce450ec4dc1603
[ "MIT" ]
null
null
null
f = open("Testabc.txt", "r") daten = f.read() print(daten)
15.5
29
0.580645
2ccda491b969e54a5ab9eb3be3e79624f53f25af
404
py
Python
listings/chapter04/triangle.py
SaschaKersken/Daten-Prozessanalyse
370f07a75b9465329deb3671adbfbef8483f76f6
[ "Apache-2.0" ]
2
2021-09-20T06:16:41.000Z
2022-01-17T14:24:43.000Z
listings/chapter04/triangle.py
SaschaKersken/Daten-Prozessanalyse
370f07a75b9465329deb3671adbfbef8483f76f6
[ "Apache-2.0" ]
null
null
null
listings/chapter04/triangle.py
SaschaKersken/Daten-Prozessanalyse
370f07a75b9465329deb3671adbfbef8483f76f6
[ "Apache-2.0" ]
null
null
null
import matplotlib.pyplot as plt plt.xlabel('x') plt.ylabel('y') plt.scatter([-3, 3, 3], [-3, -3, 3]) plt.annotate('A', (-3, -3)) plt.annotate('B', (3, -3)) plt.annotate('C', (3, 3)) plt.plot([-3, 3], [-3, -3]) plt.plot([3, 3], [-3, 3]) plt.plot([3, -3], [3, -3]) plt.text(0, -3.2, 'c') plt.text(3.1, 0, 'a') plt.text(-0...
21.263158
36
0.556931
b3c43eacedb82f18f1352631cc2d6cb195700eea
287
py
Python
kong/test-server.py
IBBD/dockerfiles
d4c7f5b95ed80a400e494d458f1bd53cd4710c23
[ "MIT" ]
null
null
null
kong/test-server.py
IBBD/dockerfiles
d4c7f5b95ed80a400e494d458f1bd53cd4710c23
[ "MIT" ]
null
null
null
kong/test-server.py
IBBD/dockerfiles
d4c7f5b95ed80a400e494d458f1bd53cd4710c23
[ "MIT" ]
2
2018-09-19T08:28:50.000Z
2020-04-27T13:13:24.000Z
# -*- coding: utf-8 -*- # # 测试server # Author: alex # Created Time: 2018年12月29日 星期六 20时30分34秒 def hello(name='world'): return 'Hello {name} in func!'.format(name=name) if __name__ == '__main__': from fireRest import API, app API(hello) app.run(debug=True, port=5000)
17.9375
52
0.651568
b3fc655226107b2eef0972e63b4d1bf8b28420c6
4,626
py
Python
Packs/Viper/Integrations/Viper/Viper.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/Viper/Integrations/Viper/Viper.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/Viper/Integrations/Viper/Viper.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
import demistomock as demisto # noqa: F401 from CommonServerPython import * # noqa: F401 ''' IMPORTS ''' import requests # Disable insecure warnings requests.packages.urllib3.disable_warnings() class ViperClient(BaseClient): """ Client will implement the service API, and should not contain any Demisto log...
30.434211
116
0.597925
205c1c2880331000e57db020ce9cec7228d83c07
6,393
py
Python
agents/ac_dqn.py
yerfor/Soft-DRGN
0c96d1ea295077b949229261c37d8dde25001a03
[ "MIT" ]
2
2022-02-24T08:21:49.000Z
2022-03-10T08:57:35.000Z
agents/ac_dqn.py
yerfor/Soft-DRGN
0c96d1ea295077b949229261c37d8dde25001a03
[ "MIT" ]
1
2022-02-24T08:40:21.000Z
2022-02-24T12:01:58.000Z
agents/ac_dqn.py
yerfor/Soft-DRGN
0c96d1ea295077b949229261c37d8dde25001a03
[ "MIT" ]
null
null
null
import torch import torch.nn as nn import torch.nn.functional as F from modules.ac_dqn import ActorDQNNetwork, CriticDQNNetwork from agents.base_agent import BaseActorCriticAgent from utils.hparams import hparams from utils.numba_utils import * from utils.torch_utils import * class ActorCriticDQNAgent(BaseActorCriti...
43.787671
108
0.60488
2065124aae29cd6bad906b99db7fdcb54dbb8442
3,107
py
Python
5_DeepLearning-Visualization/3-Keract_CNN_HeatMap.py
felixdittrich92/DeepLearning-tensorflow-keras
2880d8ed28ba87f28851affa92b6fa99d2e47be9
[ "Apache-2.0" ]
null
null
null
5_DeepLearning-Visualization/3-Keract_CNN_HeatMap.py
felixdittrich92/DeepLearning-tensorflow-keras
2880d8ed28ba87f28851affa92b6fa99d2e47be9
[ "Apache-2.0" ]
null
null
null
5_DeepLearning-Visualization/3-Keract_CNN_HeatMap.py
felixdittrich92/DeepLearning-tensorflow-keras
2880d8ed28ba87f28851affa92b6fa99d2e47be9
[ "Apache-2.0" ]
null
null
null
''' komplette Visualisierung der Schritte des Netzes mit Keract -> ziemlich cool ''' import os import keract import numpy as np from sklearn.model_selection import train_test_split import tensorflow as tf import tensorflow.keras.backend as K from tensorflow.keras.utils import to_categorical from tensorflow.keras.la...
27.990991
86
0.674284
20d16156bfffe09f0c26fd3c8ff0353e54619a75
2,589
py
Python
Entnahmesimulation.py
ThoEngel/rentenplanung
879c9a678ba1ff951a1f92b0c42673a7943a18e6
[ "MIT" ]
3
2022-01-01T18:24:46.000Z
2022-01-08T15:28:46.000Z
Entnahmesimulation.py
ThoEngel/Finanzen-Simuliert
879c9a678ba1ff951a1f92b0c42673a7943a18e6
[ "MIT" ]
null
null
null
Entnahmesimulation.py
ThoEngel/Finanzen-Simuliert
879c9a678ba1ff951a1f92b0c42673a7943a18e6
[ "MIT" ]
null
null
null
''' Vorsicht vor der 4%-Regel https://www.finanzen-erklaert.de/vorsicht-vor-der-4-regel/ ''' import pandas as pd import time from SEsimulation.mDate import mDate from SEsimulation import SEsimulation import plotly.express as px import numpy as np print('Start') starttime = time.time() # Lesen monatliche S&P500 Dat...
34.065789
119
0.625338
ff7cbed85adf70a5a3eaa842a99f8ca081372761
40
py
Python
haferml/__init__.py
emptymalei/haferml
ba193ce1c022c89fb4e88924b7bb7a05b676929a
[ "MIT" ]
11
2021-04-17T18:51:45.000Z
2021-06-25T19:42:25.000Z
haferml/__init__.py
emptymalei/haferml
ba193ce1c022c89fb4e88924b7bb7a05b676929a
[ "MIT" ]
3
2021-04-29T19:24:15.000Z
2021-05-21T04:30:54.000Z
haferml/__init__.py
emptymalei/haferml
ba193ce1c022c89fb4e88924b7bb7a05b676929a
[ "MIT" ]
2
2021-06-10T00:55:43.000Z
2021-12-30T07:37:07.000Z
from haferml.version import __version__
20
39
0.875
440799a851de9679778ae473f11b0954fc63a35d
2,304
py
Python
plotter.py
lastleon/EvolutionSimulator
3dace3bd07044c0af27c4805ee79b9dd11c45826
[ "MIT" ]
2
2017-12-14T20:54:21.000Z
2018-03-05T18:31:43.000Z
plotter.py
lastleon/EvolutionSimulator
3dace3bd07044c0af27c4805ee79b9dd11c45826
[ "MIT" ]
1
2018-03-11T20:40:24.000Z
2018-05-06T16:26:30.000Z
plotter.py
lastleon/EvolutionSimulator
3dace3bd07044c0af27c4805ee79b9dd11c45826
[ "MIT" ]
1
2017-12-06T20:29:18.000Z
2017-12-06T20:29:18.000Z
import os import matplotlib.pyplot as plt from ast import literal_eval as make_tuple myIndex = int(input("Plotindex: ")) x = [] y = [] currDir = os.path.dirname(__file__) path = currDir + "/data/ältestesLw/ältestesLw%s.txt"% myIndex try: with open(path) as data: data = data.read().split(...
22.588235
86
0.516493
441e96f18b9bdd5933a138f55f2d8708ce2cc1f9
9,022
py
Python
research/cv/squeezenet1_1/modelArts/train_on_modelarts.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/cv/squeezenet1_1/modelArts/train_on_modelarts.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/cv/squeezenet1_1/modelArts/train_on_modelarts.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...
41.196347
112
0.647639
92298960309d93040545a8b12eb854f6416b4976
17,228
py
Python
indl/model/beta_vae.py
SachsLab/indl
531d2e0c2ee765004aedc553af40e258262f86cb
[ "Apache-2.0" ]
1
2021-02-22T01:39:50.000Z
2021-02-22T01:39:50.000Z
indl/model/beta_vae.py
SachsLab/indl
531d2e0c2ee765004aedc553af40e258262f86cb
[ "Apache-2.0" ]
null
null
null
indl/model/beta_vae.py
SachsLab/indl
531d2e0c2ee765004aedc553af40e258262f86cb
[ "Apache-2.0" ]
null
null
null
__all__ = ['generate_default_args', 'generate_default_params', 'prepare_inputs', 'create_f_encoder', 'make_f_variational', 'create_z_encoder', 'make_z_variational', 'get_z_prior'] import numpy as np import tensorflow as tf import tensorflow.keras.layers as tfkl from tensorflow.keras import backe...
45.819149
135
0.62085
a65069c1b3cfb81acde4553301457d0034898566
775
py
Python
04.DFS_BFS/SY/b1260_SY.py
SP2021-2/Algorithm
2e629eb5234212fad8bbc11491aad068e5783780
[ "MIT" ]
1
2021-11-21T06:03:06.000Z
2021-11-21T06:03:06.000Z
04.DFS_BFS/SY/b1260_SY.py
SP2021-2/Algorithm
2e629eb5234212fad8bbc11491aad068e5783780
[ "MIT" ]
2
2021-10-13T07:21:09.000Z
2021-11-14T13:53:08.000Z
04.DFS_BFS/SY/b1260_SY.py
SP2021-2/Algorithm
2e629eb5234212fad8bbc11491aad068e5783780
[ "MIT" ]
null
null
null
# b1260 import sys from collections import deque def DFS(v): visit_D[v] = 1 print(v, end = " ") for i in range(1, n + 1): if visit_D[i] == 0 and graph[v][i] == 1 : DFS(i) def BFS(v): q = deque() q.append(v) visit_B[v] = 1 while q: v = q.popleft() print(v...
19.871795
53
0.468387
5bd398812029a6c03bb794ddaf5be383498f5fa8
11,611
py
Python
packages/watchmen-utilities/src/watchmen_utilities/datetime_helper.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-utilities/src/watchmen_utilities/datetime_helper.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-utilities/src/watchmen_utilities/datetime_helper.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
from datetime import date, datetime, time, timedelta from decimal import Decimal from enum import Enum from json import JSONEncoder from re import sub from typing import Any, List, Optional, Tuple, Union from .array_helper import ArrayHelper class DateTimeEncoder(JSONEncoder): def default(self, o): if isinstance(...
28.319512
115
0.720351
1b4652dffd6c7f8f74860a065e98ab012675f6ba
5,200
py
Python
tests/onegov/fsi/test_models.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/fsi/test_models.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/fsi/test_models.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
import datetime from sedate import utcnow from onegov.fsi.models.course_attendee import CourseAttendee from onegov.fsi.models.course_event import CourseEvent from onegov.fsi.models.course_notification_template import get_template_default from onegov.fsi.models.course_subscription import CourseSubscription def test_a...
35.135135
79
0.735962
04793fb03b0e4a3d04cf47dc8afa445e2b0a4477
1,603
py
Python
pizza/tests/test_module_pizza.py
gray-adeyi/pizza
659db6e85492903374416295cc3ca3a78584eccb
[ "MIT" ]
null
null
null
pizza/tests/test_module_pizza.py
gray-adeyi/pizza
659db6e85492903374416295cc3ca3a78584eccb
[ "MIT" ]
null
null
null
pizza/tests/test_module_pizza.py
gray-adeyi/pizza
659db6e85492903374416295cc3ca3a78584eccb
[ "MIT" ]
1
2022-03-17T00:54:27.000Z
2022-03-17T00:54:27.000Z
import unittest from ..pizza import ( Gender, MailTemplate, User, AddressBook, Setting, MailTemplateBook, ) class PizzaTest(unittest.TestCase): def test_user_model(self): user = User('gbenga', 'adeyi', 'adeyigbenga005@gmail.com', Gender.male) self.assertEqual(user.gender, ...
34.847826
139
0.644417
047bc3f27311aade1b6443a981a8ece6acc26357
6,552
py
Python
SBTK_League_Helper/update_tournaments.py
juanchodepisa/sbtk
7cba7748e75a02b491e551d6c1be9bd7987c5051
[ "MIT" ]
null
null
null
SBTK_League_Helper/update_tournaments.py
juanchodepisa/sbtk
7cba7748e75a02b491e551d6c1be9bd7987c5051
[ "MIT" ]
null
null
null
SBTK_League_Helper/update_tournaments.py
juanchodepisa/sbtk
7cba7748e75a02b491e551d6c1be9bd7987c5051
[ "MIT" ]
null
null
null
from src.interfacing.ogs.connect import Authentication import codecs import sys import os from time import sleep def loadList(pNameFile): iList = [] with codecs.open(pNameFile, "r", "utf-8") as f: for line in f: iList.append(line) return iList if __name__ == "__main__": a = ...
36
171
0.608364
b6fda47987073139c9ff2a0bdbc46017f6efc8d8
721
py
Python
config.py
persquare/ZK2
5c00d0a5a59123931848259286bb13bb86c5396b
[ "MIT" ]
2
2020-03-05T16:01:17.000Z
2020-09-25T11:28:27.000Z
config.py
persquare/ZK2
5c00d0a5a59123931848259286bb13bb86c5396b
[ "MIT" ]
null
null
null
config.py
persquare/ZK2
5c00d0a5a59123931848259286bb13bb86c5396b
[ "MIT" ]
null
null
null
# # Location of ZK-notes # Defaults to "~/.zk" # Can be overridden on commandline when starting server) # # notesdir = "~/Library/Mobile Documents/com~apple~CloudDocs/zk" # notesdir = "~/mynotes" # # Editor # Defaults to "/usr/bin/nano" # # editor = "/usr/local/bin/mate" # editor = "/usr/local/bin/bbedit" # # M...
24.862069
78
0.682386
8e27be64dcad3409d7806f927914b835288f276f
475
py
Python
FlaskOccupations/util/minify.py
kkysen/Soft-Dev
b19881b1fcc9c7daefc817e6b975ff6bce545d81
[ "Apache-2.0" ]
null
null
null
FlaskOccupations/util/minify.py
kkysen/Soft-Dev
b19881b1fcc9c7daefc817e6b975ff6bce545d81
[ "Apache-2.0" ]
null
null
null
FlaskOccupations/util/minify.py
kkysen/Soft-Dev
b19881b1fcc9c7daefc817e6b975ff6bce545d81
[ "Apache-2.0" ]
null
null
null
import bs4 import htmlmin import flask def prettify(html): # type: (str) -> str soup = bs4.BeautifulSoup(html, 'html.parser') return soup.prettify() def minify(app): # type: (flask.Flask) -> None wrapped = prettify if app.debug else htmlmin.minify @app.after_request def minifying_filter...
22.619048
67
0.671579
edd63906a404ad8c346076aa9f39ad9f1e8891c7
168
py
Python
aoc2020/day_15/part_2.py
en0/aoc2020
a2f41b909dffe1f366682b3d03fd5fbdbc924ec0
[ "MIT" ]
null
null
null
aoc2020/day_15/part_2.py
en0/aoc2020
a2f41b909dffe1f366682b3d03fd5fbdbc924ec0
[ "MIT" ]
null
null
null
aoc2020/day_15/part_2.py
en0/aoc2020
a2f41b909dffe1f366682b3d03fd5fbdbc924ec0
[ "MIT" ]
null
null
null
from .part_1 import Solution as Part1 class Solution(Part1): expected = 436 def solve(self) -> any: # /shrug return self.spoken_at(30000000)
16.8
39
0.636905
949082f6dc27e1799babb6fb321a50e4212c03cf
6,739
py
Python
tests/onegov/core/test_cronjobs.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/core/test_cronjobs.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/core/test_cronjobs.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
import requests from datetime import datetime from freezegun import freeze_time from onegov.core import Framework from onegov.core.cronjobs import parse_cron, Job from onegov.core.utils import scan_morepath_modules from pytest_localserver.http import WSGIServer from sedate import replace_timezone from sqlalchemy.ext.d...
30.355856
78
0.593411
bfa8e961e83f3d24fc629fcaaf1cca1650b03496
368
py
Python
src/dfs/dfs.py
jwvg0425/DSAndAlgo3
173ccf717b84610def861854736c3b16a57ac727
[ "MIT" ]
null
null
null
src/dfs/dfs.py
jwvg0425/DSAndAlgo3
173ccf717b84610def861854736c3b16a57ac727
[ "MIT" ]
null
null
null
src/dfs/dfs.py
jwvg0425/DSAndAlgo3
173ccf717b84610def861854736c3b16a57ac727
[ "MIT" ]
null
null
null
class Node: def __init__(self, value, adj): self.value = value self.adj = adj self.visited = False def dfs(graph): for source in graph: source.visited = True dfs_node(source) def dfs_node(node): print(node.value) for e in node.adj: if not e.visited: ...
21.647059
35
0.559783
44cd4fa2ede3b7e3cd97ae2ef6df746e454a2041
4,386
py
Python
Scripts/syncWiki.py
HuttonICS/API
22d61759a77f2ab3c4e610bb251684c78f71d2e6
[ "MIT" ]
40
2016-09-13T12:54:11.000Z
2021-09-05T18:45:38.000Z
Scripts/syncWiki.py
HuttonICS/API
22d61759a77f2ab3c4e610bb251684c78f71d2e6
[ "MIT" ]
351
2016-08-10T17:58:38.000Z
2021-09-15T12:19:48.000Z
Scripts/syncWiki.py
HuttonICS/API
22d61759a77f2ab3c4e610bb251684c78f71d2e6
[ "MIT" ]
32
2016-09-09T16:04:01.000Z
2021-01-21T13:27:40.000Z
#! /usr/bin/env python import yaml import glob import sys import json import os import requests from time import sleep def login(session, username, password): # get login token r1 = session.get(api_url, params={ 'format': 'json', 'action': 'query', 'meta': 'tokens', 'type': 'login', }, verify=...
25.062857
91
0.637255
78610a3d99c5b8f59465d14df9217985b3fdbdb5
366
py
Python
restraunt/django_project/dashboard/views.py
rakesh-gopal/restraunt_dashboard
8eba72dabd9de27500b184b18e02b43dfdc7da89
[ "MIT" ]
null
null
null
restraunt/django_project/dashboard/views.py
rakesh-gopal/restraunt_dashboard
8eba72dabd9de27500b184b18e02b43dfdc7da89
[ "MIT" ]
null
null
null
restraunt/django_project/dashboard/views.py
rakesh-gopal/restraunt_dashboard
8eba72dabd9de27500b184b18e02b43dfdc7da89
[ "MIT" ]
null
null
null
from django.shortcuts import render # Create your views here. from django.http import HttpResponse from libs.decorators import json_view from dashboard import documents @json_view def index(request): docs_count = documents.Actions.objects().count() return { 'status': 'ok', 'results': 'hello ...
20.333333
52
0.693989
78815d9fe318aa9c6bc1d3741d354564147b0c2a
1,475
py
Python
Problems/LinkedList/Medium/LRUCache/lru_cache.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
Problems/LinkedList/Medium/LRUCache/lru_cache.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
Problems/LinkedList/Medium/LRUCache/lru_cache.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
from typing import Optional class Node: def __init__(self, key: int, val: int) -> None: self.key = key self.val = val self.prev = None self.next = None class LRUCache: def __init__(self, capacity: int) -> None: self.capacity = capacity self.dic = dict() ...
27.830189
63
0.568814
155e11485aac914ffeff5271972b2326b37e3bfb
489
py
Python
monitor/monitorfunctions.py
magns12/python-hwmonitor
12bceb82303ebcd22a2ef1be1c5afee0c29da269
[ "MIT" ]
null
null
null
monitor/monitorfunctions.py
magns12/python-hwmonitor
12bceb82303ebcd22a2ef1be1c5afee0c29da269
[ "MIT" ]
null
null
null
monitor/monitorfunctions.py
magns12/python-hwmonitor
12bceb82303ebcd22a2ef1be1c5afee0c29da269
[ "MIT" ]
2
2021-03-22T09:32:14.000Z
2021-03-22T09:43:14.000Z
# SQL-Code ausführen, Parameter: Datenbank (die Verbindung), und der SQL-Befehl def executeSQL(db, sql, dictionary=True): # Cursor setzen und Daten als Dictionary speichern, außer die Variabe wurde auf "FALSE" gesetzt if dictionary == True: cursor = db.cursor(dictionary=True) else: ...
34.928571
103
0.627812
eca0c26cac4c3e497cb207bc77bebfca04c5e6f2
660
py
Python
Intro-Python-II/src/test_adv.py
tobias-fyi/01_intro_python
c56645291b8bce94d8511c3277fefba1fe8add89
[ "MIT" ]
null
null
null
Intro-Python-II/src/test_adv.py
tobias-fyi/01_intro_python
c56645291b8bce94d8511c3277fefba1fe8add89
[ "MIT" ]
8
2020-03-24T17:47:23.000Z
2022-03-12T00:33:21.000Z
cs/lambda_cs/01_intro_python/Intro-Python-II/src/test_adv.py
tobias-fyi/vela
b0b3d3c6dc3fa397c8c7a492098a02cf75e0ff82
[ "MIT" ]
null
null
null
""" BeWilder - text adventure game :: Game tests All tests implemented in Pytest. """ # Third-party imports import pytest # Local imports from .room import Room from .player import Player narrow_name = "Narrow Passage" narrow_description = """The narrow passage bends here from west to north. The smell of gold per...
20
63
0.731818
1709fabc685eb78da9432070ff451e971eef5cc4
25,589
py
Python
isp/config.py
MePyDo/pygqa
61cde42ee815968fdd029cc5056ede3badea3d91
[ "MIT" ]
null
null
null
isp/config.py
MePyDo/pygqa
61cde42ee815968fdd029cc5056ede3badea3d91
[ "MIT" ]
null
null
null
isp/config.py
MePyDo/pygqa
61cde42ee815968fdd029cc5056ede3badea3d91
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- ''' config ====== logging ------- logging verwenden:: import logging logger = logging.getLogger( "MQTT" ) debug Meldungen ausgeben:: logger.setLevel( logging.DEBUG ) logging level: * CRITICAL - 50 * ERROR - 40 * WARNING - 30 * INFO - 20 * DEBUG - 10 * NOTSET - 0 CHANGELOG...
30.140165
209
0.559576
e531d824abbcc5d33c9e24616b212ac2e1f9e390
208
py
Python
tests/model/test_direction.py
jonashellmann/informaticup21-team-chillow
f2e519af0a5d9a9368d62556703cfb1066ebb58f
[ "MIT" ]
3
2021-01-17T23:32:07.000Z
2022-01-30T14:49:16.000Z
tests/model/test_direction.py
jonashellmann/informaticup21-team-chillow
f2e519af0a5d9a9368d62556703cfb1066ebb58f
[ "MIT" ]
2
2021-01-17T13:37:56.000Z
2021-04-14T12:28:49.000Z
tests/model/test_direction.py
jonashellmann/informaticup21-team-chillow
f2e519af0a5d9a9368d62556703cfb1066ebb58f
[ "MIT" ]
2
2021-04-02T14:53:38.000Z
2021-04-20T11:10:17.000Z
import unittest from chillow.model.direction import Direction class DirectionTest(unittest.TestCase): def test_should_have_four_different_directions(self): self.assertEqual(len(Direction), 4)
20.8
57
0.793269
00d95248d16f3bce6d6d04804049d3a4454d28bf
1,611
py
Python
2-resources/_External-learning-resources/02-pyth/python-patterns-master/patterns/behavioral/visitor.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
2-resources/_External-learning-resources/02-pyth/python-patterns-master/patterns/behavioral/visitor.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
2-resources/_External-learning-resources/02-pyth/python-patterns-master/patterns/behavioral/visitor.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
1
2021-11-05T07:48:26.000Z
2021-11-05T07:48:26.000Z
""" http://peter-hoffmann.com/2010/extrinsic-visitor-pattern-python-inheritance.html *TL;DR Separates an algorithm from an object structure on which it operates. An interesting recipe could be found in Brian Jones, David Beazley "Python Cookbook" (2013): - "8.21. Implementing the Visitor Pattern" - "8.22. Implementin...
21.48
101
0.631906
daba2095a29b38a51fc77657afae60823560bf9c
33,415
py
Python
Contrib-Microsoft/Olympus_rack_manager/python-ocs/rackmanager/legacy/response_handler.py
opencomputeproject/Rack-Manager
e1a61d3eeeba0ff655fe9c1301e8b510d9b2122a
[ "MIT" ]
5
2019-11-11T07:57:26.000Z
2022-03-28T08:26:53.000Z
Contrib-Microsoft/Olympus_rack_manager/python-ocs/rackmanager/legacy/response_handler.py
opencomputeproject/Rack-Manager
e1a61d3eeeba0ff655fe9c1301e8b510d9b2122a
[ "MIT" ]
3
2019-09-05T21:47:07.000Z
2019-09-17T18:10:45.000Z
Contrib-Microsoft/Olympus_rack_manager/python-ocs/rackmanager/legacy/response_handler.py
opencomputeproject/Rack-Manager
e1a61d3eeeba0ff655fe9c1301e8b510d9b2122a
[ "MIT" ]
11
2019-07-20T00:16:32.000Z
2022-01-11T14:17:48.000Z
# Copyright (C) Microsoft Corporation. All rights reserved. # This program is free software; you can redistribute it # and/or modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. from xml.e...
32.347531
100
0.572408
daf9c059842880d542a5a00badf6026bbe5bed0e
901
py
Python
src/onegov/activity/matching/__init__.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/activity/matching/__init__.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/activity/matching/__init__.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from onegov.activity.matching.core import deferred_acceptance from onegov.activity.matching.core import deferred_acceptance_from_database from onegov.activity.matching.interfaces import MatchableBooking from onegov.activity.matching.interfaces import MatchableOccasion from onegov.activity.matching.score import PreferAd...
37.541667
75
0.824639
c183780fb39ab5e0b76a41aa4fca9ee4e5451faf
782
py
Python
py/jpy/src/test/python/jpy_java_embeddable_test.py
devinrsmith/deephaven-core
3a6930046faf1cd556f62a914ce1cfd7860147b9
[ "MIT" ]
55
2021-05-11T16:01:59.000Z
2022-03-30T14:30:33.000Z
py/jpy/src/test/python/jpy_java_embeddable_test.py
devinrsmith/deephaven-core
3a6930046faf1cd556f62a914ce1cfd7860147b9
[ "MIT" ]
943
2021-05-10T14:00:02.000Z
2022-03-31T21:28:15.000Z
py/jpy/src/test/python/jpy_java_embeddable_test.py
devinrsmith/deephaven-core
3a6930046faf1cd556f62a914ce1cfd7860147b9
[ "MIT" ]
29
2021-05-10T11:33:16.000Z
2022-03-30T21:01:54.000Z
import unittest import jpyutil jpyutil.init_jvm(jvm_maxmem='512M', jvm_classpath=['target/test-classes', 'target/classes']) import jpy class TestJavaTests(unittest.TestCase): def testStartingAndStoppingIfAvailable(self): PyLibTest = jpy.get_type('org.jpy.EmbeddableTest') PyLibTest.testStartingAndStoppingIf...
27.928571
92
0.755754
8220c49e6caf26f7771a2a0550aadc76fed525a4
475
py
Python
exercises/zh/solution_02_06.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
2,085
2019-04-17T13:10:40.000Z
2022-03-30T21:51:46.000Z
exercises/zh/solution_02_06.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
79
2019-04-18T14:42:55.000Z
2022-03-07T08:15:43.000Z
exercises/zh/solution_02_06.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
361
2019-04-17T13:34:32.000Z
2022-03-28T04:42:45.000Z
from spacy.lang.zh import Chinese nlp = Chinese() # 导入Doc和Span类 from spacy.tokens import Doc, Span words = ["我", "喜欢", "周", "杰伦"] spaces = [False, False, False, False] # 用words和spaces创建一个doc doc = Doc(nlp.vocab, words=words, spaces=spaces) print(doc.text) # 为doc中的"周杰伦"创建一个span,并赋予其"PERSON"的标签 span = Span(doc, 2, 4...
19.791667
51
0.705263
68bb87ab04e5ad43b0606b6bdb17bca3c0bab848
8,222
py
Python
PySQL-master/sql.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-17T03:35:03.000Z
2021-12-08T06:00:31.000Z
PySQL-master/sql.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
null
null
null
PySQL-master/sql.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-05T18:07:48.000Z
2022-02-24T21:25:07.000Z
#!/dimana saja # coding=utf-8 """ - PySQL # Usage = python3 # Asthor = Karjoq-Kun With Dobleh-Kun # Source : https://github.com/rezadkim """ # WARNA # t = "\033[1;97m" m = "\033[1;91m" u = "\033[1;95m" h = "\033[1;92m" k = "\033[1;93m" b = "\033[1;96m" logo = t+""" ╔═╗"""+m+"""┬ ┬"""+t+"""╔═╗╔═╗ ╦ ╠═╝"""+m+"""└┬┘"""+t+...
29.898182
158
0.541109
68bec5f62665ea179108d683571a7b699a736f26
1,902
py
Python
code/selfish_proxy/strategy/strategies.py
simonmulser/master-thesis
5ca2ddda377a0eede5a3c50866e0f90292c5448f
[ "CC-BY-4.0" ]
null
null
null
code/selfish_proxy/strategy/strategies.py
simonmulser/master-thesis
5ca2ddda377a0eede5a3c50866e0f90292c5448f
[ "CC-BY-4.0" ]
null
null
null
code/selfish_proxy/strategy/strategies.py
simonmulser/master-thesis
5ca2ddda377a0eede5a3c50866e0f90292c5448f
[ "CC-BY-4.0" ]
1
2019-06-05T09:10:30.000Z
2019-06-05T09:10:30.000Z
selfish_mining_strategy = \ [ [ # irrelevant ['*', '*', '*', '*', '*', '*', '*', '*', '*', '*'], ['w', '*', 'a', '*', '*', '*', '*', '*', '*', '*'], ['w', 'w', '*', 'a', '*', '*', '*', '*', '*', '*'], ['w', 'w', 'w', '*', 'a', '*', '*', '*', '*', '*'], ['w', 'w', 'w', 'w', '...
47.55
59
0.099369
68f158bf3e6c2594b09794878631c6ca447de9ed
15,681
py
Python
cloudmesh/volume/oracle/Provider.py
cloudmesh/cloudmesh-volume
a7502d077f2fb7c6b1b7986da9595a36591b06cd
[ "Apache-2.0" ]
1
2020-03-12T09:49:53.000Z
2020-03-12T09:49:53.000Z
cloudmesh/volume/oracle/Provider.py
cloudmesh/cloudmesh-volume
a7502d077f2fb7c6b1b7986da9595a36591b06cd
[ "Apache-2.0" ]
1
2020-03-25T00:47:12.000Z
2020-03-30T23:32:00.000Z
cloudmesh/volume/oracle/Provider.py
cloudmesh/cloudmesh-volume
a7502d077f2fb7c6b1b7986da9595a36591b06cd
[ "Apache-2.0" ]
5
2020-02-20T01:04:24.000Z
2020-05-05T14:36:30.000Z
import oci from cloudmesh.common.console import Console from cloudmesh.common.dotdict import dotdict from cloudmesh.configuration.Config import Config from cloudmesh.volume.VolumeABC import VolumeABC from cloudmesh.mongo.CmDatabase import CmDatabase class Provider(VolumeABC): kind = "oracle" sample = """ ...
34.846667
79
0.536254
2e41059737f4d221e7f02145402803f82b9e1f7c
2,196
py
Python
tests/MyFuncLogin.py
mribrgr/StuRa-Mitgliederdatenbank
87a261d66c279ff86056e315b05e6966b79df9fa
[ "MIT" ]
8
2019-11-26T13:34:46.000Z
2021-06-21T13:41:57.000Z
src/tests/MyFuncLogin.py
Sumarbrander/Stura-Mitgliederdatenbank
691dbd33683b2c2d408efe7a3eb28e083ebcd62a
[ "MIT" ]
93
2019-12-16T09:29:10.000Z
2021-04-24T12:03:33.000Z
src/tests/MyFuncLogin.py
Sumarbrander/Stura-Mitgliederdatenbank
691dbd33683b2c2d408efe7a3eb28e083ebcd62a
[ "MIT" ]
2
2020-12-03T12:43:19.000Z
2020-12-22T21:48:47.000Z
from django.urls import reverse def loginAsLukasAdmin(self): """ Opens a Browser instance and login as admin with the account testlukasadmin. :param self: :type self: :return: No return Value """ # Öffnen eines Browsers try: self.browser.get(self.live_server_u...
28.894737
84
0.670765
cf122f5b78a949507c5b594af369c2e1f590face
2,027
py
Python
src/main/python/tools/json_builder.py
gwdgithubnom/ox-patient
cddf4fe381cb4506db8e0d62803dd2044cf7ad92
[ "MIT" ]
null
null
null
src/main/python/tools/json_builder.py
gwdgithubnom/ox-patient
cddf4fe381cb4506db8e0d62803dd2044cf7ad92
[ "MIT" ]
null
null
null
src/main/python/tools/json_builder.py
gwdgithubnom/ox-patient
cddf4fe381cb4506db8e0d62803dd2044cf7ad92
[ "MIT" ]
1
2021-04-14T00:45:38.000Z
2021-04-14T00:45:38.000Z
import numpy import json from cluster.json_viewer import ClusterViwer from context import resource_manager def cluster_view_json_builder(clusters=[]): """ 将用户传入的多个json格式的对象存储在json文件中 newlist【】作为list先读入文件中的数据以防止丢失,然后追加新加入的json对象(以list格式存入newlist) :param clusters...
37.537037
213
0.579674
51189f3815d7180ee5894183b2274ad8f0190351
543
py
Python
Curso_Python/Secao5-modulos-uteis/133_web-scraping/main.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
Curso_Python/Secao5-modulos-uteis/133_web-scraping/main.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
Curso_Python/Secao5-modulos-uteis/133_web-scraping/main.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
from bs4 import BeautifulSoup import requests # instala o html css # pip install requests // instalando web scraping # pip install beautifulsoup4 url = 'https://pt.stackoverflow.com/questions' response = requests.get(url) html = BeautifulSoup(response.text, 'html.parser') for question in html.select('.question-sum...
30.166667
55
0.734807
5ac094cbdfc2122c9de740888c1e1218a43a62ad
4,412
py
Python
Openharmony v1.0/third_party/ltp/testcases/realtime/tools/ftqviz.py
clkbit123/TheOpenHarmony
0e6bcd9dee9f1a2481d762966b8bbd24baad6159
[ "MIT" ]
1
2022-02-15T08:51:55.000Z
2022-02-15T08:51:55.000Z
hihope_neptune-oh_hid/00_src/v0.3/third_party/ltp/testcases/realtime/tools/ftqviz.py
dawmlight/vendor_oh_fun
bc9fb50920f06cd4c27399f60076f5793043c77d
[ "Apache-2.0" ]
null
null
null
hihope_neptune-oh_hid/00_src/v0.3/third_party/ltp/testcases/realtime/tools/ftqviz.py
dawmlight/vendor_oh_fun
bc9fb50920f06cd4c27399f60076f5793043c77d
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 # Filename: ftqviz.py # Author: Darren Hart <dvhltc@us.ibm.com> # Description: Plot the time and frequency domain plots of a times and # counts log file pair from the FTQ benchmark. # Prerequisites: numpy, scipy, and pylab packages. For debian/ubuntu: # ...
28.101911
102
0.607208
7a298f862f68bd7b75a12e7274f9edf27416d649
99
py
Python
examples/myqueryset/simplerelate/apps.py
zhengtong0898/django-decode
69680853a4a5b07f6a9c4b65c7d86b2d401a92b1
[ "MIT" ]
5
2020-07-14T07:48:10.000Z
2021-12-20T21:20:10.000Z
examples/myqueryset/simplerelate/apps.py
zhengtong0898/django-decode
69680853a4a5b07f6a9c4b65c7d86b2d401a92b1
[ "MIT" ]
7
2021-03-26T03:13:38.000Z
2022-03-12T00:42:03.000Z
examples/myqueryset/simplerelate/apps.py
zhengtong0898/django-decode
69680853a4a5b07f6a9c4b65c7d86b2d401a92b1
[ "MIT" ]
1
2021-02-16T07:04:25.000Z
2021-02-16T07:04:25.000Z
from django.apps import AppConfig class SimplerelateConfig(AppConfig): name = 'simplerelate'
16.5
36
0.777778
890040b5d1c2982f33dddb934f9f149e4f4ed646
21,451
py
Python
Packs/AzureStorageTable/Integrations/AzureStorageTable/AzureStorageTable.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
2
2021-12-06T21:38:24.000Z
2022-01-13T08:23:36.000Z
Packs/AzureStorageTable/Integrations/AzureStorageTable/AzureStorageTable.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
87
2022-02-23T12:10:53.000Z
2022-03-31T11:29:05.000Z
Packs/AzureStorageTable/Integrations/AzureStorageTable/AzureStorageTable.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
2
2022-01-05T15:27:01.000Z
2022-02-01T19:27:43.000Z
import demistomock as demisto # noqa: F401 from CommonServerPython import * # noqa: F401 import copy from requests import Response DATE_FORMAT = '%Y-%m-%dT%H:%M:%S.%fZ' account_sas_token = "" storage_account_name = "" class Client: """ API Client """ def __init__(self, server_url, verify, proxy, ...
33.622257
121
0.639131
56c697e3c813a98f5c52b4da82cf6709ec7ed9f8
702
py
Python
prak_2/draw.py
Paeti/krypto
f71b794a73170aeae4aa17712eea199a8e46afc0
[ "MIT" ]
null
null
null
prak_2/draw.py
Paeti/krypto
f71b794a73170aeae4aa17712eea199a8e46afc0
[ "MIT" ]
null
null
null
prak_2/draw.py
Paeti/krypto
f71b794a73170aeae4aa17712eea199a8e46afc0
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 __author__ = "Patrick Reckeweg" __copyright__ = "" import matplotlib as mlp import matplotlib.pyplot as plt from random import * import array as arr import miller_rabbin as ml def draw_experiment(): x = arr.array('i', [10, 100, 1000, 10000, 100000, 1000000, 10000000, 100000000, 1000...
20.057143
96
0.591168
a4671a928c0178fbe90016c417d1223e45dca1ef
346
py
Python
abfahrt/classes/__init__.py
Team-Zugig-zum-Erfolg/InformatiCup
788076ac38bf6d8f462465b7fb96db14d13bed30
[ "MIT" ]
1
2022-01-30T14:30:02.000Z
2022-01-30T14:30:02.000Z
abfahrt/classes/__init__.py
Team-Zugig-zum-Erfolg/InformatiCup
788076ac38bf6d8f462465b7fb96db14d13bed30
[ "MIT" ]
null
null
null
abfahrt/classes/__init__.py
Team-Zugig-zum-Erfolg/InformatiCup
788076ac38bf6d8f462465b7fb96db14d13bed30
[ "MIT" ]
null
null
null
""" This is the classes-Package that includes all entity classes """ from abfahrt.classes.Station import * from abfahrt.classes.Passenger import * from abfahrt.classes.Line import * from abfahrt.classes.Train import * from abfahrt.classes.TrainInLine import * from abfahrt.classes.TrainInStation import * from abfahr...
31.454545
64
0.794798
74e23aa0849fabd80d8166930d324fc90dbd8401
339
py
Python
Online-Judges/DimikOJ/Python/54-hash-key.py
shihab4t/Competitive-Programming
e8eec7d4f7d86bfa1c00b7fbbedfd6a1518f19be
[ "Unlicense" ]
3
2021-06-15T01:19:23.000Z
2022-03-16T18:23:53.000Z
Online-Judges/DimikOJ/Python/54-hash-key.py
shihab4t/Competitive-Programming
e8eec7d4f7d86bfa1c00b7fbbedfd6a1518f19be
[ "Unlicense" ]
null
null
null
Online-Judges/DimikOJ/Python/54-hash-key.py
shihab4t/Competitive-Programming
e8eec7d4f7d86bfa1c00b7fbbedfd6a1518f19be
[ "Unlicense" ]
null
null
null
def hash_key(string): multiplication = 1 for i in string: multiplication *= ord(i) return (multiplication % 97) for i in range(int(input())): str1, str2 = input().split() str1_key = hash_key(str1) str2_key = hash_key(str2) if str1_key == str2_key: print("YES") else: ...
18.833333
32
0.584071
74883fb137b6d9b8c4bddfc5b03ee2e5d4283ca7
245
py
Python
exercises/ja/exc_02_05_02.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
2
2020-07-07T01:46:37.000Z
2021-04-20T03:19:43.000Z
exercises/ja/exc_02_05_02.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
exercises/ja/exc_02_05_02.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
import spacy nlp = spacy.blank("ja") # Docクラスをインポート from ____ import ____ # 作りたいテキスト:「さあ、始めよう!」 words = ["さあ", "、", "初めよう", "!"] spaces = [____, ____, ____, ____] # wordsとspacesからDocを作成 doc = ____(____, ____=____, ____=____) print(doc.text)
16.333333
38
0.661224
bb28eda778d2dcf8196aafa9adc32135b8939c8f
942
py
Python
examples/miniportal/portal/MacrosLoader.py
Jumpscale/web
8e8ec2ce01f3105c7647ee8a0c90af09311cbbeb
[ "Apache-2.0" ]
1
2015-10-26T10:38:32.000Z
2015-10-26T10:38:32.000Z
examples/miniportal/portal/MacrosLoader.py
Jumpscale/web
8e8ec2ce01f3105c7647ee8a0c90af09311cbbeb
[ "Apache-2.0" ]
null
null
null
examples/miniportal/portal/MacrosLoader.py
Jumpscale/web
8e8ec2ce01f3105c7647ee8a0c90af09311cbbeb
[ "Apache-2.0" ]
null
null
null
import os import glob import imp from portal import Page class Macro(object): pass class MacrosLoader(object): def __init__(self, path): self.path = path self.macros = None def load_macros(self, blueprint, actors): self.actors = actors for macro in os.listdir(self.path): ...
29.4375
104
0.605096
79793c4cf5656f47193ba07ea804afb6dcf0520f
4,086
py
Python
tests/addons/log2reqs/test_csv.py
ihatov08/jumeaux
7d983474df4b6dcfa57ea1a66901fbc99ebababa
[ "MIT" ]
11
2017-10-02T01:29:12.000Z
2022-03-31T08:37:22.000Z
tests/addons/log2reqs/test_csv.py
ihatov08/jumeaux
7d983474df4b6dcfa57ea1a66901fbc99ebababa
[ "MIT" ]
79
2017-07-16T14:47:17.000Z
2022-03-31T08:49:14.000Z
tests/addons/log2reqs/test_csv.py
ihatov08/jumeaux
7d983474df4b6dcfa57ea1a66901fbc99ebababa
[ "MIT" ]
2
2019-01-28T06:11:58.000Z
2021-01-25T07:21:21.000Z
#!/usr/bin/env python # -*- coding:utf-8 -*- import pytest from owlmixin.util import load_yaml from jumeaux.addons.log2reqs.csv import Executor from jumeaux.models import Log2ReqsAddOnPayload, HttpMethod CSV = """ "name1","GET","/path1","q1=1&q2=2","header1=1&header2=2" "name2","POST","/path2","q1=1&q2=&q3","header1...
34.336134
100
0.424131
30bfd99b18a3b42bf378f11e32343322a618917a
664
py
Python
Python/M01_ProgrammingBasics/L05_WhileLoop/Exercises/Solutions/P04_Walking.py
todorkrastev/softuni-software-engineering
cfc0b5eaeb82951ff4d4668332ec3a31c59a5f84
[ "MIT" ]
null
null
null
Python/M01_ProgrammingBasics/L05_WhileLoop/Exercises/Solutions/P04_Walking.py
todorkrastev/softuni-software-engineering
cfc0b5eaeb82951ff4d4668332ec3a31c59a5f84
[ "MIT" ]
null
null
null
Python/M01_ProgrammingBasics/L05_WhileLoop/Exercises/Solutions/P04_Walking.py
todorkrastev/softuni-software-engineering
cfc0b5eaeb82951ff4d4668332ec3a31c59a5f84
[ "MIT" ]
1
2022-02-23T13:03:14.000Z
2022-02-23T13:03:14.000Z
target_steps = 10000 steps_done = 0 while True: line = input() if line == "Going home": home_steps = int(input()) steps_done = steps_done + home_steps if steps_done >= target_steps: print("Goal reached! Good job!") print(f"{steps_done - target_steps} steps over ...
25.538462
75
0.579819
d6a5d004fb389a41c39d360372bf5b4b81ef363b
753
py
Python
envs/base.py
etigerstudio/zilong-on-fire
5144a471b2d39ea38a47d394e648de00dd13cd8b
[ "MIT" ]
2
2021-01-07T01:10:49.000Z
2022-01-21T09:37:16.000Z
envs/base.py
etigerstudio/zilong-on-fire
5144a471b2d39ea38a47d394e648de00dd13cd8b
[ "MIT" ]
null
null
null
envs/base.py
etigerstudio/zilong-on-fire
5144a471b2d39ea38a47d394e648de00dd13cd8b
[ "MIT" ]
null
null
null
# Base environment implementation from enum import Enum class StateFormat(Enum): """环境观测/状态格式""" VECTOR = 0 # 一维向量 MATRIX = 1 # 二维矩阵 class BaseEnvironment: def step(self, action): """Perform one timestep. Args: action: action to be performed. Returns: ...
24.290323
67
0.588313
ba663b9659fd12553abbb8dd2cc8f6730dac18b8
1,399
py
Python
wagtail_localize/migrations/0010_overridablesegment.py
th3hamm0r/wagtail-localize
e9e0ba9245060c65e3247b62739abbed71bc2516
[ "BSD-3-Clause" ]
6
2019-09-10T19:53:55.000Z
2019-11-14T16:57:07.000Z
wagtail_localize/migrations/0010_overridablesegment.py
th3hamm0r/wagtail-localize
e9e0ba9245060c65e3247b62739abbed71bc2516
[ "BSD-3-Clause" ]
17
2019-07-11T11:17:37.000Z
2019-11-19T16:40:31.000Z
wagtail_localize/migrations/0010_overridablesegment.py
th3hamm0r/wagtail-localize
e9e0ba9245060c65e3247b62739abbed71bc2516
[ "BSD-3-Clause" ]
2
2019-09-30T20:23:39.000Z
2019-10-31T14:09:31.000Z
# Generated by Django 3.1 on 2020-08-28 10:00 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ("wagtail_localize", "0009_stringtranslation_errors"), ] operations = [ migrations.CreateModel( nam...
29.145833
68
0.419585
233fcc6f11287ea68423d2a8c5aa6ad65a9a8978
7,908
py
Python
src/onegov/activity/matching/score.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/activity/matching/score.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/activity/matching/score.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
import hashlib from onegov.activity.models import Activity, Attendee, Booking, Occasion from onegov.user import User from sqlalchemy import func class Scoring(object): """ Provides scoring based on a number of criteria. A criteria is a callable which takes a booking and returns a score. The final score ...
30.183206
79
0.609004
cc86da43000f9585fe4c9e409e4413dc2512339f
8,995
py
Python
Apps/Auswertung/tests/test_comparison.py
RGreinacher/bachelor-thesis
60dbc03ce40e3ec42f2538d67a6aabfea6fbbfc8
[ "MIT" ]
1
2021-04-13T10:00:46.000Z
2021-04-13T10:00:46.000Z
Apps/Auswertung/tests/test_comparison.py
RGreinacher/bachelor-thesis
60dbc03ce40e3ec42f2538d67a6aabfea6fbbfc8
[ "MIT" ]
null
null
null
Apps/Auswertung/tests/test_comparison.py
RGreinacher/bachelor-thesis
60dbc03ce40e3ec42f2538d67a6aabfea6fbbfc8
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # import python libs import sys sys.path.append('../') # import project libs from compare_annotations import compare_annotations_in_sentences test_cases =[ { 'reference': [{'annotation': {'label': 'PER', 'length': 2}, 'term': 'Wolfgang'}, {'term': 'Schwetz...
157.807018
754
0.498388
d1ff7f65e6d9186d05dcdff849a26b3ad31393e5
1,382
py
Python
code/snake/Algorithms/SitationsechnerDavid.py
BogyMitutoyoCTL/AI-Preparation
ef535741816b02e5e63d426a3232a688c9abd726
[ "MIT" ]
1
2020-03-30T09:25:53.000Z
2020-03-30T09:25:53.000Z
code/snake/Algorithms/SitationsechnerDavid.py
BogyMitutoyoCTL/AI-Preparation
ef535741816b02e5e63d426a3232a688c9abd726
[ "MIT" ]
2
2020-02-05T14:00:23.000Z
2020-03-30T19:57:19.000Z
code/snake/Algorithms/SitationsechnerDavid.py
BogyMitutoyoCTL/AI-Preparation
ef535741816b02e5e63d426a3232a688c9abd726
[ "MIT" ]
null
null
null
from Field import Field from GameData import GameData from Snake import Snake # 1 2 4 # # 8 - 16 # # 32 64 128 def situation_number(kantenlänge: int, maske: str, field: GameData): maske = maske.replace(" ", "") beginn = int(- (kantenlänge - 1) / 2) ende = int((kantenlänge - 1) / 2)...
27.64
68
0.575977
ae52a5c6c2e194377121a5e35198ab56ccf887f1
707
py
Python
Curso_Python/Secao3-Python-Intermediario-Programacao-Procedural/74_map-75_filter-76_reduce/75_filter.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
Curso_Python/Secao3-Python-Intermediario-Programacao-Procedural/74_map-75_filter-76_reduce/75_filter.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
Curso_Python/Secao3-Python-Intermediario-Programacao-Procedural/74_map-75_filter-76_reduce/75_filter.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
from dados import produtos, pessoas, lista # new_list = filter(lambda x: x > 5, lista) # feito com filter # new_list = [x for x in lista if x > 5] # feito com list comprehension # print(list(new_list)) # outro codigo # def new_filter(produto): # if produto['preco'] > 50: # produto['e_caro'] = True # ...
20.794118
71
0.649222
ae747704dbd6c1724819b013e6d1bdc702378234
95
py
Python
musicbeats/apps.py
VICTOR4046/MusiX
4a13d849e9db9a20b3ef8f286a8d047c0de86170
[ "MIT" ]
null
null
null
musicbeats/apps.py
VICTOR4046/MusiX
4a13d849e9db9a20b3ef8f286a8d047c0de86170
[ "MIT" ]
null
null
null
musicbeats/apps.py
VICTOR4046/MusiX
4a13d849e9db9a20b3ef8f286a8d047c0de86170
[ "MIT" ]
null
null
null
from django.apps import AppConfig class MusicbeatsConfig(AppConfig): name = 'musicbeats'
15.833333
34
0.768421
884ccd57b51e086d5e8dfa1675a25cda717c5b31
5,343
py
Python
app/models/forms.py
brunomileto/gamebet_website
b315569ff5c18538cbc374d19011591edb5f8b26
[ "MIT" ]
null
null
null
app/models/forms.py
brunomileto/gamebet_website
b315569ff5c18538cbc374d19011591edb5f8b26
[ "MIT" ]
null
null
null
app/models/forms.py
brunomileto/gamebet_website
b315569ff5c18538cbc374d19011591edb5f8b26
[ "MIT" ]
null
null
null
# -*- encoding: utf-8 -*- """ License: MIT Copyright (c) 2019 - present AppSeed.us """ from flask_login import LoginManager from flask_wtf import FlaskForm from wtforms import StringField, FileField, PasswordField, IntegerField, SelectField from wtforms.validators import Email, DataRequired, InputRequired from wtforms....
49.018349
151
0.706532
ee7a59d63c1301156ba63eb8ab5e480b3fbf2ae8
492
py
Python
playlist/playlist.py
samcost/POO
5c280407abb7aa9db1c82e52c34fd372465e8fe2
[ "MIT" ]
null
null
null
playlist/playlist.py
samcost/POO
5c280407abb7aa9db1c82e52c34fd372465e8fe2
[ "MIT" ]
null
null
null
playlist/playlist.py
samcost/POO
5c280407abb7aa9db1c82e52c34fd372465e8fe2
[ "MIT" ]
null
null
null
import random class Playlist: def __init__ (self, musicas): self.__list = musicas def imprime (self): print('____________________') for i in self.__list: print(i) print('____________________') def adiciona (self, newmusic): self.__list.append(newmusic) ...
23.428571
48
0.603659
c9acbc80efc0911e35853cee9202a5f449141a0f
718
py
Python
leetcode/121-Best-Time-to-Buy-and-Sell-Stock/BestTimetoBuyandSellStock_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-12-29T03:26:39.000Z
2016-12-29T03:26:39.000Z
leetcode/121-Best-Time-to-Buy-and-Sell-Stock/BestTimetoBuyandSellStock_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-02-09T06:00:07.000Z
2016-02-09T07:20:13.000Z
leetcode/121-Best-Time-to-Buy-and-Sell-Stock/BestTimetoBuyandSellStock_001.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
2
2019-06-27T09:07:26.000Z
2019-07-01T04:40:13.000Z
class Solution: # @param {integer[]} prices # @return {integer} def maxProfit(self, prices): if len(prices) < 2: return 0 minn = prices[:-1] maxn = prices[1:] mi = minn[0] for i in range(1, len(minn)): if minn[i] > mi: minn[i]...
23.933333
45
0.401114
a004ca33400e52f820d9e4c60d713b54a8f7f962
658
py
Python
7-assets/past-student-repos/Whiteboard-Pairing-master/LargestContiguousSum/model_solution.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
7-assets/past-student-repos/Whiteboard-Pairing-master/LargestContiguousSum/model_solution.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
7-assets/past-student-repos/Whiteboard-Pairing-master/LargestContiguousSum/model_solution.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
# We'll use a greedy algorithm to check to see if we have a # new max sum as we iterate along the along. If at any time # our sum becomes negative, we reset the sum. def largestContiguousSum(arr): maxSum = 0 currentSum = 0 for i, _ in enumerate(arr): currentSum += arr[i] max...
27.416667
75
0.604863
094582dc87e2e3cd9431c8c9b63c3633a0aea3b3
187
py
Python
DataCollections/Twitter/Config.py
moasgh/BumbleBee
2b0aae7970ab316c7b8b12dd4032b41ee1772aad
[ "MIT" ]
7
2020-03-06T05:53:43.000Z
2022-01-30T17:31:18.000Z
DataCollections/Twitter/Config.py
moasgh/BumbleBee
2b0aae7970ab316c7b8b12dd4032b41ee1772aad
[ "MIT" ]
null
null
null
DataCollections/Twitter/Config.py
moasgh/BumbleBee
2b0aae7970ab316c7b8b12dd4032b41ee1772aad
[ "MIT" ]
null
null
null
class Twitter(): Consumer_Key = '' Consumer_Secret = '' Access_Token = '' Access_Token_Secret = '' CONNECTION_STRING = "sqlite:///Twitter.db" LANG = ["en"]
23.375
47
0.57754
11ec5e2e101318dcaf3d5d623b008c975f33454c
8,380
py
Python
shippolink.py
fundthmcalculus/reserautomation
31fb18815885815dffbb775dd019e28f57ac9228
[ "MIT" ]
null
null
null
shippolink.py
fundthmcalculus/reserautomation
31fb18815885815dffbb775dd019e28f57ac9228
[ "MIT" ]
null
null
null
shippolink.py
fundthmcalculus/reserautomation
31fb18815885815dffbb775dd019e28f57ac9228
[ "MIT" ]
null
null
null
import logging import shippo from datetime import datetime from typing import List, Dict, Union, Set, Iterator, Tuple import requests from smartetailing import objects from httpconnection import HttpConnectionBase class ShippoConstants: US_DOLLAR = "USD" US = "US" UNITED_STATES = "United States" POUN...
37.244444
119
0.647375
eefabbd72b3541cd3d6daeab01811065a4c9bd82
64
py
Python
Paddle_Industry_Practice_Sample_Library/Football_Action/PaddleVideo/paddlevideo/metrics/ActivityNet/__init__.py
linuxonly801/awesome-DeepLearning
b063757fa130c4d56aea5cce2e592610f1e169f9
[ "Apache-2.0" ]
883
2020-11-12T11:46:46.000Z
2022-03-31T18:27:10.000Z
paddlevideo/metrics/ActivityNet/__init__.py
arkofgalaxy/PaddleVideo
64251233c83b7eb681061b454da198a9082309a6
[ "Apache-2.0" ]
233
2020-12-09T06:04:59.000Z
2022-03-28T08:16:51.000Z
paddlevideo/metrics/ActivityNet/__init__.py
arkofgalaxy/PaddleVideo
64251233c83b7eb681061b454da198a9082309a6
[ "Apache-2.0" ]
225
2020-11-13T06:21:55.000Z
2022-03-31T05:36:11.000Z
from .anet_prop import ANETproposal __all__ = ['ANETproposal']
16
35
0.78125
0166891b3193276fa9611a81173e7df62690b314
846
py
Python
book/_build/jupyter_execute/docs/1006_Vielseitige_Kunststoffe.py
tom-tubeless/Chemie
bcd10e84b341121c260526c306f86b1556a6c034
[ "MIT" ]
null
null
null
book/_build/jupyter_execute/docs/1006_Vielseitige_Kunststoffe.py
tom-tubeless/Chemie
bcd10e84b341121c260526c306f86b1556a6c034
[ "MIT" ]
null
null
null
book/_build/jupyter_execute/docs/1006_Vielseitige_Kunststoffe.py
tom-tubeless/Chemie
bcd10e84b341121c260526c306f86b1556a6c034
[ "MIT" ]
null
null
null
#!/usr/bin/env python # coding: utf-8 # # 1006_Vielseitige Kunststoffe # # **4h** # # ## Leitfragen # # - Warum werden bestimmte Kunststoffe im Alltag verwendet? # # ## Inhaltsfelder & Inhaltliche Schwerpunkte # # - **IF10: Organische Chemie** # - Makromoleküle: ausgewählte Kunststoffe # # ## Schwerpunkte der ...
31.333333
145
0.741135
28cc5b607436dfa9c83e8ee3d5d1e23f10aad297
3,334
py
Python
src/onegov/winterthur/collections/mission_report.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/winterthur/collections/mission_report.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/winterthur/collections/mission_report.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
import sedate from datetime import datetime, date from onegov.core.collection import GenericCollection, Pagination from onegov.org.models.file import ImageFileCollection from onegov.winterthur.models import MissionReport from onegov.winterthur.models import MissionReportFile from onegov.winterthur.models import Missio...
28.991304
78
0.653269
e9446dd64157de23d9e03272a7526e470c5228be
7,620
py
Python
Packs/Carbon_Black_Enterprise_Response/Scripts/CBLiveGetFile_V2/CBLiveGetFile_V2.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/Carbon_Black_Enterprise_Response/Scripts/CBLiveGetFile_V2/CBLiveGetFile_V2.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/Carbon_Black_Enterprise_Response/Scripts/CBLiveGetFile_V2/CBLiveGetFile_V2.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
import demistomock as demisto from CommonServerPython import * from CommonServerUserPython import * import json from contextlib import contextmanager from typing import Tuple, Union '''Globals''' ERROR_SENSOR = -1 ERROR_SESSION = -1 ''' STANDALONE FUNCTION ''' def search_sensor_id(endpoint: str) -> int: """ ...
32.288136
125
0.64895
3ae10265edf0fc5cefc9438100a7b04177bb505a
245
py
Python
src/hw_raid_3ware.py
magistersart/ZTC_fork
ce72734ea575d9846b5b81f3efbfd14fa1f7e532
[ "PostgreSQL" ]
null
null
null
src/hw_raid_3ware.py
magistersart/ZTC_fork
ce72734ea575d9846b5b81f3efbfd14fa1f7e532
[ "PostgreSQL" ]
null
null
null
src/hw_raid_3ware.py
magistersart/ZTC_fork
ce72734ea575d9846b5b81f3efbfd14fa1f7e532
[ "PostgreSQL" ]
null
null
null
#!/usr/bin/python """ 3ware raid monitoring item script Copyright (c) 2010-2011 Vladimir Rusinov <vladimir@greenmice.info> Copyright (c) 2010 Murano Software [http://muranosoft.com] """ import ztc.hw tw = ztc.hw.RAID_3Ware() tw.get('status')
18.846154
66
0.730612
6e7ba1174b5e55b041392d08b91c01037d8502e0
10,692
py
Python
Utils/py/ActionSelection/experimental/QLearning/gamefield.py
tarsoly/NaoTH
dcd2b67ef6bf9953c81d3e1b26e543b5922b7d52
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
Utils/py/ActionSelection/experimental/QLearning/gamefield.py
tarsoly/NaoTH
dcd2b67ef6bf9953c81d3e1b26e543b5922b7d52
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
Utils/py/ActionSelection/experimental/QLearning/gamefield.py
tarsoly/NaoTH
dcd2b67ef6bf9953c81d3e1b26e543b5922b7d52
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
from tools import field_info as field from Tkinter import * import threading import time master = Tk() # create functions to draw field + decisions made / q values ranging from green to red # draw field + update field square_size = 200 # relative to field field_x = field.x_field_length + 200 # add a few pixels, fo...
36.868966
202
0.62832
6e94312e6d8456f053a4ac2ed87ef108234d1a39
1,137
py
Python
Python/zzz_training_challenge/Python_Challenge/solutions/ch02_math/solutions/ex08_combinatorics_cubic.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
Python/zzz_training_challenge/Python_Challenge/solutions/ch02_math/solutions/ex08_combinatorics_cubic.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
Python/zzz_training_challenge/Python_Challenge/solutions/ch02_math/solutions/ex08_combinatorics_cubic.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
# Beispielprogramm für das Buch "Python Challenge" # # Copyright 2020 by Michael Inden import math def solve_cubic_simple(): for a in range(1, 100): for b in range(1, 100): for c in range(1, 100): for d in range(1, 100): if a * a + b * b == c * c + d * d: ...
25.840909
78
0.431838
28789533552f9226dee5e6ef9f83705b84e57305
5,573
py
Python
2017/11/elex17-results-va-20171107/custom_filters.py
nprapps/graphics-archive
97b0ef326b46a959df930f5522d325e537f7a655
[ "FSFAP" ]
14
2015-05-08T13:41:51.000Z
2021-02-24T12:34:55.000Z
2017/11/elex17-results-va-20171107/custom_filters.py
nprapps/graphics-archive
97b0ef326b46a959df930f5522d325e537f7a655
[ "FSFAP" ]
null
null
null
2017/11/elex17-results-va-20171107/custom_filters.py
nprapps/graphics-archive
97b0ef326b46a959df930f5522d325e537f7a655
[ "FSFAP" ]
7
2015-04-04T04:45:54.000Z
2021-02-18T11:12:48.000Z
""" Custom filters for shaping election results for use by front-end code. All of this comes from the google-spreadsheet-election-loader project: https://github.com/nprapps/google-spreadsheet-election-loader/blob/master/loader.py """ # In Python 3.0, 5 / 2 will return 2.5 and 5 // 2 will return 2. # We want this to w...
29.026042
91
0.649202
c2e49174047ddd3601739cc66a9b0b3cedcdaac4
371
py
Python
frappe-bench/apps/erpnext/erpnext/agriculture/doctype/crop/test_crop.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/agriculture/doctype/crop/test_crop.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/agriculture/doctype/crop/test_crop.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
1
2021-04-29T14:39:01.000Z
2021-04-29T14:39:01.000Z
# -*- coding: utf-8 -*- # Copyright (c) 2017, Frappe Technologies Pvt. Ltd. and Contributors # See license.txt from __future__ import unicode_literals import frappe import unittest test_dependencies = ["Fertilizer"] class TestCrop(unittest.TestCase): def test_crop_period(self): basil = frappe.get_doc('Crop', 'Bas...
26.5
68
0.754717
6602daa1722c3e7d7d8c85a350c6861f178286f6
3,065
py
Python
code/game_board.py
obernbef/vwa
7d8edaefe6a6e38235b696112fde11ce0eba2a86
[ "MIT" ]
null
null
null
code/game_board.py
obernbef/vwa
7d8edaefe6a6e38235b696112fde11ce0eba2a86
[ "MIT" ]
null
null
null
code/game_board.py
obernbef/vwa
7d8edaefe6a6e38235b696112fde11ce0eba2a86
[ "MIT" ]
1
2021-11-10T10:36:01.000Z
2021-11-10T10:36:01.000Z
""" This module handles the game board. TODO ---- * Add `win_test()` function to `Board` class """ # %% from __future__ import annotations __author__ = "Florian Obernberger" __all__ = ['Board', 'Position', 'Stone'] from typing import List, NamedTuple, Tuple from enum import IntEnum import numpy as np from numba im...
23.945313
85
0.54062
05ab2309b718229dae4c0d1f17407cce4f2eda5a
716
py
Python
01.DataStructure/Stack&Queue/NY/B1158_NY.py
SP2021-2/Algorithm
2e629eb5234212fad8bbc11491aad068e5783780
[ "MIT" ]
1
2021-11-21T06:03:06.000Z
2021-11-21T06:03:06.000Z
01.DataStructure/Stack&Queue/NY/B1158_NY.py
SP2021-2/Algorithm
2e629eb5234212fad8bbc11491aad068e5783780
[ "MIT" ]
2
2021-10-13T07:21:09.000Z
2021-11-14T13:53:08.000Z
01.DataStructure/Stack&Queue/NY/B1158_NY.py
SP2021-2/Algorithm
2e629eb5234212fad8bbc11491aad068e5783780
[ "MIT" ]
null
null
null
# 백준 - 1158 import sys num, k = map(int, sys.stdin.readline().split()) circleQ = [] arr = [] removeIndex = k - 1 #1~n까지 삽입하기 for n in range(num) : circleQ.append(n+1) while len(circleQ) > 0 : if len(circleQ) < k : removeIndex = k % len(circleQ) - 1 arr.append(circleQ.pop(removeIndex)) ...
20.457143
47
0.548883
3c53a51fb85e7ea9eee1667f168aaac337b056ac
5,345
py
Python
TimeSeries/not_finished/vae_time_series/time_series_gen.py
stanton119/data-analysis
b6fda815c6cc1798ba13a5d2680369b7e5dfcdf9
[ "Apache-2.0" ]
null
null
null
TimeSeries/not_finished/vae_time_series/time_series_gen.py
stanton119/data-analysis
b6fda815c6cc1798ba13a5d2680369b7e5dfcdf9
[ "Apache-2.0" ]
1
2021-02-11T23:44:52.000Z
2021-02-11T23:44:52.000Z
TimeSeries/not_finished/vae_time_series/time_series_gen.py
stanton119/data-analysis
b6fda815c6cc1798ba13a5d2680369b7e5dfcdf9
[ "Apache-2.0" ]
1
2021-12-16T01:02:23.000Z
2021-12-16T01:02:23.000Z
# %% """ Fit a VAE to time series data Generate novel time series from the latent space """ # %% import numpy as np import pandas as pd from time import process_time, time import matplotlib.pyplot as plt plt.style.use("seaborn-whitegrid") # %% Load stocks data df = pd.read_csv("aapl_us.csv") df.dtypes df["Date"] =...
23.038793
80
0.656314
594219c5331ba33121655c55bd601f632ff2b6ae
5,892
py
Python
oldp/apps/search/views.py
ImgBotApp/oldp
575dc6f711dde3470d910e21c9440ee9b79a69ed
[ "MIT" ]
3
2020-06-27T08:19:35.000Z
2020-12-27T17:46:02.000Z
oldp/apps/search/views.py
ImgBotApp/oldp
575dc6f711dde3470d910e21c9440ee9b79a69ed
[ "MIT" ]
null
null
null
oldp/apps/search/views.py
ImgBotApp/oldp
575dc6f711dde3470d910e21c9440ee9b79a69ed
[ "MIT" ]
null
null
null
import logging from math import ceil from urllib.parse import urlparse from django.conf import settings from django.contrib import messages from django.shortcuts import render from django.utils.translation import ugettext_lazy as _ from elasticsearch import Elasticsearch from elasticsearch.exceptions import Connection...
29.757576
125
0.59131