Esempio n. 1
0
    ########################
    dataset = dh.ConvertWC_InTPC_thresh('{}'.format(f),Charge_thresh)
    print 'size of dataset : ' , str(len(dataset))
    if len(dataset)==0:
        continue
    
    

    ########################
    # Build the reco testing here 
    ########################
    labels = []
    

    labels = pc.kdtree_radius(dataset)
    datasetidx_holder = lh.label_to_idxholder(labels,20) # Converts the labels list into a list of indexvalues for datasets  [ [ list of index], [list of indexes].. [] ]  

    print 'out of the tree for good'
    # Make a json to view
    if make_jsons:
        dh.MakeJson_Objects(dataset,datasetidx_holder,labels,jdir,jcount,'kd_tree', mc_dl)

    print ' AT THE END'





    #if len(dataset)>=15000 or len(dataset)==0:
        #labels = pc.walker(dataset,6,20) # Runs clustering and returns labels list 
    #else:
Esempio n. 2
0
    ########################
    dataset = dh.ConvertWC_InTPC_thresh('{}'.format(f), Charge_thresh)
    if len(dataset) == 0:
        continue

    if make_jsons:
        dh.MakeJsonReco(f, jdir, jcount, 'AlgSPT', mc_dl)

    #######
    labels = []

    labels = pc.walker(dataset, nn_dist,
                       mincluster)  # Runs clustering and returns labels list

    datasetidx_holder = lh.label_to_idxholder(
        labels, mincluster
    )  # Converts the labels list into a list of indexvalues for datasets  [ [ list of index], [list of indexes].. [] ]

    if make_jsons:
        dh.MakeJson_Objects(dataset, datasetidx_holder, labels, jdir, jcount,
                            'Walker', mc_dl)

    d, labels = st.Track_Stitcher_epts(dataset, datasetidx_holder, labels,
                                       gap_dist, k_radius, min_pdelta, AE,
                                       min_clust_length)
    datasetidx_holder = lh.label_to_idxholder(
        labels, mincluster
    )  # Converts the labels list into a list of indexvalues for datasets  [ [ list of index], [list of indexes].. [] ]

    #if make_jsons:
    #    dh.MakeJson_Objects(dataset,datasetidx_holder,labels,jdir,jcount,'Stitcher', mc_dl)