combining two neural networks (net1 is trained & net2 is untrained) in one bigger network

15 Ansichten (letzte 30 Tage)
I have two shallow neural network models net1, net2.
I have a trained net1. Then I need to connect a net2 to a net1. Hence I treat the combined (net2+net1) as one large net and then train the big net . However, during the second training phase, we only need to update the weights corresponding to net2 (and keep net1 weights fixed). Is it possible in MATLAB? any suggested links or articles to perform this part.
  2 Kommentare
Xin Yee Tai
Xin Yee Tai am 14 Jul. 2020
Could you please share the code to build the neural network on the last photo? Thank you.
Russdsp am 11 Jun. 2021
Yes please share code. the green box in the middle doesnt seem like a layer- how is that there?

Melden Sie sich an, um zu kommentieren.

Akzeptierte Antwort

Hiro Yoshino
Hiro Yoshino am 10 Jan. 2020

Weitere Antworten (1)

Greg Heath
Greg Heath am 12 Jan. 2020
1. Save the outputs of net1 in a file
2. Use the file to train net2
  2 Kommentare
Beatriz Martins
Beatriz Martins am 12 Jan. 2020
Bearbeitet: Beatriz Martins am 12 Jan. 2020
Greg Heath,
I am trying to save the output of a net1 and use it to train net2. However, during training of net1 the trainFasterRCNNObjectDetector function added new layers (initially I have 25 layers and the output of net1 has 35) and I get an invalid network. Do you know how can I solve this problem?
Abdelwahab Afifi
Abdelwahab Afifi am 20 Jun. 2020
Bearbeitet: Abdelwahab Afifi am 22 Jun. 2020
Greg Heath,
more clarification please. I wanna train the bigger networok which combined of (untrained net2 + trained net1)

Melden Sie sich an, um zu kommentieren.


Mehr zu Sequence and Numeric Feature Data Workflows finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by