Hi Andre!
I understand that you are encountering an error while trying to load a model using the MATLAB Engine for Python. The error is related to the Qt package, which is commonly used for creating graphical user interfaces. It seems that the system you are working on is attempting to use certain features of the Qt package and is trying to draw on the screen.
On Linux, the QT_QPA_PLATFORM environment variable is set to 'xcb' by default. This environment variable forces Qt applications to use the 'xcb' QPA platform plugin and if Qt does not have this plugin, then the application just does not start and instead throws an error 'This application failed to start because it could not find or load the Qt platform plugin and reinstalling application might solve the issue'.
To address the problem, you can implement the following approaches.
- You can try installing the relevant modules specified in the Qt for X11 requirements using the following command.
sudo apt-get install '^libxcb.*-dev' libx11-xcb-dev libglu1-mesa-dev libxrender-dev libxi-dev libxkbcommon-devlibxkbcommon-x11-dev
- You can set the QT_QPA_PLATFORM environment variable to 'offscreen'. This will run your program in headless mode, meaning fit will not require a screen.This can be helpful if you do not need any graphical output and just want to run the program in a non-interactive mode.
Hope this helps.
Regards
Dinesh Gatla