snowflake.ml.model.CodePath

class snowflake.ml.model.CodePath(root: str, filter: Optional[str] = None)

Bases: object

Specifies a code path with optional filtering for selective inclusion.

Parameters:
  • root – The root directory or file path (absolute or relative to cwd).

  • filter – Optional relative path under root to select a subdirectory or file. The filter also determines the destination path under code/.

Examples

CodePath(“project/src/”) # Copy entire src/ to code/src/ CodePath(“project/src/”, filter=”utils”) # Copy utils/ to code/utils/ CodePath(“project/src/”, filter=”lib/helpers”) # Copy to code/lib/helpers/

Attributes

filter: Optional[str] = None
root: str