| PostgreSQL 9.0.10 Documentation | ||||
|---|---|---|---|---|
| Prev | Up | Appendix F. Additional Supplied Modules | Next |
pgbench is a simple program for running benchmark tests on PostgreSQL. It runs the same sequence of SQL commands over and over, possibly in multiple concurrent database sessions, and then calculates the average transaction rate (transactions per second). By default, pgbench tests a scenario that is loosely based on TPC-B, involving five SELECT, UPDATE, and INSERT commands per transaction. However, it is easy to test other cases by writing your own transaction script files.
Typical output from pgbench looks like:
transaction type: TPC-B (sort of) scaling factor: 10 query mode: simple number of clients: 10 number of threads: 1 number of transactions per client: 1000 number of transactions actually processed: 10000/10000 tps = 85.184871 (including connections establishing) tps = 85.296346 (excluding connections establishing)
The first six lines report some of the most important parameter settings. The next line reports the number of transactions completed and intended (the latter being just the product of number of clients and number of transactions per client); these will be equal unless the run failed before completion. The last two lines report the TPS rate, figured with and without counting the time to start database sessions.
The default TPC-B-like transaction test requires specific tables to be set up beforehand. pgbench should be invoked with the -i (initialize) option to create and populate these tables. (When you are testing a custom script, you don't need this step, but will instead need to do whatever setup your test needs.) Initialization looks like:
pgbench -i [ other-options ] dbname
where dbname is the name of the already-created database to test in. (You may also need -h, -p, and/or -U options to specify how to connect to the database server.)
| Caution |
pgbench -i creates four tables pgbench_accounts, pgbench_branches, pgbench_history, and pgbench_tellers, destroying any existing tables of these names. Be very careful to use another database if you have tables having these names! |
At the default "scale factor" of 1, the tables initially contain this many rows:
table # of rows --------------------------------- pgbench_branches 1 pgbench_tellers 10 pgbench_accounts 100000 pgbench_history 0
You can (and, for most purposes, probably should) increase the number of rows by using the -s (scale factor) option. The -F (fillfactor) option might also be used at this point.
Once you have done the necessary setup, you can run your benchmark with a command that doesn't include -i, that is
pgbench [ options ] dbname
In nearly all cases, you'll need some options to make a useful test. The most important options are -c (number of clients), -t (number of transactions), -T (time limit), and -f (specify a custom script file). See below for a full list.
Section F.23.2 shows options that are used during database initialization, while Section F.23.3 shows options that are used while running benchmarks, and Section F.23.4 shows options that are useful in both cases.
pgbench accepts the following command-line initialization arguments:
Create the pgbench_accounts, pgbench_tellers and pgbench_branches tables with the given fillfactor. Default is 100.
Required to invoke initialization mode.
Multiply the number of rows generated by the scale factor. For example, -s 100 will create 10,000,000 rows in the pgbench_accounts table. Default is 1.
pgbench accepts the following command-line benchmarking arguments:
Number of clients simulated, that is, number of concurrent database sessions. Default is 1.
Establish a new connection for each transaction, rather than doing it just once per client session. This is useful to measure the connection overhead.
Print debugging output.
Define a variable for use by a custom script (see below). Multiple -D options are allowed.
Read transaction script from filename. See below for details. -N, -S, and -f are mutually exclusive.
Number of worker threads within pgbench. Using more than one thread can be helpful on multi-CPU machines. The number of clients must be a multiple of the number of threads, since each thread is given the same number of client sessions to manage. Default is 1.
Write the time taken by each transaction to a log file. See below for details.
Protocol to use for submitting queries to the server:
simple: use simple query protocol.
extended: use extended query protocol.
prepared: use extended query protocol with prepared statements.
The default is simple query protocol. (See Chapter 46 for more information.)
Perform no vacuuming before running the test. This option is necessary if you are running a custom test scenario that does not include the standard tables pgbench_accounts, pgbench_branches, pgbench_history, and pgbench_tellers.
Do not update pgbench_tellers and pgbench_branches. This will avoid update contention on these tables, but it makes the test case even less like TPC-B.
Report the specified scale factor in pgbench's output. With the built-in tests, this is not necessary; the correct scale factor will be detected by counting the number of rows in the pgbench_branches table. However, when testing custom benchmarks (-f option), the scale factor will be reported as 1 unless this option is used.
Perform select-only transactions instead of TPC-B-like test.
Number of transactions each client runs. Default is 10.
Run the test for this many seconds, rather than a fixed number of transactions per client. -t and -T are mutually exclusive.
Vacuum all four standard tables before running the test. With neither -n nor -v, pgbench will vacuum the pgbench_tellers and pgbench_branches tables, and will truncate pgbench_history.
pgbench accepts the following command-line common arguments:
The database server's host name
The database server's port number
The user name to connect as
The default transaction script issues seven commands per transaction:
BEGIN;
UPDATE pgbench_accounts SET abalance = abalance + :delta WHERE aid = :aid;
SELECT abalance FROM pgbench_accounts WHERE aid = :aid;
UPDATE pgbench_tellers SET tbalance = tbalance + :delta WHERE tid = :tid;
UPDATE pgbench_branches SET bbalance = bbalance + :delta WHERE bid = :bid;
INSERT INTO pgbench_history (tid, bid, aid, delta, mtime) VALUES (:tid, :bid, :aid, :delta, CURRENT_TIMESTAMP);
END;
If you specify -N, steps 4 and 5 aren't included in the transaction. If you specify -S, only the SELECT is issued.
pgbench has support for running custom benchmark scenarios by replacing the default transaction script (described above) with a transaction script read from a file (-f option). In this case a "transaction" counts as one execution of a script file. You can even specify multiple scripts (multiple -f options), in which case a random one of the scripts is chosen each time a client session starts a new transaction.
The format of a script file is one SQL command per line; multiline SQL commands are not supported. Empty lines and lines beginning with -- are ignored. Script file lines can also be "meta commands", which are interpreted by pgbench itself, as described below.
There is a simple variable-substitution facility for script files. Variables can be set by the command-line -D option, explained above, or by the meta commands explained below. In addition to any variables preset by -D command-line options, the variable scale is preset to the current scale factor. Once set, a variable's value can be inserted into a SQL command by writing :variablename. When running more than one client session, each session has its own set of variables.
Script file meta commands begin with a backslash (\). Arguments to a meta command are separated by white space. These meta commands are supported:
Sets variable varname to a calculated integer value. Each operand is either an integer constant or a :variablename reference to a variable having an integer value. The operator can be +, -, *, or /.
Example:
\set ntellers 10 * :scale
Sets variable varname to a random integer value between the limits min and max inclusive. Each limit can be either an integer constant or a :variablename reference to a variable having an integer value.
Example:
\setrandom aid 1 :naccounts
Causes script execution to sleep for the specified duration in microseconds (us), milliseconds (ms) or seconds (s). If the unit is omitted then seconds are the default. number can be either an integer constant or a :variablename reference to a variable having an integer value.
Example:
\sleep 10 ms
Sets variable varname to the result of the shell command command. The command must return an integer value through its standard output.
argument can be either a text constant or a :variablename reference to a variable of any types. If you want to use argument starting with colons, you need to add an additional colon at the beginning of argument.
Example:
\setshell variable_to_be_assigned command literal_argument :variable ::literal_starting_with_colon
Same as \setshell, but the result is ignored.
Example:
\shell command literal_argument :variable ::literal_starting_with_colon
As an example, the full definition of the built-in TPC-B-like transaction is:
\set nbranches :scale \set ntellers 10 * :scale \set naccounts 100000 * :scale \setrandom aid 1 :naccounts \setrandom bid 1 :nbranches \setrandom tid 1 :ntellers \setrandom delta -5000 5000 BEGIN; UPDATE pgbench_accounts SET abalance = abalance + :delta WHERE aid = :aid; SELECT abalance FROM pgbench_accounts WHERE aid = :aid; UPDATE pgbench_tellers SET tbalance = tbalance + :delta WHERE tid = :tid; UPDATE pgbench_branches SET bbalance = bbalance + :delta WHERE bid = :bid; INSERT INTO pgbench_history (tid, bid, aid, delta, mtime) VALUES (:tid, :bid, :aid, :delta, CURRENT_TIMESTAMP); END;
This script allows each iteration of the transaction to reference different, randomly-chosen rows. (This example also shows why it's important for each client session to have its own variables — otherwise they'd not be independently touching different rows.)
With the -l option, pgbench writes the time taken by each transaction to a log file. The log file will be named pgbench_log.nnn, where nnn is the PID of the pgbench process. If the -j option is 2 or higher, creating multiple worker threads, each will have its own log file. The first worker will use the same name for its log file as in the standard single worker case. The additional log files for the other workers will be named pgbench_log.nnn.mmm, where mmm is a sequential number for each worker starting with 1.
The format of the log is:
client_id transaction_no time file_no time_epoch time_us
where time is the elapsed transaction time in microseconds, file_no identifies which script file was used (useful when multiple scripts were specified with -f), and time_epoch/time_us are a UNIX epoch format timestamp and an offset in microseconds (suitable for creating a ISO 8601 timestamp with fractional seconds) showing when the transaction completed.
Here are example outputs:
0 199 2241 0<PHONE_NUMBER> 995598 0 200 2465 0<PHONE_NUMBER> 998079 0 201 2513 0<PHONE_NUMBER> 608 0 202 2038 0<PHONE_NUMBER> 2663
It is very easy to use pgbench to produce completely meaningless numbers. Here are some guidelines to help you get useful results.
In the first place, never believe any test that runs for only a few seconds. Use the -t or -T option to make the run last at least a few minutes, so as to average out noise. In some cases you could need hours to get numbers that are reproducible. It's a good idea to try the test run a few times, to find out if your numbers are reproducible or not.
For the default TPC-B-like test scenario, the initialization scale factor (-s) should be at least as large as the largest number of clients you intend to test (-c); else you'll mostly be measuring update contention. There are only -s rows in the pgbench_branches table, and every transaction wants to update one of them, so -c values in excess of -s will undoubtedly result in lots of transactions blocked waiting for other transactions.
The default test scenario is also quite sensitive to how long it's been since the tables were initialized: accumulation of dead rows and dead space in the tables changes the results. To understand the results you must keep track of the total number of updates and when vacuuming happens. If autovacuum is enabled it can result in unpredictable changes in measured performance.
A limitation of pgbench is that it can itself become the bottleneck when trying to test a large number of client sessions. This can be alleviated by running pgbench on a different machine from the database server, although low network latency will be essential. It might even be useful to run several pgbench instances concurrently, on several client machines, against the same database server.


This inspection reports any variables which are used in a loop condition and are not updated inside the loop. These may cause an infinite loop if executed and are probably not what was intended.


What are the emergent characteristics or behaviors generated by an established business model process on the long-term financial stability of an online marketplace lending platform?
We assume that not all the borrowers are able to make installment payment every due date, and that the probability that a number of borrowers are able to make installment payments every due date, is determined by a stochastic process. In this case time to make a number of installment payments will be random, and the online marketplace lending platform needs to only form rational expectations about the future to set optimal installment payment process.
The marketplace lending platform is supposed to be constantly proactive, assesses and weigh a number of factors and then makes a prediction for the future installment payments by using strategies, rules and assessing the accuracy of any factor related to the determination of the future installment payments. The marketplace lending platform is combining all these informations to arrive to a function based on the entire future of installment payment process process for a rational profitability or financial performance prediction.


A simple class for an h1 to appropriately space out and segment sections of content on a page.
h1
It can use the h1's default small element, as well as most other components (with additional styles).
small


abstract fun onAutoFocus(success: Boolean): Unit
Called when the camera auto focus completes. If the camera does not support auto-focus and autoFocus is called, onAutoFocus will be called immediately with a fake value of success
set to true
. The auto-focus routine does not lock auto-exposure and auto-white balance after it completes.


HTML, CSS & DOM Part 2
What is grid based design?
In web design, a grid is a structure made up of a series of intersecting straight (vertical,horizontal) guide lines used to structure content. Look at any website on the internet you will most likely be able to draw a grid around the content. These grids help you to be structured and to orginise your content.
Whats all the hype about responsive webpages?
Responsive webpages are all about being able to use your website from any device. So it doesn't matter if you are browsing from your phone, a tablet or your super duper 40 inch 4k monitor, the website will display the content you can easily browse it.
What is semantic structure?
Semantic structure is all about writing clear code. And this means clear for the computer and clear for any other developer that might work with you. For example you could just wrap any html content into divs with different class names but it might be a lot clearer if you use h1 (or h2/h3/etc) for headers and p - tags for paragraphs. There are a lot of different tags which make it a lot easier for the browser to interpret your code. You can find a list and some explanations here.
Frameworks
There are a lot of frameworks for Frontend development which will help you to get up and running very quickly. Twitter Bootstrap is one of those. They have very extensive documentation on their website. In the framework they have a lot of pre-defined css for you to use, so you can quickly organise your content on your newly built website. Other frameworks are Semantic UI and Foundation.


"x" "1" "LIJINSKY,W, KOVATCH,RM AND SAAVEDRA,JE, CARCINOGENESIS AND MUTAGENESISBY N- NITROSO COMPOUNDS HAVING A BASIC CENTER, CANCER LETT. 63(2):101-107,1992"


Web Fusée Launcher
Fusee Launcher ported to JavaScript using WebUSB.
Source can be found on my Gitlab instance (you can find a mirror on GitHub).
Code forked from atlas44 on GitHub.
Ported from fusee-launcher.
Thanks to ktemkin and ReSwitched for Fusée Gelée and a ton of other things!
This fork simply adds all the payloads used in the Switch Guide.
Instructions:
- Put the Switch in RCM, and connect it to your device.
- Select either the example payload, or upload one.
- Press 'Do the thing!'
- On the consent screen that appears, select 'APX' and hit confirm.
- If all goes well, the payload will launch!
Random stuff:
- This is pretty poorly tested. I just kind wrote it and whatever. I'm not responsible if anything goes wrong!
- This does NOT work on Windows due to a limitation in the Chrome implementation of WebUSB (and probably other reasons!)
- This does NOT currently work on any browser but Chrome, because they don't implement WebUSB.
- On Linux, you might get an access denied error!
If you do, you can try creating a file at
/etc/udev/rules.d/50-switch.rules
With the following contents:
SUBSYSTEM=="usb", ATTR{idVendor}=="0955", MODE="0664", GROUP="plugdev"
- This has been tested and appears to work on Linux, OSX, Android (unrooted) and Chromebooks. Your mileage may vary.


whichFishAdd_vignette.Rmd
In this article we will show how to find for species that must be added to the mega-tree, before running the FishPhyloMaker
function. When there are few species that must be added, the interactive insertion process is ease to follow. However, when we are dealing with big data bases with many species, it is desirable that before to initiate the insertion process with FishPhyloMaker
function we know which species must be inserted and at which position in phylogenetic tree. So, in order to facilitate this process the function whichFishAdd
take all species informed by the user and provide a classification of each level in which the species be inserted when running FishPhyloMaker
function. The code of classification follows similar classification from that presented in the insertion process:
First, lets read {FishPhyloMaker}
package and the data containing more than 650 fish species with occurrence in the Neotropical region.
Then, we will check for the names of the species in the data base through the function FishTaxaMaker
, and inform manually the Family and the Order of the species that were not find in Fishbase. This procedure is better explained in other articles
taxon_data <- FishTaxaMaker(data = fish_SAmerica)
Loricariidae
Siluriformes
Anostomidae
Characiformes
Anostomidae
Characiformes
Anostomidae
Characiformes
Serrasalmidae
Characiformes
Auchenipteridae
Siluriformes
Auchenipteridae
Siluriformes
Auchenipteridae
Siluriformes
taxon_data contain the taxonomic information for all species, and can be used in whichFishAdd
function to perform the classification of each species.
class_fish <- whichFishAdd(data = taxon_data)
class_fish is a data frame that contain in insertion column an indication of which level each species must be inserted (or if the species are already on tree). This data can be used previous than FishPhyloMaker
to find for phylogenetic position of the absent species.


a State Manager (state machine)
There is no constructor function for me.state.
- Source:
- state.js, line 105
Members
-
<static, constant> CREDITS
-
default state ID for Credits Screen
- Source:
- state.js, line 306
-
<static, constant> GAME_END
-
default state ID for Game End Screen
- Source:
- state.js, line 290
-
<static, constant> GAMEOVER
-
default state ID for Game Over Screen
- Source:
- state.js, line 282
-
<static, constant> LOADING
-
default state ID for Loading Screen
- Source:
- state.js, line 248
-
<static, constant> MENU
-
default state ID for Menu Screen
- Source:
- state.js, line 258
-
<static, constant> PLAY
-
default state ID for Play Screen
- Source:
- state.js, line 274
-
<static, constant> READY
-
default state ID for "Ready" Screen
- Source:
- state.js, line 266
-
<static, constant> SCORE
-
default state ID for High Score Screen
- Source:
- state.js, line 298
-
<static, constant> SETTINGS
-
default state ID for Settings Screen
- Source:
- state.js, line 314
-
<static, constant> USER
-
default state ID for user defined constants
- Source:
- state.js, line 322
Example
var STATE_INFO = me.state.USER + 0; var STATE_WARN = me.state.USER + 1; var STATE_ERROR = me.state.USER + 2; var STATE_CUTSCENE = me.state.USER + 3;
Methods
-
<static> change(state)
-
change the game/app state
Parameters:
Name Type Argument Description state
Number State ID (see constants) arguments...
<optional>
extra arguments to be passed to the reset functions - Source:
- state.js, line 615
Example
// The onResetEvent method on the play screen will receive two args: // "level_1" and the number 3 me.state.change(me.state.PLAY, "level_1", 3);
-
<static> current() → {me.ScreenObject}
-
return a reference to the current screen object
useful to call a object specific method- Source:
- state.js, line 572
Returns:
- Type
- me.ScreenObject
-
<static> isCurrent(state)
-
return true if the specified state is the current one
Parameters:
Name Type Description state
Number State ID (see constants) - Source:
- state.js, line 662
-
<static> isPaused() → {Boolean}
-
Return the pause state of the state manager
- Source:
- state.js, line 508
Returns:
true if the game is paused- Type
- Boolean
-
<static> isRunning() → {Boolean}
-
return the running state of the state manager
- Source:
- state.js, line 496
Returns:
true if a "process is running"- Type
- Boolean
-
<static> pause(pauseTrack)
-
pause the current screen object
Parameters:
Name Type Description pauseTrack
Boolean pause current track on screen pause - Source:
- state.js, line 405
-
<static> restart(resumeTrack)
-
Restart the screen object from a full stop.
Parameters:
Name Type Description resumeTrack
Boolean resume current track on screen resume - Source:
- state.js, line 435
-
<static> resume(resumeTrack)
-
resume the screen object
Parameters:
Name Type Description resumeTrack
Boolean resume current track on screen resume - Source:
- state.js, line 467
-
<static> set(state, so)
-
associate the specified state with a screen object
Parameters:
Name Type Description state
Number State ID (see constants) so
me.ScreenObject Instantiated ScreenObject to associate with state ID - Source:
- state.js, line 520
Example
var MenuButton = me.GUI_Object.extend({ "onClick" : function () { // Change to the PLAY state when the button is clicked me.state.change(me.state.PLAY); return true; } }); var MenuScreen = me.ScreenObject.extend({ onResetEvent: function() { // Load background image me.game.world.addChild( new me.ImageLayer(0, 0, { image : "bg", z: 0 // z-index } ); // Add a button me.game.world.addChild( new MenuButton(350, 200, { "image" : "start" }), 1 // z-index ); // Play music me.audio.playTrack("menu"); }, "onDestroyEvent" : function () { // Stop music me.audio.stopTrack(); } }); me.state.set(me.state.MENU, new MenuScreen());
-
<static> setTransition(state, enable)
-
enable/disable transition for a specific state (by default enabled for all)
Parameters:
Name Type Description state
Number State ID (see constants) enable
Boolean - Source:
- state.js, line 602
-
<static> stop(pauseTrack)
-
Stop the current screen object.
Parameters:
Name Type Description pauseTrack
Boolean pause current track on screen stop. - Source:
- state.js, line 375
-
<static> transition(effect, color, duration)
-
specify a global transition effect
Parameters:
Name Type Argument Default Description effect
String (only "fade" is supported for now) color
me.Color | String a CSS color value duration
Number <optional>
1000 expressed in milliseconds - Source:
- state.js, line 585
Type Definitions
-
onPause
-
onPause callback
- Source:
- state.js, line 335
-
onRestart
-
onRestart callback
- Source:
- state.js, line 359
-
onResume
-
onResume callback
- Source:
- state.js, line 343
-
onStop
-
onStop callback
- Source:
- state.js, line 351


--- layout: main title: "Jekyll Bootstrap Shen Scroll Template" data: ["we can define data here"] ---


--- layout: post title: EventBus for Android categories: - Allgemein - Android - android - Architecture - architecture - events - java - refactoring - Zugmonitor status: publish type: post published: true meta: _edit_last: '1' _jd_tweet_this: 'yes' _wp_jd_goo: http://goo.gl/EUujQ _wp_jd_target: http://www.logv.ws/251 _jd_wp_twitter: ! 'a:1:{i:0;s:50:"New post: EventBus for Android http://goo.gl/EUujQ";}' ---
The new version of trainmonitor adds some new features like syncing multiple devices. Which was one of the most challenging features to implement. The app uses a lot of threading to do nearly everything except UI drawing off the main thread. This required a lot of callbacks and it really started to get messy when the same action should be triggered from different sources. To illustrate some of the issues I had we can have a look at the start up of my app. To illustrate it I have drawn some state diagram:
As you can see there are several way through the application. And here is a typical peace of code:
private void chooseAccount(final MainActivity that)
{
if(!Installation.wasChooseAccountShown(this))
{
new ChooseAccountFragment(new Runnable() {
@Override
public void run() {
Installation.setChooseAccountShown(that);
init();
}
}).show(getSupportFragmentManager(), "choose_account");
}
else {
init();
}
}
Both paths though the code call the same init function. The init function is the point where the menu is set up, the check for a valid Google Cloud Messaging registration and if need the registration is started. Now there nothing really wrong with it but it tends to get a bit messy when I wanted to extend the logic that is performed when the disclaimer was shown. Since I am doing a lot of Servicebus related work in my daily work for a client I searched if there is something similar for android. And indeed there is a android solution for it, EventBus. After some refactoring the code now looks like this:
@SuppressWarnings("UnusedDeclaration")
public void onEvent(DisclaimerAcceptedEvent event)
{
if(!Installation.wasChooseAccountShown(this))
{
final MainActivity that = this;
new ChooseAccountFragment(new Runnable() {
@Override
public void run() {
Installation.setChooseAccountShown(that);
mBus.post(new AccountChoosnEvent());
}
}).show(getSupportFragmentManager(), "choose_account");
}
else
{
mBus.post(new AccountChoosnEvent());
}
}
Now the code does not look that much different, the explicit calls to 'init' where replaced with a post on the EventBus and the function itself just listens to a Event and is then called by the EventBus. But you can now add easily new functionality that is called when the event occurs. This especially useful when triggering the events from different sources, e.g. refreshing a list of subscriptions from the UI or by a message from the cloud.


Unaccounted for water in Bengaluru down to 36% Water lost owing to leakage and other factors in the city was as high as 48% in 2007 17 Nov 2019, 19:06 by Staff Reporter Bangalore Water Supply and Sewerage Board launched projects to check unaccounted for water in 2016. | Photo Credit: File Photo


Sign Out Delete account
Don't have an account? Sign Up
Forgot Password?
You can reset your password here.


Quiz Yourself! Should you ever look over something you're heating?(Click to see answer) Never! It could errupt on your face. When should you wear your safety goggles?(Click to see answer) At all times till you exit the lab room. Can extra chemicals be discarded in the sink?(Click to see answer) Never! They must be disposed of in the container marked "Waste". Previous Next


Train Stopped With Police?
by StefanaBy an edhat reader
Does anyone know what was going on around 6:30 p.m. Thursday night, the train was stopped on the tracks right around Mission Street exit, and SB traffic was slow with lots of firetrucks and police on the freeway.


Directory ext/openssl/test/ocsp-tests/
- Directory Created:
- 2015-01-22 13:57
- Total Files:
- 66
- Deleted Files:
- 0
- Lines of Code:
- 1764
[root]/ext/openssl/test/ocsp-tests
Lines of Code
Developers
| Author |
Changes |
Lines of Code |
Lines per Change |
| tortoisesvn |
66 (100.0%) |
1764 (100.0%) |
26.7 |
Most Recent Commits
-
tortoisesvn
2015-01-22 13:57
Rev.: 26211
-
1764 lines of code changed in 66 files:
-
ext/openssl/test/ocsp-tests:
D1.ors (new 32),
D1_Cert_EE.pem (new 38),
D1_Issuer_ICA.pem (new 27),
D2.ors (new 32),
D2_Cert_ICA.pem (new 26),
D2_Issuer_Root.pem (new 21),
D3.ors (new 38),
D3_Cert_EE.pem (new 31),
D3_Issuer_Root.pem (new 83),
ISDOSC_D1.ors (new 32),
ISDOSC_D2.ors (new 32),
ISDOSC_D3.ors (new 38),
ISIC_D1_Issuer_ICA.pem (new 27),
ISIC_D2_Issuer_Root.pem (new 21),
ISIC_D3_Issuer_Root.pem (new 41),
ISIC_ND1_Issuer_ICA.pem (new 29),
ISIC_ND2_Issuer_Root.pem (new 23),
ISIC_ND3_Issuer_Root.pem (new 25),
ISOP_D1.ors (new 32),
ISOP_D2.ors (new 32),
ISOP_D3.ors (new 38),
ISOP_ND1.ors (new 10),
ISOP_ND2.ors (new 10),
ISOP_ND3.ors (new 10),
ND1.ors (new 10),
ND1_Cert_EE.pem (new 36),
ND1_Issuer_ICA.pem (new 29),
ND2.ors (new 10),
ND2_Cert_ICA.pem (new 29),
ND2_Issuer_Root.pem (new 23),
ND3.ors (new 10),
ND3_Cert_EE.pem (new 34),
ND3_Issuer_Root.pem (new 25),
WIKH_D1.ors (new 32),
WIKH_D2.ors (new 32),
WIKH_D3.ors (new 38),
WIKH_ND1.ors (new 10),
WIKH_ND2.ors (new 10),
WIKH_ND3.ors (new 10),
WINH_D1.ors (new 32),
WINH_D2.ors (new 32),
WINH_D3.ors (new 38),
WINH_ND1.ors (new 10),
WINH_ND2.ors (new 10),
WINH_ND3.ors (new 10),
WKDOSC_D1.ors (new 32),
WKDOSC_D2.ors (new 32),
WKDOSC_D3.ors (new 38),
WKIC_D1_Issuer_ICA.pem (new 27),
WKIC_D2_Issuer_Root.pem (new 21),
WKIC_D3_Issuer_Root.pem (new 41),
WKIC_ND1_Issuer_ICA.pem (new 29),
WKIC_ND2_Issuer_Root.pem (new 23),
WKIC_ND3_Issuer_Root.pem (new 25),
WRID_D1.ors (new 32),
WRID_D2.ors (new 32),
WRID_D3.ors (new 38),
WRID_ND1.ors (new 10),
WRID_ND2.ors (new 10),
WRID_ND3.ors (new 10),
WSNIC_D1_Issuer_ICA.pem (new 27),
WSNIC_D2_Issuer_Root.pem (new 21),
WSNIC_D3_Issuer_Root.pem (new 41),
WSNIC_ND1_Issuer_ICA.pem (new 29),
WSNIC_ND2_Issuer_Root.pem (new 23),
WSNIC_ND3_Issuer_Root.pem (new 25)


---
layout: ../../layouts/basic.html
containerCls: container
title: ESL Toggleable and ESL Trigger components
---
{{##content:
Click event
Triggers
Hover event
Triggers
Class toggle
Toggleable can be used to switch state. You can toggle it using the trigger bellow.
Triggers
Toggle type
Close On Body Click
Triggers
Group of popups (click event)
Body class marker active
Triggers
Group of popups (hover event)
Triggers
#}}


I'm a Software Engineer. My main field of study is Comp science with focus on embedded systems and IoT. I write about software, tech and other passions of mine. Feel free to check out some of my projects!😀


Student kills one, wounds three before killing himself at Russian college
MOSCOW: A 19-year-old male student shot and killed a fellow student and wounded three others at a vocational college in Russia's Far East on Thursday (Nov 14) before committing suicide, Russian investigators said in a statement.
School and college shootings are rare in Russia which has strict gun laws, and it was not immediately clear what the shooter's motive was.
Investigators said the student opened fire with a hunting rifle at the college, which is located in the city of Blagoveshchensk, around 5,600 km east of Moscow near Russia's border with China.
He shot dead another 19-year-old male student, and three other students had been taken to hospital after receiving gunshot wounds, investigators said.
One of the wounded was in a serious condition and was being operated on, the RIA news agency reported.
Russia's Investigative Committee opened a criminal case.
Vasily Orlov, the governor of the Amur Region, described the incident as a tragedy.
"I express my deep condolences to the relatives of the victims," Orlov said in a statement on social media.
"We will give them all necessary assistance. And I promise that from our side we will make sure we investigate why such an incident was possible in an educational institution."
In 2018, a teenager killed 19 people in another college shooting, in the Black Sea region of Crimea which Russia annexed from Ukraine, before also killing himself.
And in October, a Russian conscript shot dead eight fellow soldiers in Russia's Far East.


1991: EMASS Founded
EMASS, a private company offering alternative sentencing services to counties in Missouri, was founded by Michael L. Smith, a former state probation and parole officer with 17 years of field experience under his belt.
EMASS, a private company offering alternative sentencing services to counties in Missouri, was founded by Michael L. Smith, a former state probation and parole officer with 17 years of field experience under his belt.
According to a St. Louis Post-Dispatch article written by Jennifer Mann in 2012, EMASS signed a contract in July 2000 with the St. Louis Circuit Court to become a provider of post-conviction supervision for misdemeanor defendants.
Missouri's Department of Corrections brought pre-trial supervision programs to an end. In response to this, some jurisdictions in Missouri just established their own programs but the St. Louis Circuit Court decided to partner with EMASS to provide supervision. As a result of this relationship, EMASS was able to occupy a position within the criminal justice system that allowed them to quietly reap the benefits when the courts tacked on EMASS programs as a condition of bail.
EMASS was awarded a contract from the Missouri Department of Corrections / St. Louis County Justice Services to oversee a new alcohol monitoring program.
In 2012, EMASS and the 22nd Circuit Court in St. Louis signed an aggreement regarding the provision of private probation services by EMASS at the request of the court. This contract outlines that EMASS must keep records of all the cases they supervise and must be willing to be subject to yearly fee and service reviews by Associate Judges. Funnily enough, another clause in the contract states that employees of EMASS must not have some sort of interest (possibly financial) in EMASS that would prevent them from providing the services EMASS agreed to. While this makes total sense on an individual level, it seems ironic as EMASS has a vested financial interest in firmly establishing this relationship with the court.
In 2012, Jennifer Mann of the St. Louis Post-Dispatch wrote an article that presented information about EMASS that included the views of judges, bail bondsmen, and actual defendants.
On January 10th, 2019, a joint letter was sent to the 22nd Judicial Circuit Court in St. Louis by local criminal justice organizations, addressing the court's pre-trial practices. In this letter, these local organizations called out the court for allowing EMASS to unconstitutionally collect monthly fees for pre-trial GPS monitoring ankle bracelets and other services from poor residents in the St. Louis area.
Representatives from ArchCity Defenders, The Bail Project the St. Louis Public Defender's Office, the Mound Bar Association, the ACLU of Missouri, and the Roderick & Solange MacArthur Justice Center all signed the letter. Discussing the release of those who are ordered by the court to undergo some sort of court-ordered supervision, the letter says the following:
"However, this release comes at a cost, as individuals have to pay significant fees to this private company in order to remain free, and risk re-incarceration if they find themselves unable to pay. As a result, these presumptively innocent individuals are essentially shackled, often unconstitutionally, by the cost and burdens of private supervision, and their inability to afford such costs has resulted in re-incarceration. Those who benefit from the Circuit’s current practices appear to be private companies, not the St. Louis public.
According to this statement, the court does not make sure that individuals who are released to court-ordered supervision through EMASS services have the ability to pay for fees attached to this supervision. This spells bad news for indigent or particularly poor residents whose cases are assigned to EMASS even though the contract between EMASS and the court says such cases should be taken care of at no cost. Rebecca Rivas of the St. Louis American writes about the joint letter's release and lets us know that there have actually been no cases where poor residents passed on to EMASS haven't had to pay).
Robert Gable and his twin brother Ralph came up with the first electronic monitoring system many decades ago. Formally, the invention was documented as a "behavior supervision system with wrist carried transceiver". Such an invention, officially created by Ralph and colleague William Hurd, was meant to help at-risk youth using positive reinforcement techniques. Upon its creation, there was no guarantee that such a device would actually serve its intended purpose. Today, the use of wearables in the criminal justice system has gone away from the original vision the Gable brothers had; instead of a focus on rehabilitation, wearables (GPS monitors in ankle bracelets) are now an efficient punishment strategy that largely benefits the private companies that produce such technology.
In 1977, New Mexico district court Judge Jack Love was intrigued by a Spider-Man cartoon that featured a similar type of monitor. Spurred on by a major prison crowding problem that was plaguing the United States as a whole, and hitting Albuquerque particularly hard, at that time, Judge Love was convinced that remote monitoring was a viable solution. By the early 1980s he had partnered up with ex-computer salesman Michael Goss to create the GOSSLink electronic monitor bracelet and he had begun to use the device to monitor a small number of probation violators. EM took off from there.
By the mid-1980s, EM had expanded to around twenty jurisdictions across thirteen states, though still, fewer than a hundred devices were active at any given time in 1986. Companies tended to have regional control over EM manufacture and sales, and many quickly sprung up. It is important to realize that by this time, neo-conservative ideologies had become the mainstream line of thought regarding criminal justice; there was no talk of the rehabilitation that the Gable brothers had envisioned. Instead, these “first-generation” radio frequency devices just used one-way communication to tell monitoring agents whether the offender was within a small radius of their home telephone when they were expected to be.
Two big trends emerged with EM in the 1990s: first, “second-generation” devices, including GPS monitors that enabled 24/7 observation, were introduced. Second, the use of EM technology exploded -- to the point where over seventeen thousand devices were in daily use by 1994. These two trends were certainly related, but neither was singlehandedly responsible for the other; GPS did not develop a strong foothold in the market until the early 2000s.
SCRAM, which provides solutions to the criminal justice and electronic monitoring arkets, was founded just prior to the turn of the century. The company's flagship product, the SCRAM CAM or Continuous Alcohol Monitoring system, is widely used today by correction agencies and pre-trial supervision programs. Additionally, the company has rolled out a breath monitoring system, GPS monitoring system, and house arrest monitor since released the SCRAM CAM to market in 2003. All of these products are used by EMASS and a certificate establishing this relationship between EMASS and SCRAM Systems is shown on the EMASS website.
Over 100,000 people are watched over with some electronic monitoring system, which still represents only 1-2% of those involved with criminal justice system. Most states buy the monitors from private corporations (see SCRAM) that exercise varying degrees of control over the data that their devices put out; a few states, Missouri included, delegate oversight to private companies like EMASS as well.


We have many years of Shopify experience working with both big and small clients to build their dream Shopify websites.
Our Websites are easy to use, and lightning fast. We use the latest and greatest technology to build Shopify websites with the best user experience possible.
We offer training and support to help you grow your Shopify business online. We can answer any admin or development question you have about your website.
PHONE:<PHONE_NUMBER>
EMAIL<EMAIL_ADDRESS>No task is too small or too big for us.
We can start on your project immediately with no up front cost. Ask about our monthly subscription plans that are very affordable and can be customized to your needs. We're excited to work on your dream website and make it a reality.
Our Base Plan includes our custom, lightning fast, Vue Theme. It comes with maintenance, support, and improvements to the theme. We will guide you through setting up and customizing the theme to your unique needs as well as give you full, continued support on the theme.
This plan includes everything in the Vue Theme Plan plus additional support and Shopify training. We will help you with any Shopify admin or development question you may have about your site. We can also train you in advanced Shopify techniques for your business.
We also do custom work on any new or existing Shopify website. We can make a plan for you if you want any work done to your site. We can build new features, fix old code or bugs, or re build the website for you.


Our database upgrade is complete and we've left maintenance mode. (For those who missed it: in the wee early hours of 12/19, we upgraded our database for performance and scalability. The platform and embeds stayed online during the upgrade, only edits and uploads were disabled.) Follow us on Twitter for further updates, or shoot us an email if you need something.


Arrays and Hashes are similar constructs in Ruby. They are both collections of objects that contain values which have keys associated to them. Arrays automatically assign indices, represented by consecutive integers, to the ojects contained in them. Let's say we have an array with the following objects ['cubs', 'bulls', 'bears']. 'cubs' would have index 0, 'bulls' index 1, and so on and so forth. Yes, the indexing starts at 0. Now I get why we have a Phase 0 at DEV Bootcamp.
Hashes, on the other hand, have keys associated to their values, they are called key/value pairs. The keys can be anything, but they do need to be unique, while the values can repeat themselves in the hash. For an example let's got with sports again: {"baseball" => "cubs", "basketball" => "bulls", "football" => "bears"}. I used strings in both examples, arrays and hashes, but they can contain any objects, even other arrays and hashes (nested elements).
Now that we learned a bit about array and hashes, let's see how we can create them. I will walk you through two of the most popular ways:
Arrays and hashes can be manipulated in many ways, you can add/retrieve/remove ojects, merge them, apply all sorts of methods and transform them in many ways. I will not get into detail with that but I would like to touch on one more topic. Arrays and hashes sound just dandy but what do we actually use them for? And when use arrays vs. hashes? They are so closely connected, basically an array is a hash where the keys are integers and hashes are called associative arrays. Feeling more confused? From my research so far it seems that hashes are prefered for their flexibility to use any objects as keys, they are not limited to integers, but if you're going for a simpler ordered collection where automatic indices do the trick, and array is the way to go.


class: title-slide, center   5  # A Quick Introduction to tidymodels ## Model Tuning --- # Loading ```r library(tidymodels) ``` ``` ## ── Attaching packages ───────────────────────────────────────────────────────────── tidymodels 0.1.1 ── ``` ``` ## ✓ broom 0.7.0 ✓ recipes 0.1.13 ## ✓ dials 0.0.9 ✓ rsample 0.0.8 ## ✓ dplyr 1.0.2 ✓ tibble 3.0.3 ## ✓ ggplot2 3.3.2 ✓ tidyr 1.1.2 ## ✓ infer 0.5.2 ✓ tune 0.1.1 ## ✓ modeldata 0.0.2 ✓ workflows 0.2.0 ## ✓ parsnip 0.1.3 ✓ yardstick 0.0.7 ## ✓ purrr 0.3.4 ``` ``` ## ── Conflicts ──────────────────────────────────────────────────────────────── tidymodels_conflicts() ── ## x dplyr::combine() masks gridExtra::combine() ## x purrr::discard() masks scales::discard() ## x dplyr::filter() masks stats::filter() ## x dplyr::lag() masks stats::lag() ## x recipes::step() masks stats::step() ``` --- # Previously ```r library(modeldata) data(ames, package = "modeldata") ames <- mutate(ames, Sale_Price = log10(Sale_Price)) set.seed(4595) data_split <- initial_split(ames, strata = "Sale_Price") ames_train <- training(data_split) ames_test <- testing(data_split) set.seed(2453) cv_splits <- vfold_cv(ames_train) #10-fold is default perf_metrics <- metric_set(rmse, rsq, ccc) ``` ```r ames_rec <- recipe( Sale_Price ~ Bldg_Type + Neighborhood + Year_Built + Gr_Liv_Area + Full_Bath + Year_Sold + Lot_Area + Central_Air + Longitude + Latitude, data = ames_train ) %>% step_BoxCox(Lot_Area, Gr_Liv_Area) %>% step_other(Neighborhood, threshold = 0.05) %>% step_dummy(all_nominal()) %>% step_interact(~ starts_with("Central_Air"):Year_Built) %>% step_bs(Longitude, Latitude, deg_free = 5) ``` --- layout: false class: inverse, middle, center # Model Tuning --- # Tuning Parameters There are some models with parameters that _cannot be directly estimated from the data_. For example: * The number of neighbors in a K-NN models. * The depth of a classification tree. * The link function in a generalized linear model (e.g. logit, probit, etc). * The covariance structure in a linear mixed model. --- # Tuning Parameters and Overfitting Overfitting occurs when a model inappropriately picks up on trends in the training set that do not generalize to new samples. When this occurs, assessments of the model based on the training set can show good performance that does not reproduce in future samples. For example, _K_ = 1 neighbors is much more likely to overfit the data than larger values since they average more values. Also, how would you evaluate this model by re-predicting the training set? Those values would be optimistic since one of your neighbors is always you. --- # Model Tuning .pull-left[ Unsurprisingly, we will evaluate a tuning parameter by fitting a model on one set of data and assessing it with another. _Grid search_ uses a pre-defined set of candidate tuning parameter values and evaluates their performance so that the best values can be used in the final model. We'll use resampling to do this. If there are _B_ resamples and _C_ tuning parameter combinations, we end up fitting `\(B \times C\)` models (but these can be done in parallel). ] .pull-right[  ] --- # Better API's using the tune package `tune` has more general functions for tuning models. There are two main strategies used: * Grid search (as shown above) where all of the candidate models are known at the start. We pick the best of these. * Iterative search where each iteration finds novel tuning parameter values to evaluate. Both have their advantages and disadvantages. Due to time constraints, we will focus on grid search.
 Iterative methods, such as Bayesian optimization or simulated annealing, can also be used in the `tune` and `finetune` packages, respectively. --- # Elements Required for Grid Search  .pull-left[ * A set of candidate values to evaluate. * Measure of model performance. * A resampling scheme to reliably estimate model performance. We've discussed the last two. Now let's focus on the grid. There are two main types of grids: regular and non-regular. ] .pull-right[  ] --- # About Regular Grids Usually combinatorial representation of vectors of tuning parameter values. Note that: * The number of values don't have to be the same per parameter. * The values can be regular on a transformed scale (e.g. log-10 for penalty). * Quantitative and qualitative parameters can be combined. * As the number of parameters increase, the curse of dimensionality kicks in. * _Thought_ to be really inefficient but not in all cases (see the sub-model trick and `multi_predict()`). * Bad when performance plateaus over a range of one or more parameters. --- # Making Regular Grids  .pull-left[ You can use `expand.grid()` to make a data frame where parameters are in columns and candidate values are in rows. `dials` has functions to create parameters and parameter sets. For example: ```r penalty() ``` ``` ## Amount of Regularization (quantitative) ## Transformer: log-10 ## Range (transformed scale): [-10, 0] ``` ```r mixture() ``` ``` ## Proportion of lasso Penalty (quantitative) ## Range: [0, 1] ``` ```r glmn_param <- parameters(penalty(), mixture()) ``` ] .pull-right[ ```r glmn_param ``` ``` ## Collection of 2 parameters for tuning ## ## identifier type object ## penalty penalty nparam[+] ## mixture mixture nparam[+] ``` ```r glmn_grid <- grid_regular(glmn_param, levels = c(penalty = 10, mixture = 5)) glmn_grid %>% slice(1:4) ``` ``` ## # A tibble: 4 x 2 ## penalty mixture ## <dbl> <dbl> ## 1 0.0000000001 0 ## 2 0.00000000129 0 ## 3 0.0000000167 0 ## 4 0.000000215 0 ``` Note that the grid for `penalty` is created in the log-10 space but the values in the data frame are in the original units. ] --- # Non-Regular Grids  .pull-left[ There are two main methods that we have to make these: * Random grids uniformly sample the parameter space (that might already be on a different scale). * Space-filling designs (SFD) are based on statistical experimental design principles and try to keep candidate values away from one another while encompassing the entire parameter space. There's no real downside to using the space-filling designs, so we will focus on these. ] .pull-right[ The code is easy when using a parameter set: ```r set.seed(7454) glmn_sfd <- grid_max_entropy(glmn_param, size = 50) glmn_sfd %>% slice(1:4) ``` ``` ## # A tibble: 4 x 2 ## penalty mixture ## <dbl> <dbl> ## 1 0.00000362 0.172 ## 2 0.0102 0.414 ## 3 0.00000372 0.346 ## 4 0.000709 0.544 ``` ```r # grid_latin_hypercube() can also be used # grid_random() too ``` ] --- # Modifying Parameter Sets  .pull-left[ ```r # The names can be changed: glmn_set <- parameters(lambda = penalty(), mixture()) # The ranges can also be set by their name: glmn_set <- update(glmn_set, lambda = penalty(c(-5, -1))) ```
 ```r # Some parameters depend on data dimensions: mtry() ``` ``` ## # Randomly Selected Predictors (quantitative) ## Range: [1, ?] ``` ```r rf_set <- parameters(mtry(), trees()) ``` ] .pull-right[ ```r rf_set ``` ``` ## Collection of 2 parameters for tuning ## ## identifier type object ## mtry mtry nparam[?] ## trees trees nparam[+] ## ## Parameters needing finalization: ## # Randomly Selected Predictors ('mtry') ## ## See `?dials::finalize` or `?dials::update.parameters` for more information. ``` ```r # Sets the range of mtry to # be the number of predictors finalize(rf_set, mtcars %>% dplyr::select(-mpg)) ``` ``` ## Collection of 2 parameters for tuning ## ## identifier type object ## mtry mtry nparam[+] ## trees trees nparam[+] ``` ] --- # K-NN Tuning parameters  The `dist_power` parameter is related to the type of distance calculation. `dist_power = 2` is everyday Euclidean distance, `dist_power = 1` is Manhattan distance, and so on. Fractional values are acceptable. `weight_func` determines how much influence neighbors have based on their distance:  --- # Tagging Tuning parameters  To tune the model, the first step is to _tag_ the parameters that will be optimized. `tune::tune()` can be used to do this: ```r library(tune) knn_mod <- nearest_neighbor(neighbors = tune(), weight_func = tune()) %>% set_engine("kknn") %>% set_mode("regression") ``` `parameters()` can detect these arguments: ```r parameters(knn_mod) ``` ``` ## Collection of 2 parameters for tuning ## ## identifier type object ## neighbors neighbors nparam[+] ## weight_func weight_func dparam[+] ``` --- # Tagging Tuning parameters  `tune()` has an optimal argument called `id` that can be used to name the parameters: ```r nearest_neighbor(neighbors = tune("K"), weight_func = tune("weights")) %>% set_engine("kknn") %>% set_mode("regression") %>% parameters() ``` ``` ## Collection of 2 parameters for tuning ## ## identifier type object ## K neighbors nparam[+] ## weights weight_func dparam[+] ``` This mainly comes in handy when the same parameter type shows up in two different places (an example is shown later). Recipe steps can also have `tune()` in their arguments. --- # Grid Search  Let's tune the model over a regular grid and optimize `neighbors` and `weight_func`. First we make the grid, then call `tune_grid()`: .pull-left[ ```r set.seed(522) knn_grid <- knn_mod %>% parameters() %>% grid_regular( levels = c(neighbors = 15, weight_func = 5) ) ctrl <- control_grid(verbose = TRUE, save_pred = TRUE) knn_tune <- knn_mod %>% tune_grid( ames_rec, resamples = cv_splits, grid = knn_grid, control = ctrl ) ``` ] .pull-right[ We are optimizing 75 models over 10 resamples. The output looks like:  ] --- # Some Notes * If we are evaluating 75 models, why does it say `model 1/5`? * The recipe is made _once_ per resample to avoid redundant computations. * The warnings about "ill-conditioned bases" is related to using splines for longitude and latitude. Remember those outlying houses on Lincoln Highway? * These are printed _as they happen_ and are labeled so that you know which sub-model had the issue. * Unfortunately, these messages don't show up when parallel processing is used (more on that later). We are working on this but it is a tough problem that I've been trying to solve for about a decade. --- # The Results  A tibble is returned that looks like the rsample object with an extra list column called `.metrics`: .code90[ .pull-left[ ```r knn_tune ``` ``` ## Warning: This tuning result has notes. Example notes on model fitting include: ## model 2/5 (predictions): some 'x' values beyond boundary knots may cause ill-conditioned bases ## model 2/5 (predictions): some 'x' values beyond boundary knots may cause ill-conditioned bases ## model 3/5 (predictions): some 'x' values beyond boundary knots may cause ill-conditioned bases ``` ``` ## # Tuning results ## # 10-fold cross-validation ## # A tibble: 10 x 5 ## splits id .metrics .notes .predictions ## <list> <chr> <list> <list> <list> ## 1 <split [2K/220]> Fold01 <tibble [150 × 6]> <tibble [0 × 1]> <tibble [16,500 × 6]> ## 2 <split [2K/220]> Fold02 <tibble [150 × 6]> <tibble [0 × 1]> <tibble [16,500 × 6]> ## 3 <split [2K/220]> Fold03 <tibble [150 × 6]> <tibble [0 × 1]> <tibble [16,500 × 6]> ## 4 <split [2K/220]> Fold04 <tibble [150 × 6]> <tibble [5 × 1]> <tibble [16,500 × 6]> ## 5 <split [2K/220]> Fold05 <tibble [150 × 6]> <tibble [0 × 1]> <tibble [16,500 × 6]> ## 6 <split [2K/220]> Fold06 <tibble [150 × 6]> <tibble [0 × 1]> <tibble [16,500 × 6]> ## 7 <split [2K/220]> Fold07 <tibble [150 × 6]> <tibble [5 × 1]> <tibble [16,500 × 6]> ## 8 <split [2K/220]> Fold08 <tibble [150 × 6]> <tibble [5 × 1]> <tibble [16,500 × 6]> ## 9 <split [2K/220]> Fold09 <tibble [150 × 6]> <tibble [5 × 1]> <tibble [16,500 × 6]> ## 10 <split [2K/219]> Fold10 <tibble [150 × 6]> <tibble [0 × 1]> <tibble [16,425 × 6]> ``` ] .pull-right[ ```r # results for the first fold: knn_tune$.metrics[[1]] ``` ``` ## # A tibble: 150 x 6 ## neighbors weight_func .metric .estimator .estimate .config ## <int> <chr> <chr> <chr> <dbl> <chr> ## 1 1 biweight rmse standard 0.111 Model01 ## 2 2 biweight rmse standard 0.103 Model02 ## 3 3 biweight rmse standard 0.0982 Model03 ## 4 4 biweight rmse standard 0.0962 Model04 ## 5 5 biweight rmse standard 0.0950 Model05 ## 6 6 biweight rmse standard 0.0940 Model06 ## 7 7 biweight rmse standard 0.0925 Model07 ## 8 8 biweight rmse standard 0.0923 Model08 ## 9 9 biweight rmse standard 0.0926 Model09 ## 10 10 biweight rmse standard 0.0929 Model10 ## # … with 140 more rows ``` 150 rows = 75 models x 2 metrics `.config` is a column that is unique for each tuning parameter combination. ] ] --- # Resampled Performance Estimates  To get the overall resampling estimate (averaged over folds) for each parameter combination: ```r show_best(knn_tune, metric = "rmse", n = 3) ``` ``` ## # A tibble: 3 x 8 ## neighbors weight_func .metric .estimator mean n std_err .config ## <int> <chr> <chr> <chr> <dbl> <int> <dbl> <chr> ## 1 8 triangular rmse standard 0.0816 10 0.00281 Model53 ## 2 7 triangular rmse standard 0.0817 10 0.00278 Model52 ## 3 6 triangular rmse standard 0.0817 10 0.00279 Model51 ``` ```r # Or pick the numerically best results best_res <- select_best(knn_tune, metric = "rmse") best_res ``` ``` ## # A tibble: 1 x 3 ## neighbors weight_func .config ## <int> <chr> <chr> ## 1 8 triangular Model53 ``` --- # Plotting the results  ```r autoplot(knn_tune, metric = "rmse") ```  --- # Plotting the results - ENHANCE  ```r autoplot(knn_tune, metric = "rmse") + ylim(c(.07, .1)) ```  --- # Looking at the predictions  To do some diagnostic checks, let's subset on the best parameters and plot the observed vs predicted: .pull-left[ ```r knn_best_pred <- knn_tune %>% collect_predictions(parameters = best_res) %>% mutate(resid = Sale_Price - .pred) %>% arrange(desc(abs(resid))) knn_best_pred %>% slice(1:4) ``` ``` ## # A tibble: 4 x 8 ## id .pred .row neighbors weight_func Sale_Price .config resid ## <chr> <dbl> <int> <int> <chr> <dbl> <chr> <dbl> ## 1 Fold09 4.92 1173 8 triangular 4.12 Model59 -0.807 ## 2 Fold01 4.79 139 8 triangular 4.11 Model58 -0.686 ## 3 Fold06 5.03 2131 8 triangular 4.54 Model52 -0.482 ## 4 Fold09 5.12 1538 8 triangular 4.70 Model54 -0.416 ``` ```r knn_best_pred %>% ggplot(aes(x = Sale_Price, y = .pred)) + geom_abline(col = "green") + geom_point(alpha = .3) + coord_obs_pred() ``` ] .pull-right[  ] --- # Finalizing the model  If we are happy with these parameters, we can splice these back into the model so that a final fit can be created on the training set: .font70[ ```r ( final_knn_mod <- finalize_model(knn_mod, best_res) ) ``` ``` ## K-Nearest Neighbor Model Specification (regression) ## ## Main Arguments: ## neighbors = 8 ## weight_func = triangular ## ## Computational engine: kknn ``` ```r ( final_knn_fit <- final_knn_mod %>% last_fit(ames_rec, split = data_split) ) ``` ``` ## # Resampling results ## # Monte Carlo cross-validation (0.75/0.25) with 1 resamples ## # A tibble: 1 x 6 ## splits id .metrics .notes .predictions .workflow ## <list> <chr> <list> <list> <list> <list> ## 1 <split [2.2K/731]> train/test split <tibble [2 × 3]> <tibble [1 × 1]> <tibble [731 × 3]> <workflow> ``` ] --- # Test set results  .pull-left[ ```r # Test set results collect_metrics(final_knn_fit) ``` ``` ## # A tibble: 2 x 3 ## .metric .estimator .estimate ## <chr> <chr> <dbl> ## 1 rmse standard 0.0798 ## 2 rsq standard 0.784 ``` ```r final_knn_fit %>% collect_predictions() %>% ggplot(aes(x = Sale_Price, y = .pred)) + geom_abline(col = "green") + geom_point(alpha = .3) + coord_obs_pred() ``` ] .pull-right[  ] --- # Parallel Processing .pull-left[ There is no real barrier to running these models in parallel. Can we benefit from splitting the fits up to run on multiple cores? These speed-ups can be very model- and data-dependent but this pattern generally holds. Note that there is little incremental benefit to using more workers than physical cores on the computer. Use `parallel::detectCores(logical = FALSE)`. (A lot more details can be found in [this blog post](http://appliedpredictivemodeling.com/blog/2018/1/17/parallel-processing)) ] .pull-right[  In these simulations, we estimated the speed-up by using the sub-model trick to be about _25-fold_. ] --- # Running in Parallel with {tune} .pull-left[ To loop through the models and data sets, `tune` uses the [`foreach`](https://www.rdocumentation.org/packages/foreach) package, which can parallelize `for` loops. `foreach` has a number of _parallel backends_ which allow various technologies to be used in conjunction with the package. On CRAN, these are the "`do{X}`" packages, such as [`doAzureParallel`](https://github.com/Azure/doAzureParallel), [`doFuture`](https://www.rdocumentation.org/packages/doFuture), [`doMC`](https://www.rdocumentation.org/packages/doMC), [`doMPI`](https://www.rdocumentation.org/packages/doMPI), [`doParallel`](https://www.rdocumentation.org/packages/doParallel), [`doRedis`](https://www.rdocumentation.org/packages/doRedis), and [`doSNOW`](https://www.rdocumentation.org/packages/doSNOW). For example, `doMC` uses the `multicore` package, which forks processes to split computations (for unix and OS X). `doParallel` can be used for all operating systems. ] .pull-right[ To use parallel processing in `tune`, no changes are needed when calling `tune_*()`. The parallel technology must be _registered_ with `foreach` prior to calling `tune_*()`: ```r library(doParallel) cl <- makeCluster(6) registerDoParallel(cl) # run `tune_grid()`... stopCluster(cl) ``` ] --- # Model template code tidymodels code is a little more verbose than other frameworks (e.g. `caret`). For some common models, we can automatically generate code templates for certain models. ```r library(usemodels) use_xgboost(Sale_Price ~ ., data = ames) ``` The preprocessing that is used in the recipe (if any) is based on both the model and data set. For example, in the code above, we create dummy variables since `xgboost` doesn't do that for you (unlike almost all other tree ensemble models). These steps are omitted when there are no factor predictors.


You have been punished by the gods, and cast into the center of the Seven Circles of Hell! To escape the underworld, you must get through the six gates between each circle, and make it through the door back to the land of the living. Start by rolling the four-sided die to open the first gate. Don't be fooled by the ease of passing the first gate! Each succesive gate is locked by the next-highest number sided die, and you must match or exceed the value of your previous roll in order to pass!


Phone InfoThe phone that I'm using for this project is the Sony Ericsson T300. The T300 is a fist generation picture phone that's being sold as the entry-level phone for all the new T-mobile services (text messaging, picture mail, and Internet access). Unlike some other new phones, the camera is not integrated into the phone- you have to plug a special camera module into the base of the phone. The PhoneThe phone part of the T300 is your basic, modern cell phone. On the RF side of things, it's tri-band GSM, so you can take it with you to Europe (and pay outrageous surcharges). It also talks GPRS, WAP, and SMS, so you can do nerdy things with it, like check your email, get on the web, or send/receive text messages. I currently have a low opinion of these survices, as the data speeds are slow and the interface is 10x worse than a PDA (which is 10x worse than a PC). The display, of course, is part of the problem- while it looks nice with it's 256 colors, it just isn't detailed enough to display that much information. However, it is the right size for normal cell-phone tasks, and it doesn't seem to kill the battery too much. Physically, the phone feels kind of hollow and a little cheap. It's about the right size though, and is a good balance between being large enough to hold when in use, and small enough to fit in a pocket. Like other phones, you can replace the face plate of the phone with one of a different color or style. Mine came in the "redneck-motorboat-sparkly-green" color.  The CameraLike I said earlier, the T300 has a camera option that plugs into the base of the phone. The camera sells for about $50, but usually they give it to you for free (along with a carying pouch that hooks onto a keychain). I'm not sure, but I think the camera has a resolution of about 640x480, and enough flash memory to store about five pictures at that resolution. It has an "optical viewfinder", which is just a glass window below the sensor. Personally, I think they could have done without the viewfinder, as it adds to the size of the module. Plus, when you're about to take a picture, preview data is displayed on the phone's display screen at a couple frames per second, anyways.
One of the painful things about the camera attachment is that it plugs into the phone through that standard cell-phone connector at the bottom of the phone. I think this thing is just a slow, serial link (9600 baud?). In any case it takes a long freaking time to move data from the camera to the phone. Taking a PictureTaking a picture is a bit of a painful process. First you obviously have to plug the camera attachment into the phone. Every time I do this, I wonder how long it will be before the pins on the attachment will wear off. The damage may already be taking place- sometimes when I plug the camera in the phone doesn't notice anything (it should pop up camera options on the screen). Sigh.. The second step is actually taking a pictures. In theory, one could look through the optical viewfinder to take the picture. However, the viewfinder is at the bottom end of the (now foot-long) camera. Doing this makes me feel like a dork, because it looks like you're lookking through a parascope or something. Therefore, I usually just stick with looking at the phone's display to line up a picture. The on-screen preview is awfull- the resolution and colors are reduced, and the display lags by about a half second. It's good enough though. At some point you press the camera button to take the picture, meanwhile hoping that the force of pressing the button doesn't cause the camera module to become unplugged. Ahh done! Right? Well, not really. Now you've got to transfer the picture from the camera attachment to the phone. This takes some time- maybe about a minute for a 640x480 picture. During this time you have to be carefull with the phone- if the camera module becomes unplugged, you lose everything. When it finally finishes, all you have to do is.. preview the pic, tell the phone to send the message to an email address, wait for the phone to encode the picture as a mime attachment, pick an email address, and have the phone send the email as data. The data upload takes a while, and requires that you be somewhere that supports the phone's data services (that's usually most places that the phone works). If the phone can't send the message, it thankfully keeps a copy of it that you can send later. My Opinion?There are a lot of things that can be improved on with the T300. The image quality is pretty crappy, having the camera as a plugin module sucks, and the data transfer times are terrible. I also think the TV ads for these picture phones are incredibly misleading. They show happy-go-lucky yuppies snapping shots of each other (and the hedgehogs in their pants?) and emailing them away like crazy. I am confident that normal guys like my dad would be extremely disappointed in the amount of effort required to send a picture, and the quality of the picture. With that said, the camera phone does do what it's supposed to do if you have the patience. I think these things are awfully cool, and I can see how creative folks will find new and cool things to do with the technology. For my boring life, a camera phone is kind of overkill, but on the bright side of things, I can use it and the tmobile blog stuff to take snippets of my life and post them, more frequently than I would with just the normal blog stuff. |


Outside the digital screen we have learned to design architecture, learning materials like books and different mediums to accommodate the needs of others with disabilities and difficulties the majority of people may not have to deal with. The digital world is fairly new and learning to navigate design and innovate new ideas for technology users can be difficult in thinking outside the box. Many programmers and designers can be lazy and decide to stick with standards. Other companies like Apple have upped the bar and allowed themselves to get creative in coming up with ideas to reach outside the norm and invite in those who struggle with technology based access.
For this accessibility test I chose a blog site I visit frequently called Messy Nessy (https://www.messynessychic.com). This blog is fairly popular and designed nicely with plenty of followers on its social media accounts as well. Is it a site known for finding curiosities and historical quirky information on the web such as forgotten painters or oddities around the world. I will be using WAVE access tool online to look over the site (https://wave.webaim.org/).
Access Test
All I had to do to run the test was copy and paste the link to site into WAVE’s search tool. Once I did that a total of 30 errors and 30 alerts was detected by WAVE and this information came out on the left hand side bar.
Checking the errors it showed a few missing alternative texts and 7 missing form labels which shows that these parts of the site do not show larger clickable targets for form controls. Missing links to images was also presented 14 times saying that without these links, the site visitor has no reference to where this information is coming from. No headings was also a problem that has come up a lot. Lack of headings can lead to confusion for many users and derail the reading not knowing what topic they going into.
Orphaned labels was one alert I found interesting. Three were found within the site and WAVE indicates that the reason these are alerts is because there could be a problem with the coding meaning the labeling is a not associated with or providing functionality with the corresponding form control.
Thoughts
It seems that the accessibility issues were mainly due to managing references and linking items that may have an extension to other sites and information. I can definitely see how this can be an issue with a site that points out historical stories and oddities especially since it is information that isn’t easy to find. I was expecting there to be more issues since it is a standard blog. Seeing this I notice that there is a long way to go when it comes to correcting accessibility not only for those with disabilities, but with programmers correcting code in general when it comes to giving out the correct information.


Blacksmith Wilbert:
If you want to remove a seal on armor, then you've come to the right place - I'm the best there is. Whatever you want, just tell me.
Release seal on B-grade gloves and boots.
Put seal back on B-grade gloves and boots.
Release seal on A-grade armor.
Release seal on A-grade accessory.
Put seal back on A-grade armor.
Back


Preparation time
overnight
Cooking time
over 2 hours
Serves
Serves 4
Flakes of gammon accompany fried hake. Try making the pickled cucumbers a couple of days in advance for the best taste.
For the pickled cucumber, put the cucumber pieces in a heatproof bowl. In a pan, mix the vinegar, sugar, salt, white wine and honey with 400ml/14fl oz water and bring to the boil. Tip this over the cucumber, leave for five minutes and then sit the bowl over ice to cool. If cooking on the same day as the ham, store it in the fridge until needed, or keep in an airtight container in the fridge if making in advance.
For the ham hock, cover the hock in 5 litres/9 pints of water. Bring to the boil, then remove the hock and discard the water. Place the hock into 5 litres/9 pints of fresh water and add the garlic, thyme, bay leaf and peppercorns.
Bring to the boil and skim off any scum from the surface. Gently simmer with the lid on for about four hours, or until the meat is tender. Let it cool in the liquor until needed.
For the mustard sauce, heat a large frying pan. Once hot, add the shallots, garlic, thyme, white wine and white wine vinegar. Cook until the volume of liquid has reduced to nearly nothing. Add the cream and reduce again to half the volume.
Remove from the heat and whisk in the butter until emulsified. Strain through a sieve and then mix in the three types of mustard. Set aside and keep warm until ready to serve.
For the warm potato salad, put the potatoes, stock and salt in a large pan and boil until the potatoes are tender. Drain the potatoes then add the chives, shallots and the vinaigrette. Bring together and keep warm.
For the hake, preheat the oven to 200C/400F/Gas 6.
Cover the fish in the lemon zest and salt and leave for 15 minutes. In an ovenproof frying pan heat the oil to medium-hot. Wash the zest and salt from the fish. Place the fish in the pan skin-side down and fry for two minutes. Transfer the pan to the oven for three minutes. Remove from the oven, turn the fish over and leave to rest in the heat of the pan.
To serve, put a few spoonfuls of potatoes on each plate and flake three pieces of ham over the top. Place five or so pieces of cucumber around the plate. Put the fish on the potatoes too, then spoon some of the sauce over the cucumber and around the plate. Garnish with sea purslane and sea aster.


--- title: Fashion-MNIST database of fashion articles type: docs repo: https://github.com/rstudio/keras menu: main: name: Fashion-MNIST database of fashion articles - keras parent: keras-reference aliases: - /reference/keras/dataset_fashion_mnist.html - /keras/reference/dataset_fashion_mnist.html - /guide/keras/reference/dataset_fashion_mnist.html - /tools/tools/keras/reference/dataset_fashion_mnist.html - /installation/keras/reference/dataset_fashion_mnist.html - /tutorials/keras/reference/dataset_fashion_mnist.html - /guide/tools/keras/reference/dataset_fashion_mnist.html - /deploy/keras/reference/dataset_fashion_mnist.html - /tools/keras/reference/dataset_fashion_mnist.html - /tutorials/tools/keras/reference/dataset_fashion_mnist.html ---
Dataset of 60,000 28x28 grayscale images of the 10 fashion article classes, along with a test set of 10,000 images. This dataset can be used as a drop-in replacement for MNIST. The class labels are encoded as integers from 0-9 which correspond to T-shirt/top, Trouser, Pullover, Dress, Coat, Sandal, Shirt,
dataset_fashion_mnist()
Lists of training and test data: train$x, train$y, test$x, test$y
, where
x
is an array of grayscale image data with shape (num_samples, 28, 28) and y
is an array of article labels (integers in range 0-9) with shape (num_samples).
Dataset of 60,000 28x28 grayscale images of 10 fashion categories, along with a test set of 10,000 images. This dataset can be used as a drop-in replacement for MNIST. The class labels are:
0 - T-shirt/top
1 - Trouser
2 - Pullover
3 - Dress
4 - Coat
5 - Sandal
6 - Shirt
7 - Sneaker
8 - Bag
9 - Ankle boot
Other datasets:
dataset_boston_housing()
,
dataset_cifar100()
,
dataset_cifar10()
,
dataset_imdb()
,
dataset_mnist()
,
dataset_reuters()


{% extends "base.html" %}
{% block title %}Home{% endblock %}
{% block content%}
Dear, landlord approval is pending.
Share this link with lordlord.
Dear, landlord rejected your update request.
Rejection reason :
Dear, landlord approved your update request.
New address will soon be added to you Aadhar.


+callout-info
RAMADDA uses wiki text in a number of ways. You can create Wiki Page entries, you
can style any entry using wiki text and you can also add in a Page Style metadata element
that allows you to define the style used for a whole collection of entries.
-callout
RAMADDA provides a wiki text editor for use with all of the above ways of using wiki text:
Image 1: Wiki Text Editor
The menu bar provides a large number of options for entering the wiki text.
- Formatting - Basic wiki text formatting - sections, tabs, accoridion, slides, notes, etc.
- Misc - Further formatting options - title, heading, paragraph, links, etc
- Entries - Wiki display components used to display RAMADDA entries.
For single entries there is name, data, description, download, etc.
For multiple entiries there is tabletree, links, map, gallery, etc
- Import Entry - select an entry then specify how to embed it, e.g. Link, Tree, Gallery, or the entry specifier "entry=ID".
- Entry ID - Select an entry and insert its ID.
- Displays -
- Field ID -
- Etc... - A live preview window, word count and links to help.
The wiki editor supports collapsing sections of text with the little caret links on the
left of the page. For example, here is a page:
And collapsing after:
One of the entry types that RAMADDA provides is a Wiki Page entry.

In the form select "Wiki Page" to go to the Wiki Page create form:
Image 4: Wiki Page Create Form
You can use the wiki text display capabilities to customize the default
HTML view of any other entry or folder types. In the description of the entry
click on the
checkbox. This enables the wiki text editor:
Image 5: Wiki Entry Description


So far, we have identified the authorities and privileges that are available, and we have examined how these authorities and privileges are granted and revoked. But to use authorities and privileges effectively, you must be able to determine which authorities and privileges are appropriate for an individual user and which are not. Often, a blanket set of authorities and privileges are assigned to an individual, based on his or her job title and/or job responsibilities. Then, as the individual begins to work with the database, the set of authorities and privileges he or she has is modified as appropriate. Some of the more common job titles used, along with the tasks that usually accompany them and the authorities/privileges needed to perform those tasks, can be seen in Table 3-2.
|
Job Title |
Tasks |
Authorities/Privileges Needed |
|---|---|---|
|
Department Administrator |
Oversees the departmental system; designs and creates databases |
System Control (SYSCTRL) authority or System Administrator (SYSADM) authority (if the department has its own instance) |
|
Security Administrator |
Grants authorities and privileges to other users and revokes them, if necessary |
System Administrator (SYSADM) authority or Database Administrator (DBADM) authority (Security Administrator [SECADM] authority if label-based access control is used) |
|
Database Administrator |
Designs, develops, operates, safeguards, and maintains one or more databases |
Database Administrator (DBADM) authority over one or more databases and System Maintenance (SYSMAINT) authority, or in some cases System Control (SYSCTRL) authority, over the instance(s) that control the databases |
|
System Operator |
Monitors the database and performs routine backup operations. Also performs recovery operations if needed |
System Maintenance (SYSMAINT) authority or System Monitor (SYSMON) authority |
|
Application Developer/Programmer |
Develops and tests database/DB2 Database Manager application programs; may also create test tables and populate them with data |
CONNECT and CREATE_TAB privilege for one or more databases, BINDADD and BIND privilege on one or more packages, one or more schema privileges for one or more schemas, and one or more table privileges for one or more tables; CREATE_EXTERNAL_ROU-TINE privilege for one or more databases may also be required |
|
User Analyst |
Defines the data requirements for an application program by examining the database structure using the system catalog views |
CONNECT privilege for one or more databases and SELECT privilege on the system catalog views |
|
End User |
Executes one or more application programs |
CONNECT privilege for one or more databases and EXECUTE privilege on the package associated with each application used; if an application program contains dynamic SQL statements, SELECT, INSERT, UPDATE and DELETE privileges for one or more tables may be needed as well |
|
Information Center Consultant |
Defines the data requirements for a query user; provides the data needed by creating tables and views and by granting access to one or more database objects |
Database Administrator (DBADM) authority for one or more databases |
|
Query User |
Issues SQL statements (usually from the Command Line Processor) to retrieve, add, update, or delete data (may also save results of queries in tables) |
CONNECT privilege on one or more databases, SELECT, INSERT, UPDATE, and DELETE privilege on each table used, and CREATEIN privilege on the schema in which tables and views are to be created |
|
Adapted from Table 78 on pages 608–609 of the IBM DB2 Version 9 for Linux, UNIX, and Windows Administration Guide-Implementation Manual. |


At Proficiency
100-76%
Near Proficiency
100-76%
Not Proficient
100-76%
Not Started
At Proficiency
100-76%
Near Proficiency
100-76%
Not Proficient
100-76%
Not Started
At Proficiency
100-76%
Near Proficiency
100-76%
Not Proficient
100-76%
Not Started
| App | Activity | Standard Level | Concept | |
|---|---|---|---|---|
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense | ||
| Training for the Gold (Sport) | 4 | Subject-Verb Tense |
| Training for the Gold | ||
| Past Tense Verbs | ||
| Possessive Nouns | ||
| Singular and Plural Nouns with Matching Verbs | ||
| Referencing an Article |
| Student Name | Username | |
|---|---|---|
| Magdalena Montgomery-Kent | Magdalena.Montgomery-kent@merry-honey | Edit Account |
| Physics of the Future 312 | Magic-Stone | Edit Account |
| Death by Black Hole & Cosmic Quandaries | Whole-Earth | Edit Account |
| An Appetite for Wonder 202 | Agave-Space | Edit Account |


--- layout: page title: Rigel tags: [] status: publish type: page published: true meta: _edit_last: "1" _wp_page_template: default ---
This is a GNU/Linux 3D Modelling Application. It supports a limited set of polygon objects (cube, cone, cylinder), standard transformation tools (rotate, translate, scale), interactive picking/selection of objects and sub-object components, and subobject component editing (edge/face/vertex transformations, face/edge splitting). It is built using GTK-- for the interface and renders 3D scenes using OpenGL.


Portable client code for using Burlap services. Since this package is
independent of all Resin code, its classes can be copied to a
non-Resin client jar.
RPC Proxy Clients - BurlapProxyFactory
Most application clients will use BurlapProxyFactory to
create stub objects. The stub objects can be called with normal
Java calls. Because the objects are remote, the client application needs
to be able to deal with IOException caused by an unavailable server or
a protocol error.
import com.caucho.burlap.client.BurlapProxyFactory;
...
URL url = new URL("http://localhost:8080/ejb/hello");
HelloHome hello = (HelloHome) factory.create(HelloHome.class, url);
System.out.println("hello: " + hello.hello());
Serialization
Since the Burlap protocol serializes Java objects to XML, the
BurlapSerializerOutput and BurlapSerializerInput
can be used for serialization.
Serialization
OutputStream os = new FileOutputStream("test.xml");
BurlapOutput out = new BurlapSerializerOutput(os);
out.writeObject(obj);
os.close();
Deserialization
InputStream is = new FileInputStream("test.xml");
BurlapInput in = new BurlapSerializerInput(in);
Object obj = in.readObject();
is.close();
MicroBurlapInput and MicroBurlapOutput
These two classes only require classes from Java MicroEdition. So they
can be extracted separately into a burlap-micro.jar. Because of this
restriction and their small size, these two classes
are ideal for limited size devices like mobile phones and PDAs.


{{ post.title }}
PUBLISHED ON {{ post.date | date: "%B %d, %Y" }}
--- layout: master title: Reading List | description: Landing Page for the blog bloghome: true ---
As a small experiment I thought to share my reading list (which I think probably are best articles I read on internet or I think people should read it for some valid reason). I haven't really read all articles and books shared here but I am in a process to do so. Some of the below articles are really hard to understand and even far from my understanding but keeping them in a wish list doesn't harm. Hopefully enough intellect will develop soon to understand those articles too.
Note: The below list is being automatically generated from my trello board . Any card with tag "public" in the board will appear here


childprocess
======
This gem aims at being a simple and reliable solution for controlling external programs running in the background on any Ruby / OS combination.
The code originated in the selenium-webdriver gem, but should prove useful as a standalone library.
[![Build Status](secure.travis-ci.org/jarib/childprocess.png)](http://travis-ci.org/jarib/childprocess)
Usage
```ruby process = ChildProcess.build(“ruby”, “-e”, “sleep”)
# inherit stdout/stderr from parent... process.io.inherit!
# …or pass an IO process.io.stdout = Tempfile.new(“child-output”)
# modify the environment for the child process.environment[“a”] = “b” process.environment[“c”] = nil
# start the process process.start
# check process status process.alive? #=> true process.exited? #=> false
# wait indefinitely for process to exit... process.wait process.exited? #=> true
# …or poll for exit + force quit begin
process.poll_for_exit(10)
rescue ChildProcess::TimeoutError
process.stop # tries increasingly harsher methods to kill the process.
end ```
The object returned from ChildProcess.build will implement ChildProcess::AbstractProcess.
Implementation
How the process is launched and killed depends on the platform:
- Unix : fork + exec (or posix_spawn if enabled)
- Windows : CreateProcess and friends
- JRuby : java.lang.{Process,ProcessBuilder}
Note on Patches/Pull Requests
- Fork the project.
- Make your feature addition or bug fix.
- Add tests for it. This is important so I don’t break it in a future version unintentionally.
- Commit, do not mess with rakefile, version, or history. (if you want to have your own version, that is fine but bump version in a commit by itself I can ignore when I pull)
- Send me a pull request. Bonus points for topic branches.
Copyright
Copyright © 2010-2012 Jari Bakken. See LICENSE for details.


public final class WikipediaTokenizer extends Tokenizer
AttributeSource.AttributeFactory
,
AttributeSource.State
| Modifier and Type | Field and Description |
|---|---|
static int
|
ACRONYM_ID
|
static int
|
ALPHANUM_ID
|
static int
|
APOSTROPHE_ID
|
static
String
|
BOLD
|
static int
|
BOLD_ID
|
static
String
|
BOLD_ITALICS
|
static int
|
BOLD_ITALICS_ID
|
static int
|
BOTH
Output the both the untokenized token and the splits
|
static
String
|
CATEGORY
|
static int
|
CATEGORY_ID
|
static
String
|
CITATION
|
static int
|
CITATION_ID
|
static int
|
CJ_ID
|
static int
|
COMPANY_ID
|
static int
|
EMAIL_ID
|
static
String
|
EXTERNAL_LINK
|
static int
|
EXTERNAL_LINK_ID
|
static
String
|
EXTERNAL_LINK_URL
|
static int
|
EXTERNAL_LINK_URL_ID
|
static
String
|
HEADING
|
static int
|
HEADING_ID
|
static int
|
HOST_ID
|
static
String
|
INTERNAL_LINK
|
static int
|
INTERNAL_LINK_ID
|
static
String
|
ITALICS
|
static int
|
ITALICS_ID
|
static int
|
NUM_ID
|
static
String
|
SUB_HEADING
|
static int
|
SUB_HEADING_ID
|
static
String
[]
|
TOKEN_TYPES
String token types that correspond to token type int constants
|
static int
|
TOKENS_ONLY
Only output tokens
|
static int
|
UNTOKENIZED_ONLY
Only output untokenized tokens, which are tokens that would normally be split into several tokens
|
static int
|
UNTOKENIZED_TOKEN_FLAG
This flag is used to indicate that the produced "Token" would, if
TOKENS_ONLY
was used, produce multiple tokens.
|
| Constructor and Description |
|---|
WikipediaTokenizer
(
AttributeSource.AttributeFactory
factory,
Reader
input,
int tokenOutput,
Set
<
String
> untokenizedTypes)
Creates a new instance of the
WikipediaTokenizer
.
|
WikipediaTokenizer
(
AttributeSource
source,
Reader
input,
int tokenOutput,
Set
<
String
> untokenizedTypes)
Creates a new instance of the
WikipediaTokenizer
.
|
WikipediaTokenizer
(
Reader
input)
Creates a new instance of the
WikipediaTokenizer
.
|
WikipediaTokenizer
(
Reader
input,
int tokenOutput,
Set
<
String
> untokenizedTypes)
Creates a new instance of the
WikipediaTokenizer
.
|
| Modifier and Type | Method and Description |
|---|---|
void
|
end
()
This method is called by the consumer after the last token has been
consumed, after
TokenStream.incrementToken()
returned
false
(using the new
TokenStream
API).
|
boolean
|
incrementToken
()
Consumers (i.e.,
IndexWriter
) use this method to advance the stream to
the next token.
|
void
|
reset
()
Resets this stream to the beginning.
|
void
|
reset
(
Reader
reader)
Expert: Reset the tokenizer to a new reader.
|
close
,
correctOffset
addAttribute
,
addAttributeImpl
,
captureState
,
clearAttributes
,
cloneAttributes
,
copyTo
,
equals
,
getAttribute
,
getAttributeClassesIterator
,
getAttributeFactory
,
getAttributeImplsIterator
,
hasAttribute
,
hasAttributes
,
hashCode
,
reflectAsString
,
reflectWith
,
restoreState
,
toString
public static final String INTERNAL_LINK
public static final String EXTERNAL_LINK
public static final String EXTERNAL_LINK_URL
public static final String CITATION
public static final String CATEGORY
public static final String BOLD
public static final String ITALICS
public static final String BOLD_ITALICS
public static final String HEADING
public static final String SUB_HEADING
public static final int ALPHANUM_ID
public static final int APOSTROPHE_ID
public static final int ACRONYM_ID
public static final int COMPANY_ID
public static final int EMAIL_ID
public static final int HOST_ID
public static final int NUM_ID
public static final int CJ_ID
public static final int INTERNAL_LINK_ID
public static final int EXTERNAL_LINK_ID
public static final int CITATION_ID
public static final int CATEGORY_ID
public static final int BOLD_ID
public static final int ITALICS_ID
public static final int BOLD_ITALICS_ID
public static final int HEADING_ID
public static final int SUB_HEADING_ID
public static final int EXTERNAL_LINK_URL_ID
public static final String [] TOKEN_TYPES
public static final int TOKENS_ONLY
public static final int UNTOKENIZED_ONLY
public static final int BOTH
public static final int UNTOKENIZED_TOKEN_FLAG
TOKENS_ONLY
was used, produce multiple tokens.
public WikipediaTokenizer( Reader input)
WikipediaTokenizer
. Attaches the
input
to a newly created JFlex scanner.
input
- The Input Reader
public WikipediaTokenizer( Reader input, int tokenOutput, Set < String > untokenizedTypes)
WikipediaTokenizer
. Attaches the
input
to a the newly created JFlex scanner.
input
- The input
tokenOutput
- One of
TOKENS_ONLY
,
UNTOKENIZED_ONLY
,
BOTH
untokenizedTypes
-
public WikipediaTokenizer( AttributeSource.AttributeFactory factory, Reader input, int tokenOutput, Set < String > untokenizedTypes)
WikipediaTokenizer
. Attaches the
input
to a the newly created JFlex scanner. Uses the given
AttributeSource.AttributeFactory
.
input
- The input
tokenOutput
- One of
TOKENS_ONLY
,
UNTOKENIZED_ONLY
,
BOTH
untokenizedTypes
-
public WikipediaTokenizer( AttributeSource source, Reader input, int tokenOutput, Set < String > untokenizedTypes)
WikipediaTokenizer
. Attaches the
input
to a the newly created JFlex scanner. Uses the given
AttributeSource
.
input
- The input
tokenOutput
- One of
TOKENS_ONLY
,
UNTOKENIZED_ONLY
,
BOTH
untokenizedTypes
-
public final boolean incrementToken() throws IOException
TokenStream
IndexWriter
) use this method to advance the stream to
the next token. Implementing classes must implement this method and update
the appropriate
AttributeImpl
s with the attributes of the next
token.
The producer must make no assumptions about the attributes after the method
has been returned: the caller may arbitrarily change it. If the producer
needs to preserve the state for subsequent calls, it can use
AttributeSource.captureState()
to create a copy of the current attribute state.
This method is called for every token of a document, so an efficient
implementation is crucial for good performance. To avoid calls to
AttributeSource.addAttribute(Class)
and
AttributeSource.getAttribute(Class)
,
references to all
AttributeImpl
s that this stream uses should be
retrieved during instantiation.
To ensure that filters and consumers know which attributes are available,
the attributes must be added during instantiation. Filters and consumers
are not required to check for availability of attributes in
TokenStream.incrementToken()
.
incrementToken
in class
TokenStream
IOException
public void reset() throws IOException
TokenStream
TokenStream.reset()
is not needed for
the standard indexing process. However, if the tokens of a
TokenStream
are intended to be consumed more than once, it is
necessary to implement
TokenStream.reset()
. Note that if your TokenStream
caches tokens and feeds them back again after a reset, it is imperative
that you clone the tokens when you store them away (on the first pass) as
well as when you return them (on future passes after
TokenStream.reset()
).
reset
in class
TokenStream
IOException
public void reset( Reader reader) throws IOException
Tokenizer
reset
in class
Tokenizer
IOException
public void end() throws IOException
TokenStream
TokenStream.incrementToken()
returned
false
(using the new
TokenStream
API). Streams implementing the old API
should upgrade to use this feature.
This method can be used to perform any end-of-stream operations, such as setting the final offset of a stream. The final offset of a stream might differ from the offset of the last token eg in case one or more whitespaces followed after the last token, but a
WhitespaceTokenizer
was used.
end
in class
TokenStream
IOException


Coding Quiz Challenge
You have 60 seconds to answer 17 random questions. You get one point for every question you answer correctly. Answer incorrectly, and you'll lose 10 seconds. Good luck!
Timer: 60
You have 60 seconds to answer 17 random questions. You get one point for every question you answer correctly. Answer incorrectly, and you'll lose 10 seconds. Good luck!


It’s been decades since Minnesota saw an election year as consequential as 2018. With an open race for governor, both U.S. Senate seats on the ballot, a handful of highly competitive U.S. House races, and control of the Legislature up for grabs, the decisions made by Minnesota voters this year will echo across state and national politics for many more to come.
The Star Tribune has invited candidates to participate in its online and printed election guides, asking them to provide information about themselves and views on top issues ahead of the Nov. 6 general election. You’ll find information in this guide about the candidates for the governor’s office and other statewide executive posts, along with the candidates for U.S. Senate and House.
Minnesotans don’t have to wait until Nov. 6 to vote; early voting begins on Sept. 21, at which point all eligible voters may obtain an absentee ballot through the mail or in person (Find your polling place here). Keep reading the Star Tribune for more coverage of campaigns and candidates right up to Election Day and continuing coverage after the votes are counted.
Follow our coverage of this campaign season by signing up to the Star Tribune's daily politics newsletter.
{office.distAreas}
{/if}{head.party}
{head.bio}
{#if head.ststory} Star Tribune profile {/if} Candidate website
{bio.bio}
{#if bio.ststory} Star Tribune profile {/if} Candidate website
{response.last}: { response.text }
{/each}Other candidates: {office.thirdparty}
Contributors: Judy Keen, Jessie Van Berkel, Susan Hilliard, Patrick Condon
Design: C.J. Sinner
Development: C.J. Sinner, Alan Palazzolo
Photography: Glen Stubbe, Star Tribune; Provided by campaigns, Associated Press
Illustration: Tim Enthoven, Special to the Star Tribune


Copyright {{vm.date.getFullYear()}} National Technology & Engineering Solutions of Sandia, LLC (NTESS). Under the terms of Contract DE-NA0003525 with NTESS, the U.S. Government retains certain rights in this software.
| {{product.name}} | {{product.license}} |