-
Notifications
You must be signed in to change notification settings - Fork 37
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
Fix compilation time #258
Comments
With a fully precompiled environment I get a 3.6 second time for loading Rasters, ArchGDAL and NCDatasets and another 3.8 seconds opening a netcdf file. The largest imports timing I see is Dimensionaldata with 800 ms and ImageCore with 658 ms `@time_imports` timings
|
Try it without ArchGDAL and NCDatasets.jl |
Just using Rasters takes 1.5 seconds and then loading only NCDatasets to actually be able to load data takes another 0.42 seconds.
and the rest is below 50 ms per package. Details```julia julia> @time @time_imports using Rasters 1.2 ms Statistics 0.6 ms Adapt 0.3 ms SuiteSparse 0.6 ms Requires 3.9 ms ArrayInterface 1.5 ms ConstructionBase 2.9 ms Extents 3.4 ms InvertedIndices 0.3 ms IteratorInterfaceExtensions 17.1 ms Preferences 0.5 ms PrecompileTools 18.9 ms RecipesBase 0.4 ms TableTraits 0.2 ms DataValueInterfaces 1.3 ms DataAPI 42.7 ms Tables 44.1 ms IntervalSets 0.4 ms ConstructionBase → ConstructionBaseIntervalSetsExt 0.2 ms IntervalSets → IntervalSetsStatisticsExt 703.7 ms DimensionalData 57.3 ms FixedPointNumbers 110.4 ms ColorTypes 92.3 ms OffsetArrays 26.8 ms DiskArrays 140.7 ms FillArrays 6.9 ms FillArrays → FillArraysSparseArraysExt 0.4 ms FillArrays → FillArraysStatisticsExt 0.8 ms FieldMetadata 0.6 ms Flatten 17.5 ms GeoInterface 4.6 ms ProgressMeter 15.1 ms Missings 0.3 ms Reexport 15.1 ms MacroTools 5.0 ms StaticArraysCore 0.6 ms ArrayInterface → ArrayInterfaceStaticArraysCoreExt 26.6 ms Setfield 14.3 ms GeoFormatTypes 37.9 ms Rasters 1.516850 seconds (1.78 M allocations: 95.463 MiB, 3.61% gc time, 1.75% compilation time) julia> @time @time_imports using NCDatasets julia> @time Raster("/home/fcremer/Daten/image_vs_heatmap_corner.nc")
|
using DimensionalData takes 0.91 seconds with itself being the main contributor with the following import timings: julia> @time @time_imports using DimensionalData
1.3 ms Statistics
0.7 ms Adapt
0.4 ms SuiteSparse
0.4 ms Requires
3.5 ms ArrayInterface
1.4 ms ConstructionBase
3.0 ms Extents
3.6 ms InvertedIndices
0.3 ms IteratorInterfaceExtensions
16.9 ms Preferences
0.4 ms PrecompileTools
18.6 ms RecipesBase
0.4 ms TableTraits
0.2 ms DataValueInterfaces
1.2 ms DataAPI
42.6 ms Tables
44.0 ms IntervalSets
0.5 ms ConstructionBase → ConstructionBaseIntervalSetsExt
0.3 ms IntervalSets → IntervalSetsStatisticsExt
707.2 ms DimensionalData
0.915788 seconds (1.32 M allocations: 65.461 MiB, 3.02% gc time, 2.96% compilation time) |
I think a lot of DD is loading the precompiled code. We could maybe cull some less used parts?
|
ArchGDAL depending on ImageCore is a pretty big chunk of your total time, I'm not sure why we need that. It pulls in:
|
Compile time is pretty good here now with extensions. Closing. |
Loading a raster takes a few seconds the first run. Some of this is due to the backends, some to DimensionalData.jl, some here. We should fix all of these as much as possible.
The text was updated successfully, but these errors were encountered: