python script to prepare all catalogues