Stack Container¶
The Stack container module holds a list of elements. Elements are added to the top of the stack, and retrieved from the top of the stack (FIFO).
List of Functions¶
-
class
containers.stack.
Stack
(elements=None)¶ Bases:
object
Instantiate a new Stack.
Parameters: elements (list) – list of elements (optional) Examples
>>> s1 = Stack() >>> s2 = Stack([1, 2, 3, 4, 5]) >>> print(s1) [] >>> print(s2) [5, 4, 3, 2, 1]
-
clear
()¶ Clear all elements from the stack.
Examples
>>> s1 = Stack([1, 2, 3]) >>> s1.clear() >>> print(s1) []
-
isEmpty
()¶ Checks if stack is empty.
Examples
>>> s1 = Stack([1, 2, 3]) >>> v1 = s1.isEmpty() >>> print(v1) False >>> s2 = Stack() >>> v2 = s2.isEmpty() >>> print(v2) True
Returns: True or False Return type: bool
-
peek
()¶ - Preview first element in stack.
- Only returns None if stack is empty.
Examples
>>> s1 = Stack([1, 2, 3]) >>> v1 = s1.peek() >>> print(v1) 3 >>> s2 = Stack() >>> v2 = s2.peek() >>> print(v2) None
Returns: first element in stack or None Return type: mixed
-
pop
()¶ - Pop first element off stack and return.
- Returns None if stack is empty.
Examples
>>> s1 = Stack([1, 2, 3]) >>> v1 = s1.pop() >>> print(v1) 3 >>> print(s1) [2, 1]
Returns: first element in stack or None Return type: mixed
-
push
(value)¶ Pushes a new value to front of stack.
Parameters: value (mixed) – new element Examples
>>> s1 = Stack([1, 2, 3]) >>> s1.push(4) >>> print(s1) [4, 3, 2, 1]
-


Master index
Index for PS_primal_sketch\misc
Dependency Graph for PS_primal_sketch\misc
Generated on Sun 30-Sep-2007 20:39:06 by
m2html
© 2003


This is the first html page created
This is level 1 heading
This is level 2 heading
This is level 3 heading


Cain Flying Knife:
First, meet with the
saint
. My colleagues tell me that she is in a
tent near the Altar of Rites.
She will know the truth about the incident.


Notice: (provided by International Swaps and Derivatives Association, Inc.)
Unauthorized access to or use of this system is prohibited.
All access and use may be monitored and recorded.
Contact: ISDA Information Technology
Location: New York


bake and its depedencies can be found on rubygems, which is configured as ruby source per default. Type "gem sources" if you wish to check that.
Installing bake is very easy:
gem install bake-toolkit
This is how the installation could look like:
>>> gem install bake-toolkit
Fetching: highline-1.6.15.gem (100%)
Fetching: colored-1.2.gem (100%)
Fetching: progressbar-0.11.0.gem (100%)
Fetching: rgen-0.6.0.gem (100%)
Fetching: rtext-0.2.0.gem (100%)
Fetching: bake-toolkit-1.0.2.gem (100%)
Successfully installed highline-1.6.15
Successfully installed colored-1.2
Successfully installed progressbar-0.11.0
Successfully installed rgen-0.6.0
Successfully installed rtext-0.2.0
Successfully installed bake-toolkit-1.0.2
7 gems installed
Installing ri documentation for highline-1.6.15...
Installing ri documentation for colored-1.2...
Installing ri documentation for progressbar-0.11.0...
Installing ri documentation for rgen-0.6.0...
Installing ri documentation for rtext-0.2.0...
Installing ri documentation for bake-toolkit-1.0.2...
Installing RDoc documentation for highline-1.6.15...
Installing RDoc documentation for colored-1.2...
Installing RDoc documentation for progressbar-0.11.0...
Installing RDoc documentation for rgen-0.6.0...
Installing RDoc documentation for rtext-0.2.0...
Installing RDoc documentation for bake-toolkit-1.0.2...
LC_ALL=en_US
ERROR: While generating documentation for ...
... MESSAGE: Error while evaluating ...
undefined method `gsub' for nil:NilClass ...
It's a ruby bug. However, the gems were installed correctly. You can avoid building the documentation by installing bake like this:
gem install bake-toolkit --no-rdoc --no-ri


Do you think that as long as humans are the ones building the robots, we'll be okay? This simple webpage might change your mind.
Let's see what happens!
The robot says:
Try again, if you dare!


Class Clipping
Clipping class
Namespace: OwsProxy3\CoreBundle\Component
Author: Paul Schmidt
Located at OwsProxy3/CoreBundle/Component/Clipping.php
Author: Paul Schmidt
Located at OwsProxy3/CoreBundle/Component/Clipping.php
Methods summary
public
|
|
public
|
|
public
boolean
|
|
public
boolean
|
|
public
string
|
|
public
|
#
findSvgGeometry( type $conn, array $MultiPointBbox, string $database, string $geomColumn, string $whereCol, array $whereColValues, integer $width, integer $height )
Queries the svgEnvelope and the svgGeometry from the database |
public
|
#
findWktGeometry( type $conn, array $MultiPointBbox, string $database, string $geomColumn, string $whereCol, array $whereColValues, integer $width, integer $height )
Queries the svgEnvelope and the svgGeometry from the database |
public
string
|
|
public
Imagick
|
#
clipImage( type $sourceImage, type $maskImage, string $format )
Clips the svgGeometry from the image |
public
Imagick
|
|
public
boolean
|
#
checkFeatureInfo( type $conn, string $database, string $whereCol, array $whereColValues, string $geomCol,
Checks if |


| 32 | (A) | a beke of waspe bees brede in hys nese |
| 32 | (C) | A byke of waspes bredde in his nose |
| 32 | (D) | A byker of waspis & bees bred in his nase |
| 32 | (E) | A swarm of waspes & of bees . bredde yn his nose . |
| (Ex) | ---- no text ---- | |
| 32 | (L) | abikere a bikere of waspen bees bredde on his nose |
| 31 | (P) | A byke of waspes bees bredde in his nese |
| 32 | (U) | A byke of waspes and bees / brad in his nase |
| (V) | ---- no text ---- |


Home
Lessons
Exercices
## State For this exercice we will creating a default state for our `App.js` and then modifing that state when pushing on an element on the page. It should look something like this :
if your are having problems you can download the completed `src` [here](/react-course/img/downloads/exercices/exercice-6/src.zip) ---


About Keras models
There are two main types of models available in Keras: the Sequential model, and the Model class used with the functional API.
These models have a number of methods and attributes in common:
model.layers
is a flattened list of the layers comprising the model.model.inputs
is the list of input tensors of the model.model.outputs
is the list of output tensors of the model.model.summary()
prints a summary representation of your model. For layers with multiple outputs,multiple
is displayed instead of each individual output shape due to size limitations. Shortcut for utils.print_summarymodel.get_config()
returns a dictionary containing the configuration of the model. The model can be reinstantiated from its config via:
config = model.get_config()
model = Model.from_config(config)
# or, for Sequential:
model = Sequential.from_config(config)
model.get_weights()
returns a list of all weight tensors in the model, as Numpy arrays.model.set_weights(weights)
sets the values of the weights of the model, from a list of Numpy arrays. The arrays in the list should have the same shape as those returned byget_weights()
.model.to_json()
returns a representation of the model as a JSON string. Note that the representation does not include the weights, only the architecture. You can reinstantiate the same model (with reinitialized weights) from the JSON string via:
from keras.models import model_from_json
json_string = model.to_json()
model = model_from_json(json_string)
model.to_yaml()
returns a representation of the model as a YAML string. Note that the representation does not include the weights, only the architecture. You can reinstantiate the same model (with reinitialized weights) from the YAML string via:
from keras.models import model_from_yaml
yaml_string = model.to_yaml()
model = model_from_yaml(yaml_string)
model.save_weights(filepath)
saves the weights of the model as a HDF5 file.model.load_weights(filepath, by_name=False)
loads the weights of the model from a HDF5 file (created bysave_weights
). By default, the architecture is expected to be unchanged. To load weights into a different architecture (with some layers in common), useby_name=True
to load only those layers with the same name.
Note: Please also see How can I install HDF5 or h5py to save my models in Keras? in the FAQ for instructions on how to install h5py
.
Model subclassing
In addition to these two types of models, you may create your own fully-customizable models by subclassing the Model
class
and implementing your own forward pass in the call
method (the Model
subclassing API was introduced in Keras 2.2.0).
Here's an example of a simple multi-layer perceptron model written as a Model
subclass:
import keras
class SimpleMLP(keras.Model):
def __init__(self, use_bn=False, use_dp=False, num_classes=10):
super(SimpleMLP, self).__init__(name='mlp')
self.use_bn = use_bn
self.use_dp = use_dp
self.num_classes = num_classes
self.dense1 = keras.layers.Dense(32, activation='relu')
self.dense2 = keras.layers.Dense(num_classes, activation='softmax')
if self.use_dp:
self.dp = keras.layers.Dropout(0.5)
if self.use_bn:
self.bn = keras.layers.BatchNormalization(axis=-1)
def call(self, inputs):
x = self.dense1(inputs)
if self.use_dp:
x = self.dp(x)
if self.use_bn:
x = self.bn(x)
return self.dense2(x)
model = SimpleMLP()
model.compile(...)
model.fit(...)
Layers are defined in __init__(self, ...)
, and the forward pass is specified in call(self, inputs)
. In call
, you may specify custom losses by calling self.add_loss(loss_tensor)
(like you would in a custom layer).
In subclassed models, the model's topology is defined as Python code (rather than as a static graph of layers). That means the model's topology cannot be inspected or serialized. As a result, the following methods and attributes are not available for subclassed models:
model.inputs
andmodel.outputs
.model.to_yaml()
andmodel.to_json()
model.get_config()
andmodel.save()
.
Key point: use the right API for the job. The Model
subclassing API can provide you with greater flexbility for implementing complex models,
but it comes at a cost (in addition to these missing features):
it is more verbose, more complex, and has more opportunities for user errors. If possible, prefer using the functional API, which is more user-friendly.


If you share the same interest with me and would like to be my next travel buddy, I would love to meet you.


|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object javax.swing.text.View org.fife.ui.rsyntaxtextarea.SyntaxView
public class SyntaxView
The javax.swing.text.View
object used by RSyntaxTextArea
when word wrap is disabled. It implements syntax highlighting for
programming languages using the colors and font styles specified by the
RSyntaxTextArea
.
You don't really have to do anything to use this class, as
RSyntaxTextAreaUI
automatically sets the text area's view to be
an instance of this class if word wrap is disabled.
The tokens that specify how to paint the syntax-highlighted text are gleaned
from the text area's RSyntaxDocument
.
| Field Summary |
|---|
| Fields inherited from class javax.swing.text.View |
|---|
BadBreakWeight, ExcellentBreakWeight, ForcedBreakWeight, GoodBreakWeight, X_AXIS, Y_AXIS |
| Fields inherited from interface javax.swing.SwingConstants |
|---|
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST |
| Constructor Summary | |
|---|---|
SyntaxView(javax.swing.text.Element elem)
Constructs a new SyntaxView wrapped around an element. |
| Method Summary | |
|---|---|
void |
changedUpdate(javax.swing.event.DocumentEvent changes,
java.awt.Shape a,
javax.swing.text.ViewFactory f)
Gives notification from the document that attributes were changed in a location that this view is responsible for. |
protected void |
damageLineRange(int line0,
int line1,
java.awt.Shape a,
java.awt.Component host)
Repaint the given line range. |
int |
getNextVisualPositionFrom(int pos,
javax.swing.text.Position.Bias b,
java.awt.Shape a,
int direction,
javax.swing.text.Position.Bias[] biasRet)
Provides a way to determine the next visually represented model location that one might place a caret. |
float |
getPreferredSpan(int axis)
Determines the preferred span for this view along an axis. |
Token |
getTokenListForPhysicalLineAbove(int offset)
Returns a token list for the physical line above the physical line containing the specified offset into the document. |
Token |
getTokenListForPhysicalLineBelow(int offset)
Returns a token list for the physical line below the physical line containing the specified offset into the document. |
void |
insertUpdate(javax.swing.event.DocumentEvent changes,
java.awt.Shape a,
javax.swing.text.ViewFactory f)
Gives notification that something was inserted into the document in a location that this view is responsible for. |
protected java.awt.Rectangle |
lineToRect(java.awt.Shape a,
int line)
Determine the rectangle that represents the given line. |
java.awt.Shape |
modelToView(int p0,
javax.swing.text.Position.Bias b0,
int p1,
javax.swing.text.Position.Bias b1,
java.awt.Shape a)
Provides a mapping, for a given region, from the document model coordinate space to the view coordinate space. |
java.awt.Shape |
modelToView(int pos,
java.awt.Shape a,
javax.swing.text.Position.Bias b)
Provides a mapping from the document model coordinate space to the coordinate space of the view mapped to it. |
float |
nextTabStop(float x,
int tabOffset)
Returns the next tab stop position after a given reference position. |
void |
paint(java.awt.Graphics g,
java.awt.Shape a)
Actually paints the text area. |
void |
removeUpdate(javax.swing.event.DocumentEvent changes,
java.awt.Shape a,
javax.swing.text.ViewFactory f)
Gives notification that something was removed from the document in a location that this view is responsible for. |
void |
setSize(float width,
float height)
|
protected void |
updateDamage(javax.swing.event.DocumentEvent changes,
java.awt.Shape a,
javax.swing.text.ViewFactory f)
Repaint the region of change covered by the given document event. |
int |
viewToModel(float fx,
float fy,
java.awt.Shape a,
javax.swing.text.Position.Bias[] bias)
Provides a mapping from the view coordinate space to the logical coordinate space of the model. |
int |
yForLine(java.awt.Rectangle alloc,
int line)
Returns the y-coordinate of the specified line. |
int |
yForLineContaining(java.awt.Rectangle alloc,
int offs)
Returns the y-coordinate of the line containing a specified offset. |
| Methods inherited from class javax.swing.text.View |
|---|
append, breakView, createFragment, forwardUpdate, forwardUpdateToView, getAlignment, getAttributes, getBreakWeight, getChildAllocation, getContainer, getDocument, getElement, getEndOffset, getGraphics, getMaximumSpan, getMinimumSpan, getParent, getResizeWeight, getStartOffset, getToolTipText, getView, getViewCount, getViewFactory, getViewIndex, getViewIndex, insert, isVisible, modelToView, preferenceChanged, remove, removeAll, replace, setParent, updateChildren, updateLayout, viewToModel |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SyntaxView(javax.swing.text.Element elem)
SyntaxView
wrapped around an element.
elem
- The element representing the text to display.| Method Detail |
|---|
public void changedUpdate(javax.swing.event.DocumentEvent changes, java.awt.Shape a, javax.swing.text.ViewFactory f)
changedUpdate
in class javax.swing.text.View
changes
- the change information from the associated documenta
- the current allocation of the viewf
- the factory to use to rebuild if the view has childrenView.changedUpdate(javax.swing.event.DocumentEvent, java.awt.Shape, javax.swing.text.ViewFactory)
protected void damageLineRange(int line0, int line1, java.awt.Shape a, java.awt.Component host)
line0
- The starting line number to repaint. This must
be a valid line number in the model.line1
- The ending line number to repaint. This must
be a valid line number in the model.a
- The region allocated for the view to render into.host
- The component hosting the view (used to call repaint).public int getNextVisualPositionFrom(int pos, javax.swing.text.Position.Bias b, java.awt.Shape a, int direction, javax.swing.text.Position.Bias[] biasRet) throws javax.swing.text.BadLocationException
getNextVisualPositionFrom
in class javax.swing.text.View
pos
- the position to convert >= 0a
- the allocated region to render intodirection
- the direction from the current position that can
be thought of as the arrow keys typically found on a keyboard.
This may be SwingConstants.WEST, SwingConstants.EAST,
SwingConstants.NORTH, or SwingConstants.SOUTH.
javax.swing.text.BadLocationException
java.lang.IllegalArgumentException
- for an invalid directionpublic float getPreferredSpan(int axis)
getPreferredSpan
in class javax.swing.text.View
axis
- may be either View.X_AXIS or View.Y_AXIS
java.lang.IllegalArgumentException
- for an invalid axispublic Token getTokenListForPhysicalLineAbove(int offset)
offset
, since lines
are not wrapped.
getTokenListForPhysicalLineAbove
in interface TokenOrientedView
offset
- The offset in question.
offset
is in the first line in
the document, null
is returned.public Token getTokenListForPhysicalLineBelow(int offset)
offset
, since lines
are not wrapped.
getTokenListForPhysicalLineBelow
in interface TokenOrientedView
offset
- The offset in question.
offset
is in the last physical
line in the document, null
is returned.public void insertUpdate(javax.swing.event.DocumentEvent changes, java.awt.Shape a, javax.swing.text.ViewFactory f)
insertUpdate
in class javax.swing.text.View
changes
- The change information from the associated document.a
- The current allocation of the view.f
- The factory to use to rebuild if the view has children.protected java.awt.Rectangle lineToRect(java.awt.Shape a, int line)
a
- The region allocated for the view to render intoline
- The line number to find the region of. This must
be a valid line number in the model.public java.awt.Shape modelToView(int pos, java.awt.Shape a, javax.swing.text.Position.Bias b) throws javax.swing.text.BadLocationException
modelToView
in class javax.swing.text.View
pos
- the position to convert >= 0a
- the allocated region to render into
javax.swing.text.BadLocationException
- if the given position does not
represent a valid location in the associated documentView.modelToView(int, java.awt.Shape, javax.swing.text.Position.Bias)
public java.awt.Shape modelToView(int p0, javax.swing.text.Position.Bias b0, int p1, javax.swing.text.Position.Bias b1, java.awt.Shape a) throws javax.swing.text.BadLocationException
This is implemented to subtract the width of the second character, as
this view's modelToView
actually returns the width of the
character instead of "1" or "0" like the View implementations in
javax.swing.text
. Thus, if we don't override this method,
the View
implementation will return one character's width
too much for its consumers (implementations of
javax.swing.text.Highlighter
).
modelToView
in class javax.swing.text.View
p0
- the position of the first character (>=0)b0
- The bias of the first character position, toward the previous
character or the next character represented by the offset, in
case the position is a boundary of two views; b0
will have one of these values:
Position.Bias.Forward
Position.Bias.Backward
p1
- the position of the last character (>=0)b1
- the bias for the second character position, defined
one of the legal values shown abovea
- the area of the view, which encompasses the requested region
javax.swing.text.BadLocationException
- if the given position does
not represent a valid location in the associated document
java.lang.IllegalArgumentException
- if b0
or
b1
are not one of the
legal Position.Bias
values listed aboveView.viewToModel(float, float, java.awt.Shape, javax.swing.text.Position.Bias[])
public float nextTabStop(float x, int tabOffset)
nextTabStop
in interface javax.swing.text.TabExpander
x
- the current position >= 0tabOffset
- the position within the text stream
that the tab occurred at >= 0.
public void paint(java.awt.Graphics g, java.awt.Shape a)
paint
in class javax.swing.text.View
g
- The graphics context with which to paint.a
- The allocated region in which to render.public void removeUpdate(javax.swing.event.DocumentEvent changes, java.awt.Shape a, javax.swing.text.ViewFactory f)
removeUpdate
in class javax.swing.text.View
changes
- the change information from the associated documenta
- the current allocation of the viewf
- the factory to use to rebuild if the view has childrenpublic void setSize(float width, float height)
setSize
in class javax.swing.text.View
protected void updateDamage(javax.swing.event.DocumentEvent changes, java.awt.Shape a, javax.swing.text.ViewFactory f)
public int viewToModel(float fx, float fy, java.awt.Shape a, javax.swing.text.Position.Bias[] bias)
viewToModel
in class javax.swing.text.View
fx
- the X coordinate >= 0fy
- the Y coordinate >= 0a
- the allocated region to render into
public int yForLine(java.awt.Rectangle alloc, int line) throws javax.swing.text.BadLocationException
This method is quicker than using traditional
modelToView(int)
calls, as the entire bounding box isn't
computed.
alloc
- The area the text area can render into.line
- The line number.
-1
if
this text area doesn't yet have a positive size or the line is
hidden (i.e. from folding).
javax.swing.text.BadLocationException
- If line
isn't a valid line
number for this document.public int yForLineContaining(java.awt.Rectangle alloc, int offs) throws javax.swing.text.BadLocationException
This method is quicker than using traditional
modelToView(int)
calls, as the entire bounding box isn't
computed.
alloc
- The area the text area can render into.offs
- The offset info the document.
-1
if
this text area doesn't yet have a positive size or the line is
hidden (i.e. from folding).
javax.swing.text.BadLocationException
- If offs
isn't a valid offset
into the document.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |


fablabs.js
An ES6 Fablabs.io API client
Installation
yarn add fablabsjs
Usage Examples
Using a personal token
If you want to write a personal app, or just want avoid using the OAuth flow for testing, you need to get a personal token from the Fablabs.io Developer console, along with application id and secret.
WARNING: Please make sure you understand that the token must be kept safe since all operations are done with your account and other users can impersonate you if it leaks.
See docs.fablabs.io for further information
import FablabsAPI from 'fablabsjs'
const config = {
client_id: '<your application id>',
client_secret: '<your secret>',
personal_token: '<your personal token from the dashboard>' // only for thev
}
let fablabs = new FablabsAPI(config)
// get the oauth redirect url
const redirect_url = fablabs.authorization_url()
// process the authorization code and turn it into a token
const token = await fablabs.handle_token(code)
// call any of the api methods
const userProfile = await fablabs.api().getUser()
Using the oAuth flow
The library helps you in implementing the OAuth flow easily into your application. This is the preferred way to authenticate your app, allowing each user to login on fablabs.io and authorize your app.
import FablabsAPI from 'fablabsjs'
const config = {
client_id: '<your application id>',
client_secret: '<your secret>',
redirect_url:'http://localhost:3001/auth/callback'
}
let fablabs = new FablabsAPI(config)
// get the oauth redirect url
const redirect_url = fablabs.authorization_url()
// send the user to this url, and wait for the code to be sent to redirect_url
// there, process the authorization code and turn it into a token
const token = await fablabs.handle_token(code)
// call any of the api methods on behalf of the user
const userProfile = await fablabs.api().getUser()
See the API reference for available functions.
Configuration variables
The following are all the variables you can set in the fablabsjs config:
const _default_config = {
client_id: 'c7b63f68b0ec92dfc700061c373fcae80c9255e52fa30371ce224b79d7045546' || process.env['FABLABS_IO_API_KEY'],
client_secret: 'b29b0eaa742bed6e19fca87807af40bfbbd24cb15e9fdc3d6c1b7b558574850d'|| process.env['FABLABS_IO_API_SECRET'],
redirect_url:'http://localhost:3001/auth/callback' || process.env['FABLABS_IO_REDIRECT_URL']
base_url:'http://api.fablabs.local:3000' || process.env['FABLABS_IO_API_HOST'],
authorize_url:'/oauth/authorize',
token_url:'/oauth/token',
personal_token: 'a9eb5aa7a6f526a79feb3aa840aa7057d27112edb4570f1bf795c588ad89bcac' || process.env['FABLABS_IO_PERSONAL_TOKEN']
}
Please note that you can avoid to specify any config and just set environment variables instead.
FABLABS_IO_API_KEY = 'your client id'
FABLABS_IO_API_SECRET = 'your secret'
FABLABS_IO_REDIRECT_URL = 'http://localhost:3001/auth/callback'
FABLABS_IO_API_HOST = 'http://api.fablabs.io'
FABLABS_IO_PERSONAL_TOKEN = 'your personal token'
Run tests
You can test the API and your config using the following command
yarn test


| Opcode/Instruction | Op/En | 64/32 bit Mode Support | CPUID Feature Flag | Description |
|---|---|---|---|---|
| 0F 1A /r BNDLDX bnd, mib | RM | V/V | MPX | Load the bounds stored in a bound table entry (BTE) into bnd with address translation using the base of mib and conditional on the index of mib matching the pointer value in the BTE. |
|
Op/En RM |
Operand 1 ModRM:reg (w) |
Operand 2 SIB.base (r): Address of pointer SIB.index(r) |
Operand 3 NA |
BNDLDX uses the linear address constructed from the base register and displacement of the SIB-addressing form of the memory operand (mib) to perform address translation to access a bound table entry and conditionally load the bounds in the BTE to the destination. The destination register is updated with the bounds in the BTE, if the content of the index register of mib matches the pointer value stored in the BTE.
If the pointer value comparison fails, the destination is updated with INIT bounds (lb = 0x0, ub = 0x0) (note: as articulated earlier, the upper bound is represented using 1's complement, therefore, the 0x0 value of upper bound allows for access to full memory).
This instruction does not cause memory access to the linear address of mib nor the effective address referenced by the base, and does not read or write any flags.
Segment overrides apply to the linear address computation with the base of mib, and are used during address translation to generate the address of the bound table entry. By default, the address of the BTE is assumed to be linear address. There are no segmentation checks performed on the base of mib.
The base of mib will not be checked for canonical address violation as it does not access memory.
Any encoding of this instruction that does not specify base or index register will treat those registers as zero (constant). The reg-reg form of this instruction will remain a NOP.
The scale field of the SIB byte has no effect on these instructions and is ignored.
The bound register may be partially updated on memory faults. The order in which memory operands are loaded is implementation specific.
base (cid:197) mib.SIB.base ? mib.SIB.base + Disp: 0; ptr_value (cid:197) mib.SIB.index ? mib.SIB.index : 0;
Outside 64-bit mode
A_BDE[31:0] (cid:197) (Zero_extend32(base[31:12] « 2) + (BNDCFG[31:12] «12 ); A_BT[31:0] (cid:197) LoadFrom(A_BDE ); IF A_BT[0] equal 0 Then BNDSTATUS (cid:197) A_BDE | 02H; #BR; FI; A_BTE[31:0] (cid:197) (Zero_extend32(base[11:2] « 4) + (A_BT[31:2] « 2 ); Temp_lb[31:0] (cid:197) LoadFrom(A_BTE); Temp_ub[31:0] (cid:197) LoadFrom(A_BTE + 4); Temp_ptr[31:0] (cid:197) LoadFrom(A_BTE + 8); IF Temp_ptr equal ptr_value Then BND.LB (cid:197) Temp_lb; BND.UB (cid:197) Temp_ub; ELSE BND.LB (cid:197) 0; BND.UB (cid:197) 0; FI;
In 64-bit mode
A_BDE[63:0] (cid:197) (Zero_extend64(base[47+MAWA:20] « 3) + (BNDCFG[63:20] «12 );1 A_BT[63:0] (cid:197) LoadFrom(A_BDE); IF A_BT[0] equal 0 Then BNDSTATUS (cid:197) A_BDE | 02H; #BR; FI; A_BTE[63:0] (cid:197) (Zero_extend64(base[19:3] « 5) + (A_BT[63:3] « 3 ); Temp_lb[63:0] (cid:197) LoadFrom(A_BTE); Temp_ub[63:0] (cid:197) LoadFrom(A_BTE + 8); Temp_ptr[63:0] (cid:197) LoadFrom(A_BTE + 16); IF Temp_ptr equal ptr_value Then BND.LB (cid:197) Temp_lb; BND.UB (cid:197) Temp_ub; ELSE BND.LB (cid:197) 0; BND.UB (cid:197) 0; FI;
BNDLDX: Generated by compiler as needed.
None
| #BR | If the bound directory entry is invalid. |
| #UD |
If the LOCK prefix is used. If ModRM.r/m encodes BND4-BND7 when Intel MPX is enabled. If 67H prefix is not used and CS.D=0. If 67H prefix is used and CS.D=1. |
| #GP(0) |
If a destination effective address of the Bound Table entry is outside the DS segment limit. If DS register contains a NULL segment selector. |
| #PF(fault code) | If a page fault occurs. |
| #UD |
If the LOCK prefix is used. If ModRM.r/m encodes BND4-BND7 when Intel MPX is enabled. If 16-bit addressing is used. |
| #GP(0) | If a destination effective address of the Bound Table entry is outside the DS segment limit. |
1.
| If CPL < 3, the supervisor MAWA (MAWAS) is used; this value is 0. If CPL = 3, the user MAWA (MAWAU) is used; this value is enumer- |
| ated in CPUID.(EAX=07H,ECX=0H):ECX.MAWAU[bits 21:17]. See Section 17.3.1 of Intel® 64 and IA-32 Architectures Software Devel- |
| oper’s Manual, Volume 1. |
| #UD |
If the LOCK prefix is used. If ModRM.r/m encodes BND4-BND7 when Intel MPX is enabled. If 16-bit addressing is used. |
| #GP(0) | If a destination effective address of the Bound Table entry is outside the DS segment limit. |
| #PF(fault code) | If a page fault occurs. |
Same exceptions as in protected mode.
| #BR | If the bound directory entry is invalid. |
| #UD |
If ModRM is RIP relative. If the LOCK prefix is used. If ModRM.r/m and REX encodes BND4-BND15 when Intel MPX is enabled. |
| #GP(0) | If the memory address (A_BDE or A_BTE) is in a non-canonical form. |
| #PF(fault code) | If a page fault occurs. |


Voxpupuli a collective of Puppet module, tooling, and documentation authors.
- A team that adopts and maintains Puppet related modules that were abandoned by their original authors.
- How is it done: people and robots.
- Easy access to the project: Projects are standardized.
- vpci
- Travis-CI
- Strict Code of Conduct
- People: Community Gardners
Standardize your project(s) and make it easy for people to contribute!


It's getting below 0 °C in Munich again and I'm looking for cloths for Nepal. So it is about time to get a good jacket. In this article I'll have a look at Down jackets.
The three layers are:
- Underwear: A T-Shirt or something similar that is directly on your skin. Merino wool, microfibre or mixtures are common choices.
- Isolation and Humidity transport: Down jacket or fleece for keeping you warm.
- Weather Layer: Keeping wind / rain away. A softshell or a hardshell, depending on the climate.
One of their quality measures is the fill power. It measures the fluffiness in cuib. The fluffier, the more insulating a given amount is. One online source (Globetrotter) recommended 500-700 cuin for every day purposes and 650-900 cuin for expeditions and very cold temperatures.
Another quality measure of down filling is the misture. The same Globetrotter YouTube video recommended 80/20 for everyday usage and 96/4 or 95/5 for sports.
A synthetic alternative to down is PrimaLoft. It comes in 3 shapes: Gold, Silver, Black where Gold is the best and black is the worst. The weight per square meter determines how warm it is. 100 g/m² is for normal insualtion jackets; 200 g / m² is for super warm winter jackets.
Then have a look at the sewing. If it is sewed through ("durchgesteppt") or ("Boxkammer") might make a differece.
Some jackets you can package it really well where the chest pocket doubles as a stuffsack.
Features
- Buttons to close: nice for ventilation and as an alternative in case the zipper breaks
- Pockets: Front-hip, front-breast, inside - especially the inside one might be important for water or electronic devices!
- Draw chords: At the bottom of the jacket to prevent cold air from comming in
- Elastic part at the hand to make sure it closes well
Overview
The ones with green background color were recommended for Nepal.
Self-Stowing Pocket = Self-pocketing: Some jackets come with an inner pocket in which you can pack itself. Some, like the Arc'teryx Jackets, are meant to be self-pocketed into the arms.
| Product | Price↓ | Stars↑ | Ratings↑ | Weight↓ | Fill power↑ | Filling |
|---|---|---|---|---|---|---|
| Arc'teryx Cerium LT | 336 EUR | 5 | 2 | 310g | 850 cuin | - has thumb strap (Daumenschlaufe); Camp-Jacket |
| Arc'teryx Cerium SV | 450 EUR | 5 | 2 | 410g (M) | 850 cuin | Coreloft; Gänsedaune |
| Haglöfs Essens Down Hood | 203 EUR | - | - | 335 (L) | 800 cuin | 90/10 Down; 20D; 36 g/m² |
| Montane - Quattro Fusion | 270 EUR | - | - | 472g | 800 cuin | 90/10 Down; bad review for cold |
| FJÄLLRÄVEN - Keb Expedition Down | 770 EUR | - | - | 1240g | 800 cuin | Down |
| FJÄLLRÄVEN - Keb Touring Down Jacket | 460 EUR | - | - | 600g | 800 cuin | Down |
| Mountain Hardwear - Ghost Whisperer | 300 EUR | - | - | 197g | 800 cuin | Down; Good cold review at -15°C |
| Patagonia - Down Sweater | 155 EUR | - | 0 | 359g | 800 cuin | Down |
| VAUDE - Kabru Hooded Jacket III | 250 EUR | - | - | 380g | 800 cuin | Down |
| Rab Neutrino Endurance | 340 EUR | 4.4 | 24 | 585g | 800 cuin | Gänsedaune; Good review for cold |
| Black Yak - Bakosi Jacket | 500 EUR | - | - | 483 g | 750 cuin | Primaloft Gold, Goose Down; water proof |
| Black Diamond - Forge Hoody | 180 EUR | - | - | 430g | 700 cuin | Down |
| Jack Wolfskin - Zenon Storm | 160 EUR | - | - | 435g | 700 cuin | Down |
| Salomon - Haloes Down Hoodie | 250 EUR | - | - | 480g | 700 cuin | 90/10 Down, 80 g/m² |
| Outdoor Research Transcendent | 220 EUR | 4.4 | 193 | 621g | 650 cuin | |
| Columbia Frost-Fighter | 360 EUR | 4.5 | 670 | 900g | ||
| Patagonia - Nano Puff Jacket | 210 EUR | - | - | 337g | PrimaLoft Gold; 60 g/ m² | |
| North Face Tonnerro | 200 EUR | - | 0 | ? | ||
| Yeti Virtue | 250 EUR | 5 | 2 | 998 g |
Alternatives
| Product | Price | Weight | Filling |
|---|---|---|---|
| Haglöfs Essens Mimic Hood (2) | 141 EUR | 285g (L) | 48 g/m²; 30D |
| Arc'teryx Atom AR | 252 EUR | 476g | Core loft; Midlayern |
| Bergtagen Insulation Jaket M | 390 EUR | 798g (M) | 100 g/m² G-Loft Supreme; Self-pocketing |
| Bergtagen Lite Insulation Jaket M | 330 EUR | 430g (M) | 60 g/m² G-Loft Supreme |
Notes for Arc'terxy:
- SL: Good review - super light
- LT might be "light weight" (more breathable / lass wind resistant) - see review
- FL - "Fast and Light"
- AR is for All- ARound
- SV is for Severe Conditions
- Fission SV
- ZETA AR
Notes for FJÄLLRÄVEN:
- Bergtagen is the new collection, Keb is the old one.
Comments (source):
- Atom LT is a midlayer. I heard it best described as an ice climbing jacket.
- Cerium LT is a camp jacket.
See also
- See what down is suggested for
- https://www.packliste-reise.de/reise-equipment-test/beste-daunenjacke/
- https://www.outdoor-magazin.com/test/jacken/daunenjacken-kunstfaserjacken-test-2017.1640170.3.htm
- https://www.bergfreunde.de/basislager/test-patagonia-micro-puff/


Send /performActionGCF request
Send /performActionGAE request
Project ID: {{project_id}}
Use OIDC: {{use_oidc}}
Redis IP: {{redis_ip}}


Hi ,
We got your request to reset Metris Password.
If clicking the button doesn't work for you, you can click here.
If you ignore this message, your password won't be changed.
If this not your accout, you can remove the mail from inbox.


Documents
HISPID 6 Vocabulary
The set of terms in the HISPID 6 vocabulary, based on Darwin Core. This vocabulary supersedes all previous versions of HISPID.
GoMain Wiki site
HISCOM manages its work-in-progress documents in a Mediawiki instance hosted by Royal Botanic Gardens, Victoria, Australia.
Go


Click here to download this week's dataset as a CSV
Click here to download this week's dataset as a Hyper Extract
Data Storytelling and DataViz Approach
Turns out that I really enjoyed this dataset. Despite my Cardinals not making the MLB Playoffs this year, there's just something about the Playoffs and especially the World Series. I created two vizzes this week, with the intention of addressing different questions. The first (above) is a cuvy timeline, adapted from a methodology by Ken Flerlage, and the second is a stacked shape chart.
With the timeline, I wanted to look at the series over time, especially stretches where one team has repeated success in reaching or winning the World Series. For example, my Cardinals in the 1940's or the Yankees in the 1920's. I used the logos for each team, where a greyscale logo indicates a loss and the full color version of the logo is a World Series win. I also used the tooltip to provide some additional information on the series. More artistic or infographic than dashboard, but I really love the look.
The second with the stacked shapes gives a quick look at the number of appearances by franchise, as well as their wins. A trophy icon indicates a win, whereas a full color team logo indicates a World Series appearance where the team lost. To leverage interactivity, I createad a set of BANS with some metrics about the selected team's history in the World Series. Some of these are contextual - for example, the 4th metric displays either the team's first appearance in the WS, or their first win, depending on how they performed in their first series. For example, where my Cardinals experienced success in their first WS attempt, the calc displays the text 'First Win', and for the Yankees who took 3 tries to get their first WS win, it displays 'First Appearance'. Similarly, the last metric displays either the team's last WS win or appearance depending on how they did in their last WS appearance.
I've really enjoyed the participation we've seen in the community this week as well! Several great submissions:
- Anooj Zaveri and Kranthi Sarva – A collaborative effort looking at the split in World Series fortune by league. Includes some nice highlighting functionality and a really cool lollipop chart!
- Jeff Plattner – A look at World Series win droughts broken down by conference. A nice, clean viz utilizing a ranked dot plot, and leveraging Tableau’s viz in tooltip functionality.
- Tom Coyer – A different take on the data, looking at the last 27 years of the World Series Winners and how their salary stacks up against the rest of the league. Another nice lollipop chart with parameter driven interactivity
- Jim Van Sistine – A very clean dashboard, digging into multiple facets of the data using different types of bar charts. From a timeline to a bi-directional bar chart to a standard horizontal bar, Jim really knocked it out of the park. Throw in some BANS to summarize some key points to pull the whole viz together nicely.
- Ryan Murphy – An analytic view of the data. Ryan focused on the efficiency of teams in winning the World Series. Nice consistent use of colors to indicate the length of the series throughout his stacked bars and stacked shape charts. The scatter plot with his statistical flair is also a nice touch. Ryan was able to create this effective viz despite his limited knowledge and use of Tableau. Great first effort.
We'd love to see what you can do with this week's dataset, create your viz and post your work to Tableau Public and Twitter with the hashtag #ThrowbackDataThursday, tagging @TThrowbackThurs. We'd really love to see what you can come up with!
Data Source
This week's dataset comes from Wikipedia. Please be sure to cite the source on your viz.


Implementation of GPIO functions for X4M0x boards with Atmel SAM S70 MCU. More...
#include "xtio_led.h"
#include "board.h"
#include "pio.h"
#include "xtio_gpio.h"
#include "xt_config.h"
Macros | |
| #define | RED_AVAILABLE() (XPIN_LED_RED.mask != 0) |
| #define | GREEN_AVAILABLE() (XPIN_LED_GREEN.mask != 0) |
| #define | BLUE_AVAILABLE() (XPIN_LED_BLUE.mask != 0) |
| #define | SINGLE_LED() ((RED_AVAILABLE() + GREEN_AVAILABLE() + BLUE_AVAILABLE()) == 1) |
Functions | |
| int | xtio_decode_led_id (xtio_led_id_t led_id, Pin **pin) |
| int | xtio_led_init (xtio_led_id_t led_id, int mode, float led_state) |
| Initiate LED. More... | |
| int | xtio_led_set_state (xtio_pin_id_t led_id, float led_state) |
| Set LED state. More... | |
| int | xtio_led_toggle_state (xtio_pin_id_t led_id) |
| Toggle LED state. More... | |
Variables | |
| Pin | XPIN_LED_RED = {PIO_PD24, PIOD, ID_PIOD, PIO_OUTPUT_1, PIO_DEFAULT} |
| Pin | XPIN_LED_GREEN = {PIO_PD25, PIOD, ID_PIOD, PIO_OUTPUT_1, PIO_DEFAULT} |
| Pin | XPIN_LED_BLUE = {PIO_PD26, PIOD, ID_PIOD, PIO_OUTPUT_1, PIO_DEFAULT} |
| float | red_state |
| float | green_state |
| float | blue_state |
Implementation of GPIO functions for X4M0x boards with Atmel SAM S70 MCU.
See X4M0x_SAMS70/xtio_gpio.h and xt_XEP_HAL.h for more documentation.
| #define BLUE_AVAILABLE | ( | ) | (XPIN_LED_BLUE.mask != 0) |
| #define GREEN_AVAILABLE | ( | ) | (XPIN_LED_GREEN.mask != 0) |
| #define RED_AVAILABLE | ( | ) | (XPIN_LED_RED.mask != 0) |
| #define SINGLE_LED | ( | ) | ((RED_AVAILABLE() + GREEN_AVAILABLE() + BLUE_AVAILABLE()) == 1) |
| int xtio_decode_led_id | ( | xtio_led_id_t | led_id, |
| Pin ** | pin | ||
| ) |
| int xtio_led_init | ( | xtio_led_id_t | led_id, |
| int | mode, | ||
| float | led_state | ||
| ) |
Initiate LED.
Set MCU pin as output and set initial LED state.
| led_id | LED ID as defined in xtio_led_id_t |
| mode | LED mode as defined in xtio_led_mode_t |
| led_state | LED state as defined in xtio_led_state_t |
| int xtio_led_set_state | ( | xtio_pin_id_t | led_id, |
| float | led_state | ||
| ) |
Set LED state.
If LED is set to ON/OFF mode, a value of 0 is OFF and 1 is ON. If PWM mode is implemented, the brightness is controlled by a value between 0.0 and 1.0 - 0.0 is OFF.
| led_id | LED ID as defined in xtio_led_id_t |
| led_state | LED state as defined in xtio_led_state_t |
| int xtio_led_toggle_state | ( | xtio_pin_id_t | led_id | ) |
Toggle LED state.
If LED is set to ON/OFF mode, a value of 0 is OFF and 1 is ON. If LED is in PWM mode, this function will set LED state to either ON or OFF depending on current state.
| led_id | LED ID as defined in xtio_led_id_t |
| float blue_state |
| float green_state |
| float red_state |
| Pin XPIN_LED_BLUE = {PIO_PD26, PIOD, ID_PIOD, PIO_OUTPUT_1, PIO_DEFAULT} |
| Pin XPIN_LED_GREEN = {PIO_PD25, PIOD, ID_PIOD, PIO_OUTPUT_1, PIO_DEFAULT} |
| Pin XPIN_LED_RED = {PIO_PD24, PIOD, ID_PIOD, PIO_OUTPUT_1, PIO_DEFAULT} |


Task 1 40% Complete
Task 2 20% Complete
Task 3 60% Complete
Task 4 80% Complete
Last Run Date: 11/25/2015 12:00 AM
Next Schedule Date: 11/26/2015 12:00 AM
Summary:Weekly on weekdays, until Nov. 29, 2016


What is Data Science?
- Relatively new field intersecting CS, Statistics and Business
- Determining consumer trends, business opportunities, and user behavior
- Drawing valuable insight from data - data is "unbiased"
- Some areas that overlap:
- Computational Statistics
- Big Data and Data Mining
- Machine Learning
How is Data Science used?
A/B testing - web applications with different features
Consumer recommendations - Amazon, Netflix, etc.
Revenue opportunities - ad targeting, investor/stock forecasting
Accessibility
Technologies to "do" Data Science
- Programming Languages - Python, R (statistical computing)
- Big Data Frameworks - Hadoop, Spark, Pig
- Concepts - Map-Reduce, Aggregation, Regression, Distributions
- Visualization Frameworks - Matplotlib, D3, Processing
Brainstorm
- What would you like to build?
- What features? Sketches.
- What technologies do you think you'll need?
- What is your plan for developing?
Potential Projects
- Your Own Personal Website
- Data Analysis on a Dataset
- Web or Mobile App
- WCS Display for our TV
- Chrome Extension
- Slackbot


Modi government rolls back fee hike for JNU students after protests, tells them to ‘get back to classes’
by JKR StaffThe Centre’s Narendra Modi government on Wednesday announced a major rollback on the fee hike for JNU students asking the protesting students to call off their agitation and return to classes.
A tweet by Education Secretary R Subrahmanyam read, “Executive Committee announces major roll-back in the hostel fee and other stipulations. Also proposes a scheme for economic assistance to the EWS students. Time to get back to classes,”
Thousands of JNU students have been staging protests against the administration’s decision to hike fees for hostel facilities.
The one-time mess security fee, which is refundable, was hike from Rs 5,500 to Rs 12,000. The rent for single-bed room was hiked from Rs 20 per month to a whopping Rs 600 per month. The rent for a double-seater room was hiked from Rs 10 per month to Rs 300 per month.
According to news agency PTI, the draft hostel manual also has provisions for dress code and curfew timings, the students’ union alleged, even as the administration denied these two claims.
More details awaited


WebRTC Chess
This is a multiplayer version of the classical game of chess. You can start playing by sharing the below link with your opponent(or opening it in a new browser window).
Loading Link ...Hosted on Github
Status: Loading...
This is a multiplayer version of the classical game of chess. You can start playing by sharing the below link with your opponent(or opening it in a new browser window).
Loading Link ...Hosted on Github


public interface OutboundRequestHandle
ConnectionEndpoint
. The same handle is associated with all
OutboundRequest
instances produced by the same OutboundRequestIterator
(that is, all attempts to send the same
request).
An OutboundRequestHandle
is an opaque cookie
provided to a ConnectionManager
by a connection-based
Endpoint
implementation (via ConnectionManager.newRequest
) in
order to identify the request in later invocations of certain
ConnectionEndpoint
and Connection
methods. The
handle encapsulates information about the constraints for the
request and any other request-specific information needed by the
transport implementation.
Copyright 2007-2013, multiple authors.
Licensed under the Apache License, Version 2.0, see the NOTICE file for attributions.


Description:
Simulator Executive using Sequential Modular solving.
Superclasses:
Simulator Executive That part of a simulator whose job it is to create or load a previously stored flowsheet, solve it and display the results.
Associations:
has
Role A:
Class: Sequential Modular Executive
Navigatable: no
Aggregate: no
Static: no
Friend: no
Cardinality: 1
Role B:
Class: Pre-Processor Subsystem
Navigatable: no
Aggregate: no
Static: no
Friend: no
Cardinality: 1


--- layout: article title: What to do when your game is too easy and too hard author: matt tags: [onslaught] ---
We've been preparing to release version 1.0 of our game Onslaught! and part of that process has included looking wherever we can for feedback on how to improve the game.
Luckily for us, Onslaught! has been talked about a little bit on the 'net (especially on /r/WebGames; thanks Reddit!) so we've been able to dig through some players' comments. And we've noticed two recurring themes:
If the feedback was consistently that Onslaught! was too easy, here are some easy tweaks we could have made to help make the game more difficult:
Likewise, we could have reversed any of those rules to make the game easier. But what is a game designer supposed to do with conflicting requirements?
The current version of Onslaught! has a very simple algorithm for increasing difficulty. There are seven waves, the final wave consisting primarily of the dragon boss. After defeating this wave, the player is thrown back to the beginning of the loop with the number of enemies increased steadily by 50% of the first wave (so it would go: 10 bats, 15 bats, 20 bats, 25 bats, etc.).
According to Google Analytics, Onslaught!'s 10,000+ players have played the game for an average of 32 seconds each. We mentioned previously how we had failed to make a 30 second game, and for the final release of Onslaught! we decided it would be good to expand on that idea.
What we were wanting instead of a steady climb in difficulty like this was an easy beginning with a sharp increase in difficulty. So after the first couple of wave cycles, the game should rapidly increase in difficulty, providing a challenge for hardcore gamers.
The below graph shows the previous difficulty curve (v0.2, in blue), and the difficulty curve we are shooting for in v1.0 (in red):
This is going to be a difficult (but fun!) problem to solve. Here's what we have in mind:
We've got these improvements and many others in mind as well! Our hope is that these gameplay tweaks and content additions will make the game more enjoyable for both casual and hardcore players alike. What do you think? Is Onslaught! currently too easy or too hard?


{% load i18n %} {% load staticfiles %} {% trans page.title as TITLE %} {% trans "Yes" as YES %} {% trans "No" as NO %} {% trans "Not Sure" as NOTSURE %} {% trans "Step" as STEP %}


In order to provide robust backup sources, primary (stratum-1) servers are usually operated in a diversity configuration, in which the server operates with a number of remote peers in addition to one or more radio or modem clocks operating as local peers. In these configurations the suite of algorithms used in NTP to refine the data from each peer separately and to select and weight the data from a number of peers are used with the entire ensemble of remote peers and local peers. As the result of these algorithms, a set of survivors are identified which can presumably provide the most reliable and accurate time. Ordinarily, the individual clock offsets of the survivors are combined on a weighted average basis to produce an offset used to control the system clock.
However, because of small but significant systematic time offsets between the survivors, it is in general not possible to achieve the lowest jitter and highest stability in these configurations. This happens because the selection algorithm tends to clockhop between survivors of substantially the same quality, but showing small systematic offsets between them. In addition, there are a number of configurations involving pulse-per-second (PPS) signals, modem backup services and other special cases, so that a set of mitigation rules becomes necessary to select a single peer from among the survivors. These rules are based on a set of special characteristics of the various peers and reference clock drivers specified in the configuration file.
The prefer scheme works on the set of peers that have survived the sanity checks and intersection algorithms of the clock selection procedures. Ordinarily, the members of this set can be considered truechimers and any one of them could in principle provide correct time; however, due to various error contributions, not all can provide the most accurate and stable time. The job of the clustering algorithm, which is invoked at this point, is to select the best subset of the survivors providing the least variance in the combined ensemble average, compared to the variance in each member of the subset separately. The detailed operation of the clustering algorithm, which is given in the specification, is not important here, other than to point out it operates in rounds, where a survivor, presumably the worst of the lot, is discarded in each round until one of several termination conditions is met.
In the prefer scheme the clustering algorithm is modified so that the prefer peer is never discarded; on the contrary, its potential removal becomes a termination condition. If the original algorithm were about to toss out the prefer peer, the algorithm terminates right there. The prefer peer can still be discarded by the sanity checks and intersection algorithms, of course, but it will always survive the clustering algorithm. If it does not survive or for some reason it fails to provide updates, it will eventually become unreachable and the clock selection will remitigate to select the next best source.
Along with this behavior, the clock selection procedures are modified so that the combining algorithm is not used when a prefer peer is present. Instead, the offset of the prefer peer is used exclusively as the synchronization source. In the usual case involving a radio clock and a flock of remote stratum-1 peers, and with the radio clock designated a prefer peer, the result is that the high quality radio time disciplines the server clock as long as the radio itself remains operational and with valid time, as determined from the remote peers, sanity checks and intersection algorithm.
The modem clock drivers are a special case. Ordinarily, the update interval between modem calls to synchronize the system clock is many times longer than the interval between polls of either the remote or local peers. In order to provide the best stability, the operation of the clock discipline algorithm changes gradually from a phase-lock mode at the shorter update intervals to a frequency-lock mode at the longer update intervals. If both remote or local peers together with a modem peer are operated in the same configuration, what can happen is that first the clock selection algorithm can select one or more remote/local peers and the clock discipline algorithm will optimize for the shorter update intervals. Then, the selection algorithm can select the modem peer, which requires a much different optimization. The intent in the design is to allow the modem peer to control the system clock either when no other source is available or, if the modem peer happens to be marked as prefer, then it always controls the clock, as long as it passes the sanity checks and intersection algorithm. There still is room for suboptimal operation in this scheme, since a noise spike can still cause a clockhop either way. Nevertheless, the optimization function is slow to adapt, so that a clockhop or two does not cause much harm.
The local clock driver is another special case. Normally, this driver is eligible for selection only if no other source is available. When selected, vernier adjustments introduced via the configuration file or remotely using the ntpdc program can be used to trim the local clock frequency and time. However, if the local clock driver is designated the prefer peer, this driver is always selected and all other sources are ignored. This behavior is intended for use when the kernel time is controlled by some means external to NTP, such as the NIST lockclock algorithm or another time synchronization protocol such as DTSS. In this case the only way to disable the local clock driver is to mark it unsynchronized using the leap indicator bits. In the case of modified kernels with the ntp_adjtime() system call, this can be done automatically if the external synchronization protocol uses it to discipline the kernel time.
The clustering algorithm repeatedly discards outlyers in order to reduce the residual jitter in the survivor population. As required by the NTP specification, these operations continue until either a specified minimum number of survivors remain or the minimum select dispersion of the population is greater than the maximum peer dispersion of any member. The mitigation rules require an additional terminating condition which stops these operations at the point where the prefer peer is about to be discarded.
The mitigation rules establish the choice of system peer, which determine the stratum, reference identifier and several other system variables which are visible to clients of the local server. In addition, they establish which source or combination of sources control the local clock.
First, it should be pointed out that the PPS signal is inherently ambiguous, in that it provides a precise seconds epoch, but does not provide a way to number the seconds. In principle and most commonly, another source of synchronization, either the timecode from an associated radio clock, or even one or more remote NTP servers, is available to perform that function. In all cases, a specific, configured peer or server must be designated as associated with the PPS signal. This is done using the prefer keyword as described previously. The PPS signal can be associated in this way with any peer, but is most commonly used with the radio clock generating the PPS signal.
The PPS signal can be used in two ways to discipline the local clock, one using a special PPS driver described in the PPS Clock Discipline page, the other using PPS signal support in the kernel, as described in the A Kernel Model for Precision Timekeeping page. In either case, the signal must be present and within nominal jitter and wander error tolerances. In addition, the associated prefer peer must have survived the sanity checks and intersection algorithms and the dispersion settled below 1 s. This insures that the radio clock hardware is operating correctly and that, presumably, the PPS signal is operating correctly as well. Second, the absolute offset of the local clock from that peer must be less than 128 ms, or well within the 0.5-s unambiguous range of the PPS signal itself. In the case of the PPS driver, the time offsets generated from the PPS signal are propagated via the clock filter to the clock selection procedures just like any other peer. Should these pass the sanity checks and intersection algorithms, they will show up along with the offsets of the prefer peer itself. Note that, unlike the prefer peer, the PPS peer samples are not protected from discard by the clustering algorithm. These complicated procedures insure that the PPS offsets developed in this way are the most accurate, reliable available for synchronization.
The PPS peer remains active as long as it survives the intersection algorithm and the prefer peer is reachable; however, like any other clock driver, it runs a reachability algorithm on the PPS signal itself. If for some reason the signal fails or displays gross errors, the PPS peer will either become unreachable or stray out of the survivor population. In this case the clock selection remitigates as described above.
When kernel support for the PPS signal is available, the PPS signal is interfaced to the kernel serial driver code via a modem control lead. As the PPS signal is derived from external equipment, cables, etc., which sometimes fail, a good deal of error checking is done in the kernel to detect signal failure and excessive noise. The way in which the mitigation rules affect the kernel discipline is as follows.
In order to operate, the kernel support must be enabled by the enable pll command in the configuration file and the signal must be present and within nominal jitter and wander error tolerances. In the NTP daemon, the PPS discipline is active only when the prefer peer is among the survivors of the clustering algorithm, and its absolute offset is within 128 ms, as in the PPS driver. Under these conditions the kernel disregards updates produced by the NTP daemon and uses its internal PPS source instead. The kernel maintains a watchdog timer for the PPS signal; if the signal has not been heard or is out of tolerance for more than some interval, currently two minutes, the kernel discipline is declared inoperable and operation continues as if it were not present.