Hi Edward

Do you think it is feasable to change the minimisation of curvefitting of the 
CPMG relaxation protocol to Minfx. I was trying to use the minfx when I started 
coding NESSY, but decided on Scipy as documentation was better. I would be more 
than happy if this would improve NESSY.

I am also happy with creating this special task.

Cheers
Michael
-------- Original-Nachricht --------
> Datum: Wed, 27 Jun 2012 11:57:52 +0200
> Von: "Edward d\'Auvergne" <[email protected]>
> An: Michael Bieri <[email protected]>
> CC: [email protected], [email protected]
> Betreff: Re: [Nessy-users] R1rho dispersion fitting - handling exception

> Hi,
> 
> Yes, I've looked into this and it probably will involve a significant
> effort to make this specific experiment type functional.  The
> technical problem is that this is using the scipy
> (http://www.scipy.org/) Levenberg-Marquardt optimisation algorithm
> (http://en.wikipedia.org/wiki/Levenberg%E2%80%93Marquardt_algorithm)
> which I think requires that the optimisation target function
> (fit_func[str(model)] in this case) to return a Jacobian
> (http://en.wikipedia.org/wiki/Jacobian_matrix_and_determinant) rather
> than the chi-squared value to minimise.  From my testing of the scipy
> optimisation for relax (http://ww.nmr-relax.com) back in 2003, the
> optimisation code in scipy was abandon-ware - all algorithms had fatal
> bugs and my emails to the authors never had any responses.  I don't
> think the scipy optimisation authors ever reappeared, and I don't know
> if the code has changed since then.  This is why I wrote the minfx
> library (https://gna.org/projects/minfx/) for optimisation within
> relax.  I would suggest using minfx for NESSY - due to the licencing
> compatibility minfx can be bundled with the NESSY sources and the
> minfx interface is 100% compatible with the current design of the
> optimisation target functions in NESSY.
> 
> However as you hinted at Michael, there will be significant work
> required to make everything work after the optimisation is up and
> running.  My guess would be a month or more of coding and debugging.
> Unfortunately I don't have the time or resources to complete this.  I
> would suggest having this open as a bug report (Susmita, could you
> create this?), put a call out that this can be developed by anyone
> with an interest, create a special task for this development with
> links to the mailing list messages and Susmita's bug report, and to
> change the warning message to include a link to the NESSY task.
> Michael, what do you think?
> 
> Regards,
> 
> Edward
> 
> 
> On 27 June 2012 09:52, Michael Bieri <[email protected]> wrote:
> > Hi all
> >
> > The R1rho analysis is still in development. i was not able to finish the
> R1rho analysis and haven't tested it very well. So thank you Edward for
> taking care, but I assume there will be a lot of other issues coming next. As
> the message, which pops up if you chose the r1rho analysis, sais, this
> function is still under development. There is no active development currently,
> so I guess not a lot will change.
> >
> > Edward, if this is a bug which is easy to fix, this would be very nice.
> but I think it would exeed your planed involvement in NESSY.
> >
> > Cheers
> > Michael
> > -------- Original-Nachricht --------
> >> Datum: Wed, 27 Jun 2012 09:31:00 +0200
> >> Von: "Edward d\'Auvergne" <[email protected]>
> >> An: Susmita Borthakur <[email protected]>
> >> CC: [email protected]
> >> Betreff: Re: [Nessy-users] R1rho dispersion fitting - handling
> exception
> >
> >> Hi,
> >>
> >> To reproduce the problem, would you have data for a single spin
> >> system?  I can reproduce the issue you see with the repository copy of
> >> NESSY using some random data, but it would be useful for debugging
> >> purposes to have a little bit of real data (if you'd like to keep it
> >> completely secret, then you could randomise the data a little).  I
> >> would also highly recommend submitting a bug report for this at
> >> https://gna.org/bugs/?func=additem&group=nessy.  This will help other
> >> NESSY users who encounter the same issue.
> >>
> >> Cheers,
> >>
> >> Edward
> >>
> >>
> >>
> >>
> >> On 26 June 2012 15:19, Susmita Borthakur <[email protected]> wrote:
> >> > Hi Edward,
> >> >
> >> > Thank you for your mail and also for pointing me to the right email
> >> address.
> >> > As I mentioned in my previous mail, I tried fitting some R1rho
> >> > (off-resonance) data using NESSY -12.3.1 (on UBUNTU) and received
> error
> >> > messages. Please see below for the details of the experimental set up
> >> and
> >> > the error messages:
> >> >
> >> > Experimental set up-
> >> >
> >> > Experiment Type: R1rho Dispersion (off-resonance)
> >> >
> >> > Heteronuclear Frequency [MHz]:
> >> >
> >> > 81.079
> >> >
> >> > Offset [Hz]:
> >> >
> >> > 2000
> >> >
> >> > Spin-lock time [s]:
> >> >
> >> > 0.02
> >> > 0.04
> >> > 0.06
> >> > 0.08
> >> > 0.1
> >> >
> >> > Spin-lock power [Hz]:
> >> >
> >> > 0.08
> >> >
> >> > Analysis-
> >> >
> >> >
> >> > Execution Protocol......
> >> >
> >> >
> >> > Evaluating Datasets and Experiments:
> >> > ==================================================
> >> >
> >> >
> >> > Checking if project folder is set up...            [Ok]
> >> >
> >> > Evaluating Experiment 1.....
> >> > =============================================
> >> >
> >> >
> >> >  Experiment 1 checked.
> >> >
> >> > -----------------------------------------------------------------
> >> > 1 experiment will be analyzed.
> >> > -----------------------------------------------------------------
> >> >
> >> >
> >> > Experiment mode: Off resonance R1rho relaxation dispersion.
> >> >
> >> > Reading data....done.
> >> >
> >> > Starting R1rho calculation.
> >> >
> >> > Calculating R1rho for residue 1, Offset: 12566.3706Hz
> >> > R1rho: 15.1
> >> > R1rho: 15.1
> >> > R1rho: 15.1
> >> > R1rho: 15.100
> >> > R1rho: -54.45
> >> > R1rho: 8.1449
> >> > R1rho: 8.1449
> >> > R1rho: -0.423
> >> > R1rho: -0.423
> >> > R1rho: -9.194
> >> > R1rho: -9.194
> >> > R1rho: -11.35
> >> > R1rho: -11.35
> >> > R1rho: -11.21
> >> > R1rho: -11.21
> >> > R1rho: -11.21
> >> > R1rho: -11.21
> >> > R1rho: -11.21
> >> > R1rho: -11.21
> >> > R1rho: -11.21
> >> > R1rho: -11.21
> >> > R1rho: -11.21
> >> > R1rho: -11.21
> >> > R1rho: -11.21
> >> >
> >> > Calculating R1rho for residue 2, Offset: 12566.3706Hz
> >> > R1rho: 15.1
> >> > R1rho: 15.1
> >> > R1rho: 15.1
> >> > R1rho: 15.100
> >> > R1rho: -49.77
> >> > R1rho: 8.6127
> >> > R1rho: 8.6127
> >> > R1rho: 0.3406
> >> > R1rho: 0.3406
> >> > R1rho: -8.368
> >> > R1rho: -8.368
> >> > R1rho: -10.65
> >> > R1rho: -10.65
> >> > R1rho: -10.51
> >> > R1rho: -10.51
> >> > R1rho: -10.50
> >> > R1rho: -10.50
> >> > R1rho: -10.50
> >> > R1rho: -10.50
> >> > R1rho: -10.50
> >> > R1rho: -10.50
> >> > R1rho: -10.50
> >> >
> >> > Pooled variance for residue 1, of experiment 1 is 1.0
> >> > Pooled variance for residue 2, of experiment 1 is 1.0
> >> >
> >> > Fitting residue 1 to model 1...
> >> > R1: 0.01/s, R2: 15.1 1/s
> >> > NESSY error> Unhandled exception in thread started by
> >> > NESSY error>
> >> > NESSY error> Traceback (most recent call last):
> >> > NESSY error>   File "/usr/share/nessy/elements/redirect.py", line
> 93,
> >> in
> >> > write
> >> > NESSY error>
> >> > NESSY error> self.report.SetSelection(self.max-self.pageno)
> >> > NESSY error>   File
> >> >
> "/usr/lib/python2.7/dist-packages/wx-2.8-gtk2-unicode/wx/_controls.py",
> >> line
> >> > 3013, in SetSelection
> >> > NESSY error>
> >> > NESSY error> return _controls_.BookCtrlBase_SetSelection(*args,
> >> **kwargs)
> >> > NESSY error>   File "/usr/share/nessy/func/calc.py", line 62, in
> >> __init__
> >> > NESSY error>
> >> > NESSY error> Run_spinlock(self.main, globalfit=True,
> onresonance=False)
> >> > NESSY error>   File
> "/usr/share/nessy/curvefit/calc_R1rho_models.py",
> >> line
> >> > 121, in __init__
> >> > NESSY error>
> >> > NESSY error> self.minimise(num_exp=num_exp, model=1,
> >> globalfit=globalfit,
> >> > onresonance=onresonance)
> >> > NESSY error>   File
> "/usr/share/nessy/curvefit/calc_R1rho_models.py",
> >> line
> >> > 1013, in minimise
> >> > NESSY error>
> >> > NESSY error> fit = leastsq(fit_func[str(model)], p, args=(y, error,
> >> field,
> >> > offset, globalfit, self.main.report_panel, self.main.spec_freq),
> >> full_output
> >> > = 1, col_deriv = 1, ftol = self.main.tolerance, xtol =
> >> > self.main.tolerance,maxfev=2000000)
> >> > NESSY error>   File
> >> > "/usr/lib/python2.7/dist-packages/scipy/optimize/minpack.py", line
> 275,
> >> in
> >> > leastsq
> >> > NESSY error>
> >> > NESSY error> raise TypeError('Improper input: N=%s must not exceed
> M=%s'
> >> %
> >> > (n,m))
> >> > NESSY error> TypeError
> >> > NESSY error> :
> >> > NESSY error> Improper input: N=2 must not exceed M=1
> >> > NESSY error>
> >> >
> >> > Any help/suggestions will be highly appreciated.
> >> >
> >> > Best wishes,
> >> > Susmita
> >> >
> >> >
> >> > --
> >> > Susmita Borthakur, D.Phil.
> >> > Postdoctoral Scholar
> >> > Department of Physiology & Biophysics
> >> > School of Medicine
> >> > Case Western Reserve University
> >> > 10900 Euclid Avenue
> >> > Cleveland OH  44106-4970
> >> > tel: +1-216-368-8654
> >> > email: [email protected]
> >> >
> >> >
> >> > _______________________________________________
> >> > Nessy-users mailing list
> >> > [email protected]
> >> > https://mail.gna.org/listinfo/nessy-users
> >> >
> >>
> >> _______________________________________________
> >> Nessy-users mailing list
> >> [email protected]
> >> https://mail.gna.org/listinfo/nessy-users
> >
> > --
> > Michael Bieri
> > Kardiologie, HTx
> > Inselspital, Pathologie L621
> > Murtenstr. 31, CH-3010 Bern
> > Switzerland
> >
> > Tel.: +41 31 632 13 82
> > Fax: +41 31 632 88 37
> >
> > [email protected]
> > www.cvrc.dkf.unibe.ch
> > www.insel.ch
> >
> >
> > NEU: FreePhone 3-fach-Flat mit kostenlosem Smartphone!
> > Jetzt informieren: http://mobile.1und1.de/?ac=OM.PW.PW003K20328T7073a

-- 
Michael Bieri
Kardiologie, HTx
Inselspital, Pathologie L621
Murtenstr. 31, CH-3010 Bern
Switzerland

Tel.: +41 31 632 13 82
Fax: +41 31 632 88 37

[email protected]
www.cvrc.dkf.unibe.ch
www.insel.ch


NEU: FreePhone 3-fach-Flat mit kostenlosem Smartphone!                          
        
Jetzt informieren: http://mobile.1und1.de/?ac=OM.PW.PW003K20328T7073a

_______________________________________________
Nessy-users mailing list
[email protected]
https://mail.gna.org/listinfo/nessy-users

Reply via email to