Emerging Properties in Self-Supervised Vision TransformersMathilde Caron, Hugo Touvron, Ishan Misra, Hervé Jégou, Julien Mairal, Piotr Bojanowski, Armand JoulinIn this paper, we question if self-supervised learning provides new properties to Vision Transformer (ViT) that stand out compared to convolutional networks (convnets). Beyond the fact that adapting self-supervised methods to this archite..
if results[0].masks is not None: combined_mask = np.zeros(frame.shape[:2], dtype=np.uint8) clss = results[0].boxes.cls.cpu().tolist() masks = results[0].masks.xy for mask, cls in zip(masks, clss): mask_color = colors(int(cls), True) # random_color = tuple(np.random.randint(0, 256, 3).tolist()) # mask_color = (int(random_color[0]), int(random_color[1]), int(random..
1. Install CVAT1. 구축 환경OS : Ubuntu도커 설치 필수NVIDIA 드라이버 설치 되어 있어야 함NVIDIA-Container-Toolkit 설치되어 있어야 함2. 설치 방법https://opencv.github.io/cvat/docs/administration/basics/installation/최신 버전으로 설치할 경우 도커를 올리고 접속하면, Cannot connect to the server 문제가 발생하므로, 가능하면 2.2.0 버전으로 설치할 것을 추천함(2024.03 기준 최신 모델로 진행해보니 문제 없었음)Cannot connect to the serverMake sure the CVAT backend and all necessary services (Database, ..
행동 영상을 탐지한 후에, BBOX에 한글을 출력하고자 했다. ChatGPT에게 물어봤더니, opencv-contrib-python을 설치한 후 freetype 으로 하면 된다고 아래와 같이 샘플 코드를 제시해주었다 import cv2 import numpy as np # 이미지를 불러오거나 생성합니다. image = np.zeros((500, 500, 3), dtype=np.uint8) # freetype 모듈을 불러옵니다. ft = cv2.freetype.createFreeType2() # 한글 폰트 파일의 경로를 지정합니다. font_path = 'NanumGothic.ttf' ft.loadFontData(fontFileName=font_path, id=0) # 이미지에 텍스트를 추가합니다. 위치,..
windows 10에서 pycocotools를 설치시, pip install pycocotools 라고 하면 에러가 발생한다. 나의 경우는 다음과 같은 순서로 진행을 하였다 관리자 권한으로 anaconda prompt 열기 visual studio community 설치하기 conda install git Cython pip install "git+https://github.com/philferriere/cocoapi.git#egg=pycocotools&subdirectory=PythonAPI" 나의 경우는 Visual studio community가 설치되지 않은 상태에서 pycocotools를 설치하려고 하니까 오류가 발생했다
크롬에서 미디어를 재생시키려면 mp4 확장자로 해야하고, (avi는 다운로드가 되는 불상사가 발생) opencv에서는 mp4를 VideoWriter를 하고자 하면 보통 코덱을 'mp4v'로 아래와 같이 설정한다. fourcc = cv2.VideoWriter_fourcc(*'mp4v') 하지만 슬프게도 mp4v 코덱은 웹에서 플레이가 안 되므로, fourcc = cv2.VideoWriter_fourcc(*'h264') or fourcc = cv2.VideoWriter_fourcc(*'x264') 등으로 시도를 해서 많이들 해결 하는데, 나 같은 경우에는 OpenCV4로 버전을 다시 빌드해줘도 해결이 안 되서 아침 내내 삽질을 했다. 그래서 로그 화면이 더러워져도... ffmpeg를 설지한 다음, 영상을 변..