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
7367c1eaf61e7aa611cfeb58b87e734372546234
70,464
py
Python
strawberryfields/backends/states.py
felipeoyarce/strawberryfields
adb0f9919decc3a6544ddae26eb98c1afb76f7c8
[ "Apache-2.0" ]
null
null
null
strawberryfields/backends/states.py
felipeoyarce/strawberryfields
adb0f9919decc3a6544ddae26eb98c1afb76f7c8
[ "Apache-2.0" ]
null
null
null
strawberryfields/backends/states.py
felipeoyarce/strawberryfields
adb0f9919decc3a6544ddae26eb98c1afb76f7c8
[ "Apache-2.0" ]
null
null
null
# Copyright 2019 Xanadu Quantum Technologies Inc. # 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...
37.008403
138
0.584866
7367f1b71c6e21c318ad64394d1b8944c1eed09c
44,581
py
Python
tensorflow/contrib/eager/python/checkpointable_utils_test.py
zhong110020/tensorflow
b79ce0029dce3264266ced739590bc238b17096c
[ "Apache-2.0" ]
2
2018-12-05T17:34:20.000Z
2019-01-07T01:59:19.000Z
tensorflow/contrib/eager/python/checkpointable_utils_test.py
qins0426/tensorflow
b79ce0029dce3264266ced739590bc238b17096c
[ "Apache-2.0" ]
null
null
null
tensorflow/contrib/eager/python/checkpointable_utils_test.py
qins0426/tensorflow
b79ce0029dce3264266ced739590bc238b17096c
[ "Apache-2.0" ]
null
null
null
# Copyright 2017 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
45.168186
80
0.715394
7368017837a09a54b3e052c939717835ad4f470c
3,287
py
Python
pycorrector/pycorrector/bert/bert_corrector.py
DCMMC/chineseocr
0b8772615239ea7f212b1ab5bc75183e7e9f16b0
[ "MIT" ]
null
null
null
pycorrector/pycorrector/bert/bert_corrector.py
DCMMC/chineseocr
0b8772615239ea7f212b1ab5bc75183e7e9f16b0
[ "MIT" ]
null
null
null
pycorrector/pycorrector/bert/bert_corrector.py
DCMMC/chineseocr
0b8772615239ea7f212b1ab5bc75183e7e9f16b0
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ @author:XuMing(xuming624@qq.com) @description: use bert detect and correct chinese char error """ import operator import sys import time from transformers import pipeline sys.path.append('../..') from pycorrector.bert import config from pycorrector.utils.text_utils import is_chinese_strin...
36.522222
104
0.550046
736808e89b123f5389be85ea2a6dfda755632cb1
422
py
Python
Corey Schafer/Enclosure and Decorator/wrapping_func_intro.py
SeanSyue/PythonReferences
103b2d6934a33e56a5d8fbb14d95282f572b3af7
[ "MIT" ]
null
null
null
Corey Schafer/Enclosure and Decorator/wrapping_func_intro.py
SeanSyue/PythonReferences
103b2d6934a33e56a5d8fbb14d95282f572b3af7
[ "MIT" ]
null
null
null
Corey Schafer/Enclosure and Decorator/wrapping_func_intro.py
SeanSyue/PythonReferences
103b2d6934a33e56a5d8fbb14d95282f572b3af7
[ "MIT" ]
null
null
null
def logger(msg): def log_message(): print("Log:", msg) return log_message log_hi = logger('Hi') log_hi() print(log_hi.__name__) # It's the same as we run the inner function itself. def html_tag(tag): def wrap_text(msg): print('<{0}>{1}</{0}>'.format(tag, msg)) return wrap_text pri...
18.347826
76
0.63981
73681f2e23bcfafd5c959d9913cc2c5a0bc1e3ba
771
py
Python
src/users/decorators.py
ccwang002/dinglab_logo_proposal
31e712914581b60b9d30da12cdec18a09b1a6829
[ "MIT" ]
null
null
null
src/users/decorators.py
ccwang002/dinglab_logo_proposal
31e712914581b60b9d30da12cdec18a09b1a6829
[ "MIT" ]
null
null
null
src/users/decorators.py
ccwang002/dinglab_logo_proposal
31e712914581b60b9d30da12cdec18a09b1a6829
[ "MIT" ]
null
null
null
from django.contrib.auth.decorators import user_passes_test from django.core.urlresolvers import reverse_lazy def login_forbidden(function=None, redirect_url=None): """The reverse of ``login_required``. The requet is redirected to ``redirect_url`` (``dashboard_home`` by default) if the user is authentica...
33.521739
72
0.715953
73685ac72351bf6d13ddf2dbc290c4d1ad339194
62
py
Python
tron/g.py
sdss/tron
886c5c5fb6341ad85e4a9f5d6f5ecb6bbc0d8322
[ "BSD-3-Clause" ]
null
null
null
tron/g.py
sdss/tron
886c5c5fb6341ad85e4a9f5d6f5ecb6bbc0d8322
[ "BSD-3-Clause" ]
null
null
null
tron/g.py
sdss/tron
886c5c5fb6341ad85e4a9f5d6f5ecb6bbc0d8322
[ "BSD-3-Clause" ]
null
null
null
"""A place for globals, because some people don't like OO?"""
31
61
0.693548
73685fd52238d196a65a3e4f17662f9071e3cf97
5,523
py
Python
recognition/arcface_torch/train.py
dwhite54/insightface
ea172e4921c3960c0684404afff6d0d862447eae
[ "MIT" ]
null
null
null
recognition/arcface_torch/train.py
dwhite54/insightface
ea172e4921c3960c0684404afff6d0d862447eae
[ "MIT" ]
null
null
null
recognition/arcface_torch/train.py
dwhite54/insightface
ea172e4921c3960c0684404afff6d0d862447eae
[ "MIT" ]
null
null
null
import argparse import logging import os import time import torch import torch.distributed as dist import torch.nn.functional as F import torch.utils.data.distributed from torch.nn.utils import clip_grad_norm_ import backbones import losses from config import config as cfg from dataset import MXFaceDataset, DataLoade...
41.526316
116
0.699982
736865de55eb8e66c9f311909afbd57fa2753fd0
29,635
py
Python
src/dataset.py
MatthewCYM/SFLM
831c71b910bd1ddeac24d0e4836417054b95ea97
[ "MIT" ]
10
2021-11-01T15:22:43.000Z
2022-02-10T06:08:47.000Z
src/dataset.py
MatthewCYM/SFLM
831c71b910bd1ddeac24d0e4836417054b95ea97
[ "MIT" ]
null
null
null
src/dataset.py
MatthewCYM/SFLM
831c71b910bd1ddeac24d0e4836417054b95ea97
[ "MIT" ]
2
2021-11-04T08:00:35.000Z
2022-02-10T05:34:10.000Z
"""Dataset utils for different data settings for GLUE.""" import os import copy import logging import torch import numpy as np import time from filelock import FileLock import json import itertools import random import transformers from src.processors import processors_mapping, num_labels_mapping, output_modes_mapping...
44.901515
172
0.578134
73687606859af8f31f60692d566bfae9230cbff3
2,386
py
Python
topi/python/topi/x86/batch_matmul.py
mingwayzhang/tvm
3b287c4d4e6d83e6fd30db47ffa3d5481a332a63
[ "Apache-2.0" ]
48
2020-07-29T18:09:23.000Z
2021-10-09T01:53:33.000Z
topi/python/topi/x86/batch_matmul.py
mingwayzhang/tvm
3b287c4d4e6d83e6fd30db47ffa3d5481a332a63
[ "Apache-2.0" ]
9
2021-04-02T02:28:07.000Z
2022-03-26T18:23:59.000Z
topi/python/topi/x86/batch_matmul.py
mingwayzhang/tvm
3b287c4d4e6d83e6fd30db47ffa3d5481a332a63
[ "Apache-2.0" ]
42
2020-08-01T06:41:24.000Z
2022-01-20T10:33:08.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.085714
74
0.630763
7368b35cb4f323347978db7c282d7a3a8d04368d
720
py
Python
cursoemvideoPy/Mundo3/aula19_continuacao.py
BrCarlini/exPython
3bed986e5bfa5eae191b6b18306448926aed48fd
[ "MIT" ]
null
null
null
cursoemvideoPy/Mundo3/aula19_continuacao.py
BrCarlini/exPython
3bed986e5bfa5eae191b6b18306448926aed48fd
[ "MIT" ]
null
null
null
cursoemvideoPy/Mundo3/aula19_continuacao.py
BrCarlini/exPython
3bed986e5bfa5eae191b6b18306448926aed48fd
[ "MIT" ]
null
null
null
brasil = [] # Lista estado1 = {'uf': 'Rio de Janeiro', 'sigla': 'RJ'} # Dicionario estado2 = {'uf': 'São Paulo', 'sigla': 'SP'} # Dicionario brasil.append(estado1) brasil.append(estado2) print(brasil) print() print(brasil[0]) print(brasil[1]) print() print(brasil[0]['uf']) print(brasil[1]['uf']) print('-='*30) prin...
20.571429
63
0.616667
7368c73185d4c0cf11e1ec9c47a94b8dc01c0b90
330
py
Python
test/test_record.py
cslotboom/planesections
fcb2127a38a78b45de44b75f5805efde89adf5d2
[ "Apache-2.0" ]
1
2021-11-12T08:36:31.000Z
2021-11-12T08:36:31.000Z
test/test_record.py
cslotboom/planesections
fcb2127a38a78b45de44b75f5805efde89adf5d2
[ "Apache-2.0" ]
null
null
null
test/test_record.py
cslotboom/planesections
fcb2127a38a78b45de44b75f5805efde89adf5d2
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- R""" Created on Sun May 23 01:00:41 2021 @author: Christian """ from planesections import EulerBeam, OpenSeesAnalyzer, RecordOutput # from planesections import EulerBeam import numpy as np import openseespy.opensees as op x = np.array([0,5]) fixities = [np.array([1,1,1], int), np.array([1,1,...
20.625
67
0.70303
7368cb08f0ece1d5c939c94bbb14f7b58ea3b09a
2,149
py
Python
dliplib/eval.py
oterobaguer/ct-dip-benchmark
0539c284c94089ed86421ea0892cd68aa1d0575a
[ "Apache-2.0" ]
null
null
null
dliplib/eval.py
oterobaguer/ct-dip-benchmark
0539c284c94089ed86421ea0892cd68aa1d0575a
[ "Apache-2.0" ]
null
null
null
dliplib/eval.py
oterobaguer/ct-dip-benchmark
0539c284c94089ed86421ea0892cd68aa1d0575a
[ "Apache-2.0" ]
null
null
null
import argparse from dival import TaskTable, DataPairs from dival.measure import SSIM, PSNR from dliplib.reconstructors import get_reconstructor from dliplib.utils.helper import load_standard_dataset from dliplib.utils.reports import save_results_table def get_parser(): """Adds arguments to the command""" p...
29.847222
72
0.668683
7368cc5662bcc836f43467de6fc5502dbcecd4c5
6,874
py
Python
ginga/cairow/ImageViewCairo.py
Cadair/ginga
5afdd8824f27c7ae7d8d82b5013b0ff0068bd8b8
[ "BSD-3-Clause" ]
null
null
null
ginga/cairow/ImageViewCairo.py
Cadair/ginga
5afdd8824f27c7ae7d8d82b5013b0ff0068bd8b8
[ "BSD-3-Clause" ]
null
null
null
ginga/cairow/ImageViewCairo.py
Cadair/ginga
5afdd8824f27c7ae7d8d82b5013b0ff0068bd8b8
[ "BSD-3-Clause" ]
null
null
null
# # ImageViewCairo.py -- classes for the display of Ginga canvases # in Cairo surfaces # # Eric Jeschke (eric@naoj.org) # # Copyright (c) Eric R. Jeschke. All rights reserved. # This is open-source software licensed under a BSD license. # Please see the file LICENSE.txt for details. import sy...
31.53211
82
0.566191
7368dc296b63735845a99403e805694e6997b5e2
18,007
py
Python
pyscf/ci/gcisd.py
seunghoonlee89/pyscf-ecCC-TCC
2091566fb83c1474e40bf74f271be2ce4611f60c
[ "Apache-2.0" ]
2
2021-09-17T06:10:17.000Z
2022-01-22T23:37:22.000Z
pyscf/ci/gcisd.py
r-peng/pyscf
9a14f9bcc63bc75f5939cb4d00eb47861d8d8989
[ "Apache-2.0" ]
null
null
null
pyscf/ci/gcisd.py
r-peng/pyscf
9a14f9bcc63bc75f5939cb4d00eb47861d8d8989
[ "Apache-2.0" ]
2
2021-09-16T23:37:42.000Z
2021-10-14T23:00:39.000Z
#!/usr/bin/env python # Copyright 2014-2020 The PySCF Developers. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # U...
37.281573
85
0.616149
7369293bb96a9e09f20aceca3733546b2ae228ac
1,634
py
Python
tests/events.py
disruptive-technologies/python-integrations
24798a2f26bfa661149311465fbe1f6ac12e5f79
[ "MIT" ]
1
2022-02-08T21:19:42.000Z
2022-02-08T21:19:42.000Z
tests/events.py
disruptive-technologies/python-integrations
24798a2f26bfa661149311465fbe1f6ac12e5f79
[ "MIT" ]
null
null
null
tests/events.py
disruptive-technologies/python-integrations
24798a2f26bfa661149311465fbe1f6ac12e5f79
[ "MIT" ]
1
2021-11-03T10:55:08.000Z
2021-11-03T10:55:08.000Z
class Event(): def __init__(self, headers: dict, body_str: str, body: dict, payload: dict): self.headers: dict = headers self.body_str: str = body_str self.body: dict = body self.payload: dict = payload touch =...
65.36
438
0.698286
736935285dd7b751f9b057d45187173dab7659ea
30,312
py
Python
tests/test_lstm.py
LoicDagnas/tensorflow-onnx
6691850e79047d05d85017573170fd8240393b57
[ "Apache-2.0" ]
1
2022-03-28T06:21:16.000Z
2022-03-28T06:21:16.000Z
tests/test_lstm.py
LoicDagnas/tensorflow-onnx
6691850e79047d05d85017573170fd8240393b57
[ "Apache-2.0" ]
null
null
null
tests/test_lstm.py
LoicDagnas/tensorflow-onnx
6691850e79047d05d85017573170fd8240393b57
[ "Apache-2.0" ]
null
null
null
# SPDX-License-Identifier: Apache-2.0 """Unit Tests for lstm.""" import numpy as np import tensorflow as tf from tensorflow.python.ops import init_ops from tensorflow.python.ops import variable_scope from backend_test_base import Tf2OnnxBackendTestBase from common import check_tf_min_version, unittest_main, check_o...
40.042272
119
0.589535
7369362fcc380f06033a957c8c9ba7676f3c88d5
128
py
Python
tests/uspto/uspto/service/by_dataset/__init__.py
ppentchev/openapi-client-generator
a058af4ec28a1e53809273a662fb8cba0157695e
[ "MIT" ]
6
2021-01-16T21:36:43.000Z
2022-01-24T10:21:14.000Z
tests/uspto/uspto/service/by_dataset/__init__.py
ppentchev/openapi-client-generator
a058af4ec28a1e53809273a662fb8cba0157695e
[ "MIT" ]
11
2021-01-17T00:05:44.000Z
2022-01-23T16:13:56.000Z
tests/uspto/uspto/service/by_dataset/__init__.py
ppentchev/openapi-client-generator
a058af4ec28a1e53809273a662fb8cba0157695e
[ "MIT" ]
2
2021-11-06T00:07:34.000Z
2022-01-14T01:35:06.000Z
""" Auto-generated by openapi-client-generator https://github.com/avanov/openapi-client-generator """ from . import by_version
21.333333
50
0.773438
73695daf85488d5404eeaa1cd93b8a73307181dd
1,661
py
Python
lambda/AsyncWorker.py
kyhau/slack-chat-app-cdk
051b3c573c745384b7ae0f24efcc95c61f0467ff
[ "Unlicense" ]
null
null
null
lambda/AsyncWorker.py
kyhau/slack-chat-app-cdk
051b3c573c745384b7ae0f24efcc95c61f0467ff
[ "Unlicense" ]
null
null
null
lambda/AsyncWorker.py
kyhau/slack-chat-app-cdk
051b3c573c745384b7ae0f24efcc95c61f0467ff
[ "Unlicense" ]
null
null
null
""" For processing requests that will take longer than 3 seconds to process. """ import json import logging import os from urllib.parse import urlencode import boto3 import urllib3 logging.getLogger().setLevel(logging.INFO) SLACK_API_CHAT_POST_URL = "https://slack.com/api/chat.postMessage" OAUTH_DDB_TABLE_NAME = os....
28.637931
130
0.683323
73698791374cae66ffd056e1bbbcb537fc39f187
1,682
py
Python
devices/debian_wifi.py
sravichandran-contractor/boardfarm
cb8cbe75db5f0323bb56cf9563d7e9b4e940a880
[ "BSD-3-Clause-Clear" ]
null
null
null
devices/debian_wifi.py
sravichandran-contractor/boardfarm
cb8cbe75db5f0323bb56cf9563d7e9b4e940a880
[ "BSD-3-Clause-Clear" ]
null
null
null
devices/debian_wifi.py
sravichandran-contractor/boardfarm
cb8cbe75db5f0323bb56cf9563d7e9b4e940a880
[ "BSD-3-Clause-Clear" ]
null
null
null
import re import debian class DebianWifi(debian.DebianBox): '''Extension of Debian class with wifi functions''' model = ('debianwifi') iface_wlan = "wlan1" def scan(self): from tests.lib.installers import install_iw install_iw(self) self.sendline('iw %s scan | grep SSID:' ...
30.035714
103
0.606421
7369c384a6e4df61deed4546cab09ec35a5f333a
2,534
py
Python
pre_request/filters/simple/length_filter.py
Eastwu5788/pre-request
6e51076ef9260d5fcf56dc513ad0240f04ce4938
[ "MIT" ]
86
2017-08-17T12:41:52.000Z
2022-02-24T12:17:47.000Z
pre_request/filters/simple/length_filter.py
Eastwu5788/pre-request
6e51076ef9260d5fcf56dc513ad0240f04ce4938
[ "MIT" ]
10
2020-03-30T03:24:46.000Z
2022-02-23T01:34:53.000Z
pre_request/filters/simple/length_filter.py
Eastwu5788/pre-request
6e51076ef9260d5fcf56dc513ad0240f04ce4938
[ "MIT" ]
7
2017-08-18T03:40:35.000Z
2020-05-19T04:09:10.000Z
# !/usr/local/python/bin/python # -*- coding: utf-8 -*- # (C) Wu Dong, 2019 # All rights reserved # @Author: 'Wu Dong <wudong@eastwu.cn>' # @Time: '2020-03-17 15:37' from pre_request.exception import ParamsValueError from pre_request.filters.base import BaseFilter class LengthFilter(BaseFilter): """ 判断字符串长度的过...
29.811765
113
0.593133
7369c8d3bdd7b80d02d8416be3a3c5e3a585e785
9,253
py
Python
fluxhelper/jarvis/api.py
bossauh/jarvisapi
74eecca71d0dd38ab41d81d3683392eb24e5e253
[ "MIT" ]
null
null
null
fluxhelper/jarvis/api.py
bossauh/jarvisapi
74eecca71d0dd38ab41d81d3683392eb24e5e253
[ "MIT" ]
null
null
null
fluxhelper/jarvis/api.py
bossauh/jarvisapi
74eecca71d0dd38ab41d81d3683392eb24e5e253
[ "MIT" ]
null
null
null
""" Main API used for jarvis' server. This API uses aiohttp rather than the requests module for asynchronous programming. """ from dataclasses import dataclass from typing import Tuple, Union import aiohttp import requests # Used for validating if the server has started from .exceptions import * from .structure imp...
33.164875
165
0.557009
7369c9163fe041cb7331684d6e15e58453614f79
14,457
py
Python
src/models/scnn_classifier.py
jhuebotter/SpikingVAE
8ef6171559542b8bc73bb2cc45ec90b5f6612ccd
[ "MIT" ]
3
2021-05-12T01:24:43.000Z
2021-09-29T15:36:38.000Z
src/models/scnn_classifier.py
jhuebotter/SpikingVAE
8ef6171559542b8bc73bb2cc45ec90b5f6612ccd
[ "MIT" ]
null
null
null
src/models/scnn_classifier.py
jhuebotter/SpikingVAE
8ef6171559542b8bc73bb2cc45ec90b5f6612ccd
[ "MIT" ]
null
null
null
import torch import torch.nn as nn from models.base_model import SpikingBaseModel from models.spiking_layers import LIF_sNeuron, Pooling_sNeuron, LF_Unit import utils as u import math import torch.nn.functional as F class SpikingConvolutionalClassifier(SpikingBaseModel): def __init__( self, input...
37.260309
94
0.549561
7369d1ac117cc2a16b2dcb85ddd12e0579bbab10
1,522
py
Python
tests/python/pants_test/backend/codegen/antlr/java/test_java_antlr_library.py
ghthor/pants
450de702414f87f563081ddefaefd8a554de07a3
[ "Apache-2.0" ]
null
null
null
tests/python/pants_test/backend/codegen/antlr/java/test_java_antlr_library.py
ghthor/pants
450de702414f87f563081ddefaefd8a554de07a3
[ "Apache-2.0" ]
null
null
null
tests/python/pants_test/backend/codegen/antlr/java/test_java_antlr_library.py
ghthor/pants
450de702414f87f563081ddefaefd8a554de07a3
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # Copyright 2015 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). from __future__ import absolute_import, division, print_function, unicode_literals from textwrap import dedent from pants.backend.codegen.antlr.java.java_antlr_library imp...
33.822222
100
0.716163
7369d90d36328486af8eb5dffb6ef1c59e86b928
1,560
py
Python
tests/utils/httpd.py
drorata/dvc
b6bc65fcbf269b94b7c1ce2d9dff641dedb039b0
[ "Apache-2.0" ]
1
2019-09-02T00:28:11.000Z
2019-09-02T00:28:11.000Z
tests/utils/httpd.py
drorata/dvc
b6bc65fcbf269b94b7c1ce2d9dff641dedb039b0
[ "Apache-2.0" ]
null
null
null
tests/utils/httpd.py
drorata/dvc
b6bc65fcbf269b94b7c1ce2d9dff641dedb039b0
[ "Apache-2.0" ]
1
2019-09-02T00:29:40.000Z
2019-09-02T00:29:40.000Z
import hashlib import os import threading from dvc.utils.compat import HTTPServer, SimpleHTTPRequestHandler class ETagHandler(SimpleHTTPRequestHandler): def end_headers(self): file = self.translate_path(self.path) if not os.path.isdir(file) and os.path.exists(file): with open(file, "...
30
79
0.648077
7369ed0f0cb7b96f493e3d9682047d5fb0a1b893
3,037
py
Python
model/pspnet2/cil.pspnet2.R50/config.py
fywalter/TorchSeg
729eb22d8c5d607466055552fd82e0819d5f29e2
[ "MIT" ]
null
null
null
model/pspnet2/cil.pspnet2.R50/config.py
fywalter/TorchSeg
729eb22d8c5d607466055552fd82e0819d5f29e2
[ "MIT" ]
null
null
null
model/pspnet2/cil.pspnet2.R50/config.py
fywalter/TorchSeg
729eb22d8c5d607466055552fd82e0819d5f29e2
[ "MIT" ]
2
2020-07-31T14:40:49.000Z
2020-07-31T17:52:30.000Z
# encoding: utf-8 from __future__ import absolute_import from __future__ import division from __future__ import print_function import os.path as osp import sys import time import numpy as np from easydict import EasyDict as edict import argparse import torch.utils.model_zoo as model_zoo C = edict() config = C cfg =...
25.521008
75
0.712216
7369ed7d950a9eeb69b4dd919d87da2432ab6193
982
py
Python
chapter3/fannsdb/fannsdb/command/_DEPRECATED_/pred_list.py
chris-zen/phd-thesis
1eefdff8e7ca1910304e27ae42551dc64496b101
[ "Unlicense" ]
1
2015-12-22T00:53:18.000Z
2015-12-22T00:53:18.000Z
chapter3/fannsdb/fannsdb/command/_DEPRECATED_/pred_list.py
chris-zen/phd-thesis
1eefdff8e7ca1910304e27ae42551dc64496b101
[ "Unlicense" ]
null
null
null
chapter3/fannsdb/fannsdb/command/_DEPRECATED_/pred_list.py
chris-zen/phd-thesis
1eefdff8e7ca1910304e27ae42551dc64496b101
[ "Unlicense" ]
null
null
null
#!/usr/bin/env python import os import argparse from bgcore import tsv from fannsdb.cmdhelper import DefaultCommandHelper def main(): parser = argparse.ArgumentParser( description="List predictors") cmd = DefaultCommandHelper(parser) cmd.add_db_args() parser.add_argument("--json", dest="to_json", action="s...
21.347826
92
0.644603
7369f068003b7684ecca394731d74d17efc6571c
7,388
py
Python
clients/kratos/python/ory_kratos_client/model/plugin_env.py
kolotaev/sdk
0dda1becd70be8d7b9d678321ebe780c1ba00485
[ "Apache-2.0" ]
null
null
null
clients/kratos/python/ory_kratos_client/model/plugin_env.py
kolotaev/sdk
0dda1becd70be8d7b9d678321ebe780c1ba00485
[ "Apache-2.0" ]
null
null
null
clients/kratos/python/ory_kratos_client/model/plugin_env.py
kolotaev/sdk
0dda1becd70be8d7b9d678321ebe780c1ba00485
[ "Apache-2.0" ]
null
null
null
""" Ory Kratos API Documentation for all public and administrative Ory Kratos APIs. Public and administrative APIs are exposed on different ports. Public APIs can face the public internet without any protection while administrative APIs should never be exposed without prior authorization. To protect the admini...
40.371585
446
0.589063
736a01293b4ef40aa56c5410c5a78bffba53eb8e
2,197
py
Python
river/feature_selection/k_best.py
online-ml/creme
60872844e6052b5ef20e4075aea30f9031377136
[ "BSD-3-Clause" ]
1,105
2019-01-24T15:15:30.000Z
2020-11-10T18:27:00.000Z
river/feature_selection/k_best.py
online-ml/creme
60872844e6052b5ef20e4075aea30f9031377136
[ "BSD-3-Clause" ]
328
2019-01-25T13:48:43.000Z
2020-11-11T11:41:44.000Z
river/feature_selection/k_best.py
online-ml/creme
60872844e6052b5ef20e4075aea30f9031377136
[ "BSD-3-Clause" ]
150
2019-01-29T19:05:21.000Z
2020-11-11T11:50:14.000Z
import collections import copy import functools from river import base, stats class SelectKBest(base.SupervisedTransformer): """Removes all but the $k$ highest scoring features. Parameters ---------- similarity k The number of features to keep. Attributes ---------- similari...
23.623656
85
0.568047
736a189242770a508688757455af5510bf0223ea
3,045
py
Python
ktaned/button.py
MartinHarding/ktaned
b38fb91b4e2d370d20310e472863766007d4adb3
[ "MIT" ]
1
2017-12-02T21:21:37.000Z
2017-12-02T21:21:37.000Z
ktaned/button.py
MartinHarding/ktaned
b38fb91b4e2d370d20310e472863766007d4adb3
[ "MIT" ]
22
2017-12-02T05:15:32.000Z
2018-07-24T02:04:56.000Z
ktaned/button.py
MartinHarding/ktaned
b38fb91b4e2d370d20310e472863766007d4adb3
[ "MIT" ]
2
2017-12-01T23:49:17.000Z
2017-12-27T17:05:03.000Z
class Button(object): """Represents the button module""" def __init__(self, bomb): super(Button, self).__init__() self.bomb = bomb self.valid_colors = ['red', 'blue', 'yellow', 'white'] self.valid_light_colors = ['red', 'blue', 'yellow', 'white', 'green'] self.valid_label...
36.686747
77
0.56289
736a23db0bcd8b9641609aeac463cf6fc5775fcf
9,089
py
Python
lost_ds/cropping/cropping.py
l3p-cv/lost_ds
4a2f3ef027128b759d28e67cb1fdaa0a557e343c
[ "MIT" ]
1
2022-03-30T11:29:57.000Z
2022-03-30T11:29:57.000Z
lost_ds/cropping/cropping.py
l3p-cv/lost_ds
4a2f3ef027128b759d28e67cb1fdaa0a557e343c
[ "MIT" ]
null
null
null
lost_ds/cropping/cropping.py
l3p-cv/lost_ds
4a2f3ef027128b759d28e67cb1fdaa0a557e343c
[ "MIT" ]
null
null
null
import os from typing import Iterable from tqdm import tqdm import pandas as pd from joblib import Parallel, delayed from lost_ds.functional.filter import label_selection, selection_mask import numpy as np from lost_ds.functional.transform import to_abs, polygon_to_bbox from lost_ds.io.file_man import FileMan from l...
42.872642
103
0.592254
736a27c5ae246bae240fb6f1a1c183ecd1e4f297
6,328
py
Python
tests.py
cellularmitosis/retainn
9e59024f3b35d4bb0bdf675b9f29369569e2080b
[ "MIT" ]
1
2021-06-05T08:40:44.000Z
2021-06-05T08:40:44.000Z
tests.py
cellularmitosis/retainn
9e59024f3b35d4bb0bdf675b9f29369569e2080b
[ "MIT" ]
null
null
null
tests.py
cellularmitosis/retainn
9e59024f3b35d4bb0bdf675b9f29369569e2080b
[ "MIT" ]
1
2021-10-14T12:28:32.000Z
2021-10-14T12:28:32.000Z
"""Retainn unit test functions.""" from __future__ import print_function import sqlite3 import sys sys.path.insert(0, "./lib") from retainn import db from retainn import curl from retainn import util from retainn import py23 def make_memory_db(): """Create an in-memory databse with our schema.""" # 'isolat...
27.275862
105
0.671144
736a2afe3408ac6e2f3ed6cdcb49049f80c12c0c
3,817
py
Python
cheesecake/logger.py
griggheo/cheesecake
2b7aa5c980e8becb163cbcb801b202b17f715054
[ "CNRI-Python-GPL-Compatible" ]
12
2015-01-15T01:13:42.000Z
2022-03-04T21:14:27.000Z
cheesecake/logger.py
griggheo/cheesecake
2b7aa5c980e8becb163cbcb801b202b17f715054
[ "CNRI-Python-GPL-Compatible" ]
6
2015-01-19T19:46:51.000Z
2019-02-05T20:20:26.000Z
cheesecake/logger.py
griggheo/cheesecake
2b7aa5c980e8becb163cbcb801b202b17f715054
[ "CNRI-Python-GPL-Compatible" ]
3
2015-10-24T20:08:09.000Z
2019-02-04T20:53:21.000Z
from __future__ import print_function import sys import re ######################################################## ############### PRODUCERS ############################## ######################################################## class Message(object): def __init__(self, keywords, args): self.keywords = ...
29.361538
75
0.566675
736a31aafde2b95ef541b66d9d61dd53ae3050f1
5,845
py
Python
alipay/aop/api/domain/ScheduleOdItem.py
antopen/alipay-sdk-python-all
8e51c54409b9452f8d46c7bb10eea7c8f7e8d30c
[ "Apache-2.0" ]
213
2018-08-27T16:49:32.000Z
2021-12-29T04:34:12.000Z
alipay/aop/api/domain/ScheduleOdItem.py
antopen/alipay-sdk-python-all
8e51c54409b9452f8d46c7bb10eea7c8f7e8d30c
[ "Apache-2.0" ]
29
2018-09-29T06:43:00.000Z
2021-09-02T03:27:32.000Z
alipay/aop/api/domain/ScheduleOdItem.py
antopen/alipay-sdk-python-all
8e51c54409b9452f8d46c7bb10eea7c8f7e8d30c
[ "Apache-2.0" ]
59
2018-08-27T16:59:26.000Z
2022-03-25T10:08:15.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- import json from alipay.aop.api.constant.ParamConstants import * class ScheduleOdItem(object): def __init__(self): self._cluster_class = None self._direction = None self._end_load = None self._end_load_percent = None self._end...
30.602094
83
0.582207
736a5582ddbb539e1f6d0d300f22e8f86f2892bf
1,151
py
Python
scigateway_auth/app.py
ral-facilities/scigateway-auth
52b85fd477d84bcb1782f1417f03093c86121548
[ "Apache-2.0" ]
null
null
null
scigateway_auth/app.py
ral-facilities/scigateway-auth
52b85fd477d84bcb1782f1417f03093c86121548
[ "Apache-2.0" ]
9
2021-03-04T16:53:21.000Z
2021-07-16T09:59:33.000Z
scigateway_auth/app.py
ral-facilities/scigateway-auth
52b85fd477d84bcb1782f1417f03093c86121548
[ "Apache-2.0" ]
1
2021-11-05T15:46:56.000Z
2021-11-05T15:46:56.000Z
from flask import Flask from flask_cors import CORS from flask_restful import Api if __name__ == "__main__": # NOQA: E402 from scigateway_auth.common import constants constants.SECURE = False from scigateway_auth.common.config import Config, get_config_value from scigateway_auth.common.logger_setup import s...
28.073171
72
0.772372
736a70141ac6b5c3add27daddc0130644aeef896
11,313
py
Python
NBA Project/venv/Lib/site-packages/plotly/graph_objs/barpolar/unselected/__init__.py
EnriqueGambra/Most-Efficient-NBA-Players
ea67c28b5294dbc9713200a937deb9f4211ba754
[ "MIT" ]
1
2020-08-08T21:56:11.000Z
2020-08-08T21:56:11.000Z
NBA Project/venv/Lib/site-packages/plotly/graph_objs/barpolar/unselected/__init__.py
EnriqueGambra/Most-Efficient-NBA-Players
ea67c28b5294dbc9713200a937deb9f4211ba754
[ "MIT" ]
2
2021-03-31T19:54:17.000Z
2021-06-02T02:33:56.000Z
NBA Project/venv/Lib/site-packages/plotly/graph_objs/barpolar/unselected/__init__.py
EnriqueGambra/Most-Efficient-NBA-Players
ea67c28b5294dbc9713200a937deb9f4211ba754
[ "MIT" ]
null
null
null
from plotly.basedatatypes import BaseTraceHierarchyType as _BaseTraceHierarchyType import copy as _copy class Textfont(_BaseTraceHierarchyType): # color # ----- @property def color(self): """ Sets the text font color of unselected points, applied only when a selection exists. ...
35.687697
82
0.559798
736a759da5dd177eba7380c37dcf4e25c78b06af
97,091
py
Python
quest/keras/backend/theano_backend.py
shuokabe/deepQuest-mod
7140a57c30deedb0570bc835c6ad3c848f0039f4
[ "BSD-3-Clause" ]
null
null
null
quest/keras/backend/theano_backend.py
shuokabe/deepQuest-mod
7140a57c30deedb0570bc835c6ad3c848f0039f4
[ "BSD-3-Clause" ]
null
null
null
quest/keras/backend/theano_backend.py
shuokabe/deepQuest-mod
7140a57c30deedb0570bc835c6ad3c848f0039f4
[ "BSD-3-Clause" ]
null
null
null
from collections import defaultdict from contextlib import contextmanager import theano from theano import tensor as T from theano.sandbox.rng_mrg import MRG_RandomStreams as RandomStreams from theano.tensor.signal import pool from theano.tensor.nnet import conv3d2d from theano.tensor.fft import rfft, irfft from theano...
33.595502
115
0.599561
736a874e8ae60bb5c05535897c097f11037e0a21
973
py
Python
atom/nucleus/python/test/test_page_client_business_card_vo.py
AbhiGupta03/SDK
f3a61aae7a847f07f0c22a154ca88dc378e9d25e
[ "Apache-2.0" ]
null
null
null
atom/nucleus/python/test/test_page_client_business_card_vo.py
AbhiGupta03/SDK
f3a61aae7a847f07f0c22a154ca88dc378e9d25e
[ "Apache-2.0" ]
null
null
null
atom/nucleus/python/test/test_page_client_business_card_vo.py
AbhiGupta03/SDK
f3a61aae7a847f07f0c22a154ca88dc378e9d25e
[ "Apache-2.0" ]
null
null
null
# coding: utf-8 """ Hydrogen Nucleus API The Hydrogen Nucleus API # noqa: E501 OpenAPI spec version: 1.9.5 Contact: info@hydrogenplatform.com Generated by: https://github.com/swagger-api/swagger-codegen.git """ from __future__ import absolute_import import unittest import nucleus_api from nu...
23.731707
106
0.729702
736a9ac0e16ae14f23b49c950941f3c97edb675e
2,061
py
Python
src/gedml/core/metrics/metric_factory.py
wangck20/GeDML
1f76ac2094d7b88be7fd4eb6145e5586e547b9ca
[ "MIT" ]
25
2021-09-06T13:26:02.000Z
2022-01-06T13:25:24.000Z
src/gedml/core/metrics/metric_factory.py
wangck20/GeDML
1f76ac2094d7b88be7fd4eb6145e5586e547b9ca
[ "MIT" ]
1
2021-09-09T08:29:29.000Z
2021-09-13T15:05:59.000Z
src/gedml/core/metrics/metric_factory.py
wangck20/GeDML
1f76ac2094d7b88be7fd4eb6145e5586e547b9ca
[ "MIT" ]
2
2021-09-07T08:44:41.000Z
2021-09-09T08:31:55.000Z
import torch import torch.nn.functional as F from . import ( distance_metrics, similarity_metrics ) class MetricFactory(torch.nn.Module): """ Get different metric (distance or similarity) Args: is_normalize (bool): Whether to normalize the embeddings metr...
30.761194
91
0.550218
736ab0245f91fd33404bc2a536230a1fc06d884a
543
py
Python
utils.py
KitHaywood/Gecko
92f322d5248229ca11b1a5b7fd43028e0ac66f39
[ "Apache-2.0" ]
null
null
null
utils.py
KitHaywood/Gecko
92f322d5248229ca11b1a5b7fd43028e0ac66f39
[ "Apache-2.0" ]
null
null
null
utils.py
KitHaywood/Gecko
92f322d5248229ca11b1a5b7fd43028e0ac66f39
[ "Apache-2.0" ]
null
null
null
import datetime as dt import pandas as pd def date_range_lister(): end = dt.date.today() diff = dt.timedelta(days=1827, seconds=0, microseconds=0, milliseconds=0, minutes=0, hours=0, weeks=0) start = end - diff dates = pd.date_range(start=start,end=end,freq='D') dates = [int(x.timestamp()) for x in...
25.857143
106
0.620626
736b2f6f59351046924832c459c6fd32e37bea53
5,085
py
Python
tests/python/pants_test/backend/python/tasks/test_build_local_python_distributions.py
tpasternak/pants
edf5716283d449852309fff1a10dd351dfbf3493
[ "Apache-2.0" ]
1
2021-05-05T18:58:28.000Z
2021-05-05T18:58:28.000Z
tests/python/pants_test/backend/python/tasks/test_build_local_python_distributions.py
tpasternak/pants
edf5716283d449852309fff1a10dd351dfbf3493
[ "Apache-2.0" ]
null
null
null
tests/python/pants_test/backend/python/tasks/test_build_local_python_distributions.py
tpasternak/pants
edf5716283d449852309fff1a10dd351dfbf3493
[ "Apache-2.0" ]
3
2020-06-30T08:28:13.000Z
2021-07-28T09:35:57.000Z
# Copyright 2017 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). import re from collections import OrderedDict import pex.resolver from pants.backend.python.targets.python_distribution import PythonDistribution from pants.backend.python.targets.python...
34.591837
92
0.564995
736b30ddfdf71734f50dc4ef3111370115e171e2
5,018
py
Python
pysnooapi/device.py
sanghviharshit/pysnoo
c896f22cc60ae5c917551d5a349ded190de861ae
[ "MIT" ]
null
null
null
pysnooapi/device.py
sanghviharshit/pysnoo
c896f22cc60ae5c917551d5a349ded190de861ae
[ "MIT" ]
13
2021-03-10T07:31:19.000Z
2021-07-16T19:08:23.000Z
pysnooapi/device.py
sanghviharshit/pysnooapi
c896f22cc60ae5c917551d5a349ded190de861ae
[ "MIT" ]
null
null
null
"""Define Snoo device.""" import logging from datetime import datetime from .utils import parse_datetime from typing import TYPE_CHECKING, Optional if TYPE_CHECKING: from .api import API _LOGGER = logging.getLogger(__name__) class SnooDevice: """Define a snoo device.""" def __init__( self, api: ...
35.090909
133
0.640694
736b752d5e26e6c76bccaff9aa40748692a9fbcf
2,507
py
Python
src/olympia/blocklist/tests/test_models.py
abhinavraj23/addons-server
b9e3cc09718679d2a72d8e305b79d98d1421c397
[ "BSD-3-Clause" ]
null
null
null
src/olympia/blocklist/tests/test_models.py
abhinavraj23/addons-server
b9e3cc09718679d2a72d8e305b79d98d1421c397
[ "BSD-3-Clause" ]
null
null
null
src/olympia/blocklist/tests/test_models.py
abhinavraj23/addons-server
b9e3cc09718679d2a72d8e305b79d98d1421c397
[ "BSD-3-Clause" ]
null
null
null
from django.test.utils import override_settings from olympia.amo.tests import TestCase, user_factory from olympia.versions.compare import MAX_VERSION_PART from ..models import Block, BlockSubmission class TestBlock(TestCase): def test_is_version_blocked(self): block = Block.objects.create(guid='anyguid@...
37.984848
73
0.702034
736badbe5821a7439989878d807907cbc3bf94dc
1,959
py
Python
test_equipment/recorder_test/run_recorder_test.py
ChildMindInstitute/test_recording_equipment
ce062be5c278f4c32c72eadd90b68e4898e9f1fe
[ "Apache-2.0" ]
1
2018-07-20T23:45:22.000Z
2018-07-20T23:45:22.000Z
test_equipment/recorder_test/run_recorder_test.py
ChildMindInstitute/test-recording-equipment
ce062be5c278f4c32c72eadd90b68e4898e9f1fe
[ "Apache-2.0" ]
null
null
null
test_equipment/recorder_test/run_recorder_test.py
ChildMindInstitute/test-recording-equipment
ce062be5c278f4c32c72eadd90b68e4898e9f1fe
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Batch process recorder tests with user-entered openSMILE configuration file. Author: – Jon Clucas, 2017 (jon.clucas@childmind.org) © 2017, Child Mind Institute, Apache v2.0 License """ import os, subprocess def recurse(top_dir): """ Function to recursively...
31.596774
78
0.548749
736bb8236d6db68bd0949e27652569fa971a400e
28,170
py
Python
electrum/plugins/ledger/ledger.py
Snowgem/electrum-snowgem
00fed4af563930fd3a364694f8c38262059e98dc
[ "MIT" ]
2
2019-09-18T23:26:27.000Z
2019-09-21T16:39:18.000Z
electrum/plugins/ledger/ledger.py
Snowgem/electrum-snowgem
00fed4af563930fd3a364694f8c38262059e98dc
[ "MIT" ]
null
null
null
electrum/plugins/ledger/ledger.py
Snowgem/electrum-snowgem
00fed4af563930fd3a364694f8c38262059e98dc
[ "MIT" ]
8
2018-04-11T01:05:12.000Z
2020-03-24T22:26:30.000Z
from struct import pack, unpack import hashlib import sys import traceback from typing import Optional from . import bitcoin from electrum import ecc from electrum import bip32 from electrum.crypto import hash_160 from electrum.bitcoin import int_to_hex, var_int, is_segwit_script_type from electrum.bip32 import BIP32N...
44.362205
242
0.59077
736c25d3ea88511f98839a72d70280225ffc2c5b
1,265
py
Python
plugins/maya/publish/validate_mesh_has_vertex.py
davidlatwe/reveries-config
4a282dd64a32a9b87bd1a070759b6425ff785d68
[ "MIT" ]
3
2020-04-01T10:51:17.000Z
2021-08-05T18:35:23.000Z
plugins/maya/publish/validate_mesh_has_vertex.py
davidlatwe/reveries-config
4a282dd64a32a9b87bd1a070759b6425ff785d68
[ "MIT" ]
null
null
null
plugins/maya/publish/validate_mesh_has_vertex.py
davidlatwe/reveries-config
4a282dd64a32a9b87bd1a070759b6425ff785d68
[ "MIT" ]
1
2020-07-05T12:06:30.000Z
2020-07-05T12:06:30.000Z
import pyblish.api from reveries import plugins class RepairInvalid(plugins.RepairInstanceAction): label = "Delete No Vertex Meshes" class ValidateMeshHasVertex(pyblish.api.InstancePlugin): """Validate meshes must has vertex""" order = pyblish.api.ValidatorOrder label = "Mesh Has Vertex" host...
24.803922
63
0.618182
736c294572de3cbdf8f15df6f60e2b2dcca45a6c
1,668
py
Python
examples/ordering-by-key-server.py
bohblue2/callosum
adb8f6aa2d44cd3c4448f6899027a2964eca380a
[ "MIT" ]
19
2018-08-17T15:58:43.000Z
2022-03-31T07:12:43.000Z
examples/ordering-by-key-server.py
bohblue2/callosum
adb8f6aa2d44cd3c4448f6899027a2964eca380a
[ "MIT" ]
9
2018-11-15T15:44:11.000Z
2019-12-06T15:32:57.000Z
examples/ordering-by-key-server.py
bohblue2/callosum
adb8f6aa2d44cd3c4448f6899027a2964eca380a
[ "MIT" ]
2
2018-05-16T06:02:39.000Z
2020-07-24T06:30:58.000Z
import asyncio import json import signal from callosum.rpc import Peer from callosum.ordering import ( KeySerializedAsyncScheduler, ) from callosum.lower.zeromq import ZeroMQAddress, ZeroMQRPCTransport async def handle_echo(request): print('echo start') await asyncio.sleep(1) print('echo done') r...
26.0625
70
0.66247
736c332091d3c445f9a04b04f577dcbfc32c834b
4,518
py
Python
testing/pyDAE/cstr_as_as_singleton_model.py
kuanhanl/cappresse
31cd7d03414a930f7e2c21e1a3eb5e7dd25cc500
[ "MIT" ]
2
2019-09-26T20:56:06.000Z
2019-11-18T21:03:27.000Z
testing/pyDAE/cstr_as_as_singleton_model.py
kuanhanl/cappresse
31cd7d03414a930f7e2c21e1a3eb5e7dd25cc500
[ "MIT" ]
6
2018-03-19T20:36:49.000Z
2018-04-13T15:27:29.000Z
testing/pyDAE/cstr_as_as_singleton_model.py
kuanhanl/cappresse
31cd7d03414a930f7e2c21e1a3eb5e7dd25cc500
[ "MIT" ]
5
2018-10-04T18:51:02.000Z
2020-07-02T15:31:35.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- from __future__ import division from __future__ import print_function from nmpc_mhe.aux.utils import load_iguess from nmpc_mhe.pyomo_dae.MHEGen_pyDAE import MheGen_DAE from sample_mods.cstr_rodrigo.cstr_c_singleton import cstr_rodrigo_dae import os, sys import matplotlib....
32.042553
100
0.59429
736c547e0a903d60e198e27c0d565ab713d116f6
3,973
py
Python
homeassistant/components/ais_google_home/config_flow.py
stravinci/AIS-home-assistant
ead4dafd3f801ebeb32860bd34443ed24a4f4167
[ "Apache-2.0" ]
5
2020-01-21T16:06:49.000Z
2021-12-20T11:54:20.000Z
homeassistant/components/ais_google_home/config_flow.py
stravinci/AIS-home-assistant
ead4dafd3f801ebeb32860bd34443ed24a4f4167
[ "Apache-2.0" ]
68
2018-10-04T16:01:20.000Z
2022-03-31T06:21:46.000Z
homeassistant/components/ais_google_home/config_flow.py
stravinci/AIS-home-assistant
ead4dafd3f801ebeb32860bd34443ed24a4f4167
[ "Apache-2.0" ]
7
2018-10-04T10:12:45.000Z
2021-12-29T20:55:40.000Z
"""Config flow to configure the AIS Drive Service component.""" import json import logging import voluptuous as vol from homeassistant import config_entries from homeassistant.components import ais_cloud from homeassistant.const import CONF_ACCESS_TOKEN, CONF_NAME from homeassistant.core import callback from .const...
35.792793
88
0.633778
736c8602bf109ea043592d19b9be2efc41200284
1,130
py
Python
data/transcoder_evaluation_gfg/python/COUNT_BINARY_STRINGS_K_TIMES_APPEARING_ADJACENT_TWO_SET_BITS.py
mxl1n/CodeGen
e5101dd5c5e9c3720c70c80f78b18f13e118335a
[ "MIT" ]
241
2021-07-20T08:35:20.000Z
2022-03-31T02:39:08.000Z
data/transcoder_evaluation_gfg/python/COUNT_BINARY_STRINGS_K_TIMES_APPEARING_ADJACENT_TWO_SET_BITS.py
mxl1n/CodeGen
e5101dd5c5e9c3720c70c80f78b18f13e118335a
[ "MIT" ]
49
2021-07-22T23:18:42.000Z
2022-03-24T09:15:26.000Z
data/transcoder_evaluation_gfg/python/COUNT_BINARY_STRINGS_K_TIMES_APPEARING_ADJACENT_TWO_SET_BITS.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 ( n , k ) : dp = [ [ [ 0 , 0 ] for __ in range ( k + 1 ) ] for _ in range ( n + 1 ) ] dp [ 1 ] [ 0 ] [ 0 ] = ...
28.974359
90
0.425664
736cb43142bcc7d67cf9eeab9f7f4476cbd9b17d
7,125
py
Python
sdk/python/kfp/containers/entrypoint_utils.py
Iuiu1234/pipelines
1e032f550ce23cd40bfb6827b995248537b07d08
[ "Apache-2.0" ]
2,860
2018-05-24T04:55:01.000Z
2022-03-31T13:49:56.000Z
sdk/python/kfp/containers/entrypoint_utils.py
Iuiu1234/pipelines
1e032f550ce23cd40bfb6827b995248537b07d08
[ "Apache-2.0" ]
7,331
2018-05-16T09:03:26.000Z
2022-03-31T23:22:04.000Z
sdk/python/kfp/containers/entrypoint_utils.py
Iuiu1234/pipelines
1e032f550ce23cd40bfb6827b995248537b07d08
[ "Apache-2.0" ]
1,359
2018-05-15T11:05:41.000Z
2022-03-31T09:42:09.000Z
# Copyright 2021 The Kubeflow Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in...
37.303665
113
0.674526
736cc74cb417c1add18a4e0220829e211cf9949e
10,684
py
Python
opencadd/io/dataframe.py
pipaj97/opencadd
4fcf090bd612a22df9d617473ae458316a4cb4b6
[ "MIT" ]
39
2020-08-14T07:33:21.000Z
2022-03-30T02:05:19.000Z
opencadd/io/dataframe.py
pipaj97/opencadd
4fcf090bd612a22df9d617473ae458316a4cb4b6
[ "MIT" ]
94
2020-06-29T12:47:46.000Z
2022-02-13T19:16:25.000Z
opencadd/io/dataframe.py
volkamerlab/superposer
6c52a31a26f5ad32076d487929c8f4062392b2a7
[ "MIT" ]
11
2020-11-11T17:12:38.000Z
2022-03-21T09:23:39.000Z
""" opencadd.io.dataframes Defines classes that convert structural data into DataFrames. """ import logging from biopandas.mol2 import PandasMol2 from biopandas.pdb import PandasPdb import numpy as np import pandas as pd from .core import _Base from .schema import DATAFRAME_COLUMNS, PDB_COLUMNS, MOL2_COLUMNS logge...
30.878613
99
0.578716
736d012cc968c209153b294a0de0204c0f3b203c
13,566
py
Python
dipy/workflows/docstring_parser.py
martcous/dipy
6bff5655f03db19bde5aa951ffb91987983a889b
[ "MIT" ]
null
null
null
dipy/workflows/docstring_parser.py
martcous/dipy
6bff5655f03db19bde5aa951ffb91987983a889b
[ "MIT" ]
null
null
null
dipy/workflows/docstring_parser.py
martcous/dipy
6bff5655f03db19bde5aa951ffb91987983a889b
[ "MIT" ]
null
null
null
""" This was taken directly from the file docscrape.py of numpydoc package. Copyright (C) 2008 Stefan van der Walt <stefan@mentat.za.net>, Pauli Virtanen <pav@iki.fi> Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Red...
30.692308
79
0.513268
736d14b850cc7023ccc1d0b1198a6e68b3529492
3,780
py
Python
bitbots_connector/src/bitbots_connector/capsules/team_data_capsule.py
TAMS-Group/bitbots_behaviour
84f713060e6be0803dff1bc3df1bdef49bef02e3
[ "BSD-3-Clause" ]
null
null
null
bitbots_connector/src/bitbots_connector/capsules/team_data_capsule.py
TAMS-Group/bitbots_behaviour
84f713060e6be0803dff1bc3df1bdef49bef02e3
[ "BSD-3-Clause" ]
null
null
null
bitbots_connector/src/bitbots_connector/capsules/team_data_capsule.py
TAMS-Group/bitbots_behaviour
84f713060e6be0803dff1bc3df1bdef49bef02e3
[ "BSD-3-Clause" ]
1
2020-07-12T12:58:07.000Z
2020-07-12T12:58:07.000Z
""" TeamDataCapsule ^^^^^^^^^^^^^^^ """ import math import rospy from humanoid_league_msgs.msg import Strategy, TeamData class TeamDataCapsule: def __init__(self): self.bot_id = rospy.get_param("bot_id", 1) self.strategy_sender = None # type: rospy.Publisher self.team_data = TeamData() ...
37.058824
121
0.661111
736d37ac854eccd5b11c2493bf5dbbf598671bb8
433
py
Python
pydong/cli.py
lipidong/pydong
5c61a69251f0912f7490f185b13a317ca62ad46e
[ "MIT" ]
null
null
null
pydong/cli.py
lipidong/pydong
5c61a69251f0912f7490f185b13a317ca62ad46e
[ "MIT" ]
null
null
null
pydong/cli.py
lipidong/pydong
5c61a69251f0912f7490f185b13a317ca62ad46e
[ "MIT" ]
null
null
null
"""Console script for pydong.""" import argparse import sys def main(): """Console script for pydong.""" parser = argparse.ArgumentParser() parser.add_argument('_', nargs='*') args = parser.parse_args() print("Arguments: " + str(args._)) print("Replace this message by putting your code into "...
21.65
59
0.632794
736d432eae73c3e4eec629d7f529c08230d6b4db
1,591
py
Python
alipay/aop/api/response/MybankEcnyMerchantSignQueryResponse.py
antopen/alipay-sdk-python-all
8e51c54409b9452f8d46c7bb10eea7c8f7e8d30c
[ "Apache-2.0" ]
null
null
null
alipay/aop/api/response/MybankEcnyMerchantSignQueryResponse.py
antopen/alipay-sdk-python-all
8e51c54409b9452f8d46c7bb10eea7c8f7e8d30c
[ "Apache-2.0" ]
null
null
null
alipay/aop/api/response/MybankEcnyMerchantSignQueryResponse.py
antopen/alipay-sdk-python-all
8e51c54409b9452f8d46c7bb10eea7c8f7e8d30c
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # -*- coding: utf-8 -*- import json from alipay.aop.api.response.AlipayResponse import AlipayResponse class MybankEcnyMerchantSignQueryResponse(AlipayResponse): def __init__(self): super(MybankEcnyMerchantSignQueryResponse, self).__init__() self._merchant_id = None ...
28.410714
108
0.670019
736d6ee9dea756dbe13d656c633d9d0c47bacb3c
2,954
py
Python
json2txttree.py
cibinjoseph/json2txttree
5b3ec3f9faf6a3b147455fed712bee0f9a307f06
[ "MIT" ]
1
2022-02-28T08:39:23.000Z
2022-02-28T08:39:23.000Z
json2txttree.py
cibinjoseph/json2tree
5b3ec3f9faf6a3b147455fed712bee0f9a307f06
[ "MIT" ]
1
2022-02-28T09:15:07.000Z
2022-02-28T09:57:27.000Z
json2txttree.py
cibinjoseph/json2txttree
5b3ec3f9faf6a3b147455fed712bee0f9a307f06
[ "MIT" ]
1
2020-10-15T08:40:21.000Z
2020-10-15T08:40:21.000Z
""" A python code to generate a tree or table for JSON data""" from io import StringIO __version__ = '1.0.0' _branch_extend = '│ ' _branch_mid = '├─ ' _branch_last = '└─ ' _spacing = ' ' def _getHierarchy(jsonData, name='', file=None, _prefix='', _last=True): """ Recursively parse json data to prin...
34.348837
79
0.578876
736d770c83a832eb24fc04bbadc69c376de6078e
11,848
py
Python
aprspy/packets/mice.py
pduran2008/aprs2
d0a11c824c7ec3d2487e2ee92d8b968f71cb2ccf
[ "MIT" ]
11
2019-11-05T08:55:52.000Z
2021-05-14T13:16:49.000Z
aprspy/packets/mice.py
pduran2008/aprs2
d0a11c824c7ec3d2487e2ee92d8b968f71cb2ccf
[ "MIT" ]
12
2019-10-26T04:11:53.000Z
2020-11-14T09:23:07.000Z
aprspy/packets/mice.py
pduran2008/aprs2
d0a11c824c7ec3d2487e2ee92d8b968f71cb2ccf
[ "MIT" ]
1
2019-10-25T03:35:02.000Z
2019-10-25T03:35:02.000Z
#!/usr/bin/env python import logging from typing import Tuple from ..exceptions import ParseError from ..utils import APRSUtils from .position import PositionPacket # Set up logging logger = logging.getLogger(__name__) class MICEPacket(PositionPacket): """ Class to represent Mic-E encoded position packets...
36.121951
100
0.54237
736d8cb01984d059883940ae7ba0ad45a18ce4c2
1,644
py
Python
src/epc_exporter/collector/npu_utilization.py
cisco-cx/epc_exporter
8c433631dcb8118e213f67020760a2d30b4876e0
[ "X11" ]
null
null
null
src/epc_exporter/collector/npu_utilization.py
cisco-cx/epc_exporter
8c433631dcb8118e213f67020760a2d30b4876e0
[ "X11" ]
null
null
null
src/epc_exporter/collector/npu_utilization.py
cisco-cx/epc_exporter
8c433631dcb8118e213f67020760a2d30b4876e0
[ "X11" ]
null
null
null
""" Collects show npu utilization table command and parses it """ from prometheus_client import REGISTRY from prometheus_client.core import GaugeMetricFamily from collector.abstract_command_collector import AbstractCommandCollector from device import AbstractDevice class NPUUtilizationCollector(AbstractCommandColle...
34.25
79
0.564477
736daebd50bc5e50879bc9153d6c3a078f2ce327
151
py
Python
os_ref/environ.py
SeanSyue/PythonReferences
103b2d6934a33e56a5d8fbb14d95282f572b3af7
[ "MIT" ]
null
null
null
os_ref/environ.py
SeanSyue/PythonReferences
103b2d6934a33e56a5d8fbb14d95282f572b3af7
[ "MIT" ]
null
null
null
os_ref/environ.py
SeanSyue/PythonReferences
103b2d6934a33e56a5d8fbb14d95282f572b3af7
[ "MIT" ]
null
null
null
import os os.chdir('/Users/seansyue/') print(os.environ) print(os.environ.get('HOME')) print(os.environ.get('LOGNAME')) print(os.environ.get('PATH'))
18.875
32
0.715232
736dbc28180ec94b18e5b16157aa189e70ce5a06
4,544
py
Python
dags/dcm_run_dag.py
danieldjewell/starthinker
3327d5874f01d7563603b8a82c1ecd6615b9768d
[ "Apache-2.0" ]
1
2020-12-04T17:13:35.000Z
2020-12-04T17:13:35.000Z
dags/dcm_run_dag.py
hgrias/starthinker
b9ed33e23b4ffd72565a31ebb8a8041d346bfca2
[ "Apache-2.0" ]
null
null
null
dags/dcm_run_dag.py
hgrias/starthinker
b9ed33e23b4ffd72565a31ebb8a8041d346bfca2
[ "Apache-2.0" ]
null
null
null
########################################################################### # # Copyright 2020 Google 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 # # https://www.apache.org/l...
32
145
0.552597
736dc6d57abe79f90decf03309e4143d6223b9b4
1,755
py
Python
examples/flask_app/app.py
obrunet/PyLinux
f99a4f36fc40c7afa37441e00a2578608ceaabd4
[ "Apache-2.0" ]
3
2016-04-03T23:39:46.000Z
2019-06-27T13:40:34.000Z
examples/flask_app/app.py
obrunet/PyLinux
f99a4f36fc40c7afa37441e00a2578608ceaabd4
[ "Apache-2.0" ]
null
null
null
examples/flask_app/app.py
obrunet/PyLinux
f99a4f36fc40c7afa37441e00a2578608ceaabd4
[ "Apache-2.0" ]
2
2019-06-09T03:27:43.000Z
2019-10-21T14:29:15.000Z
import pylinux.pylinux as pylinux from collections import OrderedDict from flask import Flask, render_template import json app = Flask(__name__) @app.route("/plot") def memory(): data={} freemem=str(float(pylinux.freemem().split()[0])/1024.0) data['freemem'] = freemem nfiles = pylinux.lsof() d...
35.1
106
0.523647
736dd3aa9c91219f1d5f7046ce35ce75197a9982
1,010
py
Python
djangocms_navigation/migrations/0006_auto_20190410_0855.py
Bernardvdv/djangocms-navigation
200fff28cbb46fb2fd2504d00702cf2be8d687fa
[ "BSD-3-Clause" ]
6
2018-12-12T10:45:42.000Z
2022-03-16T20:50:36.000Z
djangocms_navigation/migrations/0006_auto_20190410_0855.py
Bernardvdv/djangocms-navigation
200fff28cbb46fb2fd2504d00702cf2be8d687fa
[ "BSD-3-Clause" ]
15
2019-01-08T11:55:31.000Z
2022-03-01T15:06:52.000Z
djangocms_navigation/migrations/0006_auto_20190410_0855.py
Bernardvdv/djangocms-navigation
200fff28cbb46fb2fd2504d00702cf2be8d687fa
[ "BSD-3-Clause" ]
9
2018-12-14T00:58:25.000Z
2022-03-11T17:16:17.000Z
# -*- coding: utf-8 -*- # Generated by Django 1.11.20 on 2019-04-10 08:55 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('djangocms_navigation', '0005_navigationplugin_menu'), ...
32.580645
194
0.656436
736dd8b02cf618a8730e31bbd8145fedd3764021
2,350
py
Python
python/phonenumbers/data/region_MD.py
Eyepea/python-phonenumbers
0336e191fda80a21ed5c19d5e029ad8c70f620ee
[ "Apache-2.0" ]
2
2019-03-30T02:12:54.000Z
2021-03-08T18:59:40.000Z
python/phonenumbers/data/region_MD.py
Eyepea/python-phonenumbers
0336e191fda80a21ed5c19d5e029ad8c70f620ee
[ "Apache-2.0" ]
null
null
null
python/phonenumbers/data/region_MD.py
Eyepea/python-phonenumbers
0336e191fda80a21ed5c19d5e029ad8c70f620ee
[ "Apache-2.0" ]
1
2018-11-10T03:47:34.000Z
2018-11-10T03:47:34.000Z
"""Auto-generated file, do not edit by hand. MD metadata""" from ..phonemetadata import NumberFormat, PhoneNumberDesc, PhoneMetadata PHONE_METADATA_MD = PhoneMetadata(id='MD', country_code=373, international_prefix='00', general_desc=PhoneNumberDesc(national_number_pattern='[235-9]\\d{7}', possible_number_pattern=...
102.173913
219
0.72383
736de57c7746ec95eb06834d2679865e54e3ea2c
252
py
Python
jaraco/windows/api/library.py
jaraco/jaraco.windows
e858172b4d5ee91233a8cc5319de99f17848f090
[ "MIT" ]
21
2016-01-31T00:58:59.000Z
2021-05-06T22:30:56.000Z
jaraco/windows/api/library.py
jaraco/jaraco.windows
e858172b4d5ee91233a8cc5319de99f17848f090
[ "MIT" ]
14
2016-07-21T12:02:08.000Z
2021-08-06T03:07:54.000Z
jaraco/windows/api/library.py
jaraco/jaraco.windows
e858172b4d5ee91233a8cc5319de99f17848f090
[ "MIT" ]
5
2016-06-14T04:57:04.000Z
2021-05-06T22:30:57.000Z
import ctypes.wintypes GetModuleFileName = ctypes.windll.kernel32.GetModuleFileNameW GetModuleFileName.argtypes = ( ctypes.wintypes.HANDLE, ctypes.wintypes.LPWSTR, ctypes.wintypes.DWORD, ) GetModuleFileName.restype = ctypes.wintypes.DWORD
25.2
61
0.801587
736dea3aa749945c91bdb3c90da19bea5b2ec6f1
5,756
py
Python
ssde.py
cooperlees/smartthings_schlage_doorlock_exporter
0b03e1bf2c50696633bc9cf371c20969dcefdb86
[ "BSD-2-Clause" ]
1
2021-07-03T00:33:42.000Z
2021-07-03T00:33:42.000Z
ssde.py
cooperlees/smartthings_schlage_doorlock_exporter
0b03e1bf2c50696633bc9cf371c20969dcefdb86
[ "BSD-2-Clause" ]
1
2020-11-11T05:16:53.000Z
2020-11-11T05:55:50.000Z
ssde.py
cooperlees/smartthings_schlage_doorlock_exporter
0b03e1bf2c50696633bc9cf371c20969dcefdb86
[ "BSD-2-Clause" ]
1
2021-07-03T00:33:45.000Z
2021-07-03T00:33:45.000Z
#!/usr/bin/env python3 import argparse import asyncio import aiohttp import logging import sys import time from collections import defaultdict from os import environ from typing import Dict, Generator, List, Optional import pysmartthings from prometheus_client.core import GaugeMetricFamily, REGISTRY from prometheus_c...
29.070707
86
0.61501
736e1b447baff8e9e5f3d54dd7eba9e4b4def37c
25
py
Python
btd6_memory_info/generated/NinjaKiwi/NKMulti/IO/MessageReader/message_reader.py
56kyle/bloons_auto
419d55b51d1cddc49099593970adf1c67985b389
[ "MIT" ]
null
null
null
btd6_memory_info/generated/NinjaKiwi/NKMulti/IO/MessageReader/message_reader.py
56kyle/bloons_auto
419d55b51d1cddc49099593970adf1c67985b389
[ "MIT" ]
null
null
null
btd6_memory_info/generated/NinjaKiwi/NKMulti/IO/MessageReader/message_reader.py
56kyle/bloons_auto
419d55b51d1cddc49099593970adf1c67985b389
[ "MIT" ]
null
null
null
class MessageReader: pass
25
25
0.88
736e2974055bda6786e620071d6ca086e71a89d2
3,695
py
Python
greeneye/test_streams.py
drkp/greeneye-monitor
412bd9ec36613dbe93b1b86bda10610b381b2dae
[ "MIT" ]
null
null
null
greeneye/test_streams.py
drkp/greeneye-monitor
412bd9ec36613dbe93b1b86bda10610b381b2dae
[ "MIT" ]
null
null
null
greeneye/test_streams.py
drkp/greeneye-monitor
412bd9ec36613dbe93b1b86bda10610b381b2dae
[ "MIT" ]
null
null
null
import logging import sys import unittest from . import streams from .packets import * from .packet_test_data import read_packet, read_packets, assert_packet logging.basicConfig( stream=sys.stderr, level=logging.DEBUG, format='%(asctime)s [%(name)s](%(levelname)s) %(message)s') class TestPacketAccumulat...
41.055556
109
0.691475
736e4685ec277bdd24cac1771e524c5cc4da8f91
10,356
py
Python
sendim/models/event.py
ZuluPro/snafu
dbd79da4617db315ba7e76a0af6805cc3b1cbae2
[ "BSD-3-Clause" ]
1
2017-12-13T20:28:32.000Z
2017-12-13T20:28:32.000Z
sendim/models/event.py
ZuluPro/snafu
dbd79da4617db315ba7e76a0af6805cc3b1cbae2
[ "BSD-3-Clause" ]
null
null
null
sendim/models/event.py
ZuluPro/snafu
dbd79da4617db315ba7e76a0af6805cc3b1cbae2
[ "BSD-3-Clause" ]
null
null
null
from django.db import models from sendim.exceptions import UnableToConnectGLPI from sendim.glpi_manager import GLPI_Manager GLPI_Manager = GLPI_Manager() class Event(models.Model) : element = models.ForeignKey('referentiel.Host') date = models.DateTimeField() criticity = models.CharField(max_length=30) message = ...
29.33711
149
0.667825
736e6c63e972f2e29a5a0e8387439dca788500ca
402
py
Python
terrascript/resource/google_beta.py
mjuenema/python-terrascript
6d8bb0273a14bfeb8ff8e950fe36f97f7c6e7b1d
[ "BSD-2-Clause" ]
507
2017-07-26T02:58:38.000Z
2022-01-21T12:35:13.000Z
terrascript/resource/google_beta.py
mjuenema/python-terrascript
6d8bb0273a14bfeb8ff8e950fe36f97f7c6e7b1d
[ "BSD-2-Clause" ]
135
2017-07-20T12:01:59.000Z
2021-10-04T22:25:40.000Z
terrascript/resource/google_beta.py
mjuenema/python-terrascript
6d8bb0273a14bfeb8ff8e950fe36f97f7c6e7b1d
[ "BSD-2-Clause" ]
81
2018-02-20T17:55:28.000Z
2022-01-31T07:08:40.000Z
# terrascript/resource/google_beta.py # Automatically generated by tools/makecode.py (24-Sep-2021 15:17:17 UTC) # # For imports without namespace, e.g. # # >>> import terrascript.resource.google_beta # # instead of # # >>> import terrascript.resource.hashicorp.google_beta # # This is only available for 'official' a...
26.8
73
0.758706
736e763210f6a4a13e9addf3415a9cf0f6ad4d35
2,339
py
Python
app/tools/term.py
lucid281/botcannon
635504a5af3325cce1b7f760ff860270d3639999
[ "MIT" ]
2
2019-08-06T17:31:00.000Z
2019-08-06T18:56:49.000Z
app/tools/term.py
lucid281/botcannon
635504a5af3325cce1b7f760ff860270d3639999
[ "MIT" ]
null
null
null
app/tools/term.py
lucid281/botcannon
635504a5af3325cce1b7f760ff860270d3639999
[ "MIT" ]
null
null
null
from math import ceil, floor def plot(series, minimum=None, maximum=None, offset=4, height=7, placeholder='{:8.2f} ', chat=False): """ Possible cfg parameters are 'minimum', 'maximum', 'offset', 'height' and 'format'. cfg is a dictionary, thus dictionary syntax has to be used. Example: print(plot(series, ...
32.486111
101
0.506627
736e77a56e0b102b6ba4434530e9a731c8e37261
504
py
Python
tests/pipe_proc_tests/mult.py
genematx/nmrglue
8a24cf6cbd18451e552fc0673b84c42d1dcb69a2
[ "BSD-3-Clause" ]
150
2015-01-16T12:24:13.000Z
2022-03-03T18:01:18.000Z
tests/pipe_proc_tests/mult.py
genematx/nmrglue
8a24cf6cbd18451e552fc0673b84c42d1dcb69a2
[ "BSD-3-Clause" ]
129
2015-01-13T04:58:56.000Z
2022-03-02T13:39:16.000Z
tests/pipe_proc_tests/mult.py
genematx/nmrglue
8a24cf6cbd18451e552fc0673b84c42d1dcb69a2
[ "BSD-3-Clause" ]
88
2015-02-16T20:04:12.000Z
2022-03-10T06:50:30.000Z
#! /usr/bin/env python """ tests for MULT function """ import nmrglue.fileio.pipe as pipe import nmrglue.process.pipe_proc as p d, a = pipe.read("time_complex.fid") d, a = p.mult(d, a, c=1.5, inv=True) pipe.write("mult1.glue", d, a, overwrite=True) d, a = pipe.read("time_complex.fid") d, a = p.mult(d, a, r=2.0, i=1....
28
48
0.650794
736e95c83a2a60a2227e38b85b5b7a6ddd467fce
26,356
py
Python
src/nfvo/osm/osm_r2.py
shield-h2020/nfvo
1226f3d4824d1e39dd1e986ae541820e0ac9c422
[ "Apache-2.0" ]
null
null
null
src/nfvo/osm/osm_r2.py
shield-h2020/nfvo
1226f3d4824d1e39dd1e986ae541820e0ac9c422
[ "Apache-2.0" ]
null
null
null
src/nfvo/osm/osm_r2.py
shield-h2020/nfvo
1226f3d4824d1e39dd1e986ae541820e0ac9c422
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Copyright 2017-present i2CAT # # 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 la...
42.1696
79
0.524055
736ea814591647613c8b67206e656b278b2ce23a
1,443
py
Python
tests/test_decode.py
fperrin/pyi-dunno
fa08fc382b8e5eacec5141e5900f0079f4140289
[ "MIT" ]
null
null
null
tests/test_decode.py
fperrin/pyi-dunno
fa08fc382b8e5eacec5141e5900f0079f4140289
[ "MIT" ]
null
null
null
tests/test_decode.py
fperrin/pyi-dunno
fa08fc382b8e5eacec5141e5900f0079f4140289
[ "MIT" ]
null
null
null
import i_dunno import ipaddress import pytest from random import randint def test_decode(): """Decode a form with known antecedent Note the last two bytes are UTF for U+00f0 whose binary representation has exactly 8 significant bits. >>> bin(ord(b'\xc3\xb0'.decode("utf-8"))) '0b11110000' """ ...
28.86
77
0.607762
736eb57a071129019eea2ea146ce9f7dea3cb245
2,671
py
Python
admin/__init__.py
Simple2B/cortex-backend
9cf6802b0eff9254875bcbe553517500ccfc9082
[ "MIT" ]
1
2021-10-17T13:28:51.000Z
2021-10-17T13:28:51.000Z
admin/__init__.py
Simple2B/cortex-backend
9cf6802b0eff9254875bcbe553517500ccfc9082
[ "MIT" ]
null
null
null
admin/__init__.py
Simple2B/cortex-backend
9cf6802b0eff9254875bcbe553517500ccfc9082
[ "MIT" ]
null
null
null
import os from flask import Flask from flask_sqlalchemy import SQLAlchemy from flask_login import LoginManager from flask_migrate import Migrate from flask_admin import Admin from flask_admin.contrib.sqla import ModelView from flask_mail import Mail from app.logger import log # instantiate extensions login_manager =...
26.979798
75
0.673905
736ee26d89ed6de205507136e3ffb66add0cf2d3
1,137
py
Python
diameter/node/Peer.py
netch80/i1dk-PythonDiameter
ddc6cf76269379105f260c2ecab2c6930d7f32cf
[ "Zlib" ]
null
null
null
diameter/node/Peer.py
netch80/i1dk-PythonDiameter
ddc6cf76269379105f260c2ecab2c6930d7f32cf
[ "Zlib" ]
null
null
null
diameter/node/Peer.py
netch80/i1dk-PythonDiameter
ddc6cf76269379105f260c2ecab2c6930d7f32cf
[ "Zlib" ]
null
null
null
from Capability import Capability class Peer: def __init__(self,host=None,port=None,socket_address=None,use_ericsson_host_ip_address_format=False): self.host = None self.port = 3868 self.secure = False self.capabilities = Capability() if host: self.host = host ...
31.583333
105
0.628848
736ef68d9eb9b5cd444cebdba3d34ef7919d4bbc
5,993
py
Python
notebooks/monte_carlo_dev/get_oil_type_atb.py
MIDOSS/analysis-rachael
c4a3082eca53b49e358e86a6e623a359ca6668be
[ "Apache-2.0" ]
null
null
null
notebooks/monte_carlo_dev/get_oil_type_atb.py
MIDOSS/analysis-rachael
c4a3082eca53b49e358e86a6e623a359ca6668be
[ "Apache-2.0" ]
3
2020-07-03T17:07:04.000Z
2020-07-07T16:09:53.000Z
notebooks/monte_carlo_dev/get_oil_type_atb.py
MIDOSS/analysis-rachael
c4a3082eca53b49e358e86a6e623a359ca6668be
[ "Apache-2.0" ]
null
null
null
import numpy import yaml import pathlib from monte_carlo_utils import get_oil_type_cargo from monte_carlo_utils import get_oil_type_cargo_generic_US #### Decision tree for allocating oil type to atb traffic # see google drawing [atb oil attribution](https://docs.google.com/drawings/d/1Aigd2wccnl6-pQVo4KLN0xq1is6poD9...
39.169935
128
0.563658
736f1a422178732ba85796a9cb0d10d3049ec150
681
py
Python
leetcode/easy/1029-Two_city_scheduling.py
shubhamoli/practice
5a24fdeb6e5f43b821ef0510fe3b343ddda18f22
[ "MIT" ]
1
2020-02-25T10:32:27.000Z
2020-02-25T10:32:27.000Z
leetcode/easy/1029-Two_city_scheduling.py
shubhamoli/practice
5a24fdeb6e5f43b821ef0510fe3b343ddda18f22
[ "MIT" ]
null
null
null
leetcode/easy/1029-Two_city_scheduling.py
shubhamoli/practice
5a24fdeb6e5f43b821ef0510fe3b343ddda18f22
[ "MIT" ]
null
null
null
""" Leetcode #1039 """ from typing import List class Solution: def twoCitySchedCost(self, costs: List[List[int]]) -> int: if not costs: return 0 tmp = sorted(costs, key=lambda x: x[0] - x[1]) N = len(tmp) total = 0 for i in range(N): if i < ...
20.029412
106
0.515419
736f4d9fb19ba30602793fc4f830d3a6b49d76cd
3,361
py
Python
vim_client/cli.py
jamescherti/vim-client
094f6f6818835c48991f4777478d9cb017525d0e
[ "MIT" ]
null
null
null
vim_client/cli.py
jamescherti/vim-client
094f6f6818835c48991f4777478d9cb017525d0e
[ "MIT" ]
null
null
null
vim_client/cli.py
jamescherti/vim-client
094f6f6818835c48991f4777478d9cb017525d0e
[ "MIT" ]
null
null
null
#!/usr/bin/env python # # Copyright (c) James Cherti # # Distributed under terms of the MIT license. # # 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 l...
30.279279
78
0.652484
736f5ab7ea73a51c0a7a79ef2b7c1084a4140d33
5,683
py
Python
apps/acoustics/1d/example2/setrun.py
geoflows/geoclaw-4.x
c8879d25405017b38392aa3b1ea422ff3e3604ea
[ "BSD-3-Clause" ]
7
2016-11-13T03:11:51.000Z
2021-09-07T18:59:48.000Z
apps/acoustics/1d/example2/setrun.py
che-wenchao/D-Claw
8ab5d971c9a7a7130e03a447a4b8642e292f4e88
[ "BSD-3-Clause" ]
11
2020-01-14T18:00:37.000Z
2022-03-29T14:25:24.000Z
apps/acoustics/1d/example2/setrun.py
che-wenchao/D-Claw
8ab5d971c9a7a7130e03a447a4b8642e292f4e88
[ "BSD-3-Clause" ]
6
2020-01-14T17:15:42.000Z
2021-12-03T17:28:44.000Z
""" Module to set up run time parameters for Clawpack. The values set in the function setrun are then written out to data files that will be read in by the Fortran code. """ import os from pyclaw import data #------------------------------ def setrun(claw_pkg='classic'): #------------------------------ ...
27.454106
79
0.541615
736f8dbfe925a787445dd9b994887aa99afa598e
25
py
Python
Constants/__init__.py
jwbrooks0/johnspythonlibrary2
10ca519276d8c32da0fbd41a597f75c0c98a8736
[ "MIT" ]
null
null
null
Constants/__init__.py
jwbrooks0/johnspythonlibrary2
10ca519276d8c32da0fbd41a597f75c0c98a8736
[ "MIT" ]
null
null
null
Constants/__init__.py
jwbrooks0/johnspythonlibrary2
10ca519276d8c32da0fbd41a597f75c0c98a8736
[ "MIT" ]
null
null
null
from ._constants import *
25
25
0.8
736f9a17669613b216be7a2bbae048628de919f8
34,337
py
Python
examples/lm_finetuning/simple_lm_finetuning.py
JunsungSon/pytorch-transformers-OWE
e8e9ff6d176f69da4ace2f00fed8bf5ca007b00c
[ "Apache-2.0" ]
null
null
null
examples/lm_finetuning/simple_lm_finetuning.py
JunsungSon/pytorch-transformers-OWE
e8e9ff6d176f69da4ace2f00fed8bf5ca007b00c
[ "Apache-2.0" ]
1
2021-06-02T00:39:10.000Z
2021-06-02T00:39:10.000Z
examples/lm_finetuning/simple_lm_finetuning.py
JunsungSon/pytorch-transformers-OWE
e8e9ff6d176f69da4ace2f00fed8bf5ca007b00c
[ "Apache-2.0" ]
null
null
null
# 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...
44.535668
159
0.592917
736fa980f0651d5e1b367f45aca871afdc563035
659
py
Python
tests/test_core/test_utils.py
insolite/wsappy
8713fdf32ec42fc2aa9feea56f4f808a198fcfa5
[ "MIT" ]
1
2017-11-30T04:06:44.000Z
2017-11-30T04:06:44.000Z
tests/test_core/test_utils.py
insolite/wsappy
8713fdf32ec42fc2aa9feea56f4f808a198fcfa5
[ "MIT" ]
null
null
null
tests/test_core/test_utils.py
insolite/wsappy
8713fdf32ec42fc2aa9feea56f4f808a198fcfa5
[ "MIT" ]
null
null
null
import asyncio from unittest.mock import MagicMock from asynctest.mock import CoroutineMock from wsappy.core.utils import handler_method, HANDLER_FLAG from tests.common import WsAppyTest class UtilsTest(WsAppyTest): def test_handler_method(self): result = MagicMock() method = CoroutineMock(retu...
28.652174
69
0.719272
736fb1c1412592db7c0fc6c1326d1c749b562e63
6,020
py
Python
contacts/views/person.py
ubiquitousthey/django-contacts
f3a1653a39e619eed0d9cf9ebd5b7e30054c11d4
[ "BSD-3-Clause" ]
50
2015-02-03T09:40:31.000Z
2021-08-30T12:21:18.000Z
contacts/views/person.py
ubiquitousthey/django-contacts
f3a1653a39e619eed0d9cf9ebd5b7e30054c11d4
[ "BSD-3-Clause" ]
8
2016-02-13T14:06:00.000Z
2019-03-15T20:01:40.000Z
contacts/views/person.py
ubiquitousthey/django-contacts
f3a1653a39e619eed0d9cf9ebd5b7e30054c11d4
[ "BSD-3-Clause" ]
38
2015-04-25T19:49:54.000Z
2021-07-07T02:28:38.000Z
from django.core.paginator import Paginator, InvalidPage, EmptyPage from django.core.urlresolvers import reverse from django.http import (Http404, HttpResponseForbidden, HttpResponseServerError, HttpResponseRedirect) from django.shortcuts import render_to_response from django.template import Re...
33.444444
80
0.668272
736fd714d4b28ac798c1116cc72b42fa83602874
1,475
py
Python
google-cloud-sdk/.install/.backup/lib/googlecloudsdk/command_lib/compute/networks/flags.py
KaranToor/MA450
c98b58aeb0994e011df960163541e9379ae7ea06
[ "Apache-2.0" ]
1
2017-11-29T18:52:27.000Z
2017-11-29T18:52:27.000Z
google-cloud-sdk/.install/.backup/lib/googlecloudsdk/command_lib/compute/networks/flags.py
KaranToor/MA450
c98b58aeb0994e011df960163541e9379ae7ea06
[ "Apache-2.0" ]
null
null
null
google-cloud-sdk/.install/.backup/lib/googlecloudsdk/command_lib/compute/networks/flags.py
KaranToor/MA450
c98b58aeb0994e011df960163541e9379ae7ea06
[ "Apache-2.0" ]
1
2020-07-25T12:09:01.000Z
2020-07-25T12:09:01.000Z
# Copyright 2016 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ag...
35.119048
74
0.71322
736fde1012a31a82caba91a91f6621fdd0c10a32
395
py
Python
src/pocimport/pocimport/wsgi.py
wbar/poc-import
a54b8549db8b1eb29a46d50913bee0829da2fe1e
[ "MIT" ]
null
null
null
src/pocimport/pocimport/wsgi.py
wbar/poc-import
a54b8549db8b1eb29a46d50913bee0829da2fe1e
[ "MIT" ]
null
null
null
src/pocimport/pocimport/wsgi.py
wbar/poc-import
a54b8549db8b1eb29a46d50913bee0829da2fe1e
[ "MIT" ]
null
null
null
""" WSGI config for pocimport project. It exposes the WSGI callable as a module-level variable named ``application``. For more information on this file, see https://docs.djangoproject.com/en/1.8/howto/deployment/wsgi/ """ import os from django.core.wsgi import get_wsgi_application os.environ.setdefault("DJANGO_SET...
23.235294
78
0.787342
736ff00c3ad3f0277cffa4de1a58e0e66d5c6a50
1,389
py
Python
oscar/lib/python2.7/site-packages/django_tables2/columns/emailcolumn.py
sainjusajan/django-oscar
466e8edc807be689b0a28c9e525c8323cc48b8e1
[ "BSD-3-Clause" ]
null
null
null
oscar/lib/python2.7/site-packages/django_tables2/columns/emailcolumn.py
sainjusajan/django-oscar
466e8edc807be689b0a28c9e525c8323cc48b8e1
[ "BSD-3-Clause" ]
null
null
null
oscar/lib/python2.7/site-packages/django_tables2/columns/emailcolumn.py
sainjusajan/django-oscar
466e8edc807be689b0a28c9e525c8323cc48b8e1
[ "BSD-3-Clause" ]
null
null
null
# coding: utf-8 from __future__ import absolute_import, unicode_literals from django.db import models from django_tables2.templatetags.django_tables2 import title from .base import library from .linkcolumn import BaseLinkColumn @library.register class EmailColumn(BaseLinkColumn): ''' Render e...
28.346939
78
0.602592
73701d260ac673b4fa6bc186b64519c1fdfbba4f
12,020
py
Python
avanthive/presto.py
amount/PyHive
be525f1ab500916bd1b04de6aed6e1505db4f3d8
[ "Apache-2.0" ]
null
null
null
avanthive/presto.py
amount/PyHive
be525f1ab500916bd1b04de6aed6e1505db4f3d8
[ "Apache-2.0" ]
null
null
null
avanthive/presto.py
amount/PyHive
be525f1ab500916bd1b04de6aed6e1505db4f3d8
[ "Apache-2.0" ]
null
null
null
"""DB-API implementation backed by Presto See http://www.python.org/dev/peps/pep-0249/ Many docstrings in this file are based on the PEP, which is in the public domain. """ from __future__ import absolute_import from __future__ import unicode_literals from builtins import object from avanthive import common from av...
38.15873
106
0.641181
73703619de470f15c2ddc19934dcbc3b67a2191c
4,587
py
Python
consLogotest.py
suliat16/consScore
c3104e26e665bcccb42f982fbb686bbdbca90f16
[ "MIT" ]
3
2018-10-04T18:45:40.000Z
2022-01-19T14:42:14.000Z
consLogotest.py
suliat16/consScore
c3104e26e665bcccb42f982fbb686bbdbca90f16
[ "MIT" ]
5
2018-10-04T11:45:03.000Z
2018-10-09T14:16:06.000Z
consLogotest.py
suliat16/consScore
c3104e26e665bcccb42f982fbb686bbdbca90f16
[ "MIT" ]
1
2018-10-04T11:17:45.000Z
2018-10-04T11:17:45.000Z
""" Tests for the consLogo script """ import consLogo import os import biskit.test from requests import exceptions from unittest.mock import patch class ConsLogoTest(biskit.test.BiskitTest): """Test suite for the Conservation score logo generator""" TAGS = [biskit.test.NORMAL, biskit.test.LONG, biskit.test.E...
44.970588
119
0.690211
73704f35d918d22af448323ff4ce8fdc311268f2
7,666
py
Python
eventsourcing/infrastructure/iterators.py
alexanderlarin/eventsourcing
6f2a4ded3c783ba3ee465243a48f66ecdee20f52
[ "BSD-3-Clause" ]
null
null
null
eventsourcing/infrastructure/iterators.py
alexanderlarin/eventsourcing
6f2a4ded3c783ba3ee465243a48f66ecdee20f52
[ "BSD-3-Clause" ]
null
null
null
eventsourcing/infrastructure/iterators.py
alexanderlarin/eventsourcing
6f2a4ded3c783ba3ee465243a48f66ecdee20f52
[ "BSD-3-Clause" ]
null
null
null
from abc import ABC, abstractmethod from threading import Thread from eventsourcing.infrastructure.base import AbstractSequencedItemRecordManager class AbstractSequencedItemIterator(ABC): DEFAULT_PAGE_SIZE = 1000 def __init__(self, record_manager, sequence_id, page_size=None, gt=None, gte=None, lt=None, lte...
32.483051
112
0.569789
7370777f62de79c241e87d29f873f33c98997220
7,733
py
Python
experiments/shikhar/corl2019/mulitobj_cvae/cvae.py
Asap7772/railrl_evalsawyer
baba8ce634d32a48c7dfe4dc03b123e18e96e0a3
[ "MIT" ]
null
null
null
experiments/shikhar/corl2019/mulitobj_cvae/cvae.py
Asap7772/railrl_evalsawyer
baba8ce634d32a48c7dfe4dc03b123e18e96e0a3
[ "MIT" ]
null
null
null
experiments/shikhar/corl2019/mulitobj_cvae/cvae.py
Asap7772/railrl_evalsawyer
baba8ce634d32a48c7dfe4dc03b123e18e96e0a3
[ "MIT" ]
null
null
null
import rlkit.misc.hyperparameter as hyp from experiments.murtaza.multiworld.skew_fit.reacher.generate_uniform_dataset import generate_uniform_dataset_reacher from multiworld.envs.mujoco.cameras import sawyer_init_camera_zoomed_in from rlkit.launchers.launcher_util import run_experiment from rlkit.torch.grill.launcher i...
38.665
121
0.57093
7370788058427280bdfa73d6d41338265191f909
738
py
Python
src/test/tinc/sbin/tincmm.py
rodel-talampas/gpdb
9c955e350334abbd922102f289f782697eb52069
[ "PostgreSQL", "Apache-2.0" ]
9
2018-04-20T03:31:01.000Z
2020-05-13T14:10:53.000Z
src/test/tinc/sbin/tincmm.py
rodel-talampas/gpdb
9c955e350334abbd922102f289f782697eb52069
[ "PostgreSQL", "Apache-2.0" ]
36
2017-09-21T09:12:27.000Z
2020-06-17T16:40:48.000Z
src/test/tinc/sbin/tincmm.py
rodel-talampas/gpdb
9c955e350334abbd922102f289f782697eb52069
[ "PostgreSQL", "Apache-2.0" ]
32
2017-08-31T12:50:52.000Z
2022-03-01T07:34:53.000Z
#! /usr/bin/env python """ Copyright (c) 2004-Present Pivotal Software, Inc. This program and the accompanying materials are made available under the terms of the 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 Licens...
32.086957
72
0.788618
73708372781ff713758996d118f1d15c5744b072
916
py
Python
setup.py
richjoyce/stader
24811178026fe057a51c279ec99e79aae733659f
[ "BSD-3-Clause" ]
null
null
null
setup.py
richjoyce/stader
24811178026fe057a51c279ec99e79aae733659f
[ "BSD-3-Clause" ]
null
null
null
setup.py
richjoyce/stader
24811178026fe057a51c279ec99e79aae733659f
[ "BSD-3-Clause" ]
null
null
null
from setuptools import setup, find_packages with open('README.rst') as f: readme = f.read() setup( name='stader', version='0.0.1', description='stability derivatives for aircraft package', long_description=readme, author='Richard Joyce', author_email='rjoyce@ucdavis.edu', url='https:/...
32.714286
66
0.582969
7370c1f3ffbe41a8f97a9498f610edf55cc853f5
376
py
Python
Common/StockMarketIndex/Yahoo/SnP.py
enriqueescobar-askida/Kinito.Finance
5308748b64829ac798a858161f9b4a9e5829db44
[ "MIT" ]
2
2020-03-04T11:18:38.000Z
2020-05-10T15:36:42.000Z
Common/StockMarketIndex/Yahoo/SnP.py
enriqueescobar-askida/Kinito.Finance
5308748b64829ac798a858161f9b4a9e5829db44
[ "MIT" ]
6
2020-03-30T16:42:47.000Z
2021-12-13T20:37:21.000Z
Common/StockMarketIndex/Yahoo/SnP.py
enriqueescobar-askida/Kinito.Finance
5308748b64829ac798a858161f9b4a9e5829db44
[ "MIT" ]
1
2020-04-14T11:26:16.000Z
2020-04-14T11:26:16.000Z
from Common.StockType.Funds.ExchangeTraded.ExchangeTradedFund import ExchangeTradedFund class SnP(ExchangeTradedFund): ShortName: str LongName: str Ticker: str CapType: str Size: int def __init__(self): self.LongName = 'S&P 500' self.ShortName = 'S&P' self.Ticker = '^G...
22.117647
87
0.635638
7370c5bdd6ab7ef372816c834fe75f27fa481b72
444
py
Python
libs/strings.py
Jxiang2/EasyShop-V2
19db3c828c3a72a8b3e7118db1e18d8b94c54624
[ "MIT" ]
null
null
null
libs/strings.py
Jxiang2/EasyShop-V2
19db3c828c3a72a8b3e7118db1e18d8b94c54624
[ "MIT" ]
null
null
null
libs/strings.py
Jxiang2/EasyShop-V2
19db3c828c3a72a8b3e7118db1e18d8b94c54624
[ "MIT" ]
null
null
null
""" lib.strings By Default, uses 'en-us.json' file inside the 'strings top-level folder """ import json default_locale = "en-us" cached_strings = {} def refresh(): global cached_strings with open(f"strings/{default_locale}.json") as f: cached_strings = json.load(f) def gettext(name): re...
17.76
71
0.695946
7370e5b694e0a8b642b504df5956df6f8b54cf93
7,968
py
Python
src/clients/python/examples/simple_http_shm_client.py
areche/triton-inference-server
98469161f8e8acd513af7c0dc12dabb7f033f76b
[ "BSD-3-Clause" ]
1
2021-04-27T18:42:40.000Z
2021-04-27T18:42:40.000Z
src/clients/python/examples/simple_http_shm_client.py
dhanainme/triton-inference-server
880db08b8a3a54caa51ae76387cdcea303807faf
[ "BSD-3-Clause" ]
null
null
null
src/clients/python/examples/simple_http_shm_client.py
dhanainme/triton-inference-server
880db08b8a3a54caa51ae76387cdcea303807faf
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python # Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # * Redistributions of source code must retain the above copyright # notice, thi...
45.272727
81
0.625753
7371244301b3036a451b522d4ed6b45b6de8412a
9,996
py
Python
config/settings.py
MTES-MCT/sparte
3b8ae6d21da81ca761d64ae9dfe2c8f54487211c
[ "MIT" ]
null
null
null
config/settings.py
MTES-MCT/sparte
3b8ae6d21da81ca761d64ae9dfe2c8f54487211c
[ "MIT" ]
3
2022-02-10T11:47:58.000Z
2022-02-23T18:50:24.000Z
config/settings.py
MTES-MCT/sparte
3b8ae6d21da81ca761d64ae9dfe2c8f54487211c
[ "MIT" ]
null
null
null
""" Django settings for config project. Generated by 'django-admin startproject' using Django 3.2.5. For more information on this file, see https://docs.djangoproject.com/en/3.2/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/3.2/ref/settings/ hello world """ im...
27.61326
92
0.678571
73717ef377ba8e46a9ea75f5985d7ac828bec1ae
8,685
py
Python
models/seq_activity_firespread/model.py
MISTCARRYYOU/PythonPDEVS
53cad29832b3c489ab037bdc487affcbf1e3f408
[ "Apache-2.0" ]
1
2018-09-19T14:42:28.000Z
2018-09-19T14:42:28.000Z
models/seq_activity_firespread/model.py
MISTCARRYYOU/PythonPDEVS
53cad29832b3c489ab037bdc487affcbf1e3f408
[ "Apache-2.0" ]
null
null
null
models/seq_activity_firespread/model.py
MISTCARRYYOU/PythonPDEVS
53cad29832b3c489ab037bdc487affcbf1e3f408
[ "Apache-2.0" ]
1
2021-01-14T12:21:35.000Z
2021-01-14T12:21:35.000Z
import sys sys.path.append('../../src/') from infinity import * from DEVS import AtomicDEVS, CoupledDEVS from math import exp T_AMBIENT = 27.0 T_IGNITE = 300.0 T_GENERATE = 500.0 T_BURNED = 60.0 TIMESTEP = 0.01 PH_INACTIVE = 'inactive' PH_UNBURNED = 'unburned' PH_BURNING = 'burning' PH_BURNED = 'burned' RADIUS = 3 TM...
34.879518
264
0.575705
73719645b4bfef49bd53f8f1d15246ee341053b3
21,373
py
Python
spacepackets/cfdp/tlv.py
robamu-org/py-spacepackets
522b021ba5690f97a4b74ae8b110762a32eb9b19
[ "Apache-2.0" ]
null
null
null
spacepackets/cfdp/tlv.py
robamu-org/py-spacepackets
522b021ba5690f97a4b74ae8b110762a32eb9b19
[ "Apache-2.0" ]
3
2021-10-05T09:29:45.000Z
2022-02-12T15:46:43.000Z
spacepackets/cfdp/tlv.py
robamu-org/py-spacepackets
522b021ba5690f97a4b74ae8b110762a32eb9b19
[ "Apache-2.0" ]
1
2022-03-04T17:25:29.000Z
2022-03-04T17:25:29.000Z
from __future__ import annotations from typing import Tuple, Optional, TypeVar, Type, Union, List import enum from spacepackets.log import get_console_logger from spacepackets.cfdp.lv import CfdpLv from spacepackets.cfdp.definitions import ConditionCode, FaultHandlerCodes class TlvTypes(enum.IntEnum): """All avai...
38.302867
97
0.690872
7371a9b9a298178d5bc7cd9bbf9c18104746eba6
4,557
py
Python
pollination_sdk/models/local_config.py
pollination/python-sdk
599e8dbfc6e547c5e18aa903b27c70d7ffef84e5
[ "RSA-MD" ]
2
2020-01-30T23:28:59.000Z
2020-05-06T16:43:47.000Z
pollination_sdk/models/local_config.py
pollination/python-sdk
599e8dbfc6e547c5e18aa903b27c70d7ffef84e5
[ "RSA-MD" ]
1
2020-10-02T18:00:25.000Z
2020-10-02T18:00:25.000Z
pollination_sdk/models/local_config.py
pollination/python-sdk
599e8dbfc6e547c5e18aa903b27c70d7ffef84e5
[ "RSA-MD" ]
null
null
null
# coding: utf-8 """ pollination-server Pollination Server OpenAPI Definition # noqa: E501 The version of the OpenAPI document: 0.16.0 Contact: info@pollination.cloud Generated by: https://openapi-generator.tech """ import pprint import re # noqa: F401 import six from pollination_sdk.configu...
29.784314
135
0.590081
7371b006f2f39761e0aa1d3f9a6a847942702de8
700
py
Python
tests/conftest.py
gitter-badger/SoCo
65977466057748ea522a6d8b7f2a649091485a07
[ "MIT" ]
1
2019-03-09T14:23:48.000Z
2019-03-09T14:23:48.000Z
tests/conftest.py
gitter-badger/SoCo
65977466057748ea522a6d8b7f2a649091485a07
[ "MIT" ]
null
null
null
tests/conftest.py
gitter-badger/SoCo
65977466057748ea522a6d8b7f2a649091485a07
[ "MIT" ]
null
null
null
"""py.test hooks. Add the --ip command line option, and skip all tests marked the with 'integration' marker unless the option is included """ import pytest def pytest_addoption(parser): """ Add the --ip commandline option """ parser.addoption( '--ip', type=str, default=None, a...
28
79
0.652857