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

ROM workflow for restart file collection and POD basis training #230

Merged
merged 4 commits into from
May 3, 2024

Conversation

dreamer2368
Copy link
Collaborator

@dreamer2368 dreamer2368 commented May 1, 2024

This PR must be rebased after PR #229 is merged to ROMFPMD.

src/rom_main.cc is re-written, copying from the main driver src/main.cc. This will be compiled into an executable mgmol-rom. This ROM driver will handle the entire workflow of ROM. Currently, only the restart file collection + POD training is implemented.

  • The ROM workflow routines will be implemented in src/rom_workflows.h and src/rom_workflows.cc.
    • The restart file collection + POD training is implemented as readRestartFiles.
    • This does not require saving libROM snapshot file at offline FOM simulation. The standard mgmol restart files can be used for POD basis generation.

Usage:

  • The restart file directories should be renamed following a certain string format that takes an integer. This string format should be specified in ROM.offline.restart_filefmt.
  • mgmol-rom will read the restart files starting from an index specified in the input ROM.offline.restart_min_idx, to another index specified in the input ROM.offline.restart_max_idx.

For example, examples/Carbyne/carbyne.rom.cfg specifies:

[ROM.offline]
restart_filefmt=snapshot0_%03d
restart_min_idx=0
restart_max_idx=1
basis_file=carom

Reading this input file, mgmol-rom will search for directories snapshot0_000 and snapshot0_001. The resulting POD basis will be stored in a directory carom.

Minor change

Docker container now has hdf5-tools installed.

@dreamer2368 dreamer2368 marked this pull request as ready for review May 2, 2024 23:50
src/rom_main.cc Show resolved Hide resolved
src/rom_workflows.h Outdated Show resolved Hide resolved
src/rom_main.cc Show resolved Hide resolved
src/rom_main.cc Outdated Show resolved Hide resolved
@jeanlucf22 jeanlucf22 merged commit 4d9f5f3 into ROMFPMD May 3, 2024
2 checks passed
@jeanlucf22 jeanlucf22 deleted the new-rombasis3 branch May 3, 2024 17:28
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.

3 participants