Hi Dima,
In that case please have a look at LCIOTrackParameters in my package.
The class provides static methods for the parameter conversion.
The Driver in the package should require only minor modifications to put in org.lcsim.event.Track objects into the event. That was actually the purpose for its creation. I can re-enable that, if you want.
To be honest, I don't know why you would want to use DocaTrackParamters when you yourself acknowledge that it's broken. There are no unit tests for the package and no maintainer.
On the other hand the code in org.lcsim.contrib.JanStrube.tracking has unit tests associated with it which are part of the official test suit and run at every checkin. It is certainly stable from a functional point of view, and it even passes tests that are not part of the main suite.
Also, please try to communicate your findings about shortcomings of the code to the developers. They are working very hard to produce stable and useful code and are doing a very good job, despite the fact that there is a acute shortage in manpower. An extra pair of eyes (and hands) always helps in improving the quality of the code for everybody. I am sure that there are many occasional users who are unaware of your findings and who could benefit from that feedback.
Best,
Jan
-----Original Message-----
From: Dmitry Onoprienko [mailto:[log in to unmask]]
Sent: Wednesday, November 29, 2006 12:38 PM
To: Strube, Jan
Cc: von Toerne, Eckhard; lcd-dev
Subject: Re: FW: Request of changes to DocaTrackParameters
Hi Jan,
the machinery you developed looks very useful, but it's not exactly what I
need at the moment. The org.lcsim.event.Track interface and its "standard"
implementation are indeed inadequate for some purposes, so we've always been
using our own classes to represent tracks, but we made them to implement the
standard Track interface to be compatible with other track finders, PFA
classes, and WIRED. Your org.lcsim.contrib.JanStrube.tracking.Track
interface is not the standard (yet ?) so it does not serve this purpose.
I can still use your NewFastMCTrackFactory class to convert MCParticle
parameters into helix parameters, though it will probably be a slow way to
do this since it will have to go through quite a few extra steps and
conversions.
The best way to resolve this would be to have an updated Track interface in
org.lcsim.event, and a standard implementation class
(org.lcsim.event.base.BaseTrack ?) that would include methods for converting
between particle and track parameters. I was just looking into possibility
to use org.lcsim.mc.fast.tracking.DocaTrackParameters instead of my own code
as a temporary solution - it has an advantage of being in the main CVS area
so it is supposedly stable...
Best Regards,
- Dima.
----- Original Message -----
From: "Jan Strube" <[log in to unmask]>
Cc: "lcd-dev" <[log in to unmask]>
Sent: Wednesday, November 29, 2006 12:18 AM
Subject: Re: FW: Request of changes to DocaTrackParameters
> Hi Dima,
>
> please have a look at
> http://confluence.slac.stanford.edu/display/~jstrube/A+New+Track
> +Interface
> as well as org.lcsim.contrib.JanStrube.tracking
> I have tried to be good about documenting the code, but there is a
> reason why this code is still in my contrib area.
> There is a code snippet that shows how to use the new code.
> Please feel free to post questions as comments on the page.
>
> Cheers,
> Jan
>
>
>
> On Tue, 2006-11-28 at 14:32 -0800, Johnson, Tony S. wrote:
>>
>> Hi Dima, I'm forwarding your request to the lcd-dev list, because I think
>> what you want already exists (created by Jan I think).
>>
>> Tony
>>
>> -----Original Message-----
>> From: Dmitry Onoprienko [mailto:[log in to unmask]]
>> Sent: Monday, November 27, 2006 11:37 AM
>> To: Johnson, Tony S.
>> Subject: Request of changes to DocaTrackParameters
>>
>> Hello Tony,
>>
>> I'd like to use org.lcsim.mc.fast.tracking.DocaTrackParameters class to
>> initialize a Track from an MCParticle, but for some reason the class and
>> its constructors are not public. Is it possible to change that, or is
>> there another class I should use ? I attach a modified version of
>> DocaTrackParameters.java - besides making the class and its constructors
>> public, the only change is that a call to p.getType().getCharge() is
>> replaced with p.getCharge() (p is hep.physics.particle.Particle) to
>> avoid crashes when getType() does not return a valid type - mainly for
>> nuclear fragments.
>>
>> Best Regards,
>> - Dima.
>>
>>
> --
> Jan Fridolf Strube University of Oregon
>
> Stanford Linear Accelerator Center
> mailstop 35
> bldg 48, rm 244
> phone: (650) 926-2913
>
>
|