Save and load "head" layers of yolov5? Change model 'head' during inference?

Example problem.
I have a dataset of traffic scenes that include different brands of cars. For example, the same image can have a ‘BMW’ or a ‘Mercedes’ among other brands. I want to create a model, where each head classifies a ‘car model’ for a specific brand, like the image below.


Since the input images and therefore most of the features should be the same, I wish to train one model then freeze it’s feature-extractor, and sort of transfer learn the same model for the categories using the pretrained feature extractor.

During inference, I want to
1st → load model with ‘BMW’ head and do its prediction
2nd → Load ‘Mercedes’ Head
3rd → Swap “BMW” head with ‘Mercedes’ head
4th → Do the prediction of ‘Mercedes’ head.

All of this process has the objective of saving computational resources, since the weights of the feature extracting backbone is the same, I only want to save the weights of the head.

With this, i kind of want to “future-prof” the model, and train only a specific head when a new car model launches.

I’m new to deep learning, so I don’t know if ‘multihead’ is the right name? And is this feasible with manipulation of the YAML files?

Best regards.