hexsha stringlengths 40 40 | size int64 5 2.06M | ext stringclasses 10
values | lang stringclasses 1
value | max_stars_repo_path stringlengths 3 248 | max_stars_repo_name stringlengths 5 125 | max_stars_repo_head_hexsha stringlengths 40 78 | 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 3 248 | max_issues_repo_name stringlengths 5 125 | max_issues_repo_head_hexsha stringlengths 40 78 | 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 3 248 | max_forks_repo_name stringlengths 5 125 | max_forks_repo_head_hexsha stringlengths 40 78 | 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 5 2.06M | avg_line_length float64 1 1.02M | max_line_length int64 3 1.03M | alphanum_fraction float64 0 1 | count_classes int64 0 1.6M | score_classes float64 0 1 | count_generators int64 0 651k | score_generators float64 0 1 | count_decorators int64 0 990k | score_decorators float64 0 1 | count_async_functions int64 0 235k | score_async_functions float64 0 1 | count_documentation int64 0 1.04M | score_documentation float64 0 1 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
86e856cc4992e6f53fef41d1cfe0de4271ac6642 | 1,667 | py | Python | playground.py | NHGmaniac/voctoconfig | 55a803a5f9bc81b48eaa72ced1fddd402aa7a2e9 | [
"MIT"
] | null | null | null | playground.py | NHGmaniac/voctoconfig | 55a803a5f9bc81b48eaa72ced1fddd402aa7a2e9 | [
"MIT"
] | null | null | null | playground.py | NHGmaniac/voctoconfig | 55a803a5f9bc81b48eaa72ced1fddd402aa7a2e9 | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
import signal
import logging
import sys
from gi.repository import GObject
GObject.threads_init()
import time
from lib.args import Args
from lib.loghandler import LogHandler
import lib.connection as Connection
def testCallback(args):
log = logging.getLogger("Test")
log.info(str(args... | 24.514706 | 67 | 0.644271 | 494 | 0.296341 | 0 | 0 | 0 | 0 | 0 | 0 | 223 | 0.133773 |
86e873cdab8920252696e3d917e54b578dd9f428 | 3,220 | py | Python | tianshou/utils/logger/tensorboard.py | Aceticia/tianshou | 6377dc5006ba1111adac42472447b9de4a021c2d | [
"MIT"
] | 4,714 | 2018-04-16T22:52:05.000Z | 2022-03-31T14:14:51.000Z | tianshou/utils/logger/tensorboard.py | Aceticia/tianshou | 6377dc5006ba1111adac42472447b9de4a021c2d | [
"MIT"
] | 529 | 2020-03-26T00:58:03.000Z | 2022-03-31T01:59:14.000Z | tianshou/utils/logger/tensorboard.py | Aceticia/tianshou | 6377dc5006ba1111adac42472447b9de4a021c2d | [
"MIT"
] | 798 | 2018-05-26T23:34:07.000Z | 2022-03-30T11:26:19.000Z | import warnings
from typing import Any, Callable, Optional, Tuple
from tensorboard.backend.event_processing import event_accumulator
from torch.utils.tensorboard import SummaryWriter
from tianshou.utils.logger.base import LOG_DATA_TYPE, BaseLogger
class TensorboardLogger(BaseLogger):
"""A logger that relies on ... | 37.011494 | 87 | 0.647205 | 2,964 | 0.920497 | 0 | 0 | 0 | 0 | 0 | 0 | 927 | 0.287888 |
86e8affd139b8a4dffaf5cdc66c6797adccdf84b | 7,326 | py | Python | PythonAPI/pythonwrappers/jetfuel/gui/menu.py | InsightGit/JetfuelGameEngine | 3ea0bf2fb5e09aadf304b7b5a16882d72336c408 | [
"Apache-2.0"
] | 4 | 2018-02-05T03:40:10.000Z | 2021-06-18T16:22:13.000Z | PythonAPI/pythonwrappers/jetfuel/gui/menu.py | InsightGit/JetfuelGameEngine | 3ea0bf2fb5e09aadf304b7b5a16882d72336c408 | [
"Apache-2.0"
] | null | null | null | PythonAPI/pythonwrappers/jetfuel/gui/menu.py | InsightGit/JetfuelGameEngine | 3ea0bf2fb5e09aadf304b7b5a16882d72336c408 | [
"Apache-2.0"
] | null | null | null | # Jetfuel Game Engine- A SDL-based 2D game-engine
# Copyright (C) 2018 InfernoStudios
#
# 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... | 46.367089 | 81 | 0.590227 | 6,444 | 0.879607 | 0 | 0 | 0 | 0 | 0 | 0 | 660 | 0.09009 |
86ea235dbd8e630be7e48c8aa27ae5d388c7bc1d | 30,649 | py | Python | latent_programmer/decomposition_transformer_attention/train.py | ParikhKadam/google-research | 00a282388e389e09ce29109eb050491c96cfab85 | [
"Apache-2.0"
] | 2 | 2022-01-21T18:15:34.000Z | 2022-01-25T15:21:34.000Z | latent_programmer/decomposition_transformer_attention/train.py | ParikhKadam/google-research | 00a282388e389e09ce29109eb050491c96cfab85 | [
"Apache-2.0"
] | 110 | 2021-10-01T18:22:38.000Z | 2021-12-27T22:08:31.000Z | latent_programmer/decomposition_transformer_attention/train.py | admariner/google-research | 7cee4b22b925581d912e8d993625c180da2a5a4f | [
"Apache-2.0"
] | 1 | 2022-02-10T10:43:10.000Z | 2022-02-10T10:43:10.000Z | # coding=utf-8
# Copyright 2021 The Google Research Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicab... | 38.263421 | 96 | 0.661131 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 8,859 | 0.289047 |
86ebf47f1f35ac5baec5295be6bb6feebf67dc9a | 5,412 | py | Python | plot/profile_interpolation/plot_profile.py | ziyixi/SeisScripts | a484bc1747eae52b2441f0bfd47ac7e093150f1d | [
"MIT"
] | null | null | null | plot/profile_interpolation/plot_profile.py | ziyixi/SeisScripts | a484bc1747eae52b2441f0bfd47ac7e093150f1d | [
"MIT"
] | null | null | null | plot/profile_interpolation/plot_profile.py | ziyixi/SeisScripts | a484bc1747eae52b2441f0bfd47ac7e093150f1d | [
"MIT"
] | null | null | null | import matplotlib.pyplot as plt
import numpy as np
import pandas as pd
import click
import numba
def prepare_data(data_pd, parameter):
lon_set = set(data_pd["lon"])
lat_set = set(data_pd["lat"])
dep_set = set(data_pd["dep"])
lon_list = sorted(lon_set)
lat_list = sorted(lat_set)
dep_list = sor... | 34.037736 | 153 | 0.636179 | 0 | 0 | 0 | 0 | 3,449 | 0.636699 | 0 | 0 | 658 | 0.121469 |
86ebfc32e5da592e6e4c3fa48a02c7a3cbe0a2ce | 367 | py | Python | tests/test_heroku.py | edpaget/flask-appconfig | 5264719ac9229339070b219a4358a3203ffd05b0 | [
"MIT"
] | 61 | 2015-01-28T21:19:11.000Z | 2020-12-28T10:12:28.000Z | tests/test_heroku.py | edpaget/flask-appconfig | 5264719ac9229339070b219a4358a3203ffd05b0 | [
"MIT"
] | 3 | 2016-01-25T00:09:55.000Z | 2017-09-25T11:36:19.000Z | tests/test_heroku.py | edpaget/flask-appconfig | 5264719ac9229339070b219a4358a3203ffd05b0 | [
"MIT"
] | 14 | 2015-07-22T12:58:06.000Z | 2021-03-24T02:06:30.000Z | from flask import Flask
from flask_appconfig import HerokuConfig
def create_sample_app():
app = Flask('testapp')
HerokuConfig(app)
return app
def test_herokupostgres(monkeypatch):
monkeypatch.setenv('HEROKU_POSTGRESQL_ORANGE_URL', 'heroku-db-uri')
app = create_sample_app()
assert app.config... | 22.9375 | 71 | 0.746594 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 94 | 0.256131 |
86ec0f9bcbbfb50a7fe60cb1505775e1803a9dd4 | 396 | py | Python | flask/util/logger.py | Dev-Jahn/cms | 84ea115bdb865daff83d069502f6f0dd105fc4f0 | [
"RSA-MD"
] | null | null | null | flask/util/logger.py | Dev-Jahn/cms | 84ea115bdb865daff83d069502f6f0dd105fc4f0 | [
"RSA-MD"
] | 9 | 2021-01-05T07:48:28.000Z | 2021-05-14T06:38:27.000Z | flask/util/logger.py | Dev-Jahn/cms | 84ea115bdb865daff83d069502f6f0dd105fc4f0 | [
"RSA-MD"
] | 4 | 2021-01-05T06:46:09.000Z | 2021-05-06T01:44:28.000Z | import logging
"""
Formatter
"""
formatter = logging.Formatter('%(asctime)s - %(name)s - %(levelname)s - %(message)s', datefmt='%Y-%m-%d:%H:%M:%S')
"""
Set Flask logger
"""
logger = logging.getLogger('FLASK_LOG')
logger.setLevel(logging.DEBUG)
stream_log = logging.StreamHandler()
stream_log.setFormatter(form... | 20.842105 | 114 | 0.699495 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 170 | 0.429293 |
86ecab271dab8a62fddc0d43582d82c9d0efb150 | 1,592 | py | Python | utils/backups/backup_psql.py | Krovatkin/NewsBlur | 2a5b52984c9d29c864eb80e9c60c658b1f25f7c5 | [
"MIT"
] | null | null | null | utils/backups/backup_psql.py | Krovatkin/NewsBlur | 2a5b52984c9d29c864eb80e9c60c658b1f25f7c5 | [
"MIT"
] | null | null | null | utils/backups/backup_psql.py | Krovatkin/NewsBlur | 2a5b52984c9d29c864eb80e9c60c658b1f25f7c5 | [
"MIT"
] | null | null | null | #!/usr/bin/python3
import os
import sys
import socket
CURRENT_DIR = os.path.dirname(__file__)
NEWSBLUR_DIR = ''.join([CURRENT_DIR, '/../../'])
sys.path.insert(0, NEWSBLUR_DIR)
os.environ['DJANGO_SETTINGS_MODULE'] = 'newsblur_web.settings'
import threading
class ProgressPercentage(object):
def __init__(self, fil... | 34.608696 | 108 | 0.682161 | 674 | 0.423367 | 0 | 0 | 0 | 0 | 0 | 0 | 306 | 0.192211 |
86ecdb5499de55821a90a7d456c0a5f3e2bbff3c | 22,780 | py | Python | onap_tests/scenario/solution.py | Orange-OpenSource/xtesting-onap-tests | ce4237f49089a91c81f5fad552f78fec384fd504 | [
"Apache-2.0"
] | null | null | null | onap_tests/scenario/solution.py | Orange-OpenSource/xtesting-onap-tests | ce4237f49089a91c81f5fad552f78fec384fd504 | [
"Apache-2.0"
] | null | null | null | onap_tests/scenario/solution.py | Orange-OpenSource/xtesting-onap-tests | ce4237f49089a91c81f5fad552f78fec384fd504 | [
"Apache-2.0"
] | 2 | 2018-06-08T15:49:51.000Z | 2021-06-22T10:06:30.000Z | #!/usr/bin/python
#
# This program and the accompanying materials
# are made available under the terms of the Apache License, Version 2.0
# which accompanies this distribution, and is available at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# pylint: disable=missing-docstring
# pylint: disable=duplicate-c... | 42.342007 | 80 | 0.554478 | 22,114 | 0.970764 | 0 | 0 | 0 | 0 | 0 | 0 | 7,333 | 0.321905 |
86ecf5f6a01c26c5389153d1137d146050eff0e3 | 3,262 | py | Python | tutorials/Controls4Docs/ControlEventsGraph.py | dominic-dev/pyformsd | 23e31ceff2943bc0f7286d25dd14450a14b986af | [
"MIT"
] | null | null | null | tutorials/Controls4Docs/ControlEventsGraph.py | dominic-dev/pyformsd | 23e31ceff2943bc0f7286d25dd14450a14b986af | [
"MIT"
] | null | null | null | tutorials/Controls4Docs/ControlEventsGraph.py | dominic-dev/pyformsd | 23e31ceff2943bc0f7286d25dd14450a14b986af | [
"MIT"
] | null | null | null | #!/usr/bin/python
# -*- coding: utf-8 -*-
__author__ = "Ricardo Ribeiro"
__credits__ = ["Ricardo Ribeiro"]
__license__ = "MIT"
__version__ = "0.0"
__maintainer__ = "Ricardo Ribeiro"
__email__ = "[email protected]"
__status__ = "Development"
from __init__ import *
import random, time
f... | 27.183333 | 116 | 0.62477 | 2,475 | 0.758737 | 0 | 0 | 0 | 0 | 0 | 0 | 837 | 0.256591 |
86ecf632226839fdabd506f9f83e9358864f79de | 4,447 | py | Python | annotation_gui_gcp/orthophoto_view.py | lioncorpo/sfm.lion-judge-corporation | 95fb11bff263c3faab62269cc907eec18b527e22 | [
"BSD-2-Clause"
] | 1 | 2019-05-31T13:50:41.000Z | 2019-05-31T13:50:41.000Z | annotation_gui_gcp/orthophoto_view.py | Pandinosaurus/OpenSfM | b892ba9fd5e7fd6c7a9e3c81edddca80f71c1cd5 | [
"BSD-2-Clause"
] | null | null | null | annotation_gui_gcp/orthophoto_view.py | Pandinosaurus/OpenSfM | b892ba9fd5e7fd6c7a9e3c81edddca80f71c1cd5 | [
"BSD-2-Clause"
] | 2 | 2017-03-31T16:54:34.000Z | 2018-07-10T11:32:22.000Z | from typing import Tuple
import numpy as np
import rasterio.warp
from opensfm import features
from .orthophoto_manager import OrthoPhotoManager
from .view import View
class OrthoPhotoView(View):
def __init__(
self,
main_ui,
path: str,
init_lat: float,
init_lon: float,
... | 35.293651 | 83 | 0.613672 | 4,275 | 0.961322 | 0 | 0 | 0 | 0 | 0 | 0 | 960 | 0.215876 |
86eee025668f1ba4e581d9197ce7264211e57bc7 | 3,704 | py | Python | tempest/tests/lib/services/compute/test_security_group_default_rules_client.py | mail2nsrajesh/tempest | 1a3b3dc50b418d3a15839830d7d1ff88c8c76cff | [
"Apache-2.0"
] | 254 | 2015-01-05T19:22:52.000Z | 2022-03-29T08:14:54.000Z | tempest/tests/lib/services/compute/test_security_group_default_rules_client.py | mail2nsrajesh/tempest | 1a3b3dc50b418d3a15839830d7d1ff88c8c76cff | [
"Apache-2.0"
] | 13 | 2015-03-02T15:53:04.000Z | 2022-02-16T02:28:14.000Z | tempest/tests/lib/services/compute/test_security_group_default_rules_client.py | mail2nsrajesh/tempest | 1a3b3dc50b418d3a15839830d7d1ff88c8c76cff | [
"Apache-2.0"
] | 367 | 2015-01-07T15:05:39.000Z | 2022-03-04T09:50:35.000Z | # Copyright 2015 NEC Corporation. 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 ... | 41.617978 | 78 | 0.704644 | 2,900 | 0.782937 | 0 | 0 | 0 | 0 | 0 | 0 | 1,049 | 0.283207 |
86ef419ce9a394c69c1d9d5b8bea2b3d98c02484 | 29,478 | py | Python | pirates/leveleditor/worldData/interior_spanish_npc_b.py | itsyaboyrocket/pirates | 6ca1e7d571c670b0d976f65e608235707b5737e3 | [
"BSD-3-Clause"
] | 3 | 2021-02-25T06:38:13.000Z | 2022-03-22T07:00:15.000Z | pirates/leveleditor/worldData/interior_spanish_npc_b.py | itsyaboyrocket/pirates | 6ca1e7d571c670b0d976f65e608235707b5737e3 | [
"BSD-3-Clause"
] | null | null | null | pirates/leveleditor/worldData/interior_spanish_npc_b.py | itsyaboyrocket/pirates | 6ca1e7d571c670b0d976f65e608235707b5737e3 | [
"BSD-3-Clause"
] | 1 | 2021-02-25T06:38:17.000Z | 2021-02-25T06:38:17.000Z | # uncompyle6 version 3.2.0
# Python bytecode 2.4 (62061)
# Decompiled from: Python 2.7.14 (v2.7.14:84471935ed, Sep 16 2017, 20:19:30) [MSC v.1500 32 bit (Intel)]
# Embedded file name: pirates.leveleditor.worldData.interior_spanish_npc_b
from pandac.PandaModules import Point3, VBase3, Vec4, Vec3
objectStruct = {'Objects... | 4,211.142857 | 29,056 | 0.664631 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 19,165 | 0.650146 |
86ef4e909fe2cea39d77e8fe80f71f1e8cdcd676 | 1,844 | py | Python | main.py | Light-Lens/PassGen | 8f4f2ef08299d6243b939d0f08ac75bde3cabf5e | [
"MIT"
] | 3 | 2021-07-19T16:39:06.000Z | 2021-11-08T11:53:50.000Z | main.py | Light-Lens/PassGen | 8f4f2ef08299d6243b939d0f08ac75bde3cabf5e | [
"MIT"
] | null | null | null | main.py | Light-Lens/PassGen | 8f4f2ef08299d6243b939d0f08ac75bde3cabf5e | [
"MIT"
] | null | null | null | # PassGen
# These imports will be used for this project.
from colorama import Fore, Style
from colorama import init
import datetime
import string
import random
import sys
import os
# Initilaze File organizer.
os.system('title PassGen')
init(autoreset = True)
# Create Log Functions.
class LOG:
def INF... | 32.350877 | 80 | 0.691432 | 644 | 0.349241 | 0 | 0 | 0 | 0 | 0 | 0 | 750 | 0.406725 |
86ef847c1cba2674adc29aa5bed41c18d23f595a | 24,723 | py | Python | memos/memos/models/Memo.py | iotexpert/docmgr | 735c7bcbaeb73bc44efecffb175f268f2438ac3a | [
"MIT"
] | null | null | null | memos/memos/models/Memo.py | iotexpert/docmgr | 735c7bcbaeb73bc44efecffb175f268f2438ac3a | [
"MIT"
] | null | null | null | memos/memos/models/Memo.py | iotexpert/docmgr | 735c7bcbaeb73bc44efecffb175f268f2438ac3a | [
"MIT"
] | null | null | null | """
The model file for a Memo
"""
import re
import os
import shutil
import json
from datetime import datetime
from flask import current_app
from memos import db
from memos.models.User import User
from memos.models.MemoState import MemoState
from memos.models.MemoFile import MemoFile
from memos.models.MemoSignature i... | 39.367834 | 190 | 0.582049 | 24,178 | 0.977956 | 0 | 0 | 9,820 | 0.397201 | 0 | 0 | 5,896 | 0.238482 |
86f060997b8a24b2a713e28d30aebb3fc5274d62 | 1,385 | py | Python | course_catalog/etl/conftest.py | mitodl/open-discussions | ab6e9fac70b8a1222a84e78ba778a7a065c20541 | [
"BSD-3-Clause"
] | 12 | 2017-09-27T21:23:27.000Z | 2020-12-25T04:31:30.000Z | course_catalog/etl/conftest.py | mitodl/open-discussions | ab6e9fac70b8a1222a84e78ba778a7a065c20541 | [
"BSD-3-Clause"
] | 3,293 | 2017-06-30T18:16:01.000Z | 2022-03-31T18:01:34.000Z | course_catalog/etl/conftest.py | mitodl/open-discussions | ab6e9fac70b8a1222a84e78ba778a7a065c20541 | [
"BSD-3-Clause"
] | 1 | 2020-04-13T12:19:57.000Z | 2020-04-13T12:19:57.000Z | """Common ETL test fixtures"""
import json
import pytest
@pytest.fixture(autouse=True)
def mitx_settings(settings):
"""Test settings for MITx import"""
settings.EDX_API_CLIENT_ID = "fake-client-id"
settings.EDX_API_CLIENT_SECRET = "fake-client-secret"
settings.EDX_API_ACCESS_TOKEN_URL = "http://local... | 32.209302 | 80 | 0.716245 | 0 | 0 | 310 | 0.223827 | 1,315 | 0.949458 | 0 | 0 | 572 | 0.412996 |
86f07721893f6c50f28bc8f37736be7b92dba3a5 | 8,850 | py | Python | juliaset/juliaset.py | PageotD/juliaset | 7c1f98020eeff291fcf040cfcdf25a89e72f46a9 | [
"BSD-3-Clause"
] | null | null | null | juliaset/juliaset.py | PageotD/juliaset | 7c1f98020eeff291fcf040cfcdf25a89e72f46a9 | [
"BSD-3-Clause"
] | null | null | null | juliaset/juliaset.py | PageotD/juliaset | 7c1f98020eeff291fcf040cfcdf25a89e72f46a9 | [
"BSD-3-Clause"
] | 1 | 2021-08-09T06:45:43.000Z | 2021-08-09T06:45:43.000Z | import numpy as np
import matplotlib.pyplot as plt
import matplotlib.cm as cm
import random
class JuliaSet:
def __init__(self):
"""
Constructor of the JuliaSet class
:param size: size in pixels (for both width and height)
:param dpi: dots per inch (default 300)
"""
... | 32.417582 | 89 | 0.566328 | 8,361 | 0.944746 | 0 | 0 | 0 | 0 | 0 | 0 | 4,388 | 0.495819 |
86f0877f437e0d2341e2d9c4fb9323bda9c076fe | 1,212 | py | Python | eye_detection.py | ShivanS93/VAtest_withOKN | 8da76f4c3ff526c9e16268194accfdc6221b0a66 | [
"MIT"
] | null | null | null | eye_detection.py | ShivanS93/VAtest_withOKN | 8da76f4c3ff526c9e16268194accfdc6221b0a66 | [
"MIT"
] | null | null | null | eye_detection.py | ShivanS93/VAtest_withOKN | 8da76f4c3ff526c9e16268194accfdc6221b0a66 | [
"MIT"
] | null | null | null | #!python3
# eye_detection.py - detect eyes using webcam
# tutorial: https://www.roytuts.com/real-time-eye-detection-in-webcam-using-python-3/
import cv2
import math
import numpy as np
def main():
faceCascade = cv2.CascadeClassifier("haarcascade_frontalface_alt.xml")
eyeCascade = cv2.CascadeClassifier("haarc... | 24.734694 | 86 | 0.575908 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 253 | 0.208746 |
86f0c522be62919400b4d5f2f8a78d4b4a38dcb9 | 399 | py | Python | scripts/make_gene_table.py | lmdu/bioinfo | 4542b0718410d15f3956c6545d9824a16608e02b | [
"MIT"
] | null | null | null | scripts/make_gene_table.py | lmdu/bioinfo | 4542b0718410d15f3956c6545d9824a16608e02b | [
"MIT"
] | null | null | null | scripts/make_gene_table.py | lmdu/bioinfo | 4542b0718410d15f3956c6545d9824a16608e02b | [
"MIT"
] | null | null | null | #!/usr/bin/env python
descripts = {}
with open('macaca_genes.txt') as fh:
fh.readline()
for line in fh:
cols = line.strip('\n').split('\t')
if cols[1]:
descripts[cols[0]] = cols[1].split('[')[0].strip()
else:
descripts[cols[0]] = cols[1]
with open('gene_info.txt') as fh:
for line in fh:
cols = line.... | 19.95 | 53 | 0.611529 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 73 | 0.182957 |
86f16e97aa13775a35aa0ced03caeac309db0c51 | 4,627 | py | Python | {{cookiecutter.repo_name}}/src/mix_with_scaper.py | nussl/cookiecutter | 5df8512592778ea7155b05e3e4b54676227968b0 | [
"MIT"
] | null | null | null | {{cookiecutter.repo_name}}/src/mix_with_scaper.py | nussl/cookiecutter | 5df8512592778ea7155b05e3e4b54676227968b0 | [
"MIT"
] | null | null | null | {{cookiecutter.repo_name}}/src/mix_with_scaper.py | nussl/cookiecutter | 5df8512592778ea7155b05e3e4b54676227968b0 | [
"MIT"
] | null | null | null | import gin
from scaper import Scaper, generate_from_jams
import copy
import logging
import p_tqdm
import nussl
import os
import numpy as np
def _reset_event_spec(sc):
sc.reset_fg_event_spec()
sc.reset_bg_event_spec()
def check_mixture(path_to_mix):
mix_signal = nussl.AudioSignal(path_to_mix)
if mix_si... | 31.691781 | 87 | 0.612708 | 0 | 0 | 0 | 0 | 1,954 | 0.422304 | 0 | 0 | 462 | 0.099849 |
86f1999802fa178d60effb8dd046d22fbb0dd814 | 4,643 | py | Python | adventure-cards/package/main.py | DaneRosa/adventure-cards | 0685feeec8b56627795e685ff4fffad187881e1c | [
"MIT"
] | null | null | null | adventure-cards/package/main.py | DaneRosa/adventure-cards | 0685feeec8b56627795e685ff4fffad187881e1c | [
"MIT"
] | null | null | null | adventure-cards/package/main.py | DaneRosa/adventure-cards | 0685feeec8b56627795e685ff4fffad187881e1c | [
"MIT"
] | null | null | null | import json
def hydrateCards(rawDeckDataPath):
pack = []
rawDeckData = json.load(open(rawDeckDataPath,))
for index, item in enumerate(rawDeckData):
deck = []
# print(index,item)
for i in rawDeckData[item]:
card ={
f'{index}':
{
... | 48.873684 | 92 | 0.420633 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1,246 | 0.268361 |
86f19d8269d91051babd1a81669ee8409fe871bc | 1,328 | py | Python | demo/cnn_predict.py | huynhtnhut97/keras-video-classifier | 3ea6a8d671f3bd3cc8eddef64ad75abc2a2d593a | [
"MIT"
] | 108 | 2018-03-01T10:03:22.000Z | 2022-03-27T03:00:30.000Z | demo/cnn_predict.py | drsagitn/lstm-video-classifier | 3d1bce6773e493bdff5d623883d47ca68d45e890 | [
"MIT"
] | 18 | 2020-01-28T22:13:07.000Z | 2022-03-11T23:54:10.000Z | demo/cnn_predict.py | drsagitn/lstm-video-classifier | 3d1bce6773e493bdff5d623883d47ca68d45e890 | [
"MIT"
] | 56 | 2018-03-01T10:03:22.000Z | 2022-02-23T08:19:10.000Z | import numpy as np
from keras import backend as K
import os
import sys
K.set_image_dim_ordering('tf')
def patch_path(path):
return os.path.join(os.path.dirname(__file__), path)
def main():
sys.path.append(patch_path('..'))
data_dir_path = patch_path('very_large_data')
model_dir_path = patch_path('... | 30.883721 | 110 | 0.758283 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 75 | 0.056476 |
86f2a90daa96d1b00a32e75d50fd040ca01ed705 | 172 | py | Python | pyconde/context_processors.py | EuroPython/djep | afcccbdda483e5f6962ac97f0dc4c4c5ea67fd21 | [
"BSD-3-Clause"
] | 5 | 2015-01-02T14:33:14.000Z | 2021-08-03T10:19:07.000Z | pyconde/context_processors.py | EuroPython/djep | afcccbdda483e5f6962ac97f0dc4c4c5ea67fd21 | [
"BSD-3-Clause"
] | null | null | null | pyconde/context_processors.py | EuroPython/djep | afcccbdda483e5f6962ac97f0dc4c4c5ea67fd21 | [
"BSD-3-Clause"
] | 3 | 2015-08-30T09:45:03.000Z | 2017-04-08T12:15:22.000Z | from django.conf import settings
def less_settings(request):
return {
'use_dynamic_less_in_debug': getattr(settings, 'LESS_USE_DYNAMIC_IN_DEBUG', True)
}
| 21.5 | 89 | 0.732558 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 54 | 0.313953 |
86f3b70aa2f3c882bdd1f178d6aa80fab1793aab | 5,898 | py | Python | pmdarima/preprocessing/endog/boxcox.py | tuomijal/pmdarima | 5bf84a2a5c42b81b949bd252ad3d4c6c311343f8 | [
"MIT"
] | 736 | 2019-12-02T01:33:31.000Z | 2022-03-31T21:45:29.000Z | pmdarima/preprocessing/endog/boxcox.py | tuomijal/pmdarima | 5bf84a2a5c42b81b949bd252ad3d4c6c311343f8 | [
"MIT"
] | 186 | 2019-12-01T18:01:33.000Z | 2022-03-31T18:27:56.000Z | pmdarima/preprocessing/endog/boxcox.py | tuomijal/pmdarima | 5bf84a2a5c42b81b949bd252ad3d4c6c311343f8 | [
"MIT"
] | 126 | 2019-12-07T04:03:19.000Z | 2022-03-31T17:40:14.000Z | # -*- coding: utf-8 -*-
from scipy import stats
import numpy as np
import warnings
from ...compat import check_is_fitted, pmdarima as pm_compat
from .base import BaseEndogTransformer
__all__ = ['BoxCoxEndogTransformer']
class BoxCoxEndogTransformer(BaseEndogTransformer):
r"""Apply the Box-Cox transformation t... | 33.511364 | 78 | 0.598847 | 5,671 | 0.961512 | 0 | 0 | 0 | 0 | 0 | 0 | 3,967 | 0.672601 |
86f3e8f2399f57967d9da67546eaf7a9b7b31fb7 | 2,139 | py | Python | backend/src/baserow/api/user/registries.py | ashishdhngr/baserow | b098678d2165eb7c42930ee24dc6753a3cb520c3 | [
"MIT"
] | 1 | 2022-01-24T15:12:02.000Z | 2022-01-24T15:12:02.000Z | backend/src/baserow/api/user/registries.py | rasata/baserow | c6e1d7842c53f801e1c96b49f1377da2a06afaa9 | [
"MIT"
] | null | null | null | backend/src/baserow/api/user/registries.py | rasata/baserow | c6e1d7842c53f801e1c96b49f1377da2a06afaa9 | [
"MIT"
] | null | null | null | from baserow.core.registry import Instance, Registry
class UserDataType(Instance):
"""
The user data type can be used to inject an additional payload to the API
JWT response. This is the response when a user authenticates or refreshes his
token. The returned dict of the `get_user_data` method is added... | 28.905405 | 85 | 0.633006 | 2,038 | 0.952782 | 0 | 0 | 0 | 0 | 0 | 0 | 1,640 | 0.766713 |
86f4958fe557f64425c53fe4dff977306ba95b20 | 17,197 | py | Python | Week 2/code.py | aklsh/EE2703 | 546b70c9adac4a4de294d83affbb74e480c2f65d | [
"MIT"
] | null | null | null | Week 2/code.py | aklsh/EE2703 | 546b70c9adac4a4de294d83affbb74e480c2f65d | [
"MIT"
] | null | null | null | Week 2/code.py | aklsh/EE2703 | 546b70c9adac4a4de294d83affbb74e480c2f65d | [
"MIT"
] | 3 | 2020-07-15T08:02:05.000Z | 2021-03-07T06:50:07.000Z | '''
-------------------------------------
Assignment 2 - EE2703 (Jan-May 2020)
Done by Akilesh Kannan (EE18B122)
Created on 18/01/20
Last Modified on 04/02/20
-------------------------------------
'''
# importing necessary libraries
import sys
import cmath
import numpy as np
import pandas as pd
# To improve reada... | 53.241486 | 209 | 0.51823 | 1,777 | 0.103332 | 0 | 0 | 0 | 0 | 0 | 0 | 2,186 | 0.127115 |
86f530cec67d3e933cfc6fd5269d65218a8b2c49 | 880 | py | Python | Lib/Co.py | M507/Guessing-passwords-using-machine-learning | da90cfa30ce2e7a5e08ee528f594fa047ecea75c | [
"Apache-2.0"
] | 6 | 2020-05-18T14:20:23.000Z | 2021-04-23T16:31:34.000Z | Lib/Co.py | M507/Guessing-passwords-using-machine-learning | da90cfa30ce2e7a5e08ee528f594fa047ecea75c | [
"Apache-2.0"
] | null | null | null | Lib/Co.py | M507/Guessing-passwords-using-machine-learning | da90cfa30ce2e7a5e08ee528f594fa047ecea75c | [
"Apache-2.0"
] | 1 | 2020-05-18T21:19:52.000Z | 2020-05-18T21:19:52.000Z | import subprocess
import os.path
"""
Stylish input()
"""
def s_input(string):
return input(string+">").strip("\n")
"""
Execute command locally
"""
def execute_command(command):
if len(command) > 0:
print(command)
proc = subprocess.Popen(command.split(" "), stdout=subprocess.PIPE, cwd="/tmp")... | 20.952381 | 87 | 0.619318 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 237 | 0.269318 |
86f661785147d1c962908ad8a5f0840e9e70661d | 446 | py | Python | project3_code/part_0/main.py | rachelbrown347/CS294-26_code | 72a20a9ab75345091d2a743b13857d7a88adf9be | [
"MIT"
] | 1 | 2022-03-12T00:55:52.000Z | 2022-03-12T00:55:52.000Z | project3_code/part_0/main.py | rachelbrown347/CS294-26_code | 72a20a9ab75345091d2a743b13857d7a88adf9be | [
"MIT"
] | null | null | null | project3_code/part_0/main.py | rachelbrown347/CS294-26_code | 72a20a9ab75345091d2a743b13857d7a88adf9be | [
"MIT"
] | null | null | null | import numpy as np
import matplotlib.pyplot as plt
from skimage.exposure import rescale_intensity
from unsharp import *
# Load file and normalize to 0-1
fname = 'iguana.jpg'
im = plt.imread(fname)
if im.mean() >= 1:
im = im/255.
sigma = 5
amplitude = 1.5
imsharp = unsharp_mask(im, sigma, amplitude)
imsharp = re... | 23.473684 | 70 | 0.726457 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 56 | 0.125561 |
86f77106c10502d0d37cea800a21ab20ce83f638 | 1,218 | py | Python | meregistro/apps/registro/models/EstablecimientoDomicilio.py | MERegistro/meregistro | 6cde3cab2bd1a8e3084fa38147de377d229391e3 | [
"BSD-3-Clause"
] | null | null | null | meregistro/apps/registro/models/EstablecimientoDomicilio.py | MERegistro/meregistro | 6cde3cab2bd1a8e3084fa38147de377d229391e3 | [
"BSD-3-Clause"
] | null | null | null | meregistro/apps/registro/models/EstablecimientoDomicilio.py | MERegistro/meregistro | 6cde3cab2bd1a8e3084fa38147de377d229391e3 | [
"BSD-3-Clause"
] | null | null | null | # -*- coding: utf-8 -*-
from django.db import models
from apps.registro.models.TipoDomicilio import TipoDomicilio
from apps.registro.models.Localidad import Localidad
from apps.registro.models.Establecimiento import Establecimiento
from django.core.exceptions import ValidationError
from apps.seguridad.audit import audi... | 32.918919 | 85 | 0.76601 | 886 | 0.727422 | 0 | 0 | 893 | 0.733169 | 0 | 0 | 161 | 0.132184 |
86f7b299e6e411fb0020928642f34720d9448cf2 | 301 | py | Python | python_for_everybody/py2_p4i_old/6.5findslicestringextract.py | timothyyu/p4e-prac | f978b71ce147b6e9058372929f2666c2e67d0741 | [
"BSD-3-Clause"
] | null | null | null | python_for_everybody/py2_p4i_old/6.5findslicestringextract.py | timothyyu/p4e-prac | f978b71ce147b6e9058372929f2666c2e67d0741 | [
"BSD-3-Clause"
] | null | null | null | python_for_everybody/py2_p4i_old/6.5findslicestringextract.py | timothyyu/p4e-prac | f978b71ce147b6e9058372929f2666c2e67d0741 | [
"BSD-3-Clause"
] | 1 | 2020-04-18T16:09:04.000Z | 2020-04-18T16:09:04.000Z | # 6.5 Write code using find() and string slicing (see section 6.10) to extract
# the number at the end of the line below.
# Convert the extracted value to a floating point number and print it out.
text = "X-DSPAM-Confidence: 0.8475";
pos = text.find(':')
text = float(text[pos+1:])
print text | 27.363636 | 79 | 0.697674 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 230 | 0.76412 |
86f7e1041ab1f4accc4c1f71bcc457ad4e75b7b3 | 6,672 | py | Python | tools/lucid/engine.py | Petr-By/qtpyvis | 0b9a151ee6b9a56b486c2bece9c1f03414629efc | [
"MIT"
] | 3 | 2017-10-04T14:51:26.000Z | 2017-10-22T09:35:50.000Z | tools/lucid/engine.py | CogSciUOS/DeepLearningToolbox | bf07578b9486d8c48e25df357bc4b9963b513b46 | [
"MIT"
] | 13 | 2017-09-05T12:56:11.000Z | 2017-11-22T10:38:27.000Z | tools/lucid/engine.py | CogSciUOS/DeepLearningToolbox | bf07578b9486d8c48e25df357bc4b9963b513b46 | [
"MIT"
] | 2 | 2017-09-24T21:39:42.000Z | 2017-10-04T15:29:54.000Z | import logging
logger = logging.getLogger(__name__)
print(f"!!!!!!!!!! getEffectiveLevel: {logger.getEffectiveLevel()} !!!!!!!!!!!!!")
from dltb.base.observer import Observable, change
from network import Network, loader
from network.lucid import Network as LucidNetwork
# lucid.modelzoo.vision_models:
# A module ... | 30.190045 | 82 | 0.590528 | 5,794 | 0.868405 | 0 | 0 | 4,018 | 0.602218 | 0 | 0 | 2,249 | 0.33708 |
86f8485704c303133a8ffd7f513a5c4076214c94 | 87,649 | py | Python | synapse/storage/events.py | natamelo/synapse | 3d870ecfc5353e455917166cb5c2bb8ba48a6ebd | [
"Apache-2.0"
] | null | null | null | synapse/storage/events.py | natamelo/synapse | 3d870ecfc5353e455917166cb5c2bb8ba48a6ebd | [
"Apache-2.0"
] | null | null | null | synapse/storage/events.py | natamelo/synapse | 3d870ecfc5353e455917166cb5c2bb8ba48a6ebd | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
# Copyright 2014-2016 OpenMarket Ltd
# Copyright 2018-2019 New Vector Ltd
# Copyright 2019 The Matrix.org Foundation C.I.C.
#
# 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 Licens... | 39.339767 | 89 | 0.578455 | 82,629 | 0.942726 | 31,179 | 0.355726 | 40,548 | 0.462618 | 0 | 0 | 34,832 | 0.397403 |
86f92c20143e35ec634b684ad280aeb864a0957c | 3,074 | py | Python | dev/buildtool/metrics.py | premm1983/Spinnaker | 535f78b8f5402eea942c260cb9ca26682772a3e6 | [
"Apache-2.0"
] | null | null | null | dev/buildtool/metrics.py | premm1983/Spinnaker | 535f78b8f5402eea942c260cb9ca26682772a3e6 | [
"Apache-2.0"
] | null | null | null | dev/buildtool/metrics.py | premm1983/Spinnaker | 535f78b8f5402eea942c260cb9ca26682772a3e6 | [
"Apache-2.0"
] | null | null | null | # Copyright 2017 Google Inc. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or a... | 39.410256 | 77 | 0.754717 | 2,257 | 0.734223 | 0 | 0 | 2,112 | 0.687053 | 0 | 0 | 1,295 | 0.421275 |
86f9d5c800a3592d64ffbc26d845ced72a00288c | 4,005 | py | Python | src/python/pants/backend/android/tasks/aapt_builder.py | hythloday/pants | 107e9b0957f6949ac4bd535fbef8d2d8cba05c5c | [
"Apache-2.0"
] | 11 | 2015-01-20T01:39:41.000Z | 2019-08-08T07:27:44.000Z | src/python/pants/backend/android/tasks/aapt_builder.py | hythloday/pants | 107e9b0957f6949ac4bd535fbef8d2d8cba05c5c | [
"Apache-2.0"
] | 1 | 2016-03-15T20:35:18.000Z | 2016-03-15T20:35:18.000Z | src/python/pants/backend/android/tasks/aapt_builder.py | fakeNetflix/square-repo-pants | 28a018c7f47900aec4f576c81a52e0e4b41d9fec | [
"Apache-2.0"
] | 5 | 2015-03-30T02:46:53.000Z | 2018-03-08T20:10:43.000Z | # coding=utf-8
# Copyright 2014 Pants project contributors (see CONTRIBUTORS.md).
# Licensed under the Apache License, Version 2.0 (see LICENSE).
from __future__ import (nested_scopes, generators, division, absolute_import, with_statement,
print_function, unicode_literals)
import os
import sub... | 41.71875 | 106 | 0.698127 | 3,251 | 0.811735 | 0 | 0 | 137 | 0.034207 | 0 | 0 | 1,414 | 0.353059 |
86fafa9c771d30389c672ab69f2d0d2991d82592 | 4,967 | py | Python | fat/fat_bert_nq/ppr/apr_lib.py | kiss2u/google-research | 2cd66234656f9e2f4218ed90a2d8aa9cf3139093 | [
"Apache-2.0"
] | 1 | 2020-05-27T15:40:17.000Z | 2020-05-27T15:40:17.000Z | fat/fat_bert_nq/ppr/apr_lib.py | kiss2u/google-research | 2cd66234656f9e2f4218ed90a2d8aa9cf3139093 | [
"Apache-2.0"
] | 7 | 2021-08-25T16:15:53.000Z | 2022-02-10T03:26:55.000Z | fat/fat_bert_nq/ppr/apr_lib.py | kiss2u/google-research | 2cd66234656f9e2f4218ed90a2d8aa9cf3139093 | [
"Apache-2.0"
] | null | null | null | # coding=utf-8
# Copyright 2020 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... | 35.478571 | 80 | 0.684518 | 3,520 | 0.708677 | 0 | 0 | 0 | 0 | 0 | 0 | 2,034 | 0.409503 |
86fc7c6a00ab6863dd9ce69648b4b5568994e8af | 6,941 | py | Python | src/optimal_gardening.py | evanlynch/optimal-gardening | 447ca8575efac1ad5cdd975091f3cbb67721e167 | [
"MIT"
] | null | null | null | src/optimal_gardening.py | evanlynch/optimal-gardening | 447ca8575efac1ad5cdd975091f3cbb67721e167 | [
"MIT"
] | null | null | null | src/optimal_gardening.py | evanlynch/optimal-gardening | 447ca8575efac1ad5cdd975091f3cbb67721e167 | [
"MIT"
] | null | null | null | import os
import sys
import time
from IPython.display import Image
import matplotlib.pyplot as plt
import numpy as np
import pandas as pd
import seaborn as sb
sb.set_style("dark")
#### Initial Setup ####
#plant info
plant_info = pd.read_csv('../data/plant_data.csv')
plant_info.index.name = 'plant_index'
plants = pla... | 39.662857 | 168 | 0.711713 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2,552 | 0.36767 |
86fca5740e3caf795c7b7090059ab5992cec0e59 | 9,453 | py | Python | adv_lib/utils/attack_utils.py | Daulbaev/adversarial-library | 6f979a511ad78908374cd55855a9e2c5a874be7d | [
"BSD-3-Clause"
] | 55 | 2020-11-25T10:47:48.000Z | 2022-03-21T12:11:31.000Z | adv_lib/utils/attack_utils.py | Daulbaev/adversarial-library | 6f979a511ad78908374cd55855a9e2c5a874be7d | [
"BSD-3-Clause"
] | 4 | 2021-03-10T19:25:31.000Z | 2021-08-06T00:10:49.000Z | adv_lib/utils/attack_utils.py | Daulbaev/adversarial-library | 6f979a511ad78908374cd55855a9e2c5a874be7d | [
"BSD-3-Clause"
] | 8 | 2020-11-26T08:42:04.000Z | 2022-01-13T02:55:47.000Z | import warnings
from collections import OrderedDict
from distutils.version import LooseVersion
from functools import partial
from inspect import isclass
from typing import Callable, Optional, Dict, Union
import numpy as np
import torch
import tqdm
from torch import Tensor, nn
from torch.nn import functional as F
from... | 41.643172 | 117 | 0.66307 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1,972 | 0.208611 |
86fd1a571a9b46918806e9e8e71337c7e3431481 | 2,559 | py | Python | thawSlumpChangeDet/polygons_compare.py | Summer0328/ChangeDet_DL-1 | f2474ee4200d9ad093c0e5a27a94bfbd3bd038e7 | [
"MIT"
] | 3 | 2021-07-03T14:33:37.000Z | 2021-08-03T20:35:32.000Z | thawSlumpChangeDet/polygons_compare.py | Summer0328/ChangeDet_DL-1 | f2474ee4200d9ad093c0e5a27a94bfbd3bd038e7 | [
"MIT"
] | null | null | null | thawSlumpChangeDet/polygons_compare.py | Summer0328/ChangeDet_DL-1 | f2474ee4200d9ad093c0e5a27a94bfbd3bd038e7 | [
"MIT"
] | 2 | 2021-07-29T01:45:33.000Z | 2021-08-10T09:13:58.000Z | #!/usr/bin/env python
# Filename: polygons_cd
"""
introduction: compare two polygons in to shape file
authors: Huang Lingcao
email:[email protected]
add time: 26 February, 2020
"""
import sys,os
from optparse import OptionParser
# added path of DeeplabforRS
sys.path.insert(0, os.path.expanduser('~/codes/Pychar... | 30.105882 | 108 | 0.709261 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 944 | 0.368894 |
86fdb0073cd3ede47fd363784958394b48bca5e1 | 919 | py | Python | andela_labs/Car Class Lab (OOP)/car.py | brotich/andela_bootcamp_X | 19fc5bb66d3c930d4e6b9afeb45abc00bbc4c2ea | [
"MIT"
] | null | null | null | andela_labs/Car Class Lab (OOP)/car.py | brotich/andela_bootcamp_X | 19fc5bb66d3c930d4e6b9afeb45abc00bbc4c2ea | [
"MIT"
] | null | null | null | andela_labs/Car Class Lab (OOP)/car.py | brotich/andela_bootcamp_X | 19fc5bb66d3c930d4e6b9afeb45abc00bbc4c2ea | [
"MIT"
] | null | null | null | class Car(object):
"""
Car class that can be used to instantiate various vehicles.
It takes in arguments that depict the type, model, and name
of the vehicle
"""
def __init__(self, name="General", model="GM", car_type="saloon"):
num_of_wheels = 4
num_of_doors = 4
... | 24.837838 | 70 | 0.553863 | 918 | 0.998912 | 0 | 0 | 0 | 0 | 0 | 0 | 245 | 0.266594 |
86ff60feba2c3198cb1453cbf355794a3010628a | 195 | py | Python | CV Model/Model - JupyterNotebook/mrcnn/tfliteconverter.py | fcsiba/Smart-Cart | 7d45b9f2a2be2015936c2a61068b2fd8b6c95fe5 | [
"MIT"
] | null | null | null | CV Model/Model - JupyterNotebook/mrcnn/tfliteconverter.py | fcsiba/Smart-Cart | 7d45b9f2a2be2015936c2a61068b2fd8b6c95fe5 | [
"MIT"
] | null | null | null | CV Model/Model - JupyterNotebook/mrcnn/tfliteconverter.py | fcsiba/Smart-Cart | 7d45b9f2a2be2015936c2a61068b2fd8b6c95fe5 | [
"MIT"
] | null | null | null | import tensorflow as tf
# Convert the model.
converter = tf.lite.TFLiteConverter.from_saved_model('model.py')
tflite_model = converter.convert()
open("trash_ai.tflite", "wb").write(tflite_model) | 32.5 | 64 | 0.784615 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 51 | 0.261538 |
86ffc174e23653c3f067117004b1a24f8234310f | 711 | py | Python | basicapp/cron.py | shivamsinghal212/Url-Shortener | 4127a993272744f6f8592415314c8e8514d43153 | [
"MIT"
] | null | null | null | basicapp/cron.py | shivamsinghal212/Url-Shortener | 4127a993272744f6f8592415314c8e8514d43153 | [
"MIT"
] | 8 | 2020-06-05T18:23:15.000Z | 2022-03-11T23:23:57.000Z | basicapp/cron.py | shivamsinghal212/Url-Shortener | 4127a993272744f6f8592415314c8e8514d43153 | [
"MIT"
] | null | null | null | from django_cron import CronJobBase, Schedule
from .models import Link
from django.utils import timezone
class MyCronJob(CronJobBase):
RUN_EVERY_MINS = 1 # every 2 hours
schedule = Schedule(run_every_mins=RUN_EVERY_MINS)
code = 'basicapp.cron' # a unique code
def do(self):
current_time = t... | 30.913043 | 65 | 0.610408 | 603 | 0.848101 | 0 | 0 | 0 | 0 | 0 | 0 | 150 | 0.21097 |
810028e77fa49197f58461ee88815f3bf00eba42 | 2,029 | py | Python | weasyprint/tests/test_stacking.py | Smylers/WeasyPrint | 25ce91a34755386b3350d898aa1638c349723b57 | [
"BSD-3-Clause"
] | null | null | null | weasyprint/tests/test_stacking.py | Smylers/WeasyPrint | 25ce91a34755386b3350d898aa1638c349723b57 | [
"BSD-3-Clause"
] | null | null | null | weasyprint/tests/test_stacking.py | Smylers/WeasyPrint | 25ce91a34755386b3350d898aa1638c349723b57 | [
"BSD-3-Clause"
] | null | null | null | # coding: utf8
"""
weasyprint.tests.stacking
-------------------------
:copyright: Copyright 2011-2012 Simon Sapin and contributors, see AUTHORS.
:license: BSD, see LICENSE for details.
"""
from __future__ import division, unicode_literals
from ..stacking import StackingContext
from .test_boxes impo... | 25.683544 | 78 | 0.556925 | 0 | 0 | 0 | 0 | 1,202 | 0.59241 | 0 | 0 | 765 | 0.377033 |
8100832c0d5bc42056a44079c84eec3ee522ecd0 | 1,143 | py | Python | django-magic-link/customers/views.py | industrydive/sourcelist | 9db4ec5c9cb9246a644615ca401a3c8f8d560b6e | [
"MIT"
] | 5 | 2017-10-28T17:17:35.000Z | 2020-06-24T21:43:22.000Z | django-magic-link/customers/views.py | greglinch/sourcelist | 8267bb060e55f036d6d2dd9648698a5b8e48c0b3 | [
"MIT"
] | 2 | 2020-02-11T21:50:49.000Z | 2021-04-08T18:25:26.000Z | django-magic-link/customers/views.py | industrydive/sourcelist | 9db4ec5c9cb9246a644615ca401a3c8f8d560b6e | [
"MIT"
] | 2 | 2017-11-02T02:14:25.000Z | 2019-05-28T15:35:44.000Z | from django.shortcuts import render
from django.contrib.auth.models import User
from django.contrib.auth.decorators import login_required
from sesame import utils
from django.core.mail import send_mail
def login_page(request):
if request.method == "POST":
email = request.POST.get("emailId")
user =... | 31.75 | 107 | 0.630796 | 0 | 0 | 0 | 0 | 100 | 0.087489 | 0 | 0 | 337 | 0.294838 |
81014d9aa2fe1551a160b448cdc227329bca693d | 3,079 | py | Python | python-lib/config/dss_parameter.py | dataiku/dss-plugin-nlp-analysis | ff9dce56500dc8f28f83158afbdf7db01074ee38 | [
"Apache-2.0"
] | 1 | 2021-03-12T10:45:53.000Z | 2021-03-12T10:45:53.000Z | python-lib/config/dss_parameter.py | dataiku/dss-plugin-nlp-analysis | ff9dce56500dc8f28f83158afbdf7db01074ee38 | [
"Apache-2.0"
] | 22 | 2021-03-01T18:49:54.000Z | 2021-06-08T15:16:30.000Z | python-lib/config/dss_parameter.py | dataiku/dss-plugin-nlp-analysis | ff9dce56500dc8f28f83158afbdf7db01074ee38 | [
"Apache-2.0"
] | 1 | 2021-02-22T15:19:43.000Z | 2021-02-22T15:19:43.000Z | from .custom_check import CustomCheck, CustomCheckError
from typing import Any, List
import logging
logger = logging.getLogger(__name__)
class DSSParameterError(Exception):
"""Exception raised when at least one CustomCheck fails."""
pass
class DSSParameter:
"""Object related to one parameter. It is m... | 33.835165 | 104 | 0.618383 | 2,934 | 0.952907 | 0 | 0 | 0 | 0 | 0 | 0 | 1,521 | 0.493992 |
81017170c94b85c3925c1875676b310a658ce79c | 21,868 | py | Python | misc/import_ch_zurich.py | mstarikov/transitfeed | c018d7b14f6fccaa670629c00c83a390b5461fc1 | [
"Apache-2.0"
] | null | null | null | misc/import_ch_zurich.py | mstarikov/transitfeed | c018d7b14f6fccaa670629c00c83a390b5461fc1 | [
"Apache-2.0"
] | null | null | null | misc/import_ch_zurich.py | mstarikov/transitfeed | c018d7b14f6fccaa670629c00c83a390b5461fc1 | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/python2.4
# Copyright (C) 2008 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable la... | 42.62768 | 94 | 0.559813 | 16,118 | 0.737059 | 510 | 0.023322 | 1,332 | 0.060911 | 0 | 0 | 6,786 | 0.310316 |
8101825b7fae5806f4a1d2d670c101bc508918db | 5,681 | py | Python | modules/documents.py | rotsee/protokollen | a001a1db86df57adcf5c53c95c4c2fae426340f1 | [
"MIT",
"Apache-2.0",
"CC0-1.0",
"Unlicense"
] | 4 | 2015-03-22T20:23:36.000Z | 2015-12-09T14:31:34.000Z | modules/documents.py | rotsee/protokollen | a001a1db86df57adcf5c53c95c4c2fae426340f1 | [
"MIT",
"Apache-2.0",
"CC0-1.0",
"Unlicense"
] | 4 | 2015-03-24T10:42:00.000Z | 2016-06-21T08:44:01.000Z | modules/documents.py | rotsee/protokollen | a001a1db86df57adcf5c53c95c4c2fae426340f1 | [
"MIT",
"Apache-2.0",
"CC0-1.0",
"Unlicense"
] | null | null | null | # -*- coding: utf-8 -*-
"""This module contains classes for documents, and lists of documents.
Documents are defined by the document rules in settings.py
A file can contain one or more document. However, a document can
not be constructed from more than one file. This is a limitation,
obvious in cases like ... | 33.417647 | 80 | 0.582996 | 4,874 | 0.857948 | 96 | 0.016898 | 0 | 0 | 0 | 0 | 1,645 | 0.289562 |
8101888cafdd6d738a67d105df6945c67e4d48e2 | 773 | py | Python | tools/amp_segment/ina_speech_segmenter.py | saratkumar/galaxy | 35cd0987239c1b006d6eaf70b4a03a58fb857a12 | [
"CC-BY-3.0"
] | 1 | 2020-03-11T15:17:32.000Z | 2020-03-11T15:17:32.000Z | tools/amp_segment/ina_speech_segmenter.py | saratkumar/galaxy | 35cd0987239c1b006d6eaf70b4a03a58fb857a12 | [
"CC-BY-3.0"
] | 72 | 2019-06-06T18:52:41.000Z | 2022-02-17T02:53:18.000Z | tools/done/amp_segment/ina_speech_segmenter.py | AudiovisualMetadataPlatform/amp_mgms | 593d4f4d40b597a7753cd152cd233976e6b28c75 | [
"Apache-2.0"
] | 1 | 2022-03-01T08:07:54.000Z | 2022-03-01T08:07:54.000Z | #!/usr/bin/env python3
import os
import os.path
import shutil
import subprocess
import sys
import tempfile
import uuid
import mgm_utils
def main():
(root_dir, input_file, json_file) = sys.argv[1:4]
tmpName = str(uuid.uuid4())
tmpdir = "/tmp"
temp_input_file = f"{tmpdir}/{tmpName}.dat"
temp_output_file = f"{tmpd... | 21.472222 | 83 | 0.742561 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 130 | 0.168176 |
8102b4059df75e35791f0dfa9ba091b4276e3aff | 12,313 | py | Python | test/tracerEq/test_steady_adv-diff_mms.py | jhill1/thetis | 1be5d28d5d0d7248f2bbce4986b3e886116e103a | [
"MIT"
] | null | null | null | test/tracerEq/test_steady_adv-diff_mms.py | jhill1/thetis | 1be5d28d5d0d7248f2bbce4986b3e886116e103a | [
"MIT"
] | null | null | null | test/tracerEq/test_steady_adv-diff_mms.py | jhill1/thetis | 1be5d28d5d0d7248f2bbce4986b3e886116e103a | [
"MIT"
] | null | null | null | """
Testing 3D tracer advection-diffusion equation with method of manufactured solution (MMS).
"""
from thetis import *
import numpy
from scipy import stats
import pytest
class Setup1:
"""
Constant bathymetry and u velocty, zero diffusivity, non-trivial tracer
"""
def bath(self, x, y, lx, ly):
... | 37.769939 | 1,095 | 0.559165 | 5,664 | 0.460002 | 0 | 0 | 338 | 0.027451 | 0 | 0 | 1,447 | 0.117518 |
810397b3d3caaed833502145ab5542c3eb653710 | 723 | py | Python | csat/django/fields.py | GaretJax/csat | db63441136369436140a91c9657444353c8944e6 | [
"MIT"
] | null | null | null | csat/django/fields.py | GaretJax/csat | db63441136369436140a91c9657444353c8944e6 | [
"MIT"
] | 7 | 2020-06-05T17:15:29.000Z | 2022-02-11T03:38:15.000Z | csat/django/fields.py | GaretJax/csat | db63441136369436140a91c9657444353c8944e6 | [
"MIT"
] | null | null | null | from lxml import etree
from django import forms
from django.db import models
class XMLFileField(models.FileField):
def __init__(self, *args, **kwargs):
self.schema = kwargs.pop('schema')
super(XMLFileField, self).__init__(*args, **kwargs)
def clean(self, *args, **kwargs):
data = supe... | 28.92 | 74 | 0.60166 | 642 | 0.887967 | 0 | 0 | 0 | 0 | 0 | 0 | 72 | 0.099585 |
8104cf1d7fdf7aff507bf4b2cd4aa7b19708a446 | 15,658 | py | Python | keras_cv_attention_models/yolox/yolox.py | RishabhSehgal/keras_cv_attention_models | c1e20e45815339d70a987ec7dd9e6f926b4eb21d | [
"MIT"
] | null | null | null | keras_cv_attention_models/yolox/yolox.py | RishabhSehgal/keras_cv_attention_models | c1e20e45815339d70a987ec7dd9e6f926b4eb21d | [
"MIT"
] | null | null | null | keras_cv_attention_models/yolox/yolox.py | RishabhSehgal/keras_cv_attention_models | c1e20e45815339d70a987ec7dd9e6f926b4eb21d | [
"MIT"
] | null | null | null | import tensorflow as tf
from tensorflow import keras
from keras_cv_attention_models.attention_layers import (
activation_by_name,
batchnorm_with_activation,
conv2d_no_bias,
depthwise_conv2d_no_bias,
add_pre_post_process,
)
from keras_cv_attention_models import model_surgery
from keras_cv_attention_m... | 54.940351 | 156 | 0.709158 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2,748 | 0.174676 |
8104ee7a90ab52a7bdf79ad5abbc624a2b356482 | 4,064 | py | Python | robot-server/tests/service/json_api/test_response.py | mrod0101/opentrons | 6450edb0421f1c2484c292f8583602d8f6fd13b8 | [
"Apache-2.0"
] | null | null | null | robot-server/tests/service/json_api/test_response.py | mrod0101/opentrons | 6450edb0421f1c2484c292f8583602d8f6fd13b8 | [
"Apache-2.0"
] | 2 | 2022-02-15T03:28:35.000Z | 2022-02-28T01:34:18.000Z | robot-server/tests/service/json_api/test_response.py | mrod0101/opentrons | 6450edb0421f1c2484c292f8583602d8f6fd13b8 | [
"Apache-2.0"
] | null | null | null | from pytest import raises
from pydantic import ValidationError
from robot_server.service.json_api.response import (
ResponseDataModel,
ResponseModel,
MultiResponseModel,
)
from tests.service.helpers import ItemResponseModel
def test_attributes_as_dict() -> None:
MyResponse = ResponseModel[ResponseDat... | 26.913907 | 78 | 0.483514 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 776 | 0.190945 |
81050df4590617cea7e0daedc54d45bd783c7cfa | 367 | py | Python | stickmanZ/__main__.py | MichaelMcFarland98/cse210-project | 9e5a45a75f465fe123e33712d3c19dd88e98246a | [
"MIT"
] | 1 | 2021-07-24T00:40:14.000Z | 2021-07-24T00:40:14.000Z | stickmanZ/__main__.py | MichaelMcFarland98/cse210-project | 9e5a45a75f465fe123e33712d3c19dd88e98246a | [
"MIT"
] | null | null | null | stickmanZ/__main__.py | MichaelMcFarland98/cse210-project | 9e5a45a75f465fe123e33712d3c19dd88e98246a | [
"MIT"
] | null | null | null |
from game.game_view import GameView
from game.menu_view import menu_view
from game import constants
import arcade
SCREEN_WIDTH = constants.SCREEN_WIDTH
SCREEN_HEIGHT = constants.SCREEN_HEIGHT
SCREEN_TITLE = constants.SCREEN_TITLE
window = arcade.Window(SCREEN_WIDTH, SCREEN_HEIGHT, SCREEN_TITLE)
start_view = menu_vi... | 22.9375 | 65 | 0.836512 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
81053c6c0f8dac07d6cae3bc4a12cf5b1f575105 | 2,300 | py | Python | neutron/db/migration/alembic_migrations/versions/mitaka/contract/c6c112992c9_rbac_qos_policy.py | congnt95/neutron | 6a73a362c5ff5b7c28c15a49f47a9900c0d2b4e1 | [
"Apache-2.0"
] | 1,080 | 2015-01-04T08:35:00.000Z | 2022-03-27T09:15:52.000Z | neutron/db/migration/alembic_migrations/versions/mitaka/contract/c6c112992c9_rbac_qos_policy.py | congnt95/neutron | 6a73a362c5ff5b7c28c15a49f47a9900c0d2b4e1 | [
"Apache-2.0"
] | 24 | 2015-02-21T01:48:28.000Z | 2021-11-26T02:38:56.000Z | neutron/db/migration/alembic_migrations/versions/mitaka/contract/c6c112992c9_rbac_qos_policy.py | congnt95/neutron | 6a73a362c5ff5b7c28c15a49f47a9900c0d2b4e1 | [
"Apache-2.0"
] | 1,241 | 2015-01-02T10:47:10.000Z | 2022-03-27T09:42:23.000Z | # Copyright 2015 OpenStack Foundation
#
# 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 ... | 33.333333 | 78 | 0.665652 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1,057 | 0.459565 |
8105a101c915deb0c3d41bd2462e33e9a3a8584e | 1,200 | py | Python | chapter5/ch5_gcp_subscriber.py | ericchou1/network-devops-kafka-up-and-running | c128cf7359ba40c3005a02d3033b16b67c196779 | [
"Apache-2.0"
] | 1 | 2021-12-30T08:55:09.000Z | 2021-12-30T08:55:09.000Z | chapter5/ch5_gcp_subscriber.py | ericchou1/network-devops-kafka-up-and-running | c128cf7359ba40c3005a02d3033b16b67c196779 | [
"Apache-2.0"
] | null | null | null | chapter5/ch5_gcp_subscriber.py | ericchou1/network-devops-kafka-up-and-running | c128cf7359ba40c3005a02d3033b16b67c196779 | [
"Apache-2.0"
] | 2 | 2021-11-22T09:56:30.000Z | 2022-02-06T22:55:55.000Z | from concurrent.futures import TimeoutError
from google.cloud import pubsub_v1
project_id = "pubsub-testing-331300"
subscription_id = "test-sub"
# Number of seconds the subscriber should listen for messages
timeout = 5.0
subscriber = pubsub_v1.SubscriberClient()
# The `subscription_path` method creates a fully qualif... | 38.709677 | 82 | 0.766667 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 549 | 0.4575 |
8107dd8d87df5ce3c83ed8d4993880ee03266544 | 2,136 | py | Python | odoo-13.0/addons/google_drive/models/res_config_settings.py | VaibhavBhujade/Blockchain-ERP-interoperability | b5190a037fb6615386f7cbad024d51b0abd4ba03 | [
"MIT"
] | null | null | null | odoo-13.0/addons/google_drive/models/res_config_settings.py | VaibhavBhujade/Blockchain-ERP-interoperability | b5190a037fb6615386f7cbad024d51b0abd4ba03 | [
"MIT"
] | null | null | null | odoo-13.0/addons/google_drive/models/res_config_settings.py | VaibhavBhujade/Blockchain-ERP-interoperability | b5190a037fb6615386f7cbad024d51b0abd4ba03 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
# Part of Odoo. See LICENSE file for full copyright and licensing details.
from odoo import api, fields, models, _
class ResConfigSettings(models.TransientModel):
_inherit = "res.config.settings"
google_drive_authorization_code = fields.Char(string='Authorization Code', config_parame... | 45.446809 | 142 | 0.69382 | 1,993 | 0.933052 | 0 | 0 | 307 | 0.143727 | 0 | 0 | 667 | 0.312266 |
81081edbfb2a07d5868f34f5440db42fe2a2e90a | 17,308 | py | Python | dataloaders/loader.py | sanger640/attMPTI | a2784b784e0900f3603baa3779631da67bcd0562 | [
"MIT"
] | 93 | 2021-03-18T13:56:42.000Z | 2022-03-30T03:31:35.000Z | dataloaders/loader.py | sanger640/attMPTI | a2784b784e0900f3603baa3779631da67bcd0562 | [
"MIT"
] | 20 | 2021-03-30T12:36:05.000Z | 2022-03-28T09:01:34.000Z | dataloaders/loader.py | sanger640/attMPTI | a2784b784e0900f3603baa3779631da67bcd0562 | [
"MIT"
] | 14 | 2021-04-17T17:19:19.000Z | 2022-03-09T13:49:30.000Z | """ Data Loader for Generating Tasks
Author: Zhao Na, 2020
"""
import os
import random
import math
import glob
import numpy as np
import h5py as h5
import transforms3d
from itertools import combinations
import torch
from torch.utils.data import Dataset
def sample_K_pointclouds(data_path, num_point, pc_attribs, pc_... | 46.526882 | 129 | 0.621389 | 9,882 | 0.57095 | 0 | 0 | 0 | 0 | 0 | 0 | 1,665 | 0.096198 |
8109517cd2448992084aac4cf51be9ed93b5e56f | 467 | py | Python | greendoge/types/condition_with_args.py | grayfallstown/greendoge-blockchain | 31e325913374d694dc0859140d006a642e7f95ac | [
"Apache-2.0"
] | 44 | 2021-07-06T10:09:06.000Z | 2022-02-09T04:30:14.000Z | greendoge/types/condition_with_args.py | grayfallstown/greendoge-blockchain | 31e325913374d694dc0859140d006a642e7f95ac | [
"Apache-2.0"
] | 67 | 2021-07-06T11:57:18.000Z | 2022-02-02T16:14:15.000Z | greendoge/types/condition_with_args.py | grayfallstown/greendoge-blockchain | 31e325913374d694dc0859140d006a642e7f95ac | [
"Apache-2.0"
] | 16 | 2021-07-06T10:36:37.000Z | 2022-03-15T08:35:16.000Z | from dataclasses import dataclass
from typing import List
from greendoge.types.condition_opcodes import ConditionOpcode
from greendoge.util.streamable import Streamable, streamable
@dataclass(frozen=True)
@streamable
class ConditionWithArgs(Streamable):
"""
This structure is used to store parsed CLVM conditi... | 25.944444 | 83 | 0.770878 | 246 | 0.526767 | 0 | 0 | 282 | 0.603854 | 0 | 0 | 154 | 0.329764 |
810978ce9b3f6467c879457442fbbbac1342a8e8 | 3,065 | py | Python | homeassistant/components/hunterdouglas_powerview/entity.py | pp81381/home-assistant | 23e362faf387c1535be0abab81b30d8e4631df4b | [
"Apache-2.0"
] | null | null | null | homeassistant/components/hunterdouglas_powerview/entity.py | pp81381/home-assistant | 23e362faf387c1535be0abab81b30d8e4631df4b | [
"Apache-2.0"
] | 31 | 2020-07-23T07:13:38.000Z | 2021-06-07T13:21:18.000Z | homeassistant/components/hunterdouglas_powerview/entity.py | pp81381/home-assistant | 23e362faf387c1535be0abab81b30d8e4631df4b | [
"Apache-2.0"
] | null | null | null | """The nexia integration base entity."""
from aiopvapi.resources.shade import ATTR_TYPE
from homeassistant.const import ATTR_MODEL, ATTR_SW_VERSION
import homeassistant.helpers.device_registry as dr
from homeassistant.helpers.entity import DeviceInfo
from homeassistant.helpers.update_coordinator import CoordinatorEnt... | 32.606383 | 114 | 0.669494 | 2,491 | 0.812724 | 0 | 0 | 1,790 | 0.584013 | 0 | 0 | 490 | 0.159869 |
810a3b9f5eeaf3e888067a624f744f48f465345b | 9,244 | py | Python | keycast_env/lib/python3.8/site-packages/Xlib/ext/res.py | daxter-army/key-cast | cadc88c6760839b37b7fef969294800d4c38fb1b | [
"MIT"
] | 10 | 2021-09-15T16:29:59.000Z | 2022-01-15T11:51:56.000Z | lib/Xlib/ext/res.py | ITZProGamerDieYT/SpeedrunningTimerLinux | 4383c8fdfff476fdb81a99a1d6271218e6e9eee3 | [
"CC-BY-3.0"
] | 7 | 2021-09-16T06:21:44.000Z | 2022-03-18T03:11:25.000Z | lib/Xlib/ext/res.py | ITZProGamerDieYT/SpeedrunningTimerLinux | 4383c8fdfff476fdb81a99a1d6271218e6e9eee3 | [
"CC-BY-3.0"
] | 3 | 2021-09-20T13:08:43.000Z | 2022-03-18T03:09:08.000Z | # Xlib.ext.res -- X-Resource extension module
#
# Copyright (C) 2021 Aleksei Bavshin <[email protected]>
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public License
# as published by the Free Software Foundation; either version 2.1
... | 31.986159 | 83 | 0.609801 | 3,338 | 0.361099 | 0 | 0 | 0 | 0 | 0 | 0 | 3,418 | 0.369753 |
810a45957301a3d3e19c056d8cdd8e9cf5349711 | 1,690 | py | Python | rubra/cmdline_args.py | scwatts/rubra | 0be2c1e8d56badf134954baab9705f3aeb38d426 | [
"MIT"
] | 14 | 2015-04-13T04:10:43.000Z | 2022-03-28T08:42:43.000Z | rubra/cmdline_args.py | afcarl/rubra | 82905bbbd7077d201363b96ffbbc78c099095764 | [
"MIT"
] | 3 | 2016-12-27T17:24:04.000Z | 2018-12-21T17:43:36.000Z | rubra/cmdline_args.py | afcarl/rubra | 82905bbbd7077d201363b96ffbbc78c099095764 | [
"MIT"
] | 9 | 2015-04-29T03:00:16.000Z | 2020-01-30T00:56:52.000Z | # Process the unix command line of the pipeline.
import argparse
from version import rubra_version
def get_cmdline_args():
return parser.parse_args()
parser = argparse.ArgumentParser(
description='A bioinformatics pipeline system.')
parser.add_argument(
'pipeline',
metavar='PIPELINE_FILE',
type=... | 26.825397 | 84 | 0.657396 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 781 | 0.46213 |
810ae31f2bd87d1c18d17e372bfc5f6a1cddf8a3 | 268 | py | Python | main.py | KH241/Geohashing | d5d51278776c4dc0e3d6e6c39cbd31c1f4442fc1 | [
"CC0-1.0"
] | null | null | null | main.py | KH241/Geohashing | d5d51278776c4dc0e3d6e6c39cbd31c1f4442fc1 | [
"CC0-1.0"
] | null | null | null | main.py | KH241/Geohashing | d5d51278776c4dc0e3d6e6c39cbd31c1f4442fc1 | [
"CC0-1.0"
] | null | null | null | import webbrowser
import config
from Generator import Generator
def main():
generator = Generator()
latitude, longitude = generator.getCoordinates()
webbrowser.open(config.api_request.format(latitude, longitude))
if __name__ == '__main__':
main()
| 17.866667 | 67 | 0.735075 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 10 | 0.037313 |
810b128cc1280e3c864be85f0fd7db633ecb097d | 35,104 | py | Python | knx-test.py | WAvdBeek/CoAPthon3 | 5aa9d6a6d9a2903d86b113da538df9bd970e6b44 | [
"MIT"
] | 1 | 2021-11-05T08:04:33.000Z | 2021-11-05T08:04:33.000Z | knx-test.py | WAvdBeek/CoAPthon3 | 5aa9d6a6d9a2903d86b113da538df9bd970e6b44 | [
"MIT"
] | 1 | 2021-07-21T12:40:54.000Z | 2021-07-21T14:42:42.000Z | knx-test.py | WAvdBeek/CoAPthon3 | 5aa9d6a6d9a2903d86b113da538df9bd970e6b44 | [
"MIT"
] | 1 | 2021-07-20T10:18:17.000Z | 2021-07-20T10:18:17.000Z | #!/usr/bin/env python
import getopt
import socket
import sys
import cbor
#from cbor2 import dumps, loads
import json
import time
import traceback
from coapthon.client.helperclient import HelperClient
from coapthon.utils import parse_uri
from coapthon import defines
client = None
paths = {}
paths_extend = {}
my_base ... | 33.786333 | 149 | 0.546206 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 10,398 | 0.296206 |
810b43515d14811ec32c14454930c4b55606640a | 210 | py | Python | SWIM-Executables/Windows/pyinstaller-2.0 for windows/PyInstaller/hooks/hook-PyQt4.phonon.py | alexsigaras/SWIM | 1a35df8acb26bdcb307a1b8f60e9feba68ed1715 | [
"MIT"
] | 47 | 2020-03-08T08:43:28.000Z | 2022-03-18T18:51:55.000Z | SWIM-Executables/Windows/pyinstaller-2.0 for windows/PyInstaller/hooks/hook-PyQt4.phonon.py | alexsigaras/SWIM | 1a35df8acb26bdcb307a1b8f60e9feba68ed1715 | [
"MIT"
] | null | null | null | SWIM-Executables/Windows/pyinstaller-2.0 for windows/PyInstaller/hooks/hook-PyQt4.phonon.py | alexsigaras/SWIM | 1a35df8acb26bdcb307a1b8f60e9feba68ed1715 | [
"MIT"
] | 16 | 2020-03-08T08:43:30.000Z | 2022-01-10T22:05:57.000Z | hiddenimports = ['sip', 'PyQt4.QtGui', 'PyQt4._qt']
from PyInstaller.hooks.hookutils import qt4_plugins_binaries
def hook(mod):
mod.binaries.extend(qt4_plugins_binaries('phonon_backend'))
return mod
| 23.333333 | 63 | 0.757143 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 45 | 0.214286 |
810b6e9e54a3c45eed3b42ac6920a9d12535f63c | 6,579 | py | Python | PyTradier/data.py | zlopez101/PyTradier | 83397cf38bd636c471993b57fb71a12885affcb7 | [
"MIT"
] | 1 | 2021-04-30T23:59:20.000Z | 2021-04-30T23:59:20.000Z | PyTradier/data.py | zlopez101/PyTradier | 83397cf38bd636c471993b57fb71a12885affcb7 | [
"MIT"
] | 7 | 2021-05-08T00:47:59.000Z | 2021-05-12T01:45:37.000Z | PyTradier/data.py | zlopez101/PyTradier | 83397cf38bd636c471993b57fb71a12885affcb7 | [
"MIT"
] | null | null | null | from PyTradier.base import BasePyTradier
from typing import Union
from datetime import datetime
class MarketData(BasePyTradier):
"""All Methods currently only support string API calls, no datetime, bools, etc
"""
def quotes(self, symbols: Union[str, list], greeks: bool = False) -> dict:
"""Get a ... | 42.173077 | 289 | 0.637635 | 6,258 | 0.951208 | 0 | 0 | 0 | 0 | 0 | 0 | 4,621 | 0.702386 |
810c05c71eb3fa5c73eabbeb8e2c1122faa7ac10 | 3,528 | py | Python | joulescope_ui/meter_widget.py | Axel-Jacobsen/pyjoulescope_ui | 7d296b1ead0d36c6524dc399372f7888a340e9fa | [
"Apache-2.0"
] | 1 | 2019-08-08T21:10:26.000Z | 2019-08-08T21:10:26.000Z | joulescope_ui/meter_widget.py | Axel-Jacobsen/pyjoulescope_ui | 7d296b1ead0d36c6524dc399372f7888a340e9fa | [
"Apache-2.0"
] | null | null | null | joulescope_ui/meter_widget.py | Axel-Jacobsen/pyjoulescope_ui | 7d296b1ead0d36c6524dc399372f7888a340e9fa | [
"Apache-2.0"
] | null | null | null | # Copyright 2018 Jetperch 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 agreed to in writing,... | 40.090909 | 122 | 0.693311 | 2,650 | 0.750708 | 0 | 0 | 239 | 0.067705 | 0 | 0 | 991 | 0.280737 |
810c343fb0a1f912fe6668116ca4d1081009f872 | 7,677 | py | Python | rpyc/core/service.py | bbonf/rpyc | 2c66dd6936a0d9e6e36c1ba0cda1139676acf95c | [
"MIT"
] | null | null | null | rpyc/core/service.py | bbonf/rpyc | 2c66dd6936a0d9e6e36c1ba0cda1139676acf95c | [
"MIT"
] | null | null | null | rpyc/core/service.py | bbonf/rpyc | 2c66dd6936a0d9e6e36c1ba0cda1139676acf95c | [
"MIT"
] | null | null | null | """
Services are the heart of RPyC: each side of the connection exposes a *service*,
which define the capabilities available to the other side.
Note that the services by both parties need not be symmetric, e.g., one side may
exposed *service A*, while the other may expose *service B*. As long as the two
can interopera... | 34.426009 | 86 | 0.64804 | 7,156 | 0.932135 | 0 | 0 | 1,476 | 0.192263 | 0 | 0 | 3,748 | 0.488212 |
810c8d17b4b4f09855fad0d286b79401e57777c2 | 307 | py | Python | tests/task/manager_test.py | altenia/taskmator | 4090d414125614a57649c5c92a017c12a231a2ef | [
"MIT"
] | 2 | 2015-06-06T04:59:53.000Z | 2020-08-15T22:45:01.000Z | tests/task/manager_test.py | altenia/taskmator | 4090d414125614a57649c5c92a017c12a231a2ef | [
"MIT"
] | 1 | 2015-06-06T05:02:24.000Z | 2015-06-06T05:02:24.000Z | tests/task/manager_test.py | altenia/taskmator | 4090d414125614a57649c5c92a017c12a231a2ef | [
"MIT"
] | null | null | null | import unittest
from testbase import TaskmatorTestBase
from taskmator.task import core, util
from taskmator import context
class ManagerTest(TaskmatorTestBase):
def testManager(self):
print ("Pending")
def main():
unittest.main()
if __name__ == '__main__':
unittest.main()
| 17.055556 | 38 | 0.710098 | 133 | 0.433225 | 0 | 0 | 0 | 0 | 0 | 0 | 19 | 0.061889 |
810ccb8df33ca9c859d68156c3d23f37b798cbf1 | 1,301 | py | Python | tests/components/zwave_js/test_discovery.py | tbarbette/core | 8e58c3aa7bc8d2c2b09b6bd329daa1c092d52d3c | [
"Apache-2.0"
] | 1 | 2020-12-18T12:23:04.000Z | 2020-12-18T12:23:04.000Z | tests/components/zwave_js/test_discovery.py | tbarbette/core | 8e58c3aa7bc8d2c2b09b6bd329daa1c092d52d3c | [
"Apache-2.0"
] | 60 | 2020-07-06T15:10:30.000Z | 2022-03-31T06:01:46.000Z | tests/components/zwave_js/test_discovery.py | tbarbette/core | 8e58c3aa7bc8d2c2b09b6bd329daa1c092d52d3c | [
"Apache-2.0"
] | 4 | 2017-01-10T04:17:33.000Z | 2021-09-02T16:37:24.000Z | """Test discovery of entities for device-specific schemas for the Z-Wave JS integration."""
async def test_iblinds_v2(hass, client, iblinds_v2, integration):
"""Test that an iBlinds v2.0 multilevel switch value is discovered as a cover."""
node = iblinds_v2
assert node.device_class.specific.label == "Unus... | 34.236842 | 91 | 0.731745 | 0 | 0 | 0 | 0 | 0 | 0 | 1,200 | 0.922367 | 559 | 0.429669 |
810dcd1a1c119a6c004be66c020243fbafedf1ee | 5,229 | py | Python | boto3_type_annotations/boto3_type_annotations/guardduty/client.py | cowboygneox/boto3_type_annotations | 450dce1de4e066b939de7eac2ec560ed1a7ddaa2 | [
"MIT"
] | 119 | 2018-12-01T18:20:57.000Z | 2022-02-02T10:31:29.000Z | boto3_type_annotations/boto3_type_annotations/guardduty/client.py | cowboygneox/boto3_type_annotations | 450dce1de4e066b939de7eac2ec560ed1a7ddaa2 | [
"MIT"
] | 15 | 2018-11-16T00:16:44.000Z | 2021-11-13T03:44:18.000Z | boto3_type_annotations/boto3_type_annotations/guardduty/client.py | cowboygneox/boto3_type_annotations | 450dce1de4e066b939de7eac2ec560ed1a7ddaa2 | [
"MIT"
] | 11 | 2019-05-06T05:26:51.000Z | 2021-09-28T15:27:59.000Z | from typing import Optional
from botocore.client import BaseClient
from typing import Dict
from typing import Union
from botocore.paginate import Paginator
from botocore.waiter import Waiter
from typing import List
class Client(BaseClient):
def accept_invitation(self, DetectorId: str, InvitationId: str, MasterId:... | 35.331081 | 175 | 0.669344 | 5,011 | 0.958309 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
810e20d4bc8d21dc6f3aae023a1133ca2d856392 | 1,218 | py | Python | test/workload/tpch_loop_workload_test.py | ChenYi015/Raven | e732e03f8dd118ed805a143fc6916f0e5fc53c2c | [
"Apache-2.0"
] | 1 | 2022-03-03T05:54:25.000Z | 2022-03-03T05:54:25.000Z | test/workload/tpch_loop_workload_test.py | ChenYi015/Raven | e732e03f8dd118ed805a143fc6916f0e5fc53c2c | [
"Apache-2.0"
] | null | null | null | test/workload/tpch_loop_workload_test.py | ChenYi015/Raven | e732e03f8dd118ed805a143fc6916f0e5fc53c2c | [
"Apache-2.0"
] | null | null | null | # Copyright 2021 Raven Authors. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or ... | 26.478261 | 74 | 0.705255 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 624 | 0.512315 |
810e3e3e48092c408dee59bf8a6eb974e84689eb | 1,475 | py | Python | Final-Project/server/art/serializers.py | wendy006/Web-Dev-Course | 2f0cfddb7ab4db88ffb4483c7cd4a00abf36c720 | [
"MIT"
] | null | null | null | Final-Project/server/art/serializers.py | wendy006/Web-Dev-Course | 2f0cfddb7ab4db88ffb4483c7cd4a00abf36c720 | [
"MIT"
] | null | null | null | Final-Project/server/art/serializers.py | wendy006/Web-Dev-Course | 2f0cfddb7ab4db88ffb4483c7cd4a00abf36c720 | [
"MIT"
] | null | null | null | from rest_framework import serializers
from .models import *
class CollectionSerializer(serializers.ModelSerializer):
class Meta:
model = Collection
fields = ('collectionID', 'name', 'display_name', 'description', 'img_url')
class ArtSerializer(serializers.ModelSerializer):
img_url = ... | 35.97561 | 124 | 0.626441 | 1,394 | 0.945085 | 0 | 0 | 0 | 0 | 0 | 0 | 312 | 0.211525 |
810f24ca6e713fb7958aa28861ebd60291bab8c3 | 2,089 | bzl | Python | google/cloud/google_cloud_cpp_common_unit_tests.bzl | joezqren/google-cloud-cpp | 325d312b0a21569f3c57515aec7d91f3540d3b48 | [
"Apache-2.0"
] | null | null | null | google/cloud/google_cloud_cpp_common_unit_tests.bzl | joezqren/google-cloud-cpp | 325d312b0a21569f3c57515aec7d91f3540d3b48 | [
"Apache-2.0"
] | null | null | null | google/cloud/google_cloud_cpp_common_unit_tests.bzl | joezqren/google-cloud-cpp | 325d312b0a21569f3c57515aec7d91f3540d3b48 | [
"Apache-2.0"
] | null | null | null | # Copyright 2018 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, ... | 34.245902 | 79 | 0.727621 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1,790 | 0.856869 |
8111119b844622ccdb3004ede98c4e13a46f452c | 398 | py | Python | api/tests/ver1/test_base.py | codacy-badger/politico-api | 10d926bf34f12631cb19bb9c82ccded36557c790 | [
"MIT"
] | null | null | null | api/tests/ver1/test_base.py | codacy-badger/politico-api | 10d926bf34f12631cb19bb9c82ccded36557c790 | [
"MIT"
] | null | null | null | api/tests/ver1/test_base.py | codacy-badger/politico-api | 10d926bf34f12631cb19bb9c82ccded36557c790 | [
"MIT"
] | null | null | null | import unittest
from api import create_app
class TestBase(unittest.TestCase):
"""Default super class for api ver 1 tests"""
# setup testing
def setUp(self):
self.app = create_app('testing')
self.client = self.app.test_client()
self.item_list = []
# deconstructs test elements
... | 23.411765 | 49 | 0.640704 | 353 | 0.886935 | 0 | 0 | 0 | 0 | 0 | 0 | 97 | 0.243719 |
811134f08b2c67534a9093ee9d1a20f045af6b48 | 865 | py | Python | socialdistribution/app/templatetags/filters.py | CMPUT404-Project-Group/CMPUT404-Group-Project | e541cc609f260d7221fe0be8975c5b2444d74af0 | [
"W3C-20150513"
] | null | null | null | socialdistribution/app/templatetags/filters.py | CMPUT404-Project-Group/CMPUT404-Group-Project | e541cc609f260d7221fe0be8975c5b2444d74af0 | [
"W3C-20150513"
] | 44 | 2021-10-14T15:44:46.000Z | 2021-12-05T00:57:23.000Z | socialdistribution/app/templatetags/filters.py | CMPUT404-Project-Group/Social-Distribution-CMPUT404-Group-Project | e541cc609f260d7221fe0be8975c5b2444d74af0 | [
"W3C-20150513"
] | 1 | 2021-12-07T01:14:14.000Z | 2021-12-07T01:14:14.000Z | from django import template
from django.template.defaultfilters import stringfilter
from django.utils.safestring import SafeString
import markdown
import urllib
register = template.Library()
@register.filter
def strip_space(value):
return value.replace(' ', '')
@register.filter
@stringfilter
def commonmark(value... | 23.378378 | 76 | 0.721387 | 0 | 0 | 0 | 0 | 662 | 0.765318 | 0 | 0 | 99 | 0.114451 |
81118158b2fe646b1e3b2899f2e0b74a521117c9 | 3,234 | py | Python | alipay/aop/api/domain/MetroOdItem.py | antopen/alipay-sdk-python-all | 8e51c54409b9452f8d46c7bb10eea7c8f7e8d30c | [
"Apache-2.0"
] | 213 | 2018-08-27T16:49:32.000Z | 2021-12-29T04:34:12.000Z | alipay/aop/api/domain/MetroOdItem.py | antopen/alipay-sdk-python-all | 8e51c54409b9452f8d46c7bb10eea7c8f7e8d30c | [
"Apache-2.0"
] | 29 | 2018-09-29T06:43:00.000Z | 2021-09-02T03:27:32.000Z | alipay/aop/api/domain/MetroOdItem.py | antopen/alipay-sdk-python-all | 8e51c54409b9452f8d46c7bb10eea7c8f7e8d30c | [
"Apache-2.0"
] | 59 | 2018-08-27T16:59:26.000Z | 2022-03-25T10:08:15.000Z | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import json
from alipay.aop.api.constant.ParamConstants import *
from alipay.aop.api.domain.CloudbusUserInfo import CloudbusUserInfo
class MetroOdItem(object):
def __init__(self):
self._dest_geo = None
self._od = None
self._time = None
... | 26.95 | 70 | 0.548856 | 3,049 | 0.942795 | 0 | 0 | 1,424 | 0.440322 | 0 | 0 | 336 | 0.103896 |
81145bece0e3560e4fd661b7085c6a1e4f6811f2 | 910 | py | Python | djangocms_redirect/migrations/0003_auto_20190810_1009.py | vsalat/djangocms-redirect | a2577f08430b6b65ae4a51293f861b697bf4ab9d | [
"BSD-3-Clause"
] | null | null | null | djangocms_redirect/migrations/0003_auto_20190810_1009.py | vsalat/djangocms-redirect | a2577f08430b6b65ae4a51293f861b697bf4ab9d | [
"BSD-3-Clause"
] | null | null | null | djangocms_redirect/migrations/0003_auto_20190810_1009.py | vsalat/djangocms-redirect | a2577f08430b6b65ae4a51293f861b697bf4ab9d | [
"BSD-3-Clause"
] | null | null | null | # Generated by Django 2.2.4 on 2019-08-10 08:09
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('djangocms_redirect', '0002_auto_20170321_1807'),
]
operations = [
migrations.AddField(
model_name='redirect',
name='... | 37.916667 | 239 | 0.679121 | 817 | 0.897802 | 0 | 0 | 0 | 0 | 0 | 0 | 428 | 0.47033 |
811898bc6c0124ca8489662af03fc5f7195a1876 | 5,191 | py | Python | octopart/scrape_octopart.py | nicholaschiang/dl-datasheets | 1c5ab2545a85c1ea7643fc655005259544617d90 | [
"MIT"
] | null | null | null | octopart/scrape_octopart.py | nicholaschiang/dl-datasheets | 1c5ab2545a85c1ea7643fc655005259544617d90 | [
"MIT"
] | null | null | null | octopart/scrape_octopart.py | nicholaschiang/dl-datasheets | 1c5ab2545a85c1ea7643fc655005259544617d90 | [
"MIT"
] | 1 | 2019-12-07T20:13:06.000Z | 2019-12-07T20:13:06.000Z | #! /usr/bin/env python
import sys
import json
import urllib
import urllib2
import time
import argparse
import re
# Category ID for Discrete Semiconductors > Transistors > BJTs
TRANSISTOR_ID = b814751e89ff63d3
def find_total_hits(search_query):
"""
Function: find_total_hits
--------------------
Return... | 38.169118 | 97 | 0.571374 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2,324 | 0.447698 |
811909fd3d9bc00f5888c3293282a4df3cefdd8c | 14,970 | py | Python | extras/python/fogbench/__main__.py | foglamp/FogLAMP | 918dff88b440e6ad580efdaa5f0fbdf4143a73d4 | [
"Apache-2.0"
] | 65 | 2017-05-15T21:55:04.000Z | 2022-01-19T01:30:42.000Z | extras/python/fogbench/__main__.py | foglamp/FogLAMP | 918dff88b440e6ad580efdaa5f0fbdf4143a73d4 | [
"Apache-2.0"
] | 576 | 2017-05-22T05:41:07.000Z | 2020-02-13T07:48:58.000Z | extras/python/fogbench/__main__.py | foglamp/FogLAMP | 918dff88b440e6ad580efdaa5f0fbdf4143a73d4 | [
"Apache-2.0"
] | 52 | 2017-05-09T22:45:47.000Z | 2022-03-10T18:49:02.000Z | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
# FOGLAMP_BEGIN
# See: http://foglamp.readthedocs.io/
# FOGLAMP_END
""" fogbench -- a Python script used to test FogLAMP.
The objective is to simulate payloads for input, REST and other requests against one or
more FogLAMP instances. This version of fogbench is meant ... | 36.601467 | 122 | 0.638277 | 0 | 0 | 0 | 0 | 0 | 0 | 1,650 | 0.11022 | 6,320 | 0.422178 |
81197e9fdd38be14f8210f08e7cec2020796f260 | 19,888 | py | Python | qiskit/ignis/mitigation/measurement/filters.py | paulineollitrault/qiskit-ignis | 99f24ea6533cd284be4c44a48d43e54f62f05674 | [
"Apache-2.0"
] | 182 | 2019-02-19T22:52:42.000Z | 2022-02-28T05:48:07.000Z | qiskit/ignis/mitigation/measurement/filters.py | paulineollitrault/qiskit-ignis | 99f24ea6533cd284be4c44a48d43e54f62f05674 | [
"Apache-2.0"
] | 384 | 2019-02-19T21:30:18.000Z | 2021-12-02T21:13:34.000Z | qiskit/ignis/mitigation/measurement/filters.py | paulineollitrault/qiskit-ignis | 99f24ea6533cd284be4c44a48d43e54f62f05674 | [
"Apache-2.0"
] | 203 | 2019-02-19T21:06:27.000Z | 2022-03-02T14:16:50.000Z | # -*- coding: utf-8 -*-
# This code is part of Qiskit.
#
# (C) Copyright IBM 2019.
#
# This code is licensed under the Apache License, Version 2.0. You may
# obtain a copy of this license in the LICENSE.txt file in the root directory
# of this source tree or at http://www.apache.org/licenses/LICENSE-2.0.
#
# Any modif... | 40.422764 | 100 | 0.569389 | 19,004 | 0.955551 | 0 | 0 | 1,922 | 0.096641 | 0 | 0 | 7,907 | 0.397576 |
811a461fc321525abd67f11d9522903e94b00815 | 3,067 | py | Python | 2017/adv2017-1.py | fcharlier/AdventOfCode | 6b2765da9e4d6f6b1f201897bb56043482a65bb2 | [
"WTFPL"
] | null | null | null | 2017/adv2017-1.py | fcharlier/AdventOfCode | 6b2765da9e4d6f6b1f201897bb56043482a65bb2 | [
"WTFPL"
] | null | null | null | 2017/adv2017-1.py | fcharlier/AdventOfCode | 6b2765da9e4d6f6b1f201897bb56043482a65bb2 | [
"WTFPL"
] | null | null | null | #!/usr/bin/python
def meh(captcha):
"""Returns the sum of the digits which match the next one in the captcha
input string.
>>> meh('1122')
3
>>> meh('1111')
4
>>> meh('1234')
0
>>> meh('91212129')
9
"""
result = 0
for n in range(len(captcha)):
if captcha[n]... | 61.34 | 2,134 | 0.852625 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2,599 | 0.847408 |
811bbfb3266a619b867f934c6f82a6ecb7783e88 | 111,660 | py | Python | pymatgen/analysis/graphs.py | Roy027/pymatgen | a4aa91d011033c1151b82335abd080e2b1a310d5 | [
"MIT"
] | null | null | null | pymatgen/analysis/graphs.py | Roy027/pymatgen | a4aa91d011033c1151b82335abd080e2b1a310d5 | [
"MIT"
] | null | null | null | pymatgen/analysis/graphs.py | Roy027/pymatgen | a4aa91d011033c1151b82335abd080e2b1a310d5 | [
"MIT"
] | null | null | null | # coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""
Module for graph representations of crystals.
"""
import copy
import logging
import os.path
import subprocess
import warnings
from collections import defaultdict, namedtuple
from itertools import combinati... | 37.748479 | 118 | 0.579393 | 108,474 | 0.971441 | 0 | 0 | 15,871 | 0.142133 | 0 | 0 | 48,470 | 0.434074 |
811be09e8efd00c1aea606c4e23d536a962dbfd3 | 65 | py | Python | maple/backend/singularity/__init__.py | akashdhruv/maple | 11e562f51b18b2251ea507c629a1981b031d2f35 | [
"MIT"
] | null | null | null | maple/backend/singularity/__init__.py | akashdhruv/maple | 11e562f51b18b2251ea507c629a1981b031d2f35 | [
"MIT"
] | 5 | 2021-12-24T08:55:42.000Z | 2022-02-13T16:59:30.000Z | maple/backend/singularity/__init__.py | akashdhruv/maple | 11e562f51b18b2251ea507c629a1981b031d2f35 | [
"MIT"
] | null | null | null | from . import image
from . import container
from . import system
| 16.25 | 23 | 0.769231 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
811c0a3b1e48996b84a2d4750219f62c35f29d83 | 1,064 | py | Python | articles/views.py | Ahmed-skb/blogyfy | 2cfa3d9503f1846ccd89c2bf1934293eb97ad44a | [
"MIT"
] | null | null | null | articles/views.py | Ahmed-skb/blogyfy | 2cfa3d9503f1846ccd89c2bf1934293eb97ad44a | [
"MIT"
] | null | null | null | articles/views.py | Ahmed-skb/blogyfy | 2cfa3d9503f1846ccd89c2bf1934293eb97ad44a | [
"MIT"
] | null | null | null | from django.shortcuts import render, redirect
from django.http import HttpResponse
from .models import Article
from django.contrib.auth.decorators import login_required
from . import forms
def Articles(request):
articles = Article.objects.all().order_by('date')
return render(request, 'articles/article_list.htm... | 34.322581 | 81 | 0.693609 | 0 | 0 | 0 | 0 | 516 | 0.484962 | 0 | 0 | 205 | 0.192669 |
811c9730165b0d65d78610ed7c5cc6d9f073addc | 5,039 | py | Python | sifter/grammar/grammar.py | russell/sifter | 03e85349fd2329439ae3f7eb3c1f484ba2ebf807 | [
"BSD-2-Clause"
] | null | null | null | sifter/grammar/grammar.py | russell/sifter | 03e85349fd2329439ae3f7eb3c1f484ba2ebf807 | [
"BSD-2-Clause"
] | null | null | null | sifter/grammar/grammar.py | russell/sifter | 03e85349fd2329439ae3f7eb3c1f484ba2ebf807 | [
"BSD-2-Clause"
] | 1 | 2020-08-19T06:30:47.000Z | 2020-08-19T06:30:47.000Z | # Parser based on RFC 5228, especially the grammar as defined in section 8. All
# references are to sections in RFC 5228 unless stated otherwise.
import ply.yacc
import sifter.grammar
from sifter.grammar.lexer import tokens
import sifter.handler
import logging
__all__ = ('parser',)
def parser(**kwargs):
return... | 29.467836 | 81 | 0.581663 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2,032 | 0.403255 |
811ce2660d66f66cb91158b2b6a72ae00e0a02c5 | 3,904 | py | Python | multidoc_mnb.py | dropofwill/author-attr-experiments | a90e2743591358a6253f3b3664f5e398517f84bc | [
"Unlicense"
] | 2 | 2015-01-06T12:53:39.000Z | 2018-02-01T13:57:09.000Z | multidoc_mnb.py | dropofwill/author-attr-experiments | a90e2743591358a6253f3b3664f5e398517f84bc | [
"Unlicense"
] | null | null | null | multidoc_mnb.py | dropofwill/author-attr-experiments | a90e2743591358a6253f3b3664f5e398517f84bc | [
"Unlicense"
] | null | null | null | from sklearn import datasets
from sklearn.feature_extraction.text import TfidfVectorizer
from sklearn.feature_extraction.text import CountVectorizer
from sklearn.cross_validation import train_test_split
from sklearn.cross_validation import cross_val_score
from sklearn.cross_validation import ShuffleSplit
from sklearn.... | 27.111111 | 175 | 0.733863 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1,283 | 0.328637 |
811e73ee0c3fc584081650f0224040703f26ea00 | 386 | py | Python | tabular/__init__.py | yamins81/tabular | 1caf091c8c395960a9ad7078f95158b533cc52dd | [
"MIT"
] | 6 | 2015-05-24T20:59:31.000Z | 2021-05-31T14:34:18.000Z | tabular/__init__.py | yamins81/tabular | 1caf091c8c395960a9ad7078f95158b533cc52dd | [
"MIT"
] | 3 | 2016-06-17T20:02:27.000Z | 2020-02-13T19:20:40.000Z | tabular/__init__.py | yamins81/tabular | 1caf091c8c395960a9ad7078f95158b533cc52dd | [
"MIT"
] | 8 | 2015-08-22T17:09:40.000Z | 2022-02-10T14:47:40.000Z | import io
import fast
import spreadsheet
import tab
import utils
import web
from io import *
from fast import *
from spreadsheet import *
from tab import *
from utils import *
from web import *
__all__ = []
__all__.extend(io.__all__)
__all__.extend(fast.__all__)
__all__.extend(spreadsheet.__all__)
__all__.extend(tab.... | 18.380952 | 35 | 0.795337 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
811eb205fb191ad48270915e49e393d586962cb9 | 26,184 | py | Python | smipyping/_targetstable.py | KSchopmeyer/smipyping | 9c60b3489f02592bd9099b8719ca23ae43a9eaa5 | [
"MIT"
] | null | null | null | smipyping/_targetstable.py | KSchopmeyer/smipyping | 9c60b3489f02592bd9099b8719ca23ae43a9eaa5 | [
"MIT"
] | 19 | 2017-10-18T15:31:25.000Z | 2020-03-04T19:31:59.000Z | smipyping/_targetstable.py | KSchopmeyer/smipyping | 9c60b3489f02592bd9099b8719ca23ae43a9eaa5 | [
"MIT"
] | null | null | null | # (C) Copyright 2017 Inova Development Inc.
# All Rights Reserved
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by appl... | 37.512894 | 80 | 0.588718 | 24,150 | 0.922319 | 0 | 0 | 973 | 0.03716 | 0 | 0 | 12,562 | 0.479759 |
811f8f9936b98c79ae19160b05e347adf2265632 | 1,131 | py | Python | dev/Code/Framework/AzFramework/CodeGen/AzEBusInline.py | jeikabu/lumberyard | 07228c605ce16cbf5aaa209a94a3cb9d6c1a4115 | [
"AML"
] | 1,738 | 2017-09-21T10:59:12.000Z | 2022-03-31T21:05:46.000Z | dev/Code/Framework/AzFramework/CodeGen/AzEBusInline.py | jeikabu/lumberyard | 07228c605ce16cbf5aaa209a94a3cb9d6c1a4115 | [
"AML"
] | 427 | 2017-09-29T22:54:36.000Z | 2022-02-15T19:26:50.000Z | dev/Code/Framework/AzFramework/CodeGen/AzEBusInline.py | jeikabu/lumberyard | 07228c605ce16cbf5aaa209a94a3cb9d6c1a4115 | [
"AML"
] | 671 | 2017-09-21T08:04:01.000Z | 2022-03-29T14:30:07.000Z | #
# All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
# its licensors.
#
# For complete copyright and license terms please see the LICENSE at the root of this
# distribution (the "License"). All use of this software is governed by the License,
# or, if provided, by the license below or th... | 39 | 95 | 0.763042 | 406 | 0.358974 | 0 | 0 | 0 | 0 | 0 | 0 | 594 | 0.525199 |
812066ffbcb9013a2cc703f8d57626a63964c5af | 9,057 | py | Python | QUANTAXIS/QASU/crawl_eastmoney.py | QUANTAXISER/QUANTAXIS | 6ebd727b2900e8910fa45814bf45eeffca395250 | [
"MIT"
] | 1 | 2018-09-09T02:55:10.000Z | 2018-09-09T02:55:10.000Z | QUANTAXIS/QASU/crawl_eastmoney.py | frosthaoz/QUANTAXIS | f5f482418e5f6e23ac3530089b8d17300d931b48 | [
"MIT"
] | null | null | null | QUANTAXIS/QASU/crawl_eastmoney.py | frosthaoz/QUANTAXIS | f5f482418e5f6e23ac3530089b8d17300d931b48 | [
"MIT"
] | 3 | 2018-11-29T07:07:56.000Z | 2021-02-09T17:24:56.000Z | import os
from QUANTAXIS.QASetting import QALocalize
#from QUANTAXIS_CRAWLY.run_selenium_alone import (read_east_money_page_zjlx_to_sqllite, open_chrome_driver, close_chrome_dirver)
from QUANTAXIS_CRAWLY.run_selenium_alone import *
import urllib
import pandas as pd
import time
from QUANTAXIS.QAUtil import (DATABASE)
... | 30.392617 | 128 | 0.510765 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 4,286 | 0.428471 |
8120aa4d76824186b0ed660869921ca64f9eaede | 667 | py | Python | wsgi.py | javicacheiro/salt-git-synchronizer-proxy | c93de5c0b26afe2b9ec72156497894df7f15d692 | [
"Apache-2.0"
] | null | null | null | wsgi.py | javicacheiro/salt-git-synchronizer-proxy | c93de5c0b26afe2b9ec72156497894df7f15d692 | [
"Apache-2.0"
] | null | null | null | wsgi.py | javicacheiro/salt-git-synchronizer-proxy | c93de5c0b26afe2b9ec72156497894df7f15d692 | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python
import logging
import sys
from app import app as application
def setup_flask_logging():
# Log to stdout
handler = logging.StreamHandler(sys.stdout)
# Log to a file
#handler = logging.FileHandler('./application.log')
handler.setLevel(logging.INFO)
handler.setFormatter(logg... | 24.703704 | 64 | 0.721139 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 266 | 0.398801 |
8120c7633f5990d446bca4c8a9b2275a25f1de63 | 202 | py | Python | game/base/enemy.py | PythonixCoders/PyWeek29 | 5c7492466481dec40619272a3da7fa4b9a72c1d6 | [
"MIT"
] | 8 | 2020-03-15T14:58:46.000Z | 2020-04-26T13:44:10.000Z | game/base/enemy.py | flipcoder/Butterfly-Destroyers | 855b1981ea67796e0ce0d82b525a1cb75a9e358b | [
"MIT"
] | null | null | null | game/base/enemy.py | flipcoder/Butterfly-Destroyers | 855b1981ea67796e0ce0d82b525a1cb75a9e358b | [
"MIT"
] | 4 | 2020-03-23T12:38:55.000Z | 2021-12-25T16:32:54.000Z | #!/usr/bin/env python
from game.base.being import Being
class Enemy(Being):
def __init__(self, app, scene, **kwargs):
super().__init__(app, scene, **kwargs)
self.friendly = False
| 20.2 | 46 | 0.648515 | 142 | 0.70297 | 0 | 0 | 0 | 0 | 0 | 0 | 21 | 0.10396 |
8120d71f9f5dd96debf5a9a973a1d872ce6a5597 | 561 | py | Python | main/rates/migrations/0002_auto_20170625_1510.py | Hawk94/coin_tracker | 082909e17308a8dd460225c1b035751d12a27106 | [
"MIT"
] | null | null | null | main/rates/migrations/0002_auto_20170625_1510.py | Hawk94/coin_tracker | 082909e17308a8dd460225c1b035751d12a27106 | [
"MIT"
] | null | null | null | main/rates/migrations/0002_auto_20170625_1510.py | Hawk94/coin_tracker | 082909e17308a8dd460225c1b035751d12a27106 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
# Generated by Django 1.11.1 on 2017-06-25 15:10
from __future__ import unicode_literals
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('rates', '0001_initial'),
]
operations = [
migrations.RenameField(
model... | 21.576923 | 48 | 0.568627 | 411 | 0.73262 | 0 | 0 | 0 | 0 | 0 | 0 | 148 | 0.263815 |
8120ff16ad9dc50c24922ea0574196c48067cace | 2,357 | py | Python | setup.py | dojeda/quetzal-openapi-client | d9d4dc99bb425a3f89dcbb80d5096f554bc42fff | [
"BSD-3-Clause"
] | null | null | null | setup.py | dojeda/quetzal-openapi-client | d9d4dc99bb425a3f89dcbb80d5096f554bc42fff | [
"BSD-3-Clause"
] | 1 | 2019-09-17T09:11:01.000Z | 2019-09-17T09:11:01.000Z | setup.py | dojeda/quetzal-openapi-client | d9d4dc99bb425a3f89dcbb80d5096f554bc42fff | [
"BSD-3-Clause"
] | 1 | 2021-04-28T13:06:38.000Z | 2021-04-28T13:06:38.000Z | # coding: utf-8
"""
Quetzal API
Quetzal: an API to manage data files and their associated metadata.
OpenAPI spec version: 0.5.0
Contact: [email protected]
Generated by: https://openapi-generator.tech
"""
from setuptools import setup, find_packages # noqa: H301
NAME = "quetzal-openapi-client"
V... | 32.287671 | 85 | 0.666101 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1,731 | 0.734408 |
81229a54be34a90af845ce0b0f142321ea5ad691 | 11,115 | py | Python | youtube_dl/extractor/turner.py | jonyg80/youtube-dl | ef3a87fb77891329de1d3dbebfee53bf50645261 | [
"Unlicense"
] | 66,635 | 2019-03-10T21:34:18.000Z | 2022-03-31T23:50:31.000Z | youtube_dl/extractor/turner.py | jonyg80/youtube-dl | ef3a87fb77891329de1d3dbebfee53bf50645261 | [
"Unlicense"
] | 10,936 | 2019-03-10T21:35:47.000Z | 2022-03-31T23:46:52.000Z | youtube_dl/extractor/turner.py | jonyg80/youtube-dl | ef3a87fb77891329de1d3dbebfee53bf50645261 | [
"Unlicense"
] | 15,194 | 2019-03-10T21:09:27.000Z | 2022-03-31T22:13:49.000Z | # coding: utf-8
from __future__ import unicode_literals
import re
from .adobepass import AdobePassIE
from ..compat import compat_str
from ..utils import (
fix_xml_ampersands,
xpath_text,
int_or_none,
determine_ext,
float_or_none,
parse_duration,
xpath_attr,
update_url_query,
Extrac... | 42.586207 | 134 | 0.506163 | 10,744 | 0.966622 | 0 | 0 | 0 | 0 | 0 | 0 | 2,366 | 0.212865 |
81231c1bf7b40bb3a00ed96fce4e7257f1de32c5 | 1,188 | py | Python | ml/sandbox/00-data.py | robk-dev/algo-trading | aa8d76ee739431ab24407fe094e0753c588dc8c6 | [
"MIT"
] | 1 | 2021-03-14T23:52:04.000Z | 2021-03-14T23:52:04.000Z | ml/sandbox/00-data.py | robk-dev/algo-trading | aa8d76ee739431ab24407fe094e0753c588dc8c6 | [
"MIT"
] | null | null | null | ml/sandbox/00-data.py | robk-dev/algo-trading | aa8d76ee739431ab24407fe094e0753c588dc8c6 | [
"MIT"
] | null | null | null | from alpha_vantage.timeseries import TimeSeries
from pprint import pprint
import json
import argparse
def save_dataset(symbol='MSFT', time_window='daily_adj'):
credentials = json.load(open('creds.json', 'r'))
api_key = credentials['av_api_key']
print(symbol, time_window)
ts = TimeSeries(key=api_key, o... | 34.941176 | 125 | 0.683502 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 293 | 0.246633 |
8123847da358e93698586a58b0a106958f59df07 | 12,570 | py | Python | tests/zpill.py | al3pht/cloud-custodian | ce6613d1b716f336384c5e308eee300389e6bf50 | [
"Apache-2.0"
] | 2,415 | 2018-12-04T00:37:58.000Z | 2022-03-31T12:28:56.000Z | tests/zpill.py | al3pht/cloud-custodian | ce6613d1b716f336384c5e308eee300389e6bf50 | [
"Apache-2.0"
] | 3,272 | 2018-12-03T23:58:17.000Z | 2022-03-31T21:15:32.000Z | tests/zpill.py | al3pht/cloud-custodian | ce6613d1b716f336384c5e308eee300389e6bf50 | [
"Apache-2.0"
] | 773 | 2018-12-06T09:43:23.000Z | 2022-03-30T20:44:43.000Z | # Copyright The Cloud Custodian Authors.
# SPDX-License-Identifier: Apache-2.0
import fnmatch
from io import StringIO
import json
import os
import shutil
import zipfile
import re
from datetime import datetime, timedelta, tzinfo
from distutils.util import strtobool
import boto3
import placebo
from botocore.response imp... | 33.699732 | 93 | 0.605091 | 9,544 | 0.759268 | 0 | 0 | 0 | 0 | 0 | 0 | 2,628 | 0.209069 |
8123d51391f52c37336172ab4d3305871857e10f | 16,865 | py | Python | flexget/tests/test_next_series_seasons.py | metaMMA/Flexget | a38986422461d7935ead1e2b4ed4c88bcd0a90f5 | [
"MIT"
] | null | null | null | flexget/tests/test_next_series_seasons.py | metaMMA/Flexget | a38986422461d7935ead1e2b4ed4c88bcd0a90f5 | [
"MIT"
] | 1 | 2017-10-09T23:06:44.000Z | 2017-10-09T23:06:44.000Z | flexget/tests/test_next_series_seasons.py | metaMMA/Flexget | a38986422461d7935ead1e2b4ed4c88bcd0a90f5 | [
"MIT"
] | null | null | null | from __future__ import unicode_literals, division, absolute_import
from builtins import * # noqa pylint: disable=unused-import, redefined-builtin
import pytest
from flexget.entry import Entry
# TODO Add more standard tests
class TestNextSeriesSeasonSeasonsPack(object):
_config = """
templates:
... | 37.645089 | 116 | 0.520308 | 16,636 | 0.986422 | 0 | 0 | 7,698 | 0.456448 | 0 | 0 | 12,524 | 0.742603 |
8123dd148da3e7a93c319e5be784b12da6c27afd | 22,630 | py | Python | pymatgen/analysis/wulff.py | hpatel1567/pymatgen | 8304b25464206c74305214e45935df90bab95500 | [
"MIT"
] | 1 | 2020-02-08T08:20:45.000Z | 2020-02-08T08:20:45.000Z | pymatgen/analysis/wulff.py | hpatel1567/pymatgen | 8304b25464206c74305214e45935df90bab95500 | [
"MIT"
] | null | null | null | pymatgen/analysis/wulff.py | hpatel1567/pymatgen | 8304b25464206c74305214e45935df90bab95500 | [
"MIT"
] | null | null | null | # coding: utf-8
# Copyright (c) Pymatgen Development Team.
# Distributed under the terms of the MIT License.
"""
This module define a WulffShape class to generate the Wulff shape from
a lattice, a list of indices and their corresponding surface energies,
and the total area and volume of the wulff shape,the weighted su... | 35.194401 | 107 | 0.576712 | 20,694 | 0.91445 | 0 | 0 | 3,779 | 0.166991 | 0 | 0 | 8,845 | 0.390853 |
8124c6b98bb9251fb25a500d047b7426b2a988cd | 2,721 | py | Python | ccg/supertagger/any2int.py | stanojevic/ccgtools | d87521d66fcd1b3110fbecc6b78b15a60e5095a3 | [
"MIT"
] | null | null | null | ccg/supertagger/any2int.py | stanojevic/ccgtools | d87521d66fcd1b3110fbecc6b78b15a60e5095a3 | [
"MIT"
] | null | null | null | ccg/supertagger/any2int.py | stanojevic/ccgtools | d87521d66fcd1b3110fbecc6b78b15a60e5095a3 | [
"MIT"
] | null | null | null |
class Any2Int:
def __init__(self, min_count: int, include_UNK: bool, include_PAD: bool):
self.min_count = min_count
self.include_UNK = include_UNK
self.include_PAD = include_PAD
self.frozen = False
self.UNK_i = -1
self.UNK_s = "<UNK>"
self.PAD_i = -2
... | 30.573034 | 118 | 0.529585 | 2,718 | 0.998897 | 0 | 0 | 0 | 0 | 0 | 0 | 113 | 0.041529 |
812522326c06afbf43f1bd6cee31bd8b7b273277 | 6,805 | py | Python | app/sensor.py | sosprz/nettemp | 334b3124263267c931bd7dc5c1bd8eb70614b4ef | [
"MIT"
] | 51 | 2015-01-03T01:37:25.000Z | 2021-11-03T18:07:42.000Z | app/sensor.py | sosprz/nettemp | 334b3124263267c931bd7dc5c1bd8eb70614b4ef | [
"MIT"
] | 18 | 2015-03-06T18:46:51.000Z | 2021-04-02T08:02:01.000Z | app/sensor.py | sosprz/nettemp | 334b3124263267c931bd7dc5c1bd8eb70614b4ef | [
"MIT"
] | 51 | 2015-02-04T18:53:54.000Z | 2022-02-16T20:40:45.000Z | from app import app
from flask import Flask, request, jsonify, g
import sqlite3
import os
import json
from random import randint
from flask_jwt_extended import jwt_required
import datetime
from flask_mysqldb import MySQL
mysql = MySQL()
def get_db(rom):
db = getattr(g, '_database', None)
if db is None:
... | 27.439516 | 246 | 0.603527 | 0 | 0 | 0 | 0 | 396 | 0.058193 | 0 | 0 | 2,119 | 0.311389 |