User Tools

Site Tools


visual3d:documentation:pipeline:file_commands:file_save

File Save

Overview

The File_Save command is used to save the current state of the active CMZ file in Visual3D.

  • Functions the same way as click a “Save” button: it commits any pipeline-based changes to the currently opened CMZ file.
  • If no CMZ file is active (e.g., untitled or no file has been opened), Visual3D will prompt the user to specify the file name and location for saving.

Important Note: This command is for saving over the currently open CMZ file, not creating a new one (“File_Save_As”).

Pipeline Command

The command below is as seen on the Visual3D application, it has parameters as there are options to manipulate in this command:

File_Save
/SET_PROMPT=Save CMZ file
;

Command Parameters

The following table shows the command parameters and descriptions.

Parameter Description
! /SET_PROMPT=Optional prompt message shown if no file is open or CMZ is untitled. Defaults to 'Save CMZ File'.

Dialog

Due to the simplicity of this command, there is no dialog box with editable fields like other commands.

  • The only editable parameter is the optional prompt shown in the save dialog.

Examples

The following examples will go through the use of the File_Save command in the Visual3D application.

Example 1: Save a file after adding Gait Events

This example loads a CMZ file, runs automatic gait event detection, and then saves the modified file.

Step 1: Open a file, the name/path will need to be filled in by the user, if not specified, a prompt will open for user to select CMZ.

File_Open
!/FILE_NAME=
!/FILE_PATH=
!/SEARCH_SUBFOLDERS=FALSE
!/SUFFIX=
!/SET_PROMPT=Open Trial
!/ON_FILE_NOT_FOUND=PROMPT
!/FILE_TYPES_ON_PROMPT=
;

Step 2: Add Gait Events (kinetic data)

Automatic_Gait_Events
!/FRAME_WINDOW=8
!/USE_TPR=TRUE
!/TPR_EVENT_INSTANCE=1
;

Step 3: Save File

File_Save
!/SET_PROMPT=Save CMZ with gait events
;

Example 2: Add custom events and metrics, then Save

This example loads a file, adds a custom event using Event_Global_Maximum, computes the metric value at this event, then saves the trial with all modifications.

File_Open
!/FILE_NAME=Participant04
!/FILE_PATH=CMZ_Data
!/SEARCH_SUBFOLDERS=TRUE
!/SUFFIX=_Walk1.cmz
!/SET_PROMPT=
!/ON_FILE_NOT_FOUND=SKIP
!/FILE_TYPES_ON_PROMPT=
;

Event_Global_Maximum
/RESULT_EVENT_NAME=Peak_LeftKneeFlex
/SIGNAL_TYPES=LINK_MODEL_BASED
/SIGNAL_FOLDER=ORIGINAL
/SIGNAL_NAMES=Left_Knee_Angle
/SIGNAL_COMPONENTS=Z
/FRAME_OFFSET=0
/TIME_OFFSET=
/EVENT_SEQUENCE=RTO,RHS
/EXCLUDE_EVENTS=
/EVENT_SEQUENCE_INSTANCE=0
/EVENT_SUBSEQUENCE=
/SUBSEQUENCE_EXCLUDE_EVENTS=
/EVENT_SUBSEQUENCE_INSTANCE=0
/THRESHOLD=
;

Metric_Signal_Value_At_Event
/SIGNAL_FOLDER=ORIGINAL
/SIGNAL_LABEL=Left_Knee_Angle_Z
/EVENT_NAME=Peak_LeftKneeFlex
/RESULT_METRIC_NAME=KneeFlexion_Max
;

File_Save
!/SET_PROMPT=Save updated CMZ with metrics
;

Notes

  • File_Save should be placed at the end of your pipeline unless intermediate saves are being made.
  • If batch processing, always verify the file opened with 'File_Open' is correctly matched to the save logic.

Back to Pipeline Commands Reference

visual3d/documentation/pipeline/file_commands/file_save.txt · Last modified: 2025/06/09 20:49 by wikisysop