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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
e41bb3e24e831bc6c9db543d89a47e06639cb0a0 | 355 | py | Python | src/comments/migrations/0004_auto_20200209_1812.py | samrika25/TRAVIS_HEROKU_GIT | bcae6d0422d9a0369810944a91dd03db7df0d058 | [
"MIT"
] | null | null | null | src/comments/migrations/0004_auto_20200209_1812.py | samrika25/TRAVIS_HEROKU_GIT | bcae6d0422d9a0369810944a91dd03db7df0d058 | [
"MIT"
] | 4 | 2021-03-30T12:35:36.000Z | 2021-06-10T18:11:24.000Z | src/comments/migrations/0004_auto_20200209_1812.py | samrika25/TRAVIS_HEROKU_GIT | bcae6d0422d9a0369810944a91dd03db7df0d058 | [
"MIT"
] | 2 | 2021-02-07T16:16:36.000Z | 2021-07-13T05:26:51.000Z | # Generated by Django 3.0.2 on 2020-02-09 18:12
from django.db import migrations
| 19.722222 | 51 | 0.6 |
e41c425d0ed1f3d737beeff6b6c0f31113fafb62 | 768 | py | Python | multicasting_test_scripts/sender.py | sandwichdoge/libmulticastudp | 735a3a6242d5444f9a5a070322a7033296707cdf | [
"MIT"
] | null | null | null | multicasting_test_scripts/sender.py | sandwichdoge/libmulticastudp | 735a3a6242d5444f9a5a070322a7033296707cdf | [
"MIT"
] | null | null | null | multicasting_test_scripts/sender.py | sandwichdoge/libmulticastudp | 735a3a6242d5444f9a5a070322a7033296707cdf | [
"MIT"
] | null | null | null | #
# mostly copied from
# http://bioportal.weizmann.ac.il/course/python/PyMOTW/PyMOTW/docs/socket/multicast.html
#
import socket
import struct
import sys
import time
message = 'data worth repeating'
multicast_group = ('226.1.1.1', 4321)
# Create the datagram socket
sock = socket.socket(socket.AF_INET, socket.SOCK_D... | 20.756757 | 90 | 0.670573 |
e42510b046e5ad727d96dec824908363abd5654f | 852 | py | Python | python/chol_factor_test.py | davxy/numeric | 1e8b44a72e1d570433a5ba81ae0795a750ce5921 | [
"Unlicense"
] | 2 | 2020-05-03T17:02:44.000Z | 2022-02-21T04:09:34.000Z | python/chol_factor_test.py | davxy/numeric | 1e8b44a72e1d570433a5ba81ae0795a750ce5921 | [
"Unlicense"
] | null | null | null | python/chol_factor_test.py | davxy/numeric | 1e8b44a72e1d570433a5ba81ae0795a750ce5921 | [
"Unlicense"
] | null | null | null | import numpy as np
from chol_factor import chol_factor
from triangular import triangular
# TEST: Cholesky factorization (LL')
# Symmetric positive definite matrix
A = np.matrix('5 1.2 0.3 -0.6;'
'1.2 6 -0.4 0.9;'
'0.3 -0.4 8 1.7;'
'-0.6 0.9 1.7 10');
print('A = ... | 23.027027 | 53 | 0.580986 |
e4257523a5f56faf33e09f713fd3a02e93109a4b | 11,245 | py | Python | PSO_system/GUI/gui_root.py | daniel4lee/PSO-car-simulator | b4aebca0fed614e33acc3e7d665085d55a67b82a | [
"MIT"
] | 1 | 2022-03-23T21:51:59.000Z | 2022-03-23T21:51:59.000Z | PSO_system/GUI/gui_root.py | daniel4lee/PSO-car-simulator | b4aebca0fed614e33acc3e7d665085d55a67b82a | [
"MIT"
] | 1 | 2018-10-08T12:53:42.000Z | 2018-10-08T13:46:13.000Z | PSO_system/GUI/gui_root.py | daniel4lee/PSO-car-simulator | b4aebca0fed614e33acc3e7d665085d55a67b82a | [
"MIT"
] | 2 | 2020-04-26T08:22:53.000Z | 2021-05-18T09:51:24.000Z | """Build the tkinter gui root"""
import math
from PyQt5.QtWidgets import *#(QWidget, QToolTip, QDesktopWidget, QPushButton, QApplication)
from PyQt5.QtGui import QFont
from PyQt5.QtCore import QCoreApplication, QObject, QRunnable, QThread, QThreadPool, pyqtSignal, pyqtSlot
from PyQt5.QtGui import QIntValidator, QDoubl... | 41.494465 | 139 | 0.649355 |
e425b8c86c1c0699016fdb4cfc8b01eea833c4f2 | 2,346 | py | Python | qsrlib/src/qsrlib_qsrs/qsr_cardinal_direction.py | alexiatoumpa/QSR_Detector | ff92a128dddb613690a49a7b4130afeac0dd4381 | [
"MIT"
] | 15 | 2015-06-15T16:50:37.000Z | 2022-03-27T09:25:56.000Z | qsrlib/src/qsrlib_qsrs/qsr_cardinal_direction.py | alexiatoumpa/QSR_Detector | ff92a128dddb613690a49a7b4130afeac0dd4381 | [
"MIT"
] | 205 | 2015-01-22T12:02:59.000Z | 2022-03-29T11:59:55.000Z | qsrlib/src/qsrlib_qsrs/qsr_cardinal_direction.py | alexiatoumpa/QSR_Detector | ff92a128dddb613690a49a7b4130afeac0dd4381 | [
"MIT"
] | 16 | 2015-02-04T23:13:18.000Z | 2022-03-08T13:45:53.000Z | # -*- coding: utf-8 -*-
from __future__ import print_function, division
from qsrlib_qsrs.qsr_dyadic_abstractclass import QSR_Dyadic_1t_Abstractclass
import math
| 31.28 | 118 | 0.561381 |
e4287373cf648c93ed322e508af33deff1f8e862 | 4,291 | py | Python | clustering/GMM.py | peasant98/NBA-Stats-Clustering | 57ff7e70a8cbb0c609d6a6720134a37695e2a860 | [
"MIT"
] | null | null | null | clustering/GMM.py | peasant98/NBA-Stats-Clustering | 57ff7e70a8cbb0c609d6a6720134a37695e2a860 | [
"MIT"
] | null | null | null | clustering/GMM.py | peasant98/NBA-Stats-Clustering | 57ff7e70a8cbb0c609d6a6720134a37695e2a860 | [
"MIT"
] | null | null | null | # NBA Stats Clustering
# Copyright Matthew Strong, 2019
# gaussian mixture models with em algorithm
import numpy as np
from scipy import stats
from clustering.Cluster import NBACluster
# nba gmm class
# gmm from scratch as well, more explained below
| 40.102804 | 120 | 0.554649 |
e428f454d7dceb480c84f33f264e2ac819a010fd | 1,484 | py | Python | ML/eval.py | Data-Science-Community-SRM/Fashion-Generation | fa062e2b31b4fba8945820d911dfa41de45b1333 | [
"MIT"
] | 1 | 2021-04-27T09:13:09.000Z | 2021-04-27T09:13:09.000Z | ML/eval.py | Aradhya-Tripathi/Fashion-Generation | fa062e2b31b4fba8945820d911dfa41de45b1333 | [
"MIT"
] | null | null | null | ML/eval.py | Aradhya-Tripathi/Fashion-Generation | fa062e2b31b4fba8945820d911dfa41de45b1333 | [
"MIT"
] | 1 | 2021-03-12T13:15:08.000Z | 2021-03-12T13:15:08.000Z | import torch
from torch.utils.data import DataLoader
import matplotlib.pyplot as plt
import sys
sys.path.append("./ML")
import Definitions.models as models
from Definitions.dataset import Data
if __name__ == "__main__":
main()
| 26.981818 | 94 | 0.617925 |
e42935051444daddcd5cee33f9a2daa9cde6e823 | 4,965 | py | Python | app/screens/authorize.py | jimkutter/rpi_lcars | f5ae0891f26d3494ad77f894c4f7733deaf063ee | [
"MIT"
] | null | null | null | app/screens/authorize.py | jimkutter/rpi_lcars | f5ae0891f26d3494ad77f894c4f7733deaf063ee | [
"MIT"
] | null | null | null | app/screens/authorize.py | jimkutter/rpi_lcars | f5ae0891f26d3494ad77f894c4f7733deaf063ee | [
"MIT"
] | null | null | null | from datetime import datetime, timedelta
import pygame
from pygame.mixer import Sound
from screens.base_screen import BaseScreen
from ui import colours
from ui.widgets.background import LcarsBackgroundImage
from ui.widgets.gifimage import LcarsGifImage
from ui.widgets.lcars_widgets import LcarsButton
from ui.widgets.... | 31.03125 | 118 | 0.557301 |
e42efd7b2e91e2b6ad55453d791a04774b95fe07 | 31 | py | Python | swarm_tasks/utils/__init__.py | rmvanarse/swarm_tasks | 3335297ba8fcdbff756ae519002bcce919d54a84 | [
"MIT"
] | 6 | 2021-03-13T12:54:18.000Z | 2022-01-29T12:12:28.000Z | swarm_tasks/utils/__init__.py | rmvanarse/swarm_tasks | 3335297ba8fcdbff756ae519002bcce919d54a84 | [
"MIT"
] | null | null | null | swarm_tasks/utils/__init__.py | rmvanarse/swarm_tasks | 3335297ba8fcdbff756ae519002bcce919d54a84 | [
"MIT"
] | 2 | 2021-08-06T15:02:15.000Z | 2022-02-08T12:11:30.000Z | import swarm_tasks.utils.robot
| 15.5 | 30 | 0.870968 |
e4324e2ffd9d0f0cc445c08f1b32895fbc79b0d2 | 2,178 | py | Python | Problems/P0010 - Soma de primos.py | clasenback/EulerProject | 775d9774fcdfbbcc579e3c4ec0bb2d4a941764ad | [
"CC0-1.0"
] | null | null | null | Problems/P0010 - Soma de primos.py | clasenback/EulerProject | 775d9774fcdfbbcc579e3c4ec0bb2d4a941764ad | [
"CC0-1.0"
] | null | null | null | Problems/P0010 - Soma de primos.py | clasenback/EulerProject | 775d9774fcdfbbcc579e3c4ec0bb2d4a941764ad | [
"CC0-1.0"
] | null | null | null | # -*- coding: utf-8 -*-
"""
Created on Sun Mar 7 17:11:12 2021
@author: User
SUMMATION OF PRIMES
The sum of the primes below 10 is 2 + 3 + 5 + 7 = 17.
Find the sum of all the primes below two million.
21min19s to find.
"""
from datetime import datetime as date
# INPUTS
target = 2000000
prime... | 26.888889 | 82 | 0.539027 |
e4348a8c3eadb9042a4b4b0ebb7cd499d99a7b46 | 1,124 | py | Python | l5kit/l5kit/tests/rasterization/render_context_test.py | cdicle-motional/l5kit | 4dc4ee5391479bb71f0b373f39c316f9eef5a961 | [
"Apache-2.0"
] | 1 | 2021-12-04T17:48:53.000Z | 2021-12-04T17:48:53.000Z | l5kit/l5kit/tests/rasterization/render_context_test.py | cdicle-motional/l5kit | 4dc4ee5391479bb71f0b373f39c316f9eef5a961 | [
"Apache-2.0"
] | null | null | null | l5kit/l5kit/tests/rasterization/render_context_test.py | cdicle-motional/l5kit | 4dc4ee5391479bb71f0b373f39c316f9eef5a961 | [
"Apache-2.0"
] | 1 | 2021-11-19T08:13:46.000Z | 2021-11-19T08:13:46.000Z | import numpy as np
import pytest
from l5kit.geometry import transform_points
from l5kit.rasterization.render_context import RenderContext
| 35.125 | 77 | 0.715302 |
e434cb20e1bb4b89d1f4687abbe31af32ff3e3b8 | 1,528 | py | Python | plugin/fcitx.py | bigshans/fcitx.vim | 228a51c6c95997439feddff6c38d62ce014e6d59 | [
"MIT"
] | null | null | null | plugin/fcitx.py | bigshans/fcitx.vim | 228a51c6c95997439feddff6c38d62ce014e6d59 | [
"MIT"
] | null | null | null | plugin/fcitx.py | bigshans/fcitx.vim | 228a51c6c95997439feddff6c38d62ce014e6d59 | [
"MIT"
] | null | null | null | import vim
import functools
import dbus
try:
Fcitx = FcitxComm()
fcitx_loaded = True
except dbus.exceptions.DBusException as e:
if not vim.vars.get('silent_unsupported'):
vim.command('echohl WarningMsg | echom "fcitx.vim not loaded: %s" | echohl NONE' % e)
fcitx_loaded = False
| 25.466667 | 106 | 0.656414 |
e43577db4ce37b9708732914de0c5a01c24639dc | 311 | py | Python | ctf/post.py | ntdgy/python_study | c3511846a89ea72418937de4cc3edf1595a46ec5 | [
"MIT"
] | null | null | null | ctf/post.py | ntdgy/python_study | c3511846a89ea72418937de4cc3edf1595a46ec5 | [
"MIT"
] | null | null | null | ctf/post.py | ntdgy/python_study | c3511846a89ea72418937de4cc3edf1595a46ec5 | [
"MIT"
] | null | null | null | import requests
post()
| 17.277778 | 61 | 0.559486 |
e435bc6759728f66c9ba58ab0f9f30b4d9e6d31b | 828 | py | Python | avioclient/controller.py | HermenegildoK/AvioClient | 9cad3a89bbf10d7212561cf15b3ad453060c9434 | [
"MIT"
] | null | null | null | avioclient/controller.py | HermenegildoK/AvioClient | 9cad3a89bbf10d7212561cf15b3ad453060c9434 | [
"MIT"
] | null | null | null | avioclient/controller.py | HermenegildoK/AvioClient | 9cad3a89bbf10d7212561cf15b3ad453060c9434 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
from avioclient.send_data import SendControls
from avioclient import config
if __name__ == "__main__":
send_data()
| 23.657143 | 50 | 0.48913 |
e43608fd33081461199e20cc093779ca67fd8543 | 132 | py | Python | pythonExercicios/ex014.py | Yhago-Carvalho/CursoPython | 343ccabb1a61e16c6078de9672c78c56deed2589 | [
"MIT"
] | null | null | null | pythonExercicios/ex014.py | Yhago-Carvalho/CursoPython | 343ccabb1a61e16c6078de9672c78c56deed2589 | [
"MIT"
] | null | null | null | pythonExercicios/ex014.py | Yhago-Carvalho/CursoPython | 343ccabb1a61e16c6078de9672c78c56deed2589 | [
"MIT"
] | null | null | null | c = float(input('Digite a temperatura em Ceusius: '))
f = (9*c + 160)/5
print(f'A temperatura de {c:.1f}C corresponde a {f:.1f}F') | 44 | 60 | 0.659091 |
e436ff03150d44e0196337e442c791322d057adb | 95 | py | Python | python/p287ex5.py | ThePeeps191/dmoj-solutions | 7137e945f3f595c481ad4d29e1dc3a77d8b26e55 | [
"MIT"
] | 1 | 2022-01-23T16:02:14.000Z | 2022-01-23T16:02:14.000Z | python/p287ex5.py | ThePeeps191/dmoj-solutions | 7137e945f3f595c481ad4d29e1dc3a77d8b26e55 | [
"MIT"
] | 5 | 2022-01-23T00:16:49.000Z | 2022-01-30T04:37:45.000Z | python/p287ex5.py | ThePeeps191/dmoj-solutions | 7137e945f3f595c481ad4d29e1dc3a77d8b26e55 | [
"MIT"
] | 1 | 2022-01-23T00:03:47.000Z | 2022-01-23T00:03:47.000Z | # not yet finished
for _ in range(int(input())):print(len(list(set(input().replace("-", ""))))) | 47.5 | 76 | 0.631579 |
e43c4d5552c855523479c4f6f4237cbc56d53955 | 906 | py | Python | tests/test_fitsutils.py | lsst-dm/despyfitsutils | 7fb96869077712eb20a1cb0f5c132e1cc85424ec | [
"NCSA"
] | null | null | null | tests/test_fitsutils.py | lsst-dm/despyfitsutils | 7fb96869077712eb20a1cb0f5c132e1cc85424ec | [
"NCSA"
] | null | null | null | tests/test_fitsutils.py | lsst-dm/despyfitsutils | 7fb96869077712eb20a1cb0f5c132e1cc85424ec | [
"NCSA"
] | null | null | null | import os
import unittest
import despyfitsutils.fitsutils as utils
TESTDIR = os.path.dirname(__file__)
| 25.885714 | 72 | 0.611479 |
e43dacaa5bafcd52f175484e3b1f257816fb14b1 | 4,047 | py | Python | applications/MensajeriaMasiva/models/db.py | chitohugo/MassiveSMS | 05b528de146498531c967aff1ee4fe72720febb3 | [
"BSD-3-Clause"
] | null | null | null | applications/MensajeriaMasiva/models/db.py | chitohugo/MassiveSMS | 05b528de146498531c967aff1ee4fe72720febb3 | [
"BSD-3-Clause"
] | null | null | null | applications/MensajeriaMasiva/models/db.py | chitohugo/MassiveSMS | 05b528de146498531c967aff1ee4fe72720febb3 | [
"BSD-3-Clause"
] | null | null | null | #!/usr/bin/env python
# -*- coding: utf-8 -*-
from time import gmtime, strftime
from gluon.custom_import import track_changes
track_changes(True)
from gluon import current
from pydal import *
import sys
reload(sys)
sys.setdefaultencoding('utf-8')
if request.global_settings.web2py_version < "2.14.1":
raise HTTP... | 45.988636 | 165 | 0.560909 |
e43dfd916520e80acf562c6592c0e2124190ae44 | 2,066 | py | Python | dibs/src/dibs_link.py | emin63/dibs | 419b2fad041aee40647429d3c1faac52c92c25a3 | [
"MIT"
] | null | null | null | dibs/src/dibs_link.py | emin63/dibs | 419b2fad041aee40647429d3c1faac52c92c25a3 | [
"MIT"
] | null | null | null | dibs/src/dibs_link.py | emin63/dibs | 419b2fad041aee40647429d3c1faac52c92c25a3 | [
"MIT"
] | null | null | null |
import os
if (os.name == 'nt' or os.name == 'dos'):
try:
from win32com.shell import shell
import pythoncom
except Exception, e:
print 'WARNING: Received exception ' + `e` + ' in doing import.'
print 'WARNING: Unable to import win32com.shell.shell, pythoncom.'
... | 34.433333 | 80 | 0.57696 |
e43f5553851f44ad5911378e9d31bfdce168b90d | 1,207 | py | Python | rfid/eggplant/pigeon/migrations/0003_auto_20160328_0809.py | psiyan/rfid | 401a093958ffafdcd10259cc9e19b7bd9f0c0e8c | [
"Apache-2.0"
] | null | null | null | rfid/eggplant/pigeon/migrations/0003_auto_20160328_0809.py | psiyan/rfid | 401a093958ffafdcd10259cc9e19b7bd9f0c0e8c | [
"Apache-2.0"
] | null | null | null | rfid/eggplant/pigeon/migrations/0003_auto_20160328_0809.py | psiyan/rfid | 401a093958ffafdcd10259cc9e19b7bd9f0c0e8c | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
# Generated by Django 1.9.2 on 2016-03-28 08:09
from __future__ import unicode_literals
from django.db import migrations, models
| 29.439024 | 93 | 0.584093 |
e43fd711dcd86e63949520216ee91e975352e431 | 10,839 | py | Python | esp8266/main.py | 0xSebin/SwimTime.github.io | e2d997464d1f4a36783638c81307a775cdfa7fcd | [
"MIT"
] | 1 | 2021-03-28T16:24:23.000Z | 2021-03-28T16:24:23.000Z | esp8266/main.py | 5ebin-thomas/SwimTime.github.io | e2d997464d1f4a36783638c81307a775cdfa7fcd | [
"MIT"
] | null | null | null | esp8266/main.py | 5ebin-thomas/SwimTime.github.io | e2d997464d1f4a36783638c81307a775cdfa7fcd | [
"MIT"
] | 2 | 2018-02-15T17:27:34.000Z | 2019-11-20T10:00:43.000Z | """
Group -
SwimTime - Swim your way to success
"""
import ads1x15
import network
import time
import math
import machine
from umqtt.simple import MQTTClient
import micropython
from micropython import const
from machine import Pin
"""
Define constant values
"""
run = False
lapnr = 3 #default lap number
temp = ... | 28.448819 | 110 | 0.658456 |
e44176bdde09e0e534875279d12d7f2e7e878bfb | 40,102 | py | Python | pyboto3/workdocs.py | thecraftman/pyboto3 | 653a0db2b00b06708334431da8f169d1f7c7734f | [
"MIT"
] | null | null | null | pyboto3/workdocs.py | thecraftman/pyboto3 | 653a0db2b00b06708334431da8f169d1f7c7734f | [
"MIT"
] | null | null | null | pyboto3/workdocs.py | thecraftman/pyboto3 | 653a0db2b00b06708334431da8f169d1f7c7734f | [
"MIT"
] | null | null | null | '''
The MIT License (MIT)
Copyright (c) 2016 WavyCloud
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, merge, p... | 29.143895 | 310 | 0.573039 |
e4423151d9e155eac596c2c27348cae0215b843a | 983 | py | Python | binding/python/ddls/feeder/feeder.py | huzelin/ddls | 3333a669c59ce2e525945f814a54784dafc6191b | [
"MIT"
] | 3 | 2019-01-03T07:34:01.000Z | 2020-02-13T19:53:35.000Z | binding/python/ddls/feeder/feeder.py | huzelin/ddls | 3333a669c59ce2e525945f814a54784dafc6191b | [
"MIT"
] | null | null | null | binding/python/ddls/feeder/feeder.py | huzelin/ddls | 3333a669c59ce2e525945f814a54784dafc6191b | [
"MIT"
] | 1 | 2020-05-06T11:08:07.000Z | 2020-05-06T11:08:07.000Z | """ Feeder for batch production"""
from __future__ import absolute_import
import ctypes
from ddls.base import check_call, LIB, c_str, c_array
from ddls.feeder.batch_iterator import BatchIterator
| 27.305556 | 84 | 0.580875 |
e44339ec7d8d98173878c5ddc15f39e511c628ec | 258 | py | Python | tests/test_example.py | akoul1/mvlearn | 177d391bb12c6e94335720d9af3608bd719d8be1 | [
"Apache-2.0"
] | null | null | null | tests/test_example.py | akoul1/mvlearn | 177d391bb12c6e94335720d9af3608bd719d8be1 | [
"Apache-2.0"
] | null | null | null | tests/test_example.py | akoul1/mvlearn | 177d391bb12c6e94335720d9af3608bd719d8be1 | [
"Apache-2.0"
] | null | null | null | import pytest
from mvlearn.example.example import example_function
def test_example_function():
"""
Test that example function returns correct value.
"""
assert example_function() == "param"
assert example_function("hello") == "hello"
| 21.5 | 53 | 0.713178 |
e443a35a02a890811a35899fe38cc7d3bb4c7d5c | 2,155 | py | Python | api/resources/resources.py | arkhn/fhirball-server | b4d1a1c29dfff5ba60bfbb6b291f6bdb6e6ccd6e | [
"Apache-2.0"
] | 5 | 2018-12-21T13:20:12.000Z | 2019-11-20T23:58:06.000Z | api/resources/resources.py | arkhn/fhir-ball-server | b4d1a1c29dfff5ba60bfbb6b291f6bdb6e6ccd6e | [
"Apache-2.0"
] | null | null | null | api/resources/resources.py | arkhn/fhir-ball-server | b4d1a1c29dfff5ba60bfbb6b291f6bdb6e6ccd6e | [
"Apache-2.0"
] | null | null | null | from flask_restful import Resource
import requests
from api.common.utils import file_response
ENCODING = 'utf-8'
SCHEMA_URL = 'http://127.0.0.1:8422'
STORE_URL = 'http://127.0.0.1:8423'
| 24.770115 | 87 | 0.624594 |
e445d667e0d2518eeb5e300fca8baeaa532b0501 | 427 | py | Python | t_mongo.py | iloghyr/easy_python | b750f6817d54562b23630e2419bace19da0abf8b | [
"Apache-2.0"
] | 1 | 2018-03-01T02:42:52.000Z | 2018-03-01T02:42:52.000Z | t_mongo.py | iloghyr/easy_python | b750f6817d54562b23630e2419bace19da0abf8b | [
"Apache-2.0"
] | null | null | null | t_mongo.py | iloghyr/easy_python | b750f6817d54562b23630e2419bace19da0abf8b | [
"Apache-2.0"
] | null | null | null | #!/bin/env python
#coding: utf-8
import pymongo
print [x for x in range(2)]
con = pymongo.MongoClient("localhost", 27017)
db = con.mars
collection = db.users
data = collection.find_one({"username":"hyr"})
print data
data['age'] = 225
print collection.update({"_idd":data['_id']}, data)
print collection.find_one({"u... | 17.08 | 70 | 0.683841 |
e4466c3b9ecc29dbb105b55c4d10907897f3d25c | 742 | py | Python | ArtificialData/RhoAndBeta.py | AlfLobos/DSP | 1e1073c6b0da562b0aea3dec9d62bc563a3b46f5 | [
"CNRI-Python"
] | null | null | null | ArtificialData/RhoAndBeta.py | AlfLobos/DSP | 1e1073c6b0da562b0aea3dec9d62bc563a3b46f5 | [
"CNRI-Python"
] | null | null | null | ArtificialData/RhoAndBeta.py | AlfLobos/DSP | 1e1073c6b0da562b0aea3dec9d62bc563a3b46f5 | [
"CNRI-Python"
] | null | null | null | import numpy as np | 35.333333 | 91 | 0.677898 |
e44985df33485739c9a738d44c1ed72af3c01cd0 | 3,208 | py | Python | src/utils/greedy.py | vmgabriel/tabu-base | 615c45e4d6b6fdb1c85c8fbaa316a1e6ce829fcd | [
"Apache-2.0"
] | null | null | null | src/utils/greedy.py | vmgabriel/tabu-base | 615c45e4d6b6fdb1c85c8fbaa316a1e6ce829fcd | [
"Apache-2.0"
] | null | null | null | src/utils/greedy.py | vmgabriel/tabu-base | 615c45e4d6b6fdb1c85c8fbaa316a1e6ce829fcd | [
"Apache-2.0"
] | null | null | null | """
Greedy Module Solution for Utils control
"""
# Libraries
from typing import List
from functools import reduce
# Modules
from src.utils.math import (
list_negative,
invert_positions,
evaluate_fo
)
# Constants
COMPARE_VALUE = 99999999
def worst_solution(distance_matrix: List[List[float]]) -> List[in... | 25.870968 | 73 | 0.5798 |
e45010e55211f1d8b353af0fb64ccf62757ae1c3 | 5,649 | py | Python | codes/models/modules/Inv_arch.py | lin-zhao-resoLve/Symmetric-Enhancement | 11c1a662020582d1333d11cf5f9c99556ec0f427 | [
"Apache-2.0"
] | 14 | 2021-09-30T07:05:04.000Z | 2022-03-31T08:22:39.000Z | codes/models/modules/Inv_arch.py | lin-zhao-resoLve/Symmetric-Enhancement | 11c1a662020582d1333d11cf5f9c99556ec0f427 | [
"Apache-2.0"
] | 3 | 2021-11-09T06:52:13.000Z | 2021-11-20T08:00:46.000Z | codes/models/modules/Inv_arch.py | lin-zhao-resoLve/Symmetric-Enhancement | 11c1a662020582d1333d11cf5f9c99556ec0f427 | [
"Apache-2.0"
] | null | null | null | import math
import torch
import torch.nn as nn
import torch.nn.functional as F
import numpy as np
from models.modules.model.vgg16 import Vgg16
import os
vgg = Vgg16()
vgg.load_state_dict(torch.load(os.path.join(os.path.abspath('.'), 'models/modules/model/', 'vgg16.weight')))
params = list(vgg.named_parameters())
encodi... | 36.211538 | 108 | 0.615861 |
e450e0a78fcbebd70da772f87d262f552594b525 | 56 | py | Python | FrontRunner.py | mmaist/FrontRunner | 05095421b69a0a5ccf4ef53ae3dc35b8e8b926b7 | [
"MIT"
] | 1 | 2021-02-18T10:41:36.000Z | 2021-02-18T10:41:36.000Z | FrontRunner.py | mmaist/FrontRunner | 05095421b69a0a5ccf4ef53ae3dc35b8e8b926b7 | [
"MIT"
] | null | null | null | FrontRunner.py | mmaist/FrontRunner | 05095421b69a0a5ccf4ef53ae3dc35b8e8b926b7 | [
"MIT"
] | null | null | null | import time
import random
import json
import requests
| 8 | 15 | 0.821429 |
e4520356b6e60cb7ea00f5353a2466e715bcd995 | 1,642 | py | Python | py_algo/dynamic_programming/introduction/equal_array.py | Sk0uF/Algorithms | 236cc5b056ce2637d5d947c5fc1e3367cde886bf | [
"MIT"
] | 1 | 2021-07-05T15:39:04.000Z | 2021-07-05T15:39:04.000Z | py_algo/dynamic_programming/introduction/equal_array.py | Sk0uF/Algorithms | 236cc5b056ce2637d5d947c5fc1e3367cde886bf | [
"MIT"
] | null | null | null | py_algo/dynamic_programming/introduction/equal_array.py | Sk0uF/Algorithms | 236cc5b056ce2637d5d947c5fc1e3367cde886bf | [
"MIT"
] | 1 | 2021-09-02T21:31:34.000Z | 2021-09-02T21:31:34.000Z | """
Codemonk link: https://www.hackerearth.com/practice/algorithms/dynamic-programming/introduction-to-dynamic-programming-1/practice-problems/algorithm/equal-array-84cf6c5f/
You are given an array A of size N. Find the minimum non negative number X such that there exists an index j that when
you can replace Aj by Aj+... | 30.407407 | 170 | 0.658343 |
e4526af2d705bb3c47b1ba3a6b79144d1876aeeb | 1,331 | py | Python | model.py | mollikka/Penrose | 6d9870f54e9810f7e2f4ea82bb619424785a65db | [
"MIT"
] | 1 | 2019-07-17T02:46:45.000Z | 2019-07-17T02:46:45.000Z | model.py | mollikka/Penrose | 6d9870f54e9810f7e2f4ea82bb619424785a65db | [
"MIT"
] | null | null | null | model.py | mollikka/Penrose | 6d9870f54e9810f7e2f4ea82bb619424785a65db | [
"MIT"
] | null | null | null | from itertools import chain
phi = 1.61803398875
| 22.183333 | 72 | 0.480841 |
e45397111350f9273e2cc86843e6973c134d6e85 | 1,465 | py | Python | src/tests/unittests/configuration_helper/adapters/test_keysight_e8267d_instrument_adapter.py | QuTech-Delft/qilib | a87892f8a9977ed338c36e8fb1e262b47449cf44 | [
"MIT"
] | 1 | 2019-02-20T16:56:30.000Z | 2019-02-20T16:56:30.000Z | src/tests/unittests/configuration_helper/adapters/test_keysight_e8267d_instrument_adapter.py | QuTech-Delft/qilib | a87892f8a9977ed338c36e8fb1e262b47449cf44 | [
"MIT"
] | 22 | 2019-02-16T06:10:55.000Z | 2022-02-15T18:52:34.000Z | src/tests/unittests/configuration_helper/adapters/test_keysight_e8267d_instrument_adapter.py | QuTech-Delft/qilib | a87892f8a9977ed338c36e8fb1e262b47449cf44 | [
"MIT"
] | 2 | 2020-02-04T08:46:21.000Z | 2020-10-18T16:31:58.000Z | import unittest
from unittest.mock import call, patch, Mock, MagicMock
from qilib.configuration_helper import InstrumentAdapterFactory
| 47.258065 | 112 | 0.661433 |
e455b64eee36fc129ded8331905ce5976719baa2 | 1,364 | py | Python | scripts/mint.py | tomazmm/artsyapes-contract | 95b10e1c73aa4e0712ff8d5162271e84aec91810 | [
"Apache-2.0"
] | null | null | null | scripts/mint.py | tomazmm/artsyapes-contract | 95b10e1c73aa4e0712ff8d5162271e84aec91810 | [
"Apache-2.0"
] | null | null | null | scripts/mint.py | tomazmm/artsyapes-contract | 95b10e1c73aa4e0712ff8d5162271e84aec91810 | [
"Apache-2.0"
] | null | null | null | import json
import pprint
import random
from terra_sdk.core import AccAddress, Coins
from terra_sdk.core.auth import StdFee
from terra_sdk.core.broadcast import BlockTxBroadcastResult
from scripts.deploy import owner, lt
from terra_sdk.core.wasm import MsgExecuteContract
if __name__ == '__main__':
main()
| 28.416667 | 98 | 0.662023 |
e45875441dea1d18e8ce1f3858f85bde9799b868 | 281 | py | Python | url_shortener/exceptions.py | alena-kono/simple-shortener | d1549b342e190ff70509ce5b442cb31376f2a07a | [
"MIT"
] | null | null | null | url_shortener/exceptions.py | alena-kono/simple-shortener | d1549b342e190ff70509ce5b442cb31376f2a07a | [
"MIT"
] | null | null | null | url_shortener/exceptions.py | alena-kono/simple-shortener | d1549b342e190ff70509ce5b442cb31376f2a07a | [
"MIT"
] | null | null | null | from core.exceptions import BaseProjectException
| 20.071429 | 55 | 0.761566 |
e4589a7ec39dfb446ef1fe4c8fd01bbb42b8704d | 1,507 | py | Python | enbios/processing/indicators/__init__.py | ENVIRO-Module/enbios | 10e93df9a168627833eca6d04e4e2b864de8e8d9 | [
"BSD-3-Clause"
] | 2 | 2022-01-28T09:38:28.000Z | 2022-01-28T09:38:32.000Z | enbios/processing/indicators/__init__.py | ENVIRO-Module/enbios | 10e93df9a168627833eca6d04e4e2b864de8e8d9 | [
"BSD-3-Clause"
] | 1 | 2022-01-27T21:42:42.000Z | 2022-01-27T21:42:42.000Z | enbios/processing/indicators/__init__.py | ENVIRO-Module/enbios | 10e93df9a168627833eca6d04e4e2b864de8e8d9 | [
"BSD-3-Clause"
] | null | null | null | import math
from nexinfosys.model_services import State
materials = {
"Aluminium",
"Antimony",
"Arsenic",
"Baryte",
"Beryllium",
"Borates",
"Cadmium",
"Cerium",
"Chromium",
"Cobalt",
"Copper",
"Diatomite",
"Dysprosium",
"Europium",
"Fluorspar",
"Gadolini... | 17.125 | 43 | 0.50564 |
e45a47a7a23107da9b1e4e894dbe004e6d56eaf1 | 2,933 | py | Python | Python Exercises/Exercise 8 - Functions/Functions- Decorators & Generators.py | mrankitgupta/PythonLessons | 119efc58518c5b35c6647009c74ff96728f851fa | [
"MIT"
] | null | null | null | Python Exercises/Exercise 8 - Functions/Functions- Decorators & Generators.py | mrankitgupta/PythonLessons | 119efc58518c5b35c6647009c74ff96728f851fa | [
"MIT"
] | null | null | null | Python Exercises/Exercise 8 - Functions/Functions- Decorators & Generators.py | mrankitgupta/PythonLessons | 119efc58518c5b35c6647009c74ff96728f851fa | [
"MIT"
] | null | null | null | # defining a decorator
# defining a function, to be called inside wrapper
# passing 'function_to_be_used' inside the decorator to control its behaviour
function_to_be_used = hello_decorator(function_to_be_used)
# calling the function
function_to_be_used()
# find out the execution time of a function using a deco... | 30.237113 | 144 | 0.691101 |
e45a7bbe70e7b8614eb0c9109018644cf05fb490 | 24,654 | py | Python | src/1-topicmodeling.py | sofieditmer/topic_modeling | edfff3c4d45c932562f796cc81e9ce9fe35f8e4b | [
"MIT"
] | null | null | null | src/1-topicmodeling.py | sofieditmer/topic_modeling | edfff3c4d45c932562f796cc81e9ce9fe35f8e4b | [
"MIT"
] | null | null | null | src/1-topicmodeling.py | sofieditmer/topic_modeling | edfff3c4d45c932562f796cc81e9ce9fe35f8e4b | [
"MIT"
] | null | null | null | #!/usr/bin/env python
"""
Info: This script performs topic modeling on the clean tweets by Donald Trump. The number of topics is estimated by computing coherence values for different number of topics, and an LDA model is constructed with the number of topics with the highest coherence value. Visualizations of the topic... | 46.693182 | 402 | 0.626511 |
e45a8dc57b1450e18797d47ff570959f3d7e2d31 | 15,086 | py | Python | EEG_Lightning/dassl/data/datasets/ProcessDataBase_v1.py | mcd4874/NeurIPS_competition | 4df1f222929e9824a55c9c4ae6634743391b0fe9 | [
"MIT"
] | 23 | 2021-10-14T02:31:06.000Z | 2022-01-25T16:26:44.000Z | EEG_Lightning/dassl/data/datasets/ProcessDataBase_v1.py | mcd4874/NeurIPS_competition | 4df1f222929e9824a55c9c4ae6634743391b0fe9 | [
"MIT"
] | null | null | null | EEG_Lightning/dassl/data/datasets/ProcessDataBase_v1.py | mcd4874/NeurIPS_competition | 4df1f222929e9824a55c9c4ae6634743391b0fe9 | [
"MIT"
] | 1 | 2022-03-05T06:54:11.000Z | 2022-03-05T06:54:11.000Z | """
William DUong
"""
import os.path as osp
import os
import errno
from .build import DATASET_REGISTRY
from .base_dataset import Datum, DatasetBase,EEGDatum
from scipy.io import loadmat
import numpy as np
from collections import defaultdict
| 45.032836 | 166 | 0.65173 |
e45ad99677d6577af2671852ef4f62636067fd15 | 9,321 | py | Python | pywolf3d/level_editor/app.py | jammers-ach/pywolf3d | 3e305d7bdb9aa4f38ae5cf460ed22c54efe8980c | [
"MIT"
] | null | null | null | pywolf3d/level_editor/app.py | jammers-ach/pywolf3d | 3e305d7bdb9aa4f38ae5cf460ed22c54efe8980c | [
"MIT"
] | null | null | null | pywolf3d/level_editor/app.py | jammers-ach/pywolf3d | 3e305d7bdb9aa4f38ae5cf460ed22c54efe8980c | [
"MIT"
] | null | null | null | import argparse
import json
from ursina import load_texture, Ursina, Entity, color, camera, Quad, mouse, time, window, invoke, WindowPanel, \
Text, InputField, Space, scene, Button, Draggable, Tooltip, Scrollable
from pywolf3d.games.wolf3d import WALL_DEFS, WallDef, OBJECT_DEFS
Z_GRID = 0
Z_OBJECT = 2
Z_WALL = 3... | 29.590476 | 122 | 0.55037 |
e45ba78572ce87d65bc9fa965f1a8af3685baf94 | 3,404 | py | Python | code/data_mgmt.py | TomDonoghue/EEGparam | a3e747094617479122900688643fa396ecbf8bab | [
"MIT"
] | 8 | 2021-08-17T05:22:40.000Z | 2022-03-23T02:03:48.000Z | code/data_mgmt.py | TomDonoghue/EEGparam | a3e747094617479122900688643fa396ecbf8bab | [
"MIT"
] | 1 | 2020-12-09T13:22:03.000Z | 2021-01-27T01:56:09.000Z | code/data_mgmt.py | TomDonoghue/EEGparam | a3e747094617479122900688643fa396ecbf8bab | [
"MIT"
] | 4 | 2021-06-20T14:44:38.000Z | 2021-12-11T11:21:26.000Z | """Functions for loading and data management for EEG-FOOOF."""
from os.path import join as pjoin
import numpy as np
from fooof import FOOOFGroup
from fooof.analysis import get_band_peak_fg
from settings import BANDS, YNG_INDS, OLD_INDS, N_LOADS, N_SUBJS, N_TIMES
####################################################... | 35.831579 | 99 | 0.623384 |
e45c0f05cdc7fe7a2e45a2f57230877bc9ba6968 | 413 | py | Python | match_shapes.py | KyojiOsada/Python-Library | b06e50454c56c84c2abb96e6f68d35117ea5f4b5 | [
"Apache-2.0"
] | null | null | null | match_shapes.py | KyojiOsada/Python-Library | b06e50454c56c84c2abb96e6f68d35117ea5f4b5 | [
"Apache-2.0"
] | null | null | null | match_shapes.py | KyojiOsada/Python-Library | b06e50454c56c84c2abb96e6f68d35117ea5f4b5 | [
"Apache-2.0"
] | null | null | null | import sys
import cv2
import numpy as np
img1 = cv2.imread('source1.jpg',0)
img2 = cv2.imread('source2.jpg',0)
ret, thresh = cv2.threshold(img1, 127, 255,0)
ret, thresh2 = cv2.threshold(img2, 127, 255,0)
contours,hierarchy,a = cv2.findContours(thresh,2,1)
cnt1 = contours[0]
contours,hierarchy,a = cv2.findContours(th... | 20.65 | 52 | 0.72155 |
e45c3482ede83aa24d104869dacc8d42f601273f | 25,556 | py | Python | SlicerModules/SegmentConnectedParzenPDF/SegmentConnectedParzenPDF.py | jcfr/TubeTK | 3791790e206b5627a35c46f86eeb9671c8d4190f | [
"Apache-2.0"
] | 1 | 2019-07-19T09:27:37.000Z | 2019-07-19T09:27:37.000Z | SlicerModules/SegmentConnectedParzenPDF/SegmentConnectedParzenPDF.py | jcfr/TubeTK | 3791790e206b5627a35c46f86eeb9671c8d4190f | [
"Apache-2.0"
] | null | null | null | SlicerModules/SegmentConnectedParzenPDF/SegmentConnectedParzenPDF.py | jcfr/TubeTK | 3791790e206b5627a35c46f86eeb9671c8d4190f | [
"Apache-2.0"
] | 1 | 2019-07-19T09:28:56.000Z | 2019-07-19T09:28:56.000Z | import os
from __main__ import vtk, qt, ctk, slicer
import EditorLib
from EditorLib.EditOptions import HelpButton
from EditorLib.EditOptions import EditOptions
from EditorLib import EditUtil
from EditorLib import LabelEffect
#
# EditorEffectTemplateTool
#
#
# EditorEffectTemplateLogic
#
#
# The InteractiveConnecte... | 44.138169 | 292 | 0.755204 |
e45d9ac1d7f7347063075b259a658688aa945eb7 | 415 | py | Python | category/urls.py | amin-bahiraei-75/shop_back | afcc5907fe33de2db1615f14df71443d1a35bbd0 | [
"MIT"
] | 1 | 2021-12-24T15:20:37.000Z | 2021-12-24T15:20:37.000Z | category/urls.py | amin-bahiraei-75/shop_back | afcc5907fe33de2db1615f14df71443d1a35bbd0 | [
"MIT"
] | null | null | null | category/urls.py | amin-bahiraei-75/shop_back | afcc5907fe33de2db1615f14df71443d1a35bbd0 | [
"MIT"
] | null | null | null | from django.urls import path
from category.views import List,Detail,Create,Delete,Update,Search,All
urlpatterns = [
path('all',All.as_view()),
path('list/<int:pk>',List.as_view()),
path('search/<str:pk>',Search.as_view()),
path('detail/<int:pk>',Detail.as_view()),
path('create', Create.as_view()),
... | 34.583333 | 70 | 0.653012 |
e460d64b915b9a1607000858e70b226926b3124a | 3,488 | py | Python | led_motor_switch.py | scarmel/iot-demo | 02c6d810098720803196bf32ee1780925011f57c | [
"Apache-2.0"
] | null | null | null | led_motor_switch.py | scarmel/iot-demo | 02c6d810098720803196bf32ee1780925011f57c | [
"Apache-2.0"
] | null | null | null | led_motor_switch.py | scarmel/iot-demo | 02c6d810098720803196bf32ee1780925011f57c | [
"Apache-2.0"
] | null | null | null | # ------------------------------------------
# Description: This python script will update AWS Thing Shadow for a Device/Thing
# ------------------------------------------
# Import package
import paho.mqtt.client as mqtt
import ssl, time, sys
# =======================================================
# Set Following V... | 32.90566 | 119 | 0.65539 |
e462bb80e8e5cfe48f10d58ffcdefb6c7a4fc2ec | 680 | py | Python | test.py | jsayles/LPD8806 | 6f13b65ae92f3bd903df684459964b8f5f621942 | [
"MIT"
] | null | null | null | test.py | jsayles/LPD8806 | 6f13b65ae92f3bd903df684459964b8f5f621942 | [
"MIT"
] | null | null | null | test.py | jsayles/LPD8806 | 6f13b65ae92f3bd903df684459964b8f5f621942 | [
"MIT"
] | null | null | null | import time
from lightpi.hardware import strip, string1, string2
DELAY_SEC = 0.3
# Test the RGB Strip
strip.red()
time.sleep(DELAY_SEC)
strip.green()
time.sleep(DELAY_SEC)
strip.blue()
time.sleep(DELAY_SEC)
strip.off()
# Test the LED Strings
string1.on()
time.sleep(DELAY_SEC)
string1.off()
time.sleep(DELAY_SEC)
st... | 17.435897 | 80 | 0.535294 |
e4634c0a0adb3cc0d16bbbb61f40f718de94ef2b | 3,141 | py | Python | wind_direction.py | simseve/weatherstation | 68196a032a2cd39062f3924ce6d386f5f54af393 | [
"MIT"
] | null | null | null | wind_direction.py | simseve/weatherstation | 68196a032a2cd39062f3924ce6d386f5f54af393 | [
"MIT"
] | null | null | null | wind_direction.py | simseve/weatherstation | 68196a032a2cd39062f3924ce6d386f5f54af393 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# wind_direction.py
#
# Copyright 2020 <Simone Severini>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the Licen... | 27.313043 | 71 | 0.561605 |
e4639c8948f8a93b0256a4c34b5d407b8adc42bc | 3,875 | py | Python | oswin_tempest_plugin/tests/_mixins/migrate.py | openstack/oswin-tempest-plugin | 59e6a14d01dda304c7d11fda1d35198f25799d6c | [
"Apache-2.0"
] | 6 | 2017-10-31T10:40:24.000Z | 2019-01-28T22:08:15.000Z | oswin_tempest_plugin/tests/_mixins/migrate.py | openstack/oswin-tempest-plugin | 59e6a14d01dda304c7d11fda1d35198f25799d6c | [
"Apache-2.0"
] | null | null | null | oswin_tempest_plugin/tests/_mixins/migrate.py | openstack/oswin-tempest-plugin | 59e6a14d01dda304c7d11fda1d35198f25799d6c | [
"Apache-2.0"
] | null | null | null | # Copyright 2017 Cloudbase Solutions SRL
# 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 r... | 35.87963 | 79 | 0.659613 |
e466a39aa7123e6924bb036424ddce439a785489 | 2,572 | py | Python | articulation_structure/nodes/process_bags.py | tum-vision/articulation | 3bb714fcde14b8d47977bd3b3da2c2cd13ebe685 | [
"BSD-2-Clause"
] | 3 | 2017-03-15T16:50:05.000Z | 2021-02-28T05:27:24.000Z | articulation_structure/nodes/process_bags.py | AbdelrahmanElsaid/articulation | 3bb714fcde14b8d47977bd3b3da2c2cd13ebe685 | [
"BSD-2-Clause"
] | null | null | null | articulation_structure/nodes/process_bags.py | AbdelrahmanElsaid/articulation | 3bb714fcde14b8d47977bd3b3da2c2cd13ebe685 | [
"BSD-2-Clause"
] | 7 | 2015-07-14T14:47:51.000Z | 2018-04-02T16:22:23.000Z | #!/usr/bin/python
import rospy
import rosbag
import time
| 25.72 | 84 | 0.66563 |
e468b2b5e8f04b80c414c4137b991f429ffae653 | 2,508 | py | Python | kedro/extras/logging/color_logger.py | daniel-falk/kedro | 19187199339ddc4a757aaaa328f319ec4c1e452a | [
"Apache-2.0"
] | 2,047 | 2022-01-10T15:22:12.000Z | 2022-03-31T13:38:56.000Z | kedro/extras/logging/color_logger.py | daniel-falk/kedro | 19187199339ddc4a757aaaa328f319ec4c1e452a | [
"Apache-2.0"
] | 170 | 2022-01-10T12:44:31.000Z | 2022-03-31T17:01:24.000Z | kedro/extras/logging/color_logger.py | daniel-falk/kedro | 19187199339ddc4a757aaaa328f319ec4c1e452a | [
"Apache-2.0"
] | 112 | 2022-01-10T19:15:24.000Z | 2022-03-30T11:20:52.000Z | """A logging handler class which produces coloured logs."""
import logging
import click
| 26.125 | 74 | 0.548644 |
e46b6c69ae3a4c3f1fee528d4d729291bff4cf8d | 1,468 | py | Python | qt_figure.py | liwenlongonly/LogAnalyzer | 4981c0673cf0d1a52ad76e473ffc1c30bb6bf22b | [
"Apache-2.0"
] | null | null | null | qt_figure.py | liwenlongonly/LogAnalyzer | 4981c0673cf0d1a52ad76e473ffc1c30bb6bf22b | [
"Apache-2.0"
] | null | null | null | qt_figure.py | liwenlongonly/LogAnalyzer | 4981c0673cf0d1a52ad76e473ffc1c30bb6bf22b | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
from PyQt5 import QtCore
import numpy as np
from matplotlib.figure import Figure
import time
import matplotlib
matplotlib.use("Qt5Agg") # QT5
from matplotlib.backends.backend_qt5agg import FigureCanvasQTAgg as FigureCanvas
| 32.622222 | 83 | 0.636921 |
e46c1072625294f177cc250fe85584da3ad9a985 | 124,267 | py | Python | python/target_selection/cartons/bhm_spiders_agn.py | sdss/target_selection | 7196bf1491c4e9c18140301c7001e503f391a8e1 | [
"BSD-3-Clause"
] | 3 | 2020-07-07T01:38:59.000Z | 2020-11-24T21:46:58.000Z | python/target_selection/cartons/bhm_spiders_agn.py | sdss/target_selection | 7196bf1491c4e9c18140301c7001e503f391a8e1 | [
"BSD-3-Clause"
] | 26 | 2020-05-28T07:18:54.000Z | 2021-11-30T18:36:10.000Z | python/target_selection/cartons/bhm_spiders_agn.py | sdss/target_selection | 7196bf1491c4e9c18140301c7001e503f391a8e1 | [
"BSD-3-Clause"
] | null | null | null | #!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# @Author: Tom Dwelly
# @Date: 2020-03-03
# @Filename: bhm_spiders_agn.py
# @License: BSD 3-clause (http://www.opensource.org/licenses/BSD-3-Clause)
# derived from guide.py
# ### flake8: noqa
# isort: skip_file
import peewee
from peewee import JOIN
from peewee import fn... | 41.325906 | 388 | 0.500036 |
e47016cbd72e7098c0941f4e47d79ce1b7c698d1 | 776 | py | Python | back-end/erasmail/emails/migrations/0038_auto_20210422_0059.py | SamirM-BE/ErasMail | 88602a039ae731ca8566c96c7c4d2635f82a07a5 | [
"Apache-2.0"
] | 7 | 2021-02-06T21:06:23.000Z | 2022-01-31T09:33:26.000Z | back-end/erasmail/emails/migrations/0038_auto_20210422_0059.py | SamirM-BE/ErasMail | 88602a039ae731ca8566c96c7c4d2635f82a07a5 | [
"Apache-2.0"
] | null | null | null | back-end/erasmail/emails/migrations/0038_auto_20210422_0059.py | SamirM-BE/ErasMail | 88602a039ae731ca8566c96c7c4d2635f82a07a5 | [
"Apache-2.0"
] | 5 | 2021-05-07T15:35:25.000Z | 2022-03-21T09:11:24.000Z | # Generated by Django 3.1.6 on 2021-04-22 00:59
from django.db import migrations, models
| 28.740741 | 117 | 0.619845 |
e4705f3acb58336e0e7ad1a046d3910433815d04 | 1,488 | py | Python | worldmap/src/worldmap/model/dtm.py | expertanalytics/fagkveld | 96e16b9610e8b60d36425e7bc5435d266de1f8bf | [
"BSD-2-Clause"
] | null | null | null | worldmap/src/worldmap/model/dtm.py | expertanalytics/fagkveld | 96e16b9610e8b60d36425e7bc5435d266de1f8bf | [
"BSD-2-Clause"
] | null | null | null | worldmap/src/worldmap/model/dtm.py | expertanalytics/fagkveld | 96e16b9610e8b60d36425e7bc5435d266de1f8bf | [
"BSD-2-Clause"
] | null | null | null | """
Data terrain model (DTM).
Examples::
>>> from worldmap import DTM
>>> dtm = DTM()
>>> print(dtm["NOR"])
Location('Norway')
"""
from typing import Dict, List, Tuple, Set, Optional
from bokeh.models import Model
from bokeh.models import ColumnDataSource, Patches, LabelSet
import logging
import num... | 25.220339 | 74 | 0.638441 |
e4710ca29b9a5a6a2747143e02042c64942aa376 | 1,865 | py | Python | src/blockchain/crypto_tools/__init__.py | ParisNeo/blockchain | 8bc2768a3e89088e202ea89e5f301576f6f9d95c | [
"MIT"
] | null | null | null | src/blockchain/crypto_tools/__init__.py | ParisNeo/blockchain | 8bc2768a3e89088e202ea89e5f301576f6f9d95c | [
"MIT"
] | null | null | null | src/blockchain/crypto_tools/__init__.py | ParisNeo/blockchain | 8bc2768a3e89088e202ea89e5f301576f6f9d95c | [
"MIT"
] | null | null | null | """
"""
from Crypto.PublicKey import RSA
from Crypto.Hash import SHA256
from Crypto.Signature import PKCS1_v1_5
from base58 import b58encode, b58decode
# ================= cryptography helpers ======================================
def hash(data):
"""Hash some data
"""
# Hash the stuff we need to hash
... | 26.267606 | 92 | 0.642895 |
e472ad25bd9133e0e1fe623219e0826f24f2f7ef | 365 | py | Python | Mandelbrot fractal/visualize.py | TTimerkhanov/parallel_computing | 75c79a4e50ac2f5f9fab90cd79560cd8e848228e | [
"MIT"
] | 8 | 2018-03-21T12:26:44.000Z | 2019-10-05T08:46:20.000Z | Mandelbrot fractal/visualize.py | TTimerkhanov/parallel_computing | 75c79a4e50ac2f5f9fab90cd79560cd8e848228e | [
"MIT"
] | null | null | null | Mandelbrot fractal/visualize.py | TTimerkhanov/parallel_computing | 75c79a4e50ac2f5f9fab90cd79560cd8e848228e | [
"MIT"
] | null | null | null | import numpy as np
import matplotlib.pyplot as plt
mandelbrot(120, 6000) | 22.8125 | 48 | 0.60274 |
e472f3485c0e5680d2198a1ae932c5d7712b5057 | 19,303 | py | Python | tools/unit_tests/test_config_transforms.py | dice-project/DICE-deployment-service | e209c6a061a78f170e81cfc03d2959af0283ed15 | [
"Apache-2.0"
] | 2 | 2018-04-03T20:45:26.000Z | 2022-02-07T19:53:42.000Z | tools/unit_tests/test_config_transforms.py | dice-project/DICE-deployment-service | e209c6a061a78f170e81cfc03d2959af0283ed15 | [
"Apache-2.0"
] | 3 | 2016-11-15T10:41:43.000Z | 2020-03-16T07:49:03.000Z | tools/unit_tests/test_config_transforms.py | dice-project/DICE-deployment-service | e209c6a061a78f170e81cfc03d2959af0283ed15 | [
"Apache-2.0"
] | 2 | 2018-07-04T11:37:12.000Z | 2022-02-07T19:53:43.000Z | import unittest
import copy
import os
import tempfile
from config_tool.utils import *
if __name__ == '__main__':
unittest.main()
| 38.528942 | 80 | 0.600425 |
e47311462a03c6a7eb9b40addcc16befdf99f631 | 2,133 | py | Python | code/venv/lib/python3.8/site-packages/datadog_api_client/v2/model/permission_attributes.py | Valisback/hiring-engineers | 7196915dd5a429ae27c21fa43d527f0332e662ed | [
"Apache-2.0"
] | null | null | null | code/venv/lib/python3.8/site-packages/datadog_api_client/v2/model/permission_attributes.py | Valisback/hiring-engineers | 7196915dd5a429ae27c21fa43d527f0332e662ed | [
"Apache-2.0"
] | null | null | null | code/venv/lib/python3.8/site-packages/datadog_api_client/v2/model/permission_attributes.py | Valisback/hiring-engineers | 7196915dd5a429ae27c21fa43d527f0332e662ed | [
"Apache-2.0"
] | null | null | null | # Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License.
# This product includes software developed at Datadog (https://www.datadoghq.com/).
# Copyright 2019-Present Datadog, Inc.
from datadog_api_client.v2.model_utils import (
ModelNormal,
cached_property,
... | 30.042254 | 108 | 0.61369 |
e4751dd89498b1da7109ee5f07994f5fbd04447a | 95 | py | Python | vulture/whitelists/logging_whitelist.py | kianmeng/vulture | b8cbc44dac89b2a96f6da7033424f52525d6f574 | [
"MIT"
] | 2,081 | 2017-03-06T14:45:21.000Z | 2022-03-31T13:29:34.000Z | vulture/whitelists/logging_whitelist.py | kianmeng/vulture | b8cbc44dac89b2a96f6da7033424f52525d6f574 | [
"MIT"
] | 248 | 2017-03-06T12:13:37.000Z | 2022-03-15T11:21:27.000Z | vulture/whitelists/logging_whitelist.py | kianmeng/vulture | b8cbc44dac89b2a96f6da7033424f52525d6f574 | [
"MIT"
] | 111 | 2017-03-06T20:48:04.000Z | 2022-03-17T09:49:32.000Z | import logging
logging.Filter.filter
logging.getLogger().propagate
logging.StreamHandler.emit
| 15.833333 | 29 | 0.852632 |
e479315b2fec6b1b30374526a8f3ec4a57556364 | 536 | py | Python | tests/test_set_key.py | GustavoKatel/pushbullet-cli | e5102772752a97db539594b0d50b5effb36a22e2 | [
"MIT"
] | 176 | 2017-01-30T16:21:48.000Z | 2022-02-10T05:32:57.000Z | tests/test_set_key.py | GustavoKatel/pushbullet-cli | e5102772752a97db539594b0d50b5effb36a22e2 | [
"MIT"
] | 49 | 2017-01-21T20:27:03.000Z | 2022-01-16T02:57:51.000Z | tests/test_set_key.py | GustavoKatel/pushbullet-cli | e5102772752a97db539594b0d50b5effb36a22e2 | [
"MIT"
] | 21 | 2017-01-26T06:08:54.000Z | 2022-01-04T19:53:25.000Z | import platform
import pytest
| 25.52381 | 73 | 0.673507 |
e4797fdc0550e8c83ce7e94b28483dfdbf77d5d3 | 344 | py | Python | 02. Programacion estructurada/05. datos tupla/e1.py | Cidryl/python-desde-cero | fade09d13ab0ed0cbb4f45a49a4ad9e3980f3276 | [
"MIT"
] | null | null | null | 02. Programacion estructurada/05. datos tupla/e1.py | Cidryl/python-desde-cero | fade09d13ab0ed0cbb4f45a49a4ad9e3980f3276 | [
"MIT"
] | null | null | null | 02. Programacion estructurada/05. datos tupla/e1.py | Cidryl/python-desde-cero | fade09d13ab0ed0cbb4f45a49a4ad9e3980f3276 | [
"MIT"
] | null | null | null |
# bloque principal
fecha=cargar_fecha()
imprimir_fecha(fecha) | 22.933333 | 46 | 0.639535 |
e47c17dddcd00889d223b3d8fce4a9d9c3d285a3 | 356 | py | Python | doingmathwithpython/ch03.py | andyliumathematics/mlnotes | 7b7a1c37d7660bdf9144c59693719033080d654b | [
"Apache-2.0"
] | null | null | null | doingmathwithpython/ch03.py | andyliumathematics/mlnotes | 7b7a1c37d7660bdf9144c59693719033080d654b | [
"Apache-2.0"
] | null | null | null | doingmathwithpython/ch03.py | andyliumathematics/mlnotes | 7b7a1c37d7660bdf9144c59693719033080d654b | [
"Apache-2.0"
] | null | null | null | # %%
l = [38,32,49,15,806,806]
sum(l)
# %%
len(l)
# %%
sum(l)//len(l)
# %%
l.sort()
# %%
l
# %%
# %%
l.most_common(1)
# %%
'''
'''
from collections import Counter
l = ['38','32','49','15','806','806']
c = Counter(l)
print(c.most_common()[0][0])
print(c.most_common(1))
print(c.most_common(2))
# %%
c.most_common()[... | 11.483871 | 37 | 0.530899 |
e4813380bf2daa72d111c3321e1a0890661d1b92 | 5,475 | py | Python | CodedCaching/Network.py | qizhu8/CodedCachingSim | 84e8f1e58e1c431ee4916525487d4b28f92e629b | [
"MIT"
] | null | null | null | CodedCaching/Network.py | qizhu8/CodedCachingSim | 84e8f1e58e1c431ee4916525487d4b28f92e629b | [
"MIT"
] | null | null | null | CodedCaching/Network.py | qizhu8/CodedCachingSim | 84e8f1e58e1c431ee4916525487d4b28f92e629b | [
"MIT"
] | null | null | null | """
Network class is in charge of:
1. Storing M - User Cache Size, N - Number of Files, K - Number of Users
2. Storing User instances, Server instance, and attacker instance
"""
import numpy as np
from scipy import special
import itertools
from Server import Server
from User import User
from tabulate import tabulate
... | 36.993243 | 140 | 0.592146 |
e4832a86e7db8f21257aa59834d215a8144ccb1f | 23 | py | Python | protonets/data/__init__.py | sripathisridhar/prototypical-networks | 02a1379dceea896e23ecf21384d4a6ee2393f38c | [
"MIT"
] | 889 | 2017-11-12T22:04:25.000Z | 2022-03-31T09:42:13.000Z | protonets/data/__init__.py | Harzva/prototypical-networks | c9bb4d258267c11cb6e23f0a19242d24ca98ad8a | [
"MIT"
] | 24 | 2017-12-06T19:28:23.000Z | 2021-11-27T11:35:53.000Z | protonets/data/__init__.py | Harzva/prototypical-networks | c9bb4d258267c11cb6e23f0a19242d24ca98ad8a | [
"MIT"
] | 240 | 2017-11-12T22:04:28.000Z | 2022-03-26T09:25:42.000Z | from . import omniglot
| 11.5 | 22 | 0.782609 |
e483e0a6252d9a8ff4f77f42bb3708e55acf3498 | 330 | py | Python | flask/part3_templates/ex3-app/students2.py | macloo/python-beginners | 1124922cd57d3f647eacafa0b82948587514d4bd | [
"MIT"
] | 42 | 2018-03-25T22:41:57.000Z | 2022-01-08T21:23:02.000Z | flask/part3_templates/ex3-app/students2.py | pavanpatil45/python-beginners | 1124922cd57d3f647eacafa0b82948587514d4bd | [
"MIT"
] | null | null | null | flask/part3_templates/ex3-app/students2.py | pavanpatil45/python-beginners | 1124922cd57d3f647eacafa0b82948587514d4bd | [
"MIT"
] | 17 | 2018-03-20T00:56:57.000Z | 2022-01-12T06:36:18.000Z | # two templates are used in this app
from flask import Flask, render_template
app = Flask(__name__)
if __name__ == '__main__':
app.run(debug=True)
| 20.625 | 52 | 0.70303 |
e4884423f1f3c28f1f01d03c9e676127547b57c0 | 250 | py | Python | docs/autodoc_example.py | aio-libs/sphinxcontrib-asyncio | dbfa79e29980e73ad2dd9dec59f1238b1a8a7cd7 | [
"Apache-2.0"
] | 19 | 2016-02-21T13:27:43.000Z | 2020-02-19T17:22:38.000Z | docs/autodoc_example.py | aio-libs/sphinxcontrib-asyncio | dbfa79e29980e73ad2dd9dec59f1238b1a8a7cd7 | [
"Apache-2.0"
] | 9 | 2016-04-15T08:43:39.000Z | 2022-01-06T10:43:08.000Z | docs/autodoc_example.py | aio-libs/sphinxcontrib-asyncio | dbfa79e29980e73ad2dd9dec59f1238b1a8a7cd7 | [
"Apache-2.0"
] | 6 | 2016-04-11T07:32:41.000Z | 2019-09-28T10:59:51.000Z | import asyncio
| 14.705882 | 39 | 0.608 |
e488e12d7b940dac3d9db3e9a5b2cb31258d0310 | 25,266 | py | Python | test/recipe/test_edit_recipe.py | fredsonchaves07/foodfy | 5bff04434749f369f982090b00590cca31fce186 | [
"MIT"
] | null | null | null | test/recipe/test_edit_recipe.py | fredsonchaves07/foodfy | 5bff04434749f369f982090b00590cca31fce186 | [
"MIT"
] | 141 | 2021-03-03T01:38:10.000Z | 2022-01-16T15:42:02.000Z | test/recipe/test_edit_recipe.py | fredsonchaves07/foodfy | 5bff04434749f369f982090b00590cca31fce186 | [
"MIT"
] | null | null | null | import json
from io import BytesIO
from app.ext.api.exceptions import (
ChefNotFound,
InvalidToken,
MaximumImageCapacityError,
OperationNotAllowed,
RecipeWithoutIngredient,
RecipeWithoutPreparationMode,
)
from app.ext.api.services import token_services
| 28.48478 | 87 | 0.566097 |
e4892ccb409c7b541cbd948a9e9898c388a282c5 | 521 | py | Python | survey/migrations/0018_auto_20161128_0936.py | watchdogpolska/ankieta-rodzic-po-ludzku-nfz | 68b1d1ccac969ca51416761d1168678effb1e6c6 | [
"MIT"
] | null | null | null | survey/migrations/0018_auto_20161128_0936.py | watchdogpolska/ankieta-rodzic-po-ludzku-nfz | 68b1d1ccac969ca51416761d1168678effb1e6c6 | [
"MIT"
] | null | null | null | survey/migrations/0018_auto_20161128_0936.py | watchdogpolska/ankieta-rodzic-po-ludzku-nfz | 68b1d1ccac969ca51416761d1168678effb1e6c6 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
# Generated by Django 1.10.3 on 2016-11-28 09:36
from __future__ import unicode_literals
from django.db import migrations, models
| 24.809524 | 122 | 0.610365 |
e48a824fae829e3008efd9a9fbcb0f03d3adc45f | 90 | py | Python | tests/__init__.py | slinksoft/PathExactDelayPrototype | 633576cfe031e8ee884daaa453a3e5d206eaeaa9 | [
"MIT"
] | null | null | null | tests/__init__.py | slinksoft/PathExactDelayPrototype | 633576cfe031e8ee884daaa453a3e5d206eaeaa9 | [
"MIT"
] | null | null | null | tests/__init__.py | slinksoft/PathExactDelayPrototype | 633576cfe031e8ee884daaa453a3e5d206eaeaa9 | [
"MIT"
] | null | null | null | import os
import sys
from pathlib import Path
sys.path.insert(0, 'exactdelaypathfinder')
| 15 | 42 | 0.8 |
e48ba9fc67c09776260edc71cd67600e98eb63a9 | 1,885 | py | Python | 2017/day07/code.py | Fadi88/AoC | 8b24f2f2cc7b4e1c63758e81e63d8670a261cc7c | [
"Unlicense"
] | 12 | 2019-12-15T21:53:19.000Z | 2021-12-24T17:03:41.000Z | 2017/day07/code.py | Fadi88/adventofcode19 | dd2456bdd163beb02dbfe9dcea2b021061c7671e | [
"Unlicense"
] | 1 | 2021-12-15T20:40:51.000Z | 2021-12-15T22:19:48.000Z | 2017/day07/code.py | Fadi88/adventofcode19 | dd2456bdd163beb02dbfe9dcea2b021061c7671e | [
"Unlicense"
] | 5 | 2020-12-11T06:00:24.000Z | 2021-12-20T21:37:46.000Z | import time
from collections import defaultdict
if __name__ == "__main__":
part1()
part2()
| 22.176471 | 83 | 0.490716 |
e48e53ba04ff99bdd6227e182235f811ae1dc4ee | 403 | py | Python | src/microbit/spi-tof-master.py | romilly/multi-VL53L0X | 80cf0d82d93ceae9c54acb967c24a1bf8deb5e3a | [
"MIT"
] | null | null | null | src/microbit/spi-tof-master.py | romilly/multi-VL53L0X | 80cf0d82d93ceae9c54acb967c24a1bf8deb5e3a | [
"MIT"
] | null | null | null | src/microbit/spi-tof-master.py | romilly/multi-VL53L0X | 80cf0d82d93ceae9c54acb967c24a1bf8deb5e3a | [
"MIT"
] | null | null | null | from microbit import *
import struct
from time import sleep
SENSORS = 2
spi.init(baudrate=100000)
while True:
for i in [0, 1]:
print(i, ord(spi_read(i)))
sleep(0.1) | 21.210526 | 45 | 0.652605 |
e48f98c85bda6baa0cc86d71b689b55e8122a390 | 16,653 | py | Python | hasher-matcher-actioner/hmalib/models.py | isabella232/ThreatExchange | 0d07a800bbf25d8541f40b828e2dfd377395af9b | [
"BSD-3-Clause"
] | null | null | null | hasher-matcher-actioner/hmalib/models.py | isabella232/ThreatExchange | 0d07a800bbf25d8541f40b828e2dfd377395af9b | [
"BSD-3-Clause"
] | 1 | 2021-04-19T10:20:43.000Z | 2021-04-19T10:20:43.000Z | hasher-matcher-actioner/hmalib/models.py | isabella232/ThreatExchange | 0d07a800bbf25d8541f40b828e2dfd377395af9b | [
"BSD-3-Clause"
] | null | null | null | # Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved
import datetime
import typing as t
import json
from dataclasses import dataclass, field
from mypy_boto3_dynamodb.service_resource import Table
from boto3.dynamodb.conditions import Attr, Key
"""
Data transfer object classes to be used with dynamod... | 32.273256 | 110 | 0.623311 |
e48fad25c05c483e3b144a00ff76a128d96f4a18 | 89 | py | Python | colossalai/utils/commons/__init__.py | mrriteshranjan/ColossalAI | 0d057a1bae67b915a385be7edab7da83413cb645 | [
"Apache-2.0"
] | null | null | null | colossalai/utils/commons/__init__.py | mrriteshranjan/ColossalAI | 0d057a1bae67b915a385be7edab7da83413cb645 | [
"Apache-2.0"
] | null | null | null | colossalai/utils/commons/__init__.py | mrriteshranjan/ColossalAI | 0d057a1bae67b915a385be7edab7da83413cb645 | [
"Apache-2.0"
] | null | null | null | from .bucket_tensor_copy import BucketizedTensorCopy
__all__ = ['BucketizedTensorCopy']
| 22.25 | 52 | 0.842697 |
e49334330d41dc2dca73dcd98740a04934ce3d79 | 83 | py | Python | DRF-React/appy/apps.py | Preet538-neitzen/LOC-Hackathon | e7bad458ef0069becdba42576f5fe1bfd736678b | [
"MIT"
] | null | null | null | DRF-React/appy/apps.py | Preet538-neitzen/LOC-Hackathon | e7bad458ef0069becdba42576f5fe1bfd736678b | [
"MIT"
] | 8 | 2021-03-19T13:44:46.000Z | 2022-03-12T00:55:03.000Z | DRF-React/appy/apps.py | Preet538-neitzen/LOC-Hackathon | e7bad458ef0069becdba42576f5fe1bfd736678b | [
"MIT"
] | 1 | 2021-02-13T00:16:36.000Z | 2021-02-13T00:16:36.000Z | from django.apps import AppConfig
| 13.833333 | 33 | 0.73494 |
e494747ad6589e1234241f26ac62dacfe6cecd8c | 998 | py | Python | test/test_truss.py | deeepeshthakur/ddtruss | 86aa945d577c6efe752099eee579386762942289 | [
"MIT"
] | 1 | 2020-01-27T12:03:47.000Z | 2020-01-27T12:03:47.000Z | test/test_truss.py | deeepeshthakur/ddtruss | 86aa945d577c6efe752099eee579386762942289 | [
"MIT"
] | null | null | null | test/test_truss.py | deeepeshthakur/ddtruss | 86aa945d577c6efe752099eee579386762942289 | [
"MIT"
] | null | null | null | import numpy as np
import pytest
from ddtruss import Truss, DataDrivenSolver
points = np.array([[0, 0], [1, 0], [0.5, 0.5], [2, 1]])
lines = np.array([[0, 2], [1, 2], [1, 3], [2, 3]], dtype=int)
truss = Truss(points, lines)
E = 1.962e11
A = [2e-4, 2e-4, 1e-4, 1e-4]
U_dict = {0: [0, 0], 1: [0, 0]}
F_dict = {3: [0, -... | 24.95 | 77 | 0.621242 |
e494dbf6ede35cd65a3c40c381a319f33cf3e78d | 2,563 | py | Python | app/models.py | MilanMathew/machine_test_focaloid | fa179e655c531825167e97aed4e2d6affea9c736 | [
"MIT"
] | null | null | null | app/models.py | MilanMathew/machine_test_focaloid | fa179e655c531825167e97aed4e2d6affea9c736 | [
"MIT"
] | null | null | null | app/models.py | MilanMathew/machine_test_focaloid | fa179e655c531825167e97aed4e2d6affea9c736 | [
"MIT"
] | null | null | null | from datetime import datetime
from app import db
| 37.144928 | 71 | 0.684354 |
e49516ca8ad700f85017d9325736d77d5ccd8a3d | 2,326 | py | Python | PTO-yelp/Modules/attention_classifier.py | LegendTianjin/Point-Then-Operate | a6b0818343bc34c468738ab91ecea89dd03a9535 | [
"Apache-2.0"
] | 50 | 2019-06-06T05:30:32.000Z | 2021-11-18T07:24:36.000Z | PTO-yelp/Modules/attention_classifier.py | lancopku/Point-Then-Operate | 1c04ec326b52fc65f97f5610a6f16f6e938d583e | [
"Apache-2.0"
] | 2 | 2019-08-30T09:49:26.000Z | 2020-01-17T04:20:53.000Z | PTO-yelp/Modules/attention_classifier.py | ChenWu98/Point-Then-Operate | a6b0818343bc34c468738ab91ecea89dd03a9535 | [
"Apache-2.0"
] | 7 | 2019-06-17T06:20:47.000Z | 2020-10-26T03:19:44.000Z | import os
import numpy as np
import torch
import torch.nn as nn
import torch.nn.functional as F
from torch.autograd import Variable
from utils.utils import gpu_wrapper
from Modules.subModules.attention import AttentionUnit
from torch.nn.utils.rnn import pack_padded_sequence as pack
from torch.nn.utils.rnn import pad_pa... | 41.535714 | 136 | 0.564488 |
e4954d56f09841ccf54e7784967df8b418345b0e | 569 | py | Python | minion/parser.py | timofurrer/minion-ci | 411d0ea6638fb37d7e170cc8c8c5815304cc9f5c | [
"MIT"
] | 49 | 2016-03-07T06:42:40.000Z | 2021-03-06T02:43:02.000Z | minion/parser.py | timofurrer/minion-ci | 411d0ea6638fb37d7e170cc8c8c5815304cc9f5c | [
"MIT"
] | 16 | 2016-03-08T07:20:52.000Z | 2017-04-21T18:15:12.000Z | minion/parser.py | timofurrer/minion-ci | 411d0ea6638fb37d7e170cc8c8c5815304cc9f5c | [
"MIT"
] | 9 | 2016-03-29T22:08:52.000Z | 2021-06-16T16:29:30.000Z | """
`minion-ci` is a minimalist, decentralized, flexible Continuous Integration Server for hackers.
This module contains the parser to parse the `minion.yml` file.
:copyright: (c) by Timo Furrer
:license: MIT, see LICENSE for details
"""
import yaml
from .errors import MinionError
def parse(path):... | 24.73913 | 99 | 0.681898 |
e49a3917364c39b81a8dd470087dc69990edf5b7 | 1,431 | py | Python | finace/utils/rong_city.py | pythonyhd/finace | 614d98ad92e1bbaa6cf7dc1d6dfaba4f24431688 | [
"Apache-2.0"
] | 1 | 2020-08-18T01:55:14.000Z | 2020-08-18T01:55:14.000Z | finace/utils/rong_city.py | pythonyhd/finace | 614d98ad92e1bbaa6cf7dc1d6dfaba4f24431688 | [
"Apache-2.0"
] | null | null | null | finace/utils/rong_city.py | pythonyhd/finace | 614d98ad92e1bbaa6cf7dc1d6dfaba4f24431688 | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
from pymongo import MongoClient
from finace import settings
if __name__ == '__main__':
spider = SpiderCity()
url_list = spider.get()
print(url_list) | 26.018182 | 110 | 0.583508 |
e49b044e4f3bdfef09e6426d0ff3c5f755aa63ae | 1,464 | py | Python | bufflog/bufflog.py | bufferapp/python-bufflog | 12d218dfb917419789c720fb1851a35708909810 | [
"MIT"
] | null | null | null | bufflog/bufflog.py | bufferapp/python-bufflog | 12d218dfb917419789c720fb1851a35708909810 | [
"MIT"
] | null | null | null | bufflog/bufflog.py | bufferapp/python-bufflog | 12d218dfb917419789c720fb1851a35708909810 | [
"MIT"
] | 1 | 2021-02-08T12:53:43.000Z | 2021-02-08T12:53:43.000Z | import structlog
import logging
import sys
import os
from structlog.processors import JSONRenderer
from structlog.stdlib import filter_by_level
from structlog.stdlib import add_log_level_number
from .datadog import tracer_injection
LOG_LEVEL = os.getenv("LOG_LEVEL", "INFO")
| 24.4 | 57 | 0.705601 |
e49cb572bd1c712b03397fca3826c3ed98801ce6 | 990 | py | Python | templator.py | daren-thomas/template-system-example | 248d2f78392be826f3223ee27e90c82feb70a17a | [
"MIT"
] | null | null | null | templator.py | daren-thomas/template-system-example | 248d2f78392be826f3223ee27e90c82feb70a17a | [
"MIT"
] | null | null | null | templator.py | daren-thomas/template-system-example | 248d2f78392be826f3223ee27e90c82feb70a17a | [
"MIT"
] | null | null | null | """
templator.py reads in an excel file and a template and outputs a file for each row
in the excel file, by substituting the template variables with the values in the columns.
This technique uses pandas to read the excel file into a DataFrame and the python format operator ``%```
to apply the values.
"""
import sys
... | 34.137931 | 104 | 0.706061 |
e4a25083351a643d4c8f2b90bb9ef5552f4ba55d | 483 | py | Python | src/stackoverflow/56339991/tests.py | mrdulin/python-codelab | 3d960a14a96b3a673b7dc2277d202069b1f8e778 | [
"MIT"
] | null | null | null | src/stackoverflow/56339991/tests.py | mrdulin/python-codelab | 3d960a14a96b3a673b7dc2277d202069b1f8e778 | [
"MIT"
] | null | null | null | src/stackoverflow/56339991/tests.py | mrdulin/python-codelab | 3d960a14a96b3a673b7dc2277d202069b1f8e778 | [
"MIT"
] | 3 | 2020-02-19T08:02:04.000Z | 2021-06-08T13:27:51.000Z | import unittest
from test_base import TestBaseImporter
from test_child import TestChildImporter
if __name__ == '__main__':
test_loader = unittest.TestLoader()
test_classes_to_run = [TestBaseImporter, TestChildImporter]
suites_list = []
for test_class in test_classes_to_run:
suite = test_loader... | 30.1875 | 63 | 0.766046 |
e4a318b6cae44face6ae5927fa38829adbecfa61 | 1,015 | py | Python | src/mains/test_tf.py | JungleEngine/Intelligent_Frame_Skipping_Network | 8178acfe06e112f5d33acbd17ad33239a6c4afc2 | [
"MIT"
] | null | null | null | src/mains/test_tf.py | JungleEngine/Intelligent_Frame_Skipping_Network | 8178acfe06e112f5d33acbd17ad33239a6c4afc2 | [
"MIT"
] | null | null | null | src/mains/test_tf.py | JungleEngine/Intelligent_Frame_Skipping_Network | 8178acfe06e112f5d33acbd17ad33239a6c4afc2 | [
"MIT"
] | null | null | null | # import tensorflow as tf
# print(tf.__version__)
#
#
# with tf.name_scope('scalar_set_one') as scope:
# tf_constant_one = tf.constant(10, name="ten")
# tf_constant_two = tf.constant(20, name="twenty")
# scalar_sum_one = tf.add(tf_constant_one, tf_constant_two, name="scalar_ten_plus_twenty")
#
#
#
# with tf... | 27.432432 | 100 | 0.719212 |
e4a3bd3abdfaed582c987ca4af954c061d659067 | 24,952 | py | Python | src/menus/user/Menu.py | stregea/TransactionTrackr | c38b99d56816becaa47a21400fb20c615d3483ef | [
"MIT"
] | 2 | 2021-07-02T19:49:24.000Z | 2021-07-08T02:59:25.000Z | src/menus/user/Menu.py | stregea/TransactionTrackr | c38b99d56816becaa47a21400fb20c615d3483ef | [
"MIT"
] | null | null | null | src/menus/user/Menu.py | stregea/TransactionTrackr | c38b99d56816becaa47a21400fb20c615d3483ef | [
"MIT"
] | null | null | null | from objects.user.User import User
from objects.interface.dbconn import DB
from objects.user.Currency import get_currency_symbol
from objects.threads.UploadThread import UploadThread
import utils.globals as _globals
from utils.print import print_message, print_error
from utils.enums import Months, SettingsSelection, is... | 42.726027 | 142 | 0.631412 |
e4a69e3428e588c7d00739ddb17751edb51f6451 | 1,717 | py | Python | website/CookieHelper.py | sousic/flask.huny.kr | 53a8f5af1fa63b290a4e97278a86328758e97d43 | [
"MIT"
] | null | null | null | website/CookieHelper.py | sousic/flask.huny.kr | 53a8f5af1fa63b290a4e97278a86328758e97d43 | [
"MIT"
] | null | null | null | website/CookieHelper.py | sousic/flask.huny.kr | 53a8f5af1fa63b290a4e97278a86328758e97d43 | [
"MIT"
] | null | null | null | # -*- coding: UTF-8 -*-
import base64
from functools import wraps
import pyaes
from flask import request
from werkzeug.utils import redirect
from website.domain.UserVO import UserVO
| 28.616667 | 90 | 0.594059 |
e4a6e1bb797c7875ed388c77bf15d0c26b3189cb | 3,652 | py | Python | export_resized_ios_assets.py | Tubbebubbe/gimp-plugins | 11221ded072d8d3001202f30fda266e0cccd3a36 | [
"MIT"
] | 4 | 2016-08-03T18:20:59.000Z | 2020-05-24T04:38:47.000Z | export_resized_ios_assets.py | Tubbebubbe/gimp-plugins | 11221ded072d8d3001202f30fda266e0cccd3a36 | [
"MIT"
] | null | null | null | export_resized_ios_assets.py | Tubbebubbe/gimp-plugins | 11221ded072d8d3001202f30fda266e0cccd3a36 | [
"MIT"
] | 2 | 2017-10-23T08:23:36.000Z | 2020-05-24T04:38:57.000Z | #!/usr/bin/env python
"""
export_resized_ios_images
Gimp plugin to export image to icon files usable on iOS.
Author:
-------
Tobias Blom, Techne Development AB <tobias.blom@techne-dev.se>
Installation:
-------------
Under Mac OS X, copy this file to ~/Library/Application Support/GIMP/x.x/plug-ins and
make it exec... | 33.504587 | 85 | 0.659639 |
e4a86bcd74faf3a16d79362c4832a1d23917c50f | 3,696 | py | Python | SortingComparison.py | kogol99/MSiD | bbe0ee535f785476a3fe75f0654f496c185565e4 | [
"MIT"
] | null | null | null | SortingComparison.py | kogol99/MSiD | bbe0ee535f785476a3fe75f0654f496c185565e4 | [
"MIT"
] | 10 | 2020-03-15T20:17:04.000Z | 2020-06-05T01:58:35.000Z | SortingComparison.py | kogol99/MSiD | bbe0ee535f785476a3fe75f0654f496c185565e4 | [
"MIT"
] | 37 | 2020-03-15T17:30:40.000Z | 2020-04-11T20:16:28.000Z | from timeit import default_timer as timer
import random
# shell sort using Knuth's sequence
if __name__ == "__main__":
main()
| 33.297297 | 103 | 0.619048 |
e4a93421928eb84ea60e2492daf9f320c6c9d564 | 8,417 | py | Python | site/office/compline.py | scottBowles/dailyoffice2019 | ca750ac77316d247ca7a7a820e085f9968fbc8ff | [
"MIT"
] | 19 | 2020-01-12T23:57:22.000Z | 2022-03-30T16:35:17.000Z | site/office/compline.py | scottBowles/dailyoffice2019 | ca750ac77316d247ca7a7a820e085f9968fbc8ff | [
"MIT"
] | 59 | 2020-01-13T00:45:27.000Z | 2022-02-20T04:10:05.000Z | site/office/compline.py | scottBowles/dailyoffice2019 | ca750ac77316d247ca7a7a820e085f9968fbc8ff | [
"MIT"
] | 7 | 2020-01-21T21:12:03.000Z | 2021-10-24T01:15:50.000Z | import datetime
from django.utils.functional import cached_property
from django.utils.safestring import mark_safe
from office.offices import Office, OfficeSection
from psalter.utils import get_psalms
| 43.386598 | 345 | 0.640489 |
e4a98810c99783995caf35d9ff70ccf375552008 | 1,735 | py | Python | src/tide_constituents/water_level_prediction.py | slawler/SI_2019_Coastal | 4064d323bc62ce2f47a7af41b9a11ea5538ad181 | [
"MIT"
] | 1 | 2020-03-13T07:51:44.000Z | 2020-03-13T07:51:44.000Z | src/tide_constituents/water_level_prediction.py | cheginit/SI_2019_Coastal | 4064d323bc62ce2f47a7af41b9a11ea5538ad181 | [
"MIT"
] | null | null | null | src/tide_constituents/water_level_prediction.py | cheginit/SI_2019_Coastal | 4064d323bc62ce2f47a7af41b9a11ea5538ad181 | [
"MIT"
] | 1 | 2020-03-13T14:44:57.000Z | 2020-03-13T14:44:57.000Z | import tide_constituents as tc
from py_noaa import coops
import pandas as pd
import numpy as np
import tappy
start = '20180201'
end = '20180228'
interval = 1
start = pd.to_datetime(start)
end = pd.to_datetime(end)
d = start
w, t, p, r = [], [], [], []
while d < end:
start_ = d
end_ = start_ + pd.DateOffs... | 30.438596 | 93 | 0.663977 |
e4ab8e400d3a8428f396d10f517cf745bdb624df | 24,862 | py | Python | sdk/python/pulumi_azure/cosmosdb/cassandra_table.py | henriktao/pulumi-azure | f1cbcf100b42b916da36d8fe28be3a159abaf022 | [
"ECL-2.0",
"Apache-2.0"
] | 109 | 2018-06-18T00:19:44.000Z | 2022-02-20T05:32:57.000Z | sdk/python/pulumi_azure/cosmosdb/cassandra_table.py | henriktao/pulumi-azure | f1cbcf100b42b916da36d8fe28be3a159abaf022 | [
"ECL-2.0",
"Apache-2.0"
] | 663 | 2018-06-18T21:08:46.000Z | 2022-03-31T20:10:11.000Z | sdk/python/pulumi_azure/cosmosdb/cassandra_table.py | henriktao/pulumi-azure | f1cbcf100b42b916da36d8fe28be3a159abaf022 | [
"ECL-2.0",
"Apache-2.0"
] | 41 | 2018-07-19T22:37:38.000Z | 2022-03-14T10:56:26.000Z | # coding=utf-8
# *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
# *** Do not edit by hand unless you're certain you know what you are doing! ***
import warnings
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
from .. import... | 48.558594 | 238 | 0.662376 |
e4ad4d1b1a19faa8dce0b003b788008a58802470 | 10,457 | py | Python | HW10/b06502027_hw10.py | Pyrojewel-zard/ML | d8a11d893eed3e889b9af0d6aeb3ab08cd60d997 | [
"MIT"
] | 5 | 2021-11-26T10:05:03.000Z | 2022-03-17T11:45:46.000Z | HW10/b06502027_hw10.py | Pyrojewel-zard/ML | d8a11d893eed3e889b9af0d6aeb3ab08cd60d997 | [
"MIT"
] | null | null | null | HW10/b06502027_hw10.py | Pyrojewel-zard/ML | d8a11d893eed3e889b9af0d6aeb3ab08cd60d997 | [
"MIT"
] | 1 | 2022-01-09T02:17:19.000Z | 2022-01-09T02:17:19.000Z | # -*- coding: utf-8 -*-
"""hw10_adversarial_attack.ipynb
Automatically generated by Colaboratory.
Original file is located at
https://colab.research.google.com/drive/1yPa2ushzqw8FNobfonL79PHzudn0vjrN
# **Homework 10 - Adversarial Attack**
Slides: https://reurl.cc/v5kXkk
Videos:
TA: ntu-ml-2021spring-ta@google... | 38.025455 | 286 | 0.67505 |
e4ae21080507e35b553b7b372118c5c586495e00 | 7,867 | py | Python | main/make_gradsamplingbasedexact_mesh.py | tttor/nbwpg | 271718362cf0cd810c7ea0cd9726e77276947e58 | [
"MIT"
] | null | null | null | main/make_gradsamplingbasedexact_mesh.py | tttor/nbwpg | 271718362cf0cd810c7ea0cd9726e77276947e58 | [
"MIT"
] | null | null | null | main/make_gradsamplingbasedexact_mesh.py | tttor/nbwpg | 271718362cf0cd810c7ea0cd9726e77276947e58 | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
import argparse, os, sys, pickle
import numpy as np, pathos.multiprocessing as mp, torch
import gym_util.common_util as cou, polnet as pn, util_bwopt as u
from collections import defaultdict
from poleval_pytorch import get_rpi_s, get_Ppi_ss, get_ppisteady_s, get_Qsa
if __name__ == '__main__':
... | 45.473988 | 109 | 0.645862 |
e4b424d5ad2b323394201895d8483eb6857e159f | 3,158 | py | Python | Python/tdw/FBOutput/StaticSpring.py | ricklentz/tdw | da40eec151acae20b28d6486defb4358d96adb0e | [
"BSD-2-Clause"
] | null | null | null | Python/tdw/FBOutput/StaticSpring.py | ricklentz/tdw | da40eec151acae20b28d6486defb4358d96adb0e | [
"BSD-2-Clause"
] | null | null | null | Python/tdw/FBOutput/StaticSpring.py | ricklentz/tdw | da40eec151acae20b28d6486defb4358d96adb0e | [
"BSD-2-Clause"
] | null | null | null | # automatically generated by the FlatBuffers compiler, do not modify
# namespace: FBOutput
import tdw.flatbuffers
# StaticSpring
def Id(self):
o = tdw.flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(4))
if o != 0:
return self._tab.Get(tdw.flatbuffers.number_types.I... | 38.048193 | 129 | 0.679227 |
e4b481ea04167900e771c376b8996b0f7e02b22f | 221 | py | Python | models/locobuyticketresponse.py | jujinesy/Empier_PythonKakaoBot | 80d2951955002b1a0b5d77b5c2830bc8def63ea3 | [
"MIT"
] | 3 | 2017-03-30T15:20:18.000Z | 2018-01-04T12:46:05.000Z | models/locobuyticketresponse.py | skdltmxn/kakaobot | e738b4a8d994fc4125bbd471bd48378a11a8d371 | [
"MIT"
] | 1 | 2020-08-06T08:13:22.000Z | 2020-08-06T08:13:22.000Z | models/locobuyticketresponse.py | skdltmxn/kakaobot | e738b4a8d994fc4125bbd471bd48378a11a8d371 | [
"MIT"
] | 5 | 2020-08-06T08:18:02.000Z | 2021-02-28T03:59:45.000Z | # -*- coding: utf-8 -*-
from locoresponse import LocoResponse
| 18.416667 | 42 | 0.642534 |
e4b4e1f9c8eb01d9ce9d5ca44f6c9f1bce4a4c9a | 91 | py | Python | travian4api/resources.py | ihoromi4/travian4api | 1fa9023d62d8dfca00f5276eff13868ddc057811 | [
"BSD-3-Clause"
] | 2 | 2022-03-08T20:50:08.000Z | 2022-03-08T20:50:13.000Z | travian4api/resources.py | ihoromi4/travian4api | 1fa9023d62d8dfca00f5276eff13868ddc057811 | [
"BSD-3-Clause"
] | null | null | null | travian4api/resources.py | ihoromi4/travian4api | 1fa9023d62d8dfca00f5276eff13868ddc057811 | [
"BSD-3-Clause"
] | 2 | 2021-03-10T18:43:53.000Z | 2021-12-18T13:31:22.000Z |
RESOURCE_TYPES = ['lumber', 'clay', 'iron', 'crop']
LUMBER = 0
CLAY = 1
IRON = 2
CROP = 3
| 13 | 51 | 0.593407 |
e4b5033ef04e9a7be53412dd0c2573434a49130e | 4,716 | py | Python | pikapy/interpreter.py | DanyGLewin/pykachu | d9faeb3e938e8f8da3250e432a9dd70487291627 | [
"MIT"
] | null | null | null | pikapy/interpreter.py | DanyGLewin/pykachu | d9faeb3e938e8f8da3250e432a9dd70487291627 | [
"MIT"
] | null | null | null | pikapy/interpreter.py | DanyGLewin/pykachu | d9faeb3e938e8f8da3250e432a9dd70487291627 | [
"MIT"
] | null | null | null | """Check the syntax and execute Pikachu commands.
Methods:
run -- The main context for the pikachu vm.
"""
from pikapy.utils import pika_error, pika_print
from pikapy.reader import PikaReader
from pikapy.stack import PikaStack
def run(file_name, args, debug):
"""
Run a specified Pikachu file in a virtual en... | 37.133858 | 116 | 0.496395 |
e4b53b56c59f025bc7d30fa6a90cb388b81c2484 | 1,865 | py | Python | app/accounts/views/vendor_profile.py | phessabi/eshop | 6a5352753a0c27f9c3f0eda6eec696f49ef4a8eb | [
"Apache-2.0"
] | 1 | 2020-02-04T21:18:31.000Z | 2020-02-04T21:18:31.000Z | app/accounts/views/vendor_profile.py | phessabi/eshop | 6a5352753a0c27f9c3f0eda6eec696f49ef4a8eb | [
"Apache-2.0"
] | 12 | 2020-01-01T11:46:33.000Z | 2022-03-12T00:10:01.000Z | app/accounts/views/vendor_profile.py | phessabi/eshop | 6a5352753a0c27f9c3f0eda6eec696f49ef4a8eb | [
"Apache-2.0"
] | 1 | 2020-02-18T11:12:48.000Z | 2020-02-18T11:12:48.000Z | from rest_framework import status
from rest_framework.generics import ListAPIView, RetrieveAPIView, CreateAPIView, UpdateAPIView
from rest_framework.permissions import AllowAny, IsAuthenticated
from rest_framework.response import Response
from rest_framework.viewsets import GenericViewSet
from _helpers.permissions imp... | 40.543478 | 95 | 0.790885 |
e4b72c3c2f5a5bbfee4b0bb9f47cf02969cbd82b | 31,394 | py | Python | plotoptix/tkoptix.py | robertsulej/plotoptix | 628694351791c7fb8cd631a6efe6cc0fd7d9f4f8 | [
"libtiff",
"MIT"
] | 307 | 2019-04-03T10:51:41.000Z | 2022-03-28T05:35:09.000Z | plotoptix/tkoptix.py | robertsulej/plotoptix | 628694351791c7fb8cd631a6efe6cc0fd7d9f4f8 | [
"libtiff",
"MIT"
] | 27 | 2019-05-11T08:53:32.000Z | 2022-02-07T22:43:21.000Z | plotoptix/tkoptix.py | robertsulej/plotoptix | 628694351791c7fb8cd631a6efe6cc0fd7d9f4f8 | [
"libtiff",
"MIT"
] | 21 | 2019-08-29T21:50:23.000Z | 2022-03-03T05:21:15.000Z | """
Tkinter UI for PlotOptiX raytracer.
https://github.com/rnd-team-dev/plotoptix/blob/master/LICENSE.txt
Have a look at examples on GitHub: https://github.com/rnd-team-dev/plotoptix.
"""
import logging
import numpy as np
import tkinter as tk
from PIL import Image, ImageTk
from ctypes import byref, c_float, c_uint
... | 46.099853 | 183 | 0.580334 |
e4b892cce045d4a84ff88607bc919a58e081ea7c | 453 | py | Python | tools/ckssh.py | luisxue/TreesShell | cd35826ca495264afa1e30f9b4f06eadd13ecb48 | [
"MIT"
] | null | null | null | tools/ckssh.py | luisxue/TreesShell | cd35826ca495264afa1e30f9b4f06eadd13ecb48 | [
"MIT"
] | null | null | null | tools/ckssh.py | luisxue/TreesShell | cd35826ca495264afa1e30f9b4f06eadd13ecb48 | [
"MIT"
] | null | null | null | #!/usr/bin/python
# Author: Luisxue <luisxue@gmail.com>
# BLOG: https://luisxue.xcodn.com
#
# Notes: TreesShell for CentOS/RadHat 6+ Debian 7+ and Ubuntu 12+
#
# Project home page:
# http://trees.org.cn
# https://github.com/luisxue/TreesShell
import socket,sys
sk = socket.socket(socket.AF_INET, socket.SO... | 22.65 | 65 | 0.688742 |
e4ba683b1acdb8fa2966f9142fd6e41d884299cc | 4,144 | py | Python | app.py | apizzo1/Hindsight_2020 | 51a124c7363a80ebd00999a3812a91c0b27f62cd | [
"MIT"
] | null | null | null | app.py | apizzo1/Hindsight_2020 | 51a124c7363a80ebd00999a3812a91c0b27f62cd | [
"MIT"
] | null | null | null | app.py | apizzo1/Hindsight_2020 | 51a124c7363a80ebd00999a3812a91c0b27f62cd | [
"MIT"
] | 1 | 2020-09-30T02:56:29.000Z | 2020-09-30T02:56:29.000Z | import sqlalchemy
from sqlalchemy.ext.automap import automap_base
from sqlalchemy.orm import Session
from sqlalchemy import create_engine, func
import os
import requests
import urllib.parse
# API key introduction
# API_KEY = os.environ.get('API_KEY', '')
finnhub_API_Key = os.environ.get('finnhub_API_Key', '')
from... | 36.034783 | 341 | 0.707288 |