"New handy controls like flashlight, hotspot, screen rotation and cast screen controls". Finally.
I hope that you can customise which ones appear, not holding my breath but it would be great.
There were runours of just that, after parts of the code 'leaked'.
You can't customise it in the L developer preview.
Wait. I have screen rotation now. O.o is this just bringing it to all devices?
It's there for the Nexus 7, but someone thought it was brilliant to not include it for the 4 and 5.
They're playing catch up with Samsung.
I never know whether this kind of stuff is just in cyanogenmod or from stock. I often assume everyone has them.
I know. I've got gravitybox and just assume it's normal to have.
Moto X stock has it... Every phone I've had pretty much since at least ICS has had it...
I have an N5 and an OPO. Although my N5 is more fluid, my OPO is way better at handling some things like for instance pressing on a quick setting to toggle it as opposed to holding it like on stock.
People were using android without this stuff? Holy shit
Android 5.0 Lollipop
works on/across all your devices
customization (that carries over from one device to another?)
pick up where you left off, so the songs, photos, apps, and even recent searches (I can see a NSFW situation in your future)
consistent design across devices
Now content responds to your touch, or even your voice, in more intuitive ways, and transitions between tasks are more fluid.
You can now adjust your settings so that only certain people and notifications can get through
new battery saver feature that extends the life of your device by up to 90 minutes
multiple user accounts and guest user mode for keeping your personal stuff private
you can now secure your device with a PIN, password, pattern, or even by pairing your phone to a trusted device like your watch or car with Smart Lock
Here is the official site: https://android.com/versions/lollipop-5-0/
The security thing seems great.
What am I missing? My phone already has all those security options.
What I really want is lock screen off when on a trusted WIFI network.
I've been doing that with Tasker for a while now, but I'm sure an OS integrated function will work much better than my half-assed task.
works on/across all your devices
What does that even mean? You mean my HTC Hero will now run Lollipop???
Probably more like it will work on your desktop, phone, and tablet.
THE LG GENESIS IS BACK IN ACTION
It means that all your devices that are capable of running L will sync and feel the same.
So for the majority of people who just have an Android phone or maybe an Android phone and tablet....it doesn't mean much. (And that's assuming that phone/tablet are able to run Lollipop, which won't be the case for the majority of Android users for a while.)
Yes, they've finally got a battery saver, the one thing I miss from touchwiz.
Were these things not already in android? Many of these seem like normal items that were already there, or have been in competitors (windows 8.1) for a while
pick up where you left off, so the songs, photos, apps, and even recent searches (I can see a NSFW situation in your future)
This is already in place for searches and bookmarks, and it's why I don't log into my google account at work
As I plan on switching back to Android soon after a 2 year stint with Windows Phone, the line:
You can now adjust your settings so that only certain people and notifications can get through
makes me really happy. On Windows Phone it is called Quiet Hours, and I really love it. Every night I got to bed, I turn it on. And then only my gf, my roommate and my one brother (who I trust not to call in the middle of the night unless it is an emergency) can get through.
I will be interested to see how Google makes this work. There are other nice things in the Windows Phone version (like break-through rules, anyone calls 2x's in 3 mins it will still ring, to help with emergencies).
Seems like they won't abandon the Nexus 5 http://www.google.com/nexus/
Makes sense considering the 6's screen size may be a little too large for some people.
And considering it starts at $649
Edit: I think it is worth it if you're in the market for a phablet such as the Note 3/4, G Flex, and whatever else there is. The N6 being a cheaper and different option compared to the rest. Hell, the Note 4 unlocked goes for $850+ on Amazon and $750+ for an unlocked T-Mobile version. Say what you will, but I think the N6 would be the better option for me.
There is a reason they're still selling the N5. It is still an amazingly fast phone.
Compare the Nexus 6 to its competitors which I just listed and I think it's a great choice like the N5 was compared to other phones similar to its size.
I guess that's a good thing, but it's awfully disappointing when the only reason I have been watching for the 6 is in hopes of getting a discounted 5.
I was hoping we'd get a refresh of the 5. I'd like the 6's hardware with the 5's 5" 1080p screen. Battery life would be practically eternal if you don't have to drive that big QHD display and you'd have all the processing power you could need.
It's incredible how it still costs that much.
Also if people want the new Nexus 5 they can always look to the Moto X. It's basically just a smaller Nexus 6.
And in true Nexus fashion, there are battery concerns and the price is right. It won't be pure Android but its close.
No stereo speakers though, which is a bummer. After playing 'cup the phone' for god knows how long, I want a phone that puts the damn speakers where they very well should have been put right from the beginning.
Oh Shit! Go to the Nexus 5 click the star. This is what Google Play Music update will look like. It couldn't come soon enough.
Now to find out why it went out of stock and why they started doing replacements with refurbs instead of new ones. Seems like it's out of production, so are they updating it?
So is there going to be a Nexus 5 refresh? New hardware? I need a new phone coming up around Christmas.
"...in the coming weeks" noooo I wanted it today!
Well, they still need to update Now, Maps, GMail, YouTube, Camera, Calendar, Drive, Play Games, Play Music, Play Movies, Play Books, Rewards and Translate.
impatiently waits for the Play Music update.
The updated apps will probably come with Lollipop and be able to take advantage of all the L APIs.
Thank god Androidify is updated and ready to go though.
Notice on the Nexus 5, 6 and so on there is no Hangouts icon? It's replaced by a blue and white app icon instead.
Not really though. They kinda could release it before and just update the apps on the Play Store.
Alright, just got an Android phone, so kinda confused, is this just for Nexus phones or for every phone using Android OS. Like, is this a new/better/improved Kit Kat or is this something else entirely
Not strictly for Nexus, but whether or not your phone gets the update and how soon they do will depend on the manufacturer.
KitKat is Android version 4.4(.4? Could be wrong on that.) Lollipop is Android version 5, so it is the newest version of Android, which all phones should get updates to, though older ones unfortunately won't. The Nexus devices will just get them first because their updates come straight from Google, while other devices get their updates from the OEM, so your update will have to come from HTC.
4chan leaker (who's been pretty reliable) says nexus 5 is getting the update Friday.
It's ironic because lollipops are probably my least favourite sweet to share with other people.
Sharing a single lollipop is definitely disgusting.
But oh so intimate! Maybe that's what they were aiming for.
Material Design
A bold, colorful, and responsive UI design for consistent, intuitive experiences across all your devices
Responsive, natural motion, realistic lighting and shadows, and familiar visual elements make it easier to navigate your device
Vivid new colors, typography, and edge-to-edge imagery help to focus your attention
Notifications
New ways to control when and how you receive messages - only get interrupted when you want to be
View and respond to messages directly from your lock screen. Includes the ability to hide sensitive content for these notifications
For fewer disruptions, turn on Priority mode via your device’s volume button so only certain people and notifications get through. Or schedule recurring downtime like 10pm to 8am when only Priority notifications can get through
With Lollipop, incoming phone calls won’t interrupt what you’re watching or playing. You can choose to answer the call or just keep doing what you’re doing
Control the notifications triggered by your apps; hide sensitive content and prioritize or turn off the app’s notifications entirely
More intelligent ranking of notifications based on who they’re from and the type of communication. See all your notifications in one place by tapping the top of the screen
Battery
Power for the long haul
A battery saver feature which extends device use by up to 90 mins
Estimated time left to fully charge is displayed when your device is plugged in
Estimated time left on your device before you need to charge again can now be found in battery settings
Security
Keep your stuff safe and sound
New devices come with encryption automatically turned on to help protect data on lost or stolen devices
SELinux enforcing for all applications means even better protection against vulnerabilities and malware
Use Android Smart Lock to secure your phone or tablet by pairing it with a trusted device like your wearable or even your car
Device Sharing
More flexible sharing with family and friends
Multiple users for phones. If you forget your phone, you still can call any of your friends (or access any of your messages, photos etc.) by simply logging into another Android phone running Lollipop. Also perfect for families who want to share a phone, but not their stuff
Guest user for phones and tablets means you can lend your device and not your stuff
Screen pinning: pin your screen so another user can access just that content without messing with your other stuff
New Quick Settings
Get to the most frequently used settings with just two swipes down from the top of the screen
New handy controls like flashlight, hotspot, screen rotation and cast screen controls
Easier on/off toggles for Wi-Fi, Bluetooth, and location
Manually adjust your brightness for certain conditions. Then, adaptive brightness will kick in based on ambient lighting
Connectivity
A better internet connection everywhere and more powerful Bluetooth low energy capabilities
Improved network handoffs resulting in limited interruption in connectivity. For example, continue your video chat or VoIP calls without interruption as you leave the house and switch from your home Wi-Fi back to cellular
Improved network selection logic so that your device connects only if there is a verified internet connection on Wi-Fi
Power-efficient scanning for nearby Bluetooth low energy (“BLE”) devices like wearables or beacons
New BLE peripheral mode
Runtime and Performance
A faster, smoother and more powerful computing experience
ART, an entirely new Android runtime, improves application performance and responsiveness
Support for 64 bit devices, like the Nexus 9, brings desktop class CPUs to Android
Media
Bolder graphics and improved audio, video, and camera capabilities
Lower latency audio input ensuring that music and communication applications that have strict delay requirements provide an amazing realtime experience
Multi-channel audio stream mixing means professional audio applications can now mix up to eight channels including 5.1 and 7.1 channels
USB Audio support means you can plug USB microphones, speakers, and a myriad of other USB audio devices like amplifiers and mixers into your Android device
OpenGL ES 3.1 and Android extension pack brings Android to the forefront of mobile graphics putting it on par with desktop and console class performance
A range of new professional photography features for Android Lollipop that let you
State of the art video technology with support for HEVC main profile to allow for UHD 4K 10-bit video playback, tunneled hardware video decoding to save power and improved HLS support for streaming
OK Google
Easy access to information and performing tasks
Even if your screen is off, you can say "OK Google" on devices with digital signal processing support such as Nexus 6 and Nexus 9
Talk to Google on the go to get quick answers, send a text, get directions and more
Android TV
Support for living room devices
User interface adapted for the living room
Less browsing, more watching with personalized recommendations for content like movies and TV shows
Voice search for Google Play, YouTube and supported apps so you can just say what you want to see
Console-style Android gaming on your TV with a gamepad
Cast your favorite entertainment apps to your big screen with Google Cast support for Android TV devices
Accessibility
Enhanced low vision and color blind capabilities
Boost text contrast or invert colors to improve legibility
Adjust display to improve color differentiation
Now in 68+ languages
15 new additions
Device set up
Get up and running in no-time
Tap & go: instant set up of your new Android phone or tablet by simply tapping it to your old one (requires NFC)
Whenever you get a new Android phone or tablet, you can bring over your apps from Google Play automatically from any of your old Android devices
And a whole lot more
Tap & pay: easily manage multiple payment apps by quickly switching between them
Print preview and page range support
Revamped display for battery, Bluetooth, data usage, and Wi-Fi settings and new search functionality
New device level feedback for Nexus devices in Settings > about phone > send feedback
Easier sharing with
Where supported by the hardware, your device will wake up as soon as you pick it up or tap the screen twice
Improved hardware keyboard accessory support including support for multilingual, emoji input, search key, and improved app and system key chords
From another part of Earth, you are thanked.
Even if your screen is off, you can say "OK Google" on devices with digital signal processing support such as Nexus 6 and Nexus 9
DAMN. I thought the Nexus 5 supported this at the hardware level.
Don't know if it will be supported by Google but the Nexus 5/Snapdragon 800 does have an audio core which should allow for the same functionality.
[deleted]
Basque language support... There are dozens of us, dozens!
The multiple account support looks amazing, my paranoid friends will probably (not) let me use their phones. And brings full backup one step closer.
Also ART seems to be 4 times more efficient than Dalvik, that's twice what it was on the preview right? If it's 60 fps and with less than 20ms of screen response time I'll be the happiest man on earth.
Great update overall.
Universal Ok Google with screen off? Battery improvements? Lower latency audio input?
I'm all aboard this tra... oh wait. I have a Note II.
Android 5 Custom Roms with Bugs ALL THE WAY.
Universal OK Google only if your phone supports it
Galaxy Note 2 master race.
Improved network handoffs resulting in limited interruption in connectivity. For example, continue your video chat or VoIP calls without interruption as you leave the house and switch from your home Wi-Fi back to cellular
Under-appreciated feature. Very nice!
Accessibility Enhanced low vision and color blind capabilities
And still no native support for mono audio. No love for the hard of hearing.
"first-of-its-kind android gaming device"
An Ouya developer somewhere is softly shedding a tear...
They mean the first one that people will actually buy.
The Ouya got a ton of sales during its kickstarter. It just happened to be really awful.
Surprised no one is really talking about the Android TV nexus player. I'm interested in it at the very least. I really like my android mini pc, but it's definitely got a number of flaws. It would be awesome to have a similar device made by a major manufacturer with all the bugs worked out. Hopefully, android tv will be flashable onto my existing mini pc at some point.
I was also interested in seeing that it is intel powered. I'm curious, is it possible to install windows on intel android devices?
I lost interest instantly when I saw it had no ethernet. I was hoping for Chromecast + Limelight in one device, but there's no way I can stream games reasonably over WiFi.
No Ethernet, really? I missed that. That is a huge disappointment
I didn't exactly lose interest, but my interest dropped significantly when I saw it was wifi only.
I love my Chromecast, but it's a bit flaky from time to time on wifi.
At least it supports 5 Ghz unlike Chromecast.
I'm actually happy that I'll have a second device that can utilize 802.11ac.
You can, actually. I play Crysis on my Macbook air with the Steam in home streaming all the time. Works really well.
I am also curious about the android player. I have 2 chromecasts one for each tv so I probably won't get the player but it is still interesting and looks to be a real contender to the Roku, Apple TV, and FireTV.
Yeah I feel kinda bad about purchasing my mini pc two months ago, since this may very well be the device I really want. However, it would be a nice consolation if I am able to flash android tv on it at some point.
it has half the ram of the Amazon TV device. 1GB RAM to 2G RAM: http://www.google.com/nexus/player/ http://en.wikipedia.org/wiki/Amazon_Fire_TV#Hardware
Yeah, kind of surprised about that. My mini pc has 2gb as well. I think they are banking on ppl caring more about the software than the hardware, but it is such a silly corner to cut.
All it needs is Steam Home Streaming and it can replace my HTPC.
Now, if they make a Nexus Car to test Android Car...
At $99, I'm definitely interested!
No Ethernet and Micro-USB 2.0 is kinda a deal breaker for me. Tho, 802.11ac is nice...
Also 8GB storage. Ehhhhhhh
Agreed. My biggest question about that player is whether it will support 5.1 audio. I know the chromecast doesn't (which I found out long after I purchased it).
As much as my chromecast covers me 99% of the time I'd definitely pick up the android player if the price is right and it has 5.1 audio out. If google chose not to support surround sound again then I might have to just skip it in favor of some other competitors product which does.
The Chromecast does support 5.1 but only through Dolby Digital Plus, which is the newest standard for DD.
I've owned the last 4 generations of Nexus phones and this is the first time where I don't think I need an upgrade. Especially at this price point. All I'm really seeing here is a higher resolution screen, which I don't need.
I was looking to upgrade because the battery on my 5 is starting to tank. But not for a $650 buy in.
I love my Nexus 5. I would consider upgrading if the screen wasn't so huge. The screen on the 5 is a perfect size. Anything smaller is too small, anything bigger is just overly large imo.
We had the best 2015 phone back in 2013..
Kind of same. I've had og evo, galaxy nexus, optimus g pro, now the nexus 5. I love this phone the way only my gn came close to. I'll keep my 5 forever if I can
Nexus 7 owner, can relate
Can confirm. Am Nexus 5 owner.
Nice to see they kept the 5 active for those you you who did not want a 6" phone.
It's not that even that I don't want the 6" phone at this point, I would have ended up getting it anyway, but it's way out of my price range.
Where are the official prices?
Imagine a n5v2 with a 2850mah battery.
Is it the same N5 or did they make it better?
Same N5.
Everything I wanted and more.
And also, I'm seriously digging the marketing. "Be together. Not the same." is an amazing slogan.
 You remember feelings right?
Yeah.
"Even if your screen is off, you can say "OK Google" on devices with digital signal processing support such as Nexus 6 and Nexus 9" - https://android.com/versions/lollipop-5-0/
What's this digital signal processing support, and does it differ from snapdragon 800's extra core said to be capable of handling always listening.

I read a long time ago that it will
EDIT: Grammar.
I think you're being downvoted because that sentence didn't make much sense in english. I think you meant "I read a long time ago that it will" . No criticism intended, I love learning new languages and I would want someone to correct me if my sentence didn't make sense.
There's all of the announcements.
I'm torn. I actually like them all. But I'm disappointed with the motorola design of the Nexus 6. Mainly that its a MotoX seemingly without any effort of differentiation. The Nexus 9 and Nexus Player look pretty sweet.
It's probably because it was an Android Silver project that no one put much effort into.
Yeah, it's a re-specced MotoX. can't complain though.
I don't mind the design, I want the larger screen, and I want the front facing speakers - but I don't care about 1440p and I wish I could get a wood back plate like the Moto X.
Blah.
whew!!!
was worried there for a second...
Let's hope the L preview will enable quick device updates. That seems like the plan they had but let's see if it materializes
Materializes, I see what you did there.
Anyone else noticed that under the battery section for the specs on the N6, it mentions "Ambient mode"? You think the N6 will have Active Display?
I was wondering the same thing.
With Lollipop, incoming phone calls won’t interrupt what you’re watching or playing. You can choose to answer the call or just keep doing what you’re doing
Finally I don't need to answer a call while fapping.
ITS OFFICIAL!!!!
Edit:Verizon's back in it!
Nexus 9 and Nexus Player will be available for pre-order on October 17 and in stores starting November 3. Nexus 6 will be available for pre-order in late October and in stores in November—with options for an unlocked version though Play store, or a monthly contract or installment plan through carriers, including AT&T, Sprint, T-Mobile, U.S. Cellular and Verizon. Specific carrier rollout will be subject to certification completion and will vary. Check out google.com/nexus for more details on availability.
I wonder if that means there's WiFi calling. Tmobile has stated all their phones the sell will have WiFi calling.
Did Google not learn their lesson with the Galaxy Nexus?
I loved my Galaxy Nexus. ROMs came hours after the GSM got the new update and they were perfectly stable by the next morning.
YES! All you lemon merengue and licorice people lost!
I kinda knew it would be lollipop since that one pic with a giant lollipop android showed up on google+.
So since yesterday.. Haha
I'm talking about the google+ pic from like july.
Layercake made so much sense, kinda wish they went with that. Though Lollipop is a really nice word to type with one hand.
Will the N6 support wireless charging with the magnetic stick like the N5? I didn't see anything about it on the specs for either one.
Edit: The Motorola page does list QI wireless charging, but no mention of magnets.
Thanks goodness! I have QI pads everywhere!
Every release, I get more and more disappointed that Android hasn't released an application that mutually transits SMS messages to an Android tablet via Hangouts.
Please don't let The Verge get the most upvotes and attention. This post has to reach front page, this post has to be the center for discussion.
(...Oh my the beauty of these devices)
The Verge has REALLY gotten slimy lately with their mindless stream of Apple/bendgate-defensive articles.
Josh Topolsky left The Verge a couple weeks back. I stopped going there shortly after.

Seriously, i am in love with the way both designs look. Especially the blue of the Nexus 6. Its such a nice blue
So the old 2012 nexus is getting lollipop too...right?
Yes, originally it wasn't included, but some guy on G+ said that was a mistake and was being updated.
RIP Check For Updates button...
Their campaign videos are sending chills down my spine.
Is that what being a fanboy feels like ? ...
So, Android noob here. This means Moto X is included, right?
Motorola just announced Moto X, G and E will be updated (even the first gen devices). http://motorola-blog.blogspot.com/2014/10/its-official-android-50-lollipop-coming.html
Motorola just announced Moto X, G and E will be updated (even the first gen devices).
You just made my morning! I have a first gen G and was afraid I was going to start wanting a new phone again...
It's up to Motorola to update the moto x to lollipop, but they tend to use almost stock android so it won't take them long.
Be together. Not the same.
Ugh that's so good.
I know right. Their ads for it are not only spine chilling for Android nerds, but also very mainstream. If they got air time on national networks, it would definitely get the attention of the general population. Every day people will begin to DEMAND the stock android experience. This is exciting times for Android users.
Woah the Nexus 6 is water resistant? Loom half way down the page just under the battery specs.
Exactly! And it also records 4k video! I have hopes from this device's camera. It even specifies good low light performance.
Think they said the same for last couple nexus in low light. So Dont hold out to much. But fingers crossed
F5 until it gets there
https://developers.google.com/android/nexus/images#hammerhead
According to the L Preview page, the SDK is coming 17/10. Factory images should surely follow shortly after?
Auto turn on screen when you pick up phone, or double tap screen!
Sweet!
Dear Sony: This is your moment.
No nexus 4:(
e: yay https://plus.google.com/105162099385231511005/posts/aXYoj3Ygirs
Have faith.
It is coming to the N4, was a typo:
https://plus.google.com/105162099385231511005/posts/aXYoj3Ygirs
"Android 5.0 Lollipop, which comes on Nexus 6, Nexus 9 and Nexus Player, will also be available on Nexus 4, 5, 7, 10 and Google Play edition devices in the coming weeks."
Or am I not seeing this?
As a T-Mobile customer, has anybody heard anything about Android L and WiFi calling?? This is a big deal.
YES !! TMO Announcement
Edit : "Plus, this hot new smartphone is expected to support Wi-Fi Un-leashed beginning in early 2015 with an over-the-air update– making it the first-ever Nexus device that will support Wi-Fi Calling thanks to enhancements in Android 5.0."
Hopefully this means it will actually support wifi calling through t-mobile and not just support it through google's new hangouts dialer.
What is so good about WiFi calling?
As a Republic Wireless customer, lol
$650? Yikes. Part of what I like about Android is not carrying around a $500+ device. I've only broken one phone over the years, but it's really only a matter of time before the next.
Was so sure it was gonna be Lutefisk.
with options for an unlocked version though Play store
you would think they would have has had someone proof read it...
you would think they would have has someone proof read it...
;)
well i set myself up for that one haha
So, multi-window multitasking didn't make the cut, apparently : / I was very excited about that possibility, it would be great to have it with N9.
for participating apps and services
Is there a reason why you linked the end of the video?
I like the storage options, can't wait to get my hands on the 64gb variant! Shame that there isn't a removable SD card, but that's to be expected. I hope the battery life is much better than my N4.
Yet the nexus 9 gets 16 and 32gb.
As much as I would like a Nexus 6 (or even a Moto X) It looks like i'm going to try and get a Nexus 5 or OnePlus One. I would love to get a Nexus 5 for ~$300 - $350 in a 64GB variant. That would be amazing.
 HBO announces subscription deals and now 5.0 is officially announced. The only way this could get better is if GabeN announced HL3.
Well for $649 and knowing that Sony is tinkering with putting stock roms on their devices looks like I will just get the z3, at least it won't be the size of a brick.
Google announces Android 5.0 Lollipop
This is one of those sentences where, if you went back in time and showed it to somebody it would make no sense whatsoever.
So will the HTC One M8 also be capable of getting this?
Kinda disappointed with how little they showed off of Lollipop. Once the preview builds go out Friday I know we'll see more, but there is a ton of stuff to show off and we've seen very little. I mean, they are overhauling the entire interface and they can't post some videos going in-depth with what we'll actually see when it's released? C'mon Google...
Nexus 6 is meh. Too big, and loses the appeal of Nexus pricing. I guess if people want a smaller Nexus though, it's pretty much the Moto X, and the software features Motorola adds are actually decent and not bloatware.
Android L I'm excited for, I've been using ART full time for weeks and it really is better, on my Moto G it's noticable faster, scrolling is better and more connected feeling, battery life is even slightly up.
Nexus 9, my biggest excitement is finding out about the Nvidia Denver cores, finally someone other than Apple going for two big high IPC cores rather than four smaller ones.
The Nexus 6 price is a tragedy. Along with stock Android, it's affordability was the best thing it had going for it. Major shame.
I have no experience with android whatsoever, so excuse me if I ask, say you have an HTC One, can you install Lollipop on it?
The nexus/play devices offer a pure android experience, so they get the update immediately. For everything else, it will be up to the manufacturer to decide when/if a phone gets the update.
I just played this webm on my phone in fullscreen multiple times since I can't wait.
All this time the world has been awash with dreams of a Motorola Nexus. Then one day, it happens. Unfortunately, it has been initially regarded as a bad move.
Might be a swell phone, but it's price point sucks in comparison to what the Nexus culture is known for and, honestly, it's bigger than many people preferred size. There will be some who love this phone, but there will be even more people who are disappointed.
Just seems like Google wanted to cash in on the big screen size fad and make buddy buddy with the carriers by making it less appealing to buy without a plan attached.
The Nexus 9, however, looks like it's going to replace my shitty 2013 Asus Zenbook since Asus dropped the ball on quality.
Finally, Google officially releases the performance boosting thing!.
Aaaaand there's the official announcement. Can't wait to update!
I'm really happy the Nexus 6 has an AMOLED display.
Apparently you've never owned an AMOLED phone with software keys. Still vividly remember the awful burn-in the Galaxy Nexus had.
Looks nice, but still just too big for me and too expensive...  Sorry Google... Off to Sony I go.
No update for Nexus 4? You must be kidding Google. There is no reason not to update it besides spending money on developing it. Disappointing Edit: Even the nexus 10 is getting it?
Edit2: It's coming!! Page has been edited. https://plus.google.com/app/basic/105162099385231511005/posts?cbp=1ci2tv9r4lkl2&sview=27&cid=5&soc-app=115&soc-platform=1&spath=%2Fapp%2Fbasic%2F%2BArtemRussakovskii%2Fposts&sparm=cbp%3Djx11cs4d3edm%26sview%3D2%26cid%3D5%26soc-app%3D115%26soc-platform%3D1%26spath%3D%2Fapp%2Fbasic%2Fstream
Put down them pitchforks: https://plus.google.com/105162099385231511005/posts/aXYoj3Ygirs
The Nexus 4 is getting the update! It was a mistake.
Nexus 4 gets it now, they made a mistake
WHAT?! NO L FOR US?!
guys guys guys
EDIT EDIT
EDIT
https://plus.google.com/105162099385231511005/posts/aXYoj3Ygirs
"Android 5.0 Lollipop, which comes on Nexus 6, Nexus 9 and Nexus Player, will also be available on Nexus 5, 7, 10 and Google Play edition devices in the coming weeks."
Don't the N10 and N4 use the same chip? Why would they not update it?
No. The Nexus 10 uses a Samsung Exynos SoC. The Nexus 4 uses a Snapdragon S4.
Edit: correction.
I can't be the only one annoyed that the headphone port is on the top?
So it looks like N5 will get Android 5.0. Would that be a good purchase today? (I still use the very first HTC Desire, and the price of N6 is not an option for me)
I hate how google showed L in the spring made us wait until now then they say yeah it will be available next month!


Properties
Private Readonly _is_day_of_month_wildcard_match
_is_day_of_month_wildcard_match: boolean = false
Private Readonly _is_day_of_week_wildcard_match
_is_day_of_week_wildcard_match: boolean = false
Private _month
_month: number
Private _schedule
_schedule: CronMonth
Private Readonly _tz
_tz: string
Private Readonly _utc
_utc: boolean
Private _year
_year: number
Static Readonly default_fields
default_fields: string[] = ...
Static Readonly fieldnames
fieldnames: FieldType[] = ...
Static Readonly predefined
predefined: {} = ...


SETTINGS
» Here you can change details about you and your password.
Information
Password
Caching
Settings


Suarez tells SPORT: You have to take what Pique says with a pinch of salt
The Uruguayan said the players had nothing to do with attempts to bring Neymar back to Barcelona
by Jordi Gil► You can read the complete interview with Luis Suarez here in Spanish
In his interview with SPORT, Luis Suarez commented on Gerard Pique's recent revelation that the Barcelona players were ready to help finance Neymar's return to the club.
"Sometimes you have to take what Geri says with a pinch of salt," Suarez said. "He has the gift of the gab and a lot of experience in making comments. In this case, he knows and is completely aware that the players were completely removed from the Ney case. We were ready to welcome him -- him or any other player that wants to come -- but always distanced from what was going on."
Griezmann's RECEPTION:
"[His reception] has been spectacular. Sometimes things are poorly interpreted. Both Leo (Messi) and I, as well as Geri, welcomed him last year, saying that he was a great player and one of the best in the world. He then became world champion and we lauded him for the class of player he is. After that, we didn't know what would happen with him, we weren't certain that he would come this year.
"We treat him like anyone else. It's also true some teammates have more of an affinity with others, in his case he gets on really well with the other French players. With us, sometimes we have a mate, that doesn't mean you get on better or worse. He gets on really well with everyone and is well integrated, as we expected him to be."
RETIREMENT PLANS
"Maybe we will live in Barcelona, the family is really happy here. We love it here."


General Information
BxPP, made by Pynx Technologies, is a custom Python programming language.
Version: 3.0
Platforms: Linux & Windows
Installation
sudo python3 setup.py
OR
run setup.exe
BxPP, made by Pynx Technologies, is a custom Python programming language.
Version: 3.0
Platforms: Linux & Windows
sudo python3 setup.py
OR
run setup.exe


@verysuhe @MrKomodoWorld @VerusCoin yes, I did start mining $VRSC in the Days Of The Big Blocks, before FPGAs raged the network and Mike was too dumb to realize how to deal with it and pushed many core $KMD people out of the community.
Verus is a surveillance coin, can't y...


A mixed workflow (local development, local debugging, and cloud execution) with the CLI might look like this:
lean cloud pull
to pull remotely changed files.lean cloud backtest "<projectName>" --open --push
to push local changes to the cloud, run a backtest in the cloud, and open the results in the browser once finished.lean cloud push
to push all locally changed files in the organization workspace to the cloud.The advantage of this workflow is that you can use your local development environment and its debugging tools when writing your algorithms while using QuantConnect's infrastructure and data in backtesting and live trading. Although this does require you to have a local copy of the data that your strategy needs, it doesn't require you to maintain your own infrastructure and data feeds in live trading. To download some of QuantConnect's data for local usage, see Downloading Data.


Processes ELI5¶
This is a high level overview for how processes are made and how they work.
General overview¶
A process is a simple C structure, which contains a heap, a stack, registers, and an instruction pointer. Also, there are some extra fields for exception handling, tracing etc. A new process is this structure created with a minimal size heap.
Spawning a new Process (Actor)¶
When you call spawn or spawn_link, the VM allocates a small piece of memory with a new process header (approx 200-300 bytes) and the {heap with the stack} (they live together and take about 1kb initially). A new process is granted a new unique PID, which won’t repeat for a fair amount of days or months after its death, and is registered in a process lookup table.
There are no messages involved in process creation only a couple of memory allocations.
So the newly created process is not known to any scheduler yet. It is then placed into a run queue for its priority (99.99% of processes run as normal), where one of schedulers is able to pick it up and begin executing. Newer versions of Erlang have run queues one per scheduler, but the principle is the same.
Stack¶
Stack is an array of memory on the young heap used as return stack and temporary storage for variables. Stack begins at the end of the heap and grows back (downwards). The data on stack is grouped into Stack Frames.
When a function needs some temporary memory, it allocates several words on the stack and marks the 0-th word with special CP value. Later it can be used as return address and to find out where next stack frame begins. This temporary memory is also used to preserve registers during recursive calls (thus growing the stack).
Tail-recursive calls avoid keeping this temporary data or free it before recursing. They pass arguments in a smarter way that does not require saving them on stack and does not grow it.
Execution¶
Every new process is assigned to a Scheduler. Scheduler picks one process from the queue and takes its instruction pointer. Then scheduler executes one instruction and loops. After certain amount of work done (reductions) scheduler will place the current process to the back of the queue and select another one. This allows some sort of fair scheduling: every process gets CPU time no matter how busy were other processes in the queue.
Killing and Exiting¶
Killing a process is like sending it an exit exception. The process wakes up
from sleep, receives CPU time, and discovers an exception. Then it will either
terminate or catch the exception and process it like
a regular value. An unconditional kill
signal works similarly except that
Erlang code cannot catch it.
Scheduling and Load balancing¶
By default BEAM VM starts one Erlang scheduler per CPU core. Processes get a
scheduler assigned to them in some manner (for simplicity you can say it is
random). You can configure schedulers using flags +S
and +SP
. Schedulers
can be bound to cores in different ways (+sbt
flag).
There are 4 process priorities: low, normal, high and max. Process at max always runs first making everything else wait. High runs approximately 8 times much often than normal (the number is implementation dependent). Low runs when there is no other work to do.
At runtime schedulers will compare their process queue with the other (namely
the previous one in scheduler array). If the other queue is longer, the
scheduler will steal one or more processes from it. This is the default
behaviour which can be changed. The balancing strategy and can be configured
with VM flags +S
and +scl
. You could want to use as few cores as
possible to let other CPU cores sleep and save energy. Or you could prefer
equal spread of processes to cut the latency.
Stealing is as easy as moving a pointer from one array to another. This may affect cache locality when an active process jumps CPU core.
Process Registry¶
A global process table maps process identifier (pid) to a Process structure.
To know a pid of a process, refer to its Process.common.id
field. A process
is uniquely identified by its local pid. Remote pids contain more information:
a node name and internal node id. Remote pids have to be resolved on the node
which owns them.
Another global table (process registry) maps names to pid. You can reach it
from Erlang by using erlang:register
, erlang:unregister
and
erlang:whereis
BIFs.
Message Queues¶
Messages are stored on the heap or in heap fragments, and are chained together using a single linked list. Message queue is a C structure which belongs in Process struct and it contains Terms sent to the process. Boxed data for larger or nested terms is located on the heap. A pointer to position in the queue exists, and it is advanced with BEAM opcodes which scan the mailbox. When scan pointer reaches the end of the mailbox, the process is put to receive sleep. The pointer is reset to the beginning of the queue only if a message was matched. This is why selective receive on large mailbox queues is slow.
Sending a Message¶
Sending a message to a process is simple — this is how VM does it:
Lock the process mailbox (or don’t, if running on a single core).
Copy message to destination process heap.
Add the resulting term to process mailbox.
Unlock the mailbox.
If the process was sleeping in a receive, it would return back to scheduling queue and wake up when possible.
A process waiting for a message (in receive operator) is never queued for execution until a message arrives. This is why millions of idle processes can exist on a single machine without it breaking a sweat.
Traps¶
Traps are a feature of the VM loop which allow to interrupt long running BIFs temporarily. State is saved in temporary memory block and control returns to the scheduler. Process sets its instruction pointer to the special trap instruction and the BIF returns.
During the trap the current process is placed to the back of the process queue which allows other processes to run. When the time comes again, the VM loop encounters the trap instruction and jumps back to the long running BIF.


...
# Asp.net core on LINUX
## it's the future
## let's dive right in!
![Developers Developers Developers](image/ddd.jpg)
## Ballmer, 2001:
> "Linux is a cancer"
## Ballmer, 2001:
> "Linux is a cancer"
## Ballmer, 2016:
> "I may have called Linux a cancer but now I love it"
["I may have called Linux a cancer but now I love it"](http://www.zdnet.com/article/ballmer-i-may-have-called-linux-a-cancer-but-now-i-love-it)
![ballmer](image/ballmer.png)
## What changed?
# Azure
## Desktop Sales ↓
## Cloud Services ↑
Before Azure:
> Windows Server is the best thing for data centers!
After Azure:
> Here's Windows Server Core... best thing for data centers!
More Azure:
> Here's Windows Server Nano... best thing for data centers!
Today...
> We offer Linux!
## join the dots
# Microsoft is a Linux company
## Inevitable conclusion
# MS Stuff and Linux
- dotnet core
- visual studio code
- SQL Server 2016
- Service Fabric
- PowersHell
- Ubuntu on Windows 10
- Linux Azure VMs
- Silverlight for Lynx
# Why does it benefit you today?
* opens you up to a larger ecosystem
* microservices with less friction
* scaling without license problems
* drastically cheaper hosting
![before and after (secretGeek.net)](image/uptime_before_and_after_large.png)
# The old architecture
![old architecture](image/Old_Architecture.png)
# The new architecture
![new architecture](image/New_Architecture.png)
![pepe](image/red_string_wall.JPG)
**WOAH!** Lots of differences! An overwhelming number of changes. But think of all the things we've thrown away. IIS! No more IIS. Phew! No more application pools. No more terminal services. Let's take a closer look
If it feels daunting -- if you feel that "I SUCK" feeling -- then that's great! It means you're learning! It's the mental equivalent of the gym saying 'no pain no gain.' And it's amazing how quick you'll get past those initial feelings. You run each of the commands in this tutorial 2 or 3 times on your own -- you'll start to feel veeeery comfortable with it. You can acclimatize to this very quickly. It's all just typing!
There's going to be a *lot* of terminology thrown at you during this talk. It's all online at {TODO: some simple url} where it's described in a lot more detail, with links you can follow and everything -- so for now i suggest you just sit back, let it all wash over you, and you can check up on it all later if you're super keen.
(image: pepe silvia scene from "it's always sunny in philadelphia")
# The new architecture
![new architecture](image/New_Architecture.png)
There's a finite number of boxes there... nginx, Kestrel, systemd, SSH ... we'll go through each of those, carefully, and then you'll be able to put Linux on your resume. Ok there's a few concepts we'll need to cover along the way.
# Demonstration
## See [script for demo](demo/scripts.md)
* See [script for demo](demo/scripts.md)
Demo as animated gifs...
* [create droplet](ScreenToGif_Files/CreateDroplet.gif)
* [configure droplet](ScreenToGif_Files/ConfigureDroplet.gif)
* [install .net core](ScreenToGif_Files/InstallDotNetCore.gif)
* [hello world](ScreenToGif_Files/HelloWorld.gif)
* [web app](ScreenToGif_Files/WebApp.gif)
Documentation:
* Configure droplet: [Initial Server Setup with Ubuntu 16.04 (Digital Ocean)](https://www.digitalocean.com/community/tutorials/initial-server-setup-with-ubuntu-16-04)
* [An Introduction to Securing your Linux VPS (Digital Ocean)](https://www.digitalocean.com/community/tutorials/an-introduction-to-securing-your-linux-vps)
* [7 Security Measures to Protect Your Servers (Digital Ocean)](https://www.digitalocean.com/community/tutorials/7-security-measures-to-protect-your-servers)
* [Asp.net Core Publish to a Linux Production Environment (Microsoft)](https://docs.microsoft.com/en-us/aspnet/core/publishing/linuxproduction)
* [Hanselman: Publishing an ASP.NET Core website to a cheap Linux VM host](http://www.hanselman.com/blog/PublishingAnASPNETCoreWebsiteToACheapLinuxVMHost.aspx)
* get a VM at digitalocean, US$5 per month.
...or scaleway 3 euro per month, or linode,
or amazon (AWS free tier... 1 year free), or
arubacloud.com (1 euro per month) or others...
Go there, sign up, and get a machine in the cloud.
# Windows Admin in One Slide
![linux admin in one slide](image/next.gif)
# Linux Admin in One Slide
![linux admin in one slide](image/linuxadmin1.png)
# Linux Admin in One Slide
![linux admin in one slide](image/linuxadmin.png)
How sudo works
This is how you achieve a least privilege yet powerful super user on linux: with sudo. It's basically simon says. you type sudo {command}, and then it asks you for your password. So you want a long but easy to type password -- recommend a passphrase!
![how ssh works](image/how_ssh_works.png)
Bash v cmd.exe:
Similarities
| windows | bash |
cd .. | cd .. |
cd \ | cd / |
dir | ls |
copy | cp |
del | rm |
rd | rmdir |
cls | clear |
type {file} | cat {file} |
| (pipe) | | (pipe) |
stdin, stdout, stderr | stdin, stdout, stderr |
Bash v cmd.exe:
Differences
- case sensitive!
- file extensions: not relevant.
- "dot" prefix on a file: hides the file
- no drive letters. "mount" a device into a location.
- "~" means your home path. "cd" with no parameters takes you home.
- everything is a file:
- streams
- stdin, stdout, stderr,
- devices... are all files.
Bash v cmd.exe:
Other Common Things
.profile
grep
tail
top
editing config files
managing processes
# Kestrel
## Tech Empower Benchmarks
# Kestrel
## Tech Empower Benchmarks
> Thanks to Microsoft’s herculean performance tuning effort, ASP.NET—in the new cross-platform friendly form of ASP.NET Core—is now a top performer in our Plaintext test, making it among the fastest platforms at the fundamentals of web request routing. The degree of improvement is absolutely astonishing, going from 2,120 requests per second on Mono in Round 11 to 1,822,366 requests per second on ASP.NET Core in Round 13. That’s an approximately **85,900%** improvement
[TechEmpower Blog - Round 13](https://www.techempower.com/blog/2016/11/16/framework-benchmarks-round-13/)
# Revisit...
![new architecture](image/New_Architecture.png)
If you take a photo of this slide and put it in your CV, you can ride the cash cow on the back of the gravy train until the golden goose lays a license to print money all the way to eldorado, etc.
## See Also
* [The source code from our demo](demo/scripts.md)
## References
* Configure droplet: [Initial Server Setup with Ubuntu 16.04 (Digital Ocean)](https://www.digitalocean.com/community/tutorials/initial-server-setup-with-ubuntu-16-04)
* [An Introduction to Securing your Linux VPS (Digital Ocean)](https://www.digitalocean.com/community/tutorials/an-introduction-to-securing-your-linux-vps)
* [7 Security Measures to Protect Your Servers (Digital Ocean)](https://www.digitalocean.com/community/tutorials/7-security-measures-to-protect-your-servers)
* [TIL.secretGeek.net Linux section](https://til.secretgeek.net/linux/01_summary.html) in particular:
* [SSH article](https://til.secretgeek.net/linux/SSH.html)
* [nginx article](https://til.secretgeek.net/linux/nginx.html) (covers hosting multiple sites on one linux box)
* [Asp.net Core Publish to a Linux Production Environment (Microsoft)](https://docs.microsoft.com/en-us/aspnet/core/publishing/linuxproduction)
* [Hanselman: Publishing an ASP.NET Core website to a cheap Linux VM host](http://www.hanselman.com/blog/PublishingAnASPNETCoreWebsiteToACheapLinuxVMHost.aspx)
Tod and Jakob
Workshop - An Introduction to .NET Core on Linux & Docker


| | | | Return -1 or 1 when other differs from this type, zero when other is
equal to this type.
Whenter 1 or -1 is returned is consistent but unpredictable. This makes
it possible to sort types, but the resulting order is undefined.
|
| | Return TRUE when other is equal to this type, FALSE otherwise.
|
| | Return the size of the type.
This always returns the same value, which is the size of the type itself.
It does NOT return the size of the type it stores the properties of.
|
| | Return a string representation of the type.
E.g. "string", "enum Color", "object of Foo".
|
| | Return the type of the type.
This always results in the same type with the properties of a type.
|
| | Return the name of the item.
E.g. "MyModule", "FooClass", "theVar".
When the object is NIL this returns "NIL".
|
|


In which way we could be of assistance ?
If you want to simply see the showcase of our products,
you can click right here.
Or you can get in touch with us through
the button here below.
Call us at: +xx xxx-xxx-xxxx


Enumerable Discovery - grep
July 7th, 2015
Of the many popular Enumerable methods, the ones that come to mind are "map" and "select." Though these are the most popular, they are not necessarily the most powerful. In this post, I will discover the intricacies of "grep" and unveil the possibilites of this method.
Below is the basic format from the ruby docs.
enum.grep(pattern) { |obj| block} => array
The above returns an array of every element in enum for which the pattern === element. If the optional block is applied, each matching element is passed through it, and the block's result is stored in the output array.
Grep can act as a simpler select by filtering by pattern matching rather than giving a block to "select." To do this case with "select", RegExp would be needed. Instead, you can simply choose a pattern with grep:
[1,10,100,1000].grep(1..100) # => [1, 10, 100]
[1,'a',2,'b'].grep(Integer) # => [1,2]
This filtering is easy to customize. You can even use "==" to throw a single condition as a filter.
The power of the "map" method is bulk transforming and grep can does this too.
[1,2,3,4].grep(1..10){|x| x + 1}
This will add 1 to each of the integers. As you may have noticed, this also does the select functionality and limits the array to a range of 1..10. Two birds with one stone! This style of coding can be called "selective bulk transformation." Very useful!
I will briefly say that grep can be utilized even more with RegExp, but that's for another post. Hope this help you implement grep as a more formidable tool.


Starting point
Ending point
Calculate path
Movement cost:
Click and drag on the board to add obstacles.


--- categories: [] date: 2012-05-06T15:43:20Z status: publish tags: [] title: Looking at a fox out there layout: post url: /2012/05/06/looking-at-a-fox-out-there/ ---
[AFG_gallery id='1']
The pub dog 'Otto'.


Ålborg Brutal Marathon
Ålborg DEN
Website: www.marathoniaalborg.dk
Race Winners
(32 runnings)
3:39:46 3:30:05 3:29:43 3:46:44 3:41:39 06 Apr
2007
2:56:18
3:43:03
14 Apr
2006
3:00:13
3:28:22
25 Mar
2005
3:04:06
3:19:42
09 Apr
2004
3:03:58
3:37:57
18 Apr
2003
2:52:14
3:45:24
29 Mar
2002
2:54:42
3:40:33
13 Apr
2001
2:47:01
3:50:10
21 Apr
2000
2:48:06
3:11:15 1996-1999
--- ---
22 Apr 1995
2:35:52
3:39:50
23 Apr
1994
2:29:50
3:01:09
24 Apr
1993
2:31:31
2:53:12
11 Apr
1992
2:27:38
2:51:31
13 Apr
1991
2:30:55
3:08:46
07 Apr
1990
---
---
1989
---
---
1988
---
---
11 Apr
1987
---
---
1986
---
---
1985
---
---
21 Apr
1984
---
---
02 Apr
1983
---
---
10 Apr
1982
---
---
18 Apr
1981
---
3:00:03
Notes: 1981 was the inaugural year. The 1991-1995 races were known as the
Ålborg Boulevard Marathon and were organized by a different group than the
present day race organization and was held on a different course.
25 Mar
2016
2:46:09
Emil Adelborg (DEN)
3:34:27
Stine Rex-6
03 Apr
2015
3:05:36
Morten-Sort Mouritsen (DEN)
3:36:19
Stine Rex-5
18 Apr
2014
2:47:59
Søren Rasmussen (DEN)
3:25:06
Stine Rex-4
29 Mar
2013
3:07:13
Jacob-Boye Andersen (DEN)
3:50:52
Dorte Møldrup (DEN)
06 Apr
2012
2:46:00
Daniel-Arum Jensen (DEN)
Maja Petersen (DEN)
22 Apr
2011
2:41:48
David Criniti (AUS)
Melissa Selby (AUS)
03 Apr
2010
2:51:37
Peter Mousten-2
Katrine-Amtkjær Nielsen (DEN)
10 Apr
2009
2:54:24
Peter Mousten (DEN)
Janni Mosberg (DEN) + Sund Jensen (DEN)
21 Mar
2008
3:08:18
Ole Christensen (DEN)
Karen-Marie Brogger (DEN)
Reima Hartikainen (SWE)
Stine Rex-3
Kjetil Havstein-2
Stine Rex-2
Kjetil Havstein (DEN)
Stine Rex (DEN)
Mark-Linder Petersen-3
Helle Moland Mortensen (DEN)
Mark-Linder Petersen-2
Margit Hansen (DEN)
Mark-Linder Petersen (DEN)
Helle Moland Knudsen (DEN)
Kim Michaelsen-2
Inger Meldgaard (DEN)
Kim Michaelsen (DEN)
Karin Agesen (DEN)
not held
not held
Bjorn Aanansen (DEN)
Anne-Liese Larsen (DEN)
Harri Skytta-2
Tatyana Ivanova-Zolotareva (RUS)
Harri Skytta (FIN)
Mirela Ziecina (POL)
Toomas Tarm (EST)
Lidiya Chulanova (RUS)
Peter Broe (DEN)
Gitte Schultz (DEN)
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
n/a
Mette Holm (DEN)
Most Wins
(1981/date)
Men
3
Mark-Linder Petersen (DEN)
2002-04
Women
6
Stine Rex (DEN)
2005-07,2014-16
Prize Money
(ADR qualified runners)
Prize money has not been awarded at this event according to available information.
Race Time Bias
(sec/km)
Insufficient data to calculate the race time bias.
Competitive Level
(1990-date)
Insufficient data to calculate the competitive level.
Quality Performances
Men No men under 2:20 Women No women under 2:50
Last Updated on 03 Apr 2016
Contributors: Klaas Loonstra (50), Juraj Gasparovic (45), Jan-Michael Andersen


Define the responsibilities of encryption key custodians. Prepare a form that spells out these responsibilities. Ask the designated key custodians to read and sign the form.
Designate several staff members as key custodians. Have them study the relevant parts of the information security policy and key management procedures. Interview the key custodians to verify that they understand their responsibilities. Prepare a form for the key custodians to sign to acknowledge that they accept responsibility for the keys. Have the key custodians sign the forms. Include a blank copy of the form in the information security policy and the signed forms in the network documentation.


Nice to meet you! I’m Ellen, and I like building beautiful, useful things. I'm a Data Visualization Specialist for the U.S. Geological Service.
I studied geology and environmental science at Wellesley College, ran a science-and-art communication contest for teens, wrenched on bikes at a cooperative bike shop, painted bikes out of my garage, and designed graphics for custom titanium bicycles.
I’m almost done with my my MS in Information Design and Visualization at Northeastern University here in Boston. All of that has mushed together into my dream job here at the USGS, where I make data beautiful.
Founded a cybersecurity club in my university. Conducted various sessions, workshops and talks on cybersecurity topics such as Web-Exploitation, Introduction to Bug-bounty programs, CTF challenges and so on.
Founded a chess club in my university during my sophomore year.
Started writing blogs on technical as well as non-technical content.
 Conducted several hackathons and workshops during my tenure.
During my sophomore year, created a gym management system
using various sorting and seaching algorithms in C language.


Enumerables
First of all. What in the world is an enumerable?? Enumerable is a class that is a group of methods that are useful when traversing, searching, and sorting through some data. There are many methods available within this class that allow this iteration such as sort_by (which I learned about at great length this week) and map, which I will go into further detail about. These methods usually have two forms - one that has an object and a block and one that does not have a block, where an enumerator is returned. These enumerable methods are all based off of the each method.
Enumerable#map
The map method is fun in that it allows you to do some action (block) on a group or collection of elements such as in an array. Block is run once for each element in the group and an array is the output. When no block is given an enumerator array is returned. Map is useful because you can modify the group of elements and return it without changing the original one. When using each you would have to iterate through each element, perform the action inside the each, and then return the result. Map actually alters the elements as it iterates through them. Woohoo!
Here are some examples
original_array = [1,2,3,4] original_array.map{|x| x*3} #=> [3, 6, 9, 12] original_array #=> [1, 2, 3, 4]
The block in this example is "x*3 and the object is x". Map iterates through each element in the original_array and performs the block on it. For each element, the result of block is returned in the new array. You can then see that the original array was not modified by returning it.
new_array = (1..5).map{"test"} #=> ["test", "test", "test", "test", "test"]
This example does not have a block so we set the number of times to iterate through the object (5 times). The result is an enumerator with the object repeated 5 times. In this case I set it to new_array, which can then be used later as a variable.
To read more about this method, check out http://ruby-doc.org/core-2.1.2/Enumerable.html#method-i-map and for a great explanation of why you use it and how look at http://ruby.bastardsbook.com/chapters/enumerables#h-2-2


Generate an OAuth request token to be granted access.
Redirect you to Twitter.com using our tokens from step 1. You'll then be prompted to authorize the app.
Once authorized, you'll then be redirected back to the Hello Twitter application.
Disclaimers:
The Twitter Developer API currently offers 3 tiers of search APIs (standard, premium, enterprise). We're using the standard platform which only supports 7 days of history.


--- layout: post title: 2019-07-25-Relaxing-in-the-Calanques.jpg date: 2019-07-25 14:24:17 permalink: /assets/html/gallery/2019-07-25-Relaxing-in-the-Calanques.jpg.html exclude: true ---


type Language = Elixir | Elm | Both
perks: Language -> String
perks language =
case language of
Elixir -> "Easy concurrency!"
Elm -> "No runtime errors!"
Both -> "Elchemy"
npm install -g elchemy
cd your_elixir_project
elchemy init


The X radius of the left-bottom corner of the Rect.
The Y radius of the left-bottom corner of the Rect.
The X radius of the left-top corner of the Rect.
The Y radius of the left-top corner of the Rect.
The X radius of the right-bottom corner of the Rect.
The Y radius of the right-bottom corner of the Rect.
The X radius of the right-top corner of the Rect.
The Y radius of the right-top corner of the Rect.
The X coordinate of the left-top corner of the Rect.
The X coordinate of the right-bottom corner of the Rect.
The Y coordinate of the left-top corner of the Rect.
The Y coordinate of the right-bottom corner of the Rect.
Calculate the inner RoundRect by current instance and give borders in 4 directions.
top border.
right border.
bottom border.
left border.
The current instance if all borders are 0, or a new RoundRect object which presents the result of current instance applies the borders.
Apply the given radius of 4 corners.
radius in top-left corner.
height in top-right corner.
radius in bottom-right corner.
radius in bottom-left corner.
The current instance. Useful for chaining method calls.
Apply the given size.
width of new size.
height of new size.
The current instance. Useful for chaining method calls
Adds a circular arc to the current sub-path, using the given control points and radius.
The X coordinate of the source point.
The Y coordinate of the source point.
The X coordinate of the destination point.
The Y coordinate of the destination point.
The rendering context of target canvas.
The current instance. Useful for chaining method calls.
Make a clip of current RoundRect object to a canvas.
The rendering context of target canvas.
The current instance. Useful for chaining method calls.
Makes a path of current RouncRect object.
The rendering context of target canvas.
If true, start a new path, otherwise continue the previous path.
The directions of the path.
Convert current RoundRect object to a Rect object by dropping radius.
a Rect object with same position and size.
Generated using TypeDoc
This class represents an rectangle object which contains start point (x, y) and size (width, height) with radius in four corners.


I am currently a consultant for Perficient in Saint Louis, MO.
I am working with the AI National Business Unit that works with customers across the country.
My passion is with hard challenges with no predefined solution which is what brought me to programming but even more so AI.
I love what I do which is why I have plenty of time and energy to continue on my side projects.
This allows me to build my skillset since I have built many projects from the ground up on my own.
I have a lot of experience with learning new things on my own as that is how I built ~80% of my knowledge base.


BlueJet
Blue jet is a rare type of a lightning with a very blue colour with near-ultraviolet emission lines from neutral and ionized molecular nitrogen. It typically occurs in the lower levels of ionosphere at ~50km above the surface of the earth.
Synopsis
BlueJet is a modern Swift/Cocoa wrapper around Lightning Memory-Mapped Database Manager (LMDB). It fully utilises the multi-threaded access, transations and provides a simple enumeration interface for fetching subsets of the database. Key/Value pairs are using Swift’s Encoder/Decoder protocol when dealing with the data.
What is LMDB?
LMDB is an incredibly fast key-value store written by Howard Chu for the OpenLDAP project. Given the nature of LDAP workloads the design of LMDB is read-optimised (but writes are super fast too!). This particular database allows for multiple databases within one environment which makes separating different data sets much easier to handle. It also allows for multiple processes to access a single database without locking it and supports transactions for making series of fail-safe reads/write routines. For more details on the design and implementation of LMDB go to [HERE].
Installation
Carthage
Add BlueJet to your Cartfile:
github "bobek-balinek/BlueJet"
Then run:
carthage update --use-submodules
Swift Package Manager
TODO
Basic Usage
TODO
Documentation
TODO
Contributing
See CONTRIBUTING.md for more details!
This project adheres to the Code of Conduct.
License
BlueJet
is available under the MIT license. See the LICENSE files for more info.


Fabulous croissants! If you have ever had croissants from the grocery store or an ordinary bakery, you have not had croissants. These are flaky, buttery deliciousness. Can't wait to try other…
- morgan or something
i guess it's kind of vaguely food-like though
just kidding it's not actually food
it's a rock


My name is Sihong and I'm an aspiring web developer currently participating in Development Boot Camp where I will mainly be working with Ruby on Rails, Javascript, HTML & CSS.
Email: sihongspring2011@gmail.com


@@include('./src/components/head.html')
@@include("src/components/work-header.html", {
"class": "mg-work_categories",
"header": "PinWall",
"text": "Web Development"
})
@@include('src/components/work-article/article-about.html', {
"text": "PinWall is the easy way to hire the right professionals. Tools used:
Bootstrap Grid
SASS preprocessor
jQuery for validation forms
icomoon.io for creating font with SVG icon"
})
@@include("src/components/work-article/article-paggy.html",{
"prev-url": "work-article-1.html",
"next-url": "work-article-3.html"
})
@@include("src/components/cta-section.html")
@@include('./src/components/page-footer.html')


Extra small
Visible on x-small
Small
Visible on small
Medium
Visible on medium
Large
Visible on large


solarcity
Businessmodel of SolarCity
Customer Segments
SolarCity has a segmented market business model, with customers who have slightly different needs:
- Residential – Homeowners, including those in communities established by homebuilders SolarCity has partnered with.
- Commercial – Organizations of all sizes and in a wide variety of industries, including retail, technology, manufacturing, agriculture, and non-profit.
- Government – Local, state, and federal government entities, including the Army, Navy, Marines, Air Force, the Department of Homeland Security, and numerous schools and universities. ### Value Proposition
SolarCity offers four primary value propositions: price, convenience, performance, and brand/status.
The company makes it possible for customers to install solar systems and lease the technology for a relatively low cost. It accomplishes this by making deals with major corporations to finance the manufacture of the systems and by packaging the leases into bonds that can be bought by individual investors. These corporations include Goldman Sachs, Google, Bank of America, and Honda. The financing enables SolarCity to offer repairs and a production guarantee at no extra cost.
The company offers convenience by providing multiple payment arrangements. These include a fixed monthly fee and a fee based on amount of energy produced. It also makes obtaining and maintaining a solar system simple by overseeing all aspects of the process – from financing to design to permits to installation to monitoring. This means that customers only have to deal with one point of contact. Lastly, the system makes monitoring easy by providing a real-time display of energy consumption.
The company has demonstrated strong performance. It installs more solar power systems than any other firm in the U.S., completing more than 110,000 new installations in 2015 alone. It estimates that the average SolarCity system will offset 178 tons of carbon dioxide over a period of 30 years (the amount of fuel necessary to drive 390,300 miles).
The company has a strong brand due to its success. It was one of the first entrants in the solar leasing sector, making it well-established. It bills itself as America’s top solar power provider, with over 230,000 customers in 27 states. Beyond consumers, clients include over 400 schools, government entities such as the U.S. Department of Homeland Security and the Armed Forces, and major corporations such as Intel, HP, eBay, Wal-Mart, and Walgreens. SolarCity has been recognized with many honors, including placement on lists such as the “Top 10 Most Innovative Companies of 2015 in Energy“ (Fast Company), the “50 Smartest Companies of 2015“ (MIT Technology Review), and the “20 Most Inspiring Companies of 2014“ (Business Insider).
Channels
SolarCity has a national sales organization that consists of four main channels: a direct outside sales team, internal call centers, a door-to-door sales force, and a channel partner network. It also relies on a customer referral program called Solar Ambassador. The company promotes its offering through a wide variety of techniques, including magazine and newspaper ads, radio ads and public radio sponsorships, search engine marketing, online banner ads, e-mail marketing, direct mail, social media, contests such as sweepstakes, and participation in events such as trade and home shows.
Customer Relationships
SolarCity’s customer relationship is primarily of a self-service, automated nature. Customers utilize the system while having limited interaction with employees. The company’s website provides numerous self-help resources, including white papers, reports on the solar industry, and answers to frequently asked questions. That said, there is a personal assistance component in the form of phone and e-mail support.
Key Activities
SolarCity’s business model entails designing, developing, and installing its systems. The company buys key system components from various manufacturers. Its main solar panel suppliers are Trina Solar Limited, Canadian Solar, AUO Green Energy America, Hanwa Qcells America. REC Americas, and Kyocera Solar. Its main inverter suppliers are SolarEdge Technologies, ABB, Fronius USA, and Solectria Renewables. Its mounting and racking systems are manufactured by its Zep Solar subsidiary.
Key Partners
SolarCity has a channel partner network that assists in the sales of its products; partners include:
The Home Depot – SolarCity is the exclusive solar panel provider in the chain’s stores. It sells them through field energy specialists and promotes them through point-of-purchase displays, in-store flyers, retail signage, seminars, and a co-branded website.
Best Buy – SolarCity sells its products in the chain’s stores, providing representatives who assess the possibility of installing a residential system for consumers.
Homebuilder Partners – The company sells its products through a variety of national and regional new home builders, including Pulte, Shea Homes, Del Webb, and Taylor Morrison. They promote the offerings through a variety of techniques, including community signage, newspaper inserts, realtor e-mails, co-branded flyers, online banners, and in-home advertising.
Other Channel Partners – The company sells its products through its relationships with Tesla Motors, Honda, Direct Energy, BMA, and Acura.
SolarCity also operates the Solar Ambassador Program, a network marketing program that invites individuals to promote the benefits of its offering and solar energy in general to their associates. Members receive cash rewards for referrals that result in new installations.
Key Resources
SolarCity’s main human resources are its in-house engineering employees that design and develop its systems and its experienced installation team. Its proprietary software platforms enable sales management, project management, site detail collection, and home energy consumption monitoring. The company places a high priority on its intellectual property, and as of December 2015 it had 76 completed patents and 250 pending patent applications. Lastly, SolarCity has more than 80 operations and maintenance facilities, which allow it to complete many annual installations.
Cost Structure
SolarCity has an “economies of scale” structure, with costs per unit dropping as output expands. Its position as the top solar panel installer in the U.S. enables it to achieve these economies in installation and capital costs. It aims to lower its cost per watt to $2.30 by 2017 and to $2.00 by 2019. The company’s biggest cost driver is sales/marketing expenses, a fixed cost. Other major drivers are in the areas of administration and research and development, both fixed expenses.
Revenue Streams
SolarCity has two revenue streams:
- Revenue from operating leases and solar energy systems incentives
- Revenue from solar energy systems and component sales


Oh look! I did some things.
ToughLove provides people harsh heart-to-heart that fit their current mood or emotional state. When the user invokes the skill for the first time, it introduces how the skill came about and how to use it. The skill is designed to lift the user's spirits with quick advice or storytelling.
As a conversation designer, I wanted the experience of the end-user to be intuitive and simple but with an emphasis on entertainment. Fortunately, I already had someone in mind to be the "voice" of ToughLove, rather than rely on Alexa's not-so-warm or anthropomorphized voice. A big thanks to the real Mrs. B from Jersey City! 💪🏼
Tools: VoiceFlow, LucidChart, Audacity, and my comedy skills
This chatbot is powered by DialogFlow's NLP and NLU processes to facilitate rich and natural conversations. I expanded the knowledge base of understandings and trained them to map to the right intent. 🤖
Tools: DialogFlow, Botcopy, Calendly API
As an language teacher, linguist, and now conversation designer, I'm hoping to share my experiences and knowledge to anyone who's open to learning. More info about language and its quirks in 2022! 🙂


"""This module provides a number of classes (and functions to help create those
classes) useful for computing quantities required by DISORT that are commonly
found in an observation.
"""
# TODO: In Python3.10, they should disable evaluation of type hints. Currently,
# ArrayLike evaluates to Sequence[Sequence[Sequence[...]. After that, I can
# remove the __future__ import. See also
# https://stackoverflow.com/questions/67473396/shorten-display-format-of-python-type-annotations-in-sphinx
# TODO: warn if emission > 90 if orbiter?
from __future__ import annotations
import numpy as np
from numpy.typing import ArrayLike
[docs]class Angles:
r"""A data structure that contains angles required by DISORT.
It accepts both the incidence and azimuth angles of the incident beam
as well as emission and azimuth angles from an observation. It holds
these values and computes both :math:`\mu_0` and :math:`\mu` from these
angles.
This class can compute all angular quantities required by DISORT at once,
even multiple observations. Both :code:`incidence` and :code:`beam_azimuth`
must have the same shape (the "beam measurement shape"), representing
measurements at different incident beams. Both :code:`emission` and
:code:`azimuth` must have that same shape with an additional axis at the
end, representing the angular grid at the corresponding incident beams. The
length of this final axis can be different for both of these inputs.
See the notes section for discussion of multiple cases.
Parameters
----------
incidence
Incidence (solar zenith) angles [degrees]. All values must be between 0
and 90.
beam_azimuth
Azimuth angles of the incident beam [degrees]. All values must be
between 0 and 360.
emission
Emission (emergence) angles [degrees]. All values must be between 0 and
180.
azimuth
Azimuth angles [degrees]. All values must be between 0 and 360.
Raises
------
TypeError
Raised if the input arrays contain nonnumerical values.
ValueError
Raised if any values of the input arrays are outside their
mathematically valid range, or if the inputs do not have the same beam
measurement shape.
See Also
--------
phase_to_angles: Create instances of this class if phase angles are known
but azimuth angles are unknown.
sky_image: Create instances of this class from a single sky image.
Notes
-----
In the case of a rover taking a single image from the surface along an MxN
emission and azimuth angle grid, the image is taken with a single incident
beam. Thus, :code:`incidence` and :code:`beam_azimuth` should be scalars (or
single valued arrays) whereas :code:`emission` should have shape (1, M) and
:code:`azimuth` should have shape (1, N).
In the case of an orbiter taking an MxN image, each is pixel is illuminated
by a different incident beam. In this case :code:`incidence` and
:code:`beam_azimuth` should have shape (M, N) whereas :code:`emission` and
:code:`azimuth` should have shape (M, N, 1).
DISORT wants a float for :code:`UMU0` and :code:`PHI0`; it wants a 1D array
for :code:`UMU` and :code:`PHI`. Selecting the proper indices from the
beam measurement axes is necessary to get these data types.
Examples
--------
Import the relevant modules
>>> import numpy as np
>>> from pyrt.observation import Angles
Instantiate this class for a (3, 5) sky image taken along an emission and
azimuth angle grid, with a single incident beam.
>>> incidence = 30
>>> beam_azimuth = 40
>>> emission = np.linspace(30, 60, num=3)[np.newaxis, :]
>>> azimuth = np.linspace(20, 50, num=5)[np.newaxis, :]
>>> Angles(incidence, beam_azimuth, emission, azimuth)
Angles:
mu0 = [0.8660254]
phi0 = [40]
mu = [[0.8660254 0.70710678 0.5 ]]
phi = [[20. 27.5 35. 42.5 50. ]]
Instantiate this class for a sequence of 50 (3, 5) images taken from a fixed
position over a period time where the incidence angle and beam azimuth angle
varied from image to image.
>>> incidence = np.linspace(30, 35, num=50)
>>> beam_azimuth = np.linspace(40, 50, num=50)
>>> emission = np.broadcast_to(np.linspace(30, 60, num=3), (50, 3))
>>> azimuth = np.broadcast_to(np.linspace(20, 50, num=5), (50, 5))
>>> angles = Angles(incidence, beam_azimuth, emission, azimuth)
>>> angles.mu0.shape, angles.phi0.shape, angles.mu.shape, angles.phi.shape
((50,), (50,), (50, 3), (50, 5))
Instantiate this class for a (40, 50) image where each pixel was illuminated
by a unique incident beam.
>>> ang = np.outer(np.linspace(1, 2, num=40), np.linspace(10, 40, num=50))
>>> angles = Angles(ang, ang, ang[..., np.newaxis], ang[..., np.newaxis])
>>> angles.mu0.shape, angles.phi0.shape, angles.mu.shape, angles.phi.shape,
((40, 50), (40, 50), (40, 50, 1), (40, 50, 1))
"""
def __init__(self, incidence: ArrayLike, beam_azimuth: ArrayLike,
emission: ArrayLike, azimuth: ArrayLike):
self._bundle = \
_RoverAngleBundle(incidence, beam_azimuth, emission, azimuth)
self._mu0 = self._compute_mu0()
self._mu = self._compute_mu()
def __str__(self):
return f'Angles:\n' \
f' mu0 = {self.mu0}\n' \
f' phi0 = {self.phi0}\n' \
f' mu = {self.mu}\n' \
f' phi = {self.phi}'
def __repr__(self):
return self.__str__()
def _compute_mu0(self) -> np.ndarray:
return self._bundle.incidence.cos()
def _compute_mu(self) -> np.ndarray:
return self._bundle.emission.cos()
@property
def mu0(self) -> np.ndarray:
r"""Get :math:`\mu_0`---the cosine of ``incidence``.
Notes
-----
Each element along the observation dimension(s) is named :code:`UMU0` in
DISORT.
"""
return self._mu0
@property
def mu(self) -> np.ndarray:
r"""Get :math:`\mu`---the cosine of ``emission``.
Notes
-----
Each element along the observation dimension(s) is named :code:`UMU` in
DISORT.
"""
return self._mu
@property
def phi0(self) -> np.ndarray:
r"""Get :math:`\phi_0`---the azimuth angles of the incident beam
[degrees] (the input to :code:`beam_azimuth`).
Notes
-----
Each element along the observation dimension(s) is named :code:`PHI0` in
DISORT.
"""
return self._bundle.beam_azimuth
@property
def phi(self) -> np.ndarray:
r"""Get :math:`\phi`---the azimuth angles [degrees] (the input to
:code:`azimuth`).
Notes
-----
Each element along the observation dimension(s) is named :code:`PHI` in
DISORT.
"""
return self._bundle.azimuth
# TODO: Is there a cleaner way to compute this?
[docs]def make_azimuth(incidence: ArrayLike, emission: ArrayLike,
phase: ArrayLike) -> np.ndarray:
r"""Construct azimuth angles from a set of incidence, emission, and phase
angles.
Parameters
----------
incidence
Incidence (solar zenith) angles [degrees]. All values must be between 0
and 90.
emission
Emission (emergence) angles [degrees]. All values must be between 0 and
180.
phase
Phase angles [degrees]. All values must be between 0 and 180.
Raises
------
TypeError
Raised if any values in the input arrays are nonnumerical.
ValueError
Raised if any values of the input arrays are outside their
mathematically valid range or if the input arrays do not have the same
shapes.
Examples
--------
Create the azimuth angles from an assortment of angles.
>>> import numpy as np
>>> from pyrt.observation import make_azimuth
>>> incidence_angles = np.array([20, 30, 40])
>>> emission_angles = np.array([30, 40, 50])
>>> phase_angles = np.array([25, 30, 35])
>>> make_azimuth(incidence_angles, emission_angles, phase_angles)
array([122.74921226,<PHONE_NUMBER>6,<PHONE_NUMBER>6])
"""
bundle = _OrbiterAngleBundle(incidence, emission, phase)
with np.errstate(divide='ignore', invalid='ignore'):
tmp_arg = (np.true_divide(
bundle.phase.cos() - bundle.emission.cos() * bundle.incidence.cos(),
bundle.emission.sin() * bundle.incidence.sin())).to_ndarray()
tmp_arg[~np.isfinite(tmp_arg)] = -1
d_phi = np.arccos(np.clip(tmp_arg, -1, 1))
return 180 - np.degrees(d_phi)
[docs]def phase_to_angles(incidence: ArrayLike, emission: ArrayLike,
phase: ArrayLike) -> Angles:
r"""Construct an instance of Angles in the case where phase angles are
known but azimuth angles are unknown.
Parameters
----------
incidence
Incidence (solar zenith) angles [degrees]. All values must be between 0
and 90.
emission
Emission (emergence) angles [degrees]. All values must be between 0 and
180.
phase
Phase angles [degrees]. All values must be between 0 and 180.
Raises
------
TypeError
Raised if any values in the input arrays are nonnumerical.
ValueError
Raised if any values of the input arrays are outside their
mathematically valid range or if the input arrays do not have the same
shapes.
Examples
--------
For a random assortment of input angles:
>>> import numpy as np
>>> from pyrt.observation import phase_to_angles
>>> incidence = [20, 30, 40]
>>> emission = [30, 40, 50]
>>> phase = [25, 30, 35]
>>> phase_to_angles(incidence, emission, phase)
Angles:
mu0 = [0.93969262 0.8660254 0.76604444]
phi0 = [0. 0. 0.]
mu = [[0.8660254 ]
[0.76604444]
[0.64278761]]
phi = [[122.74921226]
[129.08074256]
[131.57329276]]
"""
bundle = _OrbiterAngleBundle(incidence, emission, phase)
phi = make_azimuth(bundle.incidence, bundle.emission, bundle.phase)
phi0 = np.zeros(bundle.phase.shape)
return Angles(bundle.incidence, phi0,
bundle.emission[..., np.newaxis], phi[..., np.newaxis])
[docs]def sky_image(incidence: float, beam_azimuth: float, emission: ArrayLike,
azimuth: ArrayLike) -> Angles:
"""Create an instance of Angles from a typical sky image---that is, a single
incidence and beam azimuth angle are known, and the observational geometry
defines a 1D array of emission and azimuth angles.
Parameters
----------
incidence
Incidence (solar zenith) angle [degrees]. Value must be between 0 and
90.
beam_azimuth
Azimuth angle of the incident beam [degrees]. Value must be between 0
and 360.
emission
Emission (emergence) angle [degrees]. All values must be between 0 and
180.
azimuth
Azimuthal angle [degrees]. All values must be between 0 and 360.
Raises
------
TypeError
Raised if any values in the input arrays are nonnumerical.
ValueError
Raised if any values of the input arrays are outside their
mathematically valid range, or if the inputs do not have the same beam
measurement shape.
Examples
--------
Create an instance of Angles for a (3, 5) sky image with a single incident
beam.
>>> import numpy as np
>>> from pyrt.observation import sky_image
>>> incidence = 30
>>> beam_azimuth = 40
>>> emission = np.linspace(30, 60, num=3)
>>> azimuth = np.linspace(20, 50, num=5)
>>> sky_image(incidence, beam_azimuth, emission, azimuth)
Angles:
mu0 = [0.8660254]
phi0 = [40]
mu = [[0.8660254 0.70710678 0.5 ]]
phi = [[20. 27.5 35. 42.5 50. ]]
"""
incidence = _IncidenceAngles(incidence)
beam_azimuth = _AzimuthAngles(beam_azimuth)
emission = _EmissionAngles(emission)[np.newaxis, ...]
azimuth = _AzimuthAngles(azimuth)[np.newaxis, ...]
return Angles(incidence, beam_azimuth, emission, azimuth)
[docs]class Spectral:
"""A data structure that contains spectral information required by DISORT.
It accepts the short and long wavelengths from an observation and computes
their corresponding wavenumbers. It can accommodate arrays of any shape as
long as they have the same shape.
Parameters
----------
short_wavelength
The short wavelength [microns] of each spectral bin.
long_wavelength
The long wavelength [microns] of each spectral bin.
Raises
------
TypeError
Raised if any values in the input arrays are nonnumerical.
ValueError
Raised if either of the input arrays are not the same shape, if any
values in ``short_wavelength`` are not larger than the corresponding
values in ``long_wavelength``, or if either of the input arrays
contain values outside of 0.1 to 50 microns (I assume this is the
valid range to do retrievals).
Notes
-----
If you do not plan to use thermal emission, there is probably little benefit
to making an instance of this class. See
:py:class:`~pyrt.radiation.ThermalEmission` for a discussion on thermal
radiation in DISORT.
See Also
--------
constant_width: Create instances of this class if the wavelengths are
equally spaced.
Examples
--------
Import the relevant modules
>>> import numpy as np
>>> from pyrt.observation import Spectral
Instantiate this class for a simple set of wavelengths.
>>> short = np.array([9, 10])
>>> long = short + 1
>>> Spectral(short, long)
Spectral:
low_wavenumber = [1000.<PHONE_NUMBER>9]
high_wavenumber = [1111.11111111 1000. ]
Instantiate this class for measurements taken at 1 to 30 microns in 1 micron
increments, with each channel having a 50 nm spectral width.
>>> center = np.linspace(1, 30, num=30)
>>> half_width = 0.05 / 2
>>> wavelengths = Spectral(center - half_width, center + half_width)
>>> wavelengths.low_wavenumber.shape
(30,)
Instantiate this class for an image of shape (50, 60), where each pixel
contains the same 20 wavelengths---wavelengths that span 1 to 20 microns in
1 micron increments with each channel having a 50 nm spectral width. Note
that this is not memory efficient, as each pixel along the "measurement
shape" contains the same information, but it may be useful for keeping
as many arrays as possible equally shaped.
>>> center = np.linspace(1, 20, num=20)
>>> half_width = 0.05 / 2
>>> wav_grid = np.broadcast_to(center, (50, 60, 20))
>>> wavelengths = Spectral(wav_grid - half_width, wav_grid + half_width)
>>> wavelengths.low_wavenumber.shape
(50, 60, 20)
>>> np.array_equal(wavelengths.low_wavenumber[0, 0, :],
... wavelengths.low_wavenumber[9, 17, :])
True
"""
def __init__(self, short_wavelength: ArrayLike,
long_wavelength: ArrayLike):
self._bundle = _WavelengthBundle(short_wavelength, long_wavelength)
self._high_wavenumber = self.__calculate_high_wavenumber()
self._low_wavenumber = self.__calculate_low_wavenumber()
def __str__(self):
return f'Spectral:\n' \
f' low_wavenumber = {self._low_wavenumber}\n' \
f' high_wavenumber = {self._high_wavenumber}'
def __repr__(self):
return self.__str__()
def __calculate_high_wavenumber(self) -> np.ndarray:
return self._bundle.short.to_wavenumber()
def __calculate_low_wavenumber(self) -> np.ndarray:
return self._bundle.long.to_wavenumber()
@property
def high_wavenumber(self) -> np.ndarray:
r"""Get the high wavenumber [cm :sup:`-1`]---the wavenumber
corresponding to ``short_wavelength``.
Notes
-----
Each element along the observation dimension(s) is named :code:`WVNMHI`
in DISORT. It is only needed by DISORT if
:py:attr:`~pyrt.radiation.ThermalEmission.thermal_emission` is set to
:code:`True`.
"""
return self._high_wavenumber
@property
def low_wavenumber(self) -> np.ndarray:
r"""Get the low wavenumber [cm :sup:`-1`]---the wavenumber corresponding
to ``long_wavelength``.
Notes
-----
Each element along the observation dimension(s) is named :code:`WVNMLO`
in DISORT. It is only needed by DISORT if
:py:attr:`~pyrt.radiation.ThermalEmission.thermal_emission` is set to
:code:`True`.
"""
return self._low_wavenumber
[docs]def constant_width(center_wavelength: ArrayLike, width: float) -> Spectral:
"""Create an instance of Spectral assuming the wavelengths all have a
constant spectral width.
Parameters
----------
center_wavelength
The center wavelength [microns] of each spectral bin.
width
The width of each spectral bin.
Raises
------
TypeError
Raised if any values in the input arrays are nonnumerical.
ValueError
Raised if the inputs contain values outside of 0.1 to 50 microns (I
assume this is the valid range to do retrievals).
Examples
--------
Create an instance of Spectral for an observation taken at 1 to 3 microns
in 1 micron increments, with each channel having a 50 nm spectral width.
>>> import numpy as np
>>> from pyrt.observation import constant_width
>>> center = [1, 2, 3]
>>> width = 0.05
>>> constant_width(center, width)
Spectral:
low_wavenumber = [9756.09756098 4938.27160494 3305.78512397]
high_wavenumber = [10256.41025641 5063.29113924 3361.34453782]
"""
half = width / 2
center = _Wavelength(center_wavelength, 'center_wavelength')
return Spectral(center - half, center + half)
class _Angles(np.ndarray):
"""An abstract base class for designating that an input represents angles.
Parameters
----------
array
Any array of angles.
name
The name of the angular array.
low
The lowest value any value in the array is allowed to be.
high
The highest value any value in the array is allowed to be.
Raises
------
TypeError
Raised if any values in the input array are nonnumerical.
ValueError
Raised if any values in the input array are outside the input range.
"""
def __new__(cls, array: ArrayLike, name: str, low: float, high: float):
obj = np.asarray(array).view(cls)
obj.name = name
obj.low = low
obj.high = high
obj = cls.__add_dimension_if_array_is_shapeless(obj)
cls.__raise_value_error_if_array_is_not_in_input_range(obj)
return obj
def __array_finalize__(self, obj: np.ndarray):
if obj is None:
return
self.name = getattr(obj, 'name', None)
self.low = getattr(obj, 'low', None)
self.high = getattr(obj, 'high', None)
@staticmethod
def __add_dimension_if_array_is_shapeless(obj):
if obj.shape == ():
obj = obj[None]
return obj
@staticmethod
def __raise_value_error_if_array_is_not_in_input_range(obj) -> None:
if not np.all(((obj.low <= obj) & (obj <= obj.high))):
message = f'All values in {obj.name} must be between ' \
f'{obj.low} and {obj.high} degrees.'
raise ValueError(message)
def sin(self) -> _Angles:
"""Compute the sine of the input angles.
"""
return np.sin(np.radians(self))
def cos(self) -> _Angles:
"""Compute the cosine of the input angles.
"""
return np.cos(np.radians(self))
def to_ndarray(self) -> np.ndarray:
"""Turn this object into a generic ndarray.
"""
return np.array(self)
class _IncidenceAngles(_Angles):
"""Designate that an input array represents incidence (solar zenith) angles.
Parameters
----------
array
Any array of incidence angles [degrees]. Must be between 0 and 90.
Raises
------
TypeError
Raised if any values in the input array are nonnumerical.
ValueError
Raised if any values in the input array are not between 0 and 90.
"""
def __new__(cls, array: ArrayLike):
obj = super().__new__(cls, array, 'incidence', 0, 90)
return obj
class _EmissionAngles(_Angles):
"""Designate that an input array represents emission (emergence) angles.
Parameters
----------
array
Any array of emission angles [degrees]. Must be between 0 and 180.
Raises
------
TypeError
Raised if any values in the input array are nonnumerical.
ValueError
Raised if any values in the input array are not between 0 and 180.
"""
def __new__(cls, array: ArrayLike):
obj = super().__new__(cls, array, 'emission', 0, 180)
return obj
class _PhaseAngles(_Angles):
"""Designate that an input array represents phase angles.
Parameters
----------
array
Any array of phase angles [degrees]. Must be between 0 and 180.
Raises
------
TypeError
Raised if any values in the input array are nonnumerical.
ValueError
Raised if any values in the input array are not between 0 and 180.
"""
def __new__(cls, array: ArrayLike):
obj = super().__new__(cls, array, 'phase', 0, 180)
return obj
class _AzimuthAngles(_Angles):
"""Designate that an input array represents azimuth angles.
Parameters
----------
array
Any array of angles [degrees]. Must be between 0 and 360.
Raises
------
TypeError
Raised if any values in the input array are nonnumerical.
ValueError
Raised if any values in the input array are not between 0 and 360.
"""
def __new__(cls, array: ArrayLike):
obj = super().__new__(cls, array, 'azimuth', 0, 360)
return obj
class _OrbiterAngleBundle:
"""Designate a collection of angles that represent those found in an
orbiter observation as being linked.
Parameters
----------
incidence
Incidence (solar zenith) angles [degrees]. All values must be between 0
and 90.
emission
Emission (emergence) angles [degrees]. All values must be between 0 and
180.
phase
Phase angles [degrees]. All values must be between 0 and 180.
Raises
------
TypeError
Raised if any values in the input arrays are nonnumerical.
ValueError
Raised if any values of the input arrays are outside their
mathematically valid range, or if the input arrays do not have the same
shapes.
"""
def __init__(self, incidence: ArrayLike, emission: ArrayLike,
phase: ArrayLike):
self.incidence = _IncidenceAngles(incidence)
self.emission = _EmissionAngles(emission)
self.phase = _PhaseAngles(phase)
self.__raise_value_error_if_angle_shapes_do_not_match()
def __raise_value_error_if_angle_shapes_do_not_match(self) -> None:
if not (self.incidence.shape == self.emission.shape ==
self.phase.shape):
message = f'The shapes of the arrays must match. They are ' \
f'{self.incidence.shape}, {self.emission.shape}, and ' \
f'{self.phase.shape}'
raise ValueError(message)
class _RoverAngleBundle:
"""Designate a collection of angles that represent those found in a rover
observation as being linked.
Parameters
----------
incidence
Incidence (solar zenith) angles [degrees]. All values must be between 0
and 90.
emission
Emission (emergence) angles [degrees]. All values must be between 0 and
180.
azimuth
Azimuth angles [degrees]. All values must be between 0 and 360.
beam_azimuth
Azimuth angles of the incident beam [degrees]. All values must be
between 0 and 360.
Raises
------
TypeError
Raised if any values in the input arrays are not numeric.
ValueError
Raised if any values of the input arrays are outside their
mathematically valid range, or if the inputs do not have the same
observation shape.
"""
def __init__(self, incidence: ArrayLike, beam_azimuth: ArrayLike,
emission: ArrayLike, azimuth: ArrayLike):
self.incidence = _IncidenceAngles(incidence)
self.beam_azimuth = _AzimuthAngles(beam_azimuth)
self.emission = _EmissionAngles(emission)
self.azimuth = _AzimuthAngles(azimuth)
self.__raise_value_error_if_beam_measurement_dimensions_do_not_match()
def __raise_value_error_if_beam_measurement_dimensions_do_not_match(self) \
-> None:
if not (self.incidence.shape == self.beam_azimuth.shape ==
self.emission.shape[:-1] == self.azimuth.shape[: -1]):
message = f'The incident beam measurement dimension of the ' \
f'arrays must match. They are {self.incidence.shape}, ' \
f'{self.beam_azimuth.shape},' \
f'{self.emission.shape[:-1]}, and ' \
f'{self.azimuth.shape[:-1]}.'
raise ValueError(message)
class _Wavelength(np.ndarray):
"""Designate that an input array represents wavelengths.
Parameters
----------
array
Array of wavelengths. Must be between 0.1 and 50 microns.
name
Name of the wavelength.
Raises
------
ValueError
Raised if any values in :code`array` are not between 0.1 and 50
microns (I assume this is the valid range to do retrievals).
"""
def __new__(cls, array: ArrayLike, name: str):
obj = np.asarray(array).view(cls)
obj.name = name
cls.__raise_value_error_if_array_is_not_in_range(obj)
return obj
def __array_finalize__(self, obj: np.ndarray):
if obj is None:
return
self.name = getattr(obj, 'name', None)
@staticmethod
def __raise_value_error_if_array_is_not_in_range(obj) -> None:
if not np.all((0.1 <= obj) & (obj <= 50)):
message = f'All values in {obj.name} must be between 0.1 and 50 ' \
'microns.'
raise ValueError(message)
def to_ndarray(self) -> np.ndarray:
"""Turn this object into a generic ndarray.
"""
return np.array(self)
def to_wavenumber(self) -> np.ndarray:
"""Convert this object into an array of its corresponding wavenumbers.
"""
return np.array(10 ** 4 / self)
class _WavelengthBundle:
"""Designate the short and long wavelength from an observation as being
linked.
Parameters
----------
short_wavelength
Short wavelengths [microns].
long_wavelength
Long wavelengths [microns].
Raises
------
ValueError
Raised if any values in the input arrays are not between 0.1 and 50
microns (I assume this is the valid range to do retrievals), or if
:code:`long_wavelength` are not larger than the corresponding values in
:code:`short_wavelength`.
"""
def __init__(self, short_wavelength: ArrayLike,
long_wavelength: ArrayLike):
self.short = _Wavelength(short_wavelength, 'short_wavelength')
self.long = _Wavelength(long_wavelength, 'long_wavelength')
self.__raise_value_error_if_wavelengths_are_not_same_shape()
self.__raise_value_error_if_long_wavelength_is_not_larger()
def __raise_value_error_if_wavelengths_are_not_same_shape(self) -> None:
if self.short.shape != self.long.shape:
message = 'short_wavelength and long_wavelength must both have ' \
'the same shape.'
raise ValueError(message)
def __raise_value_error_if_long_wavelength_is_not_larger(self) -> None:
if np.any(self.short >= self.long):
message = 'Some values in long_wavelength are not larger ' \
'than the corresponding values in short_wavelength.'
raise ValueError(message)