hexsha
stringlengths
40
40
size
int64
6
1.04M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
247
max_stars_repo_name
stringlengths
4
130
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
368k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
247
max_issues_repo_name
stringlengths
4
130
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
116k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
247
max_forks_repo_name
stringlengths
4
130
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
1
1.04M
avg_line_length
float64
1.53
618k
max_line_length
int64
1
1.02M
alphanum_fraction
float64
0
1
original_content
stringlengths
6
1.04M
filtered:remove_non_ascii
int64
0
538k
filtered:remove_decorators
int64
0
917k
filtered:remove_async
int64
0
722k
filtered:remove_classes
int64
-45
1M
filtered:remove_generators
int64
0
814k
filtered:remove_function_no_docstring
int64
-102
850k
filtered:remove_class_no_docstring
int64
-3
5.46k
filtered:remove_unused_imports
int64
-1,350
52.4k
filtered:remove_delete_markers
int64
0
59.6k
76d56251ad43eae7317b80963b63d36463f6e5d2
5,977
py
Python
populate_10_day_data.py
willBear/Insider_Monitor
14eac71a9769ed95f7c8500fd4c6b9dfbf7ca88e
[ "MIT" ]
null
null
null
populate_10_day_data.py
willBear/Insider_Monitor
14eac71a9769ed95f7c8500fd4c6b9dfbf7ca88e
[ "MIT" ]
null
null
null
populate_10_day_data.py
willBear/Insider_Monitor
14eac71a9769ed95f7c8500fd4c6b9dfbf7ca88e
[ "MIT" ]
null
null
null
from datetime import datetime insider_trades = [] trading_activity = {'B': 'Buy', 'S': 'Sell', 'O': 'Options Excersise'} def parse_row_info(trades, trade_type): """ :param trades: Contains usually 7 indexes, which are: Ticker, Company Information, Person Filling & Position, Buy/Sell or Options Excers...
34.75
116
0.628074
from bs4 import BeautifulSoup from datetime import datetime import time import requests from init_database_postgre import load_db_credential_info from real_time_web_scraper import update_insider_trades, write_to_csv insider_trades = [] trading_activity = {'B': 'Buy', 'S': 'Sell', 'O': 'Options Excersise'} def parse_...
0
0
0
0
0
2,710
0
76
133
b0e8a8b9b6e76ec472f1b2d6bee4fe9b13ed9f73
1,989
py
Python
pmaf/__init__.py
mmtechslv/PhyloMAF
bab43dd4a4d2812951b1fdf4f1abb83edb79ea88
[ "BSD-3-Clause" ]
1
2021-07-02T06:24:17.000Z
2021-07-02T06:24:17.000Z
pmaf/__init__.py
mmtechslv/PhyloMAF
bab43dd4a4d2812951b1fdf4f1abb83edb79ea88
[ "BSD-3-Clause" ]
1
2021-06-28T12:02:46.000Z
2021-06-28T12:02:46.000Z
pmaf/__init__.py
mmtechslv/PhyloMAF
bab43dd4a4d2812951b1fdf4f1abb83edb79ea88
[ "BSD-3-Clause" ]
null
null
null
r""" PhyloMAF (:mod:`pmaf`) ======================= .. rubric:: Phylogenetic Microbiome Analysis Framework .. currentmodule:: pmaf PhyloMAF is a novel comprehensive microbiome data analysis tool based on Python programming language. With memory efficient and extensible design, PhyloMAF have wide range of applicatio...
26.52
93
0.759175
r""" PhyloMAF (:mod:`pmaf`) ======================= .. rubric:: Phylogenetic Microbiome Analysis Framework .. currentmodule:: pmaf PhyloMAF is a novel comprehensive microbiome data analysis tool based on Python programming language. With memory efficient and extensible design, PhyloMAF have wide range of applicatio...
0
0
0
0
0
0
0
0
0
c64732ce1acdb5bd8b363d200430396748a5ed2c
988
py
Python
app/megatron/tests/slack_connection_test.py
team-labs/megatron
24376a0173d654ef5bddb5c6ea3e763697a929bf
[ "MIT" ]
4
2019-03-21T12:22:07.000Z
2019-07-08T09:36:41.000Z
app/megatron/tests/slack_connection_test.py
team-labs/megatron
24376a0173d654ef5bddb5c6ea3e763697a929bf
[ "MIT" ]
17
2019-03-29T14:40:40.000Z
2022-01-05T12:46:05.000Z
app/megatron/tests/slack_connection_test.py
team-labs/megatron
24376a0173d654ef5bddb5c6ea3e763697a929bf
[ "MIT" ]
3
2019-04-09T16:45:57.000Z
2020-01-26T18:19:27.000Z
import pytest pytestmark = pytest.mark.django_db
32.933333
66
0.803644
import pytest from unittest.mock import MagicMock from megatron.connections import slack from megatron.tests.factories import factories pytestmark = pytest.mark.django_db def test_get_user_info(): workspace = factories.CustomerWorkspaceFactory() connection = slack.SlackConnection(workspace.connection_token)...
0
450
0
0
0
317
0
56
112
d07e9124fa7e0398e4d8d828555166b929492a62
3,878
py
Python
src/demos/python/irrlicht/demo_IRR_visualize_collision.py
lucasw/chrono
e79d8c761c718ecb4c796725cff37026f357da8c
[ "BSD-3-Clause" ]
null
null
null
src/demos/python/irrlicht/demo_IRR_visualize_collision.py
lucasw/chrono
e79d8c761c718ecb4c796725cff37026f357da8c
[ "BSD-3-Clause" ]
null
null
null
src/demos/python/irrlicht/demo_IRR_visualize_collision.py
lucasw/chrono
e79d8c761c718ecb4c796725cff37026f357da8c
[ "BSD-3-Clause" ]
null
null
null
# ============================================================================= # PROJECT CHRONO - http://projectchrono.org # # Copyright (c) 2022 projectchrono.org # All rights reserved. # # Use of this source code is governed by a BSD-style license that can be found # in the LICENSE file at the top level of the distr...
36.242991
107
0.636668
# ============================================================================= # PROJECT CHRONO - http://projectchrono.org # # Copyright (c) 2022 projectchrono.org # All rights reserved. # # Use of this source code is governed by a BSD-style license that can be found # in the LICENSE file at the top level of the distr...
0
0
0
208
0
0
0
0
22
cd06d5bedfc6f1dcb68298520f00db8f4bd05de9
3,260
py
Python
AboutWindow.py
tirtharajghosh/Subtitle-Downloader
50f2eac6d960d2f5cd2769e3a327579abb62ecb5
[ "MIT" ]
null
null
null
AboutWindow.py
tirtharajghosh/Subtitle-Downloader
50f2eac6d960d2f5cd2769e3a327579abb62ecb5
[ "MIT" ]
null
null
null
AboutWindow.py
tirtharajghosh/Subtitle-Downloader
50f2eac6d960d2f5cd2769e3a327579abb62ecb5
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'about.ui' # # Created by: PyQt5 UI code generator 5.14.1 # # WARNING! All changes made in this file will be lost!
67.916667
330
0.692025
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'about.ui' # # Created by: PyQt5 UI code generator 5.14.1 # # WARNING! All changes made in this file will be lost! from PyQt5 import QtCore, QtGui, QtWidgets class About(object): def setupUi(self, Dialog): Dialog.setObjectName...
2
0
0
2,997
0
0
0
21
46
5afb623dd4f4042147e31b2180ef2c02ab6f2fc7
885
py
Python
main.py
pjkostrzewski/kanonierzy
9b5cc95d5a6ddcb7fc647b16373f54f9c0bca21d
[ "MIT" ]
null
null
null
main.py
pjkostrzewski/kanonierzy
9b5cc95d5a6ddcb7fc647b16373f54f9c0bca21d
[ "MIT" ]
null
null
null
main.py
pjkostrzewski/kanonierzy
9b5cc95d5a6ddcb7fc647b16373f54f9c0bca21d
[ "MIT" ]
null
null
null
FILENAME = "results.json" if __name__ == '__main__': articles = get_articles_from_website() save_articles(articles)
28.548387
101
0.764972
from scrap.kanonierzy_scraper import KanonierzyScraper from adapters.article_adapter import ArticleAdapter from page.article import Article from engine.chrome_browser import BrowserChrome from adapters.file_adapter import FileAdapter FILENAME = "results.json" def get_articles_from_website(): browser = BrowserC...
0
0
0
0
0
474
0
124
157
8384dd5ded0186242d11810a5ae349eeec80f730
5,896
py
Python
dataset/shapenet.py
hirotong/NeuralFusion
b83145c79df03857de7e32a2c46302c77635ff98
[ "MIT" ]
1
2021-09-25T08:19:42.000Z
2021-09-25T08:19:42.000Z
dataset/shapenet.py
hirotong/NeuralFusion
b83145c79df03857de7e32a2c46302c77635ff98
[ "MIT" ]
null
null
null
dataset/shapenet.py
hirotong/NeuralFusion
b83145c79df03857de7e32a2c46302c77635ff98
[ "MIT" ]
null
null
null
''' Author: Jinguang Tong Affliction: Australia National University, DATA61 CSIRO ''' if __name__ == '__main__': from utils.loading import load_config_from_yaml config = load_config_from_yaml('configs/fusion/shapenet.noise.005.without.routing.yaml') config.DATA.scene_list = config.DATA.train_sc...
31.195767
114
0.614315
''' Author: Jinguang Tong Affliction: Australia National University, DATA61 CSIRO ''' import os import glob import numpy as np from skimage import io from copy import copy from graphics import Voxelgrid from scipy.ndimage.morphology import binary_dilation from torch.utils.data import Dataset from utils.data import ad...
0
38
0
5,074
0
0
0
108
245
d7c34b5cce6b5d68fdee32163b306249e4c320e0
2,470
py
Python
dataLoader.py
deekshacsg/self_driving_car_dc
36fb643026a6c0e222380a89f0874ca325e55fb5
[ "MIT" ]
null
null
null
dataLoader.py
deekshacsg/self_driving_car_dc
36fb643026a6c0e222380a89f0874ca325e55fb5
[ "MIT" ]
null
null
null
dataLoader.py
deekshacsg/self_driving_car_dc
36fb643026a6c0e222380a89f0874ca325e55fb5
[ "MIT" ]
null
null
null
import os import json import pickle import numpy as np from PIL import Image feature_container_name = 'feature' angle_container_name = 'angle' def load_data(img_size, isSwiftEnabled): """ Create pickle objects of features and labels :param img_size: the new size of the re-sized image :param isSwift...
30.493827
97
0.608502
import os import json import pickle import numpy as np from PIL import Image from collections import defaultdict import swiftclient feature_container_name = 'feature' angle_container_name = 'angle' def get_connection(name, key): conn = swiftclient.Connection( user=name, key=key, authurl='...
0
0
0
0
0
238
0
11
90
17e0d16c450ac6b9ea1068936422fbddc9f95db2
92
py
Python
presalytics/lib/plugins/__init__.py
presalytics/python-client
5d80b78562126feeeb49af4738e2c1aed12dce3a
[ "MIT" ]
4
2020-02-21T16:30:46.000Z
2021-01-12T12:22:03.000Z
presalytics/lib/plugins/__init__.py
presalytics/python-client
5d80b78562126feeeb49af4738e2c1aed12dce3a
[ "MIT" ]
4
2019-12-28T19:30:08.000Z
2020-03-31T19:27:45.000Z
presalytics/lib/plugins/__init__.py
presalytics/python-client
5d80b78562126feeeb49af4738e2c1aed12dce3a
[ "MIT" ]
null
null
null
""" Library folder for plugins configured from `presalytics.story.outline.Plugin` class """
23
83
0.771739
""" Library folder for plugins configured from `presalytics.story.outline.Plugin` class """
0
0
0
0
0
0
0
0
0
4ce237325f75cd18007718e718200915fa2bda4b
1,264
py
Python
ikaros/0003-longest-substring-without-repeating-characters/longest_substring.py
MerleLiuKun/GoGoGo
2387d365bf86e53c0866ff03583c375ce0b5deb7
[ "MIT" ]
4
2020-01-05T07:24:27.000Z
2020-09-22T00:44:25.000Z
ikaros/0003-longest-substring-without-repeating-characters/longest_substring.py
MerleLiuKun/GoGoGo
2387d365bf86e53c0866ff03583c375ce0b5deb7
[ "MIT" ]
null
null
null
ikaros/0003-longest-substring-without-repeating-characters/longest_substring.py
MerleLiuKun/GoGoGo
2387d365bf86e53c0866ff03583c375ce0b5deb7
[ "MIT" ]
2
2020-01-06T09:32:35.000Z
2020-09-22T00:44:36.000Z
if __name__ == "__main__": sr = "pwwkew" so = Solution() print(so.method2(sr))
22.981818
57
0.438291
class Solution: def method1(self, s: str) -> int: max_length = 0 cur_length = 0 r = [] for val in s: if val not in r: cur_length += 1 max_length = max(max_length, cur_length) r.append(val) else: ...
0
0
0
1,148
0
0
0
0
22
a14d84380d3b8f620573bdadf4a2f56bfbdccdb3
1,151
py
Python
jobs/read_noise/v0/producer_read_noise.py
lsst-camera-dh/ts3-analysis
bf3400f286876c5ed4368e2dafe730a8598d0bf7
[ "BSD-3-Clause-LBNL" ]
null
null
null
jobs/read_noise/v0/producer_read_noise.py
lsst-camera-dh/ts3-analysis
bf3400f286876c5ed4368e2dafe730a8598d0bf7
[ "BSD-3-Clause-LBNL" ]
null
null
null
jobs/read_noise/v0/producer_read_noise.py
lsst-camera-dh/ts3-analysis
bf3400f286876c5ed4368e2dafe730a8598d0bf7
[ "BSD-3-Clause-LBNL" ]
null
null
null
#!/usr/bin/env python import os import sys import shutil import pyfits import lsst.eotest.image_utils as imutils import lsst.eotest.sensor as sensorTest from lcatr.harness.helpers import dependency_glob bias_files = dependency_glob('*_fe55_bias_*.fits', jobname='ts3_fe55_data') system_noise_files = dependency_glob('no...
33.852941
80
0.76629
#!/usr/bin/env python import os import sys import shutil import pyfits import lsst.eotest.image_utils as imutils import lsst.eotest.sensor as sensorTest from lcatr.harness.helpers import dependency_glob bias_files = dependency_glob('*_fe55_bias_*.fits', jobname='ts3_fe55_data') system_noise_files = dependency_glob('no...
0
0
0
0
0
0
0
0
0
e693962e57ac3a4f3ad2e9e6be752f290d8e1b6a
32,913
py
Python
.venv/lib/python3.8/site-packages/pandas/tests/groupby/test_function.py
acrucetta/Chicago_COVI_WebApp
a37c9f492a20dcd625f8647067394617988de913
[ "MIT", "Unlicense" ]
115
2020-06-18T15:00:58.000Z
2022-03-02T10:13:19.000Z
.venv/lib/python3.8/site-packages/pandas/tests/groupby/test_function.py
acrucetta/Chicago_COVI_WebApp
a37c9f492a20dcd625f8647067394617988de913
[ "MIT", "Unlicense" ]
37
2020-10-20T08:30:53.000Z
2020-12-22T13:15:45.000Z
.venv/lib/python3.8/site-packages/pandas/tests/groupby/test_function.py
acrucetta/Chicago_COVI_WebApp
a37c9f492a20dcd625f8647067394617988de913
[ "MIT", "Unlicense" ]
60
2020-07-22T14:53:10.000Z
2022-03-23T10:17:59.000Z
import pandas.core.nanops as nanops # @pytest.mark.parametrize("f", [max, min, sum]) # def test_builtins_apply(f): # describe # --------------------------------
31.286122
88
0.568286
import builtins from io import StringIO import numpy as np import pytest from pandas.errors import UnsupportedFunctionCall import pandas as pd from pandas import DataFrame, Index, MultiIndex, Series, Timestamp, date_range, isna import pandas._testing as tm import pandas.core.nanops as nanops from pandas.util import ...
0
9,748
0
0
0
21,757
0
106
1,098
1b4d91fd688cefd8353cdc6165ee82de3e239164
3,032
py
Python
CoREATAC_PredictionTool.py
UcarLab/CoRE-ATAC
0a6f4c380d9ad0c542aa01368855ba9ebcd4246b
[ "MIT" ]
7
2020-02-20T18:55:09.000Z
2022-01-06T21:38:38.000Z
CoREATAC_PredictionTool.py
UcarLab/CoRE-ATAC
0a6f4c380d9ad0c542aa01368855ba9ebcd4246b
[ "MIT" ]
4
2021-07-30T13:23:30.000Z
2022-03-02T14:41:52.000Z
CoREATAC_PredictionTool.py
UcarLab/CoRE-ATAC
0a6f4c380d9ad0c542aa01368855ba9ebcd4246b
[ "MIT" ]
null
null
null
from __future__ import print_function import argparse #Step 0: Process arguments parser = argparse.ArgumentParser(description='CoRE-ATAC Prediction Tool') parser.add_argument("datadirectory") parser.add_argument("basename") parser.add_argument("model") parser.add_argument("outputfile") parser.add_argument('--pf', de...
36.53012
133
0.742744
from __future__ import print_function import tensorflow as tf import keras from tensorflow.keras.models import load_model from keras import backend as K from keras.layers import Input import numpy as np import subprocess from tensorloader import TensorLoader as tl import matplotlib.pyplot as plt from matplotlib.backend...
0
0
0
0
0
1,547
0
188
375
014facf593970e594a62a84d02b0c51102ebfd0a
8,303
py
Python
examples/characterization/wigner-tomography/configuration.py
qua-platform/qua-libs
805a3b1a69980b939b370b3ba09434bc26dc45ec
[ "BSD-3-Clause" ]
21
2021-05-21T08:23:34.000Z
2022-03-25T11:30:55.000Z
examples/characterization/wigner-tomography/configuration.py
qua-platform/qua-libs
805a3b1a69980b939b370b3ba09434bc26dc45ec
[ "BSD-3-Clause" ]
9
2021-05-13T19:56:00.000Z
2021-12-21T05:11:04.000Z
examples/characterization/wigner-tomography/configuration.py
qua-platform/qua-libs
805a3b1a69980b939b370b3ba09434bc26dc45ec
[ "BSD-3-Clause" ]
2
2021-06-21T10:56:40.000Z
2021-12-19T14:21:33.000Z
import numpy as np ############################# # simulation helpers # ############################# lo_freq_cavity = 8.0e9 cavity_IF = 180e6 lo_freq_qubit = 7.4e9 qubit_IF = 60e6 lo_freq_rr = 9.3e9 rr_IF = 60e6 readout_len = 380 IF_freq = rr_IF Td = 200 Ts = readout_len - Td power = 0.2 c...
29.759857
89
0.427797
import numpy as np import matplotlib.pyplot as plt ############################# # simulation helpers # ############################# def gauss(amplitude, mu, sigma, length): t = np.linspace(-length / 2, length / 2, length) gauss_wave = amplitude * np.exp(-((t - mu) ** 2) / (2 * sigma ** 2)) ...
0
0
0
0
0
853
0
10
73
0b15d56cbaad2a4b854cb25da85ed580da2ed79c
3,994
py
Python
litex/build/efinix/dbparser.py
navan93/litex
2886fe170160d8481b77a53c11132d881b7bfa48
[ "ADSL" ]
1,501
2016-04-19T18:16:21.000Z
2022-03-31T17:46:31.000Z
litex/build/efinix/dbparser.py
enjoy-digital/litex
8fa4de5ede281f599879c6b1b2cd87b74ac67240
[ "ADSL" ]
1,135
2016-04-19T05:49:14.000Z
2022-03-31T15:21:19.000Z
litex/build/efinix/dbparser.py
navan93/litex
2886fe170160d8481b77a53c11132d881b7bfa48
[ "ADSL" ]
357
2016-04-19T05:00:24.000Z
2022-03-31T11:28:32.000Z
# # This file is part of LiteX. # # Copyright (c) 2021 Franck Jullien <franck.jullien@collshade.fr> # SPDX-License-Identifier: BSD-2-Clause # NameSpaces --------------------------------------------------------------------------------------- namespaces = { 'efxpt' : "http://www.efinixinc.com/peri_device_db", '...
31.698413
100
0.551077
# # This file is part of LiteX. # # Copyright (c) 2021 Franck Jullien <franck.jullien@collshade.fr> # SPDX-License-Identifier: BSD-2-Clause import os import csv import re import xml.etree.ElementTree as et # NameSpaces --------------------------------------------------------------------------------------- namespace...
0
0
0
3,436
0
0
0
-22
113
34116009d828dd230bd4ece7f92d1e2518654b63
4,717
py
Python
app/shared_code/imap_sync.py
KubaTaba1uga/spam_recycler
76056635fdf610c6304e8034a3f66f235761ca76
[ "MIT" ]
2
2021-12-17T18:12:51.000Z
2021-12-17T18:12:52.000Z
app/shared_code/imap_sync.py
KubaTaba1uga/spam_recycler
76056635fdf610c6304e8034a3f66f235761ca76
[ "MIT" ]
null
null
null
app/shared_code/imap_sync.py
KubaTaba1uga/spam_recycler
76056635fdf610c6304e8034a3f66f235761ca76
[ "MIT" ]
null
null
null
from imap_tools.errors import MailboxFolderSelectError from imap_tools import MailBox, AND import logging import datetime def validate_credentials(email_address, server_address, password): """Validate IMAP credentials. If IMAP validation succeed return True Args: URL (str): [address ...
27.747059
129
0.632817
from imap_tools.errors import MailboxFolderSelectError from imap_tools import MailBox, AND import logging import datetime def validate_credentials(email_address, server_address, password): """Validate IMAP credentials. If IMAP validation succeed return True Args: URL (str): [address ...
0
432
0
0
0
586
0
0
141
6a306b67e04bd9ee4518bc5dd6e295cbacb63b7c
321
py
Python
aoclib/edge.py
BrendanLeber/aoclib
67c6939cf045f812855339f496db55eb441cfe7f
[ "MIT" ]
null
null
null
aoclib/edge.py
BrendanLeber/aoclib
67c6939cf045f812855339f496db55eb441cfe7f
[ "MIT" ]
null
null
null
aoclib/edge.py
BrendanLeber/aoclib
67c6939cf045f812855339f496db55eb441cfe7f
[ "MIT" ]
1
2019-03-21T16:21:03.000Z
2019-03-21T16:21:03.000Z
# -*- coding: utf-8 -*- from __future__ import annotations
17.833333
38
0.604361
# -*- coding: utf-8 -*- from __future__ import annotations from dataclasses import dataclass @dataclass class Edge: u: int # the "from" vertex v: int # the "to" vertex def __str__(self) -> str: return f"{self.u} -> {self.v}" def reversed(self) -> Edge: return Edge(self.v, self.u)...
0
202
0
0
0
0
0
12
46
cb875a5067dc949e30897b549f24e12ff78ddb3c
218
py
Python
src/fractal/world/_realizing/_op/flowing.py
jedhsu/fractal
97833ddc5063fae72352cf590738fef508c02f0c
[ "MIT" ]
null
null
null
src/fractal/world/_realizing/_op/flowing.py
jedhsu/fractal
97833ddc5063fae72352cf590738fef508c02f0c
[ "MIT" ]
null
null
null
src/fractal/world/_realizing/_op/flowing.py
jedhsu/fractal
97833ddc5063fae72352cf590738fef508c02f0c
[ "MIT" ]
null
null
null
""" Flow ==== Time-related operations for a realizing world. """
10.9
46
0.623853
""" Flow ==== Time-related operations for a realizing world. """ from ..realizing import Realizing class Flowing( Realizing, ): def at_dawn(self): pass def has_world_ended(self): pass
0
0
0
92
0
0
0
12
46
cdec793af3e3d4f747ac579ba41367a9a96a9dcd
3,312
py
Python
tests/test_option_binding.py
clidoc/clidoc.python
cbc2717aa3ba6cd279c8106784bc711febbef29c
[ "MIT" ]
null
null
null
tests/test_option_binding.py
clidoc/clidoc.python
cbc2717aa3ba6cd279c8106784bc711febbef29c
[ "MIT" ]
3
2015-05-10T06:45:37.000Z
2015-05-15T08:26:14.000Z
tests/test_option_binding.py
clidoc/clidoc.python
cbc2717aa3ba6cd279c8106784bc711febbef29c
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from __future__ import (division, absolute_import, print_function, unicode_literals) from utils import generate_key_checker key_checker = generate_key_checker( { "-c", "--long-4", "command", }, { "-a", "-b", "-...
21.647059
66
0.513587
# -*- coding: utf-8 -*- from __future__ import (division, absolute_import, print_function, unicode_literals) from clidoc_option_binding import * from utils import generate_key_checker, CLIDOC_TEST_MODE key_checker = generate_key_checker( { "-c", "--long-4", "comman...
0
0
0
0
0
2,605
0
32
230
4034a523b36517e6a0bdf04a9888a83e2ea95364
252
py
Python
pyuri/__init__.py
nick-allen/python-uri
a526316270b83cd76651baec016d1509aab68981
[ "MIT" ]
1
2016-07-29T01:29:04.000Z
2016-07-29T01:29:04.000Z
pyuri/__init__.py
nick-allen/pyuri
a526316270b83cd76651baec016d1509aab68981
[ "MIT" ]
1
2016-10-24T15:03:30.000Z
2016-11-01T18:01:52.000Z
pyuri/__init__.py
nick-allen/pyuri
a526316270b83cd76651baec016d1509aab68981
[ "MIT" ]
null
null
null
"""Python URI Handling""" from pkg_resources import get_distribution, DistributionNotFound from .uri import URI __all__ = ['URI'] try: __version__ = get_distribution(__name__).version except DistributionNotFound: __version__ = '0.0.0-dev'
18
64
0.753968
"""Python URI Handling""" from pkg_resources import get_distribution, DistributionNotFound from .uri import URI __all__ = ['URI'] try: __version__ = get_distribution(__name__).version except DistributionNotFound: __version__ = '0.0.0-dev'
0
0
0
0
0
0
0
0
0
404465605a931d46f6e31c6a291d217087149125
1,731
py
Python
guts/migration/driver.py
smallwormer/stable-liberty-guts
e635b710cdd210f70e9d50c3b85fffdeb53e8f01
[ "Apache-2.0" ]
null
null
null
guts/migration/driver.py
smallwormer/stable-liberty-guts
e635b710cdd210f70e9d50c3b85fffdeb53e8f01
[ "Apache-2.0" ]
null
null
null
guts/migration/driver.py
smallwormer/stable-liberty-guts
e635b710cdd210f70e9d50c3b85fffdeb53e8f01
[ "Apache-2.0" ]
null
null
null
# Copyright (c) 2015 Aptira Pty Ltd. # 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 requi...
33.288462
78
0.657423
# Copyright (c) 2015 Aptira Pty Ltd. # 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 requi...
0
0
0
1,047
0
0
0
2
46
8ac95dbd0a9032681d9dfaccf24e28f0495f5ae1
4,019
py
Python
base_config.py
zclonely/ACNet
1fa157c5b38be2ecfc4a79f8ebe8e7cb30c71561
[ "MIT" ]
2
2019-12-23T03:03:24.000Z
2019-12-23T03:03:26.000Z
base_config.py
zclonely/ACNet
1fa157c5b38be2ecfc4a79f8ebe8e7cb30c71561
[ "MIT" ]
null
null
null
base_config.py
zclonely/ACNet
1fa157c5b38be2ecfc4a79f8ebe8e7cb30c71561
[ "MIT" ]
null
null
null
from collections import namedtuple BaseConfigByEpoch = namedtuple('BaseConfigByEpoch', ['network_type', 'dataset_name', 'dataset_subset', 'global_batch_size', 'num_node', 'device', 'weight_decay', 'weight_decay_bias', 'optimizer_type', 'momentum', ...
83.729167
181
0.622294
from collections import namedtuple from model_map import get_dataset_name_by_model_name BaseConfigByEpoch = namedtuple('BaseConfigByEpoch', ['network_type', 'dataset_name', 'dataset_subset', 'global_batch_size', 'num_node', 'device', 'weight_decay', 'weight_decay_bias', 'opti...
0
0
0
0
0
2,959
0
31
72
52edcb7aea820f4031994c44df4c877102b60d05
385
py
Python
Chapter 4 - Lists & Tuples/01_list.py
alex-dsouza777/Python-Basics
8f1c406f2319cd65b5d54dfea990d09fa69d9adf
[ "MIT" ]
null
null
null
Chapter 4 - Lists & Tuples/01_list.py
alex-dsouza777/Python-Basics
8f1c406f2319cd65b5d54dfea990d09fa69d9adf
[ "MIT" ]
null
null
null
Chapter 4 - Lists & Tuples/01_list.py
alex-dsouza777/Python-Basics
8f1c406f2319cd65b5d54dfea990d09fa69d9adf
[ "MIT" ]
1
2021-04-21T10:23:08.000Z
2021-04-21T10:23:08.000Z
#Create a list using [] a = [1,2,3,7,66] #print the list using print() function print(a) #Access using index using a[0], a[1], .... print(a[2]) #Changing the value of the list a[0] = 777 print(a) #We can create a list with items of different type b = [77,"Root",False,6.9] print(b) #List Slicing friends = ["Root","...
16.73913
50
0.649351
#Create a list using [] a = [1,2,3,7,66] #print the list using print() function print(a) #Access using index using a[0], a[1], .... print(a[2]) #Changing the value of the list a[0] = 777 print(a) #We can create a list with items of different type b = [77,"Root",False,6.9] print(b) #List Slicing friends = ["Root","...
0
0
0
0
0
0
0
0
0
cbb881db08ca129cbba2949277f9b0b3fed4d340
138
py
Python
Data Scientist Career Path/3. Python Fundamentals/11. Python Files/6. with.py
myarist/Codecademy
2ba0f104bc67ab6ef0f8fb869aa12aa02f5f1efb
[ "MIT" ]
23
2021-06-06T15:35:55.000Z
2022-03-21T06:53:42.000Z
Data Scientist Career Path/3. Python Fundamentals/11. Python Files/6. with.py
shivaniverma1/Data-Scientist
f82939a411484311171465591455880c8e354750
[ "MIT" ]
null
null
null
Data Scientist Career Path/3. Python Fundamentals/11. Python Files/6. with.py
shivaniverma1/Data-Scientist
f82939a411484311171465591455880c8e354750
[ "MIT" ]
9
2021-06-08T01:32:04.000Z
2022-03-18T15:38:09.000Z
with open('fun_file.txt') as close_this_file: setup = close_this_file.readline() punchline = close_this_file.readline() print(setup)
23
45
0.768116
with open('fun_file.txt') as close_this_file: setup = close_this_file.readline() punchline = close_this_file.readline() print(setup)
0
0
0
0
0
0
0
0
0
feda459c8123407cf53096f28c805421e375f313
3,141
py
Python
guides/python/pysample/crypto/aes/aes_enc.py
ToraNova/library
20b321302868e8c2ce8723c808aa9e7a313e2cb8
[ "MIT" ]
null
null
null
guides/python/pysample/crypto/aes/aes_enc.py
ToraNova/library
20b321302868e8c2ce8723c808aa9e7a313e2cb8
[ "MIT" ]
null
null
null
guides/python/pysample/crypto/aes/aes_enc.py
ToraNova/library
20b321302868e8c2ce8723c808aa9e7a313e2cb8
[ "MIT" ]
null
null
null
#!/usr/bin/python3 # used to encrypt a byte string # used as a tool for testing # AES encryption from Crypto.Cipher import AES import base64 import os import sys if __name__ == "__main__": e_key = None plain = None allz = False AES_mode = AES.MODE_CBC #input parsing if(len(sys.argv) < 3): print("Please s...
29.083333
95
0.687042
#!/usr/bin/python3 # used to encrypt a byte string # used as a tool for testing # AES encryption from Crypto.Cipher import AES import base64 import os import sys import binascii def rawpad(s,BLOCK_SIZE): #pad it with the characters representing original block size length return s + (BLOCK_SIZE - len(s) % BL...
0
0
0
0
0
484
0
-6
114
6390b3c93147251c06317ddc9b994d40186364a9
424
py
Python
aoc2020/day9/day9_part2.py
GetPastTheMonkey/advent-of-code
db80be6d87baba4d5315cc69276905c55762da86
[ "MIT" ]
1
2019-09-15T16:37:24.000Z
2019-09-15T16:37:24.000Z
aoc2020/day9/day9_part2.py
GetPastTheMonkey/advent-of-code
db80be6d87baba4d5315cc69276905c55762da86
[ "MIT" ]
null
null
null
aoc2020/day9/day9_part2.py
GetPastTheMonkey/advent-of-code
db80be6d87baba4d5315cc69276905c55762da86
[ "MIT" ]
null
null
null
from utils import get_input_lines n = 20874512 sums = [] ints = [] solved = False for line in get_input_lines(__file__): i = int(line) sums.append(0) ints.append(i) for idx in range(len(sums)): sums[idx] = sums[idx] + i if sums[idx] == n: subset = ints[idx:] pri...
19.272727
44
0.540094
from utils import get_input_lines n = 20874512 sums = [] ints = [] solved = False for line in get_input_lines(__file__): i = int(line) sums.append(0) ints.append(i) for idx in range(len(sums)): sums[idx] = sums[idx] + i if sums[idx] == n: subset = ints[idx:] pri...
0
0
0
0
0
0
0
0
0
47f18ea67a40d6e9e4db44332a0499fd963249fe
579
py
Python
ch02/conditionals.py
skinisbizapps/learning-python
3c77fb94d978dd77057d1f0f4450d887dd389486
[ "Apache-2.0" ]
null
null
null
ch02/conditionals.py
skinisbizapps/learning-python
3c77fb94d978dd77057d1f0f4450d887dd389486
[ "Apache-2.0" ]
null
null
null
ch02/conditionals.py
skinisbizapps/learning-python
3c77fb94d978dd77057d1f0f4450d887dd389486
[ "Apache-2.0" ]
null
null
null
if __name__ == "__main__": main()
19.3
79
0.533679
def compare(x, y): st = "" if(x < y): st = "x is less than y" elif(x == y): st = "x is equal to y" else: st = "x is greater than y" return st def another_compare(x, y): st = "x is less than y" if(x < y) else "x is greater than or the same as y" return st def main...
0
0
0
0
0
470
0
0
69
4eaca5bc138f355d112c860003e0c72d36d9f501
2,412
py
Python
pyredditlive.py
nbr23/pyredditlive
c8ebccef8671201806682d2768a14e707e9814b5
[ "MIT" ]
null
null
null
pyredditlive.py
nbr23/pyredditlive
c8ebccef8671201806682d2768a14e707e9814b5
[ "MIT" ]
null
null
null
pyredditlive.py
nbr23/pyredditlive
c8ebccef8671201806682d2768a14e707e9814b5
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import sys if __name__ == "__main__": sys.exit(main())
30.15
180
0.609867
#!/usr/bin/env python3 import asyncio import websockets import requests import json import sys import os import yaml import urllib import time def load_config(config_path): config = {} if os.path.exists(config_path): with open(config_path) as configfile: config = yaml.load(configfile, Lo...
0
0
671
0
0
1,427
0
-67
292
cf8a7bb7e19ae6d2eb73dfe3eefc77adf2a57cf3
1,069
py
Python
pychecker/checker.py
PyVCEchecker/PyVCEchecker
879756927c82a2612c817bdffbae25234ff62558
[ "MIT" ]
null
null
null
pychecker/checker.py
PyVCEchecker/PyVCEchecker
879756927c82a2612c817bdffbae25234ff62558
[ "MIT" ]
null
null
null
pychecker/checker.py
PyVCEchecker/PyVCEchecker
879756927c82a2612c817bdffbae25234ff62558
[ "MIT" ]
null
null
null
import argparse parser = argparse.ArgumentParser( description="PyChecker: check whether your project's Require-Python is correct" ) package_group = parser.add_argument_group("package") package_group.add_argument("-p", "--package", help="Package name") package_group.add_argument("-v", "--version", help="Version o...
34.483871
88
0.724041
import argparse from pychecker.check import check_project, check_pkgver, print_results parser = argparse.ArgumentParser( description="PyChecker: check whether your project's Require-Python is correct" ) package_group = parser.add_argument_group("package") package_group.add_argument("-p", "--package", help="Packa...
0
0
0
0
0
419
0
49
45
4de13b8171f09853c55e978ef311746acd908c93
597
py
Python
setup.py
rohit18115/OQMscores-python
96cddadbd8eb2b12df72a216e6093e2f7d642531
[ "MIT" ]
null
null
null
setup.py
rohit18115/OQMscores-python
96cddadbd8eb2b12df72a216e6093e2f7d642531
[ "MIT" ]
null
null
null
setup.py
rohit18115/OQMscores-python
96cddadbd8eb2b12df72a216e6093e2f7d642531
[ "MIT" ]
null
null
null
from setuptools import setup with open("README.md", "r", encoding="utf-8") as fh: long_description = fh.read() setup(name='oqmscore', version='0.1', description='Objective quality measure score for speech', long_description=long_description, long_description_content_type="text/markdown", ...
27.136364
63
0.639866
from setuptools import setup with open("README.md", "r", encoding="utf-8") as fh: long_description = fh.read() setup(name='oqmscore', version='0.1', description='Objective quality measure score for speech', long_description=long_description, long_description_content_type="text/markdown", ...
0
0
0
0
0
0
0
0
0
444a8d70b910bb9557b6b49213f60ccdb90ea5bf
2,039
py
Python
core/etl/models/service.py
prorevizor/noc
37e44b8afc64318b10699c06a1138eee9e7d6a4e
[ "BSD-3-Clause" ]
84
2017-10-22T11:01:39.000Z
2022-02-27T03:43:48.000Z
core/etl/models/service.py
prorevizor/noc
37e44b8afc64318b10699c06a1138eee9e7d6a4e
[ "BSD-3-Clause" ]
22
2017-12-11T07:21:56.000Z
2021-09-23T02:53:50.000Z
core/etl/models/service.py
prorevizor/noc
37e44b8afc64318b10699c06a1138eee9e7d6a4e
[ "BSD-3-Clause" ]
23
2017-12-06T06:59:52.000Z
2022-02-24T00:02:25.000Z
# ---------------------------------------------------------------------- # ServiceModel # ---------------------------------------------------------------------- # Copyright (C) 2007-2020 The NOC Project # See LICENSE for details # ---------------------------------------------------------------------- # Python modules ...
26.828947
85
0.574301
# ---------------------------------------------------------------------- # ServiceModel # ---------------------------------------------------------------------- # Copyright (C) 2007-2020 The NOC Project # See LICENSE for details # ---------------------------------------------------------------------- # Python modules ...
0
0
0
1,439
0
0
0
87
177
b47ee23494a4382d2a0cc60f01cc0616a4774df2
1,955
py
Python
pubsub/animation/scanning-pixel.py
yanigisawa/coffee-scale
8131f5485646fa6b9803ca13b3e20d02d9debfce
[ "MIT" ]
13
2015-07-29T12:07:40.000Z
2018-06-29T13:21:41.000Z
pubsub/animation/scanning-pixel.py
yanigisawa/coffee-scale
8131f5485646fa6b9803ca13b3e20d02d9debfce
[ "MIT" ]
4
2015-05-29T11:44:43.000Z
2018-07-25T20:20:10.000Z
pubsub/animation/scanning-pixel.py
yanigisawa/coffee-scale
8131f5485646fa6b9803ca13b3e20d02d9debfce
[ "MIT" ]
7
2016-01-19T21:56:08.000Z
2018-04-25T04:34:32.000Z
#!/usr/bin/env python # Main function if __name__ == "__main__": simple_square = SimpleSquare() if (not simple_square.process()): simple_square.print_help()
34.910714
92
0.526854
#!/usr/bin/env python from samplebase import SampleBase class SimpleSquare(SampleBase): def __init__(self, *args, **kwargs): super(SimpleSquare, self).__init__(*args, **kwargs) def run(self): offset_canvas = self.matrix.CreateFrameCanvas() x, y = 0, 0 min_x, max_x = 0, offset_...
0
0
0
1,722
0
0
0
12
45
8142df55e374bc2702c74ff5c5b846221102fd7e
66,710
py
Python
statspark/r_inspired.py
joon3216/statspark
5c0c5b31694ed76bf43251eab8806bbf9f79a50e
[ "MIT" ]
null
null
null
statspark/r_inspired.py
joon3216/statspark
5c0c5b31694ed76bf43251eab8806bbf9f79a50e
[ "MIT" ]
null
null
null
statspark/r_inspired.py
joon3216/statspark
5c0c5b31694ed76bf43251eab8806bbf9f79a50e
[ "MIT" ]
null
null
null
from functools import reduce from patsy import dmatrices from scipy.optimize import curve_fit, fmin from scipy.stats import chi2 from sklearn.metrics import roc_curve from statsmodels.stats.outliers_influence import variance_inflation_factor import matplotlib.pyplot as plt import numpy as np import pandas as pd import...
36.553425
117
0.566272
from functools import reduce from patsy import dmatrices from scipy.optimize import curve_fit, fmin from scipy.stats import chi2 from sklearn.metrics import roc_curve from statsmodels.stats.outliers_influence import variance_inflation_factor import matplotlib.pyplot as plt import numpy as np import pandas as pd import...
0
0
0
6,778
0
478
0
0
162
d464ec8b2a69b1c7cc0adb6879fa792dc9074552
7,044
py
Python
wsserver.py
stanleykao72/Deepfake-Detection
417de0a0c7756397cf3a611b26008b7ed64727e9
[ "Apache-2.0" ]
1
2020-09-30T09:33:28.000Z
2020-09-30T09:33:28.000Z
wsserver.py
stanleykao72/Deepfake-Detection
417de0a0c7756397cf3a611b26008b7ed64727e9
[ "Apache-2.0" ]
null
null
null
wsserver.py
stanleykao72/Deepfake-Detection
417de0a0c7756397cf3a611b26008b7ed64727e9
[ "Apache-2.0" ]
null
null
null
import os from aiohttp import web import logging LOGGING_FORMAT = '%(asctime)s %(levelname)s: %(message)s' DATE_FORMAT = '%Y%m%d %H:%M:%S' logging.basicConfig(level=logging.INFO, format=LOGGING_FORMAT, datefmt=DATE_FORMAT) logger = logging.getLogger(__name__) WS_DOMAIN = os.getenv("WS_DOMAIN", "localhost") WS_HOST = ...
35.575758
167
0.642675
import asyncio import os import secrets import weakref import aiohttp.web from aiohttp import web import aioredis from aiohttp import WSCloseCode import json from detector_inference import detector_inference import logging LOGGING_FORMAT = '%(asctime)s %(levelname)s: %(message)s' DATE_FORMAT = '%Y%m%d %H:%M:%S' loggi...
369
1,691
3,686
0
0
511
0
-2
381
ad543e43ec057bc0f0a91c2c2ade3000ce81112d
1,267
py
Python
main.py
Davnit/capidaptor
9e03c263fed9555d5863114fd84deb195795d0e4
[ "MIT" ]
5
2018-10-06T10:00:43.000Z
2020-02-02T03:49:53.000Z
main.py
Davnit/capidaptor
9e03c263fed9555d5863114fd84deb195795d0e4
[ "MIT" ]
3
2018-10-01T11:43:00.000Z
2019-10-30T00:31:06.000Z
main.py
Davnit/capidaptor
9e03c263fed9555d5863114fd84deb195795d0e4
[ "MIT" ]
3
2018-10-01T06:57:58.000Z
2018-10-04T03:19:38.000Z
#!/usr/bin/env python3 from server import Server import argparse parser = argparse.ArgumentParser(prog='capidaptor') parser.add_argument('--interface', help='Specifies the interface and port to listen on') parser.add_argument('--debug', help='Enables debugging mode', action='store_true') parser.add_argument('--igno...
29.465116
111
0.729282
#!/usr/bin/env python3 from server import Server import argparse parser = argparse.ArgumentParser(prog='capidaptor') parser.add_argument('--interface', help='Specifies the interface and port to listen on') parser.add_argument('--debug', help='Enables debugging mode', action='store_true') parser.add_argument('--igno...
0
0
0
0
0
0
0
0
0
4e91758f971a4d37da7cfb22510a76d626e4c3c8
8,883
py
Python
tests/test_client.py
pasystem/pyqiwi
138ae75350ef50ed7643e3ab9ae4b8e6e7c81663
[ "MIT" ]
17
2016-10-28T11:25:54.000Z
2021-03-07T20:23:59.000Z
tests/test_client.py
pasystem/pyqiwi
138ae75350ef50ed7643e3ab9ae4b8e6e7c81663
[ "MIT" ]
1
2016-10-28T11:36:08.000Z
2016-10-31T16:40:16.000Z
tests/test_client.py
pasystem/pyqiwi
138ae75350ef50ed7643e3ab9ae4b8e6e7c81663
[ "MIT" ]
3
2017-02-06T15:49:00.000Z
2017-04-15T21:52:39.000Z
# coding: utf-8
32.184783
125
0.547675
# coding: utf-8 from datetime import datetime from decimal import Decimal from unittest import TestCase import httpretty from pyqiwi import QiwiError, Qiwi class QiwiErrorTestCase(TestCase): def test_error_code(self): error = QiwiError(143) self.assertEqual(error.code, 143) @httpretty.activate...
26
8,548
0
117
0
0
0
30
158
c47be3b1dc8ec4a07a8b95d594288ba031947a6e
7,895
py
Python
src/fastnn/processors/cv/object_detection.py
aychang95/fastnn
93f02b860845959a8c625f6c99267f103756318b
[ "MIT" ]
7
2020-12-03T07:04:47.000Z
2022-03-25T11:51:15.000Z
src/fastnn/processors/cv/object_detection.py
aychang95/fastnn
93f02b860845959a8c625f6c99267f103756318b
[ "MIT" ]
null
null
null
src/fastnn/processors/cv/object_detection.py
aychang95/fastnn
93f02b860845959a8c625f6c99267f103756318b
[ "MIT" ]
null
null
null
import logging logger = logging.getLogger(__name__)
36.892523
129
0.610133
import logging from typing import Optional, List, Union, Tuple, Callable import torch from torch.utils.data import DataLoader, Dataset from torchvision.transforms import ConvertImageDtype from PIL import Image, ImageDraw from PIL import ImageFont import numpy as np from fastnn.utils.cv import ImageDataset from f...
0
2,811
0
4,651
0
0
0
150
226
e762b4876e49dc54cb1de3681ceb2f8ccaffd784
2,170
py
Python
src/structs/linked_list.py
zelaznymarek/data_structures
e85e9b48a6fe9adace914d887568e692c4e2344b
[ "MIT" ]
null
null
null
src/structs/linked_list.py
zelaznymarek/data_structures
e85e9b48a6fe9adace914d887568e692c4e2344b
[ "MIT" ]
null
null
null
src/structs/linked_list.py
zelaznymarek/data_structures
e85e9b48a6fe9adace914d887568e692c4e2344b
[ "MIT" ]
null
null
null
linked_list = LinkedList() print(linked_list.size_of() == 0) linked_list.insert_at_start(10) linked_list.insert_at_start(13) linked_list.insert_at_end(15) linked_list.insert_at_end(27) print(linked_list.head.data == 13) print(linked_list.size_of() == 4) linked_list.remove(100) print(linked_list.size_of() == 4) li...
23.333333
59
0.628571
class Node: def __init__(self, data): self.data = data self.next_node = None class LinkedList: def __init__(self): self.head = None self.size = 0 def insert_at_start(self, data): new_node = Node(data) self.size += 1 if not self.head: se...
0
0
0
1,439
0
0
0
0
45
b37d8685d1dc9ffb644ec26eec8530c5ed0f4b5f
5,435
py
Python
dfa/dfa.py
ameesh-shah/dfa
00043c2c4e2762ef55f5c484e08eca7925cf0f65
[ "MIT" ]
null
null
null
dfa/dfa.py
ameesh-shah/dfa
00043c2c4e2762ef55f5c484e08eca7925cf0f65
[ "MIT" ]
null
null
null
dfa/dfa.py
ameesh-shah/dfa
00043c2c4e2762ef55f5c484e08eca7925cf0f65
[ "MIT" ]
null
null
null
from __future__ import annotations from typing import Hashable, FrozenSet State = Hashable Letter = Hashable Alphabet = FrozenSet[Letter]
32.939394
79
0.598344
from __future__ import annotations import operator from functools import wraps from typing import Hashable, FrozenSet, Callable, Optional, Sequence import attr import funcy as fn State = Hashable Letter = Hashable Alphabet = FrozenSet[Letter] def boolean_only(method): @wraps(method) def wrapped(self, *arg...
0
5,091
0
0
0
49
0
17
136
30c2f87795348253a7bc93585e22ecd969330ca7
1,775
py
Python
bot/exts/fun/ciphers.py
gurkult/gurkbot
fe42628eb01ce42539ad3a6781eb8810950b1402
[ "MIT" ]
24
2020-12-18T07:26:14.000Z
2022-03-30T22:56:49.000Z
bot/exts/fun/ciphers.py
gurkult/gurkbot
fe42628eb01ce42539ad3a6781eb8810950b1402
[ "MIT" ]
143
2020-12-18T09:13:51.000Z
2022-03-02T19:27:44.000Z
bot/exts/fun/ciphers.py
gurkult/gurkbot
fe42628eb01ce42539ad3a6781eb8810950b1402
[ "MIT" ]
44
2020-12-18T09:05:29.000Z
2022-03-02T20:06:23.000Z
import logging from bot.bot import Bot logger = logging.getLogger(__name__) def setup(bot: Bot) -> None: """Loading the Ciphers cog.""" bot.add_cog(Ciphers(bot))
29.098361
88
0.59493
import hashlib import logging from bot.bot import Bot from bot.constants import Colours from discord import Embed from discord.ext.commands import BadArgument, Cog, Context, group logger = logging.getLogger(__name__) class Ciphers(Cog): """Commands for working with ciphers, hashes and encryptions.""" def _...
3
1,248
0
187
0
0
0
53
111
2c8540dc90544d6a1d6cbfedfddc2ffd1d030ec1
234
py
Python
exercise4-3.py
raygomez/python-exercise-4
5f4fdb23767f1cc04dc133497b866dfa9feeb7f9
[ "MIT" ]
null
null
null
exercise4-3.py
raygomez/python-exercise-4
5f4fdb23767f1cc04dc133497b866dfa9feeb7f9
[ "MIT" ]
null
null
null
exercise4-3.py
raygomez/python-exercise-4
5f4fdb23767f1cc04dc133497b866dfa9feeb7f9
[ "MIT" ]
null
null
null
from __future__ import print_function __author__ = 'ragomez' number = int(raw_input('Enter a number:')) for num in f(number): print(num, end=',')
18
42
0.645299
from __future__ import print_function __author__ = 'ragomez' def f(data): mylist = xrange(0, data,2) for i in mylist: yield i number = int(raw_input('Enter a number:')) for num in f(number): print(num, end=',')
0
0
0
0
59
0
0
0
23
5d81ca03df78fb0cbc1864bcfafddccac859040d
8,661
py
Python
python/Power Bi.nuixscript/site-packages/adal/wstrust_request.py
Nuix/Power-BI-Integration
5204f51c497b4de4881a44ae9b1f421023d54842
[ "Apache-2.0" ]
1
2021-10-16T19:33:56.000Z
2021-10-16T19:33:56.000Z
python/Power Bi.nuixscript/site-packages/adal/wstrust_request.py
Nuix/Power-BI-Integration
5204f51c497b4de4881a44ae9b1f421023d54842
[ "Apache-2.0" ]
1
2021-04-30T20:41:19.000Z
2021-04-30T20:41:19.000Z
python/Power Bi.nuixscript/site-packages/adal/wstrust_request.py
Nuix/Power-BI-Integration
5204f51c497b4de4881a44ae9b1f421023d54842
[ "Apache-2.0" ]
1
2019-07-25T15:09:05.000Z
2019-07-25T15:09:05.000Z
#------------------------------------------------------------------------------ # # Copyright (c) Microsoft Corporation. # All rights reserved. # # This code is licensed under the MIT License. # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documenta...
50.947059
178
0.607436
#------------------------------------------------------------------------------ # # Copyright (c) Microsoft Corporation. # All rights reserved. # # This code is licensed under the MIT License. # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated document...
3
1,484
0
5,504
0
0
0
33
203
d5fe1334d39320c9da1b9c09dd4224c055897193
8,511
py
Python
utils.py
zikang12138/Learning-Action-Completeness-from-Points
0dcb2b70a218e975a96e269646912649d30759ba
[ "MIT" ]
52
2021-08-06T07:48:52.000Z
2022-03-30T01:53:08.000Z
utils.py
zikang12138/Learning-Action-Completeness-from-Points
0dcb2b70a218e975a96e269646912649d30759ba
[ "MIT" ]
7
2021-09-12T03:48:04.000Z
2022-03-24T08:44:30.000Z
utils.py
zikang12138/Learning-Action-Completeness-from-Points
0dcb2b70a218e975a96e269646912649d30759ba
[ "MIT" ]
10
2021-08-14T06:29:16.000Z
2022-03-06T14:58:56.000Z
import torch.nn as nn
33.507874
146
0.561039
import torch import torch.nn as nn import numpy as np from scipy.interpolate import interp1d import os import sys import random import config def upgrade_resolution(arr, scale): x = np.arange(0, arr.shape[0]) f = interp1d(x, arr, kind='linear', axis=0, fill_value='extrapolate') scale_x = np.arange(0, arr....
0
0
0
0
0
8,082
0
-34
430
2e8c1b0d110b26e611f1e48f251a997f89d7502b
11,020
py
Python
PYTHON/SelectSlice.py
Kate-Willett/Climate_Explorer
d49e65a6caa9beb1a859e16d3827022442bad324
[ "CC0-1.0" ]
null
null
null
PYTHON/SelectSlice.py
Kate-Willett/Climate_Explorer
d49e65a6caa9beb1a859e16d3827022442bad324
[ "CC0-1.0" ]
null
null
null
PYTHON/SelectSlice.py
Kate-Willett/Climate_Explorer
d49e65a6caa9beb1a859e16d3827022442bad324
[ "CC0-1.0" ]
1
2021-06-29T12:05:46.000Z
2021-06-29T12:05:46.000Z
#!/usr/local/sci/bin/python # PYTHON3 # # Author: Kate Willett # Created: 16 October 2015 # Last update: 20 July 2020 # Location: /data/local/hadkw/HADCRUH2/UPDATE2014/PROGS/PYTHON/ # GitHub: https://github.com/Kate-Willett/Climate_Explorer/tree/master/PYTHON/ # ----------------------- # CODE PURPOSE AND OUTPUT # ---...
47.705628
142
0.591379
#!/usr/local/sci/bin/python # PYTHON3 # # Author: Kate Willett # Created: 16 October 2015 # Last update: 20 July 2020 # Location: /data/local/hadkw/HADCRUH2/UPDATE2014/PROGS/PYTHON/ # GitHub: https://github.com/Kate-Willett/Climate_Explorer/tree/master/PYTHON/ # ----------------------- # CODE PURPOSE AND OUTPUT # ---...
0
0
0
0
0
0
0
-14
75
8bed170dd471e305451ac6d6a926ef6b53e8a597
517
py
Python
src/ocr-test-plate.py
ferauche/snct2021
510502ae61f76183f532f189332c8a7889048988
[ "MIT" ]
null
null
null
src/ocr-test-plate.py
ferauche/snct2021
510502ae61f76183f532f189332c8a7889048988
[ "MIT" ]
null
null
null
src/ocr-test-plate.py
ferauche/snct2021
510502ae61f76183f532f189332c8a7889048988
[ "MIT" ]
null
null
null
import cv2 import pytesseract from picamera.array import PiRGBArray from picamera import PiCamera import time import re camera = PiCamera() rawCapture = PiRGBArray(camera) time.sleep(1.2) camera.capture(rawCapture, format="bgr") image = cv2.cvtColor(rawCapture.array, cv2.COLOR_BGR2GRAY) print("Lendo...") opt = "-c...
22.478261
71
0.758221
import cv2 import pytesseract from picamera.array import PiRGBArray from picamera import PiCamera import time import re camera = PiCamera() rawCapture = PiRGBArray(camera) time.sleep(1.2) camera.capture(rawCapture, format="bgr") image = cv2.cvtColor(rawCapture.array, cv2.COLOR_BGR2GRAY) print("Lendo...") opt = "-c...
0
0
0
0
0
0
0
0
0
5ffaa237fc75904bf7161655b597df86749a2756
1,070
py
Python
convert_PALS_to_subjects.py
MadsJensen/RP_scripts
b3f7afb27b6346ee209e4bfcd7d52049d69d2eaf
[ "BSD-3-Clause" ]
null
null
null
convert_PALS_to_subjects.py
MadsJensen/RP_scripts
b3f7afb27b6346ee209e4bfcd7d52049d69d2eaf
[ "BSD-3-Clause" ]
null
null
null
convert_PALS_to_subjects.py
MadsJensen/RP_scripts
b3f7afb27b6346ee209e4bfcd7d52049d69d2eaf
[ "BSD-3-Clause" ]
null
null
null
from __future__ import print_function import subprocess # path to submit_to_isis cmd = "/usr/local/common/meeg-cfin/configurations/bin/submit_to_isis" subjects = ["0008", "0009", "0010", "0011", "0012", "0013", "0014", "0015", "0016", "0017", "0018", "0019", "0020", "0021", "0022"] for subj...
44.583333
97
0.6
from __future__ import print_function import subprocess # path to submit_to_isis cmd = "/usr/local/common/meeg-cfin/configurations/bin/submit_to_isis" subjects = ["0008", "0009", "0010", "0011", "0012", "0013", "0014", "0015", "0016", "0017", "0018", "0019", "0020", "0021", "0022"] for subj...
0
0
0
0
0
0
0
0
0
1d90aeb3f1fa4de97feff2b72f58ae3b8de84f44
1,255
py
Python
Serving/LinearRegression_streaming.py
IntelligentSensor/PHMRepository
8684c7851970293d607d18c580cec7edbf72ad17
[ "MIT" ]
6
2021-09-27T00:23:41.000Z
2022-03-16T00:21:27.000Z
Serving/LinearRegression_streaming.py
intelligentph/PhRepository
8684c7851970293d607d18c580cec7edbf72ad17
[ "MIT" ]
4
2020-08-21T03:56:16.000Z
2022-02-10T02:17:08.000Z
Serving/LinearRegression_streaming.py
IntelligentSensor/Sensor-PHM
8684c7851970293d607d18c580cec7edbf72ad17
[ "MIT" ]
5
2020-11-25T11:46:12.000Z
2022-02-14T02:37:06.000Z
""" Streaming Linear Regression Example. """ from __future__ import print_function import sys from pyspark import SparkContext from pyspark.streaming import StreamingContext from pyspark.mllib.regression import StreamingLinearRegressionWithSGD if __name__ == "__main__": if len(sys.argv) != 3: print("Usag...
30.609756
86
0.697211
""" Streaming Linear Regression Example. """ from __future__ import print_function import sys from pyspark import SparkContext from pyspark.streaming import StreamingContext from pyspark.mllib.linalg import Vectors from pyspark.mllib.regression import LabeledPoint from pyspark.mllib.regression import StreamingLinearR...
0
0
0
0
0
166
0
47
71
f1035aa58b20da1ecffd7f32eaaa3447c0cff2c9
249
py
Python
models/test.py
Mingzheng01/pointnet
401692e08441ff459b63786b9c65c11f78ea599e
[ "MIT" ]
null
null
null
models/test.py
Mingzheng01/pointnet
401692e08441ff459b63786b9c65c11f78ea599e
[ "MIT" ]
null
null
null
models/test.py
Mingzheng01/pointnet
401692e08441ff459b63786b9c65c11f78ea599e
[ "MIT" ]
null
null
null
n = [5, 6] print(id(n)) # 140312184155336 updateList(n) print(n) # [5, 6, 10] print(id(n)) # 140312184155336
22.636364
47
0.522088
import tensorflow as tf import numpy as np def updateList(list1): list1 += [10] n = [5, 6] print(id(n)) # 140312184155336 updateList(n) print(n) # [5, 6, 10] print(id(n)) # 140312184155336
0
0
0
0
0
19
0
-1
67
a0bb841d8a48c14ffe59ef91f3c70edf038b0872
761
py
Python
problems/0001_two_sum.py
SouravDutta91/LeetCode
7756d320cc5477a23011cea03a350c022a699a2e
[ "MIT" ]
null
null
null
problems/0001_two_sum.py
SouravDutta91/LeetCode
7756d320cc5477a23011cea03a350c022a699a2e
[ "MIT" ]
null
null
null
problems/0001_two_sum.py
SouravDutta91/LeetCode
7756d320cc5477a23011cea03a350c022a699a2e
[ "MIT" ]
null
null
null
''' Given an array of integers, return indices of the two numbers such that they add up to a specific target. You may assume that each input would have exactly one solution, and you may not use the same element twice. Example: Given nums = [2, 7, 11, 15], target = 9, Because nums[0] + nums[1] = 2 + 7 = 9, return [0...
27.178571
107
0.595269
''' Given an array of integers, return indices of the two numbers such that they add up to a specific target. You may assume that each input would have exactly one solution, and you may not use the same element twice. Example: Given nums = [2, 7, 11, 15], target = 9, Because nums[0] + nums[1] = 2 + 7 = 9, return [0...
0
0
0
315
0
0
0
0
23
605dd4808c430ac6c7164fe621e70d43c923a1fb
1,813
py
Python
example-generator.py
sanus-solutions/druid-superset
9a972802b74112b627e9b12f55fabbfdce5f4d44
[ "Apache-2.0" ]
null
null
null
example-generator.py
sanus-solutions/druid-superset
9a972802b74112b627e9b12f55fabbfdce5f4d44
[ "Apache-2.0" ]
null
null
null
example-generator.py
sanus-solutions/druid-superset
9a972802b74112b627e9b12f55fabbfdce5f4d44
[ "Apache-2.0" ]
null
null
null
import random, requests from faker import Faker from random import randrange, randint units = [ "Neonatal intensive care", "Pediatric intensive care", "Coronary care and cardiothoracic", "Surgical intensive care", "Medical intensive care", "Long term intensive care" ] event_types = [ ["entry", "clean", "not cle...
25.535211
92
0.679537
import random, requests from datetime import * from faker import Faker from random import randrange, randint units = [ "Neonatal intensive care", "Pediatric intensive care", "Coronary care and cardiothoracic", "Surgical intensive care", "Medical intensive care", "Long term intensive care" ] event_types = [ ["en...
0
0
0
0
0
413
0
1
68
daa4d4d5d2ba2e43db27fe3cbc2fefa6e42806b3
6,690
py
Python
DeepNetwork.py
bathonSpidey/DeepNetwork
9913d102dbe617a79b0b9cf522086b7ff0cfd8b3
[ "MIT" ]
null
null
null
DeepNetwork.py
bathonSpidey/DeepNetwork
9913d102dbe617a79b0b9cf522086b7ff0cfd8b3
[ "MIT" ]
null
null
null
DeepNetwork.py
bathonSpidey/DeepNetwork
9913d102dbe617a79b0b9cf522086b7ff0cfd8b3
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Tue Jan 5 23:01:33 2021 @author: batho """
43.72549
107
0.631091
# -*- coding: utf-8 -*- """ Created on Tue Jan 5 23:01:33 2021 @author: batho """ import numpy as np class Network: def dataReshape(self,dataset): return dataset.reshape(dataset.shape[0],-1).T def sigmoid(self,linearResult): activatedResult= 1/(1+np.exp(-linearResult)) retu...
0
0
0
6,503
0
0
0
-3
46
e27ecf3ebcb33b74a44fed1170118875536cf623
976
py
Python
silex_client/utils/log.py
ArtFXDev/silex_client
657d594dcfec79e7c8f4053df9d4a5dbc0c9ac50
[ "MIT" ]
10
2021-09-21T03:26:45.000Z
2022-03-19T00:30:03.000Z
silex_client/utils/log.py
ArtFXDev/silex_dcc
657d594dcfec79e7c8f4053df9d4a5dbc0c9ac50
[ "MIT" ]
66
2021-09-17T09:54:23.000Z
2022-03-29T23:31:17.000Z
silex_client/utils/log.py
ArtFXDev/silex_dcc
657d594dcfec79e7c8f4053df9d4a5dbc0c9ac50
[ "MIT" ]
null
null
null
""" @author: michael.haussmann retake by le TD gang A simple logger shortcut / wrapper. Uses https://logzero.readthedocs.io/ """ import logging import os import sys import logzero from logzero import logger # Formatting of the output log to look like __LOG_FORMAT__ = "[SILEX]\ [%(asctime)s] %(color)s%(levelna...
25.684211
81
0.748975
""" @author: michael.haussmann retake by le TD gang A simple logger shortcut / wrapper. Uses https://logzero.readthedocs.io/ """ import logging import os import sys import logzero from logzero import logger # Formatting of the output log to look like __LOG_FORMAT__ = "[SILEX]\ [%(asctime)s] %(color)s%(levelna...
0
0
0
0
0
0
0
0
0
403ccb3bb0baedaed9f44b1c1334c3e916bd1402
1,891
py
Python
python/shopping/content/workflows.py
akgarchi/googleads-shopping-samples
053bc5500405b751c671b169748b963fc142e8cc
[ "Apache-2.0" ]
149
2015-01-11T12:23:41.000Z
2022-03-28T03:42:20.000Z
python/shopping/content/workflows.py
akgarchi/googleads-shopping-samples
053bc5500405b751c671b169748b963fc142e8cc
[ "Apache-2.0" ]
28
2015-07-14T20:42:10.000Z
2021-12-27T01:06:12.000Z
python/shopping/content/workflows.py
akgarchi/googleads-shopping-samples
053bc5500405b751c671b169748b963fc142e8cc
[ "Apache-2.0" ]
250
2015-01-20T14:30:17.000Z
2022-03-28T06:26:51.000Z
#!/usr/bin/python # # 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 b...
33.767857
74
0.662612
#!/usr/bin/python # # 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 b...
0
0
0
0
0
721
0
151
200
81917554f945b6226b57948fc8368df61c83d0db
7,065
py
Python
cscs-checks/microbenchmarks/mpi/halo_exchange/halo_cell_exchange.py
jacwah/reframe
d650bbbb2f87c6ae5f354e50b50bcfd98fafe77b
[ "BSD-3-Clause" ]
null
null
null
cscs-checks/microbenchmarks/mpi/halo_exchange/halo_cell_exchange.py
jacwah/reframe
d650bbbb2f87c6ae5f354e50b50bcfd98fafe77b
[ "BSD-3-Clause" ]
3
2022-03-11T09:51:33.000Z
2022-03-31T08:20:19.000Z
cscs-checks/microbenchmarks/mpi/halo_exchange/halo_cell_exchange.py
jacwah/reframe
d650bbbb2f87c6ae5f354e50b50bcfd98fafe77b
[ "BSD-3-Clause" ]
null
null
null
# Copyright 2016-2022 Swiss National Supercomputing Centre (CSCS/ETH Zurich) # ReFrame Project Developers. See the top-level LICENSE file for details. # # SPDX-License-Identifier: BSD-3-Clause
46.788079
78
0.479264
# Copyright 2016-2022 Swiss National Supercomputing Centre (CSCS/ETH Zurich) # ReFrame Project Developers. See the top-level LICENSE file for details. # # SPDX-License-Identifier: BSD-3-Clause import reframe as rfm import reframe.utility.sanity as sn @rfm.simple_test class HaloCellExchangeTest(rfm.RegressionTest): ...
0
6,789
0
0
0
0
0
14
68
9791879d1c1f35de52f9cb7e5249578c2580c89b
5,398
py
Python
ojm.py
evuez/ojm
382452836779211b574e7958258ca17105d5654e
[ "MIT" ]
null
null
null
ojm.py
evuez/ojm
382452836779211b574e7958258ca17105d5654e
[ "MIT" ]
null
null
null
ojm.py
evuez/ojm
382452836779211b574e7958258ca17105d5654e
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- STORAGE = 'ojm.data' _models = {} def register(model): """ Register a class to allow object loading from JSON. """ _models[model.__name__] = model def storable(obj): """ Remove fields that can't / shouldn't be stored. """ return { a:get_data(a) for ...
27.968912
77
0.475732
# -*- coding: utf-8 -*- import json from time import strftime from os import path, remove from glob import glob from uuid import uuid4 STORAGE = 'ojm.data' class ModelNotFound(Exception): pass _models = {} def register(model): """ Register a class to allow object loading from JSON. """ _model...
0
2,465
0
2,130
0
138
0
1
183
1bf08b75140963ba2e0adf3ecf31287e7cfd92ef
5,308
py
Python
indico/modules/events/timetable/controllers/display.py
bkmgit/indico
d77ee121e35880a416b9b05e6098ea912d870b5c
[ "MIT" ]
1
2021-06-11T20:02:10.000Z
2021-06-11T20:02:10.000Z
indico/modules/events/timetable/controllers/display.py
bkmgit/indico
d77ee121e35880a416b9b05e6098ea912d870b5c
[ "MIT" ]
null
null
null
indico/modules/events/timetable/controllers/display.py
bkmgit/indico
d77ee121e35880a416b9b05e6098ea912d870b5c
[ "MIT" ]
null
null
null
# This file is part of Indico. # Copyright (C) 2002 - 2022 CERN # # Indico is free software; you can redistribute it and/or # modify it under the terms of the MIT License; see the # LICENSE file for more details.
49.607477
120
0.696873
# This file is part of Indico. # Copyright (C) 2002 - 2022 CERN # # Indico is free software; you can redistribute it and/or # modify it under the terms of the MIT License; see the # LICENSE file for more details. from io import BytesIO from flask import jsonify, request, session from werkzeug.exceptions import Forbid...
0
0
0
3,893
0
0
0
727
470
90a8ac88c134de85ef0fff569cb91c072a5406f2
9,413
py
Python
sphinx_autodoc_typehints.py
bpeake-illuscio/sphinx-autodoc-typehints
cd822aacb96bb250e8d533cd7131e986f1938f08
[ "MIT" ]
null
null
null
sphinx_autodoc_typehints.py
bpeake-illuscio/sphinx-autodoc-typehints
cd822aacb96bb250e8d533cd7131e986f1938f08
[ "MIT" ]
null
null
null
sphinx_autodoc_typehints.py
bpeake-illuscio/sphinx-autodoc-typehints
cd822aacb96bb250e8d533cd7131e986f1938f08
[ "MIT" ]
null
null
null
import inspect import typing from typing import get_type_hints, TypeVar, Any, AnyStr, Generic, Union from sphinx.util import logging from sphinx.util.inspect import Signature try: from inspect import unwrap except ImportError: def unwrap(func, *, stop=None): """This is the inspect.unwrap() method copi...
39.384937
97
0.576756
import inspect import typing from typing import get_type_hints, TypeVar, Any, AnyStr, Generic, Union from sphinx.util import logging from sphinx.util.inspect import Signature try: from inspect import unwrap except ImportError: def unwrap(func, *, stop=None): """This is the inspect.unwrap() method copi...
0
0
0
0
0
8,384
0
0
183
f9a60e9bba65feb39ffcf676f32b2f49d5004405
1,512
py
Python
tests/test_loops.py
nathfroech/flake8_pylint_comparison
1f6d5063b3055687e880b5b436346ce4b5ae95da
[ "MIT" ]
null
null
null
tests/test_loops.py
nathfroech/flake8_pylint_comparison
1f6d5063b3055687e880b5b436346ce4b5ae95da
[ "MIT" ]
null
null
null
tests/test_loops.py
nathfroech/flake8_pylint_comparison
1f6d5063b3055687e880b5b436346ce4b5ae95da
[ "MIT" ]
null
null
null
from tests.testing_utils import param_wrapper params = [ # code, flake8 rules, pylint rules param_wrapper(( 'values = []', 'for i in range(10):', ' values.append(10)', ), {'B007'}, set(), id='simple_loop'), param_wrapper(( 'values = []', 'for i in range(10):'...
33.6
92
0.571429
import pytest from hamcrest import assert_that, contains_inanyorder from tests.testing_utils import param_wrapper, run_flake8, run_pylint params = [ # code, flake8 rules, pylint rules param_wrapper(( 'values = []', 'for i in range(10):', ' values.append(10)', ), {'B007'}, set(),...
0
442
0
0
0
0
0
48
67
e904ea4282882301d69b1dd575369bf096878386
6,379
py
Python
tests/test_plPlug.py
sdss/coordio
61f5c962b8e3f335259168c9f8e872b4d3fe25d8
[ "BSD-3-Clause" ]
null
null
null
tests/test_plPlug.py
sdss/coordio
61f5c962b8e3f335259168c9f8e872b4d3fe25d8
[ "BSD-3-Clause" ]
9
2021-02-04T00:01:30.000Z
2021-11-14T22:42:49.000Z
tests/test_plPlug.py
sdss/coordio
61f5c962b8e3f335259168c9f8e872b4d3fe25d8
[ "BSD-3-Clause" ]
null
null
null
import matplotlib.pyplot as plt import coordio.fitData as fitData import os filedir = os.path.dirname(os.path.abspath(__file__)) # apo plate 15017 apo = {} apo["utcJD"] = 2459249.6184 apo["alt"] = 54 # at the JD supplied... apo["file"] = os.path.join(filedir, "plPlugMapP-15017.par") # lco plate 12377 lco = {} lco[...
28.605381
79
0.557297
from coordio.utils import radec2wokxy, wokxy2radec import time import matplotlib.pyplot as plt import numpy import coordio.fitData as fitData import os from astropy.coordinates import SkyCoord from astropy import units as u filedir = os.path.dirname(os.path.abspath(__file__)) # apo plate 15017 apo = {} apo["utcJD"]...
0
0
0
0
0
5,481
0
38
180
961b1b6516caff18447da65c62981e65debf064f
16,322
py
Python
ver1_0/openassembly/pirate_reputation/templatetags/reputationtags.py
fragro/Open-Assembly
e9679ff5e7ae9881fa5781d763288ed2f40b014d
[ "BSD-3-Clause" ]
1
2015-11-05T08:22:19.000Z
2015-11-05T08:22:19.000Z
ver1_0/openassembly/pirate_reputation/templatetags/reputationtags.py
fragro/Open-Assembly
e9679ff5e7ae9881fa5781d763288ed2f40b014d
[ "BSD-3-Clause" ]
null
null
null
ver1_0/openassembly/pirate_reputation/templatetags/reputationtags.py
fragro/Open-Assembly
e9679ff5e7ae9881fa5781d763288ed2f40b014d
[ "BSD-3-Clause" ]
1
2018-02-03T18:25:41.000Z
2018-02-03T18:25:41.000Z
from django import template from pirate_core import namespace_get from customtags.decorators import block_decorator register = template.Library() block = block_decorator(register) get_namespace = namespace_get('pp_reputation') #returns a graph of the distribution of votes for this user, based on dtype #argum...
33.863071
158
0.612241
from django import template from django import forms import datetime import sys from django.contrib.auth.models import User from django.contrib.contenttypes.models import ContentType from pirate_reputation.models import Reputation, ReputationDimension, ReputationEvent, AbuseTicket, FeedbackTicket from pirate_consensus....
0
6,787
0
782
0
6,994
0
257
562
2c3dd1949bb2955c67ca4bee97e74cf524bc7b22
5,089
py
Python
gaea/gaea/log/main.py
Yo-main/akingbee.com
144940df99900226073eb4bf721a6ab407a3911d
[ "MIT" ]
null
null
null
gaea/gaea/log/main.py
Yo-main/akingbee.com
144940df99900226073eb4bf721a6ab407a3911d
[ "MIT" ]
20
2019-10-06T20:24:49.000Z
2022-02-28T01:55:49.000Z
gaea/gaea/log/main.py
yo-main/akingbee
a8b4b307e2262f98eb93459c6dd4207e707cee1e
[ "MIT" ]
null
null
null
import os import logging from logging.handlers import RotatingFileHandler from gaea.config import CONFIG # class ContextFilter(logging.Filter): # def filter(self, record): # if flask.has_request_context(): # # when logging out, the user_id is already set # if not hasattr(record, "...
26.925926
79
0.612694
import os import time import json import datetime import logging from logging.handlers import RotatingFileHandler import pprint from gaea.config import CONFIG # class ContextFilter(logging.Filter): # def filter(self, record): # if flask.has_request_context(): # # when logging out, the user_id...
0
0
0
2,519
0
0
0
-34
180
70b89eb4aa7c16b4b0f366374cd0ae72f88c24de
524
py
Python
Tutorials/Graph/ChangeBackgroundColor/ChangeBackgroundColour.py
BlueTurtle01/PydotTutorials
d1d1cebd41069c9f93a8490dc5dff0ab06ea3101
[ "MIT" ]
null
null
null
Tutorials/Graph/ChangeBackgroundColor/ChangeBackgroundColour.py
BlueTurtle01/PydotTutorials
d1d1cebd41069c9f93a8490dc5dff0ab06ea3101
[ "MIT" ]
null
null
null
Tutorials/Graph/ChangeBackgroundColor/ChangeBackgroundColour.py
BlueTurtle01/PydotTutorials
d1d1cebd41069c9f93a8490dc5dff0ab06ea3101
[ "MIT" ]
null
null
null
import pydot # Create the graph # include the "bgcolor" argument with a string value. graph = pydot.Dot("my_graph", graph_type="graph", bgcolor="yellow") # I have added a node so we can better see that our graph creation has worked. This is naturally a trivial # graph as it has no edges, but as a minimum working exam...
34.933333
106
0.757634
import pydot # Create the graph # include the "bgcolor" argument with a string value. graph = pydot.Dot("my_graph", graph_type="graph", bgcolor="yellow") # I have added a node so we can better see that our graph creation has worked. This is naturally a trivial # graph as it has no edges, but as a minimum working exam...
0
0
0
0
0
0
0
0
0
cae2f1c9fb4552a8433e08a5926dbec94066575a
5,024
py
Python
src/restfx/middleware/middlewares/session.py
mgbin088/restfx
86a499a9a4396829e2c40428feb8b2ee13406d52
[ "MIT", "BSD-3-Clause" ]
1
2021-01-28T00:54:10.000Z
2021-01-28T00:54:10.000Z
src/restfx/middleware/middlewares/session.py
mgbin088/restfx
86a499a9a4396829e2c40428feb8b2ee13406d52
[ "MIT", "BSD-3-Clause" ]
null
null
null
src/restfx/middleware/middlewares/session.py
mgbin088/restfx
86a499a9a4396829e2c40428feb8b2ee13406d52
[ "MIT", "BSD-3-Clause" ]
null
null
null
import string """ session id : useragent remote_addr remote_addr#useragent md5 (length=32) md5 (length=32) 64 app id md5 xor (session id) """ _salt = 'hyjiacan' _salt_chars = [ord(ch) for ch in list(_salt)] _padding_len = 24 _padding_chars = string.ascii_letters + string.digits ...
32.623377
89
0.591959
import string import time from ...app_context import AppContext from ...middleware.interface import MiddlewareBase from ...session.interfaces import ISessionProvider from ...util import md5, b64 """ session id 算法: 其中包含 useragent 和 remote_addr 用于标识一个远程客户端 其值组合成 remote_addr#useragent,计算得到 md5 (length=3...
327
0
0
3,625
0
680
0
71
217
b95f7a54169f5382aa3a3dee0c6801b497a47e32
479
py
Python
assignements/simple_queue_publish.py
Antoine01100/BachelorDIM-Lectures-Algorithms-2020
78b02c75127666618ae3724e231be2c0b936a1b7
[ "MIT" ]
null
null
null
assignements/simple_queue_publish.py
Antoine01100/BachelorDIM-Lectures-Algorithms-2020
78b02c75127666618ae3724e231be2c0b936a1b7
[ "MIT" ]
null
null
null
assignements/simple_queue_publish.py
Antoine01100/BachelorDIM-Lectures-Algorithms-2020
78b02c75127666618ae3724e231be2c0b936a1b7
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Tue Oct 13 13:55:28 2020 @author: bouvaran """ import mykeys import pika AMQP_URL = mykeys.cloudamplink connection = pika.BlockingConnection(pika.URLParameters(AMQP_URL)) channel = connection.channel() channel.queue_declare(queue='presentation') channel.basic_publish(exchange...
19.16
66
0.680585
# -*- coding: utf-8 -*- """ Created on Tue Oct 13 13:55:28 2020 @author: bouvaran """ import mykeys import pika AMQP_URL = mykeys.cloudamplink connection = pika.BlockingConnection(pika.URLParameters(AMQP_URL)) channel = connection.channel() channel.queue_declare(queue='presentation’') channel.basic_publish(exchang...
6
0
0
0
0
0
0
0
0
b206e2339dcf609d1ed6ee6f2a50da09a2762c08
7,140
py
Python
csv2sql/core/type_inference.py
ymoch/csv2sql
22e20c1ccb7a5b21bacec6bd94b72d3c2e06bb4a
[ "MIT" ]
7
2017-03-07T03:05:12.000Z
2021-03-19T17:12:46.000Z
csv2sql/core/type_inference.py
ymoch/csv2sql
22e20c1ccb7a5b21bacec6bd94b72d3c2e06bb4a
[ "MIT" ]
15
2017-02-06T17:11:01.000Z
2018-08-18T02:55:17.000Z
csv2sql/core/type_inference.py
ymoch/csv2sql
22e20c1ccb7a5b21bacec6bd94b72d3c2e06bb4a
[ "MIT" ]
5
2017-02-05T18:20:00.000Z
2021-11-14T20:20:42.000Z
"""Type pattern.""" import operator import itertools import functools from csv2sql.core.error import InterpretationError _COMPATIBLE_PREDICATES = { 'int': functools.partial(_compatible, int), 'float': functools.partial(_compatible, float), } _DEFAULT_NULL_VALUE = '' _PREDICATE_GENERATORS = { ...
29.262295
78
0.658123
"""Type pattern.""" import re import decimal import operator import itertools import functools from csv2sql.core.error import InterpretationError, TypeInferenceError def _compatible(cast_type, value): try: cast_type(value) except ValueError: return False return True _COMPATIBLE_PREDICA...
0
249
0
1,307
0
2,467
0
1
344
6844e5481b83263b1031e6308182eb8b247ee480
712
py
Python
scout/server/blueprints/diagnoses/views.py
gmc-norr/scout
ea8eaaa079c63e4033af6216ec08da4a314f9b5c
[ "BSD-3-Clause" ]
null
null
null
scout/server/blueprints/diagnoses/views.py
gmc-norr/scout
ea8eaaa079c63e4033af6216ec08da4a314f9b5c
[ "BSD-3-Clause" ]
null
null
null
scout/server/blueprints/diagnoses/views.py
gmc-norr/scout
ea8eaaa079c63e4033af6216ec08da4a314f9b5c
[ "BSD-3-Clause" ]
null
null
null
from flask import Blueprint omim_bp = Blueprint("diagnoses", __name__, template_folder="templates")
27.384615
71
0.745787
from flask import Blueprint from scout.server.extensions import store from scout.server.utils import templated, public_endpoint from . import controllers omim_bp = Blueprint("diagnoses", __name__, template_folder="templates") @omim_bp.route("/diagnoses/<omim_nr>", methods=["GET"]) @templated("diagnoses/omim_term.ht...
0
436
0
0
0
0
0
60
113
9bfb08978f09c1ff3df136b1dd1eaf9e25cc2385
11,470
py
Python
sccc_contestbot/__init__.py
queragion2726/sccc_contestbot
91d59196aee11b5859bb8504288ba317523b47fd
[ "Apache-2.0" ]
2
2020-01-04T10:00:35.000Z
2020-02-25T05:08:24.000Z
sccc_contestbot/__init__.py
queragion2726/sccc_contestbot
91d59196aee11b5859bb8504288ba317523b47fd
[ "Apache-2.0" ]
1
2020-07-22T18:25:13.000Z
2020-07-22T18:25:38.000Z
sccc_contestbot/__init__.py
queragion2726/sccc_contestbot
91d59196aee11b5859bb8504288ba317523b47fd
[ "Apache-2.0" ]
1
2021-03-23T13:48:47.000Z
2021-03-23T13:48:47.000Z
import logging from sccc_contestbot.logger import init_logger init_logger(__name__) logger = logging.getLogger(__name__)
32.128852
88
0.564778
import asyncio import logging import threading import time from datetime import datetime from concurrent.futures import ThreadPoolExecutor from typing import List import slack import sqlalchemy from sqlalchemy.orm import sessionmaker, scoped_session import settings from .models import Base, Contest, Subscriber, Conte...
1,848
0
4,459
5,705
0
0
0
210
355
985b5ef5d5021bc83c0b152f4da2f8ee2e62e77c
2,000
py
Python
src/stateful_examples/river_crossing.py
FRYoussef/property-based-testing-poker
b5890d8d6934b9f7b17b0173c492a8ae68410e51
[ "MIT" ]
null
null
null
src/stateful_examples/river_crossing.py
FRYoussef/property-based-testing-poker
b5890d8d6934b9f7b17b0173c492a8ae68410e51
[ "MIT" ]
null
null
null
src/stateful_examples/river_crossing.py
FRYoussef/property-based-testing-poker
b5890d8d6934b9f7b17b0173c492a8ae68410e51
[ "MIT" ]
null
null
null
import unittest from hypothesis import settings if __name__ == "__main__": RiverCrossing.TestCase.settings = settings(max_examples=100, stateful_step_count=50) RiverCrossingTest = RiverCrossing.TestCase unittest.main()
32.258065
105
0.654
import unittest from enum import Enum from hypothesis import settings, note from hypothesis.stateful import RuleBasedStateMachine, rule, invariant, precondition class Side(Enum): Left = 0 Right = 1 def __str__(self) -> str: return 'L' if self.value == Side.Left.value else 'R' def switch(self)...
0
750
0
858
0
0
0
69
91
0e32a0b20377d21cfdbd17fa5c41d4ac67f6c84c
634
py
Python
apps/users/urls.py
vuonghv/brs
9cdf9431ac69fd7a33d8bf4240a7d49a49ae4a80
[ "MIT" ]
1
2021-01-13T23:42:54.000Z
2021-01-13T23:42:54.000Z
apps/users/urls.py
vuonghv/brs
9cdf9431ac69fd7a33d8bf4240a7d49a49ae4a80
[ "MIT" ]
1
2015-10-09T06:19:29.000Z
2015-10-09T06:19:29.000Z
apps/users/urls.py
vuonghv/brs
9cdf9431ac69fd7a33d8bf4240a7d49a49ae4a80
[ "MIT" ]
8
2015-10-09T02:00:34.000Z
2016-07-08T15:00:37.000Z
from django.conf.urls import url from . import views urlpatterns = [ url(r'^signup/$', views.SignupUserView.as_view(), name='signup'), url(r'^login/$', views.LoginUserView.as_view(), name='login'), url(r'^logout/$', views.logout_user, name='logout'), url(r'^follow/(?P<pk>[0-9]+)/$', v...
42.266667
97
0.608833
from django.conf.urls import url from . import views urlpatterns = [ url(r'^signup/$', views.SignupUserView.as_view(), name='signup'), url(r'^login/$', views.LoginUserView.as_view(), name='login'), url(r'^logout/$', views.logout_user, name='logout'), url(r'^follow/(?P<pk>[0-9]+)/$', v...
0
0
0
0
0
0
0
0
0
e033764b8f85a9224d591af351a901f2c66c2958
5,244
py
Python
ccbb_pyutils/parallel_process_fastqs.py
ucsd-ccbb/ccbb-ucsd-pyutils
944ff2230c66ab70016bcac393e05a7e12f1cfd5
[ "MIT" ]
null
null
null
ccbb_pyutils/parallel_process_fastqs.py
ucsd-ccbb/ccbb-ucsd-pyutils
944ff2230c66ab70016bcac393e05a7e12f1cfd5
[ "MIT" ]
null
null
null
ccbb_pyutils/parallel_process_fastqs.py
ucsd-ccbb/ccbb-ucsd-pyutils
944ff2230c66ab70016bcac393e05a7e12f1cfd5
[ "MIT" ]
null
null
null
# standard libraries __author__ = 'Amanda Birmingham' __maintainer__ = "Amanda Birmingham" __email__ = "abirmingham@ucsd.edu" __status__ = "prototype"
38.558824
115
0.703852
# standard libraries import datetime import logging import multiprocessing import timeit import traceback from ccbb_pyutils.bio_seq_utilities import pair_hiseq_read_files from ccbb_pyutils.files_and_paths import get_basename_fps_tuples, get_file_name_pieces, \ get_filepaths_from_wildcard __author__ = 'Amanda Bir...
0
0
0
0
0
4,674
0
118
294
bf904e02c66e86111f4b19123d219550390b8449
9,963
py
Python
tests/test_student.py
chrispyles/pybryt
23f8bfce3179638ec5b4efe3555d3bb4e7321dc0
[ "MIT" ]
null
null
null
tests/test_student.py
chrispyles/pybryt
23f8bfce3179638ec5b4efe3555d3bb4e7321dc0
[ "MIT" ]
null
null
null
tests/test_student.py
chrispyles/pybryt
23f8bfce3179638ec5b4efe3555d3bb4e7321dc0
[ "MIT" ]
null
null
null
"""""" import os import nbformat import pkg_resources import pytest import tempfile from copy import deepcopy from textwrap import dedent from unittest import mock from pybryt import (check, generate_student_impls, ReferenceImplementation, ReferenceResult, StudentImplementation) from pybryt.execution.memory_footprin...
34.714286
129
0.643882
"""""" import os import nbformat import pkg_resources import pytest import tempfile from copy import deepcopy from functools import lru_cache from textwrap import dedent from unittest import mock from pybryt import ( check, generate_student_impls, ReferenceImplementation, ReferenceResult, StudentImplementation) ...
0
99
0
343
0
555
0
15
122
b4e10b947ebfeca07132cef83cf18dbccada5bc5
3,122
py
Python
model.py
guocheng2018/ner_bilstm_crf
603f2995f6a73ebf63bc4416e98ea2656dbe9eaa
[ "MIT" ]
15
2019-08-06T06:35:11.000Z
2021-11-01T08:41:37.000Z
model.py
guocheng2018/ner_bilstm_crf
603f2995f6a73ebf63bc4416e98ea2656dbe9eaa
[ "MIT" ]
null
null
null
model.py
guocheng2018/ner_bilstm_crf
603f2995f6a73ebf63bc4416e98ea2656dbe9eaa
[ "MIT" ]
2
2020-12-22T08:08:29.000Z
2021-01-06T04:35:24.000Z
# Author: GC import torch.nn as nn
32.520833
88
0.6246
# Author: GC from typing import List import torch import torch.nn as nn from torch.nn.utils.rnn import pack_padded_sequence, pad_packed_sequence from torchcrf import CRF class BiLSTM_CRF(nn.Module): """ Args: vocab_size: size of word vocabulary num_tags: total tags embed_dim: word em...
0
0
0
2,926
0
0
0
47
113
334b5c96c0c80b3fbce0e0dc2a93bc9f82a0ef74
15,290
py
Python
backend/api/admin/user.py
deti/boss
bc0cfe3067bf1cbf26789f7443a36e7cdd2ac869
[ "Apache-2.0" ]
7
2018-05-20T08:56:08.000Z
2022-03-11T15:50:54.000Z
backend/api/admin/user.py
deti/boss
bc0cfe3067bf1cbf26789f7443a36e7cdd2ac869
[ "Apache-2.0" ]
2
2021-06-08T21:12:51.000Z
2022-01-13T01:25:27.000Z
backend/api/admin/user.py
deti/boss
bc0cfe3067bf1cbf26789f7443a36e7cdd2ac869
[ "Apache-2.0" ]
5
2016-10-09T14:52:09.000Z
2020-12-25T01:04:35.000Z
# -*- coding: utf-8 -*- import conf import errors from model import User from api.validator import StringWithLimits, ModelId UserIdExpand = ModelId(User, errors.UserNotFound) PasswordValidator = StringWithLimits(conf.user.min_password_length, conf.user.max_password_length)
35.311778
114
0.578875
# -*- coding: utf-8 -*- import conf import errors import logbook import bottle import posixpath from urllib.parse import urljoin from memdb.token import UserToken from model import User, autocommit, MessageTemplate from model import display from memdb.token import PasswordResetToken from api import get, post, put, del...
130
13,438
0
814
0
0
0
382
310
345c69b0cd3d3611e0cbaa6da0053f9746981d6b
317
py
Python
nlp100/chapter-02/11.py
nwiizo/joke
808c4c998cc7f5b7f6f3fb5a3ce421588a70c087
[ "MIT" ]
1
2017-01-11T06:12:24.000Z
2017-01-11T06:12:24.000Z
nlp100/chapter-02/11.py
ShuyaMotouchi/joke
808c4c998cc7f5b7f6f3fb5a3ce421588a70c087
[ "MIT" ]
null
null
null
nlp100/chapter-02/11.py
ShuyaMotouchi/joke
808c4c998cc7f5b7f6f3fb5a3ce421588a70c087
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- #tr """ python3 12.py """ import sys if __name__=='__main__': print (tra(sys.argv[1],sys.argv[2],sys.argv[3]))
12.68
49
0.615142
#!/usr/bin/env python3 # -*- coding: utf-8 -*- #trコマンド """ python3 12.py 置換前 置換後 """ import sys def tra(file1,val1,val2): try: with open(file1) as f: f = f.read() except: print("miss") finally: print(f.replace(val1,val2)) if __name__=='__main__': print (tra(sys.argv[1],sys.argv[2],sys.argv[3]))
30
0
0
0
0
116
0
0
23
a5b5842b55f82ce2bfb162bae3b7edfff3d1aba8
457
py
Python
script.deluge/resources/lib/basictypes/registry.py
ogero/Deluge-Manager-XBMC
10c4f2a93ac1fffba01209444ba5e597036b968b
[ "MIT" ]
null
null
null
script.deluge/resources/lib/basictypes/registry.py
ogero/Deluge-Manager-XBMC
10c4f2a93ac1fffba01209444ba5e597036b968b
[ "MIT" ]
null
null
null
script.deluge/resources/lib/basictypes/registry.py
ogero/Deluge-Manager-XBMC
10c4f2a93ac1fffba01209444ba5e597036b968b
[ "MIT" ]
null
null
null
"""Mapping from core types/classes to stand-in DataTypeDefinitions""" REGISTRY = { } def registerDT(base, DT): """Register a DataTypeDefinition for a given base-class""" REGISTRY[base] = DT def getDT(base): """Return the appropriate DT for the given base-class This looks up the base in the registry...
24.052632
69
0.700219
"""Mapping from core types/classes to stand-in DataTypeDefinitions""" REGISTRY = { } def registerDT(base, DT): """Register a DataTypeDefinition for a given base-class""" REGISTRY[base] = DT def getDT(base): """Return the appropriate DT for the given base-class This looks up the base in the registry...
0
0
0
0
0
0
0
0
0
e14ec41089318bb31e1accb2b3548a22ce24ef83
1,056
py
Python
layered_settings/loaders/config_parser_loader.py
mathandpencil/layered-settings
8c3a48cc5ac7436a4ac7c1a72e81dad0e58ac7d8
[ "MIT" ]
1
2021-03-21T01:43:22.000Z
2021-03-21T01:43:22.000Z
layered_settings/loaders/config_parser_loader.py
mathandpencil/layered-settings
8c3a48cc5ac7436a4ac7c1a72e81dad0e58ac7d8
[ "MIT" ]
null
null
null
layered_settings/loaders/config_parser_loader.py
mathandpencil/layered-settings
8c3a48cc5ac7436a4ac7c1a72e81dad0e58ac7d8
[ "MIT" ]
null
null
null
import logging logger = logging.getLogger(__name__)
29.333333
78
0.638258
import functools import logging import configparser import os from .base_loader import BaseLoader logger = logging.getLogger(__name__) class ConfigParserLoader(BaseLoader): def __init__(self, path, ignore_if_missing=False): self.path = path if os.path.exists(self.path): ...
0
0
0
673
0
184
0
-5
142
db52d0e6993745640c28ee65e947b48ae54fd623
6,935
py
Python
music_player.py
PracticalMetal/Music-Player
26b3b664ea6d4e10b5890b3f3d2c226a653e92a3
[ "Apache-2.0" ]
null
null
null
music_player.py
PracticalMetal/Music-Player
26b3b664ea6d4e10b5890b3f3d2c226a653e92a3
[ "Apache-2.0" ]
null
null
null
music_player.py
PracticalMetal/Music-Player
26b3b664ea6d4e10b5890b3f3d2c226a653e92a3
[ "Apache-2.0" ]
null
null
null
import tkinter as tk root = tk.Tk() root.config(bg='#C35817') root.geometry( '600x400' ) root.title( "MP3 MUSIC PLAYER " ) img = PhotoImage( file=r'images/music.png' ) img_size=img.subsample(5,5) next = PhotoImage( file=r'images/next.png' ) prev = PhotoImage( file=r'images/previous.png' ) play = PhotoImage( file=r'...
37.896175
178
0.589329
import os import pickle import tkinter as tk from tkinter import * from tkinter import filedialog # to open songs file from pygame import mixer # to control music play,pause class Player( tk.Frame ): def __init__(self, master): super().__init__( master ) self.master = master self.pack() ...
8
0
0
6,255
0
0
0
-8
186
6facc95e1a9d0c12f1abf8dcd9030878ab28b5c8
3,827
py
Python
test/python/transpiler/test_pass_call.py
gadial/qiskit-terra
0fc83f44a6e80969875c738b2cee7bc33223e45f
[ "Apache-2.0" ]
null
null
null
test/python/transpiler/test_pass_call.py
gadial/qiskit-terra
0fc83f44a6e80969875c738b2cee7bc33223e45f
[ "Apache-2.0" ]
12
2018-09-21T12:02:18.000Z
2018-09-25T09:14:59.000Z
test/python/transpiler/test_pass_call.py
gadial/qiskit-terra
0fc83f44a6e80969875c738b2cee7bc33223e45f
[ "Apache-2.0" ]
null
null
null
# This code is part of Qiskit. # # (C) Copyright IBM 2017, 2021. # # This code is licensed under the Apache License, Version 2.0. You may # obtain a copy of this license in the LICENSE.txt file in the root directory # of this source tree or at http://www.apache.org/licenses/LICENSE-2.0. # # Any modifications or derivat...
43.988506
98
0.674419
# This code is part of Qiskit. # # (C) Copyright IBM 2017, 2021. # # This code is licensed under the Apache License, Version 2.0. You may # obtain a copy of this license in the LICENSE.txt file in the root directory # of this source tree or at http://www.apache.org/licenses/LICENSE-2.0. # # Any modifications or derivat...
0
0
0
3,067
0
0
0
118
112
1153cb6e2f89ac2d6c2be8ad3391a606c16659e4
4,180
py
Python
gen_feas/gen_slide_feas.py
PingjunChen/ThyroidGeneralWSI
ee3adaa4c3aa7c56d3cc5bd7b44d99894578beee
[ "MIT" ]
2
2020-05-02T16:37:13.000Z
2020-05-04T20:44:17.000Z
gen_feas/gen_slide_feas.py
PingjunChen/frozen-thyroid-cls
ee3adaa4c3aa7c56d3cc5bd7b44d99894578beee
[ "MIT" ]
null
null
null
gen_feas/gen_slide_feas.py
PingjunChen/frozen-thyroid-cls
ee3adaa4c3aa7c56d3cc5bd7b44d99894578beee
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import os import torch if __name__ == '__main__': args = set_args() os.environ["CUDA_VISIBLE_DEVICES"] = str(args.device_id) # load patch model args.model_path = os.path.join(args.model_dir, args.model_type, args.model_name) if not os.path.exists(args.model_path): ...
41.8
104
0.67799
# -*- coding: utf-8 -*- import os, sys import numpy as np import argparse, time import torch from pydaily import filesystem from pyimg import combine import openslide import matplotlib.pyplot as plt from skimage import io, transform import deepdish as dd import utils, patch_util def predict_slide_fea(slide_path, cls...
0
0
0
0
0
3,286
0
35
267
ab3ebaea3f1a6d00029f5ca6400c93a7db38b8d6
602
py
Python
tests/test_gdal.py
richardsheridan/imageio
f80f068329123fc3c164c522391969ac8eeb0dd4
[ "BSD-2-Clause" ]
null
null
null
tests/test_gdal.py
richardsheridan/imageio
f80f068329123fc3c164c522391969ac8eeb0dd4
[ "BSD-2-Clause" ]
null
null
null
tests/test_gdal.py
richardsheridan/imageio
f80f068329123fc3c164c522391969ac8eeb0dd4
[ "BSD-2-Clause" ]
1
2018-11-03T18:43:26.000Z
2018-11-03T18:43:26.000Z
""" Test gdal plugin functionality. """ import pytest import imageio pytest.importorskip("osgeo", reason="gdal is not installed") def test_gdal_reading(test_images): """Test reading gdal""" filename = test_images / "geotiff.tif" im = imageio.imread(filename, "gdal") assert im.shape == (929, 699) ...
22.296296
60
0.664452
""" Test gdal plugin functionality. """ import pytest import imageio pytest.importorskip("osgeo", reason="gdal is not installed") def test_gdal_reading(test_images): """Test reading gdal""" filename = test_images / "geotiff.tif" im = imageio.imread(filename, "gdal") assert im.shape == (929, 699) ...
0
0
0
0
0
0
0
0
0
d9ba8bca5b7327bbb7e6554d0a3849c186cc4ba9
1,623
py
Python
inspiration/simplegallery/test/upload/variants/test_aws_uploader.py
Zenahr/simple-music-gallery
2cf6e81208b721a91dcbf77e047c7f77182dd194
[ "MIT" ]
1
2020-07-03T17:21:01.000Z
2020-07-03T17:21:01.000Z
simplegallery/test/upload/variants/test_aws_uploader.py
theemack/simple-photo-gallery
f5db98bca7a7443ea7a9172317811f446eff760c
[ "MIT" ]
1
2020-06-20T12:13:00.000Z
2020-06-20T15:32:03.000Z
inspiration/simplegallery/test/upload/variants/test_aws_uploader.py
Zenahr/simple-music-gallery
2cf6e81208b721a91dcbf77e047c7f77182dd194
[ "MIT" ]
null
null
null
import unittest if __name__ == '__main__': unittest.main()
37.744186
103
0.646334
import unittest from unittest import mock import os import subprocess from testfixtures import TempDirectory from simplegallery.upload.uploader_factory import get_uploader class AWSUploaderTestCase(unittest.TestCase): def test_no_location(self): uploader = get_uploader('aws') self.assertFalse(upl...
0
1,201
0
177
0
0
0
46
133
d3269fd3713d6d4b1c880425b840be5804eac931
154,090
py
Python
discussion/happiness_dictionary.py
mm5110/PIC16A
e2dab91439c2627f6a47f4bf6d16de8ba5977fe8
[ "MIT" ]
10
2020-11-07T04:07:34.000Z
2021-12-31T10:19:12.000Z
discussion/happiness_dictionary.py
mm5110/PIC16A
e2dab91439c2627f6a47f4bf6d16de8ba5977fe8
[ "MIT" ]
16
2021-02-03T22:35:01.000Z
2021-05-24T21:28:56.000Z
discussion/happiness_dictionary.py
mm5110/PIC16A
e2dab91439c2627f6a47f4bf6d16de8ba5977fe8
[ "MIT" ]
19
2020-11-11T05:44:53.000Z
2022-02-01T14:10:15.000Z
happiness_dictionary={'laughter':8.5, 'happiness':8.44, 'love':8.42, 'happy':8.3, 'laughed':8.26, 'laugh':8.22, 'laughing':8.2, 'excellent':8.18, 'laughs':8.18, 'joy':8.16, 'successful':8.16, 'win':8.12, 'rainbow':8.1, 'smile':8.1, 'won':8.1, 'pleasure':8.08, 'smiled':8.08, 'rainbows':8.06, 'winning':8.04, 'celebratio...
15.071401
37
0.600363
happiness_dictionary={'laughter':8.5, 'happiness':8.44, 'love':8.42, 'happy':8.3, 'laughed':8.26, 'laugh':8.22, 'laughing':8.2, 'excellent':8.18, 'laughs':8.18, 'joy':8.16, 'successful':8.16, 'win':8.12, 'rainbow':8.1, 'smile':8.1, 'won':8.1, 'pleasure':8.08, 'smiled':8.08, 'rainbows':8.06, 'winning':8.04, 'celebratio...
0
0
0
0
0
0
0
0
0
649d71de77a159fa7464be3ada8151dcf99987bf
1,012
py
Python
Encoder.py
Amirhossein-Zare/rsa-manager
6dfcbb5b948257ef448cbc932f5338bb3e53daba
[ "MIT" ]
1
2021-02-15T17:20:42.000Z
2021-02-15T17:20:42.000Z
Encoder.py
Amirhossein-Zare/rsa-manager
6dfcbb5b948257ef448cbc932f5338bb3e53daba
[ "MIT" ]
1
2021-02-15T17:19:28.000Z
2021-02-15T17:19:28.000Z
Encoder.py
Amirhossein-Zare/rsa-manager
6dfcbb5b948257ef448cbc932f5338bb3e53daba
[ "MIT" ]
null
null
null
# See transform.py for more info # M(message in numbers) ** e(key[0]) mod n(key[1]) = C(output)
29.764706
68
0.594862
# See transform.py for more info import transform import ascii # M(message in numbers) ** e(key[0]) mod n(key[1]) = C(output) def encrypt(): message = input("What is your secret message?") key = [0, 0] key[0] = int(input("Now please type/paste e(public key) here:")) key[1] = int(input("Now please type/...
0
0
0
0
0
863
0
-14
66
ed3ddab75fd8cd35f3e3498ca2b3368b5d9a384c
111
py
Python
setup.py
jskeys/words
00467466cb7f7157c47ea49b91d5a540765cc4aa
[ "MIT" ]
null
null
null
setup.py
jskeys/words
00467466cb7f7157c47ea49b91d5a540765cc4aa
[ "MIT" ]
null
null
null
setup.py
jskeys/words
00467466cb7f7157c47ea49b91d5a540765cc4aa
[ "MIT" ]
null
null
null
import site import sys from setuptools import setup site.ENABLE_USER_SITE = "--user" in sys.argv[1:] setup()
13.875
48
0.747748
import site import sys from setuptools import setup site.ENABLE_USER_SITE = "--user" in sys.argv[1:] setup()
0
0
0
0
0
0
0
0
0
510340caa64571a122561488ddd79b7b088711e0
2,232
py
Python
simple-proxy/tcp_proxy_encoded.py
liangsai12/Hassio-Addons
d320b4a8c7f54ac6fd7d6ce8aef0581c662a5017
[ "Apache-2.0" ]
null
null
null
simple-proxy/tcp_proxy_encoded.py
liangsai12/Hassio-Addons
d320b4a8c7f54ac6fd7d6ce8aef0581c662a5017
[ "Apache-2.0" ]
null
null
null
simple-proxy/tcp_proxy_encoded.py
liangsai12/Hassio-Addons
d320b4a8c7f54ac6fd7d6ce8aef0581c662a5017
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 import os import socket import threading from selectors import DefaultSelector, EVENT_READ # Proxy LOCAL_PORT = 7088 # REMOTE_ADDR = "hachinasp.duckdns.org" REMOTE_PORT = 7088 def xor_encode( bstring ): """""" MASK = 0x55 ret = bytearray( bstring ) for i in range(len(ret)): ...
26.258824
100
0.59095
#!/usr/bin/env python3 import os import json import socket import threading from selectors import DefaultSelector, EVENT_READ # Proxy开放的端口号 LOCAL_PORT = 7088 # 连接的远程服务器与端口,修改成你的远程服务器地址 REMOTE_ADDR = "hachinasp.duckdns.org" REMOTE_PORT = 7088 def xor_encode( bstring ): """一个简单编码:两次编码后与原值相同""" MASK = 0x55 ...
381
0
0
0
0
0
0
-10
22
ad92cc4df4b6ad37e22118abd074de52c4815494
667
py
Python
CS-483_Big-Data-Analytics-Capstone_2020-Spring/code/statistics/crime-over-time-by-type.py
CraftingGamerTom/wsu-computer-science
aa40fc95a84ac95535284048f6f572def1375f7d
[ "MIT" ]
null
null
null
CS-483_Big-Data-Analytics-Capstone_2020-Spring/code/statistics/crime-over-time-by-type.py
CraftingGamerTom/wsu-computer-science
aa40fc95a84ac95535284048f6f572def1375f7d
[ "MIT" ]
null
null
null
CS-483_Big-Data-Analytics-Capstone_2020-Spring/code/statistics/crime-over-time-by-type.py
CraftingGamerTom/wsu-computer-science
aa40fc95a84ac95535284048f6f572def1375f7d
[ "MIT" ]
null
null
null
# https://www.kaggle.com/skeftical/chicago-crimes-eda-spatio-temporal # Crime over time (by type) # This is very resource intensive to run crimes_count_date = crimes.pivot_table('P_INCID_NO', aggfunc=np.size, columns='IBR_TYPE', index=crimes.index, fill_value=0) crimes_count_date.index = pd.DatetimeIndex(crimes_count...
44.466667
124
0.757121
# https://www.kaggle.com/skeftical/chicago-crimes-eda-spatio-temporal # Crime over time (by type) # This is very resource intensive to run crimes_count_date = crimes.pivot_table('P_INCID_NO', aggfunc=np.size, columns='IBR_TYPE', index=crimes.index, fill_value=0) crimes_count_date.index = pd.DatetimeIndex(crimes_count...
0
0
0
0
0
0
0
0
0
29d2e41188a0da558bc18421bb19c9f3e24ccafc
199
py
Python
apps/categories/urls.py
ressapanda/fishka-backend
c1eb58566dce01c7a011f0093893cd16b6d50875
[ "MIT" ]
null
null
null
apps/categories/urls.py
ressapanda/fishka-backend
c1eb58566dce01c7a011f0093893cd16b6d50875
[ "MIT" ]
null
null
null
apps/categories/urls.py
ressapanda/fishka-backend
c1eb58566dce01c7a011f0093893cd16b6d50875
[ "MIT" ]
null
null
null
from rest_framework import routers from apps.categories.views import CategoryViewSet router = routers.SimpleRouter() router.register(r"", CategoryViewSet, "categories") urlpatterns = router.urls
19.9
51
0.809045
from rest_framework import routers from apps.categories.views import CategoryViewSet router = routers.SimpleRouter() router.register(r"", CategoryViewSet, "categories") urlpatterns = router.urls
0
0
0
0
0
0
0
0
0
67fd0980e8bfd9e6fdcb6df4ed1cfde8f1348929
2,515
py
Python
aliyun-python-sdk-dybaseapi/aliyunsdkdybaseapi/mns/mns_request.py
yndu13/aliyun-openapi-python-sdk
12ace4fb39fe2fb0e3927a4b1b43ee4872da43f5
[ "Apache-2.0" ]
1,001
2015-07-24T01:32:41.000Z
2022-03-25T01:28:18.000Z
aliyun-python-sdk-dybaseapi/aliyunsdkdybaseapi/mns/mns_request.py
yndu13/aliyun-openapi-python-sdk
12ace4fb39fe2fb0e3927a4b1b43ee4872da43f5
[ "Apache-2.0" ]
363
2015-10-20T03:15:00.000Z
2022-03-08T12:26:19.000Z
aliyun-python-sdk-dybaseapi/aliyunsdkdybaseapi/mns/mns_request.py
yndu13/aliyun-openapi-python-sdk
12ace4fb39fe2fb0e3927a4b1b43ee4872da43f5
[ "Apache-2.0" ]
682
2015-09-22T07:19:02.000Z
2022-03-22T09:51:46.000Z
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
29.940476
87
0.686282
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
0
0
0
1,540
0
0
0
0
161
9a541e688037965d295b83fe7772fcef39af44d0
1,006
py
Python
src/server.py
CaC-Grupo-9/backend
107067d8bc13ee2ba28c9c1a8bd0b19a4cf55277
[ "MIT" ]
1
2021-12-03T16:10:27.000Z
2021-12-03T16:10:27.000Z
src/server.py
CaC-Grupo-9/backend
107067d8bc13ee2ba28c9c1a8bd0b19a4cf55277
[ "MIT" ]
null
null
null
src/server.py
CaC-Grupo-9/backend
107067d8bc13ee2ba28c9c1a8bd0b19a4cf55277
[ "MIT" ]
5
2021-11-15T23:30:05.000Z
2021-11-30T13:10:59.000Z
from http.server import HTTPServer with HTTPServer(('', 8000), handler) as server: server.serve_forever()
35.928571
94
0.643141
from http.server import BaseHTTPRequestHandler from http.server import HTTPServer import os class handler(BaseHTTPRequestHandler): def do_GET(self): self.send_response(200) self.send_header('Content-type','application/json') self.end_headers() script_dir = os.path.dirname(__file__) ...
0
0
0
816
0
0
0
13
67
ab789c35e7c93cf4d2515dde51e2bcb17301e2fa
2,187
py
Python
encryt_by_Caesar_cipher.py
Glenn-Po/LearningPython
96b12999d13b55216a3da6cf6b9248a8e86cbe0b
[ "Apache-2.0" ]
null
null
null
encryt_by_Caesar_cipher.py
Glenn-Po/LearningPython
96b12999d13b55216a3da6cf6b9248a8e86cbe0b
[ "Apache-2.0" ]
null
null
null
encryt_by_Caesar_cipher.py
Glenn-Po/LearningPython
96b12999d13b55216a3da6cf6b9248a8e86cbe0b
[ "Apache-2.0" ]
null
null
null
#implement caesar's cipher #it is well simple to implement and it uses the idea of ASCII character codes #Note that in Python,characters are encoded in UNICODE by default #The idea behind this encryption is to shift indvidual x-ters in a string(message) by a certain number(the key) #White spaces are not encrypted i...
37.067797
111
0.589392
#implement caesar's cipher #it is well simple to implement and it uses the idea of ASCII character codes #Note that in Python,characters are encoded in UNICODE by default #The idea behind this encryption is to shift indvidual x-ters in a string(message) by a certain number(the key) #White spaces are not encrypted fr...
0
0
0
0
0
1,647
0
87
92
b52f9d37fe6b32f6785b7f5f9cf9060cea6cecf0
4,138
py
Python
site-generator/generate.py
kleutzinger/kleutzinger.github.io
ceb3d78d918e44a0636b11cfb923a116781f6363
[ "MIT" ]
1
2016-01-11T06:50:37.000Z
2016-01-11T06:50:37.000Z
site-generator/generate.py
kleutzinger/kleutzinger.github.io
ceb3d78d918e44a0636b11cfb923a116781f6363
[ "MIT" ]
1
2021-06-02T04:11:08.000Z
2021-06-02T04:11:08.000Z
site-generator/generate.py
kleutzinger/kleutzinger.github.io
ceb3d78d918e44a0636b11cfb923a116781f6363
[ "MIT" ]
null
null
null
import time import os import dominate from dominate.util import raw from prettify import html_prettify import ingest def gen_tags(project): "display tags over picture when card is hovered" tag_list = project.get("technologies", "") if tag_list == "": return "" tag_list = tag_list.split(",") ...
27.959459
93
0.594732
import datetime import time import os from markdown import markdown import dominate import sass from dominate.tags import * from dominate.util import raw from prettify import html_prettify import ingest def generate_css(): with open("card.scss") as f: uncompiled = f.read() compiled = sass.compile(...
0
0
0
0
0
1,135
0
-2
207
92e4a26b450f124c1a796965f61aeab928387856
7,427
py
Python
tests/core/data/test_transforms.py
Site-Command/lightning-flash
bfff08ded9cf193cce1cd16e7034d8005de172ae
[ "Apache-2.0" ]
1
2021-06-01T09:59:03.000Z
2021-06-01T09:59:03.000Z
tests/core/data/test_transforms.py
Site-Command/lightning-flash
bfff08ded9cf193cce1cd16e7034d8005de172ae
[ "Apache-2.0" ]
null
null
null
tests/core/data/test_transforms.py
Site-Command/lightning-flash
bfff08ded9cf193cce1cd16e7034d8005de172ae
[ "Apache-2.0" ]
null
null
null
# Copyright The PyTorch Lightning team. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to i...
34.705607
110
0.569678
# Copyright The PyTorch Lightning team. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to i...
0
5,710
0
1
0
652
0
136
280
b46e8e2aacdd145262f76dc3ea2ddc2a0d8354ca
873
bzl
Python
rules.bzl
DataDog/bazel-mypy-integration
b35f54dcb68db4edc98826c2dc831665e566fc5c
[ "MIT" ]
59
2019-12-02T11:06:55.000Z
2022-01-23T00:39:20.000Z
rules.bzl
DataDog/bazel-mypy-integration
b35f54dcb68db4edc98826c2dc831665e566fc5c
[ "MIT" ]
38
2019-12-08T05:51:32.000Z
2022-03-28T21:24:19.000Z
rules.bzl
DataDog/bazel-mypy-integration
b35f54dcb68db4edc98826c2dc831665e566fc5c
[ "MIT" ]
28
2020-02-11T02:28:17.000Z
2022-03-31T02:34:21.000Z
MyPyStubsInfo = provider( fields = { "srcs": ".pyi stub files", }, ) mypy_stubs = rule( implementation = _mypy_stubs_impl, attrs = { "srcs": attr.label_list( allow_empty = False, mandatory = True, doc = "TODO(Jonathon)", allow_files = [".p...
23.594595
60
0.539519
MyPyStubsInfo = provider( fields = { "srcs": ".pyi stub files", }, ) def _mypy_stubs_impl(ctx): pyi_srcs = [] for target in ctx.attr.srcs: pyi_srcs.extend(target.files.to_list()) transitive_srcs = depset(direct = pyi_srcs) return [ MyPyStubsInfo( srcs = ctx....
0
0
0
0
0
504
0
0
23
4c3c26fd6d7f8c7c96dd471cbbf5a45a7d7e4c61
60,553
py
Python
cogs/clan_battle.py
hibibol/clanbattle-management
89a8041ed26e5fc1ca117534737516e58fd77583
[ "MIT" ]
1
2021-06-07T21:11:05.000Z
2021-06-07T21:11:05.000Z
cogs/clan_battle.py
hibibol/clanbattle-management
89a8041ed26e5fc1ca117534737516e58fd77583
[ "MIT" ]
4
2021-07-05T12:58:30.000Z
2021-08-06T11:18:11.000Z
cogs/clan_battle.py
hibibol/clanbattle-management
89a8041ed26e5fc1ca117534737516e58fd77583
[ "MIT" ]
null
null
null
from logging import getLogger logger = getLogger(__name__)
42.854211
156
0.623817
import asyncio from collections import defaultdict from datetime import datetime, timedelta from functools import reduce from logging import getLogger from typing import List, Optional, Tuple from operator import sub import discord from discord import colour from discord.channel import TextChannel from discord.errors ...
8,643
29,344
19,940
6,618
0
44
0
1,001
664
406ac3a0994759eb44a396f798b588513f0a2419
30,236
py
Python
pysnmp-with-texts/Juniper-IP-PROFILE-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
8
2019-05-09T17:04:00.000Z
2021-06-09T06:50:51.000Z
pysnmp-with-texts/Juniper-IP-PROFILE-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
4
2019-05-31T16:42:59.000Z
2020-01-31T21:57:17.000Z
pysnmp-with-texts/Juniper-IP-PROFILE-MIB.py
agustinhenze/mibs.snmplabs.com
1fc5c07860542b89212f4c8ab807057d9a9206c7
[ "Apache-2.0" ]
10
2019-04-30T05:51:36.000Z
2022-02-16T03:33:41.000Z
# # PySNMP MIB module Juniper-IP-PROFILE-MIB (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/Juniper-IP-PROFILE-MIB # Produced by pysmi-0.3.4 at Wed May 1 14:03:04 2019 # On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4 # Using Python version 3.7.3 (d...
179.97619
2,142
0.789489
# # PySNMP MIB module Juniper-IP-PROFILE-MIB (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/Juniper-IP-PROFILE-MIB # Produced by pysmi-0.3.4 at Wed May 1 14:03:04 2019 # On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4 # Using Python version 3.7.3 (d...
0
0
0
0
0
0
0
0
0
11f91dae0c7b880aa4315bbca353b562a60d8179
11,279
py
Python
tfsnippet/utils/reuse.py
haowen-xu/tfsnippet-pre-alpha
31eb2cf692ac25b95cc815aaca53754d6db42d9f
[ "MIT" ]
null
null
null
tfsnippet/utils/reuse.py
haowen-xu/tfsnippet-pre-alpha
31eb2cf692ac25b95cc815aaca53754d6db42d9f
[ "MIT" ]
null
null
null
tfsnippet/utils/reuse.py
haowen-xu/tfsnippet-pre-alpha
31eb2cf692ac25b95cc815aaca53754d6db42d9f
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import inspect import functools import weakref import six __all__ = [ 'auto_reuse_variables', 'local_reuse', 'global_reuse', 'instance_reuse', ] #: dict to track the initialization state for each variable scope #: belonging to every living graph. __auto_reuse_variables_graph_dict = weakr...
33.769461
79
0.620534
# -*- coding: utf-8 -*- import inspect import functools import weakref from contextlib import contextmanager import six import tensorflow as tf from .scope import reopen_variable_scope, root_variable_scope __all__ = [ 'auto_reuse_variables', 'local_reuse', 'global_reuse', 'instance_reuse', ] @contextmanager de...
0
3,972
0
0
0
0
0
58
171
2be175cce772400eb717edef1cda536954ea7271
13,316
py
Python
tools/train_net.py
donghongwen/SSM
d0ef9fca75240ec2c0e15b2e26f78e19f2f6afc7
[ "MIT" ]
3
2019-11-01T11:50:43.000Z
2021-05-07T07:26:51.000Z
tools/train_net.py
donghongwen/SSM
d0ef9fca75240ec2c0e15b2e26f78e19f2f6afc7
[ "MIT" ]
null
null
null
tools/train_net.py
donghongwen/SSM
d0ef9fca75240ec2c0e15b2e26f78e19f2f6afc7
[ "MIT" ]
null
null
null
#!/usr/bin/env python # -------------------------------------------------------- # Fast R-CNN # Copyright (c) 2015 Microsoft # Licensed under The MIT License [see LICENSE for details] # Written by Ross Girshick # -------------------------------------------------------- """Train a Fast R-CNN network on a region of int...
42.954839
194
0.591018
#!/usr/bin/env python # -------------------------------------------------------- # Fast R-CNN # Copyright (c) 2015 Microsoft # Licensed under The MIT License [see LICENSE for details] # Written by Ross Girshick # -------------------------------------------------------- """Train a Fast R-CNN network on a region of int...
0
0
0
0
0
875
0
3
67
c595589da7b4d85ae7c0668163c3f9ca736b61d6
3,600
py
Python
storops/vnx/resource/cifs_server.py
tunaruraul/storops
7092c516c55b4c2f00c7c22383e1ad46ecfec091
[ "Apache-2.0" ]
60
2016-04-18T23:42:10.000Z
2022-03-23T02:26:03.000Z
storops/vnx/resource/cifs_server.py
tunaruraul/storops
7092c516c55b4c2f00c7c22383e1ad46ecfec091
[ "Apache-2.0" ]
317
2016-05-25T06:45:37.000Z
2022-03-25T13:22:38.000Z
storops/vnx/resource/cifs_server.py
tunaruraul/storops
7092c516c55b4c2f00c7c22383e1ad46ecfec091
[ "Apache-2.0" ]
34
2016-03-18T02:39:12.000Z
2022-01-07T12:54:14.000Z
# coding=utf-8 # Copyright (c) 2015 EMC Corporation. # 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 # #...
33.962264
79
0.655556
# coding=utf-8 # Copyright (c) 2015 EMC Corporation. # 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 # #...
0
1,090
0
1,553
0
0
0
76
114
f786169a8c203fe08bb2f78833d9abf361b486f1
1,023
py
Python
examples/dags/spark_example.py
FreeUniDataEngineering/airflow-spark2.4-hue-hive
031d7f9d90ace6f4f5cfe6ae2f2998ec8b53edbe
[ "Apache-2.0" ]
null
null
null
examples/dags/spark_example.py
FreeUniDataEngineering/airflow-spark2.4-hue-hive
031d7f9d90ace6f4f5cfe6ae2f2998ec8b53edbe
[ "Apache-2.0" ]
null
null
null
examples/dags/spark_example.py
FreeUniDataEngineering/airflow-spark2.4-hue-hive
031d7f9d90ace6f4f5cfe6ae2f2998ec8b53edbe
[ "Apache-2.0" ]
null
null
null
from datetime import datetime from airflow.models import DAG from airflow.providers.apache.spark.operators.spark_submit import SparkSubmitOperator import os with DAG( dag_id='spark_test', schedule_interval=None, start_date=datetime(2021, 1, 1), catchup=False, tags=['FreeUni'], ) as d...
33
104
0.72825
from datetime import datetime from airflow.models import DAG from airflow.providers.apache.spark.operators.spark_jdbc import SparkJDBCOperator from airflow.providers.apache.spark.operators.spark_sql import SparkSqlOperator from airflow.providers.apache.spark.operators.spark_submit import SparkSubmitOperator im...
0
0
0
0
0
0
0
118
46
fdd34b5cf650058e67e9c8f00cb7ffdbcaddec58
4,235
py
Python
tests/test_help_mixin.py
TheFriendlyCoder/FriendlyShell
8508c09e787cb8f0fc44c2a9e2587e8d4eec555c
[ "Apache-2.0" ]
null
null
null
tests/test_help_mixin.py
TheFriendlyCoder/FriendlyShell
8508c09e787cb8f0fc44c2a9e2587e8d4eec555c
[ "Apache-2.0" ]
93
2018-04-21T01:03:06.000Z
2019-06-23T14:22:37.000Z
tests/test_help_mixin.py
TheFriendlyCoder/FriendlyShell
8508c09e787cb8f0fc44c2a9e2587e8d4eec555c
[ "Apache-2.0" ]
null
null
null
import pytest if __name__ == "__main__": pytest.main([__file__, "-v", "-s"])
29.006849
65
0.661865
import logging from friendlyshell.base_shell import BaseShell from friendlyshell.shell_help_mixin import ShellHelpMixin from friendlyshell.basic_logger_mixin import BasicLoggerMixin from mock import patch import pytest def test_list_commands(caplog): caplog.set_level(logging.INFO) class MyShell (BasicLoggerMi...
0
0
0
1,022
0
2,713
0
95
317