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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
57d09074769759b5c763c51e278ea561e4492dc7 | 450 | py | Python | admin/urls.py | ttdys108/django-demo | 9a1c18b4bf7d92f1b122222d1777424fac2aba2d | [
"Apache-2.0"
] | null | null | null | admin/urls.py | ttdys108/django-demo | 9a1c18b4bf7d92f1b122222d1777424fac2aba2d | [
"Apache-2.0"
] | null | null | null | admin/urls.py | ttdys108/django-demo | 9a1c18b4bf7d92f1b122222d1777424fac2aba2d | [
"Apache-2.0"
] | null | null | null | from django.urls import path
from .views import index, users, weather
app_name = 'admin'
urlpatterns = [
path('', index.index, name='index'),
path('users/', users.index, name='users.index'),
path('users/add', users.add, name='users.add'),
path('users/update', users.update, name='users.update'),
pat... | 37.5 | 70 | 0.668889 |
57d29c7cf6b8de616c1ca548e36d5b66ed5cfd04 | 3,360 | py | Python | Disco.py | daniel-s-ingram/disco | f6edfa0d09c5cf822e93b554bb6aea63525441a7 | [
"MIT"
] | null | null | null | Disco.py | daniel-s-ingram/disco | f6edfa0d09c5cf822e93b554bb6aea63525441a7 | [
"MIT"
] | null | null | null | Disco.py | daniel-s-ingram/disco | f6edfa0d09c5cf822e93b554bb6aea63525441a7 | [
"MIT"
] | null | null | null | import sys
import requests
from statistics import mean, stdev
from bs4 import BeautifulSoup
import matplotlib.pyplot as plt
if __name__ == '__main__':
if len(sys.argv) == 1:
artist = "Bon Iver"
else:
artist = ' '.join(sys.argv[1:])
Disco(artist)
| 38.62069 | 126 | 0.62381 |
57d2bee9c3f83e95b3a975a6474c1974993fb8ef | 15,013 | py | Python | src/tools/dev/scripts/hooks/ciabot_svn.py | eddieTest/visit | ae7bf6f5f16b01cf6b672d34e2d293fa7170616b | [
"BSD-3-Clause"
] | null | null | null | src/tools/dev/scripts/hooks/ciabot_svn.py | eddieTest/visit | ae7bf6f5f16b01cf6b672d34e2d293fa7170616b | [
"BSD-3-Clause"
] | null | null | null | src/tools/dev/scripts/hooks/ciabot_svn.py | eddieTest/visit | ae7bf6f5f16b01cf6b672d34e2d293fa7170616b | [
"BSD-3-Clause"
] | 1 | 2020-03-18T23:17:43.000Z | 2020-03-18T23:17:43.000Z | #!/usr/bin/env python
#
# This is a CIA client script for Subversion repositories, written in python.
# It generates commit messages using CIA's XML format, and can deliver them
# using either XML-RPC or email. See below for usage and cuztomization
# information.
#
# ----------------------------------------------------... | 37.626566 | 98 | 0.605142 |
57d2ea3f2d5e155d3c26ab3d8579888941aaacdc | 493 | py | Python | lists_04/insertion_at_a_specified_position_in_a_list.py | njoroge33/py_learn | 6ad55f37789045bc5c03f3dd668cf1ea497f4e84 | [
"MIT"
] | null | null | null | lists_04/insertion_at_a_specified_position_in_a_list.py | njoroge33/py_learn | 6ad55f37789045bc5c03f3dd668cf1ea497f4e84 | [
"MIT"
] | 2 | 2019-04-15T06:29:55.000Z | 2019-04-19T17:34:32.000Z | lists_04/insertion_at_a_specified_position_in_a_list.py | njoroge33/py_learn | 6ad55f37789045bc5c03f3dd668cf1ea497f4e84 | [
"MIT"
] | 1 | 2019-11-19T04:51:18.000Z | 2019-11-19T04:51:18.000Z | # Given a list x of length n, a number to be inserted into the list and a position where to insert the number
# return the new list
# e.g given [2, 3, 6, 7], num=8 and position=2, return [2, 3, 8, 6, 7]
# for more info on this quiz, go to this url: http://www.programmr.com/insertion-specified-position-array-0
if __n... | 35.214286 | 109 | 0.673428 |
57d3a9d76e06f373164b6aa991f8a00afed0d016 | 530 | py | Python | carton/tests/urls.py | knyazz/py3-django-enriched-carton | 27d97388d8153f29a3c629cdcd3e734ad09dc52e | [
"MIT"
] | null | null | null | carton/tests/urls.py | knyazz/py3-django-enriched-carton | 27d97388d8153f29a3c629cdcd3e734ad09dc52e | [
"MIT"
] | null | null | null | carton/tests/urls.py | knyazz/py3-django-enriched-carton | 27d97388d8153f29a3c629cdcd3e734ad09dc52e | [
"MIT"
] | null | null | null | from django.conf.urls import url
from .views import (
add,
clear,
remove,
remove_single,
set_quantity,
show
)
urlpatterns = [
url(r'^show/$', show, name='carton-tests-show'),
url(r'^add/$', add, name='carton-tests-add'),
url(r'^remove/$', remove, name='carton-tests-remove'),
u... | 25.238095 | 79 | 0.632075 |
57d50f67e3d06852292f8ffe636f692eff8d51a1 | 4,798 | py | Python | spectrumanalyzer.py | cwolfe007/LEDSoundResponsiveSuit | 86c03e80a7b689e418629e4d11674299d0cad64b | [
"MIT"
] | null | null | null | spectrumanalyzer.py | cwolfe007/LEDSoundResponsiveSuit | 86c03e80a7b689e418629e4d11674299d0cad64b | [
"MIT"
] | 1 | 2019-05-05T03:13:11.000Z | 2019-05-05T03:13:11.000Z | spectrumanalyzer.py | cwolfe007/LEDSoundRepsponsiveSuit | 86c03e80a7b689e418629e4d11674299d0cad64b | [
"MIT"
] | null | null | null |
# Spectrum Analyzer Code Author: Caleb Wolfe
import time
import Adafruit_GPIO.SPI as SPI
import Adafruit_MCP3008
import numpy as np
print('Reading MCP3008 values, press Ctrl-C to quit...')
| 35.279412 | 316 | 0.563568 |
57d556f00239b349c7bc417ac464a9d2c21e51b0 | 7,992 | py | Python | hs_core/discovery_form.py | tommac7/hydroshare | 87c4543a55f98103d2614bf4c47f7904c3f9c029 | [
"BSD-3-Clause"
] | 178 | 2015-01-08T23:03:36.000Z | 2022-03-03T13:56:45.000Z | hs_core/discovery_form.py | tommac7/hydroshare | 87c4543a55f98103d2614bf4c47f7904c3f9c029 | [
"BSD-3-Clause"
] | 4,125 | 2015-01-01T14:26:15.000Z | 2022-03-31T16:38:55.000Z | hs_core/discovery_form.py | tommac7/hydroshare | 87c4543a55f98103d2614bf4c47f7904c3f9c029 | [
"BSD-3-Clause"
] | 53 | 2015-03-15T17:56:51.000Z | 2022-03-17T00:32:16.000Z | from haystack.forms import FacetedSearchForm
from haystack.query import SQ
from django import forms
from hs_core.discovery_parser import ParseSQ, MatchingBracketsNotFoundError, \
FieldNotRecognizedError, InequalityNotAllowedError, MalformedDateError
FACETS_TO_SHOW = ['creator', 'contributor', 'owner', 'content_typ... | 43.434783 | 98 | 0.56031 |
57d6f9635f5e00346ee661f725027deab67f7b92 | 26,096 | py | Python | streamlit_prophet/lib/exposition/visualize.py | carolinedlu/darkpool-snowvation | c795a95288e5d58c60aee69afacbb93374fe0900 | [
"MIT"
] | 36 | 2021-09-16T12:34:13.000Z | 2021-12-11T20:51:58.000Z | streamlit_prophet/lib/exposition/visualize.py | carolinedlu/darkpool-snowvation | c795a95288e5d58c60aee69afacbb93374fe0900 | [
"MIT"
] | 7 | 2022-01-22T03:53:37.000Z | 2022-02-12T17:41:23.000Z | streamlit_prophet/lib/exposition/visualize.py | carolinedlu/darkpool-snowvation | c795a95288e5d58c60aee69afacbb93374fe0900 | [
"MIT"
] | 20 | 2021-12-16T00:56:32.000Z | 2022-03-20T00:52:08.000Z | from typing import Any, Dict, List
import datetime
import pandas as pd
import plotly.express as px
import plotly.figure_factory as ff
import plotly.graph_objects as go
import streamlit as st
from fbprophet import Prophet
from fbprophet.plot import plot_plotly
from plotly.subplots import make_subplots
from streamlit_p... | 35.312585 | 110 | 0.606338 |
57d8dced3bb1517e1acbcb80d5b0ad588a00e015 | 9,343 | py | Python | tracking/admin.py | mohdbakhrayba/it-assets | ea03882ffd70e40c82f5684dc4980ff46520843b | [
"Apache-2.0"
] | null | null | null | tracking/admin.py | mohdbakhrayba/it-assets | ea03882ffd70e40c82f5684dc4980ff46520843b | [
"Apache-2.0"
] | null | null | null | tracking/admin.py | mohdbakhrayba/it-assets | ea03882ffd70e40c82f5684dc4980ff46520843b | [
"Apache-2.0"
] | null | null | null | from datetime import date, datetime, timedelta
from django.conf import settings
from django.conf.urls import url
from django.contrib.admin import register, ModelAdmin
from django.http import HttpResponse
import pytz
import xlsxwriter
from .models import Computer, Mobile, EC2Instance, FreshdeskTicket, LicensingRule
... | 30.433225 | 136 | 0.494809 |
57d96e1c007274d36d8529dbd1130a23bc0cd5c7 | 3,093 | py | Python | accounts/tests/test_views.py | jhonatanlteodoro/ecommerce-django | 931c70bba7658cdb982e5294e02c2b90d02b8c82 | [
"MIT"
] | 1 | 2020-01-07T20:50:48.000Z | 2020-01-07T20:50:48.000Z | accounts/tests/test_views.py | jhonatanlteodoro/ecommerce-django | 931c70bba7658cdb982e5294e02c2b90d02b8c82 | [
"MIT"
] | null | null | null | accounts/tests/test_views.py | jhonatanlteodoro/ecommerce-django | 931c70bba7658cdb982e5294e02c2b90d02b8c82 | [
"MIT"
] | null | null | null | from django.test import Client
from django.test import TestCase
from django.urls import reverse
from django.contrib.auth import get_user_model
from model_mommy import mommy
from django.conf import settings
User = get_user_model()
| 34.366667 | 84 | 0.648885 |
57daf6cc7d59c78379540bcf163d574b373cca46 | 3,360 | py | Python | modules/data_generator.py | radiradev/finetuned-cvn | 67ae5d659b6c78f670acac126e2411498048e548 | [
"MIT"
] | 1 | 2020-09-17T09:23:27.000Z | 2020-09-17T09:23:27.000Z | modules/data_generator.py | radiradev/finetuned-cvn | 67ae5d659b6c78f670acac126e2411498048e548 | [
"MIT"
] | null | null | null | modules/data_generator.py | radiradev/finetuned-cvn | 67ae5d659b6c78f670acac126e2411498048e548 | [
"MIT"
] | 1 | 2021-01-25T13:17:17.000Z | 2021-01-25T13:17:17.000Z | """
DUNE CVN generator module.
"""
__version__ = '1.0'
__author__ = 'Saul Alonso-Monsalve, Leigh Howard Whitehead'
__email__ = "saul.alonso.monsalve@cern.ch, leigh.howard.whitehead@cern.ch"
import numpy as np
import zlib
| 32.941176 | 104 | 0.574702 |
57dcfbeaa86e0a7c3e91ecfd4e63ebdf3ea2ed9b | 2,139 | py | Python | car_classifier/utils.py | SaraLatif99/car-classification | 27b017e9cba66935c0f715d5584cfd7fe7bd4653 | [
"MIT"
] | 2 | 2020-03-21T19:26:39.000Z | 2021-06-14T18:45:10.000Z | car_classifier/utils.py | SaraLatif99/car-classification | 27b017e9cba66935c0f715d5584cfd7fe7bd4653 | [
"MIT"
] | null | null | null | car_classifier/utils.py | SaraLatif99/car-classification | 27b017e9cba66935c0f715d5584cfd7fe7bd4653 | [
"MIT"
] | 5 | 2020-02-26T13:35:23.000Z | 2022-03-11T20:05:34.000Z | import numpy as np
import matplotlib.pyplot as plt
import tensorflow as tf
def show_batch(ds: tf.data.Dataset,
classes: list,
rescale: bool = False,
size: tuple = (10, 10),
title: str = None):
"""
Function to show a batch of images including labels f... | 27.779221 | 94 | 0.580645 |
57dd47aedd8a524e75ea171983002bdec3519055 | 8,078 | py | Python | mc_states/grains/makina_grains.py | makinacorpus/makina-states | 8ae1ccd1a0b614a7f308229c07e1493b06f5883a | [
"BSD-3-Clause"
] | 18 | 2015-02-22T12:53:50.000Z | 2019-03-15T16:45:10.000Z | mc_states/grains/makina_grains.py | makinacorpus/makina-states | 8ae1ccd1a0b614a7f308229c07e1493b06f5883a | [
"BSD-3-Clause"
] | 20 | 2015-01-20T22:35:02.000Z | 2017-11-06T11:17:34.000Z | doc/sphinx/mc_states/grains/makina_grains.py | makinacorpus/makina-states | 8ae1ccd1a0b614a7f308229c07e1493b06f5883a | [
"BSD-3-Clause"
] | 5 | 2015-01-13T04:23:09.000Z | 2019-01-03T17:00:31.000Z | #!/usr/bin/env python
# -*- coding: utf-8 -*-
'''
Makina custom grains
=====================
makina.upstart
true if using upstart
makina.lxc
true if inside an lxc container
makina.docker
true if inside a docker container
makina.devhost_num
devhost num if any
'''
import os
import copy
import subprocess... | 26.837209 | 68 | 0.522035 |
57ddb4b5d3ed3ad05cafa6472e006c6f0d350af7 | 1,390 | py | Python | scripts/devops_tasks/trust_proxy_cert.py | vincenttran-msft/azure-sdk-for-python | 348b56f9f03eeb3f7b502eed51daf494ffff874d | [
"MIT"
] | 2,728 | 2015-01-09T10:19:32.000Z | 2022-03-31T14:50:33.000Z | scripts/devops_tasks/trust_proxy_cert.py | v-xuto/azure-sdk-for-python | 9c6296d22094c5ede410bc83749e8df8694ccacc | [
"MIT"
] | 17,773 | 2015-01-05T15:57:17.000Z | 2022-03-31T23:50:25.000Z | scripts/devops_tasks/trust_proxy_cert.py | v-xuto/azure-sdk-for-python | 9c6296d22094c5ede410bc83749e8df8694ccacc | [
"MIT"
] | 1,916 | 2015-01-19T05:05:41.000Z | 2022-03-31T19:36:44.000Z | import requests
import os
EXISTING_ROOT_PEM = requests.certs.where()
root_dir = os.path.abspath(os.path.join(os.path.abspath(__file__), "..", "..", ".."))
LOCAL_DEV_CERT = os.path.abspath(os.path.join(root_dir, 'eng', 'common', 'testproxy', 'dotnet-devcert.crt'))
COMBINED_FILENAME = os.path.basename(LOCAL_DEV_CERT).s... | 34.75 | 108 | 0.697122 |
57dfafb9e8933dbd5e630eaa629e5d73f23115df | 1,866 | py | Python | tests/onegov/wtfs/test_fields.py | politbuero-kampagnen/onegov-cloud | 20148bf321b71f617b64376fe7249b2b9b9c4aa9 | [
"MIT"
] | null | null | null | tests/onegov/wtfs/test_fields.py | politbuero-kampagnen/onegov-cloud | 20148bf321b71f617b64376fe7249b2b9b9c4aa9 | [
"MIT"
] | null | null | null | tests/onegov/wtfs/test_fields.py | politbuero-kampagnen/onegov-cloud | 20148bf321b71f617b64376fe7249b2b9b9c4aa9 | [
"MIT"
] | null | null | null | from cgi import FieldStorage
from datetime import date
from io import BytesIO
from onegov.core.utils import Bunch
from onegov.form import Form
from onegov.wtfs.fields import HintField
from onegov.wtfs.fields import MunicipalityDataUploadField
| 29.15625 | 76 | 0.663987 |
57e57da0d0ba47a4766076fdde40ebae4111f44b | 2,156 | py | Python | airflow_server/dags/cbs.py | ephraimberkovitch/anyway-etl | e5b4b8c18ef9899c8edbdbc8bfecc933b56c892b | [
"MIT"
] | null | null | null | airflow_server/dags/cbs.py | ephraimberkovitch/anyway-etl | e5b4b8c18ef9899c8edbdbc8bfecc933b56c892b | [
"MIT"
] | 15 | 2021-08-22T11:53:47.000Z | 2022-02-21T17:09:53.000Z | airflow_server/dags/cbs.py | ephraimberkovitch/anyway-etl | e5b4b8c18ef9899c8edbdbc8bfecc933b56c892b | [
"MIT"
] | 5 | 2021-07-20T22:19:35.000Z | 2022-02-22T09:44:25.000Z | from airflow import DAG
from airflow.utils.dates import days_ago
from anyway_etl_airflow.operators.cli_bash_operator import CliBashOperator
dag_kwargs = dict(
default_args={
'owner': 'airflow',
},
schedule_interval='@weekly',
catchup=False,
start_date=days_ago(2),
)
with DAG('cbs', **da... | 39.2 | 126 | 0.612709 |
57e9214f569a136ae9aadc59ca630b01df45985d | 1,069 | py | Python | automation/devops_automation_infra/utils/s3.py | AnyVisionltd/devops-automation-infra | 7d6e75dc96ffa53d07e1dbd2c4ddb0fcdcf92cd1 | [
"MIT"
] | 2 | 2021-03-10T14:52:24.000Z | 2021-03-10T18:50:20.000Z | automation/devops_automation_infra/utils/s3.py | solganik/devops-automation-infra | 2ef2ac80a52d2f2abd037ad24cbf7f98b0c50bc6 | [
"MIT"
] | 4 | 2021-03-14T11:30:11.000Z | 2022-01-30T16:01:41.000Z | automation/devops_automation_infra/utils/s3.py | solganik/devops-automation-infra | 2ef2ac80a52d2f2abd037ad24cbf7f98b0c50bc6 | [
"MIT"
] | 5 | 2021-03-10T14:52:14.000Z | 2021-11-17T16:00:18.000Z | import os
import boto3
from automation_infra.utils import concurrently
from functools import partial
| 39.592593 | 114 | 0.77362 |
57e9e749952419b13882858f912e11103e5702e3 | 263 | py | Python | part_1_read_test_dat.py | MOTWODAHS/cc_tools | bcf79bc62c4db06bc64622f118d62b171691e80d | [
"MIT"
] | null | null | null | part_1_read_test_dat.py | MOTWODAHS/cc_tools | bcf79bc62c4db06bc64622f118d62b171691e80d | [
"MIT"
] | null | null | null | part_1_read_test_dat.py | MOTWODAHS/cc_tools | bcf79bc62c4db06bc64622f118d62b171691e80d | [
"MIT"
] | null | null | null | import cc_dat_utils
#Part 1
input_dat_file = "data/pfgd_test.dat"
#Use cc_dat_utils.make_cc_level_pack_from_dat() to load the file specified by input_dat_file
#print the resulting data
data = cc_dat_utils.make_cc_level_pack_from_dat(input_dat_file)
print(data) | 26.3 | 92 | 0.836502 |
57ea16b86e437b4ce502cfa0fbd2394638685369 | 4,808 | py | Python | src/gen_drum_kit/importer/importer_hydrogen.py | peter-zenk/genDrumkit | a74bae332443db6424be46ebd32b8fffeac14ce1 | [
"MIT"
] | 7 | 2020-06-25T15:36:17.000Z | 2022-01-09T21:43:27.000Z | src/gen_drum_kit/importer/importer_hydrogen.py | peter-zenk/genDrumkit | a74bae332443db6424be46ebd32b8fffeac14ce1 | [
"MIT"
] | 3 | 2022-01-09T20:44:52.000Z | 2022-02-02T10:43:23.000Z | src/gen_drum_kit/importer/importer_hydrogen.py | peter-zenk/genDrumkit | a74bae332443db6424be46ebd32b8fffeac14ce1 | [
"MIT"
] | 1 | 2020-08-16T18:17:26.000Z | 2020-08-16T18:17:26.000Z | '''
Created on Jun 14, 2020
@author: peter
'''
import sys
import re
import tarfile
from os import path
import xml.etree.ElementTree as ET
import logging
from gen_drum_kit.importer.importer_base import ImporterBase
from gen_drum_kit.builder.builder_hydrogen import Builder_Hydrogen
from gen_drum_kit.util ... | 34.84058 | 99 | 0.576955 |
57eb7325fe9ef8d6594ce7350e80b8d6714ba595 | 3,094 | py | Python | icbd/type_analyzer/tests/parametric.py | kmod/icbd | 9636564eb3993afa07c6220d589bbd1991923d74 | [
"MIT"
] | 7 | 2015-04-06T15:17:13.000Z | 2020-10-21T04:57:00.000Z | icbd/type_analyzer/tests/parametric.py | kmod/icbd | 9636564eb3993afa07c6220d589bbd1991923d74 | [
"MIT"
] | null | null | null | icbd/type_analyzer/tests/parametric.py | kmod/icbd | 9636564eb3993afa07c6220d589bbd1991923d74 | [
"MIT"
] | 4 | 2016-05-16T17:53:08.000Z | 2020-11-28T17:18:50.000Z | import collections
l = [1] # 0 [<int|str>]
l.append(2) # 0 [<int|str>] # 2 (<int|str>) -> None
l.append('')
l[0] = 1
l[0] = ""
l2 = list(l) # 0 [<int|str>]
l2 = sorted(l) # 0 [<int|str>]
x = collections.deque(l2).pop() # 0 <int|str>
l2 = reversed(l) # 0 iterator of <int|str>
l2 = {1:l}[1] # 0 [<int|str>]
l2 = {'':l}[... | 21.486111 | 65 | 0.486102 |
57ecf565cf5dcf9d17a6be622ca1dec561a24016 | 2,001 | py | Python | pylab/image/restoration/blind_deconv.py | N8Grant/Blind-Deconvolution-Python | a5e18e2b68b1cdd81a35d2db07b66d735aceac15 | [
"MIT"
] | null | null | null | pylab/image/restoration/blind_deconv.py | N8Grant/Blind-Deconvolution-Python | a5e18e2b68b1cdd81a35d2db07b66d735aceac15 | [
"MIT"
] | null | null | null | pylab/image/restoration/blind_deconv.py | N8Grant/Blind-Deconvolution-Python | a5e18e2b68b1cdd81a35d2db07b66d735aceac15 | [
"MIT"
] | null | null | null | import matlab.engine
import matlab
import numpy as np
import PIL
import matplotlib.pyplot as plt
import sys
print(sys.version_info[0:2])
if sys.version_info[0:2] != (3, 8) and sys.version_info[0:2] != (3, 7) and sys.version_info[0:2] != (3, 6):
raise Exception('Requires python 3.6, 3.7, or 3.8')
eng = matlab.eng... | 32.274194 | 132 | 0.66067 |
57ef2758e6f78fd8c86e719186446c008e2338ee | 6,642 | py | Python | chess-ai-master/game/rules.py | explodicus/intelliSah | acbec81a58292b788e2c7c0c7ea1ea04572a072f | [
"MIT"
] | null | null | null | chess-ai-master/game/rules.py | explodicus/intelliSah | acbec81a58292b788e2c7c0c7ea1ea04572a072f | [
"MIT"
] | null | null | null | chess-ai-master/game/rules.py | explodicus/intelliSah | acbec81a58292b788e2c7c0c7ea1ea04572a072f | [
"MIT"
] | null | null | null | from collections import defaultdict
import pieces | 29.651786 | 113 | 0.546372 |
57f2007543d3878ef0bed9620dac66d11e435984 | 178 | py | Python | eyed/rpc/bacnetd/__init__.py | ThousandMileEye/Eye | b0eca371fed5e01353ebddf7e4c400927decf0d2 | [
"Apache-2.0"
] | null | null | null | eyed/rpc/bacnetd/__init__.py | ThousandMileEye/Eye | b0eca371fed5e01353ebddf7e4c400927decf0d2 | [
"Apache-2.0"
] | 55 | 2017-12-21T15:20:36.000Z | 2019-01-20T02:49:41.000Z | eyed/rpc/bacnetd/__init__.py | ThousandMileEye/Eye | b0eca371fed5e01353ebddf7e4c400927decf0d2 | [
"Apache-2.0"
] | 3 | 2018-05-18T09:02:36.000Z | 2019-12-29T10:27:44.000Z | #!/usr/bin/env python
# -*- coding: utf-8 -*-
from bacnetd import SingleBACnetdService
from bacnetd import BACnetdService
__all__ = [
SingleBACnetdService,
BACnetdService,
]
| 16.181818 | 40 | 0.752809 |
57f2ae3f2e4e218865d07977bbf3e1de0603e097 | 2,280 | py | Python | gotham.py | amirothman/audio-visualization | 3a5efe97a1d98de06e84296f97081cd2d74fe9e2 | [
"MIT"
] | null | null | null | gotham.py | amirothman/audio-visualization | 3a5efe97a1d98de06e84296f97081cd2d74fe9e2 | [
"MIT"
] | null | null | null | gotham.py | amirothman/audio-visualization | 3a5efe97a1d98de06e84296f97081cd2d74fe9e2 | [
"MIT"
] | null | null | null | from skimage.util import img_as_float
from skimage import io, filters
# from skimage.viewer import ImageViewer
import numpy as np
def split_image_into_channels(image):
"""Look at each image separately"""
red_channel = image[:, :, 0]
green_channel = image[:, :, 1]
blue_channel = image[:, :, 2]
ret... | 30 | 78 | 0.705263 |
57f6365978e8a716c23c881a108a840cc548fa4a | 2,116 | py | Python | backend/backend/integration_utils.py | kaipietila/CookOS | b28f91cf5a750303a27e2e4589ea5a6ed271d295 | [
"MIT"
] | null | null | null | backend/backend/integration_utils.py | kaipietila/CookOS | b28f91cf5a750303a27e2e4589ea5a6ed271d295 | [
"MIT"
] | null | null | null | backend/backend/integration_utils.py | kaipietila/CookOS | b28f91cf5a750303a27e2e4589ea5a6ed271d295 | [
"MIT"
] | null | null | null | from datetime import datetime
from backend.backend.classes_main import Order, OrderItemStateUpdate, OrderUpdate, StatusHistory
from backend.backend.exceptions import NoOrderFoundException
from backend.backend.repository import get_order_by_id, update_items, update_order_status, get_orders, create_order
from backend.ba... | 40.692308 | 115 | 0.778828 |
57f817e2249400abb14e5d1810b119046f3d3c71 | 425 | py | Python | 17b.py | znuxor/adventofcode2017 | 79d0df07f24ea8d2793df3b1c853a85b760791c1 | [
"BSD-3-Clause"
] | null | null | null | 17b.py | znuxor/adventofcode2017 | 79d0df07f24ea8d2793df3b1c853a85b760791c1 | [
"BSD-3-Clause"
] | null | null | null | 17b.py | znuxor/adventofcode2017 | 79d0df07f24ea8d2793df3b1c853a85b760791c1 | [
"BSD-3-Clause"
] | null | null | null | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
from collections import deque
puzzle_input = 377
# puzzle_input = 3
my_circular_buffer = deque()
my_circular_buffer.append(0)
for i in range(1, 50000000+1):
new_pos = puzzle_input % len(my_circular_buffer)
my_circular_buffer.rotate(-new_pos-1)
my_circular_b... | 23.611111 | 55 | 0.757647 |
57fba0e21b454e1612fd2ab00c1169a35e150463 | 1,524 | py | Python | aiobotocore/configprovider.py | vemel/aiobotocore | b7726a4c45b6cdc0a8bf679191ce9c31eb7bd167 | [
"Apache-2.0"
] | null | null | null | aiobotocore/configprovider.py | vemel/aiobotocore | b7726a4c45b6cdc0a8bf679191ce9c31eb7bd167 | [
"Apache-2.0"
] | null | null | null | aiobotocore/configprovider.py | vemel/aiobotocore | b7726a4c45b6cdc0a8bf679191ce9c31eb7bd167 | [
"Apache-2.0"
] | null | null | null | from botocore.configprovider import os, SmartDefaultsConfigStoreFactory
| 40.105263 | 82 | 0.621391 |
57fbd59102d12bea08762357826a983d63184e28 | 3,302 | py | Python | modulemd/tests/ModulemdTests/module.py | val-verde/libmodulemd | 1a032da198333ee77bdbe4be65e60eb4115ea73f | [
"MIT"
] | 28 | 2017-12-07T11:42:21.000Z | 2021-09-20T17:34:40.000Z | modulemd/tests/ModulemdTests/module.py | val-verde/libmodulemd | 1a032da198333ee77bdbe4be65e60eb4115ea73f | [
"MIT"
] | 413 | 2018-01-05T15:53:01.000Z | 2022-03-31T11:45:52.000Z | modulemd/tests/ModulemdTests/module.py | val-verde/libmodulemd | 1a032da198333ee77bdbe4be65e60eb4115ea73f | [
"MIT"
] | 72 | 2018-01-15T13:38:34.000Z | 2022-03-15T06:08:27.000Z | #!/usr/bin/python3
# This file is part of libmodulemd
# Copyright (C) 2017-2018 Stephen Gallagher
#
# Fedora-License-Identifier: MIT
# SPDX-2.0-License-Identifier: MIT
# SPDX-3.0-License-Identifier: MIT
#
# This program is free software.
# For more information on the license, see COPYING.
# For more information on fre... | 27.747899 | 79 | 0.650212 |
57fc26e3bdf52a1c99cfa051147497ae4c466ad2 | 2,268 | py | Python | tests/stress/conftest.py | lolyu/sonic-mgmt | ed888fd1ce26e7f44fd7f70af00c43ace4882668 | [
"Apache-2.0"
] | 132 | 2016-10-19T12:34:44.000Z | 2022-03-16T09:00:39.000Z | tests/stress/conftest.py | lolyu/sonic-mgmt | ed888fd1ce26e7f44fd7f70af00c43ace4882668 | [
"Apache-2.0"
] | 3,152 | 2016-09-21T23:05:58.000Z | 2022-03-31T23:29:08.000Z | tests/stress/conftest.py | lolyu/sonic-mgmt | ed888fd1ce26e7f44fd7f70af00c43ace4882668 | [
"Apache-2.0"
] | 563 | 2016-09-20T01:00:15.000Z | 2022-03-31T22:43:54.000Z | import logging
import pytest
from tests.common.utilities import wait_until
from utils import get_crm_resources, check_queue_status, sleep_to_wait
CRM_POLLING_INTERVAL = 1
CRM_DEFAULT_POLL_INTERVAL = 300
MAX_WAIT_TIME = 120
logger = logging.getLogger(__name__)
| 39.103448 | 107 | 0.761023 |
57fc5340cf68c5714f41b1dafe33f998bca42b55 | 7,991 | py | Python | mamonsu/lib/zbx_template.py | dan-aksenov/mamonsu | c4822b48974e870af91910515fd7f11e4b8b41b3 | [
"BSD-3-Clause"
] | null | null | null | mamonsu/lib/zbx_template.py | dan-aksenov/mamonsu | c4822b48974e870af91910515fd7f11e4b8b41b3 | [
"BSD-3-Clause"
] | null | null | null | mamonsu/lib/zbx_template.py | dan-aksenov/mamonsu | c4822b48974e870af91910515fd7f11e4b8b41b3 | [
"BSD-3-Clause"
] | null | null | null | # -*- coding: utf-8 -*-
from mamonsu.lib.const import Template
| 37.167442 | 79 | 0.541359 |
17a84420e19ce12f3b716bc7024aa29937242930 | 1,164 | py | Python | src/rhasspy_desktop_satellite/exceptions.py | mcorino/rhasspy-desktop-satellite | aeaa820a0acdcc2e70db1f74157a0c7d3ac5d4bd | [
"MIT"
] | null | null | null | src/rhasspy_desktop_satellite/exceptions.py | mcorino/rhasspy-desktop-satellite | aeaa820a0acdcc2e70db1f74157a0c7d3ac5d4bd | [
"MIT"
] | null | null | null | src/rhasspy_desktop_satellite/exceptions.py | mcorino/rhasspy-desktop-satellite | aeaa820a0acdcc2e70db1f74157a0c7d3ac5d4bd | [
"MIT"
] | null | null | null | """This module contains exceptions defined for Rhasspy Desktop Satellite."""
| 33.257143 | 79 | 0.726804 |
17a9215dd525fc26ed3417c0d32824c0c0045586 | 1,084 | py | Python | KMeans.py | trinity652/Skin-Cancer-Classification | 257be485b84077440be77cf14b5e40d9a6765f94 | [
"MIT"
] | 16 | 2018-01-23T12:20:04.000Z | 2021-11-05T10:01:20.000Z | KMeans.py | trinity652/Skin-Cancer-Classification | 257be485b84077440be77cf14b5e40d9a6765f94 | [
"MIT"
] | null | null | null | KMeans.py | trinity652/Skin-Cancer-Classification | 257be485b84077440be77cf14b5e40d9a6765f94 | [
"MIT"
] | 1 | 2020-11-29T09:29:27.000Z | 2020-11-29T09:29:27.000Z | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Mon Oct 30 17:48:49 2017
@author: abhilasha
Using SKLearns API for performing Kmeans clustering.
Using sklearn.datasets.make_blobs for generating randomized gaussians
for clustering.
"""
import numpy as np
from matplotlib import pyplot as plt
from skle... | 22.583333 | 81 | 0.725092 |
17a967eb21d3033ca6492eedc8fc39e1742110e2 | 1,388 | py | Python | test/unit/test_classical_explainer.py | tomdyer10/interpret-text | 0c56fb645de882e31f0623afdb949d3b8f9c6aad | [
"MIT"
] | 1 | 2020-08-28T05:13:22.000Z | 2020-08-28T05:13:22.000Z | test/unit/test_classical_explainer.py | nehalecky/interpret-text | 62a5e7406bf5c7d2df69648a278082d602e88dd6 | [
"MIT"
] | null | null | null | test/unit/test_classical_explainer.py | nehalecky/interpret-text | 62a5e7406bf5c7d2df69648a278082d602e88dd6 | [
"MIT"
] | null | null | null | # ---------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# ---------------------------------------------------------
# Tests for classical explainer
from interpret_text.experimental.classical import ClassicalTextExplainer
from sklearn.model_selection impor... | 38.555556 | 106 | 0.672911 |
17a96a19e673a02ce4216b998f3cb8431e172a1f | 1,378 | py | Python | create_python_app/main.py | xuchaoqian/create-python-app | 70745432b972b96a3faf95a378d54d922b77f2be | [
"MIT"
] | null | null | null | create_python_app/main.py | xuchaoqian/create-python-app | 70745432b972b96a3faf95a378d54d922b77f2be | [
"MIT"
] | null | null | null | create_python_app/main.py | xuchaoqian/create-python-app | 70745432b972b96a3faf95a378d54d922b77f2be | [
"MIT"
] | null | null | null | import argparse
from create_python_app.path_utils import *
from create_python_app.create_gitignore_file import create_gitignore_file
from create_python_app.create_license_file import create_license_file
from create_python_app.create_makefile_file import create_makefile_file
from create_python_app.create_readme_file imp... | 41.757576 | 79 | 0.834543 |
17ab540dcdbf37fd31ad32aaf93a82fb1d9028a9 | 1,113 | py | Python | Lexical Analyzer.py | amitnandi04/Compiler_Construction | d9e18735b74fdacab76ed892a9b8fb3ae50c49ce | [
"Unlicense"
] | null | null | null | Lexical Analyzer.py | amitnandi04/Compiler_Construction | d9e18735b74fdacab76ed892a9b8fb3ae50c49ce | [
"Unlicense"
] | null | null | null | Lexical Analyzer.py | amitnandi04/Compiler_Construction | d9e18735b74fdacab76ed892a9b8fb3ae50c49ce | [
"Unlicense"
] | null | null | null | # Lexical Analyzer
import re # for performing regex expressions
tokens = [] # for string tokens
source_code = 'int result = 100;'.split() # turning source code into list of words
# Loop through each source code word
for word in source_code:
... | 35.903226 | 83 | 0.554358 |
17ac5c168ff8f7e5043d020dc537567d52acfba3 | 5,114 | py | Python | user.py | genba2/pinybotbeta-enhanced | 564ae7c363ee00ad2ae0e05d74e08e58de3d1d2f | [
"MIT"
] | null | null | null | user.py | genba2/pinybotbeta-enhanced | 564ae7c363ee00ad2ae0e05d74e08e58de3d1d2f | [
"MIT"
] | null | null | null | user.py | genba2/pinybotbeta-enhanced | 564ae7c363ee00ad2ae0e05d74e08e58de3d1d2f | [
"MIT"
] | null | null | null | import time
def add(self, user_info):
"""
Add a user to the users dict.
:param user_info dict, tinychat user info.
:return user info object (User)
"""
if user_info['nick'] not in self.all:
self._users[user_info['nick']] = User(**user_info)
retur... | 30.082353 | 113 | 0.553969 |
17afc776c10c0b9ba372d9ed2ac769c202c71e90 | 2,696 | py | Python | my_python_module/exceptions.py | a358003542/wanze_python_project | db52515af80319000e9a47a7b02f3ccd2cf46afd | [
"MIT"
] | 1 | 2020-10-30T08:54:22.000Z | 2020-10-30T08:54:22.000Z | my_python_module/exceptions.py | a358003542/wanze_python_project | db52515af80319000e9a47a7b02f3ccd2cf46afd | [
"MIT"
] | null | null | null | my_python_module/exceptions.py | a358003542/wanze_python_project | db52515af80319000e9a47a7b02f3ccd2cf46afd | [
"MIT"
] | null | null | null | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
python
+-- Exception
+-- StopIteration
+-- StopAsyncIteration
+-- ArithmeticError
| +-- FloatingPointError
| +-- OverflowError
| +-- ZeroDivisionError
+-- AssertionError
+-- AttributeError
+-- BufferError
... | 23.858407 | 80 | 0.554154 |
17b1221ef72aae7747a03fca3ca613968d0d4959 | 3,386 | py | Python | catbridge_tools/isbn_tools.py | victoriamorris/CatBridge | a91164f85ffcb93eb17c786d4a178a559242f7c9 | [
"MIT"
] | null | null | null | catbridge_tools/isbn_tools.py | victoriamorris/CatBridge | a91164f85ffcb93eb17c786d4a178a559242f7c9 | [
"MIT"
] | null | null | null | catbridge_tools/isbn_tools.py | victoriamorris/CatBridge | a91164f85ffcb93eb17c786d4a178a559242f7c9 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# ====================
# Set-up
# ====================
# Import required modules
import re
__author__ = 'Victoria Morris'
__license__ = 'MIT License'
__version__ = '1.0.0'
__status__ = '4 - Beta Development'
# ====================
# Regular ex... | 27.754098 | 105 | 0.533077 |
17b21b596279e3ab02d31a65bd2b5613da788991 | 1,334 | py | Python | tests/test_shows_tab.py | andrsd/podcastista | c05a1de09d2820899aebe592d3d4b01d64d1e5fe | [
"MIT"
] | null | null | null | tests/test_shows_tab.py | andrsd/podcastista | c05a1de09d2820899aebe592d3d4b01d64d1e5fe | [
"MIT"
] | 17 | 2021-09-22T12:21:46.000Z | 2022-02-26T12:26:40.000Z | tests/test_shows_tab.py | andrsd/podcastista | c05a1de09d2820899aebe592d3d4b01d64d1e5fe | [
"MIT"
] | null | null | null | import platform
import pytest
from unittest.mock import MagicMock
from PyQt5 import QtWidgets
if platform.system() == "Darwin":
| 25.169811 | 57 | 0.530735 |
17b2749503c2c092f3b9104e3fd3d23979721585 | 1,999 | py | Python | Solver.py | ANewDeviloper/Rubiks-Simulator | 31d06e4b5415ccf754ec91bcdd5c755e2e355d86 | [
"MIT"
] | null | null | null | Solver.py | ANewDeviloper/Rubiks-Simulator | 31d06e4b5415ccf754ec91bcdd5c755e2e355d86 | [
"MIT"
] | null | null | null | Solver.py | ANewDeviloper/Rubiks-Simulator | 31d06e4b5415ccf754ec91bcdd5c755e2e355d86 | [
"MIT"
] | null | null | null | # -*- coding: utf8 -*-
import CubeModel
methodIDs = {1 : "TLPU", 2 : "TLPD", 3 : "TVMPU", 4 : "TVMPD", 5 : "TRPU", 6 : "TRPD",
7 : "TFPR", 8 : "TFPL", 9 : "TOMPR", 10 : "TOMPL", 11 : "TBPR", 12 : "TBPL",
13 : "TUPR", 14 : "TUPL", 15 : "THMPR", 16 : "THMPL", 17... | 31.730159 | 116 | 0.50025 |
17b41cbaf511e453fc40d63d8ba1e2b7897da14a | 3,494 | py | Python | tests/python/contrib/test_ethosu/cascader/test_ethosu_conv2d_matcher.py | LEA0317/incubator-tvm | de21c8f2ef507587fdcc99b851404de5aeeb5a16 | [
"Apache-2.0"
] | 90 | 2021-11-30T11:58:10.000Z | 2022-03-31T02:24:04.000Z | tests/python/contrib/test_ethosu/cascader/test_ethosu_conv2d_matcher.py | LEA0317/incubator-tvm | de21c8f2ef507587fdcc99b851404de5aeeb5a16 | [
"Apache-2.0"
] | 64 | 2021-11-22T23:58:23.000Z | 2022-03-31T03:19:22.000Z | tests/python/contrib/test_ethosu/cascader/test_ethosu_conv2d_matcher.py | LEA0317/incubator-tvm | de21c8f2ef507587fdcc99b851404de5aeeb5a16 | [
"Apache-2.0"
] | 27 | 2021-12-09T22:39:27.000Z | 2022-03-24T23:21:48.000Z | # Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not u... | 33.92233 | 95 | 0.670864 |
17b4c6a525923c76105b1e66c532efc33cd33653 | 23 | py | Python | __init__.py | mendhak/aws-elb-logster | 4122f03fd3977225269190fff60fd5d7935ddeaf | [
"MIT"
] | 2 | 2015-09-14T22:16:52.000Z | 2016-04-11T17:08:32.000Z | __init__.py | mendhak/aws-elb-logster | 4122f03fd3977225269190fff60fd5d7935ddeaf | [
"MIT"
] | null | null | null | __init__.py | mendhak/aws-elb-logster | 4122f03fd3977225269190fff60fd5d7935ddeaf | [
"MIT"
] | null | null | null | #
# Python init file
#
| 5.75 | 18 | 0.608696 |
17b5611d8bfcc949adaf08263c632359cd3eeee4 | 1,925 | py | Python | tests/testing_support/validators/validate_serverless_payload.py | newrelic/newrelic-python-agen | 4f292ec1219c0daffc5721a7b3a245b97d0f83ba | [
"Apache-2.0"
] | 92 | 2020-06-12T17:53:23.000Z | 2022-03-01T11:13:21.000Z | tests/testing_support/validators/validate_serverless_payload.py | newrelic/newrelic-python-agen | 4f292ec1219c0daffc5721a7b3a245b97d0f83ba | [
"Apache-2.0"
] | 347 | 2020-07-10T00:10:19.000Z | 2022-03-31T17:58:56.000Z | tests/testing_support/validators/validate_serverless_payload.py | newrelic/newrelic-python-agen | 4f292ec1219c0daffc5721a7b3a245b97d0f83ba | [
"Apache-2.0"
] | 58 | 2020-06-17T13:51:57.000Z | 2022-03-06T14:26:53.000Z | # Copyright 2010 New Relic, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writ... | 32.627119 | 74 | 0.648831 |
17b5722e5e60de2426f1160b8b162178106fdd0c | 890 | py | Python | kakao_message_utils/request_token.py | hahagarden/project_news_summarize | 1c47e2ec30cff715a0c56b20f50a9ffa53ded274 | [
"MIT"
] | null | null | null | kakao_message_utils/request_token.py | hahagarden/project_news_summarize | 1c47e2ec30cff715a0c56b20f50a9ffa53ded274 | [
"MIT"
] | null | null | null | kakao_message_utils/request_token.py | hahagarden/project_news_summarize | 1c47e2ec30cff715a0c56b20f50a9ffa53ded274 | [
"MIT"
] | null | null | null | import token_def
# To get Authorization Code
# https://kauth.kakao.com/oauth/authorize?client_id=cc335daa766cc74b3de1b1c372a6cce8&response_type=code&redirect_uri=https://localhost.com
KAKAO_APP_KEY = "cc335daa766cc74b3de1b1c372a6cce8" # REST_API app key
AUTHORIZATION_CODE = "flzXSvhelQ3LLzmAKyo5-bQsafEyGOyFAMyK4N-dT... | 46.842105 | 138 | 0.830337 |
17b8f007031e6b77982d4da9880cd3ac7fe940b3 | 1,717 | py | Python | test/unit/messages/bloxroute/test_abstract_bloxroute_message.py | dolphinridercrypto/bxcommon | 8f70557c1dbff785a5dd3fcdf91176066e085c3a | [
"MIT"
] | 12 | 2019-11-06T17:39:10.000Z | 2022-03-01T11:26:19.000Z | test/unit/messages/bloxroute/test_abstract_bloxroute_message.py | dolphinridercrypto/bxcommon | 8f70557c1dbff785a5dd3fcdf91176066e085c3a | [
"MIT"
] | 8 | 2019-11-06T21:31:11.000Z | 2021-06-02T00:46:50.000Z | test/unit/messages/bloxroute/test_abstract_bloxroute_message.py | dolphinridercrypto/bxcommon | 8f70557c1dbff785a5dd3fcdf91176066e085c3a | [
"MIT"
] | 5 | 2019-11-14T18:08:11.000Z | 2022-02-08T09:36:22.000Z | from bxcommon.test_utils.abstract_test_case import AbstractTestCase
from bxcommon import constants
from bxcommon.messages.bloxroute.abstract_bloxroute_message import AbstractBloxrouteMessage
from bxcommon.messages.bloxroute.bloxroute_message_control_flags import BloxrouteMessageControlFlags
| 50.5 | 121 | 0.798486 |
17bab85be9766c1e62d10b8ba5e92bbbc7204442 | 1,139 | py | Python | test/python/LIM2Metrics/py3/base/common/Bridge/Bridge.py | sagodiz/SonarQube-plug-in | 4f8e111baecc4c9f9eaa5cd3d7ebeb1e365ace2c | [
"BSD-4-Clause"
] | 20 | 2015-06-16T17:39:10.000Z | 2022-03-20T22:39:40.000Z | test/python/LIM2Metrics/py3/base/common/Bridge/Bridge.py | sagodiz/SonarQube-plug-in | 4f8e111baecc4c9f9eaa5cd3d7ebeb1e365ace2c | [
"BSD-4-Clause"
] | 29 | 2015-12-29T19:07:22.000Z | 2022-03-22T10:39:02.000Z | test/python/LIM2Metrics/py3/base/common/Bridge/Bridge.py | sagodiz/SonarQube-plug-in | 4f8e111baecc4c9f9eaa5cd3d7ebeb1e365ace2c | [
"BSD-4-Clause"
] | 12 | 2015-08-28T01:22:18.000Z | 2021-09-25T08:17:31.000Z | # Implementor
# ConcreteImplementor 1/2
# ConcreteImplementor 2/2
# Abstraction
# Refined Abstraction
# Client
if __name__ == '__main__':
shapes = [
CircleShape(1, 2, 3, drawing_api1()),
CircleShape(5, 7, 11, drawing_api2())
]
for shape in shapes:
shape.resize_by_percenta... | 23.729167 | 65 | 0.62072 |
17bb9ce8b0c4820397f46ae9b7245ef217260243 | 6,162 | py | Python | server/main.py | priyanshujha98/leilaportal | 2f4f51173b0186b07e4c14fc06a2ecc715cf7eb7 | [
"MIT"
] | null | null | null | server/main.py | priyanshujha98/leilaportal | 2f4f51173b0186b07e4c14fc06a2ecc715cf7eb7 | [
"MIT"
] | null | null | null | server/main.py | priyanshujha98/leilaportal | 2f4f51173b0186b07e4c14fc06a2ecc715cf7eb7 | [
"MIT"
] | null | null | null | #! /usr/bin/env python3.6
"""
server.py
Stripe Sample.
Python 3.6 or newer required.
"""
import stripe
import json
import os
import requests
#flask
from flask import Flask, render_template, jsonify, request, send_from_directory, session, Session
from flask_session import Session
from dotenv import load_dotenv, find... | 34.617978 | 182 | 0.636644 |
17bc3e483fd3d3f977cf7a9dcbaef4c2331e4edd | 3,992 | py | Python | src/synthesize_predictions.py | bluetyson/concept-tagging-training | 449388748155a8f2e398d24d750e5d3871f8e75d | [
"MIT"
] | 10 | 2020-06-21T04:30:05.000Z | 2022-01-10T01:24:58.000Z | src/synthesize_predictions.py | bluetyson/concept-tagging-training | 449388748155a8f2e398d24d750e5d3871f8e75d | [
"MIT"
] | 4 | 2020-06-30T03:47:23.000Z | 2021-07-12T19:33:52.000Z | src/synthesize_predictions.py | bluetyson/concept-tagging-training | 449388748155a8f2e398d24d750e5d3871f8e75d | [
"MIT"
] | 8 | 2020-06-19T13:24:47.000Z | 2021-09-13T02:09:21.000Z | import argparse
import logging
from pathlib import Path
import dask
import h5py
import joblib
import numpy as np
import pandas as pd
from dask.diagnostics import ProgressBar
from tqdm import tqdm
from dsconcept.get_metrics import (
get_cat_inds,
get_synth_preds,
load_category_models,
load_concept_mode... | 31.1875 | 86 | 0.661072 |
17c267cdf68b5d5312402448c8870bbe5e04350c | 3,543 | py | Python | service/resources/appointment_offer.py | SFDigitalServices/otc_appointments | 62627deafa123e0bc0df367441f3c202c3176b3e | [
"MIT"
] | null | null | null | service/resources/appointment_offer.py | SFDigitalServices/otc_appointments | 62627deafa123e0bc0df367441f3c202c3176b3e | [
"MIT"
] | null | null | null | service/resources/appointment_offer.py | SFDigitalServices/otc_appointments | 62627deafa123e0bc0df367441f3c202c3176b3e | [
"MIT"
] | null | null | null | """Email module"""
#pylint: disable=too-few-public-methods
import json
import os
import falcon
import requests
from mako.template import Template
import sendgrid
from sendgrid.helpers.mail import Email, To, Content, Mail
from .hooks import validate_access
FROM_EMAIL = "no-reply@sf.gov"
SUBJECT = "Appointment Offering"... | 36.153061 | 96 | 0.65199 |
17c5134f523338eb38c2be750ed00943cad1dc8d | 34 | py | Python | matfactor/__init__.py | Joshua-Chin/matfactor | 6730ca7ddb7844d9d50f7e5725f5ccdaae31721b | [
"Apache-2.0"
] | 1 | 2018-02-13T02:55:16.000Z | 2018-02-13T02:55:16.000Z | matfactor/__init__.py | Joshua-Chin/matfactor | 6730ca7ddb7844d9d50f7e5725f5ccdaae31721b | [
"Apache-2.0"
] | null | null | null | matfactor/__init__.py | Joshua-Chin/matfactor | 6730ca7ddb7844d9d50f7e5725f5ccdaae31721b | [
"Apache-2.0"
] | null | null | null | from ._factorize import factorize
| 17 | 33 | 0.852941 |
17c5738139be0ff3cd10e6b345ccee28c0202628 | 752 | py | Python | C++/1059-All-Paths-from-Source-Lead-to-Destination/soln-1.py | wyaadarsh/LeetCode-Solutions | 3719f5cb059eefd66b83eb8ae990652f4b7fd124 | [
"MIT"
] | 5 | 2020-07-24T17:48:59.000Z | 2020-12-21T05:56:00.000Z | C++/1059-All-Paths-from-Source-Lead-to-Destination/soln-1.py | zhangyaqi1989/LeetCode-Solutions | 2655a1ffc8678ad1de6c24295071308a18c5dc6e | [
"MIT"
] | null | null | null | C++/1059-All-Paths-from-Source-Lead-to-Destination/soln-1.py | zhangyaqi1989/LeetCode-Solutions | 2655a1ffc8678ad1de6c24295071308a18c5dc6e | [
"MIT"
] | 2 | 2020-07-24T17:49:01.000Z | 2020-08-31T19:57:35.000Z | }
vector<bool> visited(n, false);
return dfs(source, destination, visited);
}
private:
bool dfs(int node, int target, vector<bool> & visited) {
if (graph.find(node) == graph.end()) return node == target;
visited[node] = true;
for (int nei : graph[node]) {
... | 30.08 | 93 | 0.542553 |
17c67804477d49c14190bfb741a72b7035d9286c | 767 | py | Python | docs/source/renderers/chart_renderer_example.py | steveblamey/django-report-tools | e12fe737a372925c7ce4969ed6e754d51cd9853b | [
"BSD-2-Clause"
] | 33 | 2015-01-30T18:02:10.000Z | 2020-06-11T18:45:08.000Z | docs/source/renderers/chart_renderer_example.py | steveblamey/django-report-tools | e12fe737a372925c7ce4969ed6e754d51cd9853b | [
"BSD-2-Clause"
] | 4 | 2015-01-29T21:00:22.000Z | 2021-06-10T17:40:08.000Z | docs/source/renderers/chart_renderer_example.py | steveblamey/django-report-tools | e12fe737a372925c7ce4969ed6e754d51cd9853b | [
"BSD-2-Clause"
] | 14 | 2015-04-13T10:34:35.000Z | 2020-08-16T18:02:04.000Z | from report_tools.renderers import ChartRenderer
| 40.368421 | 79 | 0.705346 |
17c77bdbbbefa5f7c703943e14d06b6e268f555c | 2,849 | py | Python | app.py | lwalkk/truck-website | 81035dfa7ffdafdea162838dfaf82d0a44d2cf16 | [
"MIT"
] | null | null | null | app.py | lwalkk/truck-website | 81035dfa7ffdafdea162838dfaf82d0a44d2cf16 | [
"MIT"
] | null | null | null | app.py | lwalkk/truck-website | 81035dfa7ffdafdea162838dfaf82d0a44d2cf16 | [
"MIT"
] | null | null | null | from flask import Flask, request
from flask import render_template
from flask_mysqldb import MySQL
import TimeCalc
from datetime import datetime, timedelta
app = Flask(__name__)
app.config['MYSQL_USER'] = 'root'
app.config['MYSQL_PASSWORD'] = 'password'
app.config['MYSQL_HOST'] = 'localhost'
app.config['MYSQL_DB'] = '... | 27.133333 | 109 | 0.557389 |
17c9aa0e7487d9e67e8f56273b862ff651c5d62b | 233 | py | Python | test/test_children_tree.py | kisliakovsky/structures | 19969470a7e9b150b077082cc8ca0c2fc9be279e | [
"MIT"
] | null | null | null | test/test_children_tree.py | kisliakovsky/structures | 19969470a7e9b150b077082cc8ca0c2fc9be279e | [
"MIT"
] | null | null | null | test/test_children_tree.py | kisliakovsky/structures | 19969470a7e9b150b077082cc8ca0c2fc9be279e | [
"MIT"
] | null | null | null | from unittest import TestCase
from src.tree import ChildrenTree
| 21.181818 | 60 | 0.639485 |
17cb214bdeac8ea001ea137df86d94fab66b5a09 | 5,183 | py | Python | conanfile.py | bincrafters/conan-gtk | bf8056df1294c0b6d894fddf71f8cf6531212aea | [
"MIT"
] | null | null | null | conanfile.py | bincrafters/conan-gtk | bf8056df1294c0b6d894fddf71f8cf6531212aea | [
"MIT"
] | null | null | null | conanfile.py | bincrafters/conan-gtk | bf8056df1294c0b6d894fddf71f8cf6531212aea | [
"MIT"
] | 1 | 2021-09-22T19:02:25.000Z | 2021-09-22T19:02:25.000Z | from conans import ConanFile, Meson, tools
from conans.errors import ConanInvalidConfiguration
import os
| 40.492188 | 159 | 0.612001 |
17cb5a4e5e188e8afd6b4471951035dcebbec25c | 1,346 | py | Python | Testcase11-Real-world-app-emulation/trace-gen/src/generateActionIATMapping.py | sangroad/ServerlessBench | 5cddf6c7969319c2b02c608bc3866fd781d1417e | [
"MulanPSL-1.0"
] | null | null | null | Testcase11-Real-world-app-emulation/trace-gen/src/generateActionIATMapping.py | sangroad/ServerlessBench | 5cddf6c7969319c2b02c608bc3866fd781d1417e | [
"MulanPSL-1.0"
] | null | null | null | Testcase11-Real-world-app-emulation/trace-gen/src/generateActionIATMapping.py | sangroad/ServerlessBench | 5cddf6c7969319c2b02c608bc3866fd781d1417e | [
"MulanPSL-1.0"
] | null | null | null | # this file is for debug
import os
import yaml
SECONDS_OF_A_DAY = 3600*24
MILLISECONDS_PER_SEC = 1000
config = yaml.load(open(os.path.join(os.path.dirname(__file__),'config.yaml')), yaml.FullLoader)
SAMPLE_NUM = config['sample_number']
workloadDir = "../CSVs/%i" % SAMPLE_NUM
if __name__ == '__main__':
generateActio... | 28.638298 | 96 | 0.647845 |
17cb6e924dabd28d65570136329686d987bc7e4b | 1,047 | py | Python | electronics/ltspice/rc_lowpass/calc.py | qeedquan/misc_utilities | 94c6363388662ac8ebbf075b9c853ce6defbb5b3 | [
"MIT"
] | 8 | 2018-10-17T18:17:25.000Z | 2022-03-18T09:02:53.000Z | electronics/ltspice/rc_lowpass/calc.py | qeedquan/misc_utilities | 94c6363388662ac8ebbf075b9c853ce6defbb5b3 | [
"MIT"
] | null | null | null | electronics/ltspice/rc_lowpass/calc.py | qeedquan/misc_utilities | 94c6363388662ac8ebbf075b9c853ce6defbb5b3 | [
"MIT"
] | 3 | 2020-07-01T13:52:42.000Z | 2022-03-18T09:10:59.000Z | #!/usr/bin/env python
# http://sim.okawa-denshi.jp/en/CRtool.php
# A RC circuit can act as a low pass filter when fed different AC frequencies if we hook
# them up in a serial way
# We can calculate various values of the filters using the formulas below
from math import *
# p = 1/RC
# p / (s + p)
print_risetimes()
... | 24.348837 | 105 | 0.598854 |
17cbb18aa49b9a42e1ad5b10fe3c95f49bc72cb1 | 4,860 | py | Python | apps/log_search/tasks/mapping.py | kiritoscs/bk-log | 4801b14182ba7cb108d968cd4f33668ee2d16dbc | [
"MIT"
] | null | null | null | apps/log_search/tasks/mapping.py | kiritoscs/bk-log | 4801b14182ba7cb108d968cd4f33668ee2d16dbc | [
"MIT"
] | null | null | null | apps/log_search/tasks/mapping.py | kiritoscs/bk-log | 4801b14182ba7cb108d968cd4f33668ee2d16dbc | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
"""
Tencent is pleased to support the open source community by making BK-LOG available.
Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
BK-LOG is licensed under the MIT License.
License for BK-LOG :
------------------------------------------------------------------... | 50.625 | 117 | 0.734156 |
17ce1ca456408cd57b564d3fa90a6dbc05eaed30 | 13,700 | py | Python | eliza.py | lucasmelin/eliza | 878ea25f833ccd1cc439ead01c786c920b9bd078 | [
"MIT"
] | null | null | null | eliza.py | lucasmelin/eliza | 878ea25f833ccd1cc439ead01c786c920b9bd078 | [
"MIT"
] | null | null | null | eliza.py | lucasmelin/eliza | 878ea25f833ccd1cc439ead01c786c920b9bd078 | [
"MIT"
] | null | null | null | # https://sites.google.com/view/elizagen-org/the-original-eliza
from dataclasses import dataclass
from typing import List, Pattern
import re
import random
from rich.console import Console
from rich.panel import Panel
from time import sleep
subject = {
"am": "are",
"was": "were",
"i": "you",
"i'd": "y... | 30.37694 | 154 | 0.480803 |
17cf03e398e39d203c9ebbce60b6f35bd144eb35 | 5,110 | py | Python | aws_artifact_copy/services/ecr.py | schlarpc/aws-artifact-copy | cd8a57db3f6e4636dc6f18b3f5b9534c907f9371 | [
"MIT"
] | null | null | null | aws_artifact_copy/services/ecr.py | schlarpc/aws-artifact-copy | cd8a57db3f6e4636dc6f18b3f5b9534c907f9371 | [
"MIT"
] | null | null | null | aws_artifact_copy/services/ecr.py | schlarpc/aws-artifact-copy | cd8a57db3f6e4636dc6f18b3f5b9534c907f9371 | [
"MIT"
] | null | null | null | import argparse
import hashlib
import json
import os
import sys
import tarfile
import trio
from ..common.botocore import (
create_async_session,
create_async_client,
partial_client_methods,
)
from ..common.serialization import json_dumps_canonical
def parse_original_manifest(stream):
manifest = js... | 35 | 88 | 0.553816 |
17cfb7def19232ffc27b0f1860e91472d28ccd63 | 186 | py | Python | iniciante/1132.py | samucosta13/URI-Online-Judge | d3dc0c4c3ccf260e02cb3705a11226cbddffb90b | [
"MIT"
] | 2 | 2021-05-28T18:52:53.000Z | 2021-06-04T19:30:39.000Z | iniciante/1132.py | samucosta13/URI-Online-Judge | d3dc0c4c3ccf260e02cb3705a11226cbddffb90b | [
"MIT"
] | null | null | null | iniciante/1132.py | samucosta13/URI-Online-Judge | d3dc0c4c3ccf260e02cb3705a11226cbddffb90b | [
"MIT"
] | null | null | null | X = int(input())
Y = int(input())
soma = 0
if X > Y:
troca = Y
Y = X
X = troca
sam = X
while sam <= Y:
if sam%13 != 0:
soma = soma + sam
sam += 1
print(soma)
| 13.285714 | 25 | 0.462366 |
17d0f29d3c45101f706a5d553869a8adc551e247 | 217 | py | Python | InformationSecurity/phone-number.py | eduardormonteiro/PythonPersonalLibrary | 561733bb8305c4e25a08f99c28b60ec77251ad67 | [
"MIT"
] | null | null | null | InformationSecurity/phone-number.py | eduardormonteiro/PythonPersonalLibrary | 561733bb8305c4e25a08f99c28b60ec77251ad67 | [
"MIT"
] | null | null | null | InformationSecurity/phone-number.py | eduardormonteiro/PythonPersonalLibrary | 561733bb8305c4e25a08f99c28b60ec77251ad67 | [
"MIT"
] | null | null | null | import phonenumbers
from phonenumbers import geocoder
phone = input('type phone number format(+551100000000): ')
phone_number = phonenumbers.parse(phone)
print(geocoder.description_for_number(phone_number, 'pt'))
| 21.7 | 58 | 0.801843 |
17d3a82fb3f622128e484ca6ec7f7b9d2a13f56e | 20,307 | py | Python | src/extract_old_site/modules/standard_text_chapter.py | aychen99/Excavating-Occaneechi-Town | 6e864ca69ff1881554eb4c88aebed236bafbeaf4 | [
"MIT"
] | 1 | 2020-10-01T01:07:11.000Z | 2020-10-01T01:07:11.000Z | src/extract_old_site/modules/standard_text_chapter.py | aychen99/Excavating-Occaneechi-Town | 6e864ca69ff1881554eb4c88aebed236bafbeaf4 | [
"MIT"
] | null | null | null | src/extract_old_site/modules/standard_text_chapter.py | aychen99/Excavating-Occaneechi-Town | 6e864ca69ff1881554eb4c88aebed236bafbeaf4 | [
"MIT"
] | null | null | null | from bs4 import BeautifulSoup
from pathlib import Path
import os
def extract_page_content(html_string, folder_path_str):
"""Extract contents of a page from a report*b.html file.
Parameters
----------
html_string : str
The HTML content of the report*b.html page to be extracted, as a str.
fo... | 41.27439 | 113 | 0.594032 |
17d45564c73f2ece57a82cec5a50edaf47ded893 | 4,096 | py | Python | Pyrado/tests/environment_wrappers/test_action_delay.py | KhanhThiVo/SimuRLacra | fdeaf2059c2ed80ea696f018c29290510b5c4cb9 | [
"DOC",
"Zlib",
"BSD-3-Clause"
] | null | null | null | Pyrado/tests/environment_wrappers/test_action_delay.py | KhanhThiVo/SimuRLacra | fdeaf2059c2ed80ea696f018c29290510b5c4cb9 | [
"DOC",
"Zlib",
"BSD-3-Clause"
] | null | null | null | Pyrado/tests/environment_wrappers/test_action_delay.py | KhanhThiVo/SimuRLacra | fdeaf2059c2ed80ea696f018c29290510b5c4cb9 | [
"DOC",
"Zlib",
"BSD-3-Clause"
] | 1 | 2020-11-24T15:25:26.000Z | 2020-11-24T15:25:26.000Z | # Copyright (c) 2020, Fabio Muratore, Honda Research Institute Europe GmbH, and
# Technical University of Darmstadt.
# 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 ... | 34.711864 | 86 | 0.703125 |
17d56bb81bb616a7c2df1a2ead640a65eb1314c9 | 870 | py | Python | firmware/uvc_controller/mbed-os/features/storage/filesystem/littlefs/TESTS/util/stats.py | davewhiiite/uvc | fd45223097eed5a824294db975b3c74aa5f5cc8f | [
"MIT"
] | 1 | 2021-06-12T14:54:07.000Z | 2021-06-12T14:54:07.000Z | firmware/uvc_controller/mbed-os/features/storage/filesystem/littlefsv2/TESTS/util/stats.py | davewhiiite/uvc | fd45223097eed5a824294db975b3c74aa5f5cc8f | [
"MIT"
] | null | null | null | firmware/uvc_controller/mbed-os/features/storage/filesystem/littlefsv2/TESTS/util/stats.py | davewhiiite/uvc | fd45223097eed5a824294db975b3c74aa5f5cc8f | [
"MIT"
] | null | null | null | #!/usr/bin/env python
import re
import sys
import subprocess
import os
if __name__ == "__main__":
main(*sys.argv[1:])
| 25.588235 | 69 | 0.503448 |
17d66d7d5e69a7e3bc0a7835bb2e2711e3a0a57c | 6,093 | py | Python | doltpy/cli/write/write.py | jzcruiser/doltpy | e7dfa97c66fa405e1a1ead04228084eaf3c4b0b9 | [
"Apache-2.0"
] | null | null | null | doltpy/cli/write/write.py | jzcruiser/doltpy | e7dfa97c66fa405e1a1ead04228084eaf3c4b0b9 | [
"Apache-2.0"
] | null | null | null | doltpy/cli/write/write.py | jzcruiser/doltpy | e7dfa97c66fa405e1a1ead04228084eaf3c4b0b9 | [
"Apache-2.0"
] | null | null | null | import csv
import datetime
import io
import logging
import os
import tempfile
from typing import Any, Callable, List, Mapping, Optional, Set
import pandas as pd # type: ignore
from doltpy.cli import Dolt
from doltpy.shared.helpers import columns_to_rows
logger = logging.getLogger(__name__)
CREATE, FORCE_CREATE, RE... | 26.84141 | 120 | 0.627934 |
17d686163c9068a2aa27ba7692b6a6104aee5c2a | 3,816 | py | Python | codeformatter/formatter.py | ephenyxshop/sublimetext-codeformatter | f4af5682b3e28d7ec0b450808bc0c0ad6b017fa9 | [
"MIT"
] | 676 | 2015-01-01T03:56:14.000Z | 2022-03-31T18:20:47.000Z | codeformatter/formatter.py | ephenyxshop/sublimetext-codeformatter | f4af5682b3e28d7ec0b450808bc0c0ad6b017fa9 | [
"MIT"
] | 331 | 2015-01-02T19:31:30.000Z | 2022-03-19T03:24:29.000Z | codeformatter/formatter.py | ephenyxshop/sublimetext-codeformatter | f4af5682b3e28d7ec0b450808bc0c0ad6b017fa9 | [
"MIT"
] | 196 | 2015-01-02T20:48:12.000Z | 2022-03-13T06:48:19.000Z | # @author Avtandil Kikabidze
# @copyright Copyright (c) 2008-2015, Avtandil Kikabidze aka LONGMAN (akalongman@gmail.com)
# @link http://longman.me
# @license The MIT License (MIT)
import os
import sys
import re
import sublime
directory = os.path.dirname(os.path.realpath(__file_... | 34.071429 | 99 | 0.653826 |
17d69728ccc0d7694c2df558651b0fdf5636b10f | 2,048 | py | Python | splash/teams/teams_routes.py | dylanmcreynolds/splash-server | 28559d5109c8efcf3ea882b91a99722d957f2daa | [
"BSD-3-Clause-LBNL"
] | null | null | null | splash/teams/teams_routes.py | dylanmcreynolds/splash-server | 28559d5109c8efcf3ea882b91a99722d957f2daa | [
"BSD-3-Clause-LBNL"
] | null | null | null | splash/teams/teams_routes.py | dylanmcreynolds/splash-server | 28559d5109c8efcf3ea882b91a99722d957f2daa | [
"BSD-3-Clause-LBNL"
] | null | null | null | from typing import List, Optional
from attr import dataclass
from fastapi import APIRouter, Security
from fastapi.exceptions import HTTPException
from fastapi import Header
from pydantic import BaseModel
from pydantic.tools import parse_obj_as
from splash.api.auth import get_current_user
from splash.service import Spl... | 28.054795 | 92 | 0.70752 |
17d6d2baf1ae470f49b44765fcb69dbd6a4f9357 | 1,635 | py | Python | iotbx/xds/xds_cbf.py | dperl-sol/cctbx_project | b9e390221a2bc4fd00b9122e97c3b79c632c6664 | [
"BSD-3-Clause-LBNL"
] | 155 | 2016-11-23T12:52:16.000Z | 2022-03-31T15:35:44.000Z | iotbx/xds/xds_cbf.py | dperl-sol/cctbx_project | b9e390221a2bc4fd00b9122e97c3b79c632c6664 | [
"BSD-3-Clause-LBNL"
] | 590 | 2016-12-10T11:31:18.000Z | 2022-03-30T23:10:09.000Z | iotbx/xds/xds_cbf.py | dperl-sol/cctbx_project | b9e390221a2bc4fd00b9122e97c3b79c632c6664 | [
"BSD-3-Clause-LBNL"
] | 115 | 2016-11-15T08:17:28.000Z | 2022-02-09T15:30:14.000Z | #!/usr/bin/env libtbx.python
#
# iotbx.xds.xds_cbf.py
#
# James Parkhurst, Diamond Light Source, 2012/OCT/16
#
# Class to read the CBF files used in XDS
#
from __future__ import absolute_import, division, print_function
if __name__ == '__main__':
import sys
import numpy
handle = reader()
handle.rea... | 26.803279 | 69 | 0.692355 |
17d6e153039df485af98e9c048abf9aa413e954d | 6,267 | py | Python | py_bipartite_matching/graphs_utils.py | FranciscoMoretti/PyBipartiteMatching | 1edc1b2867c0c2d221fb1deedd1a28ad905b674e | [
"MIT"
] | 1 | 2022-02-24T18:30:48.000Z | 2022-02-24T18:30:48.000Z | py_bipartite_matching/graphs_utils.py | FranciscoMoretti/PyBipartiteMatching | 1edc1b2867c0c2d221fb1deedd1a28ad905b674e | [
"MIT"
] | 1 | 2021-02-14T15:16:17.000Z | 2021-02-14T15:23:49.000Z | py_bipartite_matching/graphs_utils.py | FranciscoMoretti/py_bipartite_matching | 1edc1b2867c0c2d221fb1deedd1a28ad905b674e | [
"MIT"
] | null | null | null | # utils for graphs of the networkx library
import copy
import networkx as nx
from networkx.algorithms.shortest_paths import shortest_path
from typing import Any, Union, Optional, Iterator, Iterable, Tuple, Dict, List, cast
LEFT = 0
RIGHT = 1
def bipartite_node_positions(graph: nx.Graph) -> Dict[int, Tuple[int, int... | 39.415094 | 100 | 0.641615 |
17d70d0f739b0dba8004b1173a78f20e8da6da67 | 29,476 | py | Python | tools/lttng.py | Taritsyn/ChakraCore | b6042191545a823fcf9d53df2b09d160d5808f51 | [
"MIT"
] | 8,664 | 2016-01-13T17:33:19.000Z | 2019-05-06T19:55:36.000Z | tools/lttng.py | Taritsyn/ChakraCore | b6042191545a823fcf9d53df2b09d160d5808f51 | [
"MIT"
] | 5,058 | 2016-01-13T17:57:02.000Z | 2019-05-04T15:41:54.000Z | tools/lttng.py | Taritsyn/ChakraCore | b6042191545a823fcf9d53df2b09d160d5808f51 | [
"MIT"
] | 1,367 | 2016-01-13T17:54:57.000Z | 2019-04-29T18:16:27.000Z | #-------------------------------------------------------------------------------------------------------
# Copyright (C) Microsoft. All rights reserved.
# Licensed under the MIT license. See LICENSE.txt file in the project root for full license information.
#-------------------------------------------------------------... | 38.989418 | 157 | 0.609716 |
17d9825c1fef65245d3858f454c9d3950426c393 | 16,305 | py | Python | GSM_model/sequences.py | Schwebus/DTU_Biobuilders_2021 | 13fd78eb7516c401cc98f13ff878be3607521cef | [
"MIT"
] | null | null | null | GSM_model/sequences.py | Schwebus/DTU_Biobuilders_2021 | 13fd78eb7516c401cc98f13ff878be3607521cef | [
"MIT"
] | null | null | null | GSM_model/sequences.py | Schwebus/DTU_Biobuilders_2021 | 13fd78eb7516c401cc98f13ff878be3607521cef | [
"MIT"
] | 1 | 2021-07-02T09:16:06.000Z | 2021-07-02T09:16:06.000Z | pMMO_dna_seq = 'ATGAAAACTATTAAAGATAGAATTGCTAAATGGTCTGCTATTGGTTTGTTGTCTGCTGTTGCTGCTACTGCTTTTTATGCTCCATCTGCTTCTGCTCATGGTGAAAAATCTCAAGCTGCTTTTATGAGAATGAGGACTATTCATTGGTATGACTTATCTTGGTCTAAGGAAAAGGTTAAAATAAACGAAACTGTTGAGATTAAAGGTAAATTTCATGTTTTTGAAGGTTGGCCTGAAACTGTTGATGAACCTGATGTTGCTTTTTTGAATGTTGGTATGCCTGGTCCTGTTTTTATTAGAAAAG... | 2,717.5 | 8,891 | 0.997853 |
17da768787ed79973072983b3cce0e340bf8fc26 | 1,304 | py | Python | PythonSelenium/src/server.py | talhaHavadar/MomTV | 1673b8d41a3d6157b7e1ba5ba4bd3ad7a70a3ba9 | [
"MIT"
] | 1 | 2019-02-23T06:41:58.000Z | 2019-02-23T06:41:58.000Z | PythonSelenium/src/server.py | talhaHavadar/MomTV | 1673b8d41a3d6157b7e1ba5ba4bd3ad7a70a3ba9 | [
"MIT"
] | null | null | null | PythonSelenium/src/server.py | talhaHavadar/MomTV | 1673b8d41a3d6157b7e1ba5ba4bd3ad7a70a3ba9 | [
"MIT"
] | null | null | null | """
Handles all requests that coming from phone
"""
import socketserver
import bot
from bot import TVBot
| 34.315789 | 81 | 0.537577 |
17dbf62f58a11e99d5780b17f22714e9a8df977a | 3,640 | py | Python | pydemic/fitting/Rt.py | PyDemic/pydemic | 7e748e4bbe5c1f7fb209271af0ff8afb8fbd4fd5 | [
"MIT"
] | 3 | 2020-05-10T23:52:41.000Z | 2021-08-31T14:38:24.000Z | pydemic/fitting/Rt.py | PyDemic/pydemic | 7e748e4bbe5c1f7fb209271af0ff8afb8fbd4fd5 | [
"MIT"
] | 1 | 2020-09-27T03:26:51.000Z | 2022-03-30T12:18:08.000Z | pydemic/fitting/Rt.py | PyDemic/pydemic | 7e748e4bbe5c1f7fb209271af0ff8afb8fbd4fd5 | [
"MIT"
] | 1 | 2020-10-01T04:07:39.000Z | 2020-10-01T04:07:39.000Z | import pandas as pd
from . import K
from .epidemic_curves import epidemic_curve
from .utils import cases
from .. import formulas
from ..diseases import disease as get_disease
from ..docs import docstring
ARGS = """Args:
model ({'SIR', 'SEIR', 'SEAIR', etc}):
Epidemic model used to compute R(t) from K(... | 27.164179 | 98 | 0.64533 |
17dd134a81d8c44b28955eff31849c98b00f6958 | 5,099 | py | Python | python/tests/spark/sql/codegen/test_sklearn_flavor.py | askintution/rikai | 53a72a19beafc4097a816efb9cddd063e107e67a | [
"Apache-2.0"
] | 1 | 2022-02-18T07:53:29.000Z | 2022-02-18T07:53:29.000Z | python/tests/spark/sql/codegen/test_sklearn_flavor.py | askintution/rikai | 53a72a19beafc4097a816efb9cddd063e107e67a | [
"Apache-2.0"
] | null | null | null | python/tests/spark/sql/codegen/test_sklearn_flavor.py | askintution/rikai | 53a72a19beafc4097a816efb9cddd063e107e67a | [
"Apache-2.0"
] | null | null | null | # Copyright (c) 2021 Rikai Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed t... | 31.282209 | 79 | 0.596195 |
17ddf5f60cc34f1cbebcbf7f7b6413d3c56bbf83 | 813 | py | Python | Leetcode/week_2/p0811_subdomain_visit_count.py | SamSamhuns/wallbreakers_projekts | c07b555127ee89d6f461cea7cd87811c382086ff | [
"MIT"
] | 1 | 2021-07-07T00:55:23.000Z | 2021-07-07T00:55:23.000Z | Leetcode/week_2/p0811_subdomain_visit_count.py | SamSamhuns/wallbreakers_projekts | c07b555127ee89d6f461cea7cd87811c382086ff | [
"MIT"
] | null | null | null | Leetcode/week_2/p0811_subdomain_visit_count.py | SamSamhuns/wallbreakers_projekts | c07b555127ee89d6f461cea7cd87811c382086ff | [
"MIT"
] | null | null | null | from typing import List
from collections import defaultdict
"""
Runtime: O(4N) ~ O(N) runtime
Space: O(N)
Runtime: 52 ms, faster than 73.52% of Python3 online submissions for Subdomain Visit Count.
Memory Usage: 12.8 MB, less than 100.00% of Python3 online submissions for Subdomain Visit Count.
"""
| 29.035714 | 97 | 0.646986 |
17de742785e7e376b1d10db620dbbd2f43d27408 | 15,752 | py | Python | h2o-bindings/bin/pyunit_parser_test.py | vishalbelsare/h2o-3 | 9322fb0f4c0e2358449e339a434f607d524c69fa | [
"Apache-2.0"
] | 6,098 | 2015-05-22T02:46:12.000Z | 2022-03-31T16:54:51.000Z | h2o-bindings/bin/pyunit_parser_test.py | vishalbelsare/h2o-3 | 9322fb0f4c0e2358449e339a434f607d524c69fa | [
"Apache-2.0"
] | 2,517 | 2015-05-23T02:10:54.000Z | 2022-03-30T17:03:39.000Z | h2o-bindings/bin/pyunit_parser_test.py | vishalbelsare/h2o-3 | 9322fb0f4c0e2358449e339a434f607d524c69fa | [
"Apache-2.0"
] | 2,199 | 2015-05-22T04:09:55.000Z | 2022-03-28T22:20:45.000Z | #!/usr/bin/env python
# -*- encoding: utf-8 -*-
"""Test case for pyparser."""
from __future__ import division, print_function
import os
import re
import textwrap
import tokenize
from future.builtins import open
import pyparser
NL = tokenize.NL
NEWLINE = tokenize.NEWLINE
NAME = _make_tuple(tokenize.NAME)
OP = _make_... | 38.702703 | 117 | 0.509777 |
17e0d5e504ccaae3246c922d12121bf9759c86a5 | 29,139 | py | Python | tools/pot/openvino/tools/pot/algorithms/quantization/accuracy_aware_common/algorithm.py | chccc1994/openvino | 41f7893ae81d186d15c1754b179bf32a66d03bcf | [
"Apache-2.0"
] | 2,406 | 2020-04-22T15:47:54.000Z | 2022-03-31T10:27:37.000Z | tools/pot/openvino/tools/pot/algorithms/quantization/accuracy_aware_common/algorithm.py | thomas-yanxin/openvino | 031e998a15ec738c64cc2379d7f30fb73087c272 | [
"Apache-2.0"
] | 4,948 | 2020-04-22T15:12:39.000Z | 2022-03-31T18:45:42.000Z | tools/pot/openvino/tools/pot/algorithms/quantization/accuracy_aware_common/algorithm.py | thomas-yanxin/openvino | 031e998a15ec738c64cc2379d7f30fb73087c272 | [
"Apache-2.0"
] | 991 | 2020-04-23T18:21:09.000Z | 2022-03-31T18:40:57.000Z | # Copyright (C) 2020-2021 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
import os
import random
from copy import deepcopy
from sys import maxsize
import numpy as np
from .utils import create_metric_config, is_preset_performance, \
get_mixed_preset_config, evaluate_model, get_num_of_quantized_ops
from .... | 52.408273 | 119 | 0.651601 |
17e137bb0de594618d6979cb258b74fc8c2fc07c | 353 | py | Python | Django-React/exemple/api/migrations/0002_rename_created_app_room_created_at.py | S-c-r-a-t-c-h-y/coding-projects | cad33aedb72720c3e3a37c7529e55abd3edb291a | [
"MIT"
] | null | null | null | Django-React/exemple/api/migrations/0002_rename_created_app_room_created_at.py | S-c-r-a-t-c-h-y/coding-projects | cad33aedb72720c3e3a37c7529e55abd3edb291a | [
"MIT"
] | null | null | null | Django-React/exemple/api/migrations/0002_rename_created_app_room_created_at.py | S-c-r-a-t-c-h-y/coding-projects | cad33aedb72720c3e3a37c7529e55abd3edb291a | [
"MIT"
] | null | null | null | # Generated by Django 3.2 on 2021-07-03 21:26
from django.db import migrations
| 18.578947 | 45 | 0.575071 |
17e1d0ca3e2d0f35d168ba0274703631eff3ed3a | 417 | py | Python | exceptions.py | italovalcy/mef_eline | 230d2bb44b1506adc9900157ca09e920fb37b002 | [
"MIT"
] | 1 | 2021-12-09T17:09:33.000Z | 2021-12-09T17:09:33.000Z | exceptions.py | italovalcy/mef_eline | 230d2bb44b1506adc9900157ca09e920fb37b002 | [
"MIT"
] | 171 | 2021-06-02T20:29:22.000Z | 2022-03-18T17:47:57.000Z | exceptions.py | italovalcy/mef_eline | 230d2bb44b1506adc9900157ca09e920fb37b002 | [
"MIT"
] | 3 | 2021-06-15T18:55:52.000Z | 2021-10-01T14:47:10.000Z | """MEF Eline Exceptions."""
| 18.954545 | 42 | 0.717026 |
17e22362c78802f14ab902ca7c186827af89b8a5 | 4,724 | py | Python | stack.py | Shahadate-Rezvy/Samon_EXplainer | 2ac4a55c06d4ea90cb38dae27e24f7945415a2b6 | [
"MIT"
] | null | null | null | stack.py | Shahadate-Rezvy/Samon_EXplainer | 2ac4a55c06d4ea90cb38dae27e24f7945415a2b6 | [
"MIT"
] | null | null | null | stack.py | Shahadate-Rezvy/Samon_EXplainer | 2ac4a55c06d4ea90cb38dae27e24f7945415a2b6 | [
"MIT"
] | 1 | 2021-11-04T09:44:56.000Z | 2021-11-04T09:44:56.000Z | import numpy as np
from Orange.base import Learner, Model
from Orange.modelling import Fitter
from Orange.classification import LogisticRegressionLearner
from Orange.classification.base_classification import LearnerClassification
from Orange.data import Domain, ContinuousVariable, Table
from Orange.evaluation import C... | 33.503546 | 79 | 0.65834 |
17e2be1570ac1669d8bc94548067cec13cd745f2 | 2,049 | py | Python | tests/test8u20/main.py | potats0/javaSerializationTools | eb0291bdd336e28ca5dd9ee86ba6d645f1bf6e8f | [
"Apache-2.0"
] | 124 | 2021-01-21T08:49:20.000Z | 2022-01-23T07:17:30.000Z | tests/test8u20/main.py | potats0/javaSerializationDump | eb0291bdd336e28ca5dd9ee86ba6d645f1bf6e8f | [
"Apache-2.0"
] | 3 | 2021-01-22T03:29:55.000Z | 2021-04-20T06:04:50.000Z | tests/test8u20/main.py | potats0/javaSerializationTools | eb0291bdd336e28ca5dd9ee86ba6d645f1bf6e8f | [
"Apache-2.0"
] | 12 | 2021-01-21T14:09:01.000Z | 2021-11-18T20:13:43.000Z | import yaml
from javaSerializationTools import JavaString, JavaField, JavaObject, JavaEndBlock
from javaSerializationTools import ObjectRead
from javaSerializationTools import ObjectWrite
if __name__ == '__main__':
with open("../files/7u21.ser", "rb") as f:
a = ObjectRead(f)
obj = a.readContent()... | 43.595745 | 101 | 0.70815 |
17e369dc9f4c67838ee2db6b83ebfbd5715f6650 | 634 | py | Python | getmysql_threadid.py | wang1352083/mysql_tool | 52f7efc319d2732d780913e7b1d7692fab8e791a | [
"MIT"
] | null | null | null | getmysql_threadid.py | wang1352083/mysql_tool | 52f7efc319d2732d780913e7b1d7692fab8e791a | [
"MIT"
] | null | null | null | getmysql_threadid.py | wang1352083/mysql_tool | 52f7efc319d2732d780913e7b1d7692fab8e791a | [
"MIT"
] | null | null | null | #!/usr/bin/env python
import sys
base31=pow(2,31)
base32=pow(2,32)
base=0xFFFFFFFF
'''
mysql processlistmysql.log threadid.
from :processlist.threadid -> mysql.log.threadid
'''
if __name__ == "__main__":
if len(sys.argv) == 2:
pid =int(sys.argv[1])
print long_to_short(pid)
else:
usage(s... | 22.642857 | 52 | 0.635647 |
17e3cea80522263e8bf2426fc1e739f762bc47da | 1,756 | bzl | Python | mediapipe_api/csharp_proto_src.bzl | laukaho/MediaPipeUnityPlugin | 77ba1a4d2249b8db09b3a1e975a01f6e50d21e33 | [
"MIT"
] | 20 | 2020-07-28T22:21:04.000Z | 2020-10-05T21:43:46.000Z | mediapipe_api/csharp_proto_src.bzl | laukaho/MediaPipeUnityPlugin | 77ba1a4d2249b8db09b3a1e975a01f6e50d21e33 | [
"MIT"
] | 9 | 2020-08-24T00:18:19.000Z | 2020-09-23T08:32:47.000Z | mediapipe_api/csharp_proto_src.bzl | laukaho/MediaPipeUnityPlugin | 77ba1a4d2249b8db09b3a1e975a01f6e50d21e33 | [
"MIT"
] | 4 | 2020-07-28T22:21:06.000Z | 2020-09-15T19:07:20.000Z | # Copyright (c) 2021 homuler
#
# Use of this source code is governed by an MIT-style
# license that can be found in the LICENSE file or at
# https://opensource.org/licenses/MIT.
"""Proto compiler
Macro for generating C# source files corresponding to .proto files
"""
def csharp_proto_src(name, proto_src, deps):
"... | 26.208955 | 71 | 0.607062 |
17e620adc33ee30cd11c65a57f46f1da7b3b9897 | 94 | py | Python | bertopic/__init__.py | louisguitton/BERTopic | 0b321678ffe4eab0a28484faf76728f584a94ebd | [
"MIT"
] | 1 | 2021-09-29T12:39:16.000Z | 2021-09-29T12:39:16.000Z | bertopic/__init__.py | louisguitton/BERTopic | 0b321678ffe4eab0a28484faf76728f584a94ebd | [
"MIT"
] | null | null | null | bertopic/__init__.py | louisguitton/BERTopic | 0b321678ffe4eab0a28484faf76728f584a94ebd | [
"MIT"
] | null | null | null | from bertopic._bertopic import BERTopic
__version__ = "0.9.1"
__all__ = [
"BERTopic",
]
| 11.75 | 39 | 0.680851 |
17e90b462716e5227ea477b2107d03519822cef3 | 2,597 | py | Python | dailyfresh/df_goods/views.py | myworldhere/dailyfresh | 5c4e78095a08442feacce7038818f9978e1e0880 | [
"MIT"
] | null | null | null | dailyfresh/df_goods/views.py | myworldhere/dailyfresh | 5c4e78095a08442feacce7038818f9978e1e0880 | [
"MIT"
] | null | null | null | dailyfresh/df_goods/views.py | myworldhere/dailyfresh | 5c4e78095a08442feacce7038818f9978e1e0880 | [
"MIT"
] | null | null | null | # coding=utf-8
from django.shortcuts import render, redirect
from django.core.paginator import Paginator
from models import *
from haystack.views import SearchView
# Create your views here.
#
| 32.873418 | 98 | 0.628417 |
17e98bdd9410e5ff20a99bb45742f5cb653135df | 4,267 | py | Python | guillotina_amqp/tests/mocks.py | vjove/guillotina_amqp | 34f2011ea5547166211e90608c54657d93dde4fc | [
"BSD-3-Clause"
] | 4 | 2018-06-14T12:03:41.000Z | 2020-02-12T17:07:18.000Z | guillotina_amqp/tests/mocks.py | vjove/guillotina_amqp | 34f2011ea5547166211e90608c54657d93dde4fc | [
"BSD-3-Clause"
] | 45 | 2018-11-12T10:57:30.000Z | 2021-05-26T19:13:12.000Z | guillotina_amqp/tests/mocks.py | vjove/guillotina_amqp | 34f2011ea5547166211e90608c54657d93dde4fc | [
"BSD-3-Clause"
] | 4 | 2018-12-19T16:59:04.000Z | 2021-06-20T16:27:43.000Z | import asyncio
import uuid
| 29.427586 | 83 | 0.574408 |
17ea30689ba9d98fd7b8fd672edbe09e38e06775 | 210 | py | Python | foodbot/urls.py | surajpaib/HungerHero | be7c0b77944579f057886b074ba8db83d270ae83 | [
"Apache-2.0"
] | null | null | null | foodbot/urls.py | surajpaib/HungerHero | be7c0b77944579f057886b074ba8db83d270ae83 | [
"Apache-2.0"
] | null | null | null | foodbot/urls.py | surajpaib/HungerHero | be7c0b77944579f057886b074ba8db83d270ae83 | [
"Apache-2.0"
] | null | null | null | from django.conf.urls import url
from . import views
urlpatterns = [
url(r'^bot/', views.webhook, name='bot'),
url(r'^foodcenter/', views.food_center_webhook, name= 'food'),
# url(r'^relay/', vi)
] | 26.25 | 66 | 0.647619 |
17ea8bf7616bc3b308a3396c07848b28c8a67621 | 3,874 | py | Python | pkgs/sdk-pkg/src/genie/libs/sdk/apis/iosxe/l2vpn/configure.py | CiscoTestAutomation/genielibs | becee8a1a85f4973e00859e3244e2c8fe45a394c | [
"Apache-2.0"
] | 94 | 2018-04-30T20:29:15.000Z | 2022-03-29T13:40:31.000Z | pkgs/sdk-pkg/src/genie/libs/sdk/apis/iosxe/l2vpn/configure.py | patrickboertje/genielibs | 61c37aacf3dd0f499944555e4ff940f92f53dacb | [
"Apache-2.0"
] | 67 | 2018-12-06T21:08:09.000Z | 2022-03-29T18:00:46.000Z | pkgs/sdk-pkg/src/genie/libs/sdk/apis/iosxe/l2vpn/configure.py | patrickboertje/genielibs | 61c37aacf3dd0f499944555e4ff940f92f53dacb | [
"Apache-2.0"
] | 49 | 2018-06-29T18:59:03.000Z | 2022-03-10T02:07:59.000Z | """Common configure functions for bgp"""
# Python
import logging
import re
# Unicon
from unicon.core.errors import SubCommandFailure
log = logging.getLogger(__name__)
def configure_l2vpn_storm_control(
device, interface, service_instance_id, storm_control
):
""" Configures storm control under service insta... | 28.485294 | 79 | 0.513681 |
17ecb3cdae4406d81c58cf487da09197d576b8b9 | 590 | py | Python | MagiSlack/__main__.py | riemannulus/MagiSlack | 3bcb5057ccc0699b2e4b0029f5d1c87e03a70356 | [
"MIT"
] | null | null | null | MagiSlack/__main__.py | riemannulus/MagiSlack | 3bcb5057ccc0699b2e4b0029f5d1c87e03a70356 | [
"MIT"
] | null | null | null | MagiSlack/__main__.py | riemannulus/MagiSlack | 3bcb5057ccc0699b2e4b0029f5d1c87e03a70356 | [
"MIT"
] | null | null | null | from os import environ
from MagiSlack.io import MagiIO
from MagiSlack.module import MagiModule
if __name__ == '__main__':
print('Magi Start!')
print('='*30)
print('MagiModule Initializing.')
module = MagiModule.MagiModule(environ['SLACK_API_TOKEN'])
print('Complete')
print('='*30)
print... | 21.851852 | 74 | 0.666102 |
17edcea77994ad95b7f15708cbc1815c28e54b7c | 2,234 | py | Python | my_plugins/YouCompleteMe/third_party/ycmd/ycmd/tests/server_utils_test.py | liutongliang/myVim | 6c7ab36f25f4a5e2e1daeab8c43509975eb031e3 | [
"MIT"
] | 2 | 2018-04-16T03:08:42.000Z | 2021-01-06T10:21:49.000Z | my_plugins/YouCompleteMe/third_party/ycmd/ycmd/tests/server_utils_test.py | liutongliang/myVim | 6c7ab36f25f4a5e2e1daeab8c43509975eb031e3 | [
"MIT"
] | null | null | null | my_plugins/YouCompleteMe/third_party/ycmd/ycmd/tests/server_utils_test.py | liutongliang/myVim | 6c7ab36f25f4a5e2e1daeab8c43509975eb031e3 | [
"MIT"
] | null | null | null | # Copyright (C) 2016-2018 ycmd contributors
#
# This file is part of ycmd.
#
# ycmd 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 option) any later version.
#
#... | 39.192982 | 79 | 0.745748 |
17ee2ab39fa3aef85b71231efdccae35147bec91 | 560 | py | Python | spraycharles/utils/notify.py | Tw1sm/passwordpredator | 57e173c68b1dfe89149fc108999f560bf1569cd7 | [
"BSD-3-Clause"
] | null | null | null | spraycharles/utils/notify.py | Tw1sm/passwordpredator | 57e173c68b1dfe89149fc108999f560bf1569cd7 | [
"BSD-3-Clause"
] | null | null | null | spraycharles/utils/notify.py | Tw1sm/passwordpredator | 57e173c68b1dfe89149fc108999f560bf1569cd7 | [
"BSD-3-Clause"
] | null | null | null | import pymsteams
from discord_webhook import DiscordWebhook
from notifiers import get_notifier
| 25.454545 | 86 | 0.725 |
17ef674eddb0b6d4127cc6eda09e667c21a0faed | 716 | py | Python | manage.py | SinnerSchraderMobileMirrors/django-cms | 157daefd30d9e82cc538a0c226539bf6681beabd | [
"BSD-3-Clause"
] | 2 | 2018-05-17T02:49:49.000Z | 2019-08-20T02:07:44.000Z | manage.py | SinnerSchraderMobileMirrors/django-cms | 157daefd30d9e82cc538a0c226539bf6681beabd | [
"BSD-3-Clause"
] | 2 | 2019-02-13T07:58:23.000Z | 2019-02-13T07:58:27.000Z | manage.py | SinnerSchraderMobileMirrors/django-cms | 157daefd30d9e82cc538a0c226539bf6681beabd | [
"BSD-3-Clause"
] | null | null | null | #!/usr/bin/env python
import sys
from cms.test_utils.cli import configure
from cms.test_utils.tmpdir import temp_dir
import os
if __name__ == '__main__':
main()# -*- coding: utf-8 -*-
| 27.538462 | 81 | 0.632682 |
17f2ae7ec4594fe359f3c7b237e6c438d1daf8c2 | 2,639 | py | Python | semantic-clustering/semantic_clustering/EmbeddingDataFrameWrapper.py | zzoia/sbert_wk_sentence_embedder | 096b149eefec25fac83aaef674421dfdfb150a68 | [
"MIT"
] | null | null | null | semantic-clustering/semantic_clustering/EmbeddingDataFrameWrapper.py | zzoia/sbert_wk_sentence_embedder | 096b149eefec25fac83aaef674421dfdfb150a68 | [
"MIT"
] | null | null | null | semantic-clustering/semantic_clustering/EmbeddingDataFrameWrapper.py | zzoia/sbert_wk_sentence_embedder | 096b149eefec25fac83aaef674421dfdfb150a68 | [
"MIT"
] | null | null | null | import numpy as np
import pandas as pd
from sklearn.metrics.pairwise import cosine_similarity | 37.169014 | 112 | 0.643047 |
17f3838494cef3ff36c0edabf5b3161b2c576936 | 1,716 | py | Python | sawyer/flat_goal_env.py | geyang/gym-sawyer | c6e81ab4faefafcfa3886d74672976cc16452747 | [
"MIT"
] | 4 | 2020-06-02T16:25:31.000Z | 2020-07-28T12:26:26.000Z | sawyer/flat_goal_env.py | geyang/gym-sawyer | c6e81ab4faefafcfa3886d74672976cc16452747 | [
"MIT"
] | 1 | 2020-09-30T10:24:04.000Z | 2020-09-30T10:24:04.000Z | sawyer/flat_goal_env.py | geyang/gym-sawyer | c6e81ab4faefafcfa3886d74672976cc16452747 | [
"MIT"
] | null | null | null | import gym
import numpy as np
# wrapper classes are anti-patterns.
def FlatGoalEnv(env, obs_keys, goal_keys):
"""
We require the keys to be passed in explicitly, to avoid mistakes.
:param env:
:param obs_keys: obs_keys=('state_observation',)
:param goal_keys: goal_keys=('desired_goal',)
"""
... | 27.238095 | 78 | 0.634033 |
17f39ca5f51dfeded3449260d86659beaadb7c0a | 23,967 | py | Python | sql/views_ajax.py | Galo1117/archer | a0e32b8990cdbbe4a7166656762fbf0f694092fa | [
"Apache-2.0"
] | null | null | null | sql/views_ajax.py | Galo1117/archer | a0e32b8990cdbbe4a7166656762fbf0f694092fa | [
"Apache-2.0"
] | null | null | null | sql/views_ajax.py | Galo1117/archer | a0e32b8990cdbbe4a7166656762fbf0f694092fa | [
"Apache-2.0"
] | null | null | null | # -*- coding: UTF-8 -*-
import re
import simplejson as json
import datetime
import multiprocessing
import urllib.parse
import subprocess
from django.contrib.auth import authenticate, login
from django.db.models import Q
from django.db import transaction
from django.conf import settings
from django.views.decorators.... | 39.225859 | 122 | 0.641841 |
17f3d9a2300741cd7506a6c4460578d98121f0a5 | 154 | py | Python | gather/handlers/__init__.py | openghg/gather | 0096cfe66b0093cdd294fa2a67c060d7fc28d2fa | [
"Apache-2.0"
] | null | null | null | gather/handlers/__init__.py | openghg/gather | 0096cfe66b0093cdd294fa2a67c060d7fc28d2fa | [
"Apache-2.0"
] | null | null | null | gather/handlers/__init__.py | openghg/gather | 0096cfe66b0093cdd294fa2a67c060d7fc28d2fa | [
"Apache-2.0"
] | null | null | null | from ._scrape import scrape_handler
from ._binary_data import data_handler
from ._crds import crds_handler
__all__ = ["scrape_handler", "data_handler"]
| 22 | 44 | 0.811688 |
17f4968f43abac4e2306cd72253ba000d15a0329 | 49 | py | Python | bitswap/block_storage/__init__.py | VladislavSufyanov/py-bitswap | 875d15944e485c33b16af9965f24c1d85cb34c55 | [
"MIT"
] | null | null | null | bitswap/block_storage/__init__.py | VladislavSufyanov/py-bitswap | 875d15944e485c33b16af9965f24c1d85cb34c55 | [
"MIT"
] | null | null | null | bitswap/block_storage/__init__.py | VladislavSufyanov/py-bitswap | 875d15944e485c33b16af9965f24c1d85cb34c55 | [
"MIT"
] | null | null | null | from .base_block_storage import BaseBlockStorage
| 24.5 | 48 | 0.897959 |
17f57d12f28aa74c2e00b10a8b41523a0b884875 | 12,816 | py | Python | src/users/models.py | ofirr/OpenCommunity | 7786ac2996530af8f545f4398c071793c73634c8 | [
"BSD-3-Clause"
] | null | null | null | src/users/models.py | ofirr/OpenCommunity | 7786ac2996530af8f545f4398c071793c73634c8 | [
"BSD-3-Clause"
] | null | null | null | src/users/models.py | ofirr/OpenCommunity | 7786ac2996530af8f545f4398c071793c73634c8 | [
"BSD-3-Clause"
] | null | null | null | from django.conf import settings
from django.contrib.auth.models import BaseUserManager, AbstractBaseUser, \
PermissionsMixin
from django.core.mail import send_mail
from django.db import models
from django.template.loader import render_to_string
from django.utils import timezone
from django.utils.translation import... | 39.073171 | 220 | 0.628277 |
17f74407f6071edec00f6d7cb2950f3675cc7079 | 881 | py | Python | src/hyperloop/Python/tests/test_magnetic_drag.py | jcchin/Hyperloop_v2 | 73861d2207af8738425c1d484909ed0433b9653f | [
"Apache-2.0"
] | 1 | 2021-04-29T00:23:03.000Z | 2021-04-29T00:23:03.000Z | src/hyperloop/Python/tests/test_magnetic_drag.py | jcchin/Hyperloop_v2 | 73861d2207af8738425c1d484909ed0433b9653f | [
"Apache-2.0"
] | 9 | 2016-11-23T09:10:34.000Z | 2016-12-06T01:10:09.000Z | src/hyperloop/Python/tests/test_magnetic_drag.py | jcchin/Hyperloop_v2 | 73861d2207af8738425c1d484909ed0433b9653f | [
"Apache-2.0"
] | 11 | 2016-01-19T20:26:35.000Z | 2021-02-13T11:16:20.000Z | """
Test for magnetic_drag.py. Uses test values and outputs given by
the laminated sheet experiment in [1].
"""
import pytest
from hyperloop.Python.pod.magnetic_levitation.magnetic_drag import MagDrag
import numpy as np
from openmdao.api import Group, Problem
| 25.171429 | 74 | 0.651532 |