Пример #1
0
    trackidx_holder = []
    showeridx_holder = []
    if len(dataset) >= 15000 or len(dataset) == 0:
        labels = pc.walker(dataset, 6,
                           20)  # Runs clustering and returns labels list
    else:
        labels = pc.crawlernn(dataset, 6,
                              20)  # Runs clustering and returns labels list

    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].. [] ]

    Ea.Ana_Object_photons(dataset,
                          datasetidx_holder,
                          jcount,
                          mcinfo,
                          mcqdep,
                          filename='photon_ana_obj')

    print ' AT THE END'
    '''
    ########################
    # mc_datalabel info
    # Call this once and get the mc info for the jsons for later
    ########################
    #mc_dl =  mh.mc_Obj_points(mh.mc_neutron_induced_OBJ(f))

    ########################
    # if the file is bad then continue and fill 
    ########################
    if not file_info[0]:
Пример #2
0
            #print 'size of dataset : ' , str(len(dataset))
            if len(dataset) == 0:
                continue

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

            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].. [] ]

            Ea.Ana_Object_photons(
                dataset,
                datasetidx_holder,
                jcount,
                mcinfo,
                mcqdep,
                filename='{}/photon_ana_obj_nn_{}_mspt_{}'.format(
                    method_name, str(nn_dist), str(mincluster)))

        print 'AT THE END for nndist={} and mincluster={}'.format(
            str(nn_dist), str(mincluster))