Obit Astronomy Software ----------------------- This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. This distribution allows the installation of Obit software for processing astronomical (primarily radio) data. The Obit package relies on third party software and consists of a number of components. Some of the third party software is included in the Obit installation and is built and installed by included scripts. The components of the Obit system are 1) the Obit libraries and tasks (in c), 2) ObitView image display, 3) ObitTalk and interactive python interface. Obit and friends use AIPS and FITS files as native data types and are highly interoperable with AIPS. Download the Obit source installation kit contents via % git clone https://github.com/bill-cotton/ObitBase/ where you would like it installed. The software can be built using one of the scripts in subdirectory scripts. scripts/build_with_SSE Use only SSE vector instructions scripts/build_with_AVX Use also AVX vector instructions scripts/build_with_AVX2 Use also AVX2 vector instructions scripts/build_with_AVX512 Use also AVX512f vector instructions These control which vector instruction set is used in the build. These depend on the hardware in the target machine and you would like to use the most advanced version that the machine supports. Attempting to use an unsupported instruction causes the program to crash. If your machine has a /proc/cpuinfo file, you can test the various options (sse, avx, avx2, avx512) by % grep avx2 /proc/cpuinfo If this produces a blank string, that option is not available. Every interesting computer should have sse and most will have avx. The vector instruction set used in one of the scripts/build-with... will be written in file VectorType as 'SSE', 'AVX', AVX2 or 'AVX512. Alternatively, the instructions used in the last build can be seen in src/Obit/src/Makefile. The installation will download to current version of the Obit software from github and use it to build the installation. This installation should leave executables in the bin directory: bin/ObitTalk Python command line interface bin/ObitTalk3 Python3 command line interface bin/ObitView Image viewer bin/ObitMess Message window GUI (optional) There are also script templates in subdirectory scripts that can be edited to provide useful functionality, Edit lines marked "EDIT". scripts/SetupObit.(c)sh (Tcsh)sh script defines environment variables. This adds the bin directory to your path. Copy, edit to provide details and execute it. scripts/dot.obitrc.py Obit startup script that tells where various parts of Obit and AIPS reside. Copy to .obitrc.py, edit to provide details. It will be invoked by ObitTalk from either your home directory or cwd. Various useful make functions: target: Build obit, uses $CPPFLAGS to set AVX flags, scripts/build_with_AVX? better. clean: Delete the installation products. NOTE: this will also lose any modifications you have made, back them up. update: Update the version of Obit from github, follow this by script/rebuild_with??? to rebuild the software. backup: Makes a gzipped tarball copy of the installation in ../ObitBase_backup.tgz. distro: Makes binary distribution and tarball in distro, set $VTYPE to specify the version of the vector set used, e.g. SSE, AVX, AVX2, AVX512 Local installations of libraries not in the standard places can be pointed to by using an environmentalism variable $LOCAL (directory containing subdirectories include, lib), also setting $LD_LIBRARY_PATH may help. This can be added to scripts/SetupObit.csh (tcsh) (and executing) as # Local Mods setenv LOCAL /export/ssd/bcotton/Git/Obit/trunk/other/ setenv CPPFLAGS "-mavx -DHAVE_AVX" setenv VTYPE "AVX" This installation uses git access the Obit repository on GitHub for the latest version so you'll need this installed. Several of the more troublesome third party libraries are included in this distribution but other libraries will be searched for. Any missing ones may have to be installed if their functionality is needed. Not all are required to build. Included packages: cfitsio FITS format I/O curl Network communication plplot Plotting package xml2 XML package xmlrpc Interprocess communication via the xml/rpc protocol Major packages not included fftw3 Fast Fourier Transform package glib-2.0 Gnu library gsl Gnu Scientific Library motif X windows widgets for ObitView wvr ALMA water vapor radiometer library zlib Read gzip compressed files A more detailed list of software and libraries that might be needed is given below. Obit Binary Distribution ------------------------ After the main installation has been successfully built, a binary distribution can be built in the distro subdirectory using "make bindistro" from the command line. It will be labeled with the Vector type (SSE, AVX, AVX2 or AVX512) from the environment variable $VTYPE. This will leave a gzipped tarball in the distro directory. NB: Delete the old version before building a newer one. You may need to set LD_LIBRARY_PATH if it's needed to run. The version ID in Makefile should be updated to give the current Obit version number. Running Obit ------------ The command line interface (CLI) to Obit software is ObitTalk, or ObitTalk3 explicitly for python3. This is basically python with some modules preloaded. Obit functions and tasks are available from this python interface. In order to run ObitTalk, you need to tell it where various software components and data directories are. If you have an AIPS setup, Obit can follow the trail of breadcrumbs to find its data. Otherwise, you'll need a .obitrc.py file, see discussion of scripts/dot.obitrc.py above. Defining and executing the SetupObit.(c)sh (see description above) may also be necessary. After Obit is installed and in your path, the python interface is brought up by % ObitTalk (or ObitTalk3) This will ask for you AIPS user number (arbitrary) if you're using AIPS format data. It then executes the .obitrc.py file. The image viewer, ObitView is started independently: % ObitView & Documentation ------------ User documentation for the CLI, ObitTalk, can be found in src/ObitTalk/doc/ObitTalk.pdf. The most recent documentation is available from the Obit home page http://www.cv.nrao.edu/~bcotton/Obit.html. Troubleshooting: --------------- If the build fails there will be no executables in directory bin. In this case look at src/Obit/config.log which should say which external libraries are missing. Also check src/ObitTalk/config.log and src/ObitView/config.log depending on what failed. If one or the other of the ObitTalk scripts (ObitTalk, ObitTalk3) don't run properly, % cd $OBITBASE/src/Obit/python; make Obit might fix it. Missing header files or libraries can be added to the CFLAGS and/or LDFLAGS in the execution of configure in SETUP.Obit (or SETUP.ObitTalk or SETUP.ObitView). The location can also be explicitly given in a "--with-package=/location/of/package/ in the configure command; see configure --help" for details. Alternatively, header files and libraries can be added to deps/include and deps/lib or in a directory pointed to by $LOCAL. Some versions of python3 fail to pick up the correct version of the Obit, the symptom is Python 3.9.2 (default, Feb 28 2021, 17:03:44) ... import _Obit ImportError: obit/obit-1.1.669/share/python/_Obit.so: undefined symbol: PyInstance_Type There are two _Obit*.so libraries: _Obit.so for python2 _Obit.cpython-36m-x86_64-linux-gnu.so for python3.6 If your python is python3 (above example is python3.9.2), then renaming _Obit.cpython-36m-x86_64-linux-gnu.so to _Obit.so may fix the problem. Software and libraries needed to build Obit ------------------------------------------- Software needed: gcc, g++, gfortran A number of critical libraries are included in the ObitBase distribution and built as part of the installation. These are under the deps directory. Included packages: cfitsio FITS format I/O curl Network communication plplot Plotting package xml2 XML package xmlrpc Interprocess communication via the xml/rpc protocol Major packages (devel version) not included fftw3 Fast Fourier Transform package glib-2.0 Gnu library gsl Gnu Scientific Library (including blas) motif X windows widgets almawvr ALMA water vapor radiometer library (libair) zlib Read gzip compressed files Additional Libraries likely needed: gd-devel, libair, libair-devel, opensgmls, pango, pango-devel, pangotf2, python3, python3-devel, wish, wxwidgets ld-linux-x86-64, libbz2, libc, libcd, libcd-devel libcom_err, libcrypt, libcrypto, libcsirocsa, libdl libfreebl3, libfreetype, libgfortran, libgcc_s libgnomeui, libgnomeprintui, libgssapi_krb5 libjpeg, libk5crypto, libkeyutils, libkrb5, libkrb5support liblber-2.4, libldap-2.4, liblzma, libm, libmd, libnspr4 libnss3, libnssutil3, libpcre, libplc4, libplds4, libpng libpthread, libpython3.X, libresolv, librt, libquadmath libsasl2, libsatlas, libselinux, libsmime3, libssl, libssl3 libtinfo, libutil, libxml2, libXm, libXp W. Cotton (bcotton@nrao.edu) June 2025