Skip to content

Context

Source

Context submodule.

A convenience function to change the working directory in order to save data.

cwd(path)

Change the current working directory to the given path.

This method can be used to generate files in a specific directory, once out of the context, the working directory is set back to the original one.

Parameters:

Returns:

Examples:

The context is whcnaged within the block and then restored to the original one.

>>> with cwd(my_path):
...     pass # do something

get_careamics_home()

Return the CAREamics home directory.

CAREamics home directory is a hidden folder in home.

Returns:

  • Path

    CAREamics home directory path.