text:
\section{Introduction}
Videos represent among the most widely used forms of data, and their accurate characterization poses an important challenge for computer vision and machine learning. Generating a natural-language description of a video, termed video captioning, is an important component of video analysis. Inspired by the successful encoder-decoder framework used in machine translation \citep{Cho2014emnlp,Bahdanau2015iclr,Sutskever2014nips} and image caption generation \citep{kiros2014multimodal,NIC,neuraltalk,mao2015ICLR}, most recent work on video captioning \citep{donahue2015long,venugopalan2015sequence,venugopalan2014translating,pan2016joint,yu2016video} employs a two-dimensional (2D) or three-dimensional (3D) Convolutional Neural Network (CNN) as an encoder, mapping an input video to a compact feature-vector representation. A Recurrent Neural Network (RNN) is typically employed as a decoder, unrolling the feature vector to generate a sequence of words of arbitrary length.

Despite achieving encouraging success in video captioning, previous models suffer important limitations. Often the rich video content is mapped to a single feature vector for caption generation; this approach is prone to miss detailed and localized spatiotemporal information. To mitigate this, one may employ methods to focus attention on local regions of the feature map, but typically this is done with features from a selected (usually top) CNN layer. By employing features from a fixed CNN layer, the algorithm is limited in its ability to model rich, context-aware semantics that requires focusing on different feature abstraction levels. As investigated in \citet{mahendran2015understanding,Zeiler14ECCV}, the feature characteristics/abstraction is correlated with the CNN layer: features from layers at or near the top of a CNN tend to focus on global (extended) visual percepts, while features from lower CNN layers provide more local, fine-grained information. It is desirable to select/weight features from different CNN layers adaptively when decoding a caption, selecting different levels of feature abstraction by sequentially emphasizing features from different CNN layers. In addition to focusing on features from different CNN layers, it is also desirable to emphasize local spatiotemporal regions in feature maps at particular layers.

To realize these desiderata, the proposed decoding process for generating a sequence of words dynamically emphasizes different levels (CNN layers) of 3D convolutional features, to model important coarse or fine-grained spatiotemporal structure. Additionally, the model adaptively attends to different locations within the feature maps at particular layers. While some previous models use 2D CNN features to generate video representations, our model adopts features from a deep 3D convolutional neural network (C3D). Such features have been shown to be effective for video representations, action recognition and scene understanding \citep{tran2014learning}, by learning the spatiotemporal features that can provide better appearance and motion information. In addition, the proposed model is inspired by the recent success of attention-based models that mimic human perception \citep{mnih2014recurrent,Attend}. Adaptive spatiotemporal feature representation, with dynamic feature abstraction, involves comparing and evaluating different levels of 3D convolutional feature maps. A challenge is that the features from different C3D levels have distinct dimensions. For example, low-level features provide fine resolution on localized spatiotemporal regions, while high-level features capture extended spatiotemporal space with less resolution. To enable direct comparisons between layers, we employ convolution operations to map different levels of features to the same semantic-space dimension.

The principal contributions of this paper are: (\emph{i}) A new video-caption-generation model is developed, based on two distinct means (``hard'' and ``soft'') of imposing attention.
(\emph{ii}) Our model empolys the attention to adaptively and sequentially emphasize different levels of feature abstraction (CNN layers), while also imposing attention within local spatiotemporal regions of the feature maps at each layer.
(\emph{iii}) A 3D convolutional transformation is introduced to achieve spatiotemporal and semantic feature consistency across different layers.
(\emph{iv}) The proposed model achieves state-of-the-art performance on several benchmark datasets.
We call the proposed algorithm Adaptive SpatioTemporal representation with dynAmic abstRaction (ASTAR).

\section{Related Work}
Early work on video captioning used a two-step approach, employing role-word detection (\textit{e.g.}, subject, verb and object) and rules for language grammar.
In such work, the sentence for video description is first split into several parts, each of which is aligned with visual content. For example, \citet{rohrbach2013translating,rohrbach2014coherent} learn a Conditional Random Field (CRF) to infer high-level concepts such as object and action; in \citet{Youtube2text} semantic hierarchies are used to choose an appropriate level of sentence fragments.
Statistical language models, learned from large text corpora, are used to translate the semantic representation to a grammatically correct sentence.

Recent work often develops a probabilistic model of the caption, conditioned on a video.  \citet{donahue2015long,venugopalan2015sequence,venugopalan2014translating,yu2016video,pan2015hierarchical} applied a 2D CNN pretrained on ImageNet to video frames, with the top-layer output of the CNN used as features.
Given the {\em sequence} of features extracted from video frames, the video representation is then obtained by a CRF \citep{donahue2015long}, mean pooling \citep{venugopalan2014translating}, weighted mean pooling with attention \citep{yu2016video}, or via the last hidden state of an RNN encoder \citep{venugopalan2015sequence}.
These works were followed by \citet{pan2016joint}, which jointly embedded the 2D CNN features and spatiotemporal features extracted from a 3D CNN \citep{tran2014learning}.
However, all of these previous models utilize features extracted from the top layer of the CNN.

The proposed model is related to \citet{ballas2015delving}, but distinct in important ways. The intermediate convolutional feature maps are leveraged, like \citet{ballas2015delving}, but an attention model is developed instead of the ``stack" RNN in \citet{ballas2015delving}. In addition, a powerful decoder enhanced with two attention mechanisms is constructed for generating captions, while a simple RNN decoder is employed in \citet{ballas2015delving}. Finally,  we use features extracted from C3D instead of a 2D CNN.

\section{Method}\label{sec:method}
Consider $N$ training videos, the $n$th of which is denoted ${\bf X}^{(n)}$, with associated caption ${\bf Y}^{(n)}$. The length-$T_n$ caption is represented ${\bf Y}^{(n)}=({\boldsymbol y}_1^{(n)},\dots,{\boldsymbol y}^{(n)}_{T_n})$, with ${\boldsymbol y}_t^{(n)}$ a 1-of-$V$ (``one hot'') encoding vector, with $V$ the size of the vocabulary.

For each video, the C3D feature extractor \citep{tran2014learning} produces a set of features ${\bf A}^{(n)}=\{{\boldsymbol a}_1^{(n)},\dots,{\boldsymbol a}_L^{(n)},{\boldsymbol a}_{L+1}^{(n)}\}$, where $\{{\boldsymbol a}_1^{(n)},\dots,{\boldsymbol a}_L^{(n)}\}$ are feature maps extracted from $L$ convolutional layers, and ${\boldsymbol a}_{L+1}^{(n)}$ is a vector obtained from the top fully-connected layer.

The convolutional-layer features, $\{{\boldsymbol a}_1^{(n)},\dots,{\boldsymbol a}_L^{(n)}\}$, are extracted by feeding the entire video into C3D, and hence the dimensions of $\{{\boldsymbol a}_1^{(n)},\dots,{\boldsymbol a}_L^{(n)}\}$ are dependent on the video length (number of frames). As discussed below, we employ spatiotemporal attention at each layer (and between layers), and therefore it is not required that the sizes of $\{{\boldsymbol a}_1^{(n)},\dots,{\boldsymbol a}_L^{(n)}\}$ be the same for all videos. However, the fully connected layer at the top, responsible for ${\boldsymbol a}_{L+1}^{(n)}$, assumes that ${\boldsymbol a}_L^{(n)}$ is of the same size for all videos (like the 16-frame-length videos in \citep{tran2014learning}). To account for variable-length videos, and maintain the same fully-connected layer at the top, we employ mean pooling to ${\boldsymbol a}_L^{(n)}$, based on a window of length 16 (as in \citep{tran2014learning}) with an overlap of 8 frames. The particular form of pooling used here (one could also use max pooling) is less important than the need to make the dimension of the top-layer features the same for feeding into the final fully-connected layer.

\begin{figure}[t!]

	\vspace{-4mm}
	\includegraphics[width=0.95\textwidth]{figs/model.pdf}
	\caption{\small Illustration of our proposed caption-generation model. The model leverages a fully-connected map from the top layer as well as convolutional maps from different mid-level layers of a pretrained 3D  convolutional neural network (C3D). }
	\vspace{-4mm}

	\label{fig:model}
\end{figure}

\subsection{Caption Model}
For notational simplicity, henceforth we omit superscript $n$. The $t$-th word in a caption, ${\boldsymbol y}_t$, is mapped to an $M$-dimensional vector ${\boldsymbol w}_t={\bf W}_{e}{\boldsymbol y}_t$, where ${\bf W}_{e}\in \mathbb{R}^{M\times V}$ is a learned word-embedding matrix, \textit{i.e.}, ${\boldsymbol w}_t$ is a column of ${\bf W}_e$ chosen by the one-hot ${\boldsymbol y}_t$. The probability of caption ${\bf Y}=\{{\boldsymbol y}_t\}_{t=1,T}$ is defined as
\begin{align}
p({\bf Y}|{\bf A})=p({\boldsymbol y}_1|{\bf A})\textstyle{\prod_{t=2}^{T}p({\boldsymbol y}_t|{\boldsymbol y}_{<t}, {\bf A})}\,.\label{eq:decoder}
\end{align}
Specifically, the first word ${\boldsymbol y}_1$ is drawn from $p({\boldsymbol y}_1|{\bf A}) = \mbox{softmax}({\bf V} {\boldsymbol h}_1)$, where ${\boldsymbol h}_1 = \tanh({\bf C}{\boldsymbol a}_{L+1})$. Bias terms are omitted for simplicity throughout the paper.
All the other words in the caption are then sequentially generated using an RNN, until the end-sentence symbol is generated.
Conditional distribution $p({\boldsymbol y}_t|{\boldsymbol y}_{<t},{\bf A})$ is specified as $\mbox{softmax} ({\bf V} {\boldsymbol h}_t)$, where ${\boldsymbol h}_t$ is recursively updated as ${\boldsymbol h}_t = \mathcal{H}({\boldsymbol w}_{t-1},{\boldsymbol h}_{t-1},{\boldsymbol z}_t)$.
${\bf V}$ is a matrix connecting the RNN hidden state to a softmax, for computing a distribution over words. ${\boldsymbol z}_t = \phi({\boldsymbol h}_{t-1},{\boldsymbol a}_1,\dots,{\boldsymbol a}_L)$ is the context vector used in the attention mechanism, capturing the relevant visual features associated with the spatiotemporal attention (also weighting level of feature abstraction), as detailed in Sec. \ref{sec:att}.

Note that the output of the fully-connected-layer, ${\boldsymbol a}_{L+1}$, is only used to generate the first word (encapsulating overall-video features). We found that only using ${\boldsymbol a}_{L+1}$ there works better in practice than using it at each time step of the RNN, as also found in \citet{NIC,venugopalan2014translating}.

The transition function $\mathcal{H}(\cdot)$ is implemented with Long Short-Term Memory (LSTM) \citep{hochreiter1997long}.
At time $t$, the LSTM unit consists of a memory cell ${\boldsymbol c}_t$ and three gates: the input ${\boldsymbol i}_t$, forget ${\boldsymbol f}_t$, and output ${\boldsymbol o}_t$ gates. The memory cell transmits the information from the previous step to the current step, while the gates control reading or writing the memory unit through sigmoid functions. Specifically, the hidden units ${\boldsymbol h}_t$ are updated as follows:
\begin{align}
{\boldsymbol i}_t &= \sigma ({\bf W}_{iw}{\boldsymbol w}_{t-1} + {\bf W}_{ih}{\boldsymbol h}_{t-1} + {\bf W}_{iz} {\boldsymbol z}_t), & {\boldsymbol f}_t &= \sigma ({\bf W}_{fw}{\boldsymbol w}_{t-1} + {\bf W}_{fh}{\boldsymbol h}_{t-1} + {\bf W}_{fz} {\boldsymbol z}_t), \nonumber \\
{\boldsymbol o}_t &= \sigma ({\bf W}_{ow}{\boldsymbol w}_{t-1} + {\bf W}_{oh}{\boldsymbol h}_{t-1} + {\bf W}_{oz} {\boldsymbol z}_t), & \tilde{{\boldsymbol c}}_t &= \tanh ({\bf W}_{cw}{\boldsymbol w}_{t-1} + {\bf W}_{ch}{\boldsymbol h}_{t-1} + {\bf W}_{cz} {\boldsymbol z}_t), \nonumber \\
{\boldsymbol c}_t &= {\boldsymbol f}_t \odot {\boldsymbol c}_{t-1} + {\boldsymbol i}_t \odot \tilde{{\boldsymbol c}}_t, & {\boldsymbol h}_t &= {\boldsymbol o}_t \odot \tanh({\boldsymbol c}_t),
\end{align}
where $\sigma(\cdot)$ and $\odot$ denote the sigmoid function and the element-wise multiply operator, respectively. Matrices ${\bf W}_{\{i,f,o,c\}}$, ${\bf V}$ and ${\bf C}$ represent the set of LSTM parameters that will be learned (plus associated biases).

Given the video ${\bf X}$ (with features ${\bf A}$) and associated caption ${\bf Y}$, the objective function is the sum of the log-likelihood of the caption conditioned on the video representation:
\begin{align}
 \log p({\bf Y}|{\bf A}) =\log p({\boldsymbol y}_1|{\bf A}) + \textstyle{\sum_{t=2}^{T} \log p({\boldsymbol y}_t|{\boldsymbol y}_{<t}, {\bf A})}\,,\label{eq:loss}
\end{align}
Equation (\ref{eq:loss}) is a function of all model parameters to be learned; they are not explicitly depicted in (\ref{eq:loss}) for notational simplicity. Further, (\ref{eq:loss}) corresponds to a single video-caption pair, and when training we sum over all such training pairs.  Our proposed model is illustrated in Figure \ref{fig:model}.
\begin{figure}[t!]
	\includegraphics[width=\textwidth]{figs/attention.pdf}
	\vspace{-6mm}
	\caption{\small Illustration of our attention mechanism. The video features are extracted by C3D, followed by a 3D convolutional transformation. At each time step, the spatiotemporal attention takes these features and previous hidden units to generate $L$ feature vectors which are fed to the abstraction attention, manifesting the context vector. }
	\label{fig:attention}
	\vspace{-5mm}
\end{figure}
\subsection{Attention Mechanism}\label{sec:att}
We first define notation needed to describe attention mechanism $\phi({\boldsymbol h}_{t-1},{\boldsymbol a}_1,\dots,{\boldsymbol a}_L)$. Each feature map, ${\boldsymbol a}_l$, is a 4D tensor, with elements corresponding to two spatial coordinates ($i.e.$, vertical and horizontal dimensions in a given frame), third tensor index in the frame-index dimension, and a fourth dimension associated with the filter index (for the convolutional filters). To be explicit, at CNN layer $l$, the number of dimensions of this tensor are denoted $n_x^l\times n_y^l\times n_z^l\times n_F^l$, with respective dimensions corresponding to vertical, horizontal, frame, and filter ($e.g.$, $n_F^l$ convolutional filters at layer $l$). Note that dimensions $n_x^l$, $n_y^l$ and $n_z^l$ vary with layer level $l$ (getting smaller with increasing $l$, due to pooling).

We define ${\boldsymbol a}_{i,l}$ as a ${n_F^l}$-dimensional {\em vector}, corresponding to a fixed coordinate in three of the tensor dimensions, $i.e.$, $i \in [1,\dots, n_x^l] \times [1,\dots, n_y^l] \times [1,\dots, n_z^l]$, while sweeping across all $n_F^l$ feature/filter dimensions. Further, define ${\boldsymbol a}_l(k)$ as a 3D tensor, associated with 4D tensor ${\boldsymbol a}_l$. Specifically, ${\boldsymbol a}_l(k)$ corresponds to the 3D tensor manifested from ${\boldsymbol a}_l$, with $k\in\{1,\dots,n_F^l\}$ a fixed coordinate in the dimension of the filter index. Hence, ${\boldsymbol a}_l(k)$ corresponds to the 3D feature map at layer $l$, due to the $k$th filter at that layer.

We introduce two attention mechanisms when predicting word ${\boldsymbol y}_t$: ($i$) spatiotemporal-localization attention, and ($ii$) abstraction-level attention; these, respectively, measure the relative importance of a particular spatiotemporal location and a particular CNN layer (feature abstraction) for producing ${\boldsymbol y}_t$, based on the word-history information ${\boldsymbol y}_{<t}$.
The most straightforward way to generate the attention weights is to employ a multi-layer perceptron (MLP) \citep{Attend,Bahdanau2015iclr} on ${\boldsymbol a}_{i,l}$, as this corresponds to the $i$th spatial-spatial-frame location at layer $l$.  However, this has three challenges: (\emph{i}) the dimension of ${\boldsymbol a}_l$ depends on layer index $l$, undermine use of a single MLP for all ${\boldsymbol a}_{i,l}$; (\emph{ii}) the features represented in each layer by ${\boldsymbol a}_l$ are not spatiotemporally aligned (\emph{i.e.}, there is no correspondence between $i$ across layers); and (\emph{iii}) the semantic meaning of each feature vector ${\boldsymbol a}_{i,l}$ corresponds the convolutional filters in
each layer of C3D, which varies across layers. Issue ($ii$) undermines the ability to quantify the value of attention at a specific spatiotemporal location, based on information from {\em all} CNN layers. Issue ($iii$) implies that the layer-dependent features are in different semantic spaces, which makes it difficult to compare the value of each layer for predicting the next word in the caption and feed the features into the same LSTM decoder.

To address this, we seek to map ${\boldsymbol a}_l\rightarrow \hat{{\boldsymbol a}}_l$,
where 4D tensors $\hat{{\boldsymbol a}}_l$ all have the same dimensions, are embedded into same semantic spaces, and are aligned spatialtemporally. Specifically, $\hat{{\boldsymbol a}}_l$, $l=1,\dots,L-1$ are aligned in the above ways with ${\boldsymbol a}_L$. To achieve this, we filter each ${\boldsymbol a}_l$, $l=1,\dots, L-1$, and then apply max-pooling; the filters seek semantic alignment of the features (including feature dimension), and the pooling is used to spatiotemporally align the features with ${\boldsymbol a}_L$. Specifically, consider
\begin{align}
\hat{{\boldsymbol a}}_l&=\textstyle{f(\sum_{k=1}^{n_F^l} {\boldsymbol a}_{l}(k)*{\bf U}_{k,l})},	\label{eq:conv_trans}
\end{align}
for $l=1,\dots,L-1$, and with $\hat{{\boldsymbol a}}_L = {\boldsymbol a}_L$. As discussed above, ${\boldsymbol a}_{l}(k)$ is the 3D feature map (tensor) for dictionary $k\in\{1,\dots,n_F^l\}$ at layer $l$, and ${\bf U}_{k,l}$ is a 4D tensor. The convolution $*$ in (\ref{eq:conv_trans}) operates in the three shift dimensions, and ${\boldsymbol a}_{l}(k)*{\bf U}_{k,l}$ manifests a 4D tensor. Specifically, each of the $n_F^L$ 3D ``slices'' of ${\bf U}_{k,l}$ are spatiotemporally convolved (3D convolution) with ${\boldsymbol a}_{k,l}$, and after summing over the $n^l_F$ convolutional filters, followed by $f(\cdot)$, this manifests each of the $n^L_F$ 3D slices of $\hat{{\boldsymbol a}}_l$.
Function $f(\cdot)$ is an element-wise nonlinear activation function, followed by max pooling, with the pooling dimensions meant to realize final dimensions consistent with ${\boldsymbol a}_L$, $i.e.$, dimension $n_x^L \times n_y^L \times n_z^L \times n_F^L$. Consequently, $\hat{{\boldsymbol a}}_{i,l}\in \mathbb{R}^{ n_F^L}$ is a feature vector with $i\in [1,\dots, n_x^L] \times [1,\dots, n_y^L] \times [1,\dots, n_z^L]$.
Note that it may only require one 3D tensor ${\bf U}_{l}$ applied on each 3D slices ${\boldsymbol a}_l(k)$ for each layer to achieve spatiotemporal alignment of the layer-dependent features.
However, the features from two distinct layers will not be in the same ``semantic'' space, making it difficult to assess the value of the layer-dependent features. The multiple tensors in set $\{{\bf U}_{k,l}\}$ provide the desired semantic alignment between layers, allowing analysis of the value of features from different layers via a single MLP, in the following \eqref{eq:spa_tem} and (\ref{eq:abs}).

With $\{\hat{{\boldsymbol a}}_{l}\}_{l=1,L}$ semantically and spatiotemporally aligned, we now seek to jointly quantify the value of a particular spatiotemporal region and a particular feature layer (``abstraction'') for prediction of the next word.
For each $\hat{{\boldsymbol a}}_{i,l}$, the attention mechanism generates two positive weights, $\alpha_{ti}$ and $\beta_{tl}$, which measure the relative importance of location $i$ and layer $l$ for producing ${\boldsymbol y}_t$ based ${\boldsymbol y}_{<t}$. Attention weights $\alpha_{ti}$ and $\beta_{tl}$ and context vector ${\boldsymbol z}_{t}$ are computed as
	\begin{align}
	e_{ti}& = {\boldsymbol w}_{\alpha}^T \tanh({\bf W}_{a\alpha}\hat{{\boldsymbol a}}_{i}+{\bf W}_{h\alpha}{\boldsymbol h}_{t-1}), &\alpha_{ti} = \mbox{softmax}(\{e_{ti}\}),\quad	&{\boldsymbol s}_{t} = \psi(\{\hat{{\boldsymbol a}}_i\},\{\alpha_{ti}\}),\label{eq:spa_tem}  \\
	b_{tl}& = {\boldsymbol w}_{\beta}^T \tanh({\bf W}_{s\beta}{\boldsymbol s}_{tl}+{\bf W}_{h\beta}{\boldsymbol h}_{t-1}), &\beta_{tl} = \mbox{softmax}(\{b_{tl}\}),\quad	&{\boldsymbol z}_{t} = \psi(\{{\boldsymbol s}_{tl}\},\{\beta_{tl}\}),\label{eq:abs}
	\end{align}
where $\hat{{\boldsymbol a}}_i$ is a vector composed by stacking $\{\hat{{\boldsymbol a}}_{i,l}\}_{l=1,L}$ (all features at position $i$). $e_{ti}$ and $b_{tl}$ are scalars reflecting the importance of spatiotemporal region $i$ and layer $t$ to predicting ${\boldsymbol y}_t$, while $\alpha_{ti}$ and $\beta_{tl}$ are {\em relative} weights of this importance, reflected by the softmax output. $\psi(\cdot)$ is a function that returns a single feature vector when given a set of feature vectors, and their corresponding weights across all $i$ or $l$. Vector ${\boldsymbol s}_{tl}$ reflects the sub-portion of ${\boldsymbol s}_t$ associated with layer $l$.

In (\ref{eq:spa_tem}) we provide attention in the spatiotemporal dimensions, with that spatiotemporal attention shared across all $L$ (now aligned) CNN layers. In (\ref{eq:abs}) the attention is further refined, focusing attention in the layer dimension.

To make the following discussion concrete, we describe the attention function within the context of ${\boldsymbol z}_{t} = \psi(\{{\boldsymbol s}_{tl}\},\{\beta_{tl}\})$. This function setup is applied in the same way to ${\boldsymbol s}_{t} = \psi(\{\hat{{\boldsymbol a}}_i\},\{\alpha_{ti}\})$.

\paragraph{Soft attention}
Following \citet{Bahdanau2015iclr}, we formulate the soft attention model by computing a weighted sum of the input features
\begin{align}
{\boldsymbol z}_{t} = \psi(\{{\boldsymbol s}_{tl}\},\{\beta_{tl}\})=\textstyle{\sum_{l=1}^{L} \beta_{tl} {\boldsymbol s}_{tl}}.\label{eq:soft}
\end{align}
The model is differentiable for all parameters and can be learned end-to-end using standard back-propagation.
\paragraph{Hard attention}
Let ${\boldsymbol m}_t\in\{0,1\}^{L}$ be a vector of all zeros, and a single one, and the location of the non-zero element of ${\boldsymbol m}_t$ identifies the location to extract features for generating the next word. We impose
\begin{align}
{\boldsymbol m}_t \sim \mathsf{Mult}(1,\{\beta_{tl}\}), \qquad{\boldsymbol z}_{t} =\textstyle{ \sum_{l=1}^{L} m_{tl}} {\boldsymbol s}_{tl}.
\end{align}
In this case, optimizing the objective function in \eqref{eq:loss} is intractable. However, the marginal log-likelihood can be lower-bounded as
\begin{align} \label{eq:lbound}
\textstyle{	\log p({\bf Y}|{\bf A}) = \log \sum_{{\boldsymbol m}}p({\boldsymbol m}|{\bf A})p({\bf Y}|{\boldsymbol m},{\bf A}) \geq  \sum_{{\boldsymbol m}}p({\boldsymbol m}|{\bf A})\log p({\bf Y}|{\boldsymbol m},{\bf A}),}
\end{align}
where ${\boldsymbol m} = \{{\boldsymbol m}_t\}_{t=1,\dots,T}$.
Inspired by importance sampling, the multi-sample stochastic lower bound has been recently used for latent variable models \citep{ba2015learning, Burda16importance}, defined as
\begin{align}
\textstyle{\mathcal{L}^K({\bf Y}) = \sum_{{\boldsymbol m}^{1:K}}p({\boldsymbol m}^{1:K}|{\bf A})\Big[\log  \frac{1}{K}\sum_{k=1}^{K}p({\bf Y}|{\boldsymbol m}^k,{\bf A}) \Big],}\label{eq:bound}
\end{align}
where ${\boldsymbol m}^1,\dots,{\boldsymbol m}^K$ are independent samples. This lower bound is guaranteed to be tighter with the increase of the number of samples $K$ \citep{Burda16importance}, thus providing a better approximation of the objective function than (\ref{eq:lbound}). As shown in \citet{mnih2016variational}, the gradient of $\mathcal{L}^K({\bf Y})$ with respect to the model parameters is
\begin{align}
\textstyle{\nabla\mathcal{L}^K({\bf Y}) = \sum_{{\boldsymbol m}^{1:K}}p({\boldsymbol m}^{1:K}|{\bf A})\sum_{k=1}^{K}\Big[L({\boldsymbol m}^{1:K})\nabla\log  p({\boldsymbol m}^k|{\bf A})+\omega_k \nabla p({\bf Y}|{\boldsymbol m}^k,{\bf A}) \Big],}
\end{align}
where $L({\boldsymbol m}^{1:K}) = \log  \frac{1}{K}\sum_{k=1}^{K}p({\bf Y}|{\boldsymbol m}^k,{\bf A}) $ and $\omega_k = \frac{p({\bf Y}|{\boldsymbol m}^k,{\bf A})} {\sum_j p({\bf Y}|{\boldsymbol m}^j,{\bf A})}$.
A variance reduction technique is introduced in \citet{mnih2016variational} by replacing the above gradient with an unbiased estimator
\begin{align}
\textstyle{\nabla\mathcal{L}^K({\bf Y}) \approx \sum_{k=1}^{K}\Big[\hat{L}({\boldsymbol m}^{k}|{\boldsymbol m}^{-k})\nabla\log  p({\boldsymbol m}^k|{\bf A})+\omega_k \nabla p({\bf Y}|{\boldsymbol m}^k,{\bf A}) \Big]},\label{eq:gradient}
\end{align}
where
\begin{align}
\hat{L}({\boldsymbol m}^{k}|{\boldsymbol m}^{-k}) & = L({\boldsymbol m}^{1:K}) - \textstyle{\log\frac{1}{K}}\big(\sum_{j\neq k}p({\bf Y}|{\boldsymbol m}^j, {\bf A})+ f({\bf Y}, {\boldsymbol m}^{-k},{\bf A})) \big),\\
f({\bf Y}, {\boldsymbol m}^{-k},{\bf A}) &= \textstyle{\exp(\frac{1}{K-1}\sum_{j\neq k} \log p({\bf Y}|{\boldsymbol m}^j,{\bf A}).}
\end{align}
When learning the model parameters, the lower bound \eqref{eq:bound} is optimized via the gradient approximation in \eqref{eq:gradient}.

As an alternative method, one may first produce abstraction-level attention weights $\beta_l$, followed by generating spatiotemporal attention weights $\alpha_i$, \textit{i.e.}, switching the order of \eqref{eq:spa_tem} and \eqref{eq:abs}. However, we empirically found that this method provides slightly worse performance (we implemented and tested both) in our experiments, partially due to the increase of the number of parameters.

\section{Experiments}
\subsection{Datasets}
We present results on three benchmark datasets: Microsoft Research Video Description Corpus (YouTube2Text) \citep{Y2T}, Montreal Video Annotation Dataset (M-VAD) \citep{MVAD}, and Microsoft Research Video to Text (MSR-VTT) \citep{MSRVTT}.

The Youtube2Text contains 1970 Youtube clips, and each video is annotated with around 40 sentences. For fair comparison, we used the same splits as provided in \citet{venugopalan2014translating}, with 1200 videos for training, 100 videos for validation, and 670 videos for testing.

The M-VAD is a large-scale movie description dataset, which is composed of 46587 movie snippets annotated with 56752 sentences. We follow the setting in \citet{MVAD}, taking 36920 videos for training, 4950 videos for validation, and 4717 videos for testing.

The MSR-VTT is a newly collected large-scale video dataset, consisting of 20 video categories. The dataset was split into 6513, 2990 and 497 clips in the training, testing and validation sets. Each video has about 20-sentence descriptions. The ground-truth captions in the testing set are not available now. Thus, we split the original training dataset into a training set of 5513 clips and a testing set of 1000 clips.

We convert all captions to lower case and remove the punctuation, yielding vocabulary sizes $V=12594$ for Youtube2Text, $V=13276$ for M-VAD, and $V=8071$ for MSR-VTT.

\subsection{Training procedure}\label{sec:train}

We consider the RGB frames of videos as input, and all videos are resized to $112 \times 112$ spatially, with 2 frames per second; note that the temporal sample rate of the videos are consequently consistent, but not necessarily the total number of frames. The C3D \citep{tran2014learning} is pretrained on Sports-1M dataset \citet{karpathy2014large}, consisting of 1.1 million sports videos belonging to 487 categories. We extract the features from four convolutional layers and one fully connected layer, named as  {\em pool2, pool3, pool4, pool5} and {\em fc-7} in the C3D \citep{tran2014learning}, respectively.
The model architecture of C3D is provided in Appendix \ref{sec:c3d}. The kernel sizes of the convolutional transformation in \eqref{eq:conv_trans} are $7\times 7 \times 7$, $5\times 5 \times 5$ and $3\times 3 \times 3$ for layer {\em pool2, pool3} and {\em pool4} with $3\times 3 \times 3$, $2\times 2 \times 2$ and $1\times 1\times 1$ zero padding, respectively.  $f(\cdot)$ is implemented by ReLU \citep{relu}, followed by 3D max-pooling with $8\times 8 \times 8$, $4\times 4 \times 4$ and $2\times 2 \times 2$ ratios. More details for achieving spatiotemporal alignment are provided in Appendix \ref{sec:dimension} .

All recurrent matrices in the LSTM are initialized with orthogonal initialization \citep{saxe2013exact}.
We initialize non-recurrent weights from a uniform distribution in $[-0.01,0.01]$ and all the bias terms are initialized to zero.
Word embedding vectors are initialized with the publicly available \emph{word2vec} vectors that were trained on 100 billion words from Google News, which have dimensionality 300, and were trained using a continuous bag-of-words architecture \citep{mikolov2013distributed}.
The embedding vectors of words not present in the pre-trained set are initialized randomly.
The number of hidden units in the LSTM is set as 512 and we use mini-batches of size $32$.
Gradients are clipped if the norm of the parameter vector exceeds 5 \citep{Sutskever2014nips}. The number of samples for multi-sample stochastic lower bound is set to 10.
We do not perform any dataset-specific tuning and regularization other than dropout \citep{dropout} and early stopping on validation sets.
The Adam algorithm \cite{adam} with learning rate 0.0002 is utilized for optimization.
All experiments are implemented in Torch \citep{torch}.

\begin{table}[t]
	\vspace{-4mm}
	\centering
	\caption{\small Results on BLEU-4, METEOR and CIDEr metrics compared to other state-of-the-art results and baselines on Youtube2Text and M-VAD datasets. [1,2,3,4] represent \citet{venugopalan2015sequence,pan2016joint,ballas2015delving,yu2016video}, respectively.}\label{tab:results1}
	\vspace{1mm}
	\begin{small}
		\begin{tabular}{c|ccc|ccc}
			\toprule
			\multirow{2}{*}{Methods}& \multicolumn{3}{c|}{Youtube2Text} & \multicolumn{3}{c}{M-VAD}\\
			\cline{2-7}
			& BLEU-4 & METEOR & CIDEr & BLEU-4 & METEOR & CIDEr \\
			\midrule
			S2VT (VGG) [1] &- & 29.2 & - & - & 5.6 &-\\
			LSTM-E (VGG + C3D) [2] & 45.3 & 31.0 & - &- & 6.7 &-\\
			GRU-RCN [3]  & 47.90 &  31.14 & 67.82 & - & - & -\\
			h-RNN (C3D+VGG) [4] & 49.9 & 32.6 & 65.8 & - & - & -\\
			\midrule
			\multicolumn{2}{c}{\textit{Baselines}} & & & \\
			\midrule
			ResNet + LSTM & 44.08 & 30.99 & 66.88 & 0.81  & 6.22 & 5.54\\
			C3D fc7 + LSTM & 45.34 & 31.21 & 66.12 & 0.83 & 6.31 & 5.96 \\
			\midrule
			\multicolumn{2}{c}{\textit{Spatiotemporal attention + LSTM}}& & & & \\
			\midrule
			C3D fc7 + pool2 & 45.46 & 31.53 & 67.38 & 0.98 & 6.42 & 6.01\\
			C3D fc7 + pool3 & 48.07 & 33.52 & 69.97 & 1.12 & 6.71 & 6.97\\
			C3D fc7 + pool4 & 48.18 & 34.47 & 70.97 & 1.24 & 6.89 & 7.12\\
			C3D fc7 + pool5 & 47.75 & 33.35 & 69.71 & 1.02 & 6.49 & 6.48\\
			\midrule
			\multicolumn{2}{c}{\textit{ASTAR}} & & & \\
			\midrule
			Soft Attention  & {\bf 51.74} & {\bf 36.39}  & {\bf 72.18} & {\bf 1.94} & {\bf 7.72} & 7.98\\
			Hard Attention  & 51.64 & 34.99  &  72.08 & 1.82 & 7.12  & {\bf 8.12}\\
			\bottomrule
		\end{tabular}
	\end{small}
\end{table}
\subsection{Evaluation}
The widely used BLEU \citep{bleu}, METEOR \citep{meteor} and CIDEr \citep{cider} metrics are employed to
quantitatively evaluate the performance of our video caption generation model, and other models in the literature.
For each dataset, we show three types of results, using part of or all of our model to illustrate the role of each component:
\begin{enumerate}
	\item
	{\em C3D fc7 + LSTM }: The LSTM caption decoder is employed, only using features extracted from the top fully-connected layer. No context vector ${\boldsymbol z}_t$ is generated from intermediate convolutional layer features.
	\item
	{\em Spatiotemporal attention + LSTM}: The context vector ${\boldsymbol z}_t$ is included, but only features extracted from a certain convolutional layer are employed, \textit{i.e.}, ${\boldsymbol z}_t$ is equal to ${\boldsymbol s}_t$ in \eqref{eq:spa_tem}. The spatiotemporal attention is implemented with the soft attention in \eqref{eq:soft}. For example, ``C3D fc7 + pool2" means we leverage the features from layer {\em pool2} to generate attention weights and context vector.
	\item
	{\em ASTAR}: This is our proposed model developed in Sec.~\ref{sec:att}. We present results based on  both soft attention and hard attention.
\end{enumerate}
To verify the effectiveness of our video caption generation model and C3D features, we also implement a strong baseline method based on the LSTM encoder-decoder network \citep{Cho2014emnlp}, where ResNet \citet{resnet} is employed as the feature extractor on each frame. We denote results using this method as {\em ResNet + LSTM }.

\begin{wraptable}{r}{0.6\textwidth}
	\centering
	\vspace{-6mm}
	\caption{\small{Results on BLEU-4, METEOR and CIDEr metrics compared to baselines on MSR-VTT.}}\label{tab:results2}

	\begin{small}
		\begin{tabular}{c|ccc}
			\toprule
			Method& BLEU-4 & METEOR & CIDEr\\
			\midrule
			\multicolumn{4}{c}{\textit{Baselines}}\\
			\midrule
			ResNet + LSTM & 39.54 & 26.59 & 45.22 \\
			C3D fc7 + LSTM & 40.17 & 26.86 & 45.95 \\
			\midrule
			\multicolumn{4}{c}{\textit{Spatiotemporal attention + LSTM}}\\
			\midrule
			C3D fc7 +  pool2 & 40.43 & 26.93 & 47.15\\
			C3D fc7 + pool3 & 42.04 & 27.18 & 48.93\\
			C3D fc7 +  pool4 & 41.98 & 27.42 & 48.21\\
			C3D fc7 + pool5 & 40.83 & 27.01 & 47.86\\
			\midrule
			\multicolumn{4}{c}{\textit{ASTAR}}\\
			\midrule
			soft attention &  43.72 & {\bf 29.67}  &  50.21\\
			hard attention &  {\bf 43.89} &  28.71  &  {\bf 50.29}\\
			\bottomrule
		\end{tabular}
	\end{small}
\end{wraptable}

\subsection{Quantitative Results}
Results are summarized in Tables \ref{tab:results1} and \ref{tab:results2}, and we obtain state-of-the-art results on both Youtube2Text and M-VAD datasets. On the MSR-VTT dataset, our results also significantly outperform the strong baselines, demonstrating the effectiveness of the proposed model. Note that no comparative results exist in the literature for MSR-VTT. As a reference, with similar settings, \citet{MSRVTT} using \emph{C3D fc7 + LSTM} achieved 39.9 on BLEU-4 and 29.3 on METEOR using the standard testing set, while state-of-the-art results are 40.8 on BLEU-4, 28.2 on METEOR, and 44.8 on CIDEr, achieved by team ``v2t\_navigator" from RUC and CMU \footnote{http://ms-multimedia-challenge.com/leaderboard}.

It is worth noting that our model consistently yields significant improvements over models with only spatiotemporal attention, which further achieve better performance than only taking the C3D top fully-connected layer features; this demonstrates the importance of leveraging intermediate convolutional layer features.
In addition, we achieve these results using a single model, without averaging over an ensemble of such models.

\begin{figure}[th!]

	\vspace{4mm}
	\includegraphics[width=\textwidth]{figs/att_results1.png}
	\caption{\small Visualization of attention weights aligned with input video and generated caption on Youtube2Text: (top) Sampled frames of input video, (middle) soft attention, (bottom) hard attention. We show the frame with the strongest attention weights. The bar plot above each frame corresponds layer attention weights ${\boldsymbol \beta}_{tl}$ when the corresponding word (under the frame) is generated.}
	\vspace{-2mm}
	\label{fig:vis_att}
\end{figure}
\begin{figure}[th!]

	\vspace{4mm}
	\includegraphics[width=\textwidth]{figs/caption.pdf}
	\caption{\small Examples of generated captions with sampled frames of input video on YouTube2Text.}
	\vspace{-2mm}
	\label{fig:gen_cap}
\end{figure}
\subsection{Qualitative Results}
Following \citet{Attend}, we visualize the attention components learned by our model on Youtube2Text in Figure \ref{fig:vis_att}. As can be seen from Figure \ref{fig:vis_att}, the spatiotemporal attention aligns the objects in the video well with the corresponding words. In addition, the abstraction-level attention tends to focus on low level features when the model will generate a noun and high level features when an article or a preposition is to be generated. More results are provided in Appendix \ref{sec:att_result}.

Examples of generated captions from unseen videos on Youtube2Text are shown in Figure \ref{fig:gen_cap}. We find the results with abstraction-layer attention (indicated as ``soft attention" or `` hard attention") is generally equal to or better than the best results, compared to those only taking a certain convolutional-layer feature (indicated as ``Pool2" \textit{etc.}) . It demonstrates the effectiveness of our abstraction layer attention.
More results are provided in Appendix \ref{sec:cap_result} and http://www.cs.toronto.edu/pub/cuty/videocaption/.

\section{Conclusion and Future Work}
We have proposed a novel video captioning model, that adaptively selects/weights the feature abstraction (CNN layer), as well as the location within a layer-dependent feature map. We have implemented the attention using both ``hard'' and ``soft'' mechanisms, with the latter typically delivering better performance. Our model achieves excellent video caption generation performance, and has the capacity to provide interpretable alignments seemingly analogous to human perception.

We have focused on analysis of videos and associated captions.
Similar ideas may be applied in the future to image captioning. Additionally, the CNN parameters were learned separately as a first step, prior to analysis of the captions. It is also of interest to consider CNN-parameter refinement conditioned on observed training captions.
\clearpage

redpajama_set_name: RedPajamaArXiv


text:
Q: Fortran Dll import There is a code in Fortran by  Robert L. Parker and Philip B. Stark:
FORTRAN
      subroutine bv(key, m, n, a, b, bl, bu, x, w, act, zz, istate,  loopA)
      implicit double precision (a-h, o-z)
!      x  is an unknown n-vector
!      a  is a given m by n matrix
!      b  is a given  m-vector
!      bl is a given n-vector of lower bounds on the components of x.
!      bu is a given n-vector of upper bounds on the components of x.
!      key = 0
!   ---Output parameters:
!      x   the solution vector.
!      w(1)    the minimum 2-norm || a.x-b ||.
!  istate  vector indicating which components of  x  are active
!  loopA   number of iterations taken in the main loop, Loop A.
!  ---Working  arrays:
!  w      dimension n.               act      dimension m*(mm+2). mm=min(m,n).
!  zz     dimension m.               istate   dimension n+1.

I am trying to call that function from a dll in c# like:
C#
class Program
{
    [DllImport("bv.dll", CallingConvention = CallingConvention.StdCall )]
    public static extern void bvls(
         int key, //key = 0, the subroutine solves the problem from scratch. If key > 0 the routine initializes using the user's guess about which components of  x  are `active'
         int m,
         int n,
        double[] a, //  m by n matrix
        double[] b, //  m-vector
        double[] bl, //n-vector of lower bounds on the components of x.
        double[] bu, //n-vector of upper bounds on the components of x.
        ref double[] x, //unknown n-vector
        //Working  arrays:
        ref double[] w,  //dimension n
        double[] act, //dimension m*(mm+2). mm=min(m,n).
         double[] zz, //dimension m
        ref double[] istate, //dimension n+1.
        ref int loopA //   number of iterations taken in the main loop, Loop A.
        );

    static void Main(string[] args)
    {
        double[] a = new double[3 * 3] { //M*N
                  1.0, 10.0, 10.0,
                  2.0, 18.0, 16.0,
                  1.8, 69.0, 16.0
        };
        double[] b = new double[3]  {  //LDB*NRHS
             4.3, 6.8, 1.0,
        };
        double[] bl = new double[3];
        double[] bu = new double[3];
        double[] x = new double[3];
        double[] w = new double[3];
        double[] act = new double[3* 5];  //dimension m*(mm+2). mm=min(m,n).
        double[] zz = new double[3];
        double[] istate = new double[4];
        int loopA =0;
        Program.bv(0, 3, 3, a, b, bl, bu, ref x, ref w, act, zz, ref istate, ref loopA);
        for (int j = 0; j < 3; j++)
            Console.Write(" \t" + x[j]);

    }
}

However when executing the code I get
EntryPointNotFoundException: Entry point was not found. in 'bv' on file 'bv.dll'.
    myProject.Program.bv(Int32 key, Int32 m, Int32 n, Double[] a, Double[] b, Double[] bl, Double[] bu, Double[]& x, Double[]& w, Double[] act, Double[] zz, Double[]& istate, Int32& loopA)

Basically I have 2 questions,
How to get this to work? and other question,is it correct the way I defined the function
 [DllImport("bv.dll", CallingConvention = CallingConvention.StdCall )]
            public static extern void bvls(...)

based on the routine information of fortran code?
When using dependency walker I get:

I am suspecting dll is not correct and does not have the routine, Is there a way to check if dll was generated the right way?
UPDATE
After trying  ILSpy I get following which seems incorrect, could you please suggest how to gen dll file correctly?, Does ILSpy  tells that bvlsFortran is the function I should use? I tried it but couldn't get it to work

A: Try this in FORTRAN:
MODULE CALCBV

    INTEGER, PARAMETER :: sp = SELECTED_REAL_KIND(p=6,r=37)     ! IEEE Single Precision (32-bit)
    INTEGER, PARAMETER :: dp = SELECTED_REAL_KIND(p=15,r=307)   ! IEEE Double Precision (64-bit)

CONTAINS

    subroutine bv(key, m, n, a, b, bl, bu, x, w, act, zz, istate,  loopA)
    IMPLICIT NONE
    !DEC$ ATTRIBUTES DLLEXPORT :: bv
    !DEC$ ATTRIBUTES ALIAS:'BV' :: bv
    !DEC$ ATTRIBUTES VALUE :: key, m, n

    INTEGER, INTENT(IN)   :: key, m, n
    REAL(dp), INTENT(IN)  :: a(m,n), b(m), bl(n), bu(n)
    REAL(dp), INTENT(OUT) :: x(n), w(n)
    REAL(dp), INTENT(IN)  :: act(m,MIN(m,n)+2), zz(m)
    INTEGER, INTENT(OUT)  :: istate(n+1)
    INTEGER, INTENT(OUT)  :: loopA

    ! DO CALC HERE

    end subroutine

END MODULE

And then call it from C# with:
[DllImport("bv.dll", CallingConvention=CallingConvention.Cdecl, EntryPoint="BV")]
static extern void bvls(
    int key, //key = 0, the subroutine solves the problem from scratch. If key > 0 the routine initializes using the user's guess about which components of  x  are `active'
    int m,
    int n,
    double[] a, //  m by n matrix
    double[] b, //  m-vector
    double[] bl, //n-vector of lower bounds on the components of x.
    double[] bu, //n-vector of upper bounds on the components of x.
    double[] x, //unknown n-vector
    //Working  arrays:
    double[] w,  //dimension n
    double[] act, //dimension m*(mm+2). mm=min(m,n).
    double[] zz, //dimension m
    int[] istate, //dimension n+1.
    ref int loopA //   number of iterations taken in the main loop, Loop A.
    );

// Test code
static void BVTEST()
{
    int key=0, n=2, m=3;
    double[] a= { 1.0, 2.0, 3.0, 4.0, 5.0 };
    double[] b= { 10.0, 20.0, 30.0 };
    double[] bl= { 0.0, 1.0 };
    double[] bu= { 1.0, 2.0 };
    double[] x=new double[n];
    double[] w=new double[n];
    double[] act=new double[m*Math.Min(m, n)+2];
    double[] zz=new double[m];
    int[] istate=new int[n+1];
    int loopA = 0;
    // Call Fortran .dll
    bvls(key, m, n, a, b, bl, bu, x, w, act, zz, istate, ref loopA);
}

Remember arrays are already reference types (the default) so they don't need ref keyword. Output values need it like with loopA, but passed by value arguments need the VALUE attribute declaration in order to avoid passing them with ref, like with key, m, n. You might need to fix the size of act to something bigger that it is because I am getting some memory corruption in the parameters after this.
This posting should get you going in the right direction. Remember always use Cdecl with FORTRAN .dll and always use implicit none declarations. Compile as x86 and Win32 and do not use AnyCPU. Declare your exports with the ALIAS attirbute in order to show up.

A: Looking at your latest update, it seems that your Fortran compiler has emitted a .net assembly. You should add that as a reference and forget all about the p/invoke. Consume the .net assembly as you would any other.

This is the original answer, commenting on the p/invoke
There seems to be some confusion in the question over the name of the function. Is it bv or bvls? In any case the Fortran compiler may decorate it. Use Dependency Walker to find out its name. OK, I see you tried that. It seems that your compilation of the DLL has failed to export the function. You'll need to find out how your particular compiler marks functions for export.
The calling convention could be stdcall or cdecl. That depends on how the DLL was compiled, and the compiler used. IIRC, most Fortran compilers on Windows will use stdcall. Check in the compiler docs.
You used ref for a couple of the array parameters. That is not correct. Remove ref from the array parameters. Arrays are marshalled as pointer to first element. You never marshal arrays to native by ref since the native code cannot make a managed array.
The istate parameter is of type int[]. Other than that I think you've got the types correct.
I've not checked how you prepare the parameters. Worth double checking that in due course. You'll certainly need to make sure you respect Fortran's col major storage.

A: I would start by trying to generate a DLL for a small example, making it run, than going for that big FORTRAN code of yours.
In the past I had a some problem creating a FORTRAN DLL and calling it from my C# code.
First thing you should do is get yourself a cool compiler for that FORTRAN code, I used Open Watcom in that time because it has an easy to use IDE. And I generated my dll from it.
Here is the first FORTRAN code that I tryed:
*$pragma aux DON "DON" export parm(value*8, reference, reference)

  SUBROUTINE DON(DAA,DBB,DCC)
  REAL*8, DAA,DBB,DCC
  DBB=DAA+1
  DCC=DBB+1
  RETURN
  END

The $pragma directive is for Open Watcom Compiler use only.  So don't mind it if you're gonna be using a different compiler.
This is a simple subroutine for you to test. If you can make that work for you, you're gonna be half your way for making that huge one that you want. :-)
The C# code I used to call it was this one here:
[DllImport("Lks.dll",
        CharSet = CharSet.Auto,
        CallingConvention = CallingConvention.StdCall)]
    public static extern void DON(
        [MarshalAs(UnmanagedType.R8)]     double DAA,
        [MarshalAs(UnmanagedType.R8)] ref double DBB,
        [MarshalAs(UnmanagedType.R8)] ref double DCC
        );

    static unsafe void Main(string[] args)
    {
        //double TIME = 100.0;
        double DAA = 5.5;
        double DBB = 7;
        double DCC = 9;
        //START( ENERIN, VAL1);
        DON(DAA, DBB, DCC);

        Console.Write("val1 = " + DAA);
        Console.Write("val2 = " + DCC);
        Debug.WriteLine("VAR = " + DBB.ToString());
        Console.Write("Press any key to exit");
        Console.ReadKey(false);
    }

So for your case I think you can do almost the same but you will need to watch out for getting the right types on MarshalAs.
This worked for me, and I hope it points you to the right direction. You can get the Open Watcom from here (http://www.openwatcom.org/)
I'm a noob, and this is my first answer so don't mind me if I couldn't help.
-Roiw

redpajama_set_name: RedPajamaStackExchange


Used in high tech clean room operations. Adhesive surface captures dirt and dust particles from foot and equipment traffic. Easy to use peel-away sheets provide a fresh surface area immediately. Protective anti-microbial feature prevents bacteria growth. Supplied in packs of 8 x 30.


Faviana style S7806 features a sweetheart neckline that will flatter your shape, while the jersey skirt will elongate your frame. The front cut outs�are lined with mesh in order to show minimal skin. The back features architecturally placed detail beading that make a statement. Pair this jersey dress with stacked bangles or teardrop earrings. You are sure to make a statement at your next evening event!


Options for Window Graphics in Riverside, CA.
One of the challenges that businesses in Riverside, CA. face is trying to find creative ways to let customers know where they are and what they do. Often times businesses will look at a variety of different options such as websites, newspaper ads, flyers, commercials and more; but neglect to look at the unused real estate that is right in front of them.
Window graphics is a great way to help put out some of the most important information about your business and/or put attention grabbing graphics; right on the front of your business using the existing window space that you have. Whether you have a business in a strip mall or standalone establishment, chances are much of your building is wrapped in windows that can be utilized as billboard space help get your message out.
Depending on the size and location that you would want to get window graphics applied, there are many different choices that can be catered based upon your budget and your needs. Single color diecut window graphic stickers allow a traditional, single color labeling for words and simple logos to be placed onto the Windows. Full color diecut window graphics can accomplish the same as single color but with a little more flair, especially if you have tended windows that allow for more color options. full color, full coverage window graphics allow you to use every square inch of your windows to be wrapped just like you would a car allowing for expressive graphics that can really get your customers attention.
So you can understand better the advantages for each let's look at some of the details about these three different types of products.
Single color diecut window graphics, traditionally done in white, is a great and affordable way to help put information on the front of your business. Text and simple shapes our best to be used with this type of window lettering. Made from a high grade, weather resistant, vinyl window lettering for the front of your business in Riverside, CA. can easily last five years or more.
Those businesses that have an overhang where the diecut window graphics are not in direct sunlight, the vinyl used by Precision Sign and Graphics can last even longer. You would care for windows treated with diecut window graphics with a soapy solution just as you would treat the glass. Reverse diecut window graphics can be done as well putting the graphics on the inside of the window. While diecut window graphics is a little bit more labor it does traditionally work out to be less expensive than full coverage window graphics.
Along the same lines as single color, full color diecut window graphics can be created to give your window application that extra pizzazz. Whether a combination of colors or a full color prints we can diecut shapes to provide a greater variety of options. Uses for full color diecut window graphics would be multi-colored logos, a lettering or graphic that would have a printed pattern or bursts of colors that would draw more attention. Because color has a tendency to fade we treat all of our full color diecut window graphics with UV coating to help increase the life of the graphics.
Growing in popularity in the Riverside, CA. area is the use of full color, full coverage window graphics. By utilizing full color, full coverage window graphics it opens up the pallet of possibilities for colors and design choices to really make the front of your business stand out.
There are multiple types of full color, full coverage window graphics vinyl that is used, depending on the application, however all of our full color, full coverage window graphics utilizes UV coating for the protection and reduction of color fading. In addition you can also choose to have a full color, full coverage window graphics that are translucent, like a tent, as well as a popular textured full color, full coverage window graphics that allows it to be easily seen through from the inside.
Utilizing full color, full coverage window graphics for 100% coverage of your windows, or sections of Windows, really allows for full expression of your message, slogans, pictures and information to be easily read at a distance; not to mention with attention grabbing colors it can really help set your business apart from your competitors.
Precision Sign and Graphics serving the Riverside, CA. area and surrounding communities knows what it takes to get your message out. Our professional design artists can take your idea and crafted into a work of art that will be sure to get you noticed. We can also help brand the color scheme of your window graphics to match your website, business cards and other forms of advertising venues to properly brand your business. Give us a call today for your free consultation to get started on your window graphic application.


Radio commercials are invisible. But images do happen, in your mind.
While the 1960s shift in print and TV advertising has been heavily documented and mythologized by Mad Men, Madison Avenue's radiophonic collision with the counterculture is less well known.
In this featured episode, radio advertising producer, writer and composer Clive Desmond covers the golden age of radio ads, including Frank Zappa, Ken Nordine, Linda Ronstadt, and Randy Newman.
Desmond takes listeners on a highly subjective journey through one narrow, eccentric, corridor of radio advertising. He's been working in the field for more than thirty years, and he's won some of the industry's top awards.
In this piece, A 700-Foot Mountain Of Whipped Cream, he has rescued beautiful forgotten nuggets of radio history and delicately arranged them into a glittering associative chain—a constellation of jingles and spots that somehow all add up to more.
A version of this two part episode was originally featured on The Organist, a bi-weekly experimental arts-and-culture program from McSweeney's and KCRW, under the title A 700-Foot Mountain of Whipped Cream. Executive Producer Andrew Leland.


Thailand remains a popular teaching abroad destination for experienced ESL teachers, international schoolteachers and new university graduates alike. Known more as a destination for teachers early in their careers, there are a still a number of reasons why people choose to teach in Thailand.
Thailand, also called the Land of Smiles, is known for its friendly people, gorgeous beaches, active nightlife in main cities, and laid back lifestyle. There is a strong demand for ESL teachers in Thailand and there is also a good standard of international schools that hire schoolteachers for various subjects each year.
ESL teachers can find employment with government schools, private language centers, and, to a limited extent, universities. However, just as is the case in many other countries, there is a huge variety in the quality of teaching opportunities available to those looking to teach in Thailand. Many ESL employers will do their hiring locally, meaning they will hire ESL teachers who are already based in the country, so teachers are encouraged to visit their potential employer before committing to a contract.
By contrast, many of the reputable international schools in Thailand will do their hiring exclusively overseas. It is still possible to find a job at an international school or private school if you are already located in Thailand, but the preference for many schools is to recruit from abroad.
The majority of the teaching jobs available in Thailand will be geared more towards ESL teachers in the early stages of their teaching career. However, if you are an experienced ESL teacher or a qualified and experienced schoolteacher, there are still suitable opportunities available as long as you are patient with your search.
There is a high volume of ESL teaching positions available for new university graduates. If you possess a BA and TEFL/CELTA certificate, you can be sure to find a suitable teaching job. Salaries vary depending on location (city or rural) and the quality of the employer but you can expect between 25,000 THB – 35,000 THB ($780 to $1,100) per month, medical insurance not normally provided, accommodation most likely not provided, and no return flights to your home country.
BA + TEFL is highly recommended.
Established language schools and private education providers have a need for qualified ESL teachers in Thailand. Packages vary depending on your education and teaching experience as well as the quality of the employer. Average salaries between 30,000 THB to 45,000 THB ($1,000 to $1,400) per month (more experienced teachers can earn 40,000 - 70,000 THB +). Accommodation is sometimes offered, medical insurance is provided or partially provided, and some employers may offer a return flight (although this is not common). Salaries will be higher in Bangkok compared to other cities.
The quality of international schools and the packages that they offer vary even within major cities. The main British and American international schools in Bangkok are known to be competitive for places and have better salaries and packages than some newer international and private schools in Bangkok and other parts of the country. Teachers can expect salaries between 70,000 THB to 120,000 THB ($2,200 to $3,800) per month depending on the school and the location. Many schools provide accommodation and medical benefits, but most schools do not provide return flights to home countries for their teachers.
BA + Teaching Certificate/PGCE or B.Ed. Some schools will higher inexperienced teachers as long as they have the education background, but most schools will look for 2 years teaching experience.


text:
Jul 7 What does "4:44" by Jay-Z mean?
song lyrics blog post, song lyrics meaning
Lyrics Meaning of "4:44"
You're going to have a heart attack, but I didn't really get into music until after Jay-Z stopped producing music because he had to manage a label and not seem like he was biased towards promoting his own music. So, that being said, I don't know a lot about him other than all of the all-but-confirmed (by his and Beyonce's lyrics) rumors that he cheated on Beyonce. But I feel like "4:44" is about all of the introduction I need to who he is. He lays out everything here.
Don't forget to check out my podcast on iTunes and here!
"I'm never gonna treat you like I should"
"4:44" is Jay-Z apologizing for the things he's done to his wife and to his kids. He tells us that he wishes he hadn't had an affair and worries about what his children will think of him when they are old enough to find out. He actually thought of the song when he woke up in the middle of the night at 4:44 AM. He wrote it down, and now we have quite a bit to explain the details of.
Do I find it so hard
When I know in my heart
I'm letting you down every day
Letting you down every day
Why do I keep on running away?
Singer Hannah Williams lays down the melodic vocals for Jay Z's rap track singing, "Do I find it so hard / When I know in my heart / I'm letting you down every day?" She's singing from Jay-Z's perspective here to Beyonce, his wife. Jay-Z wishes he were a better husband and struggles with his limitations and mistakes as a human. Hannah Williams wonders for him, "Why do I keep running away?" as he thinks about how he keeps messing up.
Look, I apologize, often womanize
Took for my child to be born
See through a woman's eyes
Took for these natural twins to believe in miracles
Took me too long for this song
I don't deserve you
I harass you out in Paris
"Please come back to Rome," you make it home
We talked for hours when you were on tour
"Please pick up the phone, pick up the phone"
Said, "Don't embarrass me," instead of "Be mine"
That was my proposal for us to go steady
That was your 21st birthday
You mature faster than me, I wasn't ready
So I apologize
I seen the innocence leave your eyes
I still mourn this death and
I apologize for all the stillborns
'Cause I wasn't present, your body wouldn't accept it
I apologize to all the women whom I
Toyed with your emotions because I was emotionless
And I apologize 'cause at your best you are love
And because I fall short of what I say I'm all about
Your eyes leave with the soul that your body once housed
And you stare blankly into space
Thinkin' of all the time, you wasted it on all this basic shit
Jay-Z tells us in this first verse of "4:44" that he apologizes for his past as a womanizer and admits that it "[t]ook for my child to be born" to be able to "[s]ee through a woman's eyes." It wasn't until his first child was born that he understood how much pain he was causing. And he continues, singing that when his "natural twins" were born, he began to "believe in miracles," leaving him a better person.
He admits that it took him "too long for this song" in which he apologizes to Beyonce and acknowledges his mistakes and blessings. He wishes he'd made these feelings public earlier. He admits that he doesn't "deserve you" to Beyonce and remembers a time when he "harass[ed] you out in Paris." He asked her to "come back to Rome," which she did, and he feels bad perhaps for ordering her around or for being inconsiderate. But he was still crazy about her and talked with her "for hours when you were on tour" and remembers hoping that she'd be able to "pick up the phone" when he called so he could talk with her.
When they got together "to go steady," Beyonce was twenty-one and Jay-Z, lacking finance or true care for her, told her, "Don't embarrass me," and regrets having been so callous, realizing now that she is actually the more mature one and that he was the one who "wasn't ready." He needed her more than he expected, and now he wishes he could change what he said: "So I apologize."
Over the course of their relationship, he's "seen the innocence leave your eyes" as difficult things have happened to her and as he's hurt her repeatedly. He "mourn[s] this death" of innocence and apologizes "for all the stillborns / 'Cause I wasn't present, your body won't accept it." We know that Beyonce miscarried at least once, so "all the" could refer to their love not being ready or mature being a sort of stillborn. Looking back, he rationalizes that because he wasn't emotionally present (and was likely cheating on her) maybe that's why her body seemed to have decided it wasn't time to give birth.
Jay-Z continues with the apologies of "4:44" by apologizing "to all the women whom I / Toyed with your emotions because I was emotionless." This could be about women he dated before his wife; he seems to have been a bit of a player. But he then focuses the apologies right back on his wife rapping, "And I apologize 'cause at your best, you are love." She seems to be so kind and so forgiving here that Jay-Z doesn't waste time saying that she's loving. He just calls her love itself incarnate.
Compared to her, he knows he "fall[s] short of what I say I'm all about." And this knowledge hurts him even more because he knows it's what sometimes causes her "eyes [to] leave with the soul that your body once housed / And you stare blankly into space." As she stares off into space when she's with him, he worries that he might be losing her. He worries that she's "[t]hinkin' of all the time, you wasted it on all this basic shit"--his basic shit as he kept failing her.
And appropriately, he finishes the first verse by rapping, "So I apologize."
I'm never gonna treat you
I'm never gonna treat you like I should
Hannah Williams provides the refrain to Jay-Z's thoughts, reminding listeners that Jay-Z is very aware of his own status as someone who continues to fail to treat those he loves as well as he wishes he would. It's a sad and soft moment in the song, and it summarizes everything he's saying very well.
Our love was one for the ages and I contained us
And all this ratchet shit and we more expansive
Not meant to cry and die alone in these mansions
Or sleep with our back turned
We supposed to vacay 'til our backs burn
We're supposed to laugh 'til our heart stops
And then meet in a space where the dark stop
And let love light the way
Like the men before me, I cut off my nose to spite my face
I never wanted another woman to know
Something about me that you didn't know
I promised, I cried, I couldn't hold
I suck at love; I think I need a do-over
I will be emotionally available if I invited you over
I stew over, what if you over my shit?
Jay-Z begins the second verse by apologizing again and bemoaning how he hurt a love that "was one for the ages" and how it was him who "contained us"--or kept them from expanding and growing in love together. He then marvels at how despite this "ratchet shit" he's caused, they continue to grow "more expansive" and loving together (and seems like he would probably attribute that to her love).
He doesn't want their relationship to end with them crying and "[dying} alone in these mansions" or "sleep[ing] with our back turned." He wants them together and happy and in love. Their real life, he proposes should involve them going on vacation together (so much so they get sunburns) and laughing together "'til our heart stops." When he refers to them meeting "in a space where the dark stop / And let love light the way," he could be talking about sex and the spiritual ecstasy it might bring them. Or he could be talking about them overcoming obstacles through the power of love together.
He complains that "like the men before me," he "cut off [his] nose to spite [his] face." Perhaps he was mad at Beyonce, and that encouraged him to cheat on her. He wanted to hurt the person he loved, so he risked losing that person. But he claims that he still "never wanted another woman to know / Something about me that you didn't know." Perhaps through the cheating, he still wanted to go back to Beyonce and not give her up completely. He didn't share any secrets with other women that he wouldn't share with Beyonce (other than perhaps the secret of cheating itself). And perhaps when Beyonce found out, Jay-Z "promised" to do better and "cried" for forgiveness, but he "couldn't hold" and maybe made another mistake again.
He admits, "I suck at love; I think I need a do-over." He wants to be able to go back and correct past mistakes so that they don't hurt his wife. And he promises that if he "invited you over," he will be "emotionally available," so that she knows he's with her. He also admits that he "stew[s] over" his concerns that she may be tired of his "shit" and all the ways he's messed up. He feels like he's sometimes on the edge of finally destroying her patience.
And if my children knew, I don't even know what I would do
If they ain't look at me the same
I would prob'ly die with all the shame
"You did what with who?"
What good is a ménage à trois when you have a soulmate?
"You risked that for Blue?"
If I wasn't a superhero in your face
My heart breaks for the day I have to explain my mistakes
And the mask goes away, and Santa Claus is fake
And you go online and see
For Blue's tooth, the tooth fairy didn't pay
The third and final verse of "4:44" has Jay-Z taking a look at how his actions might affect his children. He raps, "And if my children knew, I don't even know what I would do / If they ain't look at me the same / I would prob'ly die with all the shame." He knows his wife has forgiven him (though he doubts it sometimes) and hopes that his children will be able to do the same.
He imagines them asking, "You did what with who? / What good is a menage a trois when you have a soulmate? / You risked that for Blue?" A menage a trois is a relationship involving three people, Jay-Z being the one who brings another sexually active person into the situation by cheating on Beyonce with her. The third question is a little more confusing and seems to be his hypothetical child asking why Jay-Z risked hurting his child (Blue Ivy) by having another sexual partner.
He wants desperately to be a "superhero" in the faces of his children and tells us that his "heart breaks for the day I have to explain my mistakes / And the mask goes away, and Santa Clause is fake." Santa Clause isn't real and is a lie that parents tell their children knowing one day the kids will find out. Jay-Z feels like Santa Clause. His kids might think he's great for a while, but he wonders how they'll deal with knowing the truth that their dad cheated on their mom, information they will be able to find easily by going "online."
His last line--"For Blue's tooth, the tooth fairy didn't pay"--is him continuing to think about how he'll have to rip down the curtain and reveal the man behind when his children age.
Deeper Meaning of "4:44" by Jay-Z: Getting It Over With
I really love "4:44" and just about everything else from the album of the same name. Jay-Z is amazing as an artist and lyricist, and I simply love how real and honest he gets here. He's got some powerful personal experience to share, and I wonder if perhaps he writes songs like this as his way of explaining to his children what he did before they can find out another way. Perhaps when they get old enough, he'll play this song for them and let them find out from him what they might have found out from someone else.
As far as the first two verses go, he appears to be apologizing to Beyonce in a public way, the same way that she already forgave him on her Lemonade album. He's amazed by her ability to do so, and now we have this album to fit into the spaces Lemonade left us.
Jay-Z has done an incredible job here, and I can't wait to hear what you think. What was your favorite part of this song? Do you think it's deep or not?
jayz, jayzee, jay-z, jay z, song lyrics, meaning, music, 444, 4:44, 4:44 lyrics meaning, song meaning, music pop, clifford stumme, pop song professor
Jul 13 What does "Woman" by Kesha mean?
Jul 6 What does "Praying" by Kesha mean?

redpajama_set_name: RedPajamaCommonCrawl


text:
Housecall Telemedicine
Your data, your doctor, your time.
The Doctor Will See You Onscreen : The New Yorker
April 14, 2014 April 14, 2014 / crcaldwell
A fantastic review of the challenge of telemedicine today.
The Doctor Will See You Onscreen : The New Yorker.
One night last summer, when I was working as a medical student in an emergency room, a woman pulled me aside. Her left eye was pink and looked painfully irritated. She had been waiting for hours to get it checked but would have to leave soon to catch a train home. How much longer, she asked, before she could be seen?
A doctor was able to evaluate the patient before she dashed out the door, but her dilemma struck me. We buy groceries, trade stocks, and chat with friends across the globe without getting out of bed. Yet seeing a doctor remains a fantastically old-fashioned routine: minutes of medical attention can cost hours spent in transit or in a waiting room. When the price of losing that time gets too high, we might not even bother to be seen.
There's a potential solution to this problem: using technology to deliver health care remotely. That approach, known as telemedicine, involves locating available doctors over the Internet and connecting with them, at a moment's notice, using video chat. Telemedicine lets you see a doctor whenever and wherever you want, freeing you to choose a doctor based on merit rather than location. It can also improve the quality of medical care and reduce costs.
Telemedicine works especially well for urgent care, which deals with issues that need prompt attention but can be diagnosed and treated without an in-person exam—respiratory illnesses or urinary tract infections, for example. But it has many other possible uses. A study published last month in Health Affairs focussed on an off-hours telemedicine service in a chain of Massachusetts nursing homes. When residents got sick, an outside physician could use two-way video-conferencing equipment to see them instead of going to the facility in person or transferring patients to a hospital. Homes that used the service regularly sent a smaller portion of residents to the hospital than those that didn't. The cost savings for Medicare, which would have had to pay for those hospital visits, far exceeded the cost of the telemedicine service.
In 2010—around the time that the nursing-home study was being conducted—telemedicine seemed on the verge of a breakthrough. Milt Freudenheim wrote, in the Times, that telemedicine was "gaining traction as never before"; Bernard A. Harris, Jr., a venture capitalist, told him that Americans were arriving at "a gold rush of new investment in telemedicine."
But there was a problem: many health-care providers weren't on board. In the nursing-home study, for example, two of the facilities barely used their telemedicine services. Not surprisingly, their hospitalization rates were similar to those of facilities that didn't have telemedicine capabilities. "Simply making off-hours telemedicine coverage available does not guarantee that nursing homes will use the service," the study's authors wrote. In this instance, the staff had no incentive to learn a new system. Avoiding unnecessary hospitalizations didn't save them money—in fact, it cost them money. "As long as nursing homes pay for the service and Medicare realizes the savings that result, we suspect that the use of the service will be limited," the authors wrote.
In the wake of the Affordable Care Act, the outlook may be changing. Health-care providers are forming Accountable Care Organizations, large groups that win bonus payments from the government for meeting certain standards of quality and efficiency but lose money if their costs exceed target levels. Bundled payment schemes pay providers a fixed amount to manage a given medical condition, in contrast to the traditional model that reimbursed a la carte for each service. "In the past, we were paid for the process rather than the outcome," Thomas Nesbitt, the associate vice-chancellor for technology at the University of California Davis Health System, told me. Now, doctors have an added interest in improving their patients' health efficiently. That makes telemedicine newly attractive. "Physicians see that they can manage their chronic-disease patients on a regular basis and achieve better outcomes, and get financial rewards for that," Nesbitt said.
Policymakers are also warming to telemedicine. Medicare, which previously only paid for telemedicine in rural locations, <href="#.uxkamf5rx4w">extended its coverage this year to "the fringes of metropolitan areas," according to the American Telemedicine Association. The number of states making telemedicine coverage mandatory for private insurance plans has also grown—from five in 2000 and twelve in 2011 to nineteen as of early March.
Interest and opportunity, of course, aren't enough. There is also the question of execution—how to schedule virtual patients, document encounters, and ensure that health-care providers get paid. To simplify logistics, the U.C. Davis Health System has a telemedicine clinic that provides technical, operational, and billing support. "The physicians just show up," Nesbitt said. But he acknowledged that, "eventually, if we want telemedicine to be more widespread, incorporating it into the normal workflow process is a barrier we will need to overcome."
Meanwhile, for-profit telemedicine companies, which compete with hospital systems for business, are gaining momentum. "Since the A.C.A., we're seeing a lot of interest in the area," Bob Kocher, a venture capitalist at the firm Venrock, told me. Kocher, who is also a physician and a former special assistant for health care in the White House, recently took part in Venrock's investment in a telemedicine company called Doctor on Demand, which launched in December of 2013. Startups like Doctor on Demand have the potential to offer what Clayton Christensen, a professor at Harvard Business School, calls "disruptive innovation"—innovation from smaller firms at the "bottom" of a market. Eventually, these firms can displace industry leaders.
In his book "The Innovator's Prescription," Christensen proposes that telemedicine can be disruptive if it is used to "extend care into areas of nonconsumption, where the alternative is no health care at all." If competing against nonconsumption is telemedicine's best bet, the people to woo are not payers, providers, or policymakers, but patients. That may be why Doctor on Demand is marketing its services directly to consumers. One of the company's founders is Jay McGraw, the son of Phil "Dr. Phil" McGraw and the creator and executive producer of "The Doctors," a daytime talk show about health and medicine. On his show, Dr. Phil recently demonstrated how the service might work. "If you wanted to see my throat…could I show it to you?" he asked a Doctor on Demand physician via video chat, aiming an iPhone camera at his open mouth. "What if you just need a prescription refill?…What about something like"—he feigned a cough—"Viagra?" The audience laughed and clapped.
As gimmicky as these tactics seem, Doctor on Demand may have tapped into a psychological truth: behavior change is as much about emotion as it is about reason. Simply recognizing the benefits of telemedicine isn't enough; patients must want to use it. "It's like going from buying clothes in the store to online," Pat Basu, the chief medical officer of Doctor on Demand, told me. "The user experience needs to be good, or they won't do it."
Perhaps the user experience will never be good enough to replace face-to-face medicine entirely. Skeptics say that there is no substitute for human touch. In his 2011 TED Talk, titled "A Doctor's Touch," Dr. Abraham Verghese warned against losing the physical exam, stating, "We're losing a ritual that I believe is transformative, transcendent, and is at the heart of the patient-physician relationship."
Then again, as care becomes more accessible, the patient-doctor relationship could change for the better. By turning occasional encounters into ongoing dialogues, telemedicine could enhance, rather than diminish, the human capacity for connection. "A lot of people think it's about the technology," Nesbitt said. "But it's really about a new model of care that the technology facilitates."
Rena Xu is a student at Harvard Medical School and Harvard Business School. She has written for the Web site of the Atlantic and for the New England Journal of Medicine.
← How To Share A Photo or Picture With A Provider in Housecall
Housecall App is FREE for a week! →
Trust, Healthcare, and Technology
Data and Telemedicine: MACRA, MIPS, and Your Data
Care Enough To Care
Why Telemedicine?
Follow Housecall on Twitter
Follow Housecall on Facebook


Being a Marketing Analysis Consultant you will be key to the marketing operations of the organisation. Your core focuses will be to analyse the data collected from CRM and Digital Acquisition channels like paid search, email, display and paid social using tools similar to adobe/google analytics as well as resolving problems around data integrity, data segments/filters. As this is a Consultant role a large part of your role will be working with c-suite level stakeholders and consulting them on your findings and presenting them with in depth customer insight analysis. Confidence working with large data sets is essential as you will be working with this organisations key accounts which are top tier, industry leading organisations with larger customer databases.


SB Projects founder Scooter Braun, Geffen Records President Neil Jacobson and Warner Music Group Global VP of A&R Aton Ben-Horin were recognized as "Ambassadors of Peace" by Hollywood organization Creative Community for Peace (CCFP) on Thursday night. The sold out event held in the backyard of entertainment attorney Aaron Rosenberg and TV producer Danny Rose's lavish Hancock Park home was a who's who of industry bigwigs from the film, television and music worlds. The fundraiser was organized by CCFP co-chair David Renzer of Spirit Music Group (pictured above, at right).
While Israel is the focal point of CCFP's efforts — specifically targeting the BDS (Boycott-Divestment-Sanctions) boycott of western artists performing in the country, led by Pink Floyd's Roger Waters — the greater message of peace and bridge-building through artistic freedom also resonated.
Braun, alongside his very pregnant wife Yael Cohen (eight months along with their third child) described being the grandchild of Holocaust survivors – his grandfather was in Dachau and his grandmother Auschwitz. But despite those hardships, his grandmother lit up every room she entered, he said, also recounting the moment when his client Justin Bieber name-checked her from the stage at his Tel-Aviv concert and also took her by the hand as the group viewed the Yad Vashem museum on that same trip.
When WMG's Ben-Horin came up to accept the award, his Moroccan father and Egyptian mother were front and center, kvelling as his dad recorded the proceedings on his iPhone. The same could be said for his mentor Mike Caren, founder and CEO of Artist Partner Group.
There were several mentions of providing a counter-narrative to the so-called BDS crowd, but for the most part the message isn't meant to polarize or proselytize, as much as preserving and promoting music's universal appeal.
The 400-plus guest list included Warner Bros. Records' new executive team of Co-Chairman/CEO Aaron Bay-Schuck, who started his job officially on Monday, and co-Chairman/COO Tom Corson, along with music attorney Eric Greenspan, songwriting legends Diane Warren and Desmond Child, veteran managers Benny Medina and Andy Gould, ABC VP Scott Igoe, Pulse Music Group's Josh Abraham and Jason Bernard, ASCAP's Loretta Munoz, recording artist Taylor Dayne, Atlantic Records signings Bhad Bhabie and Alec Benjamin (who performed two songs acoustically in honor of Ben-Horin), producer Scott Storch, actor Josh Duhamel, Yiddish theater vet Mike Burstyn and "Fauda" star Rona-Lee Shimon, among a host of others.
Variety was the media sponsor for the event – Israeli-born Executive Editor, Music, Shirley Halperin also received recognition — along with Atlantic Records, The Blavatnik Family Foundation, Sony/ATV Music Publishing, Warner Bros. Records, Warner Music Group and the Leon Charney Resolution Center.


Search the extensive inventory of premium tickets to "Dominy" live! Front Row King has the best online ticket selection including "Dominy" tickets. Our prices for "Dominy" tickets are among the cheapest in the industry! Once your order is placed, an email will be in your email inbox with order details such as a ticket order number, broker phone number, a link to track your order, "Dominy" event information and more information! Go to "Dominy" tickets's concert ... all you need is "Dominy" tickets tickets! "Dominy" concert tickets are on sale now. The large selection of "Dominy" concert tickets available will help you find the tickets you're looking for. Purchase premium tickets to "Dominy"


I honestly have no idea, maybe some sort of brass? It is a really strange color for metal, maybe part of a buoy or anchor?
Certainly has a strange look to it and doesn't have a natural look to it. Can you please post a picture of the full specimen?
Found on the beach in Hull MA - any ideas what it could be?


Cryptic Studios and Atari have announced the development of Neverwinter for the PC. Neverwinter is a new online roleplaying game based on Wizards of the Coast's Dungeons & Dragons and the city of Neverwinter.
In Neverwinter palyers will choose from five D&D classes and play with either AI or friends online in co-op groups. The game also features a content generation system which will allow players to create their own storylines and quests which is one feature that appeal to RPG fans.
The game will coincide with the release of a book trilogy from R. A. Salvatore which will act as a preview of the PC game's settings, charactrer and monsters. A new tabletop RPG from Wizards of the Coast is also planned for next year.
Neverwinter has been scheduled for release during Q4 2011 and hopefuly Cryptic will put the time in with this game and make sure the release is polished. An official website is also now online.


text:
Q: Using the booktabs \midrule and with brackets I am having trouble using \midrule in a latex longtable along with brackets. For example, here is my latex document (test.tex):
\documentclass[a4paper]{article}\usepackage[]{graphicx}\usepackage[]{color}
\usepackage{longtable}
\usepackage{booktabs}

\begin{document}

\begin{longtable}{|l|l|}
\caption{} \\
  \toprule
 test & estimate\\
  \midrule
  (Intercept) & 10.000 \\
  test & 20.000 \\
   \bottomrule
\end{longtable}

\end{document}

When running pdflatex on this file:
pdflatex test.tex

I run into these errors:
! Undefined control sequence.
<argument> ...al \expandafter \let \cmrsideswitch
                                                 \@tempa \fi \fi
l.12   (Intercept)
                  & 10.000 \\

Removing the brackets fixes the issue. And interestingly switching the order of the 2 rows works too [i.e. the (Intercept) row as the second row). I can't figure out what is wrong. Has anyone encountered this?

A: OK, so I had the same problem with code generated from Pandoc (with bracket after \toprule), I fixed it by using \toprule{} instead, it seems that toprule eats the bracket otherwise. Maybe this will help you.
Another possibilty is to put empty \hbox{} before the opening bracket, which I used, since I could not modify tex produced by pandoc (but pandoc is capable of parsing latex snippets in markdown).


February home sales are still at a low since the beginning of the year - will they rise in the upcoming months?
As February begins to wind down to a close, it is time to take a look at home sales for the month – and it seems as if we are seeing more of the same. Throughout the month of January, home sales had gone down 7.8% and February isn't looking much better. The sales for U.S. single-family homes have fallen for the second month in a row.
The Commerce Department has determined that the seasonally adjusted annual rate of home sales (currently 593,000 units) is at the lowest level it's been since August 2017. According to a survey conducted by Reuters economists, sales for new U.S. single-family homes had been expected to rise in January – but they did exactly the opposite. They had expected new home sales – accounting for approximately 10% of the housing market – to rise to a pace of 645,000 units in January. They didn't make a fraction of the cut.
Why did this happen? According to market reports, the waning home sales are a result of the declines in inventory throughout the Northeast and South. With little inventory, it is difficult for clients to find homes that they are willing to buy. In addition, with home sales at such a significant low, mortgage rates are increasing along with the expected value of homes. More expenses account for less interested buyers.
At the rate that home sales have been going for the past couple months, it is expected to take 6.1 months to sell the homes that are currently on the market. If this prediction is true, it will be the longest amount of time that home sales will take to close since July 2014. However, this is not an entirely dreary prediction: while this is longer than it has taken in the past, six-to-seven months is still categorized as a healthy balance of supply and demand. Yes, it'll take a bit longer for homes to sell – but they will still sell in due time. Real estate is a market of balance, and while the sales are low right now, they will inevitably rise again in future months.


Testking EMC EMCIE VPLEX latest study materials and course EMCIE VPLEX EMC test brain dumps online are the most useful products for the absolute success in Testking EMCIE VPLEX exam dumps cert. Successful completion of latest dumps EMC EMCIE VPLEX cert is not a big deal anymore for everybody after using updated Testkings EMC EMCIE VPLEX test braindump and EMCIE VPLEX Certkey EMC bootcamp online audio training. To be a specialized person with EMC EMCIE VPLEX cert and increase your worth in the field of I.T., use Testking's http://www.testkingcerts.com/EMCIE-VPLEX-Certification-Training.htm testing engine and EMCIE VPLEX online practice test and open new horizons of success for yourself. Passing EMC EMCIE VPLEX certification is no big concern any longer as our experts have demonstrated the proficiency with latest EMC Implementation Engineer VPLEX from Testking audio lectures and applied their competencies to bring Test King's EMC EMCIE VPLEX exam brain dumps online.
Get trouble - free preparation for EMC Implementation Engineer VPLEX cert by the EMC Implementation Engineer VPLEX from Test King's online study notes and EMCIE VPLEX EMC online exam brain dumps created by the well recognized professionals. Intensify your progress in EMC EMCIE VPLEX exam using our online EMC EMCIE VPLEX study notes and utilizing EMC Implementation Engineer VPLEX from TestKing's latest test to get maximum advantage over others. Apart from the hectic online EMC EMCIE VPLEX bootcamp, the right instrument for the progress in EMC Implementation Engineer VPLEX cert is right in front of you in the shape of updated Testking's EMC Implementation Engineer VPLEX brain dumps. By including updated EMC Implementation Engineer VPLEX from Testkings practise questions and EMC EMCIE VPLEX audio guide in the study pack for the preparation of EMC EMCIE VPLEX cert, we have facilitated our customers to get a hold on the thorough concepts as soon as possible. To get the clearer picture of how to make it with high score in EMC Implementation Engineer VPLEX cert use updated Testking EMC EMCIE VPLEX preparation materials and updated EMC EMCIE VPLEX testing engine.
The arrangement of updated Testkings EMC Implementation Engineer VPLEX video training with online EMCIE VPLEX audio guide is, no doubt a perfect combination for accomplishing the objective of not only passing with difference but also understanding the complex concepts portrayed in EMC EMCIE VPLEX certification. Our much acclaimed Test King EMC EMCIE VPLEX latest exam braindumps and online EMC Implementation Engineer VPLEX exam engine are specifically intended to develop and utterly comprehend troubleshooting skills, a key element for the better understanding and success in EMC EMCIE VPLEX test. For the preparation of EMC Implementation Engineer VPLEX exam before purchasing online EMC Implementation Engineer VPLEX from Test king questions and answers you can easily check whether it meets your standards or not with the updated EMC EMCIE VPLEX demo practise exam. Passing EMC Implementation Engineer VPLEX cert is a desire of every IT professional as with a little effort and time. Now it is possible with only Test kings EMC Implementation Engineer VPLEX latest notes and online EMC Implementation Engineer VPLEX from Testkings braindumps which are few clicks away. The Testkings EMC Implementation Engineer VPLEX online engine and EMC EMCIE VPLEX from Test kings exam dump so you can easily download and one of the best products u can access to pass your EMC Implementation Engineer VPLEX exam right away. If your dream is to pass EMC Implementation Engineer VPLEX test with superb marks then you must realize the Quality product by Testking which is Testkings EMCIE VPLEX EMC exam braindump and EMC Implementation Engineer VPLEX from Testkings latest test dumps.
Testking's EMC EMCIE VPLEX latest video lectures and latest Testking EMC EMCIE VPLEX lab scenarios contain very important helping materials to pass the EMC Implementation Engineer VPLEX certification with excellent scores. For EMC Implementation Engineer VPLEX cert preparation just downloads the concise updated Test King's EMC EMCIE VPLEX exam preparation materials and Test King's EMCIE VPLEX EMC practise test online and passes EMC EMCIE VPLEX certification easily.
check the EMC EMCIE VPLEX from TestKing's updated sample firstly to prepare mentally for the real product purchase of EMC EMCIE VPLEX test then start easy preparation by EMC Implementation Engineer VPLEX from Testking updated prep materials EMC Implementation Engineer VPLEX classroom training are not a elegant and wise choice as Test kings EMC EMCIE VPLEX updated video training is best alternative for Exam Preparation. They make study very easy as the method of teaching is interactive and you understand easily the concepts. You can pass EMC Implementation Engineer VPLEX certification. Get EMC EMCIE VPLEX from TestKing's questions and answers and latest Testking's EMC Implementation Engineer VPLEX practice exam so that you can experience of real Exam like characteristic for EMCIE VPLEX EMC test. Get benefit the chance to use our guaranteed products like EMCIE VPLEX EMC from Test King's prep guide and Testking's EMCIE VPLEX latest engine that assure your success in passing EMC Implementation Engineer VPLEX test. The excellent latest Test King EMC EMCIE VPLEX practise questions and answers and online EMCIE VPLEX EMC from TestKing's cbt create you contented in timed environment of final EMC Implementation Engineer VPLEX cert paper. EMCIE VPLEX EMC computer based training online educate you in the personal form of online and live tutorials in combination of EMCIE VPLEX EMC from TestKing's latest lab questions are very handy and are very helpful for EMC EMCIE VPLEX test preparation.


text:
Q: Images take a lot of time to load in JSP I have a scenario where I am fetching multiple images from the Oracle database through the loop. But it's taking a lot of time to fetch the images and display it on the browser.
Through, this code I am calling my method with some parameters.
for(Object[] obj: memberDetails)
{
    System.out.println("String.valueOf(obj[0])"+String.valueOf(obj[0]));

    try{
        memberImage=dtSrvc.getQueImageForQC(Id,String.valueOf(obj[0]));
    }
    catch(Exception e)
    {}

    map.put("memImage"+count, memberImage);
    key.add("memImage"+count);
    hmap.put("memImage"+count, memberImage);
    count++;
}

and here is my query through which I am fetching images
ps = conn.prepareStatement("select photo from member_photo where ID='"
                        + Id + "' and que_id=" + QueId);

Please, let me know how can I speed up this process.
I am unable to fetch all images if the network is slow. My application is currently used by many peoples.

A: The problem is that you use individual query to fetch each image from the db. It makes a network overhead. You can try many of the solutions described here to change your code to do one query instead of many. See how to Batching Select Statements in JDBC.
ps = conn.prepareStatement("select photo from member_photo where ID in (" + inClause.toString() + ')');

you don't need que_id if ID is a primary key in the table.

A: My suggestion is about fetching images first and keep them as pure file(temp) on a accessible and public folder of your application, and then simply point them out with simple image resource using img tag.
The process would be like this.
1. Query images and keep them under /a_public_folder/images/... which each images is going be named as 1.jpeg, 2.jpeg where 1 and 2 are ids(unique).
2. keep the ids retrieved from the database with a simple context such as list_id:List<Long>
3. your final servlet would be like the following
for(long idx:list_id){
  out.print("<img src=\"/a_public_folder/images/"+idx+".jpeg\"/>");
}

4.you may also apply a filter for /a_public_folder/images/* path in order to just allow users who have permission to view content/images
5.have a session listener in order to remove associated(fetched) images to the particular user session, or have a daemon thread for cleaning up the directory(images have no links longer) interval.

But I suggest extract images from database to simple pure file and just keep the images path into the database.


So. We've retaken the House. The Senate is teetering but not yet fallen. The Tea Party is triumphant.
We have a famous victory.
Now, GOPers....I'd like to tell you a story about the first space launch.
"Lord, don't let me f*** this up."
Ladies and Gentlemen of the 112th Congress, congratulations. But remember the prayer of Blessed +Alan Shepherd and doest thou likewise.
In the mean time.... beware of lame ducks.


Use the menu below to specify a desired action as it relates to articles. The list view and search are the quickest way to get to the data. Detail view of any article also includes links to export to industry standard NewsML or XML format.