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

SCM Repository

[diderot] View of /branches/vis12-cl/test/ty-test.diderot
ViewVC logotype

View of /branches/vis12-cl/test/ty-test.diderot

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2402 - (download) (annotate)
Sat Jul 27 13:55:03 2013 UTC (5 years, 10 months ago) by jhr
File size: 543 byte(s)
  Create branch for adding OpenCL to vis12 branch.  Based on r2401 of the vis12 branch.
// ty-test.diderot
//
// This file tests various typechecking rules, but it is an incomplete program
// and will not pass the compiler

tensor[2,3] x = [[0.0, 0.1, 0.2], [1.0, 1.1, 2.1]];
tensor[3] y = x[1,:];
tensor[2] z = x[:,0];
tensor[3,2] m = [x[:,0], x[:,1], x[:,2]];

image(3)[2] img1 = image("img1.nrrd");
field#2(3)[2] F = img1 ⊛ bspln3;
field#1(3)[2,3] dF = ∇⊗ F;

tensor[3] w = dF(y)[0,:];

real a = m:m + x:x;

strand S ()
{
    output real dummy = 0.0;
    update { dummy = 1; stabilize; }
}

initially { S() | i in 1..2 };

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