Notes Installation of InSAR processing software Roi_pac under Ubuntu

Source: Internet
Author: User
Tags gfortran

Http://wenku.baidu.com/link?url= D4hpl0ozur2np6kzl0ckb65out4x4kt74q2taj4yy3e7jvrnpxq-rjlpa-nd5jyfzlgyskhqggccvgjg-3d32inyg_5n80xnplsuev47n33

Http://www.linuxidc.com/Linux/2011-10/44952.htm

The installation method available on the Roi_pac home page is cumbersome, and the installation can be completed easily under Ubuntu.

The article involves ordering everyone not to knock hard, to use the Flexible tab key to complete.

0) Roi_pac installation needs Gcc,gfortran,perl environment, so first look at how these several environments installed, if already installed, do not run the following command.

$ sudo apt-get install gcc Gfortran perl

0) Roi_pac also needs a very important environment setting

$ sudo apt-get install Libfftw3-dev

1) Roi_pac must first install the FFTW. Currently the latest version is 3.3.

Free in http://linux.linuxidc.com/

user name and password are www.linuxidc.com

specific Download directory under/pub/2011/06/21/ubuntu install Doris and related software tutorials/

$ tar xzfv fftw-3.3.tar.gz

$ CD fftw-3.3

$ ./configure--enable-float--prefix=/usr/local/fftw cc=gcc

For multi-core CPUs above P3, this command can be optimized for $./configure--enable-float--enable-sse--with-combined-threads

Install the FFTW library into the/USR/LOCAL/FFTW folder

$ Make

$ sudo make install

When the installation directory is not indicated in configure, FFTW is installed to/usr/local/lib and/usr/local/include by default and requires super privileges.

After installing FFTW set up two environment variables, ROI_PAC need

$ Export Fftw_lib_dir=/usr/local/lib
$ Export Fftw_inc_dir=/usr/local/include

2) Download the Roi_pac and install.

Roi_pac download More trouble, I was downloaded in cdsn, thank you for sharing the information Caozhentan.

The download is roi_pac_3_0_1.tgz

$ tar xzfv roi_pac_3_0_1.tgz

$ CD roi_pac_3_0_1

$ CD Roi_pac

$ ./configure

If the GCC,GFORTRAN,PERL environment is installed, FFTW and environment variable settings are OK, then this step is not a problem

$ Make

$ sudo make install

This step is an error:

The Lib and include paths that cannot be found for FFTW are still displayed when the environment variables for LIB and Inc are set

Follow the instructions on the tip:

A command prompt was added after configure:

$ ./configure ldflag= "-l/usr/local/fftw/lib" cppflag= "-i/usr/local/fftw/include "

In addition, although the reason is not clear, but using GCC compiled FFTW Cubby c directly compiled FFTW library is a bit smoother.

That is used when the FFTW is compiled, even with:

$ sudo./configure cc=cc

F: Shows the compilation process after adding a suffix

Files after make still have an error:

It is not possible to find the SFFTWF file and then find the installation Libfftw3-dev(which should be something like hardware-driven).

$ sudo apt-get install Libfftw3-dev

See details: https://www.ruby-forum.com/topic/3304238

This completes the installation

Roi_pac execution Program is in the/usr/local/bin directory.

Roi_pac include files are in the/usr/local/share/roi_pac directory.

3) Modify the path variable once and for all.

$ CD

Back to login Directory

$ VI. BASHRC

Do not like VI can be used gedit,$ gedit. BASHRC

Add the following four lines to the end of the file

Export int_bin= "/usr/local/bin"
Export int_scr= "/usr/local/share/roi_pac"
Export fftw_lib= "/usr/local/lib"
Export path= $PATH: $INT _bin: $INT _scr: $FFTW _lib

If you are familiar with the shell, you can modify these four lines.

For me, I have set the/usr/local/bin in the path when I install Doris, so I don't need the first line, and the last line is changed.

Or you can modify it in sar_config and then source it in the. bashrc file.

A) changes in Sar_config:

Export int_bin= "/usr/local/bin"
Export int_scr= "/usr/local/share/roi_pac"
Export my_bin= "/usr/local/bin"
Export my_scr= "/usr/local/share/roi_pac"

Export fftw_lib= "/usr/local/lib"
Export fftw_inc= "/usr/local/include"

Export path= $PATH: $INT _bin: $INT _scr

Export roi_pac= "/usr/local/roi_pac_3_0_1/roi_pac"
Export sar_prc_dir= "$ROI _PAC/PRC"
Export sar_odr_dir= "$ROI _pac/odr"

B) Then add a sentence in the ~/.BASHRC file

Source/usr/local/roi_pac_3_0_1/roi_pac/doc/sar_config

4) Installation of the Roi_pac 3.0.1 two patches "not up"//alos temporarily need not

4.1) The first patch installation method in Http://www.roipac.org/ALOS_PALSAR download make_raw_alos.pl, copy to/usr/local/share/roi_pac directory.

However, you will be prompted Perl^m to find it in use. The reason is that make_raw_alos.pl is in DOS format and needs to be converted to UNIX format.

If this is the first installation, follow these commands

$ wget http://www.roipac.org/ALOS_PALSAR?action=AttachFile&do=get&target=make_raw_alos.pl

You can find the relevant link in Http://www.roipac.org/ALOS_PALSAR directly with the browser and save it as a login directory.

$ sudo apt-get install Tofrodos

Installing the DOS and UNIX format conversion tool

$ Fromdos make_raw_alos.pl

Convert to UNIX format, remove ^m

$ chmod a+x make_raw_alos.pl

Plus Execute permissions

$ sudo mv Make_raw_alos.pl/usr/local/share/roi_pac

Move the file to the appropriate location

4.2) The second patch is compiled ADD_RMGAMPPHS.C into the ROI_PAC/FIP directory and copied to the/usr/local/bin directory.

But the compilation will go wrong. Please follow the command below

$ CD ROI_PAC_3_0_1/ROI_PAC/FIP

I was in the login directory decompression Roi_pac, into the FIP directory

$ VI ADD_RMGAMPPHS.C

Add the following line to the third line of the file, you can use Gedit ADD_RMGAMPPHS.C

#include <stdlib.h>

$ gcc-o add_rmgampphs ADD_RMGAMPPHS.C

Compile

$ chmod a+x add_rmgampphs

Plus Execute permissions

$ sudo mv Add_rmgampphs/usr/local/bin

Move the file to the appropriate location


So two patches are also installed to complete.

Notes Installation of InSAR processing software Roi_pac under Ubuntu

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.