I did not use the mosaic filter
As a demo I just used a regular RGB image, then applied Blur -> Pixelise to get the mosaic. Converted that to indexed with 37 colours, so all a bit of a fudge. There are other applications that will make a mosaic using a set of sub-images. The linux one is called metapixel.
Also a gmic filter picture-mosaic, just about to go off and try it.
edit: Ok tried it for the mosaic generation, not for counting tiles. Made a folder of coloured tiles, (10x10 pngs) and applied the gmic filter - example https://i.imgur.com/ln6Oa4C.jpg

Also a gmic filter picture-mosaic, just about to go off and try it.
edit: Ok tried it for the mosaic generation, not for counting tiles. Made a folder of coloured tiles, (10x10 pngs) and applied the gmic filter - example https://i.imgur.com/ln6Oa4C.jpg