bugGNU Octave - Bugs: bug #58509, [octave forge] (parallel)...

 
 

bug #58509: [octave forge] (parallel) pararrayfun has a problem with functions

Submitted by:  richard <r1chard>
Submitted on:  Sat 06 Jun 2020 02:09:07 PM UTC  
 
Category:  Octave Forge Package Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Unexpected Error
Status:  Wont Fix Assigned to:  None
Originator Name:  Open/Closed:  Open
Release:  5.2.0 Operating System:  GNU/Linux

Add a New Comment (Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Mon 08 Jun 2020 09:21:17 AM UTC, comment #3: 

Bummer.
The good news is that it's confirmed as a bug.

Just FYI, pararayfun was introduced to assist the earlier development or the application. It's not particularly heplpful now, but it does, or did help when optimisations scripts were run to identify errors in some variables.

I read in the discussion that "threadsafe" and commandline "defined functions" are incompatible. Have I understood that correctly? 

richard <r1chard>
Sun 07 Jun 2020 11:30:02 AM UTC, comment #2: 

Yes, functions defined with 'function ... endfunction' on the commandline won't work with the newly implemented parcellfun and pararrayfun. This should probably be explicitly mentioned in the docs and in the NEWS file. It is one of the prices of making these functions safe with threaded Octave sessions, sorry.

Olaf Till <i7tiol>
Project Member
Sat 06 Jun 2020 06:40:56 PM UTC, comment #1: 

The attached file is a script with local functions (command-line functions) defined in it. It's likely this is the problem, because these functions are ephemeral and aren't recognized when pararrayfun or parcellfun creates new instances of octave to run tasks.

Mike Miller <mtmiller>
Project Administrator
Sat 06 Jun 2020 02:09:07 PM UTC, original submission:  

I'll attach a file, one of a series, and last run perhaps six months ago.

The calculation thas three options. The one I usually run uses pararrayfun, and a fallback is a manual choice to use arrayfun.

The option using arrayfun still works, and the commands are quite similar. When I use pararrayfun I get this message:

error: 'main_loop' undefined near line 1 column 6
error: 'main_loop' undefined near line 1 column 6
error: 'main_loop' undefined near line 1 column 6
error: 'main_loop' undefined near line 1 column 6
error: 'postprocess' undefined near line 1 column 15
error: 'postprocess' undefined near line 1 column 15
error: 'postprocess' undefined near line 1 column 15
error: 'postprocess' undefined near line 1 column 15
error: XX(_,10): but XX has size 1x1
error: called from
    newyork235>@<anonymous> at line 322 column 20
    newyork235 at line 322 column 3

Both 'main_loop' and 'postprocess' are functions.

I had a look to see if something obvious has changed in the latest version of Octave, but no luck.

The arrayfun calculation still works hence I think this is a bug.

richard <r1chard>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #49220:  newyork235.m added by r1chard (18KiB - text/x-objcsrc)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by i7tiol (Posted a comment)
  • -email is unavailable- added by r1chard (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

     

     

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2020-06-07 i7tiol StatusNone => Wont Fix
    2020-06-06 mtmiller CategoryOctave Function => Octave Forge Package
        Summarypararrayfun has a problem with functions => [octave forge] (parallel) pararrayfun has a problem with functions
    2020-06-06 r1chard Attached File- => Added newyork235.m, #49220

    Back to the top


    Powered by Savane 3.5