8000 Support offset pitch for `Safe mode` and `NSM` events and improve `Safe mode` by taldcroft · Pull Request #334 · sot/kadi · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Support offset pitch for Safe mode and NSM events and improve Safe mode #334

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

Merged
merged 12 commits into from
Oct 29, 2024

Conversation

taldcroft
Copy link
Member
@taldcroft taldcroft commented Aug 9, 2024

Description

  • Add support for a pitch parameter in the NSM and Safe mode events.
  • Improve the fidelity of the Safe mode event.
    • Previously the command set for safe mode started with two safe mode commands and then included all commands for a NSM transition, including the AONSMSAF command (in order to tell states to do the pitch maneuver).
    • Now kadi states understands natively the safe mode command ACPCSFSU and initiates a maneuver accordingly.

Unrelated changes

  • Fix documentation so that making a configuration file works.
  • Sort parameters in pprint_like_backstop() so that comparing two backstops has minimal diffs.

Interface impacts

Testing

Unit tests

There is a unit test for this functionality in #340. It was just easier to roll it into that PR.

  • Mac
(ska3) ➜  kadi git:(matlab-support-nsm-ssm-offsets) git rev-parse HEAD
587015c61df212f2073c8d5e827181265b99f447
(ska3) ➜  kadi git:(matlab-support-nsm-ssm-offsets) pytest
============================================ test session starts ============================================
platform darwin -- Python 3.11.8, pytest-7.4.4, pluggy-1.4.0
rootdir: /Users/aldcroft/git
configfile: pytest.ini
plugins: timeout-2.2.0, anyio-4.3.0
collected 181 items                                                                                         

kadi/commands/tests/test_commands.py ................................................................ [ 35%]
.................                                                                                     [ 44%]
kadi/commands/tests/test_states.py .......................x.........................                  [ 71%]
kadi/commands/tests/test_validate.py ...................                                              [ 82%]
kadi/tests/test_events.py ..........                                                                  [ 87%]
kadi/tests/test_occweb.py ......................                                                      [100%]

================================ 180 passed, 1 xfailed in 113.45s (0:01:53) =================================

Independent check of unit tests by Jean

  • Linux
(ska3-masters) jeanconn-fido> pytest
========================================================= test session starts =========================================================
platform linux -- Python 3.11.8, pytest-7.4.4, pluggy-1.4.0
rootdir: /proj/sot/ska/jeanproj/git
configfile: pytest.ini
plugins: timeout-2.2.0, anyio-4.3.0
collected 181 items                                                                                                                   

kadi/commands/tests/test_commands.py .................................................................................          [ 44%]
kadi/commands/tests/test_states.py .......................x..............
8000
...........                                            [ 71%]
kadi/commands/tests/test_validate.py ...................                                                                        [ 82%]
kadi/tests/test_events.py ..........                                                                                            [ 87%]
kadi/tests/test_occweb.py ......................                                                                                [100%]

============================================= 180 passed, 1 xfailed in 218.51s (0:03:38) ==============================================
(ska3-masters) jeanconn-fido> git rev-parse HEAD
587015c61df212f2073c8d5e827181265b99f447

Functional tests

Functional testing is available in the included validation Jupyter notebook. That code is mostly superseded by the unit test in #340, however it is worth having since it shows a bit more detail.

I also confirmed that the validation plots look as expected. This is not a surprise since they just reflect the states.

@taldcroft taldcroft force-pushed the matlab-support-nsm-ssm-offsets branch from f71512f to 101ab24 Compare October 16, 2024 20:10
@taldcroft taldcroft changed the title WIP: Support offset pitch for Safe mode and NSM events Support offset pitch for Safe mode and NSM events Oct 16, 2024
@jeanconn
Copy link
Contributor
jeanconn commented Oct 16, 2024

For me this isn't passing unit tests on linux or mac with a recent ska3-flight-latest.

@taldcroft
Copy link
Member Author

@jeanconn - seems this change is pretty impacting. Most tests are passing now but there are still issues with the validation regression. I need to step away to a different task now so this needs to wait for the moment.

@jeanconn
Copy link
Contributor

For validation, I note that I couldn't get tests passing when gave a 3 minute shot a regenerating validation regress data in #338 . I bring that up in that, heck, we might want to add that in as another change in this PR to only update the regress data once...

@taldcroft
Copy link
Member Author

Some validate regression tests are mostly failing, but with occasionally successes. Digging required...

@taldcroft taldcroft force-pushed the matlab-support-nsm-ssm-offsets branch from 5249ed7 to 587015c Compare October 26, 2024 09:51
@taldcroft taldcroft changed the base branch from master to better-validation-regression-data October 26, 2024 10:05
@taldcroft taldcroft requested a review from jeanconn October 28, 2024 12:45
Comment on lines +75 to +76
- 0.0
- 0.0
Copy link
Member Author

Choose a reason for hiding this comment

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

This is pcad_mode=STBY, aka Safe Mode

@taldcroft taldcroft requested a review from javierggt October 28, 2024 12:48
Base automatically changed from better-validation-regression-data to master October 29, 2024 12:51
@taldcroft taldcroft changed the title Support offset pitch for Safe mode and NSM events Support offset pitch for Safe mode and NSM events and improve Safe mode Oct 29, 2024
@taldcroft taldcroft merged commit c2ab36c into master Oct 29, 2024
4 checks passed
@taldcroft taldcroft deleted the matlab-support-nsm-ssm-offsets branch October 29, 2024 16:44
@javierggt javierggt mentioned this pull request Nov 7, 2024
@javierggt javierggt mentioned this pull request Jan 23, 2025
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
0