Get from Ico-github-logo

Highlights from
matlab-ParforProgress2

  • ParforProgressStarter2(s,...
    Starter function for parfor progress-monitor, that will automatically
  • ParforProgressStressTest2...
    Stress test for 'ParforProgressStarter2'. In case of timeouts, you can
  • get_matlab_version()
    EOF
  • pool_size()
    POOL_SIZE - temporary hack to return size of current MATLABPOOL / PARPOOL
  • print_error_red(msg, tab_...
    show error in red
  • ParforProgress2
  • ParforProgressConsole2
    do NOT use this object by itself!
  • View all files

4.55556

4.6 | 10 ratings Rate this file 25 Downloads (last 30 days) File Size: 24.7 KB File ID: #35609
image thumbnail

matlab-ParforProgress2

by

 

13 Mar 2012 (Updated )

A PARFOR progress monitor for Matlab GUIs and the command line (works with normal for-loops)

| Watch this File

File Information
Description

This progress monitor comes with a nice wrapper `ParforProgressStarter2.m` which will take care of adding the classes to the java class path, depending on whether matlabpool is enabled or not.
For instructions on how to use with global variables, please see https://github.com/kotowicz/matlab-ParforProgress2#c2-with-globals
You can fork the code @ https://github.com/kotowicz/matlab-ParforProgress2

Acknowledgements

This file inspired Improved Digital Image Correlation (Dic).

Required Products MATLAB
MATLAB release MATLAB 7.6 (R2008a)
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (16)
27 Oct 2014 Elizabeth Jones

I have been using your parfor progress bar for a couple of years, and it's been working great. I recently upgraded from R2012b to R2014b, and I was so glad to see that you had already updated the progress bar! It made switching all my code to the newest version of Matlab so much easier. Thanks!

28 Jul 2014 Rudi

Andreas, thanks for the update, seems to work. I now have another more difficult question: do you have any idea how I might use your code, or something similar, within a mexed parfor loop (mexed to C++ with OpenMP)? I tried using coder.extrinsic for your functions, but apparently calls to extrinsic functions inside mexed parfor loops are unsupported...

09 Jul 2014 Andreas

@Rudi: please use version 0.2.7 with Matlab 2014a.

27 Jun 2014 Rudi

I have used this great tool for some time but it appears to not work in 2014a with the following error. Works on same exact code in 2013b. Please update, this is the nicest parfor progress meter I have found!

Warning: While loading an object of class 'ParforProgress2': Undefined variable "ParforProgressClient2" or class "ParforProgressClient2.createClient".
Warning: The following error was caught while executing 'ParforProgress2' class destructor:
Attempt to reference field of non-structure array.
Error using ParforProgress2/increment (line 121)
Attempt to reference field of non-structure array.

03 Jun 2014 Hassan Naseri  
03 Jun 2014 Hassan Naseri

Nice tool. But it clears my global variables !!

28 Jan 2014 Christophe Trefois  
18 Nov 2013 Jerome

@Andreas: Thanks for looking into this.
Are you sure it does not clear globals?
I see that you added a "server_class_loaded" boolean to make sure that javaaddpath is only called once but I discovered the clear global was due to the first call to javaaddpath.
Since you need to do that call, it seems like global will be cleared then, correct?

24 Oct 2013 Andreas

@Jerome: please try the v0.2 release, which should appear shortly here and is also available on github:
https://github.com/kotowicz/matlab-ParforProgress2/archive/v0.2.zip

23 Oct 2013 Jerome

Do you have any idea why this clear all global variables?
Without this waitbar my globals stay fine.

28 Aug 2013 Adam

Does anyone know why this progress monitor would conflict with the Matlab 2013 unit testing framework? I have a test covering a function that uses it - when I create the test instance on its own I can run it fine. When I run it within a test suite though it appears to run fine first time, but then if I run the tests a second time I get a segmentation dump when it tries to build the test suite (this does not happen if I remove the progress monitor). It also seems to work fine when used with the older xUnit framework from Matlab Central.

I like it in general though.

09 Apr 2013 Jens  
20 Dec 2012 Bart Boesman

Thanks for this file, works perfect!

Regards,

Bart

16 Oct 2012 Eduard

FYI, I did the changes to ParforProgress2 myself and it actually works perfectly.

Only pit I fell into was compiling the Java code with JDK 7 instead of JDK 6 first, therefore not beeing compatible to MATLAB R20012a's integrated JRE 6.

15 Oct 2012 Eduard

Hi Andreas,

two questions:

1 - Could you add a possibility to "break" the parfor-loop from within ParforProgress2? I was thinking about something quite simple like polling for the existence of a file at the start of the parfor-loop and just "continue" when it exists. The file could be created by ParforProgress2 as soon as the progress window is closed replacing the current warning message (or even add a cancel-button to it).
Probably you can come up with an even better solution yourself!

2 - It would be nice if the output "execution time was XXXs." would only be displayed if do_debug=1, so bascally no output at all is produced when do_debug=0.

Regards
Eduard

02 Oct 2012 Matt Smith  
Updates
13 Mar 2012

more detailed description of program added.

24 Mar 2012

added missing functions.

24 Mar 2012

rewrite awt and java checks in 'ParforProgressStarter2'
basic support for non-GUI output in 'ParforProgressServer2.java':
 - works fine if matlabpool == 0
 - no output if matlabpool == 1

03 Apr 2012

show runtime & eta in console non-worker mode.
little fixes & improvements.

03 Apr 2012

ETA & running time update now works with parfor loops on the console.

18 Mar 2013

updated version fixes matlab 2013a problem.

24 Oct 2013

v0.2 Does not clear global variables anymore.

14 Nov 2013

Updated docs to reflect replacement of 'matlabpool' by 'parpool' in R2013b.

14 Jan 2014

added workaround and instructions for use with global variables. See https://github.com/kotowicz/matlab-ParforProgress2#c2-with-globals

05 Feb 2014

documentation update regarding usage of global variables.

22 Apr 2014

registered download link with GitHub

09 Jul 2014

Version 0.2.7 fixes problems with Matlab 2014a.

12 Jul 2014

Version 0.2.8 gives the user the option enable / disable the display of the execution time.

Contact us