Skip to main content

Benchmarks library, based on a software product teneva, for tensor based multidimensional approximation and optimization methods

Project description

teneva_bm

Description

Benchmarks library, based on a software product teneva, for tensor based multidimensional approximation and optimization methods. Benchmarks include both multidimensional data arrays and discretized functions of many variables.

Installation

Current version "0.1.0".

The package can be installed via pip: pip install teneva_bm (it requires the Python programming language of the version >= 3.8). It can be also downloaded from the repository teneva_bm and installed by python setup.py install command from the root folder of the project.

Required python packages matplotlib (3.7.0+) and teneva (0.14.0+) will be automatically installed during the installation of the main software product.

Some benchmarks require additional installation of specialized libraries. The corresponding instructions are given in the description of each benchmark (see DESC string in the corresponding python files). Installation of all required libraries for all benchmarks can be done with the following command:

pip install networkx==3.0 qubogen==0.1.1 gekko==1.0.6

Documentation and examples

All benchmarks inherit from the Bm base class (teneva_bm/bm.py) and are located in the teneva_bm folder. The corresponding python files contain a detailed description of the benchmarks, as well as a script for a demo run at the end of the file. You can run demos for all benchmarks at once with the command python demo.py from the root folder of the project.

A typical scenario for working with a benchmark is as follows:

import numpy as np
from teneva_bm import *
np.random.seed(42)

# Prepare benchmark and print info:
bm = BmQuboMaxCut().prep()
print(bm.info())

# Get value at multi-index i:
i = np.ones(bm.d)
print(bm[i])

# Get values for batch of multi-indices I:
I = np.array([i, i, i])
print(bm[I])

# Generate random train dataset:
I_trn, y_trn = bm.build_trn(1000)

Authors

✭__🚂 The stars that you give to teneva_bm, motivate us to develop faster and add new interesting features to the code 😃

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

teneva_bm-0.1.0.tar.gz (19.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

teneva_bm-0.1.0-py3-none-any.whl (35.1 kB view details)

Uploaded Python 3

File details

Details for the file teneva_bm-0.1.0.tar.gz.

File metadata

  • Download URL: teneva_bm-0.1.0.tar.gz
  • Upload date:
  • Size: 19.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.16

File hashes

Hashes for teneva_bm-0.1.0.tar.gz
Algorithm Hash digest
SHA256 49c971954c8bb513a19204474c393ddfdaebe432054e419f16059a8e2a9f453d
MD5 10318ebb3a0827c16a52f107a7117918
BLAKE2b-256 368864f199a9ee2471b60935234f421f5e31cdeb87d6f4f2a6b2ea10a20fd2ce

See more details on using hashes here.

File details

Details for the file teneva_bm-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: teneva_bm-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 35.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.16

File hashes

Hashes for teneva_bm-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b019a805967178e67ff7e69f34204d8c38de3b9def4fdefadc774e8d8f0970dd
MD5 a2acff077cae949323993396fb8b87f3
BLAKE2b-256 78e09f4f6eb30186e8cfcb8cb7e092f747876a3de4c01c80b05ce3568ef515f0

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page