Problem with fminunc.m

View: New views
3 Messages — Rating Filter:   Alert me  

Problem with fminunc.m

by Philippe Lavoie :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Some parts of this message have been removed. Learn more about Nabble's security policy.

Hi

 

I'm using a MatLab library to help me with computer vision (http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=4576&objectType=file). With version 3.0.5, I didn't have any problems with the torr_test_calib method whereas with 3.2.0 it gives me the following result (with some unary operators not implemented).

 

> torr_test_calib_sc

focal_length =  2.4450

error before non-linear minimization

ans =  14.823

warning: list objects are deprecated; use cell arrays instead

warning: struct_contains is obsolete and will be removed from a future version of Octave; please use isfield instead

warning: is_list is obsolete and will be removed from a future version of Octave; please use islist instead

minimize(): Using 'nelder_mead_min' as back-end

error: unary operator `'' not implemented for `list' operands

error: binary operator `*' not implemented for `matrix' by `<unknown type>' operations

error: called from:

error:   C:\Octave\3.2.0_gcc-4.3.0\share\octave\packages\optim-1.0.6\nelder_mead_min.m at line 153, column 3

error:   C:\Octave\3.2.0_gcc-4.3.0\share\octave\packages\optim-1.0.6\minimize.m at line 290, column 16

error:   C:\Octave\3.2.0_gcc-4.3.0\share\octave\packages\optim-1.0.6\fminunc.m at line 141, column 15

error:   d:\projects\CActusCommerce\Video\MatLab\Torr\torr_nonlinG.m at line 16, column 3

error:   d:\projects\CActusCommerce\Video\MatLab\Torr\torr_test_calib_sc.m at line 62, column 8

octave-3.2.0.exe:2:d:\projects\CActusCommerce\Video\MatLab\Torr

 

Can someone please help regarding this?

 

Thanks

 

Phil



Confidentiality Message

This e-mail and its content is confidential: its privileged information is intended for the exclusive use of the addressee. Any other person is strictly prohibited from disclosing, distributing or reproducing it. If the addressee cannot be reached or is unknown to you, please inform the sender by return e-mail immediately and delete this e-mail message and destroy all copies.

Avis de confidentialité

Le présent courriel et son contenu est confidentiel: l'information privilégiée est à l'usage exclusif du destinataire ci-dessus. Toute autre personne est par les présentes avisée qu'il lui est strictement interdit de le diffuser, le distribuer ou le reproduire. Si le destinataire ne peut être joint ou vous est inconnu, veuillez informer l'expéditeur par courrier électronique immédiatement et détruire ce message et toute copie de celui-ci.

------------------------------------------------------------------------------
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensing option that enables unlimited
royalty-free distribution of the report engine for externally facing
server and web deployment.
http://p.sf.net/sfu/businessobjects
_______________________________________________
Octave-dev mailing list
Octave-dev@...
https://lists.sourceforge.net/lists/listinfo/octave-dev

Re: Problem with fminunc.m

by Jaroslav Hajek-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Wed, Jun 17, 2009 at 5:40 PM, Philippe
Lavoie<philippe.lavoie@...> wrote:

> Hi
>
>
>
> I'm using a MatLab library to help me with computer vision
> (http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=4576&objectType=file).
> With version 3.0.5, I didn't have any problems with the torr_test_calib
> method whereas with 3.2.0 it gives me the following result (with some unary
> operators not implemented).
>
>
>
>> torr_test_calib_sc
>
> focal_length =  2.4450
>
> error before non-linear minimization
>
> ans =  14.823
>
> warning: list objects are deprecated; use cell arrays instead
>
> warning: struct_contains is obsolete and will be removed from a future
> version of Octave; please use isfield instead
>
> warning: is_list is obsolete and will be removed from a future version of
> Octave; please use islist instead
>
> minimize(): Using 'nelder_mead_min' as back-end
>
> error: unary operator `'' not implemented for `list' operands
>
> error: binary operator `*' not implemented for `matrix' by `<unknown type>'
> operations
>
> error: called from:
>
> error:
> C:\Octave\3.2.0_gcc-4.3.0\share\octave\packages\optim-1.0.6\nelder_mead_min.m
> at line 153, column 3
>
> error:
> C:\Octave\3.2.0_gcc-4.3.0\share\octave\packages\optim-1.0.6\minimize.m at
> line 290, column 16
>
> error:
>   C:\Octave\3.2.0_gcc-4.3.0\share\octave\packages\optim-1.0.6\fminunc.m at
> line 141, column 15
>
> error:   d:\projects\CActusCommerce\Video\MatLab\Torr\torr_nonlinG.m at line
> 16, column 3
>
> error:   d:\projects\CActusCommerce\Video\MatLab\Torr\torr_test_calib_sc.m
> at line 62, column 8
>
> octave-3.2.0.exe:2:d:\projects\CActusCommerce\Video\MatLab\Torr
>
>
>
> Can someone please help regarding this?
>
>
>
> Thanks
>
>
>
> Phil
>

With the core fminunc (no package), it seems to work for me if I alter
the fminunc call int torr_nonlinG.m to the modern-style call:
g = fminunc(@(g) torr_errg_sse (g,nx1,ny1,nx2,ny2,m3,C), g_init);

Note that neither "Display" nor "Diagnostics" options are currently recognized.

best,

--
RNDr. Jaroslav Hajek
computing expert & GNU Octave developer
Aeronautical Research and Test Institute (VZLU)
Prague, Czech Republic
url: www.highegg.matfyz.cz

------------------------------------------------------------------------------
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensing option that enables unlimited
royalty-free distribution of the report engine for externally facing
server and web deployment.
http://p.sf.net/sfu/businessobjects
_______________________________________________
Octave-dev mailing list
Octave-dev@...
https://lists.sourceforge.net/lists/listinfo/octave-dev

Bug in optim-1.0.6

by Philippe Lavoie :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

You are correct,

I modified the line as you stated and then I did

>pkg unload optim

I re-ran torr_test_calib_sc and it works. So this should be filed as a bug in the optim-1.0.6 package then? i.e. fminunc works in Core but not in Optim.

Phil

-----Original Message-----
From: Jaroslav Hajek [mailto:highegg@...]
Sent: June-18-09 2:03 AM
To: Philippe Lavoie
Cc: octave-dev@...
Subject: Re: [OctDev] Problem with fminunc.m

On Wed, Jun 17, 2009 at 5:40 PM, Philippe
Lavoie<philippe.lavoie@...> wrote:

> Hi
>
>
>
> I'm using a MatLab library to help me with computer vision
> (http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=4576&objectType=file).
> With version 3.0.5, I didn't have any problems with the torr_test_calib
> method whereas with 3.2.0 it gives me the following result (with some unary
> operators not implemented).
>
>
>
>> torr_test_calib_sc
>
> focal_length =  2.4450
>
> error before non-linear minimization
>
> ans =  14.823
>
> warning: list objects are deprecated; use cell arrays instead
>
> warning: struct_contains is obsolete and will be removed from a future
> version of Octave; please use isfield instead
>
> warning: is_list is obsolete and will be removed from a future version of
> Octave; please use islist instead
>
> minimize(): Using 'nelder_mead_min' as back-end
>
> error: unary operator `'' not implemented for `list' operands
>
> error: binary operator `*' not implemented for `matrix' by `<unknown type>'
> operations
>
> error: called from:
>
> error:
> C:\Octave\3.2.0_gcc-4.3.0\share\octave\packages\optim-1.0.6\nelder_mead_min.m
> at line 153, column 3
>
> error:
> C:\Octave\3.2.0_gcc-4.3.0\share\octave\packages\optim-1.0.6\minimize.m at
> line 290, column 16
>
> error:
>   C:\Octave\3.2.0_gcc-4.3.0\share\octave\packages\optim-1.0.6\fminunc.m at
> line 141, column 15
>
> error:   d:\projects\CActusCommerce\Video\MatLab\Torr\torr_nonlinG.m at line
> 16, column 3
>
> error:   d:\projects\CActusCommerce\Video\MatLab\Torr\torr_test_calib_sc.m
> at line 62, column 8
>
> octave-3.2.0.exe:2:d:\projects\CActusCommerce\Video\MatLab\Torr
>
>
>
> Can someone please help regarding this?
>
>
>
> Thanks
>
>
>
> Phil
>

With the core fminunc (no package), it seems to work for me if I alter
the fminunc call int torr_nonlinG.m to the modern-style call:
g = fminunc(@(g) torr_errg_sse (g,nx1,ny1,nx2,ny2,m3,C), g_init);

Note that neither "Display" nor "Diagnostics" options are currently recognized.

best,

--
RNDr. Jaroslav Hajek
computing expert & GNU Octave developer
Aeronautical Research and Test Institute (VZLU)
Prague, Czech Republic
url: www.highegg.matfyz.cz

Confidentiality Message

This e-mail and its content is confidential: its privileged information is intended for the exclusive use of the addressee. Any other person is strictly prohibited from disclosing, distributing or reproducing it. If the addressee cannot be reached or is unknown to you, please inform the sender by return e-mail immediately and delete this e-mail message and destroy all copies.

Avis de confidentialité

Le présent courriel et son contenu est confidentiel: l'information privilégiée est à l'usage exclusif du destinataire ci-dessus. Toute autre personne est par les présentes avisée qu'il lui est strictement interdit de le diffuser, le distribuer ou le reproduire. Si le destinataire ne peut être joint ou vous est inconnu, veuillez informer l'expéditeur par courrier électronique immédiatement et détruire ce message et toute copie de celui-ci.

------------------------------------------------------------------------------
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensing option that enables unlimited
royalty-free distribution of the report engine for externally facing
server and web deployment.
http://p.sf.net/sfu/businessobjects
_______________________________________________
Octave-dev mailing list
Octave-dev@...
https://lists.sourceforge.net/lists/listinfo/octave-dev