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

# SCM Repository

[diderot] View of /trunk/doc/diderot.tex
 [diderot] / trunk / doc / diderot.tex

# View of /trunk/doc/diderot.tex

Revision 21 - (download) (as text) (annotate)
Sat Jan 16 18:16:32 2010 UTC (11 years, 6 months ago) by glk
File size: 4985 byte(s)
* addition of a "rawten" type, also parameterized by \rho, which represents the type of tensors as they are stored in an image on disk or in memory.  As it was, images were only of type \rho, with no indication of the tensor structure.  The only annoyance now is that this allows one to store on disk or in memory tensors with int coefficients, which is probably nonsense, but its harmless.

* renamed the mapping of image to field from "sample" to "convolve".  However, its not clear to me if the definition as I wrote it is sufficiently clear that the mapping is from an image of rawten<o,d,\rho> to an field of tensor<o,d>, where the "o"s and "d"s must match up.

* added negation of fields

* moved what was in "tensor arithmatic" to the "addition" section.

\documentclass[11pt]{article}

\input{defs}

\setlength{\textwidth}{6in}
\setlength{\oddsidemargin}{0.25in}
\setlength{\evensidemargin}{0.25in}
\setlength{\parskip}{5pt}

\title{Diderot design}
\author{
Gordon Kindlmann \\
University of Chicago \\
{\small\tt{}glk@cs.uchicago.edu} \\
\and
John Reppy \\
University of Chicago \\
{\small\tt{}jhr@cs.uchicago.edu} \\
\and
Thomas Schultz \\
University of Chicago \\
{\small\tt{}t.schultz@uchicago.edu} \\
}
\date{\today}

\begin{document}

\maketitle
\thispagestyle{empty}

\section{Introduction}
This document is a semi-formal design of Diderot.

\section{Types}
The syntax of Diderot types is given in \figref{fig:types}.
\begin{figure}[t]
\begin{displaymath}
\begin{array}{rclr}
\rho  & ::= & $\ldots$ & \text{NRRD scalar types} \\[1em]
\iota & ::= & \TYbool & \text{booleans} \\
& \mid & \TYint & \text{integers} \\[1em]
% \mu for memory, where images of rawtensors will live (or on disk)
\mu & ::= & \TYrawten{o}{d}{\rho} & \begin{minipage}[l]{3in}\begin{flushright}
tensors of order $o$ and dimension $d$,\\with coefficients of type $\rho$
\end{flushright}\end{minipage}\\[1em]
\theta & ::= & \TYtensor{o}{d} & \begin{minipage}[l]{3in}\begin{flushright}
tensors of order $o$ and dimension $d$,\\with real coefficients
\end{flushright}\end{minipage}\\[1em]
\tau & ::= & \iota \\
& \mid & \theta \\
& \mid & \TYmatrix{n}{m} & \text{$n\times{}m$ matrix} \\
& \mid & \TYimage{d}{\mu} & \text{$d$-dimension image of $\mu$ values}\\
& \mid & \TYkern{k} & \text{convolution kernel with $k$ derivatives} \\
& \mid & \TYfield{k}{d}{\theta} & \text{$d$-dimension field of $\theta$ values with $k$ derivatives} \\
\end{array}%
\end{displaymath}%
where $o\in\Nat$ is the tensor order, $d,n,m\in\SET{2,3}$ are dimensions,
and $k\in\Nat$ is the differentiability of a field.
\caption{Diderot types}
\label{fig:types}
\end{figure}%
We use some type abbreviations for common cases:
\begin{eqnarray*}
\TYreal & = & \TYtensor{0}{d} \quad\text{for any $d$} \\
\TYvec{d} & = & \TYtensor{1}{d}
\end{eqnarray*}%

\section{Operations}

\subsection{Scalar operations}
\noindent{}Arithmetic:
\begin{displaymath}
\begin{array}{cl}
\BinopTy{{\odot}}{\tau}{\tau}{\tau}
& \text{for $\odot\in\SET{{+},{-},{*},{/}}$ and $\tau\in\SET{\TYint,\TYreal}$} \\
\UnopTy{{-}}{\tau}{\tau}
& \text{for $\tau\in\SET{\TYint,\TYreal}$}
\end{array}%
\end{displaymath}%

\noindent{}Comparisons:
\begin{displaymath}
\BinopTy{{\odot}}{\tau}{\tau}{\TYbool}
\qquad\text{for $\odot\in\SET{{<},{\leq},{=},{\neq}{>},{\geq}}$ and $\tau\in\SET{\TYint,\TYreal}$}
\end{displaymath}%

\subsection{Matrix operations}

\subsection{Tensor operations}

\noindent{}Scalar multiplication:
\begin{displaymath}
\begin{array}{c}
\BinopTy{{*}}{\TYreal}{\TYtensor{o}{d}}{\TYtensor{o}{d}} \\
\BinopTy{{*}}{\TYtensor{o}{d}}{\TYreal}{\TYtensor{o}{d}}
\end{array}%
\end{displaymath}%

\noindent{}Scalar division:
\begin{displaymath}
\BinopTy{{/}}{\TYtensor{o}{d}}{\TYreal}{\TYtensor{o}{d}}
\end{displaymath}%

\begin{displaymath}
\BinopTy{{\odot}}{\TYtensor{o}{d}}{\TYtensor{o}{d}}{\TYtensor{o}{d}}
\qquad\text{for $\odot\in\SET{{+},{-}}$}
\end{displaymath}%

\noindent{}Negation:
\begin{displaymath}
\UnopTy{-}{\TYtensor{o}{d}}{\TYtensor{o}{d}}
\end{displaymath}%

\subsection{Field operations}

\noindent{}Creation from an image:
\begin{displaymath}
\BinopTy{\OPconvolve}{\TYkern{k}}{\TYimage{d}{\mu}}{\TYfield{k}{d}{\theta}}
\qquad\text{where $\theta$ is the real conversion of $\mu$.}
\end{displaymath}%

\noindent{}Scalar multiplication:
\begin{displaymath}
\begin{array}{c}
\BinopTy{{*}}{\TYreal}{\TYfield{k}{d}{\theta}}{\TYfield{k}{d}{\theta}} \\
\BinopTy{{*}}{\TYfield{k}{d}{\theta}}{\TYreal}{\TYfield{k}{d}{\theta}}
\end{array}%
\end{displaymath}%

\noindent{}Scalar division:
\begin{displaymath}
\BinopTy{{/}}{\TYfield{k}{d}{\theta}}{\TYreal}{\TYfield{k}{d}{\theta}}
\end{displaymath}%

\noindent{}Negation:
\begin{displaymath}
\UnopTy{-}{\TYfield{k}{d}{\theta}}{\TYfield{k}{d}{\theta}}
\end{displaymath}%

\begin{displaymath}
\begin{array}{c}
\BinopTy{{\odot}}{\TYfield{k}{d}{\theta}}{\theta}{\TYfield{k}{d}{\theta}} \\
\BinopTy{{\odot}}{\theta}{\TYfield{k}{d}{\theta}}{\TYfield{k}{d}{\theta}} \\
\BinopTy{{\odot}}{\TYfield{k_1}{d}{\theta}}{\TYfield{k_2}{d}{\theta}}{\TYfield{\min(k_1,k_2)}{d}{\theta}}
\end{array}%
\qquad\text{for $\odot\in\SET{{+},{-}}$}
\end{displaymath}%

\noindent{}Differentiation:
\begin{displaymath}
\UnopTy{\OPdiff}{\TYfield{k}{d}{\TYtensor{o}{d}}}{\TYfield{k-1}{d}{\TYtensor{o+1}{d}}}
\qquad\text{for $k > 0$}
\end{displaymath}%

\noindent{}Probing:
\begin{displaymath}
\BinopTy{@}{\TYfield{k}{d}{\theta}}{\TYvec{d}}{\theta}
\end{displaymath}%

\end{document}


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