Matlab is unpredictably slow
16 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Like many other users, I have experienced my code (on occasion) running TEN times slower than it normally does. I have read a fair number of posts about JIT and PCode but cannot determine if this is my problem since I can't reliably reproduce the slow execution! It's a bit maddening. After experiencing the slow performance, I rerun the code & it runs MUCH faster. In order to try & reproduce the slow performance, I tried "clear all" and even restarted Matlab... to no avail! The code runs fine for a while until.... at some point in the future... it becomes slow as molasses again.
Any ideas of how I can reliably reproduce the slow performance so I can attack it? I can't post my code but I should say that it is both memory and disk intensive.
Thanks!
Dan
2 comentarios
Stephen23
el 10 de Jun. de 2016
Editada: Stephen23
el 11 de Jun. de 2016
"Like many other users"
Really, which "many other" users? Can you provide a reference for this?
I know of many cases where MATLAB is predictably slow due to poor code practices or a busy CPU/memory, but I have never heard of "many other users" suffering from unpredictably slow code.
John D'Errico
el 10 de Jun. de 2016
Don't go off and use a web browser when you are running MATLAB. Don't have other stuff running in the background. Even if your machine is has multiple cores, this cuts MATLAB's access to the CPUs that it needs.
Don't try to solve too big problems. If you solve marginally large problems, then SOMETIMES you will force MATLAB to use swap space heavily. That causes the code to wait will your disk thrashes. Disk access is far slower than RAM access.
There are other reasons why it MIGHT be slow, many of them a direct function of what you are doing, your problem etc. Since we don't know what you are doing, we cannot guess why you have issues. The crystal ball is so foggy. I bought some crystal ball anti-fogging fluid from an online retailer though, so that may help.
Respuestas (1)
Ver también
Categorías
Más información sobre Install Products en Help Center y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!