Installation

Notes: Please use Ubuntu 22.04 / WSL 2 . And set your CUDA and CUDNN env (CUDA 12.1 is the best)

1. Set Python Env


wget -O Miniforge3.sh "https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-$(uname)-$(uname -m).sh"

bash Miniforge3.sh -b -p "${HOME}/conda"

source "${HOME}/conda/etc/profile.d/conda.sh"

conda activate

conda create -n hfdev python==3.10.12

conda activate hfdev

2. Install Python Library


cd ~/zhihu/

pip install -r requirements.txt

3. Structure


|--📁 zhihu
    |-📁 datasets
    |-📁 fine-tuning
    |-📁 inferences
    |-📁 models
    |-📁 models-cache

📁 datasets - Store the data that needs fine-tuning as a json format file

📁 fine-tuning - Stores Microsoft Olive settings in olive-config.json and saves a cache of related steps

📁 inferences - For Inferences models,and test result

📁 models - Save Microsoft Phi-3 mini models

📁 models-cache - Save Fine-tuning Microsoft Phi-3 mini models