This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cmake_minimum_required(VERSION 2.6) | |
PROJECT(qt_vtk_pcl) | |
list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}) | |
find_package(PCL 1.7 REQUIRED) | |
include_directories(${PCL_INCLUDE_DIRS}) | |
link_directories(${PCL_LIBRARY_DIRS}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
struct point{ | |
unsigned int x, y; | |
point() {}; | |
point (int a, int b) { | |
x = a; y = b; | |
} | |
bool point::operator ==(const point &a){ | |
return (x == a.x && y == a.y); | |
} | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" Installing vundle, run: | |
" git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim | |
" after, run in vim | |
" :PluginInstall | |
" | |
set nocompatible " be iMproved, required | |
filetype off " required | |
set rtp+=~/.vim/bundle/Vundle.vim | |
call vundle#begin() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Add to .bashrc | |
# alias tmux="TERM=screen-256color-bce tmux" | |
# Installing new tmux on 14.04 | |
# sudo add-apt-repository ppa:pi-rho/dev | |
# sudo apt-get update | |
# sudo apt-get install python-software-properties software-properties-common | |
# sudo apt-get install -yqq tmux-next=2.3~20161028~bzr3606+20-1ubuntu1~ppa0~ubuntu14.04.1 | |
# Add to .bashrc | |
# alias tmux="TERM=screen-256color-bce tmux-next" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Source: http://stackoverflow.com/questions/12791864/c-program-to-check-little-vs-big-endian | |
#include <stdio.h> | |
int main() | |
{ | |
int x = 1; | |
char *y = (char*)&x; | |
if(*y){ | |
printf("This computer is LITTLE endian.\n"); | |
printf(" higher memory \n"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
cat *log | grep -o ".Loss.[0-9]*\.[0-9]*" | grep -o "[0-9]*\.[0-9]*" > loss_values.txt | |
num=51 | |
if [ $# -eq 1 ]; then | |
num=$1 | |
fi | |
python -c "import numpy as np; from scipy.signal import savgol_filter; y=np.loadtxt('loss_values.txt'); yh=savgol_filter(y, $num, 3); np.savetxt('smoothed_values.txt',yh);" | |
( | |
gnuplot <<- EOF |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cat *.log | grep -o ".Loss.[0-9]*\.[0-9]*" | grep -o "[0-9]*\.[0-9]*" > loss_values.txt | |
gnuplot <<- EOF | |
set terminal dumb | |
set xlabel "Iterations" | |
set ylabel "Loss" | |
plot "loss_values.txt" | |
EOF | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
showasm() { | |
$1++ $2 -O$3 -std=c++2a -S -masm=intel -o _temp_name.s && cat _temp_name.s | c++filt | grep -vE '\s+\.' > _temp_name_.s && rm _temp_name.s && vim _temp_name_.s | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
"""Extract sensor_msgs/CompressedImage from bagfile and save into a folder as png or jpeg files | |
Example usage: | |
./extract_images_from_bagfile.py bagfile.bag "/camera_topic" output_folder/images | |
Then files will be saved inside: | |
output_folder/images/image_1594120767.5438294.jpeg | |
output_folder/images/image_1594120767.8838294.jpeg | |
output_folder/images/image_1594120767.9538294.jpeg |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Recently Implicit Neural Representations gain popularity. | |
One of the issues there though is that the learned representations | |
are low-frequency biased, resulting in over-smoothed representations. | |
There has been a few approaches suggested to alleviate the issue, | |
for example by using positional encodings. | |
An alternative could be using Sin/Cos activation functions, | |
which in essence present a learnable basis functions. |