V5+ autopilot cannot hover using optical flow

hi,The PX4 firmware version I use is V1.12.1 ,Flight control is V5+ autopilot,The function I want to achieve is to use optical flow only as the data source of EKF2 to achieve hovering without GPS。Oddly enough, when I tested it, it didn’t seem to work at all, losing position information after taking off for a while.
Below is the log of my flight: