Skip to content

Conversation

@Yuksel-Rudy
Copy link
Collaborator

This feature requires the updates in drawLine2d in subsystem.py in MoorPy to be integrated. These changes are provided in this PR: NREL/MoorPy#58

  • The user can provide a set value of maximum depth to show the most transparent part of the line. By default, this is set to the water depth. But sometimes, we might be interested in limiting the depth to the first 200m for instance or to show the depth of which it can be affected by marine growth (e.g., -170m). This is added as a variable in kwargs called max_line_depth.

Here's an example of showing the first 170m of the water column:
Screenshot 2025-10-05 at 4 52 24 PM
This pull request adds the ability to color mooring lines by depth in the plot2d method of the Project class, including support for a colorbar and related options. The main changes introduce a new color_lineDepth argument, handle color mapping and validation, and update the plotting logic accordingly.

Enhancements to 2D Plotting of Moorings:

  • Added a color_lineDepth argument to the plot2d method in project.py, allowing users to color mooring lines based on their depth.
  • Included a max_line_depth option in the plotting kwargs to control the depth range for color mapping.
  • Implemented logic to set up depth-based color mapping for mooring lines, including error handling to prevent conflicts with bathymetry plotting.
  • Updated calls to drawLine2d for mooring lines to pass the new depth_cmap_settings parameter, enabling the actual depth-based coloring.

User Interface Improvements:

  • Added a colorbar to the plot when depth-based coloring is enabled and not in bare mode, providing a visual reference for line depths.

…ture requires the updates in drawLine2d in subsystem.py in MoorPy to be integrated.

- The user can provide a set value of maximum depth to show the most transparent part of the line. By default, this is set to the water depth. But sometimes, we might be interested in limiting the depth to the first 200m for instance or to show the depth of which it can be affected by marine growth (e.g., -170m). This is added as a variable in kwargs called max_line_depth.
@Yuksel-Rudy Yuksel-Rudy requested a review from mattEhall October 5, 2025 23:26
…ater column:

- adding an  option to only plot the line color based on depth for shared lines.
@Yuksel-Rudy Yuksel-Rudy merged commit 9ad867f into dev Oct 9, 2025
0 of 12 checks passed
@Yuksel-Rudy Yuksel-Rudy deleted the lineDepth_coloring branch October 9, 2025 17:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants