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

Add functionality to read .nc files back into rsgpr #11

Open
erikmannerfelt opened this issue Jun 6, 2023 · 0 comments
Open

Add functionality to read .nc files back into rsgpr #11

erikmannerfelt opened this issue Jun 6, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@erikmannerfelt
Copy link
Owner

When trying to read an .nc file (the output of a previous rsgpr run), an ugly panic occurs. Following #7, this should not result in a panic but instead a helpful error message. Also, reading an rsgpr output as an input is good for a few reasons:

  • Read the information and processing log of an output. The easiest way right now is to use xarray in python, which involves a few lines. It would be much nicer to have this built in to rsgpr.
  • Run more steps on a processed file. For example, this may be useful if the user wants to store intermediate files. Then, one can run rsgpr -f ... --steps "step1" -o step1.nc followed by rsgpr -f step1.nc --steps "step2" -o step2.nc"

For reference, here is what trying to retrieve the information about an output looks like now:

❯ rsgpr -f DAT_0122_A1.nc -i  
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: "File found but no '.rad' file found: \"DAT_0122_A1.rad\""', src/cli.rs:190:6
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant