Skip to main content
Solved

Using Metis M.2 for matrix operations

  • April 16, 2025
  • 6 replies
  • 138 views

Hi,

I know Metis can be used for ML etc. but wondering whether it’s suitable to do some more low-level operations like big matrix multiplication, FFT of data stored in Metis memory etc. - more like on CUDA (some DSP/Math library)? I assume I could use torch basic math functions?
 

Dominik 

Best answer by Spanner

Great question! And it’d be amazing to see someone create a project like this.

It’s possible to do general-purpose matrix multiplication on Metis, yep, but it needs to be framed as part of a neural network forward path and deployed as an ONNX model using the Gemm operator. It’s not a CUDA-style setup where you can run arbitrary math on memory directly—everything goes through the model deployment pipeline.

There’s a bit more info in the Gemm section of this doc: 

👉 https://github.com/axelera-ai-hub/voyager-sdk/blob/release/v1.2.5/docs/reference/onnx-opset14-support.md#gemm

Did you have a specific project or use-case in mind, ​@DominikD ?

6 replies

Spanner
Axelera Team
Forum|alt.badge.img+3
  • Axelera Team
  • Answer
  • April 16, 2025

Great question! And it’d be amazing to see someone create a project like this.

It’s possible to do general-purpose matrix multiplication on Metis, yep, but it needs to be framed as part of a neural network forward path and deployed as an ONNX model using the Gemm operator. It’s not a CUDA-style setup where you can run arbitrary math on memory directly—everything goes through the model deployment pipeline.

There’s a bit more info in the Gemm section of this doc: 

👉 https://github.com/axelera-ai-hub/voyager-sdk/blob/release/v1.2.5/docs/reference/onnx-opset14-support.md#gemm

Did you have a specific project or use-case in mind, ​@DominikD ?


  • Author
  • Cadet
  • April 16, 2025

My idea is to do some basic image processing on the edge device, where I have multiple images (not a video) taken, where each image might be shifted a bit (camera was moved a bit) and would like to have a one crispy by aligning these images and do some kind of multi-frame image averaging.


Thanks for the link ​@Spanner :) Will have a look.


Spanner
Axelera Team
Forum|alt.badge.img+3
  • Axelera Team
  • April 16, 2025

Fascinating! So combining multiple, possibly misaligned or blurred or imperfect images to create one that harnesses the best of all, to produce a high quality image?

Very cool! Keep us posted on that - would love to see it in action one day! How much progress have you made on it so far?


  • Author
  • Cadet
  • April 16, 2025

Fascinating! So combining multiple, possibly misaligned or blurred or imperfect images to create one that harnesses the best of all, to produce a high quality image?

Yes, this way we can have (should have ;) ) a much better image. So far, it's in an early development stage. Therefore, looking for options and using your chip popped up as one of the potential options.


Spanner
Axelera Team
Forum|alt.badge.img+3
  • Axelera Team
  • April 16, 2025

This is a cool idea, and not one I’ve heard anyone talking about, so you might well be on to something there! Keep us all posted ​@DominikD!

(By the way, once you’ve found what you need, please hit the “best answer” button to close your question 👍 No rush to do so, if there’s more to come - but when you’re ready 🙂)


jaydeep.de
Axelera Team
  • Axelera Team
  • April 16, 2025

@DominikD Fascinating application indeed! Try to formulate it as a Neural network operation with a forward pass problem. Some pointers could be looking at the FFT as a convolution operation as well.  Then you can use our device to run them more efficiently. Keep us posted. Cheers!