Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • bliss bliss
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 539
    • Issues 539
    • List
    • Boards
    • Service Desk
    • Milestones
  • Jira
    • Jira
  • Merge requests 148
    • Merge requests 148
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • BlissBliss
  • blissbliss
  • Merge requests
  • !3780

Flint: Clean up around custom plots

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Valentin Valls requested to merge valentin.valls/bliss:clean-up-around-custom-plots into master Jun 09, 2021
  • Overview 2
  • Commits 29
  • Pipelines 4
  • Changes 21

Closes #2051 (closed), #2143 (closed)

This MR clean up stuffs around the custom plot API.

The aim is to make the API a bit more consistent, maintainable, and make sure we will not have further regressions.

As a lot of small things were changed, this could introduce small regressions here and there.

  • Update of the user documentation
  • Coverage of the user plots including deprecated methods
  • Added a new API for the curve plot (see bellow)
  • Small tune of the widget used to hold the plots
  • Lot of small fixes around the user API

The new curve plot API:

# Create the data
t = numpy.linspace(0, 10 * numpy.pi, 100)
s1 = numpy.sin(t)
s2 = numpy.sin(t + numpy.pi * 0.5)
s3 = numpy.sin(t + numpy.pi * 1.0)
s4 = numpy.sin(t + numpy.pi * 1.5)

# -----------------------

# Create the plot
f = flint()
p = f.get_plot("curve", name="My plot", unique_name="myplot")

# Describe the plot
p.add_curve_item("t", "s1", color="pink")
p.add_curve_item("t", "s2", color="green")
p.add_curve_item("t", "s3", color="blue")
p.add_curve_item("t", "s4")

...

# Transfer the data, which update the plot
p.set_data(t=t, s1=s1, s2=s2, s3=s3, s4=s4)
Edited Jun 14, 2021 by Valentin Valls
Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: clean-up-around-custom-plots