/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 vote116 views1 answer
- 8 votes109 views2 answers
- 0 vote106 views1 answer
- 0 vote130 views1 answer
- 3 votes105 views2 answers
- 0 vote147 views1 answer
- 0 vote118 views1 answer
- 3 votes115 views2 answers
- 0 vote107 views1 answer
- 0 vote106 views1 answer