hexsha stringlengths 40 40 | size int64 1 1.03M | ext stringclasses 10
values | lang stringclasses 1
value | max_stars_repo_path stringlengths 3 239 | max_stars_repo_name stringlengths 5 130 | 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 239 | max_issues_repo_name stringlengths 5 130 | 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 239 | max_forks_repo_name stringlengths 5 130 | 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 1 1.03M | avg_line_length float64 1 958k | max_line_length int64 1 1.03M | alphanum_fraction float64 0 1 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
7947ccf32fb9b43a6a088063d161ba3ceb96ad8d | 5,481 | py | Python | search/query.py | FmasterofU/OISISI_HTMLSE | fe893dcae93cec93163d04242c08adc8cc7ecbe8 | [
"MIT"
] | null | null | null | search/query.py | FmasterofU/OISISI_HTMLSE | fe893dcae93cec93163d04242c08adc8cc7ecbe8 | [
"MIT"
] | null | null | null | search/query.py | FmasterofU/OISISI_HTMLSE | fe893dcae93cec93163d04242c08adc8cc7ecbe8 | [
"MIT"
] | null | null | null | from structures.set import Set
def validate_query(query: str):
"""
Checking validation for normal(not advanced) search
:param query: input query for normal(not advanced) search
:return: True if query is valid
"""
query = get_correct_query(query)
if query == 'and' or query == 'not' or quer... | 37.033784 | 118 | 0.509031 |
7947cd61409b65c09b5c3b08469a198ca232fe2d | 22,692 | py | Python | vol2/vol2-python-examples/examples/capstone_titanic/titanic_milestone1.py | Sun-Joong/aifh | 1b6363d26f54b77348020ce88ced0670568ed736 | [
"Apache-2.0"
] | 777 | 2015-01-17T22:48:26.000Z | 2022-03-31T01:10:07.000Z | vol2/vol2-python-examples/examples/capstone_titanic/titanic_milestone1.py | Sun-Joong/aifh | 1b6363d26f54b77348020ce88ced0670568ed736 | [
"Apache-2.0"
] | 17 | 2015-01-02T14:41:24.000Z | 2017-09-02T02:57:09.000Z | vol2/vol2-python-examples/examples/capstone_titanic/titanic_milestone1.py | Sun-Joong/aifh | 1b6363d26f54b77348020ce88ced0670568ed736 | [
"Apache-2.0"
] | 445 | 2015-01-26T17:01:49.000Z | 2022-03-24T07:16:58.000Z | #!/usr/bin/env python
"""
Artificial Intelligence for Humans
Volume 2: Nature-Inspired Algorithms
Python Version
http://www.aifh.org
http://www.jeffheaton.com
Code repository:
https://github.com/jeffheaton/aifh
Copyright 2014 by Jeff Heaton
Licensed under the Apache License, Versi... | 37.139116 | 142 | 0.545082 |
7947cd7d7fbf4b1e274716ab8443429cd36ae33f | 14,634 | py | Python | flask/lib/python2.7/site-packages/sqlalchemy/orm/base.py | ccellis/WHACK2016 | 5ef4ddadaa60ef8ca07702a0a82df8a9776b9741 | [
"BSD-3-Clause"
] | 1 | 2018-04-09T07:37:54.000Z | 2018-04-09T07:37:54.000Z | flask/lib/python2.7/site-packages/sqlalchemy/orm/base.py | ccellis/WHACK2016 | 5ef4ddadaa60ef8ca07702a0a82df8a9776b9741 | [
"BSD-3-Clause"
] | 1 | 2016-05-25T15:38:50.000Z | 2016-05-25T15:38:50.000Z | flask/lib/python2.7/site-packages/sqlalchemy/orm/base.py | ccellis/WHACK2016 | 5ef4ddadaa60ef8ca07702a0a82df8a9776b9741 | [
"BSD-3-Clause"
] | null | null | null | # orm/base.py
# Copyright (C) 2005-2016 the SQLAlchemy authors and contributors
# <see AUTHORS file>
#
# This module is part of SQLAlchemy and is released under
# the MIT License: http://www.opensource.org/licenses/mit-license.php
"""Constants and rudimental functions used throughout the ORM.
"""
from .. import util... | 27.049908 | 79 | 0.681768 |
7947cdd41e5180be90c1ac87e55af355f5a99242 | 7,976 | py | Python | IMU/VTK-6.2.0/ThirdParty/Twisted/twisted/names/common.py | timkrentz/SunTracker | 9a189cc38f45e5fbc4e4c700d7295a871d022795 | [
"MIT"
] | 4 | 2016-03-30T14:31:52.000Z | 2019-02-02T05:01:32.000Z | IMU/VTK-6.2.0/ThirdParty/Twisted/twisted/names/common.py | timkrentz/SunTracker | 9a189cc38f45e5fbc4e4c700d7295a871d022795 | [
"MIT"
] | 1 | 2020-03-06T04:49:42.000Z | 2020-03-06T04:49:42.000Z | IMU/VTK-6.2.0/ThirdParty/Twisted/twisted/names/common.py | timkrentz/SunTracker | 9a189cc38f45e5fbc4e4c700d7295a871d022795 | [
"MIT"
] | 2 | 2019-08-30T23:36:13.000Z | 2019-11-08T16:52:01.000Z | # -*- test-case-name: twisted.names.test -*-
# Copyright (c) Twisted Matrix Laboratories.
# See LICENSE for details.
"""
Base functionality useful to various parts of Twisted Names.
"""
from __future__ import division, absolute_import
import socket
from zope.interface import implementer
from twisted.... | 31.776892 | 79 | 0.62663 |
7947ce474893a4f869777763e46bca23b70bacea | 18,142 | py | Python | src/pytezos/cli/cli.py | konchunas/pytezos | 65576d18bdf1956fae8ea21241b6c43a38921b83 | [
"MIT"
] | null | null | null | src/pytezos/cli/cli.py | konchunas/pytezos | 65576d18bdf1956fae8ea21241b6c43a38921b83 | [
"MIT"
] | null | null | null | src/pytezos/cli/cli.py | konchunas/pytezos | 65576d18bdf1956fae8ea21241b6c43a38921b83 | [
"MIT"
] | null | null | null | import io
import sys
import tarfile
import time
from glob import glob
from os.path import abspath, dirname, exists, join, split
from pprint import pformat
from typing import List, Optional
import click
import docker # type: ignore
from pytezos import ContractInterface, __version__, pytezos
from pytezos.cli.github im... | 36.949084 | 128 | 0.634439 |
7947ceb66d8381b8c8164586bcef95fe302b7bdb | 7,633 | py | Python | pepe/analysis/ForceBalance.py | Jfeatherstone/pepe | 4d28cab830ff2a94d3cfc06c680bde05d92b2cdb | [
"MIT"
] | null | null | null | pepe/analysis/ForceBalance.py | Jfeatherstone/pepe | 4d28cab830ff2a94d3cfc06c680bde05d92b2cdb | [
"MIT"
] | null | null | null | pepe/analysis/ForceBalance.py | Jfeatherstone/pepe | 4d28cab830ff2a94d3cfc06c680bde05d92b2cdb | [
"MIT"
] | null | null | null | """
Methods to gauge how well force balance is satisfied for an ensemble,
and to convert between polar and cartesian systems.
"""
import numpy as np
import numba
def polarToCartesian(force, alpha, beta, collapse=True):
"""
Convert a set of forces defined in polar coordinates (f, a, b),
to cartesian coord... | 34.538462 | 177 | 0.639198 |
7947cf5e1892b79ae46d07d2a0126e6c1b20dbd8 | 4,592 | py | Python | pretrain_AE.py | bigaidream-projects/citylearn-2020-pikapika | 8c9389eb4b4e979faf269b8c0ce87b499af97ac1 | [
"Apache-2.0"
] | 3 | 2021-12-20T03:40:55.000Z | 2022-02-02T04:26:33.000Z | pretrain_AE.py | bigaidream-projects/citylearn-2020-pikapika | 8c9389eb4b4e979faf269b8c0ce87b499af97ac1 | [
"Apache-2.0"
] | null | null | null | pretrain_AE.py | bigaidream-projects/citylearn-2020-pikapika | 8c9389eb4b4e979faf269b8c0ce87b499af97ac1 | [
"Apache-2.0"
] | 4 | 2022-02-11T20:30:51.000Z | 2022-02-27T01:17:34.000Z | from torch.optim import Adam
from torch.nn.functional import l1_loss
from torch.distributions import kl_divergence, Normal
from pathlib import Path
import numpy as np
import torch
from torch.utils.tensorboard import SummaryWriter
from citylearn import CityLearn
from utils.standardization import normalize_AE_state_with... | 32.338028 | 113 | 0.690984 |
7947d033e8d393f86da4736436a387d28b8a58ad | 7,799 | py | Python | mmdet/core/bbox/bbox_target.py | arthur801031/3d-multi-resolution-rcnn | 8e5454a72f8daa174bf3eabfa5964152f04ab287 | [
"Apache-2.0"
] | 16 | 2021-03-02T07:41:01.000Z | 2022-03-14T08:55:45.000Z | mmdet/core/bbox/bbox_target.py | arthur801031/3d-multi-resolution-rcnn | 8e5454a72f8daa174bf3eabfa5964152f04ab287 | [
"Apache-2.0"
] | 2 | 2022-01-06T20:54:13.000Z | 2022-02-24T03:50:51.000Z | mmdet/core/bbox/bbox_target.py | arthur801031/3d-multi-resolution-rcnn | 8e5454a72f8daa174bf3eabfa5964152f04ab287 | [
"Apache-2.0"
] | 2 | 2021-05-26T19:23:35.000Z | 2022-01-06T20:30:24.000Z | import torch
from .transforms import bbox2delta, bbox2delta3d
from ..utils import multi_apply
def bbox_target(pos_bboxes_list,
neg_bboxes_list,
pos_gt_bboxes_list,
pos_gt_labels_list,
cfg,
reg_classes=1,
target_means=[.0,... | 39.790816 | 95 | 0.594307 |
7947d0b73cbc54028f11cf6382ee720dc2d6bf13 | 6,636 | py | Python | Lib/site-packages/qt_py_convert/_modules/from_imports/process.py | fochoao/cpython | 3dc84b260e5bced65ebc2c45c40c8fa65f9b5aa9 | [
"bzip2-1.0.6",
"0BSD"
] | 61 | 2018-04-17T18:09:32.000Z | 2022-03-04T03:33:50.000Z | Lib/site-packages/qt_py_convert/_modules/from_imports/process.py | fochoao/cpython | 3dc84b260e5bced65ebc2c45c40c8fa65f9b5aa9 | [
"bzip2-1.0.6",
"0BSD"
] | 20 | 2021-05-03T18:02:23.000Z | 2022-03-12T12:01:04.000Z | Lib/site-packages/qt_py_convert/_modules/from_imports/process.py | fochoao/cpython | 3dc84b260e5bced65ebc2c45c40c8fa65f9b5aa9 | [
"bzip2-1.0.6",
"0BSD"
] | 5 | 2018-04-18T07:36:21.000Z | 2019-07-01T01:41:55.000Z | # Copyright 2018 Digital Domain 3.0
#
# Licensed under the Apache License, Version 2.0 (the "Apache License")
# with the following modification; you may not use this file except in
# compliance with the Apache License and the following modification to it:
# Section 6. Trademarks. is deleted and replaced with:
#
# 6. Tr... | 37.280899 | 81 | 0.639994 |
7947d0c383359141ce9cb03d6cd951c21f2fa75f | 10,025 | py | Python | src/transformers/tokenization_t5_fast.py | Liang813/transformers | 08f534d2da47875a4b7eb1c125cfa7f0f3b79642 | [
"Apache-2.0"
] | null | null | null | src/transformers/tokenization_t5_fast.py | Liang813/transformers | 08f534d2da47875a4b7eb1c125cfa7f0f3b79642 | [
"Apache-2.0"
] | null | null | null | src/transformers/tokenization_t5_fast.py | Liang813/transformers | 08f534d2da47875a4b7eb1c125cfa7f0f3b79642 | [
"Apache-2.0"
] | null | null | null | # coding=utf-8
# Copyright 2018 T5 Authors and HuggingFace Inc. team.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by... | 42.299578 | 164 | 0.639302 |
7947d0e06d1b2056e68ba1afac0bed9598f27f4e | 194 | py | Python | manage.py | atten/mongo-log-watcher | 7269356acc30c44ae6ed857d491758ef4865f8a4 | [
"MIT"
] | null | null | null | manage.py | atten/mongo-log-watcher | 7269356acc30c44ae6ed857d491758ef4865f8a4 | [
"MIT"
] | null | null | null | manage.py | atten/mongo-log-watcher | 7269356acc30c44ae6ed857d491758ef4865f8a4 | [
"MIT"
] | null | null | null | from app import app, init_app, manager
@manager.command
def runserver():
app.run(host='localhost', port=8211)
if __name__ == '__main__':
init_app('local_settings')
manager.run()
| 16.166667 | 40 | 0.690722 |
7947d1981ddc9d96cd3518cb130a97c890c1b721 | 1,113 | py | Python | module3/modules04.py | zubrik13/stepic_python | 72def2a2c2d45d8ff47a94a6ba6bc4936459046d | [
"MIT"
] | null | null | null | module3/modules04.py | zubrik13/stepic_python | 72def2a2c2d45d8ff47a94a6ba6bc4936459046d | [
"MIT"
] | null | null | null | module3/modules04.py | zubrik13/stepic_python | 72def2a2c2d45d8ff47a94a6ba6bc4936459046d | [
"MIT"
] | null | null | null | """
Имеется набор файлов, каждый из которых, кроме последнего, содержит имя следующего файла.
Первое слово в тексте последнего файла: "We".
Скачайте предложенный файл. В нём содержится ссылка на первый файл из этого набора.
Все файлы располагаются в каталоге по адресу:
https://stepic.org/media/attachments/course67/3.6.... | 24.733333 | 89 | 0.683738 |
7947d19c532dad134debf70d773a709f348ef1bd | 1,648 | py | Python | exercise_code/data/base_dataset.py | Rylie-W/I2DL_21WS | d0c6517695b71a491f7f88ed1031366de209c4a0 | [
"Apache-2.0"
] | null | null | null | exercise_code/data/base_dataset.py | Rylie-W/I2DL_21WS | d0c6517695b71a491f7f88ed1031366de209c4a0 | [
"Apache-2.0"
] | null | null | null | exercise_code/data/base_dataset.py | Rylie-W/I2DL_21WS | d0c6517695b71a491f7f88ed1031366de209c4a0 | [
"Apache-2.0"
] | null | null | null | """Dataset Base Class"""
from abc import ABC, abstractmethod
from .download_utils import download_dataset
class Dataset(ABC):
"""
Abstract Dataset Base Class
All subclasses must define __getitem__() and __len__()
"""
def __init__(self, root, download_url=None, force_download=False, verbose=False... | 29.428571 | 89 | 0.617112 |
7947d19ce0ccb5dc7be7a4370b51e1c11ff969ed | 1,269 | py | Python | addic7ed/logger.py | spfeifer222/addic7ed | f606d72d88eb131a4252dd863fbee5c36ce059b7 | [
"MIT"
] | 13 | 2015-12-22T14:23:23.000Z | 2018-11-18T21:01:29.000Z | addic7ed/logger.py | spfeifer222/addic7ed | f606d72d88eb131a4252dd863fbee5c36ce059b7 | [
"MIT"
] | 5 | 2016-01-23T06:34:27.000Z | 2017-03-20T09:48:13.000Z | addic7ed/logger.py | spfeifer222/addic7ed | f606d72d88eb131a4252dd863fbee5c36ce059b7 | [
"MIT"
] | 4 | 2016-02-15T14:02:46.000Z | 2017-03-17T08:28:13.000Z | from os import makedirs
from os.path import expanduser, exists
from logging import getLogger, Formatter, StreamHandler, DEBUG, WARN
from logging.handlers import RotatingFileHandler
from termcolor import colored
LOG_COLORS = {
"DEBUG": "grey",
"INFO": "cyan",
"WARNING": "yellow",
"ERROR": "magenta",
... | 26.4375 | 70 | 0.634358 |
7947d1f977b1d1e3f29ceb0a5dae7b9d6701b2ec | 1,107 | py | Python | test/publish_async_stddev.py | Kettenhoax/quickplot | e6624dbcefef5382b2727c93286699193ae60b1c | [
"Apache-2.0"
] | null | null | null | test/publish_async_stddev.py | Kettenhoax/quickplot | e6624dbcefef5382b2727c93286699193ae60b1c | [
"Apache-2.0"
] | null | null | null | test/publish_async_stddev.py | Kettenhoax/quickplot | e6624dbcefef5382b2727c93286699193ae60b1c | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/python3
import sys
import rclpy
import math
import random
from rclpy.node import Node
from rclpy.time import CONVERSION_CONSTANT, Duration
from geometry_msgs.msg import Vector3Stamped
class PublishAsyncStddev(Node):
def __init__(self):
super().__init__('publish_async_stddev')
self._pub... | 27 | 79 | 0.676603 |
7947d2e788b5bc6f296b37452dd2b5276ff23200 | 1,699 | py | Python | tests/test_list_notation.py | lbolanos/aws-sfn-builder | 6323963786388990ba2ffc1349a9b488bee338a7 | [
"MIT"
] | 4 | 2018-10-14T23:15:57.000Z | 2020-11-03T04:05:14.000Z | tests/test_list_notation.py | lbolanos/aws-sfn-builder | 6323963786388990ba2ffc1349a9b488bee338a7 | [
"MIT"
] | null | null | null | tests/test_list_notation.py | lbolanos/aws-sfn-builder | 6323963786388990ba2ffc1349a9b488bee338a7 | [
"MIT"
] | 2 | 2020-11-03T04:06:26.000Z | 2021-05-12T00:37:53.000Z | from aws_sfn_builder import Machine, Parallel, State, States
def test_empty_machine():
m = Machine.parse([])
assert m.start_at is None
assert not m.states
assert m.dry_run() == []
def test_simple_sequence():
s = Machine.parse(["a", "b"])
assert len(s.states) == 2
assert s.start_at == "a"... | 21.506329 | 70 | 0.496174 |
7947d2fb901ee78b07c7746fba2b505013cc6e13 | 5,533 | py | Python | LogicPy/shift_registers.py | Sunillad08/Digital_logic | 18fb08b5223f57ec89ca24d8ed62a7891e657c1c | [
"MIT"
] | 6 | 2021-05-04T11:35:46.000Z | 2022-03-11T18:41:33.000Z | LogicPy/shift_registers.py | Sunillad08/Digital_logic | 18fb08b5223f57ec89ca24d8ed62a7891e657c1c | [
"MIT"
] | 9 | 2021-05-05T15:52:44.000Z | 2021-06-13T14:53:14.000Z | LogicPy/shift_registers.py | Sunillad08/Digital_logic | 18fb08b5223f57ec89ca24d8ed62a7891e657c1c | [
"MIT"
] | 1 | 2021-05-04T18:10:37.000Z | 2021-05-04T18:10:37.000Z | '''
shift registers
type:class\n
name-format: shift_register_[name]\n
SIPO\n
PISO\n
SISO\n
PIPO
'''
'''SIPO'''
class shift_register_SIPO():
def __init__(self,level,inputno = None):
self.level = level
self.inputno = inputno
def sr_set(self,inputno):
#list inpu... | 29.430851 | 97 | 0.50009 |
7947d507a8683e1a58ed9dea8fd0fdab2cff341d | 2,855 | py | Python | test/unit/test_utils_process.py | persanix-llc/endrpi-server | 0bc69bfde977e558e7097175d1207be4da388065 | [
"Apache-2.0"
] | 2 | 2021-04-30T18:12:14.000Z | 2021-10-30T02:53:48.000Z | test/unit/test_utils_process.py | persanix-llc/endrpi-server | 0bc69bfde977e558e7097175d1207be4da388065 | [
"Apache-2.0"
] | 1 | 2021-08-29T16:18:15.000Z | 2021-08-29T16:18:15.000Z | test/unit/test_utils_process.py | persanix-llc/endrpi-server | 0bc69bfde977e558e7097175d1207be4da388065 | [
"Apache-2.0"
] | null | null | null | # Copyright (c) 2020 - 2021 Persanix LLC. 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 ... | 36.602564 | 78 | 0.695972 |
7947d6bdd3ab72cc5c532d7daf87d3634956dc50 | 546 | py | Python | build/usb_cam/catkin_generated/pkg.installspace.context.pc.py | madalynlmillen/MadalynMillenCapstone | a1585ba419d4ab4854908b4ba88e4c8ca330b5cd | [
"MIT",
"Unlicense"
] | null | null | null | build/usb_cam/catkin_generated/pkg.installspace.context.pc.py | madalynlmillen/MadalynMillenCapstone | a1585ba419d4ab4854908b4ba88e4c8ca330b5cd | [
"MIT",
"Unlicense"
] | null | null | null | build/usb_cam/catkin_generated/pkg.installspace.context.pc.py | madalynlmillen/MadalynMillenCapstone | a1585ba419d4ab4854908b4ba88e4c8ca330b5cd | [
"MIT",
"Unlicense"
] | null | null | null | # generated from catkin/cmake/template/pkg.context.pc.in
CATKIN_PACKAGE_PREFIX = ""
PROJECT_PKG_CONFIG_INCLUDE_DIRS = "/home/kinova/MillenCapstone/MadalynMillenCapstone/install/include".split(';') if "/home/kinova/MillenCapstone/MadalynMillenCapstone/install/include" != "" else []
PROJECT_CATKIN_DEPENDS = "".replace(';... | 60.666667 | 197 | 0.771062 |
7947d6f31a003375bb2110cc75c25710b9b5ee80 | 5,088 | py | Python | capreolus/reranker/ptparade.py | nimasadri11/capreolus | 27b081ec1a37d2af6afa6b61eb1cb7cc4ec9db1c | [
"Apache-2.0"
] | 77 | 2019-12-01T20:48:14.000Z | 2022-03-11T14:45:54.000Z | capreolus/reranker/ptparade.py | nimasadri11/capreolus | 27b081ec1a37d2af6afa6b61eb1cb7cc4ec9db1c | [
"Apache-2.0"
] | 106 | 2020-01-30T18:01:16.000Z | 2022-02-11T18:05:16.000Z | capreolus/reranker/ptparade.py | nimasadri11/capreolus | 27b081ec1a37d2af6afa6b61eb1cb7cc4ec9db1c | [
"Apache-2.0"
] | 30 | 2020-01-31T08:50:40.000Z | 2022-01-25T05:51:11.000Z | import torch
from torch import nn
from transformers import BertModel, ElectraModel
from transformers.models.bert.modeling_bert import BertLayer
from capreolus import ConfigOption, Dependency
from capreolus.reranker import Reranker
class PTParade_Class(nn.Module):
def __init__(self, extractor, config, *args, **kw... | 43.487179 | 150 | 0.666863 |
7947d7e87955580e6d48bd07c5feb64785c360ee | 565 | py | Python | test_example.py | IvankaK/Testing | 2ce0ee645b2172b37f3c8c8ce4461b60e2180321 | [
"Apache-2.0"
] | null | null | null | test_example.py | IvankaK/Testing | 2ce0ee645b2172b37f3c8c8ce4461b60e2180321 | [
"Apache-2.0"
] | null | null | null | test_example.py | IvankaK/Testing | 2ce0ee645b2172b37f3c8c8ce4461b60e2180321 | [
"Apache-2.0"
] | 1 | 2021-12-08T17:10:05.000Z | 2021-12-08T17:10:05.000Z | import pytest
from selenium import webdriver
from selenium.webdriver.support.wait import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
@pytest.fixture
def driver(request):
wd = webdriver.Chrome()
print(wd.capabilities)
request.addfinalizer(wd.quit)
return wd
def test... | 29.736842 | 78 | 0.757522 |
7947d92b271bd5c2c437556c4ad924618395b6c2 | 2,765 | py | Python | rlscope/parser/overlap_result.py | UofT-EcoSystem/rlscope | cdd9bbdc2a3a832be24f20105b8c9fe28149cb63 | [
"Apache-2.0"
] | 35 | 2021-01-26T22:34:17.000Z | 2022-03-02T01:25:11.000Z | rlscope/parser/overlap_result.py | UofT-EcoSystem/rlscope | cdd9bbdc2a3a832be24f20105b8c9fe28149cb63 | [
"Apache-2.0"
] | 1 | 2022-03-15T01:40:03.000Z | 2022-03-15T01:40:03.000Z | rlscope/parser/overlap_result.py | UofT-EcoSystem/rlscope | cdd9bbdc2a3a832be24f20105b8c9fe28149cb63 | [
"Apache-2.0"
] | 1 | 2021-03-17T08:49:07.000Z | 2021-03-17T08:49:07.000Z | """
Reading overlap results from ``rls-analyze``.
"""
from rlscope.parser.common import *
class CategoryKey:
def __init__(self):
self.procs = frozenset()
self.ops = frozenset()
self.non_ops = frozenset()
@staticmethod
def from_js(obj):
self = CategoryKey()
assert ob... | 30.722222 | 130 | 0.588065 |
7947daffed4d4782a8432d2be0e58e95c3f9e42f | 17,407 | py | Python | sfepy/discrete/common/dof_info.py | antonykamp/sfepy | 8213d3c8cc2825602b41dc65eb543b575856ca8c | [
"BSD-3-Clause"
] | null | null | null | sfepy/discrete/common/dof_info.py | antonykamp/sfepy | 8213d3c8cc2825602b41dc65eb543b575856ca8c | [
"BSD-3-Clause"
] | null | null | null | sfepy/discrete/common/dof_info.py | antonykamp/sfepy | 8213d3c8cc2825602b41dc65eb543b575856ca8c | [
"BSD-3-Clause"
] | null | null | null | """
Classes holding information on global DOFs and mapping of all DOFs -
equations (active DOFs).
Helper functions for the equation mapping.
"""
import numpy as nm
import scipy.sparse as sp
from sfepy.base.base import assert_, Struct, basestr
from sfepy.discrete.functions import Function
from sfepy.discrete.condition... | 31.70674 | 79 | 0.5295 |
7947dbf338ac521eca55c8670d4c75ada14c51be | 2,263 | py | Python | GUIScripts/Hotel Management System/Code/recipt.py | Gaurav1401/Awesome_Python_Scripts | e98044cc42a975e81d880b27546fadcdead17a42 | [
"MIT"
] | 2 | 2021-07-12T10:12:56.000Z | 2021-07-12T10:13:10.000Z | GUIScripts/Hotel Management System/Code/recipt.py | Gaurav1401/Awesome_Python_Scripts | e98044cc42a975e81d880b27546fadcdead17a42 | [
"MIT"
] | null | null | null | GUIScripts/Hotel Management System/Code/recipt.py | Gaurav1401/Awesome_Python_Scripts | e98044cc42a975e81d880b27546fadcdead17a42 | [
"MIT"
] | 2 | 2021-10-03T16:22:08.000Z | 2021-10-03T17:35:14.000Z | #! /usr/bin/env python
# -*- coding: utf-8 -*-
#
# GUI module generated by PAGE version 4.17
# In conjunction with Tcl version 8.6
# Oct 07, 2018 01:57:36 PM IST platform: Windows NT
from __main__ import *
import sys
try:
from Tkinter import *
except ImportError:
from tkinter import *
try:
... | 24.074468 | 68 | 0.551038 |
7947dc0a4e71a3106d21b1d4e16e816652b8e7e7 | 1,321 | py | Python | line_follower_skeleton.py | MartinCoderDojo/bit-bot-line-follower | 72e5b557a70f66c2790d05ae5fd3ccc1634b950f | [
"MIT"
] | null | null | null | line_follower_skeleton.py | MartinCoderDojo/bit-bot-line-follower | 72e5b557a70f66c2790d05ae5fd3ccc1634b950f | [
"MIT"
] | null | null | null | line_follower_skeleton.py | MartinCoderDojo/bit-bot-line-follower | 72e5b557a70f66c2790d05ae5fd3ccc1634b950f | [
"MIT"
] | null | null | null | from microbit import *
leftLine = pin11
rightLine = pin5
# pin 0 = left speed
# pin 8 = left direction
# pin 1 = right speed
# pin 12 = right direction
# Direction = 0 for forward, 1 for backward
def moveRobot(pin0Val, pin8Val, pin1Val, pin12Val):
pin0.write_analog(pin0Val)
pin8.write_digital(pin8Val)
p... | 20.640625 | 63 | 0.637396 |
7947dc776d4a209ea6dcc970e5d48c72006dc88a | 184 | py | Python | webApi/books_api/book/urls.py | FreeN1ckname/web_api | 50b6ffc03f918e25d36ff11caa1cf5d83628646b | [
"MIT"
] | null | null | null | webApi/books_api/book/urls.py | FreeN1ckname/web_api | 50b6ffc03f918e25d36ff11caa1cf5d83628646b | [
"MIT"
] | null | null | null | webApi/books_api/book/urls.py | FreeN1ckname/web_api | 50b6ffc03f918e25d36ff11caa1cf5d83628646b | [
"MIT"
] | null | null | null | from django.urls import path
from .views import BookView
app_name = "books"
urlpatterns = [
path('books/', BookView.as_view()),
path('books/<int:pk>', BookView.as_view())
]
| 16.727273 | 46 | 0.673913 |
7947dcd96d795289937fadd931a974395bcc5d6d | 1,938 | py | Python | apps/Training/models.py | MarkyMark1000/AWS---PYTHON---COPY---MYWEBSITE | e6a6a76376d122b224d4744314e687f660aad770 | [
"MIT"
] | 1 | 2022-01-30T07:30:06.000Z | 2022-01-30T07:30:06.000Z | apps/Training/models.py | MarkyMark1000/AWS---PYTHON---COPY---MYWEBSITE | e6a6a76376d122b224d4744314e687f660aad770 | [
"MIT"
] | 5 | 2020-03-12T19:22:55.000Z | 2022-02-10T14:19:21.000Z | apps/Training/models.py | MarkyMark1000/AWS---PYTHON---COPY---MYWEBSITE | e6a6a76376d122b224d4744314e687f660aad770 | [
"MIT"
] | null | null | null | from __future__ import unicode_literals
from django.db import models
import datetime
from django.urls import reverse
# Create your models here.
class TrainingGroup(models.Model):
title = models.CharField(max_length=15)
updated_at = models.DateTimeField(auto_now=True)
def __str__(self):
return se... | 34.607143 | 79 | 0.674407 |
7947dde487cadbe8b98283a35268c10a35ca2c24 | 12,501 | py | Python | akshare/stock_feature/stock_board_concept_ths.py | euyuil/akshare | 5205796b53a29259831c11413004e405f8a16368 | [
"MIT"
] | null | null | null | akshare/stock_feature/stock_board_concept_ths.py | euyuil/akshare | 5205796b53a29259831c11413004e405f8a16368 | [
"MIT"
] | null | null | null | akshare/stock_feature/stock_board_concept_ths.py | euyuil/akshare | 5205796b53a29259831c11413004e405f8a16368 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
# -*- coding:utf-8 -*-
"""
Date: 2021/10/30 17:10
Desc: 同花顺-板块-概念板块
http://q.10jqka.com.cn/gn/detail/code/301558/
"""
import os
from datetime import datetime
import pandas as pd
import requests
from bs4 import BeautifulSoup
from py_mini_racer import py_mini_racer
from tqdm import tqdm
from aksha... | 37.094955 | 143 | 0.62179 |
7947de5ed2b12060285f429af18853ad1924864d | 5,025 | py | Python | bin/ADFRsuite/CCSBpckgs/MolKit2/PDBresidueNames.py | AngelRuizMoreno/Jupyter_Dock_devel | 6d23bc174d5294d1e9909a0a1f9da0713042339e | [
"MIT"
] | null | null | null | bin/ADFRsuite/CCSBpckgs/MolKit2/PDBresidueNames.py | AngelRuizMoreno/Jupyter_Dock_devel | 6d23bc174d5294d1e9909a0a1f9da0713042339e | [
"MIT"
] | null | null | null | bin/ADFRsuite/CCSBpckgs/MolKit2/PDBresidueNames.py | AngelRuizMoreno/Jupyter_Dock_devel | 6d23bc174d5294d1e9909a0a1f9da0713042339e | [
"MIT"
] | 1 | 2021-11-04T21:48:14.000Z | 2021-11-04T21:48:14.000Z | ################################################################################
##
## 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 of the License, or (at your op... | 20.1 | 106 | 0.363184 |
7947de8a85f74c935a72f7f328d86563af6e55cb | 65,087 | py | Python | tensorflow_model_analysis/api/model_eval_lib.py | rtg0795/model-analysis | 0f73989a2dfe1e56548f1ccd0001d98846f89e05 | [
"Apache-2.0"
] | null | null | null | tensorflow_model_analysis/api/model_eval_lib.py | rtg0795/model-analysis | 0f73989a2dfe1e56548f1ccd0001d98846f89e05 | [
"Apache-2.0"
] | null | null | null | tensorflow_model_analysis/api/model_eval_lib.py | rtg0795/model-analysis | 0f73989a2dfe1e56548f1ccd0001d98846f89e05 | [
"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, ... | 42.876812 | 119 | 0.732788 |
7947e1139a93608b2a4f3812af5f89bae8eb8579 | 40,278 | py | Python | utils.py | jzheng84/singleshotpose | 5d23bcd348dce8c0eeb6c90d1cdc1a0a4d4c32cb | [
"MIT"
] | null | null | null | utils.py | jzheng84/singleshotpose | 5d23bcd348dce8c0eeb6c90d1cdc1a0a4d4c32cb | [
"MIT"
] | null | null | null | utils.py | jzheng84/singleshotpose | 5d23bcd348dce8c0eeb6c90d1cdc1a0a4d4c32cb | [
"MIT"
] | null | null | null | import sys
import os
import time
import math
import torch
import numpy as np
from PIL import Image, ImageDraw, ImageFont
from torch.autograd import Variable
import torch.nn.functional as F
import cv2
from scipy import spatial
import struct
import imghdr
def get_all_files(directory):
files = []
for f in os.... | 37.748828 | 210 | 0.531407 |
7947e1e1043167789147fc53296da23eb207a314 | 1,481 | py | Python | Required Codes/Python Scripts/scikit-feature-master/skfeature/example/test_FCBF.py | shuvoprime/A-Supervised-Machine-Learning-Approach-to-Predict-Vulnerability-to-Drug-Addiction | 8bd08557f134b5347b23fd5fb4af935d0d28d6b9 | [
"MIT"
] | null | null | null | Required Codes/Python Scripts/scikit-feature-master/skfeature/example/test_FCBF.py | shuvoprime/A-Supervised-Machine-Learning-Approach-to-Predict-Vulnerability-to-Drug-Addiction | 8bd08557f134b5347b23fd5fb4af935d0d28d6b9 | [
"MIT"
] | null | null | null | Required Codes/Python Scripts/scikit-feature-master/skfeature/example/test_FCBF.py | shuvoprime/A-Supervised-Machine-Learning-Approach-to-Predict-Vulnerability-to-Drug-Addiction | 8bd08557f134b5347b23fd5fb4af935d0d28d6b9 | [
"MIT"
] | null | null | null | import scipy.io
from sklearn.metrics import accuracy_score
from sklearn import cross_validation
from sklearn import svm
from skfeature.function.information_theoretical_based import FCBF
def main():
# load data
mat = scipy.io.loadmat('../data/colon.mat')
X = mat['X'] # data
X = X.astype(float)
y... | 31.510638 | 89 | 0.667792 |
7947e2e2cb8981ffc39146ed7a0893bfac8304b7 | 5,022 | py | Python | src/icemac/ab/calendar/calendar.py | icemac/icemac.ab.calendar | c0cdedd3a8fdd39520156c2ea7cf83aca742e3d9 | [
"BSD-2-Clause"
] | 1 | 2020-04-21T19:34:04.000Z | 2020-04-21T19:34:04.000Z | src/icemac/ab/calendar/calendar.py | icemac/icemac.ab.calendar | c0cdedd3a8fdd39520156c2ea7cf83aca742e3d9 | [
"BSD-2-Clause"
] | null | null | null | src/icemac/ab/calendar/calendar.py | icemac/icemac.ab.calendar | c0cdedd3a8fdd39520156c2ea7cf83aca742e3d9 | [
"BSD-2-Clause"
] | null | null | null | # -*- coding: utf-8 -*-
from .interfaces import DATE_INDEX
from .interfaces import IEvent
from .interfaces import IRecurringEvent
from datetime import datetime, time
from icemac.addressbook.interfaces import ISchemaName
import gocept.reference
import grokcore.annotation as grok
import icemac.ab.calendar.interfaces
impo... | 41.163934 | 77 | 0.665671 |
7947e35a0811b35e7438682407f8f6cfd40002c5 | 47 | py | Python | code/exampleStrats/alwaysCooperate.py | robo-monk/PrisonersDilemmaTournament | 84f323f46233d3c6b4ce4380e04e981520912423 | [
"MIT"
] | null | null | null | code/exampleStrats/alwaysCooperate.py | robo-monk/PrisonersDilemmaTournament | 84f323f46233d3c6b4ce4380e04e981520912423 | [
"MIT"
] | null | null | null | code/exampleStrats/alwaysCooperate.py | robo-monk/PrisonersDilemmaTournament | 84f323f46233d3c6b4ce4380e04e981520912423 | [
"MIT"
] | null | null | null | def strategy(history, memory):
return 1, None
| 15.666667 | 30 | 0.744681 |
7947e404e4ee514e4c2feee5b184f0770d8a8cab | 1,319 | py | Python | pokershell/config.py | fblaha/pokershell | 36a3bfff6ead7fef175e430dfdb88ac6f6a31d1f | [
"Apache-2.0"
] | 6 | 2016-05-13T07:39:37.000Z | 2022-03-05T07:23:46.000Z | pokershell/config.py | fblaha/pokershell | 36a3bfff6ead7fef175e430dfdb88ac6f6a31d1f | [
"Apache-2.0"
] | 1 | 2017-12-18T09:08:28.000Z | 2017-12-31T01:48:32.000Z | pokershell/config.py | fblaha/pokershell | 36a3bfff6ead7fef175e430dfdb88ac6f6a31d1f | [
"Apache-2.0"
] | 5 | 2016-10-11T23:54:35.000Z | 2022-03-05T07:23:47.000Z | import pokershell.utils as utils
class ConfigOption(utils.CommonReprMixin):
def __init__(self, name, type, value, short, description):
super().__init__()
self.name = name
self.type = type
self._value = value
self.short = short
self.description = description
@pr... | 27.479167 | 89 | 0.595906 |
7947e41914c569736fcfe8a66e3c0df8f2cbd9c1 | 16,340 | py | Python | var/spack/repos/builtin/packages/rocm-openmp-extras/package.py | HigherOrderMethods/spack | 87ed3fcc59fc25ce250042338d082925e3a3610b | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | 1 | 2019-03-29T10:13:11.000Z | 2019-03-29T10:13:11.000Z | var/spack/repos/builtin/packages/rocm-openmp-extras/package.py | HigherOrderMethods/spack | 87ed3fcc59fc25ce250042338d082925e3a3610b | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | 11 | 2021-05-12T06:29:51.000Z | 2022-03-31T04:13:35.000Z | var/spack/repos/builtin/packages/rocm-openmp-extras/package.py | HigherOrderMethods/spack | 87ed3fcc59fc25ce250042338d082925e3a3610b | [
"ECL-2.0",
"Apache-2.0",
"MIT-0",
"MIT"
] | null | null | null | # Copyright 2013-2021 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from spack import *
import os
import re
tools_url = 'https://github.com/ROCm-Developer-Tools'
compute_url = 'https://gith... | 41.262626 | 79 | 0.611567 |
7947e43e9efdc64b556da3863796fa7716e34ac9 | 9,160 | py | Python | public/Python27/Lib/test/test_string.py | NingrumFadillah/cekmutasi | 1fccb6cafb874c2a80ece9b71d7c682fd44dbd48 | [
"MIT"
] | 27 | 2020-11-12T19:24:54.000Z | 2022-03-27T23:10:45.000Z | public/Python27/Lib/test/test_string.py | NingrumFadillah/cekmutasi | 1fccb6cafb874c2a80ece9b71d7c682fd44dbd48 | [
"MIT"
] | 2 | 2020-11-02T06:30:39.000Z | 2022-02-23T18:39:55.000Z | public/Python27/Lib/test/test_string.py | NingrumFadillah/cekmutasi | 1fccb6cafb874c2a80ece9b71d7c682fd44dbd48 | [
"MIT"
] | 3 | 2017-04-07T12:02:22.000Z | 2020-03-23T12:11:55.000Z | import unittest, string
from test import test_support, string_tests
from UserList import UserList
class StringTest(
string_tests.CommonTest,
string_tests.MixinStrStringUserStringTest
):
type2test = str
def checkequal(self, result, object, methodname, *args):
realresult = getattr(string, m... | 42.018349 | 764 | 0.559607 |
7947e48d11b8f33f814f4fb6352f15d6daf16777 | 685 | py | Python | app/core/migrations/0003_ingredient.py | abdulsagheer/recipe-api | 6c5f8408705c8ebf7fb1f4c916b898f8bab6ff43 | [
"MIT"
] | null | null | null | app/core/migrations/0003_ingredient.py | abdulsagheer/recipe-api | 6c5f8408705c8ebf7fb1f4c916b898f8bab6ff43 | [
"MIT"
] | null | null | null | app/core/migrations/0003_ingredient.py | abdulsagheer/recipe-api | 6c5f8408705c8ebf7fb1f4c916b898f8bab6ff43 | [
"MIT"
] | null | null | null | # Generated by Django 3.1.7 on 2021-03-15 20:18
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('core', '0002_tag'),
]
operations = [
migrations.CreateModel(
n... | 28.541667 | 118 | 0.617518 |
7947e49f6f85fe7d238de36258dfb0d9e3db3823 | 15,545 | py | Python | hydropandas/extensions/plots.py | boyandomhof/hydropandas | 0307d8dfa1262b832d559c80971884b53af0f675 | [
"MIT"
] | 11 | 2021-01-04T13:01:24.000Z | 2022-03-17T15:43:37.000Z | hydropandas/extensions/plots.py | boyandomhof/hydropandas | 0307d8dfa1262b832d559c80971884b53af0f675 | [
"MIT"
] | 21 | 2020-05-18T12:47:20.000Z | 2022-03-29T11:13:06.000Z | hydropandas/extensions/plots.py | boyandomhof/hydropandas | 0307d8dfa1262b832d559c80971884b53af0f675 | [
"MIT"
] | 2 | 2020-07-06T06:36:10.000Z | 2021-12-24T12:41:43.000Z | import os
import numpy as np
from . import accessor
import logging
logger = logging.getLogger(__name__)
@accessor.register_obscollection_accessor("plots")
class CollectionPlots:
def __init__(self, oc_obj):
"""Object containing plotting methods for ObsCollections.
Parameters
----------... | 37.639225 | 109 | 0.5156 |
7947e4a9f21b9336faa7f5564e48701bce7d2762 | 6,843 | py | Python | sp_api/api/products/products.py | coderjiang/python-amazon-sp-api | ecf64d468975b63839ee99b888dc8c72c32dcebd | [
"MIT"
] | 1 | 2022-01-10T01:45:07.000Z | 2022-01-10T01:45:07.000Z | sp_api/api/products/products.py | coderjiang/python-amazon-sp-api | ecf64d468975b63839ee99b888dc8c72c32dcebd | [
"MIT"
] | 30 | 2022-02-23T21:41:48.000Z | 2022-03-31T21:36:16.000Z | sp_api/api/products/products.py | pharm-it-de/python-amazon-sp-api | 389cca687a48da2387dac45d4352718dc60aaeec | [
"MIT"
] | null | null | null | import urllib.parse
from sp_api.base import ApiResponse, Client, fill_query_params, sp_endpoint
class Products(Client):
"""
:link: https://github.com/amzn/selling-partner-api-docs/blob/main/references/product-pricing-api/productPricingV0.md
"""
@sp_endpoint('/products/pricing/v0/price', method='GET')... | 41.222892 | 122 | 0.486483 |
7947e4b75e780761f5d74c2cf47683f445cd6ee8 | 1,124 | py | Python | mindspore/ops/_op_impl/cpu/bias_add.py | ATestGroup233/mindspore | 5d81221b5896cf7d7c6adb44daef28d92cb43352 | [
"Apache-2.0"
] | 1 | 2021-06-01T12:34:37.000Z | 2021-06-01T12:34:37.000Z | mindspore/ops/_op_impl/cpu/bias_add.py | ATestGroup233/mindspore | 5d81221b5896cf7d7c6adb44daef28d92cb43352 | [
"Apache-2.0"
] | null | null | null | mindspore/ops/_op_impl/cpu/bias_add.py | ATestGroup233/mindspore | 5d81221b5896cf7d7c6adb44daef28d92cb43352 | [
"Apache-2.0"
] | null | null | null | # Copyright 2021 Huawei Technologies Co., Ltd
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to... | 36.258065 | 93 | 0.685943 |
7947e54a17416b38a5dd639dd1a919f91909328c | 1,949 | py | Python | forecaster/Utilities.py | malin1993ml/QueryBot5000 | 58908dcd6d542b935dd8aa0f62b2dfe78430f61e | [
"Apache-2.0"
] | 82 | 2018-04-20T19:59:42.000Z | 2022-03-29T05:13:44.000Z | forecaster/Utilities.py | pentium3/QueryBot5000 | 7aace45fc9e13019931f73f837c8feb10a3cd142 | [
"Apache-2.0"
] | 4 | 2018-12-04T09:42:55.000Z | 2021-04-01T13:18:58.000Z | forecaster/Utilities.py | pentium3/QueryBot5000 | 7aace45fc9e13019931f73f837c8feb10a3cd142 | [
"Apache-2.0"
] | 28 | 2018-05-03T14:13:36.000Z | 2021-12-28T01:20:40.000Z | import numpy as np
from torch.autograd import Variable
import math
import torch
import matplotlib.pyplot as plt
import os
def onehot(X, dim):
Xind = np.zeros(dim)
Xind[X, np.arange(dim[1])] = 1
return Xind
def flat_prod(X,Y):
XY = np.zeros((X.shape[0]*Y.shape[0], X.shape[1]))
for i in range(X.sha... | 28.246377 | 82 | 0.623397 |
7947e584bf2b506b6695887c8a0e54809396cb59 | 6,611 | py | Python | test/functional/feature_maxuploadtarget.py | dogxteam/dogxwallet-master | 346189354bdec9a80c20bdc429ddec15c3b17b73 | [
"MIT"
] | 5 | 2019-03-18T02:14:20.000Z | 2019-03-21T17:08:27.000Z | test/functional/feature_maxuploadtarget.py | dogxteam/dogxwallet-master | 346189354bdec9a80c20bdc429ddec15c3b17b73 | [
"MIT"
] | null | null | null | test/functional/feature_maxuploadtarget.py | dogxteam/dogxwallet-master | 346189354bdec9a80c20bdc429ddec15c3b17b73 | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
# Copyright (c) 2015-2018 The dogxcoin Core developers
# Distributed under the MIT software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
"""Test behavior of -maxuploadtarget.
* Verify that getdata requests for old blocks (>1week) are dropped... | 40.066667 | 107 | 0.678264 |
7947e5b7dabab313f33e5e1f63fa2898c6f11020 | 8,112 | py | Python | nagios/libexec/check_mod_status.py | Oneiroi/sysadmin | 701c8db0667eff683377fd119490308c503bf464 | [
"Apache-2.0"
] | 29 | 2015-01-11T06:14:19.000Z | 2020-01-16T04:27:25.000Z | nagios/libexec/check_mod_status.py | Oneiroi/sysadmin | 701c8db0667eff683377fd119490308c503bf464 | [
"Apache-2.0"
] | 1 | 2015-04-07T12:20:07.000Z | 2015-04-07T12:20:07.000Z | nagios/libexec/check_mod_status.py | Oneiroi/sysadmin | 701c8db0667eff683377fd119490308c503bf464 | [
"Apache-2.0"
] | 18 | 2015-01-26T05:19:52.000Z | 2021-04-29T12:18:46.000Z | #!/usr/local/bin/python
#
# check_mod_status.py
#
# Created by David Busby on 30/03/2009.
#
"""
__author__="David Busby"
__copyright__="Psycle Interactive Ltd & David Busby"
__license__="GNU v3 + part 5d section 7: Redistribution/Reuse of this code is permitted under the GNU v3 license, as an additional term ALL co... | 39.960591 | 203 | 0.464127 |
7947e75c144919fa8d6f90aa6d06febedec241ef | 174 | py | Python | aws-cdk-cis/app.py | severel/aws-cdk-cis | 7008a65966240708da235eb7e52d75d21489dd9e | [
"MIT"
] | 2 | 2021-03-08T01:24:42.000Z | 2021-04-03T14:50:33.000Z | aws-cdk-cis/app.py | severel/aws-cdk-cis | 7008a65966240708da235eb7e52d75d21489dd9e | [
"MIT"
] | null | null | null | aws-cdk-cis/app.py | severel/aws-cdk-cis | 7008a65966240708da235eb7e52d75d21489dd9e | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
from aws_cdk import core
from aws_cdk_cis.aws_cdk_cis_stack import AwsCdkCisStack
app = core.App()
AwsCdkCisStack(app, "aws-cdk-cis")
app.synth()
| 14.5 | 56 | 0.764368 |
7947e857d5687cf517a0c3dd276e5e6f000b17e7 | 464 | py | Python | data/scripts/templates/object/building/poi/shared_yavin4_hutt_scavenger_camp_small1.py | obi-two/GameServer | 7d37024e2291a97d49522610cd8f1dbe5666afc2 | [
"MIT"
] | 20 | 2015-02-23T15:11:56.000Z | 2022-03-18T20:56:48.000Z | data/scripts/templates/object/building/poi/shared_yavin4_hutt_scavenger_camp_small1.py | apathyboy/swganh | 665128efe9154611dec4cb5efc61d246dd095984 | [
"MIT"
] | null | null | null | data/scripts/templates/object/building/poi/shared_yavin4_hutt_scavenger_camp_small1.py | apathyboy/swganh | 665128efe9154611dec4cb5efc61d246dd095984 | [
"MIT"
] | 20 | 2015-04-04T16:35:59.000Z | 2022-03-24T14:54:37.000Z | #### NOTICE: THIS FILE IS AUTOGENERATED
#### MODIFICATIONS MAY BE LOST IF DONE IMPROPERLY
#### PLEASE SEE THE ONLINE DOCUMENTATION FOR EXAMPLES
from swgpy.object import *
def create(kernel):
result = Building()
result.template = "object/building/poi/shared_yavin4_hutt_scavenger_camp_small1.iff"
result.attribute_... | 27.294118 | 85 | 0.737069 |
7947ea7425f1c0daf4d66cf8aac431401496318e | 3,250 | py | Python | common/database/main.py | dnguyen0304/python-common | 7fdcc584d223c277e3cdb0336cc923a4f9adcece | [
"MIT"
] | null | null | null | common/database/main.py | dnguyen0304/python-common | 7fdcc584d223c277e3cdb0336cc923a4f9adcece | [
"MIT"
] | null | null | null | common/database/main.py | dnguyen0304/python-common | 7fdcc584d223c277e3cdb0336cc923a4f9adcece | [
"MIT"
] | 1 | 2018-09-19T00:40:10.000Z | 2018-09-19T00:40:10.000Z | # -*- coding: utf-8 -*-
import datetime
import sqlalchemy
from sqlalchemy import orm
class DBContext:
def __init__(self, session):
"""
Decorator class that manages persistence operations for
ORM-mapped objects.
Parameters
----------
session : sqlalchemy.orm.ses... | 26.639344 | 72 | 0.585231 |
7947ea9ba83ddb09570586326518f67e03a4a24e | 868 | py | Python | mms/tests/unit_tests/test_utils/dummy_class_model_service.py | dhanainme/multi-model-server | cd5a693032b1bec4c46b0f7a9844df496a62c1a8 | [
"Apache-2.0"
] | 527 | 2017-12-04T20:58:19.000Z | 2019-11-14T03:15:39.000Z | mms/tests/unit_tests/test_utils/dummy_class_model_service.py | DrSnowbird/mxnet-model-server | a0bfd712350545dceb21c8e0b0b21dfa0c9918a7 | [
"Apache-2.0"
] | 303 | 2017-12-05T06:14:08.000Z | 2019-11-16T01:35:15.000Z | mms/tests/unit_tests/test_utils/dummy_class_model_service.py | DrSnowbird/mxnet-model-server | a0bfd712350545dceb21c8e0b0b21dfa0c9918a7 | [
"Apache-2.0"
] | 144 | 2017-12-05T19:27:39.000Z | 2019-11-15T22:15:50.000Z | # Copyright 2018 Amazon.com, Inc. or its affiliates. All Rights Reserved.
# Licensed under the Apache License, Version 2.0 (the "License").
# You may not use this file except in compliance with the License.
# A copy of the License is located at
# http://www.apache.org/licenses/LICENSE-2.0
# or in the "license" file... | 33.384615 | 75 | 0.732719 |
7947eb1402324f98d876f6bdeed5867603d64cfd | 2,005 | py | Python | datary/operations/clean.py | Datary/python-sdk | 2790a50e1ad262cbe3210665dc34f497625e923d | [
"MIT"
] | null | null | null | datary/operations/clean.py | Datary/python-sdk | 2790a50e1ad262cbe3210665dc34f497625e923d | [
"MIT"
] | null | null | null | datary/operations/clean.py | Datary/python-sdk | 2790a50e1ad262cbe3210665dc34f497625e923d | [
"MIT"
] | null | null | null |
# -*- coding: utf-8 -*-
"""
Datary sdk clean Operations File
"""
from datary.repos import DataryRepos
from datary.workdirs import DataryWorkdirs
from datary.operations.remove import DataryRemoveOperation
from datary.operations.limits import DataryOperationLimits
from scrapbag import flatten
import structlog
logger ... | 31.328125 | 78 | 0.505237 |
7947ebe6d82af84e96e565ed75358755411f84bb | 237 | py | Python | pattern_classes/Engineer.py | Sunuba/PythonStrategyPattern | b0490cf63ecc87562d5fc3ef1f2a152fb97b0a78 | [
"MIT"
] | null | null | null | pattern_classes/Engineer.py | Sunuba/PythonStrategyPattern | b0490cf63ecc87562d5fc3ef1f2a152fb97b0a78 | [
"MIT"
] | null | null | null | pattern_classes/Engineer.py | Sunuba/PythonStrategyPattern | b0490cf63ecc87562d5fc3ef1f2a152fb97b0a78 | [
"MIT"
] | null | null | null | class Engineer:
def __init__(self, height, width, method):
self.method = method
self.height = height
self.width = width
def calculate(self):
return self.method().calculate(self.width, self.height) | 29.625 | 63 | 0.637131 |
7947ed6af9e6a790dfcadb11eb9ecd5474560cf0 | 4,812 | py | Python | setup.py | sjfleming/pyro | c8dc40a75cc4ff1f43c6ff9178d91c08155d7973 | [
"Apache-2.0"
] | null | null | null | setup.py | sjfleming/pyro | c8dc40a75cc4ff1f43c6ff9178d91c08155d7973 | [
"Apache-2.0"
] | null | null | null | setup.py | sjfleming/pyro | c8dc40a75cc4ff1f43c6ff9178d91c08155d7973 | [
"Apache-2.0"
] | null | null | null | # Copyright (c) 2017-2019 Uber Technologies, Inc.
# SPDX-License-Identifier: Apache-2.0
import os
import subprocess
import sys
from setuptools import find_packages, setup
PROJECT_PATH = os.path.dirname(os.path.abspath(__file__))
VERSION = """
# This file is auto-generated with the version information during setup.py... | 30.649682 | 114 | 0.584996 |
7947eebcc1a5a7b8a1b7eb267e5490b41b8cfb57 | 446 | py | Python | venv/Scripts/pasteurize-script.py | TRGG3R/Visual_FCT_Explorer | 3fc2cf00109afa5f407de6c0d6e3de6cb7285a78 | [
"MIT"
] | null | null | null | venv/Scripts/pasteurize-script.py | TRGG3R/Visual_FCT_Explorer | 3fc2cf00109afa5f407de6c0d6e3de6cb7285a78 | [
"MIT"
] | null | null | null | venv/Scripts/pasteurize-script.py | TRGG3R/Visual_FCT_Explorer | 3fc2cf00109afa5f407de6c0d6e3de6cb7285a78 | [
"MIT"
] | null | null | null | #!C:\Users\thepo\PycharmProjects\Visual_FCT_Explorer\venv\Scripts\python.exe
# EASY-INSTALL-ENTRY-SCRIPT: 'future==0.18.2','console_scripts','pasteurize'
__requires__ = 'future==0.18.2'
import re
import sys
from pkg_resources import load_entry_point
if __name__ == '__main__':
sys.argv[0] = re.sub(r'(-script\.pyw?|... | 34.307692 | 77 | 0.695067 |
7947ef79e3867a3dd00242e8dc2abce727d565e5 | 353 | py | Python | Aulas/Mundo 3/104.py | JoaoEmanuell/Meus-Estudos-Python | f6f6eeb6016919e594613785ffe7136d74241ada | [
"MIT"
] | 2 | 2021-07-29T18:58:02.000Z | 2021-10-29T21:11:22.000Z | Aulas/Mundo 3/104.py | JoaoEmanuell/Meus-Estudos-Python | f6f6eeb6016919e594613785ffe7136d74241ada | [
"MIT"
] | null | null | null | Aulas/Mundo 3/104.py | JoaoEmanuell/Meus-Estudos-Python | f6f6eeb6016919e594613785ffe7136d74241ada | [
"MIT"
] | null | null | null | def leia(msg):
ok = False
valor = 0
while True:
n = str(input(msg))
if n.isnumeric():
valor = int(n)
ok = True
else:
print('Porfavor digite um numero valido')
if ok:
break
return n
n = leia('Digite um numero... | 19.611111 | 54 | 0.456091 |
7947ef9fd9180a2f6b9d4777a2890c14fba66dc7 | 1,089 | py | Python | examples/extra_examples/drum_hits.py | aejb/blinkt | e93217143ac645ed2a1365a312908283c54ac2e0 | [
"MIT"
] | 1 | 2021-06-05T03:12:37.000Z | 2021-06-05T03:12:37.000Z | examples/extra_examples/drum_hits.py | aejb/blinkt | e93217143ac645ed2a1365a312908283c54ac2e0 | [
"MIT"
] | null | null | null | examples/extra_examples/drum_hits.py | aejb/blinkt | e93217143ac645ed2a1365a312908283c54ac2e0 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
import glob
import os
import time
from sys import exit
try:
import drumhat
except ImportError:
exit("This script requires the drumhat module\nInstall with: sudo pip install drumhat")
try:
import pygame
except ImportError:
exit("This script requires the pygame module\nInstall wit... | 20.942308 | 91 | 0.708907 |
7947f117a59843822c68958a98ab745bc2d61baf | 813 | py | Python | models.py | eyvonne/TwittOff | cfb1226a351aa89ab9ae183e38042caa0eef2db9 | [
"MIT"
] | null | null | null | models.py | eyvonne/TwittOff | cfb1226a351aa89ab9ae183e38042caa0eef2db9 | [
"MIT"
] | null | null | null | models.py | eyvonne/TwittOff | cfb1226a351aa89ab9ae183e38042caa0eef2db9 | [
"MIT"
] | null | null | null | ''' SQLAlchecmy models for twittoff'''
from flask_sqlalchemy import SQLAlchemy
DB = SQLAlchemy()
class User(DB.Model):
"""Twitter users that we pull and analyze"""
id = DB.Column(DB.BigInteger, primary_key=True)
name = DB.Column(DB.String(15), nullable=False)
#newest_tweet_id = DB.Column(DB.BigInte... | 28.034483 | 80 | 0.671587 |
7947f1748767b84cff2e04ce6a706eaf08d2eeaf | 10,852 | py | Python | mayan/apps/documents/settings.py | nattangwiwat/Mayan-EDMS-recitation | fcf16afb56eae812fb99144d65ae1ae6749de0b7 | [
"Apache-2.0"
] | 4 | 2021-09-02T00:16:30.000Z | 2021-09-09T22:25:15.000Z | mayan/apps/documents/settings.py | nattangwiwat/Mayan-EDMS-recitation | fcf16afb56eae812fb99144d65ae1ae6749de0b7 | [
"Apache-2.0"
] | 86 | 2021-09-01T23:53:02.000Z | 2021-09-20T02:25:10.000Z | mayan/apps/documents/settings.py | nattangwiwat/Mayan-EDMS-recitation | fcf16afb56eae812fb99144d65ae1ae6749de0b7 | [
"Apache-2.0"
] | 70 | 2021-09-01T12:54:51.000Z | 2022-02-16T00:53:18.000Z | from django.utils.translation import ugettext_lazy as _
from mayan.apps.smart_settings.classes import SettingNamespace
from .literals import (
DEFAULT_DOCUMENTS_DISPLAY_HEIGHT, DEFAULT_DOCUMENTS_DISPLAY_WIDTH,
DEFAULT_DOCUMENTS_FAVORITE_COUNT,
DEFAULT_DOCUMENTS_FILE_PAGE_IMAGE_CACHE_STORAGE_BACKEND,
D... | 44.113821 | 98 | 0.803078 |
7947f27800b8632d645a717db73609d4f9adbc4e | 762 | py | Python | users/forms.py | zamuzakki/gis-portfolio | b628c3854db992dbd8435a655bfb32c7f5a075a7 | [
"MIT"
] | null | null | null | users/forms.py | zamuzakki/gis-portfolio | b628c3854db992dbd8435a655bfb32c7f5a075a7 | [
"MIT"
] | 9 | 2020-06-06T01:35:08.000Z | 2022-03-12T00:19:55.000Z | users/forms.py | zamuzakki/gis-portfolio | b628c3854db992dbd8435a655bfb32c7f5a075a7 | [
"MIT"
] | null | null | null | from django.contrib.auth.forms import UserCreationForm, UserChangeForm
from .models import CustomUser
class CustomUserCreationForm(UserCreationForm):
"""
Form that will be used to create the user in CustomUserAdmin
"""
class Meta(UserCreationForm.Meta):
model = CustomUser
fields = ('em... | 26.275862 | 70 | 0.666667 |
7947f2847d3466790ef15ec7e94bef5e06a88ff1 | 2,811 | py | Python | pretrainings/pretrainings_tmc.py | expertailab/ISAAQ | 133e25adbf5c219aceef6e7f38135de248371cb1 | [
"MIT"
] | 7 | 2020-10-06T03:51:13.000Z | 2021-11-30T04:05:10.000Z | pretrainings/pretrainings_tmc.py | expertailab/ISAAQ | 133e25adbf5c219aceef6e7f38135de248371cb1 | [
"MIT"
] | 2 | 2020-10-12T02:10:47.000Z | 2021-01-05T06:15:54.000Z | pretrainings/pretrainings_tmc.py | expertailab/ISAAQ | 133e25adbf5c219aceef6e7f38135de248371cb1 | [
"MIT"
] | 4 | 2020-10-08T05:04:27.000Z | 2021-01-07T01:31:22.000Z | from transformers import AdamW, RobertaForMultipleChoice, RobertaTokenizer
from transformers import get_linear_schedule_with_warmup
import numpy as np
import random
import torch
import sys
import argparse
from aux_methods import get_data_pretrainings, process_data_ndq, training_ndq
def main(argv):
parser = argpar... | 43.921875 | 161 | 0.704731 |
7947f2d84e8441a05199b8816964ce493113c9ac | 6,918 | py | Python | bindings/python/ensmallen_graph/datasets/string/lachnospiraceaebacteriumfe2018.py | caufieldjh/ensmallen_graph | 14e98b1cdbc73193a84a913d7d4f2b2b3eb2c43a | [
"MIT"
] | null | null | null | bindings/python/ensmallen_graph/datasets/string/lachnospiraceaebacteriumfe2018.py | caufieldjh/ensmallen_graph | 14e98b1cdbc73193a84a913d7d4f2b2b3eb2c43a | [
"MIT"
] | null | null | null | bindings/python/ensmallen_graph/datasets/string/lachnospiraceaebacteriumfe2018.py | caufieldjh/ensmallen_graph | 14e98b1cdbc73193a84a913d7d4f2b2b3eb2c43a | [
"MIT"
] | null | null | null | """
This file offers the methods to automatically retrieve the graph Lachnospiraceae bacterium FE2018.
The graph is automatically retrieved from the STRING repository.
Report
---------------------
At the time of rendering these methods (please see datetime below), the graph
had the following characteristics:
Date... | 36.219895 | 223 | 0.712778 |
7947f32ca0629cfad404922aa3cc80ba408baca2 | 3,054 | py | Python | tensorflow_graphics/notebooks/mesh_viewer.py | jackd/graphics | 736b99a3306e302674a9b7599e3e2857b85fdb74 | [
"Apache-2.0"
] | null | null | null | tensorflow_graphics/notebooks/mesh_viewer.py | jackd/graphics | 736b99a3306e302674a9b7599e3e2857b85fdb74 | [
"Apache-2.0"
] | null | null | null | tensorflow_graphics/notebooks/mesh_viewer.py | jackd/graphics | 736b99a3306e302674a9b7599e3e2857b85fdb74 | [
"Apache-2.0"
] | 1 | 2020-04-11T10:37:36.000Z | 2020-04-11T10:37:36.000Z | # Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, s... | 40.184211 | 80 | 0.638179 |
7947f45ac8bc384fbcbb39197a6a9122e89ec90d | 880 | py | Python | spider/data_collector.py | glstr/python_learning | 243908d6f358764386f2e58dfbfde10a406d803c | [
"Apache-2.0"
] | 2 | 2018-09-20T06:08:00.000Z | 2018-09-26T13:57:20.000Z | spider/data_collector.py | glstr/python_learning | 243908d6f358764386f2e58dfbfde10a406d803c | [
"Apache-2.0"
] | null | null | null | spider/data_collector.py | glstr/python_learning | 243908d6f358764386f2e58dfbfde10a406d803c | [
"Apache-2.0"
] | 1 | 2019-03-25T05:53:32.000Z | 2019-03-25T05:53:32.000Z | #!/usr/bin/python
# coding=utf-8
import json
import requests
class DataCollector(object):
def __init__(self):
self.name = "default data collector"
return
def grab(self, option):
url = option["url"]
r = requests.get(url)
r.json()
return r
def gather(se... | 20.465116 | 44 | 0.542045 |
7947f60c020e68066e55c9bf1360bcba8e1517d2 | 3,158 | py | Python | mindinsight/mindconverter/graph_based_converter/sub_graph_searcher/known_module_name.py | fapbatista/mindinsight | db5769eb80cbd13a2a9af7682c11f5667d8bf141 | [
"Apache-2.0"
] | null | null | null | mindinsight/mindconverter/graph_based_converter/sub_graph_searcher/known_module_name.py | fapbatista/mindinsight | db5769eb80cbd13a2a9af7682c11f5667d8bf141 | [
"Apache-2.0"
] | null | null | null | mindinsight/mindconverter/graph_based_converter/sub_graph_searcher/known_module_name.py | fapbatista/mindinsight | db5769eb80cbd13a2a9af7682c11f5667d8bf141 | [
"Apache-2.0"
] | null | null | null | # Copyright 2020 Huawei Technologies Co., Ltd.All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by ap... | 30.365385 | 101 | 0.649145 |
7947f7cccae483ca053f2dcb8c10607944745386 | 6,815 | py | Python | tests/components/hassio/test_http.py | MrDelik/core | 93a66cc357b226389967668441000498a10453bb | [
"Apache-2.0"
] | 30,023 | 2016-04-13T10:17:53.000Z | 2020-03-02T12:56:31.000Z | tests/components/hassio/test_http.py | MrDelik/core | 93a66cc357b226389967668441000498a10453bb | [
"Apache-2.0"
] | 31,101 | 2020-03-02T13:00:16.000Z | 2022-03-31T23:57:36.000Z | tests/components/hassio/test_http.py | MrDelik/core | 93a66cc357b226389967668441000498a10453bb | [
"Apache-2.0"
] | 11,956 | 2016-04-13T18:42:31.000Z | 2020-03-02T09:32:12.000Z | """The tests for the hassio component."""
import asyncio
from http import HTTPStatus
from aiohttp import StreamReader
import pytest
from homeassistant.components.hassio.http import _need_auth
async def test_forward_request(hassio_client, aioclient_mock):
"""Test fetching normal path."""
aioclient_mock.post(... | 32.922705 | 86 | 0.704916 |
7947f851f8f04b9ce2515f2ec19e08711c27ffee | 28,686 | py | Python | mskit/ms_pred/pdeep.py | gureann/MSKit | 8b360d38288100476740ad808e11b6c1b454dc2c | [
"MIT"
] | null | null | null | mskit/ms_pred/pdeep.py | gureann/MSKit | 8b360d38288100476740ad808e11b6c1b454dc2c | [
"MIT"
] | null | null | null | mskit/ms_pred/pdeep.py | gureann/MSKit | 8b360d38288100476740ad808e11b6c1b454dc2c | [
"MIT"
] | null | null | null | import os
import re
from collections import defaultdict
import pandas as pd
from mskit import rapid_kit
from mskit.post_analysis.spectronaut import SpectronautLibrary
from ._pdeep_constant import BasicpDeepInfo
from ._pdeep_constant import MOD
def intprec_to_pdeep_test(intprec_list):
"""
从 intprec 转换为 pDeep... | 46.193237 | 177 | 0.579237 |
7947f8839eecc7dabc5f3ccfb8db7265e4c4b26b | 1,363 | py | Python | threaded_stream/reader.py | cipher982/birb-watch | bdba5455f3b994b143e96b41afbf17d698610454 | [
"Apache-2.0"
] | null | null | null | threaded_stream/reader.py | cipher982/birb-watch | bdba5455f3b994b143e96b41afbf17d698610454 | [
"Apache-2.0"
] | null | null | null | threaded_stream/reader.py | cipher982/birb-watch | bdba5455f3b994b143e96b41afbf17d698610454 | [
"Apache-2.0"
] | null | null | null | # import the necessary packages
import os
from threading import Thread
import cv2
from dotenv import load_dotenv
load_dotenv()
RTSP_USER = os.getenv("RTSP_USER")
RTSP_PW = os.getenv("RTSP_PW")
RTSP_IP = os.getenv("RTSP_IP")
def get_amcrest_rtsp_url(user, pw, ip):
url = (
f"rtsp://{user}:{pw}@{ip}:554/... | 24.339286 | 70 | 0.630227 |
7947f8b4cbeb5d156ac757518624a8901ace033c | 7,548 | py | Python | lesson11/sunzhaohui/reboot/users/group/__init__.py | herrywen-nanj/51reboot | 1130c79a360e1b548a6eaad176eb60f8bed22f40 | [
"Apache-2.0"
] | null | null | null | lesson11/sunzhaohui/reboot/users/group/__init__.py | herrywen-nanj/51reboot | 1130c79a360e1b548a6eaad176eb60f8bed22f40 | [
"Apache-2.0"
] | null | null | null | lesson11/sunzhaohui/reboot/users/group/__init__.py | herrywen-nanj/51reboot | 1130c79a360e1b548a6eaad176eb60f8bed22f40 | [
"Apache-2.0"
] | null | null | null | # _*_ encoding:utf-8 _*_
__author__ = 'sunzhaohui'
__date__ = '2019-08-05 17:20'
from django.shortcuts import render
from django.http import HttpResponse,QueryDict,HttpResponseRedirect,JsonResponse,Http404
from django.urls import reverse
from django.conf import settings
from users.models import UserProfile
from djan... | 38.907216 | 106 | 0.638182 |
7947fa4f1cf325abcbf605aed1f3df3be36ad692 | 188 | py | Python | contrib/tests/tests/test_perl518.py | rockstack/rock | 1d010d942c5b1c8fd198223ac1f4a3dd5d690edb | [
"MIT"
] | 1 | 2015-03-13T06:01:06.000Z | 2015-03-13T06:01:06.000Z | contrib/tests/tests/test_perl518.py | rockstack/rock | 1d010d942c5b1c8fd198223ac1f4a3dd5d690edb | [
"MIT"
] | null | null | null | contrib/tests/tests/test_perl518.py | rockstack/rock | 1d010d942c5b1c8fd198223ac1f4a3dd5d690edb | [
"MIT"
] | null | null | null | import helper
class RuntimeTestCase(helper.RuntimeTests):
name = 'perl518'
init_files = ['cpanfile']
init_directories = ['t']
if __name__ == '__main__':
helper.main()
| 14.461538 | 43 | 0.659574 |
7947fad0417dc385353cf42672bb3f4f5e8d8531 | 4,898 | py | Python | source/models/gans/VQGAN/utils.py | Adamkomar95/gans-clip-pw | 14694abd3a793b3e0fdfed76e2e12908e91ea484 | [
"MIT"
] | null | null | null | source/models/gans/VQGAN/utils.py | Adamkomar95/gans-clip-pw | 14694abd3a793b3e0fdfed76e2e12908e91ea484 | [
"MIT"
] | null | null | null | source/models/gans/VQGAN/utils.py | Adamkomar95/gans-clip-pw | 14694abd3a793b3e0fdfed76e2e12908e91ea484 | [
"MIT"
] | null | null | null |
import os
from imageio import imread, imsave
import numpy as np
import matplotlib.pyplot as plt
import torch
import torch.nn.functional as F
def plot_text(txt, size=224):
fig = plt.figure(figsize=(1,1), dpi=size)
fontsize = size//len(txt) if len(txt) < 15 else 8
plt.text(0.5, 0.5, txt, fontsize=fontsize,... | 35.751825 | 119 | 0.603103 |
7947fb0d104b8aace7c25ae3592a76a3eb9dd5c5 | 898 | py | Python | apps/financeDashboard.py | austinbyersking/sp500Dashboard-main | 0e2ee26207c51592ea925e8fbf9303f45b2e3c31 | [
"MIT"
] | null | null | null | apps/financeDashboard.py | austinbyersking/sp500Dashboard-main | 0e2ee26207c51592ea925e8fbf9303f45b2e3c31 | [
"MIT"
] | null | null | null | apps/financeDashboard.py | austinbyersking/sp500Dashboard-main | 0e2ee26207c51592ea925e8fbf9303f45b2e3c31 | [
"MIT"
] | null | null | null | import streamlit as st
import yfinance as yf
import pandas as pd
def app():
st.title('Finance Dashboard')
#Tickers
snp500 = pd.read_csv("Datasets/SP500.csv")
tickers = snp500['Symbol'].sort_values().tolist()
#Dropdown menu
dropdown = st.multiselect('Pick your assets',
... | 27.212121 | 72 | 0.605791 |
7947fb213795fccdf10fe28c061f252c70e52237 | 1,515 | py | Python | frontoxy/blocks/reader.py | fabienvauchelles/frontoxy | 320a4b5592c507ac88955d727408b58ff35902b8 | [
"MIT"
] | 8 | 2016-10-20T15:52:09.000Z | 2019-03-27T19:16:40.000Z | frontoxy/blocks/reader.py | fabienvauchelles/frontoxy | 320a4b5592c507ac88955d727408b58ff35902b8 | [
"MIT"
] | 1 | 2018-01-19T12:31:06.000Z | 2018-01-24T09:38:12.000Z | frontoxy/blocks/reader.py | fabienvauchelles/frontoxy | 320a4b5592c507ac88955d727408b58ff35902b8 | [
"MIT"
] | 4 | 2017-08-17T11:40:41.000Z | 2021-01-21T07:07:48.000Z | # -*- coding: utf-8 -*-
from scrapy import Request
from scrapy.http import HtmlResponse
import json
import os
import zipfile
class BlocksReader(object):
INFO_FORMAT = u'{0}.desc'
BODY_FORMAT = u'{0}.dat'
def read(self, source):
source_filename = os.path.basename(source)
with zipfile.Z... | 27.053571 | 89 | 0.491749 |
7947fc13e0fd41c017b3d3c251557c2b34ccd944 | 139 | py | Python | exercicios-python/curso-python/ex011.py | PabloLanza/curso-python3 | 34cf44a2467fa239ba4019e085833002ad9b76a1 | [
"MIT"
] | null | null | null | exercicios-python/curso-python/ex011.py | PabloLanza/curso-python3 | 34cf44a2467fa239ba4019e085833002ad9b76a1 | [
"MIT"
] | null | null | null | exercicios-python/curso-python/ex011.py | PabloLanza/curso-python3 | 34cf44a2467fa239ba4019e085833002ad9b76a1 | [
"MIT"
] | null | null | null | sal = float(input('Qual o seu salário? '))
aum = sal * 0.15
novosal = sal + aum
print('O seu novo salário é de R${:.2f}.' .format(novosal)) | 34.75 | 59 | 0.640288 |
7947fcbdbe209ef363cc968339ee4c047a1a073e | 1,474 | py | Python | python_scripts/010_Concatenate_cap_catAGN.py | SoumyaShreeram/Locating_AGN_in_DM_halos | 1cfbee69b2c000faee4ecb199d65c3235afbed42 | [
"MIT"
] | null | null | null | python_scripts/010_Concatenate_cap_catAGN.py | SoumyaShreeram/Locating_AGN_in_DM_halos | 1cfbee69b2c000faee4ecb199d65c3235afbed42 | [
"MIT"
] | null | null | null | python_scripts/010_Concatenate_cap_catAGN.py | SoumyaShreeram/Locating_AGN_in_DM_halos | 1cfbee69b2c000faee4ecb199d65c3235afbed42 | [
"MIT"
] | null | null | null | """
010. Concatenates the cluster files with affected Lx due to AGN
Script written by: Soumya Shreeram
Project supervised by: Johan Comparat
Date: 1st July 2021
"""
# astropy modules
import astropy.units as u
import astropy.io.fits as fits
from astropy.table import Table, Column, join
from astropy.coordinates im... | 24.566667 | 96 | 0.807327 |
7947fd129400a285b41b3ab1ed3bf731fc382cae | 4,811 | py | Python | mymcadmin/cli/commands/start.py | durandj/mymcadmin | 6c9ebfa2a5dfcea1f5fb5c5cf1c0256b05b98172 | [
"MIT"
] | null | null | null | mymcadmin/cli/commands/start.py | durandj/mymcadmin | 6c9ebfa2a5dfcea1f5fb5c5cf1c0256b05b98172 | [
"MIT"
] | null | null | null | mymcadmin/cli/commands/start.py | durandj/mymcadmin | 6c9ebfa2a5dfcea1f5fb5c5cf1c0256b05b98172 | [
"MIT"
] | null | null | null | """
Start commands
"""
import multiprocessing
import grp
import os
import os.path
import pwd
import click
import daemon
import daemon.pidfile
from .. import params
from ..base import mymcadmin, cli_command, rpc_command, error, success
from ... import (
errors,
manager,
rpc,
utils,
)
@mymcadmin.comma... | 23.468293 | 82 | 0.563916 |
7947fed0eaa684eb6f80641ee94fbbc46ba016df | 7,314 | py | Python | graph/undirected_graph_vector.py | rburing/gcaops | 3866e11584d42354c65643c70cd2b6982866c129 | [
"MIT"
] | null | null | null | graph/undirected_graph_vector.py | rburing/gcaops | 3866e11584d42354c65643c70cd2b6982866c129 | [
"MIT"
] | null | null | null | graph/undirected_graph_vector.py | rburing/gcaops | 3866e11584d42354c65643c70cd2b6982866c129 | [
"MIT"
] | null | null | null | from itertools import product
from .graph_vector import GraphVector, GraphModule
from .graph_vector_dict import GraphVector_dict, GraphModule_dict
from .graph_vector_vector import GraphVector_vector, GraphModule_vector
from .undirected_graph_basis import UndirectedGraphBasis
class UndirectedGraphVector(GraphVector):
... | 37.896373 | 132 | 0.628521 |
7947ffbd8d5704dc68f6e3d1299c9380098fc835 | 1,302 | py | Python | pylsd/bindings/lsd_ctypes.py | AndranikSargsyan/pylsd-nova | 762a8c587a7b8bf142495d367880dbb33df121ba | [
"BSD-2-Clause"
] | 23 | 2020-08-13T01:37:54.000Z | 2022-03-31T09:39:50.000Z | pylsd/bindings/lsd_ctypes.py | AndranikSargsyan/pylsd-nova | 762a8c587a7b8bf142495d367880dbb33df121ba | [
"BSD-2-Clause"
] | 2 | 2020-08-15T15:24:26.000Z | 2021-07-20T23:05:51.000Z | pylsd/bindings/lsd_ctypes.py | AndranikSargsyan/pylsd-nova | 762a8c587a7b8bf142495d367880dbb33df121ba | [
"BSD-2-Clause"
] | 3 | 2020-09-01T17:17:45.000Z | 2022-03-09T09:58:50.000Z | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import ctypes
import os
import sys
def load_lsd_library():
root_dir = os.path.abspath(os.path.dirname(__file__))
libnames = ['linux/liblsd.so']
libdir = 'lib'
if sys.platform == 'win32':
if sys.maxsize > 2 ** 32:
libnames = ['win32/x... | 25.038462 | 77 | 0.572197 |
7948001291cd96ce098a5bb558bae227822ceaa0 | 728 | py | Python | server_part/config.py | Hubert51/Empty-study-room-detector | 9cbd18a4bf5bc02b8aebac42c15161258015ed5c | [
"MIT"
] | 2 | 2017-04-30T00:46:59.000Z | 2019-04-20T03:39:31.000Z | server_part/config.py | Hubert51/Empty-study-room-detector | 9cbd18a4bf5bc02b8aebac42c15161258015ed5c | [
"MIT"
] | 2 | 2017-04-30T16:25:08.000Z | 2017-05-04T01:47:31.000Z | server_part/config.py | Hubert51/Empty-study-room-detector | 9cbd18a4bf5bc02b8aebac42c15161258015ed5c | [
"MIT"
] | 3 | 2017-02-16T00:22:02.000Z | 2019-04-14T00:03:13.000Z | #encoding:utf-8
import os
WTF_CSRF_ENABLED = True
SECRET_KEY = 'you-will-never-guess'
OPENID_PROVIDERS = [
{'name': 'Google', 'url': 'https://www.google.com/accounts/o8/id'},
{'name': 'Yahoo', 'url': 'https://me.yahoo.com'},
{'name': 'AOL', 'url': 'http://openid.aol.com/<username>'},
{'name': 'Flickr', 'url': ... | 30.333333 | 131 | 0.717033 |
7948008a047381e0a522f628007fc2bc95a7dea4 | 1,694 | py | Python | UVA-OJ/108 - Maximum Sum.py | MhmdRyhn/Programming-Sloution | be189cbf81b14ac7c10d387e259aa23992ba1016 | [
"MIT"
] | 1 | 2019-07-29T04:05:34.000Z | 2019-07-29T04:05:34.000Z | UVA-OJ/108 - Maximum Sum.py | MhmdRyhn/Programming-Sloution | be189cbf81b14ac7c10d387e259aa23992ba1016 | [
"MIT"
] | null | null | null | UVA-OJ/108 - Maximum Sum.py | MhmdRyhn/Programming-Sloution | be189cbf81b14ac7c10d387e259aa23992ba1016 | [
"MIT"
] | null | null | null | def max_sum_subarray_1D(arr, sz):
cur_max_sum = global_max_sum = arr[0]
for i in range(1, sz):
cur_max_sum = max(arr[i], cur_max_sum+arr[i])
if cur_max_sum > global_max_sum:
global_max_sum = cur_max_sum
return global_max_sum
def max_sum_subarray_2D(arr_2d, m, n):
for i in... | 23.527778 | 61 | 0.40732 |
794800951ac21be2ddf4a72f53436150a681f5d0 | 6,768 | py | Python | sdk/python/pulumi_azure_native/network/v20200701/get_virtual_network_gateway_vpnclient_ipsec_parameters.py | sebtelko/pulumi-azure-native | 711ec021b5c73da05611c56c8a35adb0ce3244e4 | [
"Apache-2.0"
] | null | null | null | sdk/python/pulumi_azure_native/network/v20200701/get_virtual_network_gateway_vpnclient_ipsec_parameters.py | sebtelko/pulumi-azure-native | 711ec021b5c73da05611c56c8a35adb0ce3244e4 | [
"Apache-2.0"
] | null | null | null | sdk/python/pulumi_azure_native/network/v20200701/get_virtual_network_gateway_vpnclient_ipsec_parameters.py | sebtelko/pulumi-azure-native | 711ec021b5c73da05611c56c8a35adb0ce3244e4 | [
"Apache-2.0"
] | null | null | null | # coding=utf-8
# *** WARNING: this file was generated by the Pulumi SDK Generator. ***
# *** Do not edit by hand unless you're certain you know what you are doing! ***
import warnings
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
from ... import _utilities
__... | 43.10828 | 205 | 0.695035 |
794800983929868e97c60247f8df44c27ac6fc3d | 5,506 | py | Python | tests/test_image_to_ascii.py | emberati/ascii-art | 955360cea395f224d17dbb3f48ee49738a4f4014 | [
"MIT"
] | 25 | 2020-11-18T16:30:19.000Z | 2022-03-12T03:54:05.000Z | tests/test_image_to_ascii.py | emberati/ascii-art | 955360cea395f224d17dbb3f48ee49738a4f4014 | [
"MIT"
] | 3 | 2020-08-28T09:59:43.000Z | 2020-12-20T05:58:38.000Z | tests/test_image_to_ascii.py | emberati/ascii-art | 955360cea395f224d17dbb3f48ee49738a4f4014 | [
"MIT"
] | 9 | 2020-10-15T17:38:06.000Z | 2021-12-25T22:52:53.000Z | from pathlib import Path
from PIL import Image
from ascii_art import image_to_ascii
einstein = f"""??*??**???**?????????????;?;;;;?*#??**%#####@@###@@@@@@@@@##@#######SS****S###??*?.
?**??**??*?????????????;??;;,?*S#?;*%####@@@@@@@@@@@@@@@@@@@@@@######%#SS*S####*?*;.
***?***?????????... | 77.549296 | 115 | 0.081184 |
794800c65532dcfea40ee497a3fbd17d8a818d2d | 33,498 | py | Python | sdk/lusid/models/resource_list_of_get_index_convention_response.py | fossabot/lusid-sdk-python-preview | 2c95d870489d93dee921593877256d3869c090e6 | [
"MIT"
] | null | null | null | sdk/lusid/models/resource_list_of_get_index_convention_response.py | fossabot/lusid-sdk-python-preview | 2c95d870489d93dee921593877256d3869c090e6 | [
"MIT"
] | null | null | null | sdk/lusid/models/resource_list_of_get_index_convention_response.py | fossabot/lusid-sdk-python-preview | 2c95d870489d93dee921593877256d3869c090e6 | [
"MIT"
] | 1 | 2020-10-29T08:35:32.000Z | 2020-10-29T08:35:32.000Z | # coding: utf-8
"""
LUSID API
# Introduction This page documents the [LUSID APIs](https://www.lusid.com/api/swagger), which allows authorised clients to query and update their data within the LUSID platform. SDKs to interact with the LUSID APIs are available in the following languages : * [C#](https://gith... | 184.054945 | 28,439 | 0.685832 |
794801319b582d2eaef8d7df978ce1b0d46a51f9 | 79 | py | Python | nbsphinx_link/_version.py | madsmpedersen/nbsphinx-link | 9a55a92a6956c716cf341530cd3de1f9f389bf18 | [
"BSD-3-Clause"
] | null | null | null | nbsphinx_link/_version.py | madsmpedersen/nbsphinx-link | 9a55a92a6956c716cf341530cd3de1f9f389bf18 | [
"BSD-3-Clause"
] | null | null | null | nbsphinx_link/_version.py | madsmpedersen/nbsphinx-link | 9a55a92a6956c716cf341530cd3de1f9f389bf18 | [
"BSD-3-Clause"
] | null | null | null | version_info = (1, 1, 2, 'dev')
__version__ = ".".join(map(str, version_info))
| 26.333333 | 46 | 0.64557 |
7948016ccca9a31000f6563153725864c13c1188 | 214 | py | Python | algo_trading/signal_detector/urls.py | qz-fordham/algo-trading-microservice | 8778daeb90250f7c5c0e772c24d4912326850a37 | [
"MIT"
] | 1 | 2022-02-12T08:10:27.000Z | 2022-02-12T08:10:27.000Z | algo_trading/signal_detector/urls.py | qz-fordham/algo-trading-microservice | 8778daeb90250f7c5c0e772c24d4912326850a37 | [
"MIT"
] | null | null | null | algo_trading/signal_detector/urls.py | qz-fordham/algo-trading-microservice | 8778daeb90250f7c5c0e772c24d4912326850a37 | [
"MIT"
] | 1 | 2022-02-11T03:43:41.000Z | 2022-02-11T03:43:41.000Z | from django.urls import path
from . import views
# Routing
urlpatterns = [
# path('<str:ticker>/<int:span>/', views.sma_view, name='sma'),
path('', views.SignalDetectorView.as_view(), name='detector'),
]
| 21.4 | 67 | 0.668224 |
794801bd56fd3b515dcd5bf5498a7876f87f9fd3 | 26,203 | py | Python | venv/Lib/site-packages/sqlalchemy/sql/crud.py | YunJaePark3908/BaseAPIServer | 17ab922917541406a3c2d75b428614ce97152a16 | [
"Apache-2.0"
] | 1 | 2021-03-26T10:07:00.000Z | 2021-03-26T10:07:00.000Z | venv/Lib/site-packages/sqlalchemy/sql/crud.py | YunJaePark3908/BaseAPIServer | 17ab922917541406a3c2d75b428614ce97152a16 | [
"Apache-2.0"
] | 1 | 2021-09-28T04:53:41.000Z | 2021-09-28T04:53:41.000Z | venv/Lib/site-packages/sqlalchemy/sql/crud.py | YunJaePark3908/BaseAPIServer | 17ab922917541406a3c2d75b428614ce97152a16 | [
"Apache-2.0"
] | 3 | 2021-11-30T11:10:26.000Z | 2021-12-08T05:59:31.000Z | # sql/crud.py
# Copyright (C) 2005-2021 the SQLAlchemy authors and contributors
# <see AUTHORS file>
#
# This module is part of SQLAlchemy and is released under
# the MIT License: http://www.opensource.org/licenses/mit-license.php
"""Functions used by compiler.py to determine the parameters rendered
within INSERT and ... | 32.429455 | 79 | 0.602984 |
794802ec9a91fdcbe89ef923fa50ee9bd8bb5209 | 2,393 | py | Python | dzTraficoBackend/dzTrafico/BusinessEntities/Flow.py | DZAymen/dz-Trafico | 74ff9caf9e3845d8af977c46b04a2d3421a0661b | [
"MIT"
] | null | null | null | dzTraficoBackend/dzTrafico/BusinessEntities/Flow.py | DZAymen/dz-Trafico | 74ff9caf9e3845d8af977c46b04a2d3421a0661b | [
"MIT"
] | null | null | null | dzTraficoBackend/dzTrafico/BusinessEntities/Flow.py | DZAymen/dz-Trafico | 74ff9caf9e3845d8af977c46b04a2d3421a0661b | [
"MIT"
] | null | null | null | from rest_framework import serializers
from Location import Location, LocationSerializer
class Flow(object):
end_depart_time = 10000
# via_edges = "26322664#2"
via_edges = ""
def __init__(self, start, end, depart_time, flow_value):
self.start_edge = start
self.end_edge = end
sel... | 29.9125 | 60 | 0.642708 |
794802fe975600038aaffaee86a5b27b383e674e | 6,806 | py | Python | test/models/test_loaders.py | GHzytp/atomai | 30eab2e5b9cb508247341b1dea8215123b4bf995 | [
"MIT"
] | 69 | 2020-09-04T06:45:13.000Z | 2022-03-28T12:55:20.000Z | test/models/test_loaders.py | GHzytp/atomai | 30eab2e5b9cb508247341b1dea8215123b4bf995 | [
"MIT"
] | 24 | 2020-12-08T23:15:19.000Z | 2022-01-20T19:20:20.000Z | test/models/test_loaders.py | GHzytp/atomai | 30eab2e5b9cb508247341b1dea8215123b4bf995 | [
"MIT"
] | 13 | 2020-09-10T19:45:42.000Z | 2022-03-15T03:49:28.000Z | import sys
import numpy as np
import pytest
from numpy.testing import assert_, assert_array_equal, assert_equal
sys.path.append("../../../")
from atomai.models import (VAE, ImSpec, Segmentor, jrVAE, jVAE, load_ensemble,
load_model, load_pretrained_model, rVAE)
from atomai.trainers import E... | 36.395722 | 88 | 0.662651 |
79480372cae4a1aaac1a6aca825ed02d66c097a9 | 303 | py | Python | src/test_pset.py | CTimmerman/PyPico8 | a68c83ae5a9dc53221ab39d6e55bb68bb5a1e479 | [
"MIT"
] | null | null | null | src/test_pset.py | CTimmerman/PyPico8 | a68c83ae5a9dc53221ab39d6e55bb68bb5a1e479 | [
"MIT"
] | null | null | null | src/test_pset.py | CTimmerman/PyPico8 | a68c83ae5a9dc53221ab39d6e55bb68bb5a1e479 | [
"MIT"
] | null | null | null | from pypico8 import *
def _init():
fillp(1)
for y in range(129):
for x in range(129):
pset(x, y, 1 + 2 * 16)
rectfill(0, 0, 10, 10, 3 + 4 * 16)
circfill(64, 64, 10, 5 + 6 * 16)
ovalfill(80, 80, 90, 90, 7 + 8 * 16)
line(126, 0, 0, 126, 0 + 9*16)
run(_init) | 20.2 | 40 | 0.491749 |
794803b67170e3277ad5209c3c585223aa6a7aa5 | 399,183 | py | Python | modules/s3db/dvr.py | Mkgdukoo/aidiq | 840b97651d79352878d5a777067a915985617378 | [
"MIT"
] | 1 | 2018-06-06T12:11:25.000Z | 2018-06-06T12:11:25.000Z | modules/s3db/dvr.py | Mkgdukoo/aidiq | 840b97651d79352878d5a777067a915985617378 | [
"MIT"
] | null | null | null | modules/s3db/dvr.py | Mkgdukoo/aidiq | 840b97651d79352878d5a777067a915985617378 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
""" Sahana Eden Disaster Victim Registration Model
@copyright: 2012-2021 (c) Sahana Software Foundation
@license: MIT
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
files (the "Software"), to deal ... | 40.476881 | 184 | 0.412169 |
794805f6eaeb971030c2a10a20a764b88e94ae7e | 293 | py | Python | example/conanfile.py | thormme/imgui_sdl | 5d888cdcaf64a2f937e0710971e75219088d45f6 | [
"MIT"
] | null | null | null | example/conanfile.py | thormme/imgui_sdl | 5d888cdcaf64a2f937e0710971e75219088d45f6 | [
"MIT"
] | null | null | null | example/conanfile.py | thormme/imgui_sdl | 5d888cdcaf64a2f937e0710971e75219088d45f6 | [
"MIT"
] | null | null | null | from conans import ConanFile, CMake
class StrifeConan(ConanFile):
settings = "os", "compiler", "build_type", "arch"
requires = \
"sdl2/2.0.8@bincrafters/stable", \
"sdl2_image/2.0.3@bincrafters/stable", \
"imgui/1.62@bincrafters/stable"
generators = "cmake"
| 26.636364 | 52 | 0.645051 |
7948065b574978879735dc42a7ed6f8dce99ace9 | 856 | py | Python | course/models.py | oneofsunshine/OUCOJ | 68d9edf23346a30b1c6966045a0cb36abdddedfb | [
"MIT"
] | null | null | null | course/models.py | oneofsunshine/OUCOJ | 68d9edf23346a30b1c6966045a0cb36abdddedfb | [
"MIT"
] | 5 | 2021-06-08T21:55:26.000Z | 2022-03-12T00:38:42.000Z | course/models.py | oneofsunshine/OUCOJ | 68d9edf23346a30b1c6966045a0cb36abdddedfb | [
"MIT"
] | null | null | null | from django.db import models
from account.models import User
from contest.models import Contest
class Course(models.Model):
name = models.TextField()
s_year = models.CharField(max_length=4)
short_description = models.TextField(default="ownerless")
contests = models.ManyToManyField(Contest)
studen... | 29.517241 | 101 | 0.718458 |
794807174fb65d5d2b1754fccfcc4f0c80d8d68b | 6,550 | py | Python | tests/ui_tests/test_activatable_groups_ui_options_data/config_generator.py | dimuha-rs/adcm | 0f49cc9ece16c1e257be12375a64b65a34b3a3ae | [
"Apache-2.0"
] | null | null | null | tests/ui_tests/test_activatable_groups_ui_options_data/config_generator.py | dimuha-rs/adcm | 0f49cc9ece16c1e257be12375a64b65a34b3a3ae | [
"Apache-2.0"
] | null | null | null | tests/ui_tests/test_activatable_groups_ui_options_data/config_generator.py | dimuha-rs/adcm | 0f49cc9ece16c1e257be12375a64b65a34b3a3ae | [
"Apache-2.0"
] | null | null | null | import os
DATA = [(g_i, g_a, f_g, f_i, act) for g_i in [
'true', 'false'] for g_a in [
'true', 'false'] for f_g in [
'true', 'false'] for f_i in [
'true', 'false'] for act in [
'true', 'false'
]]
TYPES = ("string", "password", "integer", "text", 'boolean', 'float', 'option', 'list', 'map', 'json', ... | 23.309609 | 110 | 0.544885 |
7948072fe52b21c3eab620409b0c06b23986d74f | 78,098 | py | Python | parlai/mturk/core/dev/mturk_manager.py | whitemike889/ParlAI | 48187b7aaacea5f910719074fe78d13c409e6776 | [
"MIT"
] | 1 | 2019-07-25T17:30:18.000Z | 2019-07-25T17:30:18.000Z | parlai/mturk/core/dev/mturk_manager.py | abisee/ParlAI | 5507d4745ca23b23af311673a6b0d1b7e72eb5cd | [
"MIT"
] | null | null | null | parlai/mturk/core/dev/mturk_manager.py | abisee/ParlAI | 5507d4745ca23b23af311673a6b0d1b7e72eb5cd | [
"MIT"
] | 1 | 2019-07-28T14:53:18.000Z | 2019-07-28T14:53:18.000Z | #!/usr/bin/env python3
# Copyright (c) Facebook, Inc. and its affiliates.
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
import logging
import math
import os
import pickle
import threading
import time
import uuid
import errno
import requests... | 42.352495 | 90 | 0.597314 |
7948075596ed9ec404c366cc48003cf22bfdb57c | 52,825 | py | Python | pysnmp/Nortel-Magellan-Passport-X25TraceRcvrMIB.py | agustinhenze/mibs.snmplabs.com | 1fc5c07860542b89212f4c8ab807057d9a9206c7 | [
"Apache-2.0"
] | 11 | 2021-02-02T16:27:16.000Z | 2021-08-31T06:22:49.000Z | pysnmp/Nortel-Magellan-Passport-X25TraceRcvrMIB.py | agustinhenze/mibs.snmplabs.com | 1fc5c07860542b89212f4c8ab807057d9a9206c7 | [
"Apache-2.0"
] | 75 | 2021-02-24T17:30:31.000Z | 2021-12-08T00:01:18.000Z | pysnmp/Nortel-Magellan-Passport-X25TraceRcvrMIB.py | agustinhenze/mibs.snmplabs.com | 1fc5c07860542b89212f4c8ab807057d9a9206c7 | [
"Apache-2.0"
] | 10 | 2019-04-30T05:51:36.000Z | 2022-02-16T03:33:41.000Z | #
# PySNMP MIB module Nortel-Magellan-Passport-X25TraceRcvrMIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/Nortel-Magellan-Passport-X25TraceRcvrMIB
# Produced by pysmi-0.3.4 at Mon Apr 29 20:19:26 2019
# On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davw... | 179.676871 | 8,901 | 0.775523 |
7948077f51ef43c4716525281468ba3414bcf24a | 2,118 | py | Python | 2020/17/17 _part_1.py | Sveder/advent_of_code | 57a36bc3066fcba6330d4d579de053e8b7e78c74 | [
"CC0-1.0"
] | null | null | null | 2020/17/17 _part_1.py | Sveder/advent_of_code | 57a36bc3066fcba6330d4d579de053e8b7e78c74 | [
"CC0-1.0"
] | null | null | null | 2020/17/17 _part_1.py | Sveder/advent_of_code | 57a36bc3066fcba6330d4d579de053e8b7e78c74 | [
"CC0-1.0"
] | null | null | null | import copy
import itertools
input = """###..#..
.#######
#####...
#..##.#.
###..##.
##...#..
..#...#.
.#....##"""
#
# input = """.#.
# ..#
# ###"""
W = H = 3
cycles_count = 6
def step(world):
size = len(world[0])
new_size = size + 1
new_world = copy.deepcopy(world)
# RESIZE PART:
# Add new pla... | 21.835052 | 83 | 0.487252 |
7948091978e96e950dde7414eec430e6cf6f7ea3 | 3,096 | py | Python | qd_english/qd_english/settings.py | smujm/ScrapyProjects | 04e9eb42c64805475893be595db4f3b6530ba597 | [
"MIT"
] | null | null | null | qd_english/qd_english/settings.py | smujm/ScrapyProjects | 04e9eb42c64805475893be595db4f3b6530ba597 | [
"MIT"
] | null | null | null | qd_english/qd_english/settings.py | smujm/ScrapyProjects | 04e9eb42c64805475893be595db4f3b6530ba597 | [
"MIT"
] | null | null | null | # Scrapy settings for qd_english project
#
# For simplicity, this file contains only settings considered important or
# commonly used. You can find more settings consulting the documentation:
#
# https://docs.scrapy.org/en/latest/topics/settings.html
# https://docs.scrapy.org/en/latest/topics/downloader-middlew... | 34.786517 | 103 | 0.780039 |
794809beee4a05ad36743f08bdfb1b86720338b0 | 3,082 | py | Python | test/database_test.py | lvzheqi/StreamingEventCompliance | 3a9470f9b0b670c814864369f22e1f1eacef7bad | [
"BSD-2-Clause"
] | 3 | 2018-10-16T15:14:41.000Z | 2019-09-04T09:38:55.000Z | test/database_test.py | lvzheqi/StreamingEventCompliance | 3a9470f9b0b670c814864369f22e1f1eacef7bad | [
"BSD-2-Clause"
] | 2 | 2021-03-31T19:00:14.000Z | 2021-12-13T19:51:46.000Z | test/database_test.py | lvzheqi/StreamingEventCompliance | 3a9470f9b0b670c814864369f22e1f1eacef7bad | [
"BSD-2-Clause"
] | 2 | 2018-10-16T15:14:43.000Z | 2019-12-16T13:58:28.000Z | import unittest
from streaming_event_compliance.database import dbtools
from streaming_event_compliance.objects.automata import automata, alertlog
from streaming_event_compliance import app
class DBToolsTest(unittest.TestCase):
def setUp(self):
dbtools.empty_tables()
def create_automata(self):
... | 43.408451 | 90 | 0.629786 |
794809f9cec19936467c6329b9bb3362b22dd70a | 629 | py | Python | sample-input-h2.py | trex47/MD-copy | 915919ce1f541f93d35ebfa1461350d861a3e6a7 | [
"BSD-3-Clause"
] | 1 | 2021-03-25T09:13:16.000Z | 2021-03-25T09:13:16.000Z | sample-input-h2.py | trex47/MD-copy | 915919ce1f541f93d35ebfa1461350d861a3e6a7 | [
"BSD-3-Clause"
] | null | null | null | sample-input-h2.py | trex47/MD-copy | 915919ce1f541f93d35ebfa1461350d861a3e6a7 | [
"BSD-3-Clause"
] | 1 | 2020-12-02T19:04:32.000Z | 2020-12-02T19:04:32.000Z | from mmd.molecule import Molecule
from mmd.postscf import PostSCF
import numpy as np
h2 = """
0 1
H 0.000000000 0.000000000 -0.368652
H 0.000000000 0.000000000 0.368652
"""
# init molecule and build integrals
mol = Molecule(geometry=h2,basis='6-311G**')
# do the SCF
mol.RHF()
# do MP2
PostSCF(mol)... | 17.971429 | 67 | 0.666137 |
79480add2be70cf64764691383e0508c1acd78a7 | 8,894 | py | Python | telemetry/telemetry/internal/results/page_test_results_unittest.py | Martijnve23/catapult | 5c63b19d221af6a12889e8727acc85d93892cab7 | [
"BSD-3-Clause"
] | 1,894 | 2015-04-17T18:29:53.000Z | 2022-03-28T22:41:06.000Z | telemetry/telemetry/internal/results/page_test_results_unittest.py | Martijnve23/catapult | 5c63b19d221af6a12889e8727acc85d93892cab7 | [
"BSD-3-Clause"
] | 4,640 | 2015-07-08T16:19:08.000Z | 2019-12-02T15:01:27.000Z | telemetry/telemetry/internal/results/page_test_results_unittest.py | Martijnve23/catapult | 5c63b19d221af6a12889e8727acc85d93892cab7 | [
"BSD-3-Clause"
] | 698 | 2015-06-02T19:18:35.000Z | 2022-03-29T16:57:15.000Z | # Copyright 2014 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
from __future__ import absolute_import
import json
import shutil
import sys
import tempfile
import unittest
import mock
from telemetry.core import exceptio... | 37.058333 | 80 | 0.687317 |
79480bb8ba3893543d8703504ba1500af9d3edb4 | 8,222 | py | Python | test/pybind_test/single_node_test.py | xjqbest/HugeCTR | 0b1c92d5e65891dfdd90d917bc6d520d0ca5d1e1 | [
"Apache-2.0"
] | 130 | 2021-10-11T11:55:28.000Z | 2022-03-31T21:53:07.000Z | test/pybind_test/single_node_test.py | xjqbest/HugeCTR | 0b1c92d5e65891dfdd90d917bc6d520d0ca5d1e1 | [
"Apache-2.0"
] | 72 | 2021-10-09T04:59:09.000Z | 2022-03-31T11:27:54.000Z | test/pybind_test/single_node_test.py | xjqbest/HugeCTR | 0b1c92d5e65891dfdd90d917bc6d520d0ca5d1e1 | [
"Apache-2.0"
] | 29 | 2021-11-03T22:35:01.000Z | 2022-03-30T13:11:59.000Z | import hugectr
import json
import sys
import argparse
DATA_READER_TYPE = {"Norm": hugectr.DataReaderType_t.Norm,
"Raw": hugectr.DataReaderType_t.Raw,
"Parquet": hugectr.DataReaderType_t.Parquet}
CHECK_TYPE = {"Sum": hugectr.Check_t.Sum,
"None": hugectr.Check_t.Non}... | 47.802326 | 125 | 0.653369 |
79480c31164cbab7a3ac8ce70cda95d80b18aec2 | 808 | py | Python | manage.py | boxed/related_how | 9184b36fd07233426f80adde294eea0b2dfa8c7c | [
"BSD-3-Clause"
] | 2 | 2020-06-04T18:04:33.000Z | 2021-04-09T14:39:59.000Z | manage.py | boxed/relatedhow | 9184b36fd07233426f80adde294eea0b2dfa8c7c | [
"BSD-3-Clause"
] | null | null | null | manage.py | boxed/relatedhow | 9184b36fd07233426f80adde294eea0b2dfa8c7c | [
"BSD-3-Clause"
] | null | null | null | #!/usr/bin/env python
import os
import sys
if __name__ == "__main__":
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "relatedhow.settings")
try:
from django.core.management import execute_from_command_line
except ImportError:
# The above import may fail for some other reason. Ensure that t... | 35.130435 | 77 | 0.643564 |
79480c5fd27378c21569e9f5db1f3471d679145b | 3,497 | py | Python | BriVL-code-inference/evaluation/XYB_box_extract.py | BAAI-WuDao/BriVL | bb8d95b230e692b2669a4234bb454f75d66a5e5b | [
"MIT"
] | 130 | 2021-08-18T07:44:10.000Z | 2022-03-28T02:10:40.000Z | BriVL-code-inference/evaluation/XYB_box_extract.py | FesianXu/BriVL | 8d2c2487284f4b5c015fa3cc19b99c9171cc1ffa | [
"MIT"
] | 12 | 2021-08-31T07:27:53.000Z | 2021-12-24T07:27:58.000Z | BriVL-code-inference/evaluation/XYB_box_extract.py | FesianXu/BriVL | 8d2c2487284f4b5c015fa3cc19b99c9171cc1ffa | [
"MIT"
] | 19 | 2021-09-02T06:34:24.000Z | 2022-03-23T01:47:39.000Z | import sys
import os
sys.path.append(os.path.abspath(os.path.dirname(os.path.realpath(__file__))+'/'+'..'))
import os
import time
import argparse
import torch
import json
from tqdm import tqdm
import math
import numpy as np
import random
from utils import getLanMask
from models import build_network
from dataset impor... | 32.990566 | 103 | 0.697455 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.