mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
Revert "Enable possibly-undefined error code (#118533)"
This reverts commit 4f13f69a45ef53747e2eefffd65d91ce840b431b. Reverted https://github.com/pytorch/pytorch/pull/118533 on behalf of https://github.com/clee2000 due to sorry i'm trying to figure out a codev merge conflict, if this works i'll be back to rebase and merge ([comment](https://github.com/pytorch/pytorch/pull/118533#issuecomment-1917695185))
This commit is contained in:
@ -209,7 +209,7 @@ def estimate_nccl_collective_runtime(snode: "BaseSchedulerNode") -> float:
|
||||
nsteps = nRanks - 1
|
||||
|
||||
# Convert bus BW to algorithm BW (tensor bytes / algoBW = actual execution time)
|
||||
ratio = (1.0 * nRanks) / nsteps # type: ignore[possibly-undefined]
|
||||
ratio = (1.0 * nRanks) / nsteps
|
||||
bandwidth = busBw * ratio
|
||||
# Convert GB/s to GB/ns
|
||||
bandwidth_GB_per_ns = bandwidth / 1e9
|
||||
@ -236,7 +236,7 @@ def estimate_nccl_collective_runtime(snode: "BaseSchedulerNode") -> float:
|
||||
if nNodes > 1:
|
||||
netOverhead = 1.0 # getNetOverhead(comm);
|
||||
intraLat = max(intraLat, netOverhead)
|
||||
latency += (nsteps - nInterSteps) * intraLat + nInterSteps * interLat # type: ignore[possibly-undefined]
|
||||
latency += (nsteps - nInterSteps) * intraLat + nInterSteps * interLat
|
||||
# Convert us to ns
|
||||
latency_ns = latency * 1e3
|
||||
|
||||
|
Reference in New Issue
Block a user