Google Earth Engine Tutorial-29: Otsu Thresholding for Water Body Detection

Поделиться
HTML-код
  • Опубликовано: 27 авг 2024
  • code link: github.com/Ami...

Комментарии • 34

  • @okaagastya3635
    @okaagastya3635 3 месяца назад

    good tutorial appreciate

    • @amirhosseinahrarigee
      @amirhosseinahrarigee  3 месяца назад

      welcome. thanks for the feedback. please share the content and channel with your friends.

  • @stephenomar3650
    @stephenomar3650 2 месяца назад

    Thank you very much sir. You are doing a great job. Your content is very helpful! 🙏

    • @amirhosseinahrarigee
      @amirhosseinahrarigee  2 месяца назад

      happy to hear that. please share the content and channel with your community.

  • @wndcndra8752
    @wndcndra8752 3 месяца назад

    Thank you, you help me a lot for the script

    • @amirhosseinahrarigee
      @amirhosseinahrarigee  3 месяца назад

      Welcome. please share the content with your community. Will try to share more tutorials.

  • @Halal_hacks
    @Halal_hacks 4 месяца назад

    Truly best video

  • @user-eu6ii9ju4q
    @user-eu6ii9ju4q 8 дней назад

    great work....what if the threshold values is a range within the adjusted histogram .....

    • @amirhosseinahrarigee
      @amirhosseinahrarigee  2 дня назад

      put the otsu function in a loop to get the threshold for each time

  • @ekawahyuningsih_23
    @ekawahyuningsih_23 3 месяца назад

    What is the content of 'users/OEEL/lib:loadAll' ? and how do I find the library in GEE? and I have tried it but the error is like this "In users/OEEL/lib:/internal
    1-th input should be of type for ee.ImageCollection, but was ee.Image"

    • @amirhosseinahrarigee
      @amirhosseinahrarigee  2 месяца назад

      Please check out this website: www.open-geocomputing.org/OpenEarthEngineLibrary/

  • @vasilica-danuthorodnic9667
    @vasilica-danuthorodnic9667 4 месяца назад

    It is possible to apply this method in order to be able to delineate built-up areas from bare soil? (because the twi types of land cover present a similar spectral response).

    • @amirhosseinahrarigee
      @amirhosseinahrarigee  4 месяца назад

      Yes it is possible but the input file must be a urban built up index. Have you see this tutorial:
      ruclips.net/video/vutyioErpHQ/видео.html

    • @vasilica-danuthorodnic9667
      @vasilica-danuthorodnic9667 4 месяца назад

      @@amirhosseinahrarigee, It would be interesting te create a script where we generate our built-up index and bare soil index from Landsat datasets and then to apply the Otsu threshold to delineate built-up area.

  • @ElaheZafarian
    @ElaheZafarian 3 месяца назад

    I used this code for the the Normalized Burn Ratio. But I gut "Error generating chart: User memory limit exceeded' and 'User memory limit exceede'.. can you help me

  • @uma9183
    @uma9183 4 месяца назад +1

    Sir, ocean salinity mapping using GEE

  • @user-rb1fr7ob5j
    @user-rb1fr7ob5j Месяц назад

    How do you have it so that when you write code you get tooltips, i.e. writing options?

  • @utsavpoudel7034
    @utsavpoudel7034 22 дня назад

    I got error message 'Computation timed out'. What can i do now sir?

  • @khaledalkaraki732
    @khaledalkaraki732 4 месяца назад

    Thanks dear. Could you make video about image fusion for the data especially MODIS 8-days with 500 m to be 10 m based on sentinel 2? and thank you again ❤

    • @amirhosseinahrarigee
      @amirhosseinahrarigee  4 месяца назад +1

      welcome, will try to make fusion related tutorials in google earth engine.

  • @AgriCo-lab
    @AgriCo-lab 4 месяца назад

    Thank you so much fro this awesome vedio.
    could you please cover monthly forest fire please .

  • @utsavpoudel7034
    @utsavpoudel7034 22 часа назад

    //Load Area of Nepal
    var country = ee.FeatureCollection("USDOS/LSIB/2017")
    var table = country.filter(ee.Filter.eq("COUNTRY_NA","Nepal"))
    Map.centerObject(table, 6)
    //Load NASADEM
    var image = ee.Image("NASA/NASADEM_HGT/001")
    var elevation = image.select('elevation')
    Map.addLayer(elevation.clip(table),{},'Elevation')
    //Elevation above 3600m
    var elev3600 = elevation.gt(3600)
    Map.addLayer(elev3600.clip(table).updateMask(elev3600),{},'Elevation3600')
    //Load Sentinel-2a data and filter by date and region
    var sentinel2 = ee.ImageCollection("COPERNICUS/S2_SR_HARMONIZED")
    .filterDate('2022-01-01','2022-12-30')
    .map(function(img){
    var bands = img.select('B.*')
    var ndwi = bands.normalizedDifference(['B3','B8']).rename('ndwi')
    var ndwielev3600 = ndwi.updateMask(elev3600)
    .reproject({
    crs: 'EPSG:4326',
    scale: 500 // Downsample to 500 meters
    });
    return ndwielev3600.copyProperties(img, img.propertyNames())
    })
    Map.addLayer(sentinel2,{},'Sentinel-2a')


    // Import OEEL library
    var oeel=require('users/OEEL/lib:loadAllSF')
    // Apply Otsu Threshold
    var otsu = sentinel2.map(function(image) {
    return oeel.ImageCollection.OtsuThreshold(ee.ImageCollection([image]), 'ndwi');
    }).mosaic(); // Combine the thresholded images
    print(otsu)
    print(
    ui.Chart.image.histogram(otsu,table,500)
    )

    var thr = ee.Number(otsu.reduce(ee.Reducer.mean()).reduceRegion({
    reducer: ee.Reducer.mean(),
    geometry:table,
    scale:500
    }).values().get(0));

    print ('water body threshold', thr)

    var water = sentinel2.mean().gt(thr) // Apply threshold to the mean NDWI image
    Map.addLayer(water.updateMask(water), {palette: 'blue'}, 'Water Bodies')
    Can you please look in this code and edit this? I keep getting user memory exceeded and computation timed out.

  • @Ramilacookware
    @Ramilacookware 4 месяца назад

    سلام دوستان یه سوال علمی دارم .
    من اگه با اکسل trendline یه فایل csv بدست بیارم از اون یه معادله بیرون بکشم R2 شاخص خطا تناسب معادله با خط مثلا ۹۰درصد بشه ،
    آیا از روی اون معادله میشه پیش بینی کنم ?
    (یا حتما باید با پایتون کلی رگرسیون با NUMPY ... بزنم )
    ببخشید سوالم خارج از موضوع بود🙏

    • @amirhosseinahrarigee
      @amirhosseinahrarigee  4 месяца назад

      با سلام . متاسفانه اعضای این گروه تخصص آماری ندارند. با عرض پوزش از خدمت شما.

  • @space-time-somdeep
    @space-time-somdeep 4 месяца назад

    Thank you sir

  • @uma9183
    @uma9183 4 месяца назад

    Coastal Strom mapping using Google Earth engine

    • @amirhosseinahrarigee
      @amirhosseinahrarigee  4 месяца назад

      Coastal monitoring tutorial: ruclips.net/video/Bkck4a7wKYg/видео.html