Logo vun Dpnp Linalg Fft

Dpnp Linalg Fft

Organisatioun
intel
dpnp-linalg-fft

Linear algebra and FFT with dpnp on Intel CPUs and GPUs, backed by oneMKL. Use when a matrix multiply, solve, decomposition, eigenvalue problem, or Fourier transform is the hot part of NumPy code, when the user asks whether dpnp covers a linalg or FFT call, when an FFT result differs slightly from NumPy's, or when a large transform runs out of device memory. Covers the supported surface, transform sizing and plan reuse, fallbacks for what is missing, and how to check conditioning before solving.

Iwwersiicht

Editeurintel
Repositoryskills
Skill-Nummdpnp-linalg-fft
Stären
31
Forks
14
Matgeliwwert Fichieren
2
LizenzApache-2.0
Linken
  • Instruktiounen am Markdown-Format

    Eng SKILL.md-Datei, déi de Modell bei Bedarf luet, soudatt nëmmen Token ufalen, wann eng Ufro tatsächlech dozou passt.

  • Funktionéiert mat all LLM

    KI-Skills si reng Markdown, keen ubidderspezifesche Code. Dofir funktionéiert dëse Skill mat GPT, Claude, Gemini, Grok oder engem lokale Modell.

  • 2 matgeliwwert Dateien

    Skripten, Virlagen a Referenzen, déi de Modell beim Schaffe liese kann. D'Dateie kënnen nëmme gelies ginn a ginn ni ausgeféiert.

  • Open Source

    Vum intel op GitHub verëffentlecht. Liest de Quelltext, ier Dir de Skill installéiert.

Installatioun

Installéiert de KI-Skill Dpnp Linalg Fft an TypingMind, fir e mat all LLM ze benotzen, oder füügt en an en anere KI-Agent an, deen SKILL.md liest.

1

An TypingMind installéieren

TypingMind installéiert e Skill direkt aus sengem GitHub-Dossier — dobäi gëtt SKILL.md gelies, d'Ressourcedateie gi gebëndelt an d'Resultat gëtt lokal gespäichert.

  1. Maacht d'App op a gitt op Plugins → Skills.
  2. Wielt „Vun GitHub installéieren“.
  3. Pecht d'URL vum Skill-Dossier hei drënner an a bestätegt.
    https://github.com/intel/skills/tree/main/skills/dpnp-linalg-fft
  4. Aktivéiert de Skill an all Chat, an deem Dir e benotze wëllt.
Plugins → Skills → Skill afügen → Vu GitHub-URL, pecht dann d'URL vum Dossier an a klickt op Weider.
2

An engem anere KI-Agent installéieren

All KI-Agent, deen d'Format Agent Skills liest, kann dëse Skill benotzen — kopéiert den Dossier an de Skill-Verzeechnes vun deem KI-Agent.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/intel/skills.git /tmp/skills
mkdir -p .claude/skills
cp -r /tmp/skills/skills/dpnp-linalg-fft .claude/skills/dpnp-linalg-fft
Start Claude Code nom Kopéieren nei, fir datt den neie Skill erkannt gëtt.

An TypingMind benotzen

Aktivéiert Dpnp Linalg Fft an engem Chat vun TypingMind, an de Modell iwwerhëlt de Rescht. Den Numm an d'Beschreiwung stinn am System-Prompt. Soubal eng Ufro dozou passt, luet de Modell déi komplett Instruktioune selwer — Dir musst de Skill ni manuell opruffen, an et fale keng Token un, bis en tatsächlech benotzt gëtt.

De Modell luet Dpnp Linalg Fft automatesch, soubal eng Ufro dozou passt.

Funktionéiert mat all KI-Modell

KI-Skills si reng Markdown-Instruktiounen amplaz vun ubidderspezifeschem Code. Dofir ass Dpnp Linalg Fft net un de Modell gebonnen, fir deen de Skill geschriwwe gouf. Installéiert en eemol an TypingMind a benotzt e mat GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama oder engem lokale Modell, deen Dir selwer bedreift — alles mat Ären eegenen API-Keys.

  • Gëtt nëmme gelueden, wann et néideg ass

    De System-Prompt enthält nëmmen den Numm an d'Beschreiwung. D'Instruktioune gi bei der éischter passender Ufro gelueden, soudatt en onbenotzte Skill näischt kascht.

  • De Modell am lafende Chat wiesselen

    Well de Skill aus Instruktiounen amplaz vu Code besteet, funktionéiert en och no engem Modellwiessel — den nächste Modell liest déi selwecht SKILL.md-Datei.

Skill-Instruktiounen

Dëst ass den Inhalt vu SKILL.md, deen de Modell luet. Liest e virun der Installatioun — e Skill besteet aus Instruktiounen, déi Äre Modell befollegt.

dpnp linear algebra and FFT

Purpose

Routes linear algebra and Fourier transforms through dpnp, which dispatches them to oneMKL on Intel CPUs and GPUs. Covers what the API includes, how to size and warm a transform, what is not implemented and how to fall back to SciPy for it, and which numerical differences from NumPy are expected rather than bugs.

Prefer this skill when matrix or transform work is the expensive part of a NumPy program. Prefer plain NumPy for small operands, where the dispatch cost is not amortized, and SciPy for sparse problems, which have no dpnp equivalent.

When to Use This Skill

Use this skill when:

  • A matmul, solve, decomposition, or eigenvalue problem is the hot path.
  • An FFT or a convolution through FFT is the hot path.
  • The user needs to know whether dpnp implements a specific linalg or FFT call.
  • An FFT or a decomposition disagrees with NumPy in the last digits.
  • A large transform fails on device memory.

Do not use this skill for sparse linear algebra (scipy.sparse, on host arrays), for small operands, or as a source of speedup figures — there are none here on purpose.

Quick Start

python
import dpnp as np

A = np.random.randn(1000, 1000)
B = np.random.randn(1000, 1000)
C = A @ B                      # matmul, dispatched to oneMKL
x = np.linalg.solve(A, B)      # linear system

_ = np.fft.fft(np.zeros(1024))       # warm the plan for this size first
spectrum = np.fft.fft(np.random.randn(1024))

real_spectrum = np.fft.rfft(np.random.randn(2048))   # output length 1025

Implementation Guide

  1. Use the surface that exists. Matrix product as @, matmul(), or dot(); svd(), qr(), cholesky(); eig(), eigvals(), eigh(), eigvalsh(); solve(), lstsq(); inv(), det(), norm(), cond(), matrix_rank(); inner(), outer(), cross(). Prefer @ for readability and the function form when it has to be passed around. dot() and matmul() agree on 2-D and differ for higher rank.

  2. Batch instead of looping. The linalg functions take leading batch dimensions, so np.linalg.solve(A, B) with A.shape == (10, 100, 100) solves ten systems in one dispatch rather than ten.

  3. Pick the right transform. fft/ifft for complex input, rfft/irfft for real input (output length n // 2 + 1, exploiting conjugate symmetry), hfft/ihfft for Hermitian data, fft2/rfft2 for images, fftn/rfftn for higher rank, with fftfreq, rfftfreq, fftshift, and ifftshift as helpers. Using the real variants on real data halves the output.

  4. Size and warm transforms. A power-of-two length is the friendliest case; pad up to one when the trailing samples do not matter:

    python
    n_padded = 2 ** int(np.ceil(np.log2(n)))
    spectrum = np.fft.fft(np.pad(signal, (0, n_padded - n)))

    The first call on a new size pays for plan creation and compilation; subsequent calls on that size reuse it, with no explicit plan management.

  5. Check conditioning before solving, so a singular matrix produces an answer rather than an exception:

    python
    if np.linalg.cond(A) < 1e15:
        x = np.linalg.solve(A, b)
    else:
        x = np.linalg.lstsq(A, b, rcond=None)[0]
  6. Fall back deliberately for what is missing. Sparse problems, generalized eigenvalue problems, matrix functions such as expm, logm, sqrtm, and short-time transforms have no dpnp implementation. Convert, call SciPy, and convert back — once, at the boundary:

    python
    import scipy.linalg
    
    result = np.asarray(scipy.linalg.expm(np.asnumpy(A)))

    Verify coverage against the installed release rather than a remembered list: the set has grown between versions, and coverage can be per keyword argument.

Performance

No measured numbers ship with this skill, and none belong in it. What holds regardless of hardware:

  • There is a size below which dispatch dominates and NumPy is the better answer. Matrices in the hundreds of rows and transforms of a few hundred points are in that region; measure the actual shapes rather than adopting a threshold.
  • Compare a warmed-up run. The first call on a new shape includes compilation and plan creation, so timing it measures the wrong thing.
  • Real-input transforms do less work than complex ones on the same data.
  • Batched calls amortize dispatch that a Python loop pays per iteration.
  • A fallback to SciPy costs two transfers and host compute; count it in the end-to-end number, not just the call.

Gotchas & Limitations

  • Results are not bit-identical to NumPy. dpnp goes through oneMKL and NumPy through pocketfft or its own LAPACK; agreement is to within roundoff, and a comparison must use numpy.testing.assert_allclose, not equality.
  • Integer operands are not the fast path. Keep operands in float64 or complex128 unless there is a reason not to.
  • No sparse support at all. scipy.sparse on host arrays is the answer, not a dpnp equivalent.
  • Coverage claims expire. Any list of unimplemented functions is true of one release. Check dir(dpnp.linalg), dir(dpnp.fft), and the documentation for the installed version before telling a user something is missing.
  • Large transforms fail on device memory. Chunk the signal, or switch to a real-input transform; see dpnp-memory for capacity and chunking.

References

FileLoad it when
references/official-sources.mdyou need the linalg or FFT coverage of a specific dpnp release, the oneMKL routine behind a call, or the SciPy function to fall back to

Two questions here should never be answered from memory: which linalg and FFT functions the installed release implements (the list grows, and coverage can be per keyword argument) and which oneMKL routine backs a call, which is what explains a numerical difference from NumPy.

Matgeliwwert Fichieren

De Modell liest dës Dateie bei Bedarf, wärend de Skill gelueden ass. Si ginn als liesbar Dateie bereetgestallt a ginn ni ausgeféiert.

Heefeg gestallte Froen

Wat mécht de KI-Skill Dpnp Linalg Fft?

Linear algebra and FFT with dpnp on Intel CPUs and GPUs, backed by oneMKL. Use when a matrix multiply, solve, decomposition, eigenvalue problem, or Fourier transform is the hot part of NumPy code, when the user asks whether dpnp covers a linalg or FFT call, when an FFT result differs slightly from NumPy's, or when a large transform runs out of device memory. Covers the supported surface, transform sizing and plan reuse, fallbacks for what is missing, and how to check conditioning before solving.

Firwat Dpnp Linalg Fft op TypingMind benotzen?

Well Dir en eemol installéiert a mat all Modell benotze kënnt. Dpnp Linalg Fft besteet aus einfachem Markdown amplaz vun ubidderspezifeschem Code. Dee selwechte Skill funktionéiert also mat GPT-5, Claude, Gemini, Grok oder engem lokale Modell – an Dir kënnt de Modell matzen am Chat wiesselen, ouni datt de Skill ophält ze funktionéieren. TypingMind benotzt Är eegen API-Schlësselen, sou datt Dir d'Ubidder direkt bezuelt amplaz vun engem Abonnement pro Benotzerplaz. Är Skills a Chats bleiwen an Ärem eegene Späicher.

Wéi installéieren ech Dpnp Linalg Fft an TypingMind?

Maacht an TypingMind Plugins → Skills → Vu GitHub installéieren op a setzt https://github.com/intel/skills/tree/main/skills/dpnp-linalg-fft an. TypingMind liest d'Datei SKILL.md, bündelt déi zougehéiereg Dateien an installéiert dat Ganzt als Skill, deen Dir pro Chat aktivéiere kënnt.

Wéi eng KI-Modeller kënnen Dpnp Linalg Fft benotzen?

All Modell, deen Dir an TypingMind verbënnt. KI-Skills sinn einfach Markdown-Instruktiounen an net ubidderspezifesche Code. Dofir kënne GPT, Claude, Gemini, Grok a lokal Modeller dëse Skill lueden, wann eng Ufro dozou passt.

Wéi vill KI-Modeller kann ech mat Dpnp Linalg Fft benotzen?

Esou vill Dir wëllt. Soulaang e Modell Skills ënnerstëtzt, kënnt Dir Dpnp Linalg Fft domat benotzen – GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama a méi – alles op TypingMind mat Ären eegenen API-Schlësselen.

Ass de KI-Skill Dpnp Linalg Fft gratis?

Jo. De Skill gëtt vum intel ënner der Lizenz Apache-2.0 op GitHub publizéiert. Dir bezuelt nëmmen Ären eegene KI-Ubidder fir d'Token, déi Dir benotzt.

Wat si KI-Skills?

E KI-Skill ass e weiderverwendbaart Pak vun Instruktiounen, dat engem KI-Modell bäibréngt, wéi en eng bestëmmt Aufgab erfëllt. E follegt dem oppenen Agent Skills-Format: eng Datei SKILL.md mat engem Numm an enger Beschreiwung, plus all Scripten, Virlagen oder Referenzdateien, déi de Modell eventuell brauch. De Modell liest d'Instruktiounen eréischt, wann Är Ufro zum Skill passt. En installéierte Skill kascht also näischt, bis e benotzt gëtt.

Wéi ënnerscheede sech KI-Skills vu Plugins oder MCP-Serveren?

E Plugin oder MCP-Server gëtt engem Modell nei Tools, déi en opruffe kann – Code, deen iergendwou leeft an e Resultat zeréckgëtt. E KI-Skill gëtt dem Modell dogéint Wëssen an eng Virgoensweis: wéi en eng Aufgab ugeet, wéi eng Schrëtt en nokënnt a wéi eng gutt Ausgab ausgesäit. Skills bestinn aus einfachem Markdown, brauche kee Server, keen API-Schlëssel a keng Lafzäitëmfeld a funktionéiere mat all Modell.

All weisen

Elo Ären eegene KI-Workspace ariichten

Abonnéiert Iech op eisen Newsletter, fir iwwer nei Funktiounen an zukünfteg Gewënnspiller informéiert ze ginn 👇