Skip to content

Commit

Permalink
improve plot comparison
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaelrojasmiliani committed Aug 27, 2024
1 parent 3e6e23b commit 2623cc0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions python/gsplines/plot/plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,10 @@ def plot_compare(_q: List, _colors: List = [], _legends: List = [],
_up_to_deriv=3,
_dt=0.1, _wp=None, _title='', _show=True):

if not _colors:
cmap = plt.get_cmap('viridis')
_colors = [cmap(val) for val in np.linspace(0, 1, len(_q))]

fig, axis = plt.subplots(_up_to_deriv + 1, _q[0].get_codom_dim())

for curve, color in zip(_q, _colors):
Expand Down

0 comments on commit 2623cc0

Please sign in to comment.