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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
7956725b7b05c80f94a04b71cb40587319a509c5 | 4,852 | py | Python | python/ray/internal/internal_api.py | Crissman/ray | 2092b097eab41b118a117fdfadd0fe664db41f63 | [
"Apache-2.0"
] | 3 | 2021-06-22T19:57:41.000Z | 2021-06-23T07:16:44.000Z | python/ray/internal/internal_api.py | h453693821/ray | 9eb79727aa6ad94b01f8b660b83e1182555a89f6 | [
"Apache-2.0"
] | 72 | 2021-02-06T08:07:16.000Z | 2022-03-26T07:17:49.000Z | python/ray/internal/internal_api.py | h453693821/ray | 9eb79727aa6ad94b01f8b660b83e1182555a89f6 | [
"Apache-2.0"
] | 2 | 2021-05-05T21:05:16.000Z | 2021-06-22T21:16:03.000Z | import ray
import ray.worker
from ray import profiling
__all__ = ["free", "global_gc"]
MAX_MESSAGE_LENGTH = ray._config.max_grpc_message_size()
def global_gc():
"""Trigger gc.collect() on all workers in the cluster."""
worker = ray.worker.global_worker
worker.core_worker.global_gc()
def memory_summary... | 40.099174 | 78 | 0.643446 |
795673df415307148cd68265b981e0cfbde63702 | 25,225 | py | Python | src/dataset_SGFN.py | orsveri/3DSSG | 9f0bb09389769e0a0bf7e85eb997545fe2221049 | [
"BSD-2-Clause"
] | 38 | 2021-05-06T14:22:17.000Z | 2022-03-22T06:07:01.000Z | src/dataset_SGFN.py | orsveri/3DSSG | 9f0bb09389769e0a0bf7e85eb997545fe2221049 | [
"BSD-2-Clause"
] | 23 | 2021-05-11T08:44:56.000Z | 2022-02-26T18:08:22.000Z | src/dataset_SGFN.py | orsveri/3DSSG | 9f0bb09389769e0a0bf7e85eb997545fe2221049 | [
"BSD-2-Clause"
] | 7 | 2021-07-16T08:20:33.000Z | 2022-03-24T14:36:43.000Z | if __name__ == '__main__' and __package__ is None:
from os import sys
sys.path.append('../')
import torch.utils.data as data
import os, random, torch, json, trimesh
import numpy as np
import multiprocessing as mp
from utils import util_ply, util_data, util, define
from data_processing import compute_weigh... | 44.09965 | 147 | 0.561863 |
795673fe837cb2f4214b4cd7ea37670c9c2af46b | 1,979 | py | Python | osrsmath/examples/combat/old/part_II/models/generate.py | Palfore/OSRSmath | 373eb1e7f9702b98de318b3c708084353626a177 | [
"MIT"
] | 5 | 2020-06-30T06:51:25.000Z | 2021-11-16T01:04:48.000Z | osrsmath/examples/combat/old/part_II/models/generate.py | Palfore/OSRS-Combat | 373eb1e7f9702b98de318b3c708084353626a177 | [
"MIT"
] | 15 | 2020-06-19T14:36:38.000Z | 2021-04-16T16:17:08.000Z | osrsmath/examples/combat/old/part_II/models/generate.py | Palfore/OSRS-Combat | 373eb1e7f9702b98de318b3c708084353626a177 | [
"MIT"
] | null | null | null | from osrsmath.results.part_II.colors import colors
from osrsmath.combat.successful_hits import *
from osrsmath.results.part_II.generate_simulation import load_dataset
from pprint import pprint
from mpl_toolkits.mplot3d import Axes3D
import matplotlib.pyplot as plt
import numpy as np
import sys
import os
import... | 34.719298 | 105 | 0.67812 |
795674217f4c430d92705508e74ef26923c3a3ec | 1,066 | py | Python | .repo_tools/.repo_tmpl/svg_to_json.py | dnegorov/test-git | 3427ec94b7ca3c72a6eb108e523853fc0fa958d2 | [
"MIT"
] | null | null | null | .repo_tools/.repo_tmpl/svg_to_json.py | dnegorov/test-git | 3427ec94b7ca3c72a6eb108e523853fc0fa958d2 | [
"MIT"
] | null | null | null | .repo_tools/.repo_tmpl/svg_to_json.py | dnegorov/test-git | 3427ec94b7ca3c72a6eb108e523853fc0fa958d2 | [
"MIT"
] | null | null | null | import argparse
import json
parser = argparse.ArgumentParser(add_help=True,
description="SVG to JSON")
parent_parser = argparse.ArgumentParser(add_help=False)
parser.add_argument("-v", "--verbose", action="store_true",
help="increase output verbosity")
parser.add_a... | 26.65 | 89 | 0.625704 |
795674466c631d88b9ff440e35b7215e1f7a985b | 1,719 | py | Python | docker_links/internals.py | wlonk/docker_links | 387485bfd6cc73a86b624abda5be7dc9e3ed1c2c | [
"BSD-3-Clause"
] | null | null | null | docker_links/internals.py | wlonk/docker_links | 387485bfd6cc73a86b624abda5be7dc9e3ed1c2c | [
"BSD-3-Clause"
] | null | null | null | docker_links/internals.py | wlonk/docker_links | 387485bfd6cc73a86b624abda5be7dc9e3ed1c2c | [
"BSD-3-Clause"
] | 1 | 2019-11-23T15:53:00.000Z | 2019-11-23T15:53:00.000Z | # -*- coding: utf-8 -*-
import os
try:
import urlparse
except ImportError:
import urllib.parse as urlparse
def docker_link(env_variable, overrides=None):
if overrides is None:
overrides = {}
url = urlparse(os.environ.get(env_variable, ''))
return _docker_link_helper(
url_to_dict(ur... | 23.22973 | 65 | 0.571262 |
795674ab322e56eda3c541b6f4942e886fab7300 | 6,674 | py | Python | mcutils/input_validation.py | macanepa/mcutils | 16e71f93ce61d76a16092af8c38928036a4ef409 | [
"MIT"
] | null | null | null | mcutils/input_validation.py | macanepa/mcutils | 16e71f93ce61d76a16092af8c38928036a4ef409 | [
"MIT"
] | null | null | null | mcutils/input_validation.py | macanepa/mcutils | 16e71f93ce61d76a16092af8c38928036a4ef409 | [
"MIT"
] | null | null | null | from .print_manager import mcprint, Color
import logging
def exit_application(text: str = None, enter_quit: bool =False):
"""Exit application
Args:
text (str): Text to display before exiting
enter_quit (bool): If true, user must press enter before exiting
"""
if text:
mcprint(... | 40.695122 | 118 | 0.567126 |
795675ad0ee581131e303a292d2c734522f2729e | 309 | py | Python | ecstremity/registries/registry.py | ddmills/ECStremity | afe36ea596c9fe75f8c44576459d5dd2422ec579 | [
"MIT"
] | null | null | null | ecstremity/registries/registry.py | ddmills/ECStremity | afe36ea596c9fe75f8c44576459d5dd2422ec579 | [
"MIT"
] | null | null | null | ecstremity/registries/registry.py | ddmills/ECStremity | afe36ea596c9fe75f8c44576459d5dd2422ec579 | [
"MIT"
] | null | null | null | from __future__ import annotations
from typing import *
from collections import defaultdict
if TYPE_CHECKING:
from engine import Engine, EngineAdapter
class Registry(defaultdict):
def __init__(self, ecs: Union[Engine, EngineAdapter]) -> None:
self.ecs: Union[Engine, EngineAdapter] = ecs
| 22.071429 | 66 | 0.754045 |
795675c114f315da527de79c8c869b63c38470ff | 8,932 | py | Python | pru/db/io.py | euctrl-pru/rt-python | da5d0040e250bd159845a0d43bf0b73eab368863 | [
"MIT"
] | null | null | null | pru/db/io.py | euctrl-pru/rt-python | da5d0040e250bd159845a0d43bf0b73eab368863 | [
"MIT"
] | null | null | null | pru/db/io.py | euctrl-pru/rt-python | da5d0040e250bd159845a0d43bf0b73eab368863 | [
"MIT"
] | null | null | null | # Copyright (c) 2018 Via Technology Ltd. All Rights Reserved.
# Consult your license regarding permissions and restrictions.
"""
A python module that reads csv or geojson data files including
sectors, airports and fleet data.
"""
import csv
from pathlib import Path
from shapely.geometry import shape
import geojson
d... | 28.44586 | 78 | 0.645544 |
795675dd2846cd79920511eb491ab9a6353b4fc1 | 1,666 | py | Python | scripts/wall_return.py | tomokiyasutome/pimouse_run_corridor | 24ec8938949656ff95735c5c598327e5ec931336 | [
"BSD-3-Clause"
] | null | null | null | scripts/wall_return.py | tomokiyasutome/pimouse_run_corridor | 24ec8938949656ff95735c5c598327e5ec931336 | [
"BSD-3-Clause"
] | null | null | null | scripts/wall_return.py | tomokiyasutome/pimouse_run_corridor | 24ec8938949656ff95735c5c598327e5ec931336 | [
"BSD-3-Clause"
] | null | null | null | #!/usr/bin/env python
#encoding: utf-8
import rospy,copy,math
from geometry_msgs.msg import Twist
from std_srvs.srv import Trigger, TriggerResponse
from pimouse_ros.msg import LightSensorValues
class WallReturn():
def __init__(self):
self.cmd_vel = rospy.Publisher('/cmd_vel',Twist,queue_size=1)
se... | 30.851852 | 75 | 0.617047 |
79567615e2ef8d39900e5758b5c2ab70c0e5f27b | 2,670 | py | Python | src/ZAMPATHA_1.1-insert_api_into_elasticsearch_strict.py | delavet/SOworkspace | 74bbcfa62c7e293b2b02f23249ac408aa22b44af | [
"MIT"
] | 6 | 2020-12-31T06:13:56.000Z | 2022-03-27T16:26:12.000Z | src/ZAMPATHA_1.1-insert_api_into_elasticsearch_strict.py | delavet/SOworkspace | 74bbcfa62c7e293b2b02f23249ac408aa22b44af | [
"MIT"
] | null | null | null | src/ZAMPATHA_1.1-insert_api_into_elasticsearch_strict.py | delavet/SOworkspace | 74bbcfa62c7e293b2b02f23249ac408aa22b44af | [
"MIT"
] | null | null | null | import json
from collections import OrderedDict
import networkx as nx
from nltk.util import pr
from tqdm import tqdm
from elasticsearch import Elasticsearch
from util.concept_map.common import get_latest_concept_map
from util.config import JAVADOC_GLOBAL_NAME, Elasticsearch_host, Elasticsearch_port, API_ELASTIC_DOC_MA... | 34.675325 | 136 | 0.666292 |
79567932ec56efd5c1366625561aff318db9c1f0 | 56 | py | Python | lessons/modules/package/__init__.py | aodarc/LIST-010 | 4579a047ca1ae0266f368349ea4536c6eb367f97 | [
"MIT"
] | null | null | null | lessons/modules/package/__init__.py | aodarc/LIST-010 | 4579a047ca1ae0266f368349ea4536c6eb367f97 | [
"MIT"
] | 4 | 2018-12-19T13:41:12.000Z | 2019-01-14T15:11:11.000Z | lessons/modules/package/__init__.py | aodarc/LIST-010 | 4579a047ca1ae0266f368349ea4536c6eb367f97 | [
"MIT"
] | null | null | null | print('Package INIT file')
from .module1 import INIT_P
| 14 | 27 | 0.767857 |
795679462a24c49973b9a50317036f44cab4721c | 63 | py | Python | miscellaneous/a_00_package_dot_path_import/package_1/dir_1/module_1.py | BigMountainTiger/python-excercise-repository | 52a240faa66742ac160c9858ec4bf6a0b51aa248 | [
"MIT"
] | null | null | null | miscellaneous/a_00_package_dot_path_import/package_1/dir_1/module_1.py | BigMountainTiger/python-excercise-repository | 52a240faa66742ac160c9858ec4bf6a0b51aa248 | [
"MIT"
] | 1 | 2022-03-12T01:02:10.000Z | 2022-03-12T01:02:10.000Z | miscellaneous/a_00_package_dot_path_import/package_1/dir_1/module_1.py | BigMountainTiger/python-excercise-repository | 52a240faa66742ac160c9858ec4bf6a0b51aa248 | [
"MIT"
] | null | null | null | from ..dir_2 import module_2
def print():
module_2.printIt() | 15.75 | 28 | 0.730159 |
79567a863a852bc8109c3d6ae686e504d8136992 | 5,530 | py | Python | fabfile/__init__.py | wbez/GradingRahm | 809c9ecff3c0e2d1d3093c2eadeb55fdc3f8628f | [
"FSFAP"
] | 1 | 2021-03-15T03:14:02.000Z | 2021-03-15T03:14:02.000Z | fabfile/__init__.py | busilogic/app-template | 3a8a963535fd084bbe21197e6b4b098723ff5db1 | [
"MIT"
] | 1 | 2015-01-26T17:50:56.000Z | 2015-01-26T17:50:56.000Z | fabfile/__init__.py | wbez/GradingRahm | 809c9ecff3c0e2d1d3093c2eadeb55fdc3f8628f | [
"FSFAP"
] | null | null | null | #!/usr/bin/env python
from fabric.api import local, require, settings, task
from fabric.state import env
from termcolor import colored
import app_config
# Other fabfiles
import assets
import data
import issues
import render
import text
import utils
if app_config.DEPLOY_TO_SERVERS:
import servers
if app_config.... | 23.733906 | 182 | 0.636709 |
79567b0b4f974589bb104a37abaafed12f335e03 | 2,121 | py | Python | dash/dashblocks/templatetags/dashblocks.py | Ilhasoft/dash | d9b900cc08d9238304a226d837a4c90dec6b46fc | [
"BSD-3-Clause"
] | 7 | 2015-06-25T20:09:35.000Z | 2019-02-12T17:41:46.000Z | dash/dashblocks/templatetags/dashblocks.py | Ilhasoft/dash | d9b900cc08d9238304a226d837a4c90dec6b46fc | [
"BSD-3-Clause"
] | 108 | 2015-01-05T13:23:57.000Z | 2022-02-10T10:55:01.000Z | dash/dashblocks/templatetags/dashblocks.py | rapidpro/dash | 71c8fcd1ab823ef31512b5ee22eca6158b3575c1 | [
"BSD-3-Clause"
] | 9 | 2015-06-15T15:13:13.000Z | 2019-01-09T18:34:20.000Z | from django import template
from django.conf import settings
from dash.dashblocks.models import DashBlock, DashBlockType
"""
This module offers one templatetag called ``load_dashblocks``.
``load_dashblocks`` does a query for all active DashBlock objects
for the passed in DashBlockType and Org on request. (identified... | 26.848101 | 97 | 0.711457 |
79567bf59d3c73ec1a14318b689daaec3746419e | 864 | py | Python | mmocr/utils/__init__.py | cuongngm/TableMASTER-mmocr | 77efbc420a80f257eb6947a076a50f61c72344bd | [
"Apache-2.0"
] | 206 | 2021-07-30T09:04:08.000Z | 2022-03-22T00:57:44.000Z | mmocr/utils/__init__.py | zezeze97/image2latex | c745667cd1af91dbff2385dcf2f2b80b9a40adb6 | [
"Apache-2.0"
] | 39 | 2021-08-05T07:16:46.000Z | 2022-03-14T13:23:48.000Z | mmocr/utils/__init__.py | zezeze97/image2latex | c745667cd1af91dbff2385dcf2f2b80b9a40adb6 | [
"Apache-2.0"
] | 61 | 2021-07-30T07:51:41.000Z | 2022-03-30T14:40:02.000Z | from mmcv.utils import Registry, build_from_cfg
from .check_argument import (equal_len, is_2dlist, is_3dlist, is_ndarray_list,
is_none_or_type, is_type_list, valid_boundary)
from .collect_env import collect_env
from .data_convert_util import convert_annotations
from .fileio import list_fro... | 45.473684 | 86 | 0.771991 |
79567d720cb8456c0c6bc8307f53cdfccec5645b | 2,335 | py | Python | workflow/scripts/collect_mod_scores.py | Ellison-Lab/TestisTEs2021 | b624d80b216d219701fd60e347c4d30271e8d3d6 | [
"MIT"
] | null | null | null | workflow/scripts/collect_mod_scores.py | Ellison-Lab/TestisTEs2021 | b624d80b216d219701fd60e347c4d30271e8d3d6 | [
"MIT"
] | null | null | null | workflow/scripts/collect_mod_scores.py | Ellison-Lab/TestisTEs2021 | b624d80b216d219701fd60e347c4d30271e8d3d6 | [
"MIT"
] | 1 | 2021-06-24T05:05:45.000Z | 2021-06-24T05:05:45.000Z | import pandas as pd
import scanpy as sc
import pyarrow.dataset as pads
params = pd.read_json("results/finalized/optimal-gep-params/larval-w1118-testes.json")
ds = pads.dataset("results/finalized/larval-w1118-testes/optimal_gep_membership/", format="arrow")
df = ds.to_table().to_pandas()
tep = df.loc[(df["module"] =... | 35.378788 | 120 | 0.732762 |
79567da2f99c23ad0531b53c4fd753fedbe88ecd | 27,570 | py | Python | utils/datasets.py | jiahuei/cisip-FIRe | bcbda2b74dc5a0b26f0338f707a257d660b688a1 | [
"BSD-3-Clause"
] | 25 | 2021-11-17T15:01:00.000Z | 2022-03-28T15:41:24.000Z | utils/datasets.py | jiahuei/cisip-FIRe | bcbda2b74dc5a0b26f0338f707a257d660b688a1 | [
"BSD-3-Clause"
] | 2 | 2021-11-25T13:11:10.000Z | 2021-12-28T16:15:07.000Z | utils/datasets.py | jiahuei/cisip-FIRe | bcbda2b74dc5a0b26f0338f707a257d660b688a1 | [
"BSD-3-Clause"
] | 4 | 2021-11-19T08:29:17.000Z | 2021-12-10T08:22:10.000Z | import logging
import os
from abc import ABC
from typing import Tuple, Any
import numpy as np
import torch
import torchvision
from pandas import read_csv
from torch.utils.data import Dataset, DataLoader
from torchvision.datasets import CIFAR10, CIFAR100
from torchvision.datasets.folder import pil_loader, accimage_load... | 33.377724 | 141 | 0.586942 |
79567f394e6fadb27c905f79b808c6e415a95ebb | 11,577 | py | Python | gaphor/core/styling/parser.py | milotype/gaphor | 58370f5f8a2460863265044eaafd9624622fcdff | [
"Apache-2.0"
] | null | null | null | gaphor/core/styling/parser.py | milotype/gaphor | 58370f5f8a2460863265044eaafd9624622fcdff | [
"Apache-2.0"
] | 1 | 2017-04-18T01:51:12.000Z | 2017-04-18T01:51:12.000Z | gaphor/core/styling/parser.py | milotype/gaphor | 58370f5f8a2460863265044eaafd9624622fcdff | [
"Apache-2.0"
] | null | null | null | """Parser for CSS selectors, based on the tinycss2 tokenizer.
Original module: cssselect2.parser
:copyright: (c) 2012 by Simon Sapin, 2017 by Guillaume Ayoub.
:license: BSD, see LICENSE for more details.
"""
from tinycss2 import parse_component_value_list
__all__ = ["parse"]
def parse(input, namespaces=None):
... | 29.684615 | 88 | 0.605338 |
79568083b0b0e39262ce2eb1bc28cc79cc9330b6 | 1,722 | py | Python | package/spack-py-brian/package.py | ctuning/ck-spack | 307934efce1be2d4f104251275c82fbc70127105 | [
"BSD-3-Clause"
] | 1 | 2018-07-17T07:45:09.000Z | 2018-07-17T07:45:09.000Z | package/spack-py-brian/package.py | ctuning/ck-spack | 307934efce1be2d4f104251275c82fbc70127105 | [
"BSD-3-Clause"
] | null | null | null | package/spack-py-brian/package.py | ctuning/ck-spack | 307934efce1be2d4f104251275c82fbc70127105 | [
"BSD-3-Clause"
] | null | null | null | ##############################################################################
# Copyright (c) 2013-2018, Lawrence Livermore National Security, LLC.
# Produced at the Lawrence Livermore National Laboratory.
#
# This file is part of Spack.
# Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved.
# LLNL-CODE-64... | 44.153846 | 78 | 0.660859 |
795680a8c66ef81d1137de841a8d5fba08f7c6d1 | 6,808 | py | Python | scripts/generate_docs.py | buldi/DIGITS | 97b8379aab7c83006548fd81fe7513cc9d48a34f | [
"BSD-3-Clause"
] | 1 | 2019-08-27T21:12:15.000Z | 2019-08-27T21:12:15.000Z | scripts/generate_docs.py | buldi/DIGITS | 97b8379aab7c83006548fd81fe7513cc9d48a34f | [
"BSD-3-Clause"
] | null | null | null | scripts/generate_docs.py | buldi/DIGITS | 97b8379aab7c83006548fd81fe7513cc9d48a34f | [
"BSD-3-Clause"
] | null | null | null | #!/usr/bin/env python
# Copyright (c) 2015, NVIDIA CORPORATION. All rights reserved.
import sys
import os.path
import time
from collections import defaultdict
# requires a custom version of Flask-Autodoc:
# pip install git+https://github.com/lukeyeager/flask-autodoc.git
from flask.ext.autodoc import Autodoc
# Add... | 30.392857 | 170 | 0.55567 |
795682d8e22dc8aaea144f94744f1feb1ddf0af6 | 2,227 | py | Python | aliyun-python-sdk-vpc/aliyunsdkvpc/request/v20160428/DescribeVpnConnectionRequest.py | jia-jerry/aliyun-openapi-python-sdk | e90f3683a250cfec5b681b5f1d73a68f0dc9970d | [
"Apache-2.0"
] | null | null | null | aliyun-python-sdk-vpc/aliyunsdkvpc/request/v20160428/DescribeVpnConnectionRequest.py | jia-jerry/aliyun-openapi-python-sdk | e90f3683a250cfec5b681b5f1d73a68f0dc9970d | [
"Apache-2.0"
] | 1 | 2020-05-31T14:51:47.000Z | 2020-05-31T14:51:47.000Z | aliyun-python-sdk-vpc/aliyunsdkvpc/request/v20160428/DescribeVpnConnectionRequest.py | jia-jerry/aliyun-openapi-python-sdk | e90f3683a250cfec5b681b5f1d73a68f0dc9970d | [
"Apache-2.0"
] | null | null | null | # Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not u... | 36.508197 | 79 | 0.778626 |
795683a50349b48481442a1754bbea66f79e4116 | 879 | py | Python | deep-rl/lib/python2.7/site-packages/OpenGL/raw/WGL/NV/render_depth_texture.py | ShujaKhalid/deep-rl | 99c6ba6c3095d1bfdab81bd01395ced96bddd611 | [
"MIT"
] | 210 | 2016-04-09T14:26:00.000Z | 2022-03-25T18:36:19.000Z | deep-rl/lib/python2.7/site-packages/OpenGL/raw/WGL/NV/render_depth_texture.py | ShujaKhalid/deep-rl | 99c6ba6c3095d1bfdab81bd01395ced96bddd611 | [
"MIT"
] | 72 | 2016-09-04T09:30:19.000Z | 2022-03-27T17:06:53.000Z | deep-rl/lib/python2.7/site-packages/OpenGL/raw/WGL/NV/render_depth_texture.py | ShujaKhalid/deep-rl | 99c6ba6c3095d1bfdab81bd01395ced96bddd611 | [
"MIT"
] | 64 | 2016-04-09T14:26:49.000Z | 2022-03-21T11:19:47.000Z | '''Autogenerated by xml_generate script, do not edit!'''
from OpenGL import platform as _p, arrays
# Code generation uses this
from OpenGL.raw.WGL import _types as _cs
# End users want this...
from OpenGL.raw.WGL._types import *
from OpenGL.raw.WGL import _errors
from OpenGL.constant import Constant as _C
import ctype... | 43.95 | 122 | 0.843003 |
7956847beaf1d3d028f1b684183a4db14f736c69 | 6,766 | py | Python | kibble/scanners/scanners/git-sync.py | michalslowikowski00/kibble | 1aa68040a70397b3aea7b26def912ad67d717b67 | [
"Apache-2.0"
] | 3 | 2020-10-07T10:36:20.000Z | 2020-10-24T20:43:02.000Z | kibble/scanners/scanners/git-sync.py | michalslowikowski00/kibble | 1aa68040a70397b3aea7b26def912ad67d717b67 | [
"Apache-2.0"
] | null | null | null | kibble/scanners/scanners/git-sync.py | michalslowikowski00/kibble | 1aa68040a70397b3aea7b26def912ad67d717b67 | [
"Apache-2.0"
] | null | null | null | # Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not u... | 38.662857 | 124 | 0.514336 |
795684aab53252c45fb143ce12694d8a3cd0d22c | 1,819 | py | Python | config.py | sysu-team1/BackEnd | 4773545897fee3aa7a767cbe6d011372623e1e58 | [
"MIT"
] | 1 | 2019-11-19T09:08:50.000Z | 2019-11-19T09:08:50.000Z | config.py | sysu-team1/BackEnd | 4773545897fee3aa7a767cbe6d011372623e1e58 | [
"MIT"
] | null | null | null | config.py | sysu-team1/BackEnd | 4773545897fee3aa7a767cbe6d011372623e1e58 | [
"MIT"
] | null | null | null | from tools.utils import make_pattern
from flask_uploads import IMAGES
# 主机的MySQL账号:密码:端口号/数据库
SQLALCHEMY_DATABASE_URI = 'mysql+mysqlconnector://root:mysql@localhost:3306/test2'
# SQLALCHEMY_DATABASE_URI = 'mysql+mysqlconnector://root:960919AB@localhost:3308/test2'
# SQLALCHEMY_DATABASE_URI = 'mysql+mysqlconnector://ro... | 39.543478 | 144 | 0.766355 |
795685074ca52085b92766bb1df7b17de087f045 | 477 | py | Python | great_expectations/render/renderer/content_block/__init__.py | joshuataylor/great_expectations | 19dcead43aef9a833b3aa894a1226714a80ab840 | [
"Apache-2.0"
] | 1 | 2021-05-04T17:26:22.000Z | 2021-05-04T17:26:22.000Z | great_expectations/render/renderer/content_block/__init__.py | joshuataylor/great_expectations | 19dcead43aef9a833b3aa894a1226714a80ab840 | [
"Apache-2.0"
] | 47 | 2020-07-15T06:32:50.000Z | 2022-03-29T12:03:23.000Z | great_expectations/render/renderer/content_block/__init__.py | joshuataylor/great_expectations | 19dcead43aef9a833b3aa894a1226714a80ab840 | [
"Apache-2.0"
] | null | null | null | from great_expectations.render.renderer.content_block.validation_results_table_content_block import (
ValidationResultsTableContentBlockRenderer,
)
from .bullet_list_content_block import ExpectationSuiteBulletListContentBlockRenderer
from .exception_list_content_block import ExceptionListContentBlockRenderer
from ... | 43.363636 | 101 | 0.901468 |
7956897d68a3fb49d62ba696d0b6400b4f909989 | 805 | py | Python | python/paddle/fluid/tests/unittests/test_sum_mkldnn_op.py | jerrywgz/Paddle | 85c4912755b783dd7554a9d6b9dae4a7e40371bc | [
"Apache-2.0"
] | 2 | 2018-07-05T14:37:36.000Z | 2018-07-05T14:37:42.000Z | python/paddle/fluid/tests/unittests/test_sum_mkldnn_op.py | jerrywgz/Paddle | 85c4912755b783dd7554a9d6b9dae4a7e40371bc | [
"Apache-2.0"
] | 3 | 2017-07-15T14:20:08.000Z | 2019-05-06T03:16:54.000Z | python/paddle/fluid/tests/unittests/test_sum_mkldnn_op.py | jerrywgz/Paddle | 85c4912755b783dd7554a9d6b9dae4a7e40371bc | [
"Apache-2.0"
] | 1 | 2018-07-20T07:13:31.000Z | 2018-07-20T07:13:31.000Z | # Copyright (c) 2018 PaddlePaddle 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 appli... | 29.814815 | 74 | 0.751553 |
795689a3715af481e9356dd1c7760711561efede | 148 | py | Python | dropblock/__init__.py | transcendentsky/latent-augment | 50f43fdf9f4ab18e5a1976d873f27be3f7cddab6 | [
"MIT"
] | 556 | 2018-11-03T08:46:31.000Z | 2022-03-28T08:39:31.000Z | dropblock/__init__.py | transcendentsky/latent-augment | 50f43fdf9f4ab18e5a1976d873f27be3f7cddab6 | [
"MIT"
] | 34 | 2018-11-08T05:37:16.000Z | 2022-01-25T04:05:42.000Z | dropblock/__init__.py | transcendentsky/latent-augment | 50f43fdf9f4ab18e5a1976d873f27be3f7cddab6 | [
"MIT"
] | 90 | 2018-11-06T09:03:41.000Z | 2022-03-25T09:30:36.000Z | from .dropblock import DropBlock2D, DropBlock3D
from .scheduler import LinearScheduler
__all__ = ['DropBlock2D', 'DropBlock3D', 'LinearScheduler']
| 29.6 | 59 | 0.804054 |
79568a759b9c7ec37a7adc62c1d5ced122d99786 | 2,580 | py | Python | VimbaCam/ColorMap/ehtplot/ehtplot/extra/metroize.py | zzpwahaha/VimbaCamJILA | 3baed1b5313e6c198d54a33c2c84357035d5146a | [
"MIT"
] | 1 | 2021-06-14T11:51:37.000Z | 2021-06-14T11:51:37.000Z | VimbaCam/ColorMap/ehtplot/ehtplot/extra/metroize.py | zzpwahaha/VimbaCamJILA | 3baed1b5313e6c198d54a33c2c84357035d5146a | [
"MIT"
] | null | null | null | VimbaCam/ColorMap/ehtplot/ehtplot/extra/metroize.py | zzpwahaha/VimbaCamJILA | 3baed1b5313e6c198d54a33c2c84357035d5146a | [
"MIT"
] | 2 | 2021-01-20T16:22:57.000Z | 2021-02-14T12:31:02.000Z | # Copyright (C) 2018 Chi-kwan Chan
# Copyright (C) 2018 Steward Observatory
#
# This file is part of ehtplot.
#
# ehtplot is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (... | 33.506494 | 76 | 0.546512 |
79568b44301cecffd209da399346ed16c72b3863 | 1,688 | py | Python | python/ray/serve/examples/echo_batching.py | vermashresth/ray | 9aaaa508cacb90a5be714478970b2191aaa43170 | [
"Apache-2.0"
] | null | null | null | python/ray/serve/examples/echo_batching.py | vermashresth/ray | 9aaaa508cacb90a5be714478970b2191aaa43170 | [
"Apache-2.0"
] | null | null | null | python/ray/serve/examples/echo_batching.py | vermashresth/ray | 9aaaa508cacb90a5be714478970b2191aaa43170 | [
"Apache-2.0"
] | null | null | null | """
This example has backend which has batching functionality enabled.
"""
import ray
from ray import serve
from ray.serve import BackendConfig
class MagicCounter:
def __init__(self, increment):
self.increment = increment
@serve.accept_batch
def __call__(self, flask_request, base_number=None):
... | 29.614035 | 79 | 0.685427 |
79568b6e2e43e78c190df693a041cf0565e5e485 | 71,331 | py | Python | flink-python/pyflink/table/table_environment.py | arunjoykalathoor/flink | f171b9e33dccb5ec49f6b01ab505d0b4f526456c | [
"MIT",
"Apache-2.0",
"MIT-0",
"BSD-3-Clause"
] | 1 | 2021-10-16T00:48:35.000Z | 2021-10-16T00:48:35.000Z | flink-python/pyflink/table/table_environment.py | arunjoykalathoor/flink | f171b9e33dccb5ec49f6b01ab505d0b4f526456c | [
"MIT",
"Apache-2.0",
"MIT-0",
"BSD-3-Clause"
] | null | null | null | flink-python/pyflink/table/table_environment.py | arunjoykalathoor/flink | f171b9e33dccb5ec49f6b01ab505d0b4f526456c | [
"MIT",
"Apache-2.0",
"MIT-0",
"BSD-3-Clause"
] | 1 | 2021-03-06T15:38:45.000Z | 2021-03-06T15:38:45.000Z | ################################################################################
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this... | 43.707721 | 100 | 0.61753 |
79568bc81cdce983135cb747e3ba5214fd659d35 | 2,104 | py | Python | pylol/env/base_env_wrapper.py | jjlee0802cu/pylol | d2fc3bd6eed7546ed06481dfe5b1e4a0ddabe8e5 | [
"MIT"
] | 7 | 2020-11-09T12:49:23.000Z | 2022-03-14T22:22:50.000Z | pylol/env/base_env_wrapper.py | jjlee0802cu/pylol | d2fc3bd6eed7546ed06481dfe5b1e4a0ddabe8e5 | [
"MIT"
] | null | null | null | pylol/env/base_env_wrapper.py | jjlee0802cu/pylol | d2fc3bd6eed7546ed06481dfe5b1e4a0ddabe8e5 | [
"MIT"
] | 1 | 2022-03-30T08:26:22.000Z | 2022-03-30T08:26:22.000Z | # MIT License
#
# Copyright (c) 2020 MiscellaneousStuff
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy,... | 40.461538 | 81 | 0.690589 |
79568c9858c36468c3bf293de109e080a982004e | 34,858 | py | Python | src/main/python/smart/smartplots2_setup.py | cday97/beam | 7e1ab50eecaefafd04daab360f8b12bc7cab559b | [
"BSD-3-Clause-LBNL"
] | 123 | 2017-04-06T20:17:19.000Z | 2022-03-02T13:42:15.000Z | src/main/python/smart/smartplots2_setup.py | cday97/beam | 7e1ab50eecaefafd04daab360f8b12bc7cab559b | [
"BSD-3-Clause-LBNL"
] | 2,676 | 2017-04-26T20:27:27.000Z | 2022-03-31T16:39:53.000Z | src/main/python/smart/smartplots2_setup.py | cday97/beam | 7e1ab50eecaefafd04daab360f8b12bc7cab559b | [
"BSD-3-Clause-LBNL"
] | 60 | 2017-04-06T20:14:32.000Z | 2022-03-30T20:10:53.000Z | import matplotlib
import sys
import pandas as pd
import matplotlib.pyplot as plt
import numpy as np
import matplotlib.patches as mpatches
import matplotlib.lines as mlines
import os
plt.style.use('seaborn-colorblind')
# plt.style.use('ggplot')
plt.rcParams['axes.edgecolor'] = 'black'
plt.rcParams['axes.facecolor'] = '... | 54.636364 | 197 | 0.676774 |
79568cd059780dfd11f62dc6bdd5fb83d72b9710 | 683 | py | Python | AC02/payRent.py | rafaxtd/URI-Judge | 37a5eae0debd87f6a74323a64e98d9fb8e18d976 | [
"MIT"
] | null | null | null | AC02/payRent.py | rafaxtd/URI-Judge | 37a5eae0debd87f6a74323a64e98d9fb8e18d976 | [
"MIT"
] | null | null | null | AC02/payRent.py | rafaxtd/URI-Judge | 37a5eae0debd87f6a74323a64e98d9fb8e18d976 | [
"MIT"
] | null | null | null | rent = int(input())
pay = int(input())
payment = 1
if rent > pay:
while rent != 0:
print(f'pagamento: {payment}')
print(f'antes = {rent}')
rent -= pay
print(f'depois = {rent}')
print('-----')
payment += 1
if rent == 0:
break
... | 16.261905 | 42 | 0.401171 |
79568d2cdac6268f8ea2755b8776750a55769bd1 | 2,115 | py | Python | pyiron_base/job/external.py | pmrv/pyiron_base | af1729708a8226575ca2c84f574e7cb046b7f7cd | [
"BSD-3-Clause"
] | null | null | null | pyiron_base/job/external.py | pmrv/pyiron_base | af1729708a8226575ca2c84f574e7cb046b7f7cd | [
"BSD-3-Clause"
] | null | null | null | pyiron_base/job/external.py | pmrv/pyiron_base | af1729708a8226575ca2c84f574e7cb046b7f7cd | [
"BSD-3-Clause"
] | null | null | null | # coding: utf-8
# Copyright (c) Max-Planck-Institut für Eisenforschung GmbH - Computational Materials Design (CM) Department
# Distributed under the terms of "New BSD License", see the LICENSE file.
from __future__ import print_function
import json
from pathlib2 import Path
import warnings
from pyiron_base.generic.hdf... | 32.045455 | 108 | 0.629314 |
79568d93c8ad75366e34dc2c187606b40cb3dfda | 661 | py | Python | every_election/apps/organisations/migrations/0017_auto_20170113_1625.py | DemocracyClub/EveryElection | da8a561cb4a84d9b432b1508a68f8cfada3d9515 | [
"BSD-3-Clause"
] | 8 | 2017-06-29T10:11:33.000Z | 2019-12-16T16:17:51.000Z | every_election/apps/organisations/migrations/0017_auto_20170113_1625.py | DemocracyClub/EveryElection | da8a561cb4a84d9b432b1508a68f8cfada3d9515 | [
"BSD-3-Clause"
] | 1,300 | 2017-01-08T14:02:24.000Z | 2022-03-31T09:11:30.000Z | every_election/apps/organisations/migrations/0017_auto_20170113_1625.py | DemocracyClub/EveryElection | da8a561cb4a84d9b432b1508a68f8cfada3d9515 | [
"BSD-3-Clause"
] | 11 | 2017-02-04T10:48:04.000Z | 2021-01-27T15:07:55.000Z | # -*- coding: utf-8 -*-
# Generated by Django 1.10.2 on 2017-01-13 16:25
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [("organisations", "0016_auto_20170111_1741")]
operations = [
migrations.AlterField(
... | 27.541667 | 65 | 0.638427 |
79568e6cafa611a43bc208a9e4a9f8ea67965200 | 3,331 | py | Python | test/functional/wallet_zapwallettxes.py | bitcoin-money/bitcoinmoney | d208756366292fa7ab16b8f4b9f2dff9b8567bee | [
"MIT"
] | null | null | null | test/functional/wallet_zapwallettxes.py | bitcoin-money/bitcoinmoney | d208756366292fa7ab16b8f4b9f2dff9b8567bee | [
"MIT"
] | null | null | null | test/functional/wallet_zapwallettxes.py | bitcoin-money/bitcoinmoney | d208756366292fa7ab16b8f4b9f2dff9b8567bee | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
# Copyright (c) 2014-2017 The Bitcoin Money developers
# Distributed under the MIT software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
"""Test the zapwallettxes functionality.
- start two bitcoind nodes
- create two transactions on node 0 ... | 41.6375 | 112 | 0.707896 |
79568e6e8a3deb70b36dc16dc90db96dff140dc5 | 551 | py | Python | breached.py | zenux-dev/Cyheck | b52309085be8735b8dad39e8316dd6e6b3cc2e03 | [
"MIT"
] | null | null | null | breached.py | zenux-dev/Cyheck | b52309085be8735b8dad39e8316dd6e6b3cc2e03 | [
"MIT"
] | null | null | null | breached.py | zenux-dev/Cyheck | b52309085be8735b8dad39e8316dd6e6b3cc2e03 | [
"MIT"
] | 1 | 2021-09-14T05:36:35.000Z | 2021-09-14T05:36:35.000Z | import requests
word = 'However, someone else could have signed up using your email address. Read the explanation below.'
word2 = 'Oh no! Your email address has been leaked'
def check(email):
url = 'https://ashley.cynic.al/'
payload = {'email': email}
x = requests.post(url, data = payload)
... | 29 | 105 | 0.624319 |
79568f0a7d39ee78389d8c70e1d8967af18f492d | 6,537 | py | Python | bagpy-sbg/sbg_genpy/_SbgMagStatus.py | sergiobellido/bagpy | ba855b585c96442c21226dd4aa8bd12900fdbcf4 | [
"MIT"
] | null | null | null | bagpy-sbg/sbg_genpy/_SbgMagStatus.py | sergiobellido/bagpy | ba855b585c96442c21226dd4aa8bd12900fdbcf4 | [
"MIT"
] | null | null | null | bagpy-sbg/sbg_genpy/_SbgMagStatus.py | sergiobellido/bagpy | ba855b585c96442c21226dd4aa8bd12900fdbcf4 | [
"MIT"
] | null | null | null | # This Python file uses the following encoding: utf-8
"""autogenerated by genpy from sbg_driver/SbgMagStatus.msg. Do not edit."""
import codecs
import sys
python3 = True if sys.hexversion > 0x03000000 else False
import genpy
import struct
class SbgMagStatus(genpy.Message):
_md5sum = "057cf294623d5a0b037fdcc47f99e3c... | 35.145161 | 169 | 0.679058 |
79568f741f8a8896bfd1bec89b17e0a06218aa15 | 521 | py | Python | pdi/pdi.py | rodriguesfas/Vision-Computer | 9621f1020ea5f2f4dcabbb48e7fe2a4ef69c0ba5 | [
"MIT"
] | null | null | null | pdi/pdi.py | rodriguesfas/Vision-Computer | 9621f1020ea5f2f4dcabbb48e7fe2a4ef69c0ba5 | [
"MIT"
] | null | null | null | pdi/pdi.py | rodriguesfas/Vision-Computer | 9621f1020ea5f2f4dcabbb48e7fe2a4ef69c0ba5 | [
"MIT"
] | 1 | 2018-09-21T18:49:44.000Z | 2018-09-21T18:49:44.000Z | #coding: utf-8
#!/usr/bin/python
'''
REFERÊNCIAS:
<http://acodigo.blogspot.com.br/2013/05/procesamiento-de-imagenes-en-opencv.html>
@Author RodriguesFAS
@Date 26/09/2017
@Email <fasr@cin.ufpe.br> || <franciscosouzaacer@gmail.com>
@site <htpp://rodriguesfas.com.br>
'''
# Python 2/3 compatibility
from __future__ imp... | 17.965517 | 82 | 0.725528 |
795692b10bfcc8f4d21886b5beeb1ddb37b91738 | 24,534 | py | Python | src/sage/geometry/newton_polygon.py | vbraun/sage | 07d6c37d18811e2b377a9689790a7c5e24da16ba | [
"BSL-1.0"
] | 3 | 2016-06-19T14:48:31.000Z | 2022-01-28T08:46:01.000Z | src/sage/geometry/newton_polygon.py | vbraun/sage | 07d6c37d18811e2b377a9689790a7c5e24da16ba | [
"BSL-1.0"
] | null | null | null | src/sage/geometry/newton_polygon.py | vbraun/sage | 07d6c37d18811e2b377a9689790a7c5e24da16ba | [
"BSL-1.0"
] | 7 | 2021-11-08T10:01:59.000Z | 2022-03-03T11:25:52.000Z | """
Newton Polygons
This module implements finite Newton polygons and
infinite Newton polygons having a finite number of
slopes (and hence a last infinite slope).
"""
#############################################################################
# Copyright (C) 2013 Xavier Caruso <xavier.caruso@normalesup.org>
#
# ... | 32.495364 | 159 | 0.54076 |
795692bfefc55904b1ab140a046f29f1fc1baf65 | 3,113 | py | Python | src/oscar/views/decorators.py | highbiza/django-oscar | 7eba207a77e5dd56b04a63b9283a9d76da2f64ac | [
"BSD-3-Clause"
] | 1 | 2019-10-22T01:10:20.000Z | 2019-10-22T01:10:20.000Z | src/oscar/views/decorators.py | highbiza/django-oscar | 7eba207a77e5dd56b04a63b9283a9d76da2f64ac | [
"BSD-3-Clause"
] | 10 | 2020-05-11T20:33:31.000Z | 2022-03-12T00:24:28.000Z | src/oscar/views/decorators.py | highbiza/django-oscar | 7eba207a77e5dd56b04a63b9283a9d76da2f64ac | [
"BSD-3-Clause"
] | 3 | 2019-03-20T16:17:58.000Z | 2022-02-25T09:38:38.000Z | import collections
from functools import wraps
from django.contrib.auth.decorators import user_passes_test
from django.core.exceptions import PermissionDenied
from django.shortcuts import render
from django.urls import reverse_lazy
def check_permissions(user, permissions):
"""
Permissions can be a list or a ... | 37.963415 | 101 | 0.700289 |
795692eb59ae57c456578a5baa59e1cc8f279c2e | 12,554 | py | Python | 015-word2vec/skip-gram.py | MuhamedEssam/deeplearning | e6004da4df5d8d066f637dc471f4a0f590f3af1e | [
"Apache-2.0"
] | 22 | 2018-03-05T11:17:48.000Z | 2021-06-15T02:10:36.000Z | 015-word2vec/skip-gram.py | MuhamedEssam/deeplearning | e6004da4df5d8d066f637dc471f4a0f590f3af1e | [
"Apache-2.0"
] | 7 | 2018-03-10T10:17:30.000Z | 2018-04-23T00:57:39.000Z | 015-word2vec/skip-gram.py | deepcollege/deeplearning | e6004da4df5d8d066f637dc471f4a0f590f3af1e | [
"Apache-2.0"
] | 8 | 2018-03-06T01:21:31.000Z | 2021-06-15T02:10:37.000Z | # code is from https://github.com/tensorflow/tensorflow/blob/r1.7/tensorflow/examples/tutorials/word2vec/word2vec_basic.py
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import collections
import math
import os
import sys
import argparse
import random
from ... | 39.109034 | 122 | 0.685519 |
795693317f2f3b7de6f16769627947881070a31a | 3,926 | py | Python | mockups/godlike/Ui_aranduka.py | webmedic/booker | e4d0e8c7b7c3d8c664c760ec9458ec306a0e1116 | [
"MIT"
] | null | null | null | mockups/godlike/Ui_aranduka.py | webmedic/booker | e4d0e8c7b7c3d8c664c760ec9458ec306a0e1116 | [
"MIT"
] | null | null | null | mockups/godlike/Ui_aranduka.py | webmedic/booker | e4d0e8c7b7c3d8c664c760ec9458ec306a0e1116 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
# Form implementation generated from reading ui file '/home/godlike/eric/aranduka/aranduka.ui'
#
# Created: Wed Sep 1 00:32:14 2010
# by: PyQt4 UI code generator 4.7.3
#
# WARNING! All changes made in this file will be lost!
from PyQt4 import QtCore, QtGui
class Ui_MainWindow(object):
... | 52.346667 | 163 | 0.736373 |
795693cc5e3df178d55e80d4940be1b7f5210570 | 55 | py | Python | enthought/pyface/ui/qt4/timer/timer.py | enthought/etsproxy | 4aafd628611ebf7fe8311c9d1a0abcf7f7bb5347 | [
"BSD-3-Clause"
] | 3 | 2016-12-09T06:05:18.000Z | 2018-03-01T13:00:29.000Z | enthought/pyface/ui/qt4/timer/timer.py | enthought/etsproxy | 4aafd628611ebf7fe8311c9d1a0abcf7f7bb5347 | [
"BSD-3-Clause"
] | 1 | 2020-12-02T00:51:32.000Z | 2020-12-02T08:48:55.000Z | enthought/pyface/ui/qt4/timer/timer.py | enthought/etsproxy | 4aafd628611ebf7fe8311c9d1a0abcf7f7bb5347 | [
"BSD-3-Clause"
] | null | null | null | # proxy module
from pyface.ui.qt4.timer.timer import *
| 18.333333 | 39 | 0.763636 |
79569405ffdf30f7ceabd03457ff43bf5030abaf | 3,109 | py | Python | tf2onnx/optimizer/__init__.py | gerbenvv/tensorflow-onnx | 4cfc02520ab21b129ee025c5f5066c02ff850ca2 | [
"Apache-2.0"
] | 1 | 2021-04-30T15:26:06.000Z | 2021-04-30T15:26:06.000Z | tf2onnx/optimizer/__init__.py | hxcai/tensorflow-onnx | 97d38f12651d2bfeca3be274c1c654d2344d4cdf | [
"Apache-2.0"
] | null | null | null | tf2onnx/optimizer/__init__.py | hxcai/tensorflow-onnx | 97d38f12651d2bfeca3be274c1c654d2344d4cdf | [
"Apache-2.0"
] | null | null | null | # SPDX-License-Identifier: Apache-2.0
"""tf2onnx.optimizer module"""
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals
from collections import OrderedDict
import copy
from .const_fold_optimizer import ConstFoldOptimizer
from .identity_optimizer import Iden... | 37.914634 | 108 | 0.698617 |
795694e97b48b87f2686bb723392cbb0f37088f7 | 9,574 | py | Python | docs/conf.py | hasadi-ha/minemeld-core | eb135597ce895b78f4c2ec272ffc8a45a12962bd | [
"Apache-2.0"
] | null | null | null | docs/conf.py | hasadi-ha/minemeld-core | eb135597ce895b78f4c2ec272ffc8a45a12962bd | [
"Apache-2.0"
] | null | null | null | docs/conf.py | hasadi-ha/minemeld-core | eb135597ce895b78f4c2ec272ffc8a45a12962bd | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
#
# minemeld-core documentation build configuration file, created by
# sphinx-quickstart on Thu Aug 6 14:14:33 2015.
#
# This file is execfile()d with the current directory set to its
# containing dir.
#
# Note that not all possible configuration values are present in this
# autogenerated file.... | 32.23569 | 128 | 0.719657 |
795694ebee51e393607abcf401497175c10f3acd | 63,512 | py | Python | test/python/dagcircuit/test_dagcircuit.py | biblio-techers/Qiskit-Fall-Fest-2021 | 17bb4f21d4c7f4723c43b87ebae21196e8aa53c9 | [
"Apache-2.0"
] | 1 | 2021-09-25T18:49:52.000Z | 2021-09-25T18:49:52.000Z | test/python/dagcircuit/test_dagcircuit.py | biblio-techers/Qiskit-Fall-Fest-2021 | 17bb4f21d4c7f4723c43b87ebae21196e8aa53c9 | [
"Apache-2.0"
] | null | null | null | test/python/dagcircuit/test_dagcircuit.py | biblio-techers/Qiskit-Fall-Fest-2021 | 17bb4f21d4c7f4723c43b87ebae21196e8aa53c9 | [
"Apache-2.0"
] | 1 | 2020-04-15T07:23:23.000Z | 2020-04-15T07:23:23.000Z | # This code is part of Qiskit.
#
# (C) Copyright IBM 2017.
#
# 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 modifications or derivative wo... | 40.453503 | 100 | 0.613018 |
7956950df580d87e4ef2e4e2720344b10084e8c9 | 789 | bzl | Python | google/cloud/pubsub/samples/pubsub_samples_unit_tests.bzl | joezqren/google-cloud-cpp | 325d312b0a21569f3c57515aec7d91f3540d3b48 | [
"Apache-2.0"
] | 299 | 2019-01-31T12:17:56.000Z | 2022-03-30T15:46:15.000Z | google/cloud/pubsub/samples/pubsub_samples_unit_tests.bzl | joezqren/google-cloud-cpp | 325d312b0a21569f3c57515aec7d91f3540d3b48 | [
"Apache-2.0"
] | 6,560 | 2019-01-29T03:15:15.000Z | 2022-03-31T23:58:48.000Z | google/cloud/pubsub/samples/pubsub_samples_unit_tests.bzl | joezqren/google-cloud-cpp | 325d312b0a21569f3c57515aec7d91f3540d3b48 | [
"Apache-2.0"
] | 253 | 2019-02-07T01:18:13.000Z | 2022-03-30T17:21:10.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, ... | 35.863636 | 79 | 0.754119 |
795695ea947ef973292ca04d2b47eea48b028d32 | 54,173 | py | Python | edb/edgeql/parser/grammar/expressions.py | sfermigier/edgedb | 13aff7004aa682777287157dea52642c374967e8 | [
"Apache-2.0"
] | 7,302 | 2018-05-10T18:36:31.000Z | 2022-03-31T17:49:36.000Z | edb/edgeql/parser/grammar/expressions.py | sfermigier/edgedb | 13aff7004aa682777287157dea52642c374967e8 | [
"Apache-2.0"
] | 1,602 | 2018-05-10T17:45:38.000Z | 2022-03-31T23:46:19.000Z | edb/edgeql/parser/grammar/expressions.py | sfermigier/edgedb | 13aff7004aa682777287157dea52642c374967e8 | [
"Apache-2.0"
] | 236 | 2018-05-13T14:15:29.000Z | 2022-03-29T19:39:19.000Z | #
# This source file is part of the EdgeDB open source project.
#
# Copyright 2008-present MagicStack Inc. and the EdgeDB 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... | 30.606215 | 79 | 0.614014 |
7956965f5af53b5f793773dae0e2d5392c2ebfef | 2,146 | py | Python | utils/common_tools.py | YoungYoung619/road_object_detection | 05b0bcac45b64a6ae72606d4be77d9f8220748f8 | [
"MIT"
] | 2 | 2019-06-24T03:23:35.000Z | 2019-07-03T06:53:26.000Z | utils/common_tools.py | YoungYoung619/road_object_detection | 05b0bcac45b64a6ae72606d4be77d9f8220748f8 | [
"MIT"
] | null | null | null | utils/common_tools.py | YoungYoung619/road_object_detection | 05b0bcac45b64a6ae72606d4be77d9f8220748f8 | [
"MIT"
] | null | null | null | """
Copyright (c) College of Mechatronics and Control Engineering, Shenzhen University.
All rights reserved.
Description :
Author:Team Li
"""
import tensorflow as tf
import logging
logging.basicConfig(level=logging.INFO, format='%(asctime)s - %(levelname)s - %(message)s')
logger = logging.getLogger(__name__)
def c... | 37.649123 | 91 | 0.637931 |
79569718fdda2823e3af43e3c9d6dfa8397e4b65 | 446 | py | Python | src/statsAuxiliary/statsAuxiliary.py | nickeita/su2021_is601_project2 | 4974a05517c7884751c5ece09177af2a7640f503 | [
"MIT"
] | null | null | null | src/statsAuxiliary/statsAuxiliary.py | nickeita/su2021_is601_project2 | 4974a05517c7884751c5ece09177af2a7640f503 | [
"MIT"
] | null | null | null | src/statsAuxiliary/statsAuxiliary.py | nickeita/su2021_is601_project2 | 4974a05517c7884751c5ece09177af2a7640f503 | [
"MIT"
] | null | null | null | from calculator.calculator import Calculator
from statsAuxiliary.aggregate import aggregate
from statsAuxiliary.varianceInput import variance_input
class StatsAuxiliary(Calculator):
result = 0
def __init__(self):
super().__init__()
pass
def aggr(self, a):
self.result = aggregate(... | 22.3 | 55 | 0.688341 |
7956974aaeab2d596e7eea989c51c0e9c866f86d | 1,868 | py | Python | src/atcoder/abc006/a/sol_0.py | kagemeka/competitive-programming | c70fe481bcd518f507b885fc9234691d8ce63171 | [
"MIT"
] | 1 | 2021-07-11T03:20:10.000Z | 2021-07-11T03:20:10.000Z | src/atcoder/abc006/a/sol_0.py | kagemeka/competitive-programming | c70fe481bcd518f507b885fc9234691d8ce63171 | [
"MIT"
] | 39 | 2021-07-10T05:21:09.000Z | 2021-12-15T06:10:12.000Z | src/atcoder/abc006/a/sol_0.py | kagemeka/competitive-programming | c70fe481bcd518f507b885fc9234691d8ce63171 | [
"MIT"
] | null | null | null | class Reader:
@staticmethod
def readline():
import sys
return sys.stdin.buffer \
.readline().rstrip()
@classmethod
def read_int(cls):
i = int(cls.readline())
return i
@classmethod
def read_str(cls):
s = cls.readline().decode()
return s
@classmethod
def readli... | 14.48062 | 33 | 0.558351 |
795698164ac050be457db63b05c07e909e06d2a2 | 441 | py | Python | data_structure_helpers/tests/test_list_helpers.py | ChristopherHaydenTodd/ctodd-python-lib-data-structures | 4d9ad3ce7a066993cdff337fd0d3ca0faed75bbc | [
"MIT"
] | 1 | 2019-02-24T14:04:37.000Z | 2019-02-24T14:04:37.000Z | data_structure_helpers/tests/test_list_helpers.py | ChristopherHaydenTodd/ctodd-python-lib-data-structures | 4d9ad3ce7a066993cdff337fd0d3ca0faed75bbc | [
"MIT"
] | null | null | null | data_structure_helpers/tests/test_list_helpers.py | ChristopherHaydenTodd/ctodd-python-lib-data-structures | 4d9ad3ce7a066993cdff337fd0d3ca0faed75bbc | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
"""
Purpose:
Test File for list_helpers.py
"""
# Python Library Imports
import os
import sys
import pytest
from unittest import mock
# Import File to Test
from data_structure_helpers import list_helpers
###
# Fixtures
###
# None at the Moment (Empty Test Suite)
###
# Mocked Fu... | 11.307692 | 47 | 0.680272 |
79569885bc3f6c1a7426588de780d836f075d64d | 873 | py | Python | textbooks/nltk_book/www.nltk.org/book/pylisting/code_toolbox_validation.py | motazsaad/NLP-ICTS6361 | 1d44a187dc966ac45bbd236384d059347efbde50 | [
"Apache-2.0"
] | 10 | 2019-09-20T21:40:03.000Z | 2021-06-22T23:42:44.000Z | textbooks/nltk_book/www.nltk.org/book/pylisting/code_toolbox_validation.py | motazsaad/NLP-ICTS6361 | 1d44a187dc966ac45bbd236384d059347efbde50 | [
"Apache-2.0"
] | null | null | null | textbooks/nltk_book/www.nltk.org/book/pylisting/code_toolbox_validation.py | motazsaad/NLP-ICTS6361 | 1d44a187dc966ac45bbd236384d059347efbde50 | [
"Apache-2.0"
] | 9 | 2019-10-26T07:12:29.000Z | 2022-03-29T03:39:08.000Z | # Natural Language Toolkit: code_toolbox_validation
grammar = nltk.CFG.fromstring('''
S -> Head PS Glosses Comment Date Sem_Field Examples
Head -> Lexeme Root
Lexeme -> "lx"
Root -> "rt" |
PS -> "ps"
Glosses -> Gloss Glosses |
Gloss -> "ge" | "tkp" | "eng"
Date -> "dt"
Sem_Field -> "sf"
Examples ->... | 30.103448 | 85 | 0.630011 |
795698c4106804f01241ee98a63ac3fce66a01c7 | 3,638 | py | Python | statick_tool/discovery_plugin.py | kogut/statick | 6cbe43b5ac78275a12af3ac5aa325833368d0767 | [
"CC0-1.0"
] | 54 | 2018-08-27T19:12:41.000Z | 2022-03-31T04:16:40.000Z | statick_tool/discovery_plugin.py | gregtkogut/statick | 11a8f950d50b52903a25f4f00c7cd52a90eff56c | [
"CC0-1.0"
] | 288 | 2018-08-28T13:17:44.000Z | 2022-03-21T20:05:19.000Z | statick_tool/discovery_plugin.py | gregtkogut/statick | 11a8f950d50b52903a25f4f00c7cd52a90eff56c | [
"CC0-1.0"
] | 12 | 2018-08-28T13:18:39.000Z | 2022-03-21T19:27:16.000Z | """Discovery plugin."""
import logging
import os
import subprocess
import sys
from typing import Any, List, Optional, Union
from yapsy.IPlugin import IPlugin
from statick_tool.exceptions import Exceptions
from statick_tool.package import Package
from statick_tool.plugin_context import PluginContext
class DiscoveryP... | 34.320755 | 87 | 0.61105 |
79569a2fef7671c8bf74e86781c95074083f2ebc | 13,866 | py | Python | apps/cif_input/PyCifRW/YappsStarParser_1_0.py | mtaillefumier/SIRIUS | 50ec1c202c019113c5660f1966b170dec9dfd4d4 | [
"BSD-2-Clause"
] | 77 | 2016-03-18T08:38:30.000Z | 2022-03-11T14:06:25.000Z | apps/cif_input/PyCifRW/YappsStarParser_1_0.py | simonpintarelli/SIRIUS | f4b5c4810af2a3ea1e67992d65750535227da84b | [
"BSD-2-Clause"
] | 240 | 2016-04-12T16:39:11.000Z | 2022-03-31T08:46:12.000Z | apps/cif_input/PyCifRW/YappsStarParser_1_0.py | simonpintarelli/SIRIUS | f4b5c4810af2a3ea1e67992d65750535227da84b | [
"BSD-2-Clause"
] | 43 | 2016-03-18T17:45:07.000Z | 2022-02-28T05:27:59.000Z | from StarFile import StarBlock,StarFile
# An alternative specification for the Cif Parser, based on Yapps2
# by Amit Patel (http://theory.stanford.edu/~amitp/Yapps)
#
# helper code: we define our match tokens
lastval = ''
def monitor(location,value):
global lastval
#print 'At %s: %s' % (location,`value`)
la... | 49.170213 | 265 | 0.618491 |
79569ac2edabe2aa7eb861937d06d846ce1c5204 | 689 | py | Python | test/tests/struct_test.py | aisk/pyston | ac69cfef0621dbc8901175e84fa2b5cb5781a646 | [
"BSD-2-Clause",
"Apache-2.0"
] | 1 | 2020-02-06T14:28:45.000Z | 2020-02-06T14:28:45.000Z | test/tests/struct_test.py | aisk/pyston | ac69cfef0621dbc8901175e84fa2b5cb5781a646 | [
"BSD-2-Clause",
"Apache-2.0"
] | null | null | null | test/tests/struct_test.py | aisk/pyston | ac69cfef0621dbc8901175e84fa2b5cb5781a646 | [
"BSD-2-Clause",
"Apache-2.0"
] | 1 | 2020-02-06T14:29:00.000Z | 2020-02-06T14:29:00.000Z | import struct
s = struct.pack("II", 1, 1234)
print repr(s)
print struct.unpack("II", s)
nums = [0, 0x98, -0x12, 0x9876, -0x1234, 0x98765432, -0x12345678, 0x9876543212345678, -0x1234567812345678]
for exp in 7, 8, 15, 16, 31, 32, 63, 64:
nums += [2 ** exp, 2 ** exp - 1, -2 ** exp, -2 ** exp - 1]
for format in "bB?h... | 34.45 | 106 | 0.532656 |
79569bea9466288f72f30ea2a9534579973e5b30 | 434 | py | Python | s7_python_functions/scope.py | chiehandlu/pythonlearn | 53ba8f0f8edc7df7b09b0f233d52d7145d380ec0 | [
"Apache-2.0"
] | null | null | null | s7_python_functions/scope.py | chiehandlu/pythonlearn | 53ba8f0f8edc7df7b09b0f233d52d7145d380ec0 | [
"Apache-2.0"
] | null | null | null | s7_python_functions/scope.py | chiehandlu/pythonlearn | 53ba8f0f8edc7df7b09b0f233d52d7145d380ec0 | [
"Apache-2.0"
] | null | null | null |
"""
Names defined inside a def can only be seen by the code within that def.
You cannot even refer to such names from outside the function.
"""
# Global scope
x = 99
print('x =', x)
# 這邊的x是全局變量global scope
x += 1
print('x =', x)
def tryTest():
z = x + 1
print('z =', z)
# 這邊的z是局部變量local scope
tryTest()
def... | 14 | 72 | 0.617512 |
79569c63e994aa8f7cc72dac3a845b6d4a9f8d3e | 50 | py | Python | main.py | HaBaLeS/MqttPixel | 26a6245a5ff787a3165b04d8bde89c39043de25d | [
"Beerware"
] | null | null | null | main.py | HaBaLeS/MqttPixel | 26a6245a5ff787a3165b04d8bde89c39043de25d | [
"Beerware"
] | null | null | null | main.py | HaBaLeS/MqttPixel | 26a6245a5ff787a3165b04d8bde89c39043de25d | [
"Beerware"
] | null | null | null | import machine
def reboot():
machine.reset()
| 10 | 19 | 0.68 |
79569db91cff9ed4a2cde46f633ed960428f2749 | 403 | py | Python | tests/test_a0134gasstation.py | nirofang/pyleet | 600d58ad97028c9a14148af4ef468683a011a515 | [
"MIT"
] | 3 | 2019-11-06T13:10:38.000Z | 2021-11-17T07:29:54.000Z | tests/test_a0134gasstation.py | nirofang/pyleet | 600d58ad97028c9a14148af4ef468683a011a515 | [
"MIT"
] | 1 | 2020-12-17T22:18:05.000Z | 2020-12-17T22:18:05.000Z | tests/test_a0134gasstation.py | nirofang/pyleet | 600d58ad97028c9a14148af4ef468683a011a515 | [
"MIT"
] | 1 | 2019-11-06T13:10:45.000Z | 2019-11-06T13:10:45.000Z | from solutions.a0134gasstation import Solution
solution = Solution()
def test_canCompleteCircuit1():
gas = [1, 2, 3, 4, 5]
cost = [3, 4, 5, 1, 2]
expect = 3
actual = solution.canCompleteCircuit(gas, cost)
assert actual == expect
def test_canCompleteCircuit2():
gas = [2, 3, 4]
cost = [3, 4, 3]
expec... | 20.15 | 49 | 0.669975 |
79569de02bd529bb54f50aba2a6ce01bc901b578 | 6,041 | py | Python | zipline/utils/functional.py | degiere/zipline | bc0b117dc94b8e93081818964e3b1bdbf9b33abb | [
"Apache-2.0"
] | null | null | null | zipline/utils/functional.py | degiere/zipline | bc0b117dc94b8e93081818964e3b1bdbf9b33abb | [
"Apache-2.0"
] | null | null | null | zipline/utils/functional.py | degiere/zipline | bc0b117dc94b8e93081818964e3b1bdbf9b33abb | [
"Apache-2.0"
] | 1 | 2019-09-20T01:08:33.000Z | 2019-09-20T01:08:33.000Z | from pprint import pformat
from six import viewkeys
from six.moves import map, zip
from toolz import curry
@curry
def apply(f, *args, **kwargs):
"""Apply a function to arguments.
Parameters
----------
f : callable
The function to call.
*args, **kwargs
**kwargs
Arguments to fe... | 24.657143 | 79 | 0.540473 |
79569e42da0d7272105fb92a5c6b26c7175b5e46 | 838 | py | Python | app.py | yannicfreson/MiFurst_API | 6677decfda06cfd092ebb460c5ddf3ad71516fde | [
"MIT"
] | null | null | null | app.py | yannicfreson/MiFurst_API | 6677decfda06cfd092ebb460c5ddf3ad71516fde | [
"MIT"
] | null | null | null | app.py | yannicfreson/MiFurst_API | 6677decfda06cfd092ebb460c5ddf3ad71516fde | [
"MIT"
] | null | null | null | from flask import Flask
from flask_restful import Api, Resource, reqparse
import random
app = Flask(__name__)
api = Api(app)
quotes = [
"It is certain.",
"It is decidedly so.",
"Without a doubt.",
"Yes - definitely.",
"You may rely on it.",
"As I see it, yes.",
"Most likely.",
"Outlook ... | 21.487179 | 57 | 0.600239 |
79569f04bff92aaf5ce42a2e62e57531ba95acef | 1,159 | py | Python | pex/dist_metadata.py | jneuff/pex | f7eb554ecdbfdb9cd24a793b4dda358035e26855 | [
"Apache-2.0"
] | null | null | null | pex/dist_metadata.py | jneuff/pex | f7eb554ecdbfdb9cd24a793b4dda358035e26855 | [
"Apache-2.0"
] | null | null | null | pex/dist_metadata.py | jneuff/pex | f7eb554ecdbfdb9cd24a793b4dda358035e26855 | [
"Apache-2.0"
] | null | null | null | # coding=utf-8
# Copyright 2020 Pants project contributors (see CONTRIBUTORS.md).
# Licensed under the Apache License, Version 2.0 (see LICENSE).
from __future__ import absolute_import
import email
from pex.third_party.packaging.specifiers import SpecifierSet
from pex.third_party.pkg_resources import DistInfoDistrib... | 33.114286 | 91 | 0.765315 |
79569f878b44d7ae7e778628940246d444b6a890 | 21,557 | py | Python | src/odin/adapters/parameter_tree.py | odin-detector/odin-control | 366085b4fc04c620ee2e9e040a883f5d3d70d5a0 | [
"Apache-2.0"
] | 4 | 2018-05-24T13:38:23.000Z | 2021-08-18T08:32:54.000Z | src/odin/adapters/parameter_tree.py | odin-detector/odin-control | 366085b4fc04c620ee2e9e040a883f5d3d70d5a0 | [
"Apache-2.0"
] | 20 | 2018-04-10T09:28:01.000Z | 2022-03-17T11:43:59.000Z | src/odin/adapters/parameter_tree.py | odin-detector/odin-control | 366085b4fc04c620ee2e9e040a883f5d3d70d5a0 | [
"Apache-2.0"
] | 3 | 2017-06-07T13:28:38.000Z | 2019-07-16T10:02:21.000Z | """ParameterTree - classes representing a tree of parameters and their accessor methods.
This module implements an arbitrarily-structured, recursively-managed tree of parameters and
the appropriate accessor methods that are used to read and write those parameters. Its
particular use is in the definition of a tree of p... | 42.35167 | 107 | 0.622536 |
7956a4bc5c4d81d616634d1455c7fc9cfa180fc9 | 3,434 | py | Python | _data/galleries/gallery_creator.py | AsheBlade/ShadowArchive_Template | b2dbc658d3f1e5eb13a0ee2c2137f1aed19ce71a | [
"MIT"
] | null | null | null | _data/galleries/gallery_creator.py | AsheBlade/ShadowArchive_Template | b2dbc658d3f1e5eb13a0ee2c2137f1aed19ce71a | [
"MIT"
] | 31 | 2021-06-15T07:26:34.000Z | 2022-01-15T02:58:24.000Z | _data/galleries/gallery_creator.py | AsheBlade/ShadowArchive_Template | b2dbc658d3f1e5eb13a0ee2c2137f1aed19ce71a | [
"MIT"
] | null | null | null | #!/usr/bin/env python
# install imagesize: pip install imagesize
__author__ = 'Olivier Pieters'
__author_email__ = 'me@olivierpieters.be'
__license__ = 'BSD-3-Clause'
import yaml, imagesize
from os import listdir, rename
from os.path import isfile, join
# configuration
output_file = "Icebane_Drawing.yml"
input_file... | 30.936937 | 126 | 0.658125 |
7956a55035c90721d77718c2e33419b2957fdba1 | 2,350 | py | Python | gpytorch/lazy/sum_batch_lazy_tensor.py | llguo95/gpytorch | 1fa69935104565c377ce95d2c581c9eedfb55817 | [
"MIT"
] | 2,673 | 2018-02-19T22:28:58.000Z | 2022-03-31T13:22:28.000Z | gpytorch/lazy/sum_batch_lazy_tensor.py | llguo95/gpytorch | 1fa69935104565c377ce95d2c581c9eedfb55817 | [
"MIT"
] | 1,415 | 2018-02-19T20:38:20.000Z | 2022-03-30T12:53:13.000Z | gpytorch/lazy/sum_batch_lazy_tensor.py | llguo95/gpytorch | 1fa69935104565c377ce95d2c581c9eedfb55817 | [
"MIT"
] | 467 | 2018-03-07T02:06:05.000Z | 2022-03-27T07:05:44.000Z | #!/usr/bin/env python3
import torch
from ..utils.broadcasting import _pad_with_singletons
from ..utils.getitem import _noop_index
from .block_lazy_tensor import BlockLazyTensor
class SumBatchLazyTensor(BlockLazyTensor):
"""
Represents a lazy tensor that is actually the sum of several lazy tensors blocks.
... | 37.903226 | 113 | 0.671489 |
7956a5f8859e2f6090a31948e9ad10fe42b0442b | 197 | py | Python | 1.Basic/2.py | MajkutP/VisualPython-Fourth-Semester | 738dfbf8daecf27e99b3ecf6687d3f3843c8dad1 | [
"MIT"
] | null | null | null | 1.Basic/2.py | MajkutP/VisualPython-Fourth-Semester | 738dfbf8daecf27e99b3ecf6687d3f3843c8dad1 | [
"MIT"
] | null | null | null | 1.Basic/2.py | MajkutP/VisualPython-Fourth-Semester | 738dfbf8daecf27e99b3ecf6687d3f3843c8dad1 | [
"MIT"
] | null | null | null | def fun(lista, lista2):
ta_sama = 0;
L = []
for i in lista:
for j in lista2:
if i == j and i not in L:
L.append(i)
return L
L1 = [1,5,2,4,8]
L2 = [1,5,3,7,2]
print(fun(L1,L2)) | 14.071429 | 28 | 0.527919 |
7956a639e0637486e687e3c91a45a4959a36c6ff | 7,996 | py | Python | scripts/scz_microarray_combined/1_prepare_feature_label_matrix_old_original.py | omarmaddouri/GCNCC_1 | ec858bbe8246e4af15f7b870ca0ccafdea93d627 | [
"MIT"
] | 4 | 2020-12-03T11:57:15.000Z | 2021-12-09T05:20:44.000Z | scripts/scz_microarray_combined/1_prepare_feature_label_matrix_old_original.py | alkaidone/GCNCC | 3270b4c2d48e0090a18a0ab1df3b9fd81627029d | [
"MIT"
] | 5 | 2020-01-28T23:14:40.000Z | 2021-08-25T15:55:23.000Z | scripts/scz_microarray_combined/1_prepare_feature_label_matrix_old_original.py | alkaidone/GCNCC | 3270b4c2d48e0090a18a0ab1df3b9fd81627029d | [
"MIT"
] | 3 | 2021-11-23T05:13:27.000Z | 2021-12-30T08:12:48.000Z | from __future__ import division
from __future__ import print_function
import tensorflow as tf
from pathlib import Path
import numpy as np
import pandas as pd
from collections import OrderedDict
import itertools
import csv
import os
import sys
project_path = Path(__file__).resolve().parents[2]
sys.path.app... | 53.306667 | 708 | 0.567909 |
7956a655e70566c35750054a6b8fa28b244f542b | 3,650 | py | Python | soldadox/soldadox/middlewares.py | vcborsolan/soldadox | 6ebe98c3f2a9f1b8e5839357d94a2d1b5ded4af0 | [
"MIT"
] | 1 | 2020-11-16T20:08:40.000Z | 2020-11-16T20:08:40.000Z | soldadox/soldadox/middlewares.py | vcborsolan/soldadox | 6ebe98c3f2a9f1b8e5839357d94a2d1b5ded4af0 | [
"MIT"
] | 5 | 2020-08-12T15:14:11.000Z | 2022-03-02T14:58:44.000Z | soldadox/soldadox/middlewares.py | vcborsolan/soldadox_collector | 6ebe98c3f2a9f1b8e5839357d94a2d1b5ded4af0 | [
"MIT"
] | null | null | null | # Define here the models for your spider middleware
#
# See documentation in:
# https://docs.scrapy.org/en/latest/topics/spider-middleware.html
from scrapy import signals
# useful for handling different item types with a single interface
from itemadapter import is_item, ItemAdapter
class SoldadoxSpiderMiddleware:
... | 35.096154 | 78 | 0.674521 |
7956a694cf1760cc7f8f5e8a2392e764d03259f2 | 552 | py | Python | tests/commands/test_welcome.py | crakama/bc_7_twitment | 5e068b01b1b4aba968517a50168d3ae8d649fd32 | [
"MIT"
] | 1 | 2016-06-10T17:45:20.000Z | 2016-06-10T17:45:20.000Z | tests/commands/test_welcome.py | crakama/bc_7_twitment | 5e068b01b1b4aba968517a50168d3ae8d649fd32 | [
"MIT"
] | null | null | null | tests/commands/test_welcome.py | crakama/bc_7_twitment | 5e068b01b1b4aba968517a50168d3ae8d649fd32 | [
"MIT"
] | null | null | null | """Tests for our `twitment welcome` subcommand."""
from subprocess import PIPE, Popen as popen
from unittest import TestCase
class TestHello(TestCase):
def test_returns_multiple_lines(self):
output = popen(['twitment', 'welcome'], stdout=PIPE).communicate()[0]
lines = output.split('\n')
... | 32.470588 | 79 | 0.688406 |
7956a6c7bc0fcb350ceed5ce276bc9d47e282735 | 876 | py | Python | app/training/test_train.py | azure-walker/MLOpsPython | 710291c3c573acd0d4fcb897150404c7ca9498ca | [
"MIT"
] | null | null | null | app/training/test_train.py | azure-walker/MLOpsPython | 710291c3c573acd0d4fcb897150404c7ca9498ca | [
"MIT"
] | null | null | null | app/training/test_train.py | azure-walker/MLOpsPython | 710291c3c573acd0d4fcb897150404c7ca9498ca | [
"MIT"
] | null | null | null | import numpy as np
from app.training.train import train_model, get_model_metrics
def test_train_model():
X_train = np.array([1, 2, 3, 4, 5, 6]).reshape(-1, 1)
y_train = np.array([10, 9, 8, 8, 6, 5])
data = {"train": {"X": X_train, "y": y_train}}
reg_model = train_model(data, {"alpha": 1.2})
pred... | 26.545455 | 79 | 0.625571 |
7956a806749cf2f07c7689c1365088590ac7be5d | 232 | py | Python | lab6/__init__.py | kinpa200296/MM_labs | d56f6939e1669c3c8e9943ffb012a91cd2a7c11c | [
"MIT"
] | null | null | null | lab6/__init__.py | kinpa200296/MM_labs | d56f6939e1669c3c8e9943ffb012a91cd2a7c11c | [
"MIT"
] | null | null | null | lab6/__init__.py | kinpa200296/MM_labs | d56f6939e1669c3c8e9943ffb012a91cd2a7c11c | [
"MIT"
] | null | null | null | from channel import Channel
from input import Input
from model import Model
from output import Output
from phase import Phase
from process import Process
from request import Request
from storage import Storage
from unit import Unit
| 23.2 | 27 | 0.844828 |
7956a8137fa87bf2c06bf095b19c3498daf8b2e2 | 174 | py | Python | src/bonus.py | cloudzfy/pychallenge | 1af98a632021532e136721d282b0e7c2cbc519a3 | [
"MIT"
] | 3 | 2016-07-23T03:31:46.000Z | 2019-08-22T01:23:07.000Z | src/bonus.py | cloudzfy/pychallenge | 1af98a632021532e136721d282b0e7c2cbc519a3 | [
"MIT"
] | null | null | null | src/bonus.py | cloudzfy/pychallenge | 1af98a632021532e136721d282b0e7c2cbc519a3 | [
"MIT"
] | 3 | 2017-05-22T09:41:20.000Z | 2018-09-06T02:05:19.000Z | import this
s = 'va gur snpr bs jung?'
d = {}
for c in (65, 97):
for i in range(26):
d[chr(i+c)] = chr((i+13) % 26 + c)
print "".join([d.get(c, c) for c in s]) | 17.4 | 42 | 0.5 |
7956a83533709fe3b0780fd2dad945239f92f440 | 6,449 | py | Python | examples/optimization/hyper-parameter-optimization/hyper_parameter_optimizer.py | Whilich52/clearml | e862a6de6039a6f226cf0fb65dce71fa220cc175 | [
"Apache-2.0"
] | 1 | 2021-05-22T05:49:51.000Z | 2021-05-22T05:49:51.000Z | examples/optimization/hyper-parameter-optimization/hyper_parameter_optimizer.py | Whilich52/clearml | e862a6de6039a6f226cf0fb65dce71fa220cc175 | [
"Apache-2.0"
] | null | null | null | examples/optimization/hyper-parameter-optimization/hyper_parameter_optimizer.py | Whilich52/clearml | e862a6de6039a6f226cf0fb65dce71fa220cc175 | [
"Apache-2.0"
] | 1 | 2021-05-22T05:49:49.000Z | 2021-05-22T05:49:49.000Z | import logging
from clearml import Task
from clearml.automation import (
DiscreteParameterRange, HyperParameterOptimizer, RandomSearch,
UniformIntegerParameterRange)
# trying to load Bayesian optimizer package
try:
from clearml.automation.optuna import OptimizerOptuna # noqa
aSearchStrategy = Optimiz... | 48.488722 | 112 | 0.745542 |
7956a91ef20ca0f18eb22bf6b6f2b5dee7b6c4b2 | 834 | py | Python | setup.py | sathishpy/EN-Roadmap | 76b0816b1d89d512d511259e475f0be005365fcb | [
"MIT"
] | null | null | null | setup.py | sathishpy/EN-Roadmap | 76b0816b1d89d512d511259e475f0be005365fcb | [
"MIT"
] | null | null | null | setup.py | sathishpy/EN-Roadmap | 76b0816b1d89d512d511259e475f0be005365fcb | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
from setuptools import setup, find_packages
from pip.req import parse_requirements
import re, ast
# get version from __version__ variable in erpnext_roadmap/__init__.py
_version_re = re.compile(r'__version__\s+=\s+(.*)')
with open('erpnext_roadmap/__init__.py', 'rb') as f:
version = str(as... | 30.888889 | 70 | 0.748201 |
7956a946b7bebc5a2677b789bf083cff7d9e42bf | 704 | py | Python | src/python/grpcio_status/grpc_version.py | vsel/grpc | 10dd24dcb971c858f28362f1548cb94f738c10ef | [
"Apache-2.0"
] | 2 | 2020-06-03T06:10:48.000Z | 2020-06-03T06:10:55.000Z | src/python/grpcio_status/grpc_version.py | OneCodeMonkey/grpc | 03fc68bb5a10c2604e299a8089776462efbfc8c7 | [
"Apache-2.0"
] | 62 | 2020-02-27T00:53:36.000Z | 2021-02-05T06:10:53.000Z | src/python/grpcio_status/grpc_version.py | OneCodeMonkey/grpc | 03fc68bb5a10c2604e299a8089776462efbfc8c7 | [
"Apache-2.0"
] | 1 | 2022-02-22T16:32:03.000Z | 2022-02-22T16:32:03.000Z | # Copyright 2018 The gRPC Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writ... | 39.111111 | 97 | 0.762784 |
7956a9bba3dc60110ee542c888cdbc6af18607a4 | 26,206 | py | Python | Game_def.py | DylanR3798/Hockey-World-Cup-Simulatation | 3751206d9bf27095699ba6eb715c28acd1612223 | [
"Apache-2.0"
] | null | null | null | Game_def.py | DylanR3798/Hockey-World-Cup-Simulatation | 3751206d9bf27095699ba6eb715c28acd1612223 | [
"Apache-2.0"
] | null | null | null | Game_def.py | DylanR3798/Hockey-World-Cup-Simulatation | 3751206d9bf27095699ba6eb715c28acd1612223 | [
"Apache-2.0"
] | null | null | null | import random
import time
class Goalkeeper():
"""A definition that produces the attributes for a goalkeeper on the basis of the players overall rating"""
def __init__(self, name, reflexes, jumping, bravery, kicking):
self.name = name
self.reflexes = reflexes
... | 41.9296 | 159 | 0.577349 |
7956aa35350aad888e82bec3a75bde3dbdcf72a0 | 1,772 | py | Python | test.py | kchalkowski/python-translation-exercise | daed72ad2eb32443f64a84fdcbb1486bb2ba2fe4 | [
"CC-BY-4.0"
] | null | null | null | test.py | kchalkowski/python-translation-exercise | daed72ad2eb32443f64a84fdcbb1486bb2ba2fe4 | [
"CC-BY-4.0"
] | null | null | null | test.py | kchalkowski/python-translation-exercise | daed72ad2eb32443f64a84fdcbb1486bb2ba2fe4 | [
"CC-BY-4.0"
] | null | null | null | #!/usr/bin/env python3
import sys
def translate_sequence(rna_sequence, genetic_code):
"""Translates a sequence of RNA into a sequence of amino acids.
Translates `rna_sequence` into string of amino acids, according to the
`genetic_code` given as a dict. Translation begins at the first position of
the `... | 38.521739 | 129 | 0.514673 |
7956aa9af132c90477862a416ba73fc736ec14d2 | 11,695 | py | Python | tadacnv/lib/utils.py | jakob-he/TADA | 8db4e0af19b4a32c7071c175a21bbafe3b02cb31 | [
"MIT"
] | 3 | 2021-12-24T18:40:14.000Z | 2022-03-05T22:22:38.000Z | tadacnv/lib/utils.py | jakob-he/TADA | 8db4e0af19b4a32c7071c175a21bbafe3b02cb31 | [
"MIT"
] | 1 | 2020-11-30T09:49:08.000Z | 2021-05-14T12:28:04.000Z | tadacnv/lib/utils.py | jakob-he/TADA | 8db4e0af19b4a32c7071c175a21bbafe3b02cb31 | [
"MIT"
] | 2 | 2021-12-07T17:25:55.000Z | 2021-12-24T18:40:16.000Z | """Helper functions to parse BED files."""
# standart libraries
import pathlib
import json
import gzip
# own libraries
from .bed import Bed
from .bed_class import BedClass
# third party libararies
import numpy as np
import pandas as pd
from scipy import stats, linalg
# sklearn
from sklearn.ensemble._forest import _g... | 40.749129 | 169 | 0.643437 |
7956abdc7386545d70cbf6b0a3cd1ef61182be50 | 2,294 | py | Python | environments/sumo/TrafficLightPhases.py | Denesh1998/pytorch-a2c-ppo-acktr-gail | fc187845a4c562cbf9b2b2b3afb19b4fdda07a90 | [
"MIT"
] | null | null | null | environments/sumo/TrafficLightPhases.py | Denesh1998/pytorch-a2c-ppo-acktr-gail | fc187845a4c562cbf9b2b2b3afb19b4fdda07a90 | [
"MIT"
] | null | null | null | environments/sumo/TrafficLightPhases.py | Denesh1998/pytorch-a2c-ppo-acktr-gail | fc187845a4c562cbf9b2b2b3afb19b4fdda07a90 | [
"MIT"
] | null | null | null | from _pyio import IOBase
import xml.etree.ElementTree as ElementTree
class TrafficLightPhases():
'''
Contains all phases of all traffic lights that do not involve yellow.
Usually read from a file.
The file follows the SUMO format from
https://sumo.dlr.de/wiki/Simulation/Traffic_Lights#Defining_Ne... | 36.412698 | 105 | 0.614211 |
7956ae3455af843e87dbaaaeec8d3542454e9f0f | 3,746 | py | Python | tests/clvm/coin_store.py | keypool-com/chia-blockchain | 8c96651a78a0ef6694197c0070f4631fc4b1bf45 | [
"Apache-2.0"
] | null | null | null | tests/clvm/coin_store.py | keypool-com/chia-blockchain | 8c96651a78a0ef6694197c0070f4631fc4b1bf45 | [
"Apache-2.0"
] | null | null | null | tests/clvm/coin_store.py | keypool-com/chia-blockchain | 8c96651a78a0ef6694197c0070f4631fc4b1bf45 | [
"Apache-2.0"
] | null | null | null | from collections import defaultdict
from dataclasses import dataclass, replace
from typing import Dict, Iterator, List
from chia.consensus.blockchain_check_conditions import blockchain_check_conditions_dict
from chia.types.announcement import Announcement
from chia.types.blockchain_format.coin import Coin
from chia.ty... | 40.717391 | 119 | 0.701281 |
7956aee93ebd8c3c12475be3f53d9b5c92283c81 | 5,184 | py | Python | flask_redoc/__init__.py | whitebarry/flask-redoc | d2ecc82e106a298ba8cdfab221e7c7d75ddfc76e | [
"MIT"
] | 18 | 2020-03-16T14:01:30.000Z | 2021-08-24T01:12:11.000Z | flask_redoc/__init__.py | whitebarry/flask-redoc | d2ecc82e106a298ba8cdfab221e7c7d75ddfc76e | [
"MIT"
] | 3 | 2020-10-13T18:56:20.000Z | 2021-11-22T21:45:10.000Z | flask_redoc/__init__.py | whitebarry/flask-redoc | d2ecc82e106a298ba8cdfab221e7c7d75ddfc76e | [
"MIT"
] | 6 | 2020-05-01T00:45:40.000Z | 2022-03-25T05:02:40.000Z | """flask_redoc Module."""
import copy
import json
import os
import yaml
from apispec import APISpec
from apispec.ext.marshmallow import MarshmallowPlugin
from apispec_webframeworks.flask import FlaskPlugin
from flask import Blueprint, render_template
from jsonmerge import merge
from .version import __version__
clas... | 32.198758 | 92 | 0.563465 |
7956aef896f98ee6c14c58adefdd2bee7190aa13 | 3,608 | py | Python | utility.py | hbdat/cvpr20_IMCL | a71b592e006778f5fff05976acd64b3b412c7f4a | [
"MIT"
] | 18 | 2020-07-12T14:19:51.000Z | 2022-03-28T12:04:28.000Z | utility.py | hbdat/cvpr20_IMCL | a71b592e006778f5fff05976acd64b3b412c7f4a | [
"MIT"
] | 5 | 2020-12-08T05:04:33.000Z | 2022-01-15T06:17:11.000Z | utility.py | hbdat/cvpr20_IMCL | a71b592e006778f5fff05976acd64b3b412c7f4a | [
"MIT"
] | 3 | 2020-07-24T14:37:30.000Z | 2021-07-20T05:39:26.000Z | # -*- coding: utf-8 -*-
"""
Created on Mon Jan 21 12:34:41 2019
@author: badat
"""
from sklearn.metrics import average_precision_score
import numpy as np
import tensorflow as tf
#%%
def compute_AP(Prediction,Label,names):
num_class = Prediction.shape[1]
ap=np.zeros(num_class)
for idx_cls in ... | 38.795699 | 176 | 0.693459 |
7956b08d2033ff275b83e1338b95b1e1ad9b0db5 | 2,425 | py | Python | Notebooks/SVM/zh-cn/Util.py | wangjiangtao-NJPI/MachineLearning | 78124b56a26ec68efb3c517a4a2420860b6e4a75 | [
"MIT"
] | 1,107 | 2016-09-21T02:18:36.000Z | 2022-03-29T02:52:12.000Z | Notebooks/SVM/zh-cn/Util.py | wangjiangtao-NJPI/MachineLearning | 78124b56a26ec68efb3c517a4a2420860b6e4a75 | [
"MIT"
] | 18 | 2016-12-22T10:24:47.000Z | 2022-03-11T23:18:43.000Z | Notebooks/SVM/zh-cn/Util.py | wangjiangtao-NJPI/MachineLearning | 78124b56a26ec68efb3c517a4a2420860b6e4a75 | [
"MIT"
] | 776 | 2016-12-21T12:08:08.000Z | 2022-03-21T06:12:08.000Z | import numpy as np
import matplotlib.pyplot as plt
from math import pi
np.random.seed(142857)
# 生成简单的测试数据集
def gen_two_clusters(size=100, center=0, scale=1, dis=2):
center1 = (np.random.random(2) + center - 0.5) * scale + dis
center2 = (np.random.random(2) + center - 0.5) * scale - dis
cluster1 = (np.ran... | 34.15493 | 107 | 0.602887 |
7956b10346741045e6c9f5d2f9cdf89ff447dd08 | 3,922 | py | Python | isi_sdk_8_2_2/test/test_namespace_api.py | mohitjain97/isilon_sdk_python | a371f438f542568edb8cda35e929e6b300b1177c | [
"Unlicense"
] | 24 | 2018-06-22T14:13:23.000Z | 2022-03-23T01:21:26.000Z | isi_sdk_8_2_2/test/test_namespace_api.py | mohitjain97/isilon_sdk_python | a371f438f542568edb8cda35e929e6b300b1177c | [
"Unlicense"
] | 46 | 2018-04-30T13:28:22.000Z | 2022-03-21T21:11:07.000Z | isi_sdk_8_2_2/test/test_namespace_api.py | mohitjain97/isilon_sdk_python | a371f438f542568edb8cda35e929e6b300b1177c | [
"Unlicense"
] | 29 | 2018-06-19T00:14:04.000Z | 2022-02-08T17:51:19.000Z | # coding: utf-8
"""
Isilon SDK
Isilon SDK - Language bindings for the OneFS API # noqa: E501
OpenAPI spec version: 9
Contact: sdk@isilon.com
Generated by: https://github.com/swagger-api/swagger-codegen.git
"""
from __future__ import absolute_import
import unittest
import isi_sdk_8_2_2
from i... | 19.320197 | 79 | 0.613208 |
7956b12f7c6d75bf989f7b5b9545962e96c1d2f5 | 14,604 | py | Python | models/ConfigBuilder.py | GGarcia93/pycryptobot | 74b7d2dcbafd47419d02f179cbdc2d8086399b0f | [
"Apache-2.0"
] | null | null | null | models/ConfigBuilder.py | GGarcia93/pycryptobot | 74b7d2dcbafd47419d02f179cbdc2d8086399b0f | [
"Apache-2.0"
] | null | null | null | models/ConfigBuilder.py | GGarcia93/pycryptobot | 74b7d2dcbafd47419d02f179cbdc2d8086399b0f | [
"Apache-2.0"
] | 1 | 2022-02-02T02:55:14.000Z | 2022-02-02T02:55:14.000Z | """config.json Configuration Builder"""
from os.path import isfile
from json import dump
from re import compile as re_compile
from sys import exit as sys_exit
class ConfigBuilder():
def __init__(self) -> None:
self._b = 0
self._c = 0
self._k = 0
self._t = 0
def init(self) -> N... | 48.68 | 133 | 0.492331 |
7956b1695efd2308012e32d4182ab5c8b2b39690 | 83,625 | py | Python | django/db/models/query.py | arthurgit1/django | a47134af754fbf8dd923eb5e0cc162e3b7c0e1c5 | [
"CNRI-Python-GPL-Compatible",
"BSD-3-Clause"
] | 2 | 2020-11-24T02:26:43.000Z | 2020-11-24T02:26:45.000Z | django/db/models/query.py | arthurgit1/django | a47134af754fbf8dd923eb5e0cc162e3b7c0e1c5 | [
"CNRI-Python-GPL-Compatible",
"BSD-3-Clause"
] | 1 | 2021-01-15T17:49:48.000Z | 2021-01-15T17:49:48.000Z | django/db/models/query.py | arthurgit1/django | a47134af754fbf8dd923eb5e0cc162e3b7c0e1c5 | [
"CNRI-Python-GPL-Compatible",
"BSD-3-Clause"
] | 1 | 2021-07-18T04:00:14.000Z | 2021-07-18T04:00:14.000Z | """
The main QuerySet implementation. This provides the public API for the ORM.
"""
import copy
import operator
import warnings
from itertools import chain
import django
from django.conf import settings
from django.core import exceptions
from django.db import (
DJANGO_VERSION_PICKLE_KEY, IntegrityError, NotSuppor... | 41.875313 | 119 | 0.612436 |
7956b2169c3a5cdee99ef738ab7595be889417a3 | 23,285 | py | Python | Stock/BackTesting/Engine/Strategy/DyStockBackTestingCtaEngine.py | wangchen1ren/DevilYuan | dd7c4746134c56eaf3955c706a931cf9bf479941 | [
"MIT"
] | 49 | 2018-07-17T16:17:27.000Z | 2022-03-14T14:01:46.000Z | Stock/BackTesting/Engine/Strategy/DyStockBackTestingCtaEngine.py | yuxiaojian01/DevilYuan | 81ec51b3ada74538aa41d0a42fa8cc958d5fabf1 | [
"MIT"
] | null | null | null | Stock/BackTesting/Engine/Strategy/DyStockBackTestingCtaEngine.py | yuxiaojian01/DevilYuan | 81ec51b3ada74538aa41d0a42fa8cc958d5fabf1 | [
"MIT"
] | 28 | 2018-10-11T02:50:07.000Z | 2022-02-26T12:57:21.000Z | """
本文件中包含的是CTA模块的回测引擎,回测引擎的API和CTA引擎一致,
可以使用和实盘相同的代码进行回测。
"""
import types
import copy
from collections import OrderedDict
from DyCommon.DyCommon import *
from ....Data.Engine.DyStockDataEngine import *
from ....Trade.DyStockStrategyBase import *
from ....Trade.Strategy.DyStockCtaBase import *
from ....Trade.... | 32.888418 | 153 | 0.586601 |
7956b23e993ee0e9ddcf3ae793ace2fc534b484e | 439 | py | Python | product/migrations/0017_alter_category_category_name.py | SergueiNK/oc_projet_p8 | a2a3e3df7ecd048207f342343163a3aecf246423 | [
"Unlicense"
] | null | null | null | product/migrations/0017_alter_category_category_name.py | SergueiNK/oc_projet_p8 | a2a3e3df7ecd048207f342343163a3aecf246423 | [
"Unlicense"
] | 3 | 2021-12-04T16:47:44.000Z | 2021-12-04T19:25:31.000Z | product/migrations/0017_alter_category_category_name.py | SergueiNK/oc_projet_p8 | a2a3e3df7ecd048207f342343163a3aecf246423 | [
"Unlicense"
] | null | null | null | # Generated by Django 3.2.6 on 2021-10-29 11:27
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('product', '0016_auto_20211029_1210'),
]
operations = [
migrations.AlterField(
model_name='category',
name='category_... | 23.105263 | 94 | 0.626424 |
7956b3a6233334391737ccd58b76467a04784ff3 | 22,611 | py | Python | pandas/core/indexes/category.py | trentpark8800/pandas | 4edf3351b0bfef551a01adf3ca2e6e657448ed80 | [
"PSF-2.0",
"Apache-2.0",
"BSD-3-Clause-No-Nuclear-License-2014",
"MIT",
"ECL-2.0",
"BSD-3-Clause"
] | null | null | null | pandas/core/indexes/category.py | trentpark8800/pandas | 4edf3351b0bfef551a01adf3ca2e6e657448ed80 | [
"PSF-2.0",
"Apache-2.0",
"BSD-3-Clause-No-Nuclear-License-2014",
"MIT",
"ECL-2.0",
"BSD-3-Clause"
] | null | null | null | pandas/core/indexes/category.py | trentpark8800/pandas | 4edf3351b0bfef551a01adf3ca2e6e657448ed80 | [
"PSF-2.0",
"Apache-2.0",
"BSD-3-Clause-No-Nuclear-License-2014",
"MIT",
"ECL-2.0",
"BSD-3-Clause"
] | null | null | null | from typing import Any, List, Optional
import warnings
import numpy as np
from pandas._config import get_option
from pandas._libs import index as libindex
from pandas._libs.lib import no_default
from pandas._typing import ArrayLike, Label
from pandas.util._decorators import Appender, cache_readonly, doc
from pandas... | 34.520611 | 94 | 0.595064 |
7956b3cca36622762023e8eed883294e99b3f814 | 1,026 | py | Python | backend/backend/urls.py | Hosermes/critterco-dev | 963e17f53c162e899353b8468064b67482db9f60 | [
"MIT"
] | 4 | 2020-05-21T08:34:54.000Z | 2020-08-01T11:57:40.000Z | backend/backend/urls.py | HosseinMirjalali/critterco-dev | 909fabf1dca2fb7a50bd163db0ecee67c252c4ac | [
"MIT"
] | 5 | 2020-06-29T11:12:27.000Z | 2020-08-13T11:53:20.000Z | backend/backend/urls.py | Hosermes/critterco-dev | 963e17f53c162e899353b8468064b67482db9f60 | [
"MIT"
] | 2 | 2020-04-30T11:16:22.000Z | 2020-05-15T17:14:12.000Z | from django.contrib import admin
from django.urls import path, include
from django.conf.urls import url
from django.conf import settings
from django.conf.urls.static import static
from rest_framework_simplejwt.views import (
TokenObtainPairView,
TokenRefreshView,
)
urlpatterns = [
path("admin/", admin.site... | 35.37931 | 83 | 0.712476 |
7956b3fa955f64315ca11b2fc0dbc51695307639 | 1,803 | py | Python | test/test_get_address_details_from_callback_e400.py | Crypto-APIs/Crypto_APIs_2.0_SDK_Python | c59ebd914850622b2c6500c4c30af31fb9cecf0e | [
"MIT"
] | 5 | 2021-05-17T04:45:03.000Z | 2022-03-23T12:51:46.000Z | test/test_get_address_details_from_callback_e400.py | Crypto-APIs/Crypto_APIs_2.0_SDK_Python | c59ebd914850622b2c6500c4c30af31fb9cecf0e | [
"MIT"
] | null | null | null | test/test_get_address_details_from_callback_e400.py | Crypto-APIs/Crypto_APIs_2.0_SDK_Python | c59ebd914850622b2c6500c4c30af31fb9cecf0e | [
"MIT"
] | 2 | 2021-06-02T07:32:26.000Z | 2022-02-12T02:36:23.000Z | """
CryptoAPIs
Crypto APIs 2.0 is a complex and innovative infrastructure layer that radically simplifies the development of any Blockchain and Crypto related applications. Organized around REST, Crypto APIs 2.0 can assist both novice Bitcoin/Ethereum enthusiasts and crypto experts with the development of thei... | 40.066667 | 484 | 0.793677 |
7956b522a5f8016bc4a462e4a6402a1c7314971d | 325 | py | Python | app/user/migrations/0011_remove_user_username.py | lenaunderwood22/django-forum | 9d739166029197dcd7256d1250641928cff01251 | [
"MIT"
] | null | null | null | app/user/migrations/0011_remove_user_username.py | lenaunderwood22/django-forum | 9d739166029197dcd7256d1250641928cff01251 | [
"MIT"
] | null | null | null | app/user/migrations/0011_remove_user_username.py | lenaunderwood22/django-forum | 9d739166029197dcd7256d1250641928cff01251 | [
"MIT"
] | null | null | null | # Generated by Django 3.2.4 on 2021-10-12 08:58
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('user', '0010_auto_20211012_0847'),
]
operations = [
migrations.RemoveField(
model_name='user',
name='username',
),
... | 18.055556 | 47 | 0.587692 |
7956b582ae0f6160babd4b8e7b8865a51218d932 | 24 | py | Python | SerumWriter/Utils/Constants.py | serumstudio/SerumWriter | 5e212b49e8d3da3890cd685a985438d298db5e26 | [
"MIT"
] | 2 | 2022-03-24T05:29:02.000Z | 2022-03-24T11:01:44.000Z | SerumWriter/Utils/Constants.py | serumstudio/SerumWriter | 5e212b49e8d3da3890cd685a985438d298db5e26 | [
"MIT"
] | null | null | null | SerumWriter/Utils/Constants.py | serumstudio/SerumWriter | 5e212b49e8d3da3890cd685a985438d298db5e26 | [
"MIT"
] | null | null | null |
LIB_KEY = 'sidlibv1.0' | 12 | 22 | 0.666667 |
7956b5b1c0bec33226f130b9a068af06272f4e96 | 528 | py | Python | windflow/web/helpers.py | hartym/windflow | 69a2aeb3ab9d5bdfcd1d2ce8d5c9af14876cba23 | [
"Apache-2.0"
] | 2 | 2016-09-22T17:17:59.000Z | 2017-08-27T15:40:16.000Z | windflow/web/helpers.py | hartym/windflow | 69a2aeb3ab9d5bdfcd1d2ce8d5c9af14876cba23 | [
"Apache-2.0"
] | 1 | 2019-10-21T14:58:12.000Z | 2019-10-21T14:58:13.000Z | windflow/web/helpers.py | hartym/windflow | 69a2aeb3ab9d5bdfcd1d2ce8d5c9af14876cba23 | [
"Apache-2.0"
] | null | null | null | def create_url_for_helper(name, *parts, **defaults):
def url_for_helper(self, *args, absolute=False, **kwargs):
params = dict(defaults)
params.update(kwargs)
_parts = params.pop('parts', {})
_parts.update(dict(zip(parts, map(str, args))))
if _parts:
params['parts'... | 37.714286 | 63 | 0.638258 |
7956b6710900747ae4aa86a307f0e45e7a18bb28 | 3,933 | py | Python | tests/test_versioning.py | balabit-deps/balabit-os-7-sphinx | 4e18ca37f4ddddf346c0b30835a544db20887259 | [
"BSD-2-Clause"
] | null | null | null | tests/test_versioning.py | balabit-deps/balabit-os-7-sphinx | 4e18ca37f4ddddf346c0b30835a544db20887259 | [
"BSD-2-Clause"
] | null | null | null | tests/test_versioning.py | balabit-deps/balabit-os-7-sphinx | 4e18ca37f4ddddf346c0b30835a544db20887259 | [
"BSD-2-Clause"
] | null | null | null | # -*- coding: utf-8 -*-
"""
test_versioning
~~~~~~~~~~~~~~~
Test the versioning implementation.
:copyright: Copyright 2007-2018 by the Sphinx team, see AUTHORS.
:license: BSD, see LICENSE for details.
"""
import pickle
import pytest
from docutils.parsers.rst.directives.html import MetaBody
from... | 29.133333 | 79 | 0.70506 |
7956b738afd059ba0c67f9fc38a44500f4fc5ba3 | 1,359 | py | Python | setup.py | SummitESP/login-service-backend | a99f53069837f32d95be0bd46a11d54cc83544d9 | [
"MIT"
] | null | null | null | setup.py | SummitESP/login-service-backend | a99f53069837f32d95be0bd46a11d54cc83544d9 | [
"MIT"
] | 1 | 2019-03-07T22:54:41.000Z | 2019-03-07T22:54:41.000Z | setup.py | SummitESP/login-service-backend | a99f53069837f32d95be0bd46a11d54cc83544d9 | [
"MIT"
] | 1 | 2021-04-14T16:25:52.000Z | 2021-04-14T16:25:52.000Z | #!/usr/bin/env python
import login_backend
long_description = open('README.md').read()
setup_args = dict(
name='login-service-backend',
version=login_backend.__version__,
description='Django authentication backend for Summit tools unified Login Service.',
long_description=long_description,
author... | 32.357143 | 88 | 0.627667 |
7956b756dcb3ca5240fae43cf7b63ed0c74b73a1 | 16,352 | py | Python | tests/callbacks/test_lr_monitor.py | calebrob6/pytorch-lightning | 4c79b3a5b343866217784c66d122819c59a92c1d | [
"Apache-2.0"
] | 4 | 2021-07-27T14:39:02.000Z | 2022-03-07T10:57:13.000Z | tests/callbacks/test_lr_monitor.py | calebrob6/pytorch-lightning | 4c79b3a5b343866217784c66d122819c59a92c1d | [
"Apache-2.0"
] | 1 | 2021-03-25T18:10:25.000Z | 2021-04-06T18:54:04.000Z | tests/callbacks/test_lr_monitor.py | calebrob6/pytorch-lightning | 4c79b3a5b343866217784c66d122819c59a92c1d | [
"Apache-2.0"
] | 1 | 2021-03-25T17:09:28.000Z | 2021-03-25T17:09:28.000Z | # Copyright The PyTorch Lightning team.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to i... | 36.017621 | 116 | 0.6483 |
7956b7b285e0a67f8eaf8d6205b5e24f071da8ef | 30,380 | py | Python | DSP_Task1/newestUpdate2.py | Haidy-sayed/SBME-3rd-year-DSP-Tasks | 938d4b64d2debf2fcd0387796aa530d8c25c0777 | [
"MIT"
] | null | null | null | DSP_Task1/newestUpdate2.py | Haidy-sayed/SBME-3rd-year-DSP-Tasks | 938d4b64d2debf2fcd0387796aa530d8c25c0777 | [
"MIT"
] | null | null | null | DSP_Task1/newestUpdate2.py | Haidy-sayed/SBME-3rd-year-DSP-Tasks | 938d4b64d2debf2fcd0387796aa530d8c25c0777 | [
"MIT"
] | null | null | null |
# -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'GUIgodhelpus.ui'
#
# Created by: PyQt5 UI code generator 5.9.2
#
# WARNING! All changes made in this file will be lost!
from pyqtgraph import PlotWidget
import pyqtgraph
from PyQt5 import QtCore, QtGui, QtWidgets
#from matplotlib.pyplot i... | 44.221252 | 119 | 0.664582 |
7956b7e1c70ceeeb2e94618452f1ca400d2722a1 | 8,857 | py | Python | docs/conf.py | cosanlab/multivariate_inference | f591748e6ebd792f4192c1d04014e872af50d08d | [
"MIT"
] | null | null | null | docs/conf.py | cosanlab/multivariate_inference | f591748e6ebd792f4192c1d04014e872af50d08d | [
"MIT"
] | null | null | null | docs/conf.py | cosanlab/multivariate_inference | f591748e6ebd792f4192c1d04014e872af50d08d | [
"MIT"
] | null | null | null | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# multivariate_inference documentation build configuration file, created by
# sphinx-quickstart on Tue Jul 9 22:26:36 2013.
#
# This file is execfile()d with the current directory set to its
# containing dir.
#
# Note that not all possible configuration values are presen... | 30.860627 | 76 | 0.722366 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.