Skip to content

Instantly share code, notes, and snippets.

View harderthan's full-sized avatar
🕴️
I

brewmaster harderthan

🕴️
I
View GitHub Profile
@harderthan
harderthan / install-opencv-2.4.13.4-in-ubuntu.sh
Created December 18, 2017 08:21 — forked from arthurbeggs/install_opencv2_ubuntu.sh
Install opencv-2.4.13.4 in Ubuntu
#!/bin/bash
# install dependencies
sudo apt-get update
sudo apt-get install -y build-essential
sudo apt-get install -y cmake
sudo apt-get install -y libgtk2.0-dev
sudo apt-get install -y pkg-config
sudo apt-get install -y python-numpy python-dev
sudo apt-get install -y libavcodec-dev libavformat-dev libswscale-dev
sudo apt-get install -y libjpeg-dev libpng12-dev libtiff5-dev libjasper-dev
@harderthan
harderthan / docker_cheat.md
Created March 8, 2018 07:09 — forked from nacyot/docker_cheat.md
도커(Docker) 치트 시트

Docker 치트 시트

한국어 번역(초벌) : nacyot

왜 Docker를 사용해야하는가?

Why Should I Care (For Developers)

"나에게 Docker의 매력은 간단히 격리된 환경을 만들 수 있다는 것과, 그러한 환경을 재사용할 수 있다는 점이다."런타임 환경을 한 번 만들어 패키지로 만들면, 이 패키지를 다른 어떤 머신에서도 다시 사용할 수 있다. 또한 여기서 실행되는 모든 것은 마치 가상머신과 같이 호스트로부터 격리되어있다. 무엇보다도 이런 모든 일들이 빠르고 간단히 가능하다.

@harderthan
harderthan / make_eclipse-project.sh
Last active April 3, 2018 11:52
Eclipse with ROS (Set up the project)
#!/bin/bash
# 1. Installing Eclipse
# http://www.eclipse.org/ or CUDA Tool-Kit (Nsight Eclipse).
# 2. Catkin-y approach
[ -d "$1" ] || exit
[ $# == 1 ] || exit
export ROOT_PATH=$1
@harderthan
harderthan / mount_nas.sh
Created April 4, 2018 02:03
Mount a Nas directory on ubuntu
export nas_path=$1
export username=$2
export password=$3
export target_path=$4
sudo mount -t cifs $nas_path -o username=$username,password=$password,rw,nounix,iocharset=utf8,file_mode=0644,dir_mode=0755,uid=1000,gid=1000,ver=1.0 $target_path
@harderthan
harderthan / CMakeLists_sample.txt
Last active November 27, 2018 02:10
CMakeLists 예제
cmake_minimum_required(VERSION x.x.x FATAL_ERROR)
# Project에 필요한 최소한의 cmake 버전을 명시
project(PackageName)
# Project 이름을 지정, 여기서 패키지 이름은 ${PROJECT_NAME} 변수에 저장
find_package(Library_Name REQUIRED)
# 추가할 Library Package를 지정
set(Var_Name Val)
@harderthan
harderthan / CMakeLists.txt
Last active July 30, 2018 07:57
TensorRT_with-ROS_CMakeLists
# by Kwanghoe, kheo1772@gmail.ac.kr
#-------------------------------------------------------------------------------
cmake_minimum_required(VERSION 2.8.3)
project(rt_example)
add_compile_options(-std=c++11)
#-------------------------------------------------------------------------------
# Find Cuda and Additional packages
if(VIBRANTE)
set(ARCH_DIR "aarch64-linux")
@harderthan
harderthan / gist:e30f3dbeb98d4e5e3b67ba9edd1d04b9
Created September 4, 2018 12:39
Draw Lane on The image with Opencv
// Draw Lane on The image
cv::Mat laneOverlay = drawImg(cv::Rect(0,0,drawImg.cols, drawImg.rows)).clone();
lane_polylines.push_back(cv::Point(topic_lane[0], topic_lane[1]));
lane_polylines.push_back(cv::Point(topic_lane[2], topic_lane[3]));
lane_polylines.push_back(cv::Point(topic_lane[6], topic_lane[7]));
lane_polylines.push_back(cv::Point(topic_lane[4], topic_lane[5]));
cv::fillConvexPoly(laneOverlay, lane_polylines, cv::Scalar(0, 255, 0), 8);
double alpha = 0.3;
cv::addWeighted(laneOverlay, alpha, drawImg, 1 - alpha, 0, drawImg);
#include <opencv2/core/core.hpp>
#include <pcl/common/transforms.h>
#include <pcl/point_cloud.h>
#include <pcl/point_types.h>
#include <iostream>
void Processing(const Eigen::Affine3f &transformation_matrix, const pcl::PointCloud<pcl::PointXYZ> &origin_point_cloud, const cv::Mat &projection_matrix, const cv::Mat &cameraMat, const cv::Size &image_size, cv::Point2f &result, bool log_flag = true);
void Processing(const Eigen::Affine3f &transformation_matrix, const pcl::PointCloud<pcl::PointXYZ> &origin_point_cloud, const cv::Mat &projection_matrix, const cv::Mat &cameraMat, const cv::Size &image_size, cv::Point2f &result, bool log_flag){
// Transfrom Points with Parameters
pcl::PointCloud<pcl::PointXYZ> transform_point_cloud;
@harderthan
harderthan / README.md
Created February 14, 2019 03:59
ROS Python Tutorial for Beginners