Changeset e4078ed in sasview


Ignore:
Timestamp:
Nov 20, 2016 7:32:48 AM (8 years ago)
Author:
jhbakker
Branches:
master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
Children:
4466a6a
Parents:
55db501
Message:

Sesans optimization

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/sas/sascalc/data_util/qsmearing.py

    r55db501 re4078ed  
    1717import numpy as np  # type: ignore 
    1818from numpy import pi, exp  # type: ignore 
    19 #from scipy.special import j as besselj 
    2019 
    21 from sasmodels.resolution import Slit1D, Pinhole1D, SESANS1D 
     20from sasmodels.resolution import Slit1D, Pinhole1D 
     21from sasmodels.sesans import SESANS1D 
    2222from sasmodels.resolution2d import Pinhole2D 
    2323from src.sas.sascalc.data_util.nxsunit import Converter 
     
    6868        #Pre-compute the Hankel matrix (H) 
    6969        qmax, qunits = data.sample.zacceptance 
    70         Hankelinst=sesans.SesansTransform() 
    71         sesans.SesansTransform.set_transform(Hankelinst, 
     70        hankel=sesans.SesansTransform() 
     71        sesans.SesansTransform.set_transform(hankel, 
    7272        SE = Converter(data._xunit)(data.x, "A"), 
    7373        zaccept = Converter(qunits)(qmax, "1/A"), 
    7474        Rmax = 1000000) 
    75         H=sesans.SesansTransform._H 
    76         H0=sesans.SesansTransform._H0 
    77         q=sesans.SesansTransform.q 
    7875        # Then return the actual transform, as if it were a smearing function 
    7976        # applying evalDistribution to a model, with a q-space as param, returns the I(q) values that go with the q-values 
    8077 
    81         return PySmear(SESANS1D(data, H0, H, q), model) 
     78        return PySmear(SESANS1D(data, hankel._H0, hankel._H, hankel.q), model) 
    8279 
    8380    _found_resolution = False 
Note: See TracChangeset for help on using the changeset viewer.