app/app.py
def df_reformat(df):
    """
    aignment datafrane reformat to TMs/ICL/ECL/Term dicy
    """
    info = Info()
    nterm = reformat(df[:22]); nnterm = info.nnterm
    tm1 = reformat(df[22:52]); ntm1 = info.ntm1
    icl1 = reformat(df[52:58]); nicl1 = info.nicl1
    tm2 = reformat(df[58:86]); ntm2 = info.ntm2
    ecl1 = reformat(df[86:92]); necl1 = info.necl1
    tm3 = reformat(df[92:130]); ntm3 = info.ntm3
    icl2 = reformat(df[130:137]); nicl2 = info.nicl2
    tm4 = reformat(df[137:163]); ntm4 = info.ntm4
    ecl2 = reformat(df[163:195]); necl2 = info.necl2
    tm5 = reformat(df[195:228]); ntm5 = info.ntm5
    icl3 = reformat(df[228:233]); nicl3 = info.nicl3
    tm6 = reformat(df[233:262]); ntm6 = info.ntm6
    ecl3 = reformat(df[262:268]); necl3 = info.necl3
    tm7 = reformat(df[268:292]); ntm7 = info.ntm7
    h8 = reformat(df[292:305]); nh8 = info.nh8
    cterm = reformat(df[305:]); ncterm = info.ncterm
    data, name, stat, aads, cons = "data", "name", "stat", 'aads', 'cons'
    or_dict = {
        'nterm': {name: nnterm, aads: nterm[0], stat: nterm[1], cons: nterm[2]},
        'cterm': {name: ncterm, aads: cterm[0], stat: cterm[1], cons: cterm[2]},
        'tm1': {name: ntm1, aads: tm1[0], stat: tm1[1], cons: tm1[2]},
        'tm2': {name: ntm2, aads: tm2[0], stat: tm2[1], cons: tm2[2]},
        'tm3': {name: ntm3, aads: tm3[0], stat: tm3[1], cons: tm3[2]},
        'tm4': {name: ntm4, aads: tm4[0], stat: tm4[1], cons: tm4[2]},
        'tm5': {name: ntm5, aads: tm5[0], stat: tm5[1], cons: tm5[2]},
        'tm6': {name: ntm6, aads: tm6[0], stat: tm6[1], cons: tm6[2]},
        'tm7': {name: ntm7, aads: tm7[0], stat: tm7[1], cons: tm7[2]},
        'h8': {name: nh8, aads: h8[0], stat: h8[1], cons: h8[2]},
        'ecl1': {name: necl1, aads: ecl1[0], stat: ecl1[1], cons: ecl1[2]},
        'ecl2': {name: necl2, aads: ecl2[0], stat: ecl2[1], cons: ecl2[2]},
        'ecl3': {name: necl3, aads: ecl3[0], stat: ecl3[1], cons: ecl3[2]},
        'icl1': {name: nicl1, aads: icl1[0], stat: icl1[1], cons: icl1[2]},
        'icl2': {name: nicl2, aads: icl2[0], stat: icl2[1], cons: icl2[2]},
        'icl3': {name: nicl3, aads: icl3[0], stat: icl3[1], cons: icl3[2]}
    }
    return or_dict

    aignment datafrane reformat to TMs/ICL/ECL/Term dicy
    
aignment datafrane reformat to TMs/ICL/ECL/Term dicy
aignment datafrane reformat to TMs / ICL / ECL / Term dicy
def df_reformat(df):
    info = Info()
    nterm = reformat(df[:22]); nnterm = info.nnterm
    tm1 = reformat(df[22:52]); ntm1 = info.ntm1
    icl1 = reformat(df[52:58]); nicl1 = info.nicl1
    tm2 = reformat(df[58:86]); ntm2 = info.ntm2
    ecl1 = reformat(df[86:92]); necl1 = info.necl1
    tm3 = reformat(df[92:130]); ntm3 = info.ntm3
    icl2 = reformat(df[130:137]); nicl2 = info.nicl2
    tm4 = reformat(df[137:163]); ntm4 = info.ntm4
    ecl2 = reformat(df[163:195]); necl2 = info.necl2
    tm5 = reformat(df[195:228]); ntm5 = info.ntm5
    icl3 = reformat(df[228:233]); nicl3 = info.nicl3
    tm6 = reformat(df[233:262]); ntm6 = info.ntm6
    ecl3 = reformat(df[262:268]); necl3 = info.necl3
    tm7 = reformat(df[268:292]); ntm7 = info.ntm7
    h8 = reformat(df[292:305]); nh8 = info.nh8
    cterm = reformat(df[305:]); ncterm = info.ncterm
    data, name, stat, aads, cons = "data", "name", "stat", 'aads', 'cons'
    or_dict = {
        'nterm': {name: nnterm, aads: nterm[0], stat: nterm[1], cons: nterm[2]},
        'cterm': {name: ncterm, aads: cterm[0], stat: cterm[1], cons: cterm[2]},
        'tm1': {name: ntm1, aads: tm1[0], stat: tm1[1], cons: tm1[2]},
        'tm2': {name: ntm2, aads: tm2[0], stat: tm2[1], cons: tm2[2]},
        'tm3': {name: ntm3, aads: tm3[0], stat: tm3[1], cons: tm3[2]},
        'tm4': {name: ntm4, aads: tm4[0], stat: tm4[1], cons: tm4[2]},
        'tm5': {name: ntm5, aads: tm5[0], stat: tm5[1], cons: tm5[2]},
        'tm6': {name: ntm6, aads: tm6[0], stat: tm6[1], cons: tm6[2]},
        'tm7': {name: ntm7, aads: tm7[0], stat: tm7[1], cons: tm7[2]},
        'h8': {name: nh8, aads: h8[0], stat: h8[1], cons: h8[2]},
        'ecl1': {name: necl1, aads: ecl1[0], stat: ecl1[1], cons: ecl1[2]},
        'ecl2': {name: necl2, aads: ecl2[0], stat: ecl2[1], cons: ecl2[2]},
        'ecl3': {name: necl3, aads: ecl3[0], stat: ecl3[1], cons: ecl3[2]},
        'icl1': {name: nicl1, aads: icl1[0], stat: icl1[1], cons: icl1[2]},
        'icl2': {name: nicl2, aads: icl2[0], stat: icl2[1], cons: icl2[2]},
        'icl3': {name: nicl3, aads: icl3[0], stat: icl3[1], cons: icl3[2]}
    }
    return or_dict
def df_reformat ( df ) : info = Info ( ) nterm = reformat ( df [ : 22 ] ) ; nnterm = info . nnterm tm1 = reformat ( df [ 22 : 52 ] ) ; ntm1 = info . ntm1 icl1 = reformat ( df [ 52 : 58 ] ) ; nicl1 = info . nicl1 tm2 = reformat ( df [ 58 : 86 ] ) ; ntm2 = info . ntm2 ecl1 = reformat ( df [ 86 : 92 ] ) ; necl1 = info . necl1 tm3 = reformat ( df [ 92 : 130 ] ) ; ntm3 = info . ntm3 icl2 = reformat ( df [ 130 : 137 ] ) ; nicl2 = info . nicl2 tm4 = reformat ( df [ 137 : 163 ] ) ; ntm4 = info . ntm4 ecl2 = reformat ( df [ 163 : 195 ] ) ; necl2 = info . necl2 tm5 = reformat ( df [ 195 : 228 ] ) ; ntm5 = info . ntm5 icl3 = reformat ( df [ 228 : 233 ] ) ; nicl3 = info . nicl3 tm6 = reformat ( df [ 233 : 262 ] ) ; ntm6 = info . ntm6 ecl3 = reformat ( df [ 262 : 268 ] ) ; necl3 = info . necl3 tm7 = reformat ( df [ 268 : 292 ] ) ; ntm7 = info . ntm7 h8 = reformat ( df [ 292 : 305 ] ) ; nh8 = info . nh8 cterm = reformat ( df [ 305 : ] ) ; ncterm = info . ncterm data , name , stat , aads , cons = "data" , "name" , "stat" , 'aads' , 'cons' or_dict = { 'nterm' : { name : nnterm , aads : nterm [ 0 ] , stat : nterm [ 1 ] , cons : nterm [ 2 ] } , 'cterm' : { name : ncterm , aads : cterm [ 0 ] , stat : cterm [ 1 ] , cons : cterm [ 2 ] } , 'tm1' : { name : ntm1 , aads : tm1 [ 0 ] , stat : tm1 [ 1 ] , cons : tm1 [ 2 ] } , 'tm2' : { name : ntm2 , aads : tm2 [ 0 ] , stat : tm2 [ 1 ] , cons : tm2 [ 2 ] } , 'tm3' : { name : ntm3 , aads : tm3 [ 0 ] , stat : tm3 [ 1 ] , cons : tm3 [ 2 ] } , 'tm4' : { name : ntm4 , aads : tm4 [ 0 ] , stat : tm4 [ 1 ] , cons : tm4 [ 2 ] } , 'tm5' : { name : ntm5 , aads : tm5 [ 0 ] , stat : tm5 [ 1 ] , cons : tm5 [ 2 ] } , 'tm6' : { name : ntm6 , aads : tm6 [ 0 ] , stat : tm6 [ 1 ] , cons : tm6 [ 2 ] } , 'tm7' : { name : ntm7 , aads : tm7 [ 0 ] , stat : tm7 [ 1 ] , cons : tm7 [ 2 ] } , 'h8' : { name : nh8 , aads : h8 [ 0 ] , stat : h8 [ 1 ] , cons : h8 [ 2 ] } , 'ecl1' : { name : necl1 , aads : ecl1 [ 0 ] , stat : ecl1 [ 1 ] , cons : ecl1 [ 2 ] } , 'ecl2' : { name : necl2 , aads : ecl2 [ 0 ] , stat : ecl2 [ 1 ] , cons : ecl2 [ 2 ] } , 'ecl3' : { name : necl3 , aads : ecl3 [ 0 ] , stat : ecl3 [ 1 ] , cons : ecl3 [ 2 ] } , 'icl1' : { name : nicl1 , aads : icl1 [ 0 ] , stat : icl1 [ 1 ] , cons : icl1 [ 2 ] } , 'icl2' : { name : nicl2 , aads : icl2 [ 0 ] , stat : icl2 [ 1 ] , cons : icl2 [ 2 ] } , 'icl3' : { name : nicl3 , aads : icl3 [ 0 ] , stat : icl3 [ 1 ] , cons : icl3 [ 2 ] } } return or_dict
aignment datafrane reformat to TMs/ICL/ECL/Term dicy
aignment datafrane reformat to TMs / ICL / ECL / Term dicy
"""
    aignment datafrane reformat to TMs/ICL/ECL/Term dicy
    """
df