changed label mapping
This commit is contained in:
parent
07043bd39b
commit
46334b8456
@ -205,6 +205,16 @@ def write_clusters(path, clusters, type_column=6):
|
||||
|
||||
types = np.unique(cluster[:, type_column], axis=0).astype(int)
|
||||
|
||||
def type_mapping(t):
|
||||
if t == 0:
|
||||
return 2
|
||||
elif t == 1:
|
||||
return 1
|
||||
elif t == 3:
|
||||
return 4
|
||||
return t
|
||||
|
||||
types = np.array([type_mapping(t) for t in types])
|
||||
print("Types: ", types)
|
||||
|
||||
np.savetxt(file, types.reshape(1, types.shape[0]),delimiter=';', header='', comments='', fmt='%i')
|
||||
|
Loading…
x
Reference in New Issue
Block a user