Skip to content

Instantly share code, notes, and snippets.

View ricardodeazambuja's full-sized avatar

Ricardo de Azambuja ricardodeazambuja

View GitHub Profile
@mortcanty
mortcanty / semantic_segmentation.ipynb
Last active January 7, 2024 01:51
Semantic_Segmentation.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@jaredharley
jaredharley / Monoprice Mini Delta V2 printer API notes.md
Last active September 2, 2023 14:28
My working notes on figuring out the Monoprice Mini Delta V2 (MPMDv2) web API

Monoprice Mini Delta V2 printer API

My in-progress documentation of the Monoprice Mini Delta V2 printer api. This is traffic captured between the included Wiibuilder application and the printer when you connect to the printer through Wiibuilder and send a gcode file to print.

api/printer

api/printer during print job

{
@chabala
chabala / using-google-takeout.md
Last active March 25, 2024 00:18
Merge and extract tgz files from Google Takeout

Recently found some clowny gist was the top result for 'google takeout multiple tgz', where it was using two bash scripts to extract all the tgz files and then merge them together. Don't do that. Use brace expansion, cat the TGZs, and extract:

$ cat takeout-20201023T123551Z-{001..011}.tgz | tar xzivf -

You don't even need to use brace expansion. Globbing will order the files numerically:

$ cat takeout-20201023T123551Z-*.tgz | tar xzivf -
@driftregion
driftregion / service_from_service.py
Created May 19, 2020 09:39
Calling a ROS2 service from the callback of another service
import time
from threading import Event
from example_interfaces.srv import AddTwoInts
import rclpy
from rclpy.node import Node
from rclpy.callback_groups import ReentrantCallbackGroup
from rclpy.executors import MultiThreadedExecutor, SingleThreadedExecutor
@andreyryabtsev
andreyryabtsev / backmatting.ipynb
Last active January 16, 2024 11:59
BackMatting.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@davidlares
davidlares / rawInjection.py
Last active January 19, 2024 20:46
Raw Sockets with Python: Sniffing and network packet injections.
#!/usr/bin/python
import socket
import struct
# creating a rawSocket for communications
# PF_SOCKET (packet interface), SOCK_RAW (Raw socket) - htons (protocol) 0x08000 = IP Protocol
rawSocket = socket.socket(socket.PF_PACKET, socket.SOCK_RAW, socket.htons(0x0800))
# deciding interface - packet sniffing and then injection
@bmaupin
bmaupin / install-adobe-reader-9-ubuntu.sh
Last active December 23, 2023 09:47
Install Adobe Reader 9 on Ubuntu
# Cache sudo password
sudo -v
# Enable installation of 32-bit packages
sudo dpkg --add-architecture i386
# Enable the Ubuntu partner repository (this doesn't seem to be necessary for 20.04)
if [ $(lsb_release -r | awk '{print $2}') == '18.04' ]; then
sudo sed -i 's/^# deb http:\/\/archive.canonical.com\/ubuntu/deb http:\/\/archive.canonical.com\/ubuntu/' /etc/apt/sources.list
sudo apt update
@isphus1973
isphus1973 / dgoogle_download.sh
Last active July 2, 2019 13:20
Small bash script that downloads a Google Drive file with wget
#!/bin/sh
######Usage#######
# ./dgoogle_download.sh FILE_ID OUTPUT_NAME
## Remember to chomod +x dgoogle_download.sh
#This scrip is based on https://unix.stackexchange.com/questions/136371/how-to-download-a-folder-from-google-drive-using-terminal
@korakot
korakot / pydrive.py
Last active November 12, 2020 01:04
Google drive upload, read, update with Google Colab
from pydrive.auth import GoogleAuth
from pydrive.drive import GoogleDrive
from google.colab import auth
from oauth2client.client import GoogleCredentials
# Authenticate and create the PyDrive client.
auth.authenticate_user()
gauth = GoogleAuth()
gauth.credentials = GoogleCredentials.get_application_default()
drive = GoogleDrive(gauth)
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.