Skip to main content

MagNet Toolkit - Certified Models of the MagNet Challenge

Project description

MagNet Toolkit

Certified Models of the MagNet Challenge

Lint and Test

This repository acts as a hub for selected power loss models that were elaborated by different competitors during the MagNet Challenge 2023. Feel free to use these loss models for your power converter design as a complement to your datasheet.

The loss models are designed such that you can request a certain frequency, temperature, material and $B$ wave (sequence), in order to be provided with a scalar power loss estimate and a corresponding $H$ wave estimate.

Disclaimer: Only steady-state and no varying DC-Bias is supported yet. Moreover, training data stemmed from measurements on toroid-shaped ferrites that had a fix size.

Supported materials:

  • ML95S
  • T37
  • 3C90
  • 3C92
  • 3C94
  • 3C95
  • 3E6
  • 3F4
  • 77
  • 78
  • 79
  • N27
  • N30
  • N49
  • N87

Installation

Python

We strongly recommend Python 3.10. Higher versions may also work.

Then install through pip:

pip install mag-net-hub

or, alternatively, clone this repo and execute

cd mag-net-hub
pip install .

Usage

Models are provided as executable code with readily trained coefficients. Hence, no training is conducted in this project.

Python

import numpy as np
import magnethub as mh

# instantiate material-specific model
mdl = mh.loss.LossModel(material="3C92", team="paderborn")

# dummy B field data (one trajectory with 1024 samples)
b_wave = np.random.randn(1024)* 200e-3  # in T
freq = 124062  # Hz
temp = 58  # °C

# get power loss in W/m³ and estimated H wave in A/m
p, h = mdl(b_wave, freq, temp)

# batch execution for 100 trajectories
b_waves = np.random.randn(100, 1024)* 200e-3  # in T
freqs = np.random.randint(100e3, 750e3, size=100)
temps = np.random.randint(20, 80, size=100)
p, h = mdl(b_waves, freqs, temps)

Contributing

Whether you want to contribute your submission to the MagNet Challenge, or you are a single contributor who wants to add an awesome model to this hub -- any contribution is welcome.

Open a pull request to directly suggest small improvements to the infrastructure or to add your model (with performance statistics preferred). For larger suggestions, please first open an issue or go to the discussion section to discuss your ideas.

See the below folder structure overview with annotations on how to contribute a model.

.
├── src_py
│   └── magnethub
│       ├── __init__.py
│       ├── loss.py
│       ├── models
│       │   ├── paderborn
│       │   │   ├── changelog.md
│       │   │   ├── cnn_3C90_experiment_1b4d8_model_f3915868_seed_0_fold_0.pt
│       │   │   ├── cnn_3C92_experiment_ea1fe_model_72510647_seed_0_fold_0.pt
|       |   |   └──  ...
│       │   ├── sydney
│       │   │   └── ...
│       │   └── <add your contributor folder here>
│       │   │   └── <add your model coefficients here>
│       ├── paderborn.py
|       ├── sydney.py
|       ├── <add your model code here>

Any number of models can be incorporated easily according to this code structure policy. If you have added model coefficients and execution logic via code, it only requires to be hooked in loss.py and you are ready to fire this pull request (PR).

If it is possible, please also consider adding tests for your model logic under tests/, writing comprehensive docstrings in your code with some comments, and discuss the performance of your model in your PR.

Other open ToDos are:

  • Matlab implementation
  • improve documentation

Thank you!

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

mag_net_hub-0.0.11.tar.gz (1.3 MB view details)

Uploaded Source

Built Distribution

mag_net_hub-0.0.11-py3-none-any.whl (634.6 kB view details)

Uploaded Python 3

File details

Details for the file mag_net_hub-0.0.11.tar.gz.

File metadata

  • Download URL: mag_net_hub-0.0.11.tar.gz
  • Upload date:
  • Size: 1.3 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.19

File hashes

Hashes for mag_net_hub-0.0.11.tar.gz
Algorithm Hash digest
SHA256 35b5224f66a23337361e9b820535e3bf85f517dd638cb50b5a6afdcf8805deec
MD5 5975981be7970daf689f55dd8a8d7208
BLAKE2b-256 072933e487f54a949637a7cda93efcff25cf5aaf269f3969d47cdb69dd46d99a

See more details on using hashes here.

File details

Details for the file mag_net_hub-0.0.11-py3-none-any.whl.

File metadata

  • Download URL: mag_net_hub-0.0.11-py3-none-any.whl
  • Upload date:
  • Size: 634.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.19

File hashes

Hashes for mag_net_hub-0.0.11-py3-none-any.whl
Algorithm Hash digest
SHA256 faa9d1832353c2316d01da2a3c22b9d8f29a64a9cf5d6c3c642905ebca9847ff
MD5 e4cff60e8d70baf3ef175be83a836bbf
BLAKE2b-256 29931f9509d5b47d5ba68b8ba34912a1c12d1079b28dcdd511d5eb59e1ec7d5c

See more details on using hashes here.

Supported by

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