• Google Earth Engine(GEE)——sentinel-1数据中乌克兰附近数据缺失轨道36缺失


     

    ee.Filter.maxDifference(difference, leftField, rightValue, rightField, leftValue)
    创建一个一元或二元过滤器,如果左和右操作数都在给定的最大差值内,则通过。如果作为一个连接条件,这个数字的差异被用作一个连接措施。

    参数。
    difference (Float):
    过滤器将返回真值的最大差异。

    leftField (String, default: null):
    左边操作数的选择器。如果指定了leftValue,就不应该指定。

    rightValue(对象,默认:null)。
    右边操作数的值。如果指定了rightField,则不应该指定。

    rightField(字符串,默认:null)。
    右边操作数的选择器。如果指定了rightValue,则不应该指定。

    leftValue(对象,默认:null)。
    左边操作数的值。如果指定了leftField,则不应该指定。

    返回。过滤器

    ee.Join.saveBest(matchKey, measureKey, outer)
    返回一个连接,将第一个集合中的每个元素与第二个集合中的匹配元素配对。具有最佳连接度量的匹配被作为一个额外的属性添加到每个结果中。当 withinDistance 或 maxDifference 过滤器被用作连接条件时,会产生连接测量。

    参数。
    matchKey(字符串)。
    用来保存匹配的键。

    measureKey (String)。
    用于保存匹配的连接条件的措施的键。

    outer(布尔值,默认:false)。
    如果为真,没有匹配的主行将被包括在结果中。

    返回。连接

    filterMetadata(name, operator, value)
    已删除。使用 filter() 与 ee.Filter.eq(), ee.Filter.gte() 等。

    通过元数据来过滤一个集合的快捷方式。这相当于this.filter(ee.Filter.metadata(..))。

    返回过滤后的集合。

    参数。
    this:collection(集合)。
    集合实例。

    name(字符串)。
    要过滤的属性名称。

    operator (String):
    比较运算符的名称。可能的值是。"等于"、"小于"、"大于"。

    "not_equals", "not_less_than", "not_greater_than", "start_with",

    "end_with", "not_starts_with", "not_ends_with", " contains",

    "不包含"。

    value(对象)。
      - 要比较的值。

    返回。集合

     

     

    代码:

    1. //乌克兰哨兵1A一致性:请看这里的细节。
    2. // https://medium.com/@gglemoine62/12-day-sentinel-1-coherence-a-test-case for-ukrain-998488bf589
    3. // 问题报告。
    4. // 由于ALU软件的一个错误,相对轨道36的一致性错过了IW2的中心子路径。
    5. // 但是,由于IW1和IW3没有问题,我们没有将它们排除在外。
    6. // 我们打算在该错误修复后立即替换它们。
    7. // COH12测试集有混合的VV(多数)和VH图像,都是单带的。
    8. // 这就是为什么ee.Image.select('VV')不起作用。按偏振过滤如下。
    9. var c12 = ee.ImageCollection('JRC/S1_COH_TEST').
    10. filterMetadata('system:index', 'ends_with', '_VV_coh12')
    11. print(c12.size())
    12. print(c12.first())
    13. Map.addLayer(c12, null, 'Mosaic', false)
    14. // 用S1_GRD_FLOAT加入COH12主站
    15. var s0 = ee.ImageCollection('COPERNICUS/S1_GRD_FLOAT').
    16. filterDate('2021-09-01', '2022-09-02').filterBounds(geometry)
    17. var masterDiffFilter = ee.Filter.maxDifference({
    18. difference: 10 * 1000,
    19. leftField: 'system:time_start',
    20. rightField: 'system:time_start'
    21. });
    22. var slaveDiffFilter = ee.Filter.maxDifference({
    23. difference: 10 * 1000,
    24. leftField: 'system:time_end',
    25. rightField: 'system:time_start'
    26. });
    27. // Define the join.
    28. var saveMasterJoin = ee.Join.saveBest({
    29. matchKey: 'masterImage',
    30. measureKey: 'timeDiff'
    31. });
    32. var saveSlaveJoin = ee.Join.saveBest({
    33. matchKey: 'slaveImage',
    34. measureKey: 'timeDiff'
    35. });
    36. // Apply the joins.
    37. var c12_joined = ee.ImageCollection(saveMasterJoin.apply(c12, s0, masterDiffFilter))
    38. // Promote the relativeOrbitNumber_start
    39. c12_joined = c12_joined.map(function(f) {
    40. return f.set('relativeOrbitNumber', ee.Image(f.get('masterImage')).get('relativeOrbitNumber_start'))
    41. })
    42. // Show the issue with relativeOrbitnumber 36
    43. Map.addLayer(c12_joined.filterMetadata('relativeOrbitNumber', 'equals', 36), {min: 0.2, max: 1}, "IW2 missing for rel orbit 36")
    44. Map.centerObject(geometry, 6)

  • 相关阅读:
    VK/D3D12_Visibility Buffer架构流程实现
    产品经理的秘密武器:提高效率的 6 种软件工具
    CentOS ARM 部署 kubernetes v1.24.6
    pg_rman 的编译和使用
    Mysql数据库指定某数据库或某表赋予增删改查操作权限各类划分权限的方法总结实战
    QMS系统在质量管理中的作用
    直接安装WSL2及安装Ubuntu到F盘
    神经网络NLP基础 循环神经网络 LSTM
    文心一言 VS 讯飞星火 VS chatgpt (97)-- 算法导论9.3 3题
    一篇博客告诉你什么是时间复杂度和空间复杂度(没有基础也能看懂)(这是学习数据结构及算法所必须掌握的基础)
  • 原文地址:https://blog.csdn.net/qq_31988139/article/details/126407184