Agent to run Python snippets in a mamba shell environment.
Input
File or folder
Output
File or folder
Configuration
params
dynamic
[object Object]
env
YAML configuration of the conda environment
yaml_code_param
name: .venv
channels:
- conda-forge
dependencies:
- python=3.10
- pandas==2.2.2
- numpy==1.26.4
code
The Python code snippet to execute using shell command
python_code_param
# This is a snippet template for a Python agent.
import pandas
# Do the job here ...
data = pandas.read_csv(source_paths[0], header=0, index_col=0, sep=',')
# transform the data
result = data.transpose()
# Write the output file in the target folder
result_path = "result.csv"
result.to_csv(result_path, index=True)
target_paths = [result_path]