hexsha
stringlengths
40
40
size
int64
7
1.04M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
247
max_stars_repo_name
stringlengths
4
125
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
125
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
125
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.77
618k
max_line_length
int64
1
1.02M
alphanum_fraction
float64
0
1
original_content
stringlengths
7
1.04M
filtered:remove_function_no_docstring
int64
-102
942k
filtered:remove_class_no_docstring
int64
-354
977k
filtered:remove_delete_markers
int64
0
60.1k
d5ef128295058d5c0311565981be4c150f1cbbe2
1,232
py
Python
printer.py
MarcWarrior/NeteaseMusicDownloader
cca610557a480393977824d72c2cdc86aa6bd66f
[ "MIT" ]
2
2020-03-19T09:52:34.000Z
2022-01-08T23:39:55.000Z
printer.py
MarcWarrior/NeteaseMusicDownloader
cca610557a480393977824d72c2cdc86aa6bd66f
[ "MIT" ]
null
null
null
printer.py
MarcWarrior/NeteaseMusicDownloader
cca610557a480393977824d72c2cdc86aa6bd66f
[ "MIT" ]
1
2020-03-19T09:52:38.000Z
2020-03-19T09:52:38.000Z
#!/usr/bin/env python3 # -*-coding:utf-8 -*- import os import time from colorama import init from termcolor import cprint init()
28.651163
108
0.579545
#!/usr/bin/env python3 # -*-coding:utf-8 -*- import os import time from colorama import init from termcolor import cprint init() class Printer: instance = None def __new__(cls): if not cls.instance: cls.instance = super().__new__(cls) return cls.instance @staticmethod d...
857
220
23
1891cbeb9a52c2f67a3b2f46215c969ccb248f2c
6,109
py
Python
rebound/python_examples/longtermtest/problem.py
rodluger/ttv-devil
e534e4f3cd75db951cba54441f7a5458c87e0cf9
[ "MIT" ]
null
null
null
rebound/python_examples/longtermtest/problem.py
rodluger/ttv-devil
e534e4f3cd75db951cba54441f7a5458c87e0cf9
[ "MIT" ]
null
null
null
rebound/python_examples/longtermtest/problem.py
rodluger/ttv-devil
e534e4f3cd75db951cba54441f7a5458c87e0cf9
[ "MIT" ]
null
null
null
# Import the rebound module import sys import matplotlib; matplotlib.use("pdf") import matplotlib.pyplot as plt from matplotlib import ticker from matplotlib.colors import LogNorm import rebound import numpy as np import time from rebound.interruptible_pool import InterruptiblePool import warnings Ngrid = 500 #3dt = 1...
36.580838
207
0.609429
# Import the rebound module import sys import matplotlib; matplotlib.use("pdf") import matplotlib.pyplot as plt from matplotlib import ticker from matplotlib.colors import LogNorm import rebound import numpy as np import time from rebound.interruptible_pool import InterruptiblePool import warnings def simulation(par):...
3,704
0
23
3953b88e492cc23747d555780346b4d3e0cd4074
3,153
py
Python
theseus/semantic/metrics/dicecoeff.py
kaylode/Custom-Template
b2f11bfacf2b03b793476a19781f9046fab6fd82
[ "MIT" ]
2
2022-02-18T04:41:29.000Z
2022-03-12T09:04:14.000Z
theseus/semantic/metrics/dicecoeff.py
kaylode/Custom-Template
b2f11bfacf2b03b793476a19781f9046fab6fd82
[ "MIT" ]
8
2022-02-16T17:01:28.000Z
2022-03-28T02:53:45.000Z
theseus/semantic/metrics/dicecoeff.py
lannguyen0910/theseus
5c08fb2f4a9c7ffa395788e6a0ade43780e8bd7d
[ "MIT" ]
3
2022-02-13T05:00:13.000Z
2022-03-02T00:11:27.000Z
from typing import Any, Dict, Optional import torch import numpy as np from theseus.base.metrics.metric_template import Metric class DiceScore(Metric): """ Dice score metric for segmentation num_classes: `int` number of classes eps: `float` epsilon to avoid zero division thresh: `float...
35.426966
94
0.583571
from typing import Any, Dict, Optional import torch import numpy as np from theseus.base.metrics.metric_template import Metric class DiceScore(Metric): """ Dice score metric for segmentation num_classes: `int` number of classes eps: `float` epsilon to avoid zero division thresh: `float...
1,559
0
115
29a4c6b961b039a113ca0c467cadee5f671056b1
2,187
py
Python
monodromy/io/lrcalc.py
Qiskit/monodromy
97829c1289c8a79b6ae3ab29eb7f4ad1ea79d5ab
[ "Apache-2.0" ]
6
2022-01-04T19:12:32.000Z
2022-02-28T05:48:14.000Z
monodromy/io/lrcalc.py
Qiskit/monodromy
97829c1289c8a79b6ae3ab29eb7f4ad1ea79d5ab
[ "Apache-2.0" ]
null
null
null
monodromy/io/lrcalc.py
Qiskit/monodromy
97829c1289c8a79b6ae3ab29eb7f4ad1ea79d5ab
[ "Apache-2.0" ]
1
2022-01-05T09:07:23.000Z
2022-01-05T09:07:23.000Z
""" monodromy/io/lrcalc.py Extracts quantum Littlewood-Richardson coefficients from the package `lrcalc`. This package is cumbersome to install, so we provide a prebaked copy of this table in `qlr_table.py`. """ from copy import copy import lrcalc def qlr(r, k, a, b): """ Computes the quantum Littlewood-R...
29.16
80
0.549154
""" monodromy/io/lrcalc.py Extracts quantum Littlewood-Richardson coefficients from the package `lrcalc`. This package is cumbersome to install, so we provide a prebaked copy of this table in `qlr_table.py`. """ from copy import copy import lrcalc def qlr(r, k, a, b): """ Computes the quantum Littlewood-R...
0
0
0
7d5df58d9e6ea1a45dcaa9ff8931c62a25d30dbf
6,739
py
Python
examples/runner_battdeg.py
rafyzg/BattDeg
39ba00e83f2783b3249d002b26794677f8e9f429
[ "MIT" ]
10
2020-01-15T17:49:52.000Z
2021-08-01T12:35:02.000Z
examples/runner_battdeg.py
rafyzg/BattDeg
39ba00e83f2783b3249d002b26794677f8e9f429
[ "MIT" ]
19
2019-03-08T07:15:09.000Z
2022-02-10T00:06:21.000Z
examples/runner_battdeg.py
rafyzg/BattDeg
39ba00e83f2783b3249d002b26794677f8e9f429
[ "MIT" ]
13
2019-03-05T01:08:08.000Z
2021-12-15T12:19:54.000Z
import pandas as pd import numpy as np import datetime import os import re from os import listdir from os.path import isfile, join import matplotlib.pyplot as plt import seaborn as sns @profile def date_time_converter(date_time_list): """ This function gets the numpy array with date_time in matlab format ...
38.073446
111
0.677103
import pandas as pd import numpy as np import datetime import os import re from os import listdir from os.path import isfile, join import matplotlib.pyplot as plt import seaborn as sns @profile def date_time_converter(date_time_list): """ This function gets the numpy array with date_time in matlab format ...
0
0
0
dd09fe2dae7258e64c6bee6ccfe30ca6b0b7e4b7
3,016
py
Python
utuclient/player.py
katajakasa/utuputki2-client
1bfdaf18f5507108de2255817b654a4b2bf34cf3
[ "MIT" ]
null
null
null
utuclient/player.py
katajakasa/utuputki2-client
1bfdaf18f5507108de2255817b654a4b2bf34cf3
[ "MIT" ]
null
null
null
utuclient/player.py
katajakasa/utuputki2-client
1bfdaf18f5507108de2255817b654a4b2bf34cf3
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from gi.repository import GObject as gobject, Gst as gst, Gtk as gtk, GdkX11, GstVideo import platform import logging log = logging.getLogger(__name__)
30.464646
91
0.606432
# -*- coding: utf-8 -*- from gi.repository import GObject as gobject, Gst as gst, Gtk as gtk, GdkX11, GstVideo import platform import logging log = logging.getLogger(__name__) class Player(object): VIDEO = 0 IMAGE = 1 def __init__(self, window, url, cb_finish, cb_error, mode=VIDEO): self.window...
2,462
352
23
1158d699a873a4e35d1470483197a439452f8175
2,486
py
Python
tests/test_surround.py
wuub/rxv
da90b758da6e1cd5082bd8931f183662e54b1903
[ "BSD-3-Clause" ]
97
2015-01-21T07:04:04.000Z
2021-11-02T15:40:20.000Z
tests/test_surround.py
wuub/rxv
da90b758da6e1cd5082bd8931f183662e54b1903
[ "BSD-3-Clause" ]
68
2015-02-10T11:53:24.000Z
2022-03-02T02:20:03.000Z
tests/test_surround.py
wuub/rxv
da90b758da6e1cd5082bd8931f183662e54b1903
[ "BSD-3-Clause" ]
49
2015-02-07T15:27:38.000Z
2021-12-29T09:31:41.000Z
import unittest import requests_mock import rxv FAKE_IP = '10.0.0.0' DESC_XML = 'http://%s/YamahaRemoteControl/desc.xml' % FAKE_IP CTRL_URL = 'http://%s/YamahaRemoteControl/ctrl' % FAKE_IP
36.558824
92
0.641995
import unittest import requests_mock import rxv FAKE_IP = '10.0.0.0' DESC_XML = 'http://%s/YamahaRemoteControl/desc.xml' % FAKE_IP CTRL_URL = 'http://%s/YamahaRemoteControl/ctrl' % FAKE_IP def sample_content(name): with open('tests/samples/%s' % name) as f: return f.read() class TestSurroundRXV(unittes...
2,069
179
46
e00754c1b3377a2b65d5833ce458aa6a79274a31
6,276
py
Python
tools/toc.py
donalm/cefpython
ce21ff975194ea1b17a9061ceb66648cbb3115c5
[ "CNRI-Python", "RSA-MD", "Linux-OpenIB" ]
1
2018-08-03T07:04:47.000Z
2018-08-03T07:04:47.000Z
tools/toc.py
donalm/cefpython
ce21ff975194ea1b17a9061ceb66648cbb3115c5
[ "CNRI-Python", "RSA-MD", "Linux-OpenIB" ]
null
null
null
tools/toc.py
donalm/cefpython
ce21ff975194ea1b17a9061ceb66648cbb3115c5
[ "CNRI-Python", "RSA-MD", "Linux-OpenIB" ]
1
2021-07-22T04:29:54.000Z
2021-07-22T04:29:54.000Z
# Copyright (c) 2016 CEF Python, see the Authors file. # All rights reserved. Licensed under BSD 3-clause license. # Project website: https://github.com/cztomczak/cefpython """Create Table of contents (TOC) for a single .md file or for a directory. Usage: toc.py FILE toc.py DIR To ignore file when generating...
34.295082
78
0.559592
# Copyright (c) 2016 CEF Python, see the Authors file. # All rights reserved. Licensed under BSD 3-clause license. # Project website: https://github.com/cztomczak/cefpython """Create Table of contents (TOC) for a single .md file or for a directory. Usage: toc.py FILE toc.py DIR To ignore file when generating...
0
0
0
16818b951e58a2893fa4120c7868e99ff2ed156b
4,471
py
Python
Payload_Type/apollo/mythic/agent_functions/ls.py
tmcmil/Apollo
5e7754e53b0bd3bdefe4349b50eecc37c7b70ad7
[ "BSD-3-Clause" ]
null
null
null
Payload_Type/apollo/mythic/agent_functions/ls.py
tmcmil/Apollo
5e7754e53b0bd3bdefe4349b50eecc37c7b70ad7
[ "BSD-3-Clause" ]
null
null
null
Payload_Type/apollo/mythic/agent_functions/ls.py
tmcmil/Apollo
5e7754e53b0bd3bdefe4349b50eecc37c7b70ad7
[ "BSD-3-Clause" ]
null
null
null
from mythic_payloadtype_container.MythicCommandBase import * import json
38.213675
118
0.519123
from mythic_payloadtype_container.MythicCommandBase import * import json class LsArguments(TaskArguments): def __init__(self, command_line, **kwargs): super().__init__(command_line, **kwargs) self.args = [ CommandParameter( name="host", cli_name="Host",...
3,621
648
127
9cfa3eeaeb88cbcd76182b31b503d13fe3319968
6,615
py
Python
scratch/jpg.py
chk141/stegosploit-python
687edb9c9bfc5c0f2b4b9f2d8ff2e37c53833198
[ "WTFPL" ]
9
2019-02-21T07:27:01.000Z
2021-11-09T00:18:17.000Z
scratch/jpg.py
amichael7/python-stegosploit
078934213e48d41f176b7e1e61422e4ad0bdbf5b
[ "WTFPL" ]
null
null
null
scratch/jpg.py
amichael7/python-stegosploit
078934213e48d41f176b7e1e61422e4ad0bdbf5b
[ "WTFPL" ]
2
2020-05-04T13:00:54.000Z
2021-06-19T05:56:29.000Z
''' jpg.py <alexmichael@uchicago.edu> Description: Prototype of polyglot generator. TODO: - [ ] Build the least significant bit layer injector ''' import struct import re import random if __name__ == '__main__': main() # read() # test()
29.013158
1,140
0.647468
''' jpg.py <alexmichael@uchicago.edu> Description: Prototype of polyglot generator. TODO: - [ ] Build the least significant bit layer injector ''' import struct import re import random class Polyglot: def __init__(self): self.infile = open('stego.jpg','rb') self.outfile = open('out3.html','wb') def genRan...
6,183
-6
187
3ba17cb32481b123c951bdcfe07822edf9a689ba
6,614
py
Python
pyny/node.py
namuyan/pyny
c48f0aa9f61ab0628e08236c27ff4cde92d34f3b
[ "BSD-2-Clause" ]
1
2020-02-29T03:41:17.000Z
2020-02-29T03:41:17.000Z
pyny/node.py
namuyan/pyny
c48f0aa9f61ab0628e08236c27ff4cde92d34f3b
[ "BSD-2-Clause" ]
null
null
null
pyny/node.py
namuyan/pyny
c48f0aa9f61ab0628e08236c27ff4cde92d34f3b
[ "BSD-2-Clause" ]
null
null
null
'''Winny Node. ''' # # Copyright (c) 2006 Pyny Project. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list...
28.508621
88
0.592985
'''Winny Node. ''' # # Copyright (c) 2006 Pyny Project. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list...
2,018
0
212
ad8435b5d4017d9f560a513aa159bd374be32be4
1,012
py
Python
auto_ping.py
XC-Li/Raspberry_Projects
48b61832641fea1dcbd24b651266fe767d8cd254
[ "MIT" ]
null
null
null
auto_ping.py
XC-Li/Raspberry_Projects
48b61832641fea1dcbd24b651266fe767d8cd254
[ "MIT" ]
null
null
null
auto_ping.py
XC-Li/Raspberry_Projects
48b61832641fea1dcbd24b651266fe767d8cd254
[ "MIT" ]
null
null
null
# This is the program to run ping test on local network # XC.Li @ Apr.10 2018 # read in ping_list and ping_config ping_list, ping_config = start_up("ping_list.txt", "ping_config.txt") print(ping_list) print(ping_config)
29.764706
70
0.652174
# This is the program to run ping test on local network # XC.Li @ Apr.10 2018 # read in ping_list and ping_config def start_up(ping_list_fn, ping_config_fn): ping_list_file_name = ping_list_fn ping_list_file = open(ping_list_file_name,"r") ping_list = {} for line in ping_list_file: l...
753
0
23
e81bd792870a0dfb3237f277456bdd8f9d39dbc4
140
py
Python
schools3/config/ml/experiments/cross_tabs_experiment_config.py
dssg/mlpolicylab_fall20_schools3_public
f8eff4c56e9bada1eb81ddaca03686d7ef53c2c4
[ "MIT" ]
null
null
null
schools3/config/ml/experiments/cross_tabs_experiment_config.py
dssg/mlpolicylab_fall20_schools3_public
f8eff4c56e9bada1eb81ddaca03686d7ef53c2c4
[ "MIT" ]
null
null
null
schools3/config/ml/experiments/cross_tabs_experiment_config.py
dssg/mlpolicylab_fall20_schools3_public
f8eff4c56e9bada1eb81ddaca03686d7ef53c2c4
[ "MIT" ]
null
null
null
import sys from schools3.config import base_config config = base_config.Config() config.num_features = 10 sys.modules[__name__] = config
15.555556
39
0.792857
import sys from schools3.config import base_config config = base_config.Config() config.num_features = 10 sys.modules[__name__] = config
0
0
0
b66dac366c5b7d055a02ed46b14a39c6d3ca594e
4,476
py
Python
infrastructure/tools/batchdelete.py
uk-gov-mirror/NHSX.covid-chest-imaging-database
77799a97193d09e9267182d18fbb79d604bbb038
[ "MIT" ]
56
2020-04-08T12:40:28.000Z
2021-10-02T22:57:16.000Z
infrastructure/tools/batchdelete.py
uk-gov-mirror/NHSX.covid-chest-imaging-database
77799a97193d09e9267182d18fbb79d604bbb038
[ "MIT" ]
111
2020-04-02T13:23:06.000Z
2022-03-30T13:23:28.000Z
infrastructure/tools/batchdelete.py
uk-gov-mirror/NHSX.covid-chest-imaging-database
77799a97193d09e9267182d18fbb79d604bbb038
[ "MIT" ]
10
2020-05-05T14:07:11.000Z
2022-01-11T15:47:27.000Z
#!/usr/bin/env python import argparse import math import sys from concurrent.futures import ThreadPoolExecutor, as_completed import boto3 from tqdm.auto import tqdm client = boto3.client("s3") objects = [] parser = argparse.ArgumentParser(description="Delete files from S3") parser.add_argument("--bucket", help="The...
32.201439
98
0.606122
#!/usr/bin/env python import argparse import math import sys from concurrent.futures import ThreadPoolExecutor, as_completed import boto3 from tqdm.auto import tqdm client = boto3.client("s3") objects = [] parser = argparse.ArgumentParser(description="Delete files from S3") parser.add_argument("--bucket", help="The...
1,202
0
23
caa7cfa00699a920210f1adb177a1534ba707a0d
5,708
py
Python
train.py
UrbanOS-Examples/PredictiveParking
778acb68a0c8be78655d38698ab68f1c1b47cbc5
[ "Apache-2.0" ]
2
2021-03-29T03:36:32.000Z
2021-07-01T16:51:18.000Z
train.py
UrbanOS-Examples/PredictiveParking
778acb68a0c8be78655d38698ab68f1c1b47cbc5
[ "Apache-2.0" ]
null
null
null
train.py
UrbanOS-Examples/PredictiveParking
778acb68a0c8be78655d38698ab68f1c1b47cbc5
[ "Apache-2.0" ]
1
2022-01-28T15:56:00.000Z
2022-01-28T15:56:00.000Z
#!/usr/bin/env python3 import configparser import getpass import logging import os import sys from dataclasses import InitVar, dataclass from datetime import date, datetime, timedelta from pathlib import Path import pandas as pd import pyodbc from prometheus_client import CollectorRegistry, Gauge, push_to_gateway fro...
33.576471
104
0.692537
#!/usr/bin/env python3 import configparser import getpass import logging import os import sys from dataclasses import InitVar, dataclass from datetime import date, datetime, timedelta from pathlib import Path import pandas as pd import pyodbc from prometheus_client import CollectorRegistry, Gauge, push_to_gateway fro...
4,645
120
183
74964d9336f7d99fb8cee5047b7ac3e34e05ce4a
8,356
py
Python
tests/test_pyhpeimc_plat_system.py
HPNetworking/HP-Intelligent-Management-Center
4fba31827573587e03a6233c7db60f188038c8e5
[ "Apache-2.0" ]
13
2016-03-14T17:55:03.000Z
2021-03-26T07:18:26.000Z
tests/test_pyhpeimc_plat_system.py
HPNetworking/HP-Intelligent-Management-Center
4fba31827573587e03a6233c7db60f188038c8e5
[ "Apache-2.0" ]
7
2016-08-04T17:39:11.000Z
2017-09-19T13:42:35.000Z
tests/test_pyhpeimc_plat_system.py
HPNetworking/HP-Intelligent-Management-Center
4fba31827573587e03a6233c7db60f188038c8e5
[ "Apache-2.0" ]
17
2016-03-03T05:24:20.000Z
2022-03-10T08:16:31.000Z
# -*- coding: utf-8 -*- """ This module is used for testing the functions within the pyhpeimc.plat.system module. """ from unittest import TestCase from pyhpeimc.plat.system import * from test_machine import auth # get_system_category # get_system_device_models # get_system_series # Section deals with devic...
34.962343
96
0.620273
# -*- coding: utf-8 -*- """ This module is used for testing the functions within the pyhpeimc.plat.system module. """ from unittest import TestCase from pyhpeimc.plat.system import * from test_machine import auth class TestGet_system_vendors(TestCase): def test_get_system_vendors_type(self): vendors = ...
4,313
2,029
486
bfbcec6a8ee5fbcb969bbb111e067bf54dd04755
3,548
py
Python
local_dump.py
jhyuklee/sparc
bee309bdffd73d162c23a7c3c0b63cebe4aaea97
[ "Apache-2.0" ]
48
2020-05-01T07:10:51.000Z
2022-03-19T09:09:41.000Z
local_dump.py
jhyuklee/sparc
bee309bdffd73d162c23a7c3c0b63cebe4aaea97
[ "Apache-2.0" ]
1
2020-10-23T19:04:52.000Z
2020-11-06T03:18:46.000Z
local_dump.py
jhyuklee/sparc
bee309bdffd73d162c23a7c3c0b63cebe4aaea97
[ "Apache-2.0" ]
12
2020-05-07T08:32:07.000Z
2021-04-26T02:19:31.000Z
import argparse import math import os import subprocess if __name__ == '__main__': main()
40.781609
105
0.627678
import argparse import math import os import subprocess def run_dump_phrase(args): parallel = '--parallel' if args.parallel else '' do_case = '--do_case' if args.do_case else '' use_biobert = '--use_biobert' if args.use_biobert else '' append_title = '--append_title' if args.append_title else '' ...
3,380
0
69
16f24d171e4d038a84215a3fe535a1ab99c69de6
5,292
py
Python
app.py
Abdulaziz-Hassan/todolist-website
1ab434ab0f17a41d74da13eef3ee11fe618f5c7d
[ "MIT" ]
null
null
null
app.py
Abdulaziz-Hassan/todolist-website
1ab434ab0f17a41d74da13eef3ee11fe618f5c7d
[ "MIT" ]
null
null
null
app.py
Abdulaziz-Hassan/todolist-website
1ab434ab0f17a41d74da13eef3ee11fe618f5c7d
[ "MIT" ]
1
2021-10-06T00:22:17.000Z
2021-10-06T00:22:17.000Z
from flask import Flask, render_template, redirect, url_for, flash from flask_bootstrap import Bootstrap from flask_ckeditor import CKEditor from flask_login import login_user, LoginManager, current_user, logout_user, login_required from werkzeug.security import generate_password_hash, check_password_hash from dotenv i...
33.493671
107
0.683862
from flask import Flask, render_template, redirect, url_for, flash from flask_bootstrap import Bootstrap from flask_ckeditor import CKEditor from flask_login import login_user, LoginManager, current_user, logout_user, login_required from werkzeug.security import generate_password_hash, check_password_hash from dotenv i...
3,510
0
198
8a46116e77bc676f3f2e0b86a6d0744c6d076126
5,695
py
Python
TikTok-Views-BOT.py
aneppew/test-2
09141d0b94cf8a13a79e9c93e801973a50d2b08e
[ "BSL-1.0" ]
null
null
null
TikTok-Views-BOT.py
aneppew/test-2
09141d0b94cf8a13a79e9c93e801973a50d2b08e
[ "BSL-1.0" ]
null
null
null
TikTok-Views-BOT.py
aneppew/test-2
09141d0b94cf8a13a79e9c93e801973a50d2b08e
[ "BSL-1.0" ]
null
null
null
#coding: utf-8 from selenium import webdriver from webdriver_manager.chrome import ChromeDriverManager from selenium import webdriver from selenium.common.exceptions import TimeoutException from selenium.common.exceptions import NoSuchElementException from selenium.webdriver.support.ui import WebDriverWait fro...
32.729885
130
0.600702
#coding: utf-8 from selenium import webdriver from webdriver_manager.chrome import ChromeDriverManager from selenium import webdriver from selenium.common.exceptions import TimeoutException from selenium.common.exceptions import NoSuchElementException from selenium.webdriver.support.ui import WebDriverWait fro...
4,536
0
173
56ad1660dbb7bac6852c27d799d0133363c566fc
5,661
py
Python
tests/module_cfg/test_env_vars.py
filfreire/questions-three
1d1d621d5647407bf2d1b271e0b9c7c9f1afc5c8
[ "MIT" ]
5
2019-07-22T06:04:07.000Z
2021-07-23T06:01:51.000Z
tests/module_cfg/test_env_vars.py
filfreire/questions-three
1d1d621d5647407bf2d1b271e0b9c7c9f1afc5c8
[ "MIT" ]
15
2020-07-28T17:33:40.000Z
2021-08-23T17:30:05.000Z
tests/module_cfg/test_env_vars.py
filfreire/questions-three
1d1d621d5647407bf2d1b271e0b9c7c9f1afc5c8
[ "MIT" ]
4
2019-08-25T22:41:59.000Z
2020-10-21T14:28:15.000Z
from functools import partial from unittest import TestCase, main from expects import expect, equal from questions_three.exceptions import InvalidConfiguration from twin_sister.expects_matchers import complain from twin_sister import open_dependency_context from questions_three.module_cfg.module_cfg import ModuleCfg ...
37.74
81
0.721251
from functools import partial from unittest import TestCase, main from expects import expect, equal from questions_three.exceptions import InvalidConfiguration from twin_sister.expects_matchers import complain from twin_sister import open_dependency_context from questions_three.module_cfg.module_cfg import ModuleCfg ...
4,253
7
1,021
027426ac3118fd7597d0153f48ac1e25012779be
476
py
Python
Week 08/id_545/LeetCode_438_545.py
sekishi/algorithm004-05
1f1508c03edb94db96a7642e0c746233184a60d3
[ "Apache-2.0" ]
1
2019-10-12T06:48:45.000Z
2019-10-12T06:48:45.000Z
Week 08/id_545/LeetCode_438_545.py
sekishi/algorithm004-05
1f1508c03edb94db96a7642e0c746233184a60d3
[ "Apache-2.0" ]
null
null
null
Week 08/id_545/LeetCode_438_545.py
sekishi/algorithm004-05
1f1508c03edb94db96a7642e0c746233184a60d3
[ "Apache-2.0" ]
null
null
null
# 找到字符串中所有字母异位词
26.444444
56
0.382353
# 找到字符串中所有字母异位词 class Solution: def findAnagrams(self, s: str, p: str) -> List[int]: ns, np = len(s), len(p) t = collections.Counter(s[: np]) d = collections.Counter(p) ans = [] for i in range(ns - np): if d == t: ans += [i] t[s[i + np...
418
-6
49
ac91062254bf5f8d27b2d7f0cbcccee6131ca849
13,757
py
Python
CAIL2020/sfksu/model.py
ShenDezhou/CAIL
c4cfa98ab4ecedbce34a7a5a186830486047540c
[ "Apache-2.0" ]
71
2020-07-16T01:49:27.000Z
2022-03-27T16:55:00.000Z
CAIL2020/sfkst/model.py
ShenDezhou/CAIL
c4cfa98ab4ecedbce34a7a5a186830486047540c
[ "Apache-2.0" ]
11
2020-09-18T14:26:25.000Z
2022-02-09T23:49:33.000Z
CAIL2020/sfkst/model.py
ShenDezhou/CAIL
c4cfa98ab4ecedbce34a7a5a186830486047540c
[ "Apache-2.0" ]
16
2020-07-15T07:24:30.000Z
2022-03-19T05:41:11.000Z
import torch import torch.nn as nn import torch.nn.functional as F # from pytorch_pretrained_bert import BertModel from transformers.modeling_bert import BertModel from accuracy_tool import single_label_top1_accuracy #20200621, bert -> dropout -> conv -> linear -> bn -> softmax: acc=14.42
42.070336
91
0.510286
import torch import torch.nn as nn import torch.nn.functional as F # from pytorch_pretrained_bert import BertModel from transformers.modeling_bert import BertModel from accuracy_tool import single_label_top1_accuracy class BertQA(nn.Module): def __init__(self, config, gpu_list, *args, **params): super(Ber...
13,252
7
206
8b745aeb462ee5735a3280ce54a587a98a3b75f0
3,150
py
Python
tasktiger/redis_semaphore.py
timgates42/tasktiger
5b54a127c538b019af3690e4e7f6c0c8a9904fe1
[ "MIT" ]
1,143
2015-10-01T19:44:10.000Z
2022-03-26T17:32:14.000Z
tasktiger/redis_semaphore.py
timgates42/tasktiger
5b54a127c538b019af3690e4e7f6c0c8a9904fe1
[ "MIT" ]
126
2016-01-20T10:19:33.000Z
2022-03-31T18:19:41.000Z
tasktiger/redis_semaphore.py
timgates42/tasktiger
5b54a127c538b019af3690e4e7f6c0c8a9904fe1
[ "MIT" ]
78
2015-10-04T06:51:59.000Z
2022-03-26T17:32:16.000Z
"""Redis Semaphore lock.""" import os import time SYSTEM_LOCK_ID = 'SYSTEM_LOCK' class Semaphore(object): """Semaphore lock using Redis ZSET.""" def __init__(self, redis, name, lock_id, timeout, max_locks=1): """ Semaphore lock. Semaphore logic is implemented in the lua/semaphore.l...
28.378378
86
0.594603
"""Redis Semaphore lock.""" import os import time SYSTEM_LOCK_ID = 'SYSTEM_LOCK' class Semaphore(object): """Semaphore lock using Redis ZSET.""" def __init__(self, redis, name, lock_id, timeout, max_locks=1): """ Semaphore lock. Semaphore logic is implemented in the lua/semaphore.l...
0
0
0
0b8b07e3007f60eff722f64ed55393ee7d81bac4
1,224
py
Python
htms_low/htms_low_api/__init__.py
Arselon/HTMS
76068fa605b9e7b77ef98428a0b987aa50f94c9d
[ "Apache-2.0" ]
null
null
null
htms_low/htms_low_api/__init__.py
Arselon/HTMS
76068fa605b9e7b77ef98428a0b987aa50f94c9d
[ "Apache-2.0" ]
null
null
null
htms_low/htms_low_api/__init__.py
Arselon/HTMS
76068fa605b9e7b77ef98428a0b987aa50f94c9d
[ "Apache-2.0" ]
null
null
null
__title__ = 'htms_low_api' __version__ = '2.3.1' __author__ = 'Arslan Aliev' __license__ = 'Apache License, Version 2.0' __copyright__ = 'Copyright (c) 2018-2021 Arslan S. Aliev' from .htms_par_low import ( PAGESIZE1, NUMPAGES1, MAXSTRLEN1, PAGESIZE2, NUMPAGES2, SERVER_IP_DNS, MAIN_SERVER_PORT, HTDB_ROOT,...
18.830769
80
0.721405
__title__ = 'htms_low_api' __version__ = '2.3.1' __author__ = 'Arslan Aliev' __license__ = 'Apache License, Version 2.0' __copyright__ = 'Copyright (c) 2018-2021 Arslan S. Aliev' from .htms_par_low import ( PAGESIZE1, NUMPAGES1, MAXSTRLEN1, PAGESIZE2, NUMPAGES2, SERVER_IP_DNS, MAIN_SERVER_PORT, HTDB_ROOT,...
0
0
0
4e59ddb71e08498ae2e59145846be3915d87bf6b
11,519
py
Python
data_collection/gazette/spiders/sp_sao_bernardo_do_campo.py
gsusin/querido-diario
7149f7eb6da1cc5fec36552f5aa5d9cbdbc7df5e
[ "MIT" ]
null
null
null
data_collection/gazette/spiders/sp_sao_bernardo_do_campo.py
gsusin/querido-diario
7149f7eb6da1cc5fec36552f5aa5d9cbdbc7df5e
[ "MIT" ]
null
null
null
data_collection/gazette/spiders/sp_sao_bernardo_do_campo.py
gsusin/querido-diario
7149f7eb6da1cc5fec36552f5aa5d9cbdbc7df5e
[ "MIT" ]
null
null
null
import re from datetime import date, datetime import scrapy from gazette.items import Gazette from gazette.spiders.base import BaseGazetteSpider
40.847518
110
0.488931
import re from datetime import date, datetime import scrapy from gazette.items import Gazette from gazette.spiders.base import BaseGazetteSpider class SpSaoBernardoDoCampoSpider(BaseGazetteSpider): TERRITORY_ID = "3548708" name = "sp_sao_bernardo_do_campo" allowed_domains = ["saobernardo.sp.gov.br"] ...
7,743
3,620
23
8e4c45fc7da55a4a121aa551144811ff986b3798
10,747
py
Python
src/mysettings.py
take5553/face-check
82b859cdcb339b16ac4dca2216efda1bd5b54bff
[ "MIT" ]
1
2022-03-15T11:26:38.000Z
2022-03-15T11:26:38.000Z
src/mysettings.py
take5553/face-check
82b859cdcb339b16ac4dca2216efda1bd5b54bff
[ "MIT" ]
null
null
null
src/mysettings.py
take5553/face-check
82b859cdcb339b16ac4dca2216efda1bd5b54bff
[ "MIT" ]
null
null
null
# # Copyright (c) 2021 Takeshi Yamazaki # This software is released under the MIT License, see LICENSE. # import json import os from device_check import get_device_id, get_format, get_device_list import gst_builder
25.527316
119
0.555132
# # Copyright (c) 2021 Takeshi Yamazaki # This software is released under the MIT License, see LICENSE. # import json import os from device_check import get_device_id, get_format, get_device_list import gst_builder class MySettings(): _camera_settings = None _capture_settings = None _canvas_sett...
6,861
3,436
193
bae9dd4a54630a008aabb69c10a8e43a5e1571d1
402
py
Python
PythonExe/ex038.py
ScnMatheus/my-python-projects
9cc3511dd6e25d9b16429347598c105f15bd6916
[ "MIT" ]
null
null
null
PythonExe/ex038.py
ScnMatheus/my-python-projects
9cc3511dd6e25d9b16429347598c105f15bd6916
[ "MIT" ]
null
null
null
PythonExe/ex038.py
ScnMatheus/my-python-projects
9cc3511dd6e25d9b16429347598c105f15bd6916
[ "MIT" ]
null
null
null
#Escreva um programa que leia dois números inteiros e compare-os # indicando qual o maior número, menor ou se são iguais num1 = int(input('Digite um número: ')) num2 = int(input('Digite outro número: ')) if num1 > num2: print(f'O número {num1} é maior que o número {num2}') elif num2 > num1: print(f'O número: ...
33.5
64
0.691542
#Escreva um programa que leia dois números inteiros e compare-os # indicando qual o maior número, menor ou se são iguais num1 = int(input('Digite um número: ')) num2 = int(input('Digite outro número: ')) if num1 > num2: print(f'O número {num1} é maior que o número {num2}') elif num2 > num1: print(f'O número: ...
0
0
0
fc5c2d1c5b97a7290e287a3fb4bb4e5a0a6063c7
4,781
py
Python
train.py
tompoek/dsnd1-proj-imgclf
5ac6fa34de86ef0bffc0c83ca5e5cb13bb921d6b
[ "MIT" ]
null
null
null
train.py
tompoek/dsnd1-proj-imgclf
5ac6fa34de86ef0bffc0c83ca5e5cb13bb921d6b
[ "MIT" ]
null
null
null
train.py
tompoek/dsnd1-proj-imgclf
5ac6fa34de86ef0bffc0c83ca5e5cb13bb921d6b
[ "MIT" ]
null
null
null
import torch, argparse, sys from torch import nn, optim from torchvision import datasets, transforms, models from my_model import MyClassifier, save_checkpoint parser = argparse.ArgumentParser(description='IMAGE CLASSIFICATION TRAINER, PLEASE PROVIDE DIRECTORY WITH IMAGE DATA') parser.add_argument('data_dir', type=str...
39.841667
201
0.726626
import torch, argparse, sys from torch import nn, optim from torchvision import datasets, transforms, models from my_model import MyClassifier, save_checkpoint parser = argparse.ArgumentParser(description='IMAGE CLASSIFICATION TRAINER, PLEASE PROVIDE DIRECTORY WITH IMAGE DATA') parser.add_argument('data_dir', type=str...
0
0
0
e20325fb8c57358d892dd670970ae548bdfde77c
52
py
Python
earth_enterprise/src/server/wsgi/serve/push/search/__init__.py
ezeeyahoo/earthenterprise
b6cac9e6228946f2f17d1edb75e118aeb3e8e8c9
[ "Apache-2.0" ]
2,661
2017-03-20T22:12:50.000Z
2022-03-30T09:43:19.000Z
earth_enterprise/src/server/wsgi/serve/push/search/__init__.py
ezeeyahoo/earthenterprise
b6cac9e6228946f2f17d1edb75e118aeb3e8e8c9
[ "Apache-2.0" ]
1,531
2017-03-24T17:20:32.000Z
2022-03-16T18:11:14.000Z
earth_enterprise/src/server/wsgi/serve/push/search/__init__.py
ezeeyahoo/earthenterprise
b6cac9e6228946f2f17d1edb75e118aeb3e8e8c9
[ "Apache-2.0" ]
990
2017-03-24T11:54:28.000Z
2022-03-22T11:51:47.000Z
"""The package indicator for serve.push.search."""
17.333333
50
0.711538
"""The package indicator for serve.push.search."""
0
0
0
a7fcbbad0b7a1b74f6d72234f08565017e74fc2f
482
py
Python
src/alembic/versions/fd05599e10a6_add_identity_file.py
grihabor/teser
93ecc60a6952313c6fbb10de3b1cc0647899e9e8
[ "BSD-3-Clause" ]
null
null
null
src/alembic/versions/fd05599e10a6_add_identity_file.py
grihabor/teser
93ecc60a6952313c6fbb10de3b1cc0647899e9e8
[ "BSD-3-Clause" ]
null
null
null
src/alembic/versions/fd05599e10a6_add_identity_file.py
grihabor/teser
93ecc60a6952313c6fbb10de3b1cc0647899e9e8
[ "BSD-3-Clause" ]
null
null
null
"""empty message Revision ID: fd05599e10a6 Revises: 8a04dc559206 Create Date: 2017-08-22 14:26:50.486659 """ from alembic import op import sqlalchemy as sa # revision identifiers, used by Alembic. revision = 'fd05599e10a6' down_revision = '8a04dc559206' branch_labels = None depends_on = None
19.28
98
0.748963
"""empty message Revision ID: fd05599e10a6 Revises: 8a04dc559206 Create Date: 2017-08-22 14:26:50.486659 """ from alembic import op import sqlalchemy as sa # revision identifiers, used by Alembic. revision = 'fd05599e10a6' down_revision = '8a04dc559206' branch_labels = None depends_on = None def upgrade(): op...
137
0
46
6b50f513410dc084491665be9622064316a40d58
3,741
py
Python
openGaussBase/testcase/SQL/DATATYPE/jsonb/Opengauss_Function_Datatype_Jsonb_Case0035.py
opengauss-mirror/Yat
aef107a8304b94e5d99b4f1f36eb46755eb8919e
[ "MulanPSL-1.0" ]
null
null
null
openGaussBase/testcase/SQL/DATATYPE/jsonb/Opengauss_Function_Datatype_Jsonb_Case0035.py
opengauss-mirror/Yat
aef107a8304b94e5d99b4f1f36eb46755eb8919e
[ "MulanPSL-1.0" ]
null
null
null
openGaussBase/testcase/SQL/DATATYPE/jsonb/Opengauss_Function_Datatype_Jsonb_Case0035.py
opengauss-mirror/Yat
aef107a8304b94e5d99b4f1f36eb46755eb8919e
[ "MulanPSL-1.0" ]
null
null
null
""" Copyright (c) 2022 Huawei Technologies Co.,Ltd. openGauss is licensed under Mulan PSL v2. You can use this software according to the terms and conditions of the Mulan PSL v2. You may obtain a copy of Mulan PSL v2 at: http://license.coscl.org.cn/MulanPSL2 THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, W...
38.173469
84
0.535151
""" Copyright (c) 2022 Huawei Technologies Co.,Ltd. openGauss is licensed under Mulan PSL v2. You can use this software according to the terms and conditions of the Mulan PSL v2. You may obtain a copy of Mulan PSL v2 at: http://license.coscl.org.cn/MulanPSL2 THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, W...
2,690
10
104
c4054c8555d288d7b735b5aae1ffa3d1ec84e43f
697
py
Python
development/server/documents/common.py
FMsunyh/re_com
1510881bce07a2750c47834b6520d90f2f4ed254
[ "MIT" ]
null
null
null
development/server/documents/common.py
FMsunyh/re_com
1510881bce07a2750c47834b6520d90f2f4ed254
[ "MIT" ]
11
2020-01-28T22:29:48.000Z
2022-03-11T23:29:39.000Z
development/server/documents/common.py
FMsunyh/re_com
1510881bce07a2750c47834b6520d90f2f4ed254
[ "MIT" ]
null
null
null
from flask_restplus import reqparse from flask_restplus import fields from server import api from server.status import APIStatus, to_http_status request_parser = reqparse.RequestParser() request_parser.add_argument('token', type=str, required=True, location='headers') request_token = api.expect(request_parser, vali...
36.684211
82
0.695839
from flask_restplus import reqparse from flask_restplus import fields from server import api from server.status import APIStatus, to_http_status def build_response(name, data): return api.response(code=to_http_status(APIStatus.Ok), model=api.model(name, { 'status': fields.Integer(description...
383
0
23
0d57e79c1b7bd7e669f04513eb010415d49b54ce
10,851
py
Python
scripts/list_file_entries.py
joachimmetz/dfvfs-snippets
787a858e7e008fc44a0b78703dff2cb9236f7c0a
[ "Apache-2.0" ]
null
null
null
scripts/list_file_entries.py
joachimmetz/dfvfs-snippets
787a858e7e008fc44a0b78703dff2cb9236f7c0a
[ "Apache-2.0" ]
null
null
null
scripts/list_file_entries.py
joachimmetz/dfvfs-snippets
787a858e7e008fc44a0b78703dff2cb9236f7c0a
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """Script to list file entries.""" import abc import argparse import logging import sys from dfvfs.analyzer import analyzer from dfvfs.analyzer import fvde_analyzer_helper from dfvfs.helpers import command_line from dfvfs.helpers import volume_scanner from dfvfs.lib impor...
30.310056
85
0.680582
#!/usr/bin/env python # -*- coding: utf-8 -*- """Script to list file entries.""" import abc import argparse import logging import sys from dfvfs.analyzer import analyzer from dfvfs.analyzer import fvde_analyzer_helper from dfvfs.helpers import command_line from dfvfs.helpers import volume_scanner from dfvfs.lib impor...
0
0
0
c9dcc0a148352e5dcae7f550e00cfb4fd3d33007
2,297
py
Python
stanCode_Project/break_out_game/breakout.py
ifanchang/stancode_101
52d3834c8a94e02c09f7d2e10eca0a6f1582816f
[ "MIT" ]
null
null
null
stanCode_Project/break_out_game/breakout.py
ifanchang/stancode_101
52d3834c8a94e02c09f7d2e10eca0a6f1582816f
[ "MIT" ]
null
null
null
stanCode_Project/break_out_game/breakout.py
ifanchang/stancode_101
52d3834c8a94e02c09f7d2e10eca0a6f1582816f
[ "MIT" ]
null
null
null
""" stanCode Breakout Project Adapted from Eric Roberts's Breakout by Sonja Johnson-Yu, Kylie Jue, Nick Bowman, and Jerry Liao. YOUR DESCRIPTION HERE This is a breakout game. """ from campy.gui.events.timer import pause from breakoutgraphics import BreakoutGraphics FRAME_RATE = 1000 / 120 # 120 frames per second NU...
28.012195
102
0.607749
""" stanCode Breakout Project Adapted from Eric Roberts's Breakout by Sonja Johnson-Yu, Kylie Jue, Nick Bowman, and Jerry Liao. YOUR DESCRIPTION HERE This is a breakout game. """ from campy.gui.events.timer import pause from breakoutgraphics import BreakoutGraphics FRAME_RATE = 1000 / 120 # 120 frames per second NU...
1,875
0
23
7830cc764bbfb73ca7ab5780d35c46bb834522c4
940
py
Python
beagle/stats.py
juliendoutre/beagle
2a72ed99934801fae5966e19f14c02b52a0bc35b
[ "MIT" ]
null
null
null
beagle/stats.py
juliendoutre/beagle
2a72ed99934801fae5966e19f14c02b52a0bc35b
[ "MIT" ]
null
null
null
beagle/stats.py
juliendoutre/beagle
2a72ed99934801fae5966e19f14c02b52a0bc35b
[ "MIT" ]
null
null
null
from typing import Dict import json from beagle.logging import timer @timer
25.405405
81
0.553191
from typing import Dict import json from beagle.logging import timer class Stats: def __init__(self) -> None: self.documents: Dict[int, Dict[str, int]] = {} self.documents_number: int = 0 def update(self, stats: "Stats") -> None: self.documents_number += stats.documents_number ...
734
82
45
516b7c25c5650aeb33f7879e0a9516375602921b
2,328
py
Python
python/scripts/tools/m3qa_eeprom_sn.py
ahoarau/m3meka
237739f0266ce60aaa3013b0d2b22fc07b6374c4
[ "MIT" ]
1
2015-06-19T12:14:18.000Z
2015-06-19T12:14:18.000Z
python/scripts/tools/m3qa_eeprom_sn.py
semeyerz/m3meka
6e5d6b73ad3ebdd8429497923e601eae65d8b2fe
[ "MIT" ]
null
null
null
python/scripts/tools/m3qa_eeprom_sn.py
semeyerz/m3meka
6e5d6b73ad3ebdd8429497923e601eae65d8b2fe
[ "MIT" ]
2
2015-11-27T09:25:54.000Z
2021-08-16T16:29:22.000Z
#! /usr/bin/python #M3 -- Meka Robotics Robot Components #Copyright (c) 2010 Meka Robotics #Author: edsinger@mekabot.com (Aaron Edsinger) #M3 is free software: you can redistribute it and/or modify #it under the terms of the GNU Lesser General Public License as published by #the Free Software Foundation, either versi...
31.890411
80
0.665378
#! /usr/bin/python #M3 -- Meka Robotics Robot Components #Copyright (c) 2010 Meka Robotics #Author: edsinger@mekabot.com (Aaron Edsinger) #M3 is free software: you can redistribute it and/or modify #it under the terms of the GNU Lesser General Public License as published by #the Free Software Foundation, either versi...
0
0
0
d3f4a4bbea8a59b398c702cb337e30a29cbcc5ee
492
py
Python
idb/grpc/types.py
doc22940/idb
8eb2d82c6b560a5c243986da28124245284e65e9
[ "MIT" ]
1
2015-10-09T05:49:03.000Z
2015-10-09T05:49:03.000Z
idb/grpc/types.py
sunlight2728/FBSimulatorControl
6fd02165bc8252cfdb8efe2bf98f370e73d7902c
[ "MIT" ]
5
2021-09-02T15:20:04.000Z
2022-02-27T09:50:05.000Z
idb/grpc/types.py
Rezduan83/idb
a43b499302a37ada164cd183b9edb0e3a4699a1d
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # Copyright (c) Facebook, Inc. and its affiliates. # # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. from logging import Logger from typing import NamedTuple, Optional from idb.grpc.idb_grpc import CompanionServiceStub...
24.6
65
0.764228
#!/usr/bin/env python3 # Copyright (c) Facebook, Inc. and its affiliates. # # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. from logging import Logger from typing import NamedTuple, Optional from idb.grpc.idb_grpc import CompanionServiceStub...
0
147
23
e66cda1029d555148c6f8dd263494bf6bf20ce6a
28,510
py
Python
djangobb_forum/views.py
dboczek/DjangoBB
80c42274839714f0cc6c4529ba1b44ae5e4e03c1
[ "BSD-3-Clause" ]
null
null
null
djangobb_forum/views.py
dboczek/DjangoBB
80c42274839714f0cc6c4529ba1b44ae5e4e03c1
[ "BSD-3-Clause" ]
null
null
null
djangobb_forum/views.py
dboczek/DjangoBB
80c42274839714f0cc6c4529ba1b44ae5e4e03c1
[ "BSD-3-Clause" ]
null
null
null
import math from datetime import datetime, timedelta from django.shortcuts import get_object_or_404, render from django.http import Http404, HttpResponse, HttpResponseRedirect, HttpResponseForbidden from django.contrib.auth.models import User from django.contrib.auth.decorators import login_required from django.contr...
40.15493
156
0.645002
import math from datetime import datetime, timedelta from django.shortcuts import get_object_or_404, render from django.http import Http404, HttpResponse, HttpResponseRedirect, HttpResponseForbidden from django.contrib.auth.models import User from django.contrib.auth.decorators import login_required from django.contr...
24,970
0
489
187c2a6d0bbace6b80c7152abaf731b60e10812a
2,045
py
Python
tests/test_cnn/test_revert_syncbn.py
imabackstabber/mmcv
b272c09b463f00fd7fdd455f7bd4a055f9995521
[ "Apache-2.0" ]
null
null
null
tests/test_cnn/test_revert_syncbn.py
imabackstabber/mmcv
b272c09b463f00fd7fdd455f7bd4a055f9995521
[ "Apache-2.0" ]
null
null
null
tests/test_cnn/test_revert_syncbn.py
imabackstabber/mmcv
b272c09b463f00fd7fdd455f7bd4a055f9995521
[ "Apache-2.0" ]
null
null
null
# Copyright (c) OpenMMLab. All rights reserved. import os import platform import numpy as np import pytest import torch import torch.distributed as dist from mmcv.cnn.bricks import ConvModule from mmcv.cnn.utils import revert_sync_batchnorm if platform.system() == 'Windows': import regex as re else: import r...
32.983871
79
0.648411
# Copyright (c) OpenMMLab. All rights reserved. import os import platform import numpy as np import pytest import torch import torch.distributed as dist from mmcv.cnn.bricks import ConvModule from mmcv.cnn.utils import revert_sync_batchnorm if platform.system() == 'Windows': import regex as re else: import r...
1,579
0
45
b484ed631d6f33f581345e240cfdb2c353330420
4,109
py
Python
distances/hamming.py
FilippoPisello/Stat-utils
61f9d95ef6eaac419fd48ecf08d4b374c10087de
[ "MIT" ]
null
null
null
distances/hamming.py
FilippoPisello/Stat-utils
61f9d95ef6eaac419fd48ecf08d4b374c10087de
[ "MIT" ]
null
null
null
distances/hamming.py
FilippoPisello/Stat-utils
61f9d95ef6eaac419fd48ecf08d4b374c10087de
[ "MIT" ]
null
null
null
from typing import Union import numpy as np def hamming_from_elements( array: np.ndarray, elements: np.ndarray, weight: Union[float, int, np.ndarray] = 1 ) -> np.ndarray: """Return an array of array made of the hamming distances between each element and each of the specified points. The hamming dist...
38.401869
86
0.664152
from typing import Union import numpy as np def hamming_from_elements( array: np.ndarray, elements: np.ndarray, weight: Union[float, int, np.ndarray] = 1 ) -> np.ndarray: """Return an array of array made of the hamming distances between each element and each of the specified points. The hamming dist...
0
0
0
59259301b693a460277dfb332c1f19419c089350
766
py
Python
bozkurt-ftp.py
B3zkurt/bozkurt-ftp
2663317b5e451b2fa49e240c936a1e95b629a9c9
[ "Apache-2.0" ]
null
null
null
bozkurt-ftp.py
B3zkurt/bozkurt-ftp
2663317b5e451b2fa49e240c936a1e95b629a9c9
[ "Apache-2.0" ]
null
null
null
bozkurt-ftp.py
B3zkurt/bozkurt-ftp
2663317b5e451b2fa49e240c936a1e95b629a9c9
[ "Apache-2.0" ]
1
2022-02-11T18:25:47.000Z
2022-02-11T18:25:47.000Z
import os import time os.system("clear") print("################################") print(" ") print(" Bozkurt Ftp Bf Toolu ") print(" ") print("################################") print() print("1.Ftp Brute Force") print("2.Kullanım ...
29.461538
207
0.556136
import os import time os.system("clear") print("################################") print(" ") print(" Bozkurt Ftp Bf Toolu ") print(" ") print("################################") print() print("1.Ftp Brute Force") print("2.Kullanım ...
0
0
0
de72b5096927dd3f6e939e05e71e4b84f027aa56
7,141
py
Python
noahmp_new_case.py
ESMWG/noahmp-tools
818b6d874f2981098dd3ad1ee239c88ee4743892
[ "Apache-2.0" ]
5
2019-04-04T03:14:40.000Z
2021-07-29T03:22:11.000Z
noahmp_new_case.py
woolf1988/noahmp-tools
818b6d874f2981098dd3ad1ee239c88ee4743892
[ "Apache-2.0" ]
null
null
null
noahmp_new_case.py
woolf1988/noahmp-tools
818b6d874f2981098dd3ad1ee239c88ee4743892
[ "Apache-2.0" ]
3
2019-04-04T03:14:44.000Z
2021-12-10T07:39:17.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # create Noah-MP case # author: Hui ZHENG import os.path import string import shutil NOAHMP_NML = 'namelist.hrldas.template' NOAHMP_TBLS = ['GENPARM.TBL', 'MPTABLE.TBL', 'SOILPARM.TBL', 'VEGPARM.TBL'] NOAHMP_EXE = 'noahmp_hrldas.exe' import argparse import dateutil.pa...
45.484076
120
0.487887
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # create Noah-MP case # author: Hui ZHENG import os.path import string import shutil NOAHMP_NML = 'namelist.hrldas.template' NOAHMP_TBLS = ['GENPARM.TBL', 'MPTABLE.TBL', 'SOILPARM.TBL', 'VEGPARM.TBL'] NOAHMP_EXE = 'noahmp_hrldas.exe' def main(modelroot=None, ...
4,891
0
23
a9c3084b79249fcf226eeb9baec10359f8e056b5
167
py
Python
misago/misago/sso/tests/utils.py
vascoalramos/misago-deployment
20226072138403108046c0afad9d99eb4163cedc
[ "MIT" ]
2
2021-03-06T21:06:13.000Z
2021-03-09T15:05:12.000Z
misago/misago/sso/tests/utils.py
vascoalramos/misago-deployment
20226072138403108046c0afad9d99eb4163cedc
[ "MIT" ]
null
null
null
misago/misago/sso/tests/utils.py
vascoalramos/misago-deployment
20226072138403108046c0afad9d99eb4163cedc
[ "MIT" ]
null
null
null
TEST_SSO_SETTINGS = { "enable_sso": True, "sso_private_key": "priv1", "sso_public_key": "fakeSsoPublicKey", "sso_url": "http://example.com/server/", }
23.857143
44
0.646707
TEST_SSO_SETTINGS = { "enable_sso": True, "sso_private_key": "priv1", "sso_public_key": "fakeSsoPublicKey", "sso_url": "http://example.com/server/", }
0
0
0
bf2f2a7255aa979e2b1569f0e546cbe4536d8622
20,675
py
Python
nonbonded/tests/backend/crud/test_results.py
SimonBoothroyd/nonbonded
3efbb7d943d936b47248975f9ad0d8a006ea8684
[ "MIT" ]
5
2020-05-11T18:25:00.000Z
2022-01-27T10:55:09.000Z
nonbonded/tests/backend/crud/test_results.py
SimonBoothroyd/nonbonded
3efbb7d943d936b47248975f9ad0d8a006ea8684
[ "MIT" ]
88
2020-06-02T14:40:05.000Z
2022-03-02T09:20:39.000Z
nonbonded/tests/backend/crud/test_results.py
SimonBoothroyd/nonbonded
3efbb7d943d936b47248975f9ad0d8a006ea8684
[ "MIT" ]
null
null
null
import functools from typing import List import pytest from sqlalchemy.orm import Session from nonbonded.backend.database import models from nonbonded.backend.database.crud.datasets import DataSetCRUD from nonbonded.backend.database.crud.projects import BenchmarkCRUD, OptimizationCRUD from nonbonded.backend.database....
32.507862
88
0.557098
import functools from typing import List import pytest from sqlalchemy.orm import Session from nonbonded.backend.database import models from nonbonded.backend.database.crud.datasets import DataSetCRUD from nonbonded.backend.database.crud.projects import BenchmarkCRUD, OptimizationCRUD from nonbonded.backend.database....
6,714
12,211
92
8a34b7b3ec213b75c0a45cfd8969677bf772751f
998
py
Python
modules/finance/social_security_audit/urls.py
xuhuiliang-maybe/ace_office
07fae18676a193206802e8fb9aa32a805b1da24c
[ "Apache-2.0" ]
1
2018-11-27T08:08:07.000Z
2018-11-27T08:08:07.000Z
modules/finance/social_security_audit/urls.py
xuhuiliang-maybe/ace_office
07fae18676a193206802e8fb9aa32a805b1da24c
[ "Apache-2.0" ]
null
null
null
modules/finance/social_security_audit/urls.py
xuhuiliang-maybe/ace_office
07fae18676a193206802e8fb9aa32a805b1da24c
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 from django.conf.urls import url from modules.finance.social_security_audit.code.add_social_security_audit import * from modules.finance.social_security_audit.code.del_social_security_audit import * from modules.finance.social_security_audit.code.edit_social_security_audit import * from modules.finance....
55.444444
107
0.795591
# coding=utf-8 from django.conf.urls import url from modules.finance.social_security_audit.code.add_social_security_audit import * from modules.finance.social_security_audit.code.del_social_security_audit import * from modules.finance.social_security_audit.code.edit_social_security_audit import * from modules.finance....
0
0
0
46f2b00af8f1c4f77c772643c57035e4416d9838
7,591
py
Python
Chapter09/coffee_list2.py
Orrmj/Mastering-GUI-Programming-with-Python
cba452b96551d649144e6cfe18cd90dd454ab417
[ "MIT" ]
null
null
null
Chapter09/coffee_list2.py
Orrmj/Mastering-GUI-Programming-with-Python
cba452b96551d649144e6cfe18cd90dd454ab417
[ "MIT" ]
null
null
null
Chapter09/coffee_list2.py
Orrmj/Mastering-GUI-Programming-with-Python
cba452b96551d649144e6cfe18cd90dd454ab417
[ "MIT" ]
null
null
null
import sys from PyQt5 import QtWidgets as qtw from PyQt5 import QtCore as qtc from PyQt5 import QtGui as qtg from PyQt5 import QtSql as qts """ TODO: - Adding new reviews and new coffees """ class CoffeeForm(qtw.QWidget): """Form to display/edit all info about a coffee""" if __name__ == '__main__': ap...
33.588496
71
0.627981
import sys from PyQt5 import QtWidgets as qtw from PyQt5 import QtCore as qtc from PyQt5 import QtGui as qtg from PyQt5 import QtSql as qts """ TODO: - Adding new reviews and new coffees """ class DateDelegate(qtw.QStyledItemDelegate): def createEditor(self, parent, option, proxyModelIndex): # make s...
4,177
2,727
181
ad2f140c84a65a05433bb7a6eb37b0e031434000
3,887
py
Python
actions/smtpserver.py
elastisys/layer-charmscaler-base
ab1c1152ea931edd5d1061e74414acf529b562bf
[ "Apache-2.0" ]
null
null
null
actions/smtpserver.py
elastisys/layer-charmscaler-base
ab1c1152ea931edd5d1061e74414acf529b562bf
[ "Apache-2.0" ]
null
null
null
actions/smtpserver.py
elastisys/layer-charmscaler-base
ab1c1152ea931edd5d1061e74414acf529b562bf
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3.5 import asyncio import logging import sys sys.path.append("lib") from charms.layer.basic import activate_venv # noqa: E402 activate_venv() from aiosmtpd.controller import Controller # noqa: E402 from aiosmtpd.handlers import Message # noqa: E402 from aiozmq import rpc # noqa: E402 from cha...
26.087248
78
0.623617
#!/usr/bin/env python3.5 import asyncio import logging import sys sys.path.append("lib") from charms.layer.basic import activate_venv # noqa: E402 activate_venv() from aiosmtpd.controller import Controller # noqa: E402 from aiosmtpd.handlers import Message # noqa: E402 from aiozmq import rpc # noqa: E402 from cha...
2,270
494
138
f12af4d29de7215c8ceaab22302c45d487b560c5
2,527
py
Python
mocha_common_tools.py
boris-fx/mocha-scripts
f7119b6258dadfbf47723093e50a1a7a062b7f4d
[ "BSD-3-Clause" ]
6
2021-04-24T02:12:49.000Z
2022-02-08T12:09:38.000Z
mocha_common_tools.py
boris-fx/mocha-scripts
f7119b6258dadfbf47723093e50a1a7a062b7f4d
[ "BSD-3-Clause" ]
null
null
null
mocha_common_tools.py
boris-fx/mocha-scripts
f7119b6258dadfbf47723093e50a1a7a062b7f4d
[ "BSD-3-Clause" ]
2
2021-05-18T14:17:36.000Z
2021-08-15T11:40:16.000Z
# BSD 3-Clause License # # Copyright (c) 2020, Boris FX # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # 1. Redistributions of source code must retain the above copyright notice, this # list...
37.716418
80
0.766522
# BSD 3-Clause License # # Copyright (c) 2020, Boris FX # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # 1. Redistributions of source code must retain the above copyright notice, this # list...
586
0
69
f16286e5d47b6c1cf9c78dfb2bb3ccfbff9bffee
6,926
py
Python
src/main/python/grid/simulation.py
Patrizio1301/GridSimulation
60ae9be8043b8cef19cb02d186b63a585d18bd87
[ "MIT" ]
null
null
null
src/main/python/grid/simulation.py
Patrizio1301/GridSimulation
60ae9be8043b8cef19cb02d186b63a585d18bd87
[ "MIT" ]
null
null
null
src/main/python/grid/simulation.py
Patrizio1301/GridSimulation
60ae9be8043b8cef19cb02d186b63a585d18bd87
[ "MIT" ]
null
null
null
from typing import List import numpy from grid.Servicepoint import Servicepoint from grid.Configuration import Configuration import tensorflow as tf from utils.utils import Utils, Storage
38.692737
126
0.616084
from typing import List import numpy from grid.Servicepoint import Servicepoint from grid.Configuration import Configuration import tensorflow as tf from utils.utils import Utils, Storage class Simulation(object): def __init__(self, configuration: str, consumptions: List[Servicepoint], distribution: List[float],...
468
6,245
23
c8d0f7fa02f11fe41c311c74e10f43c19734bdea
635
py
Python
main/models.py
guanta/guanta_deploy
387b23990b5a215c2a15174d2774838e28255139
[ "Apache-2.0" ]
null
null
null
main/models.py
guanta/guanta_deploy
387b23990b5a215c2a15174d2774838e28255139
[ "Apache-2.0" ]
null
null
null
main/models.py
guanta/guanta_deploy
387b23990b5a215c2a15174d2774838e28255139
[ "Apache-2.0" ]
null
null
null
from django.db import models # Create your models here.
21.896552
60
0.650394
from django.db import models # Create your models here. class subscriber(models.Model): email = models.CharField(max_length = 255 , unique=True) def __str__(self): return self.email class respos(models.Model): name = models.CharField(max_length = 255 ) surname = models.CharFiel...
45
435
77
5db902a228e145362e715ff9f6a79cc2157c1890
286
py
Python
velarium/__init__.py
holthe/velarium
c16f608f1f99b1fab6b3556b2da414ea41777f80
[ "MIT" ]
2
2018-04-07T21:38:24.000Z
2020-01-22T19:14:01.000Z
velarium/__init__.py
holthe/velarium
c16f608f1f99b1fab6b3556b2da414ea41777f80
[ "MIT" ]
null
null
null
velarium/__init__.py
holthe/velarium
c16f608f1f99b1fab6b3556b2da414ea41777f80
[ "MIT" ]
null
null
null
from . import interpreter, network, process def ufw_reset(): """Reset UFW rules.""" network.ufw_reset() def main(): """Entry point for the application script.""" # We only allow a single instance process.ensure_single_instance('velarium') interpreter.run()
19.066667
49
0.674825
from . import interpreter, network, process def ufw_reset(): """Reset UFW rules.""" network.ufw_reset() def main(): """Entry point for the application script.""" # We only allow a single instance process.ensure_single_instance('velarium') interpreter.run()
0
0
0
3e157512599334ff18a4d6a857df5062842170ca
346
py
Python
snuggle/errors.py
halfak/snuggle
384818aaf8a783013b076ada3c74226f10e5dc18
[ "MIT" ]
2
2021-04-26T20:34:25.000Z
2021-11-12T11:26:57.000Z
snuggle/errors.py
halfak/snuggle
384818aaf8a783013b076ada3c74226f10e5dc18
[ "MIT" ]
null
null
null
snuggle/errors.py
halfak/snuggle
384818aaf8a783013b076ada3c74226f10e5dc18
[ "MIT" ]
null
null
null
# Web processing errors # User Actions
21.625
51
0.745665
# Web processing errors class AuthErrorPass(Exception): pass class AuthErrorName(Exception): pass class ConnectionError(Exception): pass class MWAPIError(Exception): def __init__(self, code, info): Exception.__init__(self, "%s: %s" % (code, info)) self.code = code self.info = info # User Actions class Invali...
100
69
135
1859c5837576db370feb8424428e2aee20da299a
1,616
py
Python
common/ng_template.py
cclauss/upvote
9d526fec72690cde1575dbd32dacf68cbbab81d1
[ "Apache-2.0" ]
null
null
null
common/ng_template.py
cclauss/upvote
9d526fec72690cde1575dbd32dacf68cbbab81d1
[ "Apache-2.0" ]
null
null
null
common/ng_template.py
cclauss/upvote
9d526fec72690cde1575dbd32dacf68cbbab81d1
[ "Apache-2.0" ]
null
null
null
# Copyright 2017 Google Inc. 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 a...
31.076923
79
0.722153
# Copyright 2017 Google Inc. 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 a...
832
0
23
e34b1b08208e9f32d5c30e4c948adc9a8327bfe2
3,585
py
Python
games/serializers/switch_game_us.py
JeffersonBC/eshop-index-back
66a11ad2ee86b9cd4dd49bcb34f676db3281153b
[ "MIT" ]
null
null
null
games/serializers/switch_game_us.py
JeffersonBC/eshop-index-back
66a11ad2ee86b9cd4dd49bcb34f676db3281153b
[ "MIT" ]
null
null
null
games/serializers/switch_game_us.py
JeffersonBC/eshop-index-back
66a11ad2ee86b9cd4dd49bcb34f676db3281153b
[ "MIT" ]
null
null
null
from django.contrib.auth import get_user_model from rest_framework import serializers from datetime import datetime import re from ..models import SwitchGameUS, SwitchGame
33.194444
76
0.630126
from django.contrib.auth import get_user_model from rest_framework import serializers from datetime import datetime import re from ..models import SwitchGameUS, SwitchGame class SwitchGameUSSerializer(serializers.Serializer): title = serializers.CharField(max_length=128) slug = serializers.SlugField(max_le...
2,885
501
23
cf26f44be725ea4761a14e264df7ac6cb3594d09
6,449
py
Python
code/colors/colored-hist.py
geo7/scientific-visualization-book
71f6bac4db7ee2f26e88052fe7faa800303d8b00
[ "BSD-2-Clause" ]
2
2021-11-17T15:10:09.000Z
2021-12-24T13:31:10.000Z
code/colors/colored-hist.py
WuShichao/scientific-visualization-book
389766215aa6b234ed1cf560a3768437d41d1d37
[ "BSD-2-Clause" ]
1
2021-12-12T11:37:48.000Z
2021-12-12T11:39:00.000Z
code/colors/colored-hist.py
WuShichao/scientific-visualization-book
389766215aa6b234ed1cf560a3768437d41d1d37
[ "BSD-2-Clause" ]
2
2021-12-30T12:20:07.000Z
2022-02-24T06:36:41.000Z
# ---------------------------------------------------------------------------- # Title: Scientific Visualisation - Python & Matplotlib # Author: Nicolas P. Rougier # License: BSD # ---------------------------------------------------------------------------- import numpy as np import matplotlib.pyplot as plt import m...
21.713805
80
0.370755
# ---------------------------------------------------------------------------- # Title: Scientific Visualisation - Python & Matplotlib # Author: Nicolas P. Rougier # License: BSD # ---------------------------------------------------------------------------- import numpy as np import matplotlib.pyplot as plt import m...
394
0
23
5926dfed09ba36a1df5f0b74193784d8e4593e50
1,337
py
Python
small_projet/hangman/function.py
ravernhe/python_random_stuff
d9dc2cd3134fc36ff761f2aa1481c4b80568d0b2
[ "MIT" ]
null
null
null
small_projet/hangman/function.py
ravernhe/python_random_stuff
d9dc2cd3134fc36ff761f2aa1481c4b80568d0b2
[ "MIT" ]
null
null
null
small_projet/hangman/function.py
ravernhe/python_random_stuff
d9dc2cd3134fc36ff761f2aa1481c4b80568d0b2
[ "MIT" ]
null
null
null
#!/usr/bin/python # -*-coding:utf-8 -* import os import pickle from random import choice from data import *
24.309091
79
0.6365
#!/usr/bin/python # -*-coding:utf-8 -* import os import pickle from random import choice from data import * def get_score(): if os.path.exists(name_score_file): score_file = open(name_score_file, "rb") my_depickler = pickle.Unpickler(score_file) scores = my_depickler.load() score_f...
1,089
0
138
8c8e94c9a0d10e71278c7ba50bc937b9b091d885
5,629
py
Python
Johnson2016Perceptual/test.py
czczup/URST
000ec9f7728f12ffad989ec1d07b1dd579514133
[ "Apache-2.0" ]
119
2021-03-21T18:30:51.000Z
2022-03-29T07:28:33.000Z
Johnson2016Perceptual/test.py
czczup/URST
000ec9f7728f12ffad989ec1d07b1dd579514133
[ "Apache-2.0" ]
5
2021-04-02T14:26:03.000Z
2022-01-12T12:59:17.000Z
Johnson2016Perceptual/test.py
czczup/URST
000ec9f7728f12ffad989ec1d07b1dd579514133
[ "Apache-2.0" ]
16
2021-03-21T18:30:53.000Z
2022-03-29T07:28:34.000Z
from model_test import TransformerNet import torch.nn.functional as F from PIL import Image from tqdm import tqdm from utils import * import torch import argparse import os import time import math import sys sys.path.append("..") from tools import unpadding, preprocess from thumb_instance_norm import init_thumbnail_in...
43.3
133
0.649671
from model_test import TransformerNet import torch.nn.functional as F from PIL import Image from tqdm import tqdm from utils import * import torch import argparse import os import time import math import sys sys.path.append("..") from tools import unpadding, preprocess from thumb_instance_norm import init_thumbnail_in...
1,456
0
73
b0c31384d07bb1f3c3f1d6d2e0992d5664a73609
2,693
py
Python
scripts/generate_sic_graphs.py
bfan1256/comarket-movements
5f7d434aa5820f3dcca2f42c3534828e00377fbd
[ "Apache-2.0" ]
5
2022-03-02T20:59:45.000Z
2022-03-03T19:28:11.000Z
scripts/generate_sic_graphs.py
bfan1256/comarket-movements
5f7d434aa5820f3dcca2f42c3534828e00377fbd
[ "Apache-2.0" ]
null
null
null
scripts/generate_sic_graphs.py
bfan1256/comarket-movements
5f7d434aa5820f3dcca2f42c3534828e00377fbd
[ "Apache-2.0" ]
null
null
null
import os import pandas as pd from glob import glob import pickle from fbprophet import Prophet from matplotlib import pyplot as plt import seaborn as sns import pickle import numpy as np from tslearn.utils import to_time_series_dataset from tslearn.preprocessing import TimeSeriesScalerMeanVariance from tslearn.clus...
37.929577
135
0.582993
import os import pandas as pd from glob import glob import pickle from fbprophet import Prophet from matplotlib import pyplot as plt import seaborn as sns import pickle import numpy as np from tslearn.utils import to_time_series_dataset from tslearn.preprocessing import TimeSeriesScalerMeanVariance from tslearn.clus...
258
0
23
2428a4fd984bea65de72321da74b3e50276f8e31
3,790
py
Python
sandbox/slice-reads-by-coverage.py
sadeepdarshana/khmer
bee54c4f579611d970c59367323d31d3545cafa6
[ "CNRI-Python" ]
558
2015-05-22T15:03:21.000Z
2022-03-23T04:49:17.000Z
sandbox/slice-reads-by-coverage.py
sadeepdarshana/khmer
bee54c4f579611d970c59367323d31d3545cafa6
[ "CNRI-Python" ]
1,057
2015-05-14T20:27:04.000Z
2022-03-08T09:29:36.000Z
sandbox/slice-reads-by-coverage.py
sadeepdarshana/khmer
bee54c4f579611d970c59367323d31d3545cafa6
[ "CNRI-Python" ]
193
2015-05-18T10:13:34.000Z
2021-12-10T11:58:01.000Z
#! /usr/bin/env python # This file is part of khmer, https://github.com/dib-lab/khmer/, and is # Copyright (C) 2014-2015, Michigan State University. # Copyright (C) 2015, The Regents of the University of California. # # Redistribution and use in source and binary forms, with or without # modification, are permitted pro...
36.442308
83
0.688654
#! /usr/bin/env python # This file is part of khmer, https://github.com/dib-lab/khmer/, and is # Copyright (C) 2014-2015, Michigan State University. # Copyright (C) 2015, The Regents of the University of California. # # Redistribution and use in source and binary forms, with or without # modification, are permitted pro...
1,854
0
46
7cecb7489ec650968b34932f3b4f9c8eb8c2f623
3,763
py
Python
tools/visualize_json_results.py
Qianna00/detectron2
e8f9a6dd6f69d58ddec0fbbde1b6a185f6c4111e
[ "Apache-2.0" ]
1
2021-08-01T08:44:40.000Z
2021-08-01T08:44:40.000Z
tools/visualize_json_results.py
Qianna00/detectron2
e8f9a6dd6f69d58ddec0fbbde1b6a185f6c4111e
[ "Apache-2.0" ]
null
null
null
tools/visualize_json_results.py
Qianna00/detectron2
e8f9a6dd6f69d58ddec0fbbde1b6a185f6c4111e
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved import argparse import json import numpy as np import os from collections import defaultdict import cv2 import tqdm from fvcore.common.file_io import PathManager from detectron2.data import DatasetCatalog, MetadataCatalog fro...
38.010101
113
0.694924
#!/usr/bin/env python # Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved import argparse import json import numpy as np import os from collections import defaultdict import cv2 import tqdm from fvcore.common.file_io import PathManager from detectron2.data import DatasetCatalog, MetadataCatalog fro...
764
0
84
177d2a8d43f9df27b52462867dbb85d9efe08de4
4,198
py
Python
noseselecttests/__init__.py
hayato-nomura/nose-selecttests
024b28d72830a84ed705ce8058ca6880b8c253da
[ "BSD-3-Clause" ]
null
null
null
noseselecttests/__init__.py
hayato-nomura/nose-selecttests
024b28d72830a84ed705ce8058ca6880b8c253da
[ "BSD-3-Clause" ]
null
null
null
noseselecttests/__init__.py
hayato-nomura/nose-selecttests
024b28d72830a84ed705ce8058ca6880b8c253da
[ "BSD-3-Clause" ]
3
2019-02-08T09:05:47.000Z
2020-01-05T00:16:41.000Z
import logging from fnmatch import fnmatch import six from nose.plugins.base import Plugin from nose.selector import Selector log = logging.getLogger(__name__) class MockPlugins(object): '''Mock "plugins" that does nothing to avoid infinite recursion calls from Selector''' class NoseSelectPlugin(Plu...
33.055118
115
0.612196
import logging from fnmatch import fnmatch import six from nose.plugins.base import Plugin from nose.selector import Selector log = logging.getLogger(__name__) class MockPlugins(object): '''Mock "plugins" that does nothing to avoid infinite recursion calls from Selector''' def wantClass(self, cls...
1,348
0
292
546124d306ea0f5331b8da9b42903b7829352171
916
py
Python
rt_gene/rt_gene_model_training/pytorch/utils/CombineGazeH5Datasets.py
martinhoang11/OpenSeeFace
c6c9b8c6c00e0e674bce781f2e372fe9109fe44b
[ "BSD-2-Clause" ]
1
2021-03-23T04:58:02.000Z
2021-03-23T04:58:02.000Z
rt_gene/rt_gene_model_training/pytorch/utils/CombineGazeH5Datasets.py
martinhoang11/OpenSeeFace
c6c9b8c6c00e0e674bce781f2e372fe9109fe44b
[ "BSD-2-Clause" ]
null
null
null
rt_gene/rt_gene_model_training/pytorch/utils/CombineGazeH5Datasets.py
martinhoang11/OpenSeeFace
c6c9b8c6c00e0e674bce781f2e372fe9109fe44b
[ "BSD-2-Clause" ]
null
null
null
import os from argparse import ArgumentParser import h5py root_dir = os.path.dirname(os.path.realpath(__file__)) root_parser = ArgumentParser(add_help=False) root_parser.add_argument('--hdf5_file', type=str, required=True, help='path to the datasets to combine', action="append") root_parser.add_argument('--save_file...
31.586207
123
0.724891
import os from argparse import ArgumentParser import h5py root_dir = os.path.dirname(os.path.realpath(__file__)) root_parser = ArgumentParser(add_help=False) root_parser.add_argument('--hdf5_file', type=str, required=True, help='path to the datasets to combine', action="append") root_parser.add_argument('--save_file...
0
0
0
7fedac847fd77f0474904414fc1ae600f359f697
5,130
py
Python
third_party/google-endpoints/Crypto/Cipher/DES3.py
tingshao/catapult
a8fe19e0c492472a8ed5710be9077e24cc517c5c
[ "BSD-3-Clause" ]
2,151
2020-04-18T07:31:17.000Z
2022-03-31T08:39:18.000Z
third_party/google-endpoints/Crypto/Cipher/DES3.py
tingshao/catapult
a8fe19e0c492472a8ed5710be9077e24cc517c5c
[ "BSD-3-Clause" ]
4,640
2015-07-08T16:19:08.000Z
2019-12-02T15:01:27.000Z
third_party/google-endpoints/Crypto/Cipher/DES3.py
tingshao/catapult
a8fe19e0c492472a8ed5710be9077e24cc517c5c
[ "BSD-3-Clause" ]
698
2015-06-02T19:18:35.000Z
2022-03-29T16:57:15.000Z
# -*- coding: utf-8 -*- # # Cipher/DES3.py : DES3 # # =================================================================== # The contents of this file are dedicated to the public domain. To # the extent that dedication to the public domain is not available, # everyone is granted a worldwide, perpetual, royalty-free, #...
38.283582
91
0.676803
# -*- coding: utf-8 -*- # # Cipher/DES3.py : DES3 # # =================================================================== # The contents of this file are dedicated to the public domain. To # the extent that dedication to the public domain is not available, # everyone is granted a worldwide, perpetual, royalty-free, #...
0
0
0
9862cb96709443616c80dacb4c1549b27d5806b6
2,334
py
Python
ipyvolume/__init__.py
wolfv/ipyvolume
5cfe5c3baf105c37611dc964ffd1b6a983032529
[ "MIT" ]
1
2019-01-31T02:43:17.000Z
2019-01-31T02:43:17.000Z
ipyvolume/__init__.py
DalavanCloud/ipyvolume
ce1546ac37a8f9a946ce0fac3ea9dcde06ff004b
[ "MIT" ]
null
null
null
ipyvolume/__init__.py
DalavanCloud/ipyvolume
ce1546ac37a8f9a946ce0fac3ea9dcde06ff004b
[ "MIT" ]
1
2019-01-31T02:43:07.000Z
2019-01-31T02:43:07.000Z
from __future__ import absolute_import from ipyvolume._version import __version__ from ipyvolume import styles from ipyvolume import examples from ipyvolume import datasets from ipyvolume import embed from ipyvolume.widgets import (Mesh, Scatter, Volume, ...
37.047619
66
0.33976
from __future__ import absolute_import from ipyvolume._version import __version__ from ipyvolume import styles from ipyvolume import examples from ipyvolume import datasets from ipyvolume import embed from ipyvolume.widgets import (Mesh, Scatter, Volume, ...
159
0
23
f8eff9fa044a3fecc9cab555ef3849feb080797a
3,555
py
Python
chapter_07/random_walk.py
linklab/link_rl_book_codes
b272b46d5ecd2802f34648440ff53641c68cbbf0
[ "MIT" ]
null
null
null
chapter_07/random_walk.py
linklab/link_rl_book_codes
b272b46d5ecd2802f34648440ff53641c68cbbf0
[ "MIT" ]
7
2020-11-13T18:57:32.000Z
2022-02-10T01:52:44.000Z
chapter_07/random_walk.py
linklab/link_rl_book_codes
b272b46d5ecd2802f34648440ff53641c68cbbf0
[ "MIT" ]
1
2021-09-07T12:41:33.000Z
2021-09-07T12:41:33.000Z
import numpy as np import matplotlib as mpl import matplotlib.pyplot as plt plt.rcParams["font.family"] = 'NanumBarunGothic' plt.rcParams["font.size"] = 12 mpl.rcParams['axes.unicode_minus'] = False # 모든 상태의 개수 (종료 상태 제외) N_STATES = 19 # 감가율 GAMMA = 1 # 종료 상태를 제외한 모든 상태 STATES = np.arange(1, N_STATES + 1) # 초기 상태 ...
25.212766
114
0.523769
import numpy as np import matplotlib as mpl import matplotlib.pyplot as plt plt.rcParams["font.family"] = 'NanumBarunGothic' plt.rcParams["font.size"] = 12 mpl.rcParams['axes.unicode_minus'] = False # 모든 상태의 개수 (종료 상태 제외) N_STATES = 19 # 감가율 GAMMA = 1 # 종료 상태를 제외한 모든 상태 STATES = np.arange(1, N_STATES + 1) # 초기 상태 ...
3,144
0
45
33f335bd045410797ade92a111bceddca26e2cc5
3,560
py
Python
PolSAR_distance_metric.py
yoyoyoohh/PolSAR_unsupervised_CD
063986eb6fa172e861ccc556bf8806767bc89624
[ "Apache-2.0" ]
3
2021-10-14T03:49:37.000Z
2022-02-16T01:16:08.000Z
PolSAR_distance_metric.py
slchenchn/PolSAR-unsupervised-change-detection
e5788d59c7d209546216b7d4e3ed1931a1bed816
[ "Apache-2.0" ]
null
null
null
PolSAR_distance_metric.py
slchenchn/PolSAR-unsupervised-change-detection
e5788d59c7d209546216b7d4e3ed1931a1bed816
[ "Apache-2.0" ]
3
2021-07-04T08:24:56.000Z
2022-02-09T14:08:50.000Z
''' Author: Shuailin Chen Created Date: 2021-05-18 Last Modified: 2021-05-19 content: adapt from Song Hui's matlab code ''' import os.path as osp import numpy as np from mylib import polSAR_utils as psr def determinant(A): ''' Calculate determinant of a C3 matrix Args: A (ndarray): PolSAR data ...
29.421488
114
0.467697
''' Author: Shuailin Chen Created Date: 2021-05-18 Last Modified: 2021-05-19 content: adapt from Song Hui's matlab code ''' import os.path as osp import numpy as np from mylib import polSAR_utils as psr def determinant(A): ''' Calculate determinant of a C3 matrix Args: A (ndarray): PolSAR data ...
0
0
0
1042923fa2ea1cefa57096d64ecbf73396befaa7
8,795
py
Python
evosoro/base.py
DanielLinsc/evosoro
6e9e584d3af4c1e0b50594d3c180ca838f343c54
[ "MIT" ]
1
2021-02-16T23:04:43.000Z
2021-02-16T23:04:43.000Z
evosoro/base.py
DanielLinsc/evosoro
6e9e584d3af4c1e0b50594d3c180ca838f343c54
[ "MIT" ]
null
null
null
evosoro/base.py
DanielLinsc/evosoro
6e9e584d3af4c1e0b50594d3c180ca838f343c54
[ "MIT" ]
null
null
null
from evosoro.tools.utils import xml_format import numpy as np # TODO: classes should hold dictionaries of variables, vxa tags and values # TODO: remove most of the hard coded text from read_write_voxelyze.py and replace with a few loops # TODO: add method to VoxCadParams for organizing (nested) subsections in vxa fil...
44.872449
120
0.652189
from evosoro.tools.utils import xml_format import numpy as np # TODO: classes should hold dictionaries of variables, vxa tags and values # TODO: remove most of the hard coded text from read_write_voxelyze.py and replace with a few loops # TODO: add method to VoxCadParams for organizing (nested) subsections in vxa fil...
4,944
0
189
40d4ecf6750745426b9186a651dcdd0849af6c66
2,881
py
Python
api/views/scheduled_test_viewset.py
adkl/etf_online_competition_system
c857ce78aec65c1d31f48ae8b8dc6facdb022a0c
[ "MIT" ]
null
null
null
api/views/scheduled_test_viewset.py
adkl/etf_online_competition_system
c857ce78aec65c1d31f48ae8b8dc6facdb022a0c
[ "MIT" ]
null
null
null
api/views/scheduled_test_viewset.py
adkl/etf_online_competition_system
c857ce78aec65c1d31f48ae8b8dc6facdb022a0c
[ "MIT" ]
null
null
null
from django.db.models import F from django.utils import timezone from rest_framework.viewsets import ModelViewSet, ViewSet from rest_framework.decorators import list_route, detail_route from rest_framework.response import Response from rest_framework.mixins import RetrieveModelMixin from api.models import ScheduledTest...
42.367647
144
0.681361
from django.db.models import F from django.utils import timezone from rest_framework.viewsets import ModelViewSet, ViewSet from rest_framework.decorators import list_route, detail_route from rest_framework.response import Response from rest_framework.mixins import RetrieveModelMixin from api.models import ScheduledTest...
1,972
444
23
4eb5a5c8098b88796228a9a8c0a0b54af34ce005
1,115
py
Python
project2.py
ballisticpotato/Python-Data-Analysis-Project
4a4efd0a816fe280e049ce44ba409fcee15b9ccb
[ "MIT" ]
1
2019-10-30T20:36:24.000Z
2019-10-30T20:36:24.000Z
project2.py
ballisticpotato/Python-Data-Analysis-Project
4a4efd0a816fe280e049ce44ba409fcee15b9ccb
[ "MIT" ]
null
null
null
project2.py
ballisticpotato/Python-Data-Analysis-Project
4a4efd0a816fe280e049ce44ba409fcee15b9ccb
[ "MIT" ]
null
null
null
from sklearn.kernel_ridge import KernelRidge from sklearn.grid_search import GridSearchCV import numpy as np import csv rawData = np.zeros((4104,4)) with open('Processed Time Dependent Data.csv', 'rb') as f: reader = csv.reader(f) labels = reader.next() i = 0 for row in reader: for j in range...
24.23913
90
0.619731
from sklearn.kernel_ridge import KernelRidge from sklearn.grid_search import GridSearchCV import numpy as np import csv rawData = np.zeros((4104,4)) with open('Processed Time Dependent Data.csv', 'rb') as f: reader = csv.reader(f) labels = reader.next() i = 0 for row in reader: for j in range...
0
0
0
1d90bd3f3f12955cb3b182b9e43f0813a1edb8be
3,564
py
Python
minikts/parsing.py
konodyuk/minikts
9ffb978e2048a11f118a5b4f5eed46d66fa5fb08
[ "MIT" ]
1
2021-03-13T16:48:03.000Z
2021-03-13T16:48:03.000Z
minikts/parsing.py
konodyuk/minikts
9ffb978e2048a11f118a5b4f5eed46d66fa5fb08
[ "MIT" ]
null
null
null
minikts/parsing.py
konodyuk/minikts
9ffb978e2048a11f118a5b4f5eed46d66fa5fb08
[ "MIT" ]
null
null
null
import sys import attr import parse from contextlib import redirect_stdout original_stdout = sys.stdout @attr.s() def parse_stdout(patterns, *callbacks): """Parses each stdout line in line with `patterns` argument and sequentially calls callbacks Args: patterns: tuple of patterns compatible with `pa...
41.44186
105
0.618406
import sys import attr import parse from contextlib import redirect_stdout original_stdout = sys.stdout @attr.s() class StreamParser: patterns = attr.ib() buf = attr.ib(factory=str, init=False) callbacks = attr.ib(default=[print]) def write(self, b): self.buf += b if self.buf.find('\n...
572
173
22
bc22db7471ca30446f0c0320f6f10f83823c0ae3
705
py
Python
tests/test_set_questions_file_path.py
MTelford/diary-tool
27e941c330d46f6e6a5817ad3006855205a041ae
[ "MIT" ]
null
null
null
tests/test_set_questions_file_path.py
MTelford/diary-tool
27e941c330d46f6e6a5817ad3006855205a041ae
[ "MIT" ]
10
2021-08-16T22:52:29.000Z
2021-09-17T15:14:34.000Z
tests/test_set_questions_file_path.py
MTelford/diary_tool
27e941c330d46f6e6a5817ad3006855205a041ae
[ "MIT" ]
null
null
null
import unittest import pathlib from diary_tool_main.diary_tool import set_questions_file_path if __name__ == '__main__': unittest.main()
27.115385
72
0.695035
import unittest import pathlib from diary_tool_main.diary_tool import set_questions_file_path class TestSetQuestionsFilePath(unittest.TestCase): def test_set_questions_file_path(self): """ Tests that function sets file path for questions correctly """ # actual path to funct...
0
538
23
21c50fbbf90c0191cf46b4687cdd84aa9ec94a2c
7,268
py
Python
gammapy/detect/cwt.py
zblz/gammapy
49539f25886433abeedc8852387ab4cd73977006
[ "BSD-3-Clause" ]
null
null
null
gammapy/detect/cwt.py
zblz/gammapy
49539f25886433abeedc8852387ab4cd73977006
[ "BSD-3-Clause" ]
null
null
null
gammapy/detect/cwt.py
zblz/gammapy
49539f25886433abeedc8852387ab4cd73977006
[ "BSD-3-Clause" ]
null
null
null
# Licensed under a 3-clause BSD style license - see LICENSE.rst from __future__ import print_function, division import logging import numpy as np from astropy.io import fits from astropy.wcs import WCS __all__ = ['CWT'] def gauss_kernel(radius, n_sigmas=8): """Normalized 2D gauss kernel array. """ sizex ...
37.658031
103
0.592873
# Licensed under a 3-clause BSD style license - see LICENSE.rst from __future__ import print_function, division import logging import numpy as np from astropy.io import fits from astropy.wcs import WCS __all__ = ['CWT'] def gauss_kernel(radius, n_sigmas=8): """Normalized 2D gauss kernel array. """ sizex ...
754
0
26
02fa655762a8c5f87ff87bed426342d23902e763
4,743
py
Python
slidingwindow_generator/slidingwindow_generator.py
flashspys/SlidingWindowGenerator
bdcefd9506732ea9c9734bd4e8e81a884b78f08c
[ "Apache-2.0" ]
3
2021-03-27T12:50:36.000Z
2022-01-16T15:30:22.000Z
slidingwindow_generator/slidingwindow_generator.py
flashspys/SlidingWindowGenerator
bdcefd9506732ea9c9734bd4e8e81a884b78f08c
[ "Apache-2.0" ]
3
2020-10-07T05:28:46.000Z
2020-11-05T08:32:01.000Z
slidingwindow_generator/slidingwindow_generator.py
flashspys/SlidingWindowGenerator
bdcefd9506732ea9c9734bd4e8e81a884b78f08c
[ "Apache-2.0" ]
1
2020-11-08T23:39:20.000Z
2020-11-08T23:39:20.000Z
import numpy as np import tensorflow as tf
37.346457
79
0.59709
import numpy as np import tensorflow as tf class SlidingWindowGenerator: def __init__(self, input_width, label_width, shift, train_df, val_df, test_df, label_columns=None): # Store raw data with dataframe type self.train_df = train_df self.val_df = val_df ...
1,950
2,764
23
ff1864b9e1aeedced66a6bc9d8f7093ad8f1e465
19,744
py
Python
src/widgettree.py
pariahsoft/Driftwood
fc5a8705031a4a676d2cb1132e33ee6aac45d5be
[ "MIT" ]
14
2018-06-30T15:37:20.000Z
2022-01-14T01:27:04.000Z
src/widgettree.py
seisatsu/Driftwood
fc5a8705031a4a676d2cb1132e33ee6aac45d5be
[ "MIT" ]
143
2016-10-08T22:52:52.000Z
2017-10-09T08:59:11.000Z
src/widgettree.py
driftwoodwg/Driftwood
fc5a8705031a4a676d2cb1132e33ee6aac45d5be
[ "MIT" ]
null
null
null
#################################### # Driftwood 2D Game Dev. Suite # # widgettree.py # # Copyright 2014-2017 # # Michael D. Reiley & Paul Merrill # #################################### # ********** # Permission is hereby granted, free of charge, to any person obtaining a copy # of ...
42.921739
117
0.531098
#################################### # Driftwood 2D Game Dev. Suite # # widgettree.py # # Copyright 2014-2017 # # Michael D. Reiley & Paul Merrill # #################################### # ********** # Permission is hereby granted, free of charge, to any person obtaining a copy # of ...
4,305
0
81
bb48fe039574e1042513b5009d411aa8bd65eed1
2,616
py
Python
mushroom-app/data-collector/cli.py
TangJiahui/AC215-Advanced_Practical_Data_Science
904e595630ddb9b2348889ce0d2cc777bb90f071
[ "MIT" ]
null
null
null
mushroom-app/data-collector/cli.py
TangJiahui/AC215-Advanced_Practical_Data_Science
904e595630ddb9b2348889ce0d2cc777bb90f071
[ "MIT" ]
null
null
null
mushroom-app/data-collector/cli.py
TangJiahui/AC215-Advanced_Practical_Data_Science
904e595630ddb9b2348889ce0d2cc777bb90f071
[ "MIT" ]
null
null
null
"""Downloading the images from Firefox based on the search term specified This scripts scrapes Firefox and downloads Google images of different images Typical usage example from command line: python -m cli --nums 10 --search "oyster mushrooms" "crimini mushrooms" "amanita mushrooms" --opp "search" """...
39.044776
114
0.659021
"""Downloading the images from Firefox based on the search term specified This scripts scrapes Firefox and downloads Google images of different images Typical usage example from command line: python -m cli --nums 10 --search "oyster mushrooms" "crimini mushrooms" "amanita mushrooms" --opp "search" """...
1,204
0
23
0ee08dcbf61ca0d7aa66b854de14d3699ca5fdae
7,208
py
Python
source/mysql/dffml_source_mysql/source.py
sourabhyadav999/dffml
beda53caf483f4d010d97795f13527b4b573fa37
[ "MIT" ]
1
2020-02-07T07:33:15.000Z
2020-02-07T07:33:15.000Z
source/mysql/dffml_source_mysql/source.py
sourabhyadav999/dffml
beda53caf483f4d010d97795f13527b4b573fa37
[ "MIT" ]
null
null
null
source/mysql/dffml_source_mysql/source.py
sourabhyadav999/dffml
beda53caf483f4d010d97795f13527b4b573fa37
[ "MIT" ]
null
null
null
import os import ssl import collections from typing import AsyncIterator, NamedTuple, Dict, List import aiomysql from dffml.base import BaseConfig from dffml.repo import Repo from dffml.source.source import BaseSourceContext, BaseSource from dffml.util.cli.arg import Arg from dffml.util.entrypoint import entrypoint ...
34.488038
135
0.541898
import os import ssl import collections from typing import AsyncIterator, NamedTuple, Dict, List import aiomysql from dffml.base import BaseConfig from dffml.repo import Repo from dffml.source.source import BaseSourceContext, BaseSource from dffml.util.cli.arg import Arg from dffml.util.entrypoint import entrypoint ...
6,217
418
229
062aaee8df921f1852a3fb8715afd38dc987dcd1
3,917
py
Python
karp/domain/index.py
spraakbanken/karp-backend-v6-tmp
e5b78157bd999df18c188973ae2a337015b6f35d
[ "MIT" ]
1
2021-12-08T15:33:42.000Z
2021-12-08T15:33:42.000Z
karp/domain/index.py
spraakbanken/karp-backend-v6-tmp
e5b78157bd999df18c188973ae2a337015b6f35d
[ "MIT" ]
null
null
null
karp/domain/index.py
spraakbanken/karp-backend-v6-tmp
e5b78157bd999df18c188973ae2a337015b6f35d
[ "MIT" ]
null
null
null
import abc import typing from karp.domain.models.resource import Resource from typing import Optional, Callable, TypeVar, List, Dict, Tuple import logging import attr import pydantic from karp.domain import errors, model from karp.domain.errors import ConfigurationError from karp.domain.models.query import Query fro...
27.978571
98
0.648966
import abc import typing from karp.domain.models.resource import Resource from typing import Optional, Callable, TypeVar, List, Dict, Tuple import logging import attr import pydantic from karp.domain import errors, model from karp.domain.errors import ConfigurationError from karp.domain.models.query import Query fro...
2,320
1,101
68
d82aebdeb4fda0b4feb795961248783bbc4e128f
2,431
py
Python
user.py
vlee489/Turnip-Bot
2571846607d6ca57171325211c5eb6572013c767
[ "MIT" ]
5
2020-04-19T22:47:28.000Z
2020-06-01T04:37:12.000Z
user.py
vlee489/Turnip-Bot
2571846607d6ca57171325211c5eb6572013c767
[ "MIT" ]
7
2020-04-21T23:25:20.000Z
2021-04-20T07:50:11.000Z
user.py
vlee489/Turnip-Bot
2571846607d6ca57171325211c5eb6572013c767
[ "MIT" ]
null
null
null
""" This file contains commands related to user configuration and management. """ from discord.ext import commands, tasks import discord import errors import turnipCalculator import datetime
45.867925
107
0.517483
""" This file contains commands related to user configuration and management. """ from discord.ext import commands, tasks import discord import errors import turnipCalculator import datetime class Users(commands.Cog): def __init__(self, bot): self.bot = bot self.pendingDelete = [] @tasks.loop...
1,955
237
46
ff31b9b80a371f2d81a6e87536f86de304bbe09f
2,261
py
Python
matchreporter/matchreporter_cli.py
moynihanrory/matchreporter
c71d2332fde6e83a0d6cb554af9f3fd7082a4ea6
[ "MIT" ]
null
null
null
matchreporter/matchreporter_cli.py
moynihanrory/matchreporter
c71d2332fde6e83a0d6cb554af9f3fd7082a4ea6
[ "MIT" ]
null
null
null
matchreporter/matchreporter_cli.py
moynihanrory/matchreporter
c71d2332fde6e83a0d6cb554af9f3fd7082a4ea6
[ "MIT" ]
null
null
null
import sys import logging import argparse import os from matchreporter.analysis.analyser import analyse from matchreporter.collect import scxmlformatter, gaamatchformatter from matchreporter.db.analysis_db import write_report_data from matchreporter.helpers.filehelper import load_data_from_file SPORTS_CODE = 'SportsC...
31.84507
122
0.728881
import sys import logging import argparse import os from matchreporter.analysis.analyser import analyse from matchreporter.collect import scxmlformatter, gaamatchformatter from matchreporter.db.analysis_db import write_report_data from matchreporter.helpers.filehelper import load_data_from_file SPORTS_CODE = 'SportsC...
1,545
0
46
6b3e24e58e12c891c4d93a70c22683dddcd08cf8
1,753
py
Python
tests/numpy/linalg_test.py
Walon1998/dace
95ddfd3e9a5c654f0f0d66d026e0b64ec0f028a0
[ "BSD-3-Clause" ]
1
2022-03-11T13:36:34.000Z
2022-03-11T13:36:34.000Z
tests/numpy/linalg_test.py
Walon1998/dace
95ddfd3e9a5c654f0f0d66d026e0b64ec0f028a0
[ "BSD-3-Clause" ]
null
null
null
tests/numpy/linalg_test.py
Walon1998/dace
95ddfd3e9a5c654f0f0d66d026e0b64ec0f028a0
[ "BSD-3-Clause" ]
null
null
null
# Copyright 2019-2021 ETH Zurich and the DaCe authors. All rights reserved. import dace import numpy as np import pytest @dace.program @dace.program @dace.program if __name__ == "__main__": test_linalg_inv() test_linalg_solve() test_linalg_cholesky()
24.013699
75
0.662864
# Copyright 2019-2021 ETH Zurich and the DaCe authors. All rights reserved. import dace import numpy as np import pytest def generate_invertible_matrix(size, dtype): if dtype == np.float32: tol = 1e-6 elif dtype == np.float64: tol = 1e-12 else: raise NotImplementedError while T...
1,272
0
204
8aa26b6c6e55cf8c288eb1f9ca6da84d75882d3f
1,528
py
Python
tests/test_userList.py
konung-yaropolk/pyABF
b5620e73ac5d060129b844da44f8b2611536ac56
[ "MIT" ]
74
2017-11-06T17:53:48.000Z
2022-03-27T12:14:46.000Z
tests/test_userList.py
konung-yaropolk/pyABF
b5620e73ac5d060129b844da44f8b2611536ac56
[ "MIT" ]
116
2018-01-16T21:36:29.000Z
2022-03-31T11:46:04.000Z
tests/test_userList.py
konung-yaropolk/pyABF
b5620e73ac5d060129b844da44f8b2611536ac56
[ "MIT" ]
30
2018-06-28T13:19:53.000Z
2022-03-25T02:52:48.000Z
""" This file tests retrieval of values from the user list. The user list replaces one cell in the waveform editor for episodic files. Instead of using a value and a delta, the user can provide a list of values to apply by sweep. """ import sys import pytest import numpy as np try: # this ensures pyABF is import...
30.56
118
0.650524
""" This file tests retrieval of values from the user list. The user list replaces one cell in the waveform editor for episodic files. Instead of using a value and a delta, the user can provide a list of values to apply by sweep. """ import sys import pytest import numpy as np try: # this ensures pyABF is import...
195
0
44
dd63c5d273cef1d1f31b196ac37b6593b96ac9bd
906
py
Python
python_tutor/11_dictionary/elections.py
ctatuk/pylearn
29566b75c14f867bd7e8fc19c236e9be4f9f5203
[ "Apache-2.0" ]
null
null
null
python_tutor/11_dictionary/elections.py
ctatuk/pylearn
29566b75c14f867bd7e8fc19c236e9be4f9f5203
[ "Apache-2.0" ]
2
2020-05-16T14:46:50.000Z
2020-06-20T16:35:37.000Z
python_tutor/11_dictionary/elections.py
ctatuk/pylearn
29566b75c14f867bd7e8fc19c236e9be4f9f5203
[ "Apache-2.0" ]
2
2020-05-03T09:13:55.000Z
2020-09-23T11:58:01.000Z
usa_elections([('m', 13), ('o', 76), ('m', 54), ('m', 7)]) usa_elections2([('m', 13), ('o', 76), ('m', 54), ('m', 7)]) usa_elections3([('m', 13), ('o', 76), ('m', 54), ('m', 7)])
31.241379
118
0.611479
def usa_elections(state_elections): elections_result = {} for n, m in state_elections: if n in elections_result.keys(): tmp = elections_result.pop(n) + m elections_result[n] = tmp else: elections_result[n] = m print(sorted(elections_result.items())) def ...
655
0
68
adfd001a37f08cd2177c0d1fcf39aab27442e81b
13,073
py
Python
venv/dbManage.py
180Studios/LoginApp
66ff684a81b23d8f45eef2c56be19a2afd95ab29
[ "MIT" ]
null
null
null
venv/dbManage.py
180Studios/LoginApp
66ff684a81b23d8f45eef2c56be19a2afd95ab29
[ "MIT" ]
5
2021-03-18T22:28:19.000Z
2022-03-11T23:41:33.000Z
venv/dbManage.py
180Studios/LoginApp
66ff684a81b23d8f45eef2c56be19a2afd95ab29
[ "MIT" ]
1
2020-02-02T21:17:12.000Z
2020-02-02T21:17:12.000Z
""" Current Limitations: - A member cannot transition from a monthly to a punchcard without losing the remainder of their time """ import sys import pprint import hashlib from datetime import datetime, date, time, timedelta import time from tinydb import * from tinydb.operations import decrement import re im...
44.315254
127
0.591907
""" Current Limitations: - A member cannot transition from a monthly to a punchcard without losing the remainder of their time """ import sys import pprint import hashlib from datetime import datetime, date, time, timedelta import time from tinydb import * from tinydb.operations import decrement import re im...
8,297
0
266
26e8614db3b2844907e182a2734e56f546e2ce1a
4,159
py
Python
prep_mortality.py
birdx0810/mimic3-benchmarks
6a663966ebe1355856380c144fb4f8a2e88d42b4
[ "MIT" ]
null
null
null
prep_mortality.py
birdx0810/mimic3-benchmarks
6a663966ebe1355856380c144fb4f8a2e88d42b4
[ "MIT" ]
null
null
null
prep_mortality.py
birdx0810/mimic3-benchmarks
6a663966ebe1355856380c144fb4f8a2e88d42b4
[ "MIT" ]
1
2021-04-10T02:30:17.000Z
2021-04-10T02:30:17.000Z
import pandas as pd import numpy as np from mimic3benchmark.readers import InHospitalMortalityReader HEADERS = [ "Index", "Hours", "Capillary refill rate", "Diastolic blood pressure", "Fraction inspired oxygen", "Glascow coma scale eye opening", "Glascow coma scale motor response", "Glascow coma scale to...
30.580882
78
0.632364
import pandas as pd import numpy as np from mimic3benchmark.readers import InHospitalMortalityReader HEADERS = [ "Index", "Hours", "Capillary refill rate", "Diastolic blood pressure", "Fraction inspired oxygen", "Glascow coma scale eye opening", "Glascow coma scale motor response", "Glascow coma scale to...
2,466
0
46
e26997be0b1d31819e7518b45db3823185c85186
898
py
Python
weight/users/models/users.py
aleducode/lose_weightapp
1210cf3104c0fc929509ff6e51337dbd2dfa157e
[ "MIT" ]
3
2019-08-21T06:18:57.000Z
2019-11-04T03:00:43.000Z
weight/users/models/users.py
alejandroduquec/lose_weightapp
1210cf3104c0fc929509ff6e51337dbd2dfa157e
[ "MIT" ]
11
2019-12-20T17:17:27.000Z
2022-03-12T00:09:01.000Z
weight/users/models/users.py
SeptumDevs/lose_weightapp
2c39ba45aa6aef37820b385c3060c83a73f8f910
[ "MIT" ]
2
2019-08-07T14:56:57.000Z
2019-09-03T00:13:31.000Z
"""User model.""" # Django from django.db import models from django.contrib.auth.models import AbstractUser # Utils from weight.utils.models import WeightModel class User(WeightModel, AbstractUser): """User model. Extend from Django abstract user, change the username field to email and add some extra i...
21.902439
72
0.624722
"""User model.""" # Django from django.db import models from django.contrib.auth.models import AbstractUser # Utils from weight.utils.models import WeightModel class User(WeightModel, AbstractUser): """User model. Extend from Django abstract user, change the username field to email and add some extra i...
0
0
0
be0af01b6d78a607e74bf0afc9f7a32a735e57c1
2,005
py
Python
kanon_api/routes/calculations.py
legau/kanon-api
bae8fcba11caefa2f6715247852f853bb52fb9a6
[ "BSD-3-Clause" ]
null
null
null
kanon_api/routes/calculations.py
legau/kanon-api
bae8fcba11caefa2f6715247852f853bb52fb9a6
[ "BSD-3-Clause" ]
80
2021-04-21T16:02:03.000Z
2022-03-28T00:48:58.000Z
kanon_api/routes/calculations.py
legau/kanon-api
bae8fcba11caefa2f6715247852f853bb52fb9a6
[ "BSD-3-Clause" ]
null
null
null
from enum import Enum from typing import Type from fastapi.param_functions import Depends, Path, Query from fastapi.routing import APIRouter, HTTPException from kanon.units.radices import BasedReal, IllegalBaseValueError from kanon_api.core.calculations.parser import parse from kanon_api.utils import safe_radix rout...
24.156627
83
0.660349
from enum import Enum from typing import Type from fastapi.param_functions import Depends, Path, Query from fastapi.routing import APIRouter, HTTPException from kanon.units.radices import BasedReal, IllegalBaseValueError from kanon_api.core.calculations.parser import parse from kanon_api.utils import safe_radix rout...
1,145
70
134
1897b6c6f7cb0200731ca062c3689139850dcb45
618
py
Python
1094.py
barroslipe/urionlinejudge
a20d8199d9a92b30ea394a6c949967d2fc51aa34
[ "MIT" ]
null
null
null
1094.py
barroslipe/urionlinejudge
a20d8199d9a92b30ea394a6c949967d2fc51aa34
[ "MIT" ]
null
null
null
1094.py
barroslipe/urionlinejudge
a20d8199d9a92b30ea394a6c949967d2fc51aa34
[ "MIT" ]
null
null
null
n = int(input()) coelhos = 0 ratos = 0 sapos = 0 for i in range(n): quantia, tipo = input().split() quantia = int(quantia) if tipo == 'C': coelhos += quantia elif tipo == 'R': ratos += quantia else: sapos += quantia total = coelhos + ratos + sapos print(f"Total: {total}...
22.888889
62
0.60356
n = int(input()) coelhos = 0 ratos = 0 sapos = 0 for i in range(n): quantia, tipo = input().split() quantia = int(quantia) if tipo == 'C': coelhos += quantia elif tipo == 'R': ratos += quantia else: sapos += quantia total = coelhos + ratos + sapos print(f"Total: {total}...
0
0
0
fc6615f6c5f14d121de15edf5c6ef89c8391483c
1,537
py
Python
tests/schema/github/mutation/test_authenticate_with_git_hub.py
simonsobs/acondbs
6ca11c2889d827ecdb2b54d0cf3b94b8cdd281e6
[ "MIT" ]
null
null
null
tests/schema/github/mutation/test_authenticate_with_git_hub.py
simonsobs/acondbs
6ca11c2889d827ecdb2b54d0cf3b94b8cdd281e6
[ "MIT" ]
24
2020-04-02T19:29:07.000Z
2022-03-08T03:05:43.000Z
tests/schema/github/mutation/test_authenticate_with_git_hub.py
simonsobs/acondbs
6ca11c2889d827ecdb2b54d0cf3b94b8cdd281e6
[ "MIT" ]
1
2020-04-08T15:48:28.000Z
2020-04-08T15:48:28.000Z
import textwrap from async_asgi_testclient import TestClient from a2wsgi import WSGIMiddleware import pytest import unittest.mock as mock ##__________________________________________________________________|| @pytest.fixture(autouse=True) ##__________________________________________________________________|| @pyt...
26.964912
84
0.681848
import textwrap from async_asgi_testclient import TestClient from a2wsgi import WSGIMiddleware import pytest import unittest.mock as mock ##__________________________________________________________________|| @pytest.fixture(autouse=True) def mock_authenticate(monkeypatch): y = mock.Mock() monkeypatch.setat...
1,083
0
44
a1e0f3993847051950cc9069c5e739fa2497d70a
3,341
py
Python
models/base.py
SDJustus/PaDiM
98684d47f71214a30687e11eb798cd5a27a8de15
[ "MIT" ]
null
null
null
models/base.py
SDJustus/PaDiM
98684d47f71214a30687e11eb798cd5a27a8de15
[ "MIT" ]
null
null
null
models/base.py
SDJustus/PaDiM
98684d47f71214a30687e11eb798cd5a27a8de15
[ "MIT" ]
null
null
null
from typing import Union, Tuple import torch from torch import Tensor, device as Device from utils import embeddings_concat from backbones import ResNet18,ResNet50, WideResNet50, EfficientNetB5 from utils.visualizer import Visualizer class BaseModel: """The embedding backbone shared by PaDiM and PaDiMSVDD "...
36.315217
122
0.622568
from typing import Union, Tuple import torch from torch import Tensor, device as Device from utils import embeddings_concat from backbones import ResNet18,ResNet50, WideResNet50, EfficientNetB5 from utils.visualizer import Visualizer class BaseModel: """The embedding backbone shared by PaDiM and PaDiMSVDD "...
2,838
0
162
18b4f7bb7688e6906cb778fe2aa8673bcb717cb7
5,069
py
Python
receiveSTA/rcv_phase_queen.py
ilinastoilkovska/syncTA
9224ef50d5ada4782d0a1d5723531ebe43149584
[ "Apache-2.0" ]
2
2021-01-05T11:45:48.000Z
2021-04-06T12:59:38.000Z
receiveSTA/rcv_phase_queen.py
ilinastoilkovska/syncTA
9224ef50d5ada4782d0a1d5723531ebe43149584
[ "Apache-2.0" ]
null
null
null
receiveSTA/rcv_phase_queen.py
ilinastoilkovska/syncTA
9224ef50d5ada4782d0a1d5723531ebe43149584
[ "Apache-2.0" ]
null
null
null
# process local states local = range(24) # L states L = {"x0" : [0, 12], "x1" : [1, 13], "q0" : [14], "q1" : [15], "qb" : [20]} # receive variables rcv_vars = ["nr0", "nr1", "nrq0", "nrq1"] # initial states initial = [0, 1, 12, 13, 18, 19] # rules rules = [] rules.append({'idx': 0, 'from': 0, 'to': 2, 'guard': "(and ...
44.464912
138
0.537779
# process local states local = range(24) # L states L = {"x0" : [0, 12], "x1" : [1, 13], "q0" : [14], "q1" : [15], "qb" : [20]} # receive variables rcv_vars = ["nr0", "nr1", "nrq0", "nrq1"] # initial states initial = [0, 1, 12, 13, 18, 19] # rules rules = [] rules.append({'idx': 0, 'from': 0, 'to': 2, 'guard': "(and ...
0
0
0
df48654b3889729ab922bcad9596bebdf57a3625
1,012
py
Python
source/pkgsrc/lang/python27/patches/patch-Lib_ctypes_macholib_dyld.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
1
2021-11-20T22:46:39.000Z
2021-11-20T22:46:39.000Z
source/pkgsrc/lang/python27/patches/patch-Lib_ctypes_macholib_dyld.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
null
null
null
source/pkgsrc/lang/python27/patches/patch-Lib_ctypes_macholib_dyld.py
Scottx86-64/dotfiles-1
51004b1e2b032664cce6b553d2052757c286087d
[ "Unlicense" ]
null
null
null
$NetBSD: patch-Lib_ctypes_macholib_dyld.py,v 1.1 2021/06/23 18:30:24 schmonz Exp $ darwin20 support, via MacPorts. --- Lib/ctypes/macholib/dyld.py.orig 2021-06-22 19:20:28.000000000 +0000 +++ Lib/ctypes/macholib/dyld.py @@ -7,6 +7,12 @@ from framework import framework_info from dylib import dylib_info from itertool...
30.666667
82
0.666996
$NetBSD: patch-Lib_ctypes_macholib_dyld.py,v 1.1 2021/06/23 18:30:24 schmonz Exp $ darwin20 support, via MacPorts. --- Lib/ctypes/macholib/dyld.py.orig 2021-06-22 19:20:28.000000000 +0000 +++ Lib/ctypes/macholib/dyld.py @@ -7,6 +7,12 @@ from framework import framework_info from dylib import dylib_info from itertool...
34
0
25
5d0e430154d171e0eabbe5f9558a448abe2f626e
3,191
py
Python
discord/ext/commands/inject.py
aio-org/aio
3a990f8eb89a115c8832f95376e71b7c129d9b26
[ "MIT" ]
12
2021-11-11T14:10:31.000Z
2022-03-16T03:08:16.000Z
discord/ext/commands/inject.py
aio-org/aio
3a990f8eb89a115c8832f95376e71b7c129d9b26
[ "MIT" ]
24
2021-12-27T04:03:20.000Z
2022-01-26T10:24:51.000Z
discord/ext/commands/inject.py
aio-org/aio
3a990f8eb89a115c8832f95376e71b7c129d9b26
[ "MIT" ]
13
2021-11-12T09:06:11.000Z
2022-03-12T13:42:47.000Z
# -*- coding: utf-8 -*- # cython: language_level=3 # Copyright (c) 2021-present VincentRPS # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation t...
31.91
100
0.643372
# -*- coding: utf-8 -*- # cython: language_level=3 # Copyright (c) 2021-present VincentRPS # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation t...
1,740
-21
228
5db81f4348769bdd8cfdd71f2e02741530552433
1,549
py
Python
Algorithms/mf_Linear.py
ParikhKadam/Forecasting_Mutual_Funds
7d033ff7370114967ba3facb7e243b95c3a6540d
[ "MIT" ]
15
2020-12-22T04:58:39.000Z
2022-03-17T10:34:20.000Z
Algorithms/mf_Linear.py
ParikhKadam/Forecasting_Mutual_Funds
7d033ff7370114967ba3facb7e243b95c3a6540d
[ "MIT" ]
1
2021-12-17T04:20:10.000Z
2021-12-18T03:58:36.000Z
Algorithms/mf_Linear.py
ParikhKadam/Forecasting_Mutual_Funds
7d033ff7370114967ba3facb7e243b95c3a6540d
[ "MIT" ]
12
2020-10-11T11:33:35.000Z
2022-02-18T06:50:50.000Z
from Algorithms import *
31.612245
92
0.647515
from Algorithms import * def linear(df): days = 30 last_week = df.iloc[-days:] last_day = df.iloc[-1:] df_new = df df_new['date'] = pd.to_datetime(df_new['date'], dayfirst=True) df_new['Prev CloseNAV'] = df_new['nav'] df_new['NAV'] = df_new['nav'].shift(1) df_new.set_index('date', inp...
1,501
0
23
6fae41d336f9d6f6d8c4520db3d57a993129fcc9
319
py
Python
flask_app.py
filchyboy/minimal_flask_application_with_templates
60dd8a919079a5ff6f1d4a8495ba49ce4653f09e
[ "MIT" ]
null
null
null
flask_app.py
filchyboy/minimal_flask_application_with_templates
60dd8a919079a5ff6f1d4a8495ba49ce4653f09e
[ "MIT" ]
null
null
null
flask_app.py
filchyboy/minimal_flask_application_with_templates
60dd8a919079a5ff6f1d4a8495ba49ce4653f09e
[ "MIT" ]
null
null
null
# flask_app.py - a minimal flsk application # import flask module from flask import Flask, render_template # initiate application app = Flask(__name__) # define route @app.route("/") # attach a function to that route using render_template # from the flask module
19.9375
55
0.752351
# flask_app.py - a minimal flsk application # import flask module from flask import Flask, render_template # initiate application app = Flask(__name__) # define route @app.route("/") # attach a function to that route using render_template # from the flask module def root(): return render_template("home.html")
30
0
22
9023582e4f07df9478c903277a46d34e51a67585
1,769
py
Python
alien.py
portelaoliveira/Spaceship_Game
f4a63477c23c6105cfce844df99ca83cd62c3314
[ "MIT" ]
1
2020-05-16T20:42:40.000Z
2020-05-16T20:42:40.000Z
alien.py
portelaoliveira/Spaceship_Game
f4a63477c23c6105cfce844df99ca83cd62c3314
[ "MIT" ]
null
null
null
alien.py
portelaoliveira/Spaceship_Game
f4a63477c23c6105cfce844df99ca83cd62c3314
[ "MIT" ]
null
null
null
import pygame from pygame.sprite import Sprite class Alien(Sprite): ''' Uma classe que representa um único alienígena da frota. ''' def __init__(self, ai_settings, screen): ''' Inicializa o alienígina e define sua posição inicial. ''' super(Alien, self).__init__() self.screen = screen...
36.854167
107
0.651781
import pygame from pygame.sprite import Sprite class Alien(Sprite): ''' Uma classe que representa um único alienígena da frota. ''' def __init__(self, ai_settings, screen): ''' Inicializa o alienígina e define sua posição inicial. ''' super(Alien, self).__init__() self.screen = screen...
0
0
0
184b6e18c7619d5d8cdf1909db71b36517c8fdc2
571
py
Python
benchmark/tb_linear_chain.py
guruofquality/gras
a93956bfc9884f9a1c53a16e12cd7e7cd86584c4
[ "BSL-1.0" ]
9
2015-07-24T15:10:14.000Z
2021-11-08T13:18:20.000Z
benchmark/tb_linear_chain.py
guruofquality/gras
a93956bfc9884f9a1c53a16e12cd7e7cd86584c4
[ "BSL-1.0" ]
3
2015-02-02T01:57:26.000Z
2018-07-20T04:52:09.000Z
benchmark/tb_linear_chain.py
guruofquality/gras
a93956bfc9884f9a1c53a16e12cd7e7cd86584c4
[ "BSL-1.0" ]
4
2015-01-12T23:12:49.000Z
2021-09-23T18:10:58.000Z
import gnuradio from gnuradio import gr from gnuradio import blocks as grblocks import sys if __name__ == '__main__': duration = float(sys.argv[1]) tb = gr.top_block() src = gr.null_source(8) b0 = gr.copy(8) b1 = grblocks.sub_cc() b2 = gr.copy(8) b3 = grblocks.divide_cc() b4 = gr.copy...
20.392857
52
0.619965
import gnuradio from gnuradio import gr from gnuradio import blocks as grblocks import sys if __name__ == '__main__': duration = float(sys.argv[1]) tb = gr.top_block() src = gr.null_source(8) b0 = gr.copy(8) b1 = grblocks.sub_cc() b2 = gr.copy(8) b3 = grblocks.divide_cc() b4 = gr.copy...
0
0
0
10eab0a565930352eafed638e81638e8029a8126
63
py
Python
eventlet/green/OpenSSL/__init__.py
CaesarLinsa/Eventlet
43e832b441977f0344a56d22b267dca443333960
[ "MIT" ]
19
2015-05-01T19:59:03.000Z
2021-12-09T08:03:16.000Z
eventlet/green/OpenSSL/__init__.py
CaesarLinsa/Eventlet
43e832b441977f0344a56d22b267dca443333960
[ "MIT" ]
1
2018-01-03T15:26:49.000Z
2018-01-03T15:26:49.000Z
eventlet/green/OpenSSL/__init__.py
CaesarLinsa/Eventlet
43e832b441977f0344a56d22b267dca443333960
[ "MIT" ]
30
2015-03-25T19:40:07.000Z
2021-05-28T22:59:26.000Z
import rand, crypto, SSL, tsafe from version import __version__
31.5
31
0.825397
import rand, crypto, SSL, tsafe from version import __version__
0
0
0
4c0a77098527709a5f1e338dc49d1a2099b3bab5
436
py
Python
itez/beneficiary/migrations/0009_auto_20211105_1231.py
sonlinux/itez
0982c19763207e211e06b4e50a5a955f3de1693e
[ "MIT" ]
null
null
null
itez/beneficiary/migrations/0009_auto_20211105_1231.py
sonlinux/itez
0982c19763207e211e06b4e50a5a955f3de1693e
[ "MIT" ]
null
null
null
itez/beneficiary/migrations/0009_auto_20211105_1231.py
sonlinux/itez
0982c19763207e211e06b4e50a5a955f3de1693e
[ "MIT" ]
null
null
null
# Generated by Django 3.1.13 on 2021-11-05 12:31 from django.db import migrations, models
22.947368
95
0.619266
# Generated by Django 3.1.13 on 2021-11-05 12:31 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('beneficiary', '0008_agentdetail'), ] operations = [ migrations.AlterField( model_name='agentdetail', name='agend_ID...
0
321
23
cc6eee492f020d5c04011b6db5794e7cb7b2dc9a
1,970
py
Python
configs/lemon-modules/config/config/modules/weather/weather.py
tiborsimon/dotfiles-osx
35bbc9a25419229ee607b2f79ec72c2b827be53a
[ "MIT" ]
6
2016-05-11T07:35:25.000Z
2019-06-10T09:29:16.000Z
configs/lemon-modules/config/config/modules/weather/weather.py
tiborsimon/dotfiles-osx
35bbc9a25419229ee607b2f79ec72c2b827be53a
[ "MIT" ]
null
null
null
configs/lemon-modules/config/config/modules/weather/weather.py
tiborsimon/dotfiles-osx
35bbc9a25419229ee607b2f79ec72c2b827be53a
[ "MIT" ]
1
2020-01-22T10:10:06.000Z
2020-01-22T10:10:06.000Z
import os import sys import time from datetime import datetime import requests ICONS = { "01d": "", # clear sky "02d": "", # few clouds "03d": "", # scattered clouds "04d": "", # broken clouds "09d": "", # shower rain "10d": "", # rain "11d": "", # thunderstorm "13d": ""...
22.906977
70
0.556345
import os import sys import time from datetime import datetime import requests ICONS = { "01d": "", # clear sky "02d": "", # few clouds "03d": "", # scattered clouds "04d": "", # broken clouds "09d": "", # shower rain "10d": "", # rain "11d": "", # thunderstorm "13d": ""...
795
0
46
f8206078ea13634f1bdd0b1944a1691a8e75173e
2,506
py
Python
step4/AlexNetCompleted.py
Lintianqianjin/reappearance-of-some-classical-CNNs
f7f7556b581066f49ea4edb2db6c8f886c189c82
[ "Apache-2.0" ]
6
2019-07-02T07:25:14.000Z
2021-05-15T06:49:18.000Z
step4/AlexNetCompleted.py
Lintianqianjin/reappearance-of-some-classical-CNNs
f7f7556b581066f49ea4edb2db6c8f886c189c82
[ "Apache-2.0" ]
null
null
null
step4/AlexNetCompleted.py
Lintianqianjin/reappearance-of-some-classical-CNNs
f7f7556b581066f49ea4edb2db6c8f886c189c82
[ "Apache-2.0" ]
null
null
null
import tensorflow as tf import os # os.environ["TF_CPP_MIN_LOG_LEVEL"]='3' #----以下是答案部分 begin----# # 定义placeholder 开始 keeProb = tf.placeholder(tf.float32, shape=()) batchImgInput = tf.placeholder(tf.float32, shape=(None, 224, 224, 3)) labels = tf.placeholder(tf.float32, shape=(None, 4)) # 第一层卷积+归一化+池化 开始 conv1 = tf.l...
36.852941
115
0.715483
import tensorflow as tf import os # os.environ["TF_CPP_MIN_LOG_LEVEL"]='3' #----以下是答案部分 begin----# # 定义placeholder 开始 keeProb = tf.placeholder(tf.float32, shape=()) batchImgInput = tf.placeholder(tf.float32, shape=(None, 224, 224, 3)) labels = tf.placeholder(tf.float32, shape=(None, 4)) # 第一层卷积+归一化+池化 开始 conv1 = tf.l...
0
0
0