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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
12c5c79e7f95fd34c8892f6f44952e889b0051d1 | 111 | py | Python | backend/venv/src/api/ordercampproduct/apps.py | AkashSDas/camps_for_champs | 1bf7e51905b5b3efc47f94ffcfde7167dace4475 | [
"MIT"
] | null | null | null | backend/venv/src/api/ordercampproduct/apps.py | AkashSDas/camps_for_champs | 1bf7e51905b5b3efc47f94ffcfde7167dace4475 | [
"MIT"
] | null | null | null | backend/venv/src/api/ordercampproduct/apps.py | AkashSDas/camps_for_champs | 1bf7e51905b5b3efc47f94ffcfde7167dace4475 | [
"MIT"
] | null | null | null | from django.apps import AppConfig
| 18.5 | 40 | 0.792793 |
12c65927c0458f39714e96cf3347972f4ddf2a65 | 691 | py | Python | onnx_tf/handlers/backend/identity.py | ZemingZhao/onnx-tensorflow | 9ab9b934c2c8494b6309d20f15acabcb3abd126d | [
"Apache-2.0"
] | null | null | null | onnx_tf/handlers/backend/identity.py | ZemingZhao/onnx-tensorflow | 9ab9b934c2c8494b6309d20f15acabcb3abd126d | [
"Apache-2.0"
] | null | null | null | onnx_tf/handlers/backend/identity.py | ZemingZhao/onnx-tensorflow | 9ab9b934c2c8494b6309d20f15acabcb3abd126d | [
"Apache-2.0"
] | null | null | null | import tensorflow as tf
from onnx_tf.handlers.backend_handler import BackendHandler
from onnx_tf.handlers.handler import onnx_op
from onnx_tf.handlers.handler import tf_func
| 25.592593 | 59 | 0.726483 |
12c759447ac7e05d73a693a7af973c9ec776f540 | 42,699 | py | Python | raiden/tests/integration/api/test_restapi.py | litexnetwork/raiden | b084c77e994d1f08f72947e57ce5bd6c8aa9c2a9 | [
"MIT"
] | 1 | 2018-11-26T01:40:37.000Z | 2018-11-26T01:40:37.000Z | raiden/tests/integration/api/test_restapi.py | litexnetwork/raiden | b084c77e994d1f08f72947e57ce5bd6c8aa9c2a9 | [
"MIT"
] | null | null | null | raiden/tests/integration/api/test_restapi.py | litexnetwork/raiden | b084c77e994d1f08f72947e57ce5bd6c8aa9c2a9 | [
"MIT"
] | null | null | null | from http import HTTPStatus
import time
import logging
import pytest
import grequests
from flask import url_for
from eth_utils import (
to_checksum_address,
to_canonical_address,
is_checksum_address,
)
from raiden_contracts.constants import (
CONTRACT_HUMAN_STANDARD_TOKEN,
MAX_TOKENS_DEPLOY,
TE... | 32.769762 | 176 | 0.686035 |
12c7cbd02b14e09531a4f5ea52a53834f3434799 | 6,946 | py | Python | contents/MyExperiment/Exp3_test/cluster_env.py | Feng-XiaoYue/Reinforcement-learning-with-tensorflow-master | 011594083410f9b2f8e16eb5deed26e730ed849e | [
"MIT"
] | null | null | null | contents/MyExperiment/Exp3_test/cluster_env.py | Feng-XiaoYue/Reinforcement-learning-with-tensorflow-master | 011594083410f9b2f8e16eb5deed26e730ed849e | [
"MIT"
] | null | null | null | contents/MyExperiment/Exp3_test/cluster_env.py | Feng-XiaoYue/Reinforcement-learning-with-tensorflow-master | 011594083410f9b2f8e16eb5deed26e730ed849e | [
"MIT"
] | null | null | null | import numpy as np
import pandas as pd
import random
import time
import sys
if sys.version_info.major == 2:
import Tkinter as tk
else:
import tkinter as tk
# if __name__ == '__main__':
# server_attribute = pd.DataFrame(np.array([0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
# ... | 37.144385 | 145 | 0.460121 |
12c7d079f923030d66c22a1b6cf6b9b674f39635 | 2,589 | py | Python | libensemble/tests/regression_tests/test_6-hump_camel_elapsed_time_abort.py | Kardyne/libensemble | 566c8f5daafe2ad4deebc13198a1e131e4ce6542 | [
"BSD-2-Clause"
] | null | null | null | libensemble/tests/regression_tests/test_6-hump_camel_elapsed_time_abort.py | Kardyne/libensemble | 566c8f5daafe2ad4deebc13198a1e131e4ce6542 | [
"BSD-2-Clause"
] | null | null | null | libensemble/tests/regression_tests/test_6-hump_camel_elapsed_time_abort.py | Kardyne/libensemble | 566c8f5daafe2ad4deebc13198a1e131e4ce6542 | [
"BSD-2-Clause"
] | null | null | null | # """
# Runs libEnsemble on the 6-hump camel problem. Documented here:
# https://www.sfu.ca/~ssurjano/camel6.html
#
# Execute via the following command:
# mpiexec -np 4 python3 test_6-hump_camel_elapsed_time_abort.py
# The number of concurrent evaluations of the objective function will be 4-1=3.
# """
from __fut... | 34.52 | 151 | 0.653148 |
12c8a53eac5c028a5e825aaa86f201c528a2f671 | 1,329 | py | Python | do_like_javac/tools/graphtools.py | zcai1/do-like-javac | 3eb4a43521ae181a9b777a589e477b0c6ab7cb6e | [
"BSD-3-Clause-Clear",
"BSD-3-Clause"
] | 1 | 2020-10-10T20:24:08.000Z | 2020-10-10T20:24:08.000Z | do_like_javac/tools/graphtools.py | zcai1/do-like-javac | 3eb4a43521ae181a9b777a589e477b0c6ab7cb6e | [
"BSD-3-Clause-Clear",
"BSD-3-Clause"
] | 13 | 2019-06-20T23:16:15.000Z | 2022-03-26T21:19:20.000Z | do_like_javac/tools/graphtools.py | zcai1/do-like-javac | 3eb4a43521ae181a9b777a589e477b0c6ab7cb6e | [
"BSD-3-Clause-Clear",
"BSD-3-Clause"
] | 5 | 2016-09-23T00:52:12.000Z | 2021-09-08T01:24:36.000Z | import os
import argparse
from . import common
argparser = argparse.ArgumentParser(add_help=False)
graph_group = argparser.add_argument_group('graphtool arguments')
graph_group.add_argument('--graph-jar', metavar='<graphtool-jar>',
action='store',default=None, dest='graph_jar',
... | 30.906977 | 88 | 0.611738 |
12c8ff9bf299511a1712cec875fde79e159c64f4 | 507 | py | Python | boss_grabbing/pipelines.py | shansb/boss_grabbing | 20aabd6b2062099eb287d7586dcf619648569ba2 | [
"MIT"
] | null | null | null | boss_grabbing/pipelines.py | shansb/boss_grabbing | 20aabd6b2062099eb287d7586dcf619648569ba2 | [
"MIT"
] | null | null | null | boss_grabbing/pipelines.py | shansb/boss_grabbing | 20aabd6b2062099eb287d7586dcf619648569ba2 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
# Define your item pipelines here
#
# Don't forget to add your pipeline to the ITEM_PIPELINES setting
# See: https://doc.scrapy.org/en/latest/topics/item-pipeline.html
from boss_grabbing.sqlite import Sqlite
| 25.35 | 65 | 0.65286 |
12c9169d04a1b953b055c11fb6f8b67fa66071ff | 344 | py | Python | core/jobs/urls.py | InKyrNet/inkyrnet | fdb5c8def9b74049c4b48f2fccf5d52b040a4435 | [
"MIT"
] | null | null | null | core/jobs/urls.py | InKyrNet/inkyrnet | fdb5c8def9b74049c4b48f2fccf5d52b040a4435 | [
"MIT"
] | 4 | 2021-06-04T21:36:18.000Z | 2021-09-22T17:44:09.000Z | core/jobs/urls.py | InKyrNet/inkyrnet | fdb5c8def9b74049c4b48f2fccf5d52b040a4435 | [
"MIT"
] | null | null | null | from django.urls import path
from .views import *
from django_filters.views import FilterView
app_name = 'jobs'
urlpatterns = [
path('', FilterView.as_view(filterset_class=JobFilter,
template_name='jobs/job_list.html'), name='index'),
path('companies/', CompanyListView.as_view(... | 28.666667 | 83 | 0.674419 |
12c9326e60a2f14e4ff7c33d36e504ccc28441b7 | 2,010 | py | Python | src/compas/datastructures/mesh/transformations_numpy.py | arpastrana/compas | ed677a162c14dbe562c82d72f370279259faf7da | [
"MIT"
] | 2 | 2021-03-17T18:14:22.000Z | 2021-09-19T13:50:02.000Z | src/compas/datastructures/mesh/transformations_numpy.py | arpastrana/compas | ed677a162c14dbe562c82d72f370279259faf7da | [
"MIT"
] | null | null | null | src/compas/datastructures/mesh/transformations_numpy.py | arpastrana/compas | ed677a162c14dbe562c82d72f370279259faf7da | [
"MIT"
] | null | null | null | from __future__ import print_function
from __future__ import absolute_import
from __future__ import division
from compas.geometry import transform_points_numpy
__all__ = [
'mesh_transform_numpy',
'mesh_transformed_numpy',
]
def mesh_transform_numpy(mesh, transformation):
"""Transform a mesh.
Param... | 24.216867 | 80 | 0.595025 |
12c93b56f0fe4bfd1cf140c773e7ff17f7dd5689 | 17,860 | py | Python | selfdrive/car/gm/carcontroller.py | CTyrell/openpilot | 1ef27823882eed575266983175f106af1e293082 | [
"MIT"
] | null | null | null | selfdrive/car/gm/carcontroller.py | CTyrell/openpilot | 1ef27823882eed575266983175f106af1e293082 | [
"MIT"
] | null | null | null | selfdrive/car/gm/carcontroller.py | CTyrell/openpilot | 1ef27823882eed575266983175f106af1e293082 | [
"MIT"
] | null | null | null | from cereal import car
from common.realtime import DT_CTRL
from common.numpy_fast import interp
from common.realtime import sec_since_boot
from selfdrive.config import Conversions as CV
from selfdrive.car import apply_std_steer_torque_limits
from selfdrive.car.gm import gmcan
from selfdrive.car.gm.values import DBC, Ac... | 54.45122 | 203 | 0.693729 |
12ca7aec9c936b7e376b5d6d2ed2e6e550f43708 | 8,570 | py | Python | src/rprblender/__init__.py | ralic/RadeonProRenderBlenderAddon | 310c650d4230289ac5d5407cc24a13b4c7ce0a90 | [
"Apache-2.0"
] | 1 | 2021-03-29T05:55:49.000Z | 2021-03-29T05:55:49.000Z | src/rprblender/__init__.py | ralic/RadeonProRenderBlenderAddon | 310c650d4230289ac5d5407cc24a13b4c7ce0a90 | [
"Apache-2.0"
] | 1 | 2021-04-03T09:39:28.000Z | 2021-04-03T09:39:28.000Z | src/rprblender/__init__.py | isabella232/RadeonProRenderBlenderAddon | ff4ede164c1e1e909f182be709422bc8c8878b1c | [
"Apache-2.0"
] | null | null | null | #**********************************************************************
# Copyright 2020 Advanced Micro Devices, 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.o... | 31.391941 | 116 | 0.655076 |
12cc0f45c792a01e3a5bd5c42c13138e07ace531 | 1,561 | py | Python | plot_metric_err_vs_dim.py | wchen459/design_embeddings_jmd_2016 | 30dfec40b14c81e6cbe1c57efc2abe1a28dbdd5f | [
"MIT"
] | 9 | 2017-07-13T19:17:48.000Z | 2022-03-17T02:19:06.000Z | plot_metric_err_vs_dim.py | wchen459/design_embeddings_jmd_2016 | 30dfec40b14c81e6cbe1c57efc2abe1a28dbdd5f | [
"MIT"
] | null | null | null | plot_metric_err_vs_dim.py | wchen459/design_embeddings_jmd_2016 | 30dfec40b14c81e6cbe1c57efc2abe1a28dbdd5f | [
"MIT"
] | 2 | 2018-08-31T22:46:03.000Z | 2020-06-19T16:17:38.000Z | """
Plots reconstruction error vs semantic space dimensionality
Usage: python metric_err_vs_dim.py
Author(s): Wei Chen (wchen459@umd.edu)
"""
import matplotlib.pyplot as plt
import numpy as np
plt.rc("font", size=18)
examples = ['glass', 'sf_linear', 'sf_s_nonlinear', 'sf_v_nonlinear']
titles = {'glass': ... | 31.22 | 104 | 0.606022 |
12cc8345dd761da772a7145052f730ec8abb45f7 | 621 | py | Python | tools/pot/openvino/tools/pot/graph/gpu_patterns.py | ryanloney/openvino-1 | 4e0a740eb3ee31062ba0df88fcf438564f67edb7 | [
"Apache-2.0"
] | 1,127 | 2018-10-15T14:36:58.000Z | 2020-04-20T09:29:44.000Z | tools/pot/openvino/tools/pot/graph/gpu_patterns.py | ryanloney/openvino-1 | 4e0a740eb3ee31062ba0df88fcf438564f67edb7 | [
"Apache-2.0"
] | 439 | 2018-10-20T04:40:35.000Z | 2020-04-19T05:56:25.000Z | tools/pot/openvino/tools/pot/graph/gpu_patterns.py | ryanloney/openvino-1 | 4e0a740eb3ee31062ba0df88fcf438564f67edb7 | [
"Apache-2.0"
] | 414 | 2018-10-17T05:53:46.000Z | 2020-04-16T17:29:53.000Z | # Copyright (C) 2020-2022 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
from .pattern_utils import check_fused_scale_shift_patterns, get_fused_scale_shift_patterns, \
check_fused_op_const_patterns, get_fused_op_const_pattern, get_clamp_mult_const_pattern
| 41.4 | 113 | 0.756844 |
12ccbde3bf71864760496c1e1f0963111fba9314 | 638 | py | Python | test/environments/instances/8x8/gen.py | Multi-Agent-Research-Group/hog2 | 544d7c0e933fd69025944a0a3abcf9a40e59f0be | [
"MIT"
] | 5 | 2020-08-03T09:43:26.000Z | 2022-01-11T08:28:30.000Z | test/environments/instances/8x8/gen.py | Multi-Agent-Research-Group/hog2 | 544d7c0e933fd69025944a0a3abcf9a40e59f0be | [
"MIT"
] | null | null | null | test/environments/instances/8x8/gen.py | Multi-Agent-Research-Group/hog2 | 544d7c0e933fd69025944a0a3abcf9a40e59f0be | [
"MIT"
] | 7 | 2017-07-31T13:01:28.000Z | 2021-05-16T10:15:49.000Z | #!/usr/bin/python
import random
import os
import errno
for i in range(100):
s=set()
g=set()
while len(s) < 50:
s.add((random.randint(0,7),random.randint(0,7)))
while len(g) < 50:
g.add((random.randint(0,7),random.randint(0,7)))
start=list(s)
goal=list(g)
for size in range(21,50):
if not os... | 22.785714 | 80 | 0.548589 |
12ccd738c589b9032a098324390886166233073c | 2,308 | py | Python | pose_recognition_from_camera_demo.py | amazingchow/capture-dance-using-mediapipe | 1963d461b4e047308da78b1bb88b9ed1f2c3c7d1 | [
"MIT"
] | null | null | null | pose_recognition_from_camera_demo.py | amazingchow/capture-dance-using-mediapipe | 1963d461b4e047308da78b1bb88b9ed1f2c3c7d1 | [
"MIT"
] | null | null | null | pose_recognition_from_camera_demo.py | amazingchow/capture-dance-using-mediapipe | 1963d461b4e047308da78b1bb88b9ed1f2c3c7d1 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
import argparse
import cv2 as cv
import mediapipe as mp
import sys
import time
if __name__ == "__main__":
parser = argparse.ArgumentParser()
parser.add_argument("--video_device", type=int, default=0)
parser.add_argument("--video_file", type=str, default="")
args = parser.pars... | 35.507692 | 101 | 0.561958 |
12ce678d7b9581bc7d8e71fefb2ce7346256d86f | 1,901 | py | Python | reference/data_dict_export.py | TBody/atomic1D | fcab88f3b303468f23ac75b847c76244593f4b7f | [
"MIT"
] | 1 | 2019-05-18T22:32:21.000Z | 2019-05-18T22:32:21.000Z | reference/data_dict_export.py | TBody/atomic1D | fcab88f3b303468f23ac75b847c76244593f4b7f | [
"MIT"
] | null | null | null | reference/data_dict_export.py | TBody/atomic1D | fcab88f3b303468f23ac75b847c76244593f4b7f | [
"MIT"
] | null | null | null | # Program name: atomic1D/reference/build_json.py
# Author: Thomas Body
# Author email: tajb500@york.ac.uk
# Date of creation: 14 July 2017
#
#
# Makes data_dict and copies it into a .json file 'sd1d-case-05.json'
filename = 'sd1d-case-05'
from boutdata.collect import collect
data_dict = {}
# Normalisation factor ... | 36.557692 | 172 | 0.730668 |
12cf323ab36261eee5e0ca79f3a3c93c62ed377b | 3,300 | py | Python | wordDocComposite.py | flyonok/image2text | 0c16e6bf35eb486e6ff28e9e402a18bea6bd338c | [
"Apache-1.1"
] | null | null | null | wordDocComposite.py | flyonok/image2text | 0c16e6bf35eb486e6ff28e9e402a18bea6bd338c | [
"Apache-1.1"
] | null | null | null | wordDocComposite.py | flyonok/image2text | 0c16e6bf35eb486e6ff28e9e402a18bea6bd338c | [
"Apache-1.1"
] | null | null | null | from docx import Document
def CompositeTwoDocs(srcDocFullName, dstDocFullName, compositeName):
'''
srcDocFullName:
dstDocFullName:
compositeName:
return: ->True->False
'''
try:
srcDoc = Document(srcDocFullName)
dstDoc = Document(dstDocFullName)
srcParasMap = {} # H... | 40.740741 | 101 | 0.538485 |
12d0afe950ed445eb9f7e907ee14e9a851acd904 | 4,853 | py | Python | app/cover.py | mrwiwi/tydom2mqtt | 293322033b67521bb981af1c8c2245ca9af6c646 | [
"MIT"
] | 26 | 2020-04-07T17:58:24.000Z | 2022-02-12T16:28:44.000Z | app/cover.py | mrwiwi/tydom2mqtt | 293322033b67521bb981af1c8c2245ca9af6c646 | [
"MIT"
] | 19 | 2020-03-25T09:46:46.000Z | 2021-11-29T09:55:57.000Z | app/cover.py | mrwiwi/tydom2mqtt | 293322033b67521bb981af1c8c2245ca9af6c646 | [
"MIT"
] | 26 | 2020-04-27T21:40:12.000Z | 2022-01-06T14:44:22.000Z | import json
import time
from datetime import datetime
from sensors import sensor
cover_command_topic = "cover/tydom/{id}/set_positionCmd"
cover_config_topic = "homeassistant/cover/tydom/{id}/config"
cover_position_topic = "cover/tydom/{id}/current_position"
cover_set_postion_topic = "cover/tydom/{id}/set_position"
cov... | 37.914063 | 147 | 0.622708 |
12d29fab22f07b19b231bdfe08bc053825594e45 | 56,823 | py | Python | edx/config/lms/docker_run.py | openfun/learning-analytics-playground | dca80d89ca781d9060bd69927af4aa1462cc53ef | [
"MIT"
] | 1 | 2021-12-13T09:05:59.000Z | 2021-12-13T09:05:59.000Z | edx/config/lms/docker_run.py | openfun/learning-analytics-playground | dca80d89ca781d9060bd69927af4aa1462cc53ef | [
"MIT"
] | 3 | 2021-05-18T08:26:51.000Z | 2022-03-14T10:34:36.000Z | edx/config/lms/docker_run.py | openfun/learning-analytics-playground | dca80d89ca781d9060bd69927af4aa1462cc53ef | [
"MIT"
] | 1 | 2021-06-03T14:21:56.000Z | 2021-06-03T14:21:56.000Z | """
This is the default template for our main set of servers. This does NOT
cover the content machines, which use content.py
Common traits:
* Use memcached, and cache-backed sessions
* Use a MySQL 5.1 database
"""
# We intentionally define lots of variables that aren't used, and
# want to import all variables from ba... | 36.239158 | 140 | 0.724671 |
12d2af7e340f2c0b16013db0e187eff0a983f2ec | 14,028 | py | Python | stashboard/handlers/site.py | kelnos/stashboard | 5f92ed14b8cf17f4b1be8441005b187e97ca74b8 | [
"MIT"
] | 1 | 2015-02-24T23:30:06.000Z | 2015-02-24T23:30:06.000Z | stashboard/handlers/site.py | ratchetio/stashboard | f8e4e6d175f48701a154e4baca10de2a4a577ab4 | [
"MIT"
] | null | null | null | stashboard/handlers/site.py | ratchetio/stashboard | f8e4e6d175f48701a154e4baca10de2a4a577ab4 | [
"MIT"
] | null | null | null | # The MIT License
#
# Copyright (c) 2008 William T. Katz
#
# 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,... | 32.852459 | 149 | 0.590961 |
12d4213a1f0e884d767b82004cfca76be19c9038 | 1,375 | py | Python | bga/forms.py | KarmaPoliceT2/bga | f7708ddae72bc83d68a2294d8f1b600345ebec30 | [
"MIT"
] | null | null | null | bga/forms.py | KarmaPoliceT2/bga | f7708ddae72bc83d68a2294d8f1b600345ebec30 | [
"MIT"
] | 3 | 2019-12-26T16:57:34.000Z | 2021-06-01T23:08:35.000Z | bga/forms.py | KarmaPoliceT2/bga | f7708ddae72bc83d68a2294d8f1b600345ebec30 | [
"MIT"
] | null | null | null | from wtforms import Form, StringField, PasswordField, DecimalField, IntegerField, SelectField, validators
from wtforms.fields.html5 import DateField
| 42.96875 | 105 | 0.696 |
12d68f272974ae7982471fbca3af702e552c3c1f | 597 | py | Python | ejercicios_python/Clase05/practica5-9.py | hcgalvan/UNSAM-Python-programming | c4b3f5ae0702dc03ea6010cb8051c7eec6aef42f | [
"MIT"
] | null | null | null | ejercicios_python/Clase05/practica5-9.py | hcgalvan/UNSAM-Python-programming | c4b3f5ae0702dc03ea6010cb8051c7eec6aef42f | [
"MIT"
] | null | null | null | ejercicios_python/Clase05/practica5-9.py | hcgalvan/UNSAM-Python-programming | c4b3f5ae0702dc03ea6010cb8051c7eec6aef42f | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
"""
Created on Wed Sep 15 08:32:03 2021
@author: User
"""
import numpy as np
import matplotlib.pyplot as plt
a = np.array([[1, 2, 3, 4], [5, 6, 7, 8], [9, 10, 11, 12]])
print(a)
print(a[0])
print(a.ndim) #te dice la cantidad de ejes (o dimensiones) del arreglo
print(a.shape) #Te va a dar una t... | 22.111111 | 98 | 0.649916 |
12d6fdba24bc3c779da8bc89c659942cc66fb630 | 9,284 | py | Python | cluster_toolkit/xi.py | jhod0/cluster_toolkit | b515b39fc4d0a17c19be4530a75d089d190f50cb | [
"MIT"
] | null | null | null | cluster_toolkit/xi.py | jhod0/cluster_toolkit | b515b39fc4d0a17c19be4530a75d089d190f50cb | [
"MIT"
] | 6 | 2019-08-14T18:54:23.000Z | 2019-09-19T22:10:42.000Z | cluster_toolkit/xi.py | jhod0/cluster_toolkit | b515b39fc4d0a17c19be4530a75d089d190f50cb | [
"MIT"
] | null | null | null | """Correlation functions for matter and halos.
"""
import cluster_toolkit
from cluster_toolkit import _ArrayWrapper, _handle_gsl_error
import numpy as np
def xi_nfw_at_r(r, M, c, Omega_m, delta=200):
"""NFW halo profile correlation function.
Args:
r (float or array like): 3d distances from halo cente... | 40.190476 | 198 | 0.62193 |
12d736e2a136d27d71bf7901bba9c44692b70118 | 1,500 | py | Python | Tools/scripts/rgrep.py | ystk/debian-python3.1 | 6241444a6994140621d1b143a2d6b311b184366a | [
"PSF-2.0"
] | 1 | 2015-05-21T23:47:54.000Z | 2015-05-21T23:47:54.000Z | Tools/scripts/rgrep.py | ystk/debian-python3.1 | 6241444a6994140621d1b143a2d6b311b184366a | [
"PSF-2.0"
] | 1 | 2015-10-29T20:51:31.000Z | 2015-10-29T20:51:31.000Z | Tools/scripts/rgrep.py | ystk/debian-python3.1 | 6241444a6994140621d1b143a2d6b311b184366a | [
"PSF-2.0"
] | 2 | 2018-08-06T04:37:38.000Z | 2022-02-27T18:07:12.000Z | #! /usr/bin/env python
"""Reverse grep.
Usage: rgrep [-i] pattern file
"""
import sys
import re
import getopt
if __name__ == '__main__':
main()
| 23.076923 | 66 | 0.519333 |
12d758ba9b3d6c5825fba951fa8141e8f0dd86e9 | 5,161 | py | Python | licel_format_parser/main.py | IFAEControl/lidar-cli | 02480ecd932cad1e11a04d866eb2eafc214f678d | [
"BSD-3-Clause"
] | null | null | null | licel_format_parser/main.py | IFAEControl/lidar-cli | 02480ecd932cad1e11a04d866eb2eafc214f678d | [
"BSD-3-Clause"
] | null | null | null | licel_format_parser/main.py | IFAEControl/lidar-cli | 02480ecd932cad1e11a04d866eb2eafc214f678d | [
"BSD-3-Clause"
] | null | null | null | import struct
f = open("c0610400.102200", 'rb')
def read_dataset(file):
ch = file.read(1)
buf = []
while True:
if chr(ch[0]) == '\n' and chr(buf[-1]) == '\r':
break
buf.append(ch[0])
ch = file.read(1)
buf.append(ch[0])
return bytes(buf)
h = Header()
p... | 33.083333 | 118 | 0.571207 |
12d85c3f8e0b325f0104a7462f8c848f6627e0a1 | 7,073 | py | Python | built-in/TensorFlow/Official/nlp/BertLarge_ID0634_for_TensorFlow2.X/bert/tf2_common/training/optimizer_v2modified.py | Ascend/modelzoo | f018cfed33dbb1cc2110b9ea2e233333f71cc509 | [
"Apache-2.0"
] | 12 | 2020-12-13T08:34:24.000Z | 2022-03-20T15:17:17.000Z | built-in/TensorFlow/Official/nlp/BertLarge_ID0634_for_TensorFlow2.X/bert/tf2_common/training/optimizer_v2modified.py | Ascend/modelzoo | f018cfed33dbb1cc2110b9ea2e233333f71cc509 | [
"Apache-2.0"
] | 1 | 2022-01-20T03:11:05.000Z | 2022-01-20T06:53:39.000Z | built-in/TensorFlow/Official/nlp/BertLarge_ID0634_for_TensorFlow2.X/bert/tf2_common/training/optimizer_v2modified.py | Ascend/modelzoo | f018cfed33dbb1cc2110b9ea2e233333f71cc509 | [
"Apache-2.0"
] | 2 | 2021-07-10T12:40:46.000Z | 2021-12-17T07:55:15.000Z | # Copyright 2018 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applica... | 42.10119 | 88 | 0.713276 |
12d9793b66d488d4aab6750551143953a771ab71 | 4,828 | py | Python | src/data/utils.py | behavioral-data/multiverse | 82b7265de0aa3e9d229ce9f3f86b8b48435ca365 | [
"MIT"
] | null | null | null | src/data/utils.py | behavioral-data/multiverse | 82b7265de0aa3e9d229ce9f3f86b8b48435ca365 | [
"MIT"
] | null | null | null | src/data/utils.py | behavioral-data/multiverse | 82b7265de0aa3e9d229ce9f3f86b8b48435ca365 | [
"MIT"
] | 1 | 2021-08-19T15:21:50.000Z | 2021-08-19T15:21:50.000Z | import os
import errno
import requests
import glob
import os
import json
from tqdm import tqdm
from selenium import webdriver
from selenium.webdriver.firefox.options import Options
| 31.555556 | 94 | 0.570008 |
12da373705e611aa87f9b708815df70bbd6ae325 | 14,870 | py | Python | jocular/calibrator.py | MartinCooke/jocular | 635816d4ef6aa6ea75187137e25386dad2d551e9 | [
"MIT"
] | 6 | 2021-03-21T16:46:44.000Z | 2021-11-27T14:07:06.000Z | jocular/calibrator.py | MartinCooke/jocular | 635816d4ef6aa6ea75187137e25386dad2d551e9 | [
"MIT"
] | null | null | null | jocular/calibrator.py | MartinCooke/jocular | 635816d4ef6aa6ea75187137e25386dad2d551e9 | [
"MIT"
] | null | null | null | ''' Handles calibration library and calibration of subs.
'''
import os.path
import numpy as np
from scipy.stats import trimboth
from kivy.app import App
from loguru import logger
from kivy.properties import BooleanProperty, DictProperty, NumericProperty
from kivy.core.window import Window
from jocular.table import T... | 39.028871 | 123 | 0.571688 |
12dbd5bf3d381ee625187e0ae26efd79aef7f23a | 1,128 | py | Python | test/office_schema.py | chrismaille/marshmallow-pynamodb | 1e799041ff1053a6aa67ce72729e7262cb0f746f | [
"MIT"
] | 3 | 2020-05-17T15:04:27.000Z | 2021-08-12T14:27:15.000Z | test/office_schema.py | chrismaille/marshmallow-pynamodb | 1e799041ff1053a6aa67ce72729e7262cb0f746f | [
"MIT"
] | 2 | 2020-05-06T00:11:49.000Z | 2022-02-23T11:45:54.000Z | test/office_schema.py | chrismaille/marshmallow-pynamodb | 1e799041ff1053a6aa67ce72729e7262cb0f746f | [
"MIT"
] | 1 | 2020-04-30T19:34:22.000Z | 2020-04-30T19:34:22.000Z | from test.office_model import Headquarters, Office
from marshmallow import fields
from pynamodb.attributes import DiscriminatorAttribute
from marshmallow_pynamodb import ModelSchema
| 22.117647 | 63 | 0.721631 |
12ddf9c1d17cbd9db7aea277570f0278393c93a6 | 1,599 | py | Python | energy_demand/initalisations/initialisations.py | willu47/energy_demand | 59a2712f353f47e3dc237479cc6cc46666b7d0f1 | [
"MIT"
] | null | null | null | energy_demand/initalisations/initialisations.py | willu47/energy_demand | 59a2712f353f47e3dc237479cc6cc46666b7d0f1 | [
"MIT"
] | null | null | null | energy_demand/initalisations/initialisations.py | willu47/energy_demand | 59a2712f353f47e3dc237479cc6cc46666b7d0f1 | [
"MIT"
] | null | null | null | """Helper initialising functions
"""
#pylint: disable=I0011, C0321, C0301, C0103, C0325, R0902, R0913, no-member, E0213
def init_fuel_tech_p_by(all_enduses_with_fuels, nr_of_fueltypes):
"""Helper function to define stocks for all enduse and fueltype
Parameters
----------
all_enduses_with_fuels : dict
... | 24.984375 | 104 | 0.676048 |
12df0714eb5fa8ab8f6068ed158fd58746d6bc32 | 37 | py | Python | npd_well_decoder/__init__.py | fmell/npd-well-name-decoder | a44ec28a6ef3b32ba38751eeffff479008b53e2d | [
"MIT"
] | null | null | null | npd_well_decoder/__init__.py | fmell/npd-well-name-decoder | a44ec28a6ef3b32ba38751eeffff479008b53e2d | [
"MIT"
] | null | null | null | npd_well_decoder/__init__.py | fmell/npd-well-name-decoder | a44ec28a6ef3b32ba38751eeffff479008b53e2d | [
"MIT"
] | null | null | null | from .npd import parse_wellbore_name
| 18.5 | 36 | 0.864865 |
12e000a4e8578ea58e111e55e0187884ea14b784 | 26,842 | py | Python | Lib/site-packages/wx-3.0-msw/wx/tools/Editra/src/util.py | jickieduan/python27 | c752b552396bbed68d8555080d475718cea2edd0 | [
"bzip2-1.0.6"
] | 5 | 2019-03-11T14:30:31.000Z | 2021-12-04T14:11:54.000Z | Lib/site-packages/wx-3.0-msw/wx/tools/Editra/src/util.py | jickieduan/python27 | c752b552396bbed68d8555080d475718cea2edd0 | [
"bzip2-1.0.6"
] | 1 | 2018-07-28T20:07:04.000Z | 2018-07-30T18:28:34.000Z | Lib/site-packages/wx-3.0-msw/wx/tools/Editra/src/util.py | jickieduan/python27 | c752b552396bbed68d8555080d475718cea2edd0 | [
"bzip2-1.0.6"
] | 2 | 2019-12-02T01:39:10.000Z | 2021-02-13T22:41:00.000Z | ###############################################################################
# Name: util.py #
# Purpose: Misc utility functions used through out Editra #
# Author: Cody Precord <cprecord@editra.org> #
... | 33.891414 | 80 | 0.595671 |
12e061c5c6e2f04c0f2228f70f6bcd0e8dd58774 | 1,105 | py | Python | genrl/environments/vec_env/utils.py | matrig/genrl | 25eb018f18a9a1d0865c16e5233a2a7ccddbfd78 | [
"MIT"
] | 390 | 2020-05-03T17:34:02.000Z | 2022-03-05T11:29:07.000Z | genrl/environments/vec_env/utils.py | matrig/genrl | 25eb018f18a9a1d0865c16e5233a2a7ccddbfd78 | [
"MIT"
] | 306 | 2020-05-03T05:53:53.000Z | 2022-03-12T00:27:28.000Z | genrl/environments/vec_env/utils.py | matrig/genrl | 25eb018f18a9a1d0865c16e5233a2a7ccddbfd78 | [
"MIT"
] | 64 | 2020-05-05T20:23:30.000Z | 2022-03-30T08:43:10.000Z | from typing import Tuple
import torch
| 28.333333 | 77 | 0.611765 |
12e064fd8ee7774d0bfca223891f1c72e7cca90f | 2,752 | py | Python | releases/pota-windows-1.3-ai5.0.2.0/ae/aiPotaTemplate.py | sumitneup/pota | a1d7a59b5ca29813d8b7f3fa77cca0a47404b785 | [
"MIT"
] | null | null | null | releases/pota-windows-1.3-ai5.0.2.0/ae/aiPotaTemplate.py | sumitneup/pota | a1d7a59b5ca29813d8b7f3fa77cca0a47404b785 | [
"MIT"
] | null | null | null | releases/pota-windows-1.3-ai5.0.2.0/ae/aiPotaTemplate.py | sumitneup/pota | a1d7a59b5ca29813d8b7f3fa77cca0a47404b785 | [
"MIT"
] | null | null | null | import mtoa.ui.ae.templates as templates
import pymel.core as pm
import maya.cmds as cmds
import mtoa.ui.ae.utils as aeUtils
templates.registerTranslatorUI(aiPotaTemplate, "camera", "pota") | 39.884058 | 135 | 0.673328 |
12e101d3d1c0a3624036d3fc55bbec2095eca800 | 2,690 | py | Python | tests/test_user.py | munniomer/Send-IT-Api-v1 | 17041c987638c7e47c7c2ebed29bf7e2b5156bed | [
"CNRI-Python",
"OML"
] | null | null | null | tests/test_user.py | munniomer/Send-IT-Api-v1 | 17041c987638c7e47c7c2ebed29bf7e2b5156bed | [
"CNRI-Python",
"OML"
] | null | null | null | tests/test_user.py | munniomer/Send-IT-Api-v1 | 17041c987638c7e47c7c2ebed29bf7e2b5156bed | [
"CNRI-Python",
"OML"
] | 1 | 2019-02-05T07:44:19.000Z | 2019-02-05T07:44:19.000Z | import unittest
from app import create_app
import json
from tests.basetest import BaseTest
| 42.03125 | 99 | 0.637546 |
12e130d67ccfe9de3b3564473e4a39882ddb1111 | 583 | py | Python | authors/apps/profiles/migrations/0023_auto_20190124_1222.py | andela/ah-django-unchained | a4e5f6cd11fdc0b9422020693ac1200b849cf0f3 | [
"BSD-3-Clause"
] | null | null | null | authors/apps/profiles/migrations/0023_auto_20190124_1222.py | andela/ah-django-unchained | a4e5f6cd11fdc0b9422020693ac1200b849cf0f3 | [
"BSD-3-Clause"
] | 26 | 2019-01-07T14:22:05.000Z | 2019-02-28T17:11:48.000Z | authors/apps/profiles/migrations/0023_auto_20190124_1222.py | andela/ah-django-unchained | a4e5f6cd11fdc0b9422020693ac1200b849cf0f3 | [
"BSD-3-Clause"
] | 3 | 2019-09-19T22:16:09.000Z | 2019-10-16T21:16:16.000Z | # Generated by Django 2.1.4 on 2019-01-24 12:22
from django.db import migrations, models
| 24.291667 | 63 | 0.595197 |
12e2d80d29d4efd869955ca94be7cd962776dc80 | 811 | py | Python | Algorithm/ShellSort/pyShellSort.py | commanderHR1/algorithms | d077364e8b08ae2b7b93bc01a73f622421086365 | [
"MIT"
] | 1 | 2020-07-17T20:49:55.000Z | 2020-07-17T20:49:55.000Z | Algorithm/ShellSort/pyShellSort.py | commanderHR1/algorithms | d077364e8b08ae2b7b93bc01a73f622421086365 | [
"MIT"
] | null | null | null | Algorithm/ShellSort/pyShellSort.py | commanderHR1/algorithms | d077364e8b08ae2b7b93bc01a73f622421086365 | [
"MIT"
] | null | null | null | # Implementation of Shell Sort algorithm in Python
l = [4, 1, 2, 5, 3]
print("Initial list: " + str(l))
shellSort(l)
print("Sorted list: " + str(l))
| 26.16129 | 70 | 0.477189 |
12e5018fbac310b4e1d16e7744a8549158b1a76a | 1,943 | py | Python | photos/models.py | benjaminbills/galleria | 4c89f265a2f4f853a5685828d5bc505b51b9bb74 | [
"MIT"
] | null | null | null | photos/models.py | benjaminbills/galleria | 4c89f265a2f4f853a5685828d5bc505b51b9bb74 | [
"MIT"
] | null | null | null | photos/models.py | benjaminbills/galleria | 4c89f265a2f4f853a5685828d5bc505b51b9bb74 | [
"MIT"
] | null | null | null | from django.db import models
# Create your models here. | 26.986111 | 79 | 0.691199 |
12e533fd59ecf8d6a32514514fcb290ff13e6ec1 | 1,322 | py | Python | main.py | kramrm/gcf-alerting-discord | c73d88520a783f9c4d12099bb8e21f03a950eebc | [
"MIT"
] | null | null | null | main.py | kramrm/gcf-alerting-discord | c73d88520a783f9c4d12099bb8e21f03a950eebc | [
"MIT"
] | null | null | null | main.py | kramrm/gcf-alerting-discord | c73d88520a783f9c4d12099bb8e21f03a950eebc | [
"MIT"
] | null | null | null | import base64
import json
from webhook import post_webhook
from datetime import datetime
def hello_pubsub(event, context):
"""Triggered from a message on a Cloud Pub/Sub topic.
Args:
event (dict): Event payload.
context (google.cloud.functions.Context): Metadata for the event.
"""
pubs... | 38.882353 | 99 | 0.683812 |
12e58dae1b7214722dcef0c29dfe11fbbf4c0b51 | 358 | py | Python | libzyre.py | brettviren/wafit | 39e9f2748c095dc4c3421a5de0f10f300d8da30b | [
"BSD-3-Clause"
] | null | null | null | libzyre.py | brettviren/wafit | 39e9f2748c095dc4c3421a5de0f10f300d8da30b | [
"BSD-3-Clause"
] | null | null | null | libzyre.py | brettviren/wafit | 39e9f2748c095dc4c3421a5de0f10f300d8da30b | [
"BSD-3-Clause"
] | null | null | null | #!/usr/bin/env waf
'''
This is a wafit tool for using zyre
'''
import util
| 21.058824 | 68 | 0.667598 |
12e5fe65e4d8ed7a4606ea760b1a56fc1a8485e1 | 6,226 | py | Python | scripts/run-gmm.py | vr100/nfl-kaggle | 74386b672ef4bb894bdf943df866855c4b555ede | [
"MIT"
] | null | null | null | scripts/run-gmm.py | vr100/nfl-kaggle | 74386b672ef4bb894bdf943df866855c4b555ede | [
"MIT"
] | null | null | null | scripts/run-gmm.py | vr100/nfl-kaggle | 74386b672ef4bb894bdf943df866855c4b555ede | [
"MIT"
] | null | null | null | import argparse, os, fnmatch, json, joblib
import pandas as pd
from sklearn.mixture import GaussianMixture
from sklearn.metrics import adjusted_rand_score
# Reference paper - https://arxiv.org/abs/1906.11373
# "Unsupervised Methods for Identifying Pass Coverage Among Defensive Backs with NFL Player Tracking Data"
STA... | 32.092784 | 106 | 0.734661 |
12e658cebecc095f8910cdb95d0ccbd190f22eff | 106 | py | Python | module01/classes/class06b.py | LauroHBrant/python-course | 2154181ca4b684b0d1fa635706bcb1647a753bc3 | [
"MIT"
] | 2 | 2021-01-07T23:59:36.000Z | 2021-01-18T00:23:52.000Z | module01/classes/class06b.py | LauroHBrant/python-course | 2154181ca4b684b0d1fa635706bcb1647a753bc3 | [
"MIT"
] | null | null | null | module01/classes/class06b.py | LauroHBrant/python-course | 2154181ca4b684b0d1fa635706bcb1647a753bc3 | [
"MIT"
] | null | null | null | from style import blue, none
n = input(f'Type {blue}something{none}: ')
print(f'{blue}{n.isnumeric()}')
| 17.666667 | 42 | 0.669811 |
12e805833151bd1898679d1e39b89a2e7fde7f1c | 2,600 | py | Python | custom_components/panasonic_cc/__init__.py | shyne99/panasonic_cc | ec7912e4067ebd0c08ea2a16c123c50d69a2fca6 | [
"MIT"
] | null | null | null | custom_components/panasonic_cc/__init__.py | shyne99/panasonic_cc | ec7912e4067ebd0c08ea2a16c123c50d69a2fca6 | [
"MIT"
] | null | null | null | custom_components/panasonic_cc/__init__.py | shyne99/panasonic_cc | ec7912e4067ebd0c08ea2a16c123c50d69a2fca6 | [
"MIT"
] | null | null | null | """Platform for the Panasonic Comfort Cloud."""
from datetime import timedelta
import logging
from typing import Any, Dict
import asyncio
from async_timeout import timeout
import voluptuous as vol
from homeassistant.core import HomeAssistant
from homeassistant.config_entries import SOURCE_IMPORT, ConfigEntry
from ho... | 27.368421 | 83 | 0.699231 |
12e82d4517d5644cd0b40eba9d476a8a70aa842c | 5,806 | py | Python | django/bossingest/test/test_ingest_manager.py | jhuapl-boss/boss | c2e26d272bd7b8d54abdc2948193163537e31291 | [
"Apache-2.0"
] | 20 | 2016-05-16T21:08:13.000Z | 2021-11-16T11:50:19.000Z | django/bossingest/test/test_ingest_manager.py | jhuapl-boss/boss | c2e26d272bd7b8d54abdc2948193163537e31291 | [
"Apache-2.0"
] | 31 | 2016-10-28T17:51:11.000Z | 2022-02-10T08:07:31.000Z | django/bossingest/test/test_ingest_manager.py | jhuapl-boss/boss | c2e26d272bd7b8d54abdc2948193163537e31291 | [
"Apache-2.0"
] | 12 | 2016-10-28T17:47:01.000Z | 2021-05-18T23:47:06.000Z | # Copyright 2016 The Johns Hopkins University Applied Physics Laboratory
#
# 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 ... | 40.887324 | 110 | 0.707544 |
12e8353d99830242965335f0aba978e3cb0ab443 | 5,505 | py | Python | sanic_devtools/log.py | yunstanford/sanic-devtools | 9e8a6d011db025d53ddd6012b5542dc18825d4b0 | [
"MIT"
] | 12 | 2019-09-06T05:14:46.000Z | 2022-02-17T09:26:38.000Z | sanic_devtools/log.py | yunstanford/sanic-devtools | 9e8a6d011db025d53ddd6012b5542dc18825d4b0 | [
"MIT"
] | null | null | null | sanic_devtools/log.py | yunstanford/sanic-devtools | 9e8a6d011db025d53ddd6012b5542dc18825d4b0 | [
"MIT"
] | 1 | 2019-09-10T03:57:21.000Z | 2019-09-10T03:57:21.000Z | import json
import logging
import logging.config
import platform
import re
import traceback
from io import StringIO
import pygments
from devtools import pformat
from devtools.ansi import isatty, sformat
from pygments.formatters import Terminal256Formatter
from pygments.lexers import Python3TracebackLexer
rs_dft_logge... | 31.820809 | 101 | 0.547502 |
12e86cadd6eb11b7a84bc77642dccfd6d3f1bfb4 | 1,893 | py | Python | rest_fhir/mixins/conditional_read.py | weynelucas/django-rest-fhir | 560a0aadd0cfa43b6dc58f995c86015f6eefb768 | [
"MIT"
] | 2 | 2021-05-07T12:16:27.000Z | 2021-12-16T20:45:36.000Z | rest_fhir/mixins/conditional_read.py | weynelucas/django-rest-fhir | 560a0aadd0cfa43b6dc58f995c86015f6eefb768 | [
"MIT"
] | 3 | 2021-05-10T19:40:33.000Z | 2021-06-27T14:24:47.000Z | rest_fhir/mixins/conditional_read.py | weynelucas/django-rest-fhir | 560a0aadd0cfa43b6dc58f995c86015f6eefb768 | [
"MIT"
] | 1 | 2021-08-09T22:00:22.000Z | 2021-08-09T22:00:22.000Z | import calendar
from typing import Union
import dateutil.parser
from rest_framework import status
from rest_framework.response import Response
from django.utils.cache import get_conditional_response
from django.utils.http import http_date
from ..models import Resource, ResourceVersion
FhirResource = Union[Resource,... | 29.578125 | 73 | 0.663497 |
12e90bbcd25c813026449118e104295e2d5b4d7b | 803 | py | Python | code_week27_1026_111/sort_colors.py | dylanlee101/leetcode | b059afdadb83d504e62afd1227107de0b59557af | [
"Apache-2.0"
] | null | null | null | code_week27_1026_111/sort_colors.py | dylanlee101/leetcode | b059afdadb83d504e62afd1227107de0b59557af | [
"Apache-2.0"
] | null | null | null | code_week27_1026_111/sort_colors.py | dylanlee101/leetcode | b059afdadb83d504e62afd1227107de0b59557af | [
"Apache-2.0"
] | null | null | null | '''
n
01 2
:
:
: [2,0,2,1,1,0]
: [0,0,1,1,2,2]
01 2 012
LeetCode
https://leetcode-cn.com/problems/sort-colors
'''
| 21.131579 | 65 | 0.554172 |
12ea0884e04ad5410800ee3a274f85dcb7596112 | 363 | py | Python | solutions/lowest_common_ancestor_deepest_leaves/__main__.py | ansonmiu0214/dsa-worked-solutions | 88801d268b78506edd77e771c29b4c9f4ae0f59a | [
"MIT"
] | null | null | null | solutions/lowest_common_ancestor_deepest_leaves/__main__.py | ansonmiu0214/dsa-worked-solutions | 88801d268b78506edd77e771c29b4c9f4ae0f59a | [
"MIT"
] | null | null | null | solutions/lowest_common_ancestor_deepest_leaves/__main__.py | ansonmiu0214/dsa-worked-solutions | 88801d268b78506edd77e771c29b4c9f4ae0f59a | [
"MIT"
] | null | null | null | from .solution import lcaDeepestLeaves
from ..utils import TreeNode
print('Enter tree, e.g. [2,3,1,3,1,null,1]:', end=' ')
nodes = [int(node) if node != 'null' else None for node in input().strip().split(',')]
root = TreeNode.fromList(nodes)
lowestCommonAncestor = lcaDeepestLeaves(root)
print(f'The lowest common anc... | 36.3 | 86 | 0.721763 |
12ea961825e76ebc83c3a72ff0731af4a86af12d | 2,472 | py | Python | code/python3/index_values_with_geo.py | jaylett/xapian-docsprint | 2e8fdffecf71f7042c0abe49924ba48c11818b7e | [
"MIT"
] | 47 | 2015-01-20T15:38:41.000Z | 2022-02-15T21:03:50.000Z | code/python3/index_values_with_geo.py | jaylett/xapian-docsprint | 2e8fdffecf71f7042c0abe49924ba48c11818b7e | [
"MIT"
] | 16 | 2015-06-09T16:12:50.000Z | 2020-02-05T06:40:18.000Z | code/python3/index_values_with_geo.py | jaylett/xapian-docsprint | 2e8fdffecf71f7042c0abe49924ba48c11818b7e | [
"MIT"
] | 56 | 2015-01-20T15:38:44.000Z | 2022-03-03T18:13:39.000Z | #!/usr/bin/env python
import json
from support import parse_states
import sys
import xapian
if len(sys.argv) != 3:
print("Usage: %s DATAPATH DBPATH" % sys.argv[0])
sys.exit(1)
index(datapath = sys.argv[1], dbpath = sys.argv[2])
| 35.314286 | 74 | 0.644013 |
12eab71a1efede1b96f0100790956e17f9d9393a | 1,265 | py | Python | logger.py | drewstone/dynamic-governanceq | 924317800db7bca6308ff912b16c7b834ab30e32 | [
"MIT"
] | null | null | null | logger.py | drewstone/dynamic-governanceq | 924317800db7bca6308ff912b16c7b834ab30e32 | [
"MIT"
] | null | null | null | logger.py | drewstone/dynamic-governanceq | 924317800db7bca6308ff912b16c7b834ab30e32 | [
"MIT"
] | null | null | null | import constants
| 36.142857 | 74 | 0.554941 |
12ec838b4e6e3d1f8f2bea5549297c2e3c075ade | 2,484 | py | Python | test/core/bad_ssl/gen_build_yaml.py | Akrog/grpc | 14800b0c1acc2d10d4fd0826731ecae2cb448143 | [
"Apache-2.0"
] | 3 | 2020-10-07T14:20:21.000Z | 2021-10-08T14:49:17.000Z | test/core/bad_ssl/gen_build_yaml.py | Akrog/grpc | 14800b0c1acc2d10d4fd0826731ecae2cb448143 | [
"Apache-2.0"
] | 1 | 2021-03-04T02:33:56.000Z | 2021-03-04T02:33:56.000Z | test/core/bad_ssl/gen_build_yaml.py | Akrog/grpc | 14800b0c1acc2d10d4fd0826731ecae2cb448143 | [
"Apache-2.0"
] | 5 | 2021-02-19T09:46:00.000Z | 2022-03-13T17:33:34.000Z | #!/usr/bin/env python2.7
# Copyright 2015 gRPC authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable la... | 35.485714 | 76 | 0.595813 |
12ed7f2619866ebbd758994ab5e6290f518e72e4 | 6,608 | py | Python | tests/test_providers.py | thejoeejoee/django-allauth-cas | 5db34b546eb32524a3a1a4b90f411e370ac7ad9b | [
"MIT"
] | null | null | null | tests/test_providers.py | thejoeejoee/django-allauth-cas | 5db34b546eb32524a3a1a4b90f411e370ac7ad9b | [
"MIT"
] | null | null | null | tests/test_providers.py | thejoeejoee/django-allauth-cas | 5db34b546eb32524a3a1a4b90f411e370ac7ad9b | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
from six.moves.urllib.parse import urlencode
from django.contrib import messages
from django.contrib.messages.api import get_messages
from django.contrib.messages.middleware import MessageMiddleware
from django.contrib.messages.storage.base import Message
from django.contrib.sessions.middleware... | 32.875622 | 79 | 0.623033 |
12ed9629940a31dc96db1b6d58b951b990da8233 | 3,723 | py | Python | infoblox_netmri/api/remote/models/device_password_log_remote.py | IngmarVG-IB/infoblox-netmri | b0c725fd64aee1890d83917d911b89236207e564 | [
"Apache-2.0"
] | null | null | null | infoblox_netmri/api/remote/models/device_password_log_remote.py | IngmarVG-IB/infoblox-netmri | b0c725fd64aee1890d83917d911b89236207e564 | [
"Apache-2.0"
] | null | null | null | infoblox_netmri/api/remote/models/device_password_log_remote.py | IngmarVG-IB/infoblox-netmri | b0c725fd64aee1890d83917d911b89236207e564 | [
"Apache-2.0"
] | null | null | null | from ..remote import RemoteModel
from infoblox_netmri.utils.utils import check_api_availability
| 31.285714 | 130 | 0.608649 |
12ee13303b7604822dba3ba0cf7479d1d2caaf67 | 4,477 | py | Python | selenium_utils/element.py | defactto/selenium-utils | d3a71f3baaaa0da29e3b1ab869f8c685ea5d1b42 | [
"Apache-2.0"
] | 7 | 2016-08-24T20:29:47.000Z | 2020-01-29T13:59:03.000Z | selenium_utils/element.py | defactto/selenium-utils | d3a71f3baaaa0da29e3b1ab869f8c685ea5d1b42 | [
"Apache-2.0"
] | null | null | null | selenium_utils/element.py | defactto/selenium-utils | d3a71f3baaaa0da29e3b1ab869f8c685ea5d1b42 | [
"Apache-2.0"
] | 1 | 2020-01-06T18:41:15.000Z | 2020-01-06T18:41:15.000Z | import logging
import time
from selenium.common import exceptions
from selenium.webdriver.remote.webdriver import WebDriver
from selenium.webdriver.common import action_chains
from selenium.webdriver.support import expected_conditions as EC
from selenium.webdriver.support.ui import WebDriverWait
from selenium_utils i... | 29.071429 | 100 | 0.691311 |
12ee5dcab405211321c77a37855a79013c17587c | 1,421 | py | Python | modules/iib_applications.py | satbel/ib-metrics-pyclient | 1670df55684a7182884fcfc777fde5ae44095f8f | [
"MIT"
] | null | null | null | modules/iib_applications.py | satbel/ib-metrics-pyclient | 1670df55684a7182884fcfc777fde5ae44095f8f | [
"MIT"
] | null | null | null | modules/iib_applications.py | satbel/ib-metrics-pyclient | 1670df55684a7182884fcfc777fde5ae44095f8f | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
"""Various functions for ib applications."""
from modules.iib_api import get_status
def get_metric_name(metric_label):
"""Returns pushgateway formatted metric name."""
return 'ib_application_{0}'.format(metric_label)
def get_metric_annotation():
"""Returns dictionary with annotat... | 36.435897 | 98 | 0.64532 |
12f0e1426999717b706caac8906a3500e72dc344 | 1,366 | py | Python | clock.py | hcjk/kitchen-bot | 5122101ed840b6bdf0b56d3c154de083cb793eda | [
"MIT"
] | null | null | null | clock.py | hcjk/kitchen-bot | 5122101ed840b6bdf0b56d3c154de083cb793eda | [
"MIT"
] | null | null | null | clock.py | hcjk/kitchen-bot | 5122101ed840b6bdf0b56d3c154de083cb793eda | [
"MIT"
] | 1 | 2019-06-10T01:25:49.000Z | 2019-06-10T01:25:49.000Z | import os
import requests
import psycopg2
import db_lib as db
from app import send_message, log
from apscheduler.schedulers.blocking import BlockingScheduler
DATABASE_URL = os.environ['DATABASE_URL']
conn = psycopg2.connect(DATABASE_URL, sslmode='require')
sched = BlockingScheduler()
sched.add_job(kitchen_reminder, ... | 23.964912 | 82 | 0.732064 |
12f18b28f2f44fef548bff40a3b625b2e4be86b9 | 2,940 | py | Python | ucf_sub_catkin_ros/src/sub_states/src/qual/test.py | RoboticsClubatUCF/RoboSub | 47304c620f963a8762db57a7ed248d1df90190fb | [
"MIT"
] | null | null | null | ucf_sub_catkin_ros/src/sub_states/src/qual/test.py | RoboticsClubatUCF/RoboSub | 47304c620f963a8762db57a7ed248d1df90190fb | [
"MIT"
] | 19 | 2016-09-16T19:52:57.000Z | 2018-04-14T18:16:17.000Z | ucf_sub_catkin_ros/src/sub_states/src/qual/test.py | RoboticsClubatUCF/RoboSub | 47304c620f963a8762db57a7ed248d1df90190fb | [
"MIT"
] | 8 | 2016-01-06T20:56:45.000Z | 2017-02-26T02:49:17.000Z | #!/usr/bin/env python
import rospy
import smach
import gate
import pole
if __name__ == '__main__':
rospy.init_node('hippo_sm')
sm = SubStates()
outcome = sm.tasks.execute()
rospy.spin()
| 49.830508 | 116 | 0.343197 |
12f1cb8ec52078b29ac8f9e2d9706191446e64ae | 3,271 | py | Python | networkapi/plugins/SDN/ODL/tests/test_send_flows_with_tcp_flags.py | vinicius-marinho/GloboNetworkAPI | 94651d3b4dd180769bc40ec966814f3427ccfb5b | [
"Apache-2.0"
] | 73 | 2015-04-13T17:56:11.000Z | 2022-03-24T06:13:07.000Z | networkapi/plugins/SDN/ODL/tests/test_send_flows_with_tcp_flags.py | leopoldomauricio/GloboNetworkAPI | 3b5b2e336d9eb53b2c113977bfe466b23a50aa29 | [
"Apache-2.0"
] | 99 | 2015-04-03T01:04:46.000Z | 2021-10-03T23:24:48.000Z | networkapi/plugins/SDN/ODL/tests/test_send_flows_with_tcp_flags.py | shildenbrand/GloboNetworkAPI | 515d5e961456cee657c08c275faa1b69b7452719 | [
"Apache-2.0"
] | 64 | 2015-08-05T21:26:29.000Z | 2022-03-22T01:06:28.000Z |
from networkapi.test.test_case import NetworkApiTestCase
from networkapi.plugins.SDN.ODL.flows.acl import AclFlowBuilder
| 33.377551 | 75 | 0.496484 |
12f2139184aea177b546923cc78d7b43a26b2e26 | 4,940 | py | Python | Old/OpenCV Scripts/red_filtered_detector.py | multirotorsociety/SAFMC-19-D2-Autonomous-Drone | fd9f0fae5d7cbf618b327224e06a7f459612b4ca | [
"MIT"
] | 6 | 2019-04-01T02:38:40.000Z | 2021-06-05T18:23:06.000Z | Old/OpenCV Scripts/red_filtered_detector.py | multirotorsociety/SAFMC-19-D2-Autonomous-Drone | fd9f0fae5d7cbf618b327224e06a7f459612b4ca | [
"MIT"
] | null | null | null | Old/OpenCV Scripts/red_filtered_detector.py | multirotorsociety/SAFMC-19-D2-Autonomous-Drone | fd9f0fae5d7cbf618b327224e06a7f459612b4ca | [
"MIT"
] | 1 | 2019-09-01T08:58:28.000Z | 2019-09-01T08:58:28.000Z |
from picamera.array import PiRGBArray
from picamera import PiCamera
import cv2
import numpy as np
import time
from fractions import Fraction
from PIL import Image
#cap = cv2.VideoCapture(0)
camera = PiCamera()
camera.resolution = (426, 240)
camera.framerate = 24
camera.exposure_mode = 'off'
camera.exposure_compensa... | 33.154362 | 109 | 0.618421 |
12f21abc71f1092fae63b143257827c5624eebdf | 2,965 | py | Python | setup.py | Maven85/plugin.video.magenta-sport | e05eeea629295d79de7467d495eb0c20b3adb60b | [
"MIT"
] | null | null | null | setup.py | Maven85/plugin.video.magenta-sport | e05eeea629295d79de7467d495eb0c20b3adb60b | [
"MIT"
] | null | null | null | setup.py | Maven85/plugin.video.magenta-sport | e05eeea629295d79de7467d495eb0c20b3adb60b | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
# Module: default
# Author: asciidisco
# Created on: 24.07.2017
# License: MIT https://goo.gl/WA1kby
"""Setup"""
from __future__ import unicode_literals
from os.path import abspath, dirname, join
from re import search
from sys import exit, version, version_info
from setuptools import find_pack... | 26.711712 | 73 | 0.551771 |
12f2a17d10d6e7d8016a1adfcae38305fb8b1df9 | 2,386 | py | Python | franka_lcas_experiments/script/load_model_rtp.py | arsh09/franka_ros_lcas | b6211125436849d5c7def8ad96a384cc34f2f121 | [
"Apache-2.0"
] | 2 | 2021-11-09T00:50:43.000Z | 2021-11-15T09:50:47.000Z | franka_lcas_experiments/script/load_model_rtp.py | arsh09/franka_ros_lcas | b6211125436849d5c7def8ad96a384cc34f2f121 | [
"Apache-2.0"
] | null | null | null | franka_lcas_experiments/script/load_model_rtp.py | arsh09/franka_ros_lcas | b6211125436849d5c7def8ad96a384cc34f2f121 | [
"Apache-2.0"
] | 1 | 2021-11-17T13:24:23.000Z | 2021-11-17T13:24:23.000Z | import numpy as np
import os, sys
os.environ['TF_CPP_MIN_LOG_LEVEL'] = '3'
from tensorflow.keras.models import Model
import tensorflow as tf
from PIL import Image
from utils_rtp import ProMP
if __name__ == "__main__":
ENCODED_MODEL_PATH = "/home/arshad/Documents/reach_to_palpate_validation_models/encoded_mode... | 40.440678 | 138 | 0.690696 |
12f2a97e43141a9ad0fb868815aad72bb1ff0352 | 5,648 | py | Python | sdv/tabular/ctgan.py | joanvaquer/SDV | 83e4fdf0ff72e6c5b72cfc8c6ec9584dbd34de28 | [
"MIT"
] | null | null | null | sdv/tabular/ctgan.py | joanvaquer/SDV | 83e4fdf0ff72e6c5b72cfc8c6ec9584dbd34de28 | [
"MIT"
] | null | null | null | sdv/tabular/ctgan.py | joanvaquer/SDV | 83e4fdf0ff72e6c5b72cfc8c6ec9584dbd34de28 | [
"MIT"
] | null | null | null | """Wrapper around CTGAN model."""
from sdv.tabular.base import BaseTabularModel
| 40.056738 | 97 | 0.599681 |
12f479c7b7668c843b94467ffeb73f441443785b | 1,130 | py | Python | cointrader/config.py | 3con/cointrader | abb3d13d1105e11db0070a9052c45cb8a87f168c | [
"MIT"
] | 103 | 2017-03-10T07:23:12.000Z | 2021-08-24T17:39:22.000Z | cointrader/config.py | altfund/cointrader-1 | abb3d13d1105e11db0070a9052c45cb8a87f168c | [
"MIT"
] | 91 | 2017-03-11T06:23:09.000Z | 2021-11-15T17:47:06.000Z | cointrader/config.py | fwolfst/cointrader | abb3d13d1105e11db0070a9052c45cb8a87f168c | [
"MIT"
] | 36 | 2017-03-23T17:48:08.000Z | 2020-02-21T23:42:03.000Z | #!/usr/bin/env python
# -*- coding: utf-8 -*-
import sys
import os
import logging
import logging.config
if (sys.version_info > (3, 0)):
# Python 3 code in this block
import configparser
else:
# Python 2 code in this block
import ConfigParser as configparser
DEFAULT_CONFIG = ".cointrader.ini"
| 25.681818 | 64 | 0.642478 |
12f51cb5ac4eefb8f57e6dbd0a326e1ca9a0b225 | 712 | py | Python | src/snakeoil/descriptors.py | Arusekk/snakeoil | aad28a50118223766e5308452b369f2c72b971b2 | [
"BSD-3-Clause"
] | null | null | null | src/snakeoil/descriptors.py | Arusekk/snakeoil | aad28a50118223766e5308452b369f2c72b971b2 | [
"BSD-3-Clause"
] | null | null | null | src/snakeoil/descriptors.py | Arusekk/snakeoil | aad28a50118223766e5308452b369f2c72b971b2 | [
"BSD-3-Clause"
] | null | null | null | """Classes implementing the descriptor protocol."""
__all__ = ("classproperty",)
| 20.342857 | 75 | 0.605337 |
12f6a69fd0573ee6b9b0a6c81a158a82f44d6769 | 6,480 | py | Python | playground/pets_dubins.py | pecey/mbrl-lib | ebca518b35a1370dbaede2a1c96fcde714bc5489 | [
"MIT"
] | null | null | null | playground/pets_dubins.py | pecey/mbrl-lib | ebca518b35a1370dbaede2a1c96fcde714bc5489 | [
"MIT"
] | null | null | null | playground/pets_dubins.py | pecey/mbrl-lib | ebca518b35a1370dbaede2a1c96fcde714bc5489 | [
"MIT"
] | null | null | null | import matplotlib as mpl
import matplotlib.pyplot as plt
import numpy as np
import torch
import omegaconf
import mbrl.env.continuous_dubins as dubins_env
import mbrl.env.reward_fns as reward_fns
import mbrl.env.termination_fns as termination_fns
import mbrl.models as models
import mbrl.planning as planning
import mbrl... | 34.105263 | 114 | 0.622531 |
12f7704aea2bda946e46a42c6fdb1b32ab8e104a | 39 | py | Python | pixiv_spider/__init__.py | Uzukidd/Pixiv-spider | 10d21bf8f1e0ec0b0792383ae9e8ae55e77efd17 | [
"MIT"
] | 1 | 2021-11-12T19:16:56.000Z | 2021-11-12T19:16:56.000Z | pixiv_spider/__init__.py | Uzukidd/Pixiv-web-crawler | 10d21bf8f1e0ec0b0792383ae9e8ae55e77efd17 | [
"MIT"
] | null | null | null | pixiv_spider/__init__.py | Uzukidd/Pixiv-web-crawler | 10d21bf8f1e0ec0b0792383ae9e8ae55e77efd17 | [
"MIT"
] | null | null | null | # from pixiv_web_crawler import Getters | 39 | 39 | 0.871795 |
12f80c5f985c410a5af8bdf06f87e46b6aa396c4 | 1,241 | py | Python | parsers/parsers_base.py | xm4dn355x/async_test | 92e7ec6a693ff4850ed603c0f4f0fa83e63b4e49 | [
"MIT"
] | null | null | null | parsers/parsers_base.py | xm4dn355x/async_test | 92e7ec6a693ff4850ed603c0f4f0fa83e63b4e49 | [
"MIT"
] | null | null | null | parsers/parsers_base.py | xm4dn355x/async_test | 92e7ec6a693ff4850ed603c0f4f0fa83e63b4e49 | [
"MIT"
] | null | null | null | #
#
#
# :
# : MIT License
#
from time import sleep
import requests
def get_htmls(urls):
"""
URL-
HTML
:param urls: URL-
:type urls: list
:return: HTML-
"""
htmls = [] #
for url in urls: # URL
html = get_html(url) # ... | 27.577778 | 109 | 0.654311 |
12f867945891bf95b1fd61c639ac565c8cecb9f9 | 16,303 | py | Python | smbspider/smbspider.py | vonahi/pentesting_scripts | 233b07a13e631cd121985465c083327f2fe372b6 | [
"MIT"
] | 13 | 2019-09-18T17:15:22.000Z | 2022-02-20T00:28:35.000Z | smbspider/smbspider.py | vonahi/pentesting_scripts | 233b07a13e631cd121985465c083327f2fe372b6 | [
"MIT"
] | null | null | null | smbspider/smbspider.py | vonahi/pentesting_scripts | 233b07a13e631cd121985465c083327f2fe372b6 | [
"MIT"
] | 4 | 2019-07-24T10:03:41.000Z | 2021-11-22T06:19:54.000Z | #!/usr/bin/python
#
# This post-exploitation script can be used to spider numerous systems
# to identify sensitive and/or confidential data. A good scenario to
# use this script is when you have admin credentials to tons of
# Windows systems, and you want to look for files containing data such
# as PII, network pas... | 38.541371 | 157 | 0.626326 |
12fad400aa5ee6c8bf4a6f0d061c8bf3df14fbb1 | 1,675 | py | Python | api-inference-community/docker_images/spacy/app/pipelines/text_classification.py | mlonaws/huggingface_hub | 588f74b98fbcab2cd7e61a74cc6d9649a92e0ef2 | [
"Apache-2.0"
] | 362 | 2020-12-22T10:24:06.000Z | 2022-03-30T22:47:25.000Z | api-inference-community/docker_images/spacy/app/pipelines/text_classification.py | mlonaws/huggingface_hub | 588f74b98fbcab2cd7e61a74cc6d9649a92e0ef2 | [
"Apache-2.0"
] | 547 | 2020-12-24T13:35:57.000Z | 2022-03-31T17:32:42.000Z | api-inference-community/docker_images/spacy/app/pipelines/text_classification.py | mlonaws/huggingface_hub | 588f74b98fbcab2cd7e61a74cc6d9649a92e0ef2 | [
"Apache-2.0"
] | 98 | 2021-01-06T17:37:09.000Z | 2022-03-29T07:20:08.000Z | import os
import subprocess
import sys
from typing import Dict, List
from app.pipelines import Pipeline
| 34.895833 | 128 | 0.601791 |
12fb3b1f1de02a4bb72cea078775fd6a9b6cb1ac | 4,867 | py | Python | aws/logs_monitoring/tests/test_cloudtrail_s3.py | rkitron/datadog-serverless-functions | d69fe6fdb489c262ffa76a529b22f2a81ae6deba | [
"Apache-2.0"
] | 232 | 2018-11-20T16:57:04.000Z | 2022-03-23T14:38:11.000Z | aws/logs_monitoring/tests/test_cloudtrail_s3.py | rkitron/datadog-serverless-functions | d69fe6fdb489c262ffa76a529b22f2a81ae6deba | [
"Apache-2.0"
] | 207 | 2018-10-25T11:48:20.000Z | 2022-03-23T00:21:10.000Z | aws/logs_monitoring/tests/test_cloudtrail_s3.py | rkitron/datadog-serverless-functions | d69fe6fdb489c262ffa76a529b22f2a81ae6deba | [
"Apache-2.0"
] | 308 | 2018-10-24T13:36:05.000Z | 2022-03-21T21:17:02.000Z | from unittest.mock import MagicMock, patch
import os
import sys
import unittest
import json
import copy
import io
import gzip
sys.modules["trace_forwarder.connection"] = MagicMock()
sys.modules["datadog_lambda.wrapper"] = MagicMock()
sys.modules["datadog_lambda.metric"] = MagicMock()
sys.modules["datadog"] = MagicMock... | 32.231788 | 115 | 0.543661 |
12fc144c5d332d1edd841f8f777a22d5c30bf0b9 | 487 | py | Python | ch_06/tests/test_lookup_mapping.py | real-slim-chadi/Python-Object-Oriented-Programming---4th-edition | 7c486866171786b620795fa33a79ec9ac9a8ba1b | [
"MIT"
] | 43 | 2021-06-03T18:39:09.000Z | 2022-03-29T20:32:13.000Z | ch_06/tests/test_lookup_mapping.py | real-slim-chadi/Python-Object-Oriented-Programming---4th-edition | 7c486866171786b620795fa33a79ec9ac9a8ba1b | [
"MIT"
] | 16 | 2022-02-08T22:41:30.000Z | 2022-03-25T22:48:28.000Z | ch_06/tests/test_lookup_mapping.py | real-slim-chadi/Python-Object-Oriented-Programming---4th-edition | 7c486866171786b620795fa33a79ec9ac9a8ba1b | [
"MIT"
] | 36 | 2021-06-19T07:14:09.000Z | 2022-03-12T22:17:09.000Z | """
Python 3 Object-Oriented Programming
Chapter 6, Abstract Base Classes and Operator Overloading
"""
from lookup_mapping import Lookup
| 20.291667 | 57 | 0.486653 |
12fd58577de1528a698dc2d572273da89af94b00 | 217 | py | Python | serempre_todo/utils/choices.py | pygabo/Serempre | 6b29e337abd8d1b3f71ee889d318a2d473d6c744 | [
"MIT"
] | null | null | null | serempre_todo/utils/choices.py | pygabo/Serempre | 6b29e337abd8d1b3f71ee889d318a2d473d6c744 | [
"MIT"
] | null | null | null | serempre_todo/utils/choices.py | pygabo/Serempre | 6b29e337abd8d1b3f71ee889d318a2d473d6c744 | [
"MIT"
] | null | null | null | TASK_STATUS = [
('TD', 'To Do'),
('IP', 'In Progress'),
('QA', 'Testing'),
('DO', 'Done'),
]
TASK_PRIORITY = [
('ME', 'Medium'),
('HI', 'Highest'),
('HG', 'High'),
('LO', 'Lowest'),
]
| 15.5 | 26 | 0.40553 |
12fda5a81fde9ab3c46b39a497e89d5ab29b6639 | 17,673 | py | Python | symbols/block.py | zerofo/sdu-face-alignment | f4b57fde0576d2327369884fd5d5e9a7765a0790 | [
"MIT"
] | 192 | 2019-03-27T02:40:41.000Z | 2022-03-18T15:35:17.000Z | symbols/block.py | zerofo/sdu-face-alignment | f4b57fde0576d2327369884fd5d5e9a7765a0790 | [
"MIT"
] | 4 | 2019-04-01T14:51:22.000Z | 2020-11-25T08:22:04.000Z | symbols/block.py | zerofo/sdu-face-alignment | f4b57fde0576d2327369884fd5d5e9a7765a0790 | [
"MIT"
] | 38 | 2019-03-30T05:33:48.000Z | 2021-10-01T06:08:17.000Z | from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import mxnet as mx
import numpy as np
from config import config
#def lin(data, num_filter, workspace, name, binarize, dcn):
# bit = 1
# ACT_BIT = config.ACT_BIT
# bn_mom = config.bn_mom
# workspace =... | 54.378462 | 148 | 0.62106 |
12fde371c750b67c435196b6031afbfb913cf73d | 9,198 | py | Python | train/metric.py | alexandrosstergiou/Squeeze-and-Recursion-Temporal-Gates | 1641b59b73c951a5b05d17b5528894ae73a014b8 | [
"MIT"
] | 54 | 2020-06-16T08:11:21.000Z | 2022-03-18T14:54:52.000Z | train/metric.py | alexandrosstergiou/Squeeze-and-Recursion-Temporal-Gates | 1641b59b73c951a5b05d17b5528894ae73a014b8 | [
"MIT"
] | 10 | 2020-06-23T07:57:45.000Z | 2021-12-16T04:18:03.000Z | train/metric.py | alexandrosstergiou/Squeeze-and-Recursion-Temporal-Gates | 1641b59b73c951a5b05d17b5528894ae73a014b8 | [
"MIT"
] | 7 | 2020-09-12T12:46:54.000Z | 2021-11-15T09:00:55.000Z | '''
--- I M P O R T S T A T E M E N T S ---
'''
import coloredlogs, logging
coloredlogs.install()
import numpy as np
'''
=== S T A R T O F C L A S S E V A L M E T R I C ===
[About]
Object class for calculating average values.
[Init Args]
- name: String for the variable name to calc... | 30.356436 | 103 | 0.593064 |
12fe867458db015f3b4f5fd16c3634fc1b9c4dae | 3,018 | py | Python | poly/repl.py | jdanford/poly | 4f3a242dbb54fb68375a310af943be759588f459 | [
"0BSD"
] | null | null | null | poly/repl.py | jdanford/poly | 4f3a242dbb54fb68375a310af943be759588f459 | [
"0BSD"
] | null | null | null | poly/repl.py | jdanford/poly | 4f3a242dbb54fb68375a310af943be759588f459 | [
"0BSD"
] | null | null | null | import sys
from string import whitespace
from clint.textui import puts, indent, colored
from poly.common import *
from poly.node import *
def empty_space(s):
if len(s) == 0:
return True
for c in s:
if s in whitespace:
return True
return False
if __name__ == "__main__":
... | 23.578125 | 63 | 0.503313 |
12fea94d07f9c12bbbce2e89b9de91f96defafac | 1,330 | py | Python | resources/mgltools_x86_64Linux2_1.5.6/lib/python2.5/site-packages/Pmw/Pmw_1_3/demos/SelectionDialog.py | J-E-J-S/aaRS-Pipeline | 43f59f28ab06e4b16328c3bc405cdddc6e69ac44 | [
"MIT"
] | 3 | 2017-09-26T03:09:14.000Z | 2022-03-20T11:12:34.000Z | resources/mgltools_x86_64Linux2_1.5.6/lib/python2.5/site-packages/Pmw/Pmw_1_3/demos/SelectionDialog.py | J-E-J-S/aaRS-Pipeline | 43f59f28ab06e4b16328c3bc405cdddc6e69ac44 | [
"MIT"
] | null | null | null | resources/mgltools_x86_64Linux2_1.5.6/lib/python2.5/site-packages/Pmw/Pmw_1_3/demos/SelectionDialog.py | J-E-J-S/aaRS-Pipeline | 43f59f28ab06e4b16328c3bc405cdddc6e69ac44 | [
"MIT"
] | 2 | 2019-10-05T23:02:41.000Z | 2020-06-25T20:21:02.000Z | title = 'Pmw.SelectionDialog demonstration'
# Import Pmw from this directory tree.
import sys
sys.path[:0] = ['../../..']
import Tkinter
import Pmw
######################################################################
# Create demo in root window for testing.
if __name__ == '__main__':
root = Tkinter.Tk()
... | 27.708333 | 76 | 0.619549 |
12ff9748e2c126e4060dc274380a9e865c327195 | 778 | py | Python | py3plex/algorithms/infomap/examples/python/example-simple.py | awesome-archive/Py3plex | a099acb992441c1630208ba13694acb8e2a38895 | [
"BSD-3-Clause"
] | 1 | 2020-02-20T07:37:02.000Z | 2020-02-20T07:37:02.000Z | py3plex/algorithms/infomap/examples/python/example-simple.py | awesome-archive/Py3plex | a099acb992441c1630208ba13694acb8e2a38895 | [
"BSD-3-Clause"
] | null | null | null | py3plex/algorithms/infomap/examples/python/example-simple.py | awesome-archive/Py3plex | a099acb992441c1630208ba13694acb8e2a38895 | [
"BSD-3-Clause"
] | null | null | null | from infomap import infomap
infomapWrapper = infomap.Infomap("--two-level")
# Add weight as an optional third argument
infomapWrapper.addLink(0, 1)
infomapWrapper.addLink(0, 2)
infomapWrapper.addLink(0, 3)
infomapWrapper.addLink(1, 0)
infomapWrapper.addLink(1, 2)
infomapWrapper.addLink(2, 1)
infomapWrapper.addLink(2,... | 25.096774 | 89 | 0.75964 |
12ffa5ef886269b64400e6ff0dbf8d65f1d35e0b | 305 | py | Python | api/tests.py | everett-toews/metaslacker | ec4bf3c4b39aa16b5ae46a0c3e732b8b9cb2cf72 | [
"MIT"
] | 90 | 2015-09-17T00:38:59.000Z | 2021-05-29T02:36:42.000Z | api/tests.py | everett-toews/metaslacker | ec4bf3c4b39aa16b5ae46a0c3e732b8b9cb2cf72 | [
"MIT"
] | null | null | null | api/tests.py | everett-toews/metaslacker | ec4bf3c4b39aa16b5ae46a0c3e732b8b9cb2cf72 | [
"MIT"
] | 10 | 2016-02-23T16:28:32.000Z | 2021-06-01T20:24:31.000Z | import unittest
if __name__ == '__main__':
unittest.main()
| 20.333333 | 38 | 0.642623 |
12ffe639dabbddd0482e5d8aa0dc1908fa825881 | 18,741 | py | Python | tools/modules/verify.py | andscha/containerization-for-sap-s4hana | 337df7b3b515dad9c243eae6b58ee95bf749782a | [
"Apache-2.0"
] | 6 | 2020-12-16T13:12:42.000Z | 2022-02-09T17:38:47.000Z | tools/modules/verify.py | andscha/containerization-for-sap-s4hana | 337df7b3b515dad9c243eae6b58ee95bf749782a | [
"Apache-2.0"
] | 5 | 2021-04-07T07:19:02.000Z | 2022-03-31T08:40:01.000Z | tools/modules/verify.py | andscha/containerization-for-sap-s4hana | 337df7b3b515dad9c243eae6b58ee95bf749782a | [
"Apache-2.0"
] | 7 | 2021-05-21T04:36:44.000Z | 2022-03-31T07:36:48.000Z | # ------------------------------------------------------------------------
# Copyright 2020, 2021 IBM Corp. 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:/... | 38.561728 | 100 | 0.566138 |
4200fb28b1b5da3ed4576b7e698fb2853d8ef02a | 1,060 | py | Python | rainbow/rainbow.py | jaxzin/adafruit-voice-docker | 8932e2432f56e795c4160dfeef8f61aa5a3da15a | [
"MIT"
] | null | null | null | rainbow/rainbow.py | jaxzin/adafruit-voice-docker | 8932e2432f56e795c4160dfeef8f61aa5a3da15a | [
"MIT"
] | null | null | null | rainbow/rainbow.py | jaxzin/adafruit-voice-docker | 8932e2432f56e795c4160dfeef8f61aa5a3da15a | [
"MIT"
] | null | null | null | import time
import board
import adafruit_dotstar
import atexit
import signal
kill_now = False
DOTSTAR_DATA = board.D5
DOTSTAR_CLOCK = board.D6
dots = adafruit_dotstar.DotStar(DOTSTAR_CLOCK, DOTSTAR_DATA, 3, brightness=0.5)
atexit.register(exit_handler)
signal.signal(signal.SIGINT, exit_handler)
signal.signal(signal.... | 24.090909 | 79 | 0.6 |
4201d4e01f67d6a8af781c7b4dac4cc684c59e89 | 117 | py | Python | src/iranlowo/corpus/__init__.py | Niger-Volta-LTI/iranlowo | 0046b61105ffadfff21dd8b37754b9d95177fbf8 | [
"MIT"
] | 17 | 2019-07-05T20:30:35.000Z | 2022-02-28T10:00:24.000Z | src/iranlowo/corpus/__init__.py | Olamyy/iranlowo | 1feb123988a8afac3ac53c7acfb72df862c4bc18 | [
"MIT"
] | 17 | 2019-07-06T09:10:10.000Z | 2020-11-13T08:30:37.000Z | src/iranlowo/corpus/__init__.py | ruohoruotsi/iranlowo | 0046b61105ffadfff21dd8b37754b9d95177fbf8 | [
"MIT"
] | 7 | 2019-07-01T01:59:07.000Z | 2020-11-27T17:12:46.000Z | from .corpus import Corpus, DirectoryCorpus
from .loaders import OweLoader, YorubaBlogCorpus, BBCCorpus, BibeliCorpus | 58.5 | 73 | 0.854701 |
4203e2556562a439641ccfc38f8f880faffaf2ad | 6,054 | py | Python | seq2seq.py | frozen86/SeqLite | 7f83e6a4716d756a45b2801085ac6628379fbea2 | [
"Apache-2.0"
] | 1 | 2018-05-10T01:40:55.000Z | 2018-05-10T01:40:55.000Z | seq2seq.py | frozen86/SeqLite | 7f83e6a4716d756a45b2801085ac6628379fbea2 | [
"Apache-2.0"
] | null | null | null | seq2seq.py | frozen86/SeqLite | 7f83e6a4716d756a45b2801085ac6628379fbea2 | [
"Apache-2.0"
] | null | null | null | import torch
import torch.nn as nn
import torch.nn.functional as F
import math
import matplotlib.pyplot as plt
import matplotlib.ticker as ticker
import numpy as np
from masked_cross_entropy import *
from preprocess import *
from parameter import *
import time
# # Training
# # Evaluating the net... | 34.20339 | 163 | 0.675421 |
4204040a123c3ac5e25851793e3ded084eda1953 | 41 | py | Python | ANNarchy_future/__init__.py | vitay/ANNarchy_future | 2c2a43c67f4201cf72175793aaa51189d208436b | [
"MIT"
] | 2 | 2021-03-11T18:11:30.000Z | 2021-05-12T09:15:17.000Z | ANNarchy_future/__init__.py | vitay/ANNarchy_future | 2c2a43c67f4201cf72175793aaa51189d208436b | [
"MIT"
] | null | null | null | ANNarchy_future/__init__.py | vitay/ANNarchy_future | 2c2a43c67f4201cf72175793aaa51189d208436b | [
"MIT"
] | null | null | null | from .api import *
__version__ = "5.0.0" | 13.666667 | 21 | 0.658537 |
4204eade92e97699c25ced0425caa0cabd5da0e0 | 1,881 | py | Python | pycqed/tests/analysis_v2/test_simple_analysis.py | nuttamas/PycQED_py3 | 1ee35c7428d36ed42ba4afb5d4bda98140b2283e | [
"MIT"
] | 60 | 2016-08-03T10:00:18.000Z | 2021-11-10T11:46:16.000Z | pycqed/tests/analysis_v2/test_simple_analysis.py | nuttamas/PycQED_py3 | 1ee35c7428d36ed42ba4afb5d4bda98140b2283e | [
"MIT"
] | 512 | 2016-08-03T17:10:02.000Z | 2022-03-31T14:03:43.000Z | pycqed/tests/analysis_v2/test_simple_analysis.py | nuttamas/PycQED_py3 | 1ee35c7428d36ed42ba4afb5d4bda98140b2283e | [
"MIT"
] | 34 | 2016-10-19T12:00:52.000Z | 2022-03-19T04:43:26.000Z | import unittest
import pycqed as pq
import os
import matplotlib.pyplot as plt
from pycqed.analysis_v2 import measurement_analysis as ma
| 36.882353 | 73 | 0.637959 |
42064154fe3a3a9a5966ee89da5b64cd37de9197 | 781 | py | Python | CS2/1275_turtle_recursion/2499_koch_snowflake/alternate_snowflake.py | nealholt/python_programming_curricula | eda4432dab97178b4a5712b160f5b1da74c068cb | [
"MIT"
] | 7 | 2020-10-14T03:23:12.000Z | 2022-03-09T23:16:13.000Z | CS2/1275_turtle_recursion/2499_koch_snowflake/alternate_snowflake.py | nealholt/python_programming_curricula | eda4432dab97178b4a5712b160f5b1da74c068cb | [
"MIT"
] | null | null | null | CS2/1275_turtle_recursion/2499_koch_snowflake/alternate_snowflake.py | nealholt/python_programming_curricula | eda4432dab97178b4a5712b160f5b1da74c068cb | [
"MIT"
] | 11 | 2021-02-21T20:50:56.000Z | 2022-01-29T07:01:28.000Z | import turtle
'''http://www.algorithm.co.il/blogs/computer-science/fractals-in-10-minutes-no-6-turtle-snowflake/
This would be a good introduction to recursion. I don't see how students
would invent this on their own, but they could modify it and see what
other fractals they could generate.
'''
pen = turtle.Turtle()
p... | 25.193548 | 98 | 0.663252 |
4206719b66d7095a812ba8babe145ead4c49882e | 1,325 | py | Python | test/test_edge.py | jbschwartz/spatial | 04dc619ae024ebb4f516cd6483f835421c7d84b1 | [
"MIT"
] | 1 | 2022-01-02T22:03:09.000Z | 2022-01-02T22:03:09.000Z | test/test_edge.py | jbschwartz/spatial | 04dc619ae024ebb4f516cd6483f835421c7d84b1 | [
"MIT"
] | null | null | null | test/test_edge.py | jbschwartz/spatial | 04dc619ae024ebb4f516cd6483f835421c7d84b1 | [
"MIT"
] | null | null | null | import unittest
from spatial import Edge, Vector3
| 36.805556 | 81 | 0.695849 |
4206df5fe7ed10541de178c4f224f75754304f2c | 324 | py | Python | wdae/wdae/user_queries/urls.py | iossifovlab/gpf | e556243d29666179dbcb72859845b4d6c011af2b | [
"MIT"
] | null | null | null | wdae/wdae/user_queries/urls.py | iossifovlab/gpf | e556243d29666179dbcb72859845b4d6c011af2b | [
"MIT"
] | 82 | 2019-07-22T11:44:23.000Z | 2022-01-13T15:27:33.000Z | wdae/wdae/user_queries/urls.py | iossifovlab/gpf | e556243d29666179dbcb72859845b4d6c011af2b | [
"MIT"
] | null | null | null | from django.urls import re_path
from user_queries.views import UserQuerySaveView, UserQueryCollectView
urlpatterns = [
re_path(r"^/save/?$", UserQuerySaveView.as_view(), name="user-save-query"),
re_path(
r"^/collect/?$",
UserQueryCollectView.as_view(),
name="user-collect-queries",
)... | 27 | 79 | 0.675926 |
4207202cb690f62fcf73ad7c61a82a12bebf477d | 419 | py | Python | src/login/migrations/0017_auto_20191006_1716.py | vandana0608/Pharmacy-Managament | f99bdec11c24027a432858daa19247a21cecc092 | [
"bzip2-1.0.6"
] | null | null | null | src/login/migrations/0017_auto_20191006_1716.py | vandana0608/Pharmacy-Managament | f99bdec11c24027a432858daa19247a21cecc092 | [
"bzip2-1.0.6"
] | null | null | null | src/login/migrations/0017_auto_20191006_1716.py | vandana0608/Pharmacy-Managament | f99bdec11c24027a432858daa19247a21cecc092 | [
"bzip2-1.0.6"
] | null | null | null | # Generated by Django 2.0.7 on 2019-10-06 11:46
import datetime
from django.db import migrations, models
| 20.95 | 70 | 0.620525 |
4208848cd73eaf4015f90f42e112e861d94326ec | 1,846 | py | Python | InfoGain.py | gsndr/AIDA | 538caf3ddb5aec8ec8904dc313eb7e31759f5154 | [
"MIT"
] | 4 | 2021-05-10T11:35:51.000Z | 2021-12-29T00:56:35.000Z | InfoGain.py | gsndr/AIDA | 538caf3ddb5aec8ec8904dc313eb7e31759f5154 | [
"MIT"
] | null | null | null | InfoGain.py | gsndr/AIDA | 538caf3ddb5aec8ec8904dc313eb7e31759f5154 | [
"MIT"
] | 1 | 2021-12-25T13:55:29.000Z | 2021-12-25T13:55:29.000Z | import pandas as pd
from math import log
| 29.301587 | 98 | 0.531419 |
4208c41522c79409c03ff3e274e65ad419a2c482 | 4,473 | py | Python | bot/localization.py | Supportiii/telegram-report-bot | 6a050caafb1c205c0fd58f91be9264f1190ea706 | [
"MIT"
] | null | null | null | bot/localization.py | Supportiii/telegram-report-bot | 6a050caafb1c205c0fd58f91be9264f1190ea706 | [
"MIT"
] | null | null | null | bot/localization.py | Supportiii/telegram-report-bot | 6a050caafb1c205c0fd58f91be9264f1190ea706 | [
"MIT"
] | null | null | null | strings = {
"en": {
"error_no_reply": "This command must be sent as a reply to one's message!",
"error_report_admin": "Whoa! Don't report admins ",
"error_restrict_admin": "You cannot restrict an admin.",
"report_date_format": "%d.%m.%Y at %H:%M",
"report_message": ' Sent {t... | 47.585106 | 116 | 0.591549 |
4209d56bec0f4b46b06778591fc9cb1f2f7511a5 | 3,140 | py | Python | swagger_server/models/linecode_r_matrix.py | garagonc/simulation-engine | c129f0bf601e0d56d924c9e5fa2cf94f7e31a356 | [
"Apache-2.0"
] | 3 | 2019-06-24T09:02:21.000Z | 2020-01-30T10:37:46.000Z | swagger_server/models/linecode_r_matrix.py | linksmart/simulation-engine | c129f0bf601e0d56d924c9e5fa2cf94f7e31a356 | [
"Apache-2.0"
] | null | null | null | swagger_server/models/linecode_r_matrix.py | linksmart/simulation-engine | c129f0bf601e0d56d924c9e5fa2cf94f7e31a356 | [
"Apache-2.0"
] | null | null | null | # coding: utf-8
from __future__ import absolute_import
from datetime import date, datetime # noqa: F401
from typing import List, Dict # noqa: F401
from swagger_server.models.base_model_ import Model
from swagger_server.models.impedance import Impedance # noqa: F401,E501
from swagger_server import util
| 26.610169 | 112 | 0.62293 |
420b2687d1f426ed1eefef8109dac3c6ae18bab7 | 261 | py | Python | workshop/serializers.py | shivammaniharsahu/django_api | 6ffb3d9f70f30f5fd3ae06ec00a6dd7c7783a797 | [
"bzip2-1.0.6"
] | null | null | null | workshop/serializers.py | shivammaniharsahu/django_api | 6ffb3d9f70f30f5fd3ae06ec00a6dd7c7783a797 | [
"bzip2-1.0.6"
] | null | null | null | workshop/serializers.py | shivammaniharsahu/django_api | 6ffb3d9f70f30f5fd3ae06ec00a6dd7c7783a797 | [
"bzip2-1.0.6"
] | null | null | null | from rest_framework import serializers
from .models import Register
| 29 | 83 | 0.724138 |
420ceb4ff961d4330b357c01567c2e654e43d336 | 5,303 | py | Python | experiments/twitter_event_data_2019/evaluation/groundtruth_processor.py | HHansi/WhatsUp | 87c3eb90570d2f997d8f1abc300a3553f8ef7ca9 | [
"Apache-2.0"
] | null | null | null | experiments/twitter_event_data_2019/evaluation/groundtruth_processor.py | HHansi/WhatsUp | 87c3eb90570d2f997d8f1abc300a3553f8ef7ca9 | [
"Apache-2.0"
] | null | null | null | experiments/twitter_event_data_2019/evaluation/groundtruth_processor.py | HHansi/WhatsUp | 87c3eb90570d2f997d8f1abc300a3553f8ef7ca9 | [
"Apache-2.0"
] | null | null | null | # Created by Hansi at 3/16/2020
import os
from algo.data_process.data_preprocessor import data_cleaning_flow
from algo.utils.file_utils import delete_create_folder
def extract_gt_tokens(text):
"""
Given GT string, method to extract GT labels.
GT string should be formatted as Twitter-Event-Data-2019.
... | 30.302857 | 120 | 0.603998 |
420d148bc469105cd3d8585bbbb8f38f1d6ec875 | 2,058 | py | Python | metaflow/plugins/env_escape/configurations/test_lib_impl/test_lib.py | RobBlumberg/metaflow | 9f737e6026eee250c1593a2cb1d1c4b19a00adf4 | [
"Apache-2.0"
] | 5,821 | 2019-12-03T17:57:52.000Z | 2022-03-31T22:55:12.000Z | metaflow/plugins/env_escape/configurations/test_lib_impl/test_lib.py | RobBlumberg/metaflow | 9f737e6026eee250c1593a2cb1d1c4b19a00adf4 | [
"Apache-2.0"
] | 605 | 2019-12-03T23:09:32.000Z | 2022-03-31T16:15:05.000Z | metaflow/plugins/env_escape/configurations/test_lib_impl/test_lib.py | RobBlumberg/metaflow | 9f737e6026eee250c1593a2cb1d1c4b19a00adf4 | [
"Apache-2.0"
] | 539 | 2019-12-03T18:25:53.000Z | 2022-03-29T18:22:33.000Z | import functools
def test_func(*args, **kwargs):
return "In test func"
test_value = 1
| 20.376238 | 65 | 0.623907 |
420d3d5356dc0a6fa2f8ece54ea58e9f77d14058 | 38,124 | py | Python | venv/Lib/site-packages/aniso8601/tests/test_interval.py | GabrielSilva2y3d/api_atividade-sqlalchemy | 4a06e37fcb733d4185daf1de6bce415b4de28444 | [
"MIT"
] | null | null | null | venv/Lib/site-packages/aniso8601/tests/test_interval.py | GabrielSilva2y3d/api_atividade-sqlalchemy | 4a06e37fcb733d4185daf1de6bce415b4de28444 | [
"MIT"
] | null | null | null | venv/Lib/site-packages/aniso8601/tests/test_interval.py | GabrielSilva2y3d/api_atividade-sqlalchemy | 4a06e37fcb733d4185daf1de6bce415b4de28444 | [
"MIT"
] | 1 | 2022-01-13T10:05:55.000Z | 2022-01-13T10:05:55.000Z | # -*- coding: utf-8 -*-
# Copyright (c) 2019, Brandon Nielsen
# All rights reserved.
#
# This software may be modified and distributed under the terms
# of the BSD license. See the LICENSE file for details.
import unittest
import aniso8601
from aniso8601.exceptions import ISOFormatError
from aniso8601.interval impo... | 50.629482 | 115 | 0.387027 |
420d64c40f09249f80d51908d10b8e6dab472942 | 3,008 | py | Python | cool/core/utils.py | 007gzs/django-cool | 3b4ed1a8ca020e6f798ca47e20169e5a854b4f24 | [
"BSD-3-Clause"
] | 11 | 2020-05-19T09:52:35.000Z | 2022-02-25T10:39:56.000Z | cool/core/utils.py | 007gzs/django-cool | 3b4ed1a8ca020e6f798ca47e20169e5a854b4f24 | [
"BSD-3-Clause"
] | null | null | null | cool/core/utils.py | 007gzs/django-cool | 3b4ed1a8ca020e6f798ca47e20169e5a854b4f24 | [
"BSD-3-Clause"
] | 1 | 2020-12-24T08:14:58.000Z | 2020-12-24T08:14:58.000Z | # encoding: utf-8
import operator
from functools import reduce
from django.core.exceptions import FieldDoesNotExist
from django.db.models import Q
from django.db.models.constants import LOOKUP_SEP
def split_camel_name(name, fall=False):
"""
GenerateURLs => [Generate, URLs]
generateURLsLite => [gene... | 31.663158 | 110 | 0.648936 |
420dab6ca09e09f7cbafe716ac539156b5dcaa62 | 773 | py | Python | setup.py | atait/klayout-gadgets | a8d9655e547fc4531982bbe55e632009bad39096 | [
"MIT"
] | 13 | 2018-12-02T23:32:29.000Z | 2022-02-11T19:28:49.000Z | setup.py | atait/klayout-gadgets | a8d9655e547fc4531982bbe55e632009bad39096 | [
"MIT"
] | 3 | 2019-01-15T23:59:59.000Z | 2020-12-04T16:30:48.000Z | setup.py | atait/klayout-gadgets | a8d9655e547fc4531982bbe55e632009bad39096 | [
"MIT"
] | 1 | 2020-12-01T22:56:03.000Z | 2020-12-01T22:56:03.000Z | from setuptools import setup
setup(name='lygadgets',
version='0.1.31',
description='Tools to make klayout, the standalone, and python environments work better together',
long_description=readme(),
long_description_content_type='text/markdown',
author='Alex Tait',
author_email='ale... | 29.730769 | 104 | 0.654592 |
420db9bdde8897b05f3ac2a8bb469ed44754dbb4 | 1,748 | py | Python | Python/Zelle/Chapter10_DefiningClasses/ProgrammingExercises/16_CannonballTarget/inputDialog.py | jeffvswanson/CodingPractice | 9ea8e0dd504230cea0e8684b31ef22c3ed90d2fb | [
"MIT"
] | null | null | null | Python/Zelle/Chapter10_DefiningClasses/ProgrammingExercises/16_CannonballTarget/inputDialog.py | jeffvswanson/CodingPractice | 9ea8e0dd504230cea0e8684b31ef22c3ed90d2fb | [
"MIT"
] | null | null | null | Python/Zelle/Chapter10_DefiningClasses/ProgrammingExercises/16_CannonballTarget/inputDialog.py | jeffvswanson/CodingPractice | 9ea8e0dd504230cea0e8684b31ef22c3ed90d2fb | [
"MIT"
] | null | null | null | # inputDialog.py
""" Provides a window to get input values
from the user to animate a cannonball."""
from graphics import GraphWin, Entry, Text, Point
from button import Button | 30.137931 | 71 | 0.568078 |
420e4e16ca0ab83a3724fd3b5d5775cec3e14b0e | 979 | py | Python | gym_envs/envs/reacher_done.py | gautams3/reacher-done | 6420f4ea3e0f6e47a3ebe25dbe170a9030b03b01 | [
"MIT"
] | 1 | 2021-11-13T13:51:37.000Z | 2021-11-13T13:51:37.000Z | gym_envs/envs/reacher_done.py | gautams3/reacher-done | 6420f4ea3e0f6e47a3ebe25dbe170a9030b03b01 | [
"MIT"
] | null | null | null | gym_envs/envs/reacher_done.py | gautams3/reacher-done | 6420f4ea3e0f6e47a3ebe25dbe170a9030b03b01 | [
"MIT"
] | 2 | 2021-04-08T12:48:29.000Z | 2021-05-09T02:04:33.000Z | import gym
from gym import error, spaces, utils
from gym.utils import seeding
from gym.envs.mujoco.reacher import ReacherEnv
import numpy as np
# def reset(self):
# super().reset()
# def render(self, mode='human'):
# ...
# def close(self):
# ... | 31.580645 | 76 | 0.668029 |
420ed2750c333b6a9c2bf33a7391b56504549e6c | 4,639 | py | Python | stackalytics/get_metric.py | yaoice/python_demo | 024f42f9cfce757bdaddf24202d8547801f0e8f6 | [
"Apache-2.0"
] | null | null | null | stackalytics/get_metric.py | yaoice/python_demo | 024f42f9cfce757bdaddf24202d8547801f0e8f6 | [
"Apache-2.0"
] | 2 | 2021-02-08T20:17:39.000Z | 2021-06-01T21:49:12.000Z | stackalytics/get_metric.py | yaoice/python_demo | 024f42f9cfce757bdaddf24202d8547801f0e8f6 | [
"Apache-2.0"
] | null | null | null | #/usr/bin/env python
import httplib2
import json
import sys
from prettytable import PrettyTable
from config import field
def main():
company_statistics = {}
engineer_statistics = {}
stackalytics = Stackalytics("http://stackalytics.com")
for project_type in field['project_type']:
comp... | 43.764151 | 143 | 0.527053 |