computefence 0.2.8__tar.gz → 0.2.9__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: computefence
3
- Version: 0.2.8
3
+ Version: 0.2.9
4
4
  Summary: Don't lose another RunPod checkpoint to ephemeral disk before your job bills.
5
5
  License-Expression: MIT
6
6
  Requires-Python: >=3.8
@@ -0,0 +1 @@
1
+ __version__ = "0.2.9"
@@ -48,7 +48,15 @@ def record_run(results: list):
48
48
  import torch
49
49
  gpu_count = torch.cuda.device_count()
50
50
  except Exception:
51
- gpu_count = 0
51
+ try:
52
+ import subprocess
53
+ result = subprocess.run(
54
+ ["nvidia-smi", "--query-gpu=name", "--format=csv,noheader"],
55
+ capture_output=True, text=True, timeout=5
56
+ )
57
+ gpu_count = len(result.stdout.strip().splitlines()) if result.returncode == 0 else 0
58
+ except Exception:
59
+ gpu_count = 0
52
60
 
53
61
  from computefence import __version__
54
62
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: computefence
3
- Version: 0.2.8
3
+ Version: 0.2.9
4
4
  Summary: Don't lose another RunPod checkpoint to ephemeral disk before your job bills.
5
5
  License-Expression: MIT
6
6
  Requires-Python: >=3.8
@@ -1 +0,0 @@
1
- __version__ = "0.2.8"
File without changes
File without changes
File without changes