def initialize_ocean_and_thresholds(world, ocean_level=1.0):
    e = world.layers['elevation'].data
    ocean = fill_ocean(e, ocean_level)
    hl = find_threshold_f(e, 0.10)  # the highest 10% of all (!) land are declared hills
    ml = find_threshold_f(e, 0.03)  # the highest 3% are declared mountains
    e_th = [('sea', ocean_level),
            ('plain', hl),
            ('hill', ml),
            ('mountain', None)]
    harmonize_ocean(ocean, e, ocean_level)
    world.set_ocean(ocean)
    world.set_elevation(e, e_th)
    world.set_sea_depth(sea_depth(world, ocean_level))
Calculate the ocean, the sea depth and the elevation thresholds
dataset/ETHPy150Open Mindwerks/worldengine/worldengine/generation.py/initialize_ocean_and_thresholds