hexsha
stringlengths
40
40
size
int64
2
1.02M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
245
max_stars_repo_name
stringlengths
6
130
max_stars_repo_head_hexsha
stringlengths
40
40
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
4
245
max_issues_repo_name
stringlengths
6
130
max_issues_repo_head_hexsha
stringlengths
40
40
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
4
245
max_forks_repo_name
stringlengths
6
130
max_forks_repo_head_hexsha
stringlengths
40
40
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
2
1.02M
avg_line_length
float64
1
958k
max_line_length
int64
1
987k
alphanum_fraction
float64
0
1
content_no_comment
stringlengths
0
1.01M
is_comment_constant_removed
bool
2 classes
is_sharp_comment_removed
bool
1 class
f757503fbd3021164a9441bb77e883165d80e053
647
py
Python
projects/graph/util.py
Nolanole/Graphs
fedfb61d81794c5a0e10e59ae67f447947c8d43c
[ "MIT" ]
null
null
null
projects/graph/util.py
Nolanole/Graphs
fedfb61d81794c5a0e10e59ae67f447947c8d43c
[ "MIT" ]
8
2020-03-24T17:47:23.000Z
2022-03-12T00:33:21.000Z
cs/lambda_cs/06_graphs/sprint_challenge/util.py
tobias-fyi/vela
b0b3d3c6dc3fa397c8c7a492098a02cf75e0ff82
[ "MIT" ]
null
null
null
# Note: This Queue class is sub-optimal. Why? class Queue(): def __init__(self): self.queue = [] def enqueue(self, value): self.queue.append(value) def dequeue(self): if self.size() > 0: return self.queue.pop(0) else: return None def size(self): ...
22.310345
45
0.53323
class Queue(): def __init__(self): self.queue = [] def enqueue(self, value): self.queue.append(value) def dequeue(self): if self.size() > 0: return self.queue.pop(0) else: return None def size(self): return len(self.queue) class Stack(): ...
true
true
f757509944dd5d08594b54482eca702d1c59c898
4,759
py
Python
sortingview/helpers/prepare_snippets_h5_old.py
garrettmflynn/sortingview
0bb3df40d5d031ec651c4821f928787bbee71fbb
[ "Apache-2.0" ]
2
2021-11-19T04:51:42.000Z
2022-03-12T23:36:19.000Z
sortingview/helpers/prepare_snippets_h5_old.py
magland/sortingview
0b1be9d55048cd4b8a0b6b6733bd7d35cb440aa7
[ "Apache-2.0" ]
172
2021-05-10T17:39:15.000Z
2022-03-18T21:46:15.000Z
sortingview/helpers/prepare_snippets_h5_old.py
garrettmflynn/sortingview
0bb3df40d5d031ec651c4821f928787bbee71fbb
[ "Apache-2.0" ]
2
2021-08-29T20:13:57.000Z
2022-03-12T23:36:34.000Z
from typing import Dict, Union import os import hither2 as hi import kachery_client as kc import numpy as np import spikeextractors as se from sortingview.extractors import LabboxEphysSortingExtractor, LabboxEphysRecordingExtractor from .SubsampledSortingExtractor import SubsampledSortingExtractor from .find_unit_peak...
43.66055
161
0.73713
from typing import Dict, Union import os import hither2 as hi import kachery_client as kc import numpy as np import spikeextractors as se from sortingview.extractors import LabboxEphysSortingExtractor, LabboxEphysRecordingExtractor from .SubsampledSortingExtractor import SubsampledSortingExtractor from .find_unit_peak...
true
true
f75750b3348d7b3f4e6929e0e6ca136fb2a8cdcc
2,237
py
Python
tests/test_session.py
KOLANICH-tools/https-everywhere-py
b25084a2edd875689e4da8876cde611dc7f61a7c
[ "Apache-2.0" ]
7
2020-02-26T00:40:44.000Z
2022-02-11T01:24:55.000Z
tests/test_session.py
KOLANICH-tools/https-everywhere-py
b25084a2edd875689e4da8876cde611dc7f61a7c
[ "Apache-2.0" ]
39
2020-02-25T18:04:22.000Z
2021-04-06T09:57:57.000Z
tests/test_session.py
KOLANICH-tools/https-everywhere-py
b25084a2edd875689e4da8876cde611dc7f61a7c
[ "Apache-2.0" ]
3
2021-04-06T09:50:42.000Z
2021-12-11T22:51:27.000Z
from __future__ import unicode_literals import unittest from https_everywhere.session import HTTPSEverywhereSession class TestRequestsSession(unittest.TestCase): def test_freerangekitten_com(self): url = "http://freerangekitten.com/" s = HTTPSEverywhereSession() r = s.get(url) r....
36.672131
80
0.637014
from __future__ import unicode_literals import unittest from https_everywhere.session import HTTPSEverywhereSession class TestRequestsSession(unittest.TestCase): def test_freerangekitten_com(self): url = "http://freerangekitten.com/" s = HTTPSEverywhereSession() r = s.get(url) r....
true
true
f75753da28d44c0037e864cd7566388422d547c2
6,321
py
Python
tools/ports/cocos2d.py
mehdisadeghi/emscripten
a3e96c3bd4751632de6e9d1d57172ac9429fcb2d
[ "MIT" ]
32
2021-05-03T09:03:57.000Z
2022-03-17T09:18:59.000Z
tools/ports/cocos2d.py
mehdisadeghi/emscripten
a3e96c3bd4751632de6e9d1d57172ac9429fcb2d
[ "MIT" ]
4
2021-05-29T20:42:52.000Z
2022-03-16T03:01:12.000Z
tools/ports/cocos2d.py
mehdisadeghi/emscripten
a3e96c3bd4751632de6e9d1d57172ac9429fcb2d
[ "MIT" ]
1
2021-12-01T18:33:25.000Z
2021-12-01T18:33:25.000Z
# Copyright 2017 The Emscripten Authors. All rights reserved. # Emscripten is available under two separate licenses, the MIT license and the # University of Illinois/NCSA Open Source License. Both these licenses can be # found in the LICENSE file. import os import shutil import logging import re TAG = 'version_3_3'...
39.50625
137
0.639614
import os import shutil import logging import re TAG = 'version_3_3' HASH = 'd7b22660036c684f09754fcbbc7562984f02aa955eef2b76555270c63a717e6672c4fe695afb16280822e8b7c75d4b99ae21975a01a4ed51cad957f7783722cd' deps = ['libpng', 'zlib'] def needed(settings): return settings.USE_COCOS2D == 3 def get(ports, settings...
true
true
f75754cadeeb00213f22b2fdc1a61ebcb5b4c185
573
py
Python
fib.py
gabrieldocs/data-structures-python
5ac4ada715730529b575775ebf37eceeb0a5449a
[ "Apache-2.0" ]
null
null
null
fib.py
gabrieldocs/data-structures-python
5ac4ada715730529b575775ebf37eceeb0a5449a
[ "Apache-2.0" ]
3
2021-04-11T19:38:01.000Z
2021-09-23T19:16:43.000Z
fib.py
gabrieldocs/data-structures-python
5ac4ada715730529b575775ebf37eceeb0a5449a
[ "Apache-2.0" ]
null
null
null
# Testando as funções com otimização para as chamadas recursivas # Realizei uma pequena mudança na estrutura do projeto, adicionando as funções de fibonacci para o formato de módulo from functions.fib_cache import fib_cache from functions.fib_memo import fib_memo if __name__ == "__main__": print("# Fibonacci ...
35.8125
117
0.69808
from functions.fib_cache import fib_cache from functions.fib_memo import fib_memo if __name__ == "__main__": print("# Fibonacci using cache") print(fib_cache(4)) print(fib_cache(8)) print(fib_cache(20)) print(fib_cache(49)) print("# Fibonacci using memoizations") print(fi...
true
true
f757552e01816e29353f4382a9416167b8155912
13,382
py
Python
scrapy/crawler.py
ZhiShiMao/scrapy
04dd29257a81be0b1291db61dd880ef3dd96127d
[ "BSD-3-Clause" ]
null
null
null
scrapy/crawler.py
ZhiShiMao/scrapy
04dd29257a81be0b1291db61dd880ef3dd96127d
[ "BSD-3-Clause" ]
null
null
null
scrapy/crawler.py
ZhiShiMao/scrapy
04dd29257a81be0b1291db61dd880ef3dd96127d
[ "BSD-3-Clause" ]
null
null
null
import logging import pprint import signal import warnings from twisted.internet import defer from zope.interface.exceptions import DoesNotImplement try: # zope >= 5.0 only supports MultipleInvalid from zope.interface.exceptions import MultipleInvalid except ImportError: MultipleInvalid = None from zope....
36.966851
88
0.667688
import logging import pprint import signal import warnings from twisted.internet import defer from zope.interface.exceptions import DoesNotImplement try: from zope.interface.exceptions import MultipleInvalid except ImportError: MultipleInvalid = None from zope.interface.verify import verifyClass from sc...
true
true
f75755498bf70a5337b510d17a0b3d3dc45238f3
6,773
py
Python
fusion_mujoco_py/export.py
bjnortier/fusion-mujoco-py
5df0a0acc72f91a669ee7c7d4d98c5e426b11d56
[ "MIT" ]
null
null
null
fusion_mujoco_py/export.py
bjnortier/fusion-mujoco-py
5df0a0acc72f91a669ee7c7d4d98c5e426b11d56
[ "MIT" ]
null
null
null
fusion_mujoco_py/export.py
bjnortier/fusion-mujoco-py
5df0a0acc72f91a669ee7c7d4d98c5e426b11d56
[ "MIT" ]
1
2021-06-29T02:22:49.000Z
2021-06-29T02:22:49.000Z
# -*- coding: utf-8 -*- import xml.etree.ElementTree as ET import os.path import xml.dom.minidom import re XML_TEMPLATE = """<?xml version="1.0" ?> <mujoco> <compiler angle="radian" coordinate="local" inertiafromgeom="true" settotalmass="14"/> <default> <joint armature=".1" damping=".01" limited="true" solimpl...
43.696774
163
0.627934
import xml.etree.ElementTree as ET import os.path import xml.dom.minidom import re XML_TEMPLATE = """<?xml version="1.0" ?> <mujoco> <compiler angle="radian" coordinate="local" inertiafromgeom="true" settotalmass="14"/> <default> <joint armature=".1" damping=".01" limited="true" solimplimit="0 .8 .03" solrefli...
true
true
f757561a83f5298ba3adadc0e5c83a0e67aefad5
5,070
py
Python
models/preresnet.py
YimiaoSun/network-slimming
8ab3e6932fc3febd893faf83e23bee1aeb28be13
[ "MIT" ]
null
null
null
models/preresnet.py
YimiaoSun/network-slimming
8ab3e6932fc3febd893faf83e23bee1aeb28be13
[ "MIT" ]
null
null
null
models/preresnet.py
YimiaoSun/network-slimming
8ab3e6932fc3febd893faf83e23bee1aeb28be13
[ "MIT" ]
null
null
null
# 本resnet结构选自:https://arxiv.org/pdf/1603.05027.pdf # 是原作者在resnet上的更新版本(实际用的没有原始版本广,认可度有质疑) from __future__ import absolute_import import math import torch.nn as nn from .channel_selection import channel_selection __all__ = ['resnet'] """ preactivation resnet with bottleneck design. """ class Bottleneck(nn.Module):...
34.965517
130
0.569625
from __future__ import absolute_import import math import torch.nn as nn from .channel_selection import channel_selection __all__ = ['resnet'] class Bottleneck(nn.Module): expansion = 4 def __init__(self, inplanes, planes, cfg, stride=1, downsample=None): super(Bottleneck, self).__init_...
true
true
f75756daa5a05c95293c94734c303dfc3b414775
6,694
py
Python
PyProj10_main.py
dknight2/Python
3054e12f2a497d8c5501cd1d86864d5c55a51ded
[ "MIT" ]
null
null
null
PyProj10_main.py
dknight2/Python
3054e12f2a497d8c5501cd1d86864d5c55a51ded
[ "MIT" ]
null
null
null
PyProj10_main.py
dknight2/Python
3054e12f2a497d8c5501cd1d86864d5c55a51ded
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ The purpose of this script is to launch a GUI that prompts the user to select either an option to APPEND or SPLIT a database. The user will then be prompted with what inputs and outputs they desire. No data has been provided for this script, but the user can still run this script to se...
45.22973
177
0.603376
import arcpy import os, sys import PyProj10_gui from PyQt5.QtWidgets import QApplication, QMainWindow, QFileDialog, QMessageBox def runTool(): activeTab = ui.tabWidget.currentWidget() tabHandler[activeTab]() def selectAppendTo(self): global appendTo appendTo = QFileDialog.getExistingD...
true
true
f75757888cf2b8bae4822e3dda03faeb735f8fc4
2,204
py
Python
configs/lane_detection/scnn/resnet50_tusimple.py
voldemortX/DeeplabV3_PyTorch1.3_Codebase
d22d23e74800fafb58eeb61d6649008745c1a287
[ "BSD-3-Clause" ]
1
2020-09-17T06:21:39.000Z
2020-09-17T06:21:39.000Z
configs/lane_detection/scnn/resnet50_tusimple.py
voldemortX/pytorch-segmentation
9c62c0a721d11c8ea6bf312ecf1c7b238a54dcda
[ "BSD-3-Clause" ]
null
null
null
configs/lane_detection/scnn/resnet50_tusimple.py
voldemortX/pytorch-segmentation
9c62c0a721d11c8ea6bf312ecf1c7b238a54dcda
[ "BSD-3-Clause" ]
null
null
null
from importmagician import import_from with import_from('./'): # Data pipeline from configs.lane_detection.common.datasets.tusimple_seg import dataset from configs.lane_detection.common.datasets.train_level0_360 import train_augmentation from configs.lane_detection.common.datasets.test_360 import test_a...
25.627907
90
0.673775
from importmagician import import_from with import_from('./'): from configs.lane_detection.common.datasets.tusimple_seg import dataset from configs.lane_detection.common.datasets.train_level0_360 import train_augmentation from configs.lane_detection.common.datasets.test_360 import test_augmentation ...
true
true
f75758488b41bb35d6f4648d866924906035af77
5,807
py
Python
connector/fixups/probe_bluestacks_hyperv.py
kooWZ/ArknightsAutoHelper
4ccde7e4661b727c20e2df20a2213746a32b1a40
[ "MIT" ]
2
2021-04-12T05:50:05.000Z
2021-04-12T05:50:47.000Z
connector/fixups/probe_bluestacks_hyperv.py
Ketven/ArknightsAutoHelper
0d528b515877ce3b8322d3f9293e5971681d52ba
[ "MIT" ]
null
null
null
connector/fixups/probe_bluestacks_hyperv.py
Ketven/ArknightsAutoHelper
0d528b515877ce3b8322d3f9293e5971681d52ba
[ "MIT" ]
null
null
null
import contextlib import ctypes from rotypes.types import GUID, REFGUID, check_hresult import json # import pprint import logging logger = logging.getLogger(__name__) if __name__ == '__main__': logger.addHandler(logging.StreamHandler(__import__('sys').stderr)) logger.setLevel(logging.DEBUG) try:...
45.724409
144
0.687963
import contextlib import ctypes from rotypes.types import GUID, REFGUID, check_hresult import json import logging logger = logging.getLogger(__name__) if __name__ == '__main__': logger.addHandler(logging.StreamHandler(__import__('sys').stderr)) logger.setLevel(logging.DEBUG) try: HCS_SYSTEM ...
true
true
f757598fe8fa114b4193f16a2a1b26ed6b5bf22c
3,578
py
Python
lib/surface/ai_platform/models/create.py
kustodian/google-cloud-sdk
b6bae4137d4b58030adb3dcb1271216dfb19f96d
[ "Apache-2.0" ]
null
null
null
lib/surface/ai_platform/models/create.py
kustodian/google-cloud-sdk
b6bae4137d4b58030adb3dcb1271216dfb19f96d
[ "Apache-2.0" ]
11
2020-02-29T02:51:12.000Z
2022-03-30T23:20:08.000Z
lib/surface/ai_platform/models/create.py
kustodian/google-cloud-sdk
b6bae4137d4b58030adb3dcb1271216dfb19f96d
[ "Apache-2.0" ]
1
2020-07-24T18:47:35.000Z
2020-07-24T18:47:35.000Z
# -*- coding: utf-8 -*- # # Copyright 2019 Google LLC. 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 requir...
37.663158
80
0.71716
from __future__ import absolute_import from __future__ import division from __future__ import unicode_literals from googlecloudsdk.api_lib.ml_engine import models from googlecloudsdk.calliope import arg_parsers from googlecloudsdk.calliope import base from googlecloudsdk.command_lib.ml_engine import flags from google...
true
true
f7575a56dde0eee34dc5d84ed1be592842d8e174
2,135
py
Python
examples/baselines/rl_discrete/helpers.py
wookayin/acme
71b2ab8577a118c103718f034fa62c5ad2c0fd97
[ "Apache-2.0" ]
null
null
null
examples/baselines/rl_discrete/helpers.py
wookayin/acme
71b2ab8577a118c103718f034fa62c5ad2c0fd97
[ "Apache-2.0" ]
null
null
null
examples/baselines/rl_discrete/helpers.py
wookayin/acme
71b2ab8577a118c103718f034fa62c5ad2c0fd97
[ "Apache-2.0" ]
null
null
null
# Copyright 2018 DeepMind Technologies Limited. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by ...
32.348485
76
0.740047
import functools from acme import specs from acme import wrappers from acme.jax import networks from acme.jax import utils import dm_env import gym import haiku as hk def make_atari_environment( level: str = 'Pong', sticky_actions: bool = True, zero_discount_on_life_loss: bool = False) -> dm_env.Enviro...
true
true
f7575ae367b8e9b729a7ae27d055c0ff406abe8e
1,979
py
Python
python-threatexchange/threatexchange/fetcher/apis/static_sample.py
dxdc/ThreatExchange
f9aff6dd0c90e6c47ffe4151bced4de1676d84f6
[ "BSD-3-Clause" ]
1
2022-02-08T01:32:58.000Z
2022-02-08T01:32:58.000Z
python-threatexchange/threatexchange/fetcher/apis/static_sample.py
Samyakk123/ThreatExchange
447b5e9738aff5d1cc895f6208a0d3bc15a14ebc
[ "BSD-3-Clause" ]
null
null
null
python-threatexchange/threatexchange/fetcher/apis/static_sample.py
Samyakk123/ThreatExchange
447b5e9738aff5d1cc895f6208a0d3bc15a14ebc
[ "BSD-3-Clause" ]
null
null
null
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved """ The fetcher is the component that talks to external APIs to get and put signals @see SignalExchangeAPI """ import typing as t from threatexchange.signal_type.pdq import PdqSignal from threatexchange.signal_type.pdq_ocr import PdqOcrSignal f...
29.984848
86
0.734715
import typing as t from threatexchange.signal_type.pdq import PdqSignal from threatexchange.signal_type.pdq_ocr import PdqOcrSignal from threatexchange.signal_type.md5 import VideoMD5Signal from threatexchange.signal_type.raw_text import RawTextSignal from threatexchange.signal_type.signal_base import SignalType fr...
true
true
f7575b26f8d8c9b9ee566a8e14b492ca1e602018
4,672
py
Python
scripts/unification/can_i_move_out.py
opensource-assist/fuschia
66646c55b3d0b36aae90a4b6706b87f1a6261935
[ "BSD-3-Clause" ]
3
2020-08-02T04:46:18.000Z
2020-08-07T10:10:53.000Z
scripts/unification/can_i_move_out.py
opensource-assist/fuschia
66646c55b3d0b36aae90a4b6706b87f1a6261935
[ "BSD-3-Clause" ]
null
null
null
scripts/unification/can_i_move_out.py
opensource-assist/fuschia
66646c55b3d0b36aae90a4b6706b87f1a6261935
[ "BSD-3-Clause" ]
1
2020-08-07T10:11:49.000Z
2020-08-07T10:11:49.000Z
#!/usr/bin/env python2.7 # Copyright 2019 The Fuchsia Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. import argparse import os import subprocess import sys SCRIPT_DIR = os.path.dirname(os.path.abspath(__file__)) FUCHSIA_ROOT = os.pa...
32
78
0.5625
import argparse import os import subprocess import sys SCRIPT_DIR = os.path.dirname(os.path.abspath(__file__)) FUCHSIA_ROOT = os.path.dirname( os.path.dirname( SCRIPT_DIR)) class Finder(object): def __init__(self, gn_binary, zircon_dir, build_dir): self._zircon_dir...
true
true
f7575bbe28e20ba73f97efc68353c5a8dba48ffe
52,003
bzl
Python
third_party/toolchains/preconfig/ubuntu14.04/gcc-nvcc-cuda10.0/cc_toolchain_config.bzl
abhaikollara/tensorflow
4f96df3659696990cb34d0ad07dc67843c4225a9
[ "Apache-2.0" ]
848
2019-12-03T00:16:17.000Z
2022-03-31T22:53:17.000Z
third_party/toolchains/preconfig/ubuntu14.04/gcc-nvcc-cuda10.0/cc_toolchain_config.bzl
abhaikollara/tensorflow
4f96df3659696990cb34d0ad07dc67843c4225a9
[ "Apache-2.0" ]
656
2019-12-03T00:48:46.000Z
2022-03-31T18:41:54.000Z
third_party/toolchains/preconfig/ubuntu14.04/gcc-nvcc-cuda10.0/cc_toolchain_config.bzl
abhaikollara/tensorflow
4f96df3659696990cb34d0ad07dc67843c4225a9
[ "Apache-2.0" ]
506
2019-12-03T00:46:26.000Z
2022-03-30T10:34:56.000Z
"""cc_toolchain_config rule for configuring CUDA toolchains on Linux, Mac, and Windows.""" load( "@bazel_tools//tools/cpp:cc_toolchain_config_lib.bzl", "action_config", "env_entry", "env_set", "feature", "feature_set", "flag_group", "flag_set", "tool", "tool_path", "variable...
34.995289
106
0.482318
load( "@bazel_tools//tools/cpp:cc_toolchain_config_lib.bzl", "action_config", "env_entry", "env_set", "feature", "feature_set", "flag_group", "flag_set", "tool", "tool_path", "variable_with_value", ) load( "@bazel_tools//tools/build_defs/cc:action_names.bzl", "ASSEMB...
true
true
f7575bd94fddb51c40faad1830b7cf92b7683827
10,972
py
Python
src/datamigration/azext_datamigration/manual/custom.py
Caoxuyang/azure-cli-extensions
d2011261f29033cb31a1064256727d87049ab423
[ "MIT" ]
null
null
null
src/datamigration/azext_datamigration/manual/custom.py
Caoxuyang/azure-cli-extensions
d2011261f29033cb31a1064256727d87049ab423
[ "MIT" ]
9
2022-03-25T19:35:49.000Z
2022-03-31T06:09:47.000Z
src/datamigration/azext_datamigration/manual/custom.py
Caoxuyang/azure-cli-extensions
d2011261f29033cb31a1064256727d87049ab423
[ "MIT" ]
1
2022-02-14T21:43:29.000Z
2022-02-14T21:43:29.000Z
# -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. # # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may cause incor...
46.491525
208
0.545024
import os import signal import subprocess from azure.cli.core.azclierror import MutuallyExclusiveArgumentError from azure.cli.core.azclierror import RequiredArgumentMissingError from azure.cli.core.azclierror import UnclassifiedUserFault from azext_datamigration.manual import helper def datamigration_assessment(conn...
true
true
f7575c788756d97bd8f3c7a75876c6bff1237851
343
py
Python
botoless/__init__.py
beaucronin/botoless
29fc63c3aac799c4f392b90b352d9e50f18748ba
[ "MIT" ]
null
null
null
botoless/__init__.py
beaucronin/botoless
29fc63c3aac799c4f392b90b352d9e50f18748ba
[ "MIT" ]
null
null
null
botoless/__init__.py
beaucronin/botoless
29fc63c3aac799c4f392b90b352d9e50f18748ba
[ "MIT" ]
null
null
null
from .core import resource, client from .util import full_name from .sqs import ( get_queue as sqs_get_queue ) from .s3 import ( get_bucket as s3_get_bucket, get_object as s3_get_object, put_object as s3_put_object ) from .dynamodb import ( put_item as dynamodb_put_item, increment_field as dyna...
21.4375
47
0.760933
from .core import resource, client from .util import full_name from .sqs import ( get_queue as sqs_get_queue ) from .s3 import ( get_bucket as s3_get_bucket, get_object as s3_get_object, put_object as s3_put_object ) from .dynamodb import ( put_item as dynamodb_put_item, increment_field as dyna...
true
true
f7575cd4abeaf7b6f4feaf0e229126ba2a2ab585
1,132
py
Python
context_managers.py
Stihotvor/python3_magic_method_examples
a23940833480eb08f25452062717a7ef9fe39911
[ "MIT" ]
null
null
null
context_managers.py
Stihotvor/python3_magic_method_examples
a23940833480eb08f25452062717a7ef9fe39911
[ "MIT" ]
null
null
null
context_managers.py
Stihotvor/python3_magic_method_examples
a23940833480eb08f25452062717a7ef9fe39911
[ "MIT" ]
null
null
null
class Vessel: def __init__(self, name: str): """ Initializing class instance with vessel name :param name: """ self.name = name self.fuel = 0.0 # list of dicts with passenger attributes self.passengers = [] def __enter__(self): """ ...
24.085106
116
0.578622
class Vessel: def __init__(self, name: str): self.name = name self.fuel = 0.0 self.passengers = [] def __enter__(self): return self def __exit__(self, exc_type, exc_val, exc_tb): pass def pump_in_fuel(self, quantity: float): self.fuel += qu...
true
true
f7575d591b3304fc14ca1b2d86b279640a95ab41
42,953
py
Python
ibis/expr/tests/test_value_exprs.py
amroid/ibis
e156a05e0069d0c9763539874c4064973c320063
[ "Apache-2.0" ]
null
null
null
ibis/expr/tests/test_value_exprs.py
amroid/ibis
e156a05e0069d0c9763539874c4064973c320063
[ "Apache-2.0" ]
1
2019-08-30T16:10:24.000Z
2019-08-30T17:51:01.000Z
ibis/expr/tests/test_value_exprs.py
costrouc/ibis
9df27958f305a901728b540200bd8fa2820d4625
[ "Apache-2.0" ]
null
null
null
import functools import operator import os from collections import OrderedDict from datetime import date, datetime, time from operator import methodcaller import numpy as np import pandas as pd import pytest import toolz import ibis import ibis.common.exceptions as com import ibis.expr.analysis as L import ibis.expr....
27.289072
79
0.60962
import functools import operator import os from collections import OrderedDict from datetime import date, datetime, time from operator import methodcaller import numpy as np import pandas as pd import pytest import toolz import ibis import ibis.common.exceptions as com import ibis.expr.analysis as L import ibis.expr....
true
true
f7575d95889fb58b2e8b450528f6fe3e21b3de3f
1,563
py
Python
Task1/module/classifier.py
KKowalewski24/ADZ
8a04570a1f6f08506572386b2312a259a8308f56
[ "MIT" ]
null
null
null
Task1/module/classifier.py
KKowalewski24/ADZ
8a04570a1f6f08506572386b2312a259a8308f56
[ "MIT" ]
null
null
null
Task1/module/classifier.py
KKowalewski24/ADZ
8a04570a1f6f08506572386b2312a259a8308f56
[ "MIT" ]
null
null
null
from typing import List, Tuple from skmultiflow.data import FileStream from skmultiflow.drift_detection.base_drift_detector import BaseDriftDetector from skmultiflow.lazy import KNNClassifier from tqdm import tqdm def classify( detector: BaseDriftDetector, dataset: FileStream, window_size: int ) -> Tuple[Lis...
33.255319
89
0.641075
from typing import List, Tuple from skmultiflow.data import FileStream from skmultiflow.drift_detection.base_drift_detector import BaseDriftDetector from skmultiflow.lazy import KNNClassifier from tqdm import tqdm def classify( detector: BaseDriftDetector, dataset: FileStream, window_size: int ) -> Tuple[Lis...
true
true
f757606c2f660f7cc0fd142ce5bb9fdf1b23e8e7
13,570
py
Python
code/generator/Model_new.py
NamiKaze7/FinQA
cf61ae2611ae205b62574e2b4264cb0318dd7202
[ "MIT" ]
69
2021-05-13T22:36:26.000Z
2022-03-29T11:02:07.000Z
code/generator/Model_new.py
NamiKaze7/FinQA
cf61ae2611ae205b62574e2b4264cb0318dd7202
[ "MIT" ]
1
2022-02-15T03:07:08.000Z
2022-02-15T03:07:08.000Z
code/generator/Model_new.py
NamiKaze7/FinQA
cf61ae2611ae205b62574e2b4264cb0318dd7202
[ "MIT" ]
3
2021-09-08T03:05:21.000Z
2021-11-15T03:10:38.000Z
import torch from torch import nn import torch.optim as optim import torch.nn.functional as F import math import numpy as np from config import parameters as conf if conf.pretrained_model == "bert": from transformers import BertModel elif conf.pretrained_model == "roberta": from transformers import RobertaMode...
42.012384
119
0.624024
import torch from torch import nn import torch.optim as optim import torch.nn.functional as F import math import numpy as np from config import parameters as conf if conf.pretrained_model == "bert": from transformers import BertModel elif conf.pretrained_model == "roberta": from transformers import RobertaMode...
true
true
f757615000ce327046ccbf239a27a106cdf6b0d2
2,096
py
Python
encryption/src/pkcs1_c/exceptions.py
hivesolutions/colony_plugins
cfd8fb2ac58037e01002966704b8a642feb37895
[ "Apache-1.1" ]
1
2016-10-30T09:51:06.000Z
2016-10-30T09:51:06.000Z
encryption/src/pkcs1_c/exceptions.py
hivesolutions/colony_plugins
cfd8fb2ac58037e01002966704b8a642feb37895
[ "Apache-1.1" ]
1
2015-12-29T18:51:07.000Z
2015-12-29T18:51:07.000Z
encryption/src/pkcs1_c/exceptions.py
hivesolutions/colony_plugins
cfd8fb2ac58037e01002966704b8a642feb37895
[ "Apache-1.1" ]
1
2018-01-26T12:54:13.000Z
2018-01-26T12:54:13.000Z
#!/usr/bin/python # -*- coding: utf-8 -*- # Hive Colony Framework # Copyright (c) 2008-2020 Hive Solutions Lda. # # This file is part of Hive Colony Framework. # # Hive Colony Framework is free software: you can redistribute it and/or modify # it under the terms of the Apache License as published by the Apach...
27.946667
80
0.65458
__author__ = "João Magalhães <joamag@hive.pt>" __version__ = "1.0.0" __revision__ = "$LastChangedRevision$" __date__ = "$LastChangedDate$" __copyright__ = "Copyright (c) 2008-2020 Hive Solutions Lda." __license__ = "Apache License, Version 2.0" import colony class PKCS1Exception(colony.ColonyEx...
true
true
f75762765570ec5d69d369ffd0448170d4ee0092
2,910
py
Python
tests/integration/api/v2010/account/available_phone_number/test_machine_to_machine.py
BrimmingDev/twilio-python
3226b5fed92b3c2ce64f03e6b19fc4792ef7647f
[ "MIT" ]
1,362
2015-01-04T10:25:18.000Z
2022-03-24T10:07:08.000Z
tests/integration/api/v2010/account/available_phone_number/test_machine_to_machine.py
BrimmingDev/twilio-python
3226b5fed92b3c2ce64f03e6b19fc4792ef7647f
[ "MIT" ]
299
2015-01-30T09:52:39.000Z
2022-03-31T23:03:02.000Z
tests/integration/api/v2010/account/available_phone_number/test_machine_to_machine.py
BrimmingDev/twilio-python
3226b5fed92b3c2ce64f03e6b19fc4792ef7647f
[ "MIT" ]
622
2015-01-03T04:43:09.000Z
2022-03-29T14:11:00.000Z
# coding=utf-8 r""" This code was generated by \ / _ _ _| _ _ | (_)\/(_)(_|\/| |(/_ v1.0.0 / / """ from tests import IntegrationTestCase from tests.holodeck import Request from twilio.base.exceptions import TwilioException from twilio.http.response import Response class MachineToMachineTestCase(...
35.060241
139
0.489347
from tests import IntegrationTestCase from tests.holodeck import Request from twilio.base.exceptions import TwilioException from twilio.http.response import Response class MachineToMachineTestCase(IntegrationTestCase): def test_list_request(self): self.holodeck.mock(Response(500, '')) with self...
true
true
f7576299c5cb220dd414ef593b2311930d25e152
3,939
py
Python
model_inception_v2_67class.py
anishvaidya/MIT-Indoor-Scene-Recognition
04b2c35b25996d420c6fe90c480b86635f3baffd
[ "MIT" ]
4
2019-10-30T01:44:04.000Z
2020-07-09T15:28:37.000Z
model_inception_v2_67class.py
anishvaidya/MIT-Indoor-Scene-Recognition
04b2c35b25996d420c6fe90c480b86635f3baffd
[ "MIT" ]
1
2020-08-04T08:33:22.000Z
2020-08-04T08:33:22.000Z
model_inception_v2_67class.py
anishvaidya/MIT-Indoor-Scene-Recognition
04b2c35b25996d420c6fe90c480b86635f3baffd
[ "MIT" ]
1
2019-10-30T02:06:13.000Z
2019-10-30T02:06:13.000Z
# -*- coding: utf-8 -*- import numpy as np import pandas as pd import imageio import skimage import skimage.io import skimage.transform from keras.models import Sequential from keras.layers import Conv2D from keras.layers import MaxPooling2D from keras.layers import Flatten from keras.layers import Dense from keras.lay...
32.825
204
0.761361
import numpy as np import pandas as pd import imageio import skimage import skimage.io import skimage.transform from keras.models import Sequential from keras.layers import Conv2D from keras.layers import MaxPooling2D from keras.layers import Flatten from keras.layers import Dense from keras.layers import Dropout from ...
true
true
f75762b924521525f4021f3b763ca69aadc65607
178
py
Python
src/Python/01_Interakcja_z_konsola/Zad1.py
djeada/Nauka-programowania
b1eb6840c15b830acf552f0a0fc5cc692759152f
[ "MIT" ]
3
2020-09-19T21:38:30.000Z
2022-03-30T11:02:26.000Z
src/Python/01_Interakcja_z_konsola/Zad1.py
djeada/Nauka-programowania
b1eb6840c15b830acf552f0a0fc5cc692759152f
[ "MIT" ]
null
null
null
src/Python/01_Interakcja_z_konsola/Zad1.py
djeada/Nauka-programowania
b1eb6840c15b830acf552f0a0fc5cc692759152f
[ "MIT" ]
1
2022-02-04T09:13:20.000Z
2022-02-04T09:13:20.000Z
if __name__ == "__main__": """ Wypisz na konsole swoje inicjaly. """ print("A.D.") """ Wypisz na konsole "witaj swiecie" """ print("Witaj swiecie")
12.714286
37
0.544944
if __name__ == "__main__": print("A.D.") print("Witaj swiecie")
true
true
f75763117fc9b7e39b63662a1e2293e166bb5cff
8,324
py
Python
pyleecan/Classes/OptiSolver.py
mxgnsr/pyleecan
2b0a04e4ae67c073a91362ab42332908fef53bdd
[ "Apache-2.0" ]
2
2019-06-08T15:04:39.000Z
2020-09-07T13:32:22.000Z
pyleecan/Classes/OptiSolver.py
mxgnsr/pyleecan
2b0a04e4ae67c073a91362ab42332908fef53bdd
[ "Apache-2.0" ]
null
null
null
pyleecan/Classes/OptiSolver.py
mxgnsr/pyleecan
2b0a04e4ae67c073a91362ab42332908fef53bdd
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # File generated according to Generator/ClassesRef/Optimization/OptiSolver.csv # WARNING! All changes made in this file will be lost! """Method code available at https://github.com/Eomys/pyleecan/tree/master/pyleecan/Methods/Optimization/OptiSolver """ from os import linesep from logging import...
32.901186
114
0.606439
from os import linesep from logging import getLogger from ._check import check_var, raise_ from ..Functions.get_logger import get_logger from ..Functions.save import save from ._frozen import FrozenClass from ._check import InitUnKnowClassError from .OptiProblem import OptiProblem from .XOutput import XOutput class...
true
true
f7576313bc6cb36305816228de43cb5c3d7d8985
15,663
py
Python
topdown_coco_tiny_dataset.py
veritaass/pig_mmdet
6bb348a002695e83b2f16b84173ce0aebbb20e60
[ "Apache-2.0" ]
null
null
null
topdown_coco_tiny_dataset.py
veritaass/pig_mmdet
6bb348a002695e83b2f16b84173ce0aebbb20e60
[ "Apache-2.0" ]
null
null
null
topdown_coco_tiny_dataset.py
veritaass/pig_mmdet
6bb348a002695e83b2f16b84173ce0aebbb20e60
[ "Apache-2.0" ]
null
null
null
import json import os import os.path as osp #from collections import OrderedDict import tempfile import numpy as np from mmpose.core.evaluation.top_down_eval import (keypoint_nme, keypoint_pck_accuracy) from mmpose.datasets.builder import DATASETS from mmpose.datasets...
35.678815
106
0.546447
import json import os import os.path as osp import tempfile import numpy as np from mmpose.core.evaluation.top_down_eval import (keypoint_nme, keypoint_pck_accuracy) from mmpose.datasets.builder import DATASETS from mmpose.datasets.datasets.base import Kpt2dSviewRgbIm...
true
true
f757663a3ef34b8fd343b2fdc97e825418c77e4f
112
py
Python
poolink_backend/apps/category/apps.py
jaethewiederholen/Poolink_backend
3a1b28856bc8916aedb7735de8b64fef3269ef1b
[ "MIT" ]
null
null
null
poolink_backend/apps/category/apps.py
jaethewiederholen/Poolink_backend
3a1b28856bc8916aedb7735de8b64fef3269ef1b
[ "MIT" ]
null
null
null
poolink_backend/apps/category/apps.py
jaethewiederholen/Poolink_backend
3a1b28856bc8916aedb7735de8b64fef3269ef1b
[ "MIT" ]
null
null
null
from django.apps import AppConfig class CategoryConfig(AppConfig): name = 'poolink_backend.apps.category'
18.666667
42
0.785714
from django.apps import AppConfig class CategoryConfig(AppConfig): name = 'poolink_backend.apps.category'
true
true
f757669e152dc4012cbc51e8e194e9bdb24e216f
281
py
Python
tests/parse/test_get_sprite_names.py
GSE-CCL/scratch-tools
4c17e671cf7f3493f04981a468b0afe9489bf403
[ "MIT" ]
null
null
null
tests/parse/test_get_sprite_names.py
GSE-CCL/scratch-tools
4c17e671cf7f3493f04981a468b0afe9489bf403
[ "MIT" ]
9
2020-04-17T02:41:49.000Z
2020-07-07T15:38:27.000Z
tests/parse/test_get_sprite_names.py
GSE-CCL/scratch-scrape
4c17e671cf7f3493f04981a468b0afe9489bf403
[ "MIT" ]
null
null
null
import pytest def test_get_sprite_names_nodata(parser): result = parser.get_sprite_names(dict()) assert result == False def test_get_sprite(parser, full_sb3): result = parser.get_sprite_names(full_sb3) assert type(result) == list assert result == ["Scratch"]
25.545455
46
0.729537
import pytest def test_get_sprite_names_nodata(parser): result = parser.get_sprite_names(dict()) assert result == False def test_get_sprite(parser, full_sb3): result = parser.get_sprite_names(full_sb3) assert type(result) == list assert result == ["Scratch"]
true
true
f75766e51819af6fef05c1bd1c21c32fef49cd50
152
py
Python
rq/version.py
mdawar/rq
0dd9ff0ec9a91e5a81cd5a30651287cad32f8ab0
[ "BSD-2-Clause-FreeBSD" ]
null
null
null
rq/version.py
mdawar/rq
0dd9ff0ec9a91e5a81cd5a30651287cad32f8ab0
[ "BSD-2-Clause-FreeBSD" ]
null
null
null
rq/version.py
mdawar/rq
0dd9ff0ec9a91e5a81cd5a30651287cad32f8ab0
[ "BSD-2-Clause-FreeBSD" ]
null
null
null
# -*- coding: utf-8 -*- from __future__ import (absolute_import, division, print_function, unicode_literals) VERSION = '1.3.0'
25.333333
66
0.611842
from __future__ import (absolute_import, division, print_function, unicode_literals) VERSION = '1.3.0'
true
true
f75767910da0c05da7dc64eb872127a0f93717d6
15,761
py
Python
internals/processes.py
liamnewmarch/chromium-dashboard
0e10b98554a85bd8edb7c61f8fa0494821fe005f
[ "Apache-2.0" ]
450
2015-01-31T03:16:15.000Z
2022-03-25T14:03:26.000Z
internals/processes.py
nirajbhutada/chromium-dashboard
6fcec787cad34350b50806f7ffde4238942d7ec3
[ "Apache-2.0" ]
1,336
2015-01-16T21:41:33.000Z
2022-03-30T16:28:24.000Z
internals/processes.py
prashantpandey9/chromium-dashboard
0aa2b3cfc9c44a6f19dec7657346809369569b17
[ "Apache-2.0" ]
314
2015-01-28T00:17:45.000Z
2022-03-28T05:09:46.000Z
# -*- coding: utf-8 -*- # Copyright 2020 Google 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...
31.904858
79
0.664615
import collections from internals import approval_defs from internals import models Process = collections.namedtuple( 'Process', 'name, description, applicability, stages') ProcessStage = collections.namedtuple( 'ProcessStage', 'name, description, progress_items, actions, approvals, ' 'inco...
true
true
f7576830c24073e35f6787146ce5bb39c2a8f446
1,705
py
Python
core/gabor.py
guilhermealvess/emotions
a65df8f44a9ff4c25421e4b5bf8dc5d918dbd38c
[ "MIT" ]
null
null
null
core/gabor.py
guilhermealvess/emotions
a65df8f44a9ff4c25421e4b5bf8dc5d918dbd38c
[ "MIT" ]
null
null
null
core/gabor.py
guilhermealvess/emotions
a65df8f44a9ff4c25421e4b5bf8dc5d918dbd38c
[ "MIT" ]
1
2019-01-12T13:17:31.000Z
2019-01-12T13:17:31.000Z
import numpy as np from skimage.filters import gabor_kernel import cv2 class KernelParams: def __init__(self, wavelength, orientation): self.wavelength = wavelength self.orientation = orientation def __hash__(self): return hash((self.wavelength, self.orientation)) def __eq__(se...
34.1
72
0.590029
import numpy as np from skimage.filters import gabor_kernel import cv2 class KernelParams: def __init__(self, wavelength, orientation): self.wavelength = wavelength self.orientation = orientation def __hash__(self): return hash((self.wavelength, self.orientation)) def __eq__(se...
true
true
f757696a93617909af6d6d4e4a9a90d31ce34fb4
795
py
Python
kivy_ios/recipes/pyasn1-modules/__init__.py
lbryio/kivy-ios
7bcd073d97bdd13663a759592d37fadbfbb71ca2
[ "MIT" ]
1
2019-10-03T12:42:38.000Z
2019-10-03T12:42:38.000Z
kivy_ios/recipes/pyasn1-modules/__init__.py
lbryio/kivy-ios
7bcd073d97bdd13663a759592d37fadbfbb71ca2
[ "MIT" ]
null
null
null
kivy_ios/recipes/pyasn1-modules/__init__.py
lbryio/kivy-ios
7bcd073d97bdd13663a759592d37fadbfbb71ca2
[ "MIT" ]
null
null
null
from kivy_ios.toolchain import PythonRecipe, shprint from os.path import join import sh, os class Pyasn1ModulesRecipe(PythonRecipe): version = "0.2.1" url = "https://pypi.python.org/packages/source/p/pyasn1-modules/pyasn1-modules-{version}.tar.gz" depends = ["python", "pyasn1"] def install(self): ...
37.857143
100
0.675472
from kivy_ios.toolchain import PythonRecipe, shprint from os.path import join import sh, os class Pyasn1ModulesRecipe(PythonRecipe): version = "0.2.1" url = "https://pypi.python.org/packages/source/p/pyasn1-modules/pyasn1-modules-{version}.tar.gz" depends = ["python", "pyasn1"] def install(self): ...
true
true
f75769940b77c7998fb82d62cd7f453197182b16
1,432
py
Python
3. Generate TV scripts/helper.py
mihir135/deep_learning_nanodegree
018bf9228d72a8c0580eb82070223cf5225ffd4a
[ "MIT" ]
null
null
null
3. Generate TV scripts/helper.py
mihir135/deep_learning_nanodegree
018bf9228d72a8c0580eb82070223cf5225ffd4a
[ "MIT" ]
null
null
null
3. Generate TV scripts/helper.py
mihir135/deep_learning_nanodegree
018bf9228d72a8c0580eb82070223cf5225ffd4a
[ "MIT" ]
1
2022-02-07T10:24:22.000Z
2022-02-07T10:24:22.000Z
import os import pickle import torch SPECIAL_WORDS = {'PADDING': '<PAD>'} def load_data(path): """ Load Dataset from File """ input_file = os.path.join(path) with open(input_file, "r") as f: data = f.read() return data def preprocess_and_save_data(dataset_path, token_lookup, creat...
25.122807
95
0.671089
import os import pickle import torch SPECIAL_WORDS = {'PADDING': '<PAD>'} def load_data(path): input_file = os.path.join(path) with open(input_file, "r") as f: data = f.read() return data def preprocess_and_save_data(dataset_path, token_lookup, create_lookup_tables): text = load_data(data...
true
true
f75769c47022def6b8ed5be6d0727e31cfb9f55a
1,606
py
Python
setup.py
gaqzi/django-emoji
e9cef5ed9baa00da8ee79a5cfb51aacde462bdff
[ "MIT" ]
78
2015-02-10T15:22:38.000Z
2022-01-08T09:02:08.000Z
setup.py
skorokithakis/django-emoji
901810b1ad34cc4e2215079bd96b496e1d69dc84
[ "MIT" ]
17
2015-04-26T14:07:15.000Z
2021-07-21T10:32:01.000Z
setup.py
skorokithakis/django-emoji
901810b1ad34cc4e2215079bd96b496e1d69dc84
[ "MIT" ]
19
2015-02-14T00:42:38.000Z
2021-01-23T18:26:01.000Z
# encoding: utf-8 import os from setuptools import setup, find_packages readme_file = os.path.join(os.path.dirname(__file__), 'README.rst') README = None try: f = open(readme_file, encoding='utf-8') except TypeError: f = open(readme_file) README = f.read() f.close() os.chdir(os.path.normpath(os.path.join(os...
29.740741
78
0.617684
import os from setuptools import setup, find_packages readme_file = os.path.join(os.path.dirname(__file__), 'README.rst') README = None try: f = open(readme_file, encoding='utf-8') except TypeError: f = open(readme_file) README = f.read() f.close() os.chdir(os.path.normpath(os.path.join(os.path.abspath(__fi...
true
true
f75769cd90b2fa3673c26636d22ab94fd49c3ce1
3,877
py
Python
sources_from_mxshop/MxShop-django/apps/users/migrations/0001_initial.py
yangtao4389/similal_taobao
90a71c55bbbaffa9776e8460d0752374a674e0ad
[ "Apache-2.0" ]
1
2019-03-05T02:22:56.000Z
2019-03-05T02:22:56.000Z
apps/users/migrations/0001_initial.py
linrong/FruitSupermarket
c69e5a2590ab4e6bcdad7a52b68d8ebcfecb3ad9
[ "MIT" ]
16
2020-06-05T20:13:57.000Z
2022-03-11T23:44:03.000Z
apps/users/migrations/0001_initial.py
linrong/FruitSupermarket
c69e5a2590ab4e6bcdad7a52b68d8ebcfecb3ad9
[ "MIT" ]
null
null
null
# Generated by Django 2.0.2 on 2018-02-13 11:39 import datetime import django.contrib.auth.models import django.contrib.auth.validators from django.db import migrations, models import django.utils.timezone class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0009_alter_u...
62.532258
329
0.637864
import datetime import django.contrib.auth.models import django.contrib.auth.validators from django.db import migrations, models import django.utils.timezone class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0009_alter_user_last_name_max_length'), ] operation...
true
true
f75769d605fed212df37756d451afe252eff0914
13,393
py
Python
sandbox/grist/functions/test_schedule.py
combinatorist/grist-core
9a6369a4ff2ebe9f0ad477cd43b90fb2b8341b36
[ "Apache-2.0" ]
null
null
null
sandbox/grist/functions/test_schedule.py
combinatorist/grist-core
9a6369a4ff2ebe9f0ad477cd43b90fb2b8341b36
[ "Apache-2.0" ]
null
null
null
sandbox/grist/functions/test_schedule.py
combinatorist/grist-core
9a6369a4ff2ebe9f0ad477cd43b90fb2b8341b36
[ "Apache-2.0" ]
null
null
null
from datetime import date, datetime, timedelta import os import timeit import unittest import moment import schedule from functions.date import DTIME from functions import date as _date DT = DTIME TICK = timedelta.resolution _orig_global_tz_getter = None class TestSchedule(unittest.TestCase): def assertDate(self,...
49.420664
98
0.674979
from datetime import date, datetime, timedelta import os import timeit import unittest import moment import schedule from functions.date import DTIME from functions import date as _date DT = DTIME TICK = timedelta.resolution _orig_global_tz_getter = None class TestSchedule(unittest.TestCase): def assertDate(self,...
false
true
f7576a2bd8ab0b077a9f85626f16d6a3e209f41f
12,921
py
Python
sdk/python/pulumi_google_native/compute/v1/get_machine_image.py
AaronFriel/pulumi-google-native
75d1cda425e33d4610348972cd70bddf35f1770d
[ "Apache-2.0" ]
44
2021-04-18T23:00:48.000Z
2022-02-14T17:43:15.000Z
sdk/python/pulumi_google_native/compute/v1/get_machine_image.py
AaronFriel/pulumi-google-native
75d1cda425e33d4610348972cd70bddf35f1770d
[ "Apache-2.0" ]
354
2021-04-16T16:48:39.000Z
2022-03-31T17:16:39.000Z
sdk/python/pulumi_google_native/compute/v1/get_machine_image.py
AaronFriel/pulumi-google-native
75d1cda425e33d4610348972cd70bddf35f1770d
[ "Apache-2.0" ]
8
2021-04-24T17:46:51.000Z
2022-01-05T10:40:21.000Z
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi SDK Generator. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union, overload from ... import _utilities fro...
48.575188
648
0.698862
import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union, overload from ... import _utilities from . import outputs __all__ = [ 'GetMachineImageResult', 'AwaitableGetMachineImageResult', 'get_machine_image', 'get_machine_image_output', ] @pulumi.o...
true
true
f7576ab0f3e6e338a73b8d881082ee260d0c3dda
2,710
py
Python
setup.py
martingu11/endas
e58be74e844efa14cbd86aba5e76dbc44fe690de
[ "MIT" ]
1
2020-05-13T13:14:09.000Z
2020-05-13T13:14:09.000Z
setup.py
martingu11/endas
e58be74e844efa14cbd86aba5e76dbc44fe690de
[ "MIT" ]
16
2020-07-13T14:51:01.000Z
2020-07-14T08:59:16.000Z
setup.py
martingu11/endas
e58be74e844efa14cbd86aba5e76dbc44fe690de
[ "MIT" ]
1
2020-03-18T10:37:45.000Z
2020-03-18T10:37:45.000Z
import sys import os.path from setuptools import setup, Extension, find_packages if sys.version_info[:2] < (3, 6): raise RuntimeError("Python >= 3.6 required.") CYTHON_REBUILD = False CYTHON_ANNOTATE = True RTD_BUILD = 'READTHEDOCS' in os.environ # Extra arguments to setup.py install/build/build_ext # This is ...
33.875
109
0.682657
import sys import os.path from setuptools import setup, Extension, find_packages if sys.version_info[:2] < (3, 6): raise RuntimeError("Python >= 3.6 required.") CYTHON_REBUILD = False CYTHON_ANNOTATE = True RTD_BUILD = 'READTHEDOCS' in os.environ if "--cython-rebuild" in sys.argv: sys.argv.remove("--cytho...
true
true
f7576e2f39260a576f93dfb1948bd6a6a0dc6aaa
3,096
py
Python
{{cookiecutter.out_dir}}/src/{{cookiecutter.flask_project_name}}/{{cookiecutter.flask_settings_name}}/base.py
corpusops/cookiecutter-flask
9b1bce6852a45c5803e4b69fbf5b0e39fcb1b209
[ "BSD-3-Clause" ]
null
null
null
{{cookiecutter.out_dir}}/src/{{cookiecutter.flask_project_name}}/{{cookiecutter.flask_settings_name}}/base.py
corpusops/cookiecutter-flask
9b1bce6852a45c5803e4b69fbf5b0e39fcb1b209
[ "BSD-3-Clause" ]
null
null
null
{{cookiecutter.out_dir}}/src/{{cookiecutter.flask_project_name}}/{{cookiecutter.flask_settings_name}}/base.py
corpusops/cookiecutter-flask
9b1bce6852a45c5803e4b69fbf5b0e39fcb1b209
[ "BSD-3-Clause" ]
null
null
null
# # Local postgis database with local user as the same name as the data base # import os import six # Nothing to define in the settings globs = globals() DEFAULT_SETTINGS = { # Database over a network interface 'POSTGRES_HOST': 'localhost', 'POSTGRES_PORT': 5432, 'POSTGRES_DB': 'db', 'POSTGRES_U...
28.145455
129
0.603682
import os import six globs = globals() DEFAULT_SETTINGS = { 'POSTGRES_HOST': 'localhost', 'POSTGRES_PORT': 5432, 'POSTGRES_DB': 'db', 'POSTGRES_USER': 'user', 'POSTGRES_PASSWORD': 'password', 'SRID': 2154, 'SECRET_KEY': 'supercret', {% if cookiecutter.with_celery %} '...
false
true
f7576e5cb936178d327d879eca622cd5d87b764d
15,957
py
Python
zhaquirks/xiaomi/__init__.py
grea09/zha-device-handlers
6b06af789bd8a97c42a24bd05c370ecfadd6f363
[ "Apache-2.0" ]
null
null
null
zhaquirks/xiaomi/__init__.py
grea09/zha-device-handlers
6b06af789bd8a97c42a24bd05c370ecfadd6f363
[ "Apache-2.0" ]
null
null
null
zhaquirks/xiaomi/__init__.py
grea09/zha-device-handlers
6b06af789bd8a97c42a24bd05c370ecfadd6f363
[ "Apache-2.0" ]
null
null
null
"""Xiaomi common components for custom device handlers.""" import asyncio import binascii import logging from zigpy import types as t from zigpy.quirks import CustomCluster, CustomDevice from zigpy.zcl.clusters.general import AnalogInput, Basic, PowerConfiguration from zigpy.zcl.clusters.homeautomation import Electric...
34.68913
112
0.628188
import asyncio import binascii import logging from zigpy import types as t from zigpy.quirks import CustomCluster, CustomDevice from zigpy.zcl.clusters.general import AnalogInput, Basic, PowerConfiguration from zigpy.zcl.clusters.homeautomation import ElectricalMeasurement from zigpy.zcl.clusters.measurement import ( ...
true
true
f7576f18849f9b35b7457c4ef227f79ab971a3c6
1,056
py
Python
iqmon/primitives/__init__.py
joshwalawender/IQMon
d6b7df9f489b94a197e4faeb53785f3f30d248df
[ "BSD-2-Clause" ]
9
2017-08-04T04:02:52.000Z
2021-03-15T23:01:04.000Z
iqmon/primitives/__init__.py
joshwalawender/IQMon
d6b7df9f489b94a197e4faeb53785f3f30d248df
[ "BSD-2-Clause" ]
9
2022-01-10T03:04:44.000Z
2022-01-10T03:04:46.000Z
iqmon/primitives/__init__.py
joshwalawender/IQMon
d6b7df9f489b94a197e4faeb53785f3f30d248df
[ "BSD-2-Clause" ]
5
2015-07-01T00:46:21.000Z
2018-11-19T11:05:24.000Z
##----------------------------------------------------------------------------- ## Primitive: Template ##----------------------------------------------------------------------------- # class Template(BasePrimitive): # """ # """ # def __init__(self, action, context): # BasePrimitive.__init__(self, ac...
31.058824
79
0.47822
# """ # Check for conditions necessary to verify that the process ran # correctly. # """ # Returns an Argument() with the parameters that depend on this # operation. # """
true
true
f7576fcf692a7e88a5785f536ee99368ee8f3c6d
19,252
py
Python
MalmoEnv/malmoenv/core.py
HumanCompatibleAI/malmo
147dad058c00574e57205833159decc91c8adfd1
[ "MIT" ]
null
null
null
MalmoEnv/malmoenv/core.py
HumanCompatibleAI/malmo
147dad058c00574e57205833159decc91c8adfd1
[ "MIT" ]
null
null
null
MalmoEnv/malmoenv/core.py
HumanCompatibleAI/malmo
147dad058c00574e57205833159decc91c8adfd1
[ "MIT" ]
null
null
null
# ------------------------------------------------------------------------------------------------ # Copyright (c) 2018 Microsoft Corporation # # 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 ...
39.613169
116
0.561448
from lxml import etree import struct import socket import time import random import numpy as np from malmoenv import comms from malmoenv.commands import CommandParser import uuid import gym.spaces from malmoenv.comms import retry from malmoenv.version import malmo_version class StringActionSpace(gym.spaces.Discrete)...
true
true
f75770208934e81937789e433291a1afcd2541f0
748
py
Python
station.py
mrpjevans/retroradio
a18e8da33787db6b9641e7fb3e274055dffeabf6
[ "MIT" ]
null
null
null
station.py
mrpjevans/retroradio
a18e8da33787db6b9641e7fb3e274055dffeabf6
[ "MIT" ]
null
null
null
station.py
mrpjevans/retroradio
a18e8da33787db6b9641e7fb3e274055dffeabf6
[ "MIT" ]
null
null
null
import time class Station: duration = 100 file = "" launch_time = 0 special = False special_active = False name = "" def __init__(self, playlist_item): self.file = playlist_item['file'] self.duration = playlist_item['duration'] self.special = playlist_item['special'] if 'special' in playlist...
27.703704
84
0.685829
import time class Station: duration = 100 file = "" launch_time = 0 special = False special_active = False name = "" def __init__(self, playlist_item): self.file = playlist_item['file'] self.duration = playlist_item['duration'] self.special = playlist_item['special'] if 'special' in playlist...
true
true
f75770e26743a2b591900fcb9c2ce8e1d65a4d3d
62,964
py
Python
openmc/filter.py
ThompsonJ314/openmc
173c85c2cbb1784e49edf51d2d379a0f981de4e3
[ "MIT" ]
null
null
null
openmc/filter.py
ThompsonJ314/openmc
173c85c2cbb1784e49edf51d2d379a0f981de4e3
[ "MIT" ]
null
null
null
openmc/filter.py
ThompsonJ314/openmc
173c85c2cbb1784e49edf51d2d379a0f981de4e3
[ "MIT" ]
null
null
null
from abc import ABCMeta from collections import OrderedDict from collections.abc import Iterable import hashlib from itertools import product from numbers import Real, Integral from xml.etree import ElementTree as ET import numpy as np import pandas as pd import openmc import openmc.checkvalue as cv from .cell import...
33.156398
81
0.59345
from abc import ABCMeta from collections import OrderedDict from collections.abc import Iterable import hashlib from itertools import product from numbers import Real, Integral from xml.etree import ElementTree as ET import numpy as np import pandas as pd import openmc import openmc.checkvalue as cv from .cell import...
true
true
f75771ad57a066252876ecec99fdc88f0cd48092
565
py
Python
ABC/m-solutions2020/B.py
yu9824/AtCoder
50a209059c005efadc1c912e443ec41365381c16
[ "MIT" ]
null
null
null
ABC/m-solutions2020/B.py
yu9824/AtCoder
50a209059c005efadc1c912e443ec41365381c16
[ "MIT" ]
null
null
null
ABC/m-solutions2020/B.py
yu9824/AtCoder
50a209059c005efadc1c912e443ec41365381c16
[ "MIT" ]
null
null
null
# list(map(int, input().split())) # int(input()) from itertools import combinations_with_replacement import copy def main(lst, K): original = copy.copy(lst) # 要するにC>B>Aになればおけ. comb = combinations_with_replacement([0, 1, 2], K) for c in comb: lst = copy.copy(original) for i in c: ...
24.565217
54
0.539823
from itertools import combinations_with_replacement import copy def main(lst, K): original = copy.copy(lst) comb = combinations_with_replacement([0, 1, 2], K) for c in comb: lst = copy.copy(original) for i in c: lst[i] *= 2 if lst[0] < lst[1] and lst[1] < lst[2]:...
true
true
f75773bb44a2cf3c93a4afdd6d1bb83176747012
59,213
py
Python
raiden/api/python.py
tirkarthi/raiden
dbd03ddda039332b54ec0c02d81cbe1100bc8028
[ "MIT" ]
2,101
2016-06-01T11:31:49.000Z
2022-03-27T20:13:19.000Z
raiden/api/python.py
tirkarthi/raiden
dbd03ddda039332b54ec0c02d81cbe1100bc8028
[ "MIT" ]
5,291
2016-06-01T18:14:04.000Z
2022-03-31T11:19:09.000Z
raiden/api/python.py
tirkarthi/raiden
dbd03ddda039332b54ec0c02d81cbe1100bc8028
[ "MIT" ]
484
2016-06-01T18:21:06.000Z
2022-03-22T10:29:45.000Z
import gevent import opentracing import structlog from eth_utils import is_binary_address from raiden import waiting from raiden.api.exceptions import ChannelNotFound, NonexistingChannel from raiden.constants import BLOCK_ID_PENDING, NULL_ADDRESS_BYTES, UINT64_MAX, UINT256_MAX from raiden.exceptions import ( Alrea...
41.006233
99
0.668586
import gevent import opentracing import structlog from eth_utils import is_binary_address from raiden import waiting from raiden.api.exceptions import ChannelNotFound, NonexistingChannel from raiden.constants import BLOCK_ID_PENDING, NULL_ADDRESS_BYTES, UINT64_MAX, UINT256_MAX from raiden.exceptions import ( Alrea...
true
true
f75773e3b74f75da43a02185504fb8ebdf951419
285
py
Python
Day 1/tdd/loan_calculator.py
JoshuaOndieki/joshua-ondieki-bootcamp-17
e2f0f2b8100da28b5db1db6292bef7040d2b9263
[ "MIT" ]
null
null
null
Day 1/tdd/loan_calculator.py
JoshuaOndieki/joshua-ondieki-bootcamp-17
e2f0f2b8100da28b5db1db6292bef7040d2b9263
[ "MIT" ]
null
null
null
Day 1/tdd/loan_calculator.py
JoshuaOndieki/joshua-ondieki-bootcamp-17
e2f0f2b8100da28b5db1db6292bef7040d2b9263
[ "MIT" ]
null
null
null
#!/usr/bin/env python # encoding: utf-8 def loan_calculator(amount, rate, time): if amount<0: return "Invalid amount!" if rate>100: return "Invalid rate!" if time>12: return "Invalid Number of months!" return amount + (amount*(rate/100)*time)
21.923077
44
0.621053
def loan_calculator(amount, rate, time): if amount<0: return "Invalid amount!" if rate>100: return "Invalid rate!" if time>12: return "Invalid Number of months!" return amount + (amount*(rate/100)*time)
true
true
f757743953c25b714d2cb14fcbd050444e106554
1,744
py
Python
modules/dependencies/filters.py
Multi-Agent-io/feecc-analytics-backend
052d41a81b48f87f7ff33438c059b3087a45f5f3
[ "Apache-2.0" ]
null
null
null
modules/dependencies/filters.py
Multi-Agent-io/feecc-analytics-backend
052d41a81b48f87f7ff33438c059b3087a45f5f3
[ "Apache-2.0" ]
1
2021-12-03T11:17:59.000Z
2021-12-03T11:17:59.000Z
modules/dependencies/filters.py
Multi-Agent-io/feecc-analytics-backend
052d41a81b48f87f7ff33438c059b3087a45f5f3
[ "Apache-2.0" ]
1
2022-03-23T14:10:43.000Z
2022-03-23T14:10:43.000Z
import datetime import typing as tp from pydantic import Field from modules.routers.tcd.models import ProtocolStatus from modules.routers.passports.models import UnitStatus from ..types import Filter async def parse_passports_filter( status: tp.Optional[UnitStatus] = None, name: tp.Optional[str] = None, ...
28.590164
106
0.631881
import datetime import typing as tp from pydantic import Field from modules.routers.tcd.models import ProtocolStatus from modules.routers.passports.models import UnitStatus from ..types import Filter async def parse_passports_filter( status: tp.Optional[UnitStatus] = None, name: tp.Optional[str] = None, ...
true
true
f757745ba7cf2fa500f03102d7ca2b0c932c27bc
8,873
py
Python
youtube_dl/extractor/drtv.py
MOODesign/Youtube-videos-Download
730c0d12a06f349907481570f1f2890251f7a181
[ "Unlicense" ]
24
2017-03-17T10:27:12.000Z
2022-02-16T05:55:50.000Z
youtube_dl/extractor/drtv.py
MOODesign/Youtube-videos-Download
730c0d12a06f349907481570f1f2890251f7a181
[ "Unlicense" ]
7
2017-07-26T08:15:27.000Z
2018-09-20T12:56:53.000Z
youtube_dl/extractor/drtv.py
MOODesign/Youtube-videos-Download
730c0d12a06f349907481570f1f2890251f7a181
[ "Unlicense" ]
3
2019-08-28T18:38:26.000Z
2021-04-27T13:43:30.000Z
# coding: utf-8 from __future__ import unicode_literals from .common import InfoExtractor from ..utils import ( ExtractorError, int_or_none, float_or_none, mimetype2ext, parse_iso8601, remove_end, update_url_query, ) class DRTVIE(InfoExtractor): _VALID_URL = r'https?://(?:www\.)?dr\.d...
38.578261
118
0.486983
from __future__ import unicode_literals from .common import InfoExtractor from ..utils import ( ExtractorError, int_or_none, float_or_none, mimetype2ext, parse_iso8601, remove_end, update_url_query, ) class DRTVIE(InfoExtractor): _VALID_URL = r'https?://(?:www\.)?dr\.dk/(?:tv/se|nyhed...
true
true
f757749960019b5b061432b6d50d6e0ebbe41e28
2,331
py
Python
src/util/input.py
cisagov/gophish-tools
95b00306fc8385c8efc974ad8cb2851e0222f1bb
[ "CC0-1.0" ]
28
2020-07-01T15:22:09.000Z
2022-03-16T04:57:39.000Z
src/util/input.py
cisagov/gophish-tools
95b00306fc8385c8efc974ad8cb2851e0222f1bb
[ "CC0-1.0" ]
47
2020-06-14T01:18:54.000Z
2022-03-28T18:41:17.000Z
src/util/input.py
cisagov/gophish-tools
95b00306fc8385c8efc974ad8cb2851e0222f1bb
[ "CC0-1.0" ]
4
2020-06-11T18:25:39.000Z
2021-09-28T19:29:17.000Z
"""Functions related to user input.""" # Standard Python Libraries from datetime import datetime import logging # Third-Party Libraries from prompt_toolkit import prompt from prompt_toolkit.completion import WordCompleter import pytz # cisagov Libraries from util.validate import BlankInputValidator, BooleanValidator...
28.426829
108
0.63106
from datetime import datetime import logging from prompt_toolkit import prompt from prompt_toolkit.completion import WordCompleter import pytz from util.validate import BlankInputValidator, BooleanValidator logger = logging.getLogger(__name__) def yes_no_prompt(message): return prompt( "{}?(yes/no) "....
true
true
f75775cf7c5e69e95c29c843feb2569e0a09ed32
7,315
py
Python
opencda/core/plan/spline.py
xiaxin2000/OpenCDA-Documents
1ad4b368d4287dae8b282bac1665816a496d57c6
[ "MIT" ]
1
2021-12-17T10:45:33.000Z
2021-12-17T10:45:33.000Z
opencda/core/plan/spline.py
xiaxin2000/OpenCDA-Documents
1ad4b368d4287dae8b282bac1665816a496d57c6
[ "MIT" ]
null
null
null
opencda/core/plan/spline.py
xiaxin2000/OpenCDA-Documents
1ad4b368d4287dae8b282bac1665816a496d57c6
[ "MIT" ]
1
2021-10-01T19:41:52.000Z
2021-10-01T19:41:52.000Z
""" Cubic spline planner Author: Atsushi Sakai(@Atsushi_twi) """ import math import numpy as np import bisect class Spline: """ Cubic Spline class for calculte curvature (Author: Atsushi Sakai(@Atsushi_twi)). Parameters -x : float The x coordinate. -y : float The y coordinate. ...
24.54698
110
0.496924
import math import numpy as np import bisect class Spline: def __init__(self, x, y): self.b, self.c, self.d, self.w = [], [], [], [] self.x = x self.y = y self.nx = len(x) h = np.diff(x) self.a = [iy for iy in y] A = self.__calc_A(h) ...
true
true
f75775e29a7f023998533d0de20b94e8e1fde6b1
3,012
py
Python
sdk/datafactory/azure-mgmt-datafactory/azure/mgmt/datafactory/models/integration_runtime_ssis_properties_py3.py
tzhanl/azure-sdk-for-python
18cd03f4ab8fd76cc0498f03e80fbc99f217c96e
[ "MIT" ]
1
2021-06-02T08:01:35.000Z
2021-06-02T08:01:35.000Z
sdk/datafactory/azure-mgmt-datafactory/azure/mgmt/datafactory/models/integration_runtime_ssis_properties_py3.py
tzhanl/azure-sdk-for-python
18cd03f4ab8fd76cc0498f03e80fbc99f217c96e
[ "MIT" ]
1
2020-03-06T05:57:16.000Z
2020-03-06T05:57:16.000Z
sdk/datafactory/azure-mgmt-datafactory/azure/mgmt/datafactory/models/integration_runtime_ssis_properties_py3.py
tzhanl/azure-sdk-for-python
18cd03f4ab8fd76cc0498f03e80fbc99f217c96e
[ "MIT" ]
null
null
null
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. # # Code generated by Microsoft (R) AutoRest Code Generator. # Changes ...
50.2
189
0.713479
from msrest.serialization import Model class IntegrationRuntimeSsisProperties(Model): _attribute_map = { 'additional_properties': {'key': '', 'type': '{object}'}, 'catalog_info': {'key': 'catalogInfo', 'type': 'IntegrationRuntimeSsisCatalogInfo'}, 'license_type': {'key': 'licenseType', '...
true
true
f7577693d0c9555983c2501dc7d9ddf1df544a25
1,084
py
Python
diventi/ebooks/migrations/0123_auto_20201010_2345.py
flavoi/diven
3173ca3ca3fbedc191b8eab3639a6bceb3c442c4
[ "Apache-2.0" ]
2
2019-06-27T16:00:17.000Z
2020-08-14T07:46:05.000Z
diventi/ebooks/migrations/0123_auto_20201010_2345.py
flavoi/diven
3173ca3ca3fbedc191b8eab3639a6bceb3c442c4
[ "Apache-2.0" ]
26
2020-02-15T22:39:35.000Z
2022-02-19T21:09:01.000Z
diventi/ebooks/migrations/0123_auto_20201010_2345.py
flavoi/diven
3173ca3ca3fbedc191b8eab3639a6bceb3c442c4
[ "Apache-2.0" ]
1
2021-11-12T22:30:15.000Z
2021-11-12T22:30:15.000Z
# Generated by Django 2.2.16 on 2020-10-10 21:45 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('ebooks', '0122_auto_20201005_2212'), ] operations = [ migrations.AlterField( model_name='book', name='logo_backgrou...
57.052632
741
0.624539
from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('ebooks', '0122_auto_20201005_2212'), ] operations = [ migrations.AlterField( model_name='book', name='logo_background', field=models.CharField(choices=[...
true
true
f75777aeba8153853338bef87650ce7df9f8b575
3,744
py
Python
isi_sdk_8_1_1/isi_sdk_8_1_1/models/namespace_objects.py
mohitjain97/isilon_sdk_python
a371f438f542568edb8cda35e929e6b300b1177c
[ "Unlicense" ]
24
2018-06-22T14:13:23.000Z
2022-03-23T01:21:26.000Z
isi_sdk_8_1_1/isi_sdk_8_1_1/models/namespace_objects.py
mohitjain97/isilon_sdk_python
a371f438f542568edb8cda35e929e6b300b1177c
[ "Unlicense" ]
46
2018-04-30T13:28:22.000Z
2022-03-21T21:11:07.000Z
isi_sdk_8_1_1/isi_sdk_8_1_1/models/namespace_objects.py
mohitjain97/isilon_sdk_python
a371f438f542568edb8cda35e929e6b300b1177c
[ "Unlicense" ]
29
2018-06-19T00:14:04.000Z
2022-02-08T17:51:19.000Z
# coding: utf-8 """ Isilon SDK Isilon SDK - Language bindings for the OneFS API # noqa: E501 OpenAPI spec version: 6 Contact: sdk@isilon.com Generated by: https://github.com/swagger-api/swagger-codegen.git """ import pprint import re # noqa: F401 import six from isi_sdk_8_1_1.models.namespa...
26.553191
84
0.569979
import pprint import re import six from isi_sdk_8_1_1.models.namespace_object import NamespaceObject class NamespaceObjects(object): swagger_types = { 'children': 'list[NamespaceObject]', 'resume': 'str' } attribute_map = { 'children': 'children', 'resume': 'resume...
true
true
f757791132a4d70fb5bcf9473e6ab74a0abe701d
12,741
py
Python
muted/tools/builder.py
st093186/mute-master
9247e422e543d9ee96d4df9133bed2cbed62ddd0
[ "MIT" ]
null
null
null
muted/tools/builder.py
st093186/mute-master
9247e422e543d9ee96d4df9133bed2cbed62ddd0
[ "MIT" ]
null
null
null
muted/tools/builder.py
st093186/mute-master
9247e422e543d9ee96d4df9133bed2cbed62ddd0
[ "MIT" ]
null
null
null
from __future__ import annotations from typing import List from typing import NamedTuple from typing import Optional from typing import Tuple from pathlib import Path import json import uuid from random import randint class Entity: @staticmethod def eid() -> str: return uuid.uuid4().hex class See...
27.050955
77
0.460168
from __future__ import annotations from typing import List from typing import NamedTuple from typing import Optional from typing import Tuple from pathlib import Path import json import uuid from random import randint class Entity: @staticmethod def eid() -> str: return uuid.uuid4().hex class See...
true
true
f7577930b0857adc7797700574bb3687d7b2ef5f
1,609
py
Python
desafios/desafio68.py
JonasAraujoP/Python
4ce6d330af4d078ff8658c82b3f3fbf2c41722d5
[ "MIT" ]
null
null
null
desafios/desafio68.py
JonasAraujoP/Python
4ce6d330af4d078ff8658c82b3f3fbf2c41722d5
[ "MIT" ]
null
null
null
desafios/desafio68.py
JonasAraujoP/Python
4ce6d330af4d078ff8658c82b3f3fbf2c41722d5
[ "MIT" ]
null
null
null
from random import randint print('\033[33m=-=\033[m'*12) print('JOGO DO PAR OU ÍMPAR') n = 0 total = 0 derrota = False resultado = '' vitoria = 0 while derrota == False: print('\033[33m=-=\033[m'*12) n = int(input('Digite um número: ')) jogador = ' ' while jogador not in 'PI': jogador = str(inpu...
38.309524
108
0.571162
from random import randint print('\033[33m=-=\033[m'*12) print('JOGO DO PAR OU ÍMPAR') n = 0 total = 0 derrota = False resultado = '' vitoria = 0 while derrota == False: print('\033[33m=-=\033[m'*12) n = int(input('Digite um número: ')) jogador = ' ' while jogador not in 'PI': jogador = str(inpu...
true
true
f75779e7519e2daefe5a8d086424ec9d3c7e4594
3,093
py
Python
SmartAnno/umls/UMLSFinder.py
jianlins/SmartAnno
e0925c45853967683aa2955588437bd120fe39c3
[ "Apache-2.0" ]
null
null
null
SmartAnno/umls/UMLSFinder.py
jianlins/SmartAnno
e0925c45853967683aa2955588437bd120fe39c3
[ "Apache-2.0" ]
null
null
null
SmartAnno/umls/UMLSFinder.py
jianlins/SmartAnno
e0925c45853967683aa2955588437bd120fe39c3
[ "Apache-2.0" ]
null
null
null
from __future__ import print_function import json import string from collections import Set, OrderedDict from SmartAnno.umls.Authentication import * class UMLSFinder: version = "current" uri = "https://uts-ws.nlm.nih.gov" content_endpoint = "/rest/search/" + version AuthClient = None translator ...
39.151899
110
0.52053
from __future__ import print_function import json import string from collections import Set, OrderedDict from SmartAnno.umls.Authentication import * class UMLSFinder: version = "current" uri = "https://uts-ws.nlm.nih.gov" content_endpoint = "/rest/search/" + version AuthClient = None translator ...
true
true
f7577a7f9d7776a9e0bd927d89e5f84349f26b36
244
py
Python
django_tenants/admin.py
buraketmen/django-tenants
39bc6f9de7dff05eed5c2b062809493ef6f77571
[ "MIT" ]
514
2015-06-12T00:31:32.000Z
2020-06-08T17:49:23.000Z
django_tenants/admin.py
tiagocapelli/django-tenants
44b0bf78a5ccabcb28c4fa4ef0465aadc3125d1c
[ "MIT" ]
363
2015-06-12T07:04:04.000Z
2020-06-09T17:10:17.000Z
django_tenants/admin.py
tiagocapelli/django-tenants
44b0bf78a5ccabcb28c4fa4ef0465aadc3125d1c
[ "MIT" ]
159
2015-06-12T13:09:15.000Z
2020-06-04T00:48:35.000Z
class TenantAdminMixin: """ Mixin for Tenant model: It disables save and delete buttons when not in current or public tenant (preventing Exceptions). """ change_form_template = 'admin/django_tenants/tenant/change_form.html'
34.857143
101
0.737705
class TenantAdminMixin: change_form_template = 'admin/django_tenants/tenant/change_form.html'
true
true
f7577b9c061ac312e73eb10c9f1175cac0466757
1,650
py
Python
src/log-analytics/setup.py
Mannan2812/azure-cli-extensions
e2b34efe23795f6db9c59100534a40f0813c3d95
[ "MIT" ]
207
2017-11-29T06:59:41.000Z
2022-03-31T10:00:53.000Z
src/log-analytics/setup.py
Mannan2812/azure-cli-extensions
e2b34efe23795f6db9c59100534a40f0813c3d95
[ "MIT" ]
4,061
2017-10-27T23:19:56.000Z
2022-03-31T23:18:30.000Z
src/log-analytics/setup.py
Mannan2812/azure-cli-extensions
e2b34efe23795f6db9c59100534a40f0813c3d95
[ "MIT" ]
802
2017-10-11T17:36:26.000Z
2022-03-31T22:24:32.000Z
#!/usr/bin/env python # -------------------------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # ---------------------------------------------...
34.375
94
0.6
from codecs import open from setuptools import setup, find_packages VERSION = "0.2.2" CLASSIFIERS = [ 'Development Status :: 4 - Beta', 'Intended Audience :: Developers', 'Intended Audience :: System Administrators', 'Programming Language :: Python', 'Programming Language :: Python :: 2', 'P...
true
true
f7577db7882224a6c644028df541b18cf3d1b193
2,156
py
Python
tests/h/services/group_scope_test.py
julien-cheng/h
36c8ec044725720cf36f0986cdf025395aca8929
[ "BSD-2-Clause" ]
2
2019-08-04T07:22:11.000Z
2020-07-17T05:01:41.000Z
tests/h/services/group_scope_test.py
11-eleven-11/h
91c7a4504ad7471ed3e30246763a03e6c1cc531b
[ "BSD-2-Clause" ]
null
null
null
tests/h/services/group_scope_test.py
11-eleven-11/h
91c7a4504ad7471ed3e30246763a03e6c1cc531b
[ "BSD-2-Clause" ]
null
null
null
# -*- coding: utf-8 -*- from __future__ import unicode_literals import pytest from h.services.group_scope import group_scope_factory, GroupScopeService class TestFetchByScope(object): def test_it_returns_empty_list_if_origin_not_parseable( self, svc, scope_util, document_uri ): scope_util.p...
29.534247
88
0.707792
from __future__ import unicode_literals import pytest from h.services.group_scope import group_scope_factory, GroupScopeService class TestFetchByScope(object): def test_it_returns_empty_list_if_origin_not_parseable( self, svc, scope_util, document_uri ): scope_util.parse_origin.return_value...
true
true
f7577dded470faf3326a4276e56ecef8cb81bcf9
1,255
py
Python
code/fs/img.py
zhangsucheng/Python-pracive
e95fd3298abb3f23804d126c3e5f973d97d37cfe
[ "MIT" ]
null
null
null
code/fs/img.py
zhangsucheng/Python-pracive
e95fd3298abb3f23804d126c3e5f973d97d37cfe
[ "MIT" ]
null
null
null
code/fs/img.py
zhangsucheng/Python-pracive
e95fd3298abb3f23804d126c3e5f973d97d37cfe
[ "MIT" ]
null
null
null
from PIL import Image, ImageDraw, ImageFont, ImageFilter import random image = Image.open("../../res/images/man.jpg") w, h = image.size image.thumbnail((w // 2, h // 2)) image.save("../res/images/thumbMan.jpg", 'jpeg') image2 = image.filter(ImageFilter.BLUR) image2.save("../res/images/blurImage.jpg", 'jpeg') # 随机字母...
24.607843
84
0.622311
from PIL import Image, ImageDraw, ImageFont, ImageFilter import random image = Image.open("../../res/images/man.jpg") w, h = image.size image.thumbnail((w // 2, h // 2)) image.save("../res/images/thumbMan.jpg", 'jpeg') image2 = image.filter(ImageFilter.BLUR) image2.save("../res/images/blurImage.jpg", 'jpeg') def rn...
true
true
f7577deb3e7b0db8479f94f57dd46c27ad3ca1b2
463
py
Python
docs/doc-generator.py
zxdawn/erc-uptrop
58111cb80285a0f959ef140c7177195e823b5289
[ "MIT" ]
3
2020-10-09T07:13:40.000Z
2022-02-15T13:14:36.000Z
docs/doc-generator.py
zxdawn/erc-uptrop
58111cb80285a0f959ef140c7177195e823b5289
[ "MIT" ]
4
2020-07-04T18:56:25.000Z
2022-02-14T13:14:47.000Z
docs/doc-generator.py
zxdawn/erc-uptrop
58111cb80285a0f959ef140c7177195e823b5289
[ "MIT" ]
3
2020-10-09T07:17:16.000Z
2022-01-09T09:36:46.000Z
import os for module_name in os.listdir("../uptrop"): if module_name.endswith(".py"): doc_name = module_name.split('.')[0] with open("source/" + doc_name + ".rst", 'w') as this_doc: this_doc.write("="*len(doc_name) + "\n") this_doc.write(doc_name + "\n") this_doc...
33.071429
66
0.546436
import os for module_name in os.listdir("../uptrop"): if module_name.endswith(".py"): doc_name = module_name.split('.')[0] with open("source/" + doc_name + ".rst", 'w') as this_doc: this_doc.write("="*len(doc_name) + "\n") this_doc.write(doc_name + "\n") this_doc...
true
true
f7577ea431cb8a118d37ce601c081ed7a137425b
5,295
py
Python
polyglotdb/io/parsers/partitur.py
msonderegger/PolyglotDB
583fd8ec14c2e34807b45b9f15fa19cffa130bfa
[ "MIT" ]
null
null
null
polyglotdb/io/parsers/partitur.py
msonderegger/PolyglotDB
583fd8ec14c2e34807b45b9f15fa19cffa130bfa
[ "MIT" ]
null
null
null
polyglotdb/io/parsers/partitur.py
msonderegger/PolyglotDB
583fd8ec14c2e34807b45b9f15fa19cffa130bfa
[ "MIT" ]
null
null
null
import re import os from polyglotdb.io.parsers.base import BaseParser # , PGAnnotation, PGAnnotationType, DiscourseData from .speaker import FilenameSpeakerParser from .speaker import DirectorySpeakerParser from .base import DiscourseData class PartiturParser(BaseParser): _extensions = ['.par,2'] def __in...
28.467742
100
0.550519
import re import os from polyglotdb.io.parsers.base import BaseParser from .speaker import FilenameSpeakerParser from .speaker import DirectorySpeakerParser from .base import DiscourseData class PartiturParser(BaseParser): _extensions = ['.par,2'] def __init__(self, annotation_tiers, hierarchy, ...
true
true
f7577eb038e91b5ee0cfe66b36e3415b8708ac64
3,311
py
Python
neutron/objects/agent.py
cloudbase/neutron
50f31386cf6976225e5f0cdba81cdadec2a30872
[ "Apache-2.0" ]
1
2017-09-10T09:57:35.000Z
2017-09-10T09:57:35.000Z
neutron/objects/agent.py
cloudbase/neutron
50f31386cf6976225e5f0cdba81cdadec2a30872
[ "Apache-2.0" ]
null
null
null
neutron/objects/agent.py
cloudbase/neutron
50f31386cf6976225e5f0cdba81cdadec2a30872
[ "Apache-2.0" ]
1
2015-05-05T14:41:11.000Z
2015-05-05T14:41:11.000Z
# Copyright (c) 2016 Intel Corporation. # # 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...
40.378049
78
0.67019
from oslo_serialization import jsonutils from oslo_versionedobjects import base as obj_base from oslo_versionedobjects import fields as obj_fields from neutron.agent.common import utils from neutron.db.models import agent as agent_model from neutron.objects import base @obj_base.VersionedObjectRegistry.register cla...
true
true
f7577fdb41b0675f4891086c656242907cb8d88f
6,693
py
Python
azurelinuxagent/common/utils/cryptutil.py
ddiss/WALinuxAgent
9c9893ebdec8a43bb15d84f309ff5b564436c408
[ "Apache-2.0" ]
null
null
null
azurelinuxagent/common/utils/cryptutil.py
ddiss/WALinuxAgent
9c9893ebdec8a43bb15d84f309ff5b564436c408
[ "Apache-2.0" ]
null
null
null
azurelinuxagent/common/utils/cryptutil.py
ddiss/WALinuxAgent
9c9893ebdec8a43bb15d84f309ff5b564436c408
[ "Apache-2.0" ]
null
null
null
# Microsoft Azure Linux Agent # # Copyright 2018 Microsoft Corporation # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required b...
41.571429
135
0.609144
import base64 import errno import struct import os.path import subprocess from azurelinuxagent.common.future import ustr, bytebuffer from azurelinuxagent.common.exception import CryptError import azurelinuxagent.common.logger as logger import azurelinuxagent.common.utils.shellutil as shellutil DECRYPT_SECRET_CMD =...
true
true
f7578094ed3e452423b36e4060c2d1e5e3ee95aa
1,531
py
Python
examples/rrt_star/rrt_star_3d.py
Taylor-Liu/rrt-algorithms
54be136b71d63f8e3ff37afadf267da49080100b
[ "MIT" ]
null
null
null
examples/rrt_star/rrt_star_3d.py
Taylor-Liu/rrt-algorithms
54be136b71d63f8e3ff37afadf267da49080100b
[ "MIT" ]
null
null
null
examples/rrt_star/rrt_star_3d.py
Taylor-Liu/rrt-algorithms
54be136b71d63f8e3ff37afadf267da49080100b
[ "MIT" ]
null
null
null
# This file is subject to the terms and conditions defined in # file 'LICENSE', which is part of this source code package. import os import sys sys.path.append(os.path.dirname(os.path.abspath(__file__)) + "/../../") import numpy as np from src.rrt.rrt_star import RRTStar from src.search_space.search_s...
34.795455
109
0.685173
import os import sys sys.path.append(os.path.dirname(os.path.abspath(__file__)) + "/../../") import numpy as np from src.rrt.rrt_star import RRTStar from src.search_space.search_space import SearchSpace from src.utilities.plotting import Plot X_dimensions = np.array([(0, 100), (0, 100), (0, 100)]) O...
true
true
f75780a925bf1eb0c17b22cc0d961234876f3dae
3,844
py
Python
src/pkg/caendr/caendr/services/cloud/lifesciences.py
AndersenLab/CAENDR
ce4cdb74db736db8226ffc90988959b71b0d5ff5
[ "MIT" ]
3
2022-02-09T07:04:37.000Z
2022-03-11T02:46:35.000Z
src/pkg/caendr/caendr/services/cloud/lifesciences.py
AndersenLab/CAENDR
ce4cdb74db736db8226ffc90988959b71b0d5ff5
[ "MIT" ]
4
2022-01-28T22:28:08.000Z
2022-02-11T21:47:15.000Z
src/pkg/caendr/caendr/services/cloud/lifesciences.py
AndersenLab/CAENDR
ce4cdb74db736db8226ffc90988959b71b0d5ff5
[ "MIT" ]
1
2022-01-11T03:39:02.000Z
2022-01-11T03:39:02.000Z
import os from logzero import logger from googleapiclient import discovery from oauth2client.client import GoogleCredentials from caendr.models.datastore import PipelineOperation, DatabaseOperation, NemascanMapping, IndelPrimer from caendr.models.error import PipelineRunError from caendr.services.cloud.datast...
34.945455
113
0.742976
import os from logzero import logger from googleapiclient import discovery from oauth2client.client import GoogleCredentials from caendr.models.datastore import PipelineOperation, DatabaseOperation, NemascanMapping, IndelPrimer from caendr.models.error import PipelineRunError from caendr.services.cloud.datast...
true
true
f7578228f3ad6379b2554f01f299e99ccb278c03
598
py
Python
tutorials/W3D1_RealNeurons/solutions/W3D1_Tutorial2_Solution_bb194a8f.py
NinelK/course-content
317b4cf153a89afbddbd194e7fbb15c91588b3c5
[ "CC-BY-4.0" ]
26
2020-07-01T20:38:44.000Z
2021-06-20T06:37:27.000Z
tutorials/W3D1_RealNeurons/solutions/W3D1_Tutorial2_Solution_bb194a8f.py
Andy-Dufrein/course-content
977f4ddaaa4f33746672930ae01d5ea592dbbba0
[ "CC-BY-4.0" ]
3
2020-06-23T03:46:36.000Z
2020-07-07T05:26:01.000Z
tutorials/W3D1_RealNeurons/solutions/W3D1_Tutorial2_Solution_bb194a8f.py
Andy-Dufrein/course-content
977f4ddaaa4f33746672930ae01d5ea592dbbba0
[ "CC-BY-4.0" ]
16
2020-07-06T06:48:02.000Z
2021-07-30T08:18:52.000Z
""" Discussion: This has got to do with which part of the input current distribution is transferred to the spiking activity. Intuitive understanding is difficult but this relationship arises due to non-linearities in the neuron F-I curve. When F-I curve is linear, output correlation is independent of the mean and...
42.714286
89
0.779264
true
true
f7578414dc14bad6e8dadf343973e5e34d74f443
1,227
py
Python
zspider/spiders/news.py
Zephor5/zspider
49178415137d67d7c88f2904bcb204df32082204
[ "MIT" ]
12
2015-12-23T10:13:31.000Z
2021-04-25T17:12:39.000Z
zspider/spiders/news.py
Zephor5/zspider
49178415137d67d7c88f2904bcb204df32082204
[ "MIT" ]
1
2022-03-02T14:53:18.000Z
2022-03-02T14:53:18.000Z
zspider/spiders/news.py
Zephor5/zspider
49178415137d67d7c88f2904bcb204df32082204
[ "MIT" ]
1
2017-09-18T08:51:51.000Z
2017-09-18T08:51:51.000Z
# coding=utf-8 import logging from scrapy import FormRequest from scrapy import Request from zspider.basespider import BaseSpider __author__ = "zephor" logger = logging.getLogger(__name__) class NewsSpider(BaseSpider): name = "news" def __init__(self, *args, **kwargs): super(NewsSpider, self).__...
29.926829
81
0.607172
import logging from scrapy import FormRequest from scrapy import Request from zspider.basespider import BaseSpider __author__ = "zephor" logger = logging.getLogger(__name__) class NewsSpider(BaseSpider): name = "news" def __init__(self, *args, **kwargs): super(NewsSpider, self).__init__(*args, *...
true
true
f7578441293369161246239d37346131c24a2500
667
py
Python
matchzoo/layers/NonMasking.py
ChangQF/MatchZoo
991bdbad1e5166870fd4051646d7834a337d0709
[ "Apache-2.0" ]
71
2018-04-18T05:17:54.000Z
2021-08-06T07:54:25.000Z
matchzoo/layers/NonMasking.py
ChangQF/MatchZoo
991bdbad1e5166870fd4051646d7834a337d0709
[ "Apache-2.0" ]
6
2018-10-16T08:33:19.000Z
2020-11-10T07:44:04.000Z
tools/layers/NonMasking.py
whatc0de/CFN-maste
ec3d1f5c8ee2c50eeaac96eca28f349fd9b92403
[ "MIT" ]
16
2018-08-03T09:44:56.000Z
2020-08-25T14:02:42.000Z
from keras.layers import Input from keras import backend as K from keras.engine.topology import Layer import numpy as np class NonMasking(Layer): def __init__(self, **kwargs): self.supports_masking = True super(NonMasking, self).__init__(**kwargs) def build(self, input_shape): input_sh...
25.653846
51
0.688156
from keras.layers import Input from keras import backend as K from keras.engine.topology import Layer import numpy as np class NonMasking(Layer): def __init__(self, **kwargs): self.supports_masking = True super(NonMasking, self).__init__(**kwargs) def build(self, input_shape): input_sh...
true
true
f75784815d57f3f2fa0a27df0a2c52fea3579f24
49,988
py
Python
gaia.py
vorticityxyz/Gaia-api
04e2a9ee2448830df72156aecf432eda0c6eb504
[ "MIT" ]
null
null
null
gaia.py
vorticityxyz/Gaia-api
04e2a9ee2448830df72156aecf432eda0c6eb504
[ "MIT" ]
null
null
null
gaia.py
vorticityxyz/Gaia-api
04e2a9ee2448830df72156aecf432eda0c6eb504
[ "MIT" ]
null
null
null
# Description: # # WARNING!!! This file is a critical component of Vorticity Gaia API for seismic imaging # PLEASE DO NOT MODIFY # # (C) Vorticity Inc. Mountain View, CA 2021 # Licence: MIT import numpy as np import grpc import time import os import sys import gaia_pb2 import gaia_pb2_grpc import dispatch_pb2 import d...
36.946046
161
0.636813
import numpy as np import grpc import time import os import sys import gaia_pb2 import gaia_pb2_grpc import dispatch_pb2 import dispatch_pb2_grpc import validate import tokens import codes CHUNK_SIZE = 1024 * 1024 IN_FILE = "_gaia_input.npz" EL_IN_FILE = "_egaia_input.npz" RTM_FILE = "_gaia_rtm.npz" EL_RTM_FILE = ...
true
true
f7578576588ffa5421aa8f2d033686a2d13fe10d
804
py
Python
ethereum_stats/process.py
carlesperezj/ethereum-analysis-tool
cad790ddab71b545d4d760f731d87a7130521e5e
[ "MIT" ]
null
null
null
ethereum_stats/process.py
carlesperezj/ethereum-analysis-tool
cad790ddab71b545d4d760f731d87a7130521e5e
[ "MIT" ]
1
2018-07-02T08:40:10.000Z
2018-07-02T08:40:10.000Z
ethereum_stats/process.py
carlesperezj/ethereum-analysis-tool
cad790ddab71b545d4d760f731d87a7130521e5e
[ "MIT" ]
1
2018-07-27T14:50:43.000Z
2018-07-27T14:50:43.000Z
from geth import LoggingMixin from geth.process import BaseGethProcess, DevGethProcess class RinkebyGethProcess(BaseGethProcess): def __init__(self, geth_kwargs=None): if geth_kwargs is None: geth_kwargs = {} if 'network_id' in geth_kwargs: raise ValueError( ...
24.363636
87
0.685323
from geth import LoggingMixin from geth.process import BaseGethProcess, DevGethProcess class RinkebyGethProcess(BaseGethProcess): def __init__(self, geth_kwargs=None): if geth_kwargs is None: geth_kwargs = {} if 'network_id' in geth_kwargs: raise ValueError( ...
true
true
f757885955e41b8150fc01309000a6792d46e4a7
1,535
py
Python
quotations/models.py
billdavisjr/wbd_fsd_project4
8f89879626378049dbe02a34e98531d1775e643d
[ "BSD-Source-Code" ]
null
null
null
quotations/models.py
billdavisjr/wbd_fsd_project4
8f89879626378049dbe02a34e98531d1775e643d
[ "BSD-Source-Code" ]
null
null
null
quotations/models.py
billdavisjr/wbd_fsd_project4
8f89879626378049dbe02a34e98531d1775e643d
[ "BSD-Source-Code" ]
null
null
null
from django.db import models # Create your models here. class Category(models.Model): class Meta: verbose_name_plural = 'Categories' name = models.CharField(max_length=254) display_name = models.CharField(max_length=254) # note: did not add null=True and blank=True params to these # as ...
30.7
73
0.674919
from django.db import models class Category(models.Model): class Meta: verbose_name_plural = 'Categories' name = models.CharField(max_length=254) display_name = models.CharField(max_length=254) objects = models.Manager() def __str__(self): return self.display_name ...
true
true
f7578971640f54fe252ba404d6023a8e7739f41a
5,318
py
Python
Geometry/HGCalCommonData/python/testHGCalV17XML_cfi.py
menglu21/cmssw
c3d6cb102c0aaddf652805743370c28044d53da6
[ "Apache-2.0" ]
null
null
null
Geometry/HGCalCommonData/python/testHGCalV17XML_cfi.py
menglu21/cmssw
c3d6cb102c0aaddf652805743370c28044d53da6
[ "Apache-2.0" ]
null
null
null
Geometry/HGCalCommonData/python/testHGCalV17XML_cfi.py
menglu21/cmssw
c3d6cb102c0aaddf652805743370c28044d53da6
[ "Apache-2.0" ]
null
null
null
import FWCore.ParameterSet.Config as cms XMLIdealGeometryESSource = cms.ESSource("XMLIdealGeometryESSource", geomXMLFiles = cms.vstring( 'Geometry/CMSCommonData/data/materials/2021/v1/materials.xml', 'Geometry/CMSCommonData/data/rotations.xml', 'Geometry/CMSCommonData/data/extend/v2/cmsexte...
59.752809
82
0.723392
import FWCore.ParameterSet.Config as cms XMLIdealGeometryESSource = cms.ESSource("XMLIdealGeometryESSource", geomXMLFiles = cms.vstring( 'Geometry/CMSCommonData/data/materials/2021/v1/materials.xml', 'Geometry/CMSCommonData/data/rotations.xml', 'Geometry/CMSCommonData/data/extend/v2/cmsexte...
true
true
f7578ba764e0162148b7ef5e7848088f964745e0
1,432
py
Python
run.py
Chasesc/codeinterview-sandbox
132bc02fe087b112f9e03267a7bc7a68ea96eb8a
[ "Apache-2.0" ]
24
2020-06-01T18:01:08.000Z
2022-01-21T09:43:12.000Z
run.py
Chasesc/codeinterview-sandbox
132bc02fe087b112f9e03267a7bc7a68ea96eb8a
[ "Apache-2.0" ]
null
null
null
run.py
Chasesc/codeinterview-sandbox
132bc02fe087b112f9e03267a7bc7a68ea96eb8a
[ "Apache-2.0" ]
7
2020-06-02T12:05:21.000Z
2021-03-18T16:03:44.000Z
import logging from celery.app import Celery from celery import shared_task from sandbox import settings, Sandbox, UnsupportedLanguage, TimeoutError, MemoryLimitExceeded from sandbox.settings import LANG_CONFIG logging.basicConfig(filename='worker.log', level=logging.DEBUG, fo...
28.078431
93
0.61243
import logging from celery.app import Celery from celery import shared_task from sandbox import settings, Sandbox, UnsupportedLanguage, TimeoutError, MemoryLimitExceeded from sandbox.settings import LANG_CONFIG logging.basicConfig(filename='worker.log', level=logging.DEBUG, fo...
true
true
f7578bc7406d32d42f02bfe448bf224dc0f049e3
2,662
py
Python
tensorflow/python/kernel_tests/dense_update_ops_no_tsan_test.py
jylinman/tensorflow
5248d111c3aeaf9f560cd77bff0f183f38e31e0b
[ "Apache-2.0" ]
73
2017-01-05T09:06:08.000Z
2021-11-06T14:00:50.000Z
tensorflow/python/kernel_tests/dense_update_ops_no_tsan_test.py
jylinman/tensorflow
5248d111c3aeaf9f560cd77bff0f183f38e31e0b
[ "Apache-2.0" ]
8
2017-04-10T10:36:20.000Z
2021-02-07T01:02:32.000Z
tensorflow/python/kernel_tests/dense_update_ops_no_tsan_test.py
jylinman/tensorflow
5248d111c3aeaf9f560cd77bff0f183f38e31e0b
[ "Apache-2.0" ]
151
2016-11-10T09:01:15.000Z
2022-01-18T08:13:49.000Z
# Copyright 2015 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 a...
34.128205
80
0.643501
from __future__ import absolute_import from __future__ import division from __future__ import print_function import numpy as np import tensorflow as tf class AssignOpTest(tf.test.TestCase): def testParallelUpdateWithoutLocking(self): with self.test_session() as sess: ones_t = tf.fill([1024, 1024]...
true
true
f7578c2b6b304498679f715dd5d077b5b6ca529a
29,997
py
Python
flink-python/pyflink/fn_execution/operations.py
klDen/flink
a2c737891afde0c63c1a453b1ee164b80b6a702c
[ "Apache-2.0" ]
null
null
null
flink-python/pyflink/fn_execution/operations.py
klDen/flink
a2c737891afde0c63c1a453b1ee164b80b6a702c
[ "Apache-2.0" ]
null
null
null
flink-python/pyflink/fn_execution/operations.py
klDen/flink
a2c737891afde0c63c1a453b1ee164b80b6a702c
[ "Apache-2.0" ]
null
null
null
################################################################################ # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this...
44.048458
100
0.663333
import abc import time from functools import reduce from itertools import chain from typing import List, Tuple, Any, Dict from apache_beam.coders import PickleCoder from pyflink.datastream.state import ValueStateDescriptor, ValueState, ListStateDescriptor, \ ListState, MapStateDescriptor, MapState, ReducingStateD...
true
true
f7578c877b5d49e70e6b5e82fbbc3f5c52128365
2,358
py
Python
make/jobserver/client.py
mithro/python-make-jobserver
f65d9d2f37822992b00a0e51897207a3f48d681b
[ "Apache-2.0" ]
null
null
null
make/jobserver/client.py
mithro/python-make-jobserver
f65d9d2f37822992b00a0e51897207a3f48d681b
[ "Apache-2.0" ]
null
null
null
make/jobserver/client.py
mithro/python-make-jobserver
f65d9d2f37822992b00a0e51897207a3f48d681b
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python3 """Simple client for the make jobserver.""" import signal from . import utils try: InterruptedError = InterruptedError except NameError: class InterruptedError(BaseException): pass class JobServerClient: def __init__(self, make_flags=None): self.tokens = [] ...
27.418605
75
0.57676
import signal from . import utils try: InterruptedError = InterruptedError except NameError: class InterruptedError(BaseException): pass class JobServerClient: def __init__(self, make_flags=None): self.tokens = [] job_rd_fd, job_wr_fd = utils.fds_for_jobserver(make_flags) ...
true
true
f7578cb83bd4d3f070bbc082e6e843273f7d77cc
3,845
py
Python
planetoid_dgi_benchmark.py
ggoh29/Simplicial-neural-network-benchmark
9a12bcd054251790d85e3971f5473dcffaa5664b
[ "MIT" ]
1
2022-02-04T23:06:52.000Z
2022-02-04T23:06:52.000Z
planetoid_dgi_benchmark.py
ggoh29/Simplicial-neural-network-benchmark
9a12bcd054251790d85e3971f5473dcffaa5664b
[ "MIT" ]
null
null
null
planetoid_dgi_benchmark.py
ggoh29/Simplicial-neural-network-benchmark
9a12bcd054251790d85e3971f5473dcffaa5664b
[ "MIT" ]
1
2022-02-04T23:07:09.000Z
2022-02-04T23:07:09.000Z
from Planetoid.PlanetoidDataset import PlanetoidSCDataset from models import planetoid_GCN, planetoid_GAT, planetoid_SCN, planetoid_SCConv, planetoid_SAN, planetoid_SAT import torch.nn as nn import torch from Planetoid.DGI import DGI from Planetoid.logreg import LogReg from constants import DEVICE 2708, 79 dataset = '...
28.065693
110
0.620286
from Planetoid.PlanetoidDataset import PlanetoidSCDataset from models import planetoid_GCN, planetoid_GAT, planetoid_SCN, planetoid_SCConv, planetoid_SAN, planetoid_SAT import torch.nn as nn import torch from Planetoid.DGI import DGI from Planetoid.logreg import LogReg from constants import DEVICE 2708, 79 dataset = '...
true
true
f7578d8657b41cea602dd5b3ea6653c8f286a509
449
py
Python
matplotlib-3.4.3/matplotlib-3.4.3/examples/mplot3d/lines3d.py
JohnLauFoo/clc_packages_Yu
259f01d9b5c02154ce258734d519ae8995cd0991
[ "MIT" ]
1
2021-11-13T17:21:44.000Z
2021-11-13T17:21:44.000Z
matplotlib-3.4.3/matplotlib-3.4.3/examples/mplot3d/lines3d.py
JohnLauFoo/clc_packages_Yu
259f01d9b5c02154ce258734d519ae8995cd0991
[ "MIT" ]
null
null
null
matplotlib-3.4.3/matplotlib-3.4.3/examples/mplot3d/lines3d.py
JohnLauFoo/clc_packages_Yu
259f01d9b5c02154ce258734d519ae8995cd0991
[ "MIT" ]
null
null
null
""" ================ Parametric Curve ================ This example demonstrates plotting a parametric curve in 3D. """ import numpy as np import matplotlib.pyplot as plt ax = plt.figure().add_subplot(projection='3d') # Prepare arrays x, y, z theta = np.linspace(-4 * np.pi, 4 * np.pi, 100) z = np.linspace(-2, 2, 1...
17.269231
60
0.610245
import numpy as np import matplotlib.pyplot as plt ax = plt.figure().add_subplot(projection='3d') theta = np.linspace(-4 * np.pi, 4 * np.pi, 100) z = np.linspace(-2, 2, 100) r = z**2 + 1 x = r * np.sin(theta) y = r * np.cos(theta) ax.plot(x, y, z, label='parametric curve') ax.legend() plt.show()
true
true
f7578dce3f97d742fef9a620e29c5eabe81153ac
36,907
py
Python
swagger_to/elm_client.py
koji8y/swagger-to
8c9201a71220b183aa55b10d61ec322008633f58
[ "MIT" ]
null
null
null
swagger_to/elm_client.py
koji8y/swagger-to
8c9201a71220b183aa55b10d61ec322008633f58
[ "MIT" ]
null
null
null
swagger_to/elm_client.py
koji8y/swagger-to
8c9201a71220b183aa55b10d61ec322008633f58
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 """Generate code for an Elm client.""" # pylint: disable=too-many-lines from typing import Optional, MutableMapping, List, Dict, TextIO, Any # pylint: disable=unused-import import collections import swagger_to import swagger_to.intermediate INDENT = ' ' * 4 class Typedef: """Represent a...
35.901751
120
0.635381
from typing import Optional, MutableMapping, List, Dict, TextIO, Any import collections import swagger_to import swagger_to.intermediate INDENT = ' ' * 4 class Typedef: def __init__(self) -> None: self.description = '' self.identifier = '' def __str__(self) -> str: return '{}({})...
true
true
f7578dd2b85828c539c786c7047d7d31a7251bec
41,854
py
Python
management/status_checks.py
ContainerizeUS/mailinabox
5b135738b4d6bde2977d5900a77855294e2a7ae0
[ "CC0-1.0" ]
1
2015-12-07T08:55:25.000Z
2015-12-07T08:55:25.000Z
management/status_checks.py
ContainerizeUS/mailinabox
5b135738b4d6bde2977d5900a77855294e2a7ae0
[ "CC0-1.0" ]
null
null
null
management/status_checks.py
ContainerizeUS/mailinabox
5b135738b4d6bde2977d5900a77855294e2a7ae0
[ "CC0-1.0" ]
1
2018-11-25T18:50:16.000Z
2018-11-25T18:50:16.000Z
#!/usr/bin/python3 # # Checks that the upstream DNS has been set correctly and that # SSL certificates have been signed, etc., and if not tells the user # what to do next. import sys, os, os.path, re, subprocess, datetime, multiprocessing.pool import dns.reversename, dns.resolver import dateutil.parser, dateutil.tz i...
44.525532
192
0.717924
import sys, os, os.path, re, subprocess, datetime, multiprocessing.pool import dns.reversename, dns.resolver import dateutil.parser, dateutil.tz import idna import psutil from dns_update import get_dns_zones, build_tlsa_record, get_custom_dns_config, get_secondary_dns, get_custom_dns_record from web_update import ge...
true
true
f7578ec4d3733ad6bea760f2ca67ceac04288a12
3,046
py
Python
aydin/it/demo/n2s/nn/2D_generic.py
AhmetCanSolak/aydin
e8bc81ee88c96e0f34986df30a63c96468a45f70
[ "BSD-3-Clause" ]
78
2021-11-08T16:11:23.000Z
2022-03-27T17:51:04.000Z
aydin/it/demo/n2s/nn/2D_generic.py
AhmetCanSolak/aydin
e8bc81ee88c96e0f34986df30a63c96468a45f70
[ "BSD-3-Clause" ]
19
2021-11-08T17:15:40.000Z
2022-03-30T17:46:55.000Z
aydin/it/demo/n2s/nn/2D_generic.py
AhmetCanSolak/aydin
e8bc81ee88c96e0f34986df30a63c96468a45f70
[ "BSD-3-Clause" ]
7
2021-11-09T17:42:32.000Z
2022-03-09T00:37:57.000Z
# flake8: noqa import os import time import numpy import numpy as np from skimage.data import camera from skimage.metrics import peak_signal_noise_ratio as psnr from skimage.metrics import structural_similarity as ssim from aydin.features.standard_features import StandardFeatureGenerator from aydin.io.datasets import...
31.081633
87
0.687131
import os import time import numpy import numpy as np from skimage.data import camera from skimage.metrics import peak_signal_noise_ratio as psnr from skimage.metrics import structural_similarity as ssim from aydin.features.standard_features import StandardFeatureGenerator from aydin.io.datasets import newyork, polle...
true
true
f757903bd63ba0ca4c5b1d40b1c591e37c3e2fcf
10,726
py
Python
main.py
maxkunes/Blender-To-DayZ
beae1c3f50588c134eadf38909060bd7cfd6017d
[ "MIT" ]
4
2020-09-24T18:21:46.000Z
2021-08-13T14:18:51.000Z
main.py
maxkunes/Blender-To-DayZ
beae1c3f50588c134eadf38909060bd7cfd6017d
[ "MIT" ]
null
null
null
main.py
maxkunes/Blender-To-DayZ
beae1c3f50588c134eadf38909060bd7cfd6017d
[ "MIT" ]
2
2020-09-24T12:24:49.000Z
2022-02-01T10:50:38.000Z
import bpy import bmesh from inspect import getmembers from pprint import pprint class SetupOperator(bpy.types.Operator): bl_idname = "blendertodayz.setup" bl_label = "Reset Scene" def remove_object(self, obj): if isinstance(obj, bpy.types.Collection): for child_col in obj.children: ...
29.794444
180
0.558922
import bpy import bmesh from inspect import getmembers from pprint import pprint class SetupOperator(bpy.types.Operator): bl_idname = "blendertodayz.setup" bl_label = "Reset Scene" def remove_object(self, obj): if isinstance(obj, bpy.types.Collection): for child_col in obj.children: ...
true
true
f75790bc09453573fcc96ae0a88023ca1245f578
2,556
py
Python
layer_list_to_darknet.py
xhuohai/kendryte-model-compiler
b6ef72b5db83a3b421046150ff3e77843c2be5bb
[ "Apache-2.0" ]
null
null
null
layer_list_to_darknet.py
xhuohai/kendryte-model-compiler
b6ef72b5db83a3b421046150ff3e77843c2be5bb
[ "Apache-2.0" ]
null
null
null
layer_list_to_darknet.py
xhuohai/kendryte-model-compiler
b6ef72b5db83a3b421046150ff3e77843c2be5bb
[ "Apache-2.0" ]
null
null
null
''' * Copyright 2018 Canaan 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 agreed to...
37.588235
89
0.621674
import tensor_list_to_layer_list import numpy def gen_config_file(layers): ret = [] for layer in layers: assert (isinstance(layer, tensor_list_to_layer_list.LayerBase)) ret.append('[' + layer.name + ']') for k, v in layer.config.items(): ret.append(str(k) + '=' + str(v)) ...
true
true
f757917778e4bee917cc0d37b98df50928f63970
422
py
Python
Numeric Patterns/numericpattern101.py
vaidehisinha1/Python-PatternHouse
49f71bcc5319a838592e69b0e49ef1edba32bf7c
[ "MIT" ]
null
null
null
Numeric Patterns/numericpattern101.py
vaidehisinha1/Python-PatternHouse
49f71bcc5319a838592e69b0e49ef1edba32bf7c
[ "MIT" ]
471
2022-01-15T07:07:18.000Z
2022-02-28T16:01:42.000Z
Numeric Patterns/numericpattern101.py
vaidehisinha1/Python-PatternHouse
49f71bcc5319a838592e69b0e49ef1edba32bf7c
[ "MIT" ]
2
2022-01-17T09:43:16.000Z
2022-01-29T15:15:47.000Z
def pattern(n): count = n for i in range(n): for j in range(n - i - 1): print(' ', end='') for k in range(2 * i + 1): print(count, end='') count = count - 1 print() print("Enter the number of rows: ") n = int(input()) patt...
14.066667
35
0.445498
def pattern(n): count = n for i in range(n): for j in range(n - i - 1): print(' ', end='') for k in range(2 * i + 1): print(count, end='') count = count - 1 print() print("Enter the number of rows: ") n = int(input()) patt...
true
true
f75791fad16120b7ce692ddbeeb1db89b7abd54c
40,295
py
Python
python/pyspark/sql/types.py
irgb/spark
ec8973d1245d4a99edeb7365d7f4b0063ac31ddf
[ "Apache-2.0", "MIT" ]
1
2015-07-17T14:30:08.000Z
2015-07-17T14:30:08.000Z
python/pyspark/sql/types.py
newscred/spark
257236c3e17906098f801cbc2059e7a9054e8cab
[ "Apache-2.0", "MIT" ]
1
2021-06-23T21:23:30.000Z
2021-06-23T21:23:30.000Z
python/pyspark/sql/types.py
newscred/spark
257236c3e17906098f801cbc2059e7a9054e8cab
[ "Apache-2.0", "MIT" ]
1
2020-07-23T14:03:42.000Z
2020-07-23T14:03:42.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 us...
31.603922
100
0.60943
import sys import decimal import time import datetime import calendar import json import re from array import array if sys.version >= "3": long = int unicode = str from py4j.protocol import register_input_converter from py4j.java_gateway import JavaClass __all__ = [ "DataType", "NullType", "StringType",...
true
true
f7579247e769863a785fed95c9e367f880c7fa20
14,850
py
Python
analysis/main.py
arrismo/tripods-testing
4ab9a7059df84cfd1f8984960900a3cf80b5c13c
[ "ECL-2.0" ]
null
null
null
analysis/main.py
arrismo/tripods-testing
4ab9a7059df84cfd1f8984960900a3cf80b5c13c
[ "ECL-2.0" ]
null
null
null
analysis/main.py
arrismo/tripods-testing
4ab9a7059df84cfd1f8984960900a3cf80b5c13c
[ "ECL-2.0" ]
null
null
null
# -*- coding: utf-8 -*- #Import Statements import pandas as pd import numpy as np import nltk import spacy import courseToBOK nltk.download('punkt') nltk.download('stopwords') nltk.download('wordnet') nltk.download('averaged_perceptron_tagger') import re from re import * from nltk.util import ngrams from nltk.corpus...
44.196429
219
0.711785
import pandas as pd import numpy as np import nltk import spacy import courseToBOK nltk.download('punkt') nltk.download('stopwords') nltk.download('wordnet') nltk.download('averaged_perceptron_tagger') import re from re import * from nltk.util import ngrams from nltk.corpus import stopwords import gower import matpl...
true
true
f757937d8b67e054895b249a7095c9820b7c8fd3
4,021
py
Python
problems/test_compare_text_read.py
gregdferrell/algo
974ae25b028d49bcb7ded6655a7e11dcf6aa221d
[ "MIT" ]
null
null
null
problems/test_compare_text_read.py
gregdferrell/algo
974ae25b028d49bcb7ded6655a7e11dcf6aa221d
[ "MIT" ]
null
null
null
problems/test_compare_text_read.py
gregdferrell/algo
974ae25b028d49bcb7ded6655a7e11dcf6aa221d
[ "MIT" ]
null
null
null
from .compare_text_read import compare_text, get_all_possible_mappings def test_get_all_possible_mappings_1(): orig = [1, 2, 3, 5] alt = [0, 1, 2, 3, 4, 5, 4, 3, 2] result = get_all_possible_mappings(orig, alt) assert len(result) == 4 assert len(result[0]) == 1 assert 1 in result[0] assert len(result[1]) == 2...
24.077844
70
0.613529
from .compare_text_read import compare_text, get_all_possible_mappings def test_get_all_possible_mappings_1(): orig = [1, 2, 3, 5] alt = [0, 1, 2, 3, 4, 5, 4, 3, 2] result = get_all_possible_mappings(orig, alt) assert len(result) == 4 assert len(result[0]) == 1 assert 1 in result[0] assert len(result[1]) == 2...
true
true
f75793fdc201b3002fdff56c1f17bdc8c2acbbf2
3,451
py
Python
SupertoolsPOST.py
wholesomegarden/WhatsappReminder
c6814c28b78738e36f2a82df65c4bc6714ce68da
[ "MIT" ]
null
null
null
SupertoolsPOST.py
wholesomegarden/WhatsappReminder
c6814c28b78738e36f2a82df65c4bc6714ce68da
[ "MIT" ]
null
null
null
SupertoolsPOST.py
wholesomegarden/WhatsappReminder
c6814c28b78738e36f2a82df65c4bc6714ce68da
[ "MIT" ]
null
null
null
אוהבים את סופרטולז אבל לא רוצים להיכנס לפייסבוק?! קבלו את סופרטולז לוואטאפ! 🚀 (beta) בשבועיים האחרונים פיתחתי פלטפורמה לסרוויסים לוואטסאפ מה הכוונה? כל רעויון לאפלקיציה שיש לכם יכולה עכשיו להשתמש בוואטספ כinput והoutput שלה! ומאפשרת whatsapp automation ברמה גבוהה מאוד. התכוונתי לשתף פה את המערכת וחשבתי מה יהיה יותר ...
56.57377
267
0.784121
אוהבים את סופרטולז אבל לא רוצים להיכנס לפייסבוק?! קבלו את סופרטולז לוואטאפ! 🚀 (beta) בשבועיים האחרונים פיתחתי פלטפורמה לסרוויסים לוואטסאפ מה הכוונה? כל רעויון לאפלקיציה שיש לכם יכולה עכשיו להשתמש בוואטספ כinput והoutput שלה! ומאפשרת whatsapp automation ברמה גבוהה מאוד. התכוונתי לשתף פה את המערכת וחשבתי מה יהיה יותר ...
false
true
f75794941e9a5106486e25d94a7619948a47cbb4
3,448
py
Python
tests/suite/test_transport_server_status.py
snebel29/kubernetes-ingress
a31cd87288fa102ef9f094da7ecd371e9b36c680
[ "Apache-2.0" ]
1
2022-03-02T19:05:19.000Z
2022-03-02T19:05:19.000Z
tests/suite/test_transport_server_status.py
snebel29/kubernetes-ingress
a31cd87288fa102ef9f094da7ecd371e9b36c680
[ "Apache-2.0" ]
228
2021-02-06T17:28:21.000Z
2022-03-31T02:08:34.000Z
tests/suite/test_transport_server_status.py
snebel29/kubernetes-ingress
a31cd87288fa102ef9f094da7ecd371e9b36c680
[ "Apache-2.0" ]
1
2021-08-10T10:54:04.000Z
2021-08-10T10:54:04.000Z
import pytest from suite.resources_utils import wait_before_test from suite.custom_resources_utils import ( read_ts, patch_ts, ) from settings import TEST_DATA @pytest.mark.ts @pytest.mark.parametrize( "crd_ingress_controller, transport_server_setup", [ ( { "type":...
30.785714
89
0.583817
import pytest from suite.resources_utils import wait_before_test from suite.custom_resources_utils import ( read_ts, patch_ts, ) from settings import TEST_DATA @pytest.mark.ts @pytest.mark.parametrize( "crd_ingress_controller, transport_server_setup", [ ( { "type":...
true
true
f75794ba73d51f5a23821507da1fd9eb10a7707e
637
py
Python
app/utils.py
pyghassen/discount-codes-generator-job
c314acc9d578ad4f8ba5bf962a7e1169c9b97a31
[ "MIT" ]
null
null
null
app/utils.py
pyghassen/discount-codes-generator-job
c314acc9d578ad4f8ba5bf962a7e1169c9b97a31
[ "MIT" ]
null
null
null
app/utils.py
pyghassen/discount-codes-generator-job
c314acc9d578ad4f8ba5bf962a7e1169c9b97a31
[ "MIT" ]
null
null
null
import random import string def generate_codes(number_of_codes: int, code_length: int): """Generates X number of random codes based on the provided length. Pramas: ------- number_of_codes (int): The number of the random codes that shall be created which should be unique also. ...
31.85
89
0.6719
import random import string def generate_codes(number_of_codes: int, code_length: int): codes = set() choices = string.ascii_uppercase + string.digits while len(codes) < number_of_codes: code = ''.join(random.SystemRandom().choice(choices) for _ in range(code_length)) codes.add(code) r...
true
true
f757955a469acb1f229032ce9cab3a2e5dbb1622
3,987
py
Python
src/comtris.py
837477/COMTRIS_AI
2cb49a9a9c5de785d6b1a864abf8d5eeb6db3302
[ "MIT" ]
2
2021-01-18T11:27:15.000Z
2021-01-26T15:49:50.000Z
src/comtris.py
837477/COMTRIS_AI
2cb49a9a9c5de785d6b1a864abf8d5eeb6db3302
[ "MIT" ]
null
null
null
src/comtris.py
837477/COMTRIS_AI
2cb49a9a9c5de785d6b1a864abf8d5eeb6db3302
[ "MIT" ]
1
2021-01-18T11:05:37.000Z
2021-01-18T11:05:37.000Z
import os import torch import torch.nn as nn import numpy as np from pymongo import MongoClient class Net(nn.Module): def __init__(self, D_in, D_out): super(Net,self).__init__() self.layer_1 = nn.Linear(D_in, D_out*2) self.layer_out = nn.Linear(D_out*2, D_out) self.relu = nn.ReLU()...
32.680328
110
0.520943
import os import torch import torch.nn as nn import numpy as np from pymongo import MongoClient class Net(nn.Module): def __init__(self, D_in, D_out): super(Net,self).__init__() self.layer_1 = nn.Linear(D_in, D_out*2) self.layer_out = nn.Linear(D_out*2, D_out) self.relu = nn.ReLU()...
true
true
f75795a1973b5b08811b277aebf2722348e9f637
1,327
py
Python
controllers/sponsors.py
bkahlerventer/web2congress
30463ef05a64b95f9ec8a5575e1f45a99986b607
[ "BSD-3-Clause" ]
3
2016-12-29T23:02:35.000Z
2021-07-01T01:10:12.000Z
controllers/sponsors.py
reingart/web2conf
a5e01d9fc2c25b271db7cee528faef58a46e7106
[ "BSD-3-Clause" ]
null
null
null
controllers/sponsors.py
reingart/web2conf
a5e01d9fc2c25b271db7cee528faef58a46e7106
[ "BSD-3-Clause" ]
null
null
null
# coding: utf8 # try something like def index(): rows = db((db.sponsor.text!="")&(db.sponsor.active==True)&(db.sponsor.level!=SPONSOR_LEVELS[-3])).select() if rows: return dict(sponsors_detail=rows) else: return plugin_flatpage() def prospectus(): return plugin_flatpage() @auth.requires_lo...
31.595238
110
0.635268
def index(): rows = db((db.sponsor.text!="")&(db.sponsor.active==True)&(db.sponsor.level!=SPONSOR_LEVELS[-3])).select() if rows: return dict(sponsors_detail=rows) else: return plugin_flatpage() def prospectus(): return plugin_flatpage() @auth.requires_login() def sign_up(): if request....
true
true
f757975469f58bda98c08b074c994dd6756c92eb
3,643
py
Python
python/benchmark_plotter/latexify.py
tum-db/partitioned-filters
56c20102715a442cbec9ecb732d41de15b31c828
[ "MIT" ]
5
2021-08-16T17:48:45.000Z
2022-03-10T22:53:54.000Z
python/benchmark_plotter/latexify.py
tum-db/partitioned-filters
56c20102715a442cbec9ecb732d41de15b31c828
[ "MIT" ]
null
null
null
python/benchmark_plotter/latexify.py
tum-db/partitioned-filters
56c20102715a442cbec9ecb732d41de15b31c828
[ "MIT" ]
null
null
null
import matplotlib import matplotlib.pyplot as plt from matplotlib.ticker import AutoMinorLocator, FuncFormatter import numpy as np def latexify(fig_width=None, fig_height=None, columns=1): """Set up matplotlib's RC params for LaTeX plotting. Call this before plotting a figure. Parameters ---------- ...
33.422018
119
0.622015
import matplotlib import matplotlib.pyplot as plt from matplotlib.ticker import AutoMinorLocator, FuncFormatter import numpy as np def latexify(fig_width=None, fig_height=None, columns=1): assert (columns in [1, 2]) if fig_width is None: fig_width = 3.39 if columns == 1 else 6.9 ...
true
true
f75797ba33f67aed0eb393930a7ffe6ad18554a5
17,544
py
Python
capstone/config/settings/settings_base.py
ChefAndy/capstone
bac7c44518312c5b64462ea92ecbabdcb5d29bb6
[ "MIT" ]
null
null
null
capstone/config/settings/settings_base.py
ChefAndy/capstone
bac7c44518312c5b64462ea92ecbabdcb5d29bb6
[ "MIT" ]
3
2018-11-29T17:48:45.000Z
2019-10-22T19:00:39.000Z
capstone/config/settings/settings_base.py
ChefAndy/capstone
bac7c44518312c5b64462ea92ecbabdcb5d29bb6
[ "MIT" ]
null
null
null
import os import sys from copy import deepcopy # Build paths inside the project like this: os.path.join(BASE_DIR, ...) BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__)))) SERVICES_DIR = os.path.join(os.path.dirname(BASE_DIR), 'services') ALLOWED_HOSTS = ['localhost', '127.0.0.1',...
29.485714
158
0.649681
import os import sys from copy import deepcopy BASE_DIR = os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__)))) SERVICES_DIR = os.path.join(os.path.dirname(BASE_DIR), 'services') ALLOWED_HOSTS = ['localhost', '127.0.0.1', '[::1]', '.test'] ADMINS = [('Caselaw Access Project', 'info@case.law'...
true
true
f757989afe2770c5ee2356aae8e676b16fe687c5
11,694
py
Python
gnes/base/__init__.py
awesome-archive/gnes
21311f05747303d0acdc303f2ade830ef971f47d
[ "Apache-2.0" ]
null
null
null
gnes/base/__init__.py
awesome-archive/gnes
21311f05747303d0acdc303f2ade830ef971f47d
[ "Apache-2.0" ]
null
null
null
gnes/base/__init__.py
awesome-archive/gnes
21311f05747303d0acdc303f2ade830ef971f47d
[ "Apache-2.0" ]
null
null
null
# Tencent is pleased to support the open source community by making GNES available. # # Copyright (C) 2019 THL A29 Limited, a Tencent company. 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...
34.093294
118
0.595006
import inspect import os import pickle import tempfile import uuid from functools import wraps from typing import Dict, Any, Union, TextIO, TypeVar, Type import ruamel.yaml.constructor from ..helper import set_logger, profiling, yaml, parse_arg, touch_dir, FileLock __all__ = ['TrainableBase'] T = TypeVar('T', bo...
true
true
f75799301b3763b5158c4600bfcffeaf50334491
294
py
Python
aging/environment_processing/__init__.py
Deep-Learning-and-Aging/Scalars-based-models-and-XWAS-pipeline
f6913ce4ec1f6aed358ba27fdf575257f712c132
[ "MIT" ]
null
null
null
aging/environment_processing/__init__.py
Deep-Learning-and-Aging/Scalars-based-models-and-XWAS-pipeline
f6913ce4ec1f6aed358ba27fdf575257f712c132
[ "MIT" ]
null
null
null
aging/environment_processing/__init__.py
Deep-Learning-and-Aging/Scalars-based-models-and-XWAS-pipeline
f6913ce4ec1f6aed358ba27fdf575257f712c132
[ "MIT" ]
null
null
null
from . import base_processing from . import FamilyHistory from . import HealthAndMedicalHistory from . import LifestyleAndEnvironment from . import PsychosocialFactors from . import SocioDemographics """ Pre-processing classes. Load and select features for each dataset in the UK biobank. """
24.5
60
0.812925
from . import base_processing from . import FamilyHistory from . import HealthAndMedicalHistory from . import LifestyleAndEnvironment from . import PsychosocialFactors from . import SocioDemographics
true
true