PatchMerging class

Merges 2x2 neighboring patches to reduce spatial resolution and increase feature dimension.

Inheritance

Constructors

PatchMerging({required int inDim})

Properties

hashCode int
The hash code for this object.
no setterinherited
inDim int
final
norm LayerNorm
final
outDim int
final
projection Layer
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

forward(List<ValueVector> x, int H, int W) List<ValueVector>
Forward pass for PatchMerging.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
parameters() List<Value>
override
toString() String
A string representation of this object.
inherited
zeroGrad() → void
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited