Skip to content

Instantly share code, notes, and snippets.

@julled
julled / thermal_intrinsic_calib.py
Created March 20, 2023 18:59
thermal camera calibration
import numpy as np
import cv2
import glob
from tqdm import tqdm
#Calib Circle Grid Setting
gridPointsWidth = 9
gridPointsHeight = 7
gridPointsDist = 0.02 #[m]
scale = 3
@julled
julled / gist:c7c707a372a0d5247b4add529200164c
Last active February 27, 2023 20:26
extract tracks from shazam sqlite database
# 1. get database from phone (e.g. with ADB) using guide from http://www.thinkoholic.com/2017/03/14/recover-songs-corrupted-shazam-library-android/#gallery-3
# 2. export detected tracks database as csv using sqlitebrowser: export table called "tag" as csv to disc => tag.csv
# 3. run below python script
import pandas as pd
import datetime
import json
df=pd.read_csv("tag.csv")
@julled
julled / resort_mission_images.py
Last active October 13, 2021 21:13
resort_mission_images
import os
import pandas as pd
from datetime import datetime
import glob
import numpy as np
from tqdm import tqdm
import shutil
import argparse
Change Line 62 in "model_main.py" from
config = tf.estimator.RunConfig(model_dir=FLAGS.model_dir)
to
config = tf.ConfigProto()
config.gpu_options.allow_growth = True
config.gpu_options.per_process_gpu_memory_fraction = 0.1
config = tf.estimator.RunConfig(model_dir=FLAGS.model_dir,
@julled
julled / bag2images.py
Last active April 24, 2019 20:13
Export images with metadata from rosbag
#!/usr/bin/env python
"""Extract images from a rosbag.
"""
import os
import argparse
import cv2
import rosbag
Setup Image
User:mav password:wingman
basiert auf maverick image
https://goodrobots.github.io/maverick/current/#/about
WLAN
config via wpa_supplicant file in /boot https://raspberrypi.stackexchange.com/questions/10251/prepare-sd-card-for-wifi-on-headless-pi
ssh mav@maverick-raspberrylite.local
MAVLINK anbindung
Device angeben via dem mavlink daten empfangen werden:
@julled
julled / gist:2c221e1743f57f5c361e0e72e75a5ebb
Last active March 27, 2019 11:55
Tutorial - Record mavlink with images in ROS on a raspberry pi
Install dependencies
ROS
Easiest is to get a image with ROS preinstalled:
MAVERICK configuration managment image
what is it?: https://goodrobots.github.io/maverick/current/#/about
install image to pi: https://goodrobots.github.io/maverick/current/#/?id=installation
MAVROS already installed
Only build of raspicam-node needed (see below)
Ubuntu Mate (easy to install aditional needed packages)
https://downloads.ubiquityrobotics.com/
--- TLP 1.1 --------------------------------------------
+++ Configured Settings: /etc/default/tlp
TLP_ENABLE=1
TLP_DEFAULT_MODE=AC
TLP_PERSISTENT_DEFAULT=0
DISK_IDLE_SECS_ON_AC=0
DISK_IDLE_SECS_ON_BAT=2
MAX_LOST_WORK_SECS_ON_AC=15
MAX_LOST_WORK_SECS_ON_BAT=60