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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
6b637d51ee53d130d2f22a3cc30f1efdedb53487 | 445 | py | Python | douyinspider/structures/__init__.py | MisterZhouZhou/pythonThreeSpider | 0e120350402f690158c89b7431f243cb462ae12f | [
"Apache-2.0"
] | 3 | 2019-11-05T01:00:05.000Z | 2021-03-16T03:56:46.000Z | douyinspider/structures/__init__.py | bingwin/pythonThreeSpider | 0e120350402f690158c89b7431f243cb462ae12f | [
"Apache-2.0"
] | null | null | null | douyinspider/structures/__init__.py | bingwin/pythonThreeSpider | 0e120350402f690158c89b7431f243cb462ae12f | [
"Apache-2.0"
] | 1 | 2020-05-16T12:45:36.000Z | 2020-05-16T12:45:36.000Z | from douyinspider.structures.hot import *
from douyinspider.structures.base import Base
from douyinspider.structures.music import Music
from douyinspider.structures.user import User
from douyinspider.structures.video import Video
from douyinspider.structures.address import Address
from douyinspider.structures.topic imp... | 44.5 | 68 | 0.876404 |
6b65f49db99507614c35cf503467297c30872685 | 1,717 | py | Python | code/generate.py | karl-joan/text2art-gan | 86370667f9a62bab95968abe1990dcaa4760b333 | [
"MIT"
] | 5 | 2021-10-30T13:40:41.000Z | 2022-03-20T04:48:45.000Z | code/generate.py | karl-joan/text2art-gan | 86370667f9a62bab95968abe1990dcaa4760b333 | [
"MIT"
] | null | null | null | code/generate.py | karl-joan/text2art-gan | 86370667f9a62bab95968abe1990dcaa4760b333 | [
"MIT"
] | 2 | 2021-09-06T03:45:04.000Z | 2022-03-13T03:23:49.000Z | import argparse
import os
from datetime import datetime
from attngan import attngan
from cyclegan import cyclegan
args = parse_args()
savepath = os.path.join("../results/", datetime.today().strftime("%Y-%m-%d_%H-%M-%S/"))
print("--------------- Generating images ---------------")
attngan(args.caption, args.dataset,... | 49.057143 | 161 | 0.633081 |
6b66098a0ef59f405b36110fd1c33e17ce0c92bd | 182 | py | Python | config.py | harshmalik9423/python-sockets-projects | 6519cf65126af7c12683c29155200c9427941cc9 | [
"MIT"
] | null | null | null | config.py | harshmalik9423/python-sockets-projects | 6519cf65126af7c12683c29155200c9427941cc9 | [
"MIT"
] | null | null | null | config.py | harshmalik9423/python-sockets-projects | 6519cf65126af7c12683c29155200c9427941cc9 | [
"MIT"
] | null | null | null | #
# config.py
#
SERVER_HOSTNAME = "eecs325.local"
SERVER_PORT = 80
SERVER_MAX_CONN_QUEUE = 5 # Number of connection requests to queue.
BUFFER_SIZE = 4096
MESSAGE_ENCODING = "utf8"
| 16.545455 | 67 | 0.758242 |
6b6681e427d456facc061c75cde2612fd3d99a96 | 115 | py | Python | app/__init__.py | MarciaAndrea/devweb_formulario | 8b038f81cdd58d2ec58c91d04ca892a4fa99f549 | [
"MIT"
] | null | null | null | app/__init__.py | MarciaAndrea/devweb_formulario | 8b038f81cdd58d2ec58c91d04ca892a4fa99f549 | [
"MIT"
] | null | null | null | app/__init__.py | MarciaAndrea/devweb_formulario | 8b038f81cdd58d2ec58c91d04ca892a4fa99f549 | [
"MIT"
] | null | null | null | from flask import Flask
app = Flask(__name__)
app.config['DEBUG'] = True
from app import models, views
| 12.777778 | 30 | 0.678261 |
6b690cd5a48b3af4a8181ceed479f3b9df620a02 | 973 | py | Python | scipy_central/thumbs/models.py | wqshi/test | 63dc0c684ec749cd03e9c071176f30f439188f14 | [
"BSD-3-Clause"
] | 7 | 2016-02-03T12:44:33.000Z | 2020-08-26T09:22:23.000Z | scipy_central/thumbs/models.py | wqshi/test | 63dc0c684ec749cd03e9c071176f30f439188f14 | [
"BSD-3-Clause"
] | 19 | 2015-01-20T11:27:22.000Z | 2017-09-23T22:26:18.000Z | scipy_central/thumbs/models.py | wqshi/test | 63dc0c684ec749cd03e9c071176f30f439188f14 | [
"BSD-3-Clause"
] | 9 | 2015-01-03T02:56:33.000Z | 2021-02-20T10:45:11.000Z | from django.db import models
| 32.433333 | 77 | 0.65776 |
6b69c34c228a53e48fd9981e515b4c0a974719ff | 260 | py | Python | sysroot/usr/lib/python3/dist-packages/ssh_import_id/version.py | 219-design/sysroot_qt5.15.0_binaries_armv6zk_rpizero_bullseye_gcc10.3 | 60545a4471090a4c9ffcf207fb5a71831bfc3bb2 | [
"MIT"
] | null | null | null | sysroot/usr/lib/python3/dist-packages/ssh_import_id/version.py | 219-design/sysroot_qt5.15.0_binaries_armv6zk_rpizero_bullseye_gcc10.3 | 60545a4471090a4c9ffcf207fb5a71831bfc3bb2 | [
"MIT"
] | null | null | null | sysroot/usr/lib/python3/dist-packages/ssh_import_id/version.py | 219-design/sysroot_qt5.15.0_binaries_armv6zk_rpizero_bullseye_gcc10.3 | 60545a4471090a4c9ffcf207fb5a71831bfc3bb2 | [
"MIT"
] | null | null | null | # This file is part of ssh-import-id. See LICENSE file for more info.
_LAST_RELEASE = "5.10"
_PACKAGED_VERSION = '5.10-1'
VERSION = _LAST_RELEASE
if not _PACKAGED_VERSION.startswith("@@"):
VERSION = _PACKAGED_VERSION
# vi: ts=4 expandtab syntax=python
| 21.666667 | 69 | 0.734615 |
6b6c4918437ff01fd308871c7f88d92fe127782e | 7,590 | py | Python | offrl/base.py | dlqudwns/RepB-SDE | d799c3bbfc9aeca9251dfa84255d1c1b90af42ce | [
"MIT"
] | null | null | null | offrl/base.py | dlqudwns/RepB-SDE | d799c3bbfc9aeca9251dfa84255d1c1b90af42ce | [
"MIT"
] | null | null | null | offrl/base.py | dlqudwns/RepB-SDE | d799c3bbfc9aeca9251dfa84255d1c1b90af42ce | [
"MIT"
] | null | null | null | import numpy as np
import tensorflow as tf
import tensorflow_probability as tfp
SCALE_DIAG_MIN_MAX = (-20, 2)
EPS = 1e-6
def apply_squashing_func(sample, logp):
"""
Squash the ouput of the gaussian distribution and account for that in the log probability.
:param sample: (tf.Tensor) Action sampled from Ga... | 40.15873 | 100 | 0.645059 |
6b6d4190127b487993f75e4be2892ed1328ace49 | 3,565 | py | Python | skinematics/sensors/xio.py | mohataher/scikit-kinematics | fa8c80c13981310666e22dcd35138be1af1b4318 | [
"BSD-3-Clause"
] | null | null | null | skinematics/sensors/xio.py | mohataher/scikit-kinematics | fa8c80c13981310666e22dcd35138be1af1b4318 | [
"BSD-3-Clause"
] | null | null | null | skinematics/sensors/xio.py | mohataher/scikit-kinematics | fa8c80c13981310666e22dcd35138be1af1b4318 | [
"BSD-3-Clause"
] | 1 | 2021-11-02T22:53:23.000Z | 2021-11-02T22:53:23.000Z | '''
Import data saved with XIO-sensors
'''
'''
Author: Thomas Haslwanter
Version: 0.2
Date: May-2016
'''
import os
import pandas as pd
def read_ratefile(reg_file):
'''Read send-rates from an XIO sensor.
"Disabled" channels have the "rate" set to "None".
Parameters
----------
in_file : string... | 24.756944 | 64 | 0.520898 |
6b6de959719deda0bcf0d3617c5c148c46c3e48d | 2,166 | py | Python | zcls/util/cutmix.py | ZJCV/PyCls | 1ef59301646b6134f2ffcc009b4fd76550fa4089 | [
"Apache-2.0"
] | 110 | 2021-02-04T14:32:57.000Z | 2022-03-30T01:51:56.000Z | zcls/util/cutmix.py | ZJCV/PyCls | 1ef59301646b6134f2ffcc009b4fd76550fa4089 | [
"Apache-2.0"
] | 8 | 2021-04-11T02:46:57.000Z | 2021-12-14T19:30:58.000Z | zcls/util/cutmix.py | ZJCV/PyCls | 1ef59301646b6134f2ffcc009b4fd76550fa4089 | [
"Apache-2.0"
] | 20 | 2021-02-07T14:17:07.000Z | 2022-03-22T05:20:40.000Z | # -*- coding: utf-8 -*-
"""
@date: 2021/7/26 10:10
@file: cutmix.py
@author: zj
@description:
refer to [ clovaai/CutMix-PyTorch](https://github.com/clovaai/CutMix-PyTorch)
"""
import torch
import numpy as np
from zcls.config.key_word import KEY_LOSS
def cutmix_data(images, targets, alpha=1.0, device=torch.device... | 26.740741 | 106 | 0.645891 |
6b707cd697e11ff349acb292012f7c6bd2f868a2 | 4,625 | py | Python | jsk_2015_05_baxter_apc/node_scripts/common.py | pazeshun/jsk_apc | 0ff42000ad5992f8a31e719a5360a39cf4fa1fde | [
"BSD-3-Clause"
] | null | null | null | jsk_2015_05_baxter_apc/node_scripts/common.py | pazeshun/jsk_apc | 0ff42000ad5992f8a31e719a5360a39cf4fa1fde | [
"BSD-3-Clause"
] | 2 | 2019-04-11T05:36:23.000Z | 2019-08-19T12:58:10.000Z | jsk_2015_05_baxter_apc/node_scripts/common.py | pazeshun/jsk_apc | 0ff42000ad5992f8a31e719a5360a39cf4fa1fde | [
"BSD-3-Clause"
] | null | null | null | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
import os
import yaml
import gzip
import cPickle as pickle
import cv2
from catkin import terminal_color
import rospy
from jsk_2015_05_baxter_apc.srv import ObjectMatch, ObjectMatchResponse
def save_siftdata(obj_name, siftdata):
"""Save sift data to data/siftdata... | 32.570423 | 82 | 0.592432 |
6b71925db630f1e5d7b40afa3a4eea245f2b4272 | 372 | py | Python | examples/timer.py | TeskaLabs/asab | f28894b62bad192d8d30df01a8ad1b842ee2a2fb | [
"BSD-3-Clause"
] | 23 | 2018-03-07T18:58:13.000Z | 2022-03-29T17:11:47.000Z | examples/timer.py | TeskaLabs/asab | f28894b62bad192d8d30df01a8ad1b842ee2a2fb | [
"BSD-3-Clause"
] | 87 | 2018-04-04T19:44:13.000Z | 2022-03-31T11:18:00.000Z | examples/timer.py | TeskaLabs/asab | f28894b62bad192d8d30df01a8ad1b842ee2a2fb | [
"BSD-3-Clause"
] | 10 | 2018-04-30T16:40:25.000Z | 2022-03-09T10:55:24.000Z | #!/usr/bin/env python3
import asab
if __name__ == '__main__':
app = TimerApplication()
app.run()
| 17.714286 | 63 | 0.723118 |
6b720ba819c29547ae26389980f418117f2a4a29 | 26,708 | py | Python | main.py | ikarmus2001/DziekanBOT | 393df5b5d4bdfa6e34bd44da0cca8e97fa51e46a | [
"MIT"
] | 2 | 2021-02-22T16:38:08.000Z | 2021-02-23T12:26:29.000Z | main.py | ikarmus2001/DziekanBOT | 393df5b5d4bdfa6e34bd44da0cca8e97fa51e46a | [
"MIT"
] | null | null | null | main.py | ikarmus2001/DziekanBOT | 393df5b5d4bdfa6e34bd44da0cca8e97fa51e46a | [
"MIT"
] | 1 | 2021-02-22T10:48:38.000Z | 2021-02-22T10:48:38.000Z | import discord as dc
from dotenv import load_dotenv
from os import getenv
import datetime as dt
import json, string
load_dotenv()
#*#*#*# variables #*#*#*#
config_relative_path = getenv("CONFIG")
database_relative_path = getenv("DATABASE")
token = getenv("TOKEN")
#*#*#*#*#*#*#*#*#*#*#*#*#
with open(co... | 48.648452 | 193 | 0.545305 |
6b7335fdc121bab7e4b361e779e47bb56e5672d8 | 6,635 | py | Python | filter_cube.py | jd-au/thor-hi | 16a1326fcfe2ffaac496d2576b8727ca2f12dc9b | [
"Apache-2.0"
] | null | null | null | filter_cube.py | jd-au/thor-hi | 16a1326fcfe2ffaac496d2576b8727ca2f12dc9b | [
"Apache-2.0"
] | null | null | null | filter_cube.py | jd-au/thor-hi | 16a1326fcfe2ffaac496d2576b8727ca2f12dc9b | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python -u
# Filter out emission from a THOR HI cube. Will 2D Fourier transform each plane of the cube and zero out the centre
# of the Fourier image and then inverse Fouroer transform back to the image domain. This produces a cube without the
# large scale emission
# Author James Dempsey
# Date 26 Nov ... | 32.52451 | 119 | 0.677468 |
6b7384092723174901fdb2fe1b0d1247ce21ab53 | 2,383 | py | Python | niscv_v2/experiments/simulation/resampling_ratio.py | IanFla/Importance-Sampling | f2dd2164e95377d2cf025fcddd19b2592394e4d7 | [
"Apache-2.0"
] | null | null | null | niscv_v2/experiments/simulation/resampling_ratio.py | IanFla/Importance-Sampling | f2dd2164e95377d2cf025fcddd19b2592394e4d7 | [
"Apache-2.0"
] | null | null | null | niscv_v2/experiments/simulation/resampling_ratio.py | IanFla/Importance-Sampling | f2dd2164e95377d2cf025fcddd19b2592394e4d7 | [
"Apache-2.0"
] | null | null | null | import numpy as np
import scipy.stats as st
from niscv_v2.basics.exp import Exp
from niscv_v2.basics import utils
import multiprocessing
import os
from functools import partial
from datetime import datetime as dt
import pickle
if __name__ == '__main__':
main(4, 'st')
main(6, 'st')
main(4, 'sp')
mai... | 30.164557 | 100 | 0.632396 |
6b73e119d61f8d0b2839a62674b1f7bc89fb2f58 | 2,641 | py | Python | 220_contains_duplicate_iii.py | gengwg/leetcode | 0af5256ec98149ef5863f3bba78ed1e749650f6e | [
"Apache-2.0"
] | 2 | 2018-04-24T19:17:40.000Z | 2018-04-24T19:33:52.000Z | 220_contains_duplicate_iii.py | gengwg/leetcode | 0af5256ec98149ef5863f3bba78ed1e749650f6e | [
"Apache-2.0"
] | null | null | null | 220_contains_duplicate_iii.py | gengwg/leetcode | 0af5256ec98149ef5863f3bba78ed1e749650f6e | [
"Apache-2.0"
] | 3 | 2020-06-17T05:48:52.000Z | 2021-01-02T06:08:25.000Z | # -*- coding: utf-8 -*-
# 220. Contains Duplicate III
#
# Given an array of integers,
# find out whether there are two distinct indices i and j in the array
# such that the absolute difference between nums[i] and nums[j] is at most t
# and the absolute difference between i and j is at most k.
import collections
if... | 31.440476 | 108 | 0.523287 |
6b7420711037e6b6953b203dd71e4d0da3755188 | 312 | py | Python | pommerman/agents/frozen_agent.py | PBarde/ASAF-playground | 6567e5c56b6e077e0686376240bd3ccaa8a0da0c | [
"Apache-2.0"
] | 1 | 2020-12-22T06:45:18.000Z | 2020-12-22T06:45:18.000Z | pommerman/agents/frozen_agent.py | PBarde/ASAF-playground | 6567e5c56b6e077e0686376240bd3ccaa8a0da0c | [
"Apache-2.0"
] | null | null | null | pommerman/agents/frozen_agent.py | PBarde/ASAF-playground | 6567e5c56b6e077e0686376240bd3ccaa8a0da0c | [
"Apache-2.0"
] | null | null | null | from . import BaseAgent
from .. import constants
| 24 | 58 | 0.673077 |
6b759d3b1a6d1d1a23a8d58955f7fb20ffc91c12 | 3,630 | py | Python | Principles-of-Computing/project-4-planner-for-yahtzee.py | ugaliguy/Python-at-Rice | b145a4475bdd3e9250f88a01dff894945d9b3e4b | [
"MIT"
] | null | null | null | Principles-of-Computing/project-4-planner-for-yahtzee.py | ugaliguy/Python-at-Rice | b145a4475bdd3e9250f88a01dff894945d9b3e4b | [
"MIT"
] | null | null | null | Principles-of-Computing/project-4-planner-for-yahtzee.py | ugaliguy/Python-at-Rice | b145a4475bdd3e9250f88a01dff894945d9b3e4b | [
"MIT"
] | 2 | 2020-11-09T16:06:28.000Z | 2020-12-07T07:42:47.000Z | """
Planner for Yahtzee
Simplifications: only allow discard and roll, only score against upper level
"""
# Used to increase the timeout, if necessary
import codeskulptor
codeskulptor.set_timeout(20)
def gen_all_sequences(outcomes, length):
"""
Iterative function that enumerates the set of all sequ... | 25.928571 | 96 | 0.614601 |
6b7921203d0b38a45781f77f3696c8da26caa2a9 | 3,079 | py | Python | pysnmp/AVAM-SNMPv1.py | agustinhenze/mibs.snmplabs.com | 1fc5c07860542b89212f4c8ab807057d9a9206c7 | [
"Apache-2.0"
] | 11 | 2021-02-02T16:27:16.000Z | 2021-08-31T06:22:49.000Z | pysnmp/AVAM-SNMPv1.py | agustinhenze/mibs.snmplabs.com | 1fc5c07860542b89212f4c8ab807057d9a9206c7 | [
"Apache-2.0"
] | 75 | 2021-02-24T17:30:31.000Z | 2021-12-08T00:01:18.000Z | pysnmp/AVAM-SNMPv1.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 AVAM-SNMPv1 (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/AVAM-SNMPv1
# Produced by pysmi-0.3.4 at Mon Apr 29 17:16:06 2019
# On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4
# Using Python version 3.7.3 (default, Mar 27 2019, 0... | 102.633333 | 543 | 0.755765 |
6b7b7ed1542c5197c3dec6914240d11b49526c97 | 4,649 | py | Python | engraving/engraving.py | catt0/lostarkthings | 72d8756d899c01e19884eebd3978d965f9073bba | [
"MIT"
] | 1 | 2022-03-24T12:29:54.000Z | 2022-03-24T12:29:54.000Z | engraving/engraving.py | catt0/lostarkthings | 72d8756d899c01e19884eebd3978d965f9073bba | [
"MIT"
] | null | null | null | engraving/engraving.py | catt0/lostarkthings | 72d8756d899c01e19884eebd3978d965f9073bba | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
# MIT License
# Copyright (c) 2022 catt0
# 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,... | 33.446043 | 178 | 0.670897 |
6b7cc6ba3cb5669cb102ecb6c5ae731e244b2f55 | 4,447 | py | Python | tests/topo_test.py | dlgeorge/geoclaw | 2b4ce9b1ba2532fe3ac38ee7c05297eb61e45bd1 | [
"BSD-3-Clause"
] | null | null | null | tests/topo_test.py | dlgeorge/geoclaw | 2b4ce9b1ba2532fe3ac38ee7c05297eb61e45bd1 | [
"BSD-3-Clause"
] | 2 | 2018-11-05T19:41:12.000Z | 2019-03-19T00:03:38.000Z | tests/topo_test.py | BrisaDavis/geoclaw | ccab58669bc2950de13cf0f35c10b3cd1cb1cda6 | [
"BSD-3-Clause"
] | null | null | null | #!/usr/bin/env python
# encoding: utf-8
from __future__ import absolute_import
from __future__ import print_function
import os
import glob
import tempfile
import matplotlib.pyplot as plt
from clawpack.geoclaw import topotools
import clawpack.geoclaw.topo as topo
import numpy as np
def test1():
"""
Make two... | 28.690323 | 83 | 0.555431 |
6b7cddd851735817010a31afc1a8841a61a5dfc8 | 3,443 | py | Python | moveit/moveit.py | pavel-paulau/moveit | 9572f3b4330b058c4cb324c774fff443a1ccb2f9 | [
"Apache-2.0"
] | 2 | 2015-09-28T13:54:43.000Z | 2015-09-28T16:59:43.000Z | moveit/moveit.py | pavel-paulau/moveit | 9572f3b4330b058c4cb324c774fff443a1ccb2f9 | [
"Apache-2.0"
] | null | null | null | moveit/moveit.py | pavel-paulau/moveit | 9572f3b4330b058c4cb324c774fff443a1ccb2f9 | [
"Apache-2.0"
] | 1 | 2020-03-10T20:17:28.000Z | 2020-03-10T20:17:28.000Z | #!/usr/bin/env python
import argparse
import json
from collections import defaultdict
if __name__ == '__main__':
main()
| 32.481132 | 79 | 0.598606 |
6b7d62abec208b5d28e43bdb68af22c4c8b92da6 | 43,769 | py | Python | test/augmentation/test_augmentation_3d.py | prcaaf/kornia | a3eca7400e6da89b313549bbae751ff23a0e7bc5 | [
"ECL-2.0",
"Apache-2.0"
] | 1 | 2020-12-13T16:13:08.000Z | 2020-12-13T16:13:08.000Z | test/augmentation/test_augmentation_3d.py | ZhiyuanChen/kornia | 87a0ead264ce5fc97997071acb9fe2286d6c425c | [
"ECL-2.0",
"Apache-2.0"
] | null | null | null | test/augmentation/test_augmentation_3d.py | ZhiyuanChen/kornia | 87a0ead264ce5fc97997071acb9fe2286d6c425c | [
"ECL-2.0",
"Apache-2.0"
] | null | null | null | from typing import Union, Tuple
import pytest
import torch
import torch.nn as nn
from torch.testing import assert_allclose
from torch.autograd import gradcheck
import kornia
import kornia.testing as utils # test utils
from kornia.constants import pi
from kornia.augmentation import (
RandomDepthicalFlip3D,
R... | 43.378593 | 112 | 0.448125 |
6b7e960044cdd21ef1c64e33f14c9a00d918de92 | 516 | py | Python | print_spelling_suggestions.py | tmills/econsult | a702948278bd9995623026702bcd4c4c9bd47159 | [
"Apache-2.0"
] | null | null | null | print_spelling_suggestions.py | tmills/econsult | a702948278bd9995623026702bcd4c4c9bd47159 | [
"Apache-2.0"
] | 3 | 2021-03-25T22:10:23.000Z | 2021-06-01T22:48:12.000Z | print_spelling_suggestions.py | tmills/econsult | a702948278bd9995623026702bcd4c4c9bd47159 | [
"Apache-2.0"
] | 1 | 2019-04-12T19:02:12.000Z | 2019-04-12T19:02:12.000Z | #!/usr/bin/env python
from pattern.en import spelling
import sys
if __name__ == '__main__':
main(sys.argv[1:]) | 24.571429 | 61 | 0.542636 |
6b7f23ac39d6f288d7f8df3e114d47ba4ac7749a | 391 | py | Python | setup.py | opalmer/vpsutil | 3d589f0c6184a9ca79f0a96af1181bc4466b7095 | [
"MIT"
] | null | null | null | setup.py | opalmer/vpsutil | 3d589f0c6184a9ca79f0a96af1181bc4466b7095 | [
"MIT"
] | null | null | null | setup.py | opalmer/vpsutil | 3d589f0c6184a9ca79f0a96af1181bc4466b7095 | [
"MIT"
] | null | null | null | from distutils.core import setup
requires = ["requests", "paramiko"]
try:
import configparser
except ImportError:
requires.append("configparser")
setup(
name="vpsutil",
version="0.0.0",
license="MIT",
packages=["vpsutil"],
install_requires=requires,
entry_points={
"console_scr... | 17.772727 | 43 | 0.618926 |
6b7f71ca34f365255fcb346d72fcc8edbf289a3b | 93 | py | Python | podstrony/apps.py | ArminD93/Django_test | 1f1de5976a1a8a46b7183200a22ef34500cdf1ee | [
"MIT"
] | null | null | null | podstrony/apps.py | ArminD93/Django_test | 1f1de5976a1a8a46b7183200a22ef34500cdf1ee | [
"MIT"
] | 6 | 2019-10-31T14:09:52.000Z | 2021-04-12T21:17:02.000Z | podstrony/apps.py | ArminD93/Django_test | 1f1de5976a1a8a46b7183200a22ef34500cdf1ee | [
"MIT"
] | null | null | null | from django.apps import AppConfig
| 15.5 | 33 | 0.763441 |
6b7fffb88d3d8522751df917d4f9168bc42ba45e | 4,117 | py | Python | aitlas/datasets/sat6.py | biasvariancelabs/aitlas | e36913c44d5a8393566b7271607ba839f9be0df3 | [
"MIT"
] | 32 | 2020-12-04T19:48:19.000Z | 2022-03-16T18:18:05.000Z | aitlas/datasets/sat6.py | biasvariancelabs/aitlas | e36913c44d5a8393566b7271607ba839f9be0df3 | [
"MIT"
] | 2 | 2021-04-11T17:09:14.000Z | 2021-05-14T13:22:41.000Z | aitlas/datasets/sat6.py | biasvariancelabs/aitlas | e36913c44d5a8393566b7271607ba839f9be0df3 | [
"MIT"
] | 8 | 2021-04-06T22:06:27.000Z | 2022-01-30T06:01:39.000Z | import csv
import pandas as pd
import seaborn as sns
import matplotlib.pyplot as plt
import scipy.io
import numpy as np
import random
from ..base import BaseDataset
from .schemas import MatDatasetSchema
"""
The format of the mat dataset is:
train_x 28x28x4x400000 uint8 (containing 400000 training samples of 28x28 ima... | 35.188034 | 103 | 0.621326 |
6b8206189230c459d344d826bd836366d971ebcf | 6,768 | py | Python | src/config_gui.py | blaubachn/slideshow | 8f87db77502ee89a689a884ac2455d4019b20363 | [
"MIT"
] | null | null | null | src/config_gui.py | blaubachn/slideshow | 8f87db77502ee89a689a884ac2455d4019b20363 | [
"MIT"
] | null | null | null | src/config_gui.py | blaubachn/slideshow | 8f87db77502ee89a689a884ac2455d4019b20363 | [
"MIT"
] | null | null | null | import gi
gi.require_version('Gtk', '3.0')
from gi.repository import Gtk
from config import Configuration_Manager
about_text = '''Welcome to Slideshow!
Photo Directory: The remote will diplay a slideshow of the photos in this folder (excluding photos in it's subfolders)
Installation Type: flatpak commands have an ext... | 45.12 | 120 | 0.494385 |
6b834a7d97ab58b448634df72525ae3e7aa49bda | 391 | py | Python | PythonExercicios/ex033.py | Lucas-ns/Python-3-Curso-Em-Video | f6d338fffd7a4606d34fab09634eea0fe4b3dfb3 | [
"MIT"
] | null | null | null | PythonExercicios/ex033.py | Lucas-ns/Python-3-Curso-Em-Video | f6d338fffd7a4606d34fab09634eea0fe4b3dfb3 | [
"MIT"
] | null | null | null | PythonExercicios/ex033.py | Lucas-ns/Python-3-Curso-Em-Video | f6d338fffd7a4606d34fab09634eea0fe4b3dfb3 | [
"MIT"
] | null | null | null | n1 = int(input('Primeiro Valor: '))
n2 = int(input('Segundo Valor: '))
n3 = int(input('Terceiro Valor: '))
maior = n1
menor = n1
if n2 < n3 and n2 < n1:
menor = n2
if n3 < n2 and n3 < n1:
menor = n3
print('O menor valor digitado foi {}'.format(menor))
if n2 > n3 and n2 > n1:
maior = n2
if n3 > n2 and n3 > n... | 24.4375 | 52 | 0.608696 |
6b84a8e0c10dad08caa3e4f6f99c18a7c9f285ee | 2,896 | py | Python | os_brick/initiator/connectors/local.py | ebalduf/os-brick-backports | 6a180265560d5e0bab80e47ac25c15906d1165fb | [
"Apache-2.0"
] | null | null | null | os_brick/initiator/connectors/local.py | ebalduf/os-brick-backports | 6a180265560d5e0bab80e47ac25c15906d1165fb | [
"Apache-2.0"
] | null | null | null | os_brick/initiator/connectors/local.py | ebalduf/os-brick-backports | 6a180265560d5e0bab80e47ac25c15906d1165fb | [
"Apache-2.0"
] | null | null | null | # All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in... | 36.658228 | 79 | 0.649862 |
6b8528a6311dd8c9d7d8cb2e04442a68e44c16ec | 46 | py | Python | petal/__init__.py | gidoBOSSftw5731/petal | 5d04796d9b74adfe8c022024945f6d0481f974ea | [
"MIT"
] | null | null | null | petal/__init__.py | gidoBOSSftw5731/petal | 5d04796d9b74adfe8c022024945f6d0481f974ea | [
"MIT"
] | null | null | null | petal/__init__.py | gidoBOSSftw5731/petal | 5d04796d9b74adfe8c022024945f6d0481f974ea | [
"MIT"
] | null | null | null | from .petal import Petal
__all__ = ["Petal"]
| 11.5 | 24 | 0.695652 |
6b85c3711ce945544b892923a3692a030d199f9f | 2,705 | py | Python | processing/data_collection/gazette/spiders/rj_rio_de_janeiro.py | gabubellon/querido-diario | b783dac359b86121173286869a8e0bbd31cf22af | [
"MIT"
] | null | null | null | processing/data_collection/gazette/spiders/rj_rio_de_janeiro.py | gabubellon/querido-diario | b783dac359b86121173286869a8e0bbd31cf22af | [
"MIT"
] | null | null | null | processing/data_collection/gazette/spiders/rj_rio_de_janeiro.py | gabubellon/querido-diario | b783dac359b86121173286869a8e0bbd31cf22af | [
"MIT"
] | null | null | null | from gazette.items import Gazette
import datetime as dt
import re
import scrapy
from gazette.spiders.base import BaseGazetteSpider
| 38.642857 | 121 | 0.607024 |
6b86ad80d46cd8819ce8434a7d769597836cdf0f | 3,502 | py | Python | 2c-AutopilotByColorSegmentation.py | Branyac/tello-innovation-challenge | 173087677bf2f964785ab76fae146b12e352ee0b | [
"MIT"
] | 1 | 2022-01-30T19:34:45.000Z | 2022-01-30T19:34:45.000Z | 2c-AutopilotByColorSegmentation.py | Branyac/tello-innovation-challenge | 173087677bf2f964785ab76fae146b12e352ee0b | [
"MIT"
] | null | null | null | 2c-AutopilotByColorSegmentation.py | Branyac/tello-innovation-challenge | 173087677bf2f964785ab76fae146b12e352ee0b | [
"MIT"
] | 1 | 2021-06-23T04:13:43.000Z | 2021-06-23T04:13:43.000Z | from djitellopy import Tello
import cv2
import numpy as np
import time
# Values for color segmentation
# It match an orange battery
LOWER = np.array([0, 239, 180])
UPPER = np.array([30, 255, 255])
DESIRED_OBJECT_SIZE = 100
MAX_SPEED_FORWARDBACK = 50
MAX_SPEED_UPDOWN = 50
MAX_SPEED_YAW = 100
MIN_MOV_TIME = 0.15
if ... | 35.734694 | 153 | 0.58538 |
6b8915baff1af0575cc4e24b0853c4cc6b8ad2a0 | 14,873 | py | Python | examples/CCS811UnitTest.py | Ekkehard/RBPiCCS811 | ca09d56b86afc92d253bdb630ddb815d04099edb | [
"Apache-2.0"
] | null | null | null | examples/CCS811UnitTest.py | Ekkehard/RBPiCCS811 | ca09d56b86afc92d253bdb630ddb815d04099edb | [
"Apache-2.0"
] | null | null | null | examples/CCS811UnitTest.py | Ekkehard/RBPiCCS811 | ca09d56b86afc92d253bdb630ddb815d04099edb | [
"Apache-2.0"
] | null | null | null | # Python Implementation: CCS811UnitTest
##
# @file CCS811UnitTest.py
#
# @version 1.0.1
#
# @par Purpose
# This module provides the Unit Test for the CCS811 module. It has been
# separated from the CCS811 module to conserve some resources, as this code is
# intended to also run on an Raspberry Pi Pico MCU. O... | 40.636612 | 80 | 0.408122 |
6b8a00b506487aff2b0ea1fefe241cb675cb897d | 4,169 | py | Python | gcloud/commons/tastypie/resources.py | springborland/bk-sops | a9057672c10efb5f2414a805a30ead4092429c76 | [
"Apache-2.0"
] | 1 | 2021-05-19T04:31:34.000Z | 2021-05-19T04:31:34.000Z | gcloud/commons/tastypie/resources.py | sighttviewliu/bk-sops | 6bf2f38bd93990f20f7c3a4decafc310e09e679c | [
"Apache-2.0"
] | null | null | null | gcloud/commons/tastypie/resources.py | sighttviewliu/bk-sops | 6bf2f38bd93990f20f7c3a4decafc310e09e679c | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
"""
Tencent is pleased to support the open source community by making PaaS (BlueKing PaaS Community
Edition) available.
Copyright (C) 2017-2020 THL A29 Limited, a Tencent company. All rights reserved.
Licensed under the MIT License (the "License"); you may not use this file except in compliance ... | 35.939655 | 115 | 0.633245 |
6b8b3dd970c2381dc6fab482c6f4e706bdbe8c46 | 25 | py | Python | core_dev/datetime_/__init__.py | alexzanderr/_core-dev | 831f69dad524e450c4243b1dd88f26de80e1d444 | [
"MIT"
] | null | null | null | core_dev/datetime_/__init__.py | alexzanderr/_core-dev | 831f69dad524e450c4243b1dd88f26de80e1d444 | [
"MIT"
] | null | null | null | core_dev/datetime_/__init__.py | alexzanderr/_core-dev | 831f69dad524e450c4243b1dd88f26de80e1d444 | [
"MIT"
] | null | null | null |
from .datetime_ import * | 12.5 | 24 | 0.76 |
6b8ba5e38a11991c07975fe01f68ff669ab459c0 | 811 | py | Python | badx12/common/click.py | agaddis02/badX12 | 7362a4d9629e570be8cd3b42af5210cda39e0efc | [
"MIT"
] | null | null | null | badx12/common/click.py | agaddis02/badX12 | 7362a4d9629e570be8cd3b42af5210cda39e0efc | [
"MIT"
] | null | null | null | badx12/common/click.py | agaddis02/badX12 | 7362a4d9629e570be8cd3b42af5210cda39e0efc | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
from collections import Iterable
import click
| 30.037037 | 103 | 0.633785 |
6b8bb153d1b8da0157b44ec53267ac54fdb21350 | 1,706 | py | Python | snakebids/admin.py | LouFel/snakebids | 6fdf64fb65471868b9cc9d55fd77654096c07686 | [
"MIT"
] | null | null | null | snakebids/admin.py | LouFel/snakebids | 6fdf64fb65471868b9cc9d55fd77654096c07686 | [
"MIT"
] | 2 | 2022-02-11T22:08:36.000Z | 2022-02-11T22:08:47.000Z | snakebids/admin.py | kaitj/snakebids | f205ab279223e9f5bb87ba170fe29d8324bc7484 | [
"MIT"
] | null | null | null | """Script to generate a Snakebids project."""
import argparse
import os
from pathlib import Path
from cookiecutter.main import cookiecutter
import snakebids
from snakebids.app import SnakeBidsApp
from snakebids.cli import add_dynamic_args
def main():
"""Invoke Cookiecutter on the Snakebids project template.... | 28.433333 | 88 | 0.715709 |
6b8c93d8422ed7233811fd0f7290cad989fa723c | 4,500 | py | Python | estimateHR_unittest.py | RingoYen85/HeartRateMonitor | 8bbecfd0969c1a91b8a5c3117869ac248c31cf17 | [
"MIT"
] | null | null | null | estimateHR_unittest.py | RingoYen85/HeartRateMonitor | 8bbecfd0969c1a91b8a5c3117869ac248c31cf17 | [
"MIT"
] | null | null | null | estimateHR_unittest.py | RingoYen85/HeartRateMonitor | 8bbecfd0969c1a91b8a5c3117869ac248c31cf17 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
"""
Created on Fri Sep 23 21:54:45 2016
@author: ringoyen
"""
import numpy as np
import unittest
if __name__ == '__main__':
unittest.main() | 31.690141 | 112 | 0.607556 |
6b8d70280f0cb0d3625c06ba1c69384706890a4a | 2,602 | py | Python | sequence/fastx_translate.py | shenwei356/bio_scripts | 703cec8d21903516346e2aae4d77d23385c30905 | [
"MIT"
] | 94 | 2015-03-26T04:32:29.000Z | 2022-03-22T13:44:11.000Z | sequence/fastx_translate.py | xinwang-bio/bio_scripts | 64fda3a72ba14edf87952a809c3d52871f155cca | [
"MIT"
] | null | null | null | sequence/fastx_translate.py | xinwang-bio/bio_scripts | 64fda3a72ba14edf87952a809c3d52871f155cca | [
"MIT"
] | 70 | 2015-04-01T10:27:05.000Z | 2021-11-08T01:46:39.000Z | #!/usr/bin/env python
# -*- coding: utf-8 -*-
# https://github.com/shenwei356/bio_scripts
from __future__ import print_function
import argparse
import gzip
import logging
import os
import re
import sys
from Bio import SeqIO
from Bio.Seq import Seq
from Bio.SeqRecord import SeqRecord
if __name__ == '__main__':
... | 35.162162 | 130 | 0.601076 |
6b8db4952ad5c55aa4611431b1886cf54a31f84a | 682 | py | Python | Assignment 3. Paxos/Simulation/Network/Network.py | WailAbou/Distributed-Processing | 46a36f1fd51d6f8b35cc639eb8002d81d7e09f2b | [
"MIT"
] | null | null | null | Assignment 3. Paxos/Simulation/Network/Network.py | WailAbou/Distributed-Processing | 46a36f1fd51d6f8b35cc639eb8002d81d7e09f2b | [
"MIT"
] | null | null | null | Assignment 3. Paxos/Simulation/Network/Network.py | WailAbou/Distributed-Processing | 46a36f1fd51d6f8b35cc639eb8002d81d7e09f2b | [
"MIT"
] | null | null | null | from Simulation.Network.Actions import send_message
| 27.28 | 77 | 0.651026 |
6b8defc3a09a8d03e2adb7a13517e975cbd888f3 | 697 | py | Python | test/test_db_matches_ui.py | ProOksana/python_training | 2174f08ebd52905bf28e7b32baf1b1401a05f79e | [
"Apache-2.0"
] | null | null | null | test/test_db_matches_ui.py | ProOksana/python_training | 2174f08ebd52905bf28e7b32baf1b1401a05f79e | [
"Apache-2.0"
] | null | null | null | test/test_db_matches_ui.py | ProOksana/python_training | 2174f08ebd52905bf28e7b32baf1b1401a05f79e | [
"Apache-2.0"
] | null | null | null | from model.contact import Contacts
| 58.083333 | 186 | 0.734577 |
6b904ccd419a7dbc39df362dd10c4cbe6f6a6b80 | 859 | py | Python | DjangoBlog/account/models.py | marasiali/Django-bog | faac81275d27b501dda0be32c82200c80941b7de | [
"MIT"
] | null | null | null | DjangoBlog/account/models.py | marasiali/Django-bog | faac81275d27b501dda0be32c82200c80941b7de | [
"MIT"
] | null | null | null | DjangoBlog/account/models.py | marasiali/Django-bog | faac81275d27b501dda0be32c82200c80941b7de | [
"MIT"
] | null | null | null | from django.db import models
from django.utils import timezone
from django.contrib.auth.models import AbstractUser
| 35.791667 | 146 | 0.735739 |
6b90cf31e44e1e7e27466082bc57a29d138e03cf | 7,345 | py | Python | pyfilter/test/test_filter.py | zkscpqm/pyfilter | 39c284681ec6f377059907b75346028d99cbdd4c | [
"MIT"
] | null | null | null | pyfilter/test/test_filter.py | zkscpqm/pyfilter | 39c284681ec6f377059907b75346028d99cbdd4c | [
"MIT"
] | 1 | 2021-04-28T18:40:13.000Z | 2021-04-28T18:40:13.000Z | pyfilter/test/test_filter.py | zkscpqm/pyfilter | 39c284681ec6f377059907b75346028d99cbdd4c | [
"MIT"
] | null | null | null | import unittest
import os
from typing import Any, Text, NoReturn, Set, Union
from parameterized import parameterized
from pyfilter import FilterContext
from pyfilter import TextFilter
| 53.224638 | 116 | 0.644384 |
6b90ec08ade0528601d7d5711be814ac665fc15d | 1,694 | py | Python | song_bond.py | skullydazed/PyRoombaAdapter | 88824e91b0f0cec008b16cfaa5a62a6546f1226e | [
"MIT"
] | null | null | null | song_bond.py | skullydazed/PyRoombaAdapter | 88824e91b0f0cec008b16cfaa5a62a6546f1226e | [
"MIT"
] | null | null | null | song_bond.py | skullydazed/PyRoombaAdapter | 88824e91b0f0cec008b16cfaa5a62a6546f1226e | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
"""James Bond Theme, Composed by Monty Norman
Adapted for Roomba by Zach White
"""
from time import sleep
from pyroombaadapter import PyRoombaAdapter
notes0 = (
# note, duration
'B3', '1/2',
'C4', '1/2',
'C#4', '1/2',
'C4', '1/2',
'B3', '1/2',
'C4', '1/2',
'C#4',... | 18.822222 | 57 | 0.485832 |
6b91473adaa0d54ec3df16837118bb8c64722382 | 227 | py | Python | users/views.py | digitaloxford/do-wagtail | 49dd75b95109ebb38bf66aca13d3fdeb8e25d319 | [
"MIT"
] | 2 | 2021-04-11T11:59:51.000Z | 2021-04-12T06:56:23.000Z | users/views.py | digitaloxford/do-wagtail | 49dd75b95109ebb38bf66aca13d3fdeb8e25d319 | [
"MIT"
] | 8 | 2021-04-10T10:40:27.000Z | 2022-01-25T16:32:22.000Z | users/views.py | digitaloxford/do-wagtail | 49dd75b95109ebb38bf66aca13d3fdeb8e25d319 | [
"MIT"
] | null | null | null | from django.contrib.auth.decorators import login_required
from django.shortcuts import render
from django.views import generic
from . import models
| 22.7 | 57 | 0.806167 |
6b934399f266b4f9c4b7a0180b20fcdaa634e13b | 4,263 | py | Python | tests/conftest.py | Dimfred/imxpy | 289a67fa51ef7b33ee106a65ad69340d07c986b3 | [
"MIT"
] | 13 | 2021-12-11T11:52:32.000Z | 2022-03-11T12:58:56.000Z | tests/conftest.py | Dimfred/imxpy | 289a67fa51ef7b33ee106a65ad69340d07c986b3 | [
"MIT"
] | 1 | 2021-12-19T19:15:29.000Z | 2021-12-26T14:09:16.000Z | tests/conftest.py | Dimfred/imxpy | 289a67fa51ef7b33ee106a65ad69340d07c986b3 | [
"MIT"
] | 1 | 2022-01-10T15:01:04.000Z | 2022-01-10T15:01:04.000Z | from pathlib import Path
import sys
import time
# add parent dir of imxpy
sys.path.insert(0, str(Path(__file__).parent.parent.parent))
from easydict import EasyDict as edict
import pytest
from imx_client import IMXClient
from imx_objects import *
def mint_params(contract_addr, id_, addr):
param... | 21.861538 | 84 | 0.697162 |
6b93b639b40dce2081a3f1509a8777312189b2f5 | 73 | py | Python | airbyte-integrations/connectors/source-twilio-singer/source_twilio_singer/__init__.py | rajatariya21/airbyte | 11e70a7a96e2682b479afbe6f709b9a5fe9c4a8d | [
"MIT"
] | 2 | 2021-03-02T09:17:41.000Z | 2021-03-02T11:02:23.000Z | airbyte-integrations/connectors/source-twilio-singer/source_twilio_singer/__init__.py | rajatariya21/airbyte | 11e70a7a96e2682b479afbe6f709b9a5fe9c4a8d | [
"MIT"
] | 4 | 2021-09-01T00:33:50.000Z | 2022-02-27T16:13:46.000Z | airbyte-integrations/connectors/source-twilio-singer/source_twilio_singer/__init__.py | rajatariya21/airbyte | 11e70a7a96e2682b479afbe6f709b9a5fe9c4a8d | [
"MIT"
] | 1 | 2021-07-02T15:08:53.000Z | 2021-07-02T15:08:53.000Z | from .source import SourceTwilioSinger
__all__ = ["SourceTwilioSinger"]
| 18.25 | 38 | 0.808219 |
6b93c4cb81d74f0acde8f0cc82aaa2e1626a119a | 1,088 | py | Python | off_policy_rl/off_policy_rl/utils/epoch.py | dti-research/ur-learning-shifting-for-grasping | 2dfecf6b2dbe67b65af00fc0ae5f73be2cb8a801 | [
"BSD-3-Clause"
] | 1 | 2021-04-12T07:04:26.000Z | 2021-04-12T07:04:26.000Z | off_policy_rl/off_policy_rl/utils/epoch.py | dti-research/ur-learning-shifting-for-grasping | 2dfecf6b2dbe67b65af00fc0ae5f73be2cb8a801 | [
"BSD-3-Clause"
] | 1 | 2021-11-10T15:51:15.000Z | 2021-11-10T15:51:15.000Z | off_policy_rl/off_policy_rl/utils/epoch.py | dti-research/ur-learning-shifting-for-grasping | 2dfecf6b2dbe67b65af00fc0ae5f73be2cb8a801 | [
"BSD-3-Clause"
] | null | null | null | from typing import List
import numpy as np
from off_policy_rl.utils.selection_method import SelectionMethod
| 35.096774 | 106 | 0.661765 |
6b940f509f4451581eb06a07caf3cae0277d933c | 306 | py | Python | nodestack/settings_example.py | chriscslaughter/nodestack | 1905d5fd7d0e208287ceb6016852ada6d32b0984 | [
"MIT"
] | null | null | null | nodestack/settings_example.py | chriscslaughter/nodestack | 1905d5fd7d0e208287ceb6016852ada6d32b0984 | [
"MIT"
] | 3 | 2020-02-11T23:15:56.000Z | 2021-06-10T20:52:54.000Z | nodestack/settings_example.py | chriscslaughter/nodestack | 1905d5fd7d0e208287ceb6016852ada6d32b0984 | [
"MIT"
] | null | null | null | DATABASES = {
'default': {
'ENGINE': 'django.db.backends.postgresql_psycopg2',
'NAME': '',
'USER': '',
'PASSWORD': '',
'HOST': '',
'PORT': 5432
}
}
REDIS_HOST = '18.215.184.182'
REDIS_PORT = 6379
REDIS_PASSWORD = 'vwTe6yLaw5hX9dIdbfW0'
REDIS_DB = 0
| 19.125 | 59 | 0.53268 |
6b947dc36dc1850a2e02965bc2a02ae7eeca3cad | 11,761 | py | Python | model/deterministic_decoder.py | illc-uva/deep-generative-lm | c65bdf9d72e7d9d4e02576b1e84bce623725a0cd | [
"MIT"
] | 26 | 2019-04-18T13:07:34.000Z | 2021-03-24T11:55:26.000Z | model/deterministic_decoder.py | illc-uva/deep-generative-lm | c65bdf9d72e7d9d4e02576b1e84bce623725a0cd | [
"MIT"
] | null | null | null | model/deterministic_decoder.py | illc-uva/deep-generative-lm | c65bdf9d72e7d9d4e02576b1e84bce623725a0cd | [
"MIT"
] | 9 | 2019-04-18T23:00:46.000Z | 2021-09-23T15:34:56.000Z | """
A deterministic decoder.
"""
import numpy as np
import sys
import os.path as osp
from collections import defaultdict
from warnings import warn
import torch
import torch.nn as nn
import torch.nn.functional as F
from torch.nn.utils.rnn import pack_padded_sequence, pad_packed_sequence
# We include the path of the t... | 45.762646 | 122 | 0.596803 |
6b96bddabe2ed1e571fa0fb67e8fe24ad3b42daf | 2,316 | py | Python | trove/tests/scenario/runners/instance_force_delete_runners.py | sapcc/trove | c03ec0827687fba202f72f4d264ab70158604857 | [
"Apache-2.0"
] | 244 | 2015-01-01T12:04:44.000Z | 2022-03-25T23:38:39.000Z | trove/tests/scenario/runners/instance_force_delete_runners.py | sapcc/trove | c03ec0827687fba202f72f4d264ab70158604857 | [
"Apache-2.0"
] | 6 | 2015-08-18T08:19:10.000Z | 2022-03-05T02:32:36.000Z | trove/tests/scenario/runners/instance_force_delete_runners.py | sapcc/trove | c03ec0827687fba202f72f4d264ab70158604857 | [
"Apache-2.0"
] | 178 | 2015-01-02T15:16:58.000Z | 2022-03-23T03:30:20.000Z | # Copyright 2016 Tesora 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
#
# Unless required by a... | 38.6 | 78 | 0.702936 |
6b976f533f13bffac48ebcfedaef5b78d985ab9b | 489 | py | Python | tests/providers/test_twilio.py | yaakov-github/notifiers | ae204bc08fd9efa06597e5e2cf30ad0a305c94bb | [
"MIT"
] | 2 | 2019-10-06T01:53:42.000Z | 2019-11-19T07:52:17.000Z | tests/providers/test_twilio.py | Delgan/notifiers | 8dd2a8aaa81a9433034a8f347d984c8aa80be9af | [
"MIT"
] | null | null | null | tests/providers/test_twilio.py | Delgan/notifiers | 8dd2a8aaa81a9433034a8f347d984c8aa80be9af | [
"MIT"
] | null | null | null | import pytest
provider = 'twilio'
| 23.285714 | 86 | 0.570552 |
6b97a216ca7bed17169dea75598a8db7b38aa938 | 3,225 | py | Python | tests/conftest.py | jeromedockes/neuroquery_image_search | 2222caf464de84694273a494ec2d00071b3d14a2 | [
"BSD-3-Clause"
] | 3 | 2021-01-26T20:27:24.000Z | 2021-09-28T19:51:36.000Z | tests/conftest.py | jeromedockes/neuroquery_image_search | 2222caf464de84694273a494ec2d00071b3d14a2 | [
"BSD-3-Clause"
] | null | null | null | tests/conftest.py | jeromedockes/neuroquery_image_search | 2222caf464de84694273a494ec2d00071b3d14a2 | [
"BSD-3-Clause"
] | 1 | 2021-01-21T22:27:16.000Z | 2021-01-21T22:27:16.000Z | from pathlib import Path
import tempfile
from unittest.mock import MagicMock
import pytest
import numpy as np
import pandas as pd
from scipy import sparse
import nibabel
import nilearn
from nilearn.datasets import _testing
from nilearn.datasets._testing import request_mocker # noqa: F401
| 32.25 | 78 | 0.68093 |
6b9b875fc942d57331cb053f791fdadd062c380c | 515 | py | Python | src/handlers/os.py | rodones/daemon | 5bcc680962274390ab1a7ca36eb3a621d4a2144d | [
"BSD-3-Clause"
] | null | null | null | src/handlers/os.py | rodones/daemon | 5bcc680962274390ab1a7ca36eb3a621d4a2144d | [
"BSD-3-Clause"
] | null | null | null | src/handlers/os.py | rodones/daemon | 5bcc680962274390ab1a7ca36eb3a621d4a2144d | [
"BSD-3-Clause"
] | null | null | null | from core.handler import handle
import os
from datetime import datetime
import psutil
| 17.166667 | 83 | 0.699029 |
6b9bad3a40c3c22732dfc5fe66b2f8ecdcf3a1fd | 1,162 | py | Python | mall_spider/spiders/actions/action.py | 524243642/taobao_spider | 9cdaed1c7a67fc1f35ee2af2e18313cedf3b1e5e | [
"Unlicense"
] | 12 | 2019-06-06T12:23:08.000Z | 2021-06-15T17:50:07.000Z | mall_spider/spiders/actions/action.py | 524243642/mall_spider | 9cdaed1c7a67fc1f35ee2af2e18313cedf3b1e5e | [
"Unlicense"
] | 3 | 2021-03-31T19:02:47.000Z | 2022-02-11T03:43:15.000Z | mall_spider/spiders/actions/action.py | 524243642/taobao_spider | 9cdaed1c7a67fc1f35ee2af2e18313cedf3b1e5e | [
"Unlicense"
] | 5 | 2019-09-17T03:55:56.000Z | 2020-12-18T03:34:03.000Z | # coding: utf-8
import traceback
from abc import ABCMeta, abstractmethod
from mall_spider.spiders.actions.executable import Executable
| 22.784314 | 70 | 0.623924 |
6b9e0d5209b7b62f3db7419587e03282debb98ce | 524 | py | Python | Praticas/pratica03/latitude_longitude.py | andrepinto42/Processamento-de-Linguagens | 98facba0d1c9ca751743b1c83dca7f441aa182e9 | [
"MIT"
] | 1 | 2022-03-18T21:39:47.000Z | 2022-03-18T21:39:47.000Z | Praticas/pratica03/latitude_longitude.py | andrepinto42/Processamento-de-Linguagens | 98facba0d1c9ca751743b1c83dca7f441aa182e9 | [
"MIT"
] | null | null | null | Praticas/pratica03/latitude_longitude.py | andrepinto42/Processamento-de-Linguagens | 98facba0d1c9ca751743b1c83dca7f441aa182e9 | [
"MIT"
] | null | null | null | import re
import sys
real_num = r'[+-]?\d+(?:\.\d+)?'
# Falta colocar as os paratenses para identificar o grupo correto
coord = rf'\(({real_num}),\s*({real_num})\)'
for line in sys.stdin:
line = re.sub(coord,r"<point lat='\1', lon='\2' />",line)
if (line):
print(line)
quit()
# Tambem d para ex... | 22.782609 | 71 | 0.574427 |
6b9f0ffcb6c75b079a5eb98125aa38eb4f61fd76 | 375 | py | Python | includes/prav_modules/test2.py | praveen868686/DAGAirflow-with-Python | 483fffc2e7f987e523ae3653a90869a67cdad886 | [
"MIT"
] | null | null | null | includes/prav_modules/test2.py | praveen868686/DAGAirflow-with-Python | 483fffc2e7f987e523ae3653a90869a67cdad886 | [
"MIT"
] | null | null | null | includes/prav_modules/test2.py | praveen868686/DAGAirflow-with-Python | 483fffc2e7f987e523ae3653a90869a67cdad886 | [
"MIT"
] | null | null | null | import pandas as pd
import numpy as np
see()
| 25 | 83 | 0.656 |
6ba002cacb0aea0efbea0d09c9f0563aeccf4db3 | 4,134 | py | Python | MLP/generate_args.py | AMNoureldin/COMP551-HW4 | 0c855372862300cc0454f144bb40b2e72ba93861 | [
"Apache-2.0"
] | 15 | 2021-03-18T03:00:15.000Z | 2022-02-28T04:42:54.000Z | MLP/generate_args.py | AMNoureldin/COMP551-HW4 | 0c855372862300cc0454f144bb40b2e72ba93861 | [
"Apache-2.0"
] | null | null | null | MLP/generate_args.py | AMNoureldin/COMP551-HW4 | 0c855372862300cc0454f144bb40b2e72ba93861 | [
"Apache-2.0"
] | 2 | 2021-11-05T15:50:20.000Z | 2022-01-16T11:48:27.000Z | # Copyright 2021 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, ... | 32.046512 | 94 | 0.618287 |
6ba2a99855aee76d9f42b28ebf924f529a089bcd | 854 | py | Python | data/datatable.py | sisiwei/impossible-food | 567e0811d5d88a83eae6dadf526bc048e7057121 | [
"MIT"
] | 1 | 2015-04-11T10:27:29.000Z | 2015-04-11T10:27:29.000Z | data/datatable.py | sisiwei/impossible-food | 567e0811d5d88a83eae6dadf526bc048e7057121 | [
"MIT"
] | null | null | null | data/datatable.py | sisiwei/impossible-food | 567e0811d5d88a83eae6dadf526bc048e7057121 | [
"MIT"
] | null | null | null | import json
import sys
from multiprocessing import Pool
DOMAIN = "TM"
if __name__ == "__main__":
pool = Pool(processes=3)
#datas = pool.map(read_file, (2011, 2009, 2008))
datas = []
for year in (2011, 2009, 2008):
datas.append(read_file(year))
data = reduce(lambda a, b: a+b, datas)
| 22.473684 | 54 | 0.539813 |
6ba35922a8da9226341017db55248451774263a5 | 38,712 | py | Python | EasyRegression.py | pankajchejara23/EasyRegression | 7f76d92c4a9d056a83bde6abc2fd6eb980602e44 | [
"MIT"
] | 1 | 2021-04-19T16:47:27.000Z | 2021-04-19T16:47:27.000Z | EasyRegression.py | pankajchejara23/EasyRegression | 7f76d92c4a9d056a83bde6abc2fd6eb980602e44 | [
"MIT"
] | null | null | null | EasyRegression.py | pankajchejara23/EasyRegression | 7f76d92c4a9d056a83bde6abc2fd6eb980602e44 | [
"MIT"
] | null | null | null |
import pandas as pd
import matplotlib.pyplot as plt
import librosa
import seaborn as sns
from sklearn.model_selection import train_test_split
import math
from sklearn.model_selection import LeaveOneGroupOut
from sklearn.metrics import mean_squared_error, mean_absolute_error
import traceback
import statistics
# Regress... | 41.139214 | 457 | 0.517462 |
6ba459622ba98919bfa10ab43ed05d7011713aea | 469 | py | Python | Moderate/Prime Numbers/main.py | AstrorEnales/CodeEval | eae0fb471d27d3a83d544ff4a4651ed1a2076930 | [
"MIT"
] | null | null | null | Moderate/Prime Numbers/main.py | AstrorEnales/CodeEval | eae0fb471d27d3a83d544ff4a4651ed1a2076930 | [
"MIT"
] | null | null | null | Moderate/Prime Numbers/main.py | AstrorEnales/CodeEval | eae0fb471d27d3a83d544ff4a4651ed1a2076930 | [
"MIT"
] | null | null | null | import sys
lines = open(sys.argv[1], 'r')
for line in lines:
line = line.replace('\n', '').replace('\r', '')
if len(line) > 0:
n = int(line)
primes = set([2])
num = 3
while num < n:
if all(num % i != 0 for i in primes):
primes = set(list(pri... | 26.055556 | 52 | 0.45629 |
6ba4e572e52707590a52608ce4cc12b513909627 | 2,117 | py | Python | gemtown/users/serializers.py | doramong0926/gemtown | 2c39284e3c68f0cc11994bed0ee2abaad0ea06b6 | [
"MIT"
] | null | null | null | gemtown/users/serializers.py | doramong0926/gemtown | 2c39284e3c68f0cc11994bed0ee2abaad0ea06b6 | [
"MIT"
] | 5 | 2020-09-04T20:13:39.000Z | 2022-02-17T22:03:33.000Z | gemtown/users/serializers.py | doramong0926/gemtown | 2c39284e3c68f0cc11994bed0ee2abaad0ea06b6 | [
"MIT"
] | null | null | null | from rest_framework import serializers
from gemtown.modelphotos import models as modelphoto_models
from gemtown.modelers import models as modeler_models
from gemtown.musicians import models as musician_models
from . import models
import time
| 25.817073 | 60 | 0.561171 |
6ba6fc313f5304844d20f830ba30be7f1409ef35 | 8,294 | py | Python | neaps-api/neaps_lib/delivery_time_test.py | HotelsDotCom/neaps | 4222016d60d27a168f4fb5569d696ec1731f8698 | [
"Apache-2.0"
] | 6 | 2018-01-18T11:31:41.000Z | 2019-11-11T19:56:06.000Z | neaps-api/neaps_lib/delivery_time_test.py | HotelsDotCom/neaps | 4222016d60d27a168f4fb5569d696ec1731f8698 | [
"Apache-2.0"
] | null | null | null | neaps-api/neaps_lib/delivery_time_test.py | HotelsDotCom/neaps | 4222016d60d27a168f4fb5569d696ec1731f8698 | [
"Apache-2.0"
] | null | null | null | #
# Copyright 2018 Expedia Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writin... | 22.176471 | 74 | 0.437545 |
6ba78991985070dc29bb6e09cbc030857e571e30 | 6,702 | py | Python | alexa_skills/cis_diagnosis.py | paramraghavan/sls-py-alexa-color-picker | da4752442dd4ead19832930103adb9d81cfc163a | [
"MIT"
] | null | null | null | alexa_skills/cis_diagnosis.py | paramraghavan/sls-py-alexa-color-picker | da4752442dd4ead19832930103adb9d81cfc163a | [
"MIT"
] | null | null | null | alexa_skills/cis_diagnosis.py | paramraghavan/sls-py-alexa-color-picker | da4752442dd4ead19832930103adb9d81cfc163a | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
import logging
from ask_sdk_core.skill_builder import SkillBuilder
from ask_sdk_core.utils import is_request_type, is_intent_name
from ask_sdk_core.handler_input import HandlerInput
from ask_sdk_model import Response
from ask_sdk_model.ui import SimpleCard
import os
from alexa_skills import aw... | 32.852941 | 110 | 0.716801 |
6ba87f59c7f750ad17a00d25ed32add4e2688d55 | 9,360 | py | Python | layouts/params.py | JAOP1/pyristicLab | fb3f0eb88af5b964bf91875e20fb3c42b04e257d | [
"MIT"
] | null | null | null | layouts/params.py | JAOP1/pyristicLab | fb3f0eb88af5b964bf91875e20fb3c42b04e257d | [
"MIT"
] | null | null | null | layouts/params.py | JAOP1/pyristicLab | fb3f0eb88af5b964bf91875e20fb3c42b04e257d | [
"MIT"
] | null | null | null |
"""
---------------------------------------------------------------------
Continuos Optimization Problems
---------------------------------------------------------------------
"""
"""
---------------------------------------------------------------------
GA configuration
------... | 25.57377 | 72 | 0.290278 |
6ba8948db01a555810296ad83a1297622916c86e | 988 | py | Python | armautils_cli/smdimerge.py | KoffeinFlummi/ArmaUtils | 2f1fdc8fb561fb54077f3c328d7a788e75c78dad | [
"MIT"
] | 1 | 2015-02-19T17:31:17.000Z | 2015-02-19T17:31:17.000Z | armautils_cli/smdimerge.py | KoffeinFlummi/ArmaUtils | 2f1fdc8fb561fb54077f3c328d7a788e75c78dad | [
"MIT"
] | null | null | null | armautils_cli/smdimerge.py | KoffeinFlummi/ArmaUtils | 2f1fdc8fb561fb54077f3c328d7a788e75c78dad | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
import numpy as np
from PIL import Image
| 23.52381 | 72 | 0.601215 |
6ba92406854249e5b9f75ef7a1b017bf6c889193 | 932 | py | Python | logstash-pruner/prune_logs.py | wuvt/containers | 729469c4e878027da589afb9b37d61de104a5713 | [
"0BSD"
] | 1 | 2017-09-16T04:54:33.000Z | 2017-09-16T04:54:33.000Z | logstash-pruner/prune_logs.py | wuvt/containers | 729469c4e878027da589afb9b37d61de104a5713 | [
"0BSD"
] | null | null | null | logstash-pruner/prune_logs.py | wuvt/containers | 729469c4e878027da589afb9b37d61de104a5713 | [
"0BSD"
] | null | null | null | #!/usr/bin/python3
import datetime
import os
import requests
import sys
if sys.version_info[0] >= 3:
import urllib.parse as urllib
else:
import urllib
endpoint = os.environ['ELASTICSEARCH_URL']
username = os.environ['ELASTICSEARCH_USERNAME']
password = os.environ['ELASTICSEARCH_PASSWORD']
prune_start = datet... | 29.125 | 70 | 0.604077 |
6baa9c56ec82f3de3e848ccc5b1bc7bfad503442 | 7,001 | py | Python | detect_motor_test3.py | binghaohuang1/object-detective-visual-tracking | e61680a771dc13a006113d96965e59ff1bc3ce6d | [
"MIT"
] | null | null | null | detect_motor_test3.py | binghaohuang1/object-detective-visual-tracking | e61680a771dc13a006113d96965e59ff1bc3ce6d | [
"MIT"
] | null | null | null | detect_motor_test3.py | binghaohuang1/object-detective-visual-tracking | e61680a771dc13a006113d96965e59ff1bc3ce6d | [
"MIT"
] | null | null | null | #!/usr/bin/env python
#!coding=utf-8
import rospy
import numpy as np
import PIL.Image as pilimage
from sensor_msgs.msg import CompressedImage
from sensor_msgs.msg import Image
from std_msgs.msg import Float64
from cv_bridge import CvBridge, CvBridgeError
import cv2
import time
from yolo import YOLO
from sensor_msgs.ms... | 32.868545 | 114 | 0.571347 |
6baa9dca059c9918a2a7be0aeb44d2c0167aca74 | 1,841 | py | Python | venv/lib/python3.8/site-packages/ansible/utils/collection_loader/_collection_meta.py | saeedya/docker-ansible | 6fb0cfc6bc4a5925b21380952a5a4502ec02119a | [
"Apache-2.0"
] | null | null | null | venv/lib/python3.8/site-packages/ansible/utils/collection_loader/_collection_meta.py | saeedya/docker-ansible | 6fb0cfc6bc4a5925b21380952a5a4502ec02119a | [
"Apache-2.0"
] | null | null | null | venv/lib/python3.8/site-packages/ansible/utils/collection_loader/_collection_meta.py | saeedya/docker-ansible | 6fb0cfc6bc4a5925b21380952a5a4502ec02119a | [
"Apache-2.0"
] | null | null | null | # (c) 2019 Ansible Project
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
# CAUTION: There are two implementations of the collection loader.
# They must be kept functionally identical, although their implementations may differ.
#
# 1) The controller implementation... | 48.447368 | 125 | 0.76969 |
6baba2b5a50d24a7e67ce4b5e3c206e3e6b416ad | 7,184 | py | Python | git_pull_all.py | searKing/git-pull-all | b77a1b0461cd00a5f3ccd48253a12674557302b6 | [
"MIT"
] | null | null | null | git_pull_all.py | searKing/git-pull-all | b77a1b0461cd00a5f3ccd48253a12674557302b6 | [
"MIT"
] | null | null | null | git_pull_all.py | searKing/git-pull-all | b77a1b0461cd00a5f3ccd48253a12674557302b6 | [
"MIT"
] | null | null | null | #!/usr/bin/python
import git
from git import *
import threading
import os
import sys
import getopt
from enum import Enum
# is_git_dir returns if current directory has .git/
if __name__ == "__main__":
sys.exit(main())
| 39.256831 | 121 | 0.579065 |
6bac63dfef6fa2d50e75637d8cb0e279922534d7 | 1,943 | py | Python | 03-dearsanta/dateconvert.py | hugovk/NaNoGenMo-2016 | e71b333173b221066f56adcdea4fe8cfdfd4e7c7 | [
"FTL"
] | null | null | null | 03-dearsanta/dateconvert.py | hugovk/NaNoGenMo-2016 | e71b333173b221066f56adcdea4fe8cfdfd4e7c7 | [
"FTL"
] | null | null | null | 03-dearsanta/dateconvert.py | hugovk/NaNoGenMo-2016 | e71b333173b221066f56adcdea4fe8cfdfd4e7c7 | [
"FTL"
] | null | null | null | #!/usr/bin/env python3
"""
Take a timestamp like:
25/11/2016 23:05:03
Convert it to:
25 November 2016, 13:05 PST
25 November 2016, 16:05 EST
25 November 2016, 21:05 GMT
25 November 2016, 21:05 UTC
25 November 2016, 23:05 EET
26 November 2016, 02:35 IST
26 November 2016, 05:05 CST
26 November 2016, 06:05 JST
26 Novembe... | 25.906667 | 74 | 0.662378 |
6bad66e09e43cf21ce9d5331e922f80d18955982 | 799 | py | Python | priv_tube/database/repositories/system_flags.py | ActionCactus/prive_tube | d6d53b87e1a91248e32532a86b23f2d2f3196c58 | [
"MIT"
] | null | null | null | priv_tube/database/repositories/system_flags.py | ActionCactus/prive_tube | d6d53b87e1a91248e32532a86b23f2d2f3196c58 | [
"MIT"
] | null | null | null | priv_tube/database/repositories/system_flags.py | ActionCactus/prive_tube | d6d53b87e1a91248e32532a86b23f2d2f3196c58 | [
"MIT"
] | null | null | null | from priv_tube.database.models.system_flags import SystemFlags as Model
from priv_tube.database import db
| 29.592593 | 106 | 0.693367 |
6baec59b9ec0b23b54791668f80cdb75f7f78fe2 | 2,899 | py | Python | borisat/models/rd/unnested.py | CircleOnCircles/borisat | 4f170ee1a0b11f06b1c3e99f42823061d7e0028e | [
"MIT"
] | null | null | null | borisat/models/rd/unnested.py | CircleOnCircles/borisat | 4f170ee1a0b11f06b1c3e99f42823061d7e0028e | [
"MIT"
] | 1 | 2020-10-10T08:18:29.000Z | 2020-10-10T08:18:29.000Z | borisat/models/rd/unnested.py | CircleOnCircles/borisat | 4f170ee1a0b11f06b1c3e99f42823061d7e0028e | [
"MIT"
] | null | null | null | """
{
'vNID': {
'anyType': [
'0105558096348'
]
},
'vtin': None,
'vtitleName': {
'anyType': [
''
]
},
'vName': {
'anyType': [
' '
]
},
'vSurname': {
'anyType': [
'-'... | 19.993103 | 137 | 0.397378 |
6bb2d695f2072ac119b9190737ac6f9ea82daea3 | 7,969 | py | Python | Kernelized-Rank-Learning-master/dataset.py | zsyasd/drug-response-test | 65bff3423a0cc972dd4664b7f547767c1f10f635 | [
"MIT"
] | 1 | 2021-01-22T04:06:57.000Z | 2021-01-22T04:06:57.000Z | Kernelized-Rank-Learning-master/dataset.py | zsyasd/drug-response-test | 65bff3423a0cc972dd4664b7f547767c1f10f635 | [
"MIT"
] | null | null | null | Kernelized-Rank-Learning-master/dataset.py | zsyasd/drug-response-test | 65bff3423a0cc972dd4664b7f547767c1f10f635 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
import os
import sys
import urllib2
import zipfile
import numpy as np
import pandas as pd
from openpyxl import load_workbook
from misc import intersect_index
if __name__ == '__main__':
main()
| 40.866667 | 136 | 0.677626 |
6bb3065e877b04d04efa39f8cb2dec584e2b65df | 3,696 | py | Python | app/utils/logger.py | janaSunrise/ZeroCOM | 7197684ce708f080fe215b0a6e57c12836e4c0ab | [
"Apache-2.0"
] | 6 | 2021-03-27T08:58:04.000Z | 2021-05-23T17:07:09.000Z | app/utils/logger.py | janaSunrise/ZeroCOM | 7197684ce708f080fe215b0a6e57c12836e4c0ab | [
"Apache-2.0"
] | 2 | 2021-05-30T08:06:53.000Z | 2021-06-02T17:02:06.000Z | app/utils/logger.py | janaSunrise/ZeroCOM | 7197684ce708f080fe215b0a6e57c12836e4c0ab | [
"Apache-2.0"
] | null | null | null | # -- Imports --
from datetime import datetime
from colorama import Back
from rich.console import Console
from .colors import get_bright_color, get_color
# -- Mappings --
log_color_mapping = {
"error": get_bright_color("RED"),
"warning": get_bright_color("YELLOW"),
"message": get_color("CYAN"),
"succe... | 29.806452 | 102 | 0.619589 |
6bb44465b2c1e375804bcf23757d647344be8b01 | 1,506 | py | Python | modasci/data_connector.py | ArashLab/MoDaSci | 3f173a9ca686edf00a2f143814b603d4e3be9de2 | [
"MIT"
] | null | null | null | modasci/data_connector.py | ArashLab/MoDaSci | 3f173a9ca686edf00a2f143814b603d4e3be9de2 | [
"MIT"
] | null | null | null | modasci/data_connector.py | ArashLab/MoDaSci | 3f173a9ca686edf00a2f143814b603d4e3be9de2 | [
"MIT"
] | 1 | 2021-09-11T13:59:13.000Z | 2021-09-11T13:59:13.000Z | from munch import Munch
from .utils import import_class
from .serialization import YAMLMixin
from .micro_task import import_class
| 40.702703 | 117 | 0.717131 |
6bb46fd7a793cdd2673a191ac0ee65bd9e96f260 | 682 | py | Python | gallery/migrations/0011_auto_20161126_1821.py | danielsinaga1/djangonewsfix | 04b84240daabb840c1e715fbade8ae15b3b0f22c | [
"BSD-3-Clause"
] | 19 | 2018-01-28T14:35:40.000Z | 2020-12-04T03:04:02.000Z | gallery/migrations/0011_auto_20161126_1821.py | danielsinaga1/djangonewsfix | 04b84240daabb840c1e715fbade8ae15b3b0f22c | [
"BSD-3-Clause"
] | 8 | 2018-06-02T14:28:28.000Z | 2021-08-06T10:22:37.000Z | gallery/migrations/0011_auto_20161126_1821.py | danielsinaga1/djangonewsfix | 04b84240daabb840c1e715fbade8ae15b3b0f22c | [
"BSD-3-Clause"
] | 21 | 2018-02-25T14:07:48.000Z | 2020-05-28T23:10:52.000Z | # -*- coding: utf-8 -*-
# Generated by Django 1.9.6 on 2016-11-26 16:21
from __future__ import unicode_literals
from django.db import migrations, models
| 26.230769 | 84 | 0.612903 |
6bb5785201bd7a9127918db4d2b10a17a6eb105d | 1,213 | py | Python | mechanic/drive_navigate_boost/drive_navigate_boost.py | oxrock/DisasterBot | 36260e9ef8730edbae018ba87aa19aaad72c8814 | [
"MIT"
] | 11 | 2018-11-18T09:30:39.000Z | 2021-08-24T18:47:48.000Z | mechanic/drive_navigate_boost/drive_navigate_boost.py | oxrock/DisasterBot | 36260e9ef8730edbae018ba87aa19aaad72c8814 | [
"MIT"
] | 6 | 2020-01-31T11:37:56.000Z | 2020-05-01T19:13:54.000Z | mechanic/drive_navigate_boost/drive_navigate_boost.py | oxrock/DisasterBot | 36260e9ef8730edbae018ba87aa19aaad72c8814 | [
"MIT"
] | 7 | 2018-11-17T20:02:19.000Z | 2020-05-01T15:07:13.000Z | from rlbot.agents.base_agent import SimpleControllerState
from mechanic.base_mechanic import BaseMechanic
from mechanic.drive_arrive_in_time import DriveArriveInTime
from skeleton.util.structure import Player
from util.linear_algebra import norm
from util.path_finder import find_fastest_path, first_target, optional_b... | 40.433333 | 101 | 0.73042 |
6bb5a3ae1541a6323233d61a349487d06b8c5714 | 1,907 | py | Python | Simplex_Files/Dual_Problem.py | c-randall/Primal-Simplex-Method | 620d7598691ed9717d2d18706c44e462f75e85c5 | [
"BSD-3-Clause"
] | 1 | 2021-12-04T12:18:17.000Z | 2021-12-04T12:18:17.000Z | Simplex_Files/Dual_Problem.py | c-randall/Primal-Simplex-Method | 620d7598691ed9717d2d18706c44e462f75e85c5 | [
"BSD-3-Clause"
] | null | null | null | Simplex_Files/Dual_Problem.py | c-randall/Primal-Simplex-Method | 620d7598691ed9717d2d18706c44e462f75e85c5 | [
"BSD-3-Clause"
] | 2 | 2020-05-30T16:38:37.000Z | 2022-01-22T19:50:42.000Z | """
Created on Wed Apr 3 13:07:18 2019
Author:
Corey R. Randall
Summary:
If the user wishes to solve the Dual Problem over the Primal one, this
function provides support to appropriately convert the problem into its
alternate form.
"""
""" Import needed modules """
"----------------... | 31.262295 | 80 | 0.529628 |
6bb5e552c9b4052b2b3d89711be844490a830473 | 1,764 | py | Python | sgcc-client/api/my_api.py | zhanwei33/baai-federated-learning | 838507f2344139e66385e1ef475a148fdeaf5c62 | [
"Apache-2.0"
] | 26 | 2020-11-30T09:42:17.000Z | 2022-03-05T02:20:45.000Z | sgcc-client/api/my_api.py | AIOpenData/baai-federated-learning-helmet-baseline | 8d9a1eded43a945f790d415f3ee37cda78b73c52 | [
"Apache-2.0"
] | null | null | null | sgcc-client/api/my_api.py | AIOpenData/baai-federated-learning-helmet-baseline | 8d9a1eded43a945f790d415f3ee37cda78b73c52 | [
"Apache-2.0"
] | 6 | 2020-12-01T13:01:15.000Z | 2021-11-16T10:51:39.000Z | from api import my_api
from service.federated.client import Client
from utils.common_utils import Common
from flask import request
| 36.75 | 93 | 0.781746 |
6bba5f186b30e976cabf28a647d3b87bff42e9f0 | 5,954 | py | Python | backend/tracim_backend/tests/library/test_application_api.py | lezardrouge/tracim | 713ff6066767554333e7e0b1de608ec1a7e4229c | [
"MIT"
] | null | null | null | backend/tracim_backend/tests/library/test_application_api.py | lezardrouge/tracim | 713ff6066767554333e7e0b1de608ec1a7e4229c | [
"MIT"
] | null | null | null | backend/tracim_backend/tests/library/test_application_api.py | lezardrouge/tracim | 713ff6066767554333e7e0b1de608ec1a7e4229c | [
"MIT"
] | null | null | null | from mock import Mock
from tracim_backend.app_models.applications import Application
from tracim_backend.app_models.contents import content_status_list
from tracim_backend.app_models.workspace_menu_entries import all_content_menu_entry
from tracim_backend.app_models.workspace_menu_entries import dashboard_menu_entry
f... | 41.062069 | 100 | 0.658885 |
6bbbb5f359c8e40427bcd1ee484f14b132a99a62 | 2,593 | py | Python | gallery/m_cardloader.py | kengoon/KvGallery | 4d946fa06479636411e027bfdebbb15c58c176cf | [
"MIT"
] | 2 | 2021-05-28T13:37:07.000Z | 2021-06-20T06:47:20.000Z | gallery/m_cardloader.py | kengoon/KvGallery | 4d946fa06479636411e027bfdebbb15c58c176cf | [
"MIT"
] | null | null | null | gallery/m_cardloader.py | kengoon/KvGallery | 4d946fa06479636411e027bfdebbb15c58c176cf | [
"MIT"
] | null | null | null | from kivy.event import EventDispatcher
from kivy.metrics import dp
from kivy.properties import ListProperty, StringProperty
from kivymd.uix.card import MDCard
from kivy.lang import Builder
__all__ = "M_CardLoader"
Builder.load_string(
"""
# kv_start
<M_CardLoader>:
md_bg_color: 0, 0, 0, 0
radius: [dp(10),... | 27.585106 | 73 | 0.529117 |
6bbc545ddb8b337163afbee7b7359f2bf1545ca8 | 763 | py | Python | setup.py | OpenTAI/pre-commit-hooks | e123691fa26ff26d1a5f3513ee419bec6eef02ab | [
"MIT"
] | null | null | null | setup.py | OpenTAI/pre-commit-hooks | e123691fa26ff26d1a5f3513ee419bec6eef02ab | [
"MIT"
] | 1 | 2022-02-16T10:19:25.000Z | 2022-02-16T10:19:26.000Z | setup.py | OpenTAI/pre-commit-hooks | e123691fa26ff26d1a5f3513ee419bec6eef02ab | [
"MIT"
] | null | null | null | from setuptools import find_packages, setup # type: ignore
setup(
name='pre_commit_hooks',
version='0.1.0',
description='A pre-commit hook for OpenTAI projects',
long_description=readme(),
long_description_content_type='text/markdown',
url='https://github.com/OpenTAI/pre-commit-hooks',
a... | 26.310345 | 68 | 0.647444 |
6bbdd01acf71fc3e4336063b1dbd03093b010571 | 6,037 | py | Python | baselines/ppo2/defaults.py | jinala/RLbaselines | 3594c1edae49e1bb997057912cfb9b07531d41f4 | [
"MIT"
] | null | null | null | baselines/ppo2/defaults.py | jinala/RLbaselines | 3594c1edae49e1bb997057912cfb9b07531d41f4 | [
"MIT"
] | null | null | null | baselines/ppo2/defaults.py | jinala/RLbaselines | 3594c1edae49e1bb997057912cfb9b07531d41f4 | [
"MIT"
] | 1 | 2021-04-27T17:21:28.000Z | 2021-04-27T17:21:28.000Z | import random
import numpy as np
'''
# best params for car retrieval bench
def car_retrieval_train():
lr = 0.002
print("lr: ", lr)
return dict(
# horizon = rand_int_linspace(32, 500),
nminibatches = 128,
ent_coef = 0.01,
noptepochs = 33,
cliprange = 0.1,
gam... | 27.193694 | 90 | 0.525427 |
6bc269d33439bd018df37c790bc02091c42db872 | 3,339 | py | Python | pysnmp-with-texts/DLINK-3100-JUMBOFRAMES-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/DLINK-3100-JUMBOFRAMES-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/DLINK-3100-JUMBOFRAMES-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 DLINK-3100-JUMBOFRAMES-MIB (http://snmplabs.com/pysmi)
# ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/DLINK-3100-JUMBOFRAMES-MIB
# Produced by pysmi-0.3.4 at Wed May 1 12:48:33 2019
# On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4
# Using Python version ... | 107.709677 | 477 | 0.790356 |
6bc370acc905253ff8d26ccf15fd3f3f085e6141 | 110 | py | Python | contrib/pyln-spec/bolt7/pyln/spec/bolt7/gen_version.py | rsouvik/bitblue | a205fb77695a26512c7eb9ba33a7379f246ec357 | [
"MIT"
] | 4 | 2019-12-08T21:02:32.000Z | 2020-08-06T12:14:37.000Z | contrib/pyln-spec/bolt7/pyln/spec/bolt7/gen_version.py | rsouvik/bitblue | a205fb77695a26512c7eb9ba33a7379f246ec357 | [
"MIT"
] | 5 | 2021-02-20T02:41:55.000Z | 2021-06-01T20:04:08.000Z | contrib/pyln-spec/bolt7/pyln/spec/bolt7/gen_version.py | rsouvik/bitblue | a205fb77695a26512c7eb9ba33a7379f246ec357 | [
"MIT"
] | 7 | 2019-10-07T23:53:49.000Z | 2021-11-23T18:26:30.000Z | __base_version__ = "1.0"
__post_version__ = "137"
__gitversion__ = "9e8e29af9b9a922eb114b2c716205d0772946e56"
| 27.5 | 59 | 0.827273 |
6bc548fb933264d47e42737add228df3e1a66805 | 3,509 | py | Python | main.py | lhs9842/KNUTNoticeBot | cfc83f2abc079a660177d00da1eab288cad021b4 | [
"MIT"
] | 1 | 2022-02-23T01:54:07.000Z | 2022-02-23T01:54:07.000Z | main.py | lhs9842/KNUTNoticeBot | cfc83f2abc079a660177d00da1eab288cad021b4 | [
"MIT"
] | null | null | null | main.py | lhs9842/KNUTNoticeBot | cfc83f2abc079a660177d00da1eab288cad021b4 | [
"MIT"
] | 1 | 2022-02-23T07:17:31.000Z | 2022-02-23T07:17:31.000Z | import setting
import requests
import threading
import time
import sqlite3
from bs4 import BeautifulSoup
from urllib import parse
public_board = [["BBSMSTR_000000000059", ""], ["BBSMSTR_000000000060", ""], ["BBSMSTR_000000000055", ""]] # [boardId, ]
db_conn = sqlite3.connect("NoticeBot.db", check_same_thread=False)
... | 44.987179 | 205 | 0.596751 |
6bc75bfe6f3b314f3347fa4156e55b1ddf54d5f2 | 785 | py | Python | migrate_dns/destructo.py | jlin/inventory | c098c98e570c3bf9fadfd811eb75e1213f6ea428 | [
"BSD-3-Clause"
] | 22 | 2015-01-16T01:36:32.000Z | 2020-06-08T00:46:18.000Z | migrate_dns/destructo.py | jlin/inventory | c098c98e570c3bf9fadfd811eb75e1213f6ea428 | [
"BSD-3-Clause"
] | 9 | 2019-03-15T11:39:32.000Z | 2019-04-30T00:59:50.000Z | migrate_dns/destructo.py | jlin/inventory | c098c98e570c3bf9fadfd811eb75e1213f6ea428 | [
"BSD-3-Clause"
] | 13 | 2015-01-13T20:56:22.000Z | 2022-02-23T06:01:17.000Z | from mozdns.address_record.models import AddressRecord
from mozdns.cname.models import CNAME
from mozdns.domain.models import Domain
from mozdns.mx.models import MX
from mozdns.nameserver.models import Nameserver
from mozdns.ptr.models import PTR
from mozdns.soa.models import SOA
from mozdns.srv.models import SRV
from ... | 30.192308 | 54 | 0.743949 |
6bc7b78982d279f5295d2beb48fb63642b3d9439 | 255 | py | Python | mundo-1/condicoes/aumentos_multiplos.py | Murilloalves/estudos-python | 804a8f646efd86840a3183b65f775168ebb6cf37 | [
"MIT"
] | null | null | null | mundo-1/condicoes/aumentos_multiplos.py | Murilloalves/estudos-python | 804a8f646efd86840a3183b65f775168ebb6cf37 | [
"MIT"
] | null | null | null | mundo-1/condicoes/aumentos_multiplos.py | Murilloalves/estudos-python | 804a8f646efd86840a3183b65f775168ebb6cf37 | [
"MIT"
] | null | null | null | salario = float(input('Qual salrio do funcionrio? R$'))
if salario <= 1250:
aumento = salario + (salario*15/100)
else:
aumento = salario + (salario * 10 / 100)
print('Quem ganhava R${} passa a ganhar R${:.2f} agora.'.format(salario, aumento))
| 36.428571 | 82 | 0.662745 |
6bc804671bae5a9914e56977a2eb91970281e7fd | 319 | py | Python | mysite/myapp/migrations/0003_remove_input_input2.py | Omnibyte27/Web-Collab | 8f18b2f62f5497669a0f95cfbcfb128738db8c9e | [
"MIT"
] | 1 | 2019-11-09T00:17:00.000Z | 2019-11-09T00:17:00.000Z | mysite/myapp/migrations/0003_remove_input_input2.py | Omnibyte27/Web-Collab | 8f18b2f62f5497669a0f95cfbcfb128738db8c9e | [
"MIT"
] | 7 | 2020-06-06T00:19:39.000Z | 2022-02-10T14:08:37.000Z | mysite/myapp/migrations/0003_remove_input_input2.py | Omnibyte27/Web-Collab | 8f18b2f62f5497669a0f95cfbcfb128738db8c9e | [
"MIT"
] | 1 | 2019-11-10T23:12:42.000Z | 2019-11-10T23:12:42.000Z | # Generated by Django 2.2.5 on 2019-09-29 18:57
from django.db import migrations
| 17.722222 | 47 | 0.579937 |
6bc8119faa11d3034406f5e04fb3d2f0570e36ee | 127 | py | Python | django_frontend_presets/presets/__init__.py | mikemenard/django-frontend-presets | 0d1837415282ae43488b3e6e66889bc94f1a45b4 | [
"BSD-3-Clause"
] | null | null | null | django_frontend_presets/presets/__init__.py | mikemenard/django-frontend-presets | 0d1837415282ae43488b3e6e66889bc94f1a45b4 | [
"BSD-3-Clause"
] | null | null | null | django_frontend_presets/presets/__init__.py | mikemenard/django-frontend-presets | 0d1837415282ae43488b3e6e66889bc94f1a45b4 | [
"BSD-3-Clause"
] | null | null | null | from .Bootstrap import Bootstrap
from .Init import Init
from .React import React
from .Reset import Reset
from .Vue import Vue
| 21.166667 | 32 | 0.80315 |
6bc83f48988080bc745090b0af2be2b40f9b6a5e | 2,041 | py | Python | inference_methods_local.py | Yaakoubi/Struct-CKN | fa007fa71310866584bdf2e5b038e6663b94e965 | [
"MIT"
] | 1 | 2021-05-30T13:42:56.000Z | 2021-05-30T13:42:56.000Z | inference_methods_local.py | Yaakoubi/Struct-CKN | fa007fa71310866584bdf2e5b038e6663b94e965 | [
"MIT"
] | null | null | null | inference_methods_local.py | Yaakoubi/Struct-CKN | fa007fa71310866584bdf2e5b038e6663b94e965 | [
"MIT"
] | 2 | 2022-03-16T22:00:30.000Z | 2022-03-29T20:08:57.000Z | import ad3
import numpy as np
from pystruct.inference.common import _validate_params
| 39.25 | 92 | 0.632533 |
6bc877d2ff907a625b44f72caf624fa66d922ec9 | 839 | py | Python | examples/dhc/deduplication_approximated_example.py | fruttasecca/hay_checker | 2bbf4e8e90e0abc590dd74080fb6e4f445056354 | [
"MIT"
] | 2 | 2019-05-22T08:24:38.000Z | 2020-12-04T13:36:30.000Z | examples/dhc/deduplication_approximated_example.py | fruttasecca/hay_checker | 2bbf4e8e90e0abc590dd74080fb6e4f445056354 | [
"MIT"
] | null | null | null | examples/dhc/deduplication_approximated_example.py | fruttasecca/hay_checker | 2bbf4e8e90e0abc590dd74080fb6e4f445056354 | [
"MIT"
] | 3 | 2018-09-15T13:40:40.000Z | 2021-06-29T23:31:18.000Z | #!/usr/bin/python3
from pyspark.sql import SparkSession
from haychecker.dhc.metrics import deduplication_approximated
spark = SparkSession.builder.appName("Deduplication_approximated_example").getOrCreate()
df = spark.read.format("csv").option("header", "true").load("examples/resources/employees.csv")
df.show()
r1... | 32.269231 | 97 | 0.747318 |
6bcafe8a760a06ba575713e54df859c88a35ea32 | 2,671 | py | Python | test.py | Tang-Jie-Chang/keras-maskrcnn | 2ad1380005265c4e3158858ae030b0039fd16eec | [
"Apache-2.0"
] | null | null | null | test.py | Tang-Jie-Chang/keras-maskrcnn | 2ad1380005265c4e3158858ae030b0039fd16eec | [
"Apache-2.0"
] | null | null | null | test.py | Tang-Jie-Chang/keras-maskrcnn | 2ad1380005265c4e3158858ae030b0039fd16eec | [
"Apache-2.0"
] | null | null | null | # import keras
import keras
# import keras_retinanet
from keras_maskrcnn import models
from keras_maskrcnn.utils.visualization import draw_mask
from keras_retinanet.utils.visualization import draw_box, draw_caption, draw_annotations
from keras_retinanet.utils.image import read_image_bgr, preprocess_image, resiz... | 34.688312 | 167 | 0.681767 |
6bcb30fd29a6ef624f4b1ad7d00a496c9b08cdb4 | 6,611 | py | Python | leo/modes/lotos.py | ATikhonov2/leo-editor | 225aac990a9b2804aaa9dea29574d6e072e30474 | [
"MIT"
] | 1,550 | 2015-01-14T16:30:37.000Z | 2022-03-31T08:55:58.000Z | leo/modes/lotos.py | ATikhonov2/leo-editor | 225aac990a9b2804aaa9dea29574d6e072e30474 | [
"MIT"
] | 2,009 | 2015-01-13T16:28:52.000Z | 2022-03-31T18:21:48.000Z | leo/modes/lotos.py | ATikhonov2/leo-editor | 225aac990a9b2804aaa9dea29574d6e072e30474 | [
"MIT"
] | 200 | 2015-01-05T15:07:41.000Z | 2022-03-07T17:05:01.000Z | # Leo colorizer control file for lotos mode.
# This file is in the public domain.
# Properties for lotos mode.
properties = {
"commentEnd": "*)",
"commentStart": "(*",
"indentNextLines": "\\s*(let|library|process|specification|type|>>).*|\\s*(\\(|\\[\\]|\\[>|\\|\\||\\|\\|\\||\\|\\[.*\\]\\||\\[.*\\]\... | 29.513393 | 149 | 0.570867 |
6bce53c9abe42e1145ff3c9feca2ddc25c7666a1 | 275 | py | Python | src/ProblemSolving/DiagonalDifference.py | Feng-Zhao/hackerrankPy | fc04f0a11cf543ad3697860eca774103593abcd5 | [
"Apache-2.0"
] | null | null | null | src/ProblemSolving/DiagonalDifference.py | Feng-Zhao/hackerrankPy | fc04f0a11cf543ad3697860eca774103593abcd5 | [
"Apache-2.0"
] | null | null | null | src/ProblemSolving/DiagonalDifference.py | Feng-Zhao/hackerrankPy | fc04f0a11cf543ad3697860eca774103593abcd5 | [
"Apache-2.0"
] | null | null | null |
if __name__ == '__main__':
arr = [[11, 2, 4],[4, 5, 6],[10, 8, -12]]
print(diagonalDifference(arr))
| 21.153846 | 45 | 0.490909 |
6bcf37239c800dc8e2d66410da87a160446a390a | 296 | py | Python | robot/Cumulus/resources/BaseObjects.py | SFDO-Alliances/NPSP | 3711a3cf8e3124bc2d7e61644d6abecb4042004e | [
"BSD-3-Clause"
] | 413 | 2015-01-02T09:53:04.000Z | 2019-12-05T15:31:25.000Z | robot/Cumulus/resources/BaseObjects.py | SFDO-Alliances/NPSP | 3711a3cf8e3124bc2d7e61644d6abecb4042004e | [
"BSD-3-Clause"
] | 2,471 | 2015-01-02T03:33:55.000Z | 2019-12-13T17:55:10.000Z | robot/Cumulus/resources/BaseObjects.py | SFDO-Alliances/NPSP | 3711a3cf8e3124bc2d7e61644d6abecb4042004e | [
"BSD-3-Clause"
] | 296 | 2015-01-06T13:03:33.000Z | 2019-12-11T14:19:31.000Z | from robot.libraries.BuiltIn import BuiltIn
| 24.666667 | 88 | 0.716216 |
6bd0d6670874846404621cb14ddcf0728b11d685 | 1,395 | py | Python | balltze_simulation/balltze_pybullet/balltze/balltze.py | Kotochleb/Balltze | 55b15cb57d20f7f212293bf838e1d6cf874bb4c2 | [
"MIT"
] | 1 | 2021-09-04T03:59:01.000Z | 2021-09-04T03:59:01.000Z | balltze_simulation/balltze_pybullet/balltze/balltze.py | Kotochleb/Balltze | 55b15cb57d20f7f212293bf838e1d6cf874bb4c2 | [
"MIT"
] | null | null | null | balltze_simulation/balltze_pybullet/balltze/balltze.py | Kotochleb/Balltze | 55b15cb57d20f7f212293bf838e1d6cf874bb4c2 | [
"MIT"
] | null | null | null | import pybullet as p
import time
import numpy as np
import pybullet_data
from balltze_description import Balltze, BalltzeKinematics
import math
if __name__ == '__main__':
time_step = 1./240.
physicsClient = p.connect(p.GUI)
p.setAdditionalSearchPath(pybullet_data.getDataPath())
p.setGravity(0,0,-9.81)
... | 32.44186 | 154 | 0.597133 |
6bd20797291e733d3485db7e9a7d16d42673718a | 8,850 | py | Python | urbit_sniffer.py | laanwj/urbit-tools | b3823d50d5ab84c0852593e3255c0d7c51de6d1c | [
"MIT"
] | 18 | 2015-02-03T19:27:18.000Z | 2021-04-04T03:03:57.000Z | urbit_sniffer.py | laanwj/urbit-tools | b3823d50d5ab84c0852593e3255c0d7c51de6d1c | [
"MIT"
] | null | null | null | urbit_sniffer.py | laanwj/urbit-tools | b3823d50d5ab84c0852593e3255c0d7c51de6d1c | [
"MIT"
] | 2 | 2015-10-02T01:37:13.000Z | 2017-06-04T03:41:49.000Z | #!/usr/bin/python3
# Copyright (c) 2014 Wladimir J. van der Laan, Visucore
# Distributed under the MIT software license, see
# http://www.opensource.org/licenses/mit-license.php.
'''
urbit UDP sniffer
Usage: urbit_sniffer.py [-p <port1>-<port2>,<port3>,...] [-i <interface>]
'''
import struct, sys, io, argparse, dateti... | 38.146552 | 165 | 0.599887 |
6bd258b97e010833aa36fdeb89edf6a7e0ee7073 | 2,556 | py | Python | Assignment_2_Pi/Pi_Archimedes/Pi_Archimedes.py | osccal/python-course | e815fd647fc5e5248188ed3976b62a181831e9ba | [
"MIT"
] | null | null | null | Assignment_2_Pi/Pi_Archimedes/Pi_Archimedes.py | osccal/python-course | e815fd647fc5e5248188ed3976b62a181831e9ba | [
"MIT"
] | null | null | null | Assignment_2_Pi/Pi_Archimedes/Pi_Archimedes.py | osccal/python-course | e815fd647fc5e5248188ed3976b62a181831e9ba | [
"MIT"
] | null | null | null | """
Python3 program to calculate pi to 100 places using Archimedes method
"""
from decimal import Decimal, getcontext
from time import time
def pi_archimedes(n):
"""
Calculate n iterations of Archimedes PI
"""
polygon_edge_length_squared = Decimal(2) # Decimal for precision
polygon_sides = 2
... | 54.382979 | 1,011 | 0.777778 |