Skip to content

Instantly share code, notes, and snippets.

View enricorotundo's full-sized avatar
🤔
Thinking

Enrico Rotundo enricorotundo

🤔
Thinking
View GitHub Profile
@enricorotundo
enricorotundo / gist:abda94dfe2924408311be004f2f3293b
Last active August 17, 2023 09:56
Tritonserver tritonserver:23.02-py3 flags
since this is nowhere to be found...
=============================
== Triton Inference Server ==
=============================
NVIDIA Release 23.02 (build 53616260)
Triton Server Version 2.31.0
@enricorotundo
enricorotundo / raspotify.md
Last active December 8, 2022 23:13
Configure and install raspotify

Configure Raspberry and Install Raspotify

1) Get Raspberry Pi OS Lite

  • Release date: September 22nd 2022
  • System: 32-bit
  • Kernel version: 5.15
  • Debian version: 11 (bullseye)
  • Size: 338MB
  • Linux pi 5.15.61-v7+ #1579 SMP Fri Aug 26 11:10:59 BST 2022 armv7l
@enricorotundo
enricorotundo / bacalhau-libp2p-tracer.json
Created October 26, 2022 12:02
bacalhau-libp2p-tracer.json
{
"type": 9,
"peerID": "EiDRDl8/gd6FYgoIwxUSC4cGtYfvCE6qycIk7L59fgMs/w==",
"timestamp": 1666772852236502000,
"join": {
"topic": "bacalhau-job-event"
}
}
0
{

Fix Docker issues

yum install -y yum-utils
yum install -y dnf
yum-config-manager \
    --add-repo \
    https://download.docker.com/linux/centos/docker-ce.repo
yum update
dnf install docker-ce docker-ce-cli containerd.io
@enricorotundo
enricorotundo / hepscore.md
Last active September 15, 2022 14:11
hepscore

Repo: https://github.com/cmscaltech/docker-hs06/tree/master/hepscore

Prerequisites

Using CentOS Stream release 9. I tried using Red Hat enterprise linux version 7,8,9 but there's a blocking issue with Google Cloud infra at the moment that prevents any yum install (opened a support ticket with them...).

sudo yum update
sudo yum -y install git
git clone https://github.com/cmscaltech/docker-hs06.git
@enricorotundo
enricorotundo / foo_data.txt
Created July 21, 2022 14:02
foo txtt dataset
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.
@enricorotundo
enricorotundo / ec2.md
Created March 4, 2022 15:54
AWS EC2 notes
alias ll='ls -alF'

@enricorotundo
enricorotundo / pymongo_connect.py
Last active June 24, 2019 09:39
Pymongo connection with a pinch of flavour
import os
import urllib
from pymongo import MongoClient
def get_conn_string() -> str:
conn_string = "mongodb://{}:{}@{}/{}".format(
os.getenv("DB_USER"),
urllib.parse.quote(os.getenv("DB_PWD")), # escapes invalid chars
os.getenv("DB_URI"),
@enricorotundo
enricorotundo / export_inference_graph_unfrozen.py
Last active October 15, 2018 13:28
Export a checkpointed object_detection model for serving with TensorFlow Serving (works with Tensorflow 1.10)
"""
Run this with
cd research/object_detection
python export_inference_graph_unfrozen.py --input_type encoded_image_string_tensor --pipeline_config_path samples/configs/ssd_mobilenet_v1_coco.config --trained_checkpoint_prefix ssd_mobilenet_v1_coco_2017_11_17/model.ckpt --output_directory /Users/erotundo/HAL24K/Projects/dockerfiles-tf-serving/ssd_mobilenet_v1_coco/models
Make sure you add object_detection in PYTHONPATH
Credits to original gist by @dnlglsn:
https://gist.github.com/dnlglsn/c42fbe71b448a11cd72041c5fcc08092
References:
@enricorotundo
enricorotundo / run_jupyterlab.sh
Created September 14, 2018 08:56
Run JupyterLab, token authentication off
#!/usr/bin/env bash
jupyter lab --ip=* --port=8888 --no-browser --notebook-dir=$HOME --allow-root --NotebookApp.token=''