Skip to content
Snippets Groups Projects
Commit 51d6ed42 authored by Daniel Ecer's avatar Daniel Ecer
Browse files

fixed combined image didn't include last layer

parent 05f7d201
No related branches found
No related tags found
No related merge requests found
...@@ -162,6 +162,9 @@ def combine_image(batch_images, replace_black_with_white=False): ...@@ -162,6 +162,9 @@ def combine_image(batch_images, replace_black_with_white=False):
combined_image = replace_black_with_white_color(combined_image) combined_image = replace_black_with_white_color(combined_image)
return combined_image return combined_image
def remove_last(a):
return a[:-1]
def add_model_summary_images( def add_model_summary_images(
tensors, dimension_colors, dimension_labels, tensors, dimension_colors, dimension_labels,
use_separate_channels=False, use_separate_channels=False,
...@@ -190,7 +193,11 @@ def add_model_summary_images( ...@@ -190,7 +193,11 @@ def add_model_summary_images(
outputs, outputs,
dimension_colors_with_unknown dimension_colors_with_unknown
) )
batch_images_excluding_unknown = batch_images[:-2] if has_unknown_class else batch_images batch_images_excluding_unknown = (
remove_last(batch_images)
if has_unknown_class
else batch_images
)
for i, (batch_image, dimension_label) in enumerate(zip( for i, (batch_image, dimension_label) in enumerate(zip(
batch_images, dimension_labels_with_unknown)): batch_images, dimension_labels_with_unknown)):
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment