|
Introduction to Data Science R The R Bootcamp |
adapted from paherald.sk.ca
In this practical you’ll practice customizing plots created using the ggplot2
package. By the end of this practical you will know how to:
patchwork
package.ggsave()
.TheRBootcamp
R project. It should already have the folders 1_Data
and 2_Code
. Make sure that the data files listed in the Datasets
section above are in your 1_Data
folder.# Done!
Open a new R script. At the top of the script, using comments, write your name and the date. Save it as a new file called plottingII_practical.R
in the 2_Code
folder.
Using library()
load the set of packages for this practical listed in the functions section above.
## NAME
## DATE
## Plotting II Practical
library(XX)
library(XX)
library(XX)
crime.csv
data set, containing crime data of US counties across various states. Using read_csv()
, load the data into R and store it as a new object called crime
.crime <- read_csv("1_Data/crime.csv")
crime
# A tibble: 1,071 × 36
communityname state population householdsize pctUrban medIncome pctWSocSec
<chr> <chr> <dbl> <dbl> <dbl> <dbl> <dbl>
1 BerkeleyHeights… NJ 11980 3.1 100 75122 23.6
2 Marpletownship PA 23123 2.82 100 47917 35.5
3 Norwoodtown MA 28700 2.6 100 42805 30.2
4 Wacocity TX 103590 2.62 100 17852 29.1
5 Shermancity TX 31601 2.54 100 24763 32.7
6 SanPablocity CA 25158 2.89 100 25479 23.0
7 Glendalecity CA 180038 2.62 100 34372 20.3
8 Worthingtoncity OH 14869 2.67 100 49851 23.8
9 Arlingtoncity TX 261721 2.6 100 35048 11.0
10 Marinacity CA 26436 3.34 100 29043 10.7
# … with 1,061 more rows, and 29 more variables: pctWRetire <dbl>,
# whitePerCap <dbl>, blackPerCap <dbl>, AsianPerCap <dbl>, HispPerCap <dbl>,
# PctPopUnderPov <dbl>, PctNotHSGrad <dbl>, PctUnemployed <dbl>,
# TotalPctDiv <dbl>, PersPerFam <dbl>, PctWorkMom <dbl>, NumImmig <dbl>,
# PctImmigRecent <dbl>, PctNotSpeakEnglWell <dbl>, RentMedian <dbl>,
# NumInShelters <dbl>, NumStreet <dbl>, PctForeignBorn <dbl>,
# PctBornSameState <dbl>, LandArea <dbl>, PopDens <dbl>,
# PctUsePubTrans <dbl>, murders <dbl>, robberies <dbl>, assaults <dbl>,
# burglaries <dbl>, larcenies <dbl>, autoTheft <dbl>, arsons <dbl>
geom_points()
) pitting each of the 7 crime indicators (murders
, robberies
, assaults
, burglaries
, larcenies
, autoTheft
, arsons
) against the percentage of people using public transportation (PctUsePubTrans
).ggplot(data = crime,
mapping = aes(x = XX, y = XX)) +
geom_point()
# and so on
scale_y_log10()
to fix this. Run the plots again.ggplot(data = crime,
mapping = aes(x = XX, y = XX)) +
geom_point() +
scale_y_log10()
# and so on
crime
data set called crime_long
, using the code below. (Note the use of crime_vars
as a positive selector for gather()
).# vector of crime variables
crime_vars = c("murders","robberies","assaults","burglaries","larcenies","autoTheft","arsons")
# transform to long
crime_long <- crime %>%
pivot_longer(names_to = "crime_var",
values_to = "frequency",
cols = all_of(crime_vars))
crime_long
data set, you can now make use of the amazing power of ggplot2
’s facet functions, such as facet_wrap()
. Use facet_wrap()
to automatically plot crime frequency against the percentage of people using public transportation for each of the crime variables.ggplot(data = crime_long,
mapping = aes(x = XX, y = XX)) +
geom_point() +
scale_y_log10() +
facet_wrap(~ XX)
ggplot(data = crime_long,
mapping = aes(x = PctUsePubTrans, y = frequency)) +
geom_point() +
scale_y_log10() +
facet_wrap(~ crime_var)
medIncome
, TotalPctDiv
, or PctNotHSGrad
, for each of the crime measures. What variables do predict, which kind of crime? Explore!theme()
Now that we have an informative plot, let’s focus on making it a bit more “pretty”", using ggplot’s theme()
function. The goal is to create a plot that looks like the plot below.
crime_facets <- ggplot(data = crime_long,
mapping = aes(x = PctUsePubTrans, y = frequency)) +
geom_point() +
scale_y_log10() +
facet_wrap(~ crime_var) +
theme(
panel.background = element_rect(fill='white'),
panel.grid.major = element_line(color = 'grey75',
size = .25),
panel.grid.minor = element_line(color = 'grey75',
size = .1),
strip.background = element_rect(fill='white'),
strip.text = element_text(face='italic', size=12, hjust=1),
axis.title.y = element_text(size=12,margin=margin(r = 10)),
axis.title.x = element_text(size=12,margin=margin(t = 10)),
panel.spacing = unit(1.1, "lines")) +
labs(x = '% public transportation', y = 'Crime frequency')
crime_facets
crime_facets
.crime_facets <- XX
"white"
of the panel using the panel.background
argument and the element_rect()
function.crime_facets +
theme(
panel.background = element_rect(fill = XX)
)
crime_facets +
theme(
panel.background = element_rect(fill = 'white')
)
"grey75"
and sizes .25
and .1
, respectively, using the panel.grid.major
and panel.grid.minor
arguments and the element_line()
function.crime_facets +
theme(
panel.background = element_rect(fill = XX),
panel.grid.major = element_line(color = XX, size = XX),
panel.grid.minor = element_line(color = XX, size = XX)
)
crime_facets +
theme(
panel.background = element_rect(fill = 'white'),
panel.grid.major = element_line(color = 'grey75', size = .25),
panel.grid.minor = element_line(color = 'grey75', size = .1)
)
"white"
using the strip.background
argument and the element_rect()
function.crime_facets +
theme(
panel.background = element_rect(fill = XX),
panel.grid.major = element_line(color = XX, size = XX),
panel.grid.minor = element_line(color = XX, size = XX),
strip.background = element_rect(fill = XX),
)
crime_facets +
theme(
panel.background = element_rect(fill = 'white'),
panel.grid.major = element_line(color = 'grey75', size = .25),
panel.grid.minor = element_line(color = 'grey75', size = .1),
strip.background = element_rect(fill = 'white')
)
"italic"
, adjust it to the right side, and set size to 12
using the strip.text
argument and the element_text()
function. See ?element_text()
.crime_facets +
theme(
panel.background = element_rect(fill = XX),
panel.grid.major = element_line(color = XX, size = XX),
panel.grid.minor = element_line(color = XX, size = XX),
strip.background = element_rect(fill = XX),
strip.text = element_text(face = XX, size = XX, hjust = XX)
)
crime_facets +
theme(
panel.background = element_rect(fill = 'white'),
panel.grid.major = element_line(color = 'grey75', size = .25),
panel.grid.minor = element_line(color = 'grey75', size = .1),
strip.background = element_rect(fill = 'white'),
strip.text = element_text(face = 'italic', size = 12, hjust = 1)
)
12
and add a margin of 10
to the top and right side, respectively, of the labels respectively, using axis.title.x
and axis.title.y
functions and the element_text()
and margin
functions. See ?margins()
.crime_facets +
theme(
panel.background = element_rect(fill = XX),
panel.grid.major = element_line(color = XX, size = XX),
panel.grid.minor = element_line(color = XX, size = XX),
strip.background = element_rect(fill = XX),
strip.text = element_text(face = XX, size = XX, hjust = XX),
axis.title.x = element_text(size = XX, margin = margin(t = XX)),
axis.title.y = element_text(size = XX, margin = margin(r = XX)),
)
crime_facets +
theme(
panel.background = element_rect(fill = 'white'),
panel.grid.major = element_line(color = 'grey75', size = .25),
panel.grid.minor = element_line(color = 'grey75', size = .1),
strip.background = element_rect(fill = 'white'),
strip.text = element_text(face = 'italic', size = 12, hjust = 1),
axis.title.x = element_text(size = 12, margin = margin(t = 10)),
axis.title.y = element_text(size = 12, margin = margin(r = 10))
)
1.1
"lines"
using the panel.spacing
argument and the unit
function.crime_facets +
theme(
panel.background = element_rect(fill = XX),
panel.grid.major = element_line(color = XX, size = XX),
panel.grid.minor = element_line(color = XX, size = XX),
strip.background = element_rect(fill = XX),
strip.text = element_text(face = XX, size = XX, hjust = XX),
axis.title.x = element_text(size = XX, margin = margin(t = XX)),
axis.title.y = element_text(size = XX, margin = margin(r = XX)),
panel.spacing = unit(XX, units = XX)
)
crime_facets +
theme(
panel.background = element_rect(fill = 'white'),
panel.grid.major = element_line(color = 'grey75', size = .25),
panel.grid.minor = element_line(color = 'grey75', size = .1),
strip.background = element_rect(fill = 'white'),
strip.text = element_text(face = 'italic', size = 12, hjust = 1),
axis.title.x = element_text(size = 12, margin = margin(t = 10)),
axis.title.y = element_text(size = 12, margin = margin(r = 10)),
panel.spacing = unit(1.1, units = "lines")
)
labs()
function.crime_facets +
theme(
panel.background = element_rect(fill = XX),
panel.grid.major = element_line(color = XX, size = XX),
panel.grid.minor = element_line(color = XX, size = XX),
strip.background = element_rect(fill = XX),
strip.text = element_text(face = XX, size = XX, hjust = XX),
axis.title.x = element_text(size = XX, margin = margin(t = XX)),
axis.title.y = element_text(size = XX, margin = margin(r = XX)),
panel.spacing = unit(XX, units = XX)
) +
labs(x = XX, y = XX)
crime_facets +
theme(
panel.background = element_rect(fill = 'white'),
panel.grid.major = element_line(color = 'grey75', size = .25),
panel.grid.minor = element_line(color = 'grey75', size = .1),
strip.background = element_rect(fill = 'white'),
strip.text = element_text(face = 'italic', size = 12, hjust = 1),
axis.title.x = element_text(size = 12, margin = margin(t = 10)),
axis.title.y = element_text(size = 12, margin = margin(r = 10)),
panel.spacing = unit(1.1, units = "lines")
) +
labs(x = '% public transportation', y = 'Crime frequency')
theme()
crime_theme
.crime_theme <- theme(
XX = XX,
XX = XX,
...
)
crime_theme <- theme(
panel.background = element_rect(fill = 'white'),
panel.grid.major = element_line(color = 'grey75', size = .25),
panel.grid.minor = element_line(color = 'grey75', size = .1),
strip.background = element_rect(fill = 'white'),
strip.text = element_text(face = 'italic', size = 12, hjust = 1),
axis.title.x = element_text(size = 12, margin = margin(t = 10)),
axis.title.y = element_text(size = 12, margin = margin(r = 10)),
panel.spacing = unit(1.1, units = "lines")
)
crime_theme
in order to apply your personalized theme.new_crime_plot + crime_theme
theme()
(see ?theme
), such as axis.ticks
or strip.placement
.When creating a plot ggplot
automatically chooses sensible dimensions for your plot in terms of x- and y-axis limits, geom sizes, or colors. However, all of these aspects of the plot can also be controlled manually or semi-manually using various scale_*
functions.
state
variable onto the color
argument and size the points according to the county’s population by mapping the population
variable onto the size
argument. Store the resulting plot in an object called crime_plot
.crime_plot <-
ggplot(data = crime_long,
mapping = aes(x = XX, y = XX,
color = XX, size = XX)) +
geom_point() +
scale_y_log10() +
facet_wrap(~ XX) +
crime_theme
crime_plot <- ggplot(data = crime_long,
mapping = aes(x = PctUsePubTrans, y = frequency,
color = state, size = population)) +
geom_point() +
scale_y_log10() +
facet_wrap(~ crime_var) +
crime_theme
crime_plot
scale_size()
and the range
argument, change the scaling of the points to reduce the degree of overlap among the points (see ?scale_size
). Try out a few numbers (smaller than 10) to create a version of the plot with a decent trade-off between point size and point overlap.crime_plot + scale_size(range = c(XX, XX))
crime_plot + scale_size(range = c(.5, 3))
scale_y_log10()
function. Set the limits to 0
and 2e+5
(i.e., 200,000
). (Note that R will tell you that this will overwrite the previous use of scale_y_log10()
, which is what we intend to do).crime_plot +
scale_size(range = c(XX, XX)) +
scale_y_continuous(limits = c(XX, XX))
crime_plot +
scale_size(range = c(.5, 3)) +
scale_y_log10(limits = c(1, 2e+5))
scale_color_gradient()
or similar functions. Another is to use a specific, pre-defined scheme, such as scale_color_colorblind()
. Use the latter. You will see that the colors have much more contrast making it distinguishing the colors based on luminescence alone easier.crime_plot +
scale_size(range = c(XX, XX)) +
scale_y_log10(limits = c(1, XX)) +
scale_color_colorblind()
crime_plot +
scale_size(range = c(.5, 3)) +
scale_y_log10(limits = c(1, 2e+5)) +
scale_color_colorblind()
scale_color_manual()
. Try assigning your own choice of colors. You may pick them from colors()
or generate them using, for instance, the viridis
function from the viridis
package (you may need to run install.packages('viridis')
before using it), which provides an optimized set of colors designed to be (1) colorful, (2) perceptually uniform, (3) robust to colorblindness, (4) and pretty. Take the latter approach, i.e., use the viridis()
function to generate colors, in the context of the scale_color_manual()
function.crime_plot +
scale_size(range = c(XX, XX)) +
scale_y_log10(limits = c(1, XX)) +
scale_color_manual(values = viridis(7))
crime_plot +
scale_size(range = c(.5, 3)) +
scale_y_log10(limits = c(1, 2e+5)) +
scale_color_manual(values = viridis(7))
crime_final
.crime_final <- ggplot(...) + ...
Save your plot to a .pdf
-file called crime_final
using ggsave()
. When you finish, find your plot in 3_Figures
and open it to see how it looks!
# Save crime_final to a pdf file
ggsave(filename = "crime_plot",
plot = crime_final,
device = "pdf",
path = '3_Figures',
width = 4,
height = 4,
units = "in")
Play around with the width
and height
arguments to change the dimensions of the plot.
Customize the code to create a .png
image.
In this section, you can play around with the patchwork
package (don’t forget to load it) do combine multiple plots into a single one.
Create three different plots that plot frequency
against different variables in our data set and call these three crime_a
, crime_b
, und crime_c
Now, combine all three plots horizontally using verbrechen_a + verbrechen_b + verbrechen_c
.
Or, place the third plot below the first two verbrechen_a + verbrechen_b / verbrechen_c
.
Now change the theme by applying theme_void()
to all three using the &
-Operator.
Finally, save your plot as a pdf using ggsave()
.
# ggplot2 -----------------------
library(tidyverse) # Load tidyverse (contains ggplot2!)
# create a scatter plot of highway miles per gallon against engine displacement
ggplot(data = mpg,
mapping = aes(x = displ, y = hwy)) +
geom_point()
# Store plot objects ------------
# store
my_plot <- ggplot(data = mpg,
mapping = aes(x = displ, y = hwy)) +
geom_point()
# evaluate (aka plot)
my_plot
# Facets ------------
# create separate plots for each car class
my_plot <- my_plot + facet_wrap(~class)
# plot
my_plot
# Customize themes ------------
# change panel background to 'green'
my_plot +
theme(
panel.background = element_rect(fill='green')
)
# change grid lines
my_plot +
theme(
panel.grid.major = element_line(color = 'red', size = 2),
panel.grid.minor = element_line(color = 'blue', size = 1)
)
# change strip background and text
my_plot +
theme(
strip.background = element_rect(fill = 'blue'),
strip.text = element_text(face = 'bold', size = 12)
)
# change axis titles
my_plot +
theme(
axis.title.y = element_text(size = 12, margin = margin(r = 10)),
axis.title.x = element_text(size = 12, margin = margin(t = 10))
)
# change panel spacing
my_plot +
theme(
panel.spacing = unit(2, "lines")
)
# Store themes ------------
# create theme
my_theme <- theme(
panel.background = element_rect(fill='green'),
panel.grid.major = element_line(color = 'red', size = 2),
panel.grid.minor = element_line(color = 'blue', size = 1),
strip.background = element_rect(fill = 'blue'),
strip.text = element_text(face = 'bold', size = 12),
strip.background = element_rect(fill = 'blue'),
strip.text = element_text(face = 'bold', size = 12),
axis.title.y = element_text(size = 12, margin = margin(r = 10)),
axis.title.x = element_text(size = 12, margin = margin(t = 10)),
panel.spacing = unit(2, "lines")
)
# apply theme
my_plot + my_theme # no parentheses
# Scaling ------------
# change x-axis scaling
my_plot + scale_x_continuous(limits = c(0, 10))
# change coloring
ggplot(data = mpg,
mapping = aes(x = displ, y = hwy,
color = class)) +
geom_point() +
scale_color_manual(values = viridis(7))
# Create image files ------------
# create pdf of my_plot
ggsave(filename = "my_plot_name",
plot = my_plot,
device = "pdf",
path = 'plotting_folder',
width = 4,
height = 4,
units = "in")
| File | Rows | Columns |
|---|---|---|
| crime.csv | 1071 | 36 |
The crime
data set is subsets of the Communities and Crime Unnormalized Data Set data set from the UCI Machine Learning Repository. Find variable descriptions below or at Communities and Crime Unnormalized Data Set
| Variable | Description |
|---|---|
| communityname | Community name |
| state | US state (by 2 letter postal abbreviation) |
| population | population for community |
| householdsize | mean people per household |
| pctUrban | number of people living in areas classified as urban |
| medIncome | median household income |
| pctWSocSec | percentage of households with social security income in 1989 |
| pctWRetire | percentage of households with retirement income in 1989 |
| whitePerCap | per capita income for caucasians |
| blackPerCap | per capita income for african americans |
| AsianPerCap | per capita income for people with asian |
| HispPerCap | per capita income for people with hispanic heritage |
| PctPopUnderPov | percentage of people under the poverty level |
| PctNotHSGrad | percentage of people 25 and over that are not high school graduates |
| PctUnemployed | percentage of people 16 and over, in the labor force, and unemployed |
| TotalPctDiv | percentage of population who are divorced |
| PersPerFam | mean number of people per family |
| PctWorkMom | percentage of moms of kids under 18 in labor force |
| NumImmig | total number of people known to be foreign born |
| PctImmigRecent | percentage of immigrants who immigated within last 3 years |
| PctNotSpeakEnglWell | percent of people who do not speak English well |
| RentMedian | rental housing - median rent |
| NumInShelters | number of people in homeless shelters |
| NumStreet | number of homeless people counted in the street |
| PctForeignBorn | percent of people foreign born |
| PctBornSameState | percent of people born in the same state as currently living |
| LandArea | land area in square miles |
| PopDens | population density in persons per square mile |
| PctUsePubTrans | percent of people using public transit for commuting |
| murders | number of murders in 1995 |
| robberies | number of robberies in 1995 |
| assaults | number of assaults in 1995 |
| burglaries | number of burglaries in 1995 |
| larcenies | number of larcenies in 1995 |
| autoTheft | number of auto thefts in 1995 |
| arsons | number of arsons in 1995 |
| Package | Installation |
|---|---|
tidyverse |
install.packages("tidyverse") |
patchwork |
install.packages("patchwork") |
| Package | Installation |
|---|---|
viridis |
install.packages("viridis") |
Facets
| Function | Package | Description |
|---|---|---|
facet_wrap() |
ggplot2 |
Create facets that wrap to fit the screen |
facet_grid() |
ggplot2 |
Create facets along one or more variables in a grid |
themes
| Function | Package | Description |
|---|---|---|
theme() |
ggplot2 |
Customize theme (see ?theme ) |
element_rect() |
ggplot2 |
Customize rect elements of theme |
element_line() |
ggplot2 |
Customize line elements of theme |
element_text() |
ggplot2 |
Customize text elements of theme |
element_blank() |
ggplot2 |
Remove elements from theme |
scales
| Function | Package | Description |
|---|---|---|
scale_x_*() , scale_y_*() |
ggplot2 |
Various functions to control the x- and y-axes |
scale_size_*() |
ggplot2 |
Various functions to control sizes |
scale_color_*() |
ggplot2 |
Various functions to control colors |
scale_fill_*() |
ggplot2 |
Various functions to control fill colors |
scale_alpha_*() |
ggplot2 |
Various functions to control color transparency |
colors
| Function | Package | Description |
|---|---|---|
viridis() |
viridis |
Generate colors from the viridis palette |
The main ggplot2
webpage at http://ggplot2.tidyverse.org/ has great tutorials and examples.
Check out Selva Prabhakaran’s website for a nice gallery of ggplot2 graphics http://r-statistics.co/Top50-Ggplot2-Visualizations-MasterList-R-Code.html
ggplot2
is also great for making maps. For examples, check out Eric Anderson’s page at http://eriqande.github.io/rep-res-web/lectures/making-maps-with-R.html
from R Studio


Performing Nested Transactions using
Savepoints in Oracle Data Provider for .NET (ODP.NET)
| The purpose of this sample is to demonstrate how Nested
Transactions can be achieved using Savepoint feature in ODP.NET.
The Savepoint feature provides fine-grained control of
transactions by marking the intermediate points within the transaction.
Once the Savepoint has been set, the transaction can be rolled back to
that Savepoint without affecting the preceding work. Through OracleTransaction class
provided in Oracle.ManagedDataAccess.ClientNamespace
with ODP.NET, the rollback operation to a particular Savepoint can be
done.
|
Using a C# console
application, this sample demonstrates:
- How to create Savepoints in a transaction
- How to rollback upto a particular Savepoint in a
transaction
- How to commit/rollback a transaction
When this sample is run, a database transaction begins. The sample
inserts a row in the Products table before creating any Savepoints. Then
three other rows are inserted in Products table. Before inserting each
of the three rows, a Savepoint is created. The user is displayed the
names of all Savepoint created. The user is given an option to rollback
to a particular Savepoint. The user can provide a Savepoint name that
he wishes to rollback. After rolling back to a particular Savepoint,
the user can further rollback to other Savepoints (if any) or commit
the data or rollback completely.This completes the transaction. Hence
it demonstrates how Nested Transactions are performed using Savepoints
in ODP.NET. |
| 1. When this sample is run, a console
application as shown in Figure 1.1 is displayed. A transaction is
started and data for Product 1 is inserted.The Savepoints "a", "b" and
"c" are created before inserting data for Product 2, Product 3 and
Product 4 respectively.
Figure 1.1
Displays the initial screen
2. The user can input the savepoint name upto which he
wishes to rollback the transaction. For eg. If the user inputs "b"
savepoint then the DML operations upto Savepoint "b" i.e. Insert
operations for Product 3, Product 4 gets rolled back. The message on
console is displayed as shown in Figure 1.2.
Figure 1.2
Displays user the options for rolling back to a savepoint,
commit, rollback completely
3. The user can further commit the changes or rollback
to the remaining savepoint (if any), in the above example the user can
rollback to savepoint "a" or rollback completely.
|
- Visual C# installed with Visual Studio 2005/2008/2010/2012.
- Oracle11g Database or higher running SQL*Net TCP/IP listener
(can be downloaded here)
- Oracle Data Provider for .NET (ODP.NET) (can be downloaded here)
Unzip SavepointSample.zipusing
Winzip or command utility to your convenient directory. Extraction of
the zip file results in the creation of Savepoint directory.
Connect to your database as any user and run the script Savepoint\Setup\DatabaseSetup.sql
at the SQL prompt.
@<Extract_Dir>\Savepoint\Setup\DatabaseSetup.sql
where <Extract_Dir>
is the directory where you have extracted the sample.
The script creates an user "oranet" with password "oranet".
It creates PRODUCTS table. This table is not populated with
any initial data.
1.Ensure that the Database setup has
been completed.
2.Open Savepoint.sln
using Visual Studio .NET from <Extract_Dir>\Savepoint
folder.
3.Edit ConnectionParams.cs
file to change the database connection parameters i.e.TNSName for
database you want to use . Save this file.
4.Ensure that the following .NET Component References have
been added to Savepoint
project:
- System
- System.Data
- Oracle.ManagedDataAccess.
To add the above .NET Components
- Go to Menu ->View-> Solution Explorer.
- Right click on Savepoint
project, choose 'Add Reference'.
- Choose the above .NET Components from the list displayed.
- Click 'Select', then OK.
- The chosen .NET component gets added to the project.
5. Build and run the sample.
| Directory |
File Name |
Description |
| Savepoint\doc |
Readme.html |
This file |
| blaf.css |
This is a cascading style sheet applied to
Readme.html |
| Savepoint\doc\images |
*.gif |
This folder contains images used as
screenshots in the Readme.html file. |
| Savepoint\src\ |
ConnectionParams.cs |
This C# file manages the database
connection used by sample. |
| Savepoint.cs |
This C# file contains source code for all
methods used for creating Savepoints and rollback/commit
operations. |
| Savepoint.csproj |
C# project file |
| Savepoint.csproj.user |
Visual Studio Project User Options (this
file gets automatically generated when a Visual Studio Project is
created) |
| Savepoint.sln |
Visual Studio Solution |
| Savepoint\Setup |
DatabaseSetup.sql |
This is a SQL script file |
|


(old?) Responder with NBNS spoofing https://github.com/foxglovesec/Potato/tree/master/Responder_with_spoof
(Original: not maintained!) https://github.com/SpiderLabs/Responder
Newer forks
https://github.com/lgandx/Responder
https://github.com/skelsec/Responder/tree/py3
https://github.com/skelsec/Responder
https://github.com/robikarobika/Responder


How to Use Sysmon 2.0 (Part 1)
On January 19, 2015, the SysInternals team released Sysmon 2.0. "This major update to Sysmon, a service that records process activity to the Windows event log for use by incident detection and forensic analysis, includes driver load and image load events with signature information, configurable hashing algorithm reporting, flexible filters for including and excluding events, and support for supplying configuration via a configuration file instead of the command line."
One interesting update in 2.0 is the addition of Import Hashes (imphash).If you are not familiar, imports are the functions that a piece of software calls from other files. Most of the time, imports are used to augment a program with a function from a Windows DLL. Imphashes are calculated by based on library/API names and their specific order within the executable. Imphashes are useful for tracking flavors of malware that use the same functionality but have different binaries. This addition separates Sysmon from being an augmentation of Windows event logging to a utility that is designed to analyze malware. Awesome.
2.0 also comes with 5 new events:
Event ID 4: Sysmon service state changed
The service state change event reports the state of the Sysmon service (started or stopped).
<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event"> <System> <Provider Name="Microsoft-Windows-Sysmon" Guid="{5770385F-C22A-43E0-BF4C-06F5698FFBD9}" /> <EventID>4</EventID> <Version>1</Version> <Level>4</Level> <Task>4</Task> <Opcode>0</Opcode> <Keywords>0x8000000000000000</Keywords> <TimeCreated SystemTime="2015-01-21T16:54:43.336928400Z" /> <EventRecordID>216242</EventRecordID> <Correlation /> <Execution ProcessID="1112" ThreadID="1168" /> <Channel>Microsoft-Windows-Sysmon/Operational</Channel> <Computer>WIN-RKSC06DQ86F</Computer> <Security UserID="S-1-5-18" /> </System> <EventData> <Data Name="State">Started</Data> </EventData> </Event>
Event ID 5: Process terminated
The process terminate event reports when a process terminates. It provides the UtcTime, ProcessGuid and ProcessId of the process.
<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event"> <System> <Provider Name="Microsoft-Windows-Sysmon" Guid="{5770385F-C22A-43E0-BF4C-06F5698FFBD9}" /> <EventID>5</EventID> <Version>1</Version> <Level>4</Level> <Task>5</Task> <Opcode>0</Opcode> <Keywords>0x8000000000000000</Keywords> <TimeCreated SystemTime="2015-01-21T17:00:43.600396700Z" /> <EventRecordID>277158</EventRecordID> <Correlation /> <Execution ProcessID="1112" ThreadID="1332" /> <Channel>Microsoft-Windows-Sysmon/Operational</Channel> <Computer>WIN-RKSC06DQ86F</Computer> <Security UserID="S-1-5-18" /> </System> <EventData> <Data Name="UtcTime">1/21/2015 05:00:43.481 PM</Data> <Data Name="ProcessGuid">{FF1717CF-DB0B-54BF-0000-001015761600}</Data> <Data Name="ProcessId">10096</Data> </EventData> </Event>
Event ID 6: Driver loaded
The driver loaded events provides information about a driver being loaded on the system. The configured hashes are provided as well as signature information. The signature is done asynchronously for performance reasons and indicates if the file was removed after loading.
<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event"> <System> <Provider Name="Microsoft-Windows-Sysmon" Guid="{5770385F-C22A-43E0-BF4C-06F5698FFBD9}" /> <EventID>6</EventID> <Version>1</Version> <Level>4</Level> <Task>6</Task> <Opcode>0</Opcode> <Keywords>0x8000000000000000</Keywords> <TimeCreated SystemTime="2015-01-21T16:54:54.924095100Z" /> <EventRecordID>218132</EventRecordID> <Correlation /> <Execution ProcessID="1112" ThreadID="1336" /> <Channel>Microsoft-Windows-Sysmon/Operational</Channel> <Computer>WIN-RKSC06DQ86F</Computer> <Security UserID="S-1-5-18" /> </System> <EventData> <Data Name="UtcTime">1/21/2015 04:54:47.299 PM</Data> <Data Name="ImageLoaded">C:\Windows\System32\drivers\WdNisDrv.sys</Data> <Data Name="HashType">SHA1,MD5,SHA256,IMPHASH</Data> <Data Name="Hash">9F469B3BA78F83D1F8B73B4F6EFD365F92A89786,282E7D46310338FF4A6B7680440EB0DA,04242798DD82F583154AEA3D775C9BFD574FC471D01CDEB9D070872425094D82,FEC15D772A16260D523B3D2E2797F735</Data> <Data Name="Signed">true</Data> <Data Name="Signature">Microsoft Windows</Data> </EventData> </Event>
Event ID 7: Image loaded
The image loaded event logs when a module is loaded in a specific process. This event is disabled by default and needs to be configured with the –l option. It indicates the process in which the module is loaded, hashes and signature information. The signature is done asynchronously for performance reasons and indicates if the file was removed after loading. This event should be configured carefully, as monitoring all image load events will generate a large number of events.
<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event"> <System> <Provider Name="Microsoft-Windows-Sysmon" Guid="{5770385F-C22A-43E0-BF4C-06F5698FFBD9}" /> <EventID>7</EventID> <Version>1</Version> <Level>4</Level> <Task>7</Task> <Opcode>0</Opcode> <Keywords>0x8000000000000000</Keywords> <TimeCreated SystemTime="2015-01-21T17:00:43.977452900Z" /> <EventRecordID>277336</EventRecordID> <Correlation /> <Execution ProcessID="1112" ThreadID="1332" /> <Channel>Microsoft-Windows-Sysmon/Operational</Channel> <Computer>WIN-RKSC06DQ86F</Computer> <Security UserID="S-1-5-18" /> </System> <EventData> <Data Name="UtcTime">1/21/2015 05:00:43.789 PM</Data> <Data Name="ProcessGuid">{FF1717CF-DB37-54BF-0000-001008982000}</Data> <Data Name="ProcessId">41744</Data> <Data Name="Image">C:\Windows\System32\cmd.exe</Data> <Data Name="ImageLoaded">C:\Windows\System32\advapi32.dll</Data> <Data Name="HashType">SHA1,MD5,SHA256,IMPHASH</Data> <Data Name="Hash">C446DE5692D5CA9B7DAEE0F0A48FC6A575F8FE3A,561F1AB95F4F01C691BDABA5FD5C67FC,4C6184C1A72B2F84BB1CA5A72F89CC44F9F37FF225D834EBCEFF26F820635BED,973A8CDB39A3DB10C284AFB640B793B3</Data> <Data Name="Signed">true</Data> <Data Name="Signature">Microsoft Windows</Data> </EventData> </Event>
Event ID 255: Error
This event is generated when an error occurred within Sysmon. They can happen if the system is under heavy load and certain tasked could not be performed or a bug exists in the Sysmon service.
<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event"> <System> <Provider Name="Microsoft-Windows-Sysmon" Guid="{5770385F-C22A-43E0-BF4C-06F5698FFBD9}" /> <EventID>255</EventID> <Version>1</Version> <Level>2</Level> <Task>255</Task> <Opcode>0</Opcode> <Keywords>0x8000000000000000</Keywords> <TimeCreated SystemTime="2015-01-21T17:00:44.001453300Z" /> <EventRecordID>278772</EventRecordID> <Correlation /> <Execution ProcessID="1112" ThreadID="1332" /> <Channel>Microsoft-Windows-Sysmon/Operational</Channel> <Computer>WIN-RKSC06DQ86F</Computer> <Security UserID="S-1-5-18" /> </System> <EventData> <Data Name="ID">DriverCommunication</Data> <Data Name="Description">Failed to retrieve events (Last error: Insufficient system resources exist to complete the requested service.).</Data> </EventData> </Event>
Took me a second to get Sysmon to throw an error like this. It is worthy to note that, from my observations, Sysmon is not prone to error under normal use. In case anyone is wondering how to make Sysmon barf (along with the rest of the computer) I used an old school fork logic bomb batch script as a means to an end. Drop this into a batch file and run it.  You have been told.
:START start %~dp0%~n0%~x0 %~dp0%~n0%~x0|%~dp0%~n0%~x0 GOTO START
I am sure there are more elegant ways but this was the first idea that came to mind that worked.
Sysmon 2.0 also has a filtering feature that I will cover in the next post.


Collector Yumi:
So, did the Starstones do the trick? Did the golem come to life?
Tell her about the conversation with Atlanta.


|
SideCar
|
Representation of an FFT processing step. More...
#include </Users/howes/src/sidecar/GUI/Spectrum/WorkRequest.h>
Public Slots | |
| void | setGateStart (int value) |
| void | setInputSmoothing (int value) |
| void | setZeroPad (bool value) |
Public Member Functions | |
| WorkRequest (const WeightWindow &weightWindow) | |
| Constructor for the first or 'master' WorkRequest object. More... | |
| WorkRequest (const WorkRequest &master) | |
| Constructor for 'slave' WorkRequest objects (all but the first). More... | |
| ~WorkRequest () | |
| Destructor. More... | |
| void | clear () |
| Reset the counter of accumulated input messages. | |
| int | getAccumulated () const |
| bool | addData (const Messages::Video::Ref &msg) |
| size_t | getFFTSize () const |
| void | execute () |
| const fftw_complex * | getOutput () const |
| const Messages::Video::Ref & | getLastMessage () const |
Static Public Member Functions | |
| static Logger::Log & | Log () |
| Log device to use for WorkRequest log messages. More... | |
Representation of an FFT processing step.
Accumulates input data that will be used for an FFT, as well as the results of an FFT calculation.
Definition at line 21 of file WorkRequest.h.
| WorkRequest::WorkRequest | ( | const WeightWindow & | weightWindow | ) |
Constructor for the first or 'master' WorkRequest object.
This object will create a FFTW3 plan for use by all other WorkRequest objects to efficiently perform their FFT calculations.
| weightWindow | the WeightWindow object to use for input sample shaping. Also defines the FFT size. |
| gateStart | the first sample in the input data to use for the FFT |
| smoothing | number of input messages to accumulate and average before submitting to an FFT. |
Definition at line 18 of file WorkRequest.cc.
References SideCar::GUI::Spectrum::App::GetApp().
| WorkRequest::WorkRequest | ( | const WorkRequest & | master | ) |
Constructor for 'slave' WorkRequest objects (all but the first).
| master | defintion to copy |
Definition at line 41 of file WorkRequest.cc.
References SideCar::GUI::Spectrum::App::GetApp().
| WorkRequest::~WorkRequest | ( | ) |
Destructor.
If the master WorkRequest, destroys the FFTW3 plan object.
Definition at line 61 of file WorkRequest.cc.
|
static |
Log device to use for WorkRequest log messages.
Definition at line 12 of file WorkRequest.cc.
References Logger::Log::Find().
Referenced by ~WorkRequest().


Today is the last day of our family of two. This weekend, my daughter will be born. My wife is 39 weeks pregnant today. We’ve been busily preparing our home for the arrival of our daughter, who happens to be the first girl born in either family since Lindsey. We’ve been blessed with support from our families and we wouldn’t have been able to ... Read more 13 Sep 2013 - 1 minute read
I used to write a lot. It wrote about day-to-day. I wrote about wins and losses, living, learning, and people. I haven’t written that way in a long time. I want to change that. I wrote, what seems like ages ago, about a shift in my career. I left the classroom. It was one of the hardest decisions I’ve ever had to make, and now, six months lat... Read more 11 Sep 2013 - 2 minute read
When the Camtasia Mac update came out a few years ago, I was intrigued by the new sketch motion callouts included in the media.  They were cool, but I quickly wanted the ability to create my own custom callout for my videos. Using some Camta... Read more 17 Aug 2013 - 1 minute read
A year ago, I discovered If This Then That (IFTTT), which might be one of the most innovated web services I’ve ever come across. Ever. In short, it allows you to create simple programs that help manage things you do on the web. If you use the Internet a lot, you should use IFTTT. Like, today. I started with some simple scripts to do things lik... Read more 14 Aug 2013 - 3 minute read
My computer is getting pretty full of photos. I’ve been taking more, but it is also housing nearly every photo taken since my wedding in 2009. I know that is chump change to a lot of people, but it’s been bugging me. I was going back through some of my kitchen remodel photos from earlier this spring and…well…I don’t know how I missed it, but so... Read more 02 Aug 2013 - 1 minute read
Leading up to the headless ds106 planned for this fall, it’s an August GIF-a-thon. I managed to find some time tonight to get one finished and uploaded. What you see below is a reconstruction of what really happened. We were able to get to the doctor in time to reduce the chance of major scarring. Today, you can barely even tell this occurred. ... Read more 01 Aug 2013 - less than 1 minute read
Two or three weeks ago, I was home alone, tasked with priming the new drywall in my kitchen. I decided to geek it up a little bit and film the entire process so I could come back and time lapse the work. I tried using a couple different time lapse apps, but I didn’t really like the quality of the tests I did. So, I ended up filming on my iPad a... Read more 30 Jul 2013 - less than 1 minute read
I was at EdCampBLC this morning in a session talking about “transformative change,” whatever that means. A lot of the discussion focused on how we can use technology to bring change into classrooms, and my mind kept sitting on the fact that there are mental barriers to change that we overlook, and in turn lose people, because of the high-level g... Read more 22 Jul 2013 - 2 minute read
I came across something so absurd, and so initially shocking, I almost thought it was a joke. Unfortunately, it isn’t. Yes, ladies and gentlemen, we have reached a new height in absurd uses of technology. I give you: TeachLIVE. TeachLIVE: We standardize the students for you! The name itself is a joke because there is no teac... Read more 28 Jun 2013 - 2 minute read
My schedule has been picking up like crazy, and I’m afraid this may be my last ds106 post for the summer semester. Maybe I can get one or two more assignments in, but I don’t think it’s going to happen. That being said, it’s time to clear the air. I know Alan posted that he is the creator of @IAmTalkyTina, but I’m here to set the record straig... Read more 13 Jun 2013 - 1 minute read


firstByte is an organization founded in 2017, incubated from the team behind Hack Arizona, that is dedicated to providing free technology education. We are volunteers from the University of Arizona who believe anyone can be a programmer with the right guidance. Let us help you take your "first byte" of coding!
We partner with Hack Arizona to equip hackers with the skills they need to create a successful projects, regardless of their previous experience. This includes subjects like coding fundamentals, web development, and more experienced topics like machine learning and artificial intelligence.
We visit high schools and middle schools in the Tucson area to introduce students to programming and show them the many possibilities it unlocks. We hope to inspire interest in technology and higher education in young people, especially those with fewer opportunities.
To schedule a workshop in your classroom, click here


Things to keep in mind before you begin a prenatal exercise regimen
Give your body adequate rest period or recovery time and do not over do any for of exercise that would prove to be detrimental to the baby, yourself or both.
By Dr Vanshika Gupta Adukia
Staying physically active during pregnancy comes with its sets of advantages; stress reduction, increased energy, improved posture, better digestion, increased strength and endurance along with stamina to sustain labour.
However, not every pregnancy may allow one to indulge in exercise through the gestational phase. Certain risk factors may prevent or limit your activities and it is important to check with your healthcare provider before beginning an exercise regime post conception.
Sometimes exercise during pregnancy may be forbidden to protect the health of the mother, baby or both. Ensure you have your healthcare practitioner in the loop before you start, continue or change any workout regimen.
The American College of Obstetricians and Gynecologists (ACOG) has ruled out exercise if you have the following conditions when pregnant:
- Heart disease
- Lung disease
- Cervical insufficiency or weakening: The cervix begins to dilate (widen) and efface (thin) before the pregnancy has reached term.
- Cervical cerclage/cervical stitch: Treatment for cervical weakness, when the cervix starts to shorten and open too early during a pregnancy.
- Multiple gestation (for example twins, triplets), if you’re at a risk for preterm labour.
- Persistent second or third trimester bleeding.
- Ruptured membranes: Your water may have broken draining/leaking amniotic fluid.
- Placenta Previa or low lying placenta after 26 weeks: Increases chances of preterm labor or placental detachment.
- Severe anaemia
- Pre-eclampsia or pregnancy induced hypertension
If you’ve been exercising throughout pregnancy but have still wondered what ‘red flags’ to watch out for that would indicate you need to stop exercising, consider the following as warning signs:
- Preterm labour or having repeated contractions.
- Sudden gush or trickling of fluid from vagina.
- Vaginal bleeding.
- Feeling nauseous or dizzy.
- Pain in the belly or vaginal area.
- Excessive shortness of breath or chest pain.
- Headaches after exercise.
- Sudden swelling or puffiness of hands, feet or face.
- Noticeable and sudden drop in foetal movement.
- Severe weakness or fatigue that was previously not present post a workout.
Keep in mind the following guidelines:
- Consult your doctor before you begin or modify an exercise routine.
- Be sure to stretch, warm up and cool down with every exercise session.
- Keep yourself well hydrated through the exercise session and take breaks as required.
- Always eat a small meal 45 minutes to an hour before your workout session to prevent your sugar from falling and a sudden energy crash.

- Use caution with activities that may impact your joints as during pregnancy joints are more loose and prone to injury.
- Exercises may need to be modified as per your balance requirements. The growing belly shifts your centre of gravity and makes it easier to fall.
- Pay attention to your body and listen to signs so as to slow down or stop when needed.

Give your body adequate rest period or recovery time and do not over do any for of exercise that would prove to be detrimental to the baby, yourself or both.
(The writer is a pregnancy, childbirth, lactation specialist and pelvic floor physiotherapist.)


ACME Coding Bootcamp
Add New Candidates:
Name:
School attended:
*Enter "Self Taught" if no school.
Programing languages:
Submit
Reset Form


MODIFICATION HISTORY:
Ver Who Date Changes ----- ---- -------- ------------------------------------------------------- 1.00a rpm 11/07/03 Added InSwap/OutSwap routines for endian conversion 1.01a ecm 02/24/06 CR225908 corrected the extra curly braces in macros and bumped version to 1.01.a. 2.11a mta 03/21/07 Updated to new coding style.
#include "xio.h"
#include "xil_types.h"
#include "xil_assert.h"
Functions | |
| void | XIo_EndianSwap16 (u16 Source, u16 *DestPtr) |
| void | XIo_EndianSwap32 (u32 Source, u32 *DestPtr) |
| u16 | XIo_InSwap16 (XIo_Address InAddress) |
| u32 | XIo_InSwap32 (XIo_Address InAddress) |
| void | XIo_OutSwap16 (XIo_Address OutAddress, u16 Value) |
| void | XIo_OutSwap32 (XIo_Address OutAddress, u32 Value) |
|
|
Performs a 16-bit endian converion.
|
|
|
Performs a 32-bit endian converion.
|
|
|
Performs an input operation for a 16-bit memory location by reading from the specified address and returning the byte-swapped value read from that address.
|
|
|
Performs an input operation for a 32-bit memory location by reading from the specified address and returning the byte-swapped value read from that address.
|
|
|
Performs an output operation for a 16-bit memory location by writing the specified value to the the specified address. The value is byte-swapped before being written.
|
|
|
Performs an output operation for a 32-bit memory location by writing the specified value to the the specified address. The value is byte-swapped before being written.
|


Variables
A
A: (Anonymous function) = htmlTagWrapper("a")
Abbr
Abbr: (Anonymous function) = htmlTagWrapper("abbr")
Address
Address: (Anonymous function) = htmlTagWrapper("address")
Area
Area: (Anonymous function) = htmlTagWrapper("area")
Article
Article: (Anonymous function) = htmlTagWrapper("article")
Aside
Aside: (Anonymous function) = htmlTagWrapper("aside")
Audio
Audio: (Anonymous function) = htmlTagWrapper("audio")
B
B: (Anonymous function) = htmlTagWrapper("b")
Base
Base: (Anonymous function) = htmlTagWrapper("base")
Bdi
Bdi: (Anonymous function) = htmlTagWrapper("bdi")
Bdo
Bdo: (Anonymous function) = htmlTagWrapper("bdo")
Blockquote
Blockquote: (Anonymous function) = htmlTagWrapper("blockquote")
Body
Body: (Anonymous function) = htmlTagWrapper("body")
Br
Br: (Anonymous function) = htmlTagWrapper("br")
Button
Button: (Anonymous function) = htmlTagWrapper("button")
Canvas
Canvas: (Anonymous function) = htmlTagWrapper("canvas")
Caption
Caption: (Anonymous function) = htmlTagWrapper("caption")
Cite
Cite: (Anonymous function) = htmlTagWrapper("cite")
Code
Code: (Anonymous function) = htmlTagWrapper("code")
Col
Col: (Anonymous function) = htmlTagWrapper("col")
Colgroup
Colgroup: (Anonymous function) = htmlTagWrapper("colgroup")
Comment
Comment: (Anonymous function) = htmlTagWrapper("!--...--")
Data
Data: (Anonymous function) = htmlTagWrapper("data")
Datalist
Datalist: (Anonymous function) = htmlTagWrapper("datalist")
Dd
Dd: (Anonymous function) = htmlTagWrapper("dd")
Del
Del: (Anonymous function) = htmlTagWrapper("del")
Details
Details: (Anonymous function) = htmlTagWrapper("details")
Dfn
Dfn: (Anonymous function) = htmlTagWrapper("dfn")
Dialog
Dialog: (Anonymous function) = htmlTagWrapper("dialog")
Div
Div: (Anonymous function) = htmlTagWrapper("div")
Dl
Dl: (Anonymous function) = htmlTagWrapper("dl")
Doctype
Doctype: (Anonymous function) = htmlTagWrapper("!DOCTYPE")
Dt
Dt: (Anonymous function) = htmlTagWrapper("dt")
Em
Em: (Anonymous function) = htmlTagWrapper("em")
Embed
Embed: (Anonymous function) = htmlTagWrapper("embed")
Fieldset
Fieldset: (Anonymous function) = htmlTagWrapper("fieldset")
Figcaption
Figcaption: (Anonymous function) = htmlTagWrapper("figcaption")
Figure
Figure: (Anonymous function) = htmlTagWrapper("figure")
Footer
Footer: (Anonymous function) = htmlTagWrapper("footer")
Form
Form: (Anonymous function) = htmlTagWrapper("form")
H1
H1: (Anonymous function) = htmlTagWrapper("h1")
H2
H2: (Anonymous function) = htmlTagWrapper("h2")
H3
H3: (Anonymous function) = htmlTagWrapper("h3")
H4
H4: (Anonymous function) = htmlTagWrapper("h4")
H5
H5: (Anonymous function) = htmlTagWrapper("h5")
H6
H6: (Anonymous function) = htmlTagWrapper("h6")
Head
Head: (Anonymous function) = htmlTagWrapper("head")
Header
Header: (Anonymous function) = htmlTagWrapper("header")
Hgroup
Hgroup: (Anonymous function) = htmlTagWrapper("hgroup")
Hr
Hr: (Anonymous function) = htmlTagWrapper("hr")
Html
Html: (Anonymous function) = htmlTagWrapper("html")
I
I: (Anonymous function) = htmlTagWrapper("i")
Iframe
Iframe: (Anonymous function) = htmlTagWrapper("iframe")
Img
Img: (Anonymous function) = htmlTagWrapper("img")
Input
Input: (Anonymous function) = htmlTagWrapper("input")
Ins
Ins: (Anonymous function) = htmlTagWrapper("ins")
Kbd
Kbd: (Anonymous function) = htmlTagWrapper("kbd")
Keygen
Keygen: (Anonymous function) = htmlTagWrapper("keygen")
Label
Label: (Anonymous function) = htmlTagWrapper("label")
Legend
Legend: (Anonymous function) = htmlTagWrapper("legend")
Li
Li: (Anonymous function) = htmlTagWrapper("li")
Link
Link: (Anonymous function) = htmlTagWrapper("link")
Main
Main: (Anonymous function) = htmlTagWrapper("main")
Map
Map: (Anonymous function) = htmlTagWrapper("map")
Mark
Mark: (Anonymous function) = htmlTagWrapper("mark")
Menu
Menu: (Anonymous function) = htmlTagWrapper("menu")
Menuitem
Menuitem: (Anonymous function) = htmlTagWrapper("menuitem")
Meta
Meta: (Anonymous function) = htmlTagWrapper("meta")
Meter
Meter: (Anonymous function) = htmlTagWrapper("meter")
Nav
Nav: (Anonymous function) = htmlTagWrapper("nav")
Noscript
Noscript: (Anonymous function) = htmlTagWrapper("noscript")
Object
Object: (Anonymous function) = htmlTagWrapper("object")
Ol
Ol: (Anonymous function) = htmlTagWrapper("ol")
Optgroup
Optgroup: (Anonymous function) = htmlTagWrapper("optgroup")
Option
Option: (Anonymous function) = htmlTagWrapper("option")
Output
Output: (Anonymous function) = htmlTagWrapper("output")
P
P: (Anonymous function) = htmlTagWrapper("p")
Param
Param: (Anonymous function) = htmlTagWrapper("param")
Pre
Pre: (Anonymous function) = htmlTagWrapper("pre")
Progress
Progress: (Anonymous function) = htmlTagWrapper("progress")
Q
Q: (Anonymous function) = htmlTagWrapper("q")
Rb
Rb: (Anonymous function) = htmlTagWrapper("rb")
Rp
Rp: (Anonymous function) = htmlTagWrapper("rp")
Rt
Rt: (Anonymous function) = htmlTagWrapper("rt")
Rtc
Rtc: (Anonymous function) = htmlTagWrapper("rtc")
Ruby
Ruby: (Anonymous function) = htmlTagWrapper("ruby")
S
S: (Anonymous function) = htmlTagWrapper("s")
Samp
Samp: (Anonymous function) = htmlTagWrapper("samp")
Script
Script: (Anonymous function) = htmlTagWrapper("script")
Section
Section: (Anonymous function) = htmlTagWrapper("section")
Select
Select: (Anonymous function) = htmlTagWrapper("select")
Small
Small: (Anonymous function) = htmlTagWrapper("small")
Source
Source: (Anonymous function) = htmlTagWrapper("source")
Span
Span: (Anonymous function) = htmlTagWrapper("span")
Strong
Strong: (Anonymous function) = htmlTagWrapper("strong")
Style
Style: (Anonymous function) = htmlTagWrapper("style")
Sub
Sub: (Anonymous function) = htmlTagWrapper("sub")
Summary
Summary: (Anonymous function) = htmlTagWrapper("summary")
Sup
Sup: (Anonymous function) = htmlTagWrapper("sup")
Table
Table: (Anonymous function) = htmlTagWrapper("table")
Tbody
Tbody: (Anonymous function) = htmlTagWrapper("tbody")
Td
Td: (Anonymous function) = htmlTagWrapper("td")
Template
Template: (Anonymous function) = htmlTagWrapper("template")
Textarea
Textarea: (Anonymous function) = htmlTagWrapper("textarea")
Tfoot
Tfoot: (Anonymous function) = htmlTagWrapper("tfoot")
Th
Th: (Anonymous function) = htmlTagWrapper("th")
Thead
Thead: (Anonymous function) = htmlTagWrapper("thead")
Time
Time: (Anonymous function) = htmlTagWrapper("time")
Title
Title: (Anonymous function) = htmlTagWrapper("title")
Tr
Tr: (Anonymous function) = htmlTagWrapper("tr")
Track
Track: (Anonymous function) = htmlTagWrapper("track")
U
U: (Anonymous function) = htmlTagWrapper("u")
Ul
Ul: (Anonymous function) = htmlTagWrapper("ul")
Var
Var: (Anonymous function) = htmlTagWrapper("var")
Video
Video: (Anonymous function) = htmlTagWrapper("video")
Wbr
Wbr: (Anonymous function) = htmlTagWrapper("wbr")


| 类和说明 |
|---|
| ProgressCallback
This interface can be implemented to return progress information from the file generation process.
|
| 类和说明 |
|---|
| FullyQualifiedTable
The Class FullyQualifiedTable.
|
| GeneratedFile
Abstract class that holds information common to all generated files.
|
| GeneratedJavaFile
The Class GeneratedJavaFile.
|
| GeneratedXmlFile
The Class GeneratedXmlFile.
|
| IntrospectedColumn
This class holds information about an introspected column.
|
| IntrospectedTable
Base class for all code generator implementations.
|
| IntrospectedTable.InternalAttribute |
| IntrospectedTable.TargetRuntime |
| JavaFormatter
Objects implementing this interface are used to convert the internal
representation of the Java DOM classes into a string suitable for
saving to the file system.
|
| Plugin
This interface defines methods that will be called at different times during
the code generation process.
|
| Plugin.ModelClassType |
| ProgressCallback
This interface can be implemented to return progress information from the file generation process.
|
| ShellCallback
This interface defines methods that a shell should support to enable
the generator
to work.
|
| XmlFormatter
Objects implementing this interface are used to convert the internal
representation of the XML DOM classes into a string suitable for
saving to the file system.
|
| 类和说明 |
|---|
| JavaFormatter
Objects implementing this interface are used to convert the internal
representation of the Java DOM classes into a string suitable for
saving to the file system.
|
| XmlFormatter
Objects implementing this interface are used to convert the internal
representation of the XML DOM classes into a string suitable for
saving to the file system.
|
| 类和说明 |
|---|
| IntrospectedColumn
This class holds information about an introspected column.
|
| IntrospectedTable
Base class for all code generator implementations.
|
| ProgressCallback
This interface can be implemented to return progress information from the file generation process.
|
| 类和说明 |
|---|
| GeneratedJavaFile
The Class GeneratedJavaFile.
|
| GeneratedXmlFile
The Class GeneratedXmlFile.
|
| IntrospectedColumn
This class holds information about an introspected column.
|
| IntrospectedTable
Base class for all code generator implementations.
|
| ProgressCallback
This interface can be implemented to return progress information from the file generation process.
|
| 类和说明 |
|---|
| DAOMethodNameCalculator
This interface is used to supply names for DAO methods.
|
| 类和说明 |
|---|
| CommentGenerator
Implementations of this interface are used to generate comments for the
various artifacts.
|
| IntrospectedTable
Base class for all code generator implementations.
|
| 类和说明 |
|---|
| IntrospectedColumn
This class holds information about an introspected column.
|
| 类和说明 |
|---|
| GeneratedJavaFile
The Class GeneratedJavaFile.
|
| GeneratedXmlFile
The Class GeneratedXmlFile.
|
| IntrospectedColumn
This class holds information about an introspected column.
|
| IntrospectedTable
Base class for all code generator implementations.
|
| ProgressCallback
This interface can be implemented to return progress information from the file generation process.
|
| 类和说明 |
|---|
| IntrospectedColumn
This class holds information about an introspected column.
|
| 类和说明 |
|---|
| IntrospectedColumn
This class holds information about an introspected column.
|
| 类和说明 |
|---|
| CommentGenerator
Implementations of this interface are used to generate comments for the
various artifacts.
|
| GeneratedJavaFile
The Class GeneratedJavaFile.
|
| GeneratedXmlFile
The Class GeneratedXmlFile.
|
| JavaFormatter
Objects implementing this interface are used to convert the internal
representation of the Java DOM classes into a string suitable for
saving to the file system.
|
| Plugin
This interface defines methods that will be called at different times during
the code generation process.
|
| ProgressCallback
This interface can be implemented to return progress information from the file generation process.
|
| XmlFormatter
Objects implementing this interface are used to convert the internal
representation of the XML DOM classes into a string suitable for
saving to the file system.
|
| 类和说明 |
|---|
| CommentGenerator
Implementations of this interface are used to generate comments for the
various artifacts.
|
| ConnectionFactory |
| DAOMethodNameCalculator
This interface is used to supply names for DAO methods.
|
| FullyQualifiedTable
The Class FullyQualifiedTable.
|
| GeneratedJavaFile
The Class GeneratedJavaFile.
|
| GeneratedXmlFile
The Class GeneratedXmlFile.
|
| IntrospectedColumn
This class holds information about an introspected column.
|
| IntrospectedTable
Base class for all code generator implementations.
|
| JavaFormatter
Objects implementing this interface are used to convert the internal
representation of the Java DOM classes into a string suitable for
saving to the file system.
|
| JavaTypeResolver
This interface describes methods that are required in any Java type resolver.
|
| Plugin
This interface defines methods that will be called at different times during
the code generation process.
|
| Plugin.ModelClassType |
| ProgressCallback
This interface can be implemented to return progress information from the file generation process.
|
| ShellCallback
This interface defines methods that a shell should support to enable
the generator
to work.
|
| XmlFormatter
Objects implementing this interface are used to convert the internal
representation of the XML DOM classes into a string suitable for
saving to the file system.
|
| 类和说明 |
|---|
| IntrospectedTable
Base class for all code generator implementations.
|
| JavaTypeResolver
This interface describes methods that are required in any Java type resolver.
|
| 类和说明 |
|---|
| IntrospectedTable
Base class for all code generator implementations.
|
| 类和说明 |
|---|
| IntrospectedColumn
This class holds information about an introspected column.
|
| JavaTypeResolver
This interface describes methods that are required in any Java type resolver.
|
| 类和说明 |
|---|
| IntrospectedColumn
This class holds information about an introspected column.
|
| IntrospectedTable
Base class for all code generator implementations.
|
| 类和说明 |
|---|
| GeneratedXmlFile
The Class GeneratedXmlFile.
|
| IntrospectedColumn
This class holds information about an introspected column.
|
| IntrospectedTable
Base class for all code generator implementations.
|
| Plugin
This interface defines methods that will be called at different times during
the code generation process.
|
| Plugin.ModelClassType |
| PluginAdapter
This class includes no-operation methods for almost every method in the
Plugin interface.
|
| 类和说明 |
|---|
| CommentGenerator
Implementations of this interface are used to generate comments for the
various artifacts.
|
| IntrospectedTable
Base class for all code generator implementations.
|
| ProgressCallback
This interface can be implemented to return progress information from the file generation process.
|
| 类和说明 |
|---|
| IntrospectedColumn
This class holds information about an introspected column.
|
| IntrospectedTable
Base class for all code generator implementations.
|
Copyright © 2006–2021 MyBatis.org. All rights reserved.


We enhance systems!
- engineer dynamic architectures
- seize killer e-markets
- integrate best-of-breed models
- recontextualize rich vortals
- embrace open-source experiences
- matrix scalable users
- facilitate plug-and-play initiatives
- matrix sticky technologies


apps
toolsets
frameworks
explore
share
contribute
Plan
Implement
Execute
Challenges
Benefits
Already had a lot of stuff out there...
So what did we do?
Esri is a very large organization
coolest
largest
popular
relatively easy
support for organizations
tons of features
api
GitHub for Organizations
Free for everyone!
Monthly plan.
learn platform
work-flows
incubation
Membership 101
GitHub has some interesting behaviors...
What happens when you transfer a repo?
Lose ownership
How can you see all private repos?
All Members Team
How do you contact all members?
GET /teams/:id/members
[
{
"login": "octocat",
"id": 1,
"avatar_url": "https://github.com/images/error/octocat_happy.gif",
"gravatar_id": "somehexcode",
"url": "https://api.github.com/users/octocat"
}
]
GET /users/:user
{
...
"email"<EMAIL_ADDRESS>...
}
Publishing Workflow
Git is not easy to use... at first...

Why can't I merge?
Rebase what?
Source Tree
You will do one of three things
1. Steal Code
2. Submit Code
3. Contribute Code
Repo Standards
repo-name-language
e.g. arcgis-flex-viewer
e.g. quickstart-map-js
<140 characters
e.g. ArcGIS JavaScript mapping app to get you started fast.
README.md
There's nothing worse that a bad README.md!
Description
Features
Instructions
Requirements
Resources
Issues
Contributing
Licensing
the ultimate README.md!
Contributions
Contribute
Issues
Licensing
Esri welcomes contributions from anyone and everyone. Please see our
[guidelines for contributing](https://github.com/esri/contributing).
Support
receive notification
issues, comments, pull requests
action
Viewing Apps Live
gh-pages
esri demoserver
Your Web Presence
esri.github.io
Dynamic Build
require "json"
require "yaml"
require "hashie"
require "rest-client"
require "erb"
# Get repos - Limited to 5000 requests per hour
@repo_array = JSON.parse(RestClient.get(@base_url+"/orgs/esri/repos?type=public&page=1&per_page=100", content_type: :json))
@repos ||= @repo_array.collect! do |repo|
if !repo["name"].nil?
# Get repo info
repo_name = repo["name"]
repo_desc = repo["description"]
repo_likes = repo["likes"]
repo_forks = repo["forks"]
# Extract README.md Esri tags
uri = URI(@base_url+"/repos/Esri/" + repo["name"] + "/contents/README.md")
repo_readme = RestClient.get(uri.to_s, content_type: :json)
if !repo_readme.nil?
repo_readme = JSON.parse(repo_readme)
content = Base64.decode64(repo_readme["content"])
if content
tags = content[/.*\(Esri Tags:(.*?)\)/,1]
tags = !tags.nil? ? tags.strip : @default_tag
language = content[/.*\(Esri Language:(.*?)\)/,1]
end
end
Hashie::Mash.new(repo)
end
README.md
...
[](Esri Tags: ArcGIS Web Mapping Leaflet)
[](Esri Language: JavaScript)
Yes, GitHub is new for some people!
Blogs
Workshops
Videos
ArcGIS Online -> GitHub
GitHub -> ArcGIS Online
Open Source Projects
ArcGIS GIS web client
Complete Source code
Very active
Geosearch place finding
ArcGIS JavaScript source
Easy to customize
JavaScript Geo library
GeoJSON, ArcGIS JSON, WKT
Geospatial operations
JavaScript mapping plug-in
ArcGIS basemaps
ArcGIS feature and map services
Discovery tool
Catalog geospatial resources
Metadata
Water Utility Network Editing
Special Event Planning
Address Data Management
Geoprocessing tools
Big data spatial analyses
geometry-api-java
arcgis-viewer-flex
arcgis-viewer-flex-builder
arcgis-osm-editor
sencha-touch-map-checkin-js
maps-app-android
driving-directions-ios
dojo-bootstrap-ui-for-maps-js
3d-cities-template
basic-storytelling-template-js
executive-dashboard
park-and-recreation-finder
citizen-service-request
terraformer
node-geoservices-adaptor/koop
geoservices-js
100 lines or less
So what can you do?
stats
and then something else happened...
Internal GitHub
Your own GitHub
SaaS
Fully featured
Core development
Website development
Wiki
Distributed
Branch and merge
Collaboration
Even support staff use GitHub!
Cross-repo normalization
Limited enterprise-level admin
LDAP for security groups
In the end...
Join us on esri.github.io


Source code for face_trigger.model.deep.FaceRecognizer
"""
Deep Learning based face recognition module.
.. moduleauthor:: Ankur Roy Chowdhury<EMAIL_ADDRESS>"""
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import logging
import os
import tqdm
import numpy as np
import dlib
import cv2
import sklearn
import time
import pkg_resources
from sklearn.preprocessing import LabelEncoder
from sklearn.metrics import accuracy_score
from sklearn.externals import joblib
from face_trigger.process.post_process import FaceDetector
[docs]class FaceRecognizer():
"""
Trains a face recognition model based on deep metric learning.
'Original paper <https://arxiv.org/abs/1503.03832>'_
"""
def __init__(self, dnn_model_path=None, classifier_model_path=None, label_map_path=None):
"""
Instantiate a FaceRecognizer object
:param dnn_model_path: path to the trainined dnn feature extractor
:type dnn_model_path: str
:param classifier_model_path: path to the trained sklearn classifier
:type classifier_model_path: str
:param label_map_path: path to the pickled label map
:type label_map_path: str
"""
self.logger = logging.getLogger(__name__)
if dnn_model_path is None:
self.logger.debug("No DNN model path specified, using default.")
dnn_model_path = pkg_resources.resource_filename(
"face_trigger", "pre_trained/dlib_face_recognition_resnet_model_v1.dat")
self.dnn_model = dlib.face_recognition_model_v1(dnn_model_path)
if classifier_model_path is not None:
self.classifier = self.load(classifier_model_path)
else:
raise Exception("No classifier model path given!")
if label_map_path is not None:
self.label_map = self.load_label_mapping(
label_map_path=label_map_path)
else:
raise Exception("No label mapping provided!")
[docs] def train(self):
"""
Train the recognizer on the training set. Not required when working with pre-trained models.
TODO: Implement the training mechanism
"""
raise NotImplementedError()
[docs] def embed(self, images=None, landmarks=None):
"""
Generates embeddings for the given images.  Alignmnet is taken care of when we generate the embeddings.
"""
assert len(images) == len(landmarks)
embeddings = []
# convert from gray to rgb
# images = np.array(images)
# images = images.reshape(images.shape + (1,))
# images = np.repeat(images, 3, axis=3)
images = [cv2.cvtColor(img, cv2.COLOR_GRAY2RGB) for img in images]
start_time = time.time()
# self.logger.debug("Start timestamp: {}".format(start_time))
embeddings = [self.dnn_model.compute_face_descriptor(
image, landmarks[i]) for i, image in enumerate(images)]
end_time = time.time() # batch:100 s: ~1.5 sec; p: n/a
# self.logger.debug("End time: {}. Runtime: {}".format(
# end_time, (end_time-start_time)))
return embeddings
[docs] def save(self, classifier_model_path):
"""
Save the trained classifier.
Call only after fitting the embeddings, otherwise will throw an exception.
:param classifier_model_path: path along with name specifiying where to save the model. Extension should be .pkl for brevity.
:type classifier_model_path: string
"""
joblib.dump(self.classifier, classifier_model_path)
[docs] def load(self, classifier_model_path):
"""
Load the saved classifier model.
:param classifier_model_path: path to the trained classifier model
:type classifier_model_path: string
"""
if not os.path.exists(classifier_model_path):
raise Exception("Path to trained classifier model does not exist!")
classifier_model_path = os.path.realpath(classifier_model_path)
return joblib.load(classifier_model_path)
[docs] def infer(self, embeddings, threshold=0.20, unknown_index=-1):
"""
Infer and return a predicted face identity.
:param embeddings: 128D face embeddings
:type embeddings: list
:param threshold: probability threshold to accept a prediction result
:type threshold: float
:param unknown_index: a integer id that denotes an unknown class
:type unknown_index: int
:returns: an identity
:rtype: int
"""
unknown = unknown_index
# get prediction probabilities across all classes for each sample
predictions = self.classifier.predict_proba(np.array(embeddings))
# get the index of the highest predicted class
prediction_indices = np.argmax(predictions, axis=1)
# get the probability of the highest predicted class
prediction_probabilities = np.max(predictions, axis=1)
self.logger.debug(
"Predicted indices before thresholding: {}".format(prediction_indices))
# get the boolean mask for all indices that have a probability less than the threshold value
thresholded_probabilities = prediction_probabilities < threshold
# extract the indices from the boolean mask
thresholded_indices = np.nonzero(thresholded_probabilities)
# set the indices below the threshold to belong to an unknown class
prediction_indices[thresholded_indices] = unknown
self.logger.debug(
"Predicted indices after thresholding: {}".format(prediction_indices))
# get the index that occured the most in the batch that was evaluated
predicted_identity = np.max(prediction_indices)
if predicted_identity != unknown:
predicted_identity = self.label_map[predicted_identity]
return predicted_identity
[docs] def load_label_mapping(self, label_map_path=None):
"""
Loads the mapping between the real labels and the ones used by sklearn during training.
:param label_map_path: path to the pickled label map
:type label_map_path: str
:returns: a dictionary mapping from encoded label to real label
:rtype: dict
"""
if not os.path.exists(label_map_path):
raise Exception("Path to label map does not exist!")
label_map_path = os.path.realpath(label_map_path)
return joblib.load(label_map_path)


 Nowadays there are only the regularly scheduled ships coming in and going out of Gludin Village, but before the troubles, when we used to trade with Gracia, there were many more ships in this port. That wretched war... I long to see this port as it used to be.
Harrumph! I think I talked too much. Would you like to buy a ticket for a ship?
Buy a ticket.
View information about the local lord and tax rate.
Quest


*
foridx
(
counter
)
This command is used to retrieve the value of a counter in a *for
cycle block.
Parameters
counter
Name of the counter whose value is to be retrieved.
Return Values
A string representing the current value of the counter.
Remarks
See the *for command.
Command Reference Index


Roasted Beet Salad
Roasted beets with balsamic vinegar dressing.
It is my favorite salad because I love learning javascript!
Ingredients
- 6 medium beets, trimmed and scrubbed
- 2 tablespoons aged balsamic vinegar
- 2 teaspoons real maple syrup
- salt and ground black pepper to taste
Directions
- Preheat the oven to 400 degrees F (200 degrees C). ♨
- Wrap beets loosely in aluminum foil and place on a rimmed baking sheet. 🧻
- Roast in the prheated oven until easily pierced with a knife or skewer, 50 to 60 minutes. ⏱
- Unwrap and cool until easily handled, about 10 minutes. 🆒
- Peel beets and cut into chunks. 🍌
- Mix vinegar and maple syrup together; season with salt and pepper. our over beets. 🎨
- Refrigerate until beets absorb the flavors, at least 1 hour. 🥶
- Serve cold. 🥗


About-
This website serves as a platform for cooks to practice and hone their cooking skills. While doing so, they may rise to fame. Our Hall of Fame will feature the top class cooks based on feedbacks by foodies.
This website also caters to requirements of foodies as they can order their food and watch there cooks being prepared by some of the best cooks in the neighbourhood.


Arduino UNO it’s the most common microcontroller in the market, but How it behaves as a DSP? In this project we explode all the posibilities of arduino as a DSP.
This device have an ADC but it don’t have a DAC, so we must use an external one. However we decide to use Pulse width Modulation. This consist on emulate an analog signal using digital pulses. PWM produces modulation noise at high frequencies but if we applicate a low pass filter we obtain the signal. In this case the filter will be the speaker.If we record the signal before playing it trough an speaker we will listen the modulation noise.
As we couldn't create audio effect due to the memory we develop an FM syntheziser with and LDR sensor. The frecuency of the modulation change with the values that we read from the sensor.


Automated tests are the best way to achieve predictable, repeatable assessments of the quality of your code. Writing automated tests for your Lightning web components gives you confidence that they work as designed, and allows you to evaluate the impact of changes like feature enhancements, refactoring, and new versions of third-party JavaScript libraries.
lts-jest
is already included in the project you setup and installed. These next steps will take you through writing your first test. We have a video walk-through available in our Pilot Chatter group monthly webinar. The second half of the video goes in-depth on testing.
Step 1
Start by ensuring you have the appropriate packages installed via npm. If you followed all the instructions this should be done but just in case run this:
Step 2
When you run lts-jest
it runs all the tests in your project. It searches within folders named __tests__. It also supports a "watch mode" where it monitors your project files for changes and runs only the impacted tests. This is a great way to see your progress in real-time. Run the following now in your terminal.
You will see the following output indicating lts-jest
has discovered all tests and identified none need to be run. When we add new tests they'll be discovered and run.
Step 3
We provided an empty test file playground.test.js in the playground/__tests__/ folder. Open that file and replace its contents with the following.
Yikes, that's a lot of code! Don't worry, we'll explain the main sections throughout this exercise, starting with the basics here. There is some code required to get the test running that isn't explained in this section, but we'll discuss it later.
The first thing you'll notice are the import
statements at the top of the file. These statements pull in dependencies for our test, including the component we're currently testing. The first import, { createElement } from 'engine'
, creates our component under test. We then import our playground component. Each test case creates the component and performs verifications against it. Note how we reference the component using the namespace-componentname format
.
Let's skip to the describe
block, which is where the test logic begins. describe
blocks are used to group related tests. The beforeEach
and afterEach
functions are Jest lifecycle hooks that run before and after each test (refer to the Jest documentation for more information). Finally, after all the setup, the it
block contains our test case logic. The flow of the test is as follows:
createElement
API.
Once you save the updated playground.test.js, lts-jest
will detect the change and runs the tests. Check your terminal window for the results. Notice that we did not need to push our changes to the scratch org! These unit tests run locally, and indeed, test artifacts are excluded from being pushed to your org.
Step 4
Now let's look at how we can control data through @wire
in the test. We've added some mock data in force-app/main/default/lightningcomponents/playground/__tests__/data/record-account.json.
To use this data in the test, we'll require()
the JSON file and then pass the data through our @wire
test utility. Add the following lines above the first describe
block:
And this code after the it('sets lightning-avatar source')
block from above.
The key line from this test is getRecordWireAdapter.emit(mockGetRecord)
. This code is where we use the @wire
test utility to feed in our mock record data. We then verify the data is correctly passed to lightning-formatted-text
component.
There are more unit tests in force-app/main/default/lightningcomponents/playground_finished/__tests__/playground_finished.test.js. We recommend reviewing them.
Lightning Testing Service offers multiple strategies for testing your Lightning web components. In this exercise we focused on the unit testing tool called lts-jest. This tool simplifies unit testing using the Jest testing framework. lts-jest takes care of all necessary configuration.
Congratulations! You've just written your first Lightning Web Component and automated unit tests. Want to view more sample components? Check out these resources:


2 Chronicles 12:10
Instead of which king Rehoboam made shields of brass, and committed them to the hands of the chief of the guard, that kept the entrance of the king's house.


Town
Travel Hazards
Basic Town/Feudal Village
Each hero rolls D6. On a 1-2, roll for travel hazard.
Frontier Town Expansion
TODO: Difference between small/medium/large town.
A Day in Town
- Each hero chooses Camp or Inn
- Roll for Camp events, once per hero.
- Each hero chooses location to visit
- Roll for location events, once per hero
- Buy goods and services
- Roll for possible Town Event: D6, equal or less than day marker.
- Increase day marker by one. Or back to 1 if there was a Town Event.
- Leave town if desired.
TODO: Advanced town changes
More Dangerous Unwanted Attention
See official FAQ v1.02 for optional rule.
Feudal Village New Locations
These are class-specific locations/events.
Sumo Wrestling
See Sumo rules page 28.


Vanessa Mdee pours her heart out to Rotimi during live radio Interview
by Dennis MilimoVanessa is swimming in deep waters of love
Tanzanian Singer Vanessa Mdee has showered her new actor boyfriend Rotimi with lots of praises, stating that it only took her two days to realize that he is the man she would like to spend the rest of her life with.
In an interview with Millard Ayo, Mdee poured out her heart, revealing that he met the power actor at the Essence Festival (July) and their connection was immediate.
She went on to describe Rotimi, born Olurotimi Akinosho as a very generous person who relates well with people and understands his position in a woman’s life.
We met at the Essence Festival
The Bado hit-maker mentioned that since hooking up with the actor, a lot has changed in her life, and she is happy with the direction her love life has taken.
“Rotimi ananizdi busara sana. Ni mtu ambaye ananipa ushauri ambao sijawahi kupwewa na mtu yeyote duniani. Unaeza ukakaa naye ukatafakari maisha yako yote ulikuwa unafanya nini. Nikama ulikuwa unachelewa, unapoteza maisha, unajidhalilisha. Tulikutana Essence festival Juliy kule marekani, ambapo tulitambilswa na rafiki yetu and everything else was instant. Tulikutan ekwenye after party ya spotify and it was so strange kwa sababu sikuwahi hata kutizama power kwa muda japo najua kazi zake vizuri.  So we started talking and we talked for a long time and exchanged numbers. And it was like fresh air. He was to go sit with his fellow actors wa Power but akakuja pande yetu. Ni mtu ambaye kila nikizungumza naye naskia amani ya moyo, furaha, butterflies mpaka kesho, he was so real. It was something very special from the beginning" said Vanessa Mdee.
He is my husband to be
Vee Money disclosed that after getting to know each other for a while, they decided to go for a holiday and that’s when their affair officially kicked off.
“So we took a break na tulikubaliana kuwa hatutashika simu, just the two of us, just talk and it took me only two days kujua kuwa huyu ndio mwanaume nitakuwa naye maishani. I was like this is my husband. He has changed my life completely. He loves God, relates well with people, very generous and understands who he is, ana hekima sana. He is a very happy person, he is a very straight forward and a happy person. He is very talented, (model, singer acting)" added Vee Money.
She added that, she will be spending most of her time in the US, just to be close to Rotimi.
Rotimi is a Nigerian-American actor, singer and model. He is known for his role as Darius Morrison on the Starz series Boss and currently stars as Andre Coleman on Power.


|
Figure 1
|
Flow chart of systematic review. The procedures were adapted ... |
|
Figure 2
|
An overview of study design and data (and metadata) availabi ... |
|
Figure 3
|
( A) Geographical origin of included studies stratified by W ... |
|
Figure 4
|
Types of specimens tested in different farm animals by numbe ... |
|
Figure 5
|
An overview of virus families found in different farm animal ... |
|
Figure 6
|
Frequencies of virus genera of top three most abundant virus ... |


California Resources (CRC) Bank of America Merrill Lynch 2019 Global Energy Conference
by SA Transcripts, https://seekingalpha.com/author/sa-transcriptsThe following slide deck was published by California Resources Corporation in conjunction with this event.


The Collection
Muriel skin care journey
- Caters to all skin types
- Address all skin concerns
- To be used with warm water only
- Offers home care regime
- Customisation of product line and protocol
- Slow cost of treatments
- Available in single use kits
Marketing support
- First time client gift
- Collateral
- Employee incentive programme
- Standee
- Danglers
- Desktop
- Menu card


THE RIGHT MOVES
Copyright (c) 1988 Diversified Ventures
This game is played on the following board with the following setup (the game's original stones have two sides, a normal side and a promoted side):
- TURNS - On each turn, each player moves one of his stones
- A stone may move (along the white paths) to an adjacent empty cell to its left or right or towards the inner circle.
- There is one exception: stones may move away from the center, if they start moving in the second innermost circle.
- A stone may also jump over an adjacent enemy piece landing on the immediate next cell (which must be empty). The jumped stone is captured.
- Jumps can be multiple (including valid changes of direction) but are not mandatory.
- Promotion - a stone reaching the inner circle is promoted.
- A promoted piece can also move and jump backwards and can also 'skip'.
- Skipping is a slide over one or more empty cells along a path (including changing of directions). Jumps are not allowed during a skip move.
- GOAL - Wins the player that accomplishes one of the following: (a) occupy all 4 center cells, (b) stalemate the adversary, or (c) leave the adversary with 3 or less stones.
Some examples In [1] the blue stone cannot capture the red stone, since there is not a path between those cells.
In [2] the red stone in the outer circle can capture the blue stone. However the blue cannot capture it, since it cannot capture backwards. The same blue stone can capture counterclockwise the adjacent red stone (and the next one, if Blue wants) while that red stone cannot capture that blue (since the next cell is occupied).
The promoted stone (here a square) can skip thru cells 'a' and 'b' and move itself to [3] and making a double capture threat.
I wish to thank John Lawson for detailed information about this game.


$10 (+2 to saving throw)
$12 (late or gate sale)
Please study our Code of Conduct. All abilities granted by this ticket may be lost if the code is broken.
For twice the material components, this ticket can be cast to allow two medium or large humanoids to teleport up to three small or tiny humanoid allies into range, as long as one of the casters maintains concentration and line of sight.
$15 (+4 to saving throw)
$19 (late or gate sale)
Please study our Code of Conduct. All abilities granted by this ticket may be lost if the code is broken.
For twice the material components, this ticket can be cast to allow two medium or large humanoids to teleport up to three small or tiny humanoid allies into range, as long as one of the casters maintains concentration and line of sight.
$7 (+1 to saving throw)
$8 (late or gate sale)
Please study our Code of Conduct. All abilities granted by this ticket may be lost if the code is broken.
For twice the material components, this ticket can be cast to allow two medium or large humanoids to teleport up to three small or tiny humanoid allies into range, as long as one of the casters maintains concentration and line of sight.


|
GPGPU-Sim
|
#include <power_stat.h>
Definition at line 43 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_active_sfu_lanes[NUM_STAT_IDX] |
Definition at line 68 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_active_sp_lanes[NUM_STAT_IDX] |
Definition at line 67 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_non_rf_operands[NUM_STAT_IDX] |
Definition at line 71 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_decoded_insn[NUM_STAT_IDX] |
Definition at line 46 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_fp_acesses[NUM_STAT_IDX] |
Definition at line 52 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_FPdecoded_insn[NUM_STAT_IDX] |
Definition at line 47 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_fpdiv_acesses[NUM_STAT_IDX] |
Definition at line 59 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_fpmul_acesses[NUM_STAT_IDX] |
Definition at line 57 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_ialu_acesses[NUM_STAT_IDX] |
Definition at line 51 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_idiv_acesses[NUM_STAT_IDX] |
Definition at line 58 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_imul24_acesses[NUM_STAT_IDX] |
Definition at line 56 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_imul32_acesses[NUM_STAT_IDX] |
Definition at line 55 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_imul_acesses[NUM_STAT_IDX] |
Definition at line 54 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_INTdecoded_insn[NUM_STAT_IDX] |
Definition at line 48 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_loadqueued_insn[NUM_STAT_IDX] |
Definition at line 50 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_mem_acesses[NUM_STAT_IDX] |
Definition at line 63 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_mem_committed[NUM_STAT_IDX] |
Definition at line 66 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_sfu_acesses[NUM_STAT_IDX] |
Definition at line 61 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_sfu_committed[NUM_STAT_IDX] |
Definition at line 65 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_sp_acesses[NUM_STAT_IDX] |
Definition at line 60 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_sp_committed[NUM_STAT_IDX] |
Definition at line 64 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_storequeued_insn[NUM_STAT_IDX] |
Definition at line 49 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_tex_inst[NUM_STAT_IDX] |
Definition at line 53 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_num_trans_acesses[NUM_STAT_IDX] |
Definition at line 62 of file power_stat.h.
| float* shader_core_power_stats_pod::m_pipeline_duty_cycle[NUM_STAT_IDX] |
Definition at line 45 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_read_regfile_acesses[NUM_STAT_IDX] |
Definition at line 69 of file power_stat.h.
| unsigned* shader_core_power_stats_pod::m_write_regfile_acesses[NUM_STAT_IDX] |
Definition at line 70 of file power_stat.h.


Create the architecture of your document
You can either
Create manually below your document's architecture
import your document's architecture from a file (.csv only) :
Document information
Fill in this row :
Your document's title
Your document's collaborators
Architecture :
Use to create new parts.
Use to move a section in the architecture.
Use to delete a section and all the subparts it contains.
Use to assign someone to a part.


Firebase Web login Example
Login With Google
Welcome User
Welcome to Firebase web login Example. You're currently logged in.
Logout


Rails is a framework for the Ruby language. It is known to be an "opinionated" software. That is to say, Rails thinks it knows best. It makes assumptions about what a developer will want to do and facilitates getting to the desired result faster. The developer has to write less code than in other frameworks. It is also considered a more enjoyable environment to write in than most, according to experienced Rails developers. By defaulting to its conventions, Rails makes the developer's life easier and less tedious.


This page does not exist: Whale
This is not a link: No Spoon
This link is empty! You can't see me
This page does not exist: Petunias
This page contains more links: Crawl Me
This domain is for use in illustrative examples in documents. You may use this domain in literature without prior coordination or asking for permission: Example


Astronaut successfully pilots Earth-bound lunar rover from space
An astronaut aboard the International Space Station (ISS) has successfully piloted a prototype lunar rover down here on Earth.
The test was carried out this week with ESA astronaut Luca Parmitano taking the helm of the Analog-1 rover.
He navigated the rover around an obstacle course in the Netherlands for half an hour. One day, it is hoped that astronauts will be able to remotely pilot these rovers on the moon’s surface.
‘We are developing systems for astronauts to work hand-in-hand with robots, to achieve much more than they could on their own’ explained ESA’s project manager Kjetil Wormnes.
‘A rover on Mars would have taken weeks to do the same work Luca and the Analog-1 rover did in half an hour.’
Although autonomous robots can be used for space exploration, they will never be as accurate as human-controlled machines.
Advertisement Advertisement
The Analog-1 rover is equipped with force feedback so astronauts can feel what the robot feels and adjust grip accordingly on a joystick that allows for six degrees of motion.
ESA’s exploration strategy for the Analog-1 foresees astronauts controlling robots from orbit around the moon or Mars or from inside a planetary base.
‘Even on the Moon preparing an astronaut for a sortie takes hours just to get into a suit and prepare the airlock,’ commented Jessica Grenouilleau, the Meteron project lead at ESA’s Exploration Systems Group.
‘By giving astronauts the possibility to control the robots nearby in the safety and comfort of their base or orbital spacecraft, much more can be achieved.
‘This first test indicates an excellent adaptation between the crew and the robotic system, making this combination better at a wide range of tasks.’


ComputeThreadPool
public protocol ComputeThreadPool
Allows efficient use of multi-core CPUs by managing a fixed-size collection of threads.
From first-principles, a (CPU) compute-bound application will run at peak performance when overheads are minimized. Once enough parallelism is exposed to leverage all cores, one of the key overheads to minimize is context switching, and thead creation / destruction. The optimal system configuration is thus a fixed-size threadpool where there is exactly one thread per CPU core (or rather, hyperthread). This configuration results in zero context switching, no additional kernel calls for thread creation & deletion, and full utilization of the hardware.
Unfortunately, in practice, it is infeasible to statically schedule work apriori onto a fixed pool of threads. Even when applying the same operation to a homogenous dataset, there will inevitably be variability in execution time. (This can arise from I/O interrupts taking over a core [briefly], or page faults, or even different latencies for memory access across NUMA domains.) As a result, it is important for peak performance to build abstractions that are flexible and dynamic in their work allocation.
The ComputeThreadPool
protocol is a foundational API designed to enable efficient use of
hardware resources. There are two APIs exposed to support two kinds of parallelism. For
additional details, please see the documentation associated with each.
Note: be sure to avoid executing code on the ComputeThreadPool
that is not compute-bound. If
you are doing I/O, be sure to use a dedicated threadpool, or use
Swift NIO for high performance non-blocking I/O.
Note: while there should be only one “physical” threadpool process-wide, there can be many
virtual threadpools that compose on top of this one to allow configuration and tuning. (This is
why ComputeThreadPool
is a protocol and not static methods.) Examples of additional threadpool
abstractions could include a separate threadpool per-NUMA domain, to support different
priorities for tasks, or higher-level parallelism primitives such as “wait-groups”.
See also
ComputeThreadPools
-
Schedules
fn
to be executed in the threadpool eventually.Declaration
Swift
func dispatch(_ fn: @escaping () -> Void)
-
Executes
a
andb
optionally in parallel; both are guaranteed to have finished executing beforejoin
returns.Declaration
Swift
func join(_ a: () -> Void, _ b: () -> Void)
-
Executes
a
andb
optionally in parallel; if one throws, it is unspecified whether the other will have started or completed executing. It is also unspecified as to which error will be thrown.This is the throwing overload
Declaration
Swift
func join(_ a: () throws -> Void, _ b: () throws -> Void) throws
-
A function to be invoked in parallel a specified number of times by
parallelFor
.Declaration
Swift
typealias ParallelForBody = (_ currentInvocationIndex: Int, _ requestedInvocationCount: Int) -> Void
Parameters
currentInvocationIndex
the index of the invocation executing in the current thread.
requestedInvocationCount
the number of parallel invocations requested.
-
A function that can be executed in parallel.
Declaration
Swift
typealias ThrowingParallelForBody = (_ currentInvocationIndex: Int, _ requestedInvocationCount: Int) throws -> Void
Parameters
currentInvocationIndex
the index of the invocation executing in the current thread.
requestedInvocationCount
the number of parallel invocations requested.
-
A vectorized function that can be executed in parallel.
The first argument is the start index for the vectorized operation, and the second argument corresponds to the end of the range. The third argument contains the total size of the range.
Declaration
Swift
typealias VectorizedParallelForBody = (Int, Int, Int) -> Void
-
A vectorized function that can be executed in parallel.
The first argument is the start index for the vectorized operation, and the second argument corresponds to the end of the range. The third argument contains the total size of the range.
Declaration
Swift
typealias ThrowingVectorizedParallelForBody = (Int, Int, Int) throws -> Void
-
parallelFor(n:
Default implementation_: ) Returns after executing
fn
n
times.Default Implementation
Implements
parallelFor(n:_:)
(scalar) in terms ofparallelFor(n:_:)
(vectorized).Declaration
Swift
func parallelFor(n: Int, _ fn: ParallelForBody)
Parameters
n
The total times to execute
fn
. -
Returns after executing
fn
an unspecified number of times, guaranteeing thatfn
has been called with parameters that perfectly cover of the range0..<n
.Declaration
Swift
func parallelFor(n: Int, _ fn: VectorizedParallelForBody)
Parameters
n
The range of numbers
0..<n
to cover. -
Returns after executing
fn
n
times.Declaration
Swift
func parallelFor(n: Int, _ fn: ThrowingParallelForBody) throws
Parameters
n
The total times to execute
fn
. -
Returns after executing
fn
an unspecified number of times, guaranteeing thatfn
has been called with parameters that perfectly cover of the range0..<n
.Declaration
Swift
func parallelFor(n: Int, _ fn: ThrowingVectorizedParallelForBody) throws
Parameters
n
The range of numbers
0..<n
to cover. -
The maximum number of concurrent threads of execution supported by this thread pool.
Declaration
Swift
var maxParallelism: Int { get }
-
Returns the index of the current thread in the pool, if running on a thread-pool thread, nil otherwise.
The return value is guaranteed to be either nil, or between 0 and
parallelism
.Declaration
Swift
var currentThreadIndex: Int? { get }


CMS Alpha
Home
(current)
Hi
Signin / Signup
Calendar Management System
Results
Welcome to Calendar Management Systems!
×
Sign up and manage your own calendars!


An app in knockoutjs, shows your Neighbourhood venues.
An app in angular 1, lets you search your favorite artists/albums.
A UX design in CSS and HTML which works across devices


You need someone to capture your weeding, birthday party or one of your priceless moments? Contact us and we will make you, the most awesome video, full with unique music, glitches, animals and many more.For example, this is the promo video
made for Metropolis - Sonic Voyager pres. Rodhad and Milton Bradley.
Cars and Motorcycles Painting
You want to have a really nasty car or motorcycle. Contact with us and we will make it unique. Everyone will watch it and says "daaaaaaaaamn".
Peintures
What about a fancy and unique picture in your room. Every picture is limited and only one people in the world can have it. If you enjoy them, call us and we will send you, the one that you like the most.
Graffiti Designing
Do you like art? Art is the way that everyone portrays the world they see through their point of view. You want different garage, room, bar, disco club or wall in your house. Contact us
and we can make your dreams came true inside your bedroom.For example, this is Oxygen disco club in Bansko, Bulgaria. We customized it, the way they want.
Architecture
In case you are so inspired by DopeZoo, we can make your dream house. At first look, you think this is impossible for us, but there isn't anything that we can't do. Take a look at our sea house in Varna, Bulgaria.


Unheard is a study situated within a philosophical premise that describes a reality which is imperceptible but intelligible. Every sound is a product of the impact of one surface on the another. But what do objects sound like when they aren’t in contact with other objects and what are the sounds of objects when they are not being defined by their relationship to other objects?
My research navigates the mysteries and realities of the aural essences of my hand. An aural essence, as I define it, is an imperceptible signifier that becomes audible when coupled with the essence of another object. And sound happens when two or more essences combine. This is a journey of the methods I developed to quantify these imperceptible sounds within us.
To isolate the aural essence of my hand, I first recorded my hand interacting with different objects, surfaces, materials and textures. After this, I recorded an impulse response of the object, which gave me the unique acoustic properties of that object. This technique is commonly used to get the acoustic charachteristics of spaces, but I used it for objects.
I wrote a script in python that allowed me to perform a mathematical function called deconvolution - to remove the sound of the surface from the sound of my hand and that surface together – leaving me with the aural essence of my hand.
This was the resusltant sound that I got.
I then worked on a performance piece for which I designed and constructed wearable with a bone conduction speaker that only allows for the audiece to hear the sounds only when their bone is contact with the speaker.
Some initial sketches and prototypes of the sleeve.
Feather with an Audio Board, a LiPo Battery and a Bone Conduction Transducer.


Reducing emotional fatigue for VAD nurses.
Initiate customer requests without staff.
Facilitating an understanding of loss.