일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 |
- sk
- awscloudbootcamp
- lg합격
- LGD
- LG인적성후기
- lg인재상
- SK인턴
- DT
- LG인적성
- lg적성검사
- aws
- 2022awscloudbootcamp
- 2022awscloud
- awsacademy
- lgenius
- aws클라우드부트캠프
- awscloud
- lg디스플레이산학장학생
- LG디스플레이
- cloudarchitecting
- SKT
- cloudfoundations
- SKC&C
- sktai
- lg인적성합격
- lg인성검사
- e1인턴
- 데이터분석
- lg인적성모의고사
- lg디스플레이lgenius
- Today
- Total
냥냥파워
RuntimeError: CUDA error: device-side assert triggered 본문
RuntimeError: CUDA error: device-side assert triggered
hjhjhj0028 2022. 6. 16. 14:28https://brstar96.github.io/shoveling/device_error_summary/
이유를 알 수 없는 GPU 에러 정리(device-side assert, CUDA error, CUDNN_STATUS_NOT_INITIALIZED 등등…)
brstar96.github.io
https://towardsdatascience.com/cuda-error-device-side-assert-triggered-c6ae1c8fa4c3
CUDA error: Device-side assert triggered
A beginner friendly solution walkthrough for this frustrating (and common) error in Pytorch
towardsdatascience.com
GPU 작업을 하다보면
정말 알 수 없는 cuda 에러가 뜰 때가 있다
가장 기본적으로 체크해야 하는건
1. 모델 input output size가 dataset과 맞는지
2. 모델 input으로 들어가는 data class num이 0부터 시작하는지
이게 무슨 소리냐면
github issues를 보니까
제일 많은 따봉을 받은 선생님께서 말씀하시길,
Another common reason for this error could be if the number of classes in the labels does not match with the number of units in the final softmaxed Linear Layer for a classification problem. I recently encountered this accidentally.
즉 input class num이랑 model 연산 후 output class num이
같아야 제대로 구동한다는 것이다
3. cuda와 cudnn등 환경 구축을 제대로 했는지(버전 호환 문제 등)
보통 이 3가지면 해결이 되는데
(nvidia -smi랑 torch.cuda.is_available() is True가 될 때)
그래도 안된다면 무한 구글링과 디버깅이 답이다!
device를 cuda말고 cpu로 돌려보는 것도 방법..
'POSTECH AI연구원 인턴' 카테고리의 다른 글
RuntimeError: cuda runtime error(10): invalid device ordinal (0) | 2022.06.17 |
---|---|
YoloV5 Detector로 OCR 데이터셋 한글 검출하기 (0) | 2022.06.16 |
YOLACT : Real Time instance segmentation (0) | 2022.06.07 |
Digitization of Old Korean Texts with Obsolete Korean Characters andSuggestion for Improvement of Information Sharing (0) | 2022.06.07 |
고서 한자 인식 OCR (0) | 2022.06.07 |