Skip to content

Instantly share code, notes, and snippets.

@MohamedAlaa
MohamedAlaa / tmux-cheatsheet.markdown
Last active May 3, 2024 19:09
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@kgriffs
kgriffs / gist:11259333
Last active November 23, 2020 18:53
Python Benchmark: MessagePack vs. JSON
In [4]: response
Out[4]:
{'messages': {'claimed': 2409,
'free': 146929,
'newest': {'age': 12,
'created': '2013-08-12T20:45:46Z',
'href': 'queues/fizbit/messages/50b68a50d6f5b8c8a7c62b01'},
'oldest': {'age': 63,
'created': '2013-08-12T20:44:55Z',
'href': 'queues/fizbit/messages/50b68a50d6f5b8c8a7c62b01'},
@hmartiro
hmartiro / zeromq-vs-redis.md
Last active April 14, 2024 20:33
Comparison of ZeroMQ and Redis for a robot control platform

ZeroMQ vs Redis

This document is research for the selection of a communication platform for robot-net.

Goal

The purpose of this component is to enable rapid, reliable, and elegant communication between the various nodes of the network, including controllers, sensors, and actuators (robot drivers). It will act as the core of robot-net to create a standardized infrastructure for robot control.

Requirements:

@rambabusaravanan
rambabusaravanan / client.py
Created November 13, 2017 14:20
Simple TCP Streaming Server Client in Python
# Streaming Client
import socket
HOST = 'localhost'
PORT = 50007
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
s.connect((HOST, PORT))
while True:
@rfezzani
rfezzani / get_crop.py
Last active September 27, 2023 07:00
Crop extraction from tiled TIFF image file directory without whole page loading using tifffile
from tifffile import TiffFile
import numpy as np
def get_crop(page, i0, j0, h, w):
"""Extract a crop from a TIFF image file directory (IFD).
Only the tiles englobing the crop area are loaded and not the whole page.
This is usefull for large Whole slide images that can't fit int RAM.

Hydra configuration loader for Kedro

⚠️ 2021-03-07: WIP / Unmaintained. This project is a proof of concept, not recommend for general use.

Tested with Kedro 0.17.1 and Hydra 1.0.6.

Author: Martin Sotir


Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.