[SJN-50] Enable JTA transactions to work through the DataSource | |
| Status: | Open |
| Project: | Simple-JNDI |
| Component/s: | |
| Affects Version/s: | 0.9.1 |
| Fix Version/s: |
| Type: | New Feature | Priority: | Major |
| Reporter: | Henri Yandell | Assignee: | Henri Yandell |
| Resolution: | Unresolved | ||
| Environment: |
| Description |
| Request made on irc to be able to use transactions/JTA with simple-jndi. |
| Comment by bayard [ Sat, 1 May 2004 11:58:58 -0700 (PDT) ] |
| Nice as it would be to write simple-jta, for simple-jndi this really just means making it a lot easier to do factories of things. Possibly Dave's Bunny project might have investigated how to abstract factory concepts in a persisted String based system. |
| Comment by bayard [ Tue, 4 May 2004 21:46:24 -0700 (PDT) ] |
| Add a #converter subvariable. Possibly rename type subvariable to #type. Avoids clashes. The #converter subvariable would specify a Converter class [interface in simple-jndi] which would have Object convert(String). The default converter would exist and be some of the code destined to be in HierarchicalMap. Is there a way to plug in a converter for the List that is created when a set of values are created? Is #type compatible with other systems? Would it have the .? Seems no point. age#type age#converter. |
| Comment by bayard [ Tue, 4 May 2004 21:48:36 -0700 (PDT) ] |
| But how would this help JTA? The type needs to be on the higher up HierarchicalMap. So: foo.blah.url= foo.blah.password= foo.blah.driver= foo.blah.user= foo.blah#type=javax.sql.DataSource and it is given a Map of values. So should be possible to implement the type=DataSource as a #converter too. Hardcoded. |


Why are Convolutional Neural Networks (CNN) so incredibly good at image classification tasks? CNN architectures make the explicit assumption that the inputs are images, which allows us to encode certain properties into the architecture. These then make the forward function more efficient to implement and vastly reduce the amount of parameters in the network.
Image Classification with CNN
In this project we will build a CNN to classify images from the CIFAR-10 dataset. My goal is to demonstrate how easy one can construct a neural network with descent accuracy (around 70%). Thereby, I used only my laptop’s i7 processor and a couple of hours training time.
Image Dataset
The CIFAR-10 dataset consists of 60000 32x32 color images in 10 categories - airplanes, dogs, cats, and other objects. The dataset is divided into five training batches and one test batch, each with 10000 images. The test batch contains exactly 1000 randomly-selected images from each class. The training batches contain the remaining images in random order, but some training batches may contain more images from one class than another. Between them, the training batches contain exactly 5000 images from each class. Here are the classes in the dataset, as well as 10 random images from each:
The classes are completely mutually exclusive. There is no overlap between automobiles and trucks. “Automobile” includes sedans, SUVs, things of that sort. “Truck” includes only big trucks. Neither includes pickup trucks.
In the following, we will preprocess the images, then train a convolutional neural network on all the samples. The images need to be normalized and the labels need to be one-hot encoded. Next, we will build a convolutional, max pooling, dropout, and fully connected layers. At the end, we will train the network and get to see it’s predictions on the sample images.
Download the dataset
First, few lines of code will download the CIFAR-10 dataset for python.
from urllib.request import urlretrieve
from os.path import isfile, isdir
from tqdm import tqdm
import tarfile
cifar10_dataset_folder_path = 'cifar-10-batches-py'
class DLProgress(tqdm):
last_block = 0
def hook(self, block_num=1, block_size=1, total_size=None):
self.total = total_size
self.update((block_num - self.last_block) * block_size)
self.last_block = block_num
if not isfile('cifar-10-python.tar.gz'):
with DLProgress(unit='B', unit_scale=True, miniters=1, desc='CIFAR-10 Dataset') as pbar:
urlretrieve(
'https://www.cs.toronto.edu/~kriz/cifar-10-python.tar.gz',
'cifar-10-python.tar.gz',
pbar.hook)
if not isdir(cifar10_dataset_folder_path):
with tarfile.open('cifar-10-python.tar.gz') as tar:
tar.extractall()
tar.close()
Data Overview
The dataset is broken into batches - this is especially useful if one is to train the network on a laptop as it will probably prevent it from running out of memory. I only had 12 GB on mine and a single batch used around 3.2 GB - it wouldn’t be possible to load everything at once. Nevertheless, the CIFAR-10 dataset consists of 5 batches, named data_batch_1
, data_batch_2
, etc.. Each batch contains the labels and images that are one of the following:
- airplane
- automobile
- bird
- cat
- deer
- dog
- frog
- horse
- ship
- truck
Understanding a dataset is part of making predictions on the data. Following functions can be used to view different images by changing the batch_id
and sample_id
. The batch_id
is the id for a batch (1-5). The sample_id
is the id for a image and label pair in the batch.
import pickle
import matplotlib.pyplot as plt
LABEL_NAMES = ['airplane', 'automobile', 'bird', 'cat', 'deer', 'dog', 'frog', 'horse', 'ship', 'truck']
def load_cfar10_batch(batch_id):
"""
Load a batch of the dataset
"""
with open(cifar10_dataset_folder_path + '/data_batch_'
+ str(batch_id), mode='rb') as file:
batch = pickle.load(file, encoding='latin1')
features = batch['data'].reshape((len(batch['data']), 3, 32, 32)).transpose(0, 2, 3, 1)
labels = batch['labels']
return features, labels
def display_stats(features, labels, sample_id):
"""
Display Stats of the the dataset
"""
if not (0 <= sample_id < len(features)):
print('{} samples in batch {}. {} is out of range.'
.format(len(features), batch_id, sample_id))
return None
print('\nStats of batch {}:'.format(batch_id))
print('Samples: {}'.format(len(features)))
print('Label Counts: {}'.format(dict(zip(*np.unique(labels, return_counts=True)))))
print('First 20 Labels: {}'.format(labels[:20]))
sample_image = features[sample_id]
sample_label = labels[sample_id]
print('\nExample of Image {}:'.format(sample_id))
print('Image - Min Value: {} Max Value: {}'.format(sample_image.min(), sample_image.max()))
print('Image - Shape: {}'.format(sample_image.shape))
print('Label - Label Id: {} Name: {}'.format(sample_label, LABEL_NAMES[sample_label]))
plt.axis('off')
plt.imshow(sample_image)
plt.show()
Let’s check the first couple of images of each batch. The lines below can be easily modified to show an arbitrary image from any batch.
%matplotlib inline
%config InlineBackend.figure_format = 'retina'
import numpy as np
for batch_id in range(1,6):
features, labels = load_cfar10_batch(batch_id)
for image_id in range(0,2):
display_stats(features, labels, image_id)
del features, labels # free memory
Stats of batch 1:
Samples: 10000
Label Counts: {0: 1005, 1: 974, 2: 1032, 3: 1016, 4: 999, 5: 937, 6: 1030, 7: 1001, 8: 1025, 9: 981}
First 20 Labels: [6, 9, 9, 4, 1, 1, 2, 7, 8, 3, 4, 7, 7, 2, 9, 9, 9, 3, 2, 6]
Example of Image 0:
Image - Min Value: 0 Max Value: 255
Image - Shape: (32, 32, 3)
Label - Label Id: 6 Name: frog
Stats of batch 1:
Samples: 10000
Label Counts: {0: 1005, 1: 974, 2: 1032, 3: 1016, 4: 999, 5: 937, 6: 1030, 7: 1001, 8: 1025, 9: 981}
First 20 Labels: [6, 9, 9, 4, 1, 1, 2, 7, 8, 3, 4, 7, 7, 2, 9, 9, 9, 3, 2, 6]
Example of Image 1:
Image - Min Value: 5 Max Value: 254
Image - Shape: (32, 32, 3)
Label - Label Id: 9 Name: truck
Stats of batch 2:
Samples: 10000
Label Counts: {0: 984, 1: 1007, 2: 1010, 3: 995, 4: 1010, 5: 988, 6: 1008, 7: 1026, 8: 987, 9: 985}
First 20 Labels: [1, 6, 6, 8, 8, 3, 4, 6, 0, 6, 0, 3, 6, 6, 5, 4, 8, 3, 2, 6]
Example of Image 0:
Image - Min Value: 5 Max Value: 225
Image - Shape: (32, 32, 3)
Label - Label Id: 1 Name: automobile
Stats of batch 2:
Samples: 10000
Label Counts: {0: 984, 1: 1007, 2: 1010, 3: 995, 4: 1010, 5: 988, 6: 1008, 7: 1026, 8: 987, 9: 985}
First 20 Labels: [1, 6, 6, 8, 8, 3, 4, 6, 0, 6, 0, 3, 6, 6, 5, 4, 8, 3, 2, 6]
Example of Image 1:
Image - Min Value: 2 Max Value: 247
Image - Shape: (32, 32, 3)
Label - Label Id: 6 Name: frog
Stats of batch 3:
Samples: 10000
Label Counts: {0: 994, 1: 1042, 2: 965, 3: 997, 4: 990, 5: 1029, 6: 978, 7: 1015, 8: 961, 9: 1029}
First 20 Labels: [8, 5, 0, 6, 9, 2, 8, 3, 6, 2, 7, 4, 6, 9, 0, 0, 7, 3, 7, 2]
Example of Image 0:
Image - Min Value: 0 Max Value: 254
Image - Shape: (32, 32, 3)
Label - Label Id: 8 Name: ship
Stats of batch 3:
Samples: 10000
Label Counts: {0: 994, 1: 1042, 2: 965, 3: 997, 4: 990, 5: 1029, 6: 978, 7: 1015, 8: 961, 9: 1029}
First 20 Labels: [8, 5, 0, 6, 9, 2, 8, 3, 6, 2, 7, 4, 6, 9, 0, 0, 7, 3, 7, 2]
Example of Image 1:
Image - Min Value: 15 Max Value: 249
Image - Shape: (32, 32, 3)
Label - Label Id: 5 Name: dog
Stats of batch 4:
Samples: 10000
Label Counts: {0: 1003, 1: 963, 2: 1041, 3: 976, 4: 1004, 5: 1021, 6: 1004, 7: 981, 8: 1024, 9: 983}
First 20 Labels: [0, 6, 0, 2, 7, 2, 1, 2, 4, 1, 5, 6, 6, 3, 1, 3, 5, 5, 8, 1]
Example of Image 0:
Image - Min Value: 34 Max Value: 203
Image - Shape: (32, 32, 3)
Label - Label Id: 0 Name: airplane
Stats of batch 4:
Samples: 10000
Label Counts: {0: 1003, 1: 963, 2: 1041, 3: 976, 4: 1004, 5: 1021, 6: 1004, 7: 981, 8: 1024, 9: 983}
First 20 Labels: [0, 6, 0, 2, 7, 2, 1, 2, 4, 1, 5, 6, 6, 3, 1, 3, 5, 5, 8, 1]
Example of Image 1:
Image - Min Value: 0 Max Value: 246
Image - Shape: (32, 32, 3)
Label - Label Id: 6 Name: frog
Stats of batch 5:
Samples: 10000
Label Counts: {0: 1014, 1: 1014, 2: 952, 3: 1016, 4: 997, 5: 1025, 6: 980, 7: 977, 8: 1003, 9: 1022}
First 20 Labels: [1, 8, 5, 1, 5, 7, 4, 3, 8, 2, 7, 2, 0, 1, 5, 9, 6, 2, 0, 8]
Example of Image 0:
Image - Min Value: 2 Max Value: 255
Image - Shape: (32, 32, 3)
Label - Label Id: 1 Name: automobile
Stats of batch 5:
Samples: 10000
Label Counts: {0: 1014, 1: 1014, 2: 952, 3: 1016, 4: 997, 5: 1025, 6: 980, 7: 977, 8: 1003, 9: 1022}
First 20 Labels: [1, 8, 5, 1, 5, 7, 4, 3, 8, 2, 7, 2, 0, 1, 5, 9, 6, 2, 0, 8]
Example of Image 1:
Image - Min Value: 1 Max Value: 244
Image - Shape: (32, 32, 3)
Label - Label Id: 8 Name: ship
Preprocess data
Normalization function
In the cell below, the normalize
function takes in image data, x
, and return it as a normalized Numpy array. The values are in the range of 0 to 1, inclusive. The returned object has the same shape as x
.
def normalize(x):
# Each pixel has three channels - Red, Green and Blue.
# Each channel is an int between 0 and 255 (8-bit color scheme).
return np.array(x) / 255.0
One-hot-encoding
Not only the input data, but also the labels have to be preprocessed. When dealing with categorical data one has to one-hot-encode the labels. Normally, I would use the OneHotEncoder from the sklearn.preprocessing library. For the sake of example, I implemented it by myself.
def one_hot_encode(x):
one_hot_encoded = np.zeros((len(x), 10))
for i in range(len(x)):
one_hot_encoded[i][x[i]] = 1.0
return one_hot_encoded
Preprocess all the data and save it
Running the code cell below will preprocess all the CIFAR-10 data and save it to file. The code below also uses 10% of the training data for validation. Remember, we do not want to load all the data in the memory simultaneously.
"""
Preprocess Training and Validation and Test Data
"""
def preprocess_and_save(features, labels, filename):
"""
Preprocess data and save it to file
Both functions have been defined above
"""
features = normalize(features)
labels = one_hot_encode(labels)
pickle.dump((features, labels), open(filename, 'wb'))
def preprocess_and_save_all_data():
"""
Preprocess Training and Validation Data
"""
n_batches = 5
valid_features = []
valid_labels = []
for batch_i in range(1, n_batches + 1):
features, labels = load_cfar10_batch(batch_i)
validation_count = int(len(features) * 0.1)
# Process and save a batch of training data
preprocess_and_save(
features[:-validation_count],
labels[:-validation_count],
'preprocess_batch_' + str(batch_i) + '.p')
# Use a portion of training batch for validation
valid_features.extend(features[-validation_count:])
valid_labels.extend(labels[-validation_count:])
# Preprocess and Save all validation data
preprocess_and_save(
np.array(valid_features),
np.array(valid_labels),
'preprocess_validation.p')
with open(cifar10_dataset_folder_path + '/test_batch', mode='rb') as file:
batch = pickle.load(file, encoding='latin1')
# load the training data
test_features = batch['data'].reshape((len(batch['data']), 3, 32, 32)).transpose(0, 2, 3, 1)
test_labels = batch['labels']
# Preprocess and Save all training data
preprocess_and_save(
np.array(test_features),
np.array(test_labels),
'preprocess_training.p')
# Run preprocessing and saving on disk
preprocess_and_save_all_data()
Building the neural network
For the neural network, I will build each type of layer into a function. Encapsulating tensorflow logic in such functions allows you to easily modify the architecture without having to rewrite the boilerplate tensorflow code. Furthermore, the functions built can be later reused for other datasets containing images with different size and different labels.
Input
The neural network needs to read the image data, one-hot encoded labels, and dropout keep probability.
import tensorflow as tf
def neural_net_image_input(image_shape):
return tf.placeholder(tf.float32, shape=(None, image_shape[0], image_shape[1], image_shape[2]), name='x')
def neural_net_label_input(n_classes):
return tf.placeholder(tf.float32, shape=(None, n_classes), name='y')
def neural_net_keep_prob_input():
return tf.placeholder(tf.float32, name='keep_prob')
Convolution and Max Pooling Layer
Convolution layers have a lot of success with images. The following block of code implements the function conv2d_maxpool
to apply convolution and then max pooling. Applying convolutions and then max pooling has become a “de facto” standard for constructing neural networks for image recognition. It is generally a nice idea to log the layer’s input and output dimensions - the two print functions at the end will be useful when fine tuning the network architecture.
def conv2d_maxpool(x_tensor, conv_num_outputs, conv_ksize, conv_strides, pool_ksize, pool_strides):
# Create filter dimensions
filter_height, filter_width, in_channels, out_channels = \
conv_ksize[0], conv_ksize[1], x_tensor.get_shape().as_list()[3], conv_num_outputs
conv_filter = [filter_height, filter_width, in_channels, out_channels]
# Create weights and bias
weights = tf.Variable(tf.truncated_normal(conv_filter, stddev=0.05))
bias = tf.Variable(tf.truncated_normal([conv_num_outputs], stddev=0.05))
# Create strides
strides=(1,conv_strides[0], conv_strides[1], 1)
# Bind all together to create the layer
conv = tf.nn.conv2d(x_tensor, weights, strides, padding='SAME')
conv = tf.nn.bias_add(conv, bias)
# Create ksize
ksize = (1, pool_ksize[0], pool_ksize[1], 1)
# Create strides
strides=(1,pool_strides[0], pool_strides[1], 1)
pool = tf.nn.max_pool(conv, ksize, strides, padding='SAME')
print('Convolutional layer with conv_num_outputs:',conv_num_outputs,
'conv_ksize:', conv_ksize,
'conv_strides:', conv_strides,
'pool_ksize:',pool_ksize,
'pool_strides', pool_strides)
print('layer input shape', x_tensor.get_shape().as_list(),
'layer output shape', pool.get_shape().as_list())
return pool
Flatten Layer and Fully Connected Layers
After stacking up the convolution layers one usually flattens the network and applies at least one, but usually several fully connected layers. Dropout is also applied at this point. As a matter of fact, dropout is one of the great discoveries in the last years. It is used to prevent the network from overfitting.
def flatten(x_tensor):
_, height, width, channels = x_tensor.get_shape().as_list()
net = tf.reshape(x_tensor, shape=[-1, height * width * channels])
print('flatten shape', net.get_shape().as_list())
return net
def fully_conn(x_tensor, num_outputs):
_, size = x_tensor.get_shape().as_list()
weights = tf.Variable(tf.truncated_normal([size, num_outputs], stddev=0.05))
bias = tf.Variable(tf.truncated_normal([num_outputs], stddev=0.05))
fully_connected = tf.add(tf.matmul(x_tensor, weights), bias)
print('layer input shape', x_tensor.get_shape().as_list(),
'layer output shape', fully_connected.get_shape().as_list())
return fully_connected
The Neural Network architecture
In the function conv_net
we create the actual convolutional neural network model. The function takes in a batch of images, x
, and outputs logits. The layers introduced above are bound together. This is where one actually defines the architecture of the neural network. As a matter of fact, I changed the architecture more than a dozen of times, until I reached a reasonable accuracy. Indeed, it is very hard to choose a proper architecture and blind trial and error is not the way to go here. There are multiple methodologies for fine tuning a neural network described in various papers by the scientific community. For the sake of simplicity I will not dive into the details here, but would definitely recommend this reading: 1st place on the Galaxy Zoo Challenge
def conv_net(input_x, keep_probability):
net = conv2d_maxpool(input_x, 32, (7,7), (2,2), (2,2), (2,2))
net = conv2d_maxpool(net, 64, (3,3), (1,1), (2,2), (2,2))
net = conv2d_maxpool(net, 128, (2,2), (1,1), (2,2), (2,2))
net = flatten(net)
net = tf.nn.dropout(net, keep_probability)
net = fully_conn(net, 1024)
net = tf.nn.dropout(net, keep_probability)
net = fully_conn(net, 128)
net = fully_conn(net, 10)
return net
Building the Neural Network
In the code block below we use tensorflow to train the neural network. I found the AdamOptimizer to be the least sensitive to the learning rate. The learning rate is another parameter one has to tune. For an overview of different optimizers check An overview of gradient descent optimization algorithms.
##############################
## Build the Neural Network ##
##############################
# Remove previous weights, bias, inputs, etc..
tf.reset_default_graph()
IMAGE_SHAPE = (32, 32, 3)
LABELS_COUNT = 10
# Inputs
x = neural_net_image_input(IMAGE_SHAPE)
y = neural_net_label_input(LABELS_COUNT)
keep_prob = neural_net_keep_prob_input()
# Model
logits = conv_net(x, keep_prob)
# Name logits Tensor, so that is can be loaded from disk after training
logits = tf.identity(logits, name='logits')
# Loss and Optimizer
cost = tf.reduce_mean(tf.nn.softmax_cross_entropy_with_logits(logits=logits, labels=y))
optimizer = tf.train.AdamOptimizer(learning_rate=0.001).minimize(cost)
# Accuracy
correct_pred = tf.equal(tf.argmax(logits, 1), tf.argmax(y, 1))
accuracy = tf.reduce_mean(tf.cast(correct_pred, tf.float32), name='accuracy')
Convolutional layer with conv_num_outputs: 32 conv_ksize: (7, 7) conv_strides: (2, 2) pool_ksize: (2, 2) pool_strides (2, 2)
layer input shape [None, 32, 32, 3] layer output shape [None, 8, 8, 32]
Convolutional layer with conv_num_outputs: 64 conv_ksize: (3, 3) conv_strides: (1, 1) pool_ksize: (2, 2) pool_strides (2, 2)
layer input shape [None, 8, 8, 32] layer output shape [None, 4, 4, 64]
Convolutional layer with conv_num_outputs: 128 conv_ksize: (2, 2) conv_strides: (1, 1) pool_ksize: (2, 2) pool_strides (2, 2)
layer input shape [None, 4, 4, 64] layer output shape [None, 2, 2, 128]
flatten shape [None, 512]
layer input shape [None, 512] layer output shape [None, 1024]
layer input shape [None, 1024] layer output shape [None, 128]
layer input shape [None, 128] layer output shape [None, 10]
Show Stats
We also need to implement a function to print loss and validation accuracy. Additionally, we define the global variables valid_features
and valid_labels
to calculate validation accuracy. Remember to always use a keep probability of 1.0
to calculate the loss and validation accuracy.
valid_features, valid_labels = pickle.load(open('preprocess_validation.p', mode='rb'))
def print_stats(session, feature_batch, label_batch, cost, accuracy):
batch_loss = session.run(cost, feed_dict=\
{x:feature_batch, y:label_batch, keep_prob:1.0})
batch_accuracy = session.run(accuracy, feed_dict=\
{x:valid_features, y:valid_labels, keep_prob:1.0})
print('batch loss is : ', batch_loss)
print('batch_accuracy accuracy is :',batch_accuracy)
Hyperparameters
A few more parameters need to be tuned:
* We set epochs
to the number of iterations until the network stops learning or starts overfitting
* We Set batch_size
to the highest number that your machine has memory for. Most people set them to common sizes of memory like 64, 128, etc. The bigger the batch size, the fewer epochs are needed for the network to be trained.
- We set
keep_probability
to the probability of keeping a node using dropout. Hence, keep_probability prevents overfitting of the neural network. Usually, values between 0.4 and 0.8 produce good results.
# For my laptop I selected:
epochs = 50
batch_size = 256
# keep probability of 70%
keep_probability = 0.5
# a couple of helper functions for loading a single batch
def batch_features_labels(features, labels, batch_size):
"""
Split features and labels into batches
"""
for start in range(0, len(features), batch_size):
end = min(start + batch_size, len(features))
yield features[start:end], labels[start:end]
def load_preprocess_training_batch(batch_id, batch_size):
"""
Load the Preprocessed Training data and return them in batches of <batch_size> or less
"""
filename = 'preprocess_batch_' + str(batch_id) + '.p'
features, labels = pickle.load(open(filename, mode='rb'))
# Return the training data in batches of size <batch_size> or less
return batch_features_labels(features, labels, batch_size)
Train on a Single CIFAR-10 Batch
Instead of training the neural network on all the CIFAR-10 batches of data, let’s use a single batch. This saved me a lot of time while iterating the parameters of the model to get a better accuracy. Once I found the final validation accuracy to be satisfying I ran the model on all the data.
print('Checking the Training on a Single Batch...')
with tf.Session() as session:
# Initializing the variables
session.run(tf.global_variables_initializer())
# Training cycle
for epoch in range(epochs):
batch_i = 1
for batch_features, batch_labels in \
load_preprocess_training_batch(batch_i, batch_size):
session.run(optimizer, feed_dict=\
{x:batch_features, y:batch_labels, keep_prob:keep_probability})
print('Epoch {:>2}, CIFAR-10 Batch {}: '.format(epoch + 1, batch_i), end='')
print_stats(session, batch_features, batch_labels, cost, accuracy)
Checking the Training on a Single Batch...
Epoch 1, CIFAR-10 Batch 1: batch loss is : 2.04934
batch_accuracy accuracy is : 0.3524
Epoch 2, CIFAR-10 Batch 1: batch loss is : 1.80641
batch_accuracy accuracy is : 0.4126
Epoch 3, CIFAR-10 Batch 1: batch loss is : 1.54692
batch_accuracy accuracy is : 0.4486
Epoch 4, CIFAR-10 Batch 1: batch loss is : 1.27744
batch_accuracy accuracy is : 0.4792
Epoch 5, CIFAR-10 Batch 1: batch loss is : 1.13442
batch_accuracy accuracy is : 0.4928
Epoch 6, CIFAR-10 Batch 1: batch loss is : 0.92034
batch_accuracy accuracy is : 0.496
Epoch 7, CIFAR-10 Batch 1: batch loss is : 0.806121
batch_accuracy accuracy is : 0.4896
Epoch 8, CIFAR-10 Batch 1: batch loss is : 0.745746
batch_accuracy accuracy is : 0.5048
Epoch 9, CIFAR-10 Batch 1: batch loss is : 0.615836
batch_accuracy accuracy is : 0.531
Epoch 10, CIFAR-10 Batch 1: batch loss is : 0.497367
batch_accuracy accuracy is : 0.5288
Epoch 11, CIFAR-10 Batch 1: batch loss is : 0.442382
batch_accuracy accuracy is : 0.531
Epoch 12, CIFAR-10 Batch 1: batch loss is : 0.381339
batch_accuracy accuracy is : 0.55
Epoch 13, CIFAR-10 Batch 1: batch loss is : 0.365281
batch_accuracy accuracy is : 0.5634
Epoch 14, CIFAR-10 Batch 1: batch loss is : 0.307827
batch_accuracy accuracy is : 0.5432
Epoch 15, CIFAR-10 Batch 1: batch loss is : 0.26708
batch_accuracy accuracy is : 0.571
Epoch 16, CIFAR-10 Batch 1: batch loss is : 0.222317
batch_accuracy accuracy is : 0.577
Epoch 17, CIFAR-10 Batch 1: batch loss is : 0.191946
batch_accuracy accuracy is : 0.5728
Epoch 18, CIFAR-10 Batch 1: batch loss is : 0.142695
batch_accuracy accuracy is : 0.5794
Epoch 19, CIFAR-10 Batch 1: batch loss is : 0.176674
batch_accuracy accuracy is : 0.5508
Epoch 20, CIFAR-10 Batch 1: batch loss is : 0.163542
batch_accuracy accuracy is : 0.579
Epoch 21, CIFAR-10 Batch 1: batch loss is : 0.171183
batch_accuracy accuracy is : 0.5622
Epoch 22, CIFAR-10 Batch 1: batch loss is : 0.132356
batch_accuracy accuracy is : 0.5728
Epoch 23, CIFAR-10 Batch 1: batch loss is : 0.10712
batch_accuracy accuracy is : 0.5704
Epoch 24, CIFAR-10 Batch 1: batch loss is : 0.101802
batch_accuracy accuracy is : 0.5618
Epoch 25, CIFAR-10 Batch 1: batch loss is : 0.108635
batch_accuracy accuracy is : 0.5678
Epoch 26, CIFAR-10 Batch 1: batch loss is : 0.112882
batch_accuracy accuracy is : 0.5596
Epoch 27, CIFAR-10 Batch 1: batch loss is : 0.0682271
batch_accuracy accuracy is : 0.5884
Epoch 28, CIFAR-10 Batch 1: batch loss is : 0.0640762
batch_accuracy accuracy is : 0.5856
Epoch 29, CIFAR-10 Batch 1: batch loss is : 0.0570013
batch_accuracy accuracy is : 0.5866
Epoch 30, CIFAR-10 Batch 1: batch loss is : 0.0763902
batch_accuracy accuracy is : 0.583
Epoch 31, CIFAR-10 Batch 1: batch loss is : 0.0564564
batch_accuracy accuracy is : 0.571
Epoch 32, CIFAR-10 Batch 1: batch loss is : 0.0532774
batch_accuracy accuracy is : 0.588
Epoch 33, CIFAR-10 Batch 1: batch loss is : 0.0437081
batch_accuracy accuracy is : 0.5838
Epoch 34, CIFAR-10 Batch 1: batch loss is : 0.0328673
batch_accuracy accuracy is : 0.5664
Epoch 35, CIFAR-10 Batch 1: batch loss is : 0.0359792
batch_accuracy accuracy is : 0.5884
Epoch 36, CIFAR-10 Batch 1: batch loss is : 0.0376761
batch_accuracy accuracy is : 0.5898
Epoch 37, CIFAR-10 Batch 1: batch loss is : 0.0326239
batch_accuracy accuracy is : 0.5694
Epoch 38, CIFAR-10 Batch 1: batch loss is : 0.0366496
batch_accuracy accuracy is : 0.589
Epoch 39, CIFAR-10 Batch 1: batch loss is : 0.0224001
batch_accuracy accuracy is : 0.582
Epoch 40, CIFAR-10 Batch 1: batch loss is : 0.0224597
batch_accuracy accuracy is : 0.5896
Epoch 41, CIFAR-10 Batch 1: batch loss is : 0.0199231
batch_accuracy accuracy is : 0.5834
Epoch 42, CIFAR-10 Batch 1: batch loss is : 0.0231632
batch_accuracy accuracy is : 0.5878
Epoch 43, CIFAR-10 Batch 1: batch loss is : 0.0191447
batch_accuracy accuracy is : 0.5932
Epoch 44, CIFAR-10 Batch 1: batch loss is : 0.0206479
batch_accuracy accuracy is : 0.5776
Epoch 45, CIFAR-10 Batch 1: batch loss is : 0.0263408
batch_accuracy accuracy is : 0.5718
Epoch 46, CIFAR-10 Batch 1: batch loss is : 0.0125673
batch_accuracy accuracy is : 0.5802
Epoch 47, CIFAR-10 Batch 1: batch loss is : 0.0197601
batch_accuracy accuracy is : 0.5828
Epoch 48, CIFAR-10 Batch 1: batch loss is : 0.0156334
batch_accuracy accuracy is : 0.5908
Epoch 49, CIFAR-10 Batch 1: batch loss is : 0.011323
batch_accuracy accuracy is : 0.5846
Epoch 50, CIFAR-10 Batch 1: batch loss is : 0.0132246
batch_accuracy accuracy is : 0.5784
Fully Train the Model
Now that we got a good accuracy with a single CIFAR-10 batch, we train the model again by using all five batches. This takes quite a lot of time. At the end, the model is saved on the hard disk in order to be reused in the future.
save_model_path = './image_classification'
print('Training...')
with tf.Session() as session:
# Initializing the variables
session.run(tf.global_variables_initializer())
# Training cycle
for epoch in range(epochs):
# Loop over all batches
n_batches = 5
for batch_i in range(1, n_batches + 1):
for batch_features, batch_labels in \
load_preprocess_training_batch(batch_i, batch_size):
session.run(optimizer, feed_dict=\
{x:batch_features, y:batch_labels, keep_prob:keep_probability})
# Save Model
saver = tf.train.Saver()
save_path = saver.save(session, save_model_path)
Training...
Test Model
Let’s load the model from the disk and use it to test against the test dataset. This will produce our final accuracy estimation.
%matplotlib inline
%config InlineBackend.figure_format = 'retina'
import tensorflow as tf
import pickle
import random
import numpy as np
import matplotlib.pyplot as plt
from sklearn.preprocessing import LabelBinarizer
def display_image_predictions(features, labels, predictions):
label_binarizer = LabelBinarizer()
label_binarizer.fit(range(LABELS_COUNT))
label_ids = label_binarizer.inverse_transform(np.array(labels))
fig, axies = plt.subplots(nrows=4, ncols=2)
fig.tight_layout()
fig.suptitle('Softmax Predictions', fontsize=20, y=1.1)
n_predictions = 3
margin = 0.05
ind = np.arange(n_predictions)
width = (1. - 2. * margin) / n_predictions
for image_i, (feature, label_id, pred_indicies, pred_values) \
in enumerate(zip(features, label_ids, predictions.indices, predictions.values)):
pred_names = [LABEL_NAMES[pred_i] for pred_i in pred_indicies]
correct_name = LABEL_NAMES[label_id]
axies[image_i][0].imshow(feature)
axies[image_i][0].set_title(correct_name)
axies[image_i][0].set_axis_off()
axies[image_i][1].barh(ind + margin, pred_values[::-1], width)
axies[image_i][1].set_yticks(ind + margin)
axies[image_i][1].set_yticklabels(pred_names[::-1])
axies[image_i][1].set_xticks([0, 0.5, 1.0])
save_model_path = './image_classification'
n_samples = 4
top_n_predictions = 3
def test_model():
"""
Test the saved model against the test dataset
"""
test_features, test_labels = pickle.load(open('preprocess_training.p', mode='rb'))
loaded_graph = tf.Graph()
with tf.Session(graph=loaded_graph) as sess:
# Load model
loader = tf.train.import_meta_graph(save_model_path + '.meta')
loader.restore(sess, save_model_path)
# Get Tensors from loaded model
loaded_x = loaded_graph.get_tensor_by_name('x:0')
loaded_y = loaded_graph.get_tensor_by_name('y:0')
loaded_keep_prob = loaded_graph.get_tensor_by_name('keep_prob:0')
loaded_logits = loaded_graph.get_tensor_by_name('logits:0')
loaded_acc = loaded_graph.get_tensor_by_name('accuracy:0')
# Get accuracy in batches for memory limitations
test_batch_acc_total = 0
test_batch_count = 0
for train_feature_batch, train_label_batch in \
batch_features_labels(test_features, test_labels, batch_size):
test_batch_acc_total += sess.run(
loaded_acc,
feed_dict={loaded_x: train_feature_batch, \
loaded_y: train_label_batch, loaded_keep_prob: 1.0})
test_batch_count += 1
print('Testing Accuracy: {}\n'.format(test_batch_acc_total/test_batch_count))
# Print Random Samples
random_test_features, random_test_labels = \
tuple(zip(*random.sample(list(zip(test_features, test_labels)), n_samples)))
random_test_predictions = sess.run(
tf.nn.top_k(tf.nn.softmax(loaded_logits), top_n_predictions),
feed_dict={loaded_x: random_test_features, \
loaded_y: random_test_labels, loaded_keep_prob: 1.0})
display_image_predictions(random_test_features, \
random_test_labels, random_test_predictions)
test_model()
Testing Accuracy: 0.6734375
Outlook
This post gives a general idea how one could build and train a convolutional neural network. Nonetheless, more than a few details were not discussed. So, dear reader, as always feel free to contact me and let me know if you have any questions. The whole Python Notebook can be found here: cnn-image-classification-cifar-10-from-scratch.ipynb.


Syntax Highlighting and Error Highlighting
The class used to specify how a particular range of text should be highlighted is called TextAttributesKey. An instance of this class is created for every distinct type of item which should be highlighted (keyword, number, string and so on). The TextAttributesKey defines the default attributes which are applied to items of the corresponding type (for example, keywords are bold, numbers are blue, strings are bold and green). The mapping of the TextAttributesKey to specific attributes used in an editor is defined by the EditorColorsScheme class, and can be configured by the user if the plugin provides an appropriate configuration interface. Highlighting from multiple TextAttributesKey items can be layered - for example, one key may define an item’s boldness and another its color.
Note: New functionality about Language Defaults and support for additional color schemes as detailed in Color Scheme Management.
Lexer
The syntax and error highlighting is performed on multiple levels. The first level of syntax highlighting is based on the lexer output, and is provided through the SyntaxHighlighter interface. The syntax highlighter returns the TextAttributesKey instances for each token type which needs special highlighting. For highlighting lexer errors, the standard TextAttributesKey for bad characters HighlighterColors.BAD_CHARACTER can be used.
Example: SyntaxHighlighter implementation for Properties language plugin
Parser
The second level of error highlighting happens during parsing. If a particular sequence of tokens is invalid according to the grammar of the language, the PsiBuilder.error() method can be used to highlight the invalid tokens and display an error message showing why they are not valid.
Annotator
The third level of highlighting is performed through the
Annotator
interface.
A plugin can register one or more annotators in the com.intellij.annotator
extension point, and these annotators are called during the background highlighting pass to process the elements in the PSI tree of the custom language.
Annotators can analyze not only the syntax, but also the semantics using PSI, and thus can provide much more complex syntax and error highlighting logic.
The annotator can also provide quick fixes to problems it detects.
When the file is changed, the annotator is called incrementally to process only changed elements in the PSI tree.
To highlight a region of text as a warning or error, the annotator calls createErrorAnnotation()
or createWarningAnnotation()
on the
AnnotationHolder
object passed to it, and optionally calls registerFix()
on the returned
Annotation
object to add a quick fix for the error or warning.
To apply additional syntax highlighting, the annotator can call
AnnotationHolder.createInfoAnnotation()
with an empty message and then call
Annotation.setTextAttributes()
to specify the text attributes key for the highlighting.
Example: Annotator for Properties language plugin
External tool
Finally, if the custom language employs external tools for validating files in the language (for example, uses the Xerces library for XML schema validation), it can provide an implementation of the
ExternalAnnotator
interface and register it in com.intellij.externalAnnotator
extension point.
The
ExternalAnnotator
highlighting has the lowest priority and is invoked only after all other background processing has completed.
It uses the same
AnnotationHolder
interface for converting the output of the external tool into editor highlighting.
Color settings
The plugin can also provide a configuration interface to allow the user to configure the colors used for highlighting specific items.
In order to do that, it should provide an implementation of
ColorSettingPage
and register it in the com.intellij.colorSettingsPage
extension point.
Example: ColorSettingsPage for Properties language plugin
The Export to HTML
feature uses the same syntax highlighting mechanism as the editor, so it will work automatically for custom languages which provide a syntax highlighter.


Tooltips are small, interactive, textual hints for mainly graphical elements. When using icons for actions you can use a tooltip to give people clarification on its function.
Add the Tooltipped class to your element and add either top, bottom, left, right on data-tooltip to control the position.

Hover me!
Initialization
document.addEventListener('DOMContentLoaded', function() {
var elems = document.querySelectorAll('.tooltipped');
var instances = M.Tooltip.init(elems, {
// specify options here
});
});
// Or with jQuery
$(document).ready(function(){
$('.tooltipped').tooltip({
// specify options here
});
});
Options
| Name | Type | Default | Description |
|---|---|---|---|
| exitDelay | Number | 200 | Delay time before tooltip disappears. |
| enterDelay | Number | 0 | Delay time before tooltip appears. |
| text | String | Text string for the tooltip. | |
| unsafeHTML | String | null | HTML content that will be appended to to text .
Only use properly sanitized or otherwise trusted data for unsafeHTML . |
| html | String | null |
(DEPRECATED): will be removed in a later release.
HTML content that will be appended to
Will be ignored if |
| margin | Number | 5 | Set distance tooltip appears away from its activator excluding transitionMovement. |
| inDuration | Number | 300 | Enter transition duration. |
| opacity | Number | 1 | Opacity of the tooltip. |
| outDuration | Number | 250 | Exit transition duration. |
| position | String | 'bottom' | Set the direction of the tooltip. 'top', 'right', 'bottom', 'left'. |
| transitionMovement | Number | 10 | Amount in px that the tooltip moves during its transition. |
Methods
Because jQuery is no longer a dependency, all the methods are called on the plugin instance. You can get the plugin instance like this:
var instance = M.Tooltip.getInstance(elem); /* jQuery Method Calls You can still use the old jQuery plugin method calls. But you won't be able to access instance properties. $('.tooltip').tooltip('methodName'); $('.tooltip').tooltip('methodName', paramName); */
.open();
Show tooltip.
instance.open();
.close();
Hide tooltip.
instance.close();
.destroy();
Destroy plugin instance and teardown
instance.destroy();
Properties
| Name | Type | Description |
|---|---|---|
| el | Element | The DOM element the plugin was initialized with. |
| options | Object | The options the instance was initialized with. |
| isOpen | Boolean | If tooltip is open. |
| isHovered | Boolean | If tooltip is hovered. |


Congratulations, you're hydrated.
Sorry, drink more water.
I want to drink
glasses of water over the next
hours.
Start!


Black Friday holiday warning as 'deals' last year found to cost people more
Black Friday isn't just about cheap tellies, with more and more travel companies now getting in on the action - but how far can you really trust the discounts on offer?
by James Andrews, http://www.facebook.com/jameswritesmoney/Brits are being warned to tread carefully on Black Friday after travel firms were found to be selling last year's deals for more than they would have cosy later on.
Consumer group Which? - who conducted the research - said some of the deals advertised as part of the annual sales bonanza "aren't always what they appear to be".
Which? Travel editor Rory Boland said: "Nothing beats the feeling of saving hundreds on your next holiday, but that feeling can quickly turn to anger when you discover it would have been cheaper if you'd waited to book.
"Our research reveals that Black Friday travel deals aren't always what they appear to be. Avoid disappointment by comparing prices and approach attention-grabbing saving claims with scepticism."
Which? looked into promotions by major airlines and travel firms on Black Friday in 2018 - which fell on November 23 - and checked what prices were two weeks later.
Ryanair advertised a 25% discount on one million seats purchased by midnight, but none of the flights Which? included in its study were more expensive if booked on December 7.
EasyJet's Black Friday sale claimed travellers could save £50 on 60,000 city breaks, although eight of 21 trips analysed were cheaper after a fortnight.
The research found a three-night break from London Luton to Barcelona cost 13% less if holidaymakers waited to book until two weeks after Black Friday.
Airline Norwegian advertised discounts of "up to 30% off short-haul fares and 15% off long-haul fares", but the biggest saving found by Which? was just 10%.
In response, Norwegian said the figures used in its promotion were based on fares excluding taxes and charges, but Which? claimed this was not clear when viewing the carrier's website.
Travel firm Tui offered discount codes worth £100 or £150 off selected bookings, but they did not work on two of the five holidays Which? analysed.
This year's Black Friday falls on November 29.


• SellMe is an online marketplace built to empower the buyer. Buyers post items they're interested in purchasing and sellers can submit competing bids to the buyer. This was our final project for Dev Bootcamp and was limited to 6 days of development. Our team decided to use AngularJs, a framework which we had a limited familiarity. We decoupled our AngularJs front-end from the Rails API back-end.
• Developed the Search bar, Countdown ticker, Forms, AWS S3 picture upload and API calls with AngularJs and JavaScript on the front-end. Setup AWS IAM/S3/Cognito policies.


A New York court unseals a lawsuit filed on behalf of the state of New York against Bayrock, Felix Sater and others. It alleges that the group sought to evade taxation and hide its true foreign ownership by laundering as much as $250 million in profits on Trump projects.
The attorneys behind the suit tell Forbes that new information leads them to believe that Trump participated in the schemes and lied about his involvement.
Source: Forbes


Good Newwz: Kareena Kapoor Khan REVEALS She Was On-Board Even Before Akshay Kumar; See Video
At the trailer launch today, Bebo was asked what made her say yes to the film.
by Pooja DaradeToday, the trailer of Good Newwz starring Kareena Kapoor Khan, Akshay Kumar, Kiara Advani and Diljit Dosanjh was dropped. The trailer is a laughter riot with a hilarious goof-up.
Good Newwz is directed by Raj Mehta and produced by Karan Johar’s Dharma Productions. At the trailer launch today, Bebo was asked what made her say yes to the film. The actress shared, “When Raj narrated the film, I personally thought that I was perfect for the part. That’s why I really wanted to do the film. It was funny, I couldn’t stop laughing. I said, why not? Of course, it is the production house that I trust beyond.”
“The whole package is great. Actually Akshay was not on board at that time. I was the first came on board. I didn’t know who the rest of the cast was. I wanted to trust Raj and do it. I think, it’s quite funny,” added Kareena Kapoor Khan.
Watch the video below:
Good Newwz will hit the screens on December 27, 2019.
Did you like the trailer? Let us know what you think of it in the comments below.


Map with Modified Control Location
Show a map with a couple of modified control locations
Active Controls
- OpenLayers.Control.Navigation
- OpenLayers.Control.PanZoomBar (Moved)
- OpenLayers.Control.LayerSwitcher
- OpenLayers.Control.Permalink
- OpenLayers.Control.MousePosition
- OpenLayers.Control.OverviewMap
- OpenLayers.Control.Scale
- OpenLayers.Control.ScaleLine (Moved)


Building Addons
Methods for Extending Dexie
The Dexie.addons array contains functions that extend Dexie. An addon may register itself in Dexie.addons by using Dexie.addons.push(fn)
.
Example:
import Dexie from 'dexie';
export function ForEachAddon (db) {
// Makes it possible to use forEach() instead of each() on collections.
db.Collection.prototype.forEach = db.Collection.prototype.each;
}
// Register the addon to be included by default (optional)
Dexie.addons.push(ForEachAddon);
ES5:
function ForEachAddon (db) {
// Makes it possible to use forEach() instead of each() on collections.
db.Collection.prototype.forEach = db.Collection.prototype.each;
}
// Register the addon to be included by default (optional)
Dexie.addons.push(ForEachAddon);
Understanding where Dexie classes reside
Dexie classes such as Collection and Table are created in the closure scope of the Dexie constructor. To extend the prototypes you must work with an instance of Dexie. See example above.
Overriding existing methods
To override an existing method on any class, you can just change its current value to your own function. A handy function for overriding is the Dexie.override() function. Example:
db.Collection.prototype.each = Dexie.override (db.Collection.prototype.each, function (originalEach) {
return function () {
var returnValue = originalEach.apply(this, arguments);
// Do some more stuff
return returnValue;
}
});
Protected methods
The API Reference does not document the protected methods and properties of Dexie. You may however look into the code and find lots of methods and properties with a leading underscore. Your addon may then override protected methods to change the behaviour of the database engine. To see an example of this, look at how Dexie.Observable.js is implemented.
Note: We will try to keep all the not-yet-documented underscore properties and methods backward compatible as much as possible, but it’s not a guarantee. To be certain we inform you about important API changes, please let us know about your addon and where to find its source. To be even more certain, let your addon reside under your fork of Dexie.js/addons and keep us updated with pull requests.
When to use prototype and when not
All inner classes (Collection, WhereClause, Table, Transaction, etc.) use prototype for all their methods. This is because it will optimize instance creations. But the main Dexie class itself does not use prototype for now since instance creation is more rare with the main class which is typically singleton.
So to extend or override methods on the main class (Dexie), you should change the property on the given db instance that your addon retrieves as its first argument. For all other internal classes, such as Collection, WhereClause, Table, etc, all methods are prototyped, so you can override the prototype of those.
Creating Subclasses
Another way to extend Dexie is to derive from it or make your extension create new classes that derives from existing ones. For example, you could derive from Table and then override the protected method db._tableFactory() method and create your instance there.
Alternate way of doing an addon
Instead of registering into Dexie.addons, you could instead create a derived class and call it something else. Example:
import Dexie from 'dexie';
class MyDerivedDexie extends Dexie {
anotherProperty;
anotherMethod() {
// Do something here...
}
constructor (name, options) {
super(name, options);
this.anotherProperty = "other prop";
}
}
ES5:
function MyDerivedDexie (dbname, options) {
Dexie.call(this, dbname, options);
this.anotherProperty = "other prop";
this.anotherMethod = function () {
// Do something here...
};
}
To use the addon:
var db = new MyDerivedDexie("DerivedSampleDB");
alert (db.anotherProperty);
db.anotherMethod ();
Creating an AMD based addon
If you write a pure AMD based addon, you should (by convention) not register it to Dexie.addons but let the module user explicitely provide your addon as an option to the Dexie constructor.
define('Dexie.NequalAddon', ["Dexie"], function (Dexie) {
function NequalAddon (db) {
db.WhereClause.prototype.notEqualTo = function (value) {
return this.below(value).or(this._ctx.index).above(value);
};
}
return NequalAddon;
});
To use your addon:
require(['Dexie', 'Dexie.NequalAddon'], function (Dexie, DexieNequalAddon) {
var db = new Dexie('testdb', {addons: [DexieNequalAddon]});
db.version(1).stores({...});
db.open();
...
});
Table of Contents
- API Reference
- Best Practices
- Building Addons
- Collection
- Collection.and()
- Collection.clone()
- Collection.count()
- Collection.delete()
- Collection.desc()
- Collection.distinct()
- Collection.each()
- Collection.eachKey()
- Collection.eachPrimaryKey()
- Collection.eachUniqueKey()
- Collection.filter()
- Collection.first()
- Collection.keys()
- Collection.last()
- Collection.limit()
- Collection.modify()
- Collection.offset()
- Collection.or()
- Collection.primaryKeys()
- Collection.raw()
- Collection.reverse()
- Collection.sortBy()
- Collection.toArray()
- Collection.uniqueKeys()
- Collection.until()
- Compound Index
- Consuming Dexie as a module
- Deprecations
- Derived Work
- Design
- Dexie
- Dexie.AbortError
- Dexie.BulkError
- Dexie.ConstraintError
- Dexie.DataCloneError
- Dexie.DataError
- Dexie.DatabaseClosedError
- Dexie.IncompatiblePromiseError
- Dexie.InternalError
- Dexie.InvalidAccessError
- Dexie.InvalidArgumentError
- Dexie.InvalidStateError
- Dexie.InvalidTableError
- Dexie.MissingAPIError
- Dexie.ModifyError
- Dexie.NoSuchDatabaseErrorError
- Dexie.NotFoundError
- Dexie.Observable
- Dexie.Observable.DatabaseChange
- Dexie.OpenFailedError
- Dexie.PrematureCommitError
- Dexie.QuotaExceededError
- Dexie.ReadOnlyError
- Dexie.SchemaError
- Dexie.SubTransactionError
- Dexie.Syncable
- Dexie.Syncable.IDatabaseChange
- Dexie.Syncable.IPersistentContext
- Dexie.Syncable.ISyncProtocol
- Dexie.Syncable.StatusTexts
- Dexie.Syncable.Statuses
- Dexie.Syncable.registerSyncProtocol()
- Dexie.TimeoutError
- Dexie.TransactionInactiveError
- Dexie.UnknownError
- Dexie.UnsupportedError
- Dexie.UpgradeError()
- Dexie.VersionChangeError
- Dexie.VersionError
- Dexie.[table]
- Dexie.addons
- Dexie.async()
- Dexie.backendDB()
- Dexie.close()
- Dexie.currentTransaction
- Dexie.debug
- Dexie.deepClone()
- Dexie.defineClass()
- Dexie.delByKeyPath()
- Dexie.delete()
- Dexie.derive()
- Dexie.events()
- Dexie.exists()
- Dexie.extend()
- Dexie.fakeAutoComplete()
- Dexie.getByKeyPath()
- Dexie.getDatabaseNames()
- Dexie.hasFailed()
- Dexie.ignoreTransaction()
- Dexie.isOpen()
- Dexie.js
- Dexie.name
- Dexie.on()
- Dexie.on.blocked
- Dexie.on.error
- Dexie.on.populate
- Dexie.on.populate-(old-version)
- Dexie.on.ready
- Dexie.on.versionchange
- Dexie.open()
- Dexie.override()
- Dexie.semVer
- Dexie.setByKeyPath()
- Dexie.shallowClone()
- Dexie.spawn()
- Dexie.table()
- Dexie.tables
- Dexie.transaction()
- Dexie.transaction()-(old-version)
- Dexie.verno
- Dexie.version
- Dexie.version()
- Dexie.vip()
- Dexie.waitFor()
- DexieError
- Docs Home
- Download
- Export and Import Database
- Getting Started
- Hello World
- How To Use the StorageManager API
- Inbound
- IndexSpec
- Indexable Type
- IndexedDB on Safari
- Migrating existing DB to Dexie
- MultiEntry Index
- Promise
- Promise.PSD
- Promise.catch()
- Promise.finally()
- Promise.on.error
- Promise.onuncatched
- Questions and Answers
- Releasing Dexie
- Samples
- Simplify with yield
- Table
- Table Schema
- Table.add()
- Table.bulkAdd()
- Table.bulkDelete()
- Table.bulkGet()
- Table.bulkPut()
- Table.clear()
- Table.count()
- Table.defineClass()
- Table.delete()
- Table.each()
- Table.filter()
- Table.get()
- Table.hook('creating')
- Table.hook('deleting')
- Table.hook('reading')
- Table.hook('updating')
- Table.limit()
- Table.mapToClass()
- Table.name
- Table.offset()
- Table.orderBy()
- Table.put()
- Table.reverse()
- Table.schema
- Table.toArray()
- Table.toCollection()
- Table.update()
- Table.where()
- The three main limitations of IndexedDB
- Transaction
- Transaction.abort()
- Transaction.on.abort
- Transaction.on.complete
- Transaction.on.error
- Transaction.table()
- Tutorial
- Typescript
- Understanding the basics
- Version
- Version.stores()
- Version.upgrade()
- WhereClause
- WhereClause.above()
- WhereClause.aboveOrEqual()
- WhereClause.anyOf()
- WhereClause.anyOfIgnoreCase()
- WhereClause.below()
- WhereClause.belowOrEqual()
- WhereClause.between()
- WhereClause.equals()
- WhereClause.equalsIgnoreCase()
- WhereClause.inAnyRange()
- WhereClause.noneOf()
- WhereClause.notEqual()
- WhereClause.startsWith()
- WhereClause.startsWithAnyOf()
- WhereClause.startsWithAnyOfIgnoreCase()
- WhereClause.startsWithIgnoreCase()
- db.syncable.connect()
- db.syncable.delete()
- db.syncable.disconnect()
- db.syncable.getOptions()
- db.syncable.getStatus()
- db.syncable.list()
- db.syncable.on('statusChanged')
- db.syncable.setFilter()
- unhandledrejection-event


User Case Studies
KubeSphere is trusted by various enterprises and organizations to the innovators driving the future of software.
-
KubeSphere is trusted by various enterprises and organizations to the innovators driving the future of software.
-
KubeSphere is trusted by various enterprises and organizations to the innovators driving the future of software.
-
KubeSphere is trusted by various enterprises and organizations to the innovators driving the future of software.
-
KubeSphere is trusted by various enterprises and organizations to the innovators driving the future of software.
-
KubeSphere is trusted by various enterprises and organizations to the innovators driving the future of software.
-
KubeSphere is trusted by various enterprises and organizations to the innovators driving the future of software.
Various Industries are Powered by KubeSphere
- ALL
- Finance
- T Service
- E-Business
- Manufacture


| Recalls |
Does the drug have any outstanding recalls? example: Advil PM |
|
|---|---|---|
| Alternatives |
What other drugs are the same (generic) or similar (same class of drug)? example: Lipitor |
|
| Shortages |
Is there a current shortage of the drug, or has it been discontinued? example: Sodium Chloride |
|
| FDA Guides |
Does the drug have a detailed FDA Medication Guide? example: Prevacid |
|
| Adverse Events |
What adverse effects have been reported? See a summary chart, then drill down to explore individual cases. example: Xanax |


Is brain Imaging for pain measurement reliable enough for the courtroom?
In recent years, several neuroimaging-based companies claim to detect pain signals using fMRI (functional magnetic resonance imaging). Such scans for measuring pain have been used as evidence in court trials in cases involving claims of unresolved pain. Although there is a real chance at helping someone in pain by providing “proof of pain” through brain imaging techniques, it is also important to examine if such methods are actually even correct and ethical or if they can be fooled, an allure to wrongly acquiring money.
Pain is a very subjective experience. To objectively quantify it, we look at the source of the experience - the brain. Several researchers over the years have tried to understand the nature of pain using fMRI on the ground that pain shares common elements. A study at the University of Colorado investigated pain’s signature by placing people in an fMRI scanner as they touch a hot plate. Note that acute pain is being measured here. However, most court cases question the truthfulness of chronic pain. A study at the Northwestern University in Chicago scanned people with back injuries over the course of one or more years. A shift of the pain signature from the insula (associated with acute pain) to the amygdala (associated with emotion) and medial prefrontal cortex (associated with cognitive behavior) was observed; “pain is becoming more internalized”. This suggests an emotional connection to chronic pain, which may also reinforce each other.
It is relevant for science to research the nature of pain and attempt to quantify it objectively. But are the current methods accurate enough to be used in court? Given how fMRI scans have been regarded as evidence for pain in court, it is critical to scrutinize the feasibility of pain imaging both from a technical and ethical point of view and discuss its limitations.
Technical Feasibility
Given the current state of the art, it is fair to say that the current advancement in pain measurement by brain imaging is not reliable. Maybe it will be sometime in the future, but not now. Pain cannot be reliably localized to a particular brain region. Hence finding biomarkers might be advantageous. Even if the exact biomarkers are known, the challenge exists in quantifying the degree of pain at a personal level and associating it with brain regions and brain activity.
Something as subjective as pain is difficult to detect using fMRI. Increased brain activity might suggest more pain, but does not necessarily quantify pain well enough to take a legal decision. Someone’s pain tolerance might be someone else’s nightmare. The subjective character of pain makes interpersonal comparisons hard. It is important to not undervalue someone’s pain and make a decision based on it by objectively measuring pain from different subjects on a common scale. Further, all this study is based on inverse inference, which might not even be true given the abstract nature of pain. Signatures detected in pain could be seen in subjects, not in pain.
fMRI mainly measures blood flow and has a poor temporal resolution which is an issue in measuring acute pain. EEG can be useful to detect such changes. During studies, for eg. using the hot plate, it can be difficult to decouple actual pain from the thought of pain. EEG and MEG with higher temporal resolution could help deal with this by separating the pain response from anticipation. But this is more useful for acute pain. Once we know the biomarkers, using multimodal imaging methods could be more comprehensive, if the biomarker shows up in all methods. For chronic pain, I think the focus should be placed on detecting maladaptive changes and functional reorganization in the brain images as an indication of pain.
It is crucial to think about how one might fool the imaging by thinking of pain. People could also physically/mentally hurt themselves before a scan to get a positive result. Therefore, a better understanding of pain signatures and their causes is of need. However, the potential for easily deceiving the method should not prevent us from studying this further.
Ethical Analysis
Let us assume that we have a perfect way of detecting and quantifying pain using fMRI. Even then it is questionable to measure how much pain a person is in, let alone use it is as evidence in court. Can courts even accept such brain imaging results as proof of pain? If yes, how much weightage should be given to such evidence, given how there is a clear “neuro” bias found in public.
To “measure” chronic pain, a woman with back pain was imaged before and after walking. This makes us question if it is even okay to force people in chronic pain to perform tasks to induce more pain, such that a biomarker is more strongly measurable? Further, tests like an fMRI scan are not accessible and also really expensive and can even cost up to $4500. The cost can also hinder people who may genuinely need such a piece of evidence in court from having one.
Accepting such brain images in court will also increase the burden of proving one’s pain. It can also lead to forcing people to undertake these tests becoming commonplace for use in health insurance claims, medicine prescription, etc. It can cause trust issues and make us question people when they say they are in pain if they don’t have a positive pain test.
The incentive structure of this method can encourage people to cheat for money, leaves, insurance claims. It can also force people who actually are in pain, to wait to take such a test when they are hurting more. Additionally, making interpersonal comparisons of pain just for treatment, compensation, etc is unjust and gives the idea that being more in pain is advantageous.
Having proper pain measurement methods does not make the underlying social issue that makes such a test relevant in court in the first place. The incentive for most of these cases in court is poor health insurance systems. A well-functioning health care system may reduce the need for pain detection, at least in legal cases.
All this said pain research is important both for science and society. Such a method can help to secure an out-of-court settlement, saving a lot of time and money. It will also help combat stigma against people in chronic pain by providing a way of it. The communication of scientific breakthroughs influences the way the public perceives and utilizes such technologies as pain measurement. Therefore it is important to both introduce and use such pain measurement techniques judiciously.


Spicy jalapeno bacon ipsum dolor amet sirloin tongue chuck biltong bresaola, frankfurter beef ribs doner shank. Pork shoulder ball tip pancetta pastrami flank. Buffalo filet mignon ground round bacon strip steak venison. Meatloaf ground round short ribs, beef cow chicken shankle venison. Turkey bacon kielbasa, pork turducken pastrami landjaeger ball tip leberkas.
Turducken sirloin pork chop pork belly. Picanha jowl sausage brisket burgdoggen tenderloin. Pork loin meatloaf sausage, strip steak beef ribs burgdoggen pork filet mignon bresaola tail jowl tongue picanha hamburger porchetta. Cupim prosciutto salami, hamburger landjaeger shank rump ham ground round ribeye beef short ribs swine.


The gap encodes the distance between clusters and improves interpretation of cluster heatmaps. The gaps can be of the same distance based on a height threshold to cut the dendrogram. Another option is to vary the size of gaps based on the distance between clusters.
| Version: | 0.0.4 |
| Depends: | R (≥ 2.10), ggplot2, reshape2 |
| Imports: | grid |
| Suggests: | knitr, dendsort, RColorBrewer |
| Published: | 2016-12-05 |
| Author: | Ryo Sakai |
| Maintainer: | Ryo Sakai <ryo at vda-lab.be> |
| License: | GPL-2 | GPL-3 |
| URL: | https://bitbucket.org/vda-lab/gapmap |
| NeedsCompilation: | no |
| CRAN checks: | gapmap results |
| Reference manual: | gapmap.pdf |
| Vignettes: |
An Introduction to the gapmap package An example with a TCGA dataset |
| Package source: | gapmap_0.0.4.tar.gz |
| Windows binaries: | r-devel: gapmap_0.0.4.zip, r-release: gapmap_0.0.4.zip, r-oldrel: gapmap_0.0.4.zip |
| OS X binaries: | r-release: gapmap_0.0.4.tgz, r-oldrel: gapmap_0.0.4.tgz |
| Old sources: | gapmap archive |
| Reverse suggests: | dendsort |
Please use the canonical form https://CRAN.R-project.org/package=gapmap to link to this page.


Connecting to Device
Device Ready
Presentation Available s
Connected. Click to ping#1.
Click to close.


QGIS Resource Sharing
Google Summer of Code 2016
Akbar Gumbira (student), Alessandro Pasotti (mentor), Anita
Graser (mentor) with the help of Richard Duivenvoorde, Tim
Sutton, and QGIS community.
Problem
Have you ever found yourself needed to share QGIS resources?
..you know stuffs like SVG
..symbols or colorramps
..styles
..processing scripts
..or composer templates?
Problem
But it's too dark for your friends to put
those resources in the right place
..or that you wish you can search available
resources out there somewhere just from your QGIS
Why don't we make something similar to our successful plugin manager?
...where users can make their own
resource repository
...and that other users can browse and install
collections available in that repository
And that it needs to have a distributed repository system...
Because then we can do cool stuffs
Put it on git platform, fork repositories
and custom the resources as we want
Put the repository on ftp, scp, or other
protocols (though these are not implemented yet :p)
And a new QGIS plugin is implemented (yay)
Where users can add repository..
Browse and filter collections..
And install collections..
But there is always something to fix and improve..
Room for Improvement
- Better 'Help' system (now only linking to online
documentation)
- Translation
- More unittests
- Collection versioning
- More resource handler: composer (qpt), project file (.qgs)
- Feature to create repository, metadata, and manage the
collections
End of Slide and Summer..


Of 22,432 displaced people listed by Bangladesh for repatriation, 21,078 scrutinized
by Thar Shwe Oo
A press release issued by the Ministry of Foreign Affairs has stated that 21,078 out of 22,432 displaced people on the list sent by Bangladesh have been scrutinized.
The scrutiny was conducted by the Ministry of Labour, Immigration and Population till November 8.
Bangladeshi officials handed over the list of 22,432 displaced persons to a Myanmar delegation during the third meeting of the joint task force of Myanmar and Bangladesh on repatriation of those who lived in Myanmar held in Dakar in October 2018.
For the smooth of resettlement of the returnees from Bangladesh, the Ministry of Labour, Immigration and Population is making village-wise lists and sending them to Bangladesh in batches. A list of 3,450 people was sent to July 11, 2019.
Under the bilateral agreement, Myanmar started preparations for repatriation on January 23, 2018, but no one has reentered the country so far.
However, till November 1 this year, 414 displaced people have entered Myanmar of their own accord, according to the Myanmar Embassy in Dakar.


climate change thermal Pörtner temperature {border-style effects evolutionary limits px;} #ffffff;} tolerance organisms OCLTT physiological species (Pörtner capacity (e.g., Bozinovic warming Biol levels organism variability ocean Exp. interactions marine animals ecological ecosystem need oxygen performance px; responses {font-family Ecol. Farrell changes concept distribution drivers example, experimental font-size functional global scope understanding Climate adaptation biotic complexity double; ecosystems limiting role suggest terrestrial various acidification approaches border-color border-width development domains ecology environmental extreme future limited molecular physiology reaction relevant shape solid; {font-style {font-weight Angilletta Biochem. Boyd Estay Evol. Folguera Knust Physiological Press Proc. Res USA adaptation, basis biology bold changing concepts courier; determine different ectotherms efforts em; evolution factors field fitness framework group high impacts individual key lethal likely limitation modified norms programs pt;} research shifts species, studies systems temperatures theoretical unifying


--- layout: post status: publish published: true title: Polyphonic C# author: display_name: Tomas Restrepo login: tomasr email<EMAIL_ADDRESS>url: http://winterdom.com/ author_login: tomasr author_email<EMAIL_ADDRESS>author_url: http://winterdom.com/ wordpress_id: 893 wordpress_url: http://winterdom.com/2002/08/polyphonicc date: '2002-08-25 06:26:54 +0000' date_gmt: '2002-08-25 06:26:54 +0000' categories: - ".NET" tags: [] comments: - id: 612 author: logena author_email<EMAIL_ADDRESS>author_url: '' date: '2007-05-24 05:57:06 +0000' date_gmt: '2007-05-24 05:57:06 +0000' content: | < please help me> ---
Cool things come from MS Research from time to time. Here's one of them: Polyphonic C#. Here's the description:
Polyphonic C# extends the C# programming language with new asynchronous concurrency abstractions, based on the join calculus. The language presents a simple and powerful model of concurrency which is applicable both to multithreaded applications running on a single machine and to the orchestration of asynchronous, event-based applications communicating over a wide area network.


Nature isn't classical, dammit, and if you want to make a simulation of nature, you'd better make it quantum mechanical.
subatomic modeling, molecular simulations, material science
problem optimization, energy research, simulation
quantum classifiers, hybrid quantum/classical training
risk analysis, complex simulations, portfolio optimization
In classical computing a bit can have only two discrete values
In quantum information theory an information unit is called a qubit.
The qubit is described by a two dimensional state vector, where $\alpha$ and $\beta$ are complex numbers.
$$|\alpha|^2 + |\beta|^2 = 1$$
$$ 0 = \begin{bmatrix} 1 \cr 0 \end{bmatrix} = \ket{0}$$ $$ 1 = \begin{bmatrix} 0 \cr 1 \end{bmatrix} = \ket{1} $$
The basis choice is a way
information into and from qubits
Any quantum state can be expressed as a linear combination of the $\mathbf{Z}$ basis states
If both $\alpha$ and $\beta$ are non-zero, the system is in a
Quantum state is not directly observable. It must be
Upon measurement, quantum state collapses to one of the observable states
$$P(0) = P(\ket{0}) = |\alpha|^2$$ $$P(1) = P(\ket{1}) = |\beta|^2$$
$$ 0 = \frac{1}{\sqrt{2}}\begin{bmatrix} 1 \\ 1 \end{bmatrix} = \ket{+}$$ $$ 1 = \frac{1}{\sqrt{2}}\begin{bmatrix} 1 \\ -1 \end{bmatrix} = \ket{-} $$
The strength of quantum computers is that the are able to take algorithmic advantage of superposition. This is called
Heuristically, and at the risk of over-simplifying, quantum parallelism allows quantum computers to evaluate a function $f(x)$ for many different values of x simultaneously.
In quantum mechanics we cannot simultaneously know values of
with arbitrary precision.
Those are for example position & momentum or energy & time.
$\Delta x \Delta p \geq \frac{\hbar}{2}$
$\Delta E \Delta t \geq \frac{\hbar}{2}$
By Ahmed Neutron - Own work, CC BY-SA 4.0, https://commons.wikimedia.org/w/index.php?curid=69715938
In quantum computing, the measurements in the $\mathbf{Z}$ and $\mathbf{X}$ bases do not commute.
Measurement in the $\mathbf{Z}$ basis creates
in $\mathbf{X}$ the basis, and vice versa.
I am convinced that Old Man [God] does not play dice
Superposition is basis dependent.
| 👧🏻 | 1 | 0 | 0 | 1 | 0 | 1 | 1 | 0 | 1 | 0 | 0 | 1 | 0 | 1 | 1 | 0 |
| Z | Z | X | Z | Z | X | Z | X | X | Z | X | Z | X | X | X | Z | |
| 💌 | ||||||||||||||||
| 👦🏼 | Z | Z | Z | X | X | Z | Z | X | X | Z | Z | Z | Z | X | X | X |
| 1 | 0 | ❌ | ❌ | ❌ | ❌ | 1 | 0 | 1 | 0 | ❌ | 1 | ❌ | 1 | 1 | ❌ |
Shared key: 0 1 0 1 0 1 1 1
Because arbitrary quantum states cannot be cloned, an attacker, 🦹♀ Eve, would need to measure the qubits to steal information.
She must guess between $\mathbf{Z}$ and $\mathbf{X}$ bases.
👧🏻 👦🏼 Alice and Bob should compare half of their resulting bits to perform an eavesdropper check.
If 👧🏻 👦🏼 Alice and Bob find mismatches between the bits for which their bases agreed, they detected an attacker.
To describe the state of a two qubit system, we use a tensor product of the individual qubit states, thus creating a vector in a four dimensional Hilbert space.
$$\ket{\psi_1} = \alpha_1\ket{0} + \beta_1\ket{1} \;\;\; \ket{\psi_2} = \alpha_2\ket{0} + \beta_2\ket{1}$$
$$\ket{\psi_{12}} = \alpha_1\alpha_2\ket{00} + \alpha_1\beta_2\ket{01} + \beta_1\alpha_2\ket{10} + \beta_1\beta_2\ket{11}$$
Quantum state of a qubit system of size $n$ is described by $2^n$ amplitudes. For example, for a 260 qubit computer:
which roughly equals of atoms in observable universe
This works well for independent qubits but breaks down for entangled states.
We cannot find $\alpha_1$, $\alpha_2$, $\beta_1$ and $\beta_2$ to satisfy
$\alpha_1\alpha_2\ket{00} + \alpha_1\beta_2\ket{01} + \beta_1\alpha_2\ket{10} + \beta_1\beta_2\ket{11} = \frac{1}{\sqrt{2}}(\ket{00} + \ket{11})$
We cannot decompose an entangled quantum state into a tensor product of the individual quantum states.
A single quantum state can span across multiple spatially separated quantum objects, which seem to affect each other instantly.
Einstein called it
We call this
Exploring entanglement in algorithms is a critical factor contributing to computational advantage of quantum computing.
$$ H=\frac{1}{\sqrt{2}}\begin{bmatrix} 1 & 1 \\ 1 & -1 \end{bmatrix}$$
$$H\ket{0} = \frac{1}{\sqrt{2}}\begin{bmatrix} 1 & 1 \\ 1 & -1 \end{bmatrix}\begin{bmatrix} 1 \\ 0 \end{bmatrix} = \frac{1}{\sqrt{2}}\ket{0} + \frac{1}{\sqrt{2}}\ket{1}$$
$$H\ket{1} = \frac{1}{\sqrt{2}}\begin{bmatrix} 1 & 1 \\ 1 & -1 \end{bmatrix}\begin{bmatrix} 0 \\ 1 \end{bmatrix} = \frac{1}{\sqrt{2}}\ket{0} - \frac{1}{\sqrt{2}}\ket{1}$$
Upon measurement, there is a 50% probability of reading out a classical 0 or a classical 1.
$$ X=\begin{bmatrix} 0 & 1 \\ 1 & 0 \end{bmatrix}$$
$$X(\alpha\ket{0} + \beta\ket{1}) = \begin{bmatrix} 0 & 1 \\ 1 & 0 \end{bmatrix}(\alpha\ket{0} + \beta\ket{1}) = \beta\ket{0} + \alpha\ket{1}$$
$$X\ket{0} = \begin{bmatrix} 0 & 1 \\ 1 & 0 \end{bmatrix}\begin{bmatrix} 1 \\ 0 \end{bmatrix} = \ket{1}$$
$$X\ket{1} = \begin{bmatrix} 0 & 1 \\ 1 & 0 \end{bmatrix}\begin{bmatrix} 0 \\ 1 \end{bmatrix} = \ket{0}$$
$$ CNOT=\begin{bmatrix} 1 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 \\ 0 & 0 & 0 & 1 \\ 0 & 0 & 1 & 0 \end{bmatrix}$$
$$\ket{00}\rightarrow\ket{00} \;\;\; \ket{01}\rightarrow\ket{01} \;\;\; \ket{10}\rightarrow\ket{11} \;\;\; \ket{11}\rightarrow\ket{10}$$
When the control qubit is in placed in a superposition, a maximally entangled state is created.
$$CNOT(H\ket{0} \otimes \ket{0}) = \frac{1}{\sqrt{2}}\ket{00} + \frac{1}{\sqrt{2}}\ket{11}$$
Upon measurement, there is a 50% probability of reading out a classical 00 or a classical 11.
> dotnet new console -lang Q#
The template "Console Application" was created successfully.
> dotnet run
Hello quantum world!
@EntryPoint()
operation Start() : Int {
use qubits = Qubit[8];
ApplyToEach(H, qubits);
// create a QPU register
let register = LittleEndian(qubits);
// measure the entire register to retrieve the integer
let randomNumber = MeasureInteger(register);
return randomNumber;
}
operation EntanglementExample() : Unit {
use (control, target) = (Qubit(), Qubit());
H(control);
CNOT(control, target);
let resultControl = MResetZ(control) == One ? "1" | "0";
let resultTarget = MResetZ(target) == One ? "1" | "0";
Message($"Result: |{resultControl}{resultTarget}>");
}
// queue job
az quantum job submit --target-id {target} --job-name {name}
// check job status
az quantum job show --job-id {id}
// fetch job output
az quantum job output --job-id {id}
Result Frequency
--------- ----------- ----------------------
[0,0,1,1] 1.00000000 |████████████████████|


pbmtopi3(1) pbmtopi3(1) NAME pbmtopi3 - convert a portable bitmap into an Atari Degas .pi3 file SYNOPSIS pbmtopi3 [pbmfile] DESCRIPTION Reads a portable bitmap as input. Produces an Atari Degas .pi3 file as output. SEE ALSO pi3topbm(1), pbm(5), ppmtopi1(1), pi1toppm(1) AUTHOR Copyright (C) 1988 by David Beckemeyer (bdt!david) and Jef Poskanzer. 11 March 1990 pbmtopi3(1)


epidemic factors dengue PRD BYM cases epidemics < environmental spatial China areas fever socioeconomic grid {border-style data land px;} study #ffffff;} km []. variables (Fig. Yunnan characteristics influencing Pearl River analysis model China, GAM NDVI higher local population regional regions density factors, ratio risk control distribution fitting relatively Border Myanmar Public conditions differences prevention Fig. Moran’s Temp addition, difference imported mosquito road used vegetation Data Delta Environ ULR file grids land, px; region represents showed use values variance {font-family Hum Infect Mean Med Pop Research Trop additive climate font-size index main number optimal typical urban Additional Aedes China’s Environmental Guangdong PRD, ULR, Xishuangbanna [], approximately areas, case different double; factor health high important incidence nonlinear observed patterns relationship significant studies temperature terms using water (No. (see BYM, Dehong Dengue Funding Health Health./ijerph NDVI, Res Spatial Therefore, affect areas. based border-color border-width developed disease domestic function generalized mainly meteorological outbreak pattern precipitation prevalence recent regression solid; spatial-temporal spatiotemporal study, suitable transmission variable virus {font-style {font-weight (April–November) A), BYM. Information Key LINKAdditional National Normal Pre Province, Road Table Thus, [–]. activity adjacent aegypti analyse annual area article autocorrelation average better bold breeding change changes clustering collinearity correlation courier; density, effect effectively effects em; epidemics, epidemics. especially explained factors. greater included increasing independent indicates infectious inland kb) linear link mean measures models moderate monthly occurred performed previous provide pt;} relative results selected shown shows significantly single slightly value vector years, km × km


Bored Blog
Bored Blog is a site where you can glean more information about exciting bored games that you can play when you're bored! We feature games old and new, suitable to many age ranges and skill levels.
We have several contributors that share their interests in games of all sorts - family games, strategy games, card games, trivia games, games with mystery and games of challenge. Each week we post a "Game of the Week" which features a game that the contributors are currently learning or have found a great interest in either its history, uniqueness or actual game play.
Don't be bored ... play a board game!
Board games have been played, travelled and evolved in most cultures and societies throughout history. A board game need not necessarily contain a physical board. Some games are based on pure strategy, but many contain an element of chance; and some are purely chance, with no element of skill.
Games usually have a goal that a player aims to achieve. Early board games represented a battle between two armies, and most modern board games are still based on defeating opponents in terms of counters, winning position, or accrual of points.


I’m a graduating senior at Florida State University studying Information Technology. My passion lies in the area of big data, design and software development. I would describe myself as a passionate learner and leader; I’m ambitious, motivated and professional. What I look forward to after I graduate is using my passions, skillset, and experience towards a career in helping businesses make better decisions through the use of data and technology.
Tampa, FL (Starting July 2016)
Thrilled to be starting my career as an applications developer within the Technology Analyst Program
Tallahassee, FL (June 2014 - Present)
Tampa, FL (June 2015 - August 2015)
Tallahassee, FL (May 2015 - Present)
Tallahassee, FL (December 2015 - February 2016)
Tallahassee, FL (December 2015 - February 2016)


Details
{{model.brewery.name}}
Located in {{model.brewery.locations[0].locality}}, {{model.brewery.locations[0].region}}
{{model.brewery.locations[0].streetAddress}}
{{model.brewery.locations[0].phone}}
Description:
{{model.brewery.description}}
Hours of Operation: {{model.brewery.locations[0].hoursOfOperation}}
Established: {{model.brewery.established}}
{{model.brewery.website}}{{model.brewery.socialAccounts[0].link}}


(F) (M) (F); {border-style px;} #ffffff;} dengue DENV- genotype Asian collected mosquitoes pools px; strains using virus {font-family Mato font-size serum Study double; sequences (Cux.) Brazil Cx. Med Southeast analysis border-color border-width comprising detected epidemics forest genotype. solid; {font-style {font-weight (,/mm) Asian/American Brazil, Grosso PCR associated based bold circulation courier; data em; fever major partial presenting pt;} related results samples state tree viruses


--- title: "2023" linkTitle: "2023" weight: -99992023 ---
# of Merged PRs reviewed
# of words written in merged PRs
# of Review Comments in merged PRs
# of Pull Requests Merged
Lines of code (delta)
Average PR size (added+changed)
# of comments
# of words (excludes authored)
# of issues closed (excludes authored)


---
layout: post
esbma_id: 1410
date: 2002-03-05 12:00:00
keywords: cornsharp
title: Blog entry on 05 Mar 2002
---
Beware the Ides of March!
Joel Spolsky: "Yeah, I know, you read Kent Beck and now you think it's OK to not design things before you implement them. Sorry, it's not OK."
I don't *always* agree with Joel's stuff, but I always enjoy reading it.
I wonder why the Joel link disappeared from Dave Winer's blogrolling list a few weeks ago?


{% extends 'layout.anonymous.html' %} {% block body %}
Don't worry! Seems you mistyped address, may be you want to start from home page?


---
layout: default
title: 刘晓庆课题组-成员
categories:
- members
---
{% for member in site.categories.members reversed %}
{% if member.position == "课题组负责人" %}
{% include member_links.html member_loc=member %}
{{ member.title }}
{{ member.content }}
{% break %}
{% endif %}
{% endfor %}
{% include member_loop.html member_role="博士后" alumni=false %}
{% include member_loop.html member_role="博士研究生" alumni=false %}
{% include member_loop.html member_role="硕士研究生" alumni=false %}
{% include member_loop.html member_role="本科生" alumni=false %}
{% include member_loop.html alumni=true%}


Across: 8. Drug delivery devices recently promoted via press or otherwise (10) 9. Cut back violently and fast (4) 10. Highlight in act oddly clean (6) 11. (Dirty act in non-mainstream show) (8) 12. Bill upset Rio showing behind (9) 14. Some you surprise, as you may during a coup! (5) 16. see 26 19. Primary piece of information: PM Luigi out after 1 2 (5) 20. Donkey is dull colour, but ultimately helpful companion (9) 22. Mild acne treated for first black Oscar winner (8) 23. Gets better presented as diet is working (6) 25. What lies might be about? Mull perhaps! (4) 26,16. 4 got what he wanted from him... "I've man in 2: tick! Luigi: out!" (4 6 8 3) Down: 1,2. Mormon reach cultivated in massive demonstration in 1922 (5 2 4) 2. see 1 3. He studies past his time, or gets in about one (9) 4. Leader in sublime? Soon it gets ridiculous! (6 9) 5. Comment on strange ideas (5) 6. 17 boy doesn't have right to be included in attack (10) 7. One in a N.Y. rut at work, lacking diversity (7) 13. Essentially, fiction by which I met composer who died in 1937? (4 6) 15. Sad tip: an evil development (9) 17. Is 19's undoing one out supporting 4 in '22? (7) 18. Even letters cut for surround (7) 21. Not all learners developed skills to be lawyers (5) 24. Introduced 4? (4)


This analysis is a placeholder with a sample set. If you want to contribute new analyses for the site, contact Disaster Area on Discord.
- Meditate
- Rolling Kick / Submission
- Earthquake
- Hyper Beam / Body Slam
This analysis is a placeholder with a sample set. If you want to contribute new analyses for the site, contact Disaster Area on Discord.
Counter, Fire Blast, Rock Slide, Substitute.
This analysis is a placeholder with a sample set. If you want to contribute new analyses for the site, contact Disaster Area on Discord.
Author: Caetano93
Publish Date: 11th June 2020


Area of operation: all Marinas in NE Sardinia.
We can provide:
- Weekly, biweekly schedule.
- Tailor-made services and timing.
- On line reports and pictures/videos.
- Full Yacht Services Management.
Standard services:
- Mooring lines and fenders check.
- Deck washing, inox polishing.
- Interiors: aeration, cleaning.
- Engine room, bilges and technical spaces: checking, cleaning.
- Engines and generators running.
- AC, toilets, pumps, running and checking.
Other Services:
- Carpet, upholstery deep cleaning.
- Scotch Guard® treatment.
- Canvas, bimini, flexible windows cleaning.
- Seasons preparation.
- Delivery.
Also Available:
- Documents update.
- Safety equipment service.
- Provisioning.
- Fuel refill.
- Pump-out Services
- Shipyard services quotations
- Moorings quotations
- Others services on request


Description
The DateLabel control lets you display a date in a clear and unambiguous way. The
DateLabel may include:
- an exact date including the day of the week
- an exact date
- a date marked as approximate
- a month and year
- a year only
- a null index date where the exact text displayed can be defined by the ISV
- a null date
Additional Information
Additional information relating to this control can be found on the corresponding MSCUI control page.


|
CANopenNode
|
CANopenNode is free and open source implementation of CANopen communication protocol. More...
Modules | |
| CANopen configuration | |
| Definitions specify, which and how many CANopenNode communication objects will be used in current configuration. | |
Files | |
| file | CANopen.h |
| Main CANopenNode file. | |
Data Structures | |
| struct | CO_t |
| CANopen object with pointers to all CANopenNode objects. More... | |
Functions | |
| CO_ReturnError_t | CO_new (uint32_t *heapMemoryUsed) |
| Allocate and initialize memory for CANopen object. More... | |
| void | CO_delete (void *CANptr) |
| Delete CANopen object and free memory. More... | |
| CO_ReturnError_t | CO_CANinit (void *CANptr, uint16_t bitRate) |
| Initialize CAN driver. More... | |
| CO_ReturnError_t | CO_LSSinit (uint8_t *pendingNodeID, uint16_t *pendingBitRate) |
| Initialize CANopen LSS slave. More... | |
| CO_ReturnError_t | CO_CANopenInit (uint8_t nodeId) |
| Initialize CANopenNode. More... | |
| CO_NMT_reset_cmd_t | CO_process (CO_t *co, uint32_t timeDifference_us, uint32_t *timerNext_us) |
| Process CANopen objects. More... | |
| bool_t | CO_process_SYNC (CO_t *co, uint32_t timeDifference_us, uint32_t *timerNext_us) |
| Process CANopen SYNC objects. More... | |
| void | CO_process_RPDO (CO_t *co, bool_t syncWas) |
| Process CANopen RPDO objects. More... | |
| void | CO_process_TPDO (CO_t *co, bool_t syncWas, uint32_t timeDifference_us, uint32_t *timerNext_us) |
| Process CANopen TPDO objects. More... | |
Variables | |
| CO_t * | CO |
| CANopen object. | |
CANopenNode is free and open source implementation of CANopen communication protocol.
CANopen is the internationally standardized (EN 50325-4) (CiA DS-301) CAN-based higher-layer protocol for embedded control system. For more information on CANopen see http://www.can-cia.org/
CANopenNode homepage is https://github.com/CANopenNode/CANopenNode
CANopen.h file combines Object dictionary (CO_OD) and all other CANopen source files. Configuration information are read from CO_OD.h file. CO_OD.h/.c files defines CANopen Object Dictionary and are generated by external tool. CANopen.h file contains most common configuration of CANopenNode objects and can also be a template for custom, more complex configurations.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
https://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
| CO_ReturnError_t CO_CANinit | ( | void * | CANptr, |
| uint16_t | bitRate | ||
| ) |
Initialize CAN driver.
Function must be called in the communication reset section.
| CANptr | Pointer to the user-defined CAN base structure, passed to CO_CANmodule_init(). |
| bitRate | CAN bit rate. |
| CO_ReturnError_t CO_CANopenInit | ( | uint8_t | nodeId | ) |
Initialize CANopenNode.
Function must be called in the communication reset section.
| nodeId | CANopen Node ID (1 ... 127) or 0xFF(unconfigured). In the CANopen initialization it is the same as pendingBitRate from CO_LSSinit(). If it is unconfigured, then some CANopen objects will not be initialized nor processed. |
| void CO_delete | ( | void * | CANptr | ) |
Delete CANopen object and free memory.
Must be called at program exit.
| CANptr | Pointer to the user-defined CAN base structure, passed to CO_CANmodule_init(). |
| CO_ReturnError_t CO_LSSinit | ( | uint8_t * | pendingNodeID, |
| uint16_t * | pendingBitRate | ||
| ) |
Initialize CANopen LSS slave.
Function must be called before CO_CANopenInit.
See CO_LSSslave_init() for description of parameters.
| [in,out] | pendingNodeID | Pending node ID or 0xFF(unconfigured) |
| [in,out] | pendingBitRate | Pending bit rate of the CAN interface |
| CO_ReturnError_t CO_new | ( | uint32_t * | heapMemoryUsed | ) |
Allocate and initialize memory for CANopen object.
Function must be called the first time, after program starts.
| [out] | heapMemoryUsed | Information about heap memory used. Ignored if NULL. |
| CO_NMT_reset_cmd_t CO_process | ( | CO_t * | co, |
| uint32_t | timeDifference_us, | ||
| uint32_t * | timerNext_us | ||
| ) |
Process CANopen objects.
Function must be called cyclically. It processes all "asynchronous" CANopen objects.
| co | CANopen object. | |
| timeDifference_us | Time difference from previous function call in microseconds. | |
| [out] | timerNext_us | info to OS - maximum delay time after this function should be called next time in [microseconds]. Value can be used for OS sleep time. Initial value must be set to maximum interval time. Output will be equal or lower to initial value. Calculation is based on various timers which expire in known time. Parameter should be used in combination with callbacks configured with CO_***_initCallbackPre() functions. Those callbacks should also trigger calling of CO_process() function. Parameter is ignored if NULL. See also CO_CONFIG_FLAG_CALLBACK_PRE configuration macro. |
Process CANopen RPDO objects.
Function must be called cyclically from real time thread with constant. interval (1ms typically). It processes receive PDO CANopen objects.
| co | CANopen object. |
| syncWas | True, if CANopen SYNC message was just received or transmitted. |
Process CANopen SYNC objects.
Function must be called cyclically from real time thread with constant interval (1ms typically). It processes SYNC CANopen objects.
| co | CANopen object. | |
| timeDifference_us | Time difference from previous function call in microseconds. | |
| [out] | timerNext_us | info to OS - see CO_process(). |
| void CO_process_TPDO | ( | CO_t * | co, |
| bool_t | syncWas, | ||
| uint32_t | timeDifference_us, | ||
| uint32_t * | timerNext_us | ||
| ) |
Process CANopen TPDO objects.
Function must be called cyclically from real time thread with constant. interval (1ms typically). It processes transmit PDO CANopen objects.
| co | CANopen object. | |
| syncWas | True, if CANopen SYNC message was just received or transmitted. | |
| timeDifference_us | Time difference from previous function call in microseconds. | |
| [out] | timerNext_us | info to OS - see CO_process(). |


An energy entry for the AEC Hackathon.
This is where we can write up the details of what has been accomplished. We can change the change the name easily.
Sample Folder ABC
Iteration system wide engenders economies of scale, cross-media technology, presentation action items and life cycle replication.
Sample Folder DEF
Marketing teams input produce cross purposing in view of goal alignments due to knowledge paucity, necessitating workflow education and orientation. Media sourcing as an acquisition strategy is counterproductive in a internet environment in virtual component methodology. Imaging through ideals rather than real world branding, is a perilous undertaking with negative results. Branding strategies generating motion as activity without reproducible results is a ultimately futile effort if left in place.


Having one or even multiple physical cookbooks,
or index cards, filled with your Family's
passed down secrets can be cumbersome.
Even worse if you say lose one part, or it becomes damaged.
Our Modern approach to allow you to put those heirlooms to
rest where they'll be
protected with our application:
That's the Easy part.
How easy you ask? It's as simple as Upload, Type in, and Submit.
First you Upload a picture, or multiple pictures.
Then you type in your recipe, including:
After that, you submit your recipe, and you'll be taken
to your own personal dashboard
to view them and select which one you want to use.


Home
Sign Up
About Us
If you would like to be kept up to date on our launch progress, please fill out the form below!
Name
Email
Tell us about yourself! (optional):
We want to know more about you!
Submit your info


Find a car for you
Sedans
Choose a sedan for its affordability and excellent fuel economy. Ideal for cruising in the city or on your next road trip.
SUVs
Take an SUV for its spacious interior, power, and versatility. Perfect for your next family vacation and off-road adventures.
Luxury
Cruise in the best car brands without the bloated prices. Enjoy the enhanced comfort of a luxury rental and arrive in style.


Victory in Europe (VE) Day celebrations
A 3-day weekend of events will mark the 70th anniversary of Victory in Europe (VE) Day.
This page is an example of how to use this content type. Back to the guidance (other links on this page may not work).
Topic
Friday 8 May 2015 is the anniversary of VE Day (Victory in Europe Day), marking 70 years since the end of the second world war in Europe.
The occasion will be commemorated with events across the UK.
A 3-day weekend of events will mark the 70th anniversary of Victory in Europe (VE) Day.
Over 200 beacons will be lit on Friday 8 May to mark Victory in Europe (VE) Day.
This online events map tracks events across the UK marking the 70th anniversary of Victory in Europe (VE) Day.
This page provides general information and lists events taking place throughout the 3-day weekend marking the 70th anniversary of VE Day.


Machine Translation¶
Introduction¶
Machine translation system converts Documents in Source Language to Documents in Target Language.
Methodology¶
Background¶
Machine translation is a three step process:
Step 0: Find lots of example source language sentences and corresponding human translations into target language. This is called bilingual parallel corpora or Bitext.
Step 1: Apply a learning algorithm to parallel corpora and build an approximate model of human translation.
Step 2: Apply learned model to new source language text and obtain translations in target language.
Machine Translation Model
The translation must be semantically adequate, which means that all of the meaning in the source language in the sentence/document should carry over to the target language. So there should be no meaning lost. And the other thing is whatever meaning rendered in the target language, is fluent in that language. So words shouldn’t be in some random order. To appreciate how Machine Translation has evolved through the years, we’ll touch upon a few history aspects of it.
There were three popular approaches before SMT and NMT:
Rule based - you write a bunch of rules that take specific parts of the source language and translate them to specific parts of the target language.
Interlingual translations - here we basically take the source language text and you reduce it to language independent formalism and then you generate the target language text from that formalism.
Transfer Based - So what if we do something in the middle. where we do some bit of analysis and write some sort of rules to transfer from that analytic form to the target language analytic form.
All three approaches no longer exist. Except for Rule Based on a few hybrid systems.
Process¶
Samoses¶
PCL is a Domain Specific Language to construct non-recurrent software pipelines. We are using PCL to build pipeline for the Statistical Machine Translation.
Samoses provides the pipeline for training and serving machine translation model. One has to just plug the dataset and the rest of the process in building a Machine translation system is taken care by Samoses.
Experiments were carried out with English-Hindi using NYU and IIT-B datasets. Results can be found at http://moses.samantar.in/ .
Summary¶
A statistical machine translation model is built using Moses. A pipeline to train and serve the Machine translation model has been laid using PCL in Samoses.
Please feel free to write us at<EMAIL_ADDRESS>, if you have any questions or concerns, we are happy to help!


Returns a File object.
fil = app.CreateFile(
file,
mode ) →
app object: File
The following methods are available on the File object:
string: path to file or folder ( "/absolute/..." or "relative/..." )
string: “r” or “w” or “rw”
length in bytes
GetPointer
Returns the control class name.
string
string: comma “,” separated: “boolean”, “char”, “byte”, “short”, “int”, “long”, “float”, “double”
Allows access to other functions defined on the object in Java via reflection.
number: integer
unknown
read len bytes from file
returns whole contrastent as number
return whole contrastent as text
ReadTextAsync
jump to given byte
?
skip a given number of bytes
writes ? to file
number
writes a number to file
writes text to file


Kickstart Your Website
With
Slider Revolution
Unlimited Transitions
Sliding, Fading, Slots, Box Transitions
SLIDER REVOLUTION
has it all!
Responsive & Mobile Optimized
Customizable Navigation
Arrows, Bullets, Thumbs
Don't you love this?
We Love Our Clients
Need Help with your Project?
Get in Touch
GET THE
PARTY
STARTED
SIGN UP HERE
American Muscle Car
4.6l V8 Engine
20 inch Rims
Video Support
Vimeo Example
You can easily add
Vimeo & Youtube Videos
to your Slides
Video Support
Youtube Example
You can easily add
Vimeo & Youtube Videos
to your Slides
Serving you the Ultimate Slider
Get Slider Revolution today!


Mobile CI
| Service | Status |
|---|---|
| Circle CI | |
| Travis CI | |
| Bitrise io | |
| Maintainability | |
| Code Coverage |
CI playground mainly testing circle CI orbs and GitHub actions.
Info
- A playground for GitHub actions and CI’s for iOS development.
Setup
Komondor
Git Hook automation for Swift and Xcode projects. A port of Husky to Swift.
- Install Komondor by running
swift run komondor install
Continuous integration
Circle CI
The config file defines multiple jobs and the workflow for circle builds.
Travis CI
See .travis.yml
Bitrise
GitHub Actions
github-tag-action
A Github Action to automatically bump and tag master, on merge, with the latest SemVer formatted version.
- A tag is automatically created for release branches.
- Manual Bumping is possible by including any of the following in a commit message: #major, #minor, or #patch
Note
If multiple are present the highest-ranking takes precedence.
Features
- [x] Circle CI with a custom ORB
- [x] Travis CI
- [x] Bitrise CI
- [x] Caching strategy - CI build performance
- [ ] git commit hooks
- [ ] Circle CI ORB example
- [ ] Documentation
GitHub actions.
- [x] Tag action
- [ ] Auto label
- [ ] Auto merge
- [ ] GitFlow


Enums
The following enums are available globally.
-
Result returned by a swiftlet to indicate whether it has handled the request. If a
Content-Length
header has been provided the connection can be reused in the HTTP/1.1 protocol and the connection will be kept open and recycled.Declaration
Swift
@objc public enum DynamoProcessed: Int


 Telephones: +1<PHONE_NUMBER> +1<PHONE_NUMBER> +1<PHONE_NUMBER> Address 2: 9867 Mill Road, Cambridge, MG09 99HT. Contact Form *This field is required. *This is not a valid name. *This field is required. *This is not a valid email. *This field is required. *This is not a valid phone. *This field is required. *The message is too short. Send × Modal title You message has been sent! We will be in touch soon.
9870 St Vincent Place, Glasgow, DC 45 Fr 45. 800 2345-6789
Telephones:
+1<PHONE_NUMBER>
+1<PHONE_NUMBER>
+1<PHONE_NUMBER>