ResNeXt¶
The ResNeXt model is based on the "Aggregated Residual Transformations for Deep Neural Networks" paper.
Architecture overview¶
This paper improves the ResNet architecture by increasing the width of bottleneck blocks
The key takeaways from the paper are the following:
- increases the number of channels in bottlenecks
- switches to group convolutions to balance the number of operations
Model builders¶
The following model builders can be used to instantiate a ResNet model, with or
without pre-trained weights. All the model builders internally rely on the
ResNet base class.
resnext50_32x4d
¶
resnext50_32x4d(pretrained: bool = False, checkpoint: Checkpoint | None = None, progress: bool = True, **kwargs: Any) -> ResNet
ResNeXt-50 from "Aggregated Residual Transformations for Deep Neural Networks"
| PARAMETER | DESCRIPTION |
|---|---|
pretrained
|
If True, returns a model pre-trained on ImageNet
TYPE:
|
checkpoint
|
If specified, load that checkpoint on the model
TYPE:
|
progress
|
If True, displays a progress bar of the download to stderr
TYPE:
|
kwargs
|
keyword args of
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
ResNet
|
classification model |
ResNeXt50_32x4d_Checkpoint
¶
Bases: Enum
IMAGENETTE
class-attribute
instance-attribute
¶
IMAGENETTE = _checkpoint(arch='resnext50_32x4d', url='https://github.com/frgfm/Holocron/releases/download/v0.2.1/resnext50_32x4d_224-5832c4ce.pth', acc1=0.9455, acc5=0.9949, sha256='5832c4ce33522a9eb7a8b5abe31cf30621721a92d4f99b4b332a007d81d071fe', size=92332638, num_params=23000394, commit='6e32c5b578711a2ef3731a8f8c61760ed9f03e58', train_args='./imagenette2-320/ --arch resnext50_32x4d --batch-size 64 --mixup-alpha 0.2 --amp --device 0 --epochs 100 --lr 1e-3 --label-smoothing 0.1 --random-erase 0.1 --train-crop-size 176 --val-resize-size 232 --opt adamw --weight-decay 5e-2')
Source code in holocron/models/classification/resnet.py
resnext101_32x8d
¶
resnext101_32x8d(pretrained: bool = False, checkpoint: Checkpoint | None = None, progress: bool = True, **kwargs: Any) -> ResNet
ResNeXt-101 from "Aggregated Residual Transformations for Deep Neural Networks"
| PARAMETER | DESCRIPTION |
|---|---|
pretrained
|
If True, returns a model pre-trained on ImageNet
TYPE:
|
checkpoint
|
If specified, load that checkpoint on the model
TYPE:
|
progress
|
If True, displays a progress bar of the download to stderr
TYPE:
|
kwargs
|
keyword args of
TYPE:
|
| RETURNS | DESCRIPTION |
|---|---|
ResNet
|
classification model |