"Function MEMORY is not available on this platform."

43 visualizaciones (últimos 30 días)
alpedhuez
alpedhuez el 26 de Jul. de 2020
Comentada: Walter Roberson el 25 de Mayo de 2023
I followed
and ran a command memory but got the following outcome
>> memory
Error using memory
Function MEMORY is not available on this platform.
What is going on?

Respuesta aceptada

Steven Lord
Steven Lord el 26 de Jul. de 2020
As stated in the Limitations section on the documentation page for the memory function, this function is only supported on Microsoft Windows systems.
  3 comentarios
Geoff May
Geoff May el 25 de Mayo de 2023
Not sure if the functionality is identical, but the following call to java will give you a number that matches up with the Java heap memory that is set in preferences:
runtime = javaMethod('getRuntime', 'java.lang.Runtime');
maxMemory = javaMethod('maxMemory', runtime);
Walter Roberson
Walter Roberson el 25 de Mayo de 2023
If I recall, on Linux you would want to first find your process ID, and then example the /proc file system entry for that process, as that can tell you how much memory the process is using.

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Startup and Shutdown en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by