Build
Deploy
Test
Release
Deployment pipeline is the automated implementation of these steps.
Manual deploys
Long release cycles
Manual configuration of environments
frequent
automated
repeatable
lowrisk
cheap
fast
predictable
Repeatable and reliable process
Automate (almost) everything
Put everything in version control
If it hurts - do it more frequently
Done means released
Everybody is responsible
software strategy that enables organizations to deliver new features to users as fast and efficiently as possible.
"Continuous Delivery is a software development discipline where you build software in such a way that the software can be released to Production at any time" - Martin Fowler.
"Continuous Delivery aims to reduce the cost, time, and risk of delivering incremental changes to users" - Jez Humble.
Every successful build on your Master branch should be releasable.
Your feature branches get merged into master, when they have been tested.
"A deployment pipeline is a way to break up your build into stages."
"Deployment pipelines are a central part of Continuous Delivery"
Martin Fowler
- Glue codeit makes every part of the process of building, deploying, testing, and releasing software visible to everybody involved, aiding collaboration.
it improves feedback so that problems are identified, and so resolved, as early in the process as possible.
it enables teams to deploy and release any version of their software to any environment at will through a fully automated process.
Detect any changes that could lead to problems in Production:
Security, Performance, Usability, etc
Enable collaboration between the various groups involved in delivering software
Provide visibility about the flow of changes
Enabled by "Pipeline" plugin (formerly known as "Workflow")
Based on Pipeline DSL (Domain-specific language)
Pipeline DSL is based on Groovy programming language
Resilent - can survive restarts
Pausable - can pause and wait for human input/approval
Efficient - can restart from saved checkpoints (in paid Jenkins version)
Visualized - provides status at-a-glance
Step - Single task that is a part of the sequence
Node - Step that schedules steps contained within it into Jenkins build queue and allocates the workspace.
Stage - Contains steps inside and have some additional configuration
node {
stage('hello') {
echo 'Hello Drupalcon!'
}
stage('build') {
echo "Give me a current
directory"
sh('pwd')
}
}
[Pipeline] {
[Pipeline] stage
[Pipeline] { (hello)
[Pipeline] echo
Hello Drupalcon!
[Pipeline] }
[Pipeline] // stage
[Pipeline] stage
[Pipeline] { (build)
[Pipeline] echo
Give me a current directory
[Pipeline] sh
[simple] Running shell script
+ pwd
/var/jenkins_home/workspace/simple/simple
[Pipeline] }
[Pipeline] // stage
[Pipeline] }
[Pipeline] // node
[Pipeline] End of Pipeline
You shouldn't commit "vendor" (Drupal core & contrib packages) to source control with proper Composer workflow
You shouldn't run "composer update" on PROD
as you want same version of code as in Development
You should NOT run "composer install" on PROD
as it can fail because of timeouts/other issues
you need to test built code before it hits Production
It can take a long time to be finished
How to deliver result of the build to the Production without commiting vendor code into Source control or executing "compose install" directly on Production servers?
Option 1: With tarball, capistrano, sync, etc. This solution will not work with major Drupal hosting/service providers, like Acquia, because code should be delivered through Git repo.
Option 2: CI/CD workflow to deliver code with additional Git repository (target repo).
Commit to source repo -> CI (Jenkins) -> Build (sh "composer install") -> Commit to target repo -> Deploy to target environment
node {
stage 'config' {
// ...
// SKIPPED SOME CONFIGURATION CODE
}
stage 'build' {
// ...
// SKIPPED SOME CONFIGURATION CODE
if (configRepo) {
sh(
"""#!/bin/bash -l
docman init ${params.path} ${configRepo} -s
"""
)
params.dir
}
sh(
"""#!/bin/bash -l
if [ "${force}" == "1" ]; then
rm -fR docroot
fi
docman init ${params.docrootDir} ${config_repo} -s
cd docroot
docman deploy git_target ${deployProjectName} branch ${version} ${flag}
"""
)
}
stage ('stage prepare') {
dir('druflow') {
git 'https://github.com/aroq/druflow.git'
sh "./gradlew app -Ddebug=${debug} -Dsite=default -Denv=${params.fromEnvironment} -Dargument='${params.db} ${params.toEnvironment}' -DexecuteCommand=dbCopyAC -Dworkspace=${params.workspace} -DdocrootDir=${docrootDir}"
}
}
stage ('stage deploy') {
// SKIPPED SOME CONFIGURATION CODE
// ...
dir('druflow') {
git 'https://github.com/aroq/druflow.git'
sh "./gradlew app -Ddebug=${debug} -DprojectName=${deployProjectName} -Denv=stage -DexecuteCommand=deployFlow -Dworkspace=${params.workspace} -DdocrootDir=${docrootDir}${options}"
}
}
stage ('stage smoke testing') {
// SKIPPED SOME CONFIGURATION CODE
// ...
dir('docroot/master/docroot') {
if (fileExists('../bin/behat')) {
if (fileExists("../code/common/behat.stage.yml")) {
sh """#!/bin/bash -l
mkdir -p ../../../reports
../bin/behat --config=../code/common/behat.stage.yml --format=pretty --out=std --format=junit --out=../../../reports @smoke ${features}
"""
}
}
}
}
stage ('stage acceptance testing') {
// SKIPPED SOME CONFIGURATION CODE
// ...
dir('docroot/master/docroot') {
if (fileExists('../bin/behat')) {
if (fileExists("../code/common/behat.stage.yml")) {
sh """#!/bin/bash -l
mkdir -p ../../../reports
../bin/behat --config=../code/common/behat.stage.yml --format=pretty --out=std --format=junit --out=../../../reports @acceptance ${features}
"""
}
}
}
}
stage ('prod deploy') {
// SKIPPED SOME CONFIGURATION CODE
// ...
dir('druflow') {
git 'https://github.com/aroq/druflow.git'
sh "./gradlew app -Ddebug=${debug} -DprojectName=${deployProjectName} -Denv=prod -DexecuteCommand=deployFlow -Dworkspace=${params.workspace} -DdocrootDir=${docrootDir}${options}"
}
}
stage ('prod smoke testing') {
// SKIPPED SOME CONFIGURATION CODE
// ...
dir('docroot/master/docroot') {
if (fileExists('../bin/behat')) {
if (fileExists("../code/common/behat.prod.yml")) {
sh """#!/bin/bash -l
mkdir -p ../../../reports
../bin/behat --config=../code/common/behat.prod.yml --format=pretty --out=std --format=junit --out=../../../reports @smoke ${features}
"""
}
}
}
}
stage ('prod acceptance testing') {
// SKIPPED SOME CONFIGURATION CODE
// ...
dir('docroot/master/docroot') {
if (fileExists('../bin/behat')) {
if (fileExists("../code/common/behat.prod.yml")) {
sh """#!/bin/bash -l
mkdir -p ../../../reports
../bin/behat --config=../code/common/behat.stage.yml --format=pretty --out=std --format=junit --out=../../../reports @acceptance ${features}
"""
}
}
}
}
stage ('finalize') {
step([$class: 'JUnitResultArchiver', testResults: params.reportsPath])
}
}
executePipeline {
pipeline =
[
'build': [
[
action: 'Docman.config',
],
[
action: 'Docman.jsonConfig',
],
[
action: 'Docman.deploy',
],
],
'stage prepare': [
[
action: 'Druflow.copySite',
params: [
fromEnvironment: 'test',
toEnvironment: 'dev',
db: 'aroq',
]
],
],
'stage deploy': [
[
action: 'Druflow.deployFlow',
params: [
deployFlowEnvironment: 'dev',
]
],
],
'stage smoke testing': [
[
action: 'Behat.perform',
params: [
testEnvironment: 'dev',
tags: '@smoke',
]
],
],
'stage acceptance testing': [
[
action: 'Behat.perform',
params: [
testEnvironment: 'dev',
tags: '@acceptance',
]
],
],
'prod deploy': [
[
action: 'Druflow.deployFlow',
params: [
deployFlowEnvironment: 'test',
]
],
],
'prod smoke testing': [
[
action: 'Behat.perform',
params: [
testEnvironment: 'test',
tags: '@smoke',
]
],
],
'prod acceptance testing': [
[
action: 'Behat.perform',
params: [
testEnvironment: 'test',
tags: '@acceptance',
]
],
],
'finalize': [
[
action: 'Publish.junit',
],
]
]
}


Hong Kong police end blockade of university campus
Hong Kong police have ended their blockade of a university campus after surrounding it for 12 days to try to arrest anti-government protesters holed up inside.
Police removed a stash of nearly 4,000 petrol bombs left behind by protesters, who fought pitched battles about two weeks ago with riot officers on surrounding streets.
The stand-off at Hong Kong Polytechnic University was one of the most dramatic episodes in nearly six months of unrest that began in June with a huge march against an extradition Bill seen as an erosion of freedoms promised when the former British colony returned to Chinese control in 1997.
Protesters have since expanded their demands to include fully democratic elections and an investigation into police use of tear gas, rubber bullets and other force to suppress the demonstrations.
Police have arrested 5,890 people since June, ranging in age from 11 to 83.
- Trump signs bills in support of Hong Kong protesters
- Pro-democracy candidates make huge gains in Hong Kong elections
About 100 officers first entered the Polytechnic campus on Thursday to collect evidence and remove dangerous items.
A police statement said that over two days, they seized 3,989 petrol bombs, 1,339 explosive items, 601 bottles of corrosive liquids and 573 weapons but no protesters were found.
One masked man told media the night before police came in that about 20 people were still hiding to avoid arrest.
They were the holdouts from perhaps 1,100 who had retreated inside after the battles with police.
A few escaped the cordon but police say they arrested 810 people and recorded the details of 300 minors who could face charges later.
Another 567 people were arrested in the vicinity of the university.
A university official estimated it would take five to six months to repair the damage to the campus.
During an official visit to Thailand, city leader Carrie Lam said that Hong Kong is undergoing a difficult period but that the fundamentals of the Asian financial centre, including its strengths under the “one country, two systems” framework, remain strong.
She said: “I and my government are listening to our people with a view to resolving some deep-seated problems in Hong Kong through dialogue.
"I have every confidence that Hong Kong can bounce back, as we always do.”
Hundreds of people chanted pro-democracy slogans at lunchtime rallies around Hong Kong on Friday disrupting traffic in at least two places before being moved on by police.
Police said two high school students were detained on Wednesday for possessing TATP, or tri-acetone triperoxide powder, a powerful explosive that has been used in bomb attacks worldwide.
The latest protests followed a large rally on Thursday night to thank America, on its Thanksgiving Day holiday, after Mr Trump signed into law two Bills supporting the protesters.
Chanting “fight for freedom, stand with Hong Kong,” thousands of people waved American flags and urged other countries to join the US in supporting human rights in the semi-autonomous Chinese territory.
One of the laws prescribes sanctions on officials found guilty of human rights abuses and requires an annual review of a special trade status for Hong Kong.
The other bans the export of certain non-lethal munitions to Hong Kong police.


Content: {{story.story}}
Priority: {{story.priorityText}}
Business value: {{story.bussinessValue}}
Estimated time: {{story.estimatedTime}} pt
Comments: Add Comment
Acceptance tests
Tasks:
{{task.description}} Edit task | Delete task
Completed Accept task Not assigned Assigned Accepted {{task.assignee}} {{task.estimatedTime}} h
You cannot delete this task: . You can only delete tasks that are not yet accepted or assigned!


?ill
O
1
cm
_
?
?
m
_
?
?
jƒl
2
3
4
£
i
6
7
£
\
9
1
o
As
copyright
reserved
Botanical
Garden
3864
FLORA
JAMAICENSIS.
POBLIC
GARDENS,
JAMAICA,
and
NEW
YORK
BOTANICAL
GARDEN.
NamÇ,
Locality,
No
ÀÀ4
Date.
_
0iJr.
_19,
Cullkctor
,
Wm.
HARRIS.
Jj+%0
juJT
xttzzzÈ.ait^.
j£j,
^/a-acs
01561307
Legend -
Level of confidence that token is an accurately-transcribed word
extremely low
very low
low
undetermined
medium
high
very high


One of the most important concepts in object-oriented programming is that of inheritance. Inheritance allows us to define a class in terms of another class, which makes it easier to create and maintain an application. This also provides an opportunity to reuse the code functionality and fast implementation time.
When creating a class, instead of writing completely new data members and member functions, the programmer can designate that the new class should inherit the members of an existing class. This existing class is called the base class, and the new class is referred to as the derived class.
The idea of inheritance implements the is a relationship. For example, mammal IS-A animal, dog IS-A mammal hence dog IS-A animal as well and so on.
A class can be derived from more than one classes, which means it can inherit data and functions from multiple base classes. To define a derived class, we use a class derivation list to specify the base class(es). A class derivation list names one or more base classes and has the form:
class derived-class: access-specifier base-class
Where access-specifier is one of public, protected, or private, and base-class is the name of a previously defined class. If the access-specifier is not used, then it is private by default.
Consider a base class Shape and its derived class Rectangle as follows:
#include <iostream> using namespace std; // Base class class Shape { public: void setWidth(int w) { width = w; } void setHeight(int h) { height = h; } protected: int width; int height; }; // Derived class class Rectangle: public Shape { public: int getArea() { return (width * height); } }; int main(void) { Rectangle Rect; Rect.setWidth(5); Rect.setHeight(7); // Print the area of the object. cout << "Total area: " << Rect.getArea() << endl; return 0; }
When the above code is compiled and executed, it produces the following result:
Total area: 35
A derived class can access all the non-private members of its base class. Thus base-class members that should not be accessible to the member functions of derived classes should be declared private in the base class.
We can summarize the different access types according to who can access them in the following way:
| Access | public | protected | private |
|---|---|---|---|
| Same class | yes | yes | yes |
| Derived classes | yes | yes | no |
| Outside classes | yes | no | no |
A derived class inherits all base class methods with the following exceptions:
Constructors, destructors and copy constructors of the base class.
Overloaded operators of the base class.
The friend functions of the base class.
When deriving a class from a base class, the base class may be inherited through public, protected or private inheritance. The type of inheritance is specified by the access-specifier as explained above.
We hardly use protected or private inheritance, but public inheritance is commonly used. While using different type of inheritance, following rules are applied:
Public Inheritance: When deriving a class from a public base class, public members of the base class become public members of the derived class and protected members of the base class become protected members of the derived class. A base class's private members are never accessible directly from a derived class, but can be accessed through calls to the public and protected members of the base class.
Protected Inheritance: When deriving from a protected base class, public and protected members of the base class become protected members of the derived class.
Private Inheritance: When deriving from a private base class, public and protected members of the base class become private members of the derived class.
A C++ class can inherit members from more than one class and here is the extended syntax:
class derived-class: access baseA, access baseB....
Where access is one of public, protected, or private and would be given for every base class and they will be separated by comma as shown above. Let us try the following example:
#include <iostream> using namespace std; // Base class Shape class Shape { public: void setWidth(int w) { width = w; } void setHeight(int h) { height = h; } protected: int width; int height; }; // Base class PaintCost class PaintCost { public: int getCost(int area) { return area * 70; } }; // Derived class class Rectangle: public Shape, public PaintCost { public: int getArea() { return (width * height); } }; int main(void) { Rectangle Rect; int area; Rect.setWidth(5); Rect.setHeight(7); area = Rect.getArea(); // Print the area of the object. cout << "Total area: " << Rect.getArea() << endl; // Print the total cost of painting cout << "Total paint cost: $" << Rect.getCost(area) << endl; return 0; }
When the above code is compiled and executed, it produces the following result:
Total area: 35 Total paint cost: $2450


John McDonnell says workers will take back control under Labour – video
by Reuters
The shadow chancellor has promised that a Labour government would ‘rewrite the rules of our economy’ as he announced proposed reforms to business regulation that he said would help workers ‘take back control’.
In a speech in Westminster, he said: ‘The relentless pursuit of shareholder value has been to the detriment of workers, consumers, communities and our environment’


Profile
Contact Info
Wall
Photos
Synced Photos
Videos
Friends
Messages
Pokes
Events
Settings
Security
Ads
Mobile Devices
Places
Survey Responses
First User 一
First User 一, Second User 二
Second User 二
Friday, October 4, 2013 at 10:05pm PDT
The last message! Hello
Second User 二
Friday, October 4, 2013 at 10:05pm PDT
Yes, it is
Second User 二
Friday, October 4, 2013 at 10:05pm PDT
This is a test
Second User 二
Friday, October 4, 2013 at 10:05pm PDT
X? Y Z!
Second User 二
Friday, October 4, 2013 at 10:04pm PDT
X Y Z
First User 一, Third User 三
First User 一
Friday, October 4, 2013 at 10:07pm PDT
7
First User 一
Friday, October 4, 2013 at 10:07pm PDT
6
Third User 三
Friday, October 4, 2013 at 10:06pm PDT
5
First User 一
Friday, October 4, 2013 at 10:05pm PDT
4
Third User 三
Friday, October 4, 2013 at 10:05pm PDT
3
Third User 三
Friday, October 4, 2013 at 10:05pm PDT
2
Third User 三
Friday, October 4, 2013 at 10:05pm PDT
1
First User 一, Second User 二, Third User 三
Second User 二
Friday, December 14, 2015 at 1:03pm PDT
8
Third User 三
Friday, October 4, 2013 at 10:07pm PDT
7
Third User 三
Friday, October 4, 2013 at 10:06pm PDT
6
Second User 二
Friday, October 4, 2013 at 10:05pm PDT
5
First User 一
Friday, October 4, 2013 at 10:05pm PDT
4
Third User 三
Friday, October 4, 2013 at 10:05pm PDT
3
Third User 三
Friday, October 4, 2013 at 10:05pm PDT
2
Third User 三
Friday, October 4, 2013 at 10:05pm PDT
1


JsonFixture allows checks on JSON, similar to what is supported by JsonHttpTest, obtained from other sources than HTTP calls.
| script | json fixture | |||
| load | {"a":"b","b":1} | |||
| show | object | { "a": "b", "b": 1 } | ||
| check | json path | b | 1 |
| script | json fixture | |||
| load | [{"a": [1,2]},{"a": "b","b": 1}] |
|||
| show | object | [ {"a": [ 1, 2 ]}, { "a": "b", "b": 1 } ] | ||
| check | json path | [0].a[1] | 2 | |
| check | json path | [1].a | b | |
| show | list json path matches | $..a | [[1, 2], b] |


The above reference is the example from the pandoc-citeproc man page.
pandoc-citeproc
Doe (2006) says: “Test your code!”
Cited Works
Doe, John F. 2006. “Article.” Journal of Generic Studies 6: 33–34.


In this step, you will add a clickable phone image swapper to the phone details page.
app/phone-detail/phone-detail.component.js
:
...
controller: ['$http', '$routeParams',
function PhoneDetailController($http, $routeParams) {
var self = this;
self.setImage = function setImage(imageUrl) {
self.mainImageUrl = imageUrl;
};
$http.get('phones/' + $routeParams.phoneId + '.json').then(function(response) {
self.phone = response.data;
self.setImage(self.phone.images[0]);
});
}
]
...
In the phoneDetail
component's controller, we created the mainImageUrl
model property and set
its default value to the first phone image URL.
We also created a setImage()
method (to be used as event handler), that will change the value of
mainImageUrl
.
app/phone-detail/phone-detail.template.html
:

...

...
We bound the ngSrc
directive of the large image to the $ctrl.mainImageUrl
property.
We also registered an ngClick handler with thumbnail images. When a
user clicks on one of the thumbnail images, the handler will use the $ctrl.setImage()
method
callback to change the value of the $ctrl.mainImageUrl
property to the URL of the clicked
thumbnail image.
To verify this new feature, we added two E2E tests. One verifies that mainImageUrl
is set to the
first phone image URL by default. The second test clicks on several thumbnail images and verifies
that the main image URL changes accordingly.
e2e-tests/scenarios.js
:
...
describe('View: Phone detail', function() {
...
it('should display the first phone image as the main phone image', function() {
var mainImage = element(by.css('img.phone'));
expect(mainImage.getAttribute('src')).toMatch(/img\/phones\/nexus-s.0.jpg/);
});
it('should swap the main image when clicking on a thumbnail image', function() {
var mainImage = element(by.css('img.phone'));
var thumbnails = element.all(by.css('.phone-thumbs img'));
thumbnails.get(2).click();
expect(mainImage.getAttribute('src')).toMatch(/img\/phones\/nexus-s.2.jpg/);
thumbnails.get(0).click();
expect(mainImage.getAttribute('src')).toMatch(/img\/phones\/nexus-s.0.jpg/);
});
});
...
You can now rerun the tests with npm run protractor
.
We also have to refactor one of our unit tests, because of the addition of the mainImageUrl
model
property to the controller. As previously, we will use a mocked response.
app/phone-detail/phone-detail.component.spec.js
:
...
describe('controller', function() {
var $httpBackend, ctrl
var xyzPhoneData = {
name: 'phone xyz',
images: ['image/url1.png', 'image/url2.png']
};
beforeEach(inject(function($componentController, _$httpBackend_, _$routeParams_) {
$httpBackend = _$httpBackend_;
$httpBackend.expectGET('phones/xyz.json').respond(xyzPhoneData);
...
}));
it('should fetch phone details', function() {
expect(ctrl.phone).toBeUndefined();
$httpBackend.flush();
expect(ctrl.phone).toEqual(xyzPhoneData);
});
});
...
Our unit tests should now be passing again.
Similar to the ngClick
directive, which binds an AngularJS expression to the click
event, there
are built-in directives for all native events, such as dblclick
, focus
/blur
, mouse and key
events, etc.
Let's add a new controller method to the phoneDetail
component's controller:
self.onDblclick = function onDblclick(imageUrl) {
alert('You double-clicked image: ' + imageUrl);
};
and add the following to the
element in phone-detail.template.html
:

Now, whenever you double-click on a thumbnail, an alert pops-up. Pretty annoying!
With the phone image swapper in place, we are ready for step 13 to learn an even better way to fetch data.


You can add a new rule (or extend an existing rule) as follows:
jss.set('code', {
color: teal;
});
You can retrieve the rules for a specific CSS selector as follows:
jss.getAll('code');
This will return an object:
{"color":"teal"}
You can also completely remove an existing rule using:
jss.remove('code');
Choose your colour:
Choose your font style:


Installation and Configuration¶
This chapter describes how to install and configure GeoMesa on a Linux system. This includes installation of the Accumulo and Kafka data stores and installation and configuration of the GeoServer plugins.
Prerequisites and Platform¶
Warning
GeoMesa requires Accumulo 1.5, 1.6, or 1.7, which in turn requires Hadoop 2.2 or better and ZooKeeper 3.4.5 or better. Installing and configuring Accumulo is beyond the scope of this manual.
Using the Kafka module requires Kafka 0.8.2 or 0.9 and ZooKeeper 3.4.5 or better.
To install the binary distribution:
To build and install the source distribution:
- Java JDK 8,
- Apache Maven (http://maven.apache.org/) 3.2.2 or better
- A
git
client (http://git-scm.com/)
Versions and Downloads¶
Note
The current recommended version of GeoMesa to install is 1.2.4.
Latest release: 1.2.4
- Release tarball: https://repo.locationtech.org/content/repositories/geomesa-releases/org/locationtech/geomesa/geomesa-dist/1.2.4/geomesa-dist-1.2.4-bin.tar.gz
- Source: https://github.com/locationtech/geomesa/archive/geomesa-1.2.4.tar.gz
Development version (source only): 1.2.5-SNAPSHOT
Latest release which has been fully reviewed by Eclipse Legal: 1.2.0
GeoMesa is part of the Locationtech working group at Eclipse. The Eclipse legal team fully reviews each major release for IP concerns.
Warning
Eclipse releases may not contain all the bug fixes and improvements from the latest release.
- Release distribution: http://download.locationtech.org/geomesa/1.2.0/geomesa-dist-1.2.0-bin.tar.gz
- Source: http://download.locationtech.org/geomesa/1.2.0/geomesa-source-1.2.0.tar.gz
1.1.x release: 1.1.0-rc.7
- Release tarball: https://repo.locationtech.org/content/repositories/geomesa-releases/org/locationtech/geomesa/geomesa-assemble/1.1.0-rc.7/geomesa-assemble-1.1.0-rc.7-bin.tar.gz
- Source: https://github.com/locationtech/geomesa/archive/geomesa-1.1.0-rc.7.tar.gz
GeoMesa artifacts can be downloaded from the LocationTech Maven repository: https://repo.locationtech.org/content/repositories/geomesa-releases/.
Snapshot artifacts are available in the LocationTech snapshots repository: https://repo.locationtech.org/content/repositories/geomesa-snapshots/.
Installing from the Binary Distribution¶
GeoMesa artifacts are available for download or can be built from source.
The easiest way to get started is to download the most recent binary version ($VERSION
= 1.2.4)
and untar it somewhere convenient.
# download and unpackage the most recent distribution
$ wget http://repo.locationtech.org/content/repositories/geomesa-releases/org/locationtech/geomesa/geomesa-dist/$VERSION/geomesa-dist-$VERSION-bin.tar.gz
$ tar xvf geomesa-dist-$VERSION-bin.tar.gz
$ cd geomesa-$VERSION
$ ls
dist/ docs/ LICENSE.txt README.md
Building from Source¶
GeoMesa may also be built from source. For more information refer to Building from Source
in the Developer Manual, or to the README.md
file in the the
source distribution. The remainder of the instructions in this chapter assume
the use of the binary GeoMesa distribution. If you have built from source, the
distribution is created in the geomesa-dist/target
directory as a part of
the build process.
More information about developing with GeoMesa may be found in the Developer Manual.
Installing the Accumulo Distributed Runtime Library¶
The geomesa-$VERSION/dist/accumulo
directory contains the distributed
runtime JAR that contains server-side code for Accumulo that must be made
available on each of the Accumulo tablet servers in the cluster. This JAR
contains GeoMesa code and the Accumulo iterator required for querying
GeoMesa data.
The version of the distributed runtime JAR must match the version of the GeoMesa data store client JAR (usually installed in GeoServer; see below). If not, queries might not work correctly or at all.
For Accumulo 1.5¶
The runtime JAR should be copied into the $ACCUMULO_HOME/lib/ext
folder on
each tablet server.
# something like this for each tablet server
$ scp geomesa-$VERSION/dist/accumulo/geomesa-accumulo-distributed-runtime-$VERSION.jar tserver1:$ACCUMULO_HOME/lib/ext
Note
You do not need the JAR on the Accumulo master server, and including it there may cause classpath issues later.
For Accumulo 1.6+¶
Copying the runtime JAR to each tablet server as for Accumulo 1.5 above will still work, but in Accumulo 1.6, we can leverage namespaces to isolate the GeoMesa classpath from the rest of Accumulo. First, you have to create the namespace in the Accumulo shell:
$ accumulo shell -u root
> createnamespace myNamespace
> grant NameSpace.CREATE_TABLE -ns myNamespace -u myUser
> config -s general.vfs.context.classpath.myNamespace=hdfs://NAME_NODE_FDQN:54310/accumulo/classpath/myNamespace/[^.].*.jar
> config -ns myNamespace -s table.classpath.context=myNamespace
Note
Depending on Hadoop version, you may need to use hdfs://NAME_NODE_FDQN:8020
.
Then copy the distributed runtime jar into HDFS under the path you specified.
The path above is just an example; you can included nested folders with project
names, version numbers, and other information in order to have different versions of GeoMesa on
the same Accumulo instance. You should remove any GeoMesa JARs under
$ACCUMULO_HOME/lib/ext
to prevent any classpath conflicts.
Note
When connecting to a data store using Accumulo namespaces, you must prefix
the tableName
parameter with the namespace. For example, refer to the
my_catalog
table as myNamespace.my_catalog
.
Setting up the Command Line Tools¶
Warning
To use the Accumulo data store with the command line tools, you need to install the distributed runtime first. See Installing the Accumulo Distributed Runtime Library.
Note
The command line tools currently support the Accumulo and Kafka data stores.
GeoMesa comes with a set of command line tools for managing features. To complete the setup
of the tools, cd into the dist/tools
directory of the binary distribution and unpack the
geomesa-tools-$VERSION-bin.tar.gz
file ($VERSION
= 1.2.4).
$ cd geomesa-$VERSION/dist/tools
$ tar -xzvf geomesa-tools-$VERSION-bin.tar.gz
$ cd geomesa-tools-$VERSION
$ ls
bin/ conf/ examples/ lib/
The instructions below assume that the geomesa-tools-$VERSION
directory is kept in the
geomesa-$VERSION/dist/tools
directory, but the tools distribution may be moved elsewhere
as desired.
In the geomesa-tools-$VERSION
directory, run bin/geomesa configure
to set up the tools.
### in geomesa-$VERSION/dist/tools/geomesa-tools-$VERSION:
$ bin/geomesa configure
Warning: GEOMESA_HOME is not set, using /path/to/geomesa-$VERSION/dist/tools/geomesa-tools-$VERSION
Using GEOMESA_HOME as set: /path/to/geomesa-$VERSION/dist/tools/geomesa-tools-$VERSION
Is this intentional? Y\n y
Warning: GEOMESA_LIB already set, probably by a prior configuration.
Current value is /path/to/geomesa-$VERSION/dist/tools/geomesa-tools-$VERSION/lib.
Is this intentional? Y\n y
To persist the configuration please update your bashrc file to include:
export GEOMESA_HOME=/path/to/geomesa-$VERSION/dist/tools/geomesa-tools-$VERSION
export PATH=${GEOMESA_HOME}/bin:$PATH
Update and re-source your ~/.bashrc
file to include the $GEOMESA_HOME
and $PATH
updates.
Warning
Please note that the $GEOMESA_HOME
variable points to the location of the geomesa-tools-$VERSION
directory, not the main geomesa binary distribution directory!
Note
geomesa
will read the $ACCUMULO_HOME
and $HADOOP_HOME
environment variables to load the
appropriate JAR files for Hadoop, Accumulo, Zookeeper, and Thrift. If possible, we recommend
installing the tools on the Accumulo master server, as you may also need various configuration
files from Hadoop/Accumulo in order to run certain commands. Use the geomesa classpath
command in order to see what JARs are being used.
If you are running the tools on a system without
Accumulo installed and configured, the install-hadoop-accumulo.sh
script
in the bin
directory may be used to download the needed Hadoop/Accumulo JARs into
the lib
directory. You should edit this script to match the versions used by your
installation.
Due to licensing restrictions, dependencies for shape file support and raster ingest must be separately installed. Do this with the following commands:
$ bin/install-jai.sh
$ bin/install-jline.sh
Test the command that invokes the GeoMesa Tools:
$ geomesa
Using GEOMESA_HOME = /path/to/geomesa-$VERSION
Usage: geomesa [command] [command options]
Commands:
create Create a feature definition in a GeoMesa catalog
deletecatalog Delete a GeoMesa catalog completely (and all features in it)
deleteraster Delete a GeoMesa Raster Table
describe Describe the attributes of a given feature in GeoMesa
env Examine the current GeoMesa environment
explain Explain how a GeoMesa query will be executed
export Export a GeoMesa feature
getsft Get the SimpleFeatureType of a feature
help Show help
ingest Ingest a file of various formats into GeoMesa
ingestraster Ingest a raster file or raster files in a directory into GeoMesa
keywords Add/remove keywords on an existing schema
list List GeoMesa features for a given catalog
queryrasterstats Export queries and statistics about the last X number of queries to a CSV file.
removeschema Remove a schema and associated features from a GeoMesa catalog
stats-analyze Analyze statistics on a GeoMesa feature type
stats-bounds View bounds on attributes in a GeoMesa schema
stats-count View feature counts in a GeoMesa schema
stats-enumerate Enumerate attribute values in a GeoMesa feature type
stats-histogram View statistics on a GeoMesa feature type
tableconf Perform table configuration operations
version GeoMesa Version
GeoMesa Tools comes bundled by default with an SLF4J implementation that is installed to the $GEOMESA_HOME/lib
directory
named slf4j-log4j12-1.7.5.jar
. If you already have an SLF4J implementation installed on your Java classpath you may
see errors at runtime and will have to exclude one of the JARs. This can be done by simply renaming the bundled
slf4j-log4j12-1.7.5.jar
file to slf4j-log4j12-1.7.5.jar.exclude
.
Note that if no slf4j implementation is installed you will see this error:
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
In this case you may download SLF4J from http://www.slf4j.org/download.html. Extract
slf4j-log4j12-1.7.7.jar
and place it in the lib
directory of the binary distribution.
If this conflicts with another SLF4J implementation, you may need to remove it from the lib
directory.
Installing the GeoMesa GeoServer Plugins¶
Warning
The GeoMesa GeoServer plugins require the use of GeoServer 2.8.1 and GeoTools 14.1.
As described in section GeoMesa and GeoServer, GeoMesa implements a GeoTools-compatible data store. This makes it possible to use GeoMesa as a data store in GeoServer. The documentation below describes how to configure GeoServer to connect to GeoMesa Accumulo and Kafka data stores. GeoServer’s web site includes installation instructions for GeoServer.
After GeoServer is running, you will also need to install the WPS plugin to your GeoServer instance. The GeoServer WPS Plugin must match the version of GeoServer instance. This is needed for both the Accumulo and Kafka variants of the plugin. The GeoServer website includes instructions for downloading and installing the WPS plugin.
Note
If using Tomcat as a web server, it will most likely be necessary to pass some custom options:
export CATALINA_OPTS="-Xmx8g -XX:MaxPermSize=512M -Duser.timezone=UTC -server -Djava.awt.headless=true"
The value of -Xmx
should be as large as your system will permit; this
is especially important for the Kafka plugin. You
should also consider passing -DGEOWEBCACHE_CACHE_DIR=/tmp/$USER-gwc
and -DEPSG-HSQL.directory=/tmp/$USER-hsql
as well. Be sure to restart Tomcat for changes to take place.
For Accumulo¶
To install the GeoMesa Accumulo GeoServer plugin, unpack the contents of the
geomesa-accumulo-gs-plugin-$VERSION.tar.gz
file in geomesa-$VERSION/dist/gs-plugins
into your GeoServer’s lib
directory ($VERSION
= 1.2.4):
If you are using Tomcat:
$ tar -xzvf \
geomesa-$VERSION/dist/gs-plugins/geomesa-accumulo-gs-plugin-$VERSION-install.tar.gz \
-C /path/to/tomcat/webapps/geoserver/WEB-INF/lib/
If you are using GeoServer’s built in Jetty web server:
$ tar -xzvf \
geomesa-$VERSION/dist/gs-plugins/geomesa-accumulo-gs-plugin-$VERSION-install.tar.gz \
-C /path/to/geoserver/webapps/geoserver/WEB-INF/lib/
There are additional JARs for Accumulo, Zookeeper, Hadoop, and Thrift that will
be specific to your installation that you will also need to copy to GeoServer’s
WEB-INF/lib
directory. For example, GeoMesa only requires Hadoop
2.2 or better, but if you are using Hadoop 2.5.0 you should use the JARs
that match the version of Hadoop you are running.
There is a script in the geomesa-tools-$VERSION
directory
($GEOMESA_HOME/bin/install-hadoop-accumulo.sh
) which will install these
dependencies to a target directory using wget
(requires an internet
connection).
Note
You may have to edit the install-hadoop-accumulo.sh
script to set the
versions of Accumulo, Zookeeper, Hadoop, and Thrift you are running.
$ $GEOMESA_HOME/bin/install-hadoop-accumulo.sh /path/to/tomcat/webapps/geoserver/WEB-INF/lib/
Install accumulo and hadoop dependencies to /path/to/tomcat/webapps/geoserver/WEB-INF/lib/?
Confirm? [Y/n]y
fetching https://search.maven.org/remotecontent?filepath=org/apache/accumulo/accumulo-core/1.6.5/accumulo-core-1.6.5.jar
--2015-09-29 15:06:48-- https://search.maven.org/remotecontent?filepath=org/apache/accumulo/accumulo-core/1.6.5/accumulo-core-1.6.5.jar
Resolving search.maven.org (search.maven.org)... <IP_ADDRESS>
Connecting to search.maven.org (search.maven.org)|<IP_ADDRESS>|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 4646545 (4.4M) [application/java-archive]
Saving to: ‘/path/to/tomcat/webapps/geoserver/WEB-INF/lib/accumulo-core-1.6.5.jar’
...
If you do no have an internet connection you can download the JARs manually via http://search.maven.org/. These may include the JARs below; the specific JARs needed for some common configurations are listed below:
Accumulo 1.5
- accumulo-core-1.5.4.jar
- accumulo-fate-1.5.4.jar
- accumulo-start-1.5.4.jar
- accumulo-trace-1.5.4.jar
- libthrift-0.9.0.jar
- zookeeper-3.3.6.jar
Accumulo 1.6
- accumulo-core-1.6.5.jar
- accumulo-fate-1.6.5.jar
- accumulo-server-base-1.6.5.jar
- accumulo-trace-1.6.5.jar
- accumulo-start-1.6.5.jar
- libthrift-0.9.1.jar
- zookeeper-3.4.6.jar
- commons-vfs2-2.0.jar
Accumulo 1.7+ (note the addition of htrace)
- accumulo-core-1.7.1.jar
- accumulo-fate-1.7.1.jar
- accumulo-server-base-1.7.1.jar
- accumulo-trace-1.7.1.jar
- accumulo-start-1.7.1.jar
- libthrift-0.9.1.jar
- zookeeper-3.4.6.jar
- htrace-core-3.1.0-incubating.jar
- commons-vfs2-2.1.jar
Hadoop 2.2
- commons-configuration-1.6.jar
- hadoop-auth-2.2.0.jar
- hadoop-client-2.2.0.jar
- hadoop-common-2.2.0.jar
- hadoop-hdfs-2.2.0.jar
Hadoop 2.4-2.7 (adjust versions as needed)
- commons-configuration-1.6.jar
- hadoop-auth-2.6.4.jar
- hadoop-client-2.6.4.jar
- hadoop-common-2.6.4.jar
- hadoop-hdfs-2.6.4.jar
Restart GeoServer after the JARs are installed.
For Kafka¶
The GeoMesa GeoServer plugin for Kafka 0.8.2 is found in the geomesa-kafka-gs-plugin-$VERSION-install.tar.gz
file in geomesa-$VERSION/dist/gs-plugins
in the binary distribution, or is built in
the geomesa-gs-plugin/geomesa-kafka-gs-plugin
directory of the source distribution.
The GeoMesa GeoServer plugin for Kafka 0.9 is found in geomesa-kafka-09-gs-plugin-$VERSION-install.tar.gz
(downloaded here: https://repo.locationtech.org/content/repositories/geomesa-releases/org/locationtech/geomesa/geomesa-kafka-09-gs-plugin/1.2.4/geomesa-kafka-09-gs-plugin-1.2.4-install.tar.gz), or is built in the
geomesa-gs-plugin/geomesa-kafka-09-gs-plugin
directory of the source distribution.
In either case, the contents of the appropriate archive should be unpacked in the GeoServer
WEB-INF/lib
directory. If you are using Tomcat:
$ tar -xzvf \
geomesa-$VERSION/dist/gs-plugins/geomesa-kafka-gs-plugin-$VERSION-install.tar.gz \
-C /path/to/tomcat/webapps/geoserver/WEB-INF/lib/
If you are using GeoServer’s built in Jetty web server:
$ tar -xzvf \
geomesa-$VERSION/dist/gs-plugins/geomesa-kafka-gs-plugin-$VERSION-install.tar.gz \
-C /path/to/geoserver/webapps/geoserver/WEB-INF/lib/
This will install the JARs for the Kafka GeoServer plugin and most of its dependencies.
However, you will also need additional JARs for Kafka and Zookeeper that will
be specific to your installation that you will also need to copy to GeoServer’s
WEB-INF/lib
directory. For example, GeoMesa only requires Kafka 0.8.2 or 0.9,
but if you are using Kafka 0.9.0 you should use the JARs that match the version of
Kafka you are running.
Warning
GeoMesa 1.2.4 depends on Scala 2.11, so you should make sure you use the
Kafka version built with Scala 2.11 as well (kafka_2.11_*
) to avoid
compatibility issues.
Copy these additional dependencies (or the equivalents for your Kafka installation) to
your GeoServer WEB-INF/lib
directory.
- Kafka
- kafka-clients-<IP_ADDRESS>.jar
- kafka_2.11-<IP_ADDRESS>.jar
- metrics-core-2.2.0.jar
- zkclient-0.3.jar
- Zookeeper
- zookeeper-3.4.5.jar
There is a script in the geomesa-tools-$VERSION
directory
($GEOMESA_HOME/bin/install-kafka.sh
) which will install these
dependencies to a target directory using wget
(requires an internet
connection).
Restart GeoServer after the JARs are installed.
For HBase¶
The HBase GeoServer plugin is not bundled by default in the GeoMesa binary distribution
and should be built from source. Download the source distribution (see
Building from Source), go to the geomesa-gs-plugin/geomesa-hbase-gs-plugin
directory, and build the module using the hbase
Maven profile:
$ mvn clean install -Phbase
After building, extract target/geomesa-hbase-gs-plugin-$VERSION-install.tar.gz
into GeoServer’s
WEB-INF/lib
directory. Note that this plugin contains a shaded JAR with HBase 1.1.5
bundled. If you require a different version, modify the pom.xml
and rebuild following
the instructions above.
This distribution does not include the Hadoop or Zookeeper JARs; the following JARs
should be copied from the lib
directory of your HBase or Hadoop installations into
GeoServer’s WEB-INF/lib
directory:
- hadoop-annotations-2.5.1.jar
- hadoop-auth-2.5.1.jar
- hadoop-common-2.5.1.jar
- hadoop-mapreduce-client-core-2.5.1.jar
- hadoop-yarn-api-2.5.1.jar
- hadoop-yarn-common-2.5.1.jar
- zookeeper-3.4.6.jar
- commons-configuration-1.6.jar
(Note the versions may vary depending on your installation.)
The HBase data store requires the configuration file hbase-site.xml
to be on the classpath. This can
be accomplished by placing the file in geoserver/WEB-INF/classes
(you should make the directory if it
doesn’t exist).
Restart GeoServer after the JARs are installed.
For Cassandra¶
The Cassandra GeoServer plugin is not bundled by default in the GeoMesa binary distribution
and should be built from source. Download the source distribution (see
Building from Source), go to the geomesa-gs-plugin/geomesa-cassandra-gs-plugin
directory, and build the module:
$ mvn clean install
After building, extract target/geomesa-cassandra-gs-plugin-$VERSION-install.tar.gz
into GeoServer’s
WEB-INF/lib
directory.
Restart GeoServer after the JARs are installed.
Upgrading¶
To upgrade between minor releases of GeoMesa, the versions of all GeoMesa components
must match. This means that the version of the geomesa-distributed-runtime
JAR installed on Accumulo tablet servers must match the version of the
geomesa-plugin
JARs installed in the WEB-INF/lib
directory of GeoServer.
We strive to maintain backwards compatibility for data ingested with older releases of GeoMesa, and in general data ingested with older releases may be read with newer ones (note that the reverse does not apply). For example, data ingested into Accumulo with GeoMesa 1.2.2 may be read with 1.2.3.
It should be noted, however, that data ingested with older GeoMesa versions may not take full advantage of indexing improvements in newer releases. If it is not feasible to reingest old data, see Updating Existing Data to the Latest Index Format for more information on updating its index format.
Security Concerns¶
Apache Commons Collections¶
Version 3.2.1 and earlier of the Apache Commons Collections library have a CVSS 10.0 vulnerability. Read more here.
Note that Accumulo 1.6.5 is the first version of Accumulo which addresses this security concern. Fixes for the GeoServer project will be available in versions 2.8.3+ and 2.9.0+.


We are the HIGGAMING.WIN team. We are (not) actually a professional team. We just wanted a fancy website to be cool like them.
Game Night
Every Weds of each week (7pm EST)
Scheduled Overwatch Games
We need a team to challenge us!
Scheduled League of Legends Games
We need a 5th man first!
We are currently playing
HIG Gaming also occasionaly plays


At Vibinex, we have amazing lunch discussions. Multiple employees and interns have mentioned that their highlight of the day was always the conversations over lunch, even when they are assigned super-interesting work. This week, one such conversation was initiated by my co-founder, Tapish Rathore. He asked an open question: What is the ratio of happiness to sadness in a person's life? Do people stay sad more or do they stay happy more? What is this ratio a function of? Before you read ahead, I would urge you to think about this question yourself (and hopefully send me your response on any of my socials).
So here is my answer: I think everyone has the exact same amount of happiness and sadness in their lives. Why? Because humans only perceive differences. Our eyes don't sense light, they sense the difference between the light from the previous moment. Our ears, nose, skin, tongue, and all the other sense organs only ever measure the difference between their last state and their current state. And our perception of happiness and sadness is not an exception.
Here, my definitions of happiness and sadness are that of being opposites of each other. They are on the same scale - a sort of projection of each emotion on the "happiness" scale. For example, emotions like elation, laughter, pride, ecstasy, achievement, contentment, satisfaction, bliss etc. have a component in the positive direction of happiness. And emotions such as grief, pain, disappointment, rage, anxiety, guilt, disgust etc. have a component in the negative direction of happiness. I am defining sadness here as the absence of happiness. Like darkness is defined as the absence of light.
I believe that if you plot this happiness value of a person's life over time, you can draw the lines for their average, median and mode happiness levels. And whenever a person is above this average line, they feel that they are generally experiencing a good time in their life. And when they are below the line, they feel that the times are not that good. But this line is very customized to the person.
Consider two different people, Amar and Badri. Amar was born into an affluent family with a very loving and caring family. His parents have put a lot of effort into his upbringing and tried to make sure that he learns everything he needs to learn to succeed in life. And so he does. He excels in his studies and gets a job that he loves and that pays well.
On the other hand, Badri is not so fortunate. He is born into a family that struggles financially. During his childhood, his parents weren't around too much because they were both working multiple jobs to sustain their livelihood and provide him with good education and facilities. He did end up getting a job, but it is not the job of his choice and pays just enough for him to go on.
Now it is clear that Amar's quality of life is much better than that of Badri. But does that directly translate into happiness? Does Amar always stay happy? Does Badri always remain sad? No. Amar gets upset about not getting that promotion that he worked so hard on. And Badri gets elated whenever he is able to buy anything for his parents. The high points in Badri might not feel high to Amar, and the low points in Amar's life might not feel low to Badri.
A scene from the TV Show FRIENDS (Season 4, Episode 22) explains this concept to a good extent in a very relatable manner. In this scene, Phoebe listens to a big problem that Rachel has regarding 'going to Ross & Emily's wedding' and says that it reminds her of the time when she was offered food in exchange for sex when she lived on the streets.
If you have watched the show, you know that Phoebe has a very tough life, while Rachel was a spoilt brat. What was a huge problem for Rachel didn't even qualify as a problem for Phoebe.
Here we compared the experience of a life event for two different persons who have different average happiness levels. Another aspect of this is the variance. When you have higher highs and lower lows, you tend to feel that your life is very happening. Whereas when your highs are not that high and lows are not that low, you tend to feel boredom. My philosophy is to try to live a life as happening as possible. To do things and feel things.
This is where Tapish asked his next question:
For me, the answer is a clear no. Even if pleasure has a positive component to the happiness value and pain has a negative component towards it, these are not opposites. The absence of pleasure is not pain. In fact, for many kinds of pleasure, experiencing pain is a mandatory step.
In our previous blog on entertainment, we discussed pleasure hormones. One of those hormones, Endorphins are only produced through physical pain (when you workout, play sports or achieve an orgasm). But even more generally, pleasure and pain usually come together. You can only feel a sense of achievement if you have put a lot of hard work into something. Often going through a lot of pain. Without pain, there is hardly any pleasure. And you usually stay in a state of boredom (as defined above).
This is 10% luck, 20% skill, 15% concentrated power of will, 5% pleasure, 50% pain, and a 100% reason to remember the name- Remember the Name, Fort Minor


Vince leaves Paarl Rocks to join Big Bash on eve of MSL final
Cape Town - England Cricket World Cup winner James Vince has left the Paarl Rocks team to join the Sydney Sixers for the Big Bash League in Australia.
The Paarl Rocks secured a place in the MSL 2.0 final after defeating the Nelson Mandela Bay Giants on Sunday in Paarl.
Vince scored 226 runs in his eight games for the Paarl Rocks at an average of 37.6 and a strike rate of 141.25.
Paarl Rocks CEO James Fortuin wished Vince well in the upcoming season of the Big Bash.
“As captain of his county Hampshire, and an England player, he brought great experience into our team and he played a vital role in getting us to the final next Monday,” he said.
Fortuin said the Rocks were aware of the arrangement for Vince to join the Sydney Sixers at the conclusion of this weekend’s fixtures when he was signed.
The final of the Mzansi Super League is taking place at Boland Park on Monday, December 16 at 17:30.


Manage the authentication of a request. Must implement the get_user method
Must return a user if authentication is successfull, None otherwise
Authentication based on an apikey stored in a datastore.
Implement the Basic Auth authentication http://fr.wikipedia.org/wiki/HTTP_Authentification
return a user or None based on the Authorization: Basic header found in the request. login and password are Base64 encoded string : “login:password”


Before Change
current_test_header = "pcd entries:\n"
def parse(self, infile):
self._expect_header(infile.readline(), "pcd entries")
num_pcd_entries = self.parse_num_items(infile.readline())
pcd_entries = []
for i in range(0, num_pcd_entries):
line = infile.readline()
After Change
def parse(self, lines_iter):
self._expect_header(next(lines_iter), "pcd entries")
num_pcd_entries = self.parse_num_items(next(lines_iter))
pcd_entries = []
for _ in range(0, num_pcd_entries):
line = next(lines_iter)
tpl = line.split(b"\t")
if len(tpl) != 5:
raise ParseError("Line must contain 5 tab-separated fields: {}".format(line))
pcd_entries.append(tpl) // Note: we preserve the \n on the last entry.


'I will never retire!' Federer not thinking about calling it a day
However, the 38-year-old admitted he is relishing the freedom retirement will bring.
by The42 TeamROGER FEDERER JOKED he may never retire from tennis as he continues to focus on extending his career for as long as possible.
World number three Federer turned 38 in August and has just rounded off a hugely successful tour with Alexander Zverev.
The 20-time grand slam winner won four titles this season, while he missed out on glory at Wimbledon after losing in an epic final against Novak Djokovic.
Federer has recently invested in Swiss-based shoe company On Running, but he insists his business venture is not a sign he is set to stop playing the sport he loves.
“I’ve been asked all week about how retirement is going to be and when it is going to come, I think they all needed to know,” Federer said during his appearance on the Today Show.
“But no, this is not about retirement. On [the company] doesn’t want me to retire, they want me to play as long as possible and that is my goal. I will never retire!”
Federer did acknowledge, however, that he is looking forward to the freedom his eventual retirement will bring, considering the impact tennis has on the rest of his life.
“I like my sweets, desserts, time off,” he said. “I start my planning for the year around where I’m going to go on vacation with my family, and that’s where I’ll be in a couple of days, on the beach, so I can’t wait.
“Actually, when I had my knee issues in 2016 and I was rehabbing for almost eight months, I felt like that could be my life after [retirement].
“Of course I was never as busy but it was just nice to be able to have schedules with friends – lunch on Wednesdays, dinners on Fridays, let’s have a good time on the weekends together with another family. I’m really looking forward to that.”
Federer’s tour included matches against Zverev in Argentina, Chile, Mexico and Ecuador. The pair were due to play in Colombia too, but a curfew in Bogota meant the exhibition was called off.
“It was absolutely crazy,” Federer said of the tour. “We played in four cities, almost in front of 100,000 people and Mexico City, had 42,000 people, double of Arthur Ashe Stadium here in New York.
“Breaking those records, doing it with Zverev, it’s not something I ever thought I would do.”


clipboard
module¶
Autogenerated docs for the clipboard¶
Let’s re-implement it as an abstract factory.
-
exception
ClipboardEmpty
[source][source]¶ Bases:
ValueError
-
class
WindowsClipboard
(_clipboard=None, *args, **kwargs)[source][source]¶ Bases:
prompt_toolkit.clipboard.base.Clipboard
Creates a prompt_toolkit compatible implementation of a _clipboard.
Notes
Requires Mark Hammond’s pywin32 extensions.
-
__init__
(_clipboard=None, *args, **kwargs)[source][source]¶ Open a _clipboard on windows with win32clipboard.OpenClipboard.
- Raises
TryNext – If win32clipboard can’t be imported.
-
win32_clipboard_get
()[source][source]¶ Get the current _clipboard’s text on Windows.
Runs
win_clip_pywin32()
and if there’s any exception attempts to run win32yank through a piped subprocess.- Returns
- Return type
Text as returned by win32clipboard.GetClipboardData or None.
-
-
tkinter_clipboard_get
()[source][source]¶ Get the _clipboard’s text using Tkinter.
This is the default on systems that are not Windows or OS X. It may interfere with other UI toolkits and should be replaced with an implementation that uses that toolkit.
Notes
Requires
tkinter
.- Raises
-
class
ClipboardMagics
(**kwargs)[source][source]¶ Bases:
IPython.core.magic.Magics
Haven’t seen it implemented in a different way than this.
-
__init__
(shell=None, *args, **kwargs)[source][source]¶ Bind the IPython instance and it’s config and parent attributes.
-
-
class
UsefulClipboard
(clipboard=None)[source][source]¶ Bases:
prompt_toolkit.clipboard.base.Clipboard
Clipboard class that can dynamically returns any Clipboard.
Uses more functionally applicable defaults and requires less boilerplate.


Welcome to our sample website on GitHub Pages!
Here is my Kumu Network of two August Wilson plays, using Kumu.io's standard embed iframe settings for width and height: direct link: opens in new window --> If I start experimenting with the width and altering the iframe, here is how it turns out (with width at 80%):Here is a sample link to another website outside of this site. This link holds an absolute URL Penn State Erie, The Behrend College.
But here is a link to another page inside my website: this is a relative URL: inner page on this website.
Here is another relative link to a page inside my website (inside this docs directory.
We are writing HTML in the XHTML syntax, which means that all elements (including self-closing elements like <img>
) must indicate how they close.
All elements in XHTML syntax must have a start tag and an end tag, or indicate that they are self-closing.
HTML code has lower-level headings like from h2 to h6, but use them in order as you create subsections! You can control the size, position, color, font, and more of headings (and any HTML display elements) using CSS.
When should I use bold vs. strong in HTML code? These are inline elements.
Other HTML elements like the p (for paragraph) or the heading level elements, or ordered and unorderd lists, or img elements make blocks on the page and are known as block elements.


Excludes a directory from scanning.
Exclusion guidelines:
Leading and trailing slashes are required.
For example, if you enter exclude /directory, a warning message will appear and the directory will not be excluded.
Directory names cannot contain double asterisks (**).
You cannot exclude archives or contents within archives.


Welcome, Agrivesty API!
Agrivesty is an Crowdfunding System that help farmers to raise farming capital from available investor. In this platform, a user can either create a crowdfunding farming project or invest money towards their favorite farming projects.
The platform also provides social features where users can leave their comments and discuss projects and like a project.
Api Documentation


Best Black Friday 2019 smartphone deals
Here are the best Black Friday 2019 smartphone deals - updated every day!
by Jason EnglandCracked your screen and been waiting for Black Friday before you can replace your phone?
Don’t just go out and pick up any random slab of OLED and glass with more cameras than the M25. We’ve put together a list of the best bargain blowers that can be found - and there are some real stonkers to be found if you know where to look.
Apple iPhone 11 (Just £33 a month)
Think the iPhone 11 couldn't get any better - with its stunning camera setup, lightning quick performance and iOS 13?
Want to up that data cap, though? Are your consumption habits to the point you need triple figures of gigabytes? This deal from Three may be of interest to you...
- 100GB data
- Unlimited minutes
- Unlimited texts
- Global roaming
- 2 months free insurance
Total cost of ownership: £960
Buy yours from fonehouse for just £40 a month with zero upfront cost.
Looking for a case?
Here are the best cases available for the iPhone 11.
Google Pixel 4 (save £70)
Google's latest blower has just got a whole lot cheaper! With a seriously impressive 90Hz display, nifty radar tech that is becoming more and more useful every day and (of course, this is a Pixel after all) an incredible camera, this latest vessel for the squeaky clean version of Android is an ideal handset. And now you can take £70 off the price, it's a far better deal too.
Was £669 | Now £599 (£70 off)
Get yours now from Currys PC World
Looking for a case?
Here are the best cases available for the Google Pixel 4.
Sony Xperia 1 (save £200)
We're so glad to see this five-star phone on sale! It's 4K HDR OLED display at 21:9 aspect ratio makes it perfect for on-the-go binge watchers, and the camera on the back is a great shooter for everyone.
Was £849 | Now £649
Samsung Galaxy S10 (DOUBLE DATA + zero upfront cost)
Even at its original price of £200 the Honor 9 Lite was considered one of the smartphone steals of 2018, so at £80 less it would be absolutely criminal not to take advantage if you’re in the market for an entry level smartphone. Not that the 9 Lite looks cheap, with its glass back and aluminium sides, 18:9 Full HD screen and dual camera setup. The processor’s a bit underpowered and battery life isn’t the best, but at this price those are compromises worth making.
- 60GB data (Double Data)
- Unlimited minutes
- Unlimited texts
- Access to O2 Priority
Total cost of ownership: £792
Buy yours from mobiles.co.uk for just £33 a month with zero upfront cost.
Looking for a case?
Here are the best cases available for the Samsung Galaxy S10.
Samsung Galaxy S10 (£150 off)
Or if you'd prefer to buy the S10 SIM Free, we've got you covered there too. You can save £150 off the price of Samsung's flagship - great for those who already have a belter of a SIM only contract and want some amazing hardware to match.
Google Pixel 4 XL (TRIPLE DATA)
Not many manufacturers cater for those who don’t want a whopper of a screen these days, so Sony’s 5in Xperia XZ2 Compact is a bit of an anomaly in the smartphone world. While the build quality doesn’t match its bigger brethren and it’s a touch on the chunky side, there’s plenty of power inside, plus this particular deal also comes with a free pair of Sony’s excellent WF-1000X true wireless earphones, which makes it even more of a bargain.
- 90GB Data (Triple Data)
- Unlimited minutes
- Unlimited texts
- Access to O2 Priority offers
Total cost of ownership:£1061
Buy from Mobiles.co.uk for just £39 a month with £125 upfront cost.
Looking for a case?
Here are the best cases available for the Google Pixel 4 XL.
Samsung Galaxy Note 10 (Double data at just £37 a month)
Who doesn't love a massive screen on their phone? Samsung clearly know the answer to that question with their beasty Note 10. The gorgeous 6.3-inch Infinity-O display is great for consuming all that content. Plus that S-Pen is next level for productivity. Normally, a phone this new costs an arm and a leg, but now it's quite the steal.
- 60GB data
- Unlimited minutes
- Unlimited texts
- Access to O2 Priority
Total cost of ownership: £1063
Get yours here from mobiles.co.uk for just £37 a month with £175 upfront cost.
Honor 20 Pro (save £100)
Honor's tech-packed 20 Pro is an absolute beast - and at this price it’s even more tempting. It’s also far from a one-trick pony, with a shapely design, gorgeous 6.3in edge-to-edge screen, supercharged AI-assisted internals, an impressive battery life and that belter of a 48MP camera. If the circa £1000 asking prices of 2018’s latest flagships has put you off but you don’t want to compromise on specs, you can do a lot worse than a P20 Pro.
Was £549 | Now £449
Apple iPhone 11 Pro (100GB data and ZERO upfront cost)
As you may have seen in our review, we absolutely love the iPhone 11 Pro. From the super speedy A13 chip and far better battery life compared to the previous gen, to the seriously pro-level camera, there's a lot to adore... Add 100GB data and zero upfront cost into the mix for Black Friday, then you have a pretty unstoppable package.
- 100GB data
- Unlimited minutes
- Unlimited texts
- "Go Roam" - Three's Global roaming package
- Two months free insurance
Total cost of ownership: £1416
Buy yours fron fonehouse for £59 a month with zero upfront cost.
Looking for a case?
Here are the best cases available for the iPhone 11 Pro.
Huawei P30 Pro (save £150)
It seems like Huawei has come from out of nowhere over the past few years, quickly becoming one of the stand out brands for gadget nerds everywhere! The P30 Pro brings plenty of power to the table, all crammed into that bonkers pearlescent body that really stands out. The camera array produces some stunning shots and the beasty 4,200 mAh battery keeps things running all day.
Was £799 | Now £649
Samsung Galaxy S10 Plus (100GB data + zero upfront cost)
Big, brilliant and just dripping with top tech. Samsung's Galaxy S10 Plus is still one of the best top-end phones of this year, from that gorgeous OLED display to that photography powerhouse of cameras on the back.
And, it's one of a rare pack of phones that still sports a headphone jack, giving your earphone freedom!
- 100GB data
- Unlimited minutes
- Unlimited texts
- Global roaming
- 2 months free insurance
Total cost of ownership: £984
Get yours from fonehouse for just £41 a month with zero upfront cost.
Looking for a case?
Here are the best cases available for the Samsung Galaxy S10 Plus.
Google Pixel 3A (£70 off)
When it comes to the mid-range of phones, there's a lot to love about Google's Pixel 3A. The purest form of Android, a simple and impressively premium design, and arguably one of the best phone cameras available (Night Sight is mind-blowing). To already get this at under £400 is crazy, but now, a further £70 has been knocked off the price!


{% import 'helper_macros.html' as helpers %}
Stats page will be available soon!Contribute to the projects, while we gather the stats!


tinnitus auditory activity cortex brain neural stimulation hearing synchrony patients neuromodulation cortical Neurosci acoustic spontaneous different neuronal Eggermont Tass changes power neurons increased connectivity frequency gamma loss primary EEG network oscillations reset tinnitus. firing significantly synaptic Res effects functional showed correlations increase areas delta gamma-band {border-style LFP cat networks sound temporal abnormal px;} reduced related #ffffff;} Hauptmann computational inhibitory noise resting-state significant treatment chronic coordinated effective group model Tinnitus control correlation electrical frequencies human local pyramidal rhythms shown study ./S-()- Hear delivered e.g., field oscillatory perception population stimulus tones tonotopic visual Biol Figure Neural Neurophysiol analysis compared phase pitch reduction right studies study, synchronized theta (– Hz) Weisz activation clinical correlated coupling i.e., large prefrontal regions sensory spike CR-induced amplitude animal change cortex. desynchronization inhibition left map observed patterns plasticity rate strength However, Sci Thus, anti-kindling band connections excitatory frontal groups lateral normal potentials reflected results similar slow specific synchronization tinnitus, tinnitus-related waves Adamchic Brain Neurol Rev addition, central contralateral delta-band findings good important induced instance, loss, means neuron order percept potential pronounced reorganization response studied studies, typically (BA Coordinated MEG Nat Phys Popovych Schlee University absence alpha causes cells cingulate cochlear controls cross-correlation data decreased effect long-lasting loudness mean patients, peak phantom px; revealed role thalamic therapy used {font-family (– Hz), ./j.heares... ./s--- Acad Natl Noreña Proc activity. anterior applied cell concept conscious cortex, decrease differences does dorsal dorsolateral employing fast font-size generally high-frequency inhibition. inputs kindling larger likely long-range measured nucleus number obtained particular, pattern presence rates recorded responders resulting spectral spiking state stimulation. stimuli suggested synchrony. trauma using weeks (i.e., ./--- Acoustic CFC Clin LFPs Research Science Van abnormally achieved animals appears bursting cause caused clinically desynchronizing double; effects, efficacy electrophysiological evoked fluctuations following gyrus induce level loss. models neocortical networks. neuromodulation. organization permanent positive potentially proof recordings relevant rhythm scores single sources spikes subjective subpopulations tinnitus-pitch traveling van -week ./-()- ./journal.pone. ./pnas. Audiol Changes Cybern Department Int Jülich Langguth NIHL Neuron Spontaneous Steriade Trends VAS active acute attention bands based border-color border-width case correlates demonstrated did duration fMRI fact, general generated generation global group. hand, healthy hearing-loss higher highly horizontal humans hyperactivity immediately increases indicate individual information limited low magnetic make membrane-potential modulated motor negative pain parahippocampal pathological performed placebo populations properties reflects relationship resetting residual result sleep solid; source spike-pair statistical stimulation, strong synapses synchronous synchrony, that: theoretical tone underlying {font-style {font-weight (G) )]. ./-- ./BF ./j.-...x BMC BOLD Berlin: Biophys Calgary, Canada Center Cereb Comput Cortex Exp Furthermore, Given Hartmann Kempter Kindling Lett Macroscopic Nature Neuroscience Otolaryngol PSPs Phase Prog STDP Springer Synchrony Vanneste Verlag abnormalities activity, alignment and, and/or approach areas, associated attention, bold characterized combined comparison context contrast, controls. cortico-cortical courier; cycles daily depression der development differential discharges em; emergence enhancement environment evidence far fields function high homeostatic input inputs, insights intensities interaction involved just large-scale lasting linked long-term marked measurements mechanisms mode modulation nervous neurological neuromodulation, noisy occurring octave opposed oscillation pair pairs parkinsonian particular patients. perceived physical possible processing provide pt;} rat recording referred region relation repetition reported responses. resting signals simultaneous soft somatosensory sound. sounds stated states study. subsequent suggest suggests sustained symptoms system, system. target thalamocortical threshold tinnitus: tones, transient types unilateral weak dB – Hz – h/day


in 15 minutes or less
DDL is short for Data Definition Language, which deals with database schemas and descriptions, of how the data should reside in the database. In simpler words it is used to build and modify the structure of your tables and other objects in the database. DDL commands are as follows,
CREATE TABLE <table_name>
( column_name1 datatype,
column_name2 datatype,
.
.
.
column_name_n datatype
);
DROP TABLE <table_name>;
OR
DROP DATABASE <database_name>;
However, If you want to remove individual records, then use DELETE command that will be further in this tutorial.
ALTER TABLE <table_name>
ADD <column_name datatype>;
OR
ALTER TABLE <table_name>
CHANGE <old_column_name> <new_column_name>;
OR
ALTER TABLE <table_name>
DROP COLUMN <column_name>;
To view the changed structure of table, use 'DESCRIBE' command.
DESCRIBE TABLE employee;
RENAME TABLE <old_name> TO <new_name>;
TRUNCATE TABLE <table_name>;
DML stands for Data Manipulation Language and it deals with data manipulation. It includes the most common SQL statements such as SELECT, INSERT, UPDATE and DELETE all of which are used to manipulate or retrieve data in a database.


psychopy.monitors
- for those that don’t like Monitor Center¶Most users won’t need to use the code here. In general the Monitor Centre interface is sufficient
and monitors setup that way can be passed as strings to Window
s. If there
is some aspect of the normal calibration that you wish to override. eg:
from psychopy import visual, monitors
mon = monitors.Monitor('SonyG55')#fetch the most recent calib for this monitor
mon.setDistance(114)#further away than normal?
win = visual.Window(size=[1024,768], monitor=mon)
You might also want to fetch the Photometer
class for conducting your own calibrations
Monitor
¶psychopy.monitors.
Monitor
(name, width=None, distance=None, gamma=None, notes=None, useBits=None, verbose=True, currentCalib=None, autoLog=True)¶Creates a monitor object for storing calibration details. This will be loaded automatically from disk if the monitor name is already defined (see methods).
Many settings from the stored monitor can easilly be overridden either by adding them as arguments during the initial call.
arguments:
width, distance, gamma
are details about the calibration
notes
is a text field to store any useful info
useBits
True, False, None
verbose
True, False, None
currentCalib
is a dictionary object containing variousfields for a calibration. Use with caution since the dictionary may not contain all the necessary fields that a monitor object expects to find.
eg:
myMon = Monitor('sony500', distance=114)
Fetches the info on the sony500 and overrides its usual distance
to be 114cm for this experiment.
These can be saved to the monitor file using
saveMon()
or not (in which case the changes will be lost)
copyCalib
(calibName=None)¶Stores the settings for the current calibration settings as new monitor.
delCalib
(calibName)¶Remove a specific calibration from the current monitor. Won’t be finalised unless monitor is saved
gammaIsDefault
()¶Determine whether we’re using the default gamma values
getCalibDate
()¶As a python date object (convert to string using calibTools.strFromDate
getDKL_RGB
(RECOMPUTE=False)¶Returns the DKL->RGB conversion matrix. If one has been saved this will be returned. Otherwise, if power spectra are available for the monitor a matrix will be calculated.
getDistance
()¶Returns distance from viewer to the screen in cm, or None if not known
getGamma
()¶Returns just the gamma value (not the whole grid)
getGammaGrid
()¶Gets the min,max,gamma values for the each gun
getLMS_RGB
(recompute=False)¶Returns the LMS->RGB conversion matrix. If one has been saved this will be returned. Otherwise (if power spectra are available for the monitor) a matrix will be calculated.
getLevelsPost
()¶Gets the measured luminance values from last calibration TEST
getLevelsPre
()¶Gets the measured luminance values from last calibration
getLinearizeMethod
()¶Gets the method that this monitor is using to linearize the guns
getLumsPost
()¶Gets the measured luminance values from last calibration TEST
getLumsPre
()¶Gets the measured luminance values from last calibration
getMeanLum
()¶Returns the mean luminance of the screen if explicitly stored
getNotes
()¶Notes about the calibration
getPsychopyVersion
()¶Returns the version of PsychoPy that was used to create this calibration
getSizePix
()¶Returns the size of the current calibration in pixels, or None if not defined
getSpectra
()¶Gets the wavelength values from the last spectrometer measurement (if available)
getUseBits
()¶Was this calibration carried out witha a bits++ box
getWidth
()¶Of the viewable screen in cm, or None if not known
lineariseLums
(desiredLums, newInterpolators=False, overrideGamma=None)¶lums should be uncalibrated luminance values (e.g. a linear ramp) ranging 0:1
newCalib
(calibName=None, width=None, distance=None, gamma=None, notes=None, useBits=False, verbose=True)¶create a new (empty) calibration for this monitor and makes this the current calibration
saveMon
()¶Saves the current dictionary of calibrations as a json file
setCalibDate
(date=None)¶Sets the current calibration to have a date/time or to the current date/time if none given. (Also returns the date as set)
setCurrent
(calibration=-1)¶Sets the current calibration for this monitor. Note that a single file can hold multiple calibrations each stored under a different key (the date it was taken)
The argument is either a string (naming the calib) or an integer eg:
myMon.setCurrent('mainCalib')
fetches the calibration named mainCalib. You can name calibrations what you want but PsychoPy will give them names of date/time by default. In Monitor Center you can ‘copy...’ a calibration and give it a new name to keep a second version.
calibName = myMon.setCurrent(0)
fetches the first calibration (alphabetically) for this monitor
calibName = myMon.setCurrent(-1)
fetches the last alphabetical calibration for this monitor (this is default). If default names are used for calibrations (ie date/time stamp) then this will import the most recent.
setDKL_RGB
(dkl_rgb)¶Sets the DKL->RGB conversion matrix for a chromatically calibrated monitor (matrix is a 3x3 num array).
setDistance
(distance)¶To the screen (cm)
setGamma
(gamma)¶Sets the gamma value(s) for the monitor. This only uses a single gamma value for the three guns, which is fairly approximate. Better to use setGammaGrid (which uses one gamma value for each gun)
setGammaGrid
(gammaGrid)¶Sets the min,max,gamma values for the each gun
setLMS_RGB
(lms_rgb)¶Sets the LMS->RGB conversion matrix for a chromatically calibrated monitor (matrix is a 3x3 num array).
setLevelsPost
(levels)¶Sets the last set of luminance values measured AFTER calibration
setLevelsPre
(levels)¶Sets the last set of luminance values measured during calibration
setLineariseMethod
(method)¶Sets the method for linearising 0 uses y=a+(bx)^gamma 1 uses y=(a+bx)^gamma 2 uses linear interpolation over the curve
setLumsPost
(lums)¶Sets the last set of luminance values measured AFTER calibration
setLumsPre
(lums)¶Sets the last set of luminance values measured during calibration
setMeanLum
(meanLum)¶Records the mean luminance (for reference only)
setNotes
(notes)¶For you to store notes about the calibration
setPsychopyVersion
(version)¶To store the version of PsychoPy that this calibration used
setSizePix
(pixels)¶Set the size of the screen in pixels x,y
setSpectra
(nm, rgb)¶Sets the phosphor spectra measured by the spectrometer
setUseBits
(usebits)¶DEPRECATED: Use the new hardware classes to control these devices
setWidth
(width)¶Of the viewable screen (cm)
GammaCalculator
¶psychopy.monitors.
GammaCalculator
(inputs=(), lums=(), gamma=None, bitsIN=8, bitsOUT=8, eq=1)¶Class for managing gamma tables
Parameters:
in range 0.0:1.0, or range 0:255. Should include the min and max of the monitor
Then give EITHER “lums” or “gamma”:
- lums = measured luminance at given input levels
- gamma = your own gamma value (single float)
- bitsIN = number of values in your lookup table
- bitsOUT = number of bits in the DACs
myTable.gammaModel myTable.gamma
fitGammaErrFun
(params, x, y, minLum, maxLum)¶Provides an error function for fitting gamma function
(used by fitGammaFun)
fitGammaFun
(x, y)¶Fits a gamma function to the monitor calibration data.
getAllMonitors()
¶psychopy.monitors.
getAllMonitors
()¶Find the names of all monitors for which calibration files exist
findPR650()
¶psychopy.monitors.
findPR650
(ports=None)¶DEPRECATED (as of v.1.60.01).
Use psychopy.hardware.findPhotometer()
instead, which
finds a wider range of devices
getLumSeriesPR650()
¶psychopy.monitors.
getLumSeriesPR650
(lumLevels=8, winSize=(800, 600), monitor=None, gamma=1.0, allGuns=True, useBits=False, autoMode='auto', stimSize=0.3, photometer='COM1')¶DEPRECATED (since v1.60.01): Use
psychopy.monitors.getLumSeries()
instead
getRGBspectra()
¶psychopy.monitors.
getRGBspectra
(stimSize=0.3, winSize=(800, 600), photometer='COM1')¶| Params: |
name on which a photometer might be found (not recommended) |
|---|
gammaFun()
¶psychopy.monitors.
gammaFun
(xx, minLum, maxLum, gamma, eq=1, a=None, b=None, k=None)¶Returns gamma-transformed luminance values. y = gammaFun(x, minLum, maxLum, gamma)
a and b are calculated directly from minLum, maxLum, gamma
Parameters:
- xx are the input values (range 0-255 or 0.0-1.0)
- minLum = the minimum luminance of your monitor
- maxLum = the maximum luminance of your monitor (for this gun)
- gamma = the value of gamma (for this gun)
gammaInvFun()
¶psychopy.monitors.
gammaInvFun
(yy, minLum, maxLum, gamma, b=None, eq=1)¶Returns inverse gamma function for desired luminance values. x = gammaInvFun(y, minLum, maxLum, gamma)
a and b are calculated directly from minLum, maxLum, gamma Parameters:
xx are the input values (range 0-255 or 0.0-1.0)
minLum = the minimum luminance of your monitor
maxLum = the maximum luminance of your monitor (for this gun)
gamma = the value of gamma (for this gun)
- eq determines the gamma equation used;
eq==1[default]: yy = a + (b * xx)**gamma eq==2: yy = (a + b*xx)**gamma


The purpose of this game is to earn the most amount of money by the end of the allotted time frame. Have a fun and friendly competition with your peers to see who can make more!
The timer will start once you decide on which house to live and how fancy your dinner is!
Instructions
00
Hours
00
Minutes
00
Seconds
0
Weeks


Pokémon News
Pokémon Presents Reveals New Pokémon Snap, Pokémon Café Mix, and Shiny Zeraora
The recent Pokémon Presents has delivered loads of news that should thrill just about any Pokémon fan. This special presentation revealed a number of incredible game announcements, plus exciting updates to Pokémon GO and Pokémon Sword and Pokémon Shield. Read on for a wrap-up of Pokémon Presents and links to learn more about these great games.
New Pokémon Snap
For over 20 years, Pokémon fans have been wondering when there would be a follow-up to the hit Nintendo 64 game Pokémon Snap. We're excited to say that the time is now! New Pokémon Snap for Nintendo Switch is (as the title suggests) an all-new adventure through beautiful islands filled with Pokémon that are just waiting to be captured—through the lens of your camera.
Pokémon Sword and Pokémon Shield
The Isle of Armor, the first part of the Pokémon Sword Expansion Pass and Pokémon Shield Expansion Pass, has launched. The Galar region has gotten even larger, giving players new areas to explore and new Pokémon to encounter. To celebrate, a special Max Raid Battle featuring the Mythical Pokémon Zeraora will be available. If one million players manage to win this Max Raid Battle while it's available, Trainers can receive a Shiny Zeraora to add to their team!
There's even a nod to The Isle of Armor in Pokémon GO. Galarian Farfetch'd will appear in the mobile title, and Pokémon GO players will receive an avatar item inspired by the training clothing that you can wear in the Pokémon Sword and Pokémon Shield expansion.
Pokémon Café Mix
If you want some puzzling Pokémon fun on the go, Pokémon Café Mix is a pretty sweet game that's coming soon to Nintendo Switch and iOS and Android devices. In this game, you link together Pokémon icons to solve puzzles.  Get prepared early to see how extensive your Pokémon Café can get by preloading, preordering, or preregistering this free-to-start game today.
 There will also be a certain Pokémon making an appearance in the game this year that players will definitely want to add to their team. The other big Pokémon GO news from the presentation is that Mega Evolutions are coming to the game! Details are coming soon on this exciting new feature, but for now, look forward to seeing some powerful Mega-Evolved Pokémon in the real world.
Pokémon Smile
Pokémon Smile is an app for mobile devices that helps children develop good tooth-brushing habits. Oral hygiene might not always be fun for kids, but it becomes a lot more enjoyable when you're brushing your teeth to defeat nasty bacteria and help out some Pokémon friends. Pokémon Smile is available to download now at no cost, so get those bristles ready!


A First Animation
Reading an Image Sequence
Let's start with an already prepared image sequence and turn it into an animated PNG. The pictures for this are saved in the folder RunPNG/doc/samples/sprockets 3/.
First we start RunPNG. In the File menu, there is the Open Image Series ... entry. The corresponding button in the toolbar can also be used in the same way. If you click on one of the two, an open image series dialog appears.
This dialog allows multiple selections. To load all 15 pictures, we first click on the picture at the top left and then with the shift key pressed on the picture at the bottom right. All images are now selected. Finally we click on Open and RunPNG loads the whole series of images into memory.
We now have a series of 15 images in the application's main memory. At first glance, there is hardly any difference between the individual images. But it is there. In the first picture, the gear is still straight. In the second it is rotated by only 2° clockwise, in the third by 4°, then by 6° etc. This results in a rotation of 28° in the last (15th) image.
The reason: The gear shown has 12 teeth. 360° divided by 12 results in 30°. In the image sequence, the gear will only turn 28°. If the picture should appear for the 30° rotation, the display jumps back to picture #0 and the sequence starts again. This makes it appear as if the gear is rotating continuously. This saves a lot of work, storage space and possibly transmission times on the Internet. Because for a full rotation in 2° steps we would need 180 individual images. Which wouldn't make a lot of sense with the material at hand.
Setup the Animation
Next, the application needs to know what type of animation is to be used. There are three options for this:
The number of repetitions can be set right below. The number 0 means an endless repetition as long as the picture is shown. A higher number limits the repetitions to the entered value. The latter is intended for use cases in which a continuous repetition could prove to be disturbing.
The other settings on this tab are explained later.
Setup the Delay Time
Under the tab "Single Frame" we come to the delay time of the single images. I. E. how long a picture is shown until the displaying program should switch to the next picture. A setting of 0 is possible and is also expressly accepted in the APNG standard. Which then means that the program should change the screen as quickly as possible.
Said APNG standard provides for a fraction in seconds for the time specification: numerator / denominator. What could be 1/10 second but with 60/1 it can also last a minute. A minimum value of 1/1000 s and a maximum value of 65,535 / 1 s (> 18 h) can be set here. RunPNG offers the input of milliseconds as a convenience function and converts the input into a fraction.
The settings made here initially relate to the currently selected single image, so that individual values can be used. By clicking on the Delay for all frames button, the display time can also be transferred to all other images. Let's simply set a delay time of 100 ms or 1/10 s for all images here. Or another value if desired.
Then it looks something like this in the lower picture bar. The individual images now show the selected display or delay time. A little tip: If you hover the mouse pointer over a single image, a small window - called a tooltip - appears with information about the image. (Which is not so exciting here because all the pictures are the same size.)
Try the Animation
You can now try out the new animation. To do this, click on the Play entry in the Player menu or on the above symbol in the toolbar.
To stop playback, click on the button above, which appears in the place of the Play button.
Save the Animation
Finally the animation needs to be saved. Either via the File menu and the Save as Picture ... entry or via the button shown in the toolbar.
Note: RunPNG can save the images with the extension .png or .apng. According to the English Wikipedia, both are common filename extensions for APNG files. The German Wikipedia only specifies .png in a much poorer article. Mozilla itself does not comment on the filename extension and only announces the MIME type image/apng as an officially registered identifier with the IANA (Internet Assigned Numbers Authority). Windows 10 doesn't really know what to do with the ending .apng. Relevant graphics programs don't know the ending .apng anyway. It is therefore advisable to save the APNG files with the extension .png. Analogous to animated GIF files, which are usually not saved with the extension .agif.


Bootstrap is an extremely popular front-end framework for developing on the web. Used for marketing pages, web applications, and everything in between, it makes building websites fast and easy. To use Bootstrap all you need to know is the basics of HTML, CSS, and a little patience to read through the documentation.
This tutorial will take you through the basics of using the Bootstrap CSS framework to develop a simple webpage, like a resume. This was written using Bootstrap 4 alpha 6, but the few small diferences from Bootstrap 3 are noted as they come up.
There are a few simple rules to remember when building your layout in Bootstrap:
Bootstrap uses a 12-column grid system. Column elements may span multiple columns to create a wide variety of layouts.
.col-3
)
.offset-4
)
.col-md-3
).col-md-offset-3
)Bootstrap is made for creating responsive websites. There are five different screen sizes that you can use with your columns to make your layout responsive:
These classes combine with .col
and .offset
to apply at
certain screen sizes. When the screen is smaller than any columns you have defined,
it will take the full width of the screen. What does this mean? Let's look at a few
examples of class declarations, and what it will look like at each screen size.
Change the size of your browser to see how these examples look at each breakpoint.
.col-3
This targets screens that fall into the xs range. It will be 3 columns wide at all screen sizes.
.col-md-3 .col-lg-4
.col-2 .col-sm-4 .col-md-6 .col-lg-8 .col-xl-12
Watch as the column changes sizes as the size of your browser changes.
When initially working on your layout, make all columns using the .col-lg-#
size (.col-md-# in v3
). This lets you get a basic layout designed for
desktops, but it will collapse to every column taking the full screen width on smaller
screens which is often the desired behavior.
Once you have finished your website, you can go back and tweak the column sizes
for smaller screens if needed to add that final polish.
Bootstrap has styles for all headings sizes, h1
through h6
.
These work without any classes on the heading elements, and can also be applied to
p
elements using the classes .h1
through .h6
.
Optionally, you can add smaller, secondary text next to the headings as well.
Heading, p with .h1 class
Heading, p with .h1 class
Basic HTML lists are available in Bootstrap, with a unstyled list option available as well.
Description lists are lesser known, but extremely useful elements, especially for building something like a resume.
There are several utility classes that allow you to apply Bootstrap-themed colors to your text. The class names reflect how they might be used in a web application.