pub struct ContinuousQNetworkConfig {
pub num_layers: usize,
pub hidden_dim: usize,
pub use_orthogonal_init: bool,
pub activation: BurnActivation,
pub seed: Option<u64>,
}Expand description
Configuration for ContinuousQNetwork architecture.
Mirrors crate::policy::q_network::QNetworkBurnConfig but adds the
depth/activation knobs SAC critics want (the default SAC critic is a
2-layer, 256-wide ReLU MLP per Haarnoja et al. 2018). Held as a
separate type so the critic can be tuned independently of the actor.
Fields§
§num_layers: usizeNumber of hidden layers in the trunk. Only 2 or 3 are
supported; anything else is treated as 2.
Width of every hidden layer.
use_orthogonal_init: boolIf true, initialize hidden-layer weights with orthogonal
(gain sqrt(2)) and the Q-head with gain = 0.01. Set false
for Burn’s stock Kaiming-uniform default.
activation: BurnActivationActivation applied between hidden layers.
seed: Option<u64>Optional construction seed. When Some, every layer is built
from a deterministic, StdRng-driven weight buffer (see
crate::policy::seeded_init) so two constructions with the same
seed produce bit-identical critics. When None (the default)
Burn’s unseedable Initializer path is used verbatim. Twin
critics should be seeded differently (or left unseeded) so they
are decorrelated.
Implementations§
Source§impl ContinuousQNetworkConfig
impl ContinuousQNetworkConfig
Sourcepub fn with_seed(self, seed: u64) -> Self
pub fn with_seed(self, seed: u64) -> Self
Set the construction seed, enabling the deterministic host-side
init path in ContinuousQNetwork::with_config.
Builder-style; returns self for chaining:
ContinuousQNetworkConfig::default().with_seed(42).
Trait Implementations§
Source§impl Clone for ContinuousQNetworkConfig
impl Clone for ContinuousQNetworkConfig
Source§fn clone(&self) -> ContinuousQNetworkConfig
fn clone(&self) -> ContinuousQNetworkConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for ContinuousQNetworkConfig
Source§impl Debug for ContinuousQNetworkConfig
impl Debug for ContinuousQNetworkConfig
Auto Trait Implementations§
impl Freeze for ContinuousQNetworkConfig
impl RefUnwindSafe for ContinuousQNetworkConfig
impl Send for ContinuousQNetworkConfig
impl Sync for ContinuousQNetworkConfig
impl Unpin for ContinuousQNetworkConfig
impl UnsafeUnpin for ContinuousQNetworkConfig
impl UnwindSafe for ContinuousQNetworkConfig
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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>
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>
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