OpenSees Virtual Machine

Version 3.8.0.2 on Amazon Linux 2023. Tcl and Python are already installed. This image does not run Jupyter.

What is installed

  • Tcl: OpenSees and openseesmp (the same OpenSeesMP binary)
  • Python 3.12: import openseespy.opensees
  • MPI: MPICH 5.0.2, command mpiexec
  • Python packages: numpy, scipy, pandas, matplotlib

Use python3.12. The python3 command is Python 3.9 and does not include OpenSeesPy.

Launch

  1. In the EC2 console, choose the region closest to you. This product is not offered in eu-south-1 (Milan).
    EC2 region menu with United States (N. Virginia) selected. Milan is not in the enabled region list.
  2. Choose Launch instance, then Browse more AMIs. On the AWS Marketplace tab, search for OpenSees and select OpenSees Virtual Machine, version 3.8.0.2.
    AMI catalog search results for OpenSees Virtual Machine version 3.8.0.2.
    Selected OpenSees Virtual Machine 3.8.0.2 AMI from the AWS Marketplace catalog.
    The catalog may list the username as root. Sign in as ec2-user.
  3. Choose an instance type from the T3, M5, or C5 series. Other types are rejected at launch. c5.large is the recommended size.
    Instance type set to c5.large, the size recommended for this AMI.
  4. Create or select a key pair and save the private key.
    Key pair name selected on the launch instance page.
  5. Allow inbound TCP port 22 (SSH) from your IP. Leave HTTP and HTTPS unchecked.
    Security group allowing SSH from My IP, with a 40 GiB gp3 root volume.
  6. The root volume is 40 GiB, as shown above. Increase it if the analysis will write large files.
  7. Launch the instance and copy its public IPv4 address.
    Success message after launching the instance.
    Instance summary showing the public IPv4 address.

The software price is an hourly charge on top of the EC2 instance price. The total is shown before you launch. Stop the instance when you are not using it. A stopped instance keeps the disk and stops the hourly software charge. The public IP changes on the next start unless you attach an Elastic IP.

Connect

Log in as ec2-user.

ssh -i awskey.pem ec2-user@PUBLIC_IP
SSH login as ec2-user on Amazon Linux 2023.

Copy a script to the instance, then copy results back.

scp -i awskey.pem script.py ec2-user@PUBLIC_IP:~
scp -i awskey.pem ec2-user@PUBLIC_IP:~/results.out .
Copying a script to the instance and copying a result file back.

Run Tcl

OpenSees script.tcl
mpiexec -np 4 OpenSees script.tcl
OpenSees running script.tcl and printing the node displacement.
mpiexec running OpenSees script.tcl on 4 processes.

openseesmp is the same program as OpenSees.

Run Python

python3.12 script.py
mpiexec -np 4 python3.12 script.py
python3.12 script.py printing OpenSeesPy version 3.8.0.2.
mpiexec running the Python script on 4 processes, each printing version 3.8.0.2.

A script starts with:

import openseespy.opensees as ops
print(ops.pyversion())

That prints 3.8.0.2.

Support

Help with launching this instance: contact@openseescloud.com. OpenSees modeling support is not included.