RivWidthCloudPaper icon indicating copy to clipboard operation
RivWidthCloudPaper copied to clipboard

Error: Image.clip: Parameter 'input' is required. (Error code: 3)

Open Muhammad-Waqas5012 opened this issue 1 year ago • 0 comments

// Assume 'aoi' is defined elsewhere in your script as your area of interest var geometry = ee.Geometry.Rectangle([-89.60113734129604, 36.32131447834511, -89.48990076903041, 36.451768707535194]);

Map.addLayer(geometry) Map.centerObject(geometry) // Load the RivWidthCloud function library var fns = require('users/eeProject/RivWidthCloudPaper:rwc_landsat.js');

// Load the image using its ID and clip it to the area of interest var image = ee.Image("LANDSAT/LC08/C02/T1_L2/LC08_023034_20231002").clip(geometry);

// Setting the parameters for the RivWidthCloud (RWC) function var rwc = fns.rwGenSR('Jones2019', 4000, 333, 500, geometry);

// Apply the RWC function to the clipped image var widths = rwc(image);

// Remove the geometry before exporting the width as a CSV file widths = widths.map(function(f) { return(f.setGeometry(null)); });

// Export the result as a CSV file into Google Drive Export.table.toDrive({ collection: widths, description: "Landsat_Widths", folder: "asad", fileNamePrefix: "widths", fileFormat: "CSV" });

"When I run this code for my study area using a single image it gives me this error, I even try this method, downloaded the image in assests and then I applied the code same error is coming."

Muhammad-Waqas5012 avatar Feb 14 '24 16:02 Muhammad-Waqas5012