Skip to content

Instantly share code, notes, and snippets.

View michaelaye's full-sized avatar

Michael Aye michaelaye

View GitHub Profile
[LabBuildApp] Building in /home/maye/miniconda3/envs/py38/share/jupyter/lab
[LabBuildApp] Node v16.10.0
[LabBuildApp] Yarn configuration loaded.
[LabBuildApp] Building jupyterlab assets (production, minimized)
[LabBuildApp] > node /home/maye/miniconda3/envs/py38/lib/python3.8/site-packages/jupyterlab/staging/yarn.js install --non-interactive
[LabBuildApp] yarn install v1.21.1
[1/5] Validating package.json...
[2/5] Resolving packages...
success Already up-to-date.
@michaelaye
michaelaye / test_nbs.py
Created October 11, 2021 20:33
cloned from Nixtla/mlforecast
# taken from: https://raw.githubusercontent.com/pete88b/decision_tree/master/test_nbs.py
# We need a "test_" file with "test_" functions to make it easy to run with pytest
# couple of example "test_" functions
# import nbdev.test
# def test_run():
# print('running nbdev.test.test_nb("20_models.ipynb") ...')
@michaelaye
michaelaye / remotemd5.py
Created October 7, 2021 02:09 — forked from brianewing/remotemd5.py
Python MD5 of remote file (URL)
import os, hashlib, urllib2, optparse
def get_remote_md5_sum(url, max_file_size=100*1024*1024):
remote = urllib2.urlopen(url)
hash = hashlib.md5()
total_read = 0
while True:
data = remote.read(4096)
total_read += 4096
@michaelaye
michaelaye / my_speedtest.py
Created September 22, 2021 03:02
Adding a timestring to speedtest csv output and add to csv file.
#!/usr/bin/env python
# -*- coding: utf-8 -*-
from datetime import datetime as dt
from pathlib import Path
from sh import speedtest
fname = Path("multiple_connections_triton.csv")
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@michaelaye
michaelaye / advanced_rasterio_features.ipynb
Created October 24, 2020 01:34 — forked from sgillies/advanced_rasterio_features.ipynb
Advanced Rasterio features notebook
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@michaelaye
michaelaye / blink_images.ipynb
Created September 24, 2020 00:40
Blinking images with matplotlib
Aug 29 12:34:26 triton kernel: [139271.638649] WARNING: CPU: 9 PID: 130936 at drivers/media/v4l2-core/v4l2-ioctl.c:1069 v4l_querycap+0x8f/0xa0 [videodev]
Aug 29 12:34:26 triton kernel: [139271.638649] Modules linked in: xt_tcpudp xt_state xt_conntrack nf_conntrack nf_defrag_ipv6 nf_defrag_ipv4 libcrc32c ccm rfcomm ip6table_filter ip6_tables iptable_filter bpfilter cmac algif_hash algif_skcipher af_alg bnep binfmt_misc snd_hda_codec_hdmi snd_hda_codec_realtek snd_hda_codec_generic ledtrig_audio snd_hda_intel snd_intel_dspcfg snd_hda_codec snd_hda_core iwlmvm snd_hwdep snd_pcm mac80211 nls_iso8859_1 snd_seq_midi snd_seq_midi_event btusb btrtl libarc4 edac_mce_amd snd_rawmidi btbcm btintel iwlwifi bluetooth snd_seq snd_seq_device snd_timer eeepc_wmi asus_wmi ucsi_ccg joydev sparse_keymap input_leds k10temp video typec_ucsi ecdh_generic kvm ecc wmi_bmof cfg80211 snd typec ccp soundcore mac_hid nvidia_uvm(OE) sch_fq_codel v4l2loopback(OE) v4l2loopback_dc(OE) videodev mc parport_pc ppdev lp parport ip_tables x_tabl