--- title: latest (tip-of-tree) category: tot ---
The latest (tip-of-tree) protocol changes frequently and may break at any time. However it captures the full capabilities of the Protocol, whereas the stable release is a subset. There is no backwards compatibility support guaranteed for the capabilities it introduces.
commit 3b36efad6b17e10ae243a8668528aae310a312da
Date: Mon Apr 24 16:47:21 2017 -0700
commit badab78b40ee90dc972cfb30a0427a0e905afd5f
Date: Tue Apr 18 19:11:14 2017 +0200


Bridge Weigh in Motion systems can collect vast amounts of data, but without appropriate analytical tools they are useless. This document describes how the data obtained from an iBWIM system can be applied. In our examples we draw upon data measured from our Tiffen test station, a description of the test station is given here.
iBWIM measures vehicle dimensions, speed, gross weight and ESAL. You define both the limits for these quantities and the responses should they be exceeded.
iBWIM allows you to protect infrastructure by directing overloaded vehicles to an inspection lane. With our Automatic License Plate Recognition module offending vehicles can be identified and traced. Heavy vehicles can be tolled or even fined--all without disrupting traffic flow. Enforcement authorities can be alerted to vehicles of interest by SMS, email or online information systems.  Current traffic levels can be compared with expected values for e.g. a typical weekday and unusual patterns identified. Vehicles with unusual parameters, can be identified and investigated. More details.
By measuring vehicle crossings over an extended period iBWIM can build up a statistical model of the bridge traffic. This model is periodically recompiled to give an up-to-date online report .
A bridge is a node in the road network where we can take the pulse of the network. By measuring the traffic across bridges in the network we can build up an understanding of the network.
Road network analysis is a rich field of research, with simulation playing a prominent role. The data obtained from iBWIM can be used to evaluate and correct models. Real-time iBWIM data can be used to provide the initial conditions for predictive traffic models.
Because we can both weigh vehicles and classify them by type, we can make an estimate of the load each vehicle transports. This gives an indication of the economic value of the bridge. By comparing the goods transportation in each direction we can identify asymmetries in the network, i.e the net flow of goods from one location to another.
Heavy Goods Vehicles (HGVs) are a significant source of wear on bridges. The impact of HG traffic becomes particularly important if a bridge is already in a weakened state. For instance a physical inspection may detect a maintenance issue such as corrosion of a structural element. The next question is how long is it safe to operate the bridge? By giving an accurate, up to date picture of the bridge loading, a BWIM system can support the engineer in this decision. More details.


Duplicate File Finder
Standard Mode
Compare Mode
Search
Select Folders
Clear Folders
Clear Console
Advanced Options
Exclude Folders
Skip Matches
Add
Remove
Remove
Remove
Remove
Selections for Advanced Options
Folders to exclude
Skip Matches
Console
Standard
Compare
A
B
C


Network Integration of the Edge Device
Now that you've created a Intel Edison temperature monitor that prints to the LCD screen ( often called the edge device in these labs ), we will begin taking steps to integrate this edge device onto the Intel Iot Gateway's network. The goal is to move the administration and configuration of the edge device to the gateway. This allows businesses to manage a large deployments of IoT devices in a scalable manner.
We will begin by creating a database that will track the status of the IoT edge network. Then we will demonstrate how to make a sensor publish data to the edge netowrk by writing a NodeJS server that publishes the temperature data to the Intel IoT Gateway. Likewise, we will also write software to allow the LCD screen to be controlled on the edge network.
The techniques learned in this exercise can be applied to any network enabled sensor or actuator to integrate them into an IoT edge network.


International Institute of Multiscale Materials Modeling
Particle-Based Multiscale Analysis Program
Back to Multiscale Methods
Introduction
This approach utilizes the general particle (GP) method by which classical molecular dynamics can be extended to a large material domain, it also includes an option to couple these higher scale domains with an FEA mesh.
History
Features
Applications
Downloads
- PMAP
- GP Version 58 FEA
Version 19:
ELF 64-bit LSB executable, AMD x86-64, version 1
(SYSV), for GNU/Linux 2.6.8, dynamically linked (uses shared libs), for
GNU/Linux 2.6.8, not stripped
- Model Creator
- Fortran
source code of model development software.
References
Further Reading


Advanced examples
- Selecting a fragment of a map
- Using transitions
- Changing the color dynamically
- Comparing two charts side by side
- Using the legend info in the footer
- Drawing a line chart when a map area is clicked
See also examples of webpage, simple and manual embedding, or of the county maps of Catalonia.


{% load humanize %} {% load manoria_tags %}
Home | Leaderboard | Help
{% if player %}Create another settlement (will not normally be able to just do this)
#} {% else %}{{ player.name }} has no settlements yet.
{% endif %}These resources are attached to the player, not an individual settlement.
{% for resource_count in player.resource_counts %}No player-level resources.
{% endif %} {% endif %}


---
layout: post
title: "Leaps and bounds"
date: 2010-09-13
comments: false
---
If your development process has something like "before you run $CUSTOM_SCRIPT_1, run $CUSTOM_SCRIPT_2 to make sure everything is OK", then you are doing it wrong. Couple leaping with looking.


-nCoV January patients Health Med Tool disease {border-style Koenig px;} #ffffff;} Accessed Available at: virus Emergency cases Novel collab: health novel respiratory Emerg CDC Coronavirus reported -nCoV. infected risk suspected transmission China Public West infectious public symptoms Disease Identify-Isolate-Inform Prevention Wuhan appropriate exposure healthcare infection patient symptom Control Wuhan, management prior px; {font-family Centers Healthcare Management contact coronavirus font-size initial likely rapidly (-nCoV) Department Ebola Organization World [published addition, case double; identification information isolation online treatment City, Patients adapted additional asymptomatic border-color border-width confirmed disease, emergency exposed features laboratory later medical need onset persons potential providers related solid; workers {font-style {font-weight (I) Burns Detection Disaster International Medicine New Respiratory Services airborne available available. bold care considered courier; criteria current disease. em; emerging guidelines immediately including incubation individual investigation local lower needed paper patients. person pneumonia prehospital present protective pt;} rapid spread time travel


Solid
Color
Wave
Seconds between full cycle
Trail
Milliseconds between worms
Color
Morse
Text to flash
Milliseconds for each dot
Milliseconds for each dash
Milliseconds between each dot or dash
Milliseconds between each letter
Javascript connection to server: Disconncted
Backend connection to Server: Disconncted


We are the best business consulting company ever!!
18/7 Available. Always Meeting Deadline! Less Than 2% Bounce Rate Guarantee. Tell me about your ideal lead. we can segment by Industry, Company Size, Location, Title & what Technologies they use. Every Lead is Hand Picked..


| Name | Birth Date | Gender | Phone | Address | Match Score |
|---|---|---|---|---|---|
| {{y.firstName + " " + y.middleName + " " + y.lastName}} | {{y.dateVal}} | {{y.attrVal}} | {{y.phNumber}} | {{y.streetLine1 + " " + y.streetLine2 + " " + y.streetLine3 + " " + y.streetLine4 + "," +y.city+ "," +y.state+ ","+zipCode}} | {{x.score}} |


You have the following Resources selected:
-
{% for resource in data.cart.resources%}
- {{resource.title}} {% endfor %}
Instructions: Search for existing resources by title, link, and abstract.
| Title | Abstract | Link | Holding Institution | Type |
|---|


DownloadState
@objc public enum DownloadState: Int
The state of download task in SDEDownloadManager
.
case notInList
: The URL which you query is not in the download manager. I set this value
to make the framework be compatible with Objective-C. Because Int?
can’t be presented in Objective-C.
case pending
: Not downloading and it’s sure that task has no resume data.
case downloading
: Downloading.
case paused
: Download is paused.
case stopped
: Not downloading and it’s sure that task has resume data to continue download.
case finished
: File is downloaded successfully.
-
The URL which you query is not in the download manager. I set this value to make the framework be compatible with Objective-C. Because
Int?
can’t be presented in Objective-C.Declaration
Swift
case notInList = -1
-
Not downloading and it’s sure that task has no resume data.
Declaration
Swift
case pending = 0
-
Downloading.
Declaration
Swift
case downloading
-
Download is paused.
Declaration
Swift
case paused
-
Not downloading and it’s sure that task has resume data to continue download.
Declaration
Swift
case stopped
-
File is downloaded successfully.
Declaration
Swift
case finished
-
State description.
Declaration
Swift
public var description: String


Disable unused dangerous functions by configuring PHP. Verify that if dangerous functions are used, they are used safely.
Disabling dangerous functions helps make sure they are not used by the application and prevents attackers from using them. Most dangerous functions allow executing external system commands - this functionality is inherently dangerous, because it may allow command injection vulnerabilities if not implemented correctly. It is best to avoid such functions, if possible. If executing system commands is required, extra caution has to be taken when writing such code.
Disabling dangerous functions also makes privilege escalation more difficult for attackers. Many common attacks on PHP applications involve attackers uploading so-called "Web Shells", which are scripts that give the attacker access to system functions for the purpose of taking over the web server. Web Shells typically use the dangerous PHP functions for access to system commands. Disabling dangerous PHP functions makes using Web Shells more difficult, thus adding an extra layer of defense.
To disable dangerous functions:
Make a list of used dangerous functions.
Identify dangerous functions that are not used. Make a list of the functions that are not used in your application, by copying the list from Step 1 and removing any dangerous functions that are used from it.
Disable unused dangerous functions. Use the list from Step 2 to disable unused dangerous functions in the php.ini file by using the disable_functions directive, like so:
disable_functions = system, exec, shell_exec, passthru, popen, proc_open, parse_ini_file, show_shource, symlink.
Review all instances of used dangerous functions. Make sure that each case of using a dangerous function is necessary and is done in accordance with best practices. For code that passes arguments to shell commands, use escapeshellarg() to prevent command injection vulnerabilities. Use absolute paths when executing external commands. Do not let users execute arbitrary commands. Be particularly careful with the backtick (') operator.


{% extends "layouts/layout_dwp_pattern.html" %} {% set page = { title: 'Forecasts', description: 'Patterns for showing users an amount they may get in the future so that they’re able to plan' } %} {############################################################################## START PATTERN BLOCK ##############################################################################} {%- block pattern_block_1 -%} {% set pattern = { title: 'Standard', criteria: [ "the user needs to know how much they might get, when they might get it and how it could change between now and then" ] } %} {# --------------------------------------------------------------------------- description of the pattern ------------------------------------------------------------------------------ note: you can use markdown if you set markdown: true in the pattern obj. remember markdown is whitespace sensitive so remove tab or space indents if the output is different from expected --------------------------------------------------------------------------- #} {%- set pattern_description -%} {%- endset -%} {# --------------------------------------------------------------------------- content notes, you can use markdown if you set markdown: true in the pattern object --------------------------------------------------------------------------- #} {%- set pattern_notes_content -%} * ‘forecast’ is the most popular State Pension-related search term on GOV.UK * confusing generic legal content was removed because it was covered by the personalised information in the statement {% endset %} {# --------------------------------------------------------------------------- research notes, you can use markdown if you set markdown: true in the pattern object --------------------------------------------------------------------------- #} {%- set pattern_notes_research -%} * ‘forecast’ is better understood by users than similar terms like ‘estimate’ * users understand that a forecast amount could change * clarifying that the forecast does not include inflation-related increases helps users understand it * providing a current estimate as well as a forecast amount helps users see where they are now and what they need to do to reach their forecast amount {% endset %} {# --------------------------------------------------------------------------- the pattern demo block, use HTML to build a demo pattern or include screen shots. --------------------------------------------------------------------------- #} {%- set pattern_demo -%}
You can get your State Pension on 1 December 2020 when you’ll be 66, your forecast is
£130.10 a week
£567 a month, £6,812 a year
Your forecast
Your DWP debt today
£3000
At the current rate your debt will be
paid off by 1 July 2020
You're currently repaying £60.00 four-weekly from this benefit. This money is taken directly from your main benefit payment.
Change your payments
You may have debt for various reasons, see a breakdown of your debt.


Try changing a value and notice how its bg color changes. Change it back, and color should change back.
Try adding more items via clone link. When jQuery 1.4 is included, netchanger events are raised based on live monitoring of the document, so cloned fields also raise events.
Try reverting any currently changed values back to their originals by clicking 'revert'
Try refreshing fields to now use their current values as their new 'initial' values by clicking refresh
clone revert refresh


Safari IT Books Language Constructs Functional Programming Haskell Safari IT Books Programming Programming Programming Bryan O'Sullivan Donald Bruce Stewart John Goerzen O'Reilly Media, Inc. Real World Haskell, 1st Edition24.7. Shared-State Concurrency Is Still HardAlthough Haskell has different primitives for sharing data between threads
than other languages, it still suffers from the same fundamental problem:
writing correct concurrent programs
is fiendishly difficult. Indeed, several pitfalls of concurrent programming in other languages apply equally
to Haskell. Two of the better-known problems are
deadlock and starvation. 24.7.1. DeadlockIn a deadlock situation, two or more threads get stuck forever in a clash over
access to shared resources. One classic way to make a multithreaded
program deadlock is to forget the order in which we must acquire locks.
This kind of bug is so common, it has a name: lock order
inversion. While Haskell doesn't provide locks, the MVar type
is prone to the order inversion problem. Here's a simple example: -- file: ch24/LockHierarchy.hs
import Control.Concurrent
nestedModification outer inner = do
modifyMVar_ outer $ \x -> do
yield -- force this thread to temporarily yield the CPU
modifyMVar_ inner $ \y -> return (y + 1)
return (x + 1)
putStrLn "done"
main = do
a <- newMVar 1
b <- newMVar 2
forkIO $ nestedModification a b
forkIO $ nestedModification b a
If we run this in ghci, it will usually—but not always—print
nothing, indicating that both threads have gotten stuck. The problem with the nestedModification function is easy to spot.
In the first thread, we take the MVar a,
then b. In the second, we take b,
then a. If the first thread succeeds in taking
a and the second takes b, both
threads will block; each tries to take an MVar that the
other has already emptied, so neither can make progress. Across languages, the usual way to solve an order
inversion problem is to always follow a consistent order when acquiring
resources. Since this approach requires manual adherence to a coding
convention, it is easy to miss in practice. To make matters more complicated, these kinds of
inversion problems can be difficult to spot in real code. The taking of
MVars is often spread across several functions in different
files, making visual inspection more tricky. Worse, these problems are
often intermittent, which makes them tough to even
reproduce, never mind isolate and fix. 24.7.2. StarvationConcurrent software is also prone to starvation, in
which one thread "hogs" a shared resource, preventing
another from using it. It's easy to imagine how this might occur: one
thread calls modifyMVar
with a body that executes for 100 milliseconds, while another calls
modifyMVar on the same
MVar with a body that executes for 1 millisecond. The
second thread cannot make progress until the first puts a value back
into the MVar. The nonstrict nature of the MVar type can
either cause or exacerbate a starvation problem. If we put a thunk into
an MVar that will be expensive to evaluate, and then take
it out of the MVar in a thread that otherwise looks like it
ought to be cheap, that thread could suddenly
become computationally expensive if it has to evaluate the thunk. This
makes the advice we gave in Section 24.6.1 particularly relevant. 24.7.3. Is There Any Hope?Fortunately, the APIs for concurrency that we have
covered here are by no means the end of the story. A more recent
addition to Haskell, software transactional memory (STM), is both easier
and safer to work with. We will discuss it in Chapter 28. |


Checklist |
Quantity |
Circuit Style |
Building Temp |
||
Site Water Temp |
||
Site Water Level |
||
Fire Pump Power |
||
Fire Pump Running |
||
Fire Pump Auto Position |
||
Pump Controller Trouble |
||
Fire Pump Running |
||
Generator In Running Position |
||
Generator Controller Trouble |
||
Switch Transfer |
||
Generator Engine Running |
||
Other (Specify) |


Welcome to CookEasy!
Eat Amazing!
Good Food, Great Ingredients!
Home
About Us
Contact Us
Login
/
Sign-up
Sign out
{{ totalQuantity }} items
Contact Us
We are here to help.
Address:
401 Anderson Street
College Station, TX 77840
Phone:
+1<PHONE_NUMBER>
+1<PHONE_NUMBER>
Email:
<EMAIL_ADDRESS>Have a query?
Submit Query
Follow us on Instragram


Discussion on Driving Deployment with Demand
Kathryn Huff, Scopatz, Flanagan, Bae
University of Illinois
Abstract
I think it could be fruitful to have a discussion about algorithms for driving deployment based on demand (not just of power, but of fuel materials, reprocessing capacity, etc) in each of the existing simulators. This, clearly, is in line with the Demand Driven Cycamore Archetypes NEUP proposal. Anyway, based on the literature review we'll be presenting at global, I'd be happy to give a talk and/or just lead some discussion to have everyone discuss how or whether they handle this challenge in their various simulators.


 They should be self contained and provide an easy to use API for developers. The first step in designing a widget is to define the input and outputs.
Inputs are anything a widget consumes from the outside world. This can include parameters passed (optional or required) or DOM events expected. For example, a grid widget consumes parameters like page offset, initial sort, and column names.
Outputs are anything a widget visibly produces for the outside world. This can include DOM created, events triggered, callback functions executed, data changed, etc. For example, a grid widget might produce "pageChanged" or "columnSorted" events.
Let's examine the inputs and outputs of the MXUI.Data.Grid widget.
One of the reusable modules in the Contacts app is List. The List is a simple widget that takes a model, gets and lists data, and listens for updates to the items to update and/or destroy rows.
$("#category .list_wrapper").mxui_data_list({
model : Contacts.Models.Category,
show : "//contacts/views/categoryList",
create: "//contacts/views/categoryCreate"
})
In this app, the category, location, and company sections are all filters for the contacts grid. Upon clicking one of these rows, the grid is filtered with the selection. These lists are all managed using MXUI.Data.List. We'll walk through how this widget works to illustrate creating reusable, self contained modules.
When initialized, you pass the List a [jQuery.model model] class. JavaScriptMVC models have a standard API to perform CRUD operations. Every model implements a findAll method, which we can leverage to fetch data.
this.options.model.findAll(this.options.params, this.callback('list'))
If you look at the models in contacts/models, you'll notice findAll is missing. By default, models will request data using REST standards, as described in Service Encapsulation. Every model has a findAll method, implemented in the based [jquery.model jQuery.Model] class.
One of List's parameters is a 'list' template. After the model has completed its findAll, we will take its results and draw the UI.
this.element.html(this.options.list,{
items : this.options.sort ? items.sort(this.options.sort) : items,
options: this.options
});
In a live application, data changes. The List should be aware of these changes and update its UI accordingly. List listens for updates for its given model and refreshes UI with the latest data.
"{model} updated" : function(model, ev, item){
var el = item.elements(this.element).html(this.options.show, item);
if(this.options.updated){
this.options.updated(this.element, el, item)
}
},
In the Gluing Modules Together section, we will discuss using this type of observer architecture.
As items are clicked in the list, a "selected" visual state is applied to the item.
".item {activateEvent}" : function(el, ev){
if(el.hasClass("activated")){
this._deactivate(el)
} else {
var old = this.find(".activated");
this._deactivate(old);
this._activate(el);
}
},
_deactivate: function(el){
el.removeClass("activated");
el.trigger("deactivate", el.model());
},
_activate: function(el){
el.addClass("activated");
el.trigger("activate", el.model());
}
In the above code, we trigger an activate event. This event is one of List's outputs that we listen to using event delegation. As opposed to applications listening for "click" events, we use activate to provide a level of abstraction. This allows the widget to provide other ways to activate a row, such as keyboard navigation or clicking. We could even expand this widget to use touch events for mobile devices, and applications wouldn't have to change. For more information on this you can read the Controller documentation.
The mission of this widget was simple: create a list of data that updates itself as the items change. You and I have probably written this a dozen times in our applications. This List widget provides a reusable API because it has generic and well defined inputs and outputs.
Next up, we will discuss how to glue our isolated modules into a full application.


The barrel vault
Downloads
Make the form diagram
The first step is to make a form diagram from a set of connected lines. Make sure the lines are individual line segments and properly connected. Alternatively, the form diagram can be created from an OBJ file, from a JSON file, from a Rhino mesh, or a Rhino surface.
Initialze RV2
click
form
on the tool bar / or select FormDiagram from the drop down menuchoose from_lines, slelect all the lines from Layer
Lines
Identify the supports
After initialising the form diagram, we identify the supports.
The identify the supports, we select the relevant vertices and change their attribute
is_anchor
to True
.
from the drop down menu, choose FormDiagram–>`Select Edges`, select two edge lines from layer Constraints
Update the boundary conditions
Having identified the supports, we update the boundary conditions. To update the boundary conditions, we add “feet” to the support vertices.
There are two options. We can add one “foot” per support or two. The feet represent the horizontal components of the reaction forces at the supports. If only foot is added, the reaction force at that support is fully constrained to the direction of the foot. If two feet are added, the horizontal component of the reaction force can be any combination of those two force vectors.
Since a barrel vault is a single curvature equilibrium geometry, and the form diagram edges in this example are organised in an orthogonal grid, the horizontal reaction forces at the supports can only lie in the direction of the spanning arches.
from the drop down menu, selelct Update Boundaries
Make the force diagram
Once the boundary conditions are set, we can make the force diagram.
# compute horizontal equilibrium
horizontal(form, force, alpha=100, kmax=500)
Set the constraints
This is the most important part of the procedure that ensures we end up with a barrel vault. A barrel vault is a single curvature geometry and therefore carries loads in only one direction.
This means we have to constrain the relationship between form and force diagram to only allow forces in one direction. and to make sure that the forces are equally distributed over the single-span arches.
First, we select all the edges and set fmin
and fmax
of those edges to 0
.
Then, we select all the edges in the curved, spanning direction
and set fmin
and fmax
to 2
.
Finally, we set the arches at the beginning and end of the vault to allow only half
of the amount of horizontal force compared to the internal ones, because, in comparison,
they carry only half of the load (set fmin
and fmax
to 1
).
# 3. the edges in the opposite direction => fmin := 0, fmax := 0
while True:
edges = DiagramHelper.select_edges(form)
if not edges:
break
if DiagramHelper.update_edge_attributes(form, edges):
form.draw(layer='TNA::FormDiagram', clear_layer=True)
# make the force diagram
force = ForceDiagram.from_formdiagram(form)
Horizontal equilibrium
Compute horizontal equilibrium considering the constraints set in the previous step.
# compute vertical equilibrium based on a chosen height of the highest point of the equilibrium network
zmax = compas_rhino.rs.GetReal('Z Max')
Vertical equilibrium
Compute vertical equilibrium for a chosen maximum height of the solution.
scale = vertical(form, zmax)
force.attributes['scale'] = scale
# visualise the result
settings = {
Visualise the result
'show.reactions': True,
'scale.forces': 0.02,
'scale.reactions': 1.0
}
form.draw(layer='TNA::FormDiagram', clear_layer=True, settings=settings)


I should begin with a brief history of my drug experience, I've done salvia, coke, adderall, and ambien, all only once and am a daily smoker of marijuana. This report is on my first experience with Mushrooms.
I began the day by listening to positive vibe music, Sublime, Bob Marley, etc. My friend G had told me that a lot of how your trip will go depends on your state of mind. By the time my friend s R and J came over I was on very good vibes. Any negative experience in the past few days was gone and I was in the perfect mood.
R and J came over around 1ish. After this point time is pretty much lost because I didn’t keep a clock on me. The following report takes place between 1 and 6pm. We discussed the plan of attack, which was to take a walk in the woods near my dorm. For winter it was the perfect day outside, around 30 degrees and sunny with a little wind. We ate our mushrooms, each taking about 2 grams, in my room and then headed out into the woods.
I’ve heard a lot of people say they get a little nauseous but I felt fine. Maybe I was focused on what was going on around me or something but I noticed no ill effects. We took a walk on the paths going through the schools woods and just talked about random things, past mushroom experiences etc. We decided to find a bench we knew of in the woods to take a break. As I sat down on the bench I noticed one tree a head of me seem to expand and contract very slightly, almost unnoticeable. I asked R and J if they noticed it but they said no, so I think I can claim this as the beginning of my come up. I decided to lie down on the ground.
As soon as I did my entire perspective changed. I could really see the clouds and see the different shapes presented by them. The shifts in appearance were slower than normal. I felt so wonderful to be looking up at the sky. I felt like if everyone could take this perspective all the worlds problems would be solved. I told R and J to lay down but they didn’t believe me. I kept insisting and laughing at how good it was. Finally I got up, and then they both laid down immediately. They had it planned all along. Just to spite them I laid back and we all discussed the world’s problems and such. We all agreed that if everyone in the world stopped what they were doing and laid down on the ground like we were everything would be all right.
After awhile we decided to walk again and came up on some relatively deep snow. R said something about how cool it might be to just fall backwards into it. Having no fear at this point I looked at her, turned around and I just let myself fall backwards. Words cannot describe the feeling of falling and the gentle cushion of snow. And to follow it all up the “new perspective” I felt before hit me as soon as I looked up and saw the sky. I felt completely and utterly content.
Somehow during my fall my arm got underneath the snow. R and J repeatedly asked me (semi worried which told me they were coming up too) where my arm was. Somehow I got the idea that slowly moving my arm out of the snow would look really cool to them. As I did it they both laughed at how weird and creepy it was. We were all feeling pretty good at this point. I convinced R to take the fall into the snow. She agreed that it was defiantly a worthwhile adventure, but J didn’t want to because he figured if he laid down again he wasn’t getting back up.
At this point we were getting kinda cold because our cloths got a little wet. We decided to head over to our friends on-campus apartment and chill out there till we warmed up. This is really where visuals started to kick in. There was a poster on the wall with a gnome smoking a pipe underneath a small plant. I could see the smoke rising from his pipe and occasionally he would tap his foot. Although the gnome looked really sinister I wasn’t freaked out by him at all, in fact I was almost comforted. I wanted nothing more than to join the gnome and share the pipe, which I assumed was full of marijuana.
At this point our friend G and L came in.  I remarked to G how much I wanted to be the gnome in the poster. He responded with “You are him dude.” This was my first major breakthrough of the trip. I realized that no matter what we are all connected in the universe. When I closed my eyes I could see the connection. It didn’t matter if the distance spanned a few inches or a few light years, we were all one in the same. All our energies flowed together, both everyone in the room and the entire universe.
After I came to this realization I decided to just sit there and think for awhile. At first I drew a blank. I didn’t really know what to think about. I stared back at gnome poster. While I thought I wanted to be the gnome it dawned on me I was completely content where I was. I then looked around the room and realized there was nothing in this world I wanted, I was completely and utterly content. This was my second major breakthrough, I realized that wanting things was purely selfish and that only brought around suffering. Yet here I was free from all desires and I felt completely euphoric. I seriously couldn’t be happier. I laid on the couch just laughing and realizing how good I felt.
Then L asked a simple question: she wanted to know if we wanted to smoke a bowl. Laying there I looked at L and wondered if I did want it. I realized I didn’t, that regardless if I wanted it actually achieving it didn’t really matter. And the feeling of selfishness returned when I contemplated actually wanting the bowl. At this point I announced to everyone that I couldn’t want anything in the world and that the actual word “want” bothered me when it was used. I couldn’t possibly want anything.
Everyone laughed about this, and though I felt a little out of place, I didn’t mind the laughter. I was still so content. We smoked one bowl and just chilled out for what felt like hours. We all did different things during our trip and here are just a few in no particular order, because to be honest I completely forgot the order they occurred in:
In the gnome picture there was a drop of water barely clinging onto the leaf above the gnomes head. While all other visuals were occurring, that drop of water refused to fall. For all of us it would drip down lower but never actually fall. I looked away for a little bit and notice R holding a large glass of water.  Doing this R actually saw the drop of water finally fall and we were all relieved. R commended me on my good idea and that’s where I came to my final breakthrough: sharing was the best way for me to escape feelings of selfishness and continue to be content.
In the room there was an origami ball that one of the guys had made. I picked it up and admired the colors. I saw how glorious it was and knew I had to share it, I passed it along urging everyone to take a look. Shortly after that I realized that my necklace would have to look really sweet at this point. I took it off and looked at the center pendant, which was a small mushroom inside a larger glass mushroom, with some really cool dragons on the outside cap. It looked so amazing that once again I had to share it. Sharing everything I could just felt amazing. It itself was a drug and I had to get more. Yet I knew there would be no negatives to sharing and that made it all the better.
At one point G and L left the room. R, J, and I suddenly heard L yelling at G that she couldn’t handle him anymore (she was laughing hysterically so we knew it wasn’t serious). She came into the room grinning and told us if we wanted to know what that was about just to spend 10 minutes with G. We all sorta looked at each other, and then I decided that G, being the most knowledgeable about shrooms would be the perfect person to hang out with for awhile.
I went into the other room and just layed down on the floor next to G. We discussed the uselessness of language and that to try and communicate what we both were experiencing was useless, we both knew what was going on and too actually talk wasn’t needed. I closed my eyes and got swept into a dark vortex. I felt like I was falling down a long shaft, yet I wasn’t scared at all. It just felt like I was growing longer and no bottom would come.  After a few minutes of this I left, knowing that the group at this point was the better choice then to be off doing my own thing.
As we began to peak I realized that I just needed to hold something. Not that anything bad was happening, but I just knew I loved the feeling of holding something. I grabbed the nearest pillow and just cuddled with it. I felt so wonderful, nothing could take me away from the cloud I was on. The pillow wasn’t so much a security issue as it was just good to hold on to. I’d say I just sat there holding onto or playing around with the pillow for a good hour. At that point we were all out of it so we each were doing our own thing. Some of us were playing with water and some were just staring at the visuals we were experiencing, it was really quite fabulous.
As I felt myself comedown I found I wanted to be by myself more. Not that the group was negative, I just wanted some time to myself. I took off and laid down in another room and just experienced everything I could. The music was flowing from the other room and just added to my general well being.
The comedown wasn’t too rough. Not till I was completely sober did I really feel any effects. At that point I felt like I had gone on a camping trip and came back: I was really tired and a little brain dead from all that had happened. Looking back on it R and I realized that the only thing we had done that day was take a walk and then lay around, but it had felt like we had done so much.
After it was all over I was really confused. I wanted to tell someone about all that had happened, but when I tried to think about it I really couldn’t form what had happened into words. I also didn’t want to be around anyone. Not that I was in a bad mood I just needed some time to think about everything.
Experience Reports are the writings and opinions of the individual authors who submit them.
Some of the activities described are dangerous and/or illegal and none are recommended by Erowid.


{% extends "email/base.html" %} {% load app_tags %} {% load i18n %} {% block email_body %}
Your registration to {{ registration.event.name }} has been cancelled. We are sorry to hear that and hope to see you in the future!


Duke Partnership for Service (dPS) is the governance organization for student service groups, social action groups, and initiatives of all sorts. 65+ student-run service organizations are a part of dPS, and they range from involvement in education, health, the environment, and much more.


matrix = Streams.readRealMatrix(fileName, matrixName, nrow, ncol, verboseRead)
Function readRealMatrix(..) opens the given MATLAB MAT file (in format v4, v6, v7, and if HDF is supported in the Modelica tool, also v7.3), and reads the given matrix from this file. The dimensions of this matrix must first be inquired with function readMatrixSize and passed via arguments nrow and ncol to this function.
See Examples.ReadRealMatrixFromFile.
readMatrixSize, writeRealMatrix
function readRealMatrix extends Modelica.Icons.Function; input String fileName "File where external data is stored" annotation( Dialog(loadSelector(filter = "MATLAB MAT files (*.mat)", caption = "Open MATLAB MAT file"))); input String matrixName "Name / identifier of the 2D Real array on the file"; input Integer nrow "Number of rows of the 2D Real array"; input Integer ncol "Number of columns of the 2D Real array"; input Boolean verboseRead = true "= true: Print info message; = false: No info message"; output Real matrix[nrow, ncol] "2D Real array"; end readRealMatrix;


Brian Keegan & Abram Handler
Week 16: April 26 & 28 2021
| Week | Topic | WA deadline |
| 14 | Customizing Vega plots | Apr 16 |
| 15 | Integrating data into Vega | Apr 23 |
| 16 | Miscellaneous wrap-up | Apr 30 |
There is no final exam and no final project
Vega has a number of benefits!
pandas
for data transformationShow off in your capstone, final projects, portfolio!
The online editor has some nice functionality for developing and debugging your code
Great way to iteratively develop your visualizations outside of text editor to browser and back
It's less forgiving of stray punctuation, but has lots of nice autocomplete and instant feedback
Due Monday, April 26 by midnight on Canvas
Historical DogeCoin price and volume data from Yahoo! Finance available on Canvas
Due Friday, April 30 by midnight on Canvas
Write a reflection on different ways of presenting quantitative and computational information to different audiences
At least three paragraphs describing how to present work to different audiences
No peer review, will help us design future versions of 3402
Short, free-form survey on Canvas asking for your reflections and input on how 3402 can be designed differently in the future
"Required" (we'll nag you a lot) but not graded
Complete the survey here
Brainstorming ideas for data, question, and analyses
Showcasing submissions and works-in-progress
Debugging issues
{
"$schema": "https://vega.github.io/schema/vega-lite/v5.json",
"width": 600,
"height": 400,
"data": {
"url": "https://raw.githubusercontent.com/cuinfoscience/INFO3402-Spring2021/main/Week16/DOGE-USD.csv"
},
"transform": [{
"filter":{
"field":"Date",
"gte":2019,
"timeUnit": "year"
}
}],
"mark": {"type": "line", "point": true},
"encoding": {
"x":{
"field":"Close",
"type":"quantitative",
"scale":{"type": "log"},
"axis": {"tickCount": 5}
},
"y":{
"field":"Volume",
"type": "quantitative",
"scale":{"type": "log"},
"axis": {"tickCount": 5}
},
"color":{
"field":"Date",
"timeUnit":"yearmonth",
"scale": {"scheme": "category10"}
}
}
}
Drop a link in chat to your submitted or in-progress work for feedback
Debugging common issues with CSS, Vega, etc.
Class recap and discussion on future versions


DTGov Dashboard
/
Targets
/
Edit Target
Loading Target, please wait...
Target Details
Make changes to this target by using the form below, then click the Save button to commit your changes.
Validation Errors
Query name is required.
Classifier is required
Name:
Type:
-
Copy
RHQ
Jboss Cli
Maven
Description:
Target Classifiers:
Classifier
Actions
http://www.jboss.org/overlord/deployment-status.owl#InDev
Add Classifier
Save
Reset


rethinking commenting system.
Mention is introducing a new way of commenting that you can integrate on any of your website with privacy and conversations in heart.
join bet nowPS: For every sign up, we will plant a tree 🌳
Mention is introducing a new way of commenting that you can integrate on any of your website with privacy and conversations in heart.
join bet nowPS: For every sign up, we will plant a tree 🌳
We have built the whole experience from ground-up with 100% privacy focused, ads free conversational UI.
Conversation are at the heart of Mention and it's user interface.
We know you don't like ads and so do we Strictly a No-Ads policy.
%100 privacy focused and we keep your and user private.
Multiple formats including videos, images, code block, etc.
Join in bet, to see full preview
join bet nowWe are still in beta. Join now and get 50% on all the paid planes when we launch!
Your name
Email Address
Business Type:
And for every sign up, we will plant a tree 🌳


Files CCore/inc/ExpandWildcard.h CCore/src/ExpandWildcard.cpp
template <FuncInitArgType<StrLen> FuncInit>
auto ExpandWildcard(FileSystem &fs,StrLen path,FuncInit func_init);
ExpandWildcard() calls the given functor on a file set, defined by file name with wildcards. Only wildcards in the file name are expanded. Functor is applied on each existing file, matching the given wildcard name.
dir/*.txt -> dir/file1.txt dir/file2.txt dir/file3.txt
To call the functor the generic functor iteration pattern is used.


If you are using the Safari browser, please use either the Chrome or Firefox browsers in order to complete this activity. Sorry for the inconvenience!


Restaurant Buena Cocina
Slow Italian with a quick ending!
9
Now Waiting
25
Mins Wait (Party of 2)
35
Mins Wait (3 or more)
Team Lately
The latest, greatest team in the building!
Sam Will
Database EngineerJohn Harper
Branding and DesignSean Hellier
Project ManagerKayode Ouseni
Quality Assurance BossThe Problem
Wait times at restaurants and clubs can make you late and interrupt life, but remain guessing game
Little Data
We know if trains are delayed or airports are congested, but what about our local businesses?
Phone Call
Often the best solution we have is picking up the phone and hoping to get a real answer from a restaurant (that wants your business).
Real Time Data
What if you could see who was waiting, and how long they actually waited, at every restaurant near you, in real time.
Crowd Sourced Data
No-Q collects real wait times from people who are waiting or have already been seated at restaurants in your area.


Home
About
Help
Specific Graphics
Bluetooth
BlackList
WhiteList
Build Graphic
Wi-Fi
BlackList
WhiteList
Build Graphic
Insert your Email
account_circle
Email


Zinnia is a simple, customizable and portable online hand recognition system based on Support Vector Machines. Zinnia simply receives user pen strokes as a sequence of coordinate data and outputs n-best characters sorted by SVM confidence. To keep portability, Zinnia doesn't have any rendering functionality. In addition to recognition, Zinnia provides training module that allows us to create any hand-written recognition systems with low-cost.
% tar zxfv zinnia-X.X.tar.gz % cd zinnia-X.X % ./configure % make % su # make install
Install recognition models
% tar zxfv zinnia-tomoe-XXXX.tar.gz % zinnia-tomoe-XXXX % ./configure % make % su # make install
DLL and executable are included in zip file. No recognition models are included. Run the following command after putting model files in zip archived directory.
bin\zinnia_convert.exe handwriting-ja.model.txt handwriting-ja.model bin\zinnia_convert.exe handwriting-zh_CN.model.txt handwriting-zh_CN.model
Zinnia provides C/C++ libraries. Perl/Ruby/Python libraries are also available with SWIG
#include <stdio.h> #include "zinnia.h" int main(int argc, char **argv) { size_t i; zinnia_recognizer_t *recognizer; zinnia_character_t *character; zinnia_result_t *result; recognizer = zinnia_recognizer_new(); if (!zinnia_recognizer_open(recognizer, "/usr/local/lib/zinnia/model/tomoe/handwriting-ja.model")) { fprintf(stderr, "ERROR: %s\n", zinnia_recognizer_strerror(recognizer)); return -1; } zinnia_character_t *character = zinnia_character_new(); zinnia_character_clear(character); zinnia_character_set_width(character, 300); zinnia_character_set_height(character, 300); zinnia_character_add(character, 0, 51, 29); zinnia_character_add(character, 0, 117, 41); zinnia_character_add(character, 1, 99, 65); zinnia_character_add(character, 1, 219, 77); zinnia_character_add(character, 2, 27, 131); zinnia_character_add(character, 2, 261, 131); zinnia_character_add(character, 3, 129, 17); zinnia_character_add(character, 3, 57, 203); zinnia_character_add(character, 4, 111, 71); zinnia_character_add(character, 4, 219, 173); zinnia_character_add(character, 5, 81, 161); zinnia_character_add(character, 5, 93, 281); zinnia_character_add(character, 6, 99, 167); zinnia_character_add(character, 6, 207, 167); zinnia_character_add(character, 6, 189, 245); zinnia_character_add(character, 7, 99, 227); zinnia_character_add(character, 7, 189, 227); zinnia_character_add(character, 8, 111, 257); zinnia_character_add(character, 8, 189, 245); result = zinnia_recognizer_classify(recognizer, character, 10); if (result == NULL) { fprintf(stderr, "%s\n", zinnia_recognizer_strerror(recognizer)); return -1; } for (i = 0; i < zinnia_result_size(result); ++i) { fprintf(stdout, "%s\t%f\n", zinnia_result_value(result, i), zinnia_result_score(result, i)); } zinnia_result_destroy(result); zinnia_character_destroy(character); zinnia_recognizer_destroy(recognizer); return 0; }
% gcc example.c -lzinnia -o zinnia_sample % ./zinnia_sample
#include <iostream> #include "zinnia.h" int main(int argc, char **argv) { zinnia::Recognizer *recognizer = zinnia::Recognizer::create(); if (!recognizer->open("/usr/local/lib/zinnia/model/tomoe/handwriting-ja.model")) { std::cerr << recognizer->what() << std::endl; return -1; } zinnia::Character *character = zinnia::Character::create(); character->clear(); character->set_width(300); character->set_height(300); character->add(0, 51, 29); character->add(0, 117, 41); character->add(1, 99, 65); character->add(1, 219, 77); character->add(2, 27, 131); character->add(2, 261, 131); character->add(3, 129, 17); character->add(3, 57, 203); character->add(4, 111, 71); character->add(4, 219, 173); character->add(5, 81, 161); character->add(5, 93, 281); character->add(6, 99, 167); character->add(6, 207, 167); character->add(6, 189, 245); character->add(7, 99, 227); character->add(7, 189, 227); character->add(8, 111, 257); character->add(8, 189, 245); zinnia::Result *result = recognizer->classify(*character, 10); if (!result) { std::cerr << recognizer->what() << std::endl; return -1; } for (size_t i = 0; i < result->size(); ++i) { std::cout << result->value(i) << "\t" << result->score(i) << std::endl; } delete result; delete character; delete recognizer; return 0; }
Character class (zinnia_character_t / zinnia::Character) has method for an Sexp-based serialization.
(character (width canvas width) (height canvas height) (strokes ((0-th-stroke 0-th-strokey) ... (0-th-stroke 0-th-strokey)) ((1-th-stroke 0-th-strokey) ... (1-th-stroke 1-th-strokey)) ((2-th-stroke 2-th-strokey) ... (2-th-stroke 2-th-strokey)) ...))
Example
static const char sexp[] = "(character (width 1000)(height 1000)(strokes ((243 273)(393 450))((700 253)(343 486)(280 716)(393 866)(710 880))))"; zinnia_character_t *character = zinnia_character_new(); zinnia_character_parse(character, sexp);
static const char sexp[] = "(character (width 1000)(height 1000)(strokes ((243 273)(393 450))((700 253)(343 486)(280 716)(393 866)(710 880))))"; zinnia::Character *character = zinnia::Character::create(); character->parse(sexp);
In order to make a training with Zinnia, you need to make a golden (training) data. Training data is written in S-expression. Generally speaking, more data yields better quality. Zinnia only supports batch training so far.
Example
(character (value あ) (width 300) (height 300) (strokes ((54 58)(249 68)) ((147 10)(145 201)(182 252)) ((224 103)(149 230)(82 240)(53 204)(86 149)(182 139)(240 172)(248 224)(228 250)))) (character (value い) (width 300) (height 300) (strokes ((56 63)(43 213)(67 259)(94 243)) ((213 66)(231 171)(208 217)))) (character (value う) (width 300) (height 300) (strokes ((102 35)(187 45)) ((73 121)(167 105)(206 139)(198 211)(135 275)))) (character (value え) (width 300) (height 300) (strokes ((140 19)(162 38)) ((62 105)(208 100)(51 263)(128 205)(188 268)(260 252)))) (character (value お) (width 300) (height 300) (strokes ((64 94)(240 98)) ((148 35)(159 129)(140 199)(105 247)(64 228)(101 161)(192 161)(222 223)(189 257)) ((223 49)(253 89))))
You might want to look into *.s file in zinnia-tomoe as references
Use zinnia_learn to conduct training
% zinnia_learn train-file model-file ... learning: (8/3033) 8 .... learning: (9/3033) 9 ... learning: (10/3033) 々 ............ learning: (11/3033) 〆 .... learning: (12/3033) あ .... learning: (13/3033) い ....... learning: (14/3033) う ............... learning: (15/3033) え ...................................................................................... learning: (16/3033) お ...... learning: (17/3033) か ....... learning: (18/3033) き ....... learning: (19/3033) く .......
train-file is a training data and model-file is a model file zinnia_learn generates
use zinnia command for testing
% zinnia -m model-file < test-file
model-file is a file zinnia_learn generates. text-file is a test data written in Sexp format.
Once training completes successfully, model-file.txt (text file) and model-file (binary file) will be generated. text-model is an architecture-independent format, and model-file is an architecture-dependent binary model. Zinnia recognizer can only load binary model. zinnia_convert program converts text-model into binary model.
% zinnia_convert model-file.txt model-file
In addition, text-model can be converted into C-header file.
% zinnia_convert --name=my_model --make_header model-file.txt my_model.h
In order to use a header file, include my_model.h in C/C++ source file and load the data using zinnia_recognizer_open_from_ptr(). my_model(content of mode) and my_model_size(model size) is defined in the header file.
#include "my_model.h" if (!zinnia_recognizer_open_from_ptr(recognizer, my_model, my_model_size)) { /* error */ }
By omitting features having small score, model can be compressed with scarifying recognition accuracy.
% zinnia_convert -c 0.01 model-file.txt model1 % zinnia_convert -c 0.001 model-file.txt model2 % ls -h -l model* -rw-r--r-- 1 taku taku 3.1M 2008-07-14 12:50 model1 -rw-r--r-- 1 taku taku 25M 2008-07-14 12:50 model2
c is a threshold. Default setting 0.001. Larger threshold gives more aggressive compression.


This is a helper class to build queries for the Model instance's in-memory table.
This class is instantiated by the Query object.
Its role is to build database specific queries for the given parameters.
In the current implementation the database is a Pandas dataframe referenced by `model.df`.
Please refer to the Model class to learn mode about `model.df`.
| def query.QueryBuilder.multi_column_match_query |
( |
|
self, |
|
|
* |
col_val_tuple |
|
) |
| |
Build a query to match one or more values across multiple columns.
Returns a Pandas selector (query) to return the set of
rows matching the *col_val_tuple in the following format:
(column_name_1, value_1), (column_name_2, [value_1, value_2, ...])...
The second item in each tupe can either be a list of primitive type values, i.e. [value_1, value_2, ...],
or single primitive type values, i.e. value_1 of type number, boolean or string.


This is a paragraph with
bold
,
italic
, and
underlined
.
This is a paragraph with a footnote
This is the text of the footnote
at the middle.


For your security, the profile that you are using to access Capital One Online Banking has been locked because of too many failed login attempts. You can unlock this profile online by selecting an option below:
Unlock your Capital One profile with:
https://service.capitalone.com/oas/login.do?objectclicked=LoginSplash
We regret any inconvenience this may cause you. Sincerely, Capital One Account Review Department. We are requesting this information to verify and protect your identity. This is in order to prevent the use of the U.S. banking system in terrorist and other illegal activity. Need help? Use "Site Helper" or call customer service at 1.800- Capital One. Please do not "Reply" to this Alert. © 2005 Capital One, N.A. All rights reserved.


I’m a Junior Ruby/Rails Developer with a year's worth of experience, including exposure to CSS, Javascript, node.js, Express, RSpec, Git/Github, Heroku, SQL, & AJAX. I love the elegance of Ruby, the opinionatedness of Rails and how Ror has helped me to understand the MVC structure. I feel like I discover something new everyday and that's why I love code!
I'm currently performing as a vacation swing in the Off-Broadway production of SWEENEY TODD @ the Barrow Street Theatre. Other NYC credits include Doc Machan in THE GOLDEN APPLE @ Encores! and Matt in THE FANTASTICKS. I've worked as a professional performer in the theatre business since I graduated college from the University of Michigan.
My father first taught me how to play guitar and as soon as I could play 3 chords I started writing my own songs. I write mostly in a folk style and have the privilege of performing and writing with my immensely talented wife, Grace. I hope you enjoy our music!


The Database class encapsulates a single connection to a SQLite3 database. Its usage is very straightforward:
require 'sqlite3' db = SQLite3::Database.new( "data.db" ) db.execute( "select * from table" ) do |row| p row end db.close
It wraps the lower-level methods provides by the selected driver, and includes the Pragmas module for access to various pragma convenience methods.
The Database class provides type translation services as well, by which the SQLite3 data types (which are all represented as strings) may be converted into their corresponding types (as defined in the schemas for their tables). This translation only occurs when querying data from the database—insertions and updates are all still typeless.
Furthermore, the Database class has been designed to work well with the ArrayFields module from Ara Howard. If you require the ArrayFields module before performing a query, and if you have not enabled results as hashes, then the results will all be indexible by field name.
- authorizer
- busy_handler
- busy_timeout
- changes
- close
- closed?
- commit
- complete?
- create_aggregate
- create_aggregate_handler
- create_function
- errcode
- errmsg
- execute
- execute2
- execute_batch
- get_first_row
- get_first_value
- interrupt
- last_insert_row_id
- new
- prepare
- query
- quote
- rollback
- total_changes
- trace
- transaction
- transaction_active?
- translator
| [R] | driver | A reference to the underlying SQLite3 driver used by this database. |
| [R] | handle | The low-level opaque database handle that this object wraps. |
| [RW] | results_as_hash | A boolean that indicates whether rows in result sets should be returned as hashes or not. By default, rows are returned as arrays. |
| [RW] | type_translation | A boolean indicating whether or not type translation is enabled for this database. |
Create a new Database object that opens the given file. If utf16 is true, the filename is interpreted as a UTF-16 encoded string.
By default, the new database will return result rows as arrays (results_as_hash) and has type translation disabled (type_translation=).
[ show source ]
# File lib/sqlite3/database.rb, line 72 72: def initialize( file_name, options={} ) 73: utf16 = options.fetch(:utf16, false) 74: load_driver( options[:driver] ) 75: 76: @statement_factory = options[:statement_factory] || Statement 77: 78: result, @handle = @driver.open( file_name, utf16 ) 79: Error.check( result, self, "could not open database" ) 80: 81: @closed = false 82: @results_as_hash = options.fetch(:results_as_hash,false) 83: @type_translation = options.fetch(:type_translation,false) 84: @translator = nil 85: @transaction_active = false 86: end
Quotes the given string, making it safe to use in an SQL statement. It replaces all instances of the single-quote character with two single-quote characters. The modified string is returned.
[ show source ]
# File lib/sqlite3/database.rb, line 47 47: def quote( string ) 48: string.gsub( /'/, "''" ) 49: end
Installs (or removes) a block that will be invoked for every access to the database. If the block returns 0 (or nil), the statement is allowed to proceed. Returning 1 causes an authorization error to occur, and returning 2 causes the access to be silently denied.
[ show source ]
# File lib/sqlite3/database.rb, line 143 143: def authorizer( data=nil, &block ) 144: result = @driver.set_authorizer( @handle, data, &block ) 145: Error.check( result, self ) 146: end
Register a busy handler with this database instance. When a requested resource is busy, this handler will be invoked. If the handler returns false, the operation will be aborted; otherwise, the resource will be requested again.
The handler will be invoked with the name of the resource that was busy, and the number of times it has been retried.
See also the mutually exclusive busy_timeout.
[ show source ]
# File lib/sqlite3/database.rb, line 309 309: def busy_handler( data=nil, &block ) # :yields: data, retries 310: result = @driver.busy_handler( @handle, data, &block ) 311: Error.check( result, self ) 312: end
Indicates that if a request for a resource terminates because that resource is busy, SQLite should sleep and retry for up to the indicated number of milliseconds. By default, SQLite does not retry busy resources. To restore the default behavior, send 0 as the ms parameter.
See also the mutually exclusive busy_handler.
[ show source ]
# File lib/sqlite3/database.rb, line 321 321: def busy_timeout( ms ) 322: result = @driver.busy_timeout( @handle, ms ) 323: Error.check( result, self ) 324: end
Returns the number of changes made to this database instance by the last operation performed. Note that a "delete from table" without a where clause will not affect this value.
[ show source ]
# File lib/sqlite3/database.rb, line 285 285: def changes 286: @driver.changes( @handle ) 287: end
Closes this database.
[ show source ]
# File lib/sqlite3/database.rb, line 118 118: def close 119: unless @closed 120: result = @driver.close( @handle ) 121: Error.check( result, self ) 122: end 123: @closed = true 124: end
Returns true if this database instance has been closed (see close).
[ show source ]
# File lib/sqlite3/database.rb, line 127 127: def closed? 128: @closed 129: end
Commits the current transaction. If there is no current transaction, this will cause an error to be raised. This returns true, in order to allow it to be used in idioms like abort? and rollback or commit.
[ show source ]
# File lib/sqlite3/database.rb, line 580 580: def commit 581: execute "commit transaction" 582: @transaction_active = false 583: true 584: end
Return true if the string is a valid (ie, parsable) SQL statement, and false otherwise. If +utf16+ is true, then the string is a UTF-16 character string.
[ show source ]
# File lib/sqlite3/database.rb, line 91 91: def complete?( string, utf16=false ) 92: @driver.complete?( string, utf16 ) 93: end
Creates a new aggregate function for use in SQL statements. Aggregate functions are functions that apply over every row in the result set, instead of over just a single row. (A very common aggregate function is the "count" function, for determining the number of rows that match a query.)
The new function will be added as name, with the given arity. (For variable arity functions, use -1 for the arity.)
The step parameter must be a proc object that accepts as its first parameter a FunctionProxy instance (representing the function invocation), with any subsequent parameters (up to the function‘s arity). The step callback will be invoked once for each row of the result set.
The finalize parameter must be a proc object that accepts only a single parameter, the FunctionProxy instance representing the current function invocation. It should invoke FunctionProxy#set_result to store the result of the function.
Example:
db.create_aggregate( "lengths", 1 ) do step do |func, value| func[ :total ] ||= 0 func[ :total ] += ( value ? value.length : 0 ) end finalize do |func| func.set_result( func[ :total ] || 0 ) end end puts db.get_first_value( "select lengths(name) from table" )
See also create_aggregate_handler for a more object-oriented approach to aggregate functions.
[ show source ]
# File lib/sqlite3/database.rb, line 405 405: def create_aggregate( name, arity, step=nil, finalize=nil, 406: text_rep=Constants::TextRep::ANY, &block ) 407: # begin 408: if block 409: proxy = AggregateDefinitionProxy.new 410: proxy.instance_eval(&block) 411: step ||= proxy.step_callback 412: finalize ||= proxy.finalize_callback 413: end 414: 415: step_callback = proc do |func,*args| 416: ctx = @driver.aggregate_context( func ) 417: unless ctx[:__error] 418: begin 419: step.call( FunctionProxy.new( @driver, func, ctx ), 420: *args.map{|v| Value.new(self,v)} ) 421: rescue Exception => e 422: ctx[:__error] = e 423: end 424: end 425: end 426: 427: finalize_callback = proc do |func| 428: ctx = @driver.aggregate_context( func ) 429: unless ctx[:__error] 430: begin 431: finalize.call( FunctionProxy.new( @driver, func, ctx ) ) 432: rescue Exception => e 433: @driver.result_error( func, 434: "#{e.message} (#{e.class})", -1 ) 435: end 436: else 437: e = ctx[:__error] 438: @driver.result_error( func, 439: "#{e.message} (#{e.class})", -1 ) 440: end 441: end 442: 443: result = @driver.create_function( @handle, name, arity, text_rep, nil, 444: nil, step_callback, finalize_callback ) 445: Error.check( result, self ) 446: 447: self 448: end
This is another approach to creating an aggregate function (see create_aggregate). Instead of explicitly specifying the name, callbacks, arity, and type, you specify a factory object (the "handler") that knows how to obtain all of that information. The handler should respond to the following messages:
| arity: | corresponds to the arity parameter of create_aggregate. This message is optional, and if the handler does not respond to it, the function will have an arity of -1. |
| name: | this is the name of the function. The handler must implement this message. |
| new: | this must be implemented by the handler. It should return a new instance of the object that will handle a specific invocation of the function. |
The handler instance (the object returned by the new message, described above), must respond to the following messages:
| step: | this is the method that will be called for each step of the aggregate function‘s evaluation. It should implement the same signature as the step callback for create_aggregate. |
| finalize: | this is the method that will be called to finalize the aggregate function‘s evaluation. It should implement the same signature as the finalize callback for create_aggregate. |
Example:
class LengthsAggregateHandler def self.arity; 1; end def initialize @total = 0 end def step( ctx, name ) @total += ( name ? name.length : 0 ) end def finalize( ctx ) ctx.set_result( @total ) end end db.create_aggregate_handler( LengthsAggregateHandler ) puts db.get_first_value( "select lengths(name) from A" )
[ show source ]
# File lib/sqlite3/database.rb, line 496 496: def create_aggregate_handler( handler ) 497: arity = -1 498: text_rep = Constants::TextRep::ANY 499: 500: arity = handler.arity if handler.respond_to?(:arity) 501: text_rep = handler.text_rep if handler.respond_to?(:text_rep) 502: name = handler.name 503: 504: step = proc do |func,*args| 505: ctx = @driver.aggregate_context( func ) 506: unless ctx[ :__error ] 507: ctx[ :handler ] ||= handler.new 508: begin 509: ctx[ :handler ].step( FunctionProxy.new( @driver, func, ctx ), 510: *args.map{|v| Value.new(self,v)} ) 511: rescue Exception, StandardError => e 512: ctx[ :__error ] = e 513: end 514: end 515: end 516: 517: finalize = proc do |func| 518: ctx = @driver.aggregate_context( func ) 519: unless ctx[ :__error ] 520: ctx[ :handler ] ||= handler.new 521: begin 522: ctx[ :handler ].finalize( FunctionProxy.new( @driver, func, ctx ) ) 523: rescue Exception => e 524: ctx[ :__error ] = e 525: end 526: end 527: 528: if ctx[ :__error ] 529: e = ctx[ :__error ] 530: @driver.sqlite3_result_error( func, "#{e.message} (#{e.class})", -1 ) 531: end 532: end 533: 534: result = @driver.create_function( @handle, name, arity, text_rep, nil, 535: nil, step, finalize ) 536: Error.check( result, self ) 537: 538: self 539: end
Creates a new function for use in SQL statements. It will be added as name, with the given arity. (For variable arity functions, use -1 for the arity.)
The block should accept at least one parameter—the FunctionProxy instance that wraps this function invocation—and any other arguments it needs (up to its arity).
The block does not return a value directly. Instead, it will invoke the FunctionProxy#set_result method on the func parameter and indicate the return value that way.
Example:
db.create_function( "maim", 1 ) do |func, value| if value.nil? func.result = nil else func.result = value.split(//).sort.join end end puts db.get_first_value( "select maim(name) from table" )
[ show source ]
# File lib/sqlite3/database.rb, line 349 349: def create_function( name, arity, text_rep=Constants::TextRep::ANY, 350: &block ) # :yields: func, *args 351: # begin 352: callback = proc do |func,*args| 353: begin 354: block.call( FunctionProxy.new( @driver, func ), 355: *args.map{|v| Value.new(self,v)} ) 356: rescue StandardError, Exception => e 357: @driver.result_error( func, 358: "#{e.message} (#{e.class})", -1 ) 359: end 360: end 361: 362: result = @driver.create_function( @handle, name, arity, text_rep, nil, 363: callback, nil, nil ) 364: Error.check( result, self ) 365: 366: self 367: end
Return an integer representing the last error to have occurred with this database.
[ show source ]
# File lib/sqlite3/database.rb, line 103 103: def errcode 104: @driver.errcode( @handle ) 105: end
Return a string describing the last error to have occurred with this database.
[ show source ]
# File lib/sqlite3/database.rb, line 97 97: def errmsg( utf16=false ) 98: @driver.errmsg( @handle, utf16 ) 99: end
Executes the given SQL statement. If additional parameters are given, they are treated as bind variables, and are bound to the placeholders in the query.
Note that if any of the values passed to this are hashes, then the key/value pairs are each bound separately, with the key being used as the name of the placeholder to bind the value to.
The block is optional. If given, it will be invoked for each row returned by the query. Otherwise, any results are accumulated into an array and returned wholesale.
See also execute2, query, and execute_batch for additional ways of executing statements.
[ show source ]
# File lib/sqlite3/database.rb, line 180 180: def execute( sql, *bind_vars ) 181: prepare( sql ) do |stmt| 182: result = stmt.execute( *bind_vars ) 183: if block_given? 184: result.each { |row| yield row } 185: else 186: return result.inject( [] ) { |arr,row| arr << row; arr } 187: end 188: end 189: end
Executes the given SQL statement, exactly as with execute. However, the first row returned (either via the block, or in the returned array) is always the names of the columns. Subsequent rows correspond to the data from the result set.
Thus, even if the query itself returns no rows, this method will always return at least one row—the names of the columns.
See also execute, query, and execute_batch for additional ways of executing statements.
[ show source ]
# File lib/sqlite3/database.rb, line 201 201: def execute2( sql, *bind_vars ) 202: prepare( sql ) do |stmt| 203: result = stmt.execute( *bind_vars ) 204: if block_given? 205: yield result.columns 206: result.each { |row| yield row } 207: else 208: return result.inject( [ result.columns ] ) { |arr,row| 209: arr << row; arr } 210: end 211: end 212: end
Executes all SQL statements in the given string. By contrast, the other means of executing queries will only execute the first statement in the string, ignoring all subsequent statements. This will execute each one in turn. The same bind parameters, if given, will be applied to each statement.
This always returns nil, making it unsuitable for queries that return rows.
[ show source ]
# File lib/sqlite3/database.rb, line 222 222: def execute_batch( sql, *bind_vars ) 223: sql = sql.strip 224: until sql.empty? do 225: prepare( sql ) do |stmt| 226: stmt.execute( *bind_vars ) 227: sql = stmt.remainder.strip 228: end 229: end 230: nil 231: end
A convenience method for obtaining the first row of a result set, and discarding all others. It is otherwise identical to execute.
See also get_first_value.
[ show source ]
# File lib/sqlite3/database.rb, line 261 261: def get_first_row( sql, *bind_vars ) 262: execute( sql, *bind_vars ) { |row| return row } 263: nil 264: end
A convenience method for obtaining the first value of the first row of a result set, and discarding all other values and rows. It is otherwise identical to execute.
See also get_first_row.
[ show source ]
# File lib/sqlite3/database.rb, line 271 271: def get_first_value( sql, *bind_vars ) 272: execute( sql, *bind_vars ) { |row| return row[0] } 273: nil 274: end
Interrupts the currently executing operation, causing it to abort.
[ show source ]
# File lib/sqlite3/database.rb, line 296 296: def interrupt 297: @driver.interrupt( @handle ) 298: end
Obtains the unique row ID of the last row to be inserted by this Database instance.
[ show source ]
# File lib/sqlite3/database.rb, line 278 278: def last_insert_row_id 279: @driver.last_insert_rowid( @handle ) 280: end
Returns a Statement object representing the given SQL. This does not execute the statement; it merely prepares the statement for execution.
The Statement can then be executed using Statement#execute.
[ show source ]
# File lib/sqlite3/database.rb, line 153 153: def prepare( sql ) 154: stmt = @statement_factory.new( self, sql ) 155: if block_given? 156: begin 157: yield stmt 158: ensure 159: stmt.close 160: end 161: else 162: return stmt 163: end 164: end
This is a convenience method for creating a statement, binding paramters to it, and calling execute:
result = db.query( "select * from foo where a=?", 5 ) # is the same as result = db.prepare( "select * from foo where a=?" ).execute( 5 )
You must be sure to call close on the ResultSet instance that is returned, or you could have problems with locks on the table. If called with a block, close will be invoked implicitly when the block terminates.
[ show source ]
# File lib/sqlite3/database.rb, line 244 244: def query( sql, *bind_vars ) 245: result = prepare( sql ).execute( *bind_vars ) 246: if block_given? 247: begin 248: yield result 249: ensure 250: result.close 251: end 252: else 253: return result 254: end 255: end
Rolls the current transaction back. If there is no current transaction, this will cause an error to be raised. This returns true, in order to allow it to be used in idioms like abort? and rollback or commit.
[ show source ]
# File lib/sqlite3/database.rb, line 590 590: def rollback 591: execute "rollback transaction" 592: @transaction_active = false 593: true 594: end
Returns the total number of changes made to this database instance since it was opened.
[ show source ]
# File lib/sqlite3/database.rb, line 291 291: def total_changes 292: @driver.total_changes( @handle ) 293: end
Installs (or removes) a block that will be invoked for every SQL statement executed. The block receives a two parameters: the data argument, and the SQL statement executed. If the block is nil, any existing tracer will be uninstalled.
[ show source ]
# File lib/sqlite3/database.rb, line 135 135: def trace( data=nil, &block ) 136: @driver.trace( @handle, data, &block ) 137: end
Begins a new transaction. Note that nested transactions are not allowed by SQLite, so attempting to nest a transaction will result in a runtime exception.
The mode parameter may be either :deferred (the default), :immediate, or :exclusive.
If a block is given, the database instance is yielded to it, and the transaction is committed when the block terminates. If the block raises an exception, a rollback will be performed instead. Note that if a block is given, commit and rollback should never be called explicitly or you‘ll get an error when the block terminates.
If a block is not given, it is the caller‘s responsibility to end the transaction explicitly, either by calling commit, or by calling rollback.
[ show source ]
# File lib/sqlite3/database.rb, line 557 557: def transaction( mode = :deferred ) 558: execute "begin #{mode.to_s} transaction" 559: @transaction_active = true 560: 561: if block_given? 562: abort = false 563: begin 564: yield self 565: rescue ::Object 566: abort = true 567: raise 568: ensure 569: abort and rollback or commit 570: end 571: end 572: 573: true 574: end
Returns true if there is a transaction active, and false otherwise.
[ show source ]
# File lib/sqlite3/database.rb, line 597 597: def transaction_active? 598: @transaction_active 599: end
Return the type translator employed by this database instance. Each database instance has its own type translator; this allows for different type handlers to be installed in each instance without affecting other instances. Furthermore, the translators are instantiated lazily, so that if a database does not use type translation, it will not be burdened by the overhead of a useless type translator. (See the Translator class.)
[ show source ]
# File lib/sqlite3/database.rb, line 113 113: def translator 114: @translator ||= Translator.new 115: end


EFA enquiries
Contact form https://form.education...
For all enquiries for the Education Funding Agency
Beta This is a test version of the layout of this page. Take the survey to help us improve it
Guidance
Information for schools and sixth-form colleges about the outcome of the Condition Improvement Fund (CIF) 2016 to 2017.
We announced the outcome of the Condition Improvement Fund ( CIF ) for 2016 to 2017 in March 2016.
We had invited applications to the CIF from academies and sixth-form colleges in the autumn, with bids due in before Christmas. Just over 3,500 applications were received this year. As agreed with ministers, the highest condition CIF priorities were compliance and health and safety, followed by projects which address the most significant building condition.
There was funding of over £435 million for 1,276 projects across 1,030 academies and sixth-form colleges, helping to ensure that children across the country have access to world class schools. We have sent details of outcomes to all applicants.
You can access information about the terms and conditions of funding, funding profiles, and detailed post approval guidance on the CIF portal .
It is important that successful projects:
The significant number of applications we received means that, unfortunately, we have not been able to fund all the projects. We will look for opportunities to fund further high scoring applications from this year’s bidding round should extra funding become available.
We have prioritised those which provided evidence of the greatest need. If your project or projects do not appear on the published list then we regret to inform you that we are unable to prioritise them for funding at this stage.
We realise this will be disappointing news and you will want to review your project scores and feedback to inform any future applications you may make. This information is now available on the CIF portal .
We have now published the outcomes of appeals for the 2016 to 2017 CIF round . We could only consider information that formed part of the original application. This decision is final, there is no further stage in the appeal process and EFA will not consider any requests to review the outcome of appeals.
We will announce details of the next round of CIF in the autumn.
If you need further advice, please contact us using:
Contact form https://form.education...
For all enquiries for the Education Funding Agency