migrate geo_comparison into api.py