Print

Print


Yes, you can add whatever set methods you want on that Driver, which should set the values on the Clusterer’s cuts.  You can do the same with the boolean method and simply have it call a method on the Clusterer to set the boolean parameter too.

On Jan 21, 2015, at 1:43 PM, Kyle McCarty <[log in to unmask]> wrote:

Hello Jeremy,

There is a wrapper class, I believe (GTPClusterDriver), but it does not have a set method for the seed energy. Also, the clustering algorithm does not seem to support storing the "limitClusterRange" parameter outside the algorithm itself. Can I add support for setting the seed energy threshold with the code

    public void setSeedEnergyThreshold(double seedEnergyThreshold) {
        getClusterer().getCuts().setValue("seedEnergyThreshold", seedEnergyThreshold);
    }

in GTPClusterDriver? How can support be added for the "limitClusterRange" parameter? This is a boolean that indicates whether the algorithm should use an asymmetric clustering window or not.

Thanks,

Kyle

On Wed, Jan 21, 2015 at 4:05 PM, McCormick, Jeremy I. <[log in to unmask]> wrote:
Hi, Kyle.

> How do I define the parameters (such as the seed hit energy threshold) in the steering files with the new clustering algorithm?

If there is a “wrapper” Driver for the algorithm then you can just utilize the arguments in a steering file in the usual manner.  Should one of these Drivers not exist it is easy to add one.

Otherwise, to use the generic clustering Driver, you can pass a cuts array like…

<driver name=“ClusterDriver’ …>
    <clustererName>TheClusteringAlgo</clustererName>
    <cuts>1.0 2.0 3.0</cuts>
</driver>

The names of the cut parameters are defined in the constructor of each Clusterer.  (See its .java file.)

> Also, do you know how to get the proper xyz coordinates from a crystal's x/y indices? I need to do this in order to set the cluster position in the GTP clustering algorithm as you asked.


Probably the easiest way if you have a hit is….

hit.getDetectorElement().getGeometryInfo().getPosition();

which gets the crystal’s position from the geometry object.

—Jeremy

On Jan 21, 2015, at 4:41 AM, Kyle McCarty <[log in to unmask]> wrote:

> Hello Jeremy,
>
> How do I define the parameters (such as the seed hit energy threshold) in the steering files with the new clustering algorithm?
>
> Also, do you know how to get the proper xyz coordinates from a crystal's x/y indices? I need to do this in order to set the cluster position in the GTP clustering algorithm as you asked.
>
> Thanks,
>
> Kyle





Use REPLY-ALL to reply to list

To unsubscribe from the HPS-SOFTWARE list, click the following link:
https://listserv.slac.stanford.edu/cgi-bin/wa?SUBED1=HPS-SOFTWARE&A=1