Esacode

Docs / Blocks / Data

Select files

Keeps the files a table selects, such as those an agent labelled keep.

Runs on a worker (Python) Data Version 1.0 Code you can open and adapt

How it works

Connect the files and a table that names them (for example the Agent's decisions). The files whose row matches (by default label = keep) go to the output, copied on the worker, ready for Save as dataset. Match column: the table column with the file name or path.

Inputs

InputTakesWhat it is
Files
files
Files Takes several connections.
Table
table
Table
csv, tsv, jsonl
A table with a path column (and, for example, a label column to keep)

Outputs

OutputGivesWhat it is
Selected
files
Files
Not selected
rest
Table
csv
Live telemetry
telemetry
Live telemetryWhat the block sends while it runs, for views such as Chart or 3D view.

Settings

SettingDefaultWhat it does
Match column
match
item
Column to test
column
label
Keep when it is
values
keep Values separated by commas

Where it runs

On one of your computers with the EsaSim worker: Any worker.

In its code, settings are ctx.params["key"], inputs ctx.inputs["id"] and outputs ctx.output("id", "name.ext"); see Custom blocks.

More in Data