Logo di Dpnp Linalg Fft

Dpnp Linalg Fft

Organizzazione
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.

Panoramica

Pubblicato daintel
Repositoryskills
Nome della skilldpnp-linalg-fft
Stelle
31
Fork
14
File inclusi
2
LicenzaApache-2.0
Link
  • Istruzioni in Markdown

    Un file SKILL.md che il modello carica quando serve, consumando token solo quando una richiesta è effettivamente pertinente.

  • Funziona con qualsiasi LLM

    Le skill IA sono in semplice Markdown, non in codice specifico di un fornitore, quindi funzionano con GPT, Claude, Gemini, Grok o un modello locale.

  • File inclusi: 2

    Script, template e riferimenti che il modello può leggere mentre lavora. I file sono di sola lettura e non vengono mai eseguiti.

  • Open source

    Pubblicata da intel su GitHub. Leggi i sorgenti prima di installarla.

Installazione

Installa la skill IA Dpnp Linalg Fft in TypingMind per usarla con qualsiasi LLM, oppure copiala in un altro agente in grado di leggere SKILL.md.

1

Installa in TypingMind

TypingMind installa una skill direttamente dalla sua cartella GitHub: legge SKILL.md, raccoglie i file delle risorse e salva il risultato in locale.

  1. Apri l'app e vai su Plugin → Skill.
  2. Scegli "Installa da GitHub".
  3. Incolla l'URL della cartella della skill riportato qui sotto e conferma.
    https://github.com/intel/skills/tree/main/skills/dpnp-linalg-fft
  4. Attiva la skill in ogni chat in cui vuoi averla a disposizione.
Plugin → Skill → Aggiungi skill → Da URL GitHub, poi incolla l'URL della cartella e premi Continua.
2

Installa in un altro agente

Qualsiasi agente che legge il formato Agent Skills può usare questa skill: copia la cartella della skill nella directory delle skill di quell'agente.

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
Dopo la copia, riavvia Claude Code per caricare la nuova skill.

Usala in TypingMind

Attiva Dpnp Linalg Fft in qualsiasi chat di TypingMind e al resto pensa il modello. Il nome e la descrizione della skill sono nel prompt di sistema e, non appena arriva una richiesta pertinente, il modello carica da solo le istruzioni complete: non devi mai richiamarla manualmente e non consuma token finché non viene effettivamente usata.

Il modello carica automaticamente Dpnp Linalg Fft non appena riceve una richiesta pertinente.

Funziona con qualsiasi modello IA

Le skill IA sono semplici istruzioni in Markdown, non codice specifico di un fornitore, quindi Dpnp Linalg Fft non è vincolata al modello per cui è stata scritta. Installala una sola volta in TypingMind e usala con GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama o un modello locale che esegui tu, sempre con le tue chiavi API.

  • Caricata solo quando serve

    Il prompt di sistema contiene solo il nome e la descrizione. Le istruzioni vengono recuperate alla prima richiesta pertinente, quindi una skill inutilizzata non costa nulla.

  • Cambia modello durante la chat

    Poiché la skill è composta da istruzioni e non da codice, continua a funzionare anche se cambi modello: il nuovo modello legge lo stesso file SKILL.md.

Istruzioni della skill

Questo è il contenuto di SKILL.md che il modello carica. Leggilo prima dell'installazione: una skill è un insieme di istruzioni che il tuo modello seguirà.

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.

File inclusi

Il modello legge questi file quando servono, mentre la skill è caricata. Sono accessibili in sola lettura e non vengono mai eseguiti.

Domande frequenti

Cosa fa la skill IA 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.

Perché usare Dpnp Linalg Fft su TypingMind?

Perché la installi una volta e la usi con qualsiasi modello. Dpnp Linalg Fft è scritta in semplice Markdown anziché in codice specifico di un fornitore, quindi la stessa skill funziona con GPT-5, Claude, Gemini, Grok o un modello locale, e puoi cambiare modello durante la chat senza che la skill smetta di funzionare. TypingMind usa le tue chiavi API, quindi paghi direttamente i fornitori anziché un abbonamento per posto utente, e le tue skill e chat restano nel tuo spazio di archiviazione.

Come installo Dpnp Linalg Fft in TypingMind?

Apri Plugin → Skill → Installa da GitHub in TypingMind e incolla https://github.com/intel/skills/tree/main/skills/dpnp-linalg-fft. TypingMind legge il file SKILL.md, include i file associati e installa la skill, che puoi abilitare per ogni singola chat.

Quali modelli IA possono usare Dpnp Linalg Fft?

Qualsiasi modello che colleghi a TypingMind. Le skill IA sono semplici istruzioni in Markdown anziché codice specifico di un fornitore, quindi GPT, Claude, Gemini, Grok e i modelli locali possono tutti caricare questa skill quando una richiesta corrisponde al suo scopo.

Quanti modelli IA posso usare con Dpnp Linalg Fft?

Quanti ne vuoi. Se un modello supporta le skill, puoi usarlo con Dpnp Linalg Fft: GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama e molti altri, tutti su TypingMind con le tue chiavi API.

La skill IA Dpnp Linalg Fft è gratuita?

Sì. È pubblicata su GitHub da intel con licenza Apache-2.0. Paghi solo il tuo fornitore IA per i token che usi.

Cosa sono le skill IA?

Una skill IA è un pacchetto di istruzioni riutilizzabili che insegna a un modello IA come svolgere un'attività specifica. Segue il formato aperto Agent Skills: un file SKILL.md con un nome e una descrizione, più eventuali script, template o file di riferimento di cui il modello potrebbe aver bisogno. Il modello legge le istruzioni solo quando la tua richiesta corrisponde alla skill, quindi una skill installata non comporta costi finché non viene usata.

In cosa si differenziano le skill IA dai plugin o dai server MCP?

Un plugin o un server MCP fornisce a un modello nuovi strumenti da richiamare: codice che viene eseguito da qualche parte e restituisce un risultato. Una skill IA, invece, fornisce al modello conoscenze e procedure: come affrontare un'attività, quali passaggi seguire e quali caratteristiche deve avere un buon output. Le skill sono semplici istruzioni in Markdown, quindi non richiedono server, chiavi API né ambienti di esecuzione e funzionano con qualsiasi modello.

Elenco completo

Crea subito il tuo spazio di lavoro AI

Iscriviti alla nostra newsletter per ricevere aggiornamenti sulle nuove funzionalità e sulle prossime iniziative a premi 👇