Skip to content

Commit

Permalink
refactor: Update deprecated class usage
Browse files Browse the repository at this point in the history
  • Loading branch information
lorenzomammana committed Jun 3, 2024
1 parent b3fbbcf commit 001a1ef
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/anomalib/models/padim/torch_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@

from anomalib.models.components import FeatureExtractor, MultiVariateGaussian
from anomalib.models.components.feature_extractors import dryrun_find_featuremap_dims
from anomalib.models.components.feature_extractors.timm import TimmFeatureExtractor
from anomalib.models.padim.anomaly_map import AnomalyMapGenerator
from anomalib.pre_processing import Tiler

Expand Down Expand Up @@ -87,7 +88,7 @@ def __init__(
self.layers = layers
self.backbone = backbone

self.feature_extractor = FeatureExtractor(
self.feature_extractor = TimmFeatureExtractor(
backbone=self.backbone, layers=layers, pre_trained=pre_trained, pretrained_weights=pretrained_weights
)
self.n_features_original, self.n_patches = _deduce_dims(self.feature_extractor, input_size, self.layers)
Expand Down

0 comments on commit 001a1ef

Please sign in to comment.