ratt-ru / simms

Creates empty measurement sets using the the CASA simulate tool.
GNU General Public License v2.0
7 stars 8 forks source link

Getting nan image using MS created with simms #4

Closed modhurita closed 9 years ago

modhurita commented 9 years ago

I created an MS using the follwoing command:

mitra@elwood:~/SimTest$ simms/simms.py -T VLA -l VLAC -dt 600 -st 8 -ih -4 -nc 8 -df 24e+6 -f0 1.330e9 -dir J2000,1.49488453rad,0.8700817rad VLAC_ANTENNAS mitra@elwood:~/SimTest$ cp -r VLAC_8h600_1330MHz24MHz_8ch.MS VLAC.MS

The uv coverage looks ok: vlac ms_uvcov

I then ran turbo-sim from meqbrowser; this is the profile I used:

gridded_sky.center_source_flux = 20.0 gridded_sky.grid_l0 = 0 gridded_sky.grid_m0 = 0 gridded_sky.grid_size = 7 gridded_sky.grid_step = 25.0 gridded_sky.model_func = grid_model gridded_sky.source_flux = 0.2 gridded_sky.source_freq0 = None gridded_sky.source_pol = 0 gridded_sky.source_spi = None gridded_sky.source_spi_2 = None gridded_sky.source_type = point img_sel.image_clean_gain = 0.1 img_sel.image_clean_method = clark img_sel.image_clean_niter = 1000 img_sel.image_clean_resetmodel = 1 img_sel.image_clean_threshold = 0Jy img_sel.image_viewer = tigger img_sel.imaging_arcmin = 180.0 img_sel.imaging_chanmode = 1 (average all) img_sel.imaging_column = CORRECTED_DATA img_sel.imaging_custom_ms_select = 0 img_sel.imaging_enable_wproj = 1 img_sel.imaging_freqmode = frequency img_sel.imaging_ifrs = all img_sel.imaging_npix = 2048 img_sel.imaging_padding = 1.0 img_sel.imaging_phasecenter = default img_sel.imaging_stokes = I img_sel.imaging_taper_gauss = 0 img_sel.imaging_weight = natural img_sel.imaging_wprojplanes = 128 img_sel.output_fitsname = default me.e_enable = 0 me.g_enable = 0 me.l_enable = 0 me.ncorr_enable = 0 me.p_enable = 0 me.sky.siamese_agw_azel_sky = 0 me.sky.siamese_oms_fitsimage_sky = 0 me.sky.siamese_oms_gridded_sky = 1 me.sky.siamese_oms_transient_sky = 0 me.sky.tiggerskymodel = 0 me.use_jones_inspectors = 0 me.use_skyjones_visualizers = 0 me.use_smearing = 0 me.z_enable = 0 ms_sel.ms_corr_sel = 2x2 ms_sel.ms_ifr_subset_str = all ms_sel.ms_taql_str = None ms_sel.msname = VLAC.MS ms_sel.output_column = CORRECTED_DATA ms_sel.select_channels = 0 ms_sel.tile_size = 10000 noise_from_sefd = 0 noise_stddev = 0.1 random_seed = time read_ms_model = 0 run_purr = 0 sim_mode = sim only tensormeqmaker.psv_class = PSVTensor uvw_refant = default uvw_source = from MS

However, the dirty image after I run the simulation is an all-nan image. I can't see anything problematic in the log:

mitra@elwood:~/SimTest$ (Meow.MSUtils: found /usr/bin/lwimager, can use it for imaging.) (Meow.MSUtils: found image viewer /home/mitra/MeqTrees/tigger/Tigger/bin/tigger) (Meow.MSUtils: found image viewer /usr/local/karma/bin/kvis) Successful readonly open of autonoread-locked table VLAC.MS: 24 columns, 16848 rows Successful readonly open of autonoread-locked table /home/mitra/SimTest/VLAC.MS/ANTENNA: 8 columns, 27 rows Warning! This MS does not define unique ANTENNA names. Using antenna indices instead. Successful readonly open of default-locked table /home/mitra/SimTest/VLAC.MS/OBSERVATION: 9 columns, 1 rows Successful readonly open of autonoread-locked table /home/mitra/SimTest/VLAC.MS/POLARIZATION: 4 columns, 1 rows Successful readonly open of autonoread-locked table /home/mitra/SimTest/VLAC.MS/DATA_DESCRIPTION: 3 columns, 1 rows Successful readonly open of autonoread-locked table /home/mitra/SimTest/VLAC.MS/SPECTRAL_WINDOW: 14 columns, 1 rows Successful readonly open of autonoread-locked table /home/mitra/SimTest/VLAC.MS/FIELD: 9 columns, 1 rows Using LSM module from Tigger (using svn version) at /home/mitra/MeqTrees/tigger/Tigger (in path) Successful readonly open of default-locked table VLAC.MS: 24 columns, 16848 rows Successful readonly open of default-locked table VLAC.MS: 24 columns, 16848 rows Successful readonly open of default-locked table VLAC.MS: 24 columns, 16848 rows Successful readonly open of default-locked table VLAC.MS: 24 columns, 16848 rows MSUtils: imager args are python /home/mitra/MeqTrees/meqtrees-cattery/Cattery/Meow/make_dirty_image.py data=CORRECTED_DATA ms=VLAC.MS mode=channel weight=natural stokes=I npix=2048 prefervelocity=False cellsize=5.2734375arcsec spwid=0 field=0 padding=1.000000 image_viewer=tigger wprojplanes=128 chanmode=channel nchan=8 chanstart=0 chanstep=1 img_nchan=1 img_chanstart=0 img_chanstep=8 fits=VLAC.MS.CORRECTED_DATA.channel.1ch.fits image=VLAC.MS.CORRECTED_DATA.channel.1ch.img remove_image lwimager: Version 1.3.2 2014-12-15 09:52:50 INFO Imager::open() Opening MeasurementSet /home/mitra/SimTest/VLAC.MS 2014-12-15 09:52:50 INFO imager::data selection Selecting data 2014-12-15 09:52:50 INFO imager::data selection Selected all 16848 visibilities 2014-12-15 09:52:50 INFO Imager::selectDataChannel() Selecting 8 channels, starting at 0, stepped by 1, for spw 0 2014-12-15 09:52:50 INFO imager::defineimage() Defining image properties:nx=2048 ny=2048 cellx='5.27344arcsec' celly='5.27344arcsec' stokes=I' mode=channel nchan=1 start=0 step=8 spwids=[0] fieldid=0 facets=1 frame=1 distance='0m' 2014-12-15 09:52:50 INFO imager::defineimage() phaseCenter='field-0 ' mStart='Radialvelocity: 0' qStep='1 km/s'' mFreqStart='Frequency: 0 2014-12-15 09:52:50 INFO imager::weight() Weighting MS: Imaging weights will be changed 2014-12-15 09:52:50 INFO imager::weight() Natural weighting 2014-12-15 09:52:50 INFO imager::setoptions() Setting processing options 2014-12-15 09:52:50 INFO imager::makeimage() Calculating image (without full skyequation) 2014-12-15 09:52:50 INFO imager::makeimage() Making dirty image from corrected data 2014-12-15 09:52:50 INFO imager::makeimage() Image is : VLAC.MS.CORRECTED_DATA.channel.1ch.img 2014-12-15 09:52:50 INFO imager::createFTMachine() Performing w-plane projection 2014-12-15 09:52:50 INFO WPConvFunc::findConvFunction W projection using 128 planes 2014-12-15 09:52:50 INFO WPConvFunc::findConvFunction Estimating maximum possible W = 9778.48 (wavelengths) 2014-12-15 09:52:50 INFO WPConvFunc::findConvFunction Typical wavelength = 0.225408 (m) 2014-12-15 09:52:50 INFO WPConvFunc::findConvFunction Scaling in W (at maximum W) = 0.606267 wavelengths per pixel 2014-12-15 09:54:03 INFO WPConvFunc::findConvFunction Convolution support = [16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 24, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 36, 36, 36, 36, 36, 36, 36, 36, 40, 40, 40, 40, 40, 40, 40, 40, 44, 44, 44, 44, 44, 44, 44, 48, 48, 48, 48, 48, 48, 48, 52, 52, 52, 52, 52, 52, 56, 56, 56, 56, 56, 56, 60, 60, 60, 60, 60, 60, 64, 64, 64] pixels in Fourier plane 2014-12-15 09:54:03 INFO WPConvFunc::findConvFunction Memory used in gridding function = 4 MB from maximum 257920 MB 2014-12-15 09:54:06 INFO ImageFitsConverter::ImageToFITS Copying '/home/mitra/SimTest/VLAC.MS.CORRECTED_DATA.channel.1ch.img' to 'VLAC.MS.CORRECTED_DATA.channel.1ch.fits' Copying row by row (2048 pixels). lwimager normally ended

Pinging @o-smirnov too.

SpheMakh commented 9 years ago

Hmm, same thing works for me. This is my TDL profile; load turbo-sim:simms: [turbo-sim:simms] gridded_sky.center_source_flux = default gridded_sky.grid_l0 = 0 gridded_sky.grid_m0 = 0 gridded_sky.grid_size = 5 gridded_sky.grid_step = 2 gridded_sky.model_func = cross_model gridded_sky.source_flux = 1 gridded_sky.source_freq0 = None gridded_sky.source_pol = 0 gridded_sky.source_spi = None gridded_sky.source_spi_2 = None gridded_sky.source_type = point me.e_enable = 0 me.g_enable = 0 me.l_enable = 0 me.ncorr_enable = 0 me.p_enable = 0 me.sky.siamese_agw_azel_sky = 0 me.sky.siamese_oms_fitsimage_sky = 0 me.sky.siamese_oms_gridded_sky = 1 me.sky.siamese_oms_transient_sky = 0 me.sky.tiggerskymodel = 0 me.use_jones_inspectors = 1 me.use_skyjones_visualizers = 0 me.use_smearing = 0 me.z_enable = 0 ms_sel.ms_corr_sel = 2x2 ms_sel.ms_ifr_subset_str = all ms_sel.ms_taql_str = None ms_sel.msname = VLAC_8h600_1330MHz24MHz_8ch.MS ms_sel.output_column = CORRECTED_DATA ms_sel.select_channels = 0 ms_sel.tile_size = 8 noise_from_sefd = 0 noise_stddev = None random_seed = time read_ms_model = 0 run_purr = 0 sim_mode = sim only tensormeqmaker.psv_class = PSVTensor uvw_refant = default uvw_source = from MS

modhurita commented 9 years ago

Still getting the same error. Also, when I try to make a clean image, it says:

2014-12-15 12:31:20 INFO CubeSkyEquation::makeSimplePSF Maximum of approximate PSF for field 0 = 0 : renormalizing to unity PSFZero SkyEquation:: PSF calculation resulted in a PSF with its peak being 0 or less! : Please check that the required data exists and is not flagged

SpheMakh commented 9 years ago

Ok, the casacore/data/geodetic on elwood is outdated. You could download the latest geodetic by running * svn co https://svn.cv.nrao.edu/svn/casa-data/distro/geodetic $HOME/geodetic * and then replace * /usr/share/casacore/data/geodetic * with * $HOME/geodetic * in your $HOME/.casarc file. Or ask @o-smirnov to update casacore/data/geodetic on the server.

BTW: you can specify the name of the MS via --name instead of creating the MS with the default name an then renaming it.

SpheMakh commented 9 years ago

CASA has been updated on elwood. Simms should work fine now

modhurita commented 9 years ago

I am still geting the same error. Is there anything else I should have done other than just repeating the simms followed by turbo-sim steps I was doing earlier?

SpheMakh commented 9 years ago

I've done this on elwood and it works. Try this to check if all is working well (on elwood): First update simms (* git pull * in your simms directory)

then try the last two steps with the VLAC_ANTENNAS_MODHU antenna table (got that from your VLAC.MS/ANTENNA)

SpheMakh commented 9 years ago

Ok, so the antenna table used to make VLAC.MS was also defective. But we should make a habbit of frequently updating CASA/geodetic.