Clarification of required fields for custom operators

Aperta
#412 1 commento 1 reazione 1 assegnatario Vedi su GitHub

@amontoison ci sta già lavorando.

Dal 26/2/2026.

Valutazione

Questa issue non è ancora stata valutata.

Descrizione

Hello, we have a few packages with custom operators based on LinearOperators.jl and with the recent 2.13 update and the included internal LinearOperator field changes from #406 our operators became incompatible (see here and related issues).

Such custom operators might be outside the scope of the package, but if not, I think it would be helpful to document the property or methods a custom operator needs to implement in order to be compatible with the package and to consider those part of the public interface.

As an example, if we consider this function:

function allocate_vectors_args3!(op::AbstractLinearOperator)
  S = storage_type(op)
  op.Mv = S(undef, op.nrow)
  op.Mtu = (op.nrow == op.ncol) ? op.Mv : S(undef, op.ncol)
  return op
end

LinearOperators.jl dispatches on AbstractLinearOperator and if we inherit from that we need to have ncol, Mv and so on. And in particular, previous versions had Mv5.

If custom operators are within the package's intended scope, maybe we could add a small section to either the readme or the docs which describes the necessary fields and methods a custom operator needs to implement

Lingua principale
Julia
Stelle
214
Fork
46
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di JuliaSmoothOptimizers/LinearOperators.jl

Tutte le issue di JuliaSmoothOptimizers/LinearOperators.jl

Issue simili

Altre issue su Julia

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.