| Home | Trees | Indices | Help |
|
|---|
|
|
object --+
|
pdfcomponent.PDFComponent --+
|
organizer.Organizer --+
|
Fitting
Fitting is the class to control a PdfFit process, which can be either running on a remote machine or locally. Fitting will start a thread to interact with the PdfFit server using ssh2 and XMLRPC protocol. rw: fitness parameter tolerancy: accurancy requirement step: current refinement step res: fitting result string parameters: parameter dictionary
|
|||
|
Worker Worker is the daemon thread of fitting |
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
Inherited from Inherited from |
|||
|
|||
INITIALIZED = 1
|
|||
CONNECTED = 2
|
|||
CONFIGURED = 4
|
|||
DONE = 8
|
|||
VOID = 256
|
|||
QUEUED = 512
|
|||
RUNNING = 1024
|
|||
PAUSED = 2048
|
|||
|
|||
|
Inherited from |
|||
|
|||
initialize name -- name of this fitting
|
change current status of fitting fitStatus -- new fitting status jobStatus -- new thread status |
make a string identifier return value: string id |
copy self to other. if other is None, create an instance other -- ref to other object return value: reference to copied object
|
load data from a zipped project file z -- zipped project file subpath -- path to its own storage within project file returns a tree of internal hierachy
|
save data from a zipped project file z -- zipped project file subpath -- path to its own storage within project file
|
Make a copy stripped of all unpickleable data members.
The copy should be suitable for pickling and has the
following data members removed:
controlCenter, lock, pauseEvent, thread
returns reference to stripped copy
|
Update parameters dictionary from active constraints. returns self.parameters |
Change a parameter index to a new value. This will replace all instances of one parameter name with another in the containing fit. |
queue or dequeue self enter -- True to queue, False to dequeue |
get a PDFfit2 instance either locally or remotely
|
Prepare server for bond angle or bond length calculation. struc -- instance of PDFStructure No return value. |
Output bond angle defined by atoms i, j, k. The angle is calculated using the shortest lengths ji and jk with respect to periodic boundary conditions. struc -- instance of PDFStructure i, j, k -- atom indices starting at 1 No return value. The result should be automatically added to the Output Window, because all server output is sent there. Raise ControlValueError for invalid indices i, j, k. |
Output shortest bond between atoms i, j. Periodic boundary conditions are applied to find the shortest bond. struc -- instance of PDFStructure i, j -- atom indices starting at 1 No return value. The result should be automatically added to the Output Window, because all server output is sent there. Raise ControlValueError for invalid indices i, j. |
Output all a1-a2 bond lenghts within specified range. struc -- instance of PDFStructure a1 -- symbol of the first element in pair or "ALL" a2 -- symbol of the second element in pair or "ALL" lb -- lower bond length boundary ub -- upper bond length boundary No return value. The result should be automatically added to the Output Window, because all server output is sent there. Raise ControlValueError for invalid element symbols. |
pause ( self, bPause = None ) --> pause a fitting process
bPause -- True to pause, False to restart. If None, it will figure out
by itself.
|
check if fitting thread is running return: True if running, False otherwise |
close up the fitting in order to exit force -- if force to exit
|
build up a data name dictionary, which will map data name to a
unique index
The private dataNameDict has such strcture:
{ 'd_data1':{'Gobs':12, 'Gcalc':11, ....},
'd_data2':{'Gobs':10, 'Gcalc':9, ....},
...
'p_ph1':{'lat(1)':1,'lat(2)':2, .....},
'p_ph1':{'lat(1)':3,'lat(2)':4, .....},
...
'f_fit':{'rw':100, 1:101, 2:102}
}
The value of each sub-dict is the corresponding index of this data
item in the snapshot.
The prefix d_ p_ f_ make dataset,struc,fitname unique within the
shared name space of dictionary
|
after a refinement step is done, append all data from self to the historical storage, i.e., self.snapshots source -- where to get the fitted data, in deed it's a PdfFit2 instance |
Run a single step of the fit. return value: True if refinement is finished, otherwise False |
get names of data item which can be plotted as y returns a name str list |
get names of data item which can be plotted as x returns a name str list |
get self's data member
name -- data item name
step -- step info, it can be:
(1) a number ( -1 means latest step ): for single step
(2) a list of numbers: for multiple steps
(3) None: for all steps
returns data object, be it a single number, a list, or a list of list
|
return all applicable meta data names
|
get meta data value name -- meta data name returns meta data value |
get any data member from snapshots
id -- reference to a Fitting/Calculation/Phase/DataSet object
name -- data item name
step -- step info, it can be:
(1) a number ( -1 means latest step ): for single step
(2) a list of numbers: for multiple steps
(3) None: for all steps
returns data object, be it a single number, a list, or a list of list
|
| Home | Trees | Indices | Help |
|
|---|
| Generated by Epydoc 3.0beta1 on Fri Apr 10 19:11:00 2009 | http://epydoc.sourceforge.net |