In various places in these docs you might find reference to caches. Please can make use of several caches to speed up its performance which are described here.
Not that caches are different from the output in
plz-out
. Even without caching, please will still
reuse built artifacts from plz-out
for incremental
builds. Please has strict caching and incrementality behavior. With that said,
you can still force a rebuild or a test rerun, use the
--rebuild
and
--rerun
flags respectively.
In all cases artifacts are only stored in the cache after a successful build or test run.
This is the simplest kind of cache; it's on by default and simply is a
directory tree (by default ~/.cache/please
or
~/Library/Caches/please
) containing various
versions of built artifacts. The main advantage of this is that it allows
extremely fast rebuilds when swapping between different versions of code
(notably git branches).
Note that the dir cache is not threadsafe or locked in any way beyond plz's normal repo lock, so sharing the same directory between multiple projects is probably a Bad Idea.
This is a more advanced cache which, as one would expect, can run on a centralised machine to share artifacts between multiple clients. It has a simple API based on PUT and GET to store and retrieve opaque blobs.
It is simply configured by setting the
httpurl
property in the
cache section of the config. There are a couple more settings to configure it for readonly mode and to
set timeouts etc.
Since the API is simple there are many existing servers that can be
configured for a backend; one option is nginx using its
webDAV
module.
Alternatively some CI services (for example
Cirrus) may offer a compatible cache out of the box.
Thanks to Diana Costea who implemented the original version of this as part of her internship with us, and prodded us into getting on and actually deploying it for our CI servers.
A reference implementation of the http cache can be found here however it should be possible to use any off the shelf http server with a little configuration, as described above.
You can realize a centralised cache also by managing the remote access part in external commands or scripts. Please will simply invoke the configured command whenever it wants to store or retrieve artifacts. A good use case is AWS S3 access by simply using the aws-cli. Lite weight generic S3 support (Minio/GCS/Backblaze etc.) could be added by running e.g. MinIO mc client or similar tools.
It's somewhat slower compared to the http cache because it must spawn external commands. Benefit is that you don't need to run and maintain a proxy between Please and your storage provider.
Enable read access by setting the
RetrieveCommand
property in the
cache section of the config.
The configured command must be able to stream a tar file to stdout.
Please sets the environment variable CACHE_KEY
to the cache entries filename.
[Cache]
# stream from s3 object to stdout:
RetrieveCommand="aws s3 cp s3://YOUR-OWN-CACHE-BUCKET/please/$CACHE_KEY -"
Write access is controlled by the
StoreCommand
property.
Keep it empty if you only want to have read-only access.
The configured command must be able to read a tar file from stdin.
Use the environment variable CACHE_KEY
as a part of the filename so that Please can retrieve the
artifact by using the same key later.
[Cache]
# stream stdin into a s3 object:
StoreCommand="aws s3 cp - s3://YOUR-OWN-CACHE-BUCKET/please/$CACHE_KEY"
Mind that you can configure read-only access but not write-only as RetrieveCommand is mandatory to enable custom cache support.
Raising the verbosity to debug
level will
help you to debug your script or command. Please logs each store/retrieve
operation to the custom cache and your scripts stderr will be shown as well.


Manual Tests (LTS 1.532.x)
Test results
- OK - test passed without any problem
- WARN - there was some problem, functionality doesn't do what is expected, but it doesn't cause failure of whole Jenkins or any other significant problems
- FAIL - cause failure of whole Jenkins or similar critical issue which affects all jobs (e.g. when plugin is installed, it's not possible to start Jenkins or save configuration of any job)
Selenium tests
Most of the test has bean automates as selenium tests. Instead of retesting manually, feel free to run the suite and report the results.
Environment |
LTS RC / result |
Tested by |
|---|---|---|
Arch / openJDK7 |
1.532.1 / OK |
ogondza |
* Following tests are broken
features/script.feature - ScriptTest in acceptance-test-harness passes
features/scriptler_plugin.feature:62 - ScriptlerPluginTest#create_and_run_parameterized_script in acceptance-test-harness passes
features/scriptler_plugin.feature:74 - ScriptlerPluginTest#override_default_parameters in acceptance-test-harness passes
Installation, upgrade
Test name |
Short description |
Expected result |
Notes |
LTS RC / result |
Tested by |
|---|---|---|---|---|---|
Install from RPM |
Install Jenkins from RPM package |
Jenkins is installed without error and runs |
FC 19, RHEL 6.4, openJDK7 |
|
|
Install from .deb |
Install Jenkins from Debian package |
Jenkins is installed without error and runs |
Debian 6 x86, Oracle JDK 7 |
1.532.2 / OK |
mwaite |
Install from war on Tomcat |
Install Jenkins from war by deploying on Tomcat |
Jenkins is deployed and runs |
Arch, openJDK7, Tomcat 7 |
1.532.1 / OK |
ogondza |
JBoss AS |
Install Jenkins from war by deploying on JBoss AS |
Jenkins is deployed and runs |
Arch, openJDK7, JBoss AS 7 |
1.532.1 / OK |
ogondza |
disk |
Make some changes directly on disk and launch "Reload Configuration from Disk" |
Made changes are reflected |
Arch / openJDK7 |
1.532.1 / OK : added to jenkins-test-harness |
ogondza |
Core functionality
Freestyle jobs
Test name |
Short description |
Expected result |
Notes |
LTS RC / result |
Tested by |
|---|---|---|---|---|---|
Batch build step |
Add a Windows batch file build step |
Batch build steps are executed successfully |
|
1.532.1 / OK |
kohsuke |
Plug-ins
Green balls (1.13)
Test name |
Short description |
Expected result |
Notes |
LTS RC / result |
Tested by |
|---|---|---|---|---|---|
Success results |
Success results |
Success results are marked as green |
Arch / openJDK7 |
1.532.1 / OK |
ogondza |
Sonar (2.0.1, 2.1)
Test name |
Short description |
Expected result |
Notes |
LTS RC / result |
Tested by |
|---|---|---|---|---|---|
Sonar analysis |
Setup sonar analysis |
Analysis is executed and published on sonar server |
|
|
|
Analysis collector (1.35, 1.36)
Test name |
Short description |
Expected result |
Notes |
LTS RC / result |
Tested by |
|---|---|---|---|---|---|
Collects and show results |
Setup collection of checkstyle, findbugs, pdm and warnings results collection |
Results are collected and shown |
|
|
|
Batch tasks (1.17)
Test name |
Short description |
Expected result |
Notes |
LTS RC / result |
Tested by |
|---|---|---|---|---|---|
Execute batch task |
Define batch task in project1, setup executions of this task in project 2 and schedule a build |
Batch task of project1 is executed |
Arch / openJDK7 |
1.532.1 / OK |
ogondza |
Jira (1.35, 1.37)
Test name |
Short description |
Expected result |
Notes |
LTS RC / result |
Tested by |
|---|---|---|---|---|---|
Update JIRA issue |
Update JIRA issue which is related to changes contained in the build |
JIRA is updated and on build page is a link to appropriate JIRA |
|
1.532.1 / OK : added to selenium-tests |
kohsuke |
Deploy (1.9)
Test name |
Short description |
Expected result |
Notes |
LTS RC / result |
Tested by |
|---|---|---|---|---|---|
Deploy on Tomcat 7 |
Build war app and deploy it on Tomcat 7 |
App is successfully deployed and running |
|
1.532.1 / OK : added to selenium-tests |
kohsuke |
Dry (2.34)
Test name |
Short description |
Expected result |
Notes |
LTS RC / result |
Tested by |
|---|---|---|---|---|---|
Publish DRY analysis results |
Setup CPD analysis and publish analysis results |
Results are published |
|
|
|
Backup (1.6.1)
Test name |
Short description |
Expected result |
Notes |
LTS RC / result |
Tested by |
|---|---|---|---|---|---|
Backup Jenkins configuration |
Setup backup dir and run Jenkins backup |
Once no builds run, backup is performed |
|
|
|
XUnit ()
Test name |
Short description |
Expected result |
Notes |
LTS RC / result |
Tested by |
|---|---|---|---|---|---|
Publish testing tools |
Create Test Result Trend graph |
|
|
1.532.1 / OK |
ogondza |
Scp publisher (1.8)
Test name |
Short description |
Expected result |
Notes |
LTS RC / result |
Tested by |
|---|---|---|---|---|---|
Publish artifact over scp |
Setup remote destination and artifact to be archived over scp |
Artifact is archived on remote machine in speficied dir |
|
1.532.1 / OK : added to selenium-tests |
kohsuke |
IRC (2.23)
Test name |
Short description |
Expected result |
Notes |
LTS RC / result |
Tested by |
|---|---|---|---|---|---|
Send IRC notification |
Setup IRC notification and schedule a build |
Notification is send to appropriate IRC channel |
Arch / openJDK7 |
1.532.1 / OK |
ogondza |
Run jenkins bot command |
Run bot command on IRC channel |
Command is executed |
|
|
|
Exploratory Tests
Test name |
Short description |
Expected result |
Notes |
LTS RC / result |
Tested by |
|---|---|---|---|---|---|
Stress/Load Test |
Run Xenu link checker while other interactive tests are running, and while jobs are executing |
Performance slower, but still functional and reliable, memory growth reasonable |
|
1.532.3 / OK |
mwaite |
Git plugin |
Explore multiple configurations of the Git plugin, including JGit and CliGit implementations, using ssh, https, and git protocol repositories |
Reasonable behavior, no detected Jenkins related regressions |
|
1.532.2 / OK |
mwaite |


程序包 planning
类 Map
- java.lang.Object
-
- planning.Map
-
public class Map extends java.lang.Object
A map regroups all the stations.- 作者:
- SUNXIAOYU
-
-
方法概要
所有方法 静态方法 实例方法 具体方法 修饰符和类型 方法 说明 void
addStation(Station s)
void
display()
to display all stationIDs in this mapint
getEleTotalBicycleNum()
static Map
getInstance()
int
getMecTotalBicycleNum()
java.lang.String
getName()
double
getSizeX()
double
getSizeY()
int
getStationNum()
java.util.HashMap<java.lang.Integer,Station>
getStations()
int
getTotalBicycleNum()
int
getTotalSlotNum()
void
init()
This correspond to the command setup velibnetworkName: to create a myVelib network with given name and consisting of 10 stations each of which has 10 parking slots and such that stations are arranged on a square grid whose of side 4km and initially populated with a 75% bikes randomly distributed over the 10 stationsvoid
init(int stationNum, int totalSlotNum)
this function initialize the map, where stations are distributed on a square grid, the side of which is 4km.void
init(int stationNum, int totalSlotNum, int totalBicycleNum, double size)
* This correspond to the command setup name nstations nslots sidearea nbikes: to create a myVelib network with given name and consisting of nstations stations with nslots parking slots and such that stations are arranged on a square grid whose of side sidarea and initially populated with a nbikes bikes randomly distributed over the stationsvoid
initFromFile(java.lang.String filepath)
to initialize from a filevoid
reset()
void
setName(java.lang.String name)
void
setSizeX(double sizeX)
void
setSizeY(double sizeY)
void
setTotalSlotNum(int totalSlotNum)
java.lang.String
toString()
override map toString method
-
-
-
方法详细资料
-
init
public void init(int stationNum, int totalSlotNum) throws java.lang.Exception
this function initialize the map, where stations are distributed on a square grid, the side of which is 4km. The square grid is just right to fit into the map size given by the minimum of sizeX and sizeY- 参数:
stationNum
- station numbertotalSlotNum
- slot number- 抛出:
java.lang.Exception
- several exceptions in initialization
-
init
public void init(int stationNum, int totalSlotNum, int totalBicycleNum, double size) throws java.lang.Exception
* This correspond to the command setup name nstations nslots sidearea nbikes: to create a myVelib network with given name and consisting of nstations stations with nslots parking slots and such that stations are arranged on a square grid whose of side sidarea and initially populated with a nbikes bikes randomly distributed over the stations- 参数:
stationNum
- station total numbertotalSlotNum
- slot total numbertotalBicycleNum
- bike total numbersize
- map size length in km(each 4 km to be a grid).- 抛出:
java.lang.Exception
- several exceptions in initialization
-
init
public void init()
This correspond to the command setup velibnetworkName: to create a myVelib network with given name and consisting of 10 stations each of which has 10 parking slots and such that stations are arranged on a square grid whose of side 4km and initially populated with a 75% bikes randomly distributed over the 10 stations
-
getInstance
public static Map getInstance()
-
getName
public java.lang.String getName()
-
setName
public void setName(java.lang.String name)
-
getSizeX
public double getSizeX()
-
getSizeY
public double getSizeY()
-
setSizeX
public void setSizeX(double sizeX)
-
setSizeY
public void setSizeY(double sizeY)
-
getStationNum
public int getStationNum()
-
getTotalSlotNum
public int getTotalSlotNum()
-
setTotalSlotNum
public void setTotalSlotNum(int totalSlotNum)
-
getStations
public java.util.HashMap<java.lang.Integer,Station> getStations()
-
getTotalBicycleNum
public int getTotalBicycleNum()
-
getEleTotalBicycleNum
public int getEleTotalBicycleNum()
-
getMecTotalBicycleNum
public int getMecTotalBicycleNum()
-
addStation
public void addStation(Station s)
-
toString
public java.lang.String toString()
override map toString method- 覆盖:
toString
在类中java.lang.Object
-
initFromFile
public void initFromFile(java.lang.String filepath)
to initialize from a file- 参数:
filepath
- file path to find
-
display
public void display()
to display all stationIDs in this map
-
reset
public void reset()
-
-


RStudio IDE; R language; Data classification and summary statistics.
In this module you will set up the working environment, connect to GitHub and pass the first big hurdle of importing data; you will learn how to do it in the proper way with a command in R. You will learn how to use RStudio IDE for R from its installation to RStudio customisation and files navigation. You will learn good habits and practice of workflow in an R project. Once you get comfortable with the RStudio working environment, you will move on to mastering the key features of R language and be introduced to fundamental statistical concepts. We will not stop there. You will be shown how to turn analyses into high quality documents and presentations with R Markdown. With the knowledge from this lesson you will be able to create reproducible reports straight from your R code allowing you to document your analysis and its results as an HTML, pdf, slideshow or Microsoft Word document.
What you will learn:
Data Wrangling and Visualising Data
In this module you will learn some of the fundamental techniques for data exploration and transformation through the use of dplyr package. This tidy verse package helps make your exploration intuitive to write and easy to read. You will learn dplyr’s key verbs for data manipulation that will help you uncover and shape the information within the data that is easy to turn into informative plots. Through the use of the grammar of graphics plotting concepts implemented in ggplot2 package you will be able create meaningful exploratory plots. You will develop understanding about the way in which you should be able to think about the necessary data transformations and summaries that can lead to an informative visualisation.
What you will learn:
DStatistical Modelling I
Introduction to DA Methodology and bivariate data analysis
In this module you will learn the fundamental concepts of statistical modelling, starting with exploring the data by using appropriate plots and computation of descriptive statistics and moving on to inferential statistics of parameter estimation and hypothesis testing. You will learn how to match up data types with an appropriate statistical model with the focus on the ‘Measured vs Attribute’ and ‘Measured vs Measured’ types of a bivariate data analysis problem. With the knowledge from this lesson you will be able to conduct basic ‘MvA’ and ‘MvM’ types of statistical analysis, interpret and report its outcomes in an appropriate manner.
What you will learn:
Statistical Modelling II
Machine learning: Multifactor linear regression and classification modelling
You will be introduced to broad ideas of supervised and unsupervised learning algorithms, as well as a number of core machine learning concepts. In this module, regression modelling is the key modelling construct that will be first introduced and then developed. You will learn the importance of selecting an appropriate causal model depending upon particular circumstances. You will also become familiar with the fundamental models and algorithms used in classification. With the knowledge from this lesson you will not just be able to conduct regression analysis, and interpret and report its outcomes in an appropriate manner, but you will be able to implement key learning algorithms for uncovering patterns and structure within data.
What you will learn:
© 2019 Tatjana Kecojevic


extends Object
a dictionary
void add ( String key, Object o );add the objectObject get ( String key );o
with namekey
return the object by keyInt size ( );number of elements in the dictionaryvoid remove ( String key );number of elements in the dictionary


Hurricane Maria is regarded as being the worst natural disaster on record to affect Dominica and Puerto Rico and the deadliest Atlantic hurricane since Hurricane Jeanne in 2004. The tenth-most intense Atlantic hurricane on record and the most intense tropical cyclone worldwide of 2017, Maria was the thirteenth named storm, eighth consecutive hurricane, fourth major hurricane, second Category 5 hurricane, and the deadliest storm of the hyperactive 2017 Atlantic hurricane season. At its peak, the hurricane caused catastrophic damage and numerous fatalities across the northeastern Caribbean, compounding recovery efforts in the areas of the Leeward Islands already struck by Hurricane Irma. Maria was the third consecutive major hurricane to threaten the Leeward Islands in two weeks, after Irma had made landfall in several of the islands two weeks prior and Hurricane Jose passed dangerously close shortly afterward, bringing tropical storm force winds to Barbuda.


skydiver
Senior Member
Registered: Nov 2001
Location: Topeka, KS, USA
Posts: 154 |
commonalities
Title- Commonalities
Author- Denise
E-mail -<EMAIL_ADDRESS>Category- Missing Scene/Tag, Cakefic, Sam/Jonas Friendship
Archive Anywhere but please link to the page on my own site. http://www.geocities.com/letthemeat...mmonalities.htm
Or
http://www.geocities.com/sky_diver1...mmonalities.htm
Season- 6
Spoilers – Unnatural Selection
Rating- PG -13
Content Warning- One big honkin cuss word
Summary- Sam and Jonas find a little common ground
Disclaimer Stargate Sg-1 and its characters are the property of Stargate (II) Productions, Showtime/Viacom, MGM/UA, Double Secret Productions, and Gekko Productions. This story is for entertainment purposes only and no money exchanged hands. No copyright infringement is intended. The original characters, situations, and story are the property of the author. This story may not be posted elsewhere without the consent of the author
Commonalities
By
Denise
Sam made her way through the halls; gladly leaving the bridge in what she hoped was the capable hands of the guys…or at least the autopilot. They were due to rendezvous with Thor soon, surely they could handle things for that long. Right now, she needed to get away, find a little privacy and regroup.
As she walked, her stomach growled, reminding her that it had been nearly twenty-four hours since she'd last eaten and even that had been a quick bite on the way to the airport. No. She stopped and thought. It'd been more like forty-eight or so since they'd been unconscious or at least unaware during the mind probes.
Shaking her head, she continued down the hall. However long it'd been, it was too long judging by the hollow feeling in her stomach. A hollow feeling that matched the one in her soul.
She arrived at the cargo bay and walked in, her heart sinking as she turned on the lights. Perfect. Just ****ing perfect.
They'd taken it all. Vaguely she remembered Fifth saying something about raiding their stores, but she hadn't imagined them taking everything. A sudden wave of depression washed over her as she turned. They'd be home in a few hours. She could just wait. It wasn’t like she was going to starve or anything.
"Sam?" She groaned softly, fighting the urge to turn and go the other way. Instead, she sighed, doing her best to keep her irritation off her face.
"Jonas," she said, turning to face him.
"Are you looking for food?" he asked, joining her.
"It looks like I'm too late," she said, shrugging her shoulders.
"Maybe, maybe not," he said, gesturing with his hand. "Hold on." He turned and opened the door to another cargo hold. He rummaged around for a few seconds and she nearly sighed aloud in frustration. A few seconds later, she turned back, his hands full. "Colonel O'Neill told us to stash this back for you," he explained, holding out a box of ho-ho's and a six pack of diet Coke. "The pop is warm but…" He handed them to her. "Anyway, sorry about the ice cream, not that it'd still be good after all this time."
She took the two items, struggling a bit not to drop the plastic bottles of pop. "Thanks," she said.
He stood there for a second, seemingly uncomfortable. "Umm…I'll aah…I'm sure they need me on the bridge." He turned and walked out of the room.
Sam looked down at the box and bottles. It certainly wasn't the most nutritious of food but…it was food. And Jonas loved his food. "Jonas," she said. He turned back, his face schooled in the nonchalance she'd started to recognize as his way of hiding any hurt feelings. "There's enough for two here," she offered. "Care to join me?"
He smiled and walked back towards her. He picked up an overturned crate and flipped it over, making a makeshift chair. She sat next to him and handed him a bottle of the pop before setting the rest down on the floor. She opened the box and handed him a package of the ho-ho's.
He unwrapped his treat and took a large bite, almost consuming the whole cake at once. "Are you ok?" he asked quietly, unwrapping a second cake.
"What?"
"Something happened after we left, didn't it?"
She took a drink of her pop and sighed. "Yeah."
"Do you want to talk about it?"
She shook her head. "No. I…"
"Ok," he agreed, opening his pop, taking care with the volatile beverage. He unwrapped another cake and handed it to her. She took it and instead of eating it, started to pick it apart, unfolding the layers with deliberate care. "I think we picked up Thor on the long range scanners. We should be home in a couple of hours."
Sam nodded, still not in the mood for conversation. He took another drink of his pop and stood up. "I should get back…"
"I lied to him," she said softly, her eyes focused on the far wall.
He sat back down. "Lied to whom?"
"I told Fifth we'd wait for him."  "When we set the timer, I told Fifth that we had five minutes and that we'd wait for him and take him back with us. I told him that, as I set the timer for three minutes and knew he'd never make it," she confessed.
"Oh," he said simply. "The colonel ordered you to didn't he?"
"Yeah."
"Well, then you were just following orders."
She shook her head. "That's a cop out. There's following orders and there's following orders.  He risked everything to help us and I looked him in the eyes and lied to him," she said, her stomach rolling in protest of her actions.
"Do you think it would have worked to bring him back? I mean, after what happened with Reese…" he said, his voice showing his discomfort at broaching a possibly touchy topic.
She sighed. "Probably not. Strategically, leaving him behind was the best thing to do. In fact, we should ask Thor to scan this ship thoroughly to make sure we don't have any stowaways." She sighed again. "It being a good strategic decision doesn’t make me feel any better."
"I remember, looking through Earth's history, several hundred years ago there was a plague," he said.
Sam nodded. "Black Death. It hit Europe three times I think."
"Right. There was this time in London…the people that lived in one area started to get sick and it was the plague. So the city leaders blocked off the area. Everyone, sick and healthy, was sealed in. They basically murdered a few hundred people to save the lives of thousands."
Sam shook her head. "What does this have to do with Fifth?"
"Leaving him behind means that two galaxies are safe," he said softly.
"I guess," she said, picking at the chocolate covering to the cake.
"We could talk to Thor," he offered.
"About what?"
"Tell him to leave a note or something." He shrugged. "Maybe when they figure out now to disable the others, they can spare him," he suggested.
"Maybe." She looked at him. "Unfortunately, we'll both be long dead by then."
"Maybe, maybe not. I mean, for all we know, the Asgard could crack the puzzle next week."
The ship shuddered and she automatically looked up. "Guess we've reached the rendezvous." She set down her ho-ho and stood up. "I guess I should go to the bridge so we can brief Thor." Jonas got up too, quickly swallowing the last of his cake. "Jonas?" He turned to look at her. "Thanks."
"Anytime." He took a drink of his pop, then screw on the cap and set it on the box. She followed suit, then proceeded him out of the cargo bay. They walked down the hall, headed towards the small elevator that would take them to the bridge.
"How about, after we get back and debrief, do you want to grab some dinner?" she asked.
"Sure. I think it's Salisbury Steak day in the commissary," he agreed.
"I actually was thinking of outside the SGC. There's this place called O'Malley's. Do you like steak?"
"Do they have French fries? I'm not too fond of baked potatoes," he said, following her into the lift.
She laughed slightly. "Yeah. They have fries."
"That sounds good," he agreed.
"Ok. It's a plan then."
"There was one more thing I was wondering if you could help me with," he said as the doors opened.
"Sure. What?"
"I was reading some books about entertainment and they mentioned a game called pool."
~Fin~
__________________
Denise's Fan Fiction
http://www.geocities.com/sky_diver119/index
Enjoy!
Let Them Eat Cake!
http://www.geocities.com/letthemeatcake2002/index
Where in the World is George Hammond?
http://www.geocities.com/witwigh/index
The Gatereview
http://www.gatereview.net/
Interested in a Virtual SG-1 Season 6?
For more info go to: http://www.spacemonkeys-gate.com/vs6/
~~~~~~~~~~~~~~
'Hey, Anubis, this is your agent. You're playing it way over the top, can you get serious please?'
Report this post to a moderator | ? + *
|


{% extends "base.html" %}
{% set active_page = "faq" %}
{% block title %}
{{ _('FAQ') }} - FP Central
{% endblock %}
{% block content %}
FAQ
{{ _('What is the current list of collected attributes?') }}
#
{{ _('Name') }}
{{ _('Description') }}
{{ _('URL') }}
{% set count = 1 %}
{% for def in definitions %}
{{ count }}
{{ def.name }}
{{ def.description }}
{% if def.URL is defined %}
{% endif %}
{% set count = count + 1 %}
{% endfor %}
{{ _('I\'m interested in studying X but it is not present in the test suite. What can I do?') }}
{{ _('You can open an issue on GitHub HERE telling
us you want that attribute to be added and why. You can also directly send us a Pull Request with the right code by following the
imposed file format described HERE .
In both cases, the relevance of the attribute will be discussed before it is accepted. This step is needed to make sure that the test suite does not become too heavy
by having dozens of uninteresting attributes.') }}
{% endblock %}


Registered Traveller: faster entry through the UK border
2. Eligible passports
Asia
Brunei, Hong Kong (must be a Special Administrative Region passport), Japan, Malaysia, Singapore, South Korea, Taiwan (you must have a personal ID number on the photo page).
Australasia
Australia, New Zealand.
Middle East
Israel.
North America
Canada, Mexico, USA.
South and Central America
Argentina, Belize, Brazil, Chile, Costa Rica, El Salvador, Guatemala, Honduras, Nicaragua, Panama, Paraguay, Uruguay.


Doctors in Portland
Search by Keyword or Doctors name
Search Key Word
Search name
Search By Specialty
Search Doctors


Undocumented
Undocumented
- (instancetype)initWithPrimaryRGBColor:(SDLRGBColor *)primaryColor secondaryRGBColor:(SDLRGBColor *)secondaryColor backgroundRGBColor:(SDLRGBColor *)backgroundColor;
init(primaryRGBColor primaryColor: SDLRGBColor, secondaryRGBColor secondaryColor: SDLRGBColor, backgroundRGBColor backgroundColor: SDLRGBColor)
Undocumented
- (instancetype)initWithPrimaryColor:(UIColor *)primaryColor secondaryColor:(UIColor *)secondaryColor backgroundColor:(UIColor *)backgroundColor;
init(primaryColor: UIColor, secondaryColor: UIColor, backgroundColor: UIColor)
The primary
color. This must always be your primary brand color. If the OEM only uses one color, this will be the color. It is recommended to the OEMs that the primaryColor should change the mediaClockTimer
bar and the highlight color of soft buttons.
@property (readwrite, strong, nonatomic, nullable) SDLRGBColor *primaryColor;
var primaryColor: SDLRGBColor? { get set }
The secondary
color. This may be an accent or complimentary color to your primary brand color. If the OEM uses this color, they must also use the primary color. It is recommended to the OEMs that the secondaryColor should change the background color of buttons, such as soft buttons.
@property (readwrite, strong, nonatomic, nullable) SDLRGBColor *secondaryColor;
var secondaryColor: SDLRGBColor? { get set }
The background color to be used on the template. If the OEM does not support this parameter, assume on dayColorScheme
that this will be a light color, and on nightColorScheme
a dark color. You should do the same for your custom schemes.
@property (readwrite, strong, nonatomic, nullable) SDLRGBColor *backgroundColor;
var backgroundColor: SDLRGBColor? { get set }


I have to be honest, this did not make sense at all to me for the longest time. I saw this diagram dozens of times and never took anything away from it.
I just saw a bunch of boxes that didn't translate into anything I could actually write in CSS. It took a lot of trail and error for me to really see any difference in the four terms. But, after some work I see that it can be broken down really simply.
Content: That name gives this one away a little bit, but the content is the actual substance (maybe text or an image) that you are working with.
Padding: Padding is the space between the content and the border. So, larger you make the padding, the more white space there will be around your content. It is written like this --> whatever { padding: 20px; }
Border: This is probably the part most people will understand first. The border is just what it sounds like... a border around the content and padding. You can adjust the width and color of the border like this --> whatever{ border: 2px solid black; } This border would have a black border that is 2px wide.
Margin: The final piece of this diagram is the margin. The margin is used to position everything within your border on your page. Increasing margin-left for example with move your box to the right. That would be written like this --> whatever { margin-left: 20px; }
I really hope that I explained that in a concise enough way. The whole box layout can be confusing at first, but after a little work it really clears up.


A web platform where farmers can easy rent-out their Tractors & Implements which they don’t need and rent-in what they want to use from nearby farmers.
Fagrimacs is a digital platform enable farmers to easy rent-out and rent-in their tractor and farming equipment from nearby farmer.
The platform ensures fast and easily availability of tractor or implements and on-time farming solution such as soil cultivation, planting, fertilizing & pest control, Drainage & Irrigation, loading, harvesting & post-harvesting and Hay making.
“Our goal is to send the hand hoe to the museum and liberate the African farmer from the backbreaking drudgery of tilling the land by hand.”
-Dr. Nkosazana Dlamini Zuma, Chairperson – African Union Commission (2012 – 2017)


THE BACHELOR A film review by Steve Rhodes Copyright 1999 Steve Rhodes RATING (0 TO ****): ** 1/2
"My mustang days were about to become a distant memory," the soon to-be-ex-bachelor Jimmie Shannon (Chris O'Donnell) laments. "Goodbye sweet grasses." A bachelor suffering from mustang metaphor obsession, Jimmie sees his life dating one girl after another as being like a wild mustang who is free to sample all of the grasses on the open range.
In Gary Sinyor's THE BACHELOR, Jimmie reluctantly decides it's time to leave "Bachelorsville" for the town of "Marriedsville," so he arranges, along with dozens of other men in a similar situation, to pop the question to his intended at one of the fanciest restaurants in town.
After rambling incoherently, Jimmie finishes his proposal of sorts with, "The upshot is: You win!" Not exactly overwhelmed, his disbelieving girlfriend, Anne (Renée Zellweger), glares at him with an incredulous look. "That's it?" she asks. "'You win!' is a proposal?"
The delightfully cute Zellweger represents everything that is right about THE BACHELOR. She acts adorable, and with her long, curly blonde hair and rosy cheeks, she looks like the catch of the century. The filmmakers ask her to carry the entire burden of the romantic portion of this romantic comedy, which is hard. One person does not a romance make.
In contrast, the incredibly bland O'Donnell shows what's wrong with the movie. Never credible as a romantic figure in the story, he is required to setup the comedy parts. "What you think?" one woman ridicules Jimmie late in the picture.  And therein lies the problem, he isn't. The movie, which features too much O'Donnell and not enough Zellweger, places its bet heavily on the comedic side of the romantic comedy equation. The result is a story that definitely has its moments but overall just fizzles.
Most of the movie concerns Jimmie's frantic search for another bride. Soon after he botches his proposal to Anne (he really sticks his foot in his mouth in an unprintable line after the "you win" disaster), his grandfather dies. In his will he leaves $100,000,000 to Jimmie but only under certain conditions -- the prime one being that he gets married the next day. In order to prove that it isn't just some sham marriage, he must stay hitched for 10 years, never leave his wife for more than one day a month and produce "genetically verifiable offspring" within 5 years.
Needless to say, Jimmie will mess up the proposals to his ex-girlfriends almost as badly as he did with his one to Anne, whom he still loves. Think you can guess the ending?
Steve Cohen's screenplay is based on Buster Keaton's silent classic SEVEN CHANCES from 1925. Besides a few quite humorous scenes, the script for THE BACHELOR has one nice serious one. James Cromwell, as a grim reaper of a priest, who turns out to have a heart of gold, explains to Jimmie his philosophy about marriage. "It's a great thing when you grow old to have someone look in your face and see what you think you look like," the priest says in the movie's only truly insightful scene.
THE BACHELOR is hard to characterize. If it's a comedy, then there just aren't enough laughs. If it's supposed to be a romance, then they should have cast someone who could have created some genuine chemistry with Zellweger. A sporadically enjoyable movie, it leaves you wishing Zellweger had been given a lot more screen time. And that they had cast a different male lead.
THE BACHELOR runs 1:40. It is rated PG-13 for language and would be fine for kids about 9 and up.
The film opens nationwide in the United States on Friday, November 5. In the San Jose area it will be playing at the AMC and Century theaters.
Email<EMAIL_ADDRESS>Web: http://www.InternetReviews.com
The review above was posted to the
rec.arts.movies.reviews newsgroup (de.rec.film.kritiken for German reviews).
The Internet Movie Database accepts no responsibility for the contents of the
review and has no editorial control. Unless stated otherwise, the copyright
belongs to the author.
Please direct comments/criticisms of the review to relevant newsgroups.
Broken URLs inthe reviews are the responsibility of the author.
The formatting of the review is likely to differ from the original due
to ASCII to HTML conversion.
Related links: index of all rec.arts.movies.reviews reviews


Budget Savers
Home
Budget
Calendar
SET BUDGETS
Entertainment
Amount Spent:
500
Budget Total:
1000
0
Travel
Amount Spent:
500
Budget Total:
1000
0
Food
Amount Spent:
500
Budget Total:
1000
0
Home
Amount Spent:
500
Budget Total:
1000
0
Car
Amount Spent:
500
Budget Total:
1000
0
Set Budgets
Budget for Food:
Budget for Travel:
Budget for Home:
Budget for Car:
Budget for Entertainment:
Submit
Cancel


108_kkspeed3.py
import math
def nCr(n,r):
f = math.factorial
return f(n) / f(r) / f(n-r)
class Solution:
def getProbability(self, balls: List[int]) -> float:
solutions = [0]
good_solutions = [0]
def isGood(balls, leftBalls):
rightBalls = [balls[i] - leftBalls[i] for i in range(len(balls))]
return len([x for x in leftBalls if x != 0]) == len([x for x in rightBalls if x != 0])
def dfs(i, balls, leftBalls, solutions, good_solutions):
if i >= len(balls):
if sum(leftBalls) == sum(balls) // 2:
this_division = 1
for i in range(len(leftBalls)):
this_division *= nCr(balls[i], leftBalls[i])
solutions[0] += this_division
good_solutions[0] += this_division if isGood(balls, leftBalls) else 0
return
for k in range(0, balls[i] + 1):
dfs(i + 1, balls, leftBalls + [k], solutions, good_solutions)
dfs(0, balls, [], solutions, good_solutions)
return good_solutions[0] / solutions[0]


class: center, middle ## Online machine learning with creme ### Max Halford #### 11th of May 2019, Amsterdam
??? Hello! --- ### Outline .bullets[ 1. You're not doing ML the correct way 2. Cool kids do online learning 3. Introducing `creme`, the fresh kid on the block 4. Forecasting League of Legends match durations 5. Future work ]
??? My goal is to convince you that the way most people do machine learning isn't the way to go in production scenarios. Online learning is more suitable and nullifies many issues. I'll introduce a new library me and some friends have been working on, and I'll show you we're using for a pet project trying to forecast the duration of League of Legends matches. --- ### Batch learning .bullets[ 1. Collect features $X$ and labels $Y$ 2. Train a model on $(X, Y)$ 3. Save the model somewhere 4. Load the model to make predictions ] With code: ```python >>> model.fit(X_train, y_train) >>> dump(model, 'model.json') >>> model = load('model.json') >>> y_pred = model.predict(X_test) ``` ??? The most common form of machine learning is called batch learning. It's what you do when you use scikit-learn and do Kaggle competitions. I won't dwell on this too long as I'm pretty sure you're all acquainted with it. In short: load, fit, predict. --- class: center, middle ### Batch machine learning in production
??? There isn't a clear pattern as to how to put into production a batch learning system. Typically this involves training a model periodically, and then serializing it before saving it somewhere. API calls can then be issues to make predictions. This is such a difficult thing to get right that startups and tech giants are building products around it. --- class: center, middle ### Batch machine learning in production is hard
??? Works fine for Kaggle cases and when you have a clear split between train and test.  This is more subtle. Sometimes it isn't possible to recreate features for past instances. If you don't store information for an instance at every particular point in time, then it isn't possible to reproduce the true state during your feature extraction process. In other words you need a solid data engineering team that cares about time. --- class: center, middle
> It is, as far as he knows, the only way of coming downstairs, but sometimes he feels that there really is another way, if only he could stop bumping for a moment and think of it. ??? And just like Winnie the Pooh, we're spending too much time banging our heads to be able to think about a better way of doing things. --- background-color: #607bd4 class: middle, white ## Online learning .bigbullets[ - Data comes from a stream - Models learn 1 observation at a time - Observations do not have to be stored - Features and labels are dynamic ] --- background-color: #FF7F50 class: middle, white ## Different names, same thing .bigbullets[ - Online learning - Incremental learning - Sequential learning - Iterative learning - Out-of-core learning ] --- background-color: #008080 class: middle, white ## Applications .bigbullets[ - Time series forecasting - Spam filtering - Recommender systems - Ad placement - Internet of things - Basically,
anything event based
] --- class: center, middle ### Online learning in a nutshell
--- background-color: #e66868ff class: middle, white ## Why is batch learning so popular? .bigbullets[ - Taught at university - (Bad) habits - Hype - Kaggle - Library availability - Higher accuracy ] --- class: middle
.bullets[ - Python library for doing online learning - API heavily inspired from `sklearn` and easy to pick up - Focus on feature extraction, not just learning - First commit in January 2019 - Version `0.1.0` released earlier this week ] --- ### Observations Representing an observation with a `dict` is natural: ```python x = { 'date': dt.datetime(2019, 4, 22), 'price': 42.95, 'shop': 'Ikea' } ``` - Values can be of any type - Feature names can be used instead of array indexes - Python's standard library plays nicely with `dict`s --- ### Targets A target's type depends on the context: ```python # Regression y = 42 # Binary classification y = True # Multi-class classification y = 'setosa' # Multi-output regression y = { height: 29.7, width: 21 } ``` --- ### Streaming data ```python from creme import stream X_y = stream.iter_csv('some/csv/file.csv') for x, y in X_y: print(x, y) ``` - `X_y` is a **generator** and consumes a tiny amount of memory - The point is that we want to **handle data points one by one** - Source depends on your use case (can be Kakfa producer, CSV file, HTTP requests, etc.) --- ### Training with `fit_one` ```python from creme import linear_model from creme import stream X_y = stream.iter_csv('some/csv/file.csv') model = linear_model.LogisticRegression() for x, y in X_y: model.fit_one(x, y) ``` Every `creme` estimator has a `fit_one` method --- ### Predicting with `predict_one` ```python from creme import linear_model from creme import stream X_y = stream.iter_csv('some/csv/file.csv') model = linear_model.LogisticRegression() for x, y in X_y: * y_pred_before = model.predict_one(x) model.fit_one(x, y) * y_pred_after = model.predict_one(x) ``` - Classifiers also have a `predict_proba_one` method - Transformers have a `transform_one` method - Training and predicting phases are inter-leaved --- ### Monitoring performance ```python from creme import linear_model from creme import metrics from creme import stream X_y = stream.iter_csv('some/csv/file.csv') model = linear_model.LogisticRegression() * metric = metrics.Accuracy() for x, y in X_y: y_pred = model.predict_one(x) model.fit_one(x, y) * metric.update(y, y_pred) print(metric) ``` Validation score is available for free! No need to do any cross-validation. You can also use `online_score` from the `model_selection` module. --- ### Composing estimators is easy ```python from creme import linear_model from creme import metrics from creme import preprocessing from creme import stream X_y = stream.iter_csv('some/csv/file.csv') scale = preprocessing.StandardScaler() lin_reg = linear_model.LogisticRegression() * model = scale | lin_reg # Pipeline shorthand metric = metrics.Accuracy() for x, y in X_y: y_pred = model.predict_one(x) model.fit_one(x, y) metric.update(y, y_pred) print(metric) ``` --- ### `creme`'s current modules .left-column[ - `cluster` - `compat` - `compose` - `datasets` - `dummy` - `ensemble` - `feature_extraction` - `feature_selection` - `impute` - `linear_model` ] .right-column[ - `model_selection` - `multiclass` - `naive_bayes` - `optim` - `preprocessing` - `reco` - `stats` - `stream` - `tree` - `utils` ] --- ### Online mean For every incoming $x$, do: 1. $n = n + 1$ 2. $\mu\_{i+1} = \mu\_{i} + \frac{x - \mu\_{i}}{n}$ ```python >>> mean = creme.stats.Mean() >>> mean.update(5) >>> mean.get() 5 >>> mean.update(10) >>> mean.get() 7.5 ``` --- ### Online variance For every incoming $x$, do: 1. $n = n + 1$ 2. $\mu\_{i+1} = \mu\_{i} + \frac{x - \mu\_{i}}{n}$ 3. $s\_{i+1} = s\_i + (x - \mu\_{i}) \times (x - \mu\_{i+1})$ (running sum of squares) 4. $\sigma\_{i+1} = \frac{s\_{i+1}}{n}$ ```python >>> variance = creme.stats.Variance() >>> X = [2, 3, 4, 5] >>> for x in X: ... variance.update(x) >>> variance.get() 1.25 >>> numpy.var(X) 1.25 ``` ??? This is called Welford's algorithm, it can be extended to skew and kurtosis --- ### Standard scaling With the mean and the variance, we can scale incoming data so that it has zero mean and unit variance. ```python >>> scaler = creme.preprocessing.StandardScaler() >>> for x in [2, 3, 4, 5]: ... print(x, 'becomes', scaler.fit_one(x)['x']) 2 becomes 0.0 3 becomes 0.9999999999999996 4 becomes 1.224744871391589 5 becomes 1.3416407864998738 ```
--- ### Linear regression (1) Model is $y_t = \langle w_t x_t \rangle + b_t$. The weights $w_t$ can be learnt with any online gradient descent algorithm, for example: - Stochastic gradient descent (SGD) - Adam - RMSProp - Follow the Regularized Leader (FTRL) ```python from creme import linear_model from creme import optim lin_reg = linear_model.LinearRegression( optimizer=optim.Adam(lr=0.01) ) ``` --- ### Linear regression (2) The intercept term $b_t$ is difficult to learn Some people (Léon Bottou, scikit-learn) suggest to use a lower learning rate for the intercept than for the weights (heuristic but okay) `creme` uses any running statistic from the `creme.stats` module, which is a powerful trick ```python from creme import linear_model from creme import optim from creme import stats lin_reg = linear_model.LinearRegression( optimizer=optim.Adam(lr=0.01), intercept=stats.RollingMean(42) ) ``` --- ### Online aggregations ```python >>> import creme >>> X = [ ... {'place': 'Taco Bell', 'revenue': 42}, ... {'place': 'Burger King', 'revenue': 16}, ... {'place': 'Burger King', 'revenue': 24}, ... {'place': 'Taco Bell', 'revenue': 58} ... ] >>> agg = creme.feature_extraction.Agg( ... on='revenue', ... by='place', ... how=creme.stats.Mean() ... ) >>> for x in X: ... print(agg.fit_one(x).transform_one(x)) {'revenue_mean_by_place': 42.0} {'revenue_mean_by_place': 16.0} {'revenue_mean_by_place': 20.0} {'revenue_mean_by_place': 50.0} ``` --- ### Bagging (1) Bagging is a popular and simple ensemble algorithm: 1. Pick $m$ base models (usually identical copies) 2. Train each model on a sample with replacement 3. Average the predictions of each model on the test set Each observation is sampled $K$ times where $K$ follows a binomial distribution: $$P(K=k) = {n \choose k} \times (\frac{1}{n})^k \times (1 - \frac{1}{n})^{n-k}$$ As $n$ grows towards infinity, $K$ can be approximated by a Poisson(1): $$P(K=k) \sim \frac{e^{-1}}{k!} $$ --- ### Bagging (2) `ensemble.BaggingClassifier` is very simple: ```python def fit_one(self, x, y): for estimator in self.estimators: for _ in range(self.rng.poisson(1)): estimator.fit_one(x, y) return self def predict_proba_one(self, x): y_pred = statistics.mean( estimator.predict_proba_one(x)[True] for estimator in self.estimators ) return { True: y_pred, False: 1 - y_pred } ``` --- ### League of Legends match duration forecasting (1)
--- ### League of Legends match duration forecasting (2)
--- ### Architecture
--- class: middle ### Django model ```python from django.db import models from picklefield.fields import PickledObjectField class CremeModel(models.Model): name = models.TextField(unique=True) pipeline = PickledObjectField() class Meta: db_table = 't_models' verbose_name_plural = 'models' def fit_one(self, x, y): self.pipeline.fit_one(x, y) return self def predict_one(self, x): return self.pipeline.predict_one(x) ``` --- class: middle ### Code for predicting ```python match = fetch_match(match_id) model = models.CremeModel.objects.get(name='My awesome model') duration = model.predict_one(match.raw_info) match.predicted_ended_at = match.started_at + predicted_duration match.predicted_by = model match.save() ``` --- class: middle ### Code for training When the match ends, it has a `true_duration` property. ```python model = models.CremeModel.objects.get(id=match.predicted_by.id) model.fit_one( x=match.raw_info, y=match.true_duration.seconds ) model.save() ``` --- class: middle ### Code for calculating performance Just some Django black magic. ```python duration = ExpressionWrapper( Func(F('predicted_ended_at') - F('ended_at'), function='ABS'), output_field=fields.DurationField() ) agg = models.Match.objects.exclude(ended_at__isnull=True)\ .annotate(duration=duration)\ .aggregate(Avg('duration')) avg_error = agg['duration__avg'] ``` --- ### Benefits of online learning .bullets[ - No need to schedule model training - Easy to debug and to monitor - You're not "far" from production - Way more fun than batch learning ]
--- ### Future work .left-column[ .bullets[ - Decision trees (nearly there!) - Gradient boosting - Bayesian linear models - More feature extraction - More models - More benchmarks - Many issues [on GitHub](https://github.com/creme-ml/creme/issues) ] ] .right-column[
] --- ### If you want to contribute - [creme-ml.github.io](https://creme-ml.github.io/) - [github.com/creme-ml](https://github.com/creme-ml/) - You can shoot emails to [maxhalford25<EMAIL_ADDRESS>- Get in contact if you want to try `creme` and want advice - Spread the word!
--- class: center, middle # Thanks for listening! .left-column[
] .right-column[
]


Profile picture
{{ house.family_name }} Account
User: {{ house.user }}
Neighborhood: {{ house.user.username }}
Family Name: {{ house.family_name }}
Join Date: {{ house.join_date }}
Address: {{ house.address }}
Return{% load staticfiles %}
Profile picture
User: {{ house.user }}
Neighborhood: {{ house.user.username }}
Family Name: {{ house.family_name }}
Join Date: {{ house.join_date }}
Address: {{ house.address }}
Return


--- layout: post title: Shooting storyboard date: '2015-07-04T18:30:37+02:00' categories: - Storyboards picture_url: https://film-Storyboards.tumblr.com/post/123237398076 ---


--- layout: archive title: Zulip Chat Archive permalink: /stream/116395-maths/topic/foundations.20of.20mathematics.html ---
I spent some time over the last couple of days learning about Voevodsky's work in type theory. I found this paper https://arxiv.org/abs/1711.01477 by Dan Grayson quite illuminating.
quite high
It seems to me that univalent foundations is similar to, but not the same as, DTT
a = b
is not a Prop in univalent foundations
In fact there seems to me to be no impredicative Prop universe in univalent foundations
What happened to your project of documenting what's in mathlib?
there are just some universes, and a Prop is basically defined to be a subsingleton
But the claim is the same as in Lean -- "we can use this set-up as a way of doing all of maths"
kenny would love hott
kenny would love hott
nope
One major weakness (possibly only temporary) is that the model you're supposed to carry around is that a type can be thought of as a topological space
but apparently they can't construct the n-sphere from the axioms
so they add n-spheres as new inductive types
and then they can't prove the theory is consistent
This does not bode well, as far as I can see.
kenny would love hott
nope
are you a fair-weather constructivist
I also re-watched Voevodsky's Newton Institute talk from last yeat
year
abuse of topology
and his discussion about how he tried to persuade Suslin to re-prove some theorem of his constructively
because Voevodsky wanted to prove an old theorem of Voevodsky constructively in this univalent foundations way
but my impression was that Suslin had no interest in the question (perhaps unsurprisingly, as I know essentially 0 mathematicians who care about constructive maths)
1
and it seemed that Voevodsky was losing interest in the whole project of checking the proof anyway (or perhaps he was stuck)
Alessio Corto
Alessio Corti
sure
To me it settles the question: HoTT is constructive ⇒ I don't care
I think Voevodsky is something else
I think HoTT might be a third thing
I'm not sure though
Is Univalent Foundations = HoTT? I'm not so sure
More precisely: it's constructive ⇒ I think it's irrelevant to most mathematics
I completely agree.
So here are some questions.
We know that Lean will allow classical logic, and to be quite frank if it didn't allow it then I definitely would not be here.
I should say Lean 3, because at some point one has to talk about what Lean 2 was
Univalent Foundations seems to have been implemented in Coq, but there are lots of rules about commands in Coq which you are _not allowed to use_ in Univalent Foundations
e.g. you are not allowed to make new inductive types
you have to stick to the ones they made in the core files
But I should get to the point.
If I am interested in mathematics, done in classical logic
then what are my options for doing this in type theory?
DTT I know, because Lean 3
HoTT?
Univalent Foundations?
Voevodsky is high
And if there is more than one option, why should I choose Lean 3?
that settles it
Voevodsky is dead :-(
oh rip
there are very few popular dtt languages; you've already listed two, coq and lean, and there is also agda and idris
i think ats might also be based on dtt
basically the only other contender is not based on dtt at all, which is isabelle
how is she doing
It is worth noting that both Agda and Idris are primarily programming languages. Unlike Lean and Coq.
isabelle is quite popular amongst mathematicians
because it ain't constructive?
because they press Sledgehammer butan'
What are Isabelle's foundations?
Isabelle is a metalanguage, you can instantiate it with whatever you feel like. Isabelle/HOL is the most popular.
i know little of isabelle. but my impression is most people work in set theory
This is what Hales used for Kepler, right?
one should make a proof-assistant based on ZFC
As in ZF(C)? Mmm, I've always thought it's mostly just HOL.
that's already been done 30 years ago
who?
Apparently proof assistants based on ZFC are hard to use
I think Mario told me this
the original big one was called mizar
Apparently proof assistants based on ZFC are hard to use
another reason why ZFC is BS
I believe Isabelle/ZFC is also a thing.
i recall sebastian gouzel was also slightly annoyed with isabelle
something about it being impossible to define the adeles
(whatever they may be)(
What do you mean by impossible?
Kenny is supposed to be defining the adeles in Lean
once he's finished revising his mechanics
discussion of the adeles is beyond my pay grade
@Andrew Ashworth:
i think ats might also be based on dtt
There is certainly no obstruction to defining the adeles in Lean
There is once you don't have dependent types (a'la Isabelle).
yes, iirc he said that was a major draw for him to work in dtt
discussion of the adeles is beyond my pay grade
it isn't quite hard to understand if you start simple, i.e. start with Q
https://gitter.im/leanprover_public/Lobby?at=5a2daedfffa3e379191e9195
Kenny, the adeles of a general number field K are just (adeles of Q) tensor_Q K
and because you did tensor product
you can do adeles for a general number field
wonderful
The adeles are an easy exercise given what we have
isabelle and coq currently have ::quite:: an advantage in library size
quite
leaving aside isabelle, why would you use lean over coq? mostly for nicer unicode syntax
But we seem to have a proof that isabelle is not suitable for all of mathematics?
Lean > Coq -- because tactics
however if you wanted to jump straight into doing research mathematics, you can't in lean because mathlib is far smaller than its coq competitors
far smaller than it is coq competitors
and I think that nicer unicode syntax, whilst this might just be superficial for CS people, will I think be important to undergraduate mathematicians
Coq > Lean because of existing tactics. Lean > Coq because of the way you write tactics.
But I am playing the long game
So I choose Lean. However this thread was basically my attempt to review this choice.
If you're playing the very long game, it might still be the case Coq > Lean, Ltac2 is coming.
If I can understand the claim that "Isabelle can't do the adeles" then we can cross Isabelle off the list
But what about HoTT?
And what about UniMath?
hott is not ready for anything, it is a subject of research
And this does not apply to DTT
because Coq
let's do things over NBG
or just second order peano arithmetic
The original univalence axiom is not constructive. There's cubical type theory extension thereof tho: https://arxiv.org/abs/1611.02108
dtt without any funny additions has been proven sound
sound!
sound in what?
as in you can do useful things with it and not summon false from anywhere
how do you even define sound
by "proven sound" you mean "relative to ZFC + existence of infinitely many inaccessible cardinals" right?
@Kenny Lau Funny you should say that. My table currently contains "Subsystems of second order arithmetic".
You can't prove that anything is sound, in some sense
exactly
without assuming consistency of some less-likely-to-be-sound system
forget about the reals
just do peano arithmetic
and then embed ZFC within
and then Goedel encode everything.
and then you can do the reals
i think for undergraduates who are not trying to do research mathematics, lean is nicer for reading and writing tactics (though i doubt they will get around to writing tactics)
Actually, Coq has much nicer tactic-description syntax still.
coq is the winner if you're trying to make something that will be around for years
it has been around for decades
feit thompson e.g.
You can pattern match on goals themselves for example. There's no obscure monad with arbitrary pexpr
transforming functions.
i think writing tactics is beyond most mathematician's interest
realistically speaking
Realistically speaking, using Lean is beyond most mathematician's interest :P.
also true
i think this has a sadder part though
using Lean is beyond most CS peoeple interest as well
well, most cs majors would rather have a tooth pulled than work with something that reminds them of their undergraduate discrete math course
most people studying CS want to be "programmers", there's no clear distinction between CS and software engineering in academia, for worse or worse
I agree about tactics. For now.
But I am going to make mathematicians interested in Lean.
if you split the two cleanly then academic CS may as well be in the math department along with the statisticians
and logicians
But I am going to make mathematicians interested in Lean.
Then we need more documentation, for instance your old project of describing mathlib
oh yeah sorry Patrick I didn't respond to your earlier question
I am still trying to figure out all the finite stuff
but multiset.lean is so long
My blog post about induction was just some consequence of me trying to understand finite stuff
For mathematicians, finite sets are so important and foundational
and I found them very hard to do in DTT
but I am slowly getting on top of them
@Andrew Ashworth well we then need to communicate better what to expect in a CS course at least... it is as you said, tooth extraction wins over discrete math for many students I teach...
My middle child is a budding CS student and he was moaning about discrete maths only 2 days ago
surely he knows better than to moan about maths to you, haha
:-)
I know I'm always writing the same thing, but did you read that Coq bigoperator paper?
I was reading it yesterday
I learnt some stuff
For example I didn't really know how to prove that sum from 0 to n of f(i) equalled sum from 0 to n of f(n-i)
but I can now see a nice way of doing it using bigoperators
Discrete math was one of my favorite undergrad courses.
I teach Java to students that had compulsory discrete math one semester prior.  :-\
In summary then, apparently HoTT isn't ready, UniMath I am still unsure about, Isabelle has problems with adeles, Mizar didn't catch on for some reason, so there's only DTT left?
And if it turns out that Coq > Lean then I just switch to Coq
that is a bonus. if lean ever dies everything you've learnt moves easily over to coq
Can I write a regular expression which turns all my Lean proofs into Coq proofs?
that's a little ambitious :)
Oh Ok
I don't know what you CS guys can do
I don't think it's a completely ridiculous idea.
i mean, it's theoretically possible to write a transpiler. but who would do the work?
Lean advantages over Coq are not only about unicode. You also get better overall ergonomics.
And much better documentation
How is less constructive stuff a good thing?!
It's a good thing for mathematics, not for everything
well.. lean, instead of having less constructive stuff, just has _less_ stuff :)
From what I understand, in Coq you need to spend more energy fighting constructivism
In Dan Grayson's article he argues that constructive maths is better than normal maths because constructive maths is a generalisation of normal maths
I was like "..."
I should tell all the group theorists I know to move into monoid theory
Exactly what I was about to write
let's all do monoids!
actually let's just do set theory
who cares about structure
we have the classification theorem already
each one bijects with a unique cardinal
so off we go
this is surprisingly reminiscent of static vs dynamic typing discussion
also, unimath is basically hott
unimath is dtt + univalence
What is this documentation comment Patrick?
and then a bunch of mathematics
I thought Coq had some big chunky tomes
like, actual math, like i recall seeing a construction of the reals using dedekind cuts
so unimath is basically mathlib + univalence
equality is not a prop in unimath
apparently
equality in unimath seems more like \equiv in Lean
if i knew more homotopy theory i'd feel more eager to say things about hott :)
What is this documentation comment Patrick?
Coq has no documentation targeting mathematicians. TPIL is written for us, and beats anything I've seen about Coq by a very wide margin.
yes, the big three textbooks for coq are: software foundations, certified programming with dependent types, and coq'art. ssreflect also has a good manual here. notice all but the last is focused towards programmers...
SSReflect manual is clearly going in the right direction compared to the other three, but it's still much harder to read that TPIL (I tried reading it before switching to Lean).
I thought that Coq also had some useful introductory tutorials. But I agree with Patrick that TPIL is a very good read for mathematicians.
Patrick -- I was going to write something else for mathematicians, where I enter tactic mode on page 1 and basically never leave, and also on page 1 I do mathematics rather than goofing around with logic, doing basic mathematical proofs of familiar statements like stuff involving congruences right from square 1. I show them the tactics they need and we go from there.
I still think that term mode is too hard for mathematicians. You clearly have a programming background. I am guessing that you were happy with lambda notation for functions before you started reading these docs.
I would like to suppress lambda notation for as long as possible.
I agree wholeheartedly with all those goals
OK! Thanks for your opinion, I genuinely value it.
We are both in the same sort of boat, trying to read books written for computer scientists with in some sense an "amateur" background (with me rather more amateurish than you when it comes to computing) but I really want to appeal to people who know no CS at all.
Back to the point -- does anyone here know if one can do classical mathematics in UniMath?
I think so. https://github.com/HoTT/HoTT/issues/299
speaking of, i linked this a long time ago, but here you can see a comparison of the most popular proof languages
http://www.cs.ru.nl/~freek/100/
yes, the big three textbooks for coq are: software foundations, certified programming with dependent types, and coq'art. ssreflect also has a good manual here. notice all but the last is focused towards programmers...
I think that suggests @Patrick Massot has the right idea: if you want documentation for mathematicians, we need actual mathematicians to do it.
I don't if you count Avigad as mathematician but TPIL comes very close to what we want. You only to unemphasize term mode and put more math examples.
Right. What I meant is that building a theorem prover is something done by programmers so it kind of colors what they'll use the prover for in the documentation.
That's the curious difference between a prover and an accounting software. In accounting software, you do it for / with accountants / people who want to do accounting. With a prover, I have a feeling you start one when you need a prover that does stuff that the other provers don't do. You're kind of the first user of the prover so you assume the other users will want the prover for the same reason. Not that I built a prover with more than 1.5 users but ...
I don't if you count Avigad as mathematician but TPIL comes very close to what we want. You only to unemphasize term mode and put more math examples.
term mode is not the enemy! i feel like if one wants to get anything done, you'll end up needing to know both modes
personally my favorite code style for math is the isabelle style, as seen https://github.com/sgouezel/mathlib/blob/d4836822a625677b9f292e26fcafb4870bbf9f91/order/conditionally_complete_lattice.lean
Term mode is not the enemy. But for a mathematician there are many things which you have to learn in order to work this sort of language, and term mode is somehow one of the more obscure things. Let's give them time to wrestle with how to steer this thing whilst they're proving that the square root of 2 is irrational, or whatever, in tactic mode, before telling them that lambda is no longer supposed to mean a real number.
if logic and proof (jeremy's other textbook) was fully worked out in lean 3, is that something you'd be looking for?
That's less Lean and less tactic mode!
I didn't write "completely remove term mode" but "unemphasize" (I don't know if this word exists but I hope what I mean is clear)
ah, true. only 50% of logic and proof is lean
I know exactly what I want, and I'm going to write it myself using Jeremy's cool org mode solution for generating books
I'd be happy to help in any way
very awesome, i think everyone here would love to peek at it as you write it
at least i would, i read all your blog posts, hah
@Kevin Buzzard I think he moved from org-mode to Restructured Text, didn't he?
In some sense the main question I have for Patrick is how to write a book which has maths like and lean stuff like this
all coloured in correctly.
Simon I was basing my org claim on this
https://github.com/leanprover/mkleanbook
and the fact that the files were called blah.org
This is not how TPIL is currently produced
You must be right
do you know how it's currently done?
Sphinx
https://github.com/leanprover/theorem_proving_in_lean
scroll down to README
that said, there is nothing wrong with mkleanbook, the issue was other people didn't want to use emacs
what about getting things ?
(although perhaps not regular sentences, they can stay in non maths mode)
Do you mean that you would format Lean code in math mode? I'd really like to see that
I mean I want to write maths and Lean code (at different times)
Ideally the maths I write would look as good as LaTeX and the Lean would be coloured in correctly
Ah ok! I think the setup they have for Lean documents should allow that
I'm soon going to give Pandoc a try. I heard good things about it and it looks easier to set up than Sphinx
Ideally, I'd like to get to a point where I don't have to switch between writing and checking Lean and writing and checking documentation.
One major weakness (possibly only temporary) is that the model you're supposed to carry around is that a type can be thought of as a topological space
but apparently they can't construct the n-sphere from the axioms
so they add n-spheres as new inductive types
and then they can't prove the theory is consistent
This does not bode well, as far as I can see.
As far as I am aware, HoTT + all the HITs people care about, including S^n and quotients and things, is known consistent because of the existence of simplicial set models and such. The unknown consistency claim here may be particular to Univalent Foundations, I'm not sure.
Is Univalent Foundations = HoTT? I'm not so sure
I think Univalent Foundations = HoTT + Propositional resizing, which means that everything you can prove is a proposition lives in the lowest universe. This is similar to Lean's Prop
universe, but in Lean you can't prove that something lives in Prop
, it either is or isn't by virtue of the form of the expression. Regular HoTT does not have this resizing rule, so there are "more propositions" in higher universes, which talk about correspondingly large objects.
If I am interested in mathematics, done in classical logic
then what are my options for doing this in type theory?
I think this is the wrong question. You can do mathematics in just about any system above a certain minimum threshold of complexity, which is somewhere around second order PA. It just gets less convenient as you remove features
I believe Isabelle/ZFC is also a thing.
Pretty much all Isabelle work is done in Isabelle/HOL. Metamath is similar in that it is a general framework which allows you to define DTT, HOL, ZFC, PA or anything else, but 99% of the actual theorem proving work has gone into the ZFC database.
Apparently proof assistants based on ZFC are hard to use
I think Mario told me this
I'm not 100% clear on this, because I hear conflicting messages, but this is the usual line:
If you're playing the very long game, it might still be the case Coq > Lean, Ltac2 is coming.
If you are playing a sufficiently long game, the best bet doesn't exist yet
dtt without any funny additions has been proven sound
DTT with inductive types, quotients and proof irrelevance is also sound, courtesy of yours truly
I am still trying to figure out all the finite stuff
but multiset.lean is so long
You don't need to read multiset.lean that carefully. The easy version is: it's lists up to permutation, with all the list functions lifted to multiset. All the lemmas are exactly what you would expect, given the definitions.
i mean, it's theoretically possible to write a transpiler. but who would do the work?
I would, if I understood Coq's metatheory as well as I do Lean's. Since they were not nearly so careful with their kernel as Lean has been, I don't know if I will find the acceptable Gallina terms written up anywhere that isn't an approximation or out of date
equality in unimath seems more like \equiv in Lean
This is exactly the right idea. However, there is something you really need to pay attention to which I think you have missed and are using to get a "free lunch" in your conception of HoTT: equality (the type constructor) is not the same as definitional equality. In Lean this isn't that big a deal because of proof irrelevance, but you absolutely cannot hold the view that one thing is as good as an equal thing when doing HoTT. In particular, it will not save you from your "up to equivalence" problems in the other thread, but I will discuss this more there.
I still think that term mode is too hard for mathematicians. You clearly have a programming background. I am guessing that you were happy with lambda notation for functions before you started reading these docs.
I would like to suppress lambda notation for as long as possible.
I don't think this is a good idea. The idea of a lambda itself, a function giving a result, is quite integral to mathematics and it's a surprise they haven't picked up the notation already (or something isomorphic, like x \in A |-> b(x)
).
If you want to write a tactic-centric lean tutorial, I would suggest to begin with a brief overview of the terms of the language, i.e. lambda, application, constants and variables, make sure they understand what a bound variable is, then move on with some statement along the lines "writing these terms directly is cumbersome, so here's a language for quickly constructing terms that is designed more for ease of use". You don't need to mention the Isar-inspired terms like match
and have
and show
until later if you want, but the core type theory should be at least briefly described.
It is a good point that mathematicians know perfectly well about lambdas, they just write them $x \mapsto f(x)$.
{% endraw %}Last updated: Apr 24 2020 at 19:02 UTC


Text can be bold, italic, or strikethrough. Links should be blue with no underlines (unless hovered over).
There should be no margin above this first sentence.
Header 1
This is a normal paragraph following a header.  Chuck kielbasa leberkas, pork bresaola ham hock filet mignon cow shoulder short ribs biltong.
Header 2
This is a blockquote following a header.  Chuck kielbasa leberkas, pork bresaola ham hock filet mignon cow shoulder short ribs biltong.
Header 3
This is a code block following a header.
Header 4
- This is an unordered list following a header.
- This is an unordered list following a header.
- This is an unordered list following a header.
Header 5
- This is an ordered list following a header.
- This is an ordered list following a header.
- This is an ordered list following a header.
Header 6
| What | Follows |
|---|---|
| A table | A header |
| A table | A header |
| A table | A header |
There's a horizontal rule above and below this.
Here is an unordered list:
- Salt-n-Pepa
- Bel Biv DeVoe
- Kid 'N Play
And an ordered list:
- Michael Jackson
- Michael Bolton
- Michael Bublé
And an unordered task list:
- Create a sample markdown document
- Add task lists to it
- Take a vacation
And a "mixed" task list:
- Steal underpants
- ?
- Profit!
And a nested list:
- Jackson 5
- Michael
- Tito
- Jackie
- Marlon
- Jermaine
- TMNT
- Leonardo
- Michelangelo
- Donatello
- Raphael
Definition lists can be used with HTML syntax. Definition terms are bold and italic.
- Name
- Godzilla
- Born
- 1952
- Birthplace
- Japan
- Color
- Green
Tables should have bold headings and alternating shaded rows.
| Artist | Album | Year |
|---|---|---|
| Michael Jackson | Thriller | 1982 |
| Prince | Purple Rain | 1984 |
| Beastie Boys | License to Ill | 1986 |
If a table is too wide, it should condense down and/or scroll horizontally.
| Artist | Album | Year | Label | Awards | Songs |
|---|---|---|---|---|---|
| Michael Jackson | Thriller | 1982 | Epic Records | Grammy Award for Album of the Year, American Music Award for Favorite Pop/Rock Album, American Music Award for Favorite Soul/R&B Album, Brit Award for Best Selling Album, Grammy Award for Best Engineered Album, Non-Classical | Wanna Be Startin' Somethin', Baby Be Mine, The Girl Is Mine, Thriller, Beat It, Billie Jean, Human Nature, P.Y.T. (Pretty Young Thing), The Lady in My Life |
| Prince | Purple Rain | 1984 | Warner Brothers Records | Grammy Award for Best Score Soundtrack for Visual Media, American Music Award for Favorite Pop/Rock Album, American Music Award for Favorite Soul/R&B Album, Brit Award for Best Soundtrack/Cast Recording, Grammy Award for Best Rock Performance by a Duo or Group with Vocal | Let's Go Crazy, Take Me With U, The Beautiful Ones, Computer Blue, Darling Nikki, When Doves Cry, I Would Die 4 U, Baby I'm a Star, Purple Rain |
| Beastie Boys | License to Ill | 1986 | Mercury Records | noawardsbutthistablecelliswide | Rhymin & Stealin, The New Style, She's Crafty, Posse in Effect, Slow Ride, Girls, (You Gotta) Fight for Your Right, No Sleep Till Brooklyn, Paul Revere, Hold It Now, Hit It, Brass Monkey, Slow and Low, Time to Get Ill |
Code snippets like var foo = "bar";
can be shown inline.
Also, this should vertically align
with this
and this.
Code can also be shown in a block element.
var foo = "bar";
Code can also use syntax highlighting.
var foo = "bar";
Long, single-line code blocks should not wrap. They should horizontally scroll if they are too long. This line should be long enough to demonstrate this.
var foo = "The same thing is true for code with syntax highlighting. A single line of code should horizontally scroll if it is really long.";
Inline code inside table cells should still be distinguishable.
| Language | Code |
|---|---|
| Javascript | var foo = "bar"; |
| Ruby | foo = "bar" |
Small images should be shown at their actual size.
Large images should always scale down and fit in the content container.
This is the final element on the page and there should be no margin below this.


Related Topics:
Subscribing to a lot of RSS feeds can start to feel like Drinking from an RSS firehose. It doesn’t take long to build up a huge list of subsribed feeds. Fortunately, RSS Bandit provides rich searching capabilities.
RSS Bandit has two search facilities built in: web search and local search. Local Search searches the contents of all your downloaded items and returns the results within a folder underneath the folder named Search Folders in the Feed Subscriptions tree.
Clicking on the Search button in the toolbar (see Figure 1) will bring up the search window (see Figure 2). This is a collapsible window so it can be collapsed within RSS Bandit to provide more detail display screen area. The window contains a textbox for entering the search phrase, a button to initiate the search, and several search options within collapsible panes below.
Figure 1: Search
Button.
Figure 2: Docked
Search Window.
By default, entering text into the textbox and clicking Search will perform a simple text search within the Description, and Title (if posts does not provide content) elements of every RSS Item.
However, starting with Rss Bandit version 1.5.*, RSS Bandit now makes use of the DotLucene search engine, a direct port of the Apache Lucene engine for Java.
This gives you a powerful syntax for searching. For example, the fuzzy search
Figure 3: Example of a
fuzzy search.
Although I misspelled “
To learn more about the search query syntax, read the syntax docs.
Search Fields
Figure 4 shows the fields that are available for searching using checkboxes:
Figure 4: Search
Fields.
There are more searchable fields available. Read about them in Search Query Syntax section!
Advanced Fields
The Advanced Fields option shown in figure 5 provides several options for
tuning search results.
To enable an advanced option, click on the button beside the option name and the red bar will be converted to a green check mark.
Figure 5: Advanced
Fields.
Read Status - enabling this option allows you to filter posts by their read status. If you enable the Read Status option and check the Unread Posts checkbox only unread items will be returned in the search. If the checkbox is unchecked then only read posts are returned. When this feature is disabled, both read and unread posts are returned in search results.
You can not define a search with Read Status specified only for internal technical reasons! To get only unread items, please use the new special folder named Unread Items.
There are three mutually exclusive ways to filter search results based on the date of the items.
Search Folder Name
For more information on this option, check out the
topic Creating Search Folders.
Search Scope
The scope for a search can be narrowed to a selection of categories or even
individual feeds. Figure 8 shows the Search Scope option. It contains a tree
view with a checkbox next to each category and feed. By selecting and
unselecting feeds and categories, you can narrow or expand the scope of your
search.
Figure 6: Search
Scope.
Search Results
Once you’ve selected your results, click on Search to get your results. The search
results will be shown in the Feed Details section as well as the Reader Pane as
in Figure 7.
Figure 7: Search
Results.
Figure 7 shows the results of an ego search using the search term author:Haacked, which found all the posts in which the author’s name is Haacked.


I hope you enjoy it and if you have feedback feel free to shoot me an email
Created By: Eric Orellana


HPP (Humanoid Path Planner) is a collection of software packages implementing path planning functionalities for a humanoid robot. The core functionalities are well suited to solve classical path planning problems. It can be extended to path planning for other types of robots like digital actors for instance.
Installation instructions can be found on github.
The code relative to HPP is distributed into several software packages. See dependency graph for a quick view of the package hierarchy.
The packages are distributed into the following categories:
The algorithmic part, built on hpp-core is embedded in corba servers implemented by hpp-corbaserver or extensions like hpp-manipulation-corba. The corba servers are linked to executable From a python terminal, clients to the corba servers can be created in order to control the executable. The control of the application is performed via idl interfaces and python classes available in Corba interfaces. Results of path planning requests as well as individual configurations can be displayed in |
Package hpp_tutorial provides some examples of how to use this project.


Sops
Intro to sops This is just a very quick intro to sops an open sourced secrets management tool from mozilla. Sops can be used to transparently encrypt full, or partially config files, transparently in the sense that the keys in a yaml, json won’t be encrypted only the values, which allows to version control the file with git and more. To create an with your gpg key ‘encrypted’ file run:


Your job in this assignment is to write the classic arcade game of Breakout, which was invented by Steve Wozniak before he founded Apple with Steve Jobs (moment of silence). It is a large assignment, but entirely manageable as long as you break the problem up into pieces.
In Breakout, the initial configuration of the world appears as shown on the right. The colored rectangles in the top part of the screen are bricks, and the slightly larger rectangle at the bottom is the paddle. The paddle is in a fixed position in the vertical dimension, but moves back and forth across the screen along with the mouse until it reaches the edge of its space.
A complete game consists of three turns. On each turn, a ball is launched from the center of the window toward the bottom of the screen at a random angle. That ball bounces off the paddle and the walls of the world, in accordance with the physical principle generally expressed as "the angle of incidence equals the angle of reflection" (which turns out to be very easy to implement as discussed later in this handout). Thus, after two bounces--one off the paddle and one off the right wall--the ball might have the trajectory shown in the second diagram. (Note that the dotted line is there to show the ball's path and won't appear on the screen.)
As you can see from the second diagram, the ball is about to collide with one of the bricks on the bottom row. When that happens, the ball bounces just as it does on any other collision, but the brick disappears. The third diagram shows what the game looks like after that collision and after the player has moved the paddle to put it in line with the oncoming ball.
The play on a turn continues in this way until one of two conditions occurs:
Success in this assignment will depend on breaking up the problem into manageable pieces and getting each one working before you move on to the next. The next few sections describe a reasonable staged approach to the problem.
Before you start playing the game, you have to set up the various pieces. Thus, it probably makes sense to implement the run method as two method calls: one that sets up the game and one that plays it. An important part of the setup consists of creating the rows of bricks at the top of the game, which look like this:
The number, dimensions, and spacing of the bricks are specified using named constants in the starter file, as is the distance from the top of the window to the first line of bricks. The only value you need to compute is the x coordinate of the first column, which should be chosen so that the bricks are centered in the window, with the leftover space divided equally on the left and right sides. The color of the bricks remain constant for two rows and run in the following rainbow-like sequence: RED, ORANGE, YELLOW, GREEN, CYAN.
The next step is to create the paddle. There is only one paddle, which is a filled GRect. You even know its position relative to the bottom of the window.
The challenge in creating the paddle is to make it track the mouse. Here, however, you only have to pay attention to the x coordinate of the mouse because the y position of the paddle is fixed.
If you call the method (perhaps from run):
addMouseListeners();
And implement the method:
public void mouseMoved(MouseEvent e)
Then any time the mouse is moved the method mouseMoved will be executed.
At one level, creating the ball is easy, given that it's just a filled GOval. The interesting part lies in getting it to move and bounce appropriately. You are now past the "setup" phase and into the "play" phase of the game. To start, create a ball and put it in the center of the window. As you do so, keep in mind that the coordinates of the GOval do not specify the location of the center of the ball but rather its upper left corner.
The program needs to keep track of the velocity of the ball, which consists of two separate components, which you will presumably declare as instance variables like this:
private double vx, vy;
The velocity components represent the change in position that occurs on each time step. Initially, the ball should be heading downward, and you might try a starting velocity of +3.0 for vy (remember that y values in Java increase as you move down the screen). The game would be boring if every ball took the same course, so you should choose the vx component randomly. You should simply do the following:
Declare an instance variable rgen, which will serve as a random-number generator:
private RandomGenerator rgen = RandomGenerator.getInstance();
Once you've done that, your next challenge is to get the ball to bounce around the world, ignoring entirely the paddle and the bricks. To do so, you need to check to see if the coordinates of the ball have gone beyond the boundary, taking into account that the ball has a nonzero size. Thus, to see if the ball has bounced off the right wall, you need to see whether the coordinate of the right edge of the ball has become greater than the width of the window; the other three directions are treated similarly. For now, have the ball bounce off the bottom wall so that you can watch it make its path around the world.
Computing what happens after a bounce is extremely simple. If a ball bounces off the top or bottom wall, all you need to do is reverse the sign of vy. Symmetrically, bounces off the side walls simply reverse the sign of vx.
Now comes the interesting part. In order to make Breakout into a real game, you have to be able to tell whether the ball is colliding with another object in the window. As scientists often do, it helps to begin by making a simplifying assumption and then relaxing that assumption later. Suppose the ball were a single point rather than a circle. In that case, how could you tell whether it had collided with another object?
There is a method:
public GObject getElementAt(double x, double y)
The easiest thing to do, which is in fact typical of real computer games, is to check a few carefully chosen points on the outside of the ball and see whether any of those points has collided with anything. As soon as you find something at one of those points, you can declare that the ball has collided with that object.
In your implementation, check the four corner points on the square in which the ball is inscribed. Remember that a GOval is defined in terms of its bounding rectangle, so that if the upper left corner of the ball is at the point (x, y), the other corners will be at the locations shown in this diagram:
These points have the advantage of being outside the ball but nonetheless close enough to make it appear that collisions have occurred. Thus, for each of these four points, you need to:
It would be very useful to write this section of code as a separate method
public GObject getCollidingObject()
GObject collider = getCollidingObject();
From here, the only remaining thing you need to do is decide what to do when a collision occurs. There are only two possibilities. First, the object you get back might be the paddle, which you can test by checking
if (collider == paddle)
If it is the paddle, you need to bounce the ball so that it starts traveling up. If it isn't the paddle, the only other thing it might be is a brick, since those are the only other objects in the world. Once again, you need to cause a bounce in the vertical direction, but you also need to take the brick away. To do so, all you need to do is remove it from the screen by calling the remove method.
If you've gotten to here, you've done all the hard parts. There are, however, a few more details you could take into account if you have time.
If you have the basic play working well, then this would be a great opportunity to go above and beyond. Here are a few ideas of for possible extensions (of course, we encourage you to use your imagination to come up with other ideas as well):
The version that is running as an applet on the CS 106A assignment page plays a short bounce sound every time the ball collides with a brick or the paddle. This extension turns out to be very easy. The starter project contains an audio clip file called bounce.au that contains that sound. You can load the sound by writing
AudioClip bounceClip = MediaTools.loadAudioClip("bounce.au");
and later play it by calling
bounceClip.play();


John Doe
<EMAIL_ADDRESS>home
HOME
assignment_ind
STAFF LOGINS
collections
COLLECTION DETAILS
developer_board
SEGREGATION DETAILS
local_shipping
TRANSPORT DETAILS
delete_sweep
DISPOSAL DETAILS
account_circle
LOGOUT
menu
ADMINISTRATOR


This \o
will be a regular 'o' in this context.
# Want literal backslash
echo Yay \o/
# Want other characters
bell=\a
echo 'Yay \o/'
bell="$(printf '\a')"
You have escaped something that has no special meaning when escaped. The backslash will be simply be ignored.
If the backslash was supposed to be literal, single quote or escape it.
If you wanted it to expand to something, rewrite the expression to use printf
(or in bash, $'\t'
). If the sequence in question is \n
, \t
or \r
, you instead get a [[SC1012]] that describes this.
None. ShellCheck (as of 2017-07-03, commit 31bb02d6) will not warn when the first letter of a command is unnecessarily escaped, as this is frequently used to suppress aliases interactively.


Get Started by Adding a Destination to the Blue Community Ecosystem.
Learn about the Assessment Features Here.
Our holistic sustainability assessment focuses on a strategic matrix of inquiries regarding local sustainability efforts...learn more
Establish a baseline for your community by completing a series of questions, based on themes in sustainability.
All edits made to the destination data are time stamped and the change becomes attributed to the person making the change. This data is only viewable by the members belonging to the same team.learn more
Having the most current data is paramount to setting goals for your Blue Community. As the data becomes converted into graphs inside the Destination Dashboard
Help the community trust you by providing the transparency stakeholders seek. Along with providing reference links to claims made inside the ...learn more


This website allows you to analyse your Facebook Messenger data.
Your file is analysed by JavaScript that runs in the browser.
Your file is not sent to any server or stored anywhere; all the analysis is done locally on your computer. After the page loads you can disconnect from the internet, then select your file and it will still work!
If you want to have a look, the code that this page runs is available on GitHub here
Before you use the application, you need to download your Facebook Messenger data in '.json' format. If you don't know how to do this, click here.
Only Facebook Messenger data is supported at this stage. If you have issues, please ensure you have the latest version of your browser. This application will not work on Internet Explorer 11.
If you don't have it yet, I wrote this guide on how to get it.
Select a .json file from your downloaded messenger data.
When analysing at what time messages were sent during the day, group them by
When analysing messages from the whole conversation history, group them by
Select a file!
When the analysis is complete, data and plots will be here.
| Name | Messages Sent | Words Sent | Average Words/Message |
|---|
| Name | Text Messages | Photos | Videos | Stickers | GIFs | Files | Shared Links | Audio Files | Plans |
|---|
Want to see more interesting word frequency results? Try setting limits on the minimum and maximum word length.
Unfortunately due to limitations in the Google Charts API, I cannot put the emoji images in the labels of the graph. What you see below is the best compromise I could come up with.
| Rank | Emoji |
|---|


I just recently installed Windows 8 on my home computer. During the installation process, I was not asked to provide a product key. This led to me not being able to activate Windows after the installation process.
To resolve this, follow these steps:
cmd
Command Prompt
and select Run as Administrator
slmgr -upk
Windows+C
to bring up the Charms windowSettings
and click Change PC Settings
Activate Windows
tab will now ask you for your product keyOddly enough, I had trouble finding this info so I thought I’d share.