geost.base.CptCollection.change_horizontal_reference#
- CptCollection.change_horizontal_reference(to_epsg: str | int | CRS)#
Change the horizontal reference (i.e. coordinate reference system, crs) of the collection to the given target crs.
- Parameters:
to_epsg (str | int | CRS) – EPSG of the target crs. Takes anything that can be interpreted by pyproj.crs.CRS.from_user_input().
Examples
To change the collection’s current horizontal reference to WGS 84 UTM zone 31N:
>>> self.change_horizontal_reference(32631)
This would be the same as:
>>> self.change_horizontal_reference("epsg:32631")
As Pyproj is very flexible, you can even use the CRS’s full official name:
>>> self.change_horizontal_reference("WGS 84 / UTM zone 31N")