--- title: 'WNBL advanced stats: Points per possession' author: Jacquie Tran date: '2021-12-02' slug: wnbl-points-per-possession categories: - On-field analyses tags: - women's sport - basketball - sports analytics - r stats ---
On Tuesday, I launched the alpha version of the wnblr
package, yahoooo!! (Guess I better write a blog post about that sometime.) wnblr
currently contains live stats recorded from WNBL games played from 2014 to 2020, inclusive. You can find it here: https://github.com/jacquietran/wnblr
Over on Twitter, I flagged down Paul Flynn (Assistant Coach, Melbourne Boomers WNBL) to take a look-see, and he asked for some specific advanced stats that can be derived from the standard game stats that are typically recorded (e.g., box score stats like points scored, number of rebounds, and so on):
Would be keen to view any data on points per possession, pace and correlating eFG% over the same period.
— Paul Flynn (@paulflynn611) December 1, 2021
First cab off the rank: points per possession.
(Don’t worry, coach: I’ll get to the other metrics in due course!)
Load up the libraries we need. The wnblr
package currently includes 4 built-in data sets with various game statistics. For this analysis, we’re going to use the box_scores
data which is recorded at the team-level.
# Install the development version of {wnblr} from Github
# remotes::install_github("jacquietran/wnblr")
# Load libraries
library(wnblr) # for retrieving WNBL game stats
library(dplyr) # for tidying data
library(tidyr) # for tidying data
library(gt) # for making data tables
library(showtext) # for loading custom fonts for plots
library(ggplot2) # for plotting
library(ggbeeswarm) # for plotting
library(ggtext) # for formatting text in ggplot2 objects
The points per possession metric is what it says on the tin: the number of points that a team scores per possession. Higher values are better. Values over 1 mean that a team has managed to score at least 1 point for each possession, which would come about from giving up fewer turnovers and having fewer missed shots that are rebounded by the opposition.
Per NBAStuffer.com, points per possession is calculated as follows:
Points per possession = PTS / (FGA + (0.44 * FTA) + TO)
(Where: PTS = Total points scored; FGA = Field goals attempted; FTA = Free throws attempted; TO = Turnovers)
With the 2021 WNBL season kicking off this weekend, it might be worth looking at how teams performed on the points_per_possession
metric in the 2020 regular season.
# Subset to games in the 2020 season -------------------------------------------
points_per_possession %>%
filter(season == 2020) %>%
# Exclude finals games
filter(!page_id %in% c(
"1809808", "1809807", "1809809", "1809810")
) -> ppp_2020
# Calculate summary stats ------------------------------------------------------
ppp_2020 %>%
group_by(team_name) %>%
summarise(
points_per_possession_mean = round(
mean(points_per_possession), 3),
points_per_possession_sd = round(
sd(points_per_possession), 3),
points_per_possession_sd_lower = points_per_possession_mean -
points_per_possession_sd,
points_per_possession_sd_higher = points_per_possession_mean +
points_per_possession_sd) %>%
ungroup() -> ppp_2020_summarised
We can get a sense of which teams typically had high or low scoring efficiency by looking at whole-season summary stats. The table below shows each team’s mean (i.e., averages) and standard deviation (SD) for points per possession.
# Present summary stats in a table ---------------------------------------------
ppp_2020_summarised %>%
select(team_name, points_per_possession_mean, points_per_possession_sd) %>%
arrange(desc(points_per_possession_mean)) %>%
# Rename columns for human readability
rename(
Team = team_name,
Mean = points_per_possession_mean,
SD = points_per_possession_sd) %>%
gt() %>%
data_color(
columns = "Mean",
colors = scales::col_numeric(
palette = c("#ffeec2", "#ee6f00"),
domain = c(min(Mean), max(Mean)))) %>%
data_color(
columns = "SD",
colors = scales::col_numeric(
palette = c("#b6d8ff", "#3090ff"),
domain = c(min(SD), max(SD)))) %>%
tab_spanner(
label = "Points per possession",
columns = c(Mean, SD)) %>%
tab_source_note(
source_note = md(
"**Data source:** {wnblr} R package and WNBL.com.au | **Table:** @jacquietran")
) %>%
tab_options(
table.width = pct(70))
| Team | Points per possession | |
|---|---|---|
| Mean | SD | |
| Southside Flyers | 1.057 | 0.117 |
| Townsville Fire | 0.935 | 0.118 |
| Melbourne Boomers | 0.866 | 0.120 |
| UC Capitals | 0.865 | 0.117 |
| Adelaide Lightning | 0.794 | 0.114 |
| Perth Lynx | 0.793 | 0.142 |
| Sydney Uni Flames | 0.760 | 0.120 |
| Bendigo Spirit | 0.716 | 0.123 |
| Data source: {wnblr} R package and WNBL.com.au | Table: @jacquietran |
In the 2020 regular season, the Southside Flyers were far and away the most efficient scoring team, in terms of converting possessions to points. They were the only team to average over 1 point per possession across the season (although Townsville got close).
Summary stats are useful, but their very nature is blunt: condensing team performance across multiple games into a singular numbers. So…why not have both?
# Merge per-game stats with summary stats
left_join(ppp_2020, ppp_2020_summarised,
by = "team_name") %>%
# Create a column for labelling means
mutate(
ppp_mean_label = format(
points_per_possession_mean, nsmall = 3)) %>%
# Set order of factor levels in team_name
mutate(
team_name = factor(
team_name, levels = c(
"Bendigo Spirit",
"Sydney Uni Flames",
"Perth Lynx",
"Adelaide Lightning",
"UC Capitals",
"Melbourne Boomers",
"Townsville Fire",
"Southside Flyers"))) -> ppp_2020_tidy
With the summary stats and per game stats merged, we can visualise points per possession for each team and each game played in the 2020 season, alongside each team’s mean and standard deviation values for points per possession.
# Set custom elements up -------------------------------------------------------
# Import Google Fonts
font_add_google(name = "Exo 2", family = "exo")
font_add_google(name = "Fira Sans Extra Condensed", family = "firacondensed")
# Set palette for fill based on uniform colours
team_pal_fill <- c(
"Southside Flyers" = "#53bae7",
"Townsville Fire" = "#ed771f",
"Melbourne Boomers" = "#3f0b5d",
"UC Capitals" = "#00b5e2",
"Adelaide Lightning" = "#f64e99",
"Perth Lynx" = "#fe0000",
"Sydney Uni Flames" = "#1c2a59",
"Bendigo Spirit" = "#2a6dfc")
# Set palette for colour based on uniform colours
team_pal_colour <- c(
"Southside Flyers" = "#FFFFFF",
"Townsville Fire" = "#000000",
"Melbourne Boomers" = "#f4ee20",
"UC Capitals" = "#000000",
"Adelaide Lightning" = "#0e1f4a",
"Perth Lynx" = "#000000",
"Sydney Uni Flames" = "#fbc549",
"Bendigo Spirit" = "#ffc438")
# Build plot -------------------------------------------------------------------
showtext_auto()
p <- ggplot(
ppp_2020_tidy,
aes(x = points_per_possession, y = team_name,
colour = team_name, fill = team_name))
p <- p + geom_jitter(
height = 0.2, shape = 21, alpha = 0.5, size = 7, stroke = 1)
p <- p + geom_linerange(
aes(xmin = points_per_possession_sd_lower,
xmax = points_per_possession_sd_higher),
colour = "#FFFFFF", size = 1, linetype = "dotted")
p <- p + geom_point(
aes(x = points_per_possession_mean, y = team_name),
colour = "#FFFFFF", shape = 10, size = 6, stroke = 1.5)
p <- p + geom_text(
aes(x = points_per_possession_mean, y = team_name,
label = ppp_mean_label),
hjust = -0.3, vjust = -0.4, colour = "#000000", fontface = "bold",
size = 12, family = "firacondensed", alpha = 0.2)
p <- p + geom_text(
aes(x = points_per_possession_mean, y = team_name,
label = ppp_mean_label),
hjust = -0.25, vjust = -0.5, colour = "#FFFFFF", fontface = "bold",
size = 12, family = "firacondensed")
p <- p + scale_x_continuous(
limits = c(0.5, 1.3),
breaks = seq(0.6, 1.2, by = 0.2))
p <- p + scale_fill_manual(values = team_pal_fill)
p <- p + scale_colour_manual(values = team_pal_colour)
p <- p + labs(
title = "Off to a Flyer in the 2020 WNBL season",
subtitle = "Filled points = per-game values. Cross hairs = season averages. Dotted lines = ±1SD.",
x = NULL, y = NULL,
caption = "**Data source:** {wnblr} & WNBL.com.au | **Plot:** @jacquietran")
p <- p + ggdark::dark_mode()
p <- p + theme(
text = element_text(
size = 48, family = "firacondensed", colour = "#FFFFFF"),
plot.title = element_text(
size = 48, family = "exo", face = "bold"),
plot.subtitle = element_text(
size = 28, family = "firacondensed", margin=margin(0,0,15,0)),
plot.caption = element_markdown(size = NULL, margin=margin(15,0,0,0)),
axis.text = element_text(colour = "#FFFFFF"),
plot.margin = unit(c(0.5,0.5,0.5,0.5), "cm"),
legend.position = "none")
plot_ppp_2020 <- p
# Display plot
# showtext_auto(FALSE) is run after the plot has been displayed
plot_ppp_2020
We get more of the story when we combine per-game numbers and season averages for each team. A few things that I noticed from plotting points per possession:


Collection of electronic and mechanical devices operating as a unit. The main parts are:
The system unit is the main container for system devices. It protects delicate electronic and mechanical devices from damage. Typical system unit devices include:
Peripherals are devices that connect to the system unit using cables or wireless techonologies. Typical peripherals include:
An integrated circuit (IC) supplied on a single silicon chip. Its function is to control all the computer's functions. The main processor manufactures are:
Primary Memory - Main computer memory. Data, programs currently in use are held in RAM.
Volatile - contents of memory are lost if the computer is turned off.
Mainboard or System Board - the main circuit board for the computer system. All devices in the computer system will either be part of the motherboar or connected to it.
A computer power supply has a number of functions:
Computer ports are interfaces between peripheral devices and the computer. They are mainly found at the back of the computer but are often also built into the front of the computer chassis for easy access.


| Module | ActiveScaffold::Actions::Nested |
| In: |
vendor/plugins/active_scaffold/lib/actions/nested.rb
|
The Nested module basically handles automatically linking controllers together. It does this by creating column links with the right parameters, and by providing any supporting systems (like a /:controller/nested action for returning associated scaffolds).


#include <vecmath.h>
Public Member Functions | |
| Matrix3 () | |
| Default constructor. | |
| Matrix3 (Real f11, Real f21, Real f31, Real f12, Real f22, Real f32, Real f13, Real f23, Real f33) | |
| Constructor with given component value. | |
| Real & | operator() (Int Col, Int Row) |
| Access grants operator. | |
| Real | operator() (Int Col, Int Row) const |
| Access grants operator. | |
| operator Real * () | |
| Casting operator. | |
| operator const Real * () const | |
| Casting operator. | |
| Matrix3 & | operator+= (const Matrix3 &tm) |
| Addition assignment operator. | |
| Matrix3 & | operator-= (const Matrix3 &tm) |
| Subtraction assignment operator. | |
| Matrix3 & | operator *= (const Matrix3 &tm) |
| Multiplication assignment operator. | |
| Matrix3 & | operator *= (Real f) |
| Multiplication assignment operator. | |
| Matrix3 & | operator/= (Real f) |
| Division assignment operator. | |
| Matrix3 | operator+ () const |
| Unary plus operator. | |
| Matrix3 | operator- () const |
| Unary negation operator. | |
| Matrix3 | operator+ (const Matrix3 &tm) const |
| Binary addition operator. | |
| Matrix3 | operator- (const Matrix3 &tm) const |
| Binary subtraction operator. | |
| Matrix3 | operator * (const Matrix3 &tm) const |
| Binary multiplication operator. | |
| Matrix3 | operator * (Real f) const |
| Binary multiplication operator. | |
| Matrix3 | operator/ (Real f) const |
| Binary division operator. | |
| Bool | operator== (const Matrix3 &tm) const |
| Equality comparison operator. | |
| Bool | operator!= (const Matrix3 &tm) const |
| Inequality comparison operator. | |
| Matrix3< Real > & | Matrix3Transpose () |
| Transposes the matrix. | |
| Matrix3< Real > & | NoTranslation () |
| Zeros the translation portion of matrix. | |
Public Attributes | |
| Real | _11 |
| Matrix element (first digit - column's number, second digit - row's number). | |
| Real | _21 |
| Matrix element (first digit - column's number, second digit - row's number). | |
| Real | _31 |
| Matrix element (first digit - column's number, second digit - row's number). | |
| Real | _12 |
| Matrix element (first digit - column's number, second digit - row's number). | |
| Real | _22 |
| Matrix element (first digit - column's number, second digit - row's number). | |
| Real | _32 |
| Matrix element (first digit - column's number, second digit - row's number). | |
| Real | _13 |
| Matrix element (first digit - column's number, second digit - row's number). | |
| Real | _23 |
| Matrix element (first digit - column's number, second digit - row's number). | |
| Real | _33 |
| Matrix element (first digit - column's number, second digit - row's number). | |
Related Functions | |
| (Note that these are not member functions.) | |
| Matrix3< Real > | operator * (Real f, const Matrix3< Real > &tm) |
| Binary multiplication operator. | |
| void | ZeroMatrix3 (Matrix3< Real > &tm) |
| Zeros all elements of matrix. | |
| Matrix3< Real > | ZeroMatrix3 () |
| Creates Zero matrix (all elements = 0). | |
| void | IdentityMatrix3 (Matrix3< Real > &tm) |
| Set matrix to the Identity matrix. | |
| Matrix3< Real > | IdentityMatrix3 () |
| Creates Identity matrix. | |
| Matrix3< Real > & | Matrix3Multiply (Matrix3< Real > &result, const Matrix3< Real > &a, const Matrix3< Real > &b) |
| Performs full multiplication of two matrices. | |
| Matrix3< Real > | Matrix3Multiply (const Matrix3< Real > &a, const Matrix3< Real > &b) |
| Performs full multiplication of two matrices. | |
| Matrix3< Real > & | Matrix3MultiplyFast (Matrix3< Real > &result, const Matrix3< Real > &a, const Matrix3< Real > &b) |
| Performs fast multiplication of two matrices. | |
| Matrix3< Real > | Matrix3MultiplyFast (const Matrix3< Real > &a, const Matrix3< Real > &b) |
| Performs fast multiplication of two matrices. | |
| Matrix3< Real > & | Matrix3Transpose (Matrix3< Real > &result, const Matrix3< Real > &tm) |
| Transposes the matrix. | |
| Matrix3< Real > | Matrix3Transpose (const Matrix3< Real > &tm) |
| Transposes the matrix. | |
| Matrix3< Real > | RotationMatrix3 (Real rads) |
| Creates rotation matrix from angle in 2D. | |
| Matrix3< Real > | TranslationMatrix3 (Real dx, Real dy) |
| Creates translation matrix in 2D. | |
| Matrix3< Real > | TranslationMatrix3 (const Vector2< Real > &v) |
| Creates translation matrix in 2D. | |
| Matrix3< Real > & | NoTranslation (Matrix3< Real > &result, const Matrix3< Real > &tm) |
| Zeros the translation portion of matrix. | |
| Matrix3< Real > | NoTranslation (const Matrix3< Real > &tm) |
| Zeros the translation portion of matrix. | |
| Vector2< Real > | GetTranslation (const Matrix3< Real > &tm) |
| Creates translation vector from transformation matrix. | |
| Matrix3< Real > | ScalingMatrix3 (Real size) |
| Creates uniform scaling matrix. | |
| Matrix3< Real > | ScalingMatrix3 (Real a, Real b) |
| Creates scaling matrix. | |
| Matrix3< Real > | ScalingMatrix3 (const Vector2< Real > &v) |
| Creates scaling matrix. |
The content of matrix is in column-major order.
| 'Real' | parameter defines matrix components numeric type. |
|
|
Constructor with given component value.
|
|
|
Transposes the matrix.
|
|
|
Zeros the translation portion of matrix.
|
|
|
Access grants operator.
|
|
|
Access grants operator.
|
|
|
Creates translation vector from transformation matrix.
|
|
|
Creates Identity matrix.
|
|
|
Set matrix to the Identity matrix.
|
|
|
Performs full multiplication of two matrices.
|
|
|
Performs full multiplication of two matrices.
|
|
|
Performs fast multiplication of two matrices. This function doesn't multiply zero portion of matrices (_31,_32 elements) in optimization purposes.
|
|
|
Performs fast multiplication of two matrices. This function doesn't multiply zero portion of matrices (_31,_32 elements) in optimization purposes.
|
|
|
Transposes the matrix.
|
|
|
Transposes the matrix.
|
|
|
Zeros the translation portion of matrix.
|
|
|
Zeros the translation portion of matrix.
|
|
|
Creates rotation matrix from angle in 2D.
|
|
|
Creates scaling matrix.
|
|
|
Creates scaling matrix.
|
|
|
Creates uniform scaling matrix.
|
|
|
Creates translation matrix in 2D.
|
|
|
Creates translation matrix in 2D.
|
|
|
Creates Zero matrix (all elements = 0).
|
|
|
Zeros all elements of matrix.
|


Item.
When done changing the voice rate, press TAB to move forward through the dialog box. SHIFT + TAB will move back through the dialog box if needed.
When done changing the voice rate, press TAB to move forward through the dialog box. SHIFT + TAB will move back through the dialog box if needed.


Enhances standard form elements like buttons, inputs and anchors to themeable buttons with appropriate hover and active styles.
Widget Buttons
CSS Buttons
Button Styles
Icon Buttons
Select Menu
Enable a DOM element (or group of elements) to be selectable. Draw a box with your cursor to select items. Hold down the Ctrl key to make multiple non-adjacent selections
Examples
Examples
Checkbox & Radio Buttons
Enhances standard checkbox and radio input element to themeable buttons with appropriate hover and active styles.


--- title: "Utilities" description: |
Evolution UI provides a list of helpers for text which can be applied through
the evo_h-txt--[modifier]
helper class.
Default font-family
Bold
Italic
Caps
Align text to the left
Align text to the center
Align text to the right
capitalize
uppercase
LOWERCASE
underline
Text no wrap


Digit Recognition on MNIST
In this tutorial, we will work through examples of training a simple multi-layer perceptron and then a convolutional neural network (the LeNet architecture) on the MNIST handwritten digit dataset. The code for this tutorial could be found in examples/mnist. There are also two Jupyter notebooks that expand a little more on the MLP and the LeNet, using the more general ArrayDataProvider
.
Simple 3-layer MLP
This is a tiny 3-layer MLP that could be easily trained on CPU. The script starts with
using MXNet
to load the MXNet
module. Then we are ready to define the network architecture via the symbolic API. We start with a placeholder data
symbol,
data = mx.Variable(:data)
and then cascading fully-connected layers and activation functions:
fc1 = mx.FullyConnected(data, name=:fc1, num_hidden=128)
act1 = mx.Activation(fc1, name=:relu1, act_type=:relu)
fc2 = mx.FullyConnected(act1, name=:fc2, num_hidden=64)
act2 = mx.Activation(fc2, name=:relu2, act_type=:relu)
fc3 = mx.FullyConnected(act2, name=:fc3, num_hidden=10)
Note each composition we take the previous symbol as the first argument, forming a feedforward chain. The architecture looks like
Input --> 128 units (ReLU) --> 64 units (ReLU) --> 10 units
where the last 10 units correspond to the 10 output classes (digits 0,...,9). We then add a final SoftmaxOutput
operation to turn the 10-dimensional prediction to proper probability values for the 10 classes:
mlp = mx.SoftmaxOutput(fc3, name=:softmax)
As we can see, the MLP is just a chain of layers. For this case, we can also use the mx.chain
macro. The same architecture above can be defined as
mlp = @mx.chain mx.Variable(:data) =>
mx.FullyConnected(name=:fc1, num_hidden=128) =>
mx.Activation(name=:relu1, act_type=:relu) =>
mx.FullyConnected(name=:fc2, num_hidden=64) =>
mx.Activation(name=:relu2, act_type=:relu) =>
mx.FullyConnected(name=:fc3, num_hidden=10) =>
mx.SoftmaxOutput(name=:softmax)
After defining the architecture, we are ready to load the MNIST data. MXNet.jl provide built-in data providers for the MNIST dataset, which could automatically download the dataset into Pkg.dir("MXNet")/data/mnist
if necessary. We wrap the code to construct the data provider into mnist-data.jl
so that it could be shared by both the MLP example and the LeNet ConvNets example.
batch_size = 100
include("mnist-data.jl")
train_provider, eval_provider = get_mnist_providers(batch_size)
If you need to write your own data providers for customized data format, please refer to mx.AbstractDataProvider
.
Given the architecture and data, we can instantiate an model to do the actual training. mx.FeedForward
is the built-in model that is suitable for most feed-forward architectures. When constructing the model, we also specify the context on which the computation should be carried out. Because this is a really tiny MLP, we will just run on a single CPU device.
model = mx.FeedForward(mlp, context=mx.cpu())
You can use a mx.gpu()
or if a list of devices (e.g. [mx.gpu(0), mx.gpu(1)]
) is provided, data-parallelization will be used automatically. But for this tiny example, using a GPU device might not help.
The last thing we need to specify is the optimization algorithm (a.k.a. optimizer) to use. We use the basic SGD with a fixed learning rate 0.1 , momentum 0.9 and weight decay 0.00001:
optimizer = mx.SGD(η=0.1, μ=0.9, λ=0.00001)
Now we can do the training. Here the n_epoch
parameter specifies that we want to train for 20 epochs. We also supply a eval_data
to monitor validation accuracy on the validation set.
mx.fit(model, optimizer, train_provider, n_epoch=20, eval_data=eval_provider)
Here is a sample output
INFO: Start training on [CPU0]
INFO: Initializing parameters...
INFO: Creating KVStore...
INFO: == Epoch 001 ==========
INFO: ## Training summary
INFO: :accuracy = 0.7554
INFO: time = 1.3165 seconds
INFO: ## Validation summary
INFO: :accuracy = 0.9502
...
INFO: == Epoch 020 ==========
INFO: ## Training summary
INFO: :accuracy = 0.9949
INFO: time = 0.9287 seconds
INFO: ## Validation summary
INFO: :accuracy = 0.9775
Convolutional Neural Networks
In the second example, we show a slightly more complicated architecture that involves convolution and pooling. This architecture for the MNIST is usually called the [LeNet]_. The first part of the architecture is listed below:
# input
data = mx.Variable(:data)
# first conv
conv1 = @mx.chain mx.Convolution(data, kernel=(5,5), num_filter=20) =>
mx.Activation(act_type=:tanh) =>
mx.Pooling(pool_type=:max, kernel=(2,2), stride=(2,2))
# second conv
conv2 = @mx.chain mx.Convolution(conv1, kernel=(5,5), num_filter=50) =>
mx.Activation(act_type=:tanh) =>
mx.Pooling(pool_type=:max, kernel=(2,2), stride=(2,2))
We basically defined two convolution modules. Each convolution module is actually a chain of Convolution
, tanh
activation and then max Pooling
operations.
Each sample in the MNIST dataset is a 28x28 single-channel grayscale image. In the tensor format used by NDArray
, a batch of 100 samples is a tensor of shape (28,28,1,100)
. The convolution and pooling operates in the spatial axis, so kernel=(5,5)
indicate a square region of 5-width and 5-height. The rest of the architecture follows as:
# first fully-connected
fc1 = @mx.chain mx.Flatten(conv2) =>
mx.FullyConnected(num_hidden=500) =>
mx.Activation(act_type=:tanh)
# second fully-connected
fc2 = mx.FullyConnected(fc1, num_hidden=10)
# softmax loss
lenet = mx.Softmax(fc2, name=:softmax)
Note a fully-connected operator expects the input to be a matrix. However, the results from spatial convolution and pooling are 4D tensors. So we explicitly used a Flatten
operator to flat the tensor, before connecting it to the FullyConnected
operator.
The rest of the network is the same as the previous MLP example. As before, we can now load the MNIST dataset:
batch_size = 100
include("mnist-data.jl")
train_provider, eval_provider = get_mnist_providers(batch_size; flat=false)
Note we specified flat=false
to tell the data provider to provide 4D tensors instead of 2D matrices because the convolution operators needs correct spatial shape information. We then construct a feedforward model on GPU, and train it.
# fit model
model = mx.FeedForward(lenet, context=mx.gpu())
# optimizer
optimizer = mx.SGD(η=0.05, μ=0.9, λ=0.00001)
# fit parameters
mx.fit(model, optimizer, train_provider, n_epoch=20, eval_data=eval_provider)
And here is a sample of running outputs:
INFO: == Epoch 001 ==========
INFO: ## Training summary
INFO: :accuracy = 0.6750
INFO: time = 4.9814 seconds
INFO: ## Validation summary
INFO: :accuracy = 0.9712
...
INFO: == Epoch 020 ==========
INFO: ## Training summary
INFO: :accuracy = 1.0000
INFO: time = 4.0086 seconds
INFO: ## Validation summary
INFO: :accuracy = 0.9915
Predicting with a trained model
Predicting with a trained model is very simple. By calling mx.predict
with the model and a data provider, we get the model output as a Julia Array:
probs = mx.predict(model, eval_provider)
The following code shows a stupid way of getting all the labels from the data provider, and compute the prediction accuracy manually:
# collect all labels from eval data
labels = reduce(
vcat,
copy(mx.get(eval_provider, batch, :softmax_label)) for batch ∈ eval_provider)
# labels are 0...9
labels .= labels .+ 1
# Now we use compute the accuracy
pred = map(i -> argmax(probs[1:10, i]), 1:size(probs, 2))
correct = sum(pred .== labels)
@printf "Accuracy on eval set: %.2f%%\n" 100correct/length(labels)
Alternatively, when the dataset is huge, one can provide a callback to mx.predict
, then the callback function will be invoked with the outputs of each mini-batch. The callback could, for example, write the data to disk for future inspection. In this case, no value is returned from mx.predict
. See also predict.


DR AHMED SHALAA.
BANK OF AFRICA OUAGADOUGOU,
BURKINA FASO.
Dear friend,
RE: TRANSFER OF ($8,500.000.00 USD EIGHT MILLION FIVE HUNDRED
THOUSAND DOLLARS)
I want to transfer to overseas the sum of ($8.500.000.00USD) Eight Million Five Hundred Thousand United States Dollars) from a Prime Bank in Africa. I would like to ask you to quietly look for a reliable and honest person who will be capable and fit to provide either an existing bank account or to set up a new Bank a/c immediately to receive this money, even an empty a/c can serve as far as it can receive money.
I am DR AHMED SHALAA. an accountant and personal confidant to Mr.Robert Rice who died together with his wife in a plane crash on the October 31st 1999 on their way to attendwedding in Boston, he is an American, a physician andindustrialist, he died without having anybeneficiary to his assets including his account here in Burkina Faso which he opened as his personal savings for the purpose of expansion and developement of his company before his untimely death in 1999.
The amount involved is ($8.500.000.00USD) Eight Million Five Hundred Thousand United States Dollars), no other person knows about this account. I am contacting you for us to transfer this funds to your account as the beneficiary, I want to transfer the whole $8,500.000.00 (Eight Million Five Hundred Thousand USD) into a safe account abroad, but I don't know any foreigner. I am only contacting you as a foreigner because this money can not be approved to a local person here, without valid international foreign passport, but can only be approved to any foreigner with valid international passport or drivers license and foreign a/c because the money is in US Dollars and the former owner of the a/c Mr.Robert Rice is aforeigner too, and as such the money can only be approved into a foreign a/c.
I need your full co-operation to make this work fine because the management is ready to approve this payment to any foreigner who has correct information of this account, which I will give to you, upon your positive response and once I am convinced that you are capable and will meet up with the inheritance procedures.
At the conclusion of this business, you will be given 40% of the total amount,55% will be for me, while 5% will be for expenses both parties might have incurred during the process of transferring. You should observe utmost CONFIDENTIALITY AND SECRECY in this transaction, and rest assured that this transaction would be most profitable for both of us because I will require your assistance to invest my share in your country.
Sincerely,
Dr.Ahmed Shalaa.
Make every IM count. Download Windows Live Messenger and join the i'm Initiative now. It's free. Make it count!


module Types.variations where
open import Types.equality
When two objects a, b ∈ β
are equal, their equality itself is represented by a type a =ᵦ b
. These types are identity types or equality types. These equality types form a family with one type per object in β
, written as:
Idᵦ : β → β → Set
such that Idᵦ(a, b)
where a, b, ∈ β
is the propositional equality type for a = b
.
The identity type for any two objects \(x, y ∈ A\) if of the form \(x =_A y\) represents the type of the proof that x is equal to y. The proof is equivalent to demonstrating that the type is inhabited, i.e. an object of that type can be created. The elimination rule on identity types, called the J rule looks like:
: {A : Set} →
J (P : (x y : A) → x ≡ y → Set)
→ ((x : A) → P x x refl)
→ (x y : A)
→ (x≡y : x ≡ y)
→ P x y x≡y
.x refl = p x J P p x
where P
is a predicate that it holds for any two objects x, y
of type A which are propositionally equal. p
is the a form that constructs P
for the case when x and y are both the same object x
and reflexivity refl
of the propositional equality ≡
. The rule states that any identity x≡y
can be proven using the reflexivity of the propositionlly equal objects x
and y
. Thus the J rule can be used with reflexivity refl
or x≡x
and y≡y
to prove the equality of all identity types, including x≡y
.
Axiom K is an identity eliminator which when defined can be used as an elimination rule to prove all identities as equal. It is also called principle of uniqueness of identity proofs.
K : {A : Set} {x : A}
P : x ≡ x → Set)
(→ P refl
→ (x≡x : x ≡ x)
→ P x≡x
K P p refl = p
Note that without the --with-K
command-line or the {-# OPTIONS --with-K #-}
inline option, agda will not compile axiom K. This is because we cannot assume every x ≡ x
to be equal to refl
, or that all identity propositions can be proven by refl
.
x≡x : x ≡ x =?= refl
The error message explains this rather clearly:
I'm not sure if there should be a case for the constructor refl,
because I get stuck when trying to solve the following unification
problems (inferred index ≟ expected index):
x ≟ x
Possible reason why unification failed:
Cannot eliminate reflexive equation x = x of type A because K has been disabled.
An alternative to axiom K and assuming the uniqueness of all identities is considering identities as paths, which are objects of Homotopy theory from Algebraic Geometry. We could then used homotopy theory to model all types as ∞-groupoids and work with some non-trivial interesting structures rather than the dead-end that is axiom K. We shall develop this theory later in this work.


| Mubango/__init__.py |
3 |
0 |
0 |
100% |
| Mubango/asgi.py |
4 |
4 |
0 |
0% |
| Mubango/settings.py |
48 |
0 |
0 |
100% |
| Mubango/test_settings.py |
3 |
0 |
0 |
100% |
| Mubango/urls.py |
17 |
1 |
0 |
94% |
| Mubango/wsgi.py |
4 |
4 |
0 |
0% |
| account/__init__.py |
0 |
0 |
0 |
100% |
| account/admin.py |
8 |
0 |
0 |
100% |
| account/apps.py |
5 |
0 |
0 |
100% |
| account/check_email_exists.py |
9 |
9 |
0 |
0% |
| account/migrations/0001_initial.py |
9 |
9 |
0 |
0% |
| account/migrations/__init__.py |
0 |
0 |
0 |
100% |
| account/models.py |
37 |
0 |
0 |
100% |
| account/signals.py |
10 |
0 |
0 |
100% |
| account/tests/__init__.py |
0 |
0 |
0 |
100% |
| account/tests/test_admin.py |
0 |
0 |
0 |
100% |
| account/tests/test_forms.py |
0 |
0 |
0 |
100% |
| account/tests/test_models.py |
39 |
1 |
0 |
97% |
| account/tests/test_views.py |
0 |
0 |
0 |
100% |
| account/urls.py |
4 |
0 |
0 |
100% |
| account/views.py |
6 |
2 |
0 |
67% |
| ad/__init__.py |
0 |
0 |
0 |
100% |
| ad/admin.py |
1 |
0 |
0 |
100% |
| ad/apps.py |
3 |
3 |
0 |
0% |
| ad/migrations/__init__.py |
0 |
0 |
0 |
100% |
| ad/models.py |
1 |
0 |
0 |
100% |
| ad/tests.py |
1 |
0 |
0 |
100% |
| ad/views.py |
1 |
1 |
0 |
0% |
| business/__init__.py |
0 |
0 |
0 |
100% |
| business/admin.py |
20 |
0 |
0 |
100% |
| business/apps.py |
3 |
3 |
0 |
0% |
| business/migrations/0001_initial.py |
10 |
10 |
0 |
0% |
| business/migrations/__init__.py |
0 |
0 |
0 |
100% |
| business/models.py |
52 |
0 |
0 |
100% |
| business/tests/__init__.py |
0 |
0 |
0 |
100% |
| business/tests/test_admin.py |
13 |
0 |
0 |
100% |
| business/tests/test_forms.py |
0 |
0 |
0 |
100% |
| business/tests/test_models.py |
33 |
0 |
0 |
100% |
| business/tests/test_views.py |
0 |
0 |
0 |
100% |
| business/views.py |
1 |
1 |
0 |
0% |
| common/__init__.py |
0 |
0 |
0 |
100% |
| common/admin.py |
14 |
0 |
0 |
100% |
| common/apps.py |
3 |
3 |
0 |
0% |
| common/migrations/0001_initial.py |
7 |
7 |
0 |
0% |
| common/migrations/__init__.py |
0 |
0 |
0 |
100% |
| common/models.py |
23 |
0 |
0 |
100% |
| common/tests/__init__.py |
0 |
0 |
0 |
100% |
| common/tests/test_admin.py |
6 |
0 |
0 |
100% |
| common/tests/test_models.py |
16 |
0 |
0 |
100% |
| common/utils.py |
7 |
0 |
0 |
100% |
| core/__init__.py |
0 |
0 |
0 |
100% |
| core/admin.py |
1 |
0 |
0 |
100% |
| core/apps.py |
3 |
3 |
0 |
0% |
| core/migrations/__init__.py |
0 |
0 |
0 |
100% |
| core/models.py |
1 |
0 |
0 |
100% |
| core/tests/__init__.py |
0 |
0 |
0 |
100% |
| core/tests/test_views.py |
11 |
0 |
0 |
100% |
| core/urls.py |
4 |
0 |
0 |
100% |
| core/views.py |
4 |
0 |
0 |
100% |
| event/__init__.py |
0 |
0 |
0 |
100% |
| event/admin.py |
15 |
0 |
0 |
100% |
| event/apps.py |
5 |
0 |
0 |
100% |
| event/migrations/0001_initial.py |
8 |
8 |
0 |
0% |
| event/migrations/__init__.py |
0 |
0 |
0 |
100% |
| event/models.py |
36 |
0 |
0 |
100% |
| event/signals.py |
12 |
0 |
0 |
100% |
| event/tests/__init__.py |
0 |
0 |
0 |
100% |
| event/tests/test_admin.py |
22 |
0 |
0 |
100% |
| event/tests/test_forms.py |
0 |
0 |
0 |
100% |
| event/tests/test_models.py |
36 |
0 |
0 |
100% |
| event/tests/test_views.py |
0 |
0 |
0 |
100% |
| event/views.py |
1 |
1 |
0 |
0% |
| manage.py |
12 |
12 |
0 |
0% |
| offer/__init__.py |
0 |
0 |
0 |
100% |
| offer/admin.py |
14 |
0 |
0 |
100% |
| offer/apps.py |
5 |
0 |
0 |
100% |
| offer/forms.py |
19 |
1 |
0 |
95% |
| offer/migrations/0001_initial.py |
8 |
8 |
0 |
0% |
| offer/migrations/__init__.py |
0 |
0 |
0 |
100% |
| offer/models.py |
45 |
0 |
0 |
100% |
| offer/signals.py |
12 |
0 |
0 |
100% |
| offer/tests/__init__.py |
0 |
0 |
0 |
100% |
| offer/tests/test_admin.py |
13 |
0 |
0 |
100% |
| offer/tests/test_forms.py |
20 |
0 |
0 |
100% |
| offer/tests/test_models.py |
44 |
0 |
0 |
100% |
| offer/tests/test_views.py |
0 |
0 |
0 |
100% |
| offer/utils.py |
3 |
0 |
0 |
100% |
| offer/views.py |
1 |
1 |
0 |
0% |
| review/__init__.py |
0 |
0 |
0 |
100% |
| review/admin.py |
6 |
0 |
0 |
100% |
| review/apps.py |
3 |
3 |
0 |
0% |
| review/migrations/0001_initial.py |
7 |
7 |
0 |
0% |
| review/migrations/__init__.py |
0 |
0 |
0 |
100% |
| review/models.py |
39 |
0 |
0 |
100% |
| review/tests/__init__.py |
0 |
0 |
0 |
100% |
| review/tests/test_models.py |
29 |
0 |
0 |
100% |
| review/views.py |
1 |
1 |
0 |
0% |


I'm Kevin Koopman
Portfolio
✨ Featured Work
Pixelnode
✨ Featured Work
Pixelnode
A game hosting panel built uppon the open-source app Pterodactyl. Made for managing your game server easier with countless extra features and a nice design.
✨ Featured Work
MusCloud
✨ Featured Work
MusCloud
A online music player built without production usage, but just to test my skills. I have used HTML and CSS, however, the panel is not responsive.
✨ Featured Work
Kraken
✨ Featured Work
Kraken
A game hosting panel built uppon the open-source app Pterodactyl. Made for managing your game server easier with countless extra features and a nice design.
Designed & built by Kevin Koopman
Look at the source-codeRecent Work ⏰
Click an image to view more details about the project!


Home
Github
Yelp
Contact
Grubnüb
"Where do you want to go?" "Wherever you do..."
A tool to help the nüb pick their type of grub
City or Zip Code:
Food Type:
Submit!
Reset


JavaScript is disabled on your browser.
Skip navigation links
Overview
Package
Class
Tree
Deprecated
Index
Help
Prev Letter
Next Letter
Frames
No Frames
All Classes
SEARCH:
JavaScript is disabled on your browser.
A
B
C
D
E
F
G
H
I
K
L
M
N
O
P
R
S
T
U
V
W
X
Y
C
camera
- Variable in class ure.actors.
UActor
canBeClosedBy(UActor)
- Method in class ure.terrain.
Door
Can actor close me?
canBeOpenedBy(UActor)
- Method in class ure.terrain.
Door
Can actor open me?
canSee(int, int, int, int, UArea, UActor)
- Static method in class ure.math.
UPath
Utility method: Can actor see from point 1 to point 2 in area? TODO: export this to a bresenham util func
canSee(UThing)
- Method in class ure.actors.
UActor
Can I see that thing from where I am (and I'm awake, and can see, etc)?
canSee(UThing)
- Method in class ure.actors.
UPlayer
canTouch(int, int)
- Method in class ure.ui.
ULight
canTouch(UCamera)
- Method in class ure.ui.
ULight
cartographer
- Variable in class ure.
UCommander
cellAt(int, int)
- Method in class ure.areas.
UArea
cellHeight()
- Method in class ure.ui.
UCamera
cellWidth()
- Method in class ure.ui.
UCamera
cellx
- Variable in class ure.ui.modals.
UModal
celly
- Variable in class ure.ui.modals.
UModal
children
- Variable in class ure.ui.
View
children()
- Method in class ure.ui.
View
Provides the set of views that will be rendered within this view.
close()
- Method in class ure.areas.
UArea
close()
- Method in class ure.ui.
ULight
closedBy(UActor, UCell)
- Method in class ure.terrain.
Door
Override this to do things when someone closes the door.
closemsg
- Variable in class ure.terrain.
Door
Clothing
- Class in
ure.things
A thing which can be worn by an actor.
Clothing()
- Constructor for class ure.things.
Clothing
color
- Variable in class ure.things.
ThingI
color
- Variable in class ure.ui.
ULight
COLOR_BLACK
- Static variable in class ure.math.
UColor
COLOR_WHITE
- Static variable in class ure.math.
UColor
colorvariance
- Variable in class ure.things.
ThingI
columns
- Variable in class ure.ui.
UCamera
CommandDrop
- Class in
ure.commands
CommandDrop()
- Constructor for class ure.commands.
CommandDrop
commander
- Variable in class ure.things.
ThingI
CommandGet
- Class in
ure.commands
CommandGet()
- Constructor for class ure.commands.
CommandGet
CommandInteract
- Class in
ure.commands
CommandInteract()
- Constructor for class ure.commands.
CommandInteract
CommandInventory
- Class in
ure.commands
CommandInventory()
- Constructor for class ure.commands.
CommandInventory
CommandLatchE
- Class in
ure.commands
CommandLatchE()
- Constructor for class ure.commands.
CommandLatchE
CommandLatchN
- Class in
ure.commands
CommandLatchN()
- Constructor for class ure.commands.
CommandLatchN
CommandLatchS
- Class in
ure.commands
CommandLatchS()
- Constructor for class ure.commands.
CommandLatchS
CommandLatchW
- Class in
ure.commands
CommandLatchW()
- Constructor for class ure.commands.
CommandLatchW
CommandMoveE
- Class in
ure.commands
CommandMoveE()
- Constructor for class ure.commands.
CommandMoveE
CommandMoveN
- Class in
ure.commands
CommandMoveN()
- Constructor for class ure.commands.
CommandMoveN
CommandMoveS
- Class in
ure.commands
CommandMoveS()
- Constructor for class ure.commands.
CommandMoveS
CommandMoveW
- Class in
ure.commands
CommandMoveW()
- Constructor for class ure.commands.
CommandMoveW
CommandPass
- Class in
ure.commands
CommandPass()
- Constructor for class ure.commands.
CommandPass
CommandTravel
- Class in
ure.commands
CommandTravel()
- Constructor for class ure.commands.
CommandTravel
consumeKeyFromBuffer()
- Method in class ure.
UCommander
Container
- Class in
ure.things
A thing which can have other things put into it, or taken out of it.
Container()
- Constructor for class ure.things.
Container
containerType()
- Method in class ure.areas.
UCell
containerType()
- Method in class ure.things.
ThingI
containerType()
- Method in interface ure.things.
UContainer
contents
- Variable in class ure.things.
ThingI
A
B
C
D
E
F
G
H
I
K
L
M
N
O
P
R
S
T
U
V
W
X
Y
Skip navigation links
Overview
Package
Class
Tree
Deprecated
Index
Help
Prev Letter
Next Letter
Frames
No Frames
All Classes
JavaScript is disabled on your browser.


Developing scalable and robust Web applications is difficult. One obstacle is JavaScript's event model, which makes asynchronous programs hard to maintain and extend. In this paper, we present the case study of a JavaScript library based on Arrows for asynchronous computation. Our library enables modular and more understandable programs and supports static type inference and visualization of control flow.
Asynchronous programming with callbacks in JavaScript leads to code that is difficult to understand and maintain. Arrows, a generalization of monads, are an elegant solution to asynchronous program composition. Unfortunately, improper arrow composition can cause mysterious failures with subtle sources. We present an arrows-based DSL in JavaScript which encodes semantics similar to ES6 Promises and an optional type-checker that reports errors at arrow composition time.


{% extends "layout.html" %} {% block body %}
This is a beta site and we encourage users to contact us with bugs or feature suggestions.
Errors in the website can be reported via Github.
You can also contact us by email to report data problems or feature suggestions.


public interface Scheduler
Each callback includes a reference to the scheduler driver that was
used to run this scheduler. The reference will not change for the
duration of a scheduler (i.e., from the point you do SchedulerDriver.start()
to the point that SchedulerDriver.join()
returns). This is intended for convenience so
that a scheduler doesn't need to store a reference to the driver
itself.
| Modifier and Type | Method and Description |
|---|---|
void |
disconnected(SchedulerDriver driver)
Invoked when the scheduler becomes "disconnected" from the master
(e.g., the master fails and another is taking over).
|
void |
error(SchedulerDriver driver,
java.lang.String message)
Invoked when there is an unrecoverable error in the scheduler or
driver.
|
void |
executorLost(SchedulerDriver driver,
Protos.ExecutorID executorId,
Protos.SlaveID slaveId,
int status)
Invoked when an executor has exited/terminated.
|
void |
frameworkMessage(SchedulerDriver driver,
Protos.ExecutorID executorId,
Protos.SlaveID slaveId,
byte[] data)
Invoked when an executor sends a message.
|
void |
offerRescinded(SchedulerDriver driver,
Protos.OfferID offerId)
Invoked when an offer is no longer valid (e.g., the slave was
lost or another framework used resources in the offer).
|
void |
registered(SchedulerDriver driver,
Protos.FrameworkID frameworkId,
Protos.MasterInfo masterInfo)
Invoked when the scheduler successfully registers with a Mesos
master.
|
void |
reregistered(SchedulerDriver driver,
Protos.MasterInfo masterInfo)
Invoked when the scheduler re-registers with a newly elected Mesos master.
|
void |
resourceOffers(SchedulerDriver driver,
java.util.List<Protos.Offer> offers)
Invoked when resources have been offered to this framework.
|
void |
slaveLost(SchedulerDriver driver,
Protos.SlaveID slaveId)
Invoked when a slave has been determined unreachable (e.g.,
machine failure, network partition).
|
void |
statusUpdate(SchedulerDriver driver,
Protos.TaskStatus status)
Invoked when the status of a task has changed (e.g., a slave is
lost and so the task is lost, a task finishes and an executor
sends a status update saying so, etc).
|
void registered(SchedulerDriver driver, Protos.FrameworkID frameworkId, Protos.MasterInfo masterInfo)
driver
- The scheduler driver that was registered.frameworkId
- The framework ID generated by the master.masterInfo
- Info about the current master, including IP and port.SchedulerDriver
,
Protos.FrameworkID
,
Protos.MasterInfo
void reregistered(SchedulerDriver driver, Protos.MasterInfo masterInfo)
driver
- The driver that was re-registered.masterInfo
- The updated information about the elected master.SchedulerDriver
,
Protos.MasterInfo
void resourceOffers(SchedulerDriver driver, java.util.List<Protos.Offer> offers)
SchedulerDriver.launchTasks(java.util.Collection<org.apache.mesos.Protos.OfferID>, java.util.Collection<org.apache.mesos.Protos.TaskInfo>, org.apache.mesos.Protos.Filters)
) or (b)
those resources have been rescinded (see offerRescinded(org.apache.mesos.SchedulerDriver, org.apache.mesos.Protos.OfferID)
).
Note that resources may be concurrently offered to more than one
framework at a time (depending on the allocator being used). In
that case, the first framework to launch tasks using those
resources will be able to use them while the other frameworks
will have those resources rescinded (or if a framework has
already launched tasks with those resources then those tasks will
fail with a TASK_LOST status and a message saying as much).driver
- The driver that was used to run this scheduler.offers
- The resources offered to this framework.SchedulerDriver
,
Protos.Offer
void offerRescinded(SchedulerDriver driver, Protos.OfferID offerId)
resourceOffers(org.apache.mesos.SchedulerDriver, java.util.List<org.apache.mesos.Protos.Offer>)
).driver
- The driver that was used to run this scheduler.offerId
- The ID of the offer that was rescinded.SchedulerDriver
,
Protos.OfferID
void statusUpdate(SchedulerDriver driver, Protos.TaskStatus status)
driver
- The driver that was used to run this scheduler.status
- The status update, which includes the task ID and status.SchedulerDriver
,
Protos.TaskStatus
void frameworkMessage(SchedulerDriver driver, Protos.ExecutorID executorId, Protos.SlaveID slaveId, byte[] data)
driver
- The driver that received the message.executorId
- The ID of the executor that sent the message.slaveId
- The ID of the slave that launched the executor.data
- The message payload.SchedulerDriver
,
Protos.ExecutorID
,
Protos.SlaveID
void disconnected(SchedulerDriver driver)
driver
- The driver that was used to run this scheduler.SchedulerDriver
void slaveLost(SchedulerDriver driver, Protos.SlaveID slaveId)
driver
- The driver that was used to run this scheduler.slaveId
- The ID of the slave that was lost.SchedulerDriver
,
Protos.SlaveID
void executorLost(SchedulerDriver driver, Protos.ExecutorID executorId, Protos.SlaveID slaveId, int status)
driver
- The driver that was used to run this scheduler.executorId
- The ID of the executor that was lost.slaveId
- The ID of the slave that launched the executor.status
- The exit status of the executor.SchedulerDriver
,
Protos.ExecutorID
,
Protos.SlaveID
,
Protos.Status
void error(SchedulerDriver driver, java.lang.String message)
driver
- The driver that was used to run this scheduler.message
- The error message.SchedulerDriver


{% extends '_layouts/layout_1-3_2-3.html' %} {% block page_title %} Chlamydia - NHS.UK {% endblock %} {% block pageTitle %} Chlamydia {% endblock %} {% block sidenav %}
{% endblock %} {% block content %}Chlamydia is the most common sexually transmitted infection (STI). Men and women can get it.
Anyone who has unprotected sex can get chlamydia.
You could have chlamydia even if you don't have any symptoms, or your symptoms go away.
The only way to know if you have it is to get a chlamydia test.
It's easy to treat with medical help.
The symptoms of chlamydia in women are:
The symptoms of chlamydia in men are:
If you think you have any symptoms you should get a test.
We can help you find a test that’s right for you.
Find out about chlamydia testsAnyone who has sex can get chlamydia and pass it on. You don't need to have sex with lots of people to be at risk.
You're more at risk and should get a chlamydia test if any of the following apply:
Chlamydia is a bacteria that's found in people who have the infection. It can live in the:
Chlamydia is usually passed on by:
Chlamydia can also be passed from a pregnant woman to her baby.
You can't get chlamydia from kissing, hugging, swimming pools, toilet seats, sharing baths, towels, cups, plates or cutlery.
If you have chlamydia a health professional will give you antibiotics. It's usually one of the following:
You might be given antibiotics before you get your test results. This could happen if it's likely that you have chlamydia, for example you have symptoms.
After you've finished the antibiotics, you may be told to have another chlamydia test to check it's gone.
{% endblock %}


Money Play. How should Red play 65?
pips Red=124 White=58
(CorrectAnswer= 0/0, ErrorScore= 0)
If White doesn't roll a 6 next turn he must pass Red's redouble.
Red's best play is bar/19, 12/7. This leaves White zero shots while still giving Red good outer board coverage. Bar/19/14 gives White 4 unnecessary shots while White still has a four-point home board. This doubles Red's gammon losses from 4% to 8% - an unacceptable risk.
Red's best play is bar/19, 12/7. This leaves White zero shots while still giving Red good outer board coverage. Bar/19/14 gives White 4 unnecessary shots while White still has a four-point home board. This doubles Red's gammon losses from 4% to 8% - an unacceptable risk.
1. Cubeful 2-ply bar/19 12/7 Eq.: +0.673 0.697 0.054 0.001 - 0.303 0.047 0.000 2. Cubeful 2-ply bar/14 Eq.: +0.606 (-0.067) 0.678 0.050 0.001 - 0.322 0.092 0.000 3. Cubeful 2-ply bar/19 16/11 Eq.: +0.547 (-0.126) 0.650 0.047 0.001 - 0.350 0.091 0.001 4. Cubeful 0-ply bar/19 6/1 Eq.: +0.369 (-0.304) 0.605 0.049 0.001 - 0.395 0.098 0.000 5. Cubeful 0-ply bar/19 8/3* Eq.: +0.249 (-0.424) 0.611 0.056 0.002 - 0.389 0.234 0.004


Effects Added:
12xx - Change Duty Cycle/Noise Mode:
This effect will change the duty cycle or the noise output mode.
If you are in a square channel (SQ1 or SQ2), you will change the Duty Cycle (possible values are 00, 01, 02 and 03), if you are in the Noise Channel (NOI) you could change the noise mode, possible values are 00 and 01. Keep in mind that you can change them too by using the Duty Cycle Macro of the instrument.


Welcome
About
Resume
Contact information:
Name: Jonathan Lander
Phone:<PHONE_NUMBER>
Email<EMAIL_ADDRESS>Address: 27109 Route 66 Lucinda PA
Projects
Here are a couple of projects I have worked on:
Sorting:
Using sorting algorithms to process large sets of numbers
in C++.
Download Sorting
Game of Life:
Using C# to program the well know simulation of
Game of Life.
Download GOL
Ski Game:
Ski game made in javascript.
Download Ski
Validation:
Validating input through javascript.
Download VALIDATION


Max
If there was ever a young pup that liked grass, it's max.
Rudy
Young and Fierce, that's all I have to say.
Max
If there was ever a young pup that liked grass, it's max.
Rudy
Young and Fierce, that's all I have to say.
Ralf
This old mutt likes to roll in the dirt.


About us:
GST guide is a user friendly project, which can help generate GST reports,
e-verifiable bills and use a mobile app for product scan instead of requiring a bar
code reader.
This project can be divided into following cateogories:


Leafony Leaf
Leaf Template
This project template is the basis of an expansion leaf for the
Leafony
and includes both printed circuit board and schematic templates.
PCB Template
The PCB template features the same dimensions as
other Leafony Leaves and includes a unified connector
to interface with other Leaves.
Schematic Template
The schematic template includes the connectors corresponding symbol
and purpose based pin naming.
Below graphic illustrates the pcb template:
© 2022 LEAFONY SYSTEMS Co., Ltd


A plane mirror makes an image of objects in front of it; these images appear to be behind the plane in which the mirror lies. A straight line drawn from part of an object to the corresponding part of its image makes a right angle with, and is bisected by, the surface of the plane mirror. The image formed by a plane mirror is always virtual (meaning that the light rays do not actually come from the image), upright, and of the same shape and size as the object it is reflecting
A convex lens is also known as a converging lens. A converging lens is a lens that converges rays of light that are traveling parallel to its principal axis. They can be identified by their shape which is relatively thick across the middle and thin at the upper and lower edges. The edges are curved outward rather than inward.
A concave lens is a lens that possesses at least one surface that curves inwards. It is a diverging lens, meaning that it spreads out light rays that have been refracted through it.


Constructor Summary
| Public Constructor | ||
| public |
|
Member Summary
| Private Members | ||
| private |
Page area replaced if path changed. |
|
| private |
_preCtx: * |
|
| private |
Root area. |
|
| private |
_router: * |
Method Summary
| Public Methods | ||
| public |
Activate application |
|
| public |
Back page. |
|
| public |
Go a page. |
|
| public |
Replace page. |
| Private Methods | ||
| private |
_replaceContent(page: Class<Page>, ctx: Object) Replace layer. |
|
| private |
Update page title of browser |
Public Constructors
public constructor() source
Public Methods
public activate(rootViewClass: Class<View>, routeMap: Object, opts: Object) source
Activate application
public replace(page: Class<Page>, ctx: *) source
Replace page.
Params:
| Name | Type | Attribute | Description |
| page | Class<Page> | Page class |
|
| ctx | * | context |


---
category:
shop_by_price: true
products:
limit: {{theme_settings.categorypage_products_per_page}}
---
{{inject "categoryProductsPerPage" theme_settings.categorypage_products_per_page}}
{{#partial "head"}}
{{#if pagination.category.previous}}
{{/if}}
{{#if pagination.category.next}}
{{/if}}
{{/partial}}
{{#partial "page"}}
{{> components/common/breadcrumbs breadcrumbs=breadcrumbs}}
{{category.name}}
- Up to 50 lbs
- Hold Feature
- Stainless Steel and plastic
- 11x15 platform
- Motion Locking
- Water Resistant
- 1-Year Warranty
- up to 75 lbs
- Trusted H2 Technology
- Stainless Steel Platform
- 10x10 platform
- Motion Locking
- Water Resistant
- 3-Year Warranty
- Up to 250 lbs
- 357 or H2
- H2 for water Weigh-in
- larger platform
- Motion Locking (H2 only)
- Water Resistant
- 3-Year Warranty
- Up to 5,000 lbs
- Trusted H2 Technology
- Stainless Steel Load Cell
- Hanging S-Hook
- Motion Locking
- Water Resistant
- 3-Year Warranty
{{#if category.image}}
{{/if}}
{{{category.description}}}
{{/partial}}
{{> layout/base}}


[ Home | Overview | Publications | Software/Downloads ] • [ Documentation/Questions | Training Videos and Slides ] • [ People | Acks ]
These notes describe how to build and install HPCToolkit and hpcviewer and their prerequisites with Spack. HPCToolkit proper (hpcrun, hpcstruct and hpcprof) is used to measure and analyze an application’s performance and then produce a database for hpcviewer. HPCToolkit is supported on the following platforms. IBM Blue Gene is no longer supported.
We provide binary distributions for hpcviewer and hpctraceviewer on Linux (x86_64, ppc64/le and aarch64), Windows and MacOS. HPCToolkit databases are platform-independent and it is common to run hpcrun on one machine and then view the results on another machine.
We build HPCToolkit and its prerequisite libraries from source.
HPCToolkit has some 15-20 prerequisites and we now use spack to build
them. It is possible to use spack to install all of hpctoolkit or
build just the prerequisites and then build hpctoolkit with the
traditional configure ; make ; make install
method from
autotools. Developers will probably want to run configure
and
make
manually, but both methods are supported.
Note: the old method of using hpctoolkit-externals to build the prerequisite libraries is now superseded by spack and is no longer supported.
These notes are written mostly from the view of using spack to build hpctoolkit and its dependencies. If you are a more experienced spack user, especially if you want to use spack to build hpctoolkit plus several other packages, then you will want to adapt these directions to your own needs.
Spack documentation is available at:
The current status of using Spack for HPCToolkit is at:
Last revised: October 19, 2021.
Building HPCToolkit requires the following prerequisites.
Hpcviewer and hpctraceviewer require Java version 8 or 11. Starting with version 2021.01, the viewers now need Java 11 or later (but not 15). Up through 2020.12, the viewers need Java 8 (not later). On Linux, the viewers also require GTK+ version 3.20 or later starting with 2021.01 and GTK+ version 2.x up through 2020.12.
Spack uses a special notation for specifying the version, variants, compilers and dependencies when describing how to build a package. This combination of version, variants, etc is called a ’spec’ and is used both on the command line and in config files.
spack info <package>
shows
the available versions and variants for a package. In most cases,
spaces are optional between elements of a spec. For example:
<EMAIL_ADDRESS>dyninst @10.1.0 hpctoolkit @master
-
(dash) and ~
(tilde) both mean ’off’. Use dash after a space
and tilde after a non-space. For example:
elfutils+bzip2~nls elfutils +bzip2 -nls<EMAIL_ADDRESS>+bzip2~nls
dyninst+openmp build_type=RelWithDebInfo<EMAIL_ADDRESS>transcoder=iconv
hpctoolkit@master <EMAIL_ADDRESS>amg2013 cflags='-O2 -mavx512pf'
hpctoolkit@master <EMAIL_ADDRESS>Normally, a system has only one arch type and you don’t need to specify this. However, for systems with separate front and back-end types, the default is the back end. For example, if you wanted to build python for the front end on Cray, then you might use something like this.
<EMAIL_ADDRESS>arch=cray-sles15-x86_64
Also, now that spack has implemented microarchitecture targets (haswell, ivybridge, etc), you can use ’target’ to build for a generic x86_64 or a specific CPU type. For example:
amg2013 target=x86_64 lulesh target=ivybridge
You can use spack arch
to display the generic, top-level
families and the micro-arch targets.
spack arch --known-targets
When writing a spec (for spack install
or other), spack will
fully resolve all possible choices for the package and all of its
dependencies and create a unique hash value for that exact
configuration. This process is called ’concretization.’ To see how
spack would concretize a spec, use spack spec
.
spack spec hpctoolkit@master <EMAIL_ADDRESS><EMAIL_ADDRESS>Spack is available via git clone from GitHub. This includes the core
spack machinery and recipes for building almost 6,000 packages (and
growing). You should also clone HPCToolkit for the
packages.yaml
file which is used to configure the spack build.
git clone https://github.com/spack/spack.git git clone https://github.com/hpctoolkit/hpctoolkit.git
After cloning, add the spack/bin
directory to your PATH, or else
source the spack setup-env
script.
(bash) . /path/to/spack/share/spack/setup-env.sh (csh) setenv SPACK_ROOT /path/to/spack/root source $SPACK_ROOT/share/spack/setup-env.csh
It suffices to add spack/bin
to your PATH (or even symlink the
spack launch script). Sourcing the setup-env
script adds extra
support for modules built by spack.
config.yaml
is the top-level spack config file. This specifies
the directory layout for installed files and the top-level spack
parameters. There are two fields that you normally want to set,
especially if you want to install packages and modules for hpctoolkit
in a public directory. For a module to be available, both the
install_tree
and module_roots
directories must be
accessible.
By default, spack installs packages inside the spack repository at
spack/opt/spack
. To use another location, set the root
field under install_tree
in config.yaml
.
config: install_tree: root: /path/to/top-level/install/directory
By default, spack installs module files inside the spack repository at
spack/share/spack
. The syntax for resetting this is changing.
In the old syntax, you put the top-level directory in
config.yaml
and enable the module type(s) in
modules.yaml
.
config: module_roots: # normally, need only one of these tcl: /path/to/top-level/tcl-module/directory lmod: /path/to/top-level/lmod-module/directory modules: enable: - tcl (or lmod)
In the new syntax, the paths go in modules.yaml
, and there is
one extra step in the hierarchy (default:
).
modules: default: roots: # normally, need only one of these tcl: /path/to/top-level/tcl-module/directory lmod: /path/to/top-level/lmod-module/directory enable: - tcl (or lmod)
There are two other fields that you may want to set for your local system.
connect_timeout
– some download sites, especially sourceforge
are often slow to connect. If you find that connections are timing out,
then increase this time to 30 or 60 seconds (default is 10 seconds).
build_jobs
– by default, spack uses all available hardware
threads for parallel make, up to a limit of 16. If you want to use a
different number, then set this.
There are also parameters for the locations of the build directories, the cache of downloaded tar files, etc, which you may wish to set.
The default config.yaml
file is in the spack repository at
spack/etc/spack/defaults
. The simplest solution is to copy this
file one directory up and then edit the copy (don’t edit the default
file directly).
cd spack/etc/spack cp defaults/config.yaml . vi config.yaml
Alternatively, you could put this file in a separate directory, outside
of the spack repository and then use -C dir
on the spack command
line. (The -C
option goes before the spack command name.)
spack -C dir install ...
Note: if you put config.yaml
in spack/etc/spack
, then it
will apply to every spack command for that repository (and you won’t
forget). Putting it in a separate directory is more flexible because
you can support multiple configurations from the same repository. But
then you must use -C dir
with every spack command or else you
will get inconsistent results.
You can view the current configuration with spack config
.
spack [-C dir] config get config
See the spack docs on ‘Configuration Files’ and ‘Basic Settings’.
https://spack.readthedocs.io/en/latest/configuration.html https://spack.readthedocs.io/en/latest/config_yaml.html
The packages.yaml
file specifies the versions and variants for
the packages that spack installs and serves as a common reference
point for HPCToolkit’s prerequisites. This file also specifies the
paths or modules for system build tools (cmake, python, etc) to avoid
rebuilding them. Put this file in the same directory as
config.yaml
. A sample packages.yaml
file is available
in the spack
directory of the hpctoolkit repository.
There are two main sections to packages.yaml
. The first
specifies the versions and variants for hpctoolkit’s prereqs. By
default, spack will choose the latest version of each package (plus
any constraints from hpctoolkit’s package.py
file). In most
cases, this will work, but not always. If you need to specify a
different version or variant, then set this in packages.yaml
.
Note: the versions and variants specified in hpctoolkit’s
package.py
file are hard constraints and should not be changed.
Variants in packages.yaml
are preferences that may be modified
for your local system. (But don’t report a bug until you have first
tried the versions from packages.yaml
that we supply.)
There are at least two packages with a variant that you may need to
change depending on your system. But always check the current
packages.yaml
file to see if any more have been added.
binutils
– avoid versions 2.35 and 2.35.1, they have a bug
that spews errors from hpcprof. Use 2.34 until 2.36 is available.
intel-tbb
– for very old Intel or AMD systems that don’t support
transactional memory, change +tm
to ~tm
. (This option has
no effect on non-x86 systems.)
The other sections in packages.yaml
specify paths or modules
for other packages and system build tools. Building hpctoolkit’s
prerequisites requires cmake 3.4 or later, perl 5.x and python 3.5 or
later. There are three ways to satisfy these requirements: a system
installed version (eg, /usr), a pre-built module or build from
scratch.
By default, spack will rebuild these from scratch, even if your local
version is perfectly fine. If you already have an installed version
and prefer to use that instead, then you can specify this in
packages.yaml
.
The easiest way to use a pre-built package is to let spack find the
package itself. Make sure the program is on your PATH and run
spack external
. For example, to search for cmake
, use:
spack external find cmake
This does not work for every spack package, but it does work with
cmake
, perl
and python
. Note: spack puts these
entries in packages.yaml
in the .spack
subdirectory of
your home directory.
You can also add these entries manually to packages.yaml
. For
example, this entry says that cmake 3.7.2 is available from module
CMake/3.7.2
. buildable: False
is optional and means
that spack must find a matching external spec or else fail the build.
cmake: externals: - spec<EMAIL_ADDRESS>modules: - CMake/3.7.2 buildable: False
This example says that python2 and python3 are both available in
/usr/bin
. Note that the prefix
entry is the parent
directory of bin
, not the bin directory itself.
python: externals: - spec<EMAIL_ADDRESS>prefix: /usr - spec<EMAIL_ADDRESS>prefix: /usr
Note: as a special rule for python, use package name python
,
even though the program name is python2 or python3.
Spack implements a hierarchy of micro-architecture targets, where ’target’ is a specific architecture (eg, haswell, ivybridge) instead of a generic family (x86_64). This allows the compiler to optimize code for the specific target.
You will notice this choice in two main places: the ’spack spec’ and the
path for the install directory. For example, linux-rhel7-x86_64
might become linux-rhel7-broadwell
. You can use spack
arch
to see the list of generic families and micro-architecture
targets.
spack arch --known-targets
If you prefer a generic install, you can use the target
option to
specify a generic family instead of a micro-architecture target. This
would be useful for a shared install that needs to work across multiple
machines with different micro-arch types. For example:
spack install hpctoolkit ... target=x86_64
If you want to use this target for all spack builds, then you can
specify this in packages.yaml
. The generic families are: x86_64,
ppc64, ppc64le and aarch64. For example:
packages: all: target: [x86_64]
See the spack docs on ’Build Customization’ and ’Specs and Dependencies’.
https://spack.readthedocs.io/en/latest/build_settings.html https://spack.readthedocs.io/en/latest/basic_usage.html#specs-dependencies
The ’concretizer’ is the part of spack that converts a partial spec into a full spec with values for the version and variants of every package in the spec plus all dependencies. The new concretizer for spack (clingo) is a third-party python library for solving answer set logic problems (eg, satisfiability).
The easiest way to install clingo it to use spack’s pre-built libraries. These are available for Linux (x86_64, ppc64le, aarch64) and Macos/Darwin (x86_64) for python 3.5 or later. The Macos version also requires Macos 10.13 or later and the Xcode developer package (for python and other programs).
By default, spack will automatically install (bootstrap) clingo the
first time you run a command that uses it (eg, spec
or
solve
). However, if this fails or you want to verify the steps
yourself, then follow these steps.
In config.yaml
, set concretizer
to clingo
.
config: concretizer: clingo
In bootstrap.yaml
, disable spack-install
to force spack
to use a pre-built binary instead of building from source.
bootstrap: trusted: github-actions: true spack-install: false
Spack needs at least one compiler configured (see below). If this is
your first time running spack on this machine, then use compiler
find
to detect a compiler. Finally, use spack solve
to
trigger bootstrapping.
spack compiler list (to display known compilers) spack compiler find (to add a compiler, if needed) spack solve zlib ==> Bootstrapping clingo from pre-built binaries ... zlib<EMAIL_ADDRESS>arch=linux-rhel8-zen
Spack stores the clingo bootstrap files in ~/.spack/bootstrap
.
You can check on the status of these files or clean (reset) them with
the find
or clean
commands.
spack find -b (displays the status of the bootstrap files) spack clean -b (erases the current bootstrap files)
If the binary bootstrap fails, then try the solve
step with
debugging turned on.
spack -d solve zlib
If the binary bootstrap fails or if your system is not supported, then
you will need to let spack build clingo from source. Reset
spack-install
to true and rerun spack solve zlib
. This
requires a compiler with support for C++14 and takes maybe 30-45
minutes to install all the packages.
https://spack.readthedocs.io/en/latest/getting_started.html#bootstrapping-clingo https://github.com/alalazo/spack-bootstrap-mirrors#supported-platforms
Building HPCToolkit requires GNU gcc/g++ version 7.3 or later. By default, spack uses the latest available version of gcc, but you can specify a different compiler, if one is available.
Spack uses a separate file, compilers.yaml
to store information
about available compilers. This file is normally in your home directory
at ~/.spack/platform
where ‘platform’ is normally ‘linux’ (or
else ‘cray’ or ‘bgq’).
The first time you use spack, or after adding a new compiler, you should
run spack compiler find
to have spack search your system for
available compilers. If a compiler is provided as a module, then you
should load the module before running find
. Normally, you only
need to run find
once, unless you want to add or delete a
compiler. You can also run spack compiler list
and spack
compiler info
to see what compilers spack knows about.
For example, on one power8 system running RedHat 7.3, /usr/bin/gcc is
version 4.8.5, but gcc 8.3.0 is available as module GCC/8.3.0
.
module load GCC/8.3.0 spack compiler find ==> Added 2 new compilers to /home/krentel/.spack/linux/compilers.yaml<EMAIL_ADDRESS><EMAIL_ADDRESS>==> Compilers are defined in the following files: /home/krentel/.spack/linux/compilers.yaml spack compiler list ==> Available compilers -- gcc rhel7-ppc64le --------------------------------------------<EMAIL_ADDRESS><EMAIL_ADDRESS>spack compiler info<EMAIL_ADDRESS><EMAIL_ADDRESS>paths: cc = /opt/apps/software/Core/GCCcore/8.3.0/bin/gcc cxx = /opt/apps/software/Core/GCCcore/8.3.0/bin/g++ f77 = /opt/apps/software/Core/GCCcore/8.3.0/bin/gfortran fc = /opt/apps/software/Core/GCCcore/8.3.0/bin/gfortran modules = ['GCC/8.3.0'] operating system = rhel7
Note: for compilers from modules, spack does not fill in the
modules:
field in the compilers.yaml
file. You need to
do this manually. In the above example, after running find
, I
edited compilers.yaml
to add GCC/8.3.0
to the
modules:
field as below. This is important to how spack
manipulates the build environment.
- compiler: modules: [GCC/8.3.0] operating_system: rhel7 spec<EMAIL_ADDRESS>...
Spack uses %
syntax to specify the build compiler and @
syntax to specify the version. For example, suppose you had gcc
versions 7.3.1, 8.3.0 and 10.2.0 available and you wanted to use 8.3.0.
You could write this as:
spack install package<EMAIL_ADDRESS>See the spack docs on ‘Compiler Configuration’.
First, set up your config.yaml
, packages.yaml
and
compilers.yaml
files as above and edit them for your system.
You can see how spack will build hpctoolkit with spack spec
.
spack spec hpctoolkit
Then, the “one button” method uses spack to install everything.
spack install hpctoolkit
Tip: Spack fetch is somewhat fragile and often has transient
problems downloading files. You can use spack fetch -D
to
pre-fetch all of the tar files and resolve any downloading problems
before starting the full install.
spack fetch -D hpctoolkit
The manual method uses spack to build hpctoolkit’s prerequisites and
then uses the traditional autotools configure && make && make
install
to install hpctoolkit. This method is primarily for
developers who want to compile hpctoolkit, edit the source code and
recompile, etc. This method is also useful if you need some configure
option that is not available through spack.
First, use spack to build hpctoolkit’s prerequisites as above. You
can either build some version of hpctoolkit as before (which will pull
in the prerequisites), or else use --only dependencies
to avoid
building hpctoolkit itself.
spack install --only dependencies hpctoolkit
Then, configure and build hpctoolkit as follows. Hpctoolkit uses automake and so allows for parallel make.
configure \ --prefix=/path/to/hpctoolkit/install/prefix \ --with-spack=/path/to/spack/install_tree/linux-fedora26-x86_64/gcc-7.3.1 \ ... make -j <num> make install
The argument to --with-spack
should be the directory containing
all of the individual package directories, normally two directories
down from the top-level install_tree
and named by the platform
and compiler. This option replaces the old --with-externals
.
The following are other options that may be useful. For the full list
of options, see configure -h
.
--enable-all-static
– build hpcprof-mpi statically linked for
the compute nodes.
--enable-bgq
– configure for Blue Gene/Q back end.
--enable-develop
– compile with optimization turned off for
debugging.
--with-package=path
– specify the install prefix for some
prerequisite package, mostly for developers who want to use a custom,
non-spack version of some package.
MPICXX=compiler
– specify the MPI C++ compiler for
hpcprof-mpi, may be a compiler name or full path.
Note: if your spack install tree has multiple versions or variants for
the same package, then --with-spack
will select the one with
the most recent directory time stamp (and issue a warning). If this
is not what you want, then you will need to specify the correct
version with a --with-package
option.
Beginning with the 2020.03.01 version, HPCToolkit now supports profiling CUDA binaries (nVidia only). For best results, use CUDA version 10.1 or later and Dyninst 10.1 or later. Note: in addition to a CUDA installation, you also need the CUDA system drivers installed. This normally requires root access and is outside the scope of spack.
For a spack install with CUDA, use the +cuda
variant.
spack install hpctoolkit +cuda
For a manual install, either download and install CUDA or use an
existing module, and then use the --with-cuda
configure option.
configure \ --prefix=/path/to/hpctoolkit/install/prefix \ --with-spack=/path/to/spack/install/dir \ --with-cuda=/path/to/cuda/install/prefix \ ...
If you installed CUDA with spack in the same directory as the rest of
the prerequisites, then the --with-spack
option should find it
automatically (but check the summary at the end of the configure
output). If you are using CUDA from a separate system module, then you
will need the --with-cuda
option.
Beginning with version 2021.02.01, HPCToolkit now supports profiling AMD GPU binaries through the HIP/ROCM interface. This requires ROCM 3.10 or later and also requires matching the HPCToolkit ROCM version to the version the application uses.
The spack build with ROCM support requires a 2-step build. First,
build the ROCM prerequisites (hip, rocm-dbgapi and roctracer-dev), and
second, specify them as spack externals packages and install
hpctoolkit with +rocm
.
The easiest way is to install the AMD package for ROCM in /opt
.
Normally, this requires root access. For example, suppose ROCM 4.0.0
is installed in /opt/rocm-4.0.0
. In this case, edit
packages.yaml
or spack.yaml
to specify the three spack
packages.
packages: hip: externals: - spec<EMAIL_ADDRESS>prefix: /opt/rocm-4.0.0/hip rocm-dbgapi: externals: - spec<EMAIL_ADDRESS>prefix: /opt/rocm-4.0.0 roctracer-dev: externals: - spec<EMAIL_ADDRESS>prefix: /opt/rocm-4.0.0
Then, build HPCToolkit with the +rocm
variant.
spack install hpctoolkit +rocm ...
Note: the hip prefix requires the hip subdirectory, but the other two
use the top-level /opt/rocm
prefix. This is somewhat fluid and
may change by system.
If /opt/rocm
is not available or is missing some of the pieces,
then build the missing packages with spack and again add them to
packages.yaml
. Note: you must build the packages one at a time
as separate roots. This will necessarily build some packages twice.
For example:
hip: externals: - spec<EMAIL_ADDRESS>prefix: /home/krentel/spack/linux-rhel8-x86_64/gcc-8.3.1/hip-4.0.0-qzauqkhwrfmpa6j37cpzysfpgipvhkmj
Note: for now, you must use the 2-step build and specify the ROCM
packages as spack externals, even if building them with spack. There
are two conflicts in the spack spec
for an all-in-one build.
Roctracer-dev requires python 2, but other packages require python 3,
and rocm-dbgapi requires libelf but dyninst requires elfutils.
Writing the packages as externals works around this problem.
For developers building with autotools, use the following configure
options. If /opt/rocm
is available, then use just the
--with-rocm
option. Otherwise, use the three other options.
--with-rocm=/opt/rocm (for all-in-one /opt/rocm) --with-rocm-hip=/path/to/hip/install --with-rocm-dbgapi=/path/to/rocm-dbgapi/install --with-rocm-tracer=/path/to/roctracer-dev/install
It is allowed to mix the all-in-one option with the individual packages. The rule is that the specific overrides the general.
HPCToolkit always supports profiling MPI applications. For
hpctoolkit, the spack variant +mpi
is for building hpcprof-mpi,
the MPI version of hpcprof. If you want to build hpcprof-mpi, then
you need to supply an installation of MPI.
Normally, for systems with compute nodes, you should use an existing
MPI module that was built for the correct interconnect for your system
and add this to packages.yaml
. The MPI module should be built
with the same version of GNU gcc/g++ used to build hpctoolkit (to keep
the C++ libraries in sync).
HPCToolkit can access the Hardware Performance Counters with either
PAPI or Perfmon (libpfm4). By default, the hpctoolkit package uses
perfmon. If you want to use PAPI instead, then build hpctoolkit with
+papi
. However, you can’t use both due to a potential conflict
in their header files.
PAPI runs on top of the perfmon library, but PAPI uses its own, internal copy of perfmon. Prior to version 5.6.0, PAPI did not install the perfmon header files, so it was impossible to access the perfmon events through PAPI.
However, starting with version 5.6.0, PAPI now installs both the perfmon library and its header files. Hpctoolkit configure will automatically detect this, so if you build hpctoolkit with a recent enough version of PAPI, then both the PAPI and perfmon interfaces will be available.
Support for Blue Gene/Q is now deprecated and versions 2020.03.01 and later will no longer build. If you want to install HPCToolkit on Blue Gene, then use spack version 2019.12.28 or git commit 0d91fb34edb2 with gcc 4.8.x and follow the directions below. These directions will also work (without Blue Gene) for Red Hat 6.x (glibc 2.12 is too old to support current hpctoolkit).
Blue Gene systems are being phased out, without a next generation replacement, but are still supported by hpctoolkit (for now). Blue Gene normally comes with a Red Hat Enterprise Linux (RHEL) 6.x front end and the GNU gcc/g++ 4.4 compilers with are too old to support the latest version of hpctoolkit.
Spack supports two architecture types on Blue Gene. The front-end arch
is bgq-rhel6-ppc64
and the back-end arch is bgq-cnk-ppc64
.
Normally, it would matter whether we built for the front end or back
end. But for the GNU compilers on Blue Gene, both compilers are
/usr/bin/gcc. So, we just build for the default back end.
There are two ways to build hpctoolkit for Blue Gene, depending on the
version of the compiler and Dyninst. The simple method uses the default
GCC 4.4 compiler and Dyninst 9.3.2. Edit these two entries in the
packages.yaml
file.
9.3.2
.
+bgq
to the libmonitor variants.
Then, build hpctoolkit with +bgq
turned on. The +bgq
variant adds MPI and hpcprof-mpi and supersedes the +mpi
variant.
spack install hpctoolkit +bgq
The advanced method involves building a new compiler (gcc 4.8 or 4.9) but allows using Dyninst 10.x. This method requires TCL or Lmod modules and an MPI C++ compiler built for a compatible version of g++. Mira and vesta at ANL have softenv modules for +mpiwrapper-gcc and +bgqtoolchain-gcc484 but don’t provide TCL or Lmod modules.
First, use spack to build a new compiler. Dyninst 10.x requires
gcc 4.8 or later, but libmonitor requires the true back-end
powerpc64-bgq-linux-gcc
compiler which is version 4.4. We
settle on gcc 4.8.5 as a compromise between these two constraints.
Edit config.yaml
to set module_roots
to a directory in
which to install the modules and then build gcc.
spack install gcc @4.8.5
Assuming you have modules installed, then load the new gcc module and
rerun spack compiler find
. This should add the new compiler to
your compilers.yaml
file (twice, for front and back end). For
example, on vulcan at LLNL,
module use /path/to/modules/bgq-cnk-ppc64 module load gcc-4.8.5-gcc-4.4.7-nzvjwva spack compiler find ==> Added 2 new compilers to /g/g21/krentel1/.spack/bgq/compilers.yaml<EMAIL_ADDRESS><EMAIL_ADDRESS>Note: after running spack compiler find
, you still need to add
the modules field to the compiler entry in compilers.yaml
as in
the section on Compilers.
Note: in the above example, we used gcc 4.4.7 to build gcc 4.8.5 (so the gcc-4.8.5 package is in the gcc-4.4.7 directory). You could then use gcc 4.8.5 to rebuild 4.8.5, if you like, but this is not necessary.
Finally, use the new compiler to build hpctoolkit with the new compiler.
If you have modified the dyninst entry in packages.yaml
, then
reset the dyninst version to 10.1.0 (or later).
spack install hpctoolkit +bgq<EMAIL_ADDRESS>If you don’t have modules installed, then use spack bootstrap
to build the environment-modules package. Then, source the bash or
csh script in the Modules/init
directory to add the
module
function to your environment. For example,
spack bootstrap cd /path/to/environment-modules-4.2.4-rwtvlanuss35fxd3xuyldbfopt2m4ecs/init (bash) . ./bash (csh) source ./csh
Alternatively, you could try adding the module environment variables
(PATH and LD_LIBRARY_PATH) manually, but then you may have to run
spack install with --dirty
. The --dirty
option tells
spack not to erase LD_LIBRARY_PATH while building packages.
spack install --dirty hpctoolkit +bgq<EMAIL_ADDRESS>For developers, if you are building hpctoolkit directly (outside of spack) but using spack prerequisites, then use a configure line similar to the following.
configure \ --prefix=/path/to/install/prefix \ --with-spack=/path/to/bgq-cnk-ppc64/gcc-4.8.5 \ --enable-bgq \ --enable-all-static \ MPICXX=mpicxx
Cray systems, like Blue Gene, have separate front and back-end
architecture types. For example, on theta at ANL, the front-end arch
is cray-sles12-haswell
(SuSE Linux version 12 for haswell) and
the back-end is cray-cnl6-mic_knl
(Compute Node Linux for KNL).
Hpctoolkit needs to be built with the GNU Programming Environment and
the front-end x86_64 compilers, plus the CC
MPI C++ wrapper.
Switch to the PrgEnv-gnu
module and unload the darshan module.
Darshan is a profiling tool that monitors an application’s use of I/O,
but it conflicts with hpctoolkit.
module swap PrgEnv-intel PrgEnv-gnu module unload darshan
By default, spack does not correctly identify the gcc compiler modules
as front-end compilers. Start by loading a recent gcc module (eg, 7.x
or 8.x) and try running spack compiler find
and spack
compiler list
. For example on theta at ANL,
module load gcc/8.3.0 spack compiler find /opt/gcc/8.3.0 spack compiler list ==> Available compilers -- gcc cnl6-any -------------------------------------------------<EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS>-- gcc sles12-x86_64 --------------------------------------------<EMAIL_ADDRESS><EMAIL_ADDRESS>If spack identifies the compiler (as above), then great. Note that we
need spack to accept this as a front-end compiler (sles12-x86_64), not
just for the back end (cnl6-any). If spack doesn’t find the compiler
automatically, then you need to add it manually. Edit
~/.spack/cray/compilers.yaml
and add an entry similer to the
following (your versions may differ).
- compiler: environment: {} flags: {} modules: - PrgEnv-gnu/6.0.5 - gcc/8.3.0 - craype/2.6.1 - cray-mpich/7.7.10 operating_system: sles12 paths: cc: /opt/gcc/8.3.0/bin/gcc cxx: /opt/gcc/8.3.0/bin/g++ f77: /opt/gcc/8.3.0/bin/gfortran fc: /opt/gcc/8.3.0/bin/gfortran spec<EMAIL_ADDRESS>target: x86_64
Regardless of whether spack created the entry or you added it, you still
need to add the modules:
field manually (be sure to include all
four modules). Although it takes several steps to create the correct
entry, the good news is that it should continue to work as long as the
underlying module exists.
Next, review your packages.yaml
file. On Cray systems with Xeon
Phi back-end nodes (KNL, KNH, etc), add ~tm
to intel-tbb to
disable transactional memory.
Finally, build hpctoolkit with the front-end arch type (eg,
cray-sles12-x86_64) and option +cray
. Normally, you can use OS
type fe
(front-end) in place of sles12
. As with Blue
Gene, the +cray
option adds MPI and hpcprof-mpi and supersedes
the +mpi
variant.
spack install hpctoolkit +cray arch=cray-fe-x86_64
On some systems, spack fails to properly load the compiler modules
during the build and fails during hpctoolkit configure with an error
about, “MPICXX is not a valid compiler.” In this case, make sure that
you have the PrgEnv-gnu and gcc modules loaded and retry the install
with --dirty
.
spack install --dirty hpctoolkit +cray arch=cray-fe-x86_64
For developers, if you are building hpctoolkit directly (outside of spack) but using spack prerequisites, then use a configure line similar to the following.
configure \ --prefix=/path/to/install/prefix \ --with-spack=/path/to/cray-sles12-x86_64/gcc-8.3.0 \ --enable-all-static \ MPICXX=CC
Since 2020.12 release, the HPCToolkit GUI interface provides both profile and trace views in a single application, i.e. hpcviewer. Prior to that, each view was a separate program: hpcviewer to analyze the profile database, and hpctraceviewer to display the traces.
We provide binary distributions for hpcviewer on Linux (x86_64, ppc64le and aarch64), Windows and MacOS (x86_64 and M1). HPCToolkit databases are platform-independent and it is common to run hpcrun on one machine and then view the results on another machine.
Starting with 2021.01, the viewer now requires Java 11 or later, plus GTK+ 3.20 or later on Linux. Older viewers, up through 2020.12, require Java 8 (not 9 or later), plus GTK+ 2.x for Linux.
The spack install is available on Linux x86_64, little-endian ppc64le (power8 and 9) and aarch64 ARM, and also MacOS on x86_64. This installs hpcviewer and includes the Java prerequisite.
For the current viewers, use openjdk with the most recent version of
Java 11 for all platforms. Currently, this is the default, but if not,
then you can add an explicit openjdk dependency. You can check this
with spack info
and spack spec
.
spack info openjdk spack install hpcviewer spack install hpcviewer ^openjdk @11.0.12_7 (if needed)
For older viewers, up through 2020.12, use the latest verion of openjdk Java 8 (version 1.8). For example (the versions may change):
spack install hpcviewer ^openjdk @1.8.0_265-b01
Note: to run the viewer on Macos, you can either open the Finder and
click your way to the hpcviewer.app
directory and double-click
on the hpcviewer icon, or else use spack load hpcviewer
to put
hpcviewer
on your PATH.
Binary distributions of the viewers for all supported platforms are available at:
On Linux, download the linux.gtk
version of hpcviewer (and also
hpctraceviewer for older versions), unpack the tar files and run the
install scripts (for both viewers) with the path to the desired install
prefix.
./install /path/to/install/directory
On Windows and MacOS, download the win32
or macosx.cocoa
versions and unpack the zip or dmg files in the desired directory.
Due to Apple’s security precautions, on MacOS, you may need to use
curl or wget instead of a web browser.
Note: the manual install uses the existing system version of Java (or one of several versions with modules), whereas the spack install includes the java prerequisite. That is, the spack install is self-contained and does not need to change the system java.
Some systems may have compilers that are too old for building HPCToolkit or other packages. For example, RedHat 7.x comes with gcc 4.8.x which is very old. If your system doesn’t already have modules for later compilers, then you may need to build a new compiler yourself.
First, pick a directory in which to install the modules and make
subdirectories for the spack packages and module files. In this
example, I’m using /opt/spack/Modules
as my top-level directory
and subdirectories packages
and modules
. Edit
config.yaml
and modules.yaml
to add these paths.
config: install_tree: root: /opt/spack/Modules/packages modules: default: roots: # just use one of these module_roots: tcl: /opt/spack/Modules/modules lmod: /opt/spack/Modules/modules
Determine if your system uses TCL (environment) or Lmod modules.
Normally, the module
command is a shell function. TCL modules
use modulecmd
and Lmod modules eval LMOD_CMD
. Edit
modules.yaml
to enable the module type for your system. Again,
you only need one of these (and don’t use dotkit unless you work at
LLNL).
modules: default: enable: - tcl - lmod
Then, choose a version of gcc and use the default compiler (normally
/usr/bin/gcc
) to build the newer version. Currently, gcc 8.x
is a good choice that builds robustly, has enough modern features but
is not too new to cause problems for some packages. For example,
spack install<EMAIL_ADDRESS>Note: it is not necessary to rebuild the new compiler with itself.
After building a new compiler, then you need to tell spack how to find
it. First, use module use
and module load
to load the
module. For TCL modules, the module files are in a subdirectory of
module_roots
named after the system architecture. For example,
module use /opt/spack/Modules/modules/linux-rhel7-x86_64 module load gcc-8.4.0-gcc-4.8.5-qemsqrc
For Lmod modules, the module directory is one level below that and the module names are a little different.
module use /opt/spack/Modules/modules/linux-rhel7-x86_64/Core module load gcc/8.4.0-dan4vbm
For both TCL and Lmod modules, it’s best to put the module use
command in your shell’s startup scripts so that module avail
and
module load
will know where to find them. After loading the
module, run spack compiler find
.
$ spack compiler find ==> Added 1 new compiler to /home/krentel/.spack/linux/compilers.yaml<EMAIL_ADDRESS>Finally, always check the new entry in compilers.yaml
and add the
name of the module to the modules:
field.
- compiler: environment: {} extra_rpaths: [] flags: {} modules: - gcc-8.4.0-gcc-4.8.5-qemsqrc operating_system: rhel7 paths: cc: /opt/spack/Modules/packages/linux-rhel7-x86_64/gcc-4.8.5/gcc-8.4.0-qemsqrcwkk52f6neef4kg5wvoucsroif/bin/gcc cxx: /opt/spack/Modules/packages/linux-rhel7-x86_64/gcc-4.8.5/gcc-8.4.0-qemsqrcwkk52f6neef4kg5wvoucsroif/bin/g++ f77: /opt/spack/Modules/packages/linux-rhel7-x86_64/gcc-4.8.5/gcc-8.4.0-qemsqrcwkk52f6neef4kg5wvoucsroif/bin/gfortran fc: /opt/spack/Modules/packages/linux-rhel7-x86_64/gcc-4.8.5/gcc-8.4.0-qemsqrcwkk52f6neef4kg5wvoucsroif/bin/gfortran spec<EMAIL_ADDRESS>target: x86_64
Note: as long as the spack packages and modules directories remain
intact and you don’t remove the compilers.yaml
entry, then this
compiler will always be available from within spack. You can also use
this compiler outside of spack by using module load
. If you
want to make this your default compiler for all spack builds, then you
can specify this in packages.yaml
. For example,
packages: all: compiler<EMAIL_ADDRESS>Also, when using the compiler from within spack, it doesn’t matter if you have the module loaded or not. Spack will erase your environment and re-add the appropriate modules automatically.
If your system does not support modules, then you will have to add it.
If you have root access, the easiest solution is to install a system
package for modules. If not, then use spack to install the
environment-modules package. Source the bash or csh script in the
init
directory to add the module
function to your
environment. For example,
spack install environment-modules cd /path/to/environment-modules-4.3.1-ism7cdy4xverxywj27jvjstqwk5oxe2v/init (bash) . ./bash (csh) source ./csh
Again, add the setup command to your shell’s startup scripts.
A spack mirror allows you to download and save a source tar file in advance. This is useful if your system is behind a firewall, or if you need to manually agree to a license, or if you just don’t want to keep downloading the same file over and over.
A mirror has a simple directory structure and is easy to set up. Create a top-level directory with subdirectories named after the spack packages and copy the tar files into their package’s subdirectory. For example,
my-mirror/ boost/ boost-1.66.0.tar.bz2 (from boost_1_66_0.tar.bz2) boost-1.70.0.tar.bz2 dyninst/ dyninst-10.1.0.tar.gz (from git checkout) ibm-java/ ibm-java-<IP_ADDRESS>.None (from ibm-java-sdk-8.0-5.30-ppc64le-archive.bin) intel-xed/ intel-xed-2019.03.01.tar.gz (from git checkout) mbuild-2019.03.01.tar.gz (resource from git checkout) jdk/ jdk-1.8.0_202.tar.gz (from jdk-8u202-linux-x64.tar.gz)
Note: the names of the files in the spack mirror always follow the same,
specific format, regardless of the actual name of the tar file. Version
is the spack name for the version (from spack info
), and
extension is the same extension as the tar file (tar.gz
,
tar.bz2
, etc) or else None
for other types of files.
<package-name> - <version> . <extension>
For example, the boost 1.66.0 tar file is actually named
boost_1_66_0.tar.bz2
but is stored in the mirror as
boost-1.66.0.tar.bz2
and jdk-8u202-linux-x64.tar.gz
is
renamed to jdk-1.8.0_202.tar.gz
.
For packages that use a snapshot from a git repository (tag or commit
hash), clone the repository, checkout the desired version, make a tar
file and gzip the file. (You should exclude the .git
subdirectory.) But note that spack refuses to use a cached file for
the head of a branch because it is a moving target.
Finally, after creating the mirror directory, add it to spack with
spack mirror add
. For example,
spack mirror add my-mirror file:///home/krentel/spack/my-mirror spack mirror list my-mirror file:///home/krentel/spack/mirror
Note: by default, spack stores downloaded files inside the spack
repository at spack/var/spack/cache
. This directory is a full
spack mirror, so instead of creating a separate directory tree, you
could just copy the files into the cache
directory. This is
useful when spack fetch
has trouble downloading a file. If you
can download the file manually, or copy it from another machine, then
just rename the file as above and copy it into the spack file cache.
For more information on mirrors, see:
Spack is somewhat fragile for how it downloads tar files and will often fail for transitory network problems. This is especially true for packages with many dependencies. For example:
==> Installing m4 ==> Searching for binary cache of m4 ==> No binary for m4 found: installing from source curl: (6) Could not resolve host: ftp.wayne.edu; Name or service not known ==> Fetching https://ftpmirror.gnu.org/m4/m4-1.4.18.tar.gz ==> Fetching from https://ftpmirror.gnu.org/m4/m4-1.4.18.tar.gz failed. ==> Error: FetchError: All fetchers failed for m4-1.4.18-vorbvkcjfac43b7vuswsvnm6xe7w7or5
There are two workarounds. First, assuming the problem is temporary,
simply wait 10 minutes or an hour and try again. Second, you could
manually download the file(s) by some other means and copy them to
spack’s cache directory spack/var/spack/cache/<package>
or to a
spack mirror.
Normally, HPCToolkit should build and work correctly with the latest version for all of its dependencies. But sometimes a new release will change something and break the build. This has happened a couple times where a new release of Boost has broken the build for Dyninst. Or, maybe the latest version of gcc/g++ disallows some usage and breaks the build.
The solution is to use packages.yaml
to specify an earlier
version until the rest of the code adapts to the change.
Spack is quite aggressive about compiling with a clean environment and
will unload modules unless they are specifically required by some config
file (compilers.yaml
or packages.yaml
). This can result
in a situation where you think some compiler or build tool is available
from your environment but spack removes it during the build.
In this example, I am using modules for GCC/8.3.0
and
CMake/3.8.2
. Spack finds the gcc 8.3.0 compiler and I added
<EMAIL_ADDRESS>to packages.yaml
. But I failed to add the
modules:
field for gcc 8.3.0 in compilers.yaml
. As a
result, the build fails with:
cmake: /usr/lib64/libstdc++.so.6: version `GLIBCXX_3.4.20' not found (required by cmake) cmake: /usr/lib64/libstdc++.so.6: version `GLIBCXX_3.4.21' not found (required by cmake) cmake: /usr/lib64/libstdc++.so.6: version `CXXABI_1.3.9' not found (required by cmake) ==> Error: ProcessError: Command exited with status 1:
The problem is that cmake 3.8.2 was built with g++ 8.3.0, but spack is
running cmake without the GCC/8.3.0 libraries and so the build fails as
above. One way to confirm this is to rerun spack install --dirty
which then succeeds. The --dirty
option tells spack not to
unload your modules. Whenever the build fails with a mismatched library
as above and especially when --dirty
fixes the problem, this is a
clear sign that spack is missing a module during the build.
Although --dirty
may make the build succeed, there should be no
case where this is necessary. The correct solution is to fill in the
modules:
field in compilers.yaml
or some other config
file. See the section on Compilers above.


Github LinkedIn Twitter
Anyone can create and share a new room here (these work best on Chrome and Firefox) iOS/iPadOS users: Public Meeting Room in Jitsi Meet App
Anyone can create and share a new board here (these are all deleted nightly)
Chat Clock Broadcast San Diego Paper Kiwix