Keras: Multi gpu model creates duplicate model names for models with multiple outputs

Created on 4 Jan 2018  路  3Comments  路  Source: keras-team/keras

Seems to be caused at the model merge stage:

https://github.com/keras-team/keras/blob/45c838cc7a0a5830c0a54a2f58f48fc61950eb68/keras/utils/training_utils.py#L172_L177

Reproduction of the issue here along with possible change that would suffix the model names running on the GPUs uniquely by index:
https://gist.github.com/BAXTER001/5b2bb9e65b587f893298f09102436ca1
https://github.com/keras-team/keras/compare/master...BAXTER001:patch-1

Most helpful comment

Any updates on this one?
Also, I have found a quick fix if anybody is fine with hacks :) Just set the names manually before calling multi_gpu_model():

model.output_names = ['output_1', 'output_2', 'output_3', ...]
model = multi_gpu_model(model)

All 3 comments

Any updates on this one?
Also, I have found a quick fix if anybody is fine with hacks :) Just set the names manually before calling multi_gpu_model():

model.output_names = ['output_1', 'output_2', 'output_3', ...]
model = multi_gpu_model(model)

bump

Any updates?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

harishkrishnav picture harishkrishnav  路  3Comments

braingineer picture braingineer  路  3Comments

nryant picture nryant  路  3Comments

anjishnu picture anjishnu  路  3Comments

Imorton-zd picture Imorton-zd  路  3Comments