Understand RADIO1D (Research) architecture
mainRADIO1D is a Vision Transformer variant that compresses spatial tokens into a variable-length 1D sequence of "global tokens" during encoding, which can then be reconstructed via a decoder.
It exposes two "necks":
encoder: Compressed 1D global tokens, shape(B, num_tokens, C).decoder: Spatially-reconstructed features, shape(B, H*W, C).
You can control the number of tokens and which neck to return using these arguments in radio_model() or RADIOModel.forward():
num_tokens(Optional[int]): The number of tokens to keep in the 1D encoder output (defaults to the model's maximum).neck_name(Optional[str]): Which neck's output to return (defaults to returning a dictionary of all necks for multi-neck models).