lm-sys / lm-sys/FastChat

Llama-2 loss and learning rate is always 0 after first step

Open
#2,072 4 comments 6 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
39.5k
Forks
4.8k
PR merge metrics
No merged PRs in 30d

Description

The log appears like this:

{'loss': 1.8709, 'learning_rate': 0.0, 'epoch': 0.0}

{'loss': 0.0, 'learning_rate': 0.0, 'epoch': 0.01}

{'loss': 0.0, 'learning_rate': 0.0, 'epoch': 0.01}

{'loss': 0.0, 'learning_rate': 0.0, 'epoch': 0.01}

{'loss': 0.0, 'learning_rate': 0.0, 'epoch': 0.01}

{'loss': 0.0, 'learning_rate': 0.0, 'epoch': 0.02}

{'loss': 0.0, 'learning_rate': 0.0, 'epoch': 0.02}

{'loss': 0.0, 'learning_rate': 0.0, 'epoch': 0.02}

{'loss': 0.0, 'learning_rate': 0.0, 'epoch': 0.02}

{'loss': 0.0, 'learning_rate': 0.0, 'epoch': 0.03}

{'loss': 0.0, 'learning_rate': 0.0, 'epoch': 0.03}

{'loss': 0.0, 'learning_rate': 0.0, 'epoch': 0.03}

{'loss': 0.0, 'learning_rate': 0.0, 'epoch': 0.04}

{'loss': 0.0, 'learning_rate': 0.0, 'epoch': 0.04}

{'loss': 0.0, 'learning_rate': 0.0, 'epoch': 0.04}

{'loss': 0.0, 'learning_rate': 0.0, 'epoch': 0.04}

{'loss': 0.0, 'learning_rate': 0.0, 'epoch': 0.05}:

Script:

deepspeed --include="localhost:0,1,2,3" --master_port=20001 fastchat/train/train_mem.py \
--deepspeed playground/deepspeed_config_s6.json \
--model_name_or_path NousResearch/Redmond-Puffin-13B \
--data_path data/dummy_conversation.json \
--output_dir PUFFIN_ON_ZOOTIEZ \
--num_train_epochs 2 \
--per_device_train_batch_size 2 \
--per_device_eval_batch_size 2 \
--gradient_accumulation_steps 8 \
--evaluation_strategy epoch \
--save_strategy "steps" \
--save_steps 1200 \
--save_total_limit 10 \
--learning_rate 1e-4 \
--weight_decay 0. \
--warmup_ratio 0.1 \
--lr_scheduler_type "cosine" \
--logging_steps 1 \
--fp16 \
--cache_dir "/tmp" \
--model_max_length 4096 \
--gradient_checkpointing True \
--lazy_preprocess True

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the reported command with fastchat/train/train_mem.py and playground/deepspeed_config_s6.json, using the listed Llama-2 training settings. Inspect the training and logging path around the first optimizer step. Done means the loss and learning-rate logs no longer remain at 0.0 after the first step.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
machine-learning
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.