visual3d:documentation:pipeline:file_commands:select_active_file
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revision | |||
visual3d:documentation:pipeline:file_commands:select_active_file [2025/07/21 20:21] – wikisysop | visual3d:documentation:pipeline:file_commands:select_active_file [2025/07/22 15:05] (current) – wikisysop | ||
---|---|---|---|
Line 12: | Line 12: | ||
==== Understanding the File Selection Methods ==== | ==== Understanding the File Selection Methods ==== | ||
+ | **/ | ||
+ | * " | ||
+ | * " | ||
- | ===== Overview ===== | + | **/QUERY=**: Lets you use logic expressions to select based on file-level tags |
+ | * If you have tagged trials like " | ||
+ | * '/ | ||
+ | * '/ | ||
- | The **Select_Active_File** command in Visual3D can allow the user to select which file is active in the workspace. As many of the pipeline commands in Visual3D act on the active files only, using this command can allow you to determine which they are applied to. | + | |Symbol|Meaning (Syntax)|Example| |
+ | |**+**|OR|' | ||
+ | |**|**|OR (Alternative)|' | ||
+ | |**& | ||
+ | |**NOT**|Negation|' | ||
+ | **'/ | ||
- | {{: | + | ===== Pipeline Command ===== |
- | ==== Pipeline Command ==== | + | The command below is as seen on the Visual3D |
- | + | ||
- | The pipeline | + | |
< | < | ||
Line 29: | Line 38: | ||
! /QUERY= | ! /QUERY= | ||
! / | ! / | ||
- | ; | ||
</ | </ | ||
- | === File_Name | + | ===== Command Parameters ===== |
- | The parameter **/ | + | The following table shows the command parameters and descriptions. |
- | **Note:** Visual3D defines | + | |**Parameter**|**Description**| |
+ | |**! / | ||
+ | |**! / | ||
+ | |**! / | ||
- | < | + | ===== Dialog ===== |
- | Select_Active_File | + | |
- | /FILE_NAME= file1.c3d | + | |
- | ; | + | |
- | </ | + | |
- | To fix the example above, you define | + | There is no dedicated dialog box for this command. The GUI equivalent is manually selecting |
- | < | + | {{:visual3d: |
- | Select_Active_File | + | |
- | /FILE_NAME= c:\data\session1\file1.c3d | + | |
- | ; | + | |
- | </ | + | |
- | or you can use a wildcard: | + | This command is primarily used in pipeline scripts and batch processing workflows to automate file selection. |
- | < | + | ===== Examples ===== |
- | Select_Active_File | + | |
- | /FILE_NAME= *file1.c3d | + | |
- | ; | + | |
- | </ | + | |
- | or you can specify a TAG: | + | The following examples will go through the use of the Select_Active_File command in the Visual3D application. |
+ | |||
+ | === Example 1: Select the Global Workspace === | ||
+ | |||
+ | Use this when working with signals that were computed across multiple trials. These signals are not associated with a specific file, and so they live in the Global Workspace. | ||
< | < | ||
Select_Active_File | Select_Active_File | ||
- | / | + | /FILE_NAME=GLOBAL |
+ | ! /QUERY= | ||
+ | ! / | ||
; | ; | ||
</ | </ | ||
- | === Query === | + | === Example 2: Select trials based on tags (OR condition) |
- | The Query option (**Visual3D Professional Only**) allows | + | Say that you've tagged trials |
- | + | ||
- | / | + | |
- | + | ||
- | === Subject_Tags === | + | |
- | + | ||
- | Set the active subject tag - FOR MULTISUBJECT ONLY! | + | |
- | + | ||
- | ==== Example 1: Global_Workspace ==== | + | |
- | + | ||
- | This example shows how to make the [[Visual3D: | + | |
< | < | ||
Select_Active_File | Select_Active_File | ||
- | /FILE_NAME=GLOBAL | + | /FILE_NAME=ALL_FILES |
- | ! /QUERY= | + | /QUERY=WALK + RUN |
+ | ! / | ||
; | ; | ||
</ | </ | ||
- | ==== Example 2 - ALL_FILES and OR Query ==== | + | Or equivalently: |
- | + | ||
- | From ALL_FILES select files that are tagged TAG1 or TAG2. Note there are multiple syntaxes for the " | + | |
- | + | ||
- | Using the " | + | |
< | < | ||
Select_Active_File | Select_Active_File | ||
/ | / | ||
- | /QUERY=TAG1 + TAG2 | + | /QUERY=WALK | RUN |
+ | ! / | ||
; | ; | ||
</ | </ | ||
- | Using " | + | === Example 3: Select trials with one tag AND NOT another === |
+ | Suppose you want to select all running trials that are not tagged | ||
< | < | ||
Select_Active_File | Select_Active_File | ||
/ | / | ||
- | /QUERY=TAG1 | TAG2 | + | /QUERY=RUN & NOT(FATIGUE) |
+ | ! / | ||
; | ; | ||
</ | </ | ||
- | ==== Example | + | === Example |
- | From ALL_FILES select files that are TAG1 AND NOT TAG2 using the operators "&" | + | Assuming you've tagged subjects as ' |
< | < | ||
Select_Active_File | Select_Active_File | ||
/ | / | ||
- | /QUERY=TAG1 & NOT(TAG2) | + | ! /QUERY= |
+ | / | ||
; | ; | ||
</ | </ | ||
- | ==== Example 4 - ALL_FILES and a wildcard ==== | ||
- | From ALL_FILES select files that do not contain the wildcard *run*.c3d | + | === Example 5: Exclude specific filename patterns using tagging === |
- | This cannot be done in one step. Command will be used to tag the files prior to using the Select_Active command. | + | If you want to exclude trials with " |
< | < | ||
+ | ! Tag only the files NOT containing " | ||
! Assign tag RUN to files with " | ! Assign tag RUN to files with " | ||
Assign_Tags_To_Files | Assign_Tags_To_Files | ||
Line 147: | Line 143: | ||
/ | / | ||
! /QUERY= | ! /QUERY= | ||
- | ; | ||
</ | </ | ||
+ | |||
+ | ===== Notes ===== | ||
+ | * Use this command any time your pipeline depends on file-specific operations in a multi-file workspace. | ||
+ | * Tags are assigned using the Assign_Tags_To_Files command and must be added before using '/ | ||
+ | * Use '/ | ||
+ | * To select files by exclusion (e.g. " | ||
+ | |||
+ | ---- | ||
[[Visual3D: | [[Visual3D: |
visual3d/documentation/pipeline/file_commands/select_active_file.1753129263.txt.gz · Last modified: 2025/07/21 20:21 by wikisysop