Clear Filters
Clear Filters

MATLAB coder has been running for a week

4 views (last 30 days)
I started running the MATLAB coder to convert a function to a MEX function a week ago. (At this point, it has been running 166 hours). It is on the first step - Automatically defining the input types.
The main input is a large data structure which is about 34 Gb. Running R2021b with 192 Gb of ram, and it seems to be using just over half of the available memory (102 Gb)
Does this seem reasonable that it should be running this long, or is it a sign that something is hung up?

Accepted Answer

Hassaan
Hassaan on 8 Apr 2024
Edited: Hassaan on 10 Apr 2024
It is highly unusual for MATLAB Coder to take this long in the type inference stage. This extended processing time is not normal and suggests that the process may be stuck. It is advisable to terminate the current process. Consider breaking down the task into smaller, more manageable parts if possible. Analyzing or converting smaller portions of the data or simplifying the data structure might help identify specific issues causing the delay.
Given the complexity of the issue, contacting MathWorks support directly could provide specific insights or solutions tailored to handling large data structures with MATLAB Coder.
Ensure the function and data structure are as optimized as possible before conversion. Simplifying the data structure or reducing its size, if feasible, might make the type inference process more manageable.
-----------------------------------------------------------------------------------------------------------------------------------------------------
If you find the solution helpful and it resolves your issue, it would be greatly appreciated if you could accept the answer. Also, leaving an upvote and a comment are also wonderful ways to provide feedback.
It's important to note that the advice and code are based on limited information and meant for educational purposes. Users should verify and adapt the code to their specific needs, ensuring compatibility and adherence to ethical standards.
Professional Interests
  • Technical Services and Consulting
  • Embedded Systems | Firmware Developement | Simulations
  • Electrical and Electronics Engineering
Feel free to contact me.

More Answers (0)

Categories

Find more on MATLAB Coder in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!