ssapy_toolkit.IO.io_utils
Functions
|
Get a list of all files in the directory tree starting at the given path. |
|
Check if a given path is either a file or a directory. |
|
Check if a file with the given name exists (including its extensions). |
|
Returns a list of full paths for all image files in the specified folder. |
|
List files in a directory, with options to filter, exclude, and sort. |
|
Create a directory if it does not already exist. |
|
Move a directory from the source path to the destination path. |
|
Flatten a list of data by splitting string elements like '[1,2,3]' and converting them into floats. |
|
Apply str_to_array to each element of a DataFrame and convert it to a NumPy array of arrays. |
|
Remove a directory and its contents. |
|
Remove a file if it exists. |
|
Convert a string representation of a list (e.g., '[1, 2, 3]') into a NumPy array of floats. |
- ssapy_toolkit.IO.io_utils.allfiles(dirName: str = '/home/docs/checkouts/readthedocs.org/user_builds/ssapy-toolkit/checkouts/latest/docs') list[source]
Get a list of all files in the directory tree starting at the given path.
- ssapy_toolkit.IO.io_utils.exists(pathname: str) bool[source]
Check if a given path is either a file or a directory.
- ssapy_toolkit.IO.io_utils.file_exists(filename: str) bool[source]
Check if a file with the given name exists (including its extensions).
- ssapy_toolkit.IO.io_utils.get_image_paths(folder_path: str, sort_by_number: bool = True) list[source]
Returns a list of full paths for all image files in the specified folder.
- ssapy_toolkit.IO.io_utils.listdir(dir_path: str = '*', files_only: bool = False, exclude: str = None, do_sort: bool = True) list[source]
List files in a directory, with options to filter, exclude, and sort.
- ssapy_toolkit.IO.io_utils.mkdir(pathname: str) None[source]
Create a directory if it does not already exist.
- ssapy_toolkit.IO.io_utils.mvdir(source_: str, destination_: str) None[source]
Move a directory from the source path to the destination path.
- ssapy_toolkit.IO.io_utils.pd_flatten(data: list, factor: float = 1) list[source]
Flatten a list of data by splitting string elements like ‘[1,2,3]’ and converting them into floats. Divides each float by factor.