<div dir="ltr">Anil,<div><br></div><div>Perhaps it's not the accuracy of the measurement but what is being measured. IIRC getrusage() measures the CPU time, not the wall clock time. And there are issues about what CPU time: user vs. system, all threads in a process vs. just the calling thread.</div><div><br></div><div>-Steve</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jan 18, 2017 at 12:33 PM, Stefan Vigerske <span dir="ltr"><<a href="mailto:stefan@math.hu-berlin.de" target="_blank">stefan@math.hu-berlin.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Ipopt uses some standard functions (getrusage()) to measure CPU time, see IpUtils.cpp. I don't think that there is a more accurate measurement of time than that. I don't know the mex interface, but unless it does not just pass on the time measurement from Ipopt, there is little one could improve, I believe.<span class=""><br>
<br>
On 01/17/2017 09:41 PM, Anil Rao wrote:<br>
</span><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">
I would like to know how to get the most accurate CPU time from Ipopt. I am running a large set of jobs and I need the CPU time from each job. I am using the MATLAB mex files compiled by Enrico Bertolazzi for my runs. I am finding that Ipopt does not seem to provide accurate CPU times using the CPU time output from the mex interface. I am grateful if somebody might be able to help me get an accurate execution time. Thanks for your help.<br>
<br>
Regards,<br>
<br>
Anil<br>
<br>
Sent from my iPhone. Please excuse any typos.<br>
<br>
Anil V. Rao, PhD<br>
Gainesville, FL 32607<br>
Tel: <a href="tel:352-672-1529" value="+13526721529" target="_blank">352-672-1529</a> (cell)<br>
Email: <a href="mailto:anilvrao@gmail.com" target="_blank">anilvrao@gmail.com</a><br></span>
Website: <a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__www.anilvrao.com&d=CwICAg&c=Ngd-ta5yRYsqeUsEDgxhcqsYYY1Xs5ogLxWPA_2Wlc4&r=k6EmmdGW84SCN3wW0TxH6Q&m=iJiciJVGLZOLnDOB9fpIdMt1CykjYBE9RqjgMSI4BtU&s=vie-1qOE5fCRo0_EkTVVsZ9ufzczk6FR_KRmR6ogNSI&e=" rel="noreferrer" target="_blank">https://urldefense.proofpoint.<wbr>com/v2/url?u=http-3A__www.anil<wbr>vrao.com&d=CwICAg&c=Ngd-ta5yRY<wbr>sqeUsEDgxhcqsYYY1Xs5ogLxWPA_<wbr>2Wlc4&r=k6EmmdGW84SCN3wW0TxH6Q<wbr>&m=iJiciJVGLZOLnDOB9fpIdMt1Cyk<wbr>jYBE9RqjgMSI4BtU&s=vie-1qOE5fC<wbr>Ro0_EkTVVsZ9ufzczk6FR_KRmR6ogN<wbr>SI&e=</a> <br>
<br>
<br>
______________________________<wbr>_________________<br>
Ipopt mailing list<br>
<a href="mailto:Ipopt@list.coin-or.org" target="_blank">Ipopt@list.coin-or.org</a><br>
<a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__list.coin-2Dor.org_mailman_listinfo_ipopt&d=CwICAg&c=Ngd-ta5yRYsqeUsEDgxhcqsYYY1Xs5ogLxWPA_2Wlc4&r=k6EmmdGW84SCN3wW0TxH6Q&m=iJiciJVGLZOLnDOB9fpIdMt1CykjYBE9RqjgMSI4BtU&s=CZlfaro4GqPHlNpufQoIbhMFN-T7rcmV2IUKrIJ79G4&e=" rel="noreferrer" target="_blank">https://urldefense.proofpoint.<wbr>com/v2/url?u=http-3A__list.coi<wbr>n-2Dor.org_mailman_listinfo_<wbr>ipopt&d=CwICAg&c=Ngd-ta5yRYsqe<wbr>UsEDgxhcqsYYY1Xs5ogLxWPA_<wbr>2Wlc4&r=k6EmmdGW84SCN3wW0TxH6Q<wbr>&m=iJiciJVGLZOLnDOB9fpIdMt1Cyk<wbr>jYBE9RqjgMSI4BtU&s=CZlfaro4GqP<wbr>HlNpufQoIbhMFN-T7rcmV2IUKrIJ79<wbr>G4&e=</a> <br><span class="HOEnZb"><font color="#888888">
</font></span></blockquote><span class="HOEnZb"><font color="#888888">
<br>
<br>
-- <br>
<a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__www.gams.com_-7Estefan&d=CwICAg&c=Ngd-ta5yRYsqeUsEDgxhcqsYYY1Xs5ogLxWPA_2Wlc4&r=k6EmmdGW84SCN3wW0TxH6Q&m=iJiciJVGLZOLnDOB9fpIdMt1CykjYBE9RqjgMSI4BtU&s=fEOXrNh7rH1657UouMXdLBnFi8wyfu6lMpFCiYOlnDU&e=" rel="noreferrer" target="_blank">https://urldefense.proofpoint.<wbr>com/v2/url?u=http-3A__www.gams<wbr>.com_-7Estefan&d=CwICAg&c=Ngd-<wbr>ta5yRYsqeUsEDgxhcqsYYY1Xs5ogLx<wbr>WPA_2Wlc4&r=k6EmmdGW84SCN3wW0T<wbr>xH6Q&m=iJiciJVGLZOLnDOB9fpIdMt<wbr>1CykjYBE9RqjgMSI4BtU&s=fEOXrNh<wbr>7rH1657UouMXdLBnFi8wyfu6lMpFCi<wbr>YOlnDU&e=</a> ______________________________<wbr>_________________<br>
Ipopt mailing list<br>
<a href="mailto:Ipopt@list.coin-or.org" target="_blank">Ipopt@list.coin-or.org</a><br>
<a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__list.coin-2Dor.org_mailman_listinfo_ipopt&d=CwICAg&c=Ngd-ta5yRYsqeUsEDgxhcqsYYY1Xs5ogLxWPA_2Wlc4&r=k6EmmdGW84SCN3wW0TxH6Q&m=iJiciJVGLZOLnDOB9fpIdMt1CykjYBE9RqjgMSI4BtU&s=CZlfaro4GqPHlNpufQoIbhMFN-T7rcmV2IUKrIJ79G4&e=" rel="noreferrer" target="_blank">https://urldefense.proofpoint.<wbr>com/v2/url?u=http-3A__list.coi<wbr>n-2Dor.org_mailman_listinfo_<wbr>ipopt&d=CwICAg&c=Ngd-ta5yRYsqe<wbr>UsEDgxhcqsYYY1Xs5ogLxWPA_<wbr>2Wlc4&r=k6EmmdGW84SCN3wW0TxH6Q<wbr>&m=iJiciJVGLZOLnDOB9fpIdMt1Cyk<wbr>jYBE9RqjgMSI4BtU&s=CZlfaro4GqP<wbr>HlNpufQoIbhMFN-T7rcmV2IUKrIJ79<wbr>G4&e=</a> </font></span></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">Steven Dirkse, Ph.D.<br>GAMS Development Corp., Washington DC<br>Voice: (202)342-0180 Fax: (202)342-0181<br><a href="mailto:sdirkse@gams.com" target="_blank">sdirkse@gams.com</a> <br><a href="http://www.gams.com" target="_blank">http://www.gams.com</a></div>
</div>