Example #1
0
def run(delta_pdgs, is_not, output_name, ccnc = 0):

    if os.path.exists(output_name):
        shutil.rmtree(output_name)
        
    os.mkdir(output_name)
    
    file_increment = 10
    increment_counter = 0
    file_counter = 1

    number_of_arguments = len(sys.argv) - 1

    loop_range = 1
    
    if(number_of_arguments > file_increment):
        loop_range = number_of_arguments / file_increment
        if(number_of_arguments % file_increment):
            loop_range += 1

    my_proc = fmwk.ana_processor()
            
    for i in xrange(0, loop_range):

        my_proc.reset()
        increment_counter += file_increment
        
        while(file_counter <= increment_counter):
            
            if file_counter >= len(sys.argv):
                break
            
            my_proc.add_input_file(sys.argv[file_counter])
            file_counter += 1
        
        my_proc.set_io_mode(fmwk.storage_manager.kBOTH)
        my_proc.set_output_file(output_name + "/" + output_name + "_" + str(i) + ".root")
        my_proc.enable_filter()

        if(ccnc == 1):
            my_proc.add_process(fmwk.ccnc(True))
        elif(ccnc == 2):
            my_proc.add_process(fmwk.ccnc(False))
            
        idrs = fmwk.is_delta_rad_spec(is_not)
        
        for i in xrange(0, len(delta_pdgs)):
            idrs.add_delta_parents(delta_pdgs[i])
        
        my_proc.add_process(idrs)
    
        my_proc.run()
Example #2
0
is_not = True

#ALL
################################################################################

my_proc = fmwk.ana_processor()

for i in xrange(1,len(sys.argv)):
    my_proc.add_input_file(sys.argv[i])

my_proc.set_io_mode(fmwk.storage_manager.kBOTH)
out_name = "not_delta_rad_1delta_1gamma.root"
my_proc.set_output_file(out_name)
my_proc.enable_filter()

idrs = fmwk.is_delta_rad_spec(is_not)
idrs.add_delta_parents(2214)
idrs.add_delta_parents(2114)
my_proc.add_process(idrs)

my_proc.run()

################################################################################

my_proc2 = fmwk.ana_processor()

for i in xrange(1,len(sys.argv)):
    my_proc2.add_input_file(sys.argv[i])
    
my_proc2.set_io_mode(fmwk.storage_manager.kBOTH)
out_name2 = "not_delta_rad_1deltaplus_1gamma.root"
Example #3
0
        
        while(file_counter <= increment_counter):
            
            if(file_counter >= len(sys.argv)):
                break
            
            my_proc.add_input_file(sys.argv[file_counter])
            file_counter += 1
        
        my_proc.set_io_mode(fmwk.storage_manager.kBOTH)
        my_proc.set_output_file(output_name + "/" + output_name + "_" + str(i) + ".root")
        my_proc.enable_filter()

        if(ccnc == 1):
            my_proc.add_process(fmwk.ccnc(True))
        elif(ccnc == 2):
            my_proc.add_process(fmwk.ccnc(False))
            
        idrs = fmwk.is_delta_rad_spec(is_not)
        
        for(i in xrange(0, len(delta_pdgs))):
            idrs.add_delta_parents(delta_pdgs[i])
        
        my_proc.add_process(idrs)
    
        my_proc.run()

        
        
run([2214, 2114], False, "delta_rad_1delta_1gamma")