Back to the main page.

Bug 1831 - consider adding a vectorized version for ptriproj

Status CLOSED FIXED
Reported 2012-11-12 23:13:00 +0100
Modified 2013-05-09 08:31:20 +0200
Product: FieldTrip
Component: core
Version: unspecified
Hardware: PC
Operating System: Mac OS
Importance: P3 normal
Assigned to: Jan-Mathijs Schoffelen
URL:
Tags:
Depends on:
Blocks:
See also:

Jan-Mathijs Schoffelen - 2012-11-12 23:13:15 +0100

even though ptriproj is mex'ed, a considerable amount of time is spent in this function in e.g. project_elec. I recently found a toolbox on file exchange (geom3d) that has a vectorized version (m-file) with similar functionality. Investigate whether it pays off to replace ptriproj-calls in large for-loops with a version of this code. anecdotally, once a large number of triangles needs to be investigated per point (~1000) it seems to start paying off (~10 times speed increase for the vectorized version).


Jan-Mathijs Schoffelen - 2013-02-25 11:19:27 +0100

/home/language/jansch/matlab/fieldtrip/forward/private Adding lmoutrn.m Adding plinprojn.m Sending project_elec.m Adding ptriprojn.m Transmitting file data .... Committed revision 7543.