Skip to content

Instantly share code, notes, and snippets.

View jokla's full-sized avatar

Giovanni Claudio jokla

View GitHub Profile
<?xml version="1.0"?>
<launch>
<arg name="launch_prefix" default=""/>
<arg name="nodelet_manager" default="camera_nodelet_manager" />
<node pkg="nodelet" type="nodelet" name="$(arg nodelet_manager)" args="manager" cwd="node" output="screen" />
<node respawn="true" pkg="nodelet" type="nodelet" name="apriltag_ros" args="load apriltag_ros/ContinuousDetector $(arg nodelet_manager)" output="screen">
<rosparam command="load" file="$(find apriltag_ros)/config/settings.yaml"/>
  • Follow building from source link I had to change the dependencies:
sudo apt-get install python-setuptools python-rosinstall ipython libeigen3-dev libboost-all-dev doxygen libopencv-dev ros-melodic-vision-opencv ros-melodic-image-transport-plugins ros-melodic-cmake-modules software-properties-common libpoco-dev python-matplotlib python-scipy python-git python-pip ipython libtbb-dev libblas-dev liblapack-dev python-catkin-tools libv4l-dev 

  • You can now build with caktin build

  • In addition, to run the calibration I had to install python-igraph:

@jokla
jokla / gist:a654e27d8b86716afd5501942c950933
Last active May 9, 2020 11:24
Getting started with Juce on Ubuntu 18.04

Getting started with Juce on Ubuntu 18.04

  1. Download Juce for linux here
  2. Extract juce-5.X.X-linux.zip (I have it in /home/jokla/software/juce-5.4.7-linux)
  3. Run the application from terminal with $ ./home/jokla/software/juce-5.4.7-linux/JUCE/Projucer or double-click on Projucer.
  4. Follow this guide. I add to set up manually the path to Juce, the Juce modules and to Clion
  5. Now install libwebkit2gtk-4.0-dev from a terminal with sudo apt-get install libwebkit2gtk-4.0-dev
  6. You will need to install ladspa-sdk to build extras/AudioPluginHost/
; ========================================
; PTPDv2 version 2.3.0-svn default configuration
; ========================================
; NOTE: the following settings are affected by ptpengine:preset selection:
; ptpengine:slave_only
; clock:no_adjust
; ptpengine:clock_class - allowed range and default value
; To see all preset settings, run ptpd2 -H (--long-help)
function sysCall_init()
visionSensorHandles={}
for i=1,4,1 do
visionSensorHandles[i]=sim.getObjectHandle('velodyneVPL_16_sensor'..i)
end
ptCloudHandle=sim.getObjectHandle('velodyneVPL_16_ptCloud')
frequency=5 -- 5 Hz
options=2+8 -- bit0 (1)=do not display points, bit1 (2)=display only current points, bit2 (4)=returned data is polar (otherwise Cartesian), bit3 (8)=displayed points are emissive
pointSize=2
coloring_closeAndFarDistance={1,4}
@jokla
jokla / aruco.test
Created May 27, 2018 14:22
Aruco painting
/**
Copyright 2017 Rafael Muñoz Salinas. All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are
permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this list of
conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice, this list
@jokla
jokla / gist:587c647c1372fa19fbcd22918a533b84
Created January 14, 2018 16:07
rosbag record image and export to video
$ rosbag record -O test2.bag /image_color
- Create a file export_img_rosbag.launch:
<launch>
<node pkg="rosbag" type="play" name="rosbag" args="-d 2 $(find carla_ros)/launch/test.bag"/>
<node name="extract" pkg="image_view" type="extract_images" respawn="false" output="screen" cwd="ROS_HOME">
<remap from="image" to="/image_color"/>
</node>
</launch>
@jokla
jokla / change_docker_root_folder.txt
Last active July 15, 2019 09:02
Change Docker root folder Ubuntu 14.04 and Ubuntu 16.04
$ sudo service docker stop
$ gksudo gedit /etc/default/docker
# Use DOCKER_OPTS to modify the daemon startup options.
DOCKER_OPTS="--dns 8.8.8.8 --dns 8.8.4.4 -g /home/jokla/docker/docker/"
$ sudo service docker start
UBUNTU 16.04
from keras.preprocessing.image import ImageDataGenerator, array_to_img, img_to_array, load_img
import matplotlib.pyplot as plt
# Visualizations will be shown in the notebook.
%matplotlib inline
import random
import numpy as np
datagen = ImageDataGenerator(
rotation_range=40,
width_shift_range=0.2,