How to load a trained model from a checkpoint.
if the model is set via settings
classification_model:
target: autoalbument.faster_autoaugment.models.ClassificationModel
num_classes: 10
architecture: resnet50 #mobilenetv2_100
pretrained: False
from typing import Tuple
import segmentation_models_pytorch as smp
import timm
from torch import Tensor, nn
from torch.nn import Flatten
import pytorch_lightning as pl
I pulled the model class from autoalbument/autoalbument/faster_autoaugment/models/main_model.py
RuntimeError: Error(s) in loading state_dict for ClassificationModel:
Missing key(s) in state_dict: "base_model.conv1.weight" ... "policy_model.sub_policies.99.stages.3.operations.13.saved_image_shape".
How to load a trained model from a checkpoint. if the model is set via settings classification_model: target: autoalbument.faster_autoaugment.models.ClassificationModel num_classes: 10 architecture: resnet50 #mobilenetv2_100 pretrained: False
I pulled the model class from autoalbument/autoalbument/faster_autoaugment/models/main_model.py
created model
when loading weights into the model, an error appears
RuntimeError: Error(s) in loading state_dict for ClassificationModel: Missing key(s) in state_dict: "base_model.conv1.weight" ... "policy_model.sub_policies.99.stages.3.operations.13.saved_image_shape".