Expert_Sparsity
[ACL 2024] Not All Experts are Equal: Efficient Expert Pruning and Skipping for Mixture-of-Experts Large Language Models
파일 탐색기
- __init__.py
- build.py
- dataset.py
- math_calib_construction.py
- benchmark_speed.py
- __init__.py
- dynamic_skipping.py
- expert_pruning.py
- __init__.py
- modeling_mixtral.py
- wrapper.py
- .gitignore
- LICENSE
- main.py
- README.md
# CDN으로 사용하기
jsDelivrjsDelivr는 공개 GitHub 리포지토리를 별도 설정 없이 CDN으로 즉시 서빙합니다. 버전과 파일을 고르면 웹페이지에 바로 붙일 수 있는 링크와 예시 코드가 만들어집니다.
명령어 용어집
이 문서에서 사용된 명령어를 모아봤습니다. 낯선 명령어가 있다면 펼쳐서 확인해보세요.
accelerate
설명 보기 ▼
accelerate
Accelerate는 동일한 PyTorch 코드를 모든 분산 환경 구성에서 실행할 수 있게 해주는 라이브러리입니다.
더 많은 정보: <https://huggingface.co/docs/accelerate/index>.
accelerate env
실행환경 정보 출력:
accelerate config
대화형으로 구성 파일 생성:
accelerate estimate-memory {{name/model}}
다양한 데이터 타입을 사용하여 Hugging Face 모델을 실행하는 데 필요한 예상 GPU 메모리 비용을 출력:
conda activate
설명 보기 ▼
conda activate
Activate a conda environment.
See also: `conda deactivate`.
conda activate myenv
Activate an existing environment named `myenv`:
conda activate {{path/to/myenv}}
Activate an existing environment located at custom path:
conda activate --stack myenv
Stack `myenv` environment on top of a previous environment making libraries/commands/variables from both accessible:
conda create
설명 보기 ▼
conda create
Create new conda environments.
conda create {{[-y|--yes]}} {{[-n|--name]}} py39 python=3.9 "numpy>=1.11" scipy
Create a new environment named `py39`, install Python 3.9, NumPy v1.11 or above in it, and the latest stable version of SciPy. Say yes to all confirmations:
conda create {{[-n|--name]}} myenv --file {{file1.yml}} --file {{file2.yml}}
Create a new environment named `myenv` and install packages listed in files:
conda create {{[-p|--prefix]}} {{path/to/myenv}}
Create a new environment at a custom path (i.e. prefix):
conda install
설명 보기 ▼
conda install
Install packages into an existing conda environment.
conda install {{package1 package2 ...}}
Install one or more package into the currently active conda environment:
conda install {{[-c|--channel]}} conda-forge {{package}}
Install a single package into the currently active conda environment using channel conda-forge:
conda install {{[-c|--channel]}} conda-forge --override-channels {{package}}
Install a single package into the currently active conda environment using channel conda-forge and ignoring other channels:
python
설명 보기 ▼
python
Python 언어 인터프리터.
더 많은 정보: <https://docs.python.org/using/cmdline.html>.
python
REPL(대화형 셸) 시작:
python {{path/to/file.py}}
특정 Python 파일 실행:
python -i {{path/to/file.py}}
특정 Python 파일 실행 후 REPL 시작:
