Convert various geo formats (tiff, netcdf into csv)
Installing this package is as easy as:
Ubuntu:
sudo apt-get install libgdal-dev
Mac:
brew install gdal
Install python dependencies
pip install .
geo-converter -i /path/to/input/dem.tif -o /path/to/output/output.csv
-i
is mandatory, -o
is optional and if ommited will take the name of the input file and default to parquet
factory = GeoConverterFactory(args.input, args.output)
converter = factory.get_converter()
converter.convert()
Create a new converter class extending BaseConverter and register it:
factory = GeoConverterFactory(args.input, args.output)
factory.register_converter(file_type, converter_class)
- Convert tiff files to csv
- Convert netcdf files to csv
If there are issues while installing gdal run and make sure you have the same gdal version in setup.py
gdal-config --version
xr.open_dataset(self.input_file, decode_times=False)