diff --git a/.gitignore b/.gitignore index 4b854c1..a16229e 100644 --- a/.gitignore +++ b/.gitignore @@ -32,6 +32,11 @@ BASE_TEMPLATE.HTML /config/old_config/logs/* /logs/* +# IDE settings : +# - VS: +.vscode/* +# - Eclipse: +.pydevproject #.idea .idea/workspace.xml /.idea/workspace.xml diff --git a/src/core/pyros_django/routine_manager/doc/ObservationSequence_SO_state_diag_with_images.pu b/src/core/pyros_django/routine_manager/doc/ObservationSequence_SO_state_diag_with_images.pu new file mode 100644 index 0000000..3f75237 --- /dev/null +++ b/src/core/pyros_django/routine_manager/doc/ObservationSequence_SO_state_diag_with_images.pu @@ -0,0 +1,175 @@ + +@startuml + +' --- STATE DIAGRAM --- +' (see http://plantuml.com/fr/state-diagram) + +title +__**Observation Sequence (SO) - State Diagram**__ +Version 9-2-2022 (E. Pallier) + +end title + + + + +/' +---------------------------------------- +--- (1) SF05-SEQ - Sequence Creation --- +---------------------------------------- +'/ + +state SF05_SEQ as "SF05-SEQ - Observation Sequence Creation" #cyan +state DRAFT_WEB as "INCOMPLETE (DRAFT)": not yet validated +state TBP as "TOBEPLANNED (TBP)": waiting for planning +state is_valid <> +state End_SF05 <> + +[*] --> SF05_SEQ + +SF05_SEQ --> is_valid: **created (from import)** +is_valid --> End_SF05: **[invalid]** +is_valid --> TBP: **[valid]** + +SF05_SEQ --> DRAFT_WEB: **created (from web form)** +DRAFT_WEB --> DRAFT_WEB: **modify** +DRAFT_WEB --> TBP: **SUBMIT, and valid** + +TBP --> SF07_PLN + + +/' +---------------------------------------- +--- (2) SF07-PLN - Sequence Planning --- +---------------------------------------- +'/ + +state SF07_PLN as "SF07-PLN - Observation Sequence Planning" #cyan +state PLND as "PLANNED (PLND)": planned for current/coming night +state UNPL as "UNPLANNABLE (UNPL)": unplannable for current/coming night +state End_SF07 <> + +SF07_PLN --> UNPL +UNPL --> End_SF07 +SF07_PLN --> PLND: **PLAN/SCHEDULE** + +PLND --> SF08_EXE + + +/' +---------------------------------------- +--- (3) SF08-EXE - Sequence Execution --- +---------------------------------------- +'/ + +state SF08_EXE as "SF08-EXE - Observation Sequence Execution" #cyan + +state E_RUN as "REC_RUNNING (R_RUN)": Sequence exec running... +state E_RUN : \nforeach image finished:\n change state to "R_END (L0)" + +state E_CCLD as "REC_STOPPED (R_CCLD)": Sequence exec cancelled +state E_END as "REC_FINISHED (R_END)": Sequence exec finished +state can_exec <> +'state fork_state <> +'state join_state <> + +/' +note right of E_RUN + foreach image finished: + change state to "R_END (L0)" +end note +'/ + +SF08_EXE -d-> can_exec +can_exec --> E_RUN: [can be executed]\n **EXEC** +can_exec --> TBP: [can't be executed] \n (too late or \n observing conditions \n not good enough) + +E_RUN --> E_CCLD: **exec cancelled** +E_CCLD --> TBP: **go back to planning**\n (don't keep incomplete Sequence) +E_RUN --> E_END: **exec finished** + +E_END --> SF11_IPC + + +/' +---------------------------------------- +--- (4) SF11-IPC - Sequence images processing --- +---------------------------------------- +'/ + +state SF11_IPC as "SF11-IPC - Sequence Images ProCessing" #cyan + +state P_RUN as "PROC_RUNNING (P_RUN)": Sequence process running... +state P_RUN : \nforeach image: +state P_RUN : \t - change state to "P_RUN" (L1) +state P_RUN : \t - if cancelled: change state to "P_CCLD" +state P_RUN : \t - if finished: change state to "P_END" +state P_RUN : \n (same algo for SF12 and SF13) + +state P_STOP as "PROC_STOPPED (P_STOP)": Sequence process stopped +state P_END as "PROC_FINISHED (P_END)": Sequence process finished + +/' +note right of P_RUN + foreach image: + - change state to "P_RUN" + - if cancelled: change state to "P_CCLD" + - when finished: change state to "P_END" + + (same algo for SF12 and SF13) +end note +'/ + +SF11_IPC --> P_RUN: **PROCESS** + +P_RUN --> P_STOP: **process stopped** +P_STOP --> E_END +P_RUN --> P_END: **process finished** + +P_END --> SF12_IAN + + +/' +---------------------------------------- +--- (5) SF12-IAN - Sequence images analysis --- +---------------------------------------- +'/ + +state SF12_IAN as "SF12-IAN - Sequence Images ANalysis" #cyan + +state A_RUN as "ANL_RUNNING (A_RUN)": Sequence analysis running... +state A_RUN : (same algo as SF11) + +state A_STOP as "ANL_STOPPED (A_STOP)": Sequence analysis temporarily stopped +state A_END as "ANL_FINISHED (A_END)": Sequence analysis finished + +SF12_IAN --> A_RUN: **ANALYSE** +A_RUN --> A_STOP: **process stopped** +A_STOP --> P_END +A_RUN --> A_END: **analysis finished** + +A_END --> SF13_IAF + + +/' +---------------------------------------- +--- (6) SF13-IAF - Sequence images archiving/fetching (zipping) --- +---------------------------------------- +'/ + +state SF13_IAF as "SF13-IAF - Sequence Images Archiving & Fetching" #cyan + +state Z_RUN as "ZIP_RUNNING (Z_RUN)": Sequence archiving running... +state Z_RUN : (same algo as SF11) + +state Z_STOP as "ZIP_STOPPED (Z_STOP)": Sequence archiving temporarily stopped +state Z_END as "ZIP_FINISHED (Z_END)": Sequence archiving finished + +SF13_IAF --> Z_RUN: **ARCHIVE** +Z_RUN --> Z_STOP: **archiving stopped** +Z_STOP --> A_END +Z_RUN --> Z_END: **archiving finished** +Z_END --> [*] + + +@enduml -- libgit2 0.21.2