Last update: 2024-02-08

This workshop is part of the ABM4Energy conference in Freiburg, Germany. It is planned for March 22nd 2024.

Agenda

Time (CET) Program
10:50-11:10 Basics on AMIRIS' Agents
11:10-11:25 Installation and Execution
11:25-11:50 Result Analysis
11:50-12:20 Parameter Variations
12:20-12:30 Documentation

Requested Preparations

AMIRIS requires Java JDK 11 or above, and Python version 3.9. AMIRIS operates on Windows, Linux and Mac.

In order to avoid waiting times for downloads and installation processes during the workshop, we ask all participants to check if their system meets these requirements.

Check Java

You can test if you have a JDK by using the command java --version (or java -version on some systems). This should show your Java version if Java was found. If you get a command not found error, or if Java version is less than 11 please download and install a recent JDK from e.g. here.

Check Python

You can test if you have Python available by using the command python --version. This should show your Python version if the Python command was found. Note that if you use a Python environment manager you can have several Python versions on your system side by side. If you do not have Python installed on your system, you may use e.g. conda or mamba.

Installation

You are free to try out your system by installing AMIRIS following these simple steps.

Set up Python Environment

In case you do not have any experience with creating a Python environment, we recommend to use anaconda. Install anaconda, start the anaconda prompt or powershell and enter:

  1. conda create -n amirisEnv python=3.9
  2. conda activate amirisEnv

In case you are using mamba, simple replace “conda” in the first command with “mamba” (but not in the second command).

Get AMIRIS-Py

We recommend to use AMIRIS-Py. AMIRIS-Py provides “one-command” installation and execution scripts, but you may also run AMIRIS using FAME scripts (see here).

In your AMIRIS Python environment (called “amirisEnv” above), run

pip install amirispy

Setup with AMIRIS-Py

  1. Create a new folder on your disk called, e.g., “AMIRIS”: mkdir <AMIRIS>
  2. Open your Python-enabled shell and navigate to this newly created folder: cd <AMIRIS>
  3. If not done yet, activate your Python environment with amiris-py: conda activate <amirisEnv>
  4. Download the latest AMIRIS build: amiris install.

This should have downloaded the latest AMIRIS model and the latest version of AMIRIS examples into the current folder. See the files in the folder - it should contain a file called “amiris-core_<x.y.z>-jar-with-dependencies.jar”, where <x.y.z> stands for the latest published version. Use this filename in the upcoming call to amiris run.

Run AMIRIS with AMIRIS-Py

Use amirispy again to run AMIRIS:

amiris run -j ./amiris-core_<x.y.z>-jar-with-dependencies.jar -s ./examples/Simple/scenario.yaml -o simple

This runs the packaged AMIRIS Java archive (Jar) file specified after the -j option and simulates the scenario specified after the -s option. Outputs of the simulation are stored in a folder as designated after the -o option. You should see some output messages stating that the scenario was compiled, AMIRIS ran, and that results were extracted.

If you experience any difficulties, do not hesitate to contact us.