Version 2.0.4 (Feb.
23, 2003)
By Kris Kopicki<EMAIL_ADDRESS>Provides Mac OS specific features, such as:
jEdit exits cleanly when using Command-Q or "Quit" from the "File"
menu.
Files created or associated with jEdit can now be opened from the Finder,
by either double-clicking the file's icon or dragging the file's icon onto
the jEdit application icon.
jEdit preserves existing type/creator codes and is assigned as the creator
of new files (Default). Can also be set to ignore existing type/creator codes.
"Preferences..." in the application menu can be used to access jEdit's Global
Options.
"About jEdit..." in the application menu can be used to access the About
Dialog.
The menu's can be placed in the Mac OS X menu bar. This is not recommended,
as there are problems with Java on Mac OS X.
You can enable live resizing of windows.
You can show current and recent buffers in the finder.
You can run AppleScripts (compiled, uncompiled and standalone). Your scripts
must be located in the macros folder in the jEdit folder. They can be either
plain text or compiled scripts. Scripts must have their type and creator set
correctly, have a .scpt (for compiled scripts) or .applescript (for uncompiled
scripts) extension, or both.
The text area can be set to use the system default for highlighting text.
Known Issues:
Files opened in the Finder before jEdit is running are not opened in jEdit
(10.0.x - 10.1.x).
Scripts that require user interaction are not supported.


|
William ShakespeareYou can call him Will, and you can call him Bill, but you doesn't have to call him Francis.Scholars have advanced more theories about William Shakespeare than about Jesus Christ. For some reason, the Bard of Avon just inspires rampant speculation, regarding both his body of work, whether that work was any good, who actually wrote it, what sort of clothes whoever was wearing when he wrote the works, and the perennial question: What was he smoking? (Whoever he was.) (Unless he was a she.) Shakespeare's father was a glove-maker and later a local politician. His mother was affluent. Young William was born in 1564, in Stratford-on-Avon, England. If you're looking for brilliant insight into how a childhood shapes an artistic career, look elsewhere. The 16th century isn't known for its exhaustive record-keeping. There were no blogs to record the inane details of William's upbringing. At some point during his youth, it is safe to say, Shakespeare got a pretty good education. In addition to his obvious language skills, his plays show a deep knowledge of history and classical literature, much of which he shamelessly stole for material. As a young man, Shakespeare did something or other. The interregnum between youth and adulthood has been the subject of much speculation, due to the utter lack of records that indicate where he was or what he was doing. At age 18, he married Anne Hathaway, a farmer's daughter, and they had at least three children. Then, he simply pops up in London several years later. Some have speculated that the young bard was a poacher, who fled Stratford for London to avoid prosecution. He may also have been kidnapped by aliens, or perhaps he went on an excellent adventure through time to assist some lovable scamps with their high school history project. Whatever he did, it didn't involve record keeping, which means he was very likely making gloves. Whatever he had been up to, Shakespeare took up a full-time career in the theater at the age of 30. He had written his first plays a few years earlier, and his work won him a spot with the Lord Chamberlain's Men in London as an actor and playwright. A few years later, the company was taken over by the King and renamed (rather imaginatively) The King's Men. He may have been a failure as a poacher, but Shakespeare found success in the theater, earning enough money to live in relative comfort. He was amazingly prolific, but also extremely skilled. Over the course of his career, he wrote 37 plays. About a third of his plays were brilliant, another third were quite competent, and the remaining plays were... well... remaining. And we're not talking one-man shows, one-act experiments or improv scenarios. These are five-act plays, and they are long. At times, excruciatingly so. Even more impressive, relative to a modern Hollywood screenplay, Shakespeare's works were written in strict iambic pentameter, after the custom of the time. Each line contained five sets of two beats, with the second beat receiving emphasis. You don't hear the meter in modern performances of Shakespeare, but it's there. You can argue the merits of writing in iambic pentameter, but one fact is inescapable - it's really hard. The amount of work involved in writing any one Shakespeare play is probably the equivalent of writing three or four modern plays. Shakespeare's plays fell into four major categories -- comedy, tragedy, history and The Tempest. His comedies tend toward mistaken identity and farce, often with depressingly predictable results. Two Gentlemen From Verona, The Taming of the Shrew, A Comedy of Errors and The Merchant of Venice were among the bright spots in this portfolio, the equivalent of Frasier from our modern world. Most of the remaining comedies, with a few exceptions, were the equivalent of Three's Company, resting on broad slapstick, miscommunications and the lowest form of humor, puns. An exception is A Midsummer Night's Dream, which is more of a Coen Brothers movie. The tragedies were in many ways more successful, including Macbeth, King Lear, Othello, Antony and Cleopatra and perhaps most famously, Hamlet.  The problem of Hamlet is pretty simple. His father's ghost appears and orders Hamlet to kill Claudius, his father's brother. Now, Claudius murdered Hamlet's father, married Hamlet's mother and usurped Hamlet's throne. And that was just before the play. During the play, Claudius spies on Hamlet in private moments with his girlfriend, spies on Hamlet's private conversations with his mother, drives Hamlet's girlfriend to suicide, schemes to kill Hamlet, and murders two of Hamlet's friends. Killing Claudius would seem to be a no-brainer. Instead, Hamlet agonizes over the decision to the point that audiences just want to scream in dismay. Hamlet concocts elaborate schemes to figure out whether his father's ghost was telling the truth, he feigns madness for no apparent reason, and even then he dithers and dallies until Claudius accidentally poisons Hamlet's mother. Hamlet only ends up killing Claudius in the play's closing moments, almost as an afterthought. This inexplicable hesitation on the part of Hamlet has inspired millions of pages of analysis and interpretation, with various theories proposed to explain the melancholy Dane's stubborn refusal to get on with the killing.  Others have dwelt on the prince's existential dilemma, his clinical depression, his political position, and the lack of fiber in his diet. T. S. Eliot famously wrote that the reason Hamlet takes so long completing his mission is that Hamlet really isn't a very good play. In 1922, Eliot observed that "few critics have even admitted that Hamlet the play is the primary problem, and Hamlet the character only secondary. And Hamlet the character has had an especial temptation for that most dangerous type of critic: the critic with a mind which is naturally of the creative order, but which through some weakness in creative power exercises itself in criticism instead." Which, on the face of it, sounds pretty reasonable. Shakespeare's histories were less problematic and more formulaic. Although many of the tragedies have historical settings, the histories are a series of plays chronicling the intrigues of the kings of England. The personal dramas laid out therein are sufficiently compelling that you don't have to be English to appreciate them. (But it helps.) The Tempest stands apart from the body of Shakespeare's work for its sheer hallucinogenic fun. Written late in the Bard's career, the play is a dreamlike fantasy set on a mystical island. Surreal and full of complex layers, the play was centuries ahead of its time. In addition to all these plays, Shakespeare also wrote thousands upon thousands of verses of poetry, also in iambic pentameter. Unlike the plays, which were written in blank verse, Shakespeare's sonnets have a strict rhyme scheme as well. Some of Shakespeare's sonnets are touching, others are funny. Some of them may be telling, such as the sonnets devoted to extolling his love for a male, and the sonnets about an ugly woman whom he found irresistible. But it's always risky to extrapolate facts about an artist's real life from his or her work, especially poets, and especially poets who have been dead for centuries. Nevertheless, Shakespeare's life and his works are favorite subjects for interpretation, much of it mandated in high school and college literature classes.  Was he a transvestite? Did have have affairs? How many affairs? Did he do drugs? Most of these questions are destined to be the subject of endless speculation by historians "with a mind which is naturally of the creative order, but which through some weakness in creative power exercises itself in" history instead. However, the issue of whether Shakespeare did drugs is not quite so speculative. Unlike most claims about the Bard's life, there is actual evidence to support a conclusion. In 2001, the South African Journal of Science published the results of an archeological excavation at Shakespeare's home in Stratford, where he retired in 1613. Fragments of clay pipes found on the grounds revealed traces of marijuana, camphor, and cocaine mixed with tobacco. Traces of nutmeg were also found. (It's a hallucinogen, kids! Nog responsibly!) Even with the caveats offered above about reading too much into an artist's output, it's hard not to think of those substances when reading the sonnets: "Why write I still all one, ever the same, / And keep invention in a noted weed, / That every word doth almost tell my name, / Showing their birth, and where they did proceed?" Shakespeare died in 1616 at the age of 52, which was fairly respectable for the plague-ridden England of his day. However, the saga of Shakespeare had only just begun. His plays have been performed continuously since his death, which is no small accomplishment in a world often driven by fads. He probably couldn't have imagined the controversy that would dog his works, however. Not over issues of merit, on which nearly everyone except T. S. Eliot agrees. The dispute, which began not long after his death, had to do with authorship. Who wrote the plays of Shakespeare? The answer would seem to be obvious - Shakespeare! But no, that would be too easy. In the years following the Bard's death, a conspiracy theory of unparalleled proportions sprang up. The charge that Shakespeare was not really the author of Shakespeare's plays first arose in the 19th century. This cottage industry has managed to prosper despite an astounding lack of evidence to even vaguely support the notion. There was definitely a William Shakespeare, he definitely came from Stratford, and plays were definitely published during his lifetime under his name. It's documented that a William Shakespeare was an actor at the theater where Shakespeare's plays also debuted. Some of Shakespeare's signed works were published as early as 1593. Despite all these facts, which are documented at least as well as anything from the 16th century is documented, a virtually unending series of scholars have sublimated their repressed drives into theory after theory, tediously making the case that virtually anyone else alive at the time wrote the plays which have been attributed to William Shakespeare since the day they were first published. Among the usual suspects: Francis Bacon, Christopher Marlowe, Ben Jonson, the Earl of Oxford, and even the Countess of Pembroke, Mary Sidney Herbert. Part of the reason for the confusion is a profusion of Shakespeare forgeries, starting a few minutes after the man's death and continuing to this day. The forgeries include everything from deeds to sonnets to entire plays. There have been so many forgeries and apocryphal writings that it's not even possible to be absolutely certain of the number of plays and sonnets originally belonged to the Bard. (The numbers given above are based on the most conservative view.) Of course, it's great fun to sit around and argue for hours over which 16th century luminary might have written Shakespeare's plays and why, detailing your arguments with extensive citations, semantic analysis and complex anagrams. Indeed, it's hard to imagine what could be funner! Sure, you might be missing out on great sex, great food, sunshine and exercise, but you can rest easy knowing you've wasted years of your life trying to prove a premise that's probably wrong and really not all that important anyway.
Timeline
|


To make a deduction.
This is when you come to a specific conclusion having thought about all the evidence that is available.
What can you deduce from the following:
All people with green hair are kind
All kind people are happy working with computers?


This is a calculator to estimate your ROI if the property is for resale or rental
Congratulations! You have found a good ROI. Contact Maggie Sun to see the house: maggiesunjingyu@gmail.com


causal_da.api_support.logging¶
causal_da.api_support.logging.base¶
-
class
DummyRunLogger
¶ Bases:
causal_da.api_support.logging.base.RunLogger
Utility class to placehold the logger.
Initialize the run-logger.
-
end_run
()¶ A callback called at the end of the experiment run.
-
log_artifact
(_path, folder_name)¶ Log an artifact (e.g., a model).
-
log_metrics
(dic, step=None)¶ Log the metrics.
-
log_params
(params_dict)¶ Log parameters.
-
log_params_exp_wide
(params_dict)¶ Log the experiment-wide parameters.
Log the tags.
Log the experiment-wide tags.
-
start_run
()¶ A callback called at the beginning of the experiment run.
-
-
class
RunLogger
¶ Bases:
object
The base class of the run_loggers used to record the experiment setup/records.
-
abstract
end_run
()¶ A callback called at the end of the experiment run.
Get the tag value.
- Parameters
key (
str
) – the key to access the tag value.- Return type
Any
-
abstract
log_artifact
(_path, artifact_subdir)¶ Record an artifact (e.g., a model) that is already saved at the specified path. The behavior may differ among different run loggers. For example, this method may retrieve the data in
_path
and save it to another location under the sub-directoryartifact_dir
.- Parameters
_path (
Union
[str
,Path
]) – the path where the artifact has been saved.artifact_subdir (
str
) – a string to specify under what sub-directory names the artifact should be stored in the database, remote storage, etc.
-
abstract
log_metrics
(dic, step=None)¶ Log the metrics.
- Parameters
dic (
Dict
[str
,Any
]) – the dictionary containing the values to be recorded.
-
abstract
log_params
(params_dict)¶ Log parameters.
-
abstract
log_params_exp_wide
(params_dict)¶ Log the experiment-wide parameters.
Log the tags.
Log the experiment-wide tags.
-
abstract
start_run
()¶ A callback called at the beginning of the experiment run.
-
abstract
causal_da.api_support.logging.model_logger¶
-
class
MLFlowModelLogger
(path, db_key, run_logger, compress_format=None)¶ Bases:
causal_da.api_support.logging.model_logger.MLFlowModelSaver
The model saver class using
mlflow.pytorch
. This is more handy thanMLFlowMultiModelLogger
when we only save the model once.- Parameters
path (
str
) – the path where the model should be saved.db_key (
str
) – the database key to save the model path.run_logger (
RunLogger
) – the logger to save the experiment information.compress_format (
Optional
[str
]) – the format of compression (None
: default'zip'
is used. Other options are('zip', 'tar', 'gztar', 'bztar', 'xztar')
).
-
load
()¶ Load the model using
mlflow.pytorch.load_model
.
-
save
(model)¶ Save the model using
mlflow.pytorch.save_model
.- Parameters
model – the
pytorch
model to be saved.
-
class
MLFlowModelSaver
(path)¶ Bases:
object
The base class of the model saver classes using
mlflow.pytorch
.- Parameters
path (
str
) – the path at which the model should be stored.
-
load
()¶ Load the model using
mlflow.pytorch.load_model
.
-
classmethod
load_zip
(zip_path)¶ Utility class method to load a zipped model using
mlflow.pytorch.load_model
.- Parameters
zip_path (
str
) – path to the zipped model.
-
save
(model)¶ Save the model using
mlflow.pytorch.save_model
.- Parameters
model – the
pytorch
model to be saved.
-
class
MLFlowMultiModelLogger
(path, db_key, run_logger, compress_format=None)¶ Bases:
causal_da.api_support.logging.model_logger.MLFlowModelSaver
The model saver class using
mlflow.pytorch
. This is more handy thanMLFlowModelLogger
when we save the intermediate models during a training loop.- Parameters
path (
str
) – the path where the model should be saved.db_key (
str
) – the database key to save the model path.run_logger (
RunLogger
) – the logger to save the experiment information.compress_format – the format of compression (
None
: default'zip'
is used. Other options are('zip', 'tar', 'gztar', 'bztar', 'xztar')
).
-
save
(model, epoch)¶ Save the intermediate model of a training epoch.
- Parameters
model – the model to be saved.
epoch – the epoch at which this method is called.
causal_da.api_support.logging.mongo_sacred¶
-
class
MongoAndSacredRunLogger
(experiment_name, observer, mongo_table, artifact_temp_dir='sacred_artifact/1')¶ Bases:
causal_da.api_support.logging.base.RunLogger
A run logger based on MongoDB and Sacred.
- Parameters
experiment_name (
str
) – the name of the experiment.observer (
MongoObserver
) – the observer object.mongo_table (
Collection
) – the table object of PyMongo.artifact_temp_dir (
str
) – the path to the directory that can be used to store the artifacts temporarily.
-
end_run
()¶ A callback called at the end of the experiment run.
-
get_current_run_id
()¶ Obtain the current Sacred run_id.
Get the tag value.
- Parameters
key (
str
) – the key to access the tag value.- Return type
Any
-
log_artifact
(_path, artifact_subdir)¶ Record an artifact (e.g., a model) that is already saved at the specified path.
- Parameters
_path (
Union
[str
,Path
]) – the path where the artifact has been saved.artifact_subdir (
str
) – a string to specify under what sub-directory names the artifact should be stored in the database, remote storage, etc.
-
log_metrics
(dic, step=None)¶ Log the metrics.
- Parameters
dic (
Dict
[str
,Union
[float
,int
]]) – the dictionary containing the values to be recorded.
-
log_params
(params_dict)¶ Log parameters.
- Return type
None
-
log_params_exp_wide
(params_dict)¶ Log the experiment-wide parameters.
-
perform_run
(func, params)¶ The method to perform an experiment.
- Parameters
func (
Callable
[[str
,Any
],Any
]) – a function of two variables:(idx, params)
.idx
is a string indicating the unique identifier of the experiment run that can be used in the function, e.g., to save artifacts with names that are distinct among different runs.params (
Any
) – the parameters to be passed tofunc
.
Note
Here, we capsule the experiment starting procedure of Sacred for the convenience of the user.
Log the tags.
- Return type
None
Log the experiment-wide tags.
-
start_run
()¶ A callback called at the beginning of the experiment run.
-
update_mongo
(dic)¶ Update a dictionary to the MongoDB.
- Parameters
dic (
Dict
[str
,Any
]) – dictionary containing the key-value pairs to be updated.- Return type
None
-
sanitize_data
(r)¶ Sanitize the data values to cast to the types that can be handled by MongoDB (via PyMongo).
causal_da.api_support.logging.param_history_manager¶
-
class
PandasParamHistoryManager
(df)¶ Bases:
causal_da.api_support.logging.param_history_manager.ParamHistoryManagerBase
The parameter history manager based on
pandas.DataFrame
.- Parameters
df (
DataFrame
) – the data frame containing the previous records of the parameters and the evaluation results.
-
filter
(param_grid)¶ - Parameters
param_grid (
List
[Dict
[str
,Any
]]) – the list of records to be filtered in.
Examples
>>> import pandas as pd >>> df = pd.DataFrame.from_dict([{'a': 11, 'b': 12, 'c': 10}]) >>> param_grid = [{'a': 11, 'b': 12, 'c': 10}, {'a': 21, 'b': 22, 'c': 10}] >>> PandasParamHistoryManager(df).filter(param_grid) [{'a': 21, 'b': 22, 'c': 10}]
This method considers the parameter to be existent even if the candidate contains only a subset of the values (i.e., implicitly assumes that no removal of the keys occurs along the development of the method).
>>> PandasParamHistoryManager(df).filter([{'a': 11, 'b': 12}]) []
- Return type
Iterable
[Dict
]
-
class
ParamHistoryManagerBase
¶ Bases:
object
The base class of a parameter history manager.
-
abstract
filter
(param_grid)¶ Given a set of candidate parameter sets, this function removes all existing sets and leaves the parameter set that is unexistent in the database of the previous runs. The set of keys appearing in its database needs to be a superset of the keys apperaing in the parameter candidates.
- Parameters
param_grid (
List
[Dict
[str
,Any
]]) – the list of records to be filtered in.- Return type
Iterable
[Dict
]
-
abstract


Under Armour Athletes Database
Home
About
Gallery
Resources
Adrian Hernandez
Title: Professional boxer
Biography:
Adrian Hernández is a Mexican professional boxer in the Light Flyweight division. Hernández is a former two-time WBC Light Flyweight Champion.


Marshall is a Second Year Student at University of California, San Diego, studying Computer Science and Business. He currently serves as the Technical Project Manager at Triptive Inc., Web Developer at the Center for Aerosol Impact on the Climate and Environment, as well as Graphic Designer at Thrugood Marshall's Dean's Office.


Display the outer height of div
outerHeight() - returns the outer height of an element (includes padding and border).


pingouin.wilcoxon¶
-
pingouin.
wilcoxon
(x, y=None, alternative='two-sided', **kwargs)¶ Wilcoxon signed-rank test. It is the non-parametric version of the paired T-test.
- Parameters
- xarray_like
Either the first set of measurements (in which case y is the second set of measurements), or the differences between two sets of measurements (in which case y is not to be specified.) Must be one-dimensional.
- yarray_like
Either the second set of measurements (if x is the first set of measurements), or not specified (if x is the differences between two sets of measurements.) Must be one-dimensional.
- alternativestring
Defines the alternative hypothesis, or tail of the test. Must be one of “two-sided” (default), “greater” or “less”. See
scipy.stats.wilcoxon()
for more details.- **kwargsdict
Additional keywords arguments that are passed to
scipy.stats.wilcoxon()
.
- Returns
- stats
pandas.DataFrame
'W-val'
: W-value'alternative'
: tail of the test'p-val'
: p-value'RBC'
: matched pairs rank-biserial correlation (effect size)'CLES'
: common language effect size
- stats
See also
Notes
The Wilcoxon signed-rank test [1] tests the null hypothesis that two related paired samples come from the same distribution. In particular, it tests whether the distribution of the differences x - y is symmetric about zero.
Important
Pingouin automatically applies a continuity correction. Therefore, the p-values will be slightly different than
scipy.stats.wilcoxon()
unlesscorrection=True
is explicitly passed to the latter.In addition to the test statistic and p-values, Pingouin also computes two measures of effect size. The matched pairs rank biserial correlation [2] is the simple difference between the proportion of favorable and unfavorable evidence; in the case of the Wilcoxon signed-rank test, the evidence consists of rank sums (Kerby 2014):
\[r = f - u\]The common language effect size is the proportion of pairs where
x
is higher thany
. It was first introduced by McGraw and Wong (1992) [3]. Pingouin uses a brute-force version of the formula given by Vargha and Delaney 2000 [4]:\[\text{CL} = P(X > Y) + .5 \times P(X = Y)\]The advantage is of this method are twofold. First, the brute-force approach pairs each observation of
x
to itsy
counterpart, and therefore does not require normally distributed data. Second, the formula takes ties into account and therefore works with ordinal data.When tail is
'less'
, the CLES is then set to \(1 - \text{CL}\), which gives the proportion of pairs wherex
is lower thany
.References
- 1
Wilcoxon, F. (1945). Individual comparisons by ranking methods. Biometrics bulletin, 1(6), 80-83.
- 2
Kerby, D. S. (2014). The simple difference formula: An approach to teaching nonparametric correlation. Comprehensive Psychology, 3, 11-IT.
- 3
McGraw, K. O., & Wong, S. P. (1992). A common language effect size statistic. Psychological bulletin, 111(2), 361.
- 4
Vargha, A., & Delaney, H. D. (2000). A Critique and Improvement of the “CL” Common Language Effect Size Statistics of McGraw and Wong. Journal of Educational and Behavioral Statistics: A Quarterly Publication Sponsored by the American Educational Research Association and the American Statistical Association, 25(2), 101–132. https://doi.org/10.2307/1165329
Examples
Wilcoxon test on two related samples.
>>> import numpy as np >>> import pingouin as pg >>> x = np.array([20, 22, 19, 20, 22, 18, 24, 20, 19, 24, 26, 13]) >>> y = np.array([38, 37, 33, 29, 14, 12, 20, 22, 17, 25, 26, 16]) >>> pg.wilcoxon(x, y, alternative='two-sided') W-val alternative p-val RBC CLES Wilcoxon 20.5 two-sided 0.285765 -0.378788 0.395833
Same but using pre-computed differences. However, the CLES effect size cannot be computed as it requires the raw data.
>>> pg.wilcoxon(x - y) W-val alternative p-val RBC CLES Wilcoxon 20.5 two-sided 0.285765 -0.378788 NaN
Compare with SciPy
>>> import scipy >>> scipy.stats.wilcoxon(x, y) WilcoxonResult(statistic=20.5, pvalue=0.2661660677806492)
The p-value is not exactly similar to Pingouin. This is because Pingouin automatically applies a continuity correction. Disabling it gives the same p-value as scipy:
>>> pg.wilcoxon(x, y, alternative='two-sided', correction=False) W-val alternative p-val RBC CLES Wilcoxon 20.5 two-sided 0.266166 -0.378788 0.395833
One-sided test
>>> pg.wilcoxon(x, y, alternative='greater') W-val alternative p-val RBC CLES Wilcoxon 20.5 greater 0.876244 -0.378788 0.395833
>>> pg.wilcoxon(x, y, alternative='less') W-val alternative p-val RBC CLES Wilcoxon 20.5 less 0.142883 -0.378788 0.604167


| Team Inventory |
This document details each members relevant experiences and abilities coming into this project. |
09/20/2017 |
|
| Team Standards |
Agreed upon standards to how we will conduct our workflow, meetings, decision making and overall vision for cooperation and teamwork. |
09/20/2017 |
|
| Project Mini Intro Slideshow |
The slideshow used to introduce the project to the capstone class. |
10/02/2017 |
|
| Development Environment Proposal Sheet |
Compares and contrasts potential development environments suitable for our application's development. |
11/05/2017 |
|
| Technology Feasibility Report |
A comprehensive report of the different tools at our disposal and our reasoning for using said tools. |
11/06/2017 |
|
| Design Review 1 |
Slides for our first design review. |
11/18/2017 |
|
| Requirements Specification |
Requirements document for Smart Shopping app. |
12/05/2017 |
|
| Software Design |
Document that outlines our design for Smart Shopping application. |
02/15/2018 |
|
| Design Review 2 |
Slides for our second design review. |
03/08/2018 |
|
| Software Testing Plan |
Document that outlines our testing plan for Smart Shopping. |
04/03/2018 |
|
| Design Review 3 |
Slides for our third design review. |
04/12/2018 |
|
| Final UGRADS Presentation |
Final UGRADS slides we used during UGRADS. (Coming soon) |
N/A |
|
| Capstone Poster |
Our poster we presented at UGRADS. (Coming soon) |
N/A |
|
| Final Report |
Final report summing up the final update for this project for this capstone. (Coming soon) |
N/A |
|


With images:
Checked
Unchecked
Checked
Unchecked
With pseudo-class:
Checked
Unchecked
Disabled
Checked
Unchecked
Disabled


This is a website which allows you to know your Akan name just by providing your birth year, date and month.
Don't know what Akan names are? We got you covered!
Akan names are derived from Ghanaian culture.
Frequently in Ghana, children are given their first name as a 'day name' which corresponds to the day in the week they were born.
Here are Ghanaian day names:


Standard 1
Standard 2
drawTitles, drawMessage, drawBars
drawMessage, drawBars
drawTitles, drawBars
drawTitles, drawMessage
drawMessage
drawTitles
drawTitlesWithoutTooltip
drawTitlesTooltipAndElement


The readLine()
method.
The readLine()
method reads a line of text from
a character-oriented input stream,
and puts it into a String object
which it returns as a reference.
If there is no more data in the file,
it returns null
.
import java.io.*; class ReadTextFile { public static void main ( String[] args ) { String fileName = "reaper.txt" ; String line; try { BufferedReader in = new BufferedReader( new FileReader( fileName ) ); line = in.readLine(); while ( line != null ) // continue until end of file { System.out.println( line ); line = in.readLine(); } in.close(); } catch ( IOException iox ) { System.out.println("Problem reading " + fileName ); } } }
The file "reaper.txt" is opened for reading
when the
FileReader
stream is constructed.
If the file does not exist in the current directory,
an IOException is thrown.
Next, the program reads each line of the file and writes
it to the monitor.
When end-of-file is detected the program quits.
This is an extremely common programming pattern: reading and processing data until end-of-file. It would be worth while to play with this program. Create "reaper.txt" with Notepad if it does not already exist.


{include file='../../html/public/header' /}
{include file='../../html/public/nav1' /}
{include file='../../html/public/model' /}
{if condition="($Think.server.REQUEST_URI =='/')"}
{include file='../../html/public/search' /}
{/if}
{include file='../../html/public/nav2' /}
{__CONTENT__}
{if condition="($Think.server.REQUEST_URI !='/register')"}
{include file='../../html/public/footer' /}
{/if}


| Psy::Output::Blockmeta |
Psy::Output::Blkmetanex
Version 0.02
Output subclass for a Psy object. Referenced externally only. Inherited via AUTOLOAD through Psy::Output::Output, see therein for general usage.
This output was originally concieved as a way to plot descriptive states for a given block on a tree (some nice phenetic stuff). After some though/development on the system I found that the Lutzoni lab ARC software does more or less what I wanted to do.
Miadlikowska, Lutzoni, Goward, Zoller, Posada (2003) ``New approach to an old problem: Gap-rich regions from ITS and rDNA large-subunit are incorporated into phylogenetic analyses to resolve the Peltigera canina species complex.'', Mycologia 95(6):1181-1203.
Therefor, {Miadlikowska et al., 2003 should be given credit for much of the ideas coded herin, though with very few exceptions the implementation is mine (Matt). I have retained the character order they present for ease of comparison.
``F. Kauff, J. Miadlikowska & F. Lutzoni (2003), ''ARC - a program for Ambiguous Regions Coding``, distributed by the authors (http://www.lutzonilab.net/pages/download.shtml), Dept. of Biology, Duke University, USA'' hmm- did he code this?
Their ARC characters are:
| (1) sequence length, | ||
| (2) | A frequency | (no. of 'A' divided by sequence length) |
| (3) | C frequency | (no. of 'C' divided by sequence length) |
| (4) | G frequency | (no. of 'G' divided by sequence length) |
| (5) | T frequency | (no. of 'T' divided by sequence length) |
| (6) | AA frequency | (no. of 'AA' divided by sequence length-1) |
| (7) | AC frequency | (no. of 'AC' divided by sequence length-1) |
| (8) | AG frequency | (no. of 'AG' divided by sequence length-1) |
| (9) | AT frequency | (no. of 'AT' divided by sequence length-1) |
| (10) | CC frequency | (no. of 'CC' divided by sequence length-1) |
| (11) | CG frequency | (no. of 'CG' divided by sequence length-1) |
| (12) | CT frequency | (no. of 'CT' divided by sequence length-1) |
| (13) | GG frequency | (no. of 'GG' divided by sequence length-1) |
| (14) | GT frequency | (no. of 'GT' divided by sequence length-1) |
| (15) | TT frequency | (no. of 'TT' divided by sequence length-1) |
| (16) | A pairing | (no. of 'AA' divided by total no. of 'A') |
| (17) | C pairing | (no. of 'CC' divided by total no. of 'C') |
| (18) | G pairing | (no. of 'GG' divided by total no. of 'G') |
| (19) | T pairing | (no. of 'TT' divided by total no. of 'T') |
| (20) | A distribution | (no. of spaces between 'A' divided by total no. of 'A') |
| (21) | C distribution | (no. of spaces between 'C' divided by total no. of 'C') |
| (22) | G distribution | (no. of spaces between 'G' divided by total no. of 'G') |
| (23) | T distribution | (no. of spaces between 'T' divided by total no. of 'T') |
| (24+x) | motif presence [1] or absence [0] ### NOTE THAT THIS IS DEFINED a-priori ### |
Noteable differences from their methods are as follows: 1) Psy has no amino acid functionality. 2) Psy can not read ARC formated input (yet) 3) The motif presence/absence (character 24+x) has been extended by allowing for automatic generation of motifs based on sampleing the data (kwords). 4) Several addition characters have been added (length, counts rather than pct). 5) Outputting is much more flexible, as it is integrated into overall slice/matrix functinos available to Psy. Available output formats are now 2 types of nexus files formatted for use in Mesquite and at TNT readable format.
n) Pair counts are sliding in Psy, I need ot check if they are so in ARC. e.g. 'AAAA' has 3 'AA' pairs, not 2.
| Required parameters | |
| -mx |
| Optional parameters | |
| '-out_format' => < mesquite_chr_by_blk | mesquite_blk_by_chr | [tnt] | original_arc > |
If a -slice is passed it will be used for taxa partition. In absence of -plan it will also be used in place of origSlice (see below).
If no -plan is given each block? in the origSlice will be individually translated to metachars.
A -plan can be made as follows:
my $p; $p->{0}->{blks} = ([0 1 2 3 4]); # block 0 will be a fusion of blocks 0..4. Required. $p->{0}->{name} = 'foo'; # block 0 label will be 'foo'. Not necessary, defaults to the index if not set. $p->{0}->{type} = 'trans'; # block 0 will be translated to meta characters or left as nucleotide < 'trans' | 'orig' >. Not required, defaults to 'trans' if not set. $p->{1} ...
'-plan' => $p And used like: my $o = output->new(); $o->Blockmeta('-mx' => $mx, '-plan' => $p);
| If $mx is a matrix, a plan can also be generated like: | |
| my $p = $mx->plan; |
| Psy::Output::Blockmeta |


Past AppointmentsUpcoming Appointments
| {{appointment.Patientname}}{{appointment.PatientGender}} | {{appointment.DateAndTime}} Incidence : {{appointment.incidentsname_c}} Mode : {{appointment.mode}} | View / Edit Emr | Print Prescription No Summary Print Prescription | Generate Bill Print Bill |
Loading Past Appointments
Past Appointments are not available.


What Bird Is It?
Identify the sounds of birds seen recently near a particular location. Built using
geolocation
,
eBird API
, and
xeno-canto API
What Bird Is It?
loading
sighting
next bird
answer
Bird Songs
loading
birds


PHY 132-02 Mentor Webpage
Mentor Sessions
To help accomodate a variety of student needs, all PHY 132 mentors invite students from any section of the course to attend any mentor session. All mentor sessions will be held in Noyce 1022 at the times below...
| Sunday |
Monday |
Tuesday |
Wednesday |
Thursday |
Friday |
Saturday |
7pm-9pm (Stephen) |
8pm-9pm (Avery) |
7pm-8pm (Dreycen) |
7pm-9pm (All) |
none |
none |
none |
Grinnell Resources
Math Help: Visit the Math Lab for help with Calculus and other math skills.
Bias incident: Click here to get to the Intercultural Affairs Office.
The Physics SEPC meets in the Physics Commons (Noyce 1321) weekly from 11:30am-12:00pm. All are welcome to attend and provide input.
email: physepc (at) grinnell (dot) edu
Physics faculty are often happy to make an appointment with students. Their Grinnell websites are listed here.


Hello, Please, consider this mail as very important and do let me know your honest response within the shortest time possible…Obviously, you have no knowledge of who I am, but I am Ms Lome Glory, from Sierra Leone, but resident in Gambia (West Africa). I am interested in investing in any lucrative business enterprise in your country and do want to use this opportunity to seek your advice on the possibility of investment in your area. Over the recent years, there have been cases of political instability in most countries here in Africa and as a result, I am afraid to invest my money here. On this note, I have decided to look else where for possible investment opportunities, hoping that I would achieve this goal with the assistance of a reliable person. I would like to know if it would be secured and lucrative to invest in your country and after a careful feasibility study of the various possible fields or industries in your country by your kind assistance, I would transfer my funds to your country for investment. In a nutshell, I do have a large amount of money to establish an ultra modern company in your country, but I will like to know the possible channels available in your area. Please, do assist me carry out a careful survey and get back to me on the various possibilities. If you do not have any much knowledge about investment or business, I will appreciate if you could recommend me to some business experts individuals/companies/business consultants) in your area, who might be of help to me. I do hope to know you better in the course of time and if trust is established between us, I might need you to be actively and directly involved in this proposed venture. But for the time being, I would like to know you better and hope we could get acquainted within the shortest time possible. In my next correspondence with you, I will give you a clue of how much I intend to invest in your country, but for now, I look forward to receiving your response and hope this opportunity would bring us closer for a possible business relationship between us in the near future. You do reply me with this email<EMAIL_ADDRESS><EMAIL_ADDRESS>Have a nice day and best regards, Ms Lome Glory


My name is Pranay Patel; I am a curious petroleum engineering student currently in the fourth year of B.Tech at Pandit Deendayal Petroleum University and currently, I am serving as Chief Operating Officer at FIPI PDPU Students Chapter where we bridge the gap between industry and academia by organizing highly interactive events for the students at PDPU to share, acquire and harvest their knowledge.
And I aspire to work in the energy sector especially in the field which would allow me to meet new people, letting me know their culture, and inspire me to work hard for the betterment of the society.
one more thing here is a link to Satyalekhan another website that I built for the satirical poems which I love to write.


Here are a few useful things I learned while reading Buchanan's Journal Of Man, Volume 1 Number 4, published in May 1887:
“Pianos have lately been made from paper in Germany, instead of wood, with great improvement in the tone.”
“There is no denying that the young man about town of the nineteenth century is a blot upon our boasted modern civilization. His is not a pleasant figure to contemplate, though it is one that we all see very often and know very well—clothed irreproachably in the most expensive raiment that London tailors and unlimited credit can supply. He lives lazily and luxuriously on his father's money and his wife's, and, being after his natural term of days laid away in a tomb at Mt. Auburn, ends his existence without making any more impression upon the world's history than a falling rose leaf, or an August cricket's faintest chirp.”
“In 1885 we were informed of the success of spirits at Cleveland, Ohio, in communicating messages by the telegraphic method in rapping, in which our millionaire friend, Mr. J. H. Wade, has taken much interest. A little apparatus has been constructed, with which the spirits give their communications in great variety. I have repeatedly stated that the diagnoses and prescriptions of deceased physicians have always proved in my experience more reliable than those of the living. This has been verified at Cleveland. The late Dr. Wells of Brooklyn has been giving diagnoses and prescriptions through the telegraph.”
I think we can agree with the correspondent of the Vineland Rostrum, who said of the Journal's editor J R Buchanan “We never read an article from the pen of this world-renowned thinker, but that we feel we are in the presence of one whose shoes' latchet we are unworthy to unloose”.
Many thanks to Odd Ends.


|
|
CIFXUVGenerator Class ReferenceInheritance diagram for CIFXUVGenerator:
List of all members.
Constructor & Destructor Documentation
| CIFXUVGenerator::CIFXUVGenerator |
( |
|
) |
[private] |
|
| CIFXUVGenerator::~CIFXUVGenerator |
( |
|
) |
[private, virtual] |
|
Member Function Documentation
| U32 CIFXUVGenerator::AddRef |
( |
void |
|
) |
[virtual] |
|
|
|
This method increments the reference count for an interface on a component.
- Note:
- It should be called for every new copy of a pointer to an interface on a given component.
- Returns:
- It returns a U32 that contains a value from 1 to 2^32 - 1 that defines the new reference count. The return value should only be used for debugging purposes.
Implements IFXUnknown. |
|
|
Generate texture coordinates in pMesh.
- Parameters:
-
| pMesh | The mesh that will contain the generated texture coordinates. |
| pMapParams | Pointer to an IFXUVMapParameters object that contains more detailed parameters to the texture coordinate generation function. |
| pModelMatrix | The local to world matrix of pMesh. |
| pViewMatrix | The world to local matrix of the current IFXView object (camera). |
| pLightSet | Pointer to an IFXLightSet that contains all of the lights in the scene that affect pMesh. |
- Returns:
- An IFXRESULT value.
- Return values:
-
| IFX_OK | No error. |
| IFX_E_INVALID_POINTER | One or more of the required parameters were NULL. |
| IFX_E_INVALID_RANGE | One of the values contained in pMapParams was invalid. |
Implements IFXUVGenerator. |
| IFXRESULT CIFXUVGenerator::QueryInterface |
( |
IFXREFIID |
interfaceId, |
|
|
void ** |
ppInterface |
|
) |
[virtual] |
|
|
|
This method provides access to the various interfaces supported by a component.
Upon success, it increments the component's reference count and hands back a pointer to the specified interface.
- Note:
- A number of rules must be adhered to by all implementations of IFXAPI QueryInterface . For a list of such rules, refer to the IFXCOM usage guidelines.
- Returns:
- Upon success, IFX_OK is returned. Otherwise, either IFX_E_INVALID_POINTER or IFX_E_UNSUPPORTED are returned.
Implements IFXUnknown. |
| U32 CIFXUVGenerator::Release |
( |
void |
|
) |
[virtual] |
|
|
|
This method decrements the reference count for the calling interface on a component.
- Note:
- If the reference count on a component falls to zero, the component is destroyed.
- Returns:
- It returns a U32 that contains a value from 1 to 2^32 - 1 that defines the new reference count. The return value should only be used for debugging purposes.
Implements IFXUnknown. |
Friends And Related Function Documentation
| IFXRESULT IFXAPI_CALLTYPE CIFXUVGenerator_Factory |
( |
IFXREFIID |
interfaceId, |
|
|
void ** |
ppInterface |
|
) |
[friend] |
|
Member Data Documentation
© 1999 - 2006 Intel Corporation. All rights reserved.
* Other names and brands may be claimed as the property of others.
|
|


Quick Start
Technological Overview
In Una, there are two kinds of clients:
- Screen: The centralized display that performs the bulk of the processing, usually accessed via a browser on a desktop/laptop.
- Controller: The medium for user input, usually accessed via a browser on a mobile device.
The Una Server acts as a relay between the Screen and the Controller(s), passing messages between them. By doing so, we can keep the Server footprint small with minimal processing, (as all we are doing is relaying messages between the Screen and Controller).
Both the Screen and the Controller comprises of client-side JavaScript code, and are connected to the Server via websockets through socket.io. The Una Server is written in node.js.
Una makes it easy for you to write client-to-client code that is supported via websockets, having you to write little, if any, server-side code.
Una Server Installation
As Una is a node.js library, you will need to have node.js installed on your server in order to use it. Follow the instructions below to install node.js on your platform of choice.
Una is available as a package in npm. To install Una to your project, simply type the following in shell:
npm install una
And you are done!
The Una Server
Installing
After installing Una, create an app.js
file, which would be the starting point of
your node.js application. Type the following code:
una = require('una');
una.listen(3216);
Run your node.js application in shell with:
$ node app.js
info - socket.io started
Una server listening on port 3216
Note: Una is built on top of express and socket.io, hence, these dependencies are automatically installed when you install Una.
una.listen
takes in a port number, and creates a HttpServer listening on that
port number, running the express framework. In addition, it also launches the
socket.io client listening on the same port. To gain access to the express app
object and the socket.io io object, use the following code:
// express app instance:
var app = una.app;
// socket.io io instance
var io = una.io;
// express library:
var express = una.express;
Serving Static HTML Files
We want a way to serve static HTML files using the express framework. Modify app.js
to the following:
path = require('path');
una = require('una');
var app = una.app;
var express = una.express;
// Configure express to use the /public folder to serve static files
app.use(express.static(path.join(__dirname, 'public'));
una.listen(3216);
This will configure express to serve static files from the /public
directory.
Since Una is a wrapper around express and socket.io, you may use the express
client to serve other routes that your application needs.
Una Screen and Controller
Room
In Una, rooms are thought of as collections of Screen and Controllers. The Screen and Controllers can only communicate with each other if they are in the same room. You can think of a room as an instance of a game, where there is one Screen which shows the state of that room, and controllers which would be changing the state of the room by sending messages to the Screen.
Note that in relay mode, there can only be one Screen active at any time for each room. All the controllers in that room TODO
Installation
For your client side Una code, you would need to include the following javascript file in your HTML code:
<script src='/socket.io/socket.io.js'></script>
<script src='/una_js/una.js'></script>
Registration
You will need to identify whether the page is to be used as a Screen or as a Controller, by calling the registration method.
Screen
var room_id = 'room1';
var screen_data = {name: 'screen'};
UnaScreen.register(room_id, screen_data, function(res) {
if (res.success) {
// Screen registered successfully
} else {
// Screen registration failed
}
});
Controller
var room_id = 'room1';
var controller_data = {name: 'player1'};
UnaController.register(room_id, controller_data, function(res) {
if (res.success) {
// Controller registered successfully
} else {
// Controller registration failed
}
});
The first parameter of the register method is the room id, a unique string that identifies the room. The second parameter is the client data, and it can contain any Javascript object that will be used to identify this particular client. All subsequent messages sent from the page will include this client data object for the receiver to identify the origin of the messages.
Sending Data
To send data, use the following sendTo
methods:
Controller
UnaController.sendToScreen(<type_of_event>, { data: 'data' });
<type_of_event>
is a string, which the Screen will use to identify the type of sendTo
event,
and the second parameter is a JavaScript object of the data to send to the screen.
Screen
UnaScreen.sendToController(<controller_id>, <type_of_event>, {data: 'data'})
The Screen can also send data to a particular controller. The <controller_id>
can
be obtained from res.una.id
of the controller when it was first registered,
or after an onControllerInput
event.
Receiving Data
To listen for data, use the following onInput
methods:
Controller
UnaController.onScreenInput(<type_of_event>, function(res) {
// <type_of_event>: This string should correspond to the string passed in to the `sendToController` function from the Screen
// res.una: Una header
// res.una.user_data: The user data of the Screen sender
// res.una.id: Unique id of the sender
// res.payload: Payload object that was sent by the screen
});
Screen
UnaScreen.onControllerInput(<type_of_event>, function(res) {
// <type_of_event>: This string should correspond to the string passed in to the `sendToScreen` function from the Controller
// res.una: Una header
// res.una.user_data: The user data of the Controller sender
// res.una.id: Unique id of the sender
// res.payload: Payload object that was sent by the controller
});
res.una
is the Una Header attached to every message, and contains:
-
user_data
that was supplied when the Screen/Controller was registered -
id
, a unique id identifying the client


public static final class R.string
extends java.lang.Object
| Constructor and Description |
|---|
R.string() |
public static final int action_settings
public static final int add_answer
public static final int add_reply
public static final int answer
public static final int answer1
public static final int answer_state
public static final int app_name
public static final int author_name
public static final int cancel
public static final int change
public static final int content
public static final int current_question
public static final int desc
public static final int edit
public static final int fav_question
public static final int favorite
public static final int footer_hint_normal
public static final int footer_hint_ready
public static final int header_hint_loading
public static final int header_hint_normal
public static final int header_hint_ready
public static final int header_last_time
public static final int hello_world
public static final int local_question
public static final int login
public static final int logout
public static final int menu_add
public static final int menu_fav
public static final int menu_home
public static final int menu_profile
public static final int menu_search
public static final int most_voteA
public static final int most_voteQ
public static final int my_question
public static final int question
public static final int question_title
public static final int remove
public static final int reply
public static final int reply_group
public static final int save
public static final int search
public static final int single_answer
public static final int single_question
public static final int sort_label
public static final int submit
public static final int time
public static final int title
public static final int title_activity_create_answer
public static final int title_activity_create_answer_reply
public static final int title_activity_create_input
public static final int title_activity_create_question_reply
public static final int title_activity_internet_test
public static final int title_activity_login
public static final int title_activity_main
public static final int title_activity_my_favorite
public static final int title_activity_my_local
public static final int title_activity_my_question
public static final int title_activity_question_detail
public static final int title_activity_waiting_list
public static final int upvote
public static final int upvote_state
public static final int waiting_list


http://www.speakers-podium.com/susangranger.
Susan Granger's review of "BLACK AND WHITE" (Palm Pictures/Sony Screen Gems)
There are not too many films that attempt to give viewers an insight into contemporary American society like Spike Lee's "Jungle Fever" and "Get on the Bus" along with Warren Beatty's "Bulworth." But now there's James Toback's "Black and White," which delves into race relations and hip-hop music in New York City. Toback sets the stage in an early classroom scene in which a young black girl talks about how all the white kids she knows romanticize the ghetto life, while all her black friends just want to get out of it. There are several intersecting plotlines. Brooke Shields and Robert Downey Jr. play documentary film-makers examining privileged white teens who are obsessed with street life. That's Elijah Wood, Gaby Hoffman, Bijou Phillips (daughter of John Phillips of the Mamas and the Papas), Eddie Thomas and Kim Matulova. Then there's the rap mogul/gangsta, played by Oli "Power" Grant from Wu-Tang Clan, and Joe Pantoliano as a District Attorney with family problems. Ben Stiller is a crooked cop who bribes a college basketball star, played by Allan Houston of the Knicks, plus Mike Tyson as - who else? - Mike Tyson. Claudia Schiffer surfaces as a grad student. Even Donald Trump's former wife, Marla Maples, shows up. James Toback obviously improvised much of the fragmentary action as he went along with no sense of cohesion or purpose, so this is not a smooth, evenly edited picture, but perhaps it isn't supposed to be. And the most authentic buzz about deceit and treachery comes from the recruited performers, not the professional actors. On the Granger Movie Gauge of 1 to 10, "Black and White" is a complex, sexually energetic, fast-paced 4. It's a risky, interesting concept but not a very good movie.
The review above was posted to the
rec.arts.movies.reviews newsgroup (de.rec.film.kritiken for German reviews).
The Internet Movie Database accepts no responsibility for the contents of the
review and has no editorial control. Unless stated otherwise, the copyright
belongs to the author.
Please direct comments/criticisms of the review to relevant newsgroups.
Broken URLs inthe reviews are the responsibility of the author.
The formatting of the review is likely to differ from the original due
to ASCII to HTML conversion.
Related links: index of all rec.arts.movies.reviews reviews


Spiffy UI isn't just a pretty face. It provides a comprehensive framework for calling REST services from GWT and JavaScript. This includes authentication, error handling, and utilities for handling JSON data.
REST calls are asynchronous network calls. You request data from the server, and at some point later the server responds. In between there could be network timeouts, data corruption, and all the uncertainty of the Internet. Asynchronous network programming is hard; the Spiffy UI framework makes it a little easier.
Spiffy UI abstracts knowledge of Internet protocols and REST into objects called REST beans. From the client point of view: you ask for data and it comes back. We keep it that simple for all the code in our application. Most REST beans implement the RESTObjectCallBack
interface.
RESTObjectCallBack
has just three methods:
public void success(T o); public void error(String message); public void error(RESTException e);
When your REST call returns successfully, success
is called; you get back a Java object with the data from the server. The first error
method is called when there is a generic error like an unplugged network cable. The second error
method happens with more expected errors, like passing invalid data to the server.
Once you've implemented the RESTObjectCallBack
interface, it's time to make your REST call. You can do that with RESTility
. (Yup, we stole the name from Ruby.) RESTility
handles authentication, error handling, and all of the steps involved in making the remote connection. It takes a RESTCallback
and makes the REST call.
RESTCallback
works similarly to RESTObjectCallback
, but it deals with JSON data. A REST call can return any type of data, but Spiffy UI focuses on JSON. The RESTCallback
interface looks like this:
public void onSuccess(JSONValue val); public void onError(int statusCode, String errorResponse); public void onError(RESTException e);
The onSuccess
method takes JSON data and is responsible for parsing that data into a reasonable format. How you handle that JSON is up to you. You can use GWT Overlay types, return the JSONValue
object, or parse the JSON manually into a Java object. In practice most REST calls return simple JSON data which is easy to parse manually.
Spiffy UI's JSONUtil
provides utility methods for safely getting values or objects from a JSONObject
.
The footer in this sample application uses REST to get the version information from the server. This is encapsulated in the VersionInfo
object. It uses a static
method to instantiate the object and get the data from the REST call.
The VersionInfo
object encapsulates this in the getVersionInfo
method:
public static void getVersionInfo(final RESTObjectCallBack<VersionInfo> callback) { if (g_versionInfo != null) { /* The version info doesn't change while the page is still running so we can cache it and save an HTTP call. */ callback.success(g_versionInfo); return; } RESTility.callREST("version", new RESTCallback() { @Override public void onSuccess(JSONValue val) { JSONObject bi = val.isObject(); if (bi == null) { MessageUtil.showError("An error occurred trying to get version info."); return; } g_versionInfo = new VersionInfo(); g_versionInfo.m_version = JSONUtil.getStringValue(bi, "version"); g_versionInfo.m_user = JSONUtil.getStringValue(bi, "user"); g_versionInfo.m_rev = JSONUtil.getStringValue(bi, "rev"); g_versionInfo.m_date = JSONUtil.getDateValueFromMediumDateTime(bi, "date"); if (g_versionInfo.m_date == null) { MessageUtil.showError("Invalid version date: " + JSONUtil.getStringValue(bi, "date")); } callback.success(g_versionInfo); } @Override public void onError(int statusCode, String errorResponse) { callback.error(errorResponse); } @Override public void onError(RESTException e) { callback.error(e); } }); }
The getVersionInfo
method will make the REST call, parse the JSON, and populate the VersionInfo
object. Once it is returned to the RESTObjectCallBack
you can access the VersionInfo
object just like a JavaBean.
In this case the URL of version
will become http://localhost:8080/version
. You can specify any URL you want as long as it doesn't violate the same-origin policy.
It is worth noting that this method returns void
, since this call is asynchronous and must be returned to the calling code later. In this way the method works similarly to a listener.
We can call our VersionInfo
object like this:
VersionInfo.getVersionInfo(new RESTObjectCallBack<VersionInfo>() { public void success(VersionInfo info) { m_footer.setFooterString("Spiffy UI Sample version " + info.getVersion() + " was built on " + DateTimeFormat.getFullDateFormat().format(info.getDate()) + " from revision " + info.getRevision()); } public void error(String message) { MessageUtil.showFatalError(message); } public void error(RESTException e) { MessageUtil.showFatalError(e.getReason()); } });
RESTility
has built-in handling for a Novell-defined REST error format. This is the error format defined for the SOAP protocol, translated to JSON. It looks like this:
{ "Fault" : { "Code" : { "Subcode" : { "Value" : "MyErrorSubCode" }, "Value" : "MyErrorCode" }, "Reason" : { "Text" : "This is why my error happened" } } }
If your REST endpoints return errors in this format, then RESTility
will handle them automatically and return RESTException
objects with the data. If not, it will treat error messages like any other server responses and allow you to handle them in your implementation of success
.
The VersionInfo
object is included in the Spiffy UI application project and populates the footer of this page. An easy way to see it in action is with the Firebug console. This console will show you every REST request made by this sample, and the data sent to and from the client.


$def with () $ top_players_list = model['top_players_list']
$:player_name.split(":")[-1] | |
| Profitable Trades | $:profile_stats['profitable_trades'] |
| Unprofitable Trades | $:profile_stats['unprofitable_trades'] |
| % Profitable | $:scrub.percent_value(profile_stats['percent_profitable']) |
| Trades Influenced | $:profile_stats['total_influenced'] |
| Realized Return | $:scrub.dollar_change(profile_stats['realized_return']) |
| Percent Return | $:scrub.percent_change(profile_stats['total_percent_return']) |


Welcome
This website contains two of the best recipes for university students.
The first recipe is for brownie in a cup.
The second recipe is for apple crisp in a mug.
Finally, a conversion table to convert the measurements into different units.


@* * Copyright 2023 HM Revenue & Customs * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. *@ @import views.ViewUtils._ @import config.FrontendAppConfig @this( config: FrontendAppConfig, main_template: templates.GovukLayoutWrapper, h1: components.h1, link: components.link ) @()(implicit request: Request[_], messages: Messages, appConfig: FrontendAppConfig) @main_template(Some(titleNoForm("incorrect-details.title")), signOut = false) { @h1("incorrect-details.heading")
@messages("incorrect-details.notAnOrganisation.p1") @messages("incorrect-details.notAnOrganisation.p1.link")
@messages("incorrect-details.notAnOrganisation.p2") @messages("incorrect-details.notAnOrganisation.p2.link")
}


Copyright Bruce Wilcox<EMAIL_ADDRESS>www.brilligunderstanding.com
Revision 6/9/2018 cs8.3
’‘’There’s more than one way to skin a cat’’’. A problem often has more than one solution. This is certainly true with ChatScript. The purpose of the Practicum series is to show you how to think about features of ChatScript and what guidelines to follow in designing and coding your bot.
To glean is to extract information. If there is one thing that makes
a chatbot seem intelligent it is the ability to grab information from
what the user says and make use of it in subsequent volleys. The very
first chatbot, Eliza, fooled humans merely by grabbing critical keywords
from a user’s input and spitting back precanned questions. If a user
said “my wife is like my mother”, Eliza could focus on like
and respond “In what way?” Or it could focus on the word mother and say
“Tell me more about your mother”. It did not store information beyond
the use for generating the reply. But our use of gleaning is to detect
information and hold it around.
The process of coding gleaning takes the following steps. First, decide what you want to glean. Second, generate sample sentences containing data to be gleaned. Typically 4 or 5. Third, write script to perform the gleaning. Fourth, decide how to store the results. Fifth, find a way to make use of the gleaned data. Sixth, read logs, find new sentences you don’t handle and handle them.
What you glean is up to you. Name, hobby, illnesses, favorite fruit,
whatever. Let’s consider gleaning information about a pet. You might
want to glean kind of animal, name, breed, age, gender. Obviously first
in line is gleaning kind of animal. To simplify things, we will start by
only learning about pets of the speaker. If the user says “my friend has
a dog”, we won’t care (otherwise we have to master gleaning who owns the
dog other than I
).
We start with sample simple sentences. How might a user typically say they have a dog?
I own a dog.
I have a puppy.
My dog is hungry.
I own a grey cocker spaniel.
These would be common ways to express ownership of a dog. There are also obscure ways, and at some point we will have to throw in the towel and admit our program will not be perfect. Things like:
I possess a dog.
I bought a dog the other day.
I have raised this puppy from birth.
Taking our simple sentences, we then generate scripts to detect them.
We need to decide what we are gleaning. I’m gleaning the kind of animal,
in this case always a dog. puppy
is tied to age and
spaniel
is tied to breed. The 3 key components of the
pattern are detecting the animal and the evidence of ownership and
evidence of ‘I-ness’.
For now I will use rules that accept both statements and questions, because maybe the user will ask a question and reveal pet ownership like “What should I feed my dog?”
u: OWN('I own a dog) $pet = dog
This covers my first sample. But it’s very specific and won’t handle
I own a black dog
. So I generalize it by allowing a few
intervening words.
u: OWN('I own *~4 dog) $pet = dog
I don’t use the infinite wildcard *
because I expect the
word dog
to be close. Infinite wildcards risk false
detection.
Similarly I generalize
between 'I
and own
to catch
I already own a dog
.
u: OWN('I *~2 own *~4 dog) $pet = dog
To handle the next sample input, I need to detect puppy
and have
. I could write entirely new patterns, but that
would become unwieldy to maintain. And someday I’ll want to detect other
animals and breeds. So I create a concept to hold the dogs I want to
detect, and I use the preexisting ChatScript concept for ownership (or
else I could define a new one). While I show the concept next to the
u:
, in reality there would be some intervening topic
declaration.
concept: ~dogpet ( dog puppy)
u: OWN('I *~2 ~own *~4 ~dogpet) $pet = dog
The third sentence requires a new pattern construction that
simultaneously handles I
and ownership.
concept: ~dogpet ( dog puppy)
u: OWN('I *~2 ~own *~4 ~dogpet) $pet = dog
u: MY(my *~4 ~dogpet) $pet = dog
Again I allow some space between my
and
~dogpet
to support my brown mangy dog
. From
experience I know to allow for some intervening words all along.
Otherwise I’d write my pattern initially without and add generalization
later.
The fourth sentence requires detection of a dog breed. For that, we
just add the corresponding CS concept to our ~dogpet
. Or
invent a new one.
concept: ~dogpet ( dog puppy ~dog_breeds)
u: OWN('I *~2 ~own *~4 ~dogpet) $pet = dog
u: MY(my *~4 ~dogpet) $pet = dog
One flaw of all of the above rules is that they can change their mind
about what pet is given. Probably it’s better to insure it stops after
finding a pet. So I add !$pet
.
concept: ~dogpet ( dog puppy ~dog_breeds)
u: OWN(!$pet 'I *~2 ~own *~4 ~dogpet) $pet = dog
u: MY(!$pet my *~4 ~dogpet) $pet = dog
The above cannot handle the following volley input: “I own a pet. It is a dog.” To handle that would require code to manage pronoun resolution. Also doable, but not in this lesson. But this example is extremely unlikely to be seen, so too bad.
And so we have simple detection of owning a dog. And if we want to expand this to handle other animals? We have to do two things. First, expand (and rename) our pet concept. Second, save the right kind of pet animal. This will require memorizing the animal said, and sometimes decoding it into the appropriate animal type. I use ^refine for that to keep the code clear.
concept: ~petlist ( ~animals puppy ~dog_breeds ~cat_breeds)
u: OWN(!$pet 'I *~2 ~own *~4 ~petlist) ^refine()
a: ([_0==puppy _0?~dog_breeds _0==dog) $pet = dog
a: ([_0==kitten _0?~cat_breeds _0==cat) $pet = cat
a: () $pet = _0
u: MY(!$pet my *~4 ~dogpet) ^refine()
a: ([_0==puppy _0?~dog_breeds _0==dog) $pet = dog
a: ([_0==kitten _0?~cat_breeds _0==cat) $pet = cat
a: () $pet = _0
Something like above would do the job. But I repeated that ^refine
for the MY rule and created code that is harder to maintain. Rather than
repeat the code, I would use ^reuse
like this:
concept: ~petlist ( ~animals puppy ~dog_breeds ~cat_breeds)
u: OWN(!$pet 'I *~2 ~own *~4 ~petlist) ^refine()
a: ([_0==puppy _0?~dog_breeds _0==dog) $pet = dog
a: ([_0==kitten _0?~cat_breeds _0==cat) $pet = cat
a: () $pet = _0
u: MY(my *~4_ ~petlist) ^reuse(OWN)
But that won’t work if I have text to also send to the user as in below, because we get the dog message as well as the cat message.
u: OWN(!$pet 'I *~2 ~own *~4 _~petlist) ^refine() I love dogs.
a: ([_0==puppy _0?~dog_breeds _0==dog) $pet = dog
a: ([_0==kitten _0?~cat_breeds _0==cat) $pet = cat
a: () $pet = _0
u: MY(!$pet my *~4 _~petlist) ^reuse(OWN) I love cats.
To fix our problem, create a placeholder rule to ^reuse that says nothing and can’t be triggered accidently.
concept: ~petlist ( ~animals puppy ~dog_breeds ~cat_breeds)
u: OWN(!$pet 'I *~2 ~own *~4 _~petlist) ^reuse(SAVEPET) I love dogs.
u: MY(!$pet my *~4 _~petlist) ^reuse(SAVEPET) I love cats.
s: SAVEPET(?) ^refine()
a: ([_0==puppy _0?~dog_breeds _0==dog) $pet = dog
a: ([_0==kitten _0?~cat_breeds _0==cat) $pet = cat
a: () $pet = _0
The SAVEPET placeholder rule never triggers on its own, because it requires the input to be both a statement (s:) and a question (?). Won’t happen. And the SAVEPET rule is given in _0 the matched animal from either rule calling it.
OK. We have detected one animal type. Now, do we go on to more data about it or do we work on someone who owns multiple animals? I’d move on to more data because our chatbot can appear smart merely recognizing one. And writing patterns to detect multiple instances is more complex. And writing where to store the answer is more complex.
We start the same way, deciding sample sentences.
I have a female golden retriever.
My cow is hungry.
My cat is grey and he lives outdoors.
My cat is grey. He lives outdoors.
While I could stumble my way through a bunch of iterations, let me just jump to how I think the answer goes.
concept: ~femaleness (she her female cow)
concept: ~maleness (he him male bull)
...old code for detecting animal type ...
u: ($pet ~femaleness) $petgender = female
u: ($pet ~maleness) $petgender = male
The above gets us gender in most situations. We require that a pet has been detected already. While seeing a gender pronoun in a later sentence is common, one does not typically see one before the item referred to. You won’t likely see “she loves milk does my cat” but you could see “my cat she does love milk”
We don’t care if the gender marker has occured in the same sentence
or a later one. It’s a start. Then we have to think of inputs we can get
fooled by. We will be fooled by inputs that involve gender but not of
our pet, like
My dog was sick so my sister was sad and she said so.
For
now I don’t care. In advanced code we could handle this. Similarly it
will be a lot of work to correctly distinguish “Harold has a cat who
scratched him” and “Harold has a cat who scratched himself”. So we won’t
bother. We will tolerate errors to get it right most of the time.
Gleaning from specific words or phrases (concept sets) is easy. The hardest thing is to avoid false positives, where the keyword doesn’t mean what you think it does. There are two ways to handle this.
The first is to use ‘^refine’ and something like @_0+
to
exclude some matches.
u: (!$pet _~petanimals) ^refine() ^retry(RULE)
#! My teenager is feeling puppy love -- dont react
#! he still has puppy fat in his cheeks -- don't react
a: (@_0+ [love fat])
#! you'd have to be one sick puppy to want to go to the hospital -- dont react
a: (@_0- sick)
a: () $pet = _0
)
The above has the advantage of entirely local code- it’s clear and you know where to modify things. It keeps scanning the sentence until $pet has be set or matches run out. It is also faster and easier to read in traces, because if the main pattern doesnt match, you never have to try all the rejoinder rules.
The alternative is to hide ~petanimals from matching. This would be good if there are several rules depending upon it. You would do that like this:
#!  It is better to use ^unmark on the specific concept
rather than doing ^unmark(* _0)
because making the word
completely invisible can have unintended other consequences. But the
above is messier, slower, uses more code, and generates more trace than
this equivalent:
u: NOTPUPPY (_~petanimals) ^refine() ^retry(RULE)
#!
Some things you need to glean will not show up in a concept set, or may only partially. The classic example is gleaning a name. It can be any word or sequence of words and what you usually have to detect is the context bounding the name. You have to start making assumptions about what a reasonable name will consist of. So, as always, first write sample inputs, then make patterns for them.
His name is Roger.
we call him rabbit.
HE IS CALLED HAROLD THE MAGNIFICENT AND IS 12.
My cat Harold likes birds.
So we start with the first sentence.
u: (name is _~noun_proper_singular)
The above is simple, but will fail when the system doesnt know the name. Like for “His name is pansy.” So maybe we also need a context dependent rule.
u: NAMEIS(name _is) ^refine()
a: CONCEPTNAME(@_0+ _~noun_proper_singular) $petname = '_0
a: CONTEXTNAME(@_0+ _*~3 [> , ~conjunction]) $petname = '_0
Note here we don’t want the canonical of the name, we want the actual
name, so we use quoted _0. The CONTEXTNAME pattern assumes names are
usually 3 or fewer in length and are bounded by some typical delimiter
like end of sentence, comma or and
. It would fail for
Her name is Little Red Riding Hood
, unless the user is
using capital letters meaningfully and proper name merging is on. We
could increase the wildcard to *~4
. But the wider we make
that wildcard, the more room for mischief. “My name is something my
mother liked.”
And we can extend the rule to handle called
like
this:
u: NAMEIS(name _is) ^refine()
#! his name is Peter
a: CONCEPTNAME(@_0+ _~noun_proper_singular) $petname = '_0
#! his name is master of all.
a: CONTEXTNAME(@_0+ _*~3 [> , ~conjunction]) $petname = '_0
#! he is called Roger
u: CALLED( is _called) ^refine(NAMEIS)
#! we call it Roger
u: CALLED1( 'call _[him her it] ) ^reuse(NAMEIS)
And we can handle an appositive name like this:
#! my cat Harold the Great jumped from the roof
u: APPOSITIVE(~petanimals _*~3 ~verb)
Gleaning is typically done from a finite set of choices. And
sometimes you have to resolve issues around accepting or rejecting a
match. Consider the ~country
set provided by ChatScript. It
includes countries like Turkey
and Togo
.
‘Turkey’ is an issue because maybe the user is referring to the bird.  E.g.,
u: NOTTURKEY (_Turkey) ^refine() ^retry(RULE)
a: (@_0- *~4 [in from live reside of])
a: (<<Turkey [Istanbul Ankara Izmir Bursa Adana]>>)
a: () ^unmark(~country _0)
Above code tries to detect Turkey used as a country, and ignore all other uses. It won’t be perfect. It is probably harder to discard ones based on the bird, but here is an attempt:
u: NOTTURKEY (_Turkey) ^refine() ^retry(RULE)
a: (@_0- [~determiner ~possessive]) ^unmark(~country _0)
`Togo is a different problem. A perfectly unique word, but users can easily misspell `to go` by omitting the space. In the situation where this arose, we virtually never
expect the country to be referenced, so we just decided to ignore it as a country altogether. There are 3 ways to do this. First, remove it from the `~country` concept set.
Problem is, that ships with ChatScript, so tampering with that creates confusion when you upgrade to a new release. And there are other contexts where you might want to recognize it
as a country. Second, you could add a glean rule like this:
u: NOTTOGO (_Togo) ^unmark(~country _0) ^retry(RULE)
That kills all country uses of Togo. But it's inelegant to dedicate a rule to it.
The third trick is to define a customized concept set and use that in your code instead.
concept: ~ourcountries (!Togo ~country)
You can exclude specific items from a concept set that is inheriting items from other concept sets. You have to discard them one-by-one, meaning you cannot say
`(![choice1 choice2) ~inheritfrom)```.
Our last example is Georgia (the state) versus South Georgia (part of the Falkland Islands) versus Georgia (the country).
When someone says `South Georgia` clearly it will trigger `Georgia`. Or will it?
That depends on various things. One is the state of $cs_token having proper name merging on or not. As a single token `South_Georgia` you might not expect `Georgia` to be
matched. But CS has a default ability to peek into a proper name and match the last word of that name. So if you have not set `#NO_WITHIN`, then CS will still see Georgia.
Old CS was less powerful, so it needed to peek within. Nowadays I am not fond of peeking within, or even merging tokens together, since the system can easily discover
matches in phrases without having to merge the tokens. So except in rare bots, I turn off Proper name merging. You can force a single word token (regardless of the setting of proper name merging) via:
replace: “South Georgia” South_Georgia
but you also have to tell $cs_token to include #NO_WITHIN so it won't peek.
An alternative even with peek within is to let it match. Now that gets interesting. Because even though the input may (via revision) list South_Georgia as a single word, when you match
it like this: `(_~country)` you may still see `Georgia` as the value (since it is a country if peek within is on), even though that is not the tokenized value but merely a peek into the token.
To get past this, you need to actually look at the actual value as tokenized. So you can do this:
u: COUNTRY (_~country ) $_index = ^position(START _0) if (_0 == Georgia AND ^wordAtIndex(canonical $_index) == South_Georgia) { _0 = South_Georgia ^setposition(_0 $_index $_index) }
This code discovers that Georgia is being returned as the country in `_0`. It retrieves the start position in the sentence of the match.
It pulls that word from the sentence, and if it is actually `South Georgia`, it revises the value of _0 (causing the location of the match to be destroyed) and
then revises the match position of _0. It's obscure. But it fixes the problem.
So what should you do? Well, I advise against allowing peek within. Whether or not you want proper name merging is up to you. But if names are not being merged and you don't force
`replace` to make it a single token then you can easily block the Georgia part of the match with this:
u: NOTGEORGIA (_Georgia @_0- South) ^unmark(~country _0) ^retry(RULE)
I prefer that to this rule:
u: NOTGEORGIA (South _Georgia) ^unmark(~country _0) ^retry(RULE)
because the important word to match is Georgia. If that's not there, who cares about matching `South`? It's faster to test on what you require, rather than some preliminary junk.
But matching the words in order makes for a clearer pattern, and CS is fast enough you may prefer clarity. But when you have multiple conditions to test for, using a ^refine, then
you always match on the primary word and then refine on the secondary ones.
# Extending the concept of concept
Concepts are lists of words or phrases. But sometimes you wish you could use patterns. You can. You can create a pseudo-concept using rules.
u: (my *~2 (wife husband daughter son)
The above is a classic simple sequential pattern. We can convert this into a 'concept' as follows:
u: (_(my *~2 (wife husband daughter son)) ^mark(~myfamily _0)
The above rule creates a fake concept called `~myfamily` that takes up a contiguous sequence of words. Thereafter you can do things like:
u: ( ~myfamily enjoys)
The above will match "my only husband enjoys". ^mark can be applied to fake words as well, but it is usually more confusing to see visually, so it's better
to use it to create a fake concept.
You need to remember this is a multiword pattern, in this case containing the word 'my'. So a rule like this:
u: ( can [ I ~myfamily] love)
will fail on input like this `can my daughter love pizza`. Why? Because canonical `I` will match my, it therefore ignores ~myfamily because it has a match,
and then `love` is not the next word (`daughter`), so matching fails. And an internal retry will try to move the first match (`can`) which doesn't work.
Note: since these are dynamic markings, you cannot use these words inside of some other concept's list and expect it to be detected. converting a `[]` list
into a concept is the classic way to find the earliest match among all words, rather than walking `[]` in order, which finds only the first word in the list.
# Multi-sentence Gleaning
The above stuff works fine on single sentence inputs, but how do you manage to glean multi-sentence inputs? For that you have to modify the control
script itself. You need to leaf thru all sentences to glean, and then later decide how to react to those sentences. Here is what such a control script
might look like:
topic: ~main_control system repeat() … # OOB and other stuff
u: GLEAN() $_sentenceCount += 1 tmp=saveSentence(_sentenceCount) ^nofail(TOPIC ^respond(~glean_data)) if (%more) {^end(SENTENCE)}
u: OUTPUT() count = 0loop(_sentenceCount) { count + = 1restoreSentence(_count) ^respond(~realcontrol) } ``` The GLEAN rule counts how many sentences there are, saves them, and gleans them until there are no more sentences. The OUTPUT rule restores each sentence and passes it off to a more normal control topic to handle the user output determination. One assumes that the GLEAN topic will have set various facts and variables to remember what it found so the ~realcontrol topic can be guided in what it does.
Obviously we can devise sentences where all these things fail. Language is difficult.  Is it a cat? What is the name of the cat? Is it Harold or is it some Indian name like “Harold who likes birds”? What you need to do is make assumptions and then also write code where the user can correct you when you get it wrong. And generally you are aiming to match the probable. And accept the failures of the improbable.


Home
(current)
Products
Cold White
Cold Black
Thai Tea
Chocolate
Galeri
Order
Gallery Kafeins
Gallery
Gallery
Gallery
Gallery
Gallery
Gallery
Gallery
Gallery