Closed carstenbauer closed 2 years ago
lib.gz
is just a collection of basis set files (e.g. sto-3g.gbs
) compressed. It comes from Basis Set Exchange (BSE). The original idea was to look up and download basis as needed, or just try to download basis if they are not saved locally. But, as you can see, that never happened.
I think it is important to easily allow the introduction of new basis set files.
The file parsing right now is a little "brute force", so it could be nice to have something like
basis["sto-3g", "O"]
But I don't think it is crucial.
What is the issue you see with the compressed file? The need for unpacking (and therefore a specific package for it)?
What is the issue you see with the compressed file? The need for unpacking (and therefore a specific package for it)?
Yes, mostly the unpacking part. Generally, Julia packages should be "immutable snapshots". The legacy deps/build.jl
approach almost inevitably undermines this idea since it mutates the package directory. Here, it downloads libcint
, compiles it, and unpacks lib.gz
.
But apart from this "conceptual" point of view, the deps/build.jl
solution also has very practical disadvantages:
Project.toml
) external dependencies since the user needs to have cmake
and BLAS etc. available and - for the lib.gz
part - needs to have tar
on the system (although you could probably work around this by using Tar.jl). libcint_jll
solves this nicely for the libcint
dependency: no need for cmake, BLAS will be automatically shipped if necessary, and everything is explicit since libcint_jll
is listed in the Project.toml
. (We also get versioning.)deps/build.jl
all packages that need libcint
would implement there own procedure for compiling libcint
(fortunately it's simple in this case but it might be a pain in the ass) and also install separate identical versions of the library. The artifact solution makes the same installed libcint
available to all Julia packages and the compilation strategy only has to be figured out once with BinaryBuilder.jl (and will be stored in Yggdrasil). The lib.gz
part is obviously simpler here and might not be reused as much which is why there are multiple possible routes (see my OP).libcint
compilation and the unpacking of lib.gz
happens whenever one installs the package or explicitly triggers ] build Fermi
. Just downloading the artifact (if it isn't already available) is generally much faster.Thank you. For now I will ship the gbs
files inside a folder to bypass the extraction and libcint_jl
will be use as default. I have merged your PR.
As I said here https://github.com/FermiQC/Fermi.jl/issues/111#issuecomment-1006847621. We plan to use GaussianBasis.jl
as the "integral library" and Fermi will deal with methods only/mostly. So I will copy the modifications made here into that package.
libcint: replace the custom cmake build step with libcint_jll (see #111, solved by PR #112)
deps/lib.gz
: this seems to be a data dependency so a few things come to mind:lib.gz
)lib.gz
without unpacking it (similar to what Pkg.jl is doing with the general registry information)?)@gustavojra where does the
lib.gz
come from? Do you compile it manually? Or do you download it from an external URL?