Zeel commited on
Commit
42d40bd
1 Parent(s): 81256b8

small change

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -64,7 +64,7 @@ def preprocess_gdf(gdf):
64
  def calculate_ndvi(image, nir_band, red_band):
65
  nir = image.select(nir_band)
66
  red = image.select(red_band)
67
- ndvi = nir.subtract(red).divide(nir.add(red)).rename("NDVI")
68
  return image.addBands(ndvi)
69
 
70
 
 
64
  def calculate_ndvi(image, nir_band, red_band):
65
  nir = image.select(nir_band)
66
  red = image.select(red_band)
67
+ ndvi = (nir.subtract(red)).divide(nir.add(red)).rename("NDVI")
68
  return image.addBands(ndvi)
69
 
70