LibreOffice is laggy/slow when GPU is used for traning machine learning models

Hi, I am wondering if there is any way to disable the use of Libreoffice on GPU so that it can stop being laggy the the GPU is in use heavily, such as training machine learning models.

My host is ubuntu 20.04 with XFCE desktop environment and Libreoffice is on 7.2.5.2. My GPU is Nvdia rtx 3090 which has plenty of memory.

I have also observed that applications based on GTK/Gnome/Cairo for rending GUI will become slow whenever the GPU is used heavily by other applications (link).

But if I remote in to my host with x2go client with XFCE desktop environment, everything is smooth without any problems. This is something I cannot explain at all.

Any help would be greatly appreciated.