The diagnostic of poloidal magnetic field ( ) in field-reversed configuration (FRC), promising for achieving efficient plasma confinement due to its high β, is a huge challenge because is small and reverses around the core region. The laser-driven ion-beam trace probe (LITP) has been proven to diagnose the profile in FRCs recently, whereas the existing iterative reconstruction approach cannot handle the measurement errors well. In this work, the machine learning approach, a fast-growing and powerful technology in automation and control, is applied to reconstruction in FRCs based on LITP principles and it has a better performance than the previous approach. The machine learning approach achieves a more accurate reconstruction of profile when 20% detector errors are considered, 15% fluctuation is introduced and the size of the detector is remarkably reduced. Therefore, machine learning could be a powerful support for LITP diagnosis of the magnetic field in magnetic confinement fusion devices.