Python ogr2ogr command not found

I have a python code that worked before, I converted data from shp to kml, I'm working on colab, I was getting the result with the following code after running all the necessary libraries, but my code has been giving the following error for about 1 month. What do you think could be the reason?

ogr2ogr -f KML {b}'.kml' {b}'.shp'

/bin/bash: ogr2ogr: command not found

ogr2ogr -f KML {b}'.kml' {b}'.shp'

/bin/bash: ogr2ogr: command not found

Upvotes: 1

Views: 397

Answers (1)

Mary M
Mary M

Reputation: 11

I also had this problem. I assume something must have changed in the default environment. Try adding the following command. It worked for me:

!apt-get install gdal-bin

Upvotes: 1

Related Questions