MCPcopy Index your code
hub / github.com/naturomics/CapsNet-Tensorflow / mergeImgs

Function mergeImgs

utils.py:63–71  ·  view source on GitHub ↗
(images, size)

Source from the content-addressed store, hash-verified

61
62
63def mergeImgs(images, size):
64 h, w = images.shape[1], images.shape[2]
65 imgs = np.zeros((h * size[0], w * size[1], 3))
66 for idx, image in enumerate(images):
67 i = idx % size[1]
68 j = idx // size[1]
69 imgs[j * h:j * h + h, i * w:i * w + w, :] = image
70
71 return imgs
72
73
74if __name__ == '__main__':

Callers 1

save_imagesFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected