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

Improve the speed for loading the GMT.jl package #9

Open
seisman opened this issue Sep 29, 2020 · 3 comments
Open

Improve the speed for loading the GMT.jl package #9

seisman opened this issue Sep 29, 2020 · 3 comments
Labels
help wanted Extra attention is needed

Comments

@seisman
Copy link
Member

seisman commented Sep 29, 2020

Loading the GMT.jl package (using GMT) is very slow (~10 s) for the first time, because Julia needs to precompile the GMT.jl package. It would be better to precompile the package when building the docker image, so that the package is already precompiled when users run using GMT.

As I understand it, running julia -e "using GMT" may do the precompiling.

@joa-quim Is it correct? Is there a way to precompile all Julia packages?

@joa-quim
Copy link
Member

That is the subject of one of biggest discussions in Julia (on how to improve compile times). When one run it locally it takes that time only the first time and caches the result. Next time it takes ~1 s but it seems the docker is not saving the cached compiled code. There are packages that allow compiling and and adding to the main Julia image, but this is a process that is more complicated and would require a kind of custom Julia build.

@seisman
Copy link
Member Author

seisman commented Sep 30, 2020

Tried to run julia -e "using GMT" in PR #10, but it doesn't work.

@seisman seisman added the help wanted Extra attention is needed label Sep 30, 2020
@joa-quim
Copy link
Member

Yes, looks like the cache is trashed every the VM is closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants