I'm really want to order and start building my openenergy system, monitoring my house, heatpump and solarpanels.
I have tried reading up on what parts I would need but as I'm wiser in computers than electricity I need to ask you all for help. I'm from Sweden and we have 3 phase mostly everywhere...I understand most of the basics but need you explain how many CT's I need, how many AC-AC plug in power adapters and positioning of it all.
Want to:
- Monitor production of my Solar PV (29 panels, 255 watt each, 7.3 kWp, SMA 6000 inverter)
- Monitor instant production (power) of my solarpanels
- Monitor household energy and instant powerusage
- Monitor heatpump energy and instant powerusage
- Split up and see actual import or export of eletricity
As you can see in my attached drawing my units are a bit spread out in my house and garage, I have tried to explain as good as I can but please ask me for more info.
Re: Help me choose and build my system
In the UK, we only have 3-phase supplies in large commercial buildings, therefore all of OEM is designed around a single phase supply. However, it is possible to have a compromise in which you measure the line-neutral voltage of one phase and assume the other 2 phases have the same amplitude. Many people have found this to be acceptable, but it is for you to judge.
If you think this will not give you sufficient accuracy, then I believe Robin Emley has a design and might be able to supply a true 3-phase unit. This was designed as an energy diverter, but you do not need to construct the power diverter section and you can use it purely as a monitor. That will monitor 3 voltages and 3 currents.
Whether you use Robin's unit or an emonTx, you will need one unit at each place where you need to measure power, so I count:
Unit 1: Grid connection
Unit 2: Inverter connection
Unit 3: Heat Pump connection
If you are content that you can calculate the house consumption by House = Grid + Inverter - Heat Pump, then you should not need a 4th unit to monitor house usage.
You might be able to assume that the heat pump is a properly balanced 3-phase load (meaning that the load on each phase is identical - check the handbook or ask the installer or manufacturer) and in that case you do not need Unit 3, and you can use the 4th CT input on the inverter connection to monitor the heat pump.
If you use the emonTx, you will need for each one:
1 - AC adapter
3 (or 4, see above) - CT
If you like the idea of Robin's unit, you will need to email him at his website for details of what you need.
To collect the information, you need <edit>
an emonPian emonBase - a Raspberry Pi with the RFM69Pi radio module and appropriate firmware</edit>, and that will need a 5 V USB adapter and cable, and a Wi-Fi dongle or Ethernet connection to your router.I think that is all you need.
Although I do not need to know at this stage, is your supply a 4-wire system (has a neutral connection, 230 V line-neutral and 398 V line-line) or a 3-wire system (i.e. has no neutral connection, 230 V line-line and 132 V line-earth)?
[Note: we do not count the protective earth connection when counting the number of supply wires, only the brown, black and grey line and the blue neutral.]
Re: Help me choose and build my system
As of now, I have limited time and limited knowledge to take in the Robin method.
I have tried reading this https://sv.wikipedia.org/wiki/Trefassystem it is in Swedish but it tells me that you can measure 400v between the live wires and 230v between a live wire and neutral. Probably we have 4 cables, 3 live wires and 1 neutral.
So if I understand you right, I will need 3 emonTX with attached 3 (or 4) CT clips on each and 3 AC-AC adapters ? -> all three emonTX connected to one emonPI ?
Re: Help me choose and build my system
OK, so it seems that you have the same 3-phase system that we have. That makes it a little easier for me, because that is the most familiar.
You might not need 3 × emonTx. Your first step will be to ask the manufacturer/installer if your heat pump is a balanced 3-phase load. If they say yes, then you only need 2 × emonTx, but one of those will have 4 CTs attached, the other will have three. If they say no, then you will need 3 × emonTx, and each will have 3 CTs attached. Each emonTx will need an ac adapter.
Note that you do not need an emonPi because you will not use the voltage and current inputs on it, so I have changed that in my post above to an emonBase.
Re: Help me choose and build my system
Thankyou very much for your time and excellent replies!
So in the worst case scenario I would need:
Based on your reply (I have asked my manufacturer of heat pump but no reply yet) and what I can understand that the emonTx is shipped with 1 CT per unit ? Or maybe I'm wrong ?
And the hardware would be placed like this:
Additional questions:
1. How close Do I need to place the AC to AC adaptors ?
2. Is there no solution or plan to transmit via wire between the emonTx and emonBase (i'm a bit allergic to wireless).
3. How many emonTx can transmit to one emonBase ?
4. Do you have any suggestions about display, should I go for the emonGLCD or try to make it all display on a tablet or so... ?
5. Will I with this setup be able to see in realtime, house consumption and production of my solar PV and if I'am importing or exporting energy?
Re: Help me choose and build my system
"the emonTx is shipped with 1 CT per unit ? Or maybe I'm wrong ?"
I'm afraid you are wrong. The basic price is without, you can order one with the emonTx and the rest as a separate line on the order. It doesn't affect the price.
"1. How close Do I need to place the AC to AC adaptors ?"
Ideally within about 1.8 m, because that's the length of the attached cable. But it can be extended without any real problem.
"2. Is there no solution or plan to transmit via wire between the emonTx and emonBase (i'm a bit allergic to wireless)."
Yes, you can use a serial connection (that's what happens inside the emonPi), but I've no idea of the maximum distance that will work over.
"3. How many emonTx can transmit to one emonBase ?"
There's no strict number, the problem is collisions in the radio band. You should be OK with 3, though the occasional missing reading because of a collision is possible.
"4. Do you have any suggestions about display, should I go for the emonGLCD or try to make it all display on a tablet or so... ?"
I thought the GLCD was discontinued, but it has re-appeared. I've no experience with tablets or smartphones. The GLCD is probably more limited than those in its capabilities, but it's more immediate. (By default, the GLCD sketch receives the power data direct from the emonTx's.)
"5. Will I with this setup be able to see in realtime, house consumption and production of my solar PV and if I'am importing or exporting energy?"
Yes, it's pretty much instantaneous (provided you refresh the display if it's via a web interface).
Re: Help me choose and build my system
Yes, it's pretty much instantaneous (provided you refresh the display if it's via a web interface).
Or you can use the realtime graph that updates without the need to refresh the screen.
Click the 24h button to to get the best view of energy import/export.
Re: Help me choose and build my system
Thankyou for your reply.
"Ideally within about 1.8 m, because that's the length of the attached cable. But it can be extended without any real problem."
Help me understand - this AC to AC adapter, for example, the emonPi I plan to have monitoring my PV inverter - do I have to connect the AC to AC adapter on a wall outlet mounted on the same cable that transports the energy from the inverter to my central in the garage ?
"I thought the GLCD was discontinued, but it has re-appeared. I've no experience with tablets or smartphones. The GLCD is probably more limited than those in its capabilities, but it's more immediate. (By default, the GLCD sketch receives the power data direct from the emonTx's.)"
In my case I guess it wont work with "recieve the power data direct from the emonTx" because of calculations that needs to be done ?
"Yes, it's pretty much instantaneous (provided you refresh the display if it's via a web interface)."
Do I understand this correctly that the CT's and emonTx is able to detect and monitor the direction of energy flow with this setup, thus being able to give me "exporting" or "importing" on the grid using only 1 emonTx and three CT's on the incoming grid cables ?
Be patient with all my questions as I have some trouble understanding this setup and the calculations needed to be done to show me House consumtion, PV generation and importing or exporting.
Re: Help me choose and build my system
"do I have to connect the AC to AC adapter..."
Not necessarily, as long as the voltage it measures is representative of the system voltage. What you must not do is put it at the end of a long cable that supplies a heavy load, where the voltage would be significantly lower when the load is on. (The same applies to generation too - except that the voltage will be higher.)
"I guess [the GLCD] wont work.."
Then you repeat the same calculations in the GLCD! (That's normally the case anyway.) I'm not sure of the data path, or even if it exists, to take processed calculations out of emoncms back through emonHub to transmit to the GLCD. The emonPi time data to the GLCD takes the second part of that path, but I think Paul (pb66) or Chaveiro need to help here.
"emonTx is able to detect and monitor the direction of energy flow"
Given a voltage input, that is indeed true. Tha emonTx on the grid connection will give you the nett power transfer - our convention is positive for import, negative for export. So house consumption = Grid + PV - heat pump [maybe].
Re: Help me choose and build my system
So I got a reply from Nibe (my heatpump-manufacturer). They tell me that "perfect" balanced is relative...but the compressor has three identical windings (coils?). Moreover the controlsystem and circulation-pumps is all on one phase they say.
Does this give you some hint if I might use only one CT for my heatpump or do I need to go with three CT's ?
Re: Help me choose and build my system
I rather suspected that the answer would be like that. What it means is, if you're content to accept the small inaccuracy caused by ignoring the extra (or missing - depending on what you monitor) power that's down to the controls and the pump, then you can save the extra emonTx and the CTs. In the overall scheme of things, that inaccuracy will probably be small.
Re: Help me choose and build my system
So for me to understand. This 1cm thick black wire going in to my heatpump needs to be opened and the CT's put over each and every one of the three live wires to monitor all energy used ? Doing it the cheap way is to open the cable and hook up only one of the live wires and get what...?
Or Do you mean that I can connect 1 CT over the whole cable without splitting it up ? Then I can't understand, wouldn't that give me all energy used by heatpump including pumps and control ? (which is exactly what I want to do).
Re: Help me choose and build my system
To understand fully, you need to understand a little about 3-phase systems. You can read more in Building Blocks | 3-Phase Power, but in brief, in a balanced system, the current flowing into the heat pump in one wire (say the brown) flows out in the other two (black & grey) and even if there is a blue neutral wire, no current flows in. This situation changes continuously as the mains cycle progresses, repeating itself at 50 Hz. In your heat pump, Nibe have told you that most of the current does that, but a little extra flows in one phase and returns in the neutral conductor.
So the cheap way is to put a CT on one phase conductor and multiply the power by 3 inside the emonTx (or in both emoncms and in your GLCD).
I would certainly not cut into the cable. It will be much better to open up your heat pump or switchboard and put the CT on a single phase conductor in there.
If you put the whole 3-core or 4-core cable through the CT, it will read absolutely nothing - because all the current flowing through the CT in one direction is also flowing back in the opposite direction, but in a different wire inside the cable.
Re: Help me choose and build my system
I've been searching for an answer to if it might be possible to connect these three emonTx via wire to my RPi at a distance of max 10 meters. I haven't found the answer yet. I'm guessing no but it would be very nice. Or maybe you can talk me out of my bad experiences with wireless ? :)
I'm using a Dallas 1-wire system in my house for a lot of things already, temp, hum, lux and so on.


404
Something went wrong
Either you made a mistake or we did. How about we act like this didn't happen.
Go back home


| PREV CLASS NEXT CLASS | FRAMES NO FRAMES |
| SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |
ExceptionReason - this enum defines the different reasons for the exception type.
| Enum Constant Summary | |
|---|---|
GENERIC
This is a generic reason. |
|
NO_CREATE
This error is due to the user not having the create permission on the specific object/field/record. |
|
NO_DELETE
This error is due to the user not having the delete permission on the specific object/field/record. |
|
NO_READ
This error is due to the user not having the read permission on the specific object/field/record. |
|
NO_UPDATE
This error is due to the user not having the update permission on the specific object/field/record. |
| Enum Constant Detail |
|---|
public static final SFDCAccessControlException.ExceptionReason GENERIC
public static final SFDCAccessControlException.ExceptionReason NO_CREATE
public static final SFDCAccessControlException.ExceptionReason NO_READ
public static final SFDCAccessControlException.ExceptionReason NO_UPDATE
public static final SFDCAccessControlException.ExceptionReason NO_DELETE
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES |
| SUMMARY: NESTED | ENUM CONSTANTS | FIELD | METHOD | DETAIL: ENUM CONSTANTS | FIELD | METHOD |


| Home | Trees | Indices | Help |
|---|
|
|
CosmoloPy is a package of cosmology routines built on NumPy/SciPy.
Functions take cosmological parameters (which can be numpy arrays) as keywords, and ignore any extra keywords. This means you can make a dictionary of all of your cosmological parameters and pass it to any function.
The parameters module supplies some convenient pre-defined parameter sets.
The easiest way to use CosmoloPy is to create a dictionary of the cosmology parameters and pass it to each function using the ** syntax.
>>> import cosmolopy.distance as cd >>> cosmo = {'omega_M_0':0.3, 'omega_lambda_0':0.7, 'omega_k_0':0.0, 'h':0.72} >>> d_co = cd.comoving_distance(6., **cosmo) >>> print "Comoving distance to z=6 is %.1f Mpc" % (d_co) Comoving distance to z=6 is 8017.8 Mpc
The cosmolopy package also defines some convenient shortcuts, including a fiducial cosmology (currently the WMAP7+BAO+H0 mean), so you can just do this:
>>> from cosmolopy import * >>> d_a = cd.angular_diameter_distance(6, **fidcosmo) >>> print "Angluar-diameter distance to z=6 is %.1f Mpc" % (d_a) Angluar-diameter distance to z=6 is 1209.9 Mpc >>> d_light = cd.light_travel_distance(6, **fidcosmo) >>> print "Light-travel distance to z=6 is %.1f Mpc" % (d_light) Light-travel distance to z=6 is 3922.9 Mpc
Calculate the mass of a halo with Virial temperature of 10^4 kelvin, then verify the Virial temperature for a halo of that mass:
>>> import cosmolopy.perturbation as cp >>> cosmo = {'omega_M_0' : 0.27, ... 'omega_lambda_0' : 1-0.27, ... 'omega_b_0' : 0.045, ... 'omega_n_0' : 0.0, ... 'N_nu' : 0, ... 'h' : 0.72, ... 'n' : 1.0, ... 'sigma_8' : 0.9 ... } >>> mass = cp.virial_mass(1e4, 6.0, **cosmo) >>> temp = cp.virial_temp(mass, 6.0, **cosmo) >>> print "Mass = %.3g M_sun" % mass Mass = 1.68e+08 M_sun >>> print round(temp, 4) 10000.0
Calculate the critical and matter densities:
>>> from cosmolopy import * >>> 'rho_crit=%.3g Msun/Mpc^3, rho_0=%.3g Msun/Mpc^3' % cden.cosmo_densities(**fidcosmo) 'rho_crit=1.38e+11 Msun/Mpc^3, rho_0=3.75e+10 Msun/Mpc^3'
Look in the tests/ and examples/ directories for more examples.
| Submodules | |
|
| Variables | |
fidcosmo =
|
|
__package__ =
|
| Variables Details |
fidcosmo
|
| Home | Trees | Indices | Help |
|---|
| Generated by Epydoc 3.0.1 on Tue Mar 27 20:49:14 2012 | http://epydoc.sourceforge.net |


10 search results found!
Loading...
No more search results at the moment!
Oops!
It’s not you. It’s us. Give it another try, please.
- Check your intenet connectivity and try again later after some time.
No search results found!
Try below suggested quick fixes!
- Make sure that your search is spelled correctly.
- A valid City or State should contain alphabets and spaces only
- Avoid numbers and special characters in your seacrhing
- Type one character at time and Wait for results to appear then scroll down to find a certain City or State


{{< layout}} {{$propositionHeader}}{{/propositionHeader}} {{$pageTitle}}Information about urgent passport{{/pageTitle}} {{$header}} {{/header}} {{$main-content}}
Get a paper form at the Post Office
Get 2 printed passport photos from a photo shop
Book an appointment to drop off your completed form and photos
Collect your new passport 4 hours later
An adult passport costs £128 using this service. If you're applying for
a child passport, you need to use Fast Track.


Tubeloh
[tu:bi:laah]
Log In
Remember my login
Click me!
Stub
Aurora
Sunrise
Daylight
Funky
White
Dec 6
Design your own
Direct
Waiting for program info..
<<       Back to programs
Hue:
Saturation:
Value:
Show advanced controls >>>
<<       Back to basic controls
Define ranges for colors:
Hue 1:
Hue 2:
Saturation 1:
Saturation 2
Value 1:
Value 2:
Movement: (pixels / s)
Synth: Attack-Sustain-Decay (1/100s)
Size, blur (pixels)
Polyphony - number of simultaneous gradients
Settings Page Contents


--- layout: post authors: ["Greg Wilson"] title: "IPython Funding: Hurray!" date: 2012-12-12 time: "10:00:00" tags: ["Community"] ---
Via email:
We are proud to announce that we've received funding from the Alfred P. Sloan Foundation that will support IPython development for the next two years. Thanks to this $1.15M grant, Brian Granger and Fernando Perez will be working roughly 3/4 of their time on IPython, Min Ragan-Kelley will be the lead project engineer, and Paul Ivanov and Thomas Kluyver will work as postdocs on the project. Furthermore, Matthew Brett and JB Poline of Nipy fame will be working part-time on the development of notebooks for applied statistics in collaboration with Jonathan Taylor from Stanford.
This will also give resources to support two annual all-hands development sprints at Berkeley where I hope all our core developers will be able to attend, as well as funding for cloud resources so that we can provide paid support for our CI hosting and nbviewer beyond what the free plans allow (and further services that may arise over time).
We'd like to particularly thank Josh Greenberg, our program director at the Sloan Foundation, for the phenomenal guidance and support he provided during the grant proposal preparation and detailed review process.
Needless to say, we are extremely excited about this news. We'll have more announcements to make over the next few weeks, but now I need to get a lot of administrative wheels in motion quickly, as the funding officially starts Jan 1, 2013!
- Fernando Perez


Oman rains: Family stuck in car
by Times News ServiceMuscat: In the middle of heavy rainfall currently being experienced at Al Buraimi, a family is reported to be stuck in their vehicle in Wadi Madha while another person is stuck in a vehicle at north Al Batinah.
In a statement, the Royal Oman Police said, "A family was reported to be stuck in a car at Wadi Madha, the situation is still being dealt with."
The Public Authority for Civil Defence and Ambulance (PACDA) said in a statement, "The Authority's Operations Center received a report on the detention of a person inside a vehicle in a wadi stream in the wilayat of Shinas, North Al Batinah Governorate."


COPPER FOR TECHNOLOGY COMPANIES
Big and small software companies grow and scale faster with Copper.
Software and technology companies at every stage of growth love Copper.
BUILT FOR G SUITE
Copper is designed and built for G Suite so your team can do everything—from adding leads to closing deals right from your inbox.
Learn MoreZERO DATA ENTRY
Copper automatically inputs leads, contacts, account details, email history and more, so you can spend your time closing deals, not copying and pasting.
LumApps manages 2,000% lead growth with CopperDATA ACCURACY
Copper creates clear and elegant reports that make it easy for everyone on your team to get the insights they need to close a deal: a bird’s eye view, a deep dive or anything in between.
How OneSupport grew subscribers by 173%By The Numbers
hours per user per week saved on manual data entry
more accurate reporting
increase in team collaboration when closing deals
faster response time to prospects and clients
Resources
No credit card required. Start your 14-day free trial today.


Black Teachers
After the passing of Brown v Board of Education of Topeka and the backlash that followed, concerns about the type of education that Black students would be receiving began to arise. Although the Brown decision was made in Topeka, and the country began to see changes in some schools like Central High School in Little Rock, many cities were still in the pre-Brown state of public education. In the midwest, predominantly Black schools were prevalent and were increasing in quantity. It's been noted that racial segregation in schools was not an issue until around 1964, nearly ten years after the Brown decision. This revelation seems odd because there surely was an amount of civil rights leaders and Black teachers who could've spoken out against racial segregation, but for nine years after a historic case did not. This has a lot to do with early civil rights activism and the history of difficulties of Black employment.
Students in class at a predominantly black school (1954)
Black Milwaukee activists were involved in the hiring process for Black teachers. They steadily pressured school officials to hire college educated Black teachers to improve education and provide guidance to Black students. Black teachers were rarely hired, in fact before the 1930s, there wasn't a single Black teacher employed by Milwaukee public schools despite the rising Black population in the state. It was so difficult for Black people to be hired as teachers that even Black college graduates came to a realization that the only work available to them was low paying, and labor based even though they obtained their degree. During this time, employment was especially tough for women, who were limited to domestic work. This is depicted in Toni Morrison's, The Bluest Eye.
The character, Mrs Pauline Breedlove is a housekeeper and has been one since she was around the age 15. She continues this profession when she moves from Kentucky to Ohio, working for a white woman. This character embodies the average black woman during this era, showing the reality of options for employment. An eye opening scene in this novel is when Mrs Breedlove attempts to negotiate with her employer to keep her job. This comes shortly after her husband, Mr Cholly Breedlove pays her an unwarranted visit and frightens the white woman. Because of this, she gives Mrs Breedlove an ultimatum, keep her job and leave Cholly or stay with him and get fired. This puts Mrs Breedlove in a difficult position because not only did she need her job to survive, it also would've been difficult to find another job due to employment options being limited for Black women during this era.
It was common for administrators to reject qualified Black applicants due to predjudices and the assumption that many of them were migrants who came up North in search of jobs. There were several occurences of Black teachers being hired but the action was merely used as an example. During a 1932 Milwaukee election, two Black teachers were hired for the substitute teaching role at an elementary school. Teaching as substitutes was common for teachers awaiting full time positions. The candidate who was responsible for the hiring of the two women later won the election. Shortly after his win, one of the two women hired was fired from her substitute teaching position while the other one was demoted from a full time to a part time substitute.


Deeply mix the properties of objects into the first object. Like merge-deep, but doesn't clone.
Please consider following this project's author, Jon Schlinkert, and consider starring the project to show your :heart: and support.
Install with npm:
$ npm install --save mixin-deep
var mixinDeep = require('mixin-deep');
mixinDeep({a: {aa: 'aa'}}, {a: {bb: 'bb'}}, {a: {cc: 'cc'}});
//=> { a: { aa: 'aa', bb: 'bb', cc: 'cc' } }
 Contributing
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.

 Running Tests
Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command:
$ npm install && npm test
  Building docs
(This project's readme.md is generated by verb, please don't edit the readme directly. Any changes to the readme must be made in the .verb.md readme template.)
To generate the readme, run the following command:
$ npm install -g verbose/verb#dev verb-generate-readme && verb

You might also be interested in these projects:
extend
but recursively copies only the missing properties/values to the target object. | homepageJon Schlinkert
Copyright © 2017, Jon Schlinkert. Released under the MIT License.
This file was generated by verb-generate-readme, v0.6.0, on December 09, 2017.


Developer
My name is Praneet Nadella and I am currently a student at Nashua High School South. I have a passion for the field of computer science and to pursue this, along with completing various programming courses, I have competed at various regional hackathons. I know both front end and some back end development and I'm proficient in various languages that can be applied anywhere from Machine Learning and AI to App and Web Devlopement. My projects range from simple programs to mobile apps. My specialities are as follows:
Diploma Expected June 2021
Class Rank: 11/434
4.97/5.4 Weighted GPA 3.93/4.2 Unweighted GPA
Relevant Coursework: AP Computer Science A, AP Calculus AB, AP Calculus BC, AP Statistics, (currently enrolled), AP Physics 1, Java Programming Honors, Pre-Calculus Honors
I am certified in Machine Learning and implementing ML techniques to create AI applications. This course also contained instruction on GNU Octave and Matlab (see below) which were used in the course. Find my certification here:
Machine Learning
I am currently certified in Dart and the Flutter SDK to create and deploy Android and IOS applications. I am currently applying this knowledge to create mobile applications that will be available in the Google Play Store and Apple Ap Store. Find my certification here:
Learn Flutter & Dart to Build iOS & Android Apps
I am certified in the Python Programming Language. This course also contained instruction on XML parsing and database management using SQL, which were used in the course. Find my certifications here:
Programming for Everybody(Getting Started with Python)
Python Data Structures
Using Python to Access Web Data
Using Databases with Python
Retrieving, Processing, and Visualizing Data with Python
Python for Everybody
I am currently certified in full stack web development using languages and libraries such as HTML, CSS, JavaScript, Bootstrap, and more. These were applied to create this website. Find my certification here:
The Web Developer Bootcamp


--- title: "COVID-19 Visualization" author: "Chong Zhang" date: "2021-04-01T00:00:00-07:00" output: pdf_document: default urlcolor: blue header-includes: - \usepackage{lastpage} - \usepackage{fancyhdr} - \pagestyle{fancy} - \fancyhead[CO, CE]{Chong Zhang} - \fancyfoot[CO, CE]{\thepage \ of \pageref{LastPage}} ---
Code last run 2021-04-01.
Daily: Data as of January 29, 2021.
Neighbourhood: Data as of January 28, 2021.
reported<- reported_raw%>%
mutate_if(is.numeric,replace_na,replace=0)%>%
mutate(reported_date=date(reported_date))%>%
pivot_longer( -c(reported_date),names_to= "status",values_to='count')%>%
mutate(status=str_to_sentence(status))%>%
mutate(status=fct_relevel(status,'Recovered',after=1))
#reported[is.na(reported)] <- 0
reported%>%
ggplot(aes(x=reported_date,y=count,fill=status))+
geom_bar(stat = 'identity')+theme_minimal()+
labs(title="Cases reported by day in Toronto, Canada",
subtitle = "Confirmed and probable cases",
x="Reported date",
y="Case count",
caption = str_c("Created by: Chong Zhang for STA303/1002,U of T\n Source: Ontario Ministry of Health, Integrated Public Health Information System and CORES\n",date_daily[1,1]))+
theme(legend.title = element_blank(),legend.position = c(0.15,0.8))+
scale_x_date(labels=scales::date_format("%d %b %y"),limits = c(date("2020-01-01")
,Sys.Date()))+
scale_y_continuous(limits = c(0,2000))+
scale_fill_manual(values = c("#003F5C","#86BCB6","#B9CA5D" ))
outbreak<-outbreak_raw%>%
mutate(episode_week=date(episode_week))%>%
mutate(outbreak_or_sporadic = str_replace(outbreak_raw$outbreak_or_sporadic,"OB Associated","Outbreak associated"))%>%
mutate(outbreak_or_sporadic= fct_relevel(outbreak_or_sporadic,'Outbreak associated',after=1))%>%
group_by(episode_week)
outbreak1<-outbreak_raw%>%
group_by(episode_week)%>%summarise(total_cases=sum(cases),.groups="drop")
outbreak%>%
ggplot(aes(x=episode_week,y=cases,fill=outbreak_or_sporadic))+
geom_bar(stat = 'identity')+theme_minimal()+
labs(title="Cases by outbreak type and week in Toronto, Canada",
subtitle = "Confirmed and probable cases",
x="Episode Week",
y="Case count",
caption = str_c("Created by: Chong Zhang for STA303/1002,U of T\nSource: Ontario Ministry of Health, Integrated Public Health Information System and CORES\n",date_daily[1,1]))+
theme(legend.title = element_blank(),legend.position = c(0.15,0.8))+
scale_x_date(labels=scales::date_format("%d %b %y"),limits = c(date("2020-01-01")
,Sys.Date()))+
scale_y_continuous(limits = c(0,max(outbreak1$total_cases)))+
scale_fill_manual(values = c("#86BCB6","#B9CA5D"))
income <- nbhood_profile %>%
filter(`_id`==1143) %>%
pivot_longer(-c(`_id`,Category,Topic,`Data Source`, Characteristic),names_to = "neighbourhood_name",values_to="percentage") %>%
mutate(percentage=parse_number(percentage))
nbhoods_shape_raw$AREA_NAME[nbhoods_shape_raw$`_id`==10681]<-"Weston-Pelham Park (91)"
nbhoods_shape_raw$AREA_NAME[nbhoods_shape_raw$`_id`==10755]<-"Cabbagetown-South St. James Town (71)"
nbhoods_shape_raw$AREA_NAME[nbhoods_shape_raw$`_id`==10659]<-"North St. James Town (74)"
nbhoods_all<-nbhoods_shape_raw%>%
mutate(neighbourhood_name =str_remove(nbhoods_shape_raw$AREA_NAME ,"\\s\\(\\d+\\)$"))%>%
left_join(income,by="neighbourhood_name") %>%
left_join(nbhood_raw,by="neighbourhood_name") %>%
rename(rate_per_100000=rate_per_100_000_people)


{% extends 'layouts/layout-transactional.html' %} {% block pageTitle %} Check your email {% endblock %} {% block content %}
We've sent an email to<EMAIL_ADDRESS>Click confirm in the email and continue from there.
If you do not get an email, check your spam folder.


Welcome, Daniil
It's great to see you again. Here are some of the most relevant events we think you could help turn into reality
Don't forget to spread the word - maybe it's you who knows that crucial person who makes another child happy!
Wishes' map


| Top |
WebKitWebExtension is a loadable module for the WebProcess. It allows you to execute code in the WebProcess and being able to use the DOM API, to change any request or to inject custom JavaScript code, for example.
To create a WebKitWebExtension you should write a module with an initialization function that could
be either webkit_web_extension_initialize()
with prototype WebKitWebExtensionInitializeFunction or
webkit_web_extension_initialize_with_user_data()
with prototype WebKitWebExtensionInitializeWithUserDataFunction.
This function has to be public and it has to use the G_MODULE_EXPORT macro. It is called when the
web process is initialized.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
static void web_page_created_callback (WebKitWebExtension *extension, WebKitWebPage *web_page, gpointer user_data) { g_print ("Page %d created for %s\n", webkit_web_page_get_id (web_page), webkit_web_page_get_uri (web_page)); } G_MODULE_EXPORT void webkit_web_extension_initialize (WebKitWebExtension *extension) { g_signal_connect (extension, "page-created", G_CALLBACK (web_page_created_callback), NULL); } |
The previous piece of code shows a trivial example of an extension that notifies when a WebKitWebPage is created.
WebKit has to know where it can find the created WebKitWebExtension. To do so you
should use the webkit_web_context_set_web_extensions_directory()
function. The signal
“initialize-web-extensions” is the recommended place to call it.
To provide the initialization data used by the webkit_web_extension_initialize_with_user_data()
function, you have to call webkit_web_context_set_web_extensions_initialization_user_data()
with
the desired data as parameter. You can see an example of this in the following piece of code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
#define WEB_EXTENSIONS_DIRECTORY /* ... */ static void initialize_web_extensions (WebKitWebContext *context, gpointer user_data) { /* Web Extensions get a different ID for each Web Process */ static guint32 unique_id = 0; webkit_web_context_set_web_extensions_directory ( context, WEB_EXTENSIONS_DIRECTORY); webkit_web_context_set_web_extensions_initialization_user_data ( context, g_variant_new_uint32 (unique_id++)); } int main (int argc, char **argv) { g_signal_connect (webkit_web_context_get_default (), "initialize-web-extensions", G_CALLBACK (initialize_web_extensions), NULL); GtkWidget *view = webkit_web_view_new (); /* ... */ } |
void
(*WebKitWebExtensionInitializeFunction)
(WebKitWebExtension *extension
);
Type definition for a function that will be called to initialize the web extension when the web process starts.
void (*WebKitWebExtensionInitializeWithUserDataFunction) (WebKitWebExtension *extension
,const GVariant *user_data
);
Type definition for a function that will be called to initialize
the web extensions when the web process starts, and which receives
as additional argument the user data set with
webkit_web_context_set_web_extensions_initialization_user_data()
.
Since: 2.4
WebKitWebPage * webkit_web_extension_get_page (WebKitWebExtension *extension
,guint64 page_id
);
Get the web page of the given page_id
.
the WebKitWebPage for the given page_id
, or NULL
if the
identifier doesn't correspond to an existing web page.
[transfer none]
“page-created”
signalvoid user_function (WebKitWebExtension *extension, WebKitWebPage *web_page, gpointer user_data)
This signal is emitted when a new WebKitWebPage is created in the Web Process.
extension |
the WebKitWebExtension on which the signal is emitted |
|
web_page |
the WebKitWebPage created |
|
user_data |
user data set when the signal handler was connected. |
Flags: Run Last


5. Hardware timers¶
Timers can be used for a great variety of tasks, calling a function periodically, counting events, and generating a PWM signal are among the most common use cases. Each timer consists of two 16-bit channels and this channels can be tied together to form one 32-bit timer. The operating mode needs to be configured per timer, but then the period (or the frequency) can be independently configured on each channel. By using the callback method, the timer event can call a Python function.
Example usage to toggle an LED at a fixed frequency:
from machine import Timer
from machine import Pin
led = Pin('GP16', mode=Pin.OUT) # enable GP16 as output to drive the LED
tim = Timer(3) # create a timer object using timer 3
tim.init(mode=Timer.PERIODIC) # initialize it in periodic mode
tim_ch = tim.channel(Timer.A, freq=5) # configure channel A at a frequency of 5Hz
tim_ch.irq(handler=lambda t:led.toggle(), trigger=Timer.TIMEOUT) # toggle a LED on every cycle of the timer
Example using named function for the callback:
from machine import Timer
from machine import Pin
tim = Timer(1, mode=Timer.PERIODIC, width=32)
tim_a = tim.channel(Timer.A | Timer.B, freq=1) # 1 Hz frequency requires a 32 bit timer
led = Pin('GP16', mode=Pin.OUT) # enable GP16 as output to drive the LED
def tick(timer): # we will receive the timer object when being called
global led
led.toggle() # toggle the LED
tim_a.irq(handler=tick, trigger=Timer.TIMEOUT) # create the interrupt
Further examples:
from machine import Timer
tim1 = Timer(1, mode=Timer.ONE_SHOT) # initialize it in one shot mode
tim2 = Timer(2, mode=Timer.PWM) # initialize it in PWM mode
tim1_ch = tim1.channel(Timer.A, freq=10, polarity=Timer.POSITIVE) # start the event counter with a frequency of 10Hz and triggered by positive edges
tim2_ch = tim2.channel(Timer.B, freq=10000, duty_cycle=5000) # start the PWM on channel B with a 50% duty cycle
tim2_ch.freq(20) # set the frequency (can also get)
tim2_ch.duty_cycle(3010) # set the duty cycle to 30.1% (can also get)
tim2_ch.duty_cycle(3020, Timer.NEGATIVE) # set the duty cycle to 30.2% and change the polarity to negative
tim2_ch.period(2000000) # change the period to 2 seconds
5.1. Additional constants for Timer class¶
-
Timer.
PWM
¶ PWM timer operating mode.
-
Timer.
A
¶
-
Timer.
B
¶ Selects the timer channel. Must be ORed (
Timer.A
|Timer.B
) when using a 32-bit timer.
-
Timer.
POSITIVE
¶
-
Timer.
NEGATIVE
¶ Timer channel polarity selection (only relevant in PWM mode).
-
Timer.
TIMEOUT
¶
-
Timer.
MATCH
¶ Timer channel IRQ triggers.


Time and Habits
December 3, 2015
which timebox and habits techniques did you try?
I dicovered the Pomodoro technique just last week. I've been using it almost everyday since and so far it's the most effective tool I've found for focus. Previously I had tried 50, 60 and 90 minute time blocks but I currently have quite a short attention span so the 25min pomodoro block is perfect. Plus 5mins is just the right amount of time to pee and make a celebratory cup of tea!
What did you find interesting?
There were three main points I found most interesting:
- Foggs suggestion to use trigger behaviours to help develop good habits. i.e. After I [existing habit], I will [new habit]
- Duhigg and Sethi's suggestion to keep track of your focus so you can convince yourself you're getting better at it. Start with the behaviour, the attitude will follow
- It's important to celebrate your achievements, no matter how small. For me that means that when I get halfway through a Pomodoro I can do a little dance. When I've done a full Pomodoro I'll do a couple of yoga poses and have some chocolate!
What worked for you?
I'm still new to this journey but so far the most valuable thing is starting small and allowing myself to feel satisfaction in the little achievments. I'm also finding the Pomodoro technique to be awesome!
What will you experiment further with?
This counter-intuitive productivity stuff looks really cool. I've only just skimmed but I'll be looking into it and experimenting over the next week or so.


 You should be receiving it shortly.
{% endblock %}


#!/usr/bin/env <%= RbConfig::CONFIG[‘ruby_install_name’] %> # # This file was generated by Bundler. # # The application ’<%= executable %>’ is installed as part of a gem, and # this file is here to facilitate running it. #
require ‘pathname’ ENV[‘BUNDLE_GEMFILE’] ||= File.expand_path(“../<%= relative_gemfile_path %>”,
Pathname.new(__FILE__).realpath)
require ‘rubygems’ require ‘bundler/setup‘
load Gem.bin_path(’<%= spec.name %>’, ’<%= executable %>’)