INNER CODE UNIT · Python
remove_dsstore
aniketmaurya/chitra · chitra/core.py:14
def remove_dsstore(path) -> None:
"""Deletes .DS_Store files from path and sub-folders of path."""
path = pathlib.Path(path)
for e in path.glob("*.DS_Store"):
os.remove(e)
for e in path.glob("*/*.DS_Store"):
os.remove(e)
def get_basename(path: tf.string) -> tf.string:
if not isinstance(path, tf.Tensor):
raise AssertionError
return tf.strings.split(path, os.path.sep)[-1]
def load_imagenet_labels() -> Tuple[str]: