hexsha
stringlengths
40
40
size
int64
2
1.05M
ext
stringclasses
9 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
193
max_stars_repo_name
stringlengths
6
109
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
36.6k
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
193
max_issues_repo_name
stringlengths
6
109
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
29.8k
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
193
max_forks_repo_name
stringlengths
6
109
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
11.2k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
2
1.05M
avg_line_length
float64
1
404k
max_line_length
int64
1
1.03M
alphanum_fraction
float64
0
1
91cc6b53fcb6dc6dd12dc5229d14b3756ddc1385
2,004
py
Python
python-src/graphoire/linalg/graph2matrix.py
ccorbell/graphoire
566b0a27a9d6b87c5952bcc6e257a6d90621ca06
[ "Apache-2.0" ]
null
null
null
python-src/graphoire/linalg/graph2matrix.py
ccorbell/graphoire
566b0a27a9d6b87c5952bcc6e257a6d90621ca06
[ "Apache-2.0" ]
null
null
null
python-src/graphoire/linalg/graph2matrix.py
ccorbell/graphoire
566b0a27a9d6b87c5952bcc6e257a6d90621ca06
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Sun Mar 7 18:50:04 2021 @author: mathaes """ import numpy as np from scipy.sparse import coo_matrix from graphoire.graph import Graph def graphToAdjacencyMatrix(G: Graph): """ Returns an adjacency matrix for Graph, as a scipy.sparse.coo_...
27.081081
105
0.558383
91cca3a1ce7e305f7c8fa5ec0e736b19bf99741b
1,908
py
Python
129/save2_nopass.py
rayjustinhuang/BitesofPy
03b694c5259ff607621419d9677c5caff90a6057
[ "MIT" ]
null
null
null
129/save2_nopass.py
rayjustinhuang/BitesofPy
03b694c5259ff607621419d9677c5caff90a6057
[ "MIT" ]
null
null
null
129/save2_nopass.py
rayjustinhuang/BitesofPy
03b694c5259ff607621419d9677c5caff90a6057
[ "MIT" ]
null
null
null
import requests from collections import Counter STOCK_DATA = 'https://bit.ly/2MzKAQg' # pre-work: load JSON data into program with requests.Session() as s: data = s.get(STOCK_DATA).json() #print(data) # your turn: def _cap_str_to_mln_float(cap): """If cap = 'n/a' return 0, else: - strip off leading ...
29.8125
84
0.660377
91ccbb46b4a8511d946dfd941b33f411d0f60360
4,464
py
Python
qiskit/chemistry/drivers/fcidumpd/fcidumpdriver.py
MetcalfeTom/qiskit-aqua
1718e1612dba38a3f15309c860fe7875914fe8cc
[ "Apache-2.0" ]
null
null
null
qiskit/chemistry/drivers/fcidumpd/fcidumpdriver.py
MetcalfeTom/qiskit-aqua
1718e1612dba38a3f15309c860fe7875914fe8cc
[ "Apache-2.0" ]
null
null
null
qiskit/chemistry/drivers/fcidumpd/fcidumpdriver.py
MetcalfeTom/qiskit-aqua
1718e1612dba38a3f15309c860fe7875914fe8cc
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # This code is part of Qiskit. # # (C) Copyright IBM 2020. # # 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 modif...
41.333333
100
0.651882
91ccd1079f8b5c8ff1e637c2e537c50e4be1aa39
47,433
py
Python
mcscf/mc1step.py
gmwang18/pyscf
fcd6877751661c8a9743c1c872a4a2b65f6dd7ac
[ "BSD-2-Clause" ]
null
null
null
mcscf/mc1step.py
gmwang18/pyscf
fcd6877751661c8a9743c1c872a4a2b65f6dd7ac
[ "BSD-2-Clause" ]
null
null
null
mcscf/mc1step.py
gmwang18/pyscf
fcd6877751661c8a9743c1c872a4a2b65f6dd7ac
[ "BSD-2-Clause" ]
null
null
null
#!/usr/bin/env python # # Author: Qiming Sun <osirpt.sun@gmail.com> # import sys import time import copy from functools import reduce import numpy import scipy.linalg from pyscf import lib from pyscf.lib import logger from pyscf.mcscf import casci from pyscf.mcscf.casci import get_fock, cas_natorb, canonicalize from p...
40.645244
110
0.564333
91cce2f6db240cd70e7ac0d47ee12b29d6b20a70
14,061
py
Python
sdk/identity/azure-identity/tests/test_powershell_credential.py
vincenttran-msft/azure-sdk-for-python
348b56f9f03eeb3f7b502eed51daf494ffff874d
[ "MIT" ]
1
2022-03-09T08:59:13.000Z
2022-03-09T08:59:13.000Z
sdk/identity/azure-identity/tests/test_powershell_credential.py
vincenttran-msft/azure-sdk-for-python
348b56f9f03eeb3f7b502eed51daf494ffff874d
[ "MIT" ]
null
null
null
sdk/identity/azure-identity/tests/test_powershell_credential.py
vincenttran-msft/azure-sdk-for-python
348b56f9f03eeb3f7b502eed51daf494ffff874d
[ "MIT" ]
null
null
null
# ------------------------------------ # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # ------------------------------------ import base64 import logging from platform import python_version import re import subprocess import sys import time try: from unittest.mock import Mock, patch excep...
44.496835
1,445
0.708484
91ccee5016680f122efeee7e174bf8328c7bc6f3
1,061
py
Python
setup.py
ManuelALH/ProyectoTeoriaComputacionDFA
f989c71934f2d31f25c31f60ed1aab9e8e0a971a
[ "MIT" ]
null
null
null
setup.py
ManuelALH/ProyectoTeoriaComputacionDFA
f989c71934f2d31f25c31f60ed1aab9e8e0a971a
[ "MIT" ]
null
null
null
setup.py
ManuelALH/ProyectoTeoriaComputacionDFA
f989c71934f2d31f25c31f60ed1aab9e8e0a971a
[ "MIT" ]
null
null
null
import pathlib from setuptools import setup # The directory containing this file HERE = pathlib.Path(__file__).parent # The text of the README file README = (HERE / "README.md").read_text() # This call to setup() does all the work setup( name="visual-automata", version="1.0", description="Automate creado...
26.525
96
0.656927
91cd6ba2190a74c7c42b3e444de5c3113f40d90f
15,553
py
Python
ThirdParty/Twisted/twisted/test/test_pbfailure.py
OpenGeoscience/VTK
a373e975b9284a022f43a062ebf5042bb17b4e44
[ "BSD-3-Clause" ]
7
2015-04-28T13:26:11.000Z
2020-02-09T17:01:04.000Z
ThirdParty/Twisted/twisted/test/test_pbfailure.py
OpenGeoscience/VTK
a373e975b9284a022f43a062ebf5042bb17b4e44
[ "BSD-3-Clause" ]
4
2017-02-19T23:58:13.000Z
2019-11-01T15:31:22.000Z
ThirdParty/Twisted/twisted/test/test_pbfailure.py
OpenGeoscience/VTK
a373e975b9284a022f43a062ebf5042bb17b4e44
[ "BSD-3-Clause" ]
6
2017-02-13T09:11:02.000Z
2021-06-29T11:22:18.000Z
# Copyright (c) Twisted Matrix Laboratories. # See LICENSE for details. """ Tests for error handling in PB. """ import sys from StringIO import StringIO from twisted.trial import unittest from twisted.spread import pb, flavors, jelly from twisted.internet import reactor, defer from twisted.python import log ## # t...
32.67437
93
0.650614
91cd882b555dcd6aad25bd7f3a35d5af7d69102e
2,152
py
Python
tests/test_wormbase.py
sgml/dipper
cff0d01299e982183a5345b8a7eb00094ed05257
[ "BSD-3-Clause" ]
null
null
null
tests/test_wormbase.py
sgml/dipper
cff0d01299e982183a5345b8a7eb00094ed05257
[ "BSD-3-Clause" ]
null
null
null
tests/test_wormbase.py
sgml/dipper
cff0d01299e982183a5345b8a7eb00094ed05257
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python3 import unittest import logging import os from dipper.graph.RDFGraph import RDFGraph from dipper.utils.rdf2dot import rdf2dot from dipper.sources.WormBase import WormBase logging.basicConfig() logging.getLogger().setLevel(logging.WARN) LOG = logging.getLogger(__name__) TEST_PATH = os.path.join(o...
28.315789
74
0.63987
91cd96e2d41d8c350cc2ecb9f0f191a65d468835
196
py
Python
src/py/wxyz_core/src/wxyz/core/_version.py
dfreeman06/wxyz
663cf6593f4c0ca12f7b94b61e34c0a8d3cbcdfd
[ "BSD-3-Clause" ]
1
2021-06-20T12:21:27.000Z
2021-06-20T12:21:27.000Z
src/py/wxyz_core/src/wxyz/core/_version.py
nrbgt/wxyz
663cf6593f4c0ca12f7b94b61e34c0a8d3cbcdfd
[ "BSD-3-Clause" ]
null
null
null
src/py/wxyz_core/src/wxyz/core/_version.py
nrbgt/wxyz
663cf6593f4c0ca12f7b94b61e34c0a8d3cbcdfd
[ "BSD-3-Clause" ]
null
null
null
""" some constants """ # pylint: disable=invalid-name version_info = (0, 2, 0, "dev") __version__ = ".".join(map(str, version_info)) module_name = "@deathbeds/wxyz-core" module_version = "^0.2.0"
24.5
46
0.678571
91cd98d7b208fb40f8e36579c0a71e954678857d
3,217
py
Python
train_pointnet.py
BowenRaymone/KaggleLyftCompetition
fcbc1e89c4c30132917842f7ad8cba09415cc76f
[ "MIT" ]
2
2021-03-09T13:27:42.000Z
2021-07-26T13:15:35.000Z
train_pointnet.py
BowenRaymone/KaggleLyftCompetition
fcbc1e89c4c30132917842f7ad8cba09415cc76f
[ "MIT" ]
null
null
null
train_pointnet.py
BowenRaymone/KaggleLyftCompetition
fcbc1e89c4c30132917842f7ad8cba09415cc76f
[ "MIT" ]
1
2021-04-07T14:25:05.000Z
2021-04-07T14:25:05.000Z
from abc import ABC from pathlib import Path from numcodecs import blosc import pandas as pd, numpy as np import os import bisect import itertools as it from tqdm import tqdm import logzero import torch from torch import nn, optim import torch.nn.functional as F from torch.autograd import Variable from pytorch_ligh...
32.17
173
0.737955
91cdc52ec8a320f5387995111df6a12fb4133a60
3,536
py
Python
bloodsword/domain/values.py
uliang/BloodSword
fc7e173ce56989c48009ec86d834072f9f2e70ac
[ "BSD-2-Clause" ]
null
null
null
bloodsword/domain/values.py
uliang/BloodSword
fc7e173ce56989c48009ec86d834072f9f2e70ac
[ "BSD-2-Clause" ]
null
null
null
bloodsword/domain/values.py
uliang/BloodSword
fc7e173ce56989c48009ec86d834072f9f2e70ac
[ "BSD-2-Clause" ]
null
null
null
from __future__ import annotations from abc import ABC, abstractclassmethod, abstractmethod, abstractproperty from dataclasses import dataclass, field from math import floor from typing import Optional from .enumeration import Square @dataclass class Vector: """ Representation of a 2d vector. We follo...
22.961039
79
0.57664
91cddd28eeb06639e166070ea07eb4135a9f5d8b
6,235
py
Python
src/common/dirhelper.py
vsbogd/language-learning
601e7bc7f97a0b6c1f713f8108fc6e81d492e921
[ "MIT" ]
21
2018-01-30T08:18:20.000Z
2020-02-18T08:15:53.000Z
src/common/dirhelper.py
vsbogd/language-learning
601e7bc7f97a0b6c1f713f8108fc6e81d492e921
[ "MIT" ]
3
2018-02-09T18:22:45.000Z
2018-07-10T10:31:25.000Z
src/common/dirhelper.py
vsbogd/language-learning
601e7bc7f97a0b6c1f713f8108fc6e81d492e921
[ "MIT" ]
10
2018-01-30T10:31:43.000Z
2021-01-26T07:54:24.000Z
import os # from grammar_tester.lgmisc import LGParseError __all__ = ['traverse_dir', 'create_dir', 'traverse_dir_tree'] def traverse_dir_tree(root: str, file_ext: str, file_arg_list: list=None, dir_arg_list: list=None, is_recursive: bool=False): """ Perform argument check and if a...
41.845638
120
0.664314
91ce36645c314833884b33272a61b7794d9f7cdc
6,756
py
Python
p2p/nat.py
jin10086/py-evm
da04e8de42fdbf3bc5ca596f5f6b3d810c1afea8
[ "MIT" ]
5
2018-09-28T20:01:42.000Z
2022-02-22T19:54:46.000Z
p2p/nat.py
jin10086/py-evm
da04e8de42fdbf3bc5ca596f5f6b3d810c1afea8
[ "MIT" ]
null
null
null
p2p/nat.py
jin10086/py-evm
da04e8de42fdbf3bc5ca596f5f6b3d810c1afea8
[ "MIT" ]
1
2019-02-27T21:29:16.000Z
2019-02-27T21:29:16.000Z
import asyncio from concurrent.futures import ( ThreadPoolExecutor, ) import ipaddress from typing import ( AsyncGenerator, NamedTuple, ) from urllib.parse import urlparse from cancel_token import ( CancelToken, OperationCancelled, ) from p2p.exceptions import ( NoInternalAddressMatchesDevice, ...
37.955056
95
0.621966
91ce872d7cb28c4c6e7f34ced8f5668009848dc7
1,380
py
Python
Seeder/legacy_db/migrations/0002_conspectusen_conspectussubcategoriesen.py
WebarchivCZ/Seeder
1958c5d3f6bdcbbdb2c81dcb6abc7f689125b6a8
[ "MIT" ]
8
2017-08-16T19:18:57.000Z
2022-01-24T10:08:19.000Z
Seeder/legacy_db/migrations/0002_conspectusen_conspectussubcategoriesen.py
WebarchivCZ/Seeder
1958c5d3f6bdcbbdb2c81dcb6abc7f689125b6a8
[ "MIT" ]
242
2017-02-03T19:15:52.000Z
2022-03-25T08:02:52.000Z
Seeder/legacy_db/migrations/0002_conspectusen_conspectussubcategoriesen.py
WebarchivCZ/Seeder
1958c5d3f6bdcbbdb2c81dcb6abc7f689125b6a8
[ "MIT" ]
2
2019-03-06T12:36:29.000Z
2019-07-08T12:52:20.000Z
# -*- coding: utf-8 -*- # Generated by Django 1.10.4 on 2017-07-25 01:17 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('legacy_db', '0001_initial'), ] operations = [ migrations.CreateModel( ...
33.658537
114
0.55
91cec6b12809c6470bb3d3a0e95b3ba6e34c720b
3,512
py
Python
joulescope/entry_points/runner.py
tadodotcom/pyjoulescope
ab9645a2774cf5d5355dee4c1e60a566419b0e00
[ "Apache-2.0" ]
29
2018-12-19T22:42:09.000Z
2022-01-31T12:26:52.000Z
joulescope/entry_points/runner.py
tadodotcom/pyjoulescope
ab9645a2774cf5d5355dee4c1e60a566419b0e00
[ "Apache-2.0" ]
23
2019-07-21T23:44:46.000Z
2022-03-11T13:29:11.000Z
joulescope/entry_points/runner.py
tadodotcom/pyjoulescope
ab9645a2774cf5d5355dee4c1e60a566419b0e00
[ "Apache-2.0" ]
9
2019-07-22T00:07:53.000Z
2021-11-26T11:46:19.000Z
#!/usr/bin/env python3 # Copyright 2018 Jetperch 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 o...
31.927273
128
0.684226
91ceca9e0509fb163ffb1f1cd18f8ad262e936bc
3,775
py
Python
experiments/ashvin/icml2020/mujoco/bc/halfcheetah_mixture2.py
Asap7772/railrl_evalsawyer
baba8ce634d32a48c7dfe4dc03b123e18e96e0a3
[ "MIT" ]
null
null
null
experiments/ashvin/icml2020/mujoco/bc/halfcheetah_mixture2.py
Asap7772/railrl_evalsawyer
baba8ce634d32a48c7dfe4dc03b123e18e96e0a3
[ "MIT" ]
null
null
null
experiments/ashvin/icml2020/mujoco/bc/halfcheetah_mixture2.py
Asap7772/railrl_evalsawyer
baba8ce634d32a48c7dfe4dc03b123e18e96e0a3
[ "MIT" ]
null
null
null
""" AWR + SAC from demo experiment """ from rlkit.demos.source.dict_to_mdp_path_loader import DictToMDPPathLoader from rlkit.launchers.experiments.awac.awac_rl import experiment import rlkit.misc.hyperparameter as hyp from rlkit.launchers.arglauncher import run_variants from rlkit.torch.sac.policies import GaussianM...
30.443548
130
0.569272
91cedd4fb4656dcf1e47a518dce06bd125bddac9
7,143
py
Python
src/retype/retype_hgext.py
ambv/retype
53ea14012ec8a7190cb2aa335e855a79f51e71b6
[ "MIT" ]
127
2017-03-13T19:27:02.000Z
2022-03-26T01:28:23.000Z
src/retype/retype_hgext.py
gaborbernat/retype
53ea14012ec8a7190cb2aa335e855a79f51e71b6
[ "MIT" ]
23
2017-06-07T14:59:54.000Z
2021-12-03T02:14:01.000Z
src/retype/retype_hgext.py
ambv/retype
53ea14012ec8a7190cb2aa335e855a79f51e71b6
[ "MIT" ]
20
2017-06-08T11:46:22.000Z
2021-10-04T09:14:38.000Z
from __future__ import annotations import io import token import tokenize from typing import cast try: from mercurial import replacetokens except ImportError: # NOTE: the following is taken directly from `mercurial/__init__.py` in # Mercurial 4.1.2. # Code by Gregory Szorc, Martijn Pieters, Yuya Nishi...
40.585227
88
0.531009
91cf0bb4e53b41ac01cf79228b1ac53df631f836
3,275
py
Python
examples/two_fans.py
HANhuiyu/SpikingStereoMatching
ef216701286e85e5df6691001299968f15bcede9
[ "MIT" ]
1
2016-09-08T12:45:41.000Z
2016-09-08T12:45:41.000Z
examples/two_fans.py
gdikov/StereoVision_HBPPlatform
ef216701286e85e5df6691001299968f15bcede9
[ "MIT" ]
null
null
null
examples/two_fans.py
gdikov/StereoVision_HBPPlatform
ef216701286e85e5df6691001299968f15bcede9
[ "MIT" ]
2
2019-04-11T15:04:01.000Z
2021-06-07T19:40:29.000Z
### # Date: August 2016 # Author: Georgi Dikov # email: gvdikov93@gmail.com ### from network import CooperativeNetwork, Retina, ExternalInputReader, SNNSimulation import os def run_experiment_fans(with_visualization=False): """ TODO: add experiment description. """ experiment_name = "Back_Front" ...
41.455696
84
0.590534
91cf0c23c162dbe7d8979d5ad3bd37d0672fdeb3
490
py
Python
backend/api/migrations/0010_proceduredesc_description.py
Carbonara-Project/Carbonara-Web
be1fac46ed3e4f590f3d885e646970a29ec43cb5
[ "MIT" ]
2
2020-01-07T12:35:11.000Z
2021-09-18T10:30:57.000Z
backend/api/migrations/0010_proceduredesc_description.py
Carbonara-Project/Carbonara-Web
be1fac46ed3e4f590f3d885e646970a29ec43cb5
[ "MIT" ]
null
null
null
backend/api/migrations/0010_proceduredesc_description.py
Carbonara-Project/Carbonara-Web
be1fac46ed3e4f590f3d885e646970a29ec43cb5
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by Django 1.11.5 on 2018-03-21 18:57 from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('api', '0009_auto_20180318_1028'), ] operations = [ migrations.AddField( ...
22.272727
48
0.612245
91cf0fede3ec343ab1823e07098f86db36887d21
610
py
Python
tests/outlookservices/outlook_case.py
wreiner/Office365-REST-Python-Client
476bbce4f5928a140b4f5d33475d0ac9b0783530
[ "MIT" ]
null
null
null
tests/outlookservices/outlook_case.py
wreiner/Office365-REST-Python-Client
476bbce4f5928a140b4f5d33475d0ac9b0783530
[ "MIT" ]
null
null
null
tests/outlookservices/outlook_case.py
wreiner/Office365-REST-Python-Client
476bbce4f5928a140b4f5d33475d0ac9b0783530
[ "MIT" ]
null
null
null
from unittest import TestCase from settings import settings from office365.outlookservices.outlook_client import OutlookClient class OutlookClientTestCase(TestCase): """SharePoint specific test case base class""" @classmethod def setUpClass(cls): client_id = settings.get('client_credentials').g...
33.888889
71
0.732787
91cf1bd2feeccc6b6484cefc80a39a5ff0b7a2fa
1,059
py
Python
WP3/Task3.3/src/models/base_model.py
on-merrit/ON-MERRIT
a21324a54a6365f2f769b5952b0cf5347a97d480
[ "MIT" ]
2
2019-12-10T13:10:58.000Z
2019-12-13T10:11:41.000Z
WP3/Task3.3/src/models/base_model.py
on-merrit/ON-MERRIT
a21324a54a6365f2f769b5952b0cf5347a97d480
[ "MIT" ]
4
2020-03-31T12:13:45.000Z
2020-04-15T15:59:17.000Z
WP3/Task3.2/src/models/base_model.py
on-merrit/ON-MERRIT
a21324a54a6365f2f769b5952b0cf5347a97d480
[ "MIT" ]
1
2020-02-26T08:52:39.000Z
2020-02-26T08:52:39.000Z
import abc from typing import Dict, Union, Iterable __author__ = 'dh8835' __email__ = 'dasha.herrmannova@open.ac.uk' class BaseModel(object, metaclass=abc.ABCMeta): @abc.abstractmethod def train_test( self, X_train: 'np.array[np.int64]', X_test: 'np.array[np.int64]', y_train: Iterable[int]...
35.3
79
0.66289
91cf2a00fb2377977c49821af0afc845e5d9505e
1,168
py
Python
adpkd_segmentation/utils/csv_attribs.py
Florassss/adpkd-segmentation-pytorch
ce06bcf9a5028836255d5845fd9017d6828d6bf7
[ "MIT" ]
5
2021-07-09T16:10:56.000Z
2022-03-23T10:22:16.000Z
adpkd_segmentation/utils/csv_attribs.py
Florassss/adpkd-segmentation-pytorch
ce06bcf9a5028836255d5845fd9017d6828d6bf7
[ "MIT" ]
3
2021-06-23T02:47:42.000Z
2022-02-04T22:43:27.000Z
adpkd_segmentation/utils/csv_attribs.py
Florassss/adpkd-segmentation-pytorch
ce06bcf9a5028836255d5845fd9017d6828d6bf7
[ "MIT" ]
2
2021-06-05T22:19:29.000Z
2022-03-13T20:50:13.000Z
# %% import pandas as pd from data.data_config import dataroot # %% csv_path = dataroot + "pkd_mutation_data/csv_attributes.csv" class CsvAttribs: def __init__(self, path=None): super().__init__() if path == None: path = f"{dataroot}pkd_mutation_data/csv_attributes.csv" self...
22.901961
68
0.531678
91cf565efed4c8a61ab6d5ad9c76bc7fdf610283
10,245
py
Python
usecases/hausdorff/hausdorff_example.py
chemlove/radical.ensemblemd
0ec4b127760d2fee88d4eae1768fecec4bdd6b21
[ "MIT" ]
null
null
null
usecases/hausdorff/hausdorff_example.py
chemlove/radical.ensemblemd
0ec4b127760d2fee88d4eae1768fecec4bdd6b21
[ "MIT" ]
null
null
null
usecases/hausdorff/hausdorff_example.py
chemlove/radical.ensemblemd
0ec4b127760d2fee88d4eae1768fecec4bdd6b21
[ "MIT" ]
null
null
null
#!/usr/bin/env python """ Hausdorff Distance calculation script for Ensemble MD Toolkit """ __author__ = "Ioannis Paraskevakos <i.parask@rutgers.edu>" __copyright__ = "Copyright 2014, http://radical.rutgers.edu" __license__ = "MIT" import math import os import ast from radical.ensemblemd import Kernel...
36.98556
129
0.544949
91cfadfd58dcaff1fdb8600ef5cb0bb1375291f0
900
py
Python
aspire/cli.py
Constructionware/aspireAPI
b558fa2f3971698f2784d8b03e1241f282a1df0b
[ "MIT" ]
1
2022-01-20T04:15:27.000Z
2022-01-20T04:15:27.000Z
aspire/cli.py
Constructionware/aspire
b558fa2f3971698f2784d8b03e1241f282a1df0b
[ "MIT" ]
null
null
null
aspire/cli.py
Constructionware/aspire
b558fa2f3971698f2784d8b03e1241f282a1df0b
[ "MIT" ]
null
null
null
"""Aspire. Usage: aspire aspire create 'app' aspire run [--build] [--debug] <module> aspire build aspire --version Options: -h --help Show this screen. -v --version Show version. """ import os import docopt from .__version__ import __version__ def cli(): args = docopt.docopt( __do...
18
79
0.561111
91cfb82c00ce3789a06fcdafa00deae19b3dcf8d
8,322
py
Python
test/test_pipelines_1.py
lacker/turbo_seti
4135c65a912f3c6c628c4434ba6b19735ee6fd80
[ "MIT" ]
1
2020-07-08T15:37:55.000Z
2020-07-08T15:37:55.000Z
test/test_pipelines_1.py
lacker/turbo_seti
4135c65a912f3c6c628c4434ba6b19735ee6fd80
[ "MIT" ]
null
null
null
test/test_pipelines_1.py
lacker/turbo_seti
4135c65a912f3c6c628c4434ba6b19735ee6fd80
[ "MIT" ]
null
null
null
r''' test_pipelines.py Using the 0000.h5 Voyager 2020 set of HDF5 files from http://blpd14.ssl.berkeley.edu/voyager_2020/single_coarse_channel/ test the following: * FindDoppler seaarch * find_event_pipeline * plot_event_pipeline ''' from time import time from shutil import rmtree from pathlib import Path from os imp...
34.820084
92
0.639029
91cfbe246d318c1a8484f89e43de82ab6b1203eb
725
py
Python
setup.py
SMSinclair/stevedata
9582863b4cad23d3b7364b699f854e8a12928a01
[ "MIT" ]
null
null
null
setup.py
SMSinclair/stevedata
9582863b4cad23d3b7364b699f854e8a12928a01
[ "MIT" ]
3
2020-03-24T17:25:38.000Z
2021-06-02T00:15:21.000Z
setup.py
SMSinclair/stevedata
9582863b4cad23d3b7364b699f854e8a12928a01
[ "MIT" ]
null
null
null
import setuptools REQUIRED = [ "numpy", "pandas" ] with open('README.md', 'r') as fh: long_description = fh.read() setuptools.setup( name='stevedata-smsinclair', version='0.1.1', author='SMSinclair@gmail.com', author_email='smsinclair@gmail.com', description='Some very basic DataFrame...
26.851852
92
0.65931
91cffd1250c8afd7959d3f5b7288a36c6efaa092
2,719
py
Python
billingclient/v1/rating/gnocchi/__init__.py
nubeliu/billingclient
f2539e211ca049f3ddc9ce5680932f8f5eff7434
[ "Apache-2.0" ]
1
2018-01-04T16:20:51.000Z
2018-01-04T16:20:51.000Z
billingclient/v1/rating/gnocchi/__init__.py
nubeliu/billingclient
f2539e211ca049f3ddc9ce5680932f8f5eff7434
[ "Apache-2.0" ]
null
null
null
billingclient/v1/rating/gnocchi/__init__.py
nubeliu/billingclient
f2539e211ca049f3ddc9ce5680932f8f5eff7434
[ "Apache-2.0" ]
null
null
null
# NubeliU Billing SDK # @autor: Sergio Colinas from billingclient.common import base class MetricRuleSet(base.Resource): key = 'metric_rule_set' def __repr__(self): return "<gnocchi.MetricRuleSet %s>" % self._info @property def metadata_rule_sets(self): return MetadataRuleSetManager...
25.411215
74
0.696212
91d022c6a80a006772ab5c6df1831ff4ba1804b2
16,216
py
Python
spinup/algos/pytorch/td3_tune_rew/td3.py
LinghengMeng/lstm_td3
2306a4f0e84417e92b9d77627abc8a7f1925f2b1
[ "MIT" ]
2
2021-04-22T01:17:37.000Z
2021-07-22T09:56:44.000Z
spinup/algos/pytorch/td3_tune_rew/td3.py
LinghengMeng/lstm_td3
2306a4f0e84417e92b9d77627abc8a7f1925f2b1
[ "MIT" ]
null
null
null
spinup/algos/pytorch/td3_tune_rew/td3.py
LinghengMeng/lstm_td3
2306a4f0e84417e92b9d77627abc8a7f1925f2b1
[ "MIT" ]
3
2021-05-05T10:27:12.000Z
2021-07-23T14:42:42.000Z
from copy import deepcopy import itertools import numpy as np import torch from torch.optim import Adam import gym import pybullet_envs import time import spinup.algos.pytorch.td3_tune_rew.core as core from spinup.utils.logx import EpochLogger, setup_logger_kwargs import os.path as osp class ReplayBuffer: """ ...
40.54
125
0.602676
91d0497805f34ddd1b02fc0c99e996a2b5996dd3
13,013
py
Python
python/geoclaw/gaugedata.py
geoflows/geoclaw-4.x
c8879d25405017b38392aa3b1ea422ff3e3604ea
[ "BSD-3-Clause" ]
7
2016-11-13T03:11:51.000Z
2021-09-07T18:59:48.000Z
python/geoclaw/gaugedata.py
geoflows/geoclaw-4.x
c8879d25405017b38392aa3b1ea422ff3e3604ea
[ "BSD-3-Clause" ]
11
2020-01-14T18:00:37.000Z
2022-03-29T14:25:24.000Z
python/geoclaw/gaugedata.py
geoflows/geoclaw-4.x
c8879d25405017b38392aa3b1ea422ff3e3604ea
[ "BSD-3-Clause" ]
6
2020-01-14T17:15:42.000Z
2021-12-03T17:28:44.000Z
#!/usr/bin/python """ gaugedata ========= Provides routines for analyzing gauge data as output from Geoclaw files: fort.gauge. see: gaugedata.fortgaugeread gaugedata.fortgaugeread1d gaugedata.plotgauge gaugedata.plotfortgauge gaugedata.writegdata gaugedata.readgdata g...
28.726269
164
0.542765
91d077b7aa7fa6ea91961fdb894ed12b0de6c9b3
20,866
py
Python
gui/page_user.py
sharksmhi/SHARKtools_qc_sensors
c5a87cb8537f4da43add918c6e0a1db19749b065
[ "MIT" ]
null
null
null
gui/page_user.py
sharksmhi/SHARKtools_qc_sensors
c5a87cb8537f4da43add918c6e0a1db19749b065
[ "MIT" ]
null
null
null
gui/page_user.py
sharksmhi/SHARKtools_qc_sensors
c5a87cb8537f4da43add918c6e0a1db19749b065
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright (c) 2018 SMHI, Swedish Meteorological and Hydrological Institute # License: MIT License (see LICENSE.txt or http://opensource.org/licenses/mit). import tkinter as tk from tkinter import ttk import matplotlib.pyplot as plt import sharkpylib.tklib.tkinter_widgets as tkw from sharkpyl...
47.10158
167
0.521374
91d0a2b54867e8a8691153bde575f605fb92c3ce
3,032
py
Python
analyze_results/cifar/one_dimensional_subspaces.py
LaudateCorpus1/learning-subspaces
240122f8a875f580eca92325fb06a98bf71bbf3e
[ "AML" ]
105
2021-03-30T06:03:44.000Z
2022-03-03T15:50:41.000Z
analyze_results/cifar/one_dimensional_subspaces.py
LaudateCorpus1/learning-subspaces
240122f8a875f580eca92325fb06a98bf71bbf3e
[ "AML" ]
3
2021-07-16T04:46:25.000Z
2022-01-29T04:47:26.000Z
analyze_results/cifar/one_dimensional_subspaces.py
LaudateCorpus1/learning-subspaces
240122f8a875f580eca92325fb06a98bf71bbf3e
[ "AML" ]
12
2021-03-23T17:24:43.000Z
2022-03-26T11:43:12.000Z
# # For licensing see accompanying LICENSE file. # Copyright (C) 2020 Apple Inc. All Rights Reserved. # import matplotlib.pyplot as plt import viz.utils as utils from viz.config import fs_helper from viz.config import helper def lvh_helper(ax, setxax=True, setyax=True): one_dim_subspace_data = utils.read_csv_fi...
21.971014
91
0.55277
91d100cdf8be108c571e603a59475c5191588b48
216
py
Python
api/classification/random_forest.py
xiafanzeng/Raman-Spectroscopy
ba0b8b7ad0d9b9487a7602b0a09a41d970f70598
[ "MIT" ]
4
2021-03-19T14:09:41.000Z
2022-01-09T09:33:55.000Z
api/classification/random_forest.py
xiafanzeng/Raman-Spectroscopy
ba0b8b7ad0d9b9487a7602b0a09a41d970f70598
[ "MIT" ]
null
null
null
api/classification/random_forest.py
xiafanzeng/Raman-Spectroscopy
ba0b8b7ad0d9b9487a7602b0a09a41d970f70598
[ "MIT" ]
1
2022-02-24T07:18:41.000Z
2022-02-24T07:18:41.000Z
from sklearn.ensemble import RandomForestClassifier def rf_clf(sample, data): clf = RandomForestClassifier(n_estimators=10) clf.fit(data[0], data[1]) return clf.predict(sample)[0] return 'rf clf'
27
51
0.717593
91d122a8655fac77e47bcca5b46f9418c1e3c873
147
py
Python
earlier-2020/pytorch/tensor_init.py
transcendentsky/py_tutorials
fed8e6c8d79f854a1cebcfd5c37297a163846208
[ "Apache-2.0" ]
1
2018-06-18T12:09:33.000Z
2018-06-18T12:09:33.000Z
earlier-2020/pytorch/tensor_init.py
transcendentsky/py_tutorials
fed8e6c8d79f854a1cebcfd5c37297a163846208
[ "Apache-2.0" ]
null
null
null
earlier-2020/pytorch/tensor_init.py
transcendentsky/py_tutorials
fed8e6c8d79f854a1cebcfd5c37297a163846208
[ "Apache-2.0" ]
1
2018-06-18T12:13:21.000Z
2018-06-18T12:13:21.000Z
import torch num = 32 num_priors = 8732 print(num, num_priors) loc_t = torch.Tensor(num, num_priors, 4) print(loc_t) t = torch.cat(1,1) print(t)
13.363636
40
0.714286
91d13bfd7cd142cb0c78f4f20259f1618829e235
907
py
Python
demos/show_transform/show_gft_L.py
bwdeng20/thgsp
785b3ff291d72ee51e51e4cdbfd4bab63f8de9ac
[ "BSD-3-Clause" ]
22
2021-01-13T05:15:38.000Z
2022-01-17T01:37:29.000Z
demos/show_transform/show_gft_L.py
bwdeng20/thgsp
785b3ff291d72ee51e51e4cdbfd4bab63f8de9ac
[ "BSD-3-Clause" ]
2
2021-03-26T04:36:39.000Z
2022-01-11T16:17:56.000Z
demos/show_transform/show_gft_L.py
bwdeng20/thgsp
785b3ff291d72ee51e51e4cdbfd4bab63f8de9ac
[ "BSD-3-Clause" ]
2
2021-01-13T05:15:43.000Z
2022-01-01T12:51:32.000Z
import numpy as np from scipy.sparse import lil_matrix from thgsp.datasets import Toy from thgsp.sampling import ess_sampling from thgsp.visual import show_transform g = Toy(download=True)[0] lap_type = "comb" fs, U = g.spectral(lap_type=lap_type) bands = np.linspace(fs[0], fs[-1], num=9) bands2 = np.hstack([bands[:-1...
37.791667
99
0.728776
91d158bf9bda0ae8ba9a14c4bf98971898a115b9
579
py
Python
medium/Minimum Path Sum/solution.py
ashutosh1919/leetcode-problems
65f99a3694549af88c7702b598de1a8ccb7db5fb
[ "MIT" ]
8
2021-08-21T19:10:04.000Z
2022-03-11T14:30:02.000Z
medium/Minimum Path Sum/solution.py
ashutosh1919/leetcode-problems
65f99a3694549af88c7702b598de1a8ccb7db5fb
[ "MIT" ]
null
null
null
medium/Minimum Path Sum/solution.py
ashutosh1919/leetcode-problems
65f99a3694549af88c7702b598de1a8ccb7db5fb
[ "MIT" ]
1
2021-08-24T06:29:02.000Z
2021-08-24T06:29:02.000Z
# Time complexity: O(m*n) # Approach: DP solution. Accumulating minimum sum class Solution: def minPathSum(self, grid: List[List[int]]) -> int: m, n = len(grid), len(grid[0]) dp = [[101]*n for i in range(m)] dp[0][0] = grid[0][0] for i in range(1, n): dp[0][i] = dp[0][i-...
34.058824
65
0.46114
91d15f19287f1e3845216e389006dec63387d3d0
15,537
py
Python
pyfiles/server_common.py
aalto-trafficsense/regular-routes-server
aa13083258b8207eb2c078ce7db4f7f7c4de8c0a
[ "MIT" ]
2
2017-08-07T07:00:59.000Z
2021-03-08T12:27:09.000Z
pyfiles/server_common.py
aalto-trafficsense/regular-routes-server
aa13083258b8207eb2c078ce7db4f7f7c4de8c0a
[ "MIT" ]
43
2015-01-30T08:03:50.000Z
2020-11-22T21:33:00.000Z
pyfiles/server_common.py
aalto-trafficsense/regular-routes-server
aa13083258b8207eb2c078ce7db4f7f7c4de8c0a
[ "MIT" ]
1
2018-05-17T15:35:03.000Z
2018-05-17T15:35:03.000Z
import json import tempfile import zipfile from collections import namedtuple from csv import DictWriter from datetime import datetime, timedelta from itertools import groupby from io import StringIO from flask import abort, jsonify, make_response from sqlalchemy.sql import ( and_, between, cast, func, literal, ...
36.386417
159
0.623608
91d1c43edd5a0f8ebdcc9fe9708503af9a56a307
11,686
py
Python
sync.py
mkelley/lco-sync
e13cbe215c85b1e2dde073b3e47b1b4ea136b54c
[ "MIT" ]
null
null
null
sync.py
mkelley/lco-sync
e13cbe215c85b1e2dde073b3e47b1b4ea136b54c
[ "MIT" ]
null
null
null
sync.py
mkelley/lco-sync
e13cbe215c85b1e2dde073b3e47b1b4ea136b54c
[ "MIT" ]
1
2021-07-07T23:49:25.000Z
2021-07-07T23:49:25.000Z
# Licensed under a MIT style license - see LICENSE """sync - Sync LCO data with local archive. Thanks to Nestor Espinoza's lcogtDD for an example on syncing with LCO. """ import io import os import sys import json import time import logging import argparse import requests from astropy.table import Table from astropy...
33.011299
148
0.534571
91d1f70e02828d0786eab9c6b54d736aca76a56b
8,948
py
Python
raiden/ui/runners.py
ExchangeUnion/raiden
2217bcb698fcfce3499dc1f41ad919ed82e8e45f
[ "MIT" ]
null
null
null
raiden/ui/runners.py
ExchangeUnion/raiden
2217bcb698fcfce3499dc1f41ad919ed82e8e45f
[ "MIT" ]
12
2019-08-09T19:12:17.000Z
2019-12-05T15:49:29.000Z
raiden/ui/runners.py
ExchangeUnion/raiden
2217bcb698fcfce3499dc1f41ad919ed82e8e45f
[ "MIT" ]
null
null
null
import signal import sys import traceback from copy import deepcopy from datetime import datetime from tempfile import NamedTemporaryFile from typing import Any, Dict import click import gevent import gevent.monkey import structlog from gevent.event import AsyncResult from requests.exceptions import ConnectionError as...
33.38806
95
0.606169
91d1fb26fcd14cd52f9dc26e4af26c8cb32ea503
1,035
py
Python
test/test_container.py
jlk/qualys-cs-python-client
e2e39fd64d41fd6671d45343843ef36fa3ab59a4
[ "Apache-2.0" ]
null
null
null
test/test_container.py
jlk/qualys-cs-python-client
e2e39fd64d41fd6671d45343843ef36fa3ab59a4
[ "Apache-2.0" ]
null
null
null
test/test_container.py
jlk/qualys-cs-python-client
e2e39fd64d41fd6671d45343843ef36fa3ab59a4
[ "Apache-2.0" ]
1
2020-05-15T04:20:48.000Z
2020-05-15T04:20:48.000Z
# coding: utf-8 """ Container Security APIs All features of the Container Security are available through REST APIs.<br/>Access support information at www.qualys.com/support/<br/><br/><b>Permissions:</b><br/>User must have the Container module enabled<br/>User must have API ACCESS permission # noqa: E501 ...
25.875
265
0.709179
91d207dfcf4e7fec5a97d8ec5d491ae17bfc7a09
10,460
py
Python
tests/openassetio/test/manager/test_harness.py
carmenpinto/OpenAssetIO
62e6f30f658684e4ea73bf4aa3b0156399989c89
[ "Apache-2.0" ]
null
null
null
tests/openassetio/test/manager/test_harness.py
carmenpinto/OpenAssetIO
62e6f30f658684e4ea73bf4aa3b0156399989c89
[ "Apache-2.0" ]
null
null
null
tests/openassetio/test/manager/test_harness.py
carmenpinto/OpenAssetIO
62e6f30f658684e4ea73bf4aa3b0156399989c89
[ "Apache-2.0" ]
null
null
null
# # Copyright 2013-2022 The Foundry Visionmongers 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 app...
36.445993
99
0.730784
91d209dc64bc9fd4de97d1306c6a85280fd92578
117,993
py
Python
Lib/inspect.py
masamitsu-murase/stackless
677b36ffe5cb5a0f4b8d3abfa20982c8d82ffb92
[ "CNRI-Python-GPL-Compatible" ]
854
2017-09-11T16:42:28.000Z
2022-03-27T14:17:09.000Z
Lib/inspect.py
masamitsu-murase/stackless
677b36ffe5cb5a0f4b8d3abfa20982c8d82ffb92
[ "CNRI-Python-GPL-Compatible" ]
164
2017-09-24T20:40:32.000Z
2021-10-30T01:35:05.000Z
Lib/inspect.py
masamitsu-murase/stackless
677b36ffe5cb5a0f4b8d3abfa20982c8d82ffb92
[ "CNRI-Python-GPL-Compatible" ]
73
2017-09-13T18:07:48.000Z
2022-03-17T13:02:29.000Z
"""Get useful information from live Python objects. This module encapsulates the interface provided by the internal special attributes (co_*, im_*, tb_*, etc.) in a friendlier fashion. It also provides some help for examining source code and class layout. Here are some of the useful functions provided by this module:...
37.386882
91
0.603595
91d20c1b49f19b0cca678c67003f3f5635de9dc2
2,428
py
Python
A340-SBKP/analysis/pitch.py
paulross/pprune-calc
ebed46e7e029bc7a3067f50ad180a1df236052cf
[ "MIT" ]
1
2020-10-24T15:46:18.000Z
2020-10-24T15:46:18.000Z
A340-SBKP/analysis/pitch.py
paulross/pprune-calc
ebed46e7e029bc7a3067f50ad180a1df236052cf
[ "MIT" ]
null
null
null
A340-SBKP/analysis/pitch.py
paulross/pprune-calc
ebed46e7e029bc7a3067f50ad180a1df236052cf
[ "MIT" ]
null
null
null
import typing import numpy as np from scipy.optimize import curve_fit from analysis import video_data from analysis import video_utils def _pitch(t: float) -> float: """Returns the apparent pitch angle of the aircraft at time t. Due to camera roll this may not be accurate.""" xS = [v.video_time.time for...
34.197183
93
0.655272
91d20cf0e193e1b15cdeb643f13d12e8dbaa79eb
7,171
py
Python
mdrsl/rule_models/mids/cover/cover_checker.py
joschout/Multi-Directional-Rule-Set-Learning
ef0620b115f4e0fd7fba3e752d238a8020c1ca6b
[ "Apache-2.0" ]
3
2020-08-03T19:25:44.000Z
2021-06-27T22:25:55.000Z
mdrsl/rule_models/mids/cover/cover_checker.py
joschout/Multi-Directional-Rule-Set-Learning
ef0620b115f4e0fd7fba3e752d238a8020c1ca6b
[ "Apache-2.0" ]
null
null
null
mdrsl/rule_models/mids/cover/cover_checker.py
joschout/Multi-Directional-Rule-Set-Learning
ef0620b115f4e0fd7fba3e752d238a8020c1ca6b
[ "Apache-2.0" ]
2
2020-08-07T22:54:28.000Z
2021-02-18T06:11:01.000Z
from typing import List, Optional import numpy as np import pandas as pd from mdrsl.data_structures.item import Literal from mdrsl.data_structures.rules.rule_part import Antecedent, Consequent, RulePart from mdrsl.rule_models.mids.mids_rule import MIDSRule TargetAttr = str class CoverChecker: @staticmethod ...
40.514124
119
0.634221
91d223c42d82c9c9c9be515d66e73645caaa8757
108
py
Python
app/requests.py
kmunge/blog
73d83b9c4cf9b8c7a1a631d63be77a00ea469f1f
[ "Unlicense" ]
null
null
null
app/requests.py
kmunge/blog
73d83b9c4cf9b8c7a1a631d63be77a00ea469f1f
[ "Unlicense" ]
1
2021-06-01T23:45:51.000Z
2021-06-01T23:45:51.000Z
app/requests.py
kmunge/blog
73d83b9c4cf9b8c7a1a631d63be77a00ea469f1f
[ "Unlicense" ]
null
null
null
from app import app import urllib.request,json from . import Post api_key = app.config['RANDOM_QUOTES_URL']
21.6
41
0.796296
91d2630efe6ea93faf8b14522302d10230382cf7
1,581
py
Python
adafruit_circuitpython_libs/adafruit-circuitpython-bundle-py-20210214/examples/pca9685_servo.py
jacoblb64/pico_rgb_keypad_hid
3251ca6a98ef86d9f98c54f639c4d61810601a0b
[ "MIT" ]
47
2021-02-15T23:02:36.000Z
2022-03-04T21:30:03.000Z
adafruit_circuitpython_libs/adafruit-circuitpython-bundle-py-20210214/examples/pca9685_servo.py
jacoblb64/pico_rgb_keypad_hid
3251ca6a98ef86d9f98c54f639c4d61810601a0b
[ "MIT" ]
7
2021-02-19T20:00:08.000Z
2022-01-14T10:51:12.000Z
adafruit_circuitpython_libs/adafruit-circuitpython-bundle-py-20210214/examples/pca9685_servo.py
jacoblb64/pico_rgb_keypad_hid
3251ca6a98ef86d9f98c54f639c4d61810601a0b
[ "MIT" ]
14
2021-02-20T17:40:56.000Z
2022-01-01T19:53:38.000Z
# SPDX-FileCopyrightText: 2021 ladyada for Adafruit Industries # SPDX-License-Identifier: MIT # This example moves a servo its full range (180 degrees by default) and then back. from board import SCL, SDA import busio # This example also relies on the Adafruit motor library available here: # https://github.com/adafr...
36.767442
98
0.753953
91d277921df566f593cd734b2c8321d1cf952e84
208
py
Python
tests/integration/issues/github_1546/good2/__init__.py
Rohitpandit021/jina
f3db4d5e480375d8dc3bceda814ac1963dee76d7
[ "Apache-2.0" ]
4
2021-06-29T04:14:31.000Z
2021-08-01T07:01:08.000Z
tests/integration/issues/github_1546/good2/__init__.py
Rohitpandit021/jina
f3db4d5e480375d8dc3bceda814ac1963dee76d7
[ "Apache-2.0" ]
1
2021-12-25T09:06:13.000Z
2021-12-25T09:06:13.000Z
tests/integration/issues/github_1546/good2/__init__.py
Rohitpandit021/jina
f3db4d5e480375d8dc3bceda814ac1963dee76d7
[ "Apache-2.0" ]
1
2021-07-05T12:42:40.000Z
2021-07-05T12:42:40.000Z
from jina import Executor from .helper import helper_function class GoodCrafter2(Executor): def __init__(self, *args, **kwargs): super().__init__(*args, **kwargs) print(helper_function)
23.111111
41
0.701923
91d2c61fb78310dcf337f415f9decfb9e7b4e941
4,966
py
Python
sdk/containerservice/azure-mgmt-containerservice/azure/mgmt/containerservice/v2020_01_01/models/__init__.py
vincenttran-msft/azure-sdk-for-python
348b56f9f03eeb3f7b502eed51daf494ffff874d
[ "MIT" ]
1
2022-03-09T08:59:13.000Z
2022-03-09T08:59:13.000Z
sdk/containerservice/azure-mgmt-containerservice/azure/mgmt/containerservice/v2020_01_01/models/__init__.py
vincenttran-msft/azure-sdk-for-python
348b56f9f03eeb3f7b502eed51daf494ffff874d
[ "MIT" ]
null
null
null
sdk/containerservice/azure-mgmt-containerservice/azure/mgmt/containerservice/v2020_01_01/models/__init__.py
vincenttran-msft/azure-sdk-for-python
348b56f9f03eeb3f7b502eed51daf494ffff874d
[ "MIT" ]
null
null
null
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may ...
39.412698
94
0.805276
91d329c7492ae15d10f6209508398c7e96ccbf27
5,098
py
Python
apps/Analyzer_Datasets/time_series/lib_data_geo_ascii.py
c-hydro/hat
6342f87237ae9e71f05d54264bce97299ab4eb61
[ "MIT" ]
1
2022-03-21T03:30:43.000Z
2022-03-21T03:30:43.000Z
apps/Analyzer_Datasets/time_series/lib_data_geo_ascii.py
c-hydro/hat
6342f87237ae9e71f05d54264bce97299ab4eb61
[ "MIT" ]
3
2021-05-06T15:22:37.000Z
2021-05-06T16:31:05.000Z
apps/Analyzer_Datasets/time_series/lib_data_geo_ascii.py
c-hydro/hat
6342f87237ae9e71f05d54264bce97299ab4eb61
[ "MIT" ]
null
null
null
""" Class Features Name: lib_jupyter_data_geo_ascii Author(s): Fabio Delogu (fabio.delogu@cimafoundation.org) Date: '20210113' Version: '1.0.0' """ ####################################################################################### # Libraries import logging import rasterio import os ...
36.156028
119
0.555316
91d33db46a61826f41df56c20ab3888144508f9e
6,081
py
Python
website/addons/box/views/auth.py
dplorimer/osf
9f3f400f62dc7bde18532949ed35bf1d3f6ec3d6
[ "Apache-2.0" ]
null
null
null
website/addons/box/views/auth.py
dplorimer/osf
9f3f400f62dc7bde18532949ed35bf1d3f6ec3d6
[ "Apache-2.0" ]
null
null
null
website/addons/box/views/auth.py
dplorimer/osf
9f3f400f62dc7bde18532949ed35bf1d3f6ec3d6
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- """OAuth views for the Box addon.""" import time import logging import httplib as http from datetime import datetime import furl import requests from flask import request from box import BoxClient, CredentialsV2 from werkzeug.wrappers import BaseResponse from framework.flask import redirect #...
29.376812
92
0.692649
91d34c2f5afa52902261bc0f559b3f7e1e84d731
19,454
py
Python
benchmarking/cnn3d/train_qm9.py
bfabiandev/atom3d
b2499ff743be2e851c286cabf64696682abffa44
[ "MIT" ]
null
null
null
benchmarking/cnn3d/train_qm9.py
bfabiandev/atom3d
b2499ff743be2e851c286cabf64696682abffa44
[ "MIT" ]
null
null
null
benchmarking/cnn3d/train_qm9.py
bfabiandev/atom3d
b2499ff743be2e851c286cabf64696682abffa44
[ "MIT" ]
null
null
null
from __future__ import division, print_function, absolute_import import argparse import functools import json import logging import math import os import random import numpy as np import pandas as pd import tensorflow as tf import tqdm try: tf.compat.v1.logging.set_verbosity(tf.compat.v1.logging.ERROR) except: ...
37.555985
106
0.624602
91d3808c7ea5d78c843955a0d6998c6a73779f11
3,472
py
Python
bookworm/service/handler.py
mush42/bookworm
a4bdd89363137a89a1bed1e9e072de4fb55576fd
[ "MIT" ]
18
2019-07-19T22:12:15.000Z
2020-08-26T17:45:19.000Z
bookworm/service/handler.py
mush42/bookworm
a4bdd89363137a89a1bed1e9e072de4fb55576fd
[ "MIT" ]
44
2019-07-15T10:17:00.000Z
2020-07-26T11:22:53.000Z
bookworm/service/handler.py
mush42/bookworm
a4bdd89363137a89a1bed1e9e072de4fb55576fd
[ "MIT" ]
9
2019-09-03T13:13:31.000Z
2020-08-25T13:55:27.000Z
# coding: utf-8 from bookworm import app from bookworm import config from bookworm.signals import app_shuttingdown from bookworm.logger import logger log = logger.getChild(__name__) # Builtin services from bookworm.otau import OTAUService from bookworm.annotation import AnnotationService from bookworm.ocr import O...
29.931034
83
0.672811
91d38fa7878cd1eae341ff95c493845431ff970a
1,860
py
Python
metafarmerx/core/auto_hedger.py
0xsamsar/MetaFarmerX
62b5171c5f63355c69b7a3089c0ca7a56e8f7d9f
[ "MIT" ]
4
2022-02-13T01:30:34.000Z
2022-03-01T21:41:53.000Z
metafarmerx/core/auto_hedger.py
0xsamsar/deltra-neutral-yield-farming
62b5171c5f63355c69b7a3089c0ca7a56e8f7d9f
[ "MIT" ]
null
null
null
metafarmerx/core/auto_hedger.py
0xsamsar/deltra-neutral-yield-farming
62b5171c5f63355c69b7a3089c0ca7a56e8f7d9f
[ "MIT" ]
null
null
null
from threading import Lock, Thread from time import sleep from pandas import Timedelta, to_datetime class AutoHedger(object): """ Implements the delta-neutral hedge rebalancing logic """ def __init__(self, _strategy): # Strategy Parameters self._strategy = _strategy self._thre...
29.0625
82
0.473118
91d39eecb1b83258c26e4be59c366db24cfa0276
172
py
Python
smoke.py
silberman/snecko
0e34e4c530fd74eb3c93bf5ea2060f36d85a69a4
[ "MIT" ]
null
null
null
smoke.py
silberman/snecko
0e34e4c530fd74eb3c93bf5ea2060f36d85a69a4
[ "MIT" ]
3
2020-08-11T05:26:24.000Z
2020-08-14T23:05:26.000Z
smoke.py
silberman/snecko
0e34e4c530fd74eb3c93bf5ea2060f36d85a69a4
[ "MIT" ]
1
2020-08-11T05:18:53.000Z
2020-08-11T05:18:53.000Z
#!/usr/bin/env python # A smoke test to see if CUDA is set up ok. import torch print("checking torch GPU bindings...") print(torch.cuda.get_device_name(0)) print("done")
19.111111
43
0.72093
91d3b3412c6a12e0ab6b1bf4a248675d8a8e5326
4,911
py
Python
adafruit_circuitpython_libs/adafruit-circuitpython-bundle-py-20210214/lib/adafruit_led_animation/color.py
jacoblb64/pico_rgb_keypad_hid
3251ca6a98ef86d9f98c54f639c4d61810601a0b
[ "MIT" ]
47
2021-02-15T23:02:36.000Z
2022-03-04T21:30:03.000Z
adafruit_circuitpython_libs/adafruit-circuitpython-bundle-py-20210214/lib/adafruit_led_animation/color.py
jacoblb64/pico_rgb_keypad_hid
3251ca6a98ef86d9f98c54f639c4d61810601a0b
[ "MIT" ]
7
2021-02-19T20:00:08.000Z
2022-01-14T10:51:12.000Z
adafruit_circuitpython_libs/adafruit-circuitpython-bundle-py-20210214/lib/adafruit_led_animation/color.py
jacoblb64/pico_rgb_keypad_hid
3251ca6a98ef86d9f98c54f639c4d61810601a0b
[ "MIT" ]
14
2021-02-20T17:40:56.000Z
2022-01-01T19:53:38.000Z
# The MIT License (MIT) # # Copyright (c) 2019 Kattni Rembor for Adafruit Industries # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the ri...
32.959732
97
0.628182
91d3c3d289882f31a536064e774ed3b8b43e4ae7
2,816
py
Python
utils/metrics_ddie.py
duanbiao-nlp/DESC_MOL-DDIE
add555a7136e4be13f369320fd694a9aae11eb4f
[ "MIT" ]
14
2020-11-03T13:53:23.000Z
2022-03-23T07:26:50.000Z
utils/metrics_ddie.py
duanbiao-nlp/DESC_MOL-DDIE
add555a7136e4be13f369320fd694a9aae11eb4f
[ "MIT" ]
1
2022-02-09T09:56:39.000Z
2022-02-09T09:56:39.000Z
utils/metrics_ddie.py
duanbiao-nlp/DESC_MOL-DDIE
add555a7136e4be13f369320fd694a9aae11eb4f
[ "MIT" ]
4
2020-11-04T04:31:05.000Z
2021-11-05T07:49:27.000Z
# coding=utf-8 # Copyright 2018 The Google AI Language Team Authors and The HuggingFace Inc. team. # Copyright (c) 2018, NVIDIA 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 cop...
34.341463
117
0.651989
91d3f41038edfe771532837a076afaf190c06ab3
5,541
py
Python
Projects/3/COVID19DN.py
Anuraag287/AI-Classification
990fd82996a874d1850f12a938d2fff5dd45cc2c
[ "MIT" ]
1
2020-04-15T19:38:11.000Z
2020-04-15T19:38:11.000Z
Projects/3/COVID19DN.py
Anuraag287/AI-Classification
990fd82996a874d1850f12a938d2fff5dd45cc2c
[ "MIT" ]
1
2020-04-25T19:33:35.000Z
2020-04-26T16:13:30.000Z
Projects/3/COVID19DN.py
Anuraag287/AI-Classification
990fd82996a874d1850f12a938d2fff5dd45cc2c
[ "MIT" ]
2
2020-04-15T19:41:18.000Z
2020-04-25T14:08:26.000Z
############################################################################################ # # Project: Peter Moss COVID-19 AI Research Project # Repository: AI-Classification # Repo Project: COVID-19 Tensorflow DenseNet Classifier # # Author: Adam Milton-Barker (AdamMiltonBarker.com) # Contributors:...
32.028902
98
0.567407
91d416626198c57165d5d25272989f1f8352d505
3,202
py
Python
skgstat/data/_loader.py
rhugonnet/scikit-gstat
a142ca13aa3b048c46613d1247396c80c32a8145
[ "MIT" ]
141
2017-10-13T10:25:19.000Z
2022-03-31T00:41:32.000Z
skgstat/data/_loader.py
rhugonnet/scikit-gstat
a142ca13aa3b048c46613d1247396c80c32a8145
[ "MIT" ]
109
2017-09-23T12:42:44.000Z
2022-03-28T06:53:44.000Z
skgstat/data/_loader.py
rhugonnet/scikit-gstat
a142ca13aa3b048c46613d1247396c80c32a8145
[ "MIT" ]
42
2017-11-28T18:44:22.000Z
2022-03-24T02:27:44.000Z
from typing import Union, Tuple, List import os import imageio from glob import glob import numpy as np import pandas as pd PATH = os.path.abspath(os.path.dirname(__file__)) def field_names() -> List[str]: """ Get all available fields """ fnames = glob(os.path.join(PATH, 'rf', '*.png')) basename...
25.212598
70
0.604622
91d48b5027cb4fdfd1df1aee34a50845c807ec03
142
py
Python
tests/conftest.py
dgilland/fnc
a8d3cda717ba1c883e546a9f3cba9b2dc24c58a6
[ "MIT" ]
152
2018-08-16T02:02:46.000Z
2022-03-16T03:01:02.000Z
tests/conftest.py
dgilland/fnc
a8d3cda717ba1c883e546a9f3cba9b2dc24c58a6
[ "MIT" ]
4
2019-11-07T10:31:02.000Z
2021-05-18T15:08:54.000Z
tests/conftest.py
dgilland/fnc
a8d3cda717ba1c883e546a9f3cba9b2dc24c58a6
[ "MIT" ]
3
2020-09-14T03:04:33.000Z
2021-03-06T11:12:21.000Z
from unittest import mock import pytest @pytest.fixture def mocksleep(): with mock.patch("time.sleep") as mocked: yield mocked
14.2
44
0.704225
91d4d58593e1eec08f753a7f48fbd5640f82accf
3,458
py
Python
violas_client/lbrtypes/contract_event.py
violas-core/violas-client
e8798f7d081ac218b78b81fd7eb2f8da92631a16
[ "MIT" ]
null
null
null
violas_client/lbrtypes/contract_event.py
violas-core/violas-client
e8798f7d081ac218b78b81fd7eb2f8da92631a16
[ "MIT" ]
null
null
null
violas_client/lbrtypes/contract_event.py
violas-core/violas-client
e8798f7d081ac218b78b81fd7eb2f8da92631a16
[ "MIT" ]
1
2022-01-05T06:49:42.000Z
2022-01-05T06:49:42.000Z
from violas_client.canoser import Struct, RustEnum, Uint64 from violas_client.lbrtypes.event import EventKey from violas_client.lbrtypes.proof.definition import EventProof from violas_client.move_core_types.language_storage import TypeTag, StructTag from violas_client.lbrtypes.account_config import ACCOUNT_MODULE_NAME,...
30.069565
147
0.674667
91d4f93ac952f7fb819c8b6a719f5e96a1a105d4
241
py
Python
abc/abc158/e/main.py
tonko2/AtCoder
5d617072517881d226d7c8af09cb88684d41af7e
[ "Xnet", "X11", "CECILL-B" ]
2
2022-01-22T07:56:58.000Z
2022-01-24T00:29:37.000Z
keyence2020/f/main.py
tonko2/AtCoder
5d617072517881d226d7c8af09cb88684d41af7e
[ "Xnet", "X11", "CECILL-B" ]
null
null
null
keyence2020/f/main.py
tonko2/AtCoder
5d617072517881d226d7c8af09cb88684d41af7e
[ "Xnet", "X11", "CECILL-B" ]
null
null
null
import sys from collections import defaultdict, deque sys.setrecursionlimit(10 ** 6) stdin = sys.stdin INF = float('inf') ni = lambda: int(ns()) na = lambda: list(map(int, stdin.readline().split())) ns = lambda: stdin.readline().strip()
18.538462
53
0.697095
91d4fc69cea28602837f18e8c4c6aa6ff525c56f
4,069
py
Python
src/data/loading.py
NikRuggeri/CLAP-interpretable-predictions
1a89ba2d2eddfa9aff25124937cc31a6b7847dec
[ "MIT" ]
3
2022-03-25T10:43:41.000Z
2022-03-30T13:53:02.000Z
src/data/loading.py
NikRuggeri/CLAP-interpretable-predictions
1a89ba2d2eddfa9aff25124937cc31a6b7847dec
[ "MIT" ]
null
null
null
src/data/loading.py
NikRuggeri/CLAP-interpretable-predictions
1a89ba2d2eddfa9aff25124937cc31a6b7847dec
[ "MIT" ]
null
null
null
from typing import Tuple import numpy as np from sklearn.model_selection import train_test_split from torch.utils.data import Dataset, Subset from torchvision.transforms import Compose, Grayscale, Normalize, Resize, ToTensor from .chestxray import ChestXRay from .mpi import MPIData, MPIDataset from .plant_village imp...
35.692982
118
0.637503
91d5010f05be2ccd464b07b4cf910b6f86046a7a
4,590
py
Python
starmato/admin/templatetags/_get_previous_or_next.py
Depado/starmato-admin
58452e0085ff06d6adee27c578a95ea5aca390d9
[ "MIT" ]
1
2015-11-08T10:13:32.000Z
2015-11-08T10:13:32.000Z
starmato/admin/templatetags/_get_previous_or_next.py
Depado/starmato-admin
58452e0085ff06d6adee27c578a95ea5aca390d9
[ "MIT" ]
null
null
null
starmato/admin/templatetags/_get_previous_or_next.py
Depado/starmato-admin
58452e0085ff06d6adee27c578a95ea5aca390d9
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from datetime import datetime # from django.contrib.admin import site from django import template from django.http import HttpRequest from django.template.defaultfilters import stringfilter from django.db.models import Q from django.db.models.sql.query import get_order_dir from django.contrib.ad...
34
106
0.589542
91d5225cd6082f25d10ae91522421e2b9a5d1346
9,490
py
Python
src/mop/azure/comprehension/operations/subscriptions.py
robertfischer3/python-mop
d81fe43e484f469d91992e471acf059ecfd57dd2
[ "MIT" ]
1
2020-01-14T21:38:10.000Z
2020-01-14T21:38:10.000Z
src/mop/azure/comprehension/operations/subscriptions.py
robertfischer3/python-mop
d81fe43e484f469d91992e471acf059ecfd57dd2
[ "MIT" ]
null
null
null
src/mop/azure/comprehension/operations/subscriptions.py
robertfischer3/python-mop
d81fe43e484f469d91992e471acf059ecfd57dd2
[ "MIT" ]
1
2020-01-30T03:12:59.000Z
2020-01-30T03:12:59.000Z
import logging from configparser import ConfigParser import jmespath import pandas as pd from azure.mgmt.managementgroups import ManagementGroupsAPI from azure.mgmt.resource.policy import PolicyClient from azure.mgmt.resource.policy.models import PolicyAssignment from tenacity import retry, wait_random, stop_after_att...
35.676692
175
0.589041
91d5375d500a66bbb8e710ffee029578b4ef1cd3
976
py
Python
sfepy/solvers/__init__.py
clazaro/sfepy
78757a6989d6aaf85a3fb27957b9179c5e2aa2c7
[ "BSD-3-Clause" ]
null
null
null
sfepy/solvers/__init__.py
clazaro/sfepy
78757a6989d6aaf85a3fb27957b9179c5e2aa2c7
[ "BSD-3-Clause" ]
null
null
null
sfepy/solvers/__init__.py
clazaro/sfepy
78757a6989d6aaf85a3fb27957b9179c5e2aa2c7
[ "BSD-3-Clause" ]
null
null
null
from __future__ import absolute_import import os import sfepy from sfepy.base.base import load_classes, insert_static_method from .solvers import * from .eigen import eig solver_files = sfepy.get_paths('sfepy/solvers/*.py') remove = ['setup.py', 'solvers.py', 'petsc_worker.py'] solver_files = [name for name in solver_...
33.655172
79
0.689549
91d53f3e9168a22fe0e60f39a00ce231e7166979
1,046
py
Python
fabkit/template.py
karolhor/fabkit
fe32e97fc3ff3aa01d5e106f6ed5b8f3aae5a558
[ "MIT" ]
null
null
null
fabkit/template.py
karolhor/fabkit
fe32e97fc3ff3aa01d5e106f6ed5b8f3aae5a558
[ "MIT" ]
null
null
null
fabkit/template.py
karolhor/fabkit
fe32e97fc3ff3aa01d5e106f6ed5b8f3aae5a558
[ "MIT" ]
null
null
null
import os.path from pathlib import Path from shlex import quote from fabric.contrib.files import upload_template from fabkit.util import run_or_sudo from fabkit.files import mkdir class Template: __TEMPLATES_DIR__ = Path.cwd() SRC_PATH = None DST_PATH = None def __init__(self): self._param...
26.15
73
0.608987
91d552b83436b0b06c711f81e56ec71a83b24ec5
2,786
py
Python
augly/audio/__init__.py
Adib234/AugLy
35a6a5de07e64f465b8979e3257218551929e57a
[ "MIT" ]
null
null
null
augly/audio/__init__.py
Adib234/AugLy
35a6a5de07e64f465b8979e3257218551929e57a
[ "MIT" ]
null
null
null
augly/audio/__init__.py
Adib234/AugLy
35a6a5de07e64f465b8979e3257218551929e57a
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # Copyright (c) Facebook, Inc. and its affiliates. from augly.audio.composition import Compose, OneOf from augly.audio.functional import ( add_background_noise, apply_lambda, change_volume, clicks, clip, harmonic, high_pass_filter, insert_in_background, invert...
20.335766
50
0.66906
91d5534f32d2a6dc85b9b6663cd885e3dd55b26e
71,197
py
Python
src/api-server/venv/lib/python3.8/site-packages/aniso8601/tests/test_interval.py
srikanteswartalluri/container-orchestrator
3cd07989e28ece0038cb0b7c6bbdc83c1c0ba7a9
[ "Apache-2.0" ]
1
2021-07-14T23:39:19.000Z
2021-07-14T23:39:19.000Z
src/api-server/venv/lib/python3.8/site-packages/aniso8601/tests/test_interval.py
srikanteswartalluri/container-orchestrator
3cd07989e28ece0038cb0b7c6bbdc83c1c0ba7a9
[ "Apache-2.0" ]
null
null
null
src/api-server/venv/lib/python3.8/site-packages/aniso8601/tests/test_interval.py
srikanteswartalluri/container-orchestrator
3cd07989e28ece0038cb0b7c6bbdc83c1c0ba7a9
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright (c) 2021, Brandon Nielsen # All rights reserved. # # This software may be modified and distributed under the terms # of the BSD license. See the LICENSE file for details. import unittest import aniso8601 from aniso8601.builders import (DateTuple, DatetimeTuple, ...
61.802951
124
0.378499
91d55c14c09d55d8fc538dbd0add55fe2a52c503
635
py
Python
tests/test_early_stopping.py
kmkurn/rnnr
6fb53b1dfe3266e1648c361753950c6c59e720a8
[ "Apache-2.0" ]
3
2019-10-27T10:03:18.000Z
2019-10-28T11:11:46.000Z
tests/test_early_stopping.py
kmkurn/rnnr
6fb53b1dfe3266e1648c361753950c6c59e720a8
[ "Apache-2.0" ]
null
null
null
tests/test_early_stopping.py
kmkurn/rnnr
6fb53b1dfe3266e1648c361753950c6c59e720a8
[ "Apache-2.0" ]
null
null
null
from rnnr.callbacks import maybe_stop_early def test_ok(runner): patience, counter, check, state = 7, "cnt", "check", {"running": True} callback = maybe_stop_early(patience, check=check, counter=counter) for i in range(patience): state[check] = False callback(state) assert state["...
26.458333
74
0.631496
91d56155fdd41b02196ebb205f6aa2e97f08d06c
9,156
py
Python
wienerschnitzelgemeinschaft/src/Christof/models/GAPNet/13_ext_512crop/oof_ul.py
guitarmind/HPA-competition-solutions
547d53aaca148fdb5f4585526ad7364dfa47967d
[ "MIT" ]
null
null
null
wienerschnitzelgemeinschaft/src/Christof/models/GAPNet/13_ext_512crop/oof_ul.py
guitarmind/HPA-competition-solutions
547d53aaca148fdb5f4585526ad7364dfa47967d
[ "MIT" ]
null
null
null
wienerschnitzelgemeinschaft/src/Christof/models/GAPNet/13_ext_512crop/oof_ul.py
guitarmind/HPA-competition-solutions
547d53aaca148fdb5f4585526ad7364dfa47967d
[ "MIT" ]
null
null
null
import os, sys #os.environ["CUDA_DEVICE_ORDER"] = "PCI_BUS_ID" os.environ["CUDA_VISIBLE_DEVICES"]="0" import numpy as np import pandas as pd from tqdm import tqdm from sklearn.utils import shuffle from classification_models.resnet.models import ResNet18 import albumentations as A import cv2 eps = 0.004 desired = { ...
32.817204
112
0.638488
91d577d15dd5911923155cd2b494fbed12ce208d
11,633
py
Python
processor/graphs/charts.py
MainakRepositor/WhatsApp-Analyzer
2a3c0de61935501fc9ff888b6cb8dc34095e9dfa
[ "MIT" ]
5
2021-12-10T11:44:59.000Z
2022-02-02T16:03:31.000Z
processor/graphs/charts.py
raahoolkumeriya/whatsapp-chat-streamlit
7d9c4de26c6325bd0b9e69b60d6a95ced3a366ec
[ "MIT" ]
16
2021-07-03T14:12:09.000Z
2021-09-20T16:46:51.000Z
processor/graphs/charts.py
raahoolkumeriya/whatsapp-chat-streamlit
7d9c4de26c6325bd0b9e69b60d6a95ced3a366ec
[ "MIT" ]
1
2022-01-26T11:13:33.000Z
2022-01-26T11:13:33.000Z
""" Analysis Chats are at one Place """ # Import support labaraies import logging from typing import Any from collections import Counter import numpy as np import pandas as pd import plotly.express as px from textblob import TextBlob import matplotlib.pyplot as plt def message_cluster(data_frame: pd.DataFrame): "...
29.67602
76
0.609129
91d593691d632eca5536eddbb3d009d46a8d1182
486
py
Python
python/p347.py
forewing/lc
314468a1a3bb7d38eccf1f34b0d1b7da04a34784
[ "CC0-1.0" ]
null
null
null
python/p347.py
forewing/lc
314468a1a3bb7d38eccf1f34b0d1b7da04a34784
[ "CC0-1.0" ]
null
null
null
python/p347.py
forewing/lc
314468a1a3bb7d38eccf1f34b0d1b7da04a34784
[ "CC0-1.0" ]
null
null
null
import heapq from collections import Counter class Solution: def topKFrequent(self, nums: List[int], k: int) -> List[int]: cnt = Counter() for num in nums: cnt[num] += 1 q = [] keys = list(cnt.keys()) for i in range(k): q.append((cnt[keys[i]], keys[...
23.142857
65
0.516461
91d59f30dc46267974a2641d4b1162cc7bc4179d
1,147
py
Python
src/server/app/fetchers/lottery.py
LiteralGenie/HvData
e4a8cac99c7443d7c6be41b4586b1d5a01e27a2b
[ "MIT" ]
null
null
null
src/server/app/fetchers/lottery.py
LiteralGenie/HvData
e4a8cac99c7443d7c6be41b4586b1d5a01e27a2b
[ "MIT" ]
null
null
null
src/server/app/fetchers/lottery.py
LiteralGenie/HvData
e4a8cac99c7443d7c6be41b4586b1d5a01e27a2b
[ "MIT" ]
null
null
null
from classes.parsers import LotteryParser from classes.models import Lottery, LotteryItem, LotteryType from sqlalchemy import select from sqlalchemy.orm import Session, subqueryload import time class LotteryFetcher: db_session: Session lotto_parser: LotteryParser def lottery(self, id: int, type: Lotter...
32.771429
107
0.632956
91d5a030ae80d528314bf5b856ac015b45908542
3,977
py
Python
venv/lib/python3.6/site-packages/kubernetes/client/api/certificates_api.py
DiptoChakrabarty/Kube-Automate
2072d1aadd58eb405c7308ff5cfecbf50300ead3
[ "MIT" ]
null
null
null
venv/lib/python3.6/site-packages/kubernetes/client/api/certificates_api.py
DiptoChakrabarty/Kube-Automate
2072d1aadd58eb405c7308ff5cfecbf50300ead3
[ "MIT" ]
null
null
null
venv/lib/python3.6/site-packages/kubernetes/client/api/certificates_api.py
DiptoChakrabarty/Kube-Automate
2072d1aadd58eb405c7308ff5cfecbf50300ead3
[ "MIT" ]
null
null
null
# coding: utf-8 """ Kubernetes No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 OpenAPI spec version: release-1.15 Generated by: https://openapi-generator.tech """ from __future__ import absolute_import import re # noqa: F401...
32.598361
124
0.62258
91d5c628775e1a3b1a8a147785293cae92a3b36d
2,193
py
Python
luna/gateware/applets/dc_flash.py
asaioe99/luna_JP
276c9d86d2c964c7c4be149d721156d869c9489b
[ "BSD-3-Clause" ]
4
2020-02-11T18:40:02.000Z
2020-04-03T13:07:38.000Z
luna/gateware/applets/dc_flash.py
kbeckmann/luna
befb33620d1c4267607a45f331b84bc196c7a8bf
[ "BSD-3-Clause" ]
null
null
null
luna/gateware/applets/dc_flash.py
kbeckmann/luna
befb33620d1c4267607a45f331b84bc196c7a8bf
[ "BSD-3-Clause" ]
1
2021-01-16T00:40:49.000Z
2021-01-16T00:40:49.000Z
# # This file is part of LUNA. # import operator from functools import reduce from nmigen import Signal, Elaboratable, Module, Cat, ClockDomain, ClockSignal, ResetInserter from nmigen.lib.cdc import FFSynchronizer from luna.gateware.utils.cdc import synchronize from luna.gateware.interface.spi import SPIRegi...
31.782609
93
0.649339
91d5d1424a37f18c2ed658e65d5347827535127f
1,849
py
Python
chemkin_io/tests/test__plot_thermo.py
sjklipp/interfaces
646673ac125c4b48e69a64025a36abd1b2ace696
[ "Apache-2.0" ]
null
null
null
chemkin_io/tests/test__plot_thermo.py
sjklipp/interfaces
646673ac125c4b48e69a64025a36abd1b2ace696
[ "Apache-2.0" ]
null
null
null
chemkin_io/tests/test__plot_thermo.py
sjklipp/interfaces
646673ac125c4b48e69a64025a36abd1b2ace696
[ "Apache-2.0" ]
null
null
null
""" Test the rate plotting functionality for comparing two mechanisms """ import tempfile import numpy import chemkin_io # Set up the thermo data NAMES = ['N2', 'Ne'] THM_DCT = { 'InChI=1S/N2/c1-2': {'mech1': [[1.4136091551074, 5.130163864501488, 10.23657268925187], [0.007074035569284...
37.734694
78
0.638724
91d606023326fda82b79e37484de1502adbaccf6
5,908
py
Python
test_app/tests/test_attachments.py
makinacorpus/django-mapentity
69a53fb8a676a9d4f6173b77fc09f99d38c4795e
[ "BSD-3-Clause" ]
26
2015-01-12T13:22:40.000Z
2022-03-07T16:50:52.000Z
test_app/tests/test_attachments.py
makinacorpus/django-mapentity
69a53fb8a676a9d4f6173b77fc09f99d38c4795e
[ "BSD-3-Clause" ]
94
2015-01-21T16:20:47.000Z
2022-03-24T13:44:56.000Z
test_app/tests/test_attachments.py
makinacorpus/django-mapentity
69a53fb8a676a9d4f6173b77fc09f99d38c4795e
[ "BSD-3-Clause" ]
13
2015-01-22T07:11:15.000Z
2019-10-28T02:07:48.000Z
from unittest import mock from django.core.management import call_command from django.test import TestCase, RequestFactory from django.contrib.auth import get_user_model from django.contrib.auth.models import Permission from django.contrib.contenttypes.models import ContentType from django.core.files.uploadedfile impo...
41.605634
117
0.653013
91d60f7968929f7810722e5ebf5f5d9be0061366
22,064
py
Python
src/compas_cem/diagrams/topology.py
dylau/compas_cem
643c7d60cb9d6a9999cb96d39c44175cc8662a25
[ "MIT" ]
null
null
null
src/compas_cem/diagrams/topology.py
dylau/compas_cem
643c7d60cb9d6a9999cb96d39c44175cc8662a25
[ "MIT" ]
null
null
null
src/compas_cem/diagrams/topology.py
dylau/compas_cem
643c7d60cb9d6a9999cb96d39c44175cc8662a25
[ "MIT" ]
null
null
null
from compas.geometry import scale_vector from compas.geometry import add_vectors from compas.geometry import normalize_vector from compas_cem.diagrams import Diagram from compas_cem.elements import Node from compas_cem.elements import TrailEdge from compas_cem.supports import NodeSupport __all__ = ["TopologyDiagra...
28.804178
171
0.482596
91d61329834e63e942241d1a1c9cd04e9141539c
935
py
Python
tests/unit/test_http_processor.py
povilasb/pycollection-pipelines
dbf58db2f8192aa0acc4269048777bbbe0642c45
[ "MIT" ]
7
2016-08-17T22:11:46.000Z
2021-06-30T15:18:27.000Z
tests/unit/test_http_processor.py
povilasb/pycollection-pipelines
dbf58db2f8192aa0acc4269048777bbbe0642c45
[ "MIT" ]
null
null
null
tests/unit/test_http_processor.py
povilasb/pycollection-pipelines
dbf58db2f8192aa0acc4269048777bbbe0642c45
[ "MIT" ]
null
null
null
from hamcrest import assert_that, is_ from mock import MagicMock, patch from collection_pipelines.http import http def describe_http(): def describe_contructor(): def it_sets_url_to_get(): proc = http('http://example.com') assert_that(proc.url, is_('http://example.com')) ...
28.333333
62
0.636364
91d653b9dfb0246c7df2dfe19f2bb54401d6f51c
2,912
py
Python
docs/examples/code/combining_simulations.py
abigailbishop/pyrex
10ba2e9f4c8820f4fcf5f00bd866927dacb0b2b5
[ "MIT" ]
6
2018-06-19T16:01:35.000Z
2020-05-21T20:02:53.000Z
docs/examples/code/combining_simulations.py
bhokansonfasig/pyrex
8b2abc954f2cf4945424042f33847b783c72dcfa
[ "MIT" ]
4
2018-01-19T14:52:33.000Z
2021-09-02T17:20:07.000Z
examples/combining_simulations.py
abigailbishop/pyrex
10ba2e9f4c8820f4fcf5f00bd866927dacb0b2b5
[ "MIT" ]
5
2018-01-19T14:49:16.000Z
2021-01-21T12:34:59.000Z
"""A script for combining the outputs of multiple effective volume simulations""" import argparse import os, os.path import re import numpy as np import matplotlib.pyplot as plt import pyrex parser = argparse.ArgumentParser(description=__doc__) parser.add_argument('directory', help="directory con...
39.351351
103
0.666209
91d662a8a3ac9076839a269f4242ddd9b7281aa6
3,787
py
Python
trajectron_plus_plus/model/mgcvae/decoding/attention.py
rozzong/trajectron-plus-plus
68b03e469ae300f3960e24a4463c361ef311425d
[ "MIT" ]
null
null
null
trajectron_plus_plus/model/mgcvae/decoding/attention.py
rozzong/trajectron-plus-plus
68b03e469ae300f3960e24a4463c361ef311425d
[ "MIT" ]
null
null
null
trajectron_plus_plus/model/mgcvae/decoding/attention.py
rozzong/trajectron-plus-plus
68b03e469ae300f3960e24a4463c361ef311425d
[ "MIT" ]
null
null
null
from abc import ABC, abstractmethod from typing import Optional, Tuple import torch from torch import nn class Attention(nn.Module, ABC): """Attention module. """ in_features: int = None out_features: int = None @abstractmethod def score( self, query: Optional[torch....
25.761905
79
0.551096
91d674add086abe61c7ea7671fde708b0abdaf1a
1,934
py
Python
data/transcoder_evaluation_gfg/python/FIND_A_FIXED_POINT_IN_A_GIVEN_ARRAY.py
mxl1n/CodeGen
e5101dd5c5e9c3720c70c80f78b18f13e118335a
[ "MIT" ]
241
2021-07-20T08:35:20.000Z
2022-03-31T02:39:08.000Z
data/transcoder_evaluation_gfg/python/FIND_A_FIXED_POINT_IN_A_GIVEN_ARRAY.py
mxl1n/CodeGen
e5101dd5c5e9c3720c70c80f78b18f13e118335a
[ "MIT" ]
49
2021-07-22T23:18:42.000Z
2022-03-24T09:15:26.000Z
data/transcoder_evaluation_gfg/python/FIND_A_FIXED_POINT_IN_A_GIVEN_ARRAY.py
mxl1n/CodeGen
e5101dd5c5e9c3720c70c80f78b18f13e118335a
[ "MIT" ]
71
2021-07-21T05:17:52.000Z
2022-03-29T23:49:28.000Z
# Copyright (c) 2019-present, Facebook, Inc. # All rights reserved. # # This source code is licensed under the license found in the # LICENSE file in the root directory of this source tree. # def f_gold ( arr , n ) : for i in range ( n ) : if arr [ i ] is i : return i return - 1 #TOFILL i...
58.606061
175
0.46484
91d69e20365dbd70b0e2974dcf8654e4cd2e4689
372
py
Python
utils/contexts.py
nicklovin/pipeline
4d8e042783321e5b0ed7b8a713a7db4d2cef9adb
[ "BSD-2-Clause" ]
null
null
null
utils/contexts.py
nicklovin/pipeline
4d8e042783321e5b0ed7b8a713a7db4d2cef9adb
[ "BSD-2-Clause" ]
null
null
null
utils/contexts.py
nicklovin/pipeline
4d8e042783321e5b0ed7b8a713a7db4d2cef9adb
[ "BSD-2-Clause" ]
null
null
null
from contextlib import contextmanager import time @contextmanager def isolate_print(bar_length=40): print('-' * bar_length) yield print('-' * bar_length) @contextmanager def timed_test(description): start = time.time() yield dif_time = time.time() - start print('Timed T...
20.666667
70
0.655914
91d6aa663eb009b0fcc2670e91647412c695446f
4,084
py
Python
segmentation_module.py
fcdl94/ModelingTheBackground
1c589833ce5c1a7446469d4602ceab2cdeac1b0e
[ "MIT" ]
105
2020-03-20T17:47:00.000Z
2022-03-16T16:52:07.000Z
segmentation_module.py
fcdl94/ModelingTheBackground
1c589833ce5c1a7446469d4602ceab2cdeac1b0e
[ "MIT" ]
38
2020-03-24T18:21:12.000Z
2022-02-25T17:44:01.000Z
segmentation_module.py
fcdl94/ModelingTheBackground
1c589833ce5c1a7446469d4602ceab2cdeac1b0e
[ "MIT" ]
28
2020-04-27T18:44:37.000Z
2022-03-28T22:43:54.000Z
import torch import torch.nn as nn from torch import distributed import torch.nn.functional as functional import inplace_abn from inplace_abn import InPlaceABNSync, InPlaceABN, ABN from functools import partial, reduce import models from modules import DeeplabV3 def make_model(opts, classes=None): if opts.norm...
34.319328
119
0.649363
91d6b87c60dec5aac86f1ab459b30797349fce8a
23,293
py
Python
petab/parameter_mapping.py
paulflang/PEtab
f263174065109ad7c5500796d871a6326fabbc8c
[ "MIT" ]
null
null
null
petab/parameter_mapping.py
paulflang/PEtab
f263174065109ad7c5500796d871a6326fabbc8c
[ "MIT" ]
null
null
null
petab/parameter_mapping.py
paulflang/PEtab
f263174065109ad7c5500796d871a6326fabbc8c
[ "MIT" ]
null
null
null
"""Functions related to mapping parameter from model to parameter estimation problem""" import logging import numbers import os import re from typing import Tuple, Dict, Union, Any, List, Optional, Iterable import libsbml import numpy as np import pandas as pd from . import lint, measurements, sbml, core, observable...
39.613946
79
0.659984
91d6bff072117769f4772678d1a507cc1cf3fc77
16,162
py
Python
pyamg/vis/vtk_writer.py
nicknytko/pyamg
c9e7e03ddb2911c2cdc8b6c93f158a7f1d8f0ce0
[ "MIT" ]
371
2015-01-11T23:32:12.000Z
2022-03-31T12:47:56.000Z
pyamg/vis/vtk_writer.py
nicknytko/pyamg
c9e7e03ddb2911c2cdc8b6c93f158a7f1d8f0ce0
[ "MIT" ]
169
2015-01-15T15:31:10.000Z
2022-03-29T23:03:35.000Z
pyamg/vis/vtk_writer.py
nicknytko/pyamg
c9e7e03ddb2911c2cdc8b6c93f158a7f1d8f0ce0
[ "MIT" ]
100
2015-01-22T23:21:23.000Z
2022-03-22T10:26:41.000Z
"""VTK output functions. Create coarse grid views and write meshes/primitives to .vtu files. Use the XML VTK format for unstructured meshes (.vtu) This will use the XML VTK format for unstructured meshes, .vtu See here for a guide: http://www.vtk.org/pdf/file-formats.pdf """ import xml.dom.minidom import numpy as...
33.8826
91
0.528895
91d6c5ba1054379aaa0a1c0adbc04d8159117124
2,878
py
Python
scripts/login.py
HumanCellAtlas/dcp-prototype
44ca66a266004124f39d7d3e3dd75e9076012ff0
[ "MIT" ]
2
2020-02-07T18:12:12.000Z
2020-02-11T14:59:03.000Z
scripts/login.py
HumanCellAtlas/dcp-prototype
44ca66a266004124f39d7d3e3dd75e9076012ff0
[ "MIT" ]
173
2020-01-29T17:48:02.000Z
2020-03-20T02:52:58.000Z
scripts/login.py
HumanCellAtlas/dcp-prototype
44ca66a266004124f39d7d3e3dd75e9076012ff0
[ "MIT" ]
null
null
null
import json import re from urllib import parse import requests def get_cxguser_cookie(): # suppress https warnings. requests.packages.urllib3.disable_warnings(requests.packages.urllib3.exceptions.InsecureRequestWarning) OIDC_LOGIN_URL = "http://backend.corporanet.local:5000/dp/v1/login" USERS_CONFIG...
35.097561
107
0.701529
91d6d414a58dd033ca0dd906532f887ca0bd53c9
22,892
py
Python
sdk/eventgrid/azure-mgmt-eventgrid/azure/mgmt/eventgrid/aio/operations/_private_endpoint_connections_operations.py
vincenttran-msft/azure-sdk-for-python
348b56f9f03eeb3f7b502eed51daf494ffff874d
[ "MIT" ]
1
2022-01-24T08:54:57.000Z
2022-01-24T08:54:57.000Z
sdk/eventgrid/azure-mgmt-eventgrid/azure/mgmt/eventgrid/aio/operations/_private_endpoint_connections_operations.py
vincenttran-msft/azure-sdk-for-python
348b56f9f03eeb3f7b502eed51daf494ffff874d
[ "MIT" ]
null
null
null
sdk/eventgrid/azure-mgmt-eventgrid/azure/mgmt/eventgrid/aio/operations/_private_endpoint_connections_operations.py
vincenttran-msft/azure-sdk-for-python
348b56f9f03eeb3f7b502eed51daf494ffff874d
[ "MIT" ]
null
null
null
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may ...
49.124464
239
0.682334
91d6e71061bece36e035166e21a94ae2f1034651
2,570
py
Python
yggdrasil/examples/osr/src/other_model.py
Xyzic/yggdrasil
44369514ffdf01960bfcce418c172dc6dc564051
[ "BSD-3-Clause" ]
null
null
null
yggdrasil/examples/osr/src/other_model.py
Xyzic/yggdrasil
44369514ffdf01960bfcce418c172dc6dc564051
[ "BSD-3-Clause" ]
null
null
null
yggdrasil/examples/osr/src/other_model.py
Xyzic/yggdrasil
44369514ffdf01960bfcce418c172dc6dc564051
[ "BSD-3-Clause" ]
null
null
null
import sys from yggdrasil import units from yggdrasil.interface.YggInterface import ( YggTimesync, YggOutput) def timestep_calc(t): r"""Updates the state based on the time where x is a sine wave with period of 10 days and y is a cosine wave with a period of 5 days. Args: t (float): Current ti...
30.235294
90
0.606615
91d74bbe74413e57a46aa201546eab7c56d0bf5e
8,212
py
Python
couchbaseConstants.py
dannyxn/couchbase-cli
33c2ea93a7a0ee165fadb76c216fcc8234c7d741
[ "Apache-2.0" ]
36
2015-02-12T20:32:04.000Z
2022-03-21T17:37:27.000Z
couchbaseConstants.py
dannyxn/couchbase-cli
33c2ea93a7a0ee165fadb76c216fcc8234c7d741
[ "Apache-2.0" ]
8
2016-09-07T16:04:16.000Z
2020-01-20T10:17:04.000Z
couchbaseConstants.py
dannyxn/couchbase-cli
33c2ea93a7a0ee165fadb76c216fcc8234c7d741
[ "Apache-2.0" ]
53
2015-03-13T13:23:55.000Z
2021-12-17T22:45:25.000Z
#!/usr/bin/env python3 """ Copyright (c) 2007 Dustin Sallings <dustin@spy.net> """ import struct from typing import Optional, Tuple, Union PUMP_ERROR = Union[str, int] # batch message: (cmd, vbucket_id, key, flg, exp, cas, rev_seqno/rev, val, seqno, dtype, metalen, conf_res/notthis) BATCH_MSG = Tuple[int, int, byte...
23.19774
115
0.773746
91d7b5cf1ab924089e2888a4e2bf4411d1ea06b9
1,529
py
Python
wienerschnitzelgemeinschaft/src/shai/fastai/tools/download_tomomi.py
guitarmind/HPA-competition-solutions
547d53aaca148fdb5f4585526ad7364dfa47967d
[ "MIT" ]
null
null
null
wienerschnitzelgemeinschaft/src/shai/fastai/tools/download_tomomi.py
guitarmind/HPA-competition-solutions
547d53aaca148fdb5f4585526ad7364dfa47967d
[ "MIT" ]
null
null
null
wienerschnitzelgemeinschaft/src/shai/fastai/tools/download_tomomi.py
guitarmind/HPA-competition-solutions
547d53aaca148fdb5f4585526ad7364dfa47967d
[ "MIT" ]
null
null
null
import requests import pandas as pd from tqdm import tqdm from joblib import Parallel, delayed import os from PIL import Image import requests from io import BytesIO newpath = "/media/galib/Documents/protein-atlas/jpg/" if not os.path.exists(newpath): os.makedirs(newpath) print(newpath) colors = ['red','green','...
28.849057
104
0.636364
91d7c055cf996d3f08f86dedc7bf82863f590d9d
1,231
py
Python
elvia/types/grid_tariff_types.py
andersem/elvia-python
cd71d13e1200845c93222dffed53baaa3a136bd4
[ "MIT" ]
null
null
null
elvia/types/grid_tariff_types.py
andersem/elvia-python
cd71d13e1200845c93222dffed53baaa3a136bd4
[ "MIT" ]
null
null
null
elvia/types/grid_tariff_types.py
andersem/elvia-python
cd71d13e1200845c93222dffed53baaa3a136bd4
[ "MIT" ]
null
null
null
from typing import List from typing_extensions import TypedDict class TariffType(TypedDict): tariffKey: str company: str customerType: str title: str resolution: int description: str class TariffTypeResponse(TypedDict): tariffTypes: List[TariffType] class PriceLevel(TypedDict): lev...
17.338028
53
0.725426
91d7e3a3b1e61d5596d3906d51db23697760e464
375
py
Python
socfaker/client.py
atstpls/soc-faker
119fcb9c4329a918ef9001ac5eaa36251b862bf0
[ "MIT" ]
null
null
null
socfaker/client.py
atstpls/soc-faker
119fcb9c4329a918ef9001ac5eaa36251b862bf0
[ "MIT" ]
null
null
null
socfaker/client.py
atstpls/soc-faker
119fcb9c4329a918ef9001ac5eaa36251b862bf0
[ "MIT" ]
null
null
null
from .useragent import UserAgent from .network import Network class Client(object): def get(self, number): ip_list=[] ua_list=[] i=0 while i < number: ip_list.append(Network().ipv4) ua_list.append(UserAgent().get()) i += 1 client_list = d...
23.4375
50
0.568
91d83f7e87159af3c3c3f52e68ac49bdf2e837ea
1,998
py
Python
Test01/test03_RNN.py
hooloong/My_TensorFlow
ef115989035b9ae14938dca47c0814b0d16dd6ba
[ "MIT" ]
3
2018-07-29T17:31:58.000Z
2019-06-27T10:36:34.000Z
Test01/test03_RNN.py
hooloong/My_TensorFlow
ef115989035b9ae14938dca47c0814b0d16dd6ba
[ "MIT" ]
null
null
null
Test01/test03_RNN.py
hooloong/My_TensorFlow
ef115989035b9ae14938dca47c0814b0d16dd6ba
[ "MIT" ]
1
2019-02-18T02:27:39.000Z
2019-02-18T02:27:39.000Z
import tensorflow as tf import numpy as np # 下载mnist数据集 from tensorflow.examples.tutorials.mnist import input_data mnist = input_data.read_data_sets('/tmp/', one_hot=True) # 一张图片是28*28,FNN是一次性把数据输入到网络,RNN把它分成块 chunk_size = 28 chunk_n = 28 rnn_size = 256 n_output_layer = 10 # 输出层 X = tf.placeholder('float', [None...
30.738462
116
0.665165
91d892a82f1e997e19c959370f5dc970a142f236
17,593
py
Python
sdk/compute/azure-mgmt-compute/azure/mgmt/compute/v2021_07_01/_compute_management_client.py
vincenttran-msft/azure-sdk-for-python
348b56f9f03eeb3f7b502eed51daf494ffff874d
[ "MIT" ]
1
2021-09-07T18:39:05.000Z
2021-09-07T18:39:05.000Z
sdk/compute/azure-mgmt-compute/azure/mgmt/compute/v2021_07_01/_compute_management_client.py
vincenttran-msft/azure-sdk-for-python
348b56f9f03eeb3f7b502eed51daf494ffff874d
[ "MIT" ]
null
null
null
sdk/compute/azure-mgmt-compute/azure/mgmt/compute/v2021_07_01/_compute_management_client.py
vincenttran-msft/azure-sdk-for-python
348b56f9f03eeb3f7b502eed51daf494ffff874d
[ "MIT" ]
1
2022-03-04T06:21:56.000Z
2022-03-04T06:21:56.000Z
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may ...
73.304167
1,275
0.810038
91d8a7148f3d4ecdb7c1a67f4c65c96017f3ef95
869
py
Python
pandaserver/configurator/aux.py
virthead/panda-server
d2b65f788c4539dc103641ca2a8052cb18729d44
[ "Apache-2.0" ]
7
2015-03-30T14:15:35.000Z
2021-12-22T06:48:22.000Z
pandaserver/configurator/aux.py
virthead/panda-server
d2b65f788c4539dc103641ca2a8052cb18729d44
[ "Apache-2.0" ]
16
2015-06-01T13:48:01.000Z
2022-02-08T15:03:32.000Z
pandaserver/configurator/aux.py
virthead/panda-server
d2b65f788c4539dc103641ca2a8052cb18729d44
[ "Apache-2.0" ]
15
2015-03-02T08:57:35.000Z
2022-03-01T09:48:45.000Z
import requests import time import os GB = 1024**3 PROD_INPUT = 'Production Input' PROD_OUTPUT = 'Production Output' EXPRESS = 'Express' FILES = 'files' MBPS = 'mbps' LATENCY = 'latency' PACKETLOSS = 'packetloss' DONE = 'done' QUEUED = 'queued' TOTAL = 'total' LATEST = 'latest' H1 = '1h' H6 = '6h' D1 = '1d' W1 = '1w' ...
21.195122
78
0.626007
91d937601a9021530c95aa5af3ac125dd47e9573
17,346
py
Python
oscar/apps/partner/migrations/0010_auto__chg_field_stockrecord_product__del_unique_stockrecord_product.py
makielab/django-oscar
0a325cd0f04a4278201872b2e163868b72b6fabe
[ "BSD-3-Clause" ]
null
null
null
oscar/apps/partner/migrations/0010_auto__chg_field_stockrecord_product__del_unique_stockrecord_product.py
makielab/django-oscar
0a325cd0f04a4278201872b2e163868b72b6fabe
[ "BSD-3-Clause" ]
null
null
null
oscar/apps/partner/migrations/0010_auto__chg_field_stockrecord_product__del_unique_stockrecord_product.py
makielab/django-oscar
0a325cd0f04a4278201872b2e163868b72b6fabe
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Removing unique constraint on 'StockRecord', fields ['product'] db.delete_unique('partner_stockrecord', ['...
82.995215
222
0.573389
91d9386e4c4cbd82089c28ad54ee3b0f8f15620a
2,167
py
Python
src/snowflake/connector/bind_upload_agent.py
666Chao666/snowflake-connector-python
81a10e522fcf19d45580c79bc066b7a4eab25485
[ "Apache-2.0" ]
null
null
null
src/snowflake/connector/bind_upload_agent.py
666Chao666/snowflake-connector-python
81a10e522fcf19d45580c79bc066b7a4eab25485
[ "Apache-2.0" ]
null
null
null
src/snowflake/connector/bind_upload_agent.py
666Chao666/snowflake-connector-python
81a10e522fcf19d45580c79bc066b7a4eab25485
[ "Apache-2.0" ]
2
2021-03-16T12:41:29.000Z
2021-03-16T14:50:08.000Z
#!/usr/bin/env python # # Copyright (c) 2012-2021 Snowflake Computing Inc. All right reserved. # import uuid from io import BytesIO from logging import getLogger from typing import TYPE_CHECKING, List from .errors import BindUploadError, Error if TYPE_CHECKING: # pragma: no cover from .cursor import SnowflakeCu...
33.859375
113
0.623904
91d954388aef678a7cb7354ccce2dd6193313ee8
2,714
py
Python
test_projects/AnimationLineAlphaInterface/main.py
ynsnf/apysc
b10ffaf76ec6beb187477d0a744fca00e3efc3fb
[ "MIT" ]
16
2021-04-16T02:01:29.000Z
2022-01-01T08:53:49.000Z
test_projects/AnimationLineAlphaInterface/main.py
ynsnf/apysc
b10ffaf76ec6beb187477d0a744fca00e3efc3fb
[ "MIT" ]
613
2021-03-24T03:37:38.000Z
2022-03-26T10:58:37.000Z
test_projects/AnimationLineAlphaInterface/main.py
simon-ritchie/apyscript
c319f8ab2f1f5f7fad8d2a8b4fc06e7195476279
[ "MIT" ]
2
2021-06-20T07:32:58.000Z
2021-12-26T08:22:11.000Z
"""The test project for the AnimationLineAlphaInterface class. Command examples: $ python test_projects/AnimationLineAlphaInterface/main.py """ import sys sys.path.append('./') import os from types import ModuleType import apysc as ap from apysc._file import file_util this_module: ModuleType = sys...
29.5
69
0.671334
91d980a903b8efdefcf8a0e472d137b54b713155
14,471
py
Python
pywinauto/timings.py
nimuston/pywinauto
3f61f7dea13b2e5b1282d65d2ae8247aae00b06f
[ "BSD-3-Clause" ]
1
2021-01-31T08:10:34.000Z
2021-01-31T08:10:34.000Z
pywinauto/timings.py
nimuston/pywinauto
3f61f7dea13b2e5b1282d65d2ae8247aae00b06f
[ "BSD-3-Clause" ]
null
null
null
pywinauto/timings.py
nimuston/pywinauto
3f61f7dea13b2e5b1282d65d2ae8247aae00b06f
[ "BSD-3-Clause" ]
null
null
null
# GUI Application automation and testing library # Copyright (C) 2006-2016 Mark Mc Mahon and Contributors # https://github.com/pywinauto/pywinauto/graphs/contributors # http://pywinauto.github.io/docs/credits.html # All rights reserved. # # Redistribution and use in source and binary forms, with or without # mod...
33.575406
95
0.608804
91d983b74fc12268a66cfe581591449c8417c53e
1,003
py
Python
examples/pygraphviz/write_dotfile.py
argriffing/networkx
5a3d000e605be2ca567f69a4694afcba3b8acb54
[ "BSD-3-Clause" ]
null
null
null
examples/pygraphviz/write_dotfile.py
argriffing/networkx
5a3d000e605be2ca567f69a4694afcba3b8acb54
[ "BSD-3-Clause" ]
null
null
null
examples/pygraphviz/write_dotfile.py
argriffing/networkx
5a3d000e605be2ca567f69a4694afcba3b8acb54
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python """ Write a dot file from a networkx graph for further processing with graphviz. You need to have either pygraphviz or pydot for this example. See http://networkx.github.io/documentation/latest/reference/drawing.html for more info. """ __author__ = """Aric Hagberg (hagberg@lanl.gov)""" # Cop...
25.717949
95
0.710867