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
180fb1fae83770d57827e99da6c36acad0697397
4,303
py
Python
practices/practice_2/task2.1.py
br4ch1st0chr0n3/robotic_systems_labs
23b8b81dc845e00cf02460258b9cec817019957b
[ "MIT" ]
null
null
null
practices/practice_2/task2.1.py
br4ch1st0chr0n3/robotic_systems_labs
23b8b81dc845e00cf02460258b9cec817019957b
[ "MIT" ]
null
null
null
practices/practice_2/task2.1.py
br4ch1st0chr0n3/robotic_systems_labs
23b8b81dc845e00cf02460258b9cec817019957b
[ "MIT" ]
null
null
null
#%% from libs.can import CANSocket from libs.myactuator import MyActuator from time import perf_counter import numpy as np # import getpass # password = getpass.getpass() # the serial port of device # you may find one by examing /dev/ folder, # this is usually devices ttyACM # os.system(f"sudo slcand -o -c -s8 /dev/...
26.398773
175
0.59261
c57948d9b3551e7ff5a4cb22f057cd02dd233821
382
py
Python
Utils/Configuration.py
Tarek1337/Dashboard-api
4feb4c0c55b8a1cd60eab5acd0a4f52d93fb7961
[ "MIT" ]
null
null
null
Utils/Configuration.py
Tarek1337/Dashboard-api
4feb4c0c55b8a1cd60eab5acd0a4f52d93fb7961
[ "MIT" ]
null
null
null
Utils/Configuration.py
Tarek1337/Dashboard-api
4feb4c0c55b8a1cd60eab5acd0a4f52d93fb7961
[ "MIT" ]
null
null
null
import json with open("config.json") as config_file: config = json.load(config_file) CLIENT_ID = config["clientID"] CLIENT_SECRET = config["clientSecret"] REDIRECT_URI = config["redirect_uri"] CLIENT_URL = config["client_url"] SESSION_TIMEOUT_LEN = config["session_timeout_length"] * 60*60*24 SESSION_KEY = config[...
29.384615
65
0.764398
b14f4a9a2933d9c40edd50ddccf210f322723345
526
pyde
Python
sketches/particles1/particles1.pyde
kantel/processingpy
74aae222e46f68d1c8f06307aaede3cdae65c8ec
[ "MIT" ]
4
2018-06-03T02:11:46.000Z
2021-08-18T19:55:15.000Z
sketches/particles1/particles1.pyde
kantel/processingpy
74aae222e46f68d1c8f06307aaede3cdae65c8ec
[ "MIT" ]
null
null
null
sketches/particles1/particles1.pyde
kantel/processingpy
74aae222e46f68d1c8f06307aaede3cdae65c8ec
[ "MIT" ]
3
2019-12-23T19:12:51.000Z
2021-04-30T14:00:31.000Z
from particles import Particle from rectparticles import RectParticle loc = PVector(250, 70) particles = [] def setup(): size(500, 500) this.surface.setTitle("Partikelsysteme 1") def draw(): background(235) ch = random(10) if ch <= 5: particles.append(Particle(loc)) else: part...
22.869565
47
0.610266
02bd18bbddcc336ba91ff33541fbc5b46042a887
86
py
Python
python/python_backup/wisp_old/archives/json_parser1.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
16
2018-11-26T08:39:42.000Z
2019-05-08T10:09:52.000Z
python/python_backup/wisp_old/archives/json_parser1.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
8
2020-05-04T06:29:26.000Z
2022-02-12T05:33:16.000Z
python/python_backup/wisp_old/archives/json_parser1.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
5
2020-02-11T16:02:21.000Z
2021-02-05T07:48:30.000Z
import json with open('secrets.txt', 'r') as f: array = json.load(f) print(array)
17.2
35
0.651163
b84ae6de78d070d0028d8fc229b54d4fc8788e45
710
py
Python
HackerRank/HackerRank-Python/Basic Data Types/Lists.py
tareqmahmud/Competitive-Programming
ad5e53300d70280bccbd5046ca01278fb246f314
[ "MIT" ]
2
2020-11-19T19:03:28.000Z
2021-01-04T19:52:11.000Z
HackerRank-Python/Basic Data Types/Lists.py
tareqmahmud/HackerRank
e1b9facab6582f86ea6cc63afcc640e66ba3f67e
[ "MIT" ]
null
null
null
HackerRank-Python/Basic Data Types/Lists.py
tareqmahmud/HackerRank
e1b9facab6582f86ea6cc63afcc640e66ba3f67e
[ "MIT" ]
null
null
null
if __name__ == "__main__": N = int(input()) data = [] while N != 0: command = input() if "print" in command: print(data) elif "insert" in command: tmp, index, value = command.split(" ") data.insert(int(index), int(value)) elif "remove" in ...
28.4
50
0.478873
a2b2748ac7b2d2d35dc436006e0c37ee29604c5c
2,653
py
Python
python/processfile.py
wittrup/crap
a77474588fd54a5a998e24df7b1e6e2ab473ded1
[ "MIT" ]
1
2017-12-12T13:58:08.000Z
2017-12-12T13:58:08.000Z
python/processfile.py
wittrup/crap
a77474588fd54a5a998e24df7b1e6e2ab473ded1
[ "MIT" ]
null
null
null
python/processfile.py
wittrup/crap
a77474588fd54a5a998e24df7b1e6e2ab473ded1
[ "MIT" ]
1
2019-11-03T10:16:35.000Z
2019-11-03T10:16:35.000Z
__author__ = 'wittr' import math def DistMidLatLong(FoLat, FoLong, ToLat, ToLong): R = 6371000 # metres rFoLat = math.radians(FoLat) rToLat = math.radians(ToLat) dLat = math.radians(ToLat-FoLat) dLong = math.radians(ToLong-FoLong) a = math.sin(dLat/2) * math.sin(dLat/2) + math.cos(rFoLat) *...
27.635417
121
0.607614
0c225da42bb42943706830382c0f99e9e5a373f8
2,426
py
Python
indl/misc/sigfuncs.py
SachsLab/indl
531d2e0c2ee765004aedc553af40e258262f86cb
[ "Apache-2.0" ]
1
2021-02-22T01:39:50.000Z
2021-02-22T01:39:50.000Z
indl/misc/sigfuncs.py
SachsLab/indl
531d2e0c2ee765004aedc553af40e258262f86cb
[ "Apache-2.0" ]
null
null
null
indl/misc/sigfuncs.py
SachsLab/indl
531d2e0c2ee765004aedc553af40e258262f86cb
[ "Apache-2.0" ]
null
null
null
__all__ = ['sigmoid', 'minimum_jerk'] import numpy as np def sigmoid(x, A=0, K=1, C=1, Q=1, B=1, v=1, x_offset=0): """ Returns f(x) = A + (K - A) / ((C + Q * np.exp(-B*(x - x_offset)))**(1/v)) This is a generalized logistic function. The default arguments reduce this to a simple sigmoid: f(x...
27.885057
105
0.52432
a7cd46baaa62942cdd191c23796cac42e74cc5da
814
py
Python
src/bo4e/enum/tarifkalkulationsmethode.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
1
2022-03-02T12:49:44.000Z
2022-03-02T12:49:44.000Z
src/bo4e/enum/tarifkalkulationsmethode.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
21
2022-02-04T07:38:46.000Z
2022-03-28T14:01:53.000Z
src/bo4e/enum/tarifkalkulationsmethode.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
null
null
null
# pylint: disable=missing-module-docstring,line-too-long from bo4e.enum.strenum import StrEnum class Tarifkalkulationsmethode(StrEnum): """ Auflistung der verschiedenen Berechnungsmethoden für ein Preisblatt. """ KEINE = "KEINE" #: Es wird keine Berechnung durchgeführt, sondern lediglich die Menge m...
54.266667
153
0.759214
ac80cf860bd087eaf2b3f652f018acd89fdfe9fc
1,747
py
Python
getVRMMqtt.py
tgfuellner/venusGX
fda42e37d8f3521c543e96b9bead5cb978268026
[ "MIT" ]
null
null
null
getVRMMqtt.py
tgfuellner/venusGX
fda42e37d8f3521c543e96b9bead5cb978268026
[ "MIT" ]
null
null
null
getVRMMqtt.py
tgfuellner/venusGX
fda42e37d8f3521c543e96b9bead5cb978268026
[ "MIT" ]
null
null
null
from time import sleep import ssl import json import os from paho.mqtt.client import Client from vrmCredentials import username from vrmCredentials import password from vrmCredentials import portal_id mqtt_broker = "mqtt70.victronenergy.com" bat_topic = "N/%s/system/0/Dc/Battery/Voltage" % portal_id soc_topic = "N/%...
25.691176
58
0.694333
65f2eb7ed46fe914abf9b8c4549718834f1972be
2,189
py
Python
Packs/FeedCyrenThreatInDepth/Scripts/CyrenThreatInDepthRelatedWidgetQuick/CyrenThreatInDepthRelatedWidgetQuick_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/FeedCyrenThreatInDepth/Scripts/CyrenThreatInDepthRelatedWidgetQuick/CyrenThreatInDepthRelatedWidgetQuick_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/FeedCyrenThreatInDepth/Scripts/CyrenThreatInDepthRelatedWidgetQuick/CyrenThreatInDepthRelatedWidgetQuick_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
import pytest import demistomock as demisto from CommonServerPython import entryTypes NORMAL = [ { "Type": entryTypes["note"], "HumanReadable": "tha output!", } ] ERROR = [ { "Type": entryTypes["error"], "Contents": "", } ] def executeCommand(result=NORMAL, error=Fal...
29.186667
90
0.682503
5a43d712808ab1388e5d0dbe334472a878bf5777
1,011
py
Python
6.Tree/Binary Search Tree/Python/binary_tree_using_array.py
Vinaypatil-Ev/vinEvC_datastructure
3e02e49c03a2b7d2e09af9a2dce080e6d9abbf74
[ "MIT" ]
3
2020-09-10T18:40:40.000Z
2020-09-15T17:32:12.000Z
6.Tree/Binary Search Tree/Python/binary_tree_using_array.py
Vinaypatil-Ev/vinEvC_datastructure
3e02e49c03a2b7d2e09af9a2dce080e6d9abbf74
[ "MIT" ]
null
null
null
6.Tree/Binary Search Tree/Python/binary_tree_using_array.py
Vinaypatil-Ev/vinEvC_datastructure
3e02e49c03a2b7d2e09af9a2dce080e6d9abbf74
[ "MIT" ]
null
null
null
class BinaryTree: def __init__(self, size): self.bt = [None] * size self.i = 0 def parent(self, i): return i def left(self, i): return i * 2 + 1 def right(self, i): return i * 2 + 2 def isFull(self): return self.i == len(self.bt) - 1 def insert(sel...
24.658537
61
0.464886
cec1fe3fdda0e823ce0fc9e10cc602c440d289d2
612
py
Python
utils/main.py
pushyzheng/docker-oj-web
119abae3763cd2e53c686a320af7f4f5af1f16ca
[ "MIT" ]
2
2019-06-24T08:34:39.000Z
2019-06-27T12:23:47.000Z
utils/main.py
pushyzheng/docker-oj-web
119abae3763cd2e53c686a320af7f4f5af1f16ca
[ "MIT" ]
null
null
null
utils/main.py
pushyzheng/docker-oj-web
119abae3763cd2e53c686a320af7f4f5af1f16ca
[ "MIT" ]
null
null
null
# encoding:utf-8 import uuid import json from datetime import datetime from flask import jsonify def get_uuid(): return str(uuid.uuid4()).replace('-', '') def sort_and_distinct(data_list): data_list = list(set(data_list)) list.sort(data_list) return data_list def get_day_zero_time(date): result...
21.103448
77
0.624183
cec6753e61952f521681dea73426407d24a7a83c
2,203
py
Python
scripts/fuzzing/lib/args.py
opensource-assist/fuschia
66646c55b3d0b36aae90a4b6706b87f1a6261935
[ "BSD-3-Clause" ]
3
2020-08-02T04:46:18.000Z
2020-08-07T10:10:53.000Z
scripts/fuzzing/lib/args.py
opensource-assist/fuschia
66646c55b3d0b36aae90a4b6706b87f1a6261935
[ "BSD-3-Clause" ]
null
null
null
scripts/fuzzing/lib/args.py
opensource-assist/fuschia
66646c55b3d0b36aae90a4b6706b87f1a6261935
[ "BSD-3-Clause" ]
1
2020-08-07T10:11:49.000Z
2020-08-07T10:11:49.000Z
#!/usr/bin/env python2.7 # Copyright 2019 The Fuchsia Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. import argparse from host import Host class Args: @classmethod def make_parser(cls, description, name_required=True, labe...
38.649123
81
0.576033
0b785eb01608785e7ea1810653321fbb9198764c
1,795
py
Python
cczoo/grpc-ra-tls/docker/grpc/v1.38.1/examples/python/ratls/client.py
BuJianlin/confidential-computing-zoo
1f08308507a9155ad9d1c05000791e19bae96e00
[ "Apache-2.0" ]
62
2021-11-25T05:47:28.000Z
2022-03-31T05:42:37.000Z
cczoo/grpc-ra-tls/docker/grpc/v1.38.1/examples/python/ratls/client.py
BuJianlin/confidential-computing-zoo
1f08308507a9155ad9d1c05000791e19bae96e00
[ "Apache-2.0" ]
9
2021-12-22T05:08:56.000Z
2022-03-31T09:34:08.000Z
cczoo/grpc-ra-tls/docker/grpc/v1.38.1/examples/python/ratls/client.py
BuJianlin/confidential-computing-zoo
1f08308507a9155ad9d1c05000791e19bae96e00
[ "Apache-2.0" ]
12
2021-11-26T02:18:08.000Z
2022-03-25T02:15:20.000Z
# # Copyright (c) 2022 Intel Corporation # # 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 ...
28.492063
76
0.702507
0ba9f1d20af8eca5e362b70adfa1d8658f83f481
1,082
py
Python
rewise-main/setup.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
73
2021-02-09T08:34:23.000Z
2022-02-18T04:41:07.000Z
rewise-main/setup.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
null
null
null
rewise-main/setup.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
4
2021-02-12T04:24:07.000Z
2022-03-22T19:23:42.000Z
import io from setuptools import setup, find_packages from os import path this_directory = path.abspath(path.dirname(__file__)) with io.open(path.join(this_directory, 'README.md'), encoding='utf-8') as f: desc = f.read() setup( name='rewise', version=__import__('rewise').__version__, description='Googl...
34.903226
81
0.672828
33269616510d74d71f04a8a9368f10ea85985d72
1,031
py
Python
api/tests/book_model.py
aidun/seite50
761a8e76f9e4473f70a8705dce169d61bf660267
[ "Apache-2.0" ]
null
null
null
api/tests/book_model.py
aidun/seite50
761a8e76f9e4473f70a8705dce169d61bf660267
[ "Apache-2.0" ]
2
2018-05-11T18:26:18.000Z
2018-05-12T18:49:38.000Z
api/tests/book_model.py
aidun/seite50
761a8e76f9e4473f70a8705dce169d61bf660267
[ "Apache-2.0" ]
1
2018-10-10T19:52:17.000Z
2018-10-10T19:52:17.000Z
from django.test import TestCase from api.models.book import Book # Create your tests here. class ModelTestCase(TestCase): fixtures = ['books.json'] @classmethod def setUpTestData(cls): cls.bookid = "1234" cls.title = "TestBuch" cls.description = "Ein Buch über das Testen" ...
31.242424
97
0.657614
33507353251d6b0f478c4a5640483d7004d0683a
5,664
py
Python
python/coursera_python/TORONTO/test/o_1.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
16
2018-11-26T08:39:42.000Z
2019-05-08T10:09:52.000Z
python/coursera_python/TORONTO/test/o_1.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
8
2020-05-04T06:29:26.000Z
2022-02-12T05:33:16.000Z
python/coursera_python/TORONTO/test/o_1.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
5
2020-02-11T16:02:21.000Z
2021-02-05T07:48:30.000Z
def shift_right(L): ''' (list) -> NoneType Shift each item in L one position to the rightand shift the last item to the first position. Precondition: len(L) >= 1 ''' last_item = L[-1] # MISSING CODE GOES HERE for i in range(1, len(L)): L[len(L) - i] = L[len(L) - i - 1] L[0] = la...
23.118367
162
0.543609
f0b28e64acd9caebb40b67b0d7328c7bd06e0440
3,015
py
Python
showcase1/com/aaron/exceptionexample.py
qsunny/python
ace8c3178a9a9619de2b60ca242c2079dd2f825e
[ "MIT" ]
null
null
null
showcase1/com/aaron/exceptionexample.py
qsunny/python
ace8c3178a9a9619de2b60ca242c2079dd2f825e
[ "MIT" ]
2
2021-03-25T22:00:07.000Z
2022-01-20T15:51:48.000Z
showcase1/com/aaron/exceptionexample.py
qsunny/python
ace8c3178a9a9619de2b60ca242c2079dd2f825e
[ "MIT" ]
null
null
null
# -*- codiing:utf-8 -*- """os example""" __author__="aaron.qiu" import sys import logging def valueException(): while True: try: x = int(input("Please enter a number: ")) break except ValueError: print("Oops! That was no valid number. Try again...") def moreE...
24.713115
76
0.59801
505793df90d06084268255f332f0e2fb0cb78a8f
413
py
Python
leetcode/389-Find-the-Difference/FindtheDifference_Bit_and_Hash.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2015-12-16T04:01:03.000Z
2015-12-16T04:01:03.000Z
leetcode/389-Find-the-Difference/FindtheDifference_Bit_and_Hash.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
1
2016-02-09T06:00:07.000Z
2016-02-09T07:20:13.000Z
leetcode/389-Find-the-Difference/FindtheDifference_Bit_and_Hash.py
cc13ny/all-in
bc0b01e44e121ea68724da16f25f7e24386c53de
[ "MIT" ]
2
2019-06-27T09:07:26.000Z
2019-07-01T04:40:13.000Z
class Solution(object): def findTheDifference(self, s, t): """ :type s: str :type t: str :rtype: str """ chrs = {} res = 0 for w in t: if w not in chrs: chrs[w] = 1 << (ord(w) - 97) res += chrs[w] # it can be ov...
24.294118
48
0.401937
ac9d126b36f90d73463100c079f4fef3156b4638
3,974
py
Python
research/gnn/dgcn/eval.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/gnn/dgcn/eval.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/gnn/dgcn/eval.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
24
2021-10-15T08:32:45.000Z
2022-03-24T18:45:20.000Z
# Copyright 2021 Huawei Technologies Co., Ltd # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to...
44.155556
119
0.700554
ace9647b8c9313946e9d91fc2f215256be709433
1,826
py
Python
marsyas-vamp/marsyas/src/marsyas_python/pitchBall.py
jaouahbi/VampPlugins
27c2248d1c717417fe4d448cdfb4cb882a8a336a
[ "Apache-2.0" ]
null
null
null
marsyas-vamp/marsyas/src/marsyas_python/pitchBall.py
jaouahbi/VampPlugins
27c2248d1c717417fe4d448cdfb4cb882a8a336a
[ "Apache-2.0" ]
null
null
null
marsyas-vamp/marsyas/src/marsyas_python/pitchBall.py
jaouahbi/VampPlugins
27c2248d1c717417fe4d448cdfb4cb882a8a336a
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # This is an ambient sound analyzer that will: # - Get sound from the microphone # - Show a graphical representation of the parameters of that sound from pylab import * from marsyas import * from marsyas_util import * from visual import * # For step one, we will create the following marsyas net...
34.45283
115
0.72782
4a23a255129dbb0b6bf903c9d385faa57c544ce0
1,635
py
Python
demos/Multiscale/adoption_funnel/model/run.py
w-ghub/demos
6382676fae89bd5a190626612712fcedf17bca6d
[ "MIT" ]
56
2020-07-08T23:23:15.000Z
2022-03-11T20:43:09.000Z
demos/Multiscale/adoption_funnel/model/run.py
w-ghub/demos
6382676fae89bd5a190626612712fcedf17bca6d
[ "MIT" ]
41
2020-07-11T23:24:06.000Z
2022-01-28T13:28:07.000Z
demos/Multiscale/adoption_funnel/model/run.py
w-ghub/demos
6382676fae89bd5a190626612712fcedf17bca6d
[ "MIT" ]
39
2020-07-15T11:35:04.000Z
2022-02-01T16:02:51.000Z
import pandas as pd from .parts.utils import * from model import config from cadCAD.engine import ExecutionMode, ExecutionContext,Executor from cadCAD import configs def get_M(k, v): if k == 'sim_config': k, v = 'M', v['M'] return k, v config_ids = [ dict( get_M(k, v) for k, v in config...
26.803279
118
0.655046
a8abef56fe1e437d69be67e520c1310fbbfe5131
505
py
Python
CodeChef_problems/LAPD/solution.py
gbrls/CompetitiveCode
b6f1b817a655635c3c843d40bd05793406fea9c6
[ "MIT" ]
165
2020-10-03T08:01:11.000Z
2022-03-31T02:42:08.000Z
CodeChef_problems/LAPD/solution.py
gbrls/CompetitiveCode
b6f1b817a655635c3c843d40bd05793406fea9c6
[ "MIT" ]
383
2020-10-03T07:39:11.000Z
2021-11-20T07:06:35.000Z
CodeChef_problems/LAPD/solution.py
gbrls/CompetitiveCode
b6f1b817a655635c3c843d40bd05793406fea9c6
[ "MIT" ]
380
2020-10-03T08:05:04.000Z
2022-03-19T06:56:59.000Z
#Question Link #https://www.codechef.com/problems/LAPD mod=10**9+7 for tc in range(int(input())): A,B,C=map(int,input().split()) #input the values ct=0 for i in range(1,B+1): temp=0 for j in range(1,A+1): for k in range(1,C+1): if(i*i<((j-1)*(k-1))): #checki...
31.5625
80
0.540594
a8be18e1db44501e86c581b4cdf2db69bc4eafa7
510
py
Python
elements/python/13/1/soln.py
mmcloughlin/problems
6095842ffe007a12ec8c2093850515aa4e046616
[ "MIT" ]
11
2019-02-08T06:54:34.000Z
2021-08-07T18:57:39.000Z
elements/python/13/1/soln.py
mmcloughlin/problems
6095842ffe007a12ec8c2093850515aa4e046616
[ "MIT" ]
1
2019-05-21T08:14:10.000Z
2019-05-21T08:14:10.000Z
elements/python/13/1/soln.py
mmcloughlin/problems
6095842ffe007a12ec8c2093850515aa4e046616
[ "MIT" ]
null
null
null
def group_by_hash(words, h): groups = dict() for word in words: groups.setdefault(h(word), []).append(word) return groups.values() def anagram_hash(word): return ''.join(sorted(word)) def anagram_groups(words): return group_by_hash(words, anagram_hash) def main(wordlist='/usr/share/dic...
20.4
51
0.637255
766cc88573df247f7955564720124a4ba47b5c58
4,448
py
Python
Wormy-master/wormy.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-17T03:35:03.000Z
2021-12-08T06:00:31.000Z
Wormy-master/wormy.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
null
null
null
Wormy-master/wormy.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-05T18:07:48.000Z
2022-02-24T21:25:07.000Z
# # Note:Most of the functions would be for windows or all of it # # Don't forget to convert it to executable & I recommend to you pyinstaller # import os,string,random,sys,glob,hashlib,zipfile from winreg import * #Get the drivers on the pc def drivers(): drivs = [] for i in string.ascii_uppercase...
33.443609
236
0.587455
8ca3cbc37b440e90220bc98e94b925dfbde09bce
6,461
py
Python
Co-Simulation/Sumo/sumo-1.7.0/tools/sumolib/options.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/sumolib/options.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/sumolib/options.py
uruzahe/carla
940c2ab23cce1eda1ef66de35f66b42d40865fb1
[ "MIT" ]
1
2020-11-20T19:31:26.000Z
2020-11-20T19:31:26.000Z
# Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo # Copyright (C) 2012-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.eclipse.org/legal/epl-2....
38.458333
115
0.551617
8cb1d97ed8b2a7f79bfb0ea1e09a70af91c98db7
996
py
Python
scripts/component_graph/server/graph/component_link.py
opensource-assist/fuschia
66646c55b3d0b36aae90a4b6706b87f1a6261935
[ "BSD-3-Clause" ]
3
2020-08-02T04:46:18.000Z
2020-08-07T10:10:53.000Z
scripts/component_graph/server/graph/component_link.py
opensource-assist/fuschia
66646c55b3d0b36aae90a4b6706b87f1a6261935
[ "BSD-3-Clause" ]
null
null
null
scripts/component_graph/server/graph/component_link.py
opensource-assist/fuschia
66646c55b3d0b36aae90a4b6706b87f1a6261935
[ "BSD-3-Clause" ]
1
2020-08-07T10:11:49.000Z
2020-08-07T10:11:49.000Z
#!/usr/bin/env python3 # Copyright 2019 The Fuchsia Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Link implementation for the ComponentGraph. ComponentLink stores rich data that is exported to the component graph about the type of...
32.129032
76
0.658635
0fe2916d6d1e1f821ee2cffd369533a35f2ffdfe
43,145
py
Python
Packs/BluelivThreatContext/Integrations/BluelivThreatContext/BluelivThreatContext.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/BluelivThreatContext/Integrations/BluelivThreatContext/BluelivThreatContext.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/BluelivThreatContext/Integrations/BluelivThreatContext/BluelivThreatContext.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
''' IMPORTS ''' import demistomock as demisto from CommonServerPython import * from CommonServerUserPython import * import json import urllib3 ''' PARAM DEFINITION ''' SEARCHABLE_BY_NAME = 'threat-actor,campaign,attack-pattern,tool,signature' SEARCHABLE_BY_HASH = 'sha256,sha1,md5' urllib3.disable_warnings() class C...
38.487957
113
0.548314
ba055e4e3b6007070047c7cb30736a63a014f54d
4,432
py
Python
emsite/emapp/views.py
thejeshpr/ExpenseManager
a3c452a87c9287a814247434ebb4039e164d7936
[ "MIT" ]
null
null
null
emsite/emapp/views.py
thejeshpr/ExpenseManager
a3c452a87c9287a814247434ebb4039e164d7936
[ "MIT" ]
null
null
null
emsite/emapp/views.py
thejeshpr/ExpenseManager
a3c452a87c9287a814247434ebb4039e164d7936
[ "MIT" ]
null
null
null
from django.shortcuts import render, HttpResponse from django.views.generic import ListView, UpdateView from django.views.generic.edit import CreateView from django.db.models import Sum from . models import Source, Transaction, Category class Home(ListView): model = Transaction context_object_name = 'transac...
34.897638
129
0.661101
e84f9e273554d03b030b4318624c7fcfcb1f049b
1,489
py
Python
balsn-2021-writeup/alldata/crypto/dlog/dist/deploy/src/server.py
Jimmy01240397/balsn-2021-writeup
91b71dfbddc1c214552280b12979a82ee1c3cb7e
[ "MIT" ]
null
null
null
balsn-2021-writeup/alldata/crypto/dlog/dist/deploy/src/server.py
Jimmy01240397/balsn-2021-writeup
91b71dfbddc1c214552280b12979a82ee1c3cb7e
[ "MIT" ]
null
null
null
balsn-2021-writeup/alldata/crypto/dlog/dist/deploy/src/server.py
Jimmy01240397/balsn-2021-writeup
91b71dfbddc1c214552280b12979a82ee1c3cb7e
[ "MIT" ]
null
null
null
#!/usr/local/bin/python3 -u from gevent import monkey monkey.patch_all() import json import os from gevent.pywsgi import WSGIServer from flask import Flask, Response, request from prometheus_client import Summary, make_wsgi_app from werkzeug.middleware.dispatcher import DispatcherMiddleware app = Flask(__name__) OR...
28.634615
90
0.667562
e857be4f72da8f161f6cb27ae4284de1d49bba60
5,964
py
Python
model_zoo/uie/doccano.py
AI-Mart/PaddleNLP
0ababea960427e8b70220ea06d908ed58cbed0ed
[ "Apache-2.0" ]
null
null
null
model_zoo/uie/doccano.py
AI-Mart/PaddleNLP
0ababea960427e8b70220ea06d908ed58cbed0ed
[ "Apache-2.0" ]
null
null
null
model_zoo/uie/doccano.py
AI-Mart/PaddleNLP
0ababea960427e8b70220ea06d908ed58cbed0ed
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2022 PaddlePaddle Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appli...
46.232558
227
0.653588
fa00648b7d1ac91038e2c6ff0eaaaa23889e618a
2,945
py
Python
exercises/networking_selfpaced/networking-workshop/collections/ansible_collections/community/general/tests/unit/modules/network/netvisor/test_pn_port_config.py
tr3ck3r/linklight
5060f624c235ecf46cb62cefcc6bddc6bf8ca3e7
[ "MIT" ]
null
null
null
exercises/networking_selfpaced/networking-workshop/collections/ansible_collections/community/general/tests/unit/modules/network/netvisor/test_pn_port_config.py
tr3ck3r/linklight
5060f624c235ecf46cb62cefcc6bddc6bf8ca3e7
[ "MIT" ]
null
null
null
exercises/networking_selfpaced/networking-workshop/collections/ansible_collections/community/general/tests/unit/modules/network/netvisor/test_pn_port_config.py
tr3ck3r/linklight
5060f624c235ecf46cb62cefcc6bddc6bf8ca3e7
[ "MIT" ]
null
null
null
# Copyright: (c) 2018, Pluribus Networks # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import (absolute_import, division, print_function) __metaclass__ = type from ansible_collections.community.general.tests.unit.compat.mock import patch from ansible_coll...
47.5
140
0.684211
d70d6067e4ac3d31f7db537d3dd217457efecbe7
5,778
py
Python
main.py
wdr-data/1live-plays
68ed22a659ea1540550bc9f5e70fdb83f362fa06
[ "MIT" ]
3
2020-07-31T11:22:04.000Z
2020-07-31T19:59:18.000Z
main.py
wdr-data/1live-plays
68ed22a659ea1540550bc9f5e70fdb83f362fa06
[ "MIT" ]
null
null
null
main.py
wdr-data/1live-plays
68ed22a659ea1540550bc9f5e70fdb83f362fa06
[ "MIT" ]
null
null
null
import math import sys import os import json import random from time import time, sleep from enum import Enum from queue import Queue import logging logging.basicConfig( level=logging.INFO, format="%(asctime)s - %(levelname)s - %(message)s", ) logging.getLogger("googleapiclient.discovery").setLevel(logging.ERROR) ...
23.975104
82
0.614746
d70d7ade3cf701d300050e2c8ebd17ee166d0c2b
2,035
py
Python
app.py
polyester-CTRL/MeetingTranscriptionWeb
178516004a2867c597e992194a6c4069cbf90c4f
[ "MIT" ]
null
null
null
app.py
polyester-CTRL/MeetingTranscriptionWeb
178516004a2867c597e992194a6c4069cbf90c4f
[ "MIT" ]
null
null
null
app.py
polyester-CTRL/MeetingTranscriptionWeb
178516004a2867c597e992194a6c4069cbf90c4f
[ "MIT" ]
null
null
null
from flask import Flask, render_template, request, session, redirect, jsonify import pickle app = Flask(__name__) app.secret_key = b'random string...' member_data = {} message_data = [] member_data_file = 'member_data.dat' message_data_file = 'message_data.dat' # load member_data from file try: with open(member_da...
22.362637
77
0.658968
cb86eae3b62c6744f4868b5d798621266d64582a
846
py
Python
source/pkgsrc/audio/picard/patches/patch-setup.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
1
2021-11-20T22:46:39.000Z
2021-11-20T22:46:39.000Z
source/pkgsrc/audio/picard/patches/patch-setup.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
null
null
null
source/pkgsrc/audio/picard/patches/patch-setup.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
null
null
null
$NetBSD: patch-setup.py,v 1.1 2021/05/15 11:45:52 nia Exp $ Don't selectively install app store data. --- setup.py.orig 2020-05-06 09:36:12.000000000 +0000 +++ setup.py @@ -289,8 +289,6 @@ class picard_build(build): 'publisher': os.environ.get('PICARD_APPX_PUBLISHER', default_publisher), ...
35.25
103
0.624113
384838e6d04338804f4674568a57b18feafa41b7
5,080
py
Python
examples/nowcoder/SQL1/tests.py
zhengtong0898/django-decode
69680853a4a5b07f6a9c4b65c7d86b2d401a92b1
[ "MIT" ]
5
2020-07-14T07:48:10.000Z
2021-12-20T21:20:10.000Z
examples/nowcoder/SQL1/tests.py
zhengtong0898/django-decode
69680853a4a5b07f6a9c4b65c7d86b2d401a92b1
[ "MIT" ]
7
2021-03-26T03:13:38.000Z
2022-03-12T00:42:03.000Z
examples/nowcoder/SQL1/tests.py
zhengtong0898/django-decode
69680853a4a5b07f6a9c4b65c7d86b2d401a92b1
[ "MIT" ]
1
2021-02-16T07:04:25.000Z
2021-02-16T07:04:25.000Z
from datetime import date from django.db import connections from django.test import TestCase, TransactionTestCase from .models import employees from django.db.models import Max from django.db.models.expressions import Subquery, OuterRef # Create your tests here. class SimpleTest(TransactionTestCase): reset_seque...
40.967742
124
0.595866
2a086e0e0083820b1a8bc627f4e5e80b973e68f7
815
py
Python
app/common/xsk_mysql_utils.py
luoweis/xskAdmin
d92d0297102140ce5241a0c9f3a80f520bee96a8
[ "MIT" ]
null
null
null
app/common/xsk_mysql_utils.py
luoweis/xskAdmin
d92d0297102140ce5241a0c9f3a80f520bee96a8
[ "MIT" ]
null
null
null
app/common/xsk_mysql_utils.py
luoweis/xskAdmin
d92d0297102140ce5241a0c9f3a80f520bee96a8
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding=utf-8 -*- from app.models.XSK import XSKStudent,XSKTeacher,XSKClass from app import db def add_student_single(**kwargs): """ 一次只增加一个学生的信息,写入数据库中 :param kwargs: :return: """ """判断添加的元素是否存在""" waring = "" if XSKStudent.query.filter_by(student_ID=kwargs....
21.447368
77
0.622086
2aea48bedda7d2dd1772501fc2c35824f6237584
256
py
Python
exercises/es/solution_01_02_01.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
2
2020-07-07T01:46:37.000Z
2021-04-20T03:19:43.000Z
exercises/es/solution_01_02_01.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
exercises/es/solution_01_02_01.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
# Importa spaCy import spacy # Crea el objeto nlp para procesar inglés nlp = spacy.blank("en") # Procesa un texto (aquí dice "Esta es una oración" en inglés) doc = nlp("This is a sentence.") # Imprime en pantalla el texto del documento print(doc.text)
19.692308
62
0.726563
2d69f3f35c7dbeeb48911da48a8aee1bd74a5812
560
py
Python
PINp/2014/Cheraneva A.S/task_3_24.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
PINp/2014/Cheraneva A.S/task_3_24.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
PINp/2014/Cheraneva A.S/task_3_24.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
#Задача 3. Вариант 24. #Напишите программу, которая выводит имя "Максимилиан Гольдман", и запрашивает его псевдоним. Программа должна сцеплять две эти строки и выводить полученную строку, разделяя имя и псевдоним с помощью тире. #Cheraneva A.S. #25.03.16 print("Герой нашей сегодняшней программы Максимилиан Гольдман...
35
205
0.757143
faf3f2eeedcdb5918e36256ebce15d3ff85d3a99
291
py
Python
api/importjobs/jobs.py
Pelleplutt/PUAT
b083d2ec5776bb73f6ba83a5ddab271a7b742e89
[ "MIT" ]
null
null
null
api/importjobs/jobs.py
Pelleplutt/PUAT
b083d2ec5776bb73f6ba83a5ddab271a7b742e89
[ "MIT" ]
null
null
null
api/importjobs/jobs.py
Pelleplutt/PUAT
b083d2ec5776bb73f6ba83a5ddab271a7b742e89
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- from flask import jsonify from flask_restful import Resource import puat.importjobs.jobs class Jobs(Resource): def get(self): jobs = puat.importjobs.jobs.Jobs() joblist = jobs.fetch_active() return jsonify(joblist)
22.384615
42
0.680412
87f68de8c567fd54d8af1aa626bff2213bffbf0a
260
py
Python
Pythonskripte/p3env/moarSilence.py
NoahEmbedded/EmbeddedKWD
2380d56b0b75bae4fedeb60885358332766f7319
[ "MIT" ]
null
null
null
Pythonskripte/p3env/moarSilence.py
NoahEmbedded/EmbeddedKWD
2380d56b0b75bae4fedeb60885358332766f7319
[ "MIT" ]
null
null
null
Pythonskripte/p3env/moarSilence.py
NoahEmbedded/EmbeddedKWD
2380d56b0b75bae4fedeb60885358332766f7319
[ "MIT" ]
null
null
null
from pydub import AudioSegment as AS stille = AS.silent(duration = 2000,frame_rate = 16000) pfad = "/home/noah/Schreibtisch/Bachelorarbeit/speechcommandCorpus/sehr_ruhig/" for i in range(1800): stille.export(pfad + "stille" + str(i) +".wav", format="wav")
43.333333
79
0.738462
35721fdcc2e95a88a2a9cea4bd5cc5c6fa2e1ead
1,488
py
Python
visualisation/visual.py
kaphka/ml-software
03c4c0023be3e10fcb9a625796142ed4605e8104
[ "Apache-2.0" ]
null
null
null
visualisation/visual.py
kaphka/ml-software
03c4c0023be3e10fcb9a625796142ed4605e8104
[ "Apache-2.0" ]
null
null
null
visualisation/visual.py
kaphka/ml-software
03c4c0023be3e10fcb9a625796142ed4605e8104
[ "Apache-2.0" ]
null
null
null
import vispy from vispy import app, scene, color from vispy import visuals from vispy.visuals.transforms import STTransform from vispy.geometry import create_box import sys import pickle import os.path as op import numpy as np # In[2]: with open('../theano/xor.keras' ,'rb') as kmodel: model = pickle.load(kmodel...
24.8
79
0.668011
52c2ddee69e232d3699581f48a37c34f046d94de
874
py
Python
src/built_in_functions/package_function.py
HuangHuaBingZiGe/GitHub-Demo
f3710f73b0828ef500343932d46c61d3b1e04ba9
[ "Apache-2.0" ]
null
null
null
src/built_in_functions/package_function.py
HuangHuaBingZiGe/GitHub-Demo
f3710f73b0828ef500343932d46c61d3b1e04ba9
[ "Apache-2.0" ]
null
null
null
src/built_in_functions/package_function.py
HuangHuaBingZiGe/GitHub-Demo
f3710f73b0828ef500343932d46c61d3b1e04ba9
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python # -*- coding: utf-8 -*- """ --------------------------------------------------------------------------------------------- # 包是一个有层次的文件目录结构,它定义了一个由模块和子包组成的python应用程序执行环境 # 有Analog.py文件,导入子包 import Phone.Mobile.Analog Phone.Mobile.Analog.dial() ---------------------------------------------------...
25.705882
93
0.331808
52d6edef6c77dadee2d279312d9d0552aa0464d3
252
py
Python
src/mongo.py
magistersart/ZTC_fork
ce72734ea575d9846b5b81f3efbfd14fa1f7e532
[ "PostgreSQL" ]
null
null
null
src/mongo.py
magistersart/ZTC_fork
ce72734ea575d9846b5b81f3efbfd14fa1f7e532
[ "PostgreSQL" ]
null
null
null
src/mongo.py
magistersart/ZTC_fork
ce72734ea575d9846b5b81f3efbfd14fa1f7e532
[ "PostgreSQL" ]
null
null
null
#!/usr/bin/python # pylint: disable=W0142 ''' Mongodb script for ztc (mongo.* items) Copyright (c) 2011 Vladimir Rusinov <vladimir@greenmice.info> License: GNU GPL v.3 ''' from ztc.mongo import Mongo d = Mongo() m = d.args[0] d.get(m, *d.args[1:])
15.75
61
0.678571
761a4b28b5c01fd2b2577ac6dc8d232155a97820
619
py
Python
python/en/archive/dropbox/cvxpy/cvxpy-example-linear_programming-01.py
aimldl/coding
70ddbfaa454ab92fd072ee8dc614ecc330b34a70
[ "MIT" ]
null
null
null
python/en/archive/dropbox/cvxpy/cvxpy-example-linear_programming-01.py
aimldl/coding
70ddbfaa454ab92fd072ee8dc614ecc330b34a70
[ "MIT" ]
null
null
null
python/en/archive/dropbox/cvxpy/cvxpy-example-linear_programming-01.py
aimldl/coding
70ddbfaa454ab92fd072ee8dc614ecc330b34a70
[ "MIT" ]
null
null
null
import numpy as np import matplotlib.pyplot as plt import cvxpy as cvx f = np.array( [1,1] ) A = np.array( [[2,1], [1,2]] ) b = np.array( [[29],[25]] ) lb = np.array( [[2],[5]] ) x = cvx.Variable(2,1) objective = cvx.Minimize( -f*x ) constraints = [ A*x <=b, lb <=x ] prob = cvx.Problem( objective, contraints ) resu...
23.807692
70
0.597738
8728b4283ee6cfd219fdf0d2d53169f9aef647e7
627
py
Python
home/migrations/0003_auto_20210901_1813.py
DeepakDarkiee/stockbinz
53512e9eb7d7214662e38828b23e4b664e6a6cda
[ "Apache-2.0" ]
1
2022-01-08T14:18:14.000Z
2022-01-08T14:18:14.000Z
home/migrations/0003_auto_20210901_1813.py
DeepakDarkiee/stockbinz
53512e9eb7d7214662e38828b23e4b664e6a6cda
[ "Apache-2.0" ]
null
null
null
home/migrations/0003_auto_20210901_1813.py
DeepakDarkiee/stockbinz
53512e9eb7d7214662e38828b23e4b664e6a6cda
[ "Apache-2.0" ]
null
null
null
# Generated by Django 3.2.6 on 2021-09-01 18:13 from django.db import migrations, models import phonenumber_field.modelfields class Migration(migrations.Migration): dependencies = [ ('home', '0002_rename_contactview_contact'), ] operations = [ migrations.AlterField( model_na...
25.08
94
0.62201
0d9518e11bef3724e77356e81464e391e670a7a2
1,501
py
Python
FCN/src/loss.py
JNingWei/Image_Segmentation
4b1663c8b294cfa29da29a0f94dab066af69cd1e
[ "Python-2.0", "OLDAP-2.7" ]
13
2018-01-21T03:38:06.000Z
2021-01-16T05:23:53.000Z
FCN/src/loss.py
JNingWei/Image-Segmentation
4b1663c8b294cfa29da29a0f94dab066af69cd1e
[ "Python-2.0", "OLDAP-2.7" ]
11
2020-01-28T21:40:15.000Z
2022-03-11T23:16:37.000Z
FCN/src/loss.py
JNingWei/Image_Segmentation
4b1663c8b294cfa29da29a0f94dab066af69cd1e
[ "Python-2.0", "OLDAP-2.7" ]
6
2018-01-09T06:44:27.000Z
2020-07-07T07:03:55.000Z
# coding=utf-8 """ Image-Segmentation Loss computation module. __author__ = 'JNingWei' """ import tensorflow as tf def loss(logits, labels, num_classes, head=None): """Calculate the loss from the logits and the labels. Args: logits: tensor, float - [batch_size, width, height, num_classes]. U...
31.93617
78
0.602931
0db49bcfcc25099bba84d05273e400800e3c0db1
540
py
Python
CareerTinderServer/CareerTinder/migrations/0006_auto_20160918_0224.py
sarojaerabelli/HVGS
86ec3d2de496540ca439c40f4a0c58c47aa181cf
[ "MIT" ]
1
2016-09-18T16:40:27.000Z
2016-09-18T16:40:27.000Z
CareerTinderServer/CareerTinder/migrations/0006_auto_20160918_0224.py
sarojaerabelli/HVGS
86ec3d2de496540ca439c40f4a0c58c47aa181cf
[ "MIT" ]
null
null
null
CareerTinderServer/CareerTinder/migrations/0006_auto_20160918_0224.py
sarojaerabelli/HVGS
86ec3d2de496540ca439c40f4a0c58c47aa181cf
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.10.1 on 2016-09-18 06:24 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('CareerTinder', '0005_auto_20160918_0221'), ] operations = [ migrations.Alte...
25.714286
135
0.592593
1d150fc6ea17456f6c2fd617a4842b122f4da13f
7,204
py
Python
apps/profile/views.py
IT-PM-OpenAdaptronik/Webapp
c3bdde0ca56b6d77f49bc830fa2b8bb41a26bae4
[ "MIT" ]
2
2017-12-17T21:28:22.000Z
2018-02-02T14:44:58.000Z
apps/profile/views.py
IT-PM-OpenAdaptronik/Webapp
c3bdde0ca56b6d77f49bc830fa2b8bb41a26bae4
[ "MIT" ]
118
2017-10-31T13:45:09.000Z
2018-02-24T20:51:42.000Z
apps/profile/views.py
OpenAdaptronik/Rattler
c3bdde0ca56b6d77f49bc830fa2b8bb41a26bae4
[ "MIT" ]
null
null
null
from django.contrib import messages from django.contrib.auth import update_session_auth_hash from django.contrib.auth.views import logout from django.contrib.auth.mixins import LoginRequiredMixin from django.contrib.auth.decorators import login_required from django.contrib.auth.forms import PasswordChangeForm from djan...
35.141463
148
0.66241
12027833367645ba035cde4b1130c5573b5d191a
1,981
py
Python
plot-functions.py
Kingpin007/SC-Lab
ba8fa9dfca4b950ebcb8c8d409f7e215c7971925
[ "MIT" ]
null
null
null
plot-functions.py
Kingpin007/SC-Lab
ba8fa9dfca4b950ebcb8c8d409f7e215c7971925
[ "MIT" ]
null
null
null
plot-functions.py
Kingpin007/SC-Lab
ba8fa9dfca4b950ebcb8c8d409f7e215c7971925
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Thu Jul 26 09:34:42 2018 @author: Kingpin007 Equation: 1/(1+x^2) """ import matplotlib.pyplot as plt import numpy as np from scipy.special import gamma as Gamma from scipy import signal from scipy.integrate import simps, trapz from pylab import * def f(x): return x**2 def g...
21.532609
118
0.5684
f6322918c4cf162cac6ade889791c61fdbac2fda
459
py
Python
20-hs-redez-sem/groups/01-decentFS/src/setup.py
Kyrus1999/BACnet
5be8e1377252166041bcd0b066cce5b92b077d06
[ "MIT" ]
8
2020-03-17T21:12:18.000Z
2021-12-12T15:55:54.000Z
20-hs-redez-sem/groups/01-decentFS/src/setup.py
Kyrus1999/BACnet
5be8e1377252166041bcd0b066cce5b92b077d06
[ "MIT" ]
2
2021-07-19T06:18:43.000Z
2022-02-10T12:17:58.000Z
20-hs-redez-sem/groups/01-decentFS/src/setup.py
Kyrus1999/BACnet
5be8e1377252166041bcd0b066cce5b92b077d06
[ "MIT" ]
25
2020-03-20T09:32:45.000Z
2021-07-18T18:12:59.000Z
import setuptools setuptools.setup( name="decentFS", version="0.0.0-dev", description="A decentral filesystem, inspired by hyperdrive", url="https://github.com/cn-uofbasel/BACnet", packages=setuptools.find_packages(), install_requires=[ 'cbor2', 'pynacl', ], classi...
24.157895
65
0.610022
f679b55aeb6412f333969e24fd9dbbcdb43173ef
168
py
Python
python/python_backup/PRAC_PYTHON/insert.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
16
2018-11-26T08:39:42.000Z
2019-05-08T10:09:52.000Z
python/python_backup/PRAC_PYTHON/insert.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
8
2020-05-04T06:29:26.000Z
2022-02-12T05:33:16.000Z
python/python_backup/PRAC_PYTHON/insert.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
5
2020-02-11T16:02:21.000Z
2021-02-05T07:48:30.000Z
def insertion_sort[L]: for i in range(0,len(L)): temp=L[i] ptr=i-1 while (ptr>=0) and L[ptr]>temp: L[ptr+1]=L[ptr] ptr=ptr-1 L[ptr]=temp print L,
16.8
33
0.565476
9cd245532aa7f16f2bd0cebf2469502c9129a5e3
233
py
Python
Licence 1/I11/TP3/tp3_3_1.py
axelcoezard/licence
1ed409c4572dea080169171beb7e8571159ba071
[ "MIT" ]
8
2020-11-26T20:45:12.000Z
2021-11-29T15:46:22.000Z
Licence 1/I11/TP3/tp3_3_1.py
axelcoezard/licence
1ed409c4572dea080169171beb7e8571159ba071
[ "MIT" ]
null
null
null
Licence 1/I11/TP3/tp3_3_1.py
axelcoezard/licence
1ed409c4572dea080169171beb7e8571159ba071
[ "MIT" ]
6
2020-10-23T15:29:24.000Z
2021-05-05T19:10:45.000Z
text = input("entrez une chaine de caracteres : ") i, j = 0, len(text) - 1 while i < len(text) and j > 0: if i < len(text) // 2: print(text[i], text[j]) i, j = i + 1, j - 1 if len(text) % 2 == 1: print(text[len(text) // 2])
29.125
50
0.536481
14426f5e809d6e2fda9fef4ed1d38ba498336f73
414
py
Python
frappe-bench/apps/erpnext/erpnext/patches/v5_0/update_frozen_accounts_permission_role.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/patches/v5_0/update_frozen_accounts_permission_role.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/patches/v5_0/update_frozen_accounts_permission_role.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
# Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors # License: GNU General Public License v3. See license.txt import frappe def execute(): account_settings = frappe.get_doc("Accounts Settings") if not account_settings.frozen_accounts_modifier and account_settings.bde_auth_role: frappe.db.set_val...
31.846154
85
0.801932
0d064a6c13942864fc10fa9c9b662ad321fc8aa8
4,623
py
Python
model/stargan.py
isadrtdinov/StarGAN
bdb33310817854802ebc6356b28303616f23060a
[ "MIT" ]
null
null
null
model/stargan.py
isadrtdinov/StarGAN
bdb33310817854802ebc6356b28303616f23060a
[ "MIT" ]
null
null
null
model/stargan.py
isadrtdinov/StarGAN
bdb33310817854802ebc6356b28303616f23060a
[ "MIT" ]
null
null
null
import torch from torch import nn from model.generator import Generator from model.critic import Critic from collections import defaultdict class StarGAN(object): """ Main StarGAN class, which implements initialization and training of the models """ def __init__(self, params, device): self...
38.525
89
0.64828
25cb3d0f83a416654b0fc4066a811b72b1e0b498
3,805
py
Python
src/util/gensby.py
CorvusPrudens/Corisc
e30abde099dc3c1979c2f7d7ff6d37f7d990f852
[ "MIT" ]
null
null
null
src/util/gensby.py
CorvusPrudens/Corisc
e30abde099dc3c1979c2f7d7ff6d37f7d990f852
[ "MIT" ]
null
null
null
src/util/gensby.py
CorvusPrudens/Corisc
e30abde099dc3c1979c2f7d7ff6d37f7d990f852
[ "MIT" ]
null
null
null
import os import sys import shutil import fileinput import re def usage(): print("\nThis script will generate an sby file for a given input"); print("If no options are given, the program will not generate any output.") print("\nUsage: file <option>") print("\n\t-h\n\t print this usage message") print("\n\t...
25.884354
97
0.561629
9f47ac2c2cb121e3f9227be25e3cb1b3dae9bb3a
392
py
Python
Django/ballon/migrations/0006_resume_name.py
ballon3/GRAD
c630e32272fe34ead590c04d8360169e02be87f1
[ "MIT" ]
null
null
null
Django/ballon/migrations/0006_resume_name.py
ballon3/GRAD
c630e32272fe34ead590c04d8360169e02be87f1
[ "MIT" ]
null
null
null
Django/ballon/migrations/0006_resume_name.py
ballon3/GRAD
c630e32272fe34ead590c04d8360169e02be87f1
[ "MIT" ]
null
null
null
# Generated by Django 2.1 on 2018-08-28 09:25 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('ballon', '0005_auto_20180828_0202'), ] operations = [ migrations.AddField( model_name='resume', name='name', ...
20.631579
63
0.59949
e2bda64cb24b1f3fb663c887101277fe0a131e2f
2,363
py
Python
simple-sklearn-demo/test12/classificationTest.py
crackedcd/Intern.MT
36398837af377a7e1c4edd7cbb15eabecd2c3103
[ "MIT" ]
1
2019-07-05T03:42:17.000Z
2019-07-05T03:42:17.000Z
simple-sklearn-demo/test12/classificationTest.py
crackedcd/Intern.MT
36398837af377a7e1c4edd7cbb15eabecd2c3103
[ "MIT" ]
null
null
null
simple-sklearn-demo/test12/classificationTest.py
crackedcd/Intern.MT
36398837af377a7e1c4edd7cbb15eabecd2c3103
[ "MIT" ]
1
2019-06-24T05:56:55.000Z
2019-06-24T05:56:55.000Z
""" 目标值为离散数据时的问题被称作分类问题 classification 逻辑回归 logistic regression 这是一种分类算法 广告点击率(是否被点击)/垃圾邮件识别/是否患病/虚假账号等等问题, 目标值都是离散的(甚至是二分的) sigmoid函数(激活函数) 1 / (1 + e^(-x)) 其中, x是线性回归的输出(即 y = w1x1 + w2x2 + w3x3 + ... + b, 即: 1 / (1 + e^(-(w1x1 + w2x2 + w3x3 + ... + b))) 逻辑回归的最终分类(二分)是基于概率的. 通过sigmoid函数计算后, 结果会被落在0~1这个区间. 然后, 设定一个阈...
29.911392
86
0.606433
1aa3125d64b5b27ab64f88a8d8403f8f7ed19d50
27
py
Python
outro.py
lcarlin/guppe
a0ee7b85e8687e8fb8243fbb509119a94bc6460f
[ "Apache-2.0" ]
1
2021-12-18T15:29:24.000Z
2021-12-18T15:29:24.000Z
outro.py
lcarlin/guppe
a0ee7b85e8687e8fb8243fbb509119a94bc6460f
[ "Apache-2.0" ]
null
null
null
outro.py
lcarlin/guppe
a0ee7b85e8687e8fb8243fbb509119a94bc6460f
[ "Apache-2.0" ]
3
2021-08-23T22:45:20.000Z
2022-02-17T13:17:09.000Z
print("OLá Mundo ?!?!?!?")
13.5
26
0.481481
b3ac2c3bc1911e54328105f6aabae8a20cc5c3fc
1,035
py
Python
RDS/circle2_use_cases/port/src/api/User/Service/Service.py
Sciebo-RDS/Sciebo-RDS
d71cf449ed045a2a7a049e2cb77c99fd5a9195bd
[ "MIT" ]
10
2020-06-24T08:22:24.000Z
2022-01-13T16:17:36.000Z
RDS/circle2_use_cases/port/src/api/User/Service/Service.py
Sciebo-RDS/Sciebo-RDS
d71cf449ed045a2a7a049e2cb77c99fd5a9195bd
[ "MIT" ]
78
2020-01-23T14:32:06.000Z
2022-03-07T14:11:16.000Z
RDS/circle2_use_cases/port/src/api/User/Service/Service.py
Sciebo-RDS/Sciebo-RDS
d71cf449ed045a2a7a049e2cb77c99fd5a9195bd
[ "MIT" ]
1
2020-06-24T08:33:48.000Z
2020-06-24T08:33:48.000Z
import Util from RDS import BaseService, User from flask import jsonify def index(user_id): listOfServices = Util.tokenService.getAllServicesForUser(User(user_id)) data = {"length": len(listOfServices), "list": listOfServices} return jsonify(data) def get(user_id, servicename): servicename = servic...
27.236842
88
0.649275
37b7d365c86dd78b77cae3c861427c1d295deef3
720
py
Python
RedBook/ch8/books/models.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
RedBook/ch8/books/models.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
RedBook/ch8/books/models.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
from django.db import models class Book(models.Model): title = models.CharField(max_length=100) authors = models.ManyToManyField('Author') publisher = models.ForeignKey('Publisher', on_delete=models.CASCADE) publication_date = models.DateField() def __str__(self): return self.title class...
25.714286
72
0.704167
0396909b45801b02d6c7b5e0493d3f4d9524fa41
1,067
py
Python
Scholien/migrations/0007_auto_20170531_1731.py
wmles/scholarium.at
d2356b3e475df772382e035ddcb839fc7dae4305
[ "MIT" ]
1
2017-07-24T10:19:36.000Z
2017-07-24T10:19:36.000Z
Scholien/migrations/0007_auto_20170531_1731.py
wmles/scholarium.at
d2356b3e475df772382e035ddcb839fc7dae4305
[ "MIT" ]
9
2017-07-26T14:16:08.000Z
2022-03-11T23:14:40.000Z
Scholien/migrations/0007_auto_20170531_1731.py
wmles/scholarium.at
d2356b3e475df772382e035ddcb839fc7dae4305
[ "MIT" ]
1
2017-03-07T12:38:23.000Z
2017-03-07T12:38:23.000Z
# -*- coding: utf-8 -*- # Generated by Django 1.9.11 on 2017-05-31 15:31 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('Scholien', '0006_auto_20170531_1640'), ] operations = [ migrations.AddField...
29.638889
90
0.597001
4458a393fc9fbc9787ef9c24c5e43babf1d1c2a6
823
py
Python
ipsc/2018/G.py
dipta007/Competitive-Programming
998d47f08984703c5b415b98365ddbc84ad289c4
[ "MIT" ]
6
2018-10-15T18:45:05.000Z
2022-03-29T04:30:10.000Z
ipsc/2018/G.py
dipta007/Competitive-Programming
998d47f08984703c5b415b98365ddbc84ad289c4
[ "MIT" ]
null
null
null
ipsc/2018/G.py
dipta007/Competitive-Programming
998d47f08984703c5b415b98365ddbc84ad289c4
[ "MIT" ]
4
2018-01-07T06:20:07.000Z
2019-08-21T15:45:59.000Z
import os vs = [] with open('easy.txt', 'r') as myfile: data=myfile.readline().strip() if len(data) > 0: vs.append(data) while data: data = myfile.readline().strip() # print(data) if len(data) > 0: vs.append(data) # vs.sort() res = 0 ind = 1 mod = 1000000007 # ...
16.795918
42
0.479951
926d0ea46587bb16b9227ea57b0a0b598c1dbd7c
4,345
py
Python
ZbjDjChannels/chatsolo/consumers.py
zbjlala/ZbjDjChannels
c4da2339574e2e398bd452eef4d026eab309752c
[ "MIT" ]
null
null
null
ZbjDjChannels/chatsolo/consumers.py
zbjlala/ZbjDjChannels
c4da2339574e2e398bd452eef4d026eab309752c
[ "MIT" ]
null
null
null
ZbjDjChannels/chatsolo/consumers.py
zbjlala/ZbjDjChannels
c4da2339574e2e398bd452eef4d026eab309752c
[ "MIT" ]
null
null
null
import json import threading from channels.generic.websocket import AsyncJsonWebsocketConsumer, AsyncWebsocketConsumer from chatsolo.models import UserList from chatsolo.serializers import user_list_json class ChatConsumer(AsyncJsonWebsocketConsumer): chats = dict() lock = threading.Lock() async def con...
29.358108
90
0.540391
2bcf247510e6e8f06d6b390d9cb6cf1148d98501
114
py
Python
scripts/hello_world_land.py
breezage/Hacktoberfest-1
6f6d52248c79c0e72fd13b599500318fce3f9ab0
[ "MIT" ]
null
null
null
scripts/hello_world_land.py
breezage/Hacktoberfest-1
6f6d52248c79c0e72fd13b599500318fce3f9ab0
[ "MIT" ]
null
null
null
scripts/hello_world_land.py
breezage/Hacktoberfest-1
6f6d52248c79c0e72fd13b599500318fce3f9ab0
[ "MIT" ]
1
2019-10-24T06:45:21.000Z
2019-10-24T06:45:21.000Z
# LANGUAGE: python # AUTHOR: willianfs # GITHUB: https://github.com/willianfs print("Hello World Land!!!");
19
39
0.675439
920fbec9f968022cdcc9df9a69c980403be43460
2,387
py
Python
render_templates.py
pzhokhov/pzhokhov.github.io
84f9979a1953bc36aee959cc6142454de0fb3ed5
[ "MIT" ]
1
2019-11-20T22:24:25.000Z
2019-11-20T22:24:25.000Z
render_templates.py
pzhokhov/pzhokhov.github.io
84f9979a1953bc36aee959cc6142454de0fb3ed5
[ "MIT" ]
1
2019-05-12T17:00:16.000Z
2019-05-12T17:00:16.000Z
render_templates.py
pzhokhov/pzhokhov.github.io
84f9979a1953bc36aee959cc6142454de0fb3ed5
[ "MIT" ]
2
2018-12-19T14:40:45.000Z
2019-05-12T16:22:22.000Z
import os import pandas as pd from collections import defaultdict from jinja2 import Environment, FileSystemLoader, select_autoescape import datetime import numpy as np env = Environment( loader=FileSystemLoader('.') ) TEMPLATE_FILES = [ "js/piecharts.js.template" ] TEMPLATE_EXT = '.template' HOURS_FILE = "dat...
29.109756
109
0.642648
47028dfc75c5afec3342f37e64a5906ec58abed2
671
py
Python
ebenezer/atencion/migrations/0003_auto_20181005_1313.py
davrv93/ebenezer-backend
d3db4dafd9a8c35bea9f32afe2be1dd451f64298
[ "Apache-2.0" ]
null
null
null
ebenezer/atencion/migrations/0003_auto_20181005_1313.py
davrv93/ebenezer-backend
d3db4dafd9a8c35bea9f32afe2be1dd451f64298
[ "Apache-2.0" ]
3
2020-02-11T23:15:00.000Z
2021-06-10T20:52:17.000Z
ebenezer/atencion/migrations/0003_auto_20181005_1313.py
davrv93/ebenezer-backend
d3db4dafd9a8c35bea9f32afe2be1dd451f64298
[ "Apache-2.0" ]
null
null
null
# Generated by Django 2.1.2 on 2018-10-05 13:13 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('atencion', '0002_auto_20181005_0031'), ] operations = [ migrations.AlterModelOptions( name='dominio', options={'default_perm...
37.277778
367
0.652757
5b47d8aca261a4800933648dcdc7b2c10edf1d3e
6,040
py
Python
PYCOMPILET-main/Pycompilet-enc.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-17T03:35:03.000Z
2021-12-08T06:00:31.000Z
PYCOMPILET-main/Pycompilet-enc.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
null
null
null
PYCOMPILET-main/Pycompilet-enc.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-05T18:07:48.000Z
2022-02-24T21:25:07.000Z
import marshal,zlib,base64 #PYCOMPILET BY MR.1557 #DI BUAT 03/09/2021 exec(marshal.loads(zlib.decompress(base64.b64decode("eJztWllsHElyjeq7m/fZpA5OUde0NBreh6gdScNrJI54TZFcDlsjyN1dRbKbXd09VdUWe8QG1pAWGH/5w8Z+GDBgwz82DCywH4btf8N/axj2hwF/GPAA/rIBwwYM2MYCdkRkVh9k89B4Rz6wbFZmZGZkVGZWvIjIrEqB/PPg9TFe9p8qADr+K5AFMBWIK6BQ2QNZD...
1,510
5,970
0.966225
3434b1572fbcf682c72ebdad7adad3042ac16c02
738
py
Python
SleekSecurity/layers/plugins/fingerprint/framework/zend.py
GitInitDev/ZohoUniv
966704837e65f58b52492b56d08e7958df3d220a
[ "Unlicense" ]
null
null
null
SleekSecurity/layers/plugins/fingerprint/framework/zend.py
GitInitDev/ZohoUniv
966704837e65f58b52492b56d08e7958df3d220a
[ "Unlicense" ]
null
null
null
SleekSecurity/layers/plugins/fingerprint/framework/zend.py
GitInitDev/ZohoUniv
966704837e65f58b52492b56d08e7958df3d220a
[ "Unlicense" ]
null
null
null
#!/usr/bin/env python # -*- coding:utf-8 -*- # # @name: Wascan - Web Application Scanner # @repo: https://github.com/m4ll0k/Wascan # @author: Momo Outaadi (M4ll0k) # @license: See the file 'LICENSE.txt from re import search,I def zend(headers,content): _ = False for header in headers.items(): _ |= search(...
36.9
99
0.650407
1b3a6ae8b97a835f2b1c0b60b96d471ec491c797
3,594
py
Python
src/onegov/feriennet/models/group_invite.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/feriennet/models/group_invite.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/feriennet/models/group_invite.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from cached_property import cached_property from onegov.activity.models import Attendee, Booking, Occasion, Period from onegov.activity.utils import random_group_code from onegov.user import User from sqlalchemy import func, or_ from sqlalchemy.orm import joinedload class GroupInvite(object): def __init__(self, ...
32.972477
79
0.63606
84e47f48c4530255920e7e1106f12614b04fb14d
2,178
py
Python
src/aijack/defense/ckks/encrypter.py
luoshenseeker/AIJack
4e871a5b3beb4b7c976d38060d6956efcebf880d
[ "MIT" ]
24
2021-11-17T02:16:47.000Z
2022-03-27T01:04:08.000Z
src/aijack/defense/ckks/encrypter.py
luoshenseeker/AIJack
4e871a5b3beb4b7c976d38060d6956efcebf880d
[ "MIT" ]
9
2021-12-03T06:09:27.000Z
2022-03-29T06:33:53.000Z
src/aijack/defense/ckks/encrypter.py
luoshenseeker/AIJack
4e871a5b3beb4b7c976d38060d6956efcebf880d
[ "MIT" ]
5
2022-01-12T09:58:04.000Z
2022-03-17T09:29:04.000Z
from numpy.polynomial import Polynomial from .ciphertext import CKKSCiphertext from .plaintext import CKKSPlaintext from .random import gen_binary_poly, gen_normal_poly, gen_uniform_poly from .utils import polydiv_coef class CKKSEncrypter: def __init__(self, encoder, q): self.N = encoder.N self.q...
27.56962
88
0.557392
1705ae2e29780a9f858b51e699460ee2f03a4f68
1,082
py
Python
python_lessons/Textastic_Files/Python SQLite Tutorial - MtMk/MtMk_database.py
1986MMartin/coding-sections-markus
e13be32e5d83e69250ecfb3c76a04ee48a320607
[ "Apache-2.0" ]
null
null
null
python_lessons/Textastic_Files/Python SQLite Tutorial - MtMk/MtMk_database.py
1986MMartin/coding-sections-markus
e13be32e5d83e69250ecfb3c76a04ee48a320607
[ "Apache-2.0" ]
null
null
null
python_lessons/Textastic_Files/Python SQLite Tutorial - MtMk/MtMk_database.py
1986MMartin/coding-sections-markus
e13be32e5d83e69250ecfb3c76a04ee48a320607
[ "Apache-2.0" ]
null
null
null
import sqlite3 CREATE_TABLE_BUYING = ("""CREATE TABLE IF NOT EXISTS buying ( id INTEGER PRIMARY KEY, b_date TEXT, company TEXT, categorie TEXT, price INTEGER );""") CREATE_TABLE_BEANS = ("""CREATE TABLE IF NOT EXISTS beans ( id INTEGER PRIMARY KEY, name TEXT, method TEXT, rating INTEG...
24.044444
94
0.707948
ca3e6ec22c91d5ad29352efa48401ba451cded6c
2,662
py
Python
datasets/landuse.py
PyGeoL/GeoL
67a5bd2f63091e19041094c14d419055fa5ce6f0
[ "MIT" ]
8
2018-03-09T16:44:38.000Z
2021-04-07T11:33:30.000Z
datasets/landuse.py
PyGeoL/GeoL
67a5bd2f63091e19041094c14d419055fa5ce6f0
[ "MIT" ]
4
2020-03-24T15:34:54.000Z
2021-06-01T21:54:33.000Z
datasets/landuse.py
PyGeoL/GeoL
67a5bd2f63091e19041094c14d419055fa5ce6f0
[ "MIT" ]
1
2020-05-13T14:30:55.000Z
2020-05-13T14:30:55.000Z
""" Methods to load different landuse datasets. """ # Authors: Gianni Barlacchi <gianni.barlacchi@gmail.com> import geopandas as gpd import os from ..utils import constants def urban_atlas(input, aggregation_level=0): gdf = gpd.read_file(os.path.abspath(input)) gdf[constants.ITEM_COL] = gdf[constants.ITEM_...
35.972973
132
0.651014
04bdf4b70c1e5420491dca5a72e6e42837be27c0
1,171
py
Python
Hackerrank_problems/Queue using Two Stacks/solution.py
gbrls/CompetitiveCode
b6f1b817a655635c3c843d40bd05793406fea9c6
[ "MIT" ]
165
2020-10-03T08:01:11.000Z
2022-03-31T02:42:08.000Z
Hackerrank_problems/Queue using Two Stacks/solution.py
gbrls/CompetitiveCode
b6f1b817a655635c3c843d40bd05793406fea9c6
[ "MIT" ]
383
2020-10-03T07:39:11.000Z
2021-11-20T07:06:35.000Z
Hackerrank_problems/Queue using Two Stacks/solution.py
gbrls/CompetitiveCode
b6f1b817a655635c3c843d40bd05793406fea9c6
[ "MIT" ]
380
2020-10-03T08:05:04.000Z
2022-03-19T06:56:59.000Z
class Queue: """ A queue using two stacks (head and tail), the head stack keeps the elements in a queue order, it means ready to dequeue or print the top element. When necessary the last elements in the tail stack are moved to the head stack. The normalize_head method verify if its necessary...
27.880952
63
0.582408
6d320d6eca5a8ccd51550e4a2815fb78b25b6f71
12,132
py
Python
SICAssembler.py
yousefra/SIC-Assembler
a2f9d2082705a7349f7d606ab36149900c08c596
[ "MIT" ]
null
null
null
SICAssembler.py
yousefra/SIC-Assembler
a2f9d2082705a7349f7d606ab36149900c08c596
[ "MIT" ]
null
null
null
SICAssembler.py
yousefra/SIC-Assembler
a2f9d2082705a7349f7d606ab36149900c08c596
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 from terminaltables import AsciiTable class SIC: def __init__(self, asmFile=None, intermediateFile=None, objectFile=None, X='8000'): self.fileNames = { 'asmFile': asmFile, 'intermediateFile': intermediateFile, 'objectFile': objectFile, ...
37.9125
132
0.440488
6d4c5a39cb6baba1b317e9f09aa7053a3ceed82e
2,386
py
Python
research/cv/stgcn/preprocess.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/cv/stgcn/preprocess.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/cv/stgcn/preprocess.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
24
2021-10-15T08:32:45.000Z
2022-03-24T18:45:20.000Z
# Copyright 2021 Huawei Technologies Co., Ltd # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to...
39.766667
103
0.708718
b6657c9031dfece0d4c6187fe3c0686f9958275b
39,327
py
Python
rollout.py
michal-choinski/sequential_moral_dilemmas
c6364672b996f04e4c791e20fd8b96eb5cf15b91
[ "MIT" ]
1
2021-04-21T10:08:10.000Z
2021-04-21T10:08:10.000Z
rollout.py
michal-choinski/sequential_moral_dilemmas
c6364672b996f04e4c791e20fd8b96eb5cf15b91
[ "MIT" ]
null
null
null
rollout.py
michal-choinski/sequential_moral_dilemmas
c6364672b996f04e4c791e20fd8b96eb5cf15b91
[ "MIT" ]
null
null
null
#!/usr/bin/env python import argparse import collections import copy import gym import json import matplotlib.pyplot as plt import numpy as np import os from pathlib import Path import shelve import shutil import ray import ray.cloudpickle as cloudpickle from ray.rllib.env import MultiAgentEnv from ray.rllib.env.base...
36.926761
126
0.621431
155deece553aff3018775136fd522417f6d02184
99
py
Python
pages/themes/beginners/modulesAndPackages/examples/my_app_pack/app.py
ProgressBG-Python-Course/ProgressBG-Python
6429833696c2c50d9f902f62cc3a65ca62659c69
[ "MIT" ]
null
null
null
pages/themes/beginners/modulesAndPackages/examples/my_app_pack/app.py
ProgressBG-Python-Course/ProgressBG-Python
6429833696c2c50d9f902f62cc3a65ca62659c69
[ "MIT" ]
null
null
null
pages/themes/beginners/modulesAndPackages/examples/my_app_pack/app.py
ProgressBG-Python-Course/ProgressBG-Python
6429833696c2c50d9f902f62cc3a65ca62659c69
[ "MIT" ]
null
null
null
import packA.packAfunctions print("__name__: ", __name__) packA.packAfunctions.packAfunction()
12.375
36
0.787879
171a7ee0bafa040cb84526f7991fe9d33a21c385
600
py
Python
hist_db/history.py
apragacz/hist-db
a2631a7eab004499dae98a0495bc17ee78c6be8a
[ "MIT" ]
1
2021-12-14T22:52:46.000Z
2021-12-14T22:52:46.000Z
hist_db/history.py
apragacz/hist-db
a2631a7eab004499dae98a0495bc17ee78c6be8a
[ "MIT" ]
null
null
null
hist_db/history.py
apragacz/hist-db
a2631a7eab004499dae98a0495bc17ee78c6be8a
[ "MIT" ]
null
null
null
from __future__ import absolute_import, print_function, unicode_literals import os import sys if sys.version_info[0] >= 3: open_unicode = open else: import codecs open_unicode = codecs.open def iter_history_lines(is_reversed=False): if is_reversed: for line in reversed(list(iter_history_lines...
25
76
0.688333
173caafef57c4762adfe48c1fb8d5caacfe7c803
1,851
py
Python
7-assets/past-student-repos/LambdaSchool-master/m6/62b1/ring_buffer/ring_buffer.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
7-assets/past-student-repos/LambdaSchool-master/m6/62b1/ring_buffer/ring_buffer.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
7-assets/past-student-repos/LambdaSchool-master/m6/62b1/ring_buffer/ring_buffer.py
eengineergz/Lambda
1fe511f7ef550aed998b75c18a432abf6ab41c5f
[ "MIT" ]
null
null
null
# Rubric: # 2: Solution in ring_buffer.py runs, but may have one or two logical errors; passes at least 5/6 tests (Note that each function in the test file that begins with test is a test) # 3: Solution in ring_buffer.py has no syntax or logical errors and passes all tests (Note that each function in the test file t...
50.027027
213
0.703404
bdb6ae2db8a71a01adf696d4bfc7acc71bab4a27
704
py
Python
day12/scope.py
nurmatthias/100DaysOfCode
22002e4b31d13e6b52e6b9222d2e91c2070c5744
[ "Apache-2.0" ]
null
null
null
day12/scope.py
nurmatthias/100DaysOfCode
22002e4b31d13e6b52e6b9222d2e91c2070c5744
[ "Apache-2.0" ]
null
null
null
day12/scope.py
nurmatthias/100DaysOfCode
22002e4b31d13e6b52e6b9222d2e91c2070c5744
[ "Apache-2.0" ]
null
null
null
################### Scope #################### # Global Scope enemies = 1 def increase_enemies(): # local scope enemies = 2 print(f"enemies inside function: {enemies}") # no block scope if 2 > 1: new_enemie = 1 print(f"enemie inside blocks (if/loop): {new_enemie}") def increase_...
20.705882
58
0.606534
8af416989a96947be151fa63c10a54e920dbbcbf
691
py
Python
python/sql_alchemy/managing_relationship/app.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
python/sql_alchemy/managing_relationship/app.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
python/sql_alchemy/managing_relationship/app.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
from os import environ from datetime import datetime from sqlalchemy import create_engine from sqlalchemy.orm import sessionmaker from example_model import Base, ExampleModel # Create engine # db_uri = environ.get('SQLALCHEMY_DATABASE_URI') db_uri = 'sqlite:///data.db' engine = create_engine(db_uri, echo=True) # Cre...
25.592593
54
0.70767
c141f759d25bf6fc9cc84473db135e3fa4d4f502
2,761
py
Python
test/test_npu/test_network_ops/test_argmin.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_argmin.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_argmin.py
Ascend/pytorch
39849cf72dafe8d2fb68bd1679d8fd54ad60fcfc
[ "BSD-3-Clause" ]
null
null
null
# Copyright (c) 2020 Huawei Technologies Co., Ltd # 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 appl...
40.014493
102
0.636364
c16b288f28380f07e4b205a8116366d3285a90b3
782
py
Python
actions.py
FireEater64/DashBroker
386fa94c6706950e695ce258d07df29207043b8a
[ "MIT" ]
null
null
null
actions.py
FireEater64/DashBroker
386fa94c6706950e695ce258d07df29207043b8a
[ "MIT" ]
null
null
null
actions.py
FireEater64/DashBroker
386fa94c6706950e695ce258d07df29207043b8a
[ "MIT" ]
null
null
null
__author__ = 'George' from clockwork import clockwork import ConfigParser from database import * config = ConfigParser.RawConfigParser() config.read("dashbroker.ini") clockwork_key = config.get("ClockworkSMS", "Key") def notifyHouse(message): for housemate in Housemates.select().where(Housemates.active): send...
25.225806
64
0.759591
e7b40cbf4a395be8eb37336b69a2e278cfa41d5d
1,098
py
Python
source/pkgsrc/cad/py-MyHDL/patches/patch-myhdl___always__seq.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
1
2021-11-20T22:46:39.000Z
2021-11-20T22:46:39.000Z
source/pkgsrc/cad/py-MyHDL/patches/patch-myhdl___always__seq.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
null
null
null
source/pkgsrc/cad/py-MyHDL/patches/patch-myhdl___always__seq.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
null
null
null
$NetBSD: patch-myhdl___always__seq.py,v 1.1 2018/12/27 16:01:54 joerg Exp $ --- myhdl/_always_seq.py.orig 2018-12-25 21:39:40.951802739 +0000 +++ myhdl/_always_seq.py @@ -45,7 +45,7 @@ _error.EmbeddedFunction = "embedded func class ResetSignal(_Signal): - def __init__(self, val, active, async): + def __init...
32.294118
75
0.587432
415a93b5b3e34bbcb6d0240f30c4c1ce1df6d17e
1,928
py
Python
Python/Docs/The-Python-Tutorial.python.org/4.6-match-Statements.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
Python/Docs/The-Python-Tutorial.python.org/4.6-match-Statements.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
Python/Docs/The-Python-Tutorial.python.org/4.6-match-Statements.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
def http_error(status): match status: case 400: return f"{status}: Bad request" case 401 | 402 | 403: return f"{status}: Not allowed" case 404: return f"{status}: Not found" case 418: return f"{status}: I'm a teapot" case _: ...
20.731183
67
0.480809
00fe67ea419f9264392ab718e99e323d43a61d5e
9,236
py
Python
core/wifi_matrix.py
kklocker/EiT-WiFi-placer
c2c621baa06377d62567d7bd0c2f048f1e6c0859
[ "MIT" ]
null
null
null
core/wifi_matrix.py
kklocker/EiT-WiFi-placer
c2c621baa06377d62567d7bd0c2f048f1e6c0859
[ "MIT" ]
null
null
null
core/wifi_matrix.py
kklocker/EiT-WiFi-placer
c2c621baa06377d62567d7bd0c2f048f1e6c0859
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # from math import floor from dask import delayed, compute import numpy as np import matplotlib.image import matplotlib.pyplot as plt import scipy.sparse import scipy.sparse.linalg from scipy.sparse import save_npz, load_npz from itertools import zip_longest import time import os c = 1 def sub...
27.164706
110
0.567562
2e623b89931c95e534d570527267d1c07e4ab60d
2,495
py
Python
src/SerialApi.py
VetrixTV/GigaCHAD
497f73f54f6164b797a3b46eeaaacf275aefe5e9
[ "MIT" ]
1
2022-01-12T10:43:23.000Z
2022-01-12T10:43:23.000Z
src/SerialApi.py
VetrixTV/GigaCHAD
497f73f54f6164b797a3b46eeaaacf275aefe5e9
[ "MIT" ]
1
2022-02-02T07:27:44.000Z
2022-02-02T07:27:44.000Z
src/SerialApi.py
VetrixTV/GigaCHAD
497f73f54f6164b797a3b46eeaaacf275aefe5e9
[ "MIT" ]
1
2022-01-12T10:01:53.000Z
2022-01-12T10:01:53.000Z
from asyncore import read from cmath import log from ctypes.wintypes import BYTE from socket import timeout import time import serial import os import csv ROOT_DIR = os.path.dirname(os.path.abspath(__file__)) center_y = 160 center_x = 220 toleranceThreshold = 19 #threshold for the face recognition file = 'cord.cs...
30.060241
125
0.63006
cf565881146c91ca376fb24a4a1bfbb61f8b5eed
129
py
Python
Licence 2/I33/TP 6/ex_2.py
axelcoezard/licence
1ed409c4572dea080169171beb7e8571159ba071
[ "MIT" ]
8
2020-11-26T20:45:12.000Z
2021-11-29T15:46:22.000Z
Licence 2/I33/TP 6/ex_2.py
axelcoezard/licence
1ed409c4572dea080169171beb7e8571159ba071
[ "MIT" ]
null
null
null
Licence 2/I33/TP 6/ex_2.py
axelcoezard/licence
1ed409c4572dea080169171beb7e8571159ba071
[ "MIT" ]
6
2020-10-23T15:29:24.000Z
2021-05-05T19:10:45.000Z
def decompose(n): T = [] while n != 0: T += [n & 1] n = n >> 1 return T[::-1] print(decompose(14))
12.9
20
0.395349
990bf56a044f70698b23632da89fb0baabcdf09e
1,942
py
Python
messagebox/anzeige.py
Hofei90/picoffee
6b2a00f2b4631790b90495d736afeb331d759241
[ "MIT" ]
3
2019-05-04T21:34:33.000Z
2022-01-25T10:00:25.000Z
messagebox/anzeige.py
Hofei90/picoffee
6b2a00f2b4631790b90495d736afeb331d759241
[ "MIT" ]
4
2019-04-11T05:03:55.000Z
2020-07-09T06:52:58.000Z
messagebox/anzeige.py
Hofei90/picoffee
6b2a00f2b4631790b90495d736afeb331d759241
[ "MIT" ]
1
2020-02-13T19:04:31.000Z
2020-02-13T19:04:31.000Z
import time from RPLCD.i2c import CharLCD COLS = 16 # Anzahl der Stellen am Display class Display: def __init__(self, lcd=None): if lcd is None: self.lcd = CharLCD(i2c_expander='PCF8574', address=0x27, port=1, cols=COLS, rows=2, dotsize=8, charmap='A02', auto_...
26.972222
121
0.564882
852c74431d88f8ba977b1d7e03a995f74b12dc90
7,599
py
Python
step_decay_test/train.py
BIGBALLON/Model_Experiment
d96712a01997a2f51cad29d611e60d2567ce1021
[ "MIT" ]
2
2018-11-25T14:05:33.000Z
2019-07-12T03:45:24.000Z
step_decay_test/train.py
BIGBALLON/Model_Experiment
d96712a01997a2f51cad29d611e60d2567ce1021
[ "MIT" ]
null
null
null
step_decay_test/train.py
BIGBALLON/Model_Experiment
d96712a01997a2f51cad29d611e60d2567ce1021
[ "MIT" ]
null
null
null
import sys sys.path.append("../models") sys.path.append("../") import argparse import math import keras import numpy as np import tensorflow as tf from keras import backend from keras.preprocessing.image import ImageDataGenerator from keras.callbacks import Callback, CSVLogger from keras.models import Model from keras...
41.52459
163
0.627583
5170994435438daf67218765e04b0730a368b3ae
602
py
Python
Dockerfiles/gedlab-khmer-filter-abund/pymodules/python2.7/lib/python/pygsl/combination.py
poojavade/Genomics_Docker
829b5094bba18bbe03ae97daf925fee40a8476e8
[ "Apache-2.0" ]
1
2019-07-29T02:53:51.000Z
2019-07-29T02:53:51.000Z
Dockerfiles/gedlab-khmer-filter-abund/pymodules/python2.7/lib/python/pygsl/combination.py
poojavade/Genomics_Docker
829b5094bba18bbe03ae97daf925fee40a8476e8
[ "Apache-2.0" ]
1
2021-09-11T14:30:32.000Z
2021-09-11T14:30:32.000Z
Dockerfiles/gedlab-khmer-filter-abund/pymodules/python2.7/lib/python/pygsl/combination.py
poojavade/Genomics_Docker
829b5094bba18bbe03ae97daf925fee40a8476e8
[ "Apache-2.0" ]
2
2016-12-19T02:27:46.000Z
2019-07-29T02:53:54.000Z
# Author Pierre Schnizer # Date 8. October 2003 """ Wrapper for the combination. Usage: Initalisation: c = Combination(n, k) Testing for validness: c.valid() returns 0 = GSL_SUCCESS if ok. Raises a gsl_DomainError if invalid. The gsl_combination_get is wrapped by: c.tolist...
22.296296
66
0.654485
7a3387a5315ffed13a435393a9584d60e737ee5e
1,201
py
Python
0-newbooks/faceswap-GAN/utils.py
gopala-kr/ds-notebooks
bc35430ecdd851f2ceab8f2437eec4d77cb59423
[ "MIT" ]
1
2019-05-10T09:16:23.000Z
2019-05-10T09:16:23.000Z
0-newbooks/faceswap-GAN/utils.py
gopala-kr/ds-notebooks
bc35430ecdd851f2ceab8f2437eec4d77cb59423
[ "MIT" ]
null
null
null
0-newbooks/faceswap-GAN/utils.py
gopala-kr/ds-notebooks
bc35430ecdd851f2ceab8f2437eec4d77cb59423
[ "MIT" ]
1
2019-10-14T07:30:18.000Z
2019-10-14T07:30:18.000Z
import cv2 import numpy import os def get_image_paths( directory ): return [ x.path for x in os.scandir( directory ) if x.name.endswith(".jpg") or x.name.endswith(".png") ] def load_images( image_paths, convert=None ): iter_all_images = ( cv2.resize(cv2.imread(fn), (256,256)) for fn in image_paths ) if co...
34.314286
108
0.620316
7a72b91f48978237bd9f113cbb26926cf81dc165
101
py
Python
scripts/hello_world_intu1.py
breezage/Hacktoberfest-1
6f6d52248c79c0e72fd13b599500318fce3f9ab0
[ "MIT" ]
null
null
null
scripts/hello_world_intu1.py
breezage/Hacktoberfest-1
6f6d52248c79c0e72fd13b599500318fce3f9ab0
[ "MIT" ]
null
null
null
scripts/hello_world_intu1.py
breezage/Hacktoberfest-1
6f6d52248c79c0e72fd13b599500318fce3f9ab0
[ "MIT" ]
1
2019-10-24T06:45:21.000Z
2019-10-24T06:45:21.000Z
# LANGUAGE: Python # AUTHOR: Shiva Subedi # GITHUB: https://github.com/intu1 print('Hello, World!');
20.2
34
0.70297
8f886aa30d6bf40218f234d814d0912f1557eeab
623
py
Python
04_SQL/commerce/auctions/migrations/0006_auto_20201103_1532.py
DaviNakamuraCardoso/Harvard-CS50-Web-Programming
afec745eede41f7b294c3ee6ebaff9ac042e5e4c
[ "MIT" ]
null
null
null
04_SQL/commerce/auctions/migrations/0006_auto_20201103_1532.py
DaviNakamuraCardoso/Harvard-CS50-Web-Programming
afec745eede41f7b294c3ee6ebaff9ac042e5e4c
[ "MIT" ]
null
null
null
04_SQL/commerce/auctions/migrations/0006_auto_20201103_1532.py
DaviNakamuraCardoso/Harvard-CS50-Web-Programming
afec745eede41f7b294c3ee6ebaff9ac042e5e4c
[ "MIT" ]
null
null
null
# Generated by Django 3.1.2 on 2020-11-03 15:32 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('auctions', '0005_auto_20201103_1531'), ] operations = [ migrations.AlterField( model_name='listing', name='category'...
25.958333
89
0.601926
854693a9b779eee8d0195fb227f0725eb2c18368
2,298
py
Python
simple-tensorflow-demo/4.demos/7.emaTest.py
crackedcd/Intern.MT
36398837af377a7e1c4edd7cbb15eabecd2c3103
[ "MIT" ]
1
2019-07-05T03:42:17.000Z
2019-07-05T03:42:17.000Z
simple-tensorflow-demo/4.demos/7.emaTest.py
crackedcd/Intern.MT
36398837af377a7e1c4edd7cbb15eabecd2c3103
[ "MIT" ]
null
null
null
simple-tensorflow-demo/4.demos/7.emaTest.py
crackedcd/Intern.MT
36398837af377a7e1c4edd7cbb15eabecd2c3103
[ "MIT" ]
1
2019-06-24T05:56:55.000Z
2019-06-24T05:56:55.000Z
""" 滑动平均 exponential moving average 记录每个参数一段时间过往值的平均 当参数w或b发生变化时, ema缓慢追随(类似于cpu load average), 因此也被称为影子值. ema_new = 衰减率 * ema + (1 - 衰减率) * 参数 其中, 衰减率 = min(moving_average_decay, (1+轮数)/(10+轮数)) 初始情况下, moving_average_decay会给一个较大的值, 例如0.99, 参数, 轮数, 滑动平均值都为0. 第1轮训练后, 假设w更新成了1, ema = min(0.99, 1/10) * 0 + (1 - min(0.99...
28.725
86
0.604003
a446451cc3e21e6c2d4e81f8b226d824bb7175f5
1,741
py
Python
src/python3_learn_video/combination.py
HuangHuaBingZiGe/GitHub-Demo
f3710f73b0828ef500343932d46c61d3b1e04ba9
[ "Apache-2.0" ]
null
null
null
src/python3_learn_video/combination.py
HuangHuaBingZiGe/GitHub-Demo
f3710f73b0828ef500343932d46c61d3b1e04ba9
[ "Apache-2.0" ]
null
null
null
src/python3_learn_video/combination.py
HuangHuaBingZiGe/GitHub-Demo
f3710f73b0828ef500343932d46c61d3b1e04ba9
[ "Apache-2.0" ]
null
null
null
""" 组合 """ class Turtle: def __init__(self, x): self.num = x class Fish: def __init__(self, x): self.num = x class Pool: def __init__(self, x, y): self.turtle = Turtle(x) self.fish = Fish(y) def print_num(self): print('水池里总共有乌龟 %d 只,小鱼 %d 条!' % (self.tu...
16.12037
74
0.433084
2d27483ac94b50b6b1ffa7deb58f80bc83e8e725
5,220
py
Python
transonic/analyses/blocks_if.py
fluiddyn/transonic
a460e9f6d1139f79b668cb3306d1e8a7e190b72d
[ "BSD-3-Clause" ]
88
2019-01-08T16:39:08.000Z
2022-02-06T14:19:23.000Z
transonic/analyses/blocks_if.py
fluiddyn/transonic
a460e9f6d1139f79b668cb3306d1e8a7e190b72d
[ "BSD-3-Clause" ]
13
2019-06-20T15:53:10.000Z
2021-02-09T11:03:29.000Z
transonic/analyses/blocks_if.py
fluiddyn/transonic
a460e9f6d1139f79b668cb3306d1e8a7e190b72d
[ "BSD-3-Clause" ]
1
2019-11-05T03:03:14.000Z
2019-11-05T03:03:14.000Z
"""Analyses for "if blocks" =========================== """ import gast as ast from transonic.analyses.util import gather_rawcode_comments class BlockDefinition: """Represent a block definition""" def __init__(self, **kwargs): self.kwargs = kwargs self.__dict__.update(**kwargs) sel...
35.033557
82
0.491762
7acb9f28e7e71b1645a35b3a333fabeac0b2eb64
698
py
Python
Labs/lab02 done grade/Lab 02/Donglin Yu.py
robots-make-art-too/Donglin_yu
95eede21e94baf16db1770337234668a816a8056
[ "MIT" ]
null
null
null
Labs/lab02 done grade/Lab 02/Donglin Yu.py
robots-make-art-too/Donglin_yu
95eede21e94baf16db1770337234668a816a8056
[ "MIT" ]
null
null
null
Labs/lab02 done grade/Lab 02/Donglin Yu.py
robots-make-art-too/Donglin_yu
95eede21e94baf16db1770337234668a816a8056
[ "MIT" ]
null
null
null
import tweepy consumer_key="3eeMdnGbDWebBN0p9i6L3HkrW" consumer_secret="nES6nuNLiJa6THQe9YqeSrg8mj1kADTrq07In0tcdcco1f0GJh" access_token="1494076192726691844-LPphEqMNW7vK4w3fqB9jtu5DAAiG1O" access_secret="KojsVaBquAA7qA0xV3wPZRtUakk8snVKsW7LLtiFqvG3n" auth = tweepy.OAuth1UserHandler(consumer_key,consumer_secre...
31.727273
69
0.780802
bb3e6d30c4d58fc1b362a93a2f21e784aa7bd67a
2,102
py
Python
main.py
AndreiD049/ProgressBar
5fcc5ab39e55e3522c3d3b3c0eec8d1a91ac6174
[ "MIT" ]
null
null
null
main.py
AndreiD049/ProgressBar
5fcc5ab39e55e3522c3d3b3c0eec8d1a91ac6174
[ "MIT" ]
null
null
null
main.py
AndreiD049/ProgressBar
5fcc5ab39e55e3522c3d3b3c0eec8d1a91ac6174
[ "MIT" ]
null
null
null
from flask import Flask, render_template, request from logic.round import Round import json app = Flask(__name__) app.debug = False @app.route('/') def index(): return render_template("index.html") @app.route("/scoreboard", methods=["GET", "POST"]) def scoreboard(): if request.method == "POST": round...
31.373134
142
0.603711