hexsha
stringlengths
40
40
size
int64
10
805k
ext
stringclasses
6 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
176
max_stars_repo_name
stringlengths
7
114
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
176
max_issues_repo_name
stringlengths
7
114
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
48.5k
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
176
max_forks_repo_name
stringlengths
7
114
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
10
805k
avg_line_length
float64
5.53
11k
max_line_length
int64
10
129k
alphanum_fraction
float64
0.13
0.93
content_no_comment
stringlengths
0
449k
is_comment_constant_removed
bool
2 classes
is_sharp_comment_removed
bool
1 class
f71970c5e8e3cf8ece041b681a8768c3ae4e47b1
1,079
py
Python
codenerix_pos/admin.py
centrologic/django-codenerix-pos
449c54971c510aba2326797ab7aaf3a0b5f6c3ab
[ "Apache-2.0" ]
3
2017-07-19T15:24:26.000Z
2017-12-22T01:35:28.000Z
codenerix_pos/admin.py
centrologic/django-codenerix-pos
449c54971c510aba2326797ab7aaf3a0b5f6c3ab
[ "Apache-2.0" ]
null
null
null
codenerix_pos/admin.py
centrologic/django-codenerix-pos
449c54971c510aba2326797ab7aaf3a0b5f6c3ab
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # # django-codenerix-pos # # Codenerix GNU # # Project URL : http://www.codenerix.com # # 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/license...
31.735294
114
0.776645
from django.contrib import admin from .models import POS, POSSlot, POSPlant, POSZone, POSProduct, POSHardware, POSOperator, POSLog, POSGroupProduct admin.site.register(POSPlant) admin.site.register(POSZone) admin.site.register(POSHardware) admin.site.register(POSGroupProduct) admin.site.register(P...
true
true
f71970cd94b344b2aafb1578c85a08cee5366ca7
20,090
py
Python
script.py
lawlie8/Mr.Hyde
c3d2c04de6343580b4b14cbd2319737ed0b3a73e
[ "MIT" ]
3
2020-06-04T10:02:35.000Z
2020-06-05T11:44:02.000Z
script.py
lawlie8/Mr.Hyde
c3d2c04de6343580b4b14cbd2319737ed0b3a73e
[ "MIT" ]
null
null
null
script.py
lawlie8/Mr.Hyde
c3d2c04de6343580b4b14cbd2319737ed0b3a73e
[ "MIT" ]
null
null
null
#!/usr/bin/python3 import tkinter as tk from tkinter import * from tkinter.ttk import * from Crypto import Random from Crypto.Cipher import AES from Crypto.Hash import SHA256 import os import os.path from os import listdir from os.path import isfile, join #import time import ctypes #import threading import hashlib impo...
49.482759
318
0.541563
import tkinter as tk from tkinter import * from tkinter.ttk import * from Crypto import Random from Crypto.Cipher import AES from Crypto.Hash import SHA256 import os import os.path from os import listdir from os.path import isfile, join import ctypes import hashlib import random import binascii try: def is_admi...
true
true
f719721f94c03312a66a5dd67b5e3f239bdd431b
1,925
py
Python
setup.py
unclemedia0/phasiakon
fe6cef9b8c3d8f7da0a9ef3b18f9c2ea0ec08dc0
[ "MIT" ]
null
null
null
setup.py
unclemedia0/phasiakon
fe6cef9b8c3d8f7da0a9ef3b18f9c2ea0ec08dc0
[ "MIT" ]
null
null
null
setup.py
unclemedia0/phasiakon
fe6cef9b8c3d8f7da0a9ef3b18f9c2ea0ec08dc0
[ "MIT" ]
null
null
null
from distutils.core import setup try: with open("README.md","r") as fh: long_description = fh.read() except: long_description = 'Taxation7% by UncleMedia' setup( name = 'phasiakon', # How you named your package folder (MyLib) packages = ['phasiakon'], # Chose the same as "name" vers...
55
147
0.660779
from distutils.core import setup try: with open("README.md","r") as fh: long_description = fh.read() except: long_description = 'Taxation7% by UncleMedia' setup( name = 'phasiakon', packages = ['phasiakon'], version = '0.1', license='MIT', description = 'Taxation7%...
true
true
f719733841763fd63a92a93738e9a161aaffbe6e
4,753
py
Python
momus/VHRED/split-examples-by-token.py
ourDirection/ourDirection
b99ed67a8cc0fe5016e03fe3b5ad083b7f8bbdc0
[ "Apache-2.0" ]
null
null
null
momus/VHRED/split-examples-by-token.py
ourDirection/ourDirection
b99ed67a8cc0fe5016e03fe3b5ad083b7f8bbdc0
[ "Apache-2.0" ]
null
null
null
momus/VHRED/split-examples-by-token.py
ourDirection/ourDirection
b99ed67a8cc0fe5016e03fe3b5ad083b7f8bbdc0
[ "Apache-2.0" ]
null
null
null
""" Takes as input a binarized dialogue corpus, splits the examples by a certain token and shuffles it Example run: python split-examples-by-token.py Training.dialogues.pkl 2 Training_SplitByDialogues.dialogues --join_last_two_examples @author Iulian Vlad Serban """ import collections import numpy import math im...
35.736842
208
0.722281
import collections import numpy import math import operator import os import sys import logging import cPickle from collections import Counter logging.basicConfig(level=logging.INFO) logger = logging.getLogger('text2dict') def safe_pickle(obj, filename): if os.path.isfile(filename): logger.info("Overwri...
true
true
f719736b5b137de7082002cec486dbcda1835bae
1,497
py
Python
tapis_cli/commands/taccapis/v2/systems/roles_show.py
shwetagopaul92/tapis-cli-ng
6f424b8352c0d034d4f5547fac21d5c8dd097a7f
[ "BSD-3-Clause" ]
null
null
null
tapis_cli/commands/taccapis/v2/systems/roles_show.py
shwetagopaul92/tapis-cli-ng
6f424b8352c0d034d4f5547fac21d5c8dd097a7f
[ "BSD-3-Clause" ]
null
null
null
tapis_cli/commands/taccapis/v2/systems/roles_show.py
shwetagopaul92/tapis-cli-ng
6f424b8352c0d034d4f5547fac21d5c8dd097a7f
[ "BSD-3-Clause" ]
null
null
null
from agavepy.agave import AgaveError from tapis_cli.display import Verbosity from tapis_cli.clients.services.mixins import ServiceIdentifier, Username from . import API_NAME, SERVICE_VERSION from .models import SystemRole from .formatters import SystemsFormatOne __all__ = ['SystemsRolesShow'] class SystemsRolesShow...
33.266667
79
0.669339
from agavepy.agave import AgaveError from tapis_cli.display import Verbosity from tapis_cli.clients.services.mixins import ServiceIdentifier, Username from . import API_NAME, SERVICE_VERSION from .models import SystemRole from .formatters import SystemsFormatOne __all__ = ['SystemsRolesShow'] class SystemsRolesShow...
true
true
f719761c09d3fa035769e8bee81a2d948a8ad1b9
255
py
Python
tests/test_example.py
skylifewww/handball
853190e44037086b7749cb8f62d9df6577b379fd
[ "MIT" ]
null
null
null
tests/test_example.py
skylifewww/handball
853190e44037086b7749cb8f62d9df6577b379fd
[ "MIT" ]
null
null
null
tests/test_example.py
skylifewww/handball
853190e44037086b7749cb8f62d9df6577b379fd
[ "MIT" ]
null
null
null
from handball.core.test import TestCase from handball.users.factories import UserFactory class TestExample(TestCase): def test_example(self): UserFactory() resp = self.client.get('/') self.assertEqual(resp.status_code, 200)
23.181818
48
0.709804
from handball.core.test import TestCase from handball.users.factories import UserFactory class TestExample(TestCase): def test_example(self): UserFactory() resp = self.client.get('/') self.assertEqual(resp.status_code, 200)
true
true
f719771bdcfb47ab5315aba6e6e1b06f312f1af0
792
py
Python
samples/client/petstore/python-experimental/test/test_parent.py
MalcolmScoffable/openapi-generator
73605a0c0e0c825286c95123c63678ba75b44d5c
[ "Apache-2.0" ]
4
2020-07-24T07:02:57.000Z
2022-01-08T17:37:38.000Z
samples/client/petstore/python-experimental/test/test_parent.py
MalcolmScoffable/openapi-generator
73605a0c0e0c825286c95123c63678ba75b44d5c
[ "Apache-2.0" ]
7
2021-05-12T00:00:20.000Z
2022-02-27T11:23:35.000Z
samples/client/petstore/python-experimental/test/test_parent.py
MalcolmScoffable/openapi-generator
73605a0c0e0c825286c95123c63678ba75b44d5c
[ "Apache-2.0" ]
2
2020-04-24T15:18:41.000Z
2021-12-07T09:39:40.000Z
# coding: utf-8 """ OpenAPI Petstore This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ # noqa: E501 The version of the OpenAPI document: 1.0.0 Generated by: https://openapi-generator.tech """ ...
20.842105
174
0.667929
from __future__ import absolute_import import unittest import petstore_api class TestParent(unittest.TestCase): def setUp(self): pass def tearDown(self): pass def testParent(self): s if __name__ == '__main__': unittest.main()
true
true
f71977e9459670b106619a17c0921c378ddd8285
166
py
Python
tests/model_control/detailed/transf_Quantization/model_control_one_enabled_Quantization_LinearTrend_Seasonal_Hour_SVR.py
jmabry/pyaf
afbc15a851a2445a7824bf255af612dc429265af
[ "BSD-3-Clause" ]
null
null
null
tests/model_control/detailed/transf_Quantization/model_control_one_enabled_Quantization_LinearTrend_Seasonal_Hour_SVR.py
jmabry/pyaf
afbc15a851a2445a7824bf255af612dc429265af
[ "BSD-3-Clause" ]
1
2019-11-30T23:39:38.000Z
2019-12-01T04:34:35.000Z
tests/model_control/detailed/transf_Quantization/model_control_one_enabled_Quantization_LinearTrend_Seasonal_Hour_SVR.py
jmabry/pyaf
afbc15a851a2445a7824bf255af612dc429265af
[ "BSD-3-Clause" ]
null
null
null
import pyaf.tests.model_control.test_ozone_custom_models_enabled as testmod testmod.build_model( ['Quantization'] , ['LinearTrend'] , ['Seasonal_Hour'] , ['SVR'] );
41.5
88
0.759036
import pyaf.tests.model_control.test_ozone_custom_models_enabled as testmod testmod.build_model( ['Quantization'] , ['LinearTrend'] , ['Seasonal_Hour'] , ['SVR'] );
true
true
f71979aaf903ff6353153012c1f5c64b155b2d5a
6,406
py
Python
libs/python/multicore_sorted/drafts/py_merge/multicore_sorted.py
denis-ryzhkov/antiques
6a67bf606c1b49cc413df26bfdf00d392b605f88
[ "MIT" ]
null
null
null
libs/python/multicore_sorted/drafts/py_merge/multicore_sorted.py
denis-ryzhkov/antiques
6a67bf606c1b49cc413df26bfdf00d392b605f88
[ "MIT" ]
null
null
null
libs/python/multicore_sorted/drafts/py_merge/multicore_sorted.py
denis-ryzhkov/antiques
6a67bf606c1b49cc413df26bfdf00d392b605f88
[ "MIT" ]
null
null
null
""" >>> DRAFT "py_merge"! <<< Builtin "sorted()" function, but using all CPU cores available for speedup! It supports all kwargs of "sorted()": "cmp", "key" and "reverse", however items of "iterable" and all of these kwargs should be picklable: https://docs.python.org/2/library/pickle.html#what-can-be-pickled-and-unp...
28.471111
118
0.635498
ted'] nctools import cmp_to_key from multiprocessing import cpu_count, Pool = kwargs.pop('processes', None) if processes is None: try: processes = cpu_count() except NotImplementedError: processes = 1 if processes < 2: return sorted(iterable, **kwargs) ...
true
true
f7197a79112a1c5cebafd40d2898d9834ee03a99
15,162
py
Python
test/simulator_tests/birth_death_simulator_test.py
YosefLab/SingleCellLineageTracing
d9133fc80c8314e7935fde037dd86111cac47447
[ "MIT" ]
52
2019-05-14T02:06:24.000Z
2022-03-27T05:22:56.000Z
test/simulator_tests/birth_death_simulator_test.py
sbradford2/Cassiopeia
010072b307f7eadbf10dc4af8b2165e48f1736a7
[ "MIT" ]
88
2019-06-07T15:07:45.000Z
2022-03-22T14:40:03.000Z
test/simulator_tests/birth_death_simulator_test.py
sbradford2/Cassiopeia
010072b307f7eadbf10dc4af8b2165e48f1736a7
[ "MIT" ]
17
2019-05-17T00:46:16.000Z
2022-03-25T00:39:18.000Z
import unittest import networkx as nx import numpy as np from typing import List, Tuple from cassiopeia.data.CassiopeiaTree import CassiopeiaTree from cassiopeia.mixins import TreeSimulatorError from cassiopeia.simulator.BirthDeathFitnessSimulator import ( BirthDeathFitnessSimulator, ) import cassiopeia.data.u...
36.186158
80
0.595502
import unittest import networkx as nx import numpy as np from typing import List, Tuple from cassiopeia.data.CassiopeiaTree import CassiopeiaTree from cassiopeia.mixins import TreeSimulatorError from cassiopeia.simulator.BirthDeathFitnessSimulator import ( BirthDeathFitnessSimulator, ) import cassiopeia.data.u...
true
true
f7197adb438e0099947d4309aa51de3f15e7c419
2,615
py
Python
src/sparkload.py
jbalint/spark
caccf1cd9122dd4a7dc0f26a57ee4a649056aa6f
[ "CNRI-Jython" ]
1
2015-05-21T20:00:12.000Z
2015-05-21T20:00:12.000Z
src/sparkload.py
jbalint/spark
caccf1cd9122dd4a7dc0f26a57ee4a649056aa6f
[ "CNRI-Jython" ]
null
null
null
src/sparkload.py
jbalint/spark
caccf1cd9122dd4a7dc0f26a57ee4a649056aa6f
[ "CNRI-Jython" ]
null
null
null
#!/usr/bin/env jython #*****************************************************************************# #* Copyright (c) 2004-2008, SRI International. *# #* All rights reserved. *# #* ...
70.675676
80
0.518164
al.version import * from spark.main import main
true
true
f7197b8026a171a1b01fc519f2c5d4c23b3f4e4d
7,153
py
Python
tests/test_other_scripts.py
vaibhavad/ParlAI
8960fab4cb7b7063df6023d8734adc8881dfed6e
[ "MIT" ]
2
2017-09-20T21:49:51.000Z
2018-08-12T06:58:10.000Z
tests/test_other_scripts.py
vaibhavad/ParlAI
8960fab4cb7b7063df6023d8734adc8881dfed6e
[ "MIT" ]
1
2021-01-22T08:11:01.000Z
2021-01-22T08:11:01.000Z
tests/test_other_scripts.py
vaibhavad/ParlAI
8960fab4cb7b7063df6023d8734adc8881dfed6e
[ "MIT" ]
1
2021-01-07T11:45:03.000Z
2021-01-07T11:45:03.000Z
#!/usr/bin/env python3 # Copyright (c) Facebook, Inc. and its affiliates. # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. """ Catch all for a number of "other" scripts. """ import os import unittest import parlai.utils.testing as testing_uti...
35.063725
87
0.562282
import os import unittest import parlai.utils.testing as testing_utils class TestConvertToParlaiFormat(unittest.TestCase): def test_convert(self): from parlai.scripts.convert_data_to_parlai_format import ( ConvertDataToParlaiFormat, ) with testing_utils.tempdir() as tmp...
true
true
f7197c8fd871714cbb61cb9b004d8a0b6f5dd33a
1,297
py
Python
sr700api/utils.py
AlexGS74/sr700api
22fc79c0e02ef66f4ef92f9c8b4a56c04fe09c4a
[ "MIT" ]
5
2017-10-15T21:58:55.000Z
2020-09-02T05:12:32.000Z
sr700api/utils.py
AlexGS74/sr700api
22fc79c0e02ef66f4ef92f9c8b4a56c04fe09c4a
[ "MIT" ]
null
null
null
sr700api/utils.py
AlexGS74/sr700api
22fc79c0e02ef66f4ef92f9c8b4a56c04fe09c4a
[ "MIT" ]
1
2018-08-25T23:27:53.000Z
2018-08-25T23:27:53.000Z
""" MIT License Copyright (c) 2017 int3ll3ct.ly@gmail.com 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,...
40.53125
78
0.781033
def f_to_c(deg_f): return (deg_f - 32.0)/1.8 def c_to_f(deg_c): return deg_c * 1.8 + 32.0
true
true
f7197ce5cfde61155bd0c88a6aa247110b8af814
10,671
py
Python
tests/test_camera.py
netmanchris/abodepy
cd7b5527cc2becd12763d949057fe0184e0395d2
[ "MIT" ]
null
null
null
tests/test_camera.py
netmanchris/abodepy
cd7b5527cc2becd12763d949057fe0184e0395d2
[ "MIT" ]
null
null
null
tests/test_camera.py
netmanchris/abodepy
cd7b5527cc2becd12763d949057fe0184e0395d2
[ "MIT" ]
null
null
null
"""Test the Abode camera class.""" import os import unittest import requests_mock import abodepy import abodepy.helpers.constants as CONST import tests.mock as MOCK import tests.mock.devices.ir_camera as IRCAMERA import tests.mock.login as LOGIN import tests.mock.oauth_claims as OAUTH_CLAIMS import tests.mock.logout ...
37.181185
79
0.607722
import os import unittest import requests_mock import abodepy import abodepy.helpers.constants as CONST import tests.mock as MOCK import tests.mock.devices.ir_camera as IRCAMERA import tests.mock.login as LOGIN import tests.mock.oauth_claims as OAUTH_CLAIMS import tests.mock.logout as LOGOUT import tests.mock.panel a...
true
true
f7197da9b6e226e3c5a5e47bd5f775747c208e82
13,187
py
Python
kws_streaming/train/train.py
ssccutyy/KWS-Transformer
7ae6d2e8fce1a293d88eedc0dbfacae726151a08
[ "Apache-2.0" ]
1
2022-03-13T07:52:15.000Z
2022-03-13T07:52:15.000Z
kws_streaming/train/train.py
ssccutyy/KWS-Transformer
7ae6d2e8fce1a293d88eedc0dbfacae726151a08
[ "Apache-2.0" ]
null
null
null
kws_streaming/train/train.py
ssccutyy/KWS-Transformer
7ae6d2e8fce1a293d88eedc0dbfacae726151a08
[ "Apache-2.0" ]
1
2022-03-11T12:33:27.000Z
2022-03-11T12:33:27.000Z
# coding=utf-8 # Copyright (c) 2021, Arm Limited and Contributors. # SPDX-License-Identifier: Apache-2.0 # Copyright 2021 The Google Research 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 Lic...
42.401929
159
0.705543
import json from types import SimpleNamespace import os.path import pprint from absl import logging import numpy as np import tensorflow.compat.v1 as tf import tensorflow_addons as tfa import kws_streaming.data.input_data as input_data from kws_streaming.models import models from kws_streaming.models i...
true
true
f7197ec8accb7480f7e6eca284267bccdb20df57
5,965
py
Python
test/functional/rpc_users.py
mrmikeo/GAU-Core
6f56bb73d0736a4245c22391314d6ba55de0e0d8
[ "MIT" ]
2
2020-08-25T18:02:32.000Z
2021-08-23T09:40:41.000Z
test/functional/rpc_users.py
mrmikeo/GAU-Core
6f56bb73d0736a4245c22391314d6ba55de0e0d8
[ "MIT" ]
null
null
null
test/functional/rpc_users.py
mrmikeo/GAU-Core
6f56bb73d0736a4245c22391314d6ba55de0e0d8
[ "MIT" ]
2
2020-08-06T20:56:42.000Z
2020-11-23T03:11:17.000Z
#!/usr/bin/env python3 # Copyright (c) 2015-2017 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Test multiple RPC users.""" from test_framework.test_framework import BitcoinTestFramework from test_f...
38.733766
129
0.61425
from test_framework.test_framework import BitcoinTestFramework from test_framework.util import str_to_b64str, assert_equal import os import http.client import urllib.parse class HTTPBasicsTest (BitcoinTestFramework): def set_test_params(self): self.num_nodes = 2 def setup_chain(self): su...
true
true
f719804da78f16f6af3489ac457e49300a75a6b2
1,916
py
Python
do_flask_mail.py
penglee87/lpython
3a53322ccdebf83d6b358386518cf81712433c9e
[ "bzip2-1.0.6" ]
null
null
null
do_flask_mail.py
penglee87/lpython
3a53322ccdebf83d6b358386518cf81712433c9e
[ "bzip2-1.0.6" ]
null
null
null
do_flask_mail.py
penglee87/lpython
3a53322ccdebf83d6b358386518cf81712433c9e
[ "bzip2-1.0.6" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- from flask import Flask from flask_mail import Mail from flask_mail import Message import os #测试成功,部分参数作用不明 app = Flask(__name__) app.config['MAIL_SERVER'] = 'smtp.163.com' app.config['MAIL_PORT'] = 25 app.config['MAIL_USE_TLS'] = True app.config['MAIL_USERNAME'] = 'pengl...
26.246575
97
0.647182
from flask import Flask from flask_mail import Mail from flask_mail import Message import os app = Flask(__name__) app.config['MAIL_SERVER'] = 'smtp.163.com' app.config['MAIL_PORT'] = 25 app.config['MAIL_USE_TLS'] = True app.config['MAIL_USERNAME'] = 'penglee87@163.com' app.config['MAIL_PASSWORD'] = '******' app.co...
true
true
f71982541576d139123ce5e181dca42523d11d05
459
py
Python
blog/search_indexes.py
GITliyanfeng/blog-django
a804702026a2d58664ec83a993116e17b89e9e8e
[ "MIT" ]
2
2019-03-14T12:35:36.000Z
2019-03-14T12:35:38.000Z
blog/search_indexes.py
GITliyanfeng/blog-django
a804702026a2d58664ec83a993116e17b89e9e8e
[ "MIT" ]
null
null
null
blog/search_indexes.py
GITliyanfeng/blog-django
a804702026a2d58664ec83a993116e17b89e9e8e
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # @Time : 2019/3/19 0019 16:25 # @Author : __Yanfeng # @Site : # @File : search_indexes.py # @Software: PyCharm from haystack import indexes from .models import Post class PostIndex(indexes.SearchIndex, indexes.Indexable): text = indexes.CharField(document=True, use_template=Tru...
24.157895
62
0.67756
from haystack import indexes from .models import Post class PostIndex(indexes.SearchIndex, indexes.Indexable): text = indexes.CharField(document=True, use_template=True) def get_model(self): return Post def index_queryset(self, using=None): return self.get_model().latest_posts()
true
true
f7198316dcf1fee5ef6b1b5530246a472718064a
109
py
Python
rest_framework_security/deny_repeat_password/__init__.py
RubenEu/django-rest-framework-security
638cf271c51a5bafd434a6b6a9c25a7c4849b485
[ "MIT" ]
7
2020-09-01T09:55:25.000Z
2021-11-04T06:59:04.000Z
rest_framework_security/deny_repeat_password/__init__.py
RubenEu/django-rest-framework-security
638cf271c51a5bafd434a6b6a9c25a7c4849b485
[ "MIT" ]
32
2020-10-28T17:09:18.000Z
2022-03-12T00:55:09.000Z
rest_framework_security/deny_repeat_password/__init__.py
RubenEu/django-rest-framework-security
638cf271c51a5bafd434a6b6a9c25a7c4849b485
[ "MIT" ]
2
2020-12-18T01:26:53.000Z
2021-11-04T06:59:07.000Z
default_app_config = ( "rest_framework_security.deny_repeat_password.apps.DenyRepeatPasswordAppConfig" )
27.25
83
0.844037
default_app_config = ( "rest_framework_security.deny_repeat_password.apps.DenyRepeatPasswordAppConfig" )
true
true
f71983d5a0a270119c6b7c7701a902ea4892f18a
20,123
py
Python
obstools/scripts/atacr_clean_spectra.py
paudetseis/OBStools
c6c02d8864c25a14f22d1fae17ff5ad911b9ff00
[ "MIT" ]
1
2019-12-05T04:32:38.000Z
2019-12-05T04:32:38.000Z
obstools/scripts/atacr_clean_spectra.py
paudetseis/OBStools
c6c02d8864c25a14f22d1fae17ff5ad911b9ff00
[ "MIT" ]
2
2019-12-04T02:06:45.000Z
2019-12-06T22:20:19.000Z
obstools/scripts/atacr_clean_spectra.py
paudetseis/OBStools
c6c02d8864c25a14f22d1fae17ff5ad911b9ff00
[ "MIT" ]
1
2020-02-25T16:51:35.000Z
2020-02-25T16:51:35.000Z
#!/usr/bin/env python # Copyright 2019 Pascal Audet & Helen Janiszewski # # This file is part of OBStools. # # 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 wi...
34.28109
79
0.533718
import numpy as np import pickle import stdb from obstools.atacr import StaNoise, Power, Cross, Rotation from obstools.atacr import utils, plotting from pathlib import Path from argparse import ArgumentParser from os.path import exists as exist from obspy import UTCDateTime from numpy import ...
true
true
f7198466f423c197e1cd92a6791f6a97eeca93b9
2,362
py
Python
tests/demos/test_demos.py
Nicolinho/RLBench
3014e872f518d5439e73e057e2251dee1f9df481
[ "BSD-3-Clause" ]
619
2019-09-26T23:15:57.000Z
2022-03-15T23:46:48.000Z
tests/demos/test_demos.py
Nicolinho/RLBench
3014e872f518d5439e73e057e2251dee1f9df481
[ "BSD-3-Clause" ]
147
2019-09-27T02:22:45.000Z
2022-03-30T08:37:43.000Z
tests/demos/test_demos.py
Nicolinho/RLBench
3014e872f518d5439e73e057e2251dee1f9df481
[ "BSD-3-Clause" ]
142
2019-09-27T03:43:12.000Z
2022-03-13T19:00:18.000Z
import unittest import rlbench.backend.task as task import os from rlbench.backend.utils import task_file_to_task_class from pyrep import PyRep from pyrep.robots.arms.panda import Panda from pyrep.robots.end_effectors.panda_gripper import PandaGripper from rlbench.backend.const import TTT_FILE from tools.task_validator...
38.096774
78
0.610076
import unittest import rlbench.backend.task as task import os from rlbench.backend.utils import task_file_to_task_class from pyrep import PyRep from pyrep.robots.arms.panda import Panda from pyrep.robots.end_effectors.panda_gripper import PandaGripper from rlbench.backend.const import TTT_FILE from tools.task_validator...
true
true
f719867e8b00abb554a28d0fafbc160c9ea3d04e
3,652
py
Python
nova/openstack/common/excutils.py
bopopescu/nova_audit
1cd2901802f82d39411adfa04cf2f432ff3bf280
[ "Apache-2.0" ]
1
2020-02-21T19:19:11.000Z
2020-02-21T19:19:11.000Z
nova/openstack/common/excutils.py
bopopescu/nova_audit
1cd2901802f82d39411adfa04cf2f432ff3bf280
[ "Apache-2.0" ]
null
null
null
nova/openstack/common/excutils.py
bopopescu/nova_audit
1cd2901802f82d39411adfa04cf2f432ff3bf280
[ "Apache-2.0" ]
1
2020-07-24T09:15:58.000Z
2020-07-24T09:15:58.000Z
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright 2011 OpenStack Foundation. # Copyright 2012, 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:/...
36.888889
78
0.61172
""" Exception related utilities. """ import logging import sys import time import traceback from nova.openstack.common.gettextutils import _ class save_and_reraise_exception(object): """Save current exception, run some code and then re-raise. In some cases the exception context can be clea...
false
true
f71986b928e02b3c1c5322f3668bc41a49a8abc1
7,013
py
Python
GHC2018/process.py
purrcat259/n-n-hashcode
98a1c443e6112903bc29a858bc18476a6635d460
[ "MIT" ]
null
null
null
GHC2018/process.py
purrcat259/n-n-hashcode
98a1c443e6112903bc29a858bc18476a6635d460
[ "MIT" ]
null
null
null
GHC2018/process.py
purrcat259/n-n-hashcode
98a1c443e6112903bc29a858bc18476a6635d460
[ "MIT" ]
null
null
null
from GHC2018.input import Input from GHC2018.models.Car import Car from GHC2018.models.Route import Route from GHC2018.models.ride import calculate_distance from tqdm import tqdm class Process: def __init__(self, input_data, debug=True): self.input_data = input_data self.debug = debug sel...
39.178771
126
0.610866
from GHC2018.input import Input from GHC2018.models.Car import Car from GHC2018.models.Route import Route from GHC2018.models.ride import calculate_distance from tqdm import tqdm class Process: def __init__(self, input_data, debug=True): self.input_data = input_data self.debug = debug sel...
true
true
f719878d7cf2f176cf391bedf04e4b2cfa47cc02
1,701
py
Python
app/core/migrations/0001_initial.py
SirEric-A/recipe-app-api
05a767fcb87f2ca47918698930d10f6e21654576
[ "MIT" ]
null
null
null
app/core/migrations/0001_initial.py
SirEric-A/recipe-app-api
05a767fcb87f2ca47918698930d10f6e21654576
[ "MIT" ]
null
null
null
app/core/migrations/0001_initial.py
SirEric-A/recipe-app-api
05a767fcb87f2ca47918698930d10f6e21654576
[ "MIT" ]
null
null
null
# Generated by Django 3.0.7 on 2020-06-18 21:50 from django.db import migrations, models class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0011_update_proxy_permissions'), ] operations = [ migrations.CreateModel( name='User', f...
50.029412
266
0.637272
from django.db import migrations, models class Migration(migrations.Migration): initial = True dependencies = [ ('auth', '0011_update_proxy_permissions'), ] operations = [ migrations.CreateModel( name='User', fields=[ ('id', models.AutoField...
true
true
f71987f0e511820af63a6cf60ad703869664ef65
4,832
py
Python
.ycm_extra_conf.py
bigt1234/objectpool
dab515f71c12f8df22686053043f7e2c4c929354
[ "Zlib" ]
66
2016-11-07T01:00:46.000Z
2022-03-13T01:25:54.000Z
.ycm_extra_conf.py
bigt1234/objectpool
dab515f71c12f8df22686053043f7e2c4c929354
[ "Zlib" ]
1
2020-11-26T12:08:53.000Z
2021-09-24T01:06:49.000Z
.ycm_extra_conf.py
bigt1234/objectpool
dab515f71c12f8df22686053043f7e2c4c929354
[ "Zlib" ]
19
2016-07-18T07:58:11.000Z
2022-03-13T01:24:07.000Z
#!/usr/bin/env python # # Copyright (C) 2014 Google Inc. # # This file is part of YouCompleteMe. # # YouCompleteMe is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at you...
32.648649
79
0.708609
import os import ycm_core # compilation database set (by default, one is not set). # CHANGE THIS LIST OF FLAGS. YES, THIS IS THE DROID YOU HAVE BEEN LOOKING FOR. flags = [ '-Wall', '-Wextra', '-Werror', '-fexceptions', '-DNDEBUG', # THIS IS IMPORTANT! Without a "-std=<something>" flag, clang won't ...
true
true
f71988e1a677b3eb305af40560a0785370f713df
14,327
py
Python
oqupy/backends/tempo_backend.py
tempoCollaboration/OQuPy
a389a161991a59259e5df47d8e0f405fcac75fe5
[ "Apache-2.0" ]
13
2022-02-15T12:33:17.000Z
2022-03-31T10:01:57.000Z
oqupy/backends/tempo_backend.py
tempoCollaboration/OQuPy
a389a161991a59259e5df47d8e0f405fcac75fe5
[ "Apache-2.0" ]
11
2022-02-16T07:35:46.000Z
2022-03-24T18:22:12.000Z
oqupy/backends/tempo_backend.py
tempoCollaboration/OQuPy
a389a161991a59259e5df47d8e0f405fcac75fe5
[ "Apache-2.0" ]
2
2022-02-17T01:23:55.000Z
2022-02-17T08:51:57.000Z
# Copyright 2020 The TEMPO Collaboration # # 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...
35.8175
79
0.520346
from typing import Callable, Dict, Optional, Tuple from copy import copy from numpy import ndarray, moveaxis, dot from oqupy import operators from oqupy.config import TEMPO_BACKEND_CONFIG from oqupy.backends import node_array as na from oqupy.util import create_delta class BaseTempoBackend: def __i...
true
true
f71988f8e6cbe49da433af143788c3ecc8e82b65
446
py
Python
setup.py
Moomoo-pls/NLP_Game_of_Life
afe6bb6ccd4a83b6ffeccc8ac257872251bd39bb
[ "MIT" ]
null
null
null
setup.py
Moomoo-pls/NLP_Game_of_Life
afe6bb6ccd4a83b6ffeccc8ac257872251bd39bb
[ "MIT" ]
null
null
null
setup.py
Moomoo-pls/NLP_Game_of_Life
afe6bb6ccd4a83b6ffeccc8ac257872251bd39bb
[ "MIT" ]
null
null
null
import setuptools setuptools.setup( name="Moo_NLP_Game_of_Life", version="1.0.0", author="Stephen Moo-Young", author_email="mooyoung12@gmail.com", description="Game of Life for the take home coding challenge", url="https://github.com/Moomoo-pls/NLP_Game_of_Life", packages=setuptools.find_pa...
27.875
66
0.663677
import setuptools setuptools.setup( name="Moo_NLP_Game_of_Life", version="1.0.0", author="Stephen Moo-Young", author_email="mooyoung12@gmail.com", description="Game of Life for the take home coding challenge", url="https://github.com/Moomoo-pls/NLP_Game_of_Life", packages=setuptools.find_pa...
true
true
f719891884a715f4ed60d4d29e0a80d1b2c17515
8,422
py
Python
2_data_collection/CIFAR_10/vgg16_CIFAR10.py
j-chan-hkust/deep_testing_of_advanced_learning_systems
ec535e2b4dc489d407b664a138d3f5262b71d21e
[ "MIT" ]
null
null
null
2_data_collection/CIFAR_10/vgg16_CIFAR10.py
j-chan-hkust/deep_testing_of_advanced_learning_systems
ec535e2b4dc489d407b664a138d3f5262b71d21e
[ "MIT" ]
null
null
null
2_data_collection/CIFAR_10/vgg16_CIFAR10.py
j-chan-hkust/deep_testing_of_advanced_learning_systems
ec535e2b4dc489d407b664a138d3f5262b71d21e
[ "MIT" ]
null
null
null
from __future__ import print_function import keras from keras.datasets import cifar10 from keras.preprocessing.image import ImageDataGenerator from keras.models import Sequential from keras.layers import Dense, Dropout, Activation, Flatten from keras.layers import Conv2D, MaxPooling2D, BatchNormalization from keras imp...
39.172093
120
0.65412
from __future__ import print_function import keras from keras.datasets import cifar10 from keras.preprocessing.image import ImageDataGenerator from keras.models import Sequential from keras.layers import Dense, Dropout, Activation, Flatten from keras.layers import Conv2D, MaxPooling2D, BatchNormalization from keras imp...
true
true
f719892d08f0cb15a072c2fb5acf64d76d3bd3a3
31,288
py
Python
scraps/forcefield_v2.py
kul-group/MAZE-sim
0f85e74bf93f9242a73bcfaa20a593ae966f38fa
[ "MIT" ]
13
2021-03-10T18:40:32.000Z
2022-03-21T20:40:57.000Z
scraps/forcefield_v2.py
kul-group/MAZE-sim
0f85e74bf93f9242a73bcfaa20a593ae966f38fa
[ "MIT" ]
27
2021-01-28T23:18:44.000Z
2021-05-06T19:33:09.000Z
scraps/forcefield_v2.py
kul-group/MAZE-sim
0f85e74bf93f9242a73bcfaa20a593ae966f38fa
[ "MIT" ]
4
2021-03-19T20:46:15.000Z
2022-03-21T20:40:59.000Z
from maze.extra_framework_maker import ExtraFrameworkMaker, ExtraFrameworkAnalyzer from maze.io_zeolite import read_vasp from maze.zeolite import PerfectZeolite, Zeolite from ase.neighborlist import natural_cutoffs, NeighborList import os from pathlib import Path from ase.io import write, read, gromacs, proteindatabank...
46.215657
121
0.685407
from maze.extra_framework_maker import ExtraFrameworkMaker, ExtraFrameworkAnalyzer from maze.io_zeolite import read_vasp from maze.zeolite import PerfectZeolite, Zeolite from ase.neighborlist import natural_cutoffs, NeighborList import os from pathlib import Path from ase.io import write, read, gromacs, proteindatabank...
true
true
f71989a26c51d5d0de8be179c705597a99ff7aea
17,373
py
Python
python/ccxt/async_support/bitbay.py
Richard-L-Johnson/ccxt1
903aa1288694f9192b15d22b945508661bdc8807
[ "MIT" ]
13
2019-01-26T14:41:37.000Z
2022-03-26T03:33:12.000Z
python/ccxt/async_support/bitbay.py
Richard-L-Johnson/ccxt1
903aa1288694f9192b15d22b945508661bdc8807
[ "MIT" ]
17
2018-10-02T04:43:13.000Z
2018-11-01T17:07:37.000Z
python/ccxt/async_support/bitbay.py
Richard-L-Johnson/ccxt1
903aa1288694f9192b15d22b945508661bdc8807
[ "MIT" ]
12
2018-12-24T02:19:02.000Z
2022-03-26T05:04:25.000Z
# -*- coding: utf-8 -*- # PLEASE DO NOT EDIT THIS FILE, IT IS GENERATED AND WILL BE OVERWRITTEN: # https://github.com/ccxt/ccxt/blob/master/CONTRIBUTING.md#how-to-contribute-code from ccxt.async_support.base.exchange import Exchange # ----------------------------------------------------------------------------- try...
50.650146
136
0.476141
rt.base.exchange import Exchange try: basestring except NameError: basestring = str import hashlib import json from ccxt.base.errors import ExchangeError from ccxt.base.errors import AuthenticationError from ccxt.base.errors import InsufficientFunds from ccxt.base.errors import InvalidOrder from ccxt....
true
true
f7198ae184bcaa5b0b938cc560dc8df6ff0d66d1
93,728
py
Python
keras/layers/recurrent.py
Duncanswilson/keras
32aa192548b6b59bf407e583fbd246ba9f5f5676
[ "MIT" ]
1
2017-11-01T19:10:35.000Z
2017-11-01T19:10:35.000Z
keras/layers/recurrent.py
dmaniry/keras
32aa192548b6b59bf407e583fbd246ba9f5f5676
[ "MIT" ]
null
null
null
keras/layers/recurrent.py
dmaniry/keras
32aa192548b6b59bf407e583fbd246ba9f5f5676
[ "MIT" ]
1
2019-02-22T03:06:41.000Z
2019-02-22T03:06:41.000Z
# -*- coding: utf-8 -*- """Recurrent layers and their base classes. """ from __future__ import absolute_import from __future__ import division from __future__ import print_function import numpy as np import warnings from .. import backend as K from .. import activations from .. import initializers from .. import regu...
43.614705
130
0.583998
from __future__ import absolute_import from __future__ import division from __future__ import print_function import numpy as np import warnings from .. import backend as K from .. import activations from .. import initializers from .. import regularizers from .. import constraints from ..engine import Layer from ..e...
true
true
f7198b1249cfc281e7acad93f4e91961e055e201
13,206
py
Python
mirage/libs/ble_utils/scapy_btlejack_layers.py
HomeSen/mirage
6beb4df508758bd152f5d929ba3e6353f161ef27
[ "MIT" ]
null
null
null
mirage/libs/ble_utils/scapy_btlejack_layers.py
HomeSen/mirage
6beb4df508758bd152f5d929ba3e6353f161ef27
[ "MIT" ]
null
null
null
mirage/libs/ble_utils/scapy_btlejack_layers.py
HomeSen/mirage
6beb4df508758bd152f5d929ba3e6353f161ef27
[ "MIT" ]
null
null
null
from scapy.all import * ''' This module contains some scapy definitions for communicating with a BTLEJack device. ''' BTLEJACK_PACKETS_TYPES = { 0x1 : "command", 0x2 : "response", 0x4 : "notification" } BTLEJACK_PACKETS_OPCODES = { 0x1 : "version", 0x2 : "reset", 0x3 : "scan_access_address...
35.5
126
0.783659
from scapy.all import * BTLEJACK_PACKETS_TYPES = { 0x1 : "command", 0x2 : "response", 0x4 : "notification" } BTLEJACK_PACKETS_OPCODES = { 0x1 : "version", 0x2 : "reset", 0x3 : "scan_access_address", 0x4 : "recover", 0x5 : "recover_channel_map", 0x6 : "recover_hop_interval", ...
true
true
f7198b76ba36f1f12ec60d6aea9e6f66c8d175da
7,421
py
Python
backend/server/models.py
thunderlink/thunderfish
a600021187a50bb078d9c36306564470cc6e9fd8
[ "MIT" ]
3
2019-04-18T04:45:27.000Z
2019-11-06T18:17:29.000Z
backend/server/models.py
thunderlink/thunderfish
a600021187a50bb078d9c36306564470cc6e9fd8
[ "MIT" ]
59
2019-04-22T07:05:52.000Z
2022-03-11T23:48:33.000Z
backend/server/models.py
thunderlink/thunderfish
a600021187a50bb078d9c36306564470cc6e9fd8
[ "MIT" ]
4
2019-04-24T05:49:21.000Z
2019-11-21T00:26:00.000Z
from django.db import models from django.contrib.auth.models import User import re from math import sqrt, pi # Path to default image DEFAULT_IMAGE = '../media/app_logo.png' DEFAULT_PROFILE_IMG = 1 DEFAULT_MEETING_IMG = 2 MEDIA_URL = '/media/' # Unique email for each user User._meta.local_fields[7].__dict__['_unique'] ...
41
229
0.694381
from django.db import models from django.contrib.auth.models import User import re from math import sqrt, pi DEFAULT_IMAGE = '../media/app_logo.png' DEFAULT_PROFILE_IMG = 1 DEFAULT_MEETING_IMG = 2 MEDIA_URL = '/media/' User._meta.local_fields[7].__dict__['_unique'] = True class Image(models.Model): profile = mo...
true
true
f7198bd1b623cee47276165d5348854e67b0535b
45,311
py
Python
pyNastran/dev/bdf_vectorized/cards/dynamic.py
Msegade/pyNastran
ae36548579c6bb2ee3a4fff207f7211c1986a5ab
[ "BSD-3-Clause" ]
null
null
null
pyNastran/dev/bdf_vectorized/cards/dynamic.py
Msegade/pyNastran
ae36548579c6bb2ee3a4fff207f7211c1986a5ab
[ "BSD-3-Clause" ]
null
null
null
pyNastran/dev/bdf_vectorized/cards/dynamic.py
Msegade/pyNastran
ae36548579c6bb2ee3a4fff207f7211c1986a5ab
[ "BSD-3-Clause" ]
1
2020-10-04T19:28:07.000Z
2020-10-04T19:28:07.000Z
# pylint: disable=C0103,R0902,R0904,R0914 """ All dynamic control cards are defined in this file. This includes: * FREQ * FREQ1 * FREQ2 (not implemented) * FREQ3 * FREQ4 * FREQ5 (not implemented) * NLPCI * NLPARM * TSTEP * TSTEPNL All cards are BaseCard objects. """ from math import log, exp, ceil import ...
35.016229
96
0.493809
from math import log, exp, ceil import numpy as np from numpy import unique, hstack from pyNastran.utils.numpy_utils import integer_types from pyNastran.bdf.field_writer_8 import set_blank_if_default from pyNastran.bdf.cards.base_card import BaseCard from pyNastran.bdf.bdf_interface.assign_type import ( integer, ...
true
true
f7198c8a3b00d357347baf407e57a7dd4b984119
620
py
Python
polls/admin.py
Obsinqsob01/polls
52f42029bd76e7a4f1dbdc947c5217ca9e2c0f1d
[ "MIT" ]
null
null
null
polls/admin.py
Obsinqsob01/polls
52f42029bd76e7a4f1dbdc947c5217ca9e2c0f1d
[ "MIT" ]
null
null
null
polls/admin.py
Obsinqsob01/polls
52f42029bd76e7a4f1dbdc947c5217ca9e2c0f1d
[ "MIT" ]
null
null
null
from django.contrib import admin from .models import Choice, Question class ChoiceInline(admin.TabularInline): model = Choice extra = 3 list_display = ('question_text', 'pub_date') class QuestionAdmin(admin.ModelAdmin): list_display = ('question_text', 'pub_date', 'was_published_recently') field...
29.52381
80
0.659677
from django.contrib import admin from .models import Choice, Question class ChoiceInline(admin.TabularInline): model = Choice extra = 3 list_display = ('question_text', 'pub_date') class QuestionAdmin(admin.ModelAdmin): list_display = ('question_text', 'pub_date', 'was_published_recently') field...
true
true
f7198cbf53eb86b681a5ce28880882ab6561e873
706
py
Python
2-add-two-numbers/2-add-two-numbers.py
Atri10/Leet-code---Atri_Patel
49fc59b9147a44ab04a66128fbb2ef259b5f7b7c
[ "MIT" ]
1
2021-10-10T20:21:18.000Z
2021-10-10T20:21:18.000Z
2-add-two-numbers/2-add-two-numbers.py
Atri10/Leet-code---Atri_Patel
49fc59b9147a44ab04a66128fbb2ef259b5f7b7c
[ "MIT" ]
null
null
null
2-add-two-numbers/2-add-two-numbers.py
Atri10/Leet-code---Atri_Patel
49fc59b9147a44ab04a66128fbb2ef259b5f7b7c
[ "MIT" ]
null
null
null
# Definition for singly-linked list. # class ListNode: # def __init__(self, val=0, next=None): # self.val = val # self.next = next class Solution: def addTwoNumbers(self, l1: Optional[ListNode], l2: Optional[ListNode]) -> Optional[ListNode]: n = cur = ListNode(-1) carry ...
27.153846
98
0.441926
class Solution: def addTwoNumbers(self, l1: Optional[ListNode], l2: Optional[ListNode]) -> Optional[ListNode]: n = cur = ListNode(-1) carry = 0 while l1 or l2 or carry: if l1: carry += l1.val l1 = l1.next ...
true
true
f7198d790f74aa6993a89e96a1b3903ca05a53bc
15,654
py
Python
manim/scene/three_d_scene.py
behackl/manim
3759b73d555792d077e1d77c854d5dbe88043b98
[ "MIT" ]
2
2020-11-17T19:00:44.000Z
2021-10-17T16:14:55.000Z
manim/scene/three_d_scene.py
behackl/manim
3759b73d555792d077e1d77c854d5dbe88043b98
[ "MIT" ]
null
null
null
manim/scene/three_d_scene.py
behackl/manim
3759b73d555792d077e1d77c854d5dbe88043b98
[ "MIT" ]
null
null
null
"""A scene suitable for rendering three-dimensional objects and animations.""" __all__ = ["ThreeDScene", "SpecialThreeDScene"] from typing import Iterable, Optional, Sequence, Union import numpy as np from .. import config from ..animation.animation import Animation from ..animation.transform import ApplyMethod fr...
35.986207
100
0.622972
__all__ = ["ThreeDScene", "SpecialThreeDScene"] from typing import Iterable, Optional, Sequence, Union import numpy as np from .. import config from ..animation.animation import Animation from ..animation.transform import ApplyMethod from ..camera.three_d_camera import ThreeDCamera from ..constants import DEGREES ...
true
true
f7198e330d6123f84319f87eb566ae8978c38f58
7,124
py
Python
corehq/apps/reports/urls.py
dimagilg/commcare-hq
ea1786238eae556bb7f1cbd8d2460171af1b619c
[ "BSD-3-Clause" ]
1
2020-07-14T13:00:23.000Z
2020-07-14T13:00:23.000Z
corehq/apps/reports/urls.py
dimagilg/commcare-hq
ea1786238eae556bb7f1cbd8d2460171af1b619c
[ "BSD-3-Clause" ]
94
2020-12-11T06:57:31.000Z
2022-03-15T10:24:06.000Z
corehq/apps/reports/urls.py
dimagilg/commcare-hq
ea1786238eae556bb7f1cbd8d2460171af1b619c
[ "BSD-3-Clause" ]
null
null
null
import logging from django.conf.urls import include, url from django.core.exceptions import ImproperlyConfigured from corehq.apps.reports.standard.forms.reports import ReprocessXFormErrorView from corehq.apps.userreports.reports.view import ( ConfigurableReportView, CustomConfigurableReportDispatcher, ) from ...
44.525
114
0.701291
import logging from django.conf.urls import include, url from django.core.exceptions import ImproperlyConfigured from corehq.apps.reports.standard.forms.reports import ReprocessXFormErrorView from corehq.apps.userreports.reports.view import ( ConfigurableReportView, CustomConfigurableReportDispatcher, ) from ...
true
true
f7198e35f24a43baae21005438b0076176ee416a
561
py
Python
oving_8_c.py
W3OP/Oving_9_round2
090cbc3b135840914659d50c6fa48ab756e5449e
[ "MIT" ]
null
null
null
oving_8_c.py
W3OP/Oving_9_round2
090cbc3b135840914659d50c6fa48ab756e5449e
[ "MIT" ]
null
null
null
oving_8_c.py
W3OP/Oving_9_round2
090cbc3b135840914659d50c6fa48ab756e5449e
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """ Created on Fri Oct 22 10:13:37 2021 @author: palme """ import oving_8_b as o8b test = o8b.Quiz("Hvor mange bein har en hest", [1, 2, 3, 4],4) print(test) dude = int(input("Svar: ")) svar1 = test.svaret(dude) if svar1: print("Svaret er rett") else: print("Svaret er feil") print...
15.162162
77
0.611408
import oving_8_b as o8b test = o8b.Quiz("Hvor mange bein har en hest", [1, 2, 3, 4],4) print(test) dude = int(input("Svar: ")) svar1 = test.svaret(dude) if svar1: print("Svaret er rett") else: print("Svaret er feil") print("\n \n") test2 = o8b.Quiz("Hvilket land er i i nå?", ["norge", "sverie", "danmar...
true
true
f7198ec98548e880b167ef7ccfc9be00d9b58137
5,121
py
Python
zipkin/binding/pyramid/pyramidhook.py
Themimitoof/python-zipkin
f91169d044a49f641930bdfc456f34e497690fe8
[ "Apache-2.0" ]
null
null
null
zipkin/binding/pyramid/pyramidhook.py
Themimitoof/python-zipkin
f91169d044a49f641930bdfc456f34e497690fe8
[ "Apache-2.0" ]
null
null
null
zipkin/binding/pyramid/pyramidhook.py
Themimitoof/python-zipkin
f91169d044a49f641930bdfc456f34e497690fe8
[ "Apache-2.0" ]
null
null
null
from __future__ import absolute_import import time import logging from pyramid.tweens import INGRESS from pyramid.settings import aslist from zipkin import local from zipkin.api import stack_trace from zipkin.models import Trace, Annotation from zipkin.util import int_or_none from zipkin.client import log as zipkin_l...
32.617834
101
0.641672
from __future__ import absolute_import import time import logging from pyramid.tweens import INGRESS from pyramid.settings import aslist from zipkin import local from zipkin.api import stack_trace from zipkin.models import Trace, Annotation from zipkin.util import int_or_none from zipkin.client import log as zipkin_l...
true
true
f7198ece6a41b7a5f0f2edead87cf05f2c1c0cd4
10,093
py
Python
sdks/python/http_client/v1/polyaxon_sdk/models/v1_bayes.py
onilton/polyaxon
3b0d7cbeead74e62eb0eedbb2962f605ebb9fa81
[ "Apache-2.0" ]
null
null
null
sdks/python/http_client/v1/polyaxon_sdk/models/v1_bayes.py
onilton/polyaxon
3b0d7cbeead74e62eb0eedbb2962f605ebb9fa81
[ "Apache-2.0" ]
null
null
null
sdks/python/http_client/v1/polyaxon_sdk/models/v1_bayes.py
onilton/polyaxon
3b0d7cbeead74e62eb0eedbb2962f605ebb9fa81
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/python # # Copyright 2018-2021 Polyaxon, 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 ...
27.13172
237
0.593382
import pprint import re import six from polyaxon_sdk.configuration import Configuration class V1Bayes(object): openapi_types = { 'kind': 'str', 'params': 'dict(str, object)', 'num_initial_runs': 'int', 'max_iterations': 'int', 'utility_function': 'o...
true
true
f7198f349b0048d3b6330725d65dfdf36b553ff4
1,458
py
Python
soltrannet/__init__.py
hengwei-chan/molecular_attention_transformer
29193d4155df528e3a6a0c1e0da39111d0b8db93
[ "Apache-2.0" ]
16
2021-03-10T17:10:06.000Z
2022-03-16T13:07:58.000Z
soltrannet/__init__.py
hengwei-chan/molecular_attention_transformer
29193d4155df528e3a6a0c1e0da39111d0b8db93
[ "Apache-2.0" ]
null
null
null
soltrannet/__init__.py
hengwei-chan/molecular_attention_transformer
29193d4155df528e3a6a0c1e0da39111d0b8db93
[ "Apache-2.0" ]
10
2021-06-01T03:36:08.000Z
2022-03-18T16:58:25.000Z
from .predict import predict import argparse import sys, multiprocessing import torch def _parse_args(): parser=argparse.ArgumentParser(description="Run SolTranNet aqueous solubility predictor") parser.add_argument('input',nargs='?',type=argparse.FileType('r'),default=sys.stdin,help='PATH to the file containi...
52.071429
199
0.739369
from .predict import predict import argparse import sys, multiprocessing import torch def _parse_args(): parser=argparse.ArgumentParser(description="Run SolTranNet aqueous solubility predictor") parser.add_argument('input',nargs='?',type=argparse.FileType('r'),default=sys.stdin,help='PATH to the file containi...
true
true
f7198f927dcfc0aeb6186a86d48263d8c4b1d8eb
5,831
py
Python
src/garage/torch/algos/_utils.py
adibellathur/garage
8394f0cf2b77c0a5b3a7b1ea977fa6cb3f9df0ca
[ "MIT" ]
1
2020-02-19T00:01:29.000Z
2020-02-19T00:01:29.000Z
src/garage/torch/algos/_utils.py
Ashutosh-Adhikari/garage
482a26a07d46091f878c41b582f1478588e397ff
[ "MIT" ]
null
null
null
src/garage/torch/algos/_utils.py
Ashutosh-Adhikari/garage
482a26a07d46091f878c41b582f1478588e397ff
[ "MIT" ]
1
2020-02-13T12:05:35.000Z
2020-02-13T12:05:35.000Z
"""Utility functions used by PyTorch algorithms.""" import torch import torch.nn.functional as F class _Default: # pylint: disable=too-few-public-methods """A wrapper class to represent default arguments. Args: val (object): Argument value. """ def __init__(self, val): self.val = v...
35.993827
79
0.630081
import torch import torch.nn.functional as F class _Default: def __init__(self, val): self.val = val def make_optimizer(optimizer_type, module, **kwargs): if isinstance(optimizer_type, tuple): opt_type, opt_args = optimizer_type for name, arg in kwargs.items(): if not ...
true
true
f7198f9535491c7521d5ae47ee77aaa8910d0441
801
py
Python
tests/test_export_id.py
David-Le-Nir/sphinxcontrib-needs
fe809445505fa1e9bf5963eab1d6283dad405e92
[ "MIT" ]
null
null
null
tests/test_export_id.py
David-Le-Nir/sphinxcontrib-needs
fe809445505fa1e9bf5963eab1d6283dad405e92
[ "MIT" ]
2
2022-02-13T19:49:18.000Z
2022-02-13T19:49:18.000Z
tests/test_export_id.py
David-Le-Nir/sphinxcontrib-needs
fe809445505fa1e9bf5963eab1d6283dad405e92
[ "MIT" ]
null
null
null
import json import os from pathlib import Path from sphinx_testing import with_app @with_app(buildername="needs", srcdir="doc_test/doc_export_id") def test_export_id(app, status, warning): app.build() content = Path(app.outdir, "needs.json").read_text() assert "filters" in content content_obj = json...
30.807692
69
0.716604
import json import os from pathlib import Path from sphinx_testing import with_app @with_app(buildername="needs", srcdir="doc_test/doc_export_id") def test_export_id(app, status, warning): app.build() content = Path(app.outdir, "needs.json").read_text() assert "filters" in content content_obj = json...
true
true
f719907ff48a40bf779cf6020839f0d298c921ad
7,308
py
Python
wavedata/tools/core/voxel_grid_2d.py
amuamushu/wavedata
1745c646ff3a76b38a81c439a0edd900c986c9f7
[ "MIT" ]
null
null
null
wavedata/tools/core/voxel_grid_2d.py
amuamushu/wavedata
1745c646ff3a76b38a81c439a0edd900c986c9f7
[ "MIT" ]
null
null
null
wavedata/tools/core/voxel_grid_2d.py
amuamushu/wavedata
1745c646ff3a76b38a81c439a0edd900c986c9f7
[ "MIT" ]
null
null
null
import numpy as np from wavedata.wavedata.tools.core import geometry_utils class VoxelGrid2D(object): """ Voxel grids represent occupancy info. The voxelize_2d method projects a point cloud onto a plane, while saving height and point density information for each voxel. """ # Class Constants ...
39.080214
87
0.601122
import numpy as np from wavedata.wavedata.tools.core import geometry_utils class VoxelGrid2D(object): VOXEL_EMPTY = -1 VOXEL_FILLED = 0 def __init__(self): self.voxel_size = 0.0 self.min_voxel_coord = np.array([]) self.max_voxel_coord = np.array([]) ...
true
true
f719919bea61d2bf5cccc3f7d4e1bee9157cfd2e
1,230
py
Python
service/scripts/resetadmin.py
OA-DeepGreen/jper
042719a790a34f877050a32f896b947ce4407b4e
[ "Apache-2.0" ]
null
null
null
service/scripts/resetadmin.py
OA-DeepGreen/jper
042719a790a34f877050a32f896b947ce4407b4e
[ "Apache-2.0" ]
1
2022-02-03T12:35:18.000Z
2022-02-03T12:35:18.000Z
service/scripts/resetadmin.py
OA-DeepGreen/jper
042719a790a34f877050a32f896b947ce4407b4e
[ "Apache-2.0" ]
3
2016-07-15T07:29:33.000Z
2020-02-03T11:20:34.000Z
""" This is a script to reset the admin account in a live system. On production this should be run once, and never again, as it removes the old account and builds a new one in its place. This means no historical data will be kept from the before time. """ from octopus.core import add_configuration, app from servic...
31.538462
139
0.664228
from octopus.core import add_configuration, app from service.models import Account if __name__ == "__main__": import argparse parser = argparse.ArgumentParser() parser.add_argument("-c", "--config", help="additional configuration to load (e.g. for testing)") args = parser.parse_args() if arg...
true
true
f719923795059f5abc5f26d2960058e68c7ca4e6
539
py
Python
game_data/migrations/0003_auto_20210103_1621.py
cmerwin3/Adventure_Project
1816978e952f1250049e8d1e7fcf172620903596
[ "Apache-2.0" ]
null
null
null
game_data/migrations/0003_auto_20210103_1621.py
cmerwin3/Adventure_Project
1816978e952f1250049e8d1e7fcf172620903596
[ "Apache-2.0" ]
null
null
null
game_data/migrations/0003_auto_20210103_1621.py
cmerwin3/Adventure_Project
1816978e952f1250049e8d1e7fcf172620903596
[ "Apache-2.0" ]
null
null
null
# Generated by Django 3.1.1 on 2021-01-03 22:21 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('game_data', '0002_auto_20201220_2025'), ] operations = [ migrations.RemoveField( model_name='gamedata', name='pin', ...
22.458333
61
0.575139
from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('game_data', '0002_auto_20201220_2025'), ] operations = [ migrations.RemoveField( model_name='gamedata', name='pin', ), migrations.AddField( ...
true
true
f719927ab980abbbc3d3ffdce109f65dd7ddd35e
118
py
Python
framework/conf.py
shew91/Retropy
9feb34855b997c48d93a5343a9842788d19582e6
[ "MIT" ]
13
2018-06-02T09:11:15.000Z
2020-08-29T01:01:19.000Z
framework/conf.py
shew91/Retropy
9feb34855b997c48d93a5343a9842788d19582e6
[ "MIT" ]
1
2021-01-17T14:03:13.000Z
2021-01-17T14:03:13.000Z
framework/conf.py
shew91/Retropy
9feb34855b997c48d93a5343a9842788d19582e6
[ "MIT" ]
6
2018-06-02T16:20:47.000Z
2021-12-30T22:26:54.000Z
# (hack) Global configs conf_cache_disk = True conf_cache_memory = True conf_cache_fails = False ignoredAssets = []
14.75
24
0.771186
conf_cache_disk = True conf_cache_memory = True conf_cache_fails = False ignoredAssets = []
true
true
f71992c33b60881673856eebed695c0f089619b3
8,381
py
Python
adwords_python3_examples_10.1.0/v201802/shopping/add_product_partition_tree.py
xyla-io/hazel
260ce906761d8b808c21ca61b44cc71ca3329e8c
[ "MIT" ]
null
null
null
adwords_python3_examples_10.1.0/v201802/shopping/add_product_partition_tree.py
xyla-io/hazel
260ce906761d8b808c21ca61b44cc71ca3329e8c
[ "MIT" ]
null
null
null
adwords_python3_examples_10.1.0/v201802/shopping/add_product_partition_tree.py
xyla-io/hazel
260ce906761d8b808c21ca61b44cc71ca3329e8c
[ "MIT" ]
null
null
null
#!/usr/bin/env python # # Copyright 2016 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless requir...
29.932143
79
0.681064
from googleads import adwords ADGROUP_ID = 'INSERT_AD_GROUP_ID_HERE' class ProductPartitionHelper(object): def __init__(self, adgroup_id): self.next_id = -1 self.operations = [] self.adgroup_id = adgroup_id def CreateSubdivision(self, ...
true
true
f71992ce83b2d3db02c5c551a3d398f75815bd4c
1,118
py
Python
tests/test_integration.py
vadim2404/pybox
3c4686245dca3d58afa5b923bcfede2172436bfd
[ "MIT" ]
null
null
null
tests/test_integration.py
vadim2404/pybox
3c4686245dca3d58afa5b923bcfede2172436bfd
[ "MIT" ]
null
null
null
tests/test_integration.py
vadim2404/pybox
3c4686245dca3d58afa5b923bcfede2172436bfd
[ "MIT" ]
null
null
null
from pybox.inject import Inject, InjectLazy from pybox.service import IService, ServiceMode class SingletonService(IService): def who_am_i(self): print(f'Singleton {id(self)}') class FactoryService(IService): singleton = Inject(SingletonService) @classmethod def service_mode(self): ...
23.787234
53
0.701252
from pybox.inject import Inject, InjectLazy from pybox.service import IService, ServiceMode class SingletonService(IService): def who_am_i(self): print(f'Singleton {id(self)}') class FactoryService(IService): singleton = Inject(SingletonService) @classmethod def service_mode(self): ...
true
true
f719931b5d6abfb3ad9bbf8bcd7dabd34ac4e957
1,023
py
Python
stacked_queue/stack_queue.py
steveflys/data-structures-and-algorithms
9c89cb24449ca7bc09578408cba3c877fe74e000
[ "MIT" ]
null
null
null
stacked_queue/stack_queue.py
steveflys/data-structures-and-algorithms
9c89cb24449ca7bc09578408cba3c877fe74e000
[ "MIT" ]
3
2018-05-01T18:07:50.000Z
2018-05-11T16:52:16.000Z
stacked_queue/stack_queue.py
steveflys/data-structures-and-algorithms
9c89cb24449ca7bc09578408cba3c877fe74e000
[ "MIT" ]
null
null
null
from .node import Node from .stack import Stack class Stack_Queue: def __init__(self): self.stack_front = Stack() self.stack_back = Stack() self._size = 0 def enqueue(self, val): """This will add a node the back of the queue and increment the ._size""" try: ...
25.575
98
0.605083
from .node import Node from .stack import Stack class Stack_Queue: def __init__(self): self.stack_front = Stack() self.stack_back = Stack() self._size = 0 def enqueue(self, val): try: node = Node(val) except TypeError: raise TypeError('Cannot en...
true
true
f7199346c4d451ef333dfac98139b138cfe947b2
1,924
py
Python
_discord.py
blairg23/discord-scheduler-bot
bd6bcc25b51b50c9eeca195adefe5cfc2eab4923
[ "MIT" ]
null
null
null
_discord.py
blairg23/discord-scheduler-bot
bd6bcc25b51b50c9eeca195adefe5cfc2eab4923
[ "MIT" ]
null
null
null
_discord.py
blairg23/discord-scheduler-bot
bd6bcc25b51b50c9eeca195adefe5cfc2eab4923
[ "MIT" ]
null
null
null
import discord import asyncio from datetime import datetime class Discord: _instance = None client = None def __new__(class_, *args, **kwargs): if not isinstance(class_._instance, class_): class_._instance = object.__new__(class_, *args, **kwargs) return class_._instance d...
34.357143
118
0.576403
import discord import asyncio from datetime import datetime class Discord: _instance = None client = None def __new__(class_, *args, **kwargs): if not isinstance(class_._instance, class_): class_._instance = object.__new__(class_, *args, **kwargs) return class_._instance d...
true
true
f719938d7b8a9a714e3e8d344249a6a2588ede43
3,085
py
Python
src/app/routes.py
taishengG/jama-slack-integration
746b7186ceaf955ca81e9e0ad4862141ce35eb8d
[ "MIT" ]
null
null
null
src/app/routes.py
taishengG/jama-slack-integration
746b7186ceaf955ca81e9e0ad4862141ce35eb8d
[ "MIT" ]
null
null
null
src/app/routes.py
taishengG/jama-slack-integration
746b7186ceaf955ca81e9e0ad4862141ce35eb8d
[ "MIT" ]
null
null
null
import os import requests import json from flask import request, make_response from app import app from app import route_handler as rt_handle """ This module handles the "intake" of requests to the server. The requests are then passed off the route_handler.py where arguments are then parsed and passed off to other pa...
24.879032
72
0.666775
import os import requests import json from flask import request, make_response from app import app from app import route_handler as rt_handle base_url = os.environ['JAMA_URL'] url_rule = os.environ['URL_RULE'] @app.route(url_rule + "/dialog", methods=['GET', 'PUT', 'POST']) def jama_dialog(): if not rt_handle....
true
true
f719944e384288656e4d709f07457f69d21c6a92
1,473
pyw
Python
Tkinter/tk5.pyw
Jav10/Python
b419a86825313b8ee537757079c95f3097f4dbad
[ "MIT" ]
null
null
null
Tkinter/tk5.pyw
Jav10/Python
b419a86825313b8ee537757079c95f3097f4dbad
[ "MIT" ]
null
null
null
Tkinter/tk5.pyw
Jav10/Python
b419a86825313b8ee537757079c95f3097f4dbad
[ "MIT" ]
null
null
null
#GUI con TKinter #Autor: Javier Arturo Hernández Sosa #Fecha: 20/Sep/2017 #Descripcion: Curso Python FES Acatlán from tkinter import * #Definición de funciones def suma(): r.set(x.get() + y.get()) def multi(): r.set(x.get() * y.get()) def resta(): r.set(x.get() - y.get()) def dividir(): r.s...
25.396552
108
0.696538
from tkinter import * def suma(): r.set(x.get() + y.get()) def multi(): r.set(x.get() * y.get()) def resta(): r.set(x.get() - y.get()) def dividir(): r.set(x.get() / y.get()) root = Tk() root.geometry("300x300") root.title("Botones y funciones") root.config(bd=15) x = DoubleVar(...
true
true
f719946d0d254ecdc9ccfe5fb6f0233c8c62eb2a
1,485
py
Python
src/data/dataset.py
zmcx16/ReclassifyAnimeCG
f5f95b229447564502564d9ffc7edf6215fec83d
[ "MIT" ]
3
2021-10-30T10:13:40.000Z
2021-12-12T10:26:14.000Z
src/data/dataset.py
zmcx16/ReclassifyAnimeCG
f5f95b229447564502564d9ffc7edf6215fec83d
[ "MIT" ]
null
null
null
src/data/dataset.py
zmcx16/ReclassifyAnimeCG
f5f95b229447564502564d9ffc7edf6215fec83d
[ "MIT" ]
null
null
null
import torch from torch.utils.data import Dataset, DataLoader import numpy as np from PIL import Image Image.MAX_IMAGE_PIXELS = None from data import get_train_transform, get_test_transform class CustomDataset(Dataset): img_aug = True imgs = [] transform = None def __init__(self, label_file, image_s...
30.9375
90
0.658586
import torch from torch.utils.data import Dataset, DataLoader import numpy as np from PIL import Image Image.MAX_IMAGE_PIXELS = None from data import get_train_transform, get_test_transform class CustomDataset(Dataset): img_aug = True imgs = [] transform = None def __init__(self, label_file, image_s...
true
true
f71994d1600fc241664b82c32779973864dfe5a1
337
py
Python
AHtask2.py
Irinakene/AHtask
6f776477c6867b8f7650394aac1c3292bced8ca9
[ "MIT" ]
null
null
null
AHtask2.py
Irinakene/AHtask
6f776477c6867b8f7650394aac1c3292bced8ca9
[ "MIT" ]
null
null
null
AHtask2.py
Irinakene/AHtask
6f776477c6867b8f7650394aac1c3292bced8ca9
[ "MIT" ]
null
null
null
import csv name = input('Enter your name: ') email = input('Enter your email: ') phone = input('Enter your phone: ') githublink = input('Enter your githublink: ') save = input('Save to CSV? ') if save == 'yes': file = open('results.csv', 'a') csv_writer = csv.writer(file) csv_writer.writerow([name, githublin...
22.466667
54
0.664688
import csv name = input('Enter your name: ') email = input('Enter your email: ') phone = input('Enter your phone: ') githublink = input('Enter your githublink: ') save = input('Save to CSV? ') if save == 'yes': file = open('results.csv', 'a') csv_writer = csv.writer(file) csv_writer.writerow([name, githublin...
true
true
f719957c1c4356a3f8209af000c59c417741c746
8,827
py
Python
parameter_sweep.py
yairchn/SCAMPy
a204b4220d722cf3dbf4e81997f8d2ed7a7324a9
[ "Apache-2.0" ]
1
2018-08-23T21:53:01.000Z
2018-08-23T21:53:01.000Z
parameter_sweep.py
yairchn/SCAMPy
a204b4220d722cf3dbf4e81997f8d2ed7a7324a9
[ "Apache-2.0" ]
1
2019-09-08T03:32:04.000Z
2019-09-08T03:32:04.000Z
parameter_sweep.py
yairchn/SCAMPy
a204b4220d722cf3dbf4e81997f8d2ed7a7324a9
[ "Apache-2.0" ]
1
2018-08-23T21:53:14.000Z
2018-08-23T21:53:14.000Z
import subprocess import argparse import json import pprint from sys import exit import uuid import ast import numpy as np import netCDF4 as nc import os # python parameter_sweep.py case_name def main(): parser = argparse.ArgumentParser(prog='Paramlist Generator') parser.add_argument('case_name') args = pa...
40.865741
124
0.60972
import subprocess import argparse import json import pprint from sys import exit import uuid import ast import numpy as np import netCDF4 as nc import os def main(): parser = argparse.ArgumentParser(prog='Paramlist Generator') parser.add_argument('case_name') args = parser.parse_args() case_name = arg...
false
true
f71997563231cf56306173544d65e6f6f5c14345
27,571
py
Python
sdk/keyvault/azure-keyvault-keys/azure/keyvault/keys/_client.py
ankitarorabit/azure-sdk-for-python
dd90281cbad9400f8080754a5ef2f56791a5a88f
[ "MIT" ]
null
null
null
sdk/keyvault/azure-keyvault-keys/azure/keyvault/keys/_client.py
ankitarorabit/azure-sdk-for-python
dd90281cbad9400f8080754a5ef2f56791a5a88f
[ "MIT" ]
1
2021-05-31T08:56:01.000Z
2021-05-31T08:56:01.000Z
sdk/keyvault/azure-keyvault-keys/azure/keyvault/keys/_client.py
ankitarorabit/azure-sdk-for-python
dd90281cbad9400f8080754a5ef2f56791a5a88f
[ "MIT" ]
null
null
null
# ------------------------------------ # Copyright (c) Microsoft Corporation. # Licensed under the MIT License. # ------------------------------------ from functools import partial from azure.core.tracing.decorator import distributed_trace from ._shared import KeyVaultClientBase from ._shared.exceptions import error_m...
45.875208
120
0.641507
from functools import partial from azure.core.tracing.decorator import distributed_trace from ._shared import KeyVaultClientBase from ._shared.exceptions import error_map as _error_map from ._shared._polling import DeleteRecoverPollingMethod, KeyVaultOperationPoller from ._models import KeyVaultKey, KeyProperties,...
true
true
f7199764cac1f3e56cc1b5f43ff6f14fb40c8601
3,487
py
Python
tests/test_cookies.py
tripsolutions/pyramid_jwt
320ed080216971467ae5e12b1f9888b50a9a29b7
[ "BSD-2-Clause" ]
null
null
null
tests/test_cookies.py
tripsolutions/pyramid_jwt
320ed080216971467ae5e12b1f9888b50a9a29b7
[ "BSD-2-Clause" ]
null
null
null
tests/test_cookies.py
tripsolutions/pyramid_jwt
320ed080216971467ae5e12b1f9888b50a9a29b7
[ "BSD-2-Clause" ]
null
null
null
import uuid import pytest from pyramid.interfaces import IAuthenticationPolicy from webob import Request from zope.interface.verify import verifyObject from pyramid_jwt.policy import JWTCookieAuthenticationPolicy @pytest.fixture(scope="module") def principal(): return str(uuid.uuid4()) def test_interface(): ...
29.058333
88
0.706051
import uuid import pytest from pyramid.interfaces import IAuthenticationPolicy from webob import Request from zope.interface.verify import verifyObject from pyramid_jwt.policy import JWTCookieAuthenticationPolicy @pytest.fixture(scope="module") def principal(): return str(uuid.uuid4()) def test_interface(): ...
true
true
f719982c32746d402b0277ba15a13000bcc77119
94
py
Python
my_classes/.history/ModulesPackages_PackageNamespaces/example3b/main_20210726185941.py
minefarmer/deep-Dive-1
b0675b853180c5b5781888266ea63a3793b8d855
[ "Unlicense" ]
null
null
null
my_classes/.history/ModulesPackages_PackageNamespaces/example3b/main_20210726185941.py
minefarmer/deep-Dive-1
b0675b853180c5b5781888266ea63a3793b8d855
[ "Unlicense" ]
null
null
null
my_classes/.history/ModulesPackages_PackageNamespaces/example3b/main_20210726185941.py
minefarmer/deep-Dive-1
b0675b853180c5b5781888266ea63a3793b8d855
[ "Unlicense" ]
null
null
null
import sys import importer module1 = importer.import_('module1', 'module1_source.py', '.')
13.428571
63
0.723404
import sys import importer module1 = importer.import_('module1', 'module1_source.py', '.')
true
true
f719994b12c769c14062f52ec104eb9f369ef914
757
py
Python
Exercicios Loop/exercicio 35 - secao 06.py
cristinamais/exercicios_python
8a09b0b68ffaa62d13afb952998e890a79667c7e
[ "MIT" ]
null
null
null
Exercicios Loop/exercicio 35 - secao 06.py
cristinamais/exercicios_python
8a09b0b68ffaa62d13afb952998e890a79667c7e
[ "MIT" ]
null
null
null
Exercicios Loop/exercicio 35 - secao 06.py
cristinamais/exercicios_python
8a09b0b68ffaa62d13afb952998e890a79667c7e
[ "MIT" ]
null
null
null
""" 35 - Faça um programa que some os números impares contidos em um intervalo definido pelo usuário. O usuário define o valor inicial do intervalo e o valor final deste intervalo e o programa deve somar todos os números ímpares contidos neste intervalo (começando por um valor maior que o valor final) deve ser escrito ...
42.055556
104
0.73712
impar = 0 inicial, final = [int(x) for x in input("Digite o valor inicial e valor final: ").split()] for i in list(range(inicial, final)): if i % 2 != 0: impar = impar + i print(f'A soma dos ímpares neste intervalo é {impar}')
true
true
f71999d547a46a0a1493f4a1de55c28d65419f04
421
py
Python
strava/cli/activity/commands.py
dparret/strava-cli
2426ea7f3fe4580aea352476b261cec31d3f0b11
[ "MIT" ]
null
null
null
strava/cli/activity/commands.py
dparret/strava-cli
2426ea7f3fe4580aea352476b261cec31d3f0b11
[ "MIT" ]
null
null
null
strava/cli/activity/commands.py
dparret/strava-cli
2426ea7f3fe4580aea352476b261cec31d3f0b11
[ "MIT" ]
null
null
null
import click from strava.commands import get_activity, get_constrain_activity, get_weekly_activity, get_lap_activity @click.group(name='activity', help='[GROUP] Get the summary of one or multiple activities.') def cli_activity(): pass cli_activity.add_command(get_activity) cli_activity.add_command(get_constrai...
28.066667
103
0.83848
import click from strava.commands import get_activity, get_constrain_activity, get_weekly_activity, get_lap_activity @click.group(name='activity', help='[GROUP] Get the summary of one or multiple activities.') def cli_activity(): pass cli_activity.add_command(get_activity) cli_activity.add_command(get_constrai...
true
true
f7199aebd95eaaf673576198d3754ac18ebe3786
4,928
py
Python
3.Netdata_package/zipcontents/bin/netdata/usr/libexec/netdata/python.d/cpuidle.chart.py
NordicID/ar8x_samples
2ac78750d6f4ff924628d1e225990f4bfcecfda0
[ "MIT" ]
4
2017-10-17T13:28:28.000Z
2020-12-23T09:46:10.000Z
3.Netdata_package/zipcontents/bin/netdata/usr/libexec/netdata/python.d/cpuidle.chart.py
NordicID/ar8x_samples
2ac78750d6f4ff924628d1e225990f4bfcecfda0
[ "MIT" ]
8
2019-02-09T15:29:12.000Z
2021-03-15T17:45:49.000Z
3.Netdata_package/zipcontents/bin/netdata/usr/libexec/netdata/python.d/cpuidle.chart.py
NordicID/ar8x_samples
2ac78750d6f4ff924628d1e225990f4bfcecfda0
[ "MIT" ]
3
2018-05-24T16:27:43.000Z
2019-08-04T23:39:22.000Z
# -*- coding: utf-8 -*- # Description: cpuidle netdata python.d module # Author: Steven Noonan (tycho) import glob import os import platform import time from base import SimpleService import ctypes syscall = ctypes.CDLL('libc.so.6').syscall # default module values (can be overridden per job in `config`) # update_eve...
34.222222
96
0.565544
import glob import os import platform import time from base import SimpleService import ctypes syscall = ctypes.CDLL('libc.so.6').syscall class Service(SimpleService): def __init__(self, configuration=None, name=None): prefix = os.getenv('NETDATA_HOST_PREFIX', "") if prefix.endswith('/'): ...
true
true
f7199b4c4ff664a5de4259b1a156f514807f75ec
358
py
Python
Ch6/picnic_table.py
dmdinh22/ATBS
3ddd331757cc434faa5f27997b178f8a39e3b5d2
[ "MIT" ]
null
null
null
Ch6/picnic_table.py
dmdinh22/ATBS
3ddd331757cc434faa5f27997b178f8a39e3b5d2
[ "MIT" ]
null
null
null
Ch6/picnic_table.py
dmdinh22/ATBS
3ddd331757cc434faa5f27997b178f8a39e3b5d2
[ "MIT" ]
null
null
null
def print_picnic(itemsDict, leftWidth, rightWidth): print('PICNIC ITEMS'.center(leftWidth + rightWidth, '-')) for k, v in itemsDict.items(): print(k.ljust(leftWidth, '.') + str(v).rjust(rightWidth)) picnic_items = {'sandwiches': 4, 'apples': 12, 'cups': 4, 'cookies': 8000} print_picnic(picnic_items, 12,...
44.75
74
0.684358
def print_picnic(itemsDict, leftWidth, rightWidth): print('PICNIC ITEMS'.center(leftWidth + rightWidth, '-')) for k, v in itemsDict.items(): print(k.ljust(leftWidth, '.') + str(v).rjust(rightWidth)) picnic_items = {'sandwiches': 4, 'apples': 12, 'cups': 4, 'cookies': 8000} print_picnic(picnic_items, 12,...
true
true
f7199b5ab43ce56280af5d2f042fc3bf18ea33f9
241
py
Python
examples/externalpyproc/test.py
scala-steward/prox
fdcab42cbdbe6a1cf4d9ffde796657d75dac6235
[ "Apache-2.0" ]
95
2018-01-19T00:09:22.000Z
2022-02-05T15:22:59.000Z
examples/externalpyproc/test.py
scala-steward/prox
fdcab42cbdbe6a1cf4d9ffde796657d75dac6235
[ "Apache-2.0" ]
312
2017-11-22T19:41:41.000Z
2022-03-30T13:31:06.000Z
examples/externalpyproc/test.py
scala-steward/prox
fdcab42cbdbe6a1cf4d9ffde796657d75dac6235
[ "Apache-2.0" ]
6
2018-05-02T10:30:44.000Z
2020-10-17T17:06:11.000Z
import sys def run(): stop = False while not stop: line = sys.stdin.readline().strip() if len(line) == 0: stop = True else: print line + "!?!?" sys.stdout.flush() run()
15.0625
43
0.452282
import sys def run(): stop = False while not stop: line = sys.stdin.readline().strip() if len(line) == 0: stop = True else: print line + "!?!?" sys.stdout.flush() run()
false
true
f7199b6017b06f096a888ac161723abab17bf6d1
80
py
Python
notebooks/_solutions/13-raster-processing42.py
jorisvandenbossche/DS-python-geospatial
893a12edc5c203a75815f6dcb5f1e18c577c8cd5
[ "BSD-3-Clause" ]
58
2020-10-09T10:10:59.000Z
2022-03-07T14:58:07.000Z
notebooks/_solutions/13-raster-processing42.py
jorisvandenbossche/DS-python-geospatial
893a12edc5c203a75815f6dcb5f1e18c577c8cd5
[ "BSD-3-Clause" ]
24
2020-09-30T19:57:14.000Z
2021-10-05T07:21:09.000Z
notebooks/_solutions/13-raster-processing42.py
jorisvandenbossche/DS-python-geospatial
893a12edc5c203a75815f6dcb5f1e18c577c8cd5
[ "BSD-3-Clause" ]
19
2020-10-05T09:32:18.000Z
2022-03-20T00:09:14.000Z
green = geopandas.read_file("data/gent/vector/parken-gent.geojson") green.head()
40
67
0.7875
green = geopandas.read_file("data/gent/vector/parken-gent.geojson") green.head()
true
true
f7199bd2f937de5095eb9d5c4cafe386b70039eb
1,325
py
Python
kale/util/ints.py
inan0812/kale-blockchain
1b502fe21a4be10b4db0171c3a7030079dcefa1b
[ "Apache-2.0" ]
null
null
null
kale/util/ints.py
inan0812/kale-blockchain
1b502fe21a4be10b4db0171c3a7030079dcefa1b
[ "Apache-2.0" ]
null
null
null
kale/util/ints.py
inan0812/kale-blockchain
1b502fe21a4be10b4db0171c3a7030079dcefa1b
[ "Apache-2.0" ]
null
null
null
from typing import Any, BinaryIO from kale.util.struct_stream import StructStream class int8(StructStream): PACK = "!b" class uint8(StructStream): PACK = "!B" class int16(StructStream): PACK = "!h" class uint16(StructStream): PACK = "!H" class int32(StructStream): PACK = "!l" class uint...
20.384615
61
0.577358
from typing import Any, BinaryIO from kale.util.struct_stream import StructStream class int8(StructStream): PACK = "!b" class uint8(StructStream): PACK = "!B" class int16(StructStream): PACK = "!h" class uint16(StructStream): PACK = "!H" class int32(StructStream): PACK = "!l" class uint...
true
true
f7199cc541ada1d15fae75b62fc319d80df9c669
428
py
Python
src/upload/admin.py
bpilkerton/vendor-upload
ba43b620340c9fffd26cf6a8ee5bc9f97ffabda1
[ "Unlicense" ]
null
null
null
src/upload/admin.py
bpilkerton/vendor-upload
ba43b620340c9fffd26cf6a8ee5bc9f97ffabda1
[ "Unlicense" ]
null
null
null
src/upload/admin.py
bpilkerton/vendor-upload
ba43b620340c9fffd26cf6a8ee5bc9f97ffabda1
[ "Unlicense" ]
null
null
null
from django.contrib import admin from .models import Upload,VendorData class UploadAdmin(admin.ModelAdmin): list_display = ('id','uploaded_file','uploaded_date') class VendordataAdmin(admin.ModelAdmin): list_display = ('id','sub_id','first_name','last_name','status') admin.site.site_header = "Subscription Fu...
32.923077
68
0.785047
from django.contrib import admin from .models import Upload,VendorData class UploadAdmin(admin.ModelAdmin): list_display = ('id','uploaded_file','uploaded_date') class VendordataAdmin(admin.ModelAdmin): list_display = ('id','sub_id','first_name','last_name','status') admin.site.site_header = "Subscription Fu...
true
true
f7199d3d3a6e51cfe86975c9d26b03a1bb377073
228
py
Python
Django Rest Class Based API view/Person/admin.py
abhisheksahu92/Django-Rest-Framework
45ddafb93ed1f2e232d2f537f144bf79cb30bf3d
[ "MIT" ]
null
null
null
Django Rest Class Based API view/Person/admin.py
abhisheksahu92/Django-Rest-Framework
45ddafb93ed1f2e232d2f537f144bf79cb30bf3d
[ "MIT" ]
null
null
null
Django Rest Class Based API view/Person/admin.py
abhisheksahu92/Django-Rest-Framework
45ddafb93ed1f2e232d2f537f144bf79cb30bf3d
[ "MIT" ]
null
null
null
from django.contrib import admin from .models import Person # Register your models here. @admin.register(Person) class PersonModel(admin.ModelAdmin): list_display = ['first_name','last_name','email','phone','date_of_birth']
32.571429
77
0.77193
from django.contrib import admin from .models import Person @admin.register(Person) class PersonModel(admin.ModelAdmin): list_display = ['first_name','last_name','email','phone','date_of_birth']
true
true
f7199de7d432eb5ce623737f74e8d53b751b22d7
9,267
py
Python
ckan/views/admin.py
robin-NEC/ckan
71a82c4b0bb499fd3a6d1ccfd038b2231f50f92a
[ "BSD-3-Clause" ]
1
2021-10-01T12:47:19.000Z
2021-10-01T12:47:19.000Z
ckan/views/admin.py
robin-NEC/ckan
71a82c4b0bb499fd3a6d1ccfd038b2231f50f92a
[ "BSD-3-Clause" ]
null
null
null
ckan/views/admin.py
robin-NEC/ckan
71a82c4b0bb499fd3a6d1ccfd038b2231f50f92a
[ "BSD-3-Clause" ]
2
2018-01-21T17:03:08.000Z
2019-07-23T08:49:52.000Z
# encoding: utf-8 from __future__ import annotations import logging from typing import Any, Union, cast, List from flask import Blueprint from flask.views import MethodView from flask.wrappers import Response import ckan.lib.app_globals as app_globals import ckan.lib.base as base import ckan.lib.helpers as h import ...
33.698182
79
0.589403
from __future__ import annotations import logging from typing import Any, Union, cast, List from flask import Blueprint from flask.views import MethodView from flask.wrappers import Response import ckan.lib.app_globals as app_globals import ckan.lib.base as base import ckan.lib.helpers as h import ckan.lib.navl.dic...
true
true
f7199e3af009f350705cd13527301b007761a105
2,956
py
Python
examples/interface/CP.py
jeffhammond/Elemental
a9e6236ce9d92dd56c7d3cd5ffd52f796a35cd0c
[ "Apache-2.0" ]
null
null
null
examples/interface/CP.py
jeffhammond/Elemental
a9e6236ce9d92dd56c7d3cd5ffd52f796a35cd0c
[ "Apache-2.0" ]
null
null
null
examples/interface/CP.py
jeffhammond/Elemental
a9e6236ce9d92dd56c7d3cd5ffd52f796a35cd0c
[ "Apache-2.0" ]
null
null
null
# # Copyright (c) 2009-2016, Jack Poulson # All rights reserved. # # This file is part of Elemental and is under the BSD 2-Clause License, # which can be found in the LICENSE file in the root directory, or at # http://opensource.org/licenses/BSD-2-Clause # import El n0 = 50 n1 = 50 display = False worldRank = E...
25.704348
73
0.609269
import El n0 = 50 n1 = 50 display = False worldRank = El.mpi.WorldRank() worldSize = El.mpi.WorldSize() def StackedFD2D(N0,N1): A = El.DistSparseMatrix() height = 2*N0*N1 width = N0*N1 A.Resize(height,width) localHeight = A.LocalHeight() A.Reserve(6*localHeight) for sLoc in xrange(localHeight)...
false
true
f7199e876ff568e200ceb2dbf17c8e228d670c71
1,919
py
Python
test/Entry.py
EmanueleCannizzaro/scons
6baa4e65cdf4df6951473545b69435711864e509
[ "MIT" ]
1
2019-09-18T06:37:02.000Z
2019-09-18T06:37:02.000Z
test/Entry.py
EmanueleCannizzaro/scons
6baa4e65cdf4df6951473545b69435711864e509
[ "MIT" ]
null
null
null
test/Entry.py
EmanueleCannizzaro/scons
6baa4e65cdf4df6951473545b69435711864e509
[ "MIT" ]
null
null
null
#!/usr/bin/env python # # Copyright (c) 2001 - 2016 The SCons Foundation # # 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 us...
29.523077
87
0.738927
__revision__ = "test/Entry.py rel_2.5.1:3735:9dc6cee5c168 2016/11/03 14:02:02 bdbaddog" import TestSCons test = TestSCons.TestSCons() test.write('SConstruct', """ env = Environment(FOO = 'fff', BAR = 'bbb') print Entry('ddd') print Entry('$FOO') print Entry('${BAR}_$BAR') print env.Entry('ee...
true
true
f719a19921e0717fd82f09f6ab40bd54a1718ceb
18,564
py
Python
sciencebeam_parser/models/model.py
elifesciences/sciencebeam-parser
66964f283612b8d6fa8a23ad8790292c1ec07651
[ "MIT" ]
13
2021-08-04T12:11:17.000Z
2022-03-28T20:41:20.000Z
sciencebeam_parser/models/model.py
elifesciences/sciencebeam-parser
66964f283612b8d6fa8a23ad8790292c1ec07651
[ "MIT" ]
33
2021-08-05T08:37:59.000Z
2022-03-29T18:42:09.000Z
sciencebeam_parser/models/model.py
elifesciences/sciencebeam-parser
66964f283612b8d6fa8a23ad8790292c1ec07651
[ "MIT" ]
1
2022-01-05T14:53:06.000Z
2022-01-05T14:53:06.000Z
import logging from abc import ABC, abstractmethod from collections import defaultdict from dataclasses import dataclass, field from typing import ( Callable, Dict, Iterable, List, NamedTuple, Optional, Sequence, Set, Tuple, TypeVar, Union ) from sciencebeam_trainer_delft.se...
37.053892
96
0.652823
import logging from abc import ABC, abstractmethod from collections import defaultdict from dataclasses import dataclass, field from typing import ( Callable, Dict, Iterable, List, NamedTuple, Optional, Sequence, Set, Tuple, TypeVar, Union ) from sciencebeam_trainer_delft.se...
true
true
f719a28a0f454eca48dc84c19a7a003b8073c988
225
py
Python
tests/test_case_files/class_test_1.py
calkerns/dyc
ddc35e6c183137dc30b2a3a2f481098280167bd1
[ "MIT" ]
100
2019-04-04T23:38:20.000Z
2022-03-30T18:14:16.000Z
tests/test_case_files/class_test_1.py
calkerns/dyc
ddc35e6c183137dc30b2a3a2f481098280167bd1
[ "MIT" ]
51
2019-04-04T20:18:47.000Z
2021-10-05T17:17:20.000Z
tests/test_case_files/class_test_1.py
calkerns/dyc
ddc35e6c183137dc30b2a3a2f481098280167bd1
[ "MIT" ]
63
2019-04-04T20:38:57.000Z
2021-05-25T02:23:16.000Z
class MyClass: x = 1 class MyClass1(Parent1): y = 1 class MyClass2(Parent1, Parent2): z = 1 class MyClass3(Parent1): a = 1 class MyClass4(Parent1, Parent2): b = 1
10.714286
41
0.515556
class MyClass: x = 1 class MyClass1(Parent1): y = 1 class MyClass2(Parent1, Parent2): z = 1 class MyClass3(Parent1): a = 1 class MyClass4(Parent1, Parent2): b = 1
true
true
f719a460ed4a51e9b13467d22b0a48aecf11f8ca
346
py
Python
students/k3343/laboratory_works/Rolinskiy_Sergey/Laba_1/project_first_app/urls.py
TonikX/ITMO_ICT_-WebProgramming_2020
ba566c1b3ab04585665c69860b713741906935a0
[ "MIT" ]
10
2020-03-20T09:06:12.000Z
2021-07-27T13:06:02.000Z
students/k3343/laboratory_works/Rolinskiy_Sergey/Laba_1/project_first_app/urls.py
TonikX/ITMO_ICT_-WebProgramming_2020
ba566c1b3ab04585665c69860b713741906935a0
[ "MIT" ]
134
2020-03-23T09:47:48.000Z
2022-03-12T01:05:19.000Z
students/k3343/laboratory_works/Rolinskiy_Sergey/Laba_1/project_first_app/urls.py
TonikX/ITMO_ICT_-WebProgramming_2020
ba566c1b3ab04585665c69860b713741906935a0
[ "MIT" ]
71
2020-03-20T12:45:56.000Z
2021-10-31T19:22:25.000Z
from django.urls import path from django.conf.urls import url from project_first_app.views import * urlpatterns = [ path('',main,name='main'), path('createowner/',createowner,name='createowner'), path('login/',log_in,name='login'), path(r'<int:ho_id>',review,name='detail') ] #path(r'getowners/<int:ow_i...
31.454545
56
0.699422
from django.urls import path from django.conf.urls import url from project_first_app.views import * urlpatterns = [ path('',main,name='main'), path('createowner/',createowner,name='createowner'), path('login/',log_in,name='login'), path(r'<int:ho_id>',review,name='detail') ]
true
true
f719a465158b15ac1c1bfd62374aefc6ed61f38a
36,465
py
Python
owslib/iso.py
peterataylor/OWSLib
8c15832da0c27dadfb567929ddd52a7570b7c231
[ "BSD-3-Clause" ]
1
2015-03-16T05:22:04.000Z
2015-03-16T05:22:04.000Z
owslib/iso.py
peterataylor/OWSLib
8c15832da0c27dadfb567929ddd52a7570b7c231
[ "BSD-3-Clause" ]
null
null
null
owslib/iso.py
peterataylor/OWSLib
8c15832da0c27dadfb567929ddd52a7570b7c231
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: ISO-8859-15 -*- # ============================================================================= # Copyright (c) 2009 Tom Kralidis # # Authors : Tom Kralidis <tomkralidis@gmail.com> # Angelos Tzotsos <tzotsos@gmail.com> # # Contact email: tomkralidis@gmail.com # ================================...
47.480469
225
0.604854
from owslib.etree import etree from owslib import util from owslib.namespaces import Namespaces def get_namespaces(): n = Namespaces() ns = n.get_namespaces(["gco","gmd","gml","gml32","gmx","gts","srv","xlink"]) ns[None] = n.get_namespace("gmd") return ns namespaces = get_namespaces() cla...
true
true
f719a47cc5a7d23e73cc98dbe3e60cc827cae0aa
3,057
py
Python
fun.py
Grymlock/Guardian_Bot
0fac4cd37038a46d1d8b6eed3fbb79832bd7abf9
[ "MIT" ]
1
2018-06-22T03:52:49.000Z
2018-06-22T03:52:49.000Z
fun.py
Grymlock/Guardian_Bot
0fac4cd37038a46d1d8b6eed3fbb79832bd7abf9
[ "MIT" ]
null
null
null
fun.py
Grymlock/Guardian_Bot
0fac4cd37038a46d1d8b6eed3fbb79832bd7abf9
[ "MIT" ]
null
null
null
import discord import constants as c from discord.ext import commands import random as r urls=['https://cdn.discordapp.com/attachments/433007901800398858/433047585121501194/maxresdefault.jpg','https://cdn.discordapp.com/attachments/442868510776098818/442879211296915466/9bt3n9w40bp01.jpg','https://cdn.discordapp.com...
44.955882
391
0.615309
import discord import constants as c from discord.ext import commands import random as r urls=['https://cdn.discordapp.com/attachments/433007901800398858/433047585121501194/maxresdefault.jpg','https://cdn.discordapp.com/attachments/442868510776098818/442879211296915466/9bt3n9w40bp01.jpg','https://cdn.discordapp.com...
true
true
f719a5d3a4154a174de4fc3bb0bdc9ef6f49b521
1,012
py
Python
test/schemes/test_qz.py
stormymcstorm/condensa
ee3bf993b0032e5d84aeb3cc7f0ddcdb8d846bd9
[ "Apache-2.0" ]
153
2019-05-29T15:10:38.000Z
2022-03-05T05:20:55.000Z
test/schemes/test_qz.py
rogerxujiang/condensa
c7321e0a362f73eca9349769b341a7dd688ee1b9
[ "Apache-2.0" ]
5
2019-07-11T20:56:38.000Z
2022-03-14T10:12:15.000Z
test/schemes/test_qz.py
rogerxujiang/condensa
c7321e0a362f73eca9349769b341a7dd688ee1b9
[ "Apache-2.0" ]
21
2019-05-30T22:21:54.000Z
2022-03-14T07:06:52.000Z
# Copyright 2019 NVIDIA Corporation # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in wr...
30.666667
74
0.733202
import torch import condensa from condensa import schemes def test_float16(device): scheme = schemes.Quantize(condensa.float16) fc = torch.nn.Linear(100, 10).float().to(device) scheme.pi(fc) assert fc.weight.dtype == torch.float16 scheme.delta(fc) assert fc.weight.dtype == torch...
true
true
f719a5ec02915c2d40aa2c28ddf93147dd695082
6,791
py
Python
objects/CSCG/_3d/forms/standard/base/export/field.py
mathischeap/mifem
3242e253fb01ca205a76568eaac7bbdb99e3f059
[ "MIT" ]
1
2020-10-14T12:48:35.000Z
2020-10-14T12:48:35.000Z
objects/CSCG/_3d/forms/standard/base/export/field.py
mathischeap/mifem
3242e253fb01ca205a76568eaac7bbdb99e3f059
[ "MIT" ]
null
null
null
objects/CSCG/_3d/forms/standard/base/export/field.py
mathischeap/mifem
3242e253fb01ca205a76568eaac7bbdb99e3f059
[ "MIT" ]
null
null
null
"""We want to export the field to some data files. """ from root.config.main import * from screws.freeze.main import FrozenOnly from screws.miscellaneous.timer import check_filename, check_no_splcharacter from scipy.io import savemat class _3dCSC_SF_Export_Field(FrozenOnly): """""" def __init__(self, sf): ...
41.408537
103
0.472684
from root.config.main import * from screws.freeze.main import FrozenOnly from screws.miscellaneous.timer import check_filename, check_no_splcharacter from scipy.io import savemat class _3dCSC_SF_Export_Field(FrozenOnly): def __init__(self, sf): assert '3dCSCG_standard_form' in sf.standard_properties.ta...
true
true
f719a60077cb4b23bbe3c54efafc1d30bc3f8163
3,252
py
Python
config.py
LongKt7/Face_Recognize_Pytorch
baa02e633d379abe1001c8b8acb942617177329c
[ "MIT" ]
1
2019-03-13T16:05:11.000Z
2019-03-13T16:05:11.000Z
config.py
LongKt7/Face_Recognize_Pytorch
baa02e633d379abe1001c8b8acb942617177329c
[ "MIT" ]
null
null
null
config.py
LongKt7/Face_Recognize_Pytorch
baa02e633d379abe1001c8b8acb942617177329c
[ "MIT" ]
1
2019-03-15T09:09:08.000Z
2019-03-15T09:09:08.000Z
from easydict import EasyDict as edict # from pathlib import Path import torch import os from torchvision import transforms as trans from utils.constants import * list_model = ['wget https://www.dropbox.com/s/akktsgxp0n8cwn2/model_mobilefacenet.pth?dl=0 -O model_mobilefacenet.pth', 'wget https://www.dropbox.com/s/kzo52...
47.823529
119
0.634071
from easydict import EasyDict as edict import torch import os from torchvision import transforms as trans from utils.constants import * list_model = ['wget https://www.dropbox.com/s/akktsgxp0n8cwn2/model_mobilefacenet.pth?dl=0 -O model_mobilefacenet.pth', 'wget https://www.dropbox.com/s/kzo52d9neybjxsb/model_ir_se50.p...
true
true
f719a616152547d0300a25992cdb6dbefb41b0a6
16,599
py
Python
utils/tests/test_util.py
Splendon/examples
ed4a8a01857b6ddca49559141acf5d0986eb01e1
[ "MIT" ]
null
null
null
utils/tests/test_util.py
Splendon/examples
ed4a8a01857b6ddca49559141acf5d0986eb01e1
[ "MIT" ]
null
null
null
utils/tests/test_util.py
Splendon/examples
ed4a8a01857b6ddca49559141acf5d0986eb01e1
[ "MIT" ]
null
null
null
# Copyright 2019 Graphcore Ltd. from statistics import mean import numpy as np import os import re import subprocess import sys import time """Library of utility functions common between frameworks""" def parse_results_for_speed(output, iter_tolerance, speed_tolerance): """Look for <iter number> sec/itr. <speed...
34.36646
85
0.636123
from statistics import mean import numpy as np import os import re import subprocess import sys import time def parse_results_for_speed(output, iter_tolerance, speed_tolerance): found_a_result = False for line in output.split("\n"): matches = re.match(r"([\d.]+) +sec/itr. +([\d.]+)", line) ...
true
true
f719a788aa6769dc9f43b9f60b9a57cc0504643a
1,535
py
Python
code/clients/requests.py
lpmatos/gitlab-analytics
47a220bb54efa473f01bf033291f65b38accdbca
[ "MIT" ]
2
2020-09-16T11:03:01.000Z
2021-07-30T07:05:58.000Z
code/clients/requests.py
lpmatos/gitlab-analytics
47a220bb54efa473f01bf033291f65b38accdbca
[ "MIT" ]
null
null
null
code/clients/requests.py
lpmatos/gitlab-analytics
47a220bb54efa473f01bf033291f65b38accdbca
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from __future__ import annotations import requests from validators.url import URL from abc import ABC, abstractmethod from requests.adapters import HTTPAdapter from typing import Text, NoReturn, Callable, Dict from requests.packages.urllib3.util.retry import Retry class RequestResponse: de...
28.962264
130
0.704235
from __future__ import annotations import requests from validators.url import URL from abc import ABC, abstractmethod from requests.adapters import HTTPAdapter from typing import Text, NoReturn, Callable, Dict from requests.packages.urllib3.util.retry import Retry class RequestResponse: def __init__(self, respon...
true
true
f719a9168a4d3106600fffcc47c14cc90f3cadc7
6,299
py
Python
official/vision/detection/dataloader/tf_example_decoder.py
gujralsanyam22/models
d96f8f043dbe2b5ca8ea1785f57df8faf68d8875
[ "Apache-2.0" ]
153
2020-10-25T13:58:04.000Z
2022-03-07T06:01:54.000Z
official/vision/detection/dataloader/tf_example_decoder.py
yangxl-2014-fe/models
11ea5237818e791a5717716d5413977f4c4db1e3
[ "Apache-2.0" ]
11
2020-07-13T08:29:00.000Z
2022-03-24T07:21:09.000Z
official/vision/detection/dataloader/tf_example_decoder.py
yangxl-2014-fe/models
11ea5237818e791a5717716d5413977f4c4db1e3
[ "Apache-2.0" ]
23
2020-10-25T14:44:47.000Z
2021-03-31T02:12:13.000Z
# Copyright 2019 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...
40.121019
122
0.657247
import tensorflow as tf class TfExampleDecoder(object): def __init__(self, include_mask=False): self._include_mask = include_mask self._keys_to_features = { 'image/encoded': tf.io.FixedLenFeature((), tf.string), 'image/source_id': tf.io.FixedLenFeature...
true
true
f719a9bfc05dbb1ca8c4fffbbf92b7f387621266
859
py
Python
taskobra/orm/components/cpu.py
Vipyr/taskobra
d9884f006ef9c735852075912d5a945543de52f5
[ "MIT" ]
null
null
null
taskobra/orm/components/cpu.py
Vipyr/taskobra
d9884f006ef9c735852075912d5a945543de52f5
[ "MIT" ]
43
2020-02-06T22:23:42.000Z
2020-04-29T23:56:43.000Z
taskobra/orm/components/cpu.py
Vipyr/taskobra
d9884f006ef9c735852075912d5a945543de52f5
[ "MIT" ]
2
2020-02-06T21:01:42.000Z
2020-02-06T23:43:11.000Z
# Libraries from sqlalchemy import Column, Float, ForeignKey, Integer, String # Taskobra from taskobra.orm.components import Component class CPU(Component): __tablename__ = "CPU" unique_id = Column(Integer, ForeignKey("Component.unique_id"), primary_key=True) manufacturer = Column(String) model = Colu...
29.62069
132
0.705471
from sqlalchemy import Column, Float, ForeignKey, Integer, String from taskobra.orm.components import Component class CPU(Component): __tablename__ = "CPU" unique_id = Column(Integer, ForeignKey("Component.unique_id"), primary_key=True) manufacturer = Column(String) model = Column(String) isa = ...
true
true
f719a9d668b8a403e901541f650b87db1bf30dbc
1,112
py
Python
music/migrations/0010_auto_20150427_2304.py
Amoki/Amoki-Music
77b0e426fe9cc6c9cd12346a5e5e81a62362bb83
[ "MIT" ]
3
2015-06-16T11:12:29.000Z
2019-05-03T09:09:21.000Z
music/migrations/0010_auto_20150427_2304.py
Amoki/Amoki-Music
77b0e426fe9cc6c9cd12346a5e5e81a62362bb83
[ "MIT" ]
16
2015-08-18T14:35:55.000Z
2021-06-10T17:31:04.000Z
music/migrations/0010_auto_20150427_2304.py
Amoki/Amoki-Music
77b0e426fe9cc6c9cd12346a5e5e81a62362bb83
[ "MIT" ]
1
2016-10-19T14:48:52.000Z
2016-10-19T14:48:52.000Z
from __future__ import unicode_literals from django.db import models, migrations def set_sources(apps, schema_editor): # We can't import the Person model directly as it may be a newer # version than this migration expects. We use the historical version. Source = apps.get_model("music", "Source") Temp...
30.888889
92
0.654676
from __future__ import unicode_literals from django.db import models, migrations def set_sources(apps, schema_editor): # version than this migration expects. We use the historical version. Source = apps.get_model("music", "Source") TemporaryMusic = apps.get_model("music", "TemporaryMusic") youtu...
true
true
f719aae1c7a532a452c6a6c2a3522f59f033bbfa
1,533
py
Python
tests/test_fieldtype_model.py
MasterScott/Formasaurus
d7d916237a6d2ca4c80c4c8ae5d66999c8beebed
[ "MIT" ]
132
2015-04-18T01:53:52.000Z
2022-03-31T08:33:26.000Z
tests/test_fieldtype_model.py
Eglet27/Formasaurus
d7d916237a6d2ca4c80c4c8ae5d66999c8beebed
[ "MIT" ]
26
2015-07-08T20:09:26.000Z
2022-03-03T16:50:08.000Z
tests/test_fieldtype_model.py
Eglet27/Formasaurus
d7d916237a6d2ca4c80c4c8ae5d66999c8beebed
[ "MIT" ]
63
2015-02-17T08:41:00.000Z
2022-03-31T08:58:18.000Z
# -*- coding: utf-8 -*- from __future__ import absolute_import, division import itertools import numpy as np from sklearn_crfsuite.metrics import flat_accuracy_score from formasaurus.fieldtype_model import ( train, _PRECISE_C1_C2, _REALISTIC_C1_C2, get_Xy, ) def test_training(storage, capsys): a...
28.924528
65
0.701239
from __future__ import absolute_import, division import itertools import numpy as np from sklearn_crfsuite.metrics import flat_accuracy_score from formasaurus.fieldtype_model import ( train, _PRECISE_C1_C2, _REALISTIC_C1_C2, get_Xy, ) def test_training(storage, capsys): annotations = (a for a i...
true
true
f719ac12ab39a81ed2df4d9c929c5f6b2e9f5724
2,399
py
Python
Lib/glyphsLib/__main__.py
silnrsi/glyphsLib
fc9ac286874e30130679430b028a173062c311a0
[ "Apache-2.0" ]
1
2019-01-19T05:50:30.000Z
2019-01-19T05:50:30.000Z
Lib/glyphsLib/__main__.py
DalavanCloud/glyphsLib
fc9ac286874e30130679430b028a173062c311a0
[ "Apache-2.0" ]
null
null
null
Lib/glyphsLib/__main__.py
DalavanCloud/glyphsLib
fc9ac286874e30130679430b028a173062c311a0
[ "Apache-2.0" ]
1
2019-01-19T05:50:14.000Z
2019-01-19T05:50:14.000Z
# Copyright 2015 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or a...
38.693548
82
0.631513
from __future__ import print_function, division, absolute_import, unicode_literals import sys import argparse import glyphsLib description = """\n Converts a Glyphs.app source file into UFO masters or UFO instances and MutatorMath designspace. """ def parse_options(args): parser = argparse.Argum...
true
true
f719ac201c882a4f33c304211ff792834b6fe5b0
640
py
Python
fm2o2.py
dumpydog212/fm2o2
b5e173735bb08466d6c20f7868725e627260dd88
[ "MIT" ]
null
null
null
fm2o2.py
dumpydog212/fm2o2
b5e173735bb08466d6c20f7868725e627260dd88
[ "MIT" ]
null
null
null
fm2o2.py
dumpydog212/fm2o2
b5e173735bb08466d6c20f7868725e627260dd88
[ "MIT" ]
null
null
null
import glob import os from xml.dom import minidom import xml.etree.ElementTree as ET path = r"C:\Users\shamb\Desktop\dita_demo" valid_path = r"C:\Users\shamb\Desktop\dita_demo_scrubbed" wildcard = "*.xml" full_path = os.path.join(path, wildcard) os.makedirs(valid_path, exist_ok=True) file_list = glob.glob(full_path...
22.068966
57
0.696875
import glob import os from xml.dom import minidom import xml.etree.ElementTree as ET path = r"C:\Users\shamb\Desktop\dita_demo" valid_path = r"C:\Users\shamb\Desktop\dita_demo_scrubbed" wildcard = "*.xml" full_path = os.path.join(path, wildcard) os.makedirs(valid_path, exist_ok=True) file_list = glob.glob(full_path...
true
true
f719acd0bf5519f70da4e2324dadedc8b1906093
12,049
py
Python
gooddata-afm-client/gooddata_afm_client/model/included_dimension_props.py
gooddata/gooddata-python-sdk
df4d4a4d730ab376960ae2ed01e7d86498e85c6a
[ "MIT" ]
7
2022-01-24T16:27:06.000Z
2022-02-25T10:18:49.000Z
gooddata-afm-client/gooddata_afm_client/model/included_dimension_props.py
gooddata/gooddata-python-sdk
df4d4a4d730ab376960ae2ed01e7d86498e85c6a
[ "MIT" ]
29
2022-01-20T15:45:38.000Z
2022-03-31T09:39:25.000Z
gooddata-afm-client/gooddata_afm_client/model/included_dimension_props.py
gooddata/gooddata-python-sdk
df4d4a4d730ab376960ae2ed01e7d86498e85c6a
[ "MIT" ]
7
2022-01-20T07:11:15.000Z
2022-03-09T14:50:17.000Z
""" OpenAPI definition No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 The version of the OpenAPI document: v0 Contact: support@gooddata.com Generated by: https://openapi-generator.tech """ import re # noqa: F401 import sy...
45.813688
361
0.590256
import re import sys from gooddata_afm_client.model_utils import ( ApiTypeError, ModelComposed, ModelNormal, ModelSimple, cached_property, change_keys_js_to_python, convert_js_args_to_python_args, date, datetime, file_type, none_type, validate_get_composed_info, ...
true
true
f719ad57e58a44fc929ef55ed10a1ee635466eb2
326
py
Python
setup.py
droberin/cyberdyne-dyndns
7d495390413cff2829f6b00a482f7b9dff3dcb5a
[ "MIT" ]
null
null
null
setup.py
droberin/cyberdyne-dyndns
7d495390413cff2829f6b00a482f7b9dff3dcb5a
[ "MIT" ]
null
null
null
setup.py
droberin/cyberdyne-dyndns
7d495390413cff2829f6b00a482f7b9dff3dcb5a
[ "MIT" ]
null
null
null
from distutils.core import setup setup( name='cyberdynedyndnscli', version='0.1.0', packages=['cyberdynedyndnscli'], url='https://github.com/droberin/cyberdynedyndnscli', license='MIT', author='DRoBeR', author_email='drober+software@gmail.com', description='Cyberdyne.es Dynamic DNS clie...
25.076923
57
0.699387
from distutils.core import setup setup( name='cyberdynedyndnscli', version='0.1.0', packages=['cyberdynedyndnscli'], url='https://github.com/droberin/cyberdynedyndnscli', license='MIT', author='DRoBeR', author_email='drober+software@gmail.com', description='Cyberdyne.es Dynamic DNS clie...
true
true
f719ae112f660d822e36dfe8386ebed7cf3c5760
13,464
py
Python
Doc/tools/extensions/pyspecific.py
deadsnakes/python3.4
e8ac58ab083b57aa04b46c79f764c68bdab607a0
[ "CNRI-Python-GPL-Compatible" ]
null
null
null
Doc/tools/extensions/pyspecific.py
deadsnakes/python3.4
e8ac58ab083b57aa04b46c79f764c68bdab607a0
[ "CNRI-Python-GPL-Compatible" ]
null
null
null
Doc/tools/extensions/pyspecific.py
deadsnakes/python3.4
e8ac58ab083b57aa04b46c79f764c68bdab607a0
[ "CNRI-Python-GPL-Compatible" ]
null
null
null
# -*- coding: utf-8 -*- """ pyspecific.py ~~~~~~~~~~~~~ Sphinx extension with Python doc-specific markup. :copyright: 2008-2014 by Georg Brandl. :license: Python license. """ import re import codecs from os import path from time import asctime from pprint import pformat from docutils.io import St...
36.096515
86
0.635844
import re import codecs from os import path from time import asctime from pprint import pformat from docutils.io import StringOutput from docutils.parsers.rst import Directive from docutils.utils import new_document from docutils import nodes, utils from sphinx import addnodes from sphinx.builders import Builder fr...
true
true
f719ae360e05e3d0b1462b0875f0af93d02276fd
5,643
py
Python
airflow/executors/debug_executor.py
IGIT-CN/airflow
a6e5bcd59198afe5716813e84ebc4c59eade532c
[ "Apache-2.0" ]
3
2019-12-11T15:54:13.000Z
2021-05-24T20:21:08.000Z
airflow/executors/debug_executor.py
IGIT-CN/airflow
a6e5bcd59198afe5716813e84ebc4c59eade532c
[ "Apache-2.0" ]
8
2021-02-08T20:40:47.000Z
2022-03-29T22:27:53.000Z
airflow/executors/debug_executor.py
IGIT-CN/airflow
a6e5bcd59198afe5716813e84ebc4c59eade532c
[ "Apache-2.0" ]
2
2021-01-11T13:53:03.000Z
2021-10-02T05:06:34.000Z
# # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not...
37.370861
104
0.633174
import threading from typing import Any, Dict, List, Optional from airflow.configuration import conf from airflow.executors.base_executor import BaseExecutor from airflow.models.taskinstance import TaskInstance, TaskInstanceKeyType from airflow.utils.state import State class DebugExecutor(BaseExecu...
true
true
f719af5392c1befb33e7fc5a3df49b8e3154b0ce
2,063
py
Python
aliyun-python-sdk-eas/aliyunsdkeas/request/v20210701/ListServicesRequest.py
yndu13/aliyun-openapi-python-sdk
12ace4fb39fe2fb0e3927a4b1b43ee4872da43f5
[ "Apache-2.0" ]
null
null
null
aliyun-python-sdk-eas/aliyunsdkeas/request/v20210701/ListServicesRequest.py
yndu13/aliyun-openapi-python-sdk
12ace4fb39fe2fb0e3927a4b1b43ee4872da43f5
[ "Apache-2.0" ]
null
null
null
aliyun-python-sdk-eas/aliyunsdkeas/request/v20210701/ListServicesRequest.py
yndu13/aliyun-openapi-python-sdk
12ace4fb39fe2fb0e3927a4b1b43ee4872da43f5
[ "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 u...
32.746032
74
0.750848
from aliyunsdkcore.request import RoaRequest from aliyunsdkeas.endpoint import endpoint_data class ListServicesRequest(RoaRequest): def __init__(self): RoaRequest.__init__(self, 'eas', '2021-07-01', 'ListServices','eas') self.set_uri_pattern('/api/v2/services') self.set_method('GET') if ...
true
true
f719af5c196d30f0eb97eff99d60406c1d503639
1,912
py
Python
tests/unit/recommenders/models/test_newsrec_utils.py
enowy/Recommenders
60033231b9167438032843c23158c0c776856e0e
[ "MIT" ]
10
2019-05-06T21:57:10.000Z
2019-05-07T06:15:39.000Z
tests/unit/recommenders/models/test_newsrec_utils.py
enowy/Recommenders
60033231b9167438032843c23158c0c776856e0e
[ "MIT" ]
2
2022-01-19T20:24:51.000Z
2022-02-18T20:25:24.000Z
tests/unit/recommenders/models/test_newsrec_utils.py
enowy/Recommenders
60033231b9167438032843c23158c0c776856e0e
[ "MIT" ]
3
2019-05-06T22:24:21.000Z
2019-05-07T02:50:46.000Z
# Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. import os import pytest try: from recommenders.models.deeprec.deeprec_utils import download_deeprec_resources from recommenders.models.newsrec.newsrec_utils import prepare_hparams, load_yaml except ImportError: p...
33.54386
88
0.69613
import os import pytest try: from recommenders.models.deeprec.deeprec_utils import download_deeprec_resources from recommenders.models.newsrec.newsrec_utils import prepare_hparams, load_yaml except ImportError: pass @pytest.mark.parametrize( "must_exist_attributes", ["wordEmb_file", "wordDict_fi...
true
true
f719af7723defb10087e667c5753c6f31f956520
12,081
py
Python
Self_Driving_Car/P1/LaneLines-P1/P1.py
Wentaobi/Udacity
00af9c36b42d6bca5f2d42d2744efed2ddb51587
[ "Apache-2.0" ]
null
null
null
Self_Driving_Car/P1/LaneLines-P1/P1.py
Wentaobi/Udacity
00af9c36b42d6bca5f2d42d2744efed2ddb51587
[ "Apache-2.0" ]
null
null
null
Self_Driving_Car/P1/LaneLines-P1/P1.py
Wentaobi/Udacity
00af9c36b42d6bca5f2d42d2744efed2ddb51587
[ "Apache-2.0" ]
null
null
null
#importing some useful packages import matplotlib.pyplot as plt import matplotlib.image as mpimg import numpy as np import cv2 #reading in an image image = mpimg.imread('test_images/solidWhiteRight.jpg'); #printing out some stats and plotting print('This image is:', type(image), 'with dimesions:', image.shape) plt.im...
35.848665
122
0.698121
import matplotlib.pyplot as plt import matplotlib.image as mpimg import numpy as np import cv2 image = mpimg.imread('test_images/solidWhiteRight.jpg'); print('This image is:', type(image), 'with dimesions:', image.shape) plt.imshow(image); import math def grayscale(img): return cv2.cvtColor(img, cv2.COLOR_...
true
true
f719afb71003662d81876c64edd582861d9f11a6
1,088
py
Python
exercicios-Python/desaf045.py
marcelo-py/Exercicios-Python
d654d54821983897dbc377a2d3db97671dd75b5b
[ "MIT" ]
null
null
null
exercicios-Python/desaf045.py
marcelo-py/Exercicios-Python
d654d54821983897dbc377a2d3db97671dd75b5b
[ "MIT" ]
null
null
null
exercicios-Python/desaf045.py
marcelo-py/Exercicios-Python
d654d54821983897dbc377a2d3db97671dd75b5b
[ "MIT" ]
null
null
null
import random from emoji import emojize from time import sleep itens = ('PEDRA', 'PAPEL', 'TESOURA') print (emojize('''Suas opções: [0] PEDRA :punch: [1] PAPEL :hand: [2] TESOURA :v:''',use_aliases=True)) escolha = int(input('Qual sua escolha? ')) computador = random.randint(0,2) print('JO') sleep(1) print('KEN') sleep...
25.302326
59
0.607537
import random from emoji import emojize from time import sleep itens = ('PEDRA', 'PAPEL', 'TESOURA') print (emojize('''Suas opções: [0] PEDRA :punch: [1] PAPEL :hand: [2] TESOURA :v:''',use_aliases=True)) escolha = int(input('Qual sua escolha? ')) computador = random.randint(0,2) print('JO') sleep(1) print('KEN') sleep...
true
true
f719afef6ce3f033481568e9522937db2bfbd069
86
py
Python
my_exceptions.py
robert-dzikowski/api-smoke-test
64394049ce82a0cf80fc128587a4a83e491725b7
[ "MIT" ]
1
2021-01-30T23:01:00.000Z
2021-01-30T23:01:00.000Z
my_exceptions.py
robert-dzikowski/api-smoke-test
64394049ce82a0cf80fc128587a4a83e491725b7
[ "MIT" ]
null
null
null
my_exceptions.py
robert-dzikowski/api-smoke-test
64394049ce82a0cf80fc128587a4a83e491725b7
[ "MIT" ]
null
null
null
class TestFail(Exception): """ Exception raised when test has failed. """
17.2
42
0.627907
class TestFail(Exception):
true
true
f719b0534049d456a9239569b20111fc6dcfa5fb
292
py
Python
esphome/components/json/__init__.py
TheEggi/esphomeyaml
98e8cc1edc7b29891e8100eb484922e5c2d4fc33
[ "MIT" ]
null
null
null
esphome/components/json/__init__.py
TheEggi/esphomeyaml
98e8cc1edc7b29891e8100eb484922e5c2d4fc33
[ "MIT" ]
null
null
null
esphome/components/json/__init__.py
TheEggi/esphomeyaml
98e8cc1edc7b29891e8100eb484922e5c2d4fc33
[ "MIT" ]
null
null
null
import esphome.codegen as cg from esphome.core import coroutine_with_priority json_ns = cg.esphome_ns.namespace('json') @coroutine_with_priority(1.0) def to_code(config): cg.add_library('ArduinoJson-esphomelib', '5.13.3') cg.add_define('USE_JSON') cg.add_global(json_ns.using)
24.333333
54
0.763699
import esphome.codegen as cg from esphome.core import coroutine_with_priority json_ns = cg.esphome_ns.namespace('json') @coroutine_with_priority(1.0) def to_code(config): cg.add_library('ArduinoJson-esphomelib', '5.13.3') cg.add_define('USE_JSON') cg.add_global(json_ns.using)
true
true
f719b0960e13ee24f7ce64d60d298220d2513dc0
53
py
Python
shiftscheduler/gui/constants.py
c-rainbow/nurse-scheduling
8537c875e46772700499a89dec3a30a796434fe0
[ "MIT" ]
2
2020-04-16T17:03:56.000Z
2021-04-08T17:23:21.000Z
shiftscheduler/gui/constants.py
c-rainbow/nurse-scheduling
8537c875e46772700499a89dec3a30a796434fe0
[ "MIT" ]
null
null
null
shiftscheduler/gui/constants.py
c-rainbow/nurse-scheduling
8537c875e46772700499a89dec3a30a796434fe0
[ "MIT" ]
1
2020-05-04T18:03:59.000Z
2020-05-04T18:03:59.000Z
EXCEL_FILE_TYPE = (("Excel 2007 files","*.xlsx"),)
13.25
50
0.622642
EXCEL_FILE_TYPE = (("Excel 2007 files","*.xlsx"),)
true
true
f719b09aaa3ce37ed804af7fc5327f4ef6a12908
645
py
Python
noxfile.py
HarshNarayanJha/diddi-and-the-bugs
82af417a2ab324de7bde38736bfc42430b6b46fa
[ "MIT" ]
null
null
null
noxfile.py
HarshNarayanJha/diddi-and-the-bugs
82af417a2ab324de7bde38736bfc42430b6b46fa
[ "MIT" ]
null
null
null
noxfile.py
HarshNarayanJha/diddi-and-the-bugs
82af417a2ab324de7bde38736bfc42430b6b46fa
[ "MIT" ]
null
null
null
""" I use Nox here to reformat the code. """ import nox files = ["noxfile.py", "main.py", "setup.py"] @nox.session(name="keep-codebase-clean") def keep_codebase_clean(session): "Run formatters." session.install("-r", "test-requirements.txt") session.run("isort", *files) session.run("blac...
26.875
59
0.632558
import nox files = ["noxfile.py", "main.py", "setup.py"] @nox.session(name="keep-codebase-clean") def keep_codebase_clean(session): session.install("-r", "test-requirements.txt") session.run("isort", *files) session.run("black", *files) @nox.session(name="check-quality") def check_quality(...
true
true