스터디 노트
article thumbnail
[Computer Vision] 2D Convolution - python code
maengkyun/CV 2021. 12. 12. 00:41

Window sliding 구현하고 Convolution 만들어봐야지 하고 미루다가 프로젝트 할 때 사용할 일이 있어서 구현해봤다. 시험기간이라 설명은 나중에 .. 커널은 edge 표현을 위해 sobel mask를 사용해봤다. import numpy as np import matplotlib.pyplot as plt from PIL import Image from PIL import ImageDraw import cv2 Array = cv2.imread('frame_00000.jpg') Array = cv2.cvtColor(Array,cv2.COLOR_BGR2GRAY)#np.ones((100,100)) print(Array.shape) #mask = np.zeros((6,6)) Array = cv2.re..

article thumbnail
depth
maengkyun/CV 2021. 11. 28. 18:10

간단하게 stereo는 Essential Matrix (Epipolar constraint)로 설명할 수 있다. epipolar geometry 특성을 이용해 Rectified image를 얻을 수 있다. x=HX (H: a plane to plane projective transformation) 3d world --> 2d projection P matrix 2d image --> 2d image Homography matrix로 simplify 이를 통해 disparity를 측정할 수 있음. 1.stereo camera calibration 2.rectification (epipolar line을 일렬로) C. loop and Z. Zhang. Computing Rectifying Homograph..

article thumbnail
ZED2 stereo camera python api setup
maengkyun/CV 2021. 11. 27. 23:24

Prerequisition ZED SDK python3.6+ cython 0.26+ numpy 1.13+ opencv python(optional) pyopengl (optional) cuda zed sdk https://www.stereolabs.com/developers/release/ cuda toolkit https://developer.nvidia.com/cuda-toolkit-archive python -m pip install cython numpy opencv-python pyopengl zed sdk를 설치하고 나면 get_python_api.py 가 있다. cmd 켜고 해당 폴더로 이동해서 python get_python_api.py를 입력하면 의존 패키지들을 설치 해주는 것 같다. S..

article thumbnail
[Computer Vision] Sliding Window Algorithm
maengkyun/CV 2021. 11. 12. 19:22

처음 CNN을 접하면서 Sliding window 개념에 대해 배웠다. 이미지내의 요소들을 뽑아 feature map을 형성하기 위해 Kenel이라는 일정한 크기의 배열을 만들어주고 이미지에 Kernel을 sliding하며 convolution하는 것을 많이 봐았지만 sliding window 자체를 구현 해보는 것은 처음이다. Sliding window algorithm은 배열내에 데이터가 존재하고 해당 배열의 일정 범위에 존재하는 데이터 요소들을 다루어야할 때 유용한 것 같다. 개념에 대해서 간단히 그려보았다. 빨간색 직사각형이 데이터를 sliding할 배열이고 검정색 직사각형 내에는 8개의 데이터가 들어있다. 빨간색 직사각형은 검은색 배열을 한칸씩 sliding하며 Data를 뽑아낼 수도 있고 연산..

article thumbnail
끄적
maengkyun/CV 2021. 8. 25. 21:53

SIFT features 물체 전체를 매칭 Spatial Pyramid Matching - 이미지들의 특징들이 이 장면이어떤 종류인지 단서를 줄 수 있다. Support Vector Algorithm 적용 Image Classification Pipeline assume given set of discrete labels {dog, cat, truck, plane} Problem: Semantic gap --> pixel wise Challenges: Deformation, Occlusion, Background clutter, Intraclass variation image classifier ex) def predic(image): return class_label test image 1, 50000..