resnet18¶
- torchvision.models.resnet18(*, weights: Optional[ResNet18_Weights] = None, progress: bool = True, **kwargs: Any) ResNet[source]¶
ResNet-18 from Deep Residual Learning for Image Recognition.
- Parameters:
weights (
ResNet18_Weights, optional) – The pretrained weights to use. SeeResNet18_Weightsbelow for more details, and possible values. By default, no pre-trained weights are used.progress (bool, optional) – If True, displays a progress bar of the download to stderr. Default is True.
**kwargs – parameters passed to the
torchvision.models.resnet.ResNetbase class. Please refer to the source code for more details about this class.