/[escript]/trunk/escript/py_src/pdetools.py
ViewVC logotype

Diff of /trunk/escript/py_src/pdetools.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 3675 by jfenwick, Thu Nov 17 00:53:38 2011 UTC revision 3676 by jfenwick, Thu Nov 17 03:52:25 2011 UTC
# Line 409  class Locator: Line 409  class Locator:
409          Returns the value of ``data`` at the Locator if ``data`` is a `Data`          Returns the value of ``data`` at the Locator if ``data`` is a `Data`
410          object otherwise the object is returned.          object otherwise the object is returned.
411          """          """
         print "Norris"  
412          if isinstance(data,escript.Data):          if isinstance(data,escript.Data):
413             dat=util.interpolate(data,self.getFunctionSpace())             dat=util.interpolate(data,self.getFunctionSpace())
414             id=self.getId()             id=self.getId()
415             r=data.getRank()             r=data.getRank()
416             if isinstance(id,list):             if isinstance(id,list):
417                 out=[]                 out=[]
                print "Zorro"  
418                 for i in id:                 for i in id:
419                    o=numpy.array(dat.getTupleForGlobalDataPoint(*i))                    o=numpy.array(dat.getTupleForGlobalDataPoint(*i))
420                    if data.getRank()==0:                    if data.getRank()==0:
# Line 425  class Locator: Line 423  class Locator:
423                       out.append(o)                       out.append(o)
424                 return out                 return out
425             else:             else:
          print "Thom"  
426               out=numpy.array(dat.getTupleForGlobalDataPoint(*id))               out=numpy.array(dat.getTupleForGlobalDataPoint(*id))
427               if data.getRank()==0:               if data.getRank()==0:
428                  return out[0]                  return out[0]

Legend:
Removed from v.3675  
changed lines
  Added in v.3676

  ViewVC Help
Powered by ViewVC 1.1.26