7.1. Overview


The nextnanoevo Python package is under development. Its release is planned for 2024.

7.1.1. About

The nextnanoevo Python package is interfacing minimization and evolution algorithms with our other tools nextnano++, nextnano³, and nextnano.NEGF. The package takes care of proper execution of simulations for optimization algorithms and definitions of problems to optimize based on standard nextnano GmbH outputs.

The user can choose between optimization algoritms from scipy.optimize and PyGMO:

  • SciPy.optimize contains set of deterministic optimization algorithms to solve root and minimization problems. You can visit the documentation here.

  • PyGMO is a Python library developed by F. Biscani and D. Izzo [Biscani2020]. It is an interface facilitating implementation of various evolutionary algorithms such as evolution strategies or genetic algorithms. It can be used to solve many kinds of single- and multi-objective problems.

We recommend using SciPy algorithms to solve simple single-objective problems, while PyGMO is more suited for multi-objective problems as well as for problems that have convergence issues with deterministic algorithms.

7.1.2. Purpose

For example, one want to study an LED with a goal to maximize quantum efficiency (QE). Let’s assume that someone start with a design having the QE of 4 %. To improve it, one needs to provide the algorithm with information about which parts of the device can be modified (for instance certain lengths or mole fractions) and input the limits of these parameters which should depend on what is experimentally feasible. Then, the algorithm runs maximizing the quantum efficiency after which a new design yielding higher theoretical efficiency of 50 % is found.

7.1.3. Requirements

To run the nextnanoevo module, you need to:

7.1.4. Installation

We recommend installing nextnanoevo with conda package manager. Installation without conda using different python distributions is possible if requirements above are met (but not tested).

Installation with conda.

1. Install Anaconda or Miniconda (miniconda is a lightweight version that install only the minimum necessary liabraries). Run following commands in the Anaconda Prompt. 2. Create and new conda environment with python 3.10

$ conda create -n nnevoEnv python=3.10
  1. Activate newly created conda environment

    $ conda activate nnevoEnv
  2. Install pygmo (this step might take few minutes)

    $ conda config --add channels conda-forge
    $ conda config --set channel_priority strict
    $ conda install pygmo
  3. Install nextnanoevo into the activated environment with installation script

    $ path/to/nextnanoevo/install.bat

7.1.5. License activation

The license is activated in the same way as other products, for more details visit License activation page

7.1.6. Config setup

In order to use nextnanoevo, at least 2 products should be set up in nextnanopy config.

  • nextnanoevo itself (license option only)

  • nextnano product you want to use it with. For example, for nextnano++ you need to set up license, exe, database and output directory

To set up nextnanoevo license, run the following script.

import nextnanopy as nn
nn.config.set('nextnanoevo', 'license', 'path\to\your\License_nnevo.lic')

Tutorial on how to set up other nextnano product can be found here - Tutorial 0 - Set up the configuration.