Opened 4 weeks ago

Last modified 5 days ago

#1144 new defect

Redundant MultiplicationModel class

Reported by: tcbennun Owned by: pkienzle
Priority: major Milestone: SasView 4.3.0
Component: SasView Keywords:
Cc: Work Package: SasView Bug Fixing

Description (last modified by butler)

In (at least) 4.2b onwards, the file sas/sascalc/fit/MultiplicationModel.py is unused in SasView, having been replaced with sasmodels' ProductModel and so forth, so it should be removed.

(assigning @pkienzle just in case anything could break)

Change History (4)

comment:1 Changed 4 weeks ago by butler

  • Description modified (diff)
  • Priority changed from minor to major

comment:2 Changed 2 weeks ago by butler

need to check if old plugins use this directly and would then break

comment:3 Changed 2 weeks ago by butler

This can be moved to 4.3 if nobody has the time to check whether it breaks old plugins. Mainly it would be 4.1.2 plugins I guess?

comment:4 Changed 5 days ago by pkienzle

  • Milestone changed from SasView 4.2.0 to SasView 4.3.0

sasmodels.sasview_model.MultiplicationModel should be a drop-in replacement.

It is unlikely that users have plugin models which use MultiplicationModel. If they do, we could have them update their models to import from sasmodels.sasview_model, or perhaps set sas/sascalc/fit/MultiplicationModel.py to:

    from sasmodels.sasview_model import MultiplcationModel

Regardless, sas.sasgui.perspectives.fitting.model_thread.Calc1D.compute will need to be updated so that it doesn't check if self.model is an instance of MultiplicationModel.

This should be done as part of the update to beta_approx, where we are restructuring the way that intermediate results are returned from the calculator.

This isn't a change we need to do for 4.2.

Note: See TracTickets for help on using tickets.