-
Notifications
You must be signed in to change notification settings - Fork 4
Adds orsopy integration for .ort
files and ORSO models
#131
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
Conversation
.ort
file reader.ort
files and ORSO models
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good so far, I've a few questions and things to think about.
In addition to the specific comments, I'm wondering about projects with the "substrate/liquid" geometry, and how they would work with this setup?
@DrPaulSharp to address your comment about substrate/liquid: the only thing |
Ok, that makes sense. My concern though is that in |
@DrPaulSharp decided to not bother creating the whole project, which makes most of the review points fixed by being no longer relevant. see the notebook for a good idea of what I suggest as a better way of doing things (as discussed in the meeting). One problem I'm noticing is that the data in the notebook example isn't fit very well - this isn't a good look, but it is also weird data. not sure if you can suggest anything there? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is looking really good and I think is the right approach to taking in this data.
As discussed, let's raise the data fit in the next project meeting and work out where to go from there.
I've one more thing I'd like you to do, could you write __str__
method for the ORSOProject and ORSOSample classes to print them out in tables like a cut down Project
. How do you think we should present the model in these classes?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alongside my question, could you please add orso to the list of utils made available in RATapi/__init__.py
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We made it! Thanks for your hard work on this one, and particularly for keeping pushing to make this piece of code as strong and useful as possible.
This PR adds functionality to read
.ort
data and models. Fixes #104The interface is through one function and one class:
RATapi.utils.orso.orso_model_to_rat
, which turns an ORSO model description (given as either an orsopySampleModel
or a string) into an ORSOSample dataclass, which gives bulk in and bulk out data as well as a list of layers in the model and the parameters required to define them.RATapi.utils.orso.ORSOProject
, which contains all data from an .ort file. This can then be put into a project as required.