Changeset 327 for trunk/GSASIIplot.py


Ignore:
Timestamp:
Jul 1, 2011 12:10:28 PM (12 years ago)
Author:
vondreele
Message:

fix to path name for atomdata.dat
fix to texture display - can't have colorbars!
put in bit to show #threads used

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/GSASIIplot.py

    r326 r327  
    11921192    Page.canvas.draw()
    11931193   
    1194 def PlotTexture(self,data,newPlot=False):
     1194def PlotTexture(self,data,newPlot=False,Start=False):
    11951195    '''Pole figure, inverse pole figure(?), 3D pole distribution and 3D inverse pole distribution(?)
    11961196    plotting; Need way to select 
     
    12111211    SHCoef = SHData['SH Coeff'][1]
    12121212    cell = generalData['Cell'][1:7]
    1213     Start = True
    12141213   
    12151214    def OnMotion(event):
     
    12641263            R = np.where(R <= 1.,2.*npasind(R*0.70710678),0.0)
    12651264            Z = np.zeros_like(R)
    1266             time0 = time.time()
    12671265            Z = G2lat.invpolfcal(ODFln,SGData,R,P)
    1268             print 'inverse time:',time.time()-time0
    12691266            Z = np.reshape(Z,(npts,npts))
    12701267            CS = Plot.contour(Y,X,Z,aspect='equal')
     
    12721269            Img = Plot.imshow(Z.T,aspect='equal',cmap='binary',extent=[-1,1,-1,1])
    12731270            if newPlot:
    1274                 Page.figure.colorbar(Img)
     1271#                Page.figure.colorbar(Img)    #colorbar fails - crashes gsasii
    12751272                newPlot = False
    12761273            Plot.set_title('Inverse pole figure for XYZ='+str(SHData['PFxyz']))
    1277             print 'inverse pole figure',Img
    12781274                       
    12791275        else:
     
    12861282            R = np.where(R <= 1.,2.*npasind(R*0.70710678),0.0)
    12871283            Z = np.zeros_like(R)
    1288             time0 = time.time()
    12891284            Z = G2lat.polfcal(ODFln,SamSym[textureData['Model']],R,P)
    1290             print 'polfig time:',time.time()-time0
    12911285            Z = np.reshape(Z,(npts,npts))
    12921286            CS = Plot.contour(Y,X,Z,aspect='equal')
     
    12941288            Img = Plot.imshow(Z.T,aspect='equal',cmap='binary',extent=[-1,1,-1,1])
    12951289            if newPlot:
    1296                 Page.figure.colorbar(Img)
     1290#                Page.figure.colorbar(Img)    #colorbar fails - crashes gsasii
    12971291                newPlot = False
    12981292            Plot.set_title('Pole figure for HKL='+str(SHData['PFhkl']))
    1299             print 'pole figure',Img
    13001293    Page.canvas.draw()
     1294
    13011295           
    13021296def PlotExposedImage(self,newPlot=False,event=None):
Note: See TracChangeset for help on using the changeset viewer.