fix emojies
This commit is contained in:
@@ -30,14 +30,14 @@ print()
|
||||
|
||||
# Check GPU availability
|
||||
if torch.cuda.is_available():
|
||||
print(f"GPU Available: ✅ CUDA")
|
||||
print(f"GPU Available: CUDA")
|
||||
print(f" Device: {torch.cuda.get_device_name(0)}")
|
||||
print(f" Memory: {torch.cuda.get_device_properties(0).total_memory / 1024**3:.2f} GB")
|
||||
|
||||
# Move model to GPU
|
||||
device = torch.device('cuda')
|
||||
model = model.to(device)
|
||||
print(f" Model moved to GPU ✅")
|
||||
print(f" Model moved to GPU")
|
||||
|
||||
# Test forward pass
|
||||
batch_size = 1
|
||||
@@ -50,18 +50,18 @@ if torch.cuda.is_available():
|
||||
with torch.no_grad():
|
||||
outputs = model(price_data_1m=price_data_1m)
|
||||
|
||||
print(f" Forward pass successful ✅")
|
||||
print(f" Forward pass successful")
|
||||
print(f" GPU memory allocated: {torch.cuda.memory_allocated() / 1024**2:.2f} MB")
|
||||
print(f" GPU memory reserved: {torch.cuda.memory_reserved() / 1024**2:.2f} MB")
|
||||
|
||||
elif hasattr(torch.version, 'hip') and torch.version.hip:
|
||||
print(f"GPU Available: ✅ ROCm/HIP")
|
||||
print(f"GPU Available: ROCm/HIP")
|
||||
device = torch.device('cuda') # ROCm uses 'cuda' device name
|
||||
model = model.to(device)
|
||||
print(f" Model moved to GPU ✅")
|
||||
print(f" Model moved to GPU")
|
||||
else:
|
||||
print(f"GPU Available: ❌ CPU only")
|
||||
print(f"GPU Available: CPU only")
|
||||
print(f" Training will use CPU (slower)")
|
||||
|
||||
print()
|
||||
print("Model ready for training! 🚀")
|
||||
print("Model ready for training!")
|
||||
|
||||
Reference in New Issue
Block a user