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

fix: LinearView and SideView plot to display operation name #2592

Merged
merged 6 commits into from
Jan 13, 2025

Conversation

TheMightyRaider
Copy link
Contributor

Purpose of PR?:
To show operation name in the sideview and linearview plot area.

Fixes #2461

Does this PR introduce a breaking change?

If the changes in this PR are manually verified, list down the scenarios covered::

  • Tested using the dummy data, which was created as mentioned in the docs.

Additional information for reviewer? :
Mention if this PR is part of any design or a continuation of previous PRs

  • There is design change in the graphs, The sideview and linearview plot graphs would contain operation name at the top-centre of the plot as shown in the images below,
Screenshot 2024-12-22 at 11 28 35 PM Screenshot 2024-12-22 at 11 39 19 PM

Does this PR results in some Documentation changes?
If yes, include the list of Documentation changes

  • The tutorial video might need to be reuploaded

Checklist:

@TheMightyRaider TheMightyRaider changed the base branch from stable to develop December 22, 2024 18:31
@ReimarBauer
Copy link
Member

ReimarBauer commented Dec 27, 2024

Hi @TheMightyRaider this is partly done. it is a good step. We can have opened views while we can change the flight or operation.
You can try with a test database setup of mscolab or create a second Flight track.

MSS$ python mslib/mscolab/mscolab.py db --seed
MSS$ python mslib/mscolab/mscolab.py start

look into the seed module for credetentials

When we change the model we need also to update this entry on the plot. This is missing yet in the solution.

changeactivemodel

Have a look into viewwindows.setFlightTrackModel how it is done for the window title

@ReimarBauer
Copy link
Member

ReimarBauer commented Dec 27, 2024

When showing some of the data from a demo server, the position of the name is overlapped by the other text

image

Maybe place it right of the plot.

@TheMightyRaider
Copy link
Contributor Author

Thank you @ReimarBauer for your feedback, Will fix the issues mentioned!

@TheMightyRaider
Copy link
Contributor Author

@ReimarBauer , Pushed a commit with the review changes you had mentioned! Let me know if it looks good on your end!

Copy link
Member

@ReimarBauer ReimarBauer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't see the information on a linearview

image

on topview please remove the old one (model name) on the left lower corner. There we have it now twice.

image

@TheMightyRaider
Copy link
Contributor Author

Sorry about that @ReimarBauer , Thanks for your feedback once again.

  • I have pushed a fix for the "repetition of title in topView" issue.
  • Regarding "The title not been shown in the LinearView" issue, It does show in my end. Can you guide how to reproduce your graph?
screen-recording-2024-12-30-at-92354-pm_ZbXrvfJf.mp4

@ReimarBauer
Copy link
Member

ReimarBauer commented Dec 30, 2024

On the place where EPSG was printed there where also optional airdata credentionals on topview shown. The place was for EPSG and that good. Or how does this look now when you select that in the docking widget?

(Select to open control)

@ReimarBauer
Copy link
Member

ReimarBauer commented Dec 30, 2024

On the place where EPSG was printed there where also optional airdata credentionals on topview shown. The place was for EPSG and that was quite good. Or how does this look now when you select that in the docking widget?

For comparing with underlaying data.

Click Server/Layer and add a Server url. E.g. http://open-mss.org (not https)

Then select a layer. The model name should be on the plot too.

@TheMightyRaider
Copy link
Contributor Author

@ReimarBauer When the size of the window is small, The text gets crowded.
Screenshot 2024-12-30 at 11 12 58 PM
Screenshot 2024-12-30 at 11 13 04 PM

@ReimarBauer
Copy link
Member

@ReimarBauer When the size of the window is small, The text gets crowded.
Screenshot 2024-12-30 at 11 12 58 PM
Screenshot 2024-12-30 at 11 13 04 PM

The name is mostly needed on a saved plot / printed plot.

On screen having it at the window title is ok.

@TheMightyRaider
Copy link
Contributor Author

TheMightyRaider commented Dec 30, 2024

I tried putting the title in the bottom left. But now it overlap with the x-axis values during sideview plot.
I feel the plot isn't scaling well when the screen of the window is shrieked, Even the values of the y-axis for the sideview plot are semi hidden by default. @ReimarBauer

@ReimarBauer
Copy link
Member

I think we should keep on topview the location where we have EPSG for everything besides the model.name

With airdata there can be more text added there and we don't have this and EPSG for the other views

without your change:

image

@ReimarBauer
Copy link
Member

On the linearview with data the model.name is gone

selection_update

@ReimarBauer
Copy link
Member

ideas are welcome to improve matplotlib/qt visualizations.

@TheMightyRaider
Copy link
Contributor Author

I think we should keep on topview the location where we have EPSG for everything besides the model.name

With airdata there can be more text added there and we don't have this and EPSG for the other views

without your change:

image

@ReimarBauer, I'm not sure whether I got right. Do you mean to say, we keep the model name alone at the top right for all the three views [ side, top and linear ] ?

@ReimarBauer
Copy link
Member

@TheMightyRaider yes we should have same place for the model name on all three views. Currently at the top right is the best option. The special information EPSG, etc on TopView should be kept on its origin place.

@TheMightyRaider
Copy link
Contributor Author

@ReimarBauer, Pushed the changes!

@ReimarBauer
Copy link
Member

On github is a rule for the CI it did not start for new contributors automatically. I cannot change that.
But you can look locally too.

The tests can ran locally, e.g. https://github.com/Open-MSS/MSS/blob/develop/.github/workflows/testing.yml#L68, https://github.com/Open-MSS/MSS/blob/develop/.github/workflows/lint.yml#L69

@ReimarBauer
Copy link
Member

@TheMightyRaider look on the flake8 linter, meanwhile I play with the changes

@TheMightyRaider
Copy link
Contributor Author

@ReimarBauer , Fixed the linting issues thrown by flake8.

Copy link
Member

@ReimarBauer ReimarBauer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok, fine

there needs a last refactoring change done. When I look with PyCharm (I guess other have also such options) I see the name parameter is not used anymore and we should change the API and content of update_info_text too.

image

@ReimarBauer
Copy link
Member

@TheMightyRaider have you seen the opportunity to refactor the sigature of update_info_text ?

@TheMightyRaider
Copy link
Contributor Author

@ReimarBauer , Nice find! I have updated the update_info_text function. Sorry about the delay.

Quoting below your earlier comment,

ok, fine

there needs a last refactoring change done. When I look with PyCharm (I guess other have also such options) I see the name parameter is not used anymore and we should change the API and content of update_info_text too.

I don't understand what you meant by API here?

@ReimarBauer
Copy link
Member

ReimarBauer commented Jan 10, 2025

I don't understand what you meant by API here?

We have not defined a public Application Programming Interface. That means any signature change is also an API change.
In that case the function has now less parameters than before.

@TheMightyRaider
Copy link
Contributor Author

Ahh okay! Thanks for the clarification!

@TheMightyRaider
Copy link
Contributor Author

TheMightyRaider commented Jan 10, 2025

https://github.com/Open-MSS/MSS/blob/develop/.github/workflows/testing-all-oses.yml, This workflow is failing if I'm not wrong. 😢

@ReimarBauer
Copy link
Member

If it is because of timeout or mac tests that is not related to your changes.

Copy link
Member

@ReimarBauer ReimarBauer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thx, for solving this

@ReimarBauer ReimarBauer merged commit 22145d9 into Open-MSS:develop Jan 13, 2025
9 of 11 checks passed
@TheMightyRaider
Copy link
Contributor Author

Thank you for your guidance! @ReimarBauer

@TheMightyRaider TheMightyRaider deleted the ui_enhancement branch January 13, 2025 10:13
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.

add operation or flightrack name on sideview and linearview plot area
2 participants