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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
798313d08d97263e540207a645df534d5226e75a | 5,728 | py | Python | scripts/profile.py | bartvbw/MILO | 334e9bdec954b0cb82da0576b339729e3f39afd0 | [
"BSD-2-Clause"
] | 3 | 2018-10-23T21:04:15.000Z | 2020-01-03T21:49:05.000Z | scripts/profile.py | bartvbw/MILO | 334e9bdec954b0cb82da0576b339729e3f39afd0 | [
"BSD-2-Clause"
] | 1 | 2018-11-27T23:41:57.000Z | 2018-11-27T23:41:57.000Z | scripts/profile.py | bartvbw/MILO | 334e9bdec954b0cb82da0576b339729e3f39afd0 | [
"BSD-2-Clause"
] | 1 | 2018-11-13T15:53:47.000Z | 2018-11-13T15:53:47.000Z | #!/usr/bin/python
# This reads in the profile file (MILO.profile) as YAML and creates graphics
import numpy as np
import matplotlib.pyplot as plt
import matplotlib.cm as cm
import sys
prof = open("MILO.profile", "r")
lines = prof.readlines()
numlines = len(lines)
# Important settings/options
nargs = len(sys.argv)... | 25.122807 | 125 | 0.61243 |
79831452919809d8e6662d5b6ca636ec60490c32 | 10,053 | py | Python | contrib/spendfrom/spendfrom.py | mihocradu/miragecoin | 55ee4696950496f262c2ac0f9cfe7d4021f00e47 | [
"MIT"
] | null | null | null | contrib/spendfrom/spendfrom.py | mihocradu/miragecoin | 55ee4696950496f262c2ac0f9cfe7d4021f00e47 | [
"MIT"
] | null | null | null | contrib/spendfrom/spendfrom.py | mihocradu/miragecoin | 55ee4696950496f262c2ac0f9cfe7d4021f00e47 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
#
# Use the raw transactions API to spend bitcoins received on particular addresses,
# and send any change back to that same address.
#
# Example usage:
# spendfrom.py # Lists available funds
# spendfrom.py --from=ADDRESS --to=ADDRESS --amount=11.00
#
# Assumes it will talk to a bitcoind or Bit... | 37.511194 | 111 | 0.632249 |
798314d0ad8e5eeffdef675402ec89455ff81bab | 3,041 | py | Python | examples/smoke_test.py | lanius/vuzixwrapdev | 694ce5b53599cdad3979f1193efe1b83a36dbd38 | [
"MIT"
] | 1 | 2015-07-31T21:54:49.000Z | 2015-07-31T21:54:49.000Z | examples/smoke_test.py | lanius/vuzixwrapdev | 694ce5b53599cdad3979f1193efe1b83a36dbd38 | [
"MIT"
] | null | null | null | examples/smoke_test.py | lanius/vuzixwrapdev | 694ce5b53599cdad3979f1193efe1b83a36dbd38 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
import argparse
import os
import unittest
import vuzixwrapdev
#import calibration # can't be tested yet
import display
import recording
import transmission
class BaseDeviceTestCase(unittest.TestCase):
record_file = 'test_record.vzrec'
address = ('localhost', 8080) # for UDP testi... | 26.911504 | 78 | 0.686287 |
79831541e845af45672e8b4755c3a02940da1561 | 7,148 | py | Python | setup.py | JLSteenwyk/PhyKIT | 0b3194d1bb5c189993b256fe96011cce48b9bbb4 | [
"MIT"
] | 26 | 2020-10-28T10:33:33.000Z | 2022-02-04T14:59:22.000Z | setup.py | JLSteenwyk/PhyKIT | 0b3194d1bb5c189993b256fe96011cce48b9bbb4 | [
"MIT"
] | 4 | 2021-03-28T22:05:39.000Z | 2022-03-22T00:33:01.000Z | setup.py | JLSteenwyk/PhyKIT | 0b3194d1bb5c189993b256fe96011cce48b9bbb4 | [
"MIT"
] | 4 | 2020-11-06T11:58:25.000Z | 2021-08-17T16:57:51.000Z | from os import path
from setuptools import setup, find_packages
from phykit.version import __version__
here = path.abspath(path.dirname(__file__))
with open(path.join(here, "README.md")) as f:
long_description = f.read()
CLASSIFIERS = [
'Operating System :: OS Independent',
'Intended Audience :: Science... | 50.338028 | 108 | 0.662563 |
798315546ec4c11bd7eed1c13909fabd7cf98a12 | 7,067 | py | Python | DQMOffline/Configuration/python/DQMOfflineHeavyIons_cff.py | sebwieland/cmssw | 431e2fdfedec052e73c16e9f06de98ade41ebc56 | [
"Apache-2.0"
] | 2 | 2020-01-27T15:21:37.000Z | 2020-05-11T11:13:18.000Z | DQMOffline/Configuration/python/DQMOfflineHeavyIons_cff.py | sebwieland/cmssw | 431e2fdfedec052e73c16e9f06de98ade41ebc56 | [
"Apache-2.0"
] | null | null | null | DQMOffline/Configuration/python/DQMOfflineHeavyIons_cff.py | sebwieland/cmssw | 431e2fdfedec052e73c16e9f06de98ade41ebc56 | [
"Apache-2.0"
] | 1 | 2020-10-06T16:30:09.000Z | 2020-10-06T16:30:09.000Z | import FWCore.ParameterSet.Config as cms
from DQMServices.Components.DQMMessageLogger_cfi import *
from DQMServices.Components.DQMDcsInfo_cfi import *
from DQMServices.Components.DQMFastTimerService_cff import *
from DQMOffline.L1Trigger.L1TriggerDqmOffline_cff import *
from DQMOffline.Ecal.ecal_dqm_source_offline_HI... | 45.593548 | 116 | 0.782369 |
798315f38aa96accb977d2486a9d99cf8bbd9b3b | 15,740 | py | Python | game_agent.py | andreistoc/aind-isolation | 47f8ff8fa0731fc782b75b866130b29c0812793b | [
"MIT"
] | null | null | null | game_agent.py | andreistoc/aind-isolation | 47f8ff8fa0731fc782b75b866130b29c0812793b | [
"MIT"
] | null | null | null | game_agent.py | andreistoc/aind-isolation | 47f8ff8fa0731fc782b75b866130b29c0812793b | [
"MIT"
] | null | null | null | """Finish all TODO items in this file to complete the isolation project, then
test your agent's strength against a set of known agents using tournament.py
and include the results in your report.
"""
import random
class SearchTimeout(Exception):
"""Subclass base exception for code clarity. """
pass
def custo... | 36.018307 | 132 | 0.593837 |
798315fa007e5c2337fc80cdb3c8d01e68f6c63e | 31,199 | py | Python | pypureclient/flasharray/FA_2_9/api/protection_group_snapshots_api.py | ashahid-ps/py-pure-client | 2e3565d37b2a41db69308769f6f485d08a7c46c3 | [
"BSD-2-Clause"
] | null | null | null | pypureclient/flasharray/FA_2_9/api/protection_group_snapshots_api.py | ashahid-ps/py-pure-client | 2e3565d37b2a41db69308769f6f485d08a7c46c3 | [
"BSD-2-Clause"
] | null | null | null | pypureclient/flasharray/FA_2_9/api/protection_group_snapshots_api.py | ashahid-ps/py-pure-client | 2e3565d37b2a41db69308769f6f485d08a7c46c3 | [
"BSD-2-Clause"
] | null | null | null | # coding: utf-8
"""
FlashArray REST API
No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
OpenAPI spec version: 2.9
Generated by: https://github.com/swagger-api/swagger-codegen.git
"""
from __future__ import absolute_import
import re
# pyth... | 53.149915 | 671 | 0.661848 |
798316d55af43c3f117c391f8e8a4c77dd76bac1 | 101 | py | Python | keras_textclassification/data/embeddings/chinese_xlnet_mid_L-24_H-768_A-12/__init__.py | rogeroyer/Keras-TextClassification | 09c9dbf6eb29cdcaac913d2d3ba21d246ec9752a | [
"MIT"
] | 2 | 2021-06-05T04:11:27.000Z | 2021-09-29T02:02:13.000Z | keras_textclassification/data/embeddings/chinese_xlnet_mid_L-24_H-768_A-12/__init__.py | zxlzr/Keras-TextClassification | 09c9dbf6eb29cdcaac913d2d3ba21d246ec9752a | [
"MIT"
] | null | null | null | keras_textclassification/data/embeddings/chinese_xlnet_mid_L-24_H-768_A-12/__init__.py | zxlzr/Keras-TextClassification | 09c9dbf6eb29cdcaac913d2d3ba21d246ec9752a | [
"MIT"
] | 1 | 2019-09-27T08:13:48.000Z | 2019-09-27T08:13:48.000Z | # -*- coding: UTF-8 -*-
# !/usr/bin/python
# @time :2019/8/28 14:08
# @author :Mo
# @function : | 20.2 | 28 | 0.524752 |
7983181e4deb26b193036cc64f778bb9eb988bd8 | 3,926 | py | Python | scratch/regression/mass_range_13.4/train_9sims_random_alpha-2.py | finn-dodgson/DeepHalos | 86e0ac6c24ac97a0a2a0a60a7ea3721a04bd050c | [
"MIT"
] | 2 | 2021-07-26T10:56:33.000Z | 2021-12-20T17:30:53.000Z | scratch/regression/mass_range_13.4/train_9sims_random_alpha-2.py | finn-dodgson/DeepHalos | 86e0ac6c24ac97a0a2a0a60a7ea3721a04bd050c | [
"MIT"
] | 1 | 2021-11-25T21:01:19.000Z | 2021-12-05T01:40:53.000Z | scratch/regression/mass_range_13.4/train_9sims_random_alpha-2.py | finn-dodgson/DeepHalos | 86e0ac6c24ac97a0a2a0a60a7ea3721a04bd050c | [
"MIT"
] | 1 | 2021-11-27T02:35:10.000Z | 2021-11-27T02:35:10.000Z | from dlhalos_code import CNN
from dlhalos_code import custom_regularizers as reg
import dlhalos_code.data_processing as tn
from pickle import load
import numpy as np
import tensorflow as tf
import random as python_random
import tensorflow.keras as keras
import tensorflow.keras.callbacks as callbacks
if __name__ == "_... | 50.333333 | 115 | 0.616403 |
7983187e9a3795b928abdd4bc1ffd3d0e5258a9e | 10,591 | py | Python | docs/html/conf.py | leodelasoul/pip | a337a4c26f60fb5317937d7f9334f2862b43dce4 | [
"MIT"
] | null | null | null | docs/html/conf.py | leodelasoul/pip | a337a4c26f60fb5317937d7f9334f2862b43dce4 | [
"MIT"
] | null | null | null | docs/html/conf.py | leodelasoul/pip | a337a4c26f60fb5317937d7f9334f2862b43dce4 | [
"MIT"
] | 2 | 2020-11-19T17:45:20.000Z | 2020-11-19T17:45:34.000Z | # -*- coding: utf-8 -*-
#
# pip documentation build configuration file, created by
# sphinx-quickstart on Tue Apr 22 22:08:49 2008
#
# 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.
#
# All confi... | 33.200627 | 79 | 0.692569 |
798318c7d99aa4943c9e45b7af706a55b736e845 | 11,562 | py | Python | setup.py | Perados/incubator-airflow | 89c1f530da04088300312ad3cec9fa74c3703176 | [
"Apache-2.0"
] | 1 | 2018-07-01T10:00:37.000Z | 2018-07-01T10:00:37.000Z | setup.py | Perados/incubator-airflow | 89c1f530da04088300312ad3cec9fa74c3703176 | [
"Apache-2.0"
] | null | null | null | setup.py | Perados/incubator-airflow | 89c1f530da04088300312ad3cec9fa74c3703176 | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
#
# 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
#... | 31.080645 | 90 | 0.557689 |
7983190dbe836f3aced7c4d16bdfa22efe16e19d | 23,149 | py | Python | homeassistant/helpers/service.py | makuser/core | ffe42e150a8f061bef86e438efd120eafb884a43 | [
"Apache-2.0"
] | null | null | null | homeassistant/helpers/service.py | makuser/core | ffe42e150a8f061bef86e438efd120eafb884a43 | [
"Apache-2.0"
] | null | null | null | homeassistant/helpers/service.py | makuser/core | ffe42e150a8f061bef86e438efd120eafb884a43 | [
"Apache-2.0"
] | null | null | null | """Service calling related helpers."""
from __future__ import annotations
import asyncio
import dataclasses
from functools import partial, wraps
import logging
from typing import (
TYPE_CHECKING,
Any,
Awaitable,
Callable,
Dict,
Iterable,
List,
Optional,
Set,
Tuple,
TypedDict... | 30.701592 | 146 | 0.64141 |
798319a0c719ae50dd17c6180eedf0f4dd7ef113 | 1,640 | py | Python | blog/templatetags/blog_tags.py | AliYmn/Django-Blog-Project | 98ef136585d570b50d2c347332ac62d15ae4d9e4 | [
"MIT"
] | 5 | 2021-02-07T16:20:44.000Z | 2021-12-16T16:47:06.000Z | blog/templatetags/blog_tags.py | AliYmn/DjangoBlog | 98ef136585d570b50d2c347332ac62d15ae4d9e4 | [
"MIT"
] | 2 | 2020-06-05T17:47:08.000Z | 2021-06-10T19:37:19.000Z | blog/templatetags/blog_tags.py | AliYmn/Django-Blog-Project | 98ef136585d570b50d2c347332ac62d15ae4d9e4 | [
"MIT"
] | 4 | 2020-04-05T18:53:52.000Z | 2022-01-05T22:48:15.000Z | from django import template
from blog.models import SiteInfo
title = ""
slogan = ""
author = ""
tags = ""
description = ""
image = ""
bio_short = ""
bio_long = ""
bio_index = ""
facebook = ""
github = ""
twitter = ""
email = ""
for i in SiteInfo.objects.all():
title = i.title
slogan = i.slogan
author = i.... | 17.446809 | 53 | 0.693293 |
798319ff17d40cf420adb97ffd0812d754ff4ef9 | 741 | py | Python | schema_parser/utils/type_parser.py | SumuduLansakara/JsonToStruct | 82d5ed613fc313dedeeada94679e0edbc0a5486a | [
"MIT"
] | null | null | null | schema_parser/utils/type_parser.py | SumuduLansakara/JsonToStruct | 82d5ed613fc313dedeeada94679e0edbc0a5486a | [
"MIT"
] | null | null | null | schema_parser/utils/type_parser.py | SumuduLansakara/JsonToStruct | 82d5ed613fc313dedeeada94679e0edbc0a5486a | [
"MIT"
] | null | null | null | from typing import Dict, List
from schema_parser.reg_key import RegKey
from schema_parser.type_defs.type_def_base import TypeDefBase
from schema_parser.type_registry import TypeRegistry
from schema_parser.utils.type_loader import get_object_type
def create_typedef(reg_key: RegKey, namespaces: List[str], name: str, d... | 37.05 | 118 | 0.773279 |
79831a178320dea17098755b72ff912635f8402f | 256 | py | Python | dropbox_problem/problem_6.py | loftwah/Daily-Coding-Problem | 0327f0b4f69ef419436846c831110795c7a3c1fe | [
"MIT"
] | 129 | 2018-10-14T17:52:29.000Z | 2022-01-29T15:45:57.000Z | dropbox_problem/problem_6.py | loftwah/Daily-Coding-Problem | 0327f0b4f69ef419436846c831110795c7a3c1fe | [
"MIT"
] | 2 | 2019-11-30T23:28:23.000Z | 2020-01-03T16:30:32.000Z | dropbox_problem/problem_6.py | loftwah/Daily-Coding-Problem | 0327f0b4f69ef419436846c831110795c7a3c1fe | [
"MIT"
] | 60 | 2019-02-21T09:18:31.000Z | 2022-03-25T21:01:04.000Z | """This problem was asked by Dropbox.
Given an undirected graph G, check whether it is bipartite.
Recall that a graph is bipartite if its vertices can be divided into two
independent sets, U and V, such that no edge connects vertices of the same set.""" | 51.2 | 82 | 0.769531 |
79831a31f80f96ac68c72300989987837bb2888f | 5,297 | py | Python | models/dense_net.py | adityaXXX/Snapshot-Ensembles | 020a393dd7d3ab4ac74e86a6ade7d1f5a83d6144 | [
"Apache-2.0"
] | 310 | 2016-11-07T16:33:58.000Z | 2021-11-19T11:30:50.000Z | models/dense_net.py | ChenglongChen/Snapshot-Ensembles | 020a393dd7d3ab4ac74e86a6ade7d1f5a83d6144 | [
"Apache-2.0"
] | 16 | 2016-11-22T22:04:29.000Z | 2022-01-17T12:16:05.000Z | models/dense_net.py | ChenglongChen/Snapshot-Ensembles | 020a393dd7d3ab4ac74e86a6ade7d1f5a83d6144 | [
"Apache-2.0"
] | 76 | 2016-12-19T02:02:35.000Z | 2022-02-02T14:46:48.000Z | '''
Code from my DenseNet repository : https://github.com/titu1994/DenseNet
'''
from keras.models import Model
from keras.layers.core import Dense, Dropout, Activation
from keras.layers.convolutional import Convolution2D
from keras.layers.pooling import AveragePooling2D
from keras.layers.pooling import GlobalAverageP... | 35.550336 | 118 | 0.677931 |
79831a89a400a94b1d74354209f44d9f4b19390d | 3,105 | py | Python | src/FPTE/FPTE_Ensemble_Average_AIMD.py | MahdiDavari/FPTE | 9b95730bca92c796c488fd92dbb4a27bd3ca6e7a | [
"MIT"
] | 7 | 2019-05-08T03:03:21.000Z | 2021-07-17T11:45:12.000Z | src/FPTE/FPTE_Ensemble_Average_AIMD.py | MahdiDavari/FPTE | 9b95730bca92c796c488fd92dbb4a27bd3ca6e7a | [
"MIT"
] | null | null | null | src/FPTE/FPTE_Ensemble_Average_AIMD.py | MahdiDavari/FPTE | 9b95730bca92c796c488fd92dbb4a27bd3ca6e7a | [
"MIT"
] | 6 | 2019-03-08T17:16:40.000Z | 2021-07-17T11:45:15.000Z | #!/usr/bin/env python
import os
import numpy as np
import argparse
import sys
'''
This file discards the initial ionic steps in order to reach equilibration.
It is recommended to discard at least 1 ps - the default is 1000 steps.
'''
__author__ = "Mahdi Davari"
__version__ = "1.0.0"
__email__ = "Mahdi.Dava... | 34.120879 | 140 | 0.592271 |
79831a9dc17fb4602d6432baae7457c599ac09db | 2,385 | py | Python | brainfrick/interpreter.py | UnknownPlayer78/brainfrick | 7e56a6053fc57342720c491491c81c05c92972ae | [
"Unlicense"
] | null | null | null | brainfrick/interpreter.py | UnknownPlayer78/brainfrick | 7e56a6053fc57342720c491491c81c05c92972ae | [
"Unlicense"
] | null | null | null | brainfrick/interpreter.py | UnknownPlayer78/brainfrick | 7e56a6053fc57342720c491491c81c05c92972ae | [
"Unlicense"
] | null | null | null | from .memory import Memory
from .utils import find_closing_bracket, find_opening_bracket
DEBUG = False
class Interpreter:
BRAINFUCK = ["+", "-", "<", ">", "[", "]", ",", "."]
pointer = 0
def __init__(self, file=""):
self.file = file
if file != "":
self.read_file()
else... | 23.382353 | 78 | 0.516562 |
79831acb716556135d16ea5e7509446a1f83d1cc | 9,768 | py | Python | jax/linear_util.py | SIben/jax | 3ac809ede30d961b873ca62f9828090709ced6be | [
"ECL-2.0",
"Apache-2.0"
] | null | null | null | jax/linear_util.py | SIben/jax | 3ac809ede30d961b873ca62f9828090709ced6be | [
"ECL-2.0",
"Apache-2.0"
] | null | null | null | jax/linear_util.py | SIben/jax | 3ac809ede30d961b873ca62f9828090709ced6be | [
"ECL-2.0",
"Apache-2.0"
] | null | null | null | # Copyright 2018 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, ... | 33.111864 | 105 | 0.714476 |
79831b8c661cbf75f7623b062d50b759a999a017 | 521 | py | Python | bsp2_9.py | Nabizeus/merkmalskonstruktion | e6553a290d36b3bb4079e0ba21989e192d70eb6b | [
"Apache-2.0"
] | null | null | null | bsp2_9.py | Nabizeus/merkmalskonstruktion | e6553a290d36b3bb4079e0ba21989e192d70eb6b | [
"Apache-2.0"
] | null | null | null | bsp2_9.py | Nabizeus/merkmalskonstruktion | e6553a290d36b3bb4079e0ba21989e192d70eb6b | [
"Apache-2.0"
] | null | null | null | import pandas as pd
import json
import matplotlib.pyplot as plt
import numpy as np
from sklearn import linear_model
from sklearn.model_selection import cross_val_score
# Beispiel 2.9 - Online News
# Datensatz
df = pd.read_csv('data/OnlineNewsPopularity.csv', delimiter=',')
df.head()
# Bilde die Logarithmustransf... | 20.84 | 74 | 0.767754 |
79831cd30c4d95101bf3dc70991276d9cda357df | 2,602 | py | Python | tests/test_tokenization_layoutlm.py | liminghao1630/transformers | 207594be81b8e5a8589c8b11c3b236924555d806 | [
"Apache-2.0"
] | 50,404 | 2019-09-26T09:55:55.000Z | 2022-03-31T23:07:49.000Z | tests/test_tokenization_layoutlm.py | liminghao1630/transformers | 207594be81b8e5a8589c8b11c3b236924555d806 | [
"Apache-2.0"
] | 13,179 | 2019-09-26T10:10:57.000Z | 2022-03-31T23:17:08.000Z | tests/test_tokenization_layoutlm.py | liminghao1630/transformers | 207594be81b8e5a8589c8b11c3b236924555d806 | [
"Apache-2.0"
] | 13,337 | 2019-09-26T10:49:38.000Z | 2022-03-31T23:06:17.000Z | # coding=utf-8
# Copyright 2018 The Microsoft Research Asia LayoutLM Team Authors, The Hugging Face 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/license... | 34.693333 | 132 | 0.677171 |
79831d0f49a9ca2a1cc70cb4ab00116411013edd | 170 | py | Python | capstone/game/players/__init__.py | davidrobles/mlnd-capstone-code | 19ca88aaa137665af147da9bbd0e510829a14cf1 | [
"MIT"
] | 2 | 2017-04-13T18:31:39.000Z | 2017-05-06T05:14:12.000Z | capstone/game/players/__init__.py | davidrobles/mlnd-capstone-code | 19ca88aaa137665af147da9bbd0e510829a14cf1 | [
"MIT"
] | null | null | null | capstone/game/players/__init__.py | davidrobles/mlnd-capstone-code | 19ca88aaa137665af147da9bbd0e510829a14cf1 | [
"MIT"
] | null | null | null | from .alphabeta import AlphaBeta
from .greedyq import GreedyQ
from .kerasplayer import KerasPlayer
from .monte_carlo import MonteCarlo
from .randplayer import RandPlayer
| 28.333333 | 36 | 0.852941 |
79831e8007e767b9cfbeddef37ae2b1fc2bf7df0 | 8,198 | py | Python | ventilator_gui.py | uBhappy2/ventivader-rpi | fb0354ca9b08e359c7c281c97922b7577690516d | [
"MIT"
] | null | null | null | ventilator_gui.py | uBhappy2/ventivader-rpi | fb0354ca9b08e359c7c281c97922b7577690516d | [
"MIT"
] | 1 | 2020-04-26T18:23:02.000Z | 2020-04-26T18:23:02.000Z | ventilator_gui.py | uBhappy2/ventivader-rpi | fb0354ca9b08e359c7c281c97922b7577690516d | [
"MIT"
] | 1 | 2020-04-19T00:13:03.000Z | 2020-04-19T00:13:03.000Z | #import important packages
from tkinter import *
import time
from tkinter import font
import tkinter.messagebox as messagebox
import serial
from time import sleep
import RPi.GPIO as GPIO
import board
import busio
import adafruit_bmp280
import ventilator_functionsd as mm
import board
import busio
import adafruit_bmp28... | 32.661355 | 137 | 0.547451 |
79831ed03296606fda1ce04d2f21faa66899bbad | 1,559 | py | Python | deploy/post/glance.py | hashnfv/hashnfv-daisy | 01f25b9ed0f203eda46f1f49461efae9b17cab5b | [
"Apache-2.0"
] | null | null | null | deploy/post/glance.py | hashnfv/hashnfv-daisy | 01f25b9ed0f203eda46f1f49461efae9b17cab5b | [
"Apache-2.0"
] | null | null | null | deploy/post/glance.py | hashnfv/hashnfv-daisy | 01f25b9ed0f203eda46f1f49461efae9b17cab5b | [
"Apache-2.0"
] | null | null | null | ##############################################################################
# Copyright (c) 2017 ZTE Coreporation and others.
# feng.xiaowei@zte.com.cn
# All rights reserved. This program and the accompanying materials
# are made available under the terms of the Apache License, Version 2.0
# which accompanies this d... | 37.119048 | 78 | 0.56254 |
798321533035453e0a4d6599a0b81b907fe92d58 | 7,278 | py | Python | accelbyte_py_sdk/api/iam/operations/users/create_user.py | encyphered/accelbyte-python-sdk | 09c1e989d7251de308150fdcd3119d662ca2d205 | [
"MIT"
] | null | null | null | accelbyte_py_sdk/api/iam/operations/users/create_user.py | encyphered/accelbyte-python-sdk | 09c1e989d7251de308150fdcd3119d662ca2d205 | [
"MIT"
] | null | null | null | accelbyte_py_sdk/api/iam/operations/users/create_user.py | encyphered/accelbyte-python-sdk | 09c1e989d7251de308150fdcd3119d662ca2d205 | [
"MIT"
] | null | null | null | # Auto-generated at 2021-09-27T17:01:24.536546+08:00
# from: Justice Iam Service (4.1.0)
# Copyright (c) 2018 - 2021 AccelByte Inc. All Rights Reserved.
# This is licensed software from AccelByte Inc, for limitations
# and restrictions contact your company contract manager.
# pylint: disable=duplicate-code
# pylint: ... | 28.766798 | 172 | 0.62792 |
798321609345c00e70b8fda6749ce69d929bdee4 | 9,796 | py | Python | CookieTTS/utils/torchmoji/create_vocab.py | AstraliteHeart/cookietts | c871f5f7b5790656d5b57bcd9e63946a2da52f0f | [
"BSD-3-Clause"
] | 25 | 2020-07-07T20:07:41.000Z | 2021-12-17T11:27:36.000Z | CookieTTS/utils/torchmoji/create_vocab.py | AstraliteHeart/cookietts | c871f5f7b5790656d5b57bcd9e63946a2da52f0f | [
"BSD-3-Clause"
] | 26 | 2020-07-04T00:06:25.000Z | 2022-02-10T03:28:35.000Z | CookieTTS/utils/torchmoji/create_vocab.py | AstraliteHeart/cookietts | c871f5f7b5790656d5b57bcd9e63946a2da52f0f | [
"BSD-3-Clause"
] | 11 | 2020-07-02T21:39:59.000Z | 2022-01-17T22:09:46.000Z | # -*- coding: utf-8 -*-
from __future__ import print_function, division
import glob
import json
import uuid
from copy import deepcopy
from collections import defaultdict, OrderedDict
import numpy as np
from CookieTTS.utils.torchmoji.filter_utils import is_special_token
from CookieTTS.utils.torchmoji.word_generator im... | 36.014706 | 85 | 0.608003 |
79832163f5bc0c88f45bf78275d743c16c25cbd8 | 774 | py | Python | chat_downloader/sites/__init__.py | xenova/ChatReplayDownloader | ff9ddb1f840fa06d0cc3976badf75c1fffebd003 | [
"MIT"
] | null | null | null | chat_downloader/sites/__init__.py | xenova/ChatReplayDownloader | ff9ddb1f840fa06d0cc3976badf75c1fffebd003 | [
"MIT"
] | null | null | null | chat_downloader/sites/__init__.py | xenova/ChatReplayDownloader | ff9ddb1f840fa06d0cc3976badf75c1fffebd003 | [
"MIT"
] | null | null | null | """Lists the sites that are supported"""
from .youtube import YouTubeChatDownloader
from .twitch import TwitchChatDownloader
# from .facebook import FacebookChatDownloader
from .reddit import RedditChatDownloader
from .common import BaseChatDownloader
def get_all_sites(include_parent=False):
"""Get all supported... | 32.25 | 128 | 0.739018 |
7983224bdc9a3ff565c7b81af62adcdc64d2f0e8 | 2,839 | py | Python | eval_metrics.py | lealex262/DeepSpeaker-pytorch | 99724865fe5658115698f2f36ea6db984829d7af | [
"MIT"
] | null | null | null | eval_metrics.py | lealex262/DeepSpeaker-pytorch | 99724865fe5658115698f2f36ea6db984829d7af | [
"MIT"
] | null | null | null | eval_metrics.py | lealex262/DeepSpeaker-pytorch | 99724865fe5658115698f2f36ea6db984829d7af | [
"MIT"
] | null | null | null | import numpy as np
from sklearn.model_selection import KFold
from scipy import interpolate
def evaluate(distances, labels):
# Calculate evaluation metrics
thresholds = np.arange(0, 30, 0.01)
tpr, fpr, accuracy = calculate_roc(thresholds, distances,
labels)
return tpr, fpr, accuracy
def calcul... | 32.632184 | 125 | 0.711166 |
79832259e839fdd61acdf4fef17ee6230b3c6d02 | 4,861 | py | Python | simulation_ws/src/rl-agent/markov/rover_agent.py | acord-robotics/AWS_JPL_OSR_DRL | 4125fc905fe8964d13896b39297908e1aef250ce | [
"Apache-2.0"
] | 13 | 2020-03-16T07:58:52.000Z | 2022-03-05T10:02:48.000Z | simulation_ws/src/rl-agent/markov/rover_agent.py | acord-robotics/AWS_JPL_OSR_DRL | 4125fc905fe8964d13896b39297908e1aef250ce | [
"Apache-2.0"
] | 10 | 2020-09-26T00:48:01.000Z | 2022-03-12T00:19:27.000Z | simulation_ws/src/rl-agent/markov/rover_agent.py | acord-robotics/AWS_JPL_OSR_DRL | 4125fc905fe8964d13896b39297908e1aef250ce | [
"Apache-2.0"
] | 6 | 2020-04-11T11:05:02.000Z | 2022-02-07T07:08:29.000Z | """
This is single machine training worker. It starts a local training and stores the model in S3.
"""
import argparse
import copy
from markov.s3_boto_data_store import S3BotoDataStore, S3BotoDataStoreParameters
from rl_coach.base_parameters import TaskParameters, Frameworks
from rl_coach.utils import short_dynamic_i... | 41.547009 | 114 | 0.647398 |
798323c2cfec26c6e71f479c0a05468245ae7a4a | 51,016 | py | Python | django/template/defaulttags.py | pomarec/django | 98514849dce07acfaa224a90a784bba9d97249e5 | [
"BSD-3-Clause"
] | 1 | 2015-06-14T07:55:29.000Z | 2015-06-14T07:55:29.000Z | django/template/defaulttags.py | pomarec/django | 98514849dce07acfaa224a90a784bba9d97249e5 | [
"BSD-3-Clause"
] | null | null | null | django/template/defaulttags.py | pomarec/django | 98514849dce07acfaa224a90a784bba9d97249e5 | [
"BSD-3-Clause"
] | null | null | null | """Default tags used by the template system, available to all templates."""
from __future__ import unicode_literals
import os
import sys
import re
from datetime import datetime
from itertools import groupby, cycle as itertools_cycle
import warnings
from django.conf import settings
from django.template.base import (No... | 35.775596 | 171 | 0.589717 |
798324429b1ea2b08331bd30eaa89896ecc3d965 | 3,351 | py | Python | Reducer/min_max_reducer.py | pberezina/earthengine-py-notebooks | 4cbe3c52bcc9ed3f1337bf097aa5799442991a5e | [
"MIT"
] | 1 | 2020-03-20T19:39:34.000Z | 2020-03-20T19:39:34.000Z | Reducer/min_max_reducer.py | pberezina/earthengine-py-notebooks | 4cbe3c52bcc9ed3f1337bf097aa5799442991a5e | [
"MIT"
] | null | null | null | Reducer/min_max_reducer.py | pberezina/earthengine-py-notebooks | 4cbe3c52bcc9ed3f1337bf097aa5799442991a5e | [
"MIT"
] | null | null | null | '''
<table class="ee-notebook-buttons" align="left">
<td><a target="_blank" href="https://github.com/giswqs/earthengine-py-notebooks/tree/master/Reducer/min_max_reducer.ipynb"><img width=32px src="https://www.tensorflow.org/images/GitHub-Mark-32px.png" /> View source on GitHub</a></td>
<td><a target="_blank" ... | 36.032258 | 422 | 0.725455 |
798325e60fce91bf98538b7352c9274ec0219f19 | 7,720 | py | Python | sdk/python/pulumi_azure_native/apimanagement/certificate.py | pulumi-bot/pulumi-azure-native | f7b9490b5211544318e455e5cceafe47b628e12c | [
"Apache-2.0"
] | null | null | null | sdk/python/pulumi_azure_native/apimanagement/certificate.py | pulumi-bot/pulumi-azure-native | f7b9490b5211544318e455e5cceafe47b628e12c | [
"Apache-2.0"
] | null | null | null | sdk/python/pulumi_azure_native/apimanagement/certificate.py | pulumi-bot/pulumi-azure-native | f7b9490b5211544318e455e5cceafe47b628e12c | [
"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
from .. import _utilities, _tables
__al... | 51.466667 | 1,747 | 0.675389 |
7983264efbc6486a85c94e05160209bc5436e039 | 4,904 | py | Python | instagram/settings.py | evelyne250/insta-app | 82942ee8117465a1ba15cbcee17793609187e87b | [
"MIT"
] | null | null | null | instagram/settings.py | evelyne250/insta-app | 82942ee8117465a1ba15cbcee17793609187e87b | [
"MIT"
] | 5 | 2020-06-05T23:55:42.000Z | 2021-09-08T01:22:22.000Z | instagram/settings.py | evelyne250/insta-app | 82942ee8117465a1ba15cbcee17793609187e87b | [
"MIT"
] | null | null | null | """
Django settings for instagram project.
Generated by 'django-admin startproject' using Django 1.11.
For more information on this file, see
https://docs.djangoproject.com/en/1.11/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/1.11/ref/settings/
"""
import os... | 25.810526 | 91 | 0.686786 |
798326d35ca7c24eb102301503182a795f356a9c | 4,107 | py | Python | trove/guestagent/strategies/backup/experimental/couchbase_impl.py | zhujzhuo/openstack-trove | e9d073762732ba405828fd54c86a27dcac95cd25 | [
"Apache-2.0"
] | null | null | null | trove/guestagent/strategies/backup/experimental/couchbase_impl.py | zhujzhuo/openstack-trove | e9d073762732ba405828fd54c86a27dcac95cd25 | [
"Apache-2.0"
] | null | null | null | trove/guestagent/strategies/backup/experimental/couchbase_impl.py | zhujzhuo/openstack-trove | e9d073762732ba405828fd54c86a27dcac95cd25 | [
"Apache-2.0"
] | null | null | null | # Copyright (c) 2014 eBay Software Foundation
# 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
#
# Unl... | 37.336364 | 78 | 0.549306 |
798327434988d6017c8303c18e092f52f8634952 | 152 | py | Python | serializer/__init__.py | CplBDJ/brython_serializer | eb5902b9e4eb86c5c6f6660d961905e220f03df2 | [
"MIT"
] | null | null | null | serializer/__init__.py | CplBDJ/brython_serializer | eb5902b9e4eb86c5c6f6660d961905e220f03df2 | [
"MIT"
] | null | null | null | serializer/__init__.py | CplBDJ/brython_serializer | eb5902b9e4eb86c5c6f6660d961905e220f03df2 | [
"MIT"
] | null | null | null | from ._encoder import Encoder
from ._decoder import Decoder
def dump(obj):
return Encoder.json(obj)
def load(obj):
return Decoder.json(obj)
| 13.818182 | 29 | 0.723684 |
798327dcf54fa4513eb95892f752fc04d7e1eb28 | 4,527 | py | Python | oneflow/python/test/ops/test_softmax.py | MaoXianXin/oneflow | 6caa52f3c5ba11a1d67f183bac4c1559b2a58ef5 | [
"Apache-2.0"
] | 1 | 2021-02-22T00:43:08.000Z | 2021-02-22T00:43:08.000Z | oneflow/python/test/ops/test_softmax.py | MaoXianXin/oneflow | 6caa52f3c5ba11a1d67f183bac4c1559b2a58ef5 | [
"Apache-2.0"
] | null | null | null | oneflow/python/test/ops/test_softmax.py | MaoXianXin/oneflow | 6caa52f3c5ba11a1d67f183bac4c1559b2a58ef5 | [
"Apache-2.0"
] | null | null | null | """
Copyright 2020 The OneFlow Authors. All rights reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agr... | 32.568345 | 86 | 0.595317 |
7983282a6de0700b7e42e687196497b18c8c6b71 | 26,216 | py | Python | bin/api_connector_splunk/requests/sessions.py | CyberGRX/api-connector-splunk | 7f1db1cecb7ae367c1882c3188dc9f8bcb6bc4c6 | [
"MIT"
] | 2,151 | 2020-04-18T07:31:17.000Z | 2022-03-31T08:39:18.000Z | office_hours/dependencies/requests/sessions.py | ikottman/alexa-skills | b7322aaf63ea8172af960a1f5f9fa5dc0bc41cf1 | [
"Unlicense"
] | 4,640 | 2015-07-08T16:19:08.000Z | 2019-12-02T15:01:27.000Z | office_hours/dependencies/requests/sessions.py | ikottman/alexa-skills | b7322aaf63ea8172af960a1f5f9fa5dc0bc41cf1 | [
"Unlicense"
] | 698 | 2015-06-02T19:18:35.000Z | 2022-03-29T16:57:15.000Z | # -*- coding: utf-8 -*-
"""
requests.session
~~~~~~~~~~~~~~~~
This module provides a Session object to manage and persist settings across
requests (cookies, auth, proxies).
"""
import os
from collections import Mapping
from datetime import datetime
from .auth import _basic_auth_str
from .compat import cookielib, Ord... | 36.110193 | 115 | 0.619202 |
7983283aedceafaba08aef7dec2d95121866a758 | 4,875 | py | Python | playbooks/library/os_ironic_facts.py | AevaOnline/bifrost | f3e9cf9b983f5becac72a723f55d97a398f9e1f0 | [
"Apache-2.0"
] | 1 | 2019-03-27T12:20:11.000Z | 2019-03-27T12:20:11.000Z | playbooks/library/os_ironic_facts.py | gbraad/openstack-bifrost | 226407dd9a265139435834f5d0295724bf5fef34 | [
"Apache-2.0"
] | null | null | null | playbooks/library/os_ironic_facts.py | gbraad/openstack-bifrost | 226407dd9a265139435834f5d0295724bf5fef34 | [
"Apache-2.0"
] | 1 | 2019-03-09T13:26:39.000Z | 2019-03-09T13:26:39.000Z | #!/usr/bin/env python
# coding: utf-8 -*-
# (c) 2015, Hewlett-Packard Development Company, L.P.
#
# This module is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your o... | 32.5 | 75 | 0.629949 |
798329519604691a954d8f0e5663a4d5136a1900 | 363 | py | Python | loveviolet.py | Inothere/scratch | e1e56aa8e7dbee04304bc6adb8f437f99e04dd31 | [
"MIT"
] | null | null | null | loveviolet.py | Inothere/scratch | e1e56aa8e7dbee04304bc6adb8f437f99e04dd31 | [
"MIT"
] | null | null | null | loveviolet.py | Inothere/scratch | e1e56aa8e7dbee04304bc6adb8f437f99e04dd31 | [
"MIT"
] | null | null | null | print 'Hello world'
def fib(n):
i = 0
a = 0
b = 1
if n == 0:
return 0
for i in range(n):
c = b
b = a+b
a = cwhi
return b
def fib2(n):
if n == 0:
return 0
if n == 1:
return 1
return fib2(n - 1) + fib2(n - 2)
if __name__ == '__main__':
... | 15.782609 | 36 | 0.426997 |
79832a3e120ba329e058e50cdbd2d2d53addd4ca | 14,824 | py | Python | deepSI/fit_systems/ss_linear.py | seaveredge/deepSI | 429dfcc3dba5cebd4ece01ad734c7f543f17f206 | [
"BSD-3-Clause"
] | 2 | 2022-01-26T10:33:13.000Z | 2022-02-16T10:22:42.000Z | deepSI/fit_systems/ss_linear.py | seaveredge/deepSI | 429dfcc3dba5cebd4ece01ad734c7f543f17f206 | [
"BSD-3-Clause"
] | null | null | null | deepSI/fit_systems/ss_linear.py | seaveredge/deepSI | 429dfcc3dba5cebd4ece01ad734c7f543f17f206 | [
"BSD-3-Clause"
] | null | null | null | from deepSI.systems.system import System, System_ss, System_data
from deepSI.fit_systems import System_fittable
import deepSI
import numpy as np
from tqdm import tqdm as tqdm
from warnings import warn
import math
import scipy as sc
from numpy.linalg import pinv
from scipy import linalg
#adapted from https://github.co... | 36.693069 | 259 | 0.555653 |
79832a6df5741d215f92dd2f091f2f4465b9cf7f | 2,535 | py | Python | tutorial/6_user_authentification/flaskblog/routes.py | wjidea/flask_repo | 2083664df012130cbf71b766e6e2d0405e6659d3 | [
"MIT"
] | null | null | null | tutorial/6_user_authentification/flaskblog/routes.py | wjidea/flask_repo | 2083664df012130cbf71b766e6e2d0405e6659d3 | [
"MIT"
] | null | null | null | tutorial/6_user_authentification/flaskblog/routes.py | wjidea/flask_repo | 2083664df012130cbf71b766e6e2d0405e6659d3 | [
"MIT"
] | null | null | null | from flask import render_template, url_for, flash, redirect, request
from flaskblog import app, db, bcrypt
from flaskblog.models import User, Post
from flaskblog.forms import RegistrationForm, LoginForm
from flask_login import login_user, current_user, logout_user, login_required
posts = [
{
'author': 'Co... | 32.088608 | 150 | 0.665089 |
79832b3b4d544ce5482f7704b164197becc618e8 | 662 | py | Python | ex053.py | LucasLCarreira/Python | 03bd64837d74315687e567261a149f0176496348 | [
"MIT"
] | 1 | 2020-04-21T19:14:50.000Z | 2020-04-21T19:14:50.000Z | ex053.py | LucasLCarreira/Python | 03bd64837d74315687e567261a149f0176496348 | [
"MIT"
] | null | null | null | ex053.py | LucasLCarreira/Python | 03bd64837d74315687e567261a149f0176496348 | [
"MIT"
] | null | null | null | # Exercício Python 053
# Leia uma frase qualquer e diga se ela é um palíndromo, desconsiderando os espaços
frase = str(input('Digite uma frase: ')).strip().upper()
c = -1
dividido = frase.split()
unido = ''.join(dividido)
comprimento = (len(unido))
for a in range(comprimento):
print(unido[comprimento + c],end='')
... | 28.782609 | 83 | 0.669184 |
79832b9ea5cd9c08f565154b5d575192ba1b5c0c | 11,191 | py | Python | src/vframe/image/processors/utils/pose_utils.py | VFRAMEio/vframe | 0dbc991697a6de47ccf3b65ced5b1201a45156b6 | [
"MIT"
] | null | null | null | src/vframe/image/processors/utils/pose_utils.py | VFRAMEio/vframe | 0dbc991697a6de47ccf3b65ced5b1201a45156b6 | [
"MIT"
] | null | null | null | src/vframe/image/processors/utils/pose_utils.py | VFRAMEio/vframe | 0dbc991697a6de47ccf3b65ced5b1201a45156b6 | [
"MIT"
] | null | null | null | import numpy as np
import cv2 as cv
from vframe.settings.app_cfg import LOG
from vframe.models.geometry import BBox
N_POINTS = 18
# COCO Output Format
KEYPOINTS_MAPPING = ['nose', 'neck', 'shoulder_right', 'elbow_right', 'wrist_right', 'shoulder_left',
'elbow_left', 'wrist_left', 'hip_right', 'knee_right', 'ankle... | 34.118902 | 115 | 0.627737 |
79832bea1dbfa6331682a5318585cf04dd176a49 | 1,992 | py | Python | options/base_option.py | fenghansen/ELD | 39846c79b5bcb406881c52700d282a9c1149666e | [
"MIT"
] | null | null | null | options/base_option.py | fenghansen/ELD | 39846c79b5bcb406881c52700d282a9c1149666e | [
"MIT"
] | null | null | null | options/base_option.py | fenghansen/ELD | 39846c79b5bcb406881c52700d282a9c1149666e | [
"MIT"
] | null | null | null | import argparse
import models
model_names = sorted(name for name in models.__dict__
if name.islower() and not name.startswith("__")
and callable(models.__dict__[name]))
class BaseOptions():
def __init__(self):
self.parser = argparse.ArgumentParser(formatter_class=argparse.ArgumentDefaultsHelpForm... | 56.914286 | 159 | 0.690763 |
79832cca2b2d58364e7bfceb8a135d34a90dec78 | 718 | py | Python | project/aval/aval.py | zahraalizadeh/zahraalizadeh.github.io | 026047de301949d1aead70f95ac6c5681e71f79b | [
"CC-BY-3.0"
] | null | null | null | project/aval/aval.py | zahraalizadeh/zahraalizadeh.github.io | 026047de301949d1aead70f95ac6c5681e71f79b | [
"CC-BY-3.0"
] | null | null | null | project/aval/aval.py | zahraalizadeh/zahraalizadeh.github.io | 026047de301949d1aead70f95ac6c5681e71f79b | [
"CC-BY-3.0"
] | null | null | null | __author__ = 'Administrator'
# #def prime(n1,n2):
# #plist=[]
# #n=n1
# while n<=n2:
# flag=True
# nlist=range(int((n/2)))[2:]
#
# for i in nlist:
# if n%i==0:
# flag=False
# break
# if flag==True:
# plist.append(n)
# ... | 17.512195 | 37 | 0.438719 |
79832d9771b04cec247b24491336c1ed457b512b | 2,285 | py | Python | bot.py | LeoLYW12138/myDiscordBot | cb7910042b7aea309774d638eddd50e4ffa27cab | [
"MIT"
] | null | null | null | bot.py | LeoLYW12138/myDiscordBot | cb7910042b7aea309774d638eddd50e4ffa27cab | [
"MIT"
] | null | null | null | bot.py | LeoLYW12138/myDiscordBot | cb7910042b7aea309774d638eddd50e4ffa27cab | [
"MIT"
] | null | null | null | import discord
import random
import asyncio
import aiohttp
import json
from discord import Game
from discord.ext.commands import Bot
TOKEN = "NTk1NjM0OTYxMTY0NDAyNzQz.XTHVGQ.rEUM5ew-sqPdyXaa4i5HtscXv0s"
client = Bot(command_prefix="!")
@client.event
async def on_message(message):
# we do not want the bot to repl... | 28.209877 | 95 | 0.663457 |
79832dadb6511f2b86ac364dd99cfc28ef0b52f1 | 893 | py | Python | os.py | Ritul6969/automatic-sorting-system | c41b76b196b6f7f36cfff3a1e21c4d2496fc3d1d | [
"MIT"
] | 2 | 2021-05-04T10:34:08.000Z | 2021-05-05T09:28:34.000Z | os.py | RitulSherkar/automatic-sorting-system | c41b76b196b6f7f36cfff3a1e21c4d2496fc3d1d | [
"MIT"
] | null | null | null | os.py | RitulSherkar/automatic-sorting-system | c41b76b196b6f7f36cfff3a1e21c4d2496fc3d1d | [
"MIT"
] | null | null | null | import os
import shutil
dir = '' # This the folder in which the sorting directories will be created. Add the directory in which you want the files to be sorted
sorA = '' # This is the target folder which the code will sort from. For example the downloads folder
sorter = ['pdf', 'txt' ,'exe']# if you need more so... | 26.264706 | 136 | 0.643897 |
79832dff9065d4fcaba889f74fda833a28eba6e6 | 1,602 | py | Python | pkg/codegen/internal/test/testdata/external-resource-schema/python/pulumi_example/arg_function.py | followben/pulumi | db6c4b88cbee47332bc305f594b1c15eb6803bd7 | [
"Apache-2.0"
] | null | null | null | pkg/codegen/internal/test/testdata/external-resource-schema/python/pulumi_example/arg_function.py | followben/pulumi | db6c4b88cbee47332bc305f594b1c15eb6803bd7 | [
"Apache-2.0"
] | null | null | null | pkg/codegen/internal/test/testdata/external-resource-schema/python/pulumi_example/arg_function.py | followben/pulumi | db6c4b88cbee47332bc305f594b1c15eb6803bd7 | [
"Apache-2.0"
] | null | null | null | # coding=utf-8
# *** WARNING: this file was generated by test. ***
# *** 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, _tables
import pulumi_ra... | 29.127273 | 109 | 0.677278 |
79832eaaa71f8561611453793e83ab7631fc5f43 | 4,931 | py | Python | scraper_utils.py | AliRZ-02/deltahacks2022 | 4604c5b4def948d9ef70c8695b48c60ba111b982 | [
"MIT"
] | null | null | null | scraper_utils.py | AliRZ-02/deltahacks2022 | 4604c5b4def948d9ef70c8695b48c60ba111b982 | [
"MIT"
] | null | null | null | scraper_utils.py | AliRZ-02/deltahacks2022 | 4604c5b4def948d9ef70c8695b48c60ba111b982 | [
"MIT"
] | null | null | null | import json
import pathlib
import re
import time
import bs4
import os
import data_models
import requests
from selenium import webdriver
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as ec
GOOGLE_CHROME_PATH ... | 36.257353 | 105 | 0.632123 |
79832f2b68da1af08d11aee59fc9ed4b23b083b4 | 4,329 | py | Python | dialogue/bot.py | TingWeiKe/ChatBox | 0425ab16b12dff30379a643b1a5debe2540a5014 | [
"MIT"
] | 7 | 2019-04-18T14:40:37.000Z | 2021-05-11T08:36:21.000Z | dialogue/bot.py | TIngWeiKe/ChatBox | 0425ab16b12dff30379a643b1a5debe2540a5014 | [
"MIT"
] | 6 | 2020-06-05T20:20:50.000Z | 2021-06-10T17:48:56.000Z | dialogue/bot.py | TingWeiKe/ChatBox | 0425ab16b12dff30379a643b1a5debe2540a5014 | [
"MIT"
] | 2 | 2019-07-26T06:07:00.000Z | 2020-06-25T17:34:47.000Z | import random
import os
from sklearn.metrics.pairwise import pairwise_distances_argmin
import torch
import torch.nn as nn
from torch.autograd import Variable
from torch.optim import Adam
from .moviebot_model import NewSeq2seq
from .moviebot_data import TrainData
from .utils import *
# Stackoverflow Robot
class StackB... | 40.083333 | 137 | 0.608686 |
79833021a46af32722060e03ea8008468673de36 | 1,191 | py | Python | office_games/urls.py | KLorentzen/office-games | 7f08891892818621c7bf30f6ebed79065cce0237 | [
"MIT"
] | null | null | null | office_games/urls.py | KLorentzen/office-games | 7f08891892818621c7bf30f6ebed79065cce0237 | [
"MIT"
] | 3 | 2021-04-08T19:02:42.000Z | 2021-09-22T18:19:21.000Z | office_games/urls.py | KLorentzen/office-games | 7f08891892818621c7bf30f6ebed79065cce0237 | [
"MIT"
] | null | null | null | """office_games URL Configuration
The `urlpatterns` list routes URLs to views. For more information please see:
https://docs.djangoproject.com/en/3.0/topics/http/urls/
Examples:
Function views
1. Add an import: from my_app import views
2. Add a URL to urlpatterns: path('', views.home, name='home')
Class-... | 34.028571 | 77 | 0.702771 |
79833033f3c98c389f1f60f306c114d289f57d8c | 12,924 | py | Python | panel/io/state.py | Jacob-Barhak/panel | 04cad38ea703e4e69fb76f063a27f4ffe40688e8 | [
"BSD-3-Clause"
] | 1 | 2021-03-09T04:46:05.000Z | 2021-03-09T04:46:05.000Z | panel/io/state.py | Jacob-Barhak/panel | 04cad38ea703e4e69fb76f063a27f4ffe40688e8 | [
"BSD-3-Clause"
] | null | null | null | panel/io/state.py | Jacob-Barhak/panel | 04cad38ea703e4e69fb76f063a27f4ffe40688e8 | [
"BSD-3-Clause"
] | null | null | null | """
Various utilities for recording and embedding state in a rendered app.
"""
import datetime as dt
import json
import threading
from collections import OrderedDict
from weakref import WeakKeyDictionary, WeakSet
from urllib.parse import urljoin
import param
from bokeh.document import Document
from bokeh.io import c... | 34.281167 | 101 | 0.599505 |
79833065678716281886e61319df6792de32cd78 | 1,148 | py | Python | alipay/aop/api/response/AlipayMobilePublicMessagebatchPushResponse.py | snowxmas/alipay-sdk-python-all | 96870ced60facd96c5bce18d19371720cbda3317 | [
"Apache-2.0"
] | 213 | 2018-08-27T16:49:32.000Z | 2021-12-29T04:34:12.000Z | alipay/aop/api/response/AlipayMobilePublicMessagebatchPushResponse.py | snowxmas/alipay-sdk-python-all | 96870ced60facd96c5bce18d19371720cbda3317 | [
"Apache-2.0"
] | 29 | 2018-09-29T06:43:00.000Z | 2021-09-02T03:27:32.000Z | alipay/aop/api/response/AlipayMobilePublicMessagebatchPushResponse.py | snowxmas/alipay-sdk-python-all | 96870ced60facd96c5bce18d19371720cbda3317 | [
"Apache-2.0"
] | 59 | 2018-08-27T16:59:26.000Z | 2022-03-25T10:08:15.000Z | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import json
from alipay.aop.api.response.AlipayResponse import AlipayResponse
class AlipayMobilePublicMessagebatchPushResponse(AlipayResponse):
def __init__(self):
super(AlipayMobilePublicMessagebatchPushResponse, self).__init__()
self._code = None
... | 24.956522 | 115 | 0.635889 |
798330d1efdb170fd353efbcce03b813ae2f585b | 33,723 | py | Python | aima3/agents.py | Calysto/aima3 | 4e6dc9b467d28015630274ff183b75b2ff4ab6eb | [
"MIT"
] | 28 | 2018-04-09T13:02:19.000Z | 2021-06-09T23:04:48.000Z | aima3/agents.py | Devang-25/aima-python-code | 4e6dc9b467d28015630274ff183b75b2ff4ab6eb | [
"MIT"
] | 2 | 2018-06-24T09:41:07.000Z | 2019-02-05T12:45:19.000Z | aima3/agents.py | Devang-25/aima-python-code | 4e6dc9b467d28015630274ff183b75b2ff4ab6eb | [
"MIT"
] | 25 | 2018-05-13T15:43:53.000Z | 2021-02-27T10:54:09.000Z | """Implement Agents and Environments (Chapters 1-2).
The class hierarchies are as follows:
Thing ## A physical object that can exist in an environment
Agent
Wumpus
Dirt
Wall
...
Environment ## An environment holds objects, runs simulations
XYEnvironment
VacuumEnvironment
W... | 34.516888 | 100 | 0.607597 |
798331c6ce2e4cb56dcca8c3e9e474044bf7f5d1 | 17,733 | py | Python | sandbox/lib/pythonbin/asyncssh/editor.py | Jumpscale/sandbox_linux | 2aacd36b467ef30ac83718abfa82c6883b67a02f | [
"Apache-2.0"
] | null | null | null | sandbox/lib/pythonbin/asyncssh/editor.py | Jumpscale/sandbox_linux | 2aacd36b467ef30ac83718abfa82c6883b67a02f | [
"Apache-2.0"
] | 1 | 2018-04-04T12:13:40.000Z | 2018-05-03T07:57:52.000Z | sandbox/lib/pythonbin/asyncssh/editor.py | Jumpscale/sandbox_linux | 2aacd36b467ef30ac83718abfa82c6883b67a02f | [
"Apache-2.0"
] | null | null | null | # Copyright (c) 2016 by Ron Frederick <ronf@timeheart.net>.
# All rights reserved.
#
# This program and the accompanying materials are made available under
# the terms of the Eclipse Public License v1.0 which accompanies this
# distribution and is available at:
#
# http://www.eclipse.org/legal/epl-v10.html
#
# Cont... | 30.364726 | 79 | 0.560368 |
798331f7ca4019dad02e6e790d05b2aaba568149 | 3,237 | py | Python | xautodl/datasets/math_dynamic_generator.py | Joey61Liuyi/AutoDL-Projects | 2092e144920e82d74753a7ac31e1890a150d41cf | [
"MIT"
] | 817 | 2020-01-15T00:23:41.000Z | 2022-03-31T14:52:03.000Z | xautodl/datasets/math_dynamic_generator.py | Joey61Liuyi/AutoDL-Projects | 2092e144920e82d74753a7ac31e1890a150d41cf | [
"MIT"
] | 77 | 2020-01-14T14:02:45.000Z | 2022-03-25T07:06:02.000Z | xautodl/datasets/math_dynamic_generator.py | Joey61Liuyi/AutoDL-Projects | 2092e144920e82d74753a7ac31e1890a150d41cf | [
"MIT"
] | 176 | 2020-01-15T10:39:41.000Z | 2022-03-31T04:24:53.000Z | #####################################################
# Copyright (c) Xuanyi Dong [GitHub D-X-Y], 2021.03 #
#####################################################
import abc
import numpy as np
def assert_list_tuple(x):
assert isinstance(x, (list, tuple))
return len(x)
class DynamicGenerator(abc.ABC):
"""... | 32.69697 | 88 | 0.607352 |
7983327ec74e2576b30fbc5f7e7148db3ce61002 | 1,224 | py | Python | setup.py | faruken/aio-tinder | a8cd9d76d3fa911c4569170e4f00b33f4c47e48d | [
"MIT"
] | 3 | 2019-01-07T10:50:28.000Z | 2022-01-09T06:07:33.000Z | setup.py | faruken/aio-tinder | a8cd9d76d3fa911c4569170e4f00b33f4c47e48d | [
"MIT"
] | null | null | null | setup.py | faruken/aio-tinder | a8cd9d76d3fa911c4569170e4f00b33f4c47e48d | [
"MIT"
] | null | null | null | #!/usr/bin/env python
# -*- coding: utf-8 -*-
from setuptools import (setup, find_packages)
setup(
name="aio-tinder",
version="0.1.8",
description="Asynchronous Tinder API client",
url="https://github.com/faruken/aio-tinder",
author="faruken",
author_email="",
platforms="any",
zip_safe... | 29.853659 | 71 | 0.562908 |
79833488be57338a9e3dfd927911f300f6e512b4 | 6,615 | py | Python | autofit/graphical/factor_graphs/transform.py | vishalbelsare/PyAutoFit | 04b927419fa95c302e0eebab632fc7ebcdc3f06b | [
"MIT"
] | null | null | null | autofit/graphical/factor_graphs/transform.py | vishalbelsare/PyAutoFit | 04b927419fa95c302e0eebab632fc7ebcdc3f06b | [
"MIT"
] | null | null | null | autofit/graphical/factor_graphs/transform.py | vishalbelsare/PyAutoFit | 04b927419fa95c302e0eebab632fc7ebcdc3f06b | [
"MIT"
] | null | null | null |
from abc import ABC, abstractmethod
from functools import wraps, lru_cache
from typing import Dict, Tuple, Optional, List
import numpy as np
from scipy.linalg import cho_factor
from scipy._lib._util import _asarray_validated
from scipy.special import ndtr, ndtri
from scipy.stats._continuous_distns import _norm_pdf
#... | 27.794118 | 69 | 0.621618 |
798335c616c21ef1b9147bff6599589661727598 | 275 | py | Python | xray/__init__.py | eriknw/xray | 19df8d202b1d8054019e7e42365c67cdde6ff448 | [
"Apache-2.0"
] | 1 | 2017-09-18T02:08:09.000Z | 2017-09-18T02:08:09.000Z | xray/__init__.py | akleeman/xray | 48ce8c23c31b9a5d092f29974715aa1888b95044 | [
"Apache-2.0"
] | null | null | null | xray/__init__.py | akleeman/xray | 48ce8c23c31b9a5d092f29974715aa1888b95044 | [
"Apache-2.0"
] | 1 | 2020-02-05T00:19:02.000Z | 2020-02-05T00:19:02.000Z | from .core.alignment import align, broadcast_arrays, concat
from .core.variable import Variable, Coordinate
from .core.dataset import Dataset, open_dataset
from .core.dataarray import DataArray
from .conventions import decode_cf
from .version import version as __version__
| 30.555556 | 59 | 0.832727 |
798336810fa75f157be24f227e8712928e60114f | 5,263 | py | Python | invenio_vocabularies/services/service.py | Glignos/invenio-vocabularies | f8db70f933d3c4836f3ab0999d7eabf14510df7f | [
"MIT"
] | null | null | null | invenio_vocabularies/services/service.py | Glignos/invenio-vocabularies | f8db70f933d3c4836f3ab0999d7eabf14510df7f | [
"MIT"
] | null | null | null | invenio_vocabularies/services/service.py | Glignos/invenio-vocabularies | f8db70f933d3c4836f3ab0999d7eabf14510df7f | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
#
# Copyright (C) 2020-2021 CERN.
#
# Invenio-Vocabularies is free software; you can redistribute it and/or
# modify it under the terms of the MIT License; see LICENSE file for more
# details.
"""Vocabulary service."""
from elasticsearch_dsl.query import Q
from elasticsearch_dsl.response impor... | 30.777778 | 79 | 0.610488 |
79833a400a16d62c8a2cfde267038ca202bdb247 | 6,870 | py | Python | cognigraph/utils/inverse_model.py | ossadtchi/cognigraph | e616e9fa021720cc62dded649f508500af01853b | [
"MIT"
] | null | null | null | cognigraph/utils/inverse_model.py | ossadtchi/cognigraph | e616e9fa021720cc62dded649f508500af01853b | [
"MIT"
] | null | null | null | cognigraph/utils/inverse_model.py | ossadtchi/cognigraph | e616e9fa021720cc62dded649f508500af01853b | [
"MIT"
] | null | null | null | import os
import numpy as np
import mne
from mne.datasets import sample
from ..utils.misc import all_upper
from ..utils.channels import capitalize_chnames_fwd
import logging
data_path = sample.data_path(verbose="ERROR")
sample_dir = os.path.join(data_path, "MEG", "sample")
neuromag_forward_file_path = os.path.join(
... | 33.188406 | 79 | 0.696652 |
79833aa6fed20fb942847c12f2c628a7cec745d1 | 141 | py | Python | tests/event/exception_event/modules/module2/__init__.py | da-h/miniflask | d5e594153cca4ce4d30db01b1d06d05afa9e7aaa | [
"MIT"
] | 5 | 2020-02-17T12:14:36.000Z | 2020-02-27T12:09:05.000Z | tests/event/exception_event/modules/module2/__init__.py | da-h/miniflask | d5e594153cca4ce4d30db01b1d06d05afa9e7aaa | [
"MIT"
] | 69 | 2020-04-03T08:16:35.000Z | 2021-12-21T15:46:29.000Z | tests/event/exception_event/modules/module2/__init__.py | da-h/miniflask | d5e594153cca4ce4d30db01b1d06d05afa9e7aaa | [
"MIT"
] | 1 | 2020-04-02T15:46:39.000Z | 2020-04-02T15:46:39.000Z |
def main(state, event):
raise ValueError("Throwing an Exception.")
def register(mf):
mf.register_event('main', main, unique=True)
| 17.625 | 48 | 0.695035 |
79833d4935934f89ae7df8e110ad658d138a5880 | 8,739 | py | Python | Contents/Server Plugin/plugin.py | KieranBroadfoot/FlowerPower.indigoPlugin | 94fee2fd5eb903dc6262908ad2092516835ee6f2 | [
"MIT"
] | null | null | null | Contents/Server Plugin/plugin.py | KieranBroadfoot/FlowerPower.indigoPlugin | 94fee2fd5eb903dc6262908ad2092516835ee6f2 | [
"MIT"
] | null | null | null | Contents/Server Plugin/plugin.py | KieranBroadfoot/FlowerPower.indigoPlugin | 94fee2fd5eb903dc6262908ad2092516835ee6f2 | [
"MIT"
] | null | null | null | #! /usr/bin/env python
# -*- coding: utf-8 -*-
####################
# Copyright (c) 2016, Kieran J. Broadfoot. All rights reserved.
import sys
import os
import re
import time
import subprocess
import socket
import simplejson as json
import requests
class Plugin(indigo.PluginBase):
def __init__(self, pluginId, pl... | 50.224138 | 187 | 0.526948 |
79833d523c37f3aff73986d89391a36ef9019a97 | 506 | py | Python | apps/search/views.py | LishenZz/my_project | c2ac8199efb467e303d343ea34ed1969b64280d7 | [
"Apache-2.0"
] | null | null | null | apps/search/views.py | LishenZz/my_project | c2ac8199efb467e303d343ea34ed1969b64280d7 | [
"Apache-2.0"
] | null | null | null | apps/search/views.py | LishenZz/my_project | c2ac8199efb467e303d343ea34ed1969b64280d7 | [
"Apache-2.0"
] | null | null | null | #Author:Li Shen
from django.shortcuts import render
from django.db.models import Q
from apps.news.models import News
from django.utils.timezone import make_aware
from datetime import datetime
def search(request):
q=request.GET.get('q')
newses=News.objects.all()
context={
'newses':newses
}
... | 25.3 | 81 | 0.717391 |
79833dea62fada9e053b8af1c6a8bf31d58ac6fc | 14,201 | py | Python | addons/io_scene_gltf2/blender/exp/gltf2_blender_gather_animation_sampler_keyframes.py | Peach1/glTF-Blender-IO | 376926538918eb5429f4a44b113e5769328ba8e8 | [
"Apache-2.0"
] | null | null | null | addons/io_scene_gltf2/blender/exp/gltf2_blender_gather_animation_sampler_keyframes.py | Peach1/glTF-Blender-IO | 376926538918eb5429f4a44b113e5769328ba8e8 | [
"Apache-2.0"
] | null | null | null | addons/io_scene_gltf2/blender/exp/gltf2_blender_gather_animation_sampler_keyframes.py | Peach1/glTF-Blender-IO | 376926538918eb5429f4a44b113e5769328ba8e8 | [
"Apache-2.0"
] | null | null | null | # Copyright 2018-2019 The glTF-Blender-IO 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 ... | 41.043353 | 138 | 0.593268 |
79833e14765e49ef714cd4414d150dfbdfc8dece | 5,951 | py | Python | ggfilm/ggfilm/settings.py | amazingchow/photon-dance-ggfilm-server | edef66c5a0855e4c31342913c391c7dabef27f5c | [
"MIT"
] | null | null | null | ggfilm/ggfilm/settings.py | amazingchow/photon-dance-ggfilm-server | edef66c5a0855e4c31342913c391c7dabef27f5c | [
"MIT"
] | null | null | null | ggfilm/ggfilm/settings.py | amazingchow/photon-dance-ggfilm-server | edef66c5a0855e4c31342913c391c7dabef27f5c | [
"MIT"
] | null | null | null | """
Django settings for ggfilm project.
Generated by 'django-admin startproject' using Django 3.1.2.
For more information on this file, see
https://docs.djangoproject.com/en/3.1/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/3.1/ref/settings/
"""
import os
fro... | 28.203791 | 91 | 0.626113 |
79833e1e1ebd3152fca42b58a5867ad7b9475895 | 15,703 | py | Python | modules/combat.py | ThanatosDi/azurlane-auto | d542c10b5a168202ffabf9ce18955b609a5796e8 | [
"WTFPL"
] | 29 | 2019-01-02T10:43:53.000Z | 2021-08-08T22:14:03.000Z | modules/combat.py | 21Voltage/azurlane-auto | d542c10b5a168202ffabf9ce18955b609a5796e8 | [
"WTFPL"
] | 12 | 2018-12-18T20:17:41.000Z | 2019-05-14T14:42:33.000Z | modules/combat.py | 21Voltage/azurlane-auto | d542c10b5a168202ffabf9ce18955b609a5796e8 | [
"WTFPL"
] | 14 | 2019-02-07T08:18:43.000Z | 2021-08-03T17:18:42.000Z | from datetime import datetime, timedelta
from threading import Thread
from util.logger import Logger
from util.utils import Region, Utils
class CombatModule(object):
def __init__(self, config, stats):
"""Initializes the Combat module.
Args:
config (Config): ALAuto Config ... | 43.378453 | 81 | 0.52958 |
79833e43d830c398f1475309fb1041659191f6ab | 3,803 | py | Python | DNS_Netassay/PaperResults/timeout/p4_graphs.py | jkim117/IWSpring2020 | 3ca93768cd94487223168a76381cfd779bbc3b80 | [
"MIT"
] | 1 | 2020-03-03T14:33:49.000Z | 2020-03-03T14:33:49.000Z | DNS_Netassay/PaperResults/timeout/p4_graphs.py | jkim117/IWSpring2020 | 3ca93768cd94487223168a76381cfd779bbc3b80 | [
"MIT"
] | null | null | null | DNS_Netassay/PaperResults/timeout/p4_graphs.py | jkim117/IWSpring2020 | 3ca93768cd94487223168a76381cfd779bbc3b80 | [
"MIT"
] | 1 | 2020-04-07T18:28:48.000Z | 2020-04-07T18:28:48.000Z | import operator
from sys import argv
import matplotlib
import matplotlib.pyplot as plt
import numpy as np
import csv
dns_60_total = 0
packets_60_total = 0
bytes_60_total = 0
with open('parse_limit60_3hr.csv') as csvfile:
#with open('unlimited0000.csv') as csvfile:
reader = csv.reader(csvfile)
for row in reade... | 23.189024 | 166 | 0.660794 |
79834162c515b3e8e76a3d2fe50ae2637717fdaf | 849 | py | Python | build/lib/django_aws_zip/migrations/0001_initial.py | paulohesilva/django-aws-zip | 45e483f70446913985e53c1c4fb56ceb14934167 | [
"MIT"
] | 4 | 2017-11-26T01:55:32.000Z | 2020-09-26T11:29:33.000Z | django_aws_zip/migrations/0001_initial.py | paulohesilva/django-aws-zip | 45e483f70446913985e53c1c4fb56ceb14934167 | [
"MIT"
] | 2 | 2017-11-26T01:52:51.000Z | 2017-12-04T01:22:25.000Z | build/lib/django_aws_zip/migrations/0001_initial.py | paulohesilva/django-aws-zip | 45e483f70446913985e53c1c4fb56ceb14934167 | [
"MIT"
] | 2 | 2017-11-30T13:16:37.000Z | 2018-02-07T21:11:38.000Z | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
class Migration(migrations.Migration):
dependencies = [
]
operations = [
migrations.CreateModel(
name='Task',
fields=[
('id', models.AutoField(primary... | 33.96 | 115 | 0.575972 |
798341ae22e1fd417982bac73b91d3576bc32227 | 2,160 | py | Python | add_facetolist.py | infinityslayer52/Attendance_Face_Recognition | b28a801ef70f23916b13f37b0bba2b3202d87ceb | [
"MIT"
] | 4 | 2018-05-03T10:53:32.000Z | 2018-07-23T04:34:37.000Z | add_facetolist.py | infinityslayer52/Attendance_Face_Recognition | b28a801ef70f23916b13f37b0bba2b3202d87ceb | [
"MIT"
] | null | null | null | add_facetolist.py | infinityslayer52/Attendance_Face_Recognition | b28a801ef70f23916b13f37b0bba2b3202d87ceb | [
"MIT"
] | null | null | null | import requests
import pprint
names = {"01.jpg": "1", "02.jpg": "2", "03.jpg": "3", "04.jpg": "4", "05.jpg": "5", "06.jpg": "6", "07.jpg": "7",
"08.jpg": "8", "09.jpg": "9",
"10.jpg": "10", "11.jpg": "11", "12.jpg": "12", "13.jpg": "13", "14.jpg": "14", "15.jpg": "15", "16.jpg": "16",
... | 40.754717 | 185 | 0.532407 |
798341e3fae4b17064a7cf454deac05aea7e6653 | 6,390 | py | Python | tests/test_diversity.py | PratyushTripathy/momepy | eac89eaff63dd6cb35dfd9a736981723ec77f496 | [
"MIT"
] | null | null | null | tests/test_diversity.py | PratyushTripathy/momepy | eac89eaff63dd6cb35dfd9a736981723ec77f496 | [
"MIT"
] | null | null | null | tests/test_diversity.py | PratyushTripathy/momepy | eac89eaff63dd6cb35dfd9a736981723ec77f496 | [
"MIT"
] | null | null | null | import geopandas as gpd
import momepy as mm
import numpy as np
import pytest
from momepy import sw_high
from pytest import approx
class TestDiversity:
def setup_method(self):
test_file_path = mm.datasets.get_path("bubenec")
self.df_buildings = gpd.read_file(test_file_path, layer="buildings")
... | 35.10989 | 88 | 0.549139 |
7983420e7b20b4b7940229bab81540a673a20c16 | 3,637 | py | Python | tests/graphql/test_fields.py | UpliftAgency/django-money | 2256fb5159c63eb23a6b63a883b9b6e9ef3b945e | [
"BSD-3-Clause"
] | null | null | null | tests/graphql/test_fields.py | UpliftAgency/django-money | 2256fb5159c63eb23a6b63a883b9b6e9ef3b945e | [
"BSD-3-Clause"
] | 5 | 2019-07-23T19:45:57.000Z | 2020-04-22T06:07:14.000Z | tests/graphql/test_fields.py | UpliftAgency/django-money | 2256fb5159c63eb23a6b63a883b9b6e9ef3b945e | [
"BSD-3-Clause"
] | null | null | null | import json
from graphene_django.utils.testing import GraphQLTestCase
from djmoney.money import Money
from tests.testapp.graphql import schema
from tests.testapp.models import ModelWithVanillaMoneyField
MONEY_FIELD_FRAGMENT = """
fragment moneyFieldInfo on MoneyField {
asString
amount
amountStr # strin... | 27.976923 | 77 | 0.412703 |
7983422036582a8f7d2bc7230fac9b09096c97ec | 1,260 | py | Python | azext_iot/iothub/models/iothub_target.py | lucadruda/azure-iot-cli-extension | 9d2f677d19580f8fbac860e079550167e743a237 | [
"MIT"
] | 79 | 2017-09-25T19:29:17.000Z | 2022-03-30T20:55:57.000Z | azext_iot/iothub/models/iothub_target.py | lucadruda/azure-iot-cli-extension | 9d2f677d19580f8fbac860e079550167e743a237 | [
"MIT"
] | 305 | 2018-01-17T01:12:10.000Z | 2022-03-23T22:38:11.000Z | azext_iot/iothub/models/iothub_target.py | lucadruda/azure-iot-cli-extension | 9d2f677d19580f8fbac860e079550167e743a237 | [
"MIT"
] | 69 | 2017-11-14T00:30:46.000Z | 2022-03-01T17:11:45.000Z | # coding=utf-8
# --------------------------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.
# -----------------------------------------------------... | 37.058824 | 94 | 0.568254 |
7983443d1f47b7ffb2533072803974a60df7860f | 304 | py | Python | hepunits/units/__init__.py | dengbangjie/hepunits | 4eb5ef53b2e366990fca24b163c42af7d3ba593d | [
"BSD-3-Clause"
] | null | null | null | hepunits/units/__init__.py | dengbangjie/hepunits | 4eb5ef53b2e366990fca24b163c42af7d3ba593d | [
"BSD-3-Clause"
] | null | null | null | hepunits/units/__init__.py | dengbangjie/hepunits | 4eb5ef53b2e366990fca24b163c42af7d3ba593d | [
"BSD-3-Clause"
] | null | null | null | # Licensed under a 3-clause BSD style license, see LICENSE.
"""
Subpackage for the HEP System of Units, (derived) physical units
and commonly-used unit prefixes.
The HEP System of Units is the set of basic units originally defined by the CLHEP project.
"""
from .prefixes import *
from .units import *
| 27.636364 | 90 | 0.759868 |
79834443e38c63af64bd7d2299fa0a5e271307ee | 667 | py | Python | lec4.py | JoshuaJurack/IA241-github | b0e5e3e8b5c12516b727e8e076fb1233dc85f0c9 | [
"MIT"
] | null | null | null | lec4.py | JoshuaJurack/IA241-github | b0e5e3e8b5c12516b727e8e076fb1233dc85f0c9 | [
"MIT"
] | null | null | null | lec4.py | JoshuaJurack/IA241-github | b0e5e3e8b5c12516b727e8e076fb1233dc85f0c9 | [
"MIT"
] | null | null | null | '''
lec4
dict
tuple
'''
my_tuple = 'a', 'b', 'c', 'd', 'e'
print(my_tuple)
my_2nd_tuple = ('a', 'b', 'c', 'd', 'e')
print(my_2nd_tuple)
not_a_tuple = ('a')
print(type(not_a_tuple))
is_a_tuple = ('a',)
print(type(is_a_tuple))
print(my_tuple[1])
print(my_tuple[1:3])
print(my_tuple[1:])
print(my_tuple[:3])
print(my_t... | 15.159091 | 40 | 0.631184 |
7983448af629197d9daad09085f802d782b7cc39 | 1,623 | py | Python | src/compas/datastructures/mesh/bbox_numpy.py | Sam-Bouten/compas | 011c7779ded9b69bb602568b470bb0443e336f62 | [
"MIT"
] | null | null | null | src/compas/datastructures/mesh/bbox_numpy.py | Sam-Bouten/compas | 011c7779ded9b69bb602568b470bb0443e336f62 | [
"MIT"
] | null | null | null | src/compas/datastructures/mesh/bbox_numpy.py | Sam-Bouten/compas | 011c7779ded9b69bb602568b470bb0443e336f62 | [
"MIT"
] | null | null | null | from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from compas.geometry import oriented_bounding_box_numpy
from compas.geometry import oriented_bounding_box_xy_numpy
__all__ = [
'mesh_oriented_bounding_box_numpy',
'mesh_oriented_bounding_box_xy_numpy... | 24.969231 | 91 | 0.669747 |
798344b5eee1ff014d13eb86a2040a2a404adbaf | 10,776 | py | Python | sandbox/block_nsf.py | wuaalb/project-NN-Pytorch-scripts | 3434179a919fe67a614d80761104010255eff752 | [
"BSD-3-Clause"
] | null | null | null | sandbox/block_nsf.py | wuaalb/project-NN-Pytorch-scripts | 3434179a919fe67a614d80761104010255eff752 | [
"BSD-3-Clause"
] | null | null | null | sandbox/block_nsf.py | wuaalb/project-NN-Pytorch-scripts | 3434179a919fe67a614d80761104010255eff752 | [
"BSD-3-Clause"
] | null | null | null | ##!/usr/bin/env python
"""
Major blocks defined for NSF
These blocks are originall defined in ../project/01_nsf/*/.model.py
Definition are gathered here for convience.
CondModule, SourceModule, and FilterModule are not copied here since
they may change according to the model for certain application
"""
from __futur... | 37.678322 | 80 | 0.573682 |
798345cd8b75443ad0249021e16e27c01addd763 | 51,802 | py | Python | zerver/data_import/slack.py | ross-sysadm/zulip | 674158b8170eddb71aa2210052f0d598752581ed | [
"Apache-2.0"
] | null | null | null | zerver/data_import/slack.py | ross-sysadm/zulip | 674158b8170eddb71aa2210052f0d598752581ed | [
"Apache-2.0"
] | null | null | null | zerver/data_import/slack.py | ross-sysadm/zulip | 674158b8170eddb71aa2210052f0d598752581ed | [
"Apache-2.0"
] | null | null | null | import logging
import os
import random
import shutil
import subprocess
from collections import defaultdict
from typing import Any, Dict, Iterator, List, Optional, Set, Tuple
from urllib.parse import urlencode
import requests
import ujson
from django.conf import settings
from django.forms.models import model_to_dict
fr... | 45.123693 | 109 | 0.632543 |
7983464e2e5c1f694b7a1ac07279fcfe7ac53830 | 2,505 | py | Python | main.py | fhvilshoj/ECINN | 8c0b8097a5791d3d2697a11332cd21f34b4c76e4 | [
"MIT"
] | 3 | 2021-12-25T13:10:33.000Z | 2022-01-24T21:40:40.000Z | main.py | fhvilshoj/ECINN | 8c0b8097a5791d3d2697a11332cd21f34b4c76e4 | [
"MIT"
] | null | null | null | main.py | fhvilshoj/ECINN | 8c0b8097a5791d3d2697a11332cd21f34b4c76e4 | [
"MIT"
] | 1 | 2021-12-03T17:47:19.000Z | 2021-12-03T17:47:19.000Z | import sys
sys.path.append('submodules/IB-INN')
import argparse
# Functions
import counterfactual
import listing
import train
from dataset.dataset import Dataset
import os
import ibinn
def check_cfg(cfg): assert cfg is not None, "To use the model or the data, you must specify config:\n > python main.py [command] ... | 31.3125 | 156 | 0.620758 |
798346960ff61ad299069188411ab7325f8e5f96 | 187 | py | Python | feeds/__init__.py | CaptainIRS/programmer-lyf-bot | a66cded0ed30ea4eff696248bc41880bbc64c0de | [
"MIT"
] | 2 | 2021-01-09T06:51:11.000Z | 2021-02-23T23:40:38.000Z | feeds/__init__.py | CaptainIRS/programmer-lyf-bot | a66cded0ed30ea4eff696248bc41880bbc64c0de | [
"MIT"
] | 24 | 2021-01-10T18:22:43.000Z | 2022-03-30T11:26:41.000Z | feeds/__init__.py | CaptainIRS/programmer-lyf-bot | a66cded0ed30ea4eff696248bc41880bbc64c0de | [
"MIT"
] | null | null | null | '''
APIs for getting feeds
'''
from .fetch import fetch_feed
def get_feed(data_file, limit, frequency):
'''
Get feed
'''
return fetch_feed(data_file, limit, frequency)
| 14.384615 | 50 | 0.663102 |
798346c53a2a2b5bae59617ffa3327315df3fb34 | 3,087 | py | Python | numba_dppy/examples/blacksholes_kernel.py | diptorupd/numba-dppy | 0b39be7af6d188a31578b87ce8ca94fc76ca3fa1 | [
"Apache-2.0"
] | null | null | null | numba_dppy/examples/blacksholes_kernel.py | diptorupd/numba-dppy | 0b39be7af6d188a31578b87ce8ca94fc76ca3fa1 | [
"Apache-2.0"
] | null | null | null | numba_dppy/examples/blacksholes_kernel.py | diptorupd/numba-dppy | 0b39be7af6d188a31578b87ce8ca94fc76ca3fa1 | [
"Apache-2.0"
] | null | null | null | # Copyright 2020, 2021 Intel Corporation
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to... | 27.318584 | 102 | 0.607062 |
798346d0e987129fe2630c25a61349f24b0f6e1a | 1,741 | py | Python | bin/get_config_env.py | tjdulka/discovery-tjd | ad99048b75a15e683b39c5b12ac1249b2126760b | [
"Net-SNMP",
"Xnet"
] | 1 | 2019-05-24T14:04:54.000Z | 2019-05-24T14:04:54.000Z | bin/get_config_env.py | tjdulka/discovery-tjd | ad99048b75a15e683b39c5b12ac1249b2126760b | [
"Net-SNMP",
"Xnet"
] | null | null | null | bin/get_config_env.py | tjdulka/discovery-tjd | ad99048b75a15e683b39c5b12ac1249b2126760b | [
"Net-SNMP",
"Xnet"
] | null | null | null | import requests,json, os
from requests.auth import HTTPBasicAuth
base_host = os.environ.get('DISCOVERY_HOST') or u'gateway.watsonplatform.net'
request_url = "https://{0}/discovery-experimental/api/v1".format(base_host)
def get_auth():
uname = os.environ.get('DISCOVERY_USERNAME')
passwd = os.environ.get('DISC... | 32.240741 | 124 | 0.634693 |
798346f191706cddd444e631f9b2571ed8c923e7 | 5,785 | py | Python | scrapy/core/downloader/webclient.py | zyuchuan/scrapy | ce24f53957b41877319a5ffc6cf26f0a18baaec2 | [
"BSD-3-Clause"
] | null | null | null | scrapy/core/downloader/webclient.py | zyuchuan/scrapy | ce24f53957b41877319a5ffc6cf26f0a18baaec2 | [
"BSD-3-Clause"
] | null | null | null | scrapy/core/downloader/webclient.py | zyuchuan/scrapy | ce24f53957b41877319a5ffc6cf26f0a18baaec2 | [
"BSD-3-Clause"
] | null | null | null | from time import time
from urllib.parse import urlparse, urlunparse, urldefrag
from twisted.web.client import HTTPClientFactory
from twisted.web.http import HTTPClient
from twisted.internet import defer
from scrapy.http import Headers
from scrapy.utils.httpobj import urlparse_cached
from scrapy.utils.python import to... | 36.15625 | 92 | 0.668453 |
7983474538fca46db78f8c503bb73e77dfe2a9df | 6,396 | py | Python | lib/utils/version.py | regnauld/ganeti | c1d88461a964a5d0d89cd1ba0571429e01f0a1b5 | [
"BSD-2-Clause"
] | 2 | 2018-09-26T10:09:23.000Z | 2018-09-27T07:27:06.000Z | lib/utils/version.py | regnauld/ganeti | c1d88461a964a5d0d89cd1ba0571429e01f0a1b5 | [
"BSD-2-Clause"
] | null | null | null | lib/utils/version.py | regnauld/ganeti | c1d88461a964a5d0d89cd1ba0571429e01f0a1b5 | [
"BSD-2-Clause"
] | null | null | null | #
#
# Copyright (C) 2013 Google Inc.
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
#
# 1. Redistributions of source code must retain the above copyright notice,
# this list of conditions and ... | 30.457143 | 79 | 0.722795 |
798347ee68b5abc07a642ff1296e4cfc7a6b85d8 | 9,112 | py | Python | pg_python/tests/s3cmd-1.6.1/S3/MultiPart.py | AbhishekPowar/pg_python | e298275b6c664e6f7673ba4f1e4f3f37f789f577 | [
"MIT"
] | 8 | 2015-12-22T19:39:50.000Z | 2018-06-13T06:52:53.000Z | pg_python/tests/s3cmd-1.6.1/S3/MultiPart.py | AbhishekPowar/pg_python | e298275b6c664e6f7673ba4f1e4f3f37f789f577 | [
"MIT"
] | 2 | 2017-12-28T06:11:10.000Z | 2018-07-11T13:47:37.000Z | pg_python/tests/s3cmd-1.6.1/S3/MultiPart.py | AbhishekPowar/pg_python | e298275b6c664e6f7673ba4f1e4f3f37f789f577 | [
"MIT"
] | 10 | 2017-02-21T09:26:28.000Z | 2020-03-04T13:26:13.000Z | # -*- coding: utf-8 -*-
## Amazon S3 Multipart upload support
## Author: Jerome Leclanche <jerome.leclanche@gmail.com>
## License: GPL Version 2
import os
import sys
from stat import ST_SIZE
from logging import debug, info, warning, error
from .Utils import getTextFromXml, getTreeFromXml, formatSize, unicodise, deuni... | 44.666667 | 227 | 0.582309 |
7983483f98832c85bf5d4d22610a73b061b444c8 | 782 | py | Python | tests/conftest.py | christian-oreilly/pyprep | 770a33da1d9a0fd5f9b3fcd9bf20d4e08be3a959 | [
"MIT"
] | null | null | null | tests/conftest.py | christian-oreilly/pyprep | 770a33da1d9a0fd5f9b3fcd9bf20d4e08be3a959 | [
"MIT"
] | null | null | null | tests/conftest.py | christian-oreilly/pyprep | 770a33da1d9a0fd5f9b3fcd9bf20d4e08be3a959 | [
"MIT"
] | 1 | 2021-09-15T13:29:31.000Z | 2021-09-15T13:29:31.000Z | """Configure tests."""
import mne
import pytest
from mne.datasets import eegbci
@pytest.fixture(scope="session")
def montage():
"""Fixture for standard EEG montage."""
montage_kind = "standard_1020"
montage = mne.channels.make_standard_montage(montage_kind)
return montage
@pytest.fixture(scope="sess... | 26.965517 | 77 | 0.705882 |
79834851597a29fe6380f81e69ceaeb292876fe6 | 704 | py | Python | src/utils/schema/jobserver/migrations/0006_auto_20200311_2252.py | gravitationalwavedc/gwcloud_job_server | fb96ed1dc6baa240d1a38ac1adcd246577285294 | [
"MIT"
] | null | null | null | src/utils/schema/jobserver/migrations/0006_auto_20200311_2252.py | gravitationalwavedc/gwcloud_job_server | fb96ed1dc6baa240d1a38ac1adcd246577285294 | [
"MIT"
] | 8 | 2020-06-06T08:39:37.000Z | 2021-09-22T18:01:47.000Z | src/utils/schema/jobserver/migrations/0006_auto_20200311_2252.py | gravitationalwavedc/gwcloud_job_server | fb96ed1dc6baa240d1a38ac1adcd246577285294 | [
"MIT"
] | null | null | null | # Generated by Django 3.0.4 on 2020-03-11 22:52
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('jobserver', '0005_remove_job_sent'),
]
operations = [
migrations.AddField(
model_name='filedown... | 26.074074 | 112 | 0.605114 |
7983486f7d986ba05ae4a14bb346b92f0eca77a1 | 145 | py | Python | site/08.level3_object_detection/lib/ssd_params.py | FaBoPlatform/RobotCarAI | c89d3330a2beda0f253733d3252b2b035b153b6b | [
"Apache-2.0"
] | 10 | 2017-12-27T20:51:26.000Z | 2020-05-27T05:29:13.000Z | site/08.level3_object_detection/lib/ssd_params.py | FaBoPlatform/RobotCarAI | c89d3330a2beda0f253733d3252b2b035b153b6b | [
"Apache-2.0"
] | null | null | null | site/08.level3_object_detection/lib/ssd_params.py | FaBoPlatform/RobotCarAI | c89d3330a2beda0f253733d3252b2b035b153b6b | [
"Apache-2.0"
] | 3 | 2017-12-27T20:51:30.000Z | 2019-03-15T02:49:25.000Z | from nets import nets_factory
ssd_class = nets_factory.get_network('ssd_300_vgg')
ssd_params = ssd_class.default_params._replace(num_classes=5)
| 29 | 61 | 0.841379 |
798349249ff36f5109d131f406b7856c2a743f91 | 2,393 | py | Python | server/openapi_server/get_annotations.py | cascadianblue/phi-annotator | 0da6c102ec1068e6b15c613e2a90a78f79d15935 | [
"Apache-2.0"
] | null | null | null | server/openapi_server/get_annotations.py | cascadianblue/phi-annotator | 0da6c102ec1068e6b15c613e2a90a78f79d15935 | [
"Apache-2.0"
] | 19 | 2021-07-29T03:14:38.000Z | 2022-03-01T06:03:14.000Z | server/openapi_server/get_annotations.py | cascadianblue/phi-annotator | 0da6c102ec1068e6b15c613e2a90a78f79d15935 | [
"Apache-2.0"
] | null | null | null | from openapi_server.annotator.phi_types import PhiType
from openapi_server.annotator.annotate import Annotator
from openapi_server.models import Note, TextContactAnnotation, \
TextPersonNameAnnotation, TextIdAnnotation, TextDateAnnotation, \
TextLocationAnnotation
annotator: Annotator = Annotator.load(
'op... | 40.559322 | 70 | 0.627664 |
79834a2da6c5e22a4ec83c6e1ce076ed0f342336 | 1,373 | py | Python | market/apps/products/admin.py | QuiZ-Dev/django_web | eba14589e959d35ff5bd799bb6075a3b5bb91638 | [
"Unlicense"
] | null | null | null | market/apps/products/admin.py | QuiZ-Dev/django_web | eba14589e959d35ff5bd799bb6075a3b5bb91638 | [
"Unlicense"
] | null | null | null | market/apps/products/admin.py | QuiZ-Dev/django_web | eba14589e959d35ff5bd799bb6075a3b5bb91638 | [
"Unlicense"
] | null | null | null | from django.contrib import admin
from django.utils.html import format_html
from .models import *
class ProductImageInline(admin.TabularInline):
model = ProductImage
extra = 0
class ProductAdmin(admin.ModelAdmin):
list_display = [field.name for field in Product._meta.fields]
inlines = [ProductImageIn... | 24.963636 | 93 | 0.702112 |
79834b210f5d2ee88a3f5cf57e42516c567f1cd6 | 7,369 | py | Python | src/main/db.py | tgrx/galera | b79dd55fa4753c077d8c00eedea924223c450c18 | [
"MIT"
] | null | null | null | src/main/db.py | tgrx/galera | b79dd55fa4753c077d8c00eedea924223c450c18 | [
"MIT"
] | null | null | null | src/main/db.py | tgrx/galera | b79dd55fa4753c077d8c00eedea924223c450c18 | [
"MIT"
] | null | null | null | from contextlib import asynccontextmanager
from datetime import date
from typing import List
from typing import Optional
from uuid import uuid4
from delorean import Delorean
from sqlalchemy import Boolean
from sqlalchemy import Column
from sqlalchemy import Date
from sqlalchemy import ForeignKey
from sqlalchemy import... | 22.129129 | 74 | 0.622201 |
79834b53c87fa9e9fc37fdcfa8cce9497f90584d | 1,455 | py | Python | test/test_sql_query_api.py | ContrastingSounds/looker_sdk_31 | f973434049fff1b605b10086ab8b84f2f62e3489 | [
"MIT"
] | null | null | null | test/test_sql_query_api.py | ContrastingSounds/looker_sdk_31 | f973434049fff1b605b10086ab8b84f2f62e3489 | [
"MIT"
] | null | null | null | test/test_sql_query_api.py | ContrastingSounds/looker_sdk_31 | f973434049fff1b605b10086ab8b84f2f62e3489 | [
"MIT"
] | null | null | null | # coding: utf-8
"""
Experimental Looker API 3.1 Preview
This API 3.1 is in active development. Breaking changes are likely to occur to some API functions in future Looker releases until API 3.1 is officially launched and upgraded to beta status. If you have time and interest to experiment with new or modifie... | 29.693878 | 518 | 0.712027 |
79834b66554e0358da76bcdf33eb401b36107332 | 140 | py | Python | tests/roots/test-ext-viewcode/spam/mod2.py | rweickelt/sphinx | 1a4c41a7691e8f78d42e2db221192962c53b27df | [
"BSD-2-Clause"
] | 1 | 2015-11-08T11:41:39.000Z | 2015-11-08T11:41:39.000Z | tests/roots/test-ext-viewcode/spam/mod2.py | shenkan/sphinx | 42f2b305791507e6bfe9507832daefc5071969cd | [
"BSD-2-Clause"
] | null | null | null | tests/roots/test-ext-viewcode/spam/mod2.py | shenkan/sphinx | 42f2b305791507e6bfe9507832daefc5071969cd | [
"BSD-2-Clause"
] | 2 | 2019-10-10T18:38:27.000Z | 2020-01-29T16:25:44.000Z | """
mod2
"""
def func2(a, b):
"""
this is func2
"""
return a, b
class Class2(object):
"""
this is Class2
"""
| 8.75 | 21 | 0.442857 |
79834c14c37ac80d5d5a15e306e855cb4a0d6788 | 399 | py | Python | medical_app/wsgi.py | DarkCat777/MedicalApp | 71a902cdef8bf48ecfa026f87d67bef2e354e5a3 | [
"MIT"
] | null | null | null | medical_app/wsgi.py | DarkCat777/MedicalApp | 71a902cdef8bf48ecfa026f87d67bef2e354e5a3 | [
"MIT"
] | null | null | null | medical_app/wsgi.py | DarkCat777/MedicalApp | 71a902cdef8bf48ecfa026f87d67bef2e354e5a3 | [
"MIT"
] | null | null | null | """
WSGI config for medical_app project.
It exposes the WSGI callable as a module-level variable named ``application``.
For more information on this file, see
https://docs.djangoproject.com/en/3.2/howto/deployment/wsgi/
"""
import os
from django.core.wsgi import get_wsgi_application
os.environ.setdefault('DJANGO_S... | 23.470588 | 78 | 0.789474 |
79834c440b07116b67656b85b59b472bda8cbdd3 | 10,315 | py | Python | lib/services/server/ncloud_server/model/__init__.py | KidongSohn/ncloud-sdk-py | 1c62471a9bd320d77164ed3193a0ebb9f64229ff | [
"MIT"
] | null | null | null | lib/services/server/ncloud_server/model/__init__.py | KidongSohn/ncloud-sdk-py | 1c62471a9bd320d77164ed3193a0ebb9f64229ff | [
"MIT"
] | null | null | null | lib/services/server/ncloud_server/model/__init__.py | KidongSohn/ncloud-sdk-py | 1c62471a9bd320d77164ed3193a0ebb9f64229ff | [
"MIT"
] | null | null | null | # coding: utf-8
# flake8: noqa
"""
server
OpenAPI spec version: 2018-06-22T02:34:44Z
Generated by: https://github.com/swagger-api/swagger-codegen.git
"""
from __future__ import absolute_import
# import models into model package
from ncloud_server.model.access_control_group import AccessControlGrou... | 83.861789 | 134 | 0.93049 |
79834c68f0d2e20f6fa2499c98a5fc91dabcec80 | 13,230 | py | Python | reconcile/openshift_saas_deploy_trigger_base.py | bwplotka/qontract-reconcile | 08fa2472edba72bb6aa8d6264579506f0bf2a830 | [
"Apache-2.0"
] | null | null | null | reconcile/openshift_saas_deploy_trigger_base.py | bwplotka/qontract-reconcile | 08fa2472edba72bb6aa8d6264579506f0bf2a830 | [
"Apache-2.0"
] | null | null | null | reconcile/openshift_saas_deploy_trigger_base.py | bwplotka/qontract-reconcile | 08fa2472edba72bb6aa8d6264579506f0bf2a830 | [
"Apache-2.0"
] | null | null | null | import logging
import datetime
from threading import Lock
import reconcile.openshift_base as osb
import reconcile.queries as queries
import reconcile.jenkins_plugins as jenkins_base
import reconcile.utils.threaded as threaded
from reconcile.utils.openshift_resource import OpenshiftResource as OR
from reconcile.jenki... | 33.241206 | 77 | 0.601058 |
79834dc36ce7d74c147705f26047a032a7c891c3 | 37,798 | py | Python | pandas/tests/indexing/test_indexing.py | dimithras/pandas | d321be6e2a43270625abf671d9e59f16529c4b48 | [
"BSD-3-Clause"
] | 1 | 2021-09-17T14:27:25.000Z | 2021-09-17T14:27:25.000Z | pandas/tests/indexing/test_indexing.py | BhavarthShah/pandas | efb068f25b911ff3009d5692eb831df35bb042e5 | [
"BSD-3-Clause"
] | null | null | null | pandas/tests/indexing/test_indexing.py | BhavarthShah/pandas | efb068f25b911ff3009d5692eb831df35bb042e5 | [
"BSD-3-Clause"
] | null | null | null | """ test fancy indexing & misc """
from datetime import datetime
import re
import weakref
import numpy as np
import pytest
from pandas.core.dtypes.common import is_float_dtype, is_integer_dtype
import pandas as pd
from pandas import DataFrame, Index, NaT, Series
import pandas._testing as tm
from pandas.core.indexin... | 33.808587 | 88 | 0.521615 |
79834f02697312c5d813f6c68849e089aecf5b3b | 2,605 | py | Python | modules/spotify.py | matthewdargan/Spotify-Siri-Integration | 4ea92e2d20155442ff65791e628682b7aac34d2a | [
"MIT"
] | null | null | null | modules/spotify.py | matthewdargan/Spotify-Siri-Integration | 4ea92e2d20155442ff65791e628682b7aac34d2a | [
"MIT"
] | null | null | null | modules/spotify.py | matthewdargan/Spotify-Siri-Integration | 4ea92e2d20155442ff65791e628682b7aac34d2a | [
"MIT"
] | null | null | null | import configparser
import os
import pprint
from spotipy import spotipy
from spotipy.spotipy import util as util
# name of the module
moduleName = "spotify"
# words that must be said for this module to be executed
commandWords = ["spotify"]
def execute(command):
"""
Executes the proper voice command when t... | 29.602273 | 95 | 0.640691 |
79834f2cbea76f9de7f64581548e55b7b44a1c1f | 8,467 | py | Python | grr/gui/selenium_tests/acl_manager_test.py | nexus-lab/relf-server | d46774799c20376691c38f9293f454a3aff3ccb3 | [
"Apache-2.0"
] | null | null | null | grr/gui/selenium_tests/acl_manager_test.py | nexus-lab/relf-server | d46774799c20376691c38f9293f454a3aff3ccb3 | [
"Apache-2.0"
] | null | null | null | grr/gui/selenium_tests/acl_manager_test.py | nexus-lab/relf-server | d46774799c20376691c38f9293f454a3aff3ccb3 | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python
# -*- mode: python; encoding: utf-8 -*-
"""Tests the access control authorization workflow."""
import unittest
from grr.gui import gui_test_lib
from grr.lib import flags
from grr.lib import utils
from grr.lib.rdfvalues import client as rdf_client
from grr.server import access_control
from grr.s... | 34.843621 | 80 | 0.669777 |
798350db074de7bc873b5fafc340864b14d9ff12 | 2,473 | py | Python | where2_core/itinerary/views.py | 1LooperTrooper/Where2 | 59c74a2f80e519fb9e2ced40174ff66ad2078406 | [
"MIT"
] | null | null | null | where2_core/itinerary/views.py | 1LooperTrooper/Where2 | 59c74a2f80e519fb9e2ced40174ff66ad2078406 | [
"MIT"
] | null | null | null | where2_core/itinerary/views.py | 1LooperTrooper/Where2 | 59c74a2f80e519fb9e2ced40174ff66ad2078406 | [
"MIT"
] | null | null | null | from django.shortcuts import render, redirect
from django.http import Http404
from django.views.generic import TemplateView
from . import weather_itinerary, data_format, get_weather
import threading
itinerary_current = weather_itinerary.Itinerary('current')
itinerary_full = weather_itinerary.Itinerary('full')
def che... | 27.175824 | 76 | 0.697938 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.