Went for 4 days to the southern canyon lands of Utah. Found an isolated camping spot and spent the first evening setting up camp site 30 feet from cliff edge. Beautiful blond cliffs with red layers below me, blue soaring skies above. Eating light first night.
Up at sunrise. Fruit, nuts and water in pack, didgeridoo over shoulder, and off on a hike to get my body present in the new local. I have always found that walking, covering ground, and then napping midday to be a useful scenario for getting present in the local land's energy.
Walked six+ miles down hill. Short break at around 2pm. Nap and didge playing in the crevices of the sandstone. Feeling more connected and open. The textures of the stone and grass and clouds are guide me into a more natural pace. Myedges are softening.
The six mile back up to the rim and my site was strong medicine. Arrived back at site for an exhausted nap and very light dinner. After dinner I wandered around and vibrated the lingering feelings of fear and loneliness. I have never taken the medicine alone in the wilderness. I feel strong in my intent to break through into another level of seeing tomorrow. no evidence of other people here.
Morning. Just tea at my small fire pit. The pinon/cedar smoke is delicious. I set up the tent for ease of access and napping. Refilled water containers. Then mixed up the henna soup for painting myself. Using the small mirror and a smooth stick I patiently draw the lines, circles and spirals I feel are appropriate on my hands and arms and face. Making the intention real.
By the time the henna has dried and is flaking off it is nearly noon. My skin hlds the designs lightly. The sun is hot but the breeze over the rim is nice and cool. It is time. I remove the medicine (dried mushrooms) from their bag. Line them up on the rug. Breathing deeply I take them one at a time. It is mid-morning to mid day. Although every time I do this it works... I always feel like nothing will happen this time. Weight unknown... a medium handful of stems and caps.
They taste musty-good. I chew then thoroughly, mixing with saliva, and letting the essence enter me first through the membranes under my tongue. Then laying down and breathing deeply. Vibrating the anticipation outward. Staying present.
Then the electric rushes begin to zing through my body and inner ear. I am seeing color tracers and auric rimming. Breathing it all in deeply. At this point the journey takes off and I feel the connection between that-which-is-looking-out-from-within-me and the surround. I move carefully through the desert rock pinon -scape. The silver-dried elder trees reach upward in wild patterns.
Laying in the shade of a wide cedar, I feel the ground shudder and am letting go deeper and deeper into the Earth's frequency. I ask for healing. I intend transcendence of ordinary. I listen deeply. The rock layers shimmer and vibrate. All seems as it really is -totally alive. I walk slowly on being as being.
Later I am laying in the tent, eyes closed, riding the energy washes. Just watching the land from the open door is deeply satisfying. I loose the thread of awareness-continuity here and find myself getting up to walk to find... something... something else. I keep looking to see the non-ordinary. Intending the miraculous.
Then I am laughing at myself. The spaces I see and feel are all familiar. I have been here many times while journeying sans-entheogens. I am pleased that I can get to this state in other ways... And without the buzzy mushy shroom distraction. I thank the ally(s) for the journey and the medicine. I am grateful to Earth, Sky and the shimmering life everywhere.
Later I feel both filled with connection and at the same time empty and quiet as the medicine runs its course. The sunset seems to take days to fade. I don't think about it, I don't analyze (ever notice that analyze is so anal?), I am just breathing being. Sleep comes easily and deeply.
Morning is spent expressing, releasing, and receiving. I intend to open my receiving to glean all that I can from this quest. I see selfishness and addiction to preoccupation in my living. I see that I keep myself so busy I have no space to receive omens, guidance and overview in life. I see I must pause to break the continuity of the ordinary much more often. I receive this medicine. I intend expanded reality. I want communion with my people and deep ongoing connection with Intent. I move with this on the cliff top. I move and vibrate until I feel all this circulating in my body.
Then its under the shade, on the blanket and letting go of limiting beliefs I have had. I change my reality and my path to integrate the seeing from yesterday and the morning. It is well.
Later I break camp and drive home, strong with the desire for this new life.
May the balance be restored.
Experience Reports are the writings and opinions of the individual authors who submit them.
Some of the activities described are dangerous and/or illegal and none are recommended by Erowid.


|
Support Class Library
A set of tools providing classes and utility
|
Files | |
| file | any.h [code] |
| file | atomic.h [code] |
| file | from.h [code] |
| file | make.hpp [code] |
| file | mutexed.h [code] |
| file | optional.h [code] |
| file | promise.h [code] |
| file | ptr.h [code] |
| file | result.h [code] |
| file | shared.h [code] |
| file | unique.h [code] |


{% extends 'base.html' %} {% load static %} {% block sidebar %}
To all marine professionals, programmers, scientists, educators, hobbyists, writers, naturalists, marketers, videographers, students, and lovers of the sea... join us!
{% endblock %} {% block content %}Early-bird tickets are on sale!
Get your tickets for Hack for the Sea 2018 now!For additonal info about tickets, podcasts, travel, and more:
{% include "partials/sign-up-for-mailing-list.html" %}"As a naturalist educator who is not a tech person, I wasn’t sure what I would contribute. As it turned out, this was a wonderful opportunity for people from all sectors to collaborate on ideas that improve the environment.”
- Jessica Kagle, Executive Director, Kestrel Educational Adventures.
"Hack for the Sea brought together ocean experts from the local and national level along with a terrific group of hardware hackers, software engineers, and product designers I can't wait for this year's event.”
- Jim Salem, Director Of Software Development, Oracle Cloud Infrastructure


enum class ReasonPendingTaskSkipped
Reasons why a PendingTask was skipped by the task runner.
interface Visitor<out E>
If you have ever used the Visitor Pattern before in Java/Kotlin, this is for you. |
|
The PendingTask of the app said that it was not ready to run. |
|
|
If a PendingTask runs that has a non-null PendingTask.groupId and it fails running, then all of the other PendingTasks that belongs to the group that have yet to run will all be skipped and rescheduled to run again. |
|
|
If there exists a recorded error for PendingTask. The PendingTask will execute again when Wendy.resolveError is called on the PendingTask. |
abstract fun <E> accept(visitor: Visitor<E>): E
If you have ever used the Visitor Pattern before in Java/Kotlin, this is for you. |


There is no graph here yet. This might have two different reasons:
1. You lack the data to generate this graph. For example you might never have tweeted with geo locations enabled, thus we can't show you your maps or times when you tweet. Or you never replied/retweeted anyone.
2. This graph isn't fully calculated yet. Depending on the size of the Twitter archive the initial graph generation can take a while. But no worries, once that is done they will be loaded instantaneously on subsequent visits. We will send you an email through Open Humans once your graphs have been calculated.


{% load staticfiles %} {% block mobile %}{% endblock %}
Subscribe to the CodeShare newsletter to receive weekly updates from your favorite products.


{% extends 'base.html' %} {% block content %} This is your profile page. Here you will find info about your athlete profile, settings and strava connection!


Skills Bridge
Post a job
Logout
Name:
Jesus
Age:
19
Location:
Taguig
Work Experience:
15 Years
Degree:
BSIT
About me
Modal title
×
...


engaging
Pushing one-way messages at your market only works if anyone is listening.  And besides, who looks at advertising or PR anymore? News flash: No one ever looked at advertising and few ever trusted spin. But people do notice what interests or inspires them. Creating powerful, motivating 'conversations and stories' to engage employees and customers equally is how brands grow from awareness to advocacy.
Research that reveals genuine gaps and opportunities, audience-relevant value propositions, brand stories and design that compel an emotive response, and communications that inspire action are Tenzing's tools of mass and micro disruption. The engagement that happens as a result is the foundation of sales, donations or any other quantitative metric you wish to apply.


This paragraph is strong.
This paragraph is emphasized.
This paragraph is tiny and high.
This paragraph is tiny and low.
This paragraph has a span.


Enigma Test
Can you crack the Engima before the Nazis crash in?
Can you crack the Engima before the Nazis crash in?
A computer would deserve to be called intelligent if it could deceive a human into believing that it was human.
(Press 'Enter' to start)


Equivalent to formatting individual characters in a cell.
Syntax
ACTIVE.CELL.FONT(font, font_style, size, strikethrough, superscript, subscript, outline, shadow, underline, color, normal, background, start_char, char_count)
The arguments for this function are the same as those for FONT.PROPERTIES.
Related Function
FONT.PROPERTIES Applies a font and other attributes to the selection
Return to index


ABOUT ME
Seattle, WA
REASONS I LIKE CODING
It's fun
I can make cool stuff
It's challenging
MY TOP TEN PLACES I WANT TO VISIT
- Frankfurt, Germany
- Paris, France
- Stockholm, Sweden
- New York, USA
- Bristol, England
- Amsterdam, Netherlands
- Reykjyavik, Iceland
- Vancouver, BC
- London, UK
- Bangkok, Thailand
- Tokyo, Japan
- Barcelona, Spain


In this project, you'll use generative adversarial networks to generate new images of faces.
You'll be using two datasets in this project:
Since the celebA dataset is complex and you're doing GANs in a project for the first time, we want you to test your neural network on MNIST before CelebA. Running the GANs on MNIST will allow you to see how well your model trains sooner.
If you're using FloydHub, set data_dir
to "/input" and use the FloydHub data ID "R5KrjnANiKVhLWAkpXhNBe".
data_dir = './data'
# FloydHub - Use with data ID "R5KrjnANiKVhLWAkpXhNBe"
#data_dir = '/input/R5KrjnANiKVhLWAkpXhNBe'
"""
DON'T MODIFY ANYTHING IN THIS CELL
"""
import helper
helper.download_extract('mnist', data_dir)
helper.download_extract('celeba', data_dir)
show_n_images = 25
"""
DON'T MODIFY ANYTHING IN THIS CELL
"""
%matplotlib inline
import os
from glob import glob
from matplotlib import pyplot
mnist_images = helper.get_batch(glob(os.path.join(data_dir, 'mnist/*.jpg'))[:show_n_images], 28, 28, 'L')
pyplot.imshow(helper.images_square_grid(mnist_images, 'L'), cmap='gray')
The CelebFaces Attributes Dataset (CelebA) dataset contains over 200,000 celebrity images with annotations. Since you're going to be generating faces, you won't need the annotations. You can view the first number of examples by changing show_n_images
.
show_n_images = 25
"""
DON'T MODIFY ANYTHING IN THIS CELL
"""
mnist_images = helper.get_batch(glob(os.path.join(data_dir, 'img_align_celeba/*.jpg'))[:show_n_images], 28, 28, 'RGB')
pyplot.imshow(helper.images_square_grid(mnist_images, 'RGB'))
Since the project's main focus is on building the GANs, we'll preprocess the data for you. The values of the MNIST and CelebA dataset will be in the range of -0.5 to 0.5 of 28x28 dimensional images. The CelebA images will be cropped to remove parts of the image that don't include a face, then resized down to 28x28.

You'll build the components necessary to build a GANs by implementing the following functions below:
model_inputs
discriminator
generator
model_loss
model_opt
train
This will check to make sure you have the correct version of TensorFlow and access to a GPU
"""
DON'T MODIFY ANYTHING IN THIS CELL
"""
from distutils.version import LooseVersion
import warnings
import tensorflow as tf
# Check TensorFlow Version
assert LooseVersion(tf.__version__) >= LooseVersion('1.0'), 'Please use TensorFlow version 1.0 or newer. You are using {}'.format(tf.__version__)
print('TensorFlow Version: {}'.format(tf.__version__))
# Check for a GPU
if not tf.test.gpu_device_name():
warnings.warn('No GPU found. Please use a GPU to train your neural network.')
else:
print('Default GPU Device: {}'.format(tf.test.gpu_device_name()))
Implement the model_inputs
function to create TF Placeholders for the Neural Network. It should create the following placeholders:
image_width
, image_height
, and image_channels
.z_dim
.Return the placeholders in the following the tuple (tensor of real input images, tensor of z data)
import problem_unittests as tests
def model_inputs(image_width, image_height, image_channels, z_dim):
"""
Create the model inputs
:param image_width: The input image width
:param image_height: The input image height
:param image_channels: The number of image channels
:param z_dim: The dimension of Z
:return: Tuple of (tensor of real input images, tensor of z data, learning rate)
"""
input_real = tf.placeholder(tf.float32, [None, image_width, image_height, image_channels], "input_real")
input_z = tf.placeholder(tf.float32, [None, z_dim], "input_z")
learning_rate = tf.placeholder(tf.float32, None, "learning_rate")
return input_real, input_z, learning_rate
"""
DON'T MODIFY ANYTHING IN THIS CELL THAT IS BELOW THIS LINE
"""
tests.test_model_inputs(model_inputs)
Implement discriminator
to create a discriminator neural network that discriminates on images
. This function should be able to reuse the variabes in the neural network. Use tf.variable_scope
with a scope name of "discriminator" to allow the variables to be reused. The function should return a tuple of (tensor output of the generator, tensor logits of the generator).
def discriminator(images, reuse=False, alpha=0.01):
"""
Create the discriminator network
:param image: Tensor of input image(s)
:param reuse: Boolean if the weights should be reused
:return: Tuple of (tensor output of the discriminator, tensor logits of the discriminator)
"""
leaky_relu = lambda x: tf.maximum(alpha * x, x)
def conv(inputs, filters, batch_norm=True):
outputs = tf.layers.conv2d(inputs, filters, 5, 2, 'same')
if batch_norm:
outputs = tf.layers.batch_normalization(outputs, training=True)
return leaky_relu(outputs)
with tf.variable_scope("discriminator", reuse=reuse):
# input 28*28*3
x1 = conv(images, 64, batch_norm=False) # 14*14*64
x2 = conv(x1, 128) # 7*7*128
x3 = conv(x2, 256) # 4*4*256
flat = tf.reshape(x3, (-1, 4*4*256))
logits = tf.layers.dense(flat, 1)
out = tf.sigmoid(logits)
return out, logits
"""
DON'T MODIFY ANYTHING IN THIS CELL THAT IS BELOW THIS LINE
"""
tests.test_discriminator(discriminator, tf)
Implement generator
to generate an image using z
. This function should be able to reuse the variabes in the neural network. Use tf.variable_scope
with a scope name of "generator" to allow the variables to be reused. The function should return the generated 28 x 28 x out_channel_dim
images.
def generator(z, out_channel_dim, is_train=True, alpha=0.01):
"""
Create the generator network
:param z: Input z
:param out_channel_dim: The number of channels in the output image
:param is_train: Boolean if generator is being used for training
:return: The tensor output of the generator
"""
leaky_relu = lambda x: tf.maximum(alpha * x, x)
with tf.variable_scope("generator", reuse=not is_train):
x1 = tf.layers.dense(z, 7*7*512)
x1 = tf.reshape(x1, (-1, 7, 7, 512))
x1 = tf.layers.batch_normalization(x1, training=is_train)
x1 = leaky_relu(x1)
# 7*7*512
x2 = tf.layers.conv2d_transpose(x1, 256, 5, 1, 'SAME')
x2 = tf.layers.batch_normalization(x2, training=is_train)
x2 = leaky_relu(x2)
# 7*7*256
x3 = tf.layers.conv2d_transpose(x2, 128, 5, 2, 'SAME')
x3 = tf.layers.batch_normalization(x3, training=is_train)
x3 = leaky_relu(x3)
# 14*14*128
logits = tf.layers.conv2d_transpose(x3, out_channel_dim, 5, 2, 'SAME')
out = tf.tanh(logits)
# 28*28*out_channel_dim
return out
"""
DON'T MODIFY ANYTHING IN THIS CELL THAT IS BELOW THIS LINE
"""
tests.test_generator(generator, tf)
Implement model_loss
to build the GANs for training and calculate the loss. The function should return a tuple of (discriminator loss, generator loss). Use the following functions you implemented:
discriminator(images, reuse=False)
generator(z, out_channel_dim, is_train=True)
def model_loss(input_real, input_z, out_channel_dim, alpha=0.9):
"""
Get the loss for the discriminator and generator
:param input_real: Images from the real dataset
:param input_z: Z input
:param out_channel_dim: The number of channels in the output image
:return: A tuple of (discriminator loss, generator loss)
"""
g_model = generator(input_z, out_channel_dim)
d_model_real, d_logits_real = discriminator(input_real)
d_model_fake, d_logits_fake = discriminator(g_model, reuse=True)
d_loss_real = tf.reduce_mean(
tf.nn.sigmoid_cross_entropy_with_logits(logits=d_logits_real, labels=tf.ones_like(d_logits_real) * alpha))
d_loss_fake = tf.reduce_mean(
tf.nn.sigmoid_cross_entropy_with_logits(logits=d_logits_fake, labels=tf.zeros_like(d_logits_fake)))
g_loss = tf.reduce_mean(
tf.nn.sigmoid_cross_entropy_with_logits(logits=d_logits_fake, labels=tf.ones_like(d_logits_fake)))
d_loss = d_loss_real + d_loss_fake
return d_loss, g_loss
"""
DON'T MODIFY ANYTHING IN THIS CELL THAT IS BELOW THIS LINE
"""
tests.test_model_loss(model_loss)
Implement model_opt
to create the optimization operations for the GANs. Use tf.trainable_variables
to get all the trainable variables. Filter the variables with names that are in the discriminator and generator scope names. The function should return a tuple of (discriminator training operation, generator training operation).
def model_opt(d_loss, g_loss, learning_rate, beta1):
"""
Get optimization operations
:param d_loss: Discriminator loss Tensor
:param g_loss: Generator loss Tensor
:param learning_rate: Learning Rate Placeholder
:param beta1: The exponential decay rate for the 1st moment in the optimizer
:return: A tuple of (discriminator training operation, generator training operation)
"""
update_ops = tf.get_collection(tf.GraphKeys.UPDATE_OPS)
with tf.control_dependencies(update_ops):
t_vars = tf.trainable_variables()
d_vars = [var for var in t_vars if var.name.startswith('discriminator')]
g_vars = [var for var in t_vars if var.name.startswith('generator')]
d_train_opt = tf.train.AdamOptimizer(learning_rate, beta1=beta1).minimize(d_loss, var_list=d_vars)
g_train_opt = tf.train.AdamOptimizer(learning_rate, beta1=beta1).minimize(g_loss, var_list=g_vars)
return d_train_opt, g_train_opt
"""
DON'T MODIFY ANYTHING IN THIS CELL THAT IS BELOW THIS LINE
"""
tests.test_model_opt(model_opt, tf)
"""
DON'T MODIFY ANYTHING IN THIS CELL
"""
import numpy as np
def show_generator_output(sess, n_images, input_z, out_channel_dim, image_mode):
"""
Show example output for the generator
:param sess: TensorFlow session
:param n_images: Number of Images to display
:param input_z: Input Z Tensor
:param out_channel_dim: The number of channels in the output image
:param image_mode: The mode to use for images ("RGB" or "L")
"""
cmap = None if image_mode == 'RGB' else 'gray'
z_dim = input_z.get_shape().as_list()[-1]
example_z = np.random.uniform(-1, 1, size=[n_images, z_dim])
samples = sess.run(
generator(input_z, out_channel_dim, False),
feed_dict={input_z: example_z})
images_grid = helper.images_square_grid(samples, image_mode)
pyplot.imshow(images_grid, cmap=cmap)
pyplot.show()
Implement train
to build and train the GANs. Use the following functions you implemented:
model_inputs(image_width, image_height, image_channels, z_dim)
model_loss(input_real, input_z, out_channel_dim)
model_opt(d_loss, g_loss, learning_rate, beta1)
Use the show_generator_output
to show generator
output while you train. Running show_generator_output
for every batch will drastically increase training time and increase the size of the notebook. It's recommended to print the generator
output every 100 batches.
def train(epoch_count, batch_size, z_dim, learning_rate, beta1, get_batches, data_shape, data_image_mode):
"""
Train the GAN
:param epoch_count: Number of epochs
:param batch_size: Batch Size
:param z_dim: Z dimension
:param learning_rate: Learning Rate
:param beta1: The exponential decay rate for the 1st moment in the optimizer
:param get_batches: Function to get batches
:param data_shape: Shape of the data
:param data_image_mode: The image mode to use for images ("RGB" or "L")
"""
input_real, input_z, lr = model_inputs(data_shape[1], data_shape[2], data_shape[3], z_dim)
d_loss, g_loss = model_loss(input_real, input_z, data_shape[3])
d_opt, g_opt = model_opt(d_loss, g_loss, lr, beta1)
with tf.Session() as sess:
sess.run(tf.global_variables_initializer())
for epoch_i in range(epoch_count):
steps = 0
for batch_images in get_batches(batch_size):
steps +=1
batch_images = batch_images * 2
batch_z = np.random.uniform(-1, 1, size=(batch_size, z_dim))
# Run optimizers
_ = sess.run(d_opt, feed_dict={input_real: batch_images, input_z: batch_z, lr: learning_rate})
_ = sess.run(g_opt, feed_dict={input_real: batch_images, input_z: batch_z, lr: learning_rate})
if steps % 10 == 0:
train_loss_d = d_loss.eval({input_real: batch_images, input_z: batch_z})
train_loss_g = g_loss.eval({input_z: batch_z})
print("Epoch {}/{}...".format(epoch_i+1, epochs),
"Discriminator Loss: {:.4f}...".format(train_loss_d),
"Generator Loss: {:.4f}".format(train_loss_g))
if steps % 100 == 0:
show_generator_output(sess, show_n_images, input_z, data_shape[3], data_image_mode)
Test your GANs architecture on MNIST. After 2 epochs, the GANs should be able to generate images that look like handwritten digits. Make sure the loss of the generator is lower than the loss of the discriminator or close to 0.
batch_size = 128
z_dim = 128
learning_rate = 0.001
beta1 = 0.5
"""
DON'T MODIFY ANYTHING IN THIS CELL THAT IS BELOW THIS LINE
"""
epochs = 2
mnist_dataset = helper.Dataset('mnist', glob(os.path.join(data_dir, 'mnist/*.jpg')))
with tf.Graph().as_default():
train(epochs, batch_size, z_dim, learning_rate, beta1, mnist_dataset.get_batches,
mnist_dataset.shape, mnist_dataset.image_mode)
Run your GANs on CelebA. It will take around 20 minutes on the average GPU to run one epoch. You can run the whole epoch or stop when it starts to generate realistic faces.
batch_size = 64
z_dim = 100
learning_rate = 0.0001
beta1 = 0.5
"""
DON'T MODIFY ANYTHING IN THIS CELL THAT IS BELOW THIS LINE
"""
epochs = 1
celeba_dataset = helper.Dataset('celeba', glob(os.path.join(data_dir, 'img_align_celeba/*.jpg')))
with tf.Graph().as_default():
train(epochs, batch_size, z_dim, learning_rate, beta1, celeba_dataset.get_batches,
celeba_dataset.shape, celeba_dataset.image_mode)
When submitting this project, make sure to run all the cells before saving the notebook. Save the notebook file as "dlnd_face_generation.ipynb" and save it as a HTML file under "File" -> "Download as". Include the "helper.py" and "problem_unittests.py" files in your submission.


TimerState
public enum TimerState
The state of a timer.
-
The state of a timer that is brand new or has just been reset.
Declaration
Swift
case new
-
The state of a timer that has been started and is actively running.
Declaration
Swift
case active
-
The state of a timer that has been stopped and is not running.
Declaration
Swift
case inactive
-
The state of a timer that has reached its duration and is now finished.
Declaration
Swift
case finished


Morning around the house, laundry, cooking, whipping kitchen into shape for company Sunday. Also let Amber sleep since she was up with Cora.
11/15/2008, 11:10:44 AM
Favs: 0
Retweets: 0
link--- layout: tweet ---
Morning around the house, laundry, cooking, whipping kitchen into shape for company Sunday. Also let Amber sleep since she was up with Cora.
11/15/2008, 11:10:44 AM
Favs: 0
Retweets: 0
link


112 When you click on the one-line description of a library, you are shown the actual blocks in the library and a longer explanation of its purpose. You can browse the libraries to ﬁnd one that will satisfy your needs. The libraries are described in detail in Section I.H, page 25. The Costumes… option opens a browser into the costume library: You can import a single costume by clicking it and then clicking the Import button. Alternatively, you can import more than one costume by double-clicking each one, and then clicking Cancel when done. Notice that some costumes are tagged with “svg” in this picture; those are vector-format costumes that are not (yet) editable within Snap ! . If you have the stage selected in the sprite corral, rather than a sprite, the Costumes… option changes to a Backgrounds… option, with different choices in the browser: The costume and background libraries include both bitmap (go jagged if enlarged) and vector (enlarge smoothly) images. Thanks to Scratch 2.0/3.0 for most of these images! Some older browsers refuse to import a vector image, but instead convert it to bitmap.


jQuery Mobile provides a number of icons that can be used by applying a data-icon
attribute to buttons, navbar elements, linked list items and select menus, data-collapsed-icon
and data-expanded-icon
to collapsibles and collapsible-sets, and data-split-icon
to split listviews. The icon name is self-describing. For example, the following will display a button with a home icon:
Home
The following is a full list of the icons provided:
The semi-transparent black circle behind the white icon ensures good contrast on any background color so it works well with the jQuery Mobile theming system. Here are examples of the same icons sitting on top of a range of different color swatches with themed buttons.


Slight oil price rollback
by Edd ReyesOIL firms will implement a slight rollback in pump prices effective today.
Pilipinas Shell, Petron Corporation and Chevron Philippines will cut prices of gasoline products by P0.20 per liter while diesel and kerosene by P0.10 effective at 6 a.m. today.
Independent oil firms PTT Philippines, Phoenix Petroleum, Unioil Philippines, Seaoil Philippines, Eastern Petroleoum, Total Philippines, Petro Gazz and Flying V will also implement the same price adjustments.
Earlier, Cleanfuel rolled back gasoline prices by P0.20 per liter and of diesel by P0.10 which took effect Sunday at 4 p.m.
The Department of Energy (DOE) said the rollback of oil prices reflected the rates in the international oil market.


Eating in Barcelona: Part I http://travel.jasonrclark.com/eating-in-barcelona-part-i/ 😋
7/31/2018, 5:45:53 AM
Favs: 2
Retweets: 0
link--- layout: tweet ---
Eating in Barcelona: Part I http://travel.jasonrclark.com/eating-in-barcelona-part-i/ 😋
7/31/2018, 5:45:53 AM
Favs: 2
Retweets: 0
link


{% extends "main_template.html" %} {% block content %}
Danger! Purging will remove all images and annotations. Are you sure you want to proceed for dataset: EMPTY?
All your stored data will be erased beyond recover. Proceed at your own risk!


Coding Blocks
It is a
long established
and a search for 'lorem ipsum' will uncover many web sites still in their infancy. Various versions have evolved over the years, sometimes by accident, sometimes on purpose (injected humour and the like).
Hello, I am placed.
A


Search a collection of 7,874 betacoronavirus sequences and use facets to filter the results. The sequences were extracted from the NCBI Blast database and the metadata was obtained from the associated INSDC entries.
Search a collection of 7,874 betacoronavirus sequences and use facets to filter the results. The sequences were extracted from the NCBI Blast database and the metadata was obtained from the associated INSDC entries.


func AssertAttributeValue(stub ChaincodeStubInterface, attrName, attrValue string) error
AssertAttributeValue checks to see if an attribute value equals the specified value
func GetAttributeValue(stub ChaincodeStubInterface, attrName string) (value string, found bool, err error)
GetAttributeValue returns value of the specified attribute
func GetID(stub ChaincodeStubInterface) (string, error)
GetID returns the ID associated with the invoking identity. This ID is guaranteed to be unique within the MSP.
func GetMSPID(stub ChaincodeStubInterface) (string, error)
GetMSPID returns the ID of the MSP associated with the identity that submitted the transaction
func GetX509Certificate(stub ChaincodeStubInterface) (*x509.Certificate, error)
GetX509Certificate returns the X509 certificate associated with the client, or nil if it was not identified by an X509 certificate.
ChaincodeStubInterface is used by deployable chaincode apps to get identity of the agent (or user) submitting the transaction.
type ChaincodeStubInterface interface { // GetCreator returns `SignatureHeader.Creator` (e.g. an identity) // of the `SignedProposal`. This is the identity of the agent (or user) // submitting the transaction. GetCreator() ([]byte, error) }
ClientIdentity represents information about the identity that submitted the transaction
type ClientIdentity interface { // GetID returns the ID associated with the invoking identity. This ID // is guaranteed to be unique within the MSP. GetID() (string, error) // Return the MSP ID of the client GetMSPID() (string, error) // GetAttributeValue returns the value of the client's attribute named `attrName`. // If the client possesses the attribute, `found` is true and `value` equals the // value of the attribute. // If the client does not possess the attribute, `found` is false and `value` // equals "". GetAttributeValue(attrName string) (value string, found bool, err error) // AssertAttributeValue verifies that the client has the attribute named `attrName` // with a value of `attrValue`; otherwise, an error is returned. AssertAttributeValue(attrName, attrValue string) error // GetX509Certificate returns the X509 certificate associated with the client, // or nil if it was not identified by an X509 certificate. GetX509Certificate() (*x509.Certificate, error) }
func New(stub ChaincodeStubInterface) (ClientIdentity, error)
New returns an instance of ClientIdentity


BC Aquifer Dashboard
Provincial Overview
search
Legend
District Boundary
Precinct Boundary
Aquifer Vulnerability: Low
Aquifer Vulnerability: Moderate
Aquifer Vulnerability: High
Groundwater Well Type
Licenced
Unlicenced
Observation


This is a demonstration of how a responsive page can be created with simple HTML5/CSS.
The page uses floating DIV elements to structure the content.
The CSS sets a default size for the DIV elements (targeted at large screens on PC/Laptop). The CSS then uses Media Queries to over-write the CSS for smaller screens.
In total, there are 3 media-query over-writes:
- The default is for large screens (which sets a maximum size for the content).
- The first over-ride changes the style to use percentages so the sizes of each area shrink as the screen shrinks.
- The second over-ride changes the style so that the 3 Widgets appear at the top (3 alongside each other), instead of on the right-hand-side.
- The final over-rise changes the style so that everything is serialised in one vertical scrolling page.


HOME
GAMES
Canvas
Unity
Assignment 1
Assignment 2
Assignment 3
Assignment 4
Assignment 5
Project 1
Project 2
EGAME GROUP V2
WebGL 3D Games System
Canvas
Unity
点击任意位置开始游戏
调速:


tufte-css-jekyll is a theme based on tufte-css, which in turn implements the design ideas of Edward Tufte in CSS, and tufte-jekyll (but tries to stick more closely to the original tufte-css styles than the latter).
Note that this is a full-width layout. This was accomplished by including layout: full-width
in the YAML front matter for this page, i.e., no sidenotes or marginnotes!
If you want to know what Tufte style comprises, have a look at the Tufte CSS page.


America's Sweethearts (2001) Reviewed by Eugene Novikov http://www.ultimate-movie.com/
"Word of advice: when you hit formica, stop."
Starring Billy Crystal, John Cusack, Catherine Zeta-Jones, Julia Roberts, Stanley Tucci, Alan Arkin, Christopher Walken. Directed by Joe Roth. Rated PG-13.
America's Sweethearts is what happens when satire gets lazy. We've seen this before, and recently; Scream 3 was plagued by the same demon.  It can also be interesting, as in Mel Brooks's better films, but in this case it's messy and dull. The film exhibits not a delicious sense of irony, but obtuseness.
Pity, because Joe Roth's romantic comedy/would-be Hollywood spoof hits the exact right note with its opening sequence, a montage of scenes from films starring Eddie Thomas (John Cusack) and Gwen Harrison (Catherine Zeta-Jones), "America's Sweethearts." It's perfect because, though exagerrated, it bears an uncanny resemblance to actual movies, tripe like Sweet November, The Bachelor, etc, etc. The films in the montage were hits, but now the real-life couple has undergone a bitter break-up and the fans are despondent.
Unfortunately, they also have a held-over movie coming out, a time travel drama cleverly entitled "Time Over Time." The director (Christopher Walken), an Oscar-winner, but so eccentric that he purchased the unabomber's shack and uses it as his editing room, is holding his work hostage until the press junket, when he will show it for the first time. It's up to big shot publicist Lee Phillips (Billy Crystal) to get both Eddie and Gwen to the junket and, when there, make the press forget about the fact that they haven't seen the actual movie.
Eddie is now at a phoney-baloney self-help resort somewhere in the mountains, with mystic guru Alan Arkin raising his self-esteem by spouting lines like "life is a cookie." Gwen, who initiated the break-up, is sulking at home with her sister/slave Kiki (Julia Roberts), who has lost a lot of weight. What does her losing weight have to do with the plot? Well, she has to be thin so that Eddie can fall in love with her. Duh.
There's good stuff in the first half of America's Sweethearts, including some good Billy Crystal lines and unexpectedly sharp jabs at the inner workings of Hollywood. Then, it becomes some of the sloppiest big-budget filmmaking I have ever seen. The script is just all over the map, with a tonal shift approximately every other scene. The payoff, which comes when we finally get to see the mystery movie, is a complete failure, a decent idea that the filmmakers ruined, making it far less incisive than they apparently think it is.
At that point, though, the movie isn't terribly concerned about being incisive. It had long degenerated into one of the lame romances it was parodying just 40 minutes earlier, with movie-star Eddie falling in love with regular-gal Kiki. Think Notting Hill, only reversed and much less interesting.
I hate movies that gather an amazing cast and then waste it, intent on giving the audience what they think it wants to see those A-list actors do. I don't particularly care whether John and Julia fall for each other, especially not if the film itself doesn't care. I was hoping for sharp satire and biting wit, but America's Sweethearts starts out well and then wimps out.
Grade: C
Up Next: Planet of the Apes
©2001 Eugene Novikov
===== --Eugene Novikov<EMAIL_ADDRESS>"Everyone is entitled to his own opinion but not his own facts." (Daniel Patrick Moynihan)
========== X-RAMR-ID: 29163 X-Language: en X-RT-ReviewID: 243830 X-RT-TitleID: 1108688 X-RT-SourceID: 610 X-RT-AuthorID: 1577 X-RT-RatingText: C
The review above was posted to the
rec.arts.movies.reviews newsgroup (de.rec.film.kritiken for German reviews).
The Internet Movie Database accepts no responsibility for the contents of the
review and has no editorial control. Unless stated otherwise, the copyright
belongs to the author.
Please direct comments/criticisms of the review to relevant newsgroups.
Broken URLs inthe reviews are the responsibility of the author.
The formatting of the review is likely to differ from the original due
to ASCII to HTML conversion.
Related links: index of all rec.arts.movies.reviews reviews


Lets understand related concepts -
The Internet Corporation for Assigned Names and Numbers ( ICANN ) is responsible for managing and coordinating the Domain Name System ( DNS ) to ensure that every address is unique and that all users of the Internet can find all valid addresses.
Click »Routing is the process of selecting a path for traffic in a network or between or across multiple networks. Broadly, routing is performed in many types of networks, including circuit-switched networks, such as the public switched telephone network, and computer networks, such as the Internet
Click »The Domain Name System is a hierarchical and decentralized naming system for computers, services, or other resources connected to the Internet or a private network. It associates various information with domain names assigned to each of the participating entities.
Hypertext Transfer Protocol Secure is an extension of the Hypertext Transfer Protocol. It is used for secure communication over a computer network, and is widely used on the Internet. In HTTPS, the communication protocol is encrypted using Transport Layer Security or, formerly, Secure Sockets Layer.
The World Wide Web Consortium (W3C) is an international community where Member organizations, a full-time staff, and the public work together to develop Web standards. Led by Web inventor and Director Tim Berners-Lee and CEO Jeffrey Jaffe, W3C's mission is to lead the Web to its full potential.


| 1 | package fr.sii.ogham.core.sender; | |
| 2 | ||
| 3 | import static fr.sii.ogham.core.util.LogUtils.summarize; | |
| 4 | ||
| 5 | import java.util.ArrayList; | |
| 6 | import java.util.Arrays; | |
| 7 | import java.util.List; | |
| 8 | ||
| 9 | import org.slf4j.Logger; | |
| 10 | import org.slf4j.LoggerFactory; | |
| 11 | ||
| 12 | import fr.sii.ogham.core.exception.MessageException; | |
| 13 | import fr.sii.ogham.core.exception.MessageNotSentException; | |
| 14 | import fr.sii.ogham.core.exception.MultipleCauseExceptionWrapper; | |
| 15 | import fr.sii.ogham.core.message.Message; | |
| 16 | ||
| 17 | /** | |
| 18 | * Decorator implementation that will try to send the message until one | |
| 19 | * decorated sender is able to send it. The aim is that if a sender fails to | |
| 20 | * send the message, then another will send it. It can ensure that message will | |
| 21 | * be sent at any costs. | |
| 22 | * | |
| 23 | * @author Aurélien Baudet | |
| 24 | * | |
| 25 | */ | |
| 26 | public class FallbackSender implements MessageSender { | |
| 27 | private static final Logger LOG = LoggerFactory.getLogger(FallbackSender.class); | |
| 28 | ||
| 29 | /** | |
| 30 | * The list of senders to try one by one until one succeeds | |
| 31 | */ | |
| 32 | private List<MessageSender> senders; | |
| 33 | ||
| 34 | /** | |
| 35 | * Initialize either none, one or several senders to try one by one until | |
| 36 | * one succeeds. | |
| 37 | * | |
| 38 | * @param senders | |
| 39 | * the senders to register | |
| 40 | */ | |
| 41 | public FallbackSender(MessageSender... senders) { | |
| 42 | this(Arrays.asList(senders)); | |
| 43 | } | |
| 44 | ||
| 45 | /** | |
| 46 | * Initialize with the provided list of senders to try one by one until one | |
| 47 | * succeeds. | |
| 48 | * | |
| 49 | * @param senders | |
| 50 | * the senders to register | |
| 51 | */ | |
| 52 | public FallbackSender(List<MessageSender> senders) { | |
| 53 | super(); | |
| 54 | this.senders = senders; | |
| 55 | } | |
| 56 | ||
| 57 | @Override | |
| 58 | @SuppressWarnings("squid:S2221") | |
| 59 | public void send(Message message) throws MessageException { | |
| 60 |
2
1. send : All method instructions removed → NO_COVERAGE 2. send : All method instructions removed → KILLED |
List<Exception> causes = new ArrayList<>(); |
| 61 | for (MessageSender sender : senders) { | |
| 62 | try { | |
| 63 | LOG.debug("Try to send message {} using sender {}", summarize(message), sender); | |
| 64 | sender.send(message); | |
| 65 | LOG.debug("Message {} sent using sender {}", summarize(message), sender); | |
| 66 | return; | |
| 67 | } catch (Exception e) { | |
| 68 | LOG.debug("Message {} couldn't be sent using sender {}. Cause: {}", summarize(message), sender, e.getMessage()); | |
| 69 | LOG.trace("", e); | |
| 70 | causes.add(e); | |
| 71 | } | |
| 72 | } | |
| 73 | throw new MessageNotSentException("No sender could handle the message", message, new MultipleCauseExceptionWrapper(causes)); | |
| 74 | } | |
| 75 | ||
| 76 | /** | |
| 77 | * Register a new sender to try. The sender is added at the end. It will be | |
| 78 | * used only after all previously registered senders have failed. | |
| 79 | * | |
| 80 | * @param sender | |
| 81 | * the sender to register | |
| 82 | */ | |
| 83 | public void addSender(MessageSender sender) { | |
| 84 |
1
1. addSender : All method instructions removed → NO_COVERAGE |
senders.add(sender); |
| 85 | } | |
| 86 | } | |
Mutations | ||
| 60 |
1.1 2.2 |
|
| 84 |
1.1 |


{% block head %}
ECG Heartbeat Categorization Dataset and Smart Health for Assessing the Risk of Events via ECG.


|
Hold
Me
(Savage Garden) |
|
Hey
If we can't find a way out of these problems Then maybe we don't need this Standing face to face Enemies at war we build defenses And secret hiding places I might need you to hold me tonight I might need you to say it's alright I might need you to make the first stand Because tonight I'm finding it hard to be your man Hey More than angry words I hate this silence It's getting so loud Well I want to scream But bitterness has silenced these emotions Iit's getting hard to breathe So tell me isn't happiness Worth more than a golden diamond ring? I'm willing to do anything To calm the storm in my heart I've never been the praying kind But lately I've been down upon my knees Not looking for a miracle Just a reason to believe I might need you to hold me tonight I might need you to say it's alright I might need you to make the first stand Because tonight I'm finding it hard to be your man Do you remember not long ago? When we used to live for the nighttime Cherish each moment Now we don't live we exist We just run through our lives So alone That's why you've got to hold me Hey If we can't find a way out of these problems Then maybe we don't need this Standing face to face Enemies at war we build defenses And secret hiding places I might need you to hold me tonight I might need you to say it's alright I might need you to make the first stand Because tonight I'm finding it hard to be your man |


I'm a pretty experienced drug user, having tried many substances in my life, especially hallucinogenics. However, up until this point I had never laid a hand on mushrooms. When I got a call from my dude Ryan saying he had shrooms, I immediately scrounged up $35 and went over to his place to buy an 8th. It was my good friends birthday, and I wanted to make the experience all the more special with mushrooms.
I arrived at my fraternity house where the party was taking place, and ate the entire 8th. I had read many reports of nausea and general discomfort associated with taking mushrooms, but I never experienced any of these symptoms. They tasted sort of foul, but I just washed them down with a can of grape soda, which eliminated the bad taste pretty effectively.
I stood around, socialized, and waited anxiously for the mushrooms to kick in. Nothing really happened for about an hour. At our house, we have a dance room with a colorful disco ball style light hanging from our ceiling, and the first thing I noticed was that the lights were trailing a little bit, and the colors seemed very prominent and beautiful, moreso than normal. I then proceeded to walk into the kitchen, and that was when I knew the mushrooms had hit me full force.
Our refridgerator is an industrial sized one that is made of a shiny metal material, I want to say chrome but I'm not quite sure. Regardless of that, I stared at the fridge, fascinated by the way the light reflected off of it. It seemed to take on a whole new level of depth an intrigue.  People would open the fridge to grab their drinks and what not, but I would yell at them for 'interrupting the continuity of the fantastic appliance'. One of my friends asked me what I was tripping on (I have a reputation as the resident druggie), and that's when I realized the mushrooms had hit me full on.
   A wave of fear and discomfort overcame me, and I isolated myself from everyone else in the attic. As soon as I was away from everyone else, I suddenly felt much calmer and at ease.
I layed down on a mattress, and stared at the wall. I immediately noticed all sorts of psychadellic patterns, similar to the stoner artwork you've probably seen all over the internet. Before I never really understood how someone could come up with those intricate, beautiful and detailed patterns, but after taking mushrooms I sure as hell understand! Anyways I stared at the ceiling for about a half hour. At this point my emotions took hold and I once again became very scared and uncomfortable, and decided I needed to talk to a close friend.
At this point I went back downstairs into the kitchen, where a large group of people were standing around talking. I went up to them, interrupted the conversation, and started talking philosophy (I am a philosophy + mathematics student). I was mainly discussing the ideas in Ludwig Wittgenstein's 'Tractatus Logico-Philosophicus', and although I'm pretty sure nobody understood what I was talking about, it all made sense to me.
One thing I noticed about mushrooms is that they make me become very introspective and philosophical. I came to so many deep, philosophical conclusions about life and the unierse on mushrooms! I basically had an existentialist epitome: mushrooms really helped me realize that life is essentially pointless, that there is no God, and that it's my duty to rebel against this pointlessness, to create my own purpose in life. Basically everything Albert Camus wrote in the Myth of Sisyphus, I realized while tripping on shrooms.
The night went on, and I continued to have all sorts of fantastic visuals and amazing philosophical + mathematical epitomes. I think the one mistake I made with mushrooms was the fact I chose a social party setting to take them in. Mushrooms are an extremely introspective drug, and although I feel I should have a sitter at all times to watch me and make sure I don't do something stupid, it's definetly not something I want to do in a party or social environment. Next time Iíll use them in a private setting with a few close friends. I can most definetly say I will definetly eat shrooms before I attempt to write any sort of philosophical masterpiece!
Experience Reports are the writings and opinions of the individual authors who submit them.
Some of the activities described are dangerous and/or illegal and none are recommended by Erowid.


Duchess of York praises ‘steadfast’ Andrew ahead of Epstein interview
She said that ‘it is so rare to meet people that are able to speak from their hearts with honesty and pure real truth’.
Sarah, Duchess of York, has hailed her “stoically steadfast” ex-husband, the Duke of York, ahead of an interview due to be aired on Saturday about his relationship with paedophile Jeffrey Epstein.
In a BBC interview, Andrew will face questions about his links to the disgraced financier, who was found dead in his New York prison cell earlier this year, where he was being held on sex trafficking charges.
Writing on Twitter on Friday night, Sarah said: “It is so rare to meet people that are able to speak from their hearts with honesty and pure real truth, that remain steadfast and strong to their beliefs.
“Andrew is a true and real gentleman and is stoically steadfast to not only his duty, but also his kindness and goodness.”
She posted the message alongside four pictures of her former husband, and father to her two daughters, Princesses Beatrice and Eugenie.
The pair were married for 10 years between 1986 and 1996.
An accuser of Epstein claims she was forced into a sexual encounter with Andrew when she was 17 years old, an allegation he denies.
Virginia Giuffre, formerly known as Virginia Roberts, is one of 16 women who says she was abused by Epstein, and also named Andrew in previous court papers.
Her allegations were struck from US civil court records in 2015 after a judge said they were “immaterial”.
Buckingham Palace has branded the allegations “false and without any foundation” and added “any suggestion of impropriety with underage minors” by the Andrew was “categorically untrue”.
The full interview, recorded at Buckingham Palace on Thursday, will air on a BBC Newsnight special on Saturday evening, BBC Two at 9pm.


Install OSX
19 Apr 2015Upgraded home desktop with fresh install of OSX 10.9.5 Mavericks.
- Motherboard is GA-Z77X-UP5-TH
- BIOS is F12
- Followed Tonymac post by Stork
- Wrok motherboard is: (GA-Z97M-D3H)[https://www.gigabyte.com/Motherboard/GA-Z97M-D3H-rev-10#ov]
Analysis
- Igor
- Fiji
- Using ‘Fiji Life-Line version, 2014 November 25’.
- Fiji will not run until setting: Security & Privacy -> Allow apps downloaded from: Anywhere
- Installing Java SE 6
Development
Synchronization
Utility
- TextWrangler
- iStat Menus
- Unarchiver - Handles .xz, .exe
Word processing and layout
- iWork
- Adobe Illustrator CS6
- Adobe reader (for digital signatures)
Web
- Stock install of Safari
- Chrome
Media
Torrent
Remote desktop connection to Raspberry Pi
myjhu VPN (This is the part that is always FUCKING IMPOSSIBLE)
- [FUCK IT, IT IS NOT MY JOB TO DOCUMENT SOFTWARE THAT DOES NOT WORK AND IS MANAGED BY INCOMPETENT AND OVERPAID TWITS]
- Start by going here
- https://jhpulse.johnshopkins.edu.
- Forces install of Java 8u45
- https://www.java.com/en/download/mac_download.jsp
- jre-8u45-macosx-x64.dmg
- Install Junos Pulse (twice)
- Requires manual setting of Safari security
- Complete bullshit amateur hack job


29 August 2002
Disease Outbreak Reported
As of 22 August, the Ministry of Health has reported a total of 591 cases including 8 deaths (case-fatality rate, 1.35%) in Bujumbura since the outbreak began on 17 June 2002 (see previous report). In Bubanza province the Ministry of Health has reported 46 cases including 3 deaths (case-fatality rate, 6.52%) from 5-30 July and 157 cases including 2 deaths (case-fatality rate, 1.27%) in Cibitoke province from 2 July to 11 August.
The United Nations Office for the Coordination of Humanitarian Affairs (OCHA), is working with the Ministry of Health and nongovenrmental organizations to coordinate the response.


THE HOUSE OF YES (1997) A Film Review by Ted Prigge Copyright 1998 Ted Prigge
Director: Mark Waters Writer: Mark Waters (based on the play by Wendy MacLeod) Starring: Parker Posey, Josh Hamilton, Tori Spelling, Freddie Prinze Jr, Geneviève Bujold, Rachel Leigh Cook, David Love
The boyfriend brings his fiance home to meet his disfunctional family...how many times have we seen this set-up? In "The House of Yes," this is what happens, only the film throws us a couple weird pitches, keeping us off guard and generally freaking us out like no film bearing this cliche has in recent memory. For one, they're all much weirder, and for another one, one of his family members...well, thinks she's Jackie Onassis. Instead of being just a cheap comedy, it has become a cheap, elongated "Tales From the Crypt" episode.
The film opens by introducing the whole "Jackie Onassis" obsession, which inhibits the one daughter (Parker Posey, making her 97 rounds in indie/art house films) in the family, who goes by "Jackie-O," but whether her name really is Jackie, we never discover. In the opening credits, we see her as a young child in the early 70s being filmed doing an impersonation of Jackie Onassis, complete with the pink dress and pill box hat. We later discover that the obsession with Jackie Onassis is a result of the disappearance of their father on the day Kennedy was assasinated. Okay...
The real plot of the film deals with, as I said, the one brother, Marty (Josh Hamilton), bringing home his perky fiance, Lesly (Tori Spelling - yes, you read correctly), to meet his family, who live in a giant mansion in D.C. There, she meets his family members: his freaky mother (Geneviève Bujold, who I thought was dead), a reclusive bizarre nut; his dorky and clueless brother, Anthony (Freddie Prinze Jr., who played the boring boyfriend in "I Know What You Did Last Summer"); and...Jackie-O, who is infactuated with him so much that when she hears of the engagement, she screams and runs off to comb her hair.
Taking place on Thanksgiving night, we are introduced to one weird evening where the disfunctions of the family take off, and some extremely weird things and facts are introduced. Anthony finds he lusts after Lesly, and begins to comfort her as the evening goes on...in his own blunt way (which means trying to get her to talk to him in what he thinks is "Girl Talk"). And we discover that Jackie-O is: a) totally insane (duh!), b) just got back from the hospital, and c) had sex with Marty when they were kids and still holds a torch for him.
This is pretty much all the film is, and that becomes a big problem because we discover that the only thing this film has to offer is some really weird things, like incest and obsessions with Jackie Onassis. "The House of Yes" has nothing much to offer in terms of characterization, depth, even some kind of message (although I guess the message of this film is...families are weird). So what it does is pull out as many controversial jokes as it can, intending to shock the audience into appreaciating the film.
This is what's wrong with the film. Because it doesn't have the guts to go any deeper with the themes and ideas it introduces, it becomes shallow and pretty much redundant. By the ending, you're just hoping that the film will suddenly perk up, dive deep into what we saw before, and expand on them. It doesn't. Everything introduced is pretty much just a contrivance to freak us out; I mean, why exactly did the writer chose Jackie Onassis to be the obsession if the film is never going to do anything with it but stage an addmittingly humorous enactment of the assasination?
But granted, the film has many strong points that kinda save it. For one, there are some really great one-liners and exchanges, even if the script isn't all that great. The acting is also pretty good, with all the actors doing good jobs (Freddie Prinze Jr is a terrible actor, but his bad acting works with the character for some reason, and Tori Spelling finds all the right notes for her part). One of the biggest shocks for me was to see Geneviève Bujold, who has pretty much been floundering since the late 70s. She gives a pretty incredible and comical performance.
But the real star of the show is Parker Posey, who does what has to be the best acting of her short yet lengthy career thus far. She goes completely over the top with her performance, and watching her do her schtick is one of the real pleasures of watching this film. If any performance would define Posey as an actress and make her a star, it's this.
It's too bad she wasn't in a better film, as "The House of Yes" is a really disappointing little film. It has some great ideas and all, but the fact that it never does a thing with them (probably because the writer wanted it to be really short) is what becomes wrong with this film. I will say this though: the film is pretty comical, and yes, I laughed several times throughout it. And the film held my attention the whole time, which is something to be commended. Of course, the flip-side of that is I was waiting for something to really happen.
MY RATING (out of 4): **
Homepage at: http://www.geocities.com/Hollywood/Hills/8335/
The review above was posted to the
rec.arts.movies.reviews newsgroup (de.rec.film.kritiken for German reviews).
The Internet Movie Database accepts no responsibility for the contents of the
review and has no editorial control. Unless stated otherwise, the copyright
belongs to the author.
Please direct comments/criticisms of the review to relevant newsgroups.
Broken URLs inthe reviews are the responsibility of the author.
The formatting of the review is likely to differ from the original due
to ASCII to HTML conversion.
Related links: index of all rec.arts.movies.reviews reviews


| Class and Description |
|---|
| BoxFilesManagerImpl |
| Class and Description |
|---|
| AbstractBoxResourceManager
Base class for BoxAPI classes.
|
| BoxItemsManagerImpl
Use this class to execute requests synchronously against the Box REST API(V2).
|
| IBoxCollaborationsManager |
| IBoxCommentsManager |
| IBoxEventsManager |
| IBoxFilesManager |
| IBoxFoldersManager |
| IBoxGroupsManager |
| IBoxItemsManager |
| IBoxOAuthManager |
| IBoxResourceManager |
| IBoxSearchManager |
| IBoxSharedItemsManager |
| IBoxTrashManager |
| IBoxUsersManager |
| Class and Description |
|---|
| AbstractBoxResourceManager
Base class for BoxAPI classes.
|
| BoxOAuthManagerImpl
API for OAuth.
|
| IBoxOAuthManager |
| IBoxResourceManager |


Enter below the name of the product you want to search:
Search:
Add another product
Search for a product
Go back to Home Page


Package livebrush
Class LiveBrushManager
- java.lang.Object
-
- livebrush.LiveBrushManager
-
public class LiveBrushManager extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description java.lang.String
absoluteSourceFolderPath
int
activeLiveBrushIndex
(package private) processing.core.PApplet
applet
java.util.ArrayList<LiveBrush>
liveBrushes
java.util.ArrayList<LiveBrushInstance>
liveBrushInstances
-
Constructor Summary
Constructors Constructor Description LiveBrushManager(processing.core.PApplet applet)
LiveBrushManager(processing.core.PApplet applet, java.lang.String absoluteSourceFolderPath)
LiveBrushManager(processing.core.PApplet applet, java.lang.String absoluteSourceFolderPath, int refreshDelay)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(processing.core.PVector origin)
Adds a LiveBrush instance at the given positionprivate void
addLiveBrushInstance(processing.core.PVector origin)
Adds a LiveBrush instance at the given positionvoid
clear()
Clears the LiveBrushManager of all the LiveBrush instancesprivate void
clearLiveBrushInstances()
Clears the LiveBrushManager of all the LiveBrush instancesvoid
create(java.lang.String name)
Creates a new Java source document in the LiveBrush folderprivate void
createLiveBrushDocument(java.lang.String name)
Creates a new Java source document in the LiveBrush folderprivate void
createLiveBrushDocumentWithRandomName()
Creates a new Java source document in the LiveBrush folder with a random namevoid
draw()
Draws all the LiveBrush instances in the managerprivate void
drawActiveLiveBrush(processing.core.PVector origin)
Draws the active LiveBrush without creating a LiveBrush instanceprivate void
drawLiveBrushInstances()
Draws all the LiveBrush instances in the managervoid
edit()
Opens a system editor to edit the current livebrushprivate void
editActiveLiveBrush()
Opens a system editor to edit the current livebrushprivate LiveBrush
getActiveLiveBrush(int activeLiveBrushIndex)
Retrieves the active LiveBrushprivate java.util.ArrayList<LiveBrush>
getLiveBrushesFromExternalSource()
Parses LiveBrush objects from external source filesvoid
openFolder()
Opens the system folder containing the LiveBrush source filesprivate void
openLiveBrushFolder()
Opens the system folder containing the LiveBrush source filesvoid
preview(processing.core.PVector origin)
Draws the active LiveBrush without creating a LiveBrush instancevoid
selectNext()
Selects the next LiveBrush classprivate void
selectNextLiveBrush()
Selects the next LiveBrush classvoid
selectPrevious()
Selects the previous LiveBrush classvoid
selectPreviousLiveBrush()
Selects the previous LiveBrush classprivate void
setFileChangeListener(java.lang.String absoluteSourceFolderPath, int refreshDelay)
Sets the listener for LiveBrush source file changesprivate void
updateLiveBrushInstances(java.util.ArrayList<LiveBrush> liveBrushes)
Updates the LiveBrush instances
-
-
-
Field Detail
-
applet
processing.core.PApplet applet
-
absoluteSourceFolderPath
public java.lang.String absoluteSourceFolderPath
-
liveBrushes
public java.util.ArrayList<LiveBrush> liveBrushes
-
liveBrushInstances
public java.util.ArrayList<LiveBrushInstance> liveBrushInstances
-
activeLiveBrushIndex
public int activeLiveBrushIndex
-
-
Constructor Detail
-
LiveBrushManager
public LiveBrushManager(processing.core.PApplet applet, java.lang.String absoluteSourceFolderPath)
-
LiveBrushManager
public LiveBrushManager(processing.core.PApplet applet, java.lang.String absoluteSourceFolderPath, int refreshDelay)
-
LiveBrushManager
public LiveBrushManager(processing.core.PApplet applet)
-
-
Method Detail
-
draw
public void draw()
Draws all the LiveBrush instances in the manager- Parameters:
applet
- The sketch as a PApplet
-
create
public void create(java.lang.String name)
Creates a new Java source document in the LiveBrush folder- Parameters:
name
- The name of the new document
-
preview
public void preview(processing.core.PVector origin)
Draws the active LiveBrush without creating a LiveBrush instance- Parameters:
applet
- The sketch as a PAppletorigin
- The origin point of the preview
-
add
public void add(processing.core.PVector origin)
Adds a LiveBrush instance at the given position- Parameters:
origin
- The origin point of the instance
-
edit
public void edit()
Opens a system editor to edit the current livebrush
-
clear
public void clear()
Clears the LiveBrushManager of all the LiveBrush instances
-
openFolder
public void openFolder()
Opens the system folder containing the LiveBrush source files
-
selectNext
public void selectNext()
Selects the next LiveBrush class
-
selectPrevious
public void selectPrevious()
Selects the previous LiveBrush class
-
openLiveBrushFolder
private void openLiveBrushFolder()
Opens the system folder containing the LiveBrush source files
-
createLiveBrushDocumentWithRandomName
private void createLiveBrushDocumentWithRandomName()
Creates a new Java source document in the LiveBrush folder with a random name
-
createLiveBrushDocument
private void createLiveBrushDocument(java.lang.String name)
Creates a new Java source document in the LiveBrush folder- Parameters:
name
- The name of the new document
-
editActiveLiveBrush
private void editActiveLiveBrush()
Opens a system editor to edit the current livebrush
-
clearLiveBrushInstances
private void clearLiveBrushInstances()
Clears the LiveBrushManager of all the LiveBrush instances
-
drawActiveLiveBrush
private void drawActiveLiveBrush(processing.core.PVector origin)
Draws the active LiveBrush without creating a LiveBrush instance- Parameters:
applet
- The sketch as a PAppletorigin
- The origin of the instance
-
drawLiveBrushInstances
private void drawLiveBrushInstances()
Draws all the LiveBrush instances in the manager- Parameters:
applet
- The sketch as a PApplet
-
addLiveBrushInstance
private void addLiveBrushInstance(processing.core.PVector origin)
Adds a LiveBrush instance at the given position- Parameters:
origin
- The origin of the instance
-
selectNextLiveBrush
private void selectNextLiveBrush()
Selects the next LiveBrush class
-
selectPreviousLiveBrush
public void selectPreviousLiveBrush()
Selects the previous LiveBrush class
-
setFileChangeListener
private void setFileChangeListener(java.lang.String absoluteSourceFolderPath, int refreshDelay)
Sets the listener for LiveBrush source file changes- Parameters:
absoluteSourceFolderPath
- The filepath to the LiveBrush source folderrefreshDelay
- The frequency time to check for file changes
-
getLiveBrushesFromExternalSource
private java.util.ArrayList<LiveBrush> getLiveBrushesFromExternalSource()
Parses LiveBrush objects from external source files- Returns:
- A list of LiveBrush objects
-
getActiveLiveBrush
private LiveBrush getActiveLiveBrush(int activeLiveBrushIndex)
Retrieves the active LiveBrush- Parameters:
activeLiveBrushIndex
- The index of the active LiveBrush- Returns:
- The active LiveBrush
-
updateLiveBrushInstances
private void updateLiveBrushInstances(java.util.ArrayList<LiveBrush> liveBrushes)
Updates the LiveBrush instances- Parameters:
liveBrushes
- A list of LiveBrushes
-
-


In this study, you will be presented with 3 images of potential products for the new Bus-Mall magazine.Simply click on the product you like most. After 25 rounds, a chart will appear showing the total results.Click the 'Begin' Button whenever you are ready. Thank you!


Key: C Db D Eb E F Gb G Ab A Bb B
Tempo: ← →
Volume: ← →
Progression:
Clear – Presets – Hallelujah Hips Don't Lie Style Canon in D Wake Me Up When... I Get Around
Chords can end with < or > for inversions.
<
>
PLAY STOP
Detected Modes: ?


# Authors: Nicolas Goix<EMAIL_ADDRESS># Alexandre Gramfort<EMAIL_ADDRESS># License: BSD 3 clause
from __future__ import division
import numpy as np
import scipy as sp
from warnings import warn
from sklearn.utils.fixes import euler_gamma
from scipy.sparse import issparse
import numbers
from ..externals import six
from ..tree import ExtraTreeRegressor
from ..utils import check_random_state, check_array
from .bagging import BaseBagging
__all__ = ["IsolationForest"]
INTEGER_TYPES = (numbers.Integral, np.integer)
class IsolationForest(BaseBagging):
"""Isolation Forest Algorithm
Return the anomaly score of each sample using the IsolationForest algorithm
The IsolationForest 'isolates' observations by randomly selecting a feature
and then randomly selecting a split value between the maximum and minimum
values of the selected feature.
Since recursive partitioning can be represented by a tree structure, the
number of splittings required to isolate a sample is equivalent to the path
length from the root node to the terminating node.
This path length, averaged over a forest of such random trees, is a
measure of normality and our decision function.
Random partitioning produces noticeably shorter paths for anomalies.
Hence, when a forest of random trees collectively produce shorter path
lengths for particular samples, they are highly likely to be anomalies.
Read more in the :ref:`User Guide <isolation_forest>`.
.. versionadded:: 0.18
Parameters
----------
n_estimators : int, optional (default=100)
The number of base estimators in the ensemble.
max_samples : int or float, optional (default="auto")
The number of samples to draw from X to train each base estimator.
- If int, then draw `max_samples` samples.
- If float, then draw `max_samples * X.shape[0]` samples.
- If "auto", then `max_samples=min(256, n_samples)`.
If max_samples is larger than the number of samples provided,
all samples will be used for all trees (no sampling).
contamination : float in (0., 0.5), optional (default=0.1)
The amount of contamination of the data set, i.e. the proportion
of outliers in the data set. Used when fitting to define the threshold
on the decision function.
max_features : int or float, optional (default=1.0)
The number of features to draw from X to train each base estimator.
- If int, then draw `max_features` features.
- If float, then draw `max_features * X.shape[1]` features.
bootstrap : boolean, optional (default=False)
If True, individual trees are fit on random subsets of the training
data sampled with replacement. If False, sampling without replacement
is performed.
n_jobs : integer, optional (default=1)
The number of jobs to run in parallel for both `fit` and `predict`.
If -1, then the number of jobs is set to the number of cores.
random_state : int, RandomState instance or None, optional (default=None)
If int, random_state is the seed used by the random number generator;
If RandomState instance, random_state is the random number generator;
If None, the random number generator is the RandomState instance used
by `np.random`.
verbose : int, optional (default=0)
Controls the verbosity of the tree building process.
Attributes
----------
estimators_ : list of DecisionTreeClassifier
The collection of fitted sub-estimators.
estimators_samples_ : list of arrays
The subset of drawn samples (i.e., the in-bag samples) for each base
estimator.
max_samples_ : integer
The actual number of samples
References
----------
.. [1] Liu, Fei Tony, Ting, Kai Ming and Zhou, Zhi-Hua. "Isolation forest."
Data Mining, 2008. ICDM'08. Eighth IEEE International Conference on.
.. [2] Liu, Fei Tony, Ting, Kai Ming and Zhou, Zhi-Hua. "Isolation-based
anomaly detection." ACM Transactions on Knowledge Discovery from
Data (TKDD) 6.1 (2012): 3.
"""
def __init__(self,
n_estimators=100,
max_samples="auto",
contamination=0.1,
max_features=1.,
bootstrap=False,
n_jobs=1,
random_state=None,
verbose=0):
super(IsolationForest, self).__init__(
base_estimator=ExtraTreeRegressor(
max_features=1,
splitter='random',
random_state=random_state),
# here above max_features has no links with self.max_features
bootstrap=bootstrap,
bootstrap_features=False,
n_estimators=n_estimators,
max_samples=max_samples,
max_features=max_features,
n_jobs=n_jobs,
random_state=random_state,
verbose=verbose)
self.contamination = contamination
def _set_oob_score(self, X, y):
raise NotImplementedError("OOB score not supported by iforest")
[docs] def fit(self, X, y=None, sample_weight=None):
"""Fit estimator.
Parameters
----------
X : array-like or sparse matrix, shape (n_samples, n_features)
The input samples. Use ``dtype=np.float32`` for maximum
efficiency. Sparse matrices are also supported, use sparse
``csc_matrix`` for maximum efficiency.
sample_weight : array-like, shape = [n_samples] or None
Sample weights. If None, then samples are equally weighted.
Returns
-------
self : object
Returns self.
"""
X = check_array(X, accept_sparse=['csc'])
if issparse(X):
# Pre-sort indices to avoid that each individual tree of the
# ensemble sorts the indices.
X.sort_indices()
rnd = check_random_state(self.random_state)
y = rnd.uniform(size=X.shape[0])
# ensure that max_sample is in [1, n_samples]:
n_samples = X.shape[0]
if isinstance(self.max_samples, six.string_types):
if self.max_samples == 'auto':
max_samples = min(256, n_samples)
else:
raise ValueError('max_samples (%s) is not supported.'
'Valid choices are: "auto", int or'
'float' % self.max_samples)
elif isinstance(self.max_samples, INTEGER_TYPES):
if self.max_samples > n_samples:
warn("max_samples (%s) is greater than the "
"total number of samples (%s). max_samples "
"will be set to n_samples for estimation."
% (self.max_samples, n_samples))
max_samples = n_samples
else:
max_samples = self.max_samples
else: # float
if not (0. < self.max_samples <= 1.):
raise ValueError("max_samples must be in (0, 1], got %r"
% self.max_samples)
max_samples = int(self.max_samples * X.shape[0])
self.max_samples_ = max_samples
max_depth = int(np.ceil(np.log2(max(max_samples, 2))))
super(IsolationForest, self)._fit(X, y, max_samples,
max_depth=max_depth,
sample_weight=sample_weight)
self.threshold_ = -sp.stats.scoreatpercentile(
-self.decision_function(X), 100. * (1. - self.contamination))
return self
[docs] def predict(self, X):
"""Predict if a particular sample is an outlier or not.
Parameters
----------
X : array-like or sparse matrix, shape (n_samples, n_features)
The input samples. Internally, it will be converted to
``dtype=np.float32`` and if a sparse matrix is provided
to a sparse ``csr_matrix``.
Returns
-------
is_inlier : array, shape (n_samples,)
For each observations, tells whether or not (+1 or -1) it should
be considered as an inlier according to the fitted model.
"""
X = check_array(X, accept_sparse='csr')
is_inlier = np.ones(X.shape[0], dtype=int)
is_inlier[self.decision_function(X) <= self.threshold_] = -1
return is_inlier
[docs] def decision_function(self, X):
"""Average anomaly score of X of the base classifiers.
The anomaly score of an input sample is computed as
the mean anomaly score of the trees in the forest.
The measure of normality of an observation given a tree is the depth
of the leaf containing this observation, which is equivalent to
the number of splittings required to isolate this point. In case of
several observations n_left in the leaf, the average path length of
a n_left samples isolation tree is added.
Parameters
----------
X : {array-like, sparse matrix}, shape (n_samples, n_features)
The training input samples. Sparse matrices are accepted only if
they are supported by the base estimator.
Returns
-------
scores : array of shape (n_samples,)
The anomaly score of the input samples.
The lower, the more abnormal.
"""
# code structure from ForestClassifier/predict_proba
# Check data
X = check_array(X, accept_sparse='csr')
n_samples = X.shape[0]
n_samples_leaf = np.zeros((n_samples, self.n_estimators), order="f")
depths = np.zeros((n_samples, self.n_estimators), order="f")
if self._max_features == X.shape[1]:
subsample_features = False
else:
subsample_features = True
for i, (tree, features) in enumerate(zip(self.estimators_,
self.estimators_features_)):
if subsample_features:
X_subset = X[:, features]
else:
X_subset = X
leaves_index = tree.apply(X_subset)
node_indicator = tree.decision_path(X_subset)
n_samples_leaf[:, i] = tree.tree_.n_node_samples[leaves_index]
depths[:, i] = np.ravel(node_indicator.sum(axis=1))
depths[:, i] -= 1
depths += _average_path_length(n_samples_leaf)
scores = 2 ** (-depths.mean(axis=1) / _average_path_length(self.max_samples_))
# Take the opposite of the scores as bigger is better (here less
# abnormal) and add 0.5 (this value plays a special role as described
# in the original paper) to give a sense to scores = 0:
return 0.5 - scores
def _average_path_length(n_samples_leaf):
""" The average path length in a n_samples iTree, which is equal to
the average path length of an unsuccessful BST search since the
latter has the same structure as an isolation tree.
Parameters
----------
n_samples_leaf : array-like of shape (n_samples, n_estimators), or int.
The number of training samples in each test sample leaf, for
each estimators.
Returns
-------
average_path_length : array, same shape as n_samples_leaf
"""
if isinstance(n_samples_leaf, INTEGER_TYPES):
if n_samples_leaf <= 1:
return 1.
else:
return 2. * (np.log(n_samples_leaf - 1.) + euler_gamma) - 2. * (
n_samples_leaf - 1.) / n_samples_leaf
else:
n_samples_leaf_shape = n_samples_leaf.shape
n_samples_leaf = n_samples_leaf.reshape((1, -1))
average_path_length = np.zeros(n_samples_leaf.shape)
mask = (n_samples_leaf <= 1)
not_mask = np.logical_not(mask)
average_path_length[mask] = 1.
average_path_length[not_mask] = 2. * (
np.log(n_samples_leaf[not_mask] - 1.) + euler_gamma) - 2. * (
n_samples_leaf[not_mask] - 1.) / n_samples_leaf[not_mask]
return average_path_length.reshape(n_samples_leaf_shape)


A Practical Guide to Broadcast State in Apache Flink
June 26, 2019 - Fabian Hueske (@fhueske)Since version 1.5.0, Apache Flink features a new type of state which is called Broadcast State. In this post, we explain what Broadcast State is, and show an example of how it can be applied to an application that evaluates dynamic patterns on an event stream. We walk you through the processing steps and the source code to implement this application in practice.
What is Broadcast State? #
The Broadcast State can be used to combine and jointly process two streams of events in a specific way. The events of the first stream are broadcasted to all parallel instances of an operator, which maintains them as state. The events of the other stream are not broadcasted but sent to individual instances of the same operator and processed together with the events of the broadcasted stream. The new broadcast state is a natural fit for applications that need to join a low-throughput and a high-throughput stream or need to dynamically update their processing logic. We will use a concrete example of the latter use case to explain the broadcast state and show its API in more detail in the remainder of this post.
Dynamic Pattern Evaluation with Broadcast State #
Imagine an e-commerce website that captures the interactions of all users as a stream of user actions. The company that operates the website is interested in analyzing the interactions to increase revenue, improve the user experience, and detect and prevent malicious behavior. The website implements a streaming application that detects a pattern on the stream of user events. However, the company wants to avoid modifying and redeploying the application every time the pattern changes. Instead, the application ingests a second stream of patterns and updates its active pattern when it receives a new pattern from the pattern stream. In the following, we discuss this application step-by-step and show how it leverages the broadcast state feature in Apache Flink.
Our example application ingests two data streams. The first stream provides user actions on the website and is illustrated on the top left side of the above figure. A user interaction event consists of the type of the action (user login, user logout, add to cart, or complete payment) and the id of the user, which is encoded by color. The user action event stream in our illustration contains a logout action of User 1001 followed by a payment-complete event for User 1003, and an “add-to-cart” action of User 1002.
The second stream provides action patterns that the application will evaluate. A pattern consists of two consecutive actions. In the figure above, the pattern stream contains the following two:
- Pattern #1: A user logs in and immediately logs out without browsing additional pages on the e-commerce website.
- Pattern #2: A user adds an item to the shopping cart and logs out without completing the purchase.
Such patterns help a business in better analyzing user behavior, detecting malicious actions, and improving the website experience. For example, in the case of items being added to a shopping cart with no follow up purchase, the website team can take appropriate actions to understand better the reasons why users don’t complete a purchase and initiate specific programs to improve the website conversion (such as providing discount codes, limited free shipping offers etc.)
On the right-hand side, the figure shows three parallel tasks of an operator that ingest the pattern and user action streams, evaluate the patterns on the action stream, and emit pattern matches downstream. For the sake of simplicity, the operator in our example only evaluates a single pattern with exactly two subsequent actions. The currently active pattern is replaced when a new pattern is received from the pattern stream. In principle, the operator could also be implemented to evaluate more complex patterns or multiple patterns concurrently which could be individually added or removed.
We will describe how the pattern matching application processes the user action and pattern streams.
First a pattern is sent to the operator. The pattern is broadcasted to all three parallel tasks of the operator. The tasks store the pattern in their broadcast state. Since the broadcast state should only be updated using broadcasted data, the state of all tasks is always expected to be the same.
Next, the first user actions are partitioned on the user id and shipped to the operator tasks. The partitioning ensures that all actions of the same user are processed by the same task. The figure above shows the state of the application after the first pattern and the first three action events were consumed by the operator tasks.
When a task receives a new user action, it evaluates the currently active pattern by looking at the user’s latest and previous actions. For each user, the operator stores the previous action in the keyed state. Since the tasks in the figure above only received a single action for each user so far (we just started the application), the pattern does not need to be evaluated. Finally, the previous action in the user’s keyed state is updated to the latest action, to be able to look it up when the next action of the same user arrives.
After the first three actions are processed, the next event, the logout action of User 1001, is shipped to the task that processes the events of User 1001. When the task receives the actions, it looks up the current pattern from the broadcast state and the previous action of User 1001. Since the pattern matches both actions, the task emits a pattern match event. Finally, the task updates its keyed state by overriding the previous event with the latest action.
When a new pattern arrives in the pattern stream, it is broadcasted to all tasks and each task updates its broadcast state by replacing the current pattern with the new one.
Once the broadcast state is updated with a new pattern, the matching logic continues as before, i.e., user action events are partitioned by key and evaluated by the responsible task.
How to Implement an Application with Broadcast State? #
Until now, we conceptually discussed the application and explained how it uses broadcast state to evaluate dynamic patterns over event streams. Next, we’ll show how to implement the example application with Flink’s DataStream API and the broadcast state feature.
Let’s start with the input data of the application. We have two data streams, actions, and patterns. At this point, we don’t really care where the streams come from. The streams could be ingested from Apache Kafka or Kinesis or any other system. Action and Pattern are Pojos with two fields each:
DataStream<Action> actions = ???
DataStream<Pattern> patterns = ???
Action
and Pattern
are Pojos with two fields each:
-
Action: Long userId, String action
-
Pattern: String firstAction, String secondAction
As a first step, we key the action stream on the userId
attribute.
KeyedStream<Action, Long> actionsByUser = actions
.keyBy((KeySelector<Action, Long>) action -> action.userId);
Next, we prepare the broadcast state. Broadcast state is always represented as MapState
, the most versatile state primitive that Flink provides.
MapStateDescriptor<Void, Pattern> bcStateDescriptor =
new MapStateDescriptor<>("patterns", Types.VOID, Types.POJO(Pattern.class));
Since our application only evaluates and stores a single Pattern
at a time, we configure the broadcast state as a MapState
with key type Void
and value type Pattern
. The Pattern
is always stored in the MapState
with null
as key.
BroadcastStream<Pattern> bcedPatterns = patterns.broadcast(bcStateDescriptor);
Using the MapStateDescriptor
for the broadcast state, we apply the broadcast()
transformation on the patterns stream and receive a BroadcastStream bcedPatterns
.
DataStream<Tuple2<Long, Pattern>> matches = actionsByUser
.connect(bcedPatterns)
.process(new PatternEvaluator());
After we obtained the keyed actionsByUser
stream and the broadcasted bcedPatterns
stream, we connect()
both streams and apply a PatternEvaluator
on the connected streams. PatternEvaluator
is a custom function that implements the KeyedBroadcastProcessFunction
interface. It applies the pattern matching logic that we discussed before and emits Tuple2<Long, Pattern>
records which contain the user id and the matched pattern.
public static class PatternEvaluator
extends KeyedBroadcastProcessFunction<Long, Action, Pattern, Tuple2<Long, Pattern>> {
// handle for keyed state (per user)
ValueState<String> prevActionState;
// broadcast state descriptor
MapStateDescriptor<Void, Pattern> patternDesc;
@Override
public void open(Configuration conf) {
// initialize keyed state
prevActionState = getRuntimeContext().getState(
new ValueStateDescriptor<>("lastAction", Types.STRING));
patternDesc =
new MapStateDescriptor<>("patterns", Types.VOID, Types.POJO(Pattern.class));
}
/**
* Called for each user action.
* Evaluates the current pattern against the previous and
* current action of the user.
*/
@Override
public void processElement(
Action action,
ReadOnlyContext ctx,
Collector<Tuple2<Long, Pattern>> out) throws Exception {
// get current pattern from broadcast state
Pattern pattern = ctx
.getBroadcastState(this.patternDesc)
// access MapState with null as VOID default value
.get(null);
// get previous action of current user from keyed state
String prevAction = prevActionState.value();
if (pattern != null && prevAction != null) {
// user had an action before, check if pattern matches
if (pattern.firstAction.equals(prevAction) &&
pattern.secondAction.equals(action.action)) {
// MATCH
out.collect(new Tuple2<>(ctx.getCurrentKey(), pattern));
}
}
// update keyed state and remember action for next pattern evaluation
prevActionState.update(action.action);
}
/**
* Called for each new pattern.
* Overwrites the current pattern with the new pattern.
*/
@Override
public void processBroadcastElement(
Pattern pattern,
Context ctx,
Collector<Tuple2<Long, Pattern>> out) throws Exception {
// store the new pattern by updating the broadcast state
BroadcastState<Void, Pattern> bcState = ctx.getBroadcastState(patternDesc);
// storing in MapState with null as VOID default value
bcState.put(null, pattern);
}
}
The KeyedBroadcastProcessFunction
interface provides three methods to process records and emit results.
processBroadcastElement()
is called for each record of the broadcasted stream. In ourPatternEvaluator
function, we simply put the receivedPattern
record in to the broadcast state using thenull
key (remember, we only store a single pattern in theMapState
).processElement()
is called for each record of the keyed stream. It provides read-only access to the broadcast state to prevent modification that result in different broadcast states across the parallel instances of the function. TheprocessElement()
method of thePatternEvaluator
retrieves the current pattern from the broadcast state and the previous action of the user from the keyed state. If both are present, it checks whether the previous and current action match with the pattern and emits a pattern match record if that is the case. Finally, it updates the keyed state to the current user action.onTimer()
is called when a previously registered timer fires. Timers can be registered in theprocessElement
method and are used to perform computations or to clean up state in the future. We did not implement this method in our example to keep the code concise. However, it could be used to remove the last action of a user when the user was not active for a certain period of time to avoid growing state due to inactive users.
You might have noticed the context objects of the KeyedBroadcastProcessFunction
’s processing method. The context objects give access to additional functionality such as:
- The broadcast state (read-write or read-only, depending on the method),
- A
TimerService
, which gives access to the record’s timestamp, the current watermark, and which can register timers, - The current key (only available in
processElement()
), and - A method to apply a function the keyed state of each registered key (only available in
processBroadcastElement()
)
The KeyedBroadcastProcessFunction
has full access to Flink state and time features just like any other ProcessFunction and hence can be used to implement sophisticated application logic. Broadcast state was designed to be a versatile feature that adapts to different scenarios and use cases. Although we only discussed a fairly simple and restricted application, you can use broadcast state in many ways to implement the requirements of your application.
Conclusion #
In this blog post, we walked you through an example application to explain what Apache Flink’s broadcast state is and how it can be used to evaluate dynamic patterns on event streams. We’ve also discussed the API and showed the source code of our example application.
We invite you to check the documentation of this feature and provide feedback or suggestions for further improvements through our mailing list.


DW Sivers Company is a second- and third-generation family business with a more than 60 year history in Portland, Oregon’s commercial real estate industry. We are proud to be a women-owned business with a majority of stock held by women active in the company operations and management. We are also proud to be majority employee-owned, boasting a small team of financial, construction, operations, development and property management professionals with an average tenure measured in decades rather than years.
DW Sivers Company has maintained our strength and reputation over time through an emphasis on strong business relationships, prudent financial management, integrity and careful selection of projects. Rather than focusing on explosive growth or a high profile, the Sivers team strives for quality and long term stability, maintaining a company in a community that can continue to thrive for generations to come.