blob_id
stringlengths
40
40
language
stringclasses
1 value
repo_name
stringlengths
5
133
path
stringlengths
2
333
src_encoding
stringclasses
30 values
length_bytes
int64
18
5.47M
score
float64
2.52
5.81
int_score
int64
3
5
detected_licenses
listlengths
0
67
license_type
stringclasses
2 values
text
stringlengths
12
5.47M
download_success
bool
1 class
8a4d78753f8eff58504daca0eea1a2e98920bc2b
Python
strutt/seaveyMeasurements
/readS11s.py
UTF-8
8,279
2.609375
3
[]
no_license
#!/usr/bin/env python2 from matplotlib import pyplot as plt import math import numpy as np from glob import glob """ Simple script to read and draw the S11 data. """ def main(): filesV = glob('seaveyDataPalestine2014/S11s/*V.csv') filesH = glob('seaveyDataPalestine2014/S11s/*H.csv') filesV = orderGlobRes...
true
38ece02182fed05201718de8f5d8e8d21bd846e6
Python
SauloRicardo/trab_rec_paa
/trab_rec.py
UTF-8
7,074
2.671875
3
[]
no_license
import networkx as nx import copy import random import time def rcsp(node_beg_f, node_end_f, qtd_max_res_f, k_paths, graph=nx.DiGraph()): graph_aux = copy.deepcopy(graph) possible_paths = {} for nodes in range(1, graph_aux.number_of_nodes()+1): possible_paths_aux = [] it = 0 for no...
true
dd00c0462afec232f206ddf2b6d2ad20a7b877be
Python
rhuckleberry/DL_Phylo
/Recombination/recombination_networks/recombination_ResNet.py
UTF-8
6,875
2.71875
3
[]
no_license
#!/usr/bin/env python3 """Quartet tree classification * Model: Convolutional neural network with basic residual connections and batch normalization. * Training data: * 100000 pre-simulated trees using training1. * Each epoch uses randomly sampled 2000 trees. * The batch size is 16. * Validation data: 20...
true
c383ae7ff856ff3caed544b17456ef275daab90e
Python
frapa/tbcnn
/prepare_input.py
UTF-8
1,574
3.109375
3
[ "MIT" ]
permissive
import os import numpy as np import imageio def prepare(inDir, outFile): """Prepare input: convert to float with unit variance and zero mean, extract labels and pack everything into a big numpy array to be used for training outFile => path without extension (more than one file will be created) """ ...
true
ff19908937173367f24f3e2d29d18c4836f5e328
Python
matt-drayton/fake-news-sentiment-analysis
/extract_training_data.py
UTF-8
1,475
3.03125
3
[]
no_license
import json from tqdm import tqdm import pandas as pd from utils import lemmatize_and_strip, preprocess_bulk, log def load_training_data(): """Parse the training data from its CSV file Returns: Tuple containing the pre-processed positive and negative tweets """ csv = pd.read_csv("training.160...
true
8bd2fb8b587cfc5ed0d729d6560351d3084731ae
Python
shivamnegi1705/Competitive-Programming
/Leetcode/Weekly Contest 220/1696. Jump Game VI.py
UTF-8
469
2.78125
3
[]
no_license
# Question Link:- https://leetcode.com/problems/jump-game-vi/ class Solution: def maxResult(self, arr: List[int], k: int) -> int: ans = deque([]) n = len(arr) ans.append([0,arr[0]]) for i in range(1,n): while i-ans[0][0]>k: ans.popleft() r = [...
true
37db058bfac47ebd109ffa1dfaab18b22560e88d
Python
JoinNova/hackerrank
/ps_Lisa's Workbook.py
UTF-8
689
2.984375
3
[]
no_license
#Lisa's Workbook #!/bin/python3 import math import os import random import re import sys # Complete the workbook function below. def workbook(n, k, arr): r=0;a=1 for _ in arr: l=list(range(1,_+1)) chk=0 for i in range(_//k+1 if _%k>0else _//k): #print(i,l[chk:chk+k]) ...
true
372ac5748d75cba514a7b6ef6331cc3735d5f566
Python
yeonghoey/hew
/hew/stt.py
UTF-8
1,618
2.53125
3
[ "MIT" ]
permissive
import wave from google.cloud import speech_v1 from moviepy.editor import AudioFileClip from hew.util import Scheme, tempfile_path scheme = Scheme() @scheme def recognize_speech(): def f(source_path, language_code='en-US'): wav_path = convert_to_wav(source_path) client = speech_v1.SpeechClient(...
true
8483a7fd5cb0ccde3f6ccc5c0b9d71b95e48b099
Python
mljes/WiTS-TextPet
/screen_functions.py
UTF-8
1,101
2.890625
3
[]
no_license
from symbols import SYMBOLS from colors import FG_COL, BG_COL, RESET ############################################# # SCREEN FIELDS max_width = 44 max_height = 13 ############################################# def printOptions(type): printFrame("TOP", max_width-2) for item in SYMBOLS[type]: if item != "NONE": o...
true
9587d90d986fa0f5928f10474721ee1843ec3b43
Python
sedhha/URC2019
/Focal_length_calculation/fl_C.py
UTF-8
466
2.546875
3
[]
no_license
import cv2 import numpy as np cam=cv2.VideoCapture(0) while True: k=cv2.waitKey(1) if k & 0xFF==ord('q'): break _,frame=cam.read() img=cv2.inRange(frame,np.array([0,0,0]),np.array([180,255,30])) im2,contours,hierarchy = cv2.findContours(img, 1, 2) for i in range(len(contour...
true
b3e99a4141f733ec4e94ec86557d0d15e1299a89
Python
Fixdq/python-learn
/weekday0520/client/core/src.py
UTF-8
428
2.53125
3
[]
no_license
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # @Time : 18-5-20 下午3:09 # @Author : fixdq # @File : src.py # @Software: PyCharm from core import admin,user menu =""" 1.用户 2.管理员 """ menu_dic = { '1':user.view, '2':admin.view } def run(): while True: print(menu) ch = input('>>>:').s...
true
e9b6b2a66a01a6af19468e32710cc22ce7566fb3
Python
redmage123/intermediatepython
/examples/circuitous7.py
UTF-8
1,237
4.125
4
[]
no_license
''' Circuitous, LLC - An advanced circle analytics company ''' from math import pi,sqrt # Added sqrt import for bbd_to_radius function. sq class Circle: ''' An advanced circle analytics toolkit. Note use of class variable version ''' version = '0.3' def __init__(self,radius): ...
true
40eabf33e4f885fd907c8dfaec662e921c61360a
Python
popravich/hiku
/hiku/compat.py
UTF-8
2,616
2.59375
3
[ "BSD-3-Clause", "LicenseRef-scancode-unknown-license-reference" ]
permissive
import sys import ast as _ast import inspect PY3 = sys.version_info[0] == 3 PY35 = sys.version_info >= (3, 5) PY36 = sys.version_info >= (3, 6) def with_metaclass(meta, *bases): """Create a base class with a metaclass.""" # This requires a bit of explanation: the basic idea is to make a dummy # metaclas...
true
53b43a41321f5039785df5b05d9e38442d8b7a0e
Python
lyqtiffany/learngit
/caiNiao/sanShiSiShi/siShiQiExchange.py
UTF-8
182
3.59375
4
[]
no_license
def exchange(a, b): a, b = b, a return a, b if __name__ == '__main__': x = 12 y = 65 x, y = exchange(x, y) print('x value is %d'%x, 'y value change to %d'%y)
true
33ae7c9f65c1462e20cf31b50507a4e2a51c791e
Python
webclinic017/fa-absa-py3
/Extensions/Advanced Corporate Actions/FPythonCode/FCorpActionPayoutViewer.py
UTF-8
2,739
2.546875
3
[]
no_license
""" Compiled: 2020-09-18 10:38:49 """ #__src_file__ = "extensions/advanced_corporate_actions/./etc/FCorpActionPayoutViewer.py" import acm import FUxCore def SelectFirstItem(objList, itemList): if objList: firstItem = objList[0] itemList.SetData(firstItem) def RemoveItem(objList, itemList, item):...
true
9e6008d1e9c926ccb5f9d8c85af83a9bfb7bce3b
Python
Timpryor91/tims_shoes
/classes/event_class.py
UTF-8
19,776
2.734375
3
[]
no_license
# -*- coding: utf-8 -*- """ @author: timpr """ from datetime import datetime, timedelta import random as rand from classes.customer_class import Customer class EventsTable(object): """ An event table class, corresponding to a MySQL table used to store events on Tim's Shoes website """ def __init_...
true
095a5cec3d6dc8109af29d10ebc708b4f149fdd2
Python
Grace-JingXiao/AVEC_2017_DDS_CNN_Research
/Pretreatment/Text/Step3_Digital.py
UTF-8
1,623
2.5625
3
[]
no_license
import os import numpy if __name__ == '__main__': loadpath = 'D:/PythonProjects_Data/AVEC2017_Data/Text_Step1_RawText/' savepath = 'D:/PythonProjects_Data/AVEC2017_Data/Text_Step3_Digital/' dictionaryData = numpy.genfromtxt(fname='Dictionary.csv', dtype=str, delimiter=',') dictionary = {} for samp...
true
30364047be721bc5c400ff68515627e9c0a142cd
Python
melexis/xunit2rst
/tests/prefix_test.py
UTF-8
6,000
2.671875
3
[ "Apache-2.0" ]
permissive
#!/usr/bin/env python3 ''' Test suite for functions that set the prefix and prefix_set variables ''' import unittest from pathlib import Path from mlx.xunit2rst import build_prefix_and_set, parse_xunit_root, verify_prefix_set, ITEST, UTEST, QTEST TEST_IN_DIR = Path(__file__).parent / 'test_in' class TestPrefix(unit...
true
a1b20a6b219678546700b96074b57f6c623cebe9
Python
josiah-wolf-oberholtzer/tloen
/tloen/textui/__main__.py
UTF-8
511
2.71875
3
[ "MIT" ]
permissive
import urwid def on_a_press(*args, **kwargs): list_walker.append(button_row) def on_b_press(*args, **kwargs): list_walker[2:] = [] button_row = urwid.LineBox( urwid.Columns( [ urwid.Button("add more", on_press=on_a_press), urwid.Button("remove one", on_press=on_b_press)...
true
ec0710fb25faee72d6b18bb03b5ef720e71540fe
Python
TINY-KE/floorplan-MapGeneralization
/misc/plot_graph_with_labels.py
UTF-8
1,468
2.765625
3
[]
no_license
import networkx as nx import numpy as np import matplotlib.pyplot as plt from matplotlib.collections import LineCollection from matplotlib.figure import figaspect import matplotlib matplotlib.use('TKAgg') import os import argparse #GRAPH_PATH = r"C:\Users\Chrips\Aalborg Universitet\Frederik Myrup Thiesson - data\data_...
true
83b8558b6e1c5f86fa9bb857061d8cb34cc3752f
Python
jankeromnes/Python-Calc
/algeb/AbsVal.py
UTF-8
1,284
3.078125
3
[ "MIT" ]
permissive
import re def absVal(): main = { } main1 = { } while True: def r(): print('desired syntax: |(equ here)|') str1 = input('what is the equ?: ') equ = re.findall(r'\|.*\|', str1) equp2 = re.findall(r'.*', str1) str(equp2) #this takes the syntax of the equasion ie. |1 + 1| so thay it can ...
true
58f1c8e1ebbe8656f2fdaa4518f2746f523a0625
Python
cassebas/run-co-runners
/experiment/notebook_mälardalen-bsort-pi3.py
UTF-8
4,985
2.6875
3
[]
no_license
# --- # jupyter: # jupytext: # formats: ipynb,py:light # text_representation: # extension: .py # format_name: light # format_version: '1.5' # jupytext_version: 1.6.0 # kernelspec: # display_name: Python 3 # language: python # name: python3 # --- import pandas as pd impor...
true
a8aaf450fe18797fc1787c3df8f08011167f1caa
Python
durden/spygit
/spygitapp/pep8.py
UTF-8
2,884
2.71875
3
[]
no_license
from django.shortcuts import render_to_response import os import string import tempfile from fnmatch import fnmatch from models import Error, Run, File, RunError, Line def add_file_to_set(myset, dirname, fnames): """Used with os.path.walk to make a list of all files""" for filename in fnames: name ...
true
4434de27b97c07a22797f04745a9dd747ebd7942
Python
ProjectLSD/Noise-Reduction-Playground
/ops/mixer.py
UTF-8
702
2.765625
3
[]
no_license
from pydub import AudioSegment import random def generate_rand_frequency(): audio = AudioSegment.from_wav("basictone.wav") # import in the file with a tone of 440 Hz octaves = random.randint(-30, 30) / 10 #generates a random number from -3 to 3 new_sample_rate = int(audio.frame_rate * (2.0 ** octaves)) ...
true
19cc618422c842ef13cab81b4504229ab99bcbee
Python
lzx3x3/Algorithm-CSE6140
/CSE6140_HW4/Hongsup_OH_CSE6140_programming/Plot_divide_dynamic.py
UTF-8
621
3.390625
3
[]
no_license
import numpy as np import matplotlib.pyplot as plt #the number of k k = [10,1000,2000,3000,4000,5000,6000,7000,8000,9000,10000] #Divide and Conquer dc = [0.168,43.55,68.7,103.64,132,159,200,224,269.1,275.8,328] #Dynamic Programming dp = [0.048,10.554,18.889,29.50,32.329,36.6,38.2,46.3,52.4,54.6,71] #Plot Gr...
true
18f8757d2b722e4870ee9241c7017434e82df5f4
Python
jvanvari/LeetCode
/python-solutions/trees/BFS/994_rotting_oranges.py
UTF-8
1,357
3.515625
4
[]
no_license
from typing import List # problem of graph traversal and zigzag order traversal where you keep track of levels class Solution: def orangesRotting(self, grid: List[List[int]]) -> int: rows = len(grid) cols = len(grid[0]) queue = [] mins = 0 # levels for i in range(rows)...
true
7c72cfbacf81d4709a42760afb949fb1d13d0958
Python
Jagrmi-C/jagrmitest
/coursera_/queue4.py
UTF-8
400
3.21875
3
[ "MIT" ]
permissive
from queue import Queue from threading import Thread def worker(q, n): while True: item = q.get() if item is None: break print("process data:", n, item) q = Queue(5) th1 = Thread(target=worker, args=(q, 1)) th2 = Thread(target=worker, args=(q, 2)) th1.start(); th2.start() fo...
true
af042215ab562f2d98bab8e8ffbc617607601c10
Python
alainaahuja/face_recognition
/face_matching.py
UTF-8
2,322
3.15625
3
[]
no_license
#importing desired modules/libraries from tkinter import * from tkinter import filedialog import face_recognition #function command for first variable; gives path for first choice def browsingPIC1(): fileVarPIC1=filedialog.askopenfilename( filetypes=(("Alaina's stuff",".gif"),("All files","*.*"))) global enc...
true
f42f197213e57c8ee9f802598135609a28e91df4
Python
Shikhar0907/Algo-and-data-structure-questions
/Amazon_interview/amazon practice/anagrm maximum subset.py
UTF-8
431
3.421875
3
[]
no_license
def anagram(string): max_num = 0 string = string.split() for i in range(len(string)): string[i] = ''.join(sorted(string[i])) temp = {} for item in string: if item not in temp: temp[item] = 1 else: temp[item] += 1 print(max(temp.items(), key = lamb...
true
082d4e850468c3d5ea20431a1b59c062c6bbd81c
Python
AprajitaChhawi/365DaysOfCode.MAY
/Day 24 strong number.py
UTF-8
679
3.546875
4
[]
no_license
#User function Template for python3 class Solution: def fact(self,n): fac=1 for i in range(2,n+1): fac=fac*i return fac def isStrong(self, N): s=0 num=N while(num!=0): temp=num%10; s=s+ob.fact(temp) num=int(num/10) ...
true
bef3d1abd584e898424c12ea699eca28bc807f0c
Python
robinhouston/maze-experiments
/pylib-mazer/mazer/generate.py
UTF-8
2,103
3.671875
4
[]
no_license
""" Maze generation algorithms. """ from mazer.maze import (Maze, DIRECTIONS, RELATIVE_DIRECTIONS, N, E, S, W, random_direction) import random def recursive_backtracking(maze): """Complete the maze using the recursive backtracking algorithm. """ directions = [ d for d in RELATIVE_DIRECTIONS ] random.shuffle(d...
true
c171bf574918a08a6ce6089fe0e60f9aeb36c179
Python
akingyin1987/pytest
/mypy14.py
UTF-8
833
3.8125
4
[]
no_license
# 工厂模式 class CarFactory: def create_car(self, brand): if brand == "奔驰": return Benz() elif brand == "宝马": return BMW() elif brand == "比亚迪": return BYD() else: return "无品牌无法创建" class Benz: pass class BMW: pass class BYD...
true
4f0e8029dfb7ac16369555191937bfe22633404f
Python
BorisDundakov/Python---Fundamentals
/07. Dictionaries - Lab/keys itteration.py
UTF-8
639
3.859375
4
[]
no_license
# # # squares = {1: 1, 2: 4, 3: 9} # # # # # # for each_key in squares.keys(): # # # print(each_key, end=" ") # # # # # # squares = {1: "Ferrari", 2: "Lamborghini", 3: "McLaren"} # # # # for (key, value) in squares.items(): # # print(f"Key: {key}, Value: {value}") # # # # my_dict = {1: "Hello", 2: "World"} # # ...
true
290e44b7c21941a8aa1f07e4e21270cec42750ce
Python
yavoratanassov/softuni_python_fundamentals
/11_lists_basics_excercices/invert_values.py
UTF-8
174
3.453125
3
[]
no_license
numbers = input().split() opposite_numbers = [] for n in range(len(numbers)): number = int(numbers[n]) * -1 opposite_numbers.append(number) print(opposite_numbers)
true
a770f07b5d65290639f203c9dd8ab69b7ee2495f
Python
yishuen/python-flask-app-HTML-templates-lab-nyc-career-ds-102218
/test/index_test.py
UTF-8
2,298
2.6875
3
[]
no_license
import unittest, sys sys.path.insert(0, '..') from app import app class HTMLTemplateTestCase(unittest.TestCase): testy = app.test_client() def test_index_status_code(self): response = self.testy.get('/') self.assertEqual(response.status_code, 200) def test_index_html(self): respon...
true
5e42cdd6de7c95d8b0690093fa841b7243c31f26
Python
Annajose23/pythonLearning
/mostFrequent.py
UTF-8
326
3.421875
3
[]
no_license
def mostFrequent(arr): arr_freq = {} for item in arr: if item in arr_freq: arr_freq[item] = arr_freq[item] + 1 else: arr_freq[item] = 1 arr_sorted = sorted(arr_freq.items(), key=lambda kv: kv[1], reverse=True) print(arr_sorted[0][0]) mostFrequent([4,1,3,3,2,1...
true
685e9e377faccb765bd47ca768790ca8d6dce019
Python
MivlaM/AIVirtualAssistant
/Mivbot.py
UTF-8
9,949
2.984375
3
[]
no_license
import pyttsx3 # pip install pyttsx3 import datetime import speech_recognition as sr #Pip install speech recognition import wikipedia #pip install wikipedia import webbrowser as wb import psutil #pip install psutil import pyjokes #pip install pyjokes import os import pyautogui #pip install pyautogui import random imp...
true
0524578214dd63e46f6496fff74c5b6050142c79
Python
geekhub-python/akvarium-2-0-valiknet18
/aquarium_test.py
UTF-8
2,603
2.703125
3
[]
no_license
import unittest import occupants from random import choice from aquarium import Aquarium, AquariumFilter, FishCreator class TestAquarium(unittest.TestCase): OCCUPANTS_MAX_COUNT = 200 OCCUPANTS_MIN_COUNT = 20 def setUp(self): self.aquarium = Aquarium() def test_occupants_length(self): ...
true
9a8fe880ff7121eb5078b1bfa24f7f6d594677db
Python
ehsanik/dogTorch
/models/resnet18_image2imu.py
UTF-8
3,540
2.609375
3
[ "MIT" ]
permissive
""" ================= This model is a non-recurrent model for Inferring the action of the dog using a Resnet-18 network. Given two images, infer the imu changes corresponding to those two frames. ================= """ import torch import torch.nn as nn import pdb from torchvision.models import resnet18 as torchvisio...
true
c946ca5c86aa1be91d1ba845d0fd4c9b27da199f
Python
Hdwig/Math
/Lesson_3_1.py
UTF-8
215
3.171875
3
[]
no_license
import numpy as np import matplotlib.pyplot as plt x = np.arange(-10, 10) ys = 5 * x + 3 ym = 7 * x + 4 yl = 0 * x + 7 plt.xlabel("x") plt.ylabel("y") plt.grid(True) plt.plot(x, ys) plt.plot(x, ym) plt.plot(x, yl)
true
15eeb2aa75d6332fa2dd280a8fa84718d15667e3
Python
Ansore/super_resolution
/images_to_tfrecord.py
UTF-8
1,451
2.59375
3
[ "MIT" ]
permissive
from configs import * import os import numpy as np from PIL import Image import tensorflow as tf def scan_file(path): result = [] for filename in os.listdir(path): if filename.endswith('.png'): filename = path + '/' + filename result.append(filename) return result def image...
true
edf7256452ef397cd8f46fccabab0e04182eed80
Python
merissab44/superHero
/ability.py
UTF-8
330
3.578125
4
[]
no_license
import random class Ability: def __init__(self, name, max_damage): # initialized values that will be passed when # we call the class self.name = name self.max_damage = max_damage def attack(self): random_value = random.randint(0, int(self.max_damage)) return ran...
true
06e89ce84ac1b87267f827031f050104b8497e32
Python
robertdavidwest/forexpricecomparison
/app/db_create.py
UTF-8
877
2.828125
3
[]
no_license
# db_create.py from datetime import datetime from views import db from models import FXQuotes if __name__ == '__main__': # create the database and the db table db.create_all() # add one row of sample data - this is actual data quote_time = datetime(year=2015, month=9, day=30, ...
true
92244fdcac2ac00ce7f02270a6548ee6344d130c
Python
edimaudo/Python-projects
/visualization/scatterplot.py
UTF-8
445
3.390625
3
[]
no_license
import matplotlib.pyplot as plt X = [590,540,740,130,810,300,320,230,470,620,770,250] Y = [32,36,39,52,61,72,77,75,68,57,48,48] #scatter plot plt.scatter(X, Y, s=60, c='red', marker='^') #change axes ranges plt.xlim(0,1000) plt.ylim(0,100) #add title plt.title('Relationship Between Temperature and Iced Coffee Sales...
true
a21574955b9b8042dfb5d6a3ae95b982880acfc6
Python
isseikz/Multicopter
/sub_system/logger.py
UTF-8
3,440
2.609375
3
[ "MIT" ]
permissive
"""Logger""" import numpy as np import matplotlib.pyplot as plt import math class Logger(object): """docstring for Logger.""" def __init__(self): super(Logger, self).__init__() self.log_tim = [] self.log_pos = [] self.log_vel = [] self.log_acc = [] self.log_ang...
true
0438493823e3ec18b7afc63351293e25a25349b6
Python
priyalorha/jesse
/jesse/models/FuturesExchange.py
UTF-8
7,369
2.6875
3
[ "MIT" ]
permissive
import jesse.helpers as jh import jesse.services.logger as logger from jesse.exceptions import NegativeBalance, InsufficientMargin from jesse.models import Order from jesse.enums import sides, order_types from jesse.libs import DynamicNumpyArray import numpy as np from jesse.services import selectors from .Exchange imp...
true
53a878a603e3afb0010cab1057849b1fb2f490dc
Python
DarthGecko/orthometer
/intronitator.py
UTF-8
11,832
2.609375
3
[]
no_license
# Nick Weiner 2017 # introninator.py # Getting introns from FASTA files made by phytozomedler import re from Bio import SeqIO from Bio.Seq import Seq from Bio import motifs don_len = 5 acc_len = 8 # Things to work out: # How are we storing the data on the introns? In RAM or ROM? # Make a FASTA file of introns? # Set...
true
2c557903a396e2830cc1f890eb008ed2045ed46d
Python
vijaykanth1729/FLASK-REST-FRAMEWORK
/app2.py
UTF-8
2,240
2.59375
3
[]
no_license
from flask import Flask, jsonify, request from flask_restful import Resource,Api from flask_marshmallow import Marshmallow from flask_sqlalchemy import SQLAlchemy import os import datetime basedir = os.path.abspath(os.path.dirname(__file__)) app = Flask(__name__) api = Api(app) app.config['SQLALCHEMY_DATABASE_URI'] =...
true
809860db3fb709c0e3f5f875f384de5ff9c8bd17
Python
daodao10/rq-bak
/dao_adjust_position_impl.py
UTF-8
5,145
2.546875
3
[]
no_license
'''=============调仓制器=============''' from dao_strategy_base import * import dao_strategy_util as dutil '''---------------再平衡规则--------------''' class Rebalance(Adjust_position): def __init__(self, params): self.max_position_count = params.get('max_position_count', 3) self.max_weight_per_position = ...
true
4b9d3f8a00e359d2ce669576ddabe7bad530f4da
Python
minuso/leetcode
/0543/diameterOfBinaryTree.py
UTF-8
364
3.125
3
[]
no_license
def diameterOfBinaryTree(self, root: TreeNode) -> int: self.res = 0 def height(root): if not root: return 0 # height of each leaf is 1 hl, hr = height(root.left), height(root.right) self.res = max(self.res, hl + hr) # maintain longest length return max(hl, hr) + 1 ...
true
8117da39ffa71af50f87b0617a43ae22db72ad0c
Python
mukul1729/Settings_Preferences
/python/Euler/euler2.py
UTF-8
215
3.375
3
[]
no_license
first = 1 second = 1 third = 0 sum = 0 for a in range(100): third = first + second if third % 2 == 0 and sum <= 4000000: sum = sum + third first = second second = third print(sum)
true
0395a187108233cf9af5c410e0a4d056c323b3c5
Python
suguke/gait-control-direct-id-paper
/src/example_mean_gain_plots.py
UTF-8
3,044
2.578125
3
[ "CC-BY-4.0", "CC0-1.0" ]
permissive
#!/usr/bin/env python """This script plots the mean of the identified joint isolated gains from all valid trials. The gains must be precomputed. It currently does not include trials from Subject 9 because it has odd ankle joint torques.""" # builtin import os # external import numpy as np from scipy.constants import...
true
c8bb2555489806df3f9c710abc4d05af7d4d3b9e
Python
vwarner1411/openrvdas-1
/logger/readers/network_reader.py
UTF-8
2,823
2.65625
3
[ "MIT" ]
permissive
#!/usr/bin/env python3 import logging import socket import sys sys.path.append('.') from logger.utils.formats import Text from logger.readers.reader import Reader BUFFER_SIZE = 4096 ################################################################################ # Read to the specified file. If filename is empty, ...
true
5cbd645273a1d8e5be4fe983267a9c6ee60bc209
Python
H-Cong/LeetCode
/152_MaximumProductSubarray/152_MaximumProductSubarray_2.py
UTF-8
1,168
3.421875
3
[]
no_license
class Solution: def maxProduct(self, nums: List[int]) -> int: if not nums: return None curr_max = nums[0] curr_min = nums[0] ans = curr_max for i in range(1, len(nums)): temp_max = max(nums[i], nums[i]*curr_max, nums[i]*curr_min) curr_min = mi...
true
a8a2093fee616ea5a5fc8629de0a5eaf2af80898
Python
SeveralCamper/USE-2020-2021
/16 задание/РекурсФункцСТекст_011.py
UTF-8
459
3.984375
4
[]
no_license
# Задание 16 № 11347 # Ниже на пяти языках программирования записан рекурсивный алгоритм F. # Чему равна сумма напечатанных на экране чисел при выполнении вызова F(10)? count = 0 def F(n): if n > 2: global count count += n print(n) F(n - 3) F(n - 4) print(F(10), count) # ...
true
19abe0a590230023d4e7ad61587796d573f023f9
Python
lufeng0614/leetcode
/leetcode-349.py
UTF-8
773
3.8125
4
[]
no_license
给定两个数组,编写一个函数来计算它们的交集。 示例 1: 输入: nums1 = [1,2,2,1], nums2 = [2,2] 输出: [2,2] 示例 2: 输入: nums1 = [4,9,5], nums2 = [9,4,9,8,4] 输出: [4,9] 说明: 输出结果中每个元素出现的次数,应与元素在两个数组中出现的次数一致。 我们可以不考虑输出结果的顺序。 ======================================================================== class Solution(object): def intersect(self, n...
true
3ef7a9af6293aec84092afa67ff607757ccf3c67
Python
jdenoc/meta-search
/cgi/engine_searcher.py
UTF-8
3,253
3.46875
3
[]
no_license
#!/usr/bin/python ## ## Filename: engine_searcher.py ## Version: 6.5.4 ## This file opens search engine webpages and takes the links from them. ## This file contains functions that: ## opens sites, retrieves site code, closes site & then returns site code ## recieves the strings found in the sites & then trims them ...
true
4330303575a8508180fa48e049ae71d9ca1ac46e
Python
michaelb/point-clustering
/generation_test.py
UTF-8
1,432
3.03125
3
[]
no_license
#!/usr/bin/env python3 """ Module de création de fichiers d'ensembles de test """ from math import floor, sqrt from random import random import numpy as np def generation_fichier(nb_points, distance_liaison, chemin="qg2 > gq1.pts"): with open(chemin, "w") as fichier: fichier.write(str(distance_liaison) + ...
true
2cf0d370c351d4e2c1831fb6e05d3cd582b070b9
Python
gordian-biotechnology/arboreto
/scripts/run_diff_seeds_dream5_standardized.py
UTF-8
2,918
2.625
3
[ "BSD-3-Clause" ]
permissive
""" Python script for running Arboreto multiple times on the DREAM5 dataset, initialized with a different random seed for each run. The objective is to assess the stability of the inference quality of GRNBoost2 compared with GENIE3/Arboreto and the GENIE3 results as reported in the Dream5 paper. """ import pandas as ...
true
7cf04d1c5245584073def0da55639f4bb8ed396d
Python
alex-rt/DistributedSystem
/processing.py
UTF-8
2,244
2.5625
3
[]
no_license
#!/usr/bin/env python # coding: utf-8 # In[1]: #MASSIVE DATA MANAGEMENT #PARCIAL 2 #ALEJANDRO RODRIGUEZ TRILLO #ANDRESS ARANA BEJAR import pymongo import numpy as np import pandas as pd myclient = pymongo.MongoClient("mongodb://localhost:27017/") mydb = myclient["Parcial1"] mycol = mydb["alejandro_rodriguez_co...
true
af6fcee9518d537c001aeae5bd62f9fa7c240130
Python
mohmah7/osajana_kehitaminen-korkeakoulu
/harij08/L08T05.py
UTF-8
699
3.90625
4
[]
no_license
first_number = input("Please input number :") if first_number > 0: first_number = first_number else: first_number = 0; second_number = input("Please input number :") if second_number > 0: second_number = second_number else: second_number =0 third_number = input("Please input number :") if third_number > 0: thi...
true
06308053fe2bdf77f62ec4cda964e54e8b668a0a
Python
CCedricYoung/bitesofpy
/333/test_metropolis_hastings.py
UTF-8
2,020
3.234375
3
[]
no_license
import math import numpy as np import pytest from metropolis_hastings import metropolis_hastings np.random.seed(42) def norm_dist(x, mean, std): """Gaussian normal probability distribution.""" return np.exp(-0.5 * (x - mean) ** 2 / std ** 2) def standard_norm_dist(x): """Gaussian norm...
true
4fd4f9708b5e36d88a486f99d728710a26307ed4
Python
ripsj/logic
/DeterminadorDireccion.py
UTF-8
811
4.03125
4
[]
no_license
def esPar(num): if (num % 2) == 0: return True else: return False T = int(input("How many matrices would you like to test?")) arregloPares = [] for x in range(T): arregloPares.append(input("Enter 'N' and 'M' values for matrix number " + str(x+1) + ", spaced by a whitespace: ")) f...
true
87155d69da09ab877704089ee80120d5858ed152
Python
SamLR/MuSIC5_offline_analysis
/MuSIC5_offline_analysis/scripts/rates_from_count.py
WINDOWS-1252
4,396
2.671875
3
[]
no_license
#!/usr/bin/python # -*- coding: utf-8 -*- """ Calculate simulated muon rates based on truth count of number of muons of each type. """ from ValueWithError import ValueWithError from root_utilities import make_canvas from ROOT import TGraphErrors from array import array from time import sleep # g4bl = True g4bl = F...
true
974a98368a93e7d04ced6cf06c706dcdeda7d442
Python
GuangyuanZhao/ee239as
/packages/geomag/emm.py
UTF-8
7,882
2.65625
3
[]
no_license
# encoding: utf-8 # module geomag.emm # from C:\Users\qinli\AppData\Local\Programs\Python\Python36\lib\site-packages\geomag\emm.cp36-win_amd64.pyd # by generator 1.145 # no doc # imports import builtins as __builtins__ # <module 'builtins' (built-in)> import ntpath as path # C:\Users\qinli\AppData\Local\Programs\Pytho...
true
09404fe514830fd880f6eecd28b8c272e893d8d7
Python
zchauvin/tictactoe
/tester.py
UTF-8
3,314
3.75
4
[]
no_license
from Computer import Computer from Board import Board import unittest from typing import List N = 3 class TestComputer(unittest.TestCase): def test_x_computer_never_loses(self): board = Board(N) c = Computer('x', 'o') self.helper(board, c, True) def test_o_computer_never_loses(self):...
true
9203cd2ba10e9780887779818eb9b5e0f3b146e3
Python
mdilauro39/ifdytn210
/practicaIIII/funcionmax.py
UTF-8
218
3.859375
4
[]
no_license
n1= int(raw_input("ingrese primer numero")) n2= int(raw_input("ingrese segundo numero")) def numgrande(a,b): if a > b: return a if b > a: return b if a == b: return "a y b iguales" print numgrande(n1,n2,n3)
true
8fa525cfee21cae9a8d89c94633008a249954b51
Python
jeffdeng1314/CS16x
/cs160_series/python_cs1/integral_calculator.py
UTF-8
3,289
4.21875
4
[]
no_license
import math def f1(x): return 5 * math.pow(x, 4) + 3 * math.pow(x, 3) - 10 * x + 2 def f2(x): return math.pow(x, 2) - 10 def f3(x): return 40 * x + 5 def f4(x): return math.pow(x, 3) def f5(x): return 20 * math.pow(x, 2) + 10 * x - 2 """ ft: function type mt: method type: 1 - rectangle, 2 - trapezoid, 3 ...
true
466cca9ddd2ec1746e4a00a0ce59f0ce24d007b7
Python
JiwoonKim/Book-review-website
/application.py
UTF-8
8,683
2.890625
3
[]
no_license
import os from flask import Flask, session, render_template, request, jsonify from flask_session import Session from sqlalchemy import create_engine from sqlalchemy.orm import scoped_session, sessionmaker from helpers import * import requests app = Flask(__name__) # Check for environment variable if not os.getenv(...
true
5dbf7e9a9610d3299b8b3e43d1bd10ab60d93d71
Python
DobrovolskayaValentinaAI182/homework
/first.py
UTF-8
1,856
3.578125
4
[]
no_license
from random import randrange import time from datetime import datetime #buble my_list = [ randrange(0, 15) for i in range(10) ] max_list = len( my_list ) i = 0 while i < max_list: j = 0 while j < max_list-i-1: if my_list[ j ] > my_list[ j + 1 ]: my_list[ j ], my_list[ j + 1] = my_list[...
true
9c495135ab9a2398c6a1e14de03486c6e9b2f260
Python
Justin-mario/python_excercises
/Self_Check_Excercises/wind_chill_temperature.py
UTF-8
329
3.71875
4
[]
no_license
temperature = eval(input("Input Temperature Between -58F and 41f: ")) velocity_of_wind = eval(input("Input velocity: ")) wind_chill_temperature = 35.74 + (0.6215 * temperature) - 35.75 * (velocity_of_wind ** 0.16) \ + 0.4275 * temperature * (velocity_of_wind ** 0.16) print(f'{wind_chill_temper...
true
c75b50b21770c8d46f850ca03ad9ed775a8029b8
Python
pntgoswami18/tutBotKhamen
/bot.py
UTF-8
7,203
3.09375
3
[]
no_license
import os import discord import random from dotenv import load_dotenv from discord.ext import commands from discord import DMChannel # pull values frm .env file load_dotenv() TOKEN = os.getenv('DISCORD_TOKEN') GUILD = os.getenv('DISCORD_GUILD') client = discord.Client() bot = commands.Bot(command_prefix='!') @clie...
true
0d54c25260e20edad7bc33f085b00fd7dfc21684
Python
toxicthunder69/Iteration
/Starter Exercises/ContinuousMessage.py
UTF-8
189
3.546875
4
[]
no_license
#Joseph Everden #09/10/14 #Continuous message num = 0 while num >= 20 or num <= 10: num = int(input("Enter a number between 10 and 20: ")) print("You entered {0} which is valid!".format(num))
true
190004cd644c6757c46c3ec1918c5d9206ac80f2
Python
Cristopher-12/AplicacionesWebOrientadasaServicios
/google_books/index.py
UTF-8
1,484
2.8125
3
[]
no_license
import web import requests import json render = web.template.render("google_books/") class Index(): def GET(self): datos = None return render.index(datos) def POST(self): form = web.input() book_name = form.book_name result = requests.get("https://www.googleapis.com/books/v1/volumes?q="+boo...
true
89ffcc60bae2a7717793a4fd72ca281e9bd25d6d
Python
alfir777/skillbox_course_python-basic
/lesson_005/painting/wall.py
UTF-8
1,957
3.328125
3
[]
no_license
# -*- coding: utf-8 -*- # (цикл for) import time import simple_draw as sd def wall(coord_x=300, coord_y=100, height=201): x = 30 y = 15 step_y = coord_y for _ in range(0, height, y): step_x = coord_x if (step_y / 5) % 2: for _ in range(0, height, x): poin...
true
478f4e3f7fb3ce9e04ab0b0160b699e39bb649d7
Python
serenafr/linklinkgo
/boards.py
UTF-8
1,870
3.53125
4
[]
no_license
import random class Board(object): def __init__(self, kinds, pairsPerKind, interval): self.interval = interval self.kinds = kinds self.pairsPerKind = pairsPerKind self.tiles = None self.GenTiles() def GenTiles(self): 'generate a new game' self.tiles = [] for i in xrange(self.kinds)...
true
34424b93f79daebbae1f47d6079aea120a69e562
Python
yangmyongho/3_Python
/chap03_DataStr_exams/exam04.py
UTF-8
602
3.78125
4
[]
no_license
''' step05 문제 문) 다음 movie 객체를 대상으로 평점 8이상인 영화 제목과 누적관객수를 출력하시오. <출력 결과> 영화제목 : 광해 영화제목 : 관상 누적 관객수 = 2,100 ''' movie = {'광해' : [9.24, 1200], '공작' : [7.86, 500], '관상' : [8.01, 900]} # 내가한 1 for i in movie : print(i, end=' : ') print(movie[i]) # 내가한 2 su = 0 for i in movie.keys() : ...
true
143ef18ac271b8ba2533fae646aabfd7f599674d
Python
CLeDoPbIT/telegram_bot_face_recognition
/project/bot_self_check.py
UTF-8
1,377
2.609375
3
[]
no_license
import apiai, json import photo_proc txt_request = apiai.ApiAI('733a0aad1eb0479c88c862e1ec1a26e7').text_request() # Токен API к Dialogflow txt_request.lang = 'ru' # На каком языке будет послан запрос txt_request.session_id = 'Comparator3000' # ID Сессии диалога (нужно, чтобы потом учить бота) txt_request.query = 'Ты з...
true
4e9cac388fa214eb1856275e9e02d0540e12280e
Python
petterin/amaer
/amaer.py
UTF-8
4,162
3.296875
3
[ "MIT" ]
permissive
#!/usr/bin/env python # AMAer ("Adjacency Matrix-er") turns a CSV list into an adjacency matrix. # Usage instructions: python amaer.py --help # # https://github.com/petterin/amaer # # Copyright (c) 2013 Petteri Noponen (Licensed under the MIT License.) import argparse import csv import os import sys import time def ...
true
a3c1401a7cb47247fd98f91f1c0e683a7c982760
Python
Serasar/leverx_homework_2
/task_2.py
UTF-8
2,679
3.015625
3
[]
no_license
class Version: def __init__(self, version): self.version = version self.__version_int = 0 self.STRING_WORTH = {"a": 1, "b": 2, "alpha": -2, "beta": -1, "r": -5} self.MAJOR_WORTH = 100 self.MINOR_WORTH = 10 self.PATCH_WORTH = 0.1 self.version_to_int() def ...
true
763b0b494a5bcf723a05b3bb7e0110ded4535132
Python
Aasthaengg/IBMdataset
/Python_codes/p03816/s466111035.py
UTF-8
99
2.71875
3
[]
no_license
N = input() A = map(int, raw_input().split()) ans = len(set(A)) if ans%2==0: ans -= 1 print ans
true
8937656571224085957c9f315d2d269865b0d300
Python
MuqadirHussain/python-instagram-bot
/Bot.py
UTF-8
2,191
2.625
3
[]
no_license
from selenium import webdriver import os import csv from selenium.webdriver.support.wait import WebDriverWait from selenium.webdriver.chrome.options import Options def read_data(path): try: if (os.path.exists(path)): tagsArray=[] with open(path,'r') as csvfile: ...
true
557fcfb2b2fe40732519990f2f59cfdaf8e24177
Python
RunTimeError2/Hand-on-ML-with-sklearn-and-TF
/ex02_chap3/multi_output.py
UTF-8
2,178
3.03125
3
[]
no_license
import numpy as np from sklearn.datasets import fetch_mldata import matplotlib import matplotlib.pyplot as plt from sklearn.linear_model import SGDClassifier from sklearn.model_selection import StratifiedKFold from sklearn.base import clone from sklearn.model_selection import cross_val_score, cross_val_predict from skl...
true
95b1746ee696f3c6de0ecf9469a8d82f141daa18
Python
daniellopes04/uva-py-solutions
/list4/10541 - Stripe.py
UTF-8
669
3.53125
4
[]
no_license
# -*- coding: UTF-8 -*- def rectangles(n, k): if k == n: return 1 if k > n: return 0 d = max(k, n - k) q = min(k, n - k) numerator = 1 for n in range(d + 1, n + 1): numerator *= n denominator = 1 for d in range(1, q + 1): denominator *= d ret...
true
60f6efc871a2b70f1bd7bc032eade4c664124878
Python
gruiick/openclassrooms-py
/01-Apprenez/2.01.py
UTF-8
820
3.46875
3
[ "BSD-2-Clause" ]
permissive
#!/usr/bin/env python3 # coding: utf-8 # $Id: 2.01.py 1.2 $ # SPDX-License-Identifier: BSD-2-Clause chaine = str() # chaîne vide, même résultat que chaine = "" #while chaine.lower() != 'q': #print("hit 'Q' to quit") #chaine = input() print('Thx') print('Thx'.upper()) print('majuscules'.upper()) print(' s...
true
277afb49b1cb9a729e8f0852b2777936f934a22c
Python
empracine/test-epcath
/TimePeriod.py
UTF-8
30,741
2.515625
3
[]
no_license
import copy import random from Schedule import * from operator import itemgetter ############################################################################################################################################################################################################ ################################...
true
25a6e6a306f09b7ed5cdeb0fa86013e4bd727793
Python
Min-h-96/BST-calc
/BST-calc-1.py
UTF-8
3,238
3.953125
4
[]
no_license
import sys def postfix(list): # 숫자와 연산자를 각각 구분을 한다 for i in range(len(list)): operands = [] operator = [] for i in list: if ord(i) >= 48: operands.append(i) else: operator.append(i) lst_postfix = [operands[0]] for...
true
3456a0f06147b3344aee6baddf14dfdba710e16f
Python
ittoyou/2-1807
/16day/3-生成器.py
UTF-8
233
3.03125
3
[]
no_license
''' def test(): a,b = 0,1 for i in range(10): a,b = b,a+b yield b t = test() for i in t: print(i) ''' def test(): a,b = 0,1 for i in range(10): a,b = b,a+b yield b t = test() for i in t: print(i)
true
34d30a3c5b544a0d58d2b569f9ddad9312dcf14b
Python
ChJL/LeetCode
/easy/599. Minimum Index Sum of Two Lists.py
UTF-8
545
3.046875
3
[]
no_license
class Solution: def findRestaurant(self, list1: List[str], list2: List[str]) -> List[str]: d1 = {} d2 = {} count = 0 for i in list1: d1[i] = count count += 1 count = 0 for i in list2: if i in d1: d2[i] = count + d1[i...
true
9a2bf64c4a3530f6c97b00aae02ee3d35d733835
Python
Leader0721/Python_Spider
/douyu/douyu.py
UTF-8
1,286
3.03125
3
[]
no_license
# coding=utf-8 # 爬取斗鱼颜值妹子图片 import os import re from urllib import request import time from bs4 import BeautifulSoup # 定义为方法 def getHTML(url): page = request.urlopen(url) html = page.read() return html # 图片存放路径 FOLDER_SAVE = r'E:/Sprider/douyu' # 开始根据链接爬图片保存数据 def getImage(html): if not os.path.ex...
true
b58b2870f853c351a1a275d6321619a4414b958c
Python
enabhishek94/SeleniumFramework_Python
/Dummy/BaseTest.py
UTF-8
648
2.5625
3
[]
no_license
import unittest from Library import * import pytest class BaseTest(unittest.TestCase): def setUp(self): print("\n Running setup") driver_path = "C:\\Users\\abc\\Desktop\\Python P\\chromedriver.exe" self.driver = webdriver.Chrome(executable_path=driver_path) self.driver.get("https:/...
true
3399bb41b056c3881890b343e3cc725cc12a7fe9
Python
mcauser/CircuitPython_TerminalPixels
/circuitpython_terminalpixels.py
UTF-8
1,319
3.1875
3
[ "MIT" ]
permissive
from math import ceil import sys class FakePixel: def __init__(self, n=80, x=1, y=1, rows=1, auto_write=True): self.n = n self.bpp = 3 self._x = x self._y = y self._rows = rows self._chars_per_row = n // rows self.pixels = [(0, 0, 0)] * n self.auto...
true
b889584694fd98ac354136c81b576ae1cae796ee
Python
borescht/HoQuNM
/hoqunm/data_tools/analysis.py
UTF-8
51,708
2.515625
3
[ "MIT" ]
permissive
"""Provide methodologies for analysing the provided data.""" import json import logging from collections import Counter from datetime import date, datetime, timedelta from pathlib import Path from typing import Any, Dict, List, Optional, Tuple import graphviz import matplotlib.pyplot as plt import numpy as np import ...
true
220782e6d68217ed4677ddf90ae3d0964c3bb3ae
Python
IKyriem/Ejercicios-procesamiento-de-imagenes
/tarea.py
UTF-8
276
2.625
3
[]
no_license
import numpy as np import matplotlib.pyplot as pyplot import cv2 #Carga de imagen a color img = cv2.imread('2C1.jpg', 1) [B, G, R] = cv2.split(img) cv2.imshow ('imageR', R) cv2.imshow ('imageG', G) cv2.imshow ('imageB',B) cv2.waitKey(0) cv2.destroyAllWindows()
true
5ea8278a46f6919fd0e35af636b65fe11522791b
Python
zctao/GLIB_Aurora
/PyChips_1_4_1/scripts/glib_icap_jump_to_image.py
UTF-8
4,249
2.59375
3
[]
no_license
##===================================================================================================## ##==================================== Script Information ===========================================## ##===================================================================================================## ## ...
true
52ab0375a54ef8c2e04d83fcc2634d11cf192590
Python
Juan8bits/low_level_programming
/0x1C-makefiles/5-island_perimeter.py
UTF-8
1,613
3.890625
4
[]
no_license
#!/usr/bin/python3 """ Islander perimeter """ def island_perimeter(grid): """ function that returns the perimeter of the island described in grid. Conditions: - Grid is a list of list of integers. - 0 represents a water zone. - 1 represents a land zone - One cell is a ...
true
494bd38d3f3d370098e8c11e672901c7f619dd73
Python
a1742861031/faceRecognition
/flask-face-recognition-manage-system/controller/api_1_0/passport.py
UTF-8
3,493
2.546875
3
[]
no_license
from . import api from flask import current_app, jsonify, make_response, request, session from .. import redis_store from .. import models, db from sqlalchemy.exc import IntegrityError from werkzeug.security import generate_password_hash, check_password_hash @api.route('/users', methods=["POST"]) def registe...
true
d276cd96b0a93aca3693bbcedd06664254ef5b85
Python
tshidhore/solver-codes
/ME614/homeworkHPC/code/p3.py
UTF-8
1,828
2.546875
3
[]
no_license
import os import sys import numpy as np # library to handle arrays like Matlab import scipy.sparse as scysparse from matplotlib import pyplot as plt from mpi4py import MPI import pickle comm = MPI.COMM_WORLD rank = comm.Get_rank() size1 = comm.Get_size() N = ((10**5)+1)*np.ones(1,dtype=np.float128) e_tr = np.zero...
true
b07aa6e4556561a02878255178fa1bb52d023c3b
Python
shivatharun/NLP
/Functional_API_Keras/5_Shared_Input_layer.py
UTF-8
852
2.609375
3
[]
no_license
# Shared Input Layer model from keras.models import Model from keras.layers import Input, Dense, Flatten from keras.utils import plot_model from keras.layers.convolutional import Conv2D from keras.layers.pooling import MaxPooling2D from keras.layers.merge import concatenate visible = Input(shape=(64,64,1)) conv1 = Co...
true
1cf8687770a7c3c62d1edb55d6ebefccd3c413bd
Python
TenzinJhopee/GamestonkTerminal
/gamestonk_terminal/cryptocurrency/onchain/ethgasstation_model.py
UTF-8
1,549
3
3
[ "MIT" ]
permissive
import pandas as pd import requests def get_gwei_fees() -> pd.DataFrame: """Returns the most recent Ethereum gas fees in gwei [Source: https://ethgasstation.info] Parameters ---------- Returns ------- pd.DataFrame four gas fees and durations (fees for slow, average, f...
true