Operation Archive

async dffml.operation.archive.extract_tar_archive(input_file_path: str, output_directory_path: str) dict[source]

Extracts a given tar file.

Parameters:
  • input_file_path (str) – Path to the tar file

  • output_directory_path (str) – Path where all the files should be extracted

Returns:

Path to the directory where the archive has been extracted

Return type:

dict

async dffml.operation.archive.extract_zip_archive(input_file_path: str, output_directory_path: str) dict[source]

Extracts a given zip file.

Parameters:
  • input_file_path (str) – Path to the zip file

  • output_directory_path (str) – Path where all the files should be extracted

Returns:

Path to the directory where the archive has been extracted

Return type:

dict

async dffml.operation.archive.make_tar_archive(input_directory_path: str, output_file_path: str) dict[source]

Creates tar file of a directory.

Parameters:
  • input_directory_path (str) – Path to directory to be archived as a tarfile.

  • output_file_path (str) – Path where the output archive should be saved (should include file name)

Returns:

Path to the created tar file.

Return type:

dict

async dffml.operation.archive.make_zip_archive(input_directory_path: str, output_file_path: str) dict[source]

Creates zip file of a directory.

Parameters:
  • input_directory_path (str) – Path to directory to be archived

  • output_file_path (str) – Path where the output archive should be saved (should include file name)

Returns:

Path to the output zip file

Return type:

dict