Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion keras_cv/visualization/plot_image_gallery.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ def plot_image_gallery(
) # batch_size from within passed `tf.data.Dataset`
else:
batch_size = (
images.shape[0] if len(images.shape) == 4 else 1
np.asarray(images).shape[0] if len(images.shape) == 4 else 1
) # batch_size from np.array or single image

rows = rows or int(math.ceil(math.sqrt(batch_size)))
Expand Down