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
cbe1784e4c43acfc4b8301d8a7bef0ab1041694a
54
py
Python
chff/__init__.py
mnes-io/chff
9f450183ae508a56bf6869f59e7ffce24f56b269
[ "MIT" ]
null
null
null
chff/__init__.py
mnes-io/chff
9f450183ae508a56bf6869f59e7ffce24f56b269
[ "MIT" ]
null
null
null
chff/__init__.py
mnes-io/chff
9f450183ae508a56bf6869f59e7ffce24f56b269
[ "MIT" ]
null
null
null
from .links import hello from .client import doclient
18
28
0.814815
69b82acc880b9e2368567438f6e05df5bab3b217
3,121
py
Python
test/test_npu/test_network_ops/test_batchnorm_backward_eval.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_batchnorm_backward_eval.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_batchnorm_backward_eval.py
Ascend/pytorch
39849cf72dafe8d2fb68bd1679d8fd54ad60fcfc
[ "BSD-3-Clause" ]
null
null
null
# Copyright (c) 2020 Huawei Technologies Co., Ltd # All rights reserved. # # Licensed under the BSD 3-Clause License (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://opensource.org/licenses/BSD-3-Clause # # Unless required by appl...
37.60241
82
0.643384
aa4c9c240faba2945d060aa967987c96dff30e1c
358
py
Python
008 Tic-Tac-Toe.py
Gravitar64/KESS
174bf9ee853f7bfb0c2e652b83150045197b6425
[ "MIT" ]
null
null
null
008 Tic-Tac-Toe.py
Gravitar64/KESS
174bf9ee853f7bfb0c2e652b83150045197b6425
[ "MIT" ]
null
null
null
008 Tic-Tac-Toe.py
Gravitar64/KESS
174bf9ee853f7bfb0c2e652b83150045197b6425
[ "MIT" ]
null
null
null
def print_feld(feld): for i, inhalt in enumerate(feld): print(f' {inhalt} |',end='') if (i+1) % 3 == 0: print() print('------------') feld = [" "]*9 spieler = True while True: print_feld(feld) zug = input(f"Dein Zug Spieler {'X' if spieler else 'O'} (0-8): ") feld[int(zug)] = "X" if spiel...
19.888889
68
0.541899
faae6c2edad50086f3e6abe8c2252aa343cf60ea
312
py
Python
apps/pymunktest/pymunktest2.py
Obyoxar/RobolabStatistics
08343ca3ac49df7efdac33692d7cc4b783e851f5
[ "MIT" ]
2
2017-11-30T21:12:11.000Z
2017-12-01T07:52:43.000Z
apps/pymunktest/pymunktest2.py
Obyoxar/RobolabStatistics
08343ca3ac49df7efdac33692d7cc4b783e851f5
[ "MIT" ]
14
2017-11-14T18:12:53.000Z
2018-06-03T16:07:57.000Z
apps/pymunktest/pymunktest2.py
Obyoxar/RobolabStatistics
08343ca3ac49df7efdac33692d7cc4b783e851f5
[ "MIT" ]
3
2018-02-05T10:40:03.000Z
2018-02-09T09:29:19.000Z
import pymunk space = pymunk.Space() space.gravity = (0.0, -900.0) ballBody = pymunk.Body(10) ballBody.position = (20, 20) shape = pymunk.Circle(ballBody, 20, (0, 0)) shape.elasticity = 0 shape.friction = 0 space.add(ballBody, shape) for i in range(1, 200): space.step(0.0002) print(ballBody.position)
20.8
43
0.692308
4f04eca13ed3beb5e7d06a47c15a2a11a697d2a1
258
py
Python
fizz.py
KelstonClub/FizzBuzz
d4d528aa025c69e27a43ba7466b302f61d4c5b8a
[ "MIT" ]
null
null
null
fizz.py
KelstonClub/FizzBuzz
d4d528aa025c69e27a43ba7466b302f61d4c5b8a
[ "MIT" ]
null
null
null
fizz.py
KelstonClub/FizzBuzz
d4d528aa025c69e27a43ba7466b302f61d4c5b8a
[ "MIT" ]
null
null
null
fizz = 5 buzz = 7 counter = 1 while counter <= 60: fizz_num = counter % fizz buzz_num = counter % buzz if fizz_num == 0: print("Fizz") elif buzz_num == 0: print("Buzz") else: print(counter) counter += 1
17.2
29
0.527132
35a52868ff1915bc9c2d34b78877cae045f09f61
1,878
py
Python
2018/quals/crypto-dm-col/challenge.py
iicarus-bit/google-ctf
4eb8742bca58ff071ff8f6814d41d9ec7eb1db4b
[ "Apache-2.0" ]
2,757
2018-04-28T21:41:36.000Z
2022-03-29T06:33:36.000Z
2018/quals/crypto-dm-col/challenge.py
iicarus-bit/google-ctf
4eb8742bca58ff071ff8f6814d41d9ec7eb1db4b
[ "Apache-2.0" ]
20
2019-07-23T15:29:32.000Z
2022-01-21T12:53:04.000Z
2018/quals/crypto-dm-col/challenge.py
iicarus-bit/google-ctf
4eb8742bca58ff071ff8f6814d41d9ec7eb1db4b
[ "Apache-2.0" ]
449
2018-05-09T05:54:05.000Z
2022-03-30T14:54:18.000Z
#!/usr/bin/env python3 # # Copyright 2018 Google LLC # # 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 ...
24.38961
74
0.691161
35a9387ca49c10c2f004597b128c1d8fab4236c3
63
py
Python
SoSe-21/Code-Vorlesungen/Wiederholung/2/Wiederholung-Slice.py
jonasrdt/Wirtschaftsinformatik2
30d5d896808b98664c55cb6fbb3b30a7f1904d9f
[ "MIT" ]
1
2022-03-23T09:40:39.000Z
2022-03-23T09:40:39.000Z
SoSe-21/Code-Vorlesungen/Wiederholung/2/Wiederholung-Slice.py
jonasrdt/Wirtschaftsinformatik2
30d5d896808b98664c55cb6fbb3b30a7f1904d9f
[ "MIT" ]
null
null
null
SoSe-21/Code-Vorlesungen/Wiederholung/2/Wiederholung-Slice.py
jonasrdt/Wirtschaftsinformatik2
30d5d896808b98664c55cb6fbb3b30a7f1904d9f
[ "MIT" ]
null
null
null
namen = "Robinson Crusoe" # Slicen von Namen print(namen[0:8])
15.75
25
0.714286
52f35fef9832b1d443d9f5d916d5a027e6453820
2,042
py
Python
python/aniket_style/DBManager.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
16
2018-11-26T08:39:42.000Z
2019-05-08T10:09:52.000Z
python/aniket_style/DBManager.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
8
2020-05-04T06:29:26.000Z
2022-02-12T05:33:16.000Z
python/aniket_style/DBManager.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
5
2020-02-11T16:02:21.000Z
2021-02-05T07:48:30.000Z
import sqlite3 class DBManager: def __init__(self,path_to_db): self.path = path_to_db self.conn = sqlite3.connect(self.path) self.cur = self.conn.cursor() def create_table(self,table_name, columns): query = "CREATE TABLE IF NOT EXISTS "+ table_name+"(" for key,val in col...
40.84
167
0.583741
eaa2be054fe69c68ff19d6c0c66619bac5b5dd38
467
py
Python
frappe-bench/apps/erpnext/erpnext/patches/v5_0/update_journal_entry_title.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
1
2021-04-29T14:55:29.000Z
2021-04-29T14:55:29.000Z
frappe-bench/apps/erpnext/erpnext/patches/v5_0/update_journal_entry_title.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/patches/v5_0/update_journal_entry_title.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
1
2021-04-29T14:39:01.000Z
2021-04-29T14:39:01.000Z
# Copyright (c) 2013, Frappe Technologies Pvt. Ltd. and Contributors # License: GNU General Public License v3. See license.txt from __future__ import unicode_literals import frappe def execute(): frappe.reload_doctype("Journal Entry") frappe.db.sql("""update `tabJournal Entry` set title = if(ifnull(pay_to_recd_fr...
35.923077
68
0.749465
dc54f784ef5cc755eddd0e0e2a8070e32303364b
136,173
py
Python
BEGUNDAL-main/brute.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-17T03:35:03.000Z
2021-12-08T06:00:31.000Z
BEGUNDAL-main/brute.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
null
null
null
BEGUNDAL-main/brute.py
Zusyaku/Termux-And-Lali-Linux-V2
b1a1b0841d22d4bf2cc7932b72716d55f070871e
[ "Apache-2.0" ]
2
2021-11-05T18:07:48.000Z
2022-02-24T21:25:07.000Z
#encrypted by azim vau >_ #Try It :) import marshal exec(marshal.loads(b'\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x00\x00\x00\xf3\t\x00\x00\x00d\x00Z\x00d\x01S\x00\t\xa9\x02s-\xcb\x00\x00\xe3\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00@\x...
22,695.5
136,119
0.747432
f4bcba3ec4606944257b07a1c568c2b673763dba
2,486
py
Python
pacman-arch/test/pacman/pmfile.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/pmfile.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/pmfile.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
1
2021-09-26T08:44:40.000Z
2021-09-26T08:44:40.000Z
# Copyright (c) 2006 by Aurelien Foret <orelien@chez.com> # Copyright (c) 2006-2021 Pacman Development Team <pacman-dev@archlinux.org> # # 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; eith...
29.951807
77
0.617458
870fae778dff1d293512f41b37b52bae5f015f1d
4,622
py
Python
casts/views.py
rocky-roll-call/rrc-backend
02e8e11c3dab7661e48650e2e861a4a97788a4ce
[ "MIT" ]
null
null
null
casts/views.py
rocky-roll-call/rrc-backend
02e8e11c3dab7661e48650e2e861a4a97788a4ce
[ "MIT" ]
null
null
null
casts/views.py
rocky-roll-call/rrc-backend
02e8e11c3dab7661e48650e2e861a4a97788a4ce
[ "MIT" ]
null
null
null
""" Cast API Views """ # django from django.shortcuts import get_object_or_404 # library from rest_framework import generics, permissions, views from rest_framework.exceptions import ParseError, ValidationError from rest_framework.response import Response # app from users.models import Profile from .models import Ca...
29.253165
83
0.717871
5eb88e03fe566d3ce7a6e8d11dc181c99f0473e3
4,993
py
Python
tests/test_models.py
ihatov08/jumeaux
7d983474df4b6dcfa57ea1a66901fbc99ebababa
[ "MIT" ]
11
2017-10-02T01:29:12.000Z
2022-03-31T08:37:22.000Z
tests/test_models.py
ihatov08/jumeaux
7d983474df4b6dcfa57ea1a66901fbc99ebababa
[ "MIT" ]
79
2017-07-16T14:47:17.000Z
2022-03-31T08:49:14.000Z
tests/test_models.py
ihatov08/jumeaux
7d983474df4b6dcfa57ea1a66901fbc99ebababa
[ "MIT" ]
2
2019-01-28T06:11:58.000Z
2021-01-25T07:21:21.000Z
#!/usr/bin/env python # -*- coding:utf-8 -*- from collections import namedtuple import pytest from owlmixin import TOption from jumeaux.models import Proxy, Response class TestProxy: def test_from_host_normal(self): actual = Proxy.from_host(TOption("proxy.net")) assert actual.http == "http://pro...
35.664286
152
0.467054
1d1c21454ab146d476ff35d5fcdb3f55fe9c37d7
7,504
py
Python
publ/html_entry.py
PlaidWeb/Publ
67efc5e32bf25dbac72a83d1167de038b79db5a7
[ "MIT" ]
27
2018-11-30T21:32:26.000Z
2022-03-20T19:46:25.000Z
publ/html_entry.py
PlaidWeb/Publ
67efc5e32bf25dbac72a83d1167de038b79db5a7
[ "MIT" ]
249
2018-09-30T07:04:37.000Z
2022-03-29T04:31:00.000Z
publ/html_entry.py
PlaidWeb/Publ
67efc5e32bf25dbac72a83d1167de038b79db5a7
[ "MIT" ]
4
2019-03-01T06:46:13.000Z
2019-06-30T17:45:46.000Z
# html_entry.py """ HTML entry processing functionality """ import html import logging import re import typing import flask from . import image, links, utils from .config import config LOGGER = logging.getLogger(__name__) class HTMLEntry(utils.HTMLTransform): """ An HTML manipulator to fixup src and href attr...
31.931915
97
0.563699
d58bd06e64445caf9ae97b2ef5b5ef6827f4ac3a
7,087
py
Python
Packs/MobileIronUEM/Integrations/MobileIronCORE/MobileIronCORE_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/MobileIronUEM/Integrations/MobileIronCORE/MobileIronCORE_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/MobileIronUEM/Integrations/MobileIronCORE/MobileIronCORE_test.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
1,297
2016-08-04T13:59:00.000Z
2022-03-31T23:43:06.000Z
import io from pytest import raises, fixture from CommonServerPython import * MOCK_URL = 'https://core.mobileiron.com' MOCK_PARAMS = { 'admin_space_id': '1' } @fixture def client(): from MobileIronCORE import MobileIronCoreClient return MobileIronCoreClient( base_url=MOCK_URL, verify=F...
39.154696
115
0.721321
f698ae8cc4b6a83f1bd305ffe77bc43c6c38ca51
831
py
Python
2019/finals/misc-stuffed-finals/bomb_creation/maketest.py
iicarus-bit/google-ctf
4eb8742bca58ff071ff8f6814d41d9ec7eb1db4b
[ "Apache-2.0" ]
2,757
2018-04-28T21:41:36.000Z
2022-03-29T06:33:36.000Z
2019/finals/misc-stuffed-finals/bomb_creation/maketest.py
iicarus-bit/google-ctf
4eb8742bca58ff071ff8f6814d41d9ec7eb1db4b
[ "Apache-2.0" ]
20
2019-07-23T15:29:32.000Z
2022-01-21T12:53:04.000Z
2019/finals/misc-stuffed-finals/bomb_creation/maketest.py
iicarus-bit/google-ctf
4eb8742bca58ff071ff8f6814d41d9ec7eb1db4b
[ "Apache-2.0" ]
449
2018-05-09T05:54:05.000Z
2022-03-30T14:54:18.000Z
#!/usr/bin/python2 # Copyright 2019 Google LLC # # 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 # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ag...
29.678571
74
0.756919
f6cb886a3835a1f466fd569d836e36682fff3f0d
1,869
py
Python
app/t1health_app/static/fusioncharts-suite-xt/integrations/django/samples/fusioncharts/samples/chart_special_chart.py
siyaochen/Tier1Health
536591a7534bbb3fb27fe889bfed9de152ec1864
[ "MIT" ]
14
2016-11-03T19:06:21.000Z
2021-11-24T09:05:09.000Z
app/t1health_app/static/fusioncharts-suite-xt/integrations/django/samples/fusioncharts/samples/chart_special_chart.py
siyaochen/Tier1Health
536591a7534bbb3fb27fe889bfed9de152ec1864
[ "MIT" ]
10
2022-02-16T07:17:49.000Z
2022-03-08T12:43:51.000Z
asset/integrations/django/samples/fusioncharts/samples/chart_special_chart.py
Piusshungu/catherine-junior-school
5356f4ff5a5c8383849d32e22a60d638c35b1a48
[ "MIT" ]
17
2016-05-19T13:16:34.000Z
2021-04-30T14:38:42.000Z
from django.shortcuts import render from django.http import HttpResponse # Include the `fusioncharts.py` file which has required functions to embed the charts in html page from ..fusioncharts import FusionCharts # Loading Data from a Static XML String # It is a example to show a Column 2D chart where data is passed a...
53.4
138
0.586945
63ef16f5f045c316b180cf7682f39fabfbd524dd
915
py
Python
propeller/11_motor.py
HackYourOffice/monitoring-with-intelligence
9ae3226e2b4e87d21d764c33c4bb6e621892be1b
[ "Unlicense" ]
2
2017-11-17T15:14:11.000Z
2017-11-17T23:04:39.000Z
propeller/11_motor.py
HackYourOffice/monitoring-with-intelligence
9ae3226e2b4e87d21d764c33c4bb6e621892be1b
[ "Unlicense" ]
null
null
null
propeller/11_motor.py
HackYourOffice/monitoring-with-intelligence
9ae3226e2b4e87d21d764c33c4bb6e621892be1b
[ "Unlicense" ]
null
null
null
#!/usr/bin/env python import RPi.GPIO as GPIO import time MotorPin_A = 11 MotorPin_B = 12 def motorStop(): GPIO.output(MotorPin_A, GPIO.HIGH) GPIO.output(MotorPin_B, GPIO.HIGH) def setup(): GPIO.setwarnings(False) GPIO.setmode(GPIO.BOARD) GPIO.setup(MotorPin_A, GPIO.OUT) GPIO.setup(MotorPin_B, GPIO.OUT) mot...
18.3
56
0.681967
d61842b94122d2a2fcdd0a43ae5c3a041796bd25
1,448
py
Python
src/test.py
marina8888/flame-dilution-method
823c004f7f7ea85ca3e010610b61972a112cf988
[ "MIT" ]
2
2020-03-23T15:05:19.000Z
2020-03-24T02:43:07.000Z
src/test.py
marina8888/flame-dilution-method
823c004f7f7ea85ca3e010610b61972a112cf988
[ "MIT" ]
1
2020-05-07T13:06:09.000Z
2020-05-07T13:06:09.000Z
src/test.py
marina8888/flame-dilution-method
823c004f7f7ea85ca3e010610b61972a112cf988
[ "MIT" ]
2
2020-05-07T13:05:09.000Z
2020-05-15T16:42:02.000Z
# before running this code pip install pandas, matplotlib and numpy libraries to your environment: from excel_file.classes import Workbook from graph_creator import graph_funcs from excel_file import create_workbook # run file with -W in script parameters. Warnings related to dataslice copies can be ignored because or...
42.588235
149
0.712707
c3e1246896c9c7889851be517cce025f3d427fd3
1,526
py
Python
migrations/versions/da63ba1d58b1_.py
DanielGrams/gsevp
e94034f7b64de76f38754b56455e83092378261f
[ "MIT" ]
1
2021-06-01T14:49:18.000Z
2021-06-01T14:49:18.000Z
migrations/versions/da63ba1d58b1_.py
DanielGrams/gsevp
e94034f7b64de76f38754b56455e83092378261f
[ "MIT" ]
286
2020-12-04T14:13:00.000Z
2022-03-09T19:05:16.000Z
migrations/versions/da63ba1d58b1_.py
DanielGrams/gsevpt
a92f71694388e227e65ed1b24446246ee688d00e
[ "MIT" ]
null
null
null
"""empty message Revision ID: da63ba1d58b1 Revises: 091deace5f08 Create Date: 2020-10-04 17:06:54.502012 """ import sqlalchemy as sa import sqlalchemy_utils from alembic import op from project import dbtypes # revision identifiers, used by Alembic. revision = "da63ba1d58b1" down_revision = "091deace5f08" branch_lab...
29.346154
84
0.650066
9c97792a2a6ab792a432c1ea1f9d7fef41339785
880
py
Python
quark_core_api/common/context_initializers.py
arcticle/Quark
17aa5b5869a9e9c7a04c1a371fef5998f33dc319
[ "MIT" ]
null
null
null
quark_core_api/common/context_initializers.py
arcticle/Quark
17aa5b5869a9e9c7a04c1a371fef5998f33dc319
[ "MIT" ]
null
null
null
quark_core_api/common/context_initializers.py
arcticle/Quark
17aa5b5869a9e9c7a04c1a371fef5998f33dc319
[ "MIT" ]
null
null
null
from quark_core_api.common import object_initializers as initializers from quark_core_api.common import schemas class ContextInitializer(object): null = None def __init__(self, object_initializer, schema): self.object_initializer = object_initializer self.schema = schema @staticmethod ...
36.666667
112
0.777273
9cb371dd86a1d347b7ea2fd6f54839826c75946c
474
py
Python
python/unittest/mock/realpython/patch_as_decorator.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
python/unittest/mock/realpython/patch_as_decorator.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
python/unittest/mock/realpython/patch_as_decorator.py
zeroam/TIL
43e3573be44c7f7aa4600ff8a34e99a65cbdc5d1
[ "MIT" ]
null
null
null
import unittest from unittest.mock import patch from my_calendar import get_holidays from requests.exceptions import Timeout class TestCalendar(unittest.TestCase): @patch("my_calendar.requests") def test_get_holidays_timeout(self, mock_requests): mock_requests.get.side_effect = Timeout with s...
24.947368
55
0.734177
1aea5c57880f9864cc349dcc17ccffb050128da6
413
py
Python
src/onegov/translator_directory/request.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/translator_directory/request.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/translator_directory/request.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from cached_property import cached_property from onegov.org.request import OrgRequest class TranslatorAppRequest(OrgRequest): @cached_property def is_member(self): return self.current_user \ and self.current_user.role == 'member' or False @cached_property def is_editor(self): ...
24.294118
59
0.699758
25784a5620af4f351d81c7ed05743a845b302fdb
1,981
py
Python
frappe-bench/apps/erpnext/erpnext/erpnext_integrations/doctype/gocardless_settings/__init__.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
1
2021-04-29T14:55:29.000Z
2021-04-29T14:55:29.000Z
frappe-bench/apps/erpnext/erpnext/erpnext_integrations/doctype/gocardless_settings/__init__.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/erpnext_integrations/doctype/gocardless_settings/__init__.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
1
2021-04-29T14:39:01.000Z
2021-04-29T14:39:01.000Z
# -*- coding: utf-8 -*- # Copyright (c) 2018, Frappe Technologies and contributors # For license information, please see license.txt from __future__ import unicode_literals import frappe import json import hmac import hashlib @frappe.whitelist(allow_guest=True) def webhooks(): r = frappe.request if not r: return ...
27.901408
159
0.751136
25cf89293e58e2084642b449c2962914d1c19450
16,039
py
Python
official/nlp/cpm/src/cpm.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
77
2021-10-15T08:32:37.000Z
2022-03-30T13:09:11.000Z
official/nlp/cpm/src/cpm.py
leelige/mindspore
5199e05ba3888963473f2b07da3f7bca5b9ef6dc
[ "Apache-2.0" ]
3
2021-10-30T14:44:57.000Z
2022-02-14T06:57:57.000Z
official/nlp/cpm/src/cpm.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...
43.348649
120
0.628655
d399e8eae15107a1616fa2668e5ad88d32fe88db
177
py
Python
Language Proficiency/Python/Itertools/Compress the String!/compress_string.py
xuedong/hacker-rank
ce8a60f80c2c6935b427f9409d7e826ee0d26a89
[ "MIT" ]
1
2021-02-22T17:37:45.000Z
2021-02-22T17:37:45.000Z
Language Proficiency/Python/Itertools/Compress the String!/compress_string.py
xuedong/hacker-rank
ce8a60f80c2c6935b427f9409d7e826ee0d26a89
[ "MIT" ]
null
null
null
Language Proficiency/Python/Itertools/Compress the String!/compress_string.py
xuedong/hacker-rank
ce8a60f80c2c6935b427f9409d7e826ee0d26a89
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 from itertools import groupby if __name__ == "__main__": string = input() print(*[(len(list(it)), int(key)) for key, it in groupby(string)])
16.090909
70
0.644068
d3ab8eade0b4111a8b5b23ded41f66a742823be1
8,696
py
Python
bindings/python/ensmallen/datasets/yue.py
LucaCappelletti94/EnsmallenGraph
572532b6d3f4352bf58f9ccca955376acd95fd89
[ "MIT" ]
null
null
null
bindings/python/ensmallen/datasets/yue.py
LucaCappelletti94/EnsmallenGraph
572532b6d3f4352bf58f9ccca955376acd95fd89
[ "MIT" ]
null
null
null
bindings/python/ensmallen/datasets/yue.py
LucaCappelletti94/EnsmallenGraph
572532b6d3f4352bf58f9ccca955376acd95fd89
[ "MIT" ]
null
null
null
"""Module providing graphs available from Yue. References ---------- Please cite: ```bib @article{yue2020graph, title={Graph embedding on biomedical networks: methods, applications and evaluations}, author={Yue, Xiang and Wang, Zhen and Huang, Jingong and Parthasarathy, Srinivasan and Moosavinasab, Soheil and Hua...
36.233333
191
0.674448
6c94dce8fe64b80a918d9fba61ce2c94e4dcea65
4,396
py
Python
pandemie/util/event_checker.py
marvinsxtr/informaticup-2020-pandemie
0d37d5236eadfe7bb3cbd7cbfd0e1b7afca74c89
[ "MIT" ]
null
null
null
pandemie/util/event_checker.py
marvinsxtr/informaticup-2020-pandemie
0d37d5236eadfe7bb3cbd7cbfd0e1b7afca74c89
[ "MIT" ]
null
null
null
pandemie/util/event_checker.py
marvinsxtr/informaticup-2020-pandemie
0d37d5236eadfe7bb3cbd7cbfd0e1b7afca74c89
[ "MIT" ]
1
2020-03-28T00:02:41.000Z
2020-03-28T00:02:41.000Z
import os.path from pandemie.util.encoding import filter_unicode class EventChecker: """ Module to check in a given dataset for new event-types """ name_path = "data/event_names.dat" pathogen_path = "data/pathogen_names.dat" def __init__(self): self.events = [] self.pathogens ...
37.254237
117
0.572793
6ca16eb862d2f226ef4bed731e6432b820b1b03d
3,200
py
Python
python/coursera_python/MICHIGAN/wikicrawler/fin5.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
16
2018-11-26T08:39:42.000Z
2019-05-08T10:09:52.000Z
python/coursera_python/MICHIGAN/wikicrawler/fin5.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
8
2020-05-04T06:29:26.000Z
2022-02-12T05:33:16.000Z
python/coursera_python/MICHIGAN/wikicrawler/fin5.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
5
2020-02-11T16:02:21.000Z
2021-02-05T07:48:30.000Z
# To run this, you can install BeautifulSoup # https://pypi.python.org/pypi/beautifulsoup4 # Or download the file # http://www.py4e.com/code3/bs4.zip # and unzip it in the same directory as this file import sqlite3 conn = sqlite3.connect('wiki1.sqlite') cur = conn.cursor() cur.executescript(''' CREATE TABLE IF NOT ...
19.753086
75
0.556875
9f02203f2a87683cfa03aa95611bc5f7e32589f3
656
py
Python
backend/migrations/versions/dbcd7d8df928_.py
davidoesch/platform
1eb6f98568cab82e28bd5350beab2042b22d99ed
[ "MIT" ]
null
null
null
backend/migrations/versions/dbcd7d8df928_.py
davidoesch/platform
1eb6f98568cab82e28bd5350beab2042b22d99ed
[ "MIT" ]
null
null
null
backend/migrations/versions/dbcd7d8df928_.py
davidoesch/platform
1eb6f98568cab82e28bd5350beab2042b22d99ed
[ "MIT" ]
null
null
null
"""empty message Revision ID: dbcd7d8df928 Revises: e8f14ef94128 Create Date: 2018-08-30 15:02:24.309423 """ from alembic import op import sqlalchemy as sa # revision identifiers, used by Alembic. revision = 'dbcd7d8df928' down_revision = 'e8f14ef94128' branch_labels = None depends_on = None def upgrade(): # ...
22.62069
81
0.692073
46f3557a49bada9c967ef1a5b21c6904dab43578
688
py
Python
CS208/exercise1/nlogn.py
Wycers/Codelib
86d83787aa577b8f2d66b5410e73102411c45e46
[ "MIT" ]
22
2018-08-07T06:55:10.000Z
2021-06-12T02:12:19.000Z
CS208/exercise1/nlogn.py
Wycers/Codelib
86d83787aa577b8f2d66b5410e73102411c45e46
[ "MIT" ]
28
2020-03-04T23:47:22.000Z
2022-02-26T18:50:00.000Z
CS208/exercise1/nlogn.py
Wycers/Codelib
86d83787aa577b8f2d66b5410e73102411c45e46
[ "MIT" ]
4
2019-11-09T15:41:26.000Z
2021-10-10T08:56:57.000Z
import random def merge(a, b): res = [] i = j = 0 while j < len(a) and i < len(b): if a[j] < b[i]: res.append(a[j]) j += 1 else: res.append(b[i]) i += 1 if j == len(a): for i in b[i:]: res.append(i) else: ...
16
36
0.434593
37b06e4a0e025eeccd57415ea76d3f390e68e5bb
1,363
py
Python
Implementierung/ResearchEnvironment/AuthorizationManagement/migrations/0003_auto_20180125_1450.py
Sashks/PSE
ae2d8133a85563c33583f15b9ba76a3a2bf0c762
[ "MIT" ]
null
null
null
Implementierung/ResearchEnvironment/AuthorizationManagement/migrations/0003_auto_20180125_1450.py
Sashks/PSE
ae2d8133a85563c33583f15b9ba76a3a2bf0c762
[ "MIT" ]
null
null
null
Implementierung/ResearchEnvironment/AuthorizationManagement/migrations/0003_auto_20180125_1450.py
Sashks/PSE
ae2d8133a85563c33583f15b9ba76a3a2bf0c762
[ "MIT" ]
null
null
null
# Generated by Django 2.0 on 2018-01-25 13:50 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('AuthorizationManagement', '0002_auto_20180122_2016'), ] operations = [ migrations.RenameField( mo...
34.075
125
0.635363
20ee7cf215b8058bbfcf01c40f09c55397675a10
995
py
Python
frappe-bench/apps/erpnext/erpnext/config/agriculture.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/config/agriculture.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
frappe-bench/apps/erpnext/erpnext/config/agriculture.py
Semicheche/foa_frappe_docker
a186b65d5e807dd4caf049e8aeb3620a799c1225
[ "MIT" ]
null
null
null
from __future__ import unicode_literals from frappe import _ def get_data(): return [ { "label": _("Crops & Lands"), "items": [ { "type": "doctype", "name": "Crop", }, { "type": "doctype", "name": "Crop Cycle", }, { "type": "doctype", "name": "Land Unit", ...
15.307692
45
0.429146
45865840cf18b3d10b58d3c045e4867c1d33bb9f
490
py
Python
measure/system/TimeSystemMeter.py
surfmachine/language-detection
b44fbb4c7b59fc70388197653060cee67b5a2ee7
[ "MIT" ]
null
null
null
measure/system/TimeSystemMeter.py
surfmachine/language-detection
b44fbb4c7b59fc70388197653060cee67b5a2ee7
[ "MIT" ]
null
null
null
measure/system/TimeSystemMeter.py
surfmachine/language-detection
b44fbb4c7b59fc70388197653060cee67b5a2ee7
[ "MIT" ]
null
null
null
import os import sys sys.path.append(os.path.dirname(__file__)) from measure.StopWatch import StopWatch from measure.system.AbstractSystemMeter import AbstractSystemMeter class TimeSystemMeter(AbstractSystemMeter): def __init__(self): AbstractSystemMeter.__init__(self, "Time") self.stop_watch = ...
21.304348
66
0.720408
b30bb2218c19e7f10854fdf02cb93b4dcb245063
529
py
Python
the_platform/views.py
Thames1990/BadBatBets
8dffb69561668b8991bf4103919e4b254d4ca56a
[ "MIT" ]
null
null
null
the_platform/views.py
Thames1990/BadBatBets
8dffb69561668b8991bf4103919e4b254d4ca56a
[ "MIT" ]
null
null
null
the_platform/views.py
Thames1990/BadBatBets
8dffb69561668b8991bf4103919e4b254d4ca56a
[ "MIT" ]
null
null
null
from django.shortcuts import render from profiles.util import user_authenticated def error403(request): return render(request, 'the_platform/403.html', { 'user_authenticated': user_authenticated(request.user) }) def error404(request): return render(request, 'the_platform/404.html', { 'u...
24.045455
62
0.718336
44444cc18411d2e0841bbc03761d2b02336634a9
1,132
py
Python
pyScript/custom_src/custom_nodes/SetVar_NodeInstance.py
Shirazbello/Pyscriptining
0f2c80a9bb10477d65966faeccc7783f20385c1b
[ "MIT" ]
null
null
null
pyScript/custom_src/custom_nodes/SetVar_NodeInstance.py
Shirazbello/Pyscriptining
0f2c80a9bb10477d65966faeccc7783f20385c1b
[ "MIT" ]
null
null
null
pyScript/custom_src/custom_nodes/SetVar_NodeInstance.py
Shirazbello/Pyscriptining
0f2c80a9bb10477d65966faeccc7783f20385c1b
[ "MIT" ]
null
null
null
from custom_src.NodeInstance import NodeInstance from custom_src.Node import Node # USEFUL # self.input(index) <- access to input data # self.outputs[index].set_val(val) <- set output data port value # self.main_widget <- access to main widget class SetVar_NodeInstance(Node...
29.025641
83
0.633392
922a5c2919e6c9e6ef900adf52bbba23db71b896
5,908
py
Python
HackTon/hackton.py
GitInitDev/ZohoUniv
966704837e65f58b52492b56d08e7958df3d220a
[ "Unlicense" ]
null
null
null
HackTon/hackton.py
GitInitDev/ZohoUniv
966704837e65f58b52492b56d08e7958df3d220a
[ "Unlicense" ]
null
null
null
HackTon/hackton.py
GitInitDev/ZohoUniv
966704837e65f58b52492b56d08e7958df3d220a
[ "Unlicense" ]
null
null
null
import os import sys import subprocess from colorama import Fore, Back, Style #Show Text print(Fore.RED+Back.GREEN+""" .----------------. .----------------. .----------------. .----------------. .----------------. .----------------. .-----------------. | .--------------. | .--------------. | .--------------. | .------...
39.386667
137
0.453791
2be510d85a5bf468181b7c13f1f72bec742f95a1
2,300
py
Python
src/bo4e/com/fremdkostenposition.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
1
2022-03-02T12:49:44.000Z
2022-03-02T12:49:44.000Z
src/bo4e/com/fremdkostenposition.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
21
2022-02-04T07:38:46.000Z
2022-03-28T14:01:53.000Z
src/bo4e/com/fremdkostenposition.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
null
null
null
""" Contains Fremdkostenposition and corresponding marshmallow schema for de-/serialization """ from typing import Optional import attr from marshmallow import fields from bo4e.com.kostenposition import Kostenposition, KostenpositionSchema # pylint: disable=too-few-public-methods, too-many-instance-attributes @attr...
40.350877
193
0.751304
a63bd6fa56eab427b017e2d734e26b8caf1028f1
38
py
Python
src/main/python/tools/__init__.py
gwdgithubnom/ox-patient
cddf4fe381cb4506db8e0d62803dd2044cf7ad92
[ "MIT" ]
null
null
null
src/main/python/tools/__init__.py
gwdgithubnom/ox-patient
cddf4fe381cb4506db8e0d62803dd2044cf7ad92
[ "MIT" ]
null
null
null
src/main/python/tools/__init__.py
gwdgithubnom/ox-patient
cddf4fe381cb4506db8e0d62803dd2044cf7ad92
[ "MIT" ]
1
2021-04-14T00:45:38.000Z
2021-04-14T00:45:38.000Z
__all__ = ["tools", "view", "cluster"]
38
38
0.605263
5b905ae18c563eafd51c710228d18f659fc26a05
2,218
py
Python
tests/test_angebotsposition.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
1
2022-03-02T12:49:44.000Z
2022-03-02T12:49:44.000Z
tests/test_angebotsposition.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
21
2022-02-04T07:38:46.000Z
2022-03-28T14:01:53.000Z
tests/test_angebotsposition.py
bo4e/BO4E-python
28b12f853c8a496d14b133759b7aa2d6661f79a0
[ "MIT" ]
null
null
null
from decimal import Decimal import pytest # type:ignore[import] from bo4e.com.angebotsposition import Angebotsposition, AngebotspositionSchema from bo4e.com.betrag import Betrag from bo4e.com.menge import Menge from bo4e.com.preis import Preis from bo4e.enum.mengeneinheit import Mengeneinheit from bo4e.enum.waehrung...
40.327273
104
0.594229
5bd1feafc75852b7144fe8f496f50583bbfaf90b
2,590
py
Python
Co-Simulation/Sumo/sumo-1.7.0/tools/net/xmlnodes_applyOffset.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/net/xmlnodes_applyOffset.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/net/xmlnodes_applyOffset.py
uruzahe/carla
940c2ab23cce1eda1ef66de35f66b42d40865fb1
[ "MIT" ]
1
2020-11-20T19:31:26.000Z
2020-11-20T19:31:26.000Z
#!/usr/bin/env python # Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo # Copyright (C) 2009-2020 German Aerospace Center (DLR) and others. # This program and the accompanying materials are made available under the # terms of the Eclipse Public License 2.0 which is available at # https://www.ec...
34.533333
88
0.654054
752b13145c59530b5b097f834238a81ced30da54
7,128
py
Python
interpolation.py
patcher1/numerik
ad24c8522d61970a3a881e034a7940d43ba486be
[ "BSD-3-Clause" ]
null
null
null
interpolation.py
patcher1/numerik
ad24c8522d61970a3a881e034a7940d43ba486be
[ "BSD-3-Clause" ]
null
null
null
interpolation.py
patcher1/numerik
ad24c8522d61970a3a881e034a7940d43ba486be
[ "BSD-3-Clause" ]
1
2019-10-01T14:36:03.000Z
2019-10-01T14:36:03.000Z
# -*- encoding: utf-8 -*- import numpy as np import numpy.linalg import scipy import scipy.linalg import numpy.linalg import matplotlib.pyplot as plt from helpers import evalchebexp, chebexp, clenshaw import numpy.random # Polynominterpolation def monom(f, a, b, N, M): """ Interpolation mit Mono...
29.454545
99
0.536616
ca0ccd67a2944eddc158c86ca1d6ebc03743a17c
1,236
py
Python
chapter_ten/deploying_with_a_private_github_repository/pip_package/src/fib_calcs/__init__.py
PacktPublishing/Speed-up-your-Python-with-Rust
1fce5fb59ea966015768e7eca51c0e31d69531ec
[ "MIT" ]
21
2021-09-10T12:46:26.000Z
2022-03-23T02:50:39.000Z
chapter_ten/fusing_rust_with_data_access/pip_package/src/fib_calcs/__init__.py
PacktPublishing/Speed-up-your-Python-with-Rust
1fce5fb59ea966015768e7eca51c0e31d69531ec
[ "MIT" ]
null
null
null
chapter_ten/fusing_rust_with_data_access/pip_package/src/fib_calcs/__init__.py
PacktPublishing/Speed-up-your-Python-with-Rust
1fce5fb59ea966015768e7eca51c0e31d69531ec
[ "MIT" ]
6
2021-09-02T08:32:37.000Z
2022-03-17T21:15:25.000Z
import time from flitton_fib_rs.flitton_fib_rs import fibonacci_number from fib_calcs.enums import CalculationMethod from fib_calcs.fib_calculation import FibCalculation def _time_process(processor, input_number): start = time.time() calc = processor(input_number) finish = time.time() time_taken = fin...
29.428571
70
0.694175
b6d22cbb50b1bb01d95efd4bf5f74368f111b794
1,159
py
Python
Python/numpy/np_create_diff_array.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
Python/numpy/np_create_diff_array.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
Python/numpy/np_create_diff_array.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
import numpy as np # Erstellen arr = np.array([1, 2, 3, 4]) arr = np.ones(42) arr = np.zeros(42) arr = np.arange(-42, 123, 3) arr = np.arange(-42.5, 123.2, 3.1) # Schrittweite arr = np.linspace(-42.5, 1337.2, 100) # Anzahl an Zahlen # Überall spezifischer Wert arr = np.full((2, 3), 42) # diagonalmatrix mit 1 in Diag...
20.333333
71
0.623814
61007021ce468cd105c7a6f87bdb12c9dc3adc26
180
py
Python
exercises/de/exc_01_02_01.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
2
2020-07-07T01:46:37.000Z
2021-04-20T03:19:43.000Z
exercises/de/exc_01_02_01.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
exercises/de/exc_01_02_01.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
# Importiere spaCy import ____ # Erstelle ein deutsches nlp-Objekt nlp = ____ # Verarbeite einen Text doc = nlp("Liebe Grüße!") # Drucke den Text des Dokuments print(____.text)
15
35
0.744444
1ebe422f09bc23b7cac14d368a526a22b7270f84
1,404
py
Python
packages/watchmen-inquiry-kernel/src/watchmen_inquiry_kernel/meta/report_service.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-inquiry-kernel/src/watchmen_inquiry_kernel/meta/report_service.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
packages/watchmen-inquiry-kernel/src/watchmen_inquiry_kernel/meta/report_service.py
Indexical-Metrics-Measure-Advisory/watchmen
c54ec54d9f91034a38e51fd339ba66453d2c7a6d
[ "MIT" ]
null
null
null
from typing import Optional from watchmen_auth import PrincipalService from watchmen_inquiry_kernel.common import InquiryKernelException from watchmen_meta.common import ask_meta_storage, ask_snowflake_generator from watchmen_meta.console import ReportService as ReportStorageService from watchmen_model.common import R...
39
110
0.797721
1538b69730715b354556382be6f6343f107847d6
14,243
py
Python
Modell/CSV/diagramm_sprache_genauigkeit.py
NoahEmbedded/EmbeddedKWD
2380d56b0b75bae4fedeb60885358332766f7319
[ "MIT" ]
null
null
null
Modell/CSV/diagramm_sprache_genauigkeit.py
NoahEmbedded/EmbeddedKWD
2380d56b0b75bae4fedeb60885358332766f7319
[ "MIT" ]
null
null
null
Modell/CSV/diagramm_sprache_genauigkeit.py
NoahEmbedded/EmbeddedKWD
2380d56b0b75bae4fedeb60885358332766f7319
[ "MIT" ]
null
null
null
import matplotlib.pyplot as plt import numpy as np #Input = Sprache #datenTF #output sprache spIn_spOut = np.array([100.0,100.0,0.61,99.84,99.17,100.0,98.2,100.0,100.0,100.0,92.67,99.98,100.0,99.84,100.0,96.43,99.99,100.0,99.97,97.62,100.0,100.0,92.77,100.0,99.93,96.97,100.0,100.0,100.0,100.0,94.32,97.25,88.54,100.0,7...
76.165775
1,801
0.588078
01d61302c274f206b3d7838f83dab5db0a465a43
10,907
py
Python
examples/myqueryset/prefetch_related_/tests.py
zhengtong0898/django-decode
69680853a4a5b07f6a9c4b65c7d86b2d401a92b1
[ "MIT" ]
5
2020-07-14T07:48:10.000Z
2021-12-20T21:20:10.000Z
examples/myqueryset/prefetch_related_/tests.py
zhengtong0898/django-decode
69680853a4a5b07f6a9c4b65c7d86b2d401a92b1
[ "MIT" ]
7
2021-03-26T03:13:38.000Z
2022-03-12T00:42:03.000Z
examples/myqueryset/prefetch_related_/tests.py
zhengtong0898/django-decode
69680853a4a5b07f6a9c4b65c7d86b2d401a92b1
[ "MIT" ]
1
2021-02-16T07:04:25.000Z
2021-02-16T07:04:25.000Z
from django.test import TestCase, TransactionTestCase from .models import Pizza, Topping, Restaurant # Create your tests here. class SimpleTest(TransactionTestCase): reset_sequences = True def test_a_normal_all(self): # 准备数据 ham = Topping.objects.create(name="ham") pineapple = Toppin...
47.628821
114
0.640781
178747f780e1f1ac2eda8b5d36d0a86812e2b401
3,715
py
Python
src/ingestion/collector.py
monosidev/monosi
a88b689fc74010b10dbabb32f4b2bdeae865f4d5
[ "Apache-2.0" ]
156
2021-11-19T18:50:14.000Z
2022-03-31T19:48:59.000Z
src/ingestion/collector.py
monosidev/monosi
a88b689fc74010b10dbabb32f4b2bdeae865f4d5
[ "Apache-2.0" ]
30
2021-12-27T19:30:56.000Z
2022-03-30T17:49:00.000Z
src/ingestion/collector.py
monosidev/monosi
a88b689fc74010b10dbabb32f4b2bdeae865f4d5
[ "Apache-2.0" ]
14
2022-01-17T23:24:34.000Z
2022-03-29T09:27:47.000Z
from dataclasses import dataclass from enum import Enum import itertools import logging from typing import Any, Dict, List, Optional from mashumaro.serializer.base.dict import DataClassDictMixin from ingestion.sources import SourceFactory from ingestion.sources.base import Source from ingestion.task import Task from...
32.304348
117
0.607537
bd7e55ca2e0034fe83dc7afdca0e784c41003084
564
py
Python
source/pkgsrc/graphics/py-Pillow/patches/patch-setup.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
1
2021-11-20T22:46:39.000Z
2021-11-20T22:46:39.000Z
source/pkgsrc/graphics/py-Pillow/patches/patch-setup.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
null
null
null
source/pkgsrc/graphics/py-Pillow/patches/patch-setup.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
null
null
null
$NetBSD: patch-setup.py,v 1.23 2021/03/10 18:43:30 adam Exp $ Fix finding zlib.h. --- setup.py.orig 2021-03-06 05:17:25.000000000 +0000 +++ setup.py @@ -561,7 +561,7 @@ class pil_build_ext(build_ext): if feature.want("zlib"): _dbg("Looking for zlib") - if _find_include_file(self, "z...
35.25
83
0.572695
bde26304a6a1bd79758249adf04c68a2cbf38167
8,910
py
Python
src/onegov/gazette/views/users.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/gazette/views/users.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/gazette/views/users.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from datetime import datetime from io import BytesIO from morepath import redirect from morepath.request import Response from onegov.core.crypto import random_password from onegov.core.security import Private from onegov.core.security import Secret from onegov.core.templates import render_template from onegov.gazette i...
26.837349
79
0.582941
da674c61d76038aa24fa07e182972e481eac0642
188
py
Python
server/apps/utils/__init__.py
Mayandev/django_morec
8d115f76ad69d7aa78b07dc06aa7047979ad134b
[ "MIT" ]
129
2019-04-20T08:23:25.000Z
2022-03-14T10:02:23.000Z
server/apps/utils/__init__.py
heartplus/django_morec
8d115f76ad69d7aa78b07dc06aa7047979ad134b
[ "MIT" ]
9
2019-05-19T15:06:17.000Z
2021-12-14T06:47:14.000Z
server/apps/utils/__init__.py
heartplus/django_morec
8d115f76ad69d7aa78b07dc06aa7047979ad134b
[ "MIT" ]
34
2019-05-06T06:37:17.000Z
2021-12-09T02:27:58.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- # @Time : 2019-04-22 09:58 # @Author : Mayandev # @Site : https://github.com/Mayandev/ # @File : __init__.py.py # @Software: PyCharm
26.857143
41
0.595745
da74daf0d502f822ea9e4be22eb4185846f259fd
620
py
Python
agspiel/api/aktie.py
KingKevin23/agspiel-python-api
33e74ff6bee2f9ce353da757bdb99e929acc1a13
[ "MIT" ]
1
2021-03-09T21:37:41.000Z
2021-03-09T21:37:41.000Z
agspiel/api/aktie.py
KingKevin23/agspiel-python-api
33e74ff6bee2f9ce353da757bdb99e929acc1a13
[ "MIT" ]
4
2020-11-13T19:34:58.000Z
2021-07-24T16:25:27.000Z
agspiel/api/aktie.py
KingKevin23/agspiel-python-api
33e74ff6bee2f9ce353da757bdb99e929acc1a13
[ "MIT" ]
1
2020-08-24T14:38:18.000Z
2020-08-24T14:38:18.000Z
# Copyright (c) 2021 | KingKevin23 (@kingkevin023) class Aktie: def __init__(self, wkn: int, stueckzahl: int): self.wkn: int = wkn self.stueckzahl: int = stueckzahl @property def wkn(self) -> int: return self._wkn @wkn.setter def wkn(self, value: int): self._wkn =...
22.962963
51
0.620968
da88cd332b72c2eda3ac93617cb4fce6d2ac15f4
5,224
py
Python
pylokid/library/emailhandling.py
tobru/pylokid
15b46d19c62ef62c068873554cafdc5b1bc0072a
[ "MIT" ]
3
2020-03-03T07:38:24.000Z
2021-07-21T22:40:41.000Z
pylokid/library/emailhandling.py
tobru/pylokid
15b46d19c62ef62c068873554cafdc5b1bc0072a
[ "MIT" ]
10
2018-01-02T17:46:06.000Z
2021-12-13T20:58:38.000Z
pylokid/library/emailhandling.py
tobru/pylokid
15b46d19c62ef62c068873554cafdc5b1bc0072a
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 """ E-Mail / IMAP handling """ import os import logging import re import email import email.parser import socket import imaplib _EMAIL_SUBJECTS = '(OR OR SUBJECT "Einsatzausdruck_FW" SUBJECT "Einsatzprotokoll" SUBJECT "Einsatzrapport" UNSEEN)' class EmailHandling: """ Email handling """ ...
36.531469
115
0.549196
e55205d896ac649e6223e7d3358e62a688124ef3
503
py
Python
Flask/Courses/Flask-Tutorials.Tech-With-Tim/04-Http-Methods/main.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
Flask/Courses/Flask-Tutorials.Tech-With-Tim/04-Http-Methods/main.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
Flask/Courses/Flask-Tutorials.Tech-With-Tim/04-Http-Methods/main.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
from flask import Flask, redirect, url_for, render_template, request app = Flask(__name__) @app.route("/") def home(): return render_template("index.html") @app.route("/login", methods=["POST", "GET"]) def login(): if request.method == "POST": return redirect(url_for("user", name=request.form["nm"...
18.62963
68
0.634195
e5a828bd3c50a96203d1bedfd58b42dff4452cb1
1,320
py
Python
tests/test_post.py
CsabaWirnhardt/cbm
1822addd72881057af34ac6a7c2a1f02ea511225
[ "BSD-3-Clause" ]
17
2021-01-18T07:27:01.000Z
2022-03-10T12:26:21.000Z
tests/test_post.py
CsabaWirnhardt/cbm
1822addd72881057af34ac6a7c2a1f02ea511225
[ "BSD-3-Clause" ]
4
2021-04-29T11:20:44.000Z
2021-12-06T10:19:17.000Z
tests/test_post.py
CsabaWirnhardt/cbm
1822addd72881057af34ac6a7c2a1f02ea511225
[ "BSD-3-Clause" ]
47
2021-01-21T08:25:22.000Z
2022-03-21T14:28:42.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # This file is part of CbM (https://github.com/ec-jrc/cbm). # Author : Guido Lemoine # Credits : GTCAP Team # Copyright : 2021 European Commission, Joint Research Centre # License : 3-Clause BSD import requests import imgLib username = 'YOURUSERNAME' password =...
28.085106
76
0.687879
f90e4a4e104c3d160b946b4b0a978a18353ad848
698
py
Python
auth.py
VNCompany/PyDafm
9634f5428b9f3739dbf7c159daad34856b372165
[ "Unlicense" ]
null
null
null
auth.py
VNCompany/PyDafm
9634f5428b9f3739dbf7c159daad34856b372165
[ "Unlicense" ]
null
null
null
auth.py
VNCompany/PyDafm
9634f5428b9f3739dbf7c159daad34856b372165
[ "Unlicense" ]
null
null
null
from PyQt5.QtWidgets import QDialog, QMessageBox from PyQt5 import uic from dbm import * from main import Main class Authorization(QDialog): def __init__(self): super().__init__() uic.loadUi("designer/authorization.ui", self) self.setWindowTitle("Вход") self.dbm = DataBaseManager()...
29.083333
83
0.62894
006d8452b2d8363128fa4487b81d4572546f60ce
7,801
py
Python
tests/onegov/fsi/test_views_subscription.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/fsi/test_views_subscription.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
tests/onegov/fsi/test_views_subscription.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from onegov.fsi.collections.course_event import CourseEventCollection from onegov.fsi.models import CourseSubscription, CourseAttendee, CourseEvent, \ Course from onegov.user import User def test_locked_course_event_reservations(client_with_db): client = client_with_db client.login_admin() session = c...
36.283721
80
0.690296
97cbbdf2e3a58bc7be3a4b00b0b1662d1c8717c7
633
py
Python
crawlab/constants/spider.py
anhilo/crawlab
363f4bf7a4ccc192a99850998c1bd0fc363832a1
[ "BSD-3-Clause" ]
1
2019-08-20T14:26:39.000Z
2019-08-20T14:26:39.000Z
crawlab/constants/spider.py
anhilo/crawlab
363f4bf7a4ccc192a99850998c1bd0fc363832a1
[ "BSD-3-Clause" ]
null
null
null
crawlab/constants/spider.py
anhilo/crawlab
363f4bf7a4ccc192a99850998c1bd0fc363832a1
[ "BSD-3-Clause" ]
null
null
null
class SpiderType: CONFIGURABLE = 'configurable' CUSTOMIZED = 'customized' class LangType: PYTHON = 'python' JAVASCRIPT = 'javascript' JAVA = 'java' GO = 'go' OTHER = 'other' class CronEnabled: ON = 1 OFF = 0 class CrawlType: LIST = 'list' DETAIL = 'detail' LIST_DETA...
14.066667
33
0.600316
de12388bc1898ceba313de7551a8a035a0408142
4,516
py
Python
Inverted-Index-Construction/03-semi-human-getter.py
liao2000/Information-Retrieval-NCHU
a800aefec442fd83514c2091d0da0a2e1a9815b7
[ "MIT" ]
null
null
null
Inverted-Index-Construction/03-semi-human-getter.py
liao2000/Information-Retrieval-NCHU
a800aefec442fd83514c2091d0da0a2e1a9815b7
[ "MIT" ]
null
null
null
Inverted-Index-Construction/03-semi-human-getter.py
liao2000/Information-Retrieval-NCHU
a800aefec442fd83514c2091d0da0a2e1a9815b7
[ "MIT" ]
null
null
null
# 綜合兩種方法將兩者不同之處之有爭議之處 print 出來 # 以工人智慧判定結果 import json from ckiptagger import data_utils, WS import sqlite3 database = './table-v2.db' conn = sqlite3.connect(database) cursor = conn.cursor() inputs = ["apple", "Volkswagen", "凡爾賽宮", "洛杉磯市", "東京迪士尼樂園", "史丹福橋球場"] #inputs = ["人心惶惶", "縱火犯", "印尼羽毛球", "生長激素", "胰高血糖素"] input...
30.106667
99
0.523251
821e77febc3f8eebf1af21205bf59bc51b206304
1,222
py
Python
elements/python/8/9/soln.py
mmcloughlin/problems
6095842ffe007a12ec8c2093850515aa4e046616
[ "MIT" ]
11
2019-02-08T06:54:34.000Z
2021-08-07T18:57:39.000Z
elements/python/8/9/soln.py
mmcloughlin/problems
6095842ffe007a12ec8c2093850515aa4e046616
[ "MIT" ]
1
2019-05-21T08:14:10.000Z
2019-05-21T08:14:10.000Z
elements/python/8/9/soln.py
mmcloughlin/problems
6095842ffe007a12ec8c2093850515aa4e046616
[ "MIT" ]
null
null
null
class Node(object): def __init__(self, x, nxt): self.x = x self.next = nxt def delete_kth_last(n, k): """ Delete the kth last element from the linked list n. The index k is 0-up, so k=0 will remove the last element. """ # step ahead k+2 times and pick up a "trailing" node t...
18.515152
76
0.550736
41460ced4e30736e983335b578696a6919c1a9a4
645
py
Python
envs/rpg/levels/medium_tutorial.py
etigerstudio/zilong-on-fire
5144a471b2d39ea38a47d394e648de00dd13cd8b
[ "MIT" ]
2
2021-01-07T01:10:49.000Z
2022-01-21T09:37:16.000Z
envs/rpg/levels/medium_tutorial.py
etigerstudio/zilong-on-fire
5144a471b2d39ea38a47d394e648de00dd13cd8b
[ "MIT" ]
null
null
null
envs/rpg/levels/medium_tutorial.py
etigerstudio/zilong-on-fire
5144a471b2d39ea38a47d394e648de00dd13cd8b
[ "MIT" ]
null
null
null
from envs.rpg.level import Level from envs.rpg.entities.actor import Actor from envs.rpg.entities.treasure import Treasure from envs.rpg.entities.spike import Spike from random import randrange class MediumTutorial(Level): @staticmethod def init(): entities = [ Actor([randrange(6), randran...
25.8
54
0.530233
ec383a5f1a11445ff733d82129639b63180f5a4f
1,864
py
Python
ie/pycorenlp/corenlp.py
iecasszyjy/tweet_search-master
e4978521a39964c22ae46bf35d6ff17710e8e6c6
[ "MIT" ]
null
null
null
ie/pycorenlp/corenlp.py
iecasszyjy/tweet_search-master
e4978521a39964c22ae46bf35d6ff17710e8e6c6
[ "MIT" ]
2
2021-03-31T18:54:16.000Z
2021-12-13T19:49:08.000Z
ie/pycorenlp/corenlp.py
iecasszyjy/tweet_search-master
e4978521a39964c22ae46bf35d6ff17710e8e6c6
[ "MIT" ]
null
null
null
import json, requests class StanfordCoreNLP: def __init__(self, server_url): if server_url[-1] == '/': server_url = server_url[:-1] self.server_url = server_url def annotate(self, text, properties=None): assert isinstance(text, str) if properties is None: ...
32.701754
86
0.560086
2e537dfaa1dfd4f4ea73395aed5b600574c80e6e
44
py
Python
Python/Books/Learning-Programming-with-Python.Tamim-Shahriar-Subeen/chapter-009.01-list/pg-9.3-list-reverse-method.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
Python/Books/Learning-Programming-with-Python.Tamim-Shahriar-Subeen/chapter-009.01-list/pg-9.3-list-reverse-method.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
Python/Books/Learning-Programming-with-Python.Tamim-Shahriar-Subeen/chapter-009.01-list/pg-9.3-list-reverse-method.py
shihab4t/Books-Code
b637b6b2ad42e11faf87d29047311160fe3b2490
[ "Unlicense" ]
null
null
null
li = [1, 2, 3, 4, 5] li.reverse() print(li)
11
20
0.522727
2e8097a8c829b3c4bb0daf8ed56cbe80c449ae95
257
py
Python
Fastir_Collector/filecatcher/modules/base_modules.py
Unam3dd/Train-2018-2020
afb6ae70fe338cbe55a21b74648d91996b818fa2
[ "MIT" ]
4
2021-04-23T15:39:17.000Z
2021-12-27T22:53:24.000Z
Fastir_Collector/filecatcher/modules/base_modules.py
Unam3dd/Train-2018-2020
afb6ae70fe338cbe55a21b74648d91996b818fa2
[ "MIT" ]
null
null
null
Fastir_Collector/filecatcher/modules/base_modules.py
Unam3dd/Train-2018-2020
afb6ae70fe338cbe55a21b74648d91996b818fa2
[ "MIT" ]
2
2021-04-19T08:28:54.000Z
2022-01-19T13:23:29.000Z
from ConfigParser import ConfigParser class _Base_Modules(object): def __init__(self, path, params): self.path = path self.params = params def process(self): raise NotImplementedError("You must implement a process method")
25.7
72
0.696498
d884cc5ce019cd0d303e271d163ecfaba48b5f62
11,146
py
Python
zencad/geometry_core_installer.py
Spiritdude/zencad
4e63b1a6306dd235f4daa2791b10249f7546c95b
[ "MIT" ]
5
2018-04-11T14:11:40.000Z
2018-09-12T19:03:36.000Z
zencad/geometry_core_installer.py
Spiritdude/zencad
4e63b1a6306dd235f4daa2791b10249f7546c95b
[ "MIT" ]
null
null
null
zencad/geometry_core_installer.py
Spiritdude/zencad
4e63b1a6306dd235f4daa2791b10249f7546c95b
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import traceback import random import string import tempfile import requests import tarfile import zipfile import sys import site import shutil import os from zencad.version import __occt_version__, __pythonocc_version__ python_occ_precompiled_packages = { "linux-64": { "python3.7"...
31.575071
141
0.580746
d8c3a06343f7c4cb5dcbae6d617f7d2b81f1e248
1,316
py
Python
correctDataset.py
moleop/Pyspark_MoviePlots
638b9b715119ed495a6c40660f78aca4739f85b6
[ "MIT" ]
null
null
null
correctDataset.py
moleop/Pyspark_MoviePlots
638b9b715119ed495a6c40660f78aca4739f85b6
[ "MIT" ]
null
null
null
correctDataset.py
moleop/Pyspark_MoviePlots
638b9b715119ed495a6c40660f78aca4739f85b6
[ "MIT" ]
null
null
null
#!usr/bin/env python import csv import re with open('movieplots_fixed.csv', 'w') as outfile: spamwriter = csv.writer(outfile, delimiter=',', quotechar='"') with open('movieplots.csv') as infile: spamreader = csv.reader(infile, delimiter=',', quotechar='"') for row in spamreader: fo...
34.631579
69
0.422492
993bcc671016f90771b8f3de6d3f5f57a1ee0713
4,398
py
Python
andinopy/gpio_zero_devices/gpio_input.py
andino-systems/andinopy
28fc09fbdd67dd690b9b3f80f03a05c342c777e1
[ "Apache-2.0" ]
null
null
null
andinopy/gpio_zero_devices/gpio_input.py
andino-systems/andinopy
28fc09fbdd67dd690b9b3f80f03a05c342c777e1
[ "Apache-2.0" ]
null
null
null
andinopy/gpio_zero_devices/gpio_input.py
andino-systems/andinopy
28fc09fbdd67dd690b9b3f80f03a05c342c777e1
[ "Apache-2.0" ]
null
null
null
# _ _ _ # / \ _ __ __| (_)_ __ ___ _ __ _ _ # / _ \ | '_ \ / _` | | '_ \ / _ \| '_ \| | | | # / ___ \| | | | (_| | | | | | (_) | |_) | |_| | # /_/ \_\_| |_|\__,_|_|_| |_|\___/| .__/ \__, | # |_| |___/ # by Jakob Groß from typing import ...
26.493976
92
0.585493
51bd03850b8dba26f440c3d857344d6d6c84a386
4,659
py
Python
render.py
levjj/wahlomat-visualization
756d41e037a6b1d98e95f3d28a0d8a61a9225a14
[ "MIT" ]
4
2016-09-26T00:01:46.000Z
2019-05-06T16:51:44.000Z
render.py
levjj/wahlomat-visualization
756d41e037a6b1d98e95f3d28a0d8a61a9225a14
[ "MIT" ]
null
null
null
render.py
levjj/wahlomat-visualization
756d41e037a6b1d98e95f3d28a0d8a61a9225a14
[ "MIT" ]
null
null
null
#!/bin/env python3 import argparse import json import logging import os import subprocess import tempfile from typing import List from urllib import request REPO = 'https://raw.githubusercontent.com/gockelhahn/qual-o-mat-data' class Party: def __init__(self, id: int, name: str): self.id = id self.name = n...
37.572581
116
0.64091
8fa1b8d6d36851f3dbff2685bbc872922cf2b14e
3,713
py
Python
test/test_npu/test_network_ops/test_elu.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_elu.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_elu.py
Ascend/pytorch
39849cf72dafe8d2fb68bd1679d8fd54ad60fcfc
[ "BSD-3-Clause" ]
null
null
null
# Copyright 2020 Huawei Technologies Co., Ltd # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to...
46.4125
155
0.611096
85804214e488eb640a8c55410d827a5c70e15eeb
7,890
py
Python
python_experiments/paper_figures/legacy/draw_varying_delta_e.py
RapidsAtHKUST/SimRank
3a601b08f9a3c281e2b36b914e06aba3a3a36118
[ "MIT" ]
8
2020-04-14T23:17:00.000Z
2021-06-21T12:34:04.000Z
python_experiments/paper_figures/legacy/draw_varying_delta_e.py
RapidsAtHKUST/SimRank
3a601b08f9a3c281e2b36b914e06aba3a3a36118
[ "MIT" ]
null
null
null
python_experiments/paper_figures/legacy/draw_varying_delta_e.py
RapidsAtHKUST/SimRank
3a601b08f9a3c281e2b36b914e06aba3a3a36118
[ "MIT" ]
1
2021-01-17T16:26:50.000Z
2021-01-17T16:26:50.000Z
import os import random import matplotlib import numpy as np matplotlib.use("pdf") import matplotlib.pyplot as plt from sklearn import linear_model from paper_figures.legacy.experimental_config import * def ICDE_get_data_file(g_name, number_of_updates): return ICDE14_DIR + g_name + "_%d.txt" % number_of_update...
38.676471
100
0.647782
f1733383d21bc8e27fa25bf2107100ace6a1c828
369
py
Python
rengine/dataset.py
noahsolomon0518/rengine
a544951c6b7dd707586cd3c4f84ddec554f1c96a
[ "MIT" ]
null
null
null
rengine/dataset.py
noahsolomon0518/rengine
a544951c6b7dd707586cd3c4f84ddec554f1c96a
[ "MIT" ]
null
null
null
rengine/dataset.py
noahsolomon0518/rengine
a544951c6b7dd707586cd3c4f84ddec554f1c96a
[ "MIT" ]
null
null
null
import pandas as pd from rengine import data DATASET_FOLDER = data.__file__.rstrip("__init__.py") def get_dataset(filename:str): if(filename.endswith(".xlsx")): df = pd.read_excel(DATASET_FOLDER+filename) else: df = pd.read_csv(DATASET_FOLDER+filename, index_col=0) return df if __name__ ...
23.0625
62
0.704607
2d1bcd9bb6b1948708a66c1287ff483f14f9f5ff
169
py
Python
Chapter2_Python/Variables.py
thisisjako/UdemyTF
ee4102391ed6bd50f764955f732f5740425a9209
[ "MIT" ]
null
null
null
Chapter2_Python/Variables.py
thisisjako/UdemyTF
ee4102391ed6bd50f764955f732f5740425a9209
[ "MIT" ]
null
null
null
Chapter2_Python/Variables.py
thisisjako/UdemyTF
ee4102391ed6bd50f764955f732f5740425a9209
[ "MIT" ]
null
null
null
my_age = 26 # int my_favourite_number = 1337.5 # float my_name = "Jan Schaffranek" # str am_i_cool = True # bool am_i_uncool = False # bool my_state = None # None
24.142857
37
0.692308
248d47a3c8fb54176099ce8830642eade2aa1817
3,343
py
Python
backend/geojson/json_parser.py
whatwouldmarvindo/sweetgeeks
9d7d1103b7aa08aaeecfe32745016b789d922076
[ "MIT" ]
null
null
null
backend/geojson/json_parser.py
whatwouldmarvindo/sweetgeeks
9d7d1103b7aa08aaeecfe32745016b789d922076
[ "MIT" ]
2
2021-09-29T08:15:26.000Z
2021-11-03T09:37:37.000Z
backend/geojson/json_parser.py
whatwouldmarvindo/sweetgeeks
9d7d1103b7aa08aaeecfe32745016b789d922076
[ "MIT" ]
null
null
null
import json import os import pathlib def list_files(): current_path = pathlib.Path(__file__).parent.absolute() / "potential" files = os.listdir(current_path) for file in files.copy(): if not file.endswith(".json"): files.remove(file) #print(files) return files def parse(fil...
30.117117
137
0.574634
24b5e300c0f13e94f0cdf39a79ae8bb1ef8ca6f6
5,252
py
Python
LFA/utils.py
joao-frohlich/BCC
9ed74eb6d921d1280f48680677a2140c5383368d
[ "Apache-2.0" ]
10
2020-12-08T20:18:15.000Z
2021-06-07T20:00:07.000Z
LFA/utils.py
joao-frohlich/BCC
9ed74eb6d921d1280f48680677a2140c5383368d
[ "Apache-2.0" ]
2
2021-06-28T03:42:13.000Z
2021-06-28T16:53:13.000Z
LFA/utils.py
joao-frohlich/BCC
9ed74eb6d921d1280f48680677a2140c5383368d
[ "Apache-2.0" ]
2
2021-01-14T19:59:20.000Z
2021-06-15T11:53:21.000Z
from graphviz import Digraph from random import randrange as r import os from glob import glob def read_quintuple_from_data(file): f = open(file, "r") name = f.readline().replace("\n", "") alphabet = set([symbol for symbol in f.readline().replace("\n", "").split()]) states = set([state for state in f....
29.505618
88
0.542841
7070aa37425d2daa1598cb272ba3d40d9ea59983
1,879
py
Python
Bibliothek/migrations/0001_initial.py
wmles/scholarium.at
d2356b3e475df772382e035ddcb839fc7dae4305
[ "MIT" ]
1
2017-07-24T10:19:36.000Z
2017-07-24T10:19:36.000Z
Bibliothek/migrations/0001_initial.py
wmles/scholarium.at
d2356b3e475df772382e035ddcb839fc7dae4305
[ "MIT" ]
9
2017-07-26T14:16:08.000Z
2022-03-11T23:14:40.000Z
Bibliothek/migrations/0001_initial.py
wmles/scholarium.at
d2356b3e475df772382e035ddcb839fc7dae4305
[ "MIT" ]
1
2017-03-07T12:38:23.000Z
2017-03-07T12:38:23.000Z
# -*- coding: utf-8 -*- # Generated by Django 1.9.11 on 2017-04-26 20:59 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): initial = True dependencies = [ ] operations = [ migrations.CreateModel( name='Buch',...
44.738095
114
0.586482
564f35a11e9cd97f777cc28e367cefcc946f8cbe
3,724
py
Python
gemtown/songs/admin.py
doramong0926/gemtown
2c39284e3c68f0cc11994bed0ee2abaad0ea06b6
[ "MIT" ]
null
null
null
gemtown/songs/admin.py
doramong0926/gemtown
2c39284e3c68f0cc11994bed0ee2abaad0ea06b6
[ "MIT" ]
5
2020-09-04T20:13:39.000Z
2022-02-17T22:03:33.000Z
gemtown/songs/admin.py
doramong0926/gemtown
2c39284e3c68f0cc11994bed0ee2abaad0ea06b6
[ "MIT" ]
null
null
null
from django.contrib import admin from . import models @admin.register(models.Song) class SongAdmin(admin.ModelAdmin): fields = [ 'file', 'contents_hash', 'blockchain_id', 'blockchain_txid', 'confirm_status', "album_title", 'title', 'cover_imag...
17.649289
44
0.443609
566ac29be5d7ed92c6e18dc76b888336c637a341
19,599
py
Python
Packs/AbnormalSecurity/Integrations/AbnormalSecurity/AbnormalSecurity.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
799
2016-08-02T06:43:14.000Z
2022-03-31T11:10:11.000Z
Packs/AbnormalSecurity/Integrations/AbnormalSecurity/AbnormalSecurity.py
diCagri/content
c532c50b213e6dddb8ae6a378d6d09198e08fc9f
[ "MIT" ]
9,317
2016-08-07T19:00:51.000Z
2022-03-31T21:56:04.000Z
Packs/AbnormalSecurity/Integrations/AbnormalSecurity/AbnormalSecurity.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 * import requests requests.packages.urllib3.disable_warnings() class Client(BaseClient): def __init__(self, server_url, verify, proxy, headers, auth): super().__init__(base_url=server_url, verify=verify, proxy=proxy, headers=headers, auth=auth...
35.313514
127
0.704016
3b77a7cc62d8a7b2d55fbcf79e473422fb7574d4
4,940
py
Python
hihope_neptune-oh_hid/00_src/v0.1/third_party/LVM2/daemons/lvmdbusd/background.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/background.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/background.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...
30.121951
74
0.726721
d975a80ca081f39e17dd5a7e210773e9d58f33aa
8,980
py
Python
src/rqt_bt/rqt_bt_widget.py
mortenmj/rqt_bt
9aee7aef14bb22da4ac47d6ce71dc7f8040e16fa
[ "MIT" ]
null
null
null
src/rqt_bt/rqt_bt_widget.py
mortenmj/rqt_bt
9aee7aef14bb22da4ac47d6ce71dc7f8040e16fa
[ "MIT" ]
null
null
null
src/rqt_bt/rqt_bt_widget.py
mortenmj/rqt_bt
9aee7aef14bb22da4ac47d6ce71dc7f8040e16fa
[ "MIT" ]
null
null
null
#!/usr/bin/env python import os import rospy import rospkg import rosgraph.impl.graph from python_qt_binding import loadUi from python_qt_binding.QtCore import Qt, QTimer, Signal, Slot from python_qt_binding.QtGui import QIcon from python_qt_binding.QtWidgets import QFileDialog, QGraphicsScene, QWidget from rqt_grap...
39.734513
145
0.672383
79d2a2b632b274c095c78290f66b9dab314ea6d3
8,981
py
Python
Kaggle-Competitions/CrowdFlower/scripts/helper.py
gopala-kr/ds-notebooks
bc35430ecdd851f2ceab8f2437eec4d77cb59423
[ "MIT" ]
1
2019-05-10T09:16:23.000Z
2019-05-10T09:16:23.000Z
Kaggle-Competitions/CrowdFlower/scripts/helper.py
gopala-kr/ds-notebooks
bc35430ecdd851f2ceab8f2437eec4d77cb59423
[ "MIT" ]
null
null
null
Kaggle-Competitions/CrowdFlower/scripts/helper.py
gopala-kr/ds-notebooks
bc35430ecdd851f2ceab8f2437eec4d77cb59423
[ "MIT" ]
1
2019-10-14T07:30:18.000Z
2019-10-14T07:30:18.000Z
import numpy as np import pandas as pd from nltk.stem import PorterStemmer from nltk.stem.wordnet import WordNetLemmatizer import re from HTMLParser import HTMLParser from sklearn.cross_validation import StratifiedShuffleSplit from bs4 import BeautifulSoup from collections import Counter import difflib from nltk import...
32.422383
283
0.637791
eb8e5906528545f27f9d66400315fc0f72128d7b
268
py
Python
rpi/app.py
dani-9/robbie9-2020
95069da86b346e691d05bddd99ac2092848b1d55
[ "Apache-2.0" ]
null
null
null
rpi/app.py
dani-9/robbie9-2020
95069da86b346e691d05bddd99ac2092848b1d55
[ "Apache-2.0" ]
null
null
null
rpi/app.py
dani-9/robbie9-2020
95069da86b346e691d05bddd99ac2092848b1d55
[ "Apache-2.0" ]
null
null
null
import time from car.car import Car if __name__ == '__main__': car = Car(17, 18, 22, 23, 5, 6, 12, 13, 1920, 1080, 270) for i in range(5): car.move_forward() car.stop() car.take_picture('img_' + str(i) + '.png') time.sleep(1)
22.333333
60
0.552239
eb9d3840619a77eb2bfb823a40605184e3ed66c1
36
py
Python
Crypto/So_called_ECB/src/flag.py
TheReturnOfTheKing/ACTF_Junior_2019
73635a8ea3f741d50153f01ca0ff9ca1a8e4db93
[ "MIT" ]
6
2019-02-27T08:40:05.000Z
2021-01-29T10:04:03.000Z
Crypto/So_called_ECB/src/flag.py
CSUwangj/ACTF_Junior_2019
a2c0ee378ed02c5353176df3490f717f7d04785f
[ "MIT" ]
null
null
null
Crypto/So_called_ECB/src/flag.py
CSUwangj/ACTF_Junior_2019
a2c0ee378ed02c5353176df3490f717f7d04785f
[ "MIT" ]
3
2019-02-27T08:40:15.000Z
2019-03-03T06:07:45.000Z
flag = r"ACTF{Don't_Use_ECB_p13453}"
36
36
0.777778
ba888c30b0472ba188f13cf4f510ba49c0b3aa41
8,143
py
Python
scripts/tweet_mining.py
pratikkumar-jain/Twitter-Mining
228a852f38b8ff8b8c9b86f270d4b530840696f7
[ "MIT" ]
1
2020-10-04T13:46:21.000Z
2020-10-04T13:46:21.000Z
scripts/tweet_mining.py
pratikkumar-jain/Twitter-Mining
228a852f38b8ff8b8c9b86f270d4b530840696f7
[ "MIT" ]
null
null
null
scripts/tweet_mining.py
pratikkumar-jain/Twitter-Mining
228a852f38b8ff8b8c9b86f270d4b530840696f7
[ "MIT" ]
null
null
null
#!/usr/local/bin/python3 """Script to get tweets based on a search query.""" import json import jsonpickle import os import sys import tweepy from datetime import datetime from zipfile import ZipFile def mineTweet(root, api, drive, searchQuery): """Perform the mining operation.""" maxTweets = float('inf') ...
36.191111
79
0.485325
307f9d862a47d55f5f5c983b7a381bced8891935
807
py
Python
elements/python/6/10/soln.py
mmcloughlin/problems
6095842ffe007a12ec8c2093850515aa4e046616
[ "MIT" ]
11
2019-02-08T06:54:34.000Z
2021-08-07T18:57:39.000Z
elements/python/6/10/soln.py
mmcloughlin/problems
6095842ffe007a12ec8c2093850515aa4e046616
[ "MIT" ]
1
2019-05-21T08:14:10.000Z
2019-05-21T08:14:10.000Z
elements/python/6/10/soln.py
mmcloughlin/problems
6095842ffe007a12ec8c2093850515aa4e046616
[ "MIT" ]
null
null
null
import random def product_excluding(A, i): P = 1 for j, a in enumerate(A): if j != i: P *= a return P def max_prod_naive(A): return max([product_excluding(A, i) for i in xrange(len(A))]) def running_product(A): P = 1 left = [] for a in A: left.append(P) ...
17.933333
65
0.586121
cca1c1ac1d359df33da4a17d138e4659492d30f4
197
py
Python
python/python_backup/PRAC_PYTHON/mi.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
16
2018-11-26T08:39:42.000Z
2019-05-08T10:09:52.000Z
python/python_backup/PRAC_PYTHON/mi.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
8
2020-05-04T06:29:26.000Z
2022-02-12T05:33:16.000Z
python/python_backup/PRAC_PYTHON/mi.py
SayanGhoshBDA/code-backup
8b6135facc0e598e9686b2e8eb2d69dd68198b80
[ "MIT" ]
5
2020-02-11T16:02:21.000Z
2021-02-05T07:48:30.000Z
def tuple(t): for t in range(1,n+1,1): max value=mini value=t[0] for i in range(t): if t[i]>max value: max=t[i] if t[i]<mini value: min=t[i] print max, print mini,
17.909091
28
0.543147
ae86ed8f6c03e0dbbfefb97815d4679667620881
139
py
Python
src/aijack/collaborative/fedgems/__init__.py
luoshenseeker/AIJack
4e871a5b3beb4b7c976d38060d6956efcebf880d
[ "MIT" ]
1
2022-03-17T21:17:44.000Z
2022-03-17T21:17:44.000Z
src/aijack/collaborative/fedgems/__init__.py
luoshenseeker/AIJack
4e871a5b3beb4b7c976d38060d6956efcebf880d
[ "MIT" ]
null
null
null
src/aijack/collaborative/fedgems/__init__.py
luoshenseeker/AIJack
4e871a5b3beb4b7c976d38060d6956efcebf880d
[ "MIT" ]
1
2022-03-17T21:17:46.000Z
2022-03-17T21:17:46.000Z
from .api import FedGEMSAPI # noqa: F401 from .client import FedGEMSClient # noqa : F401 from .server import FedGEMSServer # noqa: F401
34.75
48
0.755396
884d9b489a74756cd76b23126bc00ed7eb6870ae
601
py
Python
Problems/Depth-First Search/easy/BalancedBT/balanced_bt.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/BalancedBT/balanced_bt.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
Problems/Depth-First Search/easy/BalancedBT/balanced_bt.py
dolong2110/Algorithm-By-Problems-Python
31ecc7367aaabdd2b0ac0af7f63ca5796d70c730
[ "MIT" ]
null
null
null
from typing import Optional # 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 def isBalanced(self, root: Optional[TreeNode]) -> bool: self.ans = True def check(cur_node: Option...
21.464286
55
0.592346
c98d8bf97d1acb6df4765eae62261269296fffc2
1,218
py
Python
SleekSecurity/layers/plugins/fingerprint/header/cookies.py
GitInitDev/ZohoUniv
966704837e65f58b52492b56d08e7958df3d220a
[ "Unlicense" ]
null
null
null
SleekSecurity/layers/plugins/fingerprint/header/cookies.py
GitInitDev/ZohoUniv
966704837e65f58b52492b56d08e7958df3d220a
[ "Unlicense" ]
null
null
null
SleekSecurity/layers/plugins/fingerprint/header/cookies.py
GitInitDev/ZohoUniv
966704837e65f58b52492b56d08e7958df3d220a
[ "Unlicense" ]
null
null
null
#!/usr/bin/env python # -*- coding:utf-8 -*- # # @name: Wascan - Web Application Scanner # @repo: https://github.com/m4ll0k/Wascan # @author: Momo Outaadi (M4ll0k) # @license: See the file 'LICENSE.txt from re import findall,search,I from lib.utils.printer import * class cookies: def __run__(self,cookie): ...
26.478261
68
0.667488
c9a3f726bea9be7f6f7163a2a3b3a2cd41b8be2c
6,416
py
Python
huffman.py
andrevictor17/aulasRenzoEd
931d73f5d20e7a3c837f175131bf3a271c7f375f
[ "MIT" ]
null
null
null
huffman.py
andrevictor17/aulasRenzoEd
931d73f5d20e7a3c837f175131bf3a271c7f375f
[ "MIT" ]
null
null
null
huffman.py
andrevictor17/aulasRenzoEd
931d73f5d20e7a3c837f175131bf3a271c7f375f
[ "MIT" ]
null
null
null
def calcular_frequencias(s): dicionario = {} if len(s) < 1: return {} else: for n in s: if n in dicionario.keys(): dicionario[n] += 1 else: dicionario[n] = 1 return dicionario def gerar_arvore_de_huffman(s): folhas = [] ...
30.122066
108
0.603491
c9a702fdd7c893b0afdca3397292cc839f153c98
228
py
Python
1299-replace-elements-with-greatest-element-on-right-side/1299-replace-elements-with-greatest-element-on-right-side.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
2
2021-12-05T14:29:06.000Z
2022-01-01T05:46:13.000Z
1299-replace-elements-with-greatest-element-on-right-side/1299-replace-elements-with-greatest-element-on-right-side.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
null
null
null
1299-replace-elements-with-greatest-element-on-right-side/1299-replace-elements-with-greatest-element-on-right-side.py
hyeseonko/LeetCode
48dfc93f1638e13041d8ce1420517a886abbdc77
[ "MIT" ]
null
null
null
class Solution: def replaceElements(self, arr: List[int]) -> List[int]: output=[] for i, val in enumerate(arr[:-1]): output.append(max(arr[(i+1):])) output.append(-1) return output
32.571429
59
0.548246
14d7e0fd5c55be190fe50321121bd93ec27a27ab
2,560
py
Python
research/cv/Auto-DeepLab/src/core/model.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/core/model.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/core/model.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...
40.634921
115
0.601563
0949e60e26a9a2d99d44bb3128d2cb277ef284e7
5,545
py
Python
src/classifier/classifier.py
msei/insectcounter
1e9356e5639789b70c614da6c74307ec2b8c8304
[ "MIT" ]
null
null
null
src/classifier/classifier.py
msei/insectcounter
1e9356e5639789b70c614da6c74307ec2b8c8304
[ "MIT" ]
null
null
null
src/classifier/classifier.py
msei/insectcounter
1e9356e5639789b70c614da6c74307ec2b8c8304
[ "MIT" ]
2
2020-02-05T05:19:18.000Z
2020-02-05T15:04:32.000Z
import os import sys import json import glob import re import soundfile as sf import numpy as np from json import JSONDecodeError try: import tflite_runtime.interpreter as tf except ImportError: import tensorflow as tf class ClassifierModule: """ Class responsible for the classification of wingbeat...
36.480263
110
0.607574
eeb0b7250506026e724a90a5578ecc805cab80b1
9,584
py
Python
test/test_npu/test_network_ops/test_lerp.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_lerp.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_lerp.py
Ascend/pytorch
39849cf72dafe8d2fb68bd1679d8fd54ad60fcfc
[ "BSD-3-Clause" ]
null
null
null
# Copyright 2020 Huawei Technologies Co., Ltd # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to...
42.40708
88
0.613001
097844d06fa6f73445a080c7af0e84ad1e47746e
4,904
py
Python
nutrif-image-parser/parserByFile.py
LADOSSIFPB/nutrif
232f519b708cef199dcc2ef3485240cacf57612c
[ "Apache-2.0" ]
3
2017-09-22T14:33:54.000Z
2020-07-05T20:01:13.000Z
nutrif-image-parser/parserByFile.py
LADOSSIFPB/nutrif
232f519b708cef199dcc2ef3485240cacf57612c
[ "Apache-2.0" ]
2
2017-05-26T23:15:30.000Z
2021-12-14T21:05:56.000Z
nutrif-image-parser/parserByFile.py
LADOSSIFPB/nutrif
232f519b708cef199dcc2ef3485240cacf57612c
[ "Apache-2.0" ]
2
2016-06-02T23:45:41.000Z
2020-07-05T20:01:24.000Z
import os import shutil import glob from PIL import Image def parser(): rootDir = str(input("Informe o diretório de origem:\n")) destDir = str(input("Informe o diretório de destino:\n")) for dirName, subdirList, fileList in os.walk(rootDir): print("Diretório encontrado: %s" % dirName) has_...
38.3125
286
0.554038
61e2be87d610c1f6dde4754cea09eb1807555787
381
py
Python
exercises/zh/test_03_07.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
2
2020-07-07T01:46:37.000Z
2021-04-20T03:19:43.000Z
exercises/zh/test_03_07.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
exercises/zh/test_03_07.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
def test(): assert ( 'after="ner"' in __solution__ ), "你有特别指出将这个组件添加到实体识别器之后吗?" assert ( nlp.pipe_names[5] == "animal_component" ), "你有把组件添加到实体识别器之后吗?" assert len(doc.ents) == 2, "你有正确添加实体了吗?" assert all( ent.label_ == "ANIMAL" for ent in doc.ents ), "你有添加标签ANIMAL吗?" ...
23.8125
50
0.60105
113f028a18fa5be10f8205695f8a87ac54d925b3
1,178
py
Python
Python/zzz_training_challenge/Python_Challenge/solutions/ch04_strings/solutions/ex18_vocal_quiz.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
Python/zzz_training_challenge/Python_Challenge/solutions/ch04_strings/solutions/ex18_vocal_quiz.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
Python/zzz_training_challenge/Python_Challenge/solutions/ch04_strings/solutions/ex18_vocal_quiz.py
Kreijeck/learning
eaffee08e61f2a34e01eb8f9f04519aac633f48c
[ "MIT" ]
null
null
null
# Beispielprogramm für das Buch "Python Challenge" # # Copyright 2020 by Michael Inden def translate_vowel(text, replacement): translated = "" for letter in text: if is_vowel(letter): translated += replacement else: translated += letter return translated def is_...
24.040816
73
0.680815
28a6af7ec73a205342243326af493599cdc6ca15
2,247
py
Python
wagtail_localize/migrations/0002_translation.py
th3hamm0r/wagtail-localize
e9e0ba9245060c65e3247b62739abbed71bc2516
[ "BSD-3-Clause" ]
6
2019-09-10T19:53:55.000Z
2019-11-14T16:57:07.000Z
wagtail_localize/migrations/0002_translation.py
th3hamm0r/wagtail-localize
e9e0ba9245060c65e3247b62739abbed71bc2516
[ "BSD-3-Clause" ]
17
2019-07-11T11:17:37.000Z
2019-11-19T16:40:31.000Z
wagtail_localize/migrations/0002_translation.py
th3hamm0r/wagtail-localize
e9e0ba9245060c65e3247b62739abbed71bc2516
[ "BSD-3-Clause" ]
2
2019-09-30T20:23:39.000Z
2019-10-31T14:09:31.000Z
# Generated by Django 3.0.6 on 2020-07-20 17:27 from django.db import migrations, models import django.db.models.deletion import uuid class Migration(migrations.Migration): dependencies = [ ("wagtailcore", "0057_page_locale_fields_notnull"), ("wagtail_localize", "0001_initial"), ] opera...
35.109375
84
0.458834
28343f47e7576637942ab0c1246eb00f7b85ddd9
330
py
Python
exercises/de/solution_02_05_03.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
2
2020-07-07T01:46:37.000Z
2021-04-20T03:19:43.000Z
exercises/de/solution_02_05_03.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
exercises/de/solution_02_05_03.py
tuanducdesign/spacy-course
f8d092c5fa2997fccb3f367d174dce8667932b3d
[ "MIT" ]
null
null
null
import spacy nlp = spacy.blank("de") # Importiere die Klasse Doc from spacy.tokens import Doc # Erwarteter Text: "Was, echt?!" words = ["Was", ",", "echt", "?", "!"] spaces = [False, True, False, False, False] # Erstelle ein Doc mit den Wörtern und Leerzeichen doc = Doc(nlp.vocab, words=words, spaces=spaces) print(...
22
50
0.678788
2870855e7cc00742a035100feb90d74bc689baa4
767
py
Python
src/onegov/town6/views/export.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/town6/views/export.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
src/onegov/town6/views/export.py
politbuero-kampagnen/onegov-cloud
20148bf321b71f617b64376fe7249b2b9b9c4aa9
[ "MIT" ]
null
null
null
from onegov.core.security import Private from onegov.org.views.export import view_export_collection, view_export from onegov.town6 import TownApp from onegov.org.models import Export, ExportCollection from onegov.town6.layout import ExportCollectionLayout @TownApp.html( model=ExportCollection, permission=Priv...
30.68
71
0.771838