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

Show_tree output is not printed for old ext files #581

Closed
priscavdsluis opened this issue Nov 7, 2023 · 0 comments · Fixed by #592
Closed

Show_tree output is not printed for old ext files #581

priscavdsluis opened this issue Nov 7, 2023 · 0 comments · Fixed by #592

Comments

@priscavdsluis
Copy link
Contributor

Describe the bug
For the new ext file, the files reference in here are printed out with the show_tree function.

To Reproduce (example)

# initialize mdu file and update settings
mdu_file = os.path.join(dir_output, f'{model_name}.mdu')
mdu = hcdfm.FMModel()

# add the external forcing files (.ext)
mdu.external_forcing.extforcefile = ext_file_old
mdu.external_forcing.extforcefilenew = ext_new

# visualize the model tree
mdu.show_tree()

output:

  c:\DATA\dfm_tools\docs\notebooks\Vietnam_model\Vietnam.mdu
    Geometry
     ∟ c:\DATA\dfm_tools\docs\notebooks\Vietnam_model\Vietnam_net.nc
    ExternalForcing
     ∟ c:\DATA\dfm_tools\docs\notebooks\Vietnam_model\Vietnam_old.ext
     ∟ c:\DATA\dfm_tools\docs\notebooks\Vietnam_model\Vietnam_new.ext
       ∟ Boundary
         ∟ c:\DATA\dfm_tools\docs\notebooks\Vietnam_model\Vietnam.pli
         ∟ c:\DATA\dfm_tools\docs\notebooks\Vietnam_model\tide_Vietnam_tpxo80_opendap.bc
       ∟ Boundary
         ∟ c:\DATA\dfm_tools\docs\notebooks\Vietnam_model\Vietnam.pli
         ∟ c:\DATA\dfm_tools\docs\notebooks\Vietnam_model\waterlevelbnd_Vietnam_CMEMS.bc
       ∟ Boundary
         ∟ c:\DATA\dfm_tools\docs\notebooks\Vietnam_model\Vietnam.pli
         ∟ c:\DATA\dfm_tools\docs\notebooks\Vietnam_model\salinitybnd_Vietnam_CMEMS.bc
       ∟ Boundary
         ∟ c:\DATA\dfm_tools\docs\notebooks\Vietnam_model\Vietnam.pli
         ∟ c:\DATA\dfm_tools\docs\notebooks\Vietnam_model\temperaturebnd_Vietnam_CMEMS.bc
       ∟ Boundary
         ∟ c:\DATA\dfm_tools\docs\notebooks\Vietnam_model\Vietnam.pli
         ∟ c:\DATA\dfm_tools\docs\notebooks\Vietnam_model\uxuyadvectionvelocitybnd_Vietnam_CMEMS.bc
    Output
     ∟ c:\DATA\dfm_tools\docs\notebooks\Vietnam_model\Vietnam_obs.xyn

Expected behavior
The file paths referenced in the old external forcing file are also listed in the output.

Version info (please complete the following information):

  • Version 0.5.2

Additional context
Probably the is_intermediate_link needs to set to true for forcing objects in the old ext file.

@veenstrajelmer veenstrajelmer changed the title Show_tree ouput is not printen for old ext files Show_tree ouput is not printed for old ext files Jan 12, 2024
@veenstrajelmer veenstrajelmer linked a pull request Jan 12, 2024 that will close this issue
@veenstrajelmer veenstrajelmer changed the title Show_tree ouput is not printed for old ext files Show_tree output is not printed for old ext files Jan 12, 2024
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 a pull request may close this issue.

1 participant