Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Diff of /branches/cuda/TODO
ViewVC logotype

Diff of /branches/cuda/TODO

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

revision 1115, Thu May 5 04:42:18 2011 UTC revision 1156, Sun May 8 21:20:52 2011 UTC
# Line 1  Line 1 
1  NOTE: GLK's approximate ranking of 5 most important tagged with  NOTE: GLK's approximate ranking of 5 most important tagged with
2  [GLK:1], [GLK:2], ...  [GLK:1], [GLK:2], ...
3    
4  ==============================  ========================
5  other SHORT TERM =============  (including needed for LIC)  SHORT TERM ============= (*needed* for streamlines & tractography)
6  ==============================  ========================
7    
8  [GLK:1] Add sequence types (needed for evals & evecs)  [GLK:1] Add sequence types (needed for evals & evecs)
9      syntax      syntax
10          types: ty '{' INT '}'          types: ty '{' INT '}'
11          value construction: '{' e1 ',' … ',' en '}'          value construction: '{' e1 ',' … ',' en '}'
12          indexing: e '{' e '}'          indexing: e '{' e '}'
13    [GLK:1] evals & evecs for symmetric tensor[3,3] (requires sequences)
14    
15  IL support for higher-order tensor values (matrices, etc).  ability to emit/track/record variables into dynamically re-sized
16      tensor construction [DONE]  runtime buffer
     tensor indexing [DONE]  
     tensor slicing  
     verify that hessians work correctly [DONE]  
   
 Use ∇⊗ etc. syntax  
     syntax [DONE]  
     typechecking  
     IL and codegen  
   
 test/uninit.diderot:  
 documents need for better compiler error messages when output variables  
 are not initialized; the current messages are very cryptic  
17    
18  determinant ("det") for tensor[3,3]  tensor fields: convolution on general tensor images
19    
20  expand trace in mid to low translation  ========================
21    SHORT-ISH TERM ========= (to make using Diderot less annoying/slow)
22    ========================
23    
24  value-numbering optimization  value-numbering optimization
25    
26  Add type aliases for color types  proper handling of stabilize method
     rgb = real{3}  
     rgba = real{4}  
   
 ==============================  
 MEDIUM TERM ================== (including needed for streamlines & tractography)  
 ==============================  
   
 [GLK:1] evals & evecs for symmetric tensor[3,3] (requires sequences)  
27    
28  [GLK:2] Save Diderot output to nrrd, instead of "mip.txt"  [GLK:2] Save Diderot output to nrrd, instead of "mip.txt"
29    For grid of strands, save to similarly-shaped array    For grid of strands, save to similarly-shaped array
# Line 52  Line 35 
35  [GLK:3] Use of Teem's "hest" command-line parser for getting  [GLK:3] Use of Teem's "hest" command-line parser for getting
36  any input variables that are not defined in the source file  any input variables that are not defined in the source file
37    
38  [GLK:4] ability to declare a field in such a way so that probe  [GLK:4] ability to declare a field so that probe positions are
39  positions are *always* clamped to the support of "inside";  *always* "inside"; with various ways of mapping the known image values
40  there are many cases where this is the sensible behavior.  to non-existant index locations.  One possible syntax emphasizes that
41  (could also have "repeat" declaration, to mimic GL_REPEAT texturing)  there is a index mapping function that logically precedes convolution:
42      F = bspln3 ⊛ (img  clamp)
43  extend norm (|exp|) to all tensor types [DONE for vectors and matrices]    F = bspln3 ⊛ (img ◦ repeat)
44      F = bspln3 ⊛ (img ◦ mirror)
45  ability to emit/track/record variables into dynamically re-sized  where "◦" or "∘" is used to indicate function composition
 runtime buffer  
46    
47  Want: allow X *= Y, X /= Y, X += Y, X -= Y to mean what they do in C,  Use ∇⊗ etc. syntax
48  provided that X*Y, X/Y, X+Y, X-Y are already supported.      syntax [DONE]
49  Nearly every Diderot program would be simplified by this.      typechecking
50        IL and codegen
 Want: non-trivial field expressions & functions:  
   image(2)[2] Vimg = load(...);  
   field#0(2)[] Vlen = |Vimg ⊛ bspln3|;  
 to get a scalar field of vector length, or  
   field#2(2)[] F = Fimg ⊛ bspln3;  
   field#0(2)[] Gmag = |∇F|;  
 to get a scalar field of gradient magnitude, or  
   field#2(2)[] F = Fimg ⊛ bspln3;  
   field#0(2)[] Gmsq = ∇F•∇F;  
 to get a scalar field of squared gradient magnitude, which is simpler  
 to differentiate.  However, there is value in having these, even if  
 the differentiation of them is not supported (hence the indication  
 of "field#0" for these above)  
51    
52  Want: ability to apply "normalize" to a field itself, e.g.  Add a clamp function, which takes three arguments; either three scalars:
53    field#0(2)[2] V = normalize(Vimg ⊛ ctmr);    clamp(x, minval, maxval)  = max(minval, min(maxval, x))
54  so that V(x) = normalize((Vimg ⊛ ctmr)(x)).  or three vectors of the same size:
55  Having this would simplify expression of standard LIC method, and    clamp([x,y], minvec, maxvec)  = [max(minvec[0], min(maxvec[0], x)),
56  would also help express other vector field expressions that arise                                     max(minvec[1], min(maxvec[1], y))]
57  in vector field feature exraction.  This would be useful in many current Diderot programs.
58    One question: clamp(x, minval, maxval) is the argument order
59    used in OpenCL and other places, but clamp(minval, maxval, x)
60    would be more consistent with lerp(minout, maxout, x).
61    
62    Level of differentiability in field type should be statement about how
63    much differentiation the program *needs*, rather than what the kernel
64    *provides*.  The needed differentiability can be less than or equal to
65    the provided differentiability.
66    
67  tensor fields: convolution on general tensor images  Add type aliases for color types
68        rgb = real{3}
69        rgba = real{4}
70    
71  ==============================  ==============================
72  other MEDIUM TERM ============ (needed for particles)  MEDIUM TERM ================== (*needed* for particles)
73  ==============================  ==============================
74    
 [GLK:5] run-time death of strands; test/iso2d.diderot provides  
 great initial test for "die" command.  
   
75  run-time birth of strands  run-time birth of strands
76    
77  "initially" supports lists  "initially" supports lists
# Line 103  Line 79 
79  "initially" supports lists of positions output from  "initially" supports lists of positions output from
80  different initalization Diderot program  different initalization Diderot program
81    
82  spatial data structure that permits strands' queries of neighbors  Communication between strands: they have to be able to learn each
83    other's state (at the previous iteration).  Early version of this can
84    have the network of neighbors be completely static (for running one
85    strand/pixel image computations).  Later version with strands moving
86    through the domain will require some spatial data structure to
87    optimize discovery of neighbors.
88    
89    ============================
90    MEDIUM-ISH TERM ============ (to make Diderot more useful/effective)
91    ============================
92    
93  proper handling of stabilize method  Python/ctypes interface to run-time
94    
95  test/vr-kcomp2.diderot: Add support for code like  support for Python interop and GUI
96    
97          (F1 if x else F2)@pos  Alow X *= Y, X /= Y, X += Y, X -= Y to mean what they do in C,
98    provided that X*Y, X/Y, X+Y, X-Y are already supported.
99    Nearly every Diderot program would be simplified by this.
100    
101  This will require duplication of the continuation of the conditional  Put small 1-D and 2-D fields, when reconstructed specifically by tent
102  (but we should only duplicate over the live-range of the result of the  and when differentiation is not needed, into faster texture buffers.
103  conditional.  test/illust-vr.diderot is good example of program that uses multiple
104    such 1-D fields basically as lookup-table-based function evaluation
105    
106    expand trace in mid to low translation
107    
108    extend norm (|exp|) to all tensor types [DONE for vectors and matrices]
109    
110    determinant ("det") for tensor[3,3]
111    
112  add ":" for tensor dot product (contracts out two indices  add ":" for tensor dot product (contracts out two indices
113  instead of one like •), valid for all pairs of tensors with  instead of one like •), valid for all pairs of tensors with
114  at least two indices  at least two indices
115    
116  ==============================  test/uninit.diderot:
117  other MEDIUM TERM ============  documents need for better compiler error messages when output variables
118  ==============================  are not initialized; the current messages are very cryptic
119    
120  want: warnings when "D" (reserved for differentiation) is declared as  want: warnings when "D" (reserved for differentiation) is declared as
121  a variable name (get confusing error messages now)  a variable name (get confusing error messages now)
122    
 support for Python interop and GUI  
   
 Python/ctypes interface to run-time  
   
 ==============================  
 LONG TERM ====================  
123  ==============================  ==============================
124    LONG TERM ==================== (make Diderot more interesting/attractive from
125    ==============================  a research standpoint)
126    
127    IL support for higher-order tensor values (matrices, etc).
128        tensor construction [DONE]
129        tensor indexing [DONE]
130        tensor slicing
131        verify that hessians work correctly [DONE]
132    
133  Better handling of variables that determines the scope of a variable  Better handling of variables that determines the scope of a variable
134  based on its actual use, instead of where the user defined it.  So,  based on its actual use, instead of where the user defined it.  So,
# Line 140  Line 136 
136  scope.  Also prune out useless variables, which should include field  scope.  Also prune out useless variables, which should include field
137  variables after the translation to mid-il.  variables after the translation to mid-il.
138    
139    test/vr-kcomp2.diderot: Add support for code like
140            (F1 if x else F2)@pos
141    This will require duplication of the continuation of the conditional
142    (but we should only duplicate over the live-range of the result of the
143    conditional.
144    
145    [GLK:5] Want: non-trivial field expressions & functions:
146      image(2)[2] Vimg = load(...);
147      field#0(2)[] Vlen = |Vimg ⊛ bspln3|;
148    to get a scalar field of vector length, or
149      field#2(2)[] F = Fimg ⊛ bspln3;
150      field#0(2)[] Gmag = |∇F|;
151    to get a scalar field of gradient magnitude, or
152      field#2(2)[] F = Fimg ⊛ bspln3;
153      field#0(2)[] Gmsq = ∇F•∇F;
154    to get a scalar field of squared gradient magnitude, which is simpler
155    to differentiate.  However, there is value in having these, even if
156    the differentiation of them is not supported (hence the indication
157    of "field#0" for these above)
158    
159    Want: ability to apply "normalize" to a field itself, e.g.
160      field#0(2)[2] V = normalize(Vimg ⊛ ctmr);
161    so that V(x) = normalize((Vimg ⊛ ctmr)(x)).
162    Having this would simplify expression of standard LIC method, and
163    would also help express other vector field expressions that arise
164    in vector field feature exraction.
165    
166    Permit fields composition, especially for warping images by a
167    smooth field of deformation vectors
168      field#2(3)[3] warp = bspln3 ⊛ warpData;
169      field#2(3)[] F = bspln3 ⊛ img;
170      field#2(3)[] Fwarp = F ◦ warp;
171    So Fwarp(x) = F(warp(X)).  Chain rule can be used for differentation
172    
173    Allow the convolution to be specified either as a single 1D kernel
174    (as we have it now):
175      field#2(3)[] F = bspln3 ⊛ img;
176    or, as a tensor product of kernels, one for each axis, e.g.
177      field#0(3)[] F = (bspln3 ⊗ bspln3 ⊗ tent) ⊛ img;
178    This is especially important for things like time-varying data, or
179    other multi-dimensional fields where one axis of the domain is very
180    different from the rest.  What is very unclear is how, in such cases,
181    we should notate the gradient, when we only want to differentiate with
182    respect to some of the axes.
183    
184  co- vs contra- index distinction  co- vs contra- index distinction
185    
186  some indication of tensor symmetry  some indication of tensor symmetry
# Line 157  Line 198 
198  BUGS =================  BUGS =================
199  ======================  ======================
200    
 test/bug-usevar.diderot:  
 looks like varialble scoping bug is still present in some cases?  
   
 test/bug-matrix.diderot:  
 3x3 matrix subtraction is broken  
 (and then fix test/vr-curv-quad.diderot)  
   
 test/read2vecs.diderot:  
 // HEY (BUG?) shouldn't it be a type error to load this 2-D array of  
 // 2-vectors into a 2-D *scalar* field?  Instead, get:  
 //   uncaught exception Fail [Fail: Error in compiling lic.diderot]  
 //     raised at driver/main.sml:31.39-31.76  
 image(2)[] Vimg = load("../data/vorttest.nrrd");  
   
201  test/zslice2.diderot:  test/zslice2.diderot:
202  // HEY (bug) bspln5 leads to problems ...  // HEY (bug) bspln5 leads to problems ...
203  //  uncaught exception Size [size]  //  uncaught exception Size [size]

Legend:
Removed from v.1115  
changed lines
  Added in v.1156

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0