본문 바로가기
728x90
반응형
SMALL

CUDA6

[Linux] NVIDIA GPU 사용을 위한 Ubuntu에 Tensorflow 설치 NVIDIA Driver  NVIDIA에서 제품에 맞는 드라이버를 설치한다. WSL2 설치  PowerShell에서 WLS2를 설치한다. wls --install PowerShell에서 nvidia-smi 명령으로 GPU 서버를 확인한다. Ubuntu-22.04를 사용한다. nvidia-smi Miniconda 설치 아래의 명령어를 터미널에 입력해 스크립트 파일을 다운로드 후에 실행한다. wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.shsudo bash Miniconda3-latest-Linux-x86_64.sh 경로를 “/home/{사용자 이름}/miniconda3”로 설정한다.  # conda 경로 설정export P.. 2024. 5. 28.
[PyTorch] AssertionError: Torch not compiled with CUDA enabled AssertionError: Torch not compiled with CUDA enabled torch와 cuda 버전이 맞지 않아 출력되는 에러이다. 따라서, 공식 홈페이지에서 가이드대로 설치를 진행한다. 현재 Windows의 PyTorch는 Python 3.8 ~ 3.11만 지원하고 Python 2.x는 지원되지 않으므로 torch 가상 환경으로 파이썬 버전을 설치한다. conda create --name torch python=3.9 torch 가상 환경을 활성화하고 CUDA 11.8 또는 12.1을 설치한다. pip3 install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118 그 다음, GPU를 사.. 2024. 3. 19.
[Windows] NVIDIA GPU 사용을 위한 Window Native에 Tensorflow 설치 NVIDIA Driver  NVIDIA에서 제품에 맞는 드라이버를 설치한다. WSL2 설치  PowerShell에서 WLS2를 설치한다. wls --install PowerShell에서 nvidia-smi 명령으로 GPU 서버를 확인한다. Ubuntu-22.04를 사용한다. nvidia-smi Miniconda 설치 아래의 명령어를 터미널에 입력해 스크립트 파일을 다운로드 후에 실행한다. wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.shsudo bash Miniconda3-latest-Linux-x86_64.sh 경로를 “/home/{사용자 이름}/miniconda3”로 설정한다.  # conda 경로 설정export P.. 2024. 2. 15.
[PyTorch] Segmentation fault (core dumped) Segmentation fault (core dumped) 동일한 버전의 cuda가 torch와 호환되지 않을 가능성이 있다. 사용 중인 torch 버전이 쿠다와 호환되지 않는 경우 torch를 다시 설치해야 한다. CUDA에는 두 개의 API가 있다. 하나는 런타임 API이고 다른 하나는 드라이버 API이다. 각 API에는 자체 버전이 있다. nvidia-smi의 CUDA는 런타임 API를 나타내며 GPU 드라이버에 의해 설치된다. nvcc의 CUDA는 CUDA 툴킷에 의해 설치된다다. https://pytorch.org/get-started/previous-versions/에서 nvidia-smi로 확인한 cuda 버전을 설치해준다. # CUDA 11.8conda install pytorch==2.5.. 2024. 1. 24.
Mojo Mojo Mojo는 Modular Inc.에서 개발한 프로그래밍 언어이다. 2023년 5월에 브라우저로 액세스할 수 있게 되었고 2023년 9월에 Linux에서 로컬로 액세스할 수 있게 되었다. 이 언어는 일부 Python 프로그램을 실행할 수 있다. Mojo는 Python의 유용성과 C의 성능을 결합하여 AI 하드웨어의 탁월한 프로그래밍 가능성과 AI 모델의 확장성을 실현한다. 다양한 하위 수준 AI 하드웨어를 프로그래밍할 수 있으며 C++ 또는 CUDA가 필요하지 않다. https://www.modular.com/mojo Mojo 🔥: Programming language for all of AI Mojo combines the usability of Python with the performance.. 2023. 9. 22.
[PyTorch] CUDA (Compute Unified Device Architecture) CUDA (Compute Unified Device Architecture) CUDA ("Compute Unified Device Architecture", 쿠다)는 그래픽 처리 장치 (GPU)에서 수행하는 (병렬 처리) 알고리즘을 C 프로그래밍 언어를 비롯한 산업 표준 언어를 사용하여 작성할 수 있도록 하는 GPGPU 기술이다. import torch torch.cuda.is_available() list0 = [1,2,3,4] x = torch.tensor(list0) x.is_cuda x = x.to('cuda') x.is_cuda import torch from torch import nn from torch.utils.data import DataLoader from torchvision imp.. 2022. 11. 21.
728x90
반응형
LIST