Simulate a mock line observation

make mock observations using mockgenerator.py

[1]:
from luv_finder import MockObservation
[2]:
mock_obs = MockObservation(
    cube_shape=(50, 256, 256),
    cell='0.25arcsec',
    dv="100km/s",
    freq_center="40GHz",
    # sensitivity="0.5mJy",
    integration_time="8min",
    sources = [
        { "position": (-4.25, 23.5),
          "line": { "width": 300, "mean": 39.9, "snr": 13}},
        {"position": (-12.0, -4.25),
         "line": {"width": 300, "mean": 40.2, "snr": 9}}
        # {"position": (-12.0, -4.25),
        #  "line": {"width": 300, "mean": 3.96664359e+1, "snr": 10}}
    ],
    alma_config='alma.cycle13.3.cfg',
)
[3]:
mock_obs.create_cube()
mock_obs.save_cube()
source (-4.25, 23.5): line flux 1.906e+00 Jy km/s
source (-12.0, -4.25): line flux 1.320e+00 Jy km/s
[3]:
'support/line13_line9_input.fits'
[4]:
mock_obs.simulate_observation()
mock_obs.run_imaging()
2026-10-22 18:21:45     SEVERE  simobserve::MeasTable::dUTC(Double) (file /source/casa6/casatools/casacore/measures/Measures/MeasTable.cc, line 4290)   Leap second table TAI_UTC seems out-of-date.
2026-10-22 18:21:45     SEVERE  simobserve::MeasTable::dUTC(Double) (file /source/casa6/casatools/casacore/measures/Measures/MeasTable.cc, line 4290)+  Until the table is updated (see the CASA documentation or your system admin),
2026-10-22 18:21:45     SEVERE  simobserve::MeasTable::dUTC(Double) (file /source/casa6/casatools/casacore/measures/Measures/MeasTable.cc, line 4290)+  times and coordinates derived from UTC could be wrong by 1s or more.
....10....20....30....40....50....60....70....80....90....100%
2026-10-22 18:22:14     WARN    task_tclean::SIImageStore::restore (file /source/casa6/casatools/src/code/synthesis/ImagerObjects/SIImageStore.cc, line 2352)   Restoring with an empty model image. Only residuals will be processed to form the output restored image.
2026-10-22 18:22:26     WARN    task_tclean::SIImageStore::restore (file /source/casa6/casatools/src/code/synthesis/ImagerObjects/SIImageStore.cc, line 2352)   Restoring with an empty model image. Only residuals will be processed to form the output restored image.
[5]:
mock_obs.plot_results()
mock_obs.move_output()
[5]:
'output/ms_files/line13_line9'