hexsha
stringlengths
40
40
size
int64
5
2.06M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
3
248
max_stars_repo_name
stringlengths
5
125
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
3
248
max_issues_repo_name
stringlengths
5
125
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
3
248
max_forks_repo_name
stringlengths
5
125
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
5
2.06M
avg_line_length
float64
1
1.02M
max_line_length
int64
3
1.03M
alphanum_fraction
float64
0
1
count_classes
int64
0
1.6M
score_classes
float64
0
1
count_generators
int64
0
651k
score_generators
float64
0
1
count_decorators
int64
0
990k
score_decorators
float64
0
1
count_async_functions
int64
0
235k
score_async_functions
float64
0
1
count_documentation
int64
0
1.04M
score_documentation
float64
0
1
2fef0f20d9583beaad642d2b113a19d757ae987a
36,252
py
Python
ai_pomdp_agent.py
Grottoh/Deep-Active-Inference-for-Partially-Observable-MDPs
11fedf09cefaada3dd60f1af430d59d87cbd706e
[ "MIT" ]
8
2020-09-17T06:48:33.000Z
2022-01-08T16:51:20.000Z
ai_pomdp_agent.py
pl-robotdecision/Deep-Active-Inference-for-Partially-Observable-MDPs
11fedf09cefaada3dd60f1af430d59d87cbd706e
[ "MIT" ]
null
null
null
ai_pomdp_agent.py
pl-robotdecision/Deep-Active-Inference-for-Partially-Observable-MDPs
11fedf09cefaada3dd60f1af430d59d87cbd706e
[ "MIT" ]
1
2021-01-13T12:23:35.000Z
2021-01-13T12:23:35.000Z
__author__ = "Otto van der Himst" __credits__ = "Otto van der Himst, Pablo Lanillos" __version__ = "1.0" __email__ = "o.vanderhimst@student.ru.nl" import torch import torch.nn as nn import torch.nn.functional as F import torch.optim as optim import numpy as np import datetime import sys import gym import ...
50.702098
232
0.594698
35,731
0.985628
0
0
0
0
0
0
8,724
0.240649
2fefb9f1bc9de1b69287eaed8f707942f874fa69
2,465
py
Python
src/BribeNet/bribery/temporal/action/briberyAction.py
RobMurray98/BribeNet
09ddd8f15d9ab5fac44ae516ed92c6ba5e5119bc
[ "MIT" ]
null
null
null
src/BribeNet/bribery/temporal/action/briberyAction.py
RobMurray98/BribeNet
09ddd8f15d9ab5fac44ae516ed92c6ba5e5119bc
[ "MIT" ]
null
null
null
src/BribeNet/bribery/temporal/action/briberyAction.py
RobMurray98/BribeNet
09ddd8f15d9ab5fac44ae516ed92c6ba5e5119bc
[ "MIT" ]
null
null
null
from abc import ABC, abstractmethod from typing import List from BribeNet.helpers.bribeNetException import BribeNetException class BriberyActionExecutedMultipleTimesException(BribeNetException): pass class BriberyActionTimeNotCorrectException(BribeNetException): pass class BriberyAction(ABC): def __...
34.71831
119
0.669371
2,330
0.945233
0
0
568
0.230426
0
0
754
0.305882
2fefd6e5e58e9aad34db52d1d9799e3ab83c554a
4,269
py
Python
jax_md/quantity.py
niklasschmitz/jax-md
5702b9a852d990ff1f7bae87bf06842734df1a90
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
jax_md/quantity.py
niklasschmitz/jax-md
5702b9a852d990ff1f7bae87bf06842734df1a90
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
jax_md/quantity.py
niklasschmitz/jax-md
5702b9a852d990ff1f7bae87bf06842734df1a90
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
# Copyright 2019 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/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
29.441379
79
0.69829
268
0.062778
0
0
0
0
0
0
1,550
0.363083
2fefd9d669adc52d9fc25135e72257c4fc66d661
9,748
py
Python
nsfiu/support/Python/Micronix.py
TobiasSchof/KPIC
619ea31d9705c0168220d79f5d2f6f70535ca416
[ "Unlicense" ]
null
null
null
nsfiu/support/Python/Micronix.py
TobiasSchof/KPIC
619ea31d9705c0168220d79f5d2f6f70535ca416
[ "Unlicense" ]
null
null
null
nsfiu/support/Python/Micronix.py
TobiasSchof/KPIC
619ea31d9705c0168220d79f5d2f6f70535ca416
[ "Unlicense" ]
null
null
null
from serial import Serial from time import sleep from telnetlib import Telnet from logging import debug class TimeoutError(Exception): """An error to be thrown for a movement timeout""" pass # TODO: Can I check which axis are connected in open_x? class Micronix_Device(): """Class for controlling Micronex...
31.856209
91
0.572733
9,584
0.983176
0
0
0
0
0
0
5,257
0.53929
2feff27c4691f93b27ecb59a4c2ab20267c11251
7,151
py
Python
storops_test/lib/test_version.py
tunaruraul/storops
7092c516c55b4c2f00c7c22383e1ad46ecfec091
[ "Apache-2.0" ]
60
2016-04-18T23:42:10.000Z
2022-03-23T02:26:03.000Z
storops_test/lib/test_version.py
tunaruraul/storops
7092c516c55b4c2f00c7c22383e1ad46ecfec091
[ "Apache-2.0" ]
317
2016-05-25T06:45:37.000Z
2022-03-25T13:22:38.000Z
storops_test/lib/test_version.py
tunaruraul/storops
7092c516c55b4c2f00c7c22383e1ad46ecfec091
[ "Apache-2.0" ]
34
2016-03-18T02:39:12.000Z
2022-01-07T12:54:14.000Z
import functools from unittest import TestCase import ddt from hamcrest import assert_that, equal_to, raises from storops.exception import SystemAPINotSupported from storops.lib.resource import Resource from storops.lib.version import version, Criteria from storops_test.unity.rest_mock import t_rest, patch_rest from ...
32.652968
77
0.602014
6,739
0.942386
0
0
5,209
0.72843
0
0
938
0.13117
2ff20fd15245634531744ee562835b4c0d1a75be
2,251
py
Python
tests/test_pipeline_wgbs_index.py
Multiscale-Genomics/mg-process-fastq
50c7115c0c1a6af48dc34f275e469d1b9eb02999
[ "Apache-2.0" ]
2
2017-07-31T11:45:46.000Z
2017-08-09T09:32:35.000Z
tests/test_pipeline_wgbs_index.py
Multiscale-Genomics/mg-process-fastq
50c7115c0c1a6af48dc34f275e469d1b9eb02999
[ "Apache-2.0" ]
28
2016-11-17T11:12:32.000Z
2018-11-02T14:09:13.000Z
tests/test_pipeline_wgbs_index.py
Multiscale-Genomics/mg-process-fastq
50c7115c0c1a6af48dc34f275e469d1b9eb02999
[ "Apache-2.0" ]
4
2017-02-12T17:47:21.000Z
2018-05-29T08:16:27.000Z
""" .. See the NOTICE file distributed with this work for additional information regarding copyright ownership. 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....
30.418919
100
0.67259
0
0
0
0
1,403
0.623279
0
0
1,162
0.516215
2ff388db8366ea8591858ff099655cca6fbb8662
7,625
py
Python
finance_manager/functions.py
jehboyes/finance_manager
d310a3a4c2c6b6e5564e2a83e3f355b23266b773
[ "MIT" ]
null
null
null
finance_manager/functions.py
jehboyes/finance_manager
d310a3a4c2c6b6e5564e2a83e3f355b23266b773
[ "MIT" ]
null
null
null
finance_manager/functions.py
jehboyes/finance_manager
d310a3a4c2c6b6e5564e2a83e3f355b23266b773
[ "MIT" ]
null
null
null
""" A collection of generic functions and iterators intended for use in various parts of the App, and will probably be of use to future development. """ from importlib import import_module as imp from os import listdir, path import sys import functools import click class periods(): """ Iterator for financia...
26.943463
107
0.557902
710
0.093115
0
0
0
0
0
0
4,303
0.564328
2ff4614b2c2823a60726232798f4f0d9f9766030
5,157
py
Python
tests/test_openml.py
carefree0910/carefree-learn-benchmark
d5507c1719e0b625230e3befc23149a96e057d14
[ "MIT" ]
null
null
null
tests/test_openml.py
carefree0910/carefree-learn-benchmark
d5507c1719e0b625230e3befc23149a96e057d14
[ "MIT" ]
null
null
null
tests/test_openml.py
carefree0910/carefree-learn-benchmark
d5507c1719e0b625230e3befc23149a96e057d14
[ "MIT" ]
null
null
null
import os import cflearn import platform import unittest import numpy as np from typing import Dict from cflearn_benchmark import Benchmark from scipy.sparse import csr_matrix from cftool.ml import patterns_type from cftool.ml import Tracker from cftool.ml import Comparer from cftool.misc import timestamp from cfdata...
38.774436
90
0.587745
4,483
0.869304
0
0
0
0
0
0
364
0.070584
2ff575594cb4f67394b6f254007e19ef1d93f244
352
py
Python
aws_ips/utils.py
thepawn1/aws_ips
a708f6a59e94544ffd8e8c9f03885b340a370d13
[ "Apache-2.0" ]
null
null
null
aws_ips/utils.py
thepawn1/aws_ips
a708f6a59e94544ffd8e8c9f03885b340a370d13
[ "Apache-2.0" ]
null
null
null
aws_ips/utils.py
thepawn1/aws_ips
a708f6a59e94544ffd8e8c9f03885b340a370d13
[ "Apache-2.0" ]
1
2020-06-21T06:12:20.000Z
2020-06-21T06:12:20.000Z
""" Various utils """ import json import socket def jprint(anything): """ pprint() alternative """ print(json.dumps(anything, default=str, sort_keys=True, indent=4)) def resolve_host(hostname): """ Resolve hostname """ try: return socket.gethostbyname(hostname) except soc...
15.304348
70
0.625
0
0
0
0
0
0
0
0
91
0.258523
2ff591dd882602db2d4555a4dfd235c125da3f56
90
py
Python
character/bonds/bond.py
chrisbrake/PythonSandbox
8cd2ea847676d6a300b55c560f49cd980f760b00
[ "BSD-3-Clause" ]
1
2018-10-19T17:35:01.000Z
2018-10-19T17:35:01.000Z
character/bonds/bond.py
chrisbrake/PythonSandbox
8cd2ea847676d6a300b55c560f49cd980f760b00
[ "BSD-3-Clause" ]
null
null
null
character/bonds/bond.py
chrisbrake/PythonSandbox
8cd2ea847676d6a300b55c560f49cd980f760b00
[ "BSD-3-Clause" ]
null
null
null
class BaseBond(object): def __init__(self): super(BaseBond, self).__init__()
18
40
0.655556
89
0.988889
0
0
0
0
0
0
0
0
2ff8aa8452d3785af93c4d934bd42e377d0cab4b
6,117
py
Python
final/predict.py
terrifyzhao/information_extract
d950c25911f5a8d9f7e10eb9ecfd53f897cef8d0
[ "Apache-2.0" ]
null
null
null
final/predict.py
terrifyzhao/information_extract
d950c25911f5a8d9f7e10eb9ecfd53f897cef8d0
[ "Apache-2.0" ]
null
null
null
final/predict.py
terrifyzhao/information_extract
d950c25911f5a8d9f7e10eb9ecfd53f897cef8d0
[ "Apache-2.0" ]
null
null
null
import json from final.model import model import os import numpy as np import tensorflow as tf import jieba from tqdm import tqdm import ahocorasick from gensim.models import Word2Vec os.environ["KMP_DUPLICATE_LIB_OK"] = "TRUE" path = os.getcwd() graph = tf.get_default_graph() train_data = json.load(open(path + '/dat...
32.194737
102
0.541605
1,238
0.200616
0
0
0
0
0
0
470
0.076163
2ff8c1d733f52e6e0c92e54a6bb944e263727097
16,976
py
Python
agent/state/model.py
abiro/minerl-agent
c33361c4a5ad0d5fe903f211665ff4da16439b69
[ "MIT" ]
null
null
null
agent/state/model.py
abiro/minerl-agent
c33361c4a5ad0d5fe903f211665ff4da16439b69
[ "MIT" ]
null
null
null
agent/state/model.py
abiro/minerl-agent
c33361c4a5ad0d5fe903f211665ff4da16439b69
[ "MIT" ]
null
null
null
import os from collections import defaultdict import logging from operator import itemgetter from pathlib import Path from typing import List, Optional, Tuple, Dict, Iterable, Iterator import time import numpy as np import torch as T import torch.nn as nn import torch.nn.functional as F import torch.optim as optim fro...
33.615842
79
0.568332
16,334
0.962182
582
0.034284
1,474
0.086828
0
0
2,809
0.165469
2ffa363e2ef05730e61cd94e52d180a5b70ce996
236
py
Python
gobigger/utils/__init__.py
luanshaotong/GoBigger
00c347a89a660134677d633f39c39123c5ab3deb
[ "Apache-2.0" ]
189
2021-10-08T07:55:10.000Z
2022-03-31T23:49:43.000Z
gobigger/utils/__init__.py
luanshaotong/GoBigger
00c347a89a660134677d633f39c39123c5ab3deb
[ "Apache-2.0" ]
25
2021-11-01T06:59:30.000Z
2022-03-22T11:22:27.000Z
gobigger/utils/__init__.py
luanshaotong/GoBigger
00c347a89a660134677d633f39c39123c5ab3deb
[ "Apache-2.0" ]
28
2021-10-14T12:23:14.000Z
2022-03-31T23:49:45.000Z
from .structures import format_vector, add_size, save_screen_data_to_img, Border, QuadNode from .collision_detection import create_collision_detection from .config_utils import deep_merge_dicts from .tool import * from .colors import *
39.333333
90
0.851695
0
0
0
0
0
0
0
0
0
0
2ffd633c035e5b8a5c7381b18155f86b65f423e0
295
py
Python
common/common/utils/uuid.py
ravirahman/sancus
6563852b98edeb1068574e2d99e1fc18b815bee3
[ "MIT" ]
2
2022-03-17T04:50:20.000Z
2022-03-17T04:51:31.000Z
common/common/utils/uuid.py
ravirahman/sancus
6563852b98edeb1068574e2d99e1fc18b815bee3
[ "MIT" ]
null
null
null
common/common/utils/uuid.py
ravirahman/sancus
6563852b98edeb1068574e2d99e1fc18b815bee3
[ "MIT" ]
null
null
null
import uuid def generate_uuid4() -> uuid.UUID: return _generate_uuid4() def _generate_uuid4() -> uuid.UUID: # Defined as a private method for easy monkeypatching return uuid.uuid4() def bytes_to_uuid(data: bytes) -> uuid.UUID: return uuid.UUID(bytes=data.rjust(16, b"\0"))
19.666667
57
0.698305
0
0
0
0
0
0
0
0
58
0.19661
2ffe22f93b98651c83789010c629f07c9626d409
475
py
Python
src/maximize_product_of_array.py
marco-zangari/code-katas
1dfda1cfbbe8687b17e97e414358b38d964df675
[ "MIT" ]
null
null
null
src/maximize_product_of_array.py
marco-zangari/code-katas
1dfda1cfbbe8687b17e97e414358b38d964df675
[ "MIT" ]
null
null
null
src/maximize_product_of_array.py
marco-zangari/code-katas
1dfda1cfbbe8687b17e97e414358b38d964df675
[ "MIT" ]
null
null
null
"""Maximize_product_of_arry(array series#2), Codewars Kata, level 7.""" def max_product(li, n): """Return maxima(not maximum) product from a list from the set number. input: list of integers output: integer, product of given integers ex: maxProduct ({4,3,5} , 2) returns return 20 since the s...
26.388889
74
0.631579
0
0
0
0
0
0
0
0
333
0.701053
2fffeecfd74fb3b321b898239e5f0a7ba37a7a1d
52
py
Python
keras/optimizers/schedules/__init__.py
ikingye/keras
1a3ee8441933fc007be6b2beb47af67998d50737
[ "MIT" ]
5
2020-11-30T22:26:03.000Z
2020-12-01T22:34:25.000Z
keras/optimizers/schedules/__init__.py
ikingye/keras
1a3ee8441933fc007be6b2beb47af67998d50737
[ "MIT" ]
10
2020-12-01T22:55:29.000Z
2020-12-11T18:31:46.000Z
keras/optimizers/schedules/__init__.py
ikingye/keras
1a3ee8441933fc007be6b2beb47af67998d50737
[ "MIT" ]
15
2020-11-30T22:12:22.000Z
2020-12-09T01:32:48.000Z
from tensorflow.keras.optimizers.schedules import *
26
51
0.846154
0
0
0
0
0
0
0
0
0
0
64013de2423b6eda7583c7954f2421b985fdc3cf
1,874
py
Python
src/ch6-routing/start/pypi_routing/pypi/controllers/packages_controller.py
bkraft4257/data-driven-web-apps-with-pyramid-and-sqlalchemy
4943eb3d13c0df3c1b371efafb04e5ca41d97254
[ "MIT" ]
null
null
null
src/ch6-routing/start/pypi_routing/pypi/controllers/packages_controller.py
bkraft4257/data-driven-web-apps-with-pyramid-and-sqlalchemy
4943eb3d13c0df3c1b371efafb04e5ca41d97254
[ "MIT" ]
null
null
null
src/ch6-routing/start/pypi_routing/pypi/controllers/packages_controller.py
bkraft4257/data-driven-web-apps-with-pyramid-and-sqlalchemy
4943eb3d13c0df3c1b371efafb04e5ca41d97254
[ "MIT" ]
null
null
null
from pyramid.view import view_config from pyramid.request import Request import pyramid.httpexceptions as x # /project/{package_name}/ @view_config(route_name='package_details', renderer='pypi:templates/packages/details.pt') @view_config(route_name='package_details/', renderer='pypi:template...
28.830769
60
0.680363
0
0
0
0
1,586
0.846318
0
0
651
0.347385
64019954b6c9d169557d681eddbbc7a7c34584de
1,043
py
Python
key_gen.py
hamatz/efppap
5e1ea01e8436c30547db5805649cc64d16016e1a
[ "Apache-2.0" ]
1
2020-03-16T04:12:46.000Z
2020-03-16T04:12:46.000Z
key_gen.py
hamatz/efppap
5e1ea01e8436c30547db5805649cc64d16016e1a
[ "Apache-2.0" ]
null
null
null
key_gen.py
hamatz/efppap
5e1ea01e8436c30547db5805649cc64d16016e1a
[ "Apache-2.0" ]
null
null
null
import Crypto import Crypto.Random from Crypto.PublicKey import RSA from Crypto.Signature import PKCS1_v1_5 from Crypto.Hash import SHA256 import binascii import sys def main(my_pass): random_gen = Crypto.Random.new().read _private_key = RSA.generate(2048, random_gen) _public_key = _private_key.publickey(...
24.833333
69
0.676894
0
0
0
0
0
0
0
0
157
0.146866
64020b4bfa2cce6cea0b7b429c38432043eb9e81
115
py
Python
npypacke/regression/tests/__init__.py
phetdam/npy_openblas_demo
ff5f9932b19f82162bc0d9d46b341d42805f942b
[ "MIT" ]
1
2021-10-16T00:59:11.000Z
2021-10-16T00:59:11.000Z
npypacke/regression/tests/__init__.py
phetdam/numpy-lapacke-demo
ff5f9932b19f82162bc0d9d46b341d42805f942b
[ "MIT" ]
null
null
null
npypacke/regression/tests/__init__.py
phetdam/numpy-lapacke-demo
ff5f9932b19f82162bc0d9d46b341d42805f942b
[ "MIT" ]
null
null
null
"""Unit test subpackage for numpy-lapacke-demo.regression. .. codeauthor:: Derek Huang <djh458@stern.nyu.edu> """
28.75
59
0.730435
0
0
0
0
0
0
0
0
115
1
6402d35f820b27a9431ba5e1113030c41f480c56
2,515
py
Python
Lecture Codes/Lecture 3 notebooks/dsLecture3.py
h0han/SE274_2020_spring
a699e1d7e7bbc7cc2035b3748eea039b9a95d634
[ "MIT" ]
null
null
null
Lecture Codes/Lecture 3 notebooks/dsLecture3.py
h0han/SE274_2020_spring
a699e1d7e7bbc7cc2035b3748eea039b9a95d634
[ "MIT" ]
null
null
null
Lecture Codes/Lecture 3 notebooks/dsLecture3.py
h0han/SE274_2020_spring
a699e1d7e7bbc7cc2035b3748eea039b9a95d634
[ "MIT" ]
null
null
null
class EmptyException(Exception): """Raised when the input value is too large""" pass class ArrayStack: # Space used: O(n) def __init__(self): self._data = [] # O(1) def __len__(self): return len(self._data) # O(1) def is_empty(self): return len(self._data) == 0 # O(1...
27.944444
82
0.551491
2,510
0.998012
0
0
0
0
0
0
406
0.161431
640609535538c486602ef8f06a0b9836a7e3f787
40
py
Python
src/arcresthelper/_abstract/__init__.py
Bmcalpine/ArcREST
c437612abcaada2ef3d393a89009f8b65ea9732b
[ "Apache-2.0" ]
null
null
null
src/arcresthelper/_abstract/__init__.py
Bmcalpine/ArcREST
c437612abcaada2ef3d393a89009f8b65ea9732b
[ "Apache-2.0" ]
null
null
null
src/arcresthelper/_abstract/__init__.py
Bmcalpine/ArcREST
c437612abcaada2ef3d393a89009f8b65ea9732b
[ "Apache-2.0" ]
null
null
null
import abstract __version__ = "2.1.100"
13.333333
23
0.75
0
0
0
0
0
0
0
0
9
0.225
6406120a79bb00b6afca248985fb442df2597681
206
py
Python
ch3/multiple.sequences.while.py
ldmcdaniel/learning_python
63717c397cd75e45a8aef909d4b601466cd6036a
[ "MIT" ]
30
2016-10-28T18:14:15.000Z
2021-08-29T15:20:56.000Z
ch3/multiple.sequences.while.py
ldmcdaniel/learning_python
63717c397cd75e45a8aef909d4b601466cd6036a
[ "MIT" ]
null
null
null
ch3/multiple.sequences.while.py
ldmcdaniel/learning_python
63717c397cd75e45a8aef909d4b601466cd6036a
[ "MIT" ]
31
2016-09-10T22:47:12.000Z
2022-03-13T04:50:35.000Z
people = ['Jonas', 'Julio', 'Mike', 'Mez'] ages = [25, 30, 31, 39] position = 0 while position < len(people): person = people[position] age = ages[position] print(person, age) position += 1
22.888889
42
0.601942
0
0
0
0
0
0
0
0
25
0.121359
64081c37d1ca537a55d057ce8e0fe32c837b442b
74
py
Python
tests/type/bad/function-bad-return.py
Nakrez/RePy
057db55a99eac2c5cb3d622fa1f2e29f6083d8d6
[ "MIT" ]
1
2020-11-24T05:24:26.000Z
2020-11-24T05:24:26.000Z
tests/type/bad/function-bad-return.py
Nakrez/RePy
057db55a99eac2c5cb3d622fa1f2e29f6083d8d6
[ "MIT" ]
null
null
null
tests/type/bad/function-bad-return.py
Nakrez/RePy
057db55a99eac2c5cb3d622fa1f2e29f6083d8d6
[ "MIT" ]
null
null
null
def fun(x): if x > 1: return 0 else: return "str"
12.333333
20
0.418919
0
0
0
0
0
0
0
0
5
0.067568
640a14d0405eaeebc1bec3e73813a8225fe552d4
13,215
py
Python
generate-grammars/grammar_to_ply.py
mbaak/histogrammar-python
6311f5b0eec9c75f12018f22604535c64675fdf6
[ "Apache-2.0" ]
30
2016-09-25T16:36:06.000Z
2021-07-20T09:09:09.000Z
generate-grammars/grammar_to_ply.py
mbaak/histogrammar-python
6311f5b0eec9c75f12018f22604535c64675fdf6
[ "Apache-2.0" ]
15
2016-07-26T19:41:31.000Z
2021-02-07T16:30:11.000Z
generate-grammars/grammar_to_ply.py
mbaak/histogrammar-python
6311f5b0eec9c75f12018f22604535c64675fdf6
[ "Apache-2.0" ]
8
2016-09-19T20:48:37.000Z
2021-02-07T15:00:24.000Z
#!/usr/bin/env python # Written by Andrew Dalke # Copyright (c) 2008 by Dalke Scientific, AB # Modified by Jim Pivarski, 2016 # # (This is the MIT License with the serial numbers scratched off and my # name written in in crayon. I would prefer "share and enjoy" but # apparently that isn't a legally acceptable.) # #...
29.432071
193
0.583882
1,142
0.086417
1,035
0.07832
0
0
0
0
6,512
0.492773
640af0aa12d484396d4c73ccee7e916d7e9d9211
1,870
py
Python
Django_Rest_Framework/api/entidades/vaga.py
Drack112/Treina-Web-Django
555ecce1c351769240eefd4340b63e547f3bd2a9
[ "MIT" ]
null
null
null
Django_Rest_Framework/api/entidades/vaga.py
Drack112/Treina-Web-Django
555ecce1c351769240eefd4340b63e547f3bd2a9
[ "MIT" ]
null
null
null
Django_Rest_Framework/api/entidades/vaga.py
Drack112/Treina-Web-Django
555ecce1c351769240eefd4340b63e547f3bd2a9
[ "MIT" ]
null
null
null
class Vaga: def __init__( self, titulo, descricao, salario, local, quantidade, contato, tipo_contratacao, tecnologias, ): self.__titulo = titulo self.__descricao = descricao self.__descricao = descricao self....
21.744186
50
0.627807
1,869
0.999465
0
0
1,241
0.663636
0
0
0
0
640e4ff0b52e56376f75a16db48899141b55b809
169
py
Python
triad/utils/__init__.py
kvnkho/triad
371a5e84945b2203f1108598b8e67136414589a3
[ "Apache-2.0" ]
6
2020-10-04T23:01:33.000Z
2021-11-08T11:46:39.000Z
triad/utils/__init__.py
kvnkho/triad
371a5e84945b2203f1108598b8e67136414589a3
[ "Apache-2.0" ]
16
2020-09-28T21:58:08.000Z
2021-12-29T07:09:03.000Z
triad/utils/__init__.py
kvnkho/triad
371a5e84945b2203f1108598b8e67136414589a3
[ "Apache-2.0" ]
1
2020-10-10T20:36:43.000Z
2020-10-10T20:36:43.000Z
# flake8: noqa from triad.utils.assertion import assert_arg_not_none, assert_or_throw from triad.utils.hash import to_uuid from triad.utils.iter import make_empty_aware
33.8
70
0.852071
0
0
0
0
0
0
0
0
14
0.08284
640e5f2dbc283de85c337ecaac27efdeff2ecfa4
352
py
Python
file_open.py
farhan1503001/Data-structures-with-python-Coursera
04c04fea15f96b83056d846a8cc59f94d9df66ca
[ "MIT" ]
null
null
null
file_open.py
farhan1503001/Data-structures-with-python-Coursera
04c04fea15f96b83056d846a8cc59f94d9df66ca
[ "MIT" ]
null
null
null
file_open.py
farhan1503001/Data-structures-with-python-Coursera
04c04fea15f96b83056d846a8cc59f94d9df66ca
[ "MIT" ]
null
null
null
#Opening file filename=open('words.txt') for line in filename: print(line.upper().rstrip()) filename.close() second_file=open('mbox.txt') sum=0 count=0 for line in second_file: if line.startswith("X-DSPAM-Confidence:"): sum=sum+float(line[-7:-1]) count=count+1 print("Average sp...
20.705882
47
0.644886
0
0
0
0
0
0
0
0
82
0.232955
640fe67a8c0974d5bd49edced52848028ecff445
401
py
Python
bau_evaluations.py
cebe01/baupy
e75f877ef3749023fc7ea1c2585f7b2e1c8ec461
[ "Apache-2.0" ]
null
null
null
bau_evaluations.py
cebe01/baupy
e75f877ef3749023fc7ea1c2585f7b2e1c8ec461
[ "Apache-2.0" ]
null
null
null
bau_evaluations.py
cebe01/baupy
e75f877ef3749023fc7ea1c2585f7b2e1c8ec461
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Fri Aug 28 15:27:21 2020 @author: Cb """ import numpy as np import pandas as pd import baupy as bp # #%% path = 'C:/Users/CB.MAGMA/Documents/GitHub/baupy/kennwerte.xlsx'# r'/home/cb/Dokumente/GitHub/baupy/kennwerte_streichholzstrasse.txt' container = bp.kennwerte(...
16.04
133
0.710723
0
0
0
0
0
0
0
0
236
0.588529
64103b78b35c825d3b872412c51c638e6905c754
425
py
Python
lang/py/pylib/code/string/string_template_missing.py
ch1huizong/learning
632267634a9fd84a5f5116de09ff1e2681a6cc85
[ "MIT" ]
1
2022-01-29T08:32:11.000Z
2022-01-29T08:32:11.000Z
lang/py/pylib/code/string/string_template_missing.py
ch1huizong/learning
632267634a9fd84a5f5116de09ff1e2681a6cc85
[ "MIT" ]
null
null
null
lang/py/pylib/code/string/string_template_missing.py
ch1huizong/learning
632267634a9fd84a5f5116de09ff1e2681a6cc85
[ "MIT" ]
1
2022-01-29T08:32:12.000Z
2022-01-29T08:32:12.000Z
#!/usr/bin/env python # encoding: utf-8 # # Copyright (c) 2008 Doug Hellmann All rights reserved. # """ """ __version__ = "$Id$" #end_pymotw_header import string values = { 'var':'foo' } t = string.Template("$var is here but $missing is not provided") try: print 'substitute() :', t.substitute(values) excep...
17.708333
64
0.661176
0
0
0
0
0
0
0
0
227
0.534118
6412681b7d33190c888fe2ca81f843fbabb8f1f4
79
py
Python
app/me/apps.py
GiorgosXonikis/Social_Media-RestAPI
4d54c18b296ebf52773093a5bedcfabec9404438
[ "MIT" ]
null
null
null
app/me/apps.py
GiorgosXonikis/Social_Media-RestAPI
4d54c18b296ebf52773093a5bedcfabec9404438
[ "MIT" ]
null
null
null
app/me/apps.py
GiorgosXonikis/Social_Media-RestAPI
4d54c18b296ebf52773093a5bedcfabec9404438
[ "MIT" ]
null
null
null
from django.apps import AppConfig class MeConfig(AppConfig): name = 'me'
13.166667
33
0.721519
42
0.531646
0
0
0
0
0
0
4
0.050633
6412c114e0148cac74c8016e5dd9e4636887e532
2,196
py
Python
authentik/root/asgi.py
BeryJu/passbook
350f0d836580f4411524614f361a76c4f27b8a2d
[ "MIT" ]
15
2020-01-05T09:09:57.000Z
2020-11-28T05:27:39.000Z
authentik/root/asgi.py
BeryJu/passbook
350f0d836580f4411524614f361a76c4f27b8a2d
[ "MIT" ]
302
2020-01-21T08:03:59.000Z
2020-12-04T05:04:57.000Z
authentik/root/asgi.py
BeryJu/passbook
350f0d836580f4411524614f361a76c4f27b8a2d
[ "MIT" ]
3
2020-03-04T08:21:59.000Z
2020-08-01T20:37:18.000Z
""" ASGI config for authentik project. It exposes the ASGI callable as a module-level variable named ``application``. For more information on this file, see https://docs.djangoproject.com/en/3.0/howto/deployment/asgi/ """ import django from channels.routing import ProtocolTypeRouter, URLRouter from defusedxml import ...
30.929577
93
0.652095
1,294
0.589253
0
0
0
0
775
0.352914
894
0.407104
6412f72910f9d2b8e997d384ba6143ae4869f3af
4,922
py
Python
pysaintcoinach/ex/variant2/__init__.py
icykoneko/saintcoinach-py
66898385e1198203a7ec9da83787427bf6fe5c83
[ "MIT" ]
7
2019-11-20T17:24:49.000Z
2022-03-29T04:17:53.000Z
pysaintcoinach/ex/variant2/__init__.py
icykoneko/saintcoinach-py
66898385e1198203a7ec9da83787427bf6fe5c83
[ "MIT" ]
7
2019-04-08T07:36:46.000Z
2022-01-17T22:51:54.000Z
pysaintcoinach/ex/variant2/__init__.py
icykoneko/saintcoinach-py
66898385e1198203a7ec9da83787427bf6fe5c83
[ "MIT" ]
3
2019-04-08T08:24:22.000Z
2021-06-27T22:19:15.000Z
from struct import unpack_from from typing import Iterable as IterableT, TypeVar, Union, Dict from ..datasheet import DataRowBase, IDataSheet, IDataRow from ..column import Column from ..relational import IRelationalDataRow from ..relational.datasheet import IRelationalDataSheet class SubRow(DataRowBase, IRelational...
32.596026
111
0.645266
4,632
0.941081
0
0
1,099
0.223283
0
0
262
0.05323
641310d10a8d7e15c9a7d898de0f6cdccc1b0fc5
9,874
py
Python
wurst/ecoinvent/electricity_markets.py
pjamesjoyce/wurst
95b37e72eaa18b33bdd83cd4a51d37d9eb4ae7ba
[ "BSD-2-Clause" ]
1
2022-03-29T14:59:13.000Z
2022-03-29T14:59:13.000Z
wurst/ecoinvent/electricity_markets.py
pjamesjoyce/wurst
95b37e72eaa18b33bdd83cd4a51d37d9eb4ae7ba
[ "BSD-2-Clause" ]
null
null
null
wurst/ecoinvent/electricity_markets.py
pjamesjoyce/wurst
95b37e72eaa18b33bdd83cd4a51d37d9eb4ae7ba
[ "BSD-2-Clause" ]
null
null
null
from .. import toolz from ..searching import get_many, equals from ..transformations import rescale_exchange from functools import partial def get_generators_in_mix(db, name="market for electricity, high voltage"): """Get names of inputs to electricity mixes""" inputs = set() for act in db: if act...
51.427083
213
0.708021
0
0
0
0
0
0
0
0
6,287
0.636658
6418b3422f4c2568aa263e251a1ee434a2dfc461
634
py
Python
examples/render/render_sphere.py
jkjt/ezdxf
2acc5611b81476ea16b98063b9f55446a9182b81
[ "MIT" ]
515
2017-01-25T05:46:52.000Z
2022-03-29T09:52:27.000Z
examples/render/render_sphere.py
jkjt/ezdxf
2acc5611b81476ea16b98063b9f55446a9182b81
[ "MIT" ]
417
2017-01-25T10:01:17.000Z
2022-03-29T09:22:04.000Z
examples/render/render_sphere.py
jkjt/ezdxf
2acc5611b81476ea16b98063b9f55446a9182b81
[ "MIT" ]
149
2017-02-01T15:52:02.000Z
2022-03-17T10:33:38.000Z
# Copyright (c) 2020-2021, Manfred Moitzi # License: MIT License from pathlib import Path import ezdxf from ezdxf.render.forms import sphere DIR = Path("~/Desktop/Outbox").expanduser() doc = ezdxf.new() doc.layers.new("form", dxfattribs={"color": 5}) doc.layers.new("csg", dxfattribs={"color": 1}) doc.layers.new("no...
25.36
60
0.716088
0
0
0
0
0
0
0
0
163
0.257098
64193ff79c04af71d979ce5a5fceac0954ce5460
12,595
py
Python
tests/test_api.py
bcyran/philipstv
6037724d5fab0b72265c2de2c0441a64f6e00c00
[ "MIT" ]
null
null
null
tests/test_api.py
bcyran/philipstv
6037724d5fab0b72265c2de2c0441a64f6e00c00
[ "MIT" ]
null
null
null
tests/test_api.py
bcyran/philipstv
6037724d5fab0b72265c2de2c0441a64f6e00c00
[ "MIT" ]
null
null
null
from typing import Any, Type import pytest from philipstv import ( PhilipsTVAPI, PhilipsTVAPIMalformedResponseError, PhilipsTVAPIUnauthorizedError, PhilipsTVError, ) from philipstv.model import ( AllChannels, AmbilightColor, AmbilightLayer, AmbilightMode, AmbilightModeValue, Am...
28.560091
98
0.553394
0
0
0
0
1,865
0.148075
0
0
2,531
0.200953
641a91dbdedae51a3e67ba706dca460ad4205d27
169
py
Python
metrics/admin.py
tp00012x/bobs_banana_stand
0ae167b1bb124408770924dcb3660760da2d715c
[ "MIT" ]
null
null
null
metrics/admin.py
tp00012x/bobs_banana_stand
0ae167b1bb124408770924dcb3660760da2d715c
[ "MIT" ]
6
2021-03-18T22:01:48.000Z
2022-02-10T07:19:13.000Z
metrics/admin.py
tp00012x/bobs_banana_stand
0ae167b1bb124408770924dcb3660760da2d715c
[ "MIT" ]
null
null
null
from django.contrib import admin from metrics.models import InventoryProduct class InventoryAdmin(admin.ModelAdmin): pass admin.site.register(InventoryProduct)
15.363636
43
0.816568
48
0.284024
0
0
0
0
0
0
0
0
641bb66e30f87d492340ad814a4e968e438c0fa6
1,277
py
Python
dags/rockflow/dags/logo.py
asdf-zxcv/airflow-dags
033511deaaf07a662b30d35fd86ae866115baa28
[ "Unlicense" ]
null
null
null
dags/rockflow/dags/logo.py
asdf-zxcv/airflow-dags
033511deaaf07a662b30d35fd86ae866115baa28
[ "Unlicense" ]
null
null
null
dags/rockflow/dags/logo.py
asdf-zxcv/airflow-dags
033511deaaf07a662b30d35fd86ae866115baa28
[ "Unlicense" ]
null
null
null
from airflow.models import DAG from rockflow.dags.const import * from rockflow.dags.symbol import MERGE_CSV_KEY from rockflow.operators.logo import * with DAG("public_logo_download", default_args=DEFAULT_DEBUG_ARGS) as public: PublicLogoBatchOperator( from_key=MERGE_CSV_KEY, key=public.dag_id, ...
30.404762
88
0.729052
0
0
0
0
0
0
0
0
98
0.076742
641bc418f4c4dc36c2dc0b6d80a85e1d6643d581
1,651
py
Python
mvmm/single_view/opt_diagnostics.py
idc9/mvmm
64fce755a7cd53be9b08278484c7a4c77daf38d1
[ "MIT" ]
1
2021-08-17T13:22:54.000Z
2021-08-17T13:22:54.000Z
mvmm/single_view/opt_diagnostics.py
idc9/mvmm
64fce755a7cd53be9b08278484c7a4c77daf38d1
[ "MIT" ]
null
null
null
mvmm/single_view/opt_diagnostics.py
idc9/mvmm
64fce755a7cd53be9b08278484c7a4c77daf38d1
[ "MIT" ]
null
null
null
import matplotlib.pyplot as plt # from copy import deepcopy import numpy as np from mvmm.viz_utils import set_xaxis_int_ticks def plot_opt_hist(loss_vals, init_loss_vals=None, loss_name='loss value', title='', step_vals=None, inches=10): loss_val_diffs = np.diff(loss_vals) ...
27.065574
79
0.616596
0
0
0
0
0
0
0
0
308
0.186554
641d1843e490f1c82ee27a3b382c287be94e5ece
2,537
py
Python
webdriver/smoke.py
iamdoubz/webwormhole
a38b8f42debdf19808982d0777c130ea8d6f5815
[ "BSD-3-Clause" ]
1,647
2020-04-29T05:14:38.000Z
2022-03-31T01:19:43.000Z
webdriver/smoke.py
iamdoubz/webwormhole
a38b8f42debdf19808982d0777c130ea8d6f5815
[ "BSD-3-Clause" ]
76
2020-04-29T06:15:30.000Z
2022-03-22T21:20:28.000Z
webdriver/smoke.py
saljam/cpace-machine
0dcba5cf52a943a69340fa7243bbe092cbbc207a
[ "BSD-3-Clause" ]
87
2020-04-29T21:15:26.000Z
2022-03-17T03:50:19.000Z
# a hacky smoke test that sends a file from one chrome window to another. # docker build -t ww-selenium . # docker run --rm -it -v $PWD:$PWD -w $PWD ww-selenium python3 ./smoke.py # it isn't much but it's start. # TODO: # - use go package / go test # - run the server # - eventually smoke test *all* client com...
29.16092
84
0.736303
0
0
0
0
0
0
0
0
991
0.390465
641d5526aa245c11c77b4b77e01bc0c1c4e9e4c4
2,696
py
Python
shinyutils/matwrap.py
toddrme2178/shinyutils
c9459f93f76d0486da65a457ce1c2671c52bdc5b
[ "MIT" ]
null
null
null
shinyutils/matwrap.py
toddrme2178/shinyutils
c9459f93f76d0486da65a457ce1c2671c52bdc5b
[ "MIT" ]
null
null
null
shinyutils/matwrap.py
toddrme2178/shinyutils
c9459f93f76d0486da65a457ce1c2671c52bdc5b
[ "MIT" ]
null
null
null
"""matwrap.py: wrapper around matplotlib.""" import json import warnings from pkg_resources import resource_filename class MatWrap: _rc_defaults_path = resource_filename("shinyutils", "data/mplcfg.json") with open(_rc_defaults_path, "r") as f: _rc_defaults = json.load(f) _mpl = None _plt = N...
25.923077
79
0.556751
2,576
0.95549
0
0
2,173
0.806009
0
0
815
0.3023
641d97542f22ba65a623da3a27b56b49064773cb
649
py
Python
CCC/CCC '05 S1 - Snow Calls.py
Joon7891/Competitive-Programming
d860b7ad932cd5a6fb91fdc8c53101da57f4a408
[ "MIT" ]
2
2021-04-13T00:19:56.000Z
2021-04-13T01:19:45.000Z
CCC/CCC '05 S1 - Snow Calls.py
Joon7891/Competitive-Programming
d860b7ad932cd5a6fb91fdc8c53101da57f4a408
[ "MIT" ]
null
null
null
CCC/CCC '05 S1 - Snow Calls.py
Joon7891/Competitive-Programming
d860b7ad932cd5a6fb91fdc8c53101da57f4a408
[ "MIT" ]
1
2020-08-26T12:36:08.000Z
2020-08-26T12:36:08.000Z
keys_map = { 'A':'2', 'B':'2', 'C':'2', 'D':'3', 'E':'3', 'F':'3', 'G':'4', 'H':'4', 'I':'4', 'J':'5', 'K':'5', 'L':'5', 'M':'6', 'N':'6', 'O':'6', 'P':'7', 'Q':'7', 'R':'7', 'S':'7', 'T':'8', 'U':'8', 'V':'8', 'W':'9', 'X':'9', 'Y':'9', 'Z':'9', } n = int(input()) f...
15.452381
58
0.391371
0
0
0
0
0
0
0
0
172
0.265023
641dd088351667ee7ce3a62e35c4c5f3b6771754
3,078
py
Python
autotest/get_exes.py
MODFLOW-USGS/modflow6
6cc0f91b93e0615b68c9239c32cd5bff7f0696b9
[ "CC0-1.0" ]
102
2017-12-19T09:56:38.000Z
2022-03-30T01:47:28.000Z
autotest/get_exes.py
MODFLOW-USGS/modflow6
6cc0f91b93e0615b68c9239c32cd5bff7f0696b9
[ "CC0-1.0" ]
331
2018-01-10T21:22:48.000Z
2022-03-29T05:57:00.000Z
autotest/get_exes.py
MODFLOW-USGS/modflow6
6cc0f91b93e0615b68c9239c32cd5bff7f0696b9
[ "CC0-1.0" ]
87
2017-12-13T21:40:39.000Z
2022-03-30T05:31:40.000Z
# Get executables import os import shutil import pymake from framework import running_on_CI if running_on_CI(): print("running on CI environment") os.environ["PYMAKE_DOUBLE"] = "1" # paths to executables for previous versions of MODFLOW ebindir = os.path.abspath( os.path.join(os.path.expanduser("~"), "....
25.65
75
0.653996
0
0
0
0
0
0
0
0
963
0.312865
641f10073e3e2ac1d958d64840101d11760b2f66
236
py
Python
spopt/__init__.py
fiendskrah/spopt
b0f4b682f9246670241c415c4023fcb3e596c372
[ "BSD-3-Clause" ]
null
null
null
spopt/__init__.py
fiendskrah/spopt
b0f4b682f9246670241c415c4023fcb3e596c372
[ "BSD-3-Clause" ]
null
null
null
spopt/__init__.py
fiendskrah/spopt
b0f4b682f9246670241c415c4023fcb3e596c372
[ "BSD-3-Clause" ]
null
null
null
__version__ = "0.1.0" from .region import MaxPHeuristic from .region import RegionKMeansHeuristic from .region import Skater from .region import WardSpatial from .region import Spenc from .region import w_to_g from .region import AZP
21.454545
41
0.809322
0
0
0
0
0
0
0
0
7
0.029661
641ffda3aaa9896187418b645908b4cbd191a8de
949
py
Python
workflow/Strategy.py
YOCKOW/PythonGitHubActionsWorkflowRepresentation
1e8cb9fd4ade42b01f0c521f659c16b12d7957de
[ "MIT" ]
null
null
null
workflow/Strategy.py
YOCKOW/PythonGitHubActionsWorkflowRepresentation
1e8cb9fd4ade42b01f0c521f659c16b12d7957de
[ "MIT" ]
null
null
null
workflow/Strategy.py
YOCKOW/PythonGitHubActionsWorkflowRepresentation
1e8cb9fd4ade42b01f0c521f659c16b12d7957de
[ "MIT" ]
null
null
null
from .Node import Node from .BooleanNode import BooleanNode from .MappingNode import MappingNode from .Matrix import Matrix from .NumberNode import IntegerNode from typing import Any, Dict, List class Strategy(MappingNode): def __init__(self, info: Dict[str, Any]): assert isinstance(info, dict) converted: Di...
27.911765
69
0.646997
751
0.791359
0
0
121
0.127503
0
0
109
0.114858
642147f2d7a649b4cd903efa6b1d905ea393c7ca
4,216
py
Python
dbcron/validators.py
cloudspectatordevelopment/django-dbcron
53182ca803d1f5d8fd022a1cae79e0c0256bd25f
[ "BSD-3-Clause" ]
null
null
null
dbcron/validators.py
cloudspectatordevelopment/django-dbcron
53182ca803d1f5d8fd022a1cae79e0c0256bd25f
[ "BSD-3-Clause" ]
null
null
null
dbcron/validators.py
cloudspectatordevelopment/django-dbcron
53182ca803d1f5d8fd022a1cae79e0c0256bd25f
[ "BSD-3-Clause" ]
null
null
null
from django.core import validators from django.utils.translation import ugettext_lazy as _ from django.utils.deconstruct import deconstructible MONTH_MAP = { 'JAN': 1, 'FEB': 2, 'MAR': 3, 'APR': 4, 'MAY': 5, 'JUN': 6, 'JUL': 7, 'AUG': 8, 'SEP': 9, 'OCT': 10, 'NOV': 11, '...
27.376623
78
0.548387
3,734
0.885674
0
0
3,041
0.7213
0
0
336
0.079696
6421978a16090177ad88ec238394d851bbfb27bc
1,103
py
Python
micromagneticmodel/tests/test_rkky.py
ubermag/micromagneticmodel
91ad92d26cdbec369a5a41f7b90a17ca5328cd07
[ "BSD-3-Clause" ]
5
2019-10-21T01:12:16.000Z
2021-09-24T03:52:30.000Z
micromagneticmodel/tests/test_rkky.py
ubermag/micromagneticmodel
91ad92d26cdbec369a5a41f7b90a17ca5328cd07
[ "BSD-3-Clause" ]
11
2019-08-12T22:38:17.000Z
2022-03-15T00:08:47.000Z
micromagneticmodel/tests/test_rkky.py
ubermag/micromagneticmodel
91ad92d26cdbec369a5a41f7b90a17ca5328cd07
[ "BSD-3-Clause" ]
4
2020-06-27T15:36:28.000Z
2021-12-06T15:08:04.000Z
import re import pytest import numpy as np import discretisedfield as df import micromagneticmodel as mm from .checks import check_term class TestRKKY: def setup(self): self.valid_args = [(1, ['a', 'b']), (-1, ['a', 'bc']), (0, ['r1', 'r2'])] s...
32.441176
66
0.533998
964
0.87398
0
0
0
0
0
0
79
0.071623
6421c29517fd50762f06843cef09f1ed5fb8d24e
1,048
py
Python
tests/test_commands_status.py
ar90n/kkt
e772860b20231e067973478350a4f0edb8bf5db1
[ "Apache-2.0" ]
1
2020-09-03T08:19:46.000Z
2020-09-03T08:19:46.000Z
tests/test_commands_status.py
ar90n/kkt
e772860b20231e067973478350a4f0edb8bf5db1
[ "Apache-2.0" ]
null
null
null
tests/test_commands_status.py
ar90n/kkt
e772860b20231e067973478350a4f0edb8bf5db1
[ "Apache-2.0" ]
null
null
null
import pytest import kkt from kkt.exception import MetaDataNotFound from kkt.commands.status import status, status_impl @pytest.mark.parametrize( "given, expected", [ ( {"status": "complete", "failureMessage": None, "user": "user"}, "status: complete", ), ( ...
28.324324
80
0.607824
0
0
0
0
627
0.598282
0
0
320
0.305344
6425b466b0e6cf309b673b3dfca0d05f9849d1d2
3,813
py
Python
src/controllers/Database.py
UCHIC/ODMStreamingDataLoader
711886167a068754efff6dfbd604e3e19e545253
[ "BSD-3-Clause" ]
null
null
null
src/controllers/Database.py
UCHIC/ODMStreamingDataLoader
711886167a068754efff6dfbd604e3e19e545253
[ "BSD-3-Clause" ]
null
null
null
src/controllers/Database.py
UCHIC/ODMStreamingDataLoader
711886167a068754efff6dfbd604e3e19e545253
[ "BSD-3-Clause" ]
null
null
null
__author__ = 'Denver' import sys import logging from datetime import datetime # sys.path.append('/home/denver/Documents/ODM2PythonAPI') from odm2api.ODMconnection import dbconnection from odm2api.ODM2.services import * logger = logging.getLogger('SDL_logger') class Database: ''' This class uses the ...
31.512397
181
0.606609
3,540
0.928403
0
0
0
0
0
0
1,330
0.348807
6425be78a648f6351f256ea328387bb3f4129437
1,460
py
Python
examples/example_ros_anymal.py
TLasguignes/signal_scope
ad2690df9c7a5f1502c5e7807568b7f4050fcc10
[ "BSD-3-Clause" ]
2
2021-04-03T15:49:13.000Z
2021-06-01T08:07:11.000Z
examples/example_ros_anymal.py
TLasguignes/signal_scope
ad2690df9c7a5f1502c5e7807568b7f4050fcc10
[ "BSD-3-Clause" ]
1
2021-03-18T14:41:09.000Z
2021-03-18T21:10:05.000Z
examples/example_ros_anymal.py
TLasguignes/signal_scope
ad2690df9c7a5f1502c5e7807568b7f4050fcc10
[ "BSD-3-Clause" ]
1
2020-12-09T10:20:17.000Z
2020-12-09T10:20:17.000Z
''' A working example for signals from Anymal Plots x,y,z in position and the yaw angle ''' import numpy import sys sys.argv = ['test'] import tf def getYawDegrees(msg): '''yaw degrees''' quaternion = ( msg.pose.pose.orientation.x, msg.pose.pose.orientation.y, msg.pose.pose.orienta...
29.2
88
0.729452
0
0
0
0
0
0
0
0
348
0.238356
642625ac3b2c3acf82bc4a6e8e24c9530afa8666
1,366
py
Python
src/face_detect.py
train255/Silent-Face-Anti-Spoofing
e2137cde55ba4c7b43c2a7d6340d827a106b7404
[ "Apache-2.0" ]
null
null
null
src/face_detect.py
train255/Silent-Face-Anti-Spoofing
e2137cde55ba4c7b43c2a7d6340d827a106b7404
[ "Apache-2.0" ]
null
null
null
src/face_detect.py
train255/Silent-Face-Anti-Spoofing
e2137cde55ba4c7b43c2a7d6340d827a106b7404
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # @Time : 20-6-9 上午10:20 # @Author : zhuying # @Company : Minivision # @File : anti_spoof_predict.py # @Software : PyCharm import cv2 import math import numpy as np class FaceModel: def __init__(self): caffemodel = "./resources/detection_model/Widerface-RetinaFace.caffemodel" ...
40.176471
98
0.607613
1,175
0.857664
0
0
0
0
0
0
272
0.19854
6426a7aa1144603b703bbace9e0249804b2e5c54
1,160
py
Python
lab2/myutils/lab2_task1/checker.py
kinpa200296/python_labs
bb26c426cbe9bb27f45b8ee4c974c38db300468f
[ "MIT" ]
null
null
null
lab2/myutils/lab2_task1/checker.py
kinpa200296/python_labs
bb26c426cbe9bb27f45b8ee4c974c38db300468f
[ "MIT" ]
null
null
null
lab2/myutils/lab2_task1/checker.py
kinpa200296/python_labs
bb26c426cbe9bb27f45b8ee4c974c38db300468f
[ "MIT" ]
null
null
null
#!/usr/bin/env python import argparse __author__ = 'kinpa200296' def check_if_sorted(filename, ascending=True): with open(filename, 'r') as f: s = f.readline() if s == '': return True prev = int(s) s = f.readline() while s != '': cur = int(s) ...
24.166667
86
0.534483
0
0
0
0
0
0
0
0
243
0.209483
642774b4963705c8dd1baff49ac53f72d342febc
21,645
py
Python
ipvs.py
akamac/gnlpy
61abb4b6fda0b7c5e1e7810b3786b75d77cbaff8
[ "BSD-3-Clause" ]
176
2015-05-20T20:11:27.000Z
2020-08-24T11:39:49.000Z
ipvs.py
akamac/gnlpy
61abb4b6fda0b7c5e1e7810b3786b75d77cbaff8
[ "BSD-3-Clause" ]
22
2015-10-10T06:48:28.000Z
2020-07-24T13:12:05.000Z
ipvs.py
akamac/gnlpy
61abb4b6fda0b7c5e1e7810b3786b75d77cbaff8
[ "BSD-3-Clause" ]
46
2015-05-20T22:22:31.000Z
2020-07-24T17:29:31.000Z
# Copyright (c) 2015-present, Facebook, Inc. # All rights reserved. # # This source code is licensed under the BSD-style license found in the # LICENSE file in the root directory of this source tree. An additional grant # of patent rights can be found in the PATENTS file in the same directory. """IPVS module This mod...
32.30597
79
0.55611
16,046
0.741326
0
0
5,302
0.244953
0
0
3,238
0.149596
6427832947b865e474dcc63aff27da24ea97cbf2
810
py
Python
pynetdicom3/__init__.py
rdebroiz/pynetdicom3
0baea8310b9d3fd0a67df0c2e90f2607463f73c7
[ "MIT" ]
null
null
null
pynetdicom3/__init__.py
rdebroiz/pynetdicom3
0baea8310b9d3fd0a67df0c2e90f2607463f73c7
[ "MIT" ]
null
null
null
pynetdicom3/__init__.py
rdebroiz/pynetdicom3
0baea8310b9d3fd0a67df0c2e90f2607463f73c7
[ "MIT" ]
null
null
null
""" Set module shortcuts and globals """ version = ['0', '9', '1'] __version__ = '.'.join(version) pynetdicom_version = 'PYNETDICOM3_' + ''.join(version) # UID prefix provided by https://www.medicalconnections.co.uk/Free_UID pynetdicom_uid_prefix = '1.2.826.0.1.3680043.9.3811.' + '.'.join(version) import logging fro...
38.571429
76
0.818519
0
0
0
0
0
0
0
0
170
0.209877
642d621c0f5b8d6ce8cc22ca5eadd03e790a2df1
1,814
py
Python
src/architectures/gqn.py
ae-foster/cresp
0215842370d3d665133a496d6d971a537400c674
[ "MIT" ]
5
2021-11-15T22:49:47.000Z
2022-02-05T01:39:54.000Z
src/architectures/gqn.py
ae-foster/cresp
0215842370d3d665133a496d6d971a537400c674
[ "MIT" ]
null
null
null
src/architectures/gqn.py
ae-foster/cresp
0215842370d3d665133a496d6d971a537400c674
[ "MIT" ]
null
null
null
import torch from torch import nn from torch.nn import functional as F class GQN_Pool(nn.Module): def __init__(self, representation_dim, covariate_dim, net=None, **kwargs): assert representation_dim == 256 assert (isinstance(net, nn.Identity) or (net is None)) super(GQN_Pool, self).__init_...
36.28
92
0.597574
1,740
0.959206
0
0
0
0
0
0
139
0.076626
642d803688df88f4bfdeaaef4cc078fe36396c9e
622
py
Python
test/example/weather.py
lawsn/crawlingpy
d8737fb4964bf2492fbd91557cd6a152dd80889a
[ "Apache-2.0" ]
null
null
null
test/example/weather.py
lawsn/crawlingpy
d8737fb4964bf2492fbd91557cd6a152dd80889a
[ "Apache-2.0" ]
null
null
null
test/example/weather.py
lawsn/crawlingpy
d8737fb4964bf2492fbd91557cd6a152dd80889a
[ "Apache-2.0" ]
null
null
null
import requests from bs4 import BeautifulSoup url = 'https://weather.com/weather/tenday/l/' param = 'b757e0078b0b135DetailsSummary--tempValue--RcZzi0973ea8930d24ef111c7b8457939f4e2046fc8bbe48119f17' response = requests.get(url + param) print(response.text) soup = BeautifulSoup(response.text, 'html.parser') dateTime...
25.916667
106
0.766881
0
0
0
0
0
0
0
0
318
0.511254
642dcacaee4a8f97f5492f6645961bdd1c1df4eb
2,857
py
Python
CreateImages.py
AlJ95/VanPixel-CNN-approach
ce49af871d31211263ea0a14840ed3456b024e23
[ "CC0-1.0" ]
null
null
null
CreateImages.py
AlJ95/VanPixel-CNN-approach
ce49af871d31211263ea0a14840ed3456b024e23
[ "CC0-1.0" ]
null
null
null
CreateImages.py
AlJ95/VanPixel-CNN-approach
ce49af871d31211263ea0a14840ed3456b024e23
[ "CC0-1.0" ]
null
null
null
import random as r import cv2 import numpy as np from skimage.util import random_noise def create_figs(image, image_pre_result, no_of_objects=1): for i in range(no_of_objects): width = r.randint(0, image.shape[0] / 2) height = r.randint(0, image.shape[1] / 2) xpos = r.randint(0, ...
40.239437
74
0.500525
0
0
0
0
0
0
0
0
89
0.031152
642dd59683d2234e13b5d5f7591dbab7c437923f
3,697
py
Python
development/testing/_modules/auxiliary_scalability.py
boryana-ilieva/respy
c3f600eefbb54d4f34ae2cc1e52d4d32c03ba0dc
[ "MIT" ]
null
null
null
development/testing/_modules/auxiliary_scalability.py
boryana-ilieva/respy
c3f600eefbb54d4f34ae2cc1e52d4d32c03ba0dc
[ "MIT" ]
null
null
null
development/testing/_modules/auxiliary_scalability.py
boryana-ilieva/respy
c3f600eefbb54d4f34ae2cc1e52d4d32c03ba0dc
[ "MIT" ]
1
2020-10-31T19:40:22.000Z
2020-10-31T19:40:22.000Z
from datetime import datetime import datetime as dt import shlex import os from auxiliary_shared import strfdelta from config import SPEC_DIR import respy def get_actual_evaluations(): with open('est.respy.info', 'r') as infile: for line in infile.readlines(): list_ = shlex.split(line) ...
30.056911
80
0.614823
0
0
0
0
0
0
0
0
801
0.216662
642e25c2894b68733c612d1de87dbe97de5ee5c2
1,925
py
Python
src/main.py
idrissneumann/rpi_flow
561d9e7803bbe7212b84f092afed21f8bae1c3d6
[ "Apache-2.0" ]
null
null
null
src/main.py
idrissneumann/rpi_flow
561d9e7803bbe7212b84f092afed21f8bae1c3d6
[ "Apache-2.0" ]
null
null
null
src/main.py
idrissneumann/rpi_flow
561d9e7803bbe7212b84f092afed21f8bae1c3d6
[ "Apache-2.0" ]
null
null
null
import json import requests import sys from datetime import date from datetime import datetime from elasticsearch import Elasticsearch from time import sleep from veggie_utils import * from elastic_utils import es_connect with open('flow_conf.json') as json_file: conf = json.load(json_file) override_conf_from_en...
34.375
125
0.748052
0
0
0
0
0
0
0
0
462
0.24
6430502b11619ea1bdfdd8e1744178dab3548462
2,006
py
Python
src/app/database/model/Revisions.py
william920429/repair_system
27b5f4612a48a326943d23c2acce326070134228
[ "MIT" ]
1
2021-05-18T17:28:09.000Z
2021-05-18T17:28:09.000Z
src/app/database/model/Revisions.py
SiriusKoan/repair_system
6524e7a8d5954b6e16b34b9d88db9d455ef3dd1d
[ "MIT" ]
3
2021-05-02T06:00:47.000Z
2021-05-05T11:42:58.000Z
src/app/database/model/Revisions.py
SiriusKoan/repair_system
6524e7a8d5954b6e16b34b9d88db9d455ef3dd1d
[ "MIT" ]
3
2021-04-15T13:03:36.000Z
2021-05-06T03:13:59.000Z
import datetime from .common import db, timeformat class Revisions(db.Model): """ After the admin views the reports, they will make a revision record. The table is connected to `Records`, `Users` and `Statuses`. id: PK. record_id: `id` in `Records` table. user_id: `id` in `Users` table. s...
37.849057
145
0.664008
1,952
0.973081
0
0
421
0.20987
0
0
624
0.311067
6432e2af24456be3ab041cf5afca3a2790d37a5b
3,093
py
Python
libs/senseAll.py
WyattSP/Remote-Air-Quality-Station
908555591f6f9f183c68df01c6569171019e2246
[ "MIT" ]
null
null
null
libs/senseAll.py
WyattSP/Remote-Air-Quality-Station
908555591f6f9f183c68df01c6569171019e2246
[ "MIT" ]
null
null
null
libs/senseAll.py
WyattSP/Remote-Air-Quality-Station
908555591f6f9f183c68df01c6569171019e2246
[ "MIT" ]
null
null
null
from sds011sensor import * import aqi import time from datetime import datetime import argparse import os import csv import timeit from sense_hat import SenseHat #Initate arg parser my_parser = argparse.ArgumentParser(description='Input Parameters') #Create args my_parser.add_argument('-a', t...
24.164063
84
0.558358
0
0
0
0
0
0
0
0
454
0.146783
643504529c3cf23bc6fd859398bf2d84dc5211e8
4,373
py
Python
validation/cta-1dc/make.py
QRemy/gammapy-benchmarks
7f6170e88284958056fbdf468fb890787a13f153
[ "BSD-3-Clause" ]
null
null
null
validation/cta-1dc/make.py
QRemy/gammapy-benchmarks
7f6170e88284958056fbdf468fb890787a13f153
[ "BSD-3-Clause" ]
null
null
null
validation/cta-1dc/make.py
QRemy/gammapy-benchmarks
7f6170e88284958056fbdf468fb890787a13f153
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/env python """Run Gammapy validation: CTA 1DC""" import logging import yaml import matplotlib.pyplot as plt from gammapy.analysis import Analysis, AnalysisConfig def target_config3d(config_file, target_config_file, tag): """Create analyis configuration for out source.""" targets_config_ = yaml.safe_...
37.376068
87
0.661788
0
0
0
0
0
0
0
0
1,393
0.318546
6436d87792524f633d16459439c3e34419da5cfe
6,805
py
Python
blueprints/authentication.py
avirois/ProjectManagement
9e05d1302336ca4ef32bef93e28bcc69fdad7d4f
[ "WTFPL" ]
null
null
null
blueprints/authentication.py
avirois/ProjectManagement
9e05d1302336ca4ef32bef93e28bcc69fdad7d4f
[ "WTFPL" ]
3
2021-03-24T11:53:18.000Z
2021-04-05T10:20:58.000Z
blueprints/authentication.py
avirois/ProjectManagement
9e05d1302336ca4ef32bef93e28bcc69fdad7d4f
[ "WTFPL" ]
null
null
null
from flask import Blueprint, render_template, request, session, redirect, current_app, Markup, jsonify import sqlite3 import os from static.classes.User import User, encryptPassword, decryptPassword from cryptography.fernet import Fernet authentication_blueprint = Blueprint("authentication_blueprint", __name__, templa...
38.01676
149
0.57928
0
0
0
0
6,368
0.935783
0
0
2,320
0.340926
64376e8106131626dc32171ef1ab964eda092d64
6,487
py
Python
wrap/pyllbc/script/core/config/Property.py
zhouyanlt/llbc
a8cc4662401e9b077be7ee0058350b35fdd86060
[ "MIT" ]
null
null
null
wrap/pyllbc/script/core/config/Property.py
zhouyanlt/llbc
a8cc4662401e9b077be7ee0058350b35fdd86060
[ "MIT" ]
null
null
null
wrap/pyllbc/script/core/config/Property.py
zhouyanlt/llbc
a8cc4662401e9b077be7ee0058350b35fdd86060
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import llbc class pyllbcProperty(object): """ pyllbc property class encapsulation. property can read & write .cfg format file. file format: path.to.name = value # The comments path.to.anotherName = \#\#\# anotherValue \#\#\# # The comments too Property clas...
33.611399
98
0.612456
6,415
0.988901
0
0
0
0
0
0
3,378
0.520734
643cc63033fb1b3e849c2c4070ffb4a5b3005b89
2,944
py
Python
src/2-ner.py
nicole-dwenger/sermon-networks.dk
83c89506b32f4f8d972d8e11c0c186815d7ffad6
[ "MIT" ]
1
2020-12-21T03:51:25.000Z
2020-12-21T03:51:25.000Z
src/2-ner.py
nicole-dwenger/sermon-networks.dk
83c89506b32f4f8d972d8e11c0c186815d7ffad6
[ "MIT" ]
null
null
null
src/2-ner.py
nicole-dwenger/sermon-networks.dk
83c89506b32f4f8d972d8e11c0c186815d7ffad6
[ "MIT" ]
3
2021-04-16T11:45:47.000Z
2022-03-06T12:33:26.000Z
""" NER for sermons in content.dat """ import os import pandas as pd import numpy as np from polyglot.text import Text import nltk.data from nltk.stem.snowball import DanishStemmer stemmer = DanishStemmer() if __name__ == "__main__": """ First processing to create NER outputs """ df = pd.read_csv(os.pa...
33.83908
87
0.569973
0
0
0
0
0
0
0
0
919
0.31216
643e3d8e50c594d60d058cffa7941b77bbddb825
794
py
Python
katas/kata5.py
cesarau04/metodosnumericos
9670c91d5c659d2bfb1b95e85c437e6deed9ec28
[ "MIT" ]
null
null
null
katas/kata5.py
cesarau04/metodosnumericos
9670c91d5c659d2bfb1b95e85c437e6deed9ec28
[ "MIT" ]
null
null
null
katas/kata5.py
cesarau04/metodosnumericos
9670c91d5c659d2bfb1b95e85c437e6deed9ec28
[ "MIT" ]
null
null
null
""" Find the Minimum, Maximum, Length and Average Values Create a function that takes a list of numbers and returns the following statistics: Minimum Value Maximum Value Sequence Length Average Value """ def minMaxLengthAverage(lst): return [min(lst), max(lst), len(lst), sum(lst)/len(lst)] """ Return the Sum of ...
29.407407
140
0.738035
0
0
0
0
0
0
0
0
524
0.65995
643ebb9e00e5a46b9e13bfbe41b37466798f580a
2,994
py
Python
layers/dilated_convolution.py
giovgiac/neptune
a3cc256d3f3d833be2b8654131726ab48482f5e1
[ "MIT" ]
4
2021-03-06T10:00:43.000Z
2022-02-21T16:09:48.000Z
layers/dilated_convolution.py
giovgiac/neptune
a3cc256d3f3d833be2b8654131726ab48482f5e1
[ "MIT" ]
null
null
null
layers/dilated_convolution.py
giovgiac/neptune
a3cc256d3f3d833be2b8654131726ab48482f5e1
[ "MIT" ]
1
2020-12-21T14:50:26.000Z
2020-12-21T14:50:26.000Z
# dilated_convolution.py from __future__ import absolute_import from __future__ import division from __future__ import print_function from layers.normalization import InstanceNormalization from typing import Tuple, Union import tensorflow as tf class DilatedConv2D(tf.keras.layers.Layer): def __init__(self, fil...
38.384615
120
0.618236
2,743
0.916166
0
0
708
0.236473
0
0
144
0.048096
643f3606fb03079a2aebe0691fe7ccf424370f28
1,605
py
Python
controller/models/models.py
zhouzhibo-byte/odoo14
8b9df536e09d56d036421cd12fe141116a545dd8
[ "Unlicense" ]
null
null
null
controller/models/models.py
zhouzhibo-byte/odoo14
8b9df536e09d56d036421cd12fe141116a545dd8
[ "Unlicense" ]
null
null
null
controller/models/models.py
zhouzhibo-byte/odoo14
8b9df536e09d56d036421cd12fe141116a545dd8
[ "Unlicense" ]
null
null
null
# -*- coding: utf-8 -*- from odoo import models, fields,api class LibraryBook(models.Model): _name = 'library.book1' _description = 'Library Book' _order = 'date_release desc, name' name = fields.Char('Title', required=True) short_name = fields.Char('Short Title', required=True) date_release ...
31.470588
95
0.530841
1,571
0.962033
0
0
250
0.153092
0
0
545
0.333742
643f658432e2b5800e1eef8b53a2ef7b6a24acc9
472
py
Python
1.py
aayushgupta97/advent_of_code_2020
dbf5291f1cf4bd5855bbc54cb560ac3c7a7ac26c
[ "MIT" ]
null
null
null
1.py
aayushgupta97/advent_of_code_2020
dbf5291f1cf4bd5855bbc54cb560ac3c7a7ac26c
[ "MIT" ]
null
null
null
1.py
aayushgupta97/advent_of_code_2020
dbf5291f1cf4bd5855bbc54cb560ac3c7a7ac26c
[ "MIT" ]
null
null
null
with open("data/input_1.txt", 'r') as f: input_data = f.readlines() data = [int(i.replace("\n", "")) for i in input_data] print(len(data)) def part_1(): for i in data: for j in data: if i + j == 2020: print(i * j) def part_2(): for i in data: ...
19.666667
53
0.423729
0
0
0
0
0
0
0
0
27
0.057203
643f6db20affdc124c5bd15106d9960bdbf837f9
661
py
Python
Pdf to Audio Book Maker.py
farhan1503001/Beginners-Python-Projects
67c2cfc426cad6dcbb148252b9845aeaef78cb57
[ "MIT" ]
null
null
null
Pdf to Audio Book Maker.py
farhan1503001/Beginners-Python-Projects
67c2cfc426cad6dcbb148252b9845aeaef78cb57
[ "MIT" ]
null
null
null
Pdf to Audio Book Maker.py
farhan1503001/Beginners-Python-Projects
67c2cfc426cad6dcbb148252b9845aeaef78cb57
[ "MIT" ]
null
null
null
import pyttsx3 import PyPDF2 from tkinter.filedialog import * #Ask for book file book_file=askopenfilename() pdfreader=PyPDF2.PdfFileReader(book_file)#Initialize Reading the pdf file num_pages=pdfreader.numPages#Finds the number of pages in that book #Now iterate through each and every page and convert that to ...
38.882353
74
0.765507
0
0
0
0
0
0
0
0
279
0.422088
643fa9180d34b45a3bfb22d963256b7d5985659e
2,857
py
Python
cose/messages/macmessage.py
mpzaborski/pycose
1c63b272f551a69e411063937a070c1c0479f8e0
[ "BSD-3-Clause" ]
null
null
null
cose/messages/macmessage.py
mpzaborski/pycose
1c63b272f551a69e411063937a070c1c0479f8e0
[ "BSD-3-Clause" ]
null
null
null
cose/messages/macmessage.py
mpzaborski/pycose
1c63b272f551a69e411063937a070c1c0479f8e0
[ "BSD-3-Clause" ]
null
null
null
""" MACed Message with Recipients COSE_Mac = [ Headers, payload : bstr / nil, tag : bstr, recipients :[+COSE_recipient] ] """ from typing import Optional, List import cbor2 from cose import CoseMessage from cose.messages import cosemessage, maccommon from cose.attributes.algorithms import Co...
31.054348
117
0.60413
2,369
0.829191
0
0
2,414
0.844942
0
0
488
0.170809
ff218524b954b48397bd6cee491e5e897272d086
8,083
py
Python
V1/oer_glidervsCTD_plot.py
NOAA-PMEL/EcoFOCI_OculusGlider
5655c0e173432768706416932c94a089a3e7993f
[ "Unlicense" ]
2
2018-04-12T19:49:05.000Z
2020-10-01T11:46:48.000Z
V1/oer_glidervsCTD_plot.py
NOAA-PMEL/EcoFOCI_OculusGlider
5655c0e173432768706416932c94a089a3e7993f
[ "Unlicense" ]
null
null
null
V1/oer_glidervsCTD_plot.py
NOAA-PMEL/EcoFOCI_OculusGlider
5655c0e173432768706416932c94a089a3e7993f
[ "Unlicense" ]
null
null
null
#!/usr/bin/env python """ Background: -------- oer_glidervsCTD_plot.py Purpose: -------- History: -------- """ import argparse, os import numpy as np import calc.aanderaa_corrO2_sal as optode_O2_corr from plots.profile_plot import CTDProfilePlot import io_utils.EcoFOCI_netCDF_read as eFOCI_ncread # V...
32.857724
107
0.601633
0
0
0
0
0
0
0
0
1,601
0.19807
ff2233bb02f187b2c1f54b2c72ddfd6822179595
1,551
py
Python
scripts/operator/delete_operators_from_quay.py
snyk-schmidtty/kubernetes-monitor
58811f1fea6673561806811abfa70292ca6a4f07
[ "Apache-2.0" ]
null
null
null
scripts/operator/delete_operators_from_quay.py
snyk-schmidtty/kubernetes-monitor
58811f1fea6673561806811abfa70292ca6a4f07
[ "Apache-2.0" ]
5
2021-02-27T03:16:34.000Z
2021-02-27T03:17:58.000Z
scripts/operator/delete_operators_from_quay.py
snyk-schmidtty/kubernetes-monitor
58811f1fea6673561806811abfa70292ca6a4f07
[ "Apache-2.0" ]
null
null
null
#! /usr/bin/python3 """Delete all Operators from the Quay Snyk Operator repository Args: username (str): Quay username password (str): Quay password """ from requests import get, delete from json import loads from get_quay_token import getQuayToken from typing import List, Dict from sys import argv Package ...
24.234375
81
0.63314
0
0
0
0
0
0
0
0
475
0.306254
ff234cba60f02dcaf43134ee5acb4492e57d2cbb
4,009
py
Python
schools3/config/main_config.py
dssg/mlpolicylab_fall20_schools3_public
f8eff4c56e9bada1eb81ddaca03686d7ef53c2c4
[ "MIT" ]
null
null
null
schools3/config/main_config.py
dssg/mlpolicylab_fall20_schools3_public
f8eff4c56e9bada1eb81ddaca03686d7ef53c2c4
[ "MIT" ]
null
null
null
schools3/config/main_config.py
dssg/mlpolicylab_fall20_schools3_public
f8eff4c56e9bada1eb81ddaca03686d7ef53c2c4
[ "MIT" ]
null
null
null
import sys import pandas as pd import sherpa from schools3.config import base_config from schools3.data.features.processors.impute_null_processor import ImputeNullProcessor, ImputeBy from schools3.data.features.processors.composite_feature_processor import CompositeFeatureProcessor from schools3.data.features.processor...
39.303922
235
0.833375
0
0
0
0
0
0
0
0
307
0.076578
ff25db516b2acce8246e0ce6dbaafb46c8b2035b
623
py
Python
packaging_example/0_in_the_beginning/lab.py
sr105/python_packages_tutorial
e795ce1ff14463dd5c3da06d120a4e40da5ad732
[ "MIT" ]
1
2021-06-11T17:47:39.000Z
2021-06-11T17:47:39.000Z
packaging_example/0_in_the_beginning/lab.py
sr105/python_packages_tutorial
e795ce1ff14463dd5c3da06d120a4e40da5ad732
[ "MIT" ]
null
null
null
packaging_example/0_in_the_beginning/lab.py
sr105/python_packages_tutorial
e795ce1ff14463dd5c3da06d120a4e40da5ad732
[ "MIT" ]
null
null
null
# Computations def multiply_a_list_by(a_list, number): """Return a list with every item multiplied by number.""" return [item * number for item in a_list] def square_a_list(a_list): """Return a list with every item squared.""" return [item * item for item in a_list] # Constants PI = 3.14159 AVOGADRO...
22.25
61
0.680578
0
0
0
0
0
0
0
0
276
0.443018
ff266552067c871f264f181ad65f6b4259ee89bd
11,031
py
Python
pull_requests_and_issues.py
andreasscherbaum/github_issue_exporter
95e01b7dd90250393b4550502445ab6c0f821e7a
[ "Apache-2.0" ]
null
null
null
pull_requests_and_issues.py
andreasscherbaum/github_issue_exporter
95e01b7dd90250393b4550502445ab6c0f821e7a
[ "Apache-2.0" ]
null
null
null
pull_requests_and_issues.py
andreasscherbaum/github_issue_exporter
95e01b7dd90250393b4550502445ab6c0f821e7a
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python # # Download GitHub Issued and PR as CSV # # written by Andreas 'ads' Scherbaum <andreas@scherbaum.la> # # version: 0.5 2016-08-27 # initial version # 1.0 2016-09-04 # update help # add options # remov...
31.161017
182
0.581996
0
0
0
0
0
0
0
0
3,794
0.34394
ff298f207d3ee96b781b7eddae68d7609d2caae4
85
py
Python
units/apps.py
ezekielkibiego/Store_Center
199bb8240e78e7227d2daa0ce8d9df13e1c429f7
[ "MIT" ]
6
2022-01-27T15:12:43.000Z
2022-03-28T23:07:14.000Z
units/apps.py
ezekielkibiego/Store_Center
199bb8240e78e7227d2daa0ce8d9df13e1c429f7
[ "MIT" ]
7
2022-01-21T11:58:55.000Z
2022-01-29T00:11:10.000Z
units/apps.py
c3n7/university-portal
82bf40a1c0d98111ffe8a184d16b543a3feec072
[ "MIT" ]
3
2022-01-27T13:22:11.000Z
2022-03-03T12:41:31.000Z
from django.apps import AppConfig class UnitsConfig(AppConfig): name = 'units'
14.166667
33
0.741176
48
0.564706
0
0
0
0
0
0
7
0.082353
ff2c61c10884e455b05064de9a81456bb3dbabf3
319
py
Python
setup.py
TimothyClaeys/SramAnalyzer
0f4d908730df4a227c2a9bbbea6739f24cbebdc7
[ "MIT" ]
null
null
null
setup.py
TimothyClaeys/SramAnalyzer
0f4d908730df4a227c2a9bbbea6739f24cbebdc7
[ "MIT" ]
null
null
null
setup.py
TimothyClaeys/SramAnalyzer
0f4d908730df4a227c2a9bbbea6739f24cbebdc7
[ "MIT" ]
null
null
null
from setuptools import setup setup( name='sram_tools', version='0.1', py_modules=['sram_tools'], python_requires='>=3.6', install_requires=[ 'Click', 'pillow', 'matplotlib' ], entry_points=''' [console_scripts] sram_tools=sramanalyzer:cli ''', )
17.722222
35
0.561129
0
0
0
0
0
0
0
0
136
0.426332
ff2e375a8f50378a13a348c074037b0b1fd28807
1,035
py
Python
util/security/test/test_secret.py
sferich888/quay
4672db1df76874238baf134d04e74112ac9f630d
[ "Apache-2.0" ]
null
null
null
util/security/test/test_secret.py
sferich888/quay
4672db1df76874238baf134d04e74112ac9f630d
[ "Apache-2.0" ]
null
null
null
util/security/test/test_secret.py
sferich888/quay
4672db1df76874238baf134d04e74112ac9f630d
[ "Apache-2.0" ]
null
null
null
import uuid import pytest from util.security.secret import convert_secret_key @pytest.mark.parametrize( "config_secret_key, expected_secret_key", [ pytest.param("somesecretkey", b"somesecretkeysomesecretkeysomese", id="Some string"), pytest.param("255", b"\xff" * 32, id="Some int that can be ...
34.5
102
0.675362
0
0
0
0
953
0.920773
0
0
378
0.365217
ff3111c8ed012b9a11b5d7265507d9ec11c1c3e2
411
py
Python
slack_g_cal/g_cal/__init__.py
wfa207/slack_g_cal
2acfb19d156e3b6f14c4ad0b079b9c3a5f79c9b0
[ "Apache-2.0" ]
1
2018-11-01T15:53:18.000Z
2018-11-01T15:53:18.000Z
slack_g_cal/g_cal/__init__.py
wfa207/slack_g_cal
2acfb19d156e3b6f14c4ad0b079b9c3a5f79c9b0
[ "Apache-2.0" ]
null
null
null
slack_g_cal/g_cal/__init__.py
wfa207/slack_g_cal
2acfb19d156e3b6f14c4ad0b079b9c3a5f79c9b0
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- from __future__ import unicode_literals from os import environ, path from .client import GoogleCalClient SCOPES = ['https://www.googleapis.com/auth/calendar'] GOOGLE_AUTH_FILENAME = environ['GOOGLE_AUTH_FILENAME'] GOOGLE_AUTH_FILEPATH = path.abspath(path.join(path.dirname(__file__), './{}'.fo...
31.615385
107
0.785888
0
0
0
0
0
0
0
0
93
0.226277
ff31983c8ac601d9ab46ea257efd05459537f8e8
17,403
py
Python
database_manager/database_manager.py
virbickt/tlc-data-pipeline
18e61e0e6dd4cb00e7ad0b2b13d48ac626a9e0b8
[ "MIT" ]
1
2022-01-30T12:16:36.000Z
2022-01-30T12:16:36.000Z
database_manager/database_manager.py
virbickt/tlc-data-pipeline
18e61e0e6dd4cb00e7ad0b2b13d48ac626a9e0b8
[ "MIT" ]
null
null
null
database_manager/database_manager.py
virbickt/tlc-data-pipeline
18e61e0e6dd4cb00e7ad0b2b13d48ac626a9e0b8
[ "MIT" ]
null
null
null
import os import time import pyodbc from azure.common.credentials import ServicePrincipalCredentials from azure.mgmt.resource import ResourceManagementClient from azure.mgmt.sql import SqlManagementClient from dotenv import find_dotenv, load_dotenv load_dotenv(find_dotenv()) class Database: def __init__( ...
43.616541
438
0.600011
17,122
0.983853
0
0
0
0
0
0
11,390
0.654485
ff31cc51ee4cb699318f8c7e3d04f5809d3e62ad
3,395
py
Python
socket/app.py
cheeseywhiz/cheeseywhiz
51f6651ddbaeebd14d9ce77776bc4cf3a95511c4
[ "MIT" ]
null
null
null
socket/app.py
cheeseywhiz/cheeseywhiz
51f6651ddbaeebd14d9ce77776bc4cf3a95511c4
[ "MIT" ]
null
null
null
socket/app.py
cheeseywhiz/cheeseywhiz
51f6651ddbaeebd14d9ce77776bc4cf3a95511c4
[ "MIT" ]
null
null
null
"""A sample custom HTTP server.""" import functools import html import traceback import collect import server server.Logger.name = __file__ HTML_TMPL = '''\ <html> <head> <link rel="stylesheet" type="text/css" href="/myStyle.css"/> </head> <body id="consolas"> %s</body> </html> ''' LINK_HOME = '<a href="/">Home<...
21.762821
73
0.613844
0
0
636
0.187334
2,350
0.692194
0
0
986
0.290427
ff32f68fb44dc05b704c9e1bf005ac75b155b258
1,512
py
Python
services/web/server/src/simcore_service_webserver/projects/projects_tags_handlers.py
colinRawlings/osparc-simcore
bf2f18d5bc1e574d5f4c238d08ad15156184c310
[ "MIT" ]
25
2018-04-13T12:44:12.000Z
2022-03-12T15:01:17.000Z
services/web/server/src/simcore_service_webserver/projects/projects_tags_handlers.py
colinRawlings/osparc-simcore
bf2f18d5bc1e574d5f4c238d08ad15156184c310
[ "MIT" ]
2,553
2018-01-18T17:11:55.000Z
2022-03-31T16:26:40.000Z
services/web/server/src/simcore_service_webserver/projects/projects_tags_handlers.py
mrnicegyu11/osparc-simcore
b6fa6c245dbfbc18cc74a387111a52de9b05d1f4
[ "MIT" ]
20
2018-01-18T19:45:33.000Z
2022-03-29T07:08:47.000Z
""" Handlers for CRUD operations on /projects/{*}/tags/{*} """ import logging from aiohttp import web from .._meta import api_version_prefix as VTAG from ..login.decorators import RQT_USERID_KEY, login_required from ..security_decorators import permission_required from .projects_db import APP_PROJECT_DBAPI, Project...
28
84
0.71164
0
0
0
0
1,114
0.736772
871
0.576058
271
0.179233
ff3313d7fbbaa4f483d5adc2ada397adb8303dc3
113
py
Python
References/Geovana Neves/TCC_Geovana_Neves_GitHub/SUAVE_modifications/SUAVE-feature-constant_throttle_EAS/trunk/SUAVE/Attributes/Gases/__init__.py
Vinicius-Tanigawa/Undergraduate-Research-Project
e92372f07882484b127d7affe305eeec2238b8a9
[ "MIT" ]
null
null
null
References/Geovana Neves/TCC_Geovana_Neves_GitHub/SUAVE_modifications/SUAVE-feature-constant_throttle_EAS/trunk/SUAVE/Attributes/Gases/__init__.py
Vinicius-Tanigawa/Undergraduate-Research-Project
e92372f07882484b127d7affe305eeec2238b8a9
[ "MIT" ]
null
null
null
References/Geovana Neves/TCC_Geovana_Neves_GitHub/SUAVE_modifications/SUAVE-feature-constant_throttle_EAS/trunk/SUAVE/Attributes/Gases/__init__.py
Vinicius-Tanigawa/Undergraduate-Research-Project
e92372f07882484b127d7affe305eeec2238b8a9
[ "MIT" ]
null
null
null
# classes from Air import Air from CO2 import CO2 from Steam import Steam from Gas import Gas # packages # ...
11.3
23
0.734513
0
0
0
0
0
0
0
0
24
0.212389
ff331d0933475a031554907cd3c4b819e0f29798
1,362
py
Python
audioToJummbox/main.py
KeeyanGhoreshi/AudioToJummbox
aaf9a64e47367ff1e375916ffeab92355322bd99
[ "MIT" ]
null
null
null
audioToJummbox/main.py
KeeyanGhoreshi/AudioToJummbox
aaf9a64e47367ff1e375916ffeab92355322bd99
[ "MIT" ]
null
null
null
audioToJummbox/main.py
KeeyanGhoreshi/AudioToJummbox
aaf9a64e47367ff1e375916ffeab92355322bd99
[ "MIT" ]
null
null
null
import argparse import os import sys import logging from audioToJummbox import converter def parse_args(): parser = argparse.ArgumentParser() parser.add_argument("infile", help="The audio file to convert") parser.add_argument("--base", "-b", default="./resources/template.json", help="The file used as the b...
33.219512
148
0.637298
0
0
0
0
0
0
0
0
389
0.285609
ff34bc72d0901db6c713baef231ab65634196f4b
194
py
Python
Course/functions/example_18.py
zevgenia/Python_shultais
e51c31de221c5e7f36ede857a960138009ec8a05
[ "Apache-2.0" ]
null
null
null
Course/functions/example_18.py
zevgenia/Python_shultais
e51c31de221c5e7f36ede857a960138009ec8a05
[ "Apache-2.0" ]
null
null
null
Course/functions/example_18.py
zevgenia/Python_shultais
e51c31de221c5e7f36ede857a960138009ec8a05
[ "Apache-2.0" ]
null
null
null
def func(arg1, arg2): arg1 = 20 arg2 = arg2[:] arg2[0] = 10 print('arg1', arg1) print('arg2', arg2) ten = 10 l = [1, 2, 3] func(ten, l) print("ten:", ten) print("l:", l)
12.125
23
0.5
0
0
0
0
0
0
0
0
22
0.113402
ff34e2899bffacd28b1fe087f784f173acd09a05
18,680
py
Python
src/menu_screen.py
dcripplinger/rotj
4de46b0e39e3971dd23650a28010bd90b3f637d2
[ "MIT" ]
5
2019-11-03T21:27:17.000Z
2021-12-08T04:38:50.000Z
src/menu_screen.py
dcripplinger/rotj
4de46b0e39e3971dd23650a28010bd90b3f637d2
[ "MIT" ]
10
2018-01-06T03:56:17.000Z
2022-02-17T22:04:39.000Z
src/menu_screen.py
dcripplinger/rotj
4de46b0e39e3971dd23650a28010bd90b3f637d2
[ "MIT" ]
1
2018-01-06T03:21:51.000Z
2018-01-06T03:21:51.000Z
# -*- coding: UTF-8 -*- import time import pygame from pygame.locals import * from constants import BLACK, GAME_WIDTH, HQ_LOCATIONS from helpers import create_save_state, erase_save_state, is_half_second, load_save_states, copy_save_state from text import create_prompt, MenuBox, MenuGrid, TextBox MAIN_MENU = [ ...
45.672372
147
0.59652
18,263
0.977572
0
0
0
0
0
0
1,754
0.093887
ff359ff3fd4bf0c0cae3e20cfdf394e907b8e238
5,951
py
Python
mergify_engine/tests/unit/engine/test_action_runner.py
truthiswill/mergify-engine
c7495d23387d0f003e4ce6aeff89ee8139b83f6b
[ "Apache-2.0" ]
null
null
null
mergify_engine/tests/unit/engine/test_action_runner.py
truthiswill/mergify-engine
c7495d23387d0f003e4ce6aeff89ee8139b83f6b
[ "Apache-2.0" ]
6
2022-03-15T08:59:04.000Z
2022-03-28T07:42:05.000Z
mergify_engine/tests/unit/engine/test_action_runner.py
truthiswill/mergify-engine
c7495d23387d0f003e4ce6aeff89ee8139b83f6b
[ "Apache-2.0" ]
null
null
null
# -*- encoding: utf-8 -*- # # Copyright © 2021 Mergify SAS # # 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 applicabl...
52.201754
114
0.694505
0
0
0
0
0
0
5,062
0.85047
2,599
0.43666
ff369ffed01924e0fc727c1c01ee736be4c7d1a9
83
py
Python
backend/api/hash/apps.py
BeelGroup/EB-1920--Mass-Email-Detection-Team-3-
5960b2265f7214d95ac134c81ffb072fc45250e0
[ "MIT" ]
null
null
null
backend/api/hash/apps.py
BeelGroup/EB-1920--Mass-Email-Detection-Team-3-
5960b2265f7214d95ac134c81ffb072fc45250e0
[ "MIT" ]
8
2019-11-19T13:02:58.000Z
2022-02-10T11:53:09.000Z
backend/api/hash/apps.py
BeelGroup/EB-1920--Mass-Email-Detection-Team-3-
5960b2265f7214d95ac134c81ffb072fc45250e0
[ "MIT" ]
1
2019-11-21T14:29:32.000Z
2019-11-21T14:29:32.000Z
from django.apps import AppConfig class HashConfig(AppConfig): name = 'hash'
13.833333
33
0.73494
46
0.554217
0
0
0
0
0
0
6
0.072289
ff37239f95e4e3ea9734c1a1abe1ff10c0e7a235
1,033
py
Python
apps/groups/urls.py
sgazda94/dj_schulx
c6d2086201b80bb007df34be6b623e3001bf7446
[ "MIT" ]
null
null
null
apps/groups/urls.py
sgazda94/dj_schulx
c6d2086201b80bb007df34be6b623e3001bf7446
[ "MIT" ]
1
2022-03-28T22:19:01.000Z
2022-03-28T22:19:01.000Z
apps/groups/urls.py
sgazda94/dj_schulx
c6d2086201b80bb007df34be6b623e3001bf7446
[ "MIT" ]
null
null
null
from django.urls import path from . import views app_name = "groups" urlpatterns = [ path("", views.GroupListView.as_view(), name="group-list"), # group path("<int:pk>", views.GroupDetailView.as_view(), name="group-detail"), path("create/", views.GroupCreateView.as_view(), name="group-create"), p...
28.694444
83
0.604066
0
0
0
0
0
0
0
0
348
0.336883
ff37b21e4f22a3688a0db0f2082ba54dca0a2890
315
py
Python
analyzer/darwin/lib/common/exceptions.py
maximejf42/mac-sandbox
cb3ac3f31e97843309d4c8cc81bf703c70132c53
[ "Unlicense" ]
21
2016-07-29T16:03:20.000Z
2022-01-05T23:53:51.000Z
analyzer/darwin/lib/common/exceptions.py
maximejf42/mac-sandbox
cb3ac3f31e97843309d4c8cc81bf703c70132c53
[ "Unlicense" ]
null
null
null
analyzer/darwin/lib/common/exceptions.py
maximejf42/mac-sandbox
cb3ac3f31e97843309d4c8cc81bf703c70132c53
[ "Unlicense" ]
6
2017-08-09T23:58:44.000Z
2022-01-05T10:33:27.000Z
# Copyright (C) 2010-2014 Cuckoo Foundation. # This file is part of Cuckoo Sandbox - http://www.cuckoosandbox.org # See the file 'docs/LICENSE' for copying permission. # Note: This is unmodified from the Cuckoo Windows version class CuckooError(Exception): pass class CuckooPackageError(Exception): pass
26.25
68
0.75873
83
0.263492
0
0
0
0
0
0
223
0.707937
ff380efa06c35f4afffb0d74a5bad4060b622804
5,792
py
Python
baseline2D.py
lruthotto/NeuralOC
3f37c7349527fb1f5890077ebe987f2f77486a54
[ "MIT" ]
13
2021-05-12T11:52:53.000Z
2022-03-30T14:50:28.000Z
baseline2D.py
lruthotto/NeuralOC
3f37c7349527fb1f5890077ebe987f2f77486a54
[ "MIT" ]
null
null
null
baseline2D.py
lruthotto/NeuralOC
3f37c7349527fb1f5890077ebe987f2f77486a54
[ "MIT" ]
3
2021-04-20T08:07:50.000Z
2022-02-15T22:37:12.000Z
# baseline2D.py # baseline method for problems using the Cross2D object import math import torch import argparse from src.utils import normpdf from src.initProb import * from src.OCflow import ocG from src.plotter import * parser = argparse.ArgumentParser('Baseline') parser.add_argument( '--data', choices=['soft...
34.891566
141
0.577866
0
0
0
0
0
0
0
0
1,958
0.338052
ff38954f361ab1c6d35db5a48ef989d7e38199c8
600
bzl
Python
source/bazel/deps/emsdk/get.bzl
luxe/CodeLang-compiler
78837d90bdd09c4b5aabbf0586a5d8f8f0c1e76a
[ "MIT" ]
1
2019-01-06T08:45:46.000Z
2019-01-06T08:45:46.000Z
source/bazel/deps/emsdk/get.bzl
luxe/CodeLang-compiler
78837d90bdd09c4b5aabbf0586a5d8f8f0c1e76a
[ "MIT" ]
264
2015-11-30T08:34:00.000Z
2018-06-26T02:28:41.000Z
source/bazel/deps/emsdk/get.bzl
UniLang/compiler
c338ee92994600af801033a37dfb2f1a0c9ca897
[ "MIT" ]
null
null
null
# Do not edit this file directly. # It was auto-generated by: code/programs/reflexivity/reflexive_refresh load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_file") def emsdk(): http_archive( name = "emsdk", sha256 = "c9eb...
37.5
103
0.718333
0
0
0
0
0
0
0
0
438
0.73
ff38bd994fdfd83262984d03a2c5fd5b0d4567e2
1,419
py
Python
mbus_ref/mbus_controlframe.py
gideoncaringal/pyMeterBus
f2489425f156ec43dc408e343f69ece074cb1fba
[ "BSD-3-Clause" ]
null
null
null
mbus_ref/mbus_controlframe.py
gideoncaringal/pyMeterBus
f2489425f156ec43dc408e343f69ece074cb1fba
[ "BSD-3-Clause" ]
null
null
null
mbus_ref/mbus_controlframe.py
gideoncaringal/pyMeterBus
f2489425f156ec43dc408e343f69ece074cb1fba
[ "BSD-3-Clause" ]
1
2019-12-05T13:49:04.000Z
2019-12-05T13:49:04.000Z
from mbus_h import * from mbus_telegram import * from exceptions import * class MBusControlFrame(MBusTelegram): def __init__(self, dbuf=None): self.base_size = MBUS_FRAME_BASE_SIZE_CONTROL return def compute_crc(self): return (self.control + self.address + self.control_information) % 256 def check_crc(sel...
30.847826
73
0.693446
1,343
0.946441
0
0
1,045
0.736434
0
0
69
0.048626
ff38e67a8c1a6702cdc8622934c8e106e37e5219
303
py
Python
BOJ/17000~17999/17800~17899/17826.py
shinkeonkim/today-ps
f3e5e38c5215f19579bb0422f303a9c18c626afa
[ "Apache-2.0" ]
2
2020-01-29T06:54:41.000Z
2021-11-07T13:23:27.000Z
BOJ/17000~17999/17800~17899/17826.py
shinkeonkim/Today_PS
bb0cda0ee1b9c57e1cfa38355e29d0f1c6167a44
[ "Apache-2.0" ]
null
null
null
BOJ/17000~17999/17800~17899/17826.py
shinkeonkim/Today_PS
bb0cda0ee1b9c57e1cfa38355e29d0f1c6167a44
[ "Apache-2.0" ]
null
null
null
L = list(map(int,input().split())) a = int(input()) L.sort(reverse= True) k = -1 for i in range(len(L)): if L[i] == a: k = i+1 D = [[1,5,'A+'],[6,15,'A0'],[16,30,'B+'],[31,35,'B0'],[36,45,'C+'],[46,48,'C0'],[49,50,'F']] for i in D: if i[0] <= k <= i[1]: print(i[2]) break
25.25
92
0.438944
0
0
0
0
0
0
0
0
27
0.089109
ff3971eefa022c612a9b32f2288f8a495121ba39
1,036
py
Python
projects/code_combat/8_Cloudrip_Mountain/438-Steelclaw_Gap/steeclaw_gap.py
only-romano/junkyard
b60a25b2643f429cdafee438d20f9966178d6f36
[ "MIT" ]
null
null
null
projects/code_combat/8_Cloudrip_Mountain/438-Steelclaw_Gap/steeclaw_gap.py
only-romano/junkyard
b60a25b2643f429cdafee438d20f9966178d6f36
[ "MIT" ]
null
null
null
projects/code_combat/8_Cloudrip_Mountain/438-Steelclaw_Gap/steeclaw_gap.py
only-romano/junkyard
b60a25b2643f429cdafee438d20f9966178d6f36
[ "MIT" ]
null
null
null
defendPoints = [{"x": 35, "y": 63},{"x": 61, "y": 63},{"x": 32, "y": 26},{"x": 64, "y": 26}]; summonTypes = ["soldier","soldier","soldier","soldier","archer","archer","archer","archer"]; def summonTroops(): type = summonTypes[hero.built.length % summonTypes.length] if hero.gold >= hero.costOf(type): ...
31.393939
94
0.533784
0
0
0
0
0
0
0
0
135
0.130309
ff3de2b458b0ec727bd41816ccf0ff6f78bbd977
33,996
py
Python
pytorch_library/utils_training.py
MarioProjects/pytorchlib
81ea32304d899fbd10ae1efe1d124c0d7bc96f5c
[ "MIT" ]
1
2018-12-05T17:11:47.000Z
2018-12-05T17:11:47.000Z
pytorch_library/utils_training.py
MarioProjects/pytorchlib
81ea32304d899fbd10ae1efe1d124c0d7bc96f5c
[ "MIT" ]
null
null
null
pytorch_library/utils_training.py
MarioProjects/pytorchlib
81ea32304d899fbd10ae1efe1d124c0d7bc96f5c
[ "MIT" ]
null
null
null
import types import numpy as np import torch import math from torch import nn, optim import torch.nn.functional as F from torch.autograd.variable import Variable CROSS_ENTROPY_ONE_HOT_WARNING = False def to_categorical(y, num_classes=None, dtype='float32'): """Converts a class vector (integers) to bina...
42.978508
185
0.6011
2,626
0.077238
0
0
0
0
0
0
14,462
0.425365
ff3e34a66b19db98dc46a9bddfa39058221a3e0e
1,178
py
Python
augly/utils/base_paths.py
Ierezell/AugLy
a7dca8c36bc05dbd7694373fe9b883d6ff720f56
[ "MIT" ]
1
2021-09-29T21:27:50.000Z
2021-09-29T21:27:50.000Z
augly/utils/base_paths.py
Ierezell/AugLy
a7dca8c36bc05dbd7694373fe9b883d6ff720f56
[ "MIT" ]
null
null
null
augly/utils/base_paths.py
Ierezell/AugLy
a7dca8c36bc05dbd7694373fe9b883d6ff720f56
[ "MIT" ]
1
2021-07-02T13:08:55.000Z
2021-07-02T13:08:55.000Z
#!/usr/bin/env python3 # Copyright (c) Facebook, Inc. and its affiliates. import os MODULE_BASE_DIR = os.path.dirname(os.path.dirname(__file__)) # asset paths ASSETS_BASE_DIR = os.path.join(MODULE_BASE_DIR, "assets") AUDIO_ASSETS_DIR = os.path.join(ASSETS_BASE_DIR, "audio") TEXT_DIR = os.path.join(ASSETS_BASE_DIR, ...
40.62069
88
0.797963
0
0
0
0
0
0
0
0
279
0.236842
ff3f61dcc346db3af4cf5a36041b057887e5a981
1,639
py
Python
venv/Lib/site-packages/transliterate/tests/data/default.py
jedeland/jedel_name_generator
8d220c7e6a13e013d9664402cb0262f323a4056d
[ "MIT" ]
null
null
null
venv/Lib/site-packages/transliterate/tests/data/default.py
jedeland/jedel_name_generator
8d220c7e6a13e013d9664402cb0262f323a4056d
[ "MIT" ]
null
null
null
venv/Lib/site-packages/transliterate/tests/data/default.py
jedeland/jedel_name_generator
8d220c7e6a13e013d9664402cb0262f323a4056d
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- __title__ = 'transliterate.tests.data.default' __author__ = 'Artur Barseghyan' __copyright__ = '2013-2018 Artur Barseghyan' __license__ = 'GPL 2.0/LGPL 2.1' latin_text = u"Lorem ipsum dolor sit amet" armenian_text = u'Լօրեմ իպսում դօլօր սիտ ամետ' cyrillic_text = u'Лорем ипсум долор сит амет' ...
35.630435
78
0.721171
0
0
0
0
0
0
0
0
1,145
0.598849
ff3fa6bdc655e5c340cc8b1b61dfaa6a7d978fda
5,510
py
Python
PLOT/plot_orbits2.py
itpplasma/SIMPLE
6981791e0a7889647ac5c006325ac951811c2f36
[ "MIT" ]
1
2020-11-18T14:58:27.000Z
2020-11-18T14:58:27.000Z
PLOT/plot_orbits2.py
landreman/SIMPLE
77722c2479b4a064b99d0e2a58ef7749ce157c07
[ "MIT" ]
6
2019-10-25T07:52:00.000Z
2021-11-16T13:19:04.000Z
PLOT/plot_orbits2.py
landreman/SIMPLE
77722c2479b4a064b99d0e2a58ef7749ce157c07
[ "MIT" ]
2
2021-11-05T18:55:09.000Z
2022-03-23T06:27:04.000Z
#%% import time import numpy as np import matplotlib.pyplot as plt from mpl_toolkits.mplot3d import Axes3D from neo_orb_fffi import * from os import path import exportfig #basedir = '/home/calbert/net/cobra/ipp/ishw19/scripts' basedir = '.' zs = np.load(path.join(basedir, 'z.npy')) var_tips = np.load(path.join(base...
28.549223
83
0.634846
0
0
0
0
0
0
0
0
709
0.128675
ff42053acc3e1c654965608c70b04513a16eaec2
2,177
py
Python
helpers/extract_edges.py
aliborji/ShapeDefence
92da19bb195b5161d997f6ee1cc777b07a714f6f
[ "MIT" ]
null
null
null
helpers/extract_edges.py
aliborji/ShapeDefence
92da19bb195b5161d997f6ee1cc777b07a714f6f
[ "MIT" ]
1
2022-03-12T00:40:21.000Z
2022-03-12T00:40:21.000Z
helpers/extract_edges.py
aliborji/ShapeDefense
92da19bb195b5161d997f6ee1cc777b07a714f6f
[ "MIT" ]
null
null
null
# clac edge import os from edge_detector import * from PIL import Image # import torch from image_transform import ImageTransform from config import * # from matplotlib import pyplot as plt # import glob # import numpy as np import argparse ''' python extract_edges.py --img_dir --dest_dir img_dir = './dog-breed-...
27.910256
82
0.644465
0
0
0
0
0
0
0
0
612
0.281121