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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
2dba6814e9a58be8a1046bd1b724d2d25bc21d0e | 1,930 | py | Python | schedule/main/utils/fetch_data.py | DSD-ESDC-EDSC/dynamic-org-chart-scripts | a2247ac85ddadc5b33256a501be16bf787b395b6 | [
"MIT"
] | null | null | null | schedule/main/utils/fetch_data.py | DSD-ESDC-EDSC/dynamic-org-chart-scripts | a2247ac85ddadc5b33256a501be16bf787b395b6 | [
"MIT"
] | null | null | null | schedule/main/utils/fetch_data.py | DSD-ESDC-EDSC/dynamic-org-chart-scripts | a2247ac85ddadc5b33256a501be16bf787b395b6 | [
"MIT"
] | null | null | null | import csv
from io import BytesIO
import pandas as pd
from urllib.request import urlopen
from zipfile import ZipFile
def fetch_geds(url, subset=None):
'''
Fetches the geds dataset from Canada's Open Data Portal
Args:
url:
A string containing the url to the Canada Open Data Portal web ... | 39.387755 | 88 | 0.650259 |
2dbaf351886ba4462165fc13883318f911a808c6 | 3,210 | py | Python | grid.py | Data-Mechanics/bps-simulated-students | eb96fcb1185c5b00b822a36ce74bcbead87d5e16 | [
"MIT"
] | 2 | 2018-02-14T01:33:39.000Z | 2019-04-03T07:08:15.000Z | grid.py | data-mechanics/bps-simulated-data | eb96fcb1185c5b00b822a36ce74bcbead87d5e16 | [
"MIT"
] | null | null | null | grid.py | data-mechanics/bps-simulated-data | eb96fcb1185c5b00b822a36ce74bcbead87d5e16 | [
"MIT"
] | 2 | 2018-02-14T01:33:46.000Z | 2019-04-03T07:08:17.000Z | """
grid.py
Module containing class for working with a street grid.
"""
import json
import geojson
import geopy.distance
import shapely.geometry
from geoql import geoql
import geoleaflet
import folium
import rtree
import networkx
from tqdm import tqdm
if __name__ == "__main__":
# The following is used to generat... | 37.764706 | 111 | 0.62648 |
2dbb30295e3227128b76736e47f8b0f48dfcbaa4 | 6,019 | py | Python | lost_ds/vis/vis.py | l3p-cv/lost_ds | 4a2f3ef027128b759d28e67cb1fdaa0a557e343c | [
"MIT"
] | 1 | 2022-03-30T11:29:57.000Z | 2022-03-30T11:29:57.000Z | lost_ds/vis/vis.py | l3p-cv/lost_ds | 4a2f3ef027128b759d28e67cb1fdaa0a557e343c | [
"MIT"
] | null | null | null | lost_ds/vis/vis.py | l3p-cv/lost_ds | 4a2f3ef027128b759d28e67cb1fdaa0a557e343c | [
"MIT"
] | null | null | null | import os
from tqdm import tqdm
from joblib import Parallel, delayed
try:
import seaborn as sns
except:
pass
import numpy as np
import cv2
from lost_ds.util import get_fs
from lost_ds.geometry.lost_geom import LOSTGeometries
from lost_ds.functional.api import remove_empty
def vis_sample(img, df, line_th... | 39.860927 | 81 | 0.615052 |
2dbb32b6fb7e99eba9946c0267ff01781d71e612 | 16,638 | py | Python | cadnano/views/pathview/prexovermanager.py | mctrinh/cadnano2.5 | d8254f24eef5fd77b4fb2b1a9642a8eea2e3c736 | [
"BSD-3-Clause"
] | 1 | 2022-03-27T14:37:32.000Z | 2022-03-27T14:37:32.000Z | cadnano/views/pathview/prexovermanager.py | mctrinh/cadnano2.5 | d8254f24eef5fd77b4fb2b1a9642a8eea2e3c736 | [
"BSD-3-Clause"
] | null | null | null | cadnano/views/pathview/prexovermanager.py | mctrinh/cadnano2.5 | d8254f24eef5fd77b4fb2b1a9642a8eea2e3c736 | [
"BSD-3-Clause"
] | 1 | 2021-01-22T02:29:38.000Z | 2021-01-22T02:29:38.000Z | from collections import deque
from PyQt5.QtCore import Qt
from PyQt5.QtGui import QColor
from PyQt5.QtWidgets import QGraphicsRectItem
from cadnano.gui.palette import getNoPen
from cadnano.proxies.cnenum import StrandType
from .pathextras import PreXoverItem
# end def
def activateVirtualHelix(self, virtual_... | 36.486842 | 108 | 0.536783 |
2dbba15b3067323a927d0aa7d2634d1361341f4c | 782 | py | Python | tests/api_test.py | pmav99/sysfacts | 09a5658a8f4e789db71844759dd4ae61369f4f4a | [
"MIT"
] | 2 | 2019-01-25T17:32:49.000Z | 2020-11-06T19:45:40.000Z | tests/api_test.py | pmav99/sysfacts | 09a5658a8f4e789db71844759dd4ae61369f4f4a | [
"MIT"
] | 3 | 2019-01-25T23:36:42.000Z | 2019-01-26T23:20:09.000Z | tests/api_test.py | pmav99/sysfacts | 09a5658a8f4e789db71844759dd4ae61369f4f4a | [
"MIT"
] | null | null | null | import json
import pytest
import sysfacts
| 19.55 | 81 | 0.680307 |
2dbd516e74ed752446450ca98d09c2ca319fdd11 | 521 | py | Python | MerginLetters.py | SandraCoburn/python-code-challenges | 52ca026c02a45cadc890d01fc095d39d42b36d4c | [
"MIT"
] | null | null | null | MerginLetters.py | SandraCoburn/python-code-challenges | 52ca026c02a45cadc890d01fc095d39d42b36d4c | [
"MIT"
] | null | null | null | MerginLetters.py | SandraCoburn/python-code-challenges | 52ca026c02a45cadc890d01fc095d39d42b36d4c | [
"MIT"
] | null | null | null |
print(mergingLetters('abcd', 'jjjjjjj')) | 26.05 | 71 | 0.589251 |
2dbe52d295d10c6a1ea04833833e85f2bfabaaa8 | 2,696 | py | Python | loutilities/flask_helpers/decorators.py | louking/loutilities | 7a7bb27b09b8d6e3a411153b604858aaec397fc6 | [
"Apache-2.0"
] | 1 | 2020-03-16T12:47:08.000Z | 2020-03-16T12:47:08.000Z | loutilities/flask_helpers/decorators.py | louking/loutilities | 7a7bb27b09b8d6e3a411153b604858aaec397fc6 | [
"Apache-2.0"
] | 35 | 2015-07-11T14:57:30.000Z | 2022-03-12T00:53:44.000Z | loutilities/flask_helpers/decorators.py | louking/loutilities | 7a7bb27b09b8d6e3a411153b604858aaec397fc6 | [
"Apache-2.0"
] | null | null | null | '''
decorators - decorators to help with flask applications
'''
# standard
from datetime import timedelta
from functools import update_wrapper
# pypi
from flask import make_response, request, current_app
def crossdomain(origin=None, methods=None, headers=None,
max_age=21600, attach_to_all=True,
... | 44.196721 | 208 | 0.676187 |
2dbea13bd2722e39d52ed915d89d5e1fea406ab7 | 458 | py | Python | Forms/InstagramLoginForm.py | CT83/PyMultiPoster | 2ecd96764f21a88486f87cc55099ddff8d106e4f | [
"Apache-2.0"
] | null | null | null | Forms/InstagramLoginForm.py | CT83/PyMultiPoster | 2ecd96764f21a88486f87cc55099ddff8d106e4f | [
"Apache-2.0"
] | null | null | null | Forms/InstagramLoginForm.py | CT83/PyMultiPoster | 2ecd96764f21a88486f87cc55099ddff8d106e4f | [
"Apache-2.0"
] | null | null | null | from flask_wtf import FlaskForm
from wtforms import PasswordField, SubmitField, StringField
from wtforms.validators import DataRequired, Length
| 41.636364 | 84 | 0.679039 |
2dbf56a3c63f5d01e7044ebe76a8ea82211353a1 | 5,117 | py | Python | tests/flask/test_oauth2/test_token_introspection.py | tk193192/authlib | 4c60a628f64c6d385a06ea55e416092726b94d07 | [
"BSD-3-Clause"
] | 2 | 2021-04-26T18:17:37.000Z | 2021-04-28T21:39:45.000Z | tests/flask/test_oauth2/test_token_introspection.py | tk193192/authlib | 4c60a628f64c6d385a06ea55e416092726b94d07 | [
"BSD-3-Clause"
] | null | null | null | tests/flask/test_oauth2/test_token_introspection.py | tk193192/authlib | 4c60a628f64c6d385a06ea55e416092726b94d07 | [
"BSD-3-Clause"
] | 1 | 2019-10-07T02:01:48.000Z | 2019-10-07T02:01:48.000Z | from flask import json
from authlib.flask.oauth2.sqla import create_query_token_func
from authlib.oauth2.rfc7662 import IntrospectionEndpoint
from .models import db, User, Client, Token
from .oauth2_server import TestCase
from .oauth2_server import create_authorization_server
query_token = create_query_token_func(db.... | 34.574324 | 67 | 0.604065 |
2dc102802d9ae34a2d04e2d9f5c68f1bb09bad45 | 7,031 | py | Python | modules/database.py | MrEluzium/UlvicationBot | 87a591726161166072f59306175c1c7ef5a7f713 | [
"Apache-2.0"
] | null | null | null | modules/database.py | MrEluzium/UlvicationBot | 87a591726161166072f59306175c1c7ef5a7f713 | [
"Apache-2.0"
] | null | null | null | modules/database.py | MrEluzium/UlvicationBot | 87a591726161166072f59306175c1c7ef5a7f713 | [
"Apache-2.0"
] | null | null | null | # Copyright 2020
#
# 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 writing, software
#... | 37.005263 | 150 | 0.582563 |
2dc2a50bc68f5c4de74bd70134b3c6049945496f | 1,203 | py | Python | common-mk/mojom_bindings_generator_wrapper.py | strassek/chromiumos-platform2 | 12c953f41f48b8a6b0bd1c181d09bdb1de38325c | [
"BSD-3-Clause"
] | 4 | 2020-07-24T06:54:16.000Z | 2021-06-16T17:13:53.000Z | common-mk/mojom_bindings_generator_wrapper.py | strassek/chromiumos-platform2 | 12c953f41f48b8a6b0bd1c181d09bdb1de38325c | [
"BSD-3-Clause"
] | 1 | 2021-04-02T17:35:07.000Z | 2021-04-02T17:35:07.000Z | common-mk/mojom_bindings_generator_wrapper.py | strassek/chromiumos-platform2 | 12c953f41f48b8a6b0bd1c181d09bdb1de38325c | [
"BSD-3-Clause"
] | 1 | 2020-11-04T22:31:45.000Z | 2020-11-04T22:31:45.000Z | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
#
# Copyright 2018 The Chromium OS Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""Thin wrapper of Mojo's mojom_bindings_generator.py.
To generate C++ files from mojom, it is necessary... | 30.075 | 77 | 0.73483 |
2dc525d7b867d2625c1781dd2d072f7fa9a50ee6 | 4,799 | py | Python | script.module.placenta/lib/resources/lib/sources/en/to_be_fixed/sitedown/onlinemovies.py | parser4life/tantrumrepo | 3b37145f4772409e538cbddb0b7aa23be525772a | [
"Beerware"
] | 1 | 2021-05-09T19:55:51.000Z | 2021-05-09T19:55:51.000Z | script.module.placenta/lib/resources/lib/sources/en/to_be_fixed/sitedown/onlinemovies.py | parser4life/tantrumrepo | 3b37145f4772409e538cbddb0b7aa23be525772a | [
"Beerware"
] | null | null | null | script.module.placenta/lib/resources/lib/sources/en/to_be_fixed/sitedown/onlinemovies.py | parser4life/tantrumrepo | 3b37145f4772409e538cbddb0b7aa23be525772a | [
"Beerware"
] | 2 | 2020-04-01T22:11:12.000Z | 2020-05-07T23:54:52.000Z | # NEEDS FIXING
# -*- coding: UTF-8 -*-
#######################################################################
# ----------------------------------------------------------------------------
# "THE BEER-WARE LICENSE" (Revision 42):
# @tantrumdev wrote this file. As long as you retain this notice you
# can do whate... | 34.52518 | 182 | 0.470723 |
2dc6b64392d41e06755147486243708c0cbcc454 | 2,362 | py | Python | venv/src/pages/forms.py | ddelgadoJS/ProyectoWeb | f899c910bf16a79d5c3498bc6e8aa6b741fb56e1 | [
"MIT"
] | 1 | 2019-10-28T03:44:38.000Z | 2019-10-28T03:44:38.000Z | venv/src/pages/forms.py | ddelgadoJS/ProyectoWeb | f899c910bf16a79d5c3498bc6e8aa6b741fb56e1 | [
"MIT"
] | null | null | null | venv/src/pages/forms.py | ddelgadoJS/ProyectoWeb | f899c910bf16a79d5c3498bc6e8aa6b741fb56e1 | [
"MIT"
] | null | null | null | from django import forms
from django.contrib.auth.models import User
from django.contrib.auth.forms import UserCreationForm
from .models import * | 22.495238 | 54 | 0.453006 |
2dc76e500ca4b409bef1091d33217d948f97e80c | 5,639 | py | Python | tests/test_connections.py | iparaskev/py_connect | 43476cddfb25130d058fcf59928454f867af8feb | [
"BSD-3-Clause"
] | 5 | 2021-03-19T07:05:50.000Z | 2021-03-31T22:53:52.000Z | tests/test_connections.py | iparaskev/py_connect | 43476cddfb25130d058fcf59928454f867af8feb | [
"BSD-3-Clause"
] | null | null | null | tests/test_connections.py | iparaskev/py_connect | 43476cddfb25130d058fcf59928454f867af8feb | [
"BSD-3-Clause"
] | null | null | null | """test_connections.py"""
import unittest
import os
from py_connect import ConnectionsHandler
from py_connect import Board, Peripheral, SensorTypes
cons_path = \
"/".join(os.path.abspath(__file__).split("/")[:-2]) + "/test_connections/"
if __name__ == "__main__":
unittest.main()
| 45.845528 | 83 | 0.597446 |
2dc9476cbdfe54502530421ec62dd23ee2ee1011 | 4,624 | py | Python | p3iv_utils/src/p3iv_utils/coordinate_transformation.py | fzi-forschungszentrum-informatik/P3IV | 51784e6dc03dcaa0ad58a5078475fa4daec774bd | [
"BSD-3-Clause"
] | 4 | 2021-07-27T06:56:22.000Z | 2022-03-22T11:21:30.000Z | p3iv_utils/src/p3iv_utils/coordinate_transformation.py | fzi-forschungszentrum-informatik/P3IV | 51784e6dc03dcaa0ad58a5078475fa4daec774bd | [
"BSD-3-Clause"
] | null | null | null | p3iv_utils/src/p3iv_utils/coordinate_transformation.py | fzi-forschungszentrum-informatik/P3IV | 51784e6dc03dcaa0ad58a5078475fa4daec774bd | [
"BSD-3-Clause"
] | 1 | 2021-10-10T01:56:44.000Z | 2021-10-10T01:56:44.000Z | # This file is part of the P3IV Simulator (https://github.com/fzi-forschungszentrum-informatik/P3IV),
# copyright by FZI Forschungszentrum Informatik, licensed under the BSD-3 license (see LICENSE file in main directory)
import numpy as np
import lanelet2.geometry
from lanelet2.core import BasicPoint2d, LaneletSequenc... | 39.186441 | 118 | 0.640138 |
2dc96003810a3b3ddd4e4137fa58deb740206c23 | 668 | py | Python | web/pyserver/workers/board/views/board.py | abhatikar/training_extensions | 1c96e0f5f39688f8b79735e8dfa90646afc3d5e6 | [
"Apache-2.0"
] | 2 | 2021-01-07T05:09:17.000Z | 2021-10-15T05:13:46.000Z | web/pyserver/workers/board/views/board.py | abhatikar/training_extensions | 1c96e0f5f39688f8b79735e8dfa90646afc3d5e6 | [
"Apache-2.0"
] | 9 | 2021-09-08T03:12:59.000Z | 2022-03-12T00:57:19.000Z | web/pyserver/workers/board/views/board.py | abhatikar/training_extensions | 1c96e0f5f39688f8b79735e8dfa90646afc3d5e6 | [
"Apache-2.0"
] | null | null | null | import aiohttp_cors
from aiohttp import web
from common.utils.run_cmd import run
| 29.043478 | 103 | 0.637725 |
2dca7a410a4b4fc054c136085f57855c6543b78e | 716 | py | Python | molecule/default/tests/test_role.py | boutetnico/ansible-role-nodejs | de9d70556decbf76d9a939499c42edc85e2d65e8 | [
"MIT"
] | null | null | null | molecule/default/tests/test_role.py | boutetnico/ansible-role-nodejs | de9d70556decbf76d9a939499c42edc85e2d65e8 | [
"MIT"
] | null | null | null | molecule/default/tests/test_role.py | boutetnico/ansible-role-nodejs | de9d70556decbf76d9a939499c42edc85e2d65e8 | [
"MIT"
] | null | null | null | import pytest
import os
import testinfra.utils.ansible_runner
testinfra_hosts = testinfra.utils.ansible_runner.AnsibleRunner(
os.environ['MOLECULE_INVENTORY_FILE']).get_hosts('all')
| 23.866667 | 63 | 0.699721 |
2dcaf1c764e04a5631433a84042c46eeee80f0f9 | 28 | py | Python | losses/__init__.py | xieqk/SEF | 2163a159933d8d9ecad5ff9341cfa626f662a778 | [
"MIT"
] | null | null | null | losses/__init__.py | xieqk/SEF | 2163a159933d8d9ecad5ff9341cfa626f662a778 | [
"MIT"
] | null | null | null | losses/__init__.py | xieqk/SEF | 2163a159933d8d9ecad5ff9341cfa626f662a778 | [
"MIT"
] | null | null | null | from .ranking import Triplet | 28 | 28 | 0.857143 |
2dcbf62d4bf655fa54c52c4d475fe511450f1255 | 1,216 | py | Python | GTFtools.py | zhenglabuthscsa/PRADA2 | d050971dc6e0a8ab11f8575787b2f4848502ed21 | [
"MIT"
] | null | null | null | GTFtools.py | zhenglabuthscsa/PRADA2 | d050971dc6e0a8ab11f8575787b2f4848502ed21 | [
"MIT"
] | null | null | null | GTFtools.py | zhenglabuthscsa/PRADA2 | d050971dc6e0a8ab11f8575787b2f4848502ed21 | [
"MIT"
] | 1 | 2021-10-18T23:44:54.000Z | 2021-10-18T23:44:54.000Z | """
created by Juechen Yang at 1/8/19
"""
import os
import pandas as pd
| 46.769231 | 133 | 0.563322 |
2dcc54fe3a394449dcf9c0f9b37aad39578e1f30 | 8,767 | py | Python | dlclabel/io.py | jonmatthis/napari-DeepLabCut | 90e2fd230d9f4ab493698c619e976235df4adfeb | [
"MIT"
] | null | null | null | dlclabel/io.py | jonmatthis/napari-DeepLabCut | 90e2fd230d9f4ab493698c619e976235df4adfeb | [
"MIT"
] | null | null | null | dlclabel/io.py | jonmatthis/napari-DeepLabCut | 90e2fd230d9f4ab493698c619e976235df4adfeb | [
"MIT"
] | null | null | null | import glob
import numpy as np
import os
import pandas as pd
import yaml
from dask_image.imread import imread
from dlclabel import misc
from itertools import groupby
from napari.layers import Shapes
from napari.plugins._builtins import napari_write_shapes
from napari.types import LayerData
from skimage.io import imsave... | 37.306383 | 89 | 0.603399 |
2dcde6f1aeb6275a870472422f2f2e32d94b6cf9 | 537 | py | Python | mathematics/reverse-integer.py | Neulana/leetcode | 734078378f125a24d049061a34995c90b15cac43 | [
"Apache-2.0"
] | 2 | 2018-12-20T13:58:16.000Z | 2019-11-12T09:42:07.000Z | mathematics/reverse-integer.py | Neulana/leetcode | 734078378f125a24d049061a34995c90b15cac43 | [
"Apache-2.0"
] | null | null | null | mathematics/reverse-integer.py | Neulana/leetcode | 734078378f125a24d049061a34995c90b15cac43 | [
"Apache-2.0"
] | null | null | null | """
32
1:
: 123
: 321
2:
: -123
: -321
3:
: 120
: 21
:
32 [2**31, 2**31 1] 0
"""
| 14.916667 | 74 | 0.458101 |
2dcefc70c84d3f4061e0e716788bdf5dca8ba63f | 74 | py | Python | lib/datatools/build/__init__.py | JokerWDL/PyAnomaly | cf93437e5d7ae87fa916141cf4b5cc2e929b8199 | [
"Apache-2.0"
] | 1 | 2020-11-22T17:55:10.000Z | 2020-11-22T17:55:10.000Z | lib/datatools/build/__init__.py | JokerWDL/PyAnomaly | cf93437e5d7ae87fa916141cf4b5cc2e929b8199 | [
"Apache-2.0"
] | null | null | null | lib/datatools/build/__init__.py | JokerWDL/PyAnomaly | cf93437e5d7ae87fa916141cf4b5cc2e929b8199 | [
"Apache-2.0"
] | null | null | null | from .. import dataclass # trigger the register in the dataclass package
| 37 | 73 | 0.783784 |
2dcf7a1623416f9f81a559b63f8c49bc133ec199 | 46,393 | py | Python | src/github3/repos/branch.py | thebrid/github3.py | 1d2d0dbd67576e3b399ffdf21f29f85b467da245 | [
"BSD-3-Clause"
] | null | null | null | src/github3/repos/branch.py | thebrid/github3.py | 1d2d0dbd67576e3b399ffdf21f29f85b467da245 | [
"BSD-3-Clause"
] | null | null | null | src/github3/repos/branch.py | thebrid/github3.py | 1d2d0dbd67576e3b399ffdf21f29f85b467da245 | [
"BSD-3-Clause"
] | null | null | null | """Implementation of a branch on a repository."""
import typing as t
from . import commit
from .. import decorators
from .. import models
if t.TYPE_CHECKING:
from .. import apps as tapps
from .. import users as tusers
from . import orgs
def users(
self, number: int = -1
) -> t.Gener... | 34.673393 | 115 | 0.633371 |
2dd0dbf3c9583810719a7c459b8980e6849b03e3 | 696 | py | Python | buildings/gui/menu_frame.py | strk/nz-buildings | 8dc8ee19d322837380bb4f016b01eccee2c1bd0a | [
"PostgreSQL",
"CC-BY-4.0"
] | 2 | 2020-02-21T00:46:31.000Z | 2020-08-17T14:22:19.000Z | buildings/gui/menu_frame.py | strk/nz-buildings | 8dc8ee19d322837380bb4f016b01eccee2c1bd0a | [
"PostgreSQL",
"CC-BY-4.0"
] | 243 | 2018-12-16T22:01:54.000Z | 2022-01-10T20:09:24.000Z | buildings/gui/menu_frame.py | strk/nz-buildings | 8dc8ee19d322837380bb4f016b01eccee2c1bd0a | [
"PostgreSQL",
"CC-BY-4.0"
] | 1 | 2020-03-24T10:35:43.000Z | 2020-03-24T10:35:43.000Z | # -*- coding: utf-8 -*-
import os.path
from qgis.PyQt import uic
from qgis.PyQt.QtWidgets import QFrame
from buildings.utilities.layers import LayerRegistry
# Get the path for the parent directory of this file.
__location__ = os.path.realpath(os.path.join(os.getcwd(), os.path.dirname(__file__)))
FORM_CLASS, _ = ui... | 27.84 | 88 | 0.719828 |
2dd15aa32b6924458b8fe69007859df334c4b9ae | 1,426 | py | Python | helpers.py | denizumutdereli/dialogflow_nlp_ai_powered_chat_bot | e624927527a32f21763d23cd585c868fe9190211 | [
"Apache-2.0"
] | 1 | 2022-01-13T00:35:20.000Z | 2022-01-13T00:35:20.000Z | helpers.py | denizumutdereli/dialogflow_nlp_ai_powered_chat_bot | e624927527a32f21763d23cd585c868fe9190211 | [
"Apache-2.0"
] | null | null | null | helpers.py | denizumutdereli/dialogflow_nlp_ai_powered_chat_bot | e624927527a32f21763d23cd585c868fe9190211 | [
"Apache-2.0"
] | null | null | null | import os
import sys
import re
import emoji
import string
import time
import winsound
from bs4 import BeautifulSoup
from rich.progress import track
| 25.464286 | 64 | 0.674614 |
2dd1642cbad2de85e44adff8bc936f9819e814e3 | 3,749 | py | Python | gitver/config.py | movermeyer/gitver | 77d5a4420209a4ca00349b094eeca1f13e50d8e5 | [
"Apache-2.0"
] | 12 | 2015-03-31T18:19:42.000Z | 2019-08-14T10:56:00.000Z | gitver/config.py | movermeyer/gitver | 77d5a4420209a4ca00349b094eeca1f13e50d8e5 | [
"Apache-2.0"
] | 1 | 2015-04-21T12:44:40.000Z | 2019-07-15T07:12:15.000Z | gitver/config.py | movermeyer/gitver | 77d5a4420209a4ca00349b094eeca1f13e50d8e5 | [
"Apache-2.0"
] | 8 | 2016-03-25T16:43:13.000Z | 2021-11-26T10:44:57.000Z | #!/usr/bin/env python2
# coding=utf-8
"""
The default per-repository configuration
"""
import sys
import json
import string
from os.path import exists, dirname
from gitver.defines import CFGFILE
from termcolors import term, bold
default_config_text = """{
# automatically generated configuration file
#
# ... | 31.771186 | 148 | 0.654308 |
2dd2a210c5e9a90b7a25257a08a7c3946145f326 | 3,153 | py | Python | oracle/TLOracle/property_R2_2.py | fatmaf/ROSMonitoring | 25eb3142d697d307bb2fd33af9bf4cd5191c5b42 | [
"MIT",
"BSD-3-Clause"
] | 11 | 2020-02-18T18:51:01.000Z | 2022-03-16T12:18:51.000Z | oracle/TLOracle/property_R2_2.py | fatmaf/ROSMonitoring | 25eb3142d697d307bb2fd33af9bf4cd5191c5b42 | [
"MIT",
"BSD-3-Clause"
] | 6 | 2020-02-03T15:34:49.000Z | 2020-02-05T15:58:37.000Z | oracle/TLOracle/property_R2_2.py | fatmaf/ROSMonitoring | 25eb3142d697d307bb2fd33af9bf4cd5191c5b42 | [
"MIT",
"BSD-3-Clause"
] | 2 | 2021-10-06T13:37:47.000Z | 2022-03-24T16:27:15.000Z | # MIT License
#
# Copyright (c) [2020] [Angelo Ferrando]
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify,... | 64.346939 | 623 | 0.693942 |
2dd344951d9aeadc827ae7e0e3e8b87cd96497d0 | 3,305 | py | Python | 3. Others/Python_OOP_Passenger_Registration.py | PurveshMakode24/snippets | ba360b363c7b98528d6b7320dcc446a9e3febd4b | [
"MIT"
] | 1 | 2018-12-25T21:10:02.000Z | 2018-12-25T21:10:02.000Z | 3. Others/Python_OOP_Passenger_Registration.py | PurveshMakode24/snippets | ba360b363c7b98528d6b7320dcc446a9e3febd4b | [
"MIT"
] | 2 | 2019-10-01T16:07:46.000Z | 2019-10-01T16:07:47.000Z | 3. Others/Python_OOP_Passenger_Registration.py | PurveshMakode24/snippets | ba360b363c7b98528d6b7320dcc446a9e3febd4b | [
"MIT"
] | 4 | 2020-09-01T02:22:44.000Z | 2020-10-07T12:14:58.000Z | from random import randint
import re; import json
def displayPassengers(passengerList):
if len(passengerList):
print(json.dumps([p.__dict__ for p in passengerList], indent=4))
else:
print("\nNo data found.")
def registration(passengerList):
try:
passengerId = int... | 30.601852 | 117 | 0.586082 |
2dd39dc7304ad676d501a32885e968d0740bdaf7 | 1,379 | py | Python | software/examples/python/03-multiplexer/main.py | esysberlin/lufo-ifez-datenkonzentrator | f803724b316e2df46e69afab91afa22c64a8d920 | [
"MIT"
] | 2 | 2019-02-04T16:04:29.000Z | 2019-02-04T23:33:12.000Z | software/examples/python/03-multiplexer/main.py | esysberlin/lufo-ifez-datenkonzentrator | f803724b316e2df46e69afab91afa22c64a8d920 | [
"MIT"
] | null | null | null | software/examples/python/03-multiplexer/main.py | esysberlin/lufo-ifez-datenkonzentrator | f803724b316e2df46e69afab91afa22c64a8d920 | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
import random
from common import spi
_MULTIPLEXER_INPUTS = ['A1', 'A2', 'A3', 'A4', 'A5', 'A6', 'A7', 'A8',
'B1', 'B2', 'B3', 'B4', 'B5', 'B6', 'B7', 'B8']
_MULTIPLEXER_OUTPUTS = ['OUT_A', 'OUT_B']
if __name__ == '__main__':
main()
| 28.729167 | 88 | 0.641769 |
2dd735db2a02bcc45cec0aa0e3b52d0a3bae2b8e | 118 | py | Python | test/a.py | atsuoishimoto/pyjf3 | 6f4b22e24c8f3bae5120b00e1de86e66fabb1785 | [
"Unlicense"
] | null | null | null | test/a.py | atsuoishimoto/pyjf3 | 6f4b22e24c8f3bae5120b00e1de86e66fabb1785 | [
"Unlicense"
] | 2 | 2015-10-01T20:41:28.000Z | 2016-03-14T14:50:41.000Z | test/a.py | atsuoishimoto/pyjf3 | 6f4b22e24c8f3bae5120b00e1de86e66fabb1785 | [
"Unlicense"
] | null | null | null | # -*- coding: utf-8 -*-
import pyjf
print repr(u''.encode('euc-jp'))
print repr(pyjf.sjistoeuc(u''.encode('sjis')))
| 23.6 | 47 | 0.644068 |
2dd802a334b7dcb54120950c7e4f4e6a2c7dc01e | 437 | py | Python | rl_sandbox/priors/uniform.py | chanb/rl_sandbox_public | e55f954a29880f83a5b0c3358badda4d900f1564 | [
"MIT"
] | 14 | 2020-11-09T22:05:37.000Z | 2022-02-11T12:41:33.000Z | rl_sandbox/priors/uniform.py | chanb/rl_sandbox_public | e55f954a29880f83a5b0c3358badda4d900f1564 | [
"MIT"
] | null | null | null | rl_sandbox/priors/uniform.py | chanb/rl_sandbox_public | e55f954a29880f83a5b0c3358badda4d900f1564 | [
"MIT"
] | null | null | null | import torch
from torch.distributions import Uniform
from rl_sandbox.constants import CPU
| 24.277778 | 74 | 0.709382 |
2dd8addc613d001e1bcad53b369e5ef7379a46b5 | 2,759 | py | Python | preprocess/conll_to_factors.py | thilakshiK/wmt16-scripts | 7fa32971e2927c397434df2e0f171834abf0b07a | [
"MIT"
] | 132 | 2016-05-20T15:59:48.000Z | 2022-03-30T13:58:50.000Z | preprocess/conll_to_factors.py | chenyangh/wmt16-scripts | 9695851c150fedbac3418915b251a75292d7d527 | [
"MIT"
] | 14 | 2016-07-14T16:14:14.000Z | 2022-02-16T18:49:18.000Z | preprocess/conll_to_factors.py | chenyangh/wmt16-scripts | 9695851c150fedbac3418915b251a75292d7d527 | [
"MIT"
] | 66 | 2016-05-17T06:27:16.000Z | 2022-02-24T13:14:29.000Z | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# Author: Rico Sennrich
# Distributed under MIT license
# take conll file, and bpe-segmented text, and produce factored output
import sys
import re
from collections import namedtuple
Word = namedtuple(
'Word',
['pos', 'word', 'lemma', 'tag', 'morph', 'head', 'f... | 24.415929 | 130 | 0.507068 |
2dd8b59c63a68dfdad978b1ecaee6cd2d1f63d54 | 4,661 | py | Python | Training/Auto_Labelling/tests/test_utils.py | evamok/knowledge-extraction-recipes-forms | d42dc5a728d72fabc6a0c568834ef6786deb9116 | [
"MIT"
] | 93 | 2020-08-03T10:23:43.000Z | 2022-03-23T15:41:22.000Z | Training/Auto_Labelling/tests/test_utils.py | ciph3rwoman/knowledge-extraction-recipes-forms | ce1adbb0515d1b598ba89a4a06dd3cf554230565 | [
"MIT"
] | 11 | 2020-08-05T06:49:21.000Z | 2022-02-01T10:00:25.000Z | Training/Auto_Labelling/tests/test_utils.py | ciph3rwoman/knowledge-extraction-recipes-forms | ce1adbb0515d1b598ba89a4a06dd3cf554230565 | [
"MIT"
] | 39 | 2020-08-05T14:48:43.000Z | 2022-02-12T05:12:11.000Z | #!/usr/bin/python
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License.
import pytest
import os
import json
from mock import MagicMock, patch, mock_open
from shared_code import utils
def test_get_lookup_fields_raises_exception_when_None_passed_in():
#arrange
input = N... | 23.780612 | 91 | 0.692341 |
2ddb711319d2de41b35803baad0302688374879f | 1,600 | py | Python | plots/plottingcompare.py | HPQC-LABS/Quantum-Graph-Spectra | b897d94dd03c48ffec5735b3dc5b86f8c3ab5a8f | [
"MIT"
] | 1 | 2020-07-29T06:42:32.000Z | 2020-07-29T06:42:32.000Z | plots/plottingcompare.py | HPQC-LABS/Quantum-Graph-Spectra | b897d94dd03c48ffec5735b3dc5b86f8c3ab5a8f | [
"MIT"
] | null | null | null | plots/plottingcompare.py | HPQC-LABS/Quantum-Graph-Spectra | b897d94dd03c48ffec5735b3dc5b86f8c3ab5a8f | [
"MIT"
] | 2 | 2021-03-29T13:40:47.000Z | 2021-03-29T13:41:00.000Z | '''
@author: Josh Payne
Description: For creating multiple overlaid charts
'''
from mpl_toolkits.axes_grid1 import host_subplot
import mpl_toolkits.axisartist as AA
import matplotlib.pyplot as plt
import numpy as np
### Get values from performance.py, input here ###
x = [4, 5, 8, 9, 16, 32, 64]
lst = [(2.585895228... | 30.769231 | 302 | 0.71 |
2ddc43ce9995edf0340e08d59a52ccaf4be2ad42 | 804 | py | Python | pulse2percept/datasets/__init__.py | pulse2percept/pulse2percept | 67e0f2354db5ebe306b617f7f78a9ea8c02327ac | [
"BSD-3-Clause"
] | 40 | 2019-11-01T14:09:34.000Z | 2022-02-28T19:08:01.000Z | pulse2percept/datasets/__init__.py | jgranley/pulse2percept | 65c11393a33d1531cd02a3e38243414bf8172e9a | [
"BSD-3-Clause"
] | 277 | 2019-11-22T03:30:31.000Z | 2022-03-28T00:11:03.000Z | pulse2percept/datasets/__init__.py | jgranley/pulse2percept | 65c11393a33d1531cd02a3e38243414bf8172e9a | [
"BSD-3-Clause"
] | 31 | 2020-01-22T06:36:36.000Z | 2022-01-20T09:54:25.000Z | """Utilities to download and import datasets.
* **Dataset loaders** can be used to load small datasets that come
pre-packaged with the pulse2percept software.
* **Dataset fetchers** can be used to download larger datasets from a given
URL and directly import them into pulse2percept.
.. autosummary::
:toct... | 22.333333 | 76 | 0.726368 |
2ddca5cc12de3a408cda0ff45249cbd6d8e54333 | 7,452 | py | Python | pysnmp-with-texts/TIMETRA-SAS-IEEE8021-PAE-MIB.py | agustinhenze/mibs.snmplabs.com | 1fc5c07860542b89212f4c8ab807057d9a9206c7 | [
"Apache-2.0"
] | 8 | 2019-05-09T17:04:00.000Z | 2021-06-09T06:50:51.000Z | pysnmp-with-texts/TIMETRA-SAS-IEEE8021-PAE-MIB.py | agustinhenze/mibs.snmplabs.com | 1fc5c07860542b89212f4c8ab807057d9a9206c7 | [
"Apache-2.0"
] | 4 | 2019-05-31T16:42:59.000Z | 2020-01-31T21:57:17.000Z | pysnmp-with-texts/TIMETRA-SAS-IEEE8021-PAE-MIB.py | agustinhenze/mibs.snmplabs.com | 1fc5c07860542b89212f4c8ab807057d9a9206c7 | [
"Apache-2.0"
] | 10 | 2019-04-30T05:51:36.000Z | 2022-02-16T03:33:41.000Z | #
# PySNMP MIB module TIMETRA-SAS-IEEE8021-PAE-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/TIMETRA-SAS-IEEE8021-PAE-MIB
# Produced by pysmi-0.3.4 at Wed May 1 15:21:45 2019
# On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4
# Using Python vers... | 143.307692 | 1,076 | 0.800322 |
2ddf7737c3560fadbc544f9a488716622f8551b0 | 7,093 | py | Python | pipeline/mk_all_level1_fsf_bbr.py | lbconner/openfMRI | 265d8ef013dad14fd1741d5817d00f9411d85103 | [
"BSD-2-Clause"
] | 33 | 2015-02-17T17:21:43.000Z | 2021-08-23T08:27:10.000Z | pipeline/mk_all_level1_fsf_bbr.py | lbconner/openfMRI | 265d8ef013dad14fd1741d5817d00f9411d85103 | [
"BSD-2-Clause"
] | 13 | 2015-01-14T15:17:09.000Z | 2017-07-10T02:17:06.000Z | pipeline/mk_all_level1_fsf_bbr.py | lbconner/openfMRI | 265d8ef013dad14fd1741d5817d00f9411d85103 | [
"BSD-2-Clause"
] | 24 | 2015-01-27T10:02:47.000Z | 2021-03-19T20:05:35.000Z | #!/usr/bin/env python
""" mk_all_level1_fsf.py - make fsf files for all subjects
USAGE: python mk_all_level1_fsf_bbr.py <name of dataset> <modelnum> <basedir - default is staged> <nonlinear - default=1> <smoothing - default=0> <tasknum - default to all>
"""
## Copyright 2011, Russell Poldrack. All rights reserved.
... | 41.238372 | 172 | 0.661638 |
2de03c9b6f61130c7a0de0bbdb46eed6409dcbac | 2,492 | py | Python | gettweets.py | ketankokane94/twitter-analysis | 7820fe7d3350af5066799c7540352993b1ecc36c | [
"MIT"
] | null | null | null | gettweets.py | ketankokane94/twitter-analysis | 7820fe7d3350af5066799c7540352993b1ecc36c | [
"MIT"
] | null | null | null | gettweets.py | ketankokane94/twitter-analysis | 7820fe7d3350af5066799c7540352993b1ecc36c | [
"MIT"
] | null | null | null | import tweepy
import csv
if __name__ == '__main__':
t = dealWithTwitter()
t.loadTokens()
t.get_all_tweets('realDonaldTrump')
# t.connectToTwitter()
| 38.338462 | 105 | 0.611156 |
2de11305e60f62768eeb9919ec2876747df54327 | 22,175 | py | Python | main.py | Swaraj-Deep/UAV-GRN-DRN | f18fe05751794bc7530b58312f6fadacb1e4a500 | [
"MIT"
] | 1 | 2020-06-16T11:27:30.000Z | 2020-06-16T11:27:30.000Z | main.py | Swaraj-Deep/UAV-GRN-DRN | f18fe05751794bc7530b58312f6fadacb1e4a500 | [
"MIT"
] | null | null | null | main.py | Swaraj-Deep/UAV-GRN-DRN | f18fe05751794bc7530b58312f6fadacb1e4a500 | [
"MIT"
] | null | null | null | import json
import random
import numpy as np
import os
import time
import os.path
import networkx as nx
import users_endpoint.users
import grn_endpoint.grn_info
import move_endpoint.movement
import reward_endpoint.rewards
import matplotlib.pyplot as plt
from matplotlib.backends.backend_pdf import PdfPages
# Global var... | 35.48 | 309 | 0.659436 |
2de4906cd9dd45c4ba1ae99f800a8a5ed211db6d | 2,384 | py | Python | tests/work_with_gdscript/test_native_call.py | curradium/godot-python | 11355dfd03a3dad80253b49c532fbb61a8b26d98 | [
"CC-BY-3.0"
] | null | null | null | tests/work_with_gdscript/test_native_call.py | curradium/godot-python | 11355dfd03a3dad80253b49c532fbb61a8b26d98 | [
"CC-BY-3.0"
] | null | null | null | tests/work_with_gdscript/test_native_call.py | curradium/godot-python | 11355dfd03a3dad80253b49c532fbb61a8b26d98 | [
"CC-BY-3.0"
] | null | null | null | # TODO:
# - allow inheritance from GDScript class
# - overload native method ?
import pytest
from godot.bindings import ResourceLoader, GDScript, PluginScript
| 23.145631 | 72 | 0.693372 |
2de4ee5bc7351ca57d213412fccfba40eb972d36 | 1,880 | py | Python | tests/python/unittest/test_arith_stmt_simplify.py | ndl/tvm | 6e4c6d7a3a840ae1f7f996c856357068ba7c68ee | [
"Apache-2.0"
] | 15 | 2019-05-02T00:06:28.000Z | 2022-03-25T03:11:14.000Z | tests/python/unittest/test_arith_stmt_simplify.py | ndl/tvm | 6e4c6d7a3a840ae1f7f996c856357068ba7c68ee | [
"Apache-2.0"
] | 5 | 2019-05-13T20:44:51.000Z | 2019-09-25T19:56:29.000Z | tests/python/unittest/test_arith_stmt_simplify.py | ndl/tvm | 6e4c6d7a3a840ae1f7f996c856357068ba7c68ee | [
"Apache-2.0"
] | 5 | 2019-03-06T19:54:18.000Z | 2022-02-01T14:27:58.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... | 35.471698 | 62 | 0.685106 |
2de6561887dd2c5980bf1f012aa5a1b51a0aef2b | 3,350 | py | Python | worker/worker.py | cshenton/neuroevolution | 12f0d52513b2d9a91c96f9a4d9b4aafab1d95fe8 | [
"MIT"
] | 45 | 2018-04-18T21:37:12.000Z | 2020-09-28T22:35:08.000Z | worker/worker.py | cshenton/neuroevolution | 12f0d52513b2d9a91c96f9a4d9b4aafab1d95fe8 | [
"MIT"
] | null | null | null | worker/worker.py | cshenton/neuroevolution | 12f0d52513b2d9a91c96f9a4d9b4aafab1d95fe8 | [
"MIT"
] | 10 | 2018-04-19T10:13:03.000Z | 2022-02-02T14:06:59.000Z | """The Worker class, which manages running policy evaluations."""
import datetime
import grpc
import gym
import os
from google.protobuf import empty_pb2
from proto.neuroevolution_pb2 import Evaluation, Individual
from proto.neuroevolution_pb2_grpc import NeuroStub
from worker.policy import Policy
ENVIRONMENT = os.ge... | 32.211538 | 84 | 0.584478 |
2de6c51e3b98221f5e9ca7c29a7762f77132e57d | 836 | py | Python | CAP4-Case study_interface design/docstring.py | falble/mythinkpython2 | 25de15c8657f32a8f85189d9cb0588c816e9e7d3 | [
"Apache-2.0"
] | 1 | 2020-11-20T16:28:32.000Z | 2020-11-20T16:28:32.000Z | CAP4-Case study_interface design/docstring.py | falble/mythinkpython2 | 25de15c8657f32a8f85189d9cb0588c816e9e7d3 | [
"Apache-2.0"
] | null | null | null | CAP4-Case study_interface design/docstring.py | falble/mythinkpython2 | 25de15c8657f32a8f85189d9cb0588c816e9e7d3 | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
"""
Created on Sat Feb 16 17:05:36 2019
@author: Utente
"""
#Chapter 4
#docstring
import turtle
import math
bob = turtle.Turtle()
print(bob)
def polyline(t, n, lenght, angle):
#documentation string--->
"""Draws n line segments with the given lenght
and angle... | 25.333333 | 102 | 0.62201 |
2de89c57ba2b6a38a0def3e77a44733886f67fe3 | 378 | py | Python | Day02/part2.py | JavierRizzoA/AoC2021 | 948177b135f2570090cd3a13aafaa0199566248a | [
"Beerware"
] | null | null | null | Day02/part2.py | JavierRizzoA/AoC2021 | 948177b135f2570090cd3a13aafaa0199566248a | [
"Beerware"
] | null | null | null | Day02/part2.py | JavierRizzoA/AoC2021 | 948177b135f2570090cd3a13aafaa0199566248a | [
"Beerware"
] | null | null | null | x = 0
y = 0
aim = 0
with open('input') as f:
for line in f:
direction = line.split()[0]
magnitude = int(line.split()[1])
if direction == 'forward':
x += magnitude
y += aim * magnitude
elif direction == 'down':
aim += magnitude
elif directio... | 23.625 | 40 | 0.481481 |
2de8dc7fc9d8a2753db8ec50c0b95c8f4645d196 | 2,329 | py | Python | ddd_domain_driven_design/application/dto/generalisation/dtometa.py | pidevops/py-domain-driven-design | 86f5743e5a37628a2146e62bebd4489a93ad8f16 | [
"MIT"
] | 2 | 2019-11-14T15:10:00.000Z | 2020-05-12T07:33:37.000Z | ddd_domain_driven_design/application/dto/generalisation/dtometa.py | pidevops/py-domain-driven-design | 86f5743e5a37628a2146e62bebd4489a93ad8f16 | [
"MIT"
] | null | null | null | ddd_domain_driven_design/application/dto/generalisation/dtometa.py | pidevops/py-domain-driven-design | 86f5743e5a37628a2146e62bebd4489a93ad8f16 | [
"MIT"
] | null | null | null | from . import type_checker
from .dtodescriptor import DTODescriptor
| 43.943396 | 119 | 0.522542 |
2de971a92eef57fed46cbae27fb964015248a42c | 10,158 | py | Python | model.py | r-or/cnn-eyetrack | 93a09f209aa8d34defc82c8734d35d5ce56b9060 | [
"MIT"
] | null | null | null | model.py | r-or/cnn-eyetrack | 93a09f209aa8d34defc82c8734d35d5ce56b9060 | [
"MIT"
] | null | null | null | model.py | r-or/cnn-eyetrack | 93a09f209aa8d34defc82c8734d35d5ce56b9060 | [
"MIT"
] | null | null | null | #!/usr/bin/python3
import json
import pprint
import sys
import os
import numpy as np
import traceback
import random
import argparse
import json
import tensorflow
import keras
from keras import optimizers
from keras.models import Sequential
from keras.models import load_model
from keras.layers import Conv2D, MaxPooling... | 35.767606 | 137 | 0.641366 |
2dea338f874c3ce26ae59e17c28ac999a26659a9 | 43,498 | py | Python | ec2driver.py | venumurthy/ec2-driver | 65b0482af3af80e34c00c327f54487d492933b25 | [
"Apache-2.0"
] | null | null | null | ec2driver.py | venumurthy/ec2-driver | 65b0482af3af80e34c00c327f54487d492933b25 | [
"Apache-2.0"
] | null | null | null | ec2driver.py | venumurthy/ec2-driver | 65b0482af3af80e34c00c327f54487d492933b25 | [
"Apache-2.0"
] | null | null | null | # vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright (c) 2014 Thoughtworks.
#
# 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
#
#... | 43.324701 | 161 | 0.635271 |
2dec3a7fdb0143127ec3b1adee9a1d3e5ba90910 | 1,239 | py | Python | output/models/ms_data/additional/isdefault072_xsd/isdefault072.py | tefra/xsdata-w3c-tests | b6b6a4ac4e0ab610e4b50d868510a8b7105b1a5f | [
"MIT"
] | 1 | 2021-08-14T17:59:21.000Z | 2021-08-14T17:59:21.000Z | output/models/ms_data/additional/isdefault072_xsd/isdefault072.py | tefra/xsdata-w3c-tests | b6b6a4ac4e0ab610e4b50d868510a8b7105b1a5f | [
"MIT"
] | 4 | 2020-02-12T21:30:44.000Z | 2020-04-15T20:06:46.000Z | output/models/ms_data/additional/isdefault072_xsd/isdefault072.py | tefra/xsdata-w3c-tests | b6b6a4ac4e0ab610e4b50d868510a8b7105b1a5f | [
"MIT"
] | null | null | null | from dataclasses import dataclass, field
from typing import List
from xml.etree.ElementTree import QName
__NAMESPACE__ = "http://schemas.microsoft.com/2003/10/Serialization/"
| 24.78 | 79 | 0.514124 |
2deca87ea9f9f2cd6faccaa2e1e2be6b9753edc0 | 54,161 | py | Python | pysnmp/PRIVATE-SW0657840-MIB.py | agustinhenze/mibs.snmplabs.com | 1fc5c07860542b89212f4c8ab807057d9a9206c7 | [
"Apache-2.0"
] | 11 | 2021-02-02T16:27:16.000Z | 2021-08-31T06:22:49.000Z | pysnmp/PRIVATE-SW0657840-MIB.py | agustinhenze/mibs.snmplabs.com | 1fc5c07860542b89212f4c8ab807057d9a9206c7 | [
"Apache-2.0"
] | 75 | 2021-02-24T17:30:31.000Z | 2021-12-08T00:01:18.000Z | pysnmp/PRIVATE-SW0657840-MIB.py | agustinhenze/mibs.snmplabs.com | 1fc5c07860542b89212f4c8ab807057d9a9206c7 | [
"Apache-2.0"
] | 10 | 2019-04-30T05:51:36.000Z | 2022-02-16T03:33:41.000Z | #
# PySNMP MIB module PRIVATE-SW0657840-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/PRIVATE-SW0657840-MIB
# Produced by pysmi-0.3.4 at Mon Apr 29 20:33:18 2019
# On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4
# Using Python version 3.7.3 (def... | 129.882494 | 10,027 | 0.773342 |
2dedbb9bc8cf45b074be9e76b40b810632cf828b | 14,005 | py | Python | simpleference/inference/util.py | neptunes5thmoon/simpleference | 96c74187bd3d83f6f1e910e72e56f45d6cc8d5d9 | [
"MIT"
] | null | null | null | simpleference/inference/util.py | neptunes5thmoon/simpleference | 96c74187bd3d83f6f1e910e72e56f45d6cc8d5d9 | [
"MIT"
] | null | null | null | simpleference/inference/util.py | neptunes5thmoon/simpleference | 96c74187bd3d83f6f1e910e72e56f45d6cc8d5d9 | [
"MIT"
] | null | null | null | from __future__ import print_function
try:
import h5py
WITH_H5PY = True
except ImportError:
WITH_H5PY = False
try:
import zarr
WITH_ZARR = True
from .io import IoZarr
except ImportError:
WITH_ZARR = False
try:
import z5py
WITH_Z5PY = True
from .io import IoN5
except ImportError:
... | 37.95393 | 124 | 0.57865 |
2def07ac71914db60c5520bf17ab094d2838a077 | 481 | py | Python | python/ds/MinDiffList.py | unhingedporter/DataStructureMustKnow | 3c5b3225afa2775d37a2ff90121f73208717640a | [
"MIT"
] | 3 | 2019-11-23T08:43:58.000Z | 2019-11-23T08:52:53.000Z | python/ds/MinDiffList.py | unhingedpotter/DSMustKnow | 64958cbbbb3f4cdb1104c2255e555233554503f9 | [
"MIT"
] | null | null | null | python/ds/MinDiffList.py | unhingedpotter/DSMustKnow | 64958cbbbb3f4cdb1104c2255e555233554503f9 | [
"MIT"
] | null | null | null |
findDiff = MinDiffList()
print(findDiff.findMinDiff([1, 2, 3, 4, 5, 888, 100, 120, -5, 0.8]))
| 24.05 | 68 | 0.555094 |
2defa74f0ad5c7fdce73289dd8fcc91dc1f25cf7 | 2,075 | py | Python | ncbi/patric_add_taxonomy.py | johned0/EdwardsLab | ae0d8b51a579cd009b414d11224b4110ba13af66 | [
"MIT"
] | null | null | null | ncbi/patric_add_taxonomy.py | johned0/EdwardsLab | ae0d8b51a579cd009b414d11224b4110ba13af66 | [
"MIT"
] | null | null | null | ncbi/patric_add_taxonomy.py | johned0/EdwardsLab | ae0d8b51a579cd009b414d11224b4110ba13af66 | [
"MIT"
] | null | null | null | """
Add the taxonomy to the patric metadata file
"""
import os
import sys
import argparse
from taxon import get_taxonomy_db, get_taxonomy
c = get_taxonomy_db()
if __name__ == '__main__':
parser = argparse.ArgumentParser(description="Append taxonomy to the patric metadata file. This adds it at column 67")
par... | 33.467742 | 122 | 0.517108 |
2df494efc476f1235a7fd4bca3824c402be41058 | 11,450 | py | Python | project/save_FlowFile_BPFormat.py | wesleybowman/karsten | ef4b2d6debae605902d76cd0484e71c0ba74fdd1 | [
"MIT"
] | 1 | 2015-05-04T17:48:56.000Z | 2015-05-04T17:48:56.000Z | project/save_FlowFile_BPFormat.py | wesleybowman/karsten | ef4b2d6debae605902d76cd0484e71c0ba74fdd1 | [
"MIT"
] | null | null | null | project/save_FlowFile_BPFormat.py | wesleybowman/karsten | ef4b2d6debae605902d76cd0484e71c0ba74fdd1 | [
"MIT"
] | 1 | 2021-11-15T17:53:19.000Z | 2021-11-15T17:53:19.000Z | from __future__ import division
import numpy as np
from rawADCPclass import rawADCP
from datetime import datetime
from datetime import timedelta
import scipy.io as sio
import scipy.interpolate as sip
import matplotlib.pyplot as plt
import seaborn
def rotate_coords(x, y, theta):
'''
Similar to "rotate_to_chan... | 32.902299 | 94 | 0.599301 |
2df53d0c6968d61a6511d518ea06ce30084abc51 | 1,923 | py | Python | Module1/Day06/module1_day06_lists.py | datsaloglou/100DaysPython | b6a90bfa5260fb2cb66da9eceaafda9a53c76c0f | [
"MIT"
] | 1 | 2019-06-02T12:16:52.000Z | 2019-06-02T12:16:52.000Z | Module1/Day06/module1_day06_lists.py | datsaloglou/100DaysPython | b6a90bfa5260fb2cb66da9eceaafda9a53c76c0f | [
"MIT"
] | null | null | null | Module1/Day06/module1_day06_lists.py | datsaloglou/100DaysPython | b6a90bfa5260fb2cb66da9eceaafda9a53c76c0f | [
"MIT"
] | null | null | null | """
Author: CaptCorpMURICA
Project: 100DaysPython
File: module1_day06_lists.py
Creation Date: 6/2/2019, 8:55 AM
Description: Learn the basic of lists in python.
"""
list_1 = []
list_2 = list()
print("List 1 Type: {}\nList 2 Type: {}".format(type(list_1), type(list_2)))
... | 27.084507 | 76 | 0.667707 |
2df5a62d162481addcad6f25157f37024121dd7c | 708 | py | Python | Interview Preparation Kit/01 - Warm-up Challenges/04 - Repeated String.py | srgeyK87/Hacker-Rank-30-days-challlenge | 4a929935148db493057dd3a5a88e77efcc0fd086 | [
"MIT"
] | 275 | 2020-04-10T18:01:13.000Z | 2022-03-23T15:03:41.000Z | Interview Preparation Kit/01 - Warm-up Challenges/04 - Repeated String.py | rakshit6432/HackerRank-Solutions | 9fd5b295f03cc80b77e80810bb6b7b6acd160e79 | [
"MIT"
] | 2 | 2020-12-20T10:55:40.000Z | 2021-05-20T12:52:53.000Z | Interview Preparation Kit/01 - Warm-up Challenges/04 - Repeated String.py | rakshit6432/HackerRank-Solutions | 9fd5b295f03cc80b77e80810bb6b7b6acd160e79 | [
"MIT"
] | 196 | 2020-09-26T16:24:43.000Z | 2022-03-28T10:40:05.000Z | # ========================
# Information
# ========================
# Direct Link: https://www.hackerrank.com/challenges/repeated-string/problem
# Difficulty: Easy
# Max Score: 20
# Language: Python
# ========================
# Solution
# ========================
import os
# Complete the repeatedStrin... | 22.83871 | 76 | 0.542373 |
2df6288c891a7e36cd3f5221f22fe8e36ca68a70 | 6,056 | py | Python | regress/PORT_ME_TESTS/tests-glen.py | fp7-ofelia/VeRTIGO | 11f39f819196c8352611852435dea17bc6a2292f | [
"BSD-3-Clause"
] | 2 | 2016-10-12T08:20:00.000Z | 2017-05-09T13:13:18.000Z | regress/PORT_ME_TESTS/tests-glen.py | fp7-ofelia/VeRTIGO | 11f39f819196c8352611852435dea17bc6a2292f | [
"BSD-3-Clause"
] | null | null | null | regress/PORT_ME_TESTS/tests-glen.py | fp7-ofelia/VeRTIGO | 11f39f819196c8352611852435dea17bc6a2292f | [
"BSD-3-Clause"
] | 1 | 2020-10-01T07:57:34.000Z | 2020-10-01T07:57:34.000Z | #!/usr/bin/python
from fvregress import *
import string # really? you have to do this?
if len(sys.argv) > 1 :
wantPause = True
timeout=9999999
valgrindArgs= []
else:
wantPause = False
timeout=5
valgrindArgs= None
# start up a flowvisor with 1 switch (default) and two guests
#h= HyperTest(guests=[('localhost'... | 67.288889 | 192 | 0.803831 |
2df6451745f6199069fa0651e5f50fd52805e8f8 | 1,325 | py | Python | pseudo/__init__.py | pniedzwiedzinski/pseudo | b27570bd8400b6a51a2958454b31f1ce2e25c4f9 | [
"MIT"
] | 5 | 2019-04-02T07:01:34.000Z | 2019-11-24T02:08:03.000Z | pseudo/__init__.py | pniedzwiedzinski/pseudo | b27570bd8400b6a51a2958454b31f1ce2e25c4f9 | [
"MIT"
] | 11 | 2019-03-20T08:29:30.000Z | 2019-05-21T11:57:03.000Z | pseudo/__init__.py | pniedzwiedzinski/pseudo | b27570bd8400b6a51a2958454b31f1ce2e25c4f9 | [
"MIT"
] | 1 | 2019-04-02T15:24:40.000Z | 2019-04-02T15:24:40.000Z | """
Writing actual code might be hard to understand for new-learners. Pseudocode is a tool
for writing algorithms without knowing how to code. This module contains classes and
methods for parsing pseudocode to AST and then evaluating it.
Example:
If you installed this module with pip you can run pseudocode from fi... | 24.537037 | 92 | 0.675472 |
2df6c6319b7d1906f84dc0b600c9446955b1aa9f | 320 | py | Python | adabru_talon/code/deep_sleep.py | adabru/speech | 74a4398693186f5b90ac5b3252aa7bd2764fa695 | [
"WTFPL"
] | null | null | null | adabru_talon/code/deep_sleep.py | adabru/speech | 74a4398693186f5b90ac5b3252aa7bd2764fa695 | [
"WTFPL"
] | null | null | null | adabru_talon/code/deep_sleep.py | adabru/speech | 74a4398693186f5b90ac5b3252aa7bd2764fa695 | [
"WTFPL"
] | null | null | null | from talon import (
Module,
Context,
)
mod = Module()
mod.tag("deep_sleep", desc="Enable deep sleep")
ctx = Context()
| 15.238095 | 47 | 0.55625 |
2df782b87d6da8a3b61ad938472a58ca41cb66f2 | 396 | py | Python | stubs/esp32_1_10_0/upip_utarfile.py | jmannau/micropython-stubber | 8930e8a0038192fd259b31a193d1da3b2501256a | [
"MIT"
] | null | null | null | stubs/esp32_1_10_0/upip_utarfile.py | jmannau/micropython-stubber | 8930e8a0038192fd259b31a193d1da3b2501256a | [
"MIT"
] | null | null | null | stubs/esp32_1_10_0/upip_utarfile.py | jmannau/micropython-stubber | 8930e8a0038192fd259b31a193d1da3b2501256a | [
"MIT"
] | null | null | null | "Module 'upip_utarfile' on firmware 'v1.10-247-g0fb15fc3f on 2019-03-29'"
DIRTYPE = 'dir'
REGTYPE = 'file'
TAR_HEADER = None
uctypes = None
| 13.2 | 73 | 0.560606 |
2df89db144b707f4b0822c6ae9ce1acc6ef701ad | 482 | py | Python | core/src/zeit/content/author/browser/interfaces.py | rickdg/vivi | 16134ac954bf8425646d4ad47bdd1f372e089355 | [
"BSD-3-Clause"
] | 5 | 2019-05-16T09:51:29.000Z | 2021-05-31T09:30:03.000Z | core/src/zeit/content/author/browser/interfaces.py | rickdg/vivi | 16134ac954bf8425646d4ad47bdd1f372e089355 | [
"BSD-3-Clause"
] | 107 | 2019-05-24T12:19:02.000Z | 2022-03-23T15:05:56.000Z | core/src/zeit/content/author/browser/interfaces.py | rickdg/vivi | 16134ac954bf8425646d4ad47bdd1f372e089355 | [
"BSD-3-Clause"
] | 3 | 2020-08-14T11:01:17.000Z | 2022-01-08T17:32:19.000Z | from zeit.cms.i18n import MessageFactory as _
import zope.formlib.interfaces
import zope.interface
| 32.133333 | 70 | 0.692946 |
2df8c42e864589ea93f8316ea84d6115885699fb | 237 | py | Python | Skyhero-admin/Day 29/exp8_3.py | adityajoshi-08/100-Days-of-Code | 22026ca37dd8bcf5e5e22a8a302510249936c002 | [
"MIT"
] | 33 | 2022-01-11T14:00:24.000Z | 2022-03-24T02:49:44.000Z | Skyhero-admin/Day 29/exp8_3.py | adityajoshi-08/100-Days-of-Code | 22026ca37dd8bcf5e5e22a8a302510249936c002 | [
"MIT"
] | 28 | 2022-01-11T17:08:52.000Z | 2022-03-15T17:03:15.000Z | Skyhero-admin/Day 29/exp8_3.py | adityajoshi-08/100-Days-of-Code | 22026ca37dd8bcf5e5e22a8a302510249936c002 | [
"MIT"
] | 57 | 2022-01-11T15:54:07.000Z | 2022-03-27T04:37:42.000Z |
word = input('Enter word: ')
count = countWord(word)
print(word, '- occurence: ', count) | 21.545455 | 35 | 0.658228 |
2df9a0c0fb58029492e4ab2e5a697ee378f5037d | 9,190 | py | Python | utils.py | khangt1k25/Clustering-Segmentation | 4a7262c9d12fac4f595c8d0740342017b498262b | [
"MIT"
] | null | null | null | utils.py | khangt1k25/Clustering-Segmentation | 4a7262c9d12fac4f595c8d0740342017b498262b | [
"MIT"
] | null | null | null | utils.py | khangt1k25/Clustering-Segmentation | 4a7262c9d12fac4f595c8d0740342017b498262b | [
"MIT"
] | null | null | null | import random
import os
import logging
import pickle
import numpy as np
import torch
import torch.nn as nn
import torch.nn.functional as F
import torch.backends.cudnn as cudnn
# import faiss
################################################################################
# General-... | 31.152542 | 111 | 0.569206 |
2df9e5faeeb7d475c0095425ade4eae6bf0cbee6 | 7,009 | py | Python | rif_template.py | EngRaff92/RDL_REG_GEN | 1da36a247552217d009b41b035ddda742ad2aa3e | [
"MIT"
] | 2 | 2022-01-11T19:22:16.000Z | 2022-01-11T20:19:55.000Z | rif_template.py | EngRaff92/RDL_REG_GEN | 1da36a247552217d009b41b035ddda742ad2aa3e | [
"MIT"
] | null | null | null | rif_template.py | EngRaff92/RDL_REG_GEN | 1da36a247552217d009b41b035ddda742ad2aa3e | [
"MIT"
] | null | null | null | header = """/*
Icebreaker and IceSugar RSMB5 project - RV32I for Lattice iCE40
With complete open-source toolchain flow using:
-> yosys
-> icarus verilog
-> icestorm project
Tests are written in several languages
-> Systemverilog Pure Testbench (Vivado)
-> UVM testbench (Vivado)
-> PyUvm (Icarus)
-> Formal ... | 31.151111 | 119 | 0.66329 |
2dfab9e21824f933194ff41412afd5eaebd5cb04 | 438 | py | Python | reader.py | Asylumrunner/FeedingFrenzy | 7f0d96f8361cb2c37cd41d06345e6ec0aa721472 | [
"MIT"
] | 1 | 2020-12-08T13:09:38.000Z | 2020-12-08T13:09:38.000Z | reader.py | weisisheng/FeedingFrenzy | 7f0d96f8361cb2c37cd41d06345e6ec0aa721472 | [
"MIT"
] | null | null | null | reader.py | weisisheng/FeedingFrenzy | 7f0d96f8361cb2c37cd41d06345e6ec0aa721472 | [
"MIT"
] | 1 | 2020-12-08T13:09:39.000Z | 2020-12-08T13:09:39.000Z | import feedparser | 31.285714 | 129 | 0.6621 |
2dfac8a859dbed739d1b56982bcc545aec26ba63 | 9,229 | py | Python | modmail/config.py | fossabot/modmail-1 | ffbc3f981efb455f920e8c9f52657fbc2b802816 | [
"MIT"
] | null | null | null | modmail/config.py | fossabot/modmail-1 | ffbc3f981efb455f920e8c9f52657fbc2b802816 | [
"MIT"
] | null | null | null | modmail/config.py | fossabot/modmail-1 | ffbc3f981efb455f920e8c9f52657fbc2b802816 | [
"MIT"
] | null | null | null | import asyncio
import datetime
import json
import logging
import os
import sys
import typing
from pathlib import Path
from typing import Any, Dict, Optional, Tuple
import discord
import toml
from discord.ext.commands import BadArgument
from pydantic import BaseModel
from pydantic import BaseSettings as PydanticBaseSet... | 29.113565 | 98 | 0.694983 |
2dfc0e1a9a6d36009062ade1fde99b49f19b17a2 | 5,851 | py | Python | turnip/prots.py | RuthAngus/turnip | 83aa899b6f35e709cd8a63c5395ff8e070a91bb9 | [
"MIT"
] | null | null | null | turnip/prots.py | RuthAngus/turnip | 83aa899b6f35e709cd8a63c5395ff8e070a91bb9 | [
"MIT"
] | null | null | null | turnip/prots.py | RuthAngus/turnip | 83aa899b6f35e709cd8a63c5395ff8e070a91bb9 | [
"MIT"
] | null | null | null | # plot rotation period vs orbital period
import os
import numpy as np
import matplotlib.pyplot as plt
import pandas as pd
import glob
import re
from gyro import gyro_age
import teff_bv as tbv
import scipy.stats as sps
from calc_completeness import calc_comp
# np.set_printoptions(threshold=np.nan, linewidth=9)
plotpar... | 30.633508 | 78 | 0.604683 |
2dfc27f1da91e13bb0050491db5539cdfb26d239 | 9,911 | py | Python | proper_mod/prop_dm.py | RupertDodkins/medis | bdb1f00fb93506da2a1f251bc6780e70e97a16c5 | [
"MIT"
] | 1 | 2021-06-25T17:35:56.000Z | 2021-06-25T17:35:56.000Z | proper_mod/prop_dm.py | RupertDodkins/medis | bdb1f00fb93506da2a1f251bc6780e70e97a16c5 | [
"MIT"
] | null | null | null | proper_mod/prop_dm.py | RupertDodkins/medis | bdb1f00fb93506da2a1f251bc6780e70e97a16c5 | [
"MIT"
] | 2 | 2018-12-08T15:05:13.000Z | 2019-08-08T17:28:24.000Z | # Copyright 2016, 2017 California Institute of Technology
# Users must agree to abide by the restrictions listed in the
# file "LegalStuff.txt" in the PROPER library directory.
#
# PROPER developed at Jet Propulsion Laboratory/California Inst. Technology
# Original IDL version by John Krist
# Python transla... | 38.414729 | 114 | 0.634648 |
2dfeb124e98b0f347e20cdfa1b942484c6bbcdf7 | 1,571 | py | Python | asap-tools/experiments/depricated/handler/comparative.py | project-asap/Profiler | eaad7eafe3635a2d0881c13069a3ac632784fd3a | [
"Apache-2.0"
] | 3 | 2017-04-18T17:09:29.000Z | 2017-11-08T22:55:32.000Z | asap-tools/experiments/depricated/handler/comparative.py | project-asap/Profiler | eaad7eafe3635a2d0881c13069a3ac632784fd3a | [
"Apache-2.0"
] | 18 | 2016-11-07T10:44:58.000Z | 2017-04-25T12:40:24.000Z | asap-tools/experiments/depricated/handler/comparative.py | project-asap/Profiler | eaad7eafe3635a2d0881c13069a3ac632784fd3a | [
"Apache-2.0"
] | 4 | 2015-12-09T09:09:59.000Z | 2018-05-23T14:29:00.000Z | __author__ = 'cmantas'
from tools import *
# Kmeans mahout vs spark
m_q = """select mahout_kmeans_text.documents/1000, mahout_kmeans_text.time/1000
from mahout_tfidf inner join mahout_kmeans_text
ON
mahout_tfidf.documents=mahout_kmeans_text.documents AND
mahout_tfidf.dimensions=mahout_kmeans_text.dimensions
where ... | 38.317073 | 128 | 0.760025 |
2dff63249548afd5c182283e332b2e72f7db6505 | 1,818 | py | Python | docs/sample_code/debugging_info/src/dataset.py | mindspore-ai/docs | e7cbd69fe2bbd7870aa4591510ed3342ec6a3d41 | [
"Apache-2.0",
"CC-BY-4.0"
] | 288 | 2020-03-28T07:00:25.000Z | 2021-12-26T14:56:31.000Z | docs/sample_code/debugging_info/src/dataset.py | mindspore-ai/docs | e7cbd69fe2bbd7870aa4591510ed3342ec6a3d41 | [
"Apache-2.0",
"CC-BY-4.0"
] | 1 | 2021-07-21T08:11:58.000Z | 2021-07-21T08:11:58.000Z | docs/sample_code/debugging_info/src/dataset.py | mindspore-ai/docs | e7cbd69fe2bbd7870aa4591510ed3342ec6a3d41 | [
"Apache-2.0",
"CC-BY-4.0"
] | 37 | 2020-03-30T06:38:37.000Z | 2021-09-17T05:47:59.000Z | # Copyright 2021 Huawei Technologies Co., Ltd
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to... | 42.27907 | 94 | 0.69802 |
2dffcb312aeb4d575f278141844b269942663fab | 3,338 | py | Python | exercise/venv/lib/python3.7/site-packages/sqreen/sdk/events.py | assuzzanne/my-sqreen | 81ae0eab417a1dbc0ae6b1778ebfdd71591c3c5b | [
"MIT"
] | null | null | null | exercise/venv/lib/python3.7/site-packages/sqreen/sdk/events.py | assuzzanne/my-sqreen | 81ae0eab417a1dbc0ae6b1778ebfdd71591c3c5b | [
"MIT"
] | 1 | 2021-06-02T00:27:34.000Z | 2021-06-02T00:27:34.000Z | exercise/venv/lib/python3.7/site-packages/sqreen/sdk/events.py | assuzzanne/notifications-dispatcher-api | 81ae0eab417a1dbc0ae6b1778ebfdd71591c3c5b | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
# Copyright (c) 2016, 2017, 2018, 2019 Sqreen. All rights reserved.
# Please refer to our terms for more information:
#
# https://www.sqreen.io/terms.html
#
import logging
import traceback
from datetime import datetime
from ..runtime_storage import runtime
from ..utils import is_string
LO... | 29.539823 | 78 | 0.629718 |
930100236a4359a4387dd68192ff211e5a4519df | 149 | py | Python | roona/roona/doctype/roona_app_setting/test_roona_app_setting.py | mohsinalimat/roona | b24336d9d56eb443a883131afffd9091c9a66add | [
"MIT"
] | 1 | 2021-08-28T04:24:00.000Z | 2021-08-28T04:24:00.000Z | roona/roona/doctype/roona_app_setting/test_roona_app_setting.py | mohsinalimat/roona | b24336d9d56eb443a883131afffd9091c9a66add | [
"MIT"
] | null | null | null | roona/roona/doctype/roona_app_setting/test_roona_app_setting.py | mohsinalimat/roona | b24336d9d56eb443a883131afffd9091c9a66add | [
"MIT"
] | null | null | null | # Copyright (c) 2021, Roona and Contributors
# See license.txt
# import frappe
import unittest
| 16.555556 | 45 | 0.785235 |
9302285f60696162f64b949eeb7c5d5dad50cb49 | 37,505 | py | Python | workspace/module/maya-python-2.7/LxMaya/command/maShdr.py | no7hings/Lynxi | 43c745198a714c2e5aca86c6d7a014adeeb9abf7 | [
"MIT"
] | 2 | 2018-03-06T03:33:55.000Z | 2019-03-26T03:25:11.000Z | workspace/module/maya-python-2.7/LxMaya/command/maShdr.py | no7hings/lynxi | 43c745198a714c2e5aca86c6d7a014adeeb9abf7 | [
"MIT"
] | null | null | null | workspace/module/maya-python-2.7/LxMaya/command/maShdr.py | no7hings/lynxi | 43c745198a714c2e5aca86c6d7a014adeeb9abf7 | [
"MIT"
] | null | null | null | # coding=utf-8
# noinspection PyUnresolvedReferences
import maya.cmds as cmds
from LxBasic import bscMtdCore, bscObjects, bscMethods
#
from LxPreset import prsConfigure, prsOutputs
#
from LxCore.config import appCfg
#
from LxCore.preset.prod import assetPr
#
from LxDatabase import dtbMtdCore
#
from LxDatabase.data imp... | 36.878073 | 153 | 0.627916 |
9302303524c2d1d2dcea444d0b37ee6e17561f6a | 441 | py | Python | db/Service.py | hamedsh/healthCheck | 8f6b8ffffc1f1d8849a58b4966e54d30ead9556b | [
"Apache-2.0"
] | null | null | null | db/Service.py | hamedsh/healthCheck | 8f6b8ffffc1f1d8849a58b4966e54d30ead9556b | [
"Apache-2.0"
] | null | null | null | db/Service.py | hamedsh/healthCheck | 8f6b8ffffc1f1d8849a58b4966e54d30ead9556b | [
"Apache-2.0"
] | null | null | null | import json
| 25.941176 | 60 | 0.557823 |
9302d12e0eb5ea7aeef313eeca626e9071df7895 | 22,422 | py | Python | nbpipeline/rules.py | krassowski/nbpipeline | c2337db2b19767b2cdfcc9bf019e2bf687bb4423 | [
"MIT"
] | 16 | 2019-07-17T17:15:52.000Z | 2021-11-19T07:15:19.000Z | nbpipeline/rules.py | krassowski/nbpipeline | c2337db2b19767b2cdfcc9bf019e2bf687bb4423 | [
"MIT"
] | 5 | 2019-07-17T21:09:31.000Z | 2020-04-18T18:53:46.000Z | nbpipeline/rules.py | krassowski/nbpipeline | c2337db2b19767b2cdfcc9bf019e2bf687bb4423 | [
"MIT"
] | 2 | 2019-12-18T19:23:38.000Z | 2021-03-05T10:55:48.000Z | import json
import pickle
import re
from copy import copy, deepcopy
from functools import lru_cache
from json import JSONDecodeError
from os import system, walk, sep
from abc import ABC, abstractmethod
from pathlib import Path
import time
from subprocess import check_output
from tempfile import NamedTemporaryFile
from ... | 36.281553 | 181 | 0.550085 |
9303234b67903102cb5d3258f289b230610a2cf6 | 801 | py | Python | analyse_images.py | aalto-ui/SemanticCollage | 61b4f241aef6c029a634f0d70a2a35799db46076 | [
"MIT"
] | null | null | null | analyse_images.py | aalto-ui/SemanticCollage | 61b4f241aef6c029a634f0d70a2a35799db46076 | [
"MIT"
] | 4 | 2021-06-08T21:23:18.000Z | 2022-03-12T00:25:45.000Z | analyse_images.py | aalto-ui/SemanticCollage | 61b4f241aef6c029a634f0d70a2a35799db46076 | [
"MIT"
] | 1 | 2021-04-21T03:41:32.000Z | 2021-04-21T03:41:32.000Z | # encoding=utf8
from load_to_db import *
save_list = []
import random
import string
def randomString(url, stringLength=20):
"""Generate a random string of fixed length """
Letters = string.ascii_lowercase + string.ascii_uppercase + string.digits
url_split = url.split(".")
format_ = url_split[-1]
... | 25.83871 | 78 | 0.694132 |
93034a9a6233faadc660e34f44294b994aedc83c | 124 | py | Python | Eolymp_DSAWeek1_Solns/Digits.py | sulphatet/MiniProjectsndCodingProbs | a8f6c9c3993854cad9444800f9d1b1720a239b39 | [
"MIT"
] | 1 | 2022-02-24T08:29:00.000Z | 2022-02-24T08:29:00.000Z | Eolymp_DSAWeek1_Solns/Digits.py | sulphatet/MiniProjectsndCodingProbs | a8f6c9c3993854cad9444800f9d1b1720a239b39 | [
"MIT"
] | null | null | null | Eolymp_DSAWeek1_Solns/Digits.py | sulphatet/MiniProjectsndCodingProbs | a8f6c9c3993854cad9444800f9d1b1720a239b39 | [
"MIT"
] | null | null | null | num = int(input())
x = 0
if num == 0:
print(1)
exit()
while num != 0:
x +=1
num = num//10
print(x)
| 12.4 | 19 | 0.435484 |
9304179c9a7ef19d7cafd259a2cdab5634a69a04 | 786 | py | Python | stable_baselines_model_based_rl/wrapper/gym_step_handlers/continuous_mountain_car.py | micheltokic/stable_baselines_model_based_rl | 75bac906aeba69072878ceb15d9be459b1f436c3 | [
"Apache-2.0"
] | 1 | 2022-01-08T17:08:13.000Z | 2022-01-08T17:08:13.000Z | stable_baselines_model_based_rl/wrapper/gym_step_handlers/continuous_mountain_car.py | micheltokic/stable_baselines_model_based_rl | 75bac906aeba69072878ceb15d9be459b1f436c3 | [
"Apache-2.0"
] | 5 | 2021-09-15T18:14:48.000Z | 2021-09-19T16:17:51.000Z | stable_baselines_model_based_rl/wrapper/gym_step_handlers/continuous_mountain_car.py | micheltokic/stable_baselines_model_based_rl | 75bac906aeba69072878ceb15d9be459b1f436c3 | [
"Apache-2.0"
] | null | null | null | import math
from stable_baselines_model_based_rl.wrapper.step_handler import StepRewardDoneHandler
| 27.103448 | 87 | 0.614504 |
9304861c31e91f902b6f121f6ca51fab98031cbe | 3,305 | py | Python | src/mod_stats_by_aircraft/background_jobs/background_job.py | FGlazov/IL2Stats_ByAircraftMod | acf66eb3f31a7e789d61a5c60d32fd30dbcedf4b | [
"MIT"
] | null | null | null | src/mod_stats_by_aircraft/background_jobs/background_job.py | FGlazov/IL2Stats_ByAircraftMod | acf66eb3f31a7e789d61a5c60d32fd30dbcedf4b | [
"MIT"
] | null | null | null | src/mod_stats_by_aircraft/background_jobs/background_job.py | FGlazov/IL2Stats_ByAircraftMod | acf66eb3f31a7e789d61a5c60d32fd30dbcedf4b | [
"MIT"
] | null | null | null | from django.core.exceptions import FieldError
from django.db import ProgrammingError
from stats.models import Tour, Sortie
from django.db.models import Max
import config
RETRO_COMPUTE_FOR_LAST_TOURS = config.get_conf()['stats'].getint('retro_compute_for_last_tours')
if RETRO_COMPUTE_FOR_LAST_TOURS is None:
RETRO_C... | 39.819277 | 120 | 0.69289 |
9306105a7d6f94715dda6856227c83b2b5fdd102 | 2,016 | py | Python | peakinvestigator/actions/run.py | jct197/PeakInvestigator-Python-SDK | 75d58d67208deff07b6e366e0b34d37570b46bf5 | [
"BSD-3-Clause"
] | null | null | null | peakinvestigator/actions/run.py | jct197/PeakInvestigator-Python-SDK | 75d58d67208deff07b6e366e0b34d37570b46bf5 | [
"BSD-3-Clause"
] | 4 | 2019-03-14T03:01:05.000Z | 2019-10-16T20:51:03.000Z | peakinvestigator/actions/run.py | jct197/PeakInvestigator-Python-SDK | 75d58d67208deff07b6e366e0b34d37570b46bf5 | [
"BSD-3-Clause"
] | 1 | 2019-01-05T03:50:02.000Z | 2019-01-05T03:50:02.000Z | ## -*- coding: utf-8 -*-
#
# Copyright (c) 2016, Veritomyx, Inc.
#
# This file is part of the Python SDK for PeakInvestigator
# (http://veritomyx.com) and is distributed under the terms
# of the BSD 3-Clause license.
from .base import BaseAction
| 28 | 80 | 0.590278 |
93067822138f982e5bd62fcfd10cc9b4ae612b62 | 3,757 | py | Python | .setup/bin/input_forum_data.py | zeez2030/Submitty | 7118944ff4adc6f15d76984eb10a1e862926d724 | [
"BSD-3-Clause"
] | 411 | 2016-06-14T20:52:25.000Z | 2022-03-31T21:20:25.000Z | .setup/bin/input_forum_data.py | KaelanWillauer/Submitty | cf9b6ceda15ec0a661e2ca81ea7864790094c64a | [
"BSD-3-Clause"
] | 5,730 | 2016-05-23T21:04:32.000Z | 2022-03-31T10:08:06.000Z | .setup/bin/input_forum_data.py | KaelanWillauer/Submitty | cf9b6ceda15ec0a661e2ca81ea7864790094c64a | [
"BSD-3-Clause"
] | 423 | 2016-09-22T21:11:30.000Z | 2022-03-29T18:55:28.000Z | #!/usr/bin/env python3
import os
import sys
import json
from datetime import datetime
from submitty_utils import dateutils
if(__name__ == "__main__"):
num_args = len(sys.argv)
possible_databases = generatePossibleDatabases()
database = possible_databases[0]
if(num_args > 2):
print('Too many arguments. Use -... | 51.465753 | 398 | 0.672345 |
930766e7b8ffd5a77cf2414fe0de6b57a69af041 | 48 | py | Python | levelpy/async/__init__.py | rch/levelpy | 59e546854b3d478f3467bd573eb5f6b4da62d239 | [
"MIT"
] | 4 | 2015-11-06T22:50:22.000Z | 2020-05-31T14:49:58.000Z | levelpy/async/__init__.py | rch/levelpy | 59e546854b3d478f3467bd573eb5f6b4da62d239 | [
"MIT"
] | null | null | null | levelpy/async/__init__.py | rch/levelpy | 59e546854b3d478f3467bd573eb5f6b4da62d239 | [
"MIT"
] | 3 | 2017-01-25T22:26:40.000Z | 2021-03-24T07:49:33.000Z | #
# levelpy/async/__init__.py
#
import asyncio
| 8 | 27 | 0.729167 |
9308413560c1330a48aacec8d18de1204b19be47 | 751 | py | Python | app/domain/messaging/tests/test_models.py | anthon-alindada/sanic_messaging | 2afbc601790b4a3dbe17e0a95c589412250d8bee | [
"MIT"
] | 1 | 2019-06-21T08:51:01.000Z | 2019-06-21T08:51:01.000Z | app/domain/messaging/tests/test_models.py | anthon-alindada/sanic_messaging | 2afbc601790b4a3dbe17e0a95c589412250d8bee | [
"MIT"
] | 6 | 2021-03-09T07:47:26.000Z | 2022-02-26T11:33:25.000Z | app/domain/messaging/tests/test_models.py | anthon-alindada/sanic_messaging | 2afbc601790b4a3dbe17e0a95c589412250d8bee | [
"MIT"
] | null | null | null | # -*- coding: utf-8
# Models
from ..models import Channel, ChannelUser, Message
| 21.457143 | 62 | 0.653795 |
93095d98ffed279b01860ac139ac53ed5312a8e1 | 206 | py | Python | aiosnow/models/__init__.py | michaeldcanady/aiosnow | db515b1560d651fc7696a184990c2a2d68db8961 | [
"MIT"
] | 38 | 2020-08-03T17:58:48.000Z | 2022-03-30T19:39:24.000Z | aiosnow/models/__init__.py | michaeldcanady/aiosnow | db515b1560d651fc7696a184990c2a2d68db8961 | [
"MIT"
] | 34 | 2020-01-20T10:11:46.000Z | 2020-06-05T21:25:23.000Z | aiosnow/models/__init__.py | michaeldcanady/aiosnow | db515b1560d651fc7696a184990c2a2d68db8961 | [
"MIT"
] | 5 | 2021-03-26T19:35:20.000Z | 2022-01-23T20:09:55.000Z | from ._base import BaseModel, BaseModelMeta, BaseTableModel
from ._schema import BaseField, ModelSchema, ModelSchemaMeta, Pluck, fields
from .attachment import AttachmentModel
from .table import TableModel
| 41.2 | 75 | 0.84466 |
930a3159a270d17b3e016e6419675cf9059057cd | 506 | py | Python | examples/providers/factory_aggregate/prototype.py | kinow/python-dependency-injector | ebd98bebe9a8fc0b57e68cfc12c4979833baa6a5 | [
"BSD-3-Clause"
] | null | null | null | examples/providers/factory_aggregate/prototype.py | kinow/python-dependency-injector | ebd98bebe9a8fc0b57e68cfc12c4979833baa6a5 | [
"BSD-3-Clause"
] | null | null | null | examples/providers/factory_aggregate/prototype.py | kinow/python-dependency-injector | ebd98bebe9a8fc0b57e68cfc12c4979833baa6a5 | [
"BSD-3-Clause"
] | null | null | null | """FactoryAggregate provider prototype."""
| 28.111111 | 60 | 0.656126 |
930b6911eb3b99feb00dad0f3f43696dfc1d21e0 | 27,385 | py | Python | test_cnlunardate.py | YuBPan/cnlunardate | c19aa9821aecadea6647ac026bf233ab9f7cff90 | [
"MIT"
] | null | null | null | test_cnlunardate.py | YuBPan/cnlunardate | c19aa9821aecadea6647ac026bf233ab9f7cff90 | [
"MIT"
] | 1 | 2020-01-10T05:06:27.000Z | 2020-01-10T05:06:27.000Z | test_cnlunardate.py | YuBPan/cnlunardate | c19aa9821aecadea6647ac026bf233ab9f7cff90 | [
"MIT"
] | null | null | null | """Test cnlunardate."""
import unittest
import pickle
from cnlunardate import cnlunardate
from cnlunardate import MIN_YEAR, MAX_YEAR
from datetime import timedelta
pickle_loads = {pickle.loads, pickle._loads}
pickle_choices = [(pickle, pickle, proto)
for proto in range(pickle.HIGHEST_PROTOCOL + 1)... | 38.843972 | 88 | 0.560964 |
930cba7bd9d0b2f6492d68c76893da92e46a129b | 756 | py | Python | sloc_report/sloc_time.py | depop/sloc_report | 0e65ece3f5c95e6ab38313b38c110fea275326b2 | [
"MIT"
] | 1 | 2016-11-08T13:57:42.000Z | 2016-11-08T13:57:42.000Z | sloc_report/sloc_time.py | depop/sloc_report | 0e65ece3f5c95e6ab38313b38c110fea275326b2 | [
"MIT"
] | null | null | null | sloc_report/sloc_time.py | depop/sloc_report | 0e65ece3f5c95e6ab38313b38c110fea275326b2 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
import time
def time_now():
"""returns current unix time as an integer"""
return int(time.time())
def get_day_times(num_days=1, end_time=time_now()):
"""returns a list of tuples, where each tuple contains the start and end
times (in unix time format, as integers) of the day(s... | 30.24 | 78 | 0.650794 |
930f2ed4f673b85667c94e0ca3470af435e95eb6 | 4,593 | py | Python | tests/home_platform/test_env.py | LuCeHe/home-platform | 06f9370bfacecebd0c8623a3b8f0511532a9a1f0 | [
"BSD-3-Clause"
] | 1 | 2021-07-27T09:15:43.000Z | 2021-07-27T09:15:43.000Z | tests/home_platform/test_env.py | LuCeHe/home-platform | 06f9370bfacecebd0c8623a3b8f0511532a9a1f0 | [
"BSD-3-Clause"
] | null | null | null | tests/home_platform/test_env.py | LuCeHe/home-platform | 06f9370bfacecebd0c8623a3b8f0511532a9a1f0 | [
"BSD-3-Clause"
] | 1 | 2021-07-27T09:21:12.000Z | 2021-07-27T09:21:12.000Z | # Copyright (c) 2017, IGLU consortium
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
# - Redistributions of source code must retain the above copyright notice,
# this list of conditions and... | 34.276119 | 108 | 0.660353 |
931108d420be8aaf39aff7a40c0bd93abe403cb2 | 9,244 | py | Python | slack_sdk/oauth/installation_store/sqlite3/__init__.py | timgates42/python-slack-sdk | 6339fbe81031c9aec3f95927ac03706fd31f3544 | [
"MIT"
] | null | null | null | slack_sdk/oauth/installation_store/sqlite3/__init__.py | timgates42/python-slack-sdk | 6339fbe81031c9aec3f95927ac03706fd31f3544 | [
"MIT"
] | null | null | null | slack_sdk/oauth/installation_store/sqlite3/__init__.py | timgates42/python-slack-sdk | 6339fbe81031c9aec3f95927ac03706fd31f3544 | [
"MIT"
] | null | null | null | import logging
import sqlite3
from logging import Logger
from sqlite3 import Connection
from typing import Optional
from slack_sdk.oauth.installation_store.async_installation_store import (
AsyncInstallationStore,
)
from slack_sdk.oauth.installation_store.installation_store import InstallationStore
from slack_sdk.... | 33.860806 | 115 | 0.442449 |
93131be5c2c31240f968a45b8920858ae167fb1c | 381 | py | Python | address/admin.py | City-of-Helsinki/geo-search | d200e06223938e456d13ae9ab94e9dad149216d0 | [
"MIT"
] | null | null | null | address/admin.py | City-of-Helsinki/geo-search | d200e06223938e456d13ae9ab94e9dad149216d0 | [
"MIT"
] | 11 | 2021-09-13T11:46:17.000Z | 2022-03-11T08:40:02.000Z | address/admin.py | City-of-Helsinki/geo-search | d200e06223938e456d13ae9ab94e9dad149216d0 | [
"MIT"
] | 1 | 2021-10-04T09:15:44.000Z | 2021-10-04T09:15:44.000Z | from django.contrib import admin
from parler.admin import TranslatableAdmin
from .models import Address, Municipality, Street
| 19.05 | 49 | 0.792651 |
93146c79f274fc09fa5d075dfc9d826dd48bbd57 | 7,704 | py | Python | src/pynwb/core.py | q0j0p/pynwb | 6c3a864662f2cce63b542f9f614cc632903f9bc1 | [
"BSD-3-Clause-LBNL"
] | null | null | null | src/pynwb/core.py | q0j0p/pynwb | 6c3a864662f2cce63b542f9f614cc632903f9bc1 | [
"BSD-3-Clause-LBNL"
] | 1 | 2021-06-01T22:25:36.000Z | 2021-06-01T22:25:36.000Z | src/pynwb/core.py | q0j0p/pynwb | 6c3a864662f2cce63b542f9f614cc632903f9bc1 | [
"BSD-3-Clause-LBNL"
] | null | null | null | from collections import Iterable
from h5py import RegionReference
from .form.utils import docval, getargs, ExtenderMeta, call_docval_func, popargs
from .form import Container, Data, DataRegion, get_region_slicer
from . import CORE_NAMESPACE, register_class
from six import with_metaclass
class NWBTable(NWBData):... | 35.666667 | 113 | 0.610462 |
9314b87cfdabe5d7ea05f8832e4b689d86e607b3 | 2,246 | py | Python | tests/test_get_google_streetview.py | AQ-AI/open-geo-engine | a9382083d5a51ffef4af0a76df7a6e15d64cbaf5 | [
"BSD-3-Clause"
] | null | null | null | tests/test_get_google_streetview.py | AQ-AI/open-geo-engine | a9382083d5a51ffef4af0a76df7a6e15d64cbaf5 | [
"BSD-3-Clause"
] | 19 | 2022-01-15T19:13:26.000Z | 2022-03-20T22:30:00.000Z | tests/test_get_google_streetview.py | AQ-AI/open-geo-engine | a9382083d5a51ffef4af0a76df7a6e15d64cbaf5 | [
"BSD-3-Clause"
] | 2 | 2022-01-18T11:34:28.000Z | 2022-03-01T15:54:45.000Z | import os
import pandas as pd
from open_geo_engine.src.get_google_streetview import GetGoogleStreetView
| 32.085714 | 93 | 0.661175 |
93157bdf0f57eb1e0ef1f559e165114bea5a6259 | 6,186 | py | Python | src/cirrus/selfupdate.py | Maxsparrow/cirrus | ae9639daba4f2d8d9285e98d5b11a89eac573f96 | [
"Apache-2.0"
] | 12 | 2016-04-30T16:13:55.000Z | 2021-01-20T23:42:31.000Z | src/cirrus/selfupdate.py | Maxsparrow/cirrus | ae9639daba4f2d8d9285e98d5b11a89eac573f96 | [
"Apache-2.0"
] | 153 | 2015-02-12T15:25:42.000Z | 2020-03-09T07:16:15.000Z | src/cirrus/selfupdate.py | Maxsparrow/cirrus | ae9639daba4f2d8d9285e98d5b11a89eac573f96 | [
"Apache-2.0"
] | 7 | 2015-06-15T21:30:38.000Z | 2020-02-17T02:13:00.000Z | #!/usr/bin/env python
"""
_selfupdate_
Util command for updating the cirrus install itself
Supports getting a spefified branch or tag, or defaults to
looking up the latest release and using that instead.
"""
import sys
import argparse
import arrow
import os
import requests
import inspect
import contextlib
from cirru... | 24.943548 | 95 | 0.619787 |
9315f46f0473c586d45b30c9a29e297a98f70f78 | 1,335 | py | Python | util.py | DrD1esel/GoWDiscordTeamBot | 9e61a386e2d341a42dd45b60eda7f57a95100283 | [
"BSD-3-Clause"
] | null | null | null | util.py | DrD1esel/GoWDiscordTeamBot | 9e61a386e2d341a42dd45b60eda7f57a95100283 | [
"BSD-3-Clause"
] | null | null | null | util.py | DrD1esel/GoWDiscordTeamBot | 9e61a386e2d341a42dd45b60eda7f57a95100283 | [
"BSD-3-Clause"
] | null | null | null | from base_bot import log
# https://stackoverflow.com/questions/7204805/how-to-merge-dictionaries-of-dictionaries
# merges b into a
def debug(message):
guild = '-'
if message.guild:
guild = message.guild.name
log.debug(f'[{guild}][{message.channel}][{message.author.display_name}] {message.co... | 23.421053 | 95 | 0.591011 |
93163adbfdd7c695f51e1b653629e2cdd3f9438d | 877 | py | Python | jsgf_tags.py | onchiptech/pyjsgf | f7ff26323e5e602ea10e7d302610c2fcb46234d6 | [
"MIT"
] | null | null | null | jsgf_tags.py | onchiptech/pyjsgf | f7ff26323e5e602ea10e7d302610c2fcb46234d6 | [
"MIT"
] | null | null | null | jsgf_tags.py | onchiptech/pyjsgf | f7ff26323e5e602ea10e7d302610c2fcb46234d6 | [
"MIT"
] | null | null | null | from jsgf import parse_grammar_string
if __name__ == '__main__':
import argparse
"""Prepares arguments for the demo"""
# Usage: python jsgf_tags.py test.jsgf out.jsgf
parser = argparse.ArgumentParser(description='expand JSGF grammar tags.')
parser.add_argument('input_file_path', type=str, h... | 28.290323 | 90 | 0.654504 |
931a1eefc8b03639fa3b9346aaf0553aa1293c86 | 2,685 | py | Python | webspider/utils/log.py | chem2099/webspider | 5577878b69d85a4b75ece6701f6018767d0ee4bc | [
"MIT"
] | 256 | 2017-06-01T10:56:41.000Z | 2019-06-28T17:26:08.000Z | webspider/utils/log.py | chem2099/webspider | 5577878b69d85a4b75ece6701f6018767d0ee4bc | [
"MIT"
] | 14 | 2017-10-30T14:32:08.000Z | 2019-05-27T09:49:39.000Z | webspider/utils/log.py | chem2099/webspider | 5577878b69d85a4b75ece6701f6018767d0ee4bc | [
"MIT"
] | 88 | 2017-09-01T08:06:48.000Z | 2019-06-26T06:23:04.000Z | # coding: utf-8
import os
import logging.config
from webspider import setting
LOG_FILE_PATH = os.path.join(setting.BASE_DIR, 'log', 'spider_log.txt')
LOGGING_CONFIG = {
'version': 1,
'disable_existing_loggers': True,
'formatters': {
'default': {
'format': '%(asctime)s- %(module)s:%(l... | 27.397959 | 100 | 0.448417 |
931abc49c69a201ff08a4c4d4963b916bcd4009f | 53,851 | py | Python | manila/tests/share/drivers/hitachi/hnas/test_driver.py | kpawar89/manila | d487c2db728cedf8357b9f4acbc0a45c21c3a83e | [
"Apache-2.0"
] | 1 | 2020-06-17T13:20:21.000Z | 2020-06-17T13:20:21.000Z | manila/tests/share/drivers/hitachi/hnas/test_driver.py | viroel/manila | fbcabd2c03985000bd9b4d4d9a4478bc0b784efa | [
"Apache-2.0"
] | null | null | null | manila/tests/share/drivers/hitachi/hnas/test_driver.py | viroel/manila | fbcabd2c03985000bd9b4d4d9a4478bc0b784efa | [
"Apache-2.0"
] | 1 | 2021-02-23T05:52:11.000Z | 2021-02-23T05:52:11.000Z | # Copyright (c) 2015 Hitachi Data Systems, Inc.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# U... | 42.236078 | 79 | 0.624705 |
931acb0aff55dcc9d21d89e7ab39172fc95002c7 | 2,978 | py | Python | sloth/test/dummy_data.py | maurov/xraysloth | 6f18ddcb02050431574693d46bcf4b89c719c40b | [
"BSD-3-Clause"
] | 4 | 2015-07-03T09:38:58.000Z | 2022-03-16T11:09:49.000Z | sloth/test/dummy_data.py | maurov/xraysloth | 6f18ddcb02050431574693d46bcf4b89c719c40b | [
"BSD-3-Clause"
] | null | null | null | sloth/test/dummy_data.py | maurov/xraysloth | 6f18ddcb02050431574693d46bcf4b89c719c40b | [
"BSD-3-Clause"
] | 2 | 2017-05-22T17:14:11.000Z | 2017-07-04T04:52:08.000Z | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Generate dummy data for tests/examples
"""
import numpy as np
def dummy_gauss_image(x=None, y=None,
xhalfrng=1.5, yhalfrng=None, xcen=0.5, ycen=0.9,
xnpts=1024, ynpts=None, xsigma=0.55, ysigma=0.25,
nois... | 28.09434 | 78 | 0.576897 |
931b5bb2e3fc783e728514ebc6699f871cd2d505 | 159 | py | Python | approximate_equilibrium/optimize/__init__.py | NREL/EMISApproximateEquilibrium.jl | a94ec58e812496cec3cb40bdb84b14229c1b6440 | [
"BSD-3-Clause"
] | 1 | 2021-12-04T06:37:50.000Z | 2021-12-04T06:37:50.000Z | approximate_equilibrium/optimize/__init__.py | NREL/EMISApproximateEquilibrium.jl | a94ec58e812496cec3cb40bdb84b14229c1b6440 | [
"BSD-3-Clause"
] | null | null | null | approximate_equilibrium/optimize/__init__.py | NREL/EMISApproximateEquilibrium.jl | a94ec58e812496cec3cb40bdb84b14229c1b6440 | [
"BSD-3-Clause"
] | null | null | null | from approximate_equilibrium.optimize.optimization import de_optimizer, objective_function, brute_force_optimizer, objective_function_iccn, gradient_optimizer
| 79.5 | 158 | 0.91195 |
931b8e121065b6e7d0568d8a4e43d037da1b3b77 | 4,295 | py | Python | dynatrace/environment_v2/networkzones.py | hashmibilaldt/api-client-python | 910008a4c6800a547535acba79b7a49e540b5d16 | [
"Apache-2.0"
] | null | null | null | dynatrace/environment_v2/networkzones.py | hashmibilaldt/api-client-python | 910008a4c6800a547535acba79b7a49e540b5d16 | [
"Apache-2.0"
] | null | null | null | dynatrace/environment_v2/networkzones.py | hashmibilaldt/api-client-python | 910008a4c6800a547535acba79b7a49e540b5d16 | [
"Apache-2.0"
] | null | null | null | """
Copyright 2021 Dynatrace LLC
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
... | 40.518868 | 122 | 0.723632 |
931c579da4bce33b29c5c9ae99f9be7566e00afb | 2,984 | py | Python | tools/scruffy/checkers/orgs.py | paultag/pupa | 137293925503496e15137540e049bf544e129971 | [
"BSD-3-Clause"
] | null | null | null | tools/scruffy/checkers/orgs.py | paultag/pupa | 137293925503496e15137540e049bf544e129971 | [
"BSD-3-Clause"
] | null | null | null | tools/scruffy/checkers/orgs.py | paultag/pupa | 137293925503496e15137540e049bf544e129971 | [
"BSD-3-Clause"
] | null | null | null | from .. import Check
from .common import common_checks
| 40.324324 | 76 | 0.464142 |