| 106 U: Space + Clone + Dist<L2, F>, |
106 U: Space + Clone + Dist<L2, F>, |
| 107 for<'a> &'a U: Instance<U>, |
107 for<'a> &'a U: Instance<U>, |
| 108 I: AlgIteratorFactory<IterInfo<F>>, |
108 I: AlgIteratorFactory<IterInfo<F>>, |
| 109 Dat: DifferentiableMapping<MeasureZ<F, Z, U>, Codomain = F, DerivativeDomain = Pair<S, Z>> |
109 Dat: DifferentiableMapping<MeasureZ<F, Z, U>, Codomain = F, DerivativeDomain = Pair<S, Z>> |
| 110 + BoundedCurvature<F>, |
110 + BoundedCurvature<F>, |
| 111 S: DifferentiableMapping<U, Codomain = F> + ClosedMul<F> + MinMaxMapping<U, F>, |
111 S: ClosedMul<F>, |
| 112 for<'a> Pair<&'a P, &'a IdOp<Z>>: StepLengthBoundPair<F, Dat>, |
112 for<'a> Pair<&'a P, &'a IdOp<Z>>: StepLengthBoundPair<F, Dat>, |
| 113 //Pair<S, Z>: ClosedMul<F>, |
|
| 114 DiscreteMeasure<U, F>: SpikeMerging<F>, |
113 DiscreteMeasure<U, F>: SpikeMerging<F>, |
| 115 Reg: SlidingRegTerm<U, F>, |
114 Reg: SlidingRegTerm<U, F>, |
| 116 P: TransportProxPenalty<U, S, Reg, F>, |
115 P: TransportProxPenalty<U, S, Reg, F>, |
| 117 // KOpM : Linear<DiscreteMeasure<U, F>, Codomain=Y> |
116 // KOpM : Linear<DiscreteMeasure<U, F>, Codomain=Y> |
| 118 // + GEMV<F, DiscreteMeasure<U, F>> |
117 // + GEMV<F, DiscreteMeasure<U, F>> |
| 418 U: Space + Clone + Dist<L2, F>, |
417 U: Space + Clone + Dist<L2, F>, |
| 419 for<'a> &'a U: Instance<U>, |
418 for<'a> &'a U: Instance<U>, |
| 420 I: AlgIteratorFactory<IterInfo<F>>, |
419 I: AlgIteratorFactory<IterInfo<F>>, |
| 421 Dat: DifferentiableMapping<MeasureZ<F, Z, U>, Codomain = F, DerivativeDomain = Pair<S, Z>> |
420 Dat: DifferentiableMapping<MeasureZ<F, Z, U>, Codomain = F, DerivativeDomain = Pair<S, Z>> |
| 422 + BoundedCurvature<F>, |
421 + BoundedCurvature<F>, |
| 423 S: DifferentiableMapping<U, Codomain = F> + ClosedMul<F> + MinMaxMapping<U, F>, |
422 S: ClosedMul<F>, |
| 424 DiscreteMeasure<U, F>: SpikeMerging<F>, |
423 DiscreteMeasure<U, F>: SpikeMerging<F>, |
| 425 Reg: SlidingRegTerm<U, F>, |
424 Reg: SlidingRegTerm<U, F>, |
| 426 P: TransportProxPenalty<U, S, Reg, F>, |
425 P: TransportProxPenalty<U, S, Reg, F>, |
| 427 for<'a> Pair<&'a P, &'a IdOp<Z>>: StepLengthBoundPair<F, Dat>, |
426 for<'a> Pair<&'a P, &'a IdOp<Z>>: StepLengthBoundPair<F, Dat>, |
| 428 Z: ClosedEuclidean<F> + AXPY + Clone, |
427 Z: ClosedEuclidean<F> + AXPY + Clone, |
| 429 for<'b> &'b Z: Instance<Z>, |
428 for<'b> &'b Z: Instance<Z>, |
| 430 R: Prox<Z, Codomain = F>, |
429 R: Prox<Z, Codomain = F>, |
| 431 Plot: Plotter<P::ReturnMapping, S, DiscreteMeasure<U, F>>, |
430 Plot: Plotter<P::ReturnMapping, S, DiscreteMeasure<U, F>>, |
| 432 // We should not need to explicitly require this: |
|
| 433 for<'b> &'b Loc<0, F>: Instance<Loc<0, F>>, |
|
| 434 // Loc<0, F>: StaticEuclidean<Field = F, PrincipalE = Loc<0, F>> |
|
| 435 // + Instance<Loc<0, F>> |
|
| 436 // + VectorSpace<Field = F>, |
|
| 437 { |
431 { |
| 438 let opKz: ZeroOp<Z, Loc<0, F>, _, _, F> = |
432 let opKz: ZeroOp<Z, Loc<0, F>, _, _, F> = |
| 439 ZeroOp::new_dualisable(StaticEuclideanOriginGenerator, z.dual_origin()); |
433 ZeroOp::new_dualisable(StaticEuclideanOriginGenerator, z.dual_origin()); |
| 440 let fnH = Zero::new(); |
434 let fnH = Zero::<Loc<0, F>, F>::new(); |
| 441 // Convert config. We don't implement From (that could be done with the o2o crate), as σd0 |
435 // Convert config. We don't implement From (that could be done with the o2o crate), as σd0 |
| 442 // needs to be chosen in a general case; for the problem of this fucntion, anything is valid. |
436 // needs to be chosen in a general case; for the problem of this fucntion, anything is valid. |
| 443 let &SlidingFBConfig { τ0, σp0, insertion, transport, guess } = config; |
437 let &SlidingFBConfig { τ0, σp0, insertion, transport, guess } = config; |
| 444 let pdps_config = SlidingPDPSConfig { τ0, σp0, insertion, transport, guess, σd0: 0.0 }; |
438 let pdps_config = SlidingPDPSConfig { τ0, σp0, insertion, transport, guess, σd0: 0.0 }; |
| 445 |
439 |
| 493 U: Space + Clone + Dist<L2, F>, |
487 U: Space + Clone + Dist<L2, F>, |
| 494 for<'a> &'a U: Instance<U>, |
488 for<'a> &'a U: Instance<U>, |
| 495 I: AlgIteratorFactory<IterInfo<F>>, |
489 I: AlgIteratorFactory<IterInfo<F>>, |
| 496 Dat: DifferentiableMapping<MeasureZ<F, Z, U>, Codomain = F, DerivativeDomain = Pair<S, Z>> |
490 Dat: DifferentiableMapping<MeasureZ<F, Z, U>, Codomain = F, DerivativeDomain = Pair<S, Z>> |
| 497 + BoundedCurvature<F>, |
491 + BoundedCurvature<F>, |
| 498 S: DifferentiableMapping<U, Codomain = F> + ClosedMul<F> + MinMaxMapping<U, F>, |
492 S: ClosedMul<F>, |
| 499 for<'a> Pair<&'a P, &'a IdOp<Z>>: StepLengthBoundPair<F, Dat>, |
493 for<'a> Pair<&'a P, &'a IdOp<Z>>: StepLengthBoundPair<F, Dat>, |
| 500 //Pair<S, Z>: ClosedMul<F>, |
|
| 501 DiscreteMeasure<U, F>: SpikeMerging<F>, |
494 DiscreteMeasure<U, F>: SpikeMerging<F>, |
| 502 Reg: SlidingRegTerm<U, F>, |
495 Reg: SlidingRegTerm<U, F>, |
| 503 P: TransportProxPenalty<U, S, Reg, F>, |
496 P: TransportProxPenalty<U, S, Reg, F>, |
| 504 // KOpM : Linear<DiscreteMeasure<U, F>, Codomain=Y> |
|
| 505 // + GEMV<F, DiscreteMeasure<U, F>> |
|
| 506 // + Preadjointable< |
|
| 507 // DiscreteMeasure<U, F>, Y, |
|
| 508 // PreadjointCodomain = S, |
|
| 509 // > |
|
| 510 // + TransportLipschitz<L2Squared, FloatType=F> |
|
| 511 // + AdjointProductBoundedBy<DiscreteMeasure<U, F>, 𝒟, FloatType=F>, |
|
| 512 // for<'b> KOpM::Preadjoint<'b> : GEMV<F, Y>, |
|
| 513 // Since Z is Hilbert, we may just as well use adjoints for K_z. |
|
| 514 KOpZ: BoundedLinear<Z, L2, L2, F, Codomain = Y> |
497 KOpZ: BoundedLinear<Z, L2, L2, F, Codomain = Y> |
| 515 + GEMV<F, Z> |
498 + GEMV<F, Z> |
| 516 + SimplyAdjointable<Z, Y, AdjointCodomain = Z>, |
499 + SimplyAdjointable<Z, Y, AdjointCodomain = Z>, |
| 517 KOpZ::SimpleAdjoint: GEMV<F, Y>, |
500 KOpZ::SimpleAdjoint: GEMV<F, Y>, |
| 518 Y: ClosedEuclidean<F>, |
501 Y: ClosedEuclidean<F>, |
| 567 for<'a> Pair<&'a P, &'a IdOp<Z>>: StepLengthBoundPair<F, Dat>, |
550 for<'a> Pair<&'a P, &'a IdOp<Z>>: StepLengthBoundPair<F, Dat>, |
| 568 Z: ClosedEuclidean<F> + AXPY + Clone, |
551 Z: ClosedEuclidean<F> + AXPY + Clone, |
| 569 for<'b> &'b Z: Instance<Z>, |
552 for<'b> &'b Z: Instance<Z>, |
| 570 R: Prox<Z, Codomain = F>, |
553 R: Prox<Z, Codomain = F>, |
| 571 Plot: Plotter<P::ReturnMapping, S, DiscreteMeasure<U, F>>, |
554 Plot: Plotter<P::ReturnMapping, S, DiscreteMeasure<U, F>>, |
| 572 // We should not need to explicitly require this: |
|
| 573 for<'b> &'b Loc<0, F>: Instance<Loc<0, F>>, |
|
| 574 // Loc<0, F>: StaticEuclidean<Field = F, PrincipalE = Loc<0, F>> |
|
| 575 // + Instance<Loc<0, F>> |
|
| 576 // + VectorSpace<Field = F>, |
|
| 577 { |
555 { |
| 578 let opKz: ZeroOp<Z, Loc<0, F>, _, _, F> = |
556 let opKz: ZeroOp<Z, Loc<0, F>, _, _, F> = |
| 579 ZeroOp::new_dualisable(StaticEuclideanOriginGenerator, z.dual_origin()); |
557 ZeroOp::new_dualisable(StaticEuclideanOriginGenerator, z.dual_origin()); |
| 580 let fnH = Zero::new(); |
558 let fnH = Zero::new(); |
| 581 // Convert config. We don't implement From (that could be done with the o2o crate), as σd0 |
559 // Convert config. We don't implement From (that could be done with the o2o crate), as σd0 |