/Python/Def get_label(Dir): for nextdir in os.listdir(Dir): if not nextdir.startswith('.'): if nextdir in ['NORMAL']: label = 0 elif nextdir in ['PNEUMONIA']: label = 1 else: label = 2 return nextdir, label
Def get_label(Dir): for nextdir in os.listdir(Dir): if not nextdir.startswith('.'): if nextdir in ['NORMAL']: label = 0 elif nextdir in ['PNEUMONIA']: label = 1 else: label = 2 return nextdir, label
Def get_label(Dir): for nextdir in os.listdir(Dir): if not nextdir.startswith('.'): if nextdir in ['NORMAL']: label = 0 elif nextdir in ['PNEUMONIA']: label = 1 else: label = 2 return nextdir, label
0
- 0 vote177 views1 answer
- -3 votes128 views2 answers
- 40 votes168 views4 answers
- 0 vote155 views1 answer
- 13 votes152 views6 answers
- 0 vote130 views1 answer
- 0 vote170 views1 answer
- -1 vote162 views1 answer
- 1 vote157 views1 answer
- 0 vote165 views2 answers