Giter VIP home page Giter VIP logo

lensingbiases's Introduction

Lensingbiases

Computation of N0 and N1 biases in the context of CMB weak lensing (flat-sky approximation). Derivatives of N1 biases with respect to the lensing potential power-spectrum available.

License: GNU License (see the LICENSE file for details) covers all files in the lensingbiases repository unless stated otherwise.

Before starting

The Python code has the following dependencies:

  • numpy, pylab, argparse
  • f2py

In most machines, those packages are automatically installed. Make sure you update your PYTHONPATH to use the code. Just add in your bashrc:

BIASPATH=/path/to/the/package
export PYTHONPATH=$PYTHONPATH:$BIASPATH

Compilation of Fortran

The package is written in python, but internal operations are done in Fortran. Therefore you need to compile it before using the routines. We provide a setup file. Just run:

python setup.py build_ext --inplace --fcompiler=gfortran

Depending on system, you may need to specify a different fortran compiler. For the purist, we also provide a Makefile for a direct compilation. For extended multipole ranges, computation can be long. So make sure that you are using several processors by adding in your bashrc:

export OMP_NUM_THREADS=n

Usage

User has to provide the range of multipole, beam width, noise level, etc. In order to ease the start, we provide both a test script and a launcher:

  • LensingBiases.py (see the main)
  • launch.sh

For usage on clusters, we also provide a batch (SLURM).

lensingbiases's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

lensingbiases's Issues

Problem installing the software

Hello,

I have found an error when installing the software. I have tried with different devices and I always found the same problem (shown below). I would greatly appreciate any help.

Thanks in advance,

Miguel

miguel@miguel-VirtualBox:~/Desktop/lensingbiases$ sudo python3.6 setup.py install
running install
running build
running config_cc
unifing config_cc, config, build_clib, build_ext, build commands --compiler options
running config_fc
unifing config_fc, config, build_clib, build_ext, build commands --fcompiler options
running build_src
build_src
building extension "LensingBiases_f" sources
f2py options: []
adding 'build/src.linux-x86_64-3.6/build/src.linux-x86_64-3.6/fortranobject.c' to sources.
adding 'build/src.linux-x86_64-3.6/build/src.linux-x86_64-3.6' to include_dirs.
adding 'build/src.linux-x86_64-3.6/LensingBiases_f-f2pywrappers2.f90' to sources.
build_src: building npy-pkg config files
running build_py
running build_ext
customize UnixCCompiler
customize UnixCCompiler using build_ext
get_default_fcompiler: matching types: '['gnu95', 'intel', 'lahey', 'pg', 'nv', 'absoft', 'nag', 'vast', 'compaq', 'intele', 'intelem', 'gnu', 'g95', 'pathf95', 'nagfor']'
customize Gnu95FCompiler
Found executable /usr/bin/gfortran
customize Gnu95FCompiler
customize Gnu95FCompiler using build_ext
building 'LensingBiases_f' extension
compiling C sources
C compiler: x86_64-linux-gnu-gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -g -fwrapv -O2 -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC

compile options: '-Ibuild/src.linux-x86_64-3.6/build/src.linux-x86_64-3.6 -I/usr/local/lib/python3.6/dist-packages/numpy/core/include -I/usr/include/python3.6m -c'
extra options: ''
x86_64-linux-gnu-gcc: build/src.linux-x86_64-3.6/LensingBiases_fmodule.c
x86_64-linux-gnu-gcc: build/src.linux-x86_64-3.6/build/src.linux-x86_64-3.6/fortranobject.c
x86_64-linux-gnu-gcc: error: : No such file or directory
x86_64-linux-gnu-gcc: error: : No such file or directory
error: Command "x86_64-linux-gnu-gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -g -fwrapv -O2 -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -Ibuild/src.linux-x86_64-3.6/build/src.linux-x86_64-3.6 -I/usr/local/lib/python3.6/dist-packages/numpy/core/include -I/usr/include/python3.6m -c build/src.linux-x86_64-3.6/LensingBiases_fmodule.c -o build/temp.linux-x86_64-3.6/build/src.linux-x86_64-3.6/LensingBiases_fmodule.o -MMD -MF build/temp.linux-x86_64-3.6/build/src.linux-x86_64-3.6/LensingBiases_fmodule.o.d " failed with exit status 1

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.