注意:本文内容适用于 Tmux 2.3 及以上的版本,但是绝大部分的特性低版本也都适用,鼠标支持、VI 模式、插件管理在低版本可能会与本文不兼容。
启动新会话:
tmux [new -s 会话名 -n 窗口名]
恢复会话:
### CMakeLists.txt for CUDA | |
cmake_minimum_required(VERSION 2.8) | |
find_package(CUDA QUIET REQUIRED) | |
# Pass options to NVCC | |
set( | |
CUDA_NVCC_FLAGS | |
${CUDA_NVCC_FLAGS}; | |
-O3 -gencode arch=compute_22,code=sm_22 |
""" | |
RALIGN - Rigid alignment of two sets of points in k-dimensional | |
Euclidean space. Given two sets of points in | |
correspondence, this function computes the scaling, | |
rotation, and translation that define the transform TR | |
that minimizes the sum of squared errors between TR(X) | |
and its corresponding points in Y. This routine takes | |
O(n k^3)-time. | |
Inputs: |
import cv2 | |
import numpy as np | |
def cylindricalWarp(img, K): | |
"""This function returns the cylindrical warp for a given image and intrinsics matrix K""" | |
h_,w_ = img.shape[:2] | |
# pixel coordinates | |
y_i, x_i = np.indices((h_,w_)) | |
X = np.stack([x_i,y_i,np.ones_like(x_i)],axis=-1).reshape(h_*w_,3) # to homog | |
Kinv = np.linalg.inv(K) |
# Original Matlab code https://cs.nyu.edu/~silberman/datasets/nyu_depth_v2.html | |
# | |
# | |
# Python port of depth filling code from NYU toolbox | |
# Speed needs to be improved | |
# | |
# Uses 'pypardiso' solver | |
# | |
import scipy | |
import skimage |
import numpy.linalg as LA | |
import numpy as np | |
def any_LiDAR_to_ring(pc, num_beams=32, ring_height=8e-4): | |
""" | |
convert any type of LiDAR point cloud to ring-based LiDAR style | |
:param pc: input point cloud, shape of Nx4(x,y,z,intensity) | |
:param num_beams: number of beams | |
:param ring_height: the "line width" of a ring | |
:return: ring-stype point cloud, shape of Nx5(x,y,z,intensity, ring ID) |
import copy | |
import time | |
import open3d as o3d | |
import os | |
from collections import defaultdict | |
import numpy as np | |
import numpy.linalg as LA | |
import gtsam | |
import tqdm |