Supernova25million / run_minimal_training.py
algorythmtechnologies's picture
Upload folder using huggingface_hub
8174855 verified
#!/usr/bin/env python3
"""Run a minimal training to validate everything works."""
import sys
sys.path.append('.')
from supernova.train import train
def run_minimal_training():
"""Run minimal training for validation."""
print("πŸš€ Starting minimal training run...")
try:
train(
config_path="./configs/supernova_25m.json",
data_config_path="./configs/data_sources.yaml",
seq_len=256,
batch_size=1,
grad_accum=1,
lr=3e-4,
warmup_steps=2,
max_steps=10,
save_every=5,
out_dir="./test_checkpoints",
seed=42
)
print("βœ… Minimal training completed successfully!")
return True
except Exception as e:
print(f"❌ Training failed: {e}")
import traceback
traceback.print_exc()
return False
if __name__ == "__main__":
success = run_minimal_training()
if success:
print("πŸŽ‰ Training pipeline validated successfully!")
else:
print("πŸ’₯ Training pipeline validation FAILED!")
exit(0 if success else 1)