Part Number
Tool Serial Number
May
Raw denim you probably haven't heard of them jean shorts Austin. Nesciunt tofu stumptown aliqua butcher retro keffiyeh dreamcatcher synth.
May
Raw denim you probably haven't heard of them jean shorts Austin. Nesciunt tofu stumptown aliqua butcher retro keffiyeh dreamcatcher synth.


Enumerable Methods
October 12th, 2014
For this blog post I want to take a little bit closer look at the group_by method in Ruby.
In simplest terms, the group_by method breaks a collection into groups based on some given criteria. It expects to accept a bock that contains the criteria by which the items in the collection will be grouped. If no block is given, an enumerator is returned instead.
It returns a hash where each key represents a group. Each key’s corresponding value is an array containing the members of that group.
When called on an array, the group_by method loops through the array and creates a new hash specifying keys and values according to the block that is passed.
Let’s walk through the example found in the Ruby documentation:
(1..6).group_by {|i| i % 3}
=> {0 => [3,6], 1 => [1,4], 2 => [2,5]}
The example takes a range of numbers, 1 through 6, as its input. The group_by method iterates through each number in the range and calculates mod 3 for each number in the range. Mod returns the remainder. When you divide by 3, there are only 3 possible outcomes for the mod. They are 0, 1, and 2.
group_by creates a new hash with each possible outcome as a key. The numbers are then grouped together by their remainder after being divided by 3.
The group_by method is a great way to iterate through a list (or array) and create an easy way to access the data stored in that list. Let’s look at one more example that iterates through a list and sorts the data by alphabetical order.
The group_by method iterates through the elements in the birds array. For each element, it looks at the first letter and then creates a key value pair for that element, or stores it in an existing key-value pair if one has already been created.
The two examples given are pretty simple to try and illustrate how the group_by method works. Hopefully, you can see the power and usefulness for this method when you start working with bigger more complex data sets.
Thanks for reading.


Notices
Notices are messages that either inform you about the result of an action or the state of something.
Basic structure
An element can be turned into a notice, by giving it the class .notice
. There are five types of notices, though:
| type of notice | which class to apply | use for ... |
|---|---|---|
| Muted (default) | — | ... all notices, where no other type applies or which should have low visibility. |
| Danger | .is-danger |
... notices, that denote a dangerous, negative or deleted state or indicate that an action failed. |
| Warning | .is-warning |
... notices, that denote a critical or possibly dangerous state in need of your attention, or indicate an action with possibly unexpected outcome. |
| Success | .is-success |
... notices, that denote a positive state or indicate that an action succeeded. |
| Info | .is-info |
... notices, that inform neutrally about a state or the result of an action. |
Example

Muted notice

Danger notice

Warning notice

Success notice

Info notice

Muted notice
Danger notice
Warning notice
Success notice
Info notice
Filled notices
Sometimes a notice needs additional weight, possibly, because an action is critical. In these cases, it is in order, to apply the class .is-filled
, to make the notices even more noticeable.
Example

Muted notice

Danger notice

Warning notice

Success notice

Info notice

Muted notice
Danger notice
Warning notice
Success notice
Info notice
Notices as banner
Sometimes the notice applies to the whole page/site/instance. In these cases, the notice should be put either directly above or below the header. Also you should give it the class .is-banner
which changes some styles to make it better fit into the position. And don't forget, to center the content in a wrapper with the .container
class.
Example

Warning banner


JavaScript is disabled on your browser.
Skip navigation links
Overview
Package
Class
Tree
Deprecated
Index
Help
Prev Letter
Next Letter
Frames
No Frames
All Classes
A
B
C
D
E
F
G
H
I
L
M
N
P
R
S
T
U
V
W
R
recoverPotionEffect(Player)
- Method in interface io.github.ph1lou.werewolfapi.rolesattributs.
Roles
recoverPower(Player)
- Method in interface io.github.ph1lou.werewolfapi.rolesattributs.
Roles
registerRole(Constructor<? extends Roles>)
- Method in class io.github.ph1lou.werewolfapi.
RoleRegister
removeAffectedPlayer(UUID)
- Method in interface io.github.ph1lou.werewolfapi.rolesattributs.
AffectedPlayers
removeHost(UUID)
- Method in interface io.github.ph1lou.werewolfapi.
WereWolfAPI
Remove a host to the game
removeLover(UUID)
- Method in interface io.github.ph1lou.werewolfapi.
PlayerWW
removeModerator(UUID)
- Method in interface io.github.ph1lou.werewolfapi.
WereWolfAPI
Remove a moderator to the game
removePlayerOnWhiteList(UUID)
- Method in interface io.github.ph1lou.werewolfapi.
WereWolfAPI
Remove a player to the whitelist
resurrection(UUID)
- Method in interface io.github.ph1lou.werewolfapi.
WereWolfAPI
resurrects the player specified
ResurrectionEvent
- Class in
io.github.ph1lou.werewolfapi.events
ResurrectionEvent(UUID)
- Constructor for class io.github.ph1lou.werewolfapi.events.
ResurrectionEvent
RevealAmnesiacLoversEvent
- Class in
io.github.ph1lou.werewolfapi.events
RevealAmnesiacLoversEvent(List<UUID>)
- Constructor for class io.github.ph1lou.werewolfapi.events.
RevealAmnesiacLoversEvent
RevealCursedLoversEvent
- Class in
io.github.ph1lou.werewolfapi.events
RevealCursedLoversEvent(List<List<UUID>>)
- Constructor for class io.github.ph1lou.werewolfapi.events.
RevealCursedLoversEvent
RevealLoversEvent
- Class in
io.github.ph1lou.werewolfapi.events
RevealLoversEvent(List<List<UUID>>)
- Constructor for class io.github.ph1lou.werewolfapi.events.
RevealLoversEvent
RoleRegister
- Class in
io.github.ph1lou.werewolfapi
RoleRegister(GetWereWolfAPI, String)
- Constructor for class io.github.ph1lou.werewolfapi.
RoleRegister
Roles
- Interface in
io.github.ph1lou.werewolfapi.rolesattributs
A
B
C
D
E
F
G
H
I
L
M
N
P
R
S
T
U
V
W
Skip navigation links
Overview
Package
Class
Tree
Deprecated
Index
Help
Prev Letter
Next Letter
Frames
No Frames
All Classes


Development of a a Safe, High-Performance, Cylindrical Cell Lithium-Ion Battery Pack for an Electric Racecar. MIT Luis de Florez Design competition 1st place.
Custom battery pack using 18650 Li-Ion Cylindrical Cells, that is lighter, safer and contains more energy than the battery pack that was used two years ago to compete in FSAE. Pack consists of 6 modules, each of which is 12s12p for a total amount of energy of 7kWh (25MJ), about 1/10 that of a Tesla Model S. System level energy density is 100Wh/kg (360kJ/kg). The pack operates at a voltage of 300V, which made safety and ease of servicing our top priority.
Responsible for designing and making a fully serviceable, electrocution safe enclosure for the batteries HV electronics.
Cells after performing expoying tests. Cells after being glued to the polycarbonate holders. One completed module, with a total of 144 cells. Electrically completed modules. CAD of the battery modules along with the HV electronics packing in front, protected by blue FR4. The battery's High-Voltage electronics. The sheet metal bent battery pack enclosure. Innovations presented at the MIT De Florez's undergraduate design competition.The design for the HV electronics was based heavily on safety, and ease of serviceability. Previous year's pack was extremely dangerous to handle since it was easy for someone to accidentally electrocute themselves. In addition, the reduction in part count through the use of PEM Engineering fasteners aided not only with assembly but also minimized the chances of a metal part accidentally causing a short circuit.
The HV electronics were placed in order to minimize the number of steps required to disassemble a given component. This was achieve by placing more permanent components towards the back and placing more used or replaced components towards the front. The assembly contains a bottom layer that contains all of the HV electronics while the top contains all other components that interface with HV that are LV themselves. Layers of FR4 protect someone from accidentally electrocuting themselves.
Each module was made from custom machined polycarbonate holders for each of the cells. All of the cells were then glued onto the plates and let dry. The connections between the cells was done by placing the nickel strip on the cells and spot welding them. The polycarbonate plates were designed so that there is only one possible way of placing the nickel strips, to prevent accidental shorting.
The pack has a custom Battery Management System (BMS) that keeps track of all cell voltages to prevent an under voltage fault.
Each cell is individually fused through the use of 0.005" custom nickel-plated steel strips. Each module has 6 thermocouples in either side, which are monitored by the BMS to ensure that the cell operating temperature never exceeds 60C.
300W worth of fans cool down the cells, and the pack's peak operating power was around 60kW.
“Do not pray for an easy life, pray for the strength to endure a difficult one.”
— Bruce Lee


Mastering bag and mask ventilation
Providing the best care at birth
Improving care saves lives. Knowing the right care to give is not always enough to save babies’ lives—that knowledge must be put into practice.
Completing a workshop in Helping Babies Breathe is just the first step in improving the care that you give.
After the course, commit to making a
difference by:
(1) Identify areas that need improvement
Identify differences between what is
recommended and what is done at your
facility. Use the Action Plan, the Questions to
improve care and What to monitor.
(2) Create a system for ongoing practice
and review of cases
Master the Action Plan by participating in
ongoing practice, reviewing your actions every
time you help a baby breathe, and using case
reviews and audits to identify areas that need
improvement.
(3) Make changes that will improve care
Work with others on a plan to improve care
and take action in your facility.


MONITOR and MWAIT Instructions
The MONITOR instruction sets up an address range used to monitor write-back stores and the MWAIT instruction enables a logical processor to enter into an optimized state while waiting for a write-back store to the address range set up by the MONITOR instruction.


+++ title = "Turnhout" lat = 51.322030 lon = 4.947967 +++
Turnhout is not exactly one of the tourist hotspots of Europe — nevertheless, this small town was my first stop in the tiny nation of Belgium. Situated about 50km's east of Antwerp — in the northern reaches of Belgium, near the Dutch border — Turnhout is a quaint but mediocre place to hang out. I came here to visit my friends Annick and Stef, with whom I stayed for two nights, and with whom I had an absolute blast.


Unless otherwise noted, all readings are from the course text.
Each reading assignment should be completed before the class on the date
indicated. These readings are subject to change; check here for updates.
If a reading assigned in class does not match the reading assignment here,
the reading assigned in class supercedes.


| |
|
|
| |
|
|
|
|
|
|
|
|
| |
The wrapper methods provide extraction techniques for semi-structured sources, such as similarly-looking Web pages, but lots of data on the World Wide Web exists in an unstructured and ungrammatical form. For example, a user selling an item on EBay will not necessarily use the same textual layout as other posts about the same item. Nor will this user necessarily conform to the grammatical rules of language in their post (often times there are no verbs in listings). This lack of structure and grammar makes it difficult to develop wrapper methods for extraction on this type of data. We call this type of unstructured, ungrammatical data "posts" and it includes a large segment of Web data, such as auction listings, classified listings, and forum postings. |
|
| |
|
|
| |
To overcome this lack of structural and grammatical characterisics for extraction, we infuse the extraction process with outside knowledge, which we call reference sets. A reference set is a collection of entities and the associated attributes.
For example, a reference set of cars would include all known car makes, models, trim options and years.
A reference set could come from a set of pages on the Web, a database, a knowledge-base and ontology from the Semantic Web, or
even be built directly from the posts themselves (see our IJCAI 2009 paper). |
|
| |
|
|
| |
Exploiting these reference sets is a two step process. First, we take each listing for extraction, called the post,
and we match it to a member of the reference set. This yields a set of clues for what the system might extract from the post.
The second step extracts the items from the post that are most similar to the attributes from the matching reference set member.
This two step process can be done using machine learning methods, which yield highly accurate extractions, but at the cost of
training the system (JAIR 2008 paper), or it can be done using automatic methods, which are slightly less accurate, but do not require a human to train
the system (IJDAR 2007 paper). |
|
| |
|
|
| |
To make this type of extraction clear, consider the example posts from the website
www.BiddingForTravel.com, shown in the table Example Posts. These
posts include information users typed in regarding hotels. They contain
useful attributes such as the hotel name and the area of that hotel. Once
we extract these attributes we could then query the data set using them in a structured way, and
derive useful conclusions. Now, suppose we have a reference set such as
that shown in the table Reference Set of Hotels. This reference set
contains the hotel name and the hotel area. As stated above, the first step is to find the records in this reference set that best
match each post, which in turn yields the clues for extracting the attributes. To see the best matching record from the reference set, click on
a post from the Example Post table. This will highlight the best
matching member of the reference set in the Reference Set of Hotels table and show the extracted results in the table Extracted Information. |
|
| |
|
|
| |
Example Posts
| Post from www.BiddingForTravel.com |
| $25 winning bid at holiday inn sel. univ. ctr. |
| 4* Hyatt DT 8/18 $40 1 nite |
| Hol. Inn Greentree, $40 2/1 |
|
|
| |
|
|
| |
Reference Set of Hotels
| Hotel Name | Hotel Area |
| Holiday Inn | Greentree |
| Holiday Inn Select | University Center |
| Hyatt Regency | Downtown |
|
|
| |
|
|
| |
Extracted information
| Extracted Hotel Name | Extracted Hotel Area |
| |
|
|
| |
|
|
| |
We have released software implementations of the above methods described in the JAIR 2008 and IJDAR 2007 papers. This software is open-sourced and
freely available, and you can obtain a copy here. Also, we have released experimental data related to this task, which you can
obtain here. |
|
| |
|
|
|


Rosalyne Sirimitr
Rosalyne (Rosiee) Sirimitr is a student at the University of California, San Diego and is a candidate for a B.S. in Cognitive Science with specialization in HCI.
Project Portfolio


FT Graphics Examples
Small examples of data driven graphics -- to be used as starting points.
Open-high-low-close chart stock price chart
UK constituency cartogram (categorical)
World choropleth (categorical)
Small multiples (line)
Small multiples (columns)
Small multiples (bars)
Heatmap calendar
Circle timelines
Tree-map
Simple slope chart
10x10 icon array
(
second example
)


Welcome back! This week we're discussing ruby Classes! You can think of a class as a way to group a bunch of things that all have the same properties and rules associated with them. For instance, imagine you're a librarian who needs to keep track of a bunch of books. You could create a class called Book that would help you with this. Here's how you would start out:
1 Class Book
2 end
Pretty good, right? Well thats only the beginning. If we want our Book class to actually contain any properties or methods, we'll need to add those within. The first important step is to define the initialize method. This is what the Book class will run when you first create a new instance of Book. You'll see it below:
1 Class Book
2 def initialize(name, pagecount, isbn, checkedout)
3 @name = name
4 @pagecount = pagecount
5 @isbn = isbn
6 @checkedout = checkedout
7 end
8 end
You're probably seeing a few things you know about as well as a few new things. Lets start with line two. You'll see we're defining the method initialize to expect four arguments passed in. This means when we create a Book.new, the class will expect all of this data to be passed to it. Then, within the method you'll see those arguments being set equal to themselves with ampersands in front of them. There is something important happening here. The variables with ampersands preceding them are what we call "instance variables". They will be accessible from any method within this class, and so what we're essentially doing here is telling the class to store all four pieces of information for use with this new object.
Okay great. So now lets make a new method to make use of these instance variables.
1 Class Book
2 def initialize(name, pagecount, isbn, checkedout)
3 @name = name
4 @pagecount = pagecount
5 @isbn = isbn
6 @checkedout = checkedout
7 end
8
9 def info
10 puts "The Title is<EMAIL_ADDRESS>11 puts "The page count is #{@pagecount} pages."
12 puts "The ISBN is<EMAIL_ADDRESS>13 @checkedout = true ? puts "It is currently checked out." : "It is currently on the shelves."
14 end
15 end
Now, when we create a new instance of Book and call info on it, it will print all the information we passed in to screen. So for instance:
1 huckfinn = Book.new("The Adventures of Huckleberry Finn", 366,<PHONE_NUMBER>727, true
2 huckfinn.info
3 # => The Title is The Adventures of Huckleberry Finn
4 # => The page count is 366 pages.
5 # => The ISBN is<PHONE_NUMBER>727.
6 # => It is currently checked out.
This is a pretty redimentary way to use a class, but it gets the point across. You could also attribute reader and attribute writer (or use both in attribute accessor) to make it simple to call up each piece of info or modify it without creating new methods. Next time, on Dragon Ball Z!


Why and when
If you just want to get your first script running asap, feel free to skip this background information and jump straight to the geting started and the tutorial.
Resilient script execution
Most system interactions these days are done over HTTP and are non transactional. Between the time you start sending a request and the time you have received the confirmation in the response, you can’t really know the state of the service you tried to invoke.
The only thing you can do is keep track of which request you started and which requests completed successfully. That is exactly what RockScript does for you. RockScript keeps track of which interactions have started, which have completed and the complete runtime execution state with event sourcing.
That means RockScript is also able to recover from crashes, something
that normal programming languages cannot do. To get resilience without
RockScript, you have to revert to message queues, which require
you to cut or your code and connect those pieces with message queues.
With message queues, the overall business logic gets really hard to
follow and test. With RockScript it’s easy to read your business logic
in the scripts and test them.
Another very interesting consequence of storing the execuiton state with event sourcing is that you can really inspect the complete execution flow during and after the execution finishes. Imagine that you can investigate production issues with the exeuction inspector that lets you see what happened like in a debugger.
Juggle with JSON
When combining multiple microservices interactions, you often need to transform the data between those interactions. Most of the microservices interactions are based on JSON. There is no better language to deal with JSON manipulation than JavaScript. That’s why RockScript is based on JavaScript. So that coding your data transformations between microservice interactions becomes super easy.
 It can be a real challenge to read or debug code like that.
Activities package an interaction with an external system as a simple function invocation. Service function invocations look like normal function invocations. They are familiar and simple to read. But unlike other programming languages, the RockScript engine can execute those service function invocations non-blocking.
With RockScript, it’s much easier to keep the overview. The script contains the essence of the business logic. All the communication details are handled by the service bridges. Because those details are extracted from the script, it’s orders of magnitude easier to read, write and maintain compared to messages and message handlers.
RockScript lets you use a style of coding that is familiar to all developers. So it’s a safe choice in larger teams or teams where churn can be expected.
Alternatives
The most used alternative is message queues. This is a lower level solution that requires you to cut your code into pieces and tie your code-pieces together with with message queues and configuration of that infrastructure. It gets really hard to distill the business logic from all those fragments and configurations. RockScript let’s you write scripts at a higher business logic level and service bridges are a more elegant approach to breaking down the lower level communication details.
Other solutions on the same level as RockScript are
All these alternatives are based on activities, which are similar to our service functions. But there
is an important difference related to coding the execution flow between these activities.
In RockScript, the control flow is defined in the script itself. This means constructs
like if (condition) {...} else {...}
, for (loop) {...}
and blocks implying sequential
execution. The script, written in JavaScript syntax contains the service function
invocations as well as the control flow logic between the functions.
In AWS Step Functions and Uber Cadence the logic between the activities has to be implemented in the form of callbacks. Each time an serviceFunction is finished, those engines will call out to a workflow callback that has to calculate the next serviceFunction. So in these solutions you don’t have an overview. While you can code that logic in any language as well, you have to cut up your code in pieces. This way it’s harder to see the overview of how tasks are connected and what transformation logic is done inbetween. `` Other similar alternative technologies are Microsoft logic apps, BPM and workflow.


swSrc
Required String
If swSrc
is left undefined
, the plugin will generate a brand-new
service worker file as part of each compilation, configured based on the options provided.
If swSrc
is provided, the plugin assumes it refers to an existing service worker
file. The code in this file will be included as-is, with one addition: a call to
importScripts()
will be prepended to the existing code, automatically configured to import the generated
manifestFilename
file, as well as the necessary Workbox runtime library code.
When providing swSrc
, your service worker code can reference the
self.__precacheManifest
variable to obtain a list of
ManifestEntry
s
obtained as part of the compilation:
workbox.precaching.precacheAndRoute(self.__precacheManifest)
Example:
swSrc: path.join('dev', 'sw.js')


Enumeration members
Administrator
Administrator: = 6
BoilerRoom
BoilerRoom: = 29
Communications
Communications: = 14
Decontamination
Decontamination: = 18
Decontamination2
Decontamination2: = 26
Electrical
Electrical: = 7
Greenhouse
Greenhouse: = 24
Laboratory
Laboratory: = 21
Launchpad
Launchpad: = 19
LockerRoom
LockerRoom: = 20
LowerEngine
LowerEngine: = 13
Navigations
Navigations: = 5
ShipTasks
ShipTasks: = 15
Specimens
Specimens: = 28
UpperEngine
UpperEngine: = 4


>
The Lucy Game
The Lucy Game
Choose the button with a real nickname for Lucy, as a reward - a cute picture will appear!
Click here to play!


Test Note
MSPhysics Control Panel
Click on the main window to redirect input.
Move cursor outside the control panel to redirect input.
Drag slider to control.


Welcome! AngularGap is a powerful HTML5 native app development framework that helps you build native-feeling mobile apps all with web technologies like HTML, CSS.
AngularGap is focused mainly on the look and feel, and UI interaction of your app. Instead, AngularGap simply fits in well with these projects in order to simplify one big part of your app: the front end.
While you can still use the CSS portion of the framework, you'll miss out on powerful UI interactions, gestures, animations, and other things. In the future we'd like to expand beyond Angular to support other frameworks.
Download the latest official release of AngularGap and get started!
Download v0.9.0 "Alpha Jaguar"
You can also clone it on GitHub to get the bleeding edge release.
AngularGap comes with compiled Javascript and CSS for your app, optional SASS files and JS Framework extensions, along with a great icon pack.
The project structure is organized as follows:
angulargap/css/
- the Css code for the project and any framework extensions (like AngularJS) that we have provided.angulargap/scss/
- the raw SCSS files that can be used to integrate the AngularGap SCSS into your own project. Or you can use the compiled CSS in the dist folder above.angulargap/fonts/
- font files for the AngularGap icon pack.The CSS can stand on its own, but it is also built to be enhanced by the developer. For simplicity you can always just add in your own CSS and override default properties. And for even more power and flexibility, the core is written with SASS and includes easily customized variables and mixins. While the default design is similar to iOS, we feel we’ve left the CSS in a state which can be easily extended to get your own look and feel.
AngularGap is focused on building native/hybrid mobile apps rather than mobile websites.
As such, our browser support tends to be whatever Web View API is available to native apps on a given platform. For AngularGap v0.9.0 "Alpha Fox", that means UIWebView for iOS 6 and 7, and Android 4.1+.
AngularGap is an open source framework released under a permisive MIT license. This means you can use AngularGap in your own personal or commercial projects for free. MIT is the same license used by such popular projects as jQuery and Ruby on Rails.
AngularGap was built to take HTML5 on mobile into the future. We wanted a mobile framework that not only looked and worked great, but was also powerful enough to build the amazing apps the best developers were creating. HTML5's time has arrived. AngularGap is the framework that proves it.


WIKIPEDIA VIEWER
Search for a Wikipedia page or click on random to go to a random Wikipedia page.
Random


--- layout: post title: interpolate hex color vectors in one line of ruby date: 2007-06-27 08:30:53.000000000 +02:00 type: post published: true status: publish categories: - coding - fun - ruby tags: [] meta: _publicize_job_id: '14401150840' original_post_id: '123' _wp_old_slug: '123' author: login: joesixpack email<EMAIL_ADDRESS>display_name: dirk lüsebrink first_name: '' last_name: '' ---
which color lies halfway inbetween #ff00ff and #00ff00 you ask?
One line of ruby code can interolate two color vectors like they are usually found inside css files, like: body{background: #ff00ff; color: #00ff00}
.
%w{
ff00ff 00ff00
}.map{|a|a.scan(/../).map{|b|b.hex}}.inject{|c,d|(0...c.size).each{|i|c[i]+=d[i]};c}.map{|e|"%02x"%(e>>1)}.join
@UPDATE:
#
121 character solution by schmidt(http://www.nach-vorne.de)%w{ff00ff 00ff00}.map{|a|a.scan(/../).map{|b|b.hex}}.inject{|c,d|c.size.times{|i|c[i]+=d[i]};c}.map{|e|"%0x"%(e>>1)}.join
Answer -> 0x7f7f7f. sure, there must be a shorter version. Can you show it to me?
next step: color animations and gradients and HSR colorspace conversions mayby.
have fun
Technorati Tags: ruby, coding, puzzle, css, hex, color, interpolation


jason
hyien
olivia
jose
sal (me)
eric
Why was Betamore's app release delayed?
They had to test the beta more.


VaultSchema |
JPA representation of the core Vault Schema object VaultSchema |
VaultSchemaV1 |
First version of the Vault ORM schema object VaultSchemaV1 : MappedSchema |
MAX_CONSTRAINT_DATA_SIZE |
The maximum permissible size of contract constraint type data (for storage in vault states database table). const val MAX_CONSTRAINT_DATA_SIZE: Int |


About
Portfolio
Contact
Welcome to my world
-Sandeep Chadaram
Product Landing Page
To connect with me and know more about my projects...
Facebook
GitHub


|
19.08
|
Execution workload. More...
#include <Workload.h>
Data Fields | |
| std::vector< Tensor * > | inputs = {} |
| Input handles. More... | |
| std::vector< Tensor * > | outputs = {} |
| Output handles. More... | |
| std::vector< ExecutionTask > | tasks = {} |
| Execution workload. More... | |
| Graph * | graph = { nullptr } |
| Graph bound to the workload. More... | |
| GraphContext * | ctx = { nullptr } |
| Graph execution context. More... | |
Execution workload.
Definition at line 98 of file Workload.h.
| GraphContext* ctx = { nullptr } |
Graph execution context.
Definition at line 104 of file Workload.h.
Referenced by arm_compute::graph::detail::call_all_tasks(), and arm_compute::graph::detail::configure_all_nodes().
| Graph* graph = { nullptr } |
Graph bound to the workload.
Definition at line 103 of file Workload.h.
Referenced by arm_compute::graph::detail::configure_all_nodes(), and arm_compute::graph::detail::prepare_all_tasks().
| std::vector<Tensor *> inputs = {} |
Input handles.
Definition at line 100 of file Workload.h.
Referenced by arm_compute::graph::detail::call_all_input_node_accessors(), and arm_compute::graph::detail::configure_all_nodes().
| std::vector<Tensor *> outputs = {} |
Output handles.
Definition at line 101 of file Workload.h.
Referenced by arm_compute::graph::detail::call_all_output_node_accessors(), and arm_compute::graph::detail::configure_all_nodes().
| std::vector<ExecutionTask> tasks = {} |
Execution workload.
Definition at line 102 of file Workload.h.
Referenced by arm_compute::graph::detail::call_all_tasks(), arm_compute::graph::detail::configure_all_nodes(), arm_compute::graph::detail::configure_transition_manager(), and arm_compute::graph::detail::prepare_all_tasks().


| 1 | package fr.sii.ogham.core.message.fluent; | |
| 2 | ||
| 3 | import fr.sii.ogham.core.message.content.Content; | |
| 4 | import fr.sii.ogham.core.message.content.StringContent; | |
| 5 | import fr.sii.ogham.core.message.content.StringTemplateContent; | |
| 6 | import fr.sii.ogham.core.message.content.TemplateContent; | |
| 7 | import fr.sii.ogham.core.resource.path.ResourcePath; | |
| 8 | import fr.sii.ogham.core.template.context.Context; | |
| 9 | ||
| 10 | /** | |
| 11 | * Fluent API to build a single content based on: | |
| 12 | *
 | |
| 13 | *
Either a string
 | |
| 14 | *
Or a template string
 | |
| 15 | *
Or a template loaded from a path
 | |
| 16 | *
 | |
| 17 | * | |
| 18 | * @author Aurélien Baudet | |
| 19 | * | |
| 20 | * @param
 | |
| 21 | * the type of the parent for fluent chaining | |
| 22 | * @since 3.0.0 | |
| 23 | */ | |
| 24 | public class SingleContentBuilder
 { | |
| 25 | private final P parent; | |
| 26 | private Content content; | |
| 27 | ||
| 28 | /** | |
| 29 | * Initializes with the parent to go back to. | |
| 30 | * | |
| 31 | * @param parent | |
| 32 | * the parent instance | |
| 33 | */ | |
| 34 | public SingleContentBuilder(P parent) { | |
| 35 | super(); | |
| 36 | this.parent = parent; | |
| 37 | } | |
| 38 | ||
| 39 | /** | |
| 40 | * Set the content directly as a simple string. | |
| 41 | * | |
| 42 | *
 | |
| 43 | * If this method is called several times, only the last value is used. | |
| 44 | * | |
| 45 | *
 | |
| 46 | * If any other method of this class was called before calling this method, | |
| 47 | * only the value of this method is used. | |
| 48 | * | |
| 49 | * @param content | |
| 50 | * the content as a string | |
| 51 | * @return the instance for fluent chaining | |
| 52 | */ | |
| 53 | public P string(String content) { | |
| 54 | this.content = new StringContent(content); | |
| 55 |
1
1. string : replaced return value with null for fr/sii/ogham/core/message/fluent/SingleContentBuilder::string → NO_COVERAGE |
return parent; |
| 56 | } | |
| 57 | ||
| 58 | /** | |
| 59 | * Set the content using a template (directly provided as a string). The | |
| 60 | * template contains variables that are evaluated against the bean object. | |
| 61 | * | |
| 62 | *
 | |
| 63 | * If this method is called several times, only the last value is used. | |
| 64 | * | |
| 65 | *
 | |
| 66 | * If any other method of this class was called before calling this method, | |
| 67 | * only the value of this method is used. | |
| 68 | * | |
| 69 | * @param template | |
| 70 | * the template directly provided as a string | |
| 71 | * @param bean | |
| 72 | * the object that contains the variables that are referenced in | |
| 73 | * the template | |
| 74 | * @return the instance for fluent chaining | |
| 75 | */ | |
| 76 | public P templateString(String template, Object bean) { | |
| 77 | this.content = new StringTemplateContent(template, bean); | |
| 78 |
1
1. templateString : replaced return value with null for fr/sii/ogham/core/message/fluent/SingleContentBuilder::templateString → NO_COVERAGE |
return parent; |
| 79 | } | |
| 80 | ||
| 81 | /** | |
| 82 | * Set the content using a template (directly provided as a string). The | |
| 83 | * template contains variables that are evaluated against the evaluation | |
| 84 | * context. The context contains at least the values of the variables but | |
| 85 | * can also contain additional information for parsing the template. | |
| 86 | * | |
| 87 | *
 | |
| 88 | * If this method is called several times, only the last value is used. | |
| 89 | * | |
| 90 | *
 | |
| 91 | * If any other method of this class was called before calling this method, | |
| 92 | * only the value of this method is used. | |
| 93 | * | |
| 94 | * @param template | |
| 95 | * the template directly provided as a string | |
| 96 | * @param context | |
| 97 | * contains at least the variables that are referenced in the | |
| 98 | * template and may contain additional information to parse the | |
| 99 | * template | |
| 100 | * @return the instance for fluent chaining | |
| 101 | */ | |
| 102 | public P templateString(String template, Context context) { | |
| 103 | this.content = new StringTemplateContent(template, context); | |
| 104 |
1
1. templateString : replaced return value with null for fr/sii/ogham/core/message/fluent/SingleContentBuilder::templateString → NO_COVERAGE |
return parent; |
| 105 | } | |
| 106 | ||
| 107 | /** | |
| 108 | * Set the content using a template loaded from a path. The template | |
| 109 | * contains variables that are evaluated against the bean object. | |
| 110 | * | |
| 111 | *
 | |
| 112 | * If this method is called several times, only the last value is used. | |
| 113 | * | |
| 114 | *
 | |
| 115 | * If any other method of this class was called before calling this method, | |
| 116 | * only the value of this method is used. | |
| 117 | * | |
| 118 | * @param templatePath | |
| 119 | * the path to the template | |
| 120 | * @param bean | |
| 121 | * the object that contains the variables that are referenced in | |
| 122 | * the template | |
| 123 | * @return the instance for fluent chaining | |
| 124 | */ | |
| 125 | public P template(String templatePath, Object bean) { | |
| 126 | this.content = new TemplateContent(templatePath, bean); | |
| 127 |
1
1. template : replaced return value with null for fr/sii/ogham/core/message/fluent/SingleContentBuilder::template → NO_COVERAGE |
return parent; |
| 128 | } | |
| 129 | ||
| 130 | /** | |
| 131 | * Set the content using a template loaded from a path. The template | |
| 132 | * contains variables that are evaluated against the bean object. | |
| 133 | * | |
| 134 | *
 | |
| 135 | * If this method is called several times, only the last value is used. | |
| 136 | * | |
| 137 | *
 | |
| 138 | * If any other method of this class was called before calling this method, | |
| 139 | * only the value of this method is used. | |
| 140 | * | |
| 141 | * @param templatePath | |
| 142 | * the path to the template | |
| 143 | * @param bean | |
| 144 | * the object that contains the variables that are referenced in | |
| 145 | * the template | |
| 146 | * @return the instance for fluent chaining | |
| 147 | */ | |
| 148 | public P template(ResourcePath templatePath, Object bean) { | |
| 149 | this.content = new TemplateContent(templatePath, bean); | |
| 150 |
1
1. template : replaced return value with null for fr/sii/ogham/core/message/fluent/SingleContentBuilder::template → NO_COVERAGE |
return parent; |
| 151 | } | |
| 152 | ||
| 153 | /** | |
| 154 | * Set the content using a template loaded from a path. The template | |
| 155 | * contains variables that are evaluated against the evaluation context. The | |
| 156 | * context contains at least the values of the variables but can also | |
| 157 | * contain additional information for parsing the template. | |
| 158 | * | |
| 159 | *
 | |
| 160 | * If this method is called several times, only the last value is used. | |
| 161 | * | |
| 162 | *
 | |
| 163 | * If any other method of this class was called before calling this method, | |
| 164 | * only the value of this method is used. | |
| 165 | * | |
| 166 | * @param templatePath | |
| 167 | * the path to the template | |
| 168 | * @param context | |
| 169 | * contains at least the variables that are referenced in the | |
| 170 | * template and may contain additional information to parse the | |
| 171 | * template | |
| 172 | * @return the instance for fluent chaining | |
| 173 | */ | |
| 174 | public P template(String templatePath, Context context) { | |
| 175 | this.content = new TemplateContent(templatePath, context); | |
| 176 |
1
1. template : replaced return value with null for fr/sii/ogham/core/message/fluent/SingleContentBuilder::template → NO_COVERAGE |
return parent; |
| 177 | } | |
| 178 | ||
| 179 | /** | |
| 180 | * Set the content using a template loaded from a path. The template | |
| 181 | * contains variables that are evaluated against the evaluation context. The | |
| 182 | * context contains at least the values of the variables but can also | |
| 183 | * contain additional information for parsing the template. | |
| 184 | * | |
| 185 | *
 | |
| 186 | * If this method is called several times, only the last value is used. | |
| 187 | * | |
| 188 | *
 | |
| 189 | * If any other method of this class was called before calling this method, | |
| 190 | * only the value of this method is used. | |
| 191 | * | |
| 192 | * @param templatePath | |
| 193 | * the path to the template | |
| 194 | * @param context | |
| 195 | * contains at least the variables that are referenced in the | |
| 196 | * template and may contain additional information to parse the | |
| 197 | * template | |
| 198 | * @return the instance for fluent chaining | |
| 199 | */ | |
| 200 | public P template(ResourcePath templatePath, Context context) { | |
| 201 | this.content = new TemplateContent(templatePath, context); | |
| 202 |
1
1. template : replaced return value with null for fr/sii/ogham/core/message/fluent/SingleContentBuilder::template → NO_COVERAGE |
return parent; |
| 203 | } | |
| 204 | ||
| 205 | /** | |
| 206 | * Build the final {@link Content}. Only the last registered content is used | |
| 207 | * (the last call to any method of this class) | |
| 208 | * | |
| 209 | * @return the built content | |
| 210 | */ | |
| 211 | public Content build() { | |
| 212 |
1
1. build : replaced return value with null for fr/sii/ogham/core/message/fluent/SingleContentBuilder::build → RUN_ERROR |
return content; |
| 213 | } | |
| 214 | } | |
Mutations | ||
| 55 |
1.1 |
|
| 78 |
1.1 |
|
| 104 |
1.1 |
|
| 127 |
1.1 |
|
| 150 |
1.1 |
|
| 176 |
1.1 |
|
| 202 |
1.1 |
|
| 212 |
1.1 |


University of Michigan —<EMAIL_ADDRESS>I use data-intensive techniques to improve software reliability.
I'm going to UC Santa Cruz!
If you're interested in building more reliable software systems, let's talk!
CV —
Research —
Teaching —
Diversity
Microsoft Fellowship ('17) NSF Fellowship ('17) John L. Gilpatrick Award ('14) Ted Barclay Student-Athlete ('14)
I'm a sixth year Ph.d candidate working with Baris Kasikci at the University of Michigan. I worked with Jason Flinn for many years. I'm supported by a Microsoft Research Fellowship and a National Science Foundation Fellowship.
I'm broadly interested in improving software reliability. Specifically, I'm investigating data-intensive software reliability: how can we apply data-intensive techniques to prevent, detect, and resolve software errors? My thesis proposes a fundamentally more powerful model for observing program executions to perform tasks such as security forensics, debugging and data provenance. This work treats a program execution as a massive data object consisting of all the program states (i.e., memory and register values) reached by the execution and uses cluster-scale parallelization and declarative languages to accelerate and simplify observations over these objects. In the future, I'm interested in using similar techniques to provide run-time safety properties with minimal developer effort.
I am currently mentoring a number of students in Baris Kasikci's lab. We're working on a number of projects in the software reliability space, including improving the reliability of persistent memory applications, understanding how heterogeneous deployments impact the reliability of our systems, and building better tools for failure reproduction.
I'm an avid reader, political junkie, and casual sports fan. If I'm not working, then I'm probably wrestling with my dogs, Huckleberry and Harley; cooking an elaborate meal with my wife, Tully; baking something sweet from Bravetart; or enjoing a long run around Ann Arbor.
|
Reproducing Production Failures with Execution
Reconstruction. HIPPOCRATES: Healing Persistent Memory Bugs Without
Doing Any Harm. |
|
AGAMOTTO: How Persistent is your Persistent Memory
application? |
|
The Case for Determinism on the Edge
|
|
You can't debug what you can't see: Expanding observability with the OmniTable
|
|
Sledgehammer: Cluster-Fueled Debugging
|
|
JetStream: Cluster-scale Parallelization of Information
Flow Queries |
ASPLOS External Review Committee Member (2021) EuroSys Shadow Program Committee Member (2020) SOSP Artifact Evaluation Committee Member (2019) University of Michigan CSE Ph.D. Admissions Committee Member (2018) Discover Engineering Volunteer (2019) Techie Club Volunteer (2015) A Call to College Volunteer (2013)


We are a Code for America Brigade, which means we're volunteers that contribute our talents toward improving the way our local governments and community organizations use the web. Brigade is about action and you're here because you are someone who takes action. Watch the inspirational TED talk given by Jennifer Pahlka, the founder of Code for America.


This sample shows how to run four simple queries against the OS Linked Identifiers API.
To run any of the queries, please enter a valid API key.
To connect to your linked identifiers API:


File I/O
- ALLEGRO_FILE
- ALLEGRO_FILE_INTERFACE
- ALLEGRO_SEEK
- al_fopen
- al_fopen_interface
- al_fopen_slice
- al_fclose
- al_fread
- al_fwrite
- al_fflush
- al_ftell
- al_fseek
- al_feof
- al_ferror
- al_fclearerr
- al_fungetc
- al_fsize
- al_fgetc
- al_fputc
- al_fread16le
- al_fread16be
- al_fwrite16le
- al_fwrite16be
- al_fread32le
- al_fread32be
- al_fwrite32le
- al_fwrite32be
- al_fgets
- al_fget_ustr
- al_fputs
- Standard I/O specific routines
- Alternative file streams
These functions are declared in the main Allegro header file:
#include <allegro5/allegro.h>
ALLEGRO_FILE
typedef struct ALLEGRO_FILE ALLEGRO_FILE;
An opaque object representing an open file. This could be a real file on disk or a virtual file.
ALLEGRO_FILE_INTERFACE
typedef struct ALLEGRO_FILE_INTERFACE
A structure containing function pointers to handle a type of "file", real or virtual. See the full discussion in al_set_new_file_interface.
The fields are:
void* (*fi_fopen)(const char *path, const char *mode);
void (*fi_fclose)(ALLEGRO_FILE *f);
size_t (*fi_fread)(ALLEGRO_FILE *f, void *ptr, size_t size);
size_t (*fi_fwrite)(ALLEGRO_FILE *f, const void *ptr, size_t size);
bool (*fi_fflush)(ALLEGRO_FILE *f);
int64_t (*fi_ftell)(ALLEGRO_FILE *f);
bool (*fi_fseek)(ALLEGRO_FILE *f, int64_t offset, int whence);
bool (*fi_feof)(ALLEGRO_FILE *f);
bool (*fi_ferror)(ALLEGRO_FILE *f);
void (*fi_fclearerr)(ALLEGRO_FILE *f);
int (*fi_fungetc)(ALLEGRO_FILE *f, int c);
off_t (*fi_fsize)(ALLEGRO_FILE *f);
The fi_open function must allocate memory for whatever userdata structure it needs. The pointer to that memory must be returned; it will then be associated with the file. The other functions can access that data by calling al_get_file_userdata on the file handle. If fi_open returns NULL then al_fopen will also return NULL.
The fi_fclose function must clean up and free the userdata, but Allegro will free the ALLEGRO_FILE handle.
If fi_fungetc is NULL, then Allegro's default implementation of a 16 char long buffer will be used.
ALLEGRO_SEEK
typedef enum ALLEGRO_SEEK
- ALLEGRO_SEEK_SET - seek relative to beginning of file
- ALLEGRO_SEEK_CUR - seek relative to current file position
- ALLEGRO_SEEK_END - seek relative to end of file
See also: al_fseek
al_fopen
ALLEGRO_FILE *al_fopen(const char *path, const char *mode)
Creates and opens a file (real or virtual) given the path and mode. The current file interface is used to open the file.
Parameters:
- path - path to the file to open
- mode - access mode to open the file in ("r", "w", etc.)
Depending on the stream type and the mode string, files may be opened in "text" mode. The handling of newlines is particularly important. For example, using the default stdio-based streams on DOS and Windows platforms, where the native end-of-line terminators are CR+LF sequences, a call to al_fgetc may return just one character ('\n') where there were two bytes (CR+LF) in the file. When writing out '\n', two bytes would be written instead. (As an aside, '\n' is not defined to be equal to LF either.)
Newline translations can be useful for text files but is disastrous for binary files. To avoid this behaviour you need to open file streams in binary mode by using a mode argument containing a "b", e.g. "rb", "wb".
Returns a file handle on success, or NULL on error.
See also: al_set_new_file_interface, al_fclose.
al_fopen_interface
ALLEGRO_FILE *al_fopen_interface(const ALLEGRO_FILE_INTERFACE *drv,
const char *path, const char *mode)
Opens a file using the specified interface, instead of the interface set with al_set_new_file_interface.
See also: al_fopen
al_fopen_slice
ALLEGRO_FILE *al_fopen_slice(ALLEGRO_FILE *fp, size_t initial_size, const char *mode)
Opens a slice (subset) of an already open random access file as if it were a stand alone file. While the slice is open, the parent file handle must not be used in any way.
The slice is opened at the current location of the parent file, up through initial_size
bytes. The initial_size
may be any non-negative integer that will not exceed the bounds of the parent file.
Seeking with ALLEGRO_SEEK_SET
will be relative to this starting location. ALLEGRO_SEEK_END
will be relative to the starting location plus the size of the slice.
The mode can be any combination of:
- r: read access
- w: write access
- e: expandable
For example, a mode of "rw" indicates the file can be read and written. (Note that this is slightly different from the stdio modes.) Keep in mind that the parent file must support random access and be open in normal write mode (not append) for the slice to work in a well defined way.
If the slice is marked as expandable, then reads and writes can happen after the initial end point, and the slice will grow accordingly. Otherwise, all activity is restricted to the initial size of the slice.
A slice must be closed with al_fclose. The parent file will then be positioned immediately after the end of the slice.
Since: 5.0.6, 5.1.0
See also: al_fopen
al_fclose
void al_fclose(ALLEGRO_FILE *f)
Close the given file, writing any buffered output data (if any).
al_fread
size_t al_fread(ALLEGRO_FILE *f, void *ptr, size_t size)
Read 'size' bytes into the buffer pointed to by 'ptr', from the given file.
Returns the number of bytes actually read. If an error occurs, or the end-of-file is reached, the return value is a short byte count (or zero).
al_fread() does not distinguish between EOF and other errors. Use al_feof and al_ferror to determine which occurred.
See also: al_fgetc, al_fread16be, al_fread16le, al_fread32be, al_fread32le
al_fwrite
size_t al_fwrite(ALLEGRO_FILE *f, const void *ptr, size_t size)
Write 'size' bytes from the buffer pointed to by 'ptr' into the given file.
Returns the number of bytes actually written. If an error occurs, the return value is a short byte count (or zero).
See also: al_fputc, al_fputs, al_fwrite16be, al_fwrite16le, al_fwrite32be, al_fwrite32le
al_fflush
bool al_fflush(ALLEGRO_FILE *f)
Flush any pending writes to the given file.
Returns true on success, false otherwise. errno is set to indicate the error.
See also: al_get_errno
al_ftell
int64_t al_ftell(ALLEGRO_FILE *f)
Returns the current position in the given file, or -1 on error. errno is set to indicate the error.
On some platforms this function may not support large files.
See also: al_fseek, al_get_errno
al_fseek
bool al_fseek(ALLEGRO_FILE *f, int64_t offset, int whence)
Set the current position of the given file to a position relative to that specified by 'whence', plus 'offset' number of bytes.
'whence' can be:
- ALLEGRO_SEEK_SET - seek relative to beginning of file
- ALLEGRO_SEEK_CUR - seek relative to current file position
- ALLEGRO_SEEK_END - seek relative to end of file
Returns true on success, false on failure. errno is set to indicate the error.
After a successful seek, the end-of-file indicator is cleared and all pushback bytes are forgotten.
On some platforms this function may not support large files.
See also: al_ftell, al_get_errno
al_feof
bool al_feof(ALLEGRO_FILE *f)
Returns true if the end-of-file indicator has been set on the file, i.e. we have attempted to read past the end of the file.
This does not return true if we simply are at the end of the file. The following code correctly reads two bytes, even when the file contains exactly two bytes:
int b1 = al_fgetc(f);
int b2 = al_fgetc(f);
if (al_feof(f)) {
/* At least one byte was unsuccessfully read. */
report_error();
}
See also: al_ferror, al_fclearerr
al_ferror
bool al_ferror(ALLEGRO_FILE *f)
Returns true if the error indicator is set on the given file, i.e. there was some sort of previous error.
See also: al_feof, al_fclearerr
al_fclearerr
void al_fclearerr(ALLEGRO_FILE *f)
Clear the error indicator for the given file.
The standard I/O backend also clears the end-of-file indicator, and other backends should try to do this. However, they may not if it would require too much effort (e.g. PhysicsFS backend), so your code should not rely on it if you need your code to be portable to other backends.
al_fungetc
int al_fungetc(ALLEGRO_FILE *f, int c)
Ungets a single byte from a file. Pushed-back bytes are not written to the file, only made available for subsequent reads, in reverse order.
The number of pushbacks depends on the backend. The standard I/O backend only guarantees a single pushback; this depends on the libc implementation.
For backends that follow the standard behavior, the pushback buffer will be cleared after any seeking or writing; also calls to al_fseek and al_ftell are relative to the number of pushbacks. If a pushback causes the position to become negative, the behavior of al_fseek and al_ftell are undefined.
See also: al_fgetc, al_get_errno
al_fsize
int64_t al_fsize(ALLEGRO_FILE *f)
Return the size of the file, if it can be determined, or -1 otherwise.
al_fgetc
int al_fgetc(ALLEGRO_FILE *f)
Read and return next byte in the given file. Returns EOF on end of file or if an error occurred.
See also: al_fungetc
al_fputc
int al_fputc(ALLEGRO_FILE *f, int c)
Write a single byte to the given file. The byte written is the value of c cast to an unsigned char.
Parameters:
- c - byte value to write
- f - file to write to
Returns the written byte (cast back to an int) on success, or EOF on error.
al_fread16le
int16_t al_fread16le(ALLEGRO_FILE *f)
Reads a 16-bit word in little-endian format (LSB first).
On success, returns the 16-bit word. On failure, returns EOF (-1). Since -1 is also a valid return value, use al_feof to check if the end of the file was reached prematurely, or al_ferror to check if an error occurred.
See also: al_fread16be
al_fread16be
int16_t al_fread16be(ALLEGRO_FILE *f)
Reads a 16-bit word in big-endian format (MSB first).
On success, returns the 16-bit word. On failure, returns EOF (-1). Since -1 is also a valid return value, use al_feof to check if the end of the file was reached prematurely, or al_ferror to check if an error occurred.
See also: al_fread16le
al_fwrite16le
size_t al_fwrite16le(ALLEGRO_FILE *f, int16_t w)
Writes a 16-bit word in little-endian format (LSB first).
Returns the number of bytes written: 2 on success, less than 2 on an error.
See also: al_fwrite16be
al_fwrite16be
size_t al_fwrite16be(ALLEGRO_FILE *f, int16_t w)
Writes a 16-bit word in big-endian format (MSB first).
Returns the number of bytes written: 2 on success, less than 2 on an error.
See also: al_fwrite16le
al_fread32le
int32_t al_fread32le(ALLEGRO_FILE *f)
Reads a 32-bit word in little-endian format (LSB first).
On success, returns the 32-bit word. On failure, returns EOF (-1). Since -1 is also a valid return value, use al_feof to check if the end of the file was reached prematurely, or al_ferror to check if an error occurred.
See also: al_fread32be
al_fread32be
int32_t al_fread32be(ALLEGRO_FILE *f)
Read a 32-bit word in big-endian format (MSB first).
On success, returns the 32-bit word. On failure, returns EOF (-1). Since -1 is also a valid return value, use al_feof to check if the end of the file was reached prematurely, or al_ferror to check if an error occurred.
See also: al_fread32le
al_fwrite32le
size_t al_fwrite32le(ALLEGRO_FILE *f, int32_t l)
Writes a 32-bit word in little-endian format (LSB first).
Returns the number of bytes written: 4 on success, less than 4 on an error.
See also: al_fwrite32be
al_fwrite32be
size_t al_fwrite32be(ALLEGRO_FILE *f, int32_t l)
Writes a 32-bit word in big-endian format (MSB first).
Returns the number of bytes written: 4 on success, less than 4 on an error.
See also: al_fwrite32le
al_fgets
char *al_fgets(ALLEGRO_FILE *f, char * const buf, size_t max)
Read a string of bytes terminated with a newline or end-of-file into the buffer given. The line terminator(s), if any, are included in the returned string. A maximum of max-1 bytes are read, with one byte being reserved for a NUL terminator.
Parameters:
- f - file to read from
- buf - buffer to fill
- max - maximum size of buffer
Returns the pointer to buf on success. Returns NULL if an error occurred or if the end of file was reached without reading any bytes.
See al_fopen about translations of end-of-line characters.
See also: al_fget_ustr
al_fget_ustr
ALLEGRO_USTR *al_fget_ustr(ALLEGRO_FILE *f)
Read a string of bytes terminated with a newline or end-of-file. The line terminator(s), if any, are included in the returned string.
On success returns a pointer to a new ALLEGRO_USTR structure. This must be freed eventually with al_ustr_free. Returns NULL if an error occurred or if the end of file was reached without reading any bytes.
See al_fopen about translations of end-of-line characters.
al_fputs
int al_fputs(ALLEGRO_FILE *f, char const *p)
Writes a string to file. Apart from the return value, this is equivalent to:
al_fwrite(f, p, strlen(p));
Parameters:
- f - file handle to write to
- p - string to write
Returns a non-negative integer on success, EOF on error.
Note: depending on the stream type and the mode passed to al_fopen, newline characters in the string may or may not be automatically translated to native end-of-line sequences, e.g. CR/LF instead of LF.
See also: al_fwrite
Standard I/O specific routines
al_fopen_fd
ALLEGRO_FILE *al_fopen_fd(int fd, const char *mode)
Create an ALLEGRO_FILE object that operates on an open file descriptor using stdio routines. See the documentation of fdopen() for a description of the 'mode' argument.
Returns an ALLEGRO_FILE object on success or NULL on an error. On an error, the Allegro errno will be set and the file descriptor will not be closed.
The file descriptor will be closed by al_fclose so you should not call close() on it.
See also: al_fopen
al_make_temp_file
ALLEGRO_FILE *al_make_temp_file(const char *template, ALLEGRO_PATH **ret_path)
Make a temporary randomly named file given a filename 'template'.
'template' is a string giving the format of the generated filename and should include one or more capital Xs. The Xs are replaced with random alphanumeric characters. There should be no path separators.
If 'ret_path' is not NULL, the address it points to will be set to point to a new path structure with the name of the temporary file.
Returns the opened ALLEGRO_FILE on success, NULL on failure.
Alternative file streams
By default, the Allegro file I/O routines use the C library I/O routines, hence work with files on the local filesystem, but can be overridden so that you can read and write to other streams. For example, you can work with block of memory or sub-files inside .zip files.
There are two ways to get an ALLEGRO_FILE that doesn't use stdio. An addon library may provide a function that returns a new ALLEGRO_FILE directly, after which, all al_f* calls on that object will use overridden functions for that type of stream. Alternatively, al_set_new_file_interface changes which function will handle the following al_fopen calls for the current thread.
al_set_new_file_interface
void al_set_new_file_interface(const ALLEGRO_FILE_INTERFACE *file_interface)
Set the ALLEGRO_FILE_INTERFACE table for the calling thread. This will change the handler for later calls to al_fopen.
See also: al_set_standard_file_interface, al_store_state, al_restore_state.
al_set_standard_file_interface
void al_set_standard_file_interface(void)
Set the ALLEGRO_FILE_INTERFACE table to the default, for the calling thread. This will change the handler for later calls to al_fopen.
See also: al_set_new_file_interface
al_get_new_file_interface
const ALLEGRO_FILE_INTERFACE *al_get_new_file_interface(void)
Return a pointer to the ALLEGRO_FILE_INTERFACE table in effect for the calling thread.
See also: al_store_state, al_restore_state.
al_create_file_handle
ALLEGRO_FILE *al_create_file_handle(const ALLEGRO_FILE_INTERFACE *drv,
void *userdata)
Creates an empty, opened file handle with some abstract user data. This allows custom interfaces to extend the ALLEGRO_FILE struct with their own data. You should close the handle with the standard al_fclose function when you are finished with it.
See also: al_fopen, al_fclose, al_set_new_file_interface
al_get_file_userdata
void *al_get_file_userdata(ALLEGRO_FILE *f)
Returns a pointer to the custom userdata that is attached to the file handle. This is intended to be used by functions that extend ALLEGRO_FILE_INTERFACE.


Child members: Childrens
Created by: Parent Name
Created At: DD:MM:SS
ADD CHILD
ADD GROUP AVATAR
ADD NEW TASK
Fin more information about the app here: ABOUT THE APP
Video tuttorial: HOW TO USE IT


Chapter 32 TaskRabbit
The online and mobile marketplace TaskRabbit was launched in 2008 in Boston as “RunMyErrand.” It became TaskRabbit in 2010 to avoid perceived limitations in the word “errand” and to go with a name that was more memorable and fun. At the same time, the base of operations was changed to San Francisco. TaskRabbit is a venue for outsourcing small neighborhood jobs to pre-approved “TaskRabbits” who compete for job listings that describe the required task and give an offered price or ask for bids. Dropping the word “errand” from the service’s name helped branding. While users might hire someone to run to the grocery store for them, the job might also be assembling a shelving unit or organizing a closet. The more all-encompassing word “task” was chosen to open up user’s imagination about why and how they might utilize the service. In May 2011, TaskRabbit secured $5 million in financing with 2,000 TaskRabbits proving the concept was workable. Over the course of a year, the service expanded into four more markets: New York City, Chicago, Los Angeles, and Orange County and also launched a mobile app. A second round of funding to the tune of $17.8 million in December 2011 allowed the company to focus on their product development, including incorporating a gamified approach. Top workers are ranked on a leader board that also displays their average customer reviews. This kind of peer-to-peer sharing involves crafting a perception of trust so users are willing to do business with strangers. Each potential TaskRabbit is given a criminal background check and interviewed via video before they are approved. The site design emphasizes this guarantee, “Find safe, reliable help in your neighborhood” from “20,000+ Background Checked TaskRabbits.” Sign-up is free and requires only an email address and a zip code, a dead simple method taken from the playbook of highly successful buy low-key sites like DropBox. TaskRabbit founder Leah Busque advocates staying in constant update mode to make sure that users are always having the best possible experience with the product. Every two weeks the company tests its site design, user experience, and other features with A/B testing through Kissmetrics.
For instance, the company studies the effectiveness of photos versus illustrations on the front page and determined that photos result in twice as many sign-up. There is a strong emphasis on the company’s culture to ensure that everyone hired reflects the quality of the brand. TaskRabbit values openness with a helpful, collaborative, and friendly approach. This is even bolstered by a selection of offices with open floor plans and the inclusion of a recreation room to inject some fun in the work place. The reasoning is that the idea of TaskRabbit, though useful, is also quirkily and fun. Staying focused on the brand and offering the highest level of user experience possible has allowed this startup to thrive even in the face of competition.


Style Plugin Example
A plugin in Qt is a class stored in a shared library that can be loaded by a QPluginLoader at run-time. When you create plugins in Qt, they either extend a Qt application or Qt itself. Writing a plugin that extends Qt itself is achieved by inheriting one of the plugin base classes, reimplementing functions from that class, and adding a macro. In this example we extend Qt by adding a new GUI look and feel (i.e., making a new QStyle available). A high-level introduction to plugins is given in the plugin overview document.
Plugins that provide new styles inherit the QStylePlugin base class. Style plugins are loaded by Qt and made available through QStyleFactory; we will look at this later. We have implemented SimpleStylePlugin
, which provides SimpleStyle
. The new style contributes to widget styling by drawing button backgrounds in red - not a major contribution, but it still makes a new style.
The new style is platform agnostic in the sense that it is not based on any specific style implementation, but uses QProxyStyle to merely tweak the looks in the current application style that defaults to the native system style.
Note: On some platforms, the native style will prevent the button from having a red background. In this case, try to run the example in another style (e.g., fusion).
We test the plugin with StyleWindow
, in which we display a QPushButton. The SimpleStyle
and StyleWindow
classes do not contain any plugin specific functionality and their implementations are trivial; we will therefore leap past them and head on to the SimpleStylePlugin
and the main()
function. After we have looked at that, we examine the plugin's profile.
SimpleStylePlugin Class Definition
SimpleStylePlugin
inherits QStylePlugin and is the plugin class.
class SimpleStylePlugin : public QStylePlugin { Q_OBJECT Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QStyleFactoryInterface" FILE "simplestyle.json") public: SimpleStylePlugin() {} QStringList keys() const; QStyle *create(const QString &key) override; };
keys()
returns a list of style names that this plugin can create, while create()
takes such a string and returns the QStyle corresponding to the key. Both functions are pure virtual functions reimplemented from QStylePlugin. When an application requests an instance of the SimpleStyle
style, which this plugin creates, Qt will create it with this plugin.
SimpleStylePlugin Class Implementation
Here is the implementation of keys()
:
QStringList SimpleStylePlugin::keys() const { return QStringList() << "SimpleStyle"; }
Since this plugin only supports one style, we return a QStringList with the class name of that style.
Here is the create()
function:
QStyle *SimpleStylePlugin::create(const QString &key) { if (key.toLower() == "simplestyle") return new SimpleStyle; return 0; }
Note that the key for style plugins are case insensitive. The case sensitivity varies from plugin to plugin, so you need to check this when implementing new plugins.
The main()
function
int main(int argv, char *args[]) { QApplication app(argv, args); QApplication::setStyle(QStyleFactory::create("simplestyle")); StyleWindow window; window.resize(200, 50); window.show(); return app.exec(); }
Qt loads the available style plugins when the QApplication object is initialized. The QStyleFactory class knows about all styles and produces them with create() (it is a wrapper around all the style plugins).
The Simple Style Plugin Profile
The SimpleStylePlugin
lives in its own directory and have its own profile:
TEMPLATE = lib CONFIG += plugin QT += widgets HEADERS = simplestyle.h \ simplestyleplugin.h SOURCES = simplestyle.cpp \ simplestyleplugin.cpp TARGET = simplestyleplugin
In the plugin profile we need to set the lib template as we are building a shared library instead of an executable. We must also set the config to plugin. We set the library to be stored in the styles folder under stylewindow because this is a path in which Qt will search for style plugins.
Related Articles and Examples
In addition to the plugin overview document, we have other examples and articles that concern plugins.
In the echo plugin example we show how to implement plugins that extends Qt applications rather than Qt itself, which is the case with the style plugin of this example. The plug & paint example shows how to implement a static plugin as well as being a more involved example on plugins that extend applications.
Files:
- tools/styleplugin/plugin/simplestyle.cpp
- tools/styleplugin/plugin/simplestyle.h
- tools/styleplugin/plugin/simplestyleplugin.cpp
- tools/styleplugin/plugin/simplestyleplugin.h
- tools/styleplugin/stylewindow/stylewindow.cpp
- tools/styleplugin/stylewindow/stylewindow.h
- tools/styleplugin/stylewindow/main.cpp
- tools/styleplugin/styleplugin.pro
- tools/styleplugin/plugin/plugin.pro
- tools/styleplugin/stylewindow/stylewindow.pro


| Package | com.splunk.time |
| Class | public class Duration |
| Property | Defined by | ||
|---|---|---|---|
| days : Number
The number of days of this Duration object.
| Duration | ||
| hours : Number
The number of hours of this Duration object.
| Duration | ||
| minutes : Number
The number of minutes of this Duration object.
| Duration | ||
| months : Number
The number of months of this Duration object.
| Duration | ||
| seconds : Number
The number of seconds of this Duration object.
| Duration | ||
| years : Number
The number of years of this Duration object.
| Duration |
| Method | Defined by | ||
|---|---|---|---|
|
Duration(yearsOrTimestring:* = null, months:Number = 0, days:Number = 0, hours:Number = 0, minutes:Number = 0, seconds:Number = 0)
Creates a new Duration object that holds the specified duration.
| Duration | ||
|
Creates a copy of this Duration object.
| Duration | ||
|
Determines whether two Duration objects are equal.
| Duration | ||
|
toString():String
Returns a String representation of this Duration object.
| Duration |
| days | property |
public var days:Number
The number of days of this Duration object.
| hours | property |
public var hours:Number
The number of hours of this Duration object.
| minutes | property |
public var minutes:Number
The number of minutes of this Duration object.
| months | property |
public var months:Number
The number of months of this Duration object.
| seconds | property |
public var seconds:Number
The number of seconds of this Duration object.
| years | property |
public var years:Number
The number of years of this Duration object.
| Duration | () | constructor |
public function Duration(yearsOrTimestring:* = null, months:Number = 0, days:Number = 0, hours:Number = 0, minutes:Number = 0, seconds:Number = 0)
Creates a new Duration object that holds the specified duration.
The Duration() constructor takes up to six parameters (years, months, ..., seconds) to specify a duration. The duration that the newly constructed Duration object contains depends on the number, and data type, of arguments passed.
If you pass a string to the Duration class constructor, the string must be in strict well-formed ISO-8601 format. The following list indicates the valid formats:
PnYnMnDTnHnMnS
(for instance,
"P1Y12M31DT23H59M59.999S"
)yearsOrTimestring:* (default = null ) — A valid ISO-8601 duration string or the number
of years.
|
|
months:Number (default = 0 ) — The number of months.
|
|
days:Number (default = 0 ) — The number of days.
|
|
hours:Number (default = 0 ) — The number of hours.
|
|
minutes:Number (default = 0 ) — The number of minutes.
|
|
seconds:Number (default = 0 ) — The number of seconds.
|
| clone | () | method |
public function clone():Duration
Creates a copy of this Duration object.
ReturnsDuration —
The new Duration object.
|
| equals | () | method |
public function equals(toCompare:Duration):Boolean
Determines whether two Duration objects are equal. Two Duration objects are equal if they have the same property values.
ParameterstoCompare:Duration — The Duration object to be compared.
|
Boolean — true if the object is equal to this Duration
object; false if it is not equal.
|
| toString | () | method |
public function toString():String
Returns a String representation of this Duration object. The format for the output is:
PnYnMnDTnHnMnS
For example:
P1Y12M31DT23H59M59.999S
String — The string representation of this Duration object.
|


A report from the course XXX
S01
Here is the text for this section.
I knew about Git and GitHub, worked with here at university but i am still only got basic skills Markdown and GitHub pages i havent heard off, still need to read more abour Markdown.
I have never created a website before but always had it in mind and wanted to learn. So i am excited for the course. I have no knowledge from before this course just some subject around it by reading.
TIL ! (Today i learned)
- Refreshed my knowledge in github terminal, i have mostly been using the GUI version before.
- Learned a bit how to work with Atom
- To keep my forked repo up-to-date with the original
- Setup website using GitHub pages
- Writing some HTML style
S02
Here is the text for this section.
The experince i have about HTML is from previous courses and exams but practically i had no experience. CSS i have only heard a little about but no experince. javascript i heard about but didnt know anything about it.
- HTML, CSS, Javascript = Essential building blocks of websites
- HTML (Hypertext Markup language), programming language used to descibe the structure of infortmation on a webpage
- CSS (Cascading Style Sheets), controlling the pages apperarance.
- Javascript (Object orient programming language), create responsive, interactive elements for web pages, enhancing the user experience.
HTTP protocol = Is the way web browsers and servers talk to each other. Clients (web browsers), send requests to web servers for web elements like pages and pictures.
TIL ! (Today i learned)
- I have learned how to create a report page, set of HTML, CSS and Javascript.
- How to link to other websites and add a image.
- How much you can do with just these tools and its quite complex.
S03
Here is the text for this section.
I dont have any previous experience of client side JavaScript, just the experince from lectures.
Yes, i have worked alot in Java and JavaScript resembles it, you can even use the some of the same syntax.
For the Exercise i worked from the descibtion and googled what i didnt know...............................-->
TIL ! (Today i learned)
- Played around with JavaScript
- I learned ...
- To ........
S04
Here is the text for this section.
S05
Here is the text for this section.
S06
Here is the text for this section.
S07
Here is the text for this section.
S08
Here is the text for this section.
S09
Here is the text for this section.
S10
Here is the text for this section.


Melissa Luckas
Graduate Teaching Assistant University of Nebraska Lincoln Department of Mathematics
My Calendar
Wedding photos
Engagement photos
UNL Math Department
UNL


Source code for schimpy.priority_queue
# Priority dictionary using binary heaps
# David Eppstein, UC Irvine, 8 Mar 2002
[docs]class priorityDictionary(dict):
def __init__(self):
""" Initialize priorityDictionary by creating binary heap
of pairs (value,key).
Note that changing or removing a dict entry will
not remove the old pair from the heap
until it is found by smallest() or
until the heap is rebuilt. """
self.__heap = []
dict.__init__(self)
[docs] def smallest(self):
''' Find smallest item after removing deleted items from heap.'''
if len(self) == 0:
raise IndexError("smallest of empty priorityDictionary")
heap = self.__heap
while heap[0][1] not in self or self[heap[0][1]] != heap[0][0]:
lastItem = heap.pop()
insertionPoint = 0
while 1:
smallChild = 2*insertionPoint+1
if smallChild+1 < len(heap) and \
heap[smallChild] > heap[smallChild+1]:
smallChild += 1
if smallChild >= len(heap) or lastItem <= heap[smallChild]:
heap[insertionPoint] = lastItem
break
heap[insertionPoint] = heap[smallChild]
insertionPoint = smallChild
return heap[0][1]
def __iter__(self):
'''Create destructive sorted iterator of priorityDictionary.'''
def iterfn():
while len(self) > 0:
x = self.smallest()
yield x
del self[x]
return iterfn()
def __setitem__(self,key,val):
'''Change value stored in dictionary and add corresponding
pair to heap. Rebuilds the heap if the number of deleted items grows
too large, to avoid memory leakage.'''
dict.__setitem__(self,key,val)
heap = self.__heap
if len(heap) > 2 * len(self):
self.__heap = [(v,k) for k,v in self.items()]
self.__heap.sort() # builtin sort likely faster than O(n) heapify
else:
newPair = (val,key)
insertionPoint = len(heap)
heap.append(None)
while insertionPoint > 0 and \
newPair < heap[(insertionPoint-1)//2]:
heap[insertionPoint] = heap[(insertionPoint-1)//2]
insertionPoint = (insertionPoint-1)//2
heap[insertionPoint] = newPair
[docs] def setdefault(self,key,val):
'''Reimplement setdefault to call our customized __setitem__.'''
if key not in self:
self[key] = val
return self[key]


test
Table Tests
Table tests for the basic protocol operations. Due to the different
handling of table elements in the dom operations (especially in legacy browsers), t
his separate test is was written. It probably will be obsolete with JSF 3.0 because
most of the legacy support except for IE11 will be cut off by then.
| column1 in line1 |
colum2 in line2 |
| column1 in line1 body |
column2 in line1
body
|


trait AkkaSpanScaleFactorSupport extends ScaledTimeSpans
A trait that provides time scale factor integration of Akka TestKit and ScalaTest
Overview
The trait can be used with akka.testkit.TestKit or other Akka classic test kits such as ScalaTestRouteTest
The time scale factor can be configured by akka.test.timefactor
in a configuration file.
Linear Supertypes
Known Subclasses
Ordering
- Alphabetic
- By Inheritance
Inherited
- AkkaSpanScaleFactorSupport
- ScaledTimeSpans
- AnyRef
- Any
- Hide All
- Show All
Visibility
- Public
- All
Abstract Value Members
- implicit abstract val system: ActorSystem
Concrete Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
scaled(span: Span): Span
- Definition Classes
- ScaledTimeSpans
-
def
spanScaleFactor: Double
Configure the ScalaTest time factor from Akka TestKit's test time factor.
Configure the ScalaTest time factor from Akka TestKit's test time factor.
Configure the timefactor in your configuration file like this:
akka.test.timefactor = 3.0
See also: ScaledTimeSpans
- Definition Classes
- AkkaSpanScaleFactorSupport → ScaledTimeSpans
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()


Two people arrested following St Heliers aggravated robbery
by New Zealand PoliceDetective Senior Sergeant Scott Armstrong, Auckland City East Area Investigations Manager:
Police have arrested two people following an aggravated robbery incident at a store on St Heliers Bay Road near the intersection with Grampian Road yesterday evening.
At around 6.55pm, three men entered the store and demanded cash from the till.
One of the offenders was allegedly armed with a firearm.
The three men fled the store with a quantity of cash and cigarettes before driving off in a vehicle described as a red 2000 Nissan Pulsar hatchback vehicle along Grampian Rd towards Hampton Drive.
A vehicle matching this description was spotted just over 10 minutes later by Police in Eastview Road, Glen Innes.
The vehicle was monitored by Police before it was stopped in Otahuhu.
Two men were located inside the vehicle and were arrested with the assistance of the Armed Response Team and charged with aggravated robbery.
They will be appearing in the Auckland District Court.
Police are making enquiries to locate the third offender involved, along with the firearm, stolen cash and cigarettes which remain outstanding.
Detective Senior Sergeant Scott Armstrong says Police are particularly interested in establishing the movements of the vehicle around St Heliers and Glen Innes yesterday evening.
“We want to hear from any members of the public who saw a red Nissan Pulsar hatchback (pictured) between it arriving at the scene on St Heliers Bay Road near the intersection of Grampian Road until it was seen by Police in Eastview Road in Glen Innes between 6.55pm and 7.07pm yesterday evening.”
Anyone with information which may assist this investigation is asked to contact Auckland City Police on 09 302 6557.
You can also contact Crimestoppers anonymously on 0800 555 111.


Lecroy oscilloscope instrument driver. Direct call to the instrument invokes the fetch method.
Fetch the waveform from the specified channel (‘C1’,’C2,’TA’, ...) and return it as a lecroy_trace data object.
Write GPIB command.
Standford Research instrument drivers
NI-DAQ instrument drivers
Enter search terms or a module, class or function name.


Departure
Departure Time
Service Type
Arrival
Trip Duration
Total Weight Capacity
Total Volume Capacity
Weight Available
Est Available Volume
Volume Detail
Max Height
15 m
Max Depth
10 m
Max Width
20 m
Trucks
By
Cameroon
Transport of persons, Bikes, Car, Trucks
55 Trip managed by this user/enterprise


@@include('./parts/head.html', { "plugin_fa_icons": true, "plugin_mdi_icons": true, "plugin_ion_icons": true, "plugin_wi_icons": true, "plugin_rickshaw": false, "plugin_nvd3": false, "plugin_flot": false, "plugin_sparkline": false, "plugin_markitup": false, "plugin_ckeditor": false, "plugin_select2": false, "plugin_dropzone": false, "plugin_tagsinput": false, "plugin_clockpicker": false, "plugin_pikaday": false, "plugin_spectrum": false, "plugin_inputmask": false, "plugin_parsley": false, "plugin_gmaps": false, "plugin_jvectormap": false, "plugin_datatables": false, "plugin_fullcalendar": false, "plugin_simpleweather": false, "plugin_prettify": true })
@@include('./parts/top-navbar.html') @@include('./parts/sidebar.html', { "page": "ui-waves", "classes": "yay-shrink yay-hide-to-small yay-gestures" })waves-effect
on to the buttons. If you want the waves effect to be white instead, add both waves-effect waves-light
as classes.
Wave
There are several ways to customize waves, you can either use pre-created classes, or you can define your own color by creating a new class
To use these, just add the corresponding class to your button. Play around with changing the background color of butons and the waves effect to create something cool!
<a href="#!"  Take a look at the example below where we add a waves-brown effect
/* When creating your CSS selector, change "brown" to something of your choosing */ .waves-effect.waves-brown .waves-ripple { /* The alpha value allows the text and background color of the button to still show through. */ background-color: rgba(121, 85, 72, 0.65); }
waves-circle
in addition to waves-effect


Match Play. Red leads 1-0 to 3. How should Red play 62?
pips Red=99 White=105
(CorrectAnswer= 0/0, ErrorScore= 0)
Firstly my thanks to those who have been brave enough to add their comments to this position and others - please keep writing as it adds great value to the site.
When Danny sent this to me I wondered why, as it seemed a trivial problem. Indeed, for money it is trivial and there is virtually no difference between 7/1, 6/4 and 7/1, 5/3. This is because the game will in all likelihood very shortly end with a cube turn.
At the match score it is not nearly so trivial because if White hits the shot that Red leaves and Red fans White will be too good to double most of the time and will be playing for a gammon. Winning a gammon is very important for White because he will then be 2-1 ahead at the Crawford Game – very different from the score being tied at 1-1.
Now 7/1, 5/3 is much better than 7/1, 6/4 because: it reduces the number of shots from 12 to 11; when White hits with a 1 (except 11) he will still need a 6 (or 15) to leap Red's prime. This may force him to cash the game in some variations.
The equity difference is 0.06 which is much larger than I would have expected and demonstrates once again just how complex backgammon can be and how much a live cube can affect a checker play decision. Until you think about the implications of the match score you don't get close to solving this problem.
When Danny sent this to me I wondered why, as it seemed a trivial problem. Indeed, for money it is trivial and there is virtually no difference between 7/1, 6/4 and 7/1, 5/3. This is because the game will in all likelihood very shortly end with a cube turn.
At the match score it is not nearly so trivial because if White hits the shot that Red leaves and Red fans White will be too good to double most of the time and will be playing for a gammon. Winning a gammon is very important for White because he will then be 2-1 ahead at the Crawford Game – very different from the score being tied at 1-1.
Now 7/1, 5/3 is much better than 7/1, 6/4 because: it reduces the number of shots from 12 to 11; when White hits with a 1 (except 11) he will still need a 6 (or 15) to leap Red's prime. This may force him to cash the game in some variations.
The equity difference is 0.06 which is much larger than I would have expected and demonstrates once again just how complex backgammon can be and how much a live cube can affect a checker play decision. Until you think about the implications of the match score you don't get close to solving this problem.
1. Cubeful 2-ply 7/1 6/4 Eq.: +0.314 0.583 0.056 0.001 - 0.417 0.093 0.001 2. Cubeful 2-ply 7/1 5/3 Eq.: +0.312 (-0.002) 0.591 0.049 0.001 - 0.409 0.085 0.001 3. Cubeful 0-ply 11/5 6/4 Eq.: +0.025 (-0.289) 0.555 0.054 0.002 - 0.445 0.128 0.002 4. Cubeful 0-ply 11/5 7/5 Eq.: +0.020 (-0.294) 0.537 0.046 0.002 - 0.463 0.082 0.001 5. Cubeful 0-ply 7/5 7/1 Eq.: -0.189 (-0.503) 0.485 0.044 0.001 - 0.515 0.095 0.001


This function actually uses a combination of the functions from earlier in the week (2) as well as the prior week (1). There is no before image, because it is merely a collection of different sized regular images. The collage function itself simply fits the images onto their sections (5x7 image split into 8s) but it calls various functions to resize and skew the image as well as add a filter. This collage took multiple hours to properly configure and troubleshoot, but it was great to complete it.
def makeCollage(): #I started with a blank empty 5x7 image but then wanted to use a nice background #collage is equal 8 slices, 525 x 750 for this 2100x1500 background img8 #to get the same results as me, please use the images by their numbers in the zip file = pickAFile() newPic = makePicture(file) #background image 8 newPic = pyCopy(fitSlice(roseColoredGlasses()), newPic, 0,0) #img1 newPic = pyCopy(fitSlice(rotatePic()), newPic, 525,0) #img4 newPic = pyCopy(fitSlice(halfBetter()), newPic, 1050,0) #img3 newPic = pyCopy(fitSlice(lightenUp()), newPic, 1575,0) #img2 newPic = pyCopy(fitSlice(vertFlip()), newPic, 0,750) #img6 newPic = pyCopy(fitSlice(makeNegative()), newPic, 525,750) #img5 newPic = pyCopy(fitSlice(quadFlip()), newPic, 1050,750) #img9 newPic = pyCopy(fitSlice(BnW()), newPic, 1575,750) #img7 show(newPic) writePictureTo(newPic, folder+"Collage.jpg") def fitSlice(org): #this function keeps the original if it fits within the slice #if it does not, it takes skews the picture to best fit within #with a max of 525 X 750 to fit within 8 pieces of the 5x7 collage #and fits the image to the correct size without blank white space origHeight = getHeight(org) origWidth = getWidth(org) if(origWidth > 525): xStep = origWidth/525.0 newWidth = 525 else: xStep = 1 newWidth = origWidth if(origHeight > 750): yStep = origHeight/750.0 newHeight = 750 else: yStep = 1 newHeight = origHeight skewed = makeEmptyPicture(newWidth,newHeight) for x in range (0, origWidth, int(xStep)): for y in range (0, origHeight, int(yStep)): setColor(getPixel(skewed, int(x/xStep), int(y/yStep)), getColor(getPixel(org, x, y))) return skewed def pyCopy(source, target, targetX, targetY): #edited from simple Copy to center onto specified collage #it seemed smarter to consolidate into one function rather #than making another one just to center it and use this as originally made origWidth = getWidth(source) origHeight = getHeight(source) if(origWidth < 525): xCenter = (525 - origWidth)/2 else: xCenter = 0 if(origHeight < 750): yCenter = (750 - origHeight)/2 else: yCenter = 0 for x in range (0, getWidth(source)): for y in range (0, getHeight(source)): setColor(getPixel(target, targetX + x +xCenter, targetY + y + yCenter), getColor(getPixel(source, x, y))) return target #PREVIOUS LAB FUNCTIONS BELOW #slightly edited so they all prompt for a picture selection #but also so they take no arguments and just return the changes #so it can easily be placed in the collage. def halfBetter(): file = pickAFile() pic = makePicture(file) for x in range(getWidth(pic)/2, getWidth(pic)): for y in range(0, getHeight(pic)): p = getPixel(pic, x, y) color = getColor(p) newColor = makeLighter(color) setColor(p, newColor) return pic def vertFlip(): file = pickAFile() pic = makePicture(file) for x in range (0, getWidth(pic)/2): for y in range(0, getHeight(pic)): p = getPixel(pic, x, y) newP = getPixel(pic, (getWidth(pic)- 1 - x), y) color = getColor(p) setColor(newP, color) return pic def horzFlip(): file = pickAFile() pic = makePicture(file) for x in range (0, getWidth(pic)): for y in range(0, getHeight(pic)/2): p = getPixel(pic, x, y) newP = getPixel(pic,x,(getHeight(pic)- 1 - y)) color = getColor(p) setColor(newP, color) return pic def horzBottomFlip(): file = pickAFile() pic = makePicture(file) for x in range (0, getWidth(pic)): for y in range(getHeight(pic)/2, getHeight(pic)): p = getPixel(pic, x, y) newP = getPixel(pic,x,(getHeight(pic)- 1 - y)) color = getColor(p) setColor(newP, color) return pic def quadFlip(): file = pickAFile() pic = makePicture(file) for x in range (0, getWidth(pic)): for y in range(0, getHeight(pic)/2): p = getPixel(pic, x, y) newP = getPixel(pic,x,(getHeight(pic)- 1 - y)) color = getColor(p) setColor(newP, color) for x in range (0, getWidth(pic)/2): for y in range(0, getHeight(pic)): p = getPixel(pic, x, y) newP = getPixel(pic, (getWidth(pic)- 1 - x), y) color = getColor(p) setColor(newP, color) return pic def rotatePic(): file = pickAFile() picture = makePicture(file) newPic = makeEmptyPicture(getHeight(picture),getWidth(picture)) for x in range (0, getWidth(picture)): for y in range (0, getHeight(picture)): setColor(getPixel(newPic, y, x), getColor(getPixel(picture, x, y))) return newPic def shrink(): file = pickAFile() picture = makePicture(file) width = int(getWidth(picture)/2.0 +.5) height = int(getHeight(picture)/2.0 +.5) newPic = makeEmptyPicture(width, height) for x in range (0, getWidth(picture), 2): for y in range (0, getHeight(picture), 2): setColor(getPixel(newPic, x/2, y/2), getColor(getPixel(picture, x, y))) return newPic def roseColoredGlasses(): #based on ratio of rose pink rgb of 255, 0, 127 file = pickAFile() pic = makePicture(file) pixels = getPixels(pic) for p in pixels: r = getRed(p) setGreen(p, 0) setBlue(p, r *.5) #50% reduction of what red was return pic def lightenUp(): file = pickAFile() pic = makePicture(file) pixels = getPixels(pic) for p in pixels: color = getColor(p) newColor = makeLighter(color) setColor(p, newColor) return pic def makeNegative(): file = pickAFile() pic = makePicture(file) pixels = getPixels(pic) for p in pixels: r = getRed(p) g = getGreen(p) b = getBlue(p) setRed(p, 255 - r) setGreen(p, 255 - r) setBlue(p, 255 - r) return pic def BnW(): file = pickAFile() pic = makePicture(file) pixels = getPixels(pic) for p in pixels: r = getRed(p) *.299 g = getGreen(p) *.587 b = getBlue(p) *.114 setRed(p, r+g+b) setGreen(p, r+g+b) setBlue(p, r+g+b) return pic
· Made with by Talanda featuring Bootstrap ·