refactor: restructure project - scripts at root level
This commit is contained in:
@@ -20,6 +20,6 @@ pip install transformers datasets trl peft accelerate bitsandbytes deepspeed
|
|||||||
|
|
||||||
# Run training
|
# Run training
|
||||||
echo "Starting training with accelerate..."
|
echo "Starting training with accelerate..."
|
||||||
accelerate launch --multi_gpu --num_processes 2 training/scripts/train.py --config training/configs/ornith-35b-lora.yaml
|
accelerate launch --multi_gpu --num_processes 2 train.py --config training/configs/ornith-35b-lora.yaml
|
||||||
|
|
||||||
echo "Training completed!"
|
echo "Training completed!"
|
||||||
@@ -110,8 +110,8 @@ def train(config_path):
|
|||||||
from datasets import load_dataset
|
from datasets import load_dataset
|
||||||
import os
|
import os
|
||||||
|
|
||||||
# Get dataset paths - go up to project root
|
# Get dataset paths - training/data/ is relative to project root
|
||||||
repo_root = Path(__file__).parent.parent.parent
|
repo_root = Path(__file__).parent
|
||||||
train_path = str(repo_root / "training" / "data" / "train.jsonl")
|
train_path = str(repo_root / "training" / "data" / "train.jsonl")
|
||||||
test_path = str(repo_root / "training" / "data" / "test.jsonl")
|
test_path = str(repo_root / "training" / "data" / "test.jsonl")
|
||||||
print(f"Looking for dataset at: {train_path}")
|
print(f"Looking for dataset at: {train_path}")
|
||||||
@@ -206,7 +206,7 @@ def check_setup(config_path):
|
|||||||
|
|
||||||
# Check dataset files
|
# Check dataset files
|
||||||
print("\n3. Dataset files:")
|
print("\n3. Dataset files:")
|
||||||
repo_root = Path(__file__).parent.parent.parent # Go up to project root
|
repo_root = Path(__file__).parent
|
||||||
train_path = repo_root / "training" / "data" / "train.jsonl"
|
train_path = repo_root / "training" / "data" / "train.jsonl"
|
||||||
test_path = repo_root / "training" / "data" / "test.jsonl"
|
test_path = repo_root / "training" / "data" / "test.jsonl"
|
||||||
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
# Run training with distributed setup
|
|
||||||
|
|
||||||
set -e
|
|
||||||
|
|
||||||
# Install accelerate if not present
|
|
||||||
pip install -q accelerate
|
|
||||||
|
|
||||||
# Launch with accelerate
|
|
||||||
# Note: Use the dedicated train-on-this-server.sh instead
|
|
||||||
echo "See train-on-this-server.sh for full setup"
|
|
||||||
Reference in New Issue
Block a user