Generate plots inside docker container

조회 수: 5 (최근 30일)
Petter Cedell
Petter Cedell 2022년 1월 18일
편집: Suman 2025년 6월 20일
Hi all,
I'm having some issues generating plots inside a docker container, I'm using a Matlab docker image from 2020b.
I have created a dummy function that generates an invisible plot from a JSON file, which is saved into the current directory and is working fine outside the docker environment. I have then packed the function as a stand-alone application using the Application compiler (result_json_png.exe), entailing I'm only executing the executable inside the container.
However, when I'm trying to generate it inside the container it throws back Error 126, "Unable to load bundle mwosgserver_bultinmpl.dll, Error: 126: not connected. And I'm assuming that it can't render the figure using OpenGL inside the container.
I don't know if there is a solution for this, is it possible to configure the runtime using "painter" in the startup.m file (does it even exist in the runtime)? Is there some setting you can apply as an additional parameter that is passed to the MCC?
Best,
  댓글 수: 1
Suman
Suman 2025년 6월 20일
편집: Suman 2025년 6월 20일
You can use 'painters' in the very beginning of the MATLAB function that plots the figure.
>> set(0, 'DefaultFigureRenderer', 'painters');

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

Help CenterFile Exchange에서 C Shared Library Integration에 대해 자세히 알아보기

제품


릴리스

R2020b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by