[windows10 error] accelerate: command not found
Previously I was able to execute the code commands successfully under linux, but when I switched to windows10, I already installed accelerate, but when I executed the code sample below dreambooth, I had the following issues when I executed the bash script in CMD.
error content below
(large-model) J:\Program\lib_diffusers\diffusers\examples\dreambooth>bash run-dog.bash
run-dog.bash: line 5: accelerate: command not found
bash script content below
export MODEL_NAME="runwayml/stable-diffusion-v1-5"
export INSTANCE_DIR="./data/dog"
export OUTPUT_DIR="model_fine-tune-dog"
accelerate launch train_dreambooth.py \
--pretrained_model_name_or_path=$MODEL_NAME \
--instance_data_dir=$INSTANCE_DIR \
--output_dir=$OUTPUT_DIR \
--instance_prompt="a photo of sks dog" \
--resolution=512 \
--train_batch_size=1 \
--gradient_accumulation_steps=1 \
--learning_rate=5e-6 \
--lr_scheduler="constant" \
--lr_warmup_steps=0 \
--max_train_steps=400 \
--push_to_hub
If I run the following command from the command line, I get the following
(large-model) J:Program\lib_diffusers\diffusers\examples\dreambooth>accelerate
usage: accelerate <command> [<args>]
positional arguments:
{config,estimate-memory,env,launch,tpu-config,test}
accelerate command helpers
optional arguments:
-h, --help show this help message and exit
Can anyone give me some advice on this problem?Thanks~
In your bash script you need to activate the conda environment probably
The above result has my conda environment running,so your advise like this:
export MODEL_NAME="runwayml/stable-diffusion-v1-5"
export INSTANCE_DIR="./data/dog"
export OUTPUT_DIR="model_fine-tune-dog"
conda activate large-model # add command
accelerate launch train_dreambooth.py \
--pretrained_model_name_or_path=$MODEL_NAME \
--instance_data_dir=$INSTANCE_DIR \
--output_dir=$OUTPUT_DIR \
--instance_prompt="a photo of sks dog" \
--resolution=512 \
--train_batch_size=1 \
--gradient_accumulation_steps=1 \
--learning_rate=5e-6 \
--lr_scheduler="constant" \
--lr_warmup_steps=0 \
--max_train_steps=400 \
--push_to_hub
but it still dont't work. And it tells me that I have the following error
(large-model) J:\Program\lib_diffusers\diffusers\examples\dreambooth>bash run-dog.bash
run-dog.bash: line 4: conda command not found
run-dog.bash: line 5: accelerate: command not found
Try source activate. This is the root of your problem that you will need to try and figure out. I don't have much experience with windows sadly to advise other than that :)
Thank you for your answer, I will try to fix it:)
This issue has been automatically marked as stale because it has not had recent activity. If you think this still needs to be addressed please comment on this thread.
Please note that issues that do not follow the contributing guidelines are likely to be ignored.