[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [ROOT] On the ability of RooFit to use an arbitrary fitter plugin



Hi Kevin, Rene, Wouter, et al,

[Sorry for the late follow-up - I've been busy as ...]

On Wed, 2006-01-25 at 16:39 -0500, Kevin B. McCarty wrote:
> [CC-ing to Chris Roat and debian-science since I originally suggested
> there that RooFit could be patched to use any of the fitter plugins.]
> 
> Unfortunately it looks like RooMinuit.cxx and RooFitResults.cxx can't
> currently be converted to use the TVirtualFitter interface.  There are
> two main issues:
> 
> 1) The function RooMinuit::contour() directly uses TMinuit::Contour(), a
> method which isn't accessible through TVirtualFitter (or even in TFitter).

Hmph.

> 2) The function RooFitResult::fillCorrMatrix() mucks about in the
> internals of the TMinuit class in order to obtain an error correlation
> matrix.  There is no API for obtaining this matrix even in TMinuit, let
> alone in TVirtualFitter.

Whoha - those guys must have nerves of steel :-)

> I could submit a patch to fix RooFitResult::lastMinuitFit() and
> RooMinuit::synchronize() to use TVirtualFitter instead of gMinuit, but I
> guess there is not much point until (1) and (2) above are dealt with.
> Someday maybe these functionalities can be added to TVirtualFitter (and
> the classes that inherit from it) and RooFit can switch to use it
> completely.
...
> To conclude, currently libRooFit is constrained to depend specifically
> upon libMinuit.  I do apologize for wasting people's time because I
> thought otherwise at first.  For the ROOT Debian packages, I think
> therefore libRooFit cannot be packaged as a library unless libMinuit is
> also packaged as a library.  Or, they could both be packaged just as
> plugins.

To the ROOT people that get this mail:  I think many developers are not
really aware of the various abstract interface that exist in ROOT, like
TVirtualFitter, TSQLServer, and so on.  That results in people writing
code like 

	TSQLServer* s = TMySQLServer::Connect(...) 

(fictive example :-) which breaks these nice interfaces, and makes life
hard for the user. 

Perhaps you could make an effort to stipulate that the virtual
interfaces are there, and should be used.   Thanks. 

Of course, the Right Way(tm) to do it, would be to _not_ export the
declarations of pure `plug-in' classes like `TMinuit', `TMySQLServer',
and so on.   That is, do not install the header files anywhere, nor
create development libraries, and put the binary loadable plug-in
modules somewhere the linker doesn't look for it, say
`<base>/lib/root/plugins'.   

For the Debian people:  I'll probably merge Minuit into the libroot
package, or make libroot-minuit and libroot-minuit-dev.   Making rootfit
a plug-in package wouldn't work. 

Yours,

-- 
 ___  |  Christian Holm Christensen 
  |_| |  -------------------------------------------------------------
    | |  Address: Sankt Hansgade 23, 1. th.  Phone:  (+45) 35 35 96 91
     _|           DK-2200 Copenhagen N       Cell:   (+45) 24 61 85 91
    _|            Denmark                    Office: (+45) 353  25 404
 ____|   Email:   cholm@nbi.dk               Web:    www.nbi.dk/~cholm
 | |



Reply to: