hexsha
stringlengths
40
40
size
int64
6
1.04M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
247
max_stars_repo_name
stringlengths
4
130
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
368k
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
247
max_issues_repo_name
stringlengths
4
130
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
116k
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
247
max_forks_repo_name
stringlengths
4
130
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
1
1.04M
avg_line_length
float64
1.53
618k
max_line_length
int64
1
1.02M
alphanum_fraction
float64
0
1
original_content
stringlengths
6
1.04M
filtered:remove_non_ascii
int64
0
538k
filtered:remove_decorators
int64
0
917k
filtered:remove_async
int64
0
722k
filtered:remove_classes
int64
-45
1M
filtered:remove_generators
int64
0
814k
filtered:remove_function_no_docstring
int64
-102
850k
filtered:remove_class_no_docstring
int64
-3
5.46k
filtered:remove_unused_imports
int64
-1,350
52.4k
filtered:remove_delete_markers
int64
0
59.6k
2ead7fcbf16c57d47c0cdfebf8d054f705e2f8be
1,923
py
Python
client_barvis/main.py
antonstagge/BarvisRepo
3cc780c09839855a6b1704d0975cf6d4af1beb1a
[ "MIT" ]
null
null
null
client_barvis/main.py
antonstagge/BarvisRepo
3cc780c09839855a6b1704d0975cf6d4af1beb1a
[ "MIT" ]
null
null
null
client_barvis/main.py
antonstagge/BarvisRepo
3cc780c09839855a6b1704d0975cf6d4af1beb1a
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from threading import Thread import speech_recognition recognizer = speech_recognition.Recognizer() with speech_recognition.Microphone() as source1: recognizer.adjust_for_ambient_noise(source1) websiteThread = Thread(target=startWebsite) websiteThread.start() waitForBarvis() #websit...
26.708333
75
0.627665
# -*- coding: utf-8 -*- import requests import os from threading import Thread import website import ai_request import speech_recognition import json recognizer = speech_recognition.Recognizer() with speech_recognition.Microphone() as source1: recognizer.adjust_for_ambient_noise(source1) def startWebsite(): ...
4
0
0
0
0
1,422
0
-39
203
5f5344be6f31c8367be35c2e6cd57644f235871b
626
py
Python
cloudframe/resource/v1/res01.py
cloudken/faasframe-py
50c8cffac3fb20a096c1906b4828b5ec9aee3ba9
[ "Apache-2.0" ]
null
null
null
cloudframe/resource/v1/res01.py
cloudken/faasframe-py
50c8cffac3fb20a096c1906b4828b5ec9aee3ba9
[ "Apache-2.0" ]
null
null
null
cloudframe/resource/v1/res01.py
cloudken/faasframe-py
50c8cffac3fb20a096c1906b4828b5ec9aee3ba9
[ "Apache-2.0" ]
null
null
null
import logging LOG = logging.getLogger(__name__)
17.885714
44
0.670927
from six.moves import http_client from cloudframe.common import job import logging import time LOG = logging.getLogger(__name__) def post(tenant, req): ack = {'status': 'OK'} job.rpc_cast(_create_server, server=req) return http_client.OK, ack def put(tenant, res_id, req): ack = {'status': 'OK'} ...
0
0
0
0
0
375
0
14
182
19bcc48ee9fb238f298a5fac6d357b057a29c779
4,499
py
Python
test/unit/test_02_utils.py
au9ustine/cuda_aes
873e6768f34de1ea07fc71fc33475c9cd09843ea
[ "BSD-3-Clause" ]
2
2015-06-13T01:44:31.000Z
2016-05-16T03:09:21.000Z
test/unit/test_02_utils.py
au9ustine/cuda_aes
873e6768f34de1ea07fc71fc33475c9cd09843ea
[ "BSD-3-Clause" ]
7
2015-06-13T02:55:34.000Z
2015-07-16T16:29:21.000Z
test/unit/test_02_utils.py
au9ustine/cuda_aes
873e6768f34de1ea07fc71fc33475c9cd09843ea
[ "BSD-3-Clause" ]
null
null
null
import utils logger = utils.get_logger('test_02_utils') my_lib = load_shared_library()
95.723404
2,813
0.766615
import array import hashlib import json import os.path import ctypes from ctypes import * import utils logger = utils.get_logger('test_02_utils') def load_shared_library(): my_lib_path = os.path.join( os.path.dirname(os.path.abspath(__file__)), '..', '..', 'src', 'cuda_aes_for_py.s...
0
0
0
0
0
4,228
0
-42
224
abe44a7ba7d6b23e2e69483c0c5df6ed944c52b3
14,694
py
Python
plugin/instVHDL.py
B00Ze/instVhdl
e359035dc6a17f82ae109571a8bf07760911b4ef
[ "BSD-3-Clause" ]
1
2021-03-21T16:14:49.000Z
2021-03-21T16:14:49.000Z
plugin/instVHDL.py
B00Ze/instVhdl
e359035dc6a17f82ae109571a8bf07760911b4ef
[ "BSD-3-Clause" ]
3
2017-06-13T10:26:47.000Z
2017-09-12T15:41:41.000Z
plugin/instVHDL.py
B00Ze/instVhdl
e359035dc6a17f82ae109571a8bf07760911b4ef
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/python # ----------------------------------------------------------------------------- # Name: VHDL instantiation script # Purpose: Using with VIM # # Author: BooZe # # Created: 25.03.2013 # Copyright: (c) BooZe 2013 # Licence: BSD # ----------------------------------------------------...
33.77931
79
0.56717
#!/usr/bin/python # ----------------------------------------------------------------------------- # Name: VHDL instantiation script # Purpose: Using with VIM # # Author: BooZe # # Created: 25.03.2013 # Copyright: (c) BooZe 2013 # Licence: BSD # ----------------------------------------------------...
0
0
0
13,434
0
562
0
-12
276
b5e71b4f7c95803d854afa2f0cfa1afffd4452f2
360
py
Python
HackerRank/python/list_compre.py
tuvshinot/algorithm-sorting-DS
784c2338fb92f9d2f4da6294f242563031a09c4c
[ "MIT" ]
null
null
null
HackerRank/python/list_compre.py
tuvshinot/algorithm-sorting-DS
784c2338fb92f9d2f4da6294f242563031a09c4c
[ "MIT" ]
null
null
null
HackerRank/python/list_compre.py
tuvshinot/algorithm-sorting-DS
784c2338fb92f9d2f4da6294f242563031a09c4c
[ "MIT" ]
null
null
null
x = 2 y = 2 n = 2 # ar = [] # p = 0 # for i in range ( x + 1 ) : # for j in range( y + 1): # if i+j != n: # ar.append([]) # ar[p] = [ i , j ] # p+=1 # print(ar) x = 2 y = 2 z = 2 n = 2 lst = [[i, j, k] for i in range(x + 1) for j in range(y + 1) for k in ran...
15.652174
101
0.361111
x = 2 y = 2 n = 2 # ar = [] # p = 0 # for i in range ( x + 1 ) : # for j in range( y + 1): # if i+j != n: # ar.append([]) # ar[p] = [ i , j ] # p+=1 # print(ar) x = 2 y = 2 z = 2 n = 2 lst = [[i, j, k] for i in range(x + 1) for j in range(y + 1) for k in ran...
0
0
0
0
0
0
0
0
0
bcaa254a65f77dc17282d3b1ab843091945002a6
3,147
py
Python
src/flower/strategy/default.py
sishtiaq/flower
e8d57941863dcd193d2c0f4989f3ece5136ce027
[ "Apache-2.0" ]
null
null
null
src/flower/strategy/default.py
sishtiaq/flower
e8d57941863dcd193d2c0f4989f3ece5136ce027
[ "Apache-2.0" ]
null
null
null
src/flower/strategy/default.py
sishtiaq/flower
e8d57941863dcd193d2c0f4989f3ece5136ce027
[ "Apache-2.0" ]
null
null
null
# Copyright 2020 Adap GmbH. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ag...
39.3375
85
0.6762
# Copyright 2020 Adap GmbH. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ag...
0
0
0
2,231
0
0
0
80
114
56c5e848525e61dd3c7e758898d25b65e43c59ba
603
py
Python
ex066.py
EduotavioFonseca/ProgramasPython
8e0ef5f6f4239d1fe52321f8795b6573f6ff5130
[ "MIT" ]
null
null
null
ex066.py
EduotavioFonseca/ProgramasPython
8e0ef5f6f4239d1fe52321f8795b6573f6ff5130
[ "MIT" ]
null
null
null
ex066.py
EduotavioFonseca/ProgramasPython
8e0ef5f6f4239d1fe52321f8795b6573f6ff5130
[ "MIT" ]
null
null
null
# Tabela do Brasileiro times = ('Internacional', 'So Paulo', 'Flamengo', 'Atltico-MG', 'Palmeiras', 'Grmio', 'Fluminense', 'Cear', 'Santos', 'Corinthians', 'Bragantino', 'Athletico', 'Atltico-GO', 'Sport', 'Vasco', 'Fortaleza', 'Bahia', 'Gois', 'Coritiba', 'Botafogo') while True: print() ...
37.6875
116
0.60199
# Tabela do Brasileirão times = ('Internacional', 'São Paulo', 'Flamengo', 'Atlético-MG', 'Palmeiras', 'Grêmio', 'Fluminense', 'Ceará', 'Santos', 'Corinthians', 'Bragantino', 'Athletico', 'Atlético-GO', 'Sport', 'Vasco', 'Fortaleza', 'Bahia', 'Goiás', 'Coritiba', 'Botafogo') while True: pri...
26
0
0
0
0
0
0
0
0
aea92b50d275d2897a488416691716c9140ee10a
6,979
py
Python
keg/config.py
level12/keg
6f148a9bd0b8e167007ed5c2a0000daf7de3aee2
[ "BSD-3-Clause" ]
15
2015-06-26T09:01:53.000Z
2020-08-28T16:29:14.000Z
keg/config.py
level12/keg
6f148a9bd0b8e167007ed5c2a0000daf7de3aee2
[ "BSD-3-Clause" ]
165
2015-03-27T06:49:38.000Z
2022-03-11T21:39:52.000Z
keg/config.py
level12/keg
6f148a9bd0b8e167007ed5c2a0000daf7de3aee2
[ "BSD-3-Clause" ]
9
2015-04-22T17:03:32.000Z
2018-06-25T17:48:15.000Z
from __future__ import absolute_import substitute = SubstituteValue # The following three classes are default configuration profiles
34.549505
100
0.648947
from __future__ import absolute_import import os.path as osp import appdirs from blazeutils.helpers import tolist import flask from pathlib import PurePath import six from werkzeug.utils import ( import_string, ImportStringError ) from keg.utils import app_environ_get, pymodule_fpaths_to_objects class Conf...
0
0
0
6,431
0
0
0
90
316
91b8f58f0aef4a4e4c306770d42549a707d7b742
5,038
py
Python
rdcnet/models/rdcnet.py
fmi-basel/RDCNet
f1ebcab7b7325b08506b8da291a63c7c0470fe5f
[ "MIT" ]
5
2020-10-07T03:48:56.000Z
2021-05-27T06:28:41.000Z
rdcnet/models/rdcnet.py
fmi-basel/RDCNet
f1ebcab7b7325b08506b8da291a63c7c0470fe5f
[ "MIT" ]
null
null
null
rdcnet/models/rdcnet.py
fmi-basel/RDCNet
f1ebcab7b7325b08506b8da291a63c7c0470fe5f
[ "MIT" ]
1
2021-06-25T10:32:02.000Z
2021-06-25T10:32:02.000Z
import numpy as np from tensorflow.keras import Model from tensorflow.keras.layers import Input, LeakyReLU from rdcnet.layers.nd_layers import get_nd_conv, get_nd_spatial_dropout, get_nd_conv_transposed from rdcnet.layers.padding import DynamicPaddingLayer, DynamicTrimmingLayer from rdcnet.layers.stacked_dilated_conv...
34.040541
96
0.601826
import tensorflow as tf import numpy as np from tensorflow.keras import Model from tensorflow.keras.layers import Input, LeakyReLU from rdcnet.layers.nd_layers import get_nd_conv, get_nd_spatial_dropout, get_nd_conv_transposed from rdcnet.layers.padding import DynamicPaddingLayer, DynamicTrimmingLayer from rdcnet.lay...
0
0
0
0
0
763
0
2
98
f4dfc6814251debd6daa61577a5da72dc7586bee
5,854
py
Python
scrape.py
TienDang2802/evs-scraper
6538683e0e9db11a559022c8a9aafe67ed5024f6
[ "MIT" ]
null
null
null
scrape.py
TienDang2802/evs-scraper
6538683e0e9db11a559022c8a9aafe67ed5024f6
[ "MIT" ]
null
null
null
scrape.py
TienDang2802/evs-scraper
6538683e0e9db11a559022c8a9aafe67ed5024f6
[ "MIT" ]
null
null
null
if __name__ == '__main__': scrape()
36.5875
116
0.569354
from googleplaces import GooglePlaces, types, lang import googlemaps import csv from time import sleep import requests import sys import re from send_mail import * def scrape(query, city, filters_exclude, filters_include, user, uid): results = [['Name', 'Company Domain', 'Phone Number', 'Company owner', 'Lifecycl...
0
0
0
0
0
5,504
0
-12
314
993feb043393adf3e48cbc1d5e09178f6b6122bf
2,382
py
Python
res_mods/mods/packages/xvm_battle/python/consts.py
peterbartha/ImmunoMod
cbf8cd49893d7082a347c1f72c0e39480869318a
[ "MIT" ]
null
null
null
res_mods/mods/packages/xvm_battle/python/consts.py
peterbartha/ImmunoMod
cbf8cd49893d7082a347c1f72c0e39480869318a
[ "MIT" ]
1
2016-04-03T13:31:39.000Z
2016-04-03T16:48:26.000Z
res_mods/mods/packages/xvm_battle/python/consts.py
peterbartha/ImmunoMod
cbf8cd49893d7082a347c1f72c0e39480869318a
[ "MIT" ]
null
null
null
""" XVM (c) www.modxvm.com 2013-2017 """ ##################################################################### # constants # Shared commands # Markers only commands # Battle events # Invalidation targets # Spotted statuses
34.521739
127
0.689337
""" XVM (c) www.modxvm.com 2013-2017 """ ##################################################################### # constants # Shared commands class XVM_BATTLE_COMMAND(object): REQUEST_BATTLE_GLOBAL_DATA = "xvm_battle.request_battle_global_data" XMQP_INIT = "xvm_battle.xmqp_init" BATTLE_CTRL_SET_VEHICLE_DA...
0
0
0
2,015
0
0
0
0
138
41c9e613638a94d05eb2e8ceab952f4ed37e7164
2,187
py
Python
tests/test_converter.py
billyrrr/onto
72733d36a2583ae4758f7cf33a5229b79773702b
[ "MIT" ]
1
2020-10-04T10:01:45.000Z
2020-10-04T10:01:45.000Z
tests/test_converter.py
billyrrr/onto
72733d36a2583ae4758f7cf33a5229b79773702b
[ "MIT" ]
null
null
null
tests/test_converter.py
billyrrr/onto
72733d36a2583ae4758f7cf33a5229b79773702b
[ "MIT" ]
null
null
null
from collections import namedtuple graph_schema = namedtuple('graph_schema', ['op_type', 'name', 'graphql_object_type'])
21.441176
85
0.582533
from onto.attrs import attribute from onto.models.base import Serializable class H(Serializable): i = attribute.Attribute(type_cls=int, doc="I am 'i'.") j = attribute.PropertyAttribute( type_cls=str, doc="""I am 'j'. See next line. This is my second line. """ ) from collecti...
0
413
123
205
0
1,198
0
31
91
efd92e9172080bbf7288d421524737cd0652549d
2,303
py
Python
src/encode_task_subsample_ctl.py
motorny/chip-seq-pipeline2
b4ffdfb977eb327f8495a42e077c62640cad8ea6
[ "MIT" ]
261
2017-10-18T04:59:35.000Z
2022-03-28T08:15:33.000Z
src/encode_task_subsample_ctl.py
motorny/chip-seq-pipeline2
b4ffdfb977eb327f8495a42e077c62640cad8ea6
[ "MIT" ]
272
2018-05-03T22:57:38.000Z
2022-03-25T22:26:22.000Z
src/encode_task_subsample_ctl.py
motorny/chip-seq-pipeline2
b4ffdfb977eb327f8495a42e077c62640cad8ea6
[ "MIT" ]
142
2017-08-23T23:44:14.000Z
2022-03-18T20:53:26.000Z
#!/usr/bin/env python if __name__ == '__main__': main()
34.373134
82
0.604863
#!/usr/bin/env python import sys import os import argparse from encode_lib_common import ( assert_file_not_empty, get_num_lines, log, ls_l, mkdir_p, rm_f, run_shell_cmd, strip_ext_ta) from encode_lib_genomic import ( subsample_ta_pe, subsample_ta_se) def parse_arguments(): parser = argparse.ArgumentPar...
0
0
0
0
0
1,953
0
131
156
2101b659c05c618a0d1a94ae66118ffd25c67ab5
3,804
py
Python
main.py
allgreed/pynetkit
404142fbc21ae5b771f881d4b406fc53680b4e3b
[ "MIT" ]
2
2019-03-20T18:04:59.000Z
2019-07-15T09:09:21.000Z
main.py
allgreed/pynetkit
404142fbc21ae5b771f881d4b406fc53680b4e3b
[ "MIT" ]
null
null
null
main.py
allgreed/pynetkit
404142fbc21ae5b771f881d4b406fc53680b4e3b
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 from collections import namedtuple import click BoundIface = namedtuple('BoundIface', 'host if_no') NetedIface = namedtuple('NetedIface', 'host if_no ip netmask') DomainAsoc = namedtuple('DomainAsoc', 'iface domain') IFACE_STATEMENT_REGEXP = r'([a-z0-9_]+)\[(\d+)\]\s*=\s*"([A-Z])' pass_d...
26.978723
90
0.652471
#!/usr/bin/env python3 import re import yaml from collections import namedtuple, defaultdict from ipaddress import IPv4Network from itertools import repeat, combinations from functools import update_wrapper import click BoundIface = namedtuple('BoundIface', 'host if_no') NetedIface = namedtuple('NetedIface', 'host i...
0
2,405
0
0
0
663
0
39
294
374933fc53917d78ec37e81b2924dd9f94764c6b
135
py
Python
blobedit.py
HieuLsw/blobjob.editor
c33473ffb7836a70ba3a1b2a9dd9452a9d3a1b81
[ "Naumen", "Condor-1.1", "MS-PL" ]
null
null
null
blobedit.py
HieuLsw/blobjob.editor
c33473ffb7836a70ba3a1b2a9dd9452a9d3a1b81
[ "Naumen", "Condor-1.1", "MS-PL" ]
null
null
null
blobedit.py
HieuLsw/blobjob.editor
c33473ffb7836a70ba3a1b2a9dd9452a9d3a1b81
[ "Naumen", "Condor-1.1", "MS-PL" ]
null
null
null
#! /usr/bin/env python import sys # preferrence for the included libs sys.path.insert(0, 'libs') from editor import main main.main()
15
35
0.733333
#! /usr/bin/env python import sys # preferrence for the included libs sys.path.insert(0, 'libs') from editor import main main.main()
0
0
0
0
0
0
0
0
0
054db30675a5f4ea79156e97c0906b1d49520cbb
1,158
py
Python
qrcode/image/styles/moduledrawers/base.py
xamronpc/python-qrcode
49060c484ce6def1adbc13e3b14e71dcef266eb2
[ "BSD-3-Clause" ]
null
null
null
qrcode/image/styles/moduledrawers/base.py
xamronpc/python-qrcode
49060c484ce6def1adbc13e3b14e71dcef266eb2
[ "BSD-3-Clause" ]
null
null
null
qrcode/image/styles/moduledrawers/base.py
xamronpc/python-qrcode
49060c484ce6def1adbc13e3b14e71dcef266eb2
[ "BSD-3-Clause" ]
null
null
null
from __future__ import absolute_import from typing import TYPE_CHECKING if TYPE_CHECKING:
30.473684
83
0.707254
from __future__ import absolute_import import abc from typing import TYPE_CHECKING, Union if TYPE_CHECKING: from qrcode.image.base import BaseImage from qrcode.main import ActiveWithNeighbors class QRModuleDrawer(abc.ABC): """ QRModuleDrawer exists to draw the modules of the QR Code onto images. ...
0
94
0
838
0
0
0
36
98
f50f6421c88a6048b74f4b57e50eb679c1cc0e74
1,259
py
Python
Fundamentos/Aula 17- Listas (parte 1)/exercicio80.py
andrecrocha/Fundamentos-Python
e18a187945c3478d3b37bb3f350d0ca72e5bcc7a
[ "MIT" ]
null
null
null
Fundamentos/Aula 17- Listas (parte 1)/exercicio80.py
andrecrocha/Fundamentos-Python
e18a187945c3478d3b37bb3f350d0ca72e5bcc7a
[ "MIT" ]
null
null
null
Fundamentos/Aula 17- Listas (parte 1)/exercicio80.py
andrecrocha/Fundamentos-Python
e18a187945c3478d3b37bb3f350d0ca72e5bcc7a
[ "MIT" ]
null
null
null
"""Desafio 80. Ler cinco valores nmericos e ir colocando eles na lista de modo ordenado sem usar o mtodo sort""" numeros = list() for cont in range(0, 5): num = int(input("Escreva um nmero: ")) if cont == 0: numeros.append(num) elif cont == 1: if num >= numeros[0]: numeros.appen...
26.229167
114
0.513106
"""Desafio 80. Ler cinco valores númericos e ir colocando eles na lista de modo ordenado sem usar o método sort""" numeros = list() for cont in range(0, 5): num = int(input("Escreva um número: ")) if cont == 0: numeros.append(num) elif cont == 1: if num >= numeros[0]: numeros.ap...
6
0
0
0
0
0
0
0
0
af0b6fe564278c898bbc8ad18ad8f8d7dcf8139c
324
py
Python
7.py
Polar1ty/euler_problems
bc1cd917d95d1b63b80a0b182dbd5e9f90a95d90
[ "MIT" ]
2
2020-06-09T10:35:12.000Z
2020-06-09T11:32:16.000Z
7.py
Polar1ty/euler_problems
bc1cd917d95d1b63b80a0b182dbd5e9f90a95d90
[ "MIT" ]
null
null
null
7.py
Polar1ty/euler_problems
bc1cd917d95d1b63b80a0b182dbd5e9f90a95d90
[ "MIT" ]
null
null
null
i = 3 shit_indicator = 0 simple_nums = [2] while len(simple_nums) < 10001: for k in range(2, i): if i % k == 0: shit_indicator = 1 break if shit_indicator == 1: pass else: simple_nums.append(i) i += 1 shit_indicator = 0 print(simple_nums[...
21.6
32
0.518519
i = 3 shit_indicator = 0 simple_nums = [2] while len(simple_nums) < 10001: for k in range(2, i): if i % k == 0: shit_indicator = 1 break if shit_indicator == 1: pass else: simple_nums.append(i) i += 1 shit_indicator = 0 print(simple_nums[...
0
0
0
0
0
0
0
0
0
1c2913d42fe3bb6efd581f01b4fcc69c308fa15e
10,342
py
Python
userbot/plugins/upload.py
Aliensuniquebot/CatUserbot
93561a620fc1198c6fe6c259412088f4bc81d97b
[ "MIT" ]
1
2020-07-18T07:42:58.000Z
2020-07-18T07:42:58.000Z
userbot/plugins/upload.py
praveen368/CatUserbot
4b0cd970551ffaf86b9fdd5da584c1b3882821ff
[ "MIT" ]
null
null
null
userbot/plugins/upload.py
praveen368/CatUserbot
4b0cd970551ffaf86b9fdd5da584c1b3882821ff
[ "MIT" ]
null
null
null
import os import json import subprocess from hachoir.metadata import extractMetadata from hachoir.parser import createParser from userbot import LOGS, CMD_HELP from userbot.uniborgConfig import Config thumb_image_path = Config.TMP_DOWNLOAD_DIRECTORY + "/thumb_image.jpg" def get_video_thumb(file, outp...
36.935714
83
0.512473
import aiohttp import asyncio import os import time from datetime import datetime from telethon import events from telethon.tl.types import DocumentAttributeVideo import json import subprocess import math from pySmartDL import SmartDL from hachoir.metadata import extractMetadata from hachoir.parser import createParser ...
0
8,108
0
0
0
0
0
84
289
760213ce9bf57514cc7f63e97e35d4ca368bfe7c
2,198
py
Python
hw2/main.py
zyz29/yzhou9-webapps
e56ae829338c396850c5a91668b250ef6fb76292
[ "MIT" ]
null
null
null
hw2/main.py
zyz29/yzhou9-webapps
e56ae829338c396850c5a91668b250ef6fb76292
[ "MIT" ]
null
null
null
hw2/main.py
zyz29/yzhou9-webapps
e56ae829338c396850c5a91668b250ef6fb76292
[ "MIT" ]
null
null
null
import cherrypy import mysql.connector #Define database variables DATABASE_USER = 'root' DATABASE_HOST = '127.0.0.1' DATABASE_NAME = 'feedND' #Create connection to MySQL cnx = mysql.connector.connect(user=DATABASE_USER, host=DATABASE_HOST, database=DATABASE_NAME) cursor = cnx.cursor() application = cherrypy.Applicati...
24.422222
93
0.589172
import cherrypy import sys import mysql.connector from collections import OrderedDict #Define database variables DATABASE_USER = 'root' DATABASE_HOST = '127.0.0.1' DATABASE_NAME = 'feedND' #Create connection to MySQL cnx = mysql.connector.connect(user=DATABASE_USER, host=DATABASE_HOST, database=DATABASE_NAME) cursor ...
0
1,729
0
4
0
0
0
3
119
a13de6988b1abf618a24ce034423ff9614e01f1a
306
py
Python
xin-era/foundation/python/tricks.py
fan-weiwei/algo-prep
56514630cfe58d451dd126897459cca81bf1b2af
[ "Apache-2.0" ]
null
null
null
xin-era/foundation/python/tricks.py
fan-weiwei/algo-prep
56514630cfe58d451dd126897459cca81bf1b2af
[ "Apache-2.0" ]
null
null
null
xin-era/foundation/python/tricks.py
fan-weiwei/algo-prep
56514630cfe58d451dd126897459cca81bf1b2af
[ "Apache-2.0" ]
null
null
null
import math if __name__ == '__main__': explain('prints out all math functions') print(dir(math))
17
44
0.568627
import math def stars(func): def inner(*args, **kwargs): print("*" * 30) func(*args, **kwargs) print("*" * 30 + '\n') return inner @stars def explain(string): print(string) if __name__ == '__main__': explain('prints out all math functions') print(dir(math))
0
24
0
0
0
129
0
0
46
4eecd7f199b243a3436be78149ea66118f308fd4
454
py
Python
Ethanyan_mall/Ethanyan_mall/apps/orders/urls.py
Jaylen0829/E-commerce-sites
faa4443c11d1534642c8dc9f8262f818f489c554
[ "MIT" ]
17
2019-01-22T00:14:40.000Z
2022-02-03T12:29:49.000Z
Ethanyan_mall/Ethanyan_mall/apps/orders/urls.py
Jaylen0829/E-commerce-sites
faa4443c11d1534642c8dc9f8262f818f489c554
[ "MIT" ]
1
2020-06-28T15:16:38.000Z
2020-08-03T15:34:14.000Z
Ethanyan_mall/Ethanyan_mall/apps/orders/urls.py
EthanYan6/E-commerce-sites
faa4443c11d1534642c8dc9f8262f818f489c554
[ "MIT" ]
11
2020-02-24T00:22:08.000Z
2022-03-26T17:03:40.000Z
from django.conf.urls import url from orders import views urlpatterns = [ url(r'^orders/settlement/$', views.OrderSettlementView.as_view()), url(r'^orders/$', views.OrdersView.as_view()), url(r'^orders/(?P<order_id>\d+)/uncommentgoods/$',views.OrdersUnCommentView.as_view()), url(r'^orders/(?P<order_id...
41.272727
91
0.696035
from django.conf.urls import url from orders import views urlpatterns = [ url(r'^orders/settlement/$', views.OrderSettlementView.as_view()), url(r'^orders/$', views.OrdersView.as_view()), url(r'^orders/(?P<order_id>\d+)/uncommentgoods/$',views.OrdersUnCommentView.as_view()), url(r'^orders/(?P<order_id...
0
0
0
0
0
0
0
0
0
5319b7ce8f2eb863da9fa356bf2c15a47b27ed34
911
py
Python
physics/thermo.py
claywahlstrom/pack
86b70198a4b185611c2ce3d29df99dd01233a6ac
[ "BSD-2-Clause" ]
2
2019-05-04T09:32:15.000Z
2021-02-08T08:38:23.000Z
physics/thermo.py
claywahlstrom/pack
86b70198a4b185611c2ce3d29df99dd01233a6ac
[ "BSD-2-Clause" ]
null
null
null
physics/thermo.py
claywahlstrom/pack
86b70198a4b185611c2ce3d29df99dd01233a6ac
[ "BSD-2-Clause" ]
null
null
null
""" thermodynamics """ def x(yf, y, yg): """Returns the quality of the two-phase mixture""" if y < yf: return 0 elif y > yg: return 1 else: return (y - yf) / (yg - yf) if __name__ == '__main__': from clay.tests import testif from clay.utils import qualify single...
21.690476
90
0.514819
""" thermodynamics """ def x(yf, y, yg): """Returns the quality of the two-phase mixture""" if y < yf: return 0 elif y > yg: return 1 else: return (y - yf) / (yg - yf) if __name__ == '__main__': from clay.tests import testif from clay.utils import qualify single...
0
0
0
0
0
0
0
0
0
d85afd676288fb28551bd9a4df6bdb18e7886857
4,287
py
Python
src/controller.py
hackingyseguridad/OpenDoor
279ddf7b9f99caa6039b0b4d67db06c16d31347a
[ "Xnet", "X11", "Apache-1.1", "RSA-MD" ]
null
null
null
src/controller.py
hackingyseguridad/OpenDoor
279ddf7b9f99caa6039b0b4d67db06c16d31347a
[ "Xnet", "X11", "Apache-1.1", "RSA-MD" ]
null
null
null
src/controller.py
hackingyseguridad/OpenDoor
279ddf7b9f99caa6039b0b4d67db06c16d31347a
[ "Xnet", "X11", "Apache-1.1", "RSA-MD" ]
null
null
null
# -*- coding: utf-8 -*- """ 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 3 of the License. This program is distributed in the hope that it will be useful, but W...
27.132911
93
0.576627
# -*- coding: utf-8 -*- """ 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 3 of the License. This program is distributed in the hope that it will be useful, but W...
0
2,446
0
750
0
0
0
101
310
0f0dd477ef58d03468f0664fbabe017bfccb2929
5,911
py
Python
cfgrib/xarray_store.py
alexamici/cfgrib
6536825ede61bbc61b7b51b827ec0c41efe9d0ee
[ "Apache-2.0" ]
null
null
null
cfgrib/xarray_store.py
alexamici/cfgrib
6536825ede61bbc61b7b51b827ec0c41efe9d0ee
[ "Apache-2.0" ]
null
null
null
cfgrib/xarray_store.py
alexamici/cfgrib
6536825ede61bbc61b7b51b827ec0c41efe9d0ee
[ "Apache-2.0" ]
1
2020-05-18T21:59:22.000Z
2020-05-18T21:59:22.000Z
# # Copyright 2017-2018 European Centre for Medium-Range Weather Forecasts (ECMWF). # # 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...
33.777143
97
0.640162
# # Copyright 2017-2018 European Centre for Medium-Range Weather Forecasts (ECMWF). # # 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...
0
2,352
0
499
0
1,012
0
107
271
21ce880c5bc39254affa9c21f74859fe35d6b7c8
1,168
py
Python
quedadas/migrations/0021_auto_20171115_1613.py
fevsea/meet-Run-Server
48454a4665f55da019334271641c514df231f177
[ "MIT" ]
null
null
null
quedadas/migrations/0021_auto_20171115_1613.py
fevsea/meet-Run-Server
48454a4665f55da019334271641c514df231f177
[ "MIT" ]
null
null
null
quedadas/migrations/0021_auto_20171115_1613.py
fevsea/meet-Run-Server
48454a4665f55da019334271641c514df231f177
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.11.5 on 2017-11-15 16:13 from __future__ import unicode_literals
32.444444
114
0.603596
# -*- coding: utf-8 -*- # Generated by Django 1.11.5 on 2017-11-15 16:13 from __future__ import unicode_literals import django.db.models.deletion from django.conf import settings from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ migrations.swappable_dependen...
0
0
0
923
0
0
0
41
90
b6837b5a0422d4a20492350aa069fd47132c7f4c
382
py
Python
20_muke_python_advanced/01_summary/07_download_server_singleThread/scheduler.py
hemuke/python
bc99f2b5aee997083ae31f59a2b33db48c8255f3
[ "Apache-2.0" ]
null
null
null
20_muke_python_advanced/01_summary/07_download_server_singleThread/scheduler.py
hemuke/python
bc99f2b5aee997083ae31f59a2b33db48c8255f3
[ "Apache-2.0" ]
null
null
null
20_muke_python_advanced/01_summary/07_download_server_singleThread/scheduler.py
hemuke/python
bc99f2b5aee997083ae31f59a2b33db48c8255f3
[ "Apache-2.0" ]
null
null
null
# -*- encoding=utf-8 -*- if __name__ == '__main__': Scheduler().process()
17.363636
41
0.604712
# -*- encoding=utf-8 -*- import utils from modules.downloader import Downloader class Scheduler: """ 调度模块 """ def __init__(self): self.downloader = Downloader() def process(self): # 1.加载图片url列表 # 2.调度下载模块 url_list = utils.urllist() self.downloader.process(url_...
48
0
0
206
0
0
0
11
67
a745741dbf59947084387af7c309073e37bfd4f2
425
py
Python
from_book_data_structures/ch01/06.py
alexandrejr45/exercicios_algoritmo
b6af8275ff44e9dacea31e4d0121efd655ba34ca
[ "MIT" ]
null
null
null
from_book_data_structures/ch01/06.py
alexandrejr45/exercicios_algoritmo
b6af8275ff44e9dacea31e4d0121efd655ba34ca
[ "MIT" ]
null
null
null
from_book_data_structures/ch01/06.py
alexandrejr45/exercicios_algoritmo
b6af8275ff44e9dacea31e4d0121efd655ba34ca
[ "MIT" ]
null
null
null
# Write a short Python function that takes a positive integer n and returns # the sum of the squares of all the odd positive integers smaller than n. print(odd_squares(9)) print(odd_squares(4002)) print(odd_squares(833)) print(odd_squares(6)) print(odd_squares(112))
23.611111
75
0.684706
# Write a short Python function that takes a positive integer n and returns # the sum of the squares of all the odd positive integers smaller than n. def odd_squares(n: int): sum_numbers = 0 for x in range(1, n): if x % 2 != 0: sum_numbers += pow(x, 2) return sum_numbers print(odd_squ...
0
0
0
0
0
132
0
0
23
658ced6b186c5694b89bb298bd4e5cf2d8877648
1,039
py
Python
experiment/graphs/download_graphs.py
isaacarvestad/edc
7a45bd121c82480040694ef4f249d9cc049885b9
[ "BSD-3-Clause" ]
1
2021-01-26T18:36:24.000Z
2021-01-26T18:36:24.000Z
experiment/graphs/download_graphs.py
isaacarvestad/edc
7a45bd121c82480040694ef4f249d9cc049885b9
[ "BSD-3-Clause" ]
null
null
null
experiment/graphs/download_graphs.py
isaacarvestad/edc
7a45bd121c82480040694ef4f249d9cc049885b9
[ "BSD-3-Clause" ]
null
null
null
#! /usr/bin/env python3 """Downloads all graphs used in the experiments to the correct locations. Query results are sparse matrices. Any matrix which isn't square is removed since it does not define a graph. Usage: python3 setyp.py """ import os # Maximum results when querying website. QUERY_LIMIT = 1000 # Max non...
25.341463
88
0.728585
#! /usr/bin/env python3 """Downloads all graphs used in the experiments to the correct locations. Query results are sparse matrices. Any matrix which isn't square is removed since it does not define a graph. Usage: python3 setyp.py """ import ssgetpy import os # Maximum results when querying website. QUERY_LIMIT ...
0
0
0
0
0
158
0
-7
46
b667451592da463cb1c903926dd375ffad0cc89a
1,817
py
Python
samples/core/resource_spec/runtime_resource_request.py
nostro-im/pipelines
39f5b6b74040abbf4b764cbd5b422d7548723d9e
[ "Apache-2.0" ]
2,860
2018-05-24T04:55:01.000Z
2022-03-31T13:49:56.000Z
samples/core/resource_spec/runtime_resource_request.py
nostro-im/pipelines
39f5b6b74040abbf4b764cbd5b422d7548723d9e
[ "Apache-2.0" ]
7,331
2018-05-16T09:03:26.000Z
2022-03-31T23:22:04.000Z
samples/core/resource_spec/runtime_resource_request.py
nostro-im/pipelines
39f5b6b74040abbf4b764cbd5b422d7548723d9e
[ "Apache-2.0" ]
1,359
2018-05-15T11:05:41.000Z
2022-03-31T09:42:09.000Z
# Copyright 2021 The Kubeflow Authors # # 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 in...
37.081633
89
0.734728
# Copyright 2021 The Kubeflow Authors # # 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 in...
0
978
0
0
0
0
0
18
113
81448ebc57ce50e51e9368bd89528b3ec3717ffc
22,813
py
Python
gluon/gluoncv2/models/deeplabv3.py
naviocean/imgclsmob
f2993d3ce73a2f7ddba05da3891defb08547d504
[ "MIT" ]
2,649
2018-08-03T14:18:00.000Z
2022-03-31T08:08:17.000Z
gluon/gluoncv2/models/deeplabv3.py
naviocean/imgclsmob
f2993d3ce73a2f7ddba05da3891defb08547d504
[ "MIT" ]
95
2018-08-13T01:46:03.000Z
2022-03-13T08:38:14.000Z
gluon/gluoncv2/models/deeplabv3.py
naviocean/imgclsmob
f2993d3ce73a2f7ddba05da3891defb08547d504
[ "MIT" ]
549
2018-08-06T08:09:22.000Z
2022-03-31T08:08:21.000Z
""" DeepLabv3 for image segmentation, implemented in Gluon. Original paper: 'Rethinking Atrous Convolution for Semantic Image Segmentation,' https://arxiv.org/abs/1706.05587. """ __all__ = ['DeepLabv3', 'deeplabv3_resnetd50b_voc', 'deeplabv3_resnetd101b_voc', 'deeplabv3_resnetd152b_voc', 'deeplabv3_...
39.882867
120
0.653838
""" DeepLabv3 for image segmentation, implemented in Gluon. Original paper: 'Rethinking Atrous Convolution for Semantic Image Segmentation,' https://arxiv.org/abs/1706.05587. """ __all__ = ['DeepLabv3', 'deeplabv3_resnetd50b_voc', 'deeplabv3_resnetd101b_voc', 'deeplabv3_resnetd152b_voc', 'deeplabv3_...
0
0
0
6,323
0
3,106
0
84
181
42f7ba0d012fae8fdb13b5a32fc74472e7f94a21
2,521
py
Python
dodo_commands/extra/dodo_docker_commands/docker-build.py
mnieber/dodo-commands
82330006af2c6739b030ce932ba1ff9078b241ee
[ "MIT" ]
8
2016-12-01T16:45:45.000Z
2020-05-05T20:56:57.000Z
dodo_commands/extra/dodo_docker_commands/docker-build.py
mnieber/dodo-commands
82330006af2c6739b030ce932ba1ff9078b241ee
[ "MIT" ]
75
2017-01-29T19:25:45.000Z
2020-01-28T09:40:47.000Z
dodo_commands/extra/dodo_docker_commands/docker-build.py
mnieber/dodo-commands
82330006af2c6739b030ce932ba1ff9078b241ee
[ "MIT" ]
2
2017-06-01T09:55:20.000Z
2017-06-08T14:45:08.000Z
from dodo_commands import Dodo from dodo_commands.framework.util import to_arg_list if Dodo.is_main(__name__): args = _args() Dodo.safe = len(args.extra_dirs) == 0 _copy_extra_dirs(args.build_dir, args.extra_dirs) try: Dodo.run( [ "docker", "bu...
33.613333
87
0.613645
import os from dodo_commands import CommandError, Dodo from dodo_commands.framework.util import to_arg_list def _args(): Dodo.parser.add_argument( "name", choices=Dodo.get("/DOCKER_IMAGES").keys(), help="Key to look up in /DOCKER_IMAGES", ) Dodo.parser.add_argument("build_args", h...
0
0
0
0
0
1,783
0
2
91
03abcaec9cc791d47eb2e69bfdfbdadb1f0eea8c
4,883
py
Python
tests/function/test_project.py
vaenow/aliyun-datahub-sdk-python
bcb82ad2f558ab34c3b767ad52c667b62c10e37e
[ "Apache-2.0" ]
1
2021-07-07T08:15:19.000Z
2021-07-07T08:15:19.000Z
tests/function/test_project.py
vaenow/aliyun-datahub-sdk-python
bcb82ad2f558ab34c3b767ad52c667b62c10e37e
[ "Apache-2.0" ]
null
null
null
tests/function/test_project.py
vaenow/aliyun-datahub-sdk-python
bcb82ad2f558ab34c3b767ad52c667b62c10e37e
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License...
33.675862
107
0.649191
#!/usr/bin/env python # -*- coding: utf-8 -*- # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License...
0
0
0
2,783
0
0
0
63
111
a948f3237a28cadd19394dc7e7a272bddff7c57e
712
py
Python
sqlite tut.py
Olateetoms/billingSystem
f9e4c77645fdcad80761fc6f717387aa91fe92d6
[ "bzip2-1.0.6" ]
null
null
null
sqlite tut.py
Olateetoms/billingSystem
f9e4c77645fdcad80761fc6f717387aa91fe92d6
[ "bzip2-1.0.6" ]
null
null
null
sqlite tut.py
Olateetoms/billingSystem
f9e4c77645fdcad80761fc6f717387aa91fe92d6
[ "bzip2-1.0.6" ]
null
null
null
import sqlite3 #connection obj that represent our database with in memory database to create a file called employee database file conn = sqlite3.connect(':memory:') #so it can start from scratch, if you dont want to keep deleting a database over and over..you add :memory: #to create a cursor to start running sql comman...
27.384615
142
0.674157
import sqlite3 #connection obj that represent our database with in memory database to create a file called employee database file conn = sqlite3.connect(':memory:') #so it can start from scratch, if you dont want to keep deleting a database over and over..you add :memory: #to create a cursor to start running sql comman...
0
0
0
0
0
0
0
0
0
85db824e5e870124edc7d516245585cd93da9d5d
453
py
Python
setup.py
BiobankLab/pycdhit
feb6b702d0820d4eca890cecaca62709bd341c69
[ "Apache-2.0" ]
null
null
null
setup.py
BiobankLab/pycdhit
feb6b702d0820d4eca890cecaca62709bd341c69
[ "Apache-2.0" ]
null
null
null
setup.py
BiobankLab/pycdhit
feb6b702d0820d4eca890cecaca62709bd341c69
[ "Apache-2.0" ]
null
null
null
from setuptools import setup setup(name='pycdhit', version='0.0.1', description='CDHIT results analysis tool set', #url='http://github.com/storborg/funniest', author='Blazej Marciniak', author_email='blazejmarciniak@gmail.com', license='Apache 2.0', packages=['pycdhit...
28.3125
53
0.593819
from setuptools import setup setup(name='pycdhit', version='0.0.1', description='CDHIT results analysis tool set', #url='http://github.com/storborg/funniest', author='Blazej Marciniak', author_email='blazejmarciniak@gmail.com', license='Apache 2.0', packages=['pycdhit...
0
0
0
0
0
0
0
0
0
e36d76255d485f302ade235b4c136882fb149ab1
1,368
py
Python
docs/examples/filters/f_sphinx/__init__.py
BusyJay/sokoban
a7fac324e9ee725c7954016d368d799ca2a7c47c
[ "MIT" ]
1
2018-07-08T06:12:02.000Z
2018-07-08T06:12:02.000Z
docs/examples/filters/f_sphinx/__init__.py
BusyJay/sokoban
a7fac324e9ee725c7954016d368d799ca2a7c47c
[ "MIT" ]
null
null
null
docs/examples/filters/f_sphinx/__init__.py
BusyJay/sokoban
a7fac324e9ee725c7954016d368d799ca2a7c47c
[ "MIT" ]
null
null
null
"""A filter that can parse sphinx docs """ __author__ = 'jay' __version__ = (0, 0, 1, 'alpha', 0) catalog = ['read'] form = { "lang" : { "verbose": "Language", "require": False, "type": "select", "choices": [["python2", "Python 2"], ["python3", "Python 3"]], "value": "pytho...
22.8
77
0.537281
"""A filter that can parse sphinx docs """ __author__ = 'jay' __version__ = (0, 0, 1, 'alpha', 0) catalog = ['read'] form = { "lang" : { "verbose": "Language", "require": False, "type": "select", "choices": [["python2", "Python 2"], ["python3", "Python 3"]], "value": "pytho...
0
0
0
0
0
28
0
0
69
9c3ba2b5275e6cdda80be92f9bd65056d0f611d8
29,649
py
Python
appsite/home/migrations/0001_initial.py
markussitzmann/chembience-home
1addcd26d1168a099cf7ef715425f3e10ab5221f
[ "BSD-3-Clause" ]
null
null
null
appsite/home/migrations/0001_initial.py
markussitzmann/chembience-home
1addcd26d1168a099cf7ef715425f3e10ab5221f
[ "BSD-3-Clause" ]
null
null
null
appsite/home/migrations/0001_initial.py
markussitzmann/chembience-home
1addcd26d1168a099cf7ef715425f3e10ab5221f
[ "BSD-3-Clause" ]
null
null
null
# Generated by Django 2.2.4 on 2019-08-20 20:44 import wagtail.contrib.table_block.blocks import wagtail.core.blocks import wagtail.core.fields import wagtail.embeds.blocks
71.271635
2,131
0.630443
# Generated by Django 2.2.4 on 2019-08-20 20:44 from django.db import migrations, models import django.db.models.deletion import modelcluster.fields import wagtail.contrib.table_block.blocks import wagtail.core.blocks import wagtail.core.fields import wagtail.embeds.blocks import wagtail.images.blocks class Migratio...
0
0
0
29,321
0
0
0
42
112
8946c562e5d165e5237379b727f59e9924d369e6
5,571
py
Python
src/tests/python_tests/vector_tests.py
Whitemane/fluid-engine-dev
93c3e942182cd73d54b74b7c2a283854e79911be
[ "MIT" ]
1
2018-04-16T13:09:03.000Z
2018-04-16T13:09:03.000Z
src/tests/python_tests/vector_tests.py
kentbarber/fluid-engine-dev
fb2256badb80c04702db536b63b14754699038ca
[ "MIT" ]
null
null
null
src/tests/python_tests/vector_tests.py
kentbarber/fluid-engine-dev
fb2256badb80c04702db536b63b14754699038ca
[ "MIT" ]
null
null
null
""" Copyright (c) 2018 Doyub Kim I am making my contributions/submissions to this project solely in my personal capacity and am not conveying any rights to any intellectual property of any third parties. """ if __name__ == '__main__': main()
28.279188
78
0.531323
""" Copyright (c) 2018 Doyub Kim I am making my contributions/submissions to this project solely in my personal capacity and am not conveying any rights to any intellectual property of any third parties. """ import pyjet import unittest class Vector2FTest(unittest.TestCase): def testInit(self): a = pyje...
0
0
0
5,138
0
35
0
-15
160
eaea7ea729999bf8be7a0ffb27f39b2820743069
587
py
Python
Coursera_HW/Week_3/task_6.py
IsFelix/ML-HLS_python_course_fall21
3119482d2951feb85d8a7819d2beaac947bca5db
[ "MIT" ]
null
null
null
Coursera_HW/Week_3/task_6.py
IsFelix/ML-HLS_python_course_fall21
3119482d2951feb85d8a7819d2beaac947bca5db
[ "MIT" ]
null
null
null
Coursera_HW/Week_3/task_6.py
IsFelix/ML-HLS_python_course_fall21
3119482d2951feb85d8a7819d2beaac947bca5db
[ "MIT" ]
null
null
null
""" P , . X Y . . . P, X, Y. : . . """ p, x, y = float(input()), float(input()), float(input()) res = (100 * x + y) * (100 + p) / 100 print(int(res // 100), int(res % 100))
30.894737
67
0.744463
""" Процентная ставка по вкладу составляет P процентов годовых, которые прибавляются к сумме вклада. Вклад составляет X рублей Y копеек. Определите размер вклада через год. При решении этой задачи нельзя пользоваться условными инструкциями и циклами. Формат ввода Программа получает на вход целые числа P, X, Y. Формат...
720
0
0
0
0
0
0
0
0
8151da9fee178ce4ff62b10ab49d6836eeeb2ba2
9,978
py
Python
services/ui_backend_service/api/admin.py
valayDave/metaflow-service
65e19aef268e9e707522ee0695fd4ebaee42aa69
[ "Apache-2.0" ]
103
2019-12-04T04:41:08.000Z
2022-03-29T16:20:45.000Z
services/ui_backend_service/api/admin.py
Netflix/metaflow-service
a065407c822018ccd5ebab764bb43e0a9e121024
[ "Apache-2.0" ]
42
2019-12-16T23:15:44.000Z
2022-02-18T17:33:32.000Z
services/ui_backend_service/api/admin.py
valayDave/metaflow-service
65e19aef268e9e707522ee0695fd4ebaee42aa69
[ "Apache-2.0" ]
36
2019-12-12T17:46:46.000Z
2022-01-21T04:53:24.000Z
from services.utils import (METADATA_SERVICE_VERSION, SERVICE_BUILD_TIMESTAMP, SERVICE_COMMIT_HASH) UI_SERVICE_VERSION = "{metadata_v}-{timestamp}-{commit}".format( metadata_v=METADATA_SERVICE_VERSION, timestamp=SERVICE_BUILD_TIMESTAMP or "", commit=SERVICE_COMMIT_HASH or "" )
36.683824
111
0.523852
import os import hashlib import asyncio from aiohttp import web from multidict import MultiDict from services.utils import (METADATA_SERVICE_HEADER, METADATA_SERVICE_VERSION, SERVICE_BUILD_TIMESTAMP, SERVICE_COMMIT_HASH, web_response) from .utils import get_json...
0
0
8,288
983
0
114
0
96
203
8f36c7b0dfc50ee5aae2dda913c606bfc9d665fe
4,301
py
Python
tests/test_parser.py
CodeYellowBV/django-tally
a705821050da912fb8dabd56c41c040ea0a00a21
[ "MIT" ]
null
null
null
tests/test_parser.py
CodeYellowBV/django-tally
a705821050da912fb8dabd56c41c040ea0a00a21
[ "MIT" ]
null
null
null
tests/test_parser.py
CodeYellowBV/django-tally
a705821050da912fb8dabd56c41c040ea0a00a21
[ "MIT" ]
null
null
null
from django_tally.user_def.lang import KW source = """ (do (defn fib (n) (if (in '(0 1) n) 1 (+ (fib (- n 1)) (fib (- n 2))))) (fib 10) [1 2 3] {1 2 3} #{1 2 3} #[1 2 3] ^foo) """ body = [ [ KW('do'), [ KW('defn'), KW('fib'), [KW('n')], [ ...
28.673333
78
0.485003
from unittest import TestCase from django_tally.user_def.lang import parse, KW, serialize from django_tally.user_def.lang.parser import parse_tokens source = """ (do (defn fib (n) (if (in '(0 1) n) 1 (+ (fib (- n 1)) (fib (- n 2))))) (fib 10) [1 2 3] {1 2 3} #{1 2 3} #[1 2 3] ^foo) """ ...
0
0
0
3,353
0
0
0
63
67
37f7fb1c17a2999f23e072c756c3cc3feae54407
4,854
py
Python
tests/test_memberships.py
indigo-ag/pgbedrock
58e46f98da72e81ae0c2f69463aa6e97ea7b8936
[ "Apache-2.0" ]
295
2018-03-22T15:08:45.000Z
2022-03-24T05:06:30.000Z
tests/test_memberships.py
indigo-ag/pgbedrock
58e46f98da72e81ae0c2f69463aa6e97ea7b8936
[ "Apache-2.0" ]
54
2018-03-27T16:06:36.000Z
2022-01-21T14:25:27.000Z
tests/test_memberships.py
indigo-ag/pgbedrock
58e46f98da72e81ae0c2f69463aa6e97ea7b8936
[ "Apache-2.0" ]
34
2018-03-29T01:05:58.000Z
2022-01-08T03:17:59.000Z
ROLE1 = 'charlie' ROLE2 = 'barney' ROLE3 = 'wacko' DESIRED_GROUP1 = 'desired_group1' DESIRED_GROUP2 = 'desired_group2' CURRENT_GROUP1 = 'current_group1' CURRENT_GROUP2 = 'current_group2' Q_HAS_ROLE = "SELECT pg_has_role('{}', '{}', 'member')" DUMMY = 'foo'
38.220472
93
0.716522
from conftest import run_setup_sql from pgbedrock import memberships as memb from pgbedrock import attributes ROLE1 = 'charlie' ROLE2 = 'barney' ROLE3 = 'wacko' DESIRED_GROUP1 = 'desired_group1' DESIRED_GROUP2 = 'desired_group2' CURRENT_GROUP1 = 'current_group1' CURRENT_GROUP2 = 'current_group2' Q_HAS_ROLE = "SELECT...
0
1,239
0
0
0
3,053
0
44
250
361ee0181936dd37e60aef8c4721f06e7ee22ec6
255
py
Python
accounts/apps.py
GunnerJnr/stream-three-final-project
87aa24b64c7c3e0af8117f2c565d6b56c591964c
[ "BSD-3-Clause" ]
1
2017-10-10T14:55:55.000Z
2017-10-10T14:55:55.000Z
accounts/apps.py
GunnerJnr/stream-three-final-project
87aa24b64c7c3e0af8117f2c565d6b56c591964c
[ "BSD-3-Clause" ]
9
2019-10-22T08:11:56.000Z
2022-03-11T23:26:11.000Z
accounts/apps.py
GunnerJnr/stream-three-final-project
87aa24b64c7c3e0af8117f2c565d6b56c591964c
[ "BSD-3-Clause" ]
3
2017-10-26T02:13:10.000Z
2018-05-31T16:04:20.000Z
""" Apps.py: """ # -*- coding: utf-8 -*- from __future__ import unicode_literals
15.9375
39
0.658824
""" Apps.py: """ # -*- coding: utf-8 -*- from __future__ import unicode_literals from django.apps import AppConfig class AccountsConfig(AppConfig): """ AccountsConfig(AppConfig): Accounts app configuration """ name = 'accounts'
0
0
0
115
0
0
0
12
46
02e9c8ec20674049b5cba7e119a2025b0c715b1c
5,394
py
Python
mysite/settings.py
jordanbroberts/python-myBlog
09f373b1e7a4ce804b688d3bc18f894107119d7c
[ "MIT" ]
null
null
null
mysite/settings.py
jordanbroberts/python-myBlog
09f373b1e7a4ce804b688d3bc18f894107119d7c
[ "MIT" ]
5
2020-06-05T18:48:19.000Z
2021-09-08T00:02:06.000Z
mysite/settings.py
jordanbroberts/python-myBlog
09f373b1e7a4ce804b688d3bc18f894107119d7c
[ "MIT" ]
null
null
null
""" Django settings for {{ project_name }} project on Heroku. For more info, see: https://github.com/heroku/heroku-django-template For more information on this file, see https://docs.djangoproject.com/en/2.0/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/2.0/ref...
30.822857
91
0.693178
""" Django settings for {{ project_name }} project on Heroku. For more info, see: https://github.com/heroku/heroku-django-template For more information on this file, see https://docs.djangoproject.com/en/2.0/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/2.0/ref...
0
0
0
0
0
0
0
0
0
45b881345d216339f86ace48c6f247fa127a6ea6
684
py
Python
main.py
NaKolenke/kolenka-backend
b8bf0a49b424e088b02bfeb59b7a083e59973b88
[ "MIT" ]
null
null
null
main.py
NaKolenke/kolenka-backend
b8bf0a49b424e088b02bfeb59b7a083e59973b88
[ "MIT" ]
null
null
null
main.py
NaKolenke/kolenka-backend
b8bf0a49b424e088b02bfeb59b7a083e59973b88
[ "MIT" ]
null
null
null
import sys from src.model.migrations import migrate_schema if __name__ == "__main__": if len(sys.argv) == 1: print( """Specify argument. Possible commands: migrate convert users convert blogs For launching flask server see README.md""" ) elif sys.argv[1] == "migrate": from s...
22.8
47
0.596491
import sys from src.model.migrations import migrate_schema if __name__ == "__main__": if len(sys.argv) == 1: print( """Specify argument. Possible commands: migrate convert users convert blogs For launching flask server see README.md""" ) elif sys.argv[1] == "migrate": from s...
0
0
0
0
0
0
0
0
0
84952999aa38e354caf57eee97a391a84b7d9c5b
1,935
py
Python
minimax_agent.py
williampark73/snake
919f8f2f1a2b60cdc5f1aa7d612836b108e6eb6e
[ "MIT" ]
null
null
null
minimax_agent.py
williampark73/snake
919f8f2f1a2b60cdc5f1aa7d612836b108e6eb6e
[ "MIT" ]
null
null
null
minimax_agent.py
williampark73/snake
919f8f2f1a2b60cdc5f1aa7d612836b108e6eb6e
[ "MIT" ]
null
null
null
depth = 5
28.043478
138
0.717313
import random from curses import * from random import randint depth = 5 def minimax_agent_first_index(game, state): return minimax_agent(game, state, 1, 1) def minimax_agent_second_index(game, state): return minimax_agent(game, state, 2, 5) def get_valid(current_dir, actions): if current_dir == KEY_RIGHT: rem...
0
0
0
0
0
1,745
0
-4
181
fab2bdc56cfbd1639c744a47a03bd1a1ec58e5fa
1,252
py
Python
src/magic_config/interfaces.py
mogaiskii/magic_config
c638ffebf5174600ef9632f923da9a35820ade3f
[ "MIT" ]
null
null
null
src/magic_config/interfaces.py
mogaiskii/magic_config
c638ffebf5174600ef9632f923da9a35820ade3f
[ "MIT" ]
null
null
null
src/magic_config/interfaces.py
mogaiskii/magic_config
c638ffebf5174600ef9632f923da9a35820ade3f
[ "MIT" ]
null
null
null
""" Module for resolving circular imports via "interfaces" """
18.686567
54
0.589457
""" Module for resolving circular imports via "interfaces" """ import abc class AbstractSettingsManager(abc.ABC): @abc.abstractmethod def get_loaders(self): ... @abc.abstractmethod def get_main_loader(self): ... @abc.abstractmethod def get_fields(self): ... class AbstractSettingField(abc....
0
748
0
65
0
0
0
-11
383
c2e50a9278dba12f403557d94b131a7ea2985242
349
py
Python
Recursion/index_of_first_occurance_of_number_index_way.py
shubh2ds/DSA_Python
bf7dbb5560494e9d18b58e05ba9a51b97e25b332
[ "MIT" ]
1
2021-10-15T11:23:36.000Z
2021-10-15T11:23:36.000Z
Recursion/index_of_first_occurance_of_number_index_way.py
shubh2ds/Data-Structures-and-Algorithms-Python
bf7dbb5560494e9d18b58e05ba9a51b97e25b332
[ "MIT" ]
null
null
null
Recursion/index_of_first_occurance_of_number_index_way.py
shubh2ds/Data-Structures-and-Algorithms-Python
bf7dbb5560494e9d18b58e05ba9a51b97e25b332
[ "MIT" ]
null
null
null
#To complete # Main from sys import setrecursionlimit setrecursionlimit(11000) n=int(input()) arr=list(int(i) for i in input().strip().split(' ')) x=int(input()) idx=0 print(firstIndex(arr, x, idx))
20.529412
52
0.661891
#To complete def firstIndex(arr, x,idx): if len(arr)==0 or idx==len(arr): return -1 if arr[idx]==x: return idx return firstIndex(arr, x,idx+1) # Main from sys import setrecursionlimit setrecursionlimit(11000) n=int(input()) arr=list(int(i) for i in input().strip().split(' ')) x=int(input()) idx=0 pr...
0
0
0
0
0
127
0
0
22
863b3659a041f8fe2d390beef85ff57c3459ec80
752
py
Python
test/appcontrollers.py
minixalpha/WatchTips
4e7402741c98fcd1888a01b712a5f9e0aa0689ac
[ "BSD-3-Clause" ]
1
2017-10-25T17:08:48.000Z
2017-10-25T17:08:48.000Z
test/appcontrollers.py
minixalpha/WatchTips
4e7402741c98fcd1888a01b712a5f9e0aa0689ac
[ "BSD-3-Clause" ]
null
null
null
test/appcontrollers.py
minixalpha/WatchTips
4e7402741c98fcd1888a01b712a5f9e0aa0689ac
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python #coding: utf-8 import watchtipstest import unittest if __name__ == '__main__': suite = unittest.TestLoader().loadTestsFromTestCase(AppController) watchtipstest.main(suite)
25.066667
70
0.632979
#!/usr/bin/env python #coding: utf-8 import watchtipstest import unittest from index import app class AppController(unittest.TestCase): def testPageView(self): url_ok = ['/', '/watch/2', '/register', '/login'] method = 'GET' status_ok = '200 OK' for url in url_ok: res...
0
0
0
501
0
0
0
0
45
bf7f51474bbee7250caea9b9edf201151ad17d06
767
py
Python
bf2c.py
ikorin24/bf2c
0eea26ebaaf25d8f372ea18ce6cff3db2701a080
[ "Apache-2.0" ]
null
null
null
bf2c.py
ikorin24/bf2c
0eea26ebaaf25d8f372ea18ce6cff3db2701a080
[ "Apache-2.0" ]
null
null
null
bf2c.py
ikorin24/bf2c
0eea26ebaaf25d8f372ea18ce6cff3db2701a080
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python if __name__ == '__main__': main()
16.673913
52
0.485007
#!/usr/bin/env python import sys def main(): if len(sys.argv) < 2: sys.exit(1) filename = sys.argv[1] dic = { '+': '(*ptr)++;', '-': '(*ptr)--;', '>': 'ptr++;', '<': 'ptr--;', '[': 'while(*ptr){', ']': '}', ',': '*ptr=getchar();', '.': 'putchar(*ptr);', } start = '\ #inc...
0
0
0
0
0
671
0
-11
46
1937fc68d47cdf4d841a33cfd82360ed50daa7ef
16,564
py
Python
astm/mapping.py
Iskander1b/python-astm
606a77407e59c2f2dd12d65a7b2d2e3c141ad8d9
[ "BSD-3-Clause" ]
38
2015-06-11T06:43:02.000Z
2022-03-01T18:21:07.000Z
astm/mapping.py
Iskander1b/python-astm
606a77407e59c2f2dd12d65a7b2d2e3c141ad8d9
[ "BSD-3-Clause" ]
7
2016-08-12T10:16:34.000Z
2021-02-11T15:43:34.000Z
astm/mapping.py
Iskander1b/python-astm
606a77407e59c2f2dd12d65a7b2d2e3c141ad8d9
[ "BSD-3-Clause" ]
39
2015-08-10T16:49:33.000Z
2021-12-26T10:27:07.000Z
# -*- coding: utf-8 -*- # # Copyright (C) 2013 Alexander Shorin # All rights reserved. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. # try: from itertools import izip_longest except ImportError: # Python 3 _MappingProxy = MetaMapp...
31.610687
81
0.579087
# -*- coding: utf-8 -*- # # Copyright (C) 2013 Alexander Shorin # All rights reserved. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. # import datetime import decimal import inspect import time import warnings from operator import itemgett...
0
375
0
14,995
0
172
0
33
598
6b575eb58b808764e5984acf25dc85e83ca8068b
1,977
py
Python
pyiArduinoI2Cmotor/examples/FindReducer.py
tremaru/pyiArduinoI2Cmotor
5e83c4ab1beaf6041663f4399028a5d3f5fa3f56
[ "MIT" ]
null
null
null
pyiArduinoI2Cmotor/examples/FindReducer.py
tremaru/pyiArduinoI2Cmotor
5e83c4ab1beaf6041663f4399028a5d3f5fa3f56
[ "MIT" ]
null
null
null
pyiArduinoI2Cmotor/examples/FindReducer.py
tremaru/pyiArduinoI2Cmotor
5e83c4ab1beaf6041663f4399028a5d3f5fa3f56
[ "MIT" ]
null
null
null
# : # # : # # , 0.00 # ( ), . # 1 . # . ! # , 10 , 10. # mot = pyiArduinoI2Cmotor(0x09) # mot pyiArduinoI2Cmotor, I2C. ...
94.142857
176
0.584219
# ОПРЕДЕЛЕНИЕ РЕАЛЬНОГО ПЕРЕДАТОЧНОГО ОТНОШЕНИЯ: # # ВЫПОЛНИТЕ СЛЕДУЮЩИЕ ДЕЙСТВИЯ: # # После старта скрипта, в мониторе будут появляться значения 0.00 # При вращении ротора мотора (в любую сторону), эти значения будут увеличиваться. # Поворачивайте вручную ротор мотора до тех пор пока вал реду...
1,896
0
0
0
0
0
0
11
62
64caf2af26a1109c0a92c0164fb189e1eb42f571
3,602
py
Python
seqrep/utils.py
MIR-MU/seqrep
dbce45572af9c87b10d6f33f0e3a1b05cea77f86
[ "MIT" ]
9
2022-01-13T20:44:51.000Z
2022-02-17T13:49:33.000Z
seqrep/utils.py
MIR-MU/seqrep
dbce45572af9c87b10d6f33f0e3a1b05cea77f86
[ "MIT" ]
1
2021-09-30T08:56:50.000Z
2022-01-06T11:35:05.000Z
seqrep/utils.py
MIR-MU/seqrep
dbce45572af9c87b10d6f33f0e3a1b05cea77f86
[ "MIT" ]
null
null
null
""" Utils This file provides an implementation of helping classes and functions. """ import pandas as pd import plotly.express as px import plotly.graph_objects as go try: import cPickle as pickle except ModuleNotFoundError: def visualize_labels( labels, title="Visualization of labels", mode: str = "lines...
24.337838
81
0.575236
""" Utils This file provides an implementation of helping classes and functions. """ import abc import pandas as pd import plotly.express as px import plotly.graph_objects as go try: import cPickle as pickle except ModuleNotFoundError: import pickle class Picklable: """ Simple class for saving (and...
0
149
0
1,273
0
0
0
-19
95
0b316cf907e087dd4432a553fcc2cdebb767c078
1,697
py
Python
db_preparation/addDecoyDB.py
HKU-BAL/MegaPath-Nano
55e0ac3687aaac35c012c71970a5966a60d7d380
[ "BSD-3-Clause" ]
13
2020-09-16T13:55:41.000Z
2022-02-09T14:34:41.000Z
db_preparation/addDecoyDB.py
HKU-BAL/MegaPath-Nano
55e0ac3687aaac35c012c71970a5966a60d7d380
[ "BSD-3-Clause" ]
1
2021-01-05T02:47:30.000Z
2021-01-05T08:51:05.000Z
db_preparation/addDecoyDB.py
HKU-BAL/MegaPath-Nano
55e0ac3687aaac35c012c71970a5966a60d7d380
[ "BSD-3-Clause" ]
3
2020-10-31T02:19:39.000Z
2021-09-07T11:47:44.000Z
import argparse from shutil import copyfile import os from Bio import SeqIO if __name__ == '__main__': parser = argparse.ArgumentParser(description='Add fasta to decoy db') parser.add_argument('--decoy_fasta', required=True) cwd=os.path.dirname(os.path.realpath(__file__)) NANO_DIR=os.path.di...
48.485714
104
0.705362
import argparse from shutil import copyfile import os from Bio import SeqIO if __name__ == '__main__': parser = argparse.ArgumentParser(description='Add fasta to decoy db') parser.add_argument('--decoy_fasta', required=True) cwd=os.path.dirname(os.path.realpath(__file__)) NANO_DIR=os.path.di...
0
0
0
0
0
0
0
0
0
519396f2d83a92e220252a97680e8da6731a2521
113
py
Python
megashop/urls.py
EugeniyMalakhov/megashara
50ee8d7c73447fcbeac22483f2659032fc213176
[ "MIT" ]
null
null
null
megashop/urls.py
EugeniyMalakhov/megashara
50ee8d7c73447fcbeac22483f2659032fc213176
[ "MIT" ]
null
null
null
megashop/urls.py
EugeniyMalakhov/megashara
50ee8d7c73447fcbeac22483f2659032fc213176
[ "MIT" ]
null
null
null
from django.conf.urls import url urlpatterns = [ url(r'^$', 'megashop.views.home', name='home'), ]
18.833333
51
0.654867
from django.conf.urls import url, include urlpatterns = [ url(r'^$', 'megashop.views.home', name='home'), ]
0
0
0
0
0
0
0
9
0
2ed6ffc3d7cd8d78362ae851e58d4a8706ff894b
849
py
Python
2015/06/fc_2015_06_09.py
mfwarren/FreeCoding
58ac87f35ad2004a3514782556762ee0ed72c39a
[ "MIT" ]
null
null
null
2015/06/fc_2015_06_09.py
mfwarren/FreeCoding
58ac87f35ad2004a3514782556762ee0ed72c39a
[ "MIT" ]
1
2015-04-27T01:43:45.000Z
2015-04-27T01:43:45.000Z
2015/06/fc_2015_06_09.py
mfwarren/FreeCoding
58ac87f35ad2004a3514782556762ee0ed72c39a
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # imports go here import time as time import numpy as np import scipy as sp import matplotlib.pyplot as plt from sklearn.feature_extraction.image import grid_to_graph from sklearn.cluster import AgglomerativeClustering # # Free Coding session for 2015-06-09 # Written by Matt Warren # lena = sp...
24.970588
103
0.730271
#!/usr/bin/env python3 # imports go here import time as time import numpy as np import scipy as sp import matplotlib.pyplot as plt from sklearn.feature_extraction.image import grid_to_graph from sklearn.cluster import AgglomerativeClustering # # Free Coding session for 2015-06-09 # Written by Matt Warren # lena = sp...
0
0
0
0
0
0
0
0
0
6cd25eacec4bbf34b5da320753489717c6c1b39b
649
py
Python
Action/interpreter.py
lpdswing/DesignPatternsPython
6f4b8416b0624ecda0cca3dadd306f938da9a118
[ "Apache-2.0" ]
3
2020-07-21T11:43:22.000Z
2020-07-21T11:56:50.000Z
Action/interpreter.py
lpdswing/DesignPatternsPython
6f4b8416b0624ecda0cca3dadd306f938da9a118
[ "Apache-2.0" ]
null
null
null
Action/interpreter.py
lpdswing/DesignPatternsPython
6f4b8416b0624ecda0cca3dadd306f938da9a118
[ "Apache-2.0" ]
null
null
null
# if __name__ == '__main__': context = Context() context.name = 'alex' arrs = [NotTerminalExpression(),TerminalExpression(),TerminalExpression()] for entry in arrs: entry.interpreter(context)
19.088235
78
0.659476
# 解释器模式 class AbstractExpression: '''抽象解释器''' def interpreter(self, context): pass class TerminalExpression(AbstractExpression): '''继承抽象解释器,具体解释器终端''' def interpreter(self, context): print(f'终端解释器:{context}') class NotTerminalExpression(AbstractExpression): def interpreter(se...
105
0
0
301
0
0
0
0
92
91253aa69a78411799ddedcfc052a48d3b3e5bc0
190
py
Python
src/sweetrpg_db/exceptions.py
sweetrpg/db
efd4fbea8eeb387b3ab6cb5cf2581cdb9c454b90
[ "MIT" ]
null
null
null
src/sweetrpg_db/exceptions.py
sweetrpg/db
efd4fbea8eeb387b3ab6cb5cf2581cdb9c454b90
[ "MIT" ]
11
2021-09-27T05:02:27.000Z
2022-03-21T04:21:58.000Z
src/sweetrpg_db/exceptions.py
sweetrpg/db
efd4fbea8eeb387b3ab6cb5cf2581cdb9c454b90
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- __author__ = "Paul Schifferer <dm@sweetrpg.com>" """Common exceptions. """
17.272727
48
0.652632
# -*- coding: utf-8 -*- __author__ = "Paul Schifferer <dm@sweetrpg.com>" """Common exceptions. """ class ObjectNotFound(Exception): """An exception for objects not found.""" pass
0
0
0
67
0
0
0
0
23
4b616493893bbac3330367b82b1e9dc10fbe6c37
415
py
Python
python/sprint0/c.py
Chiga2030/algorithms-templates
6e0ee665e2420c77a3d56d153f67dcfab60be622
[ "MIT" ]
38
2021-09-14T08:22:32.000Z
2022-03-15T08:52:20.000Z
python/sprint0/c.py
Chiga2030/algorithms-templates
6e0ee665e2420c77a3d56d153f67dcfab60be622
[ "MIT" ]
null
null
null
python/sprint0/c.py
Chiga2030/algorithms-templates
6e0ee665e2420c77a3d56d153f67dcfab60be622
[ "MIT" ]
38
2021-10-04T14:06:35.000Z
2022-03-31T12:24:04.000Z
arr, window_size = read_input() print(" ".join(map(str, moving_average(arr, window_size))))
27.666667
68
0.66988
from typing import List, Tuple def moving_average(arr: List[int], window_size: int) -> List[float]: # Здесь реализация вашего решения pass def read_input() -> Tuple[List[int], int]: n = int(input()) arr = list(map(int, input().strip().split())) window_size = int(input()) return arr, window_siz...
56
0
0
0
0
217
0
9
68
eb5de1b5d6b00b937a8eeb7d9de731867c138ffe
14,779
py
Python
simpa/core/simulation_modules/optical_simulation_module/optical_forward_model_mcx_adapter.py
jgroehl/simpa
e56f0802e5a8555ee8bb139dd4f776025e7e9267
[ "MIT" ]
1
2021-11-12T22:45:06.000Z
2021-11-12T22:45:06.000Z
simpa/core/simulation_modules/optical_simulation_module/optical_forward_model_mcx_adapter.py
jgroehl/simpa
e56f0802e5a8555ee8bb139dd4f776025e7e9267
[ "MIT" ]
null
null
null
simpa/core/simulation_modules/optical_simulation_module/optical_forward_model_mcx_adapter.py
jgroehl/simpa
e56f0802e5a8555ee8bb139dd4f776025e7e9267
[ "MIT" ]
null
null
null
# SPDX-FileCopyrightText: 2021 Division of Intelligent Medical Systems, DKFZ # SPDX-FileCopyrightText: 2021 Janek Groehl # SPDX-License-Identifier: MIT
43.21345
119
0.616145
# SPDX-FileCopyrightText: 2021 Division of Intelligent Medical Systems, DKFZ # SPDX-FileCopyrightText: 2021 Janek Groehl # SPDX-License-Identifier: MIT import numpy as np import struct import subprocess from simpa.utils import Tags, Settings from simpa.core.simulation_modules.optical_simulation_module import OpticalFo...
0
2,207
0
11,952
0
0
0
201
266
62a88ee1cea48215d3c7df22a522cd9c67672444
136
py
Python
Python/CodeForces Solutions/1-500/71A.py
7namansharma/Comp-Prog
b760ef9b4173e6d5851dc63cc92a8e935baf60ed
[ "MIT" ]
null
null
null
Python/CodeForces Solutions/1-500/71A.py
7namansharma/Comp-Prog
b760ef9b4173e6d5851dc63cc92a8e935baf60ed
[ "MIT" ]
null
null
null
Python/CodeForces Solutions/1-500/71A.py
7namansharma/Comp-Prog
b760ef9b4173e6d5851dc63cc92a8e935baf60ed
[ "MIT" ]
null
null
null
for i in range(int(input())): n = input() if len(n)>10: print(n[0], len(n)-2, n[-1], sep="") else: print(n)
19.428571
44
0.441176
for i in range(int(input())): n = input() if len(n)>10: print(n[0], len(n)-2, n[-1], sep="") else: print(n)
0
0
0
0
0
0
0
0
0
e89a350d85b8cab3877c7dc4a2a8b2b77a88e09c
3,107
py
Python
setup.py
qinzzz/forte
39a106667efd7d0c72dbc44f3cf060a49d742697
[ "Apache-2.0" ]
null
null
null
setup.py
qinzzz/forte
39a106667efd7d0c72dbc44f3cf060a49d742697
[ "Apache-2.0" ]
null
null
null
setup.py
qinzzz/forte
39a106667efd7d0c72dbc44f3cf060a49d742697
[ "Apache-2.0" ]
null
null
null
import sys from pathlib import Path import os import setuptools long_description = (Path(__file__).parent / "README.md").read_text() if sys.version_info < (3, 6): sys.exit("Python>=3.6 is required by Forte.") VERSION_VAR = "VERSION" version = {} with open( os.path.join(os.path.dirname(os.path.abspath(__file...
31.07
84
0.562601
import sys from pathlib import Path import os import setuptools long_description = (Path(__file__).parent / "README.md").read_text() if sys.version_info < (3, 6): sys.exit("Python>=3.6 is required by Forte.") VERSION_VAR = "VERSION" version = {} with open( os.path.join(os.path.dirname(os.path.abspath(__file...
0
0
0
0
0
0
0
0
0
ae888740f1b547b002ac3469210c056f2816ef74
1,498
py
Python
bot.py
PiranavS/Protbot
c09dac4be4348f7c6c5ed497cc8a2c56e180f53b
[ "MIT" ]
null
null
null
bot.py
PiranavS/Protbot
c09dac4be4348f7c6c5ed497cc8a2c56e180f53b
[ "MIT" ]
null
null
null
bot.py
PiranavS/Protbot
c09dac4be4348f7c6c5ed497cc8a2c56e180f53b
[ "MIT" ]
null
null
null
from discord.ext import commands from googleapiclient.discovery import build youtube=build('youtube','v3',developerKey='') client=commands.Bot(command_prefix = ">") #await message.channel.send(message.content) client.run("")
26.280702
86
0.700935
import discord from discord.ext import commands from googleapiclient.discovery import build youtube=build('youtube','v3',developerKey='') client=commands.Bot(command_prefix = ">") @client.event async def on_ready(): print("Let's kick ass") @client.event async def on_message(message): if message...
0
1,036
0
0
0
0
0
-7
223
7a99bc863f2d42f188708751c45a4d80a7214073
102
py
Python
contrib/Research/nlp/bert/BERT_tf_Soapeggpain/script/e2e_func_node/tools/performance/performanceAnalysis_1p/test.py
Huawei-Ascend/modelzoo
df51ed9c1d6dbde1deef63f2a037a369f8554406
[ "Apache-2.0" ]
null
null
null
contrib/Research/nlp/bert/BERT_tf_Soapeggpain/script/e2e_func_node/tools/performance/performanceAnalysis_1p/test.py
Huawei-Ascend/modelzoo
df51ed9c1d6dbde1deef63f2a037a369f8554406
[ "Apache-2.0" ]
3
2021-03-31T20:15:40.000Z
2022-02-09T23:50:46.000Z
contrib/Research/nlp/bert/BERT_tf_Soapeggpain/script/e2e_func_node/tools/performance/performanceAnalysis_1p/test.py
Huawei-Ascend/modelzoo
df51ed9c1d6dbde1deef63f2a037a369f8554406
[ "Apache-2.0" ]
null
null
null
a = 3 b = 7 mean = round( a / b,2 ) print(mean)
11.333333
23
0.676471
import xlrd import numpy as np import sys import math a = 3 b = 7 mean = round( a / b,2 ) print(mean)
0
0
0
0
0
0
0
-34
88
b875c79cb37234ac905904d44dde1cdd687086b2
10,039
py
Python
poet.py
brucewuquant/POET
d93b5e048a95a4d7c1c2e8d10a45251f5edd4c4f
[ "Apache-2.0" ]
1
2022-02-25T02:52:05.000Z
2022-02-25T02:52:05.000Z
poet.py
dizhouwu/POET
d93b5e048a95a4d7c1c2e8d10a45251f5edd4c4f
[ "Apache-2.0" ]
null
null
null
poet.py
dizhouwu/POET
d93b5e048a95a4d7c1c2e8d10a45251f5edd4c4f
[ "Apache-2.0" ]
null
null
null
import numpy as np import scipy def estimate_nfactor_act(X, C=1): """ estimate number of factors given data matrix X (n*p) threshold on eigenvalues of correlation matrix (bias corrected) https://arxiv.org/abs/1909.10710 K = # eigenvalues of sample corr that > 1 + sqrt(p / (n-1)) """ ...
32.383871
222
0.513199
import numpy as np import numba import scipy class DotDict(dict): def __init__(self, *args, **kwargs): super(DotDict, self).__init__(*args, **kwargs) self.__dict__ = self for key in self.keys(): self[key] = self.__from_nested_dict(self[key]) def __setattr__(self,...
0
193
0
546
0
296
0
-9
128
e6ae6236f01c9013093adb4bb5bee3dcafd38785
4,439
py
Python
llap-server/src/main/resources/templates.py
bubblesly/hive
83e52d3c22471f153a8e7ca1392ae500850fbbc2
[ "Apache-2.0" ]
4
2019-06-05T18:08:19.000Z
2021-06-07T10:36:49.000Z
llap-server/src/main/resources/templates.py
bubblesly/hive
83e52d3c22471f153a8e7ca1392ae500850fbbc2
[ "Apache-2.0" ]
62
2020-04-23T15:01:26.000Z
2022-01-25T17:27:48.000Z
llap-server/src/main/resources/templates.py
bubblesly/hive
83e52d3c22471f153a8e7ca1392ae500850fbbc2
[ "Apache-2.0" ]
21
2016-07-28T13:17:32.000Z
2022-02-25T10:46:20.000Z
metainfo = """<?xml version="1.0"?> <!-- Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to You under the Apache License, Ve...
32.639706
110
0.64519
metainfo = """<?xml version="1.0"?> <!-- Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to You under the Apache License, Ve...
0
0
0
0
0
0
0
0
0
23e1ebdd60289e4d82ff1c4d62c75ea340b51248
4,262
py
Python
plotting_scripts/plot_cov.py
grahamgower/island_thrush_scripts
494be57780155979374776e3729d6c11e34cdbfc
[ "MIT" ]
null
null
null
plotting_scripts/plot_cov.py
grahamgower/island_thrush_scripts
494be57780155979374776e3729d6c11e34cdbfc
[ "MIT" ]
null
null
null
plotting_scripts/plot_cov.py
grahamgower/island_thrush_scripts
494be57780155979374776e3729d6c11e34cdbfc
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import numpy as np from sklearn import decomposition import matplotlib import matplotlib.cm matplotlib.use("Agg") # don't try to use $DISPLAY import matplotlib.pyplot as plt from matplotlib.backends.backend_pdf import PdfPages import matplotlib.gridspec as gridspec from circledist import cir...
28.413333
87
0.587518
#!/usr/bin/env python3 import csv import numpy as np from sklearn import decomposition import matplotlib import matplotlib.cm matplotlib.use("Agg") # don't try to use $DISPLAY import matplotlib.pyplot as plt from matplotlib.backends.backend_pdf import PdfPages import matplotlib.gridspec as gridspec from circledis...
0
0
0
0
0
1,441
0
-9
114
9de98025d2b5a2eb00b2e35ba0719f41819be4e8
2,900
py
Python
HarmoAIServer/datastruc/config.py
Vector-7/HarmoAIComposorModule
51ad553cf3f730e6038bf75d4f1ccf9a1ebd6264
[ "Apache-2.0" ]
null
null
null
HarmoAIServer/datastruc/config.py
Vector-7/HarmoAIComposorModule
51ad553cf3f730e6038bf75d4f1ccf9a1ebd6264
[ "Apache-2.0" ]
null
null
null
HarmoAIServer/datastruc/config.py
Vector-7/HarmoAIComposorModule
51ad553cf3f730e6038bf75d4f1ccf9a1ebd6264
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright SweetCase Project, Re_Coma(Ha Jeong Hyun). All Rights Reserved. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # http://www.apache.org/licenses/LICENS...
34.52381
86
0.631379
# -*- coding: utf-8 -*- # Copyright SweetCase Project, Re_Coma(Ha Jeong Hyun). All Rights Reserved. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # http://www.apache.org/licenses/LICENS...
465
0
0
1,962
0
0
0
-17
112
73111ae41f7f2d2e5947cf711b523b93998217b9
33,176
py
Python
onmyoji_win.py
AlanRuijia/onmyoji
74f6de5f41a7800b728f23b7a67fd6a2d9eb2cc7
[ "MIT" ]
null
null
null
onmyoji_win.py
AlanRuijia/onmyoji
74f6de5f41a7800b728f23b7a67fd6a2d9eb2cc7
[ "MIT" ]
null
null
null
onmyoji_win.py
AlanRuijia/onmyoji
74f6de5f41a7800b728f23b7a67fd6a2d9eb2cc7
[ "MIT" ]
null
null
null
# -*-coding:utf-8-*- import tkinter.messagebox as messagebox app = Application() # console try: test = sys.argv[1] except IndexError: test = False if test == 'test': pass else: whnd = windll.kernel32.GetConsoleWindow() if whnd: windll.user32.ShowWindow(whnd, 0) windll.kernel32.Cl...
40.458537
111
0.561219
# -*-coding:utf-8-*- import time import datetime import os import random import shelve import threading from queue import Queue import win32api, win32gui, win32con, win32com.client from ctypes import * from PIL import ImageGrab, Image as PLI_Image, ImageTk from tkinter import * from tkinter import ttk import tkinter.m...
3,678
2,322
0
28,839
0
0
0
42
333
81c2ea7ee9f616adb5fbf19a5bb4eb1e0adee74e
1,250
py
Python
synapse/replication/tcp/__init__.py
zauguin/synapse
ea00f18135ce30e8415526ce68585ea90da5b856
[ "Apache-2.0" ]
2
2020-04-30T18:38:02.000Z
2020-07-08T21:38:28.000Z
synapse/replication/tcp/__init__.py
zauguin/synapse
ea00f18135ce30e8415526ce68585ea90da5b856
[ "Apache-2.0" ]
4
2020-03-04T23:47:05.000Z
2021-12-09T21:41:44.000Z
synapse/replication/tcp/__init__.py
zauguin/synapse
ea00f18135ce30e8415526ce68585ea90da5b856
[ "Apache-2.0" ]
2
2020-03-03T18:34:52.000Z
2022-03-31T11:06:18.000Z
# -*- coding: utf-8 -*- # Copyright 2017 Vector Creations 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 applica...
40.322581
78
0.7544
# -*- coding: utf-8 -*- # Copyright 2017 Vector Creations 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 applica...
0
0
0
0
0
0
0
0
0
b3e360298a3be7d671d634b3467134349a10212e
110
py
Python
Uche Clare/Phase 1/Python Basic 1/Day 12/Task 103.py
CodedLadiesInnovateTech/-python-challenge-solutions
430cd3eb84a2905a286819eef384ee484d8eb9e7
[ "MIT" ]
6
2020-05-23T19:53:25.000Z
2021-05-08T20:21:30.000Z
Uche Clare/Phase 1/Python Basic 1/Day 12/Task 103.py
CodedLadiesInnovateTech/-python-challenge-solutions
430cd3eb84a2905a286819eef384ee484d8eb9e7
[ "MIT" ]
8
2020-05-14T18:53:12.000Z
2020-07-03T00:06:20.000Z
Uche Clare/Phase 1/Python Basic 1/Day 12/Task 103.py
CodedLadiesInnovateTech/-python-challenge-solutions
430cd3eb84a2905a286819eef384ee484d8eb9e7
[ "MIT" ]
39
2020-05-10T20:55:02.000Z
2020-09-12T17:40:59.000Z
#Write a Python program to extract the filename from a given path. import os print(os.path.basename(__file__))
36.666667
66
0.8
#Write a Python program to extract the filename from a given path. import os print(os.path.basename(__file__))
0
0
0
0
0
0
0
0
0
8b20e6eebb2aa104b7721de7a6e2365e1af62208
3,186
py
Python
tests/test_assembly_report/test_assembly_report.py
Edinburgh-Genome-Foundry/plateo
c9a608658325f3c507788d9b966a3f3c8e516bc5
[ "MIT" ]
22
2018-01-29T21:34:25.000Z
2021-12-14T15:31:49.000Z
tests/test_assembly_report/test_assembly_report.py
Edinburgh-Genome-Foundry/plateo
c9a608658325f3c507788d9b966a3f3c8e516bc5
[ "MIT" ]
3
2017-09-20T16:08:45.000Z
2021-05-28T17:45:14.000Z
tests/test_assembly_report/test_assembly_report.py
Edinburgh-Genome-Foundry/plateo
c9a608658325f3c507788d9b966a3f3c8e516bc5
[ "MIT" ]
5
2018-09-18T08:53:37.000Z
2021-04-28T08:44:38.000Z
import matplotlib matplotlib.use("Agg")
34.630435
75
0.670747
import os import matplotlib matplotlib.use("Agg") from plateo import AssemblyPlan from plateo.parsers import plate_from_content_spreadsheet from plateo.containers.plates import Plate4ti0960 from plateo.exporters import (picklist_to_labcyte_echo_picklist_file, PlateTextPlotter, ...
0
0
0
0
0
2,561
0
317
266
eab3ae228294c53fded04204fca3c7d6c2ecc943
1,029
py
Python
pkmkt2_code/task3.py
toomastahves/ml-examples
ed7d3f9e64970fe0aacd13db9afb707f428ed2ac
[ "MIT" ]
1
2022-03-08T10:53:02.000Z
2022-03-08T10:53:02.000Z
pkmkt2_code/task3.py
toomastahves/ml-examples
ed7d3f9e64970fe0aacd13db9afb707f428ed2ac
[ "MIT" ]
null
null
null
pkmkt2_code/task3.py
toomastahves/ml-examples
ed7d3f9e64970fe0aacd13db9afb707f428ed2ac
[ "MIT" ]
null
null
null
from sympy import symbols x1, x2, x3, t, v1, v2, v3 = symbols('x1 x2 x3 t v1 v2 v3') #from testdata import eq1, eq2, eq3 #print(get_velocity_Euler(eq1, eq2, eq3)) #print(get_acceleration_Euler(eq1, eq2, eq3))
42.875
75
0.605442
from sympy import symbols, diff, solve, Eq from task1 import get_Euler_descr x1, x2, x3, t, v1, v2, v3 = symbols('x1 x2 x3 t v1 v2 v3') def get_velocity_Euler(eq1, eq2, eq3): u1, u2, u3 = get_Euler_descr(eq1, eq2, eq3) v1_ = diff(u1, t) + diff(u1, x1)*v1 + diff(u1, x2)*v2 + diff(u1, x3)*v3 v2_ = diff(u2, ...
0
0
0
0
0
721
0
29
68
31a5ee7a8c15c18aa103ed2598c34cffc3a69548
3,669
py
Python
Games/hex/HexLogic.py
morozig/muzero
9798cf9ac2ab46cf6da81827607b8fa8dafbeae4
[ "MIT" ]
null
null
null
Games/hex/HexLogic.py
morozig/muzero
9798cf9ac2ab46cf6da81827607b8fa8dafbeae4
[ "MIT" ]
null
null
null
Games/hex/HexLogic.py
morozig/muzero
9798cf9ac2ab46cf6da81827607b8fa8dafbeae4
[ "MIT" ]
null
null
null
""" Class for the hex game logic. Unaltered skeleton code. EDIT: Changed board representation from dict to numpy.ndarray. EDIT: Changed numbers for the player-color indicators. :version: FINAL :date: :author: Aske Plaat :edited by: Joery de Vries """
33.66055
114
0.531207
""" Class for the hex game logic. Unaltered skeleton code. EDIT: Changed board representation from dict to numpy.ndarray. EDIT: Changed numbers for the player-color indicators. :version: FINAL :date: :author: Aske Plaat :edited by: Joery de Vries """ import numpy as np class HexBoard: BLUE = -1 # 1 RED = 1...
0
0
0
3,373
0
0
0
-3
45
16c38f5853f84fef743019e993c84890e0fb5c88
5,043
py
Python
sdk/python/pulumi_aws/outposts/get_outposts.py
alexbowers/pulumi-aws
7dbdb03b1e4f7c0d51d5b5d17233ff4465c3eff5
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
sdk/python/pulumi_aws/outposts/get_outposts.py
alexbowers/pulumi-aws
7dbdb03b1e4f7c0d51d5b5d17233ff4465c3eff5
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
sdk/python/pulumi_aws/outposts/get_outposts.py
alexbowers/pulumi-aws
7dbdb03b1e4f7c0d51d5b5d17233ff4465c3eff5
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import pulumi import pulumi.runtime from typing import Optional from .. import _utilities __all__ = [ 'GetOutpostsResult', 'Awa...
34.306122
137
0.655364
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union, overload from .. import...
0
2,592
0
435
0
0
0
35
69
39213ae05145aca03d49aa5f9978e595e8bcfaf8
2,298
py
Python
cost-analysis-result.py
efficient/catbench
4f66541efd8318109c4ac150898d60f023e7aba5
[ "Apache-2.0" ]
10
2017-12-12T17:20:41.000Z
2021-05-03T14:40:35.000Z
cost-analysis-result.py
efficient/catbench
4f66541efd8318109c4ac150898d60f023e7aba5
[ "Apache-2.0" ]
null
null
null
cost-analysis-result.py
efficient/catbench
4f66541efd8318109c4ac150898d60f023e7aba5
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python import matplotlib as mpl; mpl.use('Agg'); filename="cost-analysis-result.pdf"; main(); # Col 0 are the x points # Col 1 is the series 50/100 marker # Col 2 is the series cat data # Col 3 is the series no cat data
31.054054
124
0.644909
#!/usr/bin/python import argparse; import os; import sys; import matplotlib as mpl; mpl.use('Agg'); import matplotlib.pyplot as plt; import json; from matplotlib import ticker; import numpy as np filename="cost-analysis-result.pdf"; def graph(): fig = plt.figure(figsize=(8, 4)); ax = fig.add_subplot(1,1,1); ...
0
0
0
0
0
1,882
0
-24
207
3f9f62e3bd3edff609fc705e0328d2bab6bb7690
1,483
py
Python
setup.py
nilesh-kr-dubey/django-inbound-rules
5ca122bf915d17c04a63b1464048bba91006e854
[ "MIT" ]
1
2020-07-31T06:34:27.000Z
2020-07-31T06:34:27.000Z
setup.py
nilesh-kr-dubey/django-inbound-rules
5ca122bf915d17c04a63b1464048bba91006e854
[ "MIT" ]
null
null
null
setup.py
nilesh-kr-dubey/django-inbound-rules
5ca122bf915d17c04a63b1464048bba91006e854
[ "MIT" ]
null
null
null
import pathlib from setuptools import setup # The directory containing this file HERE = pathlib.Path(__file__).parent # The text of the README file README = (HERE / "README.md").read_text() # This call to setup() does all the work setup( name="django-inbound-rules", version="1.1.0", description="Django ...
33.704545
184
0.645314
import pathlib from setuptools import setup # The directory containing this file HERE = pathlib.Path(__file__).parent # The text of the README file README = (HERE / "README.md").read_text() # This call to setup() does all the work setup( name="django-inbound-rules", version="1.1.0", description="Django ...
0
0
0
0
0
0
0
0
0
1956a073071c209bbc51cae342eaafe640bb4376
508
py
Python
v1/chapter13/5-takeScreenshot.py
QTYResources/python-scraping
d7afe25a012fb5d079ee42372c7fce94b9494b9f
[ "MIT" ]
null
null
null
v1/chapter13/5-takeScreenshot.py
QTYResources/python-scraping
d7afe25a012fb5d079ee42372c7fce94b9494b9f
[ "MIT" ]
null
null
null
v1/chapter13/5-takeScreenshot.py
QTYResources/python-scraping
d7afe25a012fb5d079ee42372c7fce94b9494b9f
[ "MIT" ]
null
null
null
from selenium import webdriver #REPLACE WITH YOUR DRIVER PATH. EXAMPLES FOR CHROME AND PHANTOMJS driver = webdriver.PhantomJS(executable_path='../phantomjs-2.1.1-macosx/bin/phantomjs') #driver = webdriver.Chrome(executable_path='../chromedriver/chromedriver') driver.implicitly_wait(5) driver.get('http://www.pythonsc...
39.076923
87
0.818898
from selenium import webdriver from selenium.webdriver.remote.webelement import WebElement from selenium.webdriver import ActionChains #REPLACE WITH YOUR DRIVER PATH. EXAMPLES FOR CHROME AND PHANTOMJS driver = webdriver.PhantomJS(executable_path='../phantomjs-2.1.1-macosx/bin/phantomjs') #driver = webdriver.Chrome(ex...
0
0
0
0
0
0
0
60
44
a214736461c3b22a8ec607bd797d4d9b7f88a194
1,736
py
Python
oilandrope/urls.py
oil-rope/oil-and-rope
6d59c87d4809f120417a90c1624952085486bb06
[ "MIT" ]
8
2019-08-27T20:08:22.000Z
2021-07-23T22:49:47.000Z
oilandrope/urls.py
oil-rope/oil-and-rope
6d59c87d4809f120417a90c1624952085486bb06
[ "MIT" ]
73
2020-03-11T18:07:29.000Z
2022-03-28T18:07:47.000Z
oilandrope/urls.py
oil-rope/oil-and-rope
6d59c87d4809f120417a90c1624952085486bb06
[ "MIT" ]
4
2020-02-22T19:44:17.000Z
2022-03-08T09:42:45.000Z
"""oilandrope URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/2.2/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: path('', views.home, name='home') Class-ba...
32.754717
80
0.694124
"""oilandrope URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/2.2/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: path('', views.home, name='home') Class-ba...
0
0
0
0
0
0
0
0
0
fcdef3a1ffd60dc99df10f30217799615727b51f
4,467
py
Python
nbs/matricula.py
ronaldokun/cpm-joao-XXIII
0de3dc0a269d3c5bf17c5c0b111b93b01551af8d
[ "MIT" ]
null
null
null
nbs/matricula.py
ronaldokun/cpm-joao-XXIII
0de3dc0a269d3c5bf17c5c0b111b93b01551af8d
[ "MIT" ]
null
null
null
nbs/matricula.py
ronaldokun/cpm-joao-XXIII
0de3dc0a269d3c5bf17c5c0b111b93b01551af8d
[ "MIT" ]
1
2019-11-02T22:47:13.000Z
2019-11-02T22:47:13.000Z
# -*- coding: utf-8 -*- # --- # jupyter: # jupytext: # text_representation: # extension: .py # format_name: light # format_version: '1.3' # jupytext_version: 0.8.6 # kernelspec: # display_name: Python 3 # language: python # name: python3 # --- # Access and edit Google Sheets ...
22.560606
95
0.614954
# -*- coding: utf-8 -*- # --- # jupyter: # jupytext: # text_representation: # extension: .py # format_name: light # format_version: '1.3' # jupytext_version: 0.8.6 # kernelspec: # display_name: Python 3 # language: python # name: python3 # --- import pandas as pd import re ...
46
0
0
0
0
3,404
0
49
343
4f37a655a86382d93f846b1a755b235f3d4d154b
114
py
Python
euler/2.py
sara-02/dsa_sg
7c34b17772db728419070d35664ad75c67645b1e
[ "MIT" ]
null
null
null
euler/2.py
sara-02/dsa_sg
7c34b17772db728419070d35664ad75c67645b1e
[ "MIT" ]
null
null
null
euler/2.py
sara-02/dsa_sg
7c34b17772db728419070d35664ad75c67645b1e
[ "MIT" ]
null
null
null
a = 1 b = 2 c = a + b sum = 2 while c <= 4000000: if c%2 == 0: sum =sum + c a = b b = c c = a + b print sum
9.5
19
0.447368
a = 1 b = 2 c = a + b sum = 2 while c <= 4000000: if c%2 == 0: sum =sum + c a = b b = c c = a + b print sum
0
0
0
0
0
0
0
0
0
1b04f65985d461f2954f5b017d2799bccd841cfe
1,828
py
Python
sciencebeam_gym/structured_document/lxml.py
elifesciences/sciencebeam-gym
3ad654e08775e0c0cdd256753e14093bb5a42d44
[ "MIT" ]
25
2017-07-25T12:44:55.000Z
2020-09-30T22:16:50.000Z
sciencebeam_gym/structured_document/lxml.py
elifesciences/sciencebeam-gym
3ad654e08775e0c0cdd256753e14093bb5a42d44
[ "MIT" ]
192
2017-11-29T08:57:03.000Z
2022-03-29T18:44:41.000Z
sciencebeam_gym/structured_document/lxml.py
elifesciences/sciencebeam-gym
3ad654e08775e0c0cdd256753e14093bb5a42d44
[ "MIT" ]
6
2019-02-01T18:49:33.000Z
2020-07-26T08:18:46.000Z
TAG_ATTRIB_NAME = 'tag'
27.283582
84
0.688731
from sciencebeam_utils.utils.xml import ( set_or_remove_attrib ) from sciencebeam_gym.utils.bounding_box import ( BoundingBox ) from sciencebeam_gym.structured_document import ( AbstractStructuredDocument, get_scoped_attrib_name, get_attrib_by_scope ) TAG_ATTRIB_NAME = 'tag' def get_node_boundi...
0
0
0
1,182
0
275
0
206
137
c1362fe8deec65f051b72fe3170e2c65b18eeedd
237
py
Python
numpy/numpyIteratingOverArray.py
slowy07/pythonApps
22f9766291dbccd8185035745950c5ee4ebd6a3e
[ "MIT" ]
10
2020-10-09T11:05:18.000Z
2022-02-13T03:22:10.000Z
numpy/numpyIteratingOverArray.py
khairanabila/pythonApps
f90b8823f939b98f7bf1dea7ed35fe6e22e2f730
[ "MIT" ]
null
null
null
numpy/numpyIteratingOverArray.py
khairanabila/pythonApps
f90b8823f939b98f7bf1dea7ed35fe6e22e2f730
[ "MIT" ]
6
2020-11-26T12:49:43.000Z
2022-03-06T06:46:43.000Z
import numpy as np a = np.arange(12) # shape array with 3 rows and # 4 columns a = a.reshape(3,4) print('Original array is:') print(a) print() print('Modified array is:') # iterating an array for x in np.nditer(a): print(x)
14.8125
30
0.654008
import numpy as np a = np.arange(12) # shape array with 3 rows and # 4 columns a = a.reshape(3,4) print('Original array is:') print(a) print() print('Modified array is:') # iterating an array for x in np.nditer(a): print(x)
0
0
0
0
0
0
0
0
0
788c9bc3871acd7be7a51f5f8566f799e83e6d86
1,504
py
Python
nlptools/old/normalizeEmoji.py
hayj/NLPTools
46562fc03195c8fafb0654aa3f887b9b5c45a869
[ "MIT" ]
4
2019-01-18T14:20:06.000Z
2021-02-04T07:55:42.000Z
nlptools/old/normalizeEmoji.py
hayj/NLPTools
46562fc03195c8fafb0654aa3f887b9b5c45a869
[ "MIT" ]
null
null
null
nlptools/old/normalizeEmoji.py
hayj/NLPTools
46562fc03195c8fafb0654aa3f887b9b5c45a869
[ "MIT" ]
null
null
null
emojisAsciiToUtf8Strict = None emojisAsciiToUtf8 = None
37.6
88
0.701463
emojisAsciiToUtf8Strict = None emojisAsciiToUtf8 = None def normalizeEmojis(text, logger=None, verbose=True): global emojisAsciiToUtf8Strict global emojisAsciiToUtf8 if text is None or len(text) <= 1: return text if emojisAsciiToUtf8Strict is None or emojisAsciiToUtf8 is None: emojisAsciiToUtf8Strict = dict() ...
0
0
0
0
0
1,427
0
0
22
c07cfce99e7e93bd87e94c0f6b38cbaef5489f53
758
py
Python
python/python-exec/src/server.py
IMULMUL/websitesVulnerableToSSTI
0ddcae132014c4cb7324f7cfc671e733c1e775c0
[ "Apache-2.0" ]
null
null
null
python/python-exec/src/server.py
IMULMUL/websitesVulnerableToSSTI
0ddcae132014c4cb7324f7cfc671e733c1e775c0
[ "Apache-2.0" ]
null
null
null
python/python-exec/src/server.py
IMULMUL/websitesVulnerableToSSTI
0ddcae132014c4cb7324f7cfc671e733c1e775c0
[ "Apache-2.0" ]
null
null
null
app = Flask(__name__) template = '<!DOCTYPE html><html><body>\ <h1>Online Calculator</h1>\ <form action="/" method="post">\ expression:<br>\ <input type="text" name="expression" value="">\ <input type="submit" value="Submit">\ </form><h2>%s </h2></body></html>' if __name__=="__main__":...
22.294118
53
0.585752
from flask import * app = Flask(__name__) template = '<!DOCTYPE html><html><body>\ <h1>Online Calculator</h1>\ <form action="/" method="post">\ expression:<br>\ <input type="text" name="expression" value="">\ <input type="submit" value="Submit">\ </form><h2>%s </h2></body></html>' @app....
0
327
0
0
0
0
0
-2
68
da35b739dbf7dca1b1293875eb6ec7cd8e6f2cc9
7,391
py
Python
src/psiz/keras/models/rank.py
greenfieldvision/psiz
37068530a78e08792e827ee55cf55e627add115e
[ "Apache-2.0" ]
21
2020-04-03T21:10:05.000Z
2021-12-02T01:31:11.000Z
src/psiz/keras/models/rank.py
greenfieldvision/psiz
37068530a78e08792e827ee55cf55e627add115e
[ "Apache-2.0" ]
14
2020-04-10T00:48:02.000Z
2021-05-25T18:06:55.000Z
src/psiz/keras/models/rank.py
greenfieldvision/psiz
37068530a78e08792e827ee55cf55e627add115e
[ "Apache-2.0" ]
4
2020-10-13T16:46:14.000Z
2021-11-10T00:08:47.000Z
# -*- coding: utf-8 -*- # Copyright 2020 The PsiZ Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless r...
37.140704
78
0.630361
# -*- coding: utf-8 -*- # Copyright 2020 The PsiZ Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless r...
0
4,100
0
0
0
0
0
72
112
78f699b89fb6cd8f93abd36f06dc3a19458651d3
1,562
py
Python
src/genie/libs/parser/nxos/tests/ShowIpMrouteSummary/cli/equal/golden_output2_expected.py
balmasea/genieparser
d1e71a96dfb081e0a8591707b9d4872decd5d9d3
[ "Apache-2.0" ]
204
2018-06-27T00:55:27.000Z
2022-03-06T21:12:18.000Z
src/genie/libs/parser/nxos/tests/ShowIpMrouteSummary/cli/equal/golden_output2_expected.py
balmasea/genieparser
d1e71a96dfb081e0a8591707b9d4872decd5d9d3
[ "Apache-2.0" ]
468
2018-06-19T00:33:18.000Z
2022-03-31T23:23:35.000Z
src/genie/libs/parser/nxos/tests/ShowIpMrouteSummary/cli/equal/golden_output2_expected.py
balmasea/genieparser
d1e71a96dfb081e0a8591707b9d4872decd5d9d3
[ "Apache-2.0" ]
309
2019-01-16T20:21:07.000Z
2022-03-30T12:56:41.000Z
expected_output = { 'vrf': { 'vxlan-1009': { 'address_family': { 'ipv4': { 'count_multicast_starg': 11, 'count_multicast_sg': 18, 'count_multicast_total': 29, 'count_multicast_starg_prefix': 0, ...
37.190476
58
0.213188
expected_output = { 'vrf': { 'vxlan-1009': { 'address_family': { 'ipv4': { 'count_multicast_starg': 11, 'count_multicast_sg': 18, 'count_multicast_total': 29, 'count_multicast_starg_prefix': 0, ...
0
0
0
0
0
0
0
0
0
3844b3c1b40266802a6219987e07592e0f5ba9df
3,908
py
Python
src/sort_envs.py
linus87/drl_shape_optimization
39e6b66bd5b70dfce07e145aafe815071bc1b6fe
[ "MIT" ]
17
2020-12-28T16:25:47.000Z
2022-03-27T18:28:44.000Z
src/sort_envs.py
linus87/drl_shape_optimization
39e6b66bd5b70dfce07e145aafe815071bc1b6fe
[ "MIT" ]
2
2021-04-18T03:40:02.000Z
2022-01-24T08:40:10.000Z
src/sort_envs.py
linus87/drl_shape_optimization
39e6b66bd5b70dfce07e145aafe815071bc1b6fe
[ "MIT" ]
8
2020-12-23T05:59:52.000Z
2022-03-28T12:06:35.000Z
# Generic imports import os, shutil import numpy as np # Find the number of envs main_dir = '.' envs = [f.path for f in os.scandir(main_dir) if f.is_dir()] # Process names tmp = [] for env in envs: env = env[2:] if (env[0:3] == 'env'): tmp.append(env) # Printing envs = tmp print('I found ',str(len(en...
29.164179
87
0.572416
# Generic imports import os, sys, glob, shutil import numpy as np # Find the number of envs main_dir = '.' envs = [f.path for f in os.scandir(main_dir) if f.is_dir()] # Process names tmp = [] for env in envs: env = env[2:] if (env[0:3] == 'env'): tmp.append(env) # Printing envs = tmp print('I found '...
0
0
0
0
0
0
0
11
0
bd275604aedcbd3ea8eb61bb8e604d60e13461fb
1,612
py
Python
formats.py
alspitz/esc_test
4078609e3a84923b9cdbfdea8daf9814364fa9c8
[ "MIT" ]
1
2021-12-28T08:38:04.000Z
2021-12-28T08:38:04.000Z
formats.py
alspitz/esc_test
4078609e3a84923b9cdbfdea8daf9814364fa9c8
[ "MIT" ]
null
null
null
formats.py
alspitz/esc_test
4078609e3a84923b9cdbfdea8daf9814364fa9c8
[ "MIT" ]
null
null
null
import os gf2N = 9.80665 / 1000 dirpath = os.path.dirname(os.path.realpath(__file__))
22.704225
125
0.636476
import datetime import os import numpy as np from quantities import * gf2N = 9.80665 / 1000 dirpath = os.path.dirname(os.path.realpath(__file__)) class Source: def __init__(self, filename): self.filename = filename def __str__(self): return self.__class__.__name__ class CSVSource(Source): def read(...
0
0
0
1,370
0
0
0
-6
160
b9f1d76a72d34b1a60e1eecfdda0647412221cd0
1,337
py
Python
path_thin.py
ChainBreak/line_drawing
2c999083f0b530a839b2588e75e7f5fd17ab3a5d
[ "MIT" ]
1
2020-02-16T11:33:47.000Z
2020-02-16T11:33:47.000Z
path_thin.py
ChainBreak/line_drawing
2c999083f0b530a839b2588e75e7f5fd17ab3a5d
[ "MIT" ]
null
null
null
path_thin.py
ChainBreak/line_drawing
2c999083f0b530a839b2588e75e7f5fd17ab3a5d
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 if __name__ == "__main__": print("Hello There!")
20.257576
55
0.481675
#!/usr/bin/env python3 import math def thin(path_list): for path in path_list: l = len(path) if l > 3: old_path = path.copy() path.clear() p0 = old_path[0] p2 = old_path[1] path.append(p0) for i in range(2,l): ...
0
0
0
0
0
1,197
0
-10
68
def8b64ed9f1e43acb27abd8c1cc1537f9aa27ff
545
py
Python
dashcollege/src/pool/urls.py
Akash-Sharma-1/dashcollege
02832c2104637e32f5133da9d16b73bf7ba16c0a
[ "MIT" ]
null
null
null
dashcollege/src/pool/urls.py
Akash-Sharma-1/dashcollege
02832c2104637e32f5133da9d16b73bf7ba16c0a
[ "MIT" ]
null
null
null
dashcollege/src/pool/urls.py
Akash-Sharma-1/dashcollege
02832c2104637e32f5133da9d16b73bf7ba16c0a
[ "MIT" ]
null
null
null
from django.urls import path from . import views app_name = 'pool' urlpatterns = [ path('pool/', views.Pool.as_view(), name='pool'), path('pool/cab/', views.PoolCab.as_view(), name='cab'), path('pool/food/', views.PoolFood.as_view(), name='food'), path('pool/others/', views.PoolMisc.as_view(), name='ot...
38.928571
71
0.656881
from django.urls import path from . import views from django.conf.urls import url app_name = 'pool' urlpatterns = [ path('pool/', views.Pool.as_view(), name='pool'), path('pool/cab/', views.PoolCab.as_view(), name='cab'), path('pool/food/', views.PoolFood.as_view(), name='food'), path('pool/others/', v...
0
0
0
0
0
0
0
11
22
65a040bacaf5d53253989daaf3c527fbf1393b4b
2,382
py
Python
simulator/pybullet/manipulator_main.py
junhyeokahn/ASE389
a57d668f968da1db56f0dfe8dadad548ad631f33
[ "MIT" ]
null
null
null
simulator/pybullet/manipulator_main.py
junhyeokahn/ASE389
a57d668f968da1db56f0dfe8dadad548ad631f33
[ "MIT" ]
null
null
null
simulator/pybullet/manipulator_main.py
junhyeokahn/ASE389
a57d668f968da1db56f0dfe8dadad548ad631f33
[ "MIT" ]
3
2021-02-05T06:59:43.000Z
2021-05-11T20:14:02.000Z
import os import sys cwd = os.getcwd() sys.path.append(cwd) import time import pybullet as p import numpy as np from util import pybullet_util from config.manipulator_config import ManipulatorConfig from pnc.manipulator_pnc.manipulator_interface import ManipulatorInterface if __name__ == "__main__": # Environme...
31.342105
119
0.619228
import os import sys cwd = os.getcwd() sys.path.append(cwd) import time, math from collections import OrderedDict import pybullet as p import numpy as np from util import pybullet_util from config.manipulator_config import ManipulatorConfig from pnc.manipulator_pnc.manipulator_interface import ManipulatorInterface i...
0
0
0
0
0
0
0
20
22
e6fe1fccd65a5ef935d782807aa32e17cc47c4f3
4,972
py
Python
src/DioGUI.py
daign/daign-image-organizer
4ce69681d01260594b7156b3ed944dc386244ae2
[ "MIT" ]
null
null
null
src/DioGUI.py
daign/daign-image-organizer
4ce69681d01260594b7156b3ed944dc386244ae2
[ "MIT" ]
null
null
null
src/DioGUI.py
daign/daign-image-organizer
4ce69681d01260594b7156b3ed944dc386244ae2
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*-
26.588235
95
0.734714
#!/usr/bin/env python # -*- coding: utf-8 -*- import random from PyQt4 import QtGui from PyQt4 import QtCore import Database from DioView import DioView from DioDetails import DioDetails from DioScanDialog import DioScanDialog class DioGUI( QtGui.QSplitter ): def __init__( self, parent = None ): QtGui.QSplitte...
0
0
0
4,717
0
0
0
27
179
c964fcb822ead37433ac5cf5759b2dcade6d3081
1,919
py
Python
Tool/music_img_getter.py
bosssu/LocalMusicPlayerVR
0147c1300bb3e2a35c0ba46e628fd25963801b5c
[ "MIT" ]
2
2019-11-01T11:42:51.000Z
2020-03-10T07:24:51.000Z
Tool/music_img_getter.py
bosssu/LocalMusicPlayerVR
0147c1300bb3e2a35c0ba46e628fd25963801b5c
[ "MIT" ]
null
null
null
Tool/music_img_getter.py
bosssu/LocalMusicPlayerVR
0147c1300bb3e2a35c0ba46e628fd25963801b5c
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import os current_dir = os.getcwd() fileNameList_all = os.listdir(current_dir) fileNameList_shouldUse = [] failelist = [] success_amount = 0 #https://www.jianshu.com/p/53cf61220828 #mp3 if(len(fileNameList_all) > 0): for filename in fileNameList_all: if(filename.endswith('.json...
30.460317
157
0.596144
# -*- coding: utf-8 -*- import mutagen import os import json current_dir = os.getcwd() fileNameList_all = os.listdir(current_dir) fileNameList_shouldUse = [] failelist = [] success_amount = 0 #https://www.jianshu.com/p/53cf61220828 感谢这位老哥的帖子 #提取同目录下所有mp3的封面图和一些其他信息 def AudioFileAssetsExport(name): global succ...
126
0
0
0
0
753
0
-17
67
7904b86d8abe58e7e4529517770077d8ca8f90b5
140
py
Python
metrics/outputs/__init__.py
sebMathieu/code_metrics
f188041c8f2c0950c5f63a1f719cdb05aaeb42c9
[ "MIT" ]
null
null
null
metrics/outputs/__init__.py
sebMathieu/code_metrics
f188041c8f2c0950c5f63a1f719cdb05aaeb42c9
[ "MIT" ]
null
null
null
metrics/outputs/__init__.py
sebMathieu/code_metrics
f188041c8f2c0950c5f63a1f719cdb05aaeb42c9
[ "MIT" ]
null
null
null
""" Output formats. """
14
28
0.735714
""" Output formats. """ from .rst import RST from .console import Console from .json import JSON from .svg import SVG from .png import PNG
0
0
0
0
0
0
0
5
111
5a27514d3ca08d3797946bc9e86882294446f79d
13,040
py
Python
views/web/dustWeb/WebPage.py
twatteynelinear/dustlink_sierra
9dac02d4fdfdee240a8a9da2e6abc2d7fda3443b
[ "BSD-3-Clause" ]
4
2016-09-07T05:46:20.000Z
2020-05-31T21:34:27.000Z
views/web/dustWeb/WebPage.py
twatteynelinear/dustlink_sierra
9dac02d4fdfdee240a8a9da2e6abc2d7fda3443b
[ "BSD-3-Clause" ]
null
null
null
views/web/dustWeb/WebPage.py
twatteynelinear/dustlink_sierra
9dac02d4fdfdee240a8a9da2e6abc2d7fda3443b
[ "BSD-3-Clause" ]
6
2015-01-22T10:14:24.000Z
2020-05-31T21:34:30.000Z
import logging log = logging.getLogger('WebPage') log.setLevel(logging.ERROR) log.addHandler(NullHandler()) import os TEMPLATE_PATH = os.path.join('templates') LOOK_AND_FEEL = 'dust'
38.017493
108
0.486887
import logging class NullHandler(logging.Handler): def emit(self, record): pass log = logging.getLogger('WebPage') log.setLevel(logging.ERROR) log.addHandler(NullHandler()) import os import urllib import web from viz import Viz, \ VizBanner TEMPLATE_PATH = os.path.join('temp...
0
855
0
11,865
0
0
0
9
116
07cae2206f471e746a05cb99a1ed9977cf590a4a
43,501
py
Python
CrimsonApi/monitorpackage/MonitorApi.py
denisdoci/PythonCrimsonHexagonAPI
3f5cc3167586e236846d1843c80ff5e941cb497b
[ "MIT" ]
null
null
null
CrimsonApi/monitorpackage/MonitorApi.py
denisdoci/PythonCrimsonHexagonAPI
3f5cc3167586e236846d1843c80ff5e941cb497b
[ "MIT" ]
null
null
null
CrimsonApi/monitorpackage/MonitorApi.py
denisdoci/PythonCrimsonHexagonAPI
3f5cc3167586e236846d1843c80ff5e941cb497b
[ "MIT" ]
null
null
null
# # Created by Denis Doci # # Copyright Mars Inc. # # For internal use only #
44.754115
119
0.517229
# # Created by Denis Doci # # Copyright Mars Inc. # # For internal use only # import requests import json import pandas as pd import numpy as np import datetime import itertools import math from datetime import date, timedelta class monitor_api: monitorId = '' authenticationToken = '' def __init__(self, ...
0
0
0
43,251
0
0
0
-27
199
2f44edd03c922dc384d4313154a00786eacb401a
5,756
py
Python
tests/tests_py/test_interpreter.py
absheik/forthic
1d481f8a4c0c1cc7250eb5886bed43dfb4f201c0
[ "BSD-2-Clause" ]
6
2021-08-18T19:14:09.000Z
2022-02-20T05:43:46.000Z
tests/tests_py/test_interpreter.py
absheik/forthic
1d481f8a4c0c1cc7250eb5886bed43dfb4f201c0
[ "BSD-2-Clause" ]
1
2021-11-25T05:08:28.000Z
2021-12-01T15:41:21.000Z
tests/tests_py/test_interpreter.py
absheik/forthic
1d481f8a4c0c1cc7250eb5886bed43dfb4f201c0
[ "BSD-2-Clause" ]
1
2021-11-25T05:03:53.000Z
2021-11-25T05:03:53.000Z
import unittest if __name__ == '__main__': unittest.main()
32.156425
93
0.602849
import unittest import datetime from forthic.interpreter import Interpreter from forthic.module import Module, ModuleWord from tests.tests_py.sample_date_module import SampleDateModule class TestInterpreter(unittest.TestCase): def test_initial_state(self): interp = Interpreter() self.assertEqual(0...
0
0
0
5,499
0
0
0
81
111
68a3bd6446909308226cbeb22dd1ba7ed851a48d
4,379
py
Python
learntools/computer_vision/ex5.py
roannav/learntools
355a5df6a66562de62254b723da1a9389b9acc49
[ "Apache-2.0" ]
359
2018-03-23T15:57:52.000Z
2022-03-25T21:56:28.000Z
learntools/computer_vision/ex5.py
roannav/learntools
355a5df6a66562de62254b723da1a9389b9acc49
[ "Apache-2.0" ]
84
2018-06-14T00:06:52.000Z
2022-02-08T17:25:54.000Z
learntools/computer_vision/ex5.py
roannav/learntools
355a5df6a66562de62254b723da1a9389b9acc49
[ "Apache-2.0" ]
213
2018-05-02T19:06:31.000Z
2022-03-20T15:40:34.000Z
qvars = bind_exercises(globals(), [ Q1, Q2, Q3, ], var_format='q_{n}', ) __all__ = list(qvars)
36.491667
410
0.622288
import tensorflow as tf from learntools.core import * class Q1(CodingProblem): _hint = """You should add two `Conv2D` layers and then a `MaxPool2D` layer. They will be just the same as the other layers in the model, except for some of the parameter values.""" _solution = CS(""" from tensorflow import keras f...
0
0
0
4,131
0
0
0
10
122
91328e065e28cec093506bd0b92c8120a36efe5e
76
py
Python
code/ans2/ans2.py
hedgerow512/coding-question-answers
72ffa6aefac660f226470029b02db2ea87999b4f
[ "CC0-1.0" ]
null
null
null
code/ans2/ans2.py
hedgerow512/coding-question-answers
72ffa6aefac660f226470029b02db2ea87999b4f
[ "CC0-1.0" ]
null
null
null
code/ans2/ans2.py
hedgerow512/coding-question-answers
72ffa6aefac660f226470029b02db2ea87999b4f
[ "CC0-1.0" ]
null
null
null
i = 0 for i in range(0, 100): if i % 2 == 0: print(i) i+= i
12.666667
23
0.394737
i = 0 for i in range(0, 100): if i % 2 == 0: print(i) i+= i
0
0
0
0
0
0
0
0
0