hexsha
stringlengths
40
40
size
int64
3
1.03M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
3
972
max_stars_repo_name
stringlengths
6
130
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
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
3
972
max_issues_repo_name
stringlengths
6
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
3
972
max_forks_repo_name
stringlengths
6
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
3
1.03M
avg_line_length
float64
1.13
941k
max_line_length
int64
2
941k
alphanum_fraction
float64
0
1
09360c7382e6073b643a9b91447fbd6e39acfc99
17,535
py
Python
cisco-ios-xr/ydk/models/cisco_ios_xr/_meta/_Cisco_IOS_XR_wd_oper.py
tkamata-test/ydk-py
b637e7853a8edbbd31fbc05afa3aa4110b31c5f9
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
cisco-ios-xr/ydk/models/cisco_ios_xr/_meta/_Cisco_IOS_XR_wd_oper.py
tkamata-test/ydk-py
b637e7853a8edbbd31fbc05afa3aa4110b31c5f9
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
cisco-ios-xr/ydk/models/cisco_ios_xr/_meta/_Cisco_IOS_XR_wd_oper.py
tkamata-test/ydk-py
b637e7853a8edbbd31fbc05afa3aa4110b31c5f9
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
import re import collections from enum import Enum from ydk._core._dm_meta_info import _MetaInfoClassMember, _MetaInfoClass, _MetaInfoEnum from ydk.types import Empty, YList, YLeafList, DELETE, Decimal64, FixedBitsDict from ydk._core._dm_meta_info import ATTRIBUTE, REFERENCE_CLASS, REFERENCE_LIST, REFERENCE_LEAFLI...
47.137097
204
0.526889
883b5b4414a6855768c03f5b977f7577c602fa92
376
py
Python
stixcore/products/__init__.py
samaloney/STIXCore
ad9526cc37701aabcbe64bea249cb77d2313e5c6
[ "BSD-3-Clause" ]
1
2021-07-15T14:57:25.000Z
2021-07-15T14:57:25.000Z
stixcore/products/__init__.py
samaloney/STIXCore
ad9526cc37701aabcbe64bea249cb77d2313e5c6
[ "BSD-3-Clause" ]
null
null
null
stixcore/products/__init__.py
samaloney/STIXCore
ad9526cc37701aabcbe64bea249cb77d2313e5c6
[ "BSD-3-Clause" ]
null
null
null
from stixcore.products.level0.housekeeping import MaxiReport, MiniReport from stixcore.products.level0.quicklook import LightCurve from stixcore.products.level0.science import Aspect, CompressedPixelData, SummedPixelData from stixcore.products.level1.quicklook import LightCurve from stixcore.products.levelb.binary impo...
53.714286
89
0.875
d55ada538d789872c1ccdb9adeefbade05bcf7b9
12,535
py
Python
magenta/models/pianoroll_rnn_nade/pianoroll_rnn_nade_graph.py
vigliensoni/magenta
65166c2e97aac9e5b2e27b098ec95d3ec457d93e
[ "Apache-2.0" ]
1
2022-03-12T07:51:51.000Z
2022-03-12T07:51:51.000Z
magenta/models/pianoroll_rnn_nade/pianoroll_rnn_nade_graph.py
vigliensoni/magenta
65166c2e97aac9e5b2e27b098ec95d3ec457d93e
[ "Apache-2.0" ]
null
null
null
magenta/models/pianoroll_rnn_nade/pianoroll_rnn_nade_graph.py
vigliensoni/magenta
65166c2e97aac9e5b2e27b098ec95d3ec457d93e
[ "Apache-2.0" ]
null
null
null
# Copyright 2020 The Magenta Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in ...
36.123919
80
0.677463
298b38624757573e0992ccfa2a06299ab000f467
2,336
py
Python
python/graphscope/analytical/app/katz_centrality.py
wenyuanyu/GraphScope
a40ccaf70557e608d8b091eb25ab04477f99ce21
[ "Apache-2.0" ]
2
2020-12-15T08:42:10.000Z
2022-01-14T09:13:16.000Z
python/graphscope/analytical/app/katz_centrality.py
wenyuanyu/GraphScope
a40ccaf70557e608d8b091eb25ab04477f99ce21
[ "Apache-2.0" ]
1
2020-12-22T13:15:40.000Z
2020-12-22T13:15:40.000Z
python/graphscope/analytical/app/katz_centrality.py
wenyuanyu/GraphScope
a40ccaf70557e608d8b091eb25ab04477f99ce21
[ "Apache-2.0" ]
1
2021-11-23T03:40:43.000Z
2021-11-23T03:40:43.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Copyright 2020 Alibaba Group Holding Limited. 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...
35.393939
134
0.710188
e45a7bbe70e7b8614eb0c9109018644cf05fb490
24,654
py
Python
src/1-topicmodeling.py
sofieditmer/topic_modeling
edfff3c4d45c932562f796cc81e9ce9fe35f8e4b
[ "MIT" ]
null
null
null
src/1-topicmodeling.py
sofieditmer/topic_modeling
edfff3c4d45c932562f796cc81e9ce9fe35f8e4b
[ "MIT" ]
null
null
null
src/1-topicmodeling.py
sofieditmer/topic_modeling
edfff3c4d45c932562f796cc81e9ce9fe35f8e4b
[ "MIT" ]
null
null
null
#!/usr/bin/env python """ Info: This script performs topic modeling on the clean tweets by Donald Trump. The number of topics is estimated by computing coherence values for different number of topics, and an LDA model is constructed with the number of topics with the highest coherence value. Visualizations of the topic...
46.693182
402
0.626511
44ae0aa3db71362a8dc7cad9e93611a8744e2b24
13,418
py
Python
proj/notebooks/nb_utils.py
bbrighttaer/irelease
632e204436027fe30c2a3a22a1040fc0cd996a94
[ "MIT" ]
6
2020-08-17T21:59:25.000Z
2021-11-15T05:02:23.000Z
proj/notebooks/nb_utils.py
bbrighttaer/irelease
632e204436027fe30c2a3a22a1040fc0cd996a94
[ "MIT" ]
1
2021-05-10T07:50:28.000Z
2021-05-11T11:28:57.000Z
proj/notebooks/nb_utils.py
bbrighttaer/irelease
632e204436027fe30c2a3a22a1040fc0cd996a94
[ "MIT" ]
1
2020-12-21T12:07:49.000Z
2020-12-21T12:07:49.000Z
# Author: bbrighttaer # Project: irelease # Date: 6/25/2020 # Time: 6:51 AM # File: nb_utils.py from __future__ import absolute_import, division, print_function, unicode_literals import os import json import torch import torch.nn as nn import numpy as np from irelease.data import GeneratorData from irelease.model im...
44.430464
114
0.516247
3c0306a8c6e43cdacdd64da854b815bf958e4664
352
py
Python
mogua/types/blockchain_format/pool_target.py
vanthoi/mogua-blockchain
1e46ee2ee4fc98b87aede276608b3bd95971f05a
[ "Apache-2.0" ]
16
2021-08-01T14:29:14.000Z
2022-02-09T04:32:05.000Z
mogua/types/blockchain_format/pool_target.py
vanthoi/mogua-blockchain
1e46ee2ee4fc98b87aede276608b3bd95971f05a
[ "Apache-2.0" ]
18
2021-08-03T22:07:27.000Z
2022-02-03T11:08:42.000Z
mogua/types/blockchain_format/pool_target.py
vanthoi/mogua-blockchain
1e46ee2ee4fc98b87aede276608b3bd95971f05a
[ "Apache-2.0" ]
5
2021-09-13T10:23:35.000Z
2022-03-15T08:43:19.000Z
from dataclasses import dataclass from mogua.types.blockchain_format.sized_bytes import bytes32 from mogua.util.ints import uint32 from mogua.util.streamable import Streamable, streamable @dataclass(frozen=True) @streamable class PoolTarget(Streamable): puzzle_hash: bytes32 max_height: uint32 # A max height...
27.076923
69
0.809659
d5e06188010805db1c42c7dbd357b33698b07768
2,336
py
Python
workflows/sample_location_NON_FUNCTIONAL/example_sample_location.py
boutproject/VECMA-hackathon
07632a267fcaff582bf410eba13f7bc81d8ea6eb
[ "BSD-3-Clause" ]
2
2021-01-28T15:41:05.000Z
2021-02-21T07:40:22.000Z
workflows/sample_location_NON_FUNCTIONAL/example_sample_location.py
boutproject/VECMA-hackathon
07632a267fcaff582bf410eba13f7bc81d8ea6eb
[ "BSD-3-Clause" ]
4
2021-01-19T14:21:36.000Z
2021-01-21T20:00:29.000Z
workflows/sample_location_NON_FUNCTIONAL/example_sample_location.py
boutproject/VECMA-hackathon
07632a267fcaff582bf410eba13f7bc81d8ea6eb
[ "BSD-3-Clause" ]
2
2021-01-20T09:23:56.000Z
2021-02-23T09:55:51.000Z
#!/usr/bin/env python3 """ This example looks at time traces of temperature at two locations """ import boutvecma import easyvvuq as uq import chaospy import os import numpy as np import time import matplotlib.pyplot as plt campaign = uq.Campaign(name="Conduction.") encoder = boutvecma.BOUTEncoder(template_input="...
26.850575
88
0.676798
10a8129d81c937479a81f593a8b49ede6d51e8ae
15,190
py
Python
dataloader.py
KaidongLi/ApolloOne
397a8fc49c0609e543a0b0a2d8c26933545fda12
[ "Apache-2.0" ]
null
null
null
dataloader.py
KaidongLi/ApolloOne
397a8fc49c0609e543a0b0a2d8c26933545fda12
[ "Apache-2.0" ]
null
null
null
dataloader.py
KaidongLi/ApolloOne
397a8fc49c0609e543a0b0a2d8c26933545fda12
[ "Apache-2.0" ]
null
null
null
from __future__ import print_function, division import sys import os import torch import numpy as np import random import csv from torch.utils.data import Dataset, DataLoader from torchvision import transforms, utils from torch.utils.data.sampler import Sampler from pycocotools.coco import COCO import skimage.io imp...
32.878788
143
0.580843
89548100789771845287477c9a3ef1efdd85f00f
1,158
py
Python
setup.py
semuadmin/sandpit
929c31de69a5c75a3131c69413ccac8f3cd75b28
[ "BSD-3-Clause" ]
null
null
null
setup.py
semuadmin/sandpit
929c31de69a5c75a3131c69413ccac8f3cd75b28
[ "BSD-3-Clause" ]
5
2021-03-23T07:50:36.000Z
2021-04-20T11:18:13.000Z
setup.py
semuadmin/sandpit
929c31de69a5c75a3131c69413ccac8f3cd75b28
[ "BSD-3-Clause" ]
1
2021-03-23T08:02:25.000Z
2021-03-23T08:02:25.000Z
''' Created on 19 Dec 2020 @author: semuadmin ''' import setuptools from sandpit import version as VERSION with open("README.md", "r") as fh: long_description = fh.read() setuptools.setup( name="sandpit", version=VERSION, author="semuadmin", author_email="semuadmin@semuconsulting.com", descr...
28.243902
66
0.648532
5f389f2be22f08481583af2bd8d4705c44edb233
6,769
py
Python
controller.py
Syed-Sherjeel/NFST_Driverless_2019
b65aceae7f14ab097f87292adccd603f270d4a26
[ "MIT" ]
39
2020-04-27T12:15:54.000Z
2022-03-02T15:44:58.000Z
controller.py
Syed-Sherjeel/NFST_Driverless_2019
b65aceae7f14ab097f87292adccd603f270d4a26
[ "MIT" ]
null
null
null
controller.py
Syed-Sherjeel/NFST_Driverless_2019
b65aceae7f14ab097f87292adccd603f270d4a26
[ "MIT" ]
13
2020-05-03T20:42:38.000Z
2021-04-27T21:33:03.000Z
from time import time import numpy as np from constants import STEER_MAX, STEER_MIN, DEFAULT_ANGLE, HALF_CAR_WIDTH, FRONT_DISTANCE from math import atan2, degrees, hypot ######## General functions ######## def angle_to_point(point): angle = -degrees(atan2(point[1],point[0])) return angle def sort_cones(cone...
29.951327
123
0.583543
f553efb0e13d5301cd694408558503996b783be7
9,458
py
Python
web_app/fta_solutions_app/admin.py
mycyzs/fta
a50a3c498c39b14e7df4a0a960c2a1499b1ec6bb
[ "Apache-2.0" ]
null
null
null
web_app/fta_solutions_app/admin.py
mycyzs/fta
a50a3c498c39b14e7df4a0a960c2a1499b1ec6bb
[ "Apache-2.0" ]
null
null
null
web_app/fta_solutions_app/admin.py
mycyzs/fta
a50a3c498c39b14e7df4a0a960c2a1499b1ec6bb
[ "Apache-2.0" ]
2
2020-02-12T03:59:28.000Z
2021-05-27T05:34:01.000Z
# coding=utf-8 """ Tencent is pleased to support the open source community by making 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available. Copyright (C) 2017-2018 THL A29 Limited, a Tencent company. All rights reserved. Licensed under the MIT License (the "License"); you may not use this file except in compliance ...
38.921811
305
0.727004
7406368a4c5116c994a03e6d963deaa4ef492880
4,390
py
Python
test/functional/p2p_zpos_fakestake_accepted.py
sharkcoin32/Sharkcoin
0ef5bba96df4abe51436856e2d0b12be86cabf6b
[ "MIT" ]
2
2020-12-09T23:44:18.000Z
2021-04-16T01:08:04.000Z
test/functional/p2p_zpos_fakestake_accepted.py
sharkcoin32/Sharkcoin
0ef5bba96df4abe51436856e2d0b12be86cabf6b
[ "MIT" ]
null
null
null
test/functional/p2p_zpos_fakestake_accepted.py
sharkcoin32/Sharkcoin
0ef5bba96df4abe51436856e2d0b12be86cabf6b
[ "MIT" ]
1
2020-12-09T23:44:25.000Z
2020-12-09T23:44:25.000Z
#!/usr/bin/env python3 # Copyright (c) 2019 The PIVX developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. ''' Performs the same check as in Test_02 verifying that zPoS forked blocks that stake a zerocoin which is spent on ma...
37.20339
189
0.620046
2801b17b68a0970f58168fc4dcf08bfa361a803d
6,755
py
Python
InternalPythonModules/android/zapya.py
ljmf00/autopsy
34a980b7fc7ea47287e7101f5bba6cb1b518bc7b
[ "Apache-2.0" ]
13
2020-11-16T12:30:48.000Z
2021-02-10T15:00:14.000Z
InternalPythonModules/android/zapya.py
ljmf00/autopsy
34a980b7fc7ea47287e7101f5bba6cb1b518bc7b
[ "Apache-2.0" ]
1
2019-12-05T14:10:20.000Z
2019-12-05T14:10:20.000Z
InternalPythonModules/android/zapya.py
ljmf00/autopsy
34a980b7fc7ea47287e7101f5bba6cb1b518bc7b
[ "Apache-2.0" ]
5
2019-10-08T04:48:19.000Z
2019-11-22T04:29:12.000Z
""" Autopsy Forensic Browser Copyright 2019-2020 Basis Technology Corp. Contact: carrier <at> sleuthkit <dot> org 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...
49.669118
170
0.617617
4aac4264d22e4ff7798c292a5e2c6d8ef89d697d
10,319
py
Python
astropy_helpers/commands/build_sphinx.py
bsipocz/astropy-helpers
4999df1cfb6a5022347b0cef9caf8a556517c625
[ "PSF-2.0", "BSD-2-Clause", "BSD-3-Clause" ]
9
2019-12-06T13:12:33.000Z
2021-10-05T12:47:15.000Z
astropy_helpers/commands/build_sphinx.py
bsipocz/astropy-helpers
4999df1cfb6a5022347b0cef9caf8a556517c625
[ "PSF-2.0", "BSD-2-Clause", "BSD-3-Clause" ]
2
2019-11-28T17:20:27.000Z
2019-12-09T18:44:35.000Z
astropy_helpers/commands/build_sphinx.py
bsipocz/astropy-helpers
4999df1cfb6a5022347b0cef9caf8a556517c625
[ "PSF-2.0", "BSD-2-Clause", "BSD-3-Clause" ]
3
2019-11-28T17:04:22.000Z
2021-10-19T13:12:34.000Z
from __future__ import print_function import inspect import os import pkgutil import re import shutil import subprocess import sys import textwrap import warnings from distutils import log from distutils.cmd import DistutilsOptionError import sphinx from sphinx.setup_command import BuildDoc as SphinxBuildDoc from ....
40.466667
79
0.593662
a044cac11ea3b3651ae6225b14184a9604009d2e
1,295
py
Python
mtpow/__init__.py
gynt/MerkleTreePOW
7c1b9c77223efdfe0c715190d50a6982d2dc4090
[ "MIT" ]
null
null
null
mtpow/__init__.py
gynt/MerkleTreePOW
7c1b9c77223efdfe0c715190d50a6982d2dc4090
[ "MIT" ]
null
null
null
mtpow/__init__.py
gynt/MerkleTreePOW
7c1b9c77223efdfe0c715190d50a6982d2dc4090
[ "MIT" ]
null
null
null
import mtpow.cache import mtpow.tree import mtpow.hash import mtpow.util import mtpow.proof import mtpow.validation import mtpow.selection import mtpow.measurement def default_generator(desc, depth, leaves): gen=proof.ProofGenerator( proof.ProofParameters( selection.TreeBasedSelector( ...
30.116279
73
0.524324
a84b2de5ec1e7b4f20708d50eba77a32cc6050c0
2,080
py
Python
c7n/resources/simpledb.py
sstarcher/cloud-custodian
fc5b51019e9c15d0582089133d080bceee489a94
[ "Apache-2.0" ]
1
2018-06-27T14:51:12.000Z
2018-06-27T14:51:12.000Z
c7n/resources/simpledb.py
sstarcher/cloud-custodian
fc5b51019e9c15d0582089133d080bceee489a94
[ "Apache-2.0" ]
2
2018-05-08T23:39:01.000Z
2018-05-14T16:53:43.000Z
c7n/resources/simpledb.py
sstarcher/cloud-custodian
fc5b51019e9c15d0582089133d080bceee489a94
[ "Apache-2.0" ]
2
2019-11-22T14:54:28.000Z
2021-06-18T13:49:15.000Z
# Copyright 2016-2017 Capital One Services, LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed ...
33.548387
82
0.687019
c36652661ad56c58f230b08f3e18afa70e6d3d93
6,007
py
Python
src/dispatch/report/messaging.py
trinhth2601/dispatch
de736295950ffbf3c55e6d3940fc3d87b82f14a5
[ "Apache-2.0" ]
null
null
null
src/dispatch/report/messaging.py
trinhth2601/dispatch
de736295950ffbf3c55e6d3940fc3d87b82f14a5
[ "Apache-2.0" ]
null
null
null
src/dispatch/report/messaging.py
trinhth2601/dispatch
de736295950ffbf3c55e6d3940fc3d87b82f14a5
[ "Apache-2.0" ]
null
null
null
import logging from datetime import datetime, timedelta from dispatch.conversation.enums import ConversationCommands from dispatch.database import SessionLocal, resolve_attr from dispatch.incident import service as incident_service from dispatch.incident.models import Incident from dispatch.messaging.strings import (...
34.130682
105
0.720659
1853cad2ae0f7ea6f2306c4b7cb290d88b9ce941
2,538
py
Python
utils/mertrics_parser.py
iyuvalk/pensu
66a5ccd72712d04af8221505e775422d24d03a91
[ "MIT" ]
null
null
null
utils/mertrics_parser.py
iyuvalk/pensu
66a5ccd72712d04af8221505e775422d24d03a91
[ "MIT" ]
null
null
null
utils/mertrics_parser.py
iyuvalk/pensu
66a5ccd72712d04af8221505e775422d24d03a91
[ "MIT" ]
null
null
null
import base64 import stats_mgr import config_mgr import utils.logger class MetricsParser: def __init__(self): self._config_mgr = config_mgr.ConfigMgr.get_instance() self._stats_mgr = stats_mgr.StatsMgr.get_instance(__file__) self._logger = utils.logger.Logger(__file__, "MetricsParser") ...
54
227
0.640662
e784315f383d8a0c8b50fdca4b35bf05d69145d1
9,802
py
Python
lib/tests/test_transaction.py
schancel/electrum
ee125e0723a9345757b741aed93be906af80d327
[ "MIT" ]
1
2020-05-24T08:50:13.000Z
2020-05-24T08:50:13.000Z
lib/tests/test_transaction.py
Santobak/electrum
ee125e0723a9345757b741aed93be906af80d327
[ "MIT" ]
null
null
null
lib/tests/test_transaction.py
Santobak/electrum
ee125e0723a9345757b741aed93be906af80d327
[ "MIT" ]
1
2017-12-22T03:57:04.000Z
2017-12-22T03:57:04.000Z
import unittest from lib import transaction from lib import bitcoin from lib.bitcoin import TYPE_ADDRESS, set_testnet from sample_tx import sample_tx_mainnet, sample_tx_testnet import pprint from lib.keystore import xpubkey_to_address v2_blob = "0200000001191601a44a81e061502b7bfbc6eaa1cef6d1e6af5308ef96c9342f71dbf4b9...
40.841667
464
0.655376
79a18217cfada54b0139ad4b1aea31f44da8eae0
27,795
py
Python
autogluon/task/tabular_prediction/tabular_prediction.py
zhanghang1989/autogluon
8bfe6b0da8915020eeb9895fd18d7688c0d604c1
[ "Apache-2.0" ]
null
null
null
autogluon/task/tabular_prediction/tabular_prediction.py
zhanghang1989/autogluon
8bfe6b0da8915020eeb9895fd18d7688c0d604c1
[ "Apache-2.0" ]
null
null
null
autogluon/task/tabular_prediction/tabular_prediction.py
zhanghang1989/autogluon
8bfe6b0da8915020eeb9895fd18d7688c0d604c1
[ "Apache-2.0" ]
null
null
null
import copy, logging, math import numpy as np from .dataset import TabularDataset from .predictor import TabularPredictor from ..base import BaseTask from ..base.base_task import schedulers from ...utils.tabular.ml.learner.default_learner import DefaultLearner as Learner from ...utils.tabular.ml.trainer.auto_trainer i...
72.952756
210
0.682749
9a5194f1553f23f4c460ea45b9a00132e06e6b1d
768
py
Python
04-writing-structured-programs/util/renamer.py
SolangeUG/nltk-book
05051325a64836ae5c89d18f3c2145e9a6c4f0ae
[ "Apache-2.0" ]
2
2018-08-05T15:50:12.000Z
2019-01-24T05:52:02.000Z
04-writing-structured-programs/util/renamer.py
SolangeUG/nltk-book
05051325a64836ae5c89d18f3c2145e9a6c4f0ae
[ "Apache-2.0" ]
null
null
null
04-writing-structured-programs/util/renamer.py
SolangeUG/nltk-book
05051325a64836ae5c89d18f3c2145e9a6c4f0ae
[ "Apache-2.0" ]
null
null
null
import os import os.path def rename_files(directory_name, base_filename): """ Rename files in the given directory :param directory_name: input directory :param base_filename: base string for the new filename :return: None """ count = 0 for file in os.listdir(directory_name): co...
24.774194
79
0.617188
1a281614ac4de95b46188a6ea4281dd8196487cc
21,830
py
Python
drain/drain.py
MrManPew/plugins
abbdeabec6504b1f1771473296b7656f53293723
[ "BSD-3-Clause" ]
2
2021-04-11T22:00:35.000Z
2021-07-09T19:07:23.000Z
drain/drain.py
svewa/plugins
388469ba331ade4dec8e0bcc10f8f24ea48ec4ca
[ "BSD-3-Clause" ]
null
null
null
drain/drain.py
svewa/plugins
388469ba331ade4dec8e0bcc10f8f24ea48ec4ca
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python3 from pyln.client import Plugin, Millisatoshi, RpcError from utils import get_ours, wait_ours import re import time import uuid plugin = Plugin() # When draining 100% we must account (not pay) for an additional HTLC fee. # Currently there is no way of getting the exact number before the fact, #...
46.054852
181
0.617774
6dba3afde495302cfebe38acc5f51c00c83c4d46
6,969
py
Python
models/augmentation.py
xmu-xiaoma666/SDATR
44560ff70f859a46fee94ddc401b19016fb5a411
[ "MIT" ]
4
2022-03-25T05:57:41.000Z
2022-03-29T08:46:31.000Z
models/augmentation.py
xmu-xiaoma666/SDATR
44560ff70f859a46fee94ddc401b19016fb5a411
[ "MIT" ]
null
null
null
models/augmentation.py
xmu-xiaoma666/SDATR
44560ff70f859a46fee94ddc401b19016fb5a411
[ "MIT" ]
null
null
null
import torch import numpy as np from torch._C import dtype from torch import nn from torch.nn import functional as F from torchvision import transforms from torchvision.transforms import functional as TF class ImageAugmentation(): def __init__(self): super().__init__() """ PepperSaltNoise ...
30.700441
90
0.547855
17d9852ce978e7250eb2b3e6b073de06a5e52941
1,133
py
Python
tests/core/helpers.py
eocdb/ocdb-server
0e28d092e8ecf5f4813878aab43de990cc5fb4ee
[ "MIT" ]
null
null
null
tests/core/helpers.py
eocdb/ocdb-server
0e28d092e8ecf5f4813878aab43de990cc5fb4ee
[ "MIT" ]
null
null
null
tests/core/helpers.py
eocdb/ocdb-server
0e28d092e8ecf5f4813878aab43de990cc5fb4ee
[ "MIT" ]
null
null
null
from ocdb.core.service import Service, ServiceInfo class TestServiceBase(Service): @classmethod def info(cls) -> ServiceInfo: return dict(name=cls.__name__) def __init__(self): self.value1 = None self.value2 = None self.num_inits = 0 self.num_updates = 0 se...
21.377358
58
0.627538
1cf7dda54ba664b2f99001dcfb6d7be9de3c1771
5,545
py
Python
driver/generic/xpt2046.py
littlevgl/lv_bindings
c09a58213b1c8e1246b9f5c68d94741dcda71108
[ "MIT" ]
2
2019-01-23T11:35:11.000Z
2019-01-29T03:35:35.000Z
driver/generic/xpt2046.py
littlevgl/lv_bindings
c09a58213b1c8e1246b9f5c68d94741dcda71108
[ "MIT" ]
3
2019-01-25T07:37:30.000Z
2019-01-29T09:35:40.000Z
driver/generic/xpt2046.py
littlevgl/lv_bindings
c09a58213b1c8e1246b9f5c68d94741dcda71108
[ "MIT" ]
2
2019-01-23T19:41:40.000Z
2019-01-24T06:38:42.000Z
# © 2022 Václav Šmilauer <eu@doxos.eu> # MIT-licensed import machine import struct # for inspiration see e.g. # https://github.com/MatthewLowden/RPi-XPT2046-Touchscreen-Python/blob/master/XPT2046.py # and the XPT2046 datasheet XPT2046_PORTRAIT = const(0) XPT2046_LANDSCAPE = const(1) XPT2046_INV_PORTRAIT = const(2) XP...
44.717742
323
0.65284
a1e2d6ae9349970ad3f89f88a9558b31bdccd9e6
1,704
py
Python
Lib/site-packages/wx-2.8-msw-unicode/wx/py/tests/test_pseudo.py
ekkipermana/robotframework-test
243ca26f69962f8cf20cd7d054e0ff3e709bc7f4
[ "bzip2-1.0.6" ]
27
2020-11-12T19:24:54.000Z
2022-03-27T23:10:45.000Z
Lib/site-packages/wx-2.8-msw-unicode/wx/py/tests/test_pseudo.py
ekkipermana/robotframework-test
243ca26f69962f8cf20cd7d054e0ff3e709bc7f4
[ "bzip2-1.0.6" ]
2
2020-11-02T06:30:39.000Z
2022-02-23T18:39:55.000Z
Lib/site-packages/wx-2.8-msw-unicode/wx/py/tests/test_pseudo.py
ekkipermana/robotframework-test
243ca26f69962f8cf20cd7d054e0ff3e709bc7f4
[ "bzip2-1.0.6" ]
7
2018-02-13T10:22:39.000Z
2019-07-04T07:39:28.000Z
#!/usr/bin/env python __author__ = "Patrick K. O'Brien <pobrien@orbtech.com>" __cvsid__ = "$Id: test_pseudo.py 24541 2003-11-12 21:34:20Z RD $" __revision__ = "$Revision: 24541 $"[11:-2] import unittest # Import from this module's parent directory. import os import sys sys.path.insert(0, os.pardir) import pseudo del...
20.780488
72
0.673122
f3b72e1ee4474d33ed013a995a08f536080ae6d0
10,793
py
Python
docs/conf.py
by-gramm/drf-yasg
effc8f2c06e66813a0ab5bad5a4478c0a8e1969c
[ "BSD-3-Clause" ]
2,788
2017-12-13T10:52:26.000Z
2022-03-30T13:00:14.000Z
docs/conf.py
by-gramm/drf-yasg
effc8f2c06e66813a0ab5bad5a4478c0a8e1969c
[ "BSD-3-Clause" ]
694
2017-12-15T11:33:16.000Z
2022-03-31T09:27:40.000Z
docs/conf.py
by-gramm/drf-yasg
effc8f2c06e66813a0ab5bad5a4478c0a8e1969c
[ "BSD-3-Clause" ]
427
2017-12-14T19:27:43.000Z
2022-03-28T04:22:42.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # drf-yasg documentation build configuration file, created by # sphinx-quickstart on Sun Dec 10 15:20:34 2017. import inspect import os import re import sys import sphinx_rtd_theme from docutils import nodes, utils from docutils.parsers.rst import roles from docutils.pa...
33.209231
118
0.679237
6e27a6acb50ba1aa5eb390dd6a3bf0c31b633a85
3,501
py
Python
keyring/backends/SecretService.py
ewjoachim/keyring
5a887c13c9033951e9a7ac2d356cecc0cd95963f
[ "MIT" ]
null
null
null
keyring/backends/SecretService.py
ewjoachim/keyring
5a887c13c9033951e9a7ac2d356cecc0cd95963f
[ "MIT" ]
null
null
null
keyring/backends/SecretService.py
ewjoachim/keyring
5a887c13c9033951e9a7ac2d356cecc0cd95963f
[ "MIT" ]
null
null
null
import logging import sys import os from ..util import properties from ..backend import KeyringBackend from ..errors import (InitError, PasswordDeleteError, ExceptionRaisedContext, KeyringLocked) try: import secretstorage import secretstorage.exceptions as exceptions except ImportError:...
35.72449
73
0.628963
4775897548f40a4a083911603663ffccf6dd1f67
2,628
py
Python
cron/build_chrom_db.py
tdans1/Use-Galaxy
e9f05cb1b11db20a729ac73520f886ee619c6b90
[ "CC-BY-3.0" ]
4
2018-10-29T18:34:38.000Z
2021-09-29T23:30:42.000Z
cron/build_chrom_db.py
tdans1/Use-Galaxy
e9f05cb1b11db20a729ac73520f886ee619c6b90
[ "CC-BY-3.0" ]
null
null
null
cron/build_chrom_db.py
tdans1/Use-Galaxy
e9f05cb1b11db20a729ac73520f886ee619c6b90
[ "CC-BY-3.0" ]
3
2020-02-12T15:22:24.000Z
2021-08-19T10:27:39.000Z
#!/usr/bin/env python """ Connects to a UCSC table browser and scrapes chrominfo for every build specified by an input file (such as one output by parse_builds.py). If not input file specified, it will connect using parse_builds.py to retrieve a list of available builds. All chromInfo is placed in a path with the conv...
31.662651
106
0.586377
9ca40f34a20f23062e48b411101e97af48f657f0
1,229
gyp
Python
binding.gyp
Rufilla/node-pcsclite
ca55ee820c212c6078e4a2458f887a317479f9fd
[ "0BSD" ]
null
null
null
binding.gyp
Rufilla/node-pcsclite
ca55ee820c212c6078e4a2458f887a317479f9fd
[ "0BSD" ]
null
null
null
binding.gyp
Rufilla/node-pcsclite
ca55ee820c212c6078e4a2458f887a317479f9fd
[ "0BSD" ]
null
null
null
{ 'targets': [ { 'target_name': 'pcsclite', 'sources': [ 'src/addon.cpp', 'src/pcsclite.cpp', 'src/cardreader.cpp' ], 'cflags': [ '-Wall', '-Wextra', '-Wno-unused-parameter', '-fPIC', '-fno-st...
32.342105
85
0.305126
b5dd50199d49520f5e4d53beec8074dcb1a3f707
1,012
py
Python
corehq/apps/announcements/crud.py
dslowikowski/commcare-hq
ad8885cf8dab69dc85cb64f37aeaf06106124797
[ "BSD-3-Clause" ]
1
2015-02-10T23:26:39.000Z
2015-02-10T23:26:39.000Z
corehq/apps/announcements/crud.py
SEL-Columbia/commcare-hq
992ee34a679c37f063f86200e6df5a197d5e3ff6
[ "BSD-3-Clause" ]
null
null
null
corehq/apps/announcements/crud.py
SEL-Columbia/commcare-hq
992ee34a679c37f063f86200e6df5a197d5e3ff6
[ "BSD-3-Clause" ]
null
null
null
import datetime from markdown import markdown from corehq.apps.crud.models import BaseAdminHQTabularCRUDManager class HQAnnouncementCRUDManager(BaseAdminHQTabularCRUDManager): """ CRUD Manager for HQ Announcements """ @property def properties_in_row(self): return ["title", "summary", "d...
37.481481
113
0.706522
777b548004bb6f25221badac3dfffaa602f4389a
9,314
py
Python
fuzzers/015-clb-nffmux/top.py
rw1nkler/prjxray
aff076b47dcf6d653eb3ce791b41fd6cf4343edd
[ "ISC" ]
583
2017-12-21T11:06:13.000Z
2022-02-20T21:27:33.000Z
fuzzers/015-clb-nffmux/top.py
rw1nkler/prjxray
aff076b47dcf6d653eb3ce791b41fd6cf4343edd
[ "ISC" ]
1,212
2017-12-22T15:05:06.000Z
2022-02-19T13:04:59.000Z
fuzzers/015-clb-nffmux/top.py
mfkiwl/prjxray-xilinx-7-bitstream-fortmat
5349556bc2c230801d6df0cf11bccb9cfd171639
[ "ISC" ]
134
2017-12-21T10:16:50.000Z
2022-02-16T06:42:04.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Copyright (C) 2017-2020 The Project X-Ray Authors. # # Use of this source code is governed by a ISC-style # license that can be found in the LICENSE file or at # https://opensource.org/licenses/ISC # # SPDX-License-Identifier: ISC import os, random random.seed(0) from...
25.517808
95
0.490874
ebd4477a9e631a17d2137bfc33dd6e8bf2a26ae3
475
py
Python
Python/fileio.py
BirendraRokaha/Learn2020
5da92b1947a266f009f9cd371dd6a03610b95c9b
[ "MIT" ]
null
null
null
Python/fileio.py
BirendraRokaha/Learn2020
5da92b1947a266f009f9cd371dd6a03610b95c9b
[ "MIT" ]
11
2021-04-08T19:55:39.000Z
2022-03-02T09:51:03.000Z
Python/fileio.py
BirendraRokaha/Learn2020
5da92b1947a266f009f9cd371dd6a03610b95c9b
[ "MIT" ]
null
null
null
#File I/O basics ''' file = open('test.txt') print(file.read()) ''' # open a file with open ('test.txt') as f: print(f.read()) # append in that file with open('test.txt', mode = 'a') as test: test.write('\nThis line is added form the python script') with open ('test.txt') as f: print(f.read()) #overwri...
18.269231
61
0.614737
125dfc42d1b3e13a8b924bbcf8f56537afaf8d61
18,671
py
Python
intake_stripe/_version.py
AlbertDeFusco/intake-stripe
5dff6cee23cfdf8f963d08b2e7c8130e31e697f8
[ "BSD-3-Clause" ]
null
null
null
intake_stripe/_version.py
AlbertDeFusco/intake-stripe
5dff6cee23cfdf8f963d08b2e7c8130e31e697f8
[ "BSD-3-Clause" ]
null
null
null
intake_stripe/_version.py
AlbertDeFusco/intake-stripe
5dff6cee23cfdf8f963d08b2e7c8130e31e697f8
[ "BSD-3-Clause" ]
1
2022-02-09T20:50:36.000Z
2022-02-09T20:50:36.000Z
# This file helps to compute a version number in source trees obtained from # git-archive tarball (such as those provided by githubs download-from-tag # feature). Distribution tarballs (built by setup.py sdist) and build # directories (produced by setup.py build) will contain a much shorter file # that just contains t...
35.496198
79
0.585668
a519ddba0b762257c2b3bc159d280750e7051332
406
py
Python
Day_35/pronic_number.py
kiranrraj/100Days_Of_Coding
ab75d83be9be87fb7bc83a3f3b72a4638dab22a1
[ "MIT" ]
null
null
null
Day_35/pronic_number.py
kiranrraj/100Days_Of_Coding
ab75d83be9be87fb7bc83a3f3b72a4638dab22a1
[ "MIT" ]
null
null
null
Day_35/pronic_number.py
kiranrraj/100Days_Of_Coding
ab75d83be9be87fb7bc83a3f3b72a4638dab22a1
[ "MIT" ]
null
null
null
# Title : Disarium number # Author : Kiran Raj R. # Date : 18/11/2020 def is_pronic(num): if num == 0 : print("Please enter a value higher than 0") return else: for i in range(1, num+1): if i * (i+1) == num: print(f"Pronic number: {num}") r...
23.882353
51
0.507389
a6d45ac8f61ffdc7911021c4c56279f8f8811c90
1,796
py
Python
endpoint/serve.py
HaoranLv/Shelf-product-identification
a821ea152246b55b940aa37b8095a1f50b147dd7
[ "Xnet", "X11" ]
null
null
null
endpoint/serve.py
HaoranLv/Shelf-product-identification
a821ea152246b55b940aa37b8095a1f50b147dd7
[ "Xnet", "X11" ]
null
null
null
endpoint/serve.py
HaoranLv/Shelf-product-identification
a821ea152246b55b940aa37b8095a1f50b147dd7
[ "Xnet", "X11" ]
null
null
null
from __future__ import print_function import multiprocessing import os import signal import subprocess import sys cpu_count = multiprocessing.cpu_count() model_server_timeout = os.environ.get('MODEL_SERVER_TIMEOUT', 60) #model_server_workers = int(os.environ.get('MODEL_SERVER_WORKERS', cpu_count)) model_server_worker...
31.508772
88
0.625278
0c69a197d40bc24d67ebc503a628e4aacf09283e
2,049
py
Python
RasPi_Dev/ros_ws/devel/lib/python2.7/dist-packages/opencv_apps/cfg/FindContoursConfig.py
QianheYu/xtark_driver_dev
1708888161cf20c0d1f45c99d0da4467d69c26c8
[ "BSD-3-Clause" ]
1
2022-03-11T03:31:15.000Z
2022-03-11T03:31:15.000Z
RasPi_Dev/ros_ws/devel/lib/python2.7/dist-packages/opencv_apps/cfg/FindContoursConfig.py
bravetree/xtark_driver_dev
1708888161cf20c0d1f45c99d0da4467d69c26c8
[ "BSD-3-Clause" ]
null
null
null
RasPi_Dev/ros_ws/devel/lib/python2.7/dist-packages/opencv_apps/cfg/FindContoursConfig.py
bravetree/xtark_driver_dev
1708888161cf20c0d1f45c99d0da4467d69c26c8
[ "BSD-3-Clause" ]
null
null
null
## ********************************************************* ## ## File autogenerated for the opencv_apps package ## by the dynamic_reconfigure package. ## Please do not edit. ## ## ********************************************************/ from dynamic_reconfigure.encoding import extract_params inf = float('inf') co...
55.378378
1,174
0.63592
1de2cc6dfe266748289c13d50710d73df11080f8
774
py
Python
main.py
saintic/flask-image-clipper-demo
eb8f8757e5acded71c8758adc32b8ebb33a0d9f7
[ "MIT" ]
4
2019-04-15T12:32:20.000Z
2022-01-17T20:19:03.000Z
main.py
saintic/flask-image-clipper-demo
eb8f8757e5acded71c8758adc32b8ebb33a0d9f7
[ "MIT" ]
null
null
null
main.py
saintic/flask-image-clipper-demo
eb8f8757e5acded71c8758adc32b8ebb33a0d9f7
[ "MIT" ]
1
2019-06-01T04:07:42.000Z
2019-06-01T04:07:42.000Z
# coding: utf8 import os, base64 from flask import Flask, render_template, request, jsonify app = Flask(__name__) #文件上传文件夹, 相对于项目根目录, 请勿改动static/部分 IMAGE_FOLDER = 'static' UPLOAD_FOLDER = os.path.join(os.path.dirname(os.path.abspath(__file__)), IMAGE_FOLDER) @app.route("/") def index(): return render_temp...
27.642857
89
0.665375
0f5e3d7a945f570becd3a380b76f34252949e73f
2,490
py
Python
second/utils/util.py
hankeceli/3D-Object-Detection-for-AV
b6c17a4a3ecc9c32418baafa5b82cfd4704ed880
[ "Apache-2.0" ]
null
null
null
second/utils/util.py
hankeceli/3D-Object-Detection-for-AV
b6c17a4a3ecc9c32418baafa5b82cfd4704ed880
[ "Apache-2.0" ]
null
null
null
second/utils/util.py
hankeceli/3D-Object-Detection-for-AV
b6c17a4a3ecc9c32418baafa5b82cfd4704ed880
[ "Apache-2.0" ]
null
null
null
import os import random from argparse import Namespace from pathlib import Path from pprint import pprint from typing import Union import numpy as np from omegaconf import OmegaConf from src.config.config import DATSET_LINKS_DIR def set_random_seed(seed: int = 42) -> None: os.environ["PYTHONHASHSEED"] = str(see...
31.923077
80
0.644578
3d4f36c96aee4e205df5310213de25990ca8abab
173
py
Python
server/python/post_flask.py
kosyachniy/dev
39bb5c5ee10780bfcd8a59cf59cfb1a348ac52a4
[ "Apache-2.0" ]
13
2018-12-17T23:30:54.000Z
2021-12-29T14:31:43.000Z
server/python/post_flask.py
kosyachniy/dev
39bb5c5ee10780bfcd8a59cf59cfb1a348ac52a4
[ "Apache-2.0" ]
36
2018-06-07T21:34:13.000Z
2022-03-13T21:01:43.000Z
server/python/post_flask.py
kosyachniy/dev
39bb5c5ee10780bfcd8a59cf59cfb1a348ac52a4
[ "Apache-2.0" ]
2
2021-01-03T11:47:20.000Z
2021-12-29T14:31:49.000Z
from flask import Flask, jsonify app = Flask(__name__) @app.route('/', methods=['POST']) def index(): return jsonify({'error': 0}) if __name__=='__main__': app.run()
17.3
33
0.653179
14c29068c851be63167a7d6abdf263e61d65606f
3,560
py
Python
tensorflow_probability/python/experimental/lazybones/deferred_scope.py
jbergmanster/probability
e15b307066e7485b8fe9faf3d289c739ab8d3806
[ "Apache-2.0" ]
null
null
null
tensorflow_probability/python/experimental/lazybones/deferred_scope.py
jbergmanster/probability
e15b307066e7485b8fe9faf3d289c739ab8d3806
[ "Apache-2.0" ]
null
null
null
tensorflow_probability/python/experimental/lazybones/deferred_scope.py
jbergmanster/probability
e15b307066e7485b8fe9faf3d289c739ab8d3806
[ "Apache-2.0" ]
null
null
null
# Copyright 2020 The TensorFlow Probability Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law o...
27.384615
85
0.692697
1162d6b37e26276fc84ba23188015d1fa097702a
17,011
py
Python
Phase2/Metadata.py
Ankush1529/MWDB-project
a2c5fafb82253bc0084817e071cf560d085b38c2
[ "Apache-2.0" ]
null
null
null
Phase2/Metadata.py
Ankush1529/MWDB-project
a2c5fafb82253bc0084817e071cf560d085b38c2
[ "Apache-2.0" ]
null
null
null
Phase2/Metadata.py
Ankush1529/MWDB-project
a2c5fafb82253bc0084817e071cf560d085b38c2
[ "Apache-2.0" ]
null
null
null
import sys sys.path.insert(1, '../Phase1') import misc import os import numpy as np import pandas as pd from pathlib import Path from features_images import FeaturesImages from prettytable import PrettyTable from sklearn.cluster import MiniBatchKMeans from PCA import PCAModel from tqdm import tqdm def euclidean_dist...
42.106436
127
0.651931
387a3e4cb50de13d84f36c9ae44d78ef6114a867
21,136
py
Python
config.py
ardovm/wxGlade
a4cf8e65bcc6df5f65cf8ca5c49b9a628bf1e8eb
[ "MIT" ]
null
null
null
config.py
ardovm/wxGlade
a4cf8e65bcc6df5f65cf8ca5c49b9a628bf1e8eb
[ "MIT" ]
null
null
null
config.py
ardovm/wxGlade
a4cf8e65bcc6df5f65cf8ca5c49b9a628bf1e8eb
[ "MIT" ]
null
null
null
""" Configuration related stuff note: Don't place code with gettext or dependencies to other wxGlade parts here! see: preferencesdialog @copyright: 2007 Alberto Griggio @copyright: 2013-2016 Carsten Grohmann @copyright: 2017-2020 Dietmar Schwertberger @license: MIT (see LICENSE.txt) - THIS PROGRAM COMES WITH NO WARRA...
58.548476
155
0.580621
9b02a4d4a046907af2601a78c8c36af2c39fa073
5,914
py
Python
malib/algorithm/sac/loss.py
apexrl/malib
3785309e9b695ff359131fbbecabb6b5a52ef559
[ "MIT" ]
258
2021-05-10T11:17:45.000Z
2022-03-30T13:41:09.000Z
malib/algorithm/sac/loss.py
apexrl/malib
3785309e9b695ff359131fbbecabb6b5a52ef559
[ "MIT" ]
28
2021-05-13T06:50:04.000Z
2022-03-30T14:19:15.000Z
malib/algorithm/sac/loss.py
apexrl/malib
3785309e9b695ff359131fbbecabb6b5a52ef559
[ "MIT" ]
34
2021-05-31T16:17:49.000Z
2022-03-26T06:59:59.000Z
import torch from typing import Dict, Any from torch.distributions import Independent, Normal from malib.algorithm.common.loss_func import LossFunc from malib.backend.datapool.offline_dataset_server import Episode class SACLoss(LossFunc): def __init__(self): super(SACLoss, self).__init__() def res...
38.907895
108
0.595029
294e1293dc8c89f0a40c87120f298ac58bf768ab
6,558
py
Python
fissix/fixer_base.py
dgrant/fissix
77a5bc72ae39c77380345ab8006fbe3fb6911115
[ "PSF-2.0" ]
32
2018-07-07T23:55:16.000Z
2022-01-31T03:47:51.000Z
fissix/fixer_base.py
dgrant/fissix
77a5bc72ae39c77380345ab8006fbe3fb6911115
[ "PSF-2.0" ]
35
2018-09-18T22:58:16.000Z
2021-11-13T23:28:21.000Z
fissix/fixer_base.py
dgrant/fissix
77a5bc72ae39c77380345ab8006fbe3fb6911115
[ "PSF-2.0" ]
18
2018-09-21T11:46:32.000Z
2021-11-26T18:08:37.000Z
# Copyright 2006 Google, Inc. All Rights Reserved. # Licensed to PSF under a Contributor Agreement. """Base class for fixers (optional, but recommended).""" # Python imports import itertools # Local imports from .patcomp import PatternCompiler from . import pygram from .fixer_util import does_tree_import class Bas...
34.698413
87
0.641812
d5d9c98a93d923044e6476324bd2377738d83fcb
9,642
py
Python
lib/py/src/server/TServer.py
noricube/thrift
39a09ac5e49481d39dd1bcb6757ffe182e3df20a
[ "Apache-2.0" ]
519
2018-09-25T12:55:31.000Z
2022-03-30T17:26:53.000Z
lib/py/src/server/TServer.py
noricube/thrift
39a09ac5e49481d39dd1bcb6757ffe182e3df20a
[ "Apache-2.0" ]
544
2018-09-25T08:54:28.000Z
2022-03-07T16:04:51.000Z
lib/py/src/server/TServer.py
noricube/thrift
39a09ac5e49481d39dd1bcb6757ffe182e3df20a
[ "Apache-2.0" ]
139
2018-09-26T05:11:20.000Z
2022-02-15T09:14:27.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...
34.808664
83
0.586082
cfd0d53a492339c9cc98784ebe9e9d20015dc8dc
24,704
py
Python
tests/ut/python/mindrecord/test_tfrecord_to_mr.py
i4oolish/mindspore
dac3be31d0f2c0a3516200f47af30980e566601b
[ "Apache-2.0" ]
2
2020-08-12T16:14:40.000Z
2020-12-04T03:05:57.000Z
tests/ut/python/mindrecord/test_tfrecord_to_mr.py
dilingsong/mindspore
4276050f2494cfbf8682560a1647576f859991e8
[ "Apache-2.0" ]
1
2020-12-29T06:46:38.000Z
2020-12-29T06:46:38.000Z
tests/ut/python/mindrecord/test_tfrecord_to_mr.py
dilingsong/mindspore
4276050f2494cfbf8682560a1647576f859991e8
[ "Apache-2.0" ]
1
2021-05-12T06:30:29.000Z
2021-05-12T06:30:29.000Z
# Copyright 2020 Huawei Technologies Co., Ltd. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agre...
43.879218
116
0.657505
a09163cc97b7fe8f7b73ead75e4cf83dbe826041
10,182
py
Python
test/utils/test_low_rank.py
jduerholt/botorch
82c9add3e943b28bd0a42438cfcaa1a70440c0c2
[ "MIT" ]
null
null
null
test/utils/test_low_rank.py
jduerholt/botorch
82c9add3e943b28bd0a42438cfcaa1a70440c0c2
[ "MIT" ]
null
null
null
test/utils/test_low_rank.py
jduerholt/botorch
82c9add3e943b28bd0a42438cfcaa1a70440c0c2
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # Copyright (c) Meta Platforms, Inc. and affiliates. # # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. import torch from botorch.exceptions.errors import BotorchError from botorch.models.gp_regression import SingleTaskGP...
50.91
87
0.390591
20f7d3b7044409600f2fc3b9b347efcca2fda832
101,051
py
Python
cinder/tests/unit/test_cmd.py
SaumyaRackspace/cinder
08cfa44d353f84019cab529ca6f13362ba2808ea
[ "Apache-2.0" ]
null
null
null
cinder/tests/unit/test_cmd.py
SaumyaRackspace/cinder
08cfa44d353f84019cab529ca6f13362ba2808ea
[ "Apache-2.0" ]
null
null
null
cinder/tests/unit/test_cmd.py
SaumyaRackspace/cinder
08cfa44d353f84019cab529ca6f13362ba2808ea
[ "Apache-2.0" ]
null
null
null
# Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # d...
46.036902
80
0.605496
5792f9566965cb85ce7df13ea9733dc259ac10ec
1,673
py
Python
tests/util/test_location.py
rosalogia/bumblebee-status
19c3975301d8700743df745ecd5ca2c05ecf5cf0
[ "MIT" ]
null
null
null
tests/util/test_location.py
rosalogia/bumblebee-status
19c3975301d8700743df745ecd5ca2c05ecf5cf0
[ "MIT" ]
null
null
null
tests/util/test_location.py
rosalogia/bumblebee-status
19c3975301d8700743df745ecd5ca2c05ecf5cf0
[ "MIT" ]
null
null
null
import unittest import json import urllib.request import util.location class location(unittest.TestCase): def setUp(self): patcher = unittest.mock.patch("util.location.urllib.request") self.addCleanup(patcher.stop) self.request = patcher.start() util.location.reset() self...
32.173077
86
0.604901
d0261303657b6d3e99097a784d919c58f964312c
241
py
Python
src/pyglet_pymunk/breakout_game/components/collision_types.py
yoyonel/pyglet-pymunk-breakout-game
4c694948d0225fa61531f4c529e0ed53407c2710
[ "MIT" ]
null
null
null
src/pyglet_pymunk/breakout_game/components/collision_types.py
yoyonel/pyglet-pymunk-breakout-game
4c694948d0225fa61531f4c529e0ed53407c2710
[ "MIT" ]
null
null
null
src/pyglet_pymunk/breakout_game/components/collision_types.py
yoyonel/pyglet-pymunk-breakout-game
4c694948d0225fa61531f4c529e0ed53407c2710
[ "MIT" ]
null
null
null
""" """ from enum import Enum, auto, unique @unique class CollisionType(int, Enum): """ """ # https://docs.python.org/3/library/enum.html#enum.auto BALL = auto() BRICK = auto() BOTTOM = auto() PLAYER = auto()
14.176471
59
0.572614
ca6f1482d7964b33e64af26375846f0c4bba0e6b
27,681
py
Python
src/black/lines.py
marnixah/black-but-usable
83b83d3066d1d857983bfa1a666a409e7255d79d
[ "MIT" ]
1
2022-03-27T20:59:30.000Z
2022-03-27T20:59:30.000Z
src/black/lines.py
marnixah/black-but-usable
83b83d3066d1d857983bfa1a666a409e7255d79d
[ "MIT" ]
null
null
null
src/black/lines.py
marnixah/black-but-usable
83b83d3066d1d857983bfa1a666a409e7255d79d
[ "MIT" ]
null
null
null
from dataclasses import dataclass, field import itertools import sys from typing import ( Callable, Dict, Iterator, List, Optional, Sequence, Tuple, TypeVar, cast, ) from blib2to3.pytree import Node, Leaf from blib2to3.pgen2 import token from black.brackets import BracketTracker, D...
35.763566
87
0.595354
57945cd12c26085f69d0059ada54ddb8f391f9a6
310
py
Python
ProgrammingInPython3/ch1_bigdigits.py
kingmax/py
4cbc20d21c249e22e8f6b68d3c761a66a981e38f
[ "MIT" ]
null
null
null
ProgrammingInPython3/ch1_bigdigits.py
kingmax/py
4cbc20d21c249e22e8f6b68d3c761a66a981e38f
[ "MIT" ]
null
null
null
ProgrammingInPython3/ch1_bigdigits.py
kingmax/py
4cbc20d21c249e22e8f6b68d3c761a66a981e38f
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 #coding:utf-8 """ Author: kingmax_res@163.com Purpose: Programming In Python3 Example | chapter 1 | bigdigits Created: 10/04/20 """ Zero = [' *** ', ' * * ', '* *'] def main(*args, **kwargs): """""" pass if __name__ == '__main__': main()
14.090909
65
0.516129
adb915d77adb58646c1ac971fe8f4169ced7a27b
73
py
Python
imc/operations/__init__.py
marcelluseasley/IBM-Marketing-Cloud-XML-API-Wrapper
c9ea5f537a53e02785b31c9557e64674300bd8ad
[ "MIT" ]
4
2016-11-15T19:39:49.000Z
2018-04-18T19:46:07.000Z
imc/operations/__init__.py
marcelluseasley/IBM-Marketing-Cloud-XML-API-Wrapper
c9ea5f537a53e02785b31c9557e64674300bd8ad
[ "MIT" ]
2
2016-06-14T07:27:20.000Z
2021-05-09T21:57:08.000Z
imc/operations/__init__.py
marcelluseasley/IBM-Marketing-Cloud-XML-API-Wrapper
c9ea5f537a53e02785b31c9557e64674300bd8ad
[ "MIT" ]
null
null
null
# # Filename: __init__.py # 6/12/2016 5:04 AM # # __author__ = 'measley'
10.428571
23
0.643836
b47f3e0be1b49c1b677f6728449a39a83192b088
672
py
Python
scripts/__V2/sqlgraph_v2/add_meta_type.py
AutoCoinDCF/NEW_API
f4abc48fff907a0785372b941afcd67e62eec825
[ "Apache-2.0" ]
null
null
null
scripts/__V2/sqlgraph_v2/add_meta_type.py
AutoCoinDCF/NEW_API
f4abc48fff907a0785372b941afcd67e62eec825
[ "Apache-2.0" ]
null
null
null
scripts/__V2/sqlgraph_v2/add_meta_type.py
AutoCoinDCF/NEW_API
f4abc48fff907a0785372b941afcd67e62eec825
[ "Apache-2.0" ]
null
null
null
from pandas import DataFrame, read_csv import os from tqdm import tqdm meta_column_name = "meta_type" file_pattern = "./%s.csv" new_file_pattern = "./new_csv/%s.csv" tables = { "document": ["document"], "event": ["event"] } for meta_type, table_names in tqdm(tables.items()): for table_name in tqdm(table_...
26.88
71
0.629464
f66ee1e18ed9dbf43eeeeb3ae95dbb91e3f4eae9
1,241
py
Python
v1/accounts/views/account.py
VincentHch/Validator
13c87bd447e2638883746d1b65e4683ce62e5e37
[ "MIT" ]
1
2020-12-08T14:19:19.000Z
2020-12-08T14:19:19.000Z
v1/accounts/views/account.py
VincentHch/Validator
13c87bd447e2638883746d1b65e4683ce62e5e37
[ "MIT" ]
null
null
null
v1/accounts/views/account.py
VincentHch/Validator
13c87bd447e2638883746d1b65e4683ce62e5e37
[ "MIT" ]
null
null
null
from rest_framework.decorators import action from rest_framework.mixins import ListModelMixin from rest_framework.response import Response from rest_framework.viewsets import GenericViewSet from v1.cache_tools.accounts import get_account_balance, get_account_balance_lock from ..models.account import Account from ..ser...
29.547619
83
0.726027
122052d61f3e1da01bec4297d9ad45786425e3a3
885
py
Python
ai-labs/Lab1/my_tests.py
kryvokhyzha/examples-and-courses
477e82ee24e6abba8a6b6d92555f2ed549ca682c
[ "MIT" ]
1
2021-12-13T15:41:48.000Z
2021-12-13T15:41:48.000Z
ai-labs/Lab1/my_tests.py
kryvokhyzha/examples-and-courses
477e82ee24e6abba8a6b6d92555f2ed549ca682c
[ "MIT" ]
15
2021-09-12T15:06:13.000Z
2022-03-31T19:02:08.000Z
ai-labs/Lab1/my_tests.py
kryvokhyzha/examples-and-courses
477e82ee24e6abba8a6b6d92555f2ed549ca682c
[ "MIT" ]
1
2022-01-29T00:37:52.000Z
2022-01-29T00:37:52.000Z
import itertools def is_jealousy(current, couples_number=3): """ Check jealousy for current state. Args: current: couples_number: Returns: """ for i in range(0, couples_number): # husband is not with his wife if current[i] != current[couples_number + i]: ...
21.585366
63
0.59548
6b82afc45d66bff2788af7494f3ad479a986d8f0
13,984
py
Python
django/db/backends/mysql/base.py
nicois/django
db4149a063fb99e2d2ba760bafeef3f14590fef6
[ "PSF-2.0", "BSD-3-Clause" ]
null
null
null
django/db/backends/mysql/base.py
nicois/django
db4149a063fb99e2d2ba760bafeef3f14590fef6
[ "PSF-2.0", "BSD-3-Clause" ]
null
null
null
django/db/backends/mysql/base.py
nicois/django
db4149a063fb99e2d2ba760bafeef3f14590fef6
[ "PSF-2.0", "BSD-3-Clause" ]
null
null
null
""" MySQL database backend for Django. Requires mysqlclient: https://pypi.python.org/pypi/mysqlclient/ """ import re from django.core.exceptions import ImproperlyConfigured from django.db import utils from django.db.backends import utils as backend_utils from django.db.backends.base.base import BaseDatabaseWrapper fr...
40.416185
108
0.610626
23196ea43c833e0175828e161906bd323a2cd1ab
112,239
py
Python
superset/hack/core.py
zcong1993/public-actions
00a1930390e046754739e7340c34bf673f48fcd1
[ "MIT" ]
null
null
null
superset/hack/core.py
zcong1993/public-actions
00a1930390e046754739e7340c34bf673f48fcd1
[ "MIT" ]
1
2020-12-02T09:23:36.000Z
2020-12-02T09:23:57.000Z
superset/hack/core.py
zcong1993/public-actions
00a1930390e046754739e7340c34bf673f48fcd1
[ "MIT" ]
null
null
null
# 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...
38.137615
100
0.583469
dfdb30280b2135d38164cac1d8d31a9a74bf97da
4,373
py
Python
tests/parsers/test_Thinkpad-R500.py
lvps/peracotta
f841d68738f1012ba2ad78242d326eff607a81b0
[ "MIT" ]
null
null
null
tests/parsers/test_Thinkpad-R500.py
lvps/peracotta
f841d68738f1012ba2ad78242d326eff607a81b0
[ "MIT" ]
null
null
null
tests/parsers/test_Thinkpad-R500.py
lvps/peracotta
f841d68738f1012ba2ad78242d326eff607a81b0
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 import os from parsers import read_smartctl from parsers import read_decode_dimms from parsers import read_dmidecode from parsers import read_lspci_and_glxinfo from parsers import read_lscpu filedir = 'tests/Thinkpad-R500/' def test_lspci(): expect = { "type": "graphics-card", "working":...
37.059322
1,880
0.602332
7109af02991d212baf1057cc733e80452ef09e33
2,218
py
Python
src/pipx/interpreter.py
mindywallen699/pipx
5c3cc823ab780f4d562e5e8c1ed0c31aee893133
[ "MIT" ]
3,573
2019-02-06T07:13:28.000Z
2021-05-27T02:34:20.000Z
src/pipx/interpreter.py
mindywallen699/pipx
5c3cc823ab780f4d562e5e8c1ed0c31aee893133
[ "MIT" ]
533
2019-02-06T19:37:59.000Z
2021-05-27T04:05:30.000Z
src/pipx/interpreter.py
pfmoore/pipx
c54dcd9c42293e8aba242f34dfd25e2872912c33
[ "MIT" ]
187
2019-02-24T21:56:21.000Z
2021-05-21T15:46:13.000Z
import os import shutil import subprocess import sys from pipx.constants import WINDOWS from pipx.util import PipxError def has_venv() -> bool: try: import venv # noqa return True except ImportError: return False # The following code was copied from https://github.com/uranusjr/pip...
27.725
85
0.708747
1e0a19a1b92ebcc23967fd9df9b0d3afe9ddd586
1,610
py
Python
jmapd/main.py
plq/jmapd
13a59d77ef8e14946d5343b1294d30bb38b9df8b
[ "BSD-3-Clause" ]
null
null
null
jmapd/main.py
plq/jmapd
13a59d77ef8e14946d5343b1294d30bb38b9df8b
[ "BSD-3-Clause" ]
null
null
null
jmapd/main.py
plq/jmapd
13a59d77ef8e14946d5343b1294d30bb38b9df8b
[ "BSD-3-Clause" ]
1
2020-01-10T05:21:02.000Z
2020-01-10T05:21:02.000Z
# # This file is part of the jmapd project at https://github.com/arskom/jmapd. # # jmapd (c) 2020 and beyond, Arskom Ltd. All rights reserved. # # This file is subject to the terms of the 3-clause BSD license, which can be # found in the LICENSE file distributed with this file. Alternatively, you can # obtain a copy fr...
26.393443
78
0.645963
693b933ec3e197d3aa00812d49b5edfdd8a847c4
4,815
py
Python
adaptivedistillation/apis/train.py
wyze-AI/AdaptiveDistillation
5f4575794101dbb1ed2f7e90a2be03856f76041c
[ "MIT" ]
1
2022-01-12T22:24:07.000Z
2022-01-12T22:24:07.000Z
adaptivedistillation/apis/train.py
wyze-AI/AdaptiveDistillation
5f4575794101dbb1ed2f7e90a2be03856f76041c
[ "MIT" ]
null
null
null
adaptivedistillation/apis/train.py
wyze-AI/AdaptiveDistillation
5f4575794101dbb1ed2f7e90a2be03856f76041c
[ "MIT" ]
2
2022-01-12T22:24:17.000Z
2022-02-15T05:46:30.000Z
import warnings import torch from mmcv.parallel import MMDataParallel, MMDistributedDataParallel from mmcv.runner import DistSamplerSeedHook, build_optimizer, build_runner from mmcls.core import DistOptimizerHook from mmcls.utils import get_root_logger # TODO import eval hooks from mmcv and delete them from mmcls # t...
34.891304
79
0.644029
e0fb44422b57774e81d8318c703c15212032c2a5
2,736
py
Python
python/domain_plotting.py
Huizerd/AI_techniques
25791b986061fb65150c0c0cbd5010ab60000a03
[ "MIT" ]
null
null
null
python/domain_plotting.py
Huizerd/AI_techniques
25791b986061fb65150c0c0cbd5010ab60000a03
[ "MIT" ]
null
null
null
python/domain_plotting.py
Huizerd/AI_techniques
25791b986061fb65150c0c0cbd5010ab60000a03
[ "MIT" ]
1
2021-03-04T15:32:15.000Z
2021-03-04T15:32:15.000Z
import pandas as pd import numpy as np import matplotlib.pyplot as plt FNAME = 'data/domains_tournament.csv' AGENTS = ['Own', 'TheNegotiator', 'HardHeaded', 'Gahboninho'] DOMAINS = ['Party', 'ADG', 'Grocery', 'Laptop'] # Load data data_raw = pd.read_csv(FNAME, sep=',', header=0, usecol...
48
475
0.58845
faf91207eebb8da1383649f8760ec5f696718c1a
6,382
py
Python
app/modules/common/CM/CM_TUW9/specific_demand.py
HotMaps/building_h-c
db5a103cb9d41b88e6cdc3c9194fc1ec9fc5c31f
[ "Apache-2.0" ]
1
2017-05-12T11:31:09.000Z
2017-05-12T11:31:09.000Z
app/modules/common/CM/CM_TUW9/specific_demand.py
HotMaps/HotMaps-building_h-c
db5a103cb9d41b88e6cdc3c9194fc1ec9fc5c31f
[ "Apache-2.0" ]
2
2017-08-22T13:53:22.000Z
2017-09-25T07:27:28.000Z
app/modules/common/CM/CM_TUW9/specific_demand.py
HotMaps/Hotmaps-building_h-c
db5a103cb9d41b88e6cdc3c9194fc1ec9fc5c31f
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on June 8 2017 @author: fallahnejad@eeg.tuwien.ac.at """ import os import sys import time import numpy as np from osgeo import gdal from osgeo import ogr from osgeo import osr import pandas as pd import shutil path = os.path.dirname(os.path.dirname(os.path.dirname(os.path. ...
41.174194
79
0.669696
6213009424da272b0db27881c5a3fa76e8ffb4c3
371
py
Python
Artesian/GMEPublicOffers/ExtractionRangeConfig.py
AndreaCuneo/Artesian.SDK-Python
1f3528293e2da42d9f1901cd94165464cffab3fc
[ "MIT" ]
null
null
null
Artesian/GMEPublicOffers/ExtractionRangeConfig.py
AndreaCuneo/Artesian.SDK-Python
1f3528293e2da42d9f1901cd94165464cffab3fc
[ "MIT" ]
null
null
null
Artesian/GMEPublicOffers/ExtractionRangeConfig.py
AndreaCuneo/Artesian.SDK-Python
1f3528293e2da42d9f1901cd94165464cffab3fc
[ "MIT" ]
null
null
null
from typing import Optional class ExtractionRangeConfig: """ Class for the Extraction Range Configuration. Attribute: date: Date for the Extraction Range configuration in (ISO) format """ def __init__(self, date:Optional[str]=None) -> None: """ Inits the Extractio...
26.5
78
0.638814
ae4b960aa8190b096cc591f8aeb32496b0c0d6ca
6,698
py
Python
tqsdk/test/api/helper.py
xcgoo/tqsdk-python
5f9bb1d8fa7896ff9e47dde756462374e9bea938
[ "Apache-2.0" ]
3
2020-05-19T14:37:34.000Z
2021-03-25T09:56:18.000Z
tqsdk/test/api/helper.py
kozyan/tqsdk-python
ac357d7d9c5bba50ea2e79664729161586114226
[ "Apache-2.0" ]
1
2019-09-24T03:27:56.000Z
2019-09-24T03:27:56.000Z
tqsdk/test/api/helper.py
kozyan/tqsdk-python
ac357d7d9c5bba50ea2e79664729161586114226
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- import json import lzma import os import threading import asyncio import websockets from aiohttp import web class MockInsServer(): def __init__(self, port): self.loop = asyncio.new_event_loop() self.port = port self.symbols_dir = os.path.joi...
36.601093
147
0.551359
32978c8b8d1c1ceab9a2db0772d37d85e5845f90
465
py
Python
data/scripts/templates/object/tangible/ship/attachment/weapon/shared_bwing_weapon1_s03.py
obi-two/GameServer
7d37024e2291a97d49522610cd8f1dbe5666afc2
[ "MIT" ]
20
2015-02-23T15:11:56.000Z
2022-03-18T20:56:48.000Z
data/scripts/templates/object/tangible/ship/attachment/weapon/shared_bwing_weapon1_s03.py
apathyboy/swganh
665128efe9154611dec4cb5efc61d246dd095984
[ "MIT" ]
null
null
null
data/scripts/templates/object/tangible/ship/attachment/weapon/shared_bwing_weapon1_s03.py
apathyboy/swganh
665128efe9154611dec4cb5efc61d246dd095984
[ "MIT" ]
20
2015-04-04T16:35:59.000Z
2022-03-24T14:54:37.000Z
#### NOTICE: THIS FILE IS AUTOGENERATED #### MODIFICATIONS MAY BE LOST IF DONE IMPROPERLY #### PLEASE SEE THE ONLINE DOCUMENTATION FOR EXAMPLES from swgpy.object import * def create(kernel): result = Tangible() result.template = "object/tangible/ship/attachment/weapon/shared_bwing_weapon1_s03.iff" result.attribu...
27.352941
88
0.735484
d8bb43bb010dd6c38c5f0d6a98604b1a413ee854
2,060
py
Python
source/modules/__init__.py
telegrambotdev/telegram.email.notify
d16880819b2f1887b0e0f0b9841de2a122d81dd6
[ "MIT" ]
null
null
null
source/modules/__init__.py
telegrambotdev/telegram.email.notify
d16880819b2f1887b0e0f0b9841de2a122d81dd6
[ "MIT" ]
null
null
null
source/modules/__init__.py
telegrambotdev/telegram.email.notify
d16880819b2f1887b0e0f0b9841de2a122d81dd6
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ modules for transform """ from html2text import convert from models import SavedSource MARKUP = '###text_mode markdown' BUTTONS = '###buttons' NBSP = chr(0xC2) + chr(0xA0) def store(label, subj, body): """ default handler for store incoming messages """ SavedSource(label=l...
21.237113
93
0.58835
0743adb7727d4d8bc7b0db2746b65fb403a57f47
1,827
py
Python
src/pyams_zfiles/tests/test_utilsdocs.py
Py-AMS/pyams-zfiles
5a86ffe82762522012c1273fd186cda777524862
[ "ZPL-2.1" ]
null
null
null
src/pyams_zfiles/tests/test_utilsdocs.py
Py-AMS/pyams-zfiles
5a86ffe82762522012c1273fd186cda777524862
[ "ZPL-2.1" ]
null
null
null
src/pyams_zfiles/tests/test_utilsdocs.py
Py-AMS/pyams-zfiles
5a86ffe82762522012c1273fd186cda777524862
[ "ZPL-2.1" ]
null
null
null
# # Copyright (c) 2015-2019 Thierry Florac <tflorac AT ulthar.net> # All Rights Reserved. # # This software is subject to the provisions of the Zope Public License, # Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution. # THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED # WARRAN...
29.95082
95
0.675972
c34410af6508cfc05b3f20d4b123f2ec52295ab1
626
py
Python
realistic_faces/dataset_helpers.py
blzq/real-manipulable-faces
b5d62b54d992200486d2aef94d562af837fd8412
[ "Apache-2.0" ]
null
null
null
realistic_faces/dataset_helpers.py
blzq/real-manipulable-faces
b5d62b54d992200486d2aef94d562af837fd8412
[ "Apache-2.0" ]
null
null
null
realistic_faces/dataset_helpers.py
blzq/real-manipulable-faces
b5d62b54d992200486d2aef94d562af837fd8412
[ "Apache-2.0" ]
null
null
null
import os import tensorflow as tf def filenames_from_dataset_path(dataset_path): img_dirs = map(lambda d: os.path.join(dataset_path, d), os.listdir(dataset_path)) img_files = [] for img_dir in img_dirs: img_files_one_dir = list(map(lambda f: os.path.join(img_dir, f), os.listdir(img_dir))) ...
28.454545
94
0.704473
6711842d45010bdefd339350221ab37580917be5
7,063
py
Python
FD_Placement.py
parthpower/placement-heuristics
6aa4bb8bd7b6fc5f409bfcd02ec2498a8a08865e
[ "MIT" ]
null
null
null
FD_Placement.py
parthpower/placement-heuristics
6aa4bb8bd7b6fc5f409bfcd02ec2498a8a08865e
[ "MIT" ]
1
2017-10-22T16:21:17.000Z
2017-10-24T01:42:05.000Z
FD_Placement.py
parthpower/placement-heuristics
6aa4bb8bd7b6fc5f409bfcd02ec2498a8a08865e
[ "MIT" ]
null
null
null
from sys import argv import Base from Base import Net from Base import Node, Board import Base_Test import numpy as np import copy import atexit import matplotlib.pyplot as plt import Base_Test from netlist_parser import parse_file def show_graph(): # b = Board(0, nets, min_cost_placement, 12, 12) ...
28.946721
135
0.535042
5e0e5fca539da462da271668e65fa2c4eb9c11de
4,500
py
Python
gen_cs_proto_msg_ids.py
thanklzhang/Proto_Pre
e6d1998aa41b52f01b5244a59fbbbe700d6dd64c
[ "MIT" ]
null
null
null
gen_cs_proto_msg_ids.py
thanklzhang/Proto_Pre
e6d1998aa41b52f01b5244a59fbbbe700d6dd64c
[ "MIT" ]
null
null
null
gen_cs_proto_msg_ids.py
thanklzhang/Proto_Pre
e6d1998aa41b52f01b5244a59fbbbe700d6dd64c
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- #!usr/bin/python # coding=gbk import os import string import traceback import openpyxl import sys import time import re import shutil definestr = "" baseDir = os.getcwd() EnumName = "ProtoIDs" def get_proto_file_list(dir, flist): print("\n") print("start get proto files ...") ...
30.201342
101
0.483333
a20058c05754148f4870b048c74ff811862853d3
271
py
Python
python/plp/__meta__.py
behrouzsh/Proteomics-Landing-Page
920911a18b4a2191829274ffb66d129a02339659
[ "MIT" ]
null
null
null
python/plp/__meta__.py
behrouzsh/Proteomics-Landing-Page
920911a18b4a2191829274ffb66d129a02339659
[ "MIT" ]
null
null
null
python/plp/__meta__.py
behrouzsh/Proteomics-Landing-Page
920911a18b4a2191829274ffb66d129a02339659
[ "MIT" ]
null
null
null
"""Project metadata. """ __title__ = 'plp' __summary__ = 'Python library for Protein Line Notation' __url__ = '' __version__ = '0.1.0' __install_requires__ = ['requests>=1.1.0'] __author__ = 'Behrouz Shamsaei' __email__ = 'behrouz.shamsaei@uc.edu' __license__ = 'MIT'
19.357143
56
0.712177
cde56ebe49c2e743a4bd62ab261c8d69406a09fe
399
py
Python
kitti/tests/test_stereo.py
jasoncorso/kittipy
906a0ab85ba7723006d5cee31e2985e66b7bcaaf
[ "MIT" ]
97
2015-06-24T20:34:15.000Z
2022-03-05T13:52:47.000Z
kitti/tests/test_stereo.py
jasoncorso/kittipy
906a0ab85ba7723006d5cee31e2985e66b7bcaaf
[ "MIT" ]
8
2015-04-30T05:56:43.000Z
2021-06-07T17:14:30.000Z
kitti/tests/test_stereo.py
jasoncorso/kittipy
906a0ab85ba7723006d5cee31e2985e66b7bcaaf
[ "MIT" ]
27
2015-10-14T19:53:31.000Z
2021-08-13T01:23:49.000Z
from kitti.stereo import load_pair, load_disp def test_load(): import matplotlib.pyplot as plt i = 90 left, right = load_pair(i) disp = load_disp(i) plt.figure() plt.subplot(311) plt.imshow(left, cmap='gray') plt.subplot(312) plt.imshow(right, cmap='gray') plt.subplot(313) ...
17.347826
45
0.631579
0d033b7d5baa4efcd96dcb9e77cc9720cdb783ed
1,915
py
Python
pyjswidgets/pyjamas/ui/FlashPanel.browser.py
takipsizad/pyjs
54db0ba6747aca744f9f3c3e985a17e913dfb951
[ "ECL-2.0", "Apache-2.0" ]
739
2015-01-01T02:05:11.000Z
2022-03-30T15:26:16.000Z
pyjswidgets/pyjamas/ui/FlashPanel.browser.py
takipsizad/pyjs
54db0ba6747aca744f9f3c3e985a17e913dfb951
[ "ECL-2.0", "Apache-2.0" ]
33
2015-03-25T23:17:04.000Z
2021-08-19T08:25:22.000Z
pyjswidgets/pyjamas/ui/FlashPanel.browser.py
takipsizad/pyjs
54db0ba6747aca744f9f3c3e985a17e913dfb951
[ "ECL-2.0", "Apache-2.0" ]
167
2015-01-01T22:27:47.000Z
2022-03-17T13:29:19.000Z
""" Flash embedding Panel @license: Apache License Version 2.0 @copyright: 2009 Tobias Weber @author: Tobias Weber @contact: tobi-weber@gmx.de """ class FlashPanel(Panel): def callFlash(self, functionName, arguments=[]): """ @param functionName: Methodname of ExternalInterface @param argu...
31.916667
152
0.54047
ac3d3cef2673b49f796ba70e7a6398387693ccd4
88,420
py
Python
nova/virt/xenapi/vm_utils.py
bopopescu/nova-39
36c7a819582b838b7bbab11d55ca3d991a587405
[ "Apache-2.0" ]
null
null
null
nova/virt/xenapi/vm_utils.py
bopopescu/nova-39
36c7a819582b838b7bbab11d55ca3d991a587405
[ "Apache-2.0" ]
null
null
null
nova/virt/xenapi/vm_utils.py
bopopescu/nova-39
36c7a819582b838b7bbab11d55ca3d991a587405
[ "Apache-2.0" ]
1
2020-07-24T09:39:47.000Z
2020-07-24T09:39:47.000Z
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright (c) 2010 Citrix Systems, Inc. # Copyright 2011 Piston Cloud Computing, Inc. # Copyright 2012 OpenStack Foundation # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may ...
37.166877
79
0.613753
bd899330effd139771deb842ac423ba03acd0a96
4,043
py
Python
problems/blood_types.py
benallan/lovelace-problems
3780d2bfc58fe0531d60a92ae0a6c45e9814f58f
[ "MIT" ]
29
2019-07-23T16:51:36.000Z
2022-03-08T21:42:05.000Z
problems/blood_types.py
benallan/lovelace-problems
3780d2bfc58fe0531d60a92ae0a6c45e9814f58f
[ "MIT" ]
44
2019-03-22T00:05:32.000Z
2021-05-04T13:25:12.000Z
problems/blood_types.py
benallan/lovelace-problems
3780d2bfc58fe0531d60a92ae0a6c45e9814f58f
[ "MIT" ]
3
2019-08-04T13:06:21.000Z
2021-04-20T07:41:42.000Z
import logging from random import choice, choices, randint from typing import Tuple from problems.test_case import TestCase, TestCaseTypeEnum from problems.solutions.blood_types import survive logger = logging.getLogger(__name__) FUNCTION_NAME = "survive" INPUT_VARS = ["patient_blood_type", "donated_blood"] OUTPUT_V...
36.754545
96
0.67351
595c2c37994ea73be1773d3f50fb188ae964a0e0
3,265
py
Python
data/p2DJ/New/program/qiskit/noisy/startQiskit_noisy224.py
UCLA-SEAL/QDiff
d968cbc47fe926b7f88b4adf10490f1edd6f8819
[ "BSD-3-Clause" ]
null
null
null
data/p2DJ/New/program/qiskit/noisy/startQiskit_noisy224.py
UCLA-SEAL/QDiff
d968cbc47fe926b7f88b4adf10490f1edd6f8819
[ "BSD-3-Clause" ]
null
null
null
data/p2DJ/New/program/qiskit/noisy/startQiskit_noisy224.py
UCLA-SEAL/QDiff
d968cbc47fe926b7f88b4adf10490f1edd6f8819
[ "BSD-3-Clause" ]
null
null
null
# qubit number=2 # total number=16 import cirq import qiskit from qiskit.providers.aer import QasmSimulator from qiskit.test.mock import FakeVigo from qiskit import IBMQ from qiskit import QuantumCircuit, QuantumRegister, ClassicalRegister from qiskit import BasicAer, execute, transpile from pprint import pprint from ...
28.640351
82
0.629403
6acbc685270c895a94145c2dd2d33ad496aece66
626
py
Python
wirewavefront/primitives/face.py
shchuko/wirewavefront
ace3f323e7327beafd2aea92caa48e3f11b2e10c
[ "BSD-2-Clause" ]
null
null
null
wirewavefront/primitives/face.py
shchuko/wirewavefront
ace3f323e7327beafd2aea92caa48e3f11b2e10c
[ "BSD-2-Clause" ]
null
null
null
wirewavefront/primitives/face.py
shchuko/wirewavefront
ace3f323e7327beafd2aea92caa48e3f11b2e10c
[ "BSD-2-Clause" ]
null
null
null
# # Copyright (c) 2021, Vladislav Yaroshchuk <yaroshchuk2000@gmail.com> # # SPDX-License-Identifier: BSD-2-Clause # from wirewavefront.primitives.vertex import Vertex class Face: def __init__(self, vertexes: list = None): if vertexes is None: vertexes = list() self._vertexes = vertex...
24.076923
70
0.640575
0a80c9190705d1d035b7b9d464a7ac78db5ff0bc
1,865
py
Python
pyramid_heroku/migrate.py
teamniteo/pyramid_heroku
098fa326d94bfe4ac41ce82faf75246e9d81d564
[ "BSD-2-Clause-FreeBSD" ]
2
2017-08-03T12:29:17.000Z
2018-08-08T22:17:48.000Z
pyramid_heroku/migrate.py
teamniteo/pyramid_heroku
098fa326d94bfe4ac41ce82faf75246e9d81d564
[ "BSD-2-Clause-FreeBSD" ]
22
2017-08-03T17:28:09.000Z
2021-02-03T15:24:17.000Z
pyramid_heroku/migrate.py
teamniteo/pyramid_heroku
098fa326d94bfe4ac41ce82faf75246e9d81d564
[ "BSD-2-Clause-FreeBSD" ]
4
2017-08-04T04:53:18.000Z
2019-09-04T13:06:44.000Z
"""Graceful DB migrations.""" from pyramid_heroku import shell from pyramid_heroku.heroku import Heroku from time import sleep import argparse def needs_migrate(heroku: Heroku) -> bool: """ Checks current status of alembic branches. :return: True if current alembic branch is not up to date. """ ...
25.902778
83
0.64504
153db250f0688052239c60caf5286ff228216608
5,007
py
Python
conf.py
APhun/moviepy-cn
24cf045a69d58ba920a29133c28cc5332cf7f0a9
[ "MIT" ]
98
2018-07-24T07:34:35.000Z
2022-03-27T07:28:25.000Z
conf.py
APhun/moviepy-cn
24cf045a69d58ba920a29133c28cc5332cf7f0a9
[ "MIT" ]
1
2019-03-28T03:34:26.000Z
2019-03-28T04:15:37.000Z
conf.py
APhun/moviepy-cn
24cf045a69d58ba920a29133c28cc5332cf7f0a9
[ "MIT" ]
29
2018-02-01T02:49:04.000Z
2022-02-13T03:37:04.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # moviepy-cn documentation build configuration file, created by # sphinx-quickstart on Sat Nov 17 15:10:46 2018. # # This file is execfile()d with the current directory set to its # containing dir. # # Note that not all possible configuration values are present in this #...
30.345455
79
0.683443
7f2d4ac110563b6c6b75882e924895d1eddab2bc
1,089
py
Python
modules/mpi-ring/bin/onramp_run.py
elise-baumgartner/onramp
beb3c807264fcb70d8069ff2e3990b0ce3f59912
[ "BSD-3-Clause" ]
2
2016-09-09T04:19:01.000Z
2019-02-15T20:28:13.000Z
modules/mpi-ring/bin/onramp_run.py
elise-baumgartner/onramp
beb3c807264fcb70d8069ff2e3990b0ce3f59912
[ "BSD-3-Clause" ]
67
2016-06-02T19:37:56.000Z
2018-02-22T05:23:45.000Z
modules/mpi-ring/bin/onramp_run.py
elise-baumgartner/onramp
beb3c807264fcb70d8069ff2e3990b0ce3f59912
[ "BSD-3-Clause" ]
9
2015-06-22T22:10:22.000Z
2016-04-26T15:35:45.000Z
#!/usr/bin/env python # # Curriculum Module Run Script # - Run once per run of the module by a user # - Run inside job submission. So in an allocation. # - onramp_run_params.cfg file is available in current working directory # import os import sys from subprocess import call from configobj import ConfigObj # # Read t...
23.673913
88
0.690542
d0c684d61294b1b50568e47cfa435abfda8ebdff
391
py
Python
BOJ_Solved/BOJ-11758.py
CodingLeeSeungHoon/Python_Algorithm_TeamNote
1e92986999b45aa9951e12e67b23062e410e9b36
[ "MIT" ]
7
2021-11-19T14:50:59.000Z
2022-02-25T20:00:20.000Z
BOJ_Solved/BOJ-11758.py
CodingLeeSeungHoon/Python_Algorithm_TeamNote
1e92986999b45aa9951e12e67b23062e410e9b36
[ "MIT" ]
null
null
null
BOJ_Solved/BOJ-11758.py
CodingLeeSeungHoon/Python_Algorithm_TeamNote
1e92986999b45aa9951e12e67b23062e410e9b36
[ "MIT" ]
null
null
null
""" 백준 11758번 : CCW """ p1 = list(map(int, input().split())) p2 = list(map(int, input().split())) p3 = list(map(int, input().split())) def ccw(p1, p2, p3): x1, y1 = p1 x2, y2 = p2 x3, y3 = p3 return (x1 * y2) + (x2 * y3) + (x3 * y1) - (y1 * x2) - (y2 * x3) - (y3 * x1) result = ccw(p1, p2, p3) if res...
17.772727
80
0.496164
acaca3877a307daa1d65559f9385c2d8e226712d
8,518
py
Python
server/sailui_publish_gps.py
HadrienLG/SailUI
d40fac0a2de0e2a8b2ef0cd3828130fd90a5e0f1
[ "MIT" ]
2
2021-01-28T07:51:54.000Z
2021-12-27T14:29:36.000Z
server/sailui_publish_gps.py
HadrienLG/SailUI
d40fac0a2de0e2a8b2ef0cd3828130fd90a5e0f1
[ "MIT" ]
7
2021-03-05T21:33:05.000Z
2022-03-09T20:59:28.000Z
server/sailui_publish_gps.py
HadrienLG/SailUI
d40fac0a2de0e2a8b2ef0cd3828130fd90a5e0f1
[ "MIT" ]
null
null
null
# encoding: utf8 """ SailUI - GPS data from serial port parsed and send to InfluxDB MIT License Copyright (c) 2021 HadrienLG Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, ...
38.026786
119
0.611998
34474b677ddd916609c136bd2be89e17c4e42ad6
5,034
py
Python
source/univariate/test/Gamma.py
adeeconometrics/s_distributions
a29b1db324d7ee7f63498c8ed1888ab6ead849d8
[ "MIT" ]
null
null
null
source/univariate/test/Gamma.py
adeeconometrics/s_distributions
a29b1db324d7ee7f63498c8ed1888ab6ead849d8
[ "MIT" ]
null
null
null
source/univariate/test/Gamma.py
adeeconometrics/s_distributions
a29b1db324d7ee7f63498c8ed1888ab6ead849d8
[ "MIT" ]
null
null
null
try: from scipy.special import gamma as _gamma, gammainc as _gammainc, digamma as _digamma import numpy as _np from math import sqrt as _sqrt, log as _log, exp as _exp from typing import Union, Dict, List from univariate._base import SemiInfinite except Exception as e: print(f"some module...
34.958333
129
0.55741
d978cbc79dbd116acdf57a89a9aa0006b4b5da70
100
py
Python
span_ae/__init__.py
maxdel/span_ae
76dde200a68fdca30bfe312fb9e47328f3212577
[ "MIT" ]
1
2019-11-27T10:55:06.000Z
2019-11-27T10:55:06.000Z
span_ae/__init__.py
maxdel/span_ae
76dde200a68fdca30bfe312fb9e47328f3212577
[ "MIT" ]
null
null
null
span_ae/__init__.py
maxdel/span_ae
76dde200a68fdca30bfe312fb9e47328f3212577
[ "MIT" ]
null
null
null
from span_ae.models import * from span_ae.dataset_readers import * from span_ae.predictors import *
33.333333
37
0.82
327fae4623b4c19f10293bf5f38ac8cb124b68fd
196
py
Python
string/palindrome.py
shahasifbashir/LearnPython
4ce6b81d66ea7bbf0a40427871daa4e563b6a184
[ "MIT" ]
null
null
null
string/palindrome.py
shahasifbashir/LearnPython
4ce6b81d66ea7bbf0a40427871daa4e563b6a184
[ "MIT" ]
null
null
null
string/palindrome.py
shahasifbashir/LearnPython
4ce6b81d66ea7bbf0a40427871daa4e563b6a184
[ "MIT" ]
null
null
null
#ask user for an input string = input("Enter a string : ") if(string != "" and string[::]==string[::-1]): print("The string is a palindrome") else: print("The string is not a palindrome")
28
46
0.637755
b34af86c7c91c607866beb5d36c9a8afad2b4ef0
3,471
py
Python
export_onnx.py
wonderingboy/license-plate-detect-with-corner-points
f1680a6e6d4150ed75f4bcc0017fe7b3971fcaed
[ "MIT" ]
2
2022-02-21T07:28:35.000Z
2022-02-21T07:34:59.000Z
export_onnx.py
wonderingboy/license-plate-detect-with-corner-points
f1680a6e6d4150ed75f4bcc0017fe7b3971fcaed
[ "MIT" ]
null
null
null
export_onnx.py
wonderingboy/license-plate-detect-with-corner-points
f1680a6e6d4150ed75f4bcc0017fe7b3971fcaed
[ "MIT" ]
null
null
null
from __future__ import print_function import os import argparse import torch import torch.backends.cudnn as cudnn import numpy as np from data import cfg_mnet, cfg_re50 from layers.functions.prior_box import PriorBox from utils.nms.py_cpu_nms import py_cpu_nms import cv2 from models.retinaface import RetinaFace from ut...
43.3875
109
0.730913
9382792df7dbc8fa2704f645115841c72fc5bfee
8,595
py
Python
ctapipe/utils/unstructured_interpolator.py
Pluto9th/ctapipe
8c4faa674a1949210cbda8cb9e2413dd6362afea
[ "BSD-3-Clause" ]
null
null
null
ctapipe/utils/unstructured_interpolator.py
Pluto9th/ctapipe
8c4faa674a1949210cbda8cb9e2413dd6362afea
[ "BSD-3-Clause" ]
null
null
null
ctapipe/utils/unstructured_interpolator.py
Pluto9th/ctapipe
8c4faa674a1949210cbda8cb9e2413dd6362afea
[ "BSD-3-Clause" ]
null
null
null
""" This class is largely created as a more versatile alternative to the Linear ND interpolator, allowing the user to pass the interpolator an array of classes and then perform interpolation between the results of a member function of that class. Currently the name of the target interpolation function is passed in a st...
35.22541
88
0.60349
f2a792c261bfafd3e1f9039b1235a7f6df25614d
3,970
py
Python
model.py
Deferf/CLIP_Video_Representation
2fe3b5a17ea2dc96ff028ae088acc0080ebd07ec
[ "MIT" ]
45
2021-02-25T06:20:42.000Z
2022-03-21T05:14:06.000Z
model.py
Deferf/CLIP_Video_Representation
2fe3b5a17ea2dc96ff028ae088acc0080ebd07ec
[ "MIT" ]
2
2021-03-05T08:31:20.000Z
2021-03-05T10:26:23.000Z
model.py
Deferf/CLIP_Video_Representation
2fe3b5a17ea2dc96ff028ae088acc0080ebd07ec
[ "MIT" ]
4
2021-02-26T02:48:12.000Z
2022-02-22T09:45:08.000Z
import numpy as np import cv2 from PIL import Image import torch def encode_video(video_file, preprocess, model, resolution, image_mean, image_std): cap = cv2.VideoCapture(video_file) frameCount = int(cap.get(cv2.CAP_PROP_FRAME_COUNT)) frameWidth = int(cap.get(cv2.CAP_PROP_FRAME_WIDTH)) frameHeight = int(cap.g...
31.015625
111
0.702267
52bb29ea0388325491c9651180e3801e0716780c
1,349
py
Python
example/render/color.py
MRzNone/SAPIEN-Release
ae6662b7fb8f3c65a0eb6bb3bc3d7d53001d846e
[ "MIT" ]
null
null
null
example/render/color.py
MRzNone/SAPIEN-Release
ae6662b7fb8f3c65a0eb6bb3bc3d7d53001d846e
[ "MIT" ]
null
null
null
example/render/color.py
MRzNone/SAPIEN-Release
ae6662b7fb8f3c65a0eb6bb3bc3d7d53001d846e
[ "MIT" ]
null
null
null
import sapien.core as sapien from sapien.core import Pose import numpy as np from PIL import Image, ImageColor import open3d from sapien.asset import download_partnet_mobility my_token = "Your Access Token" sapien_assets_id = 179 urdf = download_partnet_mobility(sapien_assets_id, token=my_token) sim = sapien.Engine()...
26.45098
69
0.727205
691dfccd2cc255ba260e727db4c090fa6c45f073
395
py
Python
online_store/store/migrations/0031_auto_20201214_2012.py
PhiVaLo/final_project2
3d61404f2fe4b9e4503087e523ea16d6c411f57f
[ "Apache-2.0" ]
null
null
null
online_store/store/migrations/0031_auto_20201214_2012.py
PhiVaLo/final_project2
3d61404f2fe4b9e4503087e523ea16d6c411f57f
[ "Apache-2.0" ]
14
2020-12-06T13:31:34.000Z
2020-12-12T12:55:06.000Z
online_store/store/migrations/0031_auto_20201214_2012.py
PhiVaLo/final_project2
3d61404f2fe4b9e4503087e523ea16d6c411f57f
[ "Apache-2.0" ]
1
2020-12-17T14:33:19.000Z
2020-12-17T14:33:19.000Z
# Generated by Django 3.1.3 on 2020-12-14 19:12 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('store', '0030_auto_20201214_2011'), ] operations = [ migrations.AlterField( model_name='order', name='date_order', ...
20.789474
58
0.607595
c8f13a9a1b62c405517f1cd8b26a0cb3022bfb01
1,285
py
Python
biliob_spider/spiders/video_spider_all.py
ProgramRipper/biliob-spider
2fe3d5fd91bb301dd0d0eb21d03153d6882f6bcf
[ "MIT" ]
2
2021-02-21T05:49:17.000Z
2021-02-28T03:01:45.000Z
biliob_spider/spiders/video_spider_all.py
kirahan/biliob-spider
1a7c4a2b6781775c62c9a7d1aa2f1b0e2b0ab1f8
[ "MIT" ]
1
2022-03-20T07:59:27.000Z
2022-03-20T07:59:27.000Z
biliob_spider/spiders/video_spider_all.py
kirahan/biliob-spider
1a7c4a2b6781775c62c9a7d1aa2f1b0e2b0ab1f8
[ "MIT" ]
7
2021-02-13T16:58:49.000Z
2022-02-11T03:23:56.000Z
# coding=utf-8 import scrapy from scrapy.http import Request from biliob_spider.items import VideoItem from datetime import datetime import time import json import logging from pymongo import MongoClient from db import db from util import sub_channel_2_channel from biliob_spider.spiders.video_spider import VideoSpider...
24.711538
72
0.557977
968a6cfab2602b82cea3647c3515debe6d6d6c48
314
py
Python
PyObjCTest/test_nsurlcredentialstorage.py
Khan/pyobjc-framework-Cocoa
f8b015ea2a72d8d78be6084fb12925c4785b8f1f
[ "MIT" ]
132
2015-01-01T10:02:42.000Z
2022-03-09T12:51:01.000Z
mac/pyobjc-framework-Cocoa/PyObjCTest/test_nsurlcredentialstorage.py
mba811/music-player
7998986b34cfda2244ef622adefb839331b81a81
[ "BSD-2-Clause" ]
6
2015-01-06T08:23:19.000Z
2019-03-14T12:22:06.000Z
mac/pyobjc-framework-Cocoa/PyObjCTest/test_nsurlcredentialstorage.py
mba811/music-player
7998986b34cfda2244ef622adefb839331b81a81
[ "BSD-2-Clause" ]
27
2015-02-23T11:51:43.000Z
2022-03-07T02:34:18.000Z
from PyObjCTools.TestSupport import * from Foundation import * try: unicode except NameError: unicode = str class TestNSURLCredentialStorage (TestCase): def testConstants(self): self.assertIsInstance(NSURLCredentialStorageChangedNotification, unicode) if __name__ == "__main__": main()
19.625
81
0.751592
36cbc0c86939555099225e7cfb8962410cdd61d0
3,012
py
Python
Utils/Protocols/filltwitchusername.py
HeapUnderfl0w/Phaazebot
54e637bd4bc213b8efdaf23d5f331f2569e96843
[ "MIT" ]
null
null
null
Utils/Protocols/filltwitchusername.py
HeapUnderfl0w/Phaazebot
54e637bd4bc213b8efdaf23d5f331f2569e96843
[ "MIT" ]
null
null
null
Utils/Protocols/filltwitchusername.py
HeapUnderfl0w/Phaazebot
54e637bd4bc213b8efdaf23d5f331f2569e96843
[ "MIT" ]
null
null
null
# # This protocol will try to complete all entrys from the databases # twitch_user_name table. # # To be exact it tryes to get a username entry for every twitch id, # somewhere in the database. # twitch_user, discord_twitch_alert, twitch_channel, etc... # import os import sys sys.path.insert(0, f"{os.path.dirname(__fi...
28.149533
153
0.72842
5cf71b3165f23917191fe3e89f869be1cb6888a5
565
py
Python
src/calculate_features/helpers/features/coreness.py
flysoso/NetAna-Complex-Network-Analysis
3dd44a00f8af0cffb421e3d85b60bd46b22d99fe
[ "MIT" ]
3
2021-03-13T11:30:51.000Z
2021-07-26T11:26:23.000Z
src/calculate_features/helpers/features/coreness.py
flysoso/NetAna-Complex-Network-Analysis
3dd44a00f8af0cffb421e3d85b60bd46b22d99fe
[ "MIT" ]
null
null
null
src/calculate_features/helpers/features/coreness.py
flysoso/NetAna-Complex-Network-Analysis
3dd44a00f8af0cffb421e3d85b60bd46b22d99fe
[ "MIT" ]
null
null
null
''' Return the core number for each vertex. A k-core is a maximal subgraph that contains nodes of degree k or more. The core number of a node is the largest value k of a k-core containing that node. ''' import networkx as nx def calculate(net): if net.number_of_selfloops() > 0: try: net.re...
18.225806
82
0.60177
e462bcafac116f0bbc305f6d287781562be5b8ba
1,174
py
Python
xml-json/requests/requests_test.py
sanikamal/awesome-python-examples
998dd2b1ef31714f20f6e6aa061ac1f303026e84
[ "MIT" ]
1
2020-07-07T23:36:51.000Z
2020-07-07T23:36:51.000Z
xml-json/requests/requests_test.py
sanikamal/awesome-python-examples
998dd2b1ef31714f20f6e6aa061ac1f303026e84
[ "MIT" ]
null
null
null
xml-json/requests/requests_test.py
sanikamal/awesome-python-examples
998dd2b1ef31714f20f6e6aa061ac1f303026e84
[ "MIT" ]
null
null
null
# using the requests library to access internet data #import the requests library import requests def main(): # Use requests to issue a standard HTTP GET request url = "http://httpbin.org/xml" result = requests.get(url) printResults(result) # Send some parameters to the URL via a GET request ...
27.302326
65
0.627768
e930fb0e94a87c5f20c9de0e2df3e9e168cebd06
2,234
py
Python
shopping_search/tests/test_results_transforms.py
enkidulan/goods_search
2000057050b73fa252fd7390dc9a0190648bc70a
[ "Apache-2.0" ]
null
null
null
shopping_search/tests/test_results_transforms.py
enkidulan/goods_search
2000057050b73fa252fd7390dc9a0190648bc70a
[ "Apache-2.0" ]
null
null
null
shopping_search/tests/test_results_transforms.py
enkidulan/goods_search
2000057050b73fa252fd7390dc9a0190648bc70a
[ "Apache-2.0" ]
null
null
null
import unittest from copy import deepcopy from collections import OrderedDict from testfixtures import compare, replace from shopping_search.views import merge_results TEST_SERVICES_DATA = ( {'service': 'amazon', 'data': [{'price': 100}, {'price': 10}, {'price': 50}, {'price': 11}, {'price': 15}]}, {'service...
30.60274
112
0.487466