From 50b8ce67474c948ecc5efad8f682584a5b6a41df Mon Sep 17 00:00:00 2001 From: Kartikay Khandelwal Date: Fri, 26 Apr 2024 11:53:26 -0700 Subject: [PATCH] fix configs --- recipes/configs/phi3/mini_full.yaml | 14 +++++--------- recipes/configs/phi3/mini_full_low_memory.yaml | 16 ++++++---------- 2 files changed, 11 insertions(+), 19 deletions(-) diff --git a/recipes/configs/phi3/mini_full.yaml b/recipes/configs/phi3/mini_full.yaml index 19271778b4..756dc82ca1 100644 --- a/recipes/configs/phi3/mini_full.yaml +++ b/recipes/configs/phi3/mini_full.yaml @@ -1,10 +1,6 @@ # Config for multi-device full finetuning in full_finetune_distributed.py # using a Phi3 Mini 4K Instruct # -# This config uses hyperparameters based on small set of experiments and information -# available on various forums. These are not meant to replicate the numbers -# from the paper -# # This config assumes that you've run the following command before launching # this run: # tune download microsoft/Phi-3-mini-4k-instruct --output-dir ./Phi-3-mini-4k-instruct --hf-token --ignore-patterns "" @@ -19,12 +15,12 @@ # # This config works best when the model is being fine-tuned on 2+ GPUs. # Single device full finetuning requires more memory optimizations. It's -# best to use 7B_full_single_device.yaml for those cases +# best to use mini_low_memory.yaml for those cases # Tokenizer tokenizer: _component_: torchtune.models.phi3.phi3_tokenizer - path: /data/users/kartikayk/cpts/Phi-3-mini-4k-instruct/tokenizer.model + path: /tmp/cpts/Phi-3-mini-4k-instruct/tokenizer.model # Dataset dataset: @@ -39,13 +35,13 @@ model: checkpointer: _component_: torchtune.utils.FullModelHFCheckpointer - checkpoint_dir: /data/users/kartikayk/cpts/Phi-3-mini-4k-instruct + checkpoint_dir: /tmp/Phi-3-mini-4k-instruct checkpoint_files: [ model-00001-of-00002.safetensors, model-00002-of-00002.safetensors ] recipe_checkpoint: null - output_dir: /data/users/kartikayk/cpts/Phi-3-mini-4k-instruct + output_dir: /tmp/Phi-3-mini-4k-instruct model_type: PHI3_MINI resume_from_checkpoint: False @@ -74,5 +70,5 @@ dtype: bf16 metric_logger: _component_: torchtune.utils.metric_logging.DiskLogger log_dir: ${output_dir} -output_dir: /tmp/Mistral-7B-v0.1/ +output_dir: /tmp/Phi-3-mini-4k-instruct log_every_n_steps: null diff --git a/recipes/configs/phi3/mini_full_low_memory.yaml b/recipes/configs/phi3/mini_full_low_memory.yaml index 1427b9ad63..e2c96c9658 100644 --- a/recipes/configs/phi3/mini_full_low_memory.yaml +++ b/recipes/configs/phi3/mini_full_low_memory.yaml @@ -1,10 +1,6 @@ # Config for single device full finetuning in full_finetune_single_device.py # using a Phi3 Mini 4K Instruct # -# This config uses hyperparameters based on small set of experiments and information -# available on various forums. These are not meant to replicate the numbers -# from the paper -# # This config assumes that you've run the following command before launching # this run: # tune download microsoft/Phi-3-mini-4k-instruct --output-dir ./Phi-3-mini-4k-instruct --hf-token --ignore-patterns "" @@ -14,19 +10,19 @@ # pip install bitsandbytes # # To launch on a single device, run the following command from root: -# tune run full_finetune_single_device --config recipes/config/phi3/mini_full_low_memory.yaml +# tune run full_finetune_single_device --config recipes/configs/phi3/mini_full_low_memory.yaml # # You can add specific overrides through the command line. For example # to override the checkpointer directory while launching training # you can run: -# tune run full_finetune_single_device --config recipes/config/phi3/mini_full_low_memory.yaml checkpointer.checkpoint_dir= +# tune run full_finetune_single_device --config recipes/configs/phi3/mini_full_low_memory.yaml checkpointer.checkpoint_dir= # # This config works only for training on single device. # Tokenizer tokenizer: _component_: torchtune.models.phi3.phi3_tokenizer - path: /data/users/kartikayk/cpts/Phi-3-mini-4k-instruct/tokenizer.model + path: /tmp/Phi-3-mini-4k-instruct/tokenizer.model # Dataset dataset: @@ -41,13 +37,13 @@ model: checkpointer: _component_: torchtune.utils.FullModelHFCheckpointer - checkpoint_dir: /data/users/kartikayk/cpts/Phi-3-mini-4k-instruct + checkpoint_dir: /tmp/Phi-3-mini-4k-instruct checkpoint_files: [ model-00001-of-00002.safetensors, model-00002-of-00002.safetensors ] recipe_checkpoint: null - output_dir: /data/users/kartikayk/cpts/Phi-3-mini-4k-instruct + output_dir: /tmp/Phi-3-mini-4k-instruct model_type: PHI3_MINI resume_from_checkpoint: False @@ -79,5 +75,5 @@ compile: False metric_logger: _component_: torchtune.utils.metric_logging.DiskLogger log_dir: ${output_dir} -output_dir: /tmp/Mistral-7B-v0.1/ +output_dir: /tmp/Phi-3-mini-4k-instruct log_every_n_steps: null