Skip to content

Instantly share code, notes, and snippets.

View juanmed's full-sized avatar
💭
Trying to understand...

Juan juanmed

💭
Trying to understand...
View GitHub Profile
import cv2
import numpy as np
import matplotlib.pyplot as plt
from sklearn.neighbors import NearestNeighbors
#from scipy.optimize import leastsq
from scipy.optimize import fmin_bfgs
from scipy.optimize import minimize
from scipy.optimize import approx_fprime
def res(p,src,dst):
@juanmed
juanmed / gist:c1570743a080c51b19c316ed8f51950f
Last active September 1, 2020 09:28
Useful ros commands
ROS
* Print current environtment
printenv | grep ROS
* create workspace
mkdir -p catkin_ws/src
cd catkin_ws
catkin_make
source devel/setup.bash
@juanmed
juanmed / gist:5b15f3190e420734797eb7ef6b8047a6
Last active August 14, 2020 01:14
useful git commands
GIT
* start new git repository
echo "# quadrotor_sim" >> README.md
git init
git add README.md
git commit -m "first commit"
git remote add origin https://github.com/juanmed/quadrotor_sim.git
git push -u origin master
@juanmed
juanmed / gist:7fdfe07afbbf9069d477dfb5256b4a3d
Last active April 5, 2020 06:59
Install ruby, jekyll ubuntu 16
When everythin fails... follow
https://websiteforstudents.com/how-to-install-jekyll-cms-on-ubuntu-16-04-18-04-18-10/
Siguiendo el tutorial de Github para utlizar github pages:
- Instalar github-pages
$ gem install github-pages
- Entrar al directorio docs/
- Ahi ejecutar
$ bundle update
@juanmed
juanmed / gist:48bcd86db38baaba4751d8af42cba4fe
Created April 10, 2020 14:52
Update fork from upstream
https://github.com/KirstieJane/STEMMRoleModels/wiki/Syncing-your-fork-to-the-original-repository-via-the-browser
sudo ln -s /opt/ros/kinetic/lib/liborocos-kdl.so.1.3 /opt/ros/kinetic/lib/liborocos-kdl.so.1.3.0
After you have inserted your SD card into the slot open a terminal. Type
```
sudo fdisk -l
```
Hopefully your SD card should be listed as a drive and it should look something like this,
```
Device Boot Start End Blocks Id System
/dev/sdb1 3 2112 3860480 b W95 FAT32
sudo apt-get autoremove
sudo du -sh /var/cache/apt 
sudo apt-get autoclean
sudo apt-get clean
journalctl --disk-usage
sudo journalctl --vacuum-time=3d
@juanmed
juanmed / gist:cbb6280b9a4f24c50d018ff39a592721
Created April 13, 2022 16:03
depth image registration
https://github.com/java311/Bee-vision/blob/c8c8f5a6efd2d6c3ab39ef73e5b6f4d65abbfd42/real-sense/myRawAlign.py
https://github.com/opencv/opencv_contrib/issues/2234
@juanmed
juanmed / gist:740fdd84b9629de45634925817c647ca
Created April 28, 2022 03:25
coco2mvt: convert a coco dataset to mvt dataset
from pycocotools.coco import COCO
import numpy as np
import matplotlib
matplotlib.use('TkAgg')
import matplotlib.pyplot as plt
from matplotlib.patches import Rectangle
import pylab
import cv2
import shutil
import os