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

Replace broken verification cases and rewire the verification (avoid leftovers, both from actions and locally) #86

Open
emanuelegissi opened this issue Aug 18, 2023 · 4 comments

Comments

@emanuelegissi
Copy link
Member

Someone "burned" the local landuse layer.
It took me hours to understand that the fire_layer algorithm was working correctly, but the landuse was tainted.
Please @jonathan, do not touch them. I am going to replace the broken files with good ones.

@johodges
Copy link
Collaborator

good catch, not sure when that occurred. Let me know once you have added the updated file layers and I can update the figures repo with the passing cases.

@emanuelegissi
Copy link
Member Author

Hi Jonathan, I uploaded an attempt at the new golden_gate_local test.
The goal is being as similar as possible to the official FDS wildfire cases.

Here are the main mods, in no particular order:

  1. I dropped test_ from the directory name
  2. Inside the folder, you find 3 directories: QGIS, FDS and scripts:
    1. In QGIS you find the sheets, layers folders and the qgs file.
    2. In FDS you find only the case and nothing else except a .gitignore. This folder should always be cleaned in advance by the script when a test is performed, to prevent artifacts.
    3. In scripts there are several test scripts. The scripts should be self-sufficient: they clean the FDS folder, run QGIS, run FDS, call the image comparison script, and report back to the calling run.sh.

Regarding the overall structure of the verification folder, the goal is avoiding any incidental pollution of the structure when the verification is run:

  1. run.sh should be the main entry point to the verification suite. This script should enter into the test folder hierarchy, browse the directories, run all the script in the scripts subfolders, collect the test results, write a logfile (eg. 20230821-0920.log) and the error images in a folder (named eg. 20230821-0920) in the logs folder. The script run.sh should know nothing about the tests: just run the scripts and collect the results. Modularity is future-proof.
  2. The general scripts are moved to the scripts folder. I prefer to have them in python that in bash, for preventing future headaches.
  3. The tests coming from the fds cases (eg. chimney_tops) should not be copied from the cad repo, but called. This to prevent divergences.
  4. All temporary files should be created in the /tmp directory, to prevent leftovers in case of errors.

Speaking about git actions, the exact same run.sh should be run. The goal is avoiding maintaining two different testing facilities.

And I still think that a separate repo for the verification cases is better, if possible.

Before starting any work on this, I suggest reaching a consensus, so that we head in the same direction.
In the meantime, I keep cleaning qgis2fds code, and testing it by hand.

Let me know what you think on this.

@emanuelegissi
Copy link
Member Author

Forgot to add:

  1. I intend to move to python all the scripts, included the test scripts. But one thing at a time ;-)
  2. See the test scripts, they inject the $CHID.ini and $CHID.ssf files too. The goal is fully separating the test from the FDS folder.

@emanuelegissi emanuelegissi changed the title Golden gate local and remote test cases files are broken and need to be replaced Replace broken verification cases and rewire the verification (avoid leftovers, both from actions and locally) Aug 21, 2023
@johodges
Copy link
Collaborator

Some progress on this made in #89. Implemented changes:

  • Same entry point is used for local verification and the github actions workflow (verification/run.sh).
  • The firemodels/cad repo has been configured as a submodule, and an example test configured for the chimney_tops_2 case in verification/tests/
  • A log file is generated in verification/logs during run. Currently called log.txt rather than named by date.

There is still an open issue on this:

  • The obst cases run locally but hang on the github actions. These are currently disabled so the action will not fail on this.

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

No branches or pull requests

2 participants