How to analyse images when objects vary in colour or size