hexsha
stringlengths
40
40
size
int64
2
1.02M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
4
245
max_stars_repo_name
stringlengths
6
130
max_stars_repo_head_hexsha
stringlengths
40
40
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
4
245
max_issues_repo_name
stringlengths
6
130
max_issues_repo_head_hexsha
stringlengths
40
40
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
4
245
max_forks_repo_name
stringlengths
6
130
max_forks_repo_head_hexsha
stringlengths
40
40
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
2
1.02M
avg_line_length
float64
1
958k
max_line_length
int64
1
987k
alphanum_fraction
float64
0
1
content_no_comment
stringlengths
0
1.01M
is_comment_constant_removed
bool
2 classes
is_sharp_comment_removed
bool
1 class
f713d960b564dbd5eb8dda394cd9127243da4a02
70
py
Python
preprocess/__init__.py
failyang/tensorflow-examples
48da6cd25138d448a4ddf7710e8abab0392c453c
[ "MIT" ]
null
null
null
preprocess/__init__.py
failyang/tensorflow-examples
48da6cd25138d448a4ddf7710e8abab0392c453c
[ "MIT" ]
null
null
null
preprocess/__init__.py
failyang/tensorflow-examples
48da6cd25138d448a4ddf7710e8abab0392c453c
[ "MIT" ]
null
null
null
from __future__ import absolute_import from .data_prep import img_pad
23.333333
38
0.871429
from __future__ import absolute_import from .data_prep import img_pad
true
true
f713d990afcddb0cf000499c6b9a2e37b17481d0
171
py
Python
cors/resources/checkandremove.py
ziransun/wpt
ab8f451eb39eb198584d547f5d965ef54df2a86a
[ "BSD-3-Clause" ]
8
2019-04-09T21:13:05.000Z
2021-11-23T17:25:18.000Z
cors/resources/checkandremove.py
ziransun/wpt
ab8f451eb39eb198584d547f5d965ef54df2a86a
[ "BSD-3-Clause" ]
21
2021-03-31T19:48:22.000Z
2022-03-12T00:24:53.000Z
cors/resources/checkandremove.py
ziransun/wpt
ab8f451eb39eb198584d547f5d965ef54df2a86a
[ "BSD-3-Clause" ]
11
2019-04-12T01:20:16.000Z
2021-11-23T17:25:02.000Z
def main(request, response): token = request.GET.first("token") if request.server.stash.remove(token) is not None: return "1" else: return "0"
24.428571
54
0.614035
def main(request, response): token = request.GET.first("token") if request.server.stash.remove(token) is not None: return "1" else: return "0"
true
true
f713d9fffdd9e54ff53f7c4fe224e681bcfb2723
8,280
py
Python
pcdet/models/backbones_3d/spconv_unet.py
StarGazer1995/OpenPCDet
4af33e8badb0c8e68c7c94c71b0ec5667aad2348
[ "Apache-2.0" ]
null
null
null
pcdet/models/backbones_3d/spconv_unet.py
StarGazer1995/OpenPCDet
4af33e8badb0c8e68c7c94c71b0ec5667aad2348
[ "Apache-2.0" ]
null
null
null
pcdet/models/backbones_3d/spconv_unet.py
StarGazer1995/OpenPCDet
4af33e8badb0c8e68c7c94c71b0ec5667aad2348
[ "Apache-2.0" ]
null
null
null
import torch import torch.nn as nn import spconv from functools import partial from .spconv_backbone import post_act_block from ...utils import common_utils class SparseBasicBlock(spconv.SparseModule): expansion = 1 def __init__(self, inplanes, planes, stride=1, downsample=None, indice_key=None, norm_fn=None...
40
117
0.608937
import torch import torch.nn as nn import spconv from functools import partial from .spconv_backbone import post_act_block from ...utils import common_utils class SparseBasicBlock(spconv.SparseModule): expansion = 1 def __init__(self, inplanes, planes, stride=1, downsample=None, indice_key=None, norm_fn=None...
true
true
f713dab102d61680c2f1adddccfa93c5ec27ff39
1,194
py
Python
rich/_lru_cache.py
hultner-technologies/rich
7a50f9d3f299a2ed44e36aa241e0a15323add317
[ "MIT" ]
2
2021-05-11T19:27:06.000Z
2021-05-12T06:08:08.000Z
rich/_lru_cache.py
hultner-technologies/rich
7a50f9d3f299a2ed44e36aa241e0a15323add317
[ "MIT" ]
2
2020-05-09T12:42:28.000Z
2020-05-09T14:44:04.000Z
rich/_lru_cache.py
hultner-technologies/rich
7a50f9d3f299a2ed44e36aa241e0a15323add317
[ "MIT" ]
1
2020-05-04T08:13:02.000Z
2020-05-04T08:13:02.000Z
from collections import OrderedDict from typing import Dict, Generic, Mapping, TypeVar CacheKey = TypeVar("CacheKey") CacheValue = TypeVar("CacheValue") class LRUCache(Generic[CacheKey, CacheValue], OrderedDict): """ A dictionary-like container that stores a given maximum items. If an additional item i...
34.114286
83
0.675042
from collections import OrderedDict from typing import Dict, Generic, Mapping, TypeVar CacheKey = TypeVar("CacheKey") CacheValue = TypeVar("CacheValue") class LRUCache(Generic[CacheKey, CacheValue], OrderedDict): def __init__(self, cache_size: int) -> None: self.cache_size = cache_size super(LR...
true
true
f713dac0b4da63916336159fcfe479841e59456e
1,950
py
Python
hdfs_namenode/setup.py
byronwolfman/integrations-core
e89d31cf760cb0829a524929104eb400ec93ec2e
[ "BSD-3-Clause" ]
null
null
null
hdfs_namenode/setup.py
byronwolfman/integrations-core
e89d31cf760cb0829a524929104eb400ec93ec2e
[ "BSD-3-Clause" ]
null
null
null
hdfs_namenode/setup.py
byronwolfman/integrations-core
e89d31cf760cb0829a524929104eb400ec93ec2e
[ "BSD-3-Clause" ]
null
null
null
# (C) Datadog, Inc. 2018 # All rights reserved # Licensed under a 3-clause BSD style license (see LICENSE) # Always prefer setuptools over distutils from setuptools import setup # To use a consistent encoding from codecs import open from os import path HERE = path.abspath(path.dirname(__file__)) # Get the long descr...
28.26087
83
0.691282
from setuptools import setup from codecs import open from os import path HERE = path.abspath(path.dirname(__file__)) with open(path.join(HERE, 'README.md'), encoding='utf-8') as f: long_description = f.read() ABOUT = {} with open(path.join(HERE, "datadog_checks", "hdfs_namenode", "__about__.py")) as f: exec...
true
true
f713dbe3cb55df4e874d577344ebd20f05b89914
5,140
py
Python
temp/train_cnn.py
ChenLi0830/Clevo-Categorization-Service
44b509786849a6dce610171d86e5da68ad748b4b
[ "Apache-2.0" ]
null
null
null
temp/train_cnn.py
ChenLi0830/Clevo-Categorization-Service
44b509786849a6dce610171d86e5da68ad748b4b
[ "Apache-2.0" ]
null
null
null
temp/train_cnn.py
ChenLi0830/Clevo-Categorization-Service
44b509786849a6dce610171d86e5da68ad748b4b
[ "Apache-2.0" ]
null
null
null
'''This example demonstrates the use of Convolution1D for text classification. ''' from __future__ import print_function import sys sys.path.append('/Users/wangwei/anaconda2/envs/python3_keras/lib/python3.6/site-packages') from keras.preprocessing import sequence from keras.models import Sequential from keras.layer...
29.54023
93
0.630739
from __future__ import print_function import sys sys.path.append('/Users/wangwei/anaconda2/envs/python3_keras/lib/python3.6/site-packages') from keras.preprocessing import sequence from keras.models import Sequential from keras.layers import Dense, Dropout, Activation from keras.layers import Embedding from keras.l...
true
true
f713dc570725e17253c9bd8bfdf49979fa3276df
9,740
py
Python
registration.py
uzbeki/OmronHVC-2Py3.9.4
f3e62cf455a82853f73c98be70915d48b24d1c6c
[ "Apache-2.0" ]
null
null
null
registration.py
uzbeki/OmronHVC-2Py3.9.4
f3e62cf455a82853f73c98be70915d48b24d1c6c
[ "Apache-2.0" ]
null
null
null
registration.py
uzbeki/OmronHVC-2Py3.9.4
f3e62cf455a82853f73c98be70915d48b24d1c6c
[ "Apache-2.0" ]
null
null
null
# --------------------------------------------------------------------------- # Copyright 2017-2018 OMRON 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://w...
39.918033
95
0.549487
 import os.path import sys import time import p2def from serial_connector import SerialConnector from hvc_p2_api import HVCP2Api from hvc_tracking_result import HVCTrackingResult from grayscale_image import GrayscaleImage img_fname = 'registerd_img.jpg' timeout = 30 album_fname = 'Album.dat' hvc_...
false
true
f713dda96bfadd28ecfe9efd69a5b821b0f53e52
19,840
py
Python
cogs/boards.py
wpmjones/donationbot
dd2913df09b61d4fe4738fe9df14ff8bc4ec6f95
[ "MIT" ]
null
null
null
cogs/boards.py
wpmjones/donationbot
dd2913df09b61d4fe4738fe9df14ff8bc4ec6f95
[ "MIT" ]
null
null
null
cogs/boards.py
wpmjones/donationbot
dd2913df09b61d4fe4738fe9df14ff8bc4ec6f95
[ "MIT" ]
null
null
null
import asyncio import asyncpg import coc import discord import logging import math from collections import namedtuple from datetime import datetime from discord.ext import commands, tasks from cogs.utils.db_objects import DatabaseMessage from cogs.utils.formatters import CLYTable, get_render_type from cogs.utils impo...
39.055118
111
0.526563
import asyncio import asyncpg import coc import discord import logging import math from collections import namedtuple from datetime import datetime from discord.ext import commands, tasks from cogs.utils.db_objects import DatabaseMessage from cogs.utils.formatters import CLYTable, get_render_type from cogs.utils impo...
true
true
f713de87a046a2be2116ea80ff02e9b22a5d08de
24,907
py
Python
modules/s3/s3notify.py
sahana/eden-core
6af086d0617e84483aa74317c897ecffbe232596
[ "MIT" ]
2
2018-04-06T08:18:21.000Z
2021-09-17T11:45:00.000Z
modules/s3/s3notify.py
sahana/eden-core
6af086d0617e84483aa74317c897ecffbe232596
[ "MIT" ]
2
2015-02-14T18:58:17.000Z
2015-02-24T07:22:39.000Z
modules/s3/s3notify.py
sahana/eden-core
6af086d0617e84483aa74317c897ecffbe232596
[ "MIT" ]
3
2015-02-11T10:31:26.000Z
2021-09-17T11:46:29.000Z
# -*- coding: utf-8 -*- """ S3 Notifications @copyright: 2011-2021 (c) Sahana Software Foundation @license: MIT 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 re...
37.680787
88
0.500462
import datetime import json import os import string import sys from io import StringIO from urllib.parse import urlencode from urllib import parse as urlparse from urllib import request as urllib2 from urllib.request import urlopen from urllib.error import HTTPError from uuid import uuid4 from gluon import current,...
true
true
f713de958e85322d46d14b9bb7f2720bd65ba18e
577
py
Python
tests/test_int.py
stephend017/pyparcel
addef8f5da9fce8d0204fb264f7735bd607c9619
[ "MIT" ]
null
null
null
tests/test_int.py
stephend017/pyparcel
addef8f5da9fce8d0204fb264f7735bd607c9619
[ "MIT" ]
null
null
null
tests/test_int.py
stephend017/pyparcel
addef8f5da9fce8d0204fb264f7735bd607c9619
[ "MIT" ]
null
null
null
import struct import unittest from typing import List import pyparcel DATA: List[int] = [ -1 << 31, -1000, -57, -26, -20, -5, -2, -1, 0, 1, 2, 5, 20, 57, 1000, (1 << 31) - 1, ] class MyTestCase(unittest.TestCase): def test_pack(self): for i...
14.794872
73
0.535529
import struct import unittest from typing import List import pyparcel DATA: List[int] = [ -1 << 31, -1000, -57, -26, -20, -5, -2, -1, 0, 1, 2, 5, 20, 57, 1000, (1 << 31) - 1, ] class MyTestCase(unittest.TestCase): def test_pack(self): for i...
true
true
f713df1edf0e8bc7dd726bc88abbe1a02611bb76
2,984
py
Python
adamp/sgdp.py
MOONJOOYOUNG/AdamP
64a63106a2ac62bcbe90627f2a83ec1b488f3416
[ "MIT" ]
1
2021-07-09T21:00:57.000Z
2021-07-09T21:00:57.000Z
adamp/sgdp.py
MOONJOOYOUNG/AdamP
64a63106a2ac62bcbe90627f2a83ec1b488f3416
[ "MIT" ]
null
null
null
adamp/sgdp.py
MOONJOOYOUNG/AdamP
64a63106a2ac62bcbe90627f2a83ec1b488f3416
[ "MIT" ]
null
null
null
""" AdamP Copyright (c) 2020-present NAVER Corp. MIT license """ import torch import torch.nn as nn from torch.optim.optimizer import Optimizer, required import math class SGDP(Optimizer): def __init__(self, params, lr=required, momentum=0, dampening=0, weight_decay=0, nesterov=False, eps=1e-8, d...
32.086022
115
0.529491
import torch import torch.nn as nn from torch.optim.optimizer import Optimizer, required import math class SGDP(Optimizer): def __init__(self, params, lr=required, momentum=0, dampening=0, weight_decay=0, nesterov=False, eps=1e-8, delta=0.1, wd_ratio=0.1): defaults = dict(lr=lr, momentum=...
true
true
f713dfb9ff4a0320ae7a2df342bfd77d79da60df
1,422
py
Python
api/api.py
PranavPusarla/WeightTracker
16a4241b44535555d924ec39d1969b6e13c4d0a9
[ "MIT" ]
null
null
null
api/api.py
PranavPusarla/WeightTracker
16a4241b44535555d924ec39d1969b6e13c4d0a9
[ "MIT" ]
null
null
null
api/api.py
PranavPusarla/WeightTracker
16a4241b44535555d924ec39d1969b6e13c4d0a9
[ "MIT" ]
null
null
null
from flask import Flask, jsonify, send_file, url_for import data_functions from datetime import datetime app = Flask(__name__) #__name__ is a special variable in python that creates an instance of the web app @app.route("/", methods =['GET']) def hello(): return ("Hello World") @app.route("/hello") def helloo():...
37.421053
103
0.734177
from flask import Flask, jsonify, send_file, url_for import data_functions from datetime import datetime app = Flask(__name__) @app.route("/", methods =['GET']) def hello(): return ("Hello World") @app.route("/hello") def helloo(): return "Hello Not World" @app.route("/total_loss/<first_name>/<last_name>", ...
true
true
f713e15ef2d53b7068d6ee22edb42b05f24f1d54
337
py
Python
torch_nlp_utils/common/checks.py
Nemexur/torch_data_utils
c3949f29ffb0b206ddee15dd8b83a34654ff11f3
[ "Apache-2.0" ]
2
2020-06-14T15:00:25.000Z
2020-06-15T06:03:28.000Z
torch_nlp_utils/common/checks.py
Nemexur/torch-nlp-utils
c3949f29ffb0b206ddee15dd8b83a34654ff11f3
[ "Apache-2.0" ]
null
null
null
torch_nlp_utils/common/checks.py
Nemexur/torch-nlp-utils
c3949f29ffb0b206ddee15dd8b83a34654ff11f3
[ "Apache-2.0" ]
1
2020-06-15T06:03:12.000Z
2020-06-15T06:03:12.000Z
class ConfigurationError(Exception): """ The exception raised by any object when it's misconfigured (e.g. missing properties, invalid properties, unknown properties). """ def __init__(self, message): super().__init__() self.message = message def __str__(self): return re...
25.923077
70
0.658754
class ConfigurationError(Exception): def __init__(self, message): super().__init__() self.message = message def __str__(self): return repr(self.message)
true
true
f713e2f59198bac6d20cc010ae1e11de776dd8f8
2,655
py
Python
databuilder/setup.py
abhishek-ch/amundsen
0988547cd4e551488001f8327dd5db67198d9060
[ "Apache-2.0" ]
null
null
null
databuilder/setup.py
abhishek-ch/amundsen
0988547cd4e551488001f8327dd5db67198d9060
[ "Apache-2.0" ]
null
null
null
databuilder/setup.py
abhishek-ch/amundsen
0988547cd4e551488001f8327dd5db67198d9060
[ "Apache-2.0" ]
1
2021-07-19T11:30:55.000Z
2021-07-19T11:30:55.000Z
# Copyright Contributors to the Amundsen project. # SPDX-License-Identifier: Apache-2.0 from setuptools import find_packages, setup __version__ = '4.3.1' requirements = [ "neo4j-driver>=1.7.2,<4.0", "pytz>=2018.4", "statsd>=3.2.1", "retrying>=1.3.3", "requests>=2.23.0,<3.0", "elasticsearch>...
21.24
78
0.583804
from setuptools import find_packages, setup __version__ = '4.3.1' requirements = [ "neo4j-driver>=1.7.2,<4.0", "pytz>=2018.4", "statsd>=3.2.1", "retrying>=1.3.3", "requests>=2.23.0,<3.0", "elasticsearch>=6.2.0,<7.0", "pyhocon>=0.3.42", "unidecode", "Jinja2>=2.10.0,<2.12", "p...
true
true
f713e34b34f9d2fa0ac1d2261cc79b95c3f4b50f
27,503
py
Python
performer/fast_attention/jax/fast_attention.py
deepneuralmachine/google-research
d2ce2cf0f5c004f8d78bfeddf6e88e88f4840231
[ "Apache-2.0" ]
7
2021-06-15T05:54:29.000Z
2022-02-21T06:57:06.000Z
performer/fast_attention/jax/fast_attention.py
deepneuralmachine/google-research
d2ce2cf0f5c004f8d78bfeddf6e88e88f4840231
[ "Apache-2.0" ]
12
2021-08-25T16:15:31.000Z
2022-02-10T05:10:37.000Z
performer/fast_attention/jax/fast_attention.py
deepneuralmachine/google-research
d2ce2cf0f5c004f8d78bfeddf6e88e88f4840231
[ "Apache-2.0" ]
5
2021-11-25T07:40:17.000Z
2022-03-22T11:13:39.000Z
# coding=utf-8 # 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 License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicab...
38.198611
141
0.612406
import abc from collections.abc import Iterable import functools from absl import logging import gin import jax from jax import lax from jax import random import jax.numpy as jnp import numpy as onp gin.external_configurable(jnp.cos, 'jcos') gin.external_configurable(jnp.sin, 'jsin') gin.external_configurable(jnp....
true
true
f713e45808fac231d5822afc0ad72188540cb0ee
788
py
Python
mars/services/web/tests/extra_handler.py
ConanoutlooklvTBS/mars
7030566fd9e9fc02b6b4064ef7bd86f6c24a2f60
[ "Apache-2.0" ]
2,413
2018-12-06T09:37:11.000Z
2022-03-30T15:47:39.000Z
mars/services/web/tests/extra_handler.py
ConanoutlooklvTBS/mars
7030566fd9e9fc02b6b4064ef7bd86f6c24a2f60
[ "Apache-2.0" ]
1,335
2018-12-07T03:06:18.000Z
2022-03-31T11:45:57.000Z
mars/services/web/tests/extra_handler.py
ConanoutlooklvTBS/mars
7030566fd9e9fc02b6b4064ef7bd86f6c24a2f60
[ "Apache-2.0" ]
329
2018-12-07T03:12:41.000Z
2022-03-29T21:49:57.000Z
# Copyright 1999-2021 Alibaba Group Holding Ltd. # # 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...
30.307692
74
0.748731
from ..core import MarsRequestHandler class ExtraTestHandler(MarsRequestHandler): def get(self): self.write('Test') web_handlers = { '/api/extra_test': ExtraTestHandler }
true
true
f713e54ac61b29b80119ca3f3e51c995911ef04d
1,294
bzl
Python
dotnet/private/actions/resx_net.bzl
nolen777/rules_mono
b49c210478c2240fcc7be655c9fc37d751610fb1
[ "Apache-2.0" ]
null
null
null
dotnet/private/actions/resx_net.bzl
nolen777/rules_mono
b49c210478c2240fcc7be655c9fc37d751610fb1
[ "Apache-2.0" ]
null
null
null
dotnet/private/actions/resx_net.bzl
nolen777/rules_mono
b49c210478c2240fcc7be655c9fc37d751610fb1
[ "Apache-2.0" ]
null
null
null
load( "@rules_mono//dotnet/private:providers.bzl", "DotnetLibrary", ) def _make_runner_arglist(dotnet, source, output): args = dotnet.actions.args() args.add("/useSourcePath") if type(source) == "Target": args.add_all(source.files) else: args.add(source) args.add(output) ...
23.107143
83
0.572643
load( "@rules_mono//dotnet/private:providers.bzl", "DotnetLibrary", ) def _make_runner_arglist(dotnet, source, output): args = dotnet.actions.args() args.add("/useSourcePath") if type(source) == "Target": args.add_all(source.files) else: args.add(source) args.add(output) ...
true
true
f713e55caf6b99004ecc3241794afbf437dab6fc
1,098
py
Python
python/main.py
jamesGadoury/robot-search
d7ec99aef71acb113240437321d3b2868c67cf30
[ "MIT" ]
1
2020-12-28T15:30:48.000Z
2020-12-28T15:30:48.000Z
python/main.py
jamesGadoury/robot-search
d7ec99aef71acb113240437321d3b2868c67cf30
[ "MIT" ]
null
null
null
python/main.py
jamesGadoury/robot-search
d7ec99aef71acb113240437321d3b2868c67cf30
[ "MIT" ]
null
null
null
import pathgraph import robotsearch import unittest class TestGraphMethods(unittest.TestCase): def test_create_undirected_graph(self): self.assertTrue(isinstance(pathgraph.graph_by_type("undirected"), pathgraph.UndirectedGraph)) def test_create_directed_graph(self): self.assertTrue(isinst...
37.862069
101
0.73224
import pathgraph import robotsearch import unittest class TestGraphMethods(unittest.TestCase): def test_create_undirected_graph(self): self.assertTrue(isinstance(pathgraph.graph_by_type("undirected"), pathgraph.UndirectedGraph)) def test_create_directed_graph(self): self.assertTrue(isinst...
true
true
f713e5f6c485bc439394846d31e1724342ae0b37
13,276
py
Python
qtp_diversity/tests/test_validate.py
antgonza/qtp-diversity
0c2ec84711decf798ea6ffdb3e97dc9582ba4035
[ "BSD-3-Clause" ]
null
null
null
qtp_diversity/tests/test_validate.py
antgonza/qtp-diversity
0c2ec84711decf798ea6ffdb3e97dc9582ba4035
[ "BSD-3-Clause" ]
null
null
null
qtp_diversity/tests/test_validate.py
antgonza/qtp-diversity
0c2ec84711decf798ea6ffdb3e97dc9582ba4035
[ "BSD-3-Clause" ]
null
null
null
# ----------------------------------------------------------------------------- # Copyright (c) 2014--, The Qiita Development Team. # # Distributed under the terms of the BSD 3-clause License. # # The full license is in the file LICENSE, distributed with this software. # ------------------------------------------------...
43.960265
79
0.597017
from unittest import main from tempfile import mkdtemp, mkstemp from os.path import exists, isdir, join from os import remove, close from shutil import rmtree from json import dumps from skbio.stats.distance import randdm from skbio import OrdinationResults from qiita_client import ArtifactInfo from qiita_client.test...
true
true
f713e63d648cc648889f7311c7603febef324301
1,113
py
Python
__scraping__/bit.do - requests/main.py
whitmans-max/python-examples
881a8f23f0eebc76816a0078e19951893f0daaaa
[ "MIT" ]
140
2017-02-21T22:49:04.000Z
2022-03-22T17:51:58.000Z
__scraping__/bit.do - requests/main.py
whitmans-max/python-examples
881a8f23f0eebc76816a0078e19951893f0daaaa
[ "MIT" ]
5
2017-12-02T19:55:00.000Z
2021-09-22T23:18:39.000Z
__scraping__/bit.do - requests/main.py
whitmans-max/python-examples
881a8f23f0eebc76816a0078e19951893f0daaaa
[ "MIT" ]
79
2017-01-25T10:53:33.000Z
2022-03-11T16:13:57.000Z
# date: 2019.04.21 # https://stackoverflow.com/a/55778640/1832058 import requests # not need Sessions s = requests.Session() s.headers.update({ 'Accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8', 'Accept-Encoding': 'gzip, deflate', 'Accept-Language': 'pl,en-US;q=0.7,en;q=0.3', ...
22.26
90
0.630728
import requests s = requests.Session() s.headers.update({ 'Accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8', 'Accept-Encoding': 'gzip, deflate', 'Accept-Language': 'pl,en-US;q=0.7,en;q=0.3', 'Cache-Control': 'no-cache', 'Connection': 'keep-alive', }) headers={ 'X...
true
true
f713e76a06efdb4f9ded490c7a6cb8a5cf4c458f
84,590
py
Python
astropy/coordinates/sky_coordinate.py
methane/astropy
1a065d5ce403e226799cfb3d606fda33be0a6c08
[ "BSD-3-Clause" ]
null
null
null
astropy/coordinates/sky_coordinate.py
methane/astropy
1a065d5ce403e226799cfb3d606fda33be0a6c08
[ "BSD-3-Clause" ]
null
null
null
astropy/coordinates/sky_coordinate.py
methane/astropy
1a065d5ce403e226799cfb3d606fda33be0a6c08
[ "BSD-3-Clause" ]
null
null
null
import re import copy import warnings import operator import numpy as np from astropy import _erfa as erfa from astropy.utils.compat.misc import override__dir__ from astropy import units as u from astropy.constants import c as speed_of_light from astropy.utils.data_info import MixinInfo from astropy.utils import Shap...
43.268542
139
0.60519
import re import copy import warnings import operator import numpy as np from astropy import _erfa as erfa from astropy.utils.compat.misc import override__dir__ from astropy import units as u from astropy.constants import c as speed_of_light from astropy.utils.data_info import MixinInfo from astropy.utils import Shap...
true
true
f713e7b42f1da89d365885b3f25e6ebfed8d99bf
211
py
Python
chevah/compat/tests/normal/testing/__init__.py
chevah/compat
d22e5f551a628f8a1652c9f2eea306e17930cb8f
[ "BSD-3-Clause" ]
5
2016-12-03T22:54:50.000Z
2021-11-17T11:17:39.000Z
chevah/compat/tests/normal/testing/__init__.py
chevah/compat
d22e5f551a628f8a1652c9f2eea306e17930cb8f
[ "BSD-3-Clause" ]
76
2015-01-22T16:00:31.000Z
2022-02-09T22:13:34.000Z
chevah/compat/tests/normal/testing/__init__.py
chevah/compat
d22e5f551a628f8a1652c9f2eea306e17930cb8f
[ "BSD-3-Clause" ]
1
2016-12-10T15:57:31.000Z
2016-12-10T15:57:31.000Z
# Copyright (c) 2012 Adi Roiban. # See LICENSE for details. """ Unit tests for empirical package. """ from __future__ import print_function from __future__ import division from __future__ import absolute_import
23.444444
38
0.796209
from __future__ import print_function from __future__ import division from __future__ import absolute_import
true
true
f713e7fc29e485533a2b6dde959137a75ce66d30
7,898
py
Python
gammapy/estimators/tests/test_flux_point.py
LauraOlivera/gammapy
0643bb772c86092f758efad745f248a517658013
[ "BSD-3-Clause" ]
155
2015-02-25T12:38:02.000Z
2022-03-13T17:54:30.000Z
gammapy/estimators/tests/test_flux_point.py
LauraOlivera/gammapy
0643bb772c86092f758efad745f248a517658013
[ "BSD-3-Clause" ]
3,131
2015-01-06T15:36:23.000Z
2022-03-31T17:30:57.000Z
gammapy/estimators/tests/test_flux_point.py
registerrier/gammapy
8aadf0ec524bcf51d0ac5655a04507d5d449e7ed
[ "BSD-3-Clause" ]
158
2015-03-16T20:36:44.000Z
2022-03-30T16:05:37.000Z
# Licensed under a 3-clause BSD style license - see LICENSE.rst import pytest import numpy as np from numpy.testing import assert_allclose import astropy.units as u from astropy.table import Table from gammapy.catalog.fermi import SourceCatalog3FGL from gammapy.estimators import FluxPoints from gammapy.modeling.models ...
30.851563
92
0.67688
import pytest import numpy as np from numpy.testing import assert_allclose import astropy.units as u from astropy.table import Table from gammapy.catalog.fermi import SourceCatalog3FGL from gammapy.estimators import FluxPoints from gammapy.modeling.models import SpectralModel from gammapy.utils.scripts import make_path...
true
true
f713e8c33d889784d56225ab47aa4e7c69c1753d
1,369
py
Python
backend/config.py
takusan64/world-dictionary-backend
98d92547eef6c5bb4adf89dd412273d30db00317
[ "MIT" ]
null
null
null
backend/config.py
takusan64/world-dictionary-backend
98d92547eef6c5bb4adf89dd412273d30db00317
[ "MIT" ]
null
null
null
backend/config.py
takusan64/world-dictionary-backend
98d92547eef6c5bb4adf89dd412273d30db00317
[ "MIT" ]
null
null
null
import os from os.path import join, dirname from dotenv import load_dotenv from urllib.parse import urlparse # loading .env file env_path = join(dirname(__file__), '.env') load_dotenv(env_path) # use function def url_path_check(path): sample_host = 'http://localhost' sample_url = sample_host + path ...
36.026316
94
0.716581
import os from os.path import join, dirname from dotenv import load_dotenv from urllib.parse import urlparse env_path = join(dirname(__file__), '.env') load_dotenv(env_path) def url_path_check(path): sample_host = 'http://localhost' sample_url = sample_host + path if urlparse(sample_url) and urlparse...
true
true
f713ea8db528032ad33727686296727e18b4ed76
4,232
py
Python
pnc/draco3_lb_pnc/draco3_lb_controller.py
MaxxWilson/ASE389Project
13c3c72887e27fbed2eef63c1e27b4a185036a39
[ "MIT" ]
17
2021-05-31T10:55:48.000Z
2022-03-30T10:09:37.000Z
pnc/draco3_lb_pnc/draco3_lb_controller.py
MaxxWilson/ASE389Project
13c3c72887e27fbed2eef63c1e27b4a185036a39
[ "MIT" ]
2
2021-10-01T22:11:43.000Z
2021-12-06T02:34:33.000Z
pnc/draco3_lb_pnc/draco3_lb_controller.py
MaxxWilson/ASE389Project
13c3c72887e27fbed2eef63c1e27b4a185036a39
[ "MIT" ]
3
2021-08-24T00:53:18.000Z
2022-03-31T17:29:07.000Z
import numpy as np from util import util from config.draco3_lb_config import PnCConfig, WBCConfig from pnc.wbc.ihwbc.ihwbc import IHWBC from pnc.wbc.ihwbc.joint_integrator import JointIntegrator class Draco3LBController(object): def __init__(self, tci_container, robot): self._tci_container = tci_containe...
41.90099
80
0.617675
import numpy as np from util import util from config.draco3_lb_config import PnCConfig, WBCConfig from pnc.wbc.ihwbc.ihwbc import IHWBC from pnc.wbc.ihwbc.joint_integrator import JointIntegrator class Draco3LBController(object): def __init__(self, tci_container, robot): self._tci_container = tci_containe...
true
true
f713eb5b80fefbba4d3684e8dbcfd7f4fb2c4c23
7,816
py
Python
polyglot/markdown/kindle_notebook.py
thespacedoctor/simpdf
09f86aff88c3591e7f29a05dc57957f1874644ed
[ "MIT" ]
23
2017-09-25T15:24:16.000Z
2021-11-23T21:14:17.000Z
polyglot/markdown/kindle_notebook.py
thespacedoctor/simpdf
09f86aff88c3591e7f29a05dc57957f1874644ed
[ "MIT" ]
6
2018-01-26T15:39:31.000Z
2021-04-22T18:21:57.000Z
polyglot/markdown/kindle_notebook.py
thespacedoctor/simpdf
09f86aff88c3591e7f29a05dc57957f1874644ed
[ "MIT" ]
3
2017-02-03T19:02:12.000Z
2020-10-17T21:36:25.000Z
#!/usr/local/bin/python # encoding: utf-8 """ *Convert the HTML export of kindle notebooks (from kindle apps) to markdown* :Author: David Young :Date Created: October 17, 2016 """ ################# GLOBAL IMPORTS #################### import sys import os import re import collections os.environ['TERM'] = 'vt10...
33.689655
210
0.525333
""" *Convert the HTML export of kindle notebooks (from kindle apps) to markdown* :Author: David Young :Date Created: October 17, 2016 """ import sys import os import re import collections os.environ['TERM'] = 'vt100' from fundamentals import tools colorCode = { "blue": "code", "yellow": "text", "...
false
true
f713ee8c639c7e6ee5d24c6125c399a3192d0f4d
1,629
py
Python
pymantic/parsers/base.py
machallboyd/pymantic
159208f1a45d4bfda56adaa0cfdb555cadd89d39
[ "BSD-3-Clause" ]
null
null
null
pymantic/parsers/base.py
machallboyd/pymantic
159208f1a45d4bfda56adaa0cfdb555cadd89d39
[ "BSD-3-Clause" ]
1
2019-06-19T13:17:57.000Z
2019-06-19T13:44:10.000Z
pymantic/parsers/base.py
machallboyd/pymantic
159208f1a45d4bfda56adaa0cfdb555cadd89d39
[ "BSD-3-Clause" ]
1
2020-09-22T15:38:33.000Z
2020-09-22T15:38:33.000Z
from collections import defaultdict from threading import local import pymantic.primitives class BaseParser(object): """Common base class for all parsers Provides shared utilities for creating RDF objects, handling IRIs, and tracking parser state. """ def __init__(self, environment=None): ...
30.735849
74
0.688152
from collections import defaultdict from threading import local import pymantic.primitives class BaseParser(object): def __init__(self, environment=None): self.env = environment or pymantic.primitives.RDFEnvironment() self.profile = self.env.createProfile() self._call_state = local() ...
true
true
f713eea928557ab0c23074afaa3be56464a6df33
3,006
py
Python
huobi/impl/accountinfomap.py
icemilk00/huobi_Python
0cccd98ed926faa21e0bfc34033e29755788a36e
[ "Apache-2.0" ]
null
null
null
huobi/impl/accountinfomap.py
icemilk00/huobi_Python
0cccd98ed926faa21e0bfc34033e29755788a36e
[ "Apache-2.0" ]
null
null
null
huobi/impl/accountinfomap.py
icemilk00/huobi_Python
0cccd98ed926faa21e0bfc34033e29755788a36e
[ "Apache-2.0" ]
null
null
null
from huobi.exception.huobiapiexception import HuobiApiException from huobi.impl.restapiinvoker import call_sync from huobi.model.user import User class AccountInfoMap: user_map = dict() account_id_type_map = dict() account_type_id_map = dict() def update_user_info(self, api_key, request_impl): ...
45.545455
123
0.674983
from huobi.exception.huobiapiexception import HuobiApiException from huobi.impl.restapiinvoker import call_sync from huobi.model.user import User class AccountInfoMap: user_map = dict() account_id_type_map = dict() account_type_id_map = dict() def update_user_info(self, api_key, request_impl): ...
true
true
f713efa3bf3641e0b950751ae3760062ec38d96a
6,138
py
Python
visual_change_analysis/main.py
Barry-lab/Publication_TanniDeCothiBarry2021
425bc0bd9a74b837d912820e9ea1539a111fcb1f
[ "Unlicense" ]
null
null
null
visual_change_analysis/main.py
Barry-lab/Publication_TanniDeCothiBarry2021
425bc0bd9a74b837d912820e9ea1539a111fcb1f
[ "Unlicense" ]
null
null
null
visual_change_analysis/main.py
Barry-lab/Publication_TanniDeCothiBarry2021
425bc0bd9a74b837d912820e9ea1539a111fcb1f
[ "Unlicense" ]
null
null
null
import numpy as np import matplotlib.pyplot as plt import pandas as pd from scipy.stats import pearsonr from bin_data import bin_data # import pixel data right_z_pixel_change = np.load("right_z_pixel_change.npy") left_z_pixel_change = np.load("left_z_pixel_change.npy") front_z_pixel_change = np.load("front_z_pixel_...
47.581395
194
0.717009
import numpy as np import matplotlib.pyplot as plt import pandas as pd from scipy.stats import pearsonr from bin_data import bin_data right_z_pixel_change = np.load("right_z_pixel_change.npy") left_z_pixel_change = np.load("left_z_pixel_change.npy") front_z_pixel_change = np.load("front_z_pixel_change.npy") pixel_cha...
true
true
f713f0642bc4d645527625d9afb36ec84d6b177f
97,107
py
Python
vb2py/parserclasses.py
mvz/vb2py
6ea046f6fc202527a1b3fcd3ef5a67b969dea715
[ "BSD-3-Clause" ]
2
2015-12-01T10:52:36.000Z
2021-04-20T05:15:01.000Z
vb2py/parserclasses.py
mvz/vb2py
6ea046f6fc202527a1b3fcd3ef5a67b969dea715
[ "BSD-3-Clause" ]
4
2016-07-18T18:28:24.000Z
2016-07-19T08:30:14.000Z
vb2py/parserclasses.py
mvz/vb2py
6ea046f6fc202527a1b3fcd3ef5a67b969dea715
[ "BSD-3-Clause" ]
3
2015-07-15T21:08:19.000Z
2021-02-25T09:39:12.000Z
"""A set of classes used during the parsing of VB code""" StopSearch = -9999 # Used to terminate searches for parent properties class VBElement(object): """An element of VB code""" def __init__(self, details, text): """Initialize from the details""" # import pdb; pdb.set_trace() sel...
33.717708
105
0.56653
"""A set of classes used during the parsing of VB code""" StopSearch = -9999 class VBElement(object): """An element of VB code""" def __init__(self, details, text): """Initialize from the details""" self.name = details[0] self.text = makeUnicodeFromSafe(text[details[1]:detai...
false
true
f713f0ef135be2dc5f92333e9d7d370a70df85aa
2,956
py
Python
mbrl/examples/main.py
alik-git/mbrl-lib
b364f8e64ca71ebd18147fe8cdbd3068b74e1f1e
[ "MIT" ]
null
null
null
mbrl/examples/main.py
alik-git/mbrl-lib
b364f8e64ca71ebd18147fe8cdbd3068b74e1f1e
[ "MIT" ]
2
2022-03-09T19:33:18.000Z
2022-03-09T19:44:22.000Z
mbrl/examples/main.py
alik-git/mbrl-lib
b364f8e64ca71ebd18147fe8cdbd3068b74e1f1e
[ "MIT" ]
null
null
null
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved. # # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. from typing import Iterable import hydra import numpy as np import omegaconf import torch import mbrl.algorithms.mbpo as ...
33.977011
233
0.680988
from typing import Iterable import hydra import numpy as np import omegaconf import torch import mbrl.algorithms.mbpo as mbpo import mbrl.algorithms.pets as pets import mbrl.algorithms.planet as planet import mbrl.algorithms.dreamer as dreamer import mbrl.util.env import pandas as pd from collections import Iterable ...
true
true
f713f27d6c357f44964b8142d9ebf6c68ba5f1f4
1,631
py
Python
extern/locating-objects-without-bboxes/object-locator/models/utils.py
YuHsin1998/EllSeg
91a532650ef809eef081a7ef9af5f1940fb37a37
[ "MIT" ]
1
2021-05-26T05:45:42.000Z
2021-05-26T05:45:42.000Z
extern/locating-objects-without-bboxes/object-locator/models/utils.py
xiaohuaibaoguigui/EllSeg
ff56b255f8e650856aec9af23792e105897eba5c
[ "MIT" ]
null
null
null
extern/locating-objects-without-bboxes/object-locator/models/utils.py
xiaohuaibaoguigui/EllSeg
ff56b255f8e650856aec9af23792e105897eba5c
[ "MIT" ]
null
null
null
__copyright__ = \ """ Copyright &copyright © (c) 2019 The Board of Trustees of Purdue University and the Purdue Research Foundation. All rights reserved. This software is covered by US patents and copyright. This source code is to be used for academic research purposes only, and no commercial use is allowed. For any ...
33.285714
110
0.700184
__copyright__ = \ """ Copyright &copyright © (c) 2019 The Board of Trustees of Purdue University and the Purdue Research Foundation. All rights reserved. This software is covered by US patents and copyright. This source code is to be used for academic research purposes only, and no commercial use is allowed. For any ...
true
true
f713f39ba58b4fe5662cd70ad5768f8a6af5ad06
9,744
py
Python
tests/torch/nas/test_state.py
openvinotoolkit/nncf_pytorch
13a483eac6ed891720ba90d7902142c4b3bfa599
[ "Apache-2.0" ]
136
2020-06-01T14:03:31.000Z
2020-10-28T06:10:50.000Z
tests/torch/nas/test_state.py
openvinotoolkit/nncf_pytorch
13a483eac6ed891720ba90d7902142c4b3bfa599
[ "Apache-2.0" ]
133
2020-05-26T13:48:04.000Z
2020-10-28T05:25:55.000Z
tests/torch/nas/test_state.py
openvinotoolkit/nncf_pytorch
13a483eac6ed891720ba90d7902142c4b3bfa599
[ "Apache-2.0" ]
36
2020-05-28T08:18:39.000Z
2020-10-27T14:46:58.000Z
""" Copyright (c) 2022 Intel Corporation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writin...
37.476923
117
0.74179
import logging from copy import deepcopy from functools import partial import pytest import torch from nncf.common.utils.logger import logger as nncf_logger from nncf.experimental.torch.nas.bootstrapNAS.elasticity.base_handler import SEHBuilderStateNames from nncf.experimental.torch.nas.bootstrapNAS.elasticity.elasti...
true
true
f713f3f9c3a36c6b39f53d8a182a15163e5b1137
7,573
gyp
Python
gyp/animator.gyp
Android4SAM/platform_external_skia
7cd90d4eecdba0f40a36945749d40df95d6d641b
[ "BSD-3-Clause" ]
null
null
null
gyp/animator.gyp
Android4SAM/platform_external_skia
7cd90d4eecdba0f40a36945749d40df95d6d641b
[ "BSD-3-Clause" ]
null
null
null
gyp/animator.gyp
Android4SAM/platform_external_skia
7cd90d4eecdba0f40a36945749d40df95d6d641b
[ "BSD-3-Clause" ]
1
2020-11-12T05:40:43.000Z
2020-11-12T05:40:43.000Z
{ 'includes': [ 'common.gypi', ], 'targets': [ { 'target_name': 'animator', 'type': 'static_library', 'include_dirs': [ '../include/config', '../include/core', '../include/effects', '../include/animator', '../include/views', '../include/xml...
39.238342
66
0.579955
{ 'includes': [ 'common.gypi', ], 'targets': [ { 'target_name': 'animator', 'type': 'static_library', 'include_dirs': [ '../include/config', '../include/core', '../include/effects', '../include/animator', '../include/views', '../include/xml...
true
true
f713f41205149d08465b67431cb2f925a8e7cf98
221,612
py
Python
jax/lax/lax.py
baba1587/jax
cb77f2a22de49e85da93f43b7dc448aa238d5207
[ "ECL-2.0", "Apache-2.0" ]
1
2020-05-18T23:57:13.000Z
2020-05-18T23:57:13.000Z
jax/lax/lax.py
baba1587/jax
cb77f2a22de49e85da93f43b7dc448aa238d5207
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
jax/lax/lax.py
baba1587/jax
cb77f2a22de49e85da93f43b7dc448aa238d5207
[ "ECL-2.0", "Apache-2.0" ]
null
null
null
# Copyright 2018 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
41.774175
141
0.711189
import builtins import collections import enum import functools import itertools import operator import string from typing import (Any, Callable, List, NamedTuple, Optional, Sequence, Union, Tuple, Type) import warnings import numpy as onp from ..util import partial, prod from .. import core fr...
true
true
f713f4cb4e88d6989f2ec465138945e7b6d049ed
231
py
Python
santa_helpers/__init__.py
lenarother/santa-helpers
0498b9922b357c98543929a39d9755085da527b0
[ "MIT" ]
null
null
null
santa_helpers/__init__.py
lenarother/santa-helpers
0498b9922b357c98543929a39d9755085da527b0
[ "MIT" ]
null
null
null
santa_helpers/__init__.py
lenarother/santa-helpers
0498b9922b357c98543929a39d9755085da527b0
[ "MIT" ]
null
null
null
"""Top-level package for santa-helpers.""" __author__ = """Magdalena Rother""" __email__ = 'rother.magdalena@gmail.com' __version__ = '0.0.1' from .neighbors import neighbors # noqa from .parse import parse_grid_to_dict # noqa
25.666667
45
0.735931
__author__ = """Magdalena Rother""" __email__ = 'rother.magdalena@gmail.com' __version__ = '0.0.1' from .neighbors import neighbors from .parse import parse_grid_to_dict
true
true
f713f6e459931ce5f210c3897d1bf4d851edf6bf
1,194
py
Python
tests/test_class_oelint_vars_bugtrackerurl.py
vermaete/oelint-adv
6a2cadf2fd076d6e531d4bb0abcc4ad89d1fdbee
[ "BSD-2-Clause" ]
null
null
null
tests/test_class_oelint_vars_bugtrackerurl.py
vermaete/oelint-adv
6a2cadf2fd076d6e531d4bb0abcc4ad89d1fdbee
[ "BSD-2-Clause" ]
null
null
null
tests/test_class_oelint_vars_bugtrackerurl.py
vermaete/oelint-adv
6a2cadf2fd076d6e531d4bb0abcc4ad89d1fdbee
[ "BSD-2-Clause" ]
null
null
null
import os import sys import pytest sys.path.insert(0, os.path.abspath(os.path.dirname(__file__))) from base import TestBaseClass class TestClassOelintVarsBugtrackerIsUrl(TestBaseClass): @pytest.mark.parametrize('id', ['oelint.vars.bugtrackerisurl']) @pytest.mark.parametrize('occurrence', [1]) @pytest....
24.875
67
0.536851
import os import sys import pytest sys.path.insert(0, os.path.abspath(os.path.dirname(__file__))) from base import TestBaseClass class TestClassOelintVarsBugtrackerIsUrl(TestBaseClass): @pytest.mark.parametrize('id', ['oelint.vars.bugtrackerisurl']) @pytest.mark.parametrize('occurrence', [1]) @pytest....
true
true
f713f744998c6af0cf3cc3d45319704b6dcf176c
99
py
Python
spacetrading/apps.py
claudiobierig/doppeldenk
770cd5322753450834ec393a0801de1d2de2bfa2
[ "MIT" ]
1
2020-11-08T12:32:36.000Z
2020-11-08T12:32:36.000Z
spacetrading/apps.py
claudiobierig/doppeldenk
770cd5322753450834ec393a0801de1d2de2bfa2
[ "MIT" ]
1
2021-06-04T22:23:30.000Z
2021-06-04T22:23:30.000Z
spacetrading/apps.py
claudiobierig/doppeldenk
770cd5322753450834ec393a0801de1d2de2bfa2
[ "MIT" ]
null
null
null
from django.apps import AppConfig class SpacetradingConfig(AppConfig): name = 'spacetrading'
16.5
36
0.777778
from django.apps import AppConfig class SpacetradingConfig(AppConfig): name = 'spacetrading'
true
true
f713f7962135e6e3e3c9bc85590f2aebb3b24ea0
4,956
py
Python
cookie/cookie.py
ChairsDaily/cookie
58e294a6f92d061ab96683b7fda13d32daefe3a2
[ "MIT" ]
null
null
null
cookie/cookie.py
ChairsDaily/cookie
58e294a6f92d061ab96683b7fda13d32daefe3a2
[ "MIT" ]
null
null
null
cookie/cookie.py
ChairsDaily/cookie
58e294a6f92d061ab96683b7fda13d32daefe3a2
[ "MIT" ]
null
null
null
#!/usr/bin/python3 """ Beautiful command line parsing @author chairs """ import inspect, sys from collections import namedtuple from collections import defaultdict from subprocess import DEVNULL class Cookie (object): """ Main decorator object @param name of application """ def __init__ (self, app_name, notes=...
26.084211
84
0.682002
import inspect, sys from collections import namedtuple from collections import defaultdict from subprocess import DEVNULL class Cookie (object): def __init__ (self, app_name, notes=()): self.optarg = namedtuple('optarg', ['full', 'abbrev', 'default']) self.name = str(app_name) self.notes = notes def __p...
true
true
f713f85e83a78de7f23187319432ac1b46bbef92
3,117
py
Python
tests/test_cron.py
SF-300/aiocron
fe1abc1728d6c8ecb7ecbf75f86f1014e823dfec
[ "MIT" ]
245
2015-02-23T22:50:55.000Z
2022-03-24T10:24:44.000Z
tests/test_cron.py
SF-300/aiocron
fe1abc1728d6c8ecb7ecbf75f86f1014e823dfec
[ "MIT" ]
21
2015-10-21T16:00:29.000Z
2022-03-28T08:25:46.000Z
tests/test_cron.py
SF-300/aiocron
fe1abc1728d6c8ecb7ecbf75f86f1014e823dfec
[ "MIT" ]
28
2015-10-21T15:41:42.000Z
2022-03-25T21:36:04.000Z
# -*- coding: utf-8 -*- import time import datetime from aiocron import asyncio from aiocron import crontab import pytest class CustomError(Exception): pass def test_str(): loop = asyncio.new_event_loop() @crontab('* * * * * *', loop=loop) def t(): pass assert '* * * * *' in str(t) ...
20.78
67
0.605711
import time import datetime from aiocron import asyncio from aiocron import crontab import pytest class CustomError(Exception): pass def test_str(): loop = asyncio.new_event_loop() @crontab('* * * * * *', loop=loop) def t(): pass assert '* * * * *' in str(t) def test_cron(): loo...
true
true
f713f8f82b5a192645afd5b548efee29e36fd35a
23,097
py
Python
nova/tests/unit/test_fixtures.py
maya2250/nova
e483ca1cd9a5db5856f87fc69ca07c42d2be5def
[ "Apache-2.0" ]
null
null
null
nova/tests/unit/test_fixtures.py
maya2250/nova
e483ca1cd9a5db5856f87fc69ca07c42d2be5def
[ "Apache-2.0" ]
1
2021-03-31T19:35:21.000Z
2021-03-31T19:35:21.000Z
nova/tests/unit/test_fixtures.py
Mattlk13/nova
5b13eb59540aaf535a53920e783964d106de2620
[ "Apache-2.0" ]
1
2020-07-22T09:09:38.000Z
2020-07-22T09:09:38.000Z
# Copyright 2010 United States Government as represented by the # Administrator of the National Aeronautics and Space Administration. # 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 t...
40.592267
78
0.650387
import copy import fixtures as fx import futurist import mock from oslo_config import cfg from oslo_db import exception as db_exc from oslo_log import log as logging from oslo_utils.fixture import uuidsentinel as uuids from oslo_utils import timeutils from oslo_utils import uuidutils from oslotest import output impor...
true
true
f713fb2b521629818719bab00598f5172b4dfd6d
58,015
py
Python
sphinx/builders/html/__init__.py
SamB/sphinx
bf010790ace78ba4bc4231445e73bcecf97e4947
[ "BSD-2-Clause" ]
null
null
null
sphinx/builders/html/__init__.py
SamB/sphinx
bf010790ace78ba4bc4231445e73bcecf97e4947
[ "BSD-2-Clause" ]
null
null
null
sphinx/builders/html/__init__.py
SamB/sphinx
bf010790ace78ba4bc4231445e73bcecf97e4947
[ "BSD-2-Clause" ]
null
null
null
"""Several HTML builders.""" import html import os import posixpath import re import sys from datetime import datetime from os import path from typing import IO, Any, Dict, Iterable, Iterator, List, Optional, Set, Tuple, Type from urllib.parse import quote from docutils import nodes from docutils.core import publish_...
41.707405
116
0.602965
import html import os import posixpath import re import sys from datetime import datetime from os import path from typing import IO, Any, Dict, Iterable, Iterator, List, Optional, Set, Tuple, Type from urllib.parse import quote from docutils import nodes from docutils.core import publish_parts from docutils.frontend ...
true
true
f713fb64d17d622dd93ea8409be4defebd59a2ca
39,023
py
Python
ServidorPython/python32_web/Lib/site-packages/numpy/lib/tests/test_recfunctions.py
mak213k/Servidor_automatizado_python
4403ef8027a2f814220baacc95856cf5fbf01d21
[ "MIT" ]
65
2019-07-24T21:44:58.000Z
2022-03-23T07:12:07.000Z
venv/lib/python3.7/site-packages/numpy/lib/tests/test_recfunctions.py
haideraltahan/CropMe
75a111b9d3b2c50c6f2a9a36d21432053f02284d
[ "MIT" ]
10
2019-12-04T23:51:44.000Z
2022-02-10T09:23:15.000Z
venv/lib/python3.7/site-packages/numpy/lib/tests/test_recfunctions.py
haideraltahan/CropMe
75a111b9d3b2c50c6f2a9a36d21432053f02284d
[ "MIT" ]
45
2019-08-13T09:20:48.000Z
2022-02-18T06:09:42.000Z
from __future__ import division, absolute_import, print_function import pytest import numpy as np import numpy.ma as ma from numpy.ma.mrecords import MaskedRecords from numpy.ma.testutils import assert_equal from numpy.testing import assert_, assert_raises from numpy.lib.recfunctions import ( drop_fields, rename_...
42.27844
85
0.429413
from __future__ import division, absolute_import, print_function import pytest import numpy as np import numpy.ma as ma from numpy.ma.mrecords import MaskedRecords from numpy.ma.testutils import assert_equal from numpy.testing import assert_, assert_raises from numpy.lib.recfunctions import ( drop_fields, rename_...
true
true
f713fcb4e6bd2a51f7ae62f8c0d54992a88852ed
4,771
py
Python
capture/noworkflow/now/persistence/models/diff.py
raffaelfoidl/noworkflow
aa4ca189df24fec6c7abd32bcca6a097b21fdf31
[ "MIT" ]
108
2015-02-04T14:16:51.000Z
2022-03-06T13:52:45.000Z
capture/noworkflow/now/persistence/models/diff.py
raffaelfoidl/noworkflow
aa4ca189df24fec6c7abd32bcca6a097b21fdf31
[ "MIT" ]
92
2015-01-19T14:58:06.000Z
2021-04-19T17:28:50.000Z
capture/noworkflow/now/persistence/models/diff.py
raffaelfoidl/noworkflow
aa4ca189df24fec6c7abd32bcca6a097b21fdf31
[ "MIT" ]
31
2015-03-03T23:53:59.000Z
2021-11-11T04:23:44.000Z
# Copyright (c) 2016 Universidade Federal Fluminense (UFF) # Copyright (c) 2016 Polytechnic Institute of New York University. # This file is part of noWorkflow. # Please, consult the license terms in the LICENSE file. """Diff Object""" from __future__ import (absolute_import, print_function, div...
32.678082
108
0.627961
from __future__ import (absolute_import, print_function, division, unicode_literals) from collections import OrderedDict from future.utils import viewkeys from .base import Model, proxy_gen from .trial import Trial from .graphs.diff_graph import DiffGraph class Diff(Model): __modelname...
true
true
f713fd3785a1602b0c5e916541eb25874c85284a
22,928
py
Python
lib/streamlit/app_session.py
ab077u/streamlit
40356a941dc39411597084d733055e310e3cfcd1
[ "Apache-2.0" ]
null
null
null
lib/streamlit/app_session.py
ab077u/streamlit
40356a941dc39411597084d733055e310e3cfcd1
[ "Apache-2.0" ]
null
null
null
lib/streamlit/app_session.py
ab077u/streamlit
40356a941dc39411597084d733055e310e3cfcd1
[ "Apache-2.0" ]
null
null
null
# Copyright 2018-2022 Streamlit Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in wr...
37.648604
117
0.664341
import sys import uuid from enum import Enum from typing import TYPE_CHECKING, Callable, Optional, List, Any, cast from streamlit.uploaded_file_manager import UploadedFileManager import tornado.ioloop import streamlit.elements.exception as exception_utils from streamlit import __version__, caching, config, legacy_c...
true
true
f713fedde4b97aea695b77b89fd9f2e970232bca
435
py
Python
Lista4/Lista4ex7.py
hugo-paiva/IntroducaoCienciasDaComputacao
a563f2fd5b773acbffaf4c858b86423b1130ae1f
[ "MIT" ]
null
null
null
Lista4/Lista4ex7.py
hugo-paiva/IntroducaoCienciasDaComputacao
a563f2fd5b773acbffaf4c858b86423b1130ae1f
[ "MIT" ]
null
null
null
Lista4/Lista4ex7.py
hugo-paiva/IntroducaoCienciasDaComputacao
a563f2fd5b773acbffaf4c858b86423b1130ae1f
[ "MIT" ]
null
null
null
def concat(s1, s2): if not s1: return s2 return s1[0:1] + concat(s1[1:], s2) def reverse(s1): if not s1: return s1 return concat(reverse(s1[1:]), s1[0]) def prefix(s1, s2): if s1 == '' and s2 != '': return True if s1[:1] == s2[:1]: return prefix(s1[1:], s2...
16.111111
41
0.524138
def concat(s1, s2): if not s1: return s2 return s1[0:1] + concat(s1[1:], s2) def reverse(s1): if not s1: return s1 return concat(reverse(s1[1:]), s1[0]) def prefix(s1, s2): if s1 == '' and s2 != '': return True if s1[:1] == s2[:1]: return prefix(s1[1:], s2...
true
true
f713feed6e11f6d272abab6a55db7e1b8686813b
4,620
py
Python
env/lib/python3.8/site-packages/ask_sdk_model/interfaces/audioplayer/stream.py
adamash99/alexa-play-pot-of-greed
dc2d18dae55692a4bf1becb72685a5777870c643
[ "MIT" ]
90
2018-09-19T21:56:42.000Z
2022-03-30T11:25:21.000Z
ask-sdk-model/ask_sdk_model/interfaces/audioplayer/stream.py
ishitaojha/alexa-apis-for-python
a68f94b7a0e41f819595d6fe56e800403e8a4194
[ "Apache-2.0" ]
11
2018-09-23T12:16:48.000Z
2021-06-10T19:49:45.000Z
ask-sdk-model/ask_sdk_model/interfaces/audioplayer/stream.py
ishitaojha/alexa-apis-for-python
a68f94b7a0e41f819595d6fe56e800403e8a4194
[ "Apache-2.0" ]
28
2018-09-19T22:30:38.000Z
2022-02-22T22:57:07.000Z
# coding: utf-8 # # Copyright 2019 Amazon.com, Inc. or its affiliates. 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. A copy of the License is located at # # http://aws.amazon.com/apache2.0/ # # or in the "lice...
33.970588
123
0.614286
import pprint import re import six import typing from enum import Enum if typing.TYPE_CHECKING: from typing import Dict, List, Optional, Union, Any from datetime import datetime from ask_sdk_model.interfaces.audioplayer.caption_data import CaptionData as CaptionData_e119f120 class Stream(object): ...
true
true
f713feeff5540cb5abd88be8581806ea4a417b09
14,614
py
Python
oscar/lib/python2.7/site-packages/IPython/core/pylabtools.py
sainjusajan/django-oscar
466e8edc807be689b0a28c9e525c8323cc48b8e1
[ "BSD-3-Clause" ]
null
null
null
oscar/lib/python2.7/site-packages/IPython/core/pylabtools.py
sainjusajan/django-oscar
466e8edc807be689b0a28c9e525c8323cc48b8e1
[ "BSD-3-Clause" ]
null
null
null
oscar/lib/python2.7/site-packages/IPython/core/pylabtools.py
sainjusajan/django-oscar
466e8edc807be689b0a28c9e525c8323cc48b8e1
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- """Pylab (matplotlib) support utilities.""" from __future__ import print_function # Copyright (c) IPython Development Team. # Distributed under the terms of the Modified BSD License. from io import BytesIO from IPython.core.display import _pngxy from IPython.utils.decorators import ...
35.643902
91
0.622212
from __future__ import print_function from io import BytesIO from IPython.core.display import _pngxy from IPython.utils.decorators import flag_calls from IPython.utils import py3compat backends = {'tk': 'TkAgg', 'gtk': 'GTKAgg', 'gtk3': 'GTK3Agg', 'wx': 'WXAgg', ...
true
true
f713ff1895f64aa70104aa664da6eedd61326435
35,539
py
Python
sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_pool_operations.py
eliagrady/azure-sdk-for-python
64d0c78ce4a9b409dbc96864d7b65098891863f9
[ "MIT" ]
null
null
null
sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_pool_operations.py
eliagrady/azure-sdk-for-python
64d0c78ce4a9b409dbc96864d7b65098891863f9
[ "MIT" ]
null
null
null
sdk/batch/azure-mgmt-batch/azure/mgmt/batch/aio/operations/_pool_operations.py
eliagrady/azure-sdk-for-python
64d0c78ce4a9b409dbc96864d7b65098891863f9
[ "MIT" ]
1
2021-05-19T02:55:10.000Z
2021-05-19T02:55:10.000Z
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may ...
50.842632
215
0.662624
from typing import Any, AsyncIterable, Callable, Dict, Generic, Optional, TypeVar, Union import warnings from azure.core.async_paging import AsyncItemPaged, AsyncList from azure.core.exceptions import ClientAuthenticationError, HttpResponseError, ResourceExistsError, ResourceNotFoundError, map_error from azure.core.pi...
true
true
f713ff85630f45ddfb90ff880de1b07a38106d1e
1,867
py
Python
plaso/cli/helpers/vfs_backend.py
rgayon/plaso
5f1d0f2da19a28a00ab62c276162483e79a42efb
[ "Apache-2.0" ]
1
2020-12-04T10:26:34.000Z
2020-12-04T10:26:34.000Z
plaso/cli/helpers/vfs_backend.py
dvntaudio/plaso
6debdabbce3619b3210efa2a2cbc91242c02d4e3
[ "Apache-2.0" ]
null
null
null
plaso/cli/helpers/vfs_backend.py
dvntaudio/plaso
6debdabbce3619b3210efa2a2cbc91242c02d4e3
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- """The VFS back-end CLI arguments helper.""" from __future__ import unicode_literals from plaso.cli import tools from plaso.cli.helpers import interface from plaso.cli.helpers import manager from plaso.lib import errors class VFSBackEndArgumentsHelper(interface.ArgumentsHelper): """VFS bac...
32.189655
79
0.705945
from __future__ import unicode_literals from plaso.cli import tools from plaso.cli.helpers import interface from plaso.cli.helpers import manager from plaso.lib import errors class VFSBackEndArgumentsHelper(interface.ArgumentsHelper): NAME = 'vfs_backend' DESCRIPTION = 'dfVFS back-end command line arguments.' ...
true
true
f71401cefe5604f63cb273a6cb7d6715836fee70
2,146
py
Python
fab_deploy/contrib/servers.py
samdolan/django-fab-deploy
642e5cc319f811d4ee647d65388c85988ac887e2
[ "Unlicense" ]
1
2019-08-04T20:54:43.000Z
2019-08-04T20:54:43.000Z
fab_deploy/contrib/servers.py
samdolan/django-fab-deploy
642e5cc319f811d4ee647d65388c85988ac887e2
[ "Unlicense" ]
null
null
null
fab_deploy/contrib/servers.py
samdolan/django-fab-deploy
642e5cc319f811d4ee647d65388c85988ac887e2
[ "Unlicense" ]
null
null
null
from .constants import ALL_ROLES, DB_ROLE, WEB_ROLE from .database import setup_db from .django import update_db, update_python_libs from .nginx import stop_nginx, start_nginx from .ssh import setup_ssh_key from .supervisor import stop_supervisor, start_supervisor, update_supervisor from .utils import get_ip from .webs...
23.582418
82
0.695247
from .constants import ALL_ROLES, DB_ROLE, WEB_ROLE from .database import setup_db from .django import update_db, update_python_libs from .nginx import stop_nginx, start_nginx from .ssh import setup_ssh_key from .supervisor import stop_supervisor, start_supervisor, update_supervisor from .utils import get_ip from .webs...
true
true
f71404e9bb036de5356fa647bf6aa5feffbe1d2a
1,654
py
Python
cog/help.py
tasuren/TunaBot
dd9ecf79280c388bd3b38cb1822b5dbc3666a86c
[ "MIT" ]
1
2021-05-22T07:30:40.000Z
2021-05-22T07:30:40.000Z
cog/help.py
tasuren/TunaBot
dd9ecf79280c388bd3b38cb1822b5dbc3666a86c
[ "MIT" ]
1
2021-12-14T12:24:30.000Z
2021-12-14T12:24:30.000Z
cog/help.py
tasuren/TunaBot
dd9ecf79280c388bd3b38cb1822b5dbc3666a86c
[ "MIT" ]
2
2020-10-25T01:29:16.000Z
2022-02-26T04:49:20.000Z
# TunaBot Ext - Help from discord.ext import commands import discord from aiofiles import open as async_open from ujson import load, loads from data import is_admin JSON_PATH = "data/help.json" class Help(commands.Cog): def __init__(self, bot): self.bot, self.tuna = bot, bot.data with open(JS...
29.017544
83
0.52237
from discord.ext import commands import discord from aiofiles import open as async_open from ujson import load, loads from data import is_admin JSON_PATH = "data/help.json" class Help(commands.Cog): def __init__(self, bot): self.bot, self.tuna = bot, bot.data with open(JSON_PATH, 'r') as f: ...
true
true
f71405186d46fa9050d4b62064a287cfd9e3f822
485
py
Python
main.py
FayasNoushad/Requote-URL-Bot
24f35ba56981d455d7e80a7a3dfb60b1cacb3caa
[ "MIT" ]
5
2021-09-04T06:15:05.000Z
2021-11-28T12:00:35.000Z
main.py
sreeragbot/Requote-URL-Bot
24f35ba56981d455d7e80a7a3dfb60b1cacb3caa
[ "MIT" ]
null
null
null
main.py
sreeragbot/Requote-URL-Bot
24f35ba56981d455d7e80a7a3dfb60b1cacb3caa
[ "MIT" ]
5
2021-09-04T06:45:24.000Z
2022-02-06T18:05:24.000Z
import os from requests.utils import requote_uri from pyrogram import Client, filters Bot = Client( "Requote-URL-Bot", bot_token = os.environ["BOT_TOKEN"], api_id = int(os.environ["API_ID"]), api_hash = os.environ["API_HASH"] ) @Bot.on_message(filters.text) async def filter(bot, update): await u...
20.208333
70
0.676289
import os from requests.utils import requote_uri from pyrogram import Client, filters Bot = Client( "Requote-URL-Bot", bot_token = os.environ["BOT_TOKEN"], api_id = int(os.environ["API_ID"]), api_hash = os.environ["API_HASH"] ) @Bot.on_message(filters.text) async def filter(bot, update): await u...
true
true
f714056b038088a8e129999ae37a63685ffc8967
1,296
py
Python
settings.py
UUDigitalHumanitieslab/historic-hebrew-dates
5ace44d9b1315a96a96ea296383f0b618d994212
[ "BSD-3-Clause" ]
1
2020-06-24T10:29:17.000Z
2020-06-24T10:29:17.000Z
settings.py
UUDigitalHumanitieslab/historic-hebrew-dates
5ace44d9b1315a96a96ea296383f0b618d994212
[ "BSD-3-Clause" ]
11
2019-10-10T08:50:01.000Z
2022-03-02T05:23:55.000Z
settings.py
UUDigitalHumanitieslab/historic-hebrew-dates
5ace44d9b1315a96a96ea296383f0b618d994212
[ "BSD-3-Clause" ]
null
null
null
""" This is magic glue for integrating the frontend and backend. This is NOT the place for backend customizations. Go to api/historic_hebrew_dates_ui/settings.py instead. """ import os.path as op here = op.dirname(op.abspath(__file__)) # First, import the standard backend settings. This requires some # magi...
28.8
97
0.748457
import os.path as op here = op.dirname(op.abspath(__file__)) import sys from importlib import util, machinery settings_name = 'settings' settings_path = op.join(here, 'api', 'historic_hebrew_dates_ui', 'settings.py') if sys.version_info >= (3, 5): spec = util.spec_from_file_location(settings_name, settings_pa...
true
true
f714058cf6804da67a6dd34483c0d76cf1bd23ea
3,828
py
Python
delfin/tests/unit/drivers/dell_emc/vmax/test_alert_handler.py
joseph-v/SIM
61fedb261aa745d715b8a30c0945a6244fb807e2
[ "Apache-2.0" ]
4
2020-04-10T03:48:55.000Z
2020-04-27T07:52:55.000Z
delfin/tests/unit/drivers/dell_emc/vmax/test_alert_handler.py
joseph-v/SIM
61fedb261aa745d715b8a30c0945a6244fb807e2
[ "Apache-2.0" ]
210
2020-05-08T04:06:49.000Z
2020-06-22T12:59:02.000Z
delfin/tests/unit/drivers/dell_emc/vmax/test_alert_handler.py
joseph-v/SIM
61fedb261aa745d715b8a30c0945a6244fb807e2
[ "Apache-2.0" ]
10
2020-04-11T07:09:55.000Z
2020-04-28T09:50:13.000Z
# Copyright 2020 The SODA Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http:#www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writin...
42.533333
79
0.59326
import unittest from oslo_utils import importutils from delfin import exception from delfin.common import constants class AlertHandlerTestCase(unittest.TestCase): ALERT_HANDLER_CLASS = 'delfin.drivers.dell_emc.vmax.alert_handler' \ '.snmp_alerts.AlertHandler' def _get_alert_handl...
true
true
f71409450650072e4b031dd2e4e4906f4cb8d026
12,788
py
Python
recipes/hdf5/all/conanfile.py
dyndrite/conan-center-index
106b5c2f532d5129e7ca1997e29e4e105bb3018c
[ "MIT" ]
1
2021-11-11T03:07:13.000Z
2021-11-11T03:07:13.000Z
recipes/hdf5/all/conanfile.py
dyndrite/conan-center-index
106b5c2f532d5129e7ca1997e29e4e105bb3018c
[ "MIT" ]
null
null
null
recipes/hdf5/all/conanfile.py
dyndrite/conan-center-index
106b5c2f532d5129e7ca1997e29e4e105bb3018c
[ "MIT" ]
null
null
null
from conans import ConanFile, CMake, tools from conans.errors import ConanInvalidConfiguration import functools import os import textwrap required_conan_version = ">=1.43.0" class Hdf5Conan(ConanFile): name = "hdf5" description = "HDF5 is a data model, library, and file format for storing and managing data."...
48.075188
139
0.64451
from conans import ConanFile, CMake, tools from conans.errors import ConanInvalidConfiguration import functools import os import textwrap required_conan_version = ">=1.43.0" class Hdf5Conan(ConanFile): name = "hdf5" description = "HDF5 is a data model, library, and file format for storing and managing data."...
true
true
f71409decc2bf9a049085abd9f2ece5b6c0c08de
1,143
py
Python
event_sourced_bank/domain_model.py
sfinnie/event_sourced_bank
dcec864724e85ac8049a377ee2f6e2c05b1b6a2c
[ "MIT" ]
5
2022-02-17T05:54:49.000Z
2022-03-09T20:13:21.000Z
event_sourced_bank/domain_model.py
sfinnie/event_sourced_bank
dcec864724e85ac8049a377ee2f6e2c05b1b6a2c
[ "MIT" ]
2
2022-02-17T14:19:16.000Z
2022-02-17T14:21:31.000Z
event_sourced_bank/domain_model.py
sfinnie/event_sourced_bank
dcec864724e85ac8049a377ee2f6e2c05b1b6a2c
[ "MIT" ]
1
2022-03-03T05:03:23.000Z
2022-03-03T05:03:23.000Z
from eventsourcing.domain import Aggregate, event from uuid import uuid5, NAMESPACE_URL class Account(Aggregate): """A simple-as-can-be bank account""" @event('Created') def __init__(self): self.balance = 0 @event('Credited') def credit(self, amount: int): self.balance += amount ...
25.4
78
0.637795
from eventsourcing.domain import Aggregate, event from uuid import uuid5, NAMESPACE_URL class Account(Aggregate): @event('Created') def __init__(self): self.balance = 0 @event('Credited') def credit(self, amount: int): self.balance += amount @event('Debited') def debit(self,...
true
true
f71409fcadaa0c4d31744b8e38f76955efffacf1
14,688
py
Python
notion_export_enhancer/enhancer.py
Cobertos/notion-export-enhancer
07a34d4b3daeb1ec69cd4253c089ba4d9dc5bbc3
[ "MIT" ]
17
2021-01-28T11:03:47.000Z
2022-02-10T22:51:44.000Z
notion_export_enhancer/enhancer.py
Cobertos/notion-export-enhancer
07a34d4b3daeb1ec69cd4253c089ba4d9dc5bbc3
[ "MIT" ]
3
2021-03-21T02:35:24.000Z
2021-10-05T07:10:22.000Z
notion_export_enhancer/enhancer.py
Cobertos/notion-export-enhancer
07a34d4b3daeb1ec69cd4253c089ba4d9dc5bbc3
[ "MIT" ]
4
2021-03-21T03:39:36.000Z
2022-01-19T07:05:14.000Z
""" Takes a [Notion.so](https://notion.so) export .zip and enhances it """ import tempfile import sys import os import time import re import argparse import zipfile import urllib.parse from datetime import datetime from pathlib import Path import backoff import requests from emoji_extractor.extract import Extractor as...
45.757009
158
0.701593
import tempfile import sys import os import time import re import argparse import zipfile import urllib.parse from datetime import datetime from pathlib import Path import backoff import requests from emoji_extractor.extract import Extractor as EmojiExtractor from notion.client import NotionClient from notion.block im...
true
true
f7140a3806b353cd7b15d13284304cbfff67879e
5,382
py
Python
examples/old/zipline_alpaca2.py
sherrytp/TradingEvolved
4bc9cc18244954bff37a80f67cce658bd0802b5d
[ "Apache-2.0" ]
null
null
null
examples/old/zipline_alpaca2.py
sherrytp/TradingEvolved
4bc9cc18244954bff37a80f67cce658bd0802b5d
[ "Apache-2.0" ]
null
null
null
examples/old/zipline_alpaca2.py
sherrytp/TradingEvolved
4bc9cc18244954bff37a80f67cce658bd0802b5d
[ "Apache-2.0" ]
1
2022-03-26T07:11:18.000Z
2022-03-26T07:11:18.000Z
# https://github.com/RomanMichaelPaolucci/AI_Stock_Trading/blob/master/IBM.csv import abc import threading import time import pandas as pd import numpy as np from keras.layers import Dense from keras.models import Sequential, model_from_json from sklearn.model_selection import train_test_split from sklearn.metrics impo...
30.40678
78
0.579153
import abc import threading import time import pandas as pd import numpy as np from keras.layers import Dense from keras.models import Sequential, model_from_json from sklearn.model_selection import train_test_split from sklearn.metrics import classification_report from alpaca_trade_api import REST class AlpacaPaperS...
true
true
f7140adcd0356882246b5c8d05e68682363f163a
5,186
py
Python
src/calculator.py
u-aaa/simple_calculator
562231083fca44ffc0825295179af14d30df17bb
[ "MIT" ]
null
null
null
src/calculator.py
u-aaa/simple_calculator
562231083fca44ffc0825295179af14d30df17bb
[ "MIT" ]
null
null
null
src/calculator.py
u-aaa/simple_calculator
562231083fca44ffc0825295179af14d30df17bb
[ "MIT" ]
1
2021-08-17T18:59:53.000Z
2021-08-17T18:59:53.000Z
class Calculator: """" This calculator performs the following basic mathematical operations: * Addition * Subtraction * Division * Multiplication * nth root of number * exponent Attributes ---------- __value : (int or float) the calculator memory value Methods ...
29.299435
122
0.604898
class Calculator: def __init__(self, value = 0) -> None: self.__input_validation(value) self.__value = value def __input_validation(self, new_value: (int, float)) -> None: if not isinstance(new_value, (int,float)): raise NotANumber(new_value) def add(self, new_value:...
true
true
f7140bdb4009f76fa9ca6d9f7fe0d41411f83b25
3,237
py
Python
homeassistant/components/harmony/__init__.py
unverbraucht/core
312af53935a1bffd58b3b35e82e31292a6ec22ad
[ "Apache-2.0" ]
2
2019-11-20T20:56:59.000Z
2021-01-03T08:52:18.000Z
homeassistant/components/harmony/__init__.py
shownor/core
b50281a9173e7fb4a37b3f813ca92876088eaac3
[ "Apache-2.0" ]
5
2020-04-26T10:50:01.000Z
2021-03-16T21:19:46.000Z
homeassistant/components/harmony/__init__.py
winterscar/core
5a55d508791aae65f16396691d014c73fb2095f0
[ "Apache-2.0" ]
1
2021-04-18T19:36:34.000Z
2021-04-18T19:36:34.000Z
"""The Logitech Harmony Hub integration.""" import asyncio import logging from homeassistant.components.remote import ATTR_ACTIVITY, ATTR_DELAY_SECS from homeassistant.config_entries import ConfigEntry from homeassistant.const import CONF_HOST, CONF_NAME from homeassistant.core import HomeAssistant, callback from home...
32.049505
88
0.724745
import asyncio import logging from homeassistant.components.remote import ATTR_ACTIVITY, ATTR_DELAY_SECS from homeassistant.config_entries import ConfigEntry from homeassistant.const import CONF_HOST, CONF_NAME from homeassistant.core import HomeAssistant, callback from homeassistant.exceptions import ConfigEntryNotRe...
true
true
f7140c4bcf3648504d65dea8b56a9087ccad5b5d
16,838
py
Python
src/utils.py
amelieEmily/RobustDARTS
b26e127c6e9c330258786f5eb77b17d367f546ff
[ "Apache-2.0" ]
null
null
null
src/utils.py
amelieEmily/RobustDARTS
b26e127c6e9c330258786f5eb77b17d367f546ff
[ "Apache-2.0" ]
null
null
null
src/utils.py
amelieEmily/RobustDARTS
b26e127c6e9c330258786f5eb77b17d367f546ff
[ "Apache-2.0" ]
null
null
null
import os import yaml import numpy as np import torch import shutil import torchvision.transforms as transforms from torch.autograd import Variable from collections import namedtuple class MyDumper(yaml.Dumper): def increase_indent(self, flow=False, indentless=False): return super(MyDumper, self).increase...
34.646091
90
0.62644
import os import yaml import numpy as np import torch import shutil import torchvision.transforms as transforms from torch.autograd import Variable from collections import namedtuple class MyDumper(yaml.Dumper): def increase_indent(self, flow=False, indentless=False): return super(MyDumper, self).increase...
true
true
f7140cef6c17f8b6d97948c204447446cb386e9d
3,433
py
Python
samples/basic/crud/gnmi/models/cisco-ios-xr/Cisco-IOS-XR-ip-domain-cfg/gn-create-xr-ip-domain-cfg-33-ydk.py
deom119/ydk-py-samples
1ad6cc2b798f358ff835df93d12924df308b85fc
[ "Apache-2.0" ]
104
2016-03-15T17:04:01.000Z
2021-12-31T06:09:35.000Z
samples/basic/crud/gnmi/models/cisco-ios-xr/Cisco-IOS-XR-ip-domain-cfg/gn-create-xr-ip-domain-cfg-33-ydk.py
https-maxus-github-com/ydk-py-samples
1ad6cc2b798f358ff835df93d12924df308b85fc
[ "Apache-2.0" ]
15
2016-03-15T23:09:47.000Z
2020-08-13T12:13:18.000Z
samples/basic/crud/gnmi/models/cisco-ios-xr/Cisco-IOS-XR-ip-domain-cfg/gn-create-xr-ip-domain-cfg-33-ydk.py
https-maxus-github-com/ydk-py-samples
1ad6cc2b798f358ff835df93d12924df308b85fc
[ "Apache-2.0" ]
87
2016-04-15T16:59:23.000Z
2021-09-18T18:05:47.000Z
#!/usr/bin/env python # # Copyright 2016 Cisco Systems, 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 applicab...
32.386792
76
0.665599
from argparse import ArgumentParser from urlparse import urlparse from ydk.path import Repository from ydk.services import CRUDService from ydk.gnmi.providers import gNMIServiceProvider from ydk.models.cisco_ios_xr import Cisco_IOS_XR_ip_domain_cfg \ as xr_ip_domain_cfg import os import logging YDK_REPO_DIR = ...
true
true
f7140d6b0c6c816241055072b9f57a174a01a5af
13,262
py
Python
tests/test_zipreader.py
itsmehara/pysmi
51347f3c4adcc030afb9bc1ded8ce72748068b1b
[ "BSD-2-Clause" ]
121
2016-05-17T14:19:25.000Z
2022-02-03T14:28:25.000Z
tests/test_zipreader.py
itsmehara/pysmi
51347f3c4adcc030afb9bc1ded8ce72748068b1b
[ "BSD-2-Clause" ]
61
2016-05-16T20:45:32.000Z
2022-02-11T22:28:33.000Z
tests/test_zipreader.py
itsmehara/pysmi
51347f3c4adcc030afb9bc1ded8ce72748068b1b
[ "BSD-2-Clause" ]
50
2016-05-16T20:04:51.000Z
2021-11-12T12:14:35.000Z
# # This file is part of pysmi software. # # Copyright (c) 2015-2020, Ilya Etingof <etingof@gmail.com> # License: http://snmplabs.com/pysmi/license.html # import sys import os import tempfile try: import unittest2 as unittest except ImportError: import unittest try: import StringIO except ImportError: ...
59.205357
87
0.454833
import sys import os import tempfile try: import unittest2 as unittest except ImportError: import unittest try: import StringIO except ImportError: from io import StringIO from pysmi.reader.zipreader import ZipReader class ZipReaderTestCase(unittest.TestCase): zipArchive = [ 80, 75, ...
true
true
f7140dc72de40d4e3c5a116bf6731262aa4867da
4,343
py
Python
multiaddr/multiaddr.py
DalavanCloud/py-multiaddr
e1cce8ebacc6f25d0aadc0a913edb5ae2be3ee73
[ "Apache-2.0", "MIT" ]
1
2018-12-24T22:07:47.000Z
2018-12-24T22:07:47.000Z
multiaddr/multiaddr.py
DalavanCloud/py-multiaddr
e1cce8ebacc6f25d0aadc0a913edb5ae2be3ee73
[ "Apache-2.0", "MIT" ]
null
null
null
multiaddr/multiaddr.py
DalavanCloud/py-multiaddr
e1cce8ebacc6f25d0aadc0a913edb5ae2be3ee73
[ "Apache-2.0", "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import binascii from copy import copy from .codec import size_for_addr from .codec import string_to_bytes from .codec import bytes_to_string from .codec import protocol_with_name from .protocols import protocol_with_code from .protocols import read_varint_code class ProtocolNotFoundException(...
31.70073
77
0.593599
import binascii from copy import copy from .codec import size_for_addr from .codec import string_to_bytes from .codec import bytes_to_string from .codec import protocol_with_name from .protocols import protocol_with_code from .protocols import read_varint_code class ProtocolNotFoundException(Exception): pass c...
true
true
f7140dda44b8773a6814740e7a397d7b4ea099ad
223
py
Python
profiles/urls.py
ErnestaMajute/lucentCavern
a98253c5192456637f7af6400eee39cf5363d838
[ "W3C", "PostgreSQL" ]
null
null
null
profiles/urls.py
ErnestaMajute/lucentCavern
a98253c5192456637f7af6400eee39cf5363d838
[ "W3C", "PostgreSQL" ]
null
null
null
profiles/urls.py
ErnestaMajute/lucentCavern
a98253c5192456637f7af6400eee39cf5363d838
[ "W3C", "PostgreSQL" ]
1
2021-07-19T14:29:15.000Z
2021-07-19T14:29:15.000Z
from django.urls import path from . import views urlpatterns = [ path('', views.profile, name='profile'), path( 'order_history/<order_number>', views.order_history, name='order_history'), ]
20.272727
44
0.632287
from django.urls import path from . import views urlpatterns = [ path('', views.profile, name='profile'), path( 'order_history/<order_number>', views.order_history, name='order_history'), ]
true
true
f7140efb0d92fdd73416da8a46ac3e435a8a01e6
3,647
py
Python
autosklearn/data/abstract_data_manager.py
tuggeluk/auto-sklearn
202918e5641701c696b995039d06bfec81973cc6
[ "BSD-3-Clause" ]
1
2017-08-13T13:57:40.000Z
2017-08-13T13:57:40.000Z
autosklearn/data/abstract_data_manager.py
chrinide/auto-sklearn
1c6af59ff61f1d0a3b54b16a35ffbc5d2d3828cd
[ "BSD-3-Clause" ]
null
null
null
autosklearn/data/abstract_data_manager.py
chrinide/auto-sklearn
1c6af59ff61f1d0a3b54b16a35ffbc5d2d3828cd
[ "BSD-3-Clause" ]
1
2020-05-06T14:47:17.000Z
2020-05-06T14:47:17.000Z
# -*- encoding: utf-8 -*- import abc import numpy as np import scipy.sparse from autosklearn.pipeline.implementations.OneHotEncoder import OneHotEncoder from autosklearn.util import predict_RAM_usage def perform_one_hot_encoding(sparse, categorical, data): predicted_RAM_usage = float( predict_RAM_usage(d...
30.391667
79
0.550315
import abc import numpy as np import scipy.sparse from autosklearn.pipeline.implementations.OneHotEncoder import OneHotEncoder from autosklearn.util import predict_RAM_usage def perform_one_hot_encoding(sparse, categorical, data): predicted_RAM_usage = float( predict_RAM_usage(data[0], categorical)) / 10...
true
true
f7140f0751f48afe56cd8ba43fa9cea43551623a
1,042
py
Python
app/core/migrations/0004_recipe.py
devmahmud/recipe-app-api
8cf5cef38e25b6a43b013d4f65b0b8115e27ef10
[ "MIT" ]
1
2020-04-05T12:55:29.000Z
2020-04-05T12:55:29.000Z
app/core/migrations/0004_recipe.py
devmahmud/recipe-app-api
8cf5cef38e25b6a43b013d4f65b0b8115e27ef10
[ "MIT" ]
null
null
null
app/core/migrations/0004_recipe.py
devmahmud/recipe-app-api
8cf5cef38e25b6a43b013d4f65b0b8115e27ef10
[ "MIT" ]
null
null
null
# Generated by Django 3.0.5 on 2020-04-11 04:24 from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('core', '0003_ingredient'), ] operations = [ migrations.CreateModel( ...
35.931034
118
0.603647
from django.conf import settings from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('core', '0003_ingredient'), ] operations = [ migrations.CreateModel( name='Recipe', fields=[ ...
true
true
f7140f27a25c6348d47859e93ebdb50708467af5
3,433
py
Python
travel_blog/travel_blog/settings.py
kennethlove/travel_blog_livestream
a6bc74e99b4922b5ac0d3a8ed0f2d5dbebde6fd2
[ "MIT" ]
2
2016-12-17T02:56:22.000Z
2017-07-19T05:13:59.000Z
travel_blog/travel_blog/settings.py
kennethlove/travel_blog_livestream
a6bc74e99b4922b5ac0d3a8ed0f2d5dbebde6fd2
[ "MIT" ]
null
null
null
travel_blog/travel_blog/settings.py
kennethlove/travel_blog_livestream
a6bc74e99b4922b5ac0d3a8ed0f2d5dbebde6fd2
[ "MIT" ]
1
2018-12-19T06:34:37.000Z
2018-12-19T06:34:37.000Z
""" Django settings for travel_blog project. Generated by 'django-admin startproject' using Django 1.10.1. For more information on this file, see https://docs.djangoproject.com/en/1.10/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/1.10/ref/settings/ """ impor...
26.206107
91
0.694436
import os BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) SECRET_KEY = 'd$^_aoggnuh-=s=kpxb*2qkr+%)^^0cnm8h32h@qq*&1k8*g^l' DEBUG = True ALLOWED_HOSTS = [] # Application definition INSTALLED_APPS = [ 'django.contrib.admin', 'django.contrib.auth', 'django.contrib.contenttypes...
true
true
f714115dff427760c5619baec448dfd0b676ee52
8,961
py
Python
privilege/tests/group.py
luodaihong/django-privilege
1f6a6b410221aa8be109e43326b3a9d7d614287b
[ "Apache-2.0" ]
null
null
null
privilege/tests/group.py
luodaihong/django-privilege
1f6a6b410221aa8be109e43326b3a9d7d614287b
[ "Apache-2.0" ]
null
null
null
privilege/tests/group.py
luodaihong/django-privilege
1f6a6b410221aa8be109e43326b3a9d7d614287b
[ "Apache-2.0" ]
null
null
null
# -*- coding: UTF-8 -*- from django.test import Client, TestCase from django.contrib.auth.models import Group from django.core.cache import cache from django.core.urlresolvers import reverse from django.utils.translation import ugettext as _ from django.utils import simplejson from privilege.core.config import GROUP_...
44.142857
87
0.703828
from django.test import Client, TestCase from django.contrib.auth.models import Group from django.core.cache import cache from django.core.urlresolvers import reverse from django.utils.translation import ugettext as _ from django.utils import simplejson from privilege.core.config import GROUP_CACHE_KEY class GroupT...
true
true
f714119de3a6993ecf4b41e82919d082c69d9996
2,020
py
Python
the-complete-guide-to-bot-creation/batch_renamer/cron_scheudule.py
rulgamer03/Python-Projects
89a2418fadce0fd4674d3f7d3fa682a9aaa4b14d
[ "Apache-2.0" ]
1
2021-06-18T16:29:46.000Z
2021-06-18T16:29:46.000Z
the-complete-guide-to-bot-creation/batch_renamer/cron_scheudule.py
rulgamer03/Python-Projects
89a2418fadce0fd4674d3f7d3fa682a9aaa4b14d
[ "Apache-2.0" ]
null
null
null
the-complete-guide-to-bot-creation/batch_renamer/cron_scheudule.py
rulgamer03/Python-Projects
89a2418fadce0fd4674d3f7d3fa682a9aaa4b14d
[ "Apache-2.0" ]
null
null
null
import os import time from pathlib import Path # from path home import schedule print(Path.home()) # C:\Users\angel old_files_folder_name = "old_files" print("Hello ") def clean_up_downloads(): print("Cleaning up Downloads") # get all items from the downloads filder download_folder_path = os.path.join(P...
34.827586
105
0.719802
import os import time from pathlib import Path import schedule print(Path.home()) old_files_folder_name = "old_files" print("Hello ") def clean_up_downloads(): print("Cleaning up Downloads") download_folder_path = os.path.join(Path.home(), "Downloads", "Downloads") download_items = os.listdir(downl...
true
true
f71411da7bac62abcff4bebab8f8c05a980019ae
34,992
py
Python
tests/test_types.py
gertjanvanzwieten/nutils
ec04d66e4797398496453181f96b14ad2edae228
[ "MIT" ]
null
null
null
tests/test_types.py
gertjanvanzwieten/nutils
ec04d66e4797398496453181f96b14ad2edae228
[ "MIT" ]
null
null
null
tests/test_types.py
gertjanvanzwieten/nutils
ec04d66e4797398496453181f96b14ad2edae228
[ "MIT" ]
null
null
null
from nutils.testing import * import nutils.types import inspect, pickle, itertools, ctypes, stringly, tempfile, io, os import numpy class apply_annotations(TestCase): def test_without_annotations(self): @nutils.types.apply_annotations def f(a, b): return a, b a, b = f(1, 2) self.assertEqual(a,...
34.714286
165
0.658551
from nutils.testing import * import nutils.types import inspect, pickle, itertools, ctypes, stringly, tempfile, io, os import numpy class apply_annotations(TestCase): def test_without_annotations(self): @nutils.types.apply_annotations def f(a, b): return a, b a, b = f(1, 2) self.assertEqual(a,...
true
true
f7141225b2cad5e68e436f1ea8c5e6741e83043d
1,244
py
Python
DATA_SORT/3cities/SCAM/outputcesmscam_TREFHT_CLM5_CLM5F_001.py
islasimpson/snowpaper_2022
d6ee677f696d7fd6e7cadef8168ce4fd8b184cac
[ "Apache-2.0" ]
null
null
null
DATA_SORT/3cities/SCAM/outputcesmscam_TREFHT_CLM5_CLM5F_001.py
islasimpson/snowpaper_2022
d6ee677f696d7fd6e7cadef8168ce4fd8b184cac
[ "Apache-2.0" ]
null
null
null
DATA_SORT/3cities/SCAM/outputcesmscam_TREFHT_CLM5_CLM5F_001.py
islasimpson/snowpaper_2022
d6ee677f696d7fd6e7cadef8168ce4fd8b184cac
[ "Apache-2.0" ]
null
null
null
import importlib import xarray as xr import numpy as np import pandas as pd import sys from CASutils import filter_utils as filt from CASutils import readdata_utils as read from CASutils import calendar_utils as cal importlib.reload(filt) importlib.reload(read) importlib.reload(cal) expname=['SASK_CLM5_CLM5F_01.001...
29.619048
88
0.696945
import importlib import xarray as xr import numpy as np import pandas as pd import sys from CASutils import filter_utils as filt from CASutils import readdata_utils as read from CASutils import calendar_utils as cal importlib.reload(filt) importlib.reload(read) importlib.reload(cal) expname=['SASK_CLM5_CLM5F_01.001...
true
true
f714129360782fdce2e19567a3deb3c965cf7a55
5,386
py
Python
chapter2/intogen-arrays/src/biomart/ent_exp.py
chris-zen/phd-thesis
1eefdff8e7ca1910304e27ae42551dc64496b101
[ "Unlicense" ]
1
2015-12-22T00:53:18.000Z
2015-12-22T00:53:18.000Z
chapter2/intogen-arrays/src/biomart/ent_exp.py
chris-zen/phd-thesis
1eefdff8e7ca1910304e27ae42551dc64496b101
[ "Unlicense" ]
null
null
null
chapter2/intogen-arrays/src/biomart/ent_exp.py
chris-zen/phd-thesis
1eefdff8e7ca1910304e27ae42551dc64496b101
[ "Unlicense" ]
null
null
null
#!/usr/bin/env python """ Import experiments into the database * Configuration parameters: - The ones required by intogen.data.entity.EntityManagerFactory """ from wok.task import Task from wok.element import DataElementList from intogen.data.entity import types from intogen.data.entity.server import EntityServer ...
30.602273
132
0.690123
from wok.task import Task from wok.element import DataElementList from intogen.data.entity import types from intogen.data.entity.server import EntityServer from intogen.biomart import biomart_db_connect, DEFAULT_INSERT_SIZE, DEFAULT_DB_ENGINE from intogen.sql import BatchInsert from pubmed import Pubmed task = Task...
true
true
f714170b4a34daae5309a0afed9dc4fc7ef8fc70
1,331
py
Python
app/core/tests/test_models.py
Aqurds/django-rest-api
685215f05c1eba8a7ef64f3f49dbd33465544099
[ "MIT" ]
null
null
null
app/core/tests/test_models.py
Aqurds/django-rest-api
685215f05c1eba8a7ef64f3f49dbd33465544099
[ "MIT" ]
null
null
null
app/core/tests/test_models.py
Aqurds/django-rest-api
685215f05c1eba8a7ef64f3f49dbd33465544099
[ "MIT" ]
null
null
null
from django.test import TestCase from django.contrib.auth import get_user_model class ModelTests(TestCase): def test_create_user_with_email_successful(self): """Test creating a new user with email """ email = "test@aqurds.com" password = "aqurds123" user = get_user_model().objects...
35.026316
79
0.681443
from django.test import TestCase from django.contrib.auth import get_user_model class ModelTests(TestCase): def test_create_user_with_email_successful(self): email = "test@aqurds.com" password = "aqurds123" user = get_user_model().objects.create_user(email, password) self.assertE...
true
true
f714177fea775d7ec4d451e8fd295b515bc257fe
14,092
py
Python
hddcoin/hodl/val.py
u4ma-hdd/hddcoin-blockchain
4199d1f1d87e129ae9c08bf50dd48ec3b2c08727
[ "Apache-2.0" ]
37
2021-07-08T23:42:01.000Z
2022-03-26T21:30:10.000Z
hddcoin/hodl/val.py
u4ma-hdd/hddcoin-blockchain
4199d1f1d87e129ae9c08bf50dd48ec3b2c08727
[ "Apache-2.0" ]
13
2021-07-11T15:12:01.000Z
2022-03-15T08:36:18.000Z
hddcoin/hodl/val.py
u4ma-hdd/hddcoin-blockchain
4199d1f1d87e129ae9c08bf50dd48ec3b2c08727
[ "Apache-2.0" ]
19
2021-07-10T14:09:07.000Z
2022-03-14T11:17:05.000Z
# -*- coding: utf-8 -*- # NOTES: # - this file is all about the trust model for the HODL contracts. TRUST NO ONE. VALIDATE ALL. from __future__ import annotations import dataclasses import decimal import re import time import typing as th import hddcoin.hodl from clvm_tools.binutils import disassemble, int_to_bytes ...
51.057971
100
0.648027
from __future__ import annotations import dataclasses import decimal import re import time import typing as th import hddcoin.hodl from clvm_tools.binutils import disassemble, int_to_bytes from hddcoin.hodl import exc as exc from hddcoin.hodl.ContractDetails import ContractDetails from hddcoin.hodl.util import vlog, ...
true
true
f71417e1074609cbc2856e5c9c5709dab7cdcb5e
114
py
Python
django_filtersmerger/apps.py
MPASolutions/django-filtersmerger
9a209af142a5be15b79cb7025fdf771dac3aec35
[ "MIT" ]
null
null
null
django_filtersmerger/apps.py
MPASolutions/django-filtersmerger
9a209af142a5be15b79cb7025fdf771dac3aec35
[ "MIT" ]
null
null
null
django_filtersmerger/apps.py
MPASolutions/django-filtersmerger
9a209af142a5be15b79cb7025fdf771dac3aec35
[ "MIT" ]
null
null
null
from django.apps import AppConfig class DjangoFiltersMergerConfig(AppConfig): name = 'django_filtersmerger'
19
43
0.807018
from django.apps import AppConfig class DjangoFiltersMergerConfig(AppConfig): name = 'django_filtersmerger'
true
true
f7141a61052156f4da421af60a3f48ccdefcac14
103
py
Python
KulliSharif/KulliSharifapp/apps.py
iqran-star/API-PROJECT
77d021098fd17b4ce086f8e6f914a7722fa9b558
[ "MIT" ]
null
null
null
KulliSharif/KulliSharifapp/apps.py
iqran-star/API-PROJECT
77d021098fd17b4ce086f8e6f914a7722fa9b558
[ "MIT" ]
null
null
null
KulliSharif/KulliSharifapp/apps.py
iqran-star/API-PROJECT
77d021098fd17b4ce086f8e6f914a7722fa9b558
[ "MIT" ]
null
null
null
from django.apps import AppConfig class KullisharifappConfig(AppConfig): name = 'KulliSharifapp'
17.166667
38
0.786408
from django.apps import AppConfig class KullisharifappConfig(AppConfig): name = 'KulliSharifapp'
true
true
f7141cc9e45ecbc5219b86989037c927da949950
16,052
py
Python
owslib/fes2.py
vjf/OWSLib
9a3768c3cae21cb9a30dc4437259dfaa8dde1118
[ "BSD-3-Clause" ]
null
null
null
owslib/fes2.py
vjf/OWSLib
9a3768c3cae21cb9a30dc4437259dfaa8dde1118
[ "BSD-3-Clause" ]
null
null
null
owslib/fes2.py
vjf/OWSLib
9a3768c3cae21cb9a30dc4437259dfaa8dde1118
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: ISO-8859-15 -*- # ============================================================================= # Copyright (c) 2021 Tom Kralidis # # Authors : Tom Kralidis <tomkralidis@gmail.com> # # Contact email: tomkralidis@gmail.com # ============================================================================= """...
36.56492
119
0.637989
from owslib.etree import etree from owslib import util from owslib.namespaces import Namespaces def get_namespaces(): n = Namespaces() ns = n.get_namespaces(["dif", "fes", "gml", "ogc", "ows110", "xs", "xsi"]) ns[None] = n.get_namespace("fes") return ns namespaces = get_namespaces() schema = 'http...
true
true
f7141cf967ed30a0143ab32103399d5b149ab436
361
py
Python
users/migrations/0002_alter_user_options.py
JeffreyDrJ/myfirstblog
5b1f0fbd6c85027bad7d0e24d67251f41da53fac
[ "MIT" ]
null
null
null
users/migrations/0002_alter_user_options.py
JeffreyDrJ/myfirstblog
5b1f0fbd6c85027bad7d0e24d67251f41da53fac
[ "MIT" ]
1
2021-05-29T17:09:43.000Z
2021-05-29T17:09:43.000Z
users/migrations/0002_alter_user_options.py
JeffreyDrJ/myfirstblog
5b1f0fbd6c85027bad7d0e24d67251f41da53fac
[ "MIT" ]
null
null
null
# Generated by Django 3.2 on 2021-05-05 06:00 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('users', '0001_initial'), ] operations = [ migrations.AlterModelOptions( name='user', options={'verbose_name': '用户管理', 'verbose...
20.055556
76
0.592798
from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('users', '0001_initial'), ] operations = [ migrations.AlterModelOptions( name='user', options={'verbose_name': '用户管理', 'verbose_name_plural': '用户管理'}, ), ]
true
true
f7141de0498279619548f98c6c2bc7c8730633e4
4,876
py
Python
test/mitmproxy/io/test_tnetstring.py
0x7c48/mitmproxy
f9d8f3bae3f4e681d5f4d406b7e06b099e60ecba
[ "MIT" ]
74
2016-03-20T17:39:26.000Z
2020-05-12T13:53:23.000Z
test/mitmproxy/io/test_tnetstring.py
0x7c48/mitmproxy
f9d8f3bae3f4e681d5f4d406b7e06b099e60ecba
[ "MIT" ]
7
2020-06-16T06:35:02.000Z
2022-03-15T20:15:53.000Z
test/mitmproxy/io/test_tnetstring.py
0x7c48/mitmproxy
f9d8f3bae3f4e681d5f4d406b7e06b099e60ecba
[ "MIT" ]
5
2016-12-14T14:56:57.000Z
2020-03-08T20:58:31.000Z
import unittest import random import math import io import struct from mitmproxy.io import tnetstring MAXINT = 2 ** (struct.Struct('i').size * 8 - 1) - 1 FORMAT_EXAMPLES = { b'0:}': {}, b'0:]': [], b'51:5:hello,39:11:12345678901#4:this,4:true!0:~4:\x00\x00\x00\x00,]}': {b'hello': [12345678901, b'this...
35.333333
381
0.553322
import unittest import random import math import io import struct from mitmproxy.io import tnetstring MAXINT = 2 ** (struct.Struct('i').size * 8 - 1) - 1 FORMAT_EXAMPLES = { b'0:}': {}, b'0:]': [], b'51:5:hello,39:11:12345678901#4:this,4:true!0:~4:\x00\x00\x00\x00,]}': {b'hello': [12345678901, b'this...
true
true
f7141ebf7eb8ca97831794cbe3f70aa8721341b7
2,217
py
Python
examples/gbml_omniglot.py
Renovamen/metallic
c3992e4b322f9d41d9b7997c472baf99c843046c
[ "MIT" ]
5
2021-04-14T07:31:06.000Z
2021-12-11T08:12:10.000Z
examples/gbml_omniglot.py
Renovamen/metallic
c3992e4b322f9d41d9b7997c472baf99c843046c
[ "MIT" ]
1
2021-04-14T07:44:36.000Z
2021-04-15T14:01:52.000Z
examples/gbml_omniglot.py
Renovamen/metallic
c3992e4b322f9d41d9b7997c472baf99c843046c
[ "MIT" ]
null
null
null
import os import sys base_path = os.path.abspath(os.path.join(os.path.dirname(__file__), '..')) sys.path.append(base_path) from torch import optim from metallic.data.benchmarks import get_benchmarks from metallic.data.dataloader import MetaDataLoader from metallic.models import OmniglotCNN from metallic.metalearners...
25.482759
86
0.664862
import os import sys base_path = os.path.abspath(os.path.join(os.path.dirname(__file__), '..')) sys.path.append(base_path) from torch import optim from metallic.data.benchmarks import get_benchmarks from metallic.data.dataloader import MetaDataLoader from metallic.models import OmniglotCNN from metallic.metalearners...
true
true
f7141ff71ab7ab9a6756e73b6c2e968a45ebb526
2,637
py
Python
workshops/migrations/0049_auto_20150916_0544.py
tracykteal/amy
cb19e318d36b880b1c3be2104efff42ef776118a
[ "MIT" ]
1
2015-04-03T20:26:56.000Z
2015-04-03T20:26:56.000Z
workshops/migrations/0049_auto_20150916_0544.py
tracykteal/amy
cb19e318d36b880b1c3be2104efff42ef776118a
[ "MIT" ]
1
2019-12-13T11:22:47.000Z
2019-12-13T11:22:47.000Z
workshops/migrations/0049_auto_20150916_0544.py
tracykteal/amy
cb19e318d36b880b1c3be2104efff42ef776118a
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations class Migration(migrations.Migration): dependencies = [ ('workshops', '0048_auto_20150916_0441'), ] operations = [ migrations.AlterField( model_name='person', ...
52.74
629
0.628366
from __future__ import unicode_literals from django.db import models, migrations class Migration(migrations.Migration): dependencies = [ ('workshops', '0048_auto_20150916_0441'), ] operations = [ migrations.AlterField( model_name='person', name='gender', ...
true
true
f714200e0fceaf12937e196c4653e7f5a945e815
2,657
bzl
Python
pkg/tests/path_test.bzl
hborawski/rules_pkg
8d542763a3959db79175404758f46c7f3f385fa5
[ "Apache-2.0" ]
null
null
null
pkg/tests/path_test.bzl
hborawski/rules_pkg
8d542763a3959db79175404758f46c7f3f385fa5
[ "Apache-2.0" ]
null
null
null
pkg/tests/path_test.bzl
hborawski/rules_pkg
8d542763a3959db79175404758f46c7f3f385fa5
[ "Apache-2.0" ]
null
null
null
# Copyright 2021 The Bazel 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 applicable la...
28.880435
78
0.637938
load("@bazel_skylib//lib:unittest.bzl", "analysistest", "asserts", "unittest") load("//:mappings.bzl", "pkg_mkdirs") load("//:path.bzl", "compute_data_path") def _compute_data_path_test_impl(ctx): env = analysistest.begin(ctx) target_under_test = analysistest.target_under_test(env) expect = ctx.a...
true
true
f71421b82991b2284752df5cbc3abe620e97baaf
8,509
py
Python
tests/test_version.py
dfroger/conda
c0f99ff46b217d081501e66f4dcd7bcdb5d9c6aa
[ "BSD-3-Clause" ]
null
null
null
tests/test_version.py
dfroger/conda
c0f99ff46b217d081501e66f4dcd7bcdb5d9c6aa
[ "BSD-3-Clause" ]
null
null
null
tests/test_version.py
dfroger/conda
c0f99ff46b217d081501e66f4dcd7bcdb5d9c6aa
[ "BSD-3-Clause" ]
null
null
null
from __future__ import print_function, absolute_import import unittest from conda.version import ver_eval, VersionSpec, VersionOrder, normalized_version class TestVersionSpec(unittest.TestCase): def test_version_order(self): versions = [ (VersionOrder("0.4"), [[0], [0], [4]]), ...
50.349112
104
0.466212
from __future__ import print_function, absolute_import import unittest from conda.version import ver_eval, VersionSpec, VersionOrder, normalized_version class TestVersionSpec(unittest.TestCase): def test_version_order(self): versions = [ (VersionOrder("0.4"), [[0], [0], [4]]), ...
true
true
f7142361616cc1d896aba889094e5bdfd2013e97
178
py
Python
frederic/hello_world.py
infelane/python-for-java-devs
56f313f89ad8603598f879f31e0d9a35795e50e3
[ "Apache-2.0" ]
1
2019-10-20T16:05:30.000Z
2019-10-20T16:05:30.000Z
frederic/hello_world.py
infelane/python-for-java-devs
56f313f89ad8603598f879f31e0d9a35795e50e3
[ "Apache-2.0" ]
1
2020-07-10T09:09:58.000Z
2020-07-10T09:09:58.000Z
frederic/hello_world.py
infelane/python-for-java-devs
56f313f89ad8603598f879f31e0d9a35795e50e3
[ "Apache-2.0" ]
3
2020-07-10T07:46:51.000Z
2022-02-21T08:58:45.000Z
import logging def say(n): logging.basicConfig(level=logging.DEBUG) for i in range(n): logging.info(str(i) + ": Hello world") say(1) if __name__=="__main__": say(3)
14.833333
42
0.662921
import logging def say(n): logging.basicConfig(level=logging.DEBUG) for i in range(n): logging.info(str(i) + ": Hello world") say(1) if __name__=="__main__": say(3)
true
true
f71423f13ea7f981319138912b683e99f21321aa
3,285
py
Python
invenio_assets/npm.py
pazembrz/invenio-assets
dd9acd8f0bf1a10eb2593949d9f1b6cc6d95ef43
[ "MIT" ]
1
2018-10-24T11:17:30.000Z
2018-10-24T11:17:30.000Z
invenio_assets/npm.py
okraskaj/invenio-assets
e0f48743982d16cffa312fa9fe392c62db906d89
[ "MIT" ]
null
null
null
invenio_assets/npm.py
okraskaj/invenio-assets
e0f48743982d16cffa312fa9fe392c62db906d89
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # # This file is part of Invenio. # Copyright (C) 2015-2018 CERN. # # Invenio is free software; you can redistribute it and/or modify it # under the terms of the MIT License; see LICENSE file for more details. """Bundle class with support for npm dependencies.""" from __future__ import absolut...
27.605042
73
0.635616
from __future__ import absolute_import, print_function from collections import defaultdict import semver from flask_assets import Bundle as BundleBase from pkg_resources import parse_version from speaklater import is_lazy_string __all__ = ('LazyNpmBundle', 'NpmBundle', 'extract_deps', 'make_semver', ) class NpmB...
true
true
f7142447c41c8ccca6568a1c6a262abb22071efc
2,371
py
Python
geometry/matrix.py
GuillaumeRochette/HumanViewSynthesis
d65ea8744e284ec956bbc04f294f05e47731360f
[ "Apache-2.0" ]
10
2021-11-30T05:56:10.000Z
2022-03-16T07:06:16.000Z
geometry/matrix.py
GuillaumeRochette/Reconstruction3D
358d9cb55486ad0f81a31df8ab4159153765e7e5
[ "Apache-2.0" ]
1
2022-01-10T09:27:22.000Z
2022-01-10T09:27:22.000Z
geometry/matrix.py
GuillaumeRochette/Reconstruction3D
358d9cb55486ad0f81a31df8ab4159153765e7e5
[ "Apache-2.0" ]
null
null
null
from typing import Tuple import torch from torch import Tensor def homogeneous(A: Tensor, b: Tensor) -> Tensor: """ Converts heterogeneous matrix into homogeneous matrix. :param A: Heterogeneous matrix of shape [*, N, N]. :param b: Heterogeneous vector of shape [*, N, 1]. :return: Homogeneous mat...
25.223404
92
0.547027
from typing import Tuple import torch from torch import Tensor def homogeneous(A: Tensor, b: Tensor) -> Tensor: assert A.shape[:-2] == b.shape[:-2] assert A.shape[-2] == A.shape[-1] == b.shape[-2] assert b.shape[-1] == 1 s, n = A.shape[:-2], A.shape[-2] c = torch.zeros(s + (1, n), dtype=A.dtype,...
true
true
f714244989fbad4476876ccb83e7dfefdbb4a895
1,275
py
Python
hardware/ci/build.py
Axford/AFRo
e57369c2d37e6001587cd37307d36c5f9f112c53
[ "MIT" ]
null
null
null
hardware/ci/build.py
Axford/AFRo
e57369c2d37e6001587cd37307d36c5f9f112c53
[ "MIT" ]
null
null
null
hardware/ci/build.py
Axford/AFRo
e57369c2d37e6001587cd37307d36c5f9f112c53
[ "MIT" ]
null
null
null
#!/usr/bin/env python # Run the various build scripts import sys import os from parse import parse_machines from machines import machines from assemblies import assemblies from vitamins import vitamins from printed import printed from guides import guides from publish import publish def build(do_publish=0): prin...
22.368421
65
0.620392
import sys import os from parse import parse_machines from machines import machines from assemblies import assemblies from vitamins import vitamins from printed import printed from guides import guides from publish import publish def build(do_publish=0): print("Build") print("-----") outfile = 'hard...
true
true
f7142459f0d44ac68274d37d43ee06f916581229
301
py
Python
kai/model/__init__.py
Pylons/kai
8c843bdb7508a25dea094fdd38bd5b5cc521d486
[ "BSD-3-Clause" ]
1
2021-04-27T19:13:28.000Z
2021-04-27T19:13:28.000Z
kai/model/__init__.py
Pylons/kai
8c843bdb7508a25dea094fdd38bd5b5cc521d486
[ "BSD-3-Clause" ]
null
null
null
kai/model/__init__.py
Pylons/kai
8c843bdb7508a25dea094fdd38bd5b5cc521d486
[ "BSD-3-Clause" ]
null
null
null
"""CouchDB Models""" from kai.model.blog import Article from kai.model.documentation import Documentation from kai.model.generics import Comment, Rating from kai.model.human import Human from kai.model.paste import Paste from kai.model.snippet import Snippet from kai.model.traceback import Traceback
33.444444
49
0.827243
from kai.model.blog import Article from kai.model.documentation import Documentation from kai.model.generics import Comment, Rating from kai.model.human import Human from kai.model.paste import Paste from kai.model.snippet import Snippet from kai.model.traceback import Traceback
true
true
f714245b3cc1fcb188d83f0e5b42aacd5f5699f1
1,095
py
Python
beautiful_earth/app/routes.py
craklyn/space-apps-2019
f0a7e28907b9471b207d75eb840b1bd27ef99547
[ "MIT" ]
6
2021-08-16T14:48:30.000Z
2022-01-25T01:06:03.000Z
beautiful_earth/app/routes.py
craklyn/space-apps-2019
f0a7e28907b9471b207d75eb840b1bd27ef99547
[ "MIT" ]
3
2021-06-08T20:29:10.000Z
2022-03-12T00:02:34.000Z
beautiful_earth/app/routes.py
craklyn/space-apps-2019
f0a7e28907b9471b207d75eb840b1bd27ef99547
[ "MIT" ]
1
2019-10-21T05:42:25.000Z
2019-10-21T05:42:25.000Z
from flask import render_template from flask import request from flask import send_file from flask import make_response import cv2 import urllib import numpy as np # Add the pytorch folder to our script path import sys # insert at 1, 0 is the script path (or '' in REPL) sys.path.insert(1, '/Users/danielblackburn/space...
28.076923
121
0.734247
from flask import render_template from flask import request from flask import send_file from flask import make_response import cv2 import urllib import numpy as np import sys sys.path.insert(1, '/Users/danielblackburn/space-apps-2019/beautiful_earth/pytorch-CycleGAN-and-pix2pix') import inference from inference impor...
true
true
f71424d21246fe49464870c05f4d12121a8e0237
79,831
py
Python
core/domain/user_services.py
AbhinavGopal/oppiabackup
e5ae39b20623d4389885802d670b0142d82034ea
[ "Apache-2.0" ]
1
2022-02-22T09:27:22.000Z
2022-02-22T09:27:22.000Z
core/domain/user_services.py
IMADILKHAN/oppia
454bf732dfd0087bcc0b8b7cd65d80ba386f4929
[ "Apache-2.0" ]
null
null
null
core/domain/user_services.py
IMADILKHAN/oppia
454bf732dfd0087bcc0b8b7cd65d80ba386f4929
[ "Apache-2.0" ]
null
null
null
# coding: utf-8 # # Copyright 2014 The Oppia 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 requi...
39.075379
5,138
0.710539
from __future__ import absolute_import from __future__ import unicode_literals import datetime import hashlib import imghdr import logging import re from constants import constants from core.domain import role_services from core.domain import user_domain from core.platform import models import feconf import pytho...
true
true
f7142608165d85e92bb7ae364ff06ed93053dee8
7,827
py
Python
python/scripts/traj_gen/chomp_trajectory.py
tomcattigerkkk/traj_gen
d01882c17d8e979860fb1f09defa968a86adb494
[ "MIT" ]
null
null
null
python/scripts/traj_gen/chomp_trajectory.py
tomcattigerkkk/traj_gen
d01882c17d8e979860fb1f09defa968a86adb494
[ "MIT" ]
null
null
null
python/scripts/traj_gen/chomp_trajectory.py
tomcattigerkkk/traj_gen
d01882c17d8e979860fb1f09defa968a86adb494
[ "MIT" ]
null
null
null
#!/usr/bin/env python # coding=utf-8 from .traj_gen_base import TrajGen import numpy as np import casadi as ca from scipy.interpolate import interp1d class CHOMPTrajGen(TrajGen): def __init__(self, knots_, dim_, pntDensity_): super().__init__(knots_, dim_) self.pntDensity = pntDensity_ asse...
39.530303
157
0.505302
from .traj_gen_base import TrajGen import numpy as np import casadi as ca from scipy.interpolate import interp1d class CHOMPTrajGen(TrajGen): def __init__(self, knots_, dim_, pntDensity_): super().__init__(knots_, dim_) self.pntDensity = pntDensity_ assert knots_.shape[0]==2, 'For optimalTr...
true
true
f71428346cb81628139bf8ea3efe2d5d9ce53196
1,858
py
Python
setup.py
infosmith/batteries
e1e018043392997ec43f55f874231d5feb684110
[ "MIT" ]
null
null
null
setup.py
infosmith/batteries
e1e018043392997ec43f55f874231d5feb684110
[ "MIT" ]
2
2022-01-04T06:14:09.000Z
2022-01-04T09:18:14.000Z
setup.py
infosmith/helpers
e1e018043392997ec43f55f874231d5feb684110
[ "MIT" ]
null
null
null
"""Package setup script.""" from setuptools import setup, find_packages # Python packaging constants CLASSIFIERS = [ 'Development Status :: 2 - Pre-Alpha', 'Intended Audience :: Developers', 'Natural Language :: English', 'Programming Language :: Python :: 3', 'Programming Language :: Python :: 3....
29.03125
74
0.678149
from setuptools import setup, find_packages CLASSIFIERS = [ 'Development Status :: 2 - Pre-Alpha', 'Intended Audience :: Developers', 'Natural Language :: English', 'Programming Language :: Python :: 3', 'Programming Language :: Python :: 3.4', 'Programming Language :: Python :: 3.5', 'Pro...
true
true
f71428e49e034b578ef70ffe2a26d9dc7901f807
403
py
Python
DiscordOauth2/wsgi.py
TShoKT/Django-DiscordOauth2
2deab89d4bbb0f36ef405e8f29f689525df479e2
[ "MIT" ]
4
2021-09-01T10:55:06.000Z
2022-02-07T16:37:22.000Z
DiscordOauth2/wsgi.py
TShoKT/Django-DiscordOauth2
2deab89d4bbb0f36ef405e8f29f689525df479e2
[ "MIT" ]
1
2021-10-03T09:45:05.000Z
2021-10-06T18:20:17.000Z
DiscordOauth2/wsgi.py
TShoKT/Django-DiscordOauth2
2deab89d4bbb0f36ef405e8f29f689525df479e2
[ "MIT" ]
3
2021-09-11T18:49:33.000Z
2021-12-28T16:49:42.000Z
""" WSGI config for DiscordOauth2 project. It exposes the WSGI callable as a module-level variable named ``application``. For more information on this file, see https://docs.djangoproject.com/en/3.2/howto/deployment/wsgi/ """ import os from django.core.wsgi import get_wsgi_application os.environ.setdefault('DJANGO...
23.705882
78
0.791563
import os from django.core.wsgi import get_wsgi_application os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'DiscordOauth2.settings') application = get_wsgi_application()
true
true
f7142941df2d1fb97ae8bcfca78c1126c1828d24
5,515
py
Python
docs/cornell CS class/Lesson 29. Coroutines/demos/animate3.py
LizzieDeng/kalman_fliter_analysis
50e728f32c496c3fcbb8ca3ee00857b999b88d99
[ "MIT" ]
null
null
null
docs/cornell CS class/Lesson 29. Coroutines/demos/animate3.py
LizzieDeng/kalman_fliter_analysis
50e728f32c496c3fcbb8ca3ee00857b999b88d99
[ "MIT" ]
null
null
null
docs/cornell CS class/Lesson 29. Coroutines/demos/animate3.py
LizzieDeng/kalman_fliter_analysis
50e728f32c496c3fcbb8ca3ee00857b999b88d99
[ "MIT" ]
null
null
null
""" A module to show off a timed animation using coroutines Making timed animations is messy, because we have to add a lot of class attributes for all of the loop variables. A cleaner way is to do this with coroutines. Each animation is its own coroutine. The advantage of the coroutine is that yield allows you to p...
32.827381
84
0.616863
import introcs import random import math from game2d import * import time import random WINDOW_WIDTH = 512 WINDOW_HEIGHT = 512 ANIMATION_SPEED = 1 class Animation(GameApp): def start(self): self.image = GImage(x=WINDOW_WIDTH/2,y=WINDOW_HEIGHT/2,source='Walker.png') self.image.angl...
true
true
f7142aa0459addf88df1549845b063ae44233e96
5,200
py
Python
azure-devops/azext_devops/vstsCompressed/models/models.py
vijayraavi/azure-devops-cli-extension
88f1420c5815cb09bea15b050f4c553e0f326dad
[ "MIT" ]
null
null
null
azure-devops/azext_devops/vstsCompressed/models/models.py
vijayraavi/azure-devops-cli-extension
88f1420c5815cb09bea15b050f4c553e0f326dad
[ "MIT" ]
37
2020-04-27T07:45:19.000Z
2021-04-05T07:27:15.000Z
azure-devops/azext_devops/vstsCompressed/models/models.py
vijayraavi/azure-devops-cli-extension
88f1420c5815cb09bea15b050f4c553e0f326dad
[ "MIT" ]
null
null
null
# -------------------------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # --------------------------------------------------------------------...
32.911392
104
0.59
from msrest.serialization import Model class ApiResourceLocation(Model): _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'area': {'key': 'area', 'type': 'str'}, 'resource_name': {'key': 'resourceName', 'type': 'str'}, 'route_template': {'key': 'routeTemplate', 'type': 'st...
true
true
f7142b7c798ada6e8b0a89e5f7341c459d5053a1
6,028
py
Python
client.py
ElianMariano/Sistema-de-Trocas
a1caf6a1503cfa7a81fd48fbe81f19fd91f0eb3c
[ "MIT" ]
null
null
null
client.py
ElianMariano/Sistema-de-Trocas
a1caf6a1503cfa7a81fd48fbe81f19fd91f0eb3c
[ "MIT" ]
null
null
null
client.py
ElianMariano/Sistema-de-Trocas
a1caf6a1503cfa7a81fd48fbe81f19fd91f0eb3c
[ "MIT" ]
null
null
null
#from lib2to3.pytree import convert import socket import sys import _thread import json import os import time import zmq IP_ADDRESS = '127.0.0.1' TOPIC = None fila_msgs = [] conf = [] # Envia os dados def enviar(): ctx = zmq.Context() sock = ctx.socket(zmq.PUB) sock.connect(f"tcp://{IP_ADDRESS}:5500") ...
30.291457
62
0.503152
import socket import sys import _thread import json import os import time import zmq IP_ADDRESS = '127.0.0.1' TOPIC = None fila_msgs = [] conf = [] def enviar(): ctx = zmq.Context() sock = ctx.socket(zmq.PUB) sock.connect(f"tcp://{IP_ADDRESS}:5500") codigo = 5 while True: if(len(fila_...
true
true
f7142c06ba23c1277d4a118307c17e2599d7a4f9
8,434
py
Python
third_party/tlslite/tlslite/utils/cryptomath.py
zealoussnow/chromium
fd8a8914ca0183f0add65ae55f04e287543c7d4a
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
575
2015-06-18T23:58:20.000Z
2022-03-23T09:32:39.000Z
third_party/tlslite/tlslite/utils/cryptomath.py
zealoussnow/chromium
fd8a8914ca0183f0add65ae55f04e287543c7d4a
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
113
2015-05-04T09:58:14.000Z
2022-01-31T19:35:03.000Z
third_party/tlslite/tlslite/utils/cryptomath.py
zealoussnow/chromium
fd8a8914ca0183f0add65ae55f04e287543c7d4a
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
52
2015-07-14T10:40:50.000Z
2022-03-15T01:11:49.000Z
# Authors: # Trevor Perrin # Martin von Loewis - python 3 port # Yngve Pettersen (ported by Paul Sokolovsky) - TLS 1.2 # # See the LICENSE file for legal information regarding use of this file. """cryptomath module This module has basic math/crypto code.""" from __future__ import print_function import os impor...
26.945687
76
0.509248
from __future__ import print_function import os import math import base64 import binascii from .compat import * try: from M2Crypto import m2 m2cryptoLoaded = True except ImportError: m2cryptoLoaded = False try: import gmpy gmpyLoaded = True except ImportError: gmpyLoaded = False try: ...
true
true
f7142c82611ea8aa0b9d89d7f852e92f1eb6cabd
2,892
py
Python
implementation/server/factories/files.py
Aincient/cleo
933ef372fa7847d943206d72bfb03c201dbafbd6
[ "Apache-2.0" ]
null
null
null
implementation/server/factories/files.py
Aincient/cleo
933ef372fa7847d943206d72bfb03c201dbafbd6
[ "Apache-2.0" ]
null
null
null
implementation/server/factories/files.py
Aincient/cleo
933ef372fa7847d943206d72bfb03c201dbafbd6
[ "Apache-2.0" ]
3
2018-10-01T12:04:36.000Z
2021-01-07T09:30:50.000Z
""" Files for testing. """ import base64 import tempfile from PIL import Image from six import BytesIO __all__ = ( 'BASE64_PREFIX', 'TEMPORARY_FILE_LIST', 'TEMPORARY_FILE_LIST_FILE_CONTENT', 'TEMPORARY_FILE_LIST_FILE_BASE64', 'TEMPORARY_FILE_VIEW', 'TEMPORARY_FILE_VIEW_FILE_CONTENT', 'TEM...
31.434783
77
0.802213
import base64 import tempfile from PIL import Image from six import BytesIO __all__ = ( 'BASE64_PREFIX', 'TEMPORARY_FILE_LIST', 'TEMPORARY_FILE_LIST_FILE_CONTENT', 'TEMPORARY_FILE_LIST_FILE_BASE64', 'TEMPORARY_FILE_VIEW', 'TEMPORARY_FILE_VIEW_FILE_CONTENT', 'TEMPORARY_FILE_VIEW_FILE_BASE6...
true
true