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
417k
max_line_length
int64
1
987k
alphanum_fraction
float64
0
1
content_no_comment
stringlengths
0
1.01M
is_comment_constant_removed
bool
1 class
is_sharp_comment_removed
bool
1 class
f755ef8efecc43089b5915b9326ba87555971bbe
414
py
Python
server/app/wsgi.py
copyit/face-replace
373d50564b2a870ae002c502db0b276203f296d4
[ "MIT" ]
13
2020-11-05T20:06:28.000Z
2020-12-23T02:16:59.000Z
server/app/wsgi.py
copyit/face-replace
373d50564b2a870ae002c502db0b276203f296d4
[ "MIT" ]
1
2021-06-08T22:20:59.000Z
2021-06-08T22:20:59.000Z
server/app/wsgi.py
copyit/face-replace
373d50564b2a870ae002c502db0b276203f296d4
[ "MIT" ]
5
2020-11-05T20:06:52.000Z
2020-12-29T22:51:23.000Z
# wsgi entrypoint for gunicorn # https://www.digitalocean.com/community/tutorials/how-to-serve-flask-applications-with-gunicorn-and-nginx-on-ubuntu-18-04 from app import app from flask import Flask if __name__ == "__main__": # Session(app) app.debug = True app.config["SESSION_TYPE"] = "filesystem" # se...
29.571429
122
0.698068
from app import app from flask import Flask if __name__ == "__main__": app.debug = True app.config["SESSION_TYPE"] = "filesystem" app.run()
true
true
f755ef95c8988a4813dbf65b9b1a44f6fd2a1307
323
py
Python
setup.py
pexip/os-pytoml
9b930248d1f37ee23689e45c9bab6a0d85ae5678
[ "MIT-0" ]
null
null
null
setup.py
pexip/os-pytoml
9b930248d1f37ee23689e45c9bab6a0d85ae5678
[ "MIT-0" ]
null
null
null
setup.py
pexip/os-pytoml
9b930248d1f37ee23689e45c9bab6a0d85ae5678
[ "MIT-0" ]
null
null
null
#!/usr/bin/env python # coding: utf-8 from setuptools import setup setup( name='pytoml', version='0.1.2', description='A parser for TOML-0.4.0', author='Martin Vejnár', author_email='avakar@ratatanek.cz', url='https://github.com/avakar/pytoml', license='MIT', packages=['pytoml'], ...
17.944444
43
0.628483
from setuptools import setup setup( name='pytoml', version='0.1.2', description='A parser for TOML-0.4.0', author='Martin Vejnár', author_email='avakar@ratatanek.cz', url='https://github.com/avakar/pytoml', license='MIT', packages=['pytoml'], )
true
true
f755f024a50d8a323c1e34e35e2fc527d63451eb
337
py
Python
mmdet/models/necks/__init__.py
Qianna00/mmdetection
31e7dff4c61000002d27117543b85e68d2619b4c
[ "Apache-2.0" ]
1
2021-08-01T08:44:35.000Z
2021-08-01T08:44:35.000Z
mmdet/models/necks/__init__.py
Qianna00/mmdetection
31e7dff4c61000002d27117543b85e68d2619b4c
[ "Apache-2.0" ]
null
null
null
mmdet/models/necks/__init__.py
Qianna00/mmdetection
31e7dff4c61000002d27117543b85e68d2619b4c
[ "Apache-2.0" ]
null
null
null
from .bfp import BFP from .fpn import FPN from .fpn_carafe import FPN_CARAFE from .hrfpn import HRFPN from .nas_fpn import NASFPN from .nasfcos_fpn import NASFCOS_FPN from .pafpn import PAFPN from .fsr_generator import FSRGenerator __all__ = [ 'FPN', 'BFP', 'HRFPN', 'NASFPN', 'FPN_CARAFE', 'PAFPN', 'NASFCOS_FPN', ...
25.923077
89
0.753709
from .bfp import BFP from .fpn import FPN from .fpn_carafe import FPN_CARAFE from .hrfpn import HRFPN from .nas_fpn import NASFPN from .nasfcos_fpn import NASFCOS_FPN from .pafpn import PAFPN from .fsr_generator import FSRGenerator __all__ = [ 'FPN', 'BFP', 'HRFPN', 'NASFPN', 'FPN_CARAFE', 'PAFPN', 'NASFCOS_FPN', ...
true
true
f755f0ec7000ef5c3af9412c9ed292eb3f3344a3
3,409
py
Python
apps/ACL/forms.py
ExpoAshique/ProveBanking__s
f0b45fffea74d00d14014be27aa50fe5f42f6903
[ "MIT" ]
null
null
null
apps/ACL/forms.py
ExpoAshique/ProveBanking__s
f0b45fffea74d00d14014be27aa50fe5f42f6903
[ "MIT" ]
null
null
null
apps/ACL/forms.py
ExpoAshique/ProveBanking__s
f0b45fffea74d00d14014be27aa50fe5f42f6903
[ "MIT" ]
null
null
null
from django import forms from django.contrib.auth.models import Permission, Group from django.db.models import Q from django.utils.translation import ugettext as _ from med_social.utils import slugify from med_social.fields import MultiSelectizeModelField, SelectizeMultiInput from med_social.forms.base import Deletabl...
35.510417
104
0.62951
from django import forms from django.contrib.auth.models import Permission, Group from django.db.models import Q from django.utils.translation import ugettext as _ from med_social.utils import slugify from med_social.fields import MultiSelectizeModelField, SelectizeMultiInput from med_social.forms.base import Deletabl...
true
true
f755f234a8942f5412b6cb04664319cc30e92454
1,326
py
Python
theoops/rules/brew_install.py
samzhang111/oops
5823623f94f7c4cdeccea4938c1a0efd4280184e
[ "MIT" ]
null
null
null
theoops/rules/brew_install.py
samzhang111/oops
5823623f94f7c4cdeccea4938c1a0efd4280184e
[ "MIT" ]
null
null
null
theoops/rules/brew_install.py
samzhang111/oops
5823623f94f7c4cdeccea4938c1a0efd4280184e
[ "MIT" ]
null
null
null
import os import re from theoops.utils import get_closest, replace_argument from theoops.specific.brew import get_brew_path_prefix, brew_available enabled_by_default = brew_available def _get_formulas(): # Formulas are based on each local system's status try: brew_path_prefix = get_brew_path_prefix()...
30.837209
79
0.677225
import os import re from theoops.utils import get_closest, replace_argument from theoops.specific.brew import get_brew_path_prefix, brew_available enabled_by_default = brew_available def _get_formulas(): try: brew_path_prefix = get_brew_path_prefix() brew_formula_path = brew_path_prefix + '/...
true
true
f755f27395b0d5c2d94fbda186111dfe5b5fd86f
5,994
py
Python
DockerENT/docker_plugins/docker_file_info.py
laozhudetui/DockerENT
8c369e503ca9b48889032d959e5ec7f50da0bb78
[ "MIT" ]
125
2020-09-03T07:23:08.000Z
2021-12-06T03:19:35.000Z
DockerENT/docker_plugins/docker_file_info.py
laozhudetui/DockerENT
8c369e503ca9b48889032d959e5ec7f50da0bb78
[ "MIT" ]
14
2020-06-26T04:23:04.000Z
2020-07-04T06:17:13.000Z
DockerENT/docker_plugins/docker_file_info.py
laozhudetui/DockerENT
8c369e503ca9b48889032d959e5ec7f50da0bb78
[ "MIT" ]
18
2020-07-05T05:08:58.000Z
2021-08-15T16:25:18.000Z
"""Docker file-system-info scan plugin.""" from DockerENT.utils import utils import docker import logging import json _log = logging.getLogger(__name__) _plugin_name_ = 'files-info' def scan(container, output_queue, audit=False, audit_queue=None): """Docker file-system-info plugin scan. :param container: ...
33.116022
152
0.547214
from DockerENT.utils import utils import docker import logging import json _log = logging.getLogger(__name__) _plugin_name_ = 'files-info' def scan(container, output_queue, audit=False, audit_queue=None): res = {} _log.info('Starting {} Plugin ...'.format(_plugin_name_)) api_client = docker.APIClient...
true
true
f755f2d59ebed1dd329b1d22ce45a5ae2e52e444
3,097
py
Python
test_dlen.py
Endika/dlen
48e954934c0ec8768bb85a2087c37068c4d70456
[ "MIT" ]
null
null
null
test_dlen.py
Endika/dlen
48e954934c0ec8768bb85a2087c37068c4d70456
[ "MIT" ]
null
null
null
test_dlen.py
Endika/dlen
48e954934c0ec8768bb85a2087c37068c4d70456
[ "MIT" ]
null
null
null
import dlen.dlen as dlen def test_blank_console(): """Test blank in command line.""" assert dlen.main() is None def test_blank(): """Test blank.""" assert dlen.DefLen(files_content=['']).show_console is False def test_good_def(): """Test good def.""" test_input = [( 'def demo_good_...
26.245763
68
0.549564
import dlen.dlen as dlen def test_blank_console(): assert dlen.main() is None def test_blank(): assert dlen.DefLen(files_content=['']).show_console is False def test_good_def(): test_input = [( 'def demo_good_test():\n' ' # line1\n' ' # line2\n' ' # line3\n' ...
true
true
f755f4b87d0f755ce6266eeefd832731ae9932db
5,257
py
Python
tests/cmd/subcommands/test_update.py
sbussetti/jenkins-job-builder
fc63f1439816d9022a2d538614b0b7592f96b454
[ "Apache-2.0" ]
null
null
null
tests/cmd/subcommands/test_update.py
sbussetti/jenkins-job-builder
fc63f1439816d9022a2d538614b0b7592f96b454
[ "Apache-2.0" ]
null
null
null
tests/cmd/subcommands/test_update.py
sbussetti/jenkins-job-builder
fc63f1439816d9022a2d538614b0b7592f96b454
[ "Apache-2.0" ]
null
null
null
# Joint copyright: # - Copyright 2015 Hewlett-Packard Development Company, L.P. # # 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 requ...
41.070313
85
0.687274
# of actions by the JJB library, usually through interaction with the # python-jenkins library. import os import six from tests.base import mock from tests.cmd.test_cmd import CmdTestsBase @mock.patch("jenkins_jobs.builder.JenkinsManager.get_plugins_info", mock.MagicMock) class UpdateTests(CmdTests...
true
true
f755f6a744fe58e225f35cad02632d111a30568e
371
py
Python
Aula07/chef010.py
AdryanPablo/Python
d469d394b41f44dbd753bf9a7f7eebaa81096562
[ "MIT" ]
null
null
null
Aula07/chef010.py
AdryanPablo/Python
d469d394b41f44dbd753bf9a7f7eebaa81096562
[ "MIT" ]
null
null
null
Aula07/chef010.py
AdryanPablo/Python
d469d394b41f44dbd753bf9a7f7eebaa81096562
[ "MIT" ]
null
null
null
# Crie um programa que leia quanto dinheiro uma pessoa tem na carteira e mostre quantos dólares ela pode comprar. # Considere US$1.00 = R$3.27. reais = float(input("Quantos reais você tem na carteira? R$")) cotdol = float(input("Qual a cotação do dólar hoje? 1$ == R$")) dolares = reais / cotdol print("Com R${:.2f} v...
37.1
113
0.700809
reais = float(input("Quantos reais você tem na carteira? R$")) cotdol = float(input("Qual a cotação do dólar hoje? 1$ == R$")) dolares = reais / cotdol print("Com R${:.2f} você pode comprar ${:.2f}.".format(reais, dolares))
true
true
f755f85b0fae902dd9a513b5ac13addf46dd31f9
1,199
py
Python
ilearn/TranSearch/config.py
PTYin/ESRT
4d3e5c523cef7bd15ea8ce10e5cf8b7e05ad2d5c
[ "BSD-2-Clause" ]
null
null
null
ilearn/TranSearch/config.py
PTYin/ESRT
4d3e5c523cef7bd15ea8ce10e5cf8b7e05ad2d5c
[ "BSD-2-Clause" ]
null
null
null
ilearn/TranSearch/config.py
PTYin/ESRT
4d3e5c523cef7bd15ea8ce10e5cf8b7e05ad2d5c
[ "BSD-2-Clause" ]
null
null
null
class Config: def __init__(self, dataset, main_path, stop_file, processed_path): # choose dataset name self.dataset = dataset # paths self.main_path = main_path self.stop_file = stop_file self.processed_path = processed_path self.full_path = processed_path ...
39.966667
86
0.673895
class Config: def __init__(self, dataset, main_path, stop_file, processed_path): self.dataset = dataset self.main_path = main_path self.stop_file = stop_file self.processed_path = processed_path self.full_path = processed_path + '{}_full.csv'.format(datas...
true
true
f755fa22e221d36a1a1f5d1ebea90e8b294bde31
1,646
py
Python
murano/tests/unit/packages/versions/test_hot_v1.py
ISCAS-VDI/murano-base
34287bd9109b32a2bb0960c0428fe402dee6d9b2
[ "Apache-2.0" ]
1
2021-07-28T23:19:49.000Z
2021-07-28T23:19:49.000Z
murano/tests/unit/packages/versions/test_hot_v1.py
ISCAS-VDI/murano-base
34287bd9109b32a2bb0960c0428fe402dee6d9b2
[ "Apache-2.0" ]
null
null
null
murano/tests/unit/packages/versions/test_hot_v1.py
ISCAS-VDI/murano-base
34287bd9109b32a2bb0960c0428fe402dee6d9b2
[ "Apache-2.0" ]
null
null
null
# # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # ...
35.782609
78
0.659174
import imghdr import os import murano.packages.load_utils as load_utils import murano.tests.unit.base as test_base class TestHotV1(test_base.MuranoTestCase): def test_supplier_info_load(self): package_dir = os.path.abspath( os.path.join(__file__, '../../test_packages/test.hot.v...
true
true
f755fa5c5120517509b6a8bf180e9e90f869b313
7,299
py
Python
src/apps/proxy/purpleserver/proxy/tests/test_pickup.py
blueprin4/purplship-server
e4817d6f6fb358adb10eab81153cf564fdcbc784
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
src/apps/proxy/purpleserver/proxy/tests/test_pickup.py
blueprin4/purplship-server
e4817d6f6fb358adb10eab81153cf564fdcbc784
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
src/apps/proxy/purpleserver/proxy/tests/test_pickup.py
blueprin4/purplship-server
e4817d6f6fb358adb10eab81153cf564fdcbc784
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
import json from unittest.mock import patch, ANY from django.urls import reverse from rest_framework import status from purplship.core.models import PickupDetails, ConfirmationDetails, ChargeDetails from purpleserver.core.tests import APITestCase class TesPickup(APITestCase): def test_schedule_pickup(self): ...
26.16129
83
0.564872
import json from unittest.mock import patch, ANY from django.urls import reverse from rest_framework import status from purplship.core.models import PickupDetails, ConfirmationDetails, ChargeDetails from purpleserver.core.tests import APITestCase class TesPickup(APITestCase): def test_schedule_pickup(self): ...
true
true
f755fac5d9aee10579e5afc235c491e99bff0f18
17,872
py
Python
magneticalc/SamplingVolume.py
shredEngineer/MagnetiCalc
bfccb8b6ef9a4642d30b2f0639b0ab41784598ad
[ "0BSD" ]
25
2020-10-24T09:21:25.000Z
2022-03-22T08:23:44.000Z
magneticalc/SamplingVolume.py
shredEngineer/MagnetiCalc
bfccb8b6ef9a4642d30b2f0639b0ab41784598ad
[ "0BSD" ]
8
2021-02-08T17:49:04.000Z
2022-01-09T18:19:37.000Z
magneticalc/SamplingVolume.py
shredEngineer/MagnetiCalc
bfccb8b6ef9a4642d30b2f0639b0ab41784598ad
[ "0BSD" ]
2
2020-12-30T11:02:49.000Z
2021-12-30T12:35:39.000Z
""" Sampling volume module. """ # ISC License # # Copyright (c) 2020–2021, Paul Wilhelm, M. Sc. <anfrage@paulwilhelm.de> # # Permission to use, copy, modify, and/or distribute this software for any # purpose with or without fee is hereby granted, provided that the above # copyright notice and this permission noti...
36.698152
120
0.529376
from typing import Tuple, List, Optional import numpy as np from PyQt5.QtCore import QThread from magneticalc.Assert_Dialog import Assert_Dialog from magneticalc.Debug import Debug from magneticalc.Theme import Theme class SamplingVolume: Debug_Constraints = False def __init__(self, re...
true
true
f755fb86e3e9dfadd4caa6c5d4fc67ede5747e5e
959
py
Python
ProxyPools/flask_api/flask_api.py
fst034356/crawler
98f0c1a129b3b5b77fe88971f4f0c6aae5a8964f
[ "MIT" ]
92
2017-03-06T06:32:49.000Z
2020-04-05T02:14:56.000Z
ProxyPools/flask_api/flask_api.py
GeraldDoubleJ/crawler
ab068b1b4d8d00336bb11cea0860244e0817e472
[ "MIT" ]
1
2018-06-03T10:38:26.000Z
2018-09-04T09:17:40.000Z
ProxyPools/flask_api/flask_api.py
GeraldDoubleJ/crawler
ab068b1b4d8d00336bb11cea0860244e0817e472
[ "MIT" ]
58
2017-04-09T11:18:40.000Z
2020-03-23T11:20:17.000Z
# coding=utf-8 # !/usr/bin/python3 from flask import Flask, jsonify, request from manage.manageProxy import Proxymanager app = Flask(__name__) api_list = { 'get': u'get an usable proxy', 'refresh': u'refresh proxy pool', 'get_all': u'get all proxy from proxy pool', 'delete?proxy=127.0.0.1:8080': u'd...
18.803922
61
0.666319
from flask import Flask, jsonify, request from manage.manageProxy import Proxymanager app = Flask(__name__) api_list = { 'get': u'get an usable proxy', 'refresh': u'refresh proxy pool', 'get_all': u'get all proxy from proxy pool', 'delete?proxy=127.0.0.1:8080': u'delete an unable proxy', } proxym...
true
true
f755fc4b063dc1233a6a9c7cb729fcfc17d80772
370
py
Python
farms/migrations/0005_auto_20201002_2314.py
protohaus/django-timescaledb-graphql-composition
436adee91ff2ca433f63c616bc7fbd566d57498f
[ "MIT" ]
null
null
null
farms/migrations/0005_auto_20201002_2314.py
protohaus/django-timescaledb-graphql-composition
436adee91ff2ca433f63c616bc7fbd566d57498f
[ "MIT" ]
null
null
null
farms/migrations/0005_auto_20201002_2314.py
protohaus/django-timescaledb-graphql-composition
436adee91ff2ca433f63c616bc7fbd566d57498f
[ "MIT" ]
null
null
null
# Generated by Django 3.1.2 on 2020-10-02 23:14 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('farms', '0004_auto_20201002_2301'), ] operations = [ migrations.RenameField( model_name='datapoint', old_name='date_type', ...
19.473684
47
0.591892
from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('farms', '0004_auto_20201002_2301'), ] operations = [ migrations.RenameField( model_name='datapoint', old_name='date_type', new_name='data_type', ), ...
true
true
f755fc4eb8009c1695a6b619f91c0f026f2028c4
10,198
py
Python
contrib/python/pytest/_pytest/skipping.py
HeyLey/catboost
f472aed90604ebe727537d9d4a37147985e10ec2
[ "Apache-2.0" ]
6,989
2017-07-18T06:23:18.000Z
2022-03-31T15:58:36.000Z
contrib/python/pytest/_pytest/skipping.py
HeyLey/catboost
f472aed90604ebe727537d9d4a37147985e10ec2
[ "Apache-2.0" ]
1,978
2017-07-18T09:17:58.000Z
2022-03-31T14:28:43.000Z
contrib/python/pytest/_pytest/skipping.py
HeyLey/catboost
f472aed90604ebe727537d9d4a37147985e10ec2
[ "Apache-2.0" ]
1,228
2017-07-18T09:03:13.000Z
2022-03-29T05:57:40.000Z
""" support for skip/xfail functions and markers. """ from __future__ import absolute_import from __future__ import division from __future__ import print_function from _pytest.config import hookimpl from _pytest.mark.evaluate import MarkEvaluator from _pytest.outcomes import fail from _pytest.outcomes import skip from...
34.107023
91
0.618455
from __future__ import absolute_import from __future__ import division from __future__ import print_function from _pytest.config import hookimpl from _pytest.mark.evaluate import MarkEvaluator from _pytest.outcomes import fail from _pytest.outcomes import skip from _pytest.outcomes import xfail def pytest_addoption(...
true
true
f755fc5b74c608daf39f0686c5a17c7b2531403f
2,440
py
Python
tests/test_parametric_components/test_center_column_shield_flat_top_circular.py
zmarkan/paramak
ecf9a46394adb4d6bb5744000ec6e2f74c30f2ba
[ "MIT" ]
9
2019-12-28T16:48:49.000Z
2020-05-20T13:38:49.000Z
tests/test_parametric_components/test_center_column_shield_flat_top_circular.py
zmarkan/paramak
ecf9a46394adb4d6bb5744000ec6e2f74c30f2ba
[ "MIT" ]
8
2019-08-23T10:17:19.000Z
2020-05-21T18:47:22.000Z
tests/test_parametric_components/test_center_column_shield_flat_top_circular.py
zmarkan/paramak
ecf9a46394adb4d6bb5744000ec6e2f74c30f2ba
[ "MIT" ]
1
2020-05-07T16:14:26.000Z
2020-05-07T16:14:26.000Z
import unittest import paramak class TestCenterColumnShieldFlatTopCircular(unittest.TestCase): def setUp(self): self.test_shape = paramak.CenterColumnShieldFlatTopCircular( height=600, arc_height=400, inner_radius=100, mid_radius=150, outer_radius=200) def test_default_parameters(self)...
34.857143
91
0.618033
import unittest import paramak class TestCenterColumnShieldFlatTopCircular(unittest.TestCase): def setUp(self): self.test_shape = paramak.CenterColumnShieldFlatTopCircular( height=600, arc_height=400, inner_radius=100, mid_radius=150, outer_radius=200) def test_default_parameters(self)...
true
true
f755fcaadca5e331b3087fb2453a8aeabb4711ff
2,319
py
Python
tests/unit/helpers/test_document_builder.py
BenGardiner/strictdoc
c927872a8f080ca1f86cdb7e99767fb25398dbd5
[ "Apache-2.0" ]
null
null
null
tests/unit/helpers/test_document_builder.py
BenGardiner/strictdoc
c927872a8f080ca1f86cdb7e99767fb25398dbd5
[ "Apache-2.0" ]
3
2022-02-21T10:57:01.000Z
2022-02-21T13:22:23.000Z
tests/unit/helpers/test_document_builder.py
BenGardiner/strictdoc
c927872a8f080ca1f86cdb7e99767fb25398dbd5
[ "Apache-2.0" ]
null
null
null
from strictdoc.backend.sdoc.document_reference import DocumentReference from strictdoc.backend.sdoc.models.document import Document from strictdoc.backend.sdoc.models.document_config import DocumentConfig from strictdoc.backend.sdoc.models.object_factory import SDocObjectFactory from strictdoc.backend.sdoc.models.refer...
34.61194
77
0.664511
from strictdoc.backend.sdoc.document_reference import DocumentReference from strictdoc.backend.sdoc.models.document import Document from strictdoc.backend.sdoc.models.document_config import DocumentConfig from strictdoc.backend.sdoc.models.object_factory import SDocObjectFactory from strictdoc.backend.sdoc.models.refer...
true
true
f755fcaff4d7f1e8da88b566f47517988593c88b
3,332
py
Python
socfaker/useragent.py
atstpls/soc-faker
119fcb9c4329a918ef9001ac5eaa36251b862bf0
[ "MIT" ]
null
null
null
socfaker/useragent.py
atstpls/soc-faker
119fcb9c4329a918ef9001ac5eaa36251b862bf0
[ "MIT" ]
null
null
null
socfaker/useragent.py
atstpls/soc-faker
119fcb9c4329a918ef9001ac5eaa36251b862bf0
[ "MIT" ]
null
null
null
import json, requests, datetime, random, os from bs4 import BeautifulSoup __USER_AGENT_URL__ = 'http://www.useragentstring.com/pages/useragentstring.php?name={}' class UserAgent(object): __DATA_PATH = os.path.abspath(os.path.join(os.path.dirname(__file__), 'data', 'useragent' + '.json')) BROWSER_LIST = ['...
35.827957
108
0.558824
import json, requests, datetime, random, os from bs4 import BeautifulSoup __USER_AGENT_URL__ = 'http://www.useragentstring.com/pages/useragentstring.php?name={}' class UserAgent(object): __DATA_PATH = os.path.abspath(os.path.join(os.path.dirname(__file__), 'data', 'useragent' + '.json')) BROWSER_LIST = ['...
true
true
f755fd6cf44431aa18b5bd57fd06cc23f32cd32c
253
py
Python
server/sucursal/urls.py
UM-2021/speect-to-text-app
76c64cf5adf9a26c1c867de1bb47dbc4ae2c0bc0
[ "Apache-2.0" ]
null
null
null
server/sucursal/urls.py
UM-2021/speect-to-text-app
76c64cf5adf9a26c1c867de1bb47dbc4ae2c0bc0
[ "Apache-2.0" ]
15
2021-04-21T22:51:33.000Z
2021-06-14T14:21:33.000Z
server/sucursal/urls.py
UM-2021/speect-to-text-app
76c64cf5adf9a26c1c867de1bb47dbc4ae2c0bc0
[ "Apache-2.0" ]
null
null
null
from django.urls import path, include from rest_framework.routers import DefaultRouter from . import views router = DefaultRouter() router.register(r'', views.SucursalViewSet) app_name = 'sucursal' urlpatterns = [ path('', include(router.urls)) ]
21.083333
48
0.758893
from django.urls import path, include from rest_framework.routers import DefaultRouter from . import views router = DefaultRouter() router.register(r'', views.SucursalViewSet) app_name = 'sucursal' urlpatterns = [ path('', include(router.urls)) ]
true
true
f755fd8b740f6490143ce2b8737bfadc09d3b3b9
182,905
py
Python
numpy/ma/tests/test_core.py
chunweiyuan/numpy
bfe43b26969231cfe8196868280c07f0c0aa8f50
[ "BSD-3-Clause" ]
null
null
null
numpy/ma/tests/test_core.py
chunweiyuan/numpy
bfe43b26969231cfe8196868280c07f0c0aa8f50
[ "BSD-3-Clause" ]
null
null
null
numpy/ma/tests/test_core.py
chunweiyuan/numpy
bfe43b26969231cfe8196868280c07f0c0aa8f50
[ "BSD-3-Clause" ]
null
null
null
# pylint: disable-msg=W0400,W0511,W0611,W0612,W0614,R0201,E1102 """Tests suite for MaskedArray & subclassing. :author: Pierre Gerard-Marchant :contact: pierregm_at_uga_dot_edu """ from __future__ import division, absolute_import, print_function __author__ = "Pierre GF Gerard-Marchant" import warnings import pickle i...
38.057636
81
0.513901
from __future__ import division, absolute_import, print_function __author__ = "Pierre GF Gerard-Marchant" import warnings import pickle import operator import itertools from functools import reduce import numpy as np import numpy.ma.core import numpy.core.fromnumeric as fromnumeric import numpy.core.umath as umath...
true
true
f755fd9e849d760c9b43ead6bece0013c59161f8
3,455
py
Python
datasets.py
bulletPr/label-efficient-unsupervised-learning
8e320dd96dab8de97d304e0fb6550cf3ae2aa022
[ "MIT" ]
null
null
null
datasets.py
bulletPr/label-efficient-unsupervised-learning
8e320dd96dab8de97d304e0fb6550cf3ae2aa022
[ "MIT" ]
null
null
null
datasets.py
bulletPr/label-efficient-unsupervised-learning
8e320dd96dab8de97d304e0fb6550cf3ae2aa022
[ "MIT" ]
null
null
null
from __future__ import print_function import torch.utils.data as data from PIL import Image import os import os.path import errno import torch import json import codecs import numpy as np import sys import torchvision.transforms as transforms import argparse import json #Part Dataset class PartDataset(data.Dataset): ...
33.872549
120
0.588133
from __future__ import print_function import torch.utils.data as data from PIL import Image import os import os.path import errno import torch import json import codecs import numpy as np import sys import torchvision.transforms as transforms import argparse import json class PartDataset(data.Dataset): def __init...
true
true
f755fdbc901267d93d60dfa7c77e6844c5dbbf41
486
py
Python
foundation/templatetags/extrafilters.py
tbone255/foundation
ca76fdd9b5345fead2d200f829eb67ba77bc865e
[ "MIT" ]
1
2019-03-14T17:02:46.000Z
2019-03-14T17:02:46.000Z
foundation/templatetags/extrafilters.py
tbone255/foundation
ca76fdd9b5345fead2d200f829eb67ba77bc865e
[ "MIT" ]
null
null
null
foundation/templatetags/extrafilters.py
tbone255/foundation
ca76fdd9b5345fead2d200f829eb67ba77bc865e
[ "MIT" ]
null
null
null
from django.template.defaultfilters import register @register.filter def cell_count(inline_form): """Returns the number of cells used in a tabular inline""" count = 1 # Hidden cell with hidden 'id' field for fieldset in inline_form: # Loop through all the fields (one per cell) for line in...
28.588235
62
0.639918
from django.template.defaultfilters import register @register.filter def cell_count(inline_form): count = 1 for fieldset in inline_form: for line in fieldset: for _ in line: count += 1 if inline_form.formset.can_delete: count += 1 return ...
true
true
f755ff7496b7e3a21d9e5090ca91aaaa8788edd4
22,330
py
Python
tests/kernels_test.py
sumau/PredictCode
e2a2d5a8fa5d83f011c33e18d4ce6ac7e1429aa8
[ "Artistic-2.0" ]
18
2017-04-19T09:17:19.000Z
2021-05-24T08:53:28.000Z
tests/kernels_test.py
sumau/PredictCode
e2a2d5a8fa5d83f011c33e18d4ce6ac7e1429aa8
[ "Artistic-2.0" ]
8
2017-06-11T17:46:35.000Z
2021-06-07T10:49:10.000Z
tests/kernels_test.py
sumau/PredictCode
e2a2d5a8fa5d83f011c33e18d4ce6ac7e1429aa8
[ "Artistic-2.0" ]
10
2017-07-19T18:29:37.000Z
2020-11-12T22:06:45.000Z
import numpy as np import scipy.stats as stats import scipy.linalg import pytest import open_cp.kernels as testmod import open_cp.data import unittest.mock as mock import shapely.geometry def slow_gaussian_kernel_new(pts, mean, var): """Test case where `pts`, `mean`, `var` are all of shape 2.""" assert(len(pts...
37.154742
110
0.61142
import numpy as np import scipy.stats as stats import scipy.linalg import pytest import open_cp.kernels as testmod import open_cp.data import unittest.mock as mock import shapely.geometry def slow_gaussian_kernel_new(pts, mean, var): assert(len(pts.shape) == 2 and len(mean.shape) == 2 and len(var.shape) == 2) ...
true
true
f755ffb96df6b28f1f1efc92a47997ac8800f5ce
1,141
py
Python
backend/research_note/migrations/0001_initial.py
andy23512/research-note-system
42a9d67de07a0f32615c4b9c6505b46e7c852f79
[ "MIT" ]
null
null
null
backend/research_note/migrations/0001_initial.py
andy23512/research-note-system
42a9d67de07a0f32615c4b9c6505b46e7c852f79
[ "MIT" ]
6
2021-06-04T23:01:14.000Z
2022-02-26T19:57:11.000Z
backend/research_note/migrations/0001_initial.py
andy23512/research-note-system
42a9d67de07a0f32615c4b9c6505b46e7c852f79
[ "MIT" ]
null
null
null
# Generated by Django 2.2.7 on 2019-11-10 08:49 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ ] operations = [ migrations.CreateModel( name='Issue', fields=[ ...
32.6
116
0.56617
from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ ] operations = [ migrations.CreateModel( name='Issue', fields=[ ('id', models.AutoField(auto_created=Tru...
true
true
f75600a3b5ffa94ff6a4136a0e344746949adbd2
1,606
py
Python
nova/tests/cast_as_call.py
vmthunder/nova
baf05caab705c5778348d9f275dc541747b7c2de
[ "Apache-2.0" ]
7
2015-09-22T11:27:16.000Z
2015-11-02T12:33:46.000Z
nova/tests/cast_as_call.py
vmthunder/nova
baf05caab705c5778348d9f275dc541747b7c2de
[ "Apache-2.0" ]
9
2015-05-20T11:20:17.000Z
2017-07-27T08:21:33.000Z
nova/tests/cast_as_call.py
vmthunder/nova
baf05caab705c5778348d9f275dc541747b7c2de
[ "Apache-2.0" ]
13
2015-05-05T09:34:04.000Z
2017-11-08T02:03:46.000Z
# Copyright 2013 Red Hat, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agre...
32.12
78
0.67995
import fixtures from oslo import messaging class CastAsCall(fixtures.Fixture): def __init__(self, stubs): super(CastAsCall, self).__init__() self.stubs = stubs @staticmethod def _stub_out(stubs, obj): orig_prepare = obj.prepare def prepare(self, *args, **k...
true
true
f75601b14f116a0908dfdee2768300df6aca648f
1,040
py
Python
ml/mxnet/tutorial/02_create_neural_net.py
rrbb014/rrbb-playground
5487078b882c4f0df3bacc7f55c47216bc201c04
[ "MIT" ]
null
null
null
ml/mxnet/tutorial/02_create_neural_net.py
rrbb014/rrbb-playground
5487078b882c4f0df3bacc7f55c47216bc201c04
[ "MIT" ]
null
null
null
ml/mxnet/tutorial/02_create_neural_net.py
rrbb014/rrbb-playground
5487078b882c4f0df3bacc7f55c47216bc201c04
[ "MIT" ]
null
null
null
from mxnet import nd from mxnet.gluon import nn net = nn.Sequential() net.add( nn.Conv2D( channels=6, kernel_size=5, activation='relu'), nn.MaxPool2D(pool_size=2, strides=2), nn.Conv2D( channels=16, kernel_size=3, activation='relu'), nn.MaxPool2D(pool_siz...
21.22449
47
0.577885
from mxnet import nd from mxnet.gluon import nn net = nn.Sequential() net.add( nn.Conv2D( channels=6, kernel_size=5, activation='relu'), nn.MaxPool2D(pool_size=2, strides=2), nn.Conv2D( channels=16, kernel_size=3, activation='relu'), nn.MaxPool2D(pool_siz...
true
true
f756024d4a19be4cb6cfff49ba2b678d72f87799
1,202
py
Python
src/dataset/__init__.py
KimythAnly/PyTorch-Voice-Conversion
a09cb26f3520da7d33595fbf65c3f7020bd49a0b
[ "MIT" ]
null
null
null
src/dataset/__init__.py
KimythAnly/PyTorch-Voice-Conversion
a09cb26f3520da7d33595fbf65c3f7020bd49a0b
[ "MIT" ]
null
null
null
src/dataset/__init__.py
KimythAnly/PyTorch-Voice-Conversion
a09cb26f3520da7d33595fbf65c3f7020bd49a0b
[ "MIT" ]
null
null
null
import os import importlib import logging from glob import glob root = os.path.dirname(__file__) logger = logging.getLogger(__name__) INVALID_MODULES = {} def _get_valid_datasets(): datasets = glob(os.path.join(root, '*.py')) valid_datasets = [] for dataset in datasets: basename = os.path.basen...
25.041667
76
0.671381
import os import importlib import logging from glob import glob root = os.path.dirname(__file__) logger = logging.getLogger(__name__) INVALID_MODULES = {} def _get_valid_datasets(): datasets = glob(os.path.join(root, '*.py')) valid_datasets = [] for dataset in datasets: basename = os.path.basen...
true
true
f7560358105b9f628a47c96b9fb5d7d95388b5aa
17,067
py
Python
python3-alpha/python3-src/Lib/heapq.py
stormtheh4ck3r/python-for-android
b9ea9161392f60566b81482b1e25cd77004d5c45
[ "Apache-2.0" ]
4
2016-05-04T07:05:22.000Z
2020-09-24T00:21:05.000Z
python3-alpha/python3-src/Lib/heapq.py
stormtheh4ck3r/python-for-android
b9ea9161392f60566b81482b1e25cd77004d5c45
[ "Apache-2.0" ]
null
null
null
python3-alpha/python3-src/Lib/heapq.py
stormtheh4ck3r/python-for-android
b9ea9161392f60566b81482b1e25cd77004d5c45
[ "Apache-2.0" ]
1
2018-12-12T03:06:17.000Z
2018-12-12T03:06:17.000Z
"""Heap queue algorithm (a.k.a. priority queue). Heaps are arrays for which a[k] <= a[2*k+1] and a[k] <= a[2*k+2] for all k, counting elements from 0. For the sake of comparison, non-existing elements are considered to be infinite. The interesting property of a heap is that a[0] is always its smallest element. Usag...
39.234483
81
0.653601
__about__ = """Heap queues [explanation by François Pinard] Heaps are arrays for which a[k] <= a[2*k+1] and a[k] <= a[2*k+2] for all k, counting elements from 0. For the sake of comparison, non-existing elements are considered to be infinite. The interesting property of a heap is that a[0] is always its smallest...
true
true
f756039c41aae8336aae2056bcf3f2f1335dbd24
16,307
py
Python
.history/src/Simulador_20200712191028.py
eduardodut/Trabalho_final_estatistica_cd
fbedbbea6bdd7a79e1d62030cde0fab4e93fc338
[ "MIT" ]
null
null
null
.history/src/Simulador_20200712191028.py
eduardodut/Trabalho_final_estatistica_cd
fbedbbea6bdd7a79e1d62030cde0fab4e93fc338
[ "MIT" ]
null
null
null
.history/src/Simulador_20200712191028.py
eduardodut/Trabalho_final_estatistica_cd
fbedbbea6bdd7a79e1d62030cde0fab4e93fc338
[ "MIT" ]
null
null
null
import pandas as pd import numpy as np from Matriz_esferica import Matriz_esferica from Individuo import Individuo, Fabrica_individuo import random from itertools import permutations import matplotlib.pyplot as plt from matplotlib.colors import ListedColormap from scipy.sparse import csr_matrix, lil_matrix import math...
42.355844
160
0.657141
import pandas as pd import numpy as np from Matriz_esferica import Matriz_esferica from Individuo import Individuo, Fabrica_individuo import random from itertools import permutations import matplotlib.pyplot as plt from matplotlib.colors import ListedColormap from scipy.sparse import csr_matrix, lil_matrix import math...
true
true
f75603f334a453f000de76adfe256c47a88f3386
759
py
Python
packages/3d_plotting/examples/viz_volume_structure.py
jorisvandenbossche/scipy-lecture-notes
689105f90db641eb1e1f82692f4d8b8492e8245d
[ "CC-BY-3.0" ]
3
2016-06-14T02:37:55.000Z
2019-08-08T16:52:09.000Z
packages/3d_plotting/examples/viz_volume_structure.py
jorisvandenbossche/scipy-lecture-notes
689105f90db641eb1e1f82692f4d8b8492e8245d
[ "CC-BY-3.0" ]
null
null
null
packages/3d_plotting/examples/viz_volume_structure.py
jorisvandenbossche/scipy-lecture-notes
689105f90db641eb1e1f82692f4d8b8492e8245d
[ "CC-BY-3.0" ]
1
2021-05-02T09:15:57.000Z
2021-05-02T09:15:57.000Z
""" Use Mayavi to visualize the structure of a VolumeImg """ from mayavi import mlab import numpy as np x, y, z = np.mgrid[-5:5:64j, -5:5:64j, -5:5:64j] data = x*x*0.5 + y*y + z*z*2.0 mlab.figure(1, fgcolor=(0, 0, 0), bgcolor=(1, 1, 1)) mlab.clf() src = mlab.pipeline.scalar_field(x, y, z, data) mlab.pipeline.surf...
26.172414
75
0.557312
from mayavi import mlab import numpy as np x, y, z = np.mgrid[-5:5:64j, -5:5:64j, -5:5:64j] data = x*x*0.5 + y*y + z*z*2.0 mlab.figure(1, fgcolor=(0, 0, 0), bgcolor=(1, 1, 1)) mlab.clf() src = mlab.pipeline.scalar_field(x, y, z, data) mlab.pipeline.surface(src, opacity=0.4) src2 = mlab.pipeline.scalar_field(x[::...
true
true
f7560403848ec8a2b99fbbc865c6046b1add35cb
323
py
Python
arc079_a.py
hythof/atc
12cb94ebe693e1f469ce0d982bc2924b586552cd
[ "CC0-1.0" ]
null
null
null
arc079_a.py
hythof/atc
12cb94ebe693e1f469ce0d982bc2924b586552cd
[ "CC0-1.0" ]
null
null
null
arc079_a.py
hythof/atc
12cb94ebe693e1f469ce0d982bc2924b586552cd
[ "CC0-1.0" ]
null
null
null
from collections import defaultdict N,M,*AB = [int(x) for x in open(0).read().split()] d = defaultdict(lambda: []) for i in range(0, len(AB), 2): a=AB[i] b=AB[i+1] d[a].append(b) d[b].append(a) for second in d[1]: if N in d[second]: print('POSSIBLE') break else: print('IMPOSSIBLE...
21.533333
50
0.572755
from collections import defaultdict N,M,*AB = [int(x) for x in open(0).read().split()] d = defaultdict(lambda: []) for i in range(0, len(AB), 2): a=AB[i] b=AB[i+1] d[a].append(b) d[b].append(a) for second in d[1]: if N in d[second]: print('POSSIBLE') break else: print('IMPOSSIBLE...
true
true
f756042cdbb1423a61ad0bf73c1ab34ce4864142
6,810
py
Python
salt-2016.3.3/salt/states/ini_manage.py
stephane-martin/salt-debian-packaging
4ec73750ba67bfe35a5bc0faa110f2bdec5c6a66
[ "Apache-2.0" ]
null
null
null
salt-2016.3.3/salt/states/ini_manage.py
stephane-martin/salt-debian-packaging
4ec73750ba67bfe35a5bc0faa110f2bdec5c6a66
[ "Apache-2.0" ]
null
null
null
salt-2016.3.3/salt/states/ini_manage.py
stephane-martin/salt-debian-packaging
4ec73750ba67bfe35a5bc0faa110f2bdec5c6a66
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- ''' Manage ini files ================ :maintainer: <akilesh1597@gmail.com> :maturity: new :depends: re :platform: all ''' __virtualname__ = 'ini' def __virtual__(): ''' Only load if the ini module is available ''' return __virtualname__ if 'ini.set_option' in __salt__ else ...
32.122642
94
0.536417
__virtualname__ = 'ini' def __virtual__(): return __virtualname__ if 'ini.set_option' in __salt__ else False def options_present(name, sections=None): ret = {'name': name, 'changes': {}, 'result': True, 'comment': 'No anomaly detected' } if __opts__['test']...
true
true
f75604522b4ddee998356a8ee625c77fe2159071
1,493
py
Python
tools/numpy_numerology.py
HEPonHPC/pandana3-prototype
d7656e93a16a3c992c3d21e65915fed2935dd8fc
[ "Apache-2.0" ]
null
null
null
tools/numpy_numerology.py
HEPonHPC/pandana3-prototype
d7656e93a16a3c992c3d21e65915fed2935dd8fc
[ "Apache-2.0" ]
null
null
null
tools/numpy_numerology.py
HEPonHPC/pandana3-prototype
d7656e93a16a3c992c3d21e65915fed2935dd8fc
[ "Apache-2.0" ]
null
null
null
import itertools def flattened_ranges(range_lengths): return list(itertools.chain.from_iterable(range(n) for n in range_lengths)) def take(n, gen): """Take the first n items from the generator gen. Return a list of that many items and the resulting state of the generator.""" lst = list(itertools.isl...
33.931818
93
0.689886
import itertools def flattened_ranges(range_lengths): return list(itertools.chain.from_iterable(range(n) for n in range_lengths)) def take(n, gen): lst = list(itertools.islice(gen, n)) return lst, gen def flatten_list(seq): return sum(seq, []) def repeated_indices(repetition_counts): return ...
true
true
f756060a2f54dd0ee4355913d99851904db354f2
16,538
py
Python
Cinder/Rocky/fs_flow.py
Huawei/FusionStorage_OpenStack_Driver
babc45731aee85ed387f0743ae697bce54384e30
[ "Apache-2.0" ]
11
2019-05-25T02:30:51.000Z
2021-12-08T06:32:44.000Z
Cinder/Stein/fs_flow.py
Huawei/FusionStorage_OpenStack_Driver
babc45731aee85ed387f0743ae697bce54384e30
[ "Apache-2.0" ]
3
2019-12-03T04:59:50.000Z
2021-09-30T09:43:00.000Z
Cinder/Rocky/fs_flow.py
Huawei/FusionStorage_OpenStack_Driver
babc45731aee85ed387f0743ae697bce54384e30
[ "Apache-2.0" ]
5
2019-09-23T05:49:03.000Z
2021-12-08T06:32:59.000Z
# Copyright (c) 2019 Huawei Technologies Co., Ltd. # 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 # # ...
40.336585
79
0.640464
from oslo_log import log as logging import taskflow.engines from taskflow.patterns import linear_flow from taskflow import task from taskflow.types import failure from cinder import exception from cinder.i18n import _ from cinder.volume.drivers.fusionstorage import fs_utils LOG = logging.getLogger(__...
true
true
f756080dd17b380d004420c045a8744411c0e93d
6,245
py
Python
fairseq/fairseq/tasks/hubert_pretraining.py
zhaoguangxiang/OFA
cc1719df2713f0a046f34acb0afd8782e08ea6be
[ "Apache-2.0" ]
16,259
2018-05-02T02:31:30.000Z
2022-03-31T21:50:23.000Z
fairseq/fairseq/tasks/hubert_pretraining.py
zhaoguangxiang/OFA
cc1719df2713f0a046f34acb0afd8782e08ea6be
[ "Apache-2.0" ]
3,863
2018-05-02T13:42:39.000Z
2022-03-31T19:03:32.000Z
fairseq/fairseq/tasks/hubert_pretraining.py
zhaoguangxiang/OFA
cc1719df2713f0a046f34acb0afd8782e08ea6be
[ "Apache-2.0" ]
4,796
2018-05-02T07:55:51.000Z
2022-03-31T14:46:45.000Z
# Copyright (c) 2017-present, Facebook, Inc. # All rights reserved. # # This source code is licensed under the license found in the LICENSE file in # the root directory of this source tree. An additional grant of patent rights # can be found in the PATENTS file in the same directory. import logging import os import sy...
31.862245
102
0.631705
import logging import os import sys from typing import Dict, List, Optional, Tuple import numpy as np from dataclasses import dataclass, field from fairseq.data import Dictionary, HubertDataset from fairseq.dataclass.configs import FairseqDataclass from fairseq.tasks import register_task from fairseq.tasks.fai...
true
true
f756096bfb07a0ddfccecf4c5a90a427387a98a5
2,250
py
Python
shopping_ingredient/views.py
leichandra/mealplanshop
a10fb2f2d2967d6a00f27452d180cd1b302bc23a
[ "MIT" ]
null
null
null
shopping_ingredient/views.py
leichandra/mealplanshop
a10fb2f2d2967d6a00f27452d180cd1b302bc23a
[ "MIT" ]
3
2021-02-24T05:18:03.000Z
2021-03-11T04:07:03.000Z
shopping_ingredient/views.py
leichandra/mealplanshop
a10fb2f2d2967d6a00f27452d180cd1b302bc23a
[ "MIT" ]
null
null
null
from django.core.exceptions import ValidationError from django.forms import modelformset_factory from django.http import JsonResponse from django.shortcuts import render, redirect from django.views.decorators.csrf import csrf_exempt from rest_framework.decorators import api_view from rest_framework.response import Res...
38.793103
107
0.751111
from django.core.exceptions import ValidationError from django.forms import modelformset_factory from django.http import JsonResponse from django.shortcuts import render, redirect from django.views.decorators.csrf import csrf_exempt from rest_framework.decorators import api_view from rest_framework.response import Res...
true
true
f75609a8cad6af56b5d22f793ba87507ffda5104
8,514
py
Python
DevnagriLipiTrainer/Archive/TensorFlow4_ConvNN - V6.py
arvindershinh/DevnagriLipi
77539f2ecae68809bea5286a2113f1b723ae0a0f
[ "MIT" ]
null
null
null
DevnagriLipiTrainer/Archive/TensorFlow4_ConvNN - V6.py
arvindershinh/DevnagriLipi
77539f2ecae68809bea5286a2113f1b723ae0a0f
[ "MIT" ]
null
null
null
DevnagriLipiTrainer/Archive/TensorFlow4_ConvNN - V6.py
arvindershinh/DevnagriLipi
77539f2ecae68809bea5286a2113f1b723ae0a0f
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Sat Jul 28 22:26:40 2018 @author: Arvinder Shinh """ import tensorflow as tf from PIL import Image import numpy as np import os from tensorflow import saved_model as sm imageFiles=os.listdir('image') SerializedImgContainer=[] LabelContainer=[] for f in imageFiles: if f.end...
35.327801
148
0.672657
import tensorflow as tf from PIL import Image import numpy as np import os from tensorflow import saved_model as sm imageFiles=os.listdir('image') SerializedImgContainer=[] LabelContainer=[] for f in imageFiles: if f.endswith('.jpg'): fname, fext = os.path.splitext(f) label = 0 if fname == 'ka' else 1 ...
true
true
f7560a8961d3b437ef58d428b156b8312f804971
3,090
py
Python
networks/layers/spectral_norm.py
google-research/ibc
c2f6775418c3d7b1ffd0e822fc0050c834030d15
[ "Apache-2.0" ]
180
2021-11-05T19:34:29.000Z
2022-03-30T00:54:43.000Z
networks/layers/spectral_norm.py
google-research/ibc
c2f6775418c3d7b1ffd0e822fc0050c834030d15
[ "Apache-2.0" ]
5
2021-11-08T21:13:19.000Z
2022-03-17T08:42:03.000Z
networks/layers/spectral_norm.py
google-research/ibc
c2f6775418c3d7b1ffd0e822fc0050c834030d15
[ "Apache-2.0" ]
16
2021-11-07T05:43:06.000Z
2022-02-12T10:30:09.000Z
# coding=utf-8 # Copyright 2022 The Reach ML Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law ...
35.517241
77
0.650809
import tensorflow.compat.v2 as tf K = tf.keras.backend class DenseSN(tf.keras.layers.Dense): def build(self, input_shape): assert len(input_shape) >= 2 input_dim = input_shape[-1] self.kernel = self.add_weight(shape=(input_dim, self.units), initialize...
true
true
f7560ac87442f845341be61a4d786505b9cbe7a9
4,448
py
Python
algs/nsga_net/model/micro_encoding.py
Beautyya/BenchENA
5f5491614fc2f00ca26dc29f35f44c334db4718c
[ "MIT" ]
1
2022-01-21T07:56:13.000Z
2022-01-21T07:56:13.000Z
algs/nsga_net/model/micro_encoding.py
Beautyya/BenchENA
5f5491614fc2f00ca26dc29f35f44c334db4718c
[ "MIT" ]
1
2022-02-24T06:07:27.000Z
2022-02-24T06:07:27.000Z
BenchENAS_python_package/algs/nsga_net/model/micro_encoding.py
benchenas/BenchENAS
776cd1dd035d73c4af369d0106d010b932f64782
[ "MIT" ]
1
2022-01-20T07:36:37.000Z
2022-01-20T07:36:37.000Z
# NASNet Search Space https://arxiv.org/pdf/1707.07012.pdf # code modified from DARTS https://github.com/quark0/darts import numpy as np from collections import namedtuple import torch from algs.nsga_net.model.micro_models import NetworkCIFAR as Network Genotype = namedtuple('Genotype', 'normal normal_concat reduce r...
30.054054
83
0.604541
import numpy as np from collections import namedtuple import torch from algs.nsga_net.model.micro_models import NetworkCIFAR as Network Genotype = namedtuple('Genotype', 'normal normal_concat reduce reduce_concat') Genotype_norm = namedtuple('Genotype', 'normal normal_concat') Genotype_redu = namedtuple('Genotype',...
true
true
f7560b1c778d030b263cc66c094260e60e2ea46a
45
py
Python
CADRE/battery_dymos/__init__.py
johnjasa/CADRE
a4ffd61582b8474953fc309aa540838a14f29dcf
[ "Apache-2.0" ]
null
null
null
CADRE/battery_dymos/__init__.py
johnjasa/CADRE
a4ffd61582b8474953fc309aa540838a14f29dcf
[ "Apache-2.0" ]
null
null
null
CADRE/battery_dymos/__init__.py
johnjasa/CADRE
a4ffd61582b8474953fc309aa540838a14f29dcf
[ "Apache-2.0" ]
null
null
null
from .battery_soc_comp import BatterySOCComp
22.5
44
0.888889
from .battery_soc_comp import BatterySOCComp
true
true
f7560c887c895be37435fbb146afac4e56314c70
1,219
py
Python
travitia_talk/enums.py
Fogapod/travitia-talk
bc4dfc8175f63e40a323def1f0d5cca3385dc457
[ "MIT" ]
null
null
null
travitia_talk/enums.py
Fogapod/travitia-talk
bc4dfc8175f63e40a323def1f0d5cca3385dc457
[ "MIT" ]
null
null
null
travitia_talk/enums.py
Fogapod/travitia-talk
bc4dfc8175f63e40a323def1f0d5cca3385dc457
[ "MIT" ]
null
null
null
""" MIT License Copyright (c) 2021 Eugene Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distri...
35.852941
78
0.772765
from enum import Enum class Emotion(Enum): neutral = "neutral" sadness = "sadness" fear = "fear" joy = "joy" anger = "anger"
true
true
f7560c9f8981a8462afe0070d17a81372212c0dd
1,416
py
Python
jobbing/models_remote/working_area.py
davidall-amdocs/jobbing
b13311da07606366dfbe2eb737483a5820038557
[ "Apache-2.0" ]
null
null
null
jobbing/models_remote/working_area.py
davidall-amdocs/jobbing
b13311da07606366dfbe2eb737483a5820038557
[ "Apache-2.0" ]
null
null
null
jobbing/models_remote/working_area.py
davidall-amdocs/jobbing
b13311da07606366dfbe2eb737483a5820038557
[ "Apache-2.0" ]
null
null
null
# coding: utf-8 from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 from jobbing.models.base_model_ import Model from jobbing import util class WorkingArea(Model): def __init__(self, working_area_id:int = None, working_area_mun...
26.222222
102
0.762712
from __future__ import absolute_import from datetime import date, datetime from typing import List, Dict from jobbing.models.base_model_ import Model from jobbing import util class WorkingArea(Model): def __init__(self, working_area_id:int = None, working_area_municipality:int = None): self.swagger...
true
true
f7560df8be5ad5184e16224f34c0268b8ef196a4
12,738
py
Python
ue4docker/infrastructure/BuildConfiguration.py
e1d1s1/ue4-docker
3d19ab811b340b14027723942155ffe076893005
[ "MIT" ]
null
null
null
ue4docker/infrastructure/BuildConfiguration.py
e1d1s1/ue4-docker
3d19ab811b340b14027723942155ffe076893005
[ "MIT" ]
null
null
null
ue4docker/infrastructure/BuildConfiguration.py
e1d1s1/ue4-docker
3d19ab811b340b14027723942155ffe076893005
[ "MIT" ]
null
null
null
from .DockerUtils import DockerUtils from .PackageUtils import PackageUtils from .WindowsUtils import WindowsUtils import humanfriendly, os, platform, random from pkg_resources import parse_version # Import the `semver` package even when the conflicting `node-semver` package is present semver = PackageUtils.importFile...
49.181467
232
0.740462
from .DockerUtils import DockerUtils from .PackageUtils import PackageUtils from .WindowsUtils import WindowsUtils import humanfriendly, os, platform, random from pkg_resources import parse_version semver = PackageUtils.importFile('semver', os.path.join(PackageUtils.getPackageLocation('semver'), 'semver.py')) DEFAU...
true
true
f7560e6c6f2cffef71f837780bc97501e078a478
18,559
py
Python
sync/sync.py
vaikas/website-2
b57417551e339275d542cd6547daa3f4cae2be30
[ "Apache-2.0" ]
51
2019-03-13T10:56:02.000Z
2021-11-07T14:01:08.000Z
sync/sync.py
vaikas/website-2
b57417551e339275d542cd6547daa3f4cae2be30
[ "Apache-2.0" ]
357
2019-03-12T09:06:30.000Z
2022-03-28T13:37:14.000Z
sync/sync.py
vaikas/website-2
b57417551e339275d542cd6547daa3f4cae2be30
[ "Apache-2.0" ]
89
2019-03-11T18:02:42.000Z
2022-03-21T10:29:15.000Z
#!/usr/bin/env python # Copyright 2020 The Tekton Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable...
38.030738
114
0.663775
import copy import fnmatch import json import logging import markdown from multiprocessing import Pool import os import os.path import re import sys from urllib.error import URLError from urllib.parse import urlparse, urljoin, urlunparse from bs4 import BeautifulSoup import click import git from ji...
true
true
f75610577fb6c3b92e8861c4728d28d5d57ca186
612
py
Python
tweet/migrations/0002_tweet_author.py
jkube38/twitterclone
f25f2cdd81dcb0e2f12e8511c31f46cd0f1ea40f
[ "MIT" ]
null
null
null
tweet/migrations/0002_tweet_author.py
jkube38/twitterclone
f25f2cdd81dcb0e2f12e8511c31f46cd0f1ea40f
[ "MIT" ]
null
null
null
tweet/migrations/0002_tweet_author.py
jkube38/twitterclone
f25f2cdd81dcb0e2f12e8511c31f46cd0f1ea40f
[ "MIT" ]
null
null
null
# Generated by Django 3.1.7 on 2021-03-04 05:27 from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ ('tweet', '0001_initial'), migrations.swappable_dependency(settin...
25.5
139
0.671569
from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependencies = [ ('tweet', '0001_initial'), migrations.swappable_dependency(settings.AUTH_USER_MODEL), ] operations = [ ...
true
true
f756126b7f3881fc91e840846cf286ed830cc573
273
py
Python
tests/artificial/transf_Difference/trend_Lag1Trend/cycle_12/ar_12/test_artificial_1024_Difference_Lag1Trend_12_12_20.py
jmabry/pyaf
afbc15a851a2445a7824bf255af612dc429265af
[ "BSD-3-Clause" ]
null
null
null
tests/artificial/transf_Difference/trend_Lag1Trend/cycle_12/ar_12/test_artificial_1024_Difference_Lag1Trend_12_12_20.py
jmabry/pyaf
afbc15a851a2445a7824bf255af612dc429265af
[ "BSD-3-Clause" ]
1
2019-11-30T23:39:38.000Z
2019-12-01T04:34:35.000Z
tests/artificial/transf_Difference/trend_Lag1Trend/cycle_12/ar_12/test_artificial_1024_Difference_Lag1Trend_12_12_20.py
jmabry/pyaf
afbc15a851a2445a7824bf255af612dc429265af
[ "BSD-3-Clause" ]
null
null
null
import pyaf.Bench.TS_datasets as tsds import pyaf.tests.artificial.process_artificial_dataset as art art.process_dataset(N = 1024 , FREQ = 'D', seed = 0, trendtype = "Lag1Trend", cycle_length = 12, transform = "Difference", sigma = 0.0, exog_count = 20, ar_order = 12);
39
168
0.736264
import pyaf.Bench.TS_datasets as tsds import pyaf.tests.artificial.process_artificial_dataset as art art.process_dataset(N = 1024 , FREQ = 'D', seed = 0, trendtype = "Lag1Trend", cycle_length = 12, transform = "Difference", sigma = 0.0, exog_count = 20, ar_order = 12);
true
true
f756136ecbcad05f8d54744817d121c613249436
1,056
py
Python
unpack/unpack.py
jakiki6/unpacker
0704762156b45a8def8a814eb7f7d4eb721ed86b
[ "MIT" ]
4
2021-03-13T15:40:51.000Z
2021-04-21T17:18:09.000Z
unpack/unpack.py
jakiki6/unpacker
0704762156b45a8def8a814eb7f7d4eb721ed86b
[ "MIT" ]
null
null
null
unpack/unpack.py
jakiki6/unpacker
0704762156b45a8def8a814eb7f7d4eb721ed86b
[ "MIT" ]
null
null
null
#!/bin/env python3 import argparse, os import fileformats, romfs, exefs, slb2, scecaf, self, ncch, ncsd modes = { "guess": fileformats.guess, "romfs": romfs.process, "exefs": exefs.process, "slb2": slb2.process, "scecaf": scecaf.process, "self": self.process, "ncch": ncch.process, "nc...
27.789474
93
0.66572
import argparse, os import fileformats, romfs, exefs, slb2, scecaf, self, ncch, ncsd modes = { "guess": fileformats.guess, "romfs": romfs.process, "exefs": exefs.process, "slb2": slb2.process, "scecaf": scecaf.process, "self": self.process, "ncch": ncch.process, "ncsd": ncsd.process ...
true
true
f75614968b121ca1b4932959783c8ed5c4d54451
1,502
py
Python
wbb/utils/downloader.py
stylishsuryaa/JohnShelby
714d5f2a3306c9f15fe568e26b7fb63f46682168
[ "MIT" ]
null
null
null
wbb/utils/downloader.py
stylishsuryaa/JohnShelby
714d5f2a3306c9f15fe568e26b7fb63f46682168
[ "MIT" ]
1
2021-08-06T11:28:55.000Z
2021-08-06T11:28:55.000Z
wbb/utils/downloader.py
stylishsuryaa/JohnShelby
714d5f2a3306c9f15fe568e26b7fb63f46682168
[ "MIT" ]
1
2021-10-05T19:47:05.000Z
2021-10-05T19:47:05.000Z
from os.path import abspath as absolute_path from time import time import aiofiles from wbb import aiohttpsession as session from wbb.core.tasks import add_task def ensure_status(status_code: int): if status_code < 200 or status_code >= 300: raise Exception(f"HttpProcessingError: {status_code}") async...
23.84127
62
0.635153
from os.path import abspath as absolute_path from time import time import aiofiles from wbb import aiohttpsession as session from wbb.core.tasks import add_task def ensure_status(status_code: int): if status_code < 200 or status_code >= 300: raise Exception(f"HttpProcessingError: {status_code}") async...
true
true
f7561726394175de1424f96464e3a6eb658f87ac
12,965
py
Python
fabfile.py
nathanj/heltour
14c6e926e02e1c035c9037955af5673c5012d16c
[ "MIT" ]
null
null
null
fabfile.py
nathanj/heltour
14c6e926e02e1c035c9037955af5673c5012d16c
[ "MIT" ]
null
null
null
fabfile.py
nathanj/heltour
14c6e926e02e1c035c9037955af5673c5012d16c
[ "MIT" ]
null
null
null
import os import sys import datetime import strabulous from fabric.api import ( local, sudo, lcd, env, hosts, put, run, get, settings, shell_env, ) from fabric import colors from fabric.contrib.console import confirm from baste import ( DiffCommand, Git, OrderedDict...
39.769939
231
0.579329
import os import sys import datetime import strabulous from fabric.api import ( local, sudo, lcd, env, hosts, put, run, get, settings, shell_env, ) from fabric import colors from fabric.contrib.console import confirm from baste import ( DiffCommand, Git, OrderedDict...
true
true
f7561806d22b174b0586c9dbcfcde61b970f6199
928
py
Python
server/runchecks.py
NiveditJain/CS311-Project
deac88940b913956d03e9c605c0008f996a16ed2
[ "Apache-2.0" ]
1
2020-10-20T22:31:12.000Z
2020-10-20T22:31:12.000Z
server/runchecks.py
NiveditJain/CS311-Project
deac88940b913956d03e9c605c0008f996a16ed2
[ "Apache-2.0" ]
4
2020-10-04T08:28:20.000Z
2020-10-05T18:01:22.000Z
server/runchecks.py
NiveditJain/muZik
deac88940b913956d03e9c605c0008f996a16ed2
[ "Apache-2.0" ]
null
null
null
# checking all settings import settings import warnings print('Running SETTING Checks!') if type(settings.PORT) is not int: raise Exception('settings.PORT must be an integer') if settings.PORT < 0: raise Exception('settings.PORT Value cannot be negative') if settings.PORT < 1024: warnings.warn('You are ...
29.935484
88
0.755388
import settings import warnings print('Running SETTING Checks!') if type(settings.PORT) is not int: raise Exception('settings.PORT must be an integer') if settings.PORT < 0: raise Exception('settings.PORT Value cannot be negative') if settings.PORT < 1024: warnings.warn('You are using a "Well Known Por...
true
true
f75618bf900c6c2d1d02319910edcc36bda5bcf0
8,283
py
Python
Project1/Code/training configs/TTA/final_convnext_l_test_TTA_4.py
AccSrd/NTU_MSAI_AI6126_AdvancedComputerVision
cc7516e903f080cc88180eed29835b611811eb1f
[ "Apache-2.0" ]
1
2022-03-14T14:26:21.000Z
2022-03-14T14:26:21.000Z
Project1/Code/training configs/TTA/final_convnext_l_test_TTA_4.py
AccSrd/NTU_MSAI_AI6126_AdvancedComputerVision
cc7516e903f080cc88180eed29835b611811eb1f
[ "Apache-2.0" ]
null
null
null
Project1/Code/training configs/TTA/final_convnext_l_test_TTA_4.py
AccSrd/NTU_MSAI_AI6126_AdvancedComputerVision
cc7516e903f080cc88180eed29835b611811eb1f
[ "Apache-2.0" ]
null
null
null
norm_cfg = dict(type='BN', requires_grad=True) custom_imports = dict(imports='mmcls.models', allow_failed_imports=False) checkpoint_file = 'https://download.openmmlab.com/mmclassification/v0/convnext/downstream/convnext-xlarge_3rdparty_in21k_20220301-08aa5ddc.pth' model = dict( type='EncoderDecoder', pretrained...
36.488987
143
0.548835
norm_cfg = dict(type='BN', requires_grad=True) custom_imports = dict(imports='mmcls.models', allow_failed_imports=False) checkpoint_file = 'https://download.openmmlab.com/mmclassification/v0/convnext/downstream/convnext-xlarge_3rdparty_in21k_20220301-08aa5ddc.pth' model = dict( type='EncoderDecoder', pretrained...
true
true
f7561951403deb5f5fa4d71b9e84b6b7a1761eb6
4,577
py
Python
recipes/squirrel/all/conanfile.py
AntonHorbach/conan-center-index
5791577e80fa4724abc8deb04fa0cb4376d02ba9
[ "MIT" ]
1
2021-11-11T03:07:13.000Z
2021-11-11T03:07:13.000Z
recipes/squirrel/all/conanfile.py
AntonHorbach/conan-center-index
5791577e80fa4724abc8deb04fa0cb4376d02ba9
[ "MIT" ]
null
null
null
recipes/squirrel/all/conanfile.py
AntonHorbach/conan-center-index
5791577e80fa4724abc8deb04fa0cb4376d02ba9
[ "MIT" ]
null
null
null
from conans import ConanFile, tools, CMake from conans.errors import ConanInvalidConfiguration import functools import os required_conan_version = ">=1.43.0" class SquirrelConan(ConanFile): name = "squirrel" description = "Squirrel is a high level imperative, object-oriented programming " \ ...
41.609091
125
0.646056
from conans import ConanFile, tools, CMake from conans.errors import ConanInvalidConfiguration import functools import os required_conan_version = ">=1.43.0" class SquirrelConan(ConanFile): name = "squirrel" description = "Squirrel is a high level imperative, object-oriented programming " \ ...
true
true
f75619962cb4f24a048b39dce88c913d51e38943
2,422
py
Python
tests/test_format/test_fasta.py
GavinHuttley/c3test
c5bf7f8252b4f7b75a851e28275536a8c378897a
[ "BSD-3-Clause" ]
null
null
null
tests/test_format/test_fasta.py
GavinHuttley/c3test
c5bf7f8252b4f7b75a851e28275536a8c378897a
[ "BSD-3-Clause" ]
null
null
null
tests/test_format/test_fasta.py
GavinHuttley/c3test
c5bf7f8252b4f7b75a851e28275536a8c378897a
[ "BSD-3-Clause" ]
1
2020-05-04T02:44:00.000Z
2020-05-04T02:44:00.000Z
#!/usr/bin/env python """Tests for FASTA sequence format writer. """ from unittest import TestCase, main from cogent3.core.alignment import Alignment from cogent3.core.info import Info from cogent3.core.sequence import Sequence from cogent3.format.fasta import alignment_to_fasta __author__ = "Jeremy Widmann" __copyr...
35.101449
88
0.630471
from unittest import TestCase, main from cogent3.core.alignment import Alignment from cogent3.core.info import Info from cogent3.core.sequence import Sequence from cogent3.format.fasta import alignment_to_fasta __author__ = "Jeremy Widmann" __copyright__ = "Copyright 2007-2020, The Cogent Project" __credits__ = ["J...
true
true
f7561a19e81f6a1b27caa4944bc2244ecb37703b
8,866
py
Python
sdk/network/azure-mgmt-network/azure/mgmt/network/v2017_06_01/aio/operations/_default_security_rules_operations.py
rsdoherty/azure-sdk-for-python
6bba5326677468e6660845a703686327178bb7b1
[ "MIT" ]
3
2020-06-23T02:25:27.000Z
2021-09-07T18:48:11.000Z
sdk/network/azure-mgmt-network/azure/mgmt/network/v2017_06_01/aio/operations/_default_security_rules_operations.py
rsdoherty/azure-sdk-for-python
6bba5326677468e6660845a703686327178bb7b1
[ "MIT" ]
510
2019-07-17T16:11:19.000Z
2021-08-02T08:38:32.000Z
sdk/network/azure-mgmt-network/azure/mgmt/network/v2017_06_01/aio/operations/_default_security_rules_operations.py
rsdoherty/azure-sdk-for-python
6bba5326677468e6660845a703686327178bb7b1
[ "MIT" ]
5
2019-09-04T12:51:37.000Z
2020-09-16T07:28:40.000Z
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may ...
49.530726
236
0.677871
from typing import Any, AsyncIterable, Callable, Dict, Generic, Optional, TypeVar import warnings from azure.core.async_paging import AsyncItemPaged, AsyncList from azure.core.exceptions import ClientAuthenticationError, HttpResponseError, ResourceExistsError, ResourceNotFoundError, map_error from azure.core.pi...
true
true
f7561a6f079ebbbd7b8730d19724ec63b6ffceb5
984
py
Python
authentication/models/users.py
jrbenriquez/user-authentication-jr
3ea86724ff9f3a792161fc885b132474af5e1ffc
[ "MIT" ]
1
2020-12-28T08:19:17.000Z
2020-12-28T08:19:17.000Z
authentication/models/users.py
jrbenriquez/user-authentication-jr
3ea86724ff9f3a792161fc885b132474af5e1ffc
[ "MIT" ]
null
null
null
authentication/models/users.py
jrbenriquez/user-authentication-jr
3ea86724ff9f3a792161fc885b132474af5e1ffc
[ "MIT" ]
null
null
null
from django.db import models # Create your models here. from django.db import models from django.contrib.auth.models import AbstractUser, AbstractBaseUser from django.utils.translation import ugettext_lazy as _ from django.contrib.auth.models import PermissionsMixin from .managers import CustomUserManager class Use...
30.75
71
0.76626
from django.db import models from django.db import models from django.contrib.auth.models import AbstractUser, AbstractBaseUser from django.utils.translation import ugettext_lazy as _ from django.contrib.auth.models import PermissionsMixin from .managers import CustomUserManager class User(AbstractBaseUser, Permis...
true
true
f7561c0b9ccb79c129b8ae75efc011a25257b252
26,890
py
Python
tests/bugs/core_6086_test.py
reevespaul/firebird-qa
98f16f425aa9ab8ee63b86172f959d63a2d76f21
[ "MIT" ]
null
null
null
tests/bugs/core_6086_test.py
reevespaul/firebird-qa
98f16f425aa9ab8ee63b86172f959d63a2d76f21
[ "MIT" ]
null
null
null
tests/bugs/core_6086_test.py
reevespaul/firebird-qa
98f16f425aa9ab8ee63b86172f959d63a2d76f21
[ "MIT" ]
null
null
null
#coding:utf-8 # # id: bugs.core_6086 # title: Creating of the large procedure crashes the server. # decription: # Confirmed bug on: WI-T4.0.0.1534, WI-V3.0.5.33141 # Checked on: # 4.0.0.1535: OK, 2.051s. # 3.0.5.33142: ...
30.315671
216
0.630346
import pytest from firebird.qa import db_factory, isql_act, Action substitutions_1 = [] init_script_1 = """""" db_1 = db_factory(charset='WIN1251', sql_dialect=3, init=init_script_1) test_script_1 = """ set bail on; CREATE GLOBAL TEMPORARY TABLE SESSION_EDIT ( ID INTEGER NOT NULL, ...
true
true
f7561cce9c685852e7f193a2c479a6e25bfd738c
848
py
Python
sdcflows/workflows/fit/tests/test_fit.py
oesteban/sdcflows
17feeb3056448067ff7a1f80a7717f7a5b1194a0
[ "Apache-2.0" ]
null
null
null
sdcflows/workflows/fit/tests/test_fit.py
oesteban/sdcflows
17feeb3056448067ff7a1f80a7717f7a5b1194a0
[ "Apache-2.0" ]
null
null
null
sdcflows/workflows/fit/tests/test_fit.py
oesteban/sdcflows
17feeb3056448067ff7a1f80a7717f7a5b1194a0
[ "Apache-2.0" ]
null
null
null
"""Test that workflows build.""" import pytest import sys from .. import fieldmap # noqa from .. import pepolar # noqa from .. import syn # noqa @pytest.mark.parametrize( "workflow,kwargs", ( ("sdcflows.workflows.fit.fieldmap.init_fmap_wf", {"mode": "mapped"}), ("sdcflows.workflows.fit.fie...
32.615385
80
0.642689
import pytest import sys from .. import fieldmap from .. import pepolar from .. import syn @pytest.mark.parametrize( "workflow,kwargs", ( ("sdcflows.workflows.fit.fieldmap.init_fmap_wf", {"mode": "mapped"}), ("sdcflows.workflows.fit.fieldmap.init_fmap_wf", {}), ("sdcflows.workfl...
true
true
f7561d8ce4b6d80daef66e31d59b05a94b5f1d3c
1,892
py
Python
patrickstar/utils/__init__.py
zhuzilin/PatrickStar
72daf8dbded07e03d911db6369b075c9bfcd5245
[ "BSD-3-Clause" ]
null
null
null
patrickstar/utils/__init__.py
zhuzilin/PatrickStar
72daf8dbded07e03d911db6369b075c9bfcd5245
[ "BSD-3-Clause" ]
2
2022-03-15T06:57:11.000Z
2022-03-15T07:55:31.000Z
patrickstar/utils/__init__.py
zhuzilin/PatrickStar
72daf8dbded07e03d911db6369b075c9bfcd5245
[ "BSD-3-Clause" ]
null
null
null
# BSD 3-Clause License # # Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved. # # Redistribution and use in source and binary forms, with or without modification, # are permitted provided that the following conditions are met: # # * Redistributions of source code must retain the above copyrig...
48.512821
82
0.786469
from .distributed import get_world_size, get_rank from .helper import getsizeof, get_space_of from .logging import log_dist, logger, print_rank from .memory import get_memory_info from .memory_monitor import ( see_memory_usage, get_sys_memory_used, ) from .singleton_meta import Sing...
true
true
f7561e3a1f48ccf014477e076e725cf675811390
11,175
py
Python
packages/python/plotly/plotly/graph_objs/ohlc/hoverlabel/_font.py
labaran1/plotly.py
7ec751e8fed4a570c11ea4bea2231806389d62eb
[ "MIT" ]
null
null
null
packages/python/plotly/plotly/graph_objs/ohlc/hoverlabel/_font.py
labaran1/plotly.py
7ec751e8fed4a570c11ea4bea2231806389d62eb
[ "MIT" ]
null
null
null
packages/python/plotly/plotly/graph_objs/ohlc/hoverlabel/_font.py
labaran1/plotly.py
7ec751e8fed4a570c11ea4bea2231806389d62eb
[ "MIT" ]
null
null
null
from plotly.basedatatypes import BaseTraceHierarchyType as _BaseTraceHierarchyType import copy as _copy class Font(_BaseTraceHierarchyType): # class properties # -------------------- _parent_path_str = "ohlc.hoverlabel" _path_str = "ohlc.hoverlabel.font" _valid_props = {"color", "colorsrc", "fami...
33.761329
82
0.55821
from plotly.basedatatypes import BaseTraceHierarchyType as _BaseTraceHierarchyType import copy as _copy class Font(_BaseTraceHierarchyType): _parent_path_str = "ohlc.hoverlabel" _path_str = "ohlc.hoverlabel.font" _valid_props = {"color", "colorsrc", "family", "familysrc", "size", "sizesrc"} ...
true
true
f7561e3f9cf9c27ed3aa0c23b55497645f229851
2,754
py
Python
tests/sensor/test_PixelMask.py
LukasK13/ESBO-ETC
d1db999f1670f2777c5227d79629d421f03e5393
[ "Apache-2.0" ]
null
null
null
tests/sensor/test_PixelMask.py
LukasK13/ESBO-ETC
d1db999f1670f2777c5227d79629d421f03e5393
[ "Apache-2.0" ]
null
null
null
tests/sensor/test_PixelMask.py
LukasK13/ESBO-ETC
d1db999f1670f2777c5227d79629d421f03e5393
[ "Apache-2.0" ]
null
null
null
from unittest import TestCase from esbo_etc.classes.sensor.PixelMask import PixelMask import numpy as np import astropy.units as u class TestPixelMask(TestCase): def setUp(self): self.mask = PixelMask(np.array([10, 8]) << u.pix, 6.5 * u.um, center_offset=np.array([0.2, 0.5]) << u.pix) def test___new_...
51
114
0.368918
from unittest import TestCase from esbo_etc.classes.sensor.PixelMask import PixelMask import numpy as np import astropy.units as u class TestPixelMask(TestCase): def setUp(self): self.mask = PixelMask(np.array([10, 8]) << u.pix, 6.5 * u.um, center_offset=np.array([0.2, 0.5]) << u.pix) def test___new_...
true
true
f7561f9681311341f0ccad12751602e3d85da0ee
4,575
py
Python
src/model.py
lori94/DSCI_522_Group_404
e8177bd7fa388dcada94bcb9c2f6e69dc0227591
[ "MIT" ]
null
null
null
src/model.py
lori94/DSCI_522_Group_404
e8177bd7fa388dcada94bcb9c2f6e69dc0227591
[ "MIT" ]
22
2020-01-17T21:36:34.000Z
2020-02-09T01:15:50.000Z
src/model.py
lori94/DSCI_522_Group_404
e8177bd7fa388dcada94bcb9c2f6e69dc0227591
[ "MIT" ]
3
2020-01-17T23:19:09.000Z
2020-01-19T13:39:30.000Z
#!/usr/bin/env python # coding: utf-8 '''This script finds the best parameters for SVC and LGR models and fits the data to these two models and outputs the classification images and the classification reports as the csv documents. Usage: src/model.py --data_input=<data_input> --result_output=<result_output> Argument...
47.164948
223
0.72918
import numpy as np import pandas as pd from docopt import docopt from sklearn.model_selection import RandomizedSearchCV from sklearn.linear_model import LogisticRegression from sklearn.svm import SVC import matplotlib.pyplot as plt from sklearn.metrics import classification_report import lightgbm as lgb opt = doco...
true
true
f75620801c5aa4e7be767496ee1ec9518526a876
2,052
py
Python
py/torch_tensorrt/fx/test/converters/acc_op/test_embedding.py
NVIDIA/Torch-TensorRT
1a22204fecec690bc3c2a318dab4f57b98c57f05
[ "BSD-3-Clause" ]
430
2021-11-09T08:08:01.000Z
2022-03-31T10:13:45.000Z
py/torch_tensorrt/fx/test/converters/acc_op/test_embedding.py
NVIDIA/Torch-TensorRT
1a22204fecec690bc3c2a318dab4f57b98c57f05
[ "BSD-3-Clause" ]
257
2021-11-09T07:17:03.000Z
2022-03-31T20:29:31.000Z
py/torch_tensorrt/fx/test/converters/acc_op/test_embedding.py
NVIDIA/Torch-TensorRT
1a22204fecec690bc3c2a318dab4f57b98c57f05
[ "BSD-3-Clause" ]
68
2021-11-10T05:03:22.000Z
2022-03-22T17:07:32.000Z
import unittest import torch import torch_tensorrt.fx.tracer.acc_tracer.acc_ops as acc_ops from parameterized import param, parameterized from torch.testing._internal.common_utils import run_tests from torch_tensorrt.fx.tools.common_fx2trt import AccTestCase @unittest.skip( "Current implementation is limited. A...
30.176471
88
0.554581
import unittest import torch import torch_tensorrt.fx.tracer.acc_tracer.acc_ops as acc_ops from parameterized import param, parameterized from torch.testing._internal.common_utils import run_tests from torch_tensorrt.fx.tools.common_fx2trt import AccTestCase @unittest.skip( "Current implementation is limited. A...
true
true
f75620dcd71ddaff853bd8bb0ba8fc7acd6cf3da
2,452
py
Python
app/main/forms.py
nacei/h3blog-master
e433c93f56be63883538b4e03198e6e4e056ecb6
[ "MulanPSL-1.0" ]
null
null
null
app/main/forms.py
nacei/h3blog-master
e433c93f56be63883538b4e03198e6e4e056ecb6
[ "MulanPSL-1.0" ]
null
null
null
app/main/forms.py
nacei/h3blog-master
e433c93f56be63883538b4e03198e6e4e056ecb6
[ "MulanPSL-1.0" ]
null
null
null
# -*- coding:utf-8 -*- __author__ = '何三' from flask_wtf import FlaskForm from flask_login import current_user from wtforms import StringField,PasswordField, BooleanField, SubmitField, IntegerField from wtforms.validators import DataRequired, Length, Email, EqualTo, ValidationError from app.models import User, Invitati...
40.866667
104
0.707178
__author__ = '何三' from flask_wtf import FlaskForm from flask_login import current_user from wtforms import StringField,PasswordField, BooleanField, SubmitField, IntegerField from wtforms.validators import DataRequired, Length, Email, EqualTo, ValidationError from app.models import User, InvitationCode class LoginFor...
true
true
f756213157144c3a723641dfc1ff55c9db4af36f
5,965
py
Python
settings.py
caizixian/plotty
114dbe9e2566fffa3427e815cdc8b3ae76866f2b
[ "MIT" ]
7
2015-02-19T14:38:51.000Z
2019-06-16T17:47:59.000Z
settings.py
caizixian/plotty
114dbe9e2566fffa3427e815cdc8b3ae76866f2b
[ "MIT" ]
2
2015-01-04T19:59:02.000Z
2015-02-16T04:13:08.000Z
settings.py
caizixian/plotty
114dbe9e2566fffa3427e815cdc8b3ae76866f2b
[ "MIT" ]
2
2015-01-04T12:45:40.000Z
2021-09-09T09:44:50.000Z
# Django settings for django_site project. import sys, os # Files created by plotty are globally read/write os.umask(0) DEBUG = not False TEMPLATE_DEBUG = DEBUG # Two-tailed confidence level (i.e. this value will be halved for calls to # the inverse t function) CONFIDENCE_LEVEL = 0.95 if 'PLOTTY_ROOT' in os.environ:...
32.243243
119
0.732942
import sys, os os.umask(0) DEBUG = not False TEMPLATE_DEBUG = DEBUG CONFIDENCE_LEVEL = 0.95 if 'PLOTTY_ROOT' in os.environ: ROOT_DIR = os.environ['PLOTTY_ROOT'] IS_SQUIRREL = True else: ROOT_DIR = os.path.dirname(__file__) IS_SQUIRREL = False APP_ROOT = os.path.dirname(__file__) BM_LOG_DIR = os...
true
true
f7562209d2b95909a797498d52cacee3d7ef223c
465
py
Python
setup.py
jefersonjlima/wbident
e3e108f3cb4752a7dc9e51a27aff78330e5ab3d9
[ "MIT" ]
null
null
null
setup.py
jefersonjlima/wbident
e3e108f3cb4752a7dc9e51a27aff78330e5ab3d9
[ "MIT" ]
null
null
null
setup.py
jefersonjlima/wbident
e3e108f3cb4752a7dc9e51a27aff78330e5ab3d9
[ "MIT" ]
null
null
null
from setuptools import setup with open('requirements.txt', 'rt') as f: requirements_list = [req[:-1] for req in f.readlines()] setup( name='wbident', version='0.0.1', packages=['wbident', 'wbident.core'], url='https://gitlab.com/limajj_articles/core/wbident', license='', author='Jeferson ...
27.352941
59
0.68172
from setuptools import setup with open('requirements.txt', 'rt') as f: requirements_list = [req[:-1] for req in f.readlines()] setup( name='wbident', version='0.0.1', packages=['wbident', 'wbident.core'], url='https://gitlab.com/limajj_articles/core/wbident', license='', author='Jeferson ...
true
true
f7562255dff65d18aecd17dc3f33b108335cb404
3,248
py
Python
djangox/lib/python3.8/site-packages/oauthlib/oauth2/rfc6749/endpoints/resource.py
DemarcusL/django_wiki_lab
3b7cf18af7e0f89c94d10eb953ca018a150a2f55
[ "MIT" ]
954
2018-01-27T11:00:51.000Z
2022-03-31T16:04:42.000Z
djangox/lib/python3.8/site-packages/oauthlib/oauth2/rfc6749/endpoints/resource.py
DemarcusL/django_wiki_lab
3b7cf18af7e0f89c94d10eb953ca018a150a2f55
[ "MIT" ]
274
2018-01-27T08:36:01.000Z
2022-03-22T04:40:40.000Z
djangox/lib/python3.8/site-packages/oauthlib/oauth2/rfc6749/endpoints/resource.py
DemarcusL/django_wiki_lab
3b7cf18af7e0f89c94d10eb953ca018a150a2f55
[ "MIT" ]
191
2018-02-15T12:12:45.000Z
2022-03-31T22:38:13.000Z
""" oauthlib.oauth2.rfc6749 ~~~~~~~~~~~~~~~~~~~~~~~ This module is an implementation of various logic needed for consuming and providing OAuth 2.0 RFC6749. """ import logging from oauthlib.common import Request from .base import BaseEndpoint, catch_errors_and_unavailability log = logging.getLogger(__name__) class...
38.211765
77
0.695813
import logging from oauthlib.common import Request from .base import BaseEndpoint, catch_errors_and_unavailability log = logging.getLogger(__name__) class ResourceEndpoint(BaseEndpoint): def __init__(self, default_token, token_types): BaseEndpoint.__init__(self) self._tokens = token_types ...
true
true
f75622d2bdc034b43a8f7e965fa324c38b2de9a5
442
py
Python
tests/test_dist.py
Angeluz-07/python-semantic-release
39ff283312a0c686bfc5be71e1da9b6456652d95
[ "MIT" ]
null
null
null
tests/test_dist.py
Angeluz-07/python-semantic-release
39ff283312a0c686bfc5be71e1da9b6456652d95
[ "MIT" ]
null
null
null
tests/test_dist.py
Angeluz-07/python-semantic-release
39ff283312a0c686bfc5be71e1da9b6456652d95
[ "MIT" ]
null
null
null
from semantic_release.dist import build_dists from . import pytest @pytest.mark.parametrize('commands', [ 'sdist bdist_wheel', 'sdist', 'bdist_wheel', 'sdist bdist_wheel custom_cmd' ]) def test_build_command(mocker, commands): mocker.patch('semantic_release.dist.config.get', lambda *a: commands) ...
26
73
0.737557
from semantic_release.dist import build_dists from . import pytest @pytest.mark.parametrize('commands', [ 'sdist bdist_wheel', 'sdist', 'bdist_wheel', 'sdist bdist_wheel custom_cmd' ]) def test_build_command(mocker, commands): mocker.patch('semantic_release.dist.config.get', lambda *a: commands) ...
true
true
f75622e1cb03405a13903b24bc75e8cdcd191d6a
3,690
py
Python
audacity.py
naegawa/Aup2wav_dataset
bc22ce50704497f2d496da13b00cebae0083bbef
[ "MIT" ]
null
null
null
audacity.py
naegawa/Aup2wav_dataset
bc22ce50704497f2d496da13b00cebae0083bbef
[ "MIT" ]
null
null
null
audacity.py
naegawa/Aup2wav_dataset
bc22ce50704497f2d496da13b00cebae0083bbef
[ "MIT" ]
null
null
null
#!/usr/bin/env python # 2017 kojima changed https://github.com/davidavdav/audacity.py (c) 2016 David A. van Leeuwen # # # import xml.etree.ElementTree as ET import wave, os, numpy, struct class Aup: def __init__(self, aupfile): fqpath = os.path.join(os.path.curdir, aupfile) dir = os.path.dirname(fqpath) xml =...
30
101
0.647425
import xml.etree.ElementTree as ET import wave, os, numpy, struct class Aup: def __init__(self, aupfile): fqpath = os.path.join(os.path.curdir, aupfile) dir = os.path.dirname(fqpath) xml = open(aupfile) self.tree = ET.parse(xml) self.root = self.tree.getroot() self.rate = float(self.root.attrib["rate...
true
true
f75623096f26c5c1cd0d1f4f86a90c4d295eb299
10,421
py
Python
src/Python/sirf/contrib/kcl/user_dePierroMap_real_data.py
ClaireDelplancke/SIRF-Contribs
29ab88bb5a0032daa464c2617a49ba6881813902
[ "Apache-2.0" ]
1
2019-04-18T08:54:12.000Z
2019-04-18T08:54:12.000Z
src/Python/sirf/contrib/kcl/user_dePierroMap_real_data.py
ClaireDelplancke/SIRF-Contribs
29ab88bb5a0032daa464c2617a49ba6881813902
[ "Apache-2.0" ]
5
2018-12-18T10:13:02.000Z
2018-12-19T16:49:07.000Z
src/Python/sirf/contrib/kcl/user_dePierroMap_real_data.py
SyneRBI/SIRF-Contribs
130223d9bc11991eadcd11f9b715aea34c4842fd
[ "Apache-2.0" ]
1
2019-09-26T11:48:39.000Z
2019-09-26T11:48:39.000Z
'''User implemented De Pierro MAPEM reconstruction Real data implementation of De Pierro MAPEM, using a Bowsher weighted quadratic penalty. The guidance image (here a T1-weighted MR image) must be pre-aligned to the PET image and sampled on the same image grid. Implemented by Sam Ellis (13th Feb 2019) Usage: dePier...
32.77044
98
0.695998
ahv') imageReg_array = dePierroReg(current_image.as_array(),weights) OSEM_reconstructor.update(current_image) imageEM_array = current_image.as_array() imageUpdated_array = dePierroUpdate \ (imageEM_array, imageReg_array, ...
true
true
f756234d8734f7c4eadcbf966415c8e84ac0e207
732
py
Python
math/p100.py
sajjadt/competitive-programming
fb0844afba95383441f0c4c0c3b1a38078d24ec9
[ "MIT" ]
10
2019-03-29T08:37:10.000Z
2021-12-29T14:06:57.000Z
math/p100.py
sajjadt/competitive-programming
fb0844afba95383441f0c4c0c3b1a38078d24ec9
[ "MIT" ]
1
2020-07-03T08:25:38.000Z
2020-07-03T08:25:38.000Z
math/p100.py
sajjadt/competitive-programming
fb0844afba95383441f0c4c0c3b1a38078d24ec9
[ "MIT" ]
4
2019-05-30T16:04:48.000Z
2020-10-22T21:42:25.000Z
#!/usr/bin/python3 # UVA 100: 3n+1 problem LIMIT = 1000001 solutions = {} solutions[0] = 0 solutions[1] = 1 def calc_and_get(index): global solutions if index <= 0: return if index in solutions: return solutions[index] else: if index % 2 == 0: val = calc_and_get(index / 2) + 1 else: ...
17.428571
53
0.577869
LIMIT = 1000001 solutions = {} solutions[0] = 0 solutions[1] = 1 def calc_and_get(index): global solutions if index <= 0: return if index in solutions: return solutions[index] else: if index % 2 == 0: val = calc_and_get(index / 2) + 1 else: val = calc_and_get(3 * index + 1) +...
true
true
f756237eb648bd55d783f6127c4d2191d51e5e50
10,195
py
Python
lecture/1. policy-iteration/environment.py
hojeong3709/RL
a1c6eab8c3e7f2487e527fe68658d13eea5334af
[ "MIT" ]
null
null
null
lecture/1. policy-iteration/environment.py
hojeong3709/RL
a1c6eab8c3e7f2487e527fe68658d13eea5334af
[ "MIT" ]
null
null
null
lecture/1. policy-iteration/environment.py
hojeong3709/RL
a1c6eab8c3e7f2487e527fe68658d13eea5334af
[ "MIT" ]
null
null
null
import tkinter as tk from tkinter import Button import time import numpy as np from PIL import ImageTk, Image PhotoImage = ImageTk.PhotoImage UNIT = 100 # 픽셀 수 HEIGHT = 5 # 그리드월드 세로 WIDTH = 5 # 그리드월드 가로 TRANSITION_PROB = 1 #상태 변환 확률 값 POSSIBLE_ACTIONS = [0, 1, 2, 3] # 상, 하, 좌, 우 ACTIONS = [(-1, 0), (1, 0), (0, -1)...
41.108871
90
0.552133
import tkinter as tk from tkinter import Button import time import numpy as np from PIL import ImageTk, Image PhotoImage = ImageTk.PhotoImage UNIT = 100 HEIGHT = 5 WIDTH = 5 TRANSITION_PROB = 1 POSSIBLE_ACTIONS = [0, 1, 2, 3] ACTIONS = [(-1, 0), (1, 0), (0, -1), (0, 1)] REWARDS = [] class GraphicDisplay(t...
true
true
f75624d803ad381cbfbbfe67e691603f6f57449a
2,864
py
Python
limb_manipulation/src/camera_info_messages.py
TimAdamson21/access_teleop
4ca4cc3ebc29cb4942cec5c8e3e60b897b80590c
[ "MIT" ]
null
null
null
limb_manipulation/src/camera_info_messages.py
TimAdamson21/access_teleop
4ca4cc3ebc29cb4942cec5c8e3e60b897b80590c
[ "MIT" ]
null
null
null
limb_manipulation/src/camera_info_messages.py
TimAdamson21/access_teleop
4ca4cc3ebc29cb4942cec5c8e3e60b897b80590c
[ "MIT" ]
null
null
null
from sensor_msgs.msg import CameraInfo import rospy camera1 = CameraInfo() camera2 = CameraInfo() camera3 = CameraInfo() # Created by Tim """ camera1 = {header: {seq: 0, stamp: {secs: 0, nsecs: 0}, frame_id: 'camera1'}, height: 342, width: 342, distortion_model: 'plumb_bob', D: [0], K: [500.0, 0.0, ...
32.91954
83
0.623254
from sensor_msgs.msg import CameraInfo import rospy camera1 = CameraInfo() camera2 = CameraInfo() camera3 = CameraInfo() camera1.header.seq = 0 camera1.header.stamp.secs = 0 camera1.header.stamp.nsecs = 0 camera1.header.frame_id = 'camera1' camera1.height = 480 camera1.width = 640 camera1.distortion_model = 'plumb_b...
true
true
f756266a329e6f238a736fab80bc10f2e122f73e
5,845
py
Python
plotly/tests/test_plot_ly/test_grid/test_grid.py
gnestor/plotly.py
a8ae062795ddbf9867b8578fe6d9e244948c15ff
[ "MIT" ]
2
2020-03-24T11:41:14.000Z
2021-01-14T07:59:43.000Z
plotly/tests/test_plot_ly/test_grid/test_grid.py
gnestor/plotly.py
a8ae062795ddbf9867b8578fe6d9e244948c15ff
[ "MIT" ]
27
2020-04-28T21:23:12.000Z
2021-06-25T15:36:38.000Z
plotly/tests/test_plot_ly/test_grid/test_grid.py
gnestor/plotly.py
a8ae062795ddbf9867b8578fe6d9e244948c15ff
[ "MIT" ]
4
2019-06-03T14:49:12.000Z
2022-01-06T01:05:12.000Z
""" test_grid: ========== A module intended for use with Nose. """ from __future__ import absolute_import import random import string from unittest import skip from nose.plugins.attrib import attr import plotly.plotly as py from plotly.exceptions import InputError, PlotlyRequestError, PlotlyError from plotly.graph...
31.766304
73
0.607357
from __future__ import absolute_import import random import string from unittest import skip from nose.plugins.attrib import attr import plotly.plotly as py from plotly.exceptions import InputError, PlotlyRequestError, PlotlyError from plotly.graph_objs import Scatter from plotly.grid_objs import Column, Grid from p...
true
true
f75626d8a00e4dc5cf4400c5bb6f101e1edde9ad
3,744
py
Python
smoke/layers/utils.py
ZhuokunYao/smoke
d524fbe43b1aba6078c25d9aca7924b71a635e1d
[ "MIT" ]
null
null
null
smoke/layers/utils.py
ZhuokunYao/smoke
d524fbe43b1aba6078c25d9aca7924b71a635e1d
[ "MIT" ]
null
null
null
smoke/layers/utils.py
ZhuokunYao/smoke
d524fbe43b1aba6078c25d9aca7924b71a635e1d
[ "MIT" ]
null
null
null
import torch from torch.nn import functional as F def sigmoid_hm(hm_features, training=False): x = hm_features.sigmoid_() if training: x = x.clamp(min=1e-4, max=1 - 1e-4) return x def nms_hm(heat_map, kernel=3): pad = (kernel - 1) // 2 hmax = F.max_pool2d(heat_map, ...
30.942149
107
0.612447
import torch from torch.nn import functional as F def sigmoid_hm(hm_features, training=False): x = hm_features.sigmoid_() if training: x = x.clamp(min=1e-4, max=1 - 1e-4) return x def nms_hm(heat_map, kernel=3): pad = (kernel - 1) // 2 hmax = F.max_pool2d(heat_map, ...
true
true
f75627208774fb440cdef21b3d09d833aa26beb5
785
py
Python
plugins/mxtoolbox_dns/komand_mxtoolbox_dns/actions/dns/action.py
lukaszlaszuk/insightconnect-plugins
8c6ce323bfbb12c55f8b5a9c08975d25eb9f8892
[ "MIT" ]
46
2019-06-05T20:47:58.000Z
2022-03-29T10:18:01.000Z
plugins/mxtoolbox_dns/komand_mxtoolbox_dns/actions/dns/action.py
lukaszlaszuk/insightconnect-plugins
8c6ce323bfbb12c55f8b5a9c08975d25eb9f8892
[ "MIT" ]
386
2019-06-07T20:20:39.000Z
2022-03-30T17:35:01.000Z
plugins/mxtoolbox_dns/komand_mxtoolbox_dns/actions/dns/action.py
lukaszlaszuk/insightconnect-plugins
8c6ce323bfbb12c55f8b5a9c08975d25eb9f8892
[ "MIT" ]
43
2019-07-09T14:13:58.000Z
2022-03-28T12:04:46.000Z
import komand from .schema import DnsInput, DnsOutput # Custom imports below from komand_mxtoolbox_dns.util import utils class Dns(komand.Action): def __init__(self): super(self.__class__, self).__init__( name="dns", description="Run a DNS query", input=DnsInput(), output=DnsOutput() ...
30.192308
91
0.659873
import komand from .schema import DnsInput, DnsOutput from komand_mxtoolbox_dns.util import utils class Dns(komand.Action): def __init__(self): super(self.__class__, self).__init__( name="dns", description="Run a DNS query", input=DnsInput(), output=DnsOutput() ) def run(self, p...
true
true
f756275786ceeff5ebdc8cd30d844db12c6788be
254
py
Python
projectecho/projectecho/users/apps.py
ngonimombeshora/projectecho
839423738cb63da2e90f7e1d561da5413aca2357
[ "MIT" ]
null
null
null
projectecho/projectecho/users/apps.py
ngonimombeshora/projectecho
839423738cb63da2e90f7e1d561da5413aca2357
[ "MIT" ]
null
null
null
projectecho/projectecho/users/apps.py
ngonimombeshora/projectecho
839423738cb63da2e90f7e1d561da5413aca2357
[ "MIT" ]
null
null
null
from django.apps import AppConfig class UsersAppConfig(AppConfig): name = "projectecho.users" verbose_name = "Users" def ready(self): try: import users.signals # noqa F401 except ImportError: pass
18.142857
45
0.614173
from django.apps import AppConfig class UsersAppConfig(AppConfig): name = "projectecho.users" verbose_name = "Users" def ready(self): try: import users.signals except ImportError: pass
true
true
f7562aa3b825bf532ab3aa6c7e2447772a5d0bea
9,165
py
Python
codes/lib/position.py
aviolinist/EEE
032e2029815229875048cc92dd7da24ff3f71e93
[ "MIT" ]
6
2019-09-27T15:38:37.000Z
2021-02-03T13:58:01.000Z
codes/lib/position.py
aviolinist/EEE
032e2029815229875048cc92dd7da24ff3f71e93
[ "MIT" ]
null
null
null
codes/lib/position.py
aviolinist/EEE
032e2029815229875048cc92dd7da24ff3f71e93
[ "MIT" ]
5
2019-09-27T15:38:52.000Z
2022-03-22T17:24:37.000Z
#!/usr/bin/env python from __future__ import division, absolute_import, print_function import numpy as np __all__ = ['position'] def position(row=1, col=1, num=1, left=0.125, right=0.9, bottom=0.1, top=0.9, hspace=0.1, vspace=None, wspace=None, width=None, height=None, ...
40.733333
116
0.560611
from __future__ import division, absolute_import, print_function import numpy as np __all__ = ['position'] def position(row=1, col=1, num=1, left=0.125, right=0.9, bottom=0.1, top=0.9, hspace=0.1, vspace=None, wspace=None, width=None, height=None, sortcol=False, go...
true
true
f7562b12d44cd534b340dbf8b45926054f8962ff
5,008
py
Python
gluon/_compat.py
dhildebr/portfolio-website
f9d8aceb3a78c19f2b351277d1f1df2c0a55f5fd
[ "BSD-3-Clause" ]
21
2018-02-16T17:43:59.000Z
2021-12-29T12:08:28.000Z
gluon/_compat.py
dhildebr/portfolio-website
f9d8aceb3a78c19f2b351277d1f1df2c0a55f5fd
[ "BSD-3-Clause" ]
12
2017-11-01T14:54:29.000Z
2018-02-01T22:02:12.000Z
gluon/_compat.py
dhildebr/portfolio-website
f9d8aceb3a78c19f2b351277d1f1df2c0a55f5fd
[ "BSD-3-Clause" ]
8
2018-10-08T03:48:00.000Z
2022-03-31T12:13:01.000Z
import sys import hashlib import os PY2 = sys.version_info[0] == 2 _identity = lambda x: x if PY2: import cPickle as pickle from cStringIO import StringIO import copy_reg as copyreg from HTMLParser import HTMLParser import urlparse from htmlentitydefs import entitydefs, name2codepoint imp...
30.91358
88
0.679113
import sys import hashlib import os PY2 = sys.version_info[0] == 2 _identity = lambda x: x if PY2: import cPickle as pickle from cStringIO import StringIO import copy_reg as copyreg from HTMLParser import HTMLParser import urlparse from htmlentitydefs import entitydefs, name2codepoint imp...
true
true
f7562b416003b48372a61948cb13d6a8660f32f4
835
py
Python
chapter02/elasticsearch_study.py
thiagola92/learning-databases-with-python
cf23c34d7fd1ecd36dd3e7b30dc5916eb23eaf1e
[ "MIT" ]
null
null
null
chapter02/elasticsearch_study.py
thiagola92/learning-databases-with-python
cf23c34d7fd1ecd36dd3e7b30dc5916eb23eaf1e
[ "MIT" ]
null
null
null
chapter02/elasticsearch_study.py
thiagola92/learning-databases-with-python
cf23c34d7fd1ecd36dd3e7b30dc5916eb23eaf1e
[ "MIT" ]
null
null
null
from elasticsearch import Elasticsearch client = Elasticsearch("http://username:password@127.0.0.1:9200") client.indices.create(index="index_name") client.create( index="index_name", id=1, document={ "sku": 134218478, "name": "Rb-01 - Robô Aspirador De Pó Fast Clean Bivolt - Mondial", ...
27.833333
166
0.681437
from elasticsearch import Elasticsearch client = Elasticsearch("http://username:password@127.0.0.1:9200") client.indices.create(index="index_name") client.create( index="index_name", id=1, document={ "sku": 134218478, "name": "Rb-01 - Robô Aspirador De Pó Fast Clean Bivolt - Mondial", ...
true
true
f7562b536d198e0c54b5920f2bce8f8474f29dd3
12,009
py
Python
python/raydp/spark/torch/dataset.py
ConeyLiu/oap-raydp
3fe728f01dbb6494d94c4abd65bc9aacff771080
[ "Apache-2.0" ]
null
null
null
python/raydp/spark/torch/dataset.py
ConeyLiu/oap-raydp
3fe728f01dbb6494d94c4abd65bc9aacff771080
[ "Apache-2.0" ]
null
null
null
python/raydp/spark/torch/dataset.py
ConeyLiu/oap-raydp
3fe728f01dbb6494d94c4abd65bc9aacff771080
[ "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 file to You under the Apache License, Version 2.0 # (the "License"); you may not us...
40.708475
96
0.626114
from collections.abc import Iterable from typing import Any, List, Optional import numpy as np import pandas import torch from torch.utils.data import Dataset, DistributedSampler from raydp.spark.context import save_to_ray from raydp.spark.resource_manager.exchanger import SharedDataset from raydp.sp...
true
true
f7562bf6ef62c5e01fc2df18fe5dab489ce7385a
1,014
py
Python
iconQt.py
EGobi/icon-corner
bbd9e45742eb5f225b857b6e3bf28f74b79aa9dc
[ "CC0-1.0" ]
null
null
null
iconQt.py
EGobi/icon-corner
bbd9e45742eb5f225b857b6e3bf28f74b79aa9dc
[ "CC0-1.0" ]
null
null
null
iconQt.py
EGobi/icon-corner
bbd9e45742eb5f225b857b6e3bf28f74b79aa9dc
[ "CC0-1.0" ]
null
null
null
import sys, signal from PyQt5.QtWidgets import QApplication, QWidget, QLabel from PyQt5.QtGui import QIcon, QPixmap from PyQt5.QtCore import Qt class Application(QWidget): def __init__(self): super().__init__() self.setWindowFlags(Qt.CustomizeWindowHint | Qt.FramelessWindowHint | Qt.WindowStaysOnTopHint | Qt.Tool...
28.166667
106
0.710059
import sys, signal from PyQt5.QtWidgets import QApplication, QWidget, QLabel from PyQt5.QtGui import QIcon, QPixmap from PyQt5.QtCore import Qt class Application(QWidget): def __init__(self): super().__init__() self.setWindowFlags(Qt.CustomizeWindowHint | Qt.FramelessWindowHint | Qt.WindowStaysOnTopHint | Qt.Tool...
true
true
f7562c4c91991722ca112cb0267d2b90ea50dddc
4,998
py
Python
core/model.py
2anchao/NTS_NET
3b0a58616cb4b44699a11541eac2777556169812
[ "MIT" ]
1
2022-02-25T07:37:24.000Z
2022-02-25T07:37:24.000Z
core/model.py
yirui-fafa/NTS_NET
3b0a58616cb4b44699a11541eac2777556169812
[ "MIT" ]
null
null
null
core/model.py
yirui-fafa/NTS_NET
3b0a58616cb4b44699a11541eac2777556169812
[ "MIT" ]
1
2022-02-25T07:54:56.000Z
2022-02-25T07:54:56.000Z
from torch import nn import torch import torch.nn.functional as F from torch.autograd import Variable from core import resnet import numpy as np from core.anchors import generate_default_anchor_maps, hard_nms from config import Config as cfg class ProposalNet(nn.Module): """ Navigator Network ...
46.71028
121
0.628451
from torch import nn import torch import torch.nn.functional as F from torch.autograd import Variable from core import resnet import numpy as np from core.anchors import generate_default_anchor_maps, hard_nms from config import Config as cfg class ProposalNet(nn.Module): def __init__(self, in_channel=2...
true
true
f7562cc02d0d3371653c49379ac8aefc247ea73b
125,928
py
Python
catboost/python-package/catboost/core.py
ProskuraPD/catboost
d4593d4fbc8b8da66ff2d8b838578eba819d9d0d
[ "Apache-2.0" ]
null
null
null
catboost/python-package/catboost/core.py
ProskuraPD/catboost
d4593d4fbc8b8da66ff2d8b838578eba819d9d0d
[ "Apache-2.0" ]
null
null
null
catboost/python-package/catboost/core.py
ProskuraPD/catboost
d4593d4fbc8b8da66ff2d8b838578eba819d9d0d
[ "Apache-2.0" ]
null
null
null
import sys from copy import deepcopy from six import iteritems, string_types, integer_types import os import imp from collections import Iterable, Sequence, Mapping, MutableMapping import warnings import numpy as np import ctypes import platform import tempfile from enum import Enum from operator import itemgetter if ...
42.4
180
0.647418
import sys from copy import deepcopy from six import iteritems, string_types, integer_types import os import imp from collections import Iterable, Sequence, Mapping, MutableMapping import warnings import numpy as np import ctypes import platform import tempfile from enum import Enum from operator import itemgetter if ...
true
true
f7562e6282d137e43a57b3bb0fd225b46fb12aa0
2,539
py
Python
Code/Data_Collection/APIs/Itjobs_api/itjobs_api.py
gilnribeiro/Work-Project
15ad906ef5e757daed1df9c7547e5703ad496930
[ "MIT" ]
1
2022-01-31T11:31:04.000Z
2022-01-31T11:31:04.000Z
Code/Data_Collection/APIs/Itjobs_api/itjobs_api.py
gilnribeiro/Work-Project
15ad906ef5e757daed1df9c7547e5703ad496930
[ "MIT" ]
null
null
null
Code/Data_Collection/APIs/Itjobs_api/itjobs_api.py
gilnribeiro/Work-Project
15ad906ef5e757daed1df9c7547e5703ad496930
[ "MIT" ]
null
null
null
import json import os from .config import API_KEY import requests from datetime import date from w3lib.html import remove_tags def save_data_to_json(file_name, data): """Save data to a json file creating it if it does not already exist :parameter: file_name -> 'example' do not add the '.json' :parameter:...
30.590361
105
0.570303
import json import os from .config import API_KEY import requests from datetime import date from w3lib.html import remove_tags def save_data_to_json(file_name, data): if os.path.exists(file_name+'.json') == False: with open(file_name+'.json', 'w', encoding='utf-8') as json_file: ...
true
true
f7562f1fcd1e17c71bb61a1ba765f5cffb3a1dbc
37,171
py
Python
plantcv/plantcv/spectral_index/spectral_index.py
ygarrot/plantcv
e934a891e0d1bf8987ca6a9f982a4ac1f420bfe7
[ "MIT" ]
1
2022-03-12T05:46:03.000Z
2022-03-12T05:46:03.000Z
plantcv/plantcv/spectral_index/spectral_index.py
YuanYu-Double/plantcv
0e11c7f63d96a52487e01e3b67744aa8697eedb2
[ "MIT" ]
null
null
null
plantcv/plantcv/spectral_index/spectral_index.py
YuanYu-Double/plantcv
0e11c7f63d96a52487e01e3b67744aa8697eedb2
[ "MIT" ]
null
null
null
# Extract one of the predefined indices from a hyperspectral datacube import os import numpy as np import cv2 from plantcv.plantcv import params from plantcv.plantcv._debug import _debug from plantcv.plantcv import fatal_error from plantcv.plantcv import Spectral_data from plantcv.plantcv.transform import rescale from...
41.812148
115
0.672218
import os import numpy as np import cv2 from plantcv.plantcv import params from plantcv.plantcv._debug import _debug from plantcv.plantcv import fatal_error from plantcv.plantcv import Spectral_data from plantcv.plantcv.transform import rescale from plantcv.plantcv.hyperspectral import _find_closest def ndvi(hsi, d...
true
true
f7562f6dc837f9ba6a3ceb3e7c9c6a62076cf323
1,031
py
Python
Django_learning_2/Django_05_Ajax/Django_05_Ajax/urls.py
hgzerowzh/Django
2be08ad8e44065f3a0a884998d6120a415eddbb3
[ "Apache-2.0" ]
null
null
null
Django_learning_2/Django_05_Ajax/Django_05_Ajax/urls.py
hgzerowzh/Django
2be08ad8e44065f3a0a884998d6120a415eddbb3
[ "Apache-2.0" ]
null
null
null
Django_learning_2/Django_05_Ajax/Django_05_Ajax/urls.py
hgzerowzh/Django
2be08ad8e44065f3a0a884998d6120a415eddbb3
[ "Apache-2.0" ]
null
null
null
"""Django_05_Ajax URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/3.0/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: path('', views.home, name='home') Clas...
27.131579
77
0.690592
from django.contrib import admin from django.urls import path from django.conf.urls import url from app01 import views urlpatterns = [ url(r'^index.html$', views.index), url(r'^ajax1.html$', views.ajax1), url(r'^ajax2.html$', views.ajax2), url(r'^upload.html$', views.upload), url(r'^up...
true
true
f7562fbb0fd40e6f732b13273da04f190ed5f4bf
626
py
Python
bin/dynamodb_to_csv.py
istrategylabs/amweekly
befd03cc4ed9ea0dceb0bf24f339016faf6fb10a
[ "MIT" ]
3
2016-09-29T17:14:51.000Z
2020-05-12T20:38:27.000Z
bin/dynamodb_to_csv.py
istrategylabs/amweekly
befd03cc4ed9ea0dceb0bf24f339016faf6fb10a
[ "MIT" ]
2
2017-08-04T19:53:45.000Z
2018-03-07T14:10:36.000Z
bin/dynamodb_to_csv.py
istrategylabs/amweekly
befd03cc4ed9ea0dceb0bf24f339016faf6fb10a
[ "MIT" ]
1
2019-12-17T16:11:28.000Z
2019-12-17T16:11:28.000Z
import csv import json from datetime import datetime """Useful for converting DynamoDB exports to CSV""" data = [] with open('data') as f: for line in f: data.append(json.loads(line)) with open('data.csv', 'w', encoding='utf8') as csvf: w = csv.writer(csvf, quoting=csv.QUOTE_MINIMAL) w.writerow(...
28.454545
56
0.623003
import csv import json from datetime import datetime data = [] with open('data') as f: for line in f: data.append(json.loads(line)) with open('data.csv', 'w', encoding='utf8') as csvf: w = csv.writer(csvf, quoting=csv.QUOTE_MINIMAL) w.writerow(['id', 'created_at', 'user_name', 'url']) for id...
true
true
f75630cbc7b1eef703d5e902537d65487d1b7612
4,126
py
Python
sim/pid.py
jmagine/rf-selection
ba9dcb5ca550916873ce68baa71da983f2dd4be5
[ "MIT" ]
1
2020-05-06T01:28:06.000Z
2020-05-06T01:28:06.000Z
sim/pid.py
jmagine/multiuav-rf
ba9dcb5ca550916873ce68baa71da983f2dd4be5
[ "MIT" ]
null
null
null
sim/pid.py
jmagine/multiuav-rf
ba9dcb5ca550916873ce68baa71da983f2dd4be5
[ "MIT" ]
null
null
null
'''*-----------------------------------------------------------------------*--- Author: Jason Ma Date : Oct 18 2018 TODO File Name : pid.py Description: TODO ---...
25.469136
127
0.537082
import time import matplotlib.animation as anim import matplotlib.pyplot as plt import threading import math import numpy as np ORIGIN_X = 0.0 ORIGIN_Y = 0.0 C_R = 10 fig = plt.figure() ax = fig.add_subplot(2,1,1) ax2 = fig.add_subplot(2,1,2) scat = ax.scatter([], []) ax.set_xlim([-1 * C_R - 1, C_R + 1]) ax.set_yl...
true
true
f756319f056e211d5b1fbc459b2a23eb1a227f56
6,493
py
Python
stog/modules/initializers.py
sfillwo/stog
b02e2dbe8989078ccdc3df611d8b08b63d28fcae
[ "MIT" ]
172
2019-11-19T05:52:36.000Z
2022-03-26T04:58:24.000Z
stog/modules/initializers.py
sfillwo/stog
b02e2dbe8989078ccdc3df611d8b08b63d28fcae
[ "MIT" ]
22
2019-07-13T09:11:57.000Z
2021-11-17T05:30:36.000Z
stog/modules/initializers.py
banditelol/stog
b965c47c17472eea11ab63aab9aa738af7875f06
[ "MIT" ]
39
2019-06-26T11:37:51.000Z
2022-03-07T13:30:26.000Z
""" Adopted from AllenNLP: https://github.com/allenai/allennlp/blob/v0.6.1/allennlp/nn/initializers.py An initializer is just a PyTorch function. Here we implement a proxy class that allows us to register them and supply any additional function arguments (for example, the ``mean`` and ``std`` of a normal initializ...
49.946154
152
0.708301
import re import math from typing import Callable, List, Tuple, Type, Iterable import itertools import torch import torch.nn.init from stog.utils import logging from stog.utils.checks import ConfigurationError logger = logging.init_logger() def uniform_unit_scaling(tensor: torch.Tensor, nonlinearity: str = "line...
true
true
f75632098576858b984cb783ccc623277954277e
373,414
py
Python
template_container_ferret/labels/slice_77.py
lkondratova/Brainplot
3c8a88c1995dedeaa5cbd88ee71499c7cf9c571d
[ "MIT" ]
null
null
null
template_container_ferret/labels/slice_77.py
lkondratova/Brainplot
3c8a88c1995dedeaa5cbd88ee71499c7cf9c571d
[ "MIT" ]
null
null
null
template_container_ferret/labels/slice_77.py
lkondratova/Brainplot
3c8a88c1995dedeaa5cbd88ee71499c7cf9c571d
[ "MIT" ]
null
null
null
coordinates_BCBCBC = ((159, 111), (162, 108), (163, 108), ) coordinates_993300 = ((222, 14), (222, 16), (222, 17), (222, 18), (222, 19), (222, 20), (222, 21), (222, 22), (222, 23), (222, 24), (222, 25), (222, 26), (222, 27), (222, 28), (222, 29), (222, 30), (222, 31), (222, 32), (222, 34), (222, 42), (222, 44), (2...
779.569937
865
0.481669
coordinates_BCBCBC = ((159, 111), (162, 108), (163, 108), ) coordinates_993300 = ((222, 14), (222, 16), (222, 17), (222, 18), (222, 19), (222, 20), (222, 21), (222, 22), (222, 23), (222, 24), (222, 25), (222, 26), (222, 27), (222, 28), (222, 29), (222, 30), (222, 31), (222, 32), (222, 34), (222, 42), (222, 44), (2...
true
true
f75632666d1fc43d67c7136f5ed03d3cd1a06ef3
1,559
py
Python
example_mask.py
jamal919/pyIntertidalDEM
1db667a9b52939a52c71d64e20200d66bfb03665
[ "Apache-2.0" ]
3
2019-12-08T14:41:50.000Z
2020-06-17T11:04:01.000Z
example_mask.py
jamal919/pyIntertidalDEM
1db667a9b52939a52c71d64e20200d66bfb03665
[ "Apache-2.0" ]
7
2021-06-30T13:24:16.000Z
2022-03-10T11:55:24.000Z
example_mask.py
jamal919/pyIntertidalDEM
1db667a9b52939a52c71d64e20200d66bfb03665
[ "Apache-2.0" ]
1
2019-10-10T19:45:26.000Z
2019-10-10T19:45:26.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- from __future__ import print_function import os import gc import time import numpy as np import matplotlib.pyplot as plt from pyintdem.core import Band, RGB from pyintdem.data import Sentinel2 # Directory Settings input_dir='/run/media/khan/Backup KE Maxelev' output_dir =...
31.816327
84
0.617062
from __future__ import print_function import os import gc import time import numpy as np import matplotlib.pyplot as plt from pyintdem.core import Band, RGB from pyintdem.data import Sentinel2 input_dir='/run/media/khan/Backup KE Maxelev' output_dir = '/run/media/khan/Backup KE Maxelev/Analysis_v3' data_dir = o...
true
true
f756327402bca1a56490b0590a0a33c7e9b31596
2,283
py
Python
tests/tabular_output/test_terminaltables_adapter.py
tirkarthi/cli_helpers
2ae90b0c579e604d53f6297255491e049d5029f6
[ "BSD-3-Clause" ]
null
null
null
tests/tabular_output/test_terminaltables_adapter.py
tirkarthi/cli_helpers
2ae90b0c579e604d53f6297255491e049d5029f6
[ "BSD-3-Clause" ]
null
null
null
tests/tabular_output/test_terminaltables_adapter.py
tirkarthi/cli_helpers
2ae90b0c579e604d53f6297255491e049d5029f6
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- """Test the terminaltables output adapter.""" from __future__ import unicode_literals from textwrap import dedent import pytest from cli_helpers.compat import HAS_PYGMENTS from cli_helpers.tabular_output import terminaltables_adapter if HAS_PYGMENTS: from pygments.style import Style ...
32.614286
86
0.540955
from __future__ import unicode_literals from textwrap import dedent import pytest from cli_helpers.compat import HAS_PYGMENTS from cli_helpers.tabular_output import terminaltables_adapter if HAS_PYGMENTS: from pygments.style import Style from pygments.token import Token def test_terminal_tables_adapter()...
true
true
f75633c5a9b3509ebc088b632551c61995e69559
2,818
py
Python
quantitative_finance/L3/python/dje_test.py
heeran-xilinx/Vitis_Libraries
ab3f6969e397dc44705a7278fb0d480e905e72db
[ "Apache-2.0" ]
1
2021-06-14T17:02:06.000Z
2021-06-14T17:02:06.000Z
quantitative_finance/L3/python/dje_test.py
heeran-xilinx/Vitis_Libraries
ab3f6969e397dc44705a7278fb0d480e905e72db
[ "Apache-2.0" ]
null
null
null
quantitative_finance/L3/python/dje_test.py
heeran-xilinx/Vitis_Libraries
ab3f6969e397dc44705a7278fb0d480e905e72db
[ "Apache-2.0" ]
1
2021-06-08T06:18:10.000Z
2021-06-08T06:18:10.000Z
#!/usr/bin/env python3 # Ensure environmental variables i.e. paths are set to used the modules from xf_fintech_python import DeviceManager, MCEuropeanDJE, OptionType import array # State test financial model print("\nThe Dow Jones MCEuropean financial model\n========================================\n") # Declaring V...
44.03125
254
0.750532
from xf_fintech_python import DeviceManager, MCEuropeanDJE, OptionType import array print("\nThe Dow Jones MCEuropean financial model\n========================================\n") deviceList = DeviceManager.getDeviceList("u250") outputResults = [] lastruntime = 0 stockPriceList = [163.69, 117.38, 182.06, 347.82...
true
true
f75633d6d15ba85ae7c0cd0865f4bc33f738c7a0
481
py
Python
assets/Poser/Reality/Runtime/Libraries/light/Reality/SingleIBLs/LineSingleV/Large/LineSingleV_Large_70.py
Red54/reality
510d4f5fde2f4c5535482f1ea199f914102b8a2a
[ "BSD-3-Clause" ]
null
null
null
assets/Poser/Reality/Runtime/Libraries/light/Reality/SingleIBLs/LineSingleV/Large/LineSingleV_Large_70.py
Red54/reality
510d4f5fde2f4c5535482f1ea199f914102b8a2a
[ "BSD-3-Clause" ]
null
null
null
assets/Poser/Reality/Runtime/Libraries/light/Reality/SingleIBLs/LineSingleV/Large/LineSingleV_Large_70.py
Red54/reality
510d4f5fde2f4c5535482f1ea199f914102b8a2a
[ "BSD-3-Clause" ]
null
null
null
# # Copyright (c) Pret-a-3D/Paolo Ciccone. All rights reserved. # Modified by Fuzzy70/Lee Furssedonn with kind permission from Paolo Ciccone # from Reality_services import * from Reality import * # To customize this script all you need to do is to # change the following variable Re_sIBL_Map = ":Runtime:Text...
32.066667
90
0.767152
from Reality_services import * from Reality import * Re_sIBL_Map = ":Runtime:Textures:Reality:SingleIBLs:LineSingleV:LineSingleV_Large_70.ibl" Reality.Scene().setIBLImage(ReResolvePoserPath(Re_sIBL_Map).encode("utf8"))
true
true
f7563408c01bf0491d2ae9779ba8cbf803ededa9
12,691
py
Python
bin/main.py
bferd/bing-desktop-wallpaper-changer-PepermintOS
595eeea6ab4ff58ea757956ed642aa88c4b2bb83
[ "MIT" ]
null
null
null
bin/main.py
bferd/bing-desktop-wallpaper-changer-PepermintOS
595eeea6ab4ff58ea757956ed642aa88c4b2bb83
[ "MIT" ]
null
null
null
bin/main.py
bferd/bing-desktop-wallpaper-changer-PepermintOS
595eeea6ab4ff58ea757956ed642aa88c4b2bb83
[ "MIT" ]
null
null
null
#!/usr/bin/python # -*- coding: utf-8 -*- import locale import os import re import sys import shutil from PIL import Image # setup done to /opt/bing-desktop-wallpaper-changer by BDWC Installer v3.3.1-release path_to_Bing_Wallpapers="/opt/bing-desktop-wallpaper-changer" # wait computer internet connection os.system("...
28.647856
112
0.589158
import locale import os import re import sys import shutil from PIL import Image path_to_Bing_Wallpapers="/opt/bing-desktop-wallpaper-changer" os.system("sleep 10") try: from urllib.request import urlopen from urllib.request import urlretrieve from configparser import ConfigParser except ImportErr...
true
true
f75634ccc49a830308698fc6bea62d7f191eeab2
1,668
py
Python
xero_python/accounting/models/report_with_rows.py
parasharrk/xero-python
e8416f3bd893520a343af014f5bb65acbf1f4f13
[ "MIT" ]
null
null
null
xero_python/accounting/models/report_with_rows.py
parasharrk/xero-python
e8416f3bd893520a343af014f5bb65acbf1f4f13
[ "MIT" ]
null
null
null
xero_python/accounting/models/report_with_rows.py
parasharrk/xero-python
e8416f3bd893520a343af014f5bb65acbf1f4f13
[ "MIT" ]
null
null
null
# coding: utf-8 """ Accounting API No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 OpenAPI spec version: 2.4.0 Contact: api@xero.com Generated by: https://openapi-generator.tech """ import re # noqa: F401 from xero_pytho...
25.272727
124
0.622902
import re from xero_python.models import BaseModel class ReportWithRows(BaseModel): openapi_types = {"reports": "list[ReportWithRow]"} attribute_map = {"reports": "Reports"} def __init__(self, reports=None): self._reports = None self.discriminator = None if reports is...
true
true
f75634d856e8331069faa8f4d348f2ded3823467
17,929
py
Python
tensorflow/python/ops/string_ops.py
datanonymous/TFandroid
89927e863b1ad96184ab09188f62b7e391c896d9
[ "Apache-2.0" ]
6
2019-02-05T22:36:51.000Z
2022-01-14T03:50:57.000Z
tensorflow/python/ops/string_ops.py
shekharpalit/tensorflow
6aa83398ab03bfae822f36772757097bcb98b6ed
[ "Apache-2.0" ]
1
2019-09-14T04:40:07.000Z
2020-11-18T18:16:17.000Z
tensorflow/python/ops/string_ops.py
shekharpalit/tensorflow
6aa83398ab03bfae822f36772757097bcb98b6ed
[ "Apache-2.0" ]
8
2016-01-14T13:12:56.000Z
2021-04-09T10:20:53.000Z
# Copyright 2015 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
37.430063
89
0.703609
from __future__ import absolute_import from __future__ import division from __future__ import print_function import numpy as np from tensorflow.python.compat import compat from tensorflow.python.framework import constant_op from tensorflow.python.framework import dtypes from tensorflow.python.framewor...
true
true
f756352060c474d7a123e36d9d7fc377ffb88fbb
124,150
py
Python
musicbot/bot.py
javifdeezg/musicdiscordapp
3f64d7feb470c0d26b154d8a754c57943dc459b7
[ "MIT" ]
null
null
null
musicbot/bot.py
javifdeezg/musicdiscordapp
3f64d7feb470c0d26b154d8a754c57943dc459b7
[ "MIT" ]
null
null
null
musicbot/bot.py
javifdeezg/musicdiscordapp
3f64d7feb470c0d26b154d8a754c57943dc459b7
[ "MIT" ]
null
null
null
import os import sys import time import shlex import shutil import random import inspect import logging import asyncio import pathlib import traceback import math import re import aiohttp import discord import colorlog from io import BytesIO, StringIO from functools import wraps from textwrap import dedent from datet...
43.018018
219
0.585832
import os import sys import time import shlex import shutil import random import inspect import logging import asyncio import pathlib import traceback import math import re import aiohttp import discord import colorlog from io import BytesIO, StringIO from functools import wraps from textwrap import dedent from datet...
true
true
f7563656884f83256297a916c01cf434867d4e25
508
py
Python
src/xrd/crypto/Qryptonight7.py
jack3343/xrd-core
48a6d890d62485c627060b017eadf85602268caf
[ "MIT" ]
null
null
null
src/xrd/crypto/Qryptonight7.py
jack3343/xrd-core
48a6d890d62485c627060b017eadf85602268caf
[ "MIT" ]
null
null
null
src/xrd/crypto/Qryptonight7.py
jack3343/xrd-core
48a6d890d62485c627060b017eadf85602268caf
[ "MIT" ]
null
null
null
# coding=utf-8 # Distributed under the MIT software license, see the accompanying # file LICENSE or http://www.opensource.org/licenses/mit-license.php. import threading from xrd.core.Singleton import Singleton from pyqryptonight import pyqryptonight class Qryptonight7(object, metaclass=Singleton): def __init__(...
26.736842
69
0.720472
import threading from xrd.core.Singleton import Singleton from pyqryptonight import pyqryptonight class Qryptonight7(object, metaclass=Singleton): def __init__(self): self.lock = threading.Lock() self._qn = pyqryptonight.Qryptonight() def hash(self, blob): with self.lock: ...
true
true