.. code-block:: text ooooooooo. oooooooooooo ooooo ooooo oooooooooo. 8888 `Y88. 8888 8 8888 888 888 Y8b 888 .d88' oooo ooo 888 888 888 888 888 888ooo88P' `88. .8' 888oooo8 888ooooo888 888 888 888 `88..8' 888 888 888 888 888 888 `888' 888 888 888 888 d88' o888o .8' o888o o888o o888o o888bood8P' .o..P' `Y8P' Python Fast Holographic Deconvolution Translated from IDL to Python as a collaboration between Astronomy Data and Computing Services (ADACS) and the Epoch of Reionisation (EoR) Team. Repository: https://github.com/EoRImaging/pyfhd Documentation: https://pyfhd.readthedocs.io/en/latest/ Git Commit Hash: 467cb91bcba3f06cded5405f3ffcc9638bd13c26 pyfhd Run Started At: Fri May 30 09:52:35 2025 Observation ID: 1088285600 Confifuration File: ./input/1088285600 example/1088285600 example.yaml Validating your input... 2025-05-30 09:52:35 - INFO: Logging and configuration file created and copied to here: /home/skywatcher/projects/pyfhd/output/pyfhd_1088285600_example 2025-05-30 09:52:35 - INFO: Input validated, starting pyfhd run now 2025-05-30 09:52:35 - INFO: Reading in visibilities from: input/1088285600_example/1088285600.uvfits 2025-05-30 09:52:35 - WARNING: OBSRA not found in UVFITS file 2025-05-30 09:52:35 - WARNING: OBSDEC not found in UVFITS file 2025-05-30 09:52:35 - INFO: Setting mwa instrument location to: lon 116.67, lat -26.70, alt 377.83 2025-05-30 09:52:35 - INFO: pyfhd Header Created completed in: 44.74807 milliseconds 2025-05-30 09:52:35 - INFO: Params Created completed in: 0.27895 milliseconds 2025-05-30 09:52:35 - INFO: Visibilities Extracted completed in: 9.38296 milliseconds 2025-05-30 09:52:35 - INFO: Writing the visibilities array to output/pyfhd_1088285600_example/visibilities/1088285600_raw_vis_arr.h5 2025-05-30 09:52:35 - INFO: Writing the weights array to output/pyfhd_1088285600_example/visibilities/1088285600_raw_vis_weights.h5 2025-05-30 09:52:35 - WARNING: Number of Leap Seconds is missing and the time system isn't IAT so we can't know the leap seconds, setting as -1 2025-05-30 09:52:35 - WARNING: PolA params is missing from the UVFITS, set to array of zeros of length n_pol_cal_params or 0 2025-05-30 09:52:35 - WARNING: PolB params is missing from the UVFITS, set to array of zeros of length n_pol_cal_params or 0 2025-05-30 09:52:35 - INFO: Diameters not in UVFITS file continuing. 2025-05-30 09:52:35 - INFO: Beam Full Width Half maximum not present in UVFITS continuing. 2025-05-30 09:52:35 - INFO: Writing the layout dict to output/pyfhd_1088285600_example/layout.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:52:35 - INFO: Layout Dictionary Extracted completed in: 7.91407 milliseconds 2025-05-30 09:52:38 - INFO: Obs Dictionary Created completed in: 2.92785 seconds 2025-05-30 09:52:38 - INFO: Writing the obs_checkpoint dict to output/pyfhd_1088285600_example/checkpoints/1088285600_example_obs_checkpoint.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:52:39 - INFO: Checkpoint Saved: Uncalibrated visibility parameters, array and weights and the observation metadata dictionary saved into output/pyfhd_1088285600_example/obs_checkpoint.h5 2025-05-30 09:52:39 - INFO: Reading in the HDF5 file input/1088285600_example/gauss_beam_pointing0_167635008Hz.h5 2025-05-30 09:52:39 - INFO: Loading input/1088285600_example/gauss_beam_pointing0_167635008Hz.h5 into a dictionary 2025-05-30 09:52:39 - INFO: Beam and PSF dictionary imported. completed in: 301.2073 milliseconds 2025-05-30 09:52:39 - INFO: Basic Flagging Completed completed in: 2.48504 milliseconds 2025-05-30 09:52:40 - INFO: Visibilities Weights Updated After Basic Flagging completed in: 1.17173 seconds 2025-05-30 09:52:40 - INFO: Reading in model visibilities from: /home/skywatcher/projects/pyfhd/input/1088285600_example/1088285600_model.uvfits 2025-05-30 09:52:40 - INFO: Setting mwa instrument location to: lon 116.67, lat -26.70, alt 377.83 2025-05-30 09:52:40 - WARNING: Model time stamps are offset from data by an average of 1.0. Accounting for this to match model time steps to data 2025-05-30 09:52:40 - INFO: Found flagged tiles [4, 124] in the data, flagging from the model 2025-05-30 09:52:40 - INFO: Model Imported and Flagged From UVFITS completed in: 20.36548 milliseconds 2025-05-30 09:52:40 - INFO: Beginning Calibration 2025-05-30 09:52:40 - INFO: Gain initialized beginning vis_calibrate subroutine 2025-05-30 09:52:40 - INFO: Beginning Calibration for polarization 0 (XX) 2025-05-30 09:52:40 - INFO: Convergence was reached for polarization: XX (0) and frequency: 1, with a convergence of: 9.98593970029745e-08 and the threshold was: 1e-07 2025-05-30 09:52:40 - INFO: Convergence was reached for polarization: XX (0) and frequency: 2, with a convergence of: 9.999992919655905e-08 and the threshold was: 1e-07 2025-05-30 09:52:40 - INFO: Convergence was reached for polarization: XX (0) and frequency: 3, with a convergence of: 8.344520524730864e-08 and the threshold was: 1e-07 2025-05-30 09:52:41 - INFO: Convergence was reached for polarization: XX (0) and frequency: 4, with a convergence of: 9.884876342819337e-08 and the threshold was: 1e-07 2025-05-30 09:52:41 - INFO: Convergence was reached for polarization: XX (0) and frequency: 5, with a convergence of: 8.003533551747955e-08 and the threshold was: 1e-07 2025-05-30 09:52:41 - INFO: Convergence was reached for polarization: XX (0) and frequency: 6, with a convergence of: 8.544033568047118e-08 and the threshold was: 1e-07 2025-05-30 09:52:41 - INFO: Convergence was reached for polarization: XX (0) and frequency: 7, with a convergence of: 8.130504801062689e-08 and the threshold was: 1e-07 2025-05-30 09:52:41 - INFO: Convergence was reached for polarization: XX (0) and frequency: 8, with a convergence of: 9.104656101282636e-08 and the threshold was: 1e-07 2025-05-30 09:52:41 - INFO: Convergence was reached for polarization: XX (0) and frequency: 9, with a convergence of: 8.354614840674757e-08 and the threshold was: 1e-07 2025-05-30 09:52:41 - INFO: Convergence was reached for polarization: XX (0) and frequency: 10, with a convergence of: 9.918106515438548e-08 and the threshold was: 1e-07 2025-05-30 09:52:41 - INFO: Convergence was reached for polarization: XX (0) and frequency: 11, with a convergence of: 9.869434977124244e-08 and the threshold was: 1e-07 2025-05-30 09:52:42 - INFO: Convergence was reached for polarization: XX (0) and frequency: 12, with a convergence of: 8.895645139753463e-08 and the threshold was: 1e-07 2025-05-30 09:52:42 - INFO: Convergence was reached for polarization: XX (0) and frequency: 13, with a convergence of: 9.459813804237299e-08 and the threshold was: 1e-07 2025-05-30 09:52:42 - INFO: Beginning Calibration for polarization 1 (YY) 2025-05-30 09:52:42 - INFO: Convergence was reached for polarization: YY (1) and frequency: 1, with a convergence of: 8.583005611987811e-08 and the threshold was: 1e-07 2025-05-30 09:52:42 - INFO: Convergence was reached for polarization: YY (1) and frequency: 2, with a convergence of: 8.466878902748548e-08 and the threshold was: 1e-07 2025-05-30 09:52:42 - INFO: Convergence was reached for polarization: YY (1) and frequency: 3, with a convergence of: 9.921026305432663e-08 and the threshold was: 1e-07 2025-05-30 09:52:42 - INFO: Convergence was reached for polarization: YY (1) and frequency: 4, with a convergence of: 8.426838709848088e-08 and the threshold was: 1e-07 2025-05-30 09:52:42 - INFO: Convergence was reached for polarization: YY (1) and frequency: 5, with a convergence of: 8.969077306790065e-08 and the threshold was: 1e-07 2025-05-30 09:52:42 - INFO: Convergence was reached for polarization: YY (1) and frequency: 6, with a convergence of: 9.584932160621179e-08 and the threshold was: 1e-07 2025-05-30 09:52:43 - INFO: Convergence was reached for polarization: YY (1) and frequency: 7, with a convergence of: 9.976283744227554e-08 and the threshold was: 1e-07 2025-05-30 09:52:43 - INFO: Convergence was reached for polarization: YY (1) and frequency: 8, with a convergence of: 9.165962316245378e-08 and the threshold was: 1e-07 2025-05-30 09:52:43 - INFO: Convergence was reached for polarization: YY (1) and frequency: 9, with a convergence of: 8.711660483214532e-08 and the threshold was: 1e-07 2025-05-30 09:52:43 - INFO: Convergence was reached for polarization: YY (1) and frequency: 10, with a convergence of: 8.482012447714498e-08 and the threshold was: 1e-07 2025-05-30 09:52:43 - INFO: Convergence was reached for polarization: YY (1) and frequency: 11, with a convergence of: 8.962296769672843e-08 and the threshold was: 1e-07 2025-05-30 09:52:43 - INFO: Convergence was reached for polarization: YY (1) and frequency: 12, with a convergence of: 8.715709933918354e-08 and the threshold was: 1e-07 2025-05-30 09:52:43 - INFO: Convergence was reached for polarization: YY (1) and frequency: 13, with a convergence of: 8.780971269246983e-08 and the threshold was: 1e-07 2025-05-30 09:52:43 - INFO: Function vis_calibrate_subroutine has completed. 2025-05-30 09:52:43 - INFO: Flagging Calibration has been activated and calibration will now be flagged 2025-05-30 09:52:43 - INFO: You have chosen to perform a bandpass calculation and calibration 2025-05-30 09:52:43 - WARNING: /home/skywatcher/projects/pyfhd/src/pyfhd/pyfhd_tools/pyfhd_utils.py:709: RuntimeWarning: overflow encountered in divide result[i_use] = 1 / weights[i_use] 2025-05-30 09:52:43 - INFO: You have selected to perform polynomial fits over the frequency band 2025-05-30 09:52:44 - INFO: Applying the calibration 2025-05-30 09:52:44 - INFO: Saving the ratio and sigma average variance 2025-05-30 09:52:44 - INFO: Calculating statistics from calibration 2025-05-30 09:52:44 - INFO: Plotting the calibration solutions into output/pyfhd_1088285600_example/plots/calibration 2025-05-30 09:52:55 - INFO: Visibilities calibrated and cal dictionary with gains created completed in: 15.02258 seconds 2025-05-30 09:52:55 - INFO: Visibilities Weights Updated After Calibration completed in: 50.36974 milliseconds 2025-05-30 09:52:55 - INFO: Noise Calculated and added to obs completed in: 7.34496 milliseconds 2025-05-30 09:52:55 - INFO: Writing the calibrate_checkpoint dict to output/pyfhd_1088285600_example/checkpoints/1088285600_example_calibrate_checkpoint.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:52:56 - INFO: Checkpoint Saved: Calibrated and Flagged visibility parameters, array and weights, the flagged observation metadata dictionary and the calibration dictionary saved into output/pyfhd_1088285600_example/calibrate_checkpoint.h5 2025-05-30 09:52:56 - INFO: Gridding has begun for polarization XX 2025-05-30 09:52:57 - INFO: Gridding visibilities for baseline 2782 of 27825 for polarization XX 2025-05-30 09:52:57 - INFO: Gridding visibilities for baseline 5564 of 27825 for polarization XX 2025-05-30 09:52:58 - INFO: Gridding visibilities for baseline 8346 of 27825 for polarization XX 2025-05-30 09:52:59 - INFO: Gridding visibilities for baseline 11128 of 27825 for polarization XX 2025-05-30 09:52:59 - INFO: Gridding visibilities for baseline 13910 of 27825 for polarization XX 2025-05-30 09:53:00 - INFO: Gridding visibilities for baseline 16692 of 27825 for polarization XX 2025-05-30 09:53:01 - INFO: Gridding visibilities for baseline 19474 of 27825 for polarization XX 2025-05-30 09:53:02 - INFO: Gridding visibilities for baseline 22256 of 27825 for polarization XX 2025-05-30 09:53:03 - INFO: Gridding visibilities for baseline 25038 of 27825 for polarization XX 2025-05-30 09:53:04 - INFO: Gridding visibilities for baseline 27820 of 27825 for polarization XX 2025-05-30 09:53:04 - INFO: Gridding has finished for polarization XX 2025-05-30 09:53:04 - INFO: Gridding has begun for polarization YY 2025-05-30 09:53:05 - INFO: Gridding visibilities for baseline 2782 of 27825 for polarization YY 2025-05-30 09:53:06 - INFO: Gridding visibilities for baseline 5564 of 27825 for polarization YY 2025-05-30 09:53:06 - INFO: Gridding visibilities for baseline 8346 of 27825 for polarization YY 2025-05-30 09:53:07 - INFO: Gridding visibilities for baseline 11128 of 27825 for polarization YY 2025-05-30 09:53:08 - INFO: Gridding visibilities for baseline 13910 of 27825 for polarization YY 2025-05-30 09:53:08 - INFO: Gridding visibilities for baseline 16692 of 27825 for polarization YY 2025-05-30 09:53:09 - INFO: Gridding visibilities for baseline 19474 of 27825 for polarization YY 2025-05-30 09:53:10 - INFO: Gridding visibilities for baseline 22256 of 27825 for polarization YY 2025-05-30 09:53:11 - INFO: Gridding visibilities for baseline 25038 of 27825 for polarization YY 2025-05-30 09:53:13 - INFO: Gridding visibilities for baseline 27820 of 27825 for polarization YY 2025-05-30 09:53:13 - INFO: Gridding has finished for polarization YY 2025-05-30 09:53:13 - INFO: Plotting the continuum gridding outputs into output/pyfhd_1088285600_example/plots/gridding 2025-05-30 09:53:19 - INFO: Writing the gridding_checkpoint dict to output/pyfhd_1088285600_example/checkpoints/1088285600_example_gridding_checkpoint.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:53:25 - INFO: Checkpoint Saved: The Gridded UV Planes saved into output/pyfhd_1088285600_example/gridding_checkpoint.h5 2025-05-30 09:53:25 - INFO: Visibilities gridded completed in: 29.42883 seconds 2025-05-30 09:53:25 - INFO: Saving the obs dictionary to output/pyfhd_1088285600_example/metadata/1088285600_obs.h5 2025-05-30 09:53:25 - INFO: Writing the obs dict to output/pyfhd_1088285600_example/metadata/1088285600_obs.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:53:25 - INFO: Saving params dictionary to output/pyfhd_1088285600_example/metadata/1088285600_params.h5 2025-05-30 09:53:25 - INFO: Writing the params dict to output/pyfhd_1088285600_example/metadata/1088285600_params.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:53:25 - INFO: Saving the gridded uv planes to output/pyfhd_1088285600_example/gridding 2025-05-30 09:53:25 - INFO: Writing the image_uv array to output/pyfhd_1088285600_example/gridding/1088285600_image_uv.h5 2025-05-30 09:53:27 - INFO: Writing the weights_uv array to output/pyfhd_1088285600_example/gridding/1088285600_weights_uv.h5 2025-05-30 09:53:28 - INFO: Writing the variance_uv array to output/pyfhd_1088285600_example/gridding/1088285600_variance_uv.h5 2025-05-30 09:53:29 - INFO: Writing the uniform_filter_uv array to output/pyfhd_1088285600_example/gridding/1088285600_uniform_filter_uv.h5 2025-05-30 09:53:29 - INFO: Writing the model_uv array to output/pyfhd_1088285600_example/gridding/1088285600_model_uv.h5 2025-05-30 09:53:31 - INFO: Saving the calibrated visibilities to output/pyfhd_1088285600_example/visibilities/1088285600_calibrated_vis_arr.h5 2025-05-30 09:53:31 - INFO: Writing the visibilities array to output/pyfhd_1088285600_example/visibilities/1088285600_calibrated_vis_arr.h5 2025-05-30 09:53:31 - INFO: Saving the calibration dictionary to output/pyfhd_1088285600_example/calibration/1088285600_cal.h5 2025-05-30 09:53:31 - INFO: Writing the cal dict to output/pyfhd_1088285600_example/calibration/1088285600_cal.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:53:31 - INFO: Saving the calibrated weights to output/pyfhd_1088285600_example/visibilities/1088285600_calibrated_vis_weights.h5 2025-05-30 09:53:31 - INFO: Writing the weights array to output/pyfhd_1088285600_example/visibilities/1088285600_calibrated_vis_weights.h5 2025-05-30 09:53:34 - INFO: Using filter_uv_uniform for dirty_image_generate 2025-05-30 09:53:34 - INFO: Using filter_uv_uniform for dirty_image_generate 2025-05-30 09:53:36 - INFO: Building the FITS Header for all the FITS files 2025-05-30 09:53:36 - INFO: Saving the FITS files for polarization XX 2025-05-30 09:53:36 - INFO: Plotting the continuum images for polarization XX into output/pyfhd_1088285600_example/plots/images 2025-05-30 09:53:36 - WARNING: /home/skywatcher/projects/pyfhd/.venv/lib/python3.13/site-packages/astropy/wcs/wcs.py:537: FITSFixedWarning: RADECSYS= 'ICRS ' / Reference Frame the RADECSYS keyword is deprecated, use RADESYSa. wcsprm = _wcs.Wcsprm( 2025-05-30 09:53:37 - WARNING: /home/skywatcher/projects/pyfhd/.venv/lib/python3.13/site-packages/astropy/wcs/wcs.py:537: FITSFixedWarning: RADECSYS= 'ICRS ' / Reference Frame the RADECSYS keyword is deprecated, use RADESYSa. wcsprm = _wcs.Wcsprm( 2025-05-30 09:53:38 - WARNING: /home/skywatcher/projects/pyfhd/.venv/lib/python3.13/site-packages/astropy/wcs/wcs.py:537: FITSFixedWarning: RADECSYS= 'ICRS ' / Reference Frame the RADECSYS keyword is deprecated, use RADESYSa. wcsprm = _wcs.Wcsprm( 2025-05-30 09:53:38 - WARNING: /home/skywatcher/projects/pyfhd/.venv/lib/python3.13/site-packages/astropy/wcs/wcs.py:537: FITSFixedWarning: RADECSYS= 'ICRS ' / Reference Frame the RADECSYS keyword is deprecated, use RADESYSa. wcsprm = _wcs.Wcsprm( 2025-05-30 09:53:39 - WARNING: FITS data must be a 2D array, no image made for output/pyfhd_1088285600_example/fits/1088285600_uv_weights_XX.fits. 2025-05-30 09:53:39 - INFO: Saving the FITS files for polarization YY 2025-05-30 09:53:39 - INFO: Plotting the continuum images for polarization YY into output/pyfhd_1088285600_example/plots/images 2025-05-30 09:53:39 - WARNING: /home/skywatcher/projects/pyfhd/.venv/lib/python3.13/site-packages/astropy/wcs/wcs.py:537: FITSFixedWarning: RADECSYS= 'ICRS ' / Reference Frame the RADECSYS keyword is deprecated, use RADESYSa. wcsprm = _wcs.Wcsprm( 2025-05-30 09:53:40 - WARNING: /home/skywatcher/projects/pyfhd/.venv/lib/python3.13/site-packages/astropy/wcs/wcs.py:537: FITSFixedWarning: RADECSYS= 'ICRS ' / Reference Frame the RADECSYS keyword is deprecated, use RADESYSa. wcsprm = _wcs.Wcsprm( 2025-05-30 09:53:41 - WARNING: /home/skywatcher/projects/pyfhd/.venv/lib/python3.13/site-packages/astropy/wcs/wcs.py:537: FITSFixedWarning: RADECSYS= 'ICRS ' / Reference Frame the RADECSYS keyword is deprecated, use RADESYSa. wcsprm = _wcs.Wcsprm( 2025-05-30 09:53:42 - WARNING: /home/skywatcher/projects/pyfhd/.venv/lib/python3.13/site-packages/astropy/wcs/wcs.py:537: FITSFixedWarning: RADECSYS= 'ICRS ' / Reference Frame the RADECSYS keyword is deprecated, use RADESYSa. wcsprm = _wcs.Wcsprm( 2025-05-30 09:53:43 - WARNING: FITS data must be a 2D array, no image made for output/pyfhd_1088285600_example/fits/1088285600_uv_weights_YY.fits. 2025-05-30 09:53:43 - INFO: Loading /home/skywatcher/projects/pyfhd/src/pyfhd/templates/EoR0_high_healpix_inds.h5 into a dictionary 2025-05-30 09:53:44 - WARNING: All data flagged or cut! 2025-05-30 09:53:44 - ERROR: All data has been flagged 2025-05-30 09:53:44 - WARNING: No visibilities gridded for frequency channel [14 15] and polarization XX (0) 2025-05-30 09:53:44 - INFO: Writing the 1088285600_even_XX_dirty_uv_arr_gridded_uvf.h5 dict to output/pyfhd_1088285600_example/healpix/uvf_grid/1088285600_even_XX_dirty_uv_arr_gridded_uvf.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:53:45 - INFO: Writing the 1088285600_even_XX_weights_uv_gridded_uvf.h5 dict to output/pyfhd_1088285600_example/healpix/uvf_grid/1088285600_even_XX_weights_uv_gridded_uvf.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:53:46 - INFO: Writing the 1088285600_even_XX_variance_uv_arr_gridded_uvf.h5 dict to output/pyfhd_1088285600_example/healpix/uvf_grid/1088285600_even_XX_variance_uv_arr_gridded_uvf.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:53:47 - INFO: Writing the 1088285600_even_XX_model_uv_arr_gridded_uvf.h5 dict to output/pyfhd_1088285600_example/healpix/uvf_grid/1088285600_even_XX_model_uv_arr_gridded_uvf.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:53:49 - INFO: Writing the 1088285600_hpx_even_XX dict to output/pyfhd_1088285600_example/healpix/1088285600_hpx_even_XX.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:53:51 - WARNING: All data flagged or cut! 2025-05-30 09:53:51 - ERROR: All data has been flagged 2025-05-30 09:53:51 - WARNING: No visibilities gridded for frequency channel [14 15] and polarization YY (1) 2025-05-30 09:53:51 - INFO: Writing the 1088285600_even_YY_dirty_uv_arr_gridded_uvf.h5 dict to output/pyfhd_1088285600_example/healpix/uvf_grid/1088285600_even_YY_dirty_uv_arr_gridded_uvf.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:53:52 - INFO: Writing the 1088285600_even_YY_weights_uv_gridded_uvf.h5 dict to output/pyfhd_1088285600_example/healpix/uvf_grid/1088285600_even_YY_weights_uv_gridded_uvf.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:53:53 - INFO: Writing the 1088285600_even_YY_variance_uv_arr_gridded_uvf.h5 dict to output/pyfhd_1088285600_example/healpix/uvf_grid/1088285600_even_YY_variance_uv_arr_gridded_uvf.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:53:54 - INFO: Writing the 1088285600_even_YY_model_uv_arr_gridded_uvf.h5 dict to output/pyfhd_1088285600_example/healpix/uvf_grid/1088285600_even_YY_model_uv_arr_gridded_uvf.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:53:55 - INFO: Writing the 1088285600_hpx_even_YY dict to output/pyfhd_1088285600_example/healpix/1088285600_hpx_even_YY.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:53:57 - WARNING: All data flagged or cut! 2025-05-30 09:53:57 - ERROR: All data has been flagged 2025-05-30 09:53:57 - WARNING: No visibilities gridded for frequency channel [14 15] and polarization XX (0) 2025-05-30 09:53:57 - INFO: Writing the 1088285600_odd_XX_dirty_uv_arr_gridded_uvf.h5 dict to output/pyfhd_1088285600_example/healpix/uvf_grid/1088285600_odd_XX_dirty_uv_arr_gridded_uvf.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:53:58 - INFO: Writing the 1088285600_odd_XX_weights_uv_gridded_uvf.h5 dict to output/pyfhd_1088285600_example/healpix/uvf_grid/1088285600_odd_XX_weights_uv_gridded_uvf.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:53:59 - INFO: Writing the 1088285600_odd_XX_variance_uv_arr_gridded_uvf.h5 dict to output/pyfhd_1088285600_example/healpix/uvf_grid/1088285600_odd_XX_variance_uv_arr_gridded_uvf.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:54:00 - INFO: Writing the 1088285600_odd_XX_model_uv_arr_gridded_uvf.h5 dict to output/pyfhd_1088285600_example/healpix/uvf_grid/1088285600_odd_XX_model_uv_arr_gridded_uvf.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:54:02 - INFO: Writing the 1088285600_hpx_odd_XX dict to output/pyfhd_1088285600_example/healpix/1088285600_hpx_odd_XX.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:54:04 - WARNING: All data flagged or cut! 2025-05-30 09:54:04 - ERROR: All data has been flagged 2025-05-30 09:54:04 - WARNING: No visibilities gridded for frequency channel [14 15] and polarization YY (1) 2025-05-30 09:54:04 - INFO: Writing the 1088285600_odd_YY_dirty_uv_arr_gridded_uvf.h5 dict to output/pyfhd_1088285600_example/healpix/uvf_grid/1088285600_odd_YY_dirty_uv_arr_gridded_uvf.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:54:05 - INFO: Writing the 1088285600_odd_YY_weights_uv_gridded_uvf.h5 dict to output/pyfhd_1088285600_example/healpix/uvf_grid/1088285600_odd_YY_weights_uv_gridded_uvf.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:54:06 - INFO: Writing the 1088285600_odd_YY_variance_uv_arr_gridded_uvf.h5 dict to output/pyfhd_1088285600_example/healpix/uvf_grid/1088285600_odd_YY_variance_uv_arr_gridded_uvf.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:54:07 - INFO: Writing the 1088285600_odd_YY_model_uv_arr_gridded_uvf.h5 dict to output/pyfhd_1088285600_example/healpix/uvf_grid/1088285600_odd_YY_model_uv_arr_gridded_uvf.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:54:08 - INFO: Writing the 1088285600_hpx_odd_YY dict to output/pyfhd_1088285600_example/healpix/1088285600_hpx_odd_YY.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:54:09 - INFO: Writing the pyfhd_config dict to output/pyfhd_1088285600_example/config/pyfhd_config.h5, each key will be a dataset, if the key contains a dict then it will be a group. 2025-05-30 09:54:09 - INFO: pyfhd Run Completed for 1088285600 Total Runtime (Days:Hours:Minutes:Seconds.Millseconds): 0:01:33.849671 .. raw:: html
.. code-block:: yaml # Default Arguments for pyfhd # ~ returns None in Python (i.e. NULL) input-path : '/path/to/input/uvfits/1091128160' recalculate-all : false silent : false log-file : true conserve-memory : false instrument : 'mwa' memory-threshold : 100000000 dimension : 2048 elements : 2048 kbinsize : 0.5 FoV : ~ min-baseline : 1. n-pol : 2 deproject-w-term : ~ # Checkpointing save-checkpoints: false obs-checkpoint: ~ calibrate-checkpoint: ~ gridding-checkpoint: ~ # Instrument override-target-phasera: ~ override-target-phasedec: ~ # Beam Setup saved-beam-file-path: /path/to/beams/decomp_beam_pointing0.h5 lazy-load-beam: true recalculate-beam : true beam-clip-floor : true interpolate-kernel : true beam-nfreq-avg : 16 psf-dim: 54 psf-resolution : 100 beam-mask-threshold: 100 beam-model-version : 2 beam-offset-time : 0 beam-per-baseline: false # Calibration calibrate-visibilities : true cable-bandpass-fit : true # Depends on instrument cable length text file cal-bp-transfer : ~ calibration-polyfit : true allow-sidelobe-cal-sources : true cal-amp-degree-fit : 2 cal-phase-degree-fit : 1 cal-reflection-hyperresolve : true cal-reflection-mode-theory : 150 cal-reflection-mode-delay : false cal-reflection-mode-file : false calibration-auto-fit: false calibration-auto-initialize: false cal-gain-init: 1 cal-convergence-threshold: 1e-7 cal-adaptive-calibration-gain: false cal-base-gain: ~ # This is set to None by default to set the default based on cal-adaptive-calibration-gain as per FHD cal-phase-fit-iter: 4 min-cal-baseline : 50. vis-baseline-hist : true bandpass-calibrate : true auto-ratio-calibration: true cal-time-average: false digital-gain-jump-polyfit: false return-cal-visibilities : true calibration-flag-iterate : 0 diffuse-calibrate : ~ calibration-catalog-file-path : ~ # 'GLEAM_v2_plus_rlb2019.sav' (FHD Default) transfer-calibration : ~ cal-stop : true transfer-model-uv : ~ max-cal-iter: 100 # Flagging flag-basic: true flag-freq-start : ~ flag-freq-end : ~ flag-tiles: [] flag-frequencies: false flag-model: true flag-calibration : true flag-calibration-frequencies: false flag-visibilities : false transfer-weights : ~ time-cut: ~ # Gridding recalculate-grid : true image-filter : 'filter_uv_uniform' mask-mirror-indices: false grid-spectral: false grid-weights: true grid-variance: true grid-uniform: false # Deconvolution # deconvolve : false # max-deconvolution-components : 20000 # filter-background : true # smooth-width : 32 dft-threshold : true # return-decon-visibilities : false # deconvolution-filter : 'filter_uv_uniform' # Export output-path : '/path/to/output' export-images : true save-obs: true save-params: true save-cal: true save-visibilities : false save-weights: false save-healpix-fits: false snapshot-healpix-export : false pad-uv-image : 1. ring-radius-multi : 10. description : 1091128160 # Plotting calibration-plots: true gridding-plots: true image-plots: true # Model # Current choices of model-file-type are sav and uvfits model-file-type : 'uvfits' # If you set model-file-type to uvfits, set import-model-uvfits to the # (ideally absolute) path of the fits file # If model-file-type is set to sav then it will look for the sav files as # said in the function import_vis_model_from_sav model-file-path: '/path/to/models/1091128160/puma_LoBES_2s_80kHz_hbeam_1091128160.uvfits' diffuse-model : ~ model-catalog-file-path : ~ # 'GLEAM_v2_plus_rlb2019.sav' (FHD Default) allow-sidelobe-model-sources : false # Simulation # run-simulation : false # in-situ-sim-input : ~ # eor-vis-filepath : ~ # enhance-eor : 1 # sim-noise : ~ # tile-flag-list : ~ # remove-sim-flags : false # HEALPIX ps-kbinsize : 0.5 ps-kspan : 200 ps-beam-threshold: 0 ps-fov: ~ ps-dimension: ~ ps-degpix: ~ ps-nfreq-avg: ~ ps-tile-flag-list: [] n-avg : 2 rephase-weights: True restrict-healpix-inds : true healpix-inds: ~ split-ps-export : true .. raw:: html
.. code-block:: idl PRO convert_model_arr_to_sav,save_dir, obs_id, n_pol ;this is the model visibilities as written out by pyfhd hdf5_filepath = save_dir + "/" + obs_id + "_vis_model.h5" ;load in the hdf5 file print, "Now loading model data from ", hdf5_filepath file_id = H5F_OPEN(hdf5_filepath) ;for as many polarisations as specified by n_pol, write out FHD style .sav ;files pol_names = ['XX', 'YY', 'XY', 'YX'] model_dataset_id = H5D_OPEN(file_id, "vis_model_arr") ;this reads into a struct containing real and imaginary as separate values model_data = H5D_READ(model_dataset_id) ; for pol = 0, 0 do begin for pol = 0, n_pol-1 do begin ;read in this polarisation from the hdf5 file ;things have to be saved inside a pointer array for FHD to load it back ;in correctly vis_model_ptr=PTRARR(1, /allocate) *vis_model_ptr[0] = COMPLEX(model_data.r, model_data.i) print, "Writing model uvfits to .sav file: " + obs_id + "_vis_model_" + pol_names[pol] + ".sav" ;save into the FHD vis_model format and naming convention idl_save = save_dir + "/" + obs_id + "_vis_model_" + pol_names[pol] + ".sav" save, vis_model_ptr, filename = idl_save endfor ;close the hdf5 data struct, done with it now H5D_CLOSE, model_dataset_id ;close file, let's be tidy H5F_CLOSE, file_id END .. raw:: html
.. code-block:: idl PRO convert_beam_to_sav, save_dir, beam_file, obs_file ;this is the model visibilities as written out by pyfhd run beam_filepath = save_dir + "/" + beam_file obs_filepath = save_dir + "/" + obs_file ;load in the hdf5 file print, "Now loading model data from ", beam_filepath file_id = H5F_OPEN(beam_filepath) ;Get all the ints and floats from the hdf5 file beam_mask_threshold = H5D_OPEN(file_id, "beam_mask_threshold") beam_mask_threshold = H5D_READ(beam_mask_threshold) complex_flag = H5D_OPEN(file_id, "complex_flag") complex_flag = (H5D_READ(complex_flag))[0] dim = H5D_OPEN(file_id, "dim") dim = H5D_READ(dim) fbin_i = H5D_OPEN(file_id, "fbin_i") fbin_i = H5D_READ(fbin_i) fnorm = H5D_OPEN(file_id, "freq_norm") fnorm = H5D_READ(fnorm) freq = H5D_OPEN(file_id, "freq") freq = H5D_READ(freq) id = H5D_OPEN(file_id, "id") id = transpose(H5D_READ(id)) interpolate_kernel = H5D_OPEN(file_id, "interpolate_kernel") interpolate_kernel = (H5D_READ(interpolate_kernel))[0] n_freq = H5D_OPEN(file_id, "n_freq") n_freq = (H5D_READ(n_freq))[0] n_pol = H5D_OPEN(file_id, "n_pol") n_pol = (H5D_READ(n_pol))[0] pix_horizon = H5D_OPEN(file_id, "pix_horizon") pix_horizon = H5D_READ(pix_horizon) pnorm = H5D_OPEN(file_id, "pnorm") pnorm = H5D_READ(pnorm) resolution = H5D_OPEN(file_id, "resolution") resolution = H5D_READ(resolution) xvals = H5D_OPEN(file_id, "xvals") xvals = transpose(H5D_READ(xvals)) yvals = H5D_OPEN(file_id, "yvals") yvals = transpose(H5D_READ(yvals)) ; image_info image_info = H5G_OPEN(file_id, "image_info") dec_arr = H5D_OPEN(image_info, "dec_arr") dec_arr = transpose(H5D_READ(dec_arr)) ra_arr = H5D_OPEN(image_info, "ra_arr") ra_arr = transpose(H5D_READ(ra_arr)) psf_image_dim = H5D_OPEN(image_info, "psf_image_dim") psf_image_dim = (H5D_READ(psf_image_dim))[0] psf_image_resolution = H5D_OPEN(image_info, "psf_image_resolution") psf_image_resolution = (H5D_READ(psf_image_resolution))[0] h5g_close, image_info image_info = ptr_new( $ create_struct( $ 'dec_arr', dec_arr,$ 'ra_arr', ra_arr, $ 'psf_image_dim', psf_image_dim, $ 'psf_image_resolution', psf_image_resolution $ ) $ ) beam_gaussian_params_h5 = H5D_OPEN(file_id, "beam_gaussian_params") beam_gaussian_params_h5 = H5D_READ(beam_gaussian_params_h5) beam_gaussian_params_h5 = transpose(beam_gaussian_params_h5) beam_gaussian_params_dims = reverse(size(beam_gaussian_params_h5, /dim)) beam_gaussian_params = PTRARR(beam_gaussian_params_dims[0]) for pol_i = 0, n_pol - 1 do begin beam_gaussian_params[pol_i] = PTR_NEW(beam_gaussian_params_h5[pol_i, *, *]) endfor beam_ptr_h5 = H5D_OPEN(file_id, "beam_ptr") beam_ptr_h5 = H5D_READ(beam_ptr_h5) dims = size(beam_ptr_h5, /dim) beam_ptr = PTR_NEW(PTRARR(n_pol, n_freq, (size(id, /dim))[-1])) for pol_i = 0, n_pol-1 do begin for freq_i = 0, n_freq-1 do begin box_matrix = ptrarr(dims[2], dims[1]) for box_x = 0, dims[1] - 1 do begin for box_y = 0, dims[2] - 1 do begin box_matrix[box_x, box_y] = ptr_new(COMPLEX(beam_ptr_h5[*, box_y, box_x, freq_i, pol_i].r, beam_ptr_h5[*, box_y, box_x, freq_i, pol_i].i)) endfor endfor (*beam_ptr)[pol_i, freq_i, *] = PTR_NEW(box_matrix) endfor endfor psf = create_struct( $ 'beam_mask_threshold', beam_mask_threshold, $ 'beam_ptr', beam_ptr, $ 'beam_gaussian_params', beam_gaussian_params, $ 'complex_flag', complex_flag, $ 'dim', dim, $ 'fbin_i', fbin_i, $ 'fnorm', fnorm, $ 'freq', freq, $ 'id', id, $ 'interpolate_kernel', interpolate_kernel, $ 'n_freq', n_freq, $ 'n_pol', n_pol, $ 'pix_horizon', pix_horizon, $ 'pnorm', pnorm, $ 'resolution', resolution, $ 'xvals', xvals, $ 'yvals', yvals, $ 'image_info', image_info $ ) obs_file_id = H5F_OPEN(obs_filepath) baseline_info_id = H5G_OPEN(obs_file_id, "baseline_info") ; dataset /baseline_info/bin_offset H5T_INTEGER [2] bin_offset = H5D_OPEN(baseline_info_id, "bin_offset") bin_offset = H5D_READ(bin_offset) ; dataset /baseline_info/fbin_i H5T_INTEGER [16] fbin_i = H5D_OPEN(baseline_info_id, "fbin_i") fbin_i = H5D_READ(fbin_i) ; dataset /baseline_info/freq H5T_FLOAT [16] freq = H5D_OPEN(baseline_info_id, "freq") freq = H5D_READ(freq) ; dataset /baseline_info/freq_use H5T_INTEGER [16] freq_use = H5D_OPEN(baseline_info_id, "freq_use") freq_use = H5D_READ(freq_use) ; dataset /baseline_info/jdate H5T_FLOAT [2] jdate = H5D_OPEN(baseline_info_id, "jdate") jdate = H5D_READ(jdate) ; dataset /baseline_info/tile_a H5T_INTEGER [16002] tile_a = H5D_OPEN(baseline_info_id, "tile_a") tile_a = H5D_READ(tile_a) ; dataset /baseline_info/tile_b H5T_INTEGER [16002] tile_b = H5D_OPEN(baseline_info_id, "tile_b") tile_b = H5D_READ(tile_b) ; dataset /baseline_info/tile_flag H5T_INTEGER [128] tile_flag = H5D_OPEN(baseline_info_id, "tile_flag") tile_flag = H5D_READ(tile_flag) ; dataset /baseline_info/tile_height H5T_FLOAT [128] tile_height = H5D_OPEN(baseline_info_id, "tile_height") tile_height = H5D_READ(tile_height) ; dataset /baseline_info/tile_names H5T_INTEGER [128] tile_names = H5D_OPEN(baseline_info_id, "tile_names") tile_names = H5D_READ(tile_names) ; dataset /baseline_info/tile_use H5T_INTEGER [128] tile_use = H5D_OPEN(baseline_info_id, "tile_use") tile_use = H5D_READ(tile_use) ; dataset /baseline_info/time_use H5T_INTEGER [2] time_use = H5D_OPEN(baseline_info_id, "time_use") time_use = H5D_READ(time_use) baseline_info = create_struct( $ 'bin_offset', bin_offset, $ 'fbin_i', fbin_i, $ 'freq', freq, $ 'freq_use', freq_use, $ 'jdate', jdate, $ 'tile_a', tile_a, $ 'tile_b', tile_b, $ 'tile_flag', tile_flag, $ 'tile_height', tile_height, $ 'tile_names', tile_names, $ 'tile_use', tile_use, $ 'time_use', time_use $ ) H5G_CLOSE, baseline_info_id n_baselines = H5D_OPEN(obs_file_id, "n_baselines") n_baselines = (H5D_READ(n_baselines))[0] n_pol = H5D_OPEN(obs_file_id, "n_pol") n_pol = (H5D_READ(n_pol))[0] baseline_info = ptr_new(baseline_info) obs = create_struct( $ 'baseline_info', baseline_info, $ 'nbaselines', n_baselines, $ 'n_pol', n_pol, $ 'primary_beam_area', ptrarr(4),$ 'primary_beam_sq_area', ptrarr(4) $ ) save, psf, obs, filename = save_dir + "/gauss_beam_pointing0_167635008Hz.sav" ;close the hdf5 file H5F_CLOSE, file_id H5F_CLOSE, obs_file_id END .. raw:: html