hexsha stringlengths 40 40 | size int64 5 2.06M | ext stringclasses 11
values | lang stringclasses 1
value | max_stars_repo_path stringlengths 3 251 | max_stars_repo_name stringlengths 4 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 251 | max_issues_repo_name stringlengths 4 130 | max_issues_repo_head_hexsha stringlengths 40 78 | max_issues_repo_licenses listlengths 1 10 | max_issues_count int64 1 116k ⌀ | 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 251 | max_forks_repo_name stringlengths 4 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.05M | avg_line_length float64 1 1.02M | max_line_length int64 3 1.04M | alphanum_fraction float64 0 1 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
e2488ab43fc64895472fd4c4e6cd0e65a68427c1 | 20 | py | Python | test/__init__.py | LeonSu070/jira_bug_analysis | 6b1d814270be25a62706ab58b0b31c8771b649d9 | [
"Apache-2.0"
] | 2 | 2018-11-16T07:00:43.000Z | 2018-12-13T08:17:39.000Z | test/__init__.py | LeonSu070/jira_bug_analysis | 6b1d814270be25a62706ab58b0b31c8771b649d9 | [
"Apache-2.0"
] | null | null | null | test/__init__.py | LeonSu070/jira_bug_analysis | 6b1d814270be25a62706ab58b0b31c8771b649d9 | [
"Apache-2.0"
] | 1 | 2019-09-16T09:53:12.000Z | 2019-09-16T09:53:12.000Z | __author__ = 'Jack'
| 10 | 19 | 0.7 |
e24c67e2fa0e7cbac60e363c0a3c0d90ac4a1b04 | 1,643 | py | Python | basic_op.py | elosivi/python_tkinter_calculator | 1ee17adb26aa9bf2b3a17a0b340464c6ba562972 | [
"MIT"
] | null | null | null | basic_op.py | elosivi/python_tkinter_calculator | 1ee17adb26aa9bf2b3a17a0b340464c6ba562972 | [
"MIT"
] | null | null | null | basic_op.py | elosivi/python_tkinter_calculator | 1ee17adb26aa9bf2b3a17a0b340464c6ba562972 | [
"MIT"
] | null | null | null | """
myOperations is a list wich memory all values and operators entered by the user before click on "="
"""
myOperations=[]
def calc_all_myOperations():
"""
This function browse the array myOperations to return the result
of all the operations 2 by 2 from the first to the last, entered
before click on... | 31.596154 | 99 | 0.63664 |
e24cff14d61b3d1d516acfc54a69d88f1d665b63 | 3,863 | py | Python | cantools/autosar/secoc.py | malneni/cantools | b9958577c0f616c28c7fa37a2d2b491478e065ba | [
"MIT"
] | null | null | null | cantools/autosar/secoc.py | malneni/cantools | b9958577c0f616c28c7fa37a2d2b491478e065ba | [
"MIT"
] | null | null | null | cantools/autosar/secoc.py | malneni/cantools | b9958577c0f616c28c7fa37a2d2b491478e065ba | [
"MIT"
] | null | null | null | # Utilities for dealing with AUTOSAR secure on-board communication.
# (SecOC, i.e., verification of the authenticity of the sender of
# messages.)
from cantools.database.can.message import Message
from cantools.errors import Error
from typing import (
Union,
List,
Optional,
)
from cantools.typechecking i... | 35.768519 | 74 | 0.588403 |
e24edf3db066bab5b7ad6420821b48f3976957ea | 52,453 | py | Python | test/chora/scripts/testing.py | jbreck/duet-jbreck | 3bf4aa0c69983d15f199bf02f294d356c354e932 | [
"MIT"
] | 1 | 2020-08-15T15:26:25.000Z | 2020-08-15T15:26:25.000Z | test/chora/scripts/testing.py | jbreck/duet-jbreck | 3bf4aa0c69983d15f199bf02f294d356c354e932 | [
"MIT"
] | null | null | null | test/chora/scripts/testing.py | jbreck/duet-jbreck | 3bf4aa0c69983d15f199bf02f294d356c354e932 | [
"MIT"
] | null | null | null | #!/usr/bin/python
import os.path, sys, glob, datetime, time, subprocess, shutil, re
import xml.sax.saxutils, csv, tempfile
import choraconfig
css_blob="""\
div {
overflow: scroll;
max-height: 97vh;
position: relative;
}
th {
background-color: #ffffff;
font-weight: normal;
}
thead th {
position: -webkit-s... | 46.749554 | 156 | 0.528282 |
e24fbce9aed9113bc47d48913f811befc901b6e5 | 1,710 | py | Python | spec_collection.py | oursonvie/xcar | 2bc52f2935e62823c589e9a9fe708f1dcd2cdb69 | [
"Apache-2.0"
] | null | null | null | spec_collection.py | oursonvie/xcar | 2bc52f2935e62823c589e9a9fe708f1dcd2cdb69 | [
"Apache-2.0"
] | null | null | null | spec_collection.py | oursonvie/xcar | 2bc52f2935e62823c589e9a9fe708f1dcd2cdb69 | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
import crawler
import mongo
# in this module, data form model will be read and spec of each model is
# recorded int he database
# import mongo driver
from pymongo import MongoClient
client = MongoClient()
db = client['test_car']
# define base link
baselink = "http://newcar.xcar.com.cn"
# ... | 28.032787 | 85 | 0.570175 |
e25126ad015fd0336328c504cfadac599a468d6d | 1,233 | py | Python | src/adj_generator.py | Rama-007/Utility_scoring_of_product_reviews | 0b4ca33774128f55a606a546f7ed4e67cfa8d943 | [
"MIT"
] | null | null | null | src/adj_generator.py | Rama-007/Utility_scoring_of_product_reviews | 0b4ca33774128f55a606a546f7ed4e67cfa8d943 | [
"MIT"
] | null | null | null | src/adj_generator.py | Rama-007/Utility_scoring_of_product_reviews | 0b4ca33774128f55a606a546f7ed4e67cfa8d943 | [
"MIT"
] | 1 | 2018-05-17T17:42:19.000Z | 2018-05-17T17:42:19.000Z | import os,sys
import csv
import numpy as np
from sklearn.model_selection import train_test_split
from sklearn import datasets
from sklearn import svm
from sklearn import linear_model
from sklearn.metrics import matthews_corrcoef
from sklearn.feature_extraction.text import TfidfVectorizer
import re
import nltk
from coll... | 25.163265 | 59 | 0.59043 |
e2527a6fe723aa45e3efd33e33cfd5d50fd7fc36 | 3,393 | py | Python | pyapi/addins-api/localapi/deployment.py | dockerian/py-api | 777db7d5dacf3ecf29a991f50d2ac78bb5bef66a | [
"Apache-2.0"
] | null | null | null | pyapi/addins-api/localapi/deployment.py | dockerian/py-api | 777db7d5dacf3ecf29a991f50d2ac78bb5bef66a | [
"Apache-2.0"
] | 6 | 2019-12-26T16:51:55.000Z | 2022-03-21T22:16:45.000Z | pyapi/addins-api/localapi/deployment.py | dockerian/pyapi | 777db7d5dacf3ecf29a991f50d2ac78bb5bef66a | [
"Apache-2.0"
] | null | null | null | import json
import shutil
import tempfile
import traceback
from multiprocessing import Process
from subprocess import call, check_output, CalledProcessError
from api import swift
from utils import settings, delete_directory_tree
from deploy.deploy import Deployment
from deploy.deploy_status import DeploymentStatus
f... | 32.625 | 76 | 0.660772 |
e252c4820e12f03ff5ff8a21a0e62a986d8dd5fd | 2,344 | py | Python | cores/password.py | 0xGhazy/PyPass-Project | 5492eb0dc75cd023a3f1a6b3270914d27c8a7582 | [
"MIT"
] | 2 | 2022-03-18T16:13:59.000Z | 2022-03-28T20:24:56.000Z | cores/password.py | 0xGhazy/PyPass-Project | 5492eb0dc75cd023a3f1a6b3270914d27c8a7582 | [
"MIT"
] | 1 | 2022-03-19T14:50:19.000Z | 2022-03-22T18:40:57.000Z | cores/password.py | 0xGhazy/PyPass-Project | 5492eb0dc75cd023a3f1a6b3270914d27c8a7582 | [
"MIT"
] | 1 | 2022-03-18T14:58:51.000Z | 2022-03-18T14:58:51.000Z | import random
import string
if __name__ == '__main__':
x = Password()
print("[+] Generate random password")
x.generate_password()
print("Random password: ", x._random_password)
print("\n\n[+] Check password strength")
x.check_strength("Hello_World 2022")
print(x._password_strength)
| 30.441558 | 77 | 0.603242 |
e252dcbc46d6e9b468ac941a79802b5af9d1c4cb | 849 | py | Python | DjangoCountries/DjangoCountries/urls.py | xm4dn355x/specialist_DjangoCountries | debfbead4cc87faf1e60af374863498080c5fa8f | [
"MIT"
] | null | null | null | DjangoCountries/DjangoCountries/urls.py | xm4dn355x/specialist_DjangoCountries | debfbead4cc87faf1e60af374863498080c5fa8f | [
"MIT"
] | null | null | null | DjangoCountries/DjangoCountries/urls.py | xm4dn355x/specialist_DjangoCountries | debfbead4cc87faf1e60af374863498080c5fa8f | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
########################################################################
# #
# Main router #
# #
# MI... | 38.590909 | 72 | 0.262662 |
e254e16f7fd71692efcf28db1746504d39517446 | 5,153 | py | Python | schulze.py | bjornlevi/schulze | b63951a4083592988b0a94d2cdc048f1989c36e3 | [
"MIT"
] | 2 | 2015-11-09T05:11:20.000Z | 2016-05-05T10:23:10.000Z | schulze.py | bjornlevi/schulze | b63951a4083592988b0a94d2cdc048f1989c36e3 | [
"MIT"
] | null | null | null | schulze.py | bjornlevi/schulze | b63951a4083592988b0a94d2cdc048f1989c36e3 | [
"MIT"
] | null | null | null | """
Schulze STV voting implementation.
See https://en.wikipedia.org/wiki/Schulze_method
"""
from collections import defaultdict, OrderedDict
import random
def compute_strongest_paths(preference, candidates):
"""
input: preference
p[i,j] = number of voters that prefer candidate i to candidate j
in... | 39.335878 | 125 | 0.578886 |
e2553ed325e23b75f15e38f6dfb159756a4a0513 | 5,308 | py | Python | JPMC_presentation/int_func.py | qBraid/presentations | dd3d19f934b806b96c05a626b14224f35f868f6d | [
"MIT"
] | null | null | null | JPMC_presentation/int_func.py | qBraid/presentations | dd3d19f934b806b96c05a626b14224f35f868f6d | [
"MIT"
] | 1 | 2021-06-15T15:10:06.000Z | 2021-06-15T15:10:06.000Z | JPMC_presentation/int_func.py | qBraid/presentations | dd3d19f934b806b96c05a626b14224f35f868f6d | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
"""
Created on Wed Dec 12 19:42:57 2018
@author: kanav
"""
import logging
from pyscf import gto, scf, ao2mo
from pyscf.lib import param
from scipy import linalg as scila
from pyscf.lib import logger as pylogger
from qiskit.chemistry import QiskitChemistryError
# from qiskit.chemistr... | 33.594937 | 138 | 0.648832 |
e2557523d73c9829aec7494745f01d0144031b52 | 1,673 | py | Python | 02_Optimization/naive.py | IC-UFAL/mlclass | c314b028e2221915bc97ab95fc36d46fb87d8f5b | [
"MIT"
] | null | null | null | 02_Optimization/naive.py | IC-UFAL/mlclass | c314b028e2221915bc97ab95fc36d46fb87d8f5b | [
"MIT"
] | null | null | null | 02_Optimization/naive.py | IC-UFAL/mlclass | c314b028e2221915bc97ab95fc36d46fb87d8f5b | [
"MIT"
] | 2 | 2019-02-20T02:57:35.000Z | 2019-02-28T00:49:41.000Z | import datetime
import json
import requests
# url = 'http://localhost:8080/antenna/simulate?phi1={}&theta1={}&phi2={}&theta2={}&phi3={}&theta3={}'
url = 'https://aydanomachado.com/mlclass/02_Optimization.php?phi1={}&theta1={}&phi2={}&theta2={}&phi3={}&theta3={}&dev_key=Dual Core'
angles = ['phi1', 'theta1', 'phi2', '... | 32.173077 | 133 | 0.500897 |
e2586815f692b4c5cc76a0b0f9b72bd23ec35589 | 4,511 | py | Python | nautobot/extras/admin.py | romanukes/nautobot | 1a58479e702c16c9298ab18b96f74718c64697f9 | [
"Apache-2.0"
] | null | null | null | nautobot/extras/admin.py | romanukes/nautobot | 1a58479e702c16c9298ab18b96f74718c64697f9 | [
"Apache-2.0"
] | null | null | null | nautobot/extras/admin.py | romanukes/nautobot | 1a58479e702c16c9298ab18b96f74718c64697f9 | [
"Apache-2.0"
] | null | null | null | from db_file_storage.form_widgets import DBAdminClearableFileInput
from django import forms
from django.contrib import admin, messages
from django.db import transaction
from django.db.models import ProtectedError
from .models import CustomField, CustomFieldChoice, FileProxy, JobResult
def order_content_types(field):... | 24.252688 | 104 | 0.533141 |
e2591a9c5667fcee0b50b358960f50cf7f2ccbed | 112 | py | Python | pyrevolve/genotype/learning_body/config.py | braj29/robo_swimmers | b3c3fa91976884095eb6b5e67844167598ec573d | [
"Apache-1.1"
] | null | null | null | pyrevolve/genotype/learning_body/config.py | braj29/robo_swimmers | b3c3fa91976884095eb6b5e67844167598ec573d | [
"Apache-1.1"
] | null | null | null | pyrevolve/genotype/learning_body/config.py | braj29/robo_swimmers | b3c3fa91976884095eb6b5e67844167598ec573d | [
"Apache-1.1"
] | null | null | null | from dataclasses import dataclass
| 14 | 33 | 0.776786 |
e25a9a6afbe98bdd354733d1dd35bd9291fc6eb1 | 407 | py | Python | demo/catch/serve.py | marco-souza/falsy | 0dd6f792061ee833f308372f0204dea0ad9bf2d1 | [
"MIT"
] | 127 | 2017-01-05T14:55:50.000Z | 2022-02-01T06:02:49.000Z | demo/catch/serve.py | marco-souza/falsy | 0dd6f792061ee833f308372f0204dea0ad9bf2d1 | [
"MIT"
] | 9 | 2017-03-08T21:38:16.000Z | 2022-02-01T06:44:09.000Z | demo/catch/serve.py | marco-souza/falsy | 0dd6f792061ee833f308372f0204dea0ad9bf2d1 | [
"MIT"
] | 26 | 2017-01-12T08:56:15.000Z | 2022-02-01T06:02:52.000Z | import json
from falsy.falsy import FALSY
f = FALSY(static_path='test', static_dir='demo/catch/static')
f.swagger('demo/catch/spec.yml', ui=True, theme='responsive',errors= {CustomException: handle_custom})
api = f.api
| 22.611111 | 102 | 0.724816 |
e25bb3d21aa35bada6a1cc156c43483bfa1ddc27 | 1,125 | py | Python | main/services/post_service.py | andriidem308/django_02 | 6d9f624271d28ea6f53517e6144fa6b9d76598e5 | [
"MIT"
] | null | null | null | main/services/post_service.py | andriidem308/django_02 | 6d9f624271d28ea6f53517e6144fa6b9d76598e5 | [
"MIT"
] | 1 | 2021-05-15T18:28:26.000Z | 2021-05-15T18:28:26.000Z | main/services/post_service.py | andriidem308/django_02 | 6d9f624271d28ea6f53517e6144fa6b9d76598e5 | [
"MIT"
] | null | null | null | """Show Posts Method."""
from django.core.cache import cache
from main.forms import CommentsForm
from main.models import Post
def post_all():
"""Post All."""
key = Post().__class__.cache_key()
if key in cache:
objects_all = cache.get(key)
else:
objects_all = Post.objects.all()
... | 28.846154 | 66 | 0.639111 |
e25bf8be3fd6bade037eaf4f8cc3eb38deb9550a | 470 | py | Python | tests/fixtures/device.py | jspaaks/vak | 581ec4869d342e5d52bc057de54c10901f06d343 | [
"BSD-3-Clause"
] | 26 | 2019-03-04T20:08:57.000Z | 2022-01-22T13:40:00.000Z | tests/fixtures/device.py | jspaaks/vak | 581ec4869d342e5d52bc057de54c10901f06d343 | [
"BSD-3-Clause"
] | 379 | 2019-03-03T12:16:05.000Z | 2022-03-29T13:44:46.000Z | tests/fixtures/device.py | jspaaks/vak | 581ec4869d342e5d52bc057de54c10901f06d343 | [
"BSD-3-Clause"
] | 12 | 2019-11-22T21:19:19.000Z | 2022-03-14T17:44:59.000Z | import pytest
import torch
DEVICES = ["cpu"]
if torch.cuda.is_available():
DEVICES.append("cuda")
| 24.736842 | 67 | 0.695745 |
e25c0302ee8c05536014998029d4db780aef6a92 | 73 | py | Python | jacdac/heart_rate/__init__.py | microsoft/jacdac-python | 712ad5559e29065f5eccb5dbfe029c039132df5a | [
"MIT"
] | 1 | 2022-02-15T21:30:36.000Z | 2022-02-15T21:30:36.000Z | jacdac/heart_rate/__init__.py | microsoft/jacdac-python | 712ad5559e29065f5eccb5dbfe029c039132df5a | [
"MIT"
] | null | null | null | jacdac/heart_rate/__init__.py | microsoft/jacdac-python | 712ad5559e29065f5eccb5dbfe029c039132df5a | [
"MIT"
] | 1 | 2022-02-08T19:32:45.000Z | 2022-02-08T19:32:45.000Z | # Autogenerated file.
from .client import HeartRateClient # type: ignore
| 24.333333 | 50 | 0.794521 |
e25e669fd4134f81db148915a2fa79ef70cd3223 | 3,464 | py | Python | ckan_api_client/tests/functional/client_lowlev/test_group_crud.py | plorenzatto/ckan-api-client | aad42484b07f3f24eef32d10547fad8d7ea27400 | [
"BSD-2-Clause"
] | 4 | 2015-07-30T03:46:48.000Z | 2018-04-26T08:28:39.000Z | ckan_api_client/tests/functional/client_lowlev/test_group_crud.py | plorenzatto/ckan-api-client | aad42484b07f3f24eef32d10547fad8d7ea27400 | [
"BSD-2-Clause"
] | 3 | 2015-03-09T11:16:15.000Z | 2021-03-11T16:09:25.000Z | ckan_api_client/tests/functional/client_lowlev/test_group_crud.py | plorenzatto/ckan-api-client | aad42484b07f3f24eef32d10547fad8d7ea27400 | [
"BSD-2-Clause"
] | 2 | 2016-09-12T14:14:45.000Z | 2021-03-11T16:09:56.000Z | import copy
import pytest
from ckan_api_client.exceptions import HTTPError
from ckan_api_client.tests.utils.strings import gen_random_id
from ckan_api_client.tests.utils.validation import check_group
# @pytest.mark.xfail(run=False, reason='Is using deprecated functions')
# def test_simple_group_crud(ckan_client):
... | 30.928571 | 71 | 0.638857 |
e26133561a6a1fbea9a0c907133569d903786fa4 | 749 | py | Python | ex102.py | ezequielwish/Python3 | a4489d49e6919649437cb9e682614240701e2b68 | [
"MIT"
] | 1 | 2022-01-24T02:01:32.000Z | 2022-01-24T02:01:32.000Z | ex102.py | ezequielwish/Python3 | a4489d49e6919649437cb9e682614240701e2b68 | [
"MIT"
] | null | null | null | ex102.py | ezequielwish/Python3 | a4489d49e6919649437cb9e682614240701e2b68 | [
"MIT"
] | null | null | null | # Crie um programa que tenha uma funo fatorial() que receba dois parmetros: o primeiro que indique
# o nmero a calcular e outro chamado show, que ser um valor lgico (opcional) indicando se ser
# mostrado ou no na tela o processo de clculo do fatorial.
def factorial(number, show=False):
"""
Calcula o fatorial d... | 29.96 | 101 | 0.600801 |
e2617623ef2efc44b44ea28d9b54e927b69dfd87 | 208,496 | py | Python | colour_datasets/loaders/tests/test_kuopio.py | JGoldstone/colour-datasets | 8e0b52870c63c0e9b72d8b848720e0c28e0cbfa4 | [
"BSD-3-Clause"
] | 1 | 2022-01-29T09:12:18.000Z | 2022-01-29T09:12:18.000Z | colour_datasets/loaders/tests/test_kuopio.py | JGoldstone/colour-datasets | 8e0b52870c63c0e9b72d8b848720e0c28e0cbfa4 | [
"BSD-3-Clause"
] | null | null | null | colour_datasets/loaders/tests/test_kuopio.py | JGoldstone/colour-datasets | 8e0b52870c63c0e9b72d8b848720e0c28e0cbfa4 | [
"BSD-3-Clause"
] | null | null | null | # -*- coding: utf-8 -*-
"""
Defines unit tests for :mod:`colour_datasets.loaders.kuopio` module.
"""
import numpy as np
import os
import unittest
from colour import SpectralShape
from colour_datasets.loaders.kuopio import (
MatFileMetadata_KuopioUniversity, read_sds_from_mat_file_KuopioUniversity)
from colour_da... | 58.418605 | 78 | 0.281439 |
e262da1aa6ad6096d2959977d0253825881aad07 | 1,417 | py | Python | tbonlineproject/faq/templatetags/faqtags.py | nathangeffen/tbonline3 | 1b8a3af8d2dc1ee8083ca6638d025e94bd98f253 | [
"MIT"
] | null | null | null | tbonlineproject/faq/templatetags/faqtags.py | nathangeffen/tbonline3 | 1b8a3af8d2dc1ee8083ca6638d025e94bd98f253 | [
"MIT"
] | 3 | 2021-06-08T23:57:13.000Z | 2022-01-13T03:42:01.000Z | tbonlineproject/faq/templatetags/faqtags.py | nathangeffen/tbonline-2 | 0d5869197e66a0057fa07cb99f21dde7f5b47c30 | [
"MIT"
] | null | null | null | import re
from django import template
from faq.models import QuestionCategory, QuestionAndAnswer
register = template.Library()
register.tag('get_question_categories', do_get_question_categories)
| 30.148936 | 99 | 0.66549 |
e263e094c6996081261b4cf375cdf5d9eb8e965a | 3,387 | py | Python | tests/unit/test_api_connector.py | thomasperrot/weather | bc94d948f2c49a33b8ff3cf3dff850950825d161 | [
"MIT"
] | 1 | 2019-11-27T09:00:07.000Z | 2019-11-27T09:00:07.000Z | tests/unit/test_api_connector.py | thomasperrot/weather | bc94d948f2c49a33b8ff3cf3dff850950825d161 | [
"MIT"
] | 14 | 2020-09-11T12:40:01.000Z | 2020-10-06T07:17:26.000Z | tests/unit/test_api_connector.py | thomasperrot/weather | bc94d948f2c49a33b8ff3cf3dff850950825d161 | [
"MIT"
] | 2 | 2020-08-28T08:45:46.000Z | 2020-10-06T07:15:01.000Z | import json
import os
import pytest
import requests
from weather import api_connector, exceptions
| 27.762295 | 82 | 0.649838 |
e268813ad9f17d0dfbbf6f95f09c61a8270ce62b | 93 | py | Python | GoT_crawler/analysis.py | aamzhas/reddit_projects | 01f36f873315978faafdae6e8509f706a0863ba9 | [
"MIT"
] | null | null | null | GoT_crawler/analysis.py | aamzhas/reddit_projects | 01f36f873315978faafdae6e8509f706a0863ba9 | [
"MIT"
] | null | null | null | GoT_crawler/analysis.py | aamzhas/reddit_projects | 01f36f873315978faafdae6e8509f706a0863ba9 | [
"MIT"
] | null | null | null | import csv
from textblob import TextBlob as tb
if __name__ == "__main__":
analyse_data() | 18.6 | 35 | 0.741935 |
e268f670899c7a0577a47e0547ad2270f1a22f73 | 928 | py | Python | utils.py | ndukh/liver-segmentation | f46697719b78d11f8871048c7c3aaaf8d8f3777f | [
"MIT"
] | 2 | 2019-12-06T13:36:47.000Z | 2020-10-08T13:57:02.000Z | utils.py | ndukh/liver-segmentation | f46697719b78d11f8871048c7c3aaaf8d8f3777f | [
"MIT"
] | null | null | null | utils.py | ndukh/liver-segmentation | f46697719b78d11f8871048c7c3aaaf8d8f3777f | [
"MIT"
] | null | null | null | from keras import backend as K
def dice_coef(y_true, y_pred):
"""
A simple dice metric over true and predicted tensors.
We do not calculate dice axis-based, instead of this we calculate total dice
for the whole batch. It is simpler, when the result is the same as after
'fair' calculation of dice f... | 40.347826 | 82 | 0.669181 |
e26982b2c89136e7d22b94863c422aab02333678 | 1,932 | py | Python | scripts/searchtool.py | sirikata/sirikata-cdn | 115e9ad264229eaecd05008cb292ac0b8376a4a2 | [
"BSD-3-Clause"
] | 1 | 2017-07-21T13:48:45.000Z | 2017-07-21T13:48:45.000Z | scripts/searchtool.py | sirikata/sirikata-cdn | 115e9ad264229eaecd05008cb292ac0b8376a4a2 | [
"BSD-3-Clause"
] | 2 | 2020-06-05T18:30:40.000Z | 2021-06-10T20:21:24.000Z | scripts/searchtool.py | sirikata/sirikata-cdn | 115e9ad264229eaecd05008cb292ac0b8376a4a2 | [
"BSD-3-Clause"
] | 1 | 2016-05-15T13:34:47.000Z | 2016-05-15T13:34:47.000Z | import os
import os.path
import sys
import argparse
if __name__ == '__main__':
add_dirs()
from content.utils import search_index
from celery_tasks.search import update_entire_search_index, update_single_search_index_item
main()
| 32.745763 | 114 | 0.706004 |
e26a005aba399c82f6157e54fb1eeafe0b723175 | 5,145 | py | Python | tools/test_and_draw_to_file.py | freesunshine/mmdetection | 9fbd92c181f90feccfba7c8f17817c170b484bd9 | [
"Apache-2.0"
] | null | null | null | tools/test_and_draw_to_file.py | freesunshine/mmdetection | 9fbd92c181f90feccfba7c8f17817c170b484bd9 | [
"Apache-2.0"
] | null | null | null | tools/test_and_draw_to_file.py | freesunshine/mmdetection | 9fbd92c181f90feccfba7c8f17817c170b484bd9 | [
"Apache-2.0"
] | null | null | null | from mmdet.apis import init_detector, inference_detector, show_result
import mmcv
import os
import cv2
import sys
from mmdet.datasets.pipelines.loading import LoadPolNPZImageFromFile
from mmdet.datasets.pipelines.loading import LoadPolSubImageFromFile
import numpy as np
# ext_name= bgr\pol\sub\others
if __name__... | 42.172131 | 124 | 0.625462 |
e26a38dd5db9e2db5acd9b9c4ba66fe869a0a241 | 684 | py | Python | guppe/atividades/secao_7/ex029.py | WesleyLucas97/cursos_python | b2cbd393e8fed6e36b84253f7934766f2b4f1de8 | [
"MIT"
] | null | null | null | guppe/atividades/secao_7/ex029.py | WesleyLucas97/cursos_python | b2cbd393e8fed6e36b84253f7934766f2b4f1de8 | [
"MIT"
] | null | null | null | guppe/atividades/secao_7/ex029.py | WesleyLucas97/cursos_python | b2cbd393e8fed6e36b84253f7934766f2b4f1de8 | [
"MIT"
] | null | null | null | """
Faa um programa que receba 6 nmeros inteiros e mostre:
- Os nmeros pares digitados;
- A soma dos nmeros pares digitados;
- Os nmeros mpares digitados;
- A quantidade de nmeros mpares digitados.
"""
from random import randint
vetor = []
pares = []
impares = []
for x in range(randint(6, 50)):
vet... | 26.307692 | 67 | 0.676901 |
e26c2b378eb036143edf512f53458c5a06faa35c | 20,793 | py | Python | django_evolution/tests/test_rename_field.py | beanbaginc/django-evolution | fb76e44a2361a69a440dca086c0cc67ac6a4300d | [
"BSD-3-Clause"
] | 18 | 2015-02-08T14:48:02.000Z | 2021-08-03T21:07:37.000Z | django_evolution/tests/test_rename_field.py | beanbaginc/django-evolution | fb76e44a2361a69a440dca086c0cc67ac6a4300d | [
"BSD-3-Clause"
] | 4 | 2015-01-07T01:15:08.000Z | 2020-08-06T06:52:13.000Z | django_evolution/tests/test_rename_field.py | beanbaginc/django-evolution | fb76e44a2361a69a440dca086c0cc67ac6a4300d | [
"BSD-3-Clause"
] | 13 | 2015-01-07T01:06:21.000Z | 2022-02-20T16:27:41.000Z | from __future__ import unicode_literals
from django.db import models
from django_evolution.errors import SimulationFailure
from django_evolution.mutations import RenameField
from django_evolution.signature import (AppSignature,
ModelSignature,
... | 41.337972 | 77 | 0.588179 |
e26c7f0e54b8d43e115078966363aff4e60f48a6 | 26,192 | py | Python | src/cbc_sdk/platform/devices.py | fslds/carbon-black-cloud-sdk-python | 248a3c63d6b36d6fcdbcb3f51fb7751f062ed372 | [
"MIT"
] | 24 | 2020-10-16T22:07:38.000Z | 2022-03-24T14:58:03.000Z | src/cbc_sdk/platform/devices.py | fslds/carbon-black-cloud-sdk-python | 248a3c63d6b36d6fcdbcb3f51fb7751f062ed372 | [
"MIT"
] | 63 | 2020-10-26T18:26:15.000Z | 2022-03-31T17:31:02.000Z | src/cbc_sdk/platform/devices.py | fslds/carbon-black-cloud-sdk-python | 248a3c63d6b36d6fcdbcb3f51fb7751f062ed372 | [
"MIT"
] | 10 | 2020-11-09T11:54:23.000Z | 2022-03-24T20:44:00.000Z | #!/usr/bin/env python3
# *******************************************************
# Copyright (c) VMware, Inc. 2020-2021. All Rights Reserved.
# SPDX-License-Identifier: MIT
# *******************************************************
# *
# * DISCLAIMER. THIS PROGRAM IS PROVIDED TO YOU "AS IS" WITHOUT
# * WARRANTIES OR CO... | 35.062918 | 118 | 0.60465 |
e26ce504f8d020dbf40351637cdd277a284cb83b | 810 | py | Python | cmd/run_pytest.py | Amourspirit/python-version-num | 03e8f35b85900a5f9736dda2d9c172e73bdad9fe | [
"MIT"
] | 1 | 2021-11-13T08:26:05.000Z | 2021-11-13T08:26:05.000Z | cmd/run_pytest.py | Amourspirit/python-version-num | 03e8f35b85900a5f9736dda2d9c172e73bdad9fe | [
"MIT"
] | null | null | null | cmd/run_pytest.py | Amourspirit/python-version-num | 03e8f35b85900a5f9736dda2d9c172e73bdad9fe | [
"MIT"
] | 1 | 2021-11-13T08:26:41.000Z | 2021-11-13T08:26:41.000Z | # coding: utf-8
from subprocess import run
import pathlib
import os
TEST_DIR = 'tests'
ROOT_PATH = pathlib.Path(__file__).parent.parent
TEST_MODULES = ['verr']
if __name__ == '__main__':
main()
| 24.545455 | 100 | 0.658025 |
e26d97693b5c78f4bb3f85e734c99eec2f0dea90 | 220 | py | Python | generativemagic/effect.py | misaka3/generativemagic | 58f24a9fd95c94828281ed6c1267d570ee7c7b10 | [
"MIT"
] | null | null | null | generativemagic/effect.py | misaka3/generativemagic | 58f24a9fd95c94828281ed6c1267d570ee7c7b10 | [
"MIT"
] | null | null | null | generativemagic/effect.py | misaka3/generativemagic | 58f24a9fd95c94828281ed6c1267d570ee7c7b10 | [
"MIT"
] | null | null | null | from generativemagic.movement import Movement
DECK_TOP = 1
DECK_BOTTOM = 52
| 22 | 72 | 0.740909 |
e26da13b7aa0f70c0a93ca683c6aa55cf517af22 | 10,159 | py | Python | sectograph/widgets/edit_window.py | yumauri/sectograph | 457c8d44c632e04031d3e59a955d6c41a81a8104 | [
"MIT"
] | null | null | null | sectograph/widgets/edit_window.py | yumauri/sectograph | 457c8d44c632e04031d3e59a955d6c41a81a8104 | [
"MIT"
] | null | null | null | sectograph/widgets/edit_window.py | yumauri/sectograph | 457c8d44c632e04031d3e59a955d6c41a81a8104 | [
"MIT"
] | null | null | null | from PyQt5 import QtCore, QtGui, QtWidgets # , uic
from sectograph import resources, widgets, entities, datetime as dt
from .edit_window_ui import Ui_EditEventForm
repeat = {
"None": None,
"Every Day": 1,
"Every Week": 7,
"Every 2 Weeks": 14,
"Every Month": 30, # actually not a month
"Every ... | 36.543165 | 88 | 0.625849 |
e26e1e30afd44b5865d29418ebb7a003e39c3faf | 2,010 | py | Python | time_converter.py | lisprolog/python | 3d2acea2721873d57418b9158ed3bed6e160eb16 | [
"BSD-3-Clause"
] | null | null | null | time_converter.py | lisprolog/python | 3d2acea2721873d57418b9158ed3bed6e160eb16 | [
"BSD-3-Clause"
] | null | null | null | time_converter.py | lisprolog/python | 3d2acea2721873d57418b9158ed3bed6e160eb16 | [
"BSD-3-Clause"
] | null | null | null | '''
You prefer a good old 12-hour time format. But the modern world we live in would rather use the 24-hour format and you see it everywhere. Your task is to convert the time from the 24-h format into 12-h format by following the next rules:
- the output format should be 'hh:mm a.m.' (for hours before midday) or 'hh:m... | 42.765957 | 238 | 0.589055 |
e26e49266e956ade02f709bc18636ba6f4633d81 | 447 | py | Python | LeetCode/Study Plan/Algorithm/Day 1/704. Binary Search.py | TejM/HackerRank-Solutions | 8c5a79f7e644f42bc20a8c32818bf88a5c320bc1 | [
"MIT"
] | null | null | null | LeetCode/Study Plan/Algorithm/Day 1/704. Binary Search.py | TejM/HackerRank-Solutions | 8c5a79f7e644f42bc20a8c32818bf88a5c320bc1 | [
"MIT"
] | null | null | null | LeetCode/Study Plan/Algorithm/Day 1/704. Binary Search.py | TejM/HackerRank-Solutions | 8c5a79f7e644f42bc20a8c32818bf88a5c320bc1 | [
"MIT"
] | null | null | null | # Space Complexity O(1)
# Time Complexity O(log N)
| 27.9375 | 58 | 0.44519 |
e26edc3409fc91665e4e9e8bdb02caccd0068010 | 57,494 | py | Python | gail/gail.py | VisExcell/riskmodels | 012bbfd563482ba09585cd042b1f9465253ab1f4 | [
"MIT"
] | 2 | 2019-11-04T20:57:11.000Z | 2021-04-08T08:05:45.000Z | gail/gail.py | VisExcell/riskmodels | 012bbfd563482ba09585cd042b1f9465253ab1f4 | [
"MIT"
] | null | null | null | gail/gail.py | VisExcell/riskmodels | 012bbfd563482ba09585cd042b1f9465253ab1f4 | [
"MIT"
] | 2 | 2020-09-22T17:05:04.000Z | 2021-02-05T17:12:28.000Z | import numpy as np
if __name__ == '__main__':
gailMod = GailRiskCalculator()
gailMod.Initialize()
print gailMod.CalculateRisk(1, # riskIndex int [1 = Abs, 2 = Ave]
35, # CurrentAge int [t1]
40, # ProjectionAge int [t2]
0, # AgeIndicator int... | 47.28125 | 121 | 0.486364 |
e2705dcc4290b06c5f8063fcbb0d06661bdc5307 | 1,170 | py | Python | pki_framework/serializers.py | not-vibhu/aerobridge | 2edcd5e75782663184ac57da8145427613f4ef2b | [
"Apache-2.0"
] | null | null | null | pki_framework/serializers.py | not-vibhu/aerobridge | 2edcd5e75782663184ac57da8145427613f4ef2b | [
"Apache-2.0"
] | null | null | null | pki_framework/serializers.py | not-vibhu/aerobridge | 2edcd5e75782663184ac57da8145427613f4ef2b | [
"Apache-2.0"
] | null | null | null | from rest_framework import serializers
from pki_framework.models import AerobridgeCredential
from . import encrpytion_util
from django.conf import settings
| 35.454545 | 70 | 0.712821 |
e2717384cf4bcdc0a115d702eb3c542a9840a4cd | 8,777 | py | Python | entities/ships/ship.py | rkwong43/Toh | 702f689aa2c37a9f6f463e24405b6c418fd0607f | [
"CC-BY-4.0"
] | 3 | 2020-01-28T16:02:26.000Z | 2020-01-29T21:47:14.000Z | entities/ships/ship.py | rkwong43/Tears-Under-Heaven | 702f689aa2c37a9f6f463e24405b6c418fd0607f | [
"CC-BY-4.0"
] | null | null | null | entities/ships/ship.py | rkwong43/Tears-Under-Heaven | 702f689aa2c37a9f6f463e24405b6c418fd0607f | [
"CC-BY-4.0"
] | null | null | null | import math
import random
import pygame
from utils import config
# Constants for state of movement and rotations
NO_WAYPOINT = 1
MOVE_WAYPOINT = 2
FIRE_WAYPOINT = 3
MOVE_AND_FIRE_WAYPOINT = 4
"""Represents a generic ship.
"""
| 31.571942 | 103 | 0.557366 |
e2766dfb113345e1fd3a134fe901eaf909ed4549 | 1,827 | py | Python | constants2.py | Utsav-Patel/The-Imitation-Game | 09dfaffdf917c1adfb1d8cd3e09a216b9a014e52 | [
"MIT"
] | null | null | null | constants2.py | Utsav-Patel/The-Imitation-Game | 09dfaffdf917c1adfb1d8cd3e09a216b9a014e52 | [
"MIT"
] | null | null | null | constants2.py | Utsav-Patel/The-Imitation-Game | 09dfaffdf917c1adfb1d8cd3e09a216b9a014e52 | [
"MIT"
] | null | null | null | import os
PROJECT_PATH = os.path.dirname(__file__)
PROJECT_NO = 3
ARCHITECTURE_TYPE = 'dense'
NUM_COLS = 10
NUM_ROWS = 10
TRAINED_MODEL_NUM_ROWS = 10
TRAINED_MODEL_NUM_COLS = 10
INF = 1e9
FILE_PREFIX = "10x10"
FILE_SUFFIX = "new"
TRAIN_DATA_PREFIX = "21_to_30_probability_and_1000_each"
VALIDATION_TEST_DATA_PREFIX =... | 29.95082 | 118 | 0.683634 |
e277f4bdbc0bb30de17cd91736ad9678057f1dc7 | 3,919 | py | Python | tests/manage/mcg/conftest.py | vikasmulaje/ocs-ci | 98ce950150e061ba872c62f2d55f9bd395241a6e | [
"MIT"
] | null | null | null | tests/manage/mcg/conftest.py | vikasmulaje/ocs-ci | 98ce950150e061ba872c62f2d55f9bd395241a6e | [
"MIT"
] | null | null | null | tests/manage/mcg/conftest.py | vikasmulaje/ocs-ci | 98ce950150e061ba872c62f2d55f9bd395241a6e | [
"MIT"
] | null | null | null | import logging
import pytest
from ocs_ci.ocs import constants
from ocs_ci.ocs.resources import mcg
from tests import helpers
from tests.helpers import craft_s3_command, create_unique_resource_name
logger = logging.getLogger(__name__)
| 28.816176 | 85 | 0.655269 |
e27960049aaa598d72feec77e6c5226e0bfb23b5 | 266 | py | Python | UICPC/21/nwerc2020all/islandtour/generators/rand.py | MilladMuhammadi/Competitive-Programming | 9f84a2d2734a5efe0e1fde0062e51782cd5af2c6 | [
"MIT"
] | null | null | null | UICPC/21/nwerc2020all/islandtour/generators/rand.py | MilladMuhammadi/Competitive-Programming | 9f84a2d2734a5efe0e1fde0062e51782cd5af2c6 | [
"MIT"
] | null | null | null | UICPC/21/nwerc2020all/islandtour/generators/rand.py | MilladMuhammadi/Competitive-Programming | 9f84a2d2734a5efe0e1fde0062e51782cd5af2c6 | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
import sys
import random
n = int(sys.argv[1])
max_w = int(sys.argv[2])
seed = int(sys.argv[3])
k = 3
random.seed(seed)
print(n)
for _ in range(k+1):
A = []
for i in range(n):
A.append(random.randint(1, max_w))
print(*A)
| 14.777778 | 42 | 0.601504 |
e27a9e3d318c52ddc407fa0d3a29622c0ebd8768 | 488 | py | Python | odoo-13.0/doc/_extensions/autojsdoc/ext/__init__.py | VaibhavBhujade/Blockchain-ERP-interoperability | b5190a037fb6615386f7cbad024d51b0abd4ba03 | [
"MIT"
] | null | null | null | odoo-13.0/doc/_extensions/autojsdoc/ext/__init__.py | VaibhavBhujade/Blockchain-ERP-interoperability | b5190a037fb6615386f7cbad024d51b0abd4ba03 | [
"MIT"
] | null | null | null | odoo-13.0/doc/_extensions/autojsdoc/ext/__init__.py | VaibhavBhujade/Blockchain-ERP-interoperability | b5190a037fb6615386f7cbad024d51b0abd4ba03 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
from .directives import automodule_bound, autodirective_bound
from .extractor import _get_roots
| 34.857143 | 82 | 0.715164 |
e27b9ff878d5e676787f0419abe25a6716e3f34c | 1,867 | py | Python | mjolnir/test/kafka/test_bulk_daemon.py | kdhingra307/ncm | 07557138897d4266ce413c9f4fe033c24c6df065 | [
"MIT"
] | null | null | null | mjolnir/test/kafka/test_bulk_daemon.py | kdhingra307/ncm | 07557138897d4266ce413c9f4fe033c24c6df065 | [
"MIT"
] | null | null | null | mjolnir/test/kafka/test_bulk_daemon.py | kdhingra307/ncm | 07557138897d4266ce413c9f4fe033c24c6df065 | [
"MIT"
] | null | null | null | from mjolnir.kafka import bulk_daemon
import pytest
| 35.903846 | 88 | 0.656668 |
e281094af97245f121c74904895b108ebd981d2a | 2,248 | py | Python | tests/restart/rigid_vector.py | cselab/uDeviceX | 2ad5e9dd9f118e3998b291cbfc35ee91205bbef8 | [
"MIT"
] | 2 | 2018-09-19T09:53:35.000Z | 2018-10-08T16:37:31.000Z | tests/restart/rigid_vector.py | dimaleks/uDeviceX | 2ad5e9dd9f118e3998b291cbfc35ee91205bbef8 | [
"MIT"
] | 20 | 2018-09-19T10:05:55.000Z | 2018-10-01T14:50:18.000Z | tests/restart/rigid_vector.py | dimaleks/uDeviceX | 2ad5e9dd9f118e3998b291cbfc35ee91205bbef8 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
import mirheo as mir
import numpy as np
import argparse
import trimesh
parser = argparse.ArgumentParser()
parser.add_argument("--restart", action='store_true', default=False)
parser.add_argument("--ranks", type=int, nargs=3)
args = parser.parse_args()
ranks = args.ranks
domain = (16, 16, 16)
d... | 33.552239 | 165 | 0.668149 |
e28416ab6b88181873526448c13827e0449894a1 | 292 | py | Python | setup.py | Matatika/analyze-shopify | 3450eae05fba5c3852c9e009a212acd0ffaa9dfc | [
"MIT"
] | null | null | null | setup.py | Matatika/analyze-shopify | 3450eae05fba5c3852c9e009a212acd0ffaa9dfc | [
"MIT"
] | null | null | null | setup.py | Matatika/analyze-shopify | 3450eae05fba5c3852c9e009a212acd0ffaa9dfc | [
"MIT"
] | null | null | null | from setuptools import setup, find_packages
setup(
name="analyze-shopify",
version="0.1.0",
description="Matatika datasets for tap-shopify",
packages=find_packages(),
package_data={
"bundle": [
"analyze/datasets/tap-shopify/*.yml",
]
},
)
| 20.857143 | 52 | 0.609589 |
e285f7c748c8394c121ef615cb909893a57cfa34 | 11,641 | py | Python | scripts/jetsmearing.py | xju2/monojet | 7475a62f176425ae910f2f104f175b1ddc457fdf | [
"MIT"
] | null | null | null | scripts/jetsmearing.py | xju2/monojet | 7475a62f176425ae910f2f104f175b1ddc457fdf | [
"MIT"
] | null | null | null | scripts/jetsmearing.py | xju2/monojet | 7475a62f176425ae910f2f104f175b1ddc457fdf | [
"MIT"
] | null | null | null | #!/usr/bin/env python
import ROOT
import AtlasStyle
import os
import sys
import threading
import math
from array import array
ROOT.gROOT.SetBatch()
if not hasattr(ROOT, "loader"):
ROOT.gROOT.LoadMacro("/afs/cern.ch/user/x/xju/tool/loader.c")
ROOT.gROOT.LoadMacro(os.getenv("ROOTCOREBIN")+"/lib/x86_64-slc6-gcc49-... | 37.430868 | 99 | 0.556567 |
e286824d619b3fb3392a686ffb1f637ffe9558e5 | 226 | py | Python | app/user/urls.py | bondeveloper/maischool | 16bf2afe99d26caa067b7912e88839639cf2191e | [
"MIT"
] | null | null | null | app/user/urls.py | bondeveloper/maischool | 16bf2afe99d26caa067b7912e88839639cf2191e | [
"MIT"
] | null | null | null | app/user/urls.py | bondeveloper/maischool | 16bf2afe99d26caa067b7912e88839639cf2191e | [
"MIT"
] | null | null | null | from django.urls import path
from user import views
app_name = 'user'
urlpatterns = [
path('', views.ListUserView.as_view(), name="list"),
path('detail/<int:pk>', views.RetrieveUserView.as_view(), name="detail"),
]
| 20.545455 | 77 | 0.685841 |
e2869364b9dcccc3530b23aa12c8b83b04b6e9df | 11,588 | py | Python | squeezenet/develop_squeezenet.py | govindnh4cl/squeezenet | 4651a21d9ba274d49c9a8a8dcf5d98c16eff1510 | [
"MIT"
] | null | null | null | squeezenet/develop_squeezenet.py | govindnh4cl/squeezenet | 4651a21d9ba274d49c9a8a8dcf5d98c16eff1510 | [
"MIT"
] | 75 | 2020-03-14T17:07:09.000Z | 2020-05-17T01:03:29.000Z | squeezenet/develop_squeezenet.py | govindnh4cl/squeezenet | 4651a21d9ba274d49c9a8a8dcf5d98c16eff1510 | [
"MIT"
] | null | null | null | import time
import numpy as np
import tensorflow as tf
from my_logger import get_logger
from squeezenet.config import get_config
from squeezenet.inputs import get_input_pipeline
from squeezenet.networks.squeezenet import Squeezenet_Imagenet
from squeezenet import eval
from squeezenet.checkpoint_handler import Checkpo... | 43.400749 | 133 | 0.624266 |
e2877a645bbb7c7bad3cbc69941b6365e83c25ff | 1,151 | py | Python | Code/RUN_IntaRNA.py | nrohani/SARS-CoV-2 | 978320f7b644c65198d632dba8a8ebe8c4df542d | [
"MIT"
] | 1 | 2020-08-25T11:58:01.000Z | 2020-08-25T11:58:01.000Z | Code/RUN_IntaRNA.py | nrohani/SARS-CoV-2 | 978320f7b644c65198d632dba8a8ebe8c4df542d | [
"MIT"
] | null | null | null | Code/RUN_IntaRNA.py | nrohani/SARS-CoV-2 | 978320f7b644c65198d632dba8a8ebe8c4df542d | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Fri Jun 5 17:14:12 2020
@author: Narjes Rohani
"""
#install subprocess, Pandas, biopython, and IntaRNA packages
import os
import subprocess
import pandas as pd
#Load file of miRNAs sequences that you want to canculate MFE to bind SARS-CoV-2
mRNAMicroRNA=pd... | 28.775 | 80 | 0.7298 |
e2886fcfd835808de1acab30f0aa321469626e64 | 3,229 | py | Python | salt/salt.py | juhanurmi/cryptography | 362bc1cc146d291f9864f9788de904a09649d39f | [
"MIT"
] | null | null | null | salt/salt.py | juhanurmi/cryptography | 362bc1cc146d291f9864f9788de904a09649d39f | [
"MIT"
] | null | null | null | salt/salt.py | juhanurmi/cryptography | 362bc1cc146d291f9864f9788de904a09649d39f | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
'''
python3 salt.py
'''
import time
import random
import hashlib
def random_string(size=128):
''' Return a random string, default size is 128 '''
# Letters (upper and lower cases) + digits. Total of 64 options.
chars = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'... | 45.478873 | 100 | 0.600186 |
e28a9ea7765fcb38da42e9c9b798b40ab9662d1a | 2,025 | py | Python | demo/load_model/load_and_predict.py | Saumitra-Shukla/keras-bert | e60785d31129199ec0f922159e76bb63db330e00 | [
"MIT"
] | 2,465 | 2018-10-20T14:49:52.000Z | 2022-03-31T02:20:09.000Z | demo/load_model/load_and_predict.py | VictorMadu/keras-bert | 26bdfe3c36e77fa0524902f31263a920ccd62efb | [
"MIT"
] | 209 | 2018-11-01T09:03:39.000Z | 2022-03-19T09:07:47.000Z | demo/load_model/load_and_predict.py | VictorMadu/keras-bert | 26bdfe3c36e77fa0524902f31263a920ccd62efb | [
"MIT"
] | 566 | 2018-10-23T09:02:24.000Z | 2022-03-31T15:40:37.000Z | import sys
import numpy as np
from keras_bert import load_vocabulary, load_trained_model_from_checkpoint, Tokenizer, get_checkpoint_paths
print('This demo demonstrates how to load the pre-trained model and check whether the two sentences are continuous')
if len(sys.argv) == 2:
model_path = sys.argv[1]
else:
f... | 39.705882 | 116 | 0.744198 |
e28b7a15f09721739923d943b0fb11bb1a778844 | 3,052 | py | Python | archive/python/howto-logging.py | ajrichards/bayesian-examples | fbd87c6f1613ea516408e9ebc3c9eff1248246e4 | [
"BSD-3-Clause"
] | 2 | 2016-01-27T08:51:23.000Z | 2017-04-17T02:21:34.000Z | archive/python/howto-logging.py | ajrichards/notebook | fbd87c6f1613ea516408e9ebc3c9eff1248246e4 | [
"BSD-3-Clause"
] | null | null | null | archive/python/howto-logging.py | ajrichards/notebook | fbd87c6f1613ea516408e9ebc3c9eff1248246e4 | [
"BSD-3-Clause"
] | null | null | null | #!/usr/bin/env python
import time,os,re,csv,sys,uuid,joblib
from datetime import date
import numpy as np
from sklearn import svm
from sklearn import datasets
from sklearn.model_selection import train_test_split
from sklearn.metrics import classification_report
def train_model(X,y,saved_model):
"""
function t... | 28.259259 | 103 | 0.640891 |
e28c34e35ae4b4f3df58206467605471b9788535 | 14 | py | Python | sso/api/handlers/__init__.py | docloud/luna.sso | a62c0ee788b72b39340165e41de16e248eb5edad | [
"MIT"
] | null | null | null | sso/api/handlers/__init__.py | docloud/luna.sso | a62c0ee788b72b39340165e41de16e248eb5edad | [
"MIT"
] | null | null | null | sso/api/handlers/__init__.py | docloud/luna.sso | a62c0ee788b72b39340165e41de16e248eb5edad | [
"MIT"
] | null | null | null | #coding=utf8
| 4.666667 | 12 | 0.714286 |
e28c841373f2374d122cbff3f43b67a22b6729fe | 21,378 | py | Python | src/rnn_cells/skip_rnn_cells.py | imatge-upc/skiprnn-2017-tfm | 63f93a539a3f2c7a713089fdd2c38bb7b0c581ca | [
"MIT"
] | 129 | 2017-08-24T00:27:47.000Z | 2022-03-24T21:42:37.000Z | src/rnn_cells/skip_rnn_cells.py | imatge-upc/skiprnn-2018-iclr | 63f93a539a3f2c7a713089fdd2c38bb7b0c581ca | [
"MIT"
] | 8 | 2018-02-28T15:05:48.000Z | 2022-02-09T23:30:21.000Z | src/rnn_cells/skip_rnn_cells.py | imatge-upc/skiprnn-2018-iclr | 63f93a539a3f2c7a713089fdd2c38bb7b0c581ca | [
"MIT"
] | 45 | 2017-08-24T13:16:11.000Z | 2021-05-13T02:36:59.000Z | """
Skip RNN cells that decide which timesteps should be attended.
"""
from __future__ import absolute_import
from __future__ import print_function
import collections
import tensorflow as tf
from rnn_cells import rnn_ops
from tensorflow.python.framework import ops
SkipLSTMStateTuple = collections.namedtuple("Skip... | 48.697039 | 123 | 0.630882 |
e28f288d8baf761d62a58045450c5d688f0b7d68 | 1,601 | py | Python | 892.surface-area-of-3-d-shapes.py | Lonitch/hackerRank | 84991b8340e725422bc47eec664532cc84a3447e | [
"MIT"
] | null | null | null | 892.surface-area-of-3-d-shapes.py | Lonitch/hackerRank | 84991b8340e725422bc47eec664532cc84a3447e | [
"MIT"
] | null | null | null | 892.surface-area-of-3-d-shapes.py | Lonitch/hackerRank | 84991b8340e725422bc47eec664532cc84a3447e | [
"MIT"
] | null | null | null | #
# @lc app=leetcode id=892 lang=python3
#
# [892] Surface Area of 3D Shapes
#
# https://leetcode.com/problems/surface-area-of-3d-shapes/description/
#
# algorithms
# Easy (57.01%)
# Likes: 209
# Dislikes: 270
# Total Accepted: 15.9K
# Total Submissions: 27.5K
# Testcase Example: '[[2]]'
#
# On aN*Ngrid, we plac... | 14.294643 | 79 | 0.445971 |
e28fafb02e2674eaa86bebf78be4058f9ae1ced9 | 1,147 | py | Python | tensorflow/afno/afno.py | DarshanDeshpande/research-paper-implementations | fc24acfc4644ccdc9f7d46a411aa66153f234499 | [
"MIT"
] | 7 | 2021-12-20T00:53:46.000Z | 2022-03-17T01:37:00.000Z | tensorflow/afno/afno.py | DarshanDeshpande/research-paper-implementations | fc24acfc4644ccdc9f7d46a411aa66153f234499 | [
"MIT"
] | null | null | null | tensorflow/afno/afno.py | DarshanDeshpande/research-paper-implementations | fc24acfc4644ccdc9f7d46a411aa66153f234499 | [
"MIT"
] | 1 | 2022-03-31T05:41:53.000Z | 2022-03-31T05:41:53.000Z | import tensorflow as tf
import tensorflow_addons as tfa
| 27.309524 | 71 | 0.541412 |
e28ff84afb5353549cff424a116a8d2e4aba5e25 | 7,696 | py | Python | deploy/cdk_files/deploy_cdk_stack.py | nickderobertis/nick-derobertis-site | 386061dc258921eed41f2d3965ef69e02adde7ba | [
"MIT"
] | 1 | 2022-03-31T10:55:40.000Z | 2022-03-31T10:55:40.000Z | deploy/cdk_files/deploy_cdk_stack.py | nickderobertis/nick-derobertis-site | 386061dc258921eed41f2d3965ef69e02adde7ba | [
"MIT"
] | 8 | 2020-08-28T11:44:37.000Z | 2020-08-31T09:19:19.000Z | deploy/cdk_files/deploy_cdk_stack.py | nickderobertis/nick-derobertis-site | 386061dc258921eed41f2d3965ef69e02adde7ba | [
"MIT"
] | null | null | null | """AWS CDK module to create ECS infrastructure"""
import os
from typing import Optional
from aws_cdk import (
core,
aws_ecs as ecs,
aws_ec2 as ec2,
aws_iam as iam,
aws_ecr as ecr,
aws_elasticloadbalancingv2 as elbv2,
aws_route53 as route53,
aws_route53_targets as alias,
aws_certific... | 34.666667 | 107 | 0.58342 |
e2908b05587d86510e1d4c415f410a863e39895d | 1,139 | py | Python | hello/urls.py | KKawamura1/sirobutton | fb74a68e6f7a18177df3fd60df898e46d59f886e | [
"MIT"
] | 8 | 2018-07-03T03:08:41.000Z | 2020-01-05T00:08:04.000Z | hello/urls.py | KKawamura1/sirobutton | fb74a68e6f7a18177df3fd60df898e46d59f886e | [
"MIT"
] | null | null | null | hello/urls.py | KKawamura1/sirobutton | fb74a68e6f7a18177df3fd60df898e46d59f886e | [
"MIT"
] | null | null | null | from django.urls import path
from django.contrib.sitemaps.views import sitemap
import hello.views
from hello.sitemaps import SubtitleSitemap, StaticSitemap
app_name = 'sirobutton'
sitemaps = {
'subtitles': SubtitleSitemap,
'static': StaticSitemap,
}
urlpatterns = [
path('', hello.views.SubtitleListView.... | 42.185185 | 97 | 0.707638 |
e290dde6888c2655675fa623360f1477b47adc7f | 5,415 | py | Python | app/freelancer/tests/test_profile.py | mshirzad/find-my-job | 7dca88d6233649952f0b948156a91af5b96352ff | [
"MIT"
] | null | null | null | app/freelancer/tests/test_profile.py | mshirzad/find-my-job | 7dca88d6233649952f0b948156a91af5b96352ff | [
"MIT"
] | null | null | null | app/freelancer/tests/test_profile.py | mshirzad/find-my-job | 7dca88d6233649952f0b948156a91af5b96352ff | [
"MIT"
] | 1 | 2022-03-06T17:44:49.000Z | 2022-03-06T17:44:49.000Z | import os, tempfile
from PIL import Image
from django.contrib.auth import get_user_model
from django.test import TestCase
from django.urls import reverse
from rest_framework import test, status
from rest_framework.test import APIClient
from core.models import Profile, Address, Gig, Education
from freelancer.serial... | 28.650794 | 88 | 0.635272 |
e292938be0fbd99557d32fc2766285f31e477327 | 5,106 | py | Python | app2.py | dropout-sih/flask-backend | 0423274a285a841bb007e7cf4284d6d95d74e20a | [
"MIT"
] | null | null | null | app2.py | dropout-sih/flask-backend | 0423274a285a841bb007e7cf4284d6d95d74e20a | [
"MIT"
] | null | null | null | app2.py | dropout-sih/flask-backend | 0423274a285a841bb007e7cf4284d6d95d74e20a | [
"MIT"
] | null | null | null | from bokeh.embed import components
from bokeh.plotting import figure, curdoc, ColumnDataSource
from bokeh.resources import INLINE
from bokeh.util.string import encode_utf8
from bokeh.models import CustomJS, LabelSet, Slider
from bokeh.models.widgets import Slider
from bokeh.models.layouts import WidgetBox, Row
from bok... | 27.451613 | 168 | 0.697219 |
e292cc422e185ad6a241928b70c1875793558ca0 | 1,072 | py | Python | src/mailauth/migrations/0001_initial.py | Nnonexistent/chemphys | d2f34364d006a494bb965bb83d1967d7dd56f9ba | [
"MIT"
] | null | null | null | src/mailauth/migrations/0001_initial.py | Nnonexistent/chemphys | d2f34364d006a494bb965bb83d1967d7dd56f9ba | [
"MIT"
] | 19 | 2015-03-08T08:46:09.000Z | 2019-10-01T05:16:43.000Z | src/mailauth/migrations/0001_initial.py | Nnonexistent/chemphys | d2f34364d006a494bb965bb83d1967d7dd56f9ba | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import mailauth.models
import django.utils.timezone
from django.conf import settings
| 33.5 | 127 | 0.620336 |
e2962b912b0ef2494f5546db33de053e4cecd765 | 733 | py | Python | augmentation.py | JamesQFreeman/contrastive_learning_in_100_lines | e5c015c2fad392dd0142cd93728cec3ccdb935b9 | [
"MIT"
] | 2 | 2021-09-07T11:53:42.000Z | 2021-09-25T15:21:24.000Z | augmentation.py | JamesQFreeman/contrastive_learning_in_100_lines | e5c015c2fad392dd0142cd93728cec3ccdb935b9 | [
"MIT"
] | null | null | null | augmentation.py | JamesQFreeman/contrastive_learning_in_100_lines | e5c015c2fad392dd0142cd93728cec3ccdb935b9 | [
"MIT"
] | null | null | null | from torchvision import transforms as T
import torch
import random
SimCLR_augment = torch.nn.Sequential(
RandomApply(
T.ColorJitter(0.8, 0.8, 0.8, 0.2),
p=0.3
),
T.RandomGrayscale(p=0.2),
T.RandomHorizontalFlip(),
RandomApply(
T.GaussianBlur((3, 3), (1.0, 2.0)),
p=... | 21.558824 | 49 | 0.559345 |
e2966a8acfb10fae2bc5cafae57c64dc5b245211 | 728 | py | Python | lessons/058/function/app.py | murasaki718/tutorials | ad55a1f34f2dc050a5ccbceae0c09def0626dccf | [
"MIT"
] | 225 | 2020-12-12T03:41:46.000Z | 2022-03-30T20:07:31.000Z | lessons/058/function/app.py | kevAnto/tutorials | 9db76b5eeb6a54afabae6a4e386f155cc5dbc025 | [
"MIT"
] | 9 | 2021-09-18T12:36:23.000Z | 2022-03-11T17:24:20.000Z | lessons/058/function/app.py | kevAnto/tutorials | 9db76b5eeb6a54afabae6a4e386f155cc5dbc025 | [
"MIT"
] | 410 | 2020-12-24T03:34:33.000Z | 2022-03-31T22:38:13.000Z | import boto3
import requests
| 26.962963 | 54 | 0.712912 |
e29799a419ccf766cb76b6c714c7fa023b5fc415 | 421 | py | Python | backend/edw/utils/router.py | MMotionMan/django-edw | 0f686429d29e0f40409a3b2318664973b2844c08 | [
"BSD-3-Clause"
] | 4 | 2019-09-18T05:51:12.000Z | 2020-10-23T08:50:00.000Z | backend/edw/utils/router.py | MMotionMan/django-edw | 0f686429d29e0f40409a3b2318664973b2844c08 | [
"BSD-3-Clause"
] | 10 | 2020-04-29T11:46:44.000Z | 2022-03-11T23:38:27.000Z | backend/edw/utils/router.py | MMotionMan/django-edw | 0f686429d29e0f40409a3b2318664973b2844c08 | [
"BSD-3-Clause"
] | 13 | 2020-04-09T07:49:48.000Z | 2022-03-02T07:06:28.000Z | # -*- coding: utf-8 -*-
from django.db import DEFAULT_DB_ALIAS
from multidb import PinningReplicaRouter
| 35.083333 | 76 | 0.703088 |
e297d6fe5d987adf7ab2be9c741d006bb3a4ad4a | 1,593 | py | Python | compile.py | cobaltians/Cobalt-Web-Sources | a5bfc71b3d2aebaa799d1917c1d15025110c5c11 | [
"MIT"
] | 1 | 2020-07-28T13:49:50.000Z | 2020-07-28T13:49:50.000Z | compile.py | cobaltians/Cobalt-Web-Sources | a5bfc71b3d2aebaa799d1917c1d15025110c5c11 | [
"MIT"
] | 1 | 2015-08-14T21:04:47.000Z | 2015-08-15T16:07:53.000Z | compile.py | cobaltians/Cobalt-Web-Sources | a5bfc71b3d2aebaa799d1917c1d15025110c5c11 | [
"MIT"
] | 1 | 2015-08-14T20:12:19.000Z | 2015-08-14T20:12:19.000Z | import os
libName = "cobalt"
distrib_path = os.path.normpath(os.path.abspath(os.path.join(os.pardir, 'Cobalt-Web'))) #../Cobalt-Web
web_sources_path = os.path.normpath(os.path.abspath(os.path.join(os.path.dirname(__file__)))) #here
common_file_path= os.path.normpath(os.path.abspath(os.path.join(web_sources_path, 'comm... | 33.1875 | 113 | 0.697426 |
e2983c94a04750401fd0d6ef968b1c6b8d6d289f | 2,051 | py | Python | ch6 slam&navigation/turtlebot/kobuki/kobuki_testsuite/src/kobuki_testsuite/angular_accelerate.py | MINAMISAMA/Castle-X | f6aedc4e67f772b2aed269617ee8a9cac95c7f63 | [
"Apache-2.0"
] | 3 | 2021-01-10T10:52:14.000Z | 2021-12-31T10:19:25.000Z | ch6 slam&navigation/turtlebot/kobuki/kobuki_testsuite/src/kobuki_testsuite/angular_accelerate.py | MINAMISAMA/Castle-X | f6aedc4e67f772b2aed269617ee8a9cac95c7f63 | [
"Apache-2.0"
] | 1 | 2019-01-15T12:37:59.000Z | 2019-01-15T12:37:59.000Z | ch6 slam&navigation/turtlebot/kobuki/kobuki_testsuite/src/kobuki_testsuite/angular_accelerate.py | MINAMISAMA/Castle-X | f6aedc4e67f772b2aed269617ee8a9cac95c7f63 | [
"Apache-2.0"
] | 2 | 2019-01-14T07:48:42.000Z | 2019-01-15T06:32:27.000Z | #!/usr/bin/env python
#
# License: BSD
# https://raw.github.com/yujinrobot/kobuki/hydro-devel/kobuki_testsuite/LICENSE
#
##############################################################################
# Imports
##############################################################################
import threading
impo... | 28.887324 | 93 | 0.504144 |
e2987a689cdb6912d64b87c167aed0504e4c8bc3 | 2,023 | py | Python | mergify_engine/rules/types.py | eladb/mergify-engine | ca2eb9926be29d38feaf029caaa63cbb4c74659e | [
"Apache-2.0"
] | null | null | null | mergify_engine/rules/types.py | eladb/mergify-engine | ca2eb9926be29d38feaf029caaa63cbb4c74659e | [
"Apache-2.0"
] | null | null | null | mergify_engine/rules/types.py | eladb/mergify-engine | ca2eb9926be29d38feaf029caaa63cbb4c74659e | [
"Apache-2.0"
] | null | null | null | # -*- encoding: utf-8 -*-
#
# Copyright 2020 Mergify SAS
#
# 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... | 28.492958 | 83 | 0.699456 |
e2996b4376288dcac854730f4d39f437175c6874 | 692 | py | Python | backend/submission/migrations/0013_auto_20210730_2244.py | skku-npc/SKKU_Coding_Platform | 1d972e8922484cf94f6735fd08b2565e5d3517d0 | [
"MIT"
] | 1 | 2022-03-30T14:03:23.000Z | 2022-03-30T14:03:23.000Z | backend/submission/migrations/0013_auto_20210730_2244.py | skku-npc/SKKU_Coding_Platform | 1d972e8922484cf94f6735fd08b2565e5d3517d0 | [
"MIT"
] | 56 | 2022-02-19T08:13:48.000Z | 2022-03-25T10:17:07.000Z | backend/submission/migrations/0013_auto_20210730_2244.py | skku-npc/SKKU_Coding_Platform | 1d972e8922484cf94f6735fd08b2565e5d3517d0 | [
"MIT"
] | 1 | 2022-03-25T15:02:46.000Z | 2022-03-25T15:02:46.000Z | # Generated by Django 2.2.24 on 2021-07-30 13:44
from django.db import migrations, models
import django.db.models.deletion
| 26.615385 | 120 | 0.615607 |
e29bbb2c0371d64fde51e9fa4ffd3d717bbe1e2c | 304 | py | Python | src/zs2decode/__init__.py | Gargoyl13/zs2decode | 7826df443327a9465a6a0626f10543e6cd9927e3 | [
"MIT"
] | 3 | 2021-12-02T20:09:26.000Z | 2022-03-07T22:38:08.000Z | src/zs2decode/__init__.py | Gargoyl13/zs2decode | 7826df443327a9465a6a0626f10543e6cd9927e3 | [
"MIT"
] | 6 | 2016-12-13T19:52:01.000Z | 2022-03-12T21:03:55.000Z | src/zs2decode/__init__.py | Gargoyl13/zs2decode | 7826df443327a9465a6a0626f10543e6cd9927e3 | [
"MIT"
] | 5 | 2016-07-11T12:27:17.000Z | 2021-07-20T12:48:13.000Z |
__version__ = "0.3.2.dev0"
__title__ = "zs2decode"
__description__ = "read Zwick zs2 and zp2 files"
__uri__ = "https://zs2decode.readthedocs.org/"
__author__ = "Chris Petrich"
__email__ = "cpetrich@users.noreply.github.com"
__license__ = "MIT"
__copyright__ = "Copyright (C) 2015-2017 Chris Petrich"
| 23.384615 | 55 | 0.743421 |
e29bf102bcc2d01986cf90aafc7b1eecbc6c4679 | 10,158 | py | Python | test-pokersim.py | heyi19931225/Python-Texas-Holdem-Starter-Simio | 1eaf266922fb6478dd907f5cbc9eb388775d16e0 | [
"MIT"
] | 12 | 2017-01-08T17:24:43.000Z | 2021-11-14T09:09:11.000Z | test-pokersim.py | heyi19931225/Python-Texas-Holdem-Starter-Simio | 1eaf266922fb6478dd907f5cbc9eb388775d16e0 | [
"MIT"
] | 1 | 2020-06-15T11:23:41.000Z | 2020-06-15T11:23:41.000Z | test-pokersim.py | heyi19931225/Python-Texas-Holdem-Starter-Simio | 1eaf266922fb6478dd907f5cbc9eb388775d16e0 | [
"MIT"
] | 15 | 2016-05-17T01:01:24.000Z | 2021-11-16T14:37:34.000Z | ##
# test-pokersim.py
#
# Tests
# check hand logic
# check readable_hand, hand_to_numeric
# check best_five
# valid_hand
import unittest
import pokersim
if __name__ == '__main__':
unittest.main()
| 47.915094 | 77 | 0.669718 |
e29e7a0574cd25b3521ccbfec3ec991095438e5e | 446 | py | Python | visual/views.py | dukuaris/Django | d34f3e3f09028511e96b99cae7faa1b46458eed1 | [
"MIT"
] | null | null | null | visual/views.py | dukuaris/Django | d34f3e3f09028511e96b99cae7faa1b46458eed1 | [
"MIT"
] | 12 | 2020-06-06T01:22:26.000Z | 2022-03-12T00:13:42.000Z | visual/views.py | dukuaris/Django | d34f3e3f09028511e96b99cae7faa1b46458eed1 | [
"MIT"
] | null | null | null | from django.shortcuts import render
| 26.235294 | 58 | 0.764574 |
e29faff8b7ac6704b7fa82f70fed6f89ab3c757c | 2,170 | py | Python | fastiqa/bunches/iqa/test_images.py | baidut/PatchVQ | 040486b6342dfd36695f1daea0b5c4d77d728a23 | [
"Unlicense"
] | 32 | 2020-12-05T09:11:20.000Z | 2022-03-28T07:49:13.000Z | fastiqa/bunches/iqa/test_images.py | utlive/PatchVQ | 040486b6342dfd36695f1daea0b5c4d77d728a23 | [
"Unlicense"
] | 5 | 2021-07-12T19:43:51.000Z | 2022-01-28T13:16:16.000Z | fastiqa/bunches/iqa/test_images.py | utlive/PatchVQ | 040486b6342dfd36695f1daea0b5c4d77d728a23 | [
"Unlicense"
] | 7 | 2020-12-29T21:52:07.000Z | 2022-03-18T15:12:50.000Z | """fastai1 code, not yet converted"""
from ..label import *
from tqdm import tqdm
from fastai.vision import open_image
import os
from PIL import Image as PIL_Image
"""
# %%
from fastiqa.all import *
learn = RoIPoolLearner.from_cls(FLIVE, RoIPoolModel)
learn.path = Path('.')
learn.load('RoIPoolModel-fit(10,bs=120)')
l... | 32.38806 | 155 | 0.586175 |
e29fca0332219f46c9db03e2a55a11fef6c52985 | 687 | py | Python | src/appointments_has_payment/migrations/0001_initial.py | TheCleverlaure/sicco-web | 8e734c9bfa9c99056b6abd5276b65b1e4bf21e23 | [
"bzip2-1.0.6"
] | null | null | null | src/appointments_has_payment/migrations/0001_initial.py | TheCleverlaure/sicco-web | 8e734c9bfa9c99056b6abd5276b65b1e4bf21e23 | [
"bzip2-1.0.6"
] | null | null | null | src/appointments_has_payment/migrations/0001_initial.py | TheCleverlaure/sicco-web | 8e734c9bfa9c99056b6abd5276b65b1e4bf21e23 | [
"bzip2-1.0.6"
] | null | null | null | # Generated by Django 2.2.2 on 2019-12-26 03:31
from django.db import migrations, models
import django.db.models.deletion
| 25.444444 | 175 | 0.580786 |
e2a033cd806aa9352d0b43321894ec541d9fc3a8 | 2,264 | py | Python | codigos100/importaModulos.py | rosacarla/100-days-of-python-code | 3db9e35f861ce933e952cff2dd3a505dfce1b440 | [
"MIT"
] | 1 | 2021-09-26T09:17:36.000Z | 2021-09-26T09:17:36.000Z | codigos100/importaModulos.py | rosacarla/100-days-of-python-code | 3db9e35f861ce933e952cff2dd3a505dfce1b440 | [
"MIT"
] | null | null | null | codigos100/importaModulos.py | rosacarla/100-days-of-python-code | 3db9e35f861ce933e952cff2dd3a505dfce1b440 | [
"MIT"
] | null | null | null | # Codigo: Importa Modulos
# Autora: Carla Edila Silveira
# Finalidade: definir funcoes - curso Python Quick Start
# Data: 21/09/2021
# MODULO calendario do Python
import calendar # importa modulo de calendario
cal = calendar.month(2021, 9) # variavel recebe dados do calendario desejado
print(cal) # imprime o cale... | 43.538462 | 111 | 0.728357 |
e2a035bc77e1b89c5aef8a210f2601d3543648c1 | 11,873 | py | Python | mindspore/train/quant/quant.py | ZephyrChenzf/mindspore | 8f191847cf71e12715ced96bc3575914f980127a | [
"Apache-2.0"
] | 7 | 2020-05-24T03:19:26.000Z | 2020-05-24T03:20:00.000Z | mindspore/train/quant/quant.py | ZephyrChenzf/mindspore | 8f191847cf71e12715ced96bc3575914f980127a | [
"Apache-2.0"
] | null | null | null | mindspore/train/quant/quant.py | ZephyrChenzf/mindspore | 8f191847cf71e12715ced96bc3575914f980127a | [
"Apache-2.0"
] | null | null | null | # Copyright 2020 Huawei Technologies Co., Ltd
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to... | 45.144487 | 117 | 0.550577 |
e2a0ada4356b62ee8423668c3f8daf26b572107a | 5,992 | py | Python | examples/python/plots_boxplots.py | GreatWei/pythonStates | c4a9b326bfa312e2ae44a70f4dfaaf91f2d47a37 | [
"BSD-3-Clause"
] | 76 | 2019-12-28T08:37:10.000Z | 2022-03-29T02:19:41.000Z | examples/python/plots_boxplots.py | cluterdidiw/statsmodels | 543037fa5768be773a3ba31fba06e16a9edea46a | [
"BSD-3-Clause"
] | null | null | null | examples/python/plots_boxplots.py | cluterdidiw/statsmodels | 543037fa5768be773a3ba31fba06e16a9edea46a | [
"BSD-3-Clause"
] | 35 | 2020-02-04T14:46:25.000Z | 2022-03-24T03:56:17.000Z | # DO NOT EDIT
# Autogenerated from the notebook plots_boxplots.ipynb.
# Edit the notebook and then sync the output with this file.
#
# flake8: noqa
# DO NOT EDIT
#!/usr/bin/env python
# coding: utf-8
# #
# statsmodels `violin_plot` `bean_plot`.
import numpy as np
import matplotlib.pyplot as plt
import statsmode... | 26.990991 | 76 | 0.584112 |
e2a1277d6d5bab92b42350a997c75399618d77e4 | 5,736 | py | Python | forks/sphinx-git/tests/test_git_commit_detail.py | JakeGWater/Virtual-Production-Independent-Film-Guide | 022721f79b5b199f7208340564e9850dc9d97939 | [
"MIT"
] | 1 | 2021-06-25T03:15:26.000Z | 2021-06-25T03:15:26.000Z | forks/sphinx-git/tests/test_git_commit_detail.py | JakeGWater/Virtual-Production-Independent-Film-Guide | 022721f79b5b199f7208340564e9850dc9d97939 | [
"MIT"
] | 10 | 2021-04-16T17:45:06.000Z | 2021-06-26T20:59:17.000Z | forks/sphinx-git/tests/test_git_commit_detail.py | JakeGWater/Virtual-Production-Independent-Film-Guide | 022721f79b5b199f7208340564e9850dc9d97939 | [
"MIT"
] | 1 | 2021-04-16T19:48:45.000Z | 2021-04-16T19:48:45.000Z | # -*- coding: utf-8 -*-
import os
from tempfile import mkstemp
from bs4 import BeautifulSoup
from git import Repo
from nose.tools import assert_equal, assert_in, assert_is, assert_is_not
from sphinx_git import GitCommitDetail
from . import MakeTestableMixin, TempDirTestCase
| 39.558621 | 78 | 0.621688 |
e2a14db3105afb36bed7702d139b68659334f92c | 5,239 | py | Python | czitools/pylibczirw_tools.py | sebi06/czitools | 3fed073d5e56db0aaebe87f0e38af80b0724f005 | [
"BSD-3-Clause"
] | 4 | 2021-07-26T15:55:14.000Z | 2022-01-22T01:43:01.000Z | czitools/pylibczirw_tools.py | sebi06/czitools | 3fed073d5e56db0aaebe87f0e38af80b0724f005 | [
"BSD-3-Clause"
] | null | null | null | czitools/pylibczirw_tools.py | sebi06/czitools | 3fed073d5e56db0aaebe87f0e38af80b0724f005 | [
"BSD-3-Clause"
] | 1 | 2021-08-02T10:31:28.000Z | 2021-08-02T10:31:28.000Z | # -*- coding: utf-8 -*-
#################################################################
# File : pylibczirw_tools.py
# Version : 0.0.5
# Author : sebi06
# Date : 18.01.2022
#
# Disclaimer: This code is purely experimental. Feel free to
# use it at your own risk.
#
#############################... | 36.894366 | 116 | 0.584272 |
e2a1b463decdcf98f6fdf0ad03f13fe51a68b8aa | 1,316 | py | Python | tbx/people/migrations/0029_auto_20210728_1109.py | elviva404/wagtail-torchbox | 718d9e2c4337073f010296932d369c726a01dbd3 | [
"MIT"
] | 103 | 2015-02-24T17:58:21.000Z | 2022-03-23T08:08:58.000Z | tbx/people/migrations/0029_auto_20210728_1109.py | elviva404/wagtail-torchbox | 718d9e2c4337073f010296932d369c726a01dbd3 | [
"MIT"
] | 145 | 2015-01-13T17:13:43.000Z | 2022-03-29T12:56:20.000Z | tbx/people/migrations/0029_auto_20210728_1109.py | elviva404/wagtail-torchbox | 718d9e2c4337073f010296932d369c726a01dbd3 | [
"MIT"
] | 57 | 2015-01-03T12:00:37.000Z | 2022-02-09T13:11:30.000Z | # Generated by Django 2.2.17 on 2021-07-28 10:09
from django.db import migrations
import wagtail.core.blocks
import wagtail.core.fields
import wagtail.images.blocks
| 31.333333 | 153 | 0.403495 |
e2a20e7a3ae489800a9c2d7da9dadea501616d50 | 10,395 | py | Python | stage_2.py | prouast/ctc-intake-detection | 6dbfb9bbb0bb09980e4530b31742cb0d5357bf08 | [
"MIT"
] | null | null | null | stage_2.py | prouast/ctc-intake-detection | 6dbfb9bbb0bb09980e4530b31742cb0d5357bf08 | [
"MIT"
] | null | null | null | stage_2.py | prouast/ctc-intake-detection | 6dbfb9bbb0bb09980e4530b31742cb0d5357bf08 | [
"MIT"
] | null | null | null | """Evaluate exported frame-level probabilities."""
from __future__ import division
import argparse
import csv
import glob
import numpy as np
import os
from scipy.special import softmax
import sys
CSV_SUFFIX = '*.csv'
np.set_printoptions(threshold=sys.maxsize)
def import_probs_and_labels(args):
"""Import probabili... | 42.08502 | 137 | 0.614334 |
e2a3a5e193462cd9cfc3f8e77576ef311f0d6d70 | 1,050 | py | Python | async_sched/client/request_schedules.py | justengel/async_sched | f980722d51d15025522b2265426b0188ff368418 | [
"MIT"
] | 1 | 2020-10-19T13:36:20.000Z | 2020-10-19T13:36:20.000Z | async_sched/client/request_schedules.py | justengel/async_sched | f980722d51d15025522b2265426b0188ff368418 | [
"MIT"
] | null | null | null | async_sched/client/request_schedules.py | justengel/async_sched | f980722d51d15025522b2265426b0188ff368418 | [
"MIT"
] | null | null | null | """
module to run with the -m flag
python -m async_sched.client.request_schedules
"""
import argparse
from async_sched.client.client import request_schedules
from async_sched.utils import DEFAULT_HOST, DEFAULT_PORT
__all__ = ['NAME', 'get_argparse', 'main']
NAME = 'request_schedules'
if __name__ == '__main__'... | 26.25 | 117 | 0.70381 |
e2a3cfeded807fcc0d7d885eaf030b4b350af9cd | 3,775 | py | Python | tormentor/backgrounds.py | wsyCUHK/tormentor | 683b37fd943368137ddb8fc78f75ab750cf05526 | [
"Apache-2.0"
] | 2 | 2021-09-04T14:03:45.000Z | 2021-12-16T11:53:40.000Z | tormentor/backgrounds.py | wsyCUHK/tormentor | 683b37fd943368137ddb8fc78f75ab750cf05526 | [
"Apache-2.0"
] | null | null | null | tormentor/backgrounds.py | wsyCUHK/tormentor | 683b37fd943368137ddb8fc78f75ab750cf05526 | [
"Apache-2.0"
] | null | null | null | from .util import load_images_as_tensors
import torch
from diamond_square import functional_diamond_square
from .random import Uniform, Bernoulli, Categorical, Constant, Normal
from .base_augmentation import DeterministicImageAugmentation
| 46.604938 | 193 | 0.717086 |
e2a4885ec926f3d640fc765abc70c06983834ccb | 2,156 | py | Python | sns/api/reddit/reddit.py | kylepw/panner | 482ef8e8c1e8d9464d7dc8e4df5b5d9b58e83d35 | [
"MIT"
] | 2 | 2019-07-20T01:48:20.000Z | 2019-11-15T06:50:54.000Z | sns/api/reddit/reddit.py | kylepw/panner | 482ef8e8c1e8d9464d7dc8e4df5b5d9b58e83d35 | [
"MIT"
] | 5 | 2020-02-12T08:58:06.000Z | 2021-09-22T17:56:42.000Z | sns/api/reddit/reddit.py | kylepw/panner | 482ef8e8c1e8d9464d7dc8e4df5b5d9b58e83d35 | [
"MIT"
] | null | null | null | from datetime import datetime
import logging
import os
from praw import Reddit as PrawReddit
from prawcore.exceptions import NotFound
import pytz
logger = logging.getLogger(__name__)
| 35.933333 | 84 | 0.621521 |
e2a4a474063c3d3a0c1955abc43e6bbd6b0f9e4d | 5,417 | py | Python | src/pyside2_demo/frontend/example01/example01.py | chihyi-liao/pyside2_demo | 410bdaf0876897febf4607ff73928c60186c7be1 | [
"MIT"
] | null | null | null | src/pyside2_demo/frontend/example01/example01.py | chihyi-liao/pyside2_demo | 410bdaf0876897febf4607ff73928c60186c7be1 | [
"MIT"
] | null | null | null | src/pyside2_demo/frontend/example01/example01.py | chihyi-liao/pyside2_demo | 410bdaf0876897febf4607ff73928c60186c7be1 | [
"MIT"
] | null | null | null | from PySide2.QtCore import Slot, Qt, QThreadPool, QCoreApplication, QSize
from PySide2.QtGui import QIcon
from PySide2.QtWidgets import (
QDialog, QLabel, QLineEdit, QComboBox, QMainWindow, QMessageBox,
QWidget, QPushButton, QGridLayout, QDialogButtonBox, QTextEdit,
)
from pyside2_demo.utils import get_resourc... | 35.874172 | 86 | 0.628207 |
e2a69d6db231f2abaebeaf32c8c4d4494f27778d | 3,329 | py | Python | dashboard/dashboard/pinpoint/models/quest/read_value_test.py | tdresser/catapult-csm | 8f69b07e80198c1af0d5bd368d8ad8ced968884a | [
"BSD-3-Clause"
] | 4 | 2017-12-29T03:17:40.000Z | 2021-07-04T03:28:11.000Z | dashboard/dashboard/pinpoint/models/quest/read_value_test.py | tdresser/catapult-csm | 8f69b07e80198c1af0d5bd368d8ad8ced968884a | [
"BSD-3-Clause"
] | 1 | 2021-02-23T22:37:30.000Z | 2021-02-23T22:37:30.000Z | dashboard/dashboard/pinpoint/models/quest/read_value_test.py | tdresser/catapult-csm | 8f69b07e80198c1af0d5bd368d8ad8ced968884a | [
"BSD-3-Clause"
] | 6 | 2017-12-05T07:15:08.000Z | 2021-07-04T03:28:13.000Z | # Copyright 2017 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import json
import unittest
import mock
from dashboard.pinpoint.models.quest import read_value
| 32.320388 | 77 | 0.599279 |
e2a8d2bec3d6270cbb856eb6bae1fa43dddb9949 | 1,736 | py | Python | tests/test_lsp.py | WeixinYang/DatasetLoader | d6e800d6a9cca8809d7dab88a6a13a7916ef272d | [
"Apache-2.0"
] | 1 | 2021-08-16T14:14:40.000Z | 2021-08-16T14:14:40.000Z | tests/test_lsp.py | WeixinYang/DatasetLoader | d6e800d6a9cca8809d7dab88a6a13a7916ef272d | [
"Apache-2.0"
] | 1 | 2020-10-12T20:56:21.000Z | 2020-10-12T20:56:21.000Z | tests/test_lsp.py | WeixinYang/DatasetLoader | d6e800d6a9cca8809d7dab88a6a13a7916ef272d | [
"Apache-2.0"
] | 1 | 2021-06-14T10:30:08.000Z | 2021-06-14T10:30:08.000Z | import os.path
import pytest
from datasetloader import LSP
from datasetloader import LSPExtended
from . import DS_PATH
| 41.333333 | 78 | 0.611751 |
e2aefdb5d4c4918146034a0834daf3d3d9bd181b | 1,173 | py | Python | website/python/app.py | man-r/DimensionsLab | c94c3aec0d52326ad522a6fa41d43ec3bde87d74 | [
"MIT"
] | null | null | null | website/python/app.py | man-r/DimensionsLab | c94c3aec0d52326ad522a6fa41d43ec3bde87d74 | [
"MIT"
] | 1 | 2022-03-24T06:13:52.000Z | 2022-03-24T06:13:52.000Z | website/python/app.py | man-r/DimensionsLab | c94c3aec0d52326ad522a6fa41d43ec3bde87d74 | [
"MIT"
] | null | null | null | from flask import Flask
from flask_restful import Api, Resource, reqparse
app = Flask(__name__)
api = Api(app)
users = [
{
"name": "Nicholas",
"age": 42,
"occupation": "Network Engineer"
},
{
"name": "Elvin",
"age": 32,
"occupation": "Doctor"
},
{
... | 19.881356 | 66 | 0.58994 |
e2af09249eabdf6c6cfac1108013ff5630a16a85 | 371 | py | Python | src/applications/reviews/urls.py | Alex-T13/sxw_data_conversion | ae70198960af1af004ad28b73d6e885c5afa74c2 | [
"MIT"
] | null | null | null | src/applications/reviews/urls.py | Alex-T13/sxw_data_conversion | ae70198960af1af004ad28b73d6e885c5afa74c2 | [
"MIT"
] | null | null | null | src/applications/reviews/urls.py | Alex-T13/sxw_data_conversion | ae70198960af1af004ad28b73d6e885c5afa74c2 | [
"MIT"
] | null | null | null | from django.urls import path
from applications.reviews import views
urlpatterns = [
path('', views.AllPostView.as_view(), name='reviews'),
path('add_post', views.AddPostView.as_view(), name='add_post'),
path('post/<int:pk>', views.ShowPostView.as_view(), name='post'),
path('update_post/<int:pk>', view... | 33.727273 | 85 | 0.700809 |
e2af6e967078f9ead2d03be919925056b558ae89 | 13,207 | py | Python | tests/tests_with_server_and_cached_results/test_planner/test_canvas.py | aquariumbio/trident | d1712cae544103fb145e3171894e4b35141f6813 | [
"MIT"
] | 5 | 2019-01-21T11:12:05.000Z | 2020-03-05T20:52:14.000Z | tests/tests_with_server_and_cached_results/test_planner/test_canvas.py | aquariumbio/pydent | d1712cae544103fb145e3171894e4b35141f6813 | [
"MIT"
] | 28 | 2020-11-18T02:07:09.000Z | 2021-06-08T15:49:41.000Z | tests/tests_with_server_and_cached_results/test_planner/test_canvas.py | aquariumbio/trident | d1712cae544103fb145e3171894e4b35141f6813 | [
"MIT"
] | 2 | 2021-02-27T19:23:45.000Z | 2021-09-14T10:29:07.000Z | import pytest
from pydent.planner import Planner
from pydent.planner import PlannerException
from pydent.planner.utils import get_subgraphs
def test_add_wire_sets_sample_from_destination(session):
"""When adding a wire, the sample should be set from the destination to the
source."""
session.set_verbo... | 31.595694 | 88 | 0.687211 |
e2b0056c08e76535e1062630476c66ecd0573a56 | 1,021 | py | Python | icekit/plugins/image/migrations/0015_auto_20170310_2004.py | ic-labs/django-icekit | c507ea5b1864303732c53ad7c5800571fca5fa94 | [
"MIT"
] | 52 | 2016-09-13T03:50:58.000Z | 2022-02-23T16:25:08.000Z | icekit/plugins/image/migrations/0015_auto_20170310_2004.py | ic-labs/django-icekit | c507ea5b1864303732c53ad7c5800571fca5fa94 | [
"MIT"
] | 304 | 2016-08-11T14:17:30.000Z | 2020-07-22T13:35:18.000Z | icekit/plugins/image/migrations/0015_auto_20170310_2004.py | ic-labs/django-icekit | c507ea5b1864303732c53ad7c5800571fca5fa94 | [
"MIT"
] | 12 | 2016-09-21T18:46:35.000Z | 2021-02-15T19:37:50.000Z | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import migrations, models
| 34.033333 | 197 | 0.643487 |
e2b14a40b24c80800d570e25ab804585deb5e038 | 3,531 | py | Python | b3j0f/conf/parser/resolver/base.py | b3j0f/configuration | 18dd6d5d6560f9b202793739e2330a2181163511 | [
"MIT"
] | 3 | 2016-02-18T18:58:24.000Z | 2017-03-14T08:40:01.000Z | b3j0f/conf/parser/resolver/base.py | b3j0f/configuration | 18dd6d5d6560f9b202793739e2330a2181163511 | [
"MIT"
] | 1 | 2016-02-18T15:27:35.000Z | 2016-04-02T10:36:43.000Z | b3j0f/conf/parser/resolver/base.py | b3j0f/configuration | 18dd6d5d6560f9b202793739e2330a2181163511 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
# --------------------------------------------------------------------
# The MIT License (MIT)
#
#Copyright (c) 2015 Jonathan Labjof <jonathan.labejof@gmail.com>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation file... | 35.666667 | 79 | 0.704616 |
e2b187b27bc8c59eec3870b18d05e4350c4e270b | 1,670 | py | Python | statement_renamer/extractors/capitalone360.py | mkazin/StatementRenamer | ef03c71f0e627a15a4bba08e45bfa90ecacd28fc | [
"Apache-2.0"
] | null | null | null | statement_renamer/extractors/capitalone360.py | mkazin/StatementRenamer | ef03c71f0e627a15a4bba08e45bfa90ecacd28fc | [
"Apache-2.0"
] | 15 | 2018-05-01T12:48:30.000Z | 2021-05-14T02:52:48.000Z | statement_renamer/extractors/capitalone360.py | mkazin/StatementRenamer | ef03c71f0e627a15a4bba08e45bfa90ecacd28fc | [
"Apache-2.0"
] | 1 | 2019-07-09T22:59:50.000Z | 2019-07-09T22:59:50.000Z | from datetime import datetime
from .extractor import DateExtractor, ExtractedData, ExtractorException
| 29.821429 | 83 | 0.592814 |
e2b274a05a49e36d3f5f1623c359598acd291590 | 1,335 | py | Python | setup.py | oeg-upm/ya2ro | 799b59046c77a9277b92f2adfa1521d353dfe93d | [
"Apache-2.0"
] | 1 | 2021-10-06T09:34:48.000Z | 2021-10-06T09:34:48.000Z | setup.py | oeg-upm/ya2ro | 799b59046c77a9277b92f2adfa1521d353dfe93d | [
"Apache-2.0"
] | 30 | 2021-11-17T18:35:31.000Z | 2022-03-28T10:46:45.000Z | setup.py | PavelAntonia/EELISA-research-object | 799b59046c77a9277b92f2adfa1521d353dfe93d | [
"Apache-2.0"
] | 1 | 2021-11-22T17:15:53.000Z | 2021-11-22T17:15:53.000Z | from setuptools import find_packages, setup
version = {}
with open("src/ya2ro/ya2ro.py") as fp:
exec(fp.read(), version)
setup(
name='ya2ro',
author='Antonia Pavel',
author_email='floriana.antonia.pavel@gmail.com',
description='Tool to which you pass basic information of a project or a research ar... | 37.083333 | 393 | 0.64794 |
e2b3842f07dbcbc4ffcb207564d327421078951a | 13,816 | py | Python | google/ads/google_ads/v3/proto/resources/ad_group_simulation_pb2.py | jphanwebstaurant/google-ads-python | 600812b2afcc4d57f00b47dfe436620ce50bfe9b | [
"Apache-2.0"
] | 1 | 2019-11-30T23:42:39.000Z | 2019-11-30T23:42:39.000Z | google/ads/google_ads/v3/proto/resources/ad_group_simulation_pb2.py | jphanwebstaurant/google-ads-python | 600812b2afcc4d57f00b47dfe436620ce50bfe9b | [
"Apache-2.0"
] | null | null | null | google/ads/google_ads/v3/proto/resources/ad_group_simulation_pb2.py | jphanwebstaurant/google-ads-python | 600812b2afcc4d57f00b47dfe436620ce50bfe9b | [
"Apache-2.0"
] | 1 | 2020-09-30T17:04:06.000Z | 2020-09-30T17:04:06.000Z | # -*- coding: utf-8 -*-
# Generated by the protocol buffer compiler. DO NOT EDIT!
# source: google/ads/googleads_v3/proto/resources/ad_group_simulation.proto
import sys
_b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1'))
from google.protobuf import descriptor as _descriptor
from google.protobuf... | 65.478673 | 2,070 | 0.799797 |
e2b4314ef8bc163fb60b81c13fb7809c116746e2 | 1,958 | py | Python | notebook/filter_usage.py | vhn0912/python-snippets | 80b2e1d6b2b8f12ae30d6dbe86d25bb2b3a02038 | [
"MIT"
] | 174 | 2018-05-30T21:14:50.000Z | 2022-03-25T07:59:37.000Z | notebook/filter_usage.py | vhn0912/python-snippets | 80b2e1d6b2b8f12ae30d6dbe86d25bb2b3a02038 | [
"MIT"
] | 5 | 2019-08-10T03:22:02.000Z | 2021-07-12T20:31:17.000Z | notebook/filter_usage.py | vhn0912/python-snippets | 80b2e1d6b2b8f12ae30d6dbe86d25bb2b3a02038 | [
"MIT"
] | 53 | 2018-04-27T05:26:35.000Z | 2022-03-25T07:59:37.000Z | l = [-2, -1, 0, 1, 2]
print(filter(lambda x: x % 2 == 0, l))
# <filter object at 0x10bb38580>
print(type(filter(lambda x: x % 2 == 0, l)))
# <class 'filter'>
for i in filter(lambda x: x % 2 == 0, l):
print(i)
# -2
# 0
# 2
print(list(filter(lambda x: x % 2 == 0, l)))
# [-2, 0, 2]
print(list(filter(lambda x: x % ... | 20.610526 | 66 | 0.528601 |
e2b54a9ef95fb28def62c063b36281a5860a7e5a | 3,487 | py | Python | model/ANOVA.py | narayan954/fellowship-prediction | e6e58389533307fd79d28703fdff3c664242d8da | [
"MIT"
] | 47 | 2021-09-23T00:29:13.000Z | 2022-02-27T10:02:55.000Z | model/ANOVA.py | narayan954/fellowship-prediction | e6e58389533307fd79d28703fdff3c664242d8da | [
"MIT"
] | 7 | 2021-09-22T19:50:35.000Z | 2021-11-30T08:20:19.000Z | model/ANOVA.py | narayan954/fellowship-prediction | e6e58389533307fd79d28703fdff3c664242d8da | [
"MIT"
] | 6 | 2021-09-21T22:34:37.000Z | 2021-09-30T18:25:41.000Z | import pandas as pd
import json
# plots
import matplotlib.pyplot as plt
import seaborn as sns
import scipy.stats as stats
# Load and read json data
df = pd.read_json('full_info.json', lines=True)
user_name, commits, followers, repo, stars, forks, organizations, issues, contributions = \
[], [], [], [], [], [], [], [... | 35.222222 | 104 | 0.70261 |
e2b5c67e502f994e897f387d32a8d2db81b2df7b | 3,400 | py | Python | BeagleBone/Green/Grove/Software/Python/Grove_dht.py | zhanglongqi/cloud9-examples | db73b843a807361153a00e17a703206202cf73f8 | [
"MIT"
] | 37 | 2019-05-30T16:40:01.000Z | 2021-11-29T10:34:36.000Z | BeagleBone/Green/Grove/Software/Python/Grove_dht.py | zhanglongqi/cloud9-examples | db73b843a807361153a00e17a703206202cf73f8 | [
"MIT"
] | 35 | 2019-04-03T17:35:26.000Z | 2022-03-23T12:28:08.000Z | BeagleBone/Green/Grove/Software/Python/Grove_dht.py | zhanglongqi/cloud9-examples | db73b843a807361153a00e17a703206202cf73f8 | [
"MIT"
] | 40 | 2019-05-13T00:25:42.000Z | 2022-03-23T05:13:15.000Z | import time
import Adafruit_BBIO.GPIO as GPIO
Debug = True
if __name__=="__main__":
dht=DHT("P8_10")
while True:
pass
temp = dht.readTemperature()
print temp
time.sleep(1)
| 28.813559 | 104 | 0.437059 |
e2b5f97fc73e692fc433612b8f6ee7e770757d71 | 31 | py | Python | victoria/__init__.py | Vitens/Victoria | 9f464105f00165ab3f9fd47837455cb68d4bd704 | [
"Apache-2.0"
] | 1 | 2020-09-08T15:02:06.000Z | 2020-09-08T15:02:06.000Z | victoria/__init__.py | Vitens/Victoria | 9f464105f00165ab3f9fd47837455cb68d4bd704 | [
"Apache-2.0"
] | null | null | null | victoria/__init__.py | Vitens/Victoria | 9f464105f00165ab3f9fd47837455cb68d4bd704 | [
"Apache-2.0"
] | 1 | 2020-01-08T18:32:25.000Z | 2020-01-08T18:32:25.000Z | from .victoria import Victoria
| 15.5 | 30 | 0.83871 |
e2b8e2b89a1d109f4bd53134df5660df9751af92 | 545 | py | Python | actstream/tests/test_apps.py | kimbugp/django-activity-stream | 4e53e62adf2b82cd01ab70a033839ab61b2d087b | [
"BSD-3-Clause"
] | 1,489 | 2015-01-02T02:46:30.000Z | 2022-03-30T07:32:45.000Z | actstream/tests/test_apps.py | kimbugp/django-activity-stream | 4e53e62adf2b82cd01ab70a033839ab61b2d087b | [
"BSD-3-Clause"
] | 277 | 2015-01-02T19:54:09.000Z | 2022-03-28T12:07:20.000Z | actstream/tests/test_apps.py | kimbugp/django-activity-stream | 4e53e62adf2b82cd01ab70a033839ab61b2d087b | [
"BSD-3-Clause"
] | 345 | 2015-01-13T01:02:42.000Z | 2022-03-21T09:39:26.000Z | from unittest import TestCase
from django.apps.registry import apps
| 28.684211 | 93 | 0.702752 |
2c3378c740ae8e44f9721f70acf8526419bc1dcc | 26,445 | py | Python | viz_platform/dynamic_datasets/model/classes.py | alexanderzimmerman/smart-vp-server | 3aa57b5fa32e90a8406684d0d0a2860e224d7916 | [
"Apache-2.0"
] | null | null | null | viz_platform/dynamic_datasets/model/classes.py | alexanderzimmerman/smart-vp-server | 3aa57b5fa32e90a8406684d0d0a2860e224d7916 | [
"Apache-2.0"
] | null | null | null | viz_platform/dynamic_datasets/model/classes.py | alexanderzimmerman/smart-vp-server | 3aa57b5fa32e90a8406684d0d0a2860e224d7916 | [
"Apache-2.0"
] | null | null | null | import numpy as np
import scipy
import scipy.special
import scipy.interpolate
import pickle
import sklearn
import matplotlib as mpl
mpl.use('Agg')
import matplotlib.pyplot as plt
import matplotlib.gridspec as gridspec
import MySQLdb
import sqlalchemy
from sqlalchemy.ext.declarative import declarative_base
import sqla... | 49.615385 | 163 | 0.690187 |