You have missed the major problem of stock camera i.e bokeh effect is getting somewhere else in portrait mode and slow motion problem + gcam Autofocus issue.
android pie on mi a1 is full of bugs and You are providing solutions like factory reset and reboot for most of the problems which is not a solution. #xiaomidontcare