Line 58-62 metamap.py. Uses list comprehension to check if file exists in directory. #209

Closed
opened 2025-10-14 16:33:39 -06:00 by navan · 0 comments
Owner

Originally created by @thesw4rm on 10/26/2018

Lines 58-62 of metamap.py have a roundabout, list comprehension way of checking for existing files. Can be replaced with if file in os.listdir(self.cache_directory) ....

*Originally created by @thesw4rm on 10/26/2018* [Lines 58-62](https://github.com/NanoNLP/medaCy/blob/344df0f556b6eb452907b10e4c511fbf87a1943f/medacy/pipeline_components/metamap/metamap.py#L58-L62) of `metamap.py` have a roundabout, list comprehension way of checking for existing files. Can be replaced with `if file in os.listdir(self.cache_directory) ...`.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github/medaCy#209
No description provided.