shrinkage::ChainFusedLasso
Shrinkage for Rust · rust · 0.3.0
Source: src/penalty/chain_fused_lasso.rs
Complete penalty l1 * sum_j |beta[j]| + fusion * sum_j w[j] * |beta[j+1]-beta[j]|.
Edges follow feature order and contribute once. Both strengths and every weight must be finite and nonnegative, checked on use. Unit weights are implicit unless Self::with_weights supplies exactly one weight per edge. Zero weights cut the chain. Empty and single-feature chains have no edges. Intercepts are excluded, and coefficients refer to the optimization scale.
The exact complete prox uses weighted taut strings followed by uniform L1 soft-thresholding. Value and prox take O(p) time; the prox reuses O(p) CPU storage. crate::ProximalGradient supports typed and runtime problems, and crate::HybridCoordinateDescent adds exact Gaussian segment-coordinate sweeps.
use ;
let penalty = new.with_weights;
assert!;
let mut output = ;
penalty.prox?;
assert_eq!;
Inherent implementation
Source: src/penalty/chain_fused_lasso.rs
fusion
Source: src/penalty/chain_fused_lasso.rs
Configured multiplier of the edge weights.
l1
Source: src/penalty/chain_fused_lasso.rs
Configured L1 strength.
new
Source: src/penalty/chain_fused_lasso.rs
Set independent L1 and fusion strengths, with implicit unit weights.
weights
Source: src/penalty/chain_fused_lasso.rs
Explicit edge weights, or None for implicit unit weights.
with_weights
Source: src/penalty/chain_fused_lasso.rs
Supply one finite, nonnegative weight per adjacent edge, checked on use.
Implementation of Clone
Source: src/penalty/chain_fused_lasso.rs
clone
Source: src/penalty/chain_fused_lasso.rs
Implementation of Debug
Source: src/penalty/chain_fused_lasso.rs
fmt
Source: src/penalty/chain_fused_lasso.rs
Implementation of GapSafePenalty
Source: src/screening/penalty.rs
dual_feasible
Source: src/screening/penalty.rs
has_sparsity
Source: src/screening/penalty.rs
prox_zeroed
Source: src/screening/penalty.rs
screen_zeros
Source: src/screening/penalty.rs
Implementation of Partition
Source: src/solver/hybrid/segment.rs
labels
Source: src/solver/hybrid/segment.rs
new
Source: src/solver/hybrid/segment.rs
rebuild
Source: src/solver/hybrid/segment.rs
set_screened
Source: src/solver/hybrid/segment.rs
set_weights
Source: src/solver/hybrid/segment.rs
sweep_observed
Source: src/solver/hybrid/segment.rs
Sized> sweep_visits
Source: src/solver/hybrid/segment.rs
values
Source: src/solver/hybrid/segment.rs
Implementation of PathPenalty
Source: src/path/penalty.rs
AtStrength
Source: src/path/penalty.rs
type AtStrength = ChainFusedLasso;at_strength
Source: src/path/penalty.rs
maximum_penalty
Source: src/path/penalty.rs
Implementation of Penalty
Source: src/penalty/chain_fused_lasso.rs
Error
Source: src/penalty/chain_fused_lasso.rs
type Error = FitError;validate_input
Source: src/penalty/chain_fused_lasso.rs
value
Source: src/penalty/chain_fused_lasso.rs
Implementation of ProximalPenalty
Source: src/penalty/chain_fused_lasso.rs
gap_safe
Source: src/penalty/chain_fused_lasso.rs
prox
Source: src/penalty/chain_fused_lasso.rs
Implementation of ReducedCoordinatePenalty
Source: src/solver/hybrid.rs
State
Source: src/solver/hybrid.rs
type State = State;Implementation of Freeze
Implementation of RefUnwindSafe
Implementation of Send
Implementation of Sync
Implementation of Unpin
Implementation of UnsafeUnpin
Implementation of UnwindSafe
Implementation of Any
Implementation of Borrow
Implementation of BorrowMut
Implementation of ByRef
Implementation of CastableFrom
Implementation of CastableFrom
Implementation of CloneToUninit
Implementation of From
Implementation of Imply
Implementation of Into
Implementation of IntoEither
Implementation of Pointable
Implementation of Read
Implementation of Same
Implementation of SupersetOf
Implementation of ToOwned
Implementation of TryFrom
Implementation of TryInto
