#[non_exhaustive]pub enum DistributedError {
Show 15 variants
InvalidConfig {
reason: &'static str,
},
WorldSizeOutOfRange {
world_size: usize,
max: usize,
},
RankOutOfRange {
rank: usize,
world_size: usize,
},
NonLoopbackNotAllowed {
addr: SocketAddr,
},
DuplicateRank {
rank: usize,
},
WorldSizeMismatch {
expected: usize,
got: usize,
},
UnexpectedRank {
expected: usize,
got: usize,
},
Protocol {
message: String,
},
Timeout {
phase: &'static str,
},
PeerDisconnected,
Io(Error),
Poisoned,
Backend(BackendError),
GradientLengthMismatch {
expected: usize,
got: usize,
},
Other {
message: String,
},
}Expand description
分散学習の設定・集合の確立・集合通信・分散ステップが返す型付きエラー。
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
InvalidConfig
設定値が不正(固定文の理由)。
WorldSizeOutOfRange
world_size が 1..=max の範囲外。
RankOutOfRange
ランク番号が 0..world_size の範囲外。
NonLoopbackNotAllowed
非 loopback のアドレスが opt-in 無しで指定された。
Fields
§
addr: SocketAddr該当アドレス。
DuplicateRank
同じランク番号が重複した。
WorldSizeMismatch
ピアの world_size が自分と違う。
UnexpectedRank
リングの相手が想定したランクと違う。
Protocol
ワイヤ上のプロトコル違反(固定文と数値だけの説明。ピアのバイト列は含まない)。
Timeout
タイムアウト。
PeerDisconnected
ピアが切断した。
Io(Error)
その他の I/O エラー。
Poisoned
communicator が poisoned(以後の集合通信は拒否される。復旧は範囲外)。
Backend(BackendError)
勾配の読み出しや optimizer ステップが返したバックエンドエラー。
GradientLengthMismatch
平坦化した勾配の長さがストアの総要素数と一致しない。
Other
将来 autodiff 側に増える variant の受け皿(現行の全 variant はこれ以外へ写る)。
Trait Implementations§
Source§impl Debug for DistributedError
impl Debug for DistributedError
Source§impl Display for DistributedError
impl Display for DistributedError
Source§impl Error for DistributedError
impl Error for DistributedError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Auto Trait Implementations§
impl !RefUnwindSafe for DistributedError
impl !UnwindSafe for DistributedError
impl Freeze for DistributedError
impl Send for DistributedError
impl Sync for DistributedError
impl Unpin for DistributedError
impl UnsafeUnpin for DistributedError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more