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
08f0ebf67726438785810692b53930d551aaa3f6
2,158
py
Python
model.py
ikit/cytosnap
cd18d38e93a3d50bf86dd8e44cbfdf8bde2cf0e6
[ "MIT" ]
1
2016-06-29T09:26:02.000Z
2016-06-29T09:26:02.000Z
model.py
ikit/cytosnap
cd18d38e93a3d50bf86dd8e44cbfdf8bde2cf0e6
[ "MIT" ]
11
2016-06-28T07:24:57.000Z
2016-07-02T10:18:37.000Z
model.py
ikit/Cytosnap
cd18d38e93a3d50bf86dd8e44cbfdf8bde2cf0e6
[ "MIT" ]
null
null
null
from mongoengine import * from werkzeug.security import generate_password_hash, check_password_hash from itsdangerous import TimedJSONWebSignatureSerializer as Serializer from bson.objectid import ObjectId class Image(Document): path = StringField(required=True) answer = StringField(max_length=50) asked_count = Int...
24.522727
73
0.720575
from mongoengine import * from werkzeug.security import generate_password_hash, check_password_hash from itsdangerous import TimedJSONWebSignatureSerializer as Serializer from bson.objectid import ObjectId class Image(Document): path = StringField(required=True) answer = StringField(max_length=50) asked_count = Int...
true
true
08f0ecd120be0d3bc15141b627d83193773a77dc
2,737
py
Python
rootWebSraping/root/spiders/spider.py
cenavia/skylynx
6286294a8cd57279e3c176d8fcae656cef4b40a8
[ "MIT" ]
3
2020-04-29T18:07:40.000Z
2020-05-20T20:52:52.000Z
rootWebSraping/root/spiders/spider.py
cenavia/Apartacho
6286294a8cd57279e3c176d8fcae656cef4b40a8
[ "MIT" ]
53
2020-05-13T03:27:41.000Z
2022-03-12T00:32:46.000Z
rootWebSraping/root/spiders/spider.py
cenavia/Apartacho
6286294a8cd57279e3c176d8fcae656cef4b40a8
[ "MIT" ]
2
2020-05-16T05:34:45.000Z
2020-06-11T14:47:50.000Z
# Spider # scrapy from scrapy.spiders import CrawlSpider, Rule from scrapy.linkextractors import LinkExtractor from scrapy.exceptions import CloseSpider # Item from root.items import RootItem class RootSpider(CrawlSpider): name = 'root' item_count = 0 allowed_domains = ['www.fincaraiz.com.co'] start...
46.389831
144
0.614176
from scrapy.spiders import CrawlSpider, Rule from scrapy.linkextractors import LinkExtractor from scrapy.exceptions import CloseSpider from root.items import RootItem class RootSpider(CrawlSpider): name = 'root' item_count = 0 allowed_domains = ['www.fincaraiz.com.co'] start_urls = [ 'https:...
true
true
08f0ed3048053a4b8b4b9af532755a0bce8cbc03
468
py
Python
src/model/TextChannelModel.py
anondax/Discord-copy-bot
c028693dc16528fa4daa8676d46deeda3768300e
[ "MIT" ]
3
2019-10-26T18:24:16.000Z
2020-01-18T15:40:18.000Z
src/model/TextChannelModel.py
anondax/Discord-copy-bot
c028693dc16528fa4daa8676d46deeda3768300e
[ "MIT" ]
7
2019-11-15T08:28:38.000Z
2019-11-15T08:43:17.000Z
src/model/TextChannelModel.py
anondax/Discord-copy-bot
c028693dc16528fa4daa8676d46deeda3768300e
[ "MIT" ]
null
null
null
from model.GuildChannelModel import * class TextChannelModel(GuildChannelModel): def __init__(self): GuildChannelModel.__init__(self); self.nsfw = None; self.topic = None; self.slowmode_delay = None; def fillFromChannel(self, channel): super(TextChannelModel, self).fi...
26
62
0.675214
from model.GuildChannelModel import * class TextChannelModel(GuildChannelModel): def __init__(self): GuildChannelModel.__init__(self); self.nsfw = None; self.topic = None; self.slowmode_delay = None; def fillFromChannel(self, channel): super(TextChannelModel, self).fi...
true
true
08f0ed5664c75b4684743515a2c89dac7285f9e8
25
py
Python
DistributedStorageBenchmarkTool/__init__.py
shadoobie/dbench
0cca504048ba918a1502482b7d06a866cda9ab6e
[ "MIT" ]
null
null
null
DistributedStorageBenchmarkTool/__init__.py
shadoobie/dbench
0cca504048ba918a1502482b7d06a866cda9ab6e
[ "MIT" ]
null
null
null
DistributedStorageBenchmarkTool/__init__.py
shadoobie/dbench
0cca504048ba918a1502482b7d06a866cda9ab6e
[ "MIT" ]
null
null
null
__author__ = 'shadoobie'
12.5
24
0.76
__author__ = 'shadoobie'
true
true
08f0ef3e40100a90722d438f3340dff1935ed4df
1,692
py
Python
corehq/messaging/smsbackends/megamobile/models.py
kkrampa/commcare-hq
d64d7cad98b240325ad669ccc7effb07721b4d44
[ "BSD-3-Clause" ]
1
2020-05-05T13:10:01.000Z
2020-05-05T13:10:01.000Z
corehq/messaging/smsbackends/megamobile/models.py
kkrampa/commcare-hq
d64d7cad98b240325ad669ccc7effb07721b4d44
[ "BSD-3-Clause" ]
1
2019-12-09T14:00:14.000Z
2019-12-09T14:00:14.000Z
corehq/messaging/smsbackends/megamobile/models.py
MaciejChoromanski/commcare-hq
fd7f65362d56d73b75a2c20d2afeabbc70876867
[ "BSD-3-Clause" ]
5
2015-11-30T13:12:45.000Z
2019-07-01T19:27:07.000Z
from __future__ import absolute_import from __future__ import unicode_literals from six.moves.urllib.parse import urlencode, quote from six.moves.urllib.request import urlopen from corehq.apps.sms.util import strip_plus from corehq.apps.sms.models import SQLSMSBackend from corehq.messaging.smsbackends.megamobile.forms ...
27.737705
82
0.667258
from __future__ import absolute_import from __future__ import unicode_literals from six.moves.urllib.parse import urlencode, quote from six.moves.urllib.request import urlopen from corehq.apps.sms.util import strip_plus from corehq.apps.sms.models import SQLSMSBackend from corehq.messaging.smsbackends.megamobile.forms ...
true
true
08f0ef4c41dc26078dd8cf2ed15fb3c6b4338b19
51
py
Python
PyUdemy/Day1/length.py
JoseArtur/phyton-exercices
f3da4447044e445222233960f991fb2e36311131
[ "MIT" ]
null
null
null
PyUdemy/Day1/length.py
JoseArtur/phyton-exercices
f3da4447044e445222233960f991fb2e36311131
[ "MIT" ]
null
null
null
PyUdemy/Day1/length.py
JoseArtur/phyton-exercices
f3da4447044e445222233960f991fb2e36311131
[ "MIT" ]
null
null
null
name = input("What's your name? ") print(len(name))
25.5
34
0.666667
name = input("What's your name? ") print(len(name))
true
true
08f0f0d2042001266f4e7c7aa77caf11a621b72f
15,865
py
Python
resnet/resnet.py
megvii-model/FunnelAct
8a9cdc67b55b1a226ecc0e65971340043d740551
[ "MIT" ]
178
2020-07-23T04:23:59.000Z
2022-02-11T07:42:27.000Z
resnet/resnet.py
megvii-model/FunnelAct
8a9cdc67b55b1a226ecc0e65971340043d740551
[ "MIT" ]
13
2020-07-27T10:42:51.000Z
2021-09-25T02:31:51.000Z
resnet/resnet.py
megvii-model/FunnelAct
8a9cdc67b55b1a226ecc0e65971340043d740551
[ "MIT" ]
21
2020-07-24T05:27:22.000Z
2021-11-29T12:42:55.000Z
# BSD 3-Clause License # Copyright (c) Soumith Chintala 2016, # All rights reserved. # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # * Redistributions of source code must retain the above copyright notice, this # l...
36.471264
113
0.610778
import math import megengine.functional as F import megengine.hub as hub import megengine.module as M from frelu import FReLU class BasicBlock(M.Module): expansion = 1 def __init__( self, in_channels, channels, stride=1, groups=1, base_width=64, dilation=1, norm=M.BatchNorm2d, ): ...
true
true
08f0f1af801842b51b6200effad3f5a0e7162e17
6,838
py
Python
nova/tests/objects/test_migration.py
bopopescu/nova-35
c32c01e08dccad921b4af6fc03d971d6e74c990f
[ "Apache-2.0" ]
null
null
null
nova/tests/objects/test_migration.py
bopopescu/nova-35
c32c01e08dccad921b4af6fc03d971d6e74c990f
[ "Apache-2.0" ]
null
null
null
nova/tests/objects/test_migration.py
bopopescu/nova-35
c32c01e08dccad921b4af6fc03d971d6e74c990f
[ "Apache-2.0" ]
1
2020-07-24T09:13:22.000Z
2020-07-24T09:13:22.000Z
# Copyright 2013 IBM Corp. # # 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 agree...
40.223529
79
0.633957
from nova import context from nova import db from nova.objects import migration from nova.openstack.common import timeutils from nova.tests import fake_instance from nova.tests.objects import test_objects NOW = timeutils.utcnow().replace(microsecond=0) def fake_db_migration(**updates): db_instance = { ...
true
true
08f0f2379679756f1494a1264f50789f2c53fb7e
2,054
py
Python
python/pyarrow/compat.py
fengguangyuan/arrow
79fddd1138ff69953e943f5980533dc01eabbb97
[ "Apache-2.0" ]
null
null
null
python/pyarrow/compat.py
fengguangyuan/arrow
79fddd1138ff69953e943f5980533dc01eabbb97
[ "Apache-2.0" ]
null
null
null
python/pyarrow/compat.py
fengguangyuan/arrow
79fddd1138ff69953e943f5980533dc01eabbb97
[ "Apache-2.0" ]
null
null
null
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
22.086022
62
0.657254
import itertools import numpy as np import sys import six from six import BytesIO, StringIO, string_types as py_string PY26 = sys.version_info[:2] == (2, 6) PY2 = sys.version_info[0] == 2 if PY26: import unittest2 as unittest else: import unittest if PY2: import cPickle try: from cdec...
true
true
08f0f338d824050828a955f09e708ac61344811d
1,215
py
Python
LeetCode/2018-12-25-87-Scramble-String.py
HeRuivio/-Algorithm
1fbe6256630758fda3af68f469471ee246730afc
[ "MIT" ]
5
2018-10-30T05:07:32.000Z
2019-06-18T08:11:38.000Z
LeetCode/2018-12-25-87-Scramble-String.py
HeRuivio/-Algorithm
1fbe6256630758fda3af68f469471ee246730afc
[ "MIT" ]
1
2020-05-09T09:05:16.000Z
2020-05-09T09:05:16.000Z
LeetCode/2018-12-25-87-Scramble-String.py
HeRuivio/-Algorithm
1fbe6256630758fda3af68f469471ee246730afc
[ "MIT" ]
2
2020-05-09T09:02:22.000Z
2020-12-09T13:23:00.000Z
# -*- coding: utf-8 -*- # @Author: 何睿 # @Create Date: 2018-12-25 15:11:08 # @Last Modified by: 何睿 # @Last Modified time: 2018-12-25 16:25:11 class Solution: def isScramble(self, s1, s2): """ :type s1: str :type s2: str :rtype: bool """ # 如果有一个字符...
30.375
113
0.522634
class Solution: def isScramble(self, s1, s2): if not s1 or not s2 or len(s1) != len(s2): return False elif len(s1) == 1 and s1 == s2: return True elif sorted(s1) != sorted(s2): return False length = len(s1) for i i...
true
true
08f0f368a4087fc63d3cec9e60a2aba7fe160356
4,760
py
Python
build/android/install_emulator_deps.py
nagineni/chromium-crosswalk
5725642f1c67d0f97e8613ec1c3e8107ab53fdf8
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
4
2017-04-05T01:51:34.000Z
2018-02-15T03:11:54.000Z
build/android/install_emulator_deps.py
nagineni/chromium-crosswalk
5725642f1c67d0f97e8613ec1c3e8107ab53fdf8
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
1
2021-12-13T19:44:12.000Z
2021-12-13T19:44:12.000Z
build/android/install_emulator_deps.py
nagineni/chromium-crosswalk
5725642f1c67d0f97e8613ec1c3e8107ab53fdf8
[ "BSD-3-Clause-No-Nuclear-License-2014", "BSD-3-Clause" ]
4
2017-04-05T01:52:03.000Z
2022-02-13T17:58:45.000Z
#!/usr/bin/env python # Copyright (c) 2013 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Installs deps for using SDK emulator for testing. The script will download the SDK and system images, if they are not present, ...
32.380952
98
0.670588
"""Installs deps for using SDK emulator for testing. The script will download the SDK and system images, if they are not present, and install and enable KVM, if virtualization has been enabled in the BIOS. """ import logging import os import shutil import sys from pylib import cmd_helper from pylib import constant...
false
true
08f0f4fb85bbbba7ef6db17130ce07bf274cfc53
1,007
py
Python
domains/fetch/problems/training/problem1023_CR.py
patras91/rae_release
0e5faffb7eb732fdb8e3bbf2c6d2f2cbd520aa30
[ "BSD-3-Clause" ]
1
2021-09-28T12:56:56.000Z
2021-09-28T12:56:56.000Z
domains/fetch/problems/training/problem1023_CR.py
patras91/rae_release
0e5faffb7eb732fdb8e3bbf2c6d2f2cbd520aa30
[ "BSD-3-Clause" ]
null
null
null
domains/fetch/problems/training/problem1023_CR.py
patras91/rae_release
0e5faffb7eb732fdb8e3bbf2c6d2f2cbd520aa30
[ "BSD-3-Clause" ]
1
2022-03-31T16:30:39.000Z
2022-03-31T16:30:39.000Z
__author__ = 'patras' from domain_chargeableRobot import * from timer import DURATION from state import state DURATION.TIME = { 'put': 2, 'take': 2, 'perceive': 3, 'charge': 5, 'move': 10, 'moveToEmergency': 5, 'moveCharger': 15, 'addressEmergency': 10, 'wait': 5, } DURATION.COUNTE...
19.745098
56
0.525323
__author__ = 'patras' from domain_chargeableRobot import * from timer import DURATION from state import state DURATION.TIME = { 'put': 2, 'take': 2, 'perceive': 3, 'charge': 5, 'move': 10, 'moveToEmergency': 5, 'moveCharger': 15, 'addressEmergency': 10, 'wait': 5, } DURATION.COUNTE...
true
true
08f0f50b9f409017ca599e610c20bd89727aa154
371
py
Python
events/contrib/plugins/form_handlers/http_repost/__init__.py
mansonul/events
4f6ca37bc600dcba3f74400d299826882d53b7d2
[ "MIT" ]
null
null
null
events/contrib/plugins/form_handlers/http_repost/__init__.py
mansonul/events
4f6ca37bc600dcba3f74400d299826882d53b7d2
[ "MIT" ]
null
null
null
events/contrib/plugins/form_handlers/http_repost/__init__.py
mansonul/events
4f6ca37bc600dcba3f74400d299826882d53b7d2
[ "MIT" ]
null
null
null
__title__ = 'fobi.contrib.plugins.form_handlers.http_repost' __author__ = 'Artur Barseghyan <artur.barseghyan@gmail.com>' __copyright__ = '2014-2017 Artur Barseghyan' __license__ = 'GPL 2.0/LGPL 2.1' __all__ = ('default_app_config', 'UID',) default_app_config = 'fobi.contrib.plugins.form_handlers.' \ ...
33.727273
60
0.725067
__title__ = 'fobi.contrib.plugins.form_handlers.http_repost' __author__ = 'Artur Barseghyan <artur.barseghyan@gmail.com>' __copyright__ = '2014-2017 Artur Barseghyan' __license__ = 'GPL 2.0/LGPL 2.1' __all__ = ('default_app_config', 'UID',) default_app_config = 'fobi.contrib.plugins.form_handlers.' \ ...
true
true
08f0f5467cf2e00057a8d0be88249b998fac19be
1,651
py
Python
openpype/hosts/maya/plugins/publish/validate_resources.py
jonclothcat/OpenPype
d1208cbebc0a7f378de0062ccd653295c6399195
[ "MIT" ]
87
2021-05-07T08:40:46.000Z
2022-03-19T00:36:25.000Z
openpype/hosts/maya/plugins/publish/validate_resources.py
zafrs/OpenPype
4b8e7e1ed002fc55b31307efdea70b0feaed474f
[ "MIT" ]
1,019
2021-04-26T06:22:56.000Z
2022-03-31T16:30:43.000Z
openpype/hosts/maya/plugins/publish/validate_resources.py
zafrs/OpenPype
4b8e7e1ed002fc55b31307efdea70b0feaed474f
[ "MIT" ]
33
2021-04-29T12:35:54.000Z
2022-03-25T14:48:42.000Z
import os from collections import defaultdict import pyblish.api import openpype.api class ValidateResources(pyblish.api.InstancePlugin): """Validates mapped resources. These are external files to the current application, for example these could be textures, image planes, cache files or other linked ...
28.465517
74
0.578437
import os from collections import defaultdict import pyblish.api import openpype.api class ValidateResources(pyblish.api.InstancePlugin): order = openpype.api.ValidateContentsOrder label = "Resources Unique" def process(self, instance): resources = instance.data.get("resources", []) if...
true
true
08f0f5fac4e835e0ca1b7123d1f53b5cd15cb79d
2,344
py
Python
book_search/views.py
jermnelson/aristotle-library-apps
f742847cd20c5b5c3b46dd53dfc395a2e1caa240
[ "Apache-2.0" ]
2
2015-03-30T16:36:51.000Z
2016-06-15T01:39:47.000Z
book_search/views.py
jermnelson/aristotle-library-apps
f742847cd20c5b5c3b46dd53dfc395a2e1caa240
[ "Apache-2.0" ]
2
2021-06-10T17:43:54.000Z
2021-12-13T19:40:08.000Z
book_search/views.py
jermnelson/aristotle-library-apps
f742847cd20c5b5c3b46dd53dfc395a2e1caa240
[ "Apache-2.0" ]
1
2015-11-08T00:40:11.000Z
2015-11-08T00:40:11.000Z
""" :mod: views Book Search App Views """ __author__ = "Gautam Webb" from django.views.generic.simple import direct_to_template from app_settings import APP from article_search.app_settings import APP as article_app from aristotle.settings import INSTITUTION from aristotle.forms import FeedbackForm def default(reque...
34.470588
74
0.526451
__author__ = "Gautam Webb" from django.views.generic.simple import direct_to_template from app_settings import APP from article_search.app_settings import APP as article_app from aristotle.settings import INSTITUTION from aristotle.forms import FeedbackForm def default(request): return direct_to_template(request...
true
true
08f0f6ea2fd5d288e9435ee182b1f204391f193b
6,627
py
Python
custom_components/plugwise/gateway.py
geijt/plugwise-beta
a35dd5eedb49ef10ccff8f9da442fb7b9db52cc1
[ "MIT" ]
null
null
null
custom_components/plugwise/gateway.py
geijt/plugwise-beta
a35dd5eedb49ef10ccff8f9da442fb7b9db52cc1
[ "MIT" ]
3
2022-03-03T16:46:51.000Z
2022-03-30T18:30:57.000Z
custom_components/plugwise/gateway.py
geijt/plugwise-beta
a35dd5eedb49ef10ccff8f9da442fb7b9db52cc1
[ "MIT" ]
null
null
null
"""Plugwise network/gateway platform.""" from __future__ import annotations import asyncio import logging from datetime import timedelta import voluptuous as vol from plugwise.exceptions import InvalidAuthentication, PlugwiseException from plugwise.smile import Smile from homeassistant.config_entries import ConfigE...
31.557143
87
0.682209
from __future__ import annotations import asyncio import logging from datetime import timedelta import voluptuous as vol from plugwise.exceptions import InvalidAuthentication, PlugwiseException from plugwise.smile import Smile from homeassistant.config_entries import ConfigEntry from homeassistant.core import HomeA...
true
true
08f0f789752d8a864051f5503c0e64ec084e4d35
5,006
py
Python
src/src/settings.py
maxweaker/Software-Requirements-Analysis
1ac59e5aad816cce2d43f1a05605d8caef02609d
[ "MIT" ]
1
2021-11-23T13:41:45.000Z
2021-11-23T13:41:45.000Z
src/src/settings.py
maxweaker/Software-Requirements-Analysis
1ac59e5aad816cce2d43f1a05605d8caef02609d
[ "MIT" ]
null
null
null
src/src/settings.py
maxweaker/Software-Requirements-Analysis
1ac59e5aad816cce2d43f1a05605d8caef02609d
[ "MIT" ]
null
null
null
""" Django settings for src project. Generated by 'django-admin startproject' using Django 3.2.9. For more information on this file, see https://docs.djangoproject.com/en/3.2/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/3.2/ref/settings/ """ import os from pa...
23.725118
91
0.685577
import os from pathlib import Path BASE_DIR = Path(__file__).resolve().parent.parent SECRET_KEY = 'django-insecure-ust3#0pxn&hp22bp2+t-n@)%5#%8@kg6(@+vphi*8vdv#j-02_' DEBUG = True ALLOWED_HOSTS = ["*",] CORS_ALLOW_HEADERS = ('*') # Application definition INSTALLED_APPS = [ 'django.contrib.admin', 'django...
true
true
08f0f7bad44f059a7b66eb90a56c472b6e17820d
31,535
py
Python
Automold.py
RC-Car-Racing-Team-17/Automold--Road-Augmentation-Library
866dc62fd18323fce948edcbd65e4c899dc26fda
[ "MIT" ]
null
null
null
Automold.py
RC-Car-Racing-Team-17/Automold--Road-Augmentation-Library
866dc62fd18323fce948edcbd65e4c899dc26fda
[ "MIT" ]
null
null
null
Automold.py
RC-Car-Racing-Team-17/Automold--Road-Augmentation-Library
866dc62fd18323fce948edcbd65e4c899dc26fda
[ "MIT" ]
null
null
null
# import glob import cv2 as cv2 import numpy as np # import matplotlib.pyplot as plt import random import math ###################### HLS ############################# def hls(image,src='RGB'): verify_image(image) if(is_list(image)): image_HLS=[] image_list=image for img in image_lis...
35.512387
228
0.630823
import cv2 as cv2 import numpy as np import random import math def hls(image,src='RGB'): verify_image(image) if(is_list(image)): image_HLS=[] image_list=image for img in image_list: eval('image_HLS.append(cv2.cvtColor(img,cv2.COLOR_'+src.upper()+'2HLS))') else: ...
true
true
08f0f9b611a607cce30468cfccf09f8f6d7a4523
1,230
py
Python
weconnect/elements/odometer_measurement.py
gordoncrossley/WeConnect-python
49456fa4b677f1d25af55d59c255fc9b32dcc3b5
[ "MIT" ]
null
null
null
weconnect/elements/odometer_measurement.py
gordoncrossley/WeConnect-python
49456fa4b677f1d25af55d59c255fc9b32dcc3b5
[ "MIT" ]
null
null
null
weconnect/elements/odometer_measurement.py
gordoncrossley/WeConnect-python
49456fa4b677f1d25af55d59c255fc9b32dcc3b5
[ "MIT" ]
null
null
null
import logging from weconnect.addressable import AddressableAttribute from weconnect.elements.generic_status import GenericStatus LOG = logging.getLogger("weconnect") class OdometerMeasurement(GenericStatus): def __init__( self, vehicle, parent, statusId, fromDict=None, ...
31.538462
113
0.664228
import logging from weconnect.addressable import AddressableAttribute from weconnect.elements.generic_status import GenericStatus LOG = logging.getLogger("weconnect") class OdometerMeasurement(GenericStatus): def __init__( self, vehicle, parent, statusId, fromDict=None, ...
true
true
08f0fa3575fc7855bd1d0e6bc2ac7a4bc44c0f56
1,421
py
Python
src/targeter.py
TamasSzepessy/DJITelloOpticalControl
00b704afea1eb9e2bcb82fcde41baae83934c48e
[ "MIT" ]
21
2020-01-08T04:40:48.000Z
2022-03-28T21:16:35.000Z
src/targeter.py
TamasSzepessy/DJITelloOpticalControl
00b704afea1eb9e2bcb82fcde41baae83934c48e
[ "MIT" ]
null
null
null
src/targeter.py
TamasSzepessy/DJITelloOpticalControl
00b704afea1eb9e2bcb82fcde41baae83934c48e
[ "MIT" ]
3
2021-01-17T19:11:51.000Z
2021-10-30T03:26:05.000Z
import csv import numpy as np # distance from marker in camera Z coordinates DIST = 0.9 class TargetDefine(): def __init__(self): with open('marker_list/marker_conf.csv', 'rt', encoding='utf-8') as f: reader = csv.reader(f, delimiter=';') self.marker_nav = list(reader) def cha...
37.394737
78
0.475018
import csv import numpy as np DIST = 0.9 class TargetDefine(): def __init__(self): with open('marker_list/marker_conf.csv', 'rt', encoding='utf-8') as f: reader = csv.reader(f, delimiter=';') self.marker_nav = list(reader) def changeTarget(self, ID): selected = 'Origin...
true
true
08f0fc727a19960b1ac59a35f220e157fc69cf13
620
py
Python
page_fragments/diagram.py
abamaxa/docvision_generator
8017f29c7d908cb80ddcd59e345a222271fa74de
[ "MIT" ]
2
2020-02-06T17:30:41.000Z
2020-08-04T10:35:46.000Z
page_fragments/diagram.py
abamaxa/docvision_generator
8017f29c7d908cb80ddcd59e345a222271fa74de
[ "MIT" ]
null
null
null
page_fragments/diagram.py
abamaxa/docvision_generator
8017f29c7d908cb80ddcd59e345a222271fa74de
[ "MIT" ]
null
null
null
from .rectangular_content import RectangularContent import graphics class Diagram(RectangularContent) : def __init__(self, parameters) : super().__init__(parameters) self.graphic_type = self.realize_required_parameter("type") self.weight = self.realize_parameter("weight", 1) def rende...
31
67
0.670968
from .rectangular_content import RectangularContent import graphics class Diagram(RectangularContent) : def __init__(self, parameters) : super().__init__(parameters) self.graphic_type = self.realize_required_parameter("type") self.weight = self.realize_parameter("weight", 1) def rende...
true
true
08f0fc728a28506650cbd9fc71c0fc3cfe9d3a6c
14,010
py
Python
tf_agents/agents/behavioral_cloning/behavioral_cloning_agent_test.py
midopooler/agents
7a1f9bd4da1850da2b38047d9ec2fa26e551d24a
[ "Apache-2.0" ]
2
2021-10-30T16:57:37.000Z
2021-11-17T10:21:17.000Z
tf_agents/agents/behavioral_cloning/behavioral_cloning_agent_test.py
tfboyd/agents
858ee36aaaea6fbcf0e5ab1c12929c77bd17abae
[ "Apache-2.0" ]
null
null
null
tf_agents/agents/behavioral_cloning/behavioral_cloning_agent_test.py
tfboyd/agents
858ee36aaaea6fbcf0e5ab1c12929c77bd17abae
[ "Apache-2.0" ]
2
2020-06-05T18:38:16.000Z
2020-07-08T14:41:42.000Z
# coding=utf-8 # Copyright 2018 The TF-Agents 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...
39.134078
80
0.703997
from __future__ import absolute_import from __future__ import division from __future__ import print_function from absl.testing import parameterized import tensorflow as tf from tf_agents.agents.behavioral_cloning import behavioral_cloning_agent from tf_agents.networks import network from tf_agents.networks import ...
true
true
08f0fdb5f54aff8c7540b55d6132358bb225e54e
6,690
py
Python
docs/conf.py
haodeqi/lale
b58cda5d17ba6ee233e9afa91844afa413af5520
[ "Apache-2.0" ]
null
null
null
docs/conf.py
haodeqi/lale
b58cda5d17ba6ee233e9afa91844afa413af5520
[ "Apache-2.0" ]
null
null
null
docs/conf.py
haodeqi/lale
b58cda5d17ba6ee233e9afa91844afa413af5520
[ "Apache-2.0" ]
null
null
null
# Copyright 2019 IBM 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 writing, ...
30.547945
79
0.6571
project = 'LALE' copyright = '2019, IBM AI Research' author = 'IBM AI Research' version = '' release = '' import os import sys sys.path.append(os.path.join(os.path.dirname(__name__), '../lale')) import sphinx_rtd_theme extensions = [ 'sphinx.ext.autodoc', 'sphinx.ext.doctest', 'sphinx.ext.napoleo...
true
true
08f0ff2631ccd15d4dbda71c3cf2ee1ed958bb8b
6,480
py
Python
pycti/entities/opencti_kill_chain_phase.py
vvoidranger/client-python
61371fbea9294fecd6abcbb4555a402143a05cca
[ "Apache-2.0" ]
1
2020-03-20T09:27:07.000Z
2020-03-20T09:27:07.000Z
pycti/entities/opencti_kill_chain_phase.py
vvoidranger/client-python
61371fbea9294fecd6abcbb4555a402143a05cca
[ "Apache-2.0" ]
null
null
null
pycti/entities/opencti_kill_chain_phase.py
vvoidranger/client-python
61371fbea9294fecd6abcbb4555a402143a05cca
[ "Apache-2.0" ]
null
null
null
# coding: utf-8 import json class KillChainPhase: def __init__(self, opencti): self.opencti = opencti self.properties = """ id entity_type stix_id_key kill_chain_name phase_name phase_order created mod...
32.562814
159
0.48179
import json class KillChainPhase: def __init__(self, opencti): self.opencti = opencti self.properties = """ id entity_type stix_id_key kill_chain_name phase_name phase_order created modified ...
true
true
08f0ff7838c73bcd6e25a76728dfa8c65990c51b
895
py
Python
tests/table/test_repr.py
sinisaos/piccolo
1c6654f52c64ed989829913d50aa88eb7314cd4e
[ "MIT" ]
null
null
null
tests/table/test_repr.py
sinisaos/piccolo
1c6654f52c64ed989829913d50aa88eb7314cd4e
[ "MIT" ]
null
null
null
tests/table/test_repr.py
sinisaos/piccolo
1c6654f52c64ed989829913d50aa88eb7314cd4e
[ "MIT" ]
null
null
null
from tests.base import DBTestCase, postgres_only, sqlite_only from tests.example_apps.music.tables import Manager class TestTableRepr(DBTestCase): @postgres_only def test_repr_postgres(self): self.assertEqual( Manager().__repr__(), '<Manager: "id" SERIAL PRIMARY KEY NOT NULL>',...
28.870968
73
0.604469
from tests.base import DBTestCase, postgres_only, sqlite_only from tests.example_apps.music.tables import Manager class TestTableRepr(DBTestCase): @postgres_only def test_repr_postgres(self): self.assertEqual( Manager().__repr__(), '<Manager: "id" SERIAL PRIMARY KEY NOT NULL>',...
true
true
08f0ff7ad0e065ade75f6e41689504b67d95a01e
2,807
py
Python
monitoring/daily_reporter/src/html_report.py
h4l/storage-service
05524e25dfc55f4fe6e2101e1be2850bec691564
[ "MIT" ]
12
2020-02-06T13:08:28.000Z
2022-03-05T08:02:27.000Z
monitoring/daily_reporter/src/html_report.py
h4l/storage-service
05524e25dfc55f4fe6e2101e1be2850bec691564
[ "MIT" ]
98
2020-02-13T09:36:39.000Z
2022-03-31T07:02:30.000Z
monitoring/daily_reporter/src/html_report.py
wellcometrust/storage
e53dbc1ec8761f78605c65028f75b697fe06d695
[ "MIT" ]
4
2020-03-12T15:42:23.000Z
2021-07-20T06:23:35.000Z
import datetime import os import re import boto3 from jinja2 import Environment, FileSystemLoader, select_autoescape def last_event(ingest): failures = [ev for ev in ingest["events"] if "failed" in ev["description"]] if failures: return max(failures, key=lambda ev: ev["createdDate"]) else: ...
29.861702
89
0.634129
import datetime import os import re import boto3 from jinja2 import Environment, FileSystemLoader, select_autoescape def last_event(ingest): failures = [ev for ev in ingest["events"] if "failed" in ev["description"]] if failures: return max(failures, key=lambda ev: ev["createdDate"]) else: ...
true
true
08f100e3792e73251deb108bf281ddaed95a9636
782
py
Python
ws2122-lspm/Lib/site-packages/pm4py/statistics/overlap/interval_events/pandas/__init__.py
Malekhy/ws2122-lspm
e4dc8b801d12f862b8ef536a0f125f346f085a00
[ "MIT" ]
1
2022-01-19T04:02:46.000Z
2022-01-19T04:02:46.000Z
ws2122-lspm/Lib/site-packages/pm4py/statistics/overlap/interval_events/pandas/__init__.py
Malekhy/ws2122-lspm
e4dc8b801d12f862b8ef536a0f125f346f085a00
[ "MIT" ]
1
2021-11-19T07:21:48.000Z
2021-11-19T07:21:48.000Z
ws2122-lspm/Lib/site-packages/pm4py/statistics/overlap/interval_events/pandas/__init__.py
Malekhy/ws2122-lspm
e4dc8b801d12f862b8ef536a0f125f346f085a00
[ "MIT" ]
1
2022-01-14T17:15:38.000Z
2022-01-14T17:15:38.000Z
''' This file is part of PM4Py (More Info: https://pm4py.fit.fraunhofer.de). PM4Py is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any late...
43.444444
76
0.740409
from pm4py.statistics.overlap.interval_events.pandas import get
true
true
08f1017e7fb819adcbd1940d17bec6c4b5fca1db
12,011
py
Python
python/tvm/autotvm/graph_tuner/utils/traverse_graph.py
ttyang1018/tvm
ade26cacd0767cf14dc053ac4d7778859f83a32c
[ "Apache-2.0" ]
16
2019-11-20T03:43:19.000Z
2021-11-25T02:32:17.000Z
python/tvm/autotvm/graph_tuner/utils/traverse_graph.py
ttyang1018/tvm
ade26cacd0767cf14dc053ac4d7778859f83a32c
[ "Apache-2.0" ]
2
2020-02-20T10:01:48.000Z
2021-08-21T02:23:57.000Z
python/tvm/autotvm/graph_tuner/utils/traverse_graph.py
ttyang1018/tvm
ade26cacd0767cf14dc053ac4d7778859f83a32c
[ "Apache-2.0" ]
5
2020-03-18T10:14:30.000Z
2021-04-01T12:09:20.000Z
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
38.373802
92
0.598868
import threading import topi from tvm import relay, autotvm from tvm.relay.expr import Call, Function, TupleGetItem, Var, Constant, Tuple from tvm.relay.ty import TupleType, TensorType from tvm.autotvm.task import TaskExtractEnv from .._base import RULE_OUT_NODE_NAMES from .utils import has_multiple_inputs, is_input...
true
true
08f101a5d647d3c8afea83de41ac0cd8d25ea073
585
py
Python
Strings.py
dongjin2008/Pyhton
4c11bc015ca932107296cb3a829d64453e1a84e2
[ "MIT" ]
null
null
null
Strings.py
dongjin2008/Pyhton
4c11bc015ca932107296cb3a829d64453e1a84e2
[ "MIT" ]
null
null
null
Strings.py
dongjin2008/Pyhton
4c11bc015ca932107296cb3a829d64453e1a84e2
[ "MIT" ]
null
null
null
firstName = "Meher" print(firstName) fullName = "Meher Krishna Patel" print(fullName) score1 = input("Enter the score 1: ") score2 = input("Enter the score 2: ") totalString = score1 + score2 messageString = "Total score is %s" print(messageString % totalString) totalInt = int(score1) + int(score2) mes...
27.857143
46
0.687179
firstName = "Meher" print(firstName) fullName = "Meher Krishna Patel" print(fullName) score1 = input("Enter the score 1: ") score2 = input("Enter the score 2: ") totalString = score1 + score2 messageString = "Total score is %s" print(messageString % totalString) totalInt = int(score1) + int(score2) mes...
true
true
08f101bccd0092d5e3a3a803aa702e50476369a1
3,022
py
Python
chatterbox/collectors/tumblr.py
blitzagency/django-chatterbox
7bf17444f8308aa12b6718bd62ee1344021c21aa
[ "MIT" ]
8
2015-03-10T20:03:09.000Z
2018-06-14T23:03:58.000Z
chatterbox/collectors/tumblr.py
blitzagency/django-chatterbox
7bf17444f8308aa12b6718bd62ee1344021c21aa
[ "MIT" ]
3
2015-07-14T22:44:47.000Z
2020-06-05T23:43:05.000Z
chatterbox/collectors/tumblr.py
blitzagency/django-chatterbox
7bf17444f8308aa12b6718bd62ee1344021c21aa
[ "MIT" ]
null
null
null
import logging from django import forms from chatterbox.utils.tumblr import activity_from_dict from . import (Collector, maybe) log = logging.getLogger(__name__) class TumblrHostForm(forms.Form): host_name = forms.CharField( label='Host Name', max_length=100, help_text="dinopetrone.tumblr.com") class ...
25.82906
78
0.585043
import logging from django import forms from chatterbox.utils.tumblr import activity_from_dict from . import (Collector, maybe) log = logging.getLogger(__name__) class TumblrHostForm(forms.Form): host_name = forms.CharField( label='Host Name', max_length=100, help_text="dinopetrone.tumblr.com") class ...
true
true
08f101f9843230457a9ebe7638d5ea7d4eaaef33
677
py
Python
hb_quant/huobi/service/trade/get_order_by_id.py
wenli135/Binance-volatility-trading-bot
75a03ad61df0e95492128fb6f1f419d4dc256ab3
[ "MIT" ]
611
2019-07-10T08:17:50.000Z
2022-03-21T18:56:39.000Z
hb_quant/huobi/service/trade/get_order_by_id.py
wenli135/Binance-volatility-trading-bot
75a03ad61df0e95492128fb6f1f419d4dc256ab3
[ "MIT" ]
105
2019-07-12T03:43:41.000Z
2022-03-30T10:33:06.000Z
hb_quant/huobi/service/trade/get_order_by_id.py
wenli135/Binance-volatility-trading-bot
75a03ad61df0e95492128fb6f1f419d4dc256ab3
[ "MIT" ]
325
2019-07-12T02:46:54.000Z
2022-03-21T18:56:41.000Z
from huobi.connection.restapi_sync_client import RestApiSyncClient from huobi.constant import * from huobi.model.trade import * from huobi.utils import * class GetOrderByIdService: def __init__(self, params): self.params = params def request(self, **kwargs): order_id = self.params["order_id"...
23.344828
114
0.666174
from huobi.connection.restapi_sync_client import RestApiSyncClient from huobi.constant import * from huobi.model.trade import * from huobi.utils import * class GetOrderByIdService: def __init__(self, params): self.params = params def request(self, **kwargs): order_id = self.params["order_id"...
true
true
08f1020e4aaa29ed14852b9de03ed2d6aabe4a42
5,307
py
Python
xcopilot/config/commands.py
owentar/x-copilot-py
15ffa9d22fc2a906b5437d8484b4002c635085fe
[ "MIT" ]
null
null
null
xcopilot/config/commands.py
owentar/x-copilot-py
15ffa9d22fc2a906b5437d8484b4002c635085fe
[ "MIT" ]
null
null
null
xcopilot/config/commands.py
owentar/x-copilot-py
15ffa9d22fc2a906b5437d8484b4002c635085fe
[ "MIT" ]
null
null
null
try: from XPLMDataAccess import * from XPLMUtilities import * except ImportError: from XPlaneSDKStub.XPLMDataAccess import * from XPlaneSDKStub.XPLMUtilities import * from xcopilot.parser import sanitizeNumberValue, parseToFloat def parseAltimeterValue(value): sanitizedValue = sanitizeNumberValue(v...
46.964602
271
0.622574
try: from XPLMDataAccess import * from XPLMUtilities import * except ImportError: from XPlaneSDKStub.XPLMDataAccess import * from XPlaneSDKStub.XPLMUtilities import * from xcopilot.parser import sanitizeNumberValue, parseToFloat def parseAltimeterValue(value): sanitizedValue = sanitizeNumberValue(v...
true
true
08f102760bb61ea41e66a025bdfe86e9f036977b
1,524
py
Python
girder_worker_tasks/arbor_nova_tasks/arbor_tasks/fnlcr/docker_polyA.py
knowledgevis/rms_infer_web
53382762ffc6ec12ac635e2938661008cd87cae8
[ "Apache-2.0" ]
null
null
null
girder_worker_tasks/arbor_nova_tasks/arbor_tasks/fnlcr/docker_polyA.py
knowledgevis/rms_infer_web
53382762ffc6ec12ac635e2938661008cd87cae8
[ "Apache-2.0" ]
3
2022-02-02T20:35:12.000Z
2022-02-02T20:58:20.000Z
girder_worker_tasks/arbor_nova_tasks/arbor_tasks/fnlcr/docker_polyA.py
knowledgevis/rms_infer_web
53382762ffc6ec12ac635e2938661008cd87cae8
[ "Apache-2.0" ]
null
null
null
from girder_worker.app import app from girder_worker.utils import girder_job from tempfile import NamedTemporaryFile # for task code import subprocess import traceback #------------------------------------------- @girder_job(title='docker_polyA') @app.task(bind=True) def docker_polyA(self,fasta_file,linker_file,tran...
37.170732
218
0.681759
from girder_worker.app import app from girder_worker.utils import girder_job from tempfile import NamedTemporaryFile import subprocess import traceback @girder_job(title='docker_polyA') @app.task(bind=True) def docker_polyA(self,fasta_file,linker_file,transcript_file,**kwargs): print(" subject filename = {}".fo...
true
true
08f102bfe3e6515d3c533d7d3d136d06d758a120
1,761
py
Python
ngi_reports/stockholm/ign_sample_report.py
ssjunnebo/ngi_reports
42dddcd8728afc4740643de839aefaa8fcb4fb44
[ "MIT" ]
null
null
null
ngi_reports/stockholm/ign_sample_report.py
ssjunnebo/ngi_reports
42dddcd8728afc4740643de839aefaa8fcb4fb44
[ "MIT" ]
null
null
null
ngi_reports/stockholm/ign_sample_report.py
ssjunnebo/ngi_reports
42dddcd8728afc4740643de839aefaa8fcb4fb44
[ "MIT" ]
null
null
null
#!/usr/bin/env python """ Stockholm module for dealing with fields for the IGN Sample Report """ import os from ngi_reports.common import ign_sample_report from ngi_reports.utils import statusdb class Report(ign_sample_report.CommonReport): # Initialise the report def __init__(self, config, LOG, working_dir...
38.282609
139
0.626349
import os from ngi_reports.common import ign_sample_report from ngi_reports.utils import statusdb class Report(ign_sample_report.CommonReport): def __init__(self, config, LOG, working_dir, **kwargs): self.ngi_node = 'stockholm' super(Report, self).__init__(config, LOG, work...
true
true
08f102e1794d0773c837b9a25a0d40b84b02d098
8,874
py
Python
mypy/test/testmerge.py
deeper-x/mypy
0f76dfcb9720472f0d8145bff81c01314e1bef84
[ "PSF-2.0" ]
null
null
null
mypy/test/testmerge.py
deeper-x/mypy
0f76dfcb9720472f0d8145bff81c01314e1bef84
[ "PSF-2.0" ]
null
null
null
mypy/test/testmerge.py
deeper-x/mypy
0f76dfcb9720472f0d8145bff81c01314e1bef84
[ "PSF-2.0" ]
1
2020-02-27T15:22:03.000Z
2020-02-27T15:22:03.000Z
"""Test cases for AST merge (used for fine-grained incremental checking)""" import os import shutil from typing import List, Tuple, Dict, Optional from mypy import build from mypy.build import BuildSource, BuildResult from mypy.defaults import PYTHON3_VERSION from mypy.errors import CompileError from mypy.nodes impor...
37.443038
95
0.594433
import os import shutil from typing import List, Tuple, Dict, Optional from mypy import build from mypy.build import BuildSource, BuildResult from mypy.defaults import PYTHON3_VERSION from mypy.errors import CompileError from mypy.nodes import ( Node, MypyFile, SymbolTable, SymbolTableNode, TypeInfo, Expression, ...
true
true
08f1032a8412a4c09d899543f0d5c0d8e5ee9cc4
7,131
py
Python
_ext/purpose.py
geoscixyz/em
2c7b9fa470faffb2e23fa1b44a5452ee15e82fb0
[ "CC-BY-4.0" ]
37
2017-03-01T17:00:33.000Z
2022-02-09T08:58:57.000Z
_ext/purpose.py
geoscixyz/em
2c7b9fa470faffb2e23fa1b44a5452ee15e82fb0
[ "CC-BY-4.0" ]
85
2017-01-25T16:34:59.000Z
2021-11-20T01:14:23.000Z
_ext/purpose.py
geoscixyz/em
2c7b9fa470faffb2e23fa1b44a5452ee15e82fb0
[ "CC-BY-4.0" ]
68
2017-01-30T19:47:02.000Z
2022-02-19T11:45:11.000Z
""" Adapted from sphinx.ext.purpose https://github.com/sphinx-doc/sphinx/blob/master/sphinx/ext/purpose.py Allow purposes to be inserted into your documentation. Inclusion of purposes can be switched of by a configuration variable. The purposelist directive collects all purposes of your project...
33.478873
85
0.643108
from docutils import nodes from docutils.parsers.rst import directives import sphinx from sphinx.locale import _ from sphinx.errors import NoUri from sphinx.util.nodes import set_source_info from docutils.parsers.rst import Directive from docutils.parsers.rst.directives.admonitions import BaseAdmonition class purp...
true
true
08f103842c0eb91baf8349788189761993d1c96a
3,945
py
Python
sounds.py
juliusarden/slack-sounds
60039794e450adddd06a59257469e94310a8b3ce
[ "MIT" ]
null
null
null
sounds.py
juliusarden/slack-sounds
60039794e450adddd06a59257469e94310a8b3ce
[ "MIT" ]
null
null
null
sounds.py
juliusarden/slack-sounds
60039794e450adddd06a59257469e94310a8b3ce
[ "MIT" ]
null
null
null
#!/usr/bin/env python import time from slackclient import SlackClient import os, re base_dir = os.path.dirname(os.path.realpath(__file__)) player = 'mpg123' text2voice = 'espeak' sounds_dir = 'sounds' filetype = 'mp3' debug = True bots_channel = 'sherpa_roast' play_regex = re.compile("^play\s([a-z0-9]+)$") speak_reg...
42.419355
144
0.555133
import time from slackclient import SlackClient import os, re base_dir = os.path.dirname(os.path.realpath(__file__)) player = 'mpg123' text2voice = 'espeak' sounds_dir = 'sounds' filetype = 'mp3' debug = True bots_channel = 'sherpa_roast' play_regex = re.compile("^play\s([a-z0-9]+)$") speak_regex = re.compile("^spea...
false
true
08f104c5e252d42df277f8be869d223f558f80d1
21,505
py
Python
magnum/api/controllers/v1/cluster_template.py
piersharding/magnum
451358a57c4bd8fd93bab8121cfb5698d5471568
[ "Apache-2.0" ]
1
2020-01-15T08:25:38.000Z
2020-01-15T08:25:38.000Z
magnum/api/controllers/v1/cluster_template.py
HNicholas/magnum
410b7fd1055aa99d517ee82c6dcc2dba53457179
[ "Apache-2.0" ]
2
2019-06-14T12:13:53.000Z
2020-07-10T00:30:53.000Z
magnum/api/controllers/v1/cluster_template.py
zonca/magnum
3217e75b63fb9ebeb37b462677cdb72315ca1067
[ "Apache-2.0" ]
null
null
null
# All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in...
43.70935
80
0.626552
from oslo_utils import timeutils import pecan import six import wsme from wsme import types as wtypes from magnum.api import attr_validator from magnum.api.controllers import base from magnum.api.controllers import link from magnum.api.controllers.v1 import collection from magnum.api.controllers.v1 import types from ...
true
true
08f104fee7b9218b1b735f67211e4d3b508d138d
698
py
Python
migrations/versions/9197dd399d3d_add_a_password_column_for_.py
Muia23/soi
9407ffa6c6e95572ed77cb95d82b6139bf7dc350
[ "Unlicense" ]
null
null
null
migrations/versions/9197dd399d3d_add_a_password_column_for_.py
Muia23/soi
9407ffa6c6e95572ed77cb95d82b6139bf7dc350
[ "Unlicense" ]
null
null
null
migrations/versions/9197dd399d3d_add_a_password_column_for_.py
Muia23/soi
9407ffa6c6e95572ed77cb95d82b6139bf7dc350
[ "Unlicense" ]
null
null
null
"""add a password column for authentification Revision ID: 9197dd399d3d Revises: aa952a06483e Create Date: 2020-07-25 14:05:41.272196 """ from alembic import op import sqlalchemy as sa # revision identifiers, used by Alembic. revision = '9197dd399d3d' down_revision = 'aa952a06483e' branch_labels = None depends_on =...
24.068966
90
0.703438
from alembic import op import sqlalchemy as sa revision = '9197dd399d3d' down_revision = 'aa952a06483e' branch_labels = None depends_on = None def upgrade(): op.add_column('users', sa.Column('pass_secure', sa.String(length=255), nullable=True)) def downgrade(): op.drop_column('users', 'pass_se...
true
true
08f10523299315a519e8b8cd60916b07f0105649
768
py
Python
part4/polls/models.py
zweed4u/django-stuff
db0b85c1072b9ec4dc9373c5bf39cafcc3a6b744
[ "MIT" ]
null
null
null
part4/polls/models.py
zweed4u/django-stuff
db0b85c1072b9ec4dc9373c5bf39cafcc3a6b744
[ "MIT" ]
null
null
null
part4/polls/models.py
zweed4u/django-stuff
db0b85c1072b9ec4dc9373c5bf39cafcc3a6b744
[ "MIT" ]
null
null
null
import datetime from django.db import models from django.utils import timezone # Create your models here. class Question(models.Model): """ Variables used to represent database fields within the model """ question_text = models.CharField(max_length=200) pub_date = models.DateTimeField('date published') def was...
26.482759
69
0.773438
import datetime from django.db import models from django.utils import timezone class Question(models.Model): question_text = models.CharField(max_length=200) pub_date = models.DateTimeField('date published') def was_published_recently(self): return self.pub_date >= timezone.now() - datetime.timedelta(days=1) ...
true
true
08f1056162f937cb070af4c866c587572620c0c6
73,312
py
Python
ymir/command/mir/protos/mir_command_pb2.py
under-chaos/ymir
83e98186b23429e6027b187cdade247f5f93e5de
[ "Apache-2.0" ]
1
2022-01-12T03:12:47.000Z
2022-01-12T03:12:47.000Z
ymir/command/mir/protos/mir_command_pb2.py
under-chaos/ymir
83e98186b23429e6027b187cdade247f5f93e5de
[ "Apache-2.0" ]
null
null
null
ymir/command/mir/protos/mir_command_pb2.py
under-chaos/ymir
83e98186b23429e6027b187cdade247f5f93e5de
[ "Apache-2.0" ]
null
null
null
# -*- coding: utf-8 -*- # Generated by the protocol buffer compiler. DO NOT EDIT! # source: mir_command.proto """Generated protocol buffer code.""" from google.protobuf.internal import enum_type_wrapper from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.pr...
41.117218
6,859
0.760762
from google.protobuf.internal import enum_type_wrapper from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection from google.protobuf import symbol_database as _symbol_database _sym_db = _symbol_database.Default() DES...
true
true
08f105d0e84b3786dc01b467237ca65248dc9740
2,898
py
Python
tracking/eval/importers.py
holajoa/keras-YOLOv3-model-set
c15b8a2f48371c063f6482b25593dc70d5956323
[ "MIT" ]
601
2019-08-24T10:14:52.000Z
2022-03-29T15:05:33.000Z
tracking/eval/importers.py
holajoa/keras-YOLOv3-model-set
c15b8a2f48371c063f6482b25593dc70d5956323
[ "MIT" ]
220
2019-10-04T18:57:59.000Z
2022-03-31T15:30:37.000Z
tracking/eval/importers.py
holajoa/keras-YOLOv3-model-set
c15b8a2f48371c063f6482b25593dc70d5956323
[ "MIT" ]
218
2019-10-31T03:32:11.000Z
2022-03-25T14:44:19.000Z
#! /usr/bin/env python3 # -*- coding: utf-8 -*- from collections import deque def MOT_hypo_import(lines): frames = [] for line in lines: # print(line) s = deque(line.strip().split()) # any whitespace # Skip empty lines if len(s) < 1: continue ts = float(s....
25.2
86
0.444444
from collections import deque def MOT_hypo_import(lines): frames = [] for line in lines: s = deque(line.strip().split()) if len(s) < 1: continue ts = float(s.popleft()) assert((len(s)) % 5 == 0) nHypotheses = len(s) / 5 hypothese...
true
true
08f106f16050917a57c326b893c2a20d763149f6
3,643
py
Python
pygazebo/msg/pid_pb2.py
WindhoverLabs/pygazebo
9c977703be5c04fe931e7ec522fb7aa1e6bbe05e
[ "Apache-2.0" ]
null
null
null
pygazebo/msg/pid_pb2.py
WindhoverLabs/pygazebo
9c977703be5c04fe931e7ec522fb7aa1e6bbe05e
[ "Apache-2.0" ]
null
null
null
pygazebo/msg/pid_pb2.py
WindhoverLabs/pygazebo
9c977703be5c04fe931e7ec522fb7aa1e6bbe05e
[ "Apache-2.0" ]
null
null
null
# Generated by the protocol buffer compiler. DO NOT EDIT! # source: pid.proto from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection from google.protobuf import descriptor_pb2 # @@protoc_insertion_point(imports) D...
36.43
399
0.719462
from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection from google.protobuf import descriptor_pb2 DESCRIPTOR = _descriptor.FileDescriptor( name='pid.proto', package='gazebo.msgs', serialized_pb='\n\tpid.proto...
true
true
08f107c3504bec38c09a56643c0755028e2e06a0
5,934
py
Python
test.py
mon02118/azure_vton
2ec3fe38fb2e94f59fe6cabc29eac5d08e4a21fd
[ "MIT" ]
null
null
null
test.py
mon02118/azure_vton
2ec3fe38fb2e94f59fe6cabc29eac5d08e4a21fd
[ "MIT" ]
null
null
null
test.py
mon02118/azure_vton
2ec3fe38fb2e94f59fe6cabc29eac5d08e4a21fd
[ "MIT" ]
null
null
null
#coding=utf-8 import torch import torch.nn as nn import torch.nn.functional as F import argparse import os import time from cp_dataset import CPDataset, CPDataLoader from networks import GMM, UnetGenerator, load_checkpoint from tensorboardX import SummaryWriter from visualization import board_add_image, board_add_ima...
36.182927
108
0.640377
import torch import torch.nn as nn import torch.nn.functional as F import argparse import os import time from cp_dataset import CPDataset, CPDataLoader from networks import GMM, UnetGenerator, load_checkpoint from tensorboardX import SummaryWriter from visualization import board_add_image, board_add_images, save_imag...
true
true
08f1083b6c6d427546707be622583a7c688cd0ff
7,744
py
Python
invoicer/migrations/0002_auto__add_item.py
gabrielhurley/django-invoicer
11674908995104a029b3073ceda2787460ff2d8e
[ "BSD-3-Clause" ]
3
2016-07-26T13:56:59.000Z
2019-09-26T06:56:51.000Z
invoicer/migrations/0002_auto__add_item.py
gabrielhurley/django-invoicer
11674908995104a029b3073ceda2787460ff2d8e
[ "BSD-3-Clause" ]
null
null
null
invoicer/migrations/0002_auto__add_item.py
gabrielhurley/django-invoicer
11674908995104a029b3073ceda2787460ff2d8e
[ "BSD-3-Clause" ]
null
null
null
# encoding: utf-8 import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Adding model 'Item' db.create_table('invoicer_item', ( ('id', self.gf('django.db.models.fiel...
69.142857
142
0.563662
import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): db.create_table('invoicer_item', ( ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), ...
true
true
08f108a3c98172cfecb72f4994f09f12335c411a
517
py
Python
tests/quara/data_analysis/test_physicality_violation_check.py
tknrsgym/quara
8f3337af83cdd02bb85632bb1e297902b1fff8fb
[ "Apache-2.0" ]
3
2021-05-19T11:44:30.000Z
2022-03-30T07:13:49.000Z
tests/quara/data_analysis/test_physicality_violation_check.py
tknrsgym/quara
8f3337af83cdd02bb85632bb1e297902b1fff8fb
[ "Apache-2.0" ]
2
2021-06-02T01:24:59.000Z
2021-06-02T12:20:31.000Z
tests/quara/data_analysis/test_physicality_violation_check.py
tknrsgym/quara
8f3337af83cdd02bb85632bb1e297902b1fff8fb
[ "Apache-2.0" ]
1
2021-10-14T13:21:27.000Z
2021-10-14T13:21:27.000Z
from quara.data_analysis import physicality_violation_check as pvc def test_get_sum_of_eigenvalues_violation(): # Arrange source_vals = [[0.6, 0.5, 1, -0.5], [1, 0.5, 0.4, 0.1]] # Act actual_less_list, actual_greater_list = pvc.get_sum_of_eigenvalues_violation( source_vals, expected_values=(0...
28.722222
81
0.711799
from quara.data_analysis import physicality_violation_check as pvc def test_get_sum_of_eigenvalues_violation(): source_vals = [[0.6, 0.5, 1, -0.5], [1, 0.5, 0.4, 0.1]] actual_less_list, actual_greater_list = pvc.get_sum_of_eigenvalues_violation( source_vals, expected_values=(0, 2) ) ...
true
true
08f108c955ed87bc56909e717a47487b5086a788
27,029
py
Python
saleor/graphql/checkout/mutations.py
MatthewBosek/saleor
8b5a9aab3837016887aa713ec7b581089d995084
[ "CC-BY-4.0" ]
2
2019-08-29T14:17:59.000Z
2019-09-03T16:39:44.000Z
saleor/graphql/checkout/mutations.py
MatthewBosek/saleor
8b5a9aab3837016887aa713ec7b581089d995084
[ "CC-BY-4.0" ]
3
2021-03-09T16:28:16.000Z
2022-02-10T19:08:00.000Z
saleor/graphql/checkout/mutations.py
JostCrow/saleor
854bcd3699703e613a4d9aaefc4299a6a6c0d1f9
[ "CC-BY-4.0" ]
1
2020-08-24T00:43:06.000Z
2020-08-24T00:43:06.000Z
from typing import List, Optional, Tuple import graphene from django.conf import settings from django.core.exceptions import ObjectDoesNotExist, ValidationError from django.db import transaction from django.utils import timezone from ...checkout import models from ...checkout.utils import ( abort_order_data, ...
35.705416
88
0.661549
from typing import List, Optional, Tuple import graphene from django.conf import settings from django.core.exceptions import ObjectDoesNotExist, ValidationError from django.db import transaction from django.utils import timezone from ...checkout import models from ...checkout.utils import ( abort_order_data, ...
true
true
08f108d41d9925bb90c99923c066d1bd19d87a76
5,208
py
Python
docs/conf.py
makermelissa/Adafruit_CircuitPython_SSD1325
61e3de7e7a391e877950e9f23db7e38865c4baeb
[ "MIT" ]
null
null
null
docs/conf.py
makermelissa/Adafruit_CircuitPython_SSD1325
61e3de7e7a391e877950e9f23db7e38865c4baeb
[ "MIT" ]
null
null
null
docs/conf.py
makermelissa/Adafruit_CircuitPython_SSD1325
61e3de7e7a391e877950e9f23db7e38865c4baeb
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- import os import sys sys.path.insert(0, os.path.abspath('..')) # -- General configuration ------------------------------------------------ # Add any Sphinx extension module names here, as strings. They can be # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom # ones. extens...
32.347826
146
0.685676
import os import sys sys.path.insert(0, os.path.abspath('..')) extensions = [ 'sphinx.ext.autodoc', 'sphinx.ext.intersphinx', 'sphinx.ext.napoleon', 'sphinx.ext.todo', ] autodoc_mock_imports = ["displayio"] intersphinx_mapping = {'python': ('https://docs.python.org/3.4', None),'CircuitPython': ('h...
true
true
08f10990a5a942d191600ac06778c66bbc83f8d2
3,052
py
Python
pirates/invasion/DistributedWreckedFaithfulBride.py
ksmit799/POTCO-PS
520d38935ae8df4b452c733a82c94dddac01e275
[ "Apache-2.0" ]
8
2017-01-24T04:33:29.000Z
2020-11-01T08:36:24.000Z
pirates/invasion/DistributedWreckedFaithfulBride.py
ksmit799/Pirates-Online-Remake
520d38935ae8df4b452c733a82c94dddac01e275
[ "Apache-2.0" ]
1
2017-03-02T18:05:17.000Z
2017-03-14T06:47:10.000Z
pirates/invasion/DistributedWreckedFaithfulBride.py
ksmit799/Pirates-Online-Remake
520d38935ae8df4b452c733a82c94dddac01e275
[ "Apache-2.0" ]
11
2017-03-02T18:46:07.000Z
2020-11-01T08:36:26.000Z
# File: D (Python 2.4) from pandac.PandaModules import * import DistributedPostInvasionObject from pirates.effects.Fire import Fire from pirates.effects.MansionSmoke import MansionSmoke class DistributedWreckedFaithfulBride(DistributedPostInvasionObject.DistributedPostInvasionObject): notify = directNotify.newCat...
33.538462
101
0.650066
from pandac.PandaModules import * import DistributedPostInvasionObject from pirates.effects.Fire import Fire from pirates.effects.MansionSmoke import MansionSmoke class DistributedWreckedFaithfulBride(DistributedPostInvasionObject.DistributedPostInvasionObject): notify = directNotify.newCategory('DistributedWreck...
true
true
08f10a21494aa691701a64c9a586a6902e4da723
190,021
py
Python
mesonbuild/interpreter.py
pdietl/meson
578e5c04e933f9f5639549a5cd0ee0fc87964376
[ "Apache-2.0" ]
null
null
null
mesonbuild/interpreter.py
pdietl/meson
578e5c04e933f9f5639549a5cd0ee0fc87964376
[ "Apache-2.0" ]
null
null
null
mesonbuild/interpreter.py
pdietl/meson
578e5c04e933f9f5639549a5cd0ee0fc87964376
[ "Apache-2.0" ]
null
null
null
# Copyright 2012-2018 The Meson development team # 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...
45.821317
163
0.609206
from . import mparser from . import environment from . import coredata from . import dependencies from . import mlog from . import build from . import optinterpreter from . import compilers from .wrap import wrap, WrapMode from . import mesonlib from .mesonlib import FileMode, MachineChoice, Popen_safe, listify, ext...
true
true
08f10a596eb0d382910ec5550c446cabd01d8e6a
9,481
py
Python
data_preparation/metadata_completion/utilities.py
rikrd/libri-light
34c3f43774c374a529e67c88b87a79041f07b402
[ "MIT" ]
null
null
null
data_preparation/metadata_completion/utilities.py
rikrd/libri-light
34c3f43774c374a529e67c88b87a79041f07b402
[ "MIT" ]
null
null
null
data_preparation/metadata_completion/utilities.py
rikrd/libri-light
34c3f43774c374a529e67c88b87a79041f07b402
[ "MIT" ]
null
null
null
# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved from pathlib import Path import pickle import json import torchaudio import progressbar import argparse import os import matplotlib matplotlib.use('agg') def get_all_metadata(path_dir, suffix="_metadata.json"): out = [] for root, dirs, fil...
26.046703
80
0.621664
from pathlib import Path import pickle import json import torchaudio import progressbar import argparse import os import matplotlib matplotlib.use('agg') def get_all_metadata(path_dir, suffix="_metadata.json"): out = [] for root, dirs, filenames in os.walk(path_dir): for f in filenames: if...
true
true
08f10bb86d664a8c8ec880656d7cf1b7d915c4f4
1,930
py
Python
setup.py
ebothmann/heppyplot
dab969879391f70a91c34f71482a9691b9c80141
[ "MIT" ]
null
null
null
setup.py
ebothmann/heppyplot
dab969879391f70a91c34f71482a9691b9c80141
[ "MIT" ]
null
null
null
setup.py
ebothmann/heppyplot
dab969879391f70a91c34f71482a9691b9c80141
[ "MIT" ]
null
null
null
from setuptools import setup, find_packages # Always prefer setuptools over distutils from codecs import open # To use a consistent encoding from os import path here = path.abspath(path.dirname(__file__)) # Get the long description from the relevant file with open(path.join(here, 'DESCRIPTION.md'), encoding='utf-8'...
31.129032
90
0.648187
from setuptools import setup, find_packages from codecs import open from os import path here = path.abspath(path.dirname(__file__)) with open(path.join(here, 'DESCRIPTION.md'), encoding='utf-8') as f: long_description = f.read() setup( name = 'heppyplot', version = '0.1.0.dev0', description =...
true
true
08f10bc50103e3c0184b5a09d1e34d3e8e8b6bd4
1,661
py
Python
src/livestreamer/plugins/rtve.py
jaccarmac/livestreamer
ab80dbd6560f6f9835865b2fc9f9c6015aee5658
[ "BSD-2-Clause", "MIT" ]
3,614
2015-01-01T08:07:27.000Z
2022-03-20T00:31:07.000Z
src/livestreamer/plugins/rtve.py
kviktor/livestreamer
ab80dbd6560f6f9835865b2fc9f9c6015aee5658
[ "BSD-2-Clause", "MIT" ]
1,028
2015-01-02T03:38:38.000Z
2021-08-06T16:17:48.000Z
src/livestreamer/plugins/rtve.py
kviktor/livestreamer
ab80dbd6560f6f9835865b2fc9f9c6015aee5658
[ "BSD-2-Clause", "MIT" ]
795
2015-01-02T06:12:04.000Z
2022-03-27T23:41:53.000Z
import re from livestreamer.plugin import Plugin, PluginError from livestreamer.plugin.api import http from livestreamer.stream import HLSStream # The last four channel_paths repsond with 301 and provide # a redirect location that corresponds to a channel_path above. _url_re = re.compile(r""" https?://www\.rtve\....
28.152542
92
0.657435
import re from livestreamer.plugin import Plugin, PluginError from livestreamer.plugin.api import http from livestreamer.stream import HLSStream _url_re = re.compile(r""" https?://www\.rtve\.es/ (?P<channel_path> directo/la-1| directo/la-2| directo/teledeporte| directo/canal-24...
true
true
08f10ce1617d006ba360016cd698d48164eae09a
5,322
py
Python
golly/Scripts/Python/LifeGenes/lifegenes_core/tests/folly.py
7yl4r/LifeGenes
cb2928ba9ddadd785fc55be443c117fb34eae967
[ "MIT" ]
11
2015-05-07T06:20:18.000Z
2020-10-07T13:29:42.000Z
golly/Scripts/Python/LifeGenes/lifegenes_core/tests/folly.py
7yl4r/LifeGenes
cb2928ba9ddadd785fc55be443c117fb34eae967
[ "MIT" ]
2
2016-11-20T21:25:27.000Z
2017-07-28T13:03:52.000Z
golly/Scripts/Python/LifeGenes/lifegenes_core/tests/folly.py
7yl4r/LifeGenes
cb2928ba9ddadd785fc55be443c117fb34eae967
[ "MIT" ]
null
null
null
# this module defines a fake golly-like environment. This is useful for testing and debugging. # to use simply put 'from LifeGenes.lifegenes_core.tests.folly import folly as g' in place of 'import golly as g' import logging class follyInstance: def __init__(self): # change these values to test different s...
33.898089
121
0.602405
import logging class follyInstance: def __init__(self): logging.warn('using mock-GoL "folly"') self.currentLayer = 0 self.curLayerEmpty= False self.layerColors = [[0,255]] self.layerNames = ['first!'] self.layerRules = ['life'] self.nLayers ...
false
true
08f10fe74a1cebd810fb727f60d4647c2427a31c
415
py
Python
launchkey/__init__.py
lordkyzr/launchkey-python
4a6c13c2e60c5f38c4cb749d6a887eb1ac813c0c
[ "MIT" ]
9
2017-10-12T02:45:23.000Z
2021-01-11T05:44:13.000Z
launchkey/__init__.py
lordkyzr/launchkey-python
4a6c13c2e60c5f38c4cb749d6a887eb1ac813c0c
[ "MIT" ]
31
2018-09-12T00:17:10.000Z
2022-01-31T21:35:04.000Z
launchkey/__init__.py
lordkyzr/launchkey-python
4a6c13c2e60c5f38c4cb749d6a887eb1ac813c0c
[ "MIT" ]
11
2017-01-31T21:45:29.000Z
2022-01-28T00:56:48.000Z
"""LaunchKey Service SDK module""" SDK_VERSION = '3.9.1' LAUNCHKEY_PRODUCTION = "https://api.launchkey.com" VALID_JWT_ISSUER_LIST = ["svc", "dir", "org"] JOSE_SUPPORTED_JWE_ALGS = ['RSA-OAEP'] JOSE_SUPPORTED_JWE_ENCS = ['A256CBC-HS512'] JOSE_SUPPORTED_JWT_ALGS = ["RS256", "RS384", "RS512"] JOSE_SUPPORTED_CONTENT_HASH_A...
34.583333
59
0.737349
SDK_VERSION = '3.9.1' LAUNCHKEY_PRODUCTION = "https://api.launchkey.com" VALID_JWT_ISSUER_LIST = ["svc", "dir", "org"] JOSE_SUPPORTED_JWE_ALGS = ['RSA-OAEP'] JOSE_SUPPORTED_JWE_ENCS = ['A256CBC-HS512'] JOSE_SUPPORTED_JWT_ALGS = ["RS256", "RS384", "RS512"] JOSE_SUPPORTED_CONTENT_HASH_ALGS = ["S256", "S384", "S512"] JOSE...
true
true
08f11020a6ce1ed9d857f74427addc0fa2f3796d
12,155
py
Python
gbs.py
duceppemo/gbs
8083250ff1df1f98b956393e8de5c5be8736dfab
[ "MIT" ]
null
null
null
gbs.py
duceppemo/gbs
8083250ff1df1f98b956393e8de5c5be8736dfab
[ "MIT" ]
null
null
null
gbs.py
duceppemo/gbs
8083250ff1df1f98b956393e8de5c5be8736dfab
[ "MIT" ]
null
null
null
#!/usr/local/env python3 # Dependencies # conda install bbmap # conda install pigz # pip install pysam # conda install blast # conda install bowtie2 # conda install samtools # conda install kmc # conda install jellyfish # conda install psutil # conda install biopython # conda install natsort # conda install pyVCF fr...
46.75
111
0.588564
from argparse import ArgumentParser from multiprocessing import cpu_count from psutil import virtual_memory import os from glob import glob from gbs_methods import Methods from deepvariant import DeepVariant from collections import defaultdict class GBS(object): def __init__(self, args): self.i...
true
true
08f1105bb3cf3a734d18bf90aa7df85b3640b555
4,934
py
Python
app.py
VonStruddle/treehouse_social_network
78d9eb927c0e80cad248fbde2ad5e8f6bb627c16
[ "MIT" ]
null
null
null
app.py
VonStruddle/treehouse_social_network
78d9eb927c0e80cad248fbde2ad5e8f6bb627c16
[ "MIT" ]
null
null
null
app.py
VonStruddle/treehouse_social_network
78d9eb927c0e80cad248fbde2ad5e8f6bb627c16
[ "MIT" ]
null
null
null
from flask import (Flask, g, render_template, flash, redirect, url_for) from flask.ext.bcrypt import check_password_hash from flask.ext.login import (LoginManager, login_user, logout_user, login_required, current_user) import forms import models DEBUG = True PORT = 8000 HOST =...
29.195266
82
0.608431
from flask import (Flask, g, render_template, flash, redirect, url_for) from flask.ext.bcrypt import check_password_hash from flask.ext.login import (LoginManager, login_user, logout_user, login_required, current_user) import forms import models DEBUG = True PORT = 8000 HOST =...
true
true
08f1107186392b57098cc4f40f2e13d321c6e410
6,066
py
Python
tools/certbot_wrapper.py
SKsample/king-phisher
7233d1ffa3db836bafb33efc43d682bb69335671
[ "BSD-3-Clause" ]
3
2018-12-17T02:54:18.000Z
2021-07-07T15:46:04.000Z
tools/certbot_wrapper.py
SKsample/king-phisher
7233d1ffa3db836bafb33efc43d682bb69335671
[ "BSD-3-Clause" ]
null
null
null
tools/certbot_wrapper.py
SKsample/king-phisher
7233d1ffa3db836bafb33efc43d682bb69335671
[ "BSD-3-Clause" ]
4
2017-09-14T03:02:40.000Z
2019-06-25T02:58:50.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # tools/certbot_wrapper.py # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of source code must retain the above copyright # notice, this l...
43.640288
113
0.753874
import argparse import logging import os import socket import subprocess import sys sys.path.insert(1, os.path.abspath(os.path.join(os.path.dirname(__file__), '..'))) import king_phisher.color as color import king_phisher.utilities as utilities import advancedhttpserver import smoke_zephyr.utilities import yaml LE...
true
true
08f111adee362022adae91d9cbee31c90d61fee8
855
py
Python
app/views.py
hand-code/cleanblog
0ce2bc8e2a113e85a6ee9a9c41ec7385f589b1d8
[ "MIT" ]
null
null
null
app/views.py
hand-code/cleanblog
0ce2bc8e2a113e85a6ee9a9c41ec7385f589b1d8
[ "MIT" ]
null
null
null
app/views.py
hand-code/cleanblog
0ce2bc8e2a113e85a6ee9a9c41ec7385f589b1d8
[ "MIT" ]
null
null
null
from flask import Blueprint, render_template, redirect, url_for from models import User, Post from flask.ext.login import current_user, logout_user bp = Blueprint('blog', __name__) @bp.route('/') @bp.route('/<int:page>') def index(page=1): paginator = Post.objects.paginate(page=page, per_page=5) return rende...
24.428571
80
0.711111
from flask import Blueprint, render_template, redirect, url_for from models import User, Post from flask.ext.login import current_user, logout_user bp = Blueprint('blog', __name__) @bp.route('/') @bp.route('/<int:page>') def index(page=1): paginator = Post.objects.paginate(page=page, per_page=5) return rende...
true
true
08f111d7f2f5e17dc0adaa94a6e3a0acfd8dfb2b
1,696
py
Python
tests/unit/client/conftest.py
FireboltJeff/firebolt-python-sdk
17f9870e43021bacf2690c3f881fff30becce677
[ "Apache-2.0" ]
null
null
null
tests/unit/client/conftest.py
FireboltJeff/firebolt-python-sdk
17f9870e43021bacf2690c3f881fff30becce677
[ "Apache-2.0" ]
null
null
null
tests/unit/client/conftest.py
FireboltJeff/firebolt-python-sdk
17f9870e43021bacf2690c3f881fff30becce677
[ "Apache-2.0" ]
null
null
null
import json import typing import httpx import pytest from httpx import Response @pytest.fixture def test_token() -> str: yield "test_token" @pytest.fixture def test_token2() -> str: yield "test_token2" @pytest.fixture def test_username() -> str: yield "username" @pytest.fixture def test_password() ...
25.69697
81
0.669222
import json import typing import httpx import pytest from httpx import Response @pytest.fixture def test_token() -> str: yield "test_token" @pytest.fixture def test_token2() -> str: yield "test_token2" @pytest.fixture def test_username() -> str: yield "username" @pytest.fixture def test_password() ...
true
true
08f1129936d5f1c3b580fe1b3265bfe53b9f8696
14,805
py
Python
lib/cogs/music.py
TheProfessor-dev/Cyborg
4f79d74c287c14f5b02c144660d5d0652f757ced
[ "MIT" ]
null
null
null
lib/cogs/music.py
TheProfessor-dev/Cyborg
4f79d74c287c14f5b02c144660d5d0652f757ced
[ "MIT" ]
null
null
null
lib/cogs/music.py
TheProfessor-dev/Cyborg
4f79d74c287c14f5b02c144660d5d0652f757ced
[ "MIT" ]
null
null
null
import asyncio import datetime as dt import random import re import typing as t from enum import Enum import discord import wavelink from discord.ext import commands URL_REGEX = r"(?i)\b((?:https?://|www\d{0,3}[.]|[a-z0-9.\-]+[.][a-z]{2,4}/)(?:[^\s()<>]+|\(([^\s()<>]+|(\([^\s()<>]+\)))*\))+(?:\(([^\s...
32.325328
198
0.581358
import asyncio import datetime as dt import random import re import typing as t from enum import Enum import discord import wavelink from discord.ext import commands URL_REGEX = r"(?i)\b((?:https?://|www\d{0,3}[.]|[a-z0-9.\-]+[.][a-z]{2,4}/)(?:[^\s()<>]+|\(([^\s()<>]+|(\([^\s()<>]+\)))*\))+(?:\(([^\s...
true
true
08f112f153c8a5c5769e24800fa432e4f7728b7d
2,283
py
Python
MOOCS/Cs224n_2019/a2/run.py
itismesam/Courses-1
7669c4460be02b8bbaea2ae79182af2667e9e6b2
[ "MIT" ]
40
2020-09-30T13:45:50.000Z
2022-03-10T10:22:19.000Z
MOOCS/Cs224n_2019/a2/run.py
itismesam/Courses-1
7669c4460be02b8bbaea2ae79182af2667e9e6b2
[ "MIT" ]
null
null
null
MOOCS/Cs224n_2019/a2/run.py
itismesam/Courses-1
7669c4460be02b8bbaea2ae79182af2667e9e6b2
[ "MIT" ]
24
2020-10-06T07:05:38.000Z
2022-03-10T10:23:29.000Z
#!/usr/bin/env python import random import numpy as np from utils.treebank import StanfordSentiment import matplotlib matplotlib.use('agg') import matplotlib.pyplot as plt import time from word2vec import * from sgd import * # Check Python Version import sys assert sys.version_info[0] == 3 assert sys.version_info[1]...
29.649351
82
0.70346
import random import numpy as np from utils.treebank import StanfordSentiment import matplotlib matplotlib.use('agg') import matplotlib.pyplot as plt import time from word2vec import * from sgd import * import sys assert sys.version_info[0] == 3 assert sys.version_info[1] >= 5 random.seed(314) dataset = StanfordSen...
true
true
08f1141a6305aa8f002c70ec026d57360b64fb5f
3,387
py
Python
dataset.py
ankitgpt231/pytorch-0.4-yolov3
5a9c05385b0dbb2e2366659139e09c23cb99b140
[ "MIT" ]
null
null
null
dataset.py
ankitgpt231/pytorch-0.4-yolov3
5a9c05385b0dbb2e2366659139e09c23cb99b140
[ "MIT" ]
null
null
null
dataset.py
ankitgpt231/pytorch-0.4-yolov3
5a9c05385b0dbb2e2366659139e09c23cb99b140
[ "MIT" ]
null
null
null
#!/usr/bin/python # encoding: utf-8 import os import random import torch import numpy as np from torch.utils.data import Dataset from PIL import Image from utils import read_truths_args, read_truths from image import * class listDataset(Dataset): def __init__(self, root, shape=None, shuffle=True, crop=False, jitt...
36.031915
208
0.571597
import os import random import torch import numpy as np from torch.utils.data import Dataset from PIL import Image from utils import read_truths_args, read_truths from image import * class listDataset(Dataset): def __init__(self, root, shape=None, shuffle=True, crop=False, jitter=0.3, hue=0.1, saturation=1.5, exp...
true
true
08f114acc0d82f620b8328982205cb88fcd1ea8a
4,298
py
Python
scripts/run_parallel_convert_visit_to_paraview.py
alexkaiser/heart_valves
53f30ec3680503542890a84949b7fb51d1734272
[ "BSD-3-Clause" ]
null
null
null
scripts/run_parallel_convert_visit_to_paraview.py
alexkaiser/heart_valves
53f30ec3680503542890a84949b7fb51d1734272
[ "BSD-3-Clause" ]
null
null
null
scripts/run_parallel_convert_visit_to_paraview.py
alexkaiser/heart_valves
53f30ec3680503542890a84949b7fb51d1734272
[ "BSD-3-Clause" ]
null
null
null
import os, sys, subprocess, time def fix_visit_files(viz_directory): ''' Checks viz directory to find output increment and rewrites visit files ''' prev_dir = os.getcwd() os.chdir(viz_directory) # minimum nonzero step min_nonzero = float('Inf') max_idx = 0 ...
31.372263
122
0.521638
import os, sys, subprocess, time def fix_visit_files(viz_directory): ''' Checks viz directory to find output increment and rewrites visit files ''' prev_dir = os.getcwd() os.chdir(viz_directory) min_nonzero = float('Inf') max_idx = 0 for f in os.listdir...
false
true
08f1176f71a462b07ab774b82183283ee3b25a4b
773
py
Python
article/migrations/0066_teammemberdetails.py
higab85/drugsandme
7db66d9687ac9a04132de94edda364f191d497d7
[ "MIT" ]
3
2016-10-10T10:07:39.000Z
2018-10-29T19:57:52.000Z
article/migrations/0066_teammemberdetails.py
higab85/drugsandme
7db66d9687ac9a04132de94edda364f191d497d7
[ "MIT" ]
12
2016-11-04T18:59:17.000Z
2022-03-11T23:32:52.000Z
article/migrations/0066_teammemberdetails.py
higab85/drugsandme
7db66d9687ac9a04132de94edda364f191d497d7
[ "MIT" ]
2
2016-09-29T22:48:26.000Z
2019-10-01T19:55:14.000Z
# Generated by Django 2.1 on 2019-03-10 11:36 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('wagtailimages', '0001_squashed_0021'), ('article', '0065_auto_20190104_2054'), ] operations = [ migra...
32.208333
156
0.627426
from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('wagtailimages', '0001_squashed_0021'), ('article', '0065_auto_20190104_2054'), ] operations = [ migrations.CreateModel( name='TeamMembe...
true
true
08f11771ca653959b6e871d68d0d5ee67023204b
260
py
Python
college/college/doctype/recruiter_list/recruiter_list.py
ashithamudraje/college
fcfb5fa47c8815d659821390ea9c85d598d34c19
[ "MIT" ]
1
2019-09-08T19:27:27.000Z
2019-09-08T19:27:27.000Z
college/college/doctype/recruiter_list/recruiter_list.py
ashithamudraje/college
fcfb5fa47c8815d659821390ea9c85d598d34c19
[ "MIT" ]
null
null
null
college/college/doctype/recruiter_list/recruiter_list.py
ashithamudraje/college
fcfb5fa47c8815d659821390ea9c85d598d34c19
[ "MIT" ]
4
2019-09-23T16:42:12.000Z
2020-05-01T06:56:57.000Z
# -*- coding: utf-8 -*- # Copyright (c) 2020, mvit ise and contributors # For license information, please see license.txt from __future__ import unicode_literals # import frappe from frappe.model.document import Document class RecruiterList(Document): pass
23.636364
49
0.773077
from __future__ import unicode_literals from frappe.model.document import Document class RecruiterList(Document): pass
true
true
08f117a5928eea66e125471677dfb621e8edfade
3,080
py
Python
prompt_toolkit/input/posix_pipe.py
CarliJoy/python-prompt-toolkit
8bdaf3556c8ff9aea8ac02c74e5141cb8d9147f1
[ "BSD-3-Clause" ]
null
null
null
prompt_toolkit/input/posix_pipe.py
CarliJoy/python-prompt-toolkit
8bdaf3556c8ff9aea8ac02c74e5141cb8d9147f1
[ "BSD-3-Clause" ]
null
null
null
prompt_toolkit/input/posix_pipe.py
CarliJoy/python-prompt-toolkit
8bdaf3556c8ff9aea8ac02c74e5141cb8d9147f1
[ "BSD-3-Clause" ]
null
null
null
import os from contextlib import contextmanager from typing import ContextManager, Iterator, TextIO, cast from ..utils import DummyContext from .base import PipeInput from .vt100 import Vt100Input __all__ = [ "PosixPipeInput", ] class _Pipe: "Wrapper around os.pipe, that ensures we don't double close any en...
27.256637
79
0.60974
import os from contextlib import contextmanager from typing import ContextManager, Iterator, TextIO, cast from ..utils import DummyContext from .base import PipeInput from .vt100 import Vt100Input __all__ = [ "PosixPipeInput", ] class _Pipe: def __init__(self) -> None: self.read_fd, self.write_fd =...
true
true
08f117aeb0cffc17506aeb6010d2aaac28e686a5
4,460
py
Python
automl/google/cloud/automl_v1beta1/proto/temporal_pb2.py
Kami/google-cloud-python
a14ffbaa50f7823c2792e91413a37cbc3ce687f5
[ "Apache-2.0" ]
1
2019-06-14T10:11:59.000Z
2019-06-14T10:11:59.000Z
automl/google/cloud/automl_v1beta1/proto/temporal_pb2.py
Kami/google-cloud-python
a14ffbaa50f7823c2792e91413a37cbc3ce687f5
[ "Apache-2.0" ]
1
2018-04-06T19:51:23.000Z
2018-04-06T19:51:23.000Z
automl/google/cloud/automl_v1beta1/proto/temporal_pb2.py
Kami/google-cloud-python
a14ffbaa50f7823c2792e91413a37cbc3ce687f5
[ "Apache-2.0" ]
1
2020-04-14T10:47:41.000Z
2020-04-14T10:47:41.000Z
# Generated by the protocol buffer compiler. DO NOT EDIT! # source: google/cloud/automl_v1beta1/proto/temporal.proto import sys _b = sys.version_info[0] < 3 and (lambda x: x) or (lambda x: x.encode("latin1")) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from g...
34.573643
528
0.699103
import sys _b = sys.version_info[0] < 3 and (lambda x: x) or (lambda x: x.encode("latin1")) from google.protobuf import descriptor as _descriptor from google.protobuf import message as _message from google.protobuf import reflection as _reflection from google.protobuf import symbol_database as _symbol_database _sym...
true
true
08f118ed9e95cda69f3f35710adbb4df72ac15fc
18,825
py
Python
tests/test_evo.py
cbwang2016/quimb
633ae4117e6fc5518f9b1bc07a0ae734f058072c
[ "Apache-2.0" ]
264
2018-01-30T10:06:09.000Z
2022-03-28T01:39:40.000Z
tests/test_evo.py
adamcallison/quimb
a06fb9fc58976936bf7d631179ece0f832bf96a9
[ "Apache-2.0" ]
114
2017-10-24T22:37:15.000Z
2022-03-31T18:58:55.000Z
tests/test_evo.py
adamcallison/quimb
a06fb9fc58976936bf7d631179ece0f832bf96a9
[ "Apache-2.0" ]
60
2017-10-24T22:28:43.000Z
2022-02-28T13:54:20.000Z
from pytest import fixture, mark, raises from math import pi, gcd, cos from functools import reduce import numpy as np from numpy.testing import assert_allclose import quimb as qu from quimb.evo import ( schrodinger_eq_ket, schrodinger_eq_dop, schrodinger_eq_dop_vectorized, lindblad_eq, lindblad_...
35.055866
79
0.561594
from pytest import fixture, mark, raises from math import pi, gcd, cos from functools import reduce import numpy as np from numpy.testing import assert_allclose import quimb as qu from quimb.evo import ( schrodinger_eq_ket, schrodinger_eq_dop, schrodinger_eq_dop_vectorized, lindblad_eq, lindblad_...
true
true
08f11bd41d3b810d865e2cd9bdb10b928b1e6d62
651
py
Python
Coursera/Week.2/Task.13.py
v1nnyb0y/Coursera.BasePython
bbfb3184dc27a4cdb16b087123890991afbc5506
[ "MIT" ]
null
null
null
Coursera/Week.2/Task.13.py
v1nnyb0y/Coursera.BasePython
bbfb3184dc27a4cdb16b087123890991afbc5506
[ "MIT" ]
null
null
null
Coursera/Week.2/Task.13.py
v1nnyb0y/Coursera.BasePython
bbfb3184dc27a4cdb16b087123890991afbc5506
[ "MIT" ]
null
null
null
''' Type of the rectangular ''' import math a = int(input()) b = int(input()) c = int(input()) if a + b <= c or a + c <= b or b + c <= a or a + b + c <= 0: print('impossible') else: if b < c: t = b b = c c = t if a < b: t = a a = b b = t if b < c: ...
17.594595
64
0.347158
import math a = int(input()) b = int(input()) c = int(input()) if a + b <= c or a + c <= b or b + c <= a or a + b + c <= 0: print('impossible') else: if b < c: t = b b = c c = t if a < b: t = a a = b b = t if b < c: t = b b = c c ...
true
true
08f11ce88ef42c5b798b7131e6cd967b54767986
8,268
py
Python
networkx/release.py
bjedwards/NetworkX_fork
6cb4465d73b8adc4692206fdbc8e1a3934d94fe6
[ "BSD-3-Clause" ]
3
2016-02-06T01:18:41.000Z
2020-11-10T08:15:33.000Z
networkx/release.py
tomzhang/NetworkX_fork
6cb4465d73b8adc4692206fdbc8e1a3934d94fe6
[ "BSD-3-Clause" ]
null
null
null
networkx/release.py
tomzhang/NetworkX_fork
6cb4465d73b8adc4692206fdbc8e1a3934d94fe6
[ "BSD-3-Clause" ]
7
2015-04-28T19:19:30.000Z
2022-02-06T11:46:29.000Z
"""Release data for NetworkX. When NetworkX is imported a number of steps are followed to determine the version information. 1) If the release is not a development release (dev=False), then version information is read from version.py, a file containing statically defined version information. This file...
34.165289
106
0.647678
from __future__ import absolute_import import os import sys import time import datetime import subprocess basedir = os.path.abspath(os.path.split(__file__)[0]) def write_versionfile(): versionfile = os.path.join(basedir, 'version.py') text = '''""" Version information for NetworkX, created during installa...
true
true
08f11d7ed6454c304593f62982eca315af70dcd8
996
py
Python
examples/delayed_diamond/make_top_dag.py
JoshKarpel/htcondor-dags
2090f9d4c044a5b0a1f538162c5577e6722ed3e5
[ "Apache-2.0" ]
2
2019-09-21T14:40:37.000Z
2019-11-19T16:36:22.000Z
examples/delayed_diamond/make_top_dag.py
JoshKarpel/htcondor-dags
2090f9d4c044a5b0a1f538162c5577e6722ed3e5
[ "Apache-2.0" ]
15
2019-08-07T15:40:05.000Z
2020-07-24T16:54:15.000Z
examples/delayed_diamond/make_top_dag.py
JoshKarpel/htcondor-dags
2090f9d4c044a5b0a1f538162c5577e6722ed3e5
[ "Apache-2.0" ]
1
2019-09-24T17:34:13.000Z
2019-09-24T17:34:13.000Z
#!/usr/bin/env python from pathlib import Path import htcondor from htcondor import dags top_layer_dag = dags.DAG() # This is the "split" step. It stays in the top-level DAG. # Note that split_words.py no longer takes arguments. It determines the number # of chunks itself. split_words = top_layer_dag.layer( nam...
29.294118
84
0.699799
from pathlib import Path import htcondor from htcondor import dags top_layer_dag = dags.DAG() split_words = top_layer_dag.layer( name="split_words", submit_description=htcondor.Submit( { "executable": "split_words.py", "transfer_input_files": "words.txt", "output"...
true
true
08f11e6e875f25137c39f56ed62df6b31d5659af
7,042
py
Python
3ddfa/inference.py
priyanshu2103/Rotate-and-Render
34771076e1284a1de534a391d724128bfba6f06f
[ "CC-BY-4.0" ]
null
null
null
3ddfa/inference.py
priyanshu2103/Rotate-and-Render
34771076e1284a1de534a391d724128bfba6f06f
[ "CC-BY-4.0" ]
null
null
null
3ddfa/inference.py
priyanshu2103/Rotate-and-Render
34771076e1284a1de534a391d724128bfba6f06f
[ "CC-BY-4.0" ]
null
null
null
#!/usr/bin/env python3 # coding: utf-8 __author__ = 'cleardusk' """ The pipeline of 3DDFA prediction: given one image, predict the 3d face vertices, 68 landmarks and visualization. [todo] 1. CPU optimization: https://pmchojnacki.wordpress.com/2018/10/07/slow-pytorch-cpu-performance """ import torch import torchvisi...
41.423529
133
0.654928
__author__ = 'cleardusk' import torch import torchvision.transforms as transforms import mobilenet_v1 import numpy as np import cv2 import os import math from tqdm import tqdm import time import face_alignment from utils.ddfa import ToTensorGjz, NormalizeGjz, str2bool import scipy.io as sio from utils.inference impo...
true
true
08f11f92a111fce207d586ca7664a5f6e17ac9cf
28,017
py
Python
src/httprest.py
SourceZh/Docklet
2e9d2ec84abb6d1891908035ea18e7c0f9ed0ee5
[ "BSD-3-Clause" ]
null
null
null
src/httprest.py
SourceZh/Docklet
2e9d2ec84abb6d1891908035ea18e7c0f9ed0ee5
[ "BSD-3-Clause" ]
null
null
null
src/httprest.py
SourceZh/Docklet
2e9d2ec84abb6d1891908035ea18e7c0f9ed0ee5
[ "BSD-3-Clause" ]
null
null
null
#!/usr/bin/python3 # load environment variables in the beginning # because some modules need variables when import # for example, userManager/model.py # must first init loadenv import tools, env config = env.getenv("CONFIG") tools.loadenv(config) # second init logging # must import logger after initlogging, ugly fro...
47.81058
123
0.550701
import tools, env config = env.getenv("CONFIG") tools.loadenv(config) from log import initlogging initlogging("docklet-master") from log import logger import os import http.server, cgi, json, sys, shutil from socketserver import ThreadingMixIn import nodemgr, vclustermgr, etcdlib, network, imagemgr import userManag...
true
true
08f11ff058066628225c937e12b069901dc3f835
818
py
Python
armulator/armv6/opcodes/arm_instruction_set/arm_data_processing_and_miscellaneous_instructions/arm_data_processing_register/cmp_register_a1.py
matan1008/armulator
04d24dcec6ab42326018f5e09331e5b4738d6b52
[ "MIT" ]
16
2018-01-22T14:36:49.000Z
2021-12-17T15:39:52.000Z
armulator/armv6/opcodes/arm_instruction_set/arm_data_processing_and_miscellaneous_instructions/arm_data_processing_register/cmp_register_a1.py
AhmedMounir/armulator
04d24dcec6ab42326018f5e09331e5b4738d6b52
[ "MIT" ]
3
2019-02-19T17:51:47.000Z
2022-03-31T20:45:21.000Z
armulator/armv6/opcodes/arm_instruction_set/arm_data_processing_and_miscellaneous_instructions/arm_data_processing_register/cmp_register_a1.py
AhmedMounir/armulator
04d24dcec6ab42326018f5e09331e5b4738d6b52
[ "MIT" ]
4
2020-06-18T23:51:03.000Z
2022-02-09T17:43:13.000Z
from armulator.armv6.opcodes.abstract_opcodes.cmp_register import CmpRegister from armulator.armv6.opcodes.opcode import Opcode from armulator.armv6.shift import decode_imm_shift class CmpRegisterA1(CmpRegister, Opcode): def __init__(self, instruction, m, n, shift_t, shift_n): Opcode.__init__(self, instru...
35.565217
86
0.656479
from armulator.armv6.opcodes.abstract_opcodes.cmp_register import CmpRegister from armulator.armv6.opcodes.opcode import Opcode from armulator.armv6.shift import decode_imm_shift class CmpRegisterA1(CmpRegister, Opcode): def __init__(self, instruction, m, n, shift_t, shift_n): Opcode.__init__(self, instru...
true
true
08f12249d919b6beee1dfc3261a157af23c9543f
1,455
py
Python
extract_missing_tiles.py
nicolas-sitylb/tests
f992e173a35f73605bfd11f50fb46df85d4c3ed0
[ "X11" ]
null
null
null
extract_missing_tiles.py
nicolas-sitylb/tests
f992e173a35f73605bfd11f50fb46df85d4c3ed0
[ "X11" ]
null
null
null
extract_missing_tiles.py
nicolas-sitylb/tests
f992e173a35f73605bfd11f50fb46df85d4c3ed0
[ "X11" ]
null
null
null
# -*- coding: utf-8 -*- # Author Nicolas Blanc@SITYLB def extract_missing_tiles(): file_all = 'tuiles_swissimages_nord_vaudois.csv' #file_existing = 'ortho.csv' #file_existing = 'lidar.csv' file_existing = 'mnt.csv' with open(file_existing) as fe, open(file_all) as fa: data_fa = ...
41.571429
136
0.67079
def extract_missing_tiles(): file_all = 'tuiles_swissimages_nord_vaudois.csv' file_existing = 'mnt.csv' with open(file_existing) as fe, open(file_all) as fa: data_fa = fa.readlines() dataFe = fe.read() data_fa = [row_fa.strip('\n') for row_fa in data_fa] mat...
true
true
08f1237b6c6a3d49e1f06ca468505c56ff04885d
4,448
py
Python
pyocd/target/builtin/target_STM32F051xx.py
mesheven/mesh-pyocd
88136b920fa15d518d2dc8b78ef39e33e9d80cc1
[ "Apache-2.0" ]
null
null
null
pyocd/target/builtin/target_STM32F051xx.py
mesheven/mesh-pyocd
88136b920fa15d518d2dc8b78ef39e33e9d80cc1
[ "Apache-2.0" ]
null
null
null
pyocd/target/builtin/target_STM32F051xx.py
mesheven/mesh-pyocd
88136b920fa15d518d2dc8b78ef39e33e9d80cc1
[ "Apache-2.0" ]
1
2019-01-21T03:01:53.000Z
2019-01-21T03:01:53.000Z
""" mbed CMSIS-DAP debugger Copyright (c) 2006-2013 ARM Limited 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 ...
47.827957
129
0.630845
from ...flash.flash import Flash from ...coresight.coresight_target import CoreSightTarget from ...core.memory_map import (FlashRegion, RamRegion, MemoryMap) from ...debug.svd.loader import SVDFile import logging RCC_APB2ENR_CR = 0x40021018 RCC_APB2ENR_DBGMCU = 0x00400000 DBGMCU_CR = 0x40015804 DBGMCU_APB1_...
true
true
08f123a32e04da5286b9494e1b34c314f5834b8e
39,574
py
Python
ipython_config.py
mrakitin/profile_olog
55603a232c620fce4f41fe07548ed4ad5edff0cf
[ "BSD-3-Clause" ]
null
null
null
ipython_config.py
mrakitin/profile_olog
55603a232c620fce4f41fe07548ed4ad5edff0cf
[ "BSD-3-Clause" ]
null
null
null
ipython_config.py
mrakitin/profile_olog
55603a232c620fce4f41fe07548ed4ad5edff0cf
[ "BSD-3-Clause" ]
null
null
null
# Configuration file for ipython. #------------------------------------------------------------------------------ # InteractiveShellApp(Configurable) configuration #------------------------------------------------------------------------------ ## A Mixin for applications that start InteractiveShell instances. # # ...
37.617871
247
0.682317
# Default: False # c.BaseIPythonApplication.auto_create = False ## Whether to install the default config files into the profile dir. # If a new profile is being created, and IPython contains config files for that # profile, then they will be staged into the new directory. O...
true
true
08f12438a512e9a1361e418bd1c9042b0da2ffa9
3,238
py
Python
notes/algo-ds-practice/problems/dp/stock_buy_sell_k/stock_buy_sell_k.py
Anmol-Singh-Jaggi/interview-notes
65af75e2b5725894fa5e13bb5cd9ecf152a0d652
[ "MIT" ]
6
2020-07-05T05:15:19.000Z
2021-01-24T20:17:14.000Z
notes/algo-ds-practice/problems/dp/stock_buy_sell_k/stock_buy_sell_k.py
Anmol-Singh-Jaggi/interview-notes
65af75e2b5725894fa5e13bb5cd9ecf152a0d652
[ "MIT" ]
null
null
null
notes/algo-ds-practice/problems/dp/stock_buy_sell_k/stock_buy_sell_k.py
Anmol-Singh-Jaggi/interview-notes
65af75e2b5725894fa5e13bb5cd9ecf152a0d652
[ "MIT" ]
2
2020-09-14T06:46:37.000Z
2021-06-15T09:17:21.000Z
''' The cost of a stock on each day is given in an array. Find the max profit that you can make by buying and selling in those days, a maximum `k` times only. Only 1 stock can be held at a time. For example: **Input**:<br> Price = [10, 22, 5, 75, 65, 80]<br> K = 2 **Output**: 87<br> Trader earns 87 as sum of 12 and ...
30.54717
190
0.602532
def stock_maximize_k(stocks, k): ans = [[0 for j in range(len(stocks))] for i in range(k + 1)] for t in range(1, k + 1): for i in range(1, len(stocks)): no_sell = ans[t][i - 1] yes_sell = 0 for j in range(0, i): if stocks[i] > stocks[j]: ...
true
true
08f12480c6a29d2246e35de584f11e46100b6605
1,454
py
Python
scripts/feeds/uniswapv3/create.py
overlay-market/v1-core
e18fabd242f21c243a555712d3f08ca059941f41
[ "MIT" ]
3
2022-02-17T16:11:39.000Z
2022-03-10T23:46:19.000Z
scripts/feeds/uniswapv3/create.py
overlay-market/v1-core
e18fabd242f21c243a555712d3f08ca059941f41
[ "MIT" ]
10
2022-01-25T21:49:20.000Z
2022-03-31T00:32:29.000Z
scripts/feeds/uniswapv3/create.py
overlay-market/v1-core
e18fabd242f21c243a555712d3f08ca059941f41
[ "MIT" ]
2
2022-01-21T01:04:54.000Z
2022-02-23T08:38:20.000Z
import click from brownie import OverlayV1UniswapV3Factory, accounts, network # TODO: change UNIV3_FEED_FACTORY = "0x1C897298324BdAC1bB80d89E30b4D2529E98ADaE" def main(): """ Creates a new OverlayV1UniswapV3Feed through feed factory `deployFeed()` function. """ click.echo(f"You are using the '{...
30.93617
72
0.64099
import click from brownie import OverlayV1UniswapV3Factory, accounts, network UNIV3_FEED_FACTORY = "0x1C897298324BdAC1bB80d89E30b4D2529E98ADaE" def main(): click.echo(f"You are using the '{network.show_active()}' network") dev = accounts.load(click.prompt( "Account", type=click.Choice(accounts.load...
true
true
08f124fdad72a15475e23fad53cdb30b8f0f81b9
1,955
py
Python
src/tests/test_task_3_5.py
Python-course/Python-course
59de0ef9928aeaa5dd185ceaafa334eb8e719217
[ "MIT" ]
null
null
null
src/tests/test_task_3_5.py
Python-course/Python-course
59de0ef9928aeaa5dd185ceaafa334eb8e719217
[ "MIT" ]
null
null
null
src/tests/test_task_3_5.py
Python-course/Python-course
59de0ef9928aeaa5dd185ceaafa334eb8e719217
[ "MIT" ]
null
null
null
""" Тесты для задания 3.4. """ from unittest import TestCase, main from tasks import task_3_5 class TestToSymmetricTernaryNumber(TestCase): def test_to_symmetric_ternary_number__CorrectArguments__ShouldReturnCorrectResult(self): """ Проверяет работу с корректными данными. """ da...
25.064103
106
0.382609
from unittest import TestCase, main from tasks import task_3_5 class TestToSymmetricTernaryNumber(TestCase): def test_to_symmetric_ternary_number__CorrectArguments__ShouldReturnCorrectResult(self): data = [ (-5, "-++"), (-4, "--"), (-3, "-0"), (-2, "-+...
true
true
08f1261fa79c9cfd8c9f1f1f53acd762f03ab013
5,430
py
Python
test/functional/sapling_key_import_export.py
Kozisto/FreedomCoin-Core
ba4f6def338c58616ece13d890393552e657d3f0
[ "MIT" ]
null
null
null
test/functional/sapling_key_import_export.py
Kozisto/FreedomCoin-Core
ba4f6def338c58616ece13d890393552e657d3f0
[ "MIT" ]
1
2022-02-11T23:23:05.000Z
2022-02-11T23:23:05.000Z
test/functional/sapling_key_import_export.py
FreedomCoin-Project/FreedomCoin-Core
46e09320dd9903137433fc71aa9186fa3cdbe866
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # Copyright (c) 2017 The Zcash developers # Copyright (c) 2020 The FreedomCoin developers # Distributed under the MIT software license, see the accompanying # file COPYING or https://www.opensource.org/licenses/mit-license.php . from decimal import Decimal from functools import reduce from test...
39.926471
106
0.641252
from decimal import Decimal from functools import reduce from test_framework.test_framework import FreedomCoinTestFramework from test_framework.util import assert_equal, assert_greater_than class SaplingkeyImportExportTest (FreedomCoinTestFramework): def set_test_params(self): self.num_nodes = 5 ...
true
true
08f1266116865b7c86338a7195858b3e702683bf
30,650
py
Python
sdk/python/pulumi_azure_native/network/v20180401/network_interface.py
polivbr/pulumi-azure-native
09571f3bf6bdc4f3621aabefd1ba6c0d4ecfb0e7
[ "Apache-2.0" ]
null
null
null
sdk/python/pulumi_azure_native/network/v20180401/network_interface.py
polivbr/pulumi-azure-native
09571f3bf6bdc4f3621aabefd1ba6c0d4ecfb0e7
[ "Apache-2.0" ]
null
null
null
sdk/python/pulumi_azure_native/network/v20180401/network_interface.py
polivbr/pulumi-azure-native
09571f3bf6bdc4f3621aabefd1ba6c0d4ecfb0e7
[ "Apache-2.0" ]
null
null
null
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi SDK Generator. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union, overload from ... import _utilities fro...
55.125899
5,553
0.69217
import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union, overload from ... import _utilities from . import outputs from ._enums import * from ._inputs import * __all__ = ['NetworkInterfaceArgs', 'NetworkInterface'] @pulumi.input_type class NetworkInterfaceArgs: ...
true
true
08f127c3d31e05896657f612cb509f87dd1bb312
3,633
py
Python
pihid/USBInstaller.py
bkosciow/pihid
4417b94dbd5c86572fd137933b3eb195077e4456
[ "MIT" ]
1
2019-11-20T23:14:00.000Z
2019-11-20T23:14:00.000Z
pihid/USBInstaller.py
bkosciow/pihid
4417b94dbd5c86572fd137933b3eb195077e4456
[ "MIT" ]
null
null
null
pihid/USBInstaller.py
bkosciow/pihid
4417b94dbd5c86572fd137933b3eb195077e4456
[ "MIT" ]
null
null
null
import os class Installer(object): def __init__(self, device): self.device = device def is_installed(self): return self._dir_exists(self.device.path) def install(self): self._create_dirs() self._create_files() self._create_configs() self._create_functions(...
38.242105
122
0.608863
import os class Installer(object): def __init__(self, device): self.device = device def is_installed(self): return self._dir_exists(self.device.path) def install(self): self._create_dirs() self._create_files() self._create_configs() self._create_functions(...
true
true
08f128250f72efe6d40220d9c6e690fb3238dcfa
734
py
Python
make_class.py
Matgen-project/ABACUSflow
6d210be17aa14e42e531671f15771ca4de0edbbc
[ "MIT" ]
null
null
null
make_class.py
Matgen-project/ABACUSflow
6d210be17aa14e42e531671f15771ca4de0edbbc
[ "MIT" ]
null
null
null
make_class.py
Matgen-project/ABACUSflow
6d210be17aa14e42e531671f15771ca4de0edbbc
[ "MIT" ]
null
null
null
#!/usr/env/python import os import os.path as osp from monty.os import cd from pathlib import Path import sys def _yield(path): yield from (osp.join(path, i) for i in os.listdir(path)) def _mk_cls(path, cls_num): lst = list(_yield(path)) clst = [lst[i:i + cls_num] for i in range(0, len(lst), cls_num)] ...
22.9375
68
0.570845
import os import os.path as osp from monty.os import cd from pathlib import Path import sys def _yield(path): yield from (osp.join(path, i) for i in os.listdir(path)) def _mk_cls(path, cls_num): lst = list(_yield(path)) clst = [lst[i:i + cls_num] for i in range(0, len(lst), cls_num)] with cd(path): ...
true
true
08f129a81494dc34bc97d96fbc9f3d9fcf5545e1
1,814
py
Python
dataclasses_tensor/adapters.py
kachayev/dataclasses-tensor
ec7dcb15ee8bd15e8d6f4bcab484d78a5ec3cf68
[ "MIT" ]
14
2021-03-19T03:33:06.000Z
2021-12-25T16:23:02.000Z
dataclasses_tensor/adapters.py
kachayev/dataclasses-tensor
ec7dcb15ee8bd15e8d6f4bcab484d78a5ec3cf68
[ "MIT" ]
null
null
null
dataclasses_tensor/adapters.py
kachayev/dataclasses-tensor
ec7dcb15ee8bd15e8d6f4bcab484d78a5ec3cf68
[ "MIT" ]
null
null
null
from typing import Union class TensorAdapter: def zeros(self, size: int, dtype: str): raise NotImplemented() def argmax(self, arr): raise NotImplemented() def get(self, tensor, pos): raise NotImplemented() try: import numpy as np class NumpyAdapter(TensorAdapter): ...
29.258065
69
0.609702
from typing import Union class TensorAdapter: def zeros(self, size: int, dtype: str): raise NotImplemented() def argmax(self, arr): raise NotImplemented() def get(self, tensor, pos): raise NotImplemented() try: import numpy as np class NumpyAdapter(TensorAdapter): ...
true
true
08f12a58903dab0fdcee07dc8fb28e8a19a4cbd0
1,548
py
Python
titania/trainers/generic_managers.py
nathan-az/titania
98e49e73a66fc98ca0aba4d56f362ae574fd6fbe
[ "Apache-2.0" ]
null
null
null
titania/trainers/generic_managers.py
nathan-az/titania
98e49e73a66fc98ca0aba4d56f362ae574fd6fbe
[ "Apache-2.0" ]
null
null
null
titania/trainers/generic_managers.py
nathan-az/titania
98e49e73a66fc98ca0aba4d56f362ae574fd6fbe
[ "Apache-2.0" ]
null
null
null
from abc import ABC, abstractmethod import cloudpickle import pandas as pd import pyspark class BaseModelManager(ABC): @abstractmethod def __init__(self, *args, **kwargs): raise NotImplementedError @abstractmethod def train(self, *args, **kwargs): raise NotImplementedError @abst...
25.8
72
0.638889
from abc import ABC, abstractmethod import cloudpickle import pandas as pd import pyspark class BaseModelManager(ABC): @abstractmethod def __init__(self, *args, **kwargs): raise NotImplementedError @abstractmethod def train(self, *args, **kwargs): raise NotImplementedError @abst...
true
true
08f12a7a45cc4f5a3acea4f5d758d6aa8b2b29ad
101,428
py
Python
influxdb_client/service/dashboards_service.py
kelseiv/influxdb-client-python
9a0d2d659157cca96f6a04818fdeb215d699bdd7
[ "MIT" ]
1
2021-06-06T10:39:47.000Z
2021-06-06T10:39:47.000Z
influxdb_client/service/dashboards_service.py
kelseiv/influxdb-client-python
9a0d2d659157cca96f6a04818fdeb215d699bdd7
[ "MIT" ]
null
null
null
influxdb_client/service/dashboards_service.py
kelseiv/influxdb-client-python
9a0d2d659157cca96f6a04818fdeb215d699bdd7
[ "MIT" ]
null
null
null
# coding: utf-8 """ Influx API Service No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 OpenAPI spec version: 0.1.0 Generated by: https://openapi-generator.tech """ from __future__ import absolute_import import re # noqa: F40...
44.505485
166
0.640267
from __future__ import absolute_import import re import six from influxdb_client.api_client import ApiClient class DashboardsService(object): def __init__(self, api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client def delete_dashbo...
true
true
08f12b5446bc12f6b2ccd77f9a079eec971dc641
15,883
py
Python
handy-scripts/poller_Feb2018.py
aarontimko/alexis-project
64b6fe19ae152ad5f6b0840e874f857ccd70bcda
[ "BSD-3-Clause" ]
null
null
null
handy-scripts/poller_Feb2018.py
aarontimko/alexis-project
64b6fe19ae152ad5f6b0840e874f857ccd70bcda
[ "BSD-3-Clause" ]
null
null
null
handy-scripts/poller_Feb2018.py
aarontimko/alexis-project
64b6fe19ae152ad5f6b0840e874f857ccd70bcda
[ "BSD-3-Clause" ]
1
2022-03-16T04:26:30.000Z
2022-03-16T04:26:30.000Z
import requests import calendar import alexis.common from alexis.common import * # ----------------------------------- # # LOCAL FUNCTIONS # ----------------------------------- # def build_url_with_lookback(url, lookback, lookback_unit="s", epoch_unit="ms"): """ Takes a url with "$lookba...
36.596774
101
0.508405
import requests import calendar import alexis.common from alexis.common import * def build_url_with_lookback(url, lookback, lookback_unit="s", epoch_unit="ms"): if lookback_unit not in ["s", "m", "h"]: return "ERROR: lookback_unit is not: s|m|h" if epoch_unit not in ["ms", "s"]: retur...
true
true
08f12b5d511c80c2a2e7a76313ac9e1f5d029007
17,137
py
Python
python/ccxt/btcalpha.py
yogch/ccxt
5f0510a4ec490ef956a756ba4028763bc740aac5
[ "MIT" ]
3
2021-06-29T16:27:19.000Z
2021-07-18T08:36:07.000Z
python/ccxt/btcalpha.py
Bytedex/ccxt
3863b5e1d6c77d719ac102b0243964c4946e7abb
[ "MIT" ]
null
null
null
python/ccxt/btcalpha.py
Bytedex/ccxt
3863b5e1d6c77d719ac102b0243964c4946e7abb
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- # PLEASE DO NOT EDIT THIS FILE, IT IS GENERATED AND WILL BE OVERWRITTEN: # https://github.com/ccxt/ccxt/blob/master/CONTRIBUTING.md#how-to-contribute-code from ccxt.base.exchange import Exchange from ccxt.base.errors import ExchangeError from ccxt.base.errors import AuthenticationError from cc...
37.335512
131
0.48334
from ccxt.base.exchange import Exchange from ccxt.base.errors import ExchangeError from ccxt.base.errors import AuthenticationError from ccxt.base.errors import InsufficientFunds from ccxt.base.errors import InvalidOrder from ccxt.base.errors import DDoSProtection from ccxt.base.precise import Precise class btcalph...
true
true
08f12c6b1901e95e910a3a8c7f57c8589db62b58
43
py
Python
src/python/nimbusml/model_selection/__init__.py
michaelgsharp/NimbusML
50031157265f49eec85d27fe67582d9ddaf01ef9
[ "MIT" ]
134
2018-11-01T22:15:24.000Z
2019-05-04T11:30:08.000Z
src/python/nimbusml/model_selection/__init__.py
michaelgsharp/NimbusML
50031157265f49eec85d27fe67582d9ddaf01ef9
[ "MIT" ]
226
2019-05-07T19:00:44.000Z
2021-01-06T07:59:48.000Z
src/python/nimbusml/model_selection/__init__.py
michaelgsharp/NimbusML
50031157265f49eec85d27fe67582d9ddaf01ef9
[ "MIT" ]
43
2019-05-15T20:19:42.000Z
2022-03-30T10:26:07.000Z
from .cv import CV __all__ = [ 'CV' ]
7.166667
18
0.534884
from .cv import CV __all__ = [ 'CV' ]
true
true
08f12ca759426bee9dbb090aef9cd5b54edcd7a9
33,408
py
Python
google/cloud/orchestration/airflow/service/v1/airflow-service-v1-py/google/cloud/orchestration/airflow/service_v1/services/environments/async_client.py
googleapis/googleapis-gen
d84824c78563d59b0e58d5664bfaa430e9ad7e7a
[ "Apache-2.0" ]
7
2021-02-21T10:39:41.000Z
2021-12-07T07:31:28.000Z
google/cloud/orchestration/airflow/service/v1/airflow-service-v1-py/google/cloud/orchestration/airflow/service_v1/services/environments/async_client.py
googleapis/googleapis-gen
d84824c78563d59b0e58d5664bfaa430e9ad7e7a
[ "Apache-2.0" ]
6
2021-02-02T23:46:11.000Z
2021-11-15T01:46:02.000Z
google/cloud/orchestration/airflow/service/v1/airflow-service-v1-py/google/cloud/orchestration/airflow/service_v1/services/environments/async_client.py
googleapis/googleapis-gen
d84824c78563d59b0e58d5664bfaa430e9ad7e7a
[ "Apache-2.0" ]
4
2021-01-28T23:25:45.000Z
2021-08-30T01:55:16.000Z
# -*- coding: utf-8 -*- # Copyright 2020 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 # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or...
42.235145
171
0.599437
from collections import OrderedDict import functools import re from typing import Dict, Sequence, Tuple, Type, Union import pkg_resources import google.api_core.client_options as ClientOptions from google.api_core import exceptions as core_exceptions from google.api_core import gapic_v1 from google....
true
true
08f12cbad73180c2e96841ea28dd1d73edc6042f
47
py
Python
samcli/__init__.py
matteofigus/aws-sam-cli
480979f27f9913f7f843c24a04ccaf090364d592
[ "Apache-2.0" ]
null
null
null
samcli/__init__.py
matteofigus/aws-sam-cli
480979f27f9913f7f843c24a04ccaf090364d592
[ "Apache-2.0" ]
null
null
null
samcli/__init__.py
matteofigus/aws-sam-cli
480979f27f9913f7f843c24a04ccaf090364d592
[ "Apache-2.0" ]
null
null
null
""" SAM CLI version """ __version__ = '0.6.2'
7.833333
21
0.574468
__version__ = '0.6.2'
true
true
08f12d249bed1373bd4202f7b9953f49541aabe5
2,767
py
Python
synapse/tests/test_lib_coro.py
vertexproject/synapse
9712e2aee63914441c59ce6cfc060fe06a2e5920
[ "Apache-2.0" ]
216
2017-01-17T18:52:50.000Z
2022-03-31T18:44:49.000Z
synapse/tests/test_lib_coro.py
vertexproject/synapse
9712e2aee63914441c59ce6cfc060fe06a2e5920
[ "Apache-2.0" ]
2,189
2017-01-17T22:31:48.000Z
2022-03-31T20:41:45.000Z
synapse/tests/test_lib_coro.py
vertexproject/synapse
9712e2aee63914441c59ce6cfc060fe06a2e5920
[ "Apache-2.0" ]
44
2017-01-17T16:50:57.000Z
2022-03-16T18:35:52.000Z
import sys import time import asyncio import threading import synapse.exc as s_exc import synapse.glob as s_glob import synapse.lib.coro as s_coro import synapse.tests.utils as s_t_utils class FakeError(Exception): pass def spawnfunc(x, y=10): return x + y def spawnsleep(n=10): time.sleep(n) return True...
23.649573
69
0.585833
import sys import time import asyncio import threading import synapse.exc as s_exc import synapse.glob as s_glob import synapse.lib.coro as s_coro import synapse.tests.utils as s_t_utils class FakeError(Exception): pass def spawnfunc(x, y=10): return x + y def spawnsleep(n=10): time.sleep(n) return True...
true
true
08f12d3a5f59c30ade29a1c9a826a208bf6070e1
11,477
py
Python
main-synthetic-data.py
garedaba/BERMUDA
ad989cbdae03efafe81d1d0aa36673dd6ffa2e14
[ "MIT" ]
null
null
null
main-synthetic-data.py
garedaba/BERMUDA
ad989cbdae03efafe81d1d0aa36673dd6ffa2e14
[ "MIT" ]
null
null
null
main-synthetic-data.py
garedaba/BERMUDA
ad989cbdae03efafe81d1d0aa36673dd6ffa2e14
[ "MIT" ]
null
null
null
#!/usr/bin/env python # coding: utf-8 # create code to generate and run on synthetic data import torch import os import numpy as np import pandas as pd import matplotlib.pyplot as plt import yaml from sklearn.model_selection import train_test_split from sklearn.metrics import mean_squared_error, plot_confusion_matri...
46.844898
143
0.600592
import torch import os import numpy as np import pandas as pd import matplotlib.pyplot as plt import yaml from sklearn.model_selection import train_test_split from sklearn.metrics import mean_squared_error, plot_confusion_matrix from sklearn.kernel_approximation import Nystroem from sklearn.linear_model import Logis...
true
true
08f12d6d9d5e2b8260d0e22cac773f6a0ae9c443
1,043
py
Python
neolib/user/CurrentFunds.py
HenryHoward/Neolib
38894157a8a3e64b6a15b3a6298490436198fc15
[ "MIT" ]
null
null
null
neolib/user/CurrentFunds.py
HenryHoward/Neolib
38894157a8a3e64b6a15b3a6298490436198fc15
[ "MIT" ]
1
2020-06-25T14:06:59.000Z
2020-06-25T14:06:59.000Z
neolib/user/CurrentFunds.py
HenryHoward/Neolib
38894157a8a3e64b6a15b3a6298490436198fc15
[ "MIT" ]
null
null
null
""":mod:`CurrentFunds` -- Gets how much liquid neopoint the user has .. module:: CurrentFunds :synopsis: Gets how much liquid neopoint the user has .. moduleauthor:: Henry Howard <henry.a.c.howard@gmail.com> """ import logging class CurrentFunds: """Tells how much liquid neopoint the user has Attributes...
24.833333
71
0.61745
import logging class CurrentFunds: def __init__(self, usr): self.amount = None if not usr: return self.usr = usr def load(self): pg = self.usr.getPage("http://www.neopets.com/inventory.phtml") amount = int(pg.select('#npanchor')[0].text.replace('...
true
true
08f12d91102707d0f965fd2a0d34bdc6282bd30e
591
py
Python
data/challenges/boxes/Pwn/ruler/solution/solution.py
mister-hai/meeplabben
7ee8bf75bc372119fecbac01e275e2c0f6873073
[ "MIT" ]
21
2020-02-26T17:41:32.000Z
2022-02-12T13:51:05.000Z
data/challenges/boxes/Pwn/ruler/solution/solution.py
mister-hai/meeplabben
7ee8bf75bc372119fecbac01e275e2c0f6873073
[ "MIT" ]
null
null
null
data/challenges/boxes/Pwn/ruler/solution/solution.py
mister-hai/meeplabben
7ee8bf75bc372119fecbac01e275e2c0f6873073
[ "MIT" ]
5
2020-02-28T01:46:20.000Z
2021-05-06T13:57:00.000Z
import sys import os PADDING_LEN = 0x100 + 32 def unrle(val): out = [] for i in range(len(val)//2): a, b = val[i*2], val[i*2+1] if a == 0: a = 256 out.append(bytes([b]) * a) return b''.join(out) def pad(): return b'AB' * (PADDING_LEN//4) def main(): rv = pa...
18.46875
71
0.534687
import sys import os PADDING_LEN = 0x100 + 32 def unrle(val): out = [] for i in range(len(val)//2): a, b = val[i*2], val[i*2+1] if a == 0: a = 256 out.append(bytes([b]) * a) return b''.join(out) def pad(): return b'AB' * (PADDING_LEN//4) def main(): rv = pa...
true
true
08f12d9cf12755397602e2a7e23bf3837d634b2f
13,322
py
Python
runtime/python/Lib/encodings/iso8859_5.py
hwaipy/InteractionFreeNode
88642b68430f57b028fd0f276a5709f89279e30d
[ "MIT" ]
5,926
2015-01-01T07:45:08.000Z
2022-03-31T12:34:38.000Z
lib/assets/Lib/encodings/iso8859_5.py
it56660024/cafe-grader-web
e9a1305fd62e79e54f6961f97ddc5cd57bafd73c
[ "MIT" ]
1,728
2015-01-01T01:09:12.000Z
2022-03-30T23:25:22.000Z
lib/assets/Lib/encodings/iso8859_5.py
it56660024/cafe-grader-web
e9a1305fd62e79e54f6961f97ddc5cd57bafd73c
[ "MIT" ]
574
2015-01-02T01:36:10.000Z
2022-03-26T10:18:48.000Z
""" Python Character Mapping Codec iso8859_5 generated from 'MAPPINGS/ISO8859/8859-5.TXT' with gencodec.py. """#" import codecs ### Codec APIs class Codec(codecs.Codec): def encode(self,input,errors='strict'): return codecs.charmap_encode(input,errors,encoding_table) def decode(self,i...
43.253247
108
0.518691
import codecs class Codec(codecs.Codec): def encode(self,input,errors='strict'): return codecs.charmap_encode(input,errors,encoding_table) def decode(self,input,errors='strict'): return codecs.charmap_decode(input,errors,decoding_table) class IncrementalEncoder(codecs.Increment...
true
true
08f12dbafc1693aeefe9d84e467dfa256484ca30
12,865
py
Python
tcc/models.py
Adrian609/google-research
e244dbf3c619a0429368e382f5a5f89e0d220c6a
[ "Apache-2.0" ]
1
2020-03-05T09:34:44.000Z
2020-03-05T09:34:44.000Z
tcc/models.py
robot-ai-machinelearning/google-research
88481d10a87947ffb9305dc7665682e008b27391
[ "Apache-2.0" ]
5
2021-08-25T16:15:36.000Z
2022-02-10T04:34:04.000Z
tcc/models.py
robot-ai-machinelearning/google-research
88481d10a87947ffb9305dc7665682e008b27391
[ "Apache-2.0" ]
1
2020-03-16T14:21:31.000Z
2020-03-16T14:21:31.000Z
# coding=utf-8 # Copyright 2019 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...
31.609337
80
0.671512
from __future__ import absolute_import from __future__ import division from __future__ import print_function from absl import flags from keras_applications import resnet_v2 import tensorflow.compat.v2 as tf from tensorflow.compat.v1.keras import regularizers from tensorflow.compat.v1.keras.models import Model fr...
true
true
08f12e85885ecc9220c490bc46e9b72e3b3e4e74
5,697
py
Python
tests/base_conftest.py
fubuloubu/vyper
e3cfb31f9b0770d24b8a879ca1562bdc9a61e455
[ "Apache-2.0" ]
null
null
null
tests/base_conftest.py
fubuloubu/vyper
e3cfb31f9b0770d24b8a879ca1562bdc9a61e455
[ "Apache-2.0" ]
1
2022-03-19T00:45:47.000Z
2022-03-19T00:45:47.000Z
tests/base_conftest.py
fubuloubu/vyper
e3cfb31f9b0770d24b8a879ca1562bdc9a61e455
[ "Apache-2.0" ]
null
null
null
import pytest from eth_tester import EthereumTester, PyEVMBackend from eth_tester.exceptions import TransactionFailed from eth_utils.toolz import compose from web3 import Web3 from web3.contract import Contract, mk_collision_prop from web3.providers.eth_tester import EthereumTesterProvider from vyper import compiler ...
34.737805
100
0.679656
import pytest from eth_tester import EthereumTester, PyEVMBackend from eth_tester.exceptions import TransactionFailed from eth_utils.toolz import compose from web3 import Web3 from web3.contract import Contract, mk_collision_prop from web3.providers.eth_tester import EthereumTesterProvider from vyper import compiler ...
true
true