Skip to content
Snippets Groups Projects
Commit e4a0248c authored by Stephane Chavin's avatar Stephane Chavin
Browse files

add_example

parent 05f160fe
Branches
No related tags found
No related merge requests found
example.csv 0 → 100644
Source diff could not be displayed: it is too large. Options to address this: view the blob.
...@@ -56,10 +56,8 @@ for i in tqdm(os.listdir(path)): ...@@ -56,10 +56,8 @@ for i in tqdm(os.listdir(path)):
table = pd.concat([tab2, tab]) table = pd.concat([tab2, tab])
df = pd.concat([df, table]) df = pd.concat([df, table])
print('df ici : ', df)
df.reset_index(inplace = True) df.reset_index(inplace = True)
tab = df.groupby('espece').count() tab = df.groupby('espece').count()
print('tab ici : ', tab)
compte = pd.DataFrame(np.zeros((len(tab)+1,1)),columns = ['nombre']) compte = pd.DataFrame(np.zeros((len(tab)+1,1)),columns = ['nombre'])
...@@ -112,5 +110,5 @@ for i,row in train.iterrows(): ...@@ -112,5 +110,5 @@ for i,row in train.iterrows():
with open(str(direction+'custom_data.yaml'),'w') as f: with open(str(direction+'custom_data.yaml'),'w') as f:
f.write('train : '+direction+'images/train\n') f.write('train : '+direction+'images/train\n')
f.write('test : '+direction+'images/val\n') f.write('test : '+direction+'images/val\n')
f.write('nc : ' + len(tab)+'\n') f.write('nc : ' + str(len(tab))+'\n')
f.write('names : ' + str(tab.columns)) f.write('names : ' + str(tab.columns))
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment