Recently, about 2PM, I had this choice: I could continue watching the Yankee game -- it was about the 4th inning, the Yankees had scored a couple of runs, Cone was pitching well, but I wasn't paying that much attention -- or I could also see a movie.
I was thinking of seeing "Deep Impact", mainly to see the big tidal wave (I had noted the wave didn't seem to go much past, say, Fulton Street, so I thought the Upper West Side would remain dry, but, really, I had to confirm this), but with mixed reviews, I wasn't sure if I was up to seeing a couple hours of people being reconciled with their family members and working out various personal issues before the comet hits.
[I actually am not sure how the movie ends, if the big comet hits or not. I think it'd be funny if it didn't hit, but no one told the folks living in the big cave. The could emerge two years later to find a Walmart next to the entrance. Laughter would ensue.]
So, skipping over "Deep Impact", I sat down down and watched "Clockwatchers", one of those low-budget indies (it has to be since Parker Posey is in it; before I'd use Steve Buscemi as the litmus test appears, but now that he's appeared in the other big comet/meteor movie, "Armageddon", this assay method is now in doubt). This is a neat film, very fun, especially in the first hour or so. Basically, it's the story of four 20-something temps working in a depressing office.
The central character is Iris starts off the movie as a shy observer, watching her fellow temps go about trying to kill time, meet men, etc. In many cases, they're just going through life's motions: one of them is getting married to someone who apparently just gives her expensive gifts, a second claims to be an actress, though nothing apparently comes from her auditions, and the third is there trying to get a permanent job. This third one, played by Parker Posey, verbalizes the existential doubts they all seem to have: as a temp, they can vanish and no one would notice or care. Her quest for a permanent job, or at very least a recommendation, is her desire to leave a mark in the world.
Things take a darker turn when the job she'd been gunning for, executive assistant, is given to a mousy new hire. At the same time, someone starts stealing things from the office -- paperweights, books, the personal effects people have to decorate their cubicles, a very special ball of rubberbands -- and suspicion falls automatically on the temps. As pressure mounts on them, as they're put under more careful scrutiny, the work friendships they had formed shows cracks.
I don't find the film to be, say, a critique of the modern American workplace, though it shows a lot of the absurd little things that happen in offices. It's not Dilbert. Rather, the idea of people existing in a void, unconnected in any meaningful way and going through the motions of life, is its main theme, and the vagaries and darknesses of the modern American workplace is simply the most opportune setting for this existential limbo. The office is where people look for deep connections in this significant social space and fail to find it; for this film the particulars of unconnectedness are distilled into these temps.
Anyway, "Clockwatchers" is a good movie, very funny in parts. Currently, it's on one of the cable movie channels this month.
Later, I turned on CNN, and notice that the Yankees had won. I suppose it was a good game.
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


Moody News
Home
(current)
About Us
The Moody News
Search Topic:
Search
Clear Results
Aggregate For Sources
Highest Sentiscore Articles
SentiScore
News Source
Article Title
Publication Date
SentiScore
News Source
Article Title
Publication Date
SentiScore
News Source
Article Title
Publication Date
Lowest Sentiscore Articles
SentiScore
News Source
Article Title
Publication Date
SentiScore
News Source
Article Title
Publication Date
SentiScore
News Source
Article Title
Publication Date


Justin Albert is a mathematician turned web-developer. He completed his bachelors at Carthage College. After this, he went to graduate school at Marquette University. During his time there, he taught classes and researched for his dissertation with his advisor Francis Pastijn. In his dissertation he was able to find a large class of algebras that, although not necessarily initially having a lot of symmetry, could be embedded into algebras with symmetry. He describes how to do this algorithmically, which then allows for the using properties of nice algebras to find this in less nice algebras.
As Justin finished graduate school he began teaching mathematics at the college level. During this time, he taught a wide range of classes; however, his favorite were those that focused on logic and algorithms. His research further focused on algorithmically describing processes that allow starting with arbitrary algebras and end up in ones that had desired properties.
During his time teaching, he has come to realize that he wanted to work in an area with tangible results and provide products that were immediately useful to others. In order to satisfy this desire, he has completed coding courses through Northwestern. This experience has given him the technical skills he needs to create high quality and value websites.
Justin is excited by and committed to using his experiences and education to solve your technology problems.


My little brother introduced me to DXM a couple of years ago, I did not know that such a trip was even possible. This drug has advanced me spiritually and mentally beyond what I even imagined possible. The most recent trip that I have had was the most amazing yet. Throughout the years that I have tripped, each experience was like the most vivid near death experience possible, the sensation of being beyond life and back to the most familiar state that I can only compare to what might have been felt before I was born being very intense.
I took 480 MG of Triaminic Thinstrips, waiting nearly an hour or so before I felt anything out of the ordinary. A wave of nausea washed over me and I threw up several times before that familiar wave of comfort finally settled over me. When the drug was in full peak I was watching with my little brother several TV shows showing some of the more extreme police shows. The sense of familiarity and being in a dream was VERY strong, most of the experience being most like a trip back to that time that I can most compare to the time I can imagine before I was born. There is the most peculiar and strong feeling of deja vu and stong visual hallucinations of a place before memory. The experiences and memories that I have taken from each trip have made me more and more convinced of a previous life beyond just a past life, a super-conscious state where I feel like a bud or droplett from a larger place.
Everything feels like part of a dream and the natural result of every decision I have made in my life up to this point. If I am in a dark place I can close my eyes and hallucinate in pixels. I have seen past lives and from the TV shows that I have watched a greater sense of purpose or closeness to that beginning. This drug is nothing like I can compare to, it is the best comparison to a spiritual near death experience. I love it, it makes me feel like I am back to the source of life, like I am dead and alive at the same time. Coming down from the trip is a slow and spiritual release from a higher state, if I happen to share the experience with any friends I will hopefully be born as a soul brother/sister to that person.
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.


If the user tries to share when your app is not able to support share, you can provide a failure message that will be displayed in the share pane. This message should help the user understand why they cannot share and what they need to do to complete their task. You do not need to use this message if your app never supports share. Windows provides a default message for that case.
Choose the failure display text
To share, bring up the charms bar and select Share (or press Win+H).


The first study published in a paper with title C4PS - Helping Facebookers Manage their Privacy Settings, you can read it from here
In this study, they used a browser plugin named FPW:Facebook Privacy Watcher
You can visit this project on this link
The second study published in a paper with title The User Behavior in Facebook and its Development from 2009 until 2014, find it from here
In this study, they used a browser plugin named FPA:Facebook Privacy Analyzer
You can visit this project on this link


my contact details
my email<EMAIL_ADDRESS>my phone number : xxxxxxxxxxx
Name
enter your email
enter your queries


Plugin Information |
|---|
View GPRbuild on the plugin site for more information. |
Main features
- Manage multiple GNAT installations within Jenkins
- Build (Ada) projects using GNAT project files (*.gpr) with the help of GPRbuild - configurable as build step in your pipeline.
Configuring GPRbuild in your pipeline
Beside the GUI pipeline builder you can use the following in your Jenkinsfile:
gprbuild installationName: <name of GNAT installation as configured in Jenkins>, proj: <*.gpr file>, names: <Source files containing an entry point>, switches: <GPRbuild switches>
Only installationName is required. Refer to https://docs.adacore.com/gprbuild-docs/html/gprbuild_ug.html for documentation of GPRbuild.


| Figure 1 |
Recently emerged hatchling hawksbill turtle released from a ... |
| Figure 2 |
Locations of hawksbill nesting beaches, hatcheries, and in s ... |
| Figure 3 |
Estimated hawksbill hatchling sex ratios at Bahía de Jiquili ... |
| Figure 4 |
Sand temperature at two sand depths (30 and 60 cm) in hawksb ... |


Not Connected
WebControl v1.0
Joystick left
Joystick right
Buttons
CASE Association WebController by Stefan Larsson


Security Audit for
Encrypt.to
Use this tool to audit the deployed source code.
Test running
Github
equals?
Encrypt.to
Size
Audit code:
https://github.com/encrypt-to/encrypt-to.github.io


GFTW
Click the `simulate bookmarklet` to start paying then click `view Premium` to see monetized content. Scroll to post inorder to pay the owner, This website uses a 50/50 probabilist revenue to sometimes pay the platform owner or the creators. Each creator earns per user engagement.
State:
Mode: Not Monetized


Each week, we have someone on our squad assigned to be the green flag. This person is in charge of handling issues in our services while the rest of the squad is focused on working on our delivery for the sprint. The problem is our squad handles multiple services, and sometimes, it becomes challenging for the green flag to fix an issue on a service he or she hardly touches.
A suggestion from one of my squad-mates to help solve this was to start having an Alerts Playbook.
What is an Alerts Playbook?
This is a section on our wiki which contains information on the alerts that show up on our notification. It has a page for every alert that we have on our system. Each alert page has the following details:
-
Alert Message
This is typically the message that shows up on our alerts channel. Severity The classification of the alert. Is it a critical issue that has to be fixed ASAP or an error that can wait until we are back in the office?
-
Where is this triggered?
I would normally link the particular code that triggered the alert in this section. As a developer, I find it easier to understand the alert by looking at the particular code that triggered it.
-
Impact
A description of what the impact of the issue is to the users of our services.
-
How to investigate and fix?
This contains relevant information that will help the person reading the playbook to debug or fix the issue. I would put in details like where is the log located, or which server to check out.
The process is simple. If you are going to add an alert to the system, you will have to create this page, and put in the relevant details. Ideally, we would ask one of our squad-mates to read through the page we have just added to see whether it is understandable.
Some benefits I noticed by adding this
-
I only add necessary alerts. One of the things that had bogged our squad before was the number of alerts popping up on our notification. Putting too many alerts can result to alert fatigue. By filling in those details on the wiki, I become more critical of the alerts that I’m adding to our system. I ask myself whether it really is necessary to have that alert.
-
I get the confidence to know that I have a place to check out when something bad happens and I am the one who’s supposed to fix it.
-
Knowledge is shared. I am able to impart some of the things that only I used to know with the rest of the squad by documenting it here. And if I am not around, I know that my squad-mates will be able to solve the issues I used to solve by myself.
So there you have it. A simple tweak we added in our process to help boost the effectiveness of our squad. Hope this helps!


| Opcode/Instruction | Op/ En | 64/32 bit Mode Support | CPUID Feature Flag | Description |
|---|---|---|---|---|
| 66 0F 3A 20 /r ib PINSRB xmm1, r32/m8, imm8 | RMI | V/V | SSE4_1 | Insert a byte integer value from r32/m8 into xmm1 at the destination element in xmm1 specified by imm8. |
| 66 0F 3A 22 /r ib PINSRD xmm1, r/m32, imm8 | RMI | V/V | SSE4_1 | Insert a dword integer value from r/m32 into the xmm1 at the destination element specified by imm8. |
| 66 REX.W 0F 3A 22 /r ib PINSRQ xmm1, r/m64, imm8 | RMI | V/N. E. | SSE4_1 | Insert a qword integer value from r/m64 into the xmm1 at the destination element specified by imm8. |
| VEX.NDS.128.66.0F3A.W0 20 /r ib VPINSRB xmm1, xmm2, r32/m8, imm8 | RVMI | V1/V | AVX | Merge a byte integer value from r32/m8 and rest from xmm2 into xmm1 at the byte offset in imm8. |
| VEX.NDS.128.66.0F3A.W0 22 /r ib VPINSRD xmm1, xmm2, r/m32, imm8 | RVMI | V/V | AVX | Insert a dword integer value from r32/m32 and rest from xmm2 into xmm1 at the dword offset in imm8. |
| VEX.NDS.128.66.0F3A.W1 22 /r ib VPINSRQ xmm1, xmm2, r/m64, imm8 | RVMI | V/I | AVX | Insert a qword integer value from r64/m64 and rest from xmm2 into xmm1 at the qword offset in imm8. |
|
EVEX.NDS.128.66.0F3A.WIG 20 /r ib VPINSRB xmm1, xmm2, r32/m8, imm8 |
T1S-RVMI | V/V | AVX512BW | Merge a byte integer value from r32/m8 and rest from xmm2 into xmm1 at the byte offset in imm8. |
|
EVEX.NDS.128.66.0F3A.W0 22 /r ib VPINSRD xmm1, xmm2, r32/m32, imm8 |
T1S-RVMI | V/V | AVX512DQ | Insert a dword integer value from r32/m32 and rest from xmm2 into xmm1 at the dword offset in imm8. |
|
EVEX.NDS.128.66.0F3A.W1 22 /r ib VPINSRQ xmm1, xmm2, r64/m64, imm8 |
T1S-RVMI | V/N.E.1 | AVX512DQ | Insert a qword integer value from r64/m64 and rest from xmm2 into xmm1 at the qword offset in imm8. |
NOTES:
1. In 64-bit mode, VEX.W1 is ignored for VPINSRB (similar to legacy REX.W=1 prefix with PINSRB).
| Op/En | Operand 1 | Operand 2 | Operand 3 | Operand 4 |
| RMI | ModRM:reg (w) | ModRM:r/m (r) | imm8 | NA |
| RVMI | ModRM:reg (w) | VEX.vvvv (r) | ModRM:r/m (r) | imm8 |
| T1S-RVMI | ModRM:reg (w) | EVEX.vvvv (r) | ModRM:r/m (r) | Imm8 |
Copies a byte/dword/qword from the source operand (second operand) and inserts it in the destination operand (first operand) at the location specified with the count operand (third operand). (The other elements in the desti-nation register are left untouched.) The source operand can be a general-purpose register or a memory location. (When the source operand is a general-purpose register, PINSRB copies the low byte of the register.) The destina-tion operand is an XMM register. The count operand is an 8-bit immediate. When specifying a qword[dword, byte] location in an XMM register, the [2, 4] least-significant bit(s) of the count operand specify the location.
In 64-bit mode and not encoded with VEX/EVEX, using a REX prefix in the form of REX.R permits this instruction to access additional registers (XMM8-XMM15, R8-15). Use of REX.W permits the use of 64 bit general purpose regis-ters.
128-bit Legacy SSE version: Bits (VLMAX-1:128) of the corresponding YMM destination register remain unchanged.
VEX.128 encoded version: Bits (VLMAX-1:128) of the destination register are zeroed. VEX.L must be 0, otherwise the instruction will #UD. Attempt to execute VPINSRQ in non-64-bit mode will cause #UD.
EVEX.128 encoded version: Bits (VLMAX-1:128) of the destination register are zeroed. EVEX.L’L must be 0, other-wise the instruction will #UD.
CASE OF PINSRB: SEL (cid:197) COUNT[3:0]; MASK (cid:197) (0FFH << (SEL * 8)); TEMP (cid:197) (((SRC[7:0] << (SEL *8)) AND MASK); PINSRD: SEL (cid:197) COUNT[1:0]; MASK (cid:197) (0FFFFFFFFH << (SEL * 32)); TEMP (cid:197) (((SRC << (SEL *32)) AND MASK) ; PINSRQ: SEL (cid:197) COUNT[0] MASK (cid:197) (0FFFFFFFFFFFFFFFFH << (SEL * 64)); TEMP (cid:197) (((SRC << (SEL *32)) AND MASK) ; ESAC; DEST (cid:197) ((DEST AND NOT MASK) OR TEMP);
VPINSRB (VEX/EVEX encoded version)
SEL (cid:197) imm8[3:0] DEST[127:0] (cid:197) write_b_element(SEL, SRC2, SRC1) DEST[VLMAX-1:128] (cid:197) 0
VPINSRD (VEX/EVEX encoded version)
SEL (cid:197) imm8[1:0] DEST[127:0] (cid:197) write_d_element(SEL, SRC2, SRC1) DEST[VLMAX-1:128] (cid:197) 0
VPINSRQ (VEX/EVEX encoded version)
SEL (cid:197) imm8[0] DEST[127:0] (cid:197) write_q_element(SEL, SRC2, SRC1) DEST[VLMAX-1:128] (cid:197) 0
PINSRB:
__m128i _mm_insert_epi8 (__m128i s1, int s2, const int ndx);
PINSRD:
__m128i _mm_insert_epi32 (__m128i s2, int s, const int ndx);
PINSRQ:
__m128i _mm_insert_epi64(__m128i s2, __int64 s, const int ndx);
None.
None.
| EVEX-encoded instruction, see Exceptions Type 5; |
| EVEX-encoded instruction, see Exceptions Type E9NF. |
| If VEX.L = 1 or EVEX.L’L > 0. |
| If VPINSRQ in non-64-bit mode with VEX.W=1. |


Reset
GeekTrust Home
Select planets you want to search in:
Destination 1:
Destination 2:
Destination 3:
Destination 4:
Time taken: {{timeTaken}}
Find Falcone!
Congratulations on Finding Queen Al Falcone. King Shan is mighty pleased. Time taken: {{timeTaken}} Planet found: {{planetFound.planet_name}}
Try Again
Sorry Queen Al Falcone not found. Better luck next time!
Try Again


Jesus Gonzalez
Game developer. Game design and programming.
I have 14 years of professional experience as a programmer, the last 7 exclusively in the games industry.
Experienced in:
- Game framework architecture.
- Game engine architecture.
- General gameplay programming.
- Battle systems.
- Animation systems.
- VFX and animation tooling.
- UI implementation.
Tech I'm very familiar with:
- Rust
- C#
- Python
- Unity
- Game Maker


[gecode-users] branch function as static member?
Martin Mann
mmann at informatik.uni-freiburg.de
Thu Jun 8 16:08:32 CEST 2006
Hi,
currently the Gecode::branch() function is a global wrapper function for
the ViewValBranching class.
Therefor is my question if it wouldnt be better to place it into the
corresponding class description as a static member?
Doing it that way it would be clear which Branching subclass is used.
If you agree maybe its nice to introduce the static branch function
virtual in the base Branching class.
But it's just a suggestion...
;)
Cheers,
Martin
More information about the gecode-users
mailing list


Web development services imply designing, building, integrating, scaling and maintaining dynamic software solutions that work via intranet or internet.
Static website is the basic type of website that is easy to create. You don't need the knowledge of web programming and database design to create a static website. Its web pages are coded in HTML.
Dynamic website is a collection of dynamic web pages whose content changes dynamically. It uses the server side languages such as PHP,SERVLET, JSP, and ASP.NET etc. for developing a website.
E-Commerce, is simply the sale and purchase of services and goods over an electronic medium, like the Internet. it is online shopping as we commonly know it.
The different areas of web design include web graphic design; (UI design); authoring, including standardised code and proprietary software; (UX design); and search engine optimization.
Quickly Learner E-Learning Management System is a complete Web Application that is written in the PHP language. This Project will help Learners to practice their skill in real world environment.
Seeking a position to utilize my skills and abilities in the organization. I am a passionate web developer. My interest fields are full stack web development, data structure.
Download Resume


Our website address is: https://www.recruitmate.in.
Our website address is: https://www.recruitmate.in.
When visitors leave comments on the site we collect the data shown in the comments form, and also the visitor's IP address and browser user agent string to help spam detection.
An anonymized string created from your email address (also called a hash) may be provided to the Gravatar service to see if you are using it. The Gravatar service privacy policy is available here: https://automattic.com/privacy/. After approval of your comment, your profile picture is visible to the public in the context of your comment.
If you upload images to the website, you should avoid uploading images with embedded location data (EXIF GPS) included. Visitors to the website can download and extract any location data from images on the website.
If you leave a comment on our site you may opt-in to saving your name, email address and website in cookies. These are for your convenience so that you do not have to fill in your details again when you leave another comment. These cookies will last for one year.
If you visit our login page, we will set a temporary cookie to determine if your browser accepts cookies. This cookie contains no personal data and is discarded when you close your browser.
When you log in, we will also set up several cookies to save your login information and your screen display choices. Login cookies last for two days, and screen options cookies last for a year. If you select Remember Me, your login will persist for two weeks. If you log out of your account, the login cookies will be removed.
If you edit or publish an article, an additional cookie will be saved in your browser. This cookie includes no personal data and simply indicates the post ID of the article you just edited. It expires after 1 day.
Articles on this site may include embedded content (e.g. videos, images, articles, etc.). Embedded content from other websites behaves in the exact same way as if the visitor has visited the other website.
These websites may collect data about you, use cookies, embed additional third-party tracking, and monitor your interaction with that embedded content, including tracking your interaction with the embedded content if you have an account and are logged in to that website.
If you leave a comment, the comment and its metadata are retained indefinitely. This is so we can recognize and approve any follow-up comments automatically instead of holding them in a moderation queue.
For users that register on our website (if any), we also store the personal information they provide in their user profile. All users can see, edit, or delete their personal information at any time (except they cannot change their username). Website administrators can also see and edit that information.
We https://www.recruitmate.in does not share user's data to any third party.
If you have an account on this site, or have left comments, you can request to receive an exported file of the personal data we hold about you, including any data you have provided to us. You can also request that we erase any personal data we hold about you. This does not include any data we are obliged to keep for administrative, legal, or security purposes.
Visitor comments may be checked through an automated spam detection service.
User's all sensitive information like password, mobile no, email will kept private and stored in encrypted format.
Only email-id, mobile no, name will use for any internal reporting systems, contact mechanisms, or bug bounties.
We do not share any user data to any third party parties.


Frank "K" and Company varies in size from one to six musicians.
Fran, our drummer, is also an excellent vocalist who entertains as part of our Duo and Trio as well as all of the larger groups.
If you are looking for a big band sound, we can add brass and/or woodwinds along with our rhythm section.
We have a talented guitarist who sings and brings an added feature to the band.
Violins can be added for the cocktail and dinner hour.
Many events have smaller parties and the Duo or Trio can make your event something special to remember. Our musical talent, versatility and experience enable Frank "K" and Company to cater to your specific needs.
Needless to say, we can provide a variety of ensembles. We travel throughout Chicago, suburbs, and neighboring states. For additional information, please do not hesitate to contact Frank "K" via telephone<PHONE_NUMBER>), email (Frank's Email), or by clicking here.


Base interface that groups the common fields between the class Redditor and Me,
that has extra fields of the current logged in user.
(extensions in package com.kirkbushman.araw.utils)
(extensions in package com.kirkbushman.araw.utils)
This class can represent a comment on a Submission or a reply to another comment.
Base interface for the elements in the comments section of a submission.
Base interface for all the data submitted by a user.
e.g. Submission, Comment, Message
Base interface for keeping track of when a Thing was created.
Base interface for all items that can be distingushed
by moderators, admins or else.
Base interface to keep track of when a Thing was edited.
The base class for fetching pages of items
in a listing return.
Base interface for all the item that can be given Gildings
This class represents the amount of silver, gold and platinum that a contribution has,
given by users.
(extensions in package com.kirkbushman.araw.utils)
This class represent the current logged in user.
This class represents the message a user can send or receive.
Messages are grouped in the user inbox.
This class is used to load more comments in the tree,
when a comment or a group of comment is too deep.
This class represents a Redditor, that is not the current logged in one.
Base interface for all items that be replied to,
including Submission and Comment.
Base interface for all the items that can be saved,
Base interface to group all sorting options in the Reddit Api
This class represents a user post in a specific Subreddit,
this class can be replied to, in a form of a comment section.
Enum class that defines the kind of submissions.
There are additional properties inside of Submission,
to specify whether it's a video, an image, if it's hosted on reddit.com domain or not...
This class is used to represent a rule element in a Subreddit,
the rules are made by mods, and are expressing good/bad behaviour in the sub.
Base class for every class of the Reddit API,
This enum defines the time options for filtering, searching or ordering items in the Reddit Api:
This class represent a trophy given to a redditor.
Base interface for all the items that can be voted on,
likes = True -> Upvote, likes = False -> Downvote, likes = null
This enum defines the possible states of an item the logged in user has voted,
represented by the inteface Votable
An enveloped list of strings, that represents the wiki page titles.


--- layout: default title: Home ---
I've been online since 1994. I think I created my first webpage in the same year, on my university's server. This was before Wayback Machine, so there's no record of it, you'll just have to take my word for it. In the years that followed I've also made pages/sites for organisations and projects I was involved in, as well as for friends and family. Even though some of those early websites were cringeworthy by today's standards (original Geocities, anyone?), it would've be fun to revisit them for nostalgia's sake.
With the onset of "blogging" around the turn of the century as a way to frequently update a site with fresh content and news, plus the proliferation of social networks over the past decade, we're dumping more and more info and content onto the web. While not everything is worth salvaging, I'd still like to keep a record, a digital paper trail if you will. So that's my idea for this site, where you'll find a collection of links and lists, perhaps more for my own convenience/reference than anyone else's.
Maybe later on I'll add a blog or other functions to this website, but the cool thing is all the changes and incarnations will be preserved for posterity on GitHub! (as long as GitHub is around...)
If there's one certainty in this age of cloud computing and *aaS over the Internet, is that nothing is forever. Websites and services come and go. Case in point: while Instagram is still alive and well, one of their features, the Photo Map, was removed last year. They claimed that it was not widely used, but it happened to be my favourite feature. There's an alternative from The Data Pack, and although it's not as convenient as having the map in-app, at least I can embed it here!
And finally, to make it look like this page gets updated more than it actually does, here's a stream of my latest tweets via curator.io. Probably easier just to follow me on twitter/social network of your choice.


6 Profiling and benchmarking
6.1 Introduction
This chapter will introduce the the concepts of profiling and benchmarking. These concepts are universal withing programming . This chapter will focus on its practical implementation and usage in the R programming language.
The overall goal of these techniques is to measure the performance of the code you have written. Remember this is a measure of speed, not a measure of correctness.
6.2 Profiling
Profiling is the act of measuring the run-time of each line of code you have run. Knowing where the time is being spend in your code is beneficial as it is a good indication of where you should spend your time optimizing. In general you want to look for small areas that take up most of the time (also called a “bottleneck”) and focus on those before other parts. There is little reason to spend time optimizing a piece of code that only take up 0.1% of the time when you could work at a piece that takes up 70% of the time.
We will use the the profvis package to do profiling. It have a couple of different ways of interacting. In the first one you load the profvis package and then you wrap the code you want to profile in profvis({
and })
as shown below show below.
library(profvis)
profvis({
data <- runif(1e7)
# Three different ways of getting the square root
square_root <- sqrt(data)
square_root <- data ^ (1/2)
square_root <- exp(1) ^ (1/2 * log(data))
})
Another way if you are using the Rstudio IDE, comes from the navigation bar where you can access the profiling tool.
Clicking this tab reveals the following actions:
- “Profile selected line(s)”
- “Start profiling” & “Stop profiling”
Being able to profile selected lines of code is great if you have a short and compact piece of code that easily can be highlighted and tested.
On the other hand is the ability start and stop the profiling whenever you want a powerful tool. In addition to being able to profile code from different areas, you are also able to stop profiling before the code is done executing, which you aren’t able to in the previous 2 methods. This is useful if you want to profile a snapshot of a long-running simulation as it can have very consistent behavior since it is running the same thing millions of time.
No matter which of the three way you do your profile you will be presented with a page with a frame-graph
This interactive panel shows how much time and memory is being spend on each line of code. From here you should be able to identify Another useful view can be found by clicking on the “data” tab at the top. This shows how long time is being spend in each expression. We can see in this example that the power operator ^
is taking the majority of the time.
6.2.1 Troubleshooting
Sometimes when you are using profvis you will see the error
Error in parse_rprof(prof_output, expr_source) :
No parsing data available. Maybe your function was too fast?
This is because your code finished running before profvis was able to detect it. This might feel like good news, but it can make it difficult to profile very fast functions. To profile a fast function you simply let it run a lot of times. This can easily be done by putting it inside a for-loop. You change this
profvis({
data <- c(3, 7, 2)
super_fast_function(data)
})
to
profvis({
data <- c(3, 7, 2)
for (i in 1:1000) {
super_fast_function(data)
}
})
where you increase the number until it is run enough for the profiler to catch it.
6.3 Benchmarking
Measuring how long something takes is a simple skill that will become invaluable once you start to focus on making your code faster. Simply put, if you can’t measure how fast something is you don’t know if it is going any faster. This section will be broken into 2 sections
- benchmarking slow code and,
- benchmarking fast code.
In this content slow is something that takes seconds, minutes, hours or more. It is a situation where you could use a conventional stopwatch. Fast is anything faster, it is used in the context where you have two pieces of code you think does the same and you want to find out which one is faster.
6.3.1 Slow code
First we need to create a function to benchmark, here we will use this simple recursive formula for the fibonacci sequence. This function doesn’t scale well with n
so it will be perfect for these examples.
fibonacci <- function(n) {
if(n == 0) {
return(0)
}
if(n == 1) {
return(1)
}
fibonacci(n - 1) + fibonacci(n - 2)
}
Using system.time()
is classic way to measure how long something takes, simple wrap the code you want to time between system.time({
and })
.
system.time({
fibonacci(32)
})
## user system elapsed
## 2.740 0.000 2.744
The first two numbers are the are the total user and system CPU times of the current R process and any child processes on which it has waited, and the third entry is the ‘real’ elapsed time since the process was started. An alternative with the same functionality from the bench package is the function system_time()
.
library(bench)
system_time({
fibonacci(32)
})
## process real
## 2.67s 2.67s
where the two values are
- process - The process CPU usage of the expression evaluation.
- real - The wall clock time of the expression evaluation.
Another great tool is the tictoc package. Simply call tic()
when to start recording and toc()
to end recording.
library(tictoc)
tic()
x <- fibonacci(32)
toc()
## 2.808 sec elapsed
In addition does this package extend the timing functionality in such a way that we are able to measure times in nested context. In the following example we are generating some data and fitting a model. Calling tic()
another time before the toc()
allows us to measure subsections of the whole.
library(tictoc)
tic("Total")
tic("Data Generation")
X <- matrix(rnorm(5000 * 1000), 5000, 1000)
b <- sample(1:1000, 1000)
y <- runif(1) + X %*% b + rnorm(5000)
toc()
tic("Model Fitting")
model <- lm(y ~ X)
toc()
toc()
## Data Generation: 0.407 sec elapsed
## Model Fitting: 4.796 sec elapsed
## Total: 5.206 sec elapsed
This can be useful if you want to be able to time the overall script as well as parts of it. Notice how each timing is named.
6.3.2 Fast code - microbenchmarking
Here we will look at the what happens when we want to compare two expressions to see which one is faster. We will use the bench package again. Suppose we would like to determine the fastest way of calculating the variance of a selection of numbers. We use the mark()
function from the bench and insert 2 or more expressions we would like to test against each other. These expressions are then run a lot of times and the summary statistics of the times are given as a result.
library(bench)
x <- rnorm(1000)
bench::mark(
var(x),
cov(x, x)
)
## # A tibble: 2 x 10
## expression min mean median max `itr/sec` mem_alloc n_gc n_itr
## <chr> <bch:> <bch:> <bch:> <bch:t> <dbl> <bch:byt> <dbl> <int>
## 1 var(x) 9.5µs 11.9µs 10.7µs 103.2µs 83963. 13.7KB 1 9999
## 2 cov(x, x) 19.5µs 22.1µs 21.5µs 77.9µs 45231. 47.6KB 4 9996
## # … with 1 more variable: total_time <bch:tm>
mark()
also checks that all the expressions return the same output as a sanity check. Notice the units
- 1 ms, then one thousand calls takes a second.
- 1 µs, then one million calls takes a second.
- 1 ns, then one billion calls takes a second.
6.4 Additional resources
https://adv-r.hadley.nz/perf-measure.html
Chapter on “Measuring performance” from Advanced R by Hadley Wickham. Covers more or less the same topics as this chapter but with more examples and greater details, great next step for reading.


Post-parsing
cc_class.php
delete_contact.php
edit_contact.php
edit_contact_step1.php
footer.php
header.php
index.php
list_contacts.php
simple_form.php
add_contact.php
Warnings:
Warning on line 490 - File "C:\Apache2\htdocs\SampleForms\add_contact.php" has no page-level DocBlock, use @package in the first DocBlock to create one
cc_class.php
Warnings:
Warning on line 9 - no @package tag was used in a DocBlock for class CC_Utility
Warning on line 135 - no @package tag was used in a DocBlock for class CC_List
Warning on line 226 - no @package tag was used in a DocBlock for class CC_Contact
Warning on line 520 - no @package tag was used in a DocBlock for class CC_Campaign
Warning on line 1038 - File "C:\Apache2\htdocs\SampleForms\cc_class.php" has no page-level DocBlock, use @package in the first DocBlock to create one
delete_contact.php
Warnings:
Warning on line 18 - File "C:\Apache2\htdocs\SampleForms\delete_contact.php" has no page-level DocBlock, use @package in the first DocBlock to create one
edit_contact.php
Warnings:
Warning on line 0 - File "C:\Apache2\htdocs\SampleForms\edit_contact.php" has no page-level DocBlock, use @package in the first DocBlock to create one
edit_contact_step1.php
Warnings:
Warning on line 30 - File "C:\Apache2\htdocs\SampleForms\edit_contact_step1.php" has no page-level DocBlock, use @package in the first DocBlock to create one
footer.php
Warnings:
Warning on line 1 - File "C:\Apache2\htdocs\SampleForms\footer.php" has no page-level DocBlock, use @package in the first DocBlock to create one
header.php
Warnings:
Warning on line 21 - File "C:\Apache2\htdocs\SampleForms\header.php" has no page-level DocBlock, use @package in the first DocBlock to create one
index.php
Warnings:
Warning on line 2 - File "C:\Apache2\htdocs\SampleForms\index.php" has no page-level DocBlock, use @package in the first DocBlock to create one
list_contacts.php
Warnings:
Warning on line 88 - File "C:\Apache2\htdocs\SampleForms\list_contacts.php" has no page-level DocBlock, use @package in the first DocBlock to create one
simple_form.php
Warnings:
Warning on line 313 - File "C:\Apache2\htdocs\SampleForms\simple_form.php" has no page-level DocBlock, use @package in the first DocBlock to create one
Documentation generated on Mon, 14 Nov 2011 23:17:42 -0500 by phpDocumentor 1.4.1


Welcome to Pokemon Deck Utils created by Dillonzer! Currently there is only the Prize Tracker available, but looking to add more features as the days go on!
Welcome to Pokemon Deck Utils created by Dillonzer! Currently there is only the Prize Tracker available, but looking to add more features as the days go on!


Demo: Push Notification via GCM
Simulated Room Temperature Controller
Android Instruction:
- Install this apk on your Android device
- Once your device is registered to this demo, you will get your 8-digit unique ID
Desktop Instruction:
- Enter your 8-digit ID below
- Hover cursor over the temperature controller UI, and use mousewheel or trackpad to change the value
- When you set the room temperature above 80F, it sends you a push notification to your Android device


Welcome to
Thermostate!
London
New York
Paris
Tokyo
Current Temperature:
Hello! Do you want to change the temperature?
+
-
Power saving mode is
ON
Reset
PSM on
PSM off


Number Plate Detection
The NPR (Number Plate Recognition) system is based on image processing technology. The main objective here is to design an efficient automatic vehicle identification system by using vehicle number plate.
The system is implemented and simulated on MATLAB and performance is tested on real images. The system takes digital images of vehicles with their license plates visible and extracts license plate characters as a string of alphanumeric characters, and yields hypothetical user data from a related database corresponding to the extracted characters as output. The designed system is to work with reasonable accuracy if the digital image is of good resolution, and vehicle license plate has standard font in the region of interest.
The vehicle ought to stay stationary while taking the picture and the picture is caught from settled point parallel to the earth. We confronted some improper identification either because of the system, that was not able to extract the number plate from grayscale of the image taken improperly or because of luminance conditions and blurry background. Number plate extraction needs a great degree of high exactness when taking a shot at the images of busy streets or parking areas.


Exceptions used with SQLAlchemy.
The base exception class is SQLAlchemyError. Exceptions which are raised as a result of DBAPI exceptions are all subclasses of DBAPIError.
Bases: sqlalchemy.exc.ArgumentError
Raised when more than one foreign key matching can be located between two selectables during a join.
Bases: sqlalchemy.exc.SQLAlchemyError
Raised when an invalid or conflicting function argument is supplied.
This error generally corresponds to construction time state errors.
Bases: sqlalchemy.exc.SQLAlchemyError
Raised by topological sorts when a circular dependency is detected.
There are two scenarios where this error occurs:
Bases: sqlalchemy.exc.SQLAlchemyError
Raised when an error occurs during SQL compilation
Bases: sqlalchemy.exc.StatementError
Raised when the execution of a database operation fails.
Wraps exceptions raised by the DB-API underlying the database operation. Driver-specific implementations of the standard DB-API exception types are wrapped by matching sub-types of SQLAlchemy’s DBAPIError when possible. DB-API’s Error type maps to DBAPIError in SQLAlchemy, otherwise the names are identical. Note that there is no guarantee that different DB-API implementations will raise the same exception type for any given error condition.
DBAPIError features statement and params attributes which supply context regarding the specifics of the statement which had an issue, for the typical case when the error was raised within the context of emitting a SQL statement.
The wrapped exception object is available in the orig attribute. Its type and properties are DB-API implementation specific.
Bases: sqlalchemy.exc.DatabaseError
Wraps a DB-API DataError.
Bases: sqlalchemy.exc.DBAPIError
Wraps a DB-API DatabaseError.
Bases: sqlalchemy.exc.SQLAlchemyError
A disconnect is detected on a raw DB-API connection.
This error is raised and consumed internally by a connection pool. It can be raised by the PoolEvents.checkout() event so that the host pool forces a retry; the exception will be caught three times in a row before the pool gives up and raises InvalidRequestError regarding the connection attempt.
Bases: object
A mixin class which, when applied to a user-defined Exception class, will not be wrapped inside of StatementError if the error is emitted within the process of executing a statement.
E.g.:
from sqlalchemy.exc import DontWrapMixin
class MyCustomException(Exception, DontWrapMixin):
pass
class MySpecialType(TypeDecorator):
impl = String
def process_bind_param(self, value, dialect):
if value == 'invalid':
raise MyCustomException("invalid!")
Bases: sqlalchemy.exc.SQLAlchemyError
Raised when a schema name is beyond the max character limit
Bases: sqlalchemy.exc.DatabaseError
Wraps a DB-API IntegrityError.
Bases: sqlalchemy.exc.DBAPIError
Wraps a DB-API InterfaceError.
Bases: sqlalchemy.exc.DatabaseError
Wraps a DB-API InternalError.
Bases: sqlalchemy.exc.SQLAlchemyError
SQLAlchemy was asked to do something it can’t do.
This error generally corresponds to runtime state errors.
Bases: sqlalchemy.exc.ArgumentError
Raised when no foreign keys can be located between two selectables during a join.
Bases: sqlalchemy.exc.InvalidRequestError
A subject passed to sqlalchemy.inspection.inspect() produced no context for inspection.
Bases: sqlalchemy.exc.InvalidRequestError
Raised by ForeignKey to indicate a reference cannot be resolved.
Bases: sqlalchemy.exc.NoReferenceError
Raised by ForeignKey when the referred Column cannot be located.
Bases: sqlalchemy.exc.NoReferenceError
Raised by ForeignKey when the referred Table cannot be located.
Bases: exceptions.KeyError, sqlalchemy.exc.InvalidRequestError
A nonexistent column is requested from a RowProxy.
Bases: sqlalchemy.exc.InvalidRequestError
Table does not exist or is not visible to a connection.
Bases: sqlalchemy.exc.DatabaseError
Wraps a DB-API NotSupportedError.
Bases: sqlalchemy.exc.DatabaseError
Wraps a DB-API OperationalError.
Bases: sqlalchemy.exc.DatabaseError
Wraps a DB-API ProgrammingError.
Bases: sqlalchemy.exc.InvalidRequestError
An operation was requested from a connection, cursor, or other object that’s in a closed state.
Bases: exceptions.DeprecationWarning
Issued once per usage of a deprecated API.
Bases: exceptions.PendingDeprecationWarning
Issued once per usage of a deprecated API.
Bases: exceptions.RuntimeWarning
Issued at runtime.
Bases: exceptions.Exception
Generic error class.
Bases: sqlalchemy.exc.SQLAlchemyError
An error occurred during execution of a SQL statement.
StatementError wraps the exception raised during execution, and features statement and params attributes which supply context regarding the specifics of the statement which had an issue.
The wrapped exception object is available in the orig attribute.
The DBAPI exception object.
The parameter list being used when this exception occurred.
The string SQL statement being invoked when this exception occurred.
Bases: sqlalchemy.exc.SQLAlchemyError
Raised when a connection pool times out on getting a connection.
Bases: sqlalchemy.exc.InvalidRequestError
SQL was attempted without a database connection to execute it on.


I am a flutter and Web Developer. I'm currently pursuing my BTech. I ❤ ☕ and 🎵.
I started learning to code when I was 12 years old. Currently I'm learning more and more so that I could code cooler things and help the mankind.
I started learning piano when I was 10 years old and currently I'm trying to learn guitar by myself.


{% load i18n %}
{% trans "After creating a group, you can add members and share libraries into it."  %}


Cora this afternoon: first unattended climb up changing table, first escape from Pack n' Play, and first busted dish.
9/20/2009, 8:53:51 PM
Favs: 0
Retweets: 0
link--- layout: tweet ---
Cora this afternoon: first unattended climb up changing table, first escape from Pack n' Play, and first busted dish.
9/20/2009, 8:53:51 PM
Favs: 0
Retweets: 0
link


GOVERNMENT OF THE DISTRICT OF COLUMBIA Office of the Chief Technology Officer Open Government Report 2014 To institutionalize a culture of transparent and open government, accountability, and to expand opportunities for resident participation and collaboration, this Report describes how the Office of the Chief Technology Officer (OCTO) has and will continue to develop and enhance transparency, public participation, and collaboration. In accordance with Mayor’s Order 2014170, this report addresses the following topics: Transparency The Office of the Chief Technology Officer (OCTO) regularly shares press releases, announcements, public services, and other information via several agency-managed web sites including: ● OCTO Main web site octo.dc.gov ● DC-Net sub site dcnet.dc.gov ● Connect DC sub site connect.dc.gov ● DC Data Catalog data.dc.gov ● GIS updates via GovDelivery http://octo.dc.gov/service/dc-gis-services OCTO also manages several active and engaging Twitter accounts: ● Twitter @octodc ● Twitter @dcgovweb ● Twitter @connectdotdc ● Instagram @connectdotdc ● YouTube @connectdotdc ● Twitter @DCNetGov The agency also manages several online applications that provide valuable information to the public including the DC GIS Mapping Tool, DC Public Wi-Fi Hotspot Finder, among many others available here: http://octo.dc.gov/node/708212. These applications are regularly promoted both online and through community outreach activities. OCTO believes the vast amount of information available on data.dc.gov and octo.dc.gov web sites contributes to the small number of FOIA requests to the agency. Information on everything from purchase card transactions, current and needed contractor support, purchase orders, etc. is all readily available. 1 District’s Freedom of Information Act and Open Meetings Act The Office of the Chief Technology Officer (OCTO) annually receives a small number of FOIA requests for OCTO-specific information. For example, in FY 2013 the agency only received 14 requests with 4 of those were rerouted to other agencies with a 100 percent closure rate. The OCTO requests were closed within an average of 2.4 days. The preliminary FY 2014 numbers are following the same trend and will be fully reporting in early 2015. As owner of the City-wide Messaging System for partner agencies, OCTO receives a large number of requests for specific emails to and/or from certain individuals and/or containing certain names or words. Pursuant to Mayor's Order 2008-88, “Access to Email Traffic of District Government Employees”, OCTO is to provide the relevant emails back to partner agencies to review and provide to requestor. In FY 2014, OCTO fulfilled 528 requests for emails from partner agencies originating from FOIA requests or litigation. FOIAXpress Support The Office of the Chief Technology Officer (OCTO) served as the technical lead and project manager for the launch of Executive Office of Mayor’s (EOM) FOIAXpress system - a new online system for submitting and processing Freedom of Information Act (FOIA) requests to District government agencies. The new portal, powered by industry leader “FOIAXpress,” is the District’s first-ever citywide FOIA processing system. At its launch, more than 50 District agencies will be included. Additional agencies will be added to the system in the next fiscal year. The new DC Government Public FOIA Portal will allow requesters to submit public records requests for any of the participating agencies to a centralized website. The requests will be assigned a unique tracking number, and users will be able to track the status of the request. The system will also permit the District to generate reports to determine whether agencies are meeting their FOIA obligations in a timely manner. Further, it will allow agencies to publish documents to an online reading room for information that is required to be made public under FOIA and the Mayor’s Open Government and Transparency Directive, including frequently requested information under FOIA. Open Meetings Act 2 OCTO does not convene meeting subject to the Open Meetings Act. Increasing Public Access to Information The Office of the Chief Technology Officer (OCTO) works with District agencies to deliver transparency through our Citywide Data Warehouse and its Open Data Catalog. But this is not an agency, nor an administration, that rests on past achievements. OCTO and the City Administrator’s Office are investing heavily in a next generation Data Catalog to take the city even farther than we are today in terms of transparency. The DC Geographic Information Program (DC GIS), administered by the Office of the Chief Technology Officer (OCTO), will utilize open source technology to increase public access to the vast amount of information it creates and receives from our District agency partners. In doing so, we hope residents can make more informed decisions about their government and our community. The new site intends to make the District’s data more discoverable, explorable and transparent to foster greater participation and collaboration with all stakeholders. The new site is expected to launch in Fall 2014. Track.DC.Gov Originally launched in February 2010, Track.DC.Gov was lauded by open government advocates and city fiscal watchdogs. The Sunlight Foundation even said “both substance wise and technically, it out-athletes the White House's Open Government dashboard.” While it was an innovation at the time, the site had seen little change or improvements and had grown stale. The Office of the Chief Technology Officer (OCTO) has completely revamped the tool’s user interface and added new data sets and subsets to give a more transparent view of each agencies performance. Data includes: Data visualizations are now dynamic and allow more intuitive drill downs into individual data sets. The data behind each of the widgets can now be downloaded directly from the site. The tool’s accessibility has also been greatly improved with charts and graphics now also displayed in chart forms with clear text labels for those with disabilities. The tool is expected to go live in Fall 2014. Chief Data Officer 3 In response to an executive order, the Office of the Chief Technology Officer (OCTO) has designated an Interim Chief Data Officer (CDO) to assist in the deployment of the near term milestones outlined in the Transparency, Open Government and Open Data Directive and to help coordinate additional open data programming. In Fall 2014, the Chief Technology Officer will identify candidates and hire a permanent CDO to lead the Open Data Program. Open Government Advisory Group As outlined in Mayor’s Order 2014-170, “Transparency, Open Government and Open Data Directive,” the Office of the Chief Technology Officer (OCTO) and its Chief Data Officer will co-chair a new Open Government Advisory Group. The group will advise the District on improving transparency and helping establish strong policies for managing data in addition to setting short and long terms goals to make the District as open as possible. The group is also charged with monitoring and evaluating the District’s progress in meeting the requirements of Order 2014-170. The group will be announced in Fall 2014 and OCTO expects meetings to begin immediately. All meetings will be open to the public and meeting time and location, minutes, decisions, etc. will also be posted to DC.gov. Open Meeting Act The Office of the Chief Technology Officer (OCTO) is not overseen or advised by a board or commission that is subject to the Open Meetings Act. Public Access to Data The Office of the Chief Technology Officer (OCTO) is working closely with the Office of the City Administrator (OCA) to identify additional datasets that OCA and OCTO expect to publish online later this year. We currently have more than 570 data sets slated to be available online on the new Open Data site, we will continue to work with OCA to identify datasets appropriate to publish in 2015 and beyond. Public Engagement and Participation Online Access to Proposed Rules and Regulations The Office of the Chief Technology Officer (OCTO) is not a regulatory agency and does propose rules and regulations. 4 Information Sharing The Office of the Chief Technology Officer (OCTO) plays a unique role with District Government as we both provide the technology and support to our partner agencies to conduct outreach activities and implement our own outreach efforts. For example, OCTO oversees DC.Gov, the District’s web portal (see page 5 for details.) OCTO’s web team assists agencies in publishing information about District agency activity. Supporting Partner Agencies OCTO has done a massive amount of work over the past two years to get the city closer to completion of a major, multi-year project to upgrade the city’s web sites and platform to improve how the District communicates with the public. Our web team migrated some of the most complex and difficult sites during this period, they also worked with agency staff to update the content. The DC.Gov portal’s 100-plus agency and program sites generate annual traffic higher than many municipalities and counties with comparable populations (e.g. Boston and Montgomery County, Md.), with more than 14 million visitors making 29 million visits in 2013 (a 7 percent increase in visitors over 2012). DC.Gov website won first place for city portals in e.Republic’s Center for Digital Government’s 2014 Best of the Web and Digital Government Achievement Awards. DC.Gov was a Top 10 finalist in 2013, and previously won Best of the Web in 2005. Highlighted several recent upgrades to DC.gov: ● The introduction of the portal’s new responsive design, which automatically adjusts to fit the screens of any tablet or mobile device, positioning DC.Gov for the explosive growth and use of mobile devices. For example, only 1% of the visitors to DC.Gov used a mobile device in 2009, while almost 30% of visitors are expected to use a mobile device in 2014; ● Migration of almost all agency sites to the open-source Drupal platform; ● Significant improvement in resident- and business-centric navigation to make information and services easier to find; ● A clean, simple design to improve visitor experience; and ● New help pages for non-English-speaking residents. 5 The OCTO-run @dcgovweb has also been a major asset in distributing information and updates from all agencies to a wider audience. It also provides essential customer service to public by engaging residents with questions about the DC.gov portal or routing questions to other agency Twitter accounts or websites. The account quickly gained nearly 3,500 followers and is growing at a steady space. OCTO also lead the District’s first All-Hands Twitter Townhall - using #dcgovwebchat and moderated by @octodc and @dcgovweb - to highlight District government services and improvements. There were than 62 users, 235 tweets and over a million impressions on 140,000 timelines. A number of agencies participated including DPR, DCRA, DDOT, HSEMA and the Executive Office of the Mayor (EOM). Grade.dc.gov The Office of the Chief Technology Officer (OCTO) worked closely with the Mayor’s Office to design, develop and deploy grade.dc.gov in June 2012 to provide the public with an easy, accessible way to provide feedback on agency performance. Originally piloted with just 5 District agencies, grade.dc.gov now provides monthly grades on 15 agencies. In January 2014, OCTO made the site responsive, making access to the information, as well as the ability to provide input for grades much easier for residents and visitors. Our Communications Efforts OCTO’s Digital Inclusion Initiative (DII), branded as OCTO Connect.DC, functions as an effective outreach entity and sponsor of community events and partnerships with local partners, targeting specific neighborhoods to find ways to impact technology adoption and deliver computer training, broadband access, and technology outreach to underserved communities. Outreach activities include: ● Partner with local service entities like Byte Back and the Latino Economic Development Center (LEDC) to provide computer training to additional District residents, bringing OCTO’s grant to date total to about 8,000; ● Deployed more than 170 computers for public use in District-owned recreation centers, senior wellness centers, American Job Centers, and a returning citizen resource center; ● Held numerous Mobile Technology Lab events, including 10 Smart911 sign-up events in support of an effort by our friends at OUC; ● Went on the road with our technology lab in November 2013 with the DCHBX team to help them with health insurance enrollment; ● Hosted Community Broadband Summits to promote broadband adoption and engage community groups in our broadband outreach; and 6 ● Deployed a text messaging platform to improve and enhance our reach to specific groups of DC residents. While the grant funding is expired, we will continue to fund our digital divide outreach activities with OCTO’s local budget to ensure that these important efforts continue. DC GIS Steering Committee (GISSC) The GISSC fosters communication and cooperation amongst the DC GIS stakeholder community including District agencies, federal agencies, non-profit, and private sector GIS users in the District of Columbia. It serves as the primary decision-making body to establish and implement DC GIS policies and standards. The Committee takes into account needs and resources while seeking multilateral input, participation and support in defining and approving GIS projects, setting priorities and working through timelines. The GISSC meets quarterly and the meetings are open to the public, meeting agenda, minutes and presentations are posted online at: http://octo.dc.gov/node/702452 . Stakeholder Identification The Office of the Chief Technology Officer (OCTO) not only provides IT services to District and federal agencies and community organizations, we are also active members of the local, regional and national IT community. Our staff regularly attends and speaks at formal conferences, public meet-ups, summits, community meetings and other events. We want feedback on everything we do. We actively identify and engage key stakeholders who can help us discover best practices, provide feedback on services and products, etc. We believe that by being available, open and active stakeholders will also come to us - and they have. Improving Public Engagement and Participation In addition to the accomplishments and plans listed in other sections, OCTO is currently reviewing and revising its communications strategy for both internal and external stakeholders. OCTO is taking a data-driven approach to review web, social media and community relations to identify gaps in communications and identify any potential stakeholders or partners that can help us meet our objectives. Highlights include: 7 ● OCTO is currently researching and testing an online forum feature that would allow threaded, date-stamped conversations to be captured. This would allow for longer-term and more technical conversations to take place online. ● OCTO is also dedicating additional resources to: ● Improve social engagement online ● Increase direct-to-public “in real life” engagement for digital inclusion project ● Streamline web presence ● Engage developer community around new opendata.dc.gov site ● Launch @opendatadc Twitter account to handle customer service support for new opendata.dc.gov site Collaboration OCTO’s web team manages several cross agency websites that require collaboration among agencies in providing information and services to the public. For example, snow.dc.gov is a website that provides up-to-date information on snow events in the winter, including preparation for a snow event and monitoring of snowplow locations during an event. This information is provided by several agencies including DPW, DDOT and HSEMA. OCTO’s web team also creates temporary websites during emergency situations, such as Hurricane Sandy. These pages consolidate all information about District services and assistance from various agencies during these situations, enabling the public to come to a single website, rather than search for information on multiple websites. 8


Node, Express, Swig, and MongoDB - getting started with CRUD
Let’s create a basic CRUD app using Node, Express, Swig, and MongoDB.
This tutorial utilizes Node v0.12.5, Express v4.13.1, Swig and Mongoose v4.1.3.
Contents
- Getting started
- Sanity check
- Nodemon
- Routes
- Swig
- POST requests (part 1)
- Mongoose
- GET requests (all resources)
- POST requests (part 2)
- Sanity Check
- GET requests (single resource)
- PUT requests
- DELETE requests
- Conclusion
Getting started
Start by downloading the Express application generator (if you don’t already have it) to create a basic Express project:
$ npm install express-generator -g
The
-g
flag indicates that you want to install the package globally, on your entire system.
Navigate to a convenient directory, like your “Desktop” or “Documents”, then create the boilerplate:
$ express node-express-swig-mongo
$ cd node-express-swig-mongo
Check out the project structure:
├── app.js
├── bin
│ └── www
├── package.json
├── public
│ ├── images
│ ├── javascripts
│ └── stylesheets
│ └── style.css
├── routes
│ ├── index.js
│ └── users.js
└── views
├── error.jade
├── index.jade
└── layout.jade
Don’t worry about the files and folders for now. Just know that we have created a boilerplate that can be used for a number of Node/Express applications. This took care of the heavy lifting, adding common files, folders, and scripts generally associated with all apps.
Notice the package.json file. This stores your project’s dependencies, which we still need to install:
$ npm install
Now let’s install Mongoose and Swig:
$ npm install mongoose swig --save
The
--save
flag adds the dependencies and their versions to the package.json file. Take a look.
Sanity check
Let’s test our setup by running the app:
$ npm start
Navigate to http://localhost:3000/ in your browser and you should see the “Welcome to Express” text. Once done, kill the server by pressing CTRL-C.
Nodemon
Before moving on, let’s setup Nodemon so that you can run your app and watch for code changes without having to manually restart the server. Check out the link above to learn more.
$ npm install nodemon -g
Let’s test again:
$ nodemon
In your terminal you should see:
23 Aug 16:31:02 - [nodemon] v1.4.1
23 Aug 16:31:02 - [nodemon] to restart at any time, enter `rs`
23 Aug 16:31:02 - [nodemon] watching: *.*
23 Aug 16:31:02 - [nodemon] starting `node ./bin/www`
Essentially, Nodemon is watching for code changes, and if they do occur, then it will refresh the local server for you so you don’t have to constantly kill the server then start it back up. It saves a lot of time and keystrokes.
Awesome. With the setup done, let’s build something!
Routes
Grab your favorite text editor (such as Sublime or Atom), and then open the main file, app.js, which houses much of the business logic. Take a look at the routes:
app.use('/', routes);
app.use('/users', users);
Understanding how routes work as well as how to trace all the files associated with an individual route is an important skill to learn. You’ll be able to approach most applications and understand how they work just by starting with the routes.
Let’s look at this route:
app.use('/users', users)
Here, we know that this route is associated with the /users
endpoint. What’s an endpoint? Simply navigate to http://localhost:3000/users.
The end user navigates to that endpoint and expects something to happen. That could mean some HTML is rendered or perhaps JSON is returned. That’s not important at this point. For now, let’s look at how Node handles the logic for “handling routes”.
Also, within that route, you can see the variable users
. Where is in this file? It’s at the top, and it loads in another file within our app:
var users = require('./routes/users');
Open that file:
var express = require('express');
var router = express.Router();
/* GET users listing. */
router.get('/', function(req, res) {
res.send('respond with a resource');
});
module.exports = router;
What’s happening here? Essentially when that endpoint is hit, it responds by sending text in the form of a response to the end user - “respond with a resource”. Now, of course you don’t always have to send text. You could respond with a template or view like a Jade or Swig template file that gets rendered into HTML. We’ll look at how this works in just a minute when we add our own routes.
Make sure you understand everything in this section before moving on.
Add a new route
Let’s now add a new route that renders a HTML form to the end user.
Start by adding the route handler in the app.js file:
app.use('/api', api);
Remember this simply means
app.use('/ENDPOINT', VARIABLE_NAME);
,
Use the api
variable to require a JS file within our routes folder.
var api = require('./routes/api');
Take a look in the terminal. You should see an error, indicating Node can’t find the ./routes/api
module. We need to create it!
Create a new file called api.js in the “routes” directory. Add the following code:
var express = require('express');
var router = express.Router();
router.get('/superheros', function(req, res) {
res.send('Just a test');
});
module.exports = router;
Do you remember what this code
res.send('Just a test');
will do? If not, review the previous section.
Navigate to http://localhost:3000/api/superheros. You should see the text “Just a test” on the page.
Swig
Swig is a templating language, which compiles down to HTML, making it easy to separate logic from markup. For more on Swig, check out the Primer on Swig Templating.
Take a quick look at the layout.jade, index.jade, and error.jade files within the “views” folder. Right now these files are using Jade templating. Let’s update these files to remove Jade and add Swig. First, remove the .jade extension from each file and add a .html extension. Now we can update the actual syntax…
layout.html
<!DOCTYPE html>

<meta charset="utf-8">
<title>{{ title }}</title>
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css">
<link rel="stylesheet" href="/css/main.css">

{% block content %}
{% endblock %}

index.html
{% extends 'layout.html' %}
{% block title %}{% endblock %}
{% block content %}

{{ title }}

Welcome to {{ title }}

{% endblock %}
error.html
{% extends 'layout.html' %}
{% block title %}{% endblock %}
{% block content %}

{{ message }}

{{ error.status }}

{{ error.stack }}

{% endblock %}
Finally, update app.js by requiring the following dependency at the top of the file:
var swig = require('swig');
Then set Swig as the template engine by replacing app.set('view engine', 'jade');
with-
var swig = new swig.Swig();
app.engine('html', swig.renderFile);
app.set('view engine', 'html');
Jump back to the “views”, and take a look at layout.html and index.html. There’s a relationship between those two files. We define the base structure in the layout file, which contains common structure that can be reused in multiple places.
Do you see the block
keyword?
What really happens when the index file is rendered is that it first renders the base template because of the extends
keyword. So, the layout template then gets rendered, which eventually pulls in the child template, overwriting the block
keyword with:

{{ title }}

Welcome to {{ title }}

Hope that makes sense. If not, check out this resource for more info on template inheritance.
Setup api.html
Create a new file called api.html in the “views” directory, and then add the following code:
{% extends 'layout.html' %}
{% block title %}{% endblock %}
{% block content %}

{{ title }}

Welcome to {{ title }}

{% endblock %}
The same thing is happening here with inheritance. If you’re unfamiliar with Swig syntax, {{ title }}
is essentially a variable, which we can pass in from ./routes/api.js
.
Update ./routes/api.js
by changing-
res.send('Just a test');
-to-
res.render('api', { title: 'Superhero API' });
This just says, “When a user hits the /api/superheros
endpoint, render the api.html file and pass in Superhero API
as the title.”
Keep in mind that all Swig files are converted to HTML since browsers can’t read the Swig templating syntax.
Ready to test? Simple refresh http://localhost:3000/api/superheros.
Did it work? If yes, move on. If not, go back through this section and review.
Update api.html
So, let’s update the template to display a form:
{% extends 'layout.html' %}
{% block title %}{% endblock %}
{% block content %}

{{ title }}

<form method="post" action="/api/superheros" class="form-inline">

Superhero name
<input type="text" name="name" class="form-control" required>

<button type="submit" class="btn btn-default">Save</button>
</form>

{% endblock %}
Refresh your browser. Do you see the form? Try clicking save. What happens? Well, you just tried to send a POST request to the /api/superheros
endpoint, which does not exist - so you should see a 404 error. Let’s set up the route handler.
POST requests (part 1)
Open api.js to add the logic for this new route:
var express = require('express');
var router = express.Router();
router.get('/superheros', function(req, res) {
res.render('api', { title: 'Superhero API' });
});
router.post('/superheros', function(req, res) {
console.log(req.body.name);
res.redirect('/api/superheros');
});
module.exports = router;
Test this out again. Now, when you submit the form, we have the /api/superheros
endpoint setup, which then grabs the text from the input box via req.body.name
. Make sure the text is consoled in your terminal.
Okay. So, we are handling the routes and rendering the right template, but we still need to setup Mongoose to save the data from our form before we can finish with the POST request.
Mongoose
Mongoose is used for interacting with MongoDB. Start with defining the Schema, which then maps to a collection in Mongo.
Create a file called database.js in your app’s root directory, then add the following code:
var mongoose = require('mongoose');
var Schema = mongoose.Schema;
var Superhero = new Schema(
{name : String}
);
mongoose.model('superheros', Superhero);
mongoose.connect('mongodb://localhost/node-superhero');
Here, we required/included the Mongoose library along with a reference to the Schema()
method. As said, you always start with defining the schema, then we linked it to collection called “superheros”. Finally, we opened a connection to an instance of our local MongoDB.
If you don’t have the MongoDB server running. Do so now. Open a new terminal window, and run the command
sudo mongod
. If you need to set up MongoDB, follow the Installation steps here.
Next, open app.js and require the Mongoose config at the very top of the file:
// mongoose config
require('./database');
With Mongoose setup, we need to update api.js to create (via POST) and read (via GET) data from the Mongo collection.
GET requests (all resources)
Open api.js. Require Mongoose as well as the superheros
model, which we already created:
var mongoose = require('mongoose');
var Superhero = mongoose.model('superheros');
Now, update the function handling GET requests:
router.get('/superheros', function(req, res) {
Superhero.find(function(err, superheros){
console.log(superheros)
res.render(
'api',
{title : 'Superhero API', superheros : superheros}
);
});
});
Superhero.find()
grabs all superheros from the Mongo collection, which we assign to the variable superheros
. We can now use that variable in the Swig template.
Update api.html to display superheros
Let’s add a loop to iterate through the superheros and then display the name
key from the collection.
{% extends 'layout.html' %}
{% block title %}{% endblock %}
{% block content %}

{{ title }}

<form method="post" action="/api/superheros" class="form-inline">

Superhero name
<input type="text" name="name" class="form-control" required>

<button type="submit" class="btn btn-default">Save</button>
</form>

All Superheros

{% for superhero in superheros %}

{{superhero.name}}

{% endfor %}

{% endblock %}
Do you remember where we set the
name
key? Check out the database schema in database.js.
Before this will actually work - e.g., display superheros - we first need to add the logic to insert data into the Mongo collection.
POST requests (part 2)
Back in api.js, update the function for handling POST requests:
router.post('/superheros', function(req, res) {
new Superhero({name : req.body.name})
.save(function(err, superhero) {
console.log(superhero)
res.redirect('/api/superheros');
});
});
This simply saves a new superhero, which again is grabbed from the form via req.body.name
.
Sanity Check
Refresh you app. Add some superheros. If you’ve done everything correctly, the superheros should be displayed beneath the form.
What about updates? And deletions? First, let’s display a single superhero.
GET requests (single resource)
Update the list item in the HTML file like so to give each item a unique URL.

{{superhero.name}}

Now, let’s add a new route handler to api.js to display a single superhero:
router.get('/superhero/:id', function(req, res) {
var query = {"_id": req.params.id};
Superhero.findOne(query, function(err, superhero){
console.log(superhero)
res.render(
'superhero',
{title : 'Superhero API - ' + superhero.name, superhero : superhero}
);
});
});
What’s next? A new template. superhero.html:
{% extends 'layout.html' %}
{% block title %}{% endblock %}
{% block content %}

{{ title }}

<form method="post" action="/api/superhero/{{superhero.id}}?_method=PUT">

Superhero name
<input type="text" name="name" class="form-control" value="{{superhero.name}}" required>

<button type="submit" class="btn btn-default">Update</button>
</form>

<form method="post" action="/api/superhero/{{superhero.id}}?_method=DELETE" class="form-inline">
<button type="submit" class="btn btn-default">Delete</button>
</form>

{% endblock %}
Test this out.
PUT requests
Since most browsers do not handle PUT or DELETE requests, we need to use the method-override middleware to handle such requests.
Install via NPM:
$ npm install method-override --save
Add the requirement to app.js:
var methodOverride = require('method-override');
Then define the middleware just below the view engine setup in app.js:
app.use(methodOverride('_method'))
Finally, add the route handler to api.js:
router.put('/superhero/:id', function(req, res) {
var query = {"_id": req.params.id};
var update = {name : req.body.name};
var options = {new: true};
Superhero.findOneAndUpdate(query, update, options, function(err, superhero){
console.log(superhero)
res.render(
'superhero',
{title : 'Superhero API - ' + superhero.name, superhero : superhero}
);
});
});
Here, we are simply searching Mongo for the correct superhero via the Mongo ID and then updating the superhero name, which comes from the form, req.body.name
. By setting new
to true
, we’re able to grab the updated superhero information after the changes are made in Mongo. Try removing this option. What happens?
DELETE requests
With the button already set up in the template, we just need to add the route handler to api.js:
router.delete('/superhero/:id', function(req, res) {
var query = {"_id": req.params.id};
Superhero.findOneAndRemove(query, function(err, superhero){
console.log(superhero)
res.redirect('/api/superheros');
});
});
Again, we’re querying the database by the Mongo ID and then removing it. Simple, right?
Conclusion
That’s it. Post your questions below. Grab the code from the repository. Cheers!


READINGS EASTER
EASTER VIGIL
EASTER SUNDAY
EASTER WEEK
MO
TU
WE
TH
FR
SA
2ND
SU
3RD
4TH
5TH
6TH
7TH
ASCENSION
PENTECOST SUNDAY
Vigil Mass
Mass During the Day


--- layout: post permalink: airfare.html Tags: Array NameOfCoupon: Airfare Cash Back Summary: See our Airfare Coupon Code, Airfare Rebate, Airfare Promo Code, Airfare Discount, Airfare Coupon Cash Back Rebate here. MetaKeywords: Airfare Coupon Code, Airfare Rebate, Airfare Promo Code, Airfare Cash Back Rebate, Airfare Discount, Airfare Coupon Image: LinkURL: http://www.jdoqocy.com/click-4092138-10682712 affiliate_url_link: http://www.icouponblog.com/jane.php?id=4538 thesis_readmore: See the Airfare Coupon thesis_thumb: http://www.icouponblog.com/tn.php?merchantURL=airfare.com Title: Save $7.50 - Airfare Coupon Code for airfare.com. Airfare Rebate & Discount thesis_description: Our Airfare Discount Coupon Code for airfare.com. We have the best Airfare Rebate anywhere. thesis_keywords: Airfare, Airfare Coupon Code, Airfare Discount, Airfare Rebate product_name: Airfare hop_url: http://www.icouponblog.com/hop.php?id=4538 ---
Are you planning a honeymoon, reunion or just a relaxing vacation with your loved ones? Are you looking for something that suits your budget and is fun but affordable? Look no further than www.airfare.com. You will find cheap flights, cheap hotel reservations and a great vacation spot to relax, enjoy and have loads of fun! There are hundreds of national and international destinations to choose from. www.airfare.com will get you there at an amazing price. Our discount coupons will add to your savings.
You don’t need millions to have a million dollar vacation. Check out www.airfare.com and book your flight today….the beaches, the mountains, the resorts are all waiting for you. www.airfare.com will get you the lowest airfares to hundreds of destination. They buy tickets in bulk and get the volume discount which they are able to pass on to you. Do not pay an arm and a leg for air travel. Get the best rates when you visit online www.airfare.com. You can also book a hotel room at a great discounted price.
There are hundreds of places and activities to choose from. Take the fun vacation you have been trying to, at a great, affordable price. Book your seats today with www.airfare.com.Visit the beautiful beaches of Casablanca or the British Museum in London. You can go skiing in the Alps or go sand skiing and camel riding in the deserts of Dubai. You will love the prices of air tickets and hotel on www.airfare.com. Check it out today and pack your bags!


Defined in generated file: python/ops/gen_math_ops.py
Computes the product along segments of a tensor.
tf.compat.v1.math.unsorted_segment_prod
tf.compat.v1.unsorted_segment_prod
tf.compat.v2.math.unsorted_segment_prod
tf.math.unsorted_segment_prod( data, segment_ids, num_segments, name=None )
Read the section on segmentation for an explanation of segments.
This operator is similar to the unsorted segment sum operator found (here). Instead of computing the sum over segments, it computes the product of all entries belonging to a segment such that:
\(output_i = \prod_{j...} data[j...]\) where the product is over tuples
j...
such that segment_ids[j...] == i
.
c = tf.constant([[1,2,3,4], [5,6,7,8], [4,3,2,1]]) tf.unsorted_segment_prod(c, tf.constant([0, 1, 0]), num_segments=2) # ==> [[ 4, 6, 6, 4], # [5, 6, 7, 8]]
If there is no entry for a given segment ID i
, it outputs 1.
If the given segment ID i
is negative, then the corresponding value is
dropped, and will not be included in the result.
data
: A Tensor
. Must be one of the following types: float32
, float64
, int32
, uint8
, int16
, int8
, complex64
, int64
, qint8
, quint8
, qint32
, bfloat16
, uint16
, complex128
, half
, uint32
, uint64
.segment_ids
: A Tensor
. Must be one of the following types: int32
, int64
.
A tensor whose shape is a prefix of data.shape
.num_segments
: A Tensor
. Must be one of the following types: int32
, int64
.name
: A name for the operation (optional).A Tensor
. Has the same type as data
.


Help managers increase employee motivaton and team collaboration. Align sets the standard to help managers coach, communicate, and follow up with their team.


Example Project¶
Contents
A quick example test project using webdriver_test_tools
. Source code for the
example project can be found here.
Initialize the project¶
Create project files¶
First, create a directory for the test project:
mkdir example-project
cd example-project
Once in the project directory, run the following command to initialize the project:
wtt init
You will be prompted to enter a name for the test project python package. To be
a valid package name, it needs to only use alphanumeric characters and
underscores and it cannot start with a number. For this example, we’ll call it
example_package
:
Enter a name for the test package
(use only alphanumeric characters and underscores. Cannot start with a number)
> Package name: example_package
(Optional) Enter a human-readable name for the test project
(can use alphanumeric characters, spaces, hyphens, and underscores)
> Project title [example_package]: Example Test Project
Create .gitignore files for project root and log directory?
(Ignores python cache files, package install files, local driver logs, etc)
> Create .gitignore files (y/n) [y]:
Generate README file?
(README contains information on command line usage and directory structure)
> Create README file (y/n) [y]:
Creating test project...
Project initialized.
To get started, set the SITE_URL for the project in example_package/config/site.py
To create a new test, run:
python -m example_package new test <module_name> <TestCaseClass>
To create a new page object, run:
python -m example_package new page <module_name> <PageObjectClass>
For more information, visit <https://connordelacruz.com/webdriver-test-tools/>
Initializing the project should create the following files and directories:
example-project/
├── README.rst
├── example_package/
│ ├── __init__.py
│ ├── __main__.py
│ ├── config/
│ │ ├── __init__.py
│ │ ├── browser.py
│ │ ├── browserstack.py
│ │ ├── projectfiles.py
│ │ ├── site.py
│ │ ├── test.py
│ │ └── webdriver.py
│ ├── data.py
│ ├── log/
│ ├── pages/
│ │ └── __init__.py
│ ├── screenshot/
│ └── tests/
│ └── __init__.py
└── setup.py
(Optional) Setup virtualenv¶
If using virtualenv
, initialize the virtual environment before installing
the test package:
virtualenv venv
source ./venv/bin/activate
virtualenv
allows the test package to be installed in an isolated python
environment, ensuring any dependencies won’t overlap with other packages that
may require different versions. For more information, see virtualenv
documentation.
Install test package¶
After initializing the test project, run:
pip install -e .
Installing with the -e
flag will update the package automatically when
changes are made to the source code.
Note
If you don’t want to install test project packages, you can still run them
from the project root directory using python -m <test_package>
.
Configure site URLs¶
After initializing a project, the URL of the site to be tested will need to be
configured. In example_package/config/site.py
, set the SITE_URL
and
BASE_URL
of the SiteConfig
class.
For this example, we’ll use example.com.
from webdriver_test_tools.config import site
class SiteConfig(site.SiteConfig):
"""URL configurations for a site"""
# URL of the home page
SITE_URL = 'https://example.com'
# Base URL for site pages (followed by a '/')
BASE_URL = SITE_URL + '/'
# DECLARE ANY OTHER URL VARIABLES NEEDED FOR TESTING HERE
We’ll be testing that clicking a link takes us to an external page, so we’ll add
another variable INFO_URL
to SiteConfig
:
from webdriver_test_tools.config import site
class SiteConfig(site.SiteConfig):
"""URL configurations for a site"""
# URL of the home page
SITE_URL = 'https://example.com'
# Base URL for site pages (followed by a '/')
BASE_URL = SITE_URL + '/'
# DECLARE ANY OTHER URL VARIABLES NEEDED FOR TESTING HERE
# URL linked to by the 'More Information' link on example.com
INFO_URL = 'https://www.iana.org/domains/reserved'
Add a page object¶
Creating a new page object module¶
This test framework is best used with the Page Object Model. Interaction with the page should be handled by page objects to minimize the need to alter tests whenever the HTML is changed.
After configuring URLs, we’ll want to add a page object for the home page of example.com. Run the following command to create a new page object module:
example_package new page
You will be prompted to enter a name for the new module, a class name for the
new page object, and an optional description for the page object. We’ll call the
new page module home
and the new page object class HomePage
:
Enter a file name for the new page module
> Module file name: home
Enter a name for the initial page object class
> Page object class name: HomePage
(Optional) Enter description of the new page object class
> Description []:
(Optional) Select a page object prototype to subclass:
[1] form
[2] modal
[3] nav
[4] collapsible nav
[5] web page
> Page object prototype []:
This will create the file example_package/pages/home.py
.
Note
For more information on the new page
command, run:
example_package new page --help
Locating page elements¶
For any element we need to locate, we’ll want to keep track of how to target it
in the Locator
subclass. Selenium WebDriver locators are tuples in the
format (By.<selection type>, <selection string>)
, where <selection type>
is one of the constants declared in selenium.webdriver.common.by.By
and
<selection string>
is the string used to find the element.
Example.com is a pretty bare bones website, so these examples will be pretty contrived. We’ll add locators for the site heading and the ‘More information…’ link.
To locate the ‘More information…’ link, we’re going to select it by its link
text. Add HEADING
and INFO_LINK
variables to the Locator
subclass:
class HomePage(BasePage):
class Locator:
"""WebDriver locator tuples for any elements that will need to be accessed by
this page object.
"""
HEADING = (By.TAG_NAME, 'h1')
INFO_LINK = locate.by_element_text('More information', 'a')
Note
The utility function locate.by_element_text()
returns an XPATH locator
for elements with the specified text.
Interacting with page elements¶
For our example tests, we’ll want to look at the heading text and click on the
‘More information…’ link. Add the following functions to the HomePage
class:
class HomePage(BasePage):
class Locator:
"""WebDriver locator tuples for any elements that will need to be accessed by
this page object.
"""
HEADING = (By.TAG_NAME, 'h1')
INFO_LINK = locate.by_element_text('More information', 'a')
def get_heading_text(self):
heading_element = self.find_element(self.Locator.HEADING)
return heading_element.text
def click_more_information_link(self):
link_element = self.find_element(self.Locator.INFO_LINK)
link_element.click()
Note
The BasePage
method self.find_element(locator)
is shorthand for
self.driver.find_element(*locator)
.
Add a test¶
Creating a new test module¶
Now that we have a page object for interacting with example.com, we can write a test case. Run the following command to create a new test module:
example_package new test
You will be prompted to enter a name for the new module, a class name for the
test case, and an optional description for the test case class. We’ll call the
new test module home
and the new test case class HomePageTestCase
with
the description “Really contrived example test case”:
Enter a file name for the new test module
> Module file name: home
Enter a name for the initial test case class
> Test case class name: HomePageTestCase
(Optional) Enter description of the new test case class
> Description []: Really contrived example test case
This will create the file example_package/tests/home.py
.
Note
For more information on the new test
command, run:
example_package new test --help
Adding test functions¶
So far we have created a page object for the home page and an empty test case
for home page tests. Now we’re going to add some test functions to
HomePageTestCase
.
In tests/home.py
, import the HomePage
class we created:
from selenium import webdriver
import webdriver_test_tools
from webdriver_test_tools.testcase import *
from example_package import config
from example_package.pages.home import HomePage
class HomePageTestCase(WebDriverTestCase):
"""Really contrived example test case"""
We’re going to add 2 test functions:
Retrieve the heading text and assert that it says ‘Example Domain’
Click the ‘More information…’ link and assert that the URL matches
SiteConfig.INFO_URL
class HomePageTestCase(WebDriverTestCase):
"""Really contrived example test case"""
# URL to go to at the start of each test
SITE_URL = config.SiteConfig.SITE_URL
# Test Methods
def test_page_heading(self):
"""Ensure that the page heading text is correct"""
page_object = HomePage(self.driver)
heading_text = page_object.get_heading_text()
self.assertEqual('Example Domain', heading_text)
def test_more_information_link(self):
"""Test that the 'More information...' link goes to the correct URL"""
page_object = HomePage(self.driver)
expected_url = config.SiteConfig.INFO_URL
page_object.click_more_information_link()
self.assertUrlChange(expected_url)
Note
Test functions need to begin with the prefix test_
in order for
the python unittest
library to recognize them as tests.
The method WebDriverTestCase.assertUrlChange()
tests that the current URL
matches the URL given as a parameter, (waiting a few seconds for the page to
load before reporting a failure). The WebDriverTestCase
class includes a
number of additional assertion methods for WebDriver testing. For more
information, see the list of WebDriverTestCase assertion methods.
We should now have everything we need to run our test suite. To verify that the framework is able to detect the tests, run:
example_package list
This prints a list of test cases and their test methods in the package. The output should look like this:
home:
HomePageTestCase:
test_more_information_link
test_page_heading
You can also run example_package list --verbose
to view the docstring for
each class and method:
home:
└── HomePageTestCase:
Really contrived example test case
├── test_more_information_link
│ Test that the 'More information...' link goes to the correct URL
└── test_page_heading
Ensure that the page heading text is correct
Run the tests¶
Running the test suite¶
To run our test suite:
example_package
This will generate new test case classes for Chrome and Firefox based on the test case classes we wrote and run them. If all tests pass, the output should look like this:
(Firefox) Really contrived example test case
Test that the 'More information...' link goes to the correct URL ... ok
Ensure that the page heading text is correct ... ok
(Chrome) Really contrived example test case
Test that the 'More information...' link goes to the correct URL ... ok
Ensure that the page heading text is correct ... ok
----------------------------------------------------------------------
Ran 4 tests in 15.436s
OK
Optional command line arguments¶
Test packages can be run with various optional arguments to run a limited set of test cases instead of running the entire suite. To see a list of command line arguments, run:
example_package run --help
Running in a specific browser¶
If we just wanted to run the tests in a specific browser, we can use the
--browser
command line argument. For example, if we only wanted to run
Firefox test cases:
example_package --browser firefox
Running specific test modules¶
If we only want to run tests in one or more test modules, we can use the
--module
command line argument. For example, if we just wanted to run
tests/home.py
:
example_package --module home
Since we only have one test module in this example, this doesn’t do anything different than normal, but this can be useful in test projects with multiple test modules.
Skipping test modules¶
If we wanted to skip all tests in one or more test modules, we can use the
--skip-module
command line argument, which uses the same syntax as
--module
. For example, if we wanted to skip all tests in tests/home.py
:
example_package --skip-module home
Since we only have one test module in this example, this won’t run any tests, and so isn’t particularly helpful here, but this can be useful in test projects with multiple test modules.
Running specific test cases or functions¶
If we only want to run a specific test case or function within a test case, we
can use the --test
command line argument. For example, if we just wanted to
run HomePageTestCase:
example_package --test HomePageTestCase
Since we only have one test case class in this example, this doesn’t do anything different than normal, but this can be useful in test projects with multiple cases.
If we just wanted to run the test_more_information_link
function:
example_package --test HomePageTestCase.test_more_information_link
The --test
argument also supports wildcards in both the test case class and
method names. For example, if we wanted to run all test case classes beginning
with the word Home
:
example_package --test Home*
Or if we wanted to run all methods in HomePageTestCase
containing the word
page
:
example_package --test HomePageTestCase.*page*
Or if we wanted to run all test methods ending with the word link
:
example_package --test *.*_link
Obviously this isn’t particularly useful in our simple example, but can allow for a lot more control in larger test projects without needing to type out long lists of test cases and methods.
Skipping test cases or functions¶
If we wanted to skip a test case or function within a test case, we can use the
--skip
command line argument, which uses the same syntax as --test
. For
example, if we wanted to run all tests except for the
test_more_information_link
function:
example_package --skip HomePageTestCase.test_more_information_link
Like the --test
argument, --skip
also supports wildcards in class and
method names. E.g. if we wanted to skip all methods in all test cases that
contain the word page
:
example_package --skip *.*page*
Again, this isn’t particularly interesting since we only have 2 test functions, but can be useful in larger test projects.
Running tests in headless browsers¶
Some browsers support headless execution. This allows tests to be run without the browser GUI, which improves performance. To run the example test suite in headless browsers:
example_package --headless
For more information and a list of compatible browsers, see headless browsers documentation.
Running tests silently¶
By default, detailed output is displayed when running tests. If we wanted to reduce the output to just a progress bar and the final results while running tests:
example_package --verbosity 1
To suppress output entirely and just get the final results:
example_package --verbosity 0