mirror of
https://github.com/hpcaitech/ColossalAI.git
synced 2025-09-02 17:46:42 +00:00
[FIX BUG] convert env param to int in (#5934)
This commit is contained in:
@@ -44,7 +44,7 @@ class DistCoordinator(metaclass=SingletonMeta):
|
||||
self._rank = dist.get_rank()
|
||||
self._world_size = dist.get_world_size()
|
||||
# this is often passed by launchers such as torchrun
|
||||
self._local_rank = os.environ.get("LOCAL_RANK", -1)
|
||||
self._local_rank = int(os.environ.get("LOCAL_RANK", -1))
|
||||
|
||||
@property
|
||||
def rank(self) -> int:
|
||||
|
Reference in New Issue
Block a user