Commit 803cf7d8 authored by Jean-Eric Campagne's avatar Jean-Eric Campagne
Browse files

(JEC) 15/4/15 fix MakeFile and update the Readme

parent 79f5c5f6
......@@ -3,7 +3,8 @@ ifeq ($(MACH), Linux)
ifeq ($(BLAS), 1)
# ===== OpenBLAS ========
BLASYES = -DCBLAS
BLASDIR = /opt/local/
BLASDIR = /opt/OpenBLAS
BLASINC = $(BLASDIR)/include
BLASLIB = -L$(BLASDIR)/lib
BLASLIBN = -lopenblas
endif
......
......@@ -25,18 +25,23 @@ Look at the `libsharp-code/libsharp/sharp_cxx.h` file and add if necessary
sharp_geom_info* get_geom_info() { return ginfo;}
sharp_alm_info* get_alm_info() { return ainfo; }
* OpenBLAS (not Darwin):
* OpenBLAS (see note Darwin below):
If the variable `CBLAS` is defined then the code of laguerreTransform.cc use the BLAS matrix multiplication highly optimized. See installation in the Readme.md using
`git clone https://github.com/xianyi/OpenBLAS.git`
**WARNING** on Darwin the Makefile use the `Accelerate Framework` features which are a bit more effective than OpenBLAS.
**WARNING**: on Darwin the Makefile use the `Accelerate Framework` features which are a bit more effective than OpenBLAS.
# Compilation
> edit Makefile and adapat to local platform :
1) adapt to the type of Machine MacOSX (Darwin) vs Linux
2) adapt the location of the libsharp library (SHARPDIR)
3) on Linux adapt the location of BLAS/OpenBLAS
> make
4) then the make depends on the plateform and if you have BLAS
```
> make MACH=Linux BLAS=1 : on Linux with BLAS ON
> make : (default) on Darwin and use Accelerate Framework
```
> make check
runs a computation of the Nodes & Weights for N=1024
and compare to the xxx.txt.TEST files to produce a
......@@ -68,14 +73,15 @@ If the variable `CBLAS` is defined then the code of laguerreTransform.cc use the
* ./Objs/lagsht_testsuite -n 1024
gives 2 files `lagNodes-1024-Func.txt` and `lagWeights-1024-Func.txt` with the Nodes & Weights computed
* ./Objs/lagsht_testsuite -t 3 -l 1024 -n 128
perform a Laguerre SH transform with the default geometry (Gauss) using Lmax = 1024 and Nmax = 128. The program generates a set of flmn coefficients, then performs a Synthesis followed by an Analysis operations. Finally it computes the maximal absolute and relative errors comparing the original flmn complex values to the results of the Analysis. The timing of the different processes is shown in a sorted tree.
perform a Laguerre SH transform with the default geometry (Gauss) using Lmax = 1024 and Nmax = 128. The program generates a set of flmn coefficients, then performs a Synthesis followed by an Analysis operations. Finally it computes the maximal absolute and relative errors comparing the original flmn complex values to the results of the Analysis. The timing of the different processes is shown in a sorted tree (here on Darwin Mac Os X with Accelerate Framework).
````
./Objs/lagsht_testsuite -t 3 -l 1024 -n 128
Max Memory size: 8589 MBytes
___________ MultiSphericalLaguerreTransform TEST _____________
LaguerreTransform start....
Sum roots = 16640 -> diff with theory: -4.9738e-14
Sum weights = 0.657058 -> diff with theory: 1.58752e-13
Sum roots = 16640 -> diff with theory: -5.68434e-14
Sum weights = 0.657058 -> diff with theory: 1.79737e-13
SetThetaPhiMap: Geom, Nring, Nphi, Npix, Nalm: Gauss, 1024, 2047, 2096128, 524800
Main:Synthesis r_8 function...
Multi Synthesis with Function....:128
......@@ -91,32 +97,32 @@ Error analysis...
(67174398) : flnm Orig (-0.16129,0.314123) <-> flmn Rec (-0.16129,0.314123)
(67174399) : flnm Orig (0.386101,0.876158) <-> flmn Rec (0.386101,0.876158)
>>>>>>>>>>>>>>>>>>>>> <<<<<<<<<<<<<<<<<<<<<<<<<<
Err. Max. 1.99652e-11 [9970845], Err. Rel. 2.84023e-08
Err. Max. 2.30178e-11 [9469597], Err. Rel. 3.35695e-08
>>>>>>>>>>>>>>>>>>>>> <<<<<<<<<<<<<<<<<<<<<<<<<<
Total wall clock time for 'MultiSphericalLaguerreTransform': 50.7549s
Total wall clock time for 'MultiSphericalLaguerreTransform': 35.2387s
|
+- processing : 94.57% (48.0011s)
+- processing : 91.50% (32.2422s)
| |
| +- processing part Analysis : 53.66% (25.7580s)
| +- processing part Analysis : 56.91% (18.3499s)
| | |
| | +- Laguerre MultiAnalysis : 48.35% (12.4527s)
| | +- SHT Analysis : 44.46% (11.4522s)
| | +- <unaccounted> : 7.19% ( 1.8531s)
| | +- SHT Analysis : 67.80% (12.4420s)
| | +- Laguerre MultiAnalysis : 18.50% ( 3.3947s)
| | +- <unaccounted> : 13.70% ( 2.5131s)
| |
| +- processing part Synthesis : 46.34% (22.2431s)
| +- processing part Synthesis : 43.09% (13.8923s)
| | |
| | +- SHT Synthesis : 48.04% (10.6858s)
| | +- Laguerre MultiSynthesis : 46.13% (10.2609s)
| | +- <unaccounted> : 5.83% ( 1.2964s)
| | +- SHT Synthesis : 81.70% (11.3503s)
| | +- Laguerre MultiSynthesis : 5.53% ( 0.7685s)
| | +- <unaccounted> : 12.77% ( 1.7734s)
| |
| +- <unaccounted> : 0.00% ( 0.0000s)
|
+- data input : 1.64% ( 0.8313s)
+- <unaccounted> : 3.79% ( 1.9225s)
+- data input : 2.76% ( 0.9727s)
+- <unaccounted> : 5.74% ( 2.0239s)
Accumulated timing overhead: approx. 0.0000s
Accumulated timing overhead: approx. 0.0002s
---/ Fin bloc try ----
---- Programme lagsh_testsuite.cc - FIN (Rc=0) ---
```
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment