Skip to content

Commit

Permalink
truncation
Browse files Browse the repository at this point in the history
  • Loading branch information
bbaloglu authored and bbaloglu committed Oct 22, 2020
1 parent 032590d commit 132b066
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/bilge_pype.py
Original file line number Diff line number Diff line change
Expand Up @@ -715,7 +715,7 @@ def aligner_fix_name(df, col='id'):
'''
out = df.copy()
revmap = {str(i)+'_'+out.iloc[i][col].replace(' ','_'):out.iloc[i][col] for i in range(0,len(df))}
out.iloc[:,col] = revmap.keys()
out.loc[:,col] = revmap.keys()
return out, revmap

def aligner_restore_name(df, revmap, col='id'):
Expand All @@ -725,7 +725,7 @@ def aligner_restore_name(df, revmap, col='id'):
revmap = dictionary containing mapping of new id to old id
col = column name containing the id restore
'''
df.iloc[:,col] = [revmap[df.iloc[i][col]] for i in range(0,len(df))]
df.loc[:,col] = [revmap[df.iloc[i][col]] for i in range(0,len(df))]
return df

def aligner_get_similarity(data):
Expand Down

0 comments on commit 132b066

Please sign in to comment.