Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Trajectory results report plots now plot vector variables, respect the x_name argument, and avoid noisy plots when values are nearly constant. #1135

Merged
merged 11 commits into from
Dec 11, 2024

Conversation

robfalck
Copy link
Contributor

@robfalck robfalck commented Dec 4, 2024

Summary

The bokeh traj results report created by run_problem was not respecting plot_kwargs. This is now fixed, allowing users to specify the name of the time-like variable when phases rename the time-like variable.

Vectorized states, controls, and parameters were previously not being plotted correctly in the traj results report.

For example, in the brachistochrone vector states test, pos is a 2-vector holding both x and y states.
Previously, these weren't plotted correctly because Bokeh's ColumnDataSource seems to prefer a single column of data for each variable name.

Screenshot 2024-12-04 at 1 12 33 PM

Now the report will include a new figure for each element in the vector, with the axis labeled correctly.

Screenshot 2024-12-04 at 1 15 48 PM

Finally, in some cases, machine precision variation in otherwise-constant data would show up as noisy.
The y-range of the plots has now had its min_interval set to 1.0E-12 so that. machine-precision variation, typically on the order of 1E-16, appears constant.

Related Issues

Backwards incompatibilities

None

New Dependencies

None

@coveralls
Copy link

Coverage Status

coverage: 93.605% (-0.2%) from 93.802%
when pulling 3f6e85b on robfalck:timeseries_fixes
into d324563 on OpenMDAO:master.

@robfalck robfalck merged commit efb22b7 into OpenMDAO:master Dec 11, 2024
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants