How to measure parfeval() execution time?

Respuestas (1)

Edric Ellis
Edric Ellis el 22 de Nov. de 2018
A parallel.Future instance has StartDateTime and FinishDateTime properties - you can subtract these to get an idea of the execution time. (I wouldn't count on this being terribly precise - it depends what you want the information for). For example
parpool('local', 1);
f = parfeval(@pause, 0, pi);
wait(f);
dur = f.FinishDateTime - f.StartDateTime
durSeconds = seconds(dur)

Categorías

Más información sobre Startup and Shutdown en Centro de ayuda y File Exchange.

Productos

Versión

R2018b

Etiquetas

Preguntada:

el 21 de Nov. de 2018

Respondida:

el 22 de Nov. de 2018

Community Treasure Hunt

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

Start Hunting!

Translated by