These instructions will guide you through the process of setting up Efemarai. To setup and successfully run Efemarai you need a *nix based operating system, Python 3, and Chromium or Chrome.

1. Create Account

Go to our sign up page and create an account.

2. Set License Token

Copy your license token from the License section and set it as an environment variable. You might want to put this line in your shell config file in order to have the token permanently available (do not forget to source the file), not just for the current terminal session .

export EFEMARAI_LICENSE_TOKEN=<your-license-token>

3. Install Python Package

Install the Efemarai Python package.

pip install efemarai \
  --extra-index-url https://${EFEMARAI_LICENSE_TOKEN}

4. Start Efemarai Daemon

To use Efemarai you need to first run the daemon. Running the daemon locally ensures that none of your data, code or models leave your computer. Make sure that the EFEMARAI_LICENSE_TOKEN environment variable is available and set correctly. Once the daemon is running you can run your code (which uses the Efemarai Python package) from any other terminal and you will be able to explore the corresponding visualization from the Efemarai web platform.


5. Launch Efemarai

Go to the Efemarai launch page and click the LAUNCH button. Make sure to use Chromium or Google Chrome as they are the only supported browsers due to their advanced WebGL capabilities required by Efemarai.

Inspect a Tensor

As a quick example, run the following Python script.

import numpy as np
import efemarai as ef

tensor = np.random.rand(3, 4, 5)

You should be able to see your first visualized tensor in the browser! Simply press v and you should see something similar to the image below.

You can navigate within the 3D view with Shift + LeftMouse to rotate, Shift + RightMouse to translate and Scroll to zoom in or out. If what you see after running the example script is not similar to the image below make sure to consult the Troubleshoot section.

Visualize a Computational Graph

As another example, you can explore the computational graph of a CNN being trained on the CIFAR 10 dataset. Just run the demo that comes with the Efemarai Python package


With a few clicks on the function nodes (blue cubes) you should be able to see something like this.

6. Use Efemarai in Your Code

You need to do two simple things to visualize your model. Import the efemarai module and wrap your model computations in a with ef.scan(): statement. For instance:

import torch
# Do not forget the import
import efemarai as ef

dataset = load_dataset(...)
model = load_resnet18(...)

for data, target in dataset:
     # Pause execution & visualize computational graph
     with ef.scan():
         output = model(data)
         loss = F.cross_entropy(output, target)

Next Steps

Now that you are all set to use Efemarai here are a few resources that provide a deeper dive into Efemarai’s features and functionality.

owl user guide

In-depth walk-through over Efemarai’s features.

api reference icon

Complete reference of the Efemarai Python API.