Mosaic – arrange iOS icons by color using an evolutionary algorithm logo

Mosaic – arrange iOS icons by color using an evolutionary algorithm

Free
FreeFree tier
Type
Open Source

About Mosaic – arrange iOS icons by color using an evolutionary algorithm

Mosaic is an open-source tool that automatically arranges icons on an iOS home screen by color using evolutionary algorithms, specifically a genetic algorithm. It treats the arrangement problem as a multi-objective optimization (similar to the Traveling Salesman Problem) where icons are placed to fit well with neighbors, each page has a color theme, and pages are filled to a viable maximum. The tool uses a chromosome representation with page-break elements and applies mutation, elitism, and culling over generations. It supports only the classic grid layout (left-to-right, top-to-bottom) and does not support widgets or iOS 18's arbitrary icon placement. Built with CMake, OpenCV, and Google Test, it includes example executables for grayscale icons, colored icons, and real icons from a directory.

Key Features

Arranges iOS home screen icons by color using a genetic algorithm
Multi-objective scoring: icon-neighbor fit, page color theme, maximum page fill
Supports classic grid layout (left-to-right, top-to-bottom)
Open-source, built with CMake, OpenCV, and Google Test
Includes example executables for grayscale, colored, and real icons
Command-line usage with configurable population size and genetic parameters

Pros & Cons

Pros
  • Fully automatic arrangement using a sophisticated evolutionary algorithm
  • Free and open-source, allowing customization and study
  • Multiple example scripts for different icon types
  • No need for manual sorting or third-party services
Cons
  • Only supports classic grid layout, not widgets or iOS 18 arbitrary placement
  • Requires building from source with CMake and OpenCV, not a ready-to-use app
  • No graphical user interface; command-line only
  • May require manual extraction of icons from screenshots
  • Limited to iOS devices with classic grid home screen

Best For

Organizing iOS home screen icons by color for a visually pleasing layoutAutomating the arrangement of app icons without manual sortingExperimenting with genetic algorithms applied to combinatorial optimization problems

FAQ

What iOS layouts does Mosaic support?
Mosaic only supports the classic grid layout where icons fill screens from left to right and top to bottom. Widgets and the arbitrary icon placement introduced in iOS 18 are not supported.
How does the arrangement algorithm work?
It uses a genetic algorithm (evolutionary algorithm). The arrangement of icons is encoded as a chromosome, and a population of random arrangements evolves over generations using mutation (swapping two icon positions), elitism, culling of low-fitness individuals, and fresh random individuals. The fitness function considers color harmony with neighbors, page color theme, and maximizing page fill.
What do I need to build and run Mosaic?
You need CMake to build the project, OpenCV for image processing, and Google Test for testing. Examples are provided for grayscale icons, colored icons, and real icons from a directory.
Is Mosaic free?
Yes, Mosaic is open-source and free. The GitHub repository is public with no pricing.