Open jdenholm opened 1 year ago
Yes, it would be great to removepyqg
dependency so that users can feed in their data without having to installpyqg
which is a numerical solver.
My take on this is that we should support pyqg
and require it for certain things (e.g. computing similarity metrics that are specifically designed for pyqg.Model
s), but we shouldn't require it for the entire library, since much of the code (e.g. the actual hybrid symbolic procedure) can operate just as easily on an xarray.Dataset
.
To accomplish that, I think we'll need to do something like:
import
ing pyqg
and store a boolean indicating whether the import succeededpyqg.Model
with something like is_pyqg_model
that returns isinstance(pyqg.Model)
if the import succeeded and False
if the import failedDoes that make sense? I think that's a better approach than removing all references to pyqg
altogether, since then it will become very difficult to run the library with pyqg models.
Thanks @asross; i like the idea. I feel as long as one can use the hybrid symbolic procedure without pyqg
that would be really great (including calculating the derivatives).
The
utils.py
currently depends on thepyqg
repository, but Laure says she would like this equation discovery repository to be completely independent ofpyqg
.pyqg
dependency definitely what we want to achieve?pyqg
dependency?