Borrar filtros
Borrar filtros

How to add new classes into a pre-trained network?

6 visualizaciones (últimos 30 días)
Da Huang
Da Huang el 9 de Ag. de 2020
Respondida: Farshid PirahanSiah el 19 de Oct. de 2020
Say I already have a pre-trained network who can classify class A, class B and class C. Is there anyway I can re-train it only using some data from a new class D (instead of using a full dataset that contains data from all four classes), so that the new network is capable of classify both class A, B, C and D? Also wondering if it's achieveable by changing some certain settings during the transfer learning process?
Thanks in advance.

Respuestas (2)

Gouri Chennuru
Gouri Chennuru el 13 de Ag. de 2020
Hi Da Huang,
You can load the model, train and remove the last layer, change its other neurons and train the network again! This will basically train the the last layer from the beginning.
or, you can also specify the number of classes in the last fully connected layer of your network as the Output size argument.
You can refer to this link for more information.
Hope this Helps!

Farshid PirahanSiah
Farshid PirahanSiah el 19 de Oct. de 2020
Several ways to add new class to trained model which require just training for new classes.
- Transfer Learning Twice
- Continual learning approaches
* Regularization
* Expansion
* Rehearsal

Categorías

Más información sobre Image Data Workflows en Help Center y File Exchange.

Productos


Versión

R2020a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by