Cutomization
Learn how to create your own style without changing the theme’s core files so you can take advantage of future updates.
Prerequisites
Make sure you have the followed the steps from the Build tools page. You should have already installed the following:
- Node.js
- Gulp or Laravel Mix
SASS
Sass is the most mature, stable, and powerful professional grade CSS extension language in the world. To learn more click here to see the official documentation.
File structure
The Sass structure is built from two main folders:
- purpose, which contains the extended components based on Bootstrap and also the custom built ones
- skins, which contains folders with different custom variables that allow you to change the theme’s appearance with ease.
- custom, which contains a basic structure made from a style, a font and a variable files in order to get you started with the customization process nice and easy
Heads up! Bootstrap is automatically loaded from the node_modules folder in the purpose.scss
file. It is installed via npm install
and compiled using the build tools.
Remember, you are not limited to use the structure we have included in the resources/scss/user
folder. If you have a more complex project you can choose to follow the directory structure we have made for Purpose. This will help you create modular components easily extendable and re-usable.
Below is the main structure you will be able to see inside the main SCSS folder:
Important! We highly recommend to not make changes to the purpose folder. It includes core files and components that can be updated in the future. If you want to take advantage of future updates you may want to have a more Bootstrap-ish approach, meaning you should create new styles or components to override styles, extend or add new components in the custom
folder.
Variable defaults
Every Sass variable in Bootstrap 4 and Purpose includes the !default
flag allowing you to override the variable’s default value in your own Sass without modifying Purpose’s source code. Copy and paste variables as needed, modify their values, and remove the !default flag. If a variable has already been assigned, then it won’t be re-assigned by the default values in Bootstrap.
You will find the complete list of Purpose’s variables in resources/scss/purpose/_variables.scss
.
Changing variables
In order to make Sass features modular and re-usable each component has its own styles and its own set of variables. Variables should follow the $component-state-property-size
formula for consistent naming.
Ex: $nav-link-disabled-color and $modal-content-box-shadow-xs.
Let’s say you need to change the primary color with the one you use for you brand. All you have to do is to:
- open the
purpose/_variables.scss
, look for the$primary
variable and copy it - open the
custom/_variables.scss
and paste the variable with its value - replace the value and remove the
!default
flag - make sure you are running Gulp or Laravel Mix watch tasks described in the build tools page
Try following the same variable succession order. Especially, colors, typography and other fundamental variables need to be declared at the beginning of the file so they can be accessible to the components that may follow afterwards.
Creating components
Creating components is easy. It is even easier if you follow the guidelines we are suggesting. This we’ll keep make your code look clean and be easy to read and to work with. Also you will make sure you have results at the same level of quality as Purpose or Bootstrap.
There are a few steps:
First, determine which component are you going to develop next. Even though it already exists, let’s say you want to create an alert
component.
Determining exactly the component and its purpose you help you to find a name very easily.
So, in this case the class name for alert
will be .alert
. Other variations or modifier classes will begin with .alert-*
(e.g: .alert-danger, which will change the background and text color accordingly).
Also, all variables associated to the class .alert
will begin with $alert
, $alert-*
. Basically, you will need to follow the naming convention Bootstrap and Purpose use: $name-state-property-modifier
, where:
name
is the component name corresponding to the given class name (e.g .alert)state
is the pseudo-class used to define a special state of an element (e.g: hover, active, checked etc)property
is the given CSS property in order to achieve the results you need (e.g: color, background, display)modifier
is used to define additional information for the current property, like sizes, axis (e.g alert-sm, alert-padding-y)
To wrap it up, you should have in the end something like this:
In custom/_variables.scss
In custom/_styles.scss
Remember! You can modify the structure inside the user’s folder. You can make separate files for each newly created component and import them one by one in the _styles.scss
file. They will be automatically loaded and compiled in the main Sass file.
JS
File structure
You will find in Purpose a special structure for the JS files. We did this to sort each script by its scope. In the resources/js
folder you will find the following file structure:
- custom contains all the custom scripts made by us for Purpose
- init contains all the scripts needed to initialize the Purpose’s components or third-party plugins
- maps contains map scripts needed to customize the default Google Map style or other map library
- libs contains all the scripts needed to initialize third-party plugins
- layout.js is a file where we put the code needed to develop global layout actions
Making changes
Most of the JS files are just a starting point in order to make the components function properly. This means that you will need to change them accordingly, add options, create more functions and so on. All the plugins are well documented and each one has the link that will point you to the official documentations.
Also, when starting a new project you can install only the plugins you need.
Note! When starting modifying JS files make sure you keep an eye on those you edited, because Purpose will be constantly updated.
Compiling
Wether you chose to use Gulp or Laravel Mix, the mechanism behind gets the same result. All JS resources will be bundled in a single file. For the watch
commands, each time you make a change, the file will be automatically regenerated and injected in the browser. Learn more about the build tools.


You make terrain in an area up to 1 mile square look, sound, smell, and even feel like some other sort of terrain. The terrain's general shape remains the same, however. Open fields or a road could be made to resemble a swamp, hill, crevasse, or some other difficult or impassable terrain. A pond can be made to seem like a grassy meadow, a precipice like a gentle slope, or a rock-strewn gully like a wide and smooth road.
Similarly, you can alter the appearance of structures, or add them where none are present. The spell doesn't disguise, conceal, or add creatures.
The illusion includes audible, visual, tactile, and olfactory elements, so it can turn clear ground into difficult terrain (or vice versa) or otherwise impede movement through the area. Any p iece of the illusory terrain (such as a rock or stick) that is removed from the spell's area disappears immediately.
Creatures with truesight can see through the illusion to the terrain's true form; however, all other elements of the illusion remain, so while the creature is aware of the illusion's presence, the creature can still physically interact with the illusion.


About
Help
Profile
Settings
Activity
Add
Edit
Delete
Job
Add
Edit
Delete
Employer
Add
Edit
Delete
Logout
×
What job is the Activity? (ID)
Start time (dd-mm-yyyy hh:mm)
End time (dd-mm-yyyy hh:mm)
Earnings
Save Activity
×
Choice a shift you want to edit (ID):
Insert the correct details.
What job is the Activity? (ID)
Start time (dd-mm-yyyy hh:mm)
End time (dd-mm-yyyy hh:mm)
Earnings
Edit Activity
×
Choice a shift you want to delete:
Delete Activity
×
What company is the job for?
What is the job's name
How much do you earn a hour?
Save Job
×
Choice a job you want to edit:
Insert the correct details.
What company is the job for?
What is the job's name
How much do you earn a hour?

What are the phone number?
Save Employer
×
Choice an employer you want to edit: (ID)
Insert the correct details.
WorkerID
What is the name of your Employer?
What are the phone number?
Edit Employer
×
Choice an employer you want to delete:
Delete Employer


Annex Halloween mass stabbing suspect appears briefly in court
by Chris Herhalt, CP24.comA 19-year-old man accused of stabbing several people outside a Halloween party, fatally wounding one of them, appeared briefly on a video teleconference screen in a College Park courtroom on Monday morning.
Toronto police were called to a house at 22 Madison Avenue, north of Bloor Street, shortly before midnight on Oct. 31 for a report of three people stabbed outside.
Investigators said two people became angry outside the home after being denied entry to a Halloween party inside.
They both forced their way in, slashing and stabbing people inside, and then outside as they were leaving, police said.
Officers arrived at the party to find three people suffering from stab wounds.
A further search of the area led them to locate two other victims suffering from minor injuries.
One of those stabbed, 19-year-old Firdous Nabizada, died in hospital on Nov. 2.
One suspect, later identified as Jacob Alves, 19, was detained by police roughly an hour after the altercation began.
A second suspect, a 15-year-old girl from Richmond Hill who cannot be identified per the terms of the Youth Criminal Justice Act, was arrested some time later.
Alves appeared at College Park via video link on Monday.
His case was put over until the morning of Dec. 2.
He faces charges of second-degree murder, aggravated assault, assault with a weapon and weapons dangerous.


WDRP (Weather Dependent Route Planning)
Static Graphs
Algorithms
TD Graphs
TD Algorithms
Weather Maps
Play


Prime Minister, Narendra Modi, in a step towards conserving the environment, has launched the Prakash Path (Way to Light), a National Programme for LED-based Home and Street Lighting.
Under this scheme, the government is planning to replace 77 crore conventional bulbs and 3.5 crore conventional streetlights with the LED range.
As per the Economic Survey 2015-16, this change will see a savings of Rs 45,500 crore by reducing 21,500 MW electricity demand.
The Prime Minister replaced one bulb with an LED in the South Block in Delhi.
Just replacing all the bulbs in the South Blcok with LED will result in the saving of 7000 units of energy per month.
This is a Government of India scheme designed to provide continuous power supply to rural India.
The government plans to invest ₹756 billion (US$11 billion) for rural electrification under this scheme.
The scheme will replace the existing Rajiv Gandhi Grameen Vidyutikaran Yojana (RGGVY).
Keeping in view the above problems, Ministry of Power, Government of India has launched Deen Dayal Upadhyaya Gram Jyoti Yojana for rural areas having following objectives:
1. To provide electrification to all villages
2. Feeder separation to ensure sufficient power to farmers and regular supply to other consumers
3. Improvement of Sub-transmission and distribution network to improve the quality and reliability of the supply
4. Metering to reduce the losses
Benefits
• All villages and households shall be electrified
• Increase in agriculture yield
• Business of Small and household enterprises shall grow resulting in new avenues for employment
• Improvement in Health, Education, Banking (ATM) services
• Improvement in accessibility to radio, telephone, television, internet and mobile etc.
• Betterment in social security due to availability of electricity
• Accessibility of electricity to schools, panchayats, hospitals and police stations etc.
• Rural areas shall get increased opportunities for comprehensive development


[1]
this one would rate 'for better or for worse.
[2]
yes a bit quirky but i have stayed in part it hit the uco valley.


Home
|
Contact
|
About
It's
Mariya
+91 xxx xxx 5308
<EMAIL_ADDRESS>Left Pane
This is my first Webapp! I'm running this App from my local box!
Some Info
Name List
Right Pane


Enumerable Method: Map
DBC Phase 0 Week 5
January 9, 2016
"Enumerable" is both a module, meaning its a group of methods packaged together, and a mixin, meaning it can be used in other classes such as arrays and hashes. It is comprised of enumerable methods, which are methods that allow for traversing through and searching objects.
One of these methods is map
. It has both a non-destructive(plain old map
) and destructive(map!
) version. This means that map
will create a copy of the array you call it on, so the original array is not affected by the method, while map!
will modify the original array, so it won't exist in its original form anymore.
Map
is used to transform an array. When you call the map method, it will be followed by a code block in which you specify the change you would like to make to the elements in the array. Map will then iterate through the array and apply that change to each element.
For example, say you have an array of integers and would like to multiply each integer by 2. Within the block, you declare a temporary variable for the current element, then specify that you want to multiply it by 2.
Now, nums
will still have the original values, [2,5,9,15]
, while nums_times_two
will have the transformed values of [4,10,18,30]
.
If you use the destructive version, map!
then both nums
and nums_times_two
will have the transformed values of [4,10,18,30]
.


"Town & Country"
Warren Beatty, Diane Keaton, Goldie Hawn and Gary Shandling star as a pair of married couples whose complacent lives are about to be shaken up in director Peter Chelsom's version of the classic romantic, screwball comedy in "Town & Country."
The drawing room farce of the 30's dealt with sexual innuendo and relied on wit and a great deal of commotion and noise to place the viewer in the thick of the duplicitous romantic action. Back then, impossibly wealthy scions of society, with too much free time, would get themselves wrapped up in all sorts of sexual peccadilloes with spouses and lovers, only to have everything come out all right in the end - see "The Philadelphia Story" for a great farce. "Town & Country" has the impossibly wealthy protagonists with too much free time - the kind of people that have jobs but never seem to work - and sexual misconduct on several levels. But, there is almost no life to original script by Michael Laughlin and Buck Henry and this is "T&C's" downfall.
There is, obviously, a great deal of Hollywood talent, in front of and behind the camera, involved in "Town & Country," but, without a likable or, at least, interesting story to carry through their efforts, it is all for naught. And, that's what we get here - naught.
Porter Stoddard (Beatty) is a high-powered New York architect with a very good life indeed. His 25-year marriage to Ellie (Diane Keaton) appears, on the surface, to be perfect. But, there are cracks just below this pristine surface. His wife is suspicious of his whereabouts, his kids don't need him and his best friends, Griffin (Garry Shandling) and Mona (Goldie Hawn), are in the midst of a divorce. Porter tries to get control of his life before it is too late, but like a man fighting against quicksand, his struggle just sinks him deeper.
At the 90-minute mark of "Town & Country" I asked myself, "What's the point?" I wasn't entertained, I laughed three times - over silly little pratfalls - and spent most of the film marking time 'til the end. Warren Beatty wanders around with his character in a bewildered fog, making problems for himself by thinking with a part of his anatomy other than his head.  And, as you get to know them, who would want friends like Griffin and Mona?
The supporting cast is given nothing to do and, sometimes, does harm to the film, given the material they are forced to use. Nastassja Kinski plays a cellist with whom Porter has a fling. The actress, who has, eerily, failed to age over the years, is miscast as the air-headed musician and the character doesn't belong, anyway. Jenna Elfman is a sweet, but smart, ditz who joins Porter and Griffin on one of their tacked on misadventures. Andie MacDowell is absolutely painful to watch as a wealthy heiress (is there any other kind in this movie?) who comes on to Porter. The saving grace is a pair of quirky perf's by Charlton Heston and Marian Seldes as MacDowell's very strange parents.
Glib rationalization of infidelity, like, "If he doesn't speak English, it doesn't count," are a staple for the screenplay. The morality of the film seems to be, if you can get away with it, go for it. The cast of characters are mostly people you wouldn't want to know, never mind befriend. The actors do their best, but are hamstrung by the weak material. Helmer Chelsom, who made the outstanding, offbeat comedy "Funny Bones," is mired in the mess of a script and never puts his imprint on "Town & Country."
The production values are high, as one expects from a big budget Hollywood film. But, the opulent sets by Caroline Hanania, lavish wardrobes by Molly Maginnis and top-notch photography by William Fraker cannot save "Town & Country." The film has had a long list of production and distribution problems and it might have been better, for me anyway, if Hollywood just said no to this movie. I give it a D.
For more Reeling reviews visit www.reelingreviews.com
<EMAIL_ADDRESS><EMAIL_ADDRESS>========== X-RAMR-ID: 28671 X-RT-AuthorID: 1488 X-RT-TitleID: 1107209 X-RT-RatingText: D
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


{{newpost.preview.description}}
{{post.description}}
Backdate your post so it appears in the past on your Page Timeline. Backdated posts publish immediately.
Select a date and time in the future for when you want your post to publish.


2019 Kia Stinger GT-Line four-cylinder review
All of the visual sting of the top-line Stinger GT, but with a more subtle and hip-pocket-friendly engine. Could the Kia Stinger GT-Line be the large car you’ve been searching for?
by Kez CaseyRating: 8.2
$56,290 Mrlp
- Fuel Economy
8.8L - Engine Power
182kW - CO2 Emissions
201g - ANCAP Rating
5Stars
Looking for a deal on this car?
Pros and Cons
Pros
- Strong standard equipment for the price
- Roomy and comfortable interior
- Balanced all-rounder for more mundane driving
Cons
- Awkward rear entry, egress and visibility
- Boot space and utility underdone
- The constant knowledge there's a bigger, badder twin-turbo V6
- shares
It’s not quite up to its midlife overhaul yet, but with a running model-year change, the Kia Stinger has come in for attention.
As a result, Kia’s star attraction now features a simpler range. Mid-spec models have been ditched, leaving entry level and flagship variants to carry on, along with some small tweaks to specification.
The 2019 Kia Stinger GT-Line on test here represents the upper echelon of the four-cylinder range, though unless you're an avid trainspotter, there’s not much to separate it visually from the V6-powered Stinger GT.
Priced from $56,290 plus on-road costs, the Stinger GT-Line sits a significant $9100 above the entry-level Stinger 200S, but asks $4500 less than the fully fledged GT. A somewhat happy middle-ground overall, particularly if you don’t need the rush of a hi-po turbo V6.
Across the range, all variants feature dual-zone climate control, rear air vents, LED interior lighting, proximity key with push-button start, auto lights and wipers, sports seats with powered adjustment for the driver, power-folding mirrors, rear-view camera with dynamic lines, and rear park sensors.
The step up to GT-Line specification adds features like 19-inch alloy wheels (over base-model 18s), real leather trim, powered passenger seat, additional driver seat adjustment with memory settings, front seat heating and cooling, heated steering wheel, sunroof, LED headlights, a 7.0-inch TFT instrument cluster display, wireless phone charging, suede-look headlining and sports pedals.
The GT-Line also picks up an upsized 8.0-inch infotainment system with a ‘bezel-less’ display, 15-speaker Harman Kardon audio, satellite navigation with 10 years of traffic info and free map updates, AM/FM/DAB radio, plus Android Auto and Apple CarPlay compatibility.
The interior is a pleasant place to be. It might only be a little thing, but the new screen treatment gives a more premium feel to the interior compared to launch versions. The aluminium trim treatments and general look and feel of the interior straddle mainstream and upmarket satisfactorily. There’s nothing that feels underdone or cheaped-out, yet premium marques still have some breathing room.
We’ve noted noises and creaks from Stingers in the past. On this occasion, the GT-Line didn’t put a foot wrong in that regard.
The red trim option makes for a rather dramatic-looking interior. The front seats feature a sporty profile, but still manage to fit a variety of shapes and sizes with little fuss.
The hunkered-down roof line means you’ll have to drop down into the rear bench, but once inside there’s much more leg room than expected. The raked seats are relaxing to recline into, but outward visibility is limited.
Pop the powered tailgate for access to 406L of boot space, with a long and wide boot, but a lack of overall depth. With the 60:40-split rear seat folded, space grows to 1114L, though the floor isn’t fully flat.
There are no built-in bag hooks or other utility functions built into the boot either (honestly, these are my new favourite obsession – a good bag hook means never having to chase your groceries around the nooks of your boot again).
If you’re keeping score on the safety front, all Stinger variants include seven airbags, a pedestrian-protecting pop-up bonnet, rear park sensors, rear-view camera, self-dimming interior mirror, autonomous emergency braking, lane-keep assist and driver-attention monitoring.
The GT-Line adds in extra safety-skewed convenience touches with front sensors, a 360-degree camera system, dimming exterior mirrors and high-beam assist. Infotainment includes warnings for level crossings and fixed red light or speed cameras – helpful, but it might be nice if they were a touch less intrusive and persistent.
All Stinger variants carry a five-star ANCAP safety rating as of April 2018 (under 2017 assessment criteria), though earlier entry-grade cars hold a four-star rating owing to a lack of AEB.
Take to the road, and with 182kW and 353Nm from a turbocharged 2.0-litre four-cylinder, the lesser-engined Stinger provides output that’s above adequate without being boisterously over the top. In the role of family runabout, it's approachable, easy to operate, and free from aggravating quirks.
Matched to an eight-speed torque converter automatic and sending power to the rear wheels, the auto is smooth and linear, as is power delivery from the engine. No jolts, shuddering, or over-eager rear-wheel action here.
Two functions are included that perhaps aren’t as agreeable depending on your personal preference. One is a coasting mode for the transmission, and the other is an artificially generated engine sound.
The former decouples the engine and transmission when lifting off the throttle, which is fine in theory, while the other makes a more, uh… Evocative noise when you prod the throttle. Menu settings allow both to be deactivated, and the Stinger GT-Line is all the more pleasant with them off.
There’s no real sense of occasion as the engine spools up. It’s not too peaky, delivering torque in a consistent arc and making it more suited to business than pleasure.
Perhaps it’s a little hard to warm to the 2.0-litre engine knowing the far swifter 3.3-litre twin-turbo V6 exists, yet in all but the most focused driving, the four-cylinder is more than up to the task. It may not rev as feverishly, or pin you as hard in your seat, but for meandering from home to office to school run it has more than enough punch.
Kia suggests a 0–100km/h time of six seconds flat. That’s still pretty decent. You have to work to extract it, though. You won’t find that potential by accident, and in Comfort or Eco modes the package isn’t as lively as Sport mode.
Local calibration ensures the adaptive suspension delivers good ride, even with big 19-inch wheels and staggered 225/40 front and 255/35 rear tyres. Big hits still tend to reverberate through the cabin with a boom, but the discomfort is more aural than physical.
Ride can also be adjusted via the drive-mode controller. Sport mode seems a touch too unforgiving for all but the smoothest roads, but playing with the Individual mode allows a comfortable ride with the more eager sporty settings for engine and transmission, which is a great way to wake the Stinger up if you’re keen on a more spirited experience.
The Stinger GT-Line is decently comfortable, hushed and relaxed for long, loping drives. Better to stick with its strengths than push it into performance it can’t deliver. Once again, the Stinger V6 is your safer bet for outright whomp.
Fuel consumption is rated at an official 8.8 litres per 100km. Our test saw a rather close 9.8L/100km, but how you use your car will have an impact. The trip computer indicated as low as 6.5L/100km on highway runs or 14.4L/100km on all-urban runs.
Kia’s seven-year/unlimited-kilometre warranty (or capped to 150,000km for commercial-use cars) still stands as one of the longest aftersales programs available. Capped-price servicing is also available over the warranty period.
Maintenance costs tally $3528 inclusive of fluids and filters at $298, $484, $369, $670, $335, $618, and $754 for each respective visit on 12-month or 10,000km intervals – whichever comes first, meaning some owners may push past one service per year on distance.
An abundant equipment list, workable and comfortable interior, and polite dynamics give the Stinger GT-Line real positive presence. It’s eye-catching without massive compromises to family functionality.
The GT-Line will forever live in the shadow of the more muscular V6 GT, though it needn’t. Every bit as well equipped where it matters, with a more sensible approach to performance and economy, the flagship four-cylinder finds its own comfortable niche in the Stinger line-up.
MORE: Stinger news, reviews, comparisons and videos
MORE: Everything Kia
Our Ratings Breakdown
Rating: 8.2
7.5 Performance
8.4 Ride Quality
8.5 Handling & Dynamics
7.9 Driver Technology
7.8 Interior Comfort & Packaging
8.1 Infotainment & Connectivity
7.2 Fuel Efficiency
9.0 Safety
8.7 Value for Money
8.7 Fit for Purpose
Our ratings explained
Looking for a deal on this car?
1
43
nextprevious
2019 Kia Stinger GT-Line four-cylinder review


graphwfc package¶
Submodules¶
graphwfc.GraphWFCState module¶
-
class
graphwfc.GraphWFCState.
GraphWFCState
(GO, GI=None, GLs=None, pattern_count_per_GL=None, GI_isos_per_GL=None, GO_isos_per_GL=None, node_attr='color', edge_attr='type')¶ Bases:
object
includes everything needed to run GraphWaveFunctionCollapse
Variables: - GO – a copy of the input GO but with ‘invisible’ nodes removed.
After
run()
returned True it will be colored. - iteration_count – The amount of iterations that :py:meth:run did since the last :py:meth:reset
- invisible_nodes – The nodes omitted from GO since they are not targeted by any isomorphism
-
GO
¶
-
__init__
(GO, GI=None, GLs=None, pattern_count_per_GL=None, GI_isos_per_GL=None, GO_isos_per_GL=None, node_attr='color', edge_attr='type')¶ the constructor sets up the state after 0 iterations
This will create a GraphWFCState. Since we have to find isomorphisms this can take a while if a GL in GLs is ‘big’. If available GI_isos_per_GL, GO_isos_per_GL and pattern_count_per_GL can be set so they do need to be computed.
Parameters: - GO – the output graph to be colored
- GI – the colored graph used as the example input. Every node must be colored and None is not a accepted as color.
- GLs – the ordered (e.g. a list) graphs that describe the patterns (optional if pattern_count_per_GL, GI_isos_per_GL and GO_isos_per_GL are given)
- pattern_count_per_GL – (optional) a cached return value from helpers.get_patterns()
- GI_isos_per_GL – (optional) a cached return value from helpers.get_isos()
- GO_isos_per_GL – (optional) a cached return value from helpers.get_isos()
- node_attr – the name of the node attribute used as color
- edge_attr – the name of the edge attribute used to distinguish between edges
Raises: ValueError – if OG can’t be colored (if it doesn’t throw it still may be impossible)
-
invisible_nodes
¶
-
iteration_count
¶
-
reset
()¶ resets the object to the state after the construction
This is useful if run() runs into a contradiction (it returns false). Call this method and and run() can be called again. This is not called automatically so that information about the contradiction can be extracted
-
run
(iter: int = -1)¶ runs GraphWaveFunctionCollapse on the graphs
After initialising the GraphWFCState, we need to run the GraphWaveFunctionCollapse algorithm using this method. It will iterate until a contradiction is observed, colors were determined for all nodes or after the given amount of maximal iterations.
Parameters: iter – the maximum amount of GraphWaveFunctionCollapse-iterations. No limiting if negative Returns: True if GO has been completely colored, False if a contradiction occurred and nothing if the maximum amount of iterations was used up.
- GO – a copy of the input GO but with ‘invisible’ nodes removed.
After
graphwfc.helpers module¶
-
graphwfc.helpers.
get_isos
(GB: networkx.classes.digraph.DiGraph, GLs, edge_attr='type')¶ returns the isomorphisms from every GL in GLs to a node induced subgraph of G as a ordered list of nodes
This function is used to get the needed isos. Usually called with GI or GO as G. While this is called by the GraphWFCState constructor it might be useful to call it yourself and cache the results if some graphs are used multiple times.
Parameters: - GB – the ‘big’ Graph, GI or GO
- GLs – the ‘small’ graphs GL in an order (e.g. in a list)
- edge_attr – the attribute used to decide whether two edges should be considered to be of the same type
Returns: the isos in G per LG
-
graphwfc.helpers.
get_patterns
(GI: networkx.classes.digraph.DiGraph, GLs=None, GI_isos_per_GL=None, node_attr='color', edge_attr='type')¶ extracts the patterns from GI for each GL and counts them
This is called by the GraphWFCState constructor. If neither GI nor GLs differ for two GraphWFCStates, this can be used to cache the patterns. Its return value can be used as the pattern_count_per_GL parameter.Parameters: - GI – the input Graph to extract the patterns from
- GLs – the (ordered) GLs to define the ‘shape’ of the patterns
- GI_isos_per_GL – the cached isos from e.g. get_isos(GI, GL, edge_attr=edge_attr). Alternative for the GLs parameter
- node_attr – the node attribute to be used in GraphWFC
- edge_attr – the attribute used to decide whether two edges should be considered to be of the same type
Returns: the patterns found in GI per LG and how often they were found
Module contents¶
A python implementation of GraphWaveFunctionCollapse
This algorithm is based on WaveFunctionCollapse. It colors an output graph GO such that all patterns used are from the example input graph GI. A pattern is a colored subgraph which shape is determined by a small graph GL. Some usage examples can be found on the GitHub page. We use ‘iso’ in the API as a short form of ‘subgraph isomorphism’.
Example code:
>>> import networkx as nx
>>> import graphwfc
>>> GI = nx.Graph([(1,2),(2,3),(3,4)]).to_directed()
>>> GI.add_nodes_from([(1,{'c':1}),(2,{'c':1}),(3,{'c':2}),(4,{'c':3})])
>>> GL = nx.Graph([(1,2)]).to_directed()
>>> GO = nx.random_tree(1000).to_directed()
>>> S = graphwfc.GraphWFCState(GO=GO,GLs=[GL],GI=GI,node_attr='c')
>>> while not S.run():
... S.reset()
...
>>> nx.write_graphml(S.GO, "out.graphml")
GI is the graph 1 – 1 – 2 – 3 and GL is a – b where a and b have no color. We extract the patterns 1 – 1, 1 – 2 and 2 – 3. GO will only contain the extracted patterns. As such the out.graphml will contain a tree with 1000 nodes colored in a way such that no node with color 2 has a neighbour colored 2 and no node colored 3 has a neighbour with color 3 or 1. The color will be stored in the node attribute ‘c’.


declaration of Robotsimulator class
More...
#include <Robotsimulator.hpp>
|
| static int | drawOuterCircle (int centerx, int centery, int r) |
| | method to draw outer circle of joint More...
|
| |
| static int | drawInnerCircle (int centerx, int centery, int r) |
| | method to draw inner circle of joint More...
|
| |
| static int | drawJoint (int centerx, int centery) |
| | method to draw the joint using outercircle and innercircle methods More...
|
| |
| static int | drawLinkBtnJoints (float cx1, float cy1, float cx2, float cy2) |
| | method to draw link between joints More...
|
| |
|
static int | drawEndEffector (float centerx, float centery) |
| |
| static void | displayArm (void) |
| | method to display robot arm More...
|
| |
| static void | reshape (int w, int h) |
| | method to reshape the arm More...
|
| |
| static void | display (void) |
| | method to display all components for simulation More...
|
| |
| static int | drawPathCircle (void) |
| | method to draw Circular path taken by robot More...
|
| |
| static int | drawTarget (float x, float y) |
| | method to draw Target point More...
|
| |
| static void | runSimulation (int argc, char *argv[]) |
| | method to display all components for simulation More...
|
| |
declaration of Robotsimulator class
| void Robotsimulator::display |
( |
void |
| ) |
|
|
static |
method to display all components for simulation
- Parameters
-
- Returns
- void - displays components
Method to set white background
display string
| void Robotsimulator::displayArm |
( |
void |
| ) |
|
|
static |
method to display robot arm
- Parameters
-
- Returns
- void
update robots endEffector coordinates
| int Robotsimulator::drawInnerCircle |
( |
int |
centerx, |
|
|
int |
centery, |
|
|
int |
r |
|
) |
| |
|
static |
method to draw inner circle of joint
- Parameters
-
| centerx | - x Coordinate of Joint |
| centery | - y Coordinate of Joint |
- Returns
- int - for testing purposes
black foreground
| int Robotsimulator::drawJoint |
( |
int |
centerx, |
|
|
int |
centery |
|
) |
| |
|
static |
method to draw the joint using outercircle and innercircle methods
- Parameters
-
| centerx | - x Coordinate of Joint |
| centery | - y Coordinate of Joint |
- Returns
- returns 1 to indicate success
| int Robotsimulator::drawLinkBtnJoints |
( |
float |
cx1, |
|
|
float |
cy1, |
|
|
float |
cx2, |
|
|
float |
cy2 |
|
) |
| |
|
static |
method to draw link between joints
- Parameters
-
| cx1 | - X coordinate of Joint1 |
| cy1 | - Y coordinate of Joint1 |
| cx2 | - X coordinate of Joint2 |
| cy2 | - Y coordinate of joint2 |
- Returns
- int - returns 1 to indicate success
| int Robotsimulator::drawOuterCircle |
( |
int |
centerx, |
|
|
int |
centery, |
|
|
int |
r |
|
) |
| |
|
static |
method to draw outer circle of joint
- Parameters
-
| centerx | - x Coordinate of Joint |
| centery | - y Coordinate of Joint |
- Returns
- int - for testing purposes
black foreground
| int Robotsimulator::drawPathCircle |
( |
void |
| ) |
|
|
static |
method to draw Circular path taken by robot
- Returns
- returns 1 to indicate success
black foreground
| int Robotsimulator::drawTarget |
( |
float |
x, |
|
|
float |
y |
|
) |
| |
|
static |
method to draw Target point
- Parameters
-
| x | - X coordinate of target point |
| y | - Y coordinate of target point |
- Returns
- returns 1 to indicate success
| void Robotsimulator::reshape |
( |
int |
w, |
|
|
int |
h |
|
) |
| |
|
static |
method to reshape the arm
- Parameters
-
Axis of window x axis from -50 to 50 y axis from -50 to 50
| void Robotsimulator::runSimulation |
( |
int |
argc, |
|
|
char * |
argv[] |
|
) |
| |
|
static |
method to display all components for simulation
method to start simulation
- Parameters
-
- Returns
- void - displays components
- Parameters
-
| command | line arguments(Not used but needed for opengl library) |
- Returns
- void - displays arm
Robot functionalities to test
initialize window
callback functions calls the display function
calls the reshape function
calls timer function
Events are looped continuously
The documentation for this class was generated from the following files:


{{admin.first}}
{{admin.last}}
{{admin.email}}
Phone is required.
Phone is to short!
Phone is to long!
Old Password is required.
New Password is required.
Repeat Password is required.
New Passwords don't Match


Strong 7.4 Magnitude Earthquake Strikes off Indonesian Coast - USGS
A tsunami alert has been issued for the Indonesian coast after the powerful earthquake, the Indonesian Meteorology and Geophysics agency reported. There have been no immediate reports about casualties or damages caused by the quake.
A strong 7.4 magnitude earthquake struck 133 kilometres north-west of Kota Ternate, Indonesia, the US Geological Survey (USGS) reported.
According to the USGS, the quake occurred at a depth of 45 kilometres.
The European-Mediterranean Seismological Centre (EMSC) estimated the quake as being 7.1 in magnitude and occurring at a depth of 10 kilometres, 137 kilometres east of Bitung, Indonesia.
The Pacific Tsunami Warning Centre has issued a tsunami warning, saying that dangerous waves are possible along the coast at a distance of up to 185 miles.
After two hours, the Indonesian Meteorology and Geophysics Agency reported that it had lifted the tsunami alert.
In September, about 25,000 people were forced to flee their homes and seek shelter after a large 6.5 magnitude earthquake was detected eight kilometres (4.9 miles) to the southeast of the settlement of Kairatu.
Indonesia is part of the "Pacific Ring of Fire", a major area in the basin of the Pacific Ocean, which is a seismic zone, known for its powerful earthquakes.


Lava Cakes
Ingredients
- Baking spray, for spraying custard cups
- 1 stick butter
- 2 ounces bittersweet chocolate
- 2 ounces semisweet chocolate
- 1 1/4 cups powdered sugar
- 2 whole eggs
- 3 egg yolks
- 1 teaspoon vanilla
- 1/2 cup all-purpose flour
- Vanilla ice cream, for serving
Instructions
Preheat the oven to 425 degrees F. Spray four custard cups with baking spray and place on a baking sheet.
Microwave the butter, bittersweet chocolate and semisweet chocolate in a large bowl on high until the butter is melted, about 1 minute. Whisk until the chocolate is also melted. Stir in the sugar until well blended. Whisk in the eggs and egg yolks, then add the vanilla. Stir in the flour. Divide the mixture among the custard cups.
Bake until the sides are firm and the centers are soft, about 13 minutes. Let stand 1 minute. Invert on individual plates while warm and serve with vanilla ice cream.


Granted, this was a medical experience, but I think it still serves well to highlight a possible side effect.
When my doctor first put me on Zoloft, he started me on 50 mg per day. It seemed to work a bit for my depression but there was still room for improvement so he upped my dose to 100 mg. My first day on 100 mg was fine, but by early evening the second day, I started feeling as if I was coming down with the flu. After spending a few hours on the couch under three blankets trying to keep warm, I finally built up the energy and concern to finally find my thermometer. It turns out that my temperature was 102.6. A couple acetaminophens brought my fever down but I still felt awful so for the next few days I cut my pills in half to go back to 50 mg.
Once I felt like chancing things again, I went back to the full 100 mg dose. Again my temperature started to rise so I took two acetaminophen again and started feeling better. After a few days at 100 mg, my body adjusted to the Zoloft and I didn’t have any more problems with fever or body aches. However, I was still faced with side effects that reminded me of 3 or 4 Ritalin, caffeine pills, or ephedrine. I was jittery, talking much more than normal, my hands where shaking, and I had real problems getting to sleep at night.
Needless to say, I am now in the process of getting off the Zoloft; though, I am soon to start on Paxil which, from what I’ve read here at Erowid, I am not totally looking forward to. I just hope that I won’t have the experiences that others have had and, at the very least, once I’m off the Zoloft, I should be able to get a full night’s sleep again.
I wouldn’t call my Zoloft experience a total waste. My depression was lessened, if not removed, by this SSRI and for that I was glad. The side effects, for me, just aren’t worth it. When coupled with the euphoria and beautiful conversations of Meth or the productivity of Ritalin (no, I am not ADD, but I can still write like mad on Ritalin,) those same side effects are tolerable; but knowing that I have other antidepressant options makes Zoloft simply not worth it in order to just feel “normal.”
I guess the lesson here is that just because you get it from a doctor that doesn’t mean it’s safe. Moreover, serotonin is nothing to mess around with. Honestly, I think that I feel safer with something like DXM or MDMA. I’m not saying that you can always (or, really, ever) trust “street” drugs like MDMA, but at least they’ve been around and used for a good number of years and so there is some information on their effects, both short- and long-term.
Most SSRIs, on the other hand, are pretty new and not really that well understood. Not that I’m suggesting that DXM or MDMA sure be used to treat depression or anything else; self medicating just ain’t worth the risks (trust me there).
However, we should all remember that Dr. Freud prescribed cocaine for pretty much everything and that, in the 1950s, the psychiatric community wrote the same things about LSD that they later wrote about Prozac in the 1990s. I will honestly be surprised if 20 years from now today’s SSRIs are still being used. After all, you only get one brain in this life and as a PhD/MD Neuroscience professor once told me, “For all intents and purposes, we really don’t know anything at all about how the chemicals in the brain work.”
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.


Jake Bright
by @JakeRBrightLatest @TechCrunch: Samasource raises $14.8M Series A for its global AI data biz driven from Africa. Expands in Uganda & Canada; plans to increase staff in Kampala by 150%
techcrunch.com/2019/11/20/sam…
Latest @TechCrunch: Samasource raises $14.8M Series A for its global AI data biz driven from Africa. Expands in Uganda & Canada; plans to increase staff in Kampala by 150%
techcrunch.com/2019/11/20/sam…


It is surprisingly hard to figure out how to talk to a Kubernetes cluster. Not only do clients need to know where to look on the network, they also need to identify the set of root certificates to trust when talking to that endpoint.
This presents a set of problems:
* It should be super easy for users to configure client systems with a minimum of effort kubectl
or kubeadm init
(or other client systems).
* Establishing this should be doable even in the face of nodes and master components booting out of order.
* We should have mechanisms that don’t require users to ever have to manually manage certificate files.
* Over the life of the cluster this information could change and client systems should be able to adapt.
While this design is mainly being created to help kubeadm
possible, these problems aren’t isolated there and can be used outside of the kubeadm context.
Mature organizations should be able to distribute and manage root certificates out of band of Kubernetes installations. In that case, clients will defer to corporation wide system installed root certificates or root certificates distributed through other means. However, for smaller and more casual users distributing or obtaining certificates represents a challenge.
Similarly, mature organizations will be able to rely on a centrally managed DNS system to distribute the location of a set of API servers and keep those names up to date over time. Those DNS servers will be managed for high availability.
With that in mind, the proposals here will devolve into simply using DNS names that are validated with system installed root certificates.
First we define a set of information that identifies a cluster and how to talk to it. We will call this ClusterInfo in this document.
While we could define a new format for communicating the set of information needed here, we’ll start by using the standard kubeconfig
file format.
It is expected that the kubeconfig
file will have a single unnamed Cluster
entry. Other information (especially authentication secrets) MUST be omitted.
In the future we look forward to enhancing kubeconfig
to address some issues. These are out of scope for this design. Some of this is covered in #30395.
Additions include:
This is to be implemented in a later phase
Any client of the cluster will want to have this information. As the configuration of the cluster changes we need the client to keep this information up to date. The ClusterInfo ConfigMap (defined below) is expected to be a common place to get the latest ClusterInfo for any cluster. Clients should periodically grab this and cache it. It is assumed that the information here won’t drift so fast that clients won’t be able to find some way to connect.
In exceptional circumstances it is possible that this information may be out of date and a client would be unable to connect to a cluster. Consider the case where a user has kubectl set up and working well and then doesn’t run kubectl for quite a while. It is possible that over this time (a) the set of servers will have migrated so that all endpoints are now invalid or (b) the root certificates will have rotated so that the user can no longer trust any endpoint.
Now that we know what we want to get to the client, the question is how. We want to do this in as secure a way possible (as there are cryptographic keys involved) without requiring a lot of overhead in terms of information that needs to be copied around.
The simplest way to obtain ClusterInfo this would be to simply put this object in a file and copy it around. This is more overhead for the user, but it is easy to implement and lets users rely on existing systems to distribute configuration.
For the kubeadm
flow, the command line might look like:
kubeadm join --discovery-file=my-cluster.yaml
After loading the ClusterInfo from a file, the client MAY look for updated information from the server by reading the kube-public/cluster-info
ConfigMap defined below. However, when retrieving this ConfigMap the client MUST validate the certificate chain when talking to the API server.
Note: TLS bootstrap (which establishes a way for a client to authenticate itself to the server) is a separate issue and has its own set of methods. This command line may have a TLS bootstrap token (or config file) on the command line also. For this reason, even thought the --discovery-file
argument is in the form of a kubeconfig
, it MUST NOT contain client credentials as defined above.
If the ClusterInfo information is hosted in a trusted place via HTTPS you can just request it that way. This will use the root certificates that are installed on the system. It may or may not be appropriate based on the user’s constraints. This method MUST use HTTPS. Also, even though the payload for this URL is the kubeconfig
format, it MUST NOT contain client credentials.
kubeadm join --discovery-file="https://example/mycluster.yaml"
This is really a shorthand for someone doing something like (assuming we support stdin with -
):
curl https://example.com/mycluster.yaml | kubeadm join --discovery-file=-
After loading the ClusterInfo from a URL, the client MAY look for updated information from the server by reading the kube-public/cluster-info
ConfigMap defined below. However, when retrieving this ConfigMap the client MUST validate the certificate chain when talking to the API server.
Note: support for loading from stdin for --discovery-file
may not be implemented immediately.
There won’t always be a trusted external endpoint to talk to and transmitting the locator file out of band is a pain. However, we want something more secure than just hitting HTTP and trusting whatever we get back. In this case, we assume we have the following:
An interesting aspect here is that this information is often easily obtained before the API server is configured or started. This makes some cluster bring-up scenarios much easier.
The user experience for joining a cluster would be something like:
kubeadm join --token=ae23dc.faddc87f5a5ab458 <address>:<port>
Note: This is logically a different use of the token used for authentication for TLS bootstrap. We harmonize these usages and allow the same token to play double duty.
kubeadm
will implement the following flow:
kubeadm
connects to the API server address specified over TLS. As we don’t yet have a root certificate to trust, this is an insecure connection and the server certificate is not validated. kubeadm
provides no authentication credentials at all.
kubeadm
requests a ConfigMap containing the kubeconfig file defined above.
https://<server>/api/v1/namespaces/kube-public/configmaps/cluster-info
kubeadm
finds the correct signature based on the token-id
part of the token. (Described below).kubeadm
verifies the JWS and can now trust the server. Further communication is simpler as the CA certificate in the kubeconfig file can be trusted.To first make this work, we put some structure into the token. It has both a token identifier and the token value, separated by a dot. Example:
ae23dc.faddc87f5a5ab458
The first part of the token is the token-id
. The second part is the token-secret
. By having a token identifier, we make it easier to specify which token you are talking about without sending the token itself in the clear.
This new type of token is different from the current CSV token authenticator that is currently part of Kubernetes. The CSV token authenticator requires an update on disk and a restart of the API server to update/delete tokens. As we prove out this token mechanism we may wish to deprecate and eventually remove that mechanism.
The token-id
must be 6 characters and the token-secret
must be 16 characters. They must be lower case ASCII letters and numbers. Specifically it must match the regular expression: [a-z0-9]{6}\.[a-z0-9]{16}
. There is no strong reasoning behind this beyond the history of how this has been implemented in alpha versions.
Bootstrap tokens are stored and managed via Kubernetes secrets in the kube-system
namespace. They have the type bootstrap.kubernetes.io/token
.
The following keys are on the secret data:
* token-id. As defined above.
* token-secret. As defined above.
* expiration. After this time the token should be automatically deleted. This is encoded as an absolute UTC time using RFC3339.
* usage-bootstrap-signing. Set to true
to indicate this token should be used for signing bootstrap configs. If this is missing from the token secret or set to any other value, the usage is not allowed.
* usage-bootstrap-authentication. Set to true to indicate that this token should be used for authenticating to the API server. If this is missing from the token secret or set to any other value, the usage is not allowed. The bootstrap token authenticator will use this token to auth as a user that is system:bootstrap:<token-id>
in the group system:bootstrappers
.
* description. An optional free form description field for denoting the purpose of the token. If users have especially complex token management neads, they are encouraged to use labels and annotations instead of packing machined readable data in to this field.
* auth-groups. A comma-separated list of which groups the token should be authenticated as. All groups must have the system:bootstrappers:
prefix.
These secrets MUST be named bootstrap-token-<token-id>
. If a token doesn’t adhere to this naming scheme it MUST be ignored. The secret MUST also be ignored if the token-id
key in the secret doesn’t match the name of the secret.
JSON Web Signatures are a way to sign, serialize and verify a payload. It supports both symmetric keys (aka shared secrets) along with asymmetric keys (aka public key infrastructure or key pairs). The JWS is split in to 3 parts: 1. a header about how it is signed 2. the clear text payload 3. the signature.
There are a couple of different ways of encoding this data – either as a JSON object or as a set of BASE64URL strings for including in headers or URL parameters. In this case, we are using a shared secret and the HMAC-SHA256 signing algorithm and encoding it as a JSON object. The popular JWT (JSON Web Tokens) specification is a type of JWS.
The JWS specification describes how to encode “detached content”. In this way the signature is calculated as normal but the content isn’t included in the signature.
kube-public
namespaceKubernetes ConfigMaps are per-namespace and are generally only visible to principals that have read access on that namespace. To create a config map that everyone can see, we introduce a new kube-public
namespace. This namespace, by convention, is readable by all users (including those not authenticated). Note that is a convention
(to expose everything in kube-public
), not something that’s done by default in Kubernetes. kubeadm
does solely expose the cluster-info
ConfigMap, not anything else.
In the initial implementation the kube-public
namespace (and the cluster-info
config map) will be created by kubeadm
. That means that these won’t exist for clusters that aren’t bootstrapped with kubeadm
. As we have need for this configmap in other contexts (self describing HA clusters?) we’ll make this be more generally available.
cluster-info
ConfigMapA new well known ConfigMap will be created in the kube-public
namespace called cluster-info
.
Users configuring the cluster (and eventually the cluster itself) will update the kubeconfig
key here with the limited kubeconfig
above.
A new controller (bootstrapsigner
) is introduced that will watch for both new/modified bootstrap tokens and changes to the cluster-info
ConfigMap. As things change it will generate new JWS signatures. These will be saved under ConfigMap keys of the pattern jws-kubeconfig-<token-id>
.
Another controller (tokencleaner
) is introduced that deletes tokens that are past their expiration time.
Logically these controllers could run as a separate component in the control plane. But, for the sake of efficiency, they are bundled as part of the Kubernetes controller-manager.
kubeadm
UXWe extend kubeadm with a set of flags and helper commands for managing and using these tokens.
kubeadm init
flags--token
If set, this injects the bootstrap token to use when initializing the cluster. If this is unset, then a random token is created and shown to the user. If set explicitly to the empty string then no token is generated or created. This token is used for both discovery and TLS bootstrap by having usage-bootstrap-signing
and usage-bootstrap-authentication
set on the token secret.--token-ttl
If set, this sets the TTL for the lifetime of this token. Defaults to 0 which means “forever” in v1.6 and v1.7. Defaults to 24h
in v1.8kubeadm join
flags--token
This sets the token for both discovery and bootstrap auth.--discovery-file
If set, this will load the cluster-info from a file on disk or from a HTTPS URL (the HTTPS requirement due to the sensitive nature of the data)--discovery-token
If set, (or set via --token
) then we will be using the token scheme described above.--tls-bootstrap-token
(not officially part of this spec) This sets the token used to temporarily authenticate to the API server in order to submit a CSR for signing. If the system:csr-approver:approve-node-client-csr
ClusterRole is bound to the group the Bootstrap Token authenticates to, the CSR will be approved automatically (by the csrapprover
controller) for a hands off joining flow.Only one of --discovery-file
or --discovery-token
can be set. If more than one is set then an error is surfaced and kubeadm join
exits. Setting --token
counts as setting --discovery-token
.
kubeadm token
commandskubeadm
provides a set of utilities for manipulating token secrets in a running server.
kubeadm token create [token]
Creates a token server side. With no options this’ll create a token that is used for discovery and TLS bootstrap.
[token]
The actual token value (in id.secret
form) to write in. If unset, a random value is generated.--usages
A list of usages. Defaults to signing,authentication
.signing
usage is specified, the token will be used (by the BootstrapSigner controller in the KCM) to JWS-sign the ConfigMap and can then be used for discovery.authentication
usage is specified, the token can be used to authenticate for TLS bootstrap.--ttl
The TTL for this token. This sets the expiration of the token as a duration from the current time. This is converted into an absolute UTC time as it is written into the token secret.--description
Sets the free form description field for the token.kubeadm token delete <token-id>|<token-id>.<token-secret>
kubeadm token list
token-id.token-secret
, the TTL, the absolute expiration time, the usages, and the description.--json
or -o json
way to make this info programmatic? We don’t want to recreate kubectl
here and these aren’t plain API objects so we can’t reuse that plumbing easily.kubeadm token generate
This currently exists but is documented here for completeness. This pure client side method just generated a random token in the correct form.Our documentations (and output from kubeadm
) should stress to users that when the token is configured for authentication and used for TLS bootstrap is a pretty powerful credential due to that any person with access to it can claim to be a node.
The highest risk regarding being able to claim a credential in the system:nodes
group is that it can read all Secrets in the cluster, which may compromise the cluster.
The Node Authorizer locks this down a bit, but an untrusted person could still try to
guess a node’s name, get such a credential, guess the name of the Secret and be able to get that.
Users should set a TTL on the token to limit the above mentioned risk. kubeadm
sets a 24h TTL on the node bootstrap token by default in v1.8.
Or, after the cluster is up and running, users should delete the token using kubeadm token delete
.
After some back and forth, we decided to keep the separator in the token between the ID and Secret be a .
. During the 1.6 cycle, at one point :
was implemented but then reverted.
See kubernetes/client-go#114 for details on creating a shared package with common constants for this scheme.
This proposal assumes RBAC to lock things down in a couple of ways. First, it will open up cluster-info
ConfigMap in kube-public
so that it is readable by unauthenticated users (user system:anonymous
). Next, it will make it so that the identities in the system:bootstrappers
group can only be used with the certs API to submit CSRs. After a TLS certificate is created, the groupapprover controller will approve the CSR and the CSR identity can be used instead of the bootstrap token.
The end goal is to make it possible to delegate the client TLS Bootstrapping part to the kubelet, so kubeadm join
’s function will solely be to verify the validity of the token and fetch the CA bundle.
The binding of the system:bootstrappers
(or similar) group to the ability to submit CSRs is not part of the default RBAC configuration. Consumers of this feature like kubeadm
will have to explicitly create this binding.


In order to style your own components with Angular Material's tooling, the component's styles must be defined with Sass.
First, create a Sass mixin that accepts an Angular Material color configuration and outputs the color-specific styles for the component. A color configuration is a Sass map.
For example, if building a custom carousel component:
// Import library functions for theme creation.
@import '~@angular/material/theming';
@mixin candy-carousel-color($config-or-theme) {
// Extract the color configuration in case a theme has been passed.
// This allows consumers to either pass a theme object or a color configuration.
$config: mat-get-color-config($config-or-theme);
// Extract the palettes you need from the theme definition.
$primary: map-get($config, primary);
$accent: map-get($config, accent);
// Define any styles affected by the theme.
.candy-carousel {
// Use mat-color to extract individual colors from a palette.
background-color: mat-color($primary);
border-color: mat-color($accent, A400);
}
}
Second, create another Sass mixin that accepts an Angular Material typography configuration and outputs typographic styles. For example:
@mixin candy-carousel-typography($config-or-theme) {
// Extract the typography configuration in case a theme has been passed.
$config: mat-get-typography-config($config-or-theme);
.candy-carousel {
font: {
family: mat-font-family($config, body-1);
size: mat-font-size($config, body-1);
weight: mat-font-weight($config, body-1);
}
}
}
Finally, create a mixin that accepts an Angular Material theme, and delegates to the individual
theming system mixins based on the configurations. A theme consists of configurations for
individual theming systems (color
and typography
).
@mixin candy-carousel-theme($theme) {
// Extracts the color and typography configurations from the theme.
$color: mat-get-color-config($theme);
$typography: mat-get-typography-config($theme);
// Do not generate styles if configurations for individual theming
// systems have been explicitly set to `null`.
@if $color != null {
@include candy-carousel-color($color);
}
@if $typography != null {
@include candy-carousel-typography($typography);
}
}
See the typography guide for more information on typographic customization.
Define all styles unaffected by the theme in a separate file referenced directly in the component's
styleUrl
. This generally includes everything except for color and typography styles.
Use the Sass @include
keyword to include a component's theme mixin wherever you're already
including Angular Material's built-in theme mixins.
// Import library functions for theme creation.
@import '~@angular/material/theming';
// Include non-theme styles for core.
@include mat-core();
// Define your application's custom theme.
$primary: mat-palette($mat-indigo);
$accent: mat-palette($mat-pink, A200, A100, A400);
$theme: mat-light-theme((
color: (
primary: $primary,
accent: $accent,
)
));
// Include theme styles for Angular Material components.
@include angular-material-theme($theme);
// Include theme styles for your custom components.
@include candy-carousel-theme($theme);
mat-color
function to extract colors from a palette
You can consume the theming functions and Material Design color palettes from
@angular/material/theming
. The mat-color
Sass function extracts a specific color from a palette.
For example:
// Import theming functions
@import '~@angular/material/theming';
.candy-carousel {
// Get the default hue for a palette.
color: mat-color($primary);
// Get a specific hue for a palette.
// See https://material.io/archive/guidelines/style/color.html#color-color-palette for hues.
background-color: mat-color($accent, 300);
// Get a relative color for a hue ('lighter' or 'darker')
outline-color: mat-color($accent, lighter);
// Get a contrast color for a hue by adding `-contrast` to any other key.
border-color: mat-color($primary, '100-contrast');
}


|
| Comment
on Jon-Christian Suggs' article: Adam's Rib & A Time to
Kill |
From: John Denvir
I very much enjoyed Suggs' comparison of Adam's Rib with
A Time to Kill but would like to set out another way to
look at Hepburn's performance in Adam's Rib. I think we
can see Hepburn as portraying the lawyer as "trickster."
"Trickster" figures in mythology as folks like Hermes
and Mercuy or the Coyote or Raven in Native American folklore.
Lewis Hyde tells us in "The Trickster Makes this World"
that tricksters are people who intervene when conventional society
comes to gridlock; their intervention is to break up the ossified
status quo to allow a "new world" to emerge, and their
tactics tend to be amoralor at least not bounded by conventional
morality.
Isn't that just what Hepburn does. She finds a very solemn legal
system quite self-satisfied with itself by unable to accept the
humanity of women and uses all sorts of "unprofessional"
tactics to humiliate the law (and her spouse) towards the end
of opening the system up to justice.
This might be a much better way for us to view lawyers (like
Johnny Cochran)--people who use unusual tactics to awaken us
to realities we would rather ignore.
| Comment
on James Elkins' article: Are Lawyer Films Anti-lawyer? |
From: Brock Malcolm
I agree that the lawyer films are not necessarily anti-lawyer.
Making a character a lawyer aids the story because it sends certain
signals to the audience, i.e. this character is intelligent,
this character has a lot of money (rarely is the lawyer who struggles
beneath his/her shingle portrayed), and this character holds
someone's life in his/her hands. Lawyers make for good drama
because, even though the bulk of the job (research, interviews,
drafting motions) is usually not portrayed, the law will always
be there to provide that climatic battle. Because a film is a
story, it must have a perspective. This in turn divides the law
into two sidesgood and evil (although I realize that I
am way over simplifying things, you can see my point). Films
take on that anti-lawyer feel because we leave the theater hating
one of the lawyers. As time goes by, we tend to hold on to those
feelings of hatred much longer than we do any feelings connected
with the triumph of good. But it is not the fault of the genre
that the evil lawyer stands out. All through literature (see
Paradise Lost), authors have fought with this problem: Evil is
just more interesting than Good.
| Comment
on John Denvir's article: The Last Wave |
From: Stan Ross, University of New South Wales School
of Law
I saw the Last Wave when it first came out. After reading
John Denvir's comments I was drawn to comment and also I will
see the film again. The conflict between Aboriginal law and Western
(Australian law) is frequently in the news. Recently an Aboriginal
elder assaulted a photographer who was taking photos against
his wishes on Aboriginal land. The photographer complained and
criminal assault charges were brought. The case was dismissed
by the Magistrate in the Northern Territory on the basis of Aboriginal
law. This has caused a political storm in the Territory with
the Chief Minister (head of that Government) stating the decision
is wrong and that it shows discrimination in favour of Aboriginals.
In Darwin a constitutional convention is atempting to establish
the Territory as a State. One of the issues that is causing problems
is that the whites are seeking to have a provision included that
will make sure Aboriginals are no different than anyone else.
There appears to be, at least among conservative politicians,
little unstanding of the complexity and relevance of Aboriginal
law.
A recent Australian novel, Al Turello's Wild Justice (Arrow
Press, 1995) involves some interesting legal probems concerning
the death by clubbing of an Aboriginal lawyer. It appears to
be a tribal killing, but there is much more involved. Aboriginal
custom has an important role in achieving a just solution to
various murders.
There is also a distinct possibility that the Australian government
is preparing to run an early election on the 'race issue'the
right of Aboriginals to have access to land held under long term
leases by graziers, farmers and mining companies. If the present
conservative government prevails the role of Aboriginal customary
law will be greatly diminished.
Postscript by Stan Ross on The Last Wave: added September 9,
1998
There have been further developments in the confrontation between
Aboriginal law and 'white man law'. On September 1, 1998 a senior
Aboriginal traditional owner of the Jabiluka uranium mine site
was found guilty of criminal trespass on her own land. Yvonne
Margarula had argued that she was exercising her rights as part
of Aboriginal tradition when she was demonstrating against mining
uranium on her land. The magistrate held that he was 'satisfied
beyond reasonable doubt that the use and occupation the accused
put the land was not in accordance with Aboriginal tradition....
Even if one could form the view that the very use and occupation
was in accordance with Aboriginal tradition, the magistrate was
satisfied those actions would still interfere with the use of
enjoyment of Energy Resources Australia's (the mining company)
interest in the land. Yvonne Margarula is now seeking legal advice
as to a possibly appealing the decision.
| Comment
on John Denvir's article: Chinatown |
From: Matt Zwolinski
I find it difficult to see why John Denvir takes Polanski's Chinatown
to be an indictment of capitalism. Throughout the film, it is
not the free market which subverts the public good; rather, it
is the manipulation of political institutions by persons like
Cross which leads to the exploitation of the many to serve the
interests of the few.
But this is something that advocates of laissez-faire have realized
for years. It has been expressed by persons like William Legget
who, in the Jacksonian era, couched plea for economic liberty
in very populist terms, and it is still being expressed by modern
libertarians, such as Murray Rothbard and others in the Austrian
school of economics. Indeed, much of the insights of public choice
theory are little more than elaborations on the way in which
the government power is manipulated by private interests.
Where those in the classical liberal tradition differ from those
such as Professor Denvir is not in their diagnosis of the problem,
then, but in their perscribed solution. While those in the welfare-statist
wing of the liberal tradition argue that such corruption is best
dealt with by political oversight, classical liberals have long
argued that the only way to limit the abuse of government is
to limit the scope of government. By barring the use of political
coercion as a legitimate means of economic advancement, we pave
the way for a truly "populist" system in which each
person is free to seek her own good in the free and voluntary
exchange of the market.
| Comment
on Rob Waring's article: The Sweet Hereafter |
From: Kevin Crisp
I'm just plain bothered by a film that:
1) portrays people as using the legal system as a salve for their
own spiritual yearnings (the film is about more than particular
loss, it is about the loss of meaning and significance that has
occurred in all areas of modern life),
2) suggests that it is our lack of community that ails us,
3) hints at the role that the modern consumer economy plays in
undermining our humanity (Lawyers comment to father about how
all our kids are dead wandering comatose through shopping malls)
and
4) then actually makes a great case for the pro-corporate mantra
that what we need is tort reform?
Political Message: If only people couldn't sue (corporations)
to ease their pain, they would be forced to turn back to one
another and re-build their communities. (Conservative version
of deTocqueville)
Why not? If only corporations and the growth of the modern industrial
economy hadn't elevated selfishness and the private family above
community, we would be able to both avoid the emptiness of modern
life AND the callousness of corporate cost-benefit analyses that
make litigation justifiable. (Liberal version of deTocqueville).
Besides that, I liked the film
very much.
| Comments
on John Denvir's article: Personal Politics |
From: Joel Gomberg
I really liked the movie Election and Denvir's review,
but I was especially fascinated by his view of "Mr. M"
as the only character with the capacity for change, growth, and
self-awareness. Is it possible, I wondered, whether, presumably
a "popular" professor, identified just a bit with Mr.
M?
While Denvir says that the other characters are not mere cartoons,
he implies that he agrees with Tracy's view [wasn't Reese Witherspoon
terrific?] that Mr. M should never have bothered to play around
with Destiny. The rest of them are doomed to repeat their neurotic
patterns, but somehow Mr. M is exempt? I certainly agree that
just about anything would be better than repeating the neurotic
pattern of "making love" to Mrs. M as she demandingly
cries out "fill me up! fill me up!", but I'm not as
sanguine as Denvir that he might have really learned something
from his experiences. To me, Tammy is the one who managed to
manipulate the situation for her own benefit. She got to go where
the girls are. Why are is Denvir so sure that she won't find
her true soulmate?
And I don't necessarily agree that "dumb as a stick"
Paul was too nice to be successful in politics. Certainly, the
Nixon type can't afford to be nice, but how about Reagan? He
was Mr. Affable, letting his henchman do the nasty stuff. If
you're dumb enough, you can be oblivious to what your underlings
are doing in your name.
These disagreements aside, it's clear that Denvir is one of the
most insightful critics of his generation.
| Comment
on Robert Waring's article: Swimming With The Bottom Feeders |
From: Bill Rubens -
All Of Me
As an interesting comparison to Liar Liar, how about All
Of Me (1984) with Steve Martin? Besides
Liar Liar, AOM is the only magical-intervention-causes-usually-lying-lawyer-to-tell-the-truth
movie I know of.
Premise: Rich Lily Tomlin wants to have her soul placed into
young woman's body when she (Tomlin) dies but the soul is put
into Steve Martin's body by mistake. Martin is introduced as
a PI specialist who will bend the truth to get a favorable settlement
for clients. One of the high points in AOM is a courtroom
scene: wife seeking large amount in divorce settlement from husband,
whose extramarital affairs figure importantly into the alimony
settlement. Steve Martin's character, exhausted from all the
preparation he's been doing on the case, falls asleep and the
"other half" of his body (Lily Tomlin's character)
takes over and tells the truth to the court. (the husband in
the divorce case was Tomlin's own lawyer when he was alive so
she knows him quite well). It's a great scene---- Martin playing
Tomlin inside his own body. Inspiration/borrowing for Liar
Liar? Not sure, but I can't watch one without thinking of
the other.
Trivia: Jason Bernard, who played the judge in LL, was
Steve Martin's best friend in AOM!
Bill Rubens, Taiwan
| Comment
on John Denvir's article: Red Corner |
From: Arlyn Gonzalez-Diaz, Law Student
Last summer I studied at China with a Duquesne Univ. Program
abroad. I'm a law student at P.R. (both civil and common law
traditions) I went to a criminal case trial. The atmosphere was
just the same I saw at Red Corner. No jury, no visitors,
just us with special permission. The trial was really fast, I
mean 2-3 hours. Three judges, two prosecutors and a legal representant
provided by the PRC which probably was not even a lawyer (some
judges even now with the new lawyers' law have never been at
college or studied law). This woman was old and did not say a
word through the process. The poor man was incarcerated. The
conviction...7 years for stealing a bicycle and a cellular phone.(The
translator told us that the real conviction should have been
10 years but they gave him 7 because he had some Americans watching.
Anyway I'm doing research for a paper I'm writing here on the
accuracy of the movie and the law in China. I'll let you now
the details when I'm done. Thanks for your page, Arlyn
| Comment
on Michael Asimow's article: Dangerous Beauty, The Trial
Of A Courtesan |
From James Frieden
Dear Mr. Asimow, It was a pleasure to speak with you last night
at the CLE meeting. I have looked at your site and it is great.
Your article on Dangerous Beauty is excellent. I definitely
would like to link from teachwithmovies.org to articles on your
site. Even if we don't recommend the film as suitable for parents
or teachers to show to children because of violence or sex or
historical inaccuracy, we like to provide information on the
films. Your article on Dangerous Beauty is perfect. I
don't think people need permission to link to other sites, but
if you have a problem with it, please e-mail me. We are always
trying to generate more traffic and would be pleased for you
to place any of our Learning Guides on your site or to link to
them. I am thinking particularly of the Learning Guides to Inherit
the Wind and Judgment at Nuremberg both of which have
a lot of substance to them. Sincerely yours, James Frieden
Teachwithmovies.org
| Comment
on Dr. Paul Mason's article: Men, Machines And The Mincer: The
Prison Movie |
From: Mike Newman
"This article was fantastic. Thanks Paul for writing one
of the rare pieces on prison films. Your work has proved invaluable
for the assignment I am doing for you."
| Comments
on Chris Jackson's article: Judging Judging Amy |
From: D. Hutch
I thought this article was a thoughtful and insightful. The author
Chris Jackson obviously knows what she is writing about! It was
witty and creative. I loved it!!" From:
BJC
"Dr. Jackson appears to have a good handle on Maxine and
her clan". It is difficult for me, a female person of the
older generation, to allow Amy to be the star of this program
when Maxine (Tyne Daly) has finally become the most wise leader
we always knew she could be. Dr. J. has given good comparisons
between Practice, Law & Order,&Povidence. Judging
Amy could be changed to "Guiding Amy" with no problem.
BJC From: Tammy found us through: Search
Engine.
Amy Grant is a "Christian" Pop Music artist ....Amy
"Grey" is the character you speak of in this article...
| Comments
on the articles: Legally Blonde roundtable |
From: Robert Chaires found us through: World of mouth.
I really liked the movie. So did my wife who is also a lawyer/professor.
We viewed it as a meaningful comment on how undergraduates tend
to judge people by their major-and for a 'teaching moment' that
that people come to the law in strange ways and for strange reasons. From:
Karen Greenbaum-Maya found us through: World of mouth.
Paul, nice job here. I would add only a few things: 1. It was
Cyndi Lauper, not the immaterial girl, who did the Girls Just
Wanna Have Fun number. Persnickety, eh? 2. As pernicious as the
notion that being smart gets you farther than learning something
is the film's characterization of "high-brow" people
as discriminatory snobs. My experience is that intelligent people
who have actually studied something are a good deal more open
to a variety of folk than the socially adept members of the popular
crowd, who were deeply exclusionary. Bullies, anyone? Now they
blame their limited adult success on the people they picked on
in the first place-sweet.
Paul Joseph's response: "Thanks for the comment,
Karen. We have fixed the error!" From:
Judith Grant found us through: E-Mail list.
Film's inspiring message: Despite the handicap of being blond,
beautiful, and rich, you can still make it America. You've come
a long way, baby! From: Sharon found us
through: Random surfing.
As a previous blonde law student often compared to Marilyn Monroe,
I was prepared to point out the inaccuracies of your review of
Legally Blonde. A fellow writer at Picturing Justice - John Owens
- does an ample job of explaining that this movie is based on
reality.
See: /pj/blonde_owens.htm
The 179 LSAT score and representing a criminal defendant in court
may not be realistic...but it allowed a plot and a lot of humor.
This is a comedy after all...things are exaggerated. My Civil
Procedure teacher looked and acted exactly like the one in the
movie-even though I never saw her hit anyone on the head with
a pencil. (Probably only because she was afraid of a battery
charge). The essence of law school - the competition, the holier-than-thou
attitude, the feigned serious personalities, the belittling professors,
etc...ALL REAL.
Most importantly, what someone that looks like "Barbie"
but has an IQ of 160 goes through is real. The challenges from
their inner self and others is real.
When Callahan hit on Elle in the movie, I bawled. I lived those
moments of self-doubt when accomplishments were invalidated by
males. Reality is that if you are a woman with a certain look,
especially blonde, no matter what your grades, intelligence,
or accomplishments, people will attribute your success to being
wanted (or sleeping) with a man.
I get a double whammy - blonde jokes and lawyer jokes. The movie
was a refreshing reminder to me that I'm not the only person
who goes through what Elle did.  Law students need all the laughs they have
time for. Your female students could benefit from this movie
and in particular, your blonde students. From:
Meredith Lobel-Angel found us through: Link from other site.
"LOVE IT!". I, too, went to Stanford Law and Amanda's
book is virtually my right of passage "Catcher in the Rye."
I am brunette and no sorority queen - but anyone who feels "different"
can relate. My daughter and I do the "Bend and Snap"
and re-enact the orientation where Elle meets her classmates
for the first time. From: Julia Baugher
found us through: Search Engine.
I am a senior at Georgetown University, currently studying for
my Constitutional Law midterm (tomorrow). In desperate need of
a study break, I thought it would be amusing to type in "The
Law is reason free from passion" - a quote from Aristotle,
but more importantly, from my favorite movie, Legally Blonde.
I must politely disagree with the author's conclusion - that
she is not "hip" to popular culture. Had I been in
her first year torts class, I would have been rolling on the
ground with laughter and relief, knowing that one of my professor's
has at least a decent sense of humor. I saw Legally Blonde for
the first time with a 2nd year Catholic U. law student. Then
I saw it with my father, a lawyer. I have since seen it with
many aspiring law students and I must say, I have no idea who
the young people were in your class, but they must lead awfully
boring lives. I hope you get an Elle Woods in your class one
day - near-perfect LSAT score and all.
| Comment
on the articles: The Man Who Wasn't There roundtable |
From: Alyson Dion found us through: Search Engine.
I had the opportunity to view the film yesterday. After reading
both movies reviews on this site, it seems to me that both authors
acknowledge the presence of the stereotypical defense attorney
(the best that money can buy), but neither address the probate
and real estate attorney who is a blatant alcoholic. His life
is pathetic: he barely pays attention to his talented daughter,
tells his friend Crane not to have faith in the government system
(public defender), and believes that you "pay lawyers to
mess things up and then pay them to un-mess things up."
His character, his behaviors, and his beliefs about a failing
justice system, where only money and lies can set you free, all
contribute to society's increasing disbelief in our judicial
system and
attorneys. I fully understand that this was a satirical, noir
film and that one should not take all the characters seriously.
However, how many people, including those who find company with
Jerry Springer, will realize that this film attempts to portray
lawyers with a sense of humor, instead of a sense of truth? After
viewing the O.J. Simpson trial (and not through personal experience),
much of society may unfortunately relate to the theory that money
is the key to success in the courtroom and that lawyers are shysters
that are paid to "mess and un-mess" things.
| Comment
on the articles: Erin Brokovich |
From: Leslie
It's too bad that you raise a question without attempting to
provide the answer, which is relatively simple. Settlement proceeds
are to be placed in an attorney's client trust account and disbursed
from there. Any interest made on the funds are required to be
paid at the end of the year to the State Bar Association. These
client trust accounts are very closely monitored and misuse of
funds or settlement proceeds can be a basis for sanction, discipline
or even disbarment.
| Comment
on Chris Jackson's article: Picturing the President-West Wing |
From: Amanda found us through: Link
from other site, Random surfing.
Excellent article-I liked the way the other movies were brought
up as a tie-in from big screen to small screen, then from real-life
news to the Bartlet White House. I found one mistake-"President
Bartlet doesn't hold grudges-that's what he pays me for"
was said by Josh, not Leo. I assume this was a typo, as the next
line begins with "Josh also..." I just thought I'd
mention it. All in all, it's very well-written. I enjoyed reading
an article that deals with the show not as something people watch
for brain-candy during Wednesday prime-time, but as the artistic
program it is-full of symbolism, parallels, and just plain artistic
writing!
| Comment
on Rob Waring's article: The Winslow Boy, Trial Of The
Century? |
From: John R. Curd found us through: Search Engine.
Over 1 hour ago I asked "GOOGLE" to search for 'Winslow
Boy! It returned about! 12,400 result. Fate had me choosing /pj/winslowboy-waring.htm.
The page presented a very good review with many interesting facts
and commentary. Is RW English? The vocabulary and composition
felt far more English than American. So then I wondered round
the Universite but I must get into the garden (is that yard?).
The rain has stopped and the sun is shining; for the records
Sunday 3 March 2002 10:51 GMT!
Rob Waring's response:
Thank you for your kind words. The sun is shining in San
Francisco, too. I am English, in that all my ancestors came from
England, but I was born and raised in America. My maternal grandparents
immigrated just before the Great War. My father's family came
over about 1660, to Virginia. I sometimes feel more English than
American, and I enjoyed the film because it portrayed a time
when my grandmother, a suffragist, was politically active in
England. There are several other articles about The Winslow Boy
on the PJ site; it apparently struck a cord with our contributors.
Regards, Rob Waring
|


Hello everyone, I live in Italy and I'm monitoring a photovoltaic system, I wanted to know why, part production, sensors SCT-013-000 from the measure 0 - 0.65A is always higher. That is, 0,10A passage of current, the sensor measures 0.40A. still current 0.65A measure 0.85A when the passage of current of 0.90A the measurement is ok.
While the findings of the consumption is ok.
Using Arduino leonardo for pads.
How can I fix this?
It 'a problem of sensor?
Someone has my same problem?
Safe for your feedback
sincerely yours
Measurement error from 0.0A - 0.65A
Submitted by Gerardo on Wed, 28/01/2015 - 19:29»
Re: Measurement error from 0.0A - 0.65A
Not a problem with the current transformers, but we believe a problem with your Arduino. It is almost certainly digital noise from the main part of the processor getting in to the analogue to digital converter, it is being added to the millivolt signal from your CT and then the rms conversion mathematics rectify it along with the wanted signal.
If you measure the voltage also, then use emonLib to calculate real power, you will find the result is much more accurate as the noise is not rectified and therefore positive and negative spikes of noise tends to cancel each other.
Re: Measurement error from 0.0A - 0.65A
Hello Robert,
how do I calculate real power? Now I'm using:
emon.calcVI(20, 2000);
float ACV= emon.Vrms;
double Irms = emon.calcIrms(1480);
Thanks for your response
Re: Measurement error from 0.0A - 0.65A
You are already calculating real power. After you have done emon.calcVI(20, 2000), real power is available in emon.realPower. You also have emon.apparentPower & emon.powerFactor. emon.Irms is there too without the need to call calcIrms separately.
Look at emonLib.cpp and emonLib.h to see what emonLib does.
Re: Measurement error from 0.0A - 0.65A
There are some relatively easy options that might be worth a try to see if they reduce noise.
How are you powering the Arduino? You really want that supply to be as ripple-free as possible. The easiest way to achieve that is to power it via the DC-in jack and use the onboard regulator. If you're powering the Vcc rail directly (or via the USB port) you really need that supply to be as clean as possible.
Assuming you're not trying to run off batteries, consider reducing the R values used to build the mid-rails. The 470Ks recommended are aimed towards low power consumption in battery operated environments, but could be reduced by one to two orders of magnitude when not running off batteries. You can do the simple experiment described in this thread: http://openenergymonitor.org/emon/node/6196 to see how much impact that has on noise.
A low-pass filter (aka anti-aliasing filter) on all your ADC inputs is always recommended. You can see a scope picture of one of those doing their magic in this thread: http://openenergymonitor.org/emon/node/9956
Re: Measurement error from 0.0A - 0.65A
Reducing the 470 kΩ resistors will not in fact affect the noise power. As the resistor value is decreased, the noise bandwidth increases in exactly the same proportion. Only the capacitor value affects the noise power, and that should not be increased, since unless a resistor is added in series with the ADC input, it would be possible to overload the protection diodes inside the IC package.
Recent tests show that the latest emonTx, which has better grounding and does not have the inductor separating digital and analogue grounds, does indeed have a slightly improved noise performance.
Anecdotally, Arduino boards have always been the source of more complaints about noise than the emonTx (all versions).
Re: Measurement error from 0.0A - 0.65A
Reducing the 470 kΩ resistors will not in fact affect the noise power.
I think that's only true across the entire spectrum; from DC to daylight as the RF guys like to say. The meters being built here are extremely bandwidth limited, and once you do that, cumulative noise power up to a given frequency is dependent on R.
In any case I'd be surprised if the thermal noise from the resistors is a significant source of noise. The real reason you want to keep those mid-rail dividers as low as the power budget permits is to make that rail as a low an impedance voltage source as possible, so that other noise in the system is attenuated. Ideally you'd use a voltage follower op-amp, as several contributors to these forums have done.
You can see an example of how noise injected onto the mid-rail (via my finger) affects the ADC readings depending on the value chosen for those resistors in the pointer above. Admittedly I don't have a cap there to help shunt that noise away, but it demonstrates how reliant you are on that cap with such high R divider. Sure, you could go for a very high quality cap with low ESR, but lower R values on your divider would help too. 470K seem crazy high... assuming of course you're not trying to conserve battery power.
Re: Measurement error from 0.0A - 0.65A
"to make that rail as a low an impedance voltage source as possible"
But if you do that, you need to add impedance somewhere in the loop to limit the current in the input protection diodes under fault conditions.
Re: Measurement error from 0.0A - 0.65A
you need to add impedance somewhere in the loop to limit the current in the input protection diodes under fault conditions.
Fault as in a short in your toaster? How does stiffening the mid-rail make you any more susceptible to over-current from that? Even the building blocks page invites you to use anything from 10K to 470K to derive the mid-rail, and mentions:
We have been using 10 kΩ resistors for mains powered monitors. The emonTx uses 470 kΩ resistors to really keep the power consumption to a minimum as it is intended to run off batteries for several months.
Anecdotally, Arduino boards have always been the source of more complaints about noise than the emonTx (all versions).
So anything we can do to help them is a good thing, right?
Re: Measurement error from 0.0A - 0.65A
And why is a 1 kΩ series resistor included in the V3 - precisely because protection is marginal. Just because there hasn't been a proven case doesn't mean it can't happen. The fault level in the UK is generally around 300 kVA, and if you get a full-blown fault downstream of the CT, there's just about enough getting through the standard CT given worst-case components to be right on the limit of the diodes.
"So anything we can do to help them is a good thing, right?" Indeed, it's called an emonTx V3.4.
Re: Measurement error from 0.0A - 0.65A
a 1 kΩ series resistor included in the V3
That sounds like a great idea, and hopefully Gerardo will follow your lead. For even more protection, you could do that and add some beefy external protection diodes. But how does this relate to the stiffness of the mid-rail which is what we were discussing. I repeat my question:
How does stiffening the mid-rail make you any more susceptible to over-current from that?
("that" being the short circuit in your toaster).
Re: Measurement error from 0.0A - 0.65A
Q: What limits the current if there isn't a series resistor there?
A: The Thévenin equivalent impedance of the bias chain, of course! It makes no difference whether the limiting impedance is before or after the CT, it's still in series with the input. That's a very good reason for not increasing that bypass capacitor, too.
Re: Measurement error from 0.0A - 0.65A
Q: What limits the current if there isn't a series resistor there? A: The Thévenin equivalent impedance of the bias chain, of course!
I'm afraid it's still not obvious to me. Here's my attempt at an equivalent circuit:
where:
R1 - total impedance of CT/burden combo
R2- new series protection resistor
R3 - internal impedance of the ADC pin
R4 - equivalent R of the mid-rail divider
C1 - bypass cap
If we use 470K dividers, then R4 is 235K. If we use 10K dividers then R4 is 5K, but either way it's in parallel with C1 whose reactance is about 300 ohms. The impedance of that side of the circuit is 299.6 ohms or 283 ohms. Is that really all we're quibbling over?
That's a very good reason for not increasing that bypass capacitor, too.
As far as I know, you're the only one suggesting that (or not suggesting that). I'm talking about lowering the mid-rail dividers, not changing the capacitor.
Re: Measurement error from 0.0A - 0.65A
hello dBC, I now have this as I can adapt to your schedule?
Thanks for your friendly reply
Re: Measurement error from 0.0A - 0.65A
Provided you're not trying to run off batteries, I'd make R4 and R5 10K rather 470K. I'd add a 1K series resistor on the "Arduino Analog In", and I'd power your Arduino via it's DC-in jack (typically 7-12V DC) and definitely not via the USB port. Try all that and see if your low level measurements improve.
And consider using 1% resistors for most of that stuff. While the filters and calibration process will cover you for their tolerance deviation, I think 1%ers are usually more stable as well. The new 1K series resistor can be 5% as it'll only ever see current during fault conditions, but stability in all your other resistors is pretty critical to good results.
Re: Measurement error from 0.0A - 0.65A
I can use Emonlib 5V or should I use a 3.3 V ? because with 5V me incorrect values . Thank You
Re: Measurement error from 0.0A - 0.65A
Which sketch are you using? If you are using the correct sketch for the emonTx SHIELD, the supply voltage is measured inside emonLib and it should scale the measured values properly. But you must NOT define "emonTxV3" in your sketch, because when you do, it uses a fixed value of 3.3 V (and your voltage, current and power will all be wrong).


template block example
themebutton will appendto ppel,color bgcolor is controled by config.theme
themebutton close
themebutton start
themebutton hide
themebutton show
setChildOption
hide
show


Crop Rotation
Crop rotation is the systematic planting of different crops in a particular order over several years in the same growing space. This process helps maintain nutrients in the soil, reduce soil erosion, and prevents plant diseases and pests.
There is no universally accepted rotation schedule as the types of plants in a particular farm or garden depend on the local soil, climate, and resources available. The length of rotation time between different plants will also vary depending on the needs of the gardener.
Advantages of Crop Rotation
Increases soil fertility.
Increases crop yield.
Increase in soil nutrients.
Reduces soil erosion.
Limits concentration of pests and diseases.
Reduces the stress of weeds.
Improves the soil structure.
Reduces pollution.


{ZL.Source id="节点栏目信息数据源"/}
Please use the design request form below to help us provide you with an amazing custom sign that fits your needs exactly. We can do either NEON or LED and we also have 100's of custom templates to choose from on our site. Fill out as much of the form as you like and remember the more information we have from you the more our design will look like exactly what you are looking for.


Please send SMS to<PHONE_NUMBER> in the following format. VTS ,CVSM,RouteNo,StopNo
For instance, if you're boarding at Stop No 1, please send SMS as follows VTS ,CVSM,R17A,1 (This is just a sample, Please change the Route No and Stop No as per your route and stop)
To STOP receiving SMS, please send following SMS format, VTS STOP to<PHONE_NUMBER>.