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
df0ffc1d10c3681e6a3f3d8535e732ae06e05f70
11,389
py
Python
BlueHens/2021/crypto/aHead_Of_The_curve/secdsa.py
mystickev/ctf-archives
89e99a5cd5fb6b2923cad3fe1948d3ff78649b4e
[ "MIT" ]
1
2021-11-02T20:53:58.000Z
2021-11-02T20:53:58.000Z
BlueHens/2021/crypto/aHead_Of_The_curve/secdsa.py
ruhan-islam/ctf-archives
8c2bf6a608c821314d1a1cfaa05a6cccef8e3103
[ "MIT" ]
null
null
null
BlueHens/2021/crypto/aHead_Of_The_curve/secdsa.py
ruhan-islam/ctf-archives
8c2bf6a608c821314d1a1cfaa05a6cccef8e3103
[ "MIT" ]
1
2021-12-19T11:06:24.000Z
2021-12-19T11:06:24.000Z
#Elliptic curve basics, tools for finding rational points, and ECDSA implementation. #Brendan Cordy, 2015 from fractions import Fraction from math import ceil, sqrt from random import SystemRandom, randrange from hashlib import sha256 from time import time import pyotp import datetime #Affine Point (+Infin...
36.73871
109
0.533936
df2feb09124b292e71c2fed0e87e5d3a3194ba7f
1,571
py
Python
src/onegov/feriennet/redirects.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/feriennet/redirects.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/feriennet/redirects.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from onegov.feriennet import FeriennetApp from onegov.core.redirect import Redirect @FeriennetApp.path(path='/angebote') class AngeboteRedirect(Redirect): to = '/activities' @FeriennetApp.path(path='/angebot', absorb=True) class AngebotRedirect(Redirect): to = '/activity' @FeriennetApp.path(path='/durchfu...
21.520548
56
0.737747
80113db6fd49bdbee56d7db184c2b3980e848a7e
1,599
py
Python
modules/fadb/adbBin.py
Bym24v/FAS
efbcf606c49dd591857e0e537bc5b9f082c13405
[ "MIT" ]
3
2018-02-11T11:34:30.000Z
2020-05-06T12:11:03.000Z
modules/fadb/adbBin.py
Bym24v/FAS
efbcf606c49dd591857e0e537bc5b9f082c13405
[ "MIT" ]
null
null
null
modules/fadb/adbBin.py
Bym24v/FAS
efbcf606c49dd591857e0e537bc5b9f082c13405
[ "MIT" ]
null
null
null
import os, threading from subprocess import Popen, PIPE from modules.fmongodb.fClient import FASClient instFas = FASClient() def runAdb(): # Path path = os.getcwd() + "/tools/adb/./adb" arg = "logcat" arg2 = "-v" arg3 = "brief" # Open p = Popen([path, arg, arg2, arg3], stdout=PI...
21.90411
100
0.524703
d572e2825bc5f8f9f5f7225cdb84378eebd98ee8
418
py
Python
tests/parser/test_load_languages.py
OrangeUtan/babelbox
3dd01e078aea8aa352ff5606179d5e1e09f4b827
[ "MIT" ]
2
2021-03-18T04:34:23.000Z
2021-03-23T17:35:07.000Z
tests/parser/test_load_languages.py
OrangeUtan/babelbox
3dd01e078aea8aa352ff5606179d5e1e09f4b827
[ "MIT" ]
null
null
null
tests/parser/test_load_languages.py
OrangeUtan/babelbox
3dd01e078aea8aa352ff5606179d5e1e09f4b827
[ "MIT" ]
null
null
null
import os import pytest from pytest_insta import SnapshotFixture import babelbox def test_no_prefix(snapshot: SnapshotFixture): assert snapshot("languages.json") == babelbox.load_languages( "tests/parser/examples/misc", False ) def test_prefix_filename(snapshot: SnapshotFixture): assert snapsh...
22
65
0.741627
8934e2a64aacd68bcc4b08b76af7462f2ed2b03d
1,413
py
Python
Incremental/inc_bot.py
austinmh12/DiscordBots
55550b68a7ad6423de55e62dbbff93fd88f08ff2
[ "MIT" ]
null
null
null
Incremental/inc_bot.py
austinmh12/DiscordBots
55550b68a7ad6423de55e62dbbff93fd88f08ff2
[ "MIT" ]
null
null
null
Incremental/inc_bot.py
austinmh12/DiscordBots
55550b68a7ad6423de55e62dbbff93fd88f08ff2
[ "MIT" ]
null
null
null
from datetime import datetime as dt, timedelta as td from discord.ext import commands from discord.ext.commands import Bot from os import execv from os.path import getmtime import asyncio import discord import logging import sys from incremental.player import Player from incremental.resource import Resource with open(...
31.4
89
0.755131
12231f8970f33f68964ae872af3e2bc24113ad37
828
py
Python
Pythonskripte/pygameTest.py
NoahEmbedded/EmbeddedKWD
2380d56b0b75bae4fedeb60885358332766f7319
[ "MIT" ]
null
null
null
Pythonskripte/pygameTest.py
NoahEmbedded/EmbeddedKWD
2380d56b0b75bae4fedeb60885358332766f7319
[ "MIT" ]
null
null
null
Pythonskripte/pygameTest.py
NoahEmbedded/EmbeddedKWD
2380d56b0b75bae4fedeb60885358332766f7319
[ "MIT" ]
null
null
null
import pygame import numpy as np h,w = 5, 3 border = 50 pygame.init() screen = pygame.display.set_mode((w+(2*border), h+(2*border))) done = False clock = pygame.time.Clock() bild1 = np.array(np.mat("10000 10000 10000 10000 10000 ; 5000 5000 5000 5000 5000 ; 100 100 100 100 100")) bild2 = np.array(np.mat("100 100 100...
26.709677
106
0.629227
12465d07f2cc9b62e196e166270a66dd19ba51e9
5,024
py
Python
marsyas-vamp/marsyas/src/marsyas_python/polysynth.py
jaouahbi/VampPlugins
27c2248d1c717417fe4d448cdfb4cb882a8a336a
[ "Apache-2.0" ]
null
null
null
marsyas-vamp/marsyas/src/marsyas_python/polysynth.py
jaouahbi/VampPlugins
27c2248d1c717417fe4d448cdfb4cb882a8a336a
[ "Apache-2.0" ]
null
null
null
marsyas-vamp/marsyas/src/marsyas_python/polysynth.py
jaouahbi/VampPlugins
27c2248d1c717417fe4d448cdfb4cb882a8a336a
[ "Apache-2.0" ]
null
null
null
from marsyas import * from marsyas_util import create from collections import deque def main(): synth = Synth() last_tup = (0,0,0) while(True): msg = synth.get_midi_bytes() if msg != last_tup: # print msg (noteon, note, velo) = msg if noteon == 144: ...
36.941176
146
0.637341
d60e47b376c2ed75eb1901dc1ef0dec1db06a294
4,350
py
Python
Proxverter-main/proxverter/plugins/base.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-17T03:35:03.000Z
2021-12-08T06:00:31.000Z
Proxverter-main/proxverter/plugins/base.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
null
null
null
Proxverter-main/proxverter/plugins/base.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-05T18:07:48.000Z
2022-02-24T21:25:07.000Z
from proxy.http.parser import HttpParser, httpParserTypes, httpParserStates from proxy.http.proxy import HttpProxyBasePlugin class PluginBase(HttpProxyBasePlugin): '''Modified HttpProxyBasePlugin from proxy.py. Provides more functionality''' def __init__(self, *args, **kwargs): super().__init__(*args,...
37.5
81
0.647356
d62207e0f706f400ebade3f8e5e56cd2814dd6a8
2,145
py
Python
tool_discovery/ontology.py
FAIRplus/WP3_FAIR_tooling
3c6470c4f5fc3d686b4571711bb7ed6f849a9622
[ "Apache-2.0" ]
null
null
null
tool_discovery/ontology.py
FAIRplus/WP3_FAIR_tooling
3c6470c4f5fc3d686b4571711bb7ed6f849a9622
[ "Apache-2.0" ]
13
2021-06-01T10:07:02.000Z
2022-03-24T12:16:26.000Z
tool_discovery/ontology.py
FAIRplus/WP3_FAIR_tooling
3c6470c4f5fc3d686b4571711bb7ed6f849a9622
[ "Apache-2.0" ]
null
null
null
import biotools_API_querying as bAq import pandas as pd topics = ["ontology_annotation", "ontology_management","ontology_engineering","ontology_mapping"] for topic in topics: print(topic+"/n/n") # parsing zooma results terms_file='keywords/'+topic+'_EDAM_curated.csv' ontology_edam_terms, terms_label_ontology, fr...
55
157
0.841958
d657cfa5d950abfe1b3a8f2beea931048e50cae9
3,058
py
Python
Aggregator/agg_gmap_transit_score.py
socialdistancingdashboard/virushack
6ef69d26c5719d0bf257f4594ed2488dd73cdc40
[ "Apache-2.0" ]
29
2020-03-21T00:47:51.000Z
2021-07-17T15:50:33.000Z
Aggregator/agg_gmap_transit_score.py
socialdistancingdashboard/virushack
6ef69d26c5719d0bf257f4594ed2488dd73cdc40
[ "Apache-2.0" ]
7
2020-03-21T14:04:26.000Z
2022-03-02T08:05:40.000Z
Aggregator/agg_gmap_transit_score.py
socialdistancingdashboard/virushack
6ef69d26c5719d0bf257f4594ed2488dd73cdc40
[ "Apache-2.0" ]
13
2020-03-21T01:08:08.000Z
2020-04-08T17:21:11.000Z
from coords_to_kreis import coords_convert import boto3 import json import time from datetime import date, timedelta import pandas as pd import csv import numpy as np import settings def aggregate(date): s3_client = boto3.client('s3') #date = date.today() - timedelta(days = 1) #print(date) data = pd.Da...
34.75
198
0.614454
7f0a028c169b511726060dff43df906bd9d5415a
5,726
py
Python
hihope_neptune-oh_hid/00_src/v0.1/third_party/LVM2/daemons/lvmdbusd/main.py
dawmlight/vendor_oh_fun
bc9fb50920f06cd4c27399f60076f5793043c77d
[ "Apache-2.0" ]
1
2022-02-15T08:51:55.000Z
2022-02-15T08:51:55.000Z
hihope_neptune-oh_hid/00_src/v0.3/third_party/LVM2/daemons/lvmdbusd/main.py
dawmlight/vendor_oh_fun
bc9fb50920f06cd4c27399f60076f5793043c77d
[ "Apache-2.0" ]
null
null
null
hihope_neptune-oh_hid/00_src/v0.3/third_party/LVM2/daemons/lvmdbusd/main.py
dawmlight/vendor_oh_fun
bc9fb50920f06cd4c27399f60076f5793043c77d
[ "Apache-2.0" ]
null
null
null
# Copyright (C) 2015-2016 Red Hat, Inc. All rights reserved. # # This copyrighted material is made available to anyone wishing to use, # modify, copy, or redistribute it subject to the terms and conditions # of the GNU General Public License v.2. # # You should have received a copy of the GNU General Public License # a...
29.06599
79
0.745023
612ff82c842d797cae246a6b00117e0dc0026d71
1,377
py
Python
norden/norden/doctype/eyenor_stickers/eyenor_stickers.py
thispl/norden
2a208056e948cae42da688e28c15024124254867
[ "MIT" ]
null
null
null
norden/norden/doctype/eyenor_stickers/eyenor_stickers.py
thispl/norden
2a208056e948cae42da688e28c15024124254867
[ "MIT" ]
null
null
null
norden/norden/doctype/eyenor_stickers/eyenor_stickers.py
thispl/norden
2a208056e948cae42da688e28c15024124254867
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright (c) 2021, Teampro and contributors # For license information, please see license.txt from __future__ import unicode_literals import frappe from frappe.model.document import Document class EyenorStickers(Document): pass def generate_stickers(doc): data = """<body><center>...
23.338983
166
0.554103
b4f5d2c23339f19e3ae93bc4428eea9de9f2fc0e
927
py
Python
photocapture.py
Torreshan/Nao
8ad8eb9b92ce303ad79892efa2a812a1d971e058
[ "MIT" ]
null
null
null
photocapture.py
Torreshan/Nao
8ad8eb9b92ce303ad79892efa2a812a1d971e058
[ "MIT" ]
null
null
null
photocapture.py
Torreshan/Nao
8ad8eb9b92ce303ad79892efa2a812a1d971e058
[ "MIT" ]
null
null
null
from naoqi import ALProxy import qi import os import sys import time import math import argparse IP = "10.0.29.2" PORT = 9559 # try: # photoCaptureProxy = ALProxy("ALPhotoCapture",IP,PORT) # except Exception, e: # print(str(e)) # exit(1) # photoCaptureProxy.setResolution(1) # photoCaptureProxy.setPictureFormat("jpg"...
26.485714
64
0.746494
370c93002c073ba2292ee088f98b1ea7827c0053
3,901
py
Python
test/test_npu/test_grid_sampler.py
Ascend/pytorch
39849cf72dafe8d2fb68bd1679d8fd54ad60fcfc
[ "BSD-3-Clause" ]
1
2021-12-02T03:07:35.000Z
2021-12-02T03:07:35.000Z
test/test_npu/test_grid_sampler.py
Ascend/pytorch
39849cf72dafe8d2fb68bd1679d8fd54ad60fcfc
[ "BSD-3-Clause" ]
1
2021-11-12T07:23:03.000Z
2021-11-12T08:28:13.000Z
test/test_npu/test_grid_sampler.py
Ascend/pytorch
39849cf72dafe8d2fb68bd1679d8fd54ad60fcfc
[ "BSD-3-Clause" ]
null
null
null
# Copyright (c) 2020 Huawei Technologies Co., Ltd # Copyright (c) 2019, Facebook CORPORATION. # 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/lice...
48.7625
111
0.674442
25dccf9239f14d6781ec3852503a2e46d418763d
2,955
py
Python
lbry/tests/integration/test_account_commands.py
Nykseli/lbry-sdk
07afc0aa0a1e6c0ef6aa284fb47513af940440c1
[ "MIT" ]
null
null
null
lbry/tests/integration/test_account_commands.py
Nykseli/lbry-sdk
07afc0aa0a1e6c0ef6aa284fb47513af940440c1
[ "MIT" ]
4
2020-10-27T21:53:05.000Z
2022-02-11T03:10:54.000Z
lbry/tests/integration/test_account_commands.py
braveheart12/lbry-sdk
dc709b468f9dce60d206161785def5c7ace2b763
[ "MIT" ]
null
null
null
from lbry.testcase import CommandTestCase class AccountManagement(CommandTestCase): async def test_account_list_set_create_remove_add(self): # check initial account response = await self.daemon.jsonrpc_account_list() self.assertEqual(len(response['lbc_regtest']), 1) # change acco...
43.455882
90
0.666328
d3652967a0a44ada75b91bd2621fd4ee20045949
7,471
py
Python
Packs/WindowsForensics/Scripts/RegistryParse/RegistryParse.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/WindowsForensics/Scripts/RegistryParse/RegistryParse.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/WindowsForensics/Scripts/RegistryParse/RegistryParse.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
import codecs import configparser import demistomock as demisto # noqa: F401 from CommonServerPython import * # noqa: F401 CUSTOM_REG_TYPE = 'Custom' REGISTRY_TYPE_TO_KEY = { 'Users': [r'HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList'], 'MachineStartup': [r'HKEY_LOCAL_MACHINE\S...
41.505556
130
0.628162
9f44000ff388396daa8bc14c437e71a462a1e85b
13,579
py
Python
engine/model.py
HyechurnJang/rdhcp
6e9e983527a501b3f0d1bfcb796b62868b5b6292
[ "Apache-2.0" ]
null
null
null
engine/model.py
HyechurnJang/rdhcp
6e9e983527a501b3f0d1bfcb796b62868b5b6292
[ "Apache-2.0" ]
null
null
null
engine/model.py
HyechurnJang/rdhcp
6e9e983527a501b3f0d1bfcb796b62868b5b6292
[ "Apache-2.0" ]
1
2020-10-07T00:24:45.000Z
2020-10-07T00:24:45.000Z
# -*- coding: utf-8 -*- ''' Created on 2018. 3. 30. @author: HyechurnJang ''' import os import pygics from sql import * from ipaddress import ip_network from netifaces import ifaddresses, AF_INET, AF_LINK DEBUG = True db = Sql( Mysql( os.environ.get('RDHCP_DATABASE', 'localhost'), ...
40.655689
303
0.535165
9fa33ee059bdfc8ff76392d80ea7fb6a0fd4a242
941
py
Python
app/api/v1/session.py
zucc-acm-devteam/zuccacm-sso
9c7d2f0b9cc069962f32b555152732a98bf2e94a
[ "Apache-2.0" ]
null
null
null
app/api/v1/session.py
zucc-acm-devteam/zuccacm-sso
9c7d2f0b9cc069962f32b555152732a98bf2e94a
[ "Apache-2.0" ]
null
null
null
app/api/v1/session.py
zucc-acm-devteam/zuccacm-sso
9c7d2f0b9cc069962f32b555152732a98bf2e94a
[ "Apache-2.0" ]
null
null
null
from flask_login import current_user, login_required, login_user, logout_user from app.libs.error_code import Success, NotFound, Forbidden, DeleteSuccess from app.libs.red_print import RedPrint from app.validators.user import LoginForm from app.models.user import User from app.libs.helper import renew_ticket api = Re...
26.885714
77
0.726886
4cdd5c18859a82abe8befbf8af033e0d5aedce09
575
py
Python
musterloesungen/6_warm_ups/dictionaries.py
giu/appe6-uzh-hs2018
204dea36be1e53594124b606cdfa044368e54726
[ "MIT" ]
null
null
null
musterloesungen/6_warm_ups/dictionaries.py
giu/appe6-uzh-hs2018
204dea36be1e53594124b606cdfa044368e54726
[ "MIT" ]
null
null
null
musterloesungen/6_warm_ups/dictionaries.py
giu/appe6-uzh-hs2018
204dea36be1e53594124b606cdfa044368e54726
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Kurs: Python: Grundlagen der Programmierung für Nicht-Informatiker # Semester: Herbstsemester 2018 # Homepage: http://accaputo.ch/kurs/python-uzh-hs-2018/ # Author: Giuseppe Accaputo # Aufgabe: Warm-Up: Dictionaries besser kennenlernen def preisliste_ausgeben(menu):...
28.75
76
0.613913
1a6660ef66e470505b2f6489a4c6757325e9e737
17,442
py
Python
backend/apps/test_all_url_endpoints.py
n-hackert/match4healthcare
761248c27b49e568c545c643a72eac9a040649d7
[ "MIT" ]
null
null
null
backend/apps/test_all_url_endpoints.py
n-hackert/match4healthcare
761248c27b49e568c545c643a72eac9a040649d7
[ "MIT" ]
null
null
null
backend/apps/test_all_url_endpoints.py
n-hackert/match4healthcare
761248c27b49e568c545c643a72eac9a040649d7
[ "MIT" ]
null
null
null
from django.test import TestCase, Client from apps.iamstudent.models import Student, AUSBILDUNGS_TYPEN_COLUMNS from apps.ineedstudent.models import Hospital from apps.accounts.models import User from django.contrib import auth import numpy as np def generate_random_student(countrycode="DE", plz="14482", i=0, validate...
42.75
117
0.642071
6465aca9b1ad8ec2565cf8881bc61c342672a493
87
py
Python
python/redengine.py
DubskySteam/Facharbeit_Schlitten
4ce8764a13ea41120b1b17f9f77d516aa958442b
[ "MIT" ]
null
null
null
python/redengine.py
DubskySteam/Facharbeit_Schlitten
4ce8764a13ea41120b1b17f9f77d516aa958442b
[ "MIT" ]
null
null
null
python/redengine.py
DubskySteam/Facharbeit_Schlitten
4ce8764a13ea41120b1b17f9f77d516aa958442b
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import tinkerforge import os import sys import math import time
12.428571
22
0.804598
64c2a8d445544ec9378b4ce1bd8ef90a4f884577
192
py
Python
exercises/zh/exc_01_08_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
2,085
2019-04-17T13:10:40.000Z
2022-03-30T21:51:46.000Z
exercises/zh/exc_01_08_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
79
2019-04-18T14:42:55.000Z
2022-03-07T08:15:43.000Z
exercises/zh/exc_01_08_02.py
Jette16/spacy-course
32df0c8f6192de6c9daba89740a28c0537e4d6a0
[ "MIT" ]
361
2019-04-17T13:34:32.000Z
2022-03-28T04:42:45.000Z
import spacy nlp = spacy.load("zh_core_web_sm") text = "写入历史了:苹果是美国第一家市值超过一万亿美元的上市公司。" # 处理文本 doc = ____ # 对识别出的实体进行遍历 for ent in ____.____: # 打印实体文本及标注 print(ent.____, ____.____)
13.714286
38
0.703125
64cb07f975fd7cee6091cd828bd81bd845457ce2
39,156
py
Python
Contrib-Microsoft/Olympus_rack_manager/python-ocs/commonapi/controls/server_health.py
opencomputeproject/Rack-Manager
e1a61d3eeeba0ff655fe9c1301e8b510d9b2122a
[ "MIT" ]
5
2019-11-11T07:57:26.000Z
2022-03-28T08:26:53.000Z
Contrib-Microsoft/Olympus_rack_manager/python-ocs/commonapi/controls/server_health.py
opencomputeproject/Rack-Manager
e1a61d3eeeba0ff655fe9c1301e8b510d9b2122a
[ "MIT" ]
3
2019-09-05T21:47:07.000Z
2019-09-17T18:10:45.000Z
Contrib-Microsoft/Olympus_rack_manager/python-ocs/commonapi/controls/server_health.py
opencomputeproject/Rack-Manager
e1a61d3eeeba0ff655fe9c1301e8b510d9b2122a
[ "MIT" ]
11
2019-07-20T00:16:32.000Z
2022-01-11T14:17:48.000Z
# Copyright (C) Microsoft Corporation. All rights reserved. # This program is free software; you can redistribute it # and/or modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. #!/usr/bin...
43.075908
134
0.517826
b382ad15202e6d1f8333e684f4ffd5247e6fccf7
1,658
py
Python
research/cv/STGAN/eval.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/cv/STGAN/eval.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/cv/STGAN/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...
34.541667
78
0.612183
b335e52a012fb8622b66b5023b129d0118cdc02f
922
py
Python
LeetCode_problems/kth-smallest-element-in-a-bst/Solution.py
gbrls/CompetitiveCode
b6f1b817a655635c3c843d40bd05793406fea9c6
[ "MIT" ]
165
2020-10-03T08:01:11.000Z
2022-03-31T02:42:08.000Z
LeetCode_problems/kth-smallest-element-in-a-bst/Solution.py
gbrls/CompetitiveCode
b6f1b817a655635c3c843d40bd05793406fea9c6
[ "MIT" ]
383
2020-10-03T07:39:11.000Z
2021-11-20T07:06:35.000Z
LeetCode_problems/kth-smallest-element-in-a-bst/Solution.py
gbrls/CompetitiveCode
b6f1b817a655635c3c843d40bd05793406fea9c6
[ "MIT" ]
380
2020-10-03T08:05:04.000Z
2022-03-19T06:56:59.000Z
# -*- coding: utf-8 -*- """ Created on Mon Oct 5 2020 @author: Shrey1608 """ # Approach :1) Recursive inorder traversal i.e first do a inorder traversal which is a method of Dfs and then just follow the recursion(Time complexity= O(N)(h is height of the tree) # It's a very straightforward approach with O(N)\mathcal{O...
38.416667
234
0.656182
2fdddc7d0dd81d8a5e9af91722fed8c0a3fc930b
6,443
py
Python
src/main/python/qxy/rename.py
gwdgithubnom/ox-patient
cddf4fe381cb4506db8e0d62803dd2044cf7ad92
[ "MIT" ]
null
null
null
src/main/python/qxy/rename.py
gwdgithubnom/ox-patient
cddf4fe381cb4506db8e0d62803dd2044cf7ad92
[ "MIT" ]
null
null
null
src/main/python/qxy/rename.py
gwdgithubnom/ox-patient
cddf4fe381cb4506db8e0d62803dd2044cf7ad92
[ "MIT" ]
1
2021-04-14T00:45:38.000Z
2021-04-14T00:45:38.000Z
import os import configparser from context import resource_manager from tools import file_manage def rename_dir(url,reverse=True): """ 用户给定文件夹的路径,如果给定路径存在,更改指定文件夹下的文件夹的名字 :param url: 用户给定的文件夹的路径 :param reverse: 如果reverse=True就进行反向命名,reverse=False就对所给文件夹所包含的文件夹进行重命名; :return: """ ...
33.041026
137
0.559056
4467b73c95d9b2c58955f1c54d33d5927feef2ce
510
py
Python
PINp/2014/Koleganov_N_S/task_3_10.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
PINp/2014/Koleganov_N_S/task_3_10.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
PINp/2014/Koleganov_N_S/task_3_10.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
# Задача 3. Вариант 10. # Напишите программу, которая выводит имя "Игорь Васильевич Лотарев", и # запрашивает его псевдоним. Программа должна сцеплять две эти строки и # выводить полученную строку, разделяя имя и псевдоним с помощью тире. # Колеганов Никита Сергеевич # 29.05.2012 name=input("Герой нашей программы - Иг...
42.5
109
0.768627
4476ba1bfd2fc1007b3f67456acc9f653ecc2fe3
650
py
Python
challenges/blackrock/audit_sale.py
PlamenHristov/HackerRank
2c875995f0d51d7026c5cf92348d9fb94fa509d6
[ "MIT" ]
null
null
null
challenges/blackrock/audit_sale.py
PlamenHristov/HackerRank
2c875995f0d51d7026c5cf92348d9fb94fa509d6
[ "MIT" ]
null
null
null
challenges/blackrock/audit_sale.py
PlamenHristov/HackerRank
2c875995f0d51d7026c5cf92348d9fb94fa509d6
[ "MIT" ]
null
null
null
def sale(securities, M, K): sorted_sec = sorted(securities, key=lambda x: x[0] * x[1], reverse=True) res = 0 for i in range(M): if K > 0: x, _ = sorted_sec[i] y = 1 else: x, y = sorted_sec[i] K -= 1 res += x * y print(res) # N, M...
19.69697
76
0.463077
92547dfdd13037b67a68166a90b4115762bfd97f
453
py
Python
books/PythonAutomate/excel_spreadsheets/cell_inverter.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
books/PythonAutomate/excel_spreadsheets/cell_inverter.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
books/PythonAutomate/excel_spreadsheets/cell_inverter.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
"""cell_inverter.py 스프레드시트 셀 반전시키기 """ import sys import openpyxl if len(sys.argv) != 2: print(f"python {__file__} <*.xlsx>") sys.exit(1) file_name = sys.argv[1] wb = openpyxl.load_workbook(file_name) sheet = wb.active new_wb = openpyxl.Workbook() new_sheet = new_wb.active for row_obj in sheet.rows: fo...
18.875
75
0.704194
f380ec6d4ec28c12552bb7c4cc31a51a27dcbed1
789
py
Python
udacity course code/01-06-plottwohistograms.py
bluemurder/mlfl
b895b2f1d01b0f6418a5bcee2f204dd7916062f0
[ "MIT" ]
1
2021-03-22T22:25:54.000Z
2021-03-22T22:25:54.000Z
udacity course code/01-06-plottwohistograms.py
bluemurder/mlfl
b895b2f1d01b0f6418a5bcee2f204dd7916062f0
[ "MIT" ]
6
2017-01-16T09:53:21.000Z
2017-01-18T12:20:09.000Z
udacity course code/01-06-plottwohistograms.py
bluemurder/mlfl
b895b2f1d01b0f6418a5bcee2f204dd7916062f0
[ "MIT" ]
null
null
null
"""Plot a couple of histogram.""" import pandas as pd import matplotlib.pyplot as plt from util import get_data, plot_data, compute_daily_returns def test_run(): # Read data dates = pd.date_range('2009-01-01', '2012-12-31') # date range as index symbols = ['SPY','XOM'] df = get_data(symbols, dates) ...
30.346154
80
0.671736
946b4c33baf96dd37d1d32b582a875e2a52db092
3,140
py
Python
src/deal_features.py
Times125/Emotion-Analyse
b5d9f23fdf6c75f57f5cf20d58834a095b0c7e1e
[ "Apache-2.0" ]
11
2018-01-16T06:39:00.000Z
2021-11-28T11:46:41.000Z
src/deal_features.py
Times125/Emotion-Analyse
b5d9f23fdf6c75f57f5cf20d58834a095b0c7e1e
[ "Apache-2.0" ]
null
null
null
src/deal_features.py
Times125/Emotion-Analyse
b5d9f23fdf6c75f57f5cf20d58834a095b0c7e1e
[ "Apache-2.0" ]
2
2019-08-16T14:53:37.000Z
2019-08-17T02:01:22.000Z
#! /usr/bin/env python # -*- coding: utf-8 -*- """ @Author:lch02 @Time: 2017/12/26 9:51 @Description: """ import itertools import os import pickle import config from nltk.collocations import BigramCollocationFinder from nltk.metrics import BigramAssocMeasures from config import test_path from nltk.probability import...
33.404255
130
0.70414
0474aff44e74e67aa3b8adf050d40e168b3d908a
960
py
Python
kiosk/migrations/0007_kontakt_nachricht.py
AndiBr/ffksk
ff4bc4ad26d4571eaa1a6ff815b2e6a876f8ba99
[ "MIT" ]
null
null
null
kiosk/migrations/0007_kontakt_nachricht.py
AndiBr/ffksk
ff4bc4ad26d4571eaa1a6ff815b2e6a876f8ba99
[ "MIT" ]
14
2018-09-12T06:59:55.000Z
2020-02-26T07:17:48.000Z
kiosk/migrations/0007_kontakt_nachricht.py
AndiBr/ffksk
ff4bc4ad26d4571eaa1a6ff815b2e6a876f8ba99
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.11 on 2018-06-17 23:47 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('kiosk', '0006_produktpalette_imverkauf'), ] operations = [ migrations.CreateM...
34.285714
114
0.601042
1ee361bc5f016feba4576a04b68aff16068863af
6,200
py
Python
components/py_engine/adapter/esp32/m5stackcore2/lib/i2c_bus.py
wstong999/AliOS-Things
6554769cb5b797e28a30a4aa89b3f4cb2ef2f5d9
[ "Apache-2.0" ]
null
null
null
components/py_engine/adapter/esp32/m5stackcore2/lib/i2c_bus.py
wstong999/AliOS-Things
6554769cb5b797e28a30a4aa89b3f4cb2ef2f5d9
[ "Apache-2.0" ]
null
null
null
components/py_engine/adapter/esp32/m5stackcore2/lib/i2c_bus.py
wstong999/AliOS-Things
6554769cb5b797e28a30a4aa89b3f4cb2ef2f5d9
[ "Apache-2.0" ]
null
null
null
from machine import I2C from machine import Pin from micropython import const import struct #import unit #PORTA = (unit.PORTA) PAHUB0 = (0, None) PAHUB1 = (1, None) PAHUB2 = (2, None) PAHUB3 = (3, None) PAHUB4 = (4, None) PAHUB5 = (5, None) M_BUS = (21, 22) UINT8LE = const((0 << 6) | (1 << 4) | 1) UINT16LE = const(...
31.313131
83
0.597742
78b630f6accb702a9583ce0777f4bb8ab85a5834
502
py
Python
hrp.py
banachtech/hrp
b3ce4f3f35973e808eaea8a1f8b42c98ac691364
[ "MIT" ]
null
null
null
hrp.py
banachtech/hrp
b3ce4f3f35973e808eaea8a1f8b42c98ac691364
[ "MIT" ]
null
null
null
hrp.py
banachtech/hrp
b3ce4f3f35973e808eaea8a1f8b42c98ac691364
[ "MIT" ]
null
null
null
import argparse, numpy as np, pandas as pd from hrputils import calchrp my_parser = argparse.ArgumentParser() my_parser.add_argument('-i', help='input csv file with returns', required=True) my_parser.add_argument('-o', help='output csv file with hrp weights, defaults to weights.csv in the same folder', default='w...
41.833333
137
0.733068
78cc7d959318c6e14d17c6fd8da823301d5d9bd5
8,063
py
Python
Webpage/Django/settings.py
ASV-Aachen/Website
bbfc02d71dde67fdf89a4b819b795a73435da7cf
[ "Apache-2.0" ]
null
null
null
Webpage/Django/settings.py
ASV-Aachen/Website
bbfc02d71dde67fdf89a4b819b795a73435da7cf
[ "Apache-2.0" ]
46
2022-01-08T12:03:24.000Z
2022-03-30T08:51:05.000Z
Webpage/Django/settings.py
ASV-Aachen/Website
bbfc02d71dde67fdf89a4b819b795a73435da7cf
[ "Apache-2.0" ]
null
null
null
""" Django settings for Django project. Generated by 'django-admin startproject' using Django 3.1.4. For more information on this file, see https://docs.djangoproject.com/en/3.1/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/3.1/ref/settings/ """ import os from...
30.541667
118
0.690562
bf1c0ecd66d57162de1744dc7f1f0072c469a461
1,522
py
Python
official/recommend/tbnet/src/config.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
official/recommend/tbnet/src/config.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
official/recommend/tbnet/src/config.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...
38.05
78
0.659001
17214237c66cedce9feb050af3a6e63dea6a0917
164
py
Python
book/_build/jupyter_execute/docs/000_intro.py
tom-tubeless/Biologie
44660ea21971d4b3d77118606bfe1264993465fc
[ "MIT" ]
null
null
null
book/_build/jupyter_execute/docs/000_intro.py
tom-tubeless/Biologie
44660ea21971d4b3d77118606bfe1264993465fc
[ "MIT" ]
null
null
null
book/_build/jupyter_execute/docs/000_intro.py
tom-tubeless/Biologie
44660ea21971d4b3d77118606bfe1264993465fc
[ "MIT" ]
null
null
null
#!/usr/bin/env python # coding: utf-8 # # Bio am WWG # # Unterrichtsplanung, -inhalte und -materialien für das Fach Biologie am Wim-Wenders-Gymnasium Düsseldorf.
23.428571
106
0.737805
da849c9b8364c41265b972fc16018f755fffa237
1,115
py
Python
python_reference/useful_scripts/conc_gzip_files.py
gopala-kr/ds-notebooks
bc35430ecdd851f2ceab8f2437eec4d77cb59423
[ "MIT" ]
1
2019-05-10T09:16:23.000Z
2019-05-10T09:16:23.000Z
python_reference/useful_scripts/conc_gzip_files.py
gopala-kr/ds-notebooks
bc35430ecdd851f2ceab8f2437eec4d77cb59423
[ "MIT" ]
null
null
null
python_reference/useful_scripts/conc_gzip_files.py
gopala-kr/ds-notebooks
bc35430ecdd851f2ceab8f2437eec4d77cb59423
[ "MIT" ]
1
2019-10-14T07:30:18.000Z
2019-10-14T07:30:18.000Z
# Sebastian Raschka 03/2014 import gzip import shutil import os #import pyprind def conc_gzip_files(in_dir, out_file, append=False, print_progress=True): """ Reads contents from gzipped ASCII or UTF-8 files, decodes them, and appends the lines to one output file. Keyword arguments: in_dir (s...
32.794118
86
0.639462
e52b8445bb0424f37bdedb3f32cfe011304969e5
2,819
py
Python
RSS/model/rssfeed.py
dereklm12880/rssticker
d90e8c00811d67bd9fb8104bbb6ec98aae5221f4
[ "MIT" ]
2
2020-02-26T01:54:26.000Z
2020-04-27T20:09:14.000Z
RSS/model/rssfeed.py
dereklm12880/rssticker
d90e8c00811d67bd9fb8104bbb6ec98aae5221f4
[ "MIT" ]
17
2020-02-29T02:43:44.000Z
2020-04-27T20:38:44.000Z
RSS/model/rssfeed.py
dereklm12880/rssticker
d90e8c00811d67bd9fb8104bbb6ec98aae5221f4
[ "MIT" ]
8
2020-02-26T21:37:36.000Z
2020-06-23T00:01:27.000Z
# method for rss links import feedparser class RssModel: """ Class model.rssfeeds.RssModel. This class parses the feeds that are given and returns them in an an empty list. """ _newsreel_index_pos = -1 _raw_feed = '' given_url = '' title = '' subtitle = '' link = '' newsreel ...
39.152778
161
0.644555
00aa38d98e9f0a6d64f535591ec7a7ee59a6c658
909
py
Python
3kCTF/2021/pwn/klibrary/upload.py
ruhan-islam/ctf-archives
8c2bf6a608c821314d1a1cfaa05a6cccef8e3103
[ "MIT" ]
1
2021-11-02T20:53:58.000Z
2021-11-02T20:53:58.000Z
3kCTF/2021/pwn/klibrary/upload.py
ruhan-islam/ctf-archives
8c2bf6a608c821314d1a1cfaa05a6cccef8e3103
[ "MIT" ]
null
null
null
3kCTF/2021/pwn/klibrary/upload.py
ruhan-islam/ctf-archives
8c2bf6a608c821314d1a1cfaa05a6cccef8e3103
[ "MIT" ]
null
null
null
#!/usr/bin/python3.8 from pwn import * EXPLOIT_PATH = '/tmp/exploit' SERVER = 178.62.107.48 PORT = 9994 SHELL_PROMPT = '$ ' def get_splitted_encoded_exploit(): split_every = 256 # Change the name to your exploit path with open('exploit', 'rb') as exploit_file: exploit = base64.b64encode(explo...
25.971429
89
0.685369
dae43870e767daf4c1ff60a5ad5c986861b3a2d3
387
py
Python
INBa/2015/Serdechnaya_A_M/task_3_25.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
INBa/2015/Serdechnaya_A_M/task_3_25.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
INBa/2015/Serdechnaya_A_M/task_3_25.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
#Напишите программу, которая выводит имя "Алессандро Филипели", и запрашивает его псевдоним. #Программа должна сцеплять две эти строки и выводить полученную строку, разделяя имя и псевдоним с помощью тире. print("Введите псевдоним Алессандро ди Мариано ди Ванни Филипепи:") nick=input() print("Алессандро ди Мариано ди ...
64.5
112
0.801034
9718fa3aadd8b98177539d83b1aae2caac12a8ad
10,305
py
Python
research/cv/Auto-DeepLab/src/modules/operations.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
research/cv/Auto-DeepLab/src/modules/operations.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
research/cv/Auto-DeepLab/src/modules/operations.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.61039
191
0.56099
e7bd79478548a190e02ee4d47c9aae64bbe087a3
602
py
Python
___Python/Thomas/pycurs_180625/p02_datenstrukturen/m03_anwendung_woerterbuch.py
uvenil/PythonKurs201806
85afa9c9515f5dd8bec0c546f077d8cc39568fe8
[ "Apache-2.0" ]
null
null
null
___Python/Thomas/pycurs_180625/p02_datenstrukturen/m03_anwendung_woerterbuch.py
uvenil/PythonKurs201806
85afa9c9515f5dd8bec0c546f077d8cc39568fe8
[ "Apache-2.0" ]
null
null
null
___Python/Thomas/pycurs_180625/p02_datenstrukturen/m03_anwendung_woerterbuch.py
uvenil/PythonKurs201806
85afa9c9515f5dd8bec0c546f077d8cc39568fe8
[ "Apache-2.0" ]
null
null
null
satz = "Fischers Fritze fischt frische Fische" # Häufigkeit Buchstabe e # 1. Ansatz: for-schleife und Zähler zaehler = 0 for zeichen in satz: if zeichen == "e": zaehler += 1 print (zaehler) # Häufigkeit der Buchstaben im Satz dic_m03 = {} for zeichen in satz: if zeichen in dic_m03: ...
25.083333
76
0.657807
4134a9ed6605204696d1b0f3389d20bef0dbe091
71
py
Python
20-hs-redez-sem/groups/05-decentGames/src/State.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/State.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/State.py
Kyrus1999/BACnet
5be8e1377252166041bcd0b066cce5b92b077d06
[ "MIT" ]
25
2020-03-20T09:32:45.000Z
2021-07-18T18:12:59.000Z
FF = 'ff' ONGOING = 'normal' FINISHED = 'finished' CHEATED = 'cheated'
14.2
21
0.661972
68c2134237499d3dac238e74c6255f6a3006f781
92
py
Python
2015/03/poll-health-parents-20150302/graphic_config.py
nprapps/graphics-archive
97b0ef326b46a959df930f5522d325e537f7a655
[ "FSFAP" ]
14
2015-05-08T13:41:51.000Z
2021-02-24T12:34:55.000Z
2015/03/poll-health-control-20150302/graphic_config.py
nprapps/graphics-archive
97b0ef326b46a959df930f5522d325e537f7a655
[ "FSFAP" ]
null
null
null
2015/03/poll-health-control-20150302/graphic_config.py
nprapps/graphics-archive
97b0ef326b46a959df930f5522d325e537f7a655
[ "FSFAP" ]
7
2015-04-04T04:45:54.000Z
2021-02-18T11:12:48.000Z
#!/usr/bin/env python COPY_GOOGLE_DOC_KEY = '1bHsaAin7zYrB-hasOXuZolTM7DwAhn4degtdhVhsO9c'
23
68
0.836957
68eb4e700b71b99f2891692fbb6e5c832dd9ef33
985
py
Python
Problems/Depth-First Search/easy/UnivaluedBinaryTree/univalued_binary_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/UnivaluedBinaryTree/univalued_binary_tree.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
Problems/Depth-First Search/easy/UnivaluedBinaryTree/univalued_binary_tree.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
# Definition for a binary tree node. class TreeNode: def __init__(self, val=0, left=None, right=None): self.val = val self.left = left self.right = right # Recursive def isUnivalTree(root: TreeNode) -> bool: def compare_value(cur_root: TreeNode, previous_root: int) -> bool: if n...
29.848485
105
0.616244
6bd5a409455fe5863f8fd48fa075c30b28979376
4,429
py
Python
insert_tables.py
arwhyte/gffa-db
20410ab00c9f86a1bf7ca85ebdbaa9535b106c59
[ "BSD-3-Clause" ]
null
null
null
insert_tables.py
arwhyte/gffa-db
20410ab00c9f86a1bf7ca85ebdbaa9535b106c59
[ "BSD-3-Clause" ]
null
null
null
insert_tables.py
arwhyte/gffa-db
20410ab00c9f86a1bf7ca85ebdbaa9535b106c59
[ "BSD-3-Clause" ]
null
null
null
import requests import json import psycopg2 def read_json(filepath, encoding='utf-8'): """Reads a JSON document, decodes the file content, and returns a dictionary if provided with a valid filepath. Parameters: filepath (str): path to file Returns: dict: dict representations of the de...
39.19469
307
0.644389
6bd8266adc81cedfdafbd1545c80a2bbca9cae23
11,463
py
Python
Packs/PaloAltoNetworks_IoT3rdParty/Scripts/SendAllPANWIoTDevicesToCiscoISE/SendAllPANWIoTDevicesToCiscoISE.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/PaloAltoNetworks_IoT3rdParty/Scripts/SendAllPANWIoTDevicesToCiscoISE/SendAllPANWIoTDevicesToCiscoISE.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/PaloAltoNetworks_IoT3rdParty/Scripts/SendAllPANWIoTDevicesToCiscoISE/SendAllPANWIoTDevicesToCiscoISE.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
import demistomock as demisto # noqa: F401 from CommonServerPython import * # noqa: F401 PANW_IOT_INSTANCE = demisto.args().get('panw_iot_3rd_party_instance') CISCO_ISE_ACTIVE_INSTANCE = demisto.args().get("active_ise_instance") GET_EP_ID_CMD = 'cisco-ise-get-endpoint-id-by-name' CISCO_ISE_FIELD_MAP = { "ip": [...
38.989796
108
0.651226
6bfc67542b8061cb0974af1ae7c6a732f07ff2ec
290
py
Python
src/python/py-accepted/231A.py
cbarnson/UVa
0dd73fae656613e28b5aaf5880c5dad529316270
[ "Unlicense", "MIT" ]
2
2019-09-07T17:00:26.000Z
2020-08-05T02:08:35.000Z
src/python/py-accepted/231A.py
cbarnson/UVa
0dd73fae656613e28b5aaf5880c5dad529316270
[ "Unlicense", "MIT" ]
null
null
null
src/python/py-accepted/231A.py
cbarnson/UVa
0dd73fae656613e28b5aaf5880c5dad529316270
[ "Unlicense", "MIT" ]
null
null
null
#! python # Problem # : 231A # Created on : 2019-01-14 21:19:31 def Main(): n = int(input()) cnt = 0 for i in range(0, n): if sum(list(map(int, input().split(' ')))) > 1: cnt += 1 else: print(cnt) if __name__ == '__main__': Main()
15.263158
56
0.472414
d442d4ebcfe5532e7387c7a3bf2893c827baa1c9
79
py
Python
examples/miniportal/portal/actors/system/usermanager/listUsers.py
Jumpscale/web
8e8ec2ce01f3105c7647ee8a0c90af09311cbbeb
[ "Apache-2.0" ]
1
2015-10-26T10:38:32.000Z
2015-10-26T10:38:32.000Z
examples/miniportal/portal/actors/system/usermanager/listUsers.py
Jumpscale/web
8e8ec2ce01f3105c7647ee8a0c90af09311cbbeb
[ "Apache-2.0" ]
null
null
null
examples/miniportal/portal/actors/system/usermanager/listUsers.py
Jumpscale/web
8e8ec2ce01f3105c7647ee8a0c90af09311cbbeb
[ "Apache-2.0" ]
null
null
null
def listUsers(actors, name='azmy', age=20): raise NotImplementedError()
15.8
43
0.696203
d477f19fface70fc19c62f57f3984f053cd44963
6,824
py
Python
lbry/tests/integration/test_comment_commands.py
Nykseli/lbry-sdk
07afc0aa0a1e6c0ef6aa284fb47513af940440c1
[ "MIT" ]
null
null
null
lbry/tests/integration/test_comment_commands.py
Nykseli/lbry-sdk
07afc0aa0a1e6c0ef6aa284fb47513af940440c1
[ "MIT" ]
4
2020-10-27T21:53:05.000Z
2022-02-11T03:10:54.000Z
lbry/tests/integration/test_comment_commands.py
braveheart12/lbry-sdk
dc709b468f9dce60d206161785def5c7ace2b763
[ "MIT" ]
null
null
null
from math import ceil from aiohttp import web from lbry.testcase import CommandTestCase class MockedCommentServer: ERRORS = { 'INVALID_PARAMS': {'code': -32602, 'message': 'Invalid parameters'}, 'INTERNAL': {'code': -32603, 'message': 'An internal error'}, 'UNKNOWN': {'code': -1, 'messa...
38.772727
103
0.608587
2e06dfe9bc67684bd6217157e61a6a60afe366d2
9,265
py
Python
encoder.py
FinlayDaG33k/HBC
e8aa7ae6b6d8af758f15613ab2aaf6cb276e4cd9
[ "MIT" ]
1
2016-06-15T07:22:14.000Z
2016-06-15T07:22:14.000Z
encoder.py
FinlayDaG33k/HBC
e8aa7ae6b6d8af758f15613ab2aaf6cb276e4cd9
[ "MIT" ]
null
null
null
encoder.py
FinlayDaG33k/HBC
e8aa7ae6b6d8af758f15613ab2aaf6cb276e4cd9
[ "MIT" ]
null
null
null
#!/usr/bin/python """ HBC by FinlayDaG33k under the MIT License """ import Pyro4 import os import platform import re import logging from threading import Timer import subprocess from encoder_cfg import pyro_host, pyro_port, ftp_host, ftp_port, ftp_user, ftp_pass from encoder_cfg import IDLE, RUNNING, Task, getLanIP fro...
39.594017
132
0.581651
cf2ff7ebdead2953f99d3d442c16b6dc10c7c9a3
763
py
Python
Utils/py/ActionSelection/evaluation/decision_histogram_plot.py
tarsoly/NaoTH
dcd2b67ef6bf9953c81d3e1b26e543b5922b7d52
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
Utils/py/ActionSelection/evaluation/decision_histogram_plot.py
tarsoly/NaoTH
dcd2b67ef6bf9953c81d3e1b26e543b5922b7d52
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
Utils/py/ActionSelection/evaluation/decision_histogram_plot.py
tarsoly/NaoTH
dcd2b67ef6bf9953c81d3e1b26e543b5922b7d52
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
from __future__ import division from matplotlib import pyplot as plt import numpy as np import pickle """ Shows a bar plot of the decision histogram for one robot position on the field Example: run without any parameters $ python decision_histogram_plot.py """ # Set file for importing the decisions deci...
23.84375
89
0.730013
cf5813108f9b2605e07af83b9ad4c455d9ff95f7
269
py
Python
python/primary/模块/print_tuple.py
EstherLacan/jiangfw
a449b1925742873c76dc1b3284aedb359204bc76
[ "Apache-2.0" ]
1
2020-07-29T16:43:46.000Z
2020-07-29T16:43:46.000Z
python/primary/模块/print_tuple.py
EstherLacan/jiangfw
a449b1925742873c76dc1b3284aedb359204bc76
[ "Apache-2.0" ]
null
null
null
python/primary/模块/print_tuple.py
EstherLacan/jiangfw
a449b1925742873c76dc1b3284aedb359204bc76
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python # Filename: print_tuple.py age = 22 myempty = () print(len(myempty)) a1 = ('aa',) print(len(a1)) a2 = ('abcd') print(len(a2),a2[3]) name = ('Swaroop') print ('%s is %d years old' % (name, age)) print ('Why is %s playing with that python?' % name)
15.823529
52
0.609665
d8717a6e1bcee1ad4312e5038dbf93c9db29dff4
1,439
py
Python
kollokationsprofile_daten/10Words/dfcp/w_element/wele_dass/kollokation_Wphrase_pr.py
ovanov/Kollokationsprofile-von-DFCP
4d45410a4f0b1e692f18da965d51d9a8e5eb7a08
[ "MIT" ]
null
null
null
kollokationsprofile_daten/10Words/dfcp/w_element/wele_dass/kollokation_Wphrase_pr.py
ovanov/Kollokationsprofile-von-DFCP
4d45410a4f0b1e692f18da965d51d9a8e5eb7a08
[ "MIT" ]
null
null
null
kollokationsprofile_daten/10Words/dfcp/w_element/wele_dass/kollokation_Wphrase_pr.py
ovanov/Kollokationsprofile-von-DFCP
4d45410a4f0b1e692f18da965d51d9a8e5eb7a08
[ "MIT" ]
null
null
null
import re from typing import Dict, List import pandas as pd from pandas.core.frame import DataFrame def preprocess_text(filename: str) -> List: listed_words = [] with open(filename, 'r') as annis: for line in annis: if re.search(r"\d+\.\t", line) != None: line = re.sub(r...
26.648148
71
0.607366
2b04b1016a2aba0152c37007fd02c2cd7f107c4b
3,758
py
Python
mongodb/mongodb_consistent_backup/official/mongodb_consistent_backup/Upload/Gs/GsUploadThread.py
smthkissinger/docker-images
35e868295d04fa780325ada4168381f1e80e8fe4
[ "BSD-3-Clause" ]
282
2016-06-16T14:41:44.000Z
2022-03-02T03:43:02.000Z
mongodb/mongodb_consistent_backup/official/mongodb_consistent_backup/Upload/Gs/GsUploadThread.py
smthkissinger/docker-images
35e868295d04fa780325ada4168381f1e80e8fe4
[ "BSD-3-Clause" ]
146
2016-06-16T08:55:45.000Z
2020-09-08T10:37:32.000Z
mongodb/mongodb_consistent_backup/official/mongodb_consistent_backup/Upload/Gs/GsUploadThread.py
smthkissinger/docker-images
35e868295d04fa780325ada4168381f1e80e8fe4
[ "BSD-3-Clause" ]
94
2016-06-16T10:49:07.000Z
2022-03-28T09:14:03.000Z
import boto import logging import os from mongodb_consistent_backup.Common.Util import file_md5hash from mongodb_consistent_backup.Errors import OperationError class GsUploadThread: def __init__(self, backup_dir, file_path, gs_path, bucket, project_id, access_key, secret_key, remove_uploaded=False, retries=5): ...
39.145833
133
0.567855
510824956a099e0817d4a9c182b2014c3bfb0912
703
py
Python
Hello coding/selection_sort.py
wooooooogi/SAlgorithm
bf76bb721785a52b6abf158077b554b0626ee1f7
[ "MIT" ]
null
null
null
Hello coding/selection_sort.py
wooooooogi/SAlgorithm
bf76bb721785a52b6abf158077b554b0626ee1f7
[ "MIT" ]
null
null
null
Hello coding/selection_sort.py
wooooooogi/SAlgorithm
bf76bb721785a52b6abf158077b554b0626ee1f7
[ "MIT" ]
null
null
null
# Coded by Sungwook Kim # Date: 2019-07-30 # Python version: 3.6.5 # IDE: Spyder 3 # Sort, information = [Name, Date, E-mail] # Sample code is 2001 year's 메리츠화재 stock information. (Downloaded in KRX) # Sort by price (When is the highest price in 2001) import pandas as pd import numpy as np import os #...
21.96875
102
0.655761
64df9e124b4938a55fed62588a4f3ce6a5e14d05
463
py
Python
zencad/examples/1.GeomPrim/3.prim1d/polysegment.py
Spiritdude/zencad
4e63b1a6306dd235f4daa2791b10249f7546c95b
[ "MIT" ]
5
2018-04-11T14:11:40.000Z
2018-09-12T19:03:36.000Z
zencad/examples/1.GeomPrim/3.prim1d/polysegment.py
Spiritdude/zencad
4e63b1a6306dd235f4daa2791b10249f7546c95b
[ "MIT" ]
null
null
null
zencad/examples/1.GeomPrim/3.prim1d/polysegment.py
Spiritdude/zencad
4e63b1a6306dd235f4daa2791b10249f7546c95b
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 """ ZenCad API example: polysegment.py """ from zencad import * pnts = points([(0, 0, 0), (0, 10, 10), (0, 10, 20), (0, -10, 20), (0, -10, 10)]) m0 = polysegment(pnts) m1 = polysegment(pnts, closed=True) m2 = polysegment(pnts, closed=True).fill() m3 = polysegment(pnts + [(0, 0, 0)]) m4 = poly...
19.291667
80
0.611231
8559713c3ce95f2a2f0024ef72dddcb77d47aa41
4,596
py
Python
datastories_semeval2017_task4/utilities_nn/data_loader.py
florianfricke/Bachelor_Thesis_Sentiment_Analyse
aa1fa95cfbc13115ee60baaf79eab0d1940998ab
[ "MIT" ]
1
2020-06-04T13:20:45.000Z
2020-06-04T13:20:45.000Z
datastories_semeval2017_task4/utilities_nn/data_loader.py
florianfricke/Bachelor_Thesis_Sentiment_Analyse
aa1fa95cfbc13115ee60baaf79eab0d1940998ab
[ "MIT" ]
6
2020-06-03T18:45:11.000Z
2022-02-10T01:51:03.000Z
datastories_semeval2017_task4/utilities_nn/data_loader.py
florianfricke/Bachelor_Thesis_Sentiment_Analyse
aa1fa95cfbc13115ee60baaf79eab0d1940998ab
[ "MIT" ]
null
null
null
""" Created by Christos Baziotis. """ import random import pickle import numpy from ekphrasis.classes.preprocessor import TextPreProcessor from ekphrasis.classes.tokenizer import SocialTokenizer from ekphrasis.dicts.emoticons import emoticons from kutilities.helpers.data_preparation import print_dataset_statistics, \ ...
40.672566
123
0.58812
740ff96b7d1bf1f591bf1f5059c0aa00bbee743c
449
py
Python
api/models/library.py
aidun/seite50
761a8e76f9e4473f70a8705dce169d61bf660267
[ "Apache-2.0" ]
null
null
null
api/models/library.py
aidun/seite50
761a8e76f9e4473f70a8705dce169d61bf660267
[ "Apache-2.0" ]
2
2018-05-11T18:26:18.000Z
2018-05-12T18:49:38.000Z
api/models/library.py
aidun/seite50
761a8e76f9e4473f70a8705dce169d61bf660267
[ "Apache-2.0" ]
1
2018-10-10T19:52:17.000Z
2018-10-10T19:52:17.000Z
from django.db import models from api.models.user import User # Create your models here. class Library(models.Model): id = models.AutoField(primary_key=True) name = models.CharField(max_length=255, blank=False, unique=True) owner = models.ManyToManyField(User, related_name="organized_by", blank=False) ...
29.933333
82
0.759465
744976428a3f9d0b93a5bf2aee0bfc9497a2c2d3
661
py
Python
Codeforces_problems/Merge It A/solution.py
KAHund/CompetitiveCode
6ed211a2f795569f5c2f18c2f660520d99d41ca0
[ "MIT" ]
165
2020-10-03T08:01:11.000Z
2022-03-31T02:42:08.000Z
Codeforces_problems/Merge It A/solution.py
KAHund/CompetitiveCode
6ed211a2f795569f5c2f18c2f660520d99d41ca0
[ "MIT" ]
383
2020-10-03T07:39:11.000Z
2021-11-20T07:06:35.000Z
Codeforces_problems/Merge It A/solution.py
KAHund/CompetitiveCode
6ed211a2f795569f5c2f18c2f660520d99d41ca0
[ "MIT" ]
380
2020-10-03T08:05:04.000Z
2022-03-19T06:56:59.000Z
# We can check the divisibility by 3 by taking the sum of digits. # If remainder is 0, we consider it as it is. If remainder is 1 or 2 we can combine them greedily. # We can then combine 3 numbers each with remainder 1 or 2. def sum_of(n): s = 0 num = n while(num>0): s+=num%10 num = num//10 return s for i in r...
20.65625
98
0.606657
7af4d8f7d4503155cd03cb13845759a7cfd88c78
8,705
py
Python
backend/apps/ineedstudent/views.py
n-hackert/match4healthcare
761248c27b49e568c545c643a72eac9a040649d7
[ "MIT" ]
null
null
null
backend/apps/ineedstudent/views.py
n-hackert/match4healthcare
761248c27b49e568c545c643a72eac9a040649d7
[ "MIT" ]
null
null
null
backend/apps/ineedstudent/views.py
n-hackert/match4healthcare
761248c27b49e568c545c643a72eac9a040649d7
[ "MIT" ]
null
null
null
from django.shortcuts import render from django.template import loader from django.http import HttpResponse from apps.mapview.utils import plzs from apps.iamstudent.models import Student from apps.ineedstudent.models import Hospital from apps.ineedstudent.forms import HospitalForm, EmailToHospitalForm from django.util...
36.729958
172
0.673406
3b12472f1b51fd437b3679375bdf34ea708ea5eb
501
py
Python
Packs/CommonScripts/Scripts/PrintRaw/PrintRaw_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/CommonScripts/Scripts/PrintRaw/PrintRaw_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/CommonScripts/Scripts/PrintRaw/PrintRaw_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
import demistomock as demisto def test_main(mocker): from PrintRaw import main # test custom fields with short names mocker.patch.object(demisto, 'args', return_value={ 'value': '\tthat was a tab \n\n\nthree newlines\tafter another tab\n' }) mocker.patch.object(demisto, 'results') ma...
31.3125
86
0.684631
797dfd4217090df93567748343aab39dd6b56778
18,619
py
Python
event_detector/gttm/cluster_detection/cluster_handler.py
MahdiFarnaghi/gtm
adbec372786262607291f901a444a0ebe9e98b48
[ "Apache-2.0" ]
null
null
null
event_detector/gttm/cluster_detection/cluster_handler.py
MahdiFarnaghi/gtm
adbec372786262607291f901a444a0ebe9e98b48
[ "Apache-2.0" ]
null
null
null
event_detector/gttm/cluster_detection/cluster_handler.py
MahdiFarnaghi/gtm
adbec372786262607291f901a444a0ebe9e98b48
[ "Apache-2.0" ]
null
null
null
import os from datetime import datetime from pathlib import Path from pprint import pprint import sys from sklearn.cluster import DBSCAN import geopandas as gp import pandas as pd import numpy as np # from sklearn.cluster.optics_ import OPTICS from sklearn.feature_extraction.text import TfidfVectorizer, CountVectoriz...
44.436754
122
0.628068
691c70b9c8ade9bcf9dcf6c0ca515e1e5dcee5f1
6,419
py
Python
hardware/seat_cam/pixy_build/libpixyusb_swig/pixy.py
BlueHC/TTHack-2018--Easy-Rider-1
8cd8f66de88ff80751a1083350c38985ac26914d
[ "Apache-2.0" ]
null
null
null
hardware/seat_cam/pixy_build/libpixyusb_swig/pixy.py
BlueHC/TTHack-2018--Easy-Rider-1
8cd8f66de88ff80751a1083350c38985ac26914d
[ "Apache-2.0" ]
null
null
null
hardware/seat_cam/pixy_build/libpixyusb_swig/pixy.py
BlueHC/TTHack-2018--Easy-Rider-1
8cd8f66de88ff80751a1083350c38985ac26914d
[ "Apache-2.0" ]
null
null
null
# This file was automatically generated by SWIG (http://www.swig.org). # Version 3.0.10 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. from sys import version_info as _swig_python_version_info if _swig_python_version_info >= (2, 7, 0): def swi...
32.583756
91
0.687646
d6b64253d098b09f24aab1942d7750af45aec81b
645
py
Python
plan/urls.py
MIXISAMA/MIS-backend
7aaa1be773718de1beb3ce0080edca7c4114b7ad
[ "MIT" ]
null
null
null
plan/urls.py
MIXISAMA/MIS-backend
7aaa1be773718de1beb3ce0080edca7c4114b7ad
[ "MIT" ]
null
null
null
plan/urls.py
MIXISAMA/MIS-backend
7aaa1be773718de1beb3ce0080edca7c4114b7ad
[ "MIT" ]
2
2020-04-20T07:26:51.000Z
2020-04-30T11:51:54.000Z
from django.urls import path from plan.views import Requirements, RoughRequirements, DetailedRequirements from plan.views import OfferingCourses, FieldsOfStudy, IndicatorFactors from plan.views import BasisTemplates urlpatterns = [ path("requirements/", Requirements.as_view()), path("rough_requirements/", Roug...
43
76
0.770543
03180b1651d96ec104a136171bca2a414505b752
920
py
Python
python/mymail.py
EstherLacan/jiangfw
a449b1925742873c76dc1b3284aedb359204bc76
[ "Apache-2.0" ]
1
2020-07-29T16:43:46.000Z
2020-07-29T16:43:46.000Z
python/mymail.py
EstherLacan/jiangfw
a449b1925742873c76dc1b3284aedb359204bc76
[ "Apache-2.0" ]
null
null
null
python/mymail.py
EstherLacan/jiangfw
a449b1925742873c76dc1b3284aedb359204bc76
[ "Apache-2.0" ]
null
null
null
# coding:utf-8 from smtplib import SMTP from email.header import Header from email.mime.text import MIMEText from email.mime.multipart import MIMEMultipart import os def myMail(from_email,passwd,to_email,project,content): SMTPSVR = SMTP('smtp.exmail.qq.com') to = ','.join(to_email) msg = MIMEMultipart('al...
29.677419
64
0.686957
03187b4948b19bec012b3e0e5d648fdc7537ae5b
825
py
Python
Python/Sonstige_Uebungen/fractal_like/penta_fractal_turtle.py
Apop85/Scripts
1d8dad316c55e1f1343526eac9e4b3d0909e4873
[ "MIT" ]
null
null
null
Python/Sonstige_Uebungen/fractal_like/penta_fractal_turtle.py
Apop85/Scripts
1d8dad316c55e1f1343526eac9e4b3d0909e4873
[ "MIT" ]
6
2020-12-24T15:15:09.000Z
2022-01-13T01:58:35.000Z
Python/Sonstige_Uebungen/fractal_like/penta_fractal_turtle.py
Apop85/Scripts
1d8dad316c55e1f1343526eac9e4b3d0909e4873
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding:utf-8 -*- ### # File: penta_fractal_turtle.py # Project: Sonstige_Uebungen # Created Date: Thursday 28.02.2019, 12:07 # Author: Apop85 # ----- # Last Modified: Friday 01.03.2019, 12:50 # ----- # Copyright (c) 2019 Apop85 # This software is published under the MIT license. # Check htt...
18.75
71
0.62303
036fdc17306e13cb5a1bba1a15f36adba42f04e9
2,675
py
Python
TreeModelLib/GrowthAndDeathDynamics/Mortality/RandomGrowth/RandomGrowth.py
mcwimm/pyMANGA
6c7b53087e53b116bb02f91c33974f3dfd9a46de
[ "MIT" ]
1
2021-03-16T08:35:50.000Z
2021-03-16T08:35:50.000Z
TreeModelLib/GrowthAndDeathDynamics/Mortality/RandomGrowth/RandomGrowth.py
mcwimm/pyMANGA
6c7b53087e53b116bb02f91c33974f3dfd9a46de
[ "MIT" ]
67
2019-11-14T11:29:52.000Z
2022-03-09T14:37:11.000Z
TreeModelLib/GrowthAndDeathDynamics/Mortality/RandomGrowth/RandomGrowth.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 """ import numpy as np from TreeModelLib.GrowthAndDeathDynamics.Mortality.Random import Random class RandomGrowth(Random): def __init__(self, args, case): super(Random, self).__init__(args, ...
34.294872
76
0.559252
30581b42bd7880006b315eb86b70d6a55f536d33
674
py
Python
PMIa/2015/Donkor_A_H/task_6_10.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
PMIa/2015/Donkor_A_H/task_6_10.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
PMIa/2015/Donkor_A_H/task_6_10.py
YukkaSarasti/pythonintask
eadf4245abb65f4400a3bae30a4256b4658e009c
[ "Apache-2.0" ]
null
null
null
# Задача 6. Вариант 10. # Создайте игру, в которой компьютер загадывает название одной из трех стран, входящих в военно-политический блок "Тройственный союз", а игрок должен его угадать. # Donkor A.H. # 14.04.2016 import random x=random.choice(['Германия','Австро-Венгрия','Италия']) y=input('Сыграем в игру. Я загад...
35.473684
166
0.707715
063f6a9c7e6d7ee6eab51fa15b7d8a3d503ca147
11,557
py
Python
master.py
ameliecordier/IIK
57b40d6b851a1c2369604049d1820e5b572c6227
[ "MIT" ]
null
null
null
master.py
ameliecordier/IIK
57b40d6b851a1c2369604049d1820e5b572c6227
[ "MIT" ]
null
null
null
master.py
ameliecordier/IIK
57b40d6b851a1c2369604049d1820e5b572c6227
[ "MIT" ]
null
null
null
from datahandler import expertPatterns from datahandler import miningPatterns from datahandler import analyser as analyser from matplotlib import pyplot as plt from matplotlib.backends.backend_pdf import PdfPages import os import time def plot_two_results(norev, rev, fignum, legend, pp): """ Utilitaire d'affic...
29.940415
82
0.676906
2335e7284437d794717be84ed886ee2601043ec0
804
py
Python
Curso_Python/Secao4-Python-introducao-a-programacao-orientada-a-objetos-POO/098_encasulamento/main.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
Curso_Python/Secao4-Python-introducao-a-programacao-orientada-a-objetos-POO/098_encasulamento/main.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
Curso_Python/Secao4-Python-introducao-a-programacao-orientada-a-objetos-POO/098_encasulamento/main.py
pedrohd21/Cursos-Feitos
b223aad83867bfa45ad161d133e33c2c200d42bd
[ "MIT" ]
null
null
null
""" public, protected, private _ privado/protected (public _) __ privado (_NOMECLASSE__nomeatributo) """ class BaseDeDados: def __init__(self): self.__dados = {} @property def dados(self): return self.__dados def inserir_clientes(self, id, nome): if 'clientes' not in self.__d...
21.157895
57
0.630597
cc88b9bd7b332888ec7b1b6dfb9dc3e367f010ef
892
py
Python
src/constants.py
ZiningZhu/InfoProbe
0bf241356c5bfcfc4760a195eecf7c80f75379aa
[ "MIT" ]
1
2021-02-06T01:52:00.000Z
2021-02-06T01:52:00.000Z
src/constants.py
SPOClab-ca/InfoProbe
0bf241356c5bfcfc4760a195eecf7c80f75379aa
[ "MIT" ]
null
null
null
src/constants.py
SPOClab-ca/InfoProbe
0bf241356c5bfcfc4760a195eecf7c80f75379aa
[ "MIT" ]
null
null
null
spacy_model_names = { "en": "en_core_web_md", "fr": "fr_core_news_md", "es": "es_core_news_md" } # 17 for English. # 15 for French: replace "INTJ" (7 entries) or "SYM" with "X" (1296 entries). # 16 for Spanish: Change "X" (1 entry) to "INTJ" (27 entries) spacy_pos_dict = { "en": ['ADJ', 'ADP', 'ADV',...
42.47619
141
0.550448
4e1ad8de222a2875b9c6d50f8e51a5fd937564f0
870
py
Python
TreePrintAllPath.py
aertoria/MiscCode
a2e94d0fe0890e6620972f84adcb7976ca9f1408
[ "Apache-2.0" ]
null
null
null
TreePrintAllPath.py
aertoria/MiscCode
a2e94d0fe0890e6620972f84adcb7976ca9f1408
[ "Apache-2.0" ]
null
null
null
TreePrintAllPath.py
aertoria/MiscCode
a2e94d0fe0890e6620972f84adcb7976ca9f1408
[ "Apache-2.0" ]
null
null
null
class node(object): def __init__(self,val): self.val=val self.right=None self.left=None class Solution(object): def DFS_print(self,root): self.stack=[root] self.DFS(root) #self.stack.pop() def DFS(self,node): if node.left == None and node.right == None: #go back print map(lambda x:x.val...
15.818182
99
0.664368
d18f8f402ac4ed15e9faea47a484ce782a2eb6cc
1,947
py
Python
data/time_gen.py
Janrupf/airport-db-seeding
768a9373f02ede5bf613d09270d2fbe84de37a97
[ "MIT" ]
null
null
null
data/time_gen.py
Janrupf/airport-db-seeding
768a9373f02ede5bf613d09270d2fbe84de37a97
[ "MIT" ]
null
null
null
data/time_gen.py
Janrupf/airport-db-seeding
768a9373f02ede5bf613d09270d2fbe84de37a97
[ "MIT" ]
null
null
null
import functools import random class TimeGen: def __init__(self, hour_min_step, hour_max_step): self.hour_min_step = hour_min_step self.hour_max_step = hour_max_step self.current_start_hour = 6 self.current_start_minute = 0 def __iter__(self): return self def __n...
27.041667
114
0.61171
d1a180b4c25806487dcb8d5f90f1a3da3b4fe56c
13,289
py
Python
src/onegov/activity/matching/core.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/activity/matching/core.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/activity/matching/core.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
""" Implements the matching algorithm used to match attendees to occasions. The algorithm used is based on Deferred Acceptance. The algorithm has a quadratic runtime. """ from onegov.activity import Attendee, Booking, Occasion, Period from onegov.activity.matching.score import Scoring from onegov.activity.matching.u...
33.814249
78
0.636316
88171ad87dc7b1072f2705b938c97bec9545041c
10,749
py
Python
AustinBot/all_cogs/boardgame.py
austinmh12/DiscordBots
55550b68a7ad6423de55e62dbbff93fd88f08ff2
[ "MIT" ]
null
null
null
AustinBot/all_cogs/boardgame.py
austinmh12/DiscordBots
55550b68a7ad6423de55e62dbbff93fd88f08ff2
[ "MIT" ]
null
null
null
AustinBot/all_cogs/boardgame.py
austinmh12/DiscordBots
55550b68a7ad6423de55e62dbbff93fd88f08ff2
[ "MIT" ]
null
null
null
from . import log, BASE_PATH, Page, MyCog, chunk from discord import File from discord.ext import commands, tasks import asyncio from PIL import Image, ImageDraw, ImageFont from random import randint import typing from . import boardgameFunctions as BGF from .boardgameFunctions import yahtzee # Version version = '1.0....
40.870722
115
0.724626
888f2477c245e43c2f99afc8f694b43d8280fa8a
627
py
Python
DataCollections/Twitter/CTweets.py
moasgh/BumbleBee
2b0aae7970ab316c7b8b12dd4032b41ee1772aad
[ "MIT" ]
7
2020-03-06T05:53:43.000Z
2022-01-30T17:31:18.000Z
DataCollections/Twitter/CTweets.py
moasgh/BumbleBee
2b0aae7970ab316c7b8b12dd4032b41ee1772aad
[ "MIT" ]
null
null
null
DataCollections/Twitter/CTweets.py
moasgh/BumbleBee
2b0aae7970ab316c7b8b12dd4032b41ee1772aad
[ "MIT" ]
null
null
null
import re def clean(text): ctext = clean_urls(text) ctext = clean_references(ctext) ctext = clean_nonechars(ctext) ctext = ctext.strip() return ctext def clean_urls(text): return re.sub('https?://[A-Za-z0-9./]+', '', text) def clean_references(text): return re.sub('@[A-...
18.441176
55
0.578947
88a218ca3c0616a3dd8b446bc63c37ba8e4a019b
3,201
py
Python
backend/app/crud/crud_base_task.py
jinnn-dev/patholearn
b4e6a18cfbf963e71640ed6cac3fc3a618a7ae15
[ "MIT" ]
1
2021-11-04T17:06:07.000Z
2021-11-04T17:06:07.000Z
backend/app/crud/crud_base_task.py
JamesNeumann/learning-by-annotations
c2b5e4b653eeb1c973aa5a7dad35ac8be18cb1ad
[ "MIT" ]
21
2021-11-01T10:13:56.000Z
2021-12-02T10:02:13.000Z
backend/app/crud/crud_base_task.py
jinnn-dev/patholearn
b4e6a18cfbf963e71640ed6cac3fc3a618a7ae15
[ "MIT" ]
1
2021-12-16T18:20:55.000Z
2021-12-16T18:20:55.000Z
from typing import List, Optional from sqlalchemy.orm import Session from app.crud.base import CRUDBase from app.models.base_task import BaseTask from app.schemas.base_task import BaseTaskUpdate, BaseTaskCreate class CRUDBaseTask(CRUDBase[BaseTask, BaseTaskCreate, BaseTaskUpdate]): def get_multi_by_ta...
31.382353
89
0.587004
14fac4dfc6d2a571f44cfcd35f51402f4d2edf5f
722
py
Python
ANN/past_works/trapezoidal.py
joao-frohlich/BCC
9ed74eb6d921d1280f48680677a2140c5383368d
[ "Apache-2.0" ]
10
2020-12-08T20:18:15.000Z
2021-06-07T20:00:07.000Z
ANN/past_works/trapezoidal.py
joao-frohlich/BCC
9ed74eb6d921d1280f48680677a2140c5383368d
[ "Apache-2.0" ]
2
2021-06-28T03:42:13.000Z
2021-06-28T16:53:13.000Z
ANN/past_works/trapezoidal.py
joao-frohlich/BCC
9ed74eb6d921d1280f48680677a2140c5383368d
[ "Apache-2.0" ]
2
2021-01-14T19:59:20.000Z
2021-06-15T11:53:21.000Z
from math import tan """ Funcionamento O algoritmo implementado funciona da seguinte maneira É necessário definir a função, os intervalos inferioes e superiores e por fim quantidade de iterações a = limite inferior b = limite superior n = iterações f(x) = função """ def calcula_integral(...
20.055556
81
0.583102
092e558882814fb270ae1b63b10c91a2f1f27c7c
10,513
py
Python
generate_plots.py
silberzwiebel/klimawatch
fbb5b98e70080581c40821aa8f112c041c853bad
[ "Apache-2.0" ]
null
null
null
generate_plots.py
silberzwiebel/klimawatch
fbb5b98e70080581c40821aa8f112c041c853bad
[ "Apache-2.0" ]
null
null
null
generate_plots.py
silberzwiebel/klimawatch
fbb5b98e70080581c40821aa8f112c041c853bad
[ "Apache-2.0" ]
1
2020-02-07T09:21:59.000Z
2020-02-07T09:21:59.000Z
# plots import plotly.graph_objects as go # make it easier with numeric values import pandas import numpy as np # for computing the trend from scipy.stats import linregress # reading command line arguments import sys # writing json import json # wrapping long lines import textwrap # possibility to delete files import o...
37.546429
139
0.61267
117a2a307d601c9f7de185e43945911010ddb280
1,573
py
Python
test/test_cashflow.py
scuervo91/dcapy
46c9277e607baff437e5707167476d5f7e2cf80c
[ "MIT" ]
4
2021-05-21T13:26:10.000Z
2021-11-15T17:17:01.000Z
test/test_cashflow.py
scuervo91/dcapy
46c9277e607baff437e5707167476d5f7e2cf80c
[ "MIT" ]
null
null
null
test/test_cashflow.py
scuervo91/dcapy
46c9277e607baff437e5707167476d5f7e2cf80c
[ "MIT" ]
null
null
null
import unittest import numpy as np from datetime import date from pandas.testing import assert_frame_equal import pandas as pd from dcapy.cashflow import CashFlow, CashFlowModel class TestCashFlow(unittest.TestCase): def test_npv(self): oil_sell = CashFlow( name = 'oil_sell', const...
29.12963
89
0.506039
11812f21c9c596dffd83d94ca429f45ff1c17050
92
py
Python
python/python_backup/PRAC_PYTHON/5_for.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
16
2018-11-26T08:39:42.000Z
2019-05-08T10:09:52.000Z
python/python_backup/PRAC_PYTHON/5_for.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
8
2020-05-04T06:29:26.000Z
2022-02-12T05:33:16.000Z
python/python_backup/PRAC_PYTHON/5_for.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
5
2020-02-11T16:02:21.000Z
2021-02-05T07:48:30.000Z
words=["Jimut","Python","c"] for w in words: #for just simple for loop print(w,len(w))
23
42
0.630435
0101f564eff3c78e8c68b76331f82e617d38803b
820
py
Python
longest-common-prefix/longest-common-prefix.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
2
2021-12-05T14:29:06.000Z
2022-01-01T05:46:13.000Z
longest-common-prefix/longest-common-prefix.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
null
null
null
longest-common-prefix/longest-common-prefix.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
null
null
null
class Solution: def longestCommonPrefix(self, strs: List[str]) -> str: if len(strs)==1: return strs[0] minlen = min([len(each) for each in strs]) result="" for i in range(minlen): basis = strs[-1][i] for j in range(len(strs)-1): if ...
31.538462
58
0.439024
6df7257d5375f69e3ed61983628b9ca3d0df1d9f
2,607
py
Python
official/cv/srcnn/src/dataset.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
2
2021-07-08T13:10:42.000Z
2021-11-08T02:48:57.000Z
official/cv/srcnn/src/dataset.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
null
null
null
official/cv/srcnn/src/dataset.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
2
2019-09-01T06:17:04.000Z
2019-10-04T08:39:45.000Z
# Copyright 2021 Huawei Technologies Co., Ltd # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to...
41.380952
105
0.666283
0994508b38aca6fd6cbebc7f68d9e6a357639caa
424
py
Python
pyScript/custom_src/GlobalAccess.py
Shirazbello/Pyscriptining
0f2c80a9bb10477d65966faeccc7783f20385c1b
[ "MIT" ]
null
null
null
pyScript/custom_src/GlobalAccess.py
Shirazbello/Pyscriptining
0f2c80a9bb10477d65966faeccc7783f20385c1b
[ "MIT" ]
null
null
null
pyScript/custom_src/GlobalAccess.py
Shirazbello/Pyscriptining
0f2c80a9bb10477d65966faeccc7783f20385c1b
[ "MIT" ]
null
null
null
class GlobalStorage: storage = {'design style': 'dark std', 'debugging': False} def debug(*args): s = '' for arg in args: s += ' '+str(arg) if GlobalStorage.storage['debugging']: print(' --> DEBUG:', s) # yyep, that's it.... # you m...
23.555556
46
0.478774
09f6606add82e1f791fea814ebb69a0d1607b4b5
6,412
py
Python
src/visitpy/visit_utils/tests/test_encoding.py
visit-dav/vis
c08bc6e538ecd7d30ddc6399ec3022b9e062127e
[ "BSD-3-Clause" ]
226
2018-12-29T01:13:49.000Z
2022-03-30T19:16:31.000Z
src/visitpy/visit_utils/tests/test_encoding.py
visit-dav/vis
c08bc6e538ecd7d30ddc6399ec3022b9e062127e
[ "BSD-3-Clause" ]
5,100
2019-01-14T18:19:25.000Z
2022-03-31T23:08:36.000Z
src/visitpy/visit_utils/tests/test_encoding.py
visit-dav/vis
c08bc6e538ecd7d30ddc6399ec3022b9e062127e
[ "BSD-3-Clause" ]
84
2019-01-24T17:41:50.000Z
2022-03-10T10:01:46.000Z
# Copyright (c) Lawrence Livermore National Security, LLC and other VisIt # Project developers. See the top-level LICENSE file for dates and other # details. No copyright assignment is required to contribute to VisIt. """ file: test_encoding.py author: Cyrus Harrison (cyrush@llnl.gov) created: 4/09/2010 descript...
42.463576
109
0.630536
a33b8e97edb34bea127681c20fb239450206556d
3,732
py
Python
Packs/ExpanseV2/Scripts/ExpanseAggregateAttributionUser/ExpanseAggregateAttributionUser.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/ExpanseV2/Scripts/ExpanseAggregateAttributionUser/ExpanseAggregateAttributionUser.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/ExpanseV2/Scripts/ExpanseAggregateAttributionUser/ExpanseAggregateAttributionUser.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
"""ExpanseAggregateAttributionUser """ import demistomock as demisto from CommonServerPython import * # noqa # pylint: disable=unused-wildcard-import from CommonServerUserPython import * # noqa from typing import Dict, List, Any, Tuple, Optional import traceback ''' STANDALONE FUNCTION ''' def deconstruct_entr...
31.1
112
0.620579
a3a247716b05181eb2ad340dbb31ef8d5f76c0d0
5,288
py
Python
V1/utils/models.py
marsXyr/GESRL
3d60dfd4ffa1e0ae24d64b09f431d8ee0a9b5c01
[ "Apache-2.0" ]
null
null
null
V1/utils/models.py
marsXyr/GESRL
3d60dfd4ffa1e0ae24d64b09f431d8ee0a9b5c01
[ "Apache-2.0" ]
null
null
null
V1/utils/models.py
marsXyr/GESRL
3d60dfd4ffa1e0ae24d64b09f431d8ee0a9b5c01
[ "Apache-2.0" ]
null
null
null
import numpy as np from copy import deepcopy import torch import torch.nn as nn from torch.optim import Adam import torch.nn.functional as F #USE_CUDA = torch.cuda.is_available() USE_CUDA = False if USE_CUDA: FloatTensor = torch.cuda.FloatTensor else: FloatTensor = torch.FloatTensor def to_numpy(var): ...
30.217143
106
0.617247
6e55b0a9a232735b589386d0f72b1b9579ed262b
460
py
Python
packages/watchmen-dqc/src/watchmen_dqc/monitor/rule/disabled_rules.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-dqc/src/watchmen_dqc/monitor/rule/disabled_rules.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-dqc/src/watchmen_dqc/monitor/rule/disabled_rules.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
from typing import List from watchmen_model.dqc import MonitorRuleCode disabled_rules: List[MonitorRuleCode] = [ MonitorRuleCode.RAW_MISMATCH_STRUCTURE, # ignored now MonitorRuleCode.FACTOR_MISMATCH_DATE_TYPE, # should be detected on pipeline run MonitorRuleCode.FACTOR_USE_CAST, # should be detected on pipeline...
38.333333
81
0.83913
287189638a67b6c452ceb33fb318213a3f4059c3
1,049
py
Python
pyventskalender/tag15_loesung.py
kopp/pyventskalender
6f6455f3c1db07f65a772b2716e4be95fbcd1804
[ "MIT" ]
null
null
null
pyventskalender/tag15_loesung.py
kopp/pyventskalender
6f6455f3c1db07f65a772b2716e4be95fbcd1804
[ "MIT" ]
null
null
null
pyventskalender/tag15_loesung.py
kopp/pyventskalender
6f6455f3c1db07f65a772b2716e4be95fbcd1804
[ "MIT" ]
null
null
null
from typing import Set, List, Optional try: from pyventskalender.tag14_loesung import VERLOREN_BEI_SO_VIELEN_FEHLERN except ImportError: from tag14_loesung import VERLOREN_BEI_SO_VIELEN_FEHLERN def ist_buchstabe(eingabe_von_nutzer: str) -> bool: if len(eingabe_von_nutzer) != 1: return False r...
29.138889
77
0.70734
c6e2e5f03e48ea9792a6dde89b285bc867447f51
702
py
Python
pacman-arch/test/pacman/tests/replace110.py
Maxython/pacman-for-termux
3b208eb9274cbfc7a27fca673ea8a58f09ebad47
[ "MIT" ]
23
2021-05-21T19:11:06.000Z
2022-03-31T18:14:20.000Z
source/pacman-6.0.1/test/pacman/tests/replace110.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
11
2021-05-21T12:08:44.000Z
2021-12-21T08:30:08.000Z
source/pacman-6.0.1/test/pacman/tests/replace110.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
1
2021-09-26T08:44:40.000Z
2021-09-26T08:44:40.000Z
self.description = "Replace a package with a file in 'backup' (local modified)" # FS#24543 lp = pmpkg("dummy") lp.files = ["etc/dummy.conf*", "bin/dummy"] lp.backup = ["etc/dummy.conf"] self.addpkg2db("local", lp) sp = pmpkg("replacement") sp.replaces = ["dummy"] sp.files = ["etc/dummy.conf", "bin/dummy*"] sp.backup ...
25.071429
79
0.710826
05e635c35d7e288bb6171b843f14ec6a962152da
923
py
Python
Python/zzz_training_challenge/Python_Challenge/solutions/ch02_math/solutions/ex08_combinatorics.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
Python/zzz_training_challenge/Python_Challenge/solutions/ch02_math/solutions/ex08_combinatorics.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
Python/zzz_training_challenge/Python_Challenge/solutions/ch02_math/solutions/ex08_combinatorics.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
# Beispielprogramm für das Buch "Python Challenge" # # Copyright 2020 by Michael Inden import math def solve_quadratic_simple(): for a in range(1, 100): for b in range(1, 100): for c in range(1, 100): # if a ** 2 + b ** 2 == c ** 2: if a * a + b * b == c * c: ...
23.666667
67
0.48429
af6aa1df80b339741689942f942062f889d05ae8
8,733
py
Python
Liquid-optimizer/rf.py
PasaLab/YAO
2e70203197cd79f9522d65731ee5dc0eb236b005
[ "Apache-2.0" ]
2
2021-08-30T14:12:09.000Z
2022-01-20T02:14:22.000Z
Liquid-optimizer/rf.py
PasaLab/YAO
2e70203197cd79f9522d65731ee5dc0eb236b005
[ "Apache-2.0" ]
null
null
null
Liquid-optimizer/rf.py
PasaLab/YAO
2e70203197cd79f9522d65731ee5dc0eb236b005
[ "Apache-2.0" ]
null
null
null
# _*_coding:utf-8_*_ import numpy as np import pandas as pd import os def load_data(trainfile, testfile): traindata = pd.read_csv(trainfile) testdata = pd.read_csv(testfile) feature_data = traindata.iloc[:, 1:-1] label_data = traindata.iloc[:, -1] test_feature = testdata.iloc[:, 1:-1] test_label = t...
32.830827
99
0.746708
59049206796b7df07f42606a9f63a197e9b7c8cc
2,393
py
Python
andinopy/interfaces/rfid_keyboard_interface.py
andino-systems/andinopy
28fc09fbdd67dd690b9b3f80f03a05c342c777e1
[ "Apache-2.0" ]
null
null
null
andinopy/interfaces/rfid_keyboard_interface.py
andino-systems/andinopy
28fc09fbdd67dd690b9b3f80f03a05c342c777e1
[ "Apache-2.0" ]
null
null
null
andinopy/interfaces/rfid_keyboard_interface.py
andino-systems/andinopy
28fc09fbdd67dd690b9b3f80f03a05c342c777e1
[ "Apache-2.0" ]
null
null
null
# _ _ _ # / \ _ __ __| (_)_ __ ___ _ __ _ _ # / _ \ | '_ \ / _` | | '_ \ / _ \| '_ \| | | | # / ___ \| | | | (_| | | | | | (_) | |_) | |_| | # /_/ \_\_| |_|\__,_|_|_| |_|\___/| .__/ \__, | # |_| |___/ # by Jakob Groß import abc from and...
36.257576
81
0.517342
a731cb8565ca1f559b567aac3fbbbf4f9002bf3a
818
py
Python
Hackerrank_problems/Organizing_container_of_balls/solution.py
gbrls/CompetitiveCode
b6f1b817a655635c3c843d40bd05793406fea9c6
[ "MIT" ]
165
2020-10-03T08:01:11.000Z
2022-03-31T02:42:08.000Z
Hackerrank_problems/Organizing_container_of_balls/solution.py
gbrls/CompetitiveCode
b6f1b817a655635c3c843d40bd05793406fea9c6
[ "MIT" ]
383
2020-10-03T07:39:11.000Z
2021-11-20T07:06:35.000Z
Hackerrank_problems/Organizing_container_of_balls/solution.py
gbrls/CompetitiveCode
b6f1b817a655635c3c843d40bd05793406fea9c6
[ "MIT" ]
380
2020-10-03T08:05:04.000Z
2022-03-19T06:56:59.000Z
# Logic # The required solution can be obtained by simply sorting the arrays. After sorting check if the arrays are exactly same or not. # If the arrays are same, it's possible to obtain the desired configuration, otherwise it's impossible. def organizingContainers(container): rows = [sum(x) for x in container] ...
29.214286
128
0.633252
abb1a975a2d32cd0ef7a733a84328f95433e4943
1,078
py
Python
devices/device.py
MiaranaDIY/Salamigal
44ac98fa6463d46694e1f9343a0ebc788e7a88f8
[ "MIT" ]
3
2017-08-02T12:26:34.000Z
2021-01-13T01:06:26.000Z
devices/device.py
MiaranaDIY/Salamigal
44ac98fa6463d46694e1f9343a0ebc788e7a88f8
[ "MIT" ]
null
null
null
devices/device.py
MiaranaDIY/Salamigal
44ac98fa6463d46694e1f9343a0ebc788e7a88f8
[ "MIT" ]
3
2017-02-14T22:10:00.000Z
2021-01-02T14:26:43.000Z
import time class Device: #Global variable instant_count = 0 def __init__(self): #Increment instant counter Device.instant_count += 1 #load watt for power usage calculation and device property self.load_watt = 0 self.name = 'Device' self.location = 'Location' ...
26.95
72
0.552876
abd3818cc13d4399585b2153d538159610366df5
2,213
py
Python
experimental/BibTeX/tst_BibTeX_grammar.py
jecki/DHParser
c6c1bd7db2de85b5997a3640242f4f444532304e
[ "Apache-2.0" ]
2
2020-12-25T19:37:42.000Z
2021-03-26T04:59:12.000Z
experimental/BibTeX/tst_BibTeX_grammar.py
jecki/DHParser
c6c1bd7db2de85b5997a3640242f4f444532304e
[ "Apache-2.0" ]
6
2018-08-07T22:48:52.000Z
2021-10-07T18:38:20.000Z
experimental/BibTeX/tst_BibTeX_grammar.py
jecki/DHParser
c6c1bd7db2de85b5997a3640242f4f444532304e
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 """tst_BibTeX_grammar.py - runs the unit tests for the BibTeX grammar Author: Eckhart Arnold <arnold@badw.de> Copyright 2017 Bavarian Academy of Sciences and Humanities Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the Lice...
34.578125
115
0.691369
e6357fe1d0d77b7784505bdbc43908218403fd36
424
py
Python
Packs/CommonScripts/Scripts/URLEncode/URLEncode.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/CommonScripts/Scripts/URLEncode/URLEncode.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/CommonScripts/Scripts/URLEncode/URLEncode.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
import demistomock as demisto from CommonServerPython import * from urllib.parse import quote, unquote ''' MAIN FUNCTION ''' def main(args): value = args.get('value') decoded_value = unquote(value) return quote(decoded_value) if __name__ in ('__main__', '__builtin__', 'builtins'): try: retu...
22.315789
55
0.691038
558b103f7c41451affd5e793e3983b51f516433b
488
py
Python
python/requests/advanced_usage/retry_on_failure.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
python/requests/advanced_usage/retry_on_failure.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
python/requests/advanced_usage/retry_on_failure.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
import requests from requests.adapters import HTTPAdapter from requests.packages.urllib3.util.retry import Retry retry_strategy = Retry( total=3, status_forcelist=[429, 500, 502, 503, 504], method_whitelist=['HEAD', 'GET', 'OPTIONS'], backoff_factor=1 ) adapter = HTTPAdapter(max_retries=retry_strateg...
23.238095
57
0.729508