stylish.filesystem¶
-
stylish.filesystem.
load_image
(image_path, image_size=None)[source]¶ Return 3-D Numpy array from image path.
image_size can be specified to resize the image.
-
stylish.filesystem.
fetch_images
(path, limit=None)[source]¶ Return list of image paths from path.
limit should be the maximum number of files to fetch from path. By default, all files are fetched.
-
stylish.filesystem.
sanitise_value
(value, substitution_character='_', case_sensitive=True)[source]¶ Return value suitable for use with filesystem.
Replace awkward characters with substitution_character. Where possible, convert unicode characters to their closest “normal” form.
If not case_sensitive, then also lowercase value.