Changeset 2961 for branch


Ignore:
Timestamp:
Aug 2, 2017 7:38:42 PM (4 years ago)
Author:
toby
Message:

fix bug in derivative for excluded regions

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branch/2frame/GSASIIstrMath.py

    r2948 r2961  
    32593259                ip = names.index(parm)
    32603260                dMdv[varylist.index(name)] += dMdpk[4*id+ip]
    3261     cw = np.diff(x)
     3261    cw = np.diff(ma.getdata(x))
    32623262    cw = np.append(cw,cw[-1])
    32633263    Ka2 = False #also for TOF!
     
    35423542    #print '#3 getPowderProfileDerv t=',time.time()-starttime
    35433543    #print timelist,sum(timelist)
     3544    dMdv[:,ma.getmaskarray(x)] = 0.  # instead of masking, zero out masked values
    35443545    dMdv = ma.array(dMdv,mask=np.outer(np.ones(len(varylist)),ma.getmaskarray(x)))      #x is a MaskedArray!
    35453546    G2mv.Dict2Deriv(varylist,depDerivDict,dMdv)
     
    37473748            dMdvh = getPowderProfileDerv(parmDict,x[xB:xF],
    37483749                varylist,Histogram,Phases,rigidbodyDict,calcControls,pawleyLookup)
     3750            # print 'HessRefine getPowderProfileDerv'
     3751            # import cPickle
     3752            # fp = open('/tmp/hess.pkl','w')
     3753            # cPickle.dump(dMdvh,fp,1)
     3754            # fp.close()
    37493755            Wt = ma.sqrt(W[xB:xF])[nxs,:]
    37503756            Dy = dy[xB:xF][nxs,:]
Note: See TracChangeset for help on using the changeset viewer.