반응형
250x250
Notice
Recent Posts
Recent Comments
Link
«   2024/04   »
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
Archives
Today
Total
관리 메뉴

가끔 보자, 하늘.

bitsandbytes windows용으로 빌드하기 본문

개발 이야기/개발툴 및 기타 이야기

bitsandbytes windows용으로 빌드하기

가온아 2024. 2. 7. 16:21

빌드를 위해서는 vs의 cmake가 필요합니다. vs2022를 설치했다면 아래와 유사한 경로에 위치해 있습니다.

C:\Program Files\Microsoft Visual Studio\2022\Community\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin

이를 환경 변수에 등록해 powershell 혹은 console에서 cmake를 실행할 수 있게 설정해 두세요.

bitsandbytes는 아래 링크의 내용을 참고해 빌드하면 됩니다.

https://huggingface.co/docs/bitsandbytes/main/en/installation?OS+system=Windows

 

Installation

 

huggingface.co

git clone https://github.com/TimDettmers/bitsandbytes.git && cd bitsandbytes/
pip install -r requirements-dev.txt
cmake -DCOMPUTE_BACKEND=cuda -S .
cmake --build . --config Release
python -m build --wheel

빌드가 완료되면 bitsandbytes와 bitsandbytes.egg-info 폴더가 생성되며 이 두 폴더를 복사해 필요한 프로젝트에 적용하면 됩니다. 

반응형