title
stringlengths 1
200
⌀ | text
stringlengths 10
100k
| url
stringlengths 32
885
| authors
stringlengths 2
392
| timestamp
stringlengths 19
32
⌀ | tags
stringlengths 6
263
|
---|---|---|---|---|---|
Develop A Responsive Layout Of Mobile App With Flutter | Develop a Responsive Layout Of Mobile App With Flutter
With 3.5 billion smartphone users in 2020, expected to reach 3.8 billion in 2021, it is fair enough to say that demand for mobile apps has gracefully scaled from desktop to mobile. And this is due to the growing interest of the developers towards designing a highly responsive and interactive UI layout of applications.
While back in 2015, Google rolled out with a significant change in search engine algorithm and introduced a new rule for the website to be mobile responsive first. And, from there, designers have not just understood the importance of designing the responsive architecture in both desktop and non-desktop applications but also love designing responsive UI in-app to increase user experience.
However, implementing responsive UIs in the application becomes a complicated task for designers in real-life.
Whether it’s about configuring changes in the app, auto-rotating the content according to the screen, or making it compatible to display on both small and large screens. At any cost, your app needs to be responsive to the layout changes.
That’s where Flutter comes into the role and takes the momentum!
So in this guide, we will answer:
What is Responsive Design?
What is Futter, Why It’s So Demanding and What it Has Evolved In to?
How Flutter is Different and Help You Create a Responsive UI of the App?
Conclusion: Where To Go Next?
Let’s dig deep into each point to understand how to increase the responsiveness of the app with Flutter…
What is Responsive App Design?
Responsive design simply means using a single code set that responds to various changes to the layout of the devices. The responsive app lay out its UI according to the screen size and shape of the device. From smartwatch, phone, tablet to laptop, an app developed responsive UI can run on multiple devices without having to develop different interfaces of the application.
The same app will adjust the size of the page according to the screen when the user either resizes the window on the laptop or changes the orientation of the phone or tablet.
Important Elements to Focus To Create Responsive Layout
In recent years, developing a responsive app has become a hot topic of the town but how to make it happen in the real world? What essential things do you need to focus on?
In responsive design, there are majorly three things to consider- Size, Orientation, and Device type. When any one of these elements changes, the app UI changes. You can also choose to hire mobile app developer that can make it done for you. But..
Let’s make it simple for you to understand:
In the below image, we have a logo, logo title and subtitles, two fields, action button and background image.
But, when we run these components on four different devices, [small screen (480*800), medium screen (1080*1920), Large screen (1200*1920) and iPhone XR], observe the clear results.
In the small device screen, the layout components are breaking and going out of screen. The title is splitting into two lines and overall reduces the design impact. While other screens are looking fine but there are few minor differences.
So what’s the solution? In this blog, I’ll explain to you how to fix the UI problems of the app by using Flutter plugins.
But before that!
What is Flutter, Why It’s So Demanding and What it Has Evolved Into?
Flutter is defined as Google’s UI toolkit that allows developers building beautiful, natively compiled applications for multiple platforms including Mobile (iOS, Android), Desktop (Linux, Mac, Windows, Google Fuchsia) and web. With the launch of Flutter in 2015, Google has not just stolen the show again but also created a buzzword in the field of app development. That is why clients from all across the world are keen hiring flutter app development company in 2021.
Being based on Dart programming language and allowing developers to create an application for multiple platforms using a single codebase, Flutter is making good progress. It has become the second most popular choice of framework for developers.
By introducing Flutter, Google has marked incredible success in two significant aspects — in creating a genuinely platform-independent framework for Android and iOS native apps that work great for production use.
Now the question is what makes it so demanding for the app development?
Here’s a list of some features and qualities that makes it so demanding:
Being a cross-platform framework, it allows developers to create an app for iOS and Android by using the same code-base.
Flutter is an open-source framework, so it is free to use and provide extensive documentation and community support to make it easier even for beginners to get started with Flutter.
This framework is simple to learn and easy to use as it is based on Google’s in-house language that is Dart.
Despite being a young framework, Flutter has become a prime choice of leading companies like Google, Alibaba, eBay, Emaar and many more.
With hot reload feature, launching or updating a Flutter based app is quite simple and fast. Developers can instantly make changes in the code on emulators, simulators and hardware in a second, without having to restart the running app. It is one of the biggest reasons that make Flutter the first choice of developers for building UIs, fixing bugs and adding a new feature.
Hopefully, you are convinced that Flutter has become so famous for developing applications. As far as building a responsive layout in the application, Android and iOS adopt different approaches to handle layouts for different screen sizes natively.
To handle various screen sizes and pixel densities, multiple concepts are used in Android including:
Android Approaches for Developing Responsive UI
ConstraintLayout: For creating a flexible and creative UI design that adapts to different screen sizes and dimensions.
For creating a flexible and creative UI design that adapts to different screen sizes and dimensions. SplitView: For separate layout files that fit different screen sizes and able to handle layout adjustments automatically as per the screen size of the device.
For separate layout files that fit different screen sizes and able to handle layout adjustments automatically as per the screen size of the device. Fragment: For extracting your UI logic into separate components, so you don’t need to define the reason separately.
For extracting your UI logic into separate components, so you don’t need to define the reason separately. VectorDrawable: For any kind of illustrations like icons, or vector graphics.
iOS Approaches for Developing Responsive UI
Auto Layout: Also known as Constraints that govern content in your app and automatically adjust the layout according to the specified constraints.
Also known as Constraints that govern content in your app and automatically adjust the layout according to the specified constraints. Size Classes: With size classes, iOS dramatically makes layout adjustments based on the size classes of a content area.
With size classes, iOS dramatically makes layout adjustments based on the size classes of a content area. UI Elements: There are few UI elements that developers use for building responsive UIs on iOS including UIStackView, UIViewController, UISplitViewController and more.
How Flutter is Different and Help You Create a Responsive UI of the App?
Just because we are claiming that creating responsive layouts in Flutter is quite more straightforward and easier, therefore, many of you are curious to ask these two questions instead of directly moving to hire software development company:
What widgets should I Use in App That adapts to Screens of Different Sizes? How Can You Get The Information About the Screen Size and How Can You Use It While Writing the UI Code?
We’ll answer these questions but let’s first talk about the second question because it is the heart of the issue.
So there are here major ways to meet your goals:
1. MediaQuery
One potential way to get information from the MediaQueryData of the MediaQuery root that is “InheritedWidget”. It provides some valuable information on Orientation and ScreenSize, that enables you to determine which layout to display based on the current orientation, what type of screen (mobile, tablet or Desktop), and screen size on which app is being displayed on.
Now the question is how to use it?
Let’s learn with the example of building a chat app in Flutter that responds to layout changes:
To get started with the changes in the layout of the chat page using MediaQuery, you need first to check the orientation from MediaQuery- If it is a landscape, then you’ll have a detail page.
You need to declare a child widget to use it later.
If you have a details page, then you can declare the child widget as a row of widgets.
For this, the row contains the list of chats as a first item.
After that, the next thing in a row is the chat page showing the conversation.
If you don’t have a detail page on the app, then the child will be the list of chats.
Lastly, you need to assign that child widget you created as a SafeArea.
Develop the app and make it run different screens and it will most likely this on Portrait and Landscape:
To make it happen, you need to go into the “ChatListPage.Dart” file in the Lib folder and have to replace the content of “build (Buildcontext Context)” with these above mentioned steps.
2. LayoutBuilder
The other way is to use a LayoutBuilder, a perfect alternative to MediaQuery that has been used to handle orientation changes. It is a builder widget just like a “StreamBuilder” or a “FutureBuilder”, that also gives BoxConstraints which enables you to determine the maximum and minimum height and width properties of the screen.
Let’s understand how this approach will work practically:
Firstly, you need to declare the LayoutBuilder as a SafeArea.
You need to determine whether the details page is using the maximum width of the parent widget. If it is greater than 600, then you have to have a detail page.
If you have a detail page, then declare the child as a row of widgets.
For this, the row contains the list of chats as a first item.
Next item in a row is the detail page showing the conversation.
Lastly, if you don’t have a detail page, it’ll be the list of chats.
Following these steps, you can build and test projects on different screens.
So these are the two major ways to check different orientations and screen sizes. But, how to make further adjustments with text?
Auto-Resizing Text Based on Parent Widget Size
If you notice the text in the above landscape screenshot, the coloured text is not resized correctly as per the layout of the screen. In that case, increasing the size of the font is quite daunting as it will go over the box. But using the Flutter Widget “FittedBox”, you can rightly scale the size according to the size of the parent widget.
This is how you can use this widget in a chat app:
To make changes in the text size , you need to follow “BoxFit.Contain” rules and try to go over these steps:
Firstly, you declare a FittedBox as a parent of the Text Widget.
Secondly, as you are using the BoxFit.Contain, you can fit to make it scale as big as it can without going out of the widget box.
Lastly, declare the original TEXT widget as a child.
Following the steps, you can see the improvement in the text size that automatically get adjusted with the screen size.
UI Architecture: Expandable and Flexible
App responsiveness is directly related to making your UI flexible and expandable with the right choice of widgets. And, the plugins that are really useful inside a column or a row. To fix the broken image to the screen, firstly you need to open the “ConversationalPage.Dart” file in that Lib folder. Then discover the line with “SquareGallery()” with TODO.
That widget will not appear, because it’s a child of “Column” and it doesn’t have enough information to determine its own height. So there you can wrap it in an “AspectRatio” widget to give it constraints.
In case if you are not able to find such constraints, then it will give you one that only follows the ratio provided by you. Moreover, in that case, the widget might overflow.
Final results, when you click on to attach the image button, then the image will come like this in both portrait and landscape screen.
CustomMultiChildLayout
Flutter also provides layout widget, that helps to size its child layout to a fraction of the total available space. It is especially useful inside Expandable and Flexible widgets.
With CustomMultiChildLayou, you can make your layout responsive, but how?
Since its a vast topic, so here we are explaining the basic code snippet below:
First, you need to declare a subclass of MultiChildLayoutDelegate.
Overlay the PerformLayout method, so you need to layout the children widgets using the LayoutChild and PositionChild methods.
Lastly, you need to return a boolean from ShouldRelayout if the widget should perform a layout again. The choice of the method depends upon your widget’s parameters.
Conclusion: Where To Go Next?
Most of you are wondering that from where you can get these plugins or widgets to make you app UI responsive. You can download the material by simply clicking on the interlinks of the blog, and you can choose to get connected with our experts.
Since Flutter has become a most demanding framework in the app development market, therefore, the majority of developers are looking forward to leveraging the features of Flutter.
There are plenty of guides, tutorials and official docs available for responsive apps in Flutter, but understanding the technicality of those tutorials is quite challenging for a novice. Therefore, we drafted things in this blog in a simple and straightforward manner to make you understand the concept.
Apart from the above mentioned widget, there are various other things that you need to know and understand. Therefore, we recommend you to hire an app development company that stands by your side at every step to make your Android/iOS app responsive with Flutter. | https://medium.com/flutter-community/develop-a-responsive-layout-of-mobile-app-with-flutter-c6a6f7013aec | ['Sophia Martin'] | 2020-12-14 05:52:38.459000+00:00 | ['Mobile App Development', 'Mobile Apps', 'Technology', 'Startup', 'Flutter'] |
Cultural Innovation Accelerators | 1. China is the Mammoth in the Room
Forget all you know. China is fucking huge. The scariest part is that nobody knows just how far China has come.
I met Edward Tse, the author of China’s Disruptors in our Shanghai Summit. He told me the one thing to take away from his book was that the Chinese knew how to innovate, they’re not just copycats anymore.
The West, encumbered by bureaucracy, simply does not know what is coming. No developed country has anywhere near as advanced a mobile payments solution as China does.
No developed country has anywhere near as advanced an ecommerce logistics platform as China does. When I dropship items via AliExpress on my ecommerce business Discover Qi (btw like my Facebook page #shamelessplug), it costs me $3 to get tracking and have my supplier send it straight to my customers anywhere in the world.
When I don’t drop ship, I pay customs for ordering in bulk, handle packaging myself, then pay $8.80 to send a package just within Australia. It’s absolutely flipping crazy.
Just as before, the Middle Kingdom has never used brute force to conquer the world (as the West did).
Throughout CAMP we learnt that the Chinese think and formulate their solutions before speaking out loud. We underestimate our Chinese student compatriots, when we sit in our lecture theaters and find that none of them speak up.
That’s why only a few people in CAMP knew that we had YuJia, a quietly spoken, incredibly intelligent and funny Chinese lady, sitting amongst us.
YuJia is the CMO of UiSee. Heard of UiSee? Didn’t think so. They’re a Beijing-based autonomous vehicle startup.
They’re rumored to be working with Didi (you know the guys who got $1B from Apple and beat the crap out of Uber), led by ex-director of Intel Labs and with over 40 AI engineers.
Just as before, the Middle Kingdom has never used brute force to conquer the world (as the West did). It’s even more invisible now that it’s happening in the cloud (you’ll understand the double entendre if you read on).
Get your head out of the sand. The game has changed.
2. Design Thinking Is More Important Than Ever.
In an increasingly, connected world, the future of work is one that will transcend all boundaries of space and time.
We will increasingly work via distance and communicate asynchronously. CAMP taught me that when you bring together multiple people from different ethnic backgrounds, cities and professions you need a framework that democratizes and captures the truths that everyone brings to the table.
Design thinking is many things to many people, but for me it’s an opportunity to play at the “edges” not at the “centre”.
Design thinking is many things to many people, but for me it’s an opportunity to play at the “edges” not at the “centre.” Innovation after all happens at the intersection between different schools of thought.
When carried out properly, the tools of design thinking let their practitioners capture the craziest of ideas and merge them into something truly unheard of before.
Throughout CAMP, many of the teams (including our own) struggled with internal conflict. Voices fought to be heard and diversity in experiences led to clashes in ideology. The only real constant was the process. Our team agreed early on to just have faith in the process.
To deliver our Insights Report, we used user centered design to interview users and diverge on the discovery process. We used open questions to grasp insights at the edges and understood that qualitative data was the priority.
Our research revealed that people actively avoided public open spaces if they felt unsafe or lacked transport options. But the places that they loved most about their city were spaces that let them connect with people and nature at the same time. This helped us craft our problem statement:
How might we get more people to engage in public open spaces and create opportunities for businesses to leverage this engagement.
We used a digital whiteboard and post-it notes (via Google Slides) to share insights and affinitise the different patterns that arose. Then we used dotmocracy to vote and discuss the different categories.
In doing so, we were all able to obtain buy-in to the problem we were solving.
Design thinking was crucial to our success. Because whenever we had doubts about the solutions we were forming, we would always come back to the the problem statement that we all genuinely believed in.
Design Thinking enabled us to diverge but also converge together. Something that’s extremely hard to do with five very different people.
3. Problem Solving happens in the Clouds and the Dirt
In the weeks leading up to CAMP’s Sydney Summit, I was listening avidly to Gary Vaynerchuk’s audiobook #AskGaryVee (11/10 would recommend!!!).
I came across this concept of being in the clouds and the dirt. The Clouds is your “why” and your “what,” the Dirt is your “how.” For me it’s the perfect encapsulation of everything I’ve done to help Mad Paws a high-growth, early stage tech startup, succeed.
You’ve got to have this high level strategy, this 10,000 ft view of where your business sits and what the bigger context of everything you do is.
In other words, you’ve got to have your head in the clouds, not in the sand. But it’s not enough, you’ve got to hustle, you’ve got get your hands dirty and get shit done.
For me, from the get go, the most daunting task our group faced as the EY Sustainable Resilient Cities think tank, was the scope of the problem we faced. Design thinkers call this a “wicked problem.”
We didn’t want to be a think tank that just delivered a pretty pitch deck and a whole bunch of high level strategy and concepts. We wanted to deliver a solution that had real user validation and that had the potential to be profitable and scaleable as well.
It’s extremely difficult to pitch a massive problem and convince the audience that your solution is still relevant to that problem.
For us, it was the $800M burden of physical inactivity on the healthcare system. But we brought it back to the opportunities physical activity and engagement in public open spaces brought for local businesses.
I felt many of the teams had identified critical problems to solve, they even had great ideas as concepts. E.g. the first runner’s up Chagri, gave a compelling and super relevant business case for Australian Agricultural businesses exporting to China.
But, the core differentiator (in my opinion) was our dirty work. We got out of the proverbial building and spoke to 41 real customers and 17 real businesses. We hustled and by staying close to the users this allowed me to present a pitch with real learning and real market traction.
4. Surround Yourself with People of the Same “Religion.” Your religion can be a common belief or goal.
This might sound cultish. But I’m convinced that by surrounding yourself with people of the same religion, it truly magnifies and augments you.
This is another concept that came out of Gary’s book. It’s significance only really hit me as I reflected on the CAMP experience. If there’s just one thing that made CAMP worth it for me, it was the people.
Our time on this planet is short. You’ve got to actively pick the people in your life that will accelerate you towards your clouds.
Our time on this planet is short. You’ve got to actively pick the people in your life that will accelerate you towards your clouds. You need to let go of the ones that drag you back.
It reminds me of facilitating Agile Sprint retrospectives at Mad Paws, do less of the things that don’t go well, do more of the things that do.
For CAMP, our religion was the mutual belief that the answer to the world’s biggest problems could only be solved at the intersection of true cultural diversity.
No matter the cultural differences, no matter what our “day jobs” were, we were all here for the same reason.
It speaks to the power of cults. When you surround yourself with people of the same religion, your feel augmented by those around you.
This sounds corny, but you feel like your flying. I am feeling massive surges of oxytocin and serotonin as I write this!
It was an un-describable high and a beautiful, amazing moment of what happens when embracing cultural diversity IS the religion.
For me, one of those highs, was when CAMPers trekked it out to a Karaoke bar in Shanghai. There was this magical moment when Bella (a German Australian) and Will (an Australian, Chinese-Timorese expat living in Shanghai) busted out an old-school Chinese karaoke duet. This was a duet that I had grown up listening to my parents sing.
Then the next second the whole group was singing Wonderwall. It was an un-describable high and a beautiful, amazing moment of what happens when embracing cultural diversity IS the religion. This is a church I can certainly ascribe to.
The CAMPers on Sichuan (aka “Sexual”) Hot Pot Night
5. Pitching = Performing Arts
My final realization was that after 10 years of hip hop dancing, I finally found how to apply it to my professional career.
Throughout CAMP we were blessed to have the guidance of the wonderful ladies of High Performance Coaching. They helped us increase our self-awareness both off the stage and on the stage.
It was to my absolute surprise and delight that both Louise and Karen came from successful careers in the performing arts and here they were coaching executives on performance.
On the afternoon of the final night, we were given tips on how to own the stage, breathe deeply, create presence and show confidence. As I took part in the ritualistic exercises, and stood on the stage in front of an empty set of tables it suddenly occurred to me.
This was no different from the countless other times I had done hip hop performances in front of thousands at a national level.
When I realized that, everything became simple. I understood the need to take the audience on a journey. I understood what it meant to look the judges in the eye and make them believe.
I understood my position on the stage and what moves I needed to perform to maximize impact. And I understood that my word craft and the story I would tell, were already captured in my verbal “muscle memory”. It was zen.
Once I made that quantum leap, I realized the dirt I had been working on for so long, suddenly found a purpose within my clouds.
Up to that moment, I had always questioned the value of dance in my life. It had been a significant emotional burden, when I saw that other people were excelling at other things. I just loved to dance but I couldn’t reconcile it with my own career’s ambitions.
However, once I made that quantum leap, I realized the dirt I had been working on for so long, suddenly found a purpose within my clouds. By connected pitching to performing arts, I knew that the stage that night would be mine (irrelevant if our team won or not).
Our Team’s Winning Pitch
Finishing Up and Giving Thanks
Needless to say, CAMP has been a game-changing milestone in my life.
When I wrote my personal life OKRs at the beginning of 2017, I set myself a personal OKR to organize a networking trip to China.
hen I saw a selfie of Andrea Myles and Jack Ma on LinkedIn which I liked. I received a push notification over the cloud. Andrea reached out and despite how steep the price seemed, I just jumped the gun and went for it. I could not have imagined what would’ve unfolded.
Now, I’m finally seeing how the things that I’ve been doing, my dirt, are connecting up to my destiny, the clouds. | https://medium.com/startup-grind/five-surprising-things-i-learnt-in-a-cultural-innovation-accelerator-1b42f5652764 | ['Christopher Nheu'] | 2017-07-03 18:18:00.374000+00:00 | ['Design', 'China', 'Startup', 'Personal Development', 'Innovation'] |
Catharsis Submission Guidelines | How to submit?
If you are already a writer with Catharsis, you know the drill — After thoroughly reviewing your draft, click on the three dots beside the Publish icon in the right hand corner of your Draft page. Select Catharsis and send.
Also, please note: If your story is in alignment with the guidelines, it will be published within 48 hours without fail.
If you are not a writer with us yet, you can either reply to this story/leave a comment and we’ll add you as a writer or you can send an email at [email protected] with your Medium profile link.
We welcome each and every one of you to this family with open arms. We can’t wait to read your story.
If you still have any questions or doubts, feel free to reply here or reach us at [email protected]. | https://medium.com/catharsis-pub/catharsis-submission-guidelines-7ee75514d0df | ['Navya Gupta'] | 2020-08-07 19:17:20.518000+00:00 | ['Storytelling', 'Poetry', 'Writing', 'Submission Guidelines', 'Catharsis'] |
A School of Emotion | To better understand what emotional intelligence is, one has to ask a basic question; how do we learn in the first place? Most of us were brought up in an academic educational system that taught us a number of basic principles.
First of all, we were taught that anything worth a grade needs to be scientifically proven, measurable, and verifiable. If it can’t be repeated in a controlled environment for others to analyze, then it is just a theory, not a fact, and should be treated as such.
“With the exception of teachers, few people actually wonder about new methods of delivering content, whatever that may be.”
Secondly, we were led to believe that how we were taught (in terms of pedagogy) mattered far less than what we were taught. With the exception of teachers, few people actually wonder about methods of delivering content, whatever that may be. As a general rule, we were always led to believe that good teaching should be impartial, unbiased, and not reliant on the teacher’s charisma or charm. This isn’t quite the case — I’m sure you remember a childhood teacher, and probably not because of the subject they taught.
Lastly, the educational system assumed that whatever we understood well would remain in our minds for as long as we needed it to. Our minds were made out to be little hard drives, capable of retaining information for as long as we wanted them to (unless banged against something hard).
So what does all this have to do with our emotional education? Admittedly not a lot; since none of the above will help you on your quest towards emotional intelligence.
“I’m sure you remember a childhood teacher, and probably not because of the subject they taught.”
Let’s start with the obvious; the way in which we learn. Contrary to popular belief, the way in which we are thought, or by whom we are taught makes a big difference. In simpler terms, we are more likely to listen to someone who has good things to say, or knows how to ‘sugarcoat’ a bitter pill. Without knowing it, we tend to block out any information that makes us feel awkward, weak, or downright stupid. It is for this reason that when someone points out our inadequacies, we subconsciously turn a blind eye.
The theory holds true both in academic and emotional education. Have you ever watched an undergraduate squirm or fidget as their lecturer chews them out in front of their peers? We tend to do that as well; all it takes is one (sometimes non-verbal) suggestion that we are not as emotionally mature as we should be. The result? We immediately go deaf, dismissing the offensive opinion as pure nonsense. Ironically, we’d prefer to knowingly listen to a well-written lie, rather than acknowledge the uncomfortable truth about our failings.
“we are more likely to listen to someone who has good things to say, or knows how to ‘sugarcoat’ a bitter pill.”
Our minds aren’t hard drives either — we forget things all the time. What seemed like a sure thing yesterday might feel like a possibility today and unlikely to happen tomorrow. Even things that hurt us emotionally fade over time, leaving us with feelings of self-doubt. If there is one thing we can be sure of, it’s that strong emotions and infectious enthusiasm will eventually fade and disappear completely. Very little sticks.
But what about scientific proof? Surely we provide a reliable pattern to explain the way in which we react to emotional stimuli. Well, as with any scientific experiment, a key factor in obtaining reliable information would be to eliminate external forces. Precautions must be taken to minimize errors. Since we all carry different emotional baggage along our journey, this becomes impossible. It’s like trying to analyze a water molecule while underwater — you are constantly bombarded by external forces, each and every one of them competing for your attention.
“we’d prefer to knowingly listen to a well-written lie, rather than acknowledge the uncomfortable truth about our failings.”
So what’s the moral of the story here? If conventional teaching methods don’t apply to emotional education, can it be taught as a discipline? As with most articles within this series, the answer lies within an invitation to explore oneself, rather than a written conclusion.
Think back to an event that triggered a strong, negative emotion. Was it because of what happened, or perhaps the person who triggered it? Perhaps you had been told it would happen, but chose not to listen. Did you try to attribute some theory or logic to the event, despite knowing that external forces were also at play?
Acknowledging the fact that emotional intelligence requires a different approach to be mastered is already a good start. The more prepared we are, the less misguided conclusions we will arrive at. It’s only when we are able to consider uncomfortable truths, acknowledge external forces, and do away with the notion of systematic logic that we can better understand ourselves from an emotional point of view. | https://medium.com/swlh/a-school-of-emotion-cbfb91c612de | ['Daniel Caruana Smith'] | 2020-12-24 14:30:56.314000+00:00 | ['Emotional Intelligence', 'Mental Health', 'Self Improvement', 'Psychology', 'Life Lessons'] |
Facta: a few steps closer to our first case study | Facta: a few steps closer to our first case study
… and the changes I had to adjust to in my journey to build it
Can we use science to improve our approach to journalism — to make it more transparent, accountable, useful? If journalism is the first draft of history, shouldn’t we use a more solid methodology? We could, I believe, draw inspiration from the researchers who develop hypotheses, look for data, check sources and resources, and test their assumptions before we write, shoot video or design a visualization. Some of you might argue that this is what good journalists do, and it is true. But it is not what most journalists and media do. And this is a problem.
When I started my journey toward the development of Facta, our new journalistic venture, I thought I had a very clear idea of the project’s goals, as well as the process to build it. But working on it as a Tow-Knight fellow in entrepreneurial journalism at the Craig Newmark Graduate School of Journalism at CUNY, I have become increasingly aware how much I need to study, experiment, adjust and prototype.
Formicablu: science made accessible through journalistic skills
For years, I have been focusing on how to make science available to people who are not experts in it. The pure essence of the work my team and I have been performing at formicablu, our Italian science communication agency, since we started in 2005 has been trying different formats, techniques, data visualizations, video and digital animations to improve the accessibility of science.
In a nutshell, we have used journalism and its tools to give our readers and listeners entry into the research laboratories and institutions, the data, the fascinating discovery stories and sometimes even the controversies. We have developed our own style, our own signature and our own language. We have become more and more involved in projects with a very vast array of clients who are, most of the time, partners more than customers. We have been working within EU-funded as well as national projects, with great freedom to develop communication strategies to bring science to different communities and audiences.
At the same time, I have been freelancing all along, sometimes as an explainer, sometimes as a reporter, sometimes even experimenting with investigative journalism. Last year, at the European Conference of Science Journalists, I was part of a panel discussing why science journalism is rarely investigative. Well, I said, it is because we are not brave enough. We prefer quite basic explanatory science, sometimes even being content with just a sort of translational work from technical jargon into more common language. This approach is usually less controversial, and we feel part of a community, that of pro science people. Yet at the same time it rarely produces real benefits for people; it is confined to the realm of knowledge for its own sake by people who already cherish science.
And I do not want that anymore. We cannot linger any longer; we have to be more committed to journalism: use our entire toolkit to investigate, report and connect; look for stories and not only for explanations; look for impacts; understand the complicated processes that lie beneath scientific enterprises; be very open about the controversies and not be content to show only good and positive results. We are perceived as being always on scientists’ side, and this should not be the case. We should be speaking for the people, for the communities, for the ones who may need science but may not be sure where to find it and how to deal with it.
Facta: building transparent journalism using a scientific approach and method
So I decided to start a new venture, one fully dedicated to build a better journalism. There are many reasons, some of which are explained in my previous post. And as I focus on building this new project, it becomes clearer that this time we need to bring a science toolkit into journalism. Science is not only the vault of stories and data we enjoy talking and reading about, but also a frame of mind that can help journalists improve their approach to finding facts, to evaluating them, to either confirming or discarding them.
One thing is very clear: journalism today is under attack. And particularly very good journalism, brave journalism, the kind that is investigating powerful people and dark players, corporations and governments. At the same time, there is an enormous amount of very mediocre journalism out there. An enormous amount of very basic and often inaccurate “cut and paste” products. An enormous amount of journalism that doesn’t care about truth, about verification, about real significance, about impact on people. An enormous amount of journalism that is performed as a very bad, low-quality job, with no dedication, no passion, no mental commitment. And this happens for a number of reasons, some even understandable. But certainly it is not the kind of journalism our societies need. It is not the kind of journalism that is the pillar of democracy, or the key to respond to people’s needs for good quality information.
While I was working on business models, value propositions, project plans, north stars and growth equations, and at the same time talking to many, many people to analyze the gaps, the critical issues in the world of journalism, I start playing with the idea that we have a potential solution at hand: using the scientific method and approach to investigate reality.
My Facta team and I do have a very unfair advantage: we all have solid research backgrounds. Some in fields that are perceived as more traditionally scientific, from bio sciences to hard ones, and others in history and philosophy, equally if not even more important in fostering critical thinking and in challenging ideas and facts. We can use this advantage to investigate reality. We know how to state hypotheses and how to test them. And we know how to collect data and work with them. We know how to find scientific literature and evaluate the impact of publications and reports. We know scientists working in many different fields, and we are capable of finding our way through the research world, which, believe me, sometimes makes you feel you’re entering another dimension. And we know how to use all of these skills in our reporting, complementing them with stories explored and collected in the field.
Getting ready to experiment
What does Facta do? It focuses on stories relevant to the entire Mediterranean region — a region that was once the epicenter of civilization and multicultural trade and exchange, and is now a stage for wars, conflicts, the drama of migration and that of a very serious climate crisis.
Facta will dive deep into topics that are relevant to at least two Mediterranean countries at a time. From the beginning, we will form a team of journalists from the involved countries and work with selected tech and scientific experts, as well as with representatives of local communities. These key players will be involved in the reporting phase to assess the continuing findings, and to give feedback and make sure the work will address their information needs.
Our final output? An innovative journalistic product, in formats that will be decided depending on the story, multimedia and/or data viz, or other factors. We’ll also curate the relevant publications we use, scientific articles, reports, etc., and all the raw interviews, except those with people whose identities need to be protected for security reasons. And then we’ll publish all the data we have collected, available to all in a form that will allow interaction and selective visualization.
If you are thinking that data journalism is already done this way, I can argue that this is rarely true. “Data journalism shouldn’t be pretty,” said one of the innovation experts I have interviewed recently in preparing my project. Others expressed the same idea: “It should serve the people; it should be useful to the people.” Even according to this recent publication on Digital Journalism, this is not often the case, both for lack of real transparency and for reliance on very few and often merely institutional sources of data. As a result, current data journalism is not, as a matter of fact, increasing much trust or usability. That’s why I’d like to approach it from a different perspective.
Everything will be published on our website, but also in syndication with other publications, national and local. Moreover, local journalists not directly involved in the project from the beginning will still be able to access the materials to produce local stories for their audiences.
Given that all ingredients and the recipe will be available, our work will be more accountable. It will serve to regain trust and to enhance transparency — a challenge, I know, and not an easy one. But one I feel quite ready to embrace, and one I hope to be working on with many of you for the next few years.
(Again, thanks to Diane Nottle for polishing my English)
(Image credits: Card puncher, Public Domain via Wikimedia; Woman technician, Robert Yarnall Richie [No restrictions], via Wikimedia Commons; formicablu) | https://medium.com/journalism-innovation/facta-a-few-steps-closer-to-the-first-case-study-ba38b390427d | ['Elisabetta Tola'] | 2019-05-08 20:45:43.608000+00:00 | ['Scientific Thinking', 'Facta', 'Science', 'Journalism', 'Data Journalism'] |
Wine Classifier Using Supervised Learning with 98% Accuracy | With the information I just obtained from the graph, I already have an idea of the kind of classifier I am going to use: a Naive Bayes Classifier. This machine learning classifier performs extremely well on normally distributed data (do not believe developer who mocks it!). If the distributions are situated apart from each other, even better, it will be much easier to distinguish among the three different classes.
4. Preprocessing
Given that this is a very simple dataset and the data is already in numerical form, I personally do not think I need to make any preprocessing. If you are a beginner, know that you need to preprocess data when you have to prepare it for your model (for example converting categorical data to encoded data).
Extracting Labels
The only thing I am going to do is extracting labels from the dataset so that I can feed it to the model.
v.upload.retrieve_backup(e.K)
v.extract.labels(['Wine'])
e.y
sample of labels
5. Splitting
I will now split X (features) and y (labels) into train and test. As a default, I will use a .2 proportion for the test side.
X_train, X_test, y_train, y_test = v.split(0.2)
print(X_train.shape, X_test.shape, y_train.shape, y_test.shape)
6. Machine Learning Model
It is now time to create my AI:
Creating the Model
I will be using the scikit-learn library, one of the best open-source machine learning libraries.
from sklearn.naive_bayes import GaussianNB
clf = GaussianNB()
Training the Model
I will use my train samples to find the rules that link X to y. Then, I will make an estimate on X_test and compare it with the actual results that the model has never seen: y_test.
clf = clf.fit(X_train, y_train)
y_predict = clf.predict(X_test)
from sklearn.metrics import accuracy_score
print(accuracy_score(y_test, y_predict))
1.0
100%! Astonishing result!
7. Evaluation
I have only been splitting the dataset once, but, to improve the validity of the model, I can use a cross-validation algorithm to test the model on 10 different splits, each one with different data taken from the dataset.
v.statistics.cross_validation(clf, X_train, y_train, 10) Accuracy: 0.96 (+/- 0.09)
[1.00,
1.00,
1.00,
0.92,
0.92,
1.00,
0.85,
0.92,
0.92,
1.00
]
Depending on the data in train and test determined by the split, the accuracy ranges from 85% to 100%, with an average of 96%. The result can vary, the top I obtained is 98% after a few attempts. | https://medium.com/towards-artificial-intelligence/wine-classifier-using-supervised-learning-with-98-accuracy-5f2e173e967e | ['Michelangiolo Mazzeschi'] | 2020-06-05 21:01:01.157000+00:00 | ['Machine Learning', 'Artificial Intelligence', 'Data Science', 'Wine', 'Big Data'] |
Can Jigsaw Puzzles Really Improve Your Mental Health? | Can Jigsaw Puzzles Really Improve Your Mental Health?
How puzzles can help with anxiety, ADHD, and other mental health issues
Photo by Hans-Peter Gauster on Unsplash
I’ve probably always had a minor anxiety issue, but since the pandemic, it’s gone into the stratosphere.
It’s the kind of anxiety where, even when I remove the stressors and solve the thing I was worried about, my nervous system takes a while to catch up. My mind still races, my heart rate is elevated, my stomach hurts — sometimes it takes all day for the feeling to go away.
Normally, I’d try to distract myself with something else, like a show or a book — but lately, it’s gotten so bad that I can’t even focus on those things. In the warmer months, I’d go for a run or do something active outside in order to quiet my mind. But in the dead of winter, going for a jog isn’t as appealing.
So, I’ve turned to jigsaw puzzles — and apparently this is not a new idea.
Is “puzzle therapy” effective?
An article last year from Refinery29 explored this very issue — can puzzles really help to quell anxiety?
With people now stuck at home in quarantine, the puzzle business is booming. According to a MarketWatch report, the puzzle industry (because yes, that is a thing) is expected to reach a value of $730 million by 2024.
But it’s not just because people are bored — although, that is a contributing factor. It’s because puzzles are relaxing and addicting — in a good way. I myself can attest to this.
At my first job, we had a puzzle table. I worked in a newsroom as a copyeditor, so the days were long and stressful. My boss set up a table next to one of the cubicles with a puzzle, and every time we’d walk by it, my coworkers and I would place a few pieces here or there. Sometimes, we’d work on it together during our lunch break.
Something as simple as a puzzle was good for team bonding and morale, and it was a good way to take a quick break after a stressful client phone call.
While there’s no hard and fast science or research to support the effect puzzles have on mental health, there’s no denying that there are benefits. There’s anecdotal evidence from many a jigsaw puzzler about how puzzles have helped them cope with ADHD, anxiety, insomnia, and PTSD.
Some people even swear by 18,000+ piece Ravensburger puzzles — which I didn’t even know existed. They’re about the size of a medium area rug and look completely impossible.
Dr. Vaile Wright, director of clinical research and quality at the American Psychological Association, said in an article for CNN that puzzles reduce stress because they distract our brain with finding patterns, which then triggers a hormone response and lowers cortisol. Puzzles also help us get “in the zone,” or into a state of flow where we are hyper-focused on the task in front of us and the rest of the world melts away.
And it doesn’t have to be a jigsaw puzzle, if that’s not your pleasure — crossword puzzles, sudoku, word searches, or a Rubik’s cube can have the same effect.
Reduce your screen time with a puzzle
Especially cooped up in quarantine, people are looking for new ways to spend their time other than staring at a small, medium, or large screen on rotation day after day. Too much screen time can result in headaches, eye fatigue, and disrupted sleep.
Remember when adult coloring books were all the rage? It’s because, like puzzles, they’re used as a way to relax and reduce stress. But unlike coloring books, puzzles can be calming and collaborative.
“You can talk, someone can read nearby and still feel included, and even if you’re completely focusing, you still feel like you’re doing something together,” said Amanda Kahle, owner of the puzzle business Inner Piece, in an article for CNN.
Quality time with others is a key way to beat stress and depression. The next time you crave connection, try working on a puzzle with someone instead of vegging out in front of the TV. Even if you’re quarantining alone, puzzles are a great way to focus your mind on something else, and they can even help you sleep better at night. | https://medium.com/moments-matter/can-jigsaw-puzzles-really-improve-your-mental-health-981e84442e6 | ['Megan Boley'] | 2020-12-14 13:07:15.680000+00:00 | ['Self', 'Mental Health', 'Mindfulness', 'Life', 'Psychology'] |
Handling Outliers in Machine Learning | Methods To Find Outliers
Now We have understood what an outlier is and the different types of outliers now let’s see different methods to find outliers.
There are two basic methods:
Percentile Box Plot
Percentile
In this method, we choose a minimum percentile and maximum percentile. Usually, the minimum percentile is 5%, and the maximum percentile is 95%. Then We Fetch out all the data points outside the percentile range, which means those values that are greater than 95% value or smaller than 5% value, and consider them as outliers.
Example: In a dataset, if 5% is 45 and 95% is 1000, then all the values that are below 45 or greater than 1000 are considered as outliers.
Practical Example:
## Let's First Create a Dummy DataFrame With Outliers
lst = [random.randint(0,100) for i in range(0,100)]
## Adding a manual outlier
global_outlier = [300]
df = pd.DataFrame(lst+global_outlier,columns=['number']) ## Minimum Percentile Value
min_val = df.quantile(0.05) ## Maximum Percentile Value
max_val = df.quantile(0.95) ## Finding All the Outliers
df[(df['number']<min_val[0])| (df['number']>max_val[0])] ##############OUTPUT################
number
23 2
64 1
66 99
84 2
89 99
100 300
######YOUR OUTPUT MAY BE DIFFERENT BECAUSE WE ARE USING RANDOM MODULE TO GENERATE SAMPLE DATAFRAME####
Box Plot
A box plot is a graphical display for describing the distribution of data. Box plots use the median and the lower and upper quartiles.
Pandas data frame has a built-in boxplot function. Let’s use the above to create a data frame and try to find the outliers.
df.boxplot(column=['number'])
300 value as an outlier
Let’s use both the techniques and try to find outliers in a real dataset like Titanic. Visit my Github repo and download the cleaned version of the dataset with no nan values from here.
Percentile
########## DETECTING OUTLIERS USING PERCENTILE ###############
df = pd.read_csv('data/titanic_with_no_nan.csv')
max_val = df.Age.quantile(0.95)
min_val = df.Age.quantile(0.05)
df2 = df[(df['Age']<min_val) | (df['Age']>max_val)]
print("Number of Outliers Detected in Age:",df2.shape[0]) #########OUTPUT#########
Number of Outliers Detected in Age: 86
Box Plot
########## DETECTING OUTLIERS USING BOX PLOT ###############
df = pd.read_csv('data/titanic_with_no_nan.csv') ### LET'S USE SEABORN BOX PLOTS
import seaborn as sns
sns.boxplot(df['Age'])
Outliers in the ‘Age’ Column in Titanic Dataset
Different Ways to Handle Outliers
There are two ways to handle outliers.
Remove All the outliers. Replace Outliers Values with a suitable value
Removing all the outliers
In this method, we first find the min and max value quantiles, and then we simply remove all the values by not picking them in further processing.
import matplotlib.pyplot as plt
import seaborn as sns
import warnings
import pandas as pd
warnings.filterwarnings("ignore")
fig, axes = plt.subplots(1,2)
plt.tight_layout(0.2) ## DataFrame
df = pd.read_csv('data/titanic_with_no_nan.csv')
print("Before Shape:",df.shape) ## Max and Min Quantile
max_val = df.Age.quantile(0.95)
min_val = df.Age.quantile(0.05) ## Removing all the outliers
df2 = df[(df['Age']>min_val) & (df['Age']<max_val)] ## Visulization
print("After Shape:",df2.shape)
sns.boxplot(df['Age'],orient='v',ax=axes[0])
axes[0].title.set_text("Before")
sns.boxplot(df2['Age'],orient='v',ax=axes[1])
axes[1].title.set_text("After")
plt.show()
Replacing Outliers Values with a suitable value
Using Quantile Method
In this method, we first find the min and max quantile. After that, we find all the values outside the quantile range and replace them with min or max quantile value accordingly.
import numpy as np
import matplotlib.pyplot as plt
import warnings
warnings.filterwarnings("ignore")
fig, axes = plt.subplots(1,2)
plt.tight_layout(0.2)
df = pd.read_csv('data/titanic_with_no_nan.csv')
print("Previous Shape With Outlier: ",df.shape)
sns.boxplot(df['Age'],orient='v',ax=axes[0])
axes[0].title.set_text("Before") ########### HANDLING OUTLIER ######
max_val = df.Age.quantile(0.95)
min_val = df.Age.quantile(0.05) df2 = df ####### REPLACING ALL THE Large values with MAX QUANTILE VALUE ####
df2['Age'] = np.where(df2['Age']>max_val,max_val,df2['Age']) print("Shape After Removing Outliers:", df2.shape) sns.boxplot(df2['Age'],orient='v',ax=axes[1])
axes[1].title.set_text("After")
plt.show()
Using IQR
IQR or interquartile range is a measurement of variability based on dividing the dataset into different quantiles.
Quantiles are divided into Q1, Q2, and Q3, where Q1is the middle value of the first half of the dataset. Q2 is the median value, and Q3 is the middle value of the second half of the dataset.
IQR is equal to Q3 minus Q1.
Q1 = df.column.quantile(0.25)
Q3 = df.column.quantile(0.75)
IQR = Q3-Q1
After calculating IQR, we calculate the lower limit and upper limit and then simply discard all the values that are less or above the limit and replace them with lower and upper limit accordingly.
NOTE: It will Also Work For Data That is Left skewed or Right Skewed
df = pd.read_csv('data/titanic_with_no_nan.csv')
import numpy as np
import matplotlib.pyplot as plt
import warnings
warnings.filterwarnings("ignore")
fig, axes = plt.subplots(1,2)
plt.tight_layout(0.2)
print("Previous Shape With Outlier: ",df.shape)
sns.boxplot(df['Age'],orient='v',ax=axes[0])
axes[0].title.set_text("Before") ########### HANDLING OUTLIER ######
Q1 = df.Age.quantile(0.25)
Q3 = df.Age.quantile(0.75)
print(Q1,Q3) IQR = Q3-Q1
print(IQR) lower_limit = Q1 - 1.5*IQR
upper_limit = Q3 + 1.5*IQR
print(lower_limit,upper_limit) df2 = df
df2['Age'] = np.where(df2['Age']>upper_limit,upper_limit,df2['Age'])
df2['Age'] = np.where(df2['Age']<lower_limit,lower_limit,df2['Age']) print("Shape After Removing Outliers:", df2.shape) sns.boxplot(df2['Age'],orient='v',ax=axes[1])
axes[1].title.set_text("After")
plt.show()
Bonus Tip
It is not always easy as it looks to find the outliers and then handle them. In such a situation, we can use a different machine learning model that is not sensitive to outliers.
1. Naivye Bayes Classifier--- Not Sensitive To Outliers
2. SVM-------- Not Sensitive To Outliers
3. Decision Tree Regressor or Classifier---- Not Sensitive
4. Ensemble(RF,XGboost,GB)------------Not Sensitive
5. KNN--------------------------- Not Sensitive 6. Linear Regression------------- Sensitive
7. Logistic Regression----------- Sensitive
8. Kmeans------------------------ Sensitive
9. Hierarichal------------------- Sensitive
10. PCA-------------------------- Sensitive
11. Neural Networks-------------- Sensitive
Github & Notebook Link | https://medium.com/towards-artificial-intelligence/handling-outliers-in-machine-learning-f842d8f4c1dc | ['Abhay Parashar'] | 2020-12-03 16:50:18.950000+00:00 | ['Machine Learning', 'Python', 'Artificial Intelligence', 'Education', 'Data Science'] |
Data Scientists, The 5 Graph Algorithms that you should know | 1. Connected Components
A graph with 3 connected components
We all know how clustering works?
You can think of Connected Components in very layman’s terms as a sort of a hard clustering algorithm which finds clusters/islands in related/connected data.
As a concrete example: Say you have data about roads joining any two cities in the world. And you need to find out all the continents in the world and which city they contain.
How will you achieve that? Come on give some thought.
The connected components algorithm that we use to do this is based on a special case of BFS/DFS. I won’t talk much about how it works here, but we will see how to get the code up and running using Networkx .
Applications
From a Retail Perspective: Let us say, we have a lot of customers using a lot of accounts. One way in which we can use the Connected components algorithm is to find out distinct families in our dataset.
We can assume edges(roads) between CustomerIDs based on same credit card usage, or same address or same mobile number, etc. Once we have those connections, we can then run the connected component algorithm on the same to create individual clusters to which we can then assign a family ID.
We can then use these family IDs to provide personalized recommendations based on family needs. We can also use this family ID to fuel our classification algorithms by creating grouped features based on family.
From a Finance Perspective: Another use case would be to capture fraud using these family IDs. If an account has done fraud in the past, it is highly probable that the connected accounts are also susceptible to fraud.
The possibilities are only limited by your own imagination.
Code
We will be using the Networkx module in Python for creating and analyzing our graphs.
Let us start with an example graph which we are using for our purpose. Contains cities and distance information between them.
Graph with Some random distances
We first start by creating a list of edges along with the distances which we will add as the weight of the edge:
edgelist = [['Mannheim', 'Frankfurt', 85], ['Mannheim', 'Karlsruhe', 80], ['Erfurt', 'Wurzburg', 186], ['Munchen', 'Numberg', 167], ['Munchen', 'Augsburg', 84], ['Munchen', 'Kassel', 502], ['Numberg', 'Stuttgart', 183], ['Numberg', 'Wurzburg', 103], ['Numberg', 'Munchen', 167], ['Stuttgart', 'Numberg', 183], ['Augsburg', 'Munchen', 84], ['Augsburg', 'Karlsruhe', 250], ['Kassel', 'Munchen', 502], ['Kassel', 'Frankfurt', 173], ['Frankfurt', 'Mannheim', 85], ['Frankfurt', 'Wurzburg', 217], ['Frankfurt', 'Kassel', 173], ['Wurzburg', 'Numberg', 103], ['Wurzburg', 'Erfurt', 186], ['Wurzburg', 'Frankfurt', 217], ['Karlsruhe', 'Mannheim', 80], ['Karlsruhe', 'Augsburg', 250],["Mumbai", "Delhi",400],["Delhi", "Kolkata",500],["Kolkata", "Bangalore",600],["TX", "NY",1200],["ALB", "NY",800]]
Let us create a graph using Networkx :
g = nx.Graph()
for edge in edgelist:
g.add_edge(edge[0],edge[1], weight = edge[2])
Now we want to find out distinct continents and their cities from this graph.
We can now do this using the connected components algorithm as:
for i, x in enumerate(nx.connected_components(g)):
print("cc"+str(i)+":",x)
------------------------------------------------------------
cc0: {'Frankfurt', 'Kassel', 'Munchen', 'Numberg', 'Erfurt', 'Stuttgart', 'Karlsruhe', 'Wurzburg', 'Mannheim', 'Augsburg'}
cc1: {'Kolkata', 'Bangalore', 'Mumbai', 'Delhi'}
cc2: {'ALB', 'NY', 'TX'}
As you can see we are able to find distinct components in our data. Just by using Edges and Vertices. This algorithm could be run on different data to satisfy any use case that I presented above. | https://towardsdatascience.com/data-scientists-the-five-graph-algorithms-that-you-should-know-30f454fa5513 | ['Rahul Agarwal'] | 2020-09-11 11:58:49.065000+00:00 | ['Machine Learning', 'Artificial Intelligence', 'Visualization', 'Data Science', 'Programming'] |
Increasing Personal Productivity During Distance Learning | Increasing Personal Productivity During Distance Learning
6 tips for getting your work done with kids at home
Image of the author’s “office” provided by the author
This was my year to finally hit some writing goals for myself. My youngest is going to full-day kindergarten and for the first time in 9 years I was going to have large portions of time to myself to knock things off my to-do list. Having my last baby go to school full-time was definitely bitter sweet. Last year, I began dreaming about how I was going to use this time. Other than the never ending chores and errands, I was going to dedicate days on my calendar for writing. If I could get away with it, I was going to dedicate a portion of everyday to my writing. But thanks to the pandemic, my kids are all distance learning from home and my husband has been working from his home office since March.
Having five other people home means my house is never quiet. While each child has their own space for their school time, they all have different schedules so when one is on break, another is still in class. My makeshift office has always been the kitchen table. But since I was only able to dedicate 1–2 hours two days a week to my writing, it has never been an issue. Now, my “office” is at the end of the couch next to my kindergartener’s dedicated learning space. She’s fairly independent, but as she reminds me, she can’t read yet so I still have to help her navigate getting online for her class. I thought this set up was going to put a damper on my writing goals. Everyone else had a dedicated desk space, but me. But I have found that sitting next to her has actually made me more productive! How is that possible?
Have you ever heard that adage from Lucille Ball: If you want to get something done, ask a busy person. I’ve always wondered if it’s true, but if you look at anyone who volunteers or those who are on several committees at work, it’s totally true. It also seems like it’s the same 5–7 people doing several different jobs. But they have learned to time manage effectively. When I became a stay at home mom there were months where I was busier and worked more than when I was working full time as a teacher. I was volunteering weekly at my children’s schools and their after school activities. My day started before theirs and often times ended well past a typical duty day if I was working a traditional 9–5 job.
So here we are four weeks into the school year and in my makeshift office at the end of the couch I have cranked out more stories than I thought possible. I know that I only have x amount of minutes to get anything written before any of my four children are on a break. Even as I write this my teenager has just approached me talking to me about assignments and grades. Sometimes my children flit in and out of my peripheral vision to share something about their day and then move along before I can look up.
So how do I do it? How do I write while juggling 4 children’s schedules and their various breaks? How is it possible to get anything one with someone always vying for my attention? Here’s what I do:
I write in time chunks. I write for 15 minutes at a time and take a break if needed. If no one needs my attention right away I keep writing until someone asks for my attention. 15 minutes seems like a short amount of time, but it’s dedicated time. I’m not wandering aimlessly on the internet. I know it’s just a matter of time that I have to stop, so I write as much as I can in the time given to me. I take a lunch break when my children take their lunch/wellness break. It does force me to stop what I’m doing, clear the brain, and talk about something other than what I’ve been writing. When lunch is over and everyone is back at their desk, so am I. Surprisingly, it works. I know that I only have another small chunk of time before someone asks me for something. I dedicate time to work when my children are working. I could probably get other things done, but I’m treating this writing gig as a job despite the lack of a real office or office hours. So if they’re working, so am I. I put an imaginary do not disturb sign on my laptop and get my work done. I don’t answer superfluous texts, emails, or the rare phone call that do not pertain to the work I’m doing at that moment in time. I’ll spend an hour after my work day to do that. I don’t have time to waste. If I waste it on something other than my work, I don’t have time to go back to my writing until the kids are in bed or until the next day when they are back in school. Honestly, I am just too darn tired to go back to it at night. Once upon a time I was a night owl and I could be uber productive after dinner. But then kids happened and that time is spent with them or making sure everyone has underwear for the next day. So there’s that. When school is over for the day is when the laundry, housekeeping, cooking, and other chores get done. The nice thing about the pandemic is that we have no where to go. No after school sports or after school clubs. Self quarantining does have it’s been benefits. Not a lot, but I’ll take what I can get. Creating boundaries. Working at home and working in close proximity to my children at all times means I have to create boundaries. Because I’m not behind a close door, like my husband, doesn’t mean I’m immediately available. This has made my children more independent. If they see my fingers flying over the keyboards or if I put my finger up as they approach me with a question or comment, they’ll wait. I try to take up every second of that 15 minutes block to get down my thoughts. It has made them more patient and more independent. They have found that they don’t need me for every.blessed.thing and that’s okay. I don’t always finish my sentences. This is a tip I learned from Stephen King’s book On Writing. He suggests letting a sentence hang there and later when he gets back to it he has jumping off point to begin again. When my timer goes off and my children need me, I actually leave off my sentence and attend to them. When I come back to my piece, I reread and sometimes I find a new trajectory or a better ending for that sentence. I know that this isn’t possible for everyone and every situation, but for writing, give this one a try and see how it works for you.
When I found that we were going into distance learning with the kids, I was mourning the loss of having time to myself to get things done. I honestly thought I would have to put off being productive in my writing for yet another year. My husband’s job isn’t flexible. When he’s in a meeting, he is in a meeting and no one can interrupt. I had no idea how many meetings that man could have in a day and now I do. I’m glad that it’s him and not me. Yes, the kids are in school, but I’m constantly called away to help them print something, access technology, follow up on an assignment, or answer a random question. While more independent day by day, my kindergartner wants me working next to her while she’s online for her class. That has more to do with anxiety and that some personal health issues that have cropped up for me so she’s in this phase of always wanting mommy around.
But now that we’ve found our groove, I am more productive in the last 4 weeks than I have been in the last 8 months. I can still get my work done while attending to all the ups and downs of distance learning. It is possible without neglecting my children or my work.
I’m not so arrogant to think that these tips will work for everyone due to job expectations and the ages of the children at home. Take these tips with a grain of salt. I know that this does not take into account families with younger children at home. That’s another ball of wax, but doable, and requires a lot more maneuvering of the day. It doesn’t take into account if you are needed in meetings many hours throughout the day, like my husband. And if you’re a teacher working from home while your children are also distance learning, thank you for your dedication. You are a true superhero. But for the rest of us, it is possible to check off your work to-do list amidst the chaos of distance learning. | https://medium.com/home-sweet-home/increasing-personal-productivity-during-distance-learning-f43939a73679 | ['Heather Jauquet'] | 2020-09-23 13:36:22.036000+00:00 | ['Work Life Balance', 'Life Lessons', 'Writing', 'Productivity', 'Parenting'] |
Stumbling on the Happiness of Being Like Everyone Else | In some ways we realize we’re all very much alike. That’s why we can get behind big, bold statements like: “All men are created equal.” But research shows that regardless of IQ or education level, we are all susceptible to similar errors in our reasoning. As a result, most people believe they are the exceptions to the rule.
Most overestimate their abilities and underestimate their weaknesses. Some researchers call this “illusory bias.” It reminds me of author William Saroyan’s statement:
“Everyone has got to die, but I always thought an exception would be made in my case.”
Daniel Gilbert’s, Stumbling on Happiness, brings to life the latest scientific research in psychology, cognitive neuroscience, philosophy, and behavioral economics. Gilbert reveals what scientists have discovered about the uniquely human ability to imagine the future, and about our capacity to predict how much we will like it when we get there. (Hint: we’re not very good.)
He explains in detail the cognitive errors we make in trying to predict our future happiness. The greatest ability of the human brain is to imagine, to see the world as it has never been before. Our brains fall victim to biases that cause our predictions of the future, and our memories of the past, to be inaccurate.
This leads to our fallibility and not being able to predict well what will make us happy. He also outlines one technique that has been effective in predicting future happiness, but then goes on to discuss the reason why the vast majority of humans won’t use it. | https://medium.com/big-self-society/stumbling-on-the-happiness-of-being-like-everyone-else-da087951fa08 | ['Chad Prevost'] | 2020-11-12 13:55:28.947000+00:00 | ['Authors', 'Books', 'Happiness', 'Psychology', 'Two Minute Takeaway'] |
How we can easily stop plastic waste now | Swimming in a sea of plastic (Source: Fabbaloo)
Ok. So by now it’s pretty clear to most people that we have a plastic problem. Our oceans are literally swimming in plastic.
The question is: what can we do about it?
There is a fairly simple solution. But before we get to the solution, we need to understand the problem and how we got here.
The problem
Out of the 8.3 billion metric tons of plastic ever produced only 9% is recycled. More recently that figure is about 14% but the fact is that even when the intentions are good, we are terrible at recycling plastics still poses big challenges.
For simplicity, we will focus on single-use plastic water bottles but many other plastics such as bags, cigarette buts, diapers, food packaging, other beverages, microbeads from clothes, etc. are equally important.
A clear example: Bottled water
The bottled water market globally keeps growing with an approximate 600 million households now consuming bottled water. In 2017 the bottled water market reached a volume of 391 billion litres after growing at an average of 6% per year during 2009–2016. At the current rate of growth, 90 million more homes will consume bottled water by 2022.
Table: Bottled water consumption worldwide
* Households with access to electricity and water (WHO)
** Estimates based on population and bottled water consumption. In some cases, it may include large bottles that are refilled.
Assuming that each household consumes about 2 bottles per day on average this means 576 million x 365 = 210 billion bottles per year. This aligns pretty well with the estimate of a total of 480 billion plastic bottles consumed annually whereof 50% are water.
Gobal annual bottled water consumption in millions of tons of plastic
Why are so many people drinking bottled water?
During the past 30 years, tap water quality in Europe and North America vastly improved both in terms of taste and quality. Despite this, bottled water consumption went from zero to the staggering numbers above.
The main reasons cited by consumers are:
Prefer the taste of bottled water
Concerned about the quality and health impact of tap water
Replacing sugary beverages
Convenience of bottled water
In addition to this, the bottled water industry has actively been promoting the health benefits of mineral and spring water for many years. Due to this almost half of the population believe bottled water is healthier than tap water.
How can we solve this?
There are many very challenging problems in the world such as climate change, inequality and terrorism that are extremely difficult to solve. Bottled water is not one of them.
As a matter of fact, bottled water is completely unnecessary for most households. In North America and Europe more than 95% households have access to clean tap water. In many other areas of the world with access to tap water, it can easily be made safe with an affordable filter.
Despite this too many homes choose bottled water due to taste preference or misinformed health concerns. Governments have a responsibility to educate people and provide guidelines on solutions for drinking water just like they do for recycling, water consumption, alcohol and general health.
This includes informing people about the problems bottled water is causing in terms of transportation, waste and plastic pollution and provide alternatives. For low- income families it may even be advisable to subsidise solutions for clean drinking water.
With education and water filters everyone can safely drink tap water
What’s next?
With the help of education and regulation Europe and North America could cut bottled water consumption by at least 75% in just a couple of years limiting most consumption to sparkling mineral water served on glass bottles. China, India, Mexico and Indonesia that are big consumers of bottled water can do the same, although the quality of local tap water requires more stringent regulation of water filters.
The money saved by consumers will go to other consumption and thus creating new jobs replacing the bottled water industry.
If we do the same thing for all the major groups of single-use plastics, then plastic waste can be vastly reduced as an issue.
What are we waiting for? Let’s start lobbying family, friends and politicians now!
Disclaimer:
I’m Co-founder of TAPP Water with a mission to provide easy and affordable solutions for clean and environmentally friendly water.
Sources:
Ellen MacArthur Foundation — 2017 Study on plastic production and recycling
National Geographics -Plastic Produced Recycling Waste Ocean Trash 2017
Forbes — 1 million bottles per minute and 91% not recycled | https://medium.com/hackernoon/how-we-can-easily-stop-plastic-waste-now-16107096a841 | ['Magnus Jern'] | 2018-10-01 10:51:11.871000+00:00 | ['Plastic Pollution', 'Sustainability', 'Recycling', 'Environment', 'Water'] |
Food Waste Economics | HOW FOOD IS WASTED
People waste food at four levels: producer, distributor, seller, and consumer. At these levels, three types of food get discarded: food gone bad, food we think is bad, and food we know is still consumable, but we don’t want.
1. LOST IN TRANSIT
When genuinely non-consumable food is thrown away, it is usually because problems in packaging, storage, and transportation at the production level and consumers and sellers stocking more than needed. For the average US household, approximately $2200 of food is tossed- roughly a fifth of goods in every consumer’s shopping cart.
Surprisingly, actually bad food is the smallest margin of food wasted. On average, 90% of tossed food can still be safely eaten.
2. OVEREMPHASIZED EXPIRATION DATES AND APPEARANCES
The largest category of food trash is food we think is bad, but could actually still be consumed. This comes down to aesthetics and expiration dates. First, aesthetically, producers and sellers are hesitant to deal with misshapen or bruised goods, even if they’re still eatable. At the retail level, there is an emphasis on all individual products looking homogeneous. So, when an item is perceived as a distorted, such as a two-bodied pear, it won’t make the market shelves. Tacked on to this, there is hesitation to consume food that looks slightly bruised or is past its sell-by date. However, when it comes to bruises on produce, damaged boxes, or passed sell-by dates, it often only indicates a decrease in quality- not in-edibility. Thus, the items are tossed.
3. LEFTOVERS
Lastly, when we throw away food we know is still good, but we simply don’t want, it is often because the time, resources, and money needed to donate the food or transport it to someone who would eat the food outweighs what we believe the possible good to be. For sellers in particular, companies like Walmart recognize that it is more cost efficient to throw away the good than to spend money on a driver to transport the food to a homeless shelter. | https://christinagayton.medium.com/food-waste-economics-f3176cfaeb1a | ['Christina Gayton'] | 2018-12-29 14:55:39.076000+00:00 | ['Economy', 'Economics', 'Sustainability', 'Environment', 'Food'] |
When Your Calling Seems Vague and Unclear, You’re on the Right Track | Lesson 2: Just Because It’s Hard Doesn’t Mean You Should Quit
“We are what we repeatedly do. Excellence, then, is not an act, but a habit.” —Aristotle
I’m wary of people who can name their dream immediately without having had any real experience with it. The flame that is fast to light is also the quickest to burn out.
Although you occasionally encounter rare cases of people knowing what they were meant to do since childhood, most struggle with the clarity concept. But what if we at least temporarily disregarded it?
Often, I hear people tell me they would gladly follow their passions in life, if they just knew what they were. Or they have too many interests in life and don’t know which one to focus on.
So where do you start?
Instead of following your passion, as Cal Newport says, maybe you should let your passion follow you. We all tend to enjoy activities we’re good at and shy away from the things we’re not. So if you don’t have something like that, don’t wait for passion. Just get so good that the enjoyment soon follows. And if it doesn’t, you can always pick something else.
Naming and claiming a dream is a popular trend these days. What’s far less popular is the disciplined practice of a craft — spending thousands of thankless hours getting great at something before sharing it with the world.
If you tell me, “I want to be an author” but have never written a word, I’m skeptical.
If you say, “I was born to be a carpenter” but have never lifted a hammer, I’m doubtful.
You may like the idea of being a writer or the image of being on a construction project, but you haven’t done any actual work. You don’t understand the cost of the dream, of putting yourself out there and risking failure. Therefore, it has no real value to you. You have to practice.
But not all practice is equal. In fact, most people have no idea how to do something with excellence, which is little wonder why we drift from one meaningless job to the next. Maybe what we need is not less work and more four-hour work weeks, but instead the kind of practice that demands our total presence and most serious attitude.
This is what Daniel Coyle, author of The Talent Code, calls “deep practice.” It is the kind of activity that requires all your strength and attention but also ends up being the most fulfilling thing you could possibly do. No, it isn’t always easy, but since when did your calling have to come easy?
And if you choose to wait, to bide your time before beginning to figure out what you were meant to do with your life, well, that’s a form of practice, too. | https://medium.com/better-humans/when-your-calling-seems-vague-and-unclear-you-re-on-the-right-track-816cfddb2450 | ['Jeff Goins'] | 2019-12-10 01:46:34.378000+00:00 | ['Self Improvement', 'Work', 'Entrepreneurship', 'Careers', 'Productivity'] |
Java + Python = Jython? | Java + Python = Jython?
Yes, this is legit
Photo by Tracy Adams on Unsplash
The Story
A couple of weeks ago, I was working on a Java application that creates directories and files based on the parameters given. Like with all of my applications, I want to know what’s going on while they are running. This got me thinking about my previous article that talked about a small logging module I wrote in Python. This module contains different levels for logging that get inserted into a database. The problem is that it was written in Python and that obviously doesn’t mix with Java. Or does it?
It took less than five minutes of googling, to discover Jython. In a nutshell, Jython is an implementation of Python that runs on Java. For the most part, it is compatible with Python 2.7. Keep in mind that Python 2.7 is no longer receiving support, but the Jython team is working to get it compatible with Python 3.
The Struggles
Initially, I was hoping to leverage the Python logging class that I had already written. Essentially, this would require importing the module, creating a class object, and then calling one of the class functions (Depending on which level of logging I wanted to do). It would have looked like something similar to this:
from my_logger import MyLogger myLogger = MyLogger("project_creator", "mysql://<USER>:<PASSWORD>@<HOST>/<DATABASE>") myLogger.LogInfo("This is some logging information.")
Using Jython, this would loosely translate to:
PythonInterpreter interp = new PythonInterpreter(); interp.exec("from my_logger import MyLogger"); PyInstance loggingObject = (PyInstance)interp.eval("MyLogging('project_creator', 'mysql://<USER>:<PASSWORD>@<HOST>/<DATABASE>')"); System.out.println(loggingObject.invoke("LogInfo()").__tojava__(String.class));
Writing the Java code seemed fairly quick and easy. With my hopes high, I started researching what needs to be done to get this project to build and run. It was after quite a lot of time and experimenting where I realized that my original plan wasn’t going to work. Before I realized this, I needed to get Jython installed first.
Ubuntu has a package in its store called Jython that can be used. However, this package is for Jython 2.5. All of the modern documentation recommends downloading the Jython 2.7 installer which will give you the most recent version. Once downloaded, to run the installer:
java -jar jython-installer-2.7.2.jar
Selecting the second option which is the Standard edition will install the .jar file that you need along with demos and documentation. I tried the ninth option, which is supposed to install just the .jar file failed during installation every time I tried. While installing, you will be prompted to specify which directory you want the .jar file to install to.
Once installed, I was able to run this command that, in theory, would build my Java application:
javac -cp ~/jython/jython.jar jythontest/*.java
Unfortunately, that was wishful thinking. It was here that I started seeing errors for missing Python modules. After more research, I learned that I need to install the missing modules for Jython using the .jar file that I installed. Normal Python uses “pip” to install packages. From the research, I’ve done, Jython did have something called “jip”, but documentation for that is scarce. It was a little bit of a pain, but I had to download the missing modules from PyPi and unzip them. The unzipped module directories contain a setup.py file Using a command similar to this, I was able to install them:
java -jar ~/jython/jython.jar setup.py install
All seemed well until I tried building the project for a second time. Again, it was another missing module (_mysql to be exact). This led to another round of research as to why my project wouldn’t build. As it turns out, the driver in the connection string I was using for SQLAlchemy was causing the issue. Since Jython was built using Java, it relies on the JDBC for connections to MySQL. In short, the JDBC (Java Database Connectivity)is an API (Application Programming Interface)that tells the client how it can connect to a database.
JayDeBeApi and zxJDBC are a couple of modules that could be used to fix the problem, however, they don’t mix well with SQLAlchemy’s create_engine() function. By this, I mean when I tried using the recommended driver, “jdbc:mysql”, that the function fails to parse the URL. This is probably because these modules construct the connection in a different way than SQLAlchemy and are more designed for parameterized querying.
The last hope that I had was in the documentation found here. Reading through, it was very detailed and well written. There is an SQLAlchemy example, but it’s connecting to an Oracle database using the module zxoracle. After another trip to Google to look for something similar, I came across the Github repo for zxoracle. Scanning through this code, I think it would be possible to modify this code to be used for MySQL. In the end, I decided that I needed to alter the course I was taking with this project.
The Solution
It wasn’t an easy decision by any means to change the implementation plan. Instead of importing the logging class and calling its functions, I decided to create an API for the logging class and create a client class that Jython will use. Since I already intended on making an API for logging, this wasn’t any extra work. Below is what the client class looked like and the Jython code in Java to call it:
Looking at the client.py file, a very simple function was written that creates a POST request that gets sent to the logging API. A dictionary that contains the application name, log message, and log event type gets sent along with the request. The Jython code in jython.java admittedly looks a little weird. What it basically does is import the Python file, create a function object, and pass the necessary parameters to that function. Just like earlier, the command I had to run that builds the Java project was:
javac -cp ~/jython/jython.jar jythontest/*.java
At last, I was finally able to build without getting any errors. To run the project, this command was used. Note that because my project required command-line parameters, it was necessary to add it in (the part that says “python”).
java -cp ~/jython/jython.jar:. jythontest.StartingPoint “python”
Once the project had finished running, I checked the database to make sure my log event had been inserted.
I think it was safe to say that at this point, I finally had a working project.
Final Thoughts
Reflecting on the events that occurred while trying to get the project to work, made me realize that maybe Jython isn’t the approach I’m looking for. On previous Java projects, I used the ProcessBuilder class to run all sorts of scripts. I am also very aware that Python has its own methods for calling APIs. I guess I was just hoping that Jython would save me a little more development time. In the end, I don’t regret the experience I obtained. If you happen to know what I did wrong while trying to get the SQLAlchemy driver to work, or notice any other mistakes I might have made, feel free to leave a comment. Happy coding and cheers! | https://medium.com/python-in-plain-english/java-python-jython-f887b356a92e | ['Mike Wolfe'] | 2020-10-11 08:37:19.495000+00:00 | ['API', 'MySQL', 'Java', 'Python', 'Sql'] |
A World Without Climate Role Models — 5 Years After the Paris Agreement | In response to many commemorative and reflective discussions taking place to mark the 5th anniversary of the Paris Agreement, Greta Thunberg boldly accused national and international leaders of creating “distant hypothetical targets” and “new loopholes with empty words,” ultimately falling short of every uttered promise.
With no intention of completely nullifying the attempts at the progress that has been made, I agree with her remarks. While electoral politics is inherently geared toward alleviating immediate concerns, governments have an obligation to anticipate future adversity, especially perils so clearcut as the ramifications of climate change. We stand in a situation now where these consequences are already perceptible and worsening.
And yet, five years after the signing of the Paris Agreement, there are no global role models on climate change action. Only Morocco and the Gambia are on track for meeting the 1.5 degree Celsius limit set forth in this agreement meant to hold nations accountable for their actions.
But the young activist was also correct to implore for our optimism and for a fervent, unbending commitment to making climate change mitigation and transitions toward a more sustainable global society our highest priority. All along, I have believed that the engagement of individuals and communities in the discussions concerning how to address the climate crisis will be imperative to ensure that appropriate action is actually taken in order to curb emissions and establish sustainable solutions moving forward.
Without awareness of the current and imposing ramifications of global warming continually incurred with our inaction, and the daunting facts held secret for many years that human action is to blame, any number of other misfortunes, more paramount at the moment, will claim the position of highest salience. Rapid transitions without the will to adopt greener technology and more sustainable solutions will inevitably feel like some form of loss.
But long, drawn-out problems — such as systemic racism, gender inequality, and, naturally, climate change — demand enduring commitments.
Often we complain about an absence in political will when we ourselves remain confined to past traditions and resistant to change. Governments will move forward with climate action more aggressively when we push them to do so. So engage in discussion with your climate change-denying father and choose to eat plant-based even when it annoys your friends; speak as loudly as you can and listen to your Mother. | https://medium.com/climate-conscious/a-world-without-climate-role-models-5-years-after-the-paris-agreement-4a7de84ac1d6 | ['Amanda Hanemaayer'] | 2020-12-20 17:55:52.768000+00:00 | ['Environment', 'Climate Action', 'Sustainability', 'Awareness', 'Learning'] |
Vegan for Keeps Submission Guidelines | Good work fueled by a Fair-Trade oat-milk dirty chai latte.
Thanks for your interest in joining our community!
What we are looking for: cultural criticism (particularly literary, extra-particularly #kidlit, which inspired the name of this publication), “white learning” and vegan-oriented social justice, reflections and experiments on personal growth and creativity through a vegan lens, interviews with vegan artists, veganized heirloom recipes, and plenty more that falls under the category of “we’ll love it when we see it.”
cultural criticism (particularly literary, extra-particularly #kidlit, which inspired the name of this publication), “white learning” and vegan-oriented social justice, reflections and experiments on personal growth and creativity through a vegan lens, interviews with vegan artists, veganized heirloom recipes, and plenty more that falls under the category of “we’ll love it when we see it.” While we would be glad to publish your journey-to-veganism story, in order to write for us we ask that you be 100% committed to an ethical vegan lifestyle (meaning that you are all in for animal rights). If you’re “transitioning,” you can let us know when you’re actually vegan.
If you’re “transitioning,” you can let us know when you’re actually vegan. We believe in excellent writers making an excellent livelihood, and that is why we suggest you pitch Tenderly first, since they are an official Medium publication (and as such can actually pay you beyond what you’ll make in the Medium Partner Program, which you should definitely sign up for before you start writing for us!)
A further note on writers making more money: we’d be delighted to re-publish posts that originally appeared on your personal blog.
Submissions should be free of grammatical and typographical errors. If we catch more than one, we’ll stop reading and ask you to revise and resubmit (ironic, yes, but like most editors these days, we do not have time to edit!) Do your utmost to write in accordance with Medium’s Curation Guidelines.
To be added as a writer, simply leave a comment on this post to introduce yourself. Once added, you’ll be able to submit drafts for our consideration.
We’ll be tweaking these guidelines over time, so do check back periodically. Feel free to comment or tweet to us with any questions you may have, and thanks again! | https://medium.com/vegan-for-keeps/vegan-for-keeps-submission-guidelines-138a4164a9c7 | ['Camille Deangelis'] | 2019-10-10 22:06:04.388000+00:00 | ['Animal Rights', 'Writing', 'Vegan', 'Veganism', 'Personal Growth'] |
How to feel like the King of the World | How to feel like the King of the World
Top 5 Benefits of Cold Showers (and some tips to start)
Photo from Xannah Xu on Unsplash
There was a period in my life when I started doing challenges, one after another, constantly. Most of them just passed by, while some stayed. This one I never gave up on.
Why?
Because if you want to feel good and get out of your comfort zone cold showers could be the strongest practice you will ever find out there.
I have been doing them daily for almost 3 months now: it is time I share with you the enormous benefits I got from it. You might be skeptical, I was, but you will never know until you will try, right?
In the meantime, here are 5 benefits I got from cold showers. Hope you will reach the same results!
1. Cold showers make you feel like the king of the world
The first benefit I noticed once I started taking cold showers was the amazing feeling I experienced once I finished. It is a mixture of joy and strength that I hardly could get from anywhere else: just amazing.
The reason behind that feeling is a natural reaction of our body. As human beings we developed a strong resistance to cold temperature, hence overcoming that block will give you the impression you could defeat any obstacle on your way.
Your decision to go under cold water is a conscious decision into stepping out of the comfort zone. By taking that step into the water, aware that it will hurt your comfort, you are taking a step into the unknown. Your body will never be prepared for what is coming. You will feel like you are taking part in a completely new fight, every time, winning it over and over again besides its harshnesses.
This is exactly what will make you feel like the king of the world.
Moreover, your decision will empower your resilience.
How? Simple. Cold water will cause your body to produces eustress, which is the kind of stress that forces our mental health to get stronger. So, when you will get out of that shower, not only you will feel like the king of the world, but also your resilience will permanently improve.
2. Cold showers refill your energies and make you productive
There are two types of energies you could get in your life: the one static and refreshing that comes from sleeping, and the one dynamic and explosive that you get from high impact activities, like jumping with a parachute.
A cold shower is like jumping with a parachute in miniature, it is like bungee jumping with your eyes closed. You get a fast boost of that dynamic energy but staying in your bathroom, and you get it for free!
One thing I experienced once I got out of the shower was exactly this enormous amount of rush power filling my body. Being under cold water for some minutes was recharging my brain and my muscles.
Of course, it was less strong than jumping from a 20k feet height but still considerable. There is no other way you could get that adrenaline that simple.
Moreover, that rush will make you feel the necessity of acting, the need of doing something, which might be very productive if you learn to use it properly.
3. Cold showers get you into a meditative state
The first time I got under cold water I noticed how it built a block between me and the external world. My mind was completely erased, and all the thoughts that were draining me disappeared. I could not think about anything else but survival and, with a little effort, I could stop that too.
Thus, the most important side benefit that you will get from cold showers is a deeper awareness of every inch of your body. At first, you will be able to distinguish between the parts of the skin exposed to the cold water and the relaxed ones. Then you will slowly become more conscious of your internal body by noticing how it fills up with air at every breath you take.
This is exactly what you want to achieve with meditation: the mental clarity given by the absence of thoughts, and the mental embodiment given by a deeper comprehension of your body.
4. Cold showers make you reconnect to yourself
When I first went under cold water I was so hyped by the benefits I did not think that much about how harsh could it be. The following repetitions were harder, but once you take that decision of going under you don’t come back. What happens next it’s the real challenge.
Staying under the shower is a constant internal fight that makes you ultimately discover yourself on a deeper level. With time you will start to recognize which patterns your brain uses to get you out of danger, and which to keep you resistant.
Being aware of the patterns that get you out of trouble is very important. First of all because you will recognize danger easier, and secondly you can stop your brain from overreacting in situations that are only apparently dangerous.
5. Cold showers improve your cold tolerance
I remember when I moved out and I started living alone. I was economizing on the bills so the temperature in my house was very very low. I had to put always my sweater on and it was not that comfy.
Then I started the cold shower challenge. After the first 30 days, I recognized how I was able to stay without any clothes on, at the same usual temperature, for around one hour, without feeling cold. Not only that, but also my general cold resistance improved, and I was able to remain in the house wearing just a simple T-shirt. | https://medium.com/get-better-togetter/cold-showers-how-to-feel-like-the-king-of-the-world-1c05f6cf2a23 | ['Cosmin Angheluta'] | 2020-05-16 15:10:17.798000+00:00 | ['Self-awareness', 'Self Improvement', 'Motivation', 'Cold Shower', 'Habit Building'] |
Fixated on Taking Selfies? You Might Have these Psychological Issues | Fixated on Taking Selfies? You Might Have these Psychological Issues
#2 needs to be fixed right now
Photo by Cristina Zaragoza on Unsplash
Is that the picture of a glass of milk? No, that’s a glass of black tea taken in my uber-cool new selfie camera!Apparently, the camera doesn’t like the ‘dark’ tone.
I know that joke is a bit of a stretch, but selfie cameras and the Artificial Intelligence powering them, have come close to creating a near-perfect version of anything it captures. They remove the spots, patch the scars, pull the beauty filters, and do a million things you can’t imagine.
Take a stroll down the mobile shop, see how the industry has raced to near saturation in selfie technology. The punch hole camera, the twin optics, the lens that magically appears from nowhere, all sorts of innovation within a tiny space at the top of your 6-inch device. We happily pay a premium for them. And we revel in posting selfies.
But does taking selfies mean you have some psychological condition?
After all, it’s a harmless means of fun that doesn’t poke into someone’s territory. Your face. Your camera. Your rules.
But let me tell you that taking excessive selfies can be an indication of an underlying psychological problem. But here is the million-dollar question: What’s ‘excessive’? What is the limit one has to cross to be bothered about it?
How much is too much?
The American Psychiatric Association (APA), in a study, confirms three levels of disorders linked to an excessive affinity for selfies.
The Borderline: Taking (atleast) three selfies a day, but not posting them on social media. The Acute: Taking (atleast) three selfies a day and posting them all on social media. Chronic: An uncontrollable urge to take selfies all day and post them (atleast) six times a day.
The author calls such people with an excessive affinity for selfies as SELFITIS.
So based on the above measure, are you a selfitis? Even if you are not one, I will encourage you to read further. I will tell you four reasons why people show a craving for taking selfies. No offence.
#1 You Could be a narcissist!
“The narcissist enjoys being looked at and not looking back.” — Mason Cooley
A narcissist is a person who pursues gratification from vanity or egotistic admiration of one’s perfect self-image.
From blowing his own trumpet to an outright exhibition of arrogance, a narcissist would seek to build his image, and no wonder selfies occur to him as a convenient tool.
To maintain his own meticulous and perfect image, a narcissist has to post his flawless pictures. While letting someone handle the camera can go, either way, the ability to control his picture, with the perfect angle and the right looks, gives him the necessary control that allows him to have the image exactly as he wanted it.
Besides, narcissists are also people who want them to be considered special. A selfie lets him be the lone subject of a photograph and feeds his craving to be the star. It allows them to set the exact public image they yearn for.
A study published in The Open Psychology Journal, done by researchers from Swansea University and Milan University, confirms the link between selfie craving and narcissism. Out of the 74 test subjects in the study, those who used social media through excessive visual posting showed a 25% increase in narcissistic traits.
#2 Do You have problems presenting your body?
Low self esteem involves imagining the worst that other people can think about you. — Roger Ebert
Many people are not impressed by the way they look, and much like a narcissist, they want to be in control of their images, albeit for a different reason.
From being fat to having a slightly long nose, there is a myriad of details about themselves they would like to either hide or project. In my part of the world, fair skin is another illusion that’s coveted. And hence the cams that turn black coffee to milk!
Selfie looms in the air as a rescue for all such people nursing a low self-image, for you can have the ‘perfect’ shot to your design.
They adjust the angle, tweak the settings, put the filters, and use every big and small feature to ensure that what they don’t want is not captured and what they want is standing out and staring at the beholder.
In a study published on Sciencedirect.com, done with a participation of 259 young women, it was found that social networking sites’ selfie activities are linked with body-related and eating concerns.
However, such negative impressions of oneself can work the other way round too.
For instance, if you have abysmal self-esteem, so much that you think your ‘poor looks’ cannot be fixed with any advanced effect of your smartphone, you might entirely withdraw from the act of taking selfies.
#3 How is your social life going?
A healthy social life is found only, when in the mirror of each soul the whole community finds its reflection, and when in the whole community the virtue of each one is living. — Rudolf Steiner
If you take a lot of selfies and are alone in most of them, you better ask this question yourself.
Ideally, a picture should be taken to cherish a special moment. But if most of your selfies are not encompassing such moments and instead show you in different backgrounds, it could be a strong indication that you are not entirely content with your social life. Perhaps you yearn to mix more but just cannot.
Peerayuth Charoensukmongkol, who researched the connection between personal characteristics and selfie addiction, says that selfies are meant to improve self-disclosure and social communication on social media sites, and therefore, essential for those who experience loneliness.
Posting pictures and getting feedback from social media websites can enhance their social communication. However, the approach can backfire as relationships erected through social media communications can often be shallow. This could further worsen your loneliness.
Your loneliness can have several reasons behind it. It is possible that you recently broke up with your partner or that you have social anxiety issues. It makes sense for you to build a healthy social life or address the core issue, rather than seeking temporary relief in selfies.
#4 Look at me!
Seek respect, not attention. It lasts longer.
Some people can’t get enough attention and approval. Taking your pictures and engaging them on social media is one of the easiest methods to draw eyeballs towards you. Besides, with all those filters and smiley faces, you can build a ‘my-life-is-cooler-than-yours’ aura around you.
For such people, their mind perceives the ‘likes’ and ‘reactions’ they receive as a token of acceptance. Needless to say, if your self worth is invested in someone else’s opinion about you, you will end up living a life to impress. You will seldom listen to your inner calls.
Besides, such attention-seeking behavior, in the long run, may adversely affect your self-confidence.
For instance, if one of your pictures fails to draw the same successful results as your previous one did, suddenly, you may start doubting yourself. “Have people stopped loving me” “Don’t I look good in that photo” a million questions erupt.
In an article published in psychologytoday.com, the author, Martin Graff Ph.D., says that attention-seeking may be one of the main reasons people take selfies and use social media. He adds that people would do so to feel more popular.
Letting others’ opinion dictate your life is not the way to live. If you are posting more selfies to gain attention, you need to rethink your priorities.
Final thoughts
If you go through the image gallery of your smartphone, rest assured, you are going to find quite a few selfies. But that wouldn’t make you a sefitist or an addict. You have already read the parameters of becoming an addict. If you don’t fit that profile, you have nothing to worry about.
However, if you are overly drawn to your front camera, with an irresistible temptation to post them on social media, there are things to ponder. You have to start introspecting now! | https://medium.com/indian-thoughts/fixated-on-taking-selfies-you-might-have-psychological-issues-a751927b4ed3 | ['Aravind Balakrishnan'] | 2020-12-11 14:59:27.530000+00:00 | ['Technology', 'Mental Health', 'Psychology', 'Culture', 'Social Media'] |
Self-Care: You Need It Too | Self-Care: You Need It Too
How caregivers can learn to care for themselves
When you’re caught up in life, busy attending to bills, housework, pets, and maybe even a family member or two, it can be really easy to forget yourself. I don’t mean forgetting your personality outside of being a caregiver. I mean if you’re always busy caring for someone else, who is going to care for you?
Photo by Keenan Constance from Pexels
Rianne Grace made an excellent point in her story What My Self-Care Looks Like Today: Self-care is not always pretty, but it is necessary.
My family has a long, long history of health issues, from cancer to diabetes to fibromyalgia. As one of the healthier members of the family (not to mention the youngest) I was left with a lot of the heavy lifting, so to speak. I was born a year or so before my mom was diagnosed with fibro. The intense lack of energy from the disease left her pretty well chair-bound for the better part of four years. She’s since learned to manage it better and can get around normally. However, this caused me to grow up with the caregiver mentality.
What is the caregiver mentality, you ask? It’s where you’re so used to caring for another person, physically or emotionally, that it shapes your entire view of living. I was always the able-bodied young ’un who was obligated to help because I could. Because of that, I can’t stop myself from trying to help every single struggling person I come across.
I became so focused on supporting my struggling family members, I forgot that I was struggling too.
Now, I’m not saying it’s a bad thing to have this caregiver mentality. And I’m certainly not saying it was anyone’s fault; it’s a good thing to want to help people. What I’m trying to say is to be sure you’re taking care of yourself. I became so focused on supporting my struggling family members, I forgot that I was struggling too. Take it from me that once you’re focused on caring for someone else’s needs, it can be very easy to forget that you have needs as well. | https://medium.com/write-well-be-well/self-care-you-need-it-too-9873d5d42da0 | ['Pj Ryder'] | 2019-09-24 11:16:01.441000+00:00 | ['Self Care', 'Support', 'Mental Health', 'Psychology', 'Caregiving'] |
101,572 Words in 30 Days | by LaDonna Witmer Willems, with guest appearance by Chris Baty
Artwork by Samuel Pasquier
Every November, hundreds of thousands of writers around the world hunker down to write a 50,000-word novel in 30 days. (That’s 1,667 words per day.)
It’s called National Novel Writing Month or, more colloquially, NaNoWriMo.
These keyboard masochists gather in groups for write-ins, or sequester themselves in libraries, in cafés, in corners, or wherever they can find the space and time to write, unmolested by self-doubt, self-criticism, and other acts of self-bullying (as specified in NaNoWriMo’s Month-Long Novelist Agreement and Statement of Understanding.)
To be able to write your way into a project, free of the gremlin of self-criticism, is no small thing. For many would-be writers (and full-time writers, too), getting started is the hardest part of the creative process.
That’s because we often hold in our heads this utopian vision of what we want to make, but when we try — or even think about trying — to take it out and make it live in the visible world, it feels like it’s falling apart.
Booking it
For months, I had a writing project brewing in the back of my brain. It wasn’t a novel; more of a memoir-ish thing. I kept saying I was going to start, but had yet to ink a single word on paper.
Luckily for me, I sit right next to Chris Baty in Writer’s Row at the Dropbox Brand Studio. Chris isn’t just a fine human person and Stanford professor of writing. He’s also the creator of NaNoWriMo. And he’s written a novel in 30 days, every year, for the last 20 years.
So when he suggested I use the framework of NaNoWriMo to bang out a 50,000-word first draft of my not-novel, I signed up for the challenge. And it was, indeed, a challenge. To make that word count deadline, I wrote wherever and whenever I could. I wrote in airplanes and pickup trucks, in beds and bathrooms. I wrote on vacation, on Thanksgiving, and on my birthday. I even wrote during those first five minutes of work meetings when you’re sitting alone in a conference room waiting for everyone to gather.
Some days I wrote well over 3,000 words. One day I wrote only 144. But every morning when I walked in to Dropbox, Chris would swivel his desk chair my way and say with a knowing twinkle, “How ya doin’ today? How’s your word count?”
Between the two of us, a first-time NaNoWriMo-er and a 20-year veteran, we wrote 101,572 words in November. (I won’t tell you who wrote more, but 51,545 of those words were mine.) Here’s how it went:
LaDonna and Chris discussing how two Dropbox writers each wrote a book in a month (and held down their day jobs) — Photo by Chris Behroozian
The first-timer and the veteran: a debrief
LaDonna: So, Chris, I want to know-in your 20th year writing a novel for NaNoWriMo, what’s different and what’s the same?
Chris: I’d say there’s a lot more confidence. After the first time, when you realize you can do it, that’s the game-changer. That’s the Eureka moment.
LaDonna: It’s mind-blowing, yeah!
Chris: You’re like, “Whoa, there was a book in me I didn’t know was in there!” And then you start asking yourself, “What else is in there?” And it could be more books or it could be wanting to start a new business or learn a foreign language or get back to the viola lessons you gave up when you were nine.
It’s that sense of discovering things inside you that you didn’t know were there, or you’d forgotten were there. And the other big wow is that it feels great to do it. I mean, it’s work and it hurts sometimes, but it’s also really fun. Especially when you start hitting that place where your imagination comes up with the connections and you see themes emerging. If you’re writing fiction, it happens when the characters start taking the story in different directions, and that feels incredible.
I think a lot of people assume professional novelists or professional writers have a supercharged part of their brain, that their brain chemistry is different. But everybody who starts writing and keeps writing has that process of discovery and surprise and wonder. And once you’ve experienced it, the next times are not quite as miraculously eye-opening.
In fact, the second time people do NaNoWriMo, it’s legendarily difficult. People will look at that first year and say, “I didn’t really plan and it turned out pretty well!” And then they plan four times as much and expect it to be four times as good or the output to be four times as refined, and instead it sucks four times worse because you’re suddenly putting all kinds of pressure and expectations on yourself.
The first draft is always going to be terrible. Promising, but terrible. Once you start hoping that because you’re more experienced at this, you can write a second draft on your first try, that’s where things start to hurt a little bit more.
LaDonna: So, after 20 times, do you think there’s going to be a year where you say, “Meh. I don’t need to NaNoWriMo this year.” Or will you just keep going until you’re too old to smack a keyboard?
Chris: I do feel like there has not been a year so far when I thought, “I’m not going to do this.” I think it gets in your blood a little bit. Like the leaves start changing, and you get that autumn smell, and you’re like, “I NEED TO START WRITING! GET ME A COMPUTER!”
Fall is such an interesting time. It feels like November is a month for cocooning and turning inward in general; it’s spitting rain outside, and everything is changing, and NaNoWriMo fits this notion so beautifully.
There’s just something so appealing about starting with the seed of an idea and seeing that idea blossom and then wilt and then blossom some more. It’s pretty intoxicating in a way that few things are. So I can see myself continuing to do this.
LaDonna: I was telling someone in October that I was going to do this, and she said, “November? That’s a terrible month! You’ve got Thanksgiving, and you’ve got all of this stuff. Why would anyone want to do all this writing in November?!”
And my thought was just, “There is no good month!” Right? There’s never going be that perfect time to sit down and write a book!
So besides fall and the magic of the leaves turning and whatnot, what made November the NaNoWriMo month?
Chris: So we actually did it in July the first year. And it was great. It was a little challenging in that a lot of people went on vacation, so they were writing while they were supposed to be relaxing. But it was fun.
The first year there were 21 people; it was such a small group. There were six of us who crossed that 50,000-word finish line, and we were the ones who would actually get together at night and write together. So when we were planning it again, we were going to do it in July the following year too, but then people were busy and everyone was like, “I can’t do July. How about August?”
And it just kept getting pushed back until we landed on November as the time nobody had any plans or excuses. And then it just stuck in November.
LaDonna: I like it. It feels like a nice roller coaster ride into the holidays.
Chris: Yeah. You know, I think you’re right that there’s never going be a good time to write your book. February is the clear worst month because it’s just too short. A lot of people think January would be good because it’s like starting fresh, a lot of people have New Year’s resolutions around creativity.
But this is something I’ve been telling everybody-any month can be National Novel Writing Month. If you can get at least one other person to agree on a set word-count goal and a time frame, you’re golden.
The magic is that there are a couple hundred thousand people doing it at the same time which means there is a lot of encouragement in the air. I mean, you and I, just knowing that we were going to get to check in because we sit next to each other at work, that’s really powerful.
LaDonna: It is. It is quite huge. On the day that I wrote only 144 words, I remember being glad it was a Saturday because I didn’t have to see you the next day. Because I knew you’d ask, “What’s your word count?!” and I’d go, [whispers] “One hundred and forty-four.”
Chris: Yeah, and then I’d just spit on you and be like, “You’re a fraud. You’re a sham.” [laughter]
LaDonna: Totally. And then we wouldn’t be friends anymore. [more laughter]
Someone asked me after I had finished: “Where did you find the time?” And I said, “I didn’t. I stole it.”
Five minutes here and an hour there. Deciding not to check social media and getting 15 minutes back. I know there are some writers who are like, “I’m getting up at 5:30 every morning, and I’m going to write for an hour.” And at this stage of life, for me, with a child, I can’t. Because she would for sure wake up at 5:35 and ruin the plan.
Chris: Right, and she’d just want to hang out and talk about cereal. Yeah.
So, LaDonna, you’re a professional writer, you’ve been part of this general rodeo most of your life. Was it surprising to you that you could get a book written in these pockets of time? Did you see yourself as someone who would need to block out two hours on a Sunday and write?
LaDonna: Yeah, I did. I decided I wanted to write a book before you suggested jumping on NaNoWriMo. And I remember thinking, “Well, I guess maybe every Wednesday could be my book writing day.” And then, you know, a couple Wednesdays went by and book writing didn’t happen, because life.
So it was a wonderful discovery to me that in even just five minutes, I can get down something worthwhile. I kind of knew that about poetry. But poetry is so much less intimidating to me, in part because I’ve done it for so long but also because it’s moments. It’s that skinny column of words, and you’re not writing an epic, usually. And so I knew I could bang out a poem in five minutes-it might suck-but it would be there, and I could fix it later.
But the idea of writing a book in five-minute chunks had never occurred to me.
Chris: Well, it’s not ideal. But we are forever going to live in a not-ideal world until we become independently wealthy, and then we can buy the castles that we deserve …
LaDonna: … and hire ghostwriters.
Chris: Exactly! Or literal ghosts from the castle can write our books!
I think there’s something nice about discovering that there are these pockets of time. And this is where I think word count is actually quite helpful. Because books are magical, squishy, strange, mysterious creatures, so you feel like it wouldn’t work very well to pin it to this very linear sense of “How many words did you write?” or “Your total goal today is 1,667-where are you on that spectrum?”
But in five minutes you can maybe write 100 words, and that’s a deposit in the word bank. And that starts to feel like you’ve achieved something. Whereas, if you write for five minutes and you don’t have that word count ticker in your head… you look at what you’ve made and you’re like, “Bleah.”
But if you’re like “Bleah” plus 100 words, that’s a good bleah!
There’s this writer, Rachael Herron, who I really love. She lives in the Bay Area and has done NaNoWriMo infinity times and has published most of her NaNoWriMo novels. She’s very prolific. And she says that the difference between the writing sessions she felt bad about-the ones that felt like pulling teeth, but she wrote through it anyway-and the sessions where she felt perfectly in flow, when she goes back and reads them both, she can’t tell the difference between the two.
So even though one writing session during the creation process might feel better than the other, it doesn’t matter. Because, in fact, the thing you’re creating is your voice.
LaDonna: One night during NaNoWriMo, I was writing at the dining room table and my husband’s making dinner, my daughter’s in and out, and I was getting increasingly annoyed with both of them. I thought it was because they were interrupting me-I don’t have a private place in my house where I can go and close the door and write-but then I realized, much later, that it was actually because what I was writing about was really dredging up some stuff. I was writing about my mom, and I got quite triggered by all of it. And I had to go back to both of them later and apologize and make sure they knew it wasn’t their fault.
Do novels do that to you, too? Are they bleeding into your life?
Chris: Oh, yeah. I mean, you’re writing these scenes with these people where big things are happening and somebody’s dying or a relationship is ending or something, and you really get pulled into it.
In the NaNoWriMo forums, there’s a thread dedicated to weepy novelists. And there’s a badge dedicated to the moment when you’re writing your novel and you start crying.
That happens to me every novel, you know? Especially if you’re listening to a good playlist that’s just punching you right in the feelings. And you’re writing a scene of great change or departures, and then real life comes knocking, and you’re like, “NOOOO! Something is happening here on this page and I’m with these people.”
I mean, what a great thing, really.
LaDonna: So you’ve got this momentum in November-you’ve written thousands and thousands of words, and you’ve built this daily habit and reached your 50,000-word count, and then you hit December. I wanted to let it marinate before I dove into editing, so I didn’t work on this project for a month or so. Do some people just keep going?
Chris: I think it depends on what you want out of the experience. If it was to build the habit and now you want to keep going, that’s great. But 1,667 words a day is an unsustainable amount of words, in my opinion. I mean, some people can bash that out in, like, 20 minutes because they’re just great typists and their brain works well with it.
But, to me, if you want to keep going, I would say drop it down to a much smaller word count-so you’re looking at 500 words a day, five days a week. Keeping some kind of schedule, I think, is good.
I do think, though, that much like running a marathon, we’re exhausted now. This has been an exhausting endeavor. So I do think it’s important to go back and reconnect with your life while you let that thing you wrote rest.
When we’re writing, we’re just so close to it, and that’s the right place to be. But when we’re revising, we need to start with some distance from it. Because there are going to be parts that we felt very connected to-and maybe they’re great writing-but they don’t fit in the book. And we’re going to have to say goodbye to those. We’re going to have to realize also that there are holes that are going to be pretty time-consuming to fill.
When you have some distance from the writing process, you can make those decisions with a more clinical eye. And that’s exactly the right place to be, because you’re making hard decisions. But it’s also important to let it rest because you’re just tired! I mean, that was quite an experience. What were we all thinking? [laughter]
So I have a question for you. There are a lot of NaNoWriMo haters out there or NaNoWriMo skeptics who say, “This is just encouraging crappy writing. It’s telling people they’ve done something that actually they haven’t. This isn’t a novel-it’s 50,000 words of a first draft!”
I’m sure you heard that out in the world, so were you a NaNoWriMo skeptic at some point when you first heard about it, or did it always seem interesting to you?
LaDonna: I was always wowed by the idea, but I stopped at the word “novel” because I have never aspired to write a novel. So when you suggested I use it to write a not-novel instead, lots of light bulbs started going off in my head.
But, to me, it’s not the promise of “you will have a novel” at the end of November-it’s “you will have a beginning.” And I think that beginning, for many of us, is so difficult to achieve.
For me, it was really super-helpful, not just to know that I wasn’t alone but to know that there were rules. And the rule was, you cannot go back and look at it and judge it.* I took that really seriously.
When I do go back and look at it, I know I’m going to see parentheses that say, “UGH! THIS IS AWFUL!” Because whenever I had that thought, I would just write it down and keep going. Had I not had that framework, and those rules, I would have stopped myself 40,000 words ago, thrown up my hands, and said, “Who am I to think that I can do this? This is crazy, this is terrible, no one wants to read this! I should stop now.”
But since I was purposely told that I was going to hear that voice and I should tell it to shut up and keep going, I did.
So maybe there aren’t a lot of novels that have been created, but there are a lot of beginnings. There are beginnings that could become something.
How many of yours have you gone back to?
Chris: Five or six.
LaDonna: Five or six out of 20 is pretty awesome.
Chris: Yeah, and I think that’s the nice thing about the 30-day time frame, too. A lot of people end it feeling like, “I just don’t like that book that I was writing,” and they don’t go back to it.
But that’s OK, because you learn so many things about how to build a book and where things can go wrong for you, and about your own approaches as a writer, and what inspires you. And it’s not so hard to let go of, because you were just writing for a month.
LaDonna: I loved that, too! Because it was like, “You can do this” for 30 days. You can not eat carbs for 30 days. You can write 1,667 words each day for 30 days.
Chris: You know, there’s this notion of the “writer’s retreat,” where you get put up in this beautiful house overlooking some ocean somewhere and get to write. I think the more powerful model is to have it happen in the middle of our busy, hectic lives and to learn how to carve out time. Because the writer’s retreat on the coast-sure, it may happen for you, but that’s not going to be a regular part of your life.
But if you’ve learned how to create a writer’s retreat in the middle of everything else going on, that will be the ongoing, powerful, sustaining thing that helps you get this thing done.
LaDonna: There’s not just the writer’s retreat but the sense that the “muse” will come, and it will be beautiful, and words will fill my head and fall right onto the page. I’ve learned by doing this for a living that, actually, nothing will happen unless you just start putting words down. Muse or no muse.
I used to wait for a magical feeling and the right… whatever. The right desk. The right light. The right socks. And I don’t anymore.
Chris: Yeah. You can write barefoot. It’s fine.
Any month is Novel Writing Month
If you’re feeling energized and inspired and itching for a blank page to make your mark on (and why wouldn’t you be?!), Chris’s book No Plot? No Problem! is a great place for getting-started ideas.
Also, it’s important to remember that whatever you want to write is legit. You want to write start a novel in 30 days? Great. But you could also finish a novel. Or revise one. Or write a not-novel. A series of essays. A blog post every day. A poem a day! (I’m happy to tell you that April is, in fact, National Poetry Writing Month: NaPoWriMo.)
So go-find yourself a comfy corner! Steal 15 minutes. Shut the door on that self-critiquing gremlin and put some words on a page. You might write your way straight into a book. Or at least a beginning. | https://medium.com/dropbox-design/101-572-words-in-30-days-c05a6c714a2d | ['Ladonna Witmer Willems'] | 2020-03-02 18:30:31.241000+00:00 | ['Design Thinking', 'Design', 'Writing', 'NaNoWriMo', 'UX'] |
Aligning Sales And Marketing SaaS Teams | In the Digital Age, cohesion between departments is critical towards creating the seamless customer experience that consumers not only look for but expect, when considering new brands and businesses. A report by Forrester Research supports this by concluding that businesses with proper alignment see a 32% increase in revenue growth, while organizations with less alignment actually see a 7% decrease.
Organizational alignment is particularly important between sales and marketing teams, as these two departments are so closely connected throughout the purchasing process. However, aligning sales and marketing and achieving this level of cohesion presents a lot of obstacles for companies. After all, sales and marketing have always been kept in separate containers. They still remain apart in many organizations.
If your business still has this traditional structure, you should consider the powerful impact that aligning marketing and sales can have. Beyond meeting this new customer expectation, companies that have made this shift in their structure have seen 36% higher customer retention figures and 38% better success rates in sales opportunities.
This discussion will focus on the steps that companies need to take into consideration as they push for alignment between marketing and sales teams.
It Starts With Your Team
Your first step is educating your organization, particularly your salespersons and marketers, about what alignment means and how this change will affect their duties and day-to-day work life. For some, this will be a hard adjustment because marketing and sales have for so long operated in their own bubbles.
The key is showcasing how this change is going to affect the organization and promote a positive impact on revenue and growth. (Feel free to utilize some of the sales and marketing alignment statistics we’ve shared to justify the change to your staff). The truth that you need to get across to your organization is that times are changing — customers are changing. Adapting to these shifts is a matter of growth and survival.
Most organizations will face some level of resistance from staff during this period of increased alignment, whether this is intentional or not. Some employees may be actively against merging sales and marketing teams together because it challenges everything that they’ve come to know and learn. Others will be on board with this new direction, but just lack the mindset that it takes.
Unfortunately, you may have to make some tough personnel decisions. This means eliminating some staff and bringing in forward-thinking individuals that have experience working for an organization where marketing and sales work closely together, instead of apart.
Assign Leadership To This Newly Aligned Team
In the traditional, un-aligned model, sales and marketing departments each have their own leader (VP of sales, VP of marketing, etc.). As your company moves towards a more aligned organizational structure, this can create a lot of conflict.
Do you allow both department heads to continue existing as part of a team? Do you let one leader go and appoint the other as the head of sales and marketing? Do you create a new leadership role, like chief revenue officer, to manage the alignment between these two teams?
It’s best to have a single head to control both departments. While keeping both department heads may keep everyone happy in the short term, as no one has to be let go, if those individuals can’t effectively work as a cohesive, conflict-free team, alignment doesn’t occur.
Review Your Revenue-Focused Strategy
Alignment means treating sales and marketing as one entity. These once-separate departments now need to act with a singular, unified focus. The easiest way to achieve this is to focus your organization solely on driving revenue. This makes a defined path to guide both teams and ensure that everyone is marching in the same direction and with the same goals in mind.
An aligned strategy has many critical components that your teams need to research and understand before proceeding:
What’s the target market and what types of buyer personas exist in that audience?
What messages, channels, and tactics do these buyers respond to most?
What separates us from the competition?
How do we utilize sales and marketing together to produce more revenue?
Many of these questions your company has already answered, probably multiple times.
However, readdressing them with your newly aligned teams ensures that everyone is indeed on the same page. Sometimes, poor alignment occurs because sales have a different understanding of the target audience than marketing, or they view the brand’s unique selling point differently.
Create A Seamless Journey
Customers just don’t follow the traditional paths to making a purchase that they used to. This is part of the reason that alignment is so crucial in the digital age. Thanks to the Internet, consumers, and brands sometimes interact on over 13 touch points before a purchase is made. Some of these are marketing-focused, while others are sales.
Once you’ve created your cohesive strategy focused on producing revenue, you need to begin finding ways to utilize both sales and marketing touch points to facilitate a frictionless buying experience. Due to the sheer number of possible channels involved in a single customer’s purchasing journey, this is not an easy puzzle to solve. Not to mention, every touch point is unique in its own way, which requires lots of testing and learning to crack the code of each new platform.
Eliminating friction in this customer journey involves effectively tracking their progress across all of these different touch points. As you monitor their activity, you learn about their unique preferences, needs and behaviors, which allows you to produce a smoother journey. When sales and marketing are misaligned, it can often create an experience where the customer feels that they are starting their journey over and over at each new touch point. Not only does this result in a clunky journey, but it also severely disinterests them in shopping with your business at all.
Sharing Data-Born Insights And Business Intelligence Tools
One of the keys to unlocking the puzzle of the customer journey is data. If sales and marketing were the apocalypses, data would be canned food. Because so much of the customer journey takes place online, there is a lot of data being created. Within all of this data is everything you need to learn about your customers.
Extracting these customer insights from all this raw data, however, is a bit of a needle in a haystack conundrum. Two key obstacles get in the way:
1. The easy part: finding the right tools and solutions to help your organization collect, sort and analyze all of this unstructured data
2. The hard part: understanding which data points are most relevant and worthy of tracking to provide the answers to your company’s most pressing and revenue-producing questions
Misalignment makes these obstacles even more difficult. You have two departments asking their own questions and sometimes using their own data tools. Once you bring these departments under the same roof, it becomes easier to realize the key metrics that are most valuable towards furthering your organization’s goals. Though, “easier,” in this sense, means removing only some of the hay from that pile with the needle.
Communication, Communication… Communication
The best tool that an organization can utilize to achieve seamless alignment of their sales and marketing is simple communication. These teams, which have operated autonomously of one another for so long, now need to work side by side.
For example, marketing needs to create campaigns that aid sales’ strategies, while sales need to leverage marketing’s messages in their pitches. This produces that cohesive, frictionless purchase journey that organizations want to give their customers.
There’s some simple, yet effective communication strategies that can bolster your organization’s alignment. For example:
Team Meetings: No one likes large meetings, but in a properly aligned business, they are very essential. It’s a critical time to reiterate the latest goals, look at the current metrics and discuss new ways that sales can support marketing and vice versa.
Feedback Loops: One of the more undervalued communication techniques is creating a feedback loop between marketers and salespersons. This creates an ongoing conversation about what’s working and what isn’t between these two, newly-connected teams. This feedback can quickly be applied and improve strategies in the immediate future.
Open Office Layout: Changing the layout of your office to mix sales and marketing professionals together makes it much easier for natural communication to take place, whether it’s asking a simple question or collaborating on a new campaign.
Conclusions
Aligning your sales and marketing strategies is all about removing friction from the customer journey to generate increased revenue and more loyal clients. Ironically, achieving this alignment can add friction to your organization and even produce tension among your sales and marketing teams.
By following the tips included in this discussion, you’ll successfully complete this transition with less turmoil. Any dramatic chance of this caliber is bound to create some disruption, but your staff will quickly realize that an aligned business performs and operates smoothly and to more significant effect, in terms of growth, revenue and overall success.
https://upscri.be/hackernoon/ | https://medium.com/hackernoon/aligning-sales-and-marketing-saas-teams-19ba70fcedc9 | ['Andrew Gazdecki'] | 2019-04-25 13:16:00.940000+00:00 | ['Marketing', 'Startup', 'Alignment', 'SaaS', 'Sales'] |
Create a Running Docker Container With Gunicorn and Flask | Running With Local K8s via Minikube
Assuming you already have Minikube running on your machine, follow the steps below.
In order to use local Docker images, you need to run:
eval $(minikube docker-env)
Note that you should do that on each terminal you want to use.
Next, build the image:
docker build -t marounbassam/hello-flask:v1 .
Run on kubectl and expose the deployment:
$ kubectl run hello-flask --image=marounbassam/hello-flask:v1 --port=8003 --image-pull-policy=IfNotPresent
$ kubectl expose deployment hello-flask --type=NodePort
Now we can reach the endpoint of our application: | https://medium.com/better-programming/create-a-running-docker-container-with-gunicorn-and-flask-dcd98fddb8e0 | ['Maroun Maroun'] | 2020-11-04 16:37:54.771000+00:00 | ['Docker', 'Python', 'Gunicorn', 'Programming', 'Kubernetes'] |
Lowering Your Stress During the Holidays | Taking It Easy
This Christmas holiday season, we get to sit down with the people we live with and share a feast where we acknowledge the things that happened to us, both the bad and the good.
Without the bad, it can be hard to appreciate and enjoy the good. We savour the good because it is a luxury, and we lap it up. We deserve happiness, just as much as the next person, so there’s nothing wrong with a little enjoyment every now and then.
Photo by Nabil Boukala on Unsplash — I liken happiness to honey and it’s okay to enjoy it sometimes.
More often than not, a lot of us are plagued by ongoing stressors. Stress can impact a lot of areas in our lives, including our relationships and our perceptions of reality.
As studies have shown, emotions can and will influence how we process neutral information. While it’s okay to be stressed sometimes, when your stress impacts your ability to make credible and reliable decisions, we sometimes need to take a step back and keep it easy.
If we cannot control the outside forces that bother us, the only thing left to do is influence how we respond to those terrible situations.
If that means doing a minimalist version of sought-after rituals and traditions, then that might be what you need. For example, let’s say you typically go all out in decorating your home to be that picturesque image for your neighbours to admire.
This year, it’s more than okay to take a break, especially when we’re feeling more tired than usual. Plus, at the end of the day, we celebrate Christmas for the warmth and goodness it provides us, and not necessarily for the aesthetic luxury.
Photo by Amy Humphries on Unsplash — Nothing like a little warmth and joy.
There’s nothing wrong with working hard either, as long as you know how to pace yourself and take it easy. While we have a long year ahead of us, we need as much relaxation as we need, especially if we need to continue to fight our proverbial monsters. For now, we are readying our armour, ready to tackle and slay our demons, once and for all. | https://medium.com/preoccupy-negative-thoughts/lowering-your-stress-during-the-holidays-d2d21c8ce074 | ['Synthia Satkuna', 'Ma Candidate'] | 2020-12-24 19:30:57.178000+00:00 | ['Stress', 'Emotions', 'Mental Health', 'Validation', 'Psychology'] |
How startups are inverting the marketing funnel | Some weeks ago I was discussing my first months in Growth for CompareEuropeGroup, the largest financial comparison group in Europe, following the success of its sibling group in Asia. CEG has ventures in Denmark (Samlino.dk), Finland (VertaaEnsin.fi), Belgium (TopCompare.be), Portugal (ComparaJá.pt) and Norway (Samlino.no), all of them seeing considerable growth.
Sat down in a nice coffeehouse in sunny Lisbon, an experienced digital marketer was inquiring me how is our approach to the customer conversion path, and what is the storytelling we use to attract the customer.
My very early-stage experience forced me to think quickly to provide an answer: I haven’t outlined one. He was surprised. I later explained a bit more:
In order to grow in a sustainable way (OK, as much as feasible…), I cannot think of the traditional marketing funnel to outline my digital strategy. I don’t have neither the budget nor sufficient insight to know what is the storyline I will tell to my customer.
A bit surprised to hear this, he let me carry on.
The approach we take is to use, optimise and exhaust the more intent-driven channels and then utilise the revenue growth to reinvest in more awareness channels.
So you’re not telling a story to the customer, he replied. And with this sentence I realised that he was missing the point.
More than wanting to create a storyline for the customer, I want to the customer to create it for me.
This is the beauty of digital channels. The traditional strategy, planning and execution cycle that lasted several months is now shortened to days. Moreover, it is iterative more than ever. If I can have (almost) instant feedback, why not letting the customer tell me what works for him/her?
The more interesting part is how this affects the marketing funnel. Looking at the traditional funnel (see below), traditional businesses rely on hypotheses to define the which story should they tell the users. “Let’s use this TV ad to create Awareness, then outdoors will bring Consideration, Conversion is done with a door-to-door”. Most of theses hypotheses come from our own assumptions of the product and the customer, but were they validated? Good marketers have done their job and ran some focus groups, but were these representative? We may have different answers to the questions, but the bottom line is that the digital world allows us to test these hypotheses in a very short period and take actions on the outcome.
Credits to Travis Balinas, outboundengine.com
Why am I being fussy about this so-called inversion? Sustainability. In order to grow these start-up businesses where cash is scarce (despite the usual hype around funding rounds, in which cash comes to allow marketing and operations to survive), the traditional marketing funnel is simply not available. TV is not an option, outdoors hardly. The actual only option is capture the customer that is ready to buy. For a B2C product, start-ups aim for search engines, whereas B2B typically requires more people interaction (marketing becomes sales).
Andre Albuquerque (Uniplaces) was brilliant at explaining how channel utilisation is streamlined and put into cruise control, freeing up resources to explore other channels:
After enough time of deepening the channel you get to cruise control (acquisition cost is maybe stable or improving at a reasonable % rate), so it’s time to restart testing more channels to grow your metrics (second red circle), and number of channels being tested increases again (third red circle), and the loop restarts. Overtime you stack up acquisition channels and your absolute metric values grows until you hit the holy grail trend of the hockey stick curve (orange line).
Credits to Andre Albuquerque for such a nice chart :)
Following what I said earlier, the first logical channel to explore are Action-related channels, such as Search, since it captures the customer with greater intent to buy/convert. E-mail marketing and Affiliate traffic can be also be included in this bucket, the former requiring a level of engagement with the user (or not, since several tools can stereotype your customer and provide you a “look-a-like” persona).
The natural next step is to move on to Interest-based channels, such as Content (through your own blog for instance) and Referrals. Building on top of your persona (created through data gathered in the Action channels), you can now reach out to a greater audience, that still resembles in some aspects your current customers.
Display and Social channels belong then to the Awareness layer of the marketing funnel, which are available to reach in a targeted and segmented way a greater, less-informed audience. These channels are then used when all the channels “below” have matured and been streamlined. Finally, TV and Outdoors can be used a later stage to “shout to the world” about your products’ existence. Most start-ups take their time to rely on these since targeting is much more inaccurate.
Marketing funnel — adapted to the digital world.
As mentioned above, the good performance of a channel at the bottom of the funnel will fund the development of the upper layer of channels, often at higher cost of acquisition (CPA). How can a start-up support a growing CPA? Scale, scale, scale. Cross-sell. Get more money from each transaction, or get more transactions. Whatever model the business is supported on.
Summing up, you can construct your customer path by inverting the traditional marketing funnel. Start by the channels that offer an higher buying-intent customer, optimise, streamline, move up in the marketing funnel by selecting the next appropriate channel. Reinvest your earnings to climb up the ladder and reach a larger audience. The slippery funnel will be hard to climb, but the challenge is the exciting piece.
This is my first Medium article, feel free to add your thoughts by commenting below. | https://medium.com/business-startup-development-and-more/how-startups-are-inverting-the-marketing-funnel-23b4067da960 | ['Ricardo Batista'] | 2017-01-19 10:51:07.625000+00:00 | ['Growth', 'Marketing', 'Startup', 'Digital', 'Digital Marketing'] |
Why I’m not celebrating my birthday | And how a mindset shift can make every day feel like your birthday
Oh, my birthday.
In the past, I’d have been dropping hints and anticipating the big day for weeks. I would have been dreaming of it, thinking about it, and wishing for its arrival. I’ve always LOVED my birthday.
But one year (in 2015, to be exact), I realized I hadn’t been very excited.
It knew it wasn’t because I was bummed or having a bad birthday. And as I contemplated why, I realized that in the past, my birthday was just about the only time I gave myself permission to ask for and do what I wanted to do.
But in 2015, in the months leading up to my birthday, everything had changed.
A monumental, life-changing tragedy precipitated this change: the unexpected, unexplained, full-term stillbirth of my first child, Maeve Evalyn.
After she died, I questioned everything in my life and made the changes I’m sharing here, but it doesn’t have to take a tragedy for YOU to do the same.
As a result of losing her, and deciding to fully live for myself and for her, I’d stopped saying “someday” or “one day,” and instead I WENT FOR what I wanted.
I decided I was no longer waiting for one day a year to give myself permission to do, get, and most importantly, BE, what I wanted. Since then, and to this day, I focus on these things EVERY day.
I no longer spend every other day outside of my birthday feeling obligated to everyone and everything else in my life.
And, while I was originally scared to be anything but a people-pleaser because I feared conflict above almost anything, ironically, that’s actually IMPROVED my relationships because I’m the authentic, genuine version of me, and that person is much happier and easier to love than the one who lived trying to be what I thought other people wanted or needed from me.
In the months leading up to my birthday that fateful year when everything changed, I:
Traveled to Europe for 2 weeks
Moved into my dream house
Tripled my monthly income
Got over my lifelong fear of what others think
Kicked the competitive habit and began surrounding myself with encouraging people
Shared my story and started inspiring others
Supported amazing high-achievers around the world in creating their dream lives
I’m celebrating that change today and every day.
I guess you could say I’ve started living every day like it’s my birthday!
What about you?
Don’t wait for your birthday; here’s how you can get closer to your dreams TODAY:
1. Be honest with yourself.
What are the things you are pretending you don’t want in the name of “practicality?” Write them down.
2. Do something to make yourself smile today.
Snap out of your daily rut. Exercise, meditate, go to your favorite coffee/tea shop and “treat yo’ self,” pick up a new book and get lost in it — even if you only have 5 minutes.
3. Just START.
So often in my coaching and consulting, I see the theme of OVERTHOUGHT and UNDER ACTION in women who are struggling to make a change.
The insightful book The Confidence Code: The Science and Art of Self-Assurance — What Women Should Know, reported that men will apply for a job when they feel 60% qualified, but women won’t apply unless they feel 100% qualified. Is this true for you, whether or not it relates to you going for a new job, starting or growing a business, or taking another risk you’ve been dreaming of? How does this relate to your life?
Most importantly, action brings clarity (and relieves anxiety!), so where can you take action today?
4. Get support.
Before 2015, I always told myself I could do it on my own because I prided myself on being independent and I honestly found many women to be catty or competitive. So I wasted years and years struggling in my business.
Connecting with the right coach and a like-minded, supportive group of women were the two keys that helped me believe I COULD change, showed me what was possible, and catapulted me to the next level in visibility, income and living authentically, with passion, that I’d so long been dreaming of reaching.
This change came for me years ago. It wasn’t just a temporary fad that eventually faded into the background of “real life” as the rawness of my grief subsided.
I’ve had three more birthdays since then. And this is still how I’m embracing my life every day.
This can be your reality, too. Will you embrace it? Let me know in the comments below!
Next Steps
Ready for more tips on how to get out of your own way and get visible with your business so that you can replace your income and quit or stay out of your 9–5?
Learn the 7 simple steps to doing what you love & making 6 figures from anywhere in the first chapter of my #1 bestselling book, The Income Replacement Formula, for FREE by clicking here. | https://medium.com/thrive-global/why-im-not-celebrating-my-birthday-b6bdf661c133 | ['Christine Mcalister'] | 2019-01-22 22:18:39.627000+00:00 | ['Self Improvement', 'Mindset', 'Productivity', 'Entrepreneurship', 'Work Smarter'] |
How Negativity Can Always Stop Your Progress | Failure To Recognize Adverse Situations Will Halt Advancement…
Image Courtesy of Unsplash
A positive mindset is a great thing to have daily to uplift yourself and others. No one benefits from negativity or how it can subdue your progress in any situation.
Looking deep into our lives, one must who is surrounding me that can bring more of a positive spin as opposed to negativity in one’s life? To be quite frank, negativity can be a mainstay in any life if you let it consume you and stop your progress to reaching more of your goals and achievements than you think.
Lacking the proper mindset to move forward towards a desired result is something that takes effort. Surrounding yourself by awesome people that are like-minded can be a great thing to you and your mindset.
When someone is being negative, oftentimes they’re doing it because of some reason that has nothing to do with you. Those are usually the people that you really don’t want to be around or have a meaningful relationship with.
I will show how negativity can be a burden and get in the way of moving forward in life and your daily routine.
Self Limited Beliefs
Life provides us with many emotions and no matter how confident that you might be, self-limiting beliefs can be a negative thing. Everyone has doubts when throughout life especially when trying to get something accomplished.
Image Courtesy of Unsplash
Getting down on yourself no matter what the situation is can be a natural occurrence with anyone no matter who they are or what their persona might be.
If you’re trying to accomplish a goal and you reach a roadblock doubting yourself, self-limiting beliefs could be the reason. We all have that little angel on one shoulder and the proverbial devil on the other shoulder giving us conflicting information about our next move.
A positive mindset to the contrary can feed us great things and give encouragement to keep us going. The devil on the shoulder that’s putting in way more work than the angel on the other shoulder.
The devil on one shoulder is telling you that it can’t be accomplished but at some point, you have to stop listening to it because of the negative energy that it creates.
Fear of Learning or Furthering Education
We all know the one person that doesn’t like to learn for one reason or another. The person that’s stuck in their ways and just can’t seem to get their feet out the quicksand to learn something new.
It could be a common element that may or may not be true with you personally but you probably can relate because we all know someone like that. Sometimes learning something new can be a great thing and it can advance you in a lot of different ways whether it’s a relationship, new skill for a job or just something that could get you what you want in life.
I had to do things to further my education too and I’m not just talking about school or college or anything like. I learned how to code, write tables and queries in a database better, build websites, etc.
Image Courtesy of Unsplash
I learned as much as possible because I knew the path that I wanted to take to be successful so I have to embrace learning new skills.
Getting better daily using free tools such as YouTube, Google and iTunes and Stitcher for listening to audio podcasts can help you further your education for Free!
The fear of furthering education or just learning any tactical thing can be a negative burden towards moving forward as well.
Making Constant Excuses
At some point, we’ve all made excuses in one form or another. It may help to come to grips and get it out of your system as soon as possible. Making continual excuses can add an abundance of negativity in your life.
You can definitely stunt the growth of just about anything because making excuses is the easiest thing to do.
Excuses are very easy to make and don’t require a lot of time but do sometimes require energy which is mainly wasted and unwanted. Think about how great things are when you don’t make steady explanations?
Image Courtesy of Unsplash
Some people are so caught up into making excuses that it’s the fabric of their existence. They don’t even realize the extent of what they’re doing and usually those same people really don’t care.
Are you one of those people who make constant excuses that drain off negative energy? It’s not too late to make a change in the right direction.
Stuck In Their Ways
We are all stuck in our ways on something but the difference is some of us have the ability to recognize our faults. Generally, we can get out of situations but at the same time some of us just can’t because of stubbornness.
I’ll give an example of being stuck in your ways: eating too many harmful foods. There has been so much research done on for health and wellness. And we know that one of the huge things that cause diseases is the food we consume.
Image Courtesy of Unsplash
In a lot of ways, it’s more harmful to eat a cheeseburger that it is to smoke cigarettes but it doesn’t stop us because we want that satisfaction of the food because it tastes so good.
If this is something that’s in your daily or weekly diet and you just cannot remove it, then you might be stuck in your ways. Do you cherish your life or will you keep eating burgers every other day from one fast food restaurant to the next?
Always Complaining
Everyone complains about something whether it is intentional or apart of our fabric. There’s no way you can go through life without being dissatisfied with something whether it’s a product, your local salon or even customer service at your favorite restaurant.
We can likely agree that everyone has a complaint somewhere along the line. But it’s the person that’s ALWAYS complaining that is extremely irritating.
Image Courtesy of Unsplash
The reality is that the “Complainer” sees it as an escape from other internal issues where he or she lacks and can’t recognize that the problem is them. The one thing that we find very hard to do in life is to look in the mirror embrace blame or better yet accountability.
I truly believe that some people rather not face their inner fears and admit to being wrong about something. There’s a difference between a legitimate complaint and a constant one that shows negativity that keeps you from moving forward.
Using Failure As The Reason To Quit
Most people never reach their full potential, accomplish goals, and definitely halt their progress because they use failure as a reason to quit. If you look at failure as an opportunity to get back up to continue, then your chances of reaching a goal is a lot better.
Image Courtesy of Unsplash
Quitting is so easy to do, it requires zero effort and it’s very convenient. So many people fail because it can be a difficult task to believe in ourselves enough to think that we can actually accomplish something of value.
Stop using failure as the reason to quit and keep moving in the direction of gratitude and positivity. You are much closer to a goal when you fall because of negativity and get back up than you were before.
Are There Any Other Negative Ways To Stop You From Progressing? Leave A Comment, A Clap and/or A shout out on Twitter!
If you liked this article, please check out the rest of my articles on Medium, Thrive Global, Good Men Project and for tips on Blogging. | https://medium.com/thrive-global/how-negativity-can-always-stop-your-progress-ee8a594bd337 | ['Andre L. Vaughn'] | 2019-03-01 01:44:28.093000+00:00 | ['Life Lessons', 'Productivity', 'Success', 'Entrepreneurship', 'Life'] |
Strategies for Learning New Skills Faster | Strategies for Learning New Skills Faster
Like programming
Learning any new skill has become easier than ever due to the internet. We are just a few clicks away from any information.
Do you know that most people take an average of 25–30 days to complete a 30-hour course on Coursera/Udemy. Online MOOCs have a completion rate of less than 15%, which means that out of 1,000 people registered in a course, 850 of them never complete the course, and drop out.
But why do people drop out in the middle of a course? What could be the reason? Is the course not good, or don’t we have enough motivation to continue?
I conducted a survey of around 200 people, and here is what they say.
Survey Response — 1
Survey Response — 2
Some key insights:
More than 55% of people said they take more than one month of time.
More than 70% of people have a course-completion rate of approximately 50% or less.
Now, let’s see what the approaches are to learn any new skill faster. | https://medium.com/better-programming/how-to-learn-anything-faster-40b54235f0d6 | ['Deepak Kumar'] | 2020-12-05 07:12:42.348000+00:00 | ['Startup', 'Learning To Code', 'Learning', 'Entrepreneurship', 'Programming'] |
A Conversational Design Primer | A Conversational Design Primer
Looking to get started in voice or chatbot design? Learn the basic terminology and concepts to empower better design decisions.
As we used to say at Amazon, the tech industry has passed through the threshold of a “one way door” with regard to conversational experiences. Our industry will never look back at the world of purely point-and-click websites as the end-all and be-all of customer experiences.
My own path in the space of both voice UI and conversational design has been a long and winding road: from video games to CRM cloud services; from Cortana to Alexa. In 2017, I started a new chapter in that career, sharing the knowledge I’d gained along the way with others via workshops (Giving Voice to your Voice Designs) and talks (Blank Page to World Stage, The Future of Voice).
Now that I’m focused on my work as Principal Designer and owner of Ideaplatz, I’d like to share with you the introductory primer to the key concepts in the conversational design space: the primer I wish I’d had when starting out on this modern wave of conversationally focused experiences.
As it was passed on to me, I want to pass on to you the basic concepts you’ll need to start thinking about design for conversational user interfaces. Image licensed via Adobe Stock.
Not sure whether voice or conversation is right for you? You may want to start with one of my introductory Medium posts: Voice User Interface Design: New Solutions to Old Problems.
Let’s talk about the past
Up until the advent of dedicated voice experiences on the iPhone, conversational interfaces fell into one of two categories:
Dictation-based
Products like Dragon Naturally Speaking, which required considerable training and were about transcription, not transactions. (This line has blurred in the ensuing decades.) These systems can transform the spoken word into digital text, but were not optimized for taking action on the spoken word. They also required quite a bit of user-specific training to get their accuracy to acceptable levels.
Grammar-based
Best for command-and-control scenarios, grammar-based systems know a fixed dictionary of terms and will match speech to the closest option within that dictionary. Many early voice-enabled toys and video games like Hey You, Pikachu and Disney Friends (disclaimer: I was the Lead Producer on Disney Friends) were grammar-based.
The key shortcoming of grammar-based systems is that they are inherently unforgiving. If a customer changes the order of the words in their request in an unexpected way, or otherwise contravenes expectations, the system can’t adapt and will often take the wrong action as a result.
In many ways, these shortcomings can be mapped to our own learning frameworks as children. When we are young, we only know a few words. Words that sound like words we know may be miscategorized because we don’t know how to adapt yet.
Connectivity changes everything
Once cloud services became a reality, everything changed. You see, to go beyond the dictionary approach, we needed to teach systems how to extract meaning from words. Not just to match sounds to letters, but to apply the semantic rules within a chosen language to understand the difference between similar words, and to understand that different phrasings sometimes mean the same thing.
Consider this pair of examples:
“Computer, turn on the lights in the play room.”
“Computer, play ‘Turn it On Again’.”
A system that was just looking for words that sound similar might get confused here. “Turn”, “on”, and “play” are all key words present in both phrases. Think about how we as humans distinguish between the two. It’s actually pretty complicated, isn’t it? Part of it is ordering, part of it is additional context (like the word “room” — which might not be present if I asked for lights in the basement), and part of it is those tricky linguistic connective tissues like “in” and “the”.
This is the difference between early voice recognition systems and a natural language recognition system — the ability to go beyond sound and understand the underlying meaning in a customer’s request. It’s a complicated problem, which is why we needed artificial intelligence to solve it.
The language behind natural language
If you’re coming from a world of more traditional, visually-oriented design (and almost all of us do) — working on conversational designs will mean familiarizing yourself with the terms of the trade. You may encounter a new type of collaborator in linguists or speech scientists, who are the individuals tasked with teaching your artificial intelligence solution about the semantic meanings specific to your product, service, or feature.
Utterance
The utterance is the “ground truth” about a customer’s request; it is the specific way in which a request is posed to the system. For chatbots, this is typically a text string; for voice-based systems, it may be helpful to think of this as the actual recording of the request. This utterance may include typos, grammatical errors, ambient noise, or interruptions — whatever actually happened at the time of the request.
Intent
Conversational designers use the term “intent” to signify the customer’s goal when making a request. Many utterances may correspond to a single intent. For example, a thermostat may have an intent model to represent a customer’s desire to make it incrementally warmer in the room. The following utterances could all be mapped to Thermostat/Warmer:
Make it warmer in here.
I’m cold!
It’s cold in here.
Turn up the heat.
Interaction designers and researchers are often responsible for examining potential customer intents and providing recommendations to speech scientists. During this process, the design team would also provide sample utterances like these for each intent to get things started.
Slot
A slot is essentially a conversational variable, for those of you with a programming background. For the rest of us, slots are parts of an utterance that we expect to vary from request to request. A common example is weather. Consider the following request:
Computer, what’s the weather going to be in Orlando on January 9?
In this example, most of the utterance is unlikely to vary much, though you might see discrepancies in ordering. But the bolded text indicates slots: places where we expect the content to vary almost every time.
Intents often depend upon the content of a slot to complete the request. For a “Weather on specific day” intent, we would expect at minimum a date; and optionally a location we’re curious about.
Entity
This is where our industry terminology starts to feel a bit needlessly obtuse. Entities are a concept that almost everyone seems to understand, but no one can describe; maddening for those coming in from the outside.
IBM’s developer documentation defines entities as “usually a classification of objects aimed to help alert the response to an intent.” Which is… not particularly helpful.
Essentially, entities are a model of the concepts important to your product, and how those concepts relate to one another. You might start modeling your entities by drawing out a conceptual map of the terms your customers must deal with, and filling in the relationships and values.
In most systems, you can define your own entity types. For example, when I was prototyping a Microsoft Azure onboarding chatbot during my latest stint at Microsoft, one entity I defined was an “operating system”, and that entity could have values of “Windows,” “Linux”, or “Mac OS”.
But in many cases, the values in our slots correspond to very well-understood entities, like time or city name. In other cases, the value maps to a massive catalog of slot values, like musical artists. In those cases, designers don’t usually model the entities themselves.
Slot Types (aka System Entities)
This concept goes by several names in the industry, but in short a slot type is a hint to our natural language system to apply additional logic to the bit of utterance in that slot. For example, Alexa allows you to define a slot type of “Date”. Any utterance processed as AMAZON.Date is processed based on Amazon’s extensive experience. Slot types are often very forgiving: for the case of Date, it can handle a range of utterances like “January 9”, “January 9 2019”, “The 9th of January”, “January”, etc.
Every system comes with its own system entities or slot types, so your mileage may vary; there is no universal set of concepts. Dates, times, cities, colors, and numbers are some of the most common slot types. For further examples, start with this Amazon Slot Type reference or Dialogflow System Entities.
Prompt
The text of a response to be delivered back to a customer conversationally on behalf of the system. “Prompt” sounds like it’s asking for something, but that’s not necessarily the case. Some systems use terms like “response” instead to avoid this issue. But note that we said text of a response. What if your response should be spoken?
Text to Speech
If you’re building a voice-enabled system, it’s a generally accepted best practice to ‘respond in kind’. That is, speak when you’re spoken to. But most prompts start out as text. 5 years ago, most spoken prompts required a recording session with a voice-over artist, resulting in MP3s that could be played back. That doesn’t scale to a huge problem space, like including all possible musicians and song titles.
Alexa, Google Home and Cortana have all moved to using a text to speech system, or TTS. These used to sound very robotic, but proprietary advances in technology have allowed these systems to generate arbitrary audio prompts very convincingly in real time — as long as there’s a functional Internet connection to transmit the resulting audio file.
Conversation or not?
You’ll notice that I often specify “voice AND conversational” design, or differentiate between the two. This is because the two aren’t quite equivalent, at least as the industry sees them.
Conversational design can apply to BOTH text-based chatbots AND voice user interfaces.
can apply to BOTH text-based chatbots AND voice user interfaces. Voice user interface design refers ONLY to experiences where the input (and usually output) is audio-based, or spoken.
An experience designed for voice can usually translate back to a traditional chat medium, but an experience built for chat is NOT necessarily going to succeed over voice. This is because these two modalities engage different parts of the human brain: visual memory and processing are fundamentally different from auditory memory and processing. A good foundation in cognitive psychology will go a long way for designers asked to straddle this divide.
This distinction is a large part of what I cover in my workshop, “Giving Voice to your Voice Designs”. It’s also why the Twitter hashtag #VoiceFirst has gained such traction. The movement isn’t about ONLY interacting via voice, so much as it is starting from the most difficult and restrictive interaction model, and moving out from there.
The systems behind conversational understanding
As someone who’s worked for years in spaces considered by the outside world as “artificial intelligence”, I’m often asked about the robot revolution. When will SkyNet take over? I usually reply with the observation that I feel the singularity is overhyped at best. Most systems we perceive as a singular, unified intelligence (like Alexa and Cortana) are actually a series of disparate services on the Internet communicating in real time. If any link in this chain fails, our ability to understand and respond is limited, or completely removed.
So what are these disparate systems? Let’s dive in.
Automatic Speech Recognition (ASR)
For voice controlled systems, automatic speech recognition is the first and most rudimentary step in the process — not so much artificial intelligence as a processing step.
ASR systems take the spoken utterance from the customer (ie, the waveform itself) and chop it up into individual segments called phonemes. A phoneme is defined by Merriam-Webster as “any of the abstract units of the phonetic system of a language that correspond to a set of similar speech sounds.”
ASR systems don’t understand sentence structure, but they do understand some basic fundamentals about their assigned language: for example, K and Z are unlikely to appear adjacent to each other in English text, so we can rule those guesses out.
The output of the ASR step is a first guess at the customer’s utterance. Since we don’t have the full context, this guess might change. But it’s enough to move on to the natural language understanding system.
Natural Language Understanding (NLU)
Natural language understanding systems are the real artificial intelligence behind your favorite conversational systems. NLU engines take text as input — either directly from chat, or the output from an ASR system if speech is involved.
From that starting point, a natural language understanding system attempts to map the utterance to an intent. Think of the NLU system as working to answer these three questions:
What does the customer want to accomplish? (Intent) What’s unique about this request? (Slots) Is there anything in this request I need help understanding? (Entity Recognition)
For voice recognition systems, sometimes the NLU system decides the ASR output doesn’t make sense… but it might be close. In these situations, NLU might send an utterance back to ASR with additional context to check a hypothesis. If you’ve ever used Siri and noticed that she erased her transcription of what you said and replaced it with something more accurate — this is what happened.
Entity Recognition (ER)
If our utterance contains a non-standard slot type, our utterance might be processed by a separate entity recognition engine. For finite sets, the entity recognition might be trivial, but usually still technically separate.
In cases where our slot is expected to contain a reference to a giant catalog of possibilities, that piece of the utterance is often sent over to an entity recognition system. In some cases, these are run by different companies entirely. For example, Nuance Communications is a company that has helped many speech systems by providing an entity recognition service for musical requests. This is harder than it sounds, when you consider that the catalog of available music is literally getting larger day by day, and will continue to do so until the end of civilization. And don’t get speech scientists started on artist names like Ke$ha. Entity recognition engines often account for these sorts of challenges.
Business logic
This isn’t a formal system, per se, but I wanted to make the point that your system’s response to an intent is completely separate from the processing and identification of that intent.
Most conversational services out there focus on intent processing, but the business logic to respond to an intent comes down to traditional programming, though often a serverless solution like Lambda or Azure Functions.
For example, my Trainer Tips skill has two main components: the input processing, via Alexa’s Skill Kit; and the business logic, hosted on AWS Lambda, which generates the prompts for each intent and sends them to Alexa’s text-to-speech engine.
Next steps on Medium
With regard to conversational UI, I’m workshopping a few future pieces on the dangers of AI-powered experiences, conversational error patterns, and beyond.
A great way to get started with conversational interfaces is to build your own chat app for fun, and see what you learn. I’m hoping to put together a chatbot tutorial for designer/developers, likely using LUIS.ai and Azure Bot Service. For those less experienced on the development side, Alexa skills have spawned a cottage industry of helper apps, tutorials, and templates to get you on your way.
If you’re not yet ready to dive in headfirst but want more context, I have a written a wide variety of Medium articles exploring voice and conversational design, as well as some posts about more general product design topics. Peruse them all at my profile page, and follow me to get updates when new articles are available.
Best of luck with wherever the conversation takes you. May the voice be with you. | https://medium.com/ideaplatz/a-conversational-design-primer-9914778559d5 | ['Cheryl Platz'] | 2019-04-20 19:33:00.441000+00:00 | ['Speech Recognition', 'Artificial Intelligence', 'Design', 'Alexa', 'Conversational UI'] |
Pandas on Steroids: Dask- End to End Data Science with python code | Pandas on Steroids: Dask- End to End Data Science with python code
End to End Parallelized Data Science from Reading Big Data to Data Manipulation to Visualisation to Machine Learning
Dask- Familiar pandas with superpowers
As the saying goes, a data scientist spends 90% of their time in cleaning data and 10% in complaining about the data. Their complaints may range from data size, faulty data distributions, Null values, data randomness, systematic errors in data capture, differences between train and test sets and the list just goes on and on.
One common bottleneck theme is the enormity of data size where either the data doesn’t fit into memory or the processing time is so large(In order of multi-mins) that the inherent pattern analysis goes for a toss. Data scientists by nature are curious human beings who want to identify and interpret patterns normally hidden from cursory Drag-N-Drop glance. They need to wear multiple hats and make the data confess via repeated tortures(read iterations 😂 )
They wear multiple hats during exploratory data analysis and from a minimal dataset with 6 columns on New York Taxi Fare dataset( https://www.kaggle.com/c/new-york-city-taxi-fare-prediction) - ID, Fare, Time of Trip, Passengers and Location, their questions may range from:
1. How the fares have changed Year-Over-Year? 2. Has the number of trips increased across the years? 3. Do people prefer traveling alone or they have company? 4. Has the small distance rides increased as people have become lazier? 5. What time of the day and day of week do people want to travel? 6. Is there emergence of new hotspots in the city recently except the regular Air Port pickup and drop? 7. Are people taking more inter-city trips? 8. Has the traffic increased leading to more fares/time taken for the same distances? 9. Are there cluster of pick-up and Drop points or areas which see high traffic? 10. Are there outliers in data i.e 0 distance and fare of $100+ and so on? 11. Do the demand change during Holiday season and airport trips increase? 12. Is there any correlation of weather i.e rain or snow with the taxi demand?
Even after answering these questions, multiple sub-threads can emerge i.e can we predict how the Covid affected New year is going to be, How the annual NY marathon shifts taxi demand, If a particular route if more prone to have multiple passengers(Party hub) vs Single Passengers( Airport to Suburbs).
To quench these curiosities, time is of the essence and its criminal to keep the data scientists waiting for 5+ minutes to read a csv file(55 Mn rows) or do a column add followed by aggregation. Also, since the majority of Data Scientists are self-taught and they have been so much used to pandas data frame API that they wouldn’t want to start the learning process all over again with a different API like numba, Spark or datatable. I have tried juggling between DPLYR(R), Pandas(Python) and pyspark(Spark) and it is a bit unfulfilling/unproductive considering the need for a uniform pipeline and code syntax. However, for the curious folks, I have written a pyspark starter guide here: https://medium.com/@ravishankar_22148/billions-of-rows-milliseconds-of-time-pyspark-starter-guide-c1f984023bf2
In subsequent sections, I am trying to provide a hands on guide to Dask with minimal architectural change from our beloved Pandas:
Data Read and Profiling
Dask vs Pandas speed
How is Dask able to process data ~90X faster i.e Sub 1 secs to 91 secs in pandas.
What makes Dask so popular is the fact that it makes analytics scalable in Python and not necessarily need switching back and forth between SQL, Scala and Python.The magical feature is that this tool requires minimum code changes. It breaks down computation into pandas data frames and thus operates in parallel to enable fast calculations.
2. Data Aggregation:
With absolutely 0 change from Pandas API, it is able to perform aggregation and sorting in milliseconds, Please note .compute() function at the end of lazy computation which brings the results of big data to memory in Pandas Data Frame.
3. Machine Learning:
Code snippet below provides a working example of feature engineering and ML model building in Dask using XGBoost
Feature Engineering and ML Model with Dask
Conclusion:
Dask is a powerful tool offering parallel computing, big data handling and creating end to end Data Science pipeline. It has a steep learning curve as the API is almost similar to pandas and it can handle Out Of Memory computations(~10X of RAM) like a breeze.
Since it is a living blog, I will be writing subsequent parts in Dask series where we will be targeting Kaggle leaderboard using parallel processing. Let me know in comments if you are facing any issues in setting up Dask or unable to perform any Dask Operations or even for a general chit-chat. Happy Learning!!!
Sources: | https://medium.com/analytics-vidhya/pandas-on-steroids-dask-end-to-end-data-science-with-python-code-1845d3722c8a | ['Ravi Shankar'] | 2020-10-21 12:27:47.251000+00:00 | ['Machine Learning', 'Python', 'Dask', 'Parallel Processing', 'Big Data'] |
The CRISPR Nobel Prize & Data Stored in DNA Gets Destroyed | NEWSLETTER
The CRISPR Nobel Prize & Data Stored in DNA Gets Destroyed
This Week in Synthetic Biology (Issue #11)
Receive this newsletter every Friday morning! Sign up here: https://synbio.substack.com/
Data, Stored in DNA, Gets Destroyed (But In A Good Way)
DNA is promising for data storage, mainly because a single gram of DNA can store 256 petabytes of information. But there’s a problem: DNA is, in some cases, too stable. To remove a user’s data from DNA on “nucleic acid hard drives” of the future, scientists first need to develop better ways to selectively target, and destroy, DNA.
A new method, published in Nature Communications, could be a contender for wiping DNA hard drives in the year 2087 (assuming the human race survives that long). DNA sequences, each containing a “True” barcode and one, or several, “False” barcodes, are first mixed together. Then, “truth markers” — DNA sequences that selectively bind to the “True” sequences — are added to the mixture. If the mixture is then heated to 95 degrees Celsius, the “truth markers” fall off and information from the “True” bits is lost. It’s a simple technique, with promising results.
The researchers showed that “8 separate bitmap images can be stably encoded and read after storage at 25 °C for 65 days with an average of over 99% correct information recall, which extrapolates to a half-life of over 15 years at 25 °C. Heating to 95 °C for 5 minutes, however, permanently erases the message.”
An enzymatic pathway has been assembled on top of a Tobacco mosaic virus. Using peptide “linkers”, the scientists, based in Hong Kong, tethered “three terpene biosynthetic enzymes” to the outer particles of the virus, and grew them inside of E. coli cells. The goal was to explore how the proximity of enzymes impacts the bioproduction of a molecule (in this case, amorpha-4,11-diene).
Since the Tobacco mosaic virus is 300nm long, metabolic engineers could presumably use it as a foundation to assemble any number of complex enzymatic pathways. This study was published in Bioconjugate Chemistry.
Deep Learning to Design RNA “Switches”
Two studies, published in Nature Communications, used deep learning to guide the engineering of RNA “toehold switches”. These RNA switches are, basically, synthetic RNA sequences that can be turned ON and OFF. In their OFF state, the toehold switches form a hairpin loop and cannot be read by the ribosomes — they do not produce a protein. The addition of an RNA “trigger”, however, can be used to turn a toehold switch ON; translation can proceed.
Toehold switches are especially useful because a lot of them can be present in a cell at the same time, and triggers can be designed for each of them. This means that many genes can be precisely controlled for synthetic biology applications. Unfortunately, toehold switches are really difficult to design, and even a slight tweak to a sequence can impact their utility.
In the first study, led by Nicolaas M. Angenent-Mari, over 90,000 toehold switches were synthesized and tested using clever experiments that enabled the activity of each toehold switch to be individually assessed. After testing each of the RNAs, data was fed into a deep learning model (which I won’t even pretend to understand). The output from that model looks promising: “[Deep Neural Networks] trained on nucleotide sequences outperform (R2 = 0.43–0.70) previous state-of-the-art thermodynamic and kinetic models (R2 = 0.04–0.15).”
In the second study, led by Jacqueline Valeri, two “deep learning architectures” were introduced — called STORM and NuSpeak — to improve the performance of RNA toehold switches. Both studies are open access, and represent a paradigm shift in how quickly synthetic biologists will be able to design and engineer biological molecules that behave as expected.
The vast majority of plants on earth are C3 plants; when it’s hot or dry, C3 plants close their stomas, oxygen builds up, and the efficiency of photosynthesis goes down. C4 plants, on the other hand, have figured out a way to avoid that pesky oxygen buildup. In C4 plants, fixation of entering carbon dioxide occurs in mesophyll cells, while the Calvin cycle instead occurs inside of bundle-sheath cells. This separation means that C4 cells can avoid oxygen buildup, and typically have a higher photosynthesis efficiency.
A new study in Plant Biotechnology Journal has introduced five genes into a specific strain of rice, boosting its photosynthetic flux by…well, only about 2%. But these early results look promising. If scientists can get the balance of gene expression right, it may one day prove useful for boosting rice yields, a staple food for more than half of the planet’s population.
Biological circuits, operating inside of cells, can be built from dozens of individual genetic parts. Even a tiny tweak to one of those parts — a promoter, ribosome binding site, or terminator — can impact the performance of the genetic circuit. A new study exhaustively characterized all 54 parts in a circuit, parametrized them, and then used the data to build a mathematical model that could “predict circuit performance, dynamics, and robustness.” They even used the computed parameters to calculate “the cellular power (RNAP and ribosome usage) required to maintain a circuit state.” This study, published in Nature Communications, is open access. | https://medium.com/bioeconomy-xyz/the-crispr-nobel-prize-data-stored-in-dna-gets-destroyed-df00c34c9111 | ['Niko Mccarty'] | 2020-10-09 09:06:46.420000+00:00 | ['Tech', 'Startup', 'Nobel Prize', 'Newsletter', 'Science'] |
The Origin of Machine Learning | Zoologists and psychologists study learning in animals and humans. There are several parallels between animal and machine learning.
Certainly, many techniques in machine learning derived from the efforts of psychologists to make more precise their theories of animal and human learning through computational models.
It seems likely also that the concepts and techniques being explored by researchers in machine learning may illuminate certain aspects of biological learning.
As regards machines, we might say, very broadly, that a machine learns whenever it changes its structure, program, or data in such a manner that its expected future performance improves.
Some of these changes, such as the addition of a record to a database, fall comfortably within the province of other disciplines and are not necessarily better understood for being called learning.
Machine learning usually refers to the changes in systems that perform tasks associated with artificial intelligence. Such tasks involve recognition, diagnosis, planning, robot control, prediction, etc.
Why should machines have to learn? Why not design machines to perform as desired in the first place?
There are several reasons why machine learning is important. Of course, as I have already mentioned that the achievement of learning in machines might help us understand how animals and humans learn.
But there are important engineering reasons as well. Some of these are:
Some tasks cannot be defined well except by example; that is, we might be able to specify input/output pairs but not a concise relationship between inputs and desired outputs.
We would like machines to be able to adjust their internal structure to produce correct outputs for a large number of sample inputs and thus suitably constrain their input/output function to approximate the relationship implicit in the examples.
It is possible that hidden among large piles of data are important relationships and correlations. Machine learning methods can often be used to extract these relationships (data mining).
Human designers often produce machines that do not work as well as desired in the environments in which they are used. In fact, certain characteristics of the working environment might not be completely known at design time. Machine learning methods can be used for the on-the-job improvement of existing machine designs.
The amount of knowledge available about certain tasks might be too large for explicit encoding by humans. Machines that learn this knowledge gradually might be able to capture more of it than humans would want to write down.
Environments change over time. Machines that can adapt to a changing environment would reduce the need for constant redesign.
New knowledge about tasks is constantly being discovered by humans. Vocabulary changes. There is a constant stream of new events in the world. Continuing redesign of AI systems to conform to new knowledge is impractical, but machine learning methods might be able to track much of it.
I hope you liked this article on the origin of Machine Learning. Feel free to ask your valuable questions in the comments section below. You can also connect with me from here, to learn every topic of Machine Learning. | https://medium.com/the-innovation/the-origin-of-machine-learning-c2a0893ee0c4 | ['Aman Kharwal'] | 2020-09-02 18:05:18.341000+00:00 | ['Programming', 'Artificial Intelligence', 'Python', 'Data Science', 'Machine Learning'] |
You’ve Settled in as an Engineer. Now What? | You’ve Settled in as an Engineer. Now What?
How to avoid the plateau and continue to grow
Photo by True Agency on Unsplash
Congrats! You’ve settled in at your first job. You’ve made it past the initial wave of impostor syndrome and have some idea of what you’re doing and what you’re good at. You might’ve even received a promotion or two. You’re no longer wildly floundering every day and are able to at least flounder in the right direction. You might even be on your second or third job at this point. You actually feel like a real engineer now.
Now what?
It’s common to feel a sensation of plateauing after an initial few years of hypergrowth. This is only natural: Growth comes from new information, and the supply of novelty provided by a job quickly dries up as the years pass by. Up to this point, simply engaging with your job was enough to provide steady improvement; now, you must actively seek new information to keep growing.
Before proceeding, I want to clarify one thing: being happy with where you are is perfectly fine. You might feel entirely comfortable with plateauing, and that doesn’t make you any less of a person. If you’re content and have job security, congrats — you’ve won. It’s not worth it to burn yourself out trying to level up if you’re not motivated to do so. | https://medium.com/better-programming/youve-settled-in-as-an-engineer-now-what-b7f12c277131 | ['Tim Hwang'] | 2020-12-27 23:59:34.334000+00:00 | ['Personal Development', 'Startup', 'Software Engineering', 'Learning To Code', 'Programming'] |
I Wish Marketing Was Easy | .. but it’s not.
Last week I was talking to a brilliant app developer. He launched his app few months ago and now he wants to “market it”.
BTW this is very typical in the startup community. We build our apps / products and then start thinking about getting users.
This is what I told him.
If developing an app is hard, marketing it is 10x harder (ali)
Why?
There are 100s of apps that are launched daily. It’s hard to get people’s attention for your product.
I read product hunt daily and I can’t even name 3 apps / products I saw there this morning. I saw a lot of cool stuff but, I can’t name any right now.
I wish I was wrong but marketing is not easy.
If you think of marketing as an after-thought, you will FAIL.
Marketing != Selling
Marketing = Educating
Start educating your potential users as soon as possible.
You can use content marketing as a medium. I know its a big word, but content marketing is not hard. It’s actually very simple. Here are some simple steps.
1 — Create a website (or landing page) for your app
2 — Install an email capture form on the home page
3 — Install Google Analytics
4 — Add a blog to your website
5 — Do some research and come up with 10 articles you can write. If this seems scary, just look at your competitor’s blog. What type of content they are producing. Steal some ideas from there.
6 — You can also use a tool like Buzzsumo to get some viral content ideas.
7 — Write and publish one article every week.
8 — If you suck at writing, it’s OK. That makes 2 of us. You can find ghost writers on Fiverr.com or Upwork.com
9 — You should also submit your startup to directories like Product Hunt, Beta list, and Startup list.
10 — Setup Google Alerts on your niche keywords and reach out to people who are writing about your industry or competitors. This is what I did to get my app featured in some news outlets.
Here is the step by step process > Free press for an app
Yes, marketing is HARD, but you can do it.
Again, just think of marketing = educating.
Your job is not to just to create beautiful apps. You have to tell your target audience about it. You kinda owe it to them.
Start educating people about your idea the day you write your first if statement. (ali)
Now over to you. Are you working on a startup?
How are you educating your target audience about your product? | https://medium.com/social-media-growth-hacking-hub/i-wish-marketing-was-easy-5328b342a1ae | ['Ali Mirza'] | 2016-05-03 07:09:21.363000+00:00 | ['Startup', 'Marketing', 'Growth'] |
Neurons in Spreadsheets | Neurons in Spreadsheets
Your own neural network on the cheap
In the previous post, we saw what a neural network is and how it works. Now comes the fun part. We’ll make one in a spreadsheet.
It doesn’t matter which spreadsheet you use. You can visualise such neurons in Excel, or you can equally well use LibreOffice, Google Sheets or any other spreadsheet application.
Image by the author
In the top line, the two yellow cells are the input values. You can change these to simulate various inputs. The next line contains the two synaptic weights by which we will multiply the input values. Here we put them to 0.6 to simulate a logical and. Like above, if you change both synaptic weights to 1.1, you will make the neuron behave like a logical or, since the threshold is put at 1, and if either input is 1.1, and thus greater than the threshold value, the neuron will fire. In the next line, we see the activation value, which is just the sum of the two weighted inputs. The next line contains the threshold, which in all these examples is 1. But there is no reason not to change it to any other value if you want to experiment. Finally, in the last line, the blue cell contains the output of the neuron. This will be 1 if the neuron has fired or 0 if the neuron has not fired.
You can also easily add additional neurons to your network and try to create more complex behaviours.
The only special thing you need to do is to insert two formulas into the spreadsheet:
Into cell C3 (the “activation” cell), we enter the formula for calculating the weighted sum of the two inputs: =(D1*D2)+(B1*B2). Into cell C5 (“output”), we enter a conditional statement: =if(C3>=C4, 1, 0). This is saying: if the sum of the inputs (cell C3) is greater than the threshold (cell C4), the neuron will fire (output=1); otherwise, it will stay silent (output=0). These formulas are written for Google Sheets, so if you use another spreadsheet application, you might need to change the syntax a bit.
That’s it! Your first, very own artificial neuron. You can now play with it. You can change the synaptic weights and the activation thresholds, and observe how it works. You can also easily add additional neurons to your network and try to create more complex behaviours. Of course, this doesn’t yet learn. It is pre-programmed by the fixed synaptic weights to do one thing only.
As an additional example, let’s look at how we would create a little network that can calculate the ‘exclusive or’, or xor, function in a spreadsheet. Here is the network we want to simulate (we discussed how this works in the previous post):
Image by the author
And here is the same neural network in a spreadsheet table. Again, the input is on top (yellow), and the output is at the bottom (blue). But now we have three neurons. The first layer (above) consists of two neurons (pink and green). Each of these neurons is connected to the two yellow inputs; this is why each has two synapses instead of one. Each of these neurons has its own (blue) output. Both intermediate outputs from the first layer feed into the orange neuron at the bottom. The orange neuron’s inputs are the outputs of the previous layer; this is why we don’t have yellow input cells for that neuron. The output of the whole network is the blue cell at the very bottom.
This neuron will implement an xor function between its (yellow) inputs in the first row and the blue output cell at the very bottom:
Image by the author
What you can see from this, is how the behaviour of a neural network is all encoded in the synaptic weights, which, in this case, we entered by hand. In a later post will see how an artificial neural network can change these weights by itself, and in this way learn new behaviours. Make sure to follow this series, so you don’t miss the fun!
Simulating neural networks in a spreadsheet is a great way to learn how they work and to get accustomed to the basic ideas and the structure of artificial neurons. I hope you enjoyed this and I hope to see you around here next time!
Thanks for reading! | https://medium.com/the-innovation/neurons-in-spreadsheets-e917c5c77a22 | ['Moral Robots'] | 2020-10-10 17:38:20.374000+00:00 | ['Neural Networks', 'Artificial Intelligence', 'AI', 'Programming', 'Education Technology'] |
When is data science a house of cards? | June Andrews | Pinterest engineer, Data Science
As data scientists, when we reach an answer, we often communicate that answer and move on. But what happens when there are multiple data scientists with varying answers? The expense of replicating and testing the quality of work often leaves critical business challenges unstaffed. At Pinterest, we lowered the cost of replication to the point that could afford to run an experiment. So we did. We asked nine data scientists and machine learning engineers the same question, in the same setting, on the same day. We received nine different results.
Reducing the costs of data science
In order to efficiently replicate results nine times, we used a new method of iterative supervised clustering. It’s phenomenally easy to grok and comes with a three step Python notebook with pre-loaded data. It makes analysis fun again. The algorithm is an extension of Klaufman and Kleinberg’s KDD paper and is explained in the following diagrams.
Stage 1: Use your favorite clustering algorithm to break up data into candidate clusters.
Stage 2: Ask a domain expert to interact with visualizations of each cluster, select the most human interpretable description and define that cluster. A cluster definition includes a name, a description and a short Python function determining if a point belongs to that cluster.
Stage 3: Now that we have a human interpretable cluster, we don’t need the machine to focus on data in that cluster, so remove the labeled data. Repeat from stage 1 and stop when the domain expert is no longer interested in the remaining data and labels remaining points as Unclassified.
There we go! The power of human interpretable clustering is now in your hands.
Digging into billions of data-rich Pins
There was one particular question we wanted to put this to use for. As a catalog of ideas, Pinterest is built on an interest graph of +75 billion Pins saved by +100 million monthly active users onto +1 billion boards. Boards articulate how ideas can become reality. This is incredible data. There’s a tiny detail that works so well, you rarely notice it — behind each Pin is a link into the wild wild web. For the sources behind Pins, we wanted to know how do Pinners engage with link domains?
Measuring Pin engagement
To answer this question, we pulled a sample of 100K link domains and looked at how Pinners engaged with content during its first year on Pinterest. In particular, we pulled Pins created from the Pinterest Save button, both on and off Pinterest. The volume of new Pins reflects how a domain is performing on the web, and repins reflect how a domain is performing on Pinterest. The data was cleaned, normalized and loaded into a Python notebook. (We love our app aesthetic, and couldn’t help but have our notebooks follow suit.)
Find additional clustering details in my talk at the from the O’Reilly Strata conference.
You’ll find link domains fall into an interesting set of clusters. My favorite is “Pinterest Specials”, domains whose popularity or reachability has greatly diminished on the web, but whose content lives on and thrives within the Pinterest ecosystem. Here are our the monikers of Link Domain Types:
Replicating data science
We asked the question of how Pinners engage with link domains and found an interesting and insightful answer that helps us understand what types of products to build. Let’s ask that question again. This is where we asked nine data scientists and machine learning engineers the same question. Each is an industry veteran and has been at Pinterest for more than one year. They work with Pinterest content and are part of the team helping surface great content to Pinners through 1.5 trillion recommendations every year. With the above algorithm and handling of the data, each person completed a clustering of link domains within an hour. The only remaining step before sharing the cluster with colleagues was pulling domain examples from each cluster.
Before we reveal the results, let us take a quick minute to review existing work touching on the replicability of analysis. Three incredible industry studies have surfaced in the last year. The first was a study on how skin tone affected the rate at which red cards attributed in soccer, published in Nature. Twenty-nine crowd-sourced researchers analyzed the same data and shared reviews of each other’s methods. While there’s a relatively consistent answer of yes, it makes a slight difference. Ten of the 29 teams have deviating results from the opposite conclusion to an astonishingly strong correlation.
The replication crisis in medicine and science deserves at least one citation in this context. Last year, Begley and Ioannidis [Reproducibility in Science] pegged 75 percent to 90 percent of preclinical research as irreproducible. If you care about the effectiveness of cancer treatments, you’re in for a scary read. While some flaws have arisen from scandals of fabricated data such as with Diederik Stapel a majority of shortcomings have been attributed to the analysis of data and the human error under pressure to produce publishable results.
In a recent test of asking the same question of the same data, The New York Times sent the same poll results to four other reputable pollsters. While the difference between Clinton at +3 and Clinton at +4 may seem negligible, one reputable pollster reported a conclusion of Trump winning Florida, which is an astronomically different outcome.
For data science, is the diversity of our results on the level of Clinton within one point, or are data science results on polar ends of the spectrum?
Going back to our test with nine data scientists and machine learning engineers, through the development of lightweight interactive algorithms and using Python notebooks with preloaded data, we lowered the cost of replicating data science work to the point we could ask everyone the same question: how do Pinners engage with link domains?
Results
We received nine different results that were so different, they may as well be as diverse as the previous studies in reproducibility.
We found two reasons for the different results. The smaller influence was that some results contained bad answers. First, these answers were caused by two skills we can detect and level up people in:
Preconceived notions of what the data entails before looking at the data. Cherry picking on a subset of features without understanding the larger picture.
The second cause comes from a difference in perspective. Some data scientists were intent on the viral aspects of growth while others focused on the return on investment within the Pinterest ecosystem. For a sample of different universes of perspective on Pinterest content, here are the unique monikers of clusters in different results:
House of cards
We asked the same question nine times and received nine astronomically different answers. When have we built irreproducible analysis on top of irreproducible analysis to the point that data-driven decisions are no longer supported by data? If we want to advance in the future we must ask the hard question, we must speak Lord Voldemort’s name. When is data science a house of cards?
There is an avalanche of supporting work I believe will enable data science as a field to answer this question in the near future. A key component is the infrastructural investment by many companies throughout Silicon Valley making experimental systems and fast access to data the standard. Another is that the industry-wide effort to recruit and train data scientists has taken data scientists from a scarce resource to within reach. The most recent key effort is that in reproducibility, a natural precursor to replicability is the ability to run the same analysis over the same data, with the same parameters, twice. Setting those parameters and designing models is still an expensive process, requiring a week or more for a broad question. With the development of faster Human-in-the-Loop algorithms, we’re lowering the cost of having multiple data scientists answer the same question. All of these components combined bring on the perfect storm to experiment and understand how different data science practices impact the business bottom line.
It’s a hard question. But as a field, I believe we can take it on. To stay informed and be involved in future efforts, join us. | https://medium.com/pinterest-engineering/when-is-data-science-a-house-of-cards-86c9ab0a2c6f | ['Pinterest Engineering'] | 2017-02-21 20:16:02.646000+00:00 | ['Data Science', 'Big Data', 'Engineering', 'A B Testing', 'Pinterest'] |
The Future of Content Marketing is Already Here | Experienced marketers expect change. If you continue to use the same strategies and tactics today that worked 20 years ago, you will get buried.
It has been quietly whispered in marketing circles for the past few years that Google has been suppressing organic reach. It has been more difficult to hit the magically shrinking first page of the world’s largest search engine.
The experts at The Markup finally conducted an experiment that demonstrated what most marketers already suspected — Google shows you a lot of content to keep you on Google before showing you any organic results.
While these practices may raise ethical and antitrust concerns, you have to deal with the reality on the ground. It’s time for businesses and marketers to think about what the true state of content marketing is. Cranking out dozens or hundreds of 500-word blog posts is not going to help your business.
That doesn’t mean content marketing is dead. It means that you need to look at the purpose of content marketing is and understand how to use it beyond keywords and blog posts.
Purpose of Content Marketing
Content marketing is a way to build trust with your ideal prospects and move them into your sales funnel. Content marketing was not invented for the internet. It has existed for hundreds of years.
Benjamin Franklin’s Poor Richard’s Almanac was a form of content marketing to show off his printing expertise. Brands as diverse as John Deere and Betty Crocker have made fortunes using content marketing long before the first microprocessor was ever fired up.
We tend to associate content marketing with blog posts because that has been one of the cheapest tools in the marketing toolbox for the past 20 years. Only recently have businesses begun to embrace video and podcasts as content marketing tools.
Many marketers have gotten complacent. They acted like Google would always be around to drive organic traffic to websites if they followed a few simple best practices. While those days are long gone, that doesn’t mean blogs or content marketing are dead.
It means that you need to find new ways to get your content in front of your ideal customers. You need to be more creative and disciplined in how you showcase your authority and expertise.
Google is Killing Traditional Business Blogging
A blog used to be the best way to build almost any kind of online business. You could write high-quality posts and know that the search engine algorithms would eventually find your content. If you wanted to build an audience faster, you could just write more content.
Blogs can still be a powerful way to build a business. But, it takes much longer to bear fruit. You also can’t put up a bunch of short blogs. Your content needs to be more detailed than ever before.
You are not just competing with other blogs — you are competing with Google’s desire to drive traffic within its own ecosystem.
The best performing blog content is now skyscraper posts or cornerstone posts that are 2,000-words to 10,000-words long. These are much more expensive to produce, but if used wisely, they provide a much higher return on investment than short blog posts that now seem disposable.
You also need to do more legwork to drive traffic to your content. That means rethinking the way your sales funnels are constructed.
The Old Model and the New Way
The old content marketing model relied on organic traffic. You wrote content that people found on search engines. That content invited people to contact you or to join your mailing list. Once you had a prospect’s contact information, you could guide them through your sales funnel.
Now, organic traffic is too slow and too small. If you have enough time, six months to three years, you can still rely primarily on organic traffic to power your business. Most entrepreneurs and marketers aren’t that patient.
The new way requires you either invest in social media advertising to drive traffic to your content or to expand the channels you use to increase your organic reach. This often means branching out from blog posts and expanding into different types of media.
Content marketing is a way for you to show your audience what you can do. It provides an entrance to your sales funnel.
If your content is only generating likes, views, and shares, you are doing it wrong. Effective content marketing collects contact information, and it generates email list sign-ups.
Is Email the New Blog?
Email has always been an important part of a digital marketing strategy. If you have someone’s email, you have the key to their heart. You can reach them directly. Direct marketing is the best way to convert marketing dollars into revenues.
It used to be that you created a massive amount of content to generate email list sign-ups. Now, you need to create fewer, better quality types of content to generate email sign-ups. Instead of pushing out blog posts to social media and the blogosphere, savvy businesses now save their best material for their email lists.
Services like Substack are betting massive amounts of money that email newsletters will replace the blog as the primary form of long-term content marketing.
It is much more cost-effective to invest money in high-value content as a lead magnet to build email lists of your ideal customers than to write a million blog posts. Once you have someone on your list, you can send them the same content you used to put on your blog in an email. Your emails nurture the relationship with your audience the way blog posts used to. But, with email, you have a much better sense of how effective something is.
You also can drill down on the core needs of your audience.
Best of all, Google isn’t scraping your email content and using it to keep people in their ecosystem. Email gives you a direct line to the people most likely to buy from you.
Content Curation
Another critical difference in modern content marketing is the role curation plays. The truth is none of your customers lack access to information. They don’t need you to tell them how or why to do something. They can just ask Siri or Alexa.
What your audience needs is a way to filter all of the information out there. While every business still needs to create amazing content, they also need to focus on curating content for their customers.
Curation means you put the best of the web together in a simple bundle for people to consume. You will want to include some of your best work too. Through curation, more people will come to trust you. They will also learn to enjoy your unique brand voice.
If you love music, chances are you enjoy checking out the playlists your favorite artists make in Spotify. Those playlists are a form of curation. They are a type of content marketing.
Curation scares some businesses because they are afraid of sending their customers away. They don’t trust their customers to come back.
In March of 2020, Taylor Swift created a Spotify playlist for Women’s History Month that highlighted a bunch of other female artists. Was Swift worried that her fans would discover other artists and never listen to her music again? No, because that’s idiotic. That playlist was good for Swift’s career and it was a nice signal boost to other talented artists.
Curation shows people that you are confident enough in your brand voice and business value to highlight the great work other businesses are doing.
Reimagining Your Sales Funnel
The future of content marketing will require you to create and curate content on many different channels. You may want to use Apple podcasts or TikTok or YouTube. But, no matter where you create content, you need a sales funnel. You need a strategy behind your content marketing.
It used to be that you wanted to drive everyone to your website or blog. You still need your own website. But now you want to drive traffic to a specific lead magnet or landing page to join your mailing list. That lead magnet could be a bribe like a free PDF, or it could be a skyscraper blog post that anyone can access.
You may find that curating content helps you build your email list faster than creating all of your own original content.
However, you need to get people on your email list, and then you need a strategy to nurture those leads into becoming paying customers.
If you think this sounds almost exactly like the old way of building a funnel, you are right. The only difference is in how you are using content to get people to join your email list.
You don’t need a weekly blog anymore. You may get the results you want faster by changing the type of content you are using to attract your ideal customers.
Content marketing and direct marketing are never going to die because they are based on human psychology. However, just like John Deere isn’t using the same content strategies in 2020 that it used in 1920, you shouldn’t be using the same content strategies today that you used in 2000, or even in 2016.
The best content marketing is not dependent on Google or any other single platform to drive traffic and generate leads.
The future of content marketing requires empathy, creativity, and adaptability. Instead of churning out another basic 500-word blog post today, spend time reimaging ways to show your ideal customers you can help them.
That’s what successful marketers have always done and will continue to do. | https://medium.com/escape-motivation/the-future-of-content-marketing-is-already-here-546ab978708f | ['Jason Mcbride'] | 2020-08-16 06:53:24.532000+00:00 | ['Marketing', 'Content Marketing', 'Email Marketing', 'Business', 'Writing'] |
Objectron: Real-Time 3D Object Detection with Smartphone | DEEP LEARNING
Objectron is a new SOTA dataset, recently presented by Google AI, which intended to improve 3D object recognition in videos. The dataset contains 15 thousand short video clips, each containing annotation of 3D boundaries of objects. The dataset contains both real clips and synthetic ones, that is, generated based on real ones.
What is the problem
The dataset is designed to facilitate the process of training models for 3D objects on 2D image and video data.
While 2D prediction only provides 2D bounding boxes, by extending prediction to 3D, one can capture an object’s size, position, and orientation in the world, leading to a variety of applications in robotics, self-driving vehicles, image retrieval, and augmented reality.
To do this, the researchers have collected a dataset that contains information about the structure of 3D objects and improves the accuracy of object detectors. | https://medium.com/deep-learning-digest/objectron-real-time-3d-object-detection-e5a689cc12f6 | ['Mikhail Raevskiy'] | 2020-11-25 10:57:46.995000+00:00 | ['Deep Learning', 'Data Science', 'Machine Learning', 'Artificial Intelligence', 'Computer Vision'] |
Latest Computer Vision Trends from CVPR 2019 | Doing cool things with data!
The 2019 IEEE Conference on Computer Vision and Pattern Recognition (CVPR) was held this year from June 16- June 20. CVPR is one of the world’s top three academic conferences in the field of computer vision (along with ICCV and ECCV). A total of 1300 papers were accepted this year from a record-high 5165 submissions (25.2 percent acceptance rate).
CVPR brings in top minds in the field of computer vision and every year there are many papers that are very impressive.
I have taken the accepted papers from CVPR and done analysis on them to understand the main areas of research and common keywords in Paper Titles. This can give an indication of where the research is moving.
The underlying data and code is available on my Github. Feel free to pull this and add your own spin to it.
CVPR assigns a primary subject area to each paper. The breakdown of accepted papers by subject area is below:
Not surprisingly, most of the research is focused on Deep Learning (isn’t everything deep learning now!), Detection and Categorization and Face/Gesture/Pose. This breakdown is quite generic and doesn’t really give good insights. So next I extracted all the words from the accepted paper and used a counter to count their frequency. The top 25 most common keywords were below:
Now this in more interesting. Most popular areas of research were detection, segmentation, 3D, and adversarial training. It also shows the growing research in unsupervised learning methods.
Finally I also plotted the Word Cloud.
You can use my Github to pull top papers by topic as shown below
Papers with research on “face”
I run a Machine Learning Consultancy. Check out our website here. I love to work on computer vision projects. Feel free to contact through the website or email at [email protected] if you have an idea that we can collaborate on.
Next in the blog I chose 5 interesting papers from the key areas of research. Please note that I picked select papers that appealed the most to me.
The human visual system has a remarkable ability to make sense of our 3D world from its 2D projection. Even in complex environments with multiple moving objects, people are able to maintain a feasible interpretation of the objects’ geometry and depth ordering. A lot of work has been done in depth estimation using camera images in the last few years but robust reconstruction remains difficult in many cases. A particularly challenging case occurs when both the camera and the objects in the scene are freely moving. This confuses traditional 3D reconstruction algorithms that are based on triangulation.
To learn more about depth images and estimating depth of a scene please check out this blog.
This paper solves this by building a deep learning model on a scene where both the camera and subject are freely moving. See gif below:
Depth estimation on moving people
To create such a model we need video sequences of natural scenes captured by moving camera along with accurate depth map for each image. Creating such a data set would be a challenge. To overcome this, the paper very innovatively uses an existing data set — YouTube videos in which people imitate mannequins by freezing in a wide variety of natural poses, while a hand-held camera tours the scene. Because the scene is stationary and only the camera is moving, accurate depth maps can be built using triangulation techniques. This paper is a very interesting read. It solves a complex problem and is very creative in creating a data set for it.
The performance of the trained model on internet video clips with moving cameras and people is much better than any other previous research. See below:
Model comparison through the paper
You can read the full paper here.
2. BubbleNets: Learning to Select the Guidance Frame in Video Object Segmentation by Deep Sorting Frames
I saw several papers on video object segmentation (VOS). This is the task of segmenting an object in a video provided a single annotation in first frame. This finds applications in video understanding and has seen a lot of research in the last one year.
The location and appearance of objects in video can change significantly from frame-to-frame, and, the paper finds that using different frames for annotation changes performance dramatically, as shown below.
Bubblenets video demo
BubbleNets iteratively compares and swaps adjacent video frames until the frame with the greatest predicted performance is ranked highest, at which point, it is selected for the user to annotate and use for video object segmentation.
BubbleNet first frame selection
A video description of the model is shared on youtube and source code is open sourced on Github.
BubbleNets model is used to predict relative performance difference between two frames. Relative performance is measured by a combination of region similarity and contour accuracy.
It takes as input 2 frames to compare and 3 reference frames. It then passes these through ResNet50 and fully connected layers to output a single number f denoting the comparison of the 2 frames. To perform bubble sort, we start with the first 2 frames and compare them. If BubbleNet predicts that frame 1 has better performance than frame 2 then order of frames is swapped and the next frame is compared with the best frame so far. At the end of processing through the entire video sequence the best frame remains. The figure below shows BubbleNets architecture and process for bubble sort.
Overall the authors show that changing the way the annotation frame is selected with no change to underlying segmentation algorithm results in an 11% increase in perform on the DAVIS benchmark data set.
Bubblenets architecture
3. 3D Hand Shape and Pose Estimation from a Single RGB Image
3D hand shape and pose estimation has been a very active area of research lately. This has applications in VR and Robotics. This paper uses a monocular RGB image to create a 3D hand pose and 3D mesh around the hand as shown below.
3D hand mesh from single image
The paper uses Graph CNNs to reconstruct a full 3D mesh of the hand. Here is a good introduction to the topic of Graph CNNs. To train the network, the authors created a large-scale synthetic dataset containing both ground truth 3D meshes and 3D poses. Manually annotating the ground truth 3D hand meshes on real-world RGB images is extremely laborious and time-consuming. However, models trained on the synthetic dataset usually produce unsatisfactory estimation results on real-world datasets due to the domain gap between them. To address this issue, the authors propose a novel weakly supervised method by leveraging depth map as a weak supervision for 3D mesh generation, since depth map can be easily captured by an RGB-D camera when collecting real world training data. The paper has rich details on data set, training process etc. Please read through it if this is an area that interests you.
One interesting learning for me was the architecture of the Graph CNN used for mesh generation. The input to this network is a latent vector from the RGB image. It goes through 2 fully connected layers to output 80x64 features in a coarse graph. It then goes through layers of upsampling and Graph CNNs to output richer details resulting in a final output of 1280 vertices.
3D hand mesh model architecture
4. Reasoning-RCNN: Unifying Adaptive Global Reasoning into Large-scale Object Detection
Reasoning RCNN output
Object detection has gained a lot of popularity with many common computer vision applications. Faster RCNN is a popular object detection model that is frequently used. To learn more about object detection and Faster RCNN checkout this blog. However object detection is most successful when number of detection classes is small — less than 100. This paper addresses the large-scale object detection problem with thousands of categories, which poses severe challenges due to long-tail data distributions, heavy occlusions, and class ambiguities.
Reasoning-RCNN does this by constructing a knowledge graph that encodes common human sense knowledge. What is Knowledge Graph? Knowledge graph encodes information between objects such as spatial relationship (on, near), subject-verb-object (ex. Drive, run) relationship as well as attribute similarities like color, size, material. As shown below categories with visual relationship to each other are closer to each other.
Knowledge Graph
In terms of architecture it stacks a Reasoning framework on top of a standard object detector like Faster RCNN. The weights of the previous classifier are collected to generate a global semantic pool over all categories, which is fed into an adaptive global reasoning module. The enhanced category contexts (i.e., output of the reasoning module) are mapped back to region proposals by a soft-mapping mechanism. Finally, each region’s enhanced features are used to improve the performance of both classification and localization in an end-to-end manner. The diagram below shows the model architecture. Please refer to the paper to get more detailed understanding of their architecture.
The model is trained and evaluated on 3 main datasets — Visual Gnome (3000 categories), ADE (445 categories) and COCO (80 categories). The model is able to get 16% improvement on Visual Gnome, 37% on ADE and a 15% improvement in COCO on mAP scores.
Training code will be open sourced at this link. Not available yet.
5. Deep Learning for Zero Shot Face Anti-Spoofing
A lot of progress has been made on Facial Detection in the last few years and now facial detection and recognition systems are commonly used in many applications. In Fact it is possible to build a system that detects faces, recognizes them and understands their emotions in 8 lines of code. See blog here.
However there is also continuous risk of face detection being spoofed to gain illegal access. Face anti-spoofing is designed to prevent face recognition systems from recognizing fake faces as the genuine users. While advanced face anti-spoofing methods are developed, new types of spoof attacks are also being created and becoming a threat to all existing systems. This paper introduces the concept of detecting unknown spoof attacks as s Zero-Shot Face Anti-spoofing (ZSFA). Previous ZSFA works only study 1- 2 types of spoof attacks, such as print/replay, which limits the insight of this problem. This work investigates the ZSFA problem in a wide range of 13 types of spoof attacks, including print, replay, 3D mask, and so on. The image below shows different types of spoof attacks.
Face spoofing can include various forms like print (print a face photo), replaying a video, 3D mask, face photo with cutout for eyes, makeup, transparent mask etc. The paper proposes to use a deep tree network to learn semantic embeddings from spoof pictures in unsupervised fashion. Embeddings here could model things like human gaze. It creates a data set of spoof images to learn these embeddings. During the testing, the unknown attacks are projected to the embedding to find the closest attributes for spoof detection.
Read the paper for more detail about the model architecture for deep tree network and process for training it. The paper is able to create embeddings that separate out live face (True Face) with various types of spoofs. See t-SNE plot below
This paper was awesome. A promising research into tackling a practical problem.
Conclusion
It is fascinating to see all the latest research in Computer Vision. The 5 papers shared here are just the tip of the iceberg. I hope you will use my Github to sort through the papers and select the ones that interest you.
I am extremely passionate about computer vision and deep learning in general. I have my own deep learning consultancy and love to work on interesting problems. I have helped many startups deploy innovative AI based solutions. Check us out at — http://deeplearninganalytics.org/.
You can also see my other writings at: https://medium.com/@priya.dwivedi
If you have a project that we can collaborate on, then please contact me through my website or at [email protected]
References: | https://towardsdatascience.com/latest-computer-vision-trends-from-cvpr-2019-c07806dd570b | ['Priya Dwivedi'] | 2019-08-09 17:45:03.421000+00:00 | ['Machine Learning', 'Artificial Intelligence', 'Trends', 'Computer Vision', 'Data Science'] |
The Brain and Body Prioritize Adaptation, Not Balance | The Brain and Body Prioritize Adaptation, Not Balance
‘Allostasis’ is reshaping science’s understanding of disease and disorder
In ancient Greece, the top medical minds believed that the function of the human brain and body was dependent on the proper ratio of four internal fluids which were known as the “humors.” Too much or too little of any one of the humors was thought to cause pain, dysfunction, and behavioral or emotional intemperance.
This cocktail mixologist’s notion of human physiology continued to dominate medical theory until the 19th century, when doctors finally recognized that “humorism” was mostly bunk. But they couldn’t quite shake off the belief that a sick body is somehow a body out of balance.
The next big idea that emerged — one that became “the dominant explanatory framework for physiological regulation” from the late 1800s all the way up to the present — is the concept of “homeostasis.” In a nutshell, homeostasis holds that the human body has certain baseline states or “set points” that it strives to maintain. Constancy is the goal, and disease and disorder are the result of deviations from these set points or the body’s unsuccessful attempts to get back to them. Like Leonardo da Vinci’s Vitruvian Man, homeostasis holds that a healthy body and mind are in all ways proportional.
Type-1 diabetes is often cited as an example of homeostatic principles at work: An insulin insufficiency causes dangerous disruptions in the blood’s levels of glucose; introducing insulin via injection helps restore balance.
But some experts have challenged the idea that the ultimate goal of the body’s inner workings is to maintain some predetermined set point or state of balance. “Homeostasis is all about staying the same, but most physiological systems are about change and adapting to it,” says Jay Schulkin, PhD, a behavioral neuroscientist at the University of Washington.
Schulkin’s work has contributed to a newer concept of human health and functioning known as “allostasis,” which means “stability through change.” It argues that, rather than simply striving to preserve a steady state of internal balance, the human body and brain are designed to anticipate and make preparatory adjustments based on experience.
For example, levels of digestive enzymes and energy-transporting hormones rise before a person eats a meal, and the specifics of these shifts depend in part on that person’s typical diet, eating schedule, and other past behaviors. If that person normally eats an unhealthy, sugar-rich diet, these pre-meal enzyme and hormone shifts — including ones that can contribute to poor energy metabolism and type-2 diabetes — will happen even if the person ends up dining on healthier fare.
What the homeostasis model may regard as disorder or dysfunction, allostasis views as a logical response to external events or stimuli — even if that response has some unwelcome drawbacks. “Allostasis takes into account the environment and social contexts and how we adapt to them,” Schulkin says.
For too long, he says that homeostatic theory has dominated medical science and its approach to research and treatment. Allostasis, by shifting the medical community’s notions of how the brain and body work, could inform more productive scholarship and better maybe especially when it comes to mental health conditions like anxiety and depression.
“We need a concept like allostasis that takes into account how we manage to adjust, or don’t manage to adjust, to things in our life,” he says.
Allostasis and mental health
Anxiety disorders, depression, and other mental health challenges are often described as the result of chemical “imbalances” in the brain. This homeostasis-influenced view has been around for decades, and it serves as the foundation for contemporary pharmacotherapy. By correcting these supposed imbalances — for example, by increasing levels of the neurotransmitter serotonin — these drugs are intended to improve mood, cognition, or behavior.
But some proponents of allostasis hold a different view. While mental health disorders are frequently associated with elevated or reduced levels of certain neurotransmitters, they say that there’s little evidence that these disorders are caused by neurotransmitter imbalances. “Drugs amount to a blind tweaking of circuits that are not even identified, let alone understood,” says Peter Sterling, PhD, a professor of neuroscience at the University of Pennsylvania and author of What Is Health? Allostasis and the Evolution of Human Design.
While this kind of tweaking may in some cases help relieve a person’s symptoms, it doesn’t address the underlying causes of those symptoms, Sterling says. Adjusting the brain’s levels of neurochemicals can also interfere with other aspects of mood or cognition, and in some cases can induce bouts of paranoia, anger, or other negative side effects.
“We need a concept like allostasis that takes into account how we manage to adjust, or don’t manage to adjust, to things in our life.”
Sterling, along with the late UPenn biologist Joseph Eyer, coined the phrase “allostasis” and has been developing and refining its model for more than 30 years. He says that the big idea — the thing that really differentiates allostasis from homeostasis — is the recognition that the brain and body are constantly trying to predict and adapt through adjustments to a person’s physiology and behavior. “The most efficient way to run the body is for the brain to figure out ahead of time what will be needed,” he says.
Allostasis concepts help explain why a person whose life is filled with stress may experience worry and its physical manifestations — such as elevated blood pressure, rapid heart rate, and GI discomfort — even during those times when no threat or source of stress is present. Rather than returning to a set point — which is the response that the homeostasis model predicts — the brain has adapted.
In a 2014 paper in JAMA Psychiatry, Sterling explains how this allostatic understanding of the brain and body may inform mental health treatment. If practiced in the right contexts, mindfulness meditation, cognitive behavioral therapy, and other non-drug programs designed to encourage constructive thoughts, attitudes, and behaviors could engage the brain’s adaptation mechanisms in therapeutic ways.
By changing the brain’s experience of life, people can remodel their own neural circuitry in ways that reduce the burden of mental health challenges, he says.
A broad conceptual shake-up
Not everyone buys into the idea of allostasis. Some experts have argued that it’s just a reorganization and rebranding of concepts already folded into homeostatic theory. Others see all the homeostasis-allostasis bickering as a semantical sideshow that doesn’t have much bearing on health and medicine.
But plenty of experts agree that some new ways of thinking and talking about health are needed. Especially when it comes to mental health, a number of doctors have argued that the terms and theoretical frameworks we apply to some of these conditions need refurbishment.
Peter Kinderman, PhD, a professor of clinical psychology at the University of Liverpool in the U.K., says that the current language around mental health pathologizes what are in a lot of instances predictable and logical responses to distressing life events, and that it might be better to refer to certain mental health conditions as experiences, rather than disorders.
For example, depression and anxiety symptoms have increased in the U.S. during the coronavirus pandemic. SARS-CoV-2 poses a very real and deadly threat to oneself and one’s loved ones, and it has also contributed to economic, political, and social turmoil. Reacting to all this with feelings of sadness or anxiousness is not “a dysfunction in the biology of the brain,” Kinderman says. “There’s nothing pathological about that response.” Using more appropriate language to describe these experiences could in many cases help people move on from — rather than just manage — what they’re dealing with, he adds.
These sorts of conceptual health debates aren’t going away anytime soon, and they’re of a piece with broader discussions about contemporary life and the way it may be driving historically high rates of metabolic disease and existential torment.
“Homeostasis doesn’t explain why half of the population is obese or diabetic, or why we have such high rates of so-called ‘deaths of despair,’” Sterling says. “I think we’re overdriving the body and demanding too much of these mechanisms that aren’t really broken, they’re just mistreated.”
Embracing an allostasis model of human functioning, he says, may help us better address these growing problems. | https://elemental.medium.com/the-brain-and-body-prioritize-adaptation-not-balance-c64aa6bb36be | ['Markham Heid'] | 2020-09-24 05:32:39.106000+00:00 | ['Disease', 'Brain', 'The Nuance', 'Body', 'Science'] |
We Design Reality With Words | Before a pandemic chewed through our livelihoods and collective mental health, summer used to be silly season. News slowed down to a crawl, trivia and oddities took their place, and life read a little easier for a while. But now? It’s been surreal season for so long constant overwhelm is the new normal. If words matter to you and you’re concerned about the political climate, you may have come to regard writing with suspicion and doubt. Is there no other way to earn a living with words than by oozing fear, greed, and anger in print or riding the coat tails of celebrities who behaved badly? Recycling the worst of the zeitgeist ad nauseam is no way to improve it, defunding dumb may be more effective.
If there’s no financial incentive to produce garbage then the trash will eventually take itself out. Meanwhile, the internet is a dump, digital detritus abounds, and everyone is scavenging for meaning.
We don’t have to be seagulls. | https://asingularstory.medium.com/we-design-reality-with-words-761e1e89bf77 | ['A Singular Story'] | 2020-08-28 09:24:20.258000+00:00 | ['Media', 'Social Media', 'Writing', 'Creativity', 'Philosophy'] |
How to Finetune mT5 to Create a Question Generator 🤔(for 100+ Languages) | Its been a month since Google released the massive multilingual model mT5. I was really excited to perform some crazy experiments using mT5. The special quirk about mT5 is its ability to perform any seq-2-seq task in more than 100 languages. I experimented with mT5 on mainly two tasks i.e. for language translations and secondly Question generation. I found the second use case much more interesting. So I created this blog as a tutorial on how to use mT5 for finetuning mT5 to build a question generator.🤩
What is exactly a question generator!
Question generators generate questions. They can be used by teachers and students for generating a variety of questions from a giving text. They can be particularly helpful for comprehension type questions.
Now that we know what is questions generator, let's build one. I will build question generator for Hindi language and you can replicate it on any 101 languages of your choice on which mT5 is trained on. (provided you have the dataset) You can check out supported language here.
Task
Let's define the task. For generating questions we need to input a text context to the mT5 model and expect a question in return.
Here is an example in English:
Context: Donald John Trump (born June 14, 1946) is the 45th and current president of the United States. Before entering politics, he was a businessman and television personality.
Output: Who is Donald Trump?
Since we are mainly focusing on the Hindi language we will have Hindi Context as input and Hindi Question as Output.
Dataset Collection
One another major issue in languages other than English is lack of quality Dataset for training and fine-tuning transformers models. Luckily for us, I found two similar datasets which just fulfil our dataset requirement in the Hindi language.
First is Deepmind Xquad Dataset (Cross-lingual Question Answering Dataset)and Facebook MLQA (MultiLingual Question Answering).
XQuAD (Cross-lingual Question Answering Dataset) is a benchmark dataset for evaluating cross-lingual question answering performance. The dataset consists of a subset of 240 paragraphs and 1190 question-answer pairs from the development set of SQuAD v1.1 (Rajpurkar et al., 2016) together with their professional translations into ten languages: Spanish, German, Greek, Russian, Turkish, Arabic, Vietnamese, Thai, Chinese, and Hindi. MLQA (MultiLingual Question Answering) is a benchmark dataset for evaluating cross-lingual question answering performance. MLQA consists of over 5K extractive QA instances (12K in English) in SQuAD format in seven languages — English, Arabic, German, Spanish, Hindi, Vietnamese and Simplified Chinese. MLQA is highly parallel, with QA instances parallel between 4 different languages on average.
I collected 1190 context-question pairs from Deep Mind Xquad dataset. From Facebook MLQA I concatenated test and dev dataset which consist a total of 5425 context-question pairs.
Since both datasets were originally present in JSON format for the ease of using I converted them CSV format. I divided the overall collected dataset into two sets: A training set with 6500 context-question pairs and testing set with 150 context-question pairs. The reason for keeping such low count testing set is unlike in classification problems, text generation problem doesn’t benefit much from a large testing dataset (since we do not have metric to evaluate generated questions or text generation in general).
Above is the script I created to perform these operations. (Colab notebooks are less convenient than Kaggle as Kaggle provide P100 GPU while Colab has Tesla T4 thus much lesser time while finetuning on Kaggle).
Finetuning mT5 using pytorch-lightning
We’ll be using PyTorch-lightning library for finetuning. Most of the code below is adapted from here. The trainer is generic and can be used for any text-2-text task. You’ll just need to change the dataset. Rest of the code will stay unchanged for all the tasks.
This is the most interesting and powerful thing about the text-2-text format. You can fine-tune the model on a variety of NLP tasks by just formulating the problem in the text-2-text setting. No need to change hyperparameters, learning rate, optimizer or loss function.
I trained the ‘google/mt5-base’ for 10 epochs with a batch size of 8. Here is the link to the fine-tuning script.
If you want to finetune mT5 on any of your tasks you need to take care of two things.
Create your own dataset in CSV format and change the dataset path in the fine-tuning Kaggle notebook. (dataset must have two files train.csv and valid.csv)
Secondly, change the QuestionDataset class in the above Kaggle notebook according to your use case. The input format I used while finetuning is
Input = "Hindi Context: %s" % (input_text)
# input_text is the given input to the model
Inference for Question Generation
Inferencing the model is the easiest part as we have done most of the heavy lifting. Let's check out the results.
from transformers import MT5ForConditionalGeneration, AutoTokenizer
model = MT5ForConditionalGeneration.from_pretrained("../input/mt5-hindi-question-generator")
tokenizer = AutoTokenizer.from_pretrained("google/mt5-base")
Input text (Any paragraph in the Hindi language)
article = '''Hindi context:पूरे विश्व भर में भारत एक प्रसिद्ध देश है। भौगोलिक रुप से, हमारा देश एशिया महाद्वीप के दक्षिण में स्थित है।
भारत एक अत्यधिक जनसंख्या वाला देश है साथ ही प्राकृतिक रुप से सभी दिशाओं से सुरक्षित है। पूरे विश्व भर में अपनी महान संस्कृति और पारंपरिक मूल्यों के लिये ये एक प्रसिद्ध देश है।
इसके पास हिमालय नाम का एक पर्वत है जो विश्व में सबसे ऊँचा है। ये तीन तरफ से तीन महासागरों से घिरा हुआ है जैसे दक्षिण में भारतीय महासागर, पूरब में बंगाल की खाड़ी और पश्चिम में अरेबिक सागर से।
भारत एक लोकतांत्रिक देश है जो जनसंख्या के लिहाज से दूसरे स्थान पर है। भारत में मुख्य रूप से हिंदी भाषा बोली जाती है परंतु यहां लगभग 22 भाषाओं को राष्ट्रीय रुप से मान्यता दी गयी है।
'''
For decoding, we can either use greedy decoding with single question generation or top_kp decoding with multiple questions generation.
Here are the results obtained
start = time.time()
encoding = tokenizer.encode_plus(article, return_tensors="pt")
input_ids, attention_masks = encoding["input_ids"].to(device), encoding["attention_mask"].to(device)
print(article)
output = greedy_decoding(input_ids,attention_masks)
print ("Greedy decoding::
",output)
end = time.time()
print ("
Time elapsed ", end-start)
print ("
")
Output :
Hindi context:पूरे विश्व भर में भारत एक प्रसिद्ध देश है। भौगोलिक रुप से, हमारा देश एशिया महाद्वीप के दक्षिण में स्थित है।
भारत एक अत्यधिक जनसंख्या वाला देश है साथ ही प्राकृतिक रुप से सभी दिशाओं से सुरक्षित है। पूरे विश्व भर में अपनी महान संस्कृति और पारंपरिक मूल्यों के लिये ये एक प्रसिद्ध देश है।
इसके पास हिमालय नाम का एक पर्वत है जो विश्व में सबसे ऊँचा है। ये तीन तरफ से तीन महासागरों से घिरा हुआ है जैसे दक्षिण में भारतीय महासागर, पूरब में बंगाल की खाड़ी और पश्चिम में अरेबिक सागर से।
भारत एक लोकतांत्रिक देश है जो जनसंख्या के लिहाज से दूसरे स्थान पर है। भारत में मुख्य रूप से हिंदी भाषा बोली जाती है परंतु यहां लगभग 22 भाषाओं को राष्ट्रीय रुप से मान्यता दी गयी है।
Greedy decoding::
भारत में कितनी भाषाएं बोली जाती हैं?
Time elapsed 1.0903606414794922
So the question generated seems pretty legit😇😇.
Here is the top_kp output for multiple questions
Hindi context:पूरे विश्व भर में भारत एक प्रसिद्ध देश है। भौगोलिक रुप से, हमारा देश एशिया महाद्वीप के दक्षिण में स्थित है।
भारत एक अत्यधिक जनसंख्या वाला देश है साथ ही प्राकृतिक रुप से सभी दिशाओं से सुरक्षित है। पूरे विश्व भर में अपनी महान संस्कृति और पारंपरिक मूल्यों के लिये ये एक प्रसिद्ध देश है।
इसके पास हिमालय नाम का एक पर्वत है जो विश्व में सबसे ऊँचा है। ये तीन तरफ से तीन महासागरों से घिरा हुआ है जैसे दक्षिण में भारतीय महासागर, पूरब में बंगाल की खाड़ी और पश्चिम में अरेबिक सागर से।
भारत एक लोकतांत्रिक देश है जो जनसंख्या के लिहाज से दूसरे स्थान पर है। भारत में मुख्य रूप से हिंदी भाषा बोली जाती है परंतु यहां लगभग 22 भाषाओं को राष्ट्रीय रुप से मान्यता दी गयी है।
Topkp decoding::
['भारत कहाँ स्थित है?', 'भारत के पास कितनी भाषाएँ हैं?', 'भारत की मुख्य भाषा क्या है?', 'भारत में मुख्य रूप से कौन सी भाषाएं बोली जाती हैं?', 'भारत में कितनी भाषाएँ बोली जाती हैं?', 'भारत की दूसरी लोकतांत्रिक सरकार क्या है?', 'भारत का हिस्सा किस महाद्वीप के दक्षिण में है?', 'भारत में कौन सी भाषा बोली जाती है?', 'हिंदी भाषा की कौन सी संस्कृति सबसे अधिक लोकप्रिय है?', 'भारत की जनसंख्या क्या है?']
Time elapsed 1.3107168674468994
So as you can see few questions are grammatically incorrect but if we check the overall quality its good for basic uses.
If you want to experiment more with my Hindi question generator check out my notebook on Kaggle.
So I conclude my blog on the question generator using mT5. You can now finetune mT5 on the various task in various languages. All the Kaggle notebooks and dataset used is set to public (anyone can use). I have given references for so many notebooks which might be confusing so if you have any question you may ask in comments. So are you ready to experiment with mT5?🤔🤔🤔
References:
Original Suraj Patil Colab on Finetuning T5 | https://medium.com/swlh/how-to-finetune-mt5-to-create-a-question-generator-for-100-languages-4a3878e63118 | ['Parth Chokhra'] | 2020-12-04 12:51:59.441000+00:00 | ['Machine Learning', 'Artificial Intelligence', 'Google', 'Technology', 'Programming'] |
Human Ego and Aspirations Are the Driving Forces Behind Engineering Decisions | The Choice
Let’s start with an example that might be 👀 inspired by a real situation.
The team needs to make a technological choice by introducing a new event broker. There is none at the moment. The two contenders are Kafka and Pulsar.
Developer A has significant experience with Kafka in real life situation. They mention the complexity of Kafka operations at scale and vouches for Pulsar. Developer B is a proponent of Kafka, as it became a standard in the industry and has strong support overall. They have little experience working with Kafka though. Both agree that we only have basic requirements with no change in workload for the foreseeable future and these two solutions would both fit the bill. The rest of the team is less opinionated.
After hours of meetings and point-by-point comparisons against a technical criteria grid, Kafka is chosen. Everybody agrees it’s perfectly sound decision-making, the rationale behind the choice is documented, and the team proceeds with the implementation.
But are the true motivations of this choice ever evoked? | https://medium.com/better-programming/human-ego-and-aspirations-are-the-driving-forces-behind-engineering-decisions-1519ecc076ff | ['Emmanuel Sys'] | 2020-12-18 20:47:19.588000+00:00 | ['Programming', 'Startup', 'DevOps', 'Software Development', 'Software Engineering'] |
AWS CDK Continuous Integration and Delivery Using Travis CI | Open Pull Requests to Validate Your Deployment
The best strategy I have found to deploy the code to AWS is to have one branch per stage ( dev , pre , pro ), so every time a new commit reaches one of these branches, we are deploying the actual stack. Yes, it looks like GitOps!
But we don’t want to blindly deploy our CDK stack on an AWS account. So I have an automatic way of opening pull requests when something is merged to the main branch:
Process of opening pull request
Each time something is merged to the main branch, we have a specific job that runs cdk diff -c stage=<STAGE> and opens a pull request to the destination branch.
For that, we use the script below. As you can see, it runs cdk diff and uses the results to open a pull request using the GitHub CLI:
Now we have to call this script inside Travis, so our .travis.yaml file will look like this:
As you can see, we are now using some env variables to specify our AWS Credentials in addition to our GitHub Token. Please make sure to encrypt them before committing them in your repo. | https://medium.com/better-programming/aws-cdk-continuous-integration-and-delivery-using-travis-ci-ee5dd7549434 | ['Thomas Poignant'] | 2020-12-09 16:42:41.710000+00:00 | ['Startup', 'AWS', 'Travis Ci', 'DevOps', 'Programming'] |
Want To Increase Your Readership Today? | Want To Increase Your Readership Today?
Come join us at The Narrative.
As of today, The Narrative — an independent publication designed to house some of Medium’s most influential writers is now accepting submissions to become a contributor.
With over 1300 followers up to date, we use a editor-based model that allows writers to self publish as they please — much like The Partnered Pen.
As Medium’s userbase keeps growing, I understand that it may become increasingly difficult to get views on your articles. This is why I decided to re-brand the publication and use a model that has been working for a lot of active users.
We currently have the following categories:
Arts & Culture
Life Lessons
Career Growth
World Travels
Poetry
Why self-publish?
It’s easy for your article to get lost in a publication, especially with the amount of activity going on Medium these days. When you self-publish, other writers will instantly receive a notification for your article. This will not only help you gain a few new followers, but it will also provide more exposure for your writing too.
Things to remember.
As an editor of The Narrative, editing the posts of other authors without their permission will be frowned upon. Please be mindful of this when contributing to the publication.
The Narrative does not promote any hate speech or plagiarism. If you violate these terms, we will immediately revoke your participation from the publication.
Supporting other writers is highly encouraged. To keep the publication a positive space, we recommend you to read the work of others, highlight and comment as much as you can.
Thank you for your interest in becoming a part of The Narrative. We look forward to hearing your stories. | https://medium.com/the-partnered-pen/want-to-increase-your-readership-today-c10e935fa222 | ['Katy Velvet'] | 2020-12-26 19:26:39.487000+00:00 | ['Writing', 'Medium', 'Business', 'Entrepreneurship', 'Work'] |
Introducing Kaleido: | Introducing Kaleido ✨
Static image export for web-based visualization libraries with zero dependencies
Background
As simple as it sounds on the surface, programmatically generating static images (e.g. raster images like PNGs or vector images like SVGs) from web-based visualization libraries (e.g. Plotly.js) is a complex problem. It’s a problem that library developers have struggled with for years, and it has delayed the adoption of these libraries among scientific communities that rely on print-based publications for sharing their research. Today we introduce Kaleido: an easy to install Chromium-based library for static image export for web-based visualization libraries.
The core difficulty is that web-based visualization libraries don’t actually render plots on their own. Instead, they delegate this work to web technologies like SVG, Canvas, WebGL, etc. Similar to how matplotlib relies on various backends to display figures, web-based visualization libraries rely on a web browser rendering engine to display figures.
When a figure is displayed in a browser window, it’s relatively straight-forward for a visualization library to provide an export-image button because it has full access to the browser for rendering. The difficulty arises when trying to export an image programmatically (e.g. from Python) without displaying it in a browser and without user interaction. To accomplish this, the Python portion of the visualization library needs programmatic access to a web browser’s rendering engine.
There are three main approaches that are currently in use among Python web-based visualization libraries (e.g. Plotly, Bokeh, Altair, ipyvolume, etc.):
The Selenium or pyppeteer Python libraries can be used to control a full system web browser such as Firefox, Chrome, or Chromium to perform image rendering. A custom headless Electron application can be used to perform image rendering using the Chromium browser engine built in to Electron. This is the approach taken by Plotly’s current Orca image export library. When operating in the Jupyter notebook or JupyterLab, a Python library can use the Jupyter Comms protocol to communicate with a custom Jupyter extension running in the browser. This extension can perform the image export and then communicate the results back to the Python process using the Comms protocol.
While approaches 1 and 2 can both be installed using conda , they still rely on all of the system dependencies of a complete web browser, even the parts that aren’t actually necessary for rendering a visualization. For example, on Linux both require the installation of system libraries related to audio ( libasound.so ), video ( libffmpeg.so ), GUI toolkit ( libgtk-3.so ), screensaver ( libXss.so ), and X11 ( libX11-xcb.so ) support. Many of these are not typically included in headless Linux installations like you find in JupyterHub, Binder, Colab, Azure Notebooks, SageMaker, etc. Also, conda is still not as universally available as the pip package manager and neither approach is installable using pip packages.
Additionally, both 1 and 2 communicate between the Python process and the web browser process over a local network port. While not typically a problem, certain firewall and container configurations can interfere with this local network connection.
The advantage of options 3 is that it introduces no additional system dependencies. The disadvantage is that it relies on running within a Jupyter notebook, so it can’t be used in standalone Python scripts.
The end result is that all of these visualization libraries have in-depth documentation pages on how to get image export working, and how to troubleshoot the inevitable failures and edge cases that people run into. While this is a great improvement over the state of affairs just a couple of years ago, and a lot of excellent work has gone into making these approaches work as seamlessly as possible, the fundamental limitations detailed above still result in sub-optimal user experiences. This is especially true when comparing web-based plotting libraries to traditional plotting libraries like matplotlib and ggplot2 where there’s never a question of whether image export will work in a particular context.
The goal of the Kaleido project is to make static image export of web-based visualization libraries as universally available and reliable as it is in matplotlib and ggplot2.
The Kaleido Approach
To accomplish this goal, Kaleido introduces a new approach. The core of Kaleido is a standalone C++ application that embeds the open-source Chromium browser as a library. This architecture allows Kaleido to communicate with the Chromium browser engine using the C++ API rather than requiring a local network connection. A thin Python wrapper runs the Kaleido C++ application as a subprocess and communicates with it by writing image export requests to standard-in and retrieving results by reading from standard-out.
By compiling Chromium as a library, we have a degree of control over what is included in the Chromium build. In particular, on Linux we can build Chromium in headless mode which eliminates a large number of runtime dependencies, including the audio, video, GUI toolkit, screensaver, and X11 dependencies mentioned above. The remaining dependencies can then be bundled with the library, making it possible to run Kaleido in minimal Linux environments with no additional dependencies required. In this way, Kaleido can be distributed as a self-contained library that plays a similar role to a matplotlib backend.
Improvements
Compared to Orca, Kaleido brings a wide range of improvements to plotly.py users.
pip installation support
Pre-compiled wheels for 64-bit Linux, MacOS, and Windows are available on PyPI and can be installed using pip . As with Orca, Kaleido can also be installed using conda .
Improved startup time and resource usage
Kaleido starts up about twice as fast as Orca, and uses about half as much system memory.
Docker compatibility
Kaleido can operate inside docker containers based on Ubuntu 14.04+ or Centos 7+ (or most any other Linux distro released after ~2014) without the need to install additional dependencies using apt or yum , and without relying on Xvfb as a headless X11 Server.
Hosted notebook service compatibility
Kaleido can be used in just about any online notebook service that permits the use of pip to install the kaleido package. These include Colab, Sagemaker, Azure Notebooks, Databricks, Kaggle, etc. In addition, Kaleido is compatible with the default Docker image used by Binder.
Security policy / Firewall compatibility
There were occasionally situations where strict security policies and/or firewall services would block Orca’s ability to bind to a local port. Kaleido does not have this limitation since it does not use ports for communication.
Try it out
Kaleido can be installed using pip…
$ pip install kaleido
or conda.
$ conda install -c plotly python-kaleido
Out of the box, Kaleido supports converting Plotly figures to PNG, JPG, WebP, SVG, and PDF output formats. Support for the EPS format is available when the poppler library is installed. This can be done either using conda, or a system package manager.
When Kaleido is installed, plotly.py 4.9.0+ will automatically use it for image export operations, falling back to Orca if Kaleido is not available. For example…
import plotly.express as px df = px.data.iris() fig = px.scatter(
df, x="sepal_width", y="sepal_length", color="species"
) fig.write_image("fig.png")
This will produce a file named fig.png in the current working directory containing this image
PNG image produced by Kaleido
Beyond plotly.py: Kaleido Scopes
While the development of Kaleido has been motivated by the needs of the plotly.py community, we know we’re not unique in facing these challenges. We’ve designed the C++ and Python portions of Kaleido using a basic plugin architecture (Kaleido plugins are called Scopes) with the goal of making it possible to support image export for other web-based visualization libraries. If you’re interested in adding support to Kaleido for another web-based visualization library, check out the Scope (Plugin) Architecture wiki page and let us know how we can help!
Additionally, since the core of Kaleido is a standalone C++ application that receives export requests on standard-in and writes responses to standard-out, it is relatively straightforward to build wrappers for other languages besides Python. In fact, Kaleido support will be coming soon to the Plotly for Rust library. If you’re interested in writing a Kaleido wrapper for another language, check out the Language Wrapper Architecture wiki page and, again, let us know how we can help.
Learn more | https://medium.com/plotly/introducing-kaleido-b03c4b7b1d81 | ['Jon Mease'] | 2020-07-16 13:33:51.723000+00:00 | ['Python', 'Plotly', 'Data Visualization'] |
Coronavirus: Why You Must Act Now | If you stack up the orange bars until 1/22, you get 444 cases. Now add up all the grey bars. They add up to ~12,000 cases. So when Wuhan thought it had 444 cases, it had 27 times more. If France thinks it has 1,400 cases, it might well have tens of thousands
The same math applies to Paris. With ~30 cases inside the city, the true number of cases is likely to be in the hundreds, maybe thousands. With 300 cases in the Ile-de-France region, the total cases in the region might already exceed tens of thousands.
Spain and Madrid
Spain has very similar numbers as France (1,200 cases vs. 1,400, and both have 30 deaths). That means the same rules are valid: Spain has probably upwards of 20k true cases already.
In the Comunidad de Madrid region, with 600 official cases and 17 deaths, the true number of cases is likely between 10,000 and 60,000.
If you read these data and tell yourself: “Impossible, this can’t be true”, just think this: With this number of cases, Wuhan was already in lockdown.
With the number of cases we see today in countries like the US, Spain, France, Iran, Germany, Japan, Netherlands, Denmark, Sweden or Switzerland, Wuhan was already in lockdown.
And if you’re telling yourself: “Well, Hubei is just one region”, let me remind you that it has nearly 60 million people, bigger than Spain and about the size of France.
2. What Will Happen When These Coronavirus Cases Materialize?
So the coronavirus is already here. It’s hidden, and it’s growing exponentially.
What will happen in our countries when it hits? It’s easy to know, because we already have several places where it’s happening. The best examples are Hubei and Italy.
Fatality Rates
The World Health Organization (WHO) quotes 3.4% as the fatality rate (% people who contract the coronavirus and then die). This number is out of context so let me explain it.
It really depends on the country and the moment: between 0.6% in South Korea and 4.4% in Iran. So what is it? We can use a trick to figure it out.
The two ways you can calculate the fatality rate is Deaths/Total Cases and Death/Closed Cases. The first one is likely to be an underestimate, because lots of open cases can still end up in death. The second is an overestimate, because it’s likely that deaths are closed quicker than recoveries.
What I did was look at how both evolve over time. Both of these numbers will converge to the same result once all cases are closed, so if you project past trends to the future, you can make a guess on what the final fatality rate will be.
This is what you see in the data. China’s fatality rate is now between 3.6% and 6.1%. If you project that in the future, it looks like it converges towards ~3.8%-4%. This is double the current estimate, and 30 times worse than the flu.
It is made up of two completely different realities though: Hubei and the rest of China.
Hubei’s fatality rate will probably converge towards 4.8%. Meanwhile, for the rest of China, it will likely converge to ~0.9%:
I also charted the numbers for Iran, Italy and South Korea, the only countries with enough deaths to make this somewhat relevant.
Iran’s and Italy’s Deaths / Total Cases are both converging towards the 3%-4% range. My guess is their numbers will end up around that figure too.
South Korea is the most interesting example, because these 2 numbers are completely disconnected: deaths / total cases is only 0.6%, but deaths / closed cases is a whopping 48%. My take on it is that a few unique things are happening there. First, they’re testing everybody (with so many open cases, the death rate seems low), and leaving the cases open for longer (so they close cases quickly when the patient is dead). Second, they have a lot of hospital beds (see chart 17.b). There might also be other reasons we don’t know. What is relevant is that deaths/cases has hovered around 0.5% since the beginning, suggesting it will stay there, likely heavily influenced by the healthcare system and crisis management.
The last relevant example is the Diamond Princess cruise: with 706 cases, 6 deaths and 100 recoveries, the fatality rate will be between 1% and 6.5%.
Note that the age distribution in each country will also have an impact: Since mortality is much higher for older people, countries with an aging population like Japan will be harder hit on average than younger countries like Nigeria. There are also weather factors, especially humidity and temperature, but it’s still unclear how this will impact transmission and fatality rates.
This is what you can conclude:
Excluding these, countries that are prepared will see a fatality rate of ~0.5% (South Korea) to 0.9% (rest of China).
Countries that are overwhelmed will have a fatality rate between ~3%-5%
Put in another way: Countries that act fast can reduce the number of deaths by a factor of ten. And that’s just counting the fatality rate. Acting fast also drastically reduces the cases, making this even more of a no-brainer.
Countries that act fast reduce the number of deaths at least by 10x.
So what does a country need to be prepared?
What Will Be the Pressure on the System
Around 20% of cases require hospitalization, 5% of cases require the Intensive Care Unit (ICU), and around 2.5% require very intensive help, with items such as ventilators or ECMO (extra-corporeal oxygenation).
The problem is that items such as ventilators and ECMO can’t be produced or bought easily. A few years ago, the US had a total of 250 ECMO machines, for example.
So if you suddenly have 100,000 people infected, many of them will want to go get tested. Around 20,000 will require hospitalization, 5,000 will need the ICU, and 1,000 will need machines that we don’t have enough of today. And that’s just with 100,000 cases.
That is without taking into account issues such as masks. A country like the US has only 1% of the masks it needs to cover the needs of its healthcare workers (12M N95, 30M surgical vs. 3.5B needed). If a lot of cases appear at once, there will be masks for only 2 weeks.
Countries like Japan, South Korea, Hong Kong or Singapore, as well as Chinese regions outside of Hubei, have been prepared and given the care that patients need.
But the rest of Western countries are rather going in the direction of Hubei and Italy. So what is happening there?
What an Overwhelmed Healthcare System Looks Like
The stories that happened in Hubei and those in Italy are starting to become eerily similar. Hubei built two hospitals in ten days, but even then, it was completely overwhelmed.
Both complained that patients inundated their hospitals. They had to be taken care of anywhere: in hallways, in waiting rooms…
I heavily recommend this short Twitter thread. It paints a pretty stark picture of Italy today
Healthcare workers spend hours in a single piece of protective gear, because there’s not enough of them. As a result, they can’t leave the infected areas for hours. When they do, they crumble, dehydrated and exhausted. Shifts don’t exist anymore. People are driven back from retirement to cover needs. People who have no idea about nursing are trained overnight to fulfill critical roles. Everybody is on call, always.
Francesca Mangiatordi, an Italian nurse that crumbled in the middle of the war with the Coronavirus
That is, until they become sick. Which happens a lot, because they’re in constant exposure to the virus, without enough protective gear. When that happens, they need to be in quarantine for 14 days, during which they can’t help. Best case scenario, 2 weeks are lost. Worst case, they’re dead.
The worst is in the ICUs, when patients need to share ventilators or ECMOs. These are in fact impossible to share, so the healthcare workers must determine what patient will use it. That really means, which one lives and which one dies.
“After a few days, we have to choose. […] Not everyone can be intubated. We decide based on age and state of health.” —Christian Salaroli, Italian MD.
Medical workers wear protective suits to attend to people sickened by the novel coronavirus, in the intensive care unit of a designated hospital in Wuhan, China, on Feb. 6. (China Daily/Reuters), via Washington Post
All of this is what drives a system to have a fatality rate of ~4% instead of ~0.5%. If you want your city or your country to be part of the 4%, don’t do anything today.
Satellite images show Behesht Masoumeh cemetery in the Iranian city of Qom. Photograph: ©2020 Maxar Technologies. Via The Guardian and the The New York Times.
3. What Should You Do?
Flatten the Curve
This is a pandemic now. It can’t be eliminated. But what we can do is reduce its impact.
Some countries have been exemplary at this. The best one is Taiwan, which is extremely connected with China and yet still has as of today fewer than 50 cases. This recent paper explain all the measures they took early on, which were focused on containment.
They have been able to contain it, but most countries lacked this expertise and didn’t. Now, they’re playing a different game: mitigation. They need to make this virus as inoffensive as possible.
If we reduce the infections as much as possible, our healthcare system will be able to handle cases much better, driving the fatality rate down. And, if we spread this over time, we will reach a point where the rest of society can be vaccinated, eliminating the risk altogether. So our goal is not to eliminate coronavirus contagions. It’s to postpone them.
The more we postpone cases, the better the healthcare system can function, the lower the mortality rate, and the higher the share of the population that will be vaccinated before it gets infected.
How do we flatten the curve?
Social Distancing
There is one very simple thing that we can do and that works: social distancing.
If you go back to the Wuhan graph, you will remember that as soon as there was a lockdown, cases went down. That’s because people didn’t interact with each other, and the virus didn’t spread.
The current scientific consensus is that this virus can be spread within 2 meters (6 feet) if somebody coughs. Otherwise, the droplets fall to the ground and don’t infect you.
The worst infection then becomes through surfaces: The virus survives for up to 9 days on different surfaces such as metal, ceramics and plastics. That means things like doorknobs, tables, or elevator buttons can be terrible infection vectors.
The only way to truly reduce that is with social distancing: Keeping people home as much as possible, for as long as possible until this recedes.
This has already been proven in the past. Namely, in the 1918 flu pandemic.
Learnings from the 1918 Flu Pandemic
You can see how Philadelphia didn’t act quickly, and had a massive peak in death rates. Compare that with St Louis, which did.
Then look at Denver, which enacted measures and then loosened them. They had a double peak, with the 2nd one higher than the first.
If you generalize, this is what you find:
This chart shows, for the 1918 flu in the US, how many more deaths there were per city depending on how fast measures were taken. For example, a city like St Louis took measures 6 days before Pittsburgh, and had less than half the deaths per citizen. On average, taking measures 20 days earlier halved the death rate.
Italy has finally figured this out. They first locked down Lombardy on Sunday, and one day later, on Monday, they realized their mistake and decided they had to lock down the entire country.
Hopefully, we will see results in the coming days. However, it will take one to two weeks to see. Remember the Wuhan graph: there was a delay of 12 days between the moment when the lockdown was announced and the moment when official cases (orange) started going down.
How Can Politicians Contribute to Social Distancing?
The question politicians are asking themselves today is not whether they should do something, but rather what’s the appropriate action to take.
There are several stages to control an epidemic, starting with anticipation and ending with eradication. But it’s too late for most options today. With this level of cases, the only options politicians have in front of them are containment, mitigation or suppression.
Containment
Containment is making sure all the cases are identified, controlled, and isolated. It’s what Singapore, South Korea or Taiwan are doing so well: They very quickly limit people coming in, identify the sick, immediately isolate them, use heavy protective gear to protect their health workers, track all their contacts, quarantine them… This works extremely well when you’re prepared and you do it early on, and don’t need to grind your economy to a halt to make it happen.
I’ve already touted Taiwan’s approach. But China’s is good too. The lengths at which it went to contain the virus are mind-boggling. For example, they had up to 1,800 teams of 5 people each tracking every infected person, everybody they got interacted with, then everybody those people interacted with, and isolating the bunch. That’s how they were able to contain the virus across a billion-people country.
This is not what Western countries have done. And now it’s too late. The recent US announcement that most travel from Europe was banned is a containment measure for a country that has, as of today, 3 times the cases that Hubei had when it shut down, growing exponentially. How can we know if it’s enough? It turns out, we can know by looking at the Wuhan travel ban. | https://tomaspueyo.medium.com/coronavirus-act-today-or-people-will-die-f4d3d9cd99ca | ['Tomas Pueyo'] | 2020-05-28 07:57:30.905000+00:00 | ['Epidemia', 'Health', 'Healthcare', 'Coronavirus', 'Virality'] |
Interesting AI/ML Articles On Medium This Week (Dec 12) | Some adults know Santa Claus isn’t real. But that doesn’t stop deep fake Santa Claus from making an appearance this Christmas. Thomas Smith explores an AI video generation tool that produces deep fake Santas. These synthetically generated Santas can utter words from provided scripts.
Jair Ribeiro visualises a future where his daughters experience the comfort and efficiency of automated driving cars.
Also, If you are a fan of Game Of Thrones, then Sajid Lhessani’s unique take on the association of programming languages and GOT characters is an article you have to read.
These are just examples of the interesting articles I came across this week. Feel free to scroll through my compiled list of AI/ML/DS articles that are sure to provide some form of value to ML practitioners. | https://towardsdatascience.com/interesting-ai-ml-articles-on-medium-this-week-dec-12-59ffa32f1a5f | ['Richmond Alake'] | 2020-12-12 01:04:01.633000+00:00 | ['Machine Learning', 'Artificial Intelligence', 'Technology', 'AI', 'Data Science'] |
‘Animal Kingdom,’ Prince’s Animal Rights Anthem | When regarding the late musician Prince, subjective statements find themselves turning objective. It is simply and undeniably factual that he was a guitar virtuoso, a musical visionary, fearless, pioneering, and massively influential. Also undeniable is how prolific Prince was, with an astonishing thirty-nine studio albums, to say nothing of compilations, live recordings, albums recorded with his bands, and posthumous releases. You might conclude that statistically anyone who creates thirty-nine albums worth of material would surely end up with a song about the plight of animals, because eventually, what else would there be to write about? Prince, of course, had no need for such a theorem: he was a proud animal rights activist and wrote about the subject very much on purpose, for example, in the song “Animal Kingdom” from his 1998 album The Truth — which was, for those counting, merely his twenty first studio album.
“To eat a tomato and then replant it for your nutrition as opposed to killing a cow or a pig for your meal is reducing the amount of suffering in the world. Besides, pigs are too cute to die.”
For the casual fan — which I admit, is me — it would be very easy to miss this song amongst Prince’s dizzying output. But it’s a highly rewarding discovery.
According to interviews, Prince stopped eating red meat in the 1980s — “we don’t have to kill things to survive!” — and then continued to move towards a vegan lifestyle, although he has also claimed to be a vegetarian. “Compassion is an action word with no boundaries,” he said, “It is never wasted. To eat a tomato and then replant it for your nutrition as opposed to killing a cow or a pig for your meal is reducing the amount of suffering in the world. Besides, pigs are too cute to die.”
This idea of compassion and living in harmony with the universe is explored in “Animal Kingdom,” a song that is edifying yet sexy at the same time, a curious but effective mix for getting his point across. His opinions are unambiguous, strident even, however the song is so languid and lushly produced that it’s a pleasure to receive the information.
I saw a friend of mine today, in an ad sayin’ what would do my body good I told him he was wasting time I say If God wanted milk in me The breast I suck would have a line around the hood.
The friend Prince is referring to is director Spike Lee, participating in the 90s celebrity-fronted Got Milk? campaign. This opening feels like pure brazen Prince, but the lyrics continue in an emotive, informative fashion.
“No animal nurses past maturity,” he reminds us, and then, “I don’t eat red meat or white fish, don’t give me no blue cheese — we’re all members of the animal kingdom, leave your brothers and sisters in the sea.” I won’t lie, I don’t often consider the interiority of the clam, but such is the power of Prince’s profound words and delivery that I felt my eyes get a little misty when he sung this line:
What about the clams on the shore? Souls in progress — here comes the fisherman — souls no more.
This song was ahead of its time in many ways — not just in terms of the relevance of its message, as more people continue to reject eating animals. “Animal Kingdom” really sounds like it could have been released in the last year. There’s an airy quality to the production, his voice is extruded through a vocoder, every part of it is dreamy and unhurried — even the slinky guitar riff and bass line — and it’s interspersed with ambient ocean noises. It somehow sounds — and I mean this in a positive way — viral. It could sit side by side with say, “Old Town Road” or “Redbone,” those tracks that become songs of the summer, that become the background of your favourite TikToc videos, that you want to hear over and over again. It just feels so fresh.
Further evidence of the power of Prince — way back in 1998 he knew how to not only preempt the ideas of the future, but also the sound of it. | https://medium.com/tenderlymag/animal-kingdom-prince-s-animal-rights-anthem-eea65d165db2 | ['Laura Vincent'] | 2020-01-10 17:31:01.950000+00:00 | ['Vegan', 'Equality', 'Prince', 'Animal Rights', 'Music'] |
5 Habits That Are Holding You Back From Being the Best Writer You Can Be | 5. Complaining. Period.
Photo by Priscilla Du Preez on Unsplash
“This is unfair.” “How come I haven’t made that much yet?” “Why is everyone else doing better than me?” “How come she gets to do that?” “Why is this platform changing again?”
It’s impossible for people not to complain. We’ve got a lot of crappy feelings inside that are slamming against the cage of our ribs, hoping to escape. But I do know that we can practice becoming aware of when we complain. We have the ability to stop ourselves from looking like further ungrateful bumbling idiots. (No offense. Also, I’m kidding. We’re not idiots. We’re human.)
Complaining only accomplishes one thing: making you feel like crap. Other than that, it doesn’t benefit you. It doesn’t act like a slingshot and fling you closer to your goals.
This journey is unfair. You might as well accept that now because once you do you can ask yourself this question: Am I going to keep complaining or am I going to do something about it?
For example, let’s say a website made a change you don’t like. What can you do? Reach out to them about it. Take action. And if they don’t get back to you? Get over it. Seriously. What are you going to do? Keep complaining? No one cares.
When I find myself feeling envious of someone’s success I tell myself one thing: “If you want those results, then start working as hard as them.” or “If you want to make that much money, stick around as long as them.” Keep working — that’ll get you the results you want.
You can also acknowledge all the ways life is fair to you. You’re not making $1,000 yet, but you earned $100. You don’t have 50 comments, but you have five. You’re doing what you love. You’ve made friends. There’s a lot of greatness to acknowledge. Don’t let your self-pity, anger, or jealousy get in the way of it. Let that gray cloud move along so you can see the sun. | https://medium.com/the-brave-writer/5-habits-that-are-holding-you-back-from-being-the-best-writer-you-can-be-7d33b63142fe | ['Itxy Lopez'] | 2020-11-19 17:01:08.290000+00:00 | ['Creativity', 'Writing Tips', '5 Tips', 'Habits', 'Writing'] |
A Major Instigator of Modern Conflict | When my daughter was in high school, she constantly questioned why it was so important to learn about history. Why did she have to study what happened hundreds or thousands of years ago, and when would she ever need to use any of that knowledge throughout her life?
Although I often wondered the same, my automatic response would almost always be that it was important to know where we came from, and how the world got to be what it is today. And it’s true, we do! But what we choose to do with that information can be a little conflicting.
How much weight should we allow past history to have on shaping the present and the future? I’m not arguing the fact that it’s important to know about our ancestors — what has shaped the world we live in today. However, we need to learn where to draw a very real line between knowing about it and re-living it.
I’m going to start by saying that this is an opinion piece, and should only be taken as such.
History vs. Heritage.
There are many history buffs who feel it’s extremely important to know what happened before us. For example, did Christopher Colombus really discover America? History books say yes, but research tells us that he probably didn’t.
I personally love learning and hearing about things that happened throughout history, not only in my own country and culture but in every country and culture. The good, the bad, and the ugly. And there’s a whole lot of ugly, from every point of view. Humans have a history of doing really horrific things to one another.
That being said, I tend to question a lot of it and not just take everything at face value. History books were written and re-written, translated and updated. As we are mostly all writers here, I’m sure you can attest that most of what we write is tainted by our own often biassed opinions.
How one person perceives an event might not be how the next person sees it. And just like rumours tend to evolve over time, we should probably expect that some of what was written as history may not be exactly as it happened. Just as we should expect that some of what happened may never have been written at all, or that some of what was written may have never happened. The only true experts on history are those who lived it.
Why are so much time and energy spent (wasted?) on worrying about what has already happened? Heritage is one thing — but history is something entirely different, although it’s often mistaken for the same.
Should we not be less concerned with a past that cannot be changed, and more with making sure we don’t repeat it? Should we not be focused more on how we can live our lives to the best of our abilities today, in order to create a beautiful tomorrow?
We are currently writing the history books that will grace library shelves — or internet sites, or whatever technology will have overtaken the world — in another hundred years. What kind of legacy are we prepared to leave behind? What kind of ancestors do we want to portray?
Our heritage tells us where we came from — what our customs were, the kind of lives our ancestors lived. Heritage is where family and cultural traditions come from, as a people. History, on the other hand, recounts events, both traumatic and memorable, such as wars, conflicts, and victories. Do not mistake the two.
The Weight of History
History, because we allow it, has the undeserved power to create chaos by reminding us of all the horrible things that have happened in the past. And let’s face it, the human race has recorded many more horrific events than we have good ones. Many more, I’m sure, have gone unspoken. Unwritten. And even most of those things that we consider to be ‘good’ have emerged out of conflict and war.
Humans are a cruel, self-serving species. We’ve orchestrated horrifying events throughout the past centuries. We’ve gone to war more times than I can count, and continue to do so. We’ve enslaved or eradicated entire groups of people. We’ve traumatized, demoralized, dehumanized, and administered unspeakable torture.
And instead of choosing to heal from these hurts, we hang on for dear life. We feel sorry for ourselves and pick at the wounds, we let it fester. We refuse to let go of the things that were done by our ancestors — and to our ancestor. We cling to it with fierce determination, hell-bent on retribution. Validation and revenge. We rant and scream about hate when we should encourage love.
Who was right? Who was wrong? We endlessly debate this question with no right answer, instead of living in the present to create a peaceful future. Instead of making ‘now’ a good place to be, by our words and actions. We continue to revive and relive history, taking offence in the actions of our predecessors, and ultimately recreating them, taking vengeance on those who look the part. We bring history back to life and take our self-justified revenge on the people of this generation as if they were the ones who personally persecuted us.
I ask you: should we let events that happened hundreds of years ago dictate how we live our lives today?
People. We are not our ancestors. They were not us! Let us love, not hate!
Do we make a child pay for the sins of his father? Or do we teach that child a better way instead?
Live and Learn
To live is to learn. To learn, to live. We can usually learn from our own mistakes, but we should also take notes and learn from the mistakes of those before us. Learn what to do. What not to do. We can see — both first and second hand — by being the product of what was, what needs to change in order for us to ensure a better outcome for what will be.
This Woman’s [Unpopular] Opinion
My thoughts on this may not be shared by many, but it’s my hope that they are at least shared by some. In my mind, the concept is quite simple. Or at least, should be simple.
We are but one race: humankind.
We have but one home: planet earth.
A planet we did not create, therefore, do not own. We have ignorantly chosen, and continue to choose segregation. We have repeatedly chosen to divide. To conquer. To argue about who discovered what. To fight over land that we put our name on, to plant our flag in, but is not ours to fight over.
We mistreat our home, and each other, with disregard, arrogance, hatred, and unspeakable violence.
Where there should be unity, there is division. War, where there should be peace. We judge and hate those who appear different from us when we should accept, love, and embrace the undeniable beauty of diversity and individuality.
History has proven time and again that there are no real winners in war. And yet we choose to continue down the same destructive paths paved by those who came before us. We choose to expand the divide.
Real humanity knows no colour. Knows no language but love. It knows no judgement.
Humanity is inclusive, completely. Regardless of whether you believe in one God, or many. Whether you are far left, or far right. Whether your skin is made of light or dark pigments, or no pigments at all. Whether you love men or women, or both, or neither.
Where history has destroyed, humanity should rebuild.
It is our duty as humans to go forth in unity, with love for all as our one guide.
Because we all bleed red.
And because when you turn out the lights, we all look the same. | https://medium.com/the-partnered-pen/a-major-instigator-of-modern-conflict-705086443f8a | ['Edie Tuck'] | 2019-10-24 22:26:29.714000+00:00 | ['Society', 'Life', 'Conflict', 'History', 'Change'] |
Organizing as an Indie | Shaping an Idea
I started off using a mind-mapping tool as everyone thinks of them. That starting bubble, just one or two words that sum up the app. It usually gets changed to the app name later, but for now, you need that title to identify this mind map. A few I’ve used for apps are Countdown, Timer, Shopping List, and Barcodes. Even though you don’t know what apps they became, you know a little of what they are for already.
From that initial bubble, it’s easy to just start adding every random thought that comes into your head that you want to capture, which mind-mapping tools are designed to handle well. With that said, I do like to add a very minimal starting structure. I add three nodes immediately: Purpose, Technical, and Design. These will later be split into more nodes, but at this point, my mind is flitting between these aspects, so I need to group things very loosely.
Purpose
This is where the idea of the app is formed. They are either statements or multiple nodes in a question-and-answer format. That way, as I progress, I can add more answers. None are right — they are all options at this stage. I also chain nodes to back up a statement, which can often lead to questioning that statement later. Nodes here will often become technical items or user stories that you can either move from purpose or link to, depending on whether the idea is fully formed.
Technical
As you start defining the purpose of your app and sometimes the design, you’ll start running into things you’ve never done technically. Add them here. You’re building your research list for later and getting that worry about how hard something is out of your head.
Design
Like the technical node, this is a holding area to quickly get thoughts out of your head, allowing you to revisit them and probably iterate on your previous thoughts. Design, for me, covers everything on how I want to present the app.
I always start with Name and Icon, which are usually the last things to get finalized, but as the app progresses, new ideas keep occurring.
I’ll also start capturing thoughts on how I want the app to look, which is usually heavily influenced by the latest trends and anything I haven’t done before, so it will be nav bars, tab views, single screen. It inevitably won’t stick as the purpose and technical aspects evolve, but again, the idea is to stop dwelling on this irrelevant thought now and comforting yourself that it won’t be forgotten.
The start of an idea
After a few minutes, you’ll get a mind map you can start fleshing out with more and more detail until you are ready to create actionable items:
Photo by the author.
Every mind-mapping tool gives options to style things as much as you want, changing node shapes, colors, adding images. If it helps to add visual clues to where your thoughts are going, do so. I tend to stick to the default formatting applied. For some really big topics, I will add an icon to make it easy to identify later. | https://medium.com/better-programming/organizing-yourself-as-an-indie-developer-a7cabdcafd44 | ['Andrew Jackson'] | 2020-10-15 16:25:03.718000+00:00 | ['Software Development', 'Startup', 'Indy', 'Productivity', 'Programming'] |
All you need is mobx-react-lite | What about bundle size?
Using lightweight packages alternatives is a great way to reduce the final bundle size. And we can do that with many packages. Remember using Moment.js? I don’t recall using it for a while because it has a way bigger bundle size that the alternative Date-fns package. Even tho the Moment still has twice more downloads and stars.
Mobx-react-lite is a lightweight binding to glue Mobx stores and functional React components. And the size of it is smaller, but maybe not as much as you would expect. Nevertheless — this is all we need.
Let’s get started
We will need a React project setup and two dependencies to get started:
yarn add mobx mobx-react-lite OR npm install mobx mobx-react-lite
For a simple example, we can create a Counter Store with some actions and values. I’m using Typescript with the feature enabled to support decorators syntax, but it does not matter if you are using decorators or functions for our case.
In order to access the store from the component we will need to create the instance of the store and, of course, share it in some way with components. React Context is a quite good fit for this task and we can leverage it for our needs. Let’s create a stores.ts file with the store instances and Context wrapper.
Good. Now we have a stores variable to which we can save instances of the Mobx stores. We freeze the object in order to avoid any unexpected changes in it. But, of course, this is an optional step.
We created a React Context based on the store’s variables, and also created a Stores Provider component, we will use it shortly.
Now, let’s update the root index.tsx file with a Context Provider wrapper. Follow this code snippet.
Very well. At this point, we have a place, where we keep our stores. We also have a way to share the stores with the components, but not completely. To access that context we have to create two custom and quite handy hooks. One will return all stores, another — specific store of preference.
Alright, now we have it. See that weird type definition for the useStore hook? It would give us proper types for the passed store key.
<T extends keyof typeof stores>
(store: T): typeof stores[T]
We will only accept store variable type if it’s one of the keys of the stores object. So, in our case, it will only accept a counterStore string and will return the corresponding type of the given store. Nice, isn’t it?
Ok, let’s finally access the store, its methods, and properties from the actual component. To do that we have to modify App.tsx file with the custom hooks and Mobx Observer wrapper.
We access the counter store with it’s key and get the store in return. Also, we have to wrap the component into the observer function to allow the component to listen for the store changes. But still, we do not destruct stores.
const counterStore = useStore("counterStore");
Counter App demo
The app is working as expected, cool! Let’s see the TypeScript hints that we got from this setup and the ways it will cover our back from doing wrong things.
The first thing to mention is the code completion feature. When we will add the useStore hook and start passing a string there as an argument — a key hint will be shown. We also will not be able to pass non-existing store keys. Nice!
TypeScript hint
TypeScript warning
This also works for the case when we have multiple stores as well. We can access them with a separate useStore hook or with a useStores hook as well. Check this out.
TypeScript hint for multiple options
Testing
Sure thing we need to test this. In this article, we won’t make tests for the store itself, since this is a topic of a different nature.
I find it easy enough to use Jest alongside with React Testing Library. So, let’s add the necessary dependencies.
yarn add @testing-library/react-hooks react-test-renderer -D OR npm install @testing-library/react-hooks react-test-renderer --save-dev
Cool! Now we can start testing our hooks file. Nothing too fancy here, but still necessary.
Hooks file tests results
How about component tests?
To do that we will need a few more dependencies. To test the components and to perform user events.
yarn add @testing-library/react @testing-library/user-event -D OR npm install @testing -library/react @testing-library/user-event --save-dev
Good! Let’s test the components now. We can mock the useStore hook to always return a specific store using Jest. And, we can be type-safe with a few extra lines of code. For every test we want the hook to return a new store. But, for one of the tests, we will change that slightly and replace the initial value of the counter. Check this code snippet.
App file tests results
Quite simple, isn’t it? Yep! And we got a green light as well!
Summary
Mobx-react-lite is actually all I need in my personal projects. Would this be your choice of favor as well? Let me know in the comments below 😉.
The entire project is available on the GitHub link.
Thanks for reading this topic! | https://medium.com/javascript-in-plain-english/all-you-need-is-mobx-react-lite-47ba0e95e9c8 | ['Bogdan Birdie'] | 2020-09-24 07:16:02.631000+00:00 | ['JavaScript', 'Mobx', 'Web Development', 'Typescript', 'React'] |
Why Risk Innovation is critical to the futures we aspire to | Why Risk Innovation is critical to the futures we aspire to
If there’s one thing we cannot escape as we look to the future, it’s risk.
An entrepreneur uses the risk innovation planner to navigate orphan risks
Risk is inevitable in a universe where past “causes” connect in complex and often unpredictable ways with future “effects,” and every action we take leads to reactions that are detrimental to someone in some way.
And just to make things harder, the sheer complexity, the interconnectedness, and the technological capabilities of today’s society, vastly amplify the uncertainty surrounding present-day actions and future consequences.
As a result, if we’re to thrive in the future, we need to get a better handle on risk and how we think about it. The consequences of not doing so, ironically, are that our outmoded ideas about risk actually become a risk in themselves and threaten the future we aspire to.
Thinking Differently About Risk
This need to think differently about risk underpins the Risk Innovation Nexus at ASU — an initiative committed to connecting ethical and responsible innovation with value growth.
The seeds of the ASU Risk Innovation Nexus were planted several years ago, while I was working with entrepreneurial students at the University of Michigan. Faced with a bewilderingly complex landscape around emerging and hard to grapple with risks — many of them social and political in nature — it was clear that entrepreneurially minded creators of the future needed a completely new risk toolkit if they were to not just succeed, but succeed in a way that that was a win-win for them and society more broadly.
However, it wasn’t until 2016 that the ASU Idea Enterprise provided the opportunity to transform these seeds into a flourishing enterprise.
With the encouragement of the Idea Enterprise and the support of Entrepreneurship + Innovation at ASU, we launched the Risk Innovation Accelerator in 2017 with the aim of providing time and resource-constrained entrepreneurs and others with a unique toolkit for navigating what we came to call ”orphan risks” — those hard to quantify and easy to ignore risks that nevertheless have a habit of coming back to bite.
Orphan risks making up the Risk Innovation Nexus risk landscape
Working at the Nexus of Entrepreneurship and Social Value Creation
In 2019 we changed our name to the Risk Innovation Nexus, reflecting the evolving nature of our approaches that empower anyone working at the nexus of entrepreneurship and social value creation in a rapidly changing world. And with it, we began to see those initial seeds transformed into a powerful array of tools and resources that uniquely support entrepreneurial success.
This phase of the Nexus is coming to an end as our initial seed funding wraps up. The good news though is that the tools and resources our fantastic team has produced will continue to be freely available to anyone looking to succeed in today’s complex world.
Of course I may be a little biased here as the Nexus is near and dear to my heart, but working in the thick of technology innovation within an increasingly complex social, environmental and geopolitical landscape, I cannot emphasize enough how important these tools and resources are.
One of the traits of complex, non-linear systems is that they look as if they are thriving, until seemingly-insignificant and often overlooked events lead catastrophic failures. And an important part of building resilience is having the ability to identify and navigate around risks that are hard to quantify, and because of this are often discounted, and yet can mean the difference between success and failure.
Developing a Risk Innovation Mindset
This is where a risk innovation mindset is critical–not just for entrepreneurs, but for anyone striving to build a better future. And it’s also why it’s central to the work of a college that is founded on opening up pathways to better futures.
As we wrap up this phase of the Nexus, please do check out the resources below: | https://medium.com/edge-of-innovation/why-risk-innovation-is-critical-to-the-futures-we-aspire-to-a4ec96ef7516 | ['Andrew Maynard'] | 2020-11-05 15:39:47.498000+00:00 | ['Innovation', 'Entrepreneurship', 'Risk', 'Future', 'Responsible Innovation'] |
A Better Note-Taking System for Your Scattered Brain | A Better Note-Taking System for Your Scattered Brain
‘Four Mind Banks’ can help you process information in a simple, engaging way
Photo: David Travis via Unsplash
I recently started a new job, and I’m in that phase where I’m constantly bombarded with new and unfamiliar concepts, from company vocabulary to industry know-how. The learning curve is steep. At every meeting, I take furious notes, trying to soak in as much information as possible.
For a while, I tried the bullet journal system of note-taking, in which you use icons to label the nature of every single bullet point you write down. While it’s a creative way to mark your thoughts, I found that it becomes difficult to quickly label all the different patterns when you’re faced with heaps of new information. People talk fast. Slides move from one to the next at lightning speed. You don’t have time for labels — you’re simply trying to keep up.
During meetings, I realized that four things were happening in my mind:
I was gaining new information. I was coming across things I wanted to gain further clarity or dig deeper on. I was coming up with ideas and insights. I was having strong feelings about certain issues.
And so I came up with a framework to capture these different notes and thoughts in a way that allows me to easily return to them later on. I call it the Four Mind Banks system.
How it works: Create four “mind banks” in your notes. You can either divide a sheet of paper into four quadrants or divide your notebook into four sections. (If you go with the latter, it helps to add tabs to your notebook so you can swiftly switch from section to section.) Every note you take goes into one of the banks:
🤓 The minutes bank
This is where you put important discussion points, new concepts, factual information, quotes, and key takeaways.
❓The question bank
This is for the things you either don’t understand or want to learn more about. If there’s a Q&A portion of the meeting, you can refer to this bank. If not, you can dive deeper into the questions on your own time.
💡The idea bank
This is for those lightbulb moments: Maybe you have an idea for a new project or a thought about how a certain process can be streamlined. It’s important that you don’t let these ideas escape you, no matter how small or raw they might be.
😳 The reaction bank
This is for emotions and reactions. We are human beings, not robots that automatically absorb any information presented to us. Feeling is part of the processing. Our reactions and triggers help us to make sense of information, form opinions and convictions, and add value to the discussion.
The notes we take aren’t just bits of new information. They’re breeding grounds for curiosity, creativity, and natural human responses. This system has helped me to process all the information I’m receiving in my meetings in a more effective and engaging way. My brain loves compartmentalizing things.
You can use this system not just with meetings, but in any area of work or life. Try it for yourself. It’s like a filing cabinet for your brain — one that stores what you need for whenever you need it. | https://forge.medium.com/a-better-note-taking-system-for-your-scattered-brain-a65a398bd1f4 | ['Ria Tagulinao'] | 2020-10-14 15:26:57.483000+00:00 | ['Notes', 'Productivity', 'Brain', 'Work', 'Lifestyle'] |
Your Code Should Read Like a Book | Your Code Should Read Like a Book
It makes life easier for everyone involved
Photo by Fabian Grohs on Unsplash
There’s a pandemic among programmers. Long functions, broad and nondescriptive names for functions, classes, and variable names, overly commented code, disorganized structure, and a lack of overall streamlined flow.
It’s much too often that I take a peek at someone else’s working code just to notice that I have to exert a strenuous amount of effort just to understand what it does in the first place.
I have to try my best to reason about ambiguous variable names such as i, k, num, counter, etc. What type of num are we representing, and what is the purpose of the operations that surround it? What is the purpose of the counter? What is it tracking? Why is it there?
I have to constantly jump all over the class to see how each function builds on top of the other functions around it, just to realize that the names of each function don’t really tell me anything about what the function does.
I’d even have to sometimes read paragraphs of comments that explain the purpose of what a function might do, but still, I shouldn’t have to be reading an essay to simply understand what a function does. I should be able to reason about this simply by taking a quick glance at the function.
Your code should read like a book. Just how a book is structured through paragraphs and chapters that follow a descriptive story that flows in a streamlined and progressive fashion, your code should be structured and designed in a way that I can enter into a class and be able to understand its purpose within moments of engagement. Please don’t make any developer, including yourself, who is looking at your code have to embody Sherlock Holmes in order to deduce the purpose and meaning behind what you wrote.
What exactly should you do? | https://medium.com/better-programming/your-code-should-read-like-a-book-873b27f71fe5 | ['Zachary Minott'] | 2020-08-07 17:50:41.776000+00:00 | ['Programming', 'Software Development', 'Clean Code', 'Software Engineering', 'Startup'] |
Where Did Tom, the Founder of Myspace, Bizarrely Vanish To? | Where Did Tom, the Founder of Myspace, Bizarrely Vanish To?
This is what happens when the concept of money is removed from your life.
Image Credit: Pedestrian/gettyimages
“Myspace changed my life,” said no one.
Well, it changed mine. I was an unknown musician looking for an audience. I set up a Myspace account.
My first friend was this weird guy called Tom. Tom looked freaking happy and he was the co-founder of the site. He looked like someone that could actually be my friend. I was a Myspace prostitute. I made friends with everybody. Myspace was where I published the remixes I created and played in nightclubs as a DJ.
Unfortunately, Myspace didn’t make me a successful musician. I didn’t go viral with my Fleetwood Mac remix while holding a bottle of cranberry juice.
Myspace was fun though. It’s where I met one of my best friends. He randomly messaged me and asked to talk about my music. I met up with him, and his record label ended up publishing all of my electronic dance tracks to sites like Beatport. Without Myspace I would never have become a musician signed to two record labels.
The experience on Myspace later became my foundation and apprenticeship for how to write on the internet.
The online assistance from Myspace wasn’t enough. I didn’t know it at the time, but I was suffering from extreme mental illness. Practically speaking, this meant when I went to go on stage and play my set I’d feel physically sick.
It took me hours to prepare for the nerve-racking battle that I faced every night. I loved playing to an audience. What made no sense was my body’s response to my hobby. After a while the stress of mental illness became too much. I gave up DJing and stopped using Myspace.
It’s been years since my experience with Myspace, although my account is still very much alive (see here for a laugh).
Screenshot by me (2020). From Hollywood celebs, to nightclubs, to mixtape cds, to strange long hair…haha
The other day I thought to myself where the heck did Tom from Myspace end up? The answer surprised me, given he is now 50, which is hard to believe. You might be curious too and there’s an awesome lesson in it for you.
The historical importance of Myspace
Myspace was significant because it accidentally paved the way for creative people to release their work into the world without owning a website. Tom made this happen by mistake and it was a happy accident.
Myspace created the social media category of apps. Without Myspace we may never of had Facebook, LinkedIn, Twitter or Instagram. Tom started Myspace in 2003 with Chris DeWolfe.
Myspace got eaten for breakfast by Facebook in 2008.
The company eventually pivoted to serving musicians solely. They lost their identity and their mojo. Nobody knew what Myspace was anymore. Now, only people who want to walk through a time warp (like me) visit the site.
Myspace helped the internet unleash its creativity, and that’s historically important regardless of how things ended up.
This is what Myspace Tom is doing now.
Myspace was sold in 2005 for $580 million.
Tom walked away from the experiment a rich human. He attempted to stay on for a few years at the company, but became frustrated with endless meetings and the inability for anybody to make a decision.
He dabbled with a few adviser roles. Then, in 2009 he retired. Since then most people have no idea what happened to him. Here’s what he said about the concept of retirement:
I’ll never say ‘never’ because, more than anything, I like the idea that anything can happen. I don’t know exactly where my life will lead. Adventure and the unknown has always been appealing to me.
Tom was going to travel the world and do nothing. In 2011 Tom visited the Burning Man festival and became inspired by photography, thanks to his friend Troy Ratcliff.
“I’m not necessarily trying to represent nature exactly. I’m trying to make something beautiful like a painter would,” says Tom. Now Tom travels the world as a photographer. He doesn’t make a dollar from his art and that’s intentional. All of his photographs can be found on Instagram.
“I haven’t wanted to take commissions or sell my photos, or do anything commercial with it — that would just feel like work, which I don’t want to do.”
Tom lives an odd life.
It reminds me of the Humans of New York founder, Brandon Stanton. Brandon left behind a high-profile job in finance to take photos of everyday people in the street.
He said in an interview “I’d go out some days and ten people in a row would make me feel like I’m some sort of freak. ‘No you can’t take my photo — get out of here!’ There were days when I couldn’t do it anymore and would go home and lay in bed.”
Brandon burst into tears after sharing that experience. The rejection was overwhelming. What saved him was this: The act of doing his passion rather than thinking about it.
Doing creative work for the sake of it is a deeply fulfilling and odd experience. It’s worth you experimenting with like Tom and Brandon have.
What you can learn from Myspace Tom
Okay, so you may not be retiring on hundreds of millions of dollars. What Tom can teach you about life through his experience is still powerful.
Time is worth more than money.
“I’ll pay a lot to not waste time. Time is the most important thing to me — how can you do all the things you want to do with such limited time. … I’m hoping the science of life extension makes progress.”
The purpose of retirement is not to quit work. It’s to quit the type of work you have to do for money, so you can do whatever work you want and not need to stress about how much it pays.
Retire from work you do for money as soon as you can.
Buy back your time. Buying stuff forces you to work longer for money.
Dumb meetings and indecision aren’t worth it.
It forced Tom to walk away from corporate life. Tom likes to build stuff and explore his creative passions. It’s hard to make progress when you’ve got a corporate giant molding you for their exploitation and benefit.
Real passion keeps you going.
You might think having loads of money and retiring like Tom is a dream. The problem with retirement and loads of money is it gets boring.
$580 million will make you happy for a few months, not a lifetime.
Tom figured this out the hard way. He says his passion for photography keeps him traveling. I reckon that’s a lie. His passion for photography keeps him alive and away from doing enormous amounts of coke and gambling at casinos every day.
When money is taken care of, work changes its meaning. If you’re not intentional about that meaning, then you’ll end up having a new meaning written for you which may not be consistent with living a good life. | https://medium.com/the-ascent/where-did-tom-the-founder-of-myspace-bizarrely-vanish-to-a4ddb3ef50d9 | ['Tim Denning'] | 2020-12-14 16:00:09.551000+00:00 | ['Creativity', 'Mental Health', 'Social Media', 'Money', 'Work'] |
Whatever Happened to the Heroes? Punk, Trotsky, Che Chic and the consumption of revolutionary icons | Wandering down steaming ramen shopping alleys from Tokyo’s Koenji to Ueno in the mid-aughts, I was overcome by the ubiquity of Che Guevara’s image on t-shirts in cheap military gear and punk shops. In the suburbs of Saitama, his likeness also punctuated the crowded roads lined by Marui and Seibu department stores. The irony of Marxist iconography being commodified is well known, but I couldn’t help feel perplexed with Che’s presence in a culture more conformist than my ganga-infused, DIY, punk East Vancouver home city where Che shirts seemed a right of passage, once upon a time. This is not to say the image of Che belongs any more in Vancouver. In fact, the appropriateness of using his image to signify revolution at all should be called into question given his thirst for murder and his homophobia. But how does the imported icon of Che Guevara relate to the logo worship of Kitty-chan and brand fetishism of Louis Vuitton in Japan? Especially with emerging trend of uniformity of no logo in brands like Muji and Uniclo. In my hometown, I have always wondered why and how icons of revolution project the views of wearers. Is it earnest social consciousness with awareness of the history behind the image? Irony? Naive rebelliousness? Further, why do we need to import our heroes and do those heroes signify truly subversive revolution?
The Stranglers song “No More Heroes” mourns the lack of sufficient revolutionary representatives by asking “whatever happened to Leon Trotsky…” a Marxist ledgend listed among several famous figures such as Lenin and Shakespeare. The 1977 punk song, as well as the punk movement, seemed to sense an absence of contemporary examples as it sought to cleave itself from the mainstream. Indeed, of cultural and ideological movements such as Literature, Trotsky argues continutiy of literary expression is dialectical and a series of reactions to and from which it is trying to break. The foundation of Punk was a break from the reliance on old, conservative forms that were less relevant to an increasingly restless urban culture. If one were to align punk with Trotsky’s idealized proletariat, the revolutionary individual is one who changes culture and history by seizing and modifying it. But wearing a mass-produced Che shirt feebly hints at the wearer’s rebelliousness. Even worn in sincerity, the ubiquity of the image alone has deadened the meaning. In most cases, the emergence of what Newsweek called “Che Chic” seems a non-revolutionary act of consumerism.
“No More Hereos” cites other famous figures such as Elmyr de Hory, famous for forging great paintings and it seems ironic that the Stranglers exalt a copyist, but I believe it references de Hory’s ability to master the art of copying and undermine the legitimacy of the original paintings. Furthermore, the song “No More Heroes” itself became embattled in copyright litigation a few decades later against Elastica’s too-familiar sounding “Waking up” echoing the tenous legitimacy of original, revolutionary art.
The key point of contention is whether or not the wearer of any pop or cult image is fully aware of the history of the signs they use. In the postmodern, capitalist exchange of icons and logos, the individual is too often worn by the logo. (I marvel, for instance at the prevalence of Disney paraphernalia and its cult of innocence in Japan, despite the company’s historical use of characters as Japanese stereotypes in anti-Japanese WWII propaganda). One can be a chameleon without much accountability to the idea from which the image or cultural use emerged. This is as potentially liberating, as it is a meaningless repetition of mass culture. The rift between images and their origins allows us to use them in a way that can potentially challenge long-stale stereotypes or challenge rigid meaning to make it dialectical. It is not a given that the image of Che is one we should revere, given the accounts of his less-celebrated brutality.
My excursions to Tokyo’s goth Mecca, Harajuku as both spectator and spectacle confirms that repetition of subculture can turn into a completely different expression from some of the same inspiration. A subculture like Goth in Japan is multiply-removed from one of its iterations via late 70s punk in the UK, yet is uniquely expressive of youth culture in its colourful Japanese interpretation, which itself has now been (mis)appropriated by North American pop idols.
But does Guevara, transfigured to a silk-screened face, long-since separated from the contested history of the “hero” himself, a hint of global consciousness? The rash of Che paraphernalia became popular in the 1960's and more recently spawned by the popular film The Motorcycle Diaries. Che Chic does not seem to capture the revolutionary spirit it had in the past because his image has been generally resurrected through consumerism and fashion, rather than ideological means. He has been donned by everyone from celebrities to left-wing college idealists. Is it possible to be aware of the irony, dismissing the claim that image never had authentic meaning? I am aware of my own hypocrisy here purchasing the 150th Anniversary Communist Manifesto from a huge, Canadian retailer Chapters, instead of my local, non-profit, socialist bookstore that had a cheeky sign at one point to liberate any books they did not have in stock at one of the bookstore giants. Yet, I have also delighted in buying American soda with Che’s image on the bottle and own a tin Lenin lunchbox (barcode and all) as a playful comment on the exchange between communist ideology and capitalist reality. How can one be ironic or visibly expressive as a means to counter the mass replication and homogeneity of culture?
The last few decades has brough more playful incarnations of Che, allowing for the questioning of his image and legacy. Challenging monoculture and heternormativity, Comedian Margaret Cho modeled her likeness after Che in her one-woman show Revolution, using Guevara’s icon as a new means to express multiple cultural revolutions. Cho’s appropriation may be the most subversive because the parody of Cho wearing Che calls attention to the lack of representation of women and people of colour among revolutionary icons. The only female icon on t-shirts I can think of is Rosie the Riveter, who is not only fictional, but her edginess has been lost in a deluge of blasé, retro imagery on mugs and magnets aimed at women including “wine mom”. At least more humorous play with Che’s image recently includes drag, artisitc reinterpretations and commingling with other political heroes. For instance, Obama wearing a Che shirt wearing an Obama shirt hyperbolizes casual use of political iconography including Obama’s 2008 Hope poster in an endless play of signifiers. While a conscious play with Che’s symbolic meaning gives a glimmer of hope, I question how the image of revolution is being sold or misused as part of the mass culture of the individual. Revolution, transgression and anti-conformity can all be worn, but do they challenge or repeat? In a tacit responsibility for the individual to be a wearer and a thinker. We just may never know which it is until we open a dialogue about it. | https://jessicaleemcmillan.medium.com/whatever-happened-to-the-heroes-ebc3351584b3 | ['Jessica Lee Mcmillan'] | 2020-04-09 01:51:13.976000+00:00 | ['Tokyo', 'Nonfiction', 'Revolution', 'Che Guevara', 'Music'] |
Blockchain and Artificial Intelligence | It is always exciting to keep an eye on the new and cutting edge technology that is shaping the world that we live in. What’s even better is when two of these emerging technologies are combined. Today we want to look at how blockchain technology is being combined with Artificial Intelligence. We will outline some of the projects leveraging these technologies in the crypto space.
Let’s start by briefly defining these two technologies.
What is Blockchain?
We did an entire article recently explaining Blockchain technology. For the purpose of keeping it simple, Blockchain can be defined as follows:
A blockchain is an incorruptible and decentralised digital ledger of transactions that can be programmed to record not just financial transactions but virtually anything of value.
As mentioned above, Blockchain ledgers work through decentralisation. This means that there is no one central controller of the ledger. It is maintained and updated by the network. In the case of Bitcoin, the network is made up of thousands of devices all over the world.
What is Artificial Intelligence?
Artificial intelligence or AI , is an area of computing all around the creation of intelligent machines. Artificial Intelligence has actually been studied since the 1950’s when there was the emergence of neural networks. This was followed by machine learning techniques in the 1980’s.
Today we see deep learning pushing a new boom in the Artificial Intelligence space. While there are many applications of AI for enterprise and business purposes, it is slowly engulfing much of the technology we use on a daily basis ourselves.
Ride-sharing apps like Uber and Lyft utilise machine learning techniques to predict the price of your ride and minimise wait times. Your email service provider likely uses artificial intelligence to filter spam messages coming into your inbox. Google maps uses anonymised data from smartphones to update traffic statistics in real time. Plagiarism checkers use AI to scan for plagiarised content.
Facebook, Snapchat and instagram all use AI for facial recognition and your favourite filters. So Artificial Intelligence is all around us. We are interacting with it on a daily basis, even though we may not even realise it. The AI Robots we see in the movies is but one form of AI we should concern ourselves with. The ways in which neural networks, machine learning and deep learning can be applied in our lives today can make our world much easier to manoeuvre. There are many projects in the cryptocurrency space trying to make this happen today.
So what happens when Blockchain and AI are combined?
There are some very ambitious projects in the cryptocurrency space seeking to make the best of these two technologies.
Matrix AI Network
Matrix AI network appears a very ambitious project on the surface. Videos on their website paint the picture of an Artificial Intelligence assistant helping us navigate nearly every facet of our daily lives. They describe themselves as an open source public intelligent Blockchain platform. They want to help bring old technology into the new world and propose to do this by utilising easily programmable smart contracts on their platform.
The area where they seem to merge Artificial Intelligence into the project is through Deep Learning based code generation for smart contracts. They recognise that programming smart contracts on the likes of Ethereum requires having to read and write code. Matrix aims to leverage AI to generate smart contracts for users. Users will only need to insert basic information like input, output, and transaction conditions. Being able to write smart contracts without having a coding background will allow a much larger pool of people to use their platform.
Also outlined in their white-paper is an interesting AI-enabled security and enhancement mechanism. Matrix’s built in compiler scans the smart contract code in order to try and find vulnerabilities and execution problems. It even carries out rule based checking and code revision. On top of all this they have a “deep learning based framework to discover the hidden intention of smart contracts and detect complex patterns of security vulnerabilities.”
Matrix’s blockchain, coupled with the above implementations means their blockchain will learn and evolve over time. Using AI to constantly search for vulnerabilities means that it will be able to serve up better and more refined smart contract code for users over time.
Potential Partners…
There is also much speculation that Matrix is working closely with the Chinese government. The Chinese government are working on some huge initiatives. The resurrection of the Silk Road connecting China back across Asia to Europe is one example. Could Matrix AI have some partnerships lined up on some government ventures? It is all speculation for now.
Nonetheless, Matrix AI network is a very interesting project and its implementation of AI seems very practical on the surface. If their machine learning algorithms can serve up easy to programme smart contracts this is sure to make Matrix AI network one to watch.
DeepBrain Chain
Deepbrain chain (DBC) is another initiative in the crypto space leveraging AI technology. They describe themselves as an Artificial Intelligence computing platform driven by Blockchain. In its whitepaper, DBC outlines a number of advantages of its platform. They focus on serving AI companies and already integrate deep learning frameworks such as TensorFlow (Google), Caffe (Facebook) and CNTK (Microsoft).
While Matirix AI network runs on its own native blockchain, DeepBrain chain will release their DBC coin on NEO. They will also run the DBC Coin issuing algorithm on NEO’s smart contracts.
It appears that DeepBrain Chain want to position themselves as the go to platform for AI companies. According to their whitepaper many of their benefits will stem from AI companies accessing DBC’s neural network computing power. By pooling together computing power from all over the world they say they can reduce the amount of money AI companies spend on computing power by up to 70%.
They are not simply providing a decentralised supply of computing power though. DBC are also seeking to create an AI data trading platform, an AI algorithm trading platform, an AI model trading platform and much more.
Where does this all lead?
With the examples above, its clear that there could be some very interesting use cases for the merging of Blockchain and Artificial Intelligence. Both projects are creating initiatives that result in a form of decentralised intelligence. Leveraging elements of AI like machine learning and neural networks means that these blockchains can become more efficient and evolve over time.
Add to this the ability for them to assist users in exploring and creating smart contracts and applications and it makes for a very interesting future. It is clear that AI can therefore aid us in not only creating a better user experience, but more efficient outputs in terms decision making and business performance. | https://medium.com/cryptosuss/blockchain-and-artificial-intelligence-232c4821885e | ['Crypto Suss'] | 2018-09-17 17:30:43.910000+00:00 | ['Artificial Intelligence', 'Blockchain', 'Cryptocurrency', 'AI', 'Bitcoin'] |
Is Angular Still Alive? | Let the Stats Speak
Stack Overflow Survey
In this survey by Stack Overflow to find what the most loved, dreaded, and wanted web framework is, React and Vue placed first and second, respectively, in both the Loved and Wanted sections. Meanwhile, Angular placed third. As I remember it, Angular had a lead on React in those categories in 2018.
NPM trends
The NPM trends graph above shows us the number of downloads of each framework overs a period of time. The screenshot shows the stats over the past six months, and we can see that React clearly holds the lead with almost 9 million downloads. Vue and Angular are in a tight contest for second place.
Another feature in NPM trends is that it shows the data from GitHub as well. In the screenshot below, you can see the number of forks, stars, and issues of each framework:
These stats again emphasize Angular’s loss of users. Angular only has 67,000+ stars, while both Vue and React are well ahead with 158,000+ and 175,000+ stars in their GitHub repos.
State of JavaScript
The 2019 State of JavaScript includes another report generation platform on JavaScript, and you can find various kinds of comparisons there. The figure below shows the responses of the users, whether they will use it again or not, whether they have heard of the technology, etc.
As we can see, the highest number of users are likely to use React and Vue again rather than Angular. Also, the number of users who voted “I’ve used it before, and would NOT use it again” is higher for Angular than the other two. This means Angular is losing its users rapidly. | https://medium.com/better-programming/is-angular-still-alive-4977515f4de1 | ['Chameera Dulanga'] | 2020-11-19 14:22:02.611000+00:00 | ['Programming', 'Angular', 'React', 'Vuejs', 'JavaScript'] |
Why (and when) you should use Kubernetes | Kubernetes is a powerful container management tool that automates the deployment and management of containers. Kubernetes (k8’s) is the next big wave in cloud computing and it’s easy to see why as businesses migrate their infrastructure and architecture to reflect a cloud-native, data-driven era.
Getting started with Kubernetes? Try out the Practical Guide to Kubernetes and start running production grade clusters.
Outlined in this post are some of the top reasons why you should use Kubernetes and when you should/shouldn’t use it.
Container orchestration
Containers are great. They provide you with an easy way to package and deploy services, allow for process isolation, immutability, efficient resource utilization, and are lightweight in creation.
But when it comes to actually running containers in production, you can end up with dozens, even thousands of containers over time. These containers need to be deployed, managed, and connected and updated; if you were to do this manually, you’d need an entire team dedicated to this.
It’s not enough to run containers; you need to be able to:
Integrate and orchestrate these modular parts
Scale up and scale down based on the demand
Make them fault tolerant
Provide communication across a cluster
You might ask: aren’t containers supposed to do all that? The answer is that containers are only a low-level piece of the puzzle. The real benefits are obtained with tools that sit on top of containers — like Kubernetes. These tools are today known as container schedulers.
Great for multi-cloud adoption
With many of today’s businesses gearing towards microservice architecture, it’s no surprise that containers and the tools used to manage them have become so popular. Microservice architecture makes it easy to split your application into smaller components with containers that can then be run on different cloud environments, giving you the option to choose the best host for your needs. What’s great about Kubernetes is that it’s built to be used anywhere so you can deploy to public/private/hybrid clouds, enabling you to reach users where they’re at, with greater availability and security. You can see how Kubernetes can help you avoid potential hazards with “vendor lock-in”.
Deploy and update applications at scale for faster time-to-market
Kubernetes allows teams to keep pace with the requirements of modern software development. Without Kubernetes, large teams would have to manually script their own deployment workflows. Containers, combined with an orchestration tool, provide management of machines and services for you — improving the reliability of your application while reducing the amount of time and resources spent on DevOps.
Kubernetes has some great features that allow you to deploy applications faster with scalability in mind:
Horizontal infrastructure scaling: New servers can be added or removed easily.
Auto-scaling: Automatically change the number of running containers, based on CPU utilization or other application-provided metrics.
Manual scaling: Manually scale the number of running containers through a command or the interface.
Replication controller: The replication controller makes sure your cluster has an equal amount of pods running. If there are too many pods, the replication controller terminates the extra pods. If there are too few, it starts more pods.
Health checks and self-healing: Kubernetes can check the health of nodes and containers ensuring your application doesn’t run into any failures. Kubernetes also offers self-healing and auto-replacement so you don’t need to worry about if a container or pod fails.
Traffic routing and load balancing: Traffic routing sends requests to the appropriate containers. Kubernetes also comes with built-in load balancers so you can balance resources in order to respond to outages or periods of high traffic.
Automated rollouts and rollbacks: Kubernetes handles rollouts for new versions or updates without downtime while monitoring the containers’ health. In case the rollout doesn’t go well, it automatically rolls back.
Canary Deployments: Canary deployments enable you to test the new deployment in production in parallel with the previous version.
“Before Kubernetes, our infrastructure was so antiquated it was taking us more than six months to deploy a new microservice. Today, a new microservice takes less than five days to deploy. And we’re working on getting it to an hour.” — Box
Better management of your applications
Containers allow applications to be broken down into smaller parts which can then be managed through an orchestration tool like Kubernetes. This makes it easy to manage codebases and test specific inputs and outputs.
As mentioned earlier, Kubernetes has built-in features like self-healing and automated rollouts/rollbacks, effectively managing the containers for you.
To go even further, Kubernetes allows for declarative expressions of the desired state as opposed to an execution of a deployment script, meaning that a scheduler can monitor a cluster and perform actions whenever the actual state does not match the desired. You can think of schedulers as operators who are continually monitoring the system and fixing discrepancies between the desired and actual state.
Overview/additional benefits
You can use it to deploy your services, to roll out new releases without downtime, and to scale (or de-scale) those services.
It is portable.
It can run on a public or private cloud.
It can run on-premise or in a hybrid environment.
You can move a Kubernetes cluster from one hosting vendor to another without changing (almost) any of the deployment and management processes.
Kubernetes can be easily extended to serve nearly any needs. You can choose which modules you’ll use, and you can develop additional features yourself and plug them in.
Kubernetes will decide where to run something and how to maintain the state you specify.
Kubernetes can place replicas of service on the most appropriate server, restart them when needed, replicate them, and scale them.
Self-healing is a feature included in its design from the start. On the other hand, self-adaptation is coming soon as well.
Zero-downtime deployments, fault tolerance, high availability, scaling, scheduling, and self-healing add significant value in Kubernetes.
You can use it to mount volumes for stateful applications.
It allows you to store confidential information as secrets.
You can use it to validate the health of your services.
It can load balance requests and monitor resources.
It provides service discovery and easy access to logs.
When you should use it
If your application uses a microservice architecture
If you have transitioned or are looking to transition to a microservice architecture then Kubernetes will suit you well because it’s likely you’re already using software like Docker to containerize your application.
If you’re suffering from slow development and deployment
If you’re unable to meet customer demands due to slow development time, then Kubernetes might help. Rather than a team of developers spending their time wrapping their heads around the development and deployment lifecycle, Kubernetes (along with Docker) can effectively manage it for you so the team can spend their time on more meaningful work that gets products out the door.
“Our internal teams have less of a need to focus on manual capacity provisioning and more time to focus on delivering features for Spotify.”—Spotify
Lower infrastructure costs
Kubernetes uses an efficient resource management model at the container, pod, and cluster level, helping you lower cloud infrastructure costs by ensuring your clusters always have available resources for running applications.
When you shouldn’t use it
Simple, lightweight applications
If your application makes use of a monolithic architecture it may be tough to see the real benefits of containers and a tool used to orchestrate them. That’s because the very nature of a monolithic architecture is to have every piece of the application intertwined — from IO to the data processing to rendering, whereas containers are used to separate your application into individual components.
Culture doesn’t reflect the changes ahead
Kubernetes notoriously has a steep learning curve, meaning you’ll be spending a good amount of time educating teams and addressing the challenges of a new solution, etc. If you don’t have a team that’s willing to experiment and take risks then it’s probably not the choice for you.
What’s next?
Overall, Kubernetes boasts some pretty great features that can have a positive impact on your developing/DevOps teams and for the business as a whole. If you’re looking to get started with Kubernetes, you can check out A Practical Guide to Kubernetes, written by Viktor Farcic, a Developer Advocate at CloudBees, a member of the Google Developer Experts and Docker Captains groups, and a published author. | https://medium.com/hackernoon/why-and-when-you-should-use-kubernetes-8b50915d97d8 | ['Fahim Ul Haq'] | 2019-07-12 17:23:22.307000+00:00 | ['Software Development', 'Use Kubernetes', 'Learn Kubernetes', 'Kubernetes', 'Cloud Computing'] |
How To Decouple Data from UI in React | Approach A. Custom Hook
Let’s create a custom hook — useSomeData — that returns the properties someData , loading , and error regardless of the data fetching/management logic. The following are 3 different implementations of useSomeData .
With Fetch API and component state:
With Redux:
With Apollo GraphQL:
The 3 implementations above are interchangeable without having to modify this UI component:
But, as Julius Koronci correctly pointed out, while the data fetching/management logic is decoupled, the SomeComponent UI is still coupled to the useSomeData hook.
In other words, even though we can reuse useSomeData without SomeComponent , we cannot reuse SomeComponent without useSomeData .
Perhaps this is where Render Props and Higher Order Components do a better job at enforcing the separation of concerns (thanks again to Julius for highlighting this). | https://medium.com/javascript-in-plain-english/how-to-decouple-data-from-ui-in-react-d6b1516f4f0b | ['Suhan'] | 2020-12-21 16:47:14.382000+00:00 | ['JavaScript', 'React', 'Technology', 'Software Engineering', 'Programming'] |
This is How Seth Godin Changed My Life For Good | This is How Seth Godin Changed My Life For Good
Shattering the illusion of corporate security and picking myself
Seth Godin and Rebecca Murauskas. Photo by Akimbo Staff.
It’s 5:30 PM two days before Thanksgiving, and I step into an elevator with the COO of the Fortune 15 company that I work for.
He and I have a good relationship and a shared interest in mountain climbing that we chat about periodically. I’ve also been working on a huge transformational project with him for a few months, and our camaraderie has expanded.
As the ground floor nears, he turns to me and says, “Have you heard about the leadership summit we want to host?”
“Yes,” I reply. I was privy to some vague chatter and had started to marinate on ideas.
“Sounds great! How may I be helpful?” I add.
“We want to gather our top leaders for a week and make a big impact.”
I remember thinking, fantastic! We can make the event engaging and fun. Maybe release pieces of our transformational project? Plan it over a year and build up the hype.
As the elevator doors open, he casually mentions, “I was thinking right after Easter would be a good time.”
I froze. I can imagine the look on my face was sheer terror.
This “important man,” who was my boss’s boss, wanted us to pull together 6,000 people from across the US to an unknown location for a week’s worth of a leadership summit with four months of planning time during the holidays while we still did our “regular jobs.”
My internal first blush reaction was nothing short of four or five curse words. I may have mustered a fake smile as he turned to hop in his car.
“Happy Thanksgiving,” he shouted. | https://medium.com/the-innovation/this-is-how-seth-godin-changed-my-life-for-good-a70f33652724 | ['Rebecca Murauskas'] | 2020-12-23 19:02:35.043000+00:00 | ['Self Improvement', 'Business', 'Mental Health', 'Writing', 'Life Lessons'] |
The Internet is Multilingual But You Need To Learn Mandarin | The Internet is Multilingual But You Need To Learn Mandarin
Geopolitics and the global adoption of the internet are creating an East vs West language divide.
Photo by Cherry Lin on Unsplash
The internet is becoming the town square for the global village of tomorrow. — Bill Gates.
The language of the internet has shifted from predominantly English to multilingual. But the internet seemingly reinforces a few main languages, putting the majority of others at risk of exclusion. Chinese Mandarin is quickly becoming one of the dominant languages of the internet at the expense of others.
If as Bill Gates says, the internet is a town square, then you need to learn Mandarin in order to have a voice in the digital village of the future.
The Internet’s Multilinguism is Contracting
There are 8 billion people, 195 countries, and over 6,500 languages spoken on the planet. Of the 8 billion, nearly half the people on the planet don’t have regular internet access. And a significant portion of these individuals without access reside in the least developed countries.
Given these stats, it’s fascinating to see the distribution of global languages on the internet.
There are 10 languages that represent 75% of all web traffic. English and Mandarin are neck and neck as the most common languages with the most web traffic. Nearly 50% of global traffic.
The primary English speaking nations (US and UK) have a combined population of about 400 million well below China’s 1.2 billion people. Of the Chinese population, 480 million are not online yet.
Put plainly, populations that represent 15% of the global population see their local languages dominate 50% of web traffic.
Based on these data points, it appears that the internet is leading to a contraction of the languages in use.
Why The Internet’s Language Options are Contracting
Why do English and Chinese dominate as the language of the internet when there are so many other languages?
Because in the 20-year span of 2000 to 2020, the US, China and other more developed nations have experienced significant internet user growth. Unlike less developed locations, these languages have experienced a first-mover and early adoption advantage allowing them to dominate 75% of global web traffic.
With this early advantage, a lot of useful content has been developed and added to the global network in these languages.
As new and often poorly developed nations gain access to the internet, they are forced to choose between building useful content from scratch or opting for a dominant language with well-established content and network effects.
Late adopters are left to adapt to pre-existing technology and their pre-established use cases.
“The famous engine [Google] that recognises 30 European languages recognises only one African language and no indigenous American or Pacific languages.” Daniel Prado Wikipedia is just one site, but even this small pool suggests the universe of information on the internet looks very different from one language to the next. The Digital Language Divide
Because language is often so intertwined with culture, the contracting of available languages online raises a question of equity on the internet. Ie: If languages are not represented equally on webpages does that mean that cultural representation on the web also contracts?
This may indicate that its likely new users coming online have to choose an alternative language to navigate the web and subsequently assimilate into that global culture.
Chinese Geopolitical Strategy Amplifies Language Contraction & Creates A Paradigm Shift
China’s ongoing investments in Africa creates an interesting potential shift in the language makeup of the internet. Africa represents a significant number of the global populace without internet access. Nearly 70% of the Africans representing 800 million people don’t have access.
As initiatives like Starlink and other infrastructure investments unfold, Africa will increasingly join the global internet network in the next decade. Whether they join because of Chinese or US investment, these new users are likely to use one of the 2 dominant languages because of the pre-established network effects.
Research has suggested (pdf) that speakers of smaller languages online will often opt to use the internet in a larger language, even if they don’t speak it well. The Digital Language Divide
But Starlink is an unproven technology and has a slow implementation process. The Chinese investment, on the other hand, is already underway on the African continent. And it also appears that as African’s join the internet their preference is for mobile access.
Mobile internet is an area Chinese companies like Huawei have shown an ability to implement infrastructure quickly. As a consequence, it may be that pre-existing infrastructure investments create a scenario where many of the 800 million African’s default to Chinese web content. This would shift Mandarin to the most dominant language on the web.
Image Created by Author
The Divergent Internet of the East and the West
The Chinese style of the internet is different from the Western style of the internet. The Chinese standard is a notoriously state-controlled economy, with authoritarian controls on media and other types of content. It’s a communally oriented internet, ie: the good of the state comes before the good of the individual. This is often contrary to the western ideals of individual freedoms, privacy-oriented regulations, and freedoms of expression.
The divergent aspects of these respective networks have created different technologies and companies that support their respective network ideologies.
Examples of Divergence:
Like WeChat, an all in one P2P chat, social networking service, and payments platform. Many western individuals would balk at the privacy-related issues of having all their data wrapped into one app. In the west, there are privacy and security-oriented technologies like Bitcoin, Signal, and Facebook.
China and the Mandarin language are more likely than English speaking countries to become the dominant force in the entire Asia region (with the exception of India). This makes it likely that Mandarin could become the dominant language of the web.
Regardless of whether or not the language balance tips one way or the other, Mandarin oriented web content will still make up significant portions of the internet. The diverging policies and subsequent technologies that form from them will be interesting to follow. They represent an opportunity for aspiring digital workers to bridge the gap in diverging tech.
Why You Need to Learn Mandarin
Capital, like energy, is a dormant value. Bringing it to life requires us to go beyond looking at our assets as they are to actively thinking about them as they could be. It requires a process for fixing an asset’s economic potential into a form that can be used to initiate additional production. The Mystery of Capital
In the digital age, information is capital and influence is power.
The ability to create and curate unique digital information assets is like creating and accumulating potential power. As the languages of the internet contract to be dominated by a few, the cultural ideas reinforced by these dominant languages will be evangelized in developing communities.
Influence is gained by leveraging the network effects of the internet to connect large groups of people. As more people join the network, it’s value grows and the internet converges on a few languages and the east/west divide.
Moving forward, being a monolinguist will prove to be a significant opportunity cost as it represents a disadvantage in controlling the global ideological narrative.
As China’s geopolitical strategy plays out over the coming decades the adoption of Mandarin can be expected to continuously grow in Africa and the developing world. Therefore, it makes sense for individuals that want to be relevant in an increasingly connected world to speak the 2 most dominant languages.
Learning Mandarin will empower internet users to tap into a large and growing body of unique internet content. An amalgamation of divergent processes, unique thoughts, and ideologies.
The future of the internet will be characteristic of a multilingual global society where the utility of polyglots becomes significant. By learning Mandarin, you open yourself up to a wider world of opportunities, positioning yourself to maximize the value of the internet's network effects. | https://medium.com/digital-diplomacy/the-internet-is-multilingual-but-you-need-to-learn-mandarin-558c15ab5158 | ['Doug Antin'] | 2020-07-26 16:18:02.794000+00:00 | ['Marketing', 'Technology', 'Future', 'Language', 'Internet'] |
What I Didn’t Learn at Wharton About Personal Finance | 1. Establish The Basic Consumer Banking Accounts and Services
Many people open a bank account after turning 18 or during college. However, a shocking amount of young adults don’t have basic bank accounts (and some are still sharing a custodial account with a parent or guardian).
All young adults should open their own bank account. Ideally, both a checking and savings account, with no monthly fees.
Not only is this good experience in and of itself, it’s important to learn more about the ancillary services your bank offers.
Your bank account will likely come with checks and a debit card.
Learn how to write a check! It may seem antiquated to some, but eventually, you will likely need to write one for a deposit, utility, or a landlord that does accept credit cards or direct deposit.
If your bank offers safety deposit boxes, this can also be a good time to inquire about one.
Many banks are reducing their physical footprint, and as a result, you may need to get on a waiting list.
Why do you potentially need a safety deposit box?
There are some documents and personal items that you want to keep the original version or protect it from fire or damage at home.
Examples of this include:
Social Security Card
Passport
Titles to vehicles or property
Copies of important documents
Physical photographs
Extra keys
Analog media that you haven’t taken the time to convert to digital format
Family heirlooms
Jewelry that is valuable/you don’t wear often
2. Develop A Plan to Maximize Your Credit
Note: If you cannot control your spending, and will not be paying off your entire balance every month, do not get a credit card!
Assuming you only use a credit card for purchases that you can easily pay off in full, getting a credit card is critical for most young adults, when building their credit.
Their are many myths about credit cards:
One of the worst myths is that you have to use a credit card on a regular basis or carry a balance to build credit.
You do need to use credit products to build a good credit score, but you can use them very sparingly. That can be as simple as opening a credit card, charging a small amount with it 2–3 times per year, paying it off immediately every month, and otherwise keeping the card in your dresser drawer.
If you feel comfortable using the card more regularly, you can compare different credit cards, and try to find a rewards structure that you like.
Generally though, you should not be getting a credit card that has annual fees (unless you absolutely know you will be spending enough money to justify the credit card rewards/spending ratio). Even then, this can be a slippery slope into encouraging increased spending. So just stick with a card that has no annual fees.
3. Avoid Grad School Unless Absolutely Necessary
For college graduates, there are generally three tracks that would lead you to pursue graduate education:
Some professions require graduate school. In most cases, you cannot become a doctor, lawyer, university professor without a graduate degree. Assuming you are passionate about these professions, you can usually justify the cost. There is little choice in this scenario in getting the graduate degree, unless you reconsider the entire profession. However it get much more murky with the wide range of jobs, which may not require a graduate degree, but a graduate degree is something that may seem essential to succeed. For example, if you want to work in certain management level positions in business, you may realistically need an MBA depending upon how competitive a position is/company culture. You may also be able to get a lower level job, at the same company, demonstrate your value through work experience, and get promoted into such a role. It may even be the case that companies who otherwise require MBAs for external hires will waive these requirements for an internal candidate that they really want to retain.
In this second case, you need to be careful. While graduate degrees are typically a clearly positive factor from a hiring perspective, many young adults fail to weigh this against the true cost of continuing with education.
Debt, especially student loan debt, is very restrictive. While I can’t advise you one way or the another about whether you should go to graduate school without knowing the intricacies of your situation/life goals, I can say with certainty that the debt you will likely incur, will be something that you will likely have to adjust your life around for years if not decades.
3. Typically the third reason for considering graduate education is a career switch. This is similar to the second reason in that the debt you incur needs to be factored into the equation properly.
4. Emergency Fund
Once you are working and able to save money, you should focus on building an emergency fund.
An emergency fund is a readily available source of assets to help one navigate financial dilemmas such as the loss of a job, a debilitating illness, or a major repair to your home or car. The purpose of the fund is to improve financial security by creating a safety net of cash or other highly liquid assets that can be used to meet emergency expenses, as well as reduce the need to draw from high-interest debt options, such as credit cards or unsecured loans — or undermine your future security by tapping retirement funds.
An emergency fund should contain enough money to cover between three and six months’ worth of expenses, according to most financial planners. Note that financial institutions do not carry accounts labeled as emergency funds. Rather, the onus falls on an individual to set up this type of account and earmark it as capital reserved for personal financial crises.
I tend to agree that 3–6 months is a good amount for an emergency fund if you have a stable source of income.
However, if you are a freelancer, entrepreneur, or are paid a large percentage of your salary as a bonus or work on commission, I would suggest saving a larger amount.
5. Dealing with Debt
In general, you should be avoiding most consumer debt. But if you do have consumer debt (credit cards, auto, store debt), you should almost always prioritize paying down this debt before building your savings. This is because consumer debt (especially credit cards) tend to have very high interest rates.
Credit card issuers can lure you in with a low introductory APR and gleaming credit line. But that introductory APR offer will eventually expire. When it does, you can find yourself staring at an overwhelming pile of debt if you didn’t manage your new credit card account the right way.
The reason revolving debt can be so overwhelming is because credit card interest rates are typically really high. So, if you’re just making the minimum payment each month, it will take you a long time to pay off your balance — possibly decades. During that time, you’ll also pay a lot of interest.
Let’s say you charge $8,000 on a credit card with 17% APR, and then put it in a drawer, never spending another cent. If you make only the minimum payment on that bill each month, it could take you almost 16 years to pay off your debt — and cost you nearly $7,000 extra in interest!
6. Develop Savings and Spending Patterns
In our “treat yourself/YOLO” culture it is easy to forget to prioritize saving and developing good spending habits.
Start with a spending log. Yes, you have heard this advice before. This exercise is eye-opening if you do it diligently. With online banking you will have access to a visual record of all your spending. This is a great way to begin to spot patterns and decide where you can cut back.
Analyze your online account statement (four weeks is ideal) to help you determine where your money is going. Review your log without judgment. What you have done, in terms of your spending, does not matter — at least not yet. What does matter is that you get a firm hold on your expenses. For example, how much money do you spend on eating out each week?
Next, write down all sources of income. With a list of your income and expenses in hand determine your priorities. Begin your budgeting process here. Obviously housing and other fixed costs will figure prominently on your priority list. Now, take a look at the conveniences that represent variable expenses. This is likely where you will find room to make changes. For example, if you buy coffee each day, can you bring it from home a time or two each week? Or would you be willing to purchase a smaller or otherwise less expensive cup? Can you clip coupons or eat out a little less?
Remember, developing any new habit takes practice. In time you may even learn to love your new healthy spending habits. It is liberating to be in control of your finances. So take a serious look at your savings/spending. Create a budget and stick to your savings goal.
7. Developing Multiple Sources of Income
This topic is a bit more advanced, but only because so few people are taught this.
Developing multiple streams of income is essential to achieving financial independence.
This could consist of someone creating a new source of active income. An example of this would be someone who works as an office manager during the week (their primary job) but begins driving for Uber on the weekend to make some extra money. This is also an additional income stream.
This could also consist of someone creating new streams of passive income. I am a huge proponent of developing passive income streams. The basic difference between passive and active income is that active income requires the direct trading of time for money. Passive Income is generally defined as a stream of income earned with little or no ongoing effort needed from the individual receiving the passive income in order to grow the stream of income. Passive income is income that is not proportional to the time you physically put into acquiring it.
I’ve written a fairly detailed article with a number of passive income ideas that I have tried:
Regardless of whether its active or passive income, diversifying you sources of income will make you feel more secure and financially stable.
8. Investing
Once you have a well stocked emergency fund, and your savings account begins to grow, it is time to start strategically investing that money. Many people are scared of investing. But luckily, the rise of index funds have made cost effective investing much easier than it was a generation ago.
Index funds are a type of mutual fund where thousands of investors pool their cash to purchase shares in a fund that mimics a benchmark index, such as the S&P 500 (hence the name “index fund”).
This simpler approach — known as passive investing — has proved more profitable for the average investor than active investing, for two reasons: Markets tend to rise over time, and index funds charge lower fees, allowing investors to keep more of their money in the market. As a result, many investors now flock to passive funds.
All investments carry risk, and Vanguard index funds are no exception. For example, investors in Vanguard’s flagship S&P 500 Index Fund saw the fund’s value drop more than 4% year over year after the market tumult in 2018. But the fund’s 10-year average annual return was 14.3%, thanks to the second-longest bull market in history.
Passively investing in index funds is so popular because most actively managed funds fail to consistently outperform the market. For example, from 2002 to 2017, only about 11% of actively managed stock funds beat their designated benchmark, according to Vanguard and Morningstar data.
9. Begin Retirement Account Contributions
Even if you have never considered retirement, don’t feel like your ship has sailed. Every dollar you can save now will be much appreciated later. Strategically invest and you won’t be playing catch-up for long. Note: This topic is too big to cover in this section alone, but hopefully it will serve as a primer for the larger topic.
The first place to start retirement planning is by saving and investing money through one or all of the available options offered through employment and personal investments. Many employers offer retirement planning options such as pension plans, 401(K) plans, or a combination of various plans. However, you do not have to rely solely on company-sponsored plans. You can choose to invest on your own with or without the help of financial planners.
Employer-sponsored retirement plans
Employer-sponsored retirement plans include benefit plans such as pensions; contribution plans such as 401(k), Roth 401(k), 403(b), 457(b); and Thrift Savings Plans.
401(k) can be one of the best tools for creating a secure retirement. It provides you with two important advantages. First, all contributions and earnings to your 401(k) are tax-deferred. You only pay taxes on contributions and earnings when the money is withdrawn. Second, many employers provide matching contributions to your 401(k) account. The combined result is a retirement savings plan you cannot afford to pass up.
403(b) plans are only available for employees of certain non-profit, tax-exempt organizations: 501c(3) Corps, including colleges, universities, schools, hospitals, etc. If you are an employee of one of these organizations, a 403(b) can be one of your best tools for creating a secure retirement. It provides you with two important advantages. First, all contributions and earnings to your 403(b) are tax-deferred. You only pay taxes on contributions and earnings when the money is withdrawn. Second, many employers provide matching contributions to your 403(b) account which can range from 0% to 100% of your contributions. The combined result is a retirement savings plan you cannot afford to pass up.
Individual retirement plans
Individual retirement plans include traditional IRAs, ROTH IRAs, spousal IRAs, myRAs, and rollover IRAs. Contributing to a traditional IRA can create a current tax deduction, plus it provides for tax-deferred growth. While long term savings in a Roth IRA may produce better after-tax returns, a Traditional IRA may be an excellent alternative if you qualify for the tax deduction. Always check with your tax advisor prior to making any investments.
Retirement plans for self-employed and small business owners
Retirement plans such as SEP, SIMPLE, and Payroll Deduction IRAs are for individuals or small business owners with employees. | https://medium.com/escaping-the-9-to-5/what-i-didnt-learn-at-wharton-about-personal-finance-8a1f2d79dee9 | ['Casey Botticello'] | 2020-05-06 02:27:01.226000+00:00 | ['Personal Finance', 'Business', 'Entrepreneurship', 'Productivity', 'Financial'] |
10 rules for better dashboard design | One view to rule them all
Dashboard design is a frequent request these days. Businesses dream about a simple view that presents all information, shows trends and risky areas, updates users on what happened — a view that will guide them into a bright financial future.
For me, a dashboard — is an at a glance preview of the most crucial information for the user at the moment he is looking at it, and an easy way to navigate directly to various areas of the application that require users attention. The term “dashboard” is a metaphor for a car dashboard, sometimes also called the cockpit area, usually near the front of an aircraft or spacecraft, from which a pilot controls the aircraft.
Working on enterprise projects for years, I have designed countless dashboards. And every new one is the next challenge for me. A good dashboard can be a daunting thing to design. Based on my experience, I put together a list of useful suggestions to help you in the future. Whether you just starting, or are seasoned designer, I’m sure you will find something interesting here.
1.Define the purpose of the dashboard.
Like any other view in your product, the dashboard has a specific purpose that it’s undertaken to serve. Getting this wrong renders your further efforts meaningless. There are multiple popular ways to categorize dashboards based on their purpose(Analytical, Strategic, Operational, Tactical etc).
To keep things simple I will divide them into 2 more general forms:
Operational dashboard
Operational dashboards aim to impart critical information quickly to users as they are engaged in time-sensitive tasks. The main goals of the operational dashboard are to present data deviations to the user quickly and clearly, show current resources, and display their status. It’s a digital control room designed to help users be quick, proactive, and efficient. | https://uxplanet.org/10-rules-for-better-dashboard-design-ef68189d734c | ['Taras Bakusevych'] | 2019-10-05 17:11:28.891000+00:00 | ['Design', 'Dashboard', 'UX', 'Data Visualization', 'User Interface'] |
Coronavirus: The Hammer and the Dance | As of today, there are 0 daily new cases of coronavirus in the entire 60 million-big region of Hubei.
The diagnostics would keep going up for a couple of weeks, but then they would start going down. With fewer cases, the fatality rate starts dropping too. And the collateral damage is also reduced: fewer people would die from non-coronavirus-related causes because the healthcare system is simply overwhelmed.
Suppression would get us:
Fewer total cases of Coronavirus
Immediate relief for the healthcare system and the humans who run it
Reduction in fatality rate
Reduction in collateral damage
Ability for infected, isolated and quarantined healthcare workers to get better and back to work. In Italy, healthcare workers represent 8% of all contagions.
Understand the True Problem: Testing and Tracing
Right now, the UK and the US have no idea about their true cases. We don’t know how many there are. We just know the official number is not right, and the true one is in the tens of thousands of cases. This has happened because we’re not testing, and we’re not tracing.
With a few more weeks, we could get our testing situation in order, and start testing everybody. With that information, we would finally know the true extent of the problem, where we need to be more aggressive, and what communities are safe to be released from a lockdown.
New testing methods could speed up testing and drive costs down substantially.
We could also set up a tracing operation like the ones they have in China or other East Asia countries, where they can identify all the people that every sick person met, and can put them in quarantine. This would give us a ton of intelligence to release later on our social distancing measures: if we know where the virus is, we can target these places only. This is not rocket science: it’s the basics of how East Asia Countries have been able to control this outbreak without the kind of draconian social distancing that is increasingly essential in other countries.
The measures from this section (testing and tracing) single-handedly curbed the growth of the coronavirus in South Korea and got the epidemic under control, without a strong imposition of social distancing measures.
Build Up Capacity
The US (and presumably the UK) are about to go to war without armor.
We have masks for just two weeks, few personal protective equipments (“PPE”), not enough ventilators, not enough ICU beds, not enough ECMOs (blood oxygenation machines)… This is why the fatality rate would be so high in a mitigation strategy.
But if we buy ourselves some time, we can turn this around:
We have more time to buy equipment we will need for a future wave
We can quickly build up our production of masks, PPEs, ventilators, ECMOs, and any other critical device to reduce fatality rate.
Put in another way: we don’t need years to get our armor, we need weeks. Let’s do everything we can to get our production humming now. Countries are mobilized. People are being inventive, such as using 3D printing for ventilator parts. We can do it. We just need more time. Would you wait a few weeks to get yourself some armor before facing a mortal enemy?
This is not the only capacity we need. We will need health workers as soon as possible. Where will we get them? We need to train people to assist nurses, and we need to get medical workers out of retirement. Many countries have already started, but this takes time. We can do this in a few weeks, but not if everything collapses.
Lower Public Contagiousness
The public is scared. The coronavirus is new. There’s so much we don’t know how to do yet! People haven’t learned to stop hand-shaking. They still hug. They don’t open doors with their elbow. They don’t wash their hands after touching a door knob. They don’t disinfect tables before sitting.
Once we have enough masks, we can use them outside of the healthcare system too. Right now, it’s better to keep them for healthcare workers. But if they weren’t scarce, people should wear them in their daily lives, making it less likely that they infect other people when sick, and with proper training also reducing the likelihood that the wearers get infected. (In the meantime, wearing something is better than nothing.)
All of these are pretty cheap ways to reduce the transmission rate. The less this virus propagates, the fewer measures we’ll need in the future to contain it. But we need time to educate people on all these measures and equip them.
Understand the Virus
We know very very little about the virus. But every week, hundreds of new papers are coming.
The world is finally united against a common enemy. Researchers around the globe are mobilizing to understand this virus better.
How does the virus spread?
How can contagion be slowed down?
What is the share of asymptomatic carriers?
Are they contagious? How much?
What are good treatments?
How long does it survive?
On what surfaces?
How do different social distancing measures impact the transmission rate?
What’s their cost?
What are tracing best practices?
How reliable are our tests?
Clear answers to these questions will help make our response as targeted as possible while minimizing collateral economic and social damage. And they will come in weeks, not years.
Find Treatments
Not only that, but what if we found a treatment in the next few weeks? Any day we buy gets us closer to that. Right now, there are already several candidates, such as Favipiravir, Chloroquine, or Chloroquine combined with Azithromycin. What if it turned out that in two months we discovered a treatment for the coronavirus? How stupid would we look if we already had millions of deaths following a mitigation strategy?
Understand the Cost-Benefits
All of the factors above can help us save millions of lives. That should be enough. Unfortunately, politicians can’t only think about the lives of the infected. They must think about all the population, and heavy social distancing measures have an impact on others.
Right now we have no idea how different social distancing measures reduce transmission. We also have no clue what their economic and social costs are.
Isn’t it a bit difficult to decide what measures we need for the long term if we don’t know their cost or benefit?
A few weeks would give us enough time to start studying them, understand them, prioritize them, and decide which ones to follow.
Fewer cases, more understanding of the problem, building up assets, understanding the virus, understanding the cost-benefit of different measures, educating the public… These are some core tools to fight the virus, and we just need a few weeks to develop many of them. Wouldn’t it be dumb to commit to a strategy that throws us instead, unprepared, into the jaws of our enemy?
4. The Hammer and the Dance
Now we know that the Mitigation Strategy is probably a terrible choice, and that the Suppression Strategy has a massive short-term advantage.
But people have rightful concerns about this strategy:
How long will it actually last?
How expensive will it be?
Will there be a second peak as big as if we didn’t do anything?
Here, we’re going to look at what a true Suppression Strategy would look like. We can call it the Hammer and the Dance.
The Hammer
First, you act quickly and aggressively. For all the reasons we mentioned above, given the value of time, we want to quench this thing as soon as possible.
One of the most important questions is: How long will this last?
The fear that everybody has is that we will be locked inside our homes for months at a time, with the ensuing economic disaster and mental breakdowns. This idea was unfortunately entertained in the famous Imperial College paper:
Do you remember this chart? The light blue area that goes from end of March to end of August is the period that the paper recommends as the Hammer, the initial suppression that includes heavy social distancing.
If you’re a politician and you see that one option is to let hundreds of thousands or millions of people die with a mitigation strategy and the other is to stop the economy for five months before going through the same peak of cases and deaths, these don’t sound like compelling options.
But this doesn’t need to be so. This paper, driving policy today, has been brutally criticized for core flaws: They ignore contact tracing (at the core of policies in South Korea, China or Singapore among others) or travel restrictions (critical in China), ignore the impact of big crowds…
The time needed for the Hammer is weeks, not months. | https://tomaspueyo.medium.com/coronavirus-the-hammer-and-the-dance-be9337092b56 | ['Tomas Pueyo'] | 2020-05-28 07:58:27.402000+00:00 | ['Health', 'Coronavirus', 'Politics', 'Healthcare'] |
Life (and Sex) is Better Without Alcohol | I stopped drinking last year. I had been told to expect better sex. But it still surprised me when it happened.
Photo of me 31 weeks pregnant, by Scott Schell.
Growing up I remember my great-grandmother having her drink every day at 4 pm in a tall glass that I used for drinking milk — 3/4 red wine, 1/4 water. At her 88th birthday party, she was sitting on the grass in a wicker folding chair, and just as her drink was handed to her, the chair folded up. She fell to the ground and somehow managed to not break a bone or spill a drop of her drink. My uncle would tell this story with a drink in his hand and laugh so hard he needed to wipe his eyes. I heard this and understood that alcohol brings happiness and is worth sacrificing your body to protect.
We inherit the experiences of at least three generations of our ancestors in our DNA, and all three of mine are Irish Catholic and drank too much. Alcohol isn’t a small thing to my body. It feels like the scaffolding of my nervous system has a lot of Budweiser, red wine, and Beefeater dry gin in it.
I don’t remember my first drink, but I was probably five. I’m told they found me ‘asleep’ in the coat closet after I sneaked around my parents’ holiday party sampling adult refreshments. I was fourteen the first time I got drunk on purpose. My parents had a big party, and I took two beers every hour and hid them behind the furnace (it took me a few years to figure out that I could take all ten at once and no one would notice). The next weekend, after my parents had gone to bed, my best friend and I sat on the floor in the triangle between the couch, the coffee table, and the lazy boy and drank five beers each. I don’t remember what we talked about, but I do remember that we both cried and when I tried to stand up I fell over the lazy boy and threw up on the carpet.
I continued drinking heavily until my early 30s when I started teaching yoga. I was living in Afghanistan and a friend asked me to fill in teaching her evening class on the UN compound. It wasn’t at a yoga studio and no one paid. It was just a group of people wanting some yoga. That’s how I justified drinking a gin and tonic before class. I almost fell over demonstrating a triangle pose and I laughed about that with my friends, but the hypocrisy I felt about myself was so excruciating that I started to drink less.
Me and my grandmother.
By the time I stopped drinking I was 42 and a lot like my great-grandmother, a dedicated one drink a day kind of gal. And what I can see looking back, is that whether I had one drink or five, the pattern was the same. I would spend a lot of time looking forward to it and a lot of energy trying to be cool about that. And then the glorious delight of it finally being time and my body softening at the first sip; my chest lighter and more open, and for a brief moment everything was going to be okay.
With a few more sips a daydreamy, floaty mind would creep in and eventually linger into a sleepy, lonely, and slightly checked out feeling. As that wore off, there was only the worry that wouldn’t leave me alone — the part of me that knew my drinking was a problem. And the sad little pit in my stomach.
The background hum of shame and melancholy was like the wallpaper in my parent’s bathroom. I didn’t like it, but I also didn’t think about it that much and it never occurred to me that I could change it. And then I got off that tragic little roller coaster that every cell of my being knew so well; and dropped a substance that had been organizing my emotions since long before I was even born.
I have experienced every benefit purported in the quit lit: better sleep, better sex, more self-confidence, improved well-being. What I didn’t expect, was no longer needing a vibrator to have an orgasm during sex. My body only ever knew the predictable up and down of life disrupted and controlled by alcohol — and I was sort of free falling without it. And that is what changed my orgasm, the ability to release into the free fall of a life not controlled by a substance.
The slow steady build-up of orgasm without a vibrator is terrifying — or it was because that build-up requires me to stay present with something I can’t control and don’t know where it’s going. I was probably thirteen the first time I used a vibrator. My mom was a math teacher and came home one day with a vibrating pen. I remember sneaking into her office with a tingle of excitement and shamefully putting it back exactly as I had found it not too long later.
I never questioned the ‘sure-thing’ climax a vibrator provided me. Until all of a sudden, about six months after my last drink, I didn’t want to reach for the predictable outcome of the vibrator. I didn’t plan it or set out to do it. The vibrator just started to feel in the way. And I started being able to stay in my body, to feel my body, to feel safe enough to stay at the pace of my body — with my husband, and his body, and we started having orgasms at the same time. I had never done that before and always wanted to.
The unconscious story playing out, “If I can’t control it then I’m not safe” — is true in an alcohol-addicted home. The story that, “I can’t trust myself” is also true with substance use. There is a good reason we shouldn’t use heavy machinery or send important work emails when drinking — we can’t be trusted.
I didn’t even know these stories were there, or what they were holding me back from until I stopped using the substance that made them true. Pema Chodron describes addiction as anything we reach for to avoid a feeling we can’t tolerate. The intensity, even when it was exciting and felt good, scared me. And I only needed one drink to keep myself tethered to that deep groove in my nervous system.
I grew up believing that hitting rock bottom, face first, was the only reason to stop drinking. That being forced to give up alcohol would be a tragic loss. That I would be bored and alone, white-knuckling my way through a sad little thirsty life. I believed there are alcoholics, who want to drink but can’t because there is something wrong with them; and normal people, who can drink as much as they want and never have a problem. Years ago, a family friend actually said, “I can drink as much as I want because I’m not an alcoholic.”
Of course, that isn’t true. Alcohol is an addictive substance, and alcohol addiction is progressive. Just because we find ways to make our lives work around our drinking, doesn’t mean our drinking isn’t a problem or that it’s making us happy. For me, it took losing someone I love to an overdose to finally see alcohol for what it is, an imposter. A toxic and addictive depressant cleverly disguised as happiness.
Alcohol wasn’t ruining my life, but it was diminishing it, and I was addicted. And every aspect of my life — including my orgasm — is more wild and free without it.
Addiction is progressive and so is sobriety. Slowly, over time, and with repeated experiences we can and do re-pattern our nervous system. I stopped drinking a year ago, but I’ve been working on getting sober for at least a decade, and true sobriety means so much more than the absence of alcohol. It means coming closer to the nature of reality. It means I don’t need things to be more predictable than they are to feel safe. It means I can bake cookies with my kids and not lose my shit.
When my four-year-old drops an egg and it feels like things are spiraling out of control and my one-year-old puts his hand in it and that familiar rush of fear and anxiety is so strong, and I feel panicked to make it stop — I can stay a few breaths longer. And sometimes, one year into being free from alcohol, I don’t lose my shit at all. Sometimes it’s genuinely fun. And that is the experience I want to share with three generations — the grounded freedom of true sobriety.
If you have that voice that won’t let you alone, wondering if you’re drinking is a problem, I really want you to hear that sobriety is not the prison of boredom mainstream culture would have you believe. Freedom from alcohol means endless nights of deep dream-filled sleep, waking up bright-eyed, sturdy, without a hangover — and if you have them, ready to be more patient and enjoy your kids.
You don’t need to be in a ditch bleeding out to decide it’s a good time to stop drinking. And it doesn’t have to be all or nothing. You can just drink a little less and see how it goes. And you don’t have to be addicted or have a family history of addiction for it to be a good idea. My husband stopped drinking before I did because he was training for a 150mile trail run. For him, he just feels better, and that’s enough.
Like anything else, you will learn a lot about your relationship with alcohol when you leave it. So why not try and find out? You never know, you might just surprise yourself with a great orgasm. | https://medium.com/an-injustice/life-is-better-without-alcohol-dc5e7ec4ff13 | ['Meghann Mcniff'] | 2020-12-28 15:12:20.777000+00:00 | ['Women', 'Mental Health', 'Addiction', 'Sexuality', 'Health'] |
Trigger Warnings Help Me Deal With Trauma In My Own Time | Trigger Warnings Help Me Deal With Trauma In My Own Time
How one website has helped me process traumatic incidents
Photo by Colby Ray on Unsplash
Trigger warnings have been much maligned as of late. They’ve been described as indicative of a “snowflake generation”, too scared to see anything mildly unpleasant, cocooned in cotton-wool by over-zealous parents. But trigger warnings have really helped me deal with the traumatic thing that happened to me.
A trigger warning (often shortened to ‘TW’) is a kind of advance notice of a potentially traumatic image or phrase occurring in a film or literature. There are varied responses to the idea of a trigger warning. Urban Dictionary (arguably the encyclopedia of the youth) shows a polarization in views between people; the ‘top definition’ at the time of writing applauds trigger warnings, described them as ‘a warning before showing something that could cause a PTSD reaction. Commonly used as a joke, its meaning has unfortunately depreciated, drawing more stigma to mental illness.’
Another, however, takes a wholly negative view of the trigger warning — describing them as ‘a phrase posted at the beginning of various posts, articles, or blogs. Its purpose is to warn weak-minded people who are easily offended that they might find what is being posted offensive in some way due to its content, causing them to overreact […] trigger warnings are unnecessary 100% of the time due to the fact that people who are easily offended have no business randomly browsing the internet anyways. As a result of the phrases irrelevance, most opinions that start out with this phrase tend to be simplistic and dull since they were made by people ridiculous enough to think that the internet is supposed to cater to people who can’t take a joke.’
I don’t see it this way. Trigger warnings have really helped me. I use a site called DoesTheDogDie.com; a place where trigger warnings are given for material that could be sensitive to some eyes. The website scours various forms of media and assesses the content. It’s founded on the goodwill of users. I’ve found it to be a life-saver.
I was in a psychiatric hospital a few years ago after everything with me, mental health-wise, reached a crisis. I had experienced a traumatic sexual assault when I was a teenager, and I had pushed the experience down deep inside me. I had barely thought about it. Then, a similar kind of thing happened again around consent — a male friend was very drunk, and I tried to push him away. He tried to kiss me because he thought I was his girlfriend. I completely broke. I remember crying after it happened, and someone stopping me in the street to ask if I was okay. I wasn’t.
I ended up self-harming voraciously; daily burning myself or cutting the soles of my feet. I was binging and purging sometimes up to six times a day. I had to pour dishwashing liquid over the food I’d thrown out. It was intolerable. I ended up being sectioned under the UK’s Mental Health Act, and I was inside a psychiatric institution for a fortnight. While I was there, a healthcare assistant backed me up against the floor while she screamed at me. I was scrambling around on the floor like a dog. My parents traveled six hours north to visit me, where they would only stay for half-an-hour or so; they said they had to get back on the road, but I knew that they found it too upsetting.
My father, a man who is normally very Stoic by nature, cried when he saw me in the hospital. I’d never seen him cry before, and I’ve never seen him cry since — and I’ll be twenty-five next year. My heart broke a little as I saw his eyes fill and a single, solitary tear trickle down his cheek.
I didn’t magically get better upon leaving the hospital (as some people think), but that’s a story for another time. The important thing is that talking about mental illness became very distressing for me. Watching suicide attempts on screen left me squirming in my seat and sometimes in tears. I also found it hard to see images of psychiatric hospitals. It became incredibly tough to sit down and watch a movie with my family without worrying that there would be a scene that would make me feel distressed in it.
I was already struggling with a Generalized Anxiety Disorder. I struggle with relaxing. When I’m thinking about self-care and what routines to implement in my daily life, there are often suggestions on the internet of ‘doing things to relax you’ — to which I think, “well how am I meant to do that?”
So dealing with relaxation is something I really struggle with. I can’t deal with doing nothing; I start to feel guilty, I start to feel like I need to be doing something productive. Trying to relax and watch a film is stressful enough. But this is where DoesTheDogDie.com comes in; it offers warnings as to the potentially triggering material in over 7,000 movies, TV shows, books, and video games.
The first question on every page is “Does the dog die?” Apparently, that used to be the only question. Creator John Whipple told Lifehacker that the site was originally his sister’s idea, “She found it frustrating to watch a movie with a dog in it because worrying over the survival of the dog made it impossible to enjoy the movie.” Now it’s expanded to cover a wide range of issues, like films with strobe effects, books where a parent dies, violence, self-harm, and torture, to TV shows where Santa is revealed to be a fictional character.
Some questions aren’t covered, like “Is someone sexually assaulted?”, linking to the site Unconsenting Media, which meticulously tracks sexual violence in various media forms. But over 70 categories are covered, and that’s helped me deal with the awkwardness of an unsuspecting scene that could provoke a traumatic response in me and a general awkwardness with my family. Sure, things have got a little better since; I hardly use the site now, as I’m a lot less prone to traumatic responses. But I’m slowly tapering down from my medication, and so I’m aware that I can become triggered a little easier at the moment.
I’ve found trigger warnings to be really helpful when I’m recovering from traumatic past incidents. I understand that some people can find trigger warnings unnecessary. But if that’s you, then — congratulations — you don’t need to use them. Scroll past that TW to your heart’s content. But for those of us who do need trigger warnings, it can save us an unnecessary amount of heartache. It’s not about completely avoiding everything that might upset me or trigger me. It’s about dealing with those trauma-inducing situations safely with a professional, like a therapist. I’m currently doing CBT-E, and I’m addressing some of the traumatic things that happened to be there. For people who really need them, trigger warnings are so important. | https://medium.com/invisible-illness/how-trigger-warnings-help-me-deal-with-my-trauma-1d0193ae7cec | ['Lizzie Bestow'] | 2020-09-05 21:41:05.914000+00:00 | ['Health', 'Trauma', 'Life', 'Mental Health', 'Life Lessons'] |
5 Untouched Writing Genres You Can Opt For | 5 Untouched Writing Genres You Can Opt For
Philosophy with fiction can be a good combination, learn how.
Photo by Ella Jardim on Unsplash
Writing genres are various categories in which your writing can fall. While some genres have grown with their writers and readers over time, others are probably not even heard of. Some of the prominent genres that have gained attention over time include:
Poetry
History
Short story
Narrative
Biography
Self-improvement
Fiction including romance, Horror, sci-fi, crime, fantasy.
But there are some equally fascinating genres that are like the roads less traveled by. Some of them were limited to a time period in history and have lost their imprints in today’s world. While others could not gain much traction due to other lesser-known reasons.
In this article, I am going to talk about 5 such writing genres that could be added to your list. Even though they are chosen by relatively fewer people, this doesn't conclude that they are difficult to write in. So let's get started: | https://medium.com/the-brave-writer/5-untouched-writing-genres-you-can-opt-for-32f179168d69 | ['Niyati Jain'] | 2020-12-10 13:02:02.707000+00:00 | ['Creativity', 'Work', 'Self Improvement', 'Freelancing', 'Writing'] |
How To Use A Book To Build A Career Or Business | How To Use A Book To Build A Career Or Business
A book will help you stand out
Imagine meeting the person who can impact your career big time. Maybe it’s an angel investor for your start-up or a corporate executive who can get you some major consulting or public speaking projects. What can you give them, to effectively communicate that you’re worth listening to?
A business card? A resume? Most people throw that stuff away as soon as you give it to them. They’ll move on and forget about you.
Or let’s say you want to grow your business. Why would a stranger give you money for your products or services? Why would they trust you? No one likes to chase clients and get people for their business.
This is where a book comes in. A book communicates that:
You’re who had the idea and insight to write a book, Not everyone can start, finish, and publish a book — but you did; This means the book is proof you know what you’re talking about, plus you can execute.
Everybody has a business card and a resume. And every business has a website. But compared to the masses, only a few people have a book.
Of course, simply having a book won’t get you there. Your book has to actually deliver its message properly and persuasively; otherwise you’ll lose the credibility you’re trying to build. So how do you publish a book to build a career or business?
Be Clear About Your Goals
Every book has a purpose and a message. If your book has nothing to do with your professional field it won’t help your career at all. Imagine a sales trainer who would write about yoga. Nothing wrong with both topics, but there’s no match between your profession and your book in that case.
So think of your goal first.
Want to sell books and make money from book royalties?
Or do you want to sell consulting, courses, apps, you name it?
You have to be clear about the goal of your work, including the kind of people that you’re writing it for. This article is for people who want the latter.
Remember that on average, nonfiction books sell less than 500 copies in a year. There are authors who couldn’t even reach the industry average, while best selling authors like the late Stephen Covery have sold millions of books.
Price’s Law applies here too. Only a handful of people generate the majority of book sales. That’s why your book’s message and purpose has to be very clear from the start. To be honest, I’m definitely not part of the minority that generates the majority of the sales in the book business. And that’s totally fine. Accepting that will only make your career or business more successful.
Write Something That Genuinely Helps
A book’s main selling point is an effectively communicated idea.
Consultants, public speakers and coaches are all there to help a specific niche of people. Keep this in mind when you’re writing your book: don’t write for everyone. Your personality, style of writing and solutions won’t work for everyone. Hitting too broad or too narrow will get you nowhere, so focus instead on giving a unique solution to a general problem.
Remember the scenario when you give your book to a potential client/investor/business partner? Think of your book as an answer to your target audience’s perceived problems. This is why you should talk about the things you know best. It’s always about leveraging your strengths to solve other people’s problems.
Your book serves as an initial impression of your skills and expertise. I believe this is the only way you can demonstrate your worth. No one cares about promises and what you want to do. Show it! This brings us to the next point.
Establish Your Credibility
There are plenty of experts in the world with shiny business cards and fancy websites. If you want to be a high-demand consultant, public speaker, or personal coach, your book helps you stand out from the crowd.
There’s a reason why bloggers, interviewers, journalists want to talk to the “person who wrote the book” about a topic. A book not only shows that you have the concentration, dedication, and focus to get something done. It also establishes your status as an expert in your field.
Nowadays, it’s almost an almost a necessity for panel experts or public speakers to have published at least a book or two, to be considered as a real specialist in the field. We’ve got to be honest about this.
So remember to write your book well. Remember to be honest about what you say (you don’t want to have a reputation of being sleazy), keep your stories personal, clear and to the point, and research your facts right.
Create and Attract Opportunities
Here’s what I learned about the nonfiction book business: Don’t focus on book sales. Why? Because it’s all a matter of getting your book in front of the few people who can truly impact your business.
My first book sold about 20–30 copies a month. The royalties were a few bucks a month. Most people will not be able to earn a good living from book royalties. But that book helped me to create many different opportunities as a trainer, earning six figures.
Even now that I have a bigger audience, my book sales are good for about 7% of my revenue. You see, it’s not about book sales.
With your book out there, you can reach the attention of people who are both consciously and unconsciously looking for what you have to say or the services that you offer.
This is especially true for technical experts. You’re unlikely to reach busy executives or company heads using social media ads. So when you write your book, don’t think too much about book sales. Instead, focus on how your books will attract the right opportunities.
Books Are Forever
The great thing about writing a book is that often, your book can far outlast you. Peter Drucker passed away years ago (2005), yet his ideas are still being used in many progressive companies all over the world. How crazy is that? Think about the potential impact you can have with a book.
This is the true power of books: They immortalize our ideas and stories, farther than our own lifespan can ever reach. It’s all about creating a lasting impact on people’s lives.
So when you’re writing a book to build a business, always think about this: How can you change your reader’s life? Answer that, and you’ll book will take care of the rest. You just have to write it first. | https://medium.com/darius-foroux/how-to-use-a-book-to-build-a-career-or-business-194f200dd39a | ['Darius Foroux'] | 2020-09-08 11:47:40.464000+00:00 | ['Business', 'Books', 'Careers', 'Writer', 'Writing'] |
Plotly Express: the Good, the Bad, and the Ugly | Plotly Express: the Good, the Bad, and the Ugly
It might be newer, but is it better?
Creating effective data visualizations is a very important part of data science from the beginning to the end of the data science process. Using visualizations during your exploratory data analysis is a great way to get a good idea of what your data is about. Creating visualizations at the end of your project is a great way to communicate your findings in an easy-to-understand way. There are so many different tools for data visualization in Python, from cult favorites like Matplotlib and Seaborn, to the newly-released Plotly Express. All three are pretty simple to use, and don’t require a lot of in-depth programming knowledge, but how do you decide which one to use?
What is Plotly Express?
If you’ve ever used Plotly, or even just looked at code written to use Plotly, you know that it’s definitely not the simplest library to use for visualizations. That’s where Plotly Express comes in. Plotly Express is a high-level wrapper for Plotly, which essentially means it does a lot of the things that you can do it Plotly with a much simpler syntax. It is pretty easy to use, and doesn’t require connecting your file to Plotly or specifying that you want to work with Plotly offline. After Plotly Express is installed, a simple import plotly_express as px is all you need to start creating simple, interactive visualizations with Python.
The Good
There are several advantages to using Plotly Express to create visualizations.
The entire visualization can be created with one line of code (kind of).
px.scatter(df, x='ShareWomen', y = 'Median',
color = 'Major_category',
size = 'Total', size_max = 40,
title = 'Median Salary vs Share of Women in a Major',
color_discrete_sequence = px.colors.colorbrewer.Paired,
hover_name = 'Major'
While it technically took 6 lines to create this, it still only took a single command. In creating a Plotly Express visualization, everything can be done in the same command, from adjusting the size of the graphic, to the colors it uses, to the axes labels. In my opinion, Plotly Express is the easiest way to quickly create and modify a visualization. Also, the visualization is automatically interactive, which brings me to my next point.
It’s interactive.
A mouseover of a specific point will bring up a box that has any of the information that was used to create the graph, as well as any extra information you want to include. In this particular graph, including hover_name = 'Major' made the specific major the point was referring to the title of each box. This allows us to get a lot of information out of our graphic that we wouldn’t be able to get otherwise. Additionally, we can also see what the two largest majors are, which we were unable to do when creating a similar plot using Seaborn.
You can isolate certain information.
Clicking a category in the legend of the visualization twice will isolate that category so it is the only one we can see in the graphic. Clicking it once will remove that category, so we can see all of the categories with the exception of that one. If you want to zoom in on a certain area, all you have to do is click and drag to create a rectangle that encompasses the smaller are you want examine more closely.
You can animate change.
One of the coolest features available with Plotly Express is the ability to add an animation frame. By doing so, you allow yourself to view how something changes over a certain variable. Most often, the animation frame is based on year, so you can visualize how something changes over time. Not only is this cool to see as you’re creating visualizations for yourself, but being able to create an animated AND interactive visualization seriously make you look like you know what you’re doing.
The Bad
It doesn’t have ton of features.
Don’t get me wrong, there is a LOT you can do with Plotly express. It just doesn’t have as many options when it comes to adjusting the appearance of your graph. In Seaborn, for example, you can change the why the points on your categorical scatterplot line up by changing things like jitter = False and kind = 'swarm' . To my knowledge, neither of these are possible using Plotly Express. This really isn’t the end of the world, especially considering that one of the main goals of Plotly Express was to allow users to quickly and easily create interactive visualizations while performing exploratory data analysis. I would guess that most people using it for this purpose don’t care too much about how their points are lined up on their scatter plot.
You need to set the color every single time you create a new graph.
# Seaborn
sns.catplot(x = 'Major_category', y = 'Median', kind = 'box', data = df)
plt.xticks(rotation = 90)
plt.show() # Plotly Express
px.box(df, x = "Major_category", y = 'Median', hover_name = 'Major')
You would expect both of these to create very similar visualizations, and they do (for the most part). | https://towardsdatascience.com/plotly-express-the-good-the-bad-and-the-ugly-dc941649687c | ['Reilly Meinert'] | 2019-06-14 22:37:59.678000+00:00 | ['Python', 'Data Science', 'Plotly', 'Data Visualization'] |
Inventing Enemies | It’s easy to imagine a regular season NBA game without fans; playoff seeding or the perceived slight of an opponent are usually all that elevate mid-season contests above glorified pickup basketball. But what about a game that matters? And what about home court advantage? If the NBA decides to finish out the season without real crowds, they should seriously consider ways to enhance the experience not just for the fans at home but for the players as well. “I play for the fans,” LeBron James said recently, before the severity of the situation became apparent around the league, “That’s what it’s all about. If I show up to an arena and there are no fans in there, I ain’t playing.”
It’s not just home fans that matter for the players either. A huge part of the narrative of greatness in sports is tied to how one performs in enemy territory. If you look back to some of the most oft-cited “clutch” performances in NBA history, they often came on the road; Magic in Philadelphia in 1980, Jordan in Utah in 1998, Lebron in Boston in 2012, Klay Thompson in OKC in 2016. The list goes on. There needs to be real fan energy not just for aesthetics, but to push the stakes to another level.
Clutch Performances Often Come on the Road
My former colleagues at Populous have spent their entire careers designing venues that bring people together and I’m very interested to see what they do when challenged with the task of making the fan experience a long-distance relationship. It may not be a question of doing something new but rather absorbing innovations in interactive entertainment that have already been successful. There’s a lot to be learned from online video games, from the way platforms like Twitch engage their audiences to how games like Second Life allow players an open-ended virtual experience in which to interact with others they may not normally be able to reach.
Online Games Provide a Template for Virtual Fans
The NBA seeks out innovation, and as such they have been broadcasting games in Virtual Reality since 2016. During VR broadcasts you can connect with others watching the game and even customize an avatar. Still, the experience seems a work in progress and often utilizes vantages (courtside, directly behind the basket) out of alignment with the typical fan experience. Regarding socializing with others during the game it is not on the level of a Second Life, where anyone who is online is in a space with everyone else who has logged on.
The NBA has Broadcast in VR since 2016
Perhaps the next step in this time of empty arenas is a VR camera in every seat. One could imagine a scenario similar to avatar based online meeting platforms where people can interact with each other in a digitized version of the concourse. To avoid hundreds of avatars running around obstructing the game, when someone enters the seating bowl they immediately find themselves in the seat they purchased a ticket for, next to other fans who purchased tickets for the specific seats next to them. They can watch the game in 360 degrees from their seat and also get the full experience of interacting with those around them in the crowd.
Some might find it hard to believe people would pay not to be courtside, but there are a lot of people right now craving something familiar. If the cost tag of tens of thousands of VR cameras seems prohibitive there is no reason it couldn’t be done with a thousand or a few hundred seats, or only for playoff games that generate more revenue, with the individual VR seats sold at a cost that makes such an endeavor financially worthwhile. And if the idea of spending a higher amount of money for a better virtual seat seems crazy to you, just remember at one point Candy Crush was making $230 million a year solely off in-game upgrades.
Virtual Meetings are Becoming More Prevalent; What About Virtual Fans?
The in-game experience for the players could utilize the same digital interface in a completely different way. Think of something akin to an upside-down planetarium; a large projector sits a hundred feet above the court projecting on to perforated screens with speakers behind them. If you set up the interface so that the fans can use their actual voices like players live streaming on Twitch, and then calibrate the sound so that it correlates to where fans’ avatars are being projected on the screen, suddenly you have real fans surrounding the court making real noise. They would be free to heckle or cheer as much as they would at a real game, their only limitations being the same rules of conduct that they would be held to in person.
A Planetarium Provides the Template
No one is saying any of this would be ideal. But what is these days? The NBA is as creative and innovative as any league out there. They have consistently been at the forefront of not only VR but relaxing copyright restrictions so regular fans can post highlights on websites like YouTube, a policy which has been a huge asset in helping the league grow on social media platforms (people watch 30,000 hours of Steph Curry clips on YouTube every day). The league has already turned tragedy into innovation once this year, paying tribute to Kobe Bryant while experimenting with the “Elam Ending” at the 2020 All-Star game. Now, as the league tries to salvage the rest of the season, it’s not only possible for the NBA to do something significant with virtual fans, it might be more feasible than playing in front of real ones. | https://medium.com/paper-architecture/inventing-enemies-dc653f2b5d63 | ['Dan Edleson'] | 2020-03-18 20:54:32.743000+00:00 | ['Virtual Reality', 'NBA Playoffs', 'Design', 'NBA', 'Coronavirus'] |
To Make Better Decisions | To Make Better Decisions
Assign Rights, Describe Processes, Set Criteria, Experiment
In Does Your Company Know How It Makes Decisions? I pointed out that most people have no idea how decisions get made within their own organizations, and as a consequence the organizations lack decision-making skills. While I claimed that there were better processes available than “consensus,” I didn’t specify what those might be, or how to design them to replace the ineffective, bureaucratic, political waste of energy that constitutes most organizational decision-making processes in American organizations.
Now is a good time to correct this oversight.
What is a decision?
Although people probably make hundreds of decisions a day, few have thought about, or are able to describe, what constitutes a decision. Ask a dozen people in your company, and several of them are going to tell you something like, “A decision is when you make up your mind about something. It’s when you make a choice, from among several different alternatives.”
But choices are prerequisites to a decision. They might provide some satisfaction of relieving uncertainty or anxiety, but they are not decisions.
A decision is an irreversible commitment of resources.
It’s not a decision when my niece makes a declaration at the family holiday picnic, “I’ve decided I’m moving to New York to pursue a new career as an actress!”
Although her relatives might cheer her on and make encouraging noises, until she commits resources (time, energy, money) that create opportunity costs, her declaration is a fantasy, not a decision. To elevate her career aspirations from her imagination to reality, she must make commitments that will be difficult to undo. For example, she might sign a lease on an new apartment and pay a security deposit, strengthening her decision to move. She might audition for roles, committing time, energy, and putting herself at risk of rejection, to strengthen her decision to pursue a new vocation.
Her problem is that making public declarations of intent is much more rewarding, with less effort, than an irreversible commitment of resources.
Too many business managers are like my niece. They fantasize out loud about their aspirations, or make solemn declarations about change, but they never commit resources. They want the temporary satisfaction of a false resolve, so they announce public resolutions that reward their brains with the dope hit of false accomplishment, without incurring the expense, sacrifice, or risks of making commitments.
It’s not a decision until you’ve made an irreversible commitment of resources.
Who in your organization gets to make decisions?
As organizations grow, they become further and further removed from the people who founded them. The problem is that the people who founded the organization have excellent judgment about what constitutes a good idea (or the organization would never have succeeded), and the people who join the organization as it grows do not.
And how did these wise organizational Founders develop their excellent judgment? Typically, by making and learning from many mistakes.
Then, once the organization figures out what’s working and it becomes profitable and growing, the patience for mistakes wears thin, and institutional controls creep in to reduce the possibility of errors. We call these controls “bureaucracy” and it is this system of policies and procedures that constitute and enforce these controls.
Bureaucracies substitute rules for judgment.
The problem with error-minimizing bureaucracies is that so few people in the organization are permitted to make the mistakes necessary to develop their own excellent judgment, as the entire organization becomes preoccupied learning and conforming to the rules.
In bureaucratic organizations, their are few decision makers, because the policies, processes, and rules remove alternatives. For example, in No Rules Rules: Netflix and the Culture of Reinvention (Hastings & Meyer 2020) Netflix CEO Reed Hastings tells a story about an executive at one of Hasting’s earlier companies who was infuriated by a travel policy that refused to reimburse him for a $12 taxi fare.
The travel expense refusal wasn’t a decision made by an individual at the company. It was a rule that absolved any travel account manager from the responsibility of exercising judgment. And there were no compensating rules that empowered anyone in the organizations to override it!
Most bureaucracies do not allow decision making. They operate by approval, in which managers at upper levels review resource allocations to ensure that they comply with policies. Eventually, you get a corporate culture like the one satirized in the 1985 movie Head Office.
To make better decisions, organizations must assign decision-making rights to the people in the organization and foster an environment that encourages them to experiment, make mistakes, receive feedback, and improve their judgment.
Most organizations have no idea how to do this.
For example, the first purchase I made right after I secured my very first National Science Foundation grant was an electric pencil sharpener. I wanted the sharpener so that I could take notes on the manuscripts and books I was reading for my dissertation. Because I wasn’t authorized to make such purchases, I put in a request that was subject to at least four different levels of organizational approval.
These multiple levels of review are intended to avoid fraud and misappropriation of grant funds, which (upon rare occasions) has been a legitimate problem in the past. In fact, almost all purchases at my home University were treated like suspected fraud, no matter who initiated the purchase — because no one in any typical University organization is really authorized to commit $20 to the purchase of a pencil sharpener. We’re only authorized to initiate a series of reviews and approvals of proposed purchase commitments.
By contrast, almost any idiot in a University can call a meeting. And meetings, when you consider the salaries paid to the employees who show up for them, are much more expensive than pencil sharpeners.
To empower people in your organization to make decisions, you must communicate to them the resources they have the right to commit. And not all resource commitments will come with a receipt.
What is your organizational decision process?
After your organization learns to recognize what decisions are, and who within the organization has the right to make them, it’s important to give the people in your organization some guidance regarding how to make good decisions. For example, in Only the Paranoid Survive: Lessons from the CEO of Intel (Grove, 1988) Andy Grove describes the process by which production resources were allocated among different product lines at Intel Corporation.
Production managers at individual production facilities were already empowered to commit resources to either memory chips or microprocessors. To guide their decision, they had information about sales prices, production costs, and gross margins. The managers were directed to make decisions that would increase production of the most profitable products, according to the data available for their factory.
While almost everyone at Intel at the time thought of themselves as memory chip manufacturers first, and microprocessors as an accessory to the memory business, the production managers were getting data telling them that the microprocessors were more profitable. So they allocated additional resources to microprocessors, and fewer to memory, because their decision process was to gather data and reallocate production resources to the more profitable products.
When Grove finally made a commitment to exit the memory business altogether, he discovered that his managers had already put Intel on that path, by shifting the company towards microprocessors. This sped Intel’s transition, and according to Grove, probably saved the company additional losses from the crippling competition in the low-cost memory market.
In other words, Intel already understood that a decision is an irreversible commitment of production resources. They already assigned decision rights to the production managers. And they’d provided sufficient guidance to managers about the decision-making process that when the corporation was faced with what felt like an existential crisis, the managers had already been steering production towards a resolution.
Nevertheless, the Intel example is an oversimplification. To create a more general process for a broader range of decisions, we must understand the two critical dimensions of decision-making: 1) speed, and 2) scale.
The hundreds and thousands of decisions made every day in your company can be organized along two dimensions: 1) speed and 2) scale.
Speed refers to pace of the decision. Some decisions happen fast and frequent, while others take longer. The processes that work well for fast, frequent decisions are different from those work for slower decisions.
Scale refers to the number of people engaged in the decision-making process: individual, group, or larger society. Design processes that work well for individuals will differ form those that work well for large groups.
The two scales relate to one another, as shown in the Figure above. The more people engaged in the decision-making process, the longer the decision typically takes. For example, in the Intel example, the production allocation decision resides in the middle of the figure, near the midpoint between fast and slow, because Intel established a data-driven process that was executed at the scale of small groups of plant managers.
To improve organizational decisions, processes must be designed that apply to fast decisions made at the individual scale, as well as for slow decisions made at the collective scale.
In the lower left-hand corner of the figure, where individuals make instantaneous decisions, processes rely on a sense of identity. For example, a vegetarian doesn’t have to think about whether they’re eating meat today. Because they identify as a vegetarian, they’re just not a meat person.
This is why twelve-step addiction recovery programs begin with the identity statement: “I’m an alcoholic… and my life has become unmanageable.”
The first part of Step 1 is a powerful rational for making the decision to stay sober, while the second part reminds the alcoholic that their current decision-making processes were not working for them and they need new processes that will support their new identity.
Eventually, after weeks or months of practice, better decision making will become a habit.
Because identity is so important to rapid decision making, organizational leaders must make a consistent effort to create a strong sense of identity for those in their organization. This is why we have job titles and descriptions, so that people understand who they are in relation to the organization, and what their role within it is. The stronger their sense of identity, the faster their identify-based individual decisions.
Moving towards the middle of the figure, where policies and rules are found, decisions are made at a larger scale. This is the scale at which bureaucracy operates, and most readers have so much experience with bureaucracy that it’s of little further interest to us now. The key point to remember is that bureaucracy is an attempt to simplify the process of group decision making to make it less expensive and more reliable.
That comes with consequences at slower speeds and larger scales, where bureaucracy no longer functions.
What gets really interesting are judgment, analysis and the social process that couples them: deliberation. To the extent that judgment is about knowing when to break the rules, it stands in opposition to bureaucracy. And it provides room for creativity and innovation.
While I can’t say what sort of creative, analytic-deliberative decision-making process will work for your organization, I can describe for you the processes that work at our little startup company called Morozko Forge. We manufacture the world’s first ice bath. (Our competitors are cold baths, because we’re the first and still the only that reaches freezing temperatures).
Three co-Founders of the world’s first ice bath company: me, Adrienne Jezick and Jason Stauffer. (Photo by Patrick Nissen). The logo on my T-shirt is the Hydra monster, from Greek mythology. It symbolizes the antifragility of deliberate cold exposure, because cutting off one head of the Hydra will cause it to grow two more. It also symbolizes how we apply many brains in our decision-making processes.
The Morozko decision-making process has two important stages. The first is to identify and formulate the problem you are trying to solve. The second is to share lots of ideas and speculate about the consequences in a process we call “What if?”
What problem are you trying to solve (and why is it important)?
When Steve Jobs launched the iphone over 10 years ago, he was explicit about the problem that the iphone solved for mobile phone users. Most people didn’t even know they had a problem… until Jobs showed them the Apple solution.
And that’s the value with asking ‘What problem are you trying to solve?’ Most people are so pre-occupied with their own solutions that they forget what problem they’re trying to solve. They lose their focus. They dilute their efforts, and as a result they wind up with lots of great solutions for problems that don’t exist.
I had an exchange with one subordinate who was two hours into an inventory solution without an understanding of the problem. Instead of asking, “What problem am I trying to solve?” this subordinate (and others) kept researching solutions to problems we didn’t have.
As a start up company, our survival depends upon our ability to identify, formulate, and solve important problems. When we lose track of the problem we’re trying to solve at any particular moment, we’ve lost our path to profitability.
In another exchange, a particularly clever and creative subordinate wanted to show me a new heat exchanger design he had just finished prototyping. He was beaming with his preliminary results, and he wanted to share them and improve the idea further.
But I interrupted him and asked, “What problem are you trying to solve?”
He said, “Oh, I don’t have a problem!”
And I lost my temper, at least a little bit… because all of his creative energy could take us in the wrong direction if he wasn’t able to improve his capacity to identify, formulate, and articulate problems.
I scolded him:
Well, that sucks for me that YOU don’t have a problem, because our future as a startup depends on our ability to identify, formulate, and solve problems that make life better for our customers, and I have about 99 problems I’ve got to attend to, and here you are — one of our brightest and most clever companions — and you can’t find one single damn problem inside our company to be working on?
He laughed.
He understood right away that his enthusiasm for his new solution had caused him to lose sight of the problem he was working on, and that his response was a reflex instead of an explanation.
When we use the prompt, “What problem are you trying to solve?” we sometimes activate an emotional, defensive response. As children, we learn that teachers, parents, bullies, and other authority figures will threaten us with the challenge:
What’s your problem?
Many of us learned to avoid conflict and confrontation by saying, “I don’t have a problem,” and that’s exactly what my subordinate found himself doing when he was trying to present his new prototype. In fact, this type of conflict-avoidant behavior is exactly why most organizations suffer from a failure to identify and formulate important problems.
In this case, my clever engineer regained his composure, restarted his presentation with “The problem is that our units take too long to cool down in hot Phoenix summers, wearing out our compressors and disappointing our customers.”
Now that’s a problem for which I have a lot of patience and creative energy!
What if?
After we understand the problem we’re trying to solve, it’s time to generate solutions. It’s OK if we start with crappy solutions, because each idea could lead to a better one.
One of the things that is a comfort to me when brainstorming for new solutions is reminding myself:
My first idea is rarely good enough.
By asking, “What if… ?” we think through the consequences of of different alternatives. We’re simply speculating at this point. We’re creating thought experiments about what would change in the world if we implemented whatever idea it is that we’re asking about.
For example, we had a leaky tub that defied our usual troubleshooting and repair protocols. So we ran a series of “What if … ?” thought experiments. It sounds like this:
What if we threw the tub away and started with a new one?
If we threw this tub away and started with a new one, we would save ourselves hours of head-scratching, we would finish producing the unit faster, we would increase our materials costs by about $110, and we would never learn about what was causing the problem and how to prevent it.
What if we used Liquid Nails Fuze-it to seal all of the seams from the inside?
If we used Liquid Nails Fuze-it to seal all the seams from the inside, it would take us an hour to apply the seal and retest the tub, and we might discover a reliable way of repairing leaky tubs and save ourselves from having to purchase a new $110 tub.
(This experiment sounded good enough to try, but our brainstorming process doesn’t stop there. We often keep going, just to see if we could improve upon the idea).
What if we used aluminum impregnated nitrile rubber to seal all the seams from the inside?
If we used aluminum impregnated nitrile rubber sealant to seal all the seams from the inside, it might take several hours for the sealant to cure before we could retest the tub, and we might discovery a reliable way of repairing leaky tubs and save ourselves the expense of having to purchase a new $110 tub.
(We decided to use both the Fuze-it and the nitrile rubber in separate experiments. The Fuze-it was faster, cheaper, and worked great!)
The whole point to asking “What if… ?” is to generate enough solutions to ensure we might find one that is good enough. Only by describing the consequences of the solution, rather than judging it, can we come to understand what a world with that solution in it might look like to us.
After a few years of implementing the “What if… ?” protocol, I’ve discovered that the most common mistake is short cutting the process by misinterpreting the question as a command.
When your subordinates respond to your “What if… ?” by saying, “OK, I’ll do that,” they have removed themselves from the decision process. And that’s going to result in a lot of inferior decisions.
By what criteria will you assess the quality of different solutions?
Once you’ve described the consequences of different “solutions”, it’s important to understand which to experiment with first. To prioritize each, we must understand the criteria by which we assess our resources commitments.
Thus, we ask ourselves a series of questions, in the following order:
Will this experiment result in new knowledge? (I.e., what might we learn?)
At this stage of our start up, knowledge is the single most important resource we have. It could be knowledge of technique, such as how to repair a tub. It could be knowledge of the market, such as customer preferences and values. It could even be knowledge of one another, and specific strengths each brings to our company.
If the experiment will create new knowledge, it becomes a high resource priority.
Will this experiment take care of our customers?
The entire point of our health and wellness company is to help people take better care of themselves. Experimenting with solutions that come at the expense of our customers is antithetical to our mission, so that doens’twon’t work for us. No one is going value a health and wellness company that does not provide knowledge and equipment for taking care of health and wellness. That doesn’t mean we do everything for our customers, because caring for our customers means empowering them and we sometimes struggle to make the distinction between caring for and doing for. Nevertheless, this question prompts us to consider how our proposed solutions might impact our customers, because:
“The purpose of business is to create customers. — Peter Drucker.
Will this experiment take care of our companions?
To enable our customers to better care for themselves, we must exemplify taking care of ourselves. Put another way, without caring for ourselves, we cannot expect to be able to care for our customers. Solutions that come at the health and wellness expense of our companions will undermine our capacity to provide the necessary knowledge and equipment to our customers, and undermine our credibility in the marketplace.
Will this experiment conform to our vision of the future world in which we want to live?
Responses to this question require clarity about the future vision of the company and the change we seek to make in the world. For us, that vision includes a world that is free from Type 2 diabetes, free from Alzheimer’s, free from obesity, and free from all the maladies of modern living.
The mission of Morozko Forge is to provide the knowledge and equipment necessary to live a natural life in an unnatural world.
Not every decision we make will be on direct path towards that vision, and that’s OK. We’re not asking for the shortest path, or the best path, or even the quickest path.
When we ask whether an experiment conforms to our vision, we’re seeking to clarify our vision and the space within it for the experiment we’re contemplating. Sometimes, we won’t know the answer to this question until we run the experiment.
And other times, asking this question makes it clear that the experiment will not take us closer to the future world we seek, in which case we discard the experiment.
Might this experiment generate more resources than it consumes?
In this final question, we’re finally getting to what MBA programs might call “return on investment” — but don’t think that means we’re reducing the answer to a financial spreadsheet.
Although money is important to the health of our company, at this stage of our venture, our creative energy is even more important.
So what we’re prompting in this question is a multi-dimensional examination of the resources we’re committing to a decisions in terms of energy, time, and money, relative to the return we will realize in all three of those resource categories. When we make resource commitments that generate more energy, more time, and more money, we accumulate the resources we need to grow our venture.
Every decision is an experiment
Although I’ve described a decision as an “irreversible commitment of resources,” that doesn’t mean we can’t make a different decision later. It only means that the resources we’ve committed to the previous decision can’t be recouped.
A new decision might commit additional resources to undo the previous decision, and that’s OK — even if it gets expensive sometimes.
Thinking of everything decision as an experiment gives us the freedom of being wrong without the anticipatory anxiety of regret.
In Designing Your Life (2016) Stanford Professors Bill Burnett and Dave Evans encourage readers to think of commitments as experiments that allow trying new things, learning, and trying again. They argue for the application of what’s typically called “design thinking” to personal and career choices.
The difficulty with this type of thinking is that you’re always going to be wrong. When you’re trying new things, you can hardly ever get it right the first time. For many, the imagined humiliation of being wrong is so painful that they’ll never do the experimenting that continue their learning. As a result, people get stuck in old patterns, old habits, and failed “solutions” that stopped working long ago — while their energy is midirected into defending themselves against the nagging suspicion that they might bear some responsibility for their own failures.
The antidote is to stop worrying about being right, and to focus instead on what you have to do to be successful.
At Morozko Forge, talking about every decision as an experiment releases us from the ego investment in being right. It helps dissolve the anticipatory anxiety of being proved wrong, and managing that anxiety is essential for the growth of our venture.
When we think in terms of experiments, rather than in terms of answers, it refocuses our energy on our most important decision question, “Will this experiment result in new knowledge?”
That’s how our organization makes decisions, by:
Assigning decision rights,
Describing decision processes,
Setting criteria for evaluating alternatives, and
Running experiments.
I wonder if your organization might benefit from adopting some of the same practices? | https://medium.com/morozko-method/to-make-better-decisions-40bbf57fe46 | ['Thomas P Seager'] | 2020-11-14 00:18:46.173000+00:00 | ['Creativity', 'Decision Making', 'Innovation', 'Entrepreneurship', 'Small Business'] |
What To Look For In A Graph | A Machine Learning Engineer who needs to figure out distributions of features to create better models, or a Platform Engineer who needs to monitor the platform for metrics like requests per minute, needs to draw and understand graphs.
Knowing what graph works in which situation can make it easier to depict stories through graphs. Today there are so many graphs out there, selecting one can become an overwhelming task.
The goal of this article is to understand how based on specific type of data we can choose a specific type of graph and what information we can infer from that graph. This enables the reader to quickly infer vital information from a graph and to know which graph to use just based on the type of variables.
This article is written keeping in mind what information a machine learning engineer or data scientist will try to infer from some give data. Even though it is useful for anyone who want to know what graphs to draw in which scenario or how to understand the basic graphs.
Contents
Types of Variable (Categorical, Quantitative)
Scale of Measurement (Nominal, Ordinal, Interval, Ratio)
Examining Distributions (Pie Chart, Bar Graph, Histogram, Box Plot)
Examining Relationships (Side-By-Side Box Plot, Scatter Plot, Two Ways Table, HeatMap)
Conclusion
Types of Variable
Categorical Variables: According to Wikipedia A categorical (qualitative) variable is a variable that can take on one of a limited, and usually fixed, number of possible values , assigning each individual or other unit of observation to a particular group. For example Smoking is a categorical variable which can categorize a person into two groups one that smokes and other one that doesn’t smoke. Gender and Race are also categorical as a person can belong to one of a given set of values. Zip code is a categorical variable as it categorizes geographic location.
According to Wikipedia A categorical (qualitative) variable is a variable that can take on , assigning each individual or other unit of observation to a particular group. For example is a categorical variable which can categorize a person into two groups one that smokes and other one that doesn’t smoke. and are also categorical as a person can belong to one of a given set of values. is a categorical variable as it categorizes geographic location. Quantitative Variables: Are the variables that represent some kind of measurement and take numerical value. Example can be Age, Weight and Height of a person.
An easier way to recognize if a variable is quantitative is to see if it represents some form of measurement while having numeric values, which is not the case with categorical variables. Otherwise there is no restriction on categorical variables to not to have numerical values or have a small set of possible values as is the case with Zip code. Even though it’s numerical and hence can be added, subtracted or sorted it doesn’t represents any ordinal behavior but just the locality to which a person belongs.
Scale of Measurement
Nominal: is a qualitative (categorical) measure that uses discrete categories to describe a characteristic. For example: citizenship, religious affiliation, and marital status . Even though these can be represented by using numbers these don’t have and way to be ranked or ordered.
is a qualitative (categorical) measure that uses discrete categories to describe a characteristic. For example: . Even though these can be represented by using numbers these don’t have and way to be ranked or ordered. Ordinal: ranks or orders participants on some scale or attribute, but the difference doesn’t convey fixed or equal differences. For example condition of a car . It can be Very Good, Good, Okay, Bad.
ranks or orders participants on some scale or attribute, but the difference doesn’t convey fixed or equal differences. For example . It can be Very Good, Good, Okay, Bad. Interval: takes numerical form and the distance between pairs of consecutive number is equal. For example temperature .
takes numerical form and the distance between pairs of consecutive number is equal. For example . Ratio: is similar to interval scale, the major difference is how we interpret a value of zero. For ratio measures the zero is meaningful and tell us that the attribute is absent in the participant. For example number of people having polio in India.
Examining Distribution
Examining distribution has two components
What values the variable takes
How often the variable takes those values
Categorical Variable
In case the data we have contains categorical variable, for example the data in the below image, which show a snippet of data of car and brand to which car belongs to, In some vintage car store.
Categorical car brands data
In such a dataset what we look for is the frequency distributions of the categorical variable. As that answers the category imbalance that we might have in our data.
In this case the graph we go for are the following:
Frequency Distribution of Cars
A Pie chart is useful in describing the frequency distribution. The area covered by one color shows the dominance of that category in the dataset. Additional information like Name and percentage of the category can be useful to show. Looking at the above graph we see that The parking lot has 53% cars with brand Mercedes.
Frequency Distribution of Cars
In a bar graph x-axis usually represents the categorical labels and y axis will represent the numerical term associated with it. Which is the frequency in this case. The bars that are higher will show the dominant category in the dataset.
Quantitative Variable
In case the variable is quantitative, we usually have values over a large range and it’s not possible to create frequency distribution for each individual value. So we create bins for it and then those bins represent categorical variables for which the histogram can be drawn. An example of quantitative variable is shown in the following graph.
Example of Quantitative Dataset
We can define a set of intervals to represent a grade for those marks which will look like:
Bins for Student Marks
Histogram of Student Grades
Histogram even though is just a bar chart, is different as we didn’t represent the values we were given on the X-axis but created bins and then represented the frequency distribution of those bins. In some places it might be clear on how many bins make sense or the bins can be predefined. But in some places this can be experimented with or let alone for the plotting libraries to decide based on some mathematical formulation. To checkout variations in histogram/distplots checkout histogram and distplot.
The information we can infer from a histogram is the following:
Shape
Shape of a histogram has two things to look for:
Skewness: If the distribution is left skewed, right skewed or symmetric.
Symmetric
Symmetric distribution in real word can be seen when measuring heights of students in a class. Where majority of students will exist within some specific range with some exceptions on either side.
Left Skewed
Left skewed distribution will have most of the data towards the right end. A real world example of this kind of distribution is the age of death from natural causes. Most such deaths happen at older ages.
Right Skewed
In skewed right distribution the most of the data is at the left end. A real world example of this is salaries of people. Most people earn in lower ranges while a few have very high salaries.
By knowing the skew we can decide from which side we want to remove the outliers for a given set of data. If we remove data from both sides of a distribution when the distribution is skewed we might end up removing useful data and as a consequence the models trained might not generalize well.
Modality: the number of peaks the distribution has.
Bimodal Graph (2 peaks)
Any graph with more than 2 modes is known as multimodal
The graph above has two peaks and in real world can come up while looking at distribution of money spent by people at an e-commerce website. The use of this information is to create various segments of users which can be targeted using different ranged recommendations in term of prices.
Outliers
Outliers are the observations that fall outside the overall pattern.
Outliers
Center
Center is the midpoint of the distribution. Center is expected to divide the distribution into approximately two equal parts. Mode, Mean and Median are the three measures of center. The point to remember is that Mean is highly sensitive to outliers but median is almost unaffected.
Spread
Spread of the distribution is described by the approximate range covered by the data. Measures of Spread include Range, Inter-quartile range (IQR) and Standard deviation.
Let’s see what Inter-quartile range is, as its the measure we will need for understanding the upcoming graph. The IQR is the first quartile subtracted from the third quartile. And what first quartile represents is the point on the x-axis which has 25% of data on the left side and 75% of the data on the right side. The third quartile represents the point on x-axis which has 75% of the data on the left side and 25% of the data on the right side of it. So IQR represents the range in which 50% of the data around the median lies.
IQR And Range of Dataset
IQR can help us detect outliers. A general rule of thumb know as 1.5(IQR) Criterion is that:
An observation is considered a suspected outlier if it is:
Below Q1–1.5(IQR) or
Above Q3 + 1.5(IQR)
In the above image (Min, Q1, Median, Q3, Max) gives us a quick numerical description of both center and spread of the distribution which brings us to the next graph which can show that.
Box Plot for Distribution of Sepal Width
The information in the above graph is based on the data which looks like:
Histogram of Sepal Width
We will revisit box plots later explaining how it is even more useful while examining relationships.
Examining Relationship
Examining distribution is based on a single variable, whereas relationship is between two variables. We will explore three cases which are
One variable is Categorical and other is Quantitative
Both variables are Quantitative
Both variables are Categorical
Categorical-Quantitative
The following image shows a snippet of Iris dataset which represents three categories of Iris flower and also their sepal and petal dimensions.
Iris Dataset
Let’s try to find the relationship between sepal_width and species.
Side by Side Box Plots:
Side by Side Box Plots
Once we know what a box plot represents we can use the box plots side by side to let us see how distribution of sepal_width varies in the three varieties of flower. Based on the above graph one can see some patterns, like setosa on average have much larger sepal widths as compared to others.
Quantitative-Quantitative
When both variables are quantitative for example the sepal_width and sepal_height in the above Iris dataset, we can use scatter plot.
Scatter Plot petal_width vs sepal_width
Scatter plot shows a relationship between sepal_width and petal_width. Based on this one can create regression line to see a potential trend in the two variables which shows that as sepal_width increases the petal_width also shows increase.
Scatter plot in the most basic form has become a thing of past. Usually it is accompanied with regression lines showing possible trends, with boxplots showing the distributions of the variables plotted along axis. With labeled points(Usually colors are used to label different points on the graph) The graph below shows an advance version of scatter plot.
Hybrid Scatter Plot
Categorical-Categorical
In case both variables are categorical. The hypothetical example below shows an example of that:
Flower Gender and its Species
Two Way Table
In a two way table each cell contains the value for the intersection of two categorical attributes. for example there are 21 Male Versicolor type Iris flowers in our dataset. If both variables are categorical, their counts/percentage can shown in a two way table to clearly show the relationship between those.
Heat Map
If the number of categories is large it might take a lot of time to read through the numbers, in those cases a heat map can be used which displays this information using colors of cells making it easy to find ranges of interest or unusual patterns. Like in this figure Male-Setosa flowers are the least represented category in our dataset. The color map on the right shows the number associated with a specific shade of color.
Conclusion
Above I’ve shown a way to infer based on types of variables how one can decide the type of graph one might want and what insights one can find in those graphs. This set represents only a basic set of graphs that are available out there. Those graphs are mostly some form of modification of the above described basic graphs which are used to show some extra information.
One should be careful while using those graphs as having too many insights within the same graph instead of summarizing the point might just confuse people.
It is better to use multiple graphs which visualize some insights at a time and then try to conclude the entire set of insights using some hybrid version of graphs.
Using basic graphs also has a benefit that most people will know how to read those and hence it’s easier to propagate information without having to attach some long documentation that just represents the same information that we wanted the graph to depict in words, completely deferring the point of having a graph. If the graph isn’t self explanatory, then it’s pointless to have it. | https://medium.com/ai-in-plain-english/what-to-look-for-in-a-graph-5c2cf85c7446 | ['Kartikeya Sharma'] | 2020-12-28 16:40:40.399000+00:00 | ['Machine Learning', 'Python', 'Artificial Intelligence', 'Data Science', 'Data Visualization'] |
How Amazon Plans to Take Down SpaceX | Space Is the Only Way to Go
On several occasions Bezos has expressed the view that mankind must inevitably move into the heavens. His vision — outlined in a speech in 2019 — paints a future of mass industrialisation of space. Instead of polluting and destroying our fragile world, he wants factories placed in giant orbiting hubs.
Bezos imagines humanity will leave the Earth as well. But unlike others, who picture colonies on Mars or on the Moon, he believes we will construct gigantic habitats in space. These structures, first imagined by physicist Gerard O’Neill, could be perfectly adapted to human life. Unlike planets, which by nature are limited in size, an almost endless supply of habitats could be built.
In this vision of the future, the pressure we currently place on the Earth would slowly be lifted. As manufacturing moved off-world, pollution would fall. As people migrate to new habitats in the heavens, wildlife could reclaim our planet. Eventually the Earth would become a massive park, and humanity would become truly space-borne.
What Bezos imagines is vast in scale, a revolution comparable to the dawn of agriculture thousands of years ago. Even with huge wealth and the vast resources of Amazon, Bezos will not be able to do it alone. His aim, at least for now, is to the take the first few steps down the road towards that future. The launch of New Shepard in 2015 was the first, small, step along the road. Now he has bigger steps planned.
Take Blue Origin first. Since 2015 the company has continued work on New Shepard. They have now made a dozen sub-orbital flights, and hope to soon demonstrate that the capsule can carry paying passengers to the edge of space. The real prize, of course, is building an orbital rocket — and with New Glenn, a new design, Blue Origin believe they have that.
Building an orbital rocket is hard. Only one private company — SpaceX — has ever managed to do so. Despite at least eight years of development work Blue Origin still have not flown New Glenn, though they claim to be close to a launch, perhaps as soon as 2021. Like SpaceX, Blue Origin hope to one day carry astronauts onboard, taking them to orbit, and even beyond.
To that end Blue Origin have announced another secretive project: New Armstrong. Though little is known about the project, it would appear to be a lunar rocket of some kind. That guess is backed up by Bezos’ publicly stated ambitions to reach the Moon. In 2019 he unveiled a planned lunar lander named Blue Moon, now under consideration by NASA for use in any American return to the Moon.
Blue Moon: a vision of how Jeff Bezos may one day send deliveries, and astronauts, to the Moon. Image by Blue Origin
The Second Path to Space: Amazon
Blue Origin is a separate company to Amazon. It sells no products, and makes no profit. The company is funded privately by Jeff Bezos, reportedly costing him more than a billion dollars every year. And though it has had some success in reaching space, it has not achieved as much as Elon Musk has with SpaceX.
Through Amazon, though, Bezos has a second lever to push his goals in space. And though the company has so far revealed little about its intentions, it has made several interesting announcements. Most notably the company has announced plans, named Project Kuiper, to launch a constellation of satellites. Officially the aim is to expand Internet access, especially among the poor. But this is probably not the only reason Amazon is suddenly interested in the heavens.
The business case for large satellite constellations remains unproven. Previous attempts at building such constellations — by Iridium, Teledesic and Globalstar — failed miserably when faced with the high costs of putting thousands of satellites into orbit. Several recent attempts have stumbled at the same hurdle. OneWeb recently suffered bankruptcy, and others like LeoSat have long since faded away.
Jeff Bezos does not seem to be afraid of the huge capital investment, or even of running a satellite internet service at a loss. If instead the constellation serves as a means to drive data and customers towards Amazon’s computing platform, it may be worth the costs. If it can serve his other ambitions in space, and perhaps provide Blue Origin with a dedicated customer, even better.
Both Amazon and Microsoft are already building ground stations near their data centres. They aim to transfer data from orbit to their computing clouds as fast as possible. It is clear both companies think large amounts of data will soon be flowing through satellite networks, and they each want to capture as much of this market as they can.
Much like computer infrastructure, satellites don’t directly earn revenue for their owners. Their value lies in the data they collect or transfer, and especially in processing that data. One clue that Amazon is thinking in this direction comes from Earth, a set of tools provided through Amazon Web Services that handles processing of Earth observation data.
Satellites can capture vast amounts of data. The hard part is getting it back to Earth. Photo by NASA on Unsplash
To Know the Future, Watch the Data
The idea is simple. Amazon, or rivals, can provide powerful data processing tools through their cloud platforms. Satellite networks, together with strategically located ground stations, help them rapidly collect and transfer data into the cloud. Stop thinking about satellite broadband as a way of connecting the world, then, and start thinking of it as a massive new way of gathering data.
More speculatively, Amazon could even treat its satellites as a service. Instead of needing to launch a constellation of satellites to collect datasets, could you just rent sensor time on an Amazon satellite? If Amazon is regularly launching satellites, could you just pay them a nominal fee to carry your device to orbit?
If this succeeds, if the cost of getting an instrument into orbit falls to almost nothing, then we may see huge volumes of data following back to Earth. Everything from weather monitoring to movements of ships, aircraft and cargo containers could potentially be watched, recorded and processed through Amazon offerings.
This is, so far, just speculation. Amazon has revealed very little publicly about its plans for satellite constellations, though senior figures at Amazon hint they are thinking in this direction. Regardless, as more and more satellites go up, and constellations grow ever larger, it’s hard not to imagine something similar happening.
The elephant in the room is, of course, SpaceX. By all appearances they are far ahead of Amazon and Jeff Bezos. SpaceX have already launched astronauts to the International Space Station, and placed hundreds of satellites into orbit. Amazon, by contrast, seem to have hardly moved off the drawing board. Can they really compete?
Amazon has two big advantages over SpaceX. They have more money, with annual revenues that dwarf anything SpaceX can claim. They also have more existing infrastructure. If Amazon can make space all about data, their existing platforms will make them the clear winner, even if they are slow to get started.
Jeff Bezos though, is undoubtedly thinking bigger. New Shepard, Blue Origin, Blue Moon, Project Kuiper. All are just the first steps along a path towards revolutionising our way of life. That revolution may not happen for decades, or even centuries. But Bezos is determined to give humanity the push it needs to get moving. | https://medium.com/discourse/the-new-space-race-is-all-about-data-5e1b757e04a7 | ['Alastair Isaacs'] | 2020-12-18 03:08:45.096000+00:00 | ['Space', 'Technology', 'Amazon', 'Data Science', 'Future'] |
Monitoring with JMX: How to Integrate Tableau Server with InfluxDB | Concurrent VizQL Sessions from JMX in InfluxDB/Grafana
Telegraf is a great tool to collect information from thousands of different sources, but sometimes you need to complete it with other tools due to source limitations. One of these cases when we want to get monitoring and/or performance information from applications using Java Management Extensions API — an API exclusive for Java VMs — where the client must be written in Java too.
This the second part of the Grafana/InfluxDB monitoring series, focusing on collecting JMX metrics from 3rd party applications like Tableau Server. The previous post can be found here.
We have two options: use Telegraf’s Jolokia2 plugin, or use a standalone JMX agent: jmxtrans. Jolokia2 (a JMX-to-REST-API gateway) is a great solution in case we need to monitor local processes, however, to use it for remote monitoring it has to be deployed in a web container (like OSGi, Tomcat, Jboss). For these scenarios using jmxtrans is more straightforward: it can monitor multiple JMX/RMI endpoints and feed the results to time series databases such as InfluxDB.
Monitoring Tableau Server using its JMX API
Tableau Server containers and most parts of their application are written in Java, thus it was a natural decision from the Tableau engineering teams to make their internal, performance metrics available in JMX/RMI. You can get information about current active sessions in each service, cache/hit ratio in the VizQL servers among many other metrics.
Enable JMX in Tableau Server
To enable JMX ports in Tableau Server, use the following tsm commands:
$ tsm configuration set -k service.jmx_enabled -v true
$ tsm pending-changes apply
After the configuration is deployed, you can check the JMX ports for each service:
tsm topology list-ports | grep jmx[^\.]
These ports are dynamically allocated, so it is advised to set them manually to a fixed port as described here.
Now our Server is ready to serve us with JMX metrics.
Understand our Server JMX Domains, MBeans, Attributes and values
Before we set up jmxtrans to collect JMX metrics, we need to understand what are the available attributes in each service. Some people like to use jconsole for this purpose, I personally favor command-line tools like jmxterm .
Let’s pick one of the vizqlserver JMX ports from list-ports ‘s output and connect to it:
wget https://github.com/jiaqi/jmxterm/releases/download/v1.0.2/jmxterm-1.0.2-uber.jar
$ java -jar jmxterm-1.0.2-uber.jar
Welcome to JMX terminal. Type "help" for available commands.
$>open localhost:8789
#Connection to localhost:8789 is opened Welcome to JMX terminal. Type "help" for available commands.$>#Connection to localhost:8789 is opened
We are connected to our vizqlserver JMX service, how exciting it is. The first thing we can do is to list all domains using domains command:
$>domains
#following domains are available
Catalina
JMImplementation
Users
com.sun.management
com.tableausoftware.instrumentation
java.lang
java.nio
java.util.logging
org.apache.commons.pool2
tableau.health.jmx
Catalina domain contains tomcat related information, we have a few JVM related domains too, but tableau.health.jmx is the one what we are looking for. Let’s have a closer look, what beans do we have in it:
$>beans -d tableau.health.jmx
#domain = tableau.health.jmx:
tableau.health.jmx:name=searchservice
tableau.health.jmx:name=vizqlservice
We have two beans in the service, one for searchservice and one for vizqlservice. To see what attributes we have inside vizqlservice bean, use the info command:
$>info -b tableau.health.jmx:name=vizqlservice -t a
#mbean = tableau.health.jmx:name=vizqlservice
#class name = com.tableausoftware.health.performancecounter.jmx.JMXMonitoringView
# attributes
%0 - PerformanceMetrics (javax.management.openmbean.CompositeData, r)
It has one attribute called PerformanceMetrics . We are getting close, the last step is to get the actual values from this bean attribute:
$>get -b tableau.health.jmx:name=vizqlservice PerformanceMetrics
#mbean = tableau.health.jmx:name=vizqlservice:
PerformanceMetrics = {
ActiveSessions = 0;
Bootstraps = 0;
BootstrapsDeferred = 0;
BootstrapsDeferredThenPerformed = 0;
DataserverInserters = 0;
DataserverLockedSessions = 0;
[...]
VisualModelCacheHits = 0;
VisualModelCacheMisses = 0;
VisualModelCachePartialHits = 0;
WorkbookAttributesParseCacheHits = 0;
WorkbookAttributesParseCacheMisses = 0;
};
These metrics are extremely important in case we want to understand how our Server performs. Since these metrics are stored in these processes’ memory, we do not have to go into the Postgres repository and collect these data with costly SQL queries — everything is a matter of milliseconds.
Now we just have to collect some of the important metrics and store them in our InfluxDB.
Sending metrics to InfluxDB with jmxtrans
You can use rpm to install jmxtrans on Centos, otherwise, you can follow the install instruction on the page.
sudo rpm -Uvh https://repo1.maven.org/maven2/org/jmxtrans/jmxtrans/271/jmxtrans-271.rpm
Configuration files are stored under /var/lib/jmxtrans folder. Let’s create a new file called /var/lib/jmxtrans/tableau.json with the following contents (sample config for one vizqlserver and one backgrounder processes):
If all set, we can start our JMX service:
sudo service jmxtrans start
Results in Grafana
If we log in to our grafana instance (the one what we configured in my previous blog post), we can start consuming the results:
We have tons of vizqlservice metrics available for our dashboards
In the next parts, we will build an execd based input plugin for telegraf to collect additional, non-standard metrics (using TSM API in our case), then put everything together in a nice monitoring dashboard.
Questions? Comments?
Did this help? Or something is not quite right? Or you need help to set it up on your end? Just drop a comment below. | https://medium.com/starschema-blog/monitoring-with-jmx-how-to-integrate-tableau-server-with-influxdb-d99e87119750 | ['Tamas Foldi'] | 2020-12-15 12:26:05.765000+00:00 | ['Data Engineering', 'Jmx', 'Influxdb', 'Tableau Server', 'Dataviz'] |
Meet the Mormon Transhumanists Seeking Salvation in the Singularity | Michaelann Bradley was living the good Mormon life. A faithful member of the Church of Jesus Christ of Latter-day Saints, Bradley had moved from Texas to Provo, Utah, the fervent epicenter of Mormon culture, to attend Brigham Young University. At church, she played the organ, taught Sunday school, and often served in leadership roles in her congregation.
Bradley was “living by the Spirit” — a practice she learned as a young girl and refined during her time as a missionary in Switzerland. In everyday situations, she would pause and reflect, trying to intuit what God would want her to do: Did he want her to take the long way home from campus? Who should she assign to look after a member with unique needs in her congregation? She felt guided.
Until she didn’t.
The crisis came during her senior year of college when she felt the spirit pushing her to marry someone she sensed was a bad fit. He was abusive, and she knew that if she married him, it wouldn’t end well. “I had to make a decision between what I knew was best for me and what I thought God expected of me,” she said. The disconnect pained her, but she told God no.
“I remember praying, telling God, ‘It’s my eternity, not yours,’” she said. The decision drove a wedge between her and God — and between her and other Mormons, who she felt didn’t understand her doubts. So she quietly wrestled with God alone for years.
“I used to have this magical view of God, and then those views were shattered,” Michaelann Bradley said. “Then Mormon Transhumanism came along, and has been an anchor for me. We don’t know if heaven exists, but we can make it.”
In 2013, Bradley met her future husband, Don, at an academic scripture study group. He was a thoughtful historian 18 years her senior whose own faith in the LDS Church had been shaken years before. Many of their early dates were to “Mormon-adjacent gatherings,” Bradley said, so she hardly batted an eye when Don invited her to a meeting of the Mormon Transhumanist Association. He billed it as a group of thoughtful folks tackling slightly different ideas about Mormonism. “I thought he meant ‘transcendentalist,’” Bradley told me. “I came prepared to talk about Thoreau.”
The meeting was as far from Walden as the moon or a terraformed Mars. Held in a local tech entrepreneur’s basement, it was a philosophical free-for-all of ideas that were closer to science fiction than scripture. The 10 other attendees — all male, all white, all in their 20s and 30s, and mostly with backgrounds in computer science or the tech world — batted around theories that reframed deeply held Mormon beliefs, like the notion that “As man now is, God once was; as God now is, man may become,” in terms of cryonics and the singularity. They quoted futurists in the same breath as Latter-day Saint Apostles and Carl Sagan. They asked whether we could become like God through technology — could we live forever now and not just after we die?
Scratch the surface, and you’ll find that Mormon transhumanists believe the coming leaps in science and technology will help us realize the Mormon promise of achieving perfect, immortal bodies and becoming Gods.
With nearly 1,000 members, the Mormon Transhumanist Association, or MTA, is a growing offshoot of the broad transhumanist movement, which believes that the human race can evolve beyond its current mental and physical state through the use of science and technology in order to achieve breakthrough outcomes in the near future. Think: uploading your brain to the cloud or freezing your body in order to resuscitate in an era of immortality. Championed by innovators like Google’s head of engineering, Ray Kurzweil, and Elon Musk, the idea has taken hold with a generation of techno-libertarians and others looking for solutions to — or just an escape hatch out of — a failing world.
Mormon transhumanism takes those theories and molds them onto a religious framework, where technology and science are tools to further the work of Jesus Christ. There are straightforward applications, like using cybernetic limbs to help injured and disabled people to walk or laser cataract procedures to help people with low vision to see. But scratch the surface, and you’ll find that Mormon transhumanists believe that science can bring about the “realization of diverse prophetic visions of transfiguration, immortality, resurrection, renewal of this world, and the discovery and creation of worlds without end.” They believe the coming leaps in science and technology will help us realize the Mormon promise of achieving perfect, immortal bodies and becoming Gods.
Bradley left her first meeting of the MTA buzzing. For the first time in a long time, she felt at home with her doubts. Here was a group of people “thinking really hard about what it means to have faith and what it means to believe in science and logic,” she said. No idea was taboo. Skepticism and doubt were part of the discourse. “It was invigorating,” she said. | https://gen.medium.com/meet-the-mormon-transhumanists-seeking-salvation-in-the-singularity-a7e3784d6c04 | ['Erin Clare Brown'] | 2019-09-27 00:48:26.490000+00:00 | ['Mormon', 'Reasonable Doubt', 'Transhumanism', 'Future', 'Religion'] |
7 Quotes by Albert Einstein That Will Change How You Think | Albert Einstein is considered one of the smartest people in history. So smart that after his death, the pathologist who inspected his body stole his brain.
Thomas Harvey took Einstein’s brain even though the genius clearly stated that he didn’t want his brain or body to be studied after his death.
And even though it turned out that Einstein’s brain was really different from the majority, his genius wasn’t always obvious.
When he was young, Einstein’s parents even thought that he was disabled because he was slow to learn and didn't talk until he was four years old.
Yet he became obsessed with science at the age of five when his father showed him a compass for the first time. In the following decades, he didn’t only develop the theory of relativity and several other inventions that changed the way we see and experience the world but also left us with wisdom on how to live better lives. | https://medium.com/age-of-awareness/7-quotes-by-albert-einstein-that-will-change-how-you-think-6b898c3af6ee | ['Sinem Günel'] | 2020-10-21 14:58:33.837000+00:00 | ['Creativity', 'Education', 'Psychology', 'Advice', 'Inspiration'] |
The Hidden Connection Between Habits and Learning | Learning and habits seem like to separate facts about our psychology. Learning is about knowledge, information and skills. Habits are about routines, behaviors and actions.
However, I think the two actually work on mostly the same principles of the brain, and recognizing this connection can help you both learn better and form better habits.
Learning = Habits
To see the connection, let’s start by asking what a habit is. A habit is a semi-automatic behavioral response, given a certain set of cues in the environment. In other words, when you say you have a habit you mean something of the form “Whenever X happens, I do Y.” Examples:
I go to the gym every day = “Every day after work, I go to the gym.”
I don’t eat meat = “Whenever there’s meat in something, I don’t eat it.”
I have a reading habit = “Whenever I have free time, I tend to read (as opposed to something else)”
Informally, habits can be more complicated than a 1:1 association. A regular exercise “habit” may, in fact, be multiple such associations of varying complexity, for instance:
“When I plan my day, I always put in exercise.”
“If the day is nearly over, and I haven’t exercised yet, I exercise.”
“I go after work, except if I have other activities, in which case I go in the morning.”
Although some habits are actually just a simple cue and response, most are complex, dealing with specific sub-cases and having rules for certain situations that get embedded so they work most of the time. A habit doesn’t need to be 100% coupled to count, either. A voracious reader may not have a habit that says “whenever X happens, I must read,” but simply a tendency to read more when there’s spare time.
Learning, it turns out, is almost exactly like this. To learn something means you produce some kind of response (mentally or physically) when given a set of cues. Examples:
I know the capital cities of every state = “When state X is mentioned, in context of asking for the capital city, I produce the correct city, Y.”
I can speak Chinese = “When someone speaks to me in Chinese, I produce an appropriate response.”
I can ski downhill = “When I’m falling down on my skis, my body automatically produces the motor actions that will get me to the bottom safely.”
This may sound hand-wavey, because these examples are so much more complicated and nuanced than simple habits. But as I mentioned before, habits are also often quite complicated, with varying responses for different situations and sometimes only probabilistically so, rather than a completely automated response to a situation.
Conscious Control Versus Automatic Action
One seeming difference between learning and habits may be that applying what you’ve learned is a more conscious process, whereas a habit is thought to be mostly automatic.
An expert painter, for instance, doesn’t just splatter paint on autopilot. Every stroke is a deliberate effort to achieve a particular result. This deliberateness seems the complete opposite of habits, which are defined by their level of automaticity.
While this seems to be the case, I’m also inclined to believe it’s more a superficial difference than it first appears. Even in simple habits, there’s often a great deal of flexibility about how to execute it. Take something like exercising every day: should you go in the morning or afternoon? Run or lift weights? Push yourself or take it easy?
Of course, a habitual action tends to have a strong default (otherwise it wouldn’t be a habit), but this too is similar to learning. When you encounter a familiar problem, the overriding tendency is to apply the techniques you’ve learned before. To solve a problem in an original way takes effort the same way that breaking out of a habitual groove does.
The Neuroscience of Learning and Habits
There’s a lot we don’t understand yet about both learning and habit-formation in the brain. But a common principle to both seems to be selectively strengthening the connections between neuronal circuits that lead to the desired output, and weakening incorrect or spurious connections.
A habit forms when a sequence of neurons fire forms a strong connection with downstream synapses and thus when the earlier ones fire, the later ones fire with a high probability. Think of this like a river carving a valley into the ground, so the water flowing downhill will be exceedingly likely to follow a certain path.
Learning happens when associations of one long-term memory become tightly coupled with another. This can be as simple as a cue-response: “Q: What is the capital of France? A: Paris.” or it can be as complicated as solving a differential equation by having the forms of the differential equation automatically flow to the mental actions that begin to solve it.
While there is likely quite a bit of nuance in each of these broad categories, my suspicion is that they overlap considerably, rather than being largely separate domains. Some forms of learning are encoded as motor sequences (such as learning to drive a car), some habits are encoded as associations between higher-level abstractions (such as remembering to write down to-do items when actions are discussed in an office meeting).
How to Use this to Learn Better (and Make Better Habits)
By seeing learning as similar to habit formation, you can start to view learning not as the process of storing information, but of preparing actions in particular contexts. So learning a language isn’t just storing vocabulary words, but learning to activate certain knowledge, in response to particular situations.
Once you see learning as cue-driven and context-based, as well as something that is trained like a habit (through repetition of the pattern of cue-response), then you’ll be much more likely to practice in a way that will eventually be useful. You’ll be able to spot inefficient learning designs when you recognize that the habit you’re creating isn’t the habit you actually need.
While it is true that you can’t anticipate every detail of a situation, it’s easy to recognize, for instance that a fundamental habit of mind which is useful when speaking a language is being able to think of an idea/concept and come up with the associate word in the language, but that picking that word out of a wordbox isn’t probably the habit you need (like in apps such as DuoLingo).
Similarly, you can improve your habit-formation by seeing it more like an act of learning. Rather than see your habits as being simple units, you can see that you’re trying to create flexible responses to a whole host of situations, all of which need to be conditioned separately. An exercise habit isn’t just going to the gym every day, but finding the appropriate response for all sorts of varied conditions (the gym is closed, you’re feeling sick, you forgot your running shoes, etc.)
By seeing habits-as-learning, you recognize that what you’re doing is not simply a matter of self-discipline, but also of exploration, experimentation and trying to create patterns of behavior that produce useful responses in situations you can’t quite predict. This takes time and practice, rather than simply being an act of will to execute.
Above all, by seeing the connection between learning and habits, you can see how much of your life is made up of similar patterns. Your thoughts, emotions, relationships and identity also operate on similarly practiced loops of cue and response. See the patterns, and you can start to change them. | https://medium.com/datadriveninvestor/the-hidden-connection-between-habits-and-learning-4ed4ec1f11b6 | ['Scott H. Young'] | 2020-12-15 05:12:47.044000+00:00 | ['Neuroscience', 'Self', 'Productivity', 'Habits', 'Learning'] |
Efficient Biomedical Segmentation When Only a Few Label Images Are Available @MICCAI2020 | Computer Vision
Efficient Biomedical Segmentation When Only a Few Label Images Are Available @MICCAI2020
A Proposal for State-of-the-Art Unsupervised Segmentation Using Contrastive Learning
MICCAI 2020
Photo by National Cancer Institute on Unsplash
In this story, Label-Efficient Multi-Task Segmentation using Contrastive Learning, by the University of Tokyo and Preferred Networks, is presented. This is published as a technical paper of the MICCAI BrainLes 2020 workshop. In this paper, a multi-task segmentation model is proposed for a precision medical image task where only a small amount of labeled data is available, and contrast learning is used to train the segmentation model. We show experimentally for the first time the effectiveness of contrastive predictive coding [Oord et al., 2018 and H´enaff et al., 2019] as a regularization task for image segmentation using both labeled and unlabeled images, and The results provide a new direction for label-efficient segmentation. The results show that it outperforms other multi-tasking methods, including state-of-the-art fully supervised models, when the amount of annotated data is limited. Experiments suggest that the use of unlabeled data can provide state-of-the-art performance when the amount of annotated data is limited.
Let’s see how they achieved that. I will explain only the essence of ssCPCseg, so If you are interested in reading my blog, please click on ssCPCseg paper and Github. | https://medium.com/towards-artificial-intelligence/efficient-biomedical-segmentation-when-only-a-few-label-images-are-available-2e0b2513703d | ['Makoto Takamatsu'] | 2020-12-19 14:21:21.971000+00:00 | ['Machine Learning', 'Artificial Intelligence', 'Deep Learning', 'Medical Imaging', 'Computer Vision'] |
Song lyrics generation with Artificial Intelligence (RNN) | 1. The theory (a brief overview)
Note: If you know enough about Machine Learning and Recurrent Neural Networks (and you are just interested in the code), please skip this part.
Let’s try to give a brief (non technical) overview of the theory that is behind this project.
Saying Artificial Intelligence is saying so many things, and it collapses into saying almost nothing. With this term we mean generally the entire set of techniques that are used to build some form of ability that we can in some way define “intelligent” (it is unclear, right?). Let’s try to be more precise.
In this particular application of this vague term that is Artificial Intelligence, I’ve used Recurrent Neural Networks. What are these beasts?
Let’s take a step-back. Neural Networks are Machine Learning algorithms that learn stuff in a layered way, in a similar way of the human learning (from simple concepts to more complex ones).
Recurrent Neural Networks is a specific kind of Neural Networks that process the data that are meant to be look in their entire sequence. Let’s say you want to predict the highest temperature you will get tomorrow. A way to do that is to use the Recurrent Neural Networks. This example may seems trivial, but it is actually the same thing we want to do here:
From a given sequence as an input, predict the next word, then the next word, then the next word…
Let’s play. :)
GIF from The Kennedy Center
2. The Dataset
The dataset I’ve used is a courtesy of Manva Pradhan and you can find it here
Yes, I’ve picked Taylor Swift choruses to train my data. And it is not (just) because she melts my hearts every time she sings.
GIF from Giphy
These methods work extremely well if you use a lot of data to train your model (you may have encountered the term “Big Data”). The drawback is that you require a lot of computational power to have a decent result out of a lot of data. So I’ve used a single singer and base my model on that.
But why did I use Taylor Swift?
I’ve done that because she is actually “easy to get” when it is about choruses. She doesn’t use solemn terms and she doesn’t use over-sophisticated metrics. And that’s about it. You could use Ed Sheeran, or Justin Bieber, or someone else (the best thing would be actually to use them all together to create a powerful model).
3. Data pre-processing
Let’s give a look at the dataset:
So you have the entire lyrics with this line_number for each songs. But we want to write the new choruses, so we’re eventually have to take the choruses only (we will do that, keep calm). In all the datasets I’ve worked, I’ve always found something strange that messes your model up. Unfortunately, this is not an exception.
The same album appears multiple times, but with different names, and it is actually a problem. Fixing this with this few lines:
Ok, we’re cool. Now, if you look at the starting point of each verse, chorus, or bridge you could find this notation : [Verse], [Chorus], [Bridge] (actually you find it every where, it is like super-basic).
So let’s have another column that select the lines that contains that ‘[‘ stuff (1/0).
Awesome, now we just have to pick the Choruses. We move in these ‘[‘ values that are specifically the ones of the Choruses (remember that you have stored those in that IND list), and we stop when we find another ‘]’.
Again, let’s clean some mess here:
Here:
And here:
With this line:
And the die is cast.
This is an example:
GIF from Ash vs Evil Dead
4. Song-writing RNN
These models are complex to build, and unless you are a researcher, you’ll never build a Neural Network from scratch. Here’ s the Recurrent Neural Network I’ve used .
The first thing you do is not immediate to comprehend, as it is pretty technical. It regards a series of techniques that are used in order to make strings “readable” as numbers.
It is not so interesting to deepen it here, but here’s the TensorFlow commented code:
Then you have the interesting part. Words are seen as vectors that needs to be computed in the best way as possible to capture the meaning of the word itself (this method is called embedding). Then, you use the Gated Recurrent Units, that are cells that are able to “remember” a certain number of previous words in a clever way. Finally, you use a dense layer with the logit that gives you an information about the most probable word you expect. Isn’t that awesome?
Graph developed by Tensorflow
Of course, these methods are “magical but not magic”. So they need to be trained, for a pretty long period of time. Specifically, they are trained to minimize a certain loss you have to attach to your optimizer:
Trained model right here:
And this is the last step:
So the input is:
The trained model
The start string (remember: the model is “recurrent”)
The temperature.
This last input is actually amazing. In fact if you use low temperature, you will get predictable results, if you increase the temperature, your lyrics will become more “creative”. You don’t believe me, right? You will. :)
5. Results
You would probably be thinking: “Hey man, this is enough. Give me your lyrics”.
You’re right bad boy/ girl. Here’s three example, with different values of temperature and different inputs:
As I’ve told you, if you increase the temperature you risk to have nonsense lyrics like “Say a mind of my friends are saying”. On the other hand, low temperature takes you to existing lyrics, so you have to be careful and adapt the temperature and the start string.
If you want to be more technical, you could use LSTM cell instead of GRU, or use a more powerful machine, or change the data pre processing part.
6. Thinking out loud
We are skeptical about “AI writing songs”, and there is a reason why we are. We like to think that Music, Art, Poetry, Cinema doesn’t regards numbers, equation, computers, but belongs to a different part of ourselves, that is the creative and passionate one.
As a musician and data scientist, I’m really confused. I would like to think that when I listen to my favourite album and I get goosebumps it is because there is something more about the music that is not just a good mix of sounds and words that are accurately predicted by a logit function. But isn’t it Artificial Intelligence a form of art by itself? Does this “art” actually exist? Does these feelings actually exist? Well, I do have feelings for Taylor Swift though.
Ok, I’ve got way too far. As always, please hit me at [email protected] if you have anything you would like to share with me about this project (literally, anything).
Thank you :) | https://towardsdatascience.com/song-lyrics-generation-with-artificial-intelligence-rnn-cdba26738530 | ['Piero Paialunga'] | 2020-12-29 00:47:11.546000+00:00 | ['Machine Learning', 'Artificial Intelligence', 'Taylor Swift', 'Lyrics', 'Music'] |
How to Create a Custom Request Model in React Using RxJs, TypeScript, and Fetch | How to Create a Custom Request Model in React Using RxJs, TypeScript, and Fetch
Make your API requests easier
Image source: Author
Shifting from Angular to React wasn’t an easy transition. That was not due to the difference in difficulty between frameworks, but because I knew how much I’d miss the seamless TypeScript integration, along with Services and Pipes, but most of all potentially having to abandon RxJs. That is, until I did some research and realized I wouldn’t have to. So in this article, we’ll be looking at how to implement a base model for using the Fetch API already provided by JavaScript, along with TypeScript and RxJs for some flavor.
To get things started, let’s begin by creating a fresh React project with TypeScript support off the bat using the command:
npx create-react-app rxjs-react --template typescript
If you’d like to add TypeScript support to a current React project, please refer to this link: https://create-react-app.dev/docs/adding-typescript/
After that has been set up, switch to the root directory of your project and run this command to install RxJs:
npm i rxjs
Upon installation we’re good to go. You can now open the project in your preferred code editor and begin coding. Below is the structure we’ll be following for our files within our project. Please note that these will have to go under our src folder.
-services
|-api.service.ts
|-index.ts -utils
|-types.ts
|-base-request-model.ts
We’ll start off with creating our types.ts . Here we’ll be declaring the allowed types we’ll be using when performing our fetch requests.
Next, we’ll be creating our base-request-model.ts . This is the model we’ll be using to make any request coming from our app. We then import these types into our BaseRequestModel like so:
import { Method, _Headers, Body } from "./types";
For this example, we’ll be using http://dummy.restapiexample.com/api/v1 as our baseUrl and setting our default method to GET in our constructor. We’ll also be implementing our own interface for the properties. The model will have the following:
const baseUrl = 'http://dummy.restapiexample.com/api/v1'; interface Props {
url: string;
method?: Method;
headers: _Headers,
body?: Body
}
We’re making the body optional in the event that we’re making a get request and we don’t supply a body. We then implement the interface by using the keyword “implements” followed by the interface name after our class name. We then create a method that returns an observable, but before that, we’ll have to import the observable interface into our file in order to use it.
import {Observable} from 'rxjs'
Then we initialize our properties in the BaseModel contructor. A constructor is basically a special method that is used to initialize objects and is called as an object of a class is instantiated.
Then we implement the request method. Inside this method is where we’ll be using the built-in Fetch API:
https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API
We’ll be returning the resolved promise wrapped in a new observable where we pass our values using the next() method provided by the observable and closing the stream using complete() . We can also throw errors using the error() method, similar to how promises use resolve() and reject() .
And that’s it for the BaseRequestModel . Below is the complete implementation.
Next, we’ll be creating our api.service.ts . Here we’ll be declaring our own fetch methods and returning an observable, as well as creating any custom headers we might need to pass. For now, we’ll be focusing only on post and get , but feel free to add your own methods and develop further if need be.
First, we’ll import our BaseRequestModel previously created and the Body interface declared in our types.ts .
import BaseRequestModel from '../utils/base-request-model';
import { Body } from '../utils/types';
Then we implement our get method wrapped in an object so we can easily access them, like so:
const ApiService = {
get: (route: string): Observable<any> => {
const headers = {
'Access-Control-Allow-Origin': '*'
};
const newBase = new BaseRequestModel(route, 'GET', headers);
return newBase.request();
},
}
What we’re basically doing here is creating a new instance of our BaseRequestModel . We’re passing the route, the method, and the headers defined by our constructor and then returning the request() method property, which is an observable stream we can subscribe to later to access the values of the request we made.
We repeat this for our post method, with the exception of a form parameter, which will be of type Body that we imported from our types and content type of application/json in our headers. We then pass the form into our new BaseRequestModel (this is why we made the body optional).
To conclude this part, we’ll export these methods with our index.ts , which we’ll be creating at the root of our services folder. We just need to add the export keyword to our ApiService variable. Below is the complete implementation.
Finally, we can test this by simply importing ApiService from our services into any component we’d like to make any fetch methods from.
import { ApiService } from "./services";
For now, we’ll be using this in our App.tsx . We’ll start by creating an interface for our employee.
interface Employee {
id: string;
employee_name: string;
employee_salary: string;
employee_age: string;
profile_image?: string;
}
The Elvis operator “?” indicates that the profile_image property will be optional, and we don’t have to assign a value to it. We’ll start with the get request. You can place this in a function and call it when need be, but for now, we’ll be using this in our useEffect() .
Note that on mount, we’re assigning our subscription to a value so we can easily unsubscribe from our observable on cleanup as our component unmounts. We’re also using the take() operator imported from ‘rxjs/operators’ and passing (1) so that we only get the first result of the stream, as well as the map() operator to manipulate any data received before assigning it to any value within the component. In this case, I only want the res.data being returned from the response.
We then map the results on our template and add some styling to each div note to declare the style object outside the scope of your component.
This will be the result:
We then include a button to test adding of an employee, along with the appropriate style declared outside the scope of the component.
We then define our addEmployee function.
We’ll be passing an object with the id, age, salary, and name of the employee to our post method from our ApiService and then pushing this object to the front of our employee array upon successful subscription or a successful post request. Save, and then click the Add Employee button to see the new employee prepended to our list of employees.
Ben Solo has joined the list
Below is the complete implementation. | https://medium.com/better-programming/creating-a-fetch-model-for-react-using-rxjs-typescript-e2aecf113023 | ['Rogelio Monteagudo'] | 2020-11-11 03:38:39.322000+00:00 | ['JavaScript', 'Typescript', 'React', 'Reactjs', 'Programming'] |
A Founder’s Story: Julian Mazzitelli, CIO of BioBox Analytics (3/3) | When I began my undergraduate degree at the University of Toronto, I knew exactly what I was going to study.
It started in a high school civics class, when our teacher handed out some university program fliers to help us figure out our career paths. One of these fliers was for a Bioinformatics program. I learned that a specialization in Bioinformatics combined two of my strongest passions — Biology & Computer Science. From that point on, I would go on to pursue those passions relentlessly throughout undergrad, and now at BioBox.
An exemplary instance of combining my passions is the real-scale 3D mitochondria I built for a project course. Outside of classes I kept these passions alive by participating in a Google Summer of Code project under the Open Bioinformatics Foundation, leading the iGEM dry lab team and joining the Center for Computational Medicine as a co-op student, where I would end up staying beyond my co-op term as summer research student on the CANDIG project. At CCM I worked on full stack web development, cloud computing infrastructure, and would participate in the bioinformatician team meetings. These skills in concert, unknowingly to me at the time, had prepared me for what would be the most exciting opportunity yet…
The powerhouse of the cell
One fateful evening, my co-founder Chris and I were having 🐟 sushi 🍣 at a favourite UofT spot on Baldwin. Chris had wrote a simple web application for biologists to configure plots to their data and was surprised at how well it was received. This first prototypal app exposed two pain points from both sides of the biology research fence:
Biologists want independence and autonomy when investigating data and Bioinformaticians want to spend more time on challenging problems rather than manually making modifications to plotting parameters.
Shortly thereafter, I was introduced to my second co-founder, Hamza, and the trio was formed.
I started BioBox with my two co-founders because we all have strong convictions to fix the problems that we ourselves had experienced. As a biologist (Chris), a bioinformatician (Hamza), and an infrastructure developer (Yours Truly), we each had a different perspective on the same problems. We bonded over our shared optimism that these problems could in fact be tackled, and imagined the possibilities of such a software.
Confidence in my co-founders is the ultimate reason I chose to join BioBox.
When not directly developing code for the product, I act as our DevOps ambassador by ensuring that our developers and team at large have a productive work environment. In the same way BioBox streamlines the research process between bioinformaticians and biologists, I am excited to apply DevOps methodologies and tools to our company’s internal assembly line to foster efficiencies. We have built the continuous integration and continuous deployment capabilities from the beginning with these goals in mind.
My personal mandate to utilize DevOps practices doesn’t stop at our company. Last fall I gave a conference talk on GitOps-based continuous delivery with Kubernetes as well as a meetup talk on leveraging GitOps for developer environments! I believe that a strong DevOps culture is key to a company’s success and am passionate about sharing it with the greater DevOps community.
GDG DevFest 2019 in Montreal
While DevOps has improved our internal processes, no amount of perfect sprint planning or developer tooling will scratch the itch my co-founders and I initially bonded over. The real meat and potatoes of BioBox is delivering a web application to enable the autonomy of biologists to explore their data while simultaneously streamlining the collaboration process for bioinformaticians.
I am beyond excited to continue to build this company alongside my colleagues, to influence our internal processes and culture, and to leverage my skills to help make our product the best it can possibly be. | https://medium.com/bioboxanalytics/a-founders-story-julian-mazzitelli-cio-of-biobox-analytics-3-3-d2ebd7ac6bc4 | ['Julian Mazzitelli'] | 2020-12-10 13:49:03.491000+00:00 | ['Software Development', 'Founder Stories', 'Startup', 'Kubernetes', 'DevOps'] |
The Cone of Silence: Speech Separation by Localization | The model produces an audio track with the speaker’s speech and predicts the speaker’s position in relation to the microphones. The neural network handles audio recordings where speakers speak simultaneously and interrupt each other.
The neural network isolates sound sources for a particular corner. By decreasing the angle exponentially, the model localizes and separates sound sources in logarithmic time. The algorithm works on audio recordings with any number of moving speakers. Based on the results of the experiments, the model produces state-of-the-art results both on the problem of localizing the source of noise and on the problem of separating speakers. | https://medium.com/deep-learning-digest/the-cone-of-silence-speech-separation-by-localization-91fd7eb9c3c5 | ['Mikhail Raevskiy'] | 2020-11-12 11:57:13.707000+00:00 | ['Machine Learning', 'Artificial Intelligence', 'Deep Learning', 'AI', 'Data Science'] |
15 virtual AI assistants for digital marketers | 15 virtual AI assistants for digital marketers
A quick look at AI digital assistants to carry out marketing tasks (track metrics, detect anomalies, analyze ads, create and publish content, suggest how to optimize campaigns, generate reports)
Inspired by Seth Louey I decided to share this list of virtual AI assistants for digital marketers. Hope you will find some useful assistants to carry out your marketing tasks.
To create and publish content
#1 Yala — a chatbot that uses machine learning to find the best time to schedule social media posts. Channels: Facebook, Twitter, LinkedIn. Platforms: Facebook Messenger, Slack.
#2 Martin — content curation bot powered by A.I. Martin learns what you post to your Page and finds new content for you. Channels: Facebook. Platforms: Facebook Messenger.
#3 Rocco — will suggest fresh content that your followers are likely to engage with. Spend less time coming up with content strategies and crafting social-media posts. Platforms: Slack.
To track metrics and get reports
#4 Statsbot — monitors your application’s metrics by integrating with tools like Google Analytics, Salesforce and Mixpanel. Platforms: Slack.
#5 Hunch — the fastest way to check on all PPC campaigns across Facebook and Adwords at once. Channels: Facebook, Adwords, Twitter. Platforms: Slack.
#6 Revere — get critical alerts in Slack for AdWords campaigns and Optimizely experiments. Channels: Adwords, Optimizely. Platforms: Slack.
#7 Maisie — AI-powered marketing analyst. Maisie’s goal is to help you be more effective with your marketing so you can successfully grow your business. Integrated with Google analytics. Platforms: Slack.
#8 Reveal — your personal marketing assistant who warns you when you lose money on ads. Channels: Facebook, Instagram, Adwords, Youtube. Platforms: Slack.
To make decisions and optimize ad campaigns
#9 Leadza — a personal advertising assistant for Facebook marketers that sends daily optimizations tips which saves you ad spend and improve campaign performance. Channels: Facebook, Instagram. Platforms: Facebook Messanger.
#10 Aiden — AI powered virtual colleague for marketers that helps you spend your marketing budget efficiently. Integrated with Google analytics. Platforms: Facebook Messenger, Slack, Skype, SMS.
#11 Crystal — turn data into clear answers with the latest technologies in order to help modern-day marketers and companies make better decisions to reach their targets. Channels: Facebook, Google, Twitter, Youtube, Instagram, LinkedIn. Platforms: Mobile Website, iOS, Android.
#12 IBM Watson Marketing Assistant — is intended to simplify the analysis and decisions made by marketers trying to understand the effects of different components on their campaigns. Powered by voice.
To create and run simple marketing campaigns
#13 Kit — helps drive sales by doing everything from creating Facebook ads, to sending thank you emails, to handling the other apps that you use with your Shopify store. Channels: Email, Facebook, Instagram, MMS, Bold aps, Yotpo. Platforms: Facebook Messуnger, SMS, Telegram.
#14 Joy — is an AI powered virtual assistant to run personalized 1v1 marketing campaigns on social media and messaging channels. Channels: Facebook, Instagram, Twitter. Platforms: Mobile Website.
To get marketing advice
#15 GrowthBot — gives you useful information in a fast, friendly chat interface. It’s built for marketing, sales and others working on driving growth for companies. Uses Google analytics and Hubspot data. Platforms: Facebook Messenger, Slack, Twitter.
This list does not pretend to be complete. It would be great if you will help to add new solutions for marketers that you already use and like. Your comments and suggestions are welcome! | https://medium.com/leadza/15-virtual-ai-assistants-for-digital-marketers-d84265dce79e | ['Victoria Fast'] | 2017-10-27 04:56:14.233000+00:00 | ['AI', 'Digital Marketing', 'Virtual Assistant', 'Artificial Intelligence'] |
“ProGuard”-A Safe and Unique Platform for Sharing Confidential Files Using AWS | Privacy is the main concern in today’s world. There are many threats to the integrity of data and can be more harmful if the data is highly confidential. Encrypting the data and adding security layers is a must when dealing with highly confidential information. And for this purpose, using Advanced Encryption Standard (AES) encryption-decryption algorithm becomes most important as the AES algorithm is very difficult to crack.
What is Advanced Encryption Standard (AES)?
The Advanced Encryption Standard (AES) is a symmetric block cipher used to protect classified information.There are three block ciphers in AES: AES-128, AES-192 and AES-256. AES-128 uses a 128-bit key length to encrypt-decrypt a block of messages, while AES-192 uses a 192-bit key length and AES-256 uses a 256-bit key length to encrypt-decrypt messages. Each cipher encrypts and decrypts data in blocks of 128 bits using cryptographic keys of 128, 192 and 256 bits. Symmetric, also known as secret key, ciphers use the same key for encrypting and decrypting, so the sender and the receiver must both know and use the same secret key. There are 10 rounds for 128-bit keys, 12 rounds for 192-bit keys and 14 rounds for 256-bit keys. A round consists of several processing steps that include substitution, transposition and mixing of the input plain-text to transform it into the final output of cipher-text. It uses higher length key sizes such as 128, 192 and 256 bits for encryption. Hence it makes AES algorithm more robust against hacking.
What is ProGuard and how it works?
ProGuard is a safe platform for transferring confidential files by encrypting the files and sending them to receiver using AWS instance which is slightly different approach than the current platforms. Here there are two applications: 1) Stand-alone Application and 2) Web Application. The stand-alone application works on local machine for encryption-decryption and securing the files. The web application runs on cloud for the purpose of sending the encoded file and key to the receiver which he can later download the file and key to decode it through stand-alone application.
Pre-requisites
Necessary dependencies for this project:
Flask
Pycrypto
Reportlib
Secretsharing
PyPDF2
Below is the step-by-step process for implementing the program to share the files securely:
1. Stand-alone Application
Step 1: Download the project folder from my Github page and install all the necessary dependencies for this project. You can also find all the libraries listed above in the site-packages folder within the ProGuard folder.
Step 2: Create one text file and write your data which you intend to encrypt and share with others.
Step 3: Go to ProGuard/source/stand-alone-application and run the main.py file. Here one dialog box will appear in which you have to select the text file which you want to encrypt and share. After browsing the file location, you have to enter the pass-key and secret-key which can also be called as public key of receiver and private key of sender. These keys will be further used for generating keys for AES algorithm.
Step 4: After entering the details, press the Encrypt button to generate the encoded file on the destination folder. Note that the original file gets replaced with the encoded file. So currently you will not have your original data file on the machine but only the encoded file. Now you will see the file name EncodedFile.txt on your destination place in local machine.
Step 5: Now click the Make PDF button on the stand-alone application to generate the PDF of the keys used for encryption. Here you have to enter the pass-key and secret-key which you entered in the application and also the name of the PDF.
Step 6: Now press the Create PDF button. It will create a new PDF of the information that you entered above and will be present in your stand-alone-application folder.
Step 7: Now press the Secure PDF button. Another dialog box will appear after this. Here you have to choose the PDF file location and also the pass-key. Note that this pass-key is not the same as discussed above. This pass-key will be the password for accessing the PDF, so the pass-key should be known to both the party. For example, pass-key can be the last four digits of the contact number of receiver which is pre-decided by both the parties. After securing, you will find one new PDF file created named ENCRYPTED_KEY.pdf in the folder. After entering the correct password, the keys in the PDF are accessible.
Step 8: Now comes the decryption part. Go to the dialog box in Step 3, and select the file location which you want to decrypt. Enter the pass-key and secret-key and lastly press the Decrypt button. You will find the same original data file with name DecodedFile.txt in the destination that you provided in the application.
First part of the process is completed with stand-alone application. Now comes the second portion of the process i.e. file sharing through web application using AWS. | https://medium.com/swlh/proguard-a-safe-and-unique-platform-for-sharing-confidential-files-using-aws-f2694d0247e5 | ['Kirtan Pathak'] | 2020-10-15 21:02:54.797000+00:00 | ['Python', 'Security', 'AWS', 'Privacy', 'Cryptography'] |
Scalable & Highly Available Web & Mobile App Architecture | This is a quick overview of how to architect a web+mobile application in a way it is scalable and highly available. We will use AWS cloud technologies to implement the architecutre to achieve these targets.
What is High Availability?
A highly available application is one that can function properly when one or more of its components fail. It does not have a single point of failure, that is, when one component fails, the application can still deliver correct results.
What is scalability?
Scalability is the ability of an application to fulfill its functions properly when its execution rate becomes higher. For example, in the case of a HTTP API, it concretely means the ability of the API to respond correctly and in a reasonable time to all requests when the number of requests per second goes higher.
Typical Application Architecture
Modern applications typically consist of one or more frontend clients used by customers (one or more native mobile apps + a javascript app), talking to one back-end through HTTP API. The back-end stores data in a database and responds to requests coming from front-end clients.
Design for High Availability
Single points of failure
The first step is to identify where a failure can compromise the availability of the application. All the following are single points of failure :
The locations where the front-end clients are stored for distribution. If a location becomes unavailable, one of the clients cannot be accessed and used by customers, and thus cannot use the application. The HTTP API back-end component. If this component fails, requests sent by front-end clients will not be fullfilled. The database. If the database fails, the back-end will not be able to extract stored data or write data in response to API requests sent by clients.
HA for front-end clients distribution locations
The locations where the front-end clients are stored for distribution depend of the target platform. In case of Android and IOS clients, these locations are typically Google Play Store and Apple App Store. Or mobile app stores in general. High availability of these locations are handled by Google, Apple and app stores owners and we can’t do much about it.
For web client, we can store it in AWS S3 and distribute it with AWS Cloudfront, which makes it not only highly available but also scalable as we will see later. Using this setup is so common today. Here is a step by step tutorial about how to achieve that.
HA for Back-end
The back-end API component needs to be up and running to respond to any request sent by front-end clients. The basic setup consists in running one instance of Nodejs express server that fullfills HTTP requests. But if that instance goes down for whatever reason, the application is not available anymore. One approach is to launch multiple EC2 instances hosting your servers on multiple Availability Zones / Regions. Then use Amazon Elastic Load Balancer to distribute the incoming requests to the healthy instances. Amazon ELB does the health check automatically so that if it finds that an instance is not responding, it does not forward future requests to it. Using Amazon ELB has another advantage, it can do the SSL/HTTPS connection management for us so that our servers receive plain HTTP traffic. This is a big advantage, given the high cost of SSL connection management computing. And since usage of SSL is increasingly being enforced by web browsers and platforms, this comes really handy.
HA for Database
The typical way to ensure high availability of a database is to have replicas in different availability zones that are the mirror of the master database. When the master becomes unavailable, one of the replicas takes the role of the master. Replication can be done either the old way, setting up multiple EC2 instances each hosting a database replica, and you manage the replication and failover by yourself. Or you can use Amazon RDS which manages the database server for you and takes care of maintenance, upgrades, replications and failover. Note that Amazon RDS is for relational database servers. There are also offerings for NoSql databases.
Design for Scalability
Now we know how to make our application highly available. But what about scalability? How to make sure our application can cope with traffic peaks and still functions properly under heavy load?
Front-end clients distribution
For front-end clients distribution, mobile app stores and Amazon cloudfront are designed to be highly scalable so no need to worry about that point.
Backend API
For the back-end part, Amazon EC2 Auto Scaling can be leveraged to automatically scale your Nodejs servers when required. Amazon Elastic Load Balancer works well with EC2 Auto Scaling. Here is a tutorial about how to achieve it.
Another way to achieve scalability is to use Amazon API Gateway in combination with AWS Lambda. The first lets you define endpoints for your API. The second lets you execute functions without managing any server. This is called Serverless Computing. Express application servers can easily be updated to run as lambda function using serverless-http npm module. It will be triggered when front-end clients fire HTTPS requests to your defined APIs. Amazon API Gateway is highly available and scalable and you can use your own domains and subdomains to trigger it. Amazon API Gateway + AWS Lambda can be used as a replacement for Amazon Elastic Load Balancer + Amazon EC2 Auto Scaling + EC2 with less administration overhead. It should also cost less. It costs nothing when you have no or low traffic.
Database
Coming to database, it is not as easy to scale as computing since most databases can support a limited number of open connections, depending on the database server and the underlying machine available memory.
The first step scaling database layer is to use some pooling mechanism that can recycle connections and manage them in an efficient way. Amazon RDS Proxy achieves this pooling mechanism for serverless applications that use AWS lambda. But even if it improves and optimizes connection management to your RDS instance, the proxy is not sufficient in case of heavy load. Once the pool is saturated due to high number of concurrent requests, the remaining requests will be delayed and will probably time out.
The second step, is to use a memory cache like Redis or the equivalent AWS offer called Amazon ElasticCache. Memory caches are incredibly fast and have a very low latency. They also have much lighter connection management mechanisms and support a much higher number of simultanous connections. So you will need to implement your data access methods in your application in a way that they look for data in the cache first, and only if it is not available or is outdated, retrieve it from database. Obviously, this is rather applicable to the read operations. Write operations should be done on the database for consistency. One way to scale write operations is to handle them asynchronically. An example implementation would be to send write commands to an Amazon SQS queue and have them executed by another lambda function. This way, write operations and database connections are made in a predictable manner.
Please note as well that to have a highly available memory cache setup you need either use multiple instances of Redis with sentinels or use Amazon ElasticCache with replicas.
Client Side Caching
Implementing caching on front-end client side can be benefical for two aspects :
It allows to reduce the load on the back-end by serving data that does not change frequently from local cache. It provides a better overall user experience, allowing users to still use some parts of your application when your back-end is not reachable. This typically happens when a mobile user has no internet connection. Users appreciate when they can still use applications offline.
A simple cache can be implemented as a key,value,ttl array with 3 simple methods :
set(key,value[,ttl]) : store or update an object in the cache indexed by key with optional time to live
get(key) : get the object indexed by key if it exists and is not expired
getCacheEntry(key) : get the object indexed by key even if it has expired. The result could be something like {object : …, expired: true|false}
SharedPreferences could be used to store cache data in Android if it is relatively small. On Web application side, LocalStorage can be leveraged to achieve the same. One more convenient way is to use LocalForage which abstracts the underlying storage APIs and use the optimal ones when available.
Conclusion
I hope this article was a helpful overview. There is no step by step tutorial or code snippets but this is intended to be a quick overview about making your application scalable and highly available. I used most of these concepts to architect couponfog the coupons app. | https://medium.com/swlh/scalable-highly-available-web-mobile-app-architecture-d803b8ba56e | ['Ahmed Mahouachi'] | 2020-11-10 08:56:17.856000+00:00 | ['AWS Lambda', 'High Availability', 'React', 'AWS', 'Scalability'] |
Disaster Recovery: Backing Up your Oracle Database with Oracle Database Cloud Backup Service, RMAN, and Object Storage | Disaster Recovery: Backing Up your Oracle Database with Oracle Database Cloud Backup Service, RMAN, and Object Storage
how to back up your Oracle Cloud Database
Photo by Kevin Ku on Unsplash
How can we prepare for disaster? If a server crashes, a technician unplugs a machine, or a meteor hits a datacenter, how can the business recover crucial data? In this tutorial we demonstrate how to backup the Oracle Cloud Database with Oracle Database Cloud Backup Service, RMAN (Recovery Manager), and Object Storage. Here, Oracle Database Cloud Backup Service enables connection and communication with Oracle Cloud Infrastructure (OCI) while RMAN executes backups of your Oracle Cloud Database to OCI Object Storage.
Note: there are many different ways to backup an Oracle Cloud Database, this is meant to represent one option. Note: given the diversity of customer environments and the ever-changing landscape of Oracle Cloud Infrastructure, please take the commands and their explanations listed below with a grain of salt.
Outline:
Pre-Requisites for Using Oracle Database Cloud Backup Service Full List of Commands for installing Oracle Database Cloud Backup Service Pre-Requisites for Installing Oracle Cloud Backup Database Service Installing RMAN Configure RMAN and Backup Database Database Table Access through SQL Plus Conclusion
Pre-Requisites for Using Oracle Database Cloud Backup Service
Before we get started, here is a link to all the pre-requisites needed to use the Oracle Cloud Backup Service. I will try to provide as much context to each pre-requisite and provide helpful links and examples.
Check and make sure you are running the right database version and operating system. In this module I am using Enterprise Extreme Performance Edition version 19c.
Setup Object Storage in OCI (Oracle Cloud Infrastructure). I recommend simply using the console, accessing object storage, and creating a bucket.
In the virtual machine which hosts the database, generate keys to access OCI. Here is, in essence, how it will look. (The scripts below assume you are already in the VM instance which hosts the database.) This is how you will upload the key to OCI such that your virtual machine can communicate/connect with OCI.
Check that you have a JDK 1.7 or later. You can check which version you have by typing “java -version” in your linux terminal. You should get an output similar to the following:
java version “1.8.0_191”
Java(TM) SE Runtime Environment (build 1.8.0_191-b12)
Java HotSpot(TM) 64-Bit Server VM (build 25.191-b12, mixed mode)
Finally, you want to download the latest version of the Oracle Cloud Backup service. This is the link to download the backup service. This should download a zip file called opc_installer. When unzipped, you should two folders, opc_installer and oci_installer. These are the two ways to install the Cloud Backup Service. In this tutorial, I will be using the oci_installer for OCI (not OCI classic).
Note: If you have downloaded the Oracle Cloud Backup Service on a different machine than the one which hosts your database, you can use this command to copy your key from your local machine to your database host instance:
#generic command
cp -i <file/path/to/your/private_key> oci_install.jar opc@<vm_db_ip>:~”.
cp -i /Users/abibi/.ssh/id_rsa oci_install.jar #examplecp -i /Users/abibi/.ssh/id_rsa oci_install.jar [email protected] :~
Note: To SSH to the virtual machine which hosts your database:
Full List of Commands for installing Oracle Database Cloud Backup Service
I am doing this a bit backwards and providing a list of commands for installing the oci_install.jar file before detailing the pre-requisites for the command. I am doing this because I wanted to provide a nice flow of commands. If you like more detail about the commands or are running into issues, simply reference the pre-reqs listed in the next section.
Note: If you have executed some the commands listed above, no need to repeat them.
#copy the newly downloaded oci_install.jar file to your database instance, assumes that the oci_install file in your current directory scp -i <private_key> oci_install.jar opc@<db_ip>:~ #SSH into the instance
ssh -i <private_key> opc@<db_ip> #maybe log into your Oracle user--see note below
#sudo su - oracle #create directories for installing jar file
mkdir ~/lib
mkdir ~/wallet #directory for oci credentials
mkdir .oci #generating key for OCI
openssl genrsa -out ~/.oci/oci_api_key.pem 2048
openssl rsa -pubout -in ~/.oci/oci_api_key.pem -out ~/.oci/oci_api_key_public.pem #change directory to oci folder
cd .oci #note: to see hidden files, enter "ls -a" #output the key, copy and paste into user ssh key
cat oci_api_key_public.pem #cd into folder containing oci_install.jar file, should be in opc folder #I assume the opc directory is where the jar file is located
cd opc #generic command to install backup service
java -jar oci_install.jar -host <object storage endpoint> -pvtKeyFile ~/.oci/oci_api_key.pem -pubFingerprint <fingerprint> -tOCID <tOCID> -cOCID <cOCID> -uOCID <uOCID> -walletDir ~/wallet -libDir ~/lib -bucket <bucketname>
N ote: depending on the version of the database you are installing, you may need to copy files from one directory to another within the database instance. To do this, I recommend accessing the root user, copying files, and changing permissions for a file:
#becoming root user
sudo su #example of copying wallet credentials from opc to oracle user
cp /home/opc/wallet/cwallet.sso /u01/app/oracle #changing permission access for a particular file such that other users can access the file
chmod 775 /home/opc/wallet/cwallet.sso
Note: another option is to log in as the instance’s Oracle user and run the commands above. To do this you can enter the following command after you have SSH’d into the instance:
sudo su - oracle
Pre-Requisites for Installing Oracle Cloud Backup Database Service
To execute the jar file that will install the Oracle Cloud Backup Database Service, we need to gather some information from our Oracle Cloud Tenancy:
Host: our object storage endpoint indicating the region where we created a bucket. Here is a list of valid value.
pvtKeyFile: the location to the oci_api_key which we generated earlier in our database virtual machine.
pubFingerprint: the fingerprint corresponding to the oci_api_key.
tOCID: our tenancy OCID
cOCID: the compartment OCID which holds object storage and our database instance.
uOCID: our user’s OCID.
Note: OCID is a unique value which identifies specific components of OCI like user, compartments, tenancy, and services. Learn more about OCIDs, here.
walletDir: location for newly created wallet.
Note: simply type the following if you want to create a folder in your current working directory:
mkdir ~/wallet
libDir: location for newly created library.
Note: simply type the following if you want to create a folder in your current working directory.
mkdir ~/lib
Here is the GENERIC command that installs the Oracle Cloud Backup Database Service:
Here is an EXAMPLE command:
Note: I’ve spaced out the commands so that it is easier to understand, but when executing these commands in linux, they should all be in one line separated by a space. Note: if you are getting errors, here is some documentation that helps diagnose some common issues.
We can validate successfully installing the jar file by checking if wallet and lib folders were created and if we see a “config” file which contains the OPC_HOST, OPC_WALLET, OPC_CONTAINER, OPC_COMPARTMENT, and OPC_AUTH_SCHEME values.
Note: To open and read linux files, I recommend installing nano by typing the following (assuming you are in a directory with access to the config file):
yum install nano
nano config
Installing RMAN
Now that we have successfully installed Oracle Database Cloud Backup Service and established a connection to OCI, let’s setup RMAN (Oracle Recovery Manager) to manage our database backup to object storage.
Pre-requisite:
Oracle DB Password, the password entered when provisioning the Oracle Cloud Database instance.
RMAN binaries location for installation
#to find the rman binaries
find / -iname rman
Note: if there is a permission error, please enter the command to become a root user
#example output should look something like this:
/opt/oracle/dcs/log/ary/rman
/tmp/dcsserver/rman
/u01/app/19.0.0.0/grid/bin/rman
/u01/app/oracle/product/19.0.0.0/dbhome_1/bin/rman
Add RMAN binary location to current path
#generic example of path
export PATH=/u01/app/oracle/product/<insert DB version number>/dbhome_1/bin
Set environment variables, ORACLE_HOME and ORACLE_SID
#not really sure how important this, but points to database path
export ORACLE_HOME=/u01/app/oracle/product/19.0.0.0/dbhome_1 #a unique identifier for your database, can find this in the console where you database is provisioned
export ORACLE_SID=DB1111 #outputs all environment variables to confirm
env #outputs config info for the database
srvctl config database -d <database unique identifier>
Configure RMAN and Backup Database
Now we are ready to configure RMAN for backing up the Oracle Cloud Database to object storage. Simply enter this command to set/authorize RMAN connection to the database:
#generic, TARGET is the command, SYS is the user, oracle is the password, and trgt2 is the database unique identifier
rman TARGET SYS/oracle@trgt2 #example
rman TARGET SYS/mypassword@DB111_asc3fp
By this point, you should see a lingering “RMAN” at the bottom of the terminal and a message above stating that you have successfully connected to the database.
Note: Here is some additional documentation and another source that is helpful for logging into the database using RMAN.
Next, we need to configure some RMAN parameters before backing up the database:
CONFIGURE CHANNEL DEVICE TYPE 'SBT_TAPE' PARMS 'SBT_LIBRARY=/path/to/libopc.so, SBT_PARMS=(OPC_PFILE=/path/to/config)';
Some additional commands:
CONFIGURE CONTROLFILE AUTOBACKUP ON;
CONFIGURE DEFAULT DEVICE TYPE TO SBT_TAPE;
CONFIGURE BACKUP OPTIMIZATION ON;
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE SBT_TAPE TO '%F';
CONFIGURE ENCRYPTION FOR DATABASE ON;
SET ENCRYPTION IDENTIFIED BY "password" ONLY;
Note: details about the commands listed above and other options can be found here.
Finally:
BACKUP DATABASE;
At this point, the command should result in the database being backed up into the object storage defined earlier. To confirm the backup is successful simply check object storage for database content and metadata files along with other related objects.
Database Table Access through SQL Plus
As an aside, to connect to the database tables, here is a link to some documentation. More information about connecting to a database. Below is a command that accesses the database tables through SQL Plus.
#generic script to access database tables as system user
sqlplus system/@(DESCRIPTION=(CONNECT_TIMEOUT=5)(TRANSPORT_CONNECT_TIMEOUT=3)(RETRY_COUNT=3)(ADDRESS_LIST=(LOAD_BALANCE=on)(ADDRESS=(PROTOCOL=TCP)(HOST=10.0.0.3)(PORT=1521)))(CONNECT_DATA=(SERVICE_NAME=<unique service name defined in database console under database connection>))) #example script to access database tables as system user
sqlplus system/@meee.subnet.vcn.oraclevcn.com:1521/DB1111_asb3bs.subnet.vcn.oraclevcn.com
Conclusion
There are other ways of backing up an Oracle Cloud Database, why choose this option? I believe this provides find-grained control and the ability to set a cron job for scheduling the backup. With object storage involved, the database can be backed up to another region where the database is not running to provide high availability during a disaster. Nevertheless, there are automatic backups available in the console, the Oracle OCI Python SDK, and a number of other options to backup your database. I recommend considering the use case, RPO, RTO, and other factors before choosing this backup solution as it is tedious and time consuming to implement. | https://medium.com/oracledevs/disaster-recovery-backing-up-your-oracle-database-with-oracle-database-cloud-backup-service-rman-e28b86876ad2 | ['Ary Sharifian'] | 2020-08-10 05:43:47.156000+00:00 | ['Oracle Database', 'Disaster Recovery', 'Data Engineering', 'Cloud Computing', 'Iaas'] |
I Thought I Was Some Bigshot Writer, Then I Submitted to Real Publications | WRITING
I Thought I Was Some Bigshot Writer, Then I Submitted to Real Publications
Like ‘America’s Got Talent,’ but awkwarder
Photo: Francisco Osorio on Flickr / CC-2.0
“Sorry, sir, your card is declined.”
A declined credit card only happened a few times in my life, and my heart sinks every time. It feels like I did something wrong, even though it’s always been a machine error.
Did I overspend? Did someone hack my bank account? Am I overdrawn?
The questions spin around my mind — all from a declined card.
Now, I’m getting used to that feeling.
I used to think I was special. I used to believe I could write. Then I started submitting to publications, and boy is it a wake-up.
When I wrote my first articles, I was like one of those singers on America’s Got Talent. I wanted to get them published. Give me the microphone already!
In my imagination, I could already hear the audience screaming in adoration.
Then I sang and — oh no —
It’s not that the audience started laughing. It was more of an awkward, silent grimace.
You know those people who annoy you because they clearly think they’re somebody? They think they’ve got it, even though it’s obvious they don’t. I’m sorry to say it, but I was that guy.
I believed I wrote incredible articles that no-one would decline.
It’s easy to believe that when you don’t write anything. Life’s so much easier when you avoid stepping out, avoid creating, keep it all inside, where it’s pristine and perfect. You can admire that beautiful blank canvas, and nobody will ever judge.
I stopped being pristine. I started submitting. The beautiful articles that I spent so many hours crafting.
“Thank you for your submission; we’re going to pass on this article.”
Simon Cowell, how could you?
If you want a wake-up call, start submitting to publications. It’s a ride like no other.
And nope, I’m not ready to stop submitting yet. No matter how many times I get declined, here’s to one more try. | https://medium.com/2-minute-madness/i-thought-i-was-some-bigshot-writer-then-i-submitted-to-real-publications-1b1aa66c3b3e | ['David Majister'] | 2020-12-10 16:22:45.268000+00:00 | ['Writing', 'Creativity', 'Writing Tips', 'Rejection', 'Humor'] |
Mico Yuk on the Importance of Community and the Paradigm Shift in Business Intelligence | Mico Yuk is the CEO and Co-Founder of BI Brainz. Her company uses their data storytelling methodology to help companies take their data and make sense of it in a fun, visual way.
“I am heading into a conference with 25K tech women which is partly why I’m high octane right now!!!” That’s the message I received from the CEO and Co-Founder of BI Brainz, Mico Yuk. I had reached out to her to be a part of my ongoing series talking to thought leaders such as Ben Jones, Nick Caldwell and Matt David to get her insights on the future of BI. After years of being a sought-after consultant, Mico formed BI Brainz to “help companies take their data and make sense of it in a fun, visual way” using their data storytelling methodology and templates. In addition to running her own analytics consultancy, she’s an author, speaker and host of her own podcast, Analytics on Fire!
Mico was about to enter the Grace Hopper Celebration (GHC) when she responded to my request for an interview. She was pumped up to attend THE largest gathering of women technologists in the United States. GHC is an event run by women for women in the tech space to network, mentor and find their tribe. Mico shares her highlights of GHC as well as the future of business intelligence.
Mico hanging out with GHC President Brenda Wilkerson. Ms Wilkerson personally invited Mico to the GHC festivities! Mico describes her experience there as a career dream come true.
Allen Hillery: Hi Mico! Thanks so much for chatting with me! I know we were exchanging messages from the Grace Hopper Celebration. Please tell us what the energy was like and what it means to you to be a part of such a monumental event?
Mico Yuk: “I finally know what heaven looks like. Women, from all over the world, talking about technology, making hiring decisions and in leadership.” That is how I described #GHC19 to both the CEO of Anita.borg, Brenda Wilkerson, who inspires me and personally invited me to #GHC19, and our CMO of BI Brainz, Soo Tang Yuk on day one. I literally stood up in the middle of the exhibition center watching companies I only dreamed to worked for 5–10 years ago, with hundreds of women lined up, résumé in hand waiting for an interview. I pinched myself and realized it was not a dream. I stood in awe, as I went from booth to booth being celebrated for being a woman, greeted with girlie colors like pink, pastel green and purples. Every sticker, wall, and pen had an empowering message for women. My heart is racing again just thinking about it! It was A-M-A-Z-I-N-G!!
AH: What particular moment, event or speaker at GHC has most inspired you ?
MY:There were so many sessions but if I had to pick one event, it would have to be the closing ceremony. I felt like I was at a rock concert, but we, the women in tech, were on stage — crazy right?
AH: Tell us about it.
MY: The closing ceremony on the last day was a collection of final announcements such as the Abie Award winner, scholarships recipients and winners of the #pitcher event. At the #pitcher segment, I was so excited to see Backstage Capital Founder, Arland Hamilton on stage, stating that she hit her goal of investing in 100 under represented companies two years early!
Mico Yuk (left) with Stephanie Lampkin, CEO of Blendoor, a recruiting tool that removes unconscious bias from hiring by leaving only the applicant credentials visible to employers.
Even more amazing, was running into my engineering classmate Sanna Gaspard after 15 years. She won first place in the #pitcher contest, going home with $40,000 to accelerate her biotech startup Rubitection, an early detection tool. I was delighted to run into old friends like Stephanie Lampkin, Founder of Blendoor, a recruiting tool that removes unconscious bias from hiring by hiding everything but applicant credentials. Her Tedtalk is prolific. It was nuts!
AH: That sounds like an awesome reunion! Can you share more about how that sense of community has been helpful in your career overall?
MY: Community is SO important! It’s honestly how we built BI Brainz from the ground up. Being a woman in tech can be very mentally and emotionally taxing at times. People make assumptions because you’re a woman. You have to work harder because you’re a woman. My outlet has always been and will continue to be the community and knowing that what I do makes a difference in people’s lives. I have also met so many amazing females who are on the same path. We support each other and pay it forward to the next generation of intelligent ladies. I’d tell anyone getting into tech as a woman… find your community and hold unto it, tightly.
“Knowing someone else has been discriminated against, overlooked, and not even invited to the table is sometimes what you need to push forward and realize it’s not just you!” -Mico Yuk on the importance of community
AH: BI and Data Viz are both male dominated fields. What do you think is missing when these fields don’t accurately represent society at large?
Mico discussed how women in tech can be very mentally and emotionally taxing at times but she credits her community of amazing females for helping her push forward and continuing to break boundaries!
MY: The first thing that comes to mind is a keynote I heard at an MIT event I spoke at by Peter Schwartz, author of The Art of the Long View where he described what led IBM to decide not to invest in then unknown startup Microsoft, as they projected that PCs were for girls and the fad would die by the 1980’s. He concluded that companies like IBM who made such ‘now unthinkable’ decisions had one thing in common. A lack of diversity in ideas, a lack of diversity in thought and a lack of diversity in the room (in gender and race).
Business intelligence has been like this for a long time. The last 20 years has been focused on the dark hole aka the data warehouse. Thank God we are now focused on getting insights and wisdom out of data. The creative nature of data visualization also attracts more females to the field, so we will continue to see more diversity in the coming years.
“Business intelligence has been like this for a long time. The last 20 years has been focused on the dark hole aka the data warehouse. Thank God we are now focused on getting insights and wisdom out of data.” — Mico Yuk on the historical lack of diversity of BI
AH: What made you want to get started in data viz and how did you end up where you are now?
Growing up in the Caribbean, I’ve always loved art. I was the president of our Art Honor Society in high school, which was no. 1 throughout the Caribbean. I also had a secret hobby at home, which was playing on my over-sized HP desktop I begged my parents to buy in the ninth grade. Fast-forward to age 15 — I graduated from high school and went to college to study computer engineering (dropping out twice before graduating).
AH: Did you see computer engineering as your pathway to data visualization?
MY: Data viz kind of found me. I spent six months programming in mainframe SaaS as a data scientist, and then a year later I saw a job on Craigslist for a data viz expert, who would could help Ryder Logistics role out their Lean Six Sigma program to all their customers. I applied (running away from writing C++ code at AT&T all day, ugh), got the offer two days later and I took it. That job changed my life.
My obsession with user design, user experience and user adoption, helped to make Ryder’s Lean Six Sigma visual program successful, then taking me to New York to work with Pfizer, and then onto work with other large enterprises such as AllState, Bank of America, Shell, and many more. Now I run my own analytics consulting firm, BI Brainz, which is now co-owned by a company called EPI-USE, whose core competency is developing HR solutions. With access to 2,200 consultants globally in 67 countries there is no limit to our future! It’s not easy, but I love what we do.
AH: How much has your love for art impacted your career in data viz? Do you feel someone with a liberal arts background can contribute to data visualization or even business intelligence?
MY: I LOVE art. So when I realized that I could combine my programming skills with my passion for user design and user experience, creating data visualizations was a no-brainer for me. I was honestly dreading doing hard core programming or even graphic design! I think anyone who wants to learn (regardless of degree), enjoys solving complex problems and is willing to put on a critical thinking hat can do BI. It’s a field that requires passion, customer service, and THEN technical know how.
“I think anyone who wants to learn (regardless of degree), enjoys solving complex problems and is willing to put on a critical thinking hat can do BI. It’s a field that requires passion, customer service, and THEN technical know how.” — Mico Yuk on the importance of liberal arts majors entering BI
AH: In addition to a consultancy you also host a podcast, Analytics on Fire. What have you learned from that experience? How has it impacted you and your work? Do you have a favorite episode of all time?
Let’s just say AoF was a $50,000 failure in 2016. I took a break from podcasting for two and a half years (never planning to return, I’m embarrassed to admit that) but after 500-plus “please bring it back” messages from around the globe, I finally caved in and brought back Analytics on Fire in May of 2019. To my surprise we were greeted with 10,000+ monthly downloads and continue to grow!
In terms of lessons learned from hosting a podcast, there are so many hard lessons, but here a few key ones.
1) It’s a different audience. People who listen to podcasts don’t necessarily read blogs and vice versa. You must cater to both learning styles.
2) Be yourself. It’s challenging sometimes talking into a microphone, knowing that thousands of people are going to listen to it word for word. Very early on I decided to just be Mico.
3) Just go with it. I used to be a perfectionist, editing out any and everything that did not go as planned. Today I edit out nothing. Authenticity can be heard, not just seen.
The great thing about hosting a podcast with the biggest data influencers, our largest customers and some of our most successful students is getting a free PhD with each interview. It’s HARD to pick a favorite podcast. Seriously … this may affect me getting future guests lol. But, If I had to pick one, it would have to be Episode 33, with Andrew Mackay. I met Andrew back in 2014, while he was working in Saudi Arabia. He had just registered for our online BI Dashboard methodology course, and wanted to differentiate himself in the analytics field in the Middle East. Fast forward to 2019, where he sold his company to PWC and now the Director or Digital Transformation!
“It’s special to me, because I recall our discussion. I had no idea it would change his life. Those little things keep me motivated and going.” — Mico Yuk on hosting BI podcast ‘Analytics on Fire’
AH: I would like to go back to something you said earlier. You mentioned people who listen to podcasts don’t necessarily read blogs and vice versa. Can you elaborate on that for us in the content game? How do the learning styles differ?
MY: OMG … wow. This was such a freaking learning curve for us. After spending years writing a blog , we made a HUGE assumption (ass — out — of — you — and — me) that our thousands of loyal blog readers would automatically listen to our new Analytics on Fire podcast. Boy were we wrong! We quickly learned from our audience that they listen to our podcasts during their commutes, at the gym and even in the shower (like me). When done, most do not go to the podcast page to get the show notes and downloads, they just move on to the next podcast! So we are super careful how we use the limited notes we can post with each of our podcasts in iTunes, Spotify and other platforms, of course including a link to the full podcast page, but also including the podcast highlights, podcast artwork, and any special offers directly in the notes. Don’t get me wrong, there is some overlap, but we opened up to an entirely new audience which is amazing!
AH: What accomplishment are you most proud of this year?
MY: Disclaimer: I’m not good at talking about myself! I’m never really proud, just grateful. If I had to point out one thing, I never thought I would keynote events at Google, Facebook, and MIT to name a few. I’m now eyeballing a Ted Talk! I feel sooo blessed to have a platform where I can teach and inspire so many. It’s a responsibility I take very seriously. I look at what I do as more than a business, it’s a cause and one that changes people’s lives. I feel humbled and blessed that God chose me.
AH: What has you excited as we go into 2020? There are rumors that you will be chatting with Alberto Cairo very soon!
MY: Many things! This year we re-launched our Analytics on Fire podcast, kicked off our first three-day public BI Data Storytelling workshop (which sold out in six weeks), doubled our team size, expanded our technology focus to Microsoft Power BI and Power Apps. We also started our private BI Data Storytelling Mastery Facebook group which has over 1,500 enthusiast storytellers like me. In 2020 we not only plan to expand on all of the above, but I’m may be writing a book (hint hint) if I find the right publisher and finally relaunching our flagship online course, the BI Dashboard Formula. Needless to say, it’s going to be lit!
AH: I believe there is a difference between data visualization & data storytelling. I would love to hear your opinion on this to share with our readers.
MY: Of course there is — however, most of the big BI vendors (no name called) milk the definition to their benefit. It’s a constant uphill battle for us, as we see storytelling as the art of engaging your users with what you say, write and draw. We view data visualization as one of many means to engage users through drawing. It is just one small component of the data storytelling, but because it is the most visible it gets most of the attention. The reality is this — If you engage just the visual sense of your users, you won’t get long term adoption and buy in for your solution, whether it is a data visualization, dashboard or a reporting tool.
You first have to engage your users on an emotion level. There was a study done a while back by neuroscientist named Antonio Damasio, who concluded that human beings make decisions with their emotions, and then justify those decisions with logic aka data, not the other way around. Data visualization is great, but without engaging and really understanding the user’s story it’s useless IMO.
“Long story short, you need data storytelling to make data visualization useful and that is exactly what we teach at BI Brainz in our BI Data Storytelling Accelerator workshops.” — Mico Yuk on the importance of data storytelling
AH: Between running Analytics on Fire and being co-Founder of BI Brainz, how would you define your leadership style?
MY: Everyday I’m honored that people are willing to work for me and follow my dream. You have no idea. I get up before 5 a.m. everyday, and the first thing I do is thank God that by 9 a.m. my team is ready to go and our customers are excited to work with us. I depend on my amazing team at BI Brainz for EVERYTHING. People often see you on the top but they don’t realize it’s virtually impossible without insane support. I expect a lot from our team, and they over deliver. I want everyone to work to their strengths, but as a perfectionist I am always pushing them to do more, sometimes over the edge. Comfort zones bore me. My motto is, when you stop having fun, it’s time to change.
AH: When reading your website a few messages pop out like timeliness, quick turnaround times and visual presentation. Would you describe this as the secret sauce of your business? | https://medium.com/nightingale/mico-yuk-on-the-importance-of-community-and-the-paradigm-shift-in-business-intelligence-a297515204f5 | ['Allen Hillery'] | 2020-01-08 12:01:01.413000+00:00 | ['Analytics', 'Startup', 'Business Intelligence', 'Data Visualization', 'Women In Tech'] |
Fragranced Products Could Hurt Your Health | Fragranced Products Could Hurt Your Health
Americans are cleaning more than ever — and all those scented products are worrying consumer-health researchers
Even before the pandemic, Americans were among the world’s most enthusiastic users of scented home-cleaning products. Market research from the industry-tracking firm Statista shows that the United States ranks first in the world in spending on household cleaners; the U.S. spends more on these products than the next three countries on the list, combined.
The emergence of SARS-CoV-2 has only intensified the country’s zeal for scented wipes, sprays, detergents, soaps, and sanitizers. According to a recent study in Air Quality, Atmosphere & Health, the pandemic has initiated a “sweeping and surging use” of such products both in the U.S. and abroad.
While there’s certainly a heightened need for regular and thorough hand-washing, and probably also for frequent disinfection of door handles and other oft-touched surfaces, it’s not at all clear that Americans can scrub and spray the novel coronavirus into lavender-scented submission — especially if they’re doing so at home.
In August, an expert comment appearing in The Lancet reviewed some of the best research to date on surface-contact transmission. It concluded that the risks of a person catching the virus by touching an infected surface are “exaggerated.” Likewise, the U.S. Centers for Disease Control and Prevention now says that while surface-contact transmission is probably possible, it “is not thought to be a common way that COVID-19 spreads.” (Most experts now agree that close-range exposure to an infected individual — especially indoors — is the primary mode of transmission.) Even if surface-contact transmission is a thing, hand-washing and masks would foil most of the virus’s opportunities to move from a surface into a person’s body.
“A primary source of indoor air pollutants is fragranced consumer products, such as air fresheners and cleaning supplies.”
It would be one thing if commercial cleaners or disinfectants came with no downsides. And this seems to be the operating assumption that governs a lot of people’s approach to their use. But experts say that many of the chemicals in these products — and, notably, the chemicals that lend these products pleasing scents, which contribute nothing to their germ-clearing effectiveness — are linked to health harms ranging from headaches and skin rashes to asthma, immune system dysfunction, and heart trouble.
They may even contribute to some Covid-19-related risks.
The hazards of fragrance chemicals
Chemicals that give a product fragrance — whether that product is an all-purpose cleaner, a scented candle, an air freshener, or hair spray — have lately been worrying some consumer-health researchers. A 2020 review in Air Quality, Atmosphere & Health summarized some of the latest findings.
“As background, most of our exposure to pollutants occurs indoors,” writes Anne Steinemann, PhD, author of that review and a professor at the University of Melbourne in Australia. “A primary source of indoor air pollutants is fragranced consumer products, such as air fresheners and cleaning supplies.”
Steinemann is an expert in product emissions and environmental health, and has authored or co-authored dozens of studies on these topics. Her review catalogs a long list of health harms associated with fragrance chemicals, among which migraine headaches, breathing problems, and skin reactions are most common.
While a product’s list of ingredients may include a single word like “fragrance” or “parfum,” these or similar words often refer to a proprietary blend of several or even dozens of chemicals. The chemicals used in this blend do not have to be publicly disclosed, and may lawfully contain any one (or more) of the thousands of chemicals that are now approved for use in consumer products. This list includes volatile organic compounds (VOCs) and also endocrine-disrupting chemicals, so named because they may interfere in some way with the activity of the body’s hormones.
And that list of allowed fragrance chemicals is growing. “Even 10 years ago, the list included just one phthalate,” says Robin Dodson, PhD, an environmental exposure scientist at the nonprofit Silent Spring Institute in Massachusetts. Phthalates are a type of chemical that research has linked to elevated risks for breast cancer, reduced fertility, and asthma. “Now there are several phthalates on the list,” she says.
Dodson sometimes gives talks on the risks of consumer chemicals. She says that even health-conscious, in-the-know consumers are often unaware of how the U.S. chemical industry is regulated — or, in many cases, not regulated. “Something people are always surprised to learn is that only a minority of the chemicals in our products are thoroughly tested for toxicity,” she says. “Companies are allowed to put chemicals into products that have not been fully evaluated for safety, and often these chemicals are only flagged as harmful after evaluation by independent scientists.”
She highlights research findings that have linked phthalates and other fragrance chemicals to a heightened risk for asthma, suppressed immune function, and diabetes. All of these are on the CDC’s list of conditions associated with severe Covid-19 disease. “I don’t think it’s overboard to say that exposure to the chemicals could make you more susceptible to something like Covid-19,” she says.
More chemical concerns
Fragrance chemicals aren’t the only ones in consumer products that are associated with health problems. Far from it.
“Unfortunately, with Covid, we’re seeing a resurgence in the use of antimicrobials and other disinfectants that wipe out the virus but can be toxic or endocrine-disrupting in humans,” says Heather Patisaul, PhD, an expert in environmental chemicals and health at North Carolina State University.
Patisaul highlights a category of disinfectant chemicals called quaternary ammonium compounds (QACs or “quats”), which are found in products that were once mainly used in medical or commercial food-service settings but have since migrated into the home. According to a report from Mount Sinai and New York University, QACs now turn up in everything from disinfectant sprays and wipes to dish soaps, all-purpose cleaners, and baby products. Products labeled “antimicrobial” or “disinfectant” are most likely to contain QACs, which can be hard to avoid unless you memorize their names and look for them on the list of active ingredients.
“We’re exposed to a whole soup of these on a daily basis, and it’s that soup that most concerns me.”
“Although they are marketed as household disinfectants, they are actually certified by the EPA as pesticides, and they are overkill for cleaning at home,” Patisaul says. QAC’s are lung and skin irritants, “which is not great if you’re worried about Covid,” she says. They’re also “teratogenic,” meaning they have been shown to interfere with fetal development. They can also disrupt the actions of hormones in ways that may promote the development of cancer or immune dysfunction, though those specific harms are still theoretical. And that’s just one category of chemical among the hundreds found in household cleaning and personal care products.
Patisaul is part of a community of researchers and public health advocates who for years have worked to raise awareness of the dangers of consumer chemicals — both to people and to the environment. The emergence of Covid-19 — and the persistent misconception that a “clean” person, place, or thing is one bathed in some kind of scented product — threaten to undo much of their good work.
The Silent Spring Institute’s Dodson says that U.S. health authorities, unlike oversight bodies in some other countries, tend to apply an “innocent until proven guilty” standard to consumer chemicals. And especially when it comes to cancer, immune dysfunction, and other slow-to-emerge, multifactorial health conditions, establishing “proof” of harm is next to impossible.
“We’re ubiquitously exposed to these chemicals — they’re everywhere — and so there’s really no way to compare people who’ve been exposed to those who have not been exposed to see what might happen 30 years later,” Dodson says. Even if you could do that type of experiment, it wouldn’t reveal how the combination of hundreds of these chemicals might interact with an individual’s unique biology in ways that could create disease or damage.
“We’re exposed to a whole soup of these on a daily basis, and it’s that soup that most concerns me,” she adds.
How to avoid the risks
Ditching fragranced products is a good first step, Dodson says. Even if you’re unwilling to part with a favorite cologne or perfume — and yes, those products also contain potentially harmful chemicals — she points out that most American households contain a panoply of scented cosmetics, lotions, detergents, air fresheners, candles, and cleaning products. “None of us needs fragranced trash bags,” she says. “We can all skip those.”
Unfortunately, avoiding fragrance chemicals may be easier said than done. While products labeled “fragrance free” are often good options, those labeled “unscented” may actually contain additional chemicals used to mask a product’s unpleasant odor, Dodson says. Searching out products labeled “green” or “organic” also isn’t much use; research has found that those products often emit some of the same harmful pollutants as regular products.
On the other hand, simply buying and using fewer cosmetics and cleaning products is one good way to cut back exposure. And if ditching a product isn’t possible, the nonprofit Environmental Working Group provides helpful resources for finding safer options for cleaning and personal care. The Silent Spring Institute’s Detox Me app is also a useful tool.
“None of us needs fragranced trash bags. We can all skip those.”
When it comes to safely ridding your home, car, or other areas — not your hands or body — of SARS-CoV-2, simple and old-school cleaning solutions may be the safest options. “Hydrogen peroxide, citric acid, or octanoic acid are safe and effective,” says NCSU’s Patisaul.
Each of these is on the Environmental Protection Agency’s list of products that can effectively inactivate SARS-CoV-2 on surfaces. They’re all inexpensive and easy to find. Just make sure you’re not mixing them with vinegar or other cleaners, which Patisaul says can create a toxic cocktail. (According to resources from the University of North Carolina, mixing one part over-the-counter hydrogen peroxide with one part water creates a solution that will inactive the coronavirus on surfaces.)
To clean your hands and body, the CDC says that plain old soap and water is the best and safest way to go. If you can’t wash, hand sanitizers are a next-best option; fragrance-free, alcohol-based products that contain at least 60% alcohol are effective, per the CDC, and need not contain any other chemicals to effectively neutralize the virus.
Looking beyond the pandemic, Dodson says that in order to meaningfully reduce the public’s exposure to harmful consumer chemicals, regulators will need to implement more robust safety standards. Today, even if a person is diligent about avoiding harmful chemicals, that person may still be exposed to harmful levels at work, at school, or elsewhere.
“We really need better safeguards in place,” she says. | https://elemental.medium.com/fragranced-products-could-hurt-your-health-f746b7680f71 | ['Markham Heid'] | 2020-10-22 05:33:29.367000+00:00 | ['Health', 'Lifestyle', 'The Nuance', 'Cleaning', 'Science'] |
The Volunteers who Challenge the Virus: Controlled Human Infections | The Volunteers who Challenge the Virus: Controlled Human Infections
Would you be a volunteer who challenges the virus?
Photo by Obi Onyeador on Unsplash
In a time where everybody tries to protect themselves from COVID-19 — by wearing masks, respecting social distancing, or avoiding shared surfaces — some are facing the virus head-on!
Yes, thousands of people have expressed interest in participating in Controlled Human Infection (CHI) studies with SARS-CoV-2, the causative agent of COVID-19.
CHI studies aim to speed up the development of a vaccine for COVID-19. According to 1daysooner.org, a website that encourages people to volunteer to participate in human challenge trials or to advocate on their behalf, almost 30000 people from 140 countries have already applied to deliberately expose themselves to SARS-CoV-2. This is surprising, given that COVID-19 is like the “perfect” pandemic, it killed almost 500000 people worldwide and no specific treatments are available.
Why do these volunteers want to take on a life-threatening risk?
There are multiple reasons: some have strong motivations to help others, some people are motivated by the money while other volunteers are curious of the experience.
The perspective of one 41-year-old volunteer is very interesting, as the owner of a business that has him visiting warehouses and flying regularly, he figures he’ll inevitably get infected anyways, so he declared on CNN: “I feel if I did it under a controlled environment, and I had an adverse reaction, my chances are much better”.
On one hand, Dr. Lipsitch, a Harvard epidemiologist, confirmed that
“as a part of being in the trial they [partecipants] would be guaranteed excellent care if they needed it”.
On the other hand, controlled human infection studies continue to generate controversy within the scientific community especially from an ethical point of view.
It may seem impermissible to ask people to take on the risk of severe illness or death, even for an important collective gain.
To better understand the scientific doubts on this matter let’s start by defining controlled human infection studies.
In CHI studies, a small number of healthy participants are deliberately exposed to a known dose of a pathogen in a controlled setting, to study infection and gather preliminary efficacy data on experimental vaccines or treatments.
CHI studies, by allowing preliminary efficacy testing in 10–100 participants, are cheaper than phase 2 and 3 clinical trials that often require sample sizes ranging from hundreds to hundreds of thousands of participants. Thus, they help to identify inferior vaccine candidates or treatments before initiating large safety and efficacy trials, allowing valuable resources to be focused on those candidates that have the greatest potential for success.
CHI studies have emerged as powerful tools to select promising new vaccines or drugs on the increasingly complex and expensive path towards licensure. In this decade more than 120 controlled human infection studies have been published, primarily for influenza, rhinovirus, typhoid and malaria.
A malaria CHI study provided critical information for the development of the malaria vaccine RTS,S. Malaria CHI studies were performed to first evaluate the efficacy of this vaccine and to then further refine the formulation and dosing regimen before initiating Phase 3 efficacy evaluations in Africa.
A dengue CHI study was used to determine which formulation of a live-attenuated tetravalent dengue vaccine should be chosen to move forward in a Phase 3 efficacy trial in Brazil. | https://medium.com/beingwell/the-volunteers-who-challenge-the-virus-controlled-human-infections-321e5d2fb887 | ['Valentina Colapicchioni'] | 2020-06-25 11:10:30.016000+00:00 | ['Vaccines', 'Health', 'Research', 'Science', 'Clinical Trials'] |
Deploy a Production Django App With Elastic Beanstalk (Part 2) | Setting up S3 — Static and Media Storage
Up to this point, we have a working Django app deployed on Elastic Beanstalk Amazon Linux 2. Congratulations! However, we still need to set up S3 so the site shows styles and we can upload images — which would be nice, considering it’s an image of the day app!
Create a group and user
First things first: We need to create an IAM user with programmatic access so our application can access the S3 bucket we’re creating next. Best practice here is to create a group with the appropriate policies attached and add a new user to the group. Note: I highly recommend creating a new user for the application’s S3 access. Using an admin user opens all kinds of security risks.
In the AWS services search bar, look for IAM. Navigate to IAM → Groups → Create New Group. Set the group name to something like “S3FullAccess” and go to the next step. Here, search for “S3” and select AmazonS3FullAccess . Click on the next step and create the group.
Now, we’ll navigate to “Users” and add a new user. Name the user whatever you want, I’ll go with “iotd-s3-access” and select “Programmatic Access.”
Click to permissions and add this user to the group we created. Click through and create the user.
After the user is created, you will get a success notification and be able to save the Access key ID and Secret access key. Important: if you don’t save these credentials here, you will not be able to see them again. You will have to delete this user and create a new one to get credentials again.
Download the .csv file with the credentials in it and head back over to the iotd project settings file. Add two new settings at the end of iotd/settings.py — we’re not going to add the keys, but instead references to them:
if 'AWS_ACCESS_KEY_ID' in os.environ:
AWS_ACCESS_KEY_ID = os.environ['AWS_ACCESS_KEY_ID']
AWS_SECRET_ACCESS_KEY = os.environ['AWS_SECRET_ACCESS_KEY']
Committing the actual keys in your settings file is a dangerous idea. It poses a security vulnerability if anyone were to gain access to your project’s code (GitHub or otherwise). Instead of keeping them in the settings file, we’re going to add them as environment variables and pull them into the settings file securely. Docs here.
Create a bucket
Before we get into environment variables, navigate to S3, and create a new bucket. Make sure to turn off the block public access. We’ll need the images stored here to be public to show them in the API and have access to them later on. Name your bucket whatever you want. I usually recommend enabling versioning, but this is optional. Click “Create Bucket” and we’re all set. | https://medium.com/better-programming/production-django-elastic-beanstalk-part2-4501caf7d8fb | ['Zack Petersen'] | 2020-12-15 16:49:55.854000+00:00 | ['Python', 'Database', 'AWS', 'Django', 'Programming'] |
Tools for Machine Learning and Artificial Intelligence in Analytics | Photo by Mitchell Luo on Unsplash
By tools for analytics, the reference are to apps that allow for environments to create solutions, language, libraries, and even graphical user interface to manipulate data for insights from information. There are many tools for data analytics. What is available?
Tools
Anaconda provides environment for Python and R including machine learning for mac/linux/windows. After downloading the app and installing, the environment can be customized to include variety of data science tools with libraries. Anaconda is used desktop but also exists as a cloud version.
JetBrains is an organization with a lot of apps for specific goals. There is PyCharm for Python, DataGrip for Databases, RubyMine for Ruby, and more. For analytics, the tool set and ability to integrate across their tools is unique. The positive is creating full apps that have artificial intelligent components or subcomponents and code for other pieces of the app in languages like PHP that can work together in a JetBrains solution.
Google has a few analytics tools, most notably, Looker and Google Cloud Platform.
Microsoft Access, Azure, Excel, and Power BI all provide analytics and data service.
IBM has SPSS and Watson tools there are cloud and local versions of each platform. SPSS provides analytics and smart menus in a graphical user interface. Watson is famous for its performance on “Jeopardy” January 14, 2011 where it was tasked with competing against humans in trivia. Now, it is a service that can be tasked with data challenges.
Salesforce has Tableau which is a business oriented analytics service.
Snowflake is a data warehouse and analytics provider providing data services.
Photo by Patrick Fore on Unsplash
I have experience in cloud and local tools. Cloud is trending, easy, and has great benefits. Artificial Intelligence is highly integrated into tool platforms with a range of how much control the developer or user has in method and performance. The introduction of smart menus and graphical user interfaces for analytics has changed the way many approach data analytics and data science. It is more friendly and requires more knowledge of how processes work to gain results with meaning and coherence.
Conclusion
There are different ways and tools to develop a solution for knowledge from data. Analytics done in code is more control and provides specific results. Using a toolset that has blocks is less control and provides results that are based on subunits creating a tradeoff on control, how a process works. Last, using an app and selecting by forms and menus is little control over process, easy, and will process according to parameters with little seen of the computation. Choice is there for tools specifically with machine learning and artificial intelligence, however best fit for the situation and conditions is important. | https://medium.com/ai-in-plain-english/tools-for-machine-learning-and-artificial-intelligence-in-analytics-5313c2ba05e | ['Sarah Mason'] | 2020-12-28 08:04:44.217000+00:00 | ['Machine Learning', 'Analytics Platforms', 'Artificial Intelligence', 'Analytic Applications', 'AI'] |
How to Learn Coding: From Theory to Practice | source: Unsplash
Software development is one of the most popular professions today with an average salary of $59,568 a year. As the demand for promising coding professionals is not going anywhere, many people strive to master new skills to join the ranks of developers. But, even if you don’t plan to become a full-time developer, obtaining experience in coding will open up more opportunities and greatly benefit your future career.
In this post, I will help you start your journey in the world of coding — you will figure out the best ways to make the learning process efficient. Following these tips will put you on the right track.
Top Recommendations on How to Learn Coding
There is no single correct algorithm to follow to become a first-class developer. However, I have a few encouraging pieces of advice for everyone who wants to learn to code independently but has no idea where to start.
Let’s get right to the point.
Start with a Brainstorm
Every single process requires thorough preparation. Coding is no exception. Before starting to learn any programming language, it is quite important to decide on the real reasons you want that. Answering the following questions will let you figure that out.
What reasons are there to become a dev?
Am I going to learn just for fun?
Do I want to get a promotion or change my career?
Do I have an idea for my own app and need appropriate skills for it?
What kind of software developer do I want to become?
Do I plan to work in a company?
Do I want to work individually?
Is freelance a better option for me?
What industries am I interested in?
Web development?
Server-side projects?
Game development?
Big Data, or others?
Additionally, do some research among different industries, be it fintech or AI, enquire about what kind of programmers they are looking for, and learn job specifics and salaries to decide where you want to work. Of course, if you already have a preferred industry in your mind, you’re a step ahead.
Answering the given questions will also help you determine the programming language to master. E.g., creating a well-performing OS or alternatives to prominent photo editors may only require studying formal computer science. The latter will give you a clear understanding of C++ language, data structure, memory allocation, and algorithms.
Although, if you want to make a mid-career change to a tech job, it is reasonable to apply for an intensive website development program rather than spend a fortune on obtaining the second degree.
Choosing the Right Programming Language
Now you know the reason for learning to code, so choosing the right language will be way easier.
In a few words, mobile apps flawlessly perform if they are based on Java, Swift or Kotlin. Javascript, in its turn, is suitable for front-end development, while PHP and Python will benefit back-end devs. To create video games, developers prefer C++.
Choosing the programming language requires considering its popularity on the market. Let’s take a quick look at the TIOBE Index. Java has never left the top three most popular coding languages. Two other languages commonly used in many areas of software development include C and Python, which are unlikely to lose their popularity in the coming years.
For a better idea on the most commonly used programming languages, I will give you a quick overview of them.
Java
Java is an easy-to-manage object-oriented multithreaded programming language with a good level of security. It is an independent platform that follows the clue “Write once, Run anywhere”, which means you can transfer the already written app between different platforms. Java also ensures backward compatibility and is easier to keep up with compared to C++ and any other programming languages.
Main uses:
Server-side enterprise applications
Desktop enterprise
Android apps (including games)
Big Data
Embed Scientific Applications Systems
Finances and Trading
Software Tools
Sometimes — Big Games (such as Minecraft)
Python
Python is another high-level, server-side interpreted scripting language. It can be used as an independent language or as a part of another framework. With its constructs and object-oriented approach, it allows developers to write readable code for small and large projects.
Main uses:
Desktop GUIs
Software
AI and ML
Data science and visualization
Web scraping apps and more
C Language
C language is a machine-independent, general-purpose programming language frequently used in various applications, including low-level ones. There is an opinion that it is a base for programming, so if you’ve mastered C language, you can easily master the others.
Main uses:
Embedded systems
System and desktop apps
Browsers and their extensions
Databases
Operating systems
Javascript
JavaScript, abbreviated as JS, determines a high-level and multi-paradigm programming language used for client-side page behavior. JS is also known as one of the key technologies enabling interactive web pages and playing a significant role in building web apps.
Main uses:
Front-end web development
Non-browser applications
Games and APIs
Web-based slide decks
Smartwatch apps, etc
PHP
PHP refers to an open-source scripting language used to generate dynamic page content that supports a wide range of databases. PHP runs on various platforms and is compatible with almost all commonly used servers, including Apache, IIS, and others. PHP files can support text, HTML, CSS, JavaScript, and PHP code.
Main uses:
Web development (backend)
LAMP platform used by Facebook and Yahoo
CMS platforms
Form data collection
Encrypted data
Cookies
SQL
SQL stands for Structured Query Language used to work with databases. MySQL, an open-source version of SQL, is the most common way to interact with databases.
Main uses:
Relational database management systems
Data query language
Database transaction management
Manual analysis
Procedures, user-defined functions, triggers, indexes, etc.
Swift
Swift is a six-year-old product by Apple Inc. built using a modern approach to safety, performance, and software design patterns. This general-purpose coding language makes writing and maintaining programs easier for developers.
Main uses:
Mobile and desktop apps for iOS and OS X
Cloud services
A new class of modern server applications
Event-driven network application framework
Server-oriented tools and technologies, comprising metrics and database drivers, etc.
C#
C# language (pronounced “see sharp”) is more or less like Java, but made by Microsoft. It is a type-safe object-oriented language used to build secure and robust apps that run in the .NET ecosystem.
Main uses:
Backend services
Microsoft .NET-connected apps
Windows apps
Server-side web applications
Games with the Unity game engine, etc.
Give Online Courses a Try
If you don’t feel comfortable about an in-person coding-intensive program, there are multiple courses on the web to choose from. Since many of them teach the same coding language in different ways and picking up the right course may be challenging, I’ve put together a few working solutions.
Practical Training
I’ve recently had a talk with fellow developers about what advice they would give to newbies. They all answered that the more practice, the better. So, I’ve decided to put practical training in the first place. Other than theory, coding needs practice that allows for developing problem-solving skills. For this, you need to choose the right platform.
For instance, you can go for coding platforms based on practice, such as:
CodeGym. This online course is directly aimed at studying Java programming and consists of 80% practice. Despite the theory, it offers 1200 small practical tasks of increasing complexity. To get experience and land a job, you need to write tons of code.
FreeCodeCamp with a whole lot of project-based tasks. Also, they have a great News and Forum section. You could get a certification in Python, JavaScript, HTML, CSS, etc.
Code4Startup with an ability to write your first line of code for an existing business.
Codewars addictive assignments that let you test your skills while competing with your fellow developers.
Code Avengers with a bulk of engaging quizzes on different programming languages, etc.
Theoretical Training
Regardless of what you are learning, the educational process is not complete without the theory. I would say you should try Udacity. It is a MOOC-based platform, so everyone who wants to start learning to code can sign up and get an online learning experience right away.
I like the range of courses this website offers. They are in micro-credential form, also known as Nanodegrees. The micro-credentials that are sometimes released for free come with video courses and projects. So, you can choose one to your liking, sorting them by language and level.
If to say about other resources used for theoretical training, I would also highlight books as an additional source of learning. Every learning process requires starting with the details, hence involves familiarization with the theory in one way or another. It is likely to give you a good idea of coding. So, if you are looking for helpful books, I would recommend considering the next three.
Clean Code: A Handbook of Agile Software Craftsmanship by Robert C. “Uncle Bob” Martin
The Pragmatic Programmer: From Journeyman to Master by Andrew Hunt and Dave Thomas
Code Complete: A Practical Handbook of Software Construction by Steve McConnell
Put Interactive Tutorials and Coding Games on the List
What makes interactive coding tutorials good is that they bring into action the so-called abstract concepts you would read about in a book, so you won’t get bored while obtaining the programming experience.
For instance, the CodeGym platform offers different coding gamified projects in the Games section. The whole course has an exciting plot, vivid characters, and a tricky concept explained through real-life examples, you will keep training without getting bored. For example, there are four cool quests with a robot named Amigo. Every single quest contains ten levels with 12 to 13 lessons and guides through different subjects from Java Core to Java Multithreading.
So, students can’t jump to the next level or more fun stuff until they debug the code while learning, which is very useful, as if you want to become a programmer, you need to code.
The other courses I’ve previously mentioned also offer interactive tutorials, quizzes, and other engaging tasks, such as:
Project Caesar Cipher on Ruby programming at the Odin Project
Mastering different languages on kata at Codewars
Different gamified courses at Code Avengers, etc.
Consider Watching Videos When Learning to Code
People perceive information differently: one prefers reading books or taking courses, while the other chooses to watch videos on platforms like YouTube. Learning to code by watching videos is cost-saving and allows for moving at your own pace — you can either spend more time on the video or skip ahead if things seem easy to you.
YouTube is home to numerous educational videos dedicated to software development. Here you can find coding marathons and solutions that show how to troubleshoot issues within any programming language you can imagine. So, if you are the one searching for decent content, my top-ten list of YouTube channels for coding is at your disposal.
Google the Error
Let’s face it: everyone who learns to code experiences errors that break their code. You are not alone in your problem — there are many users before you who have made the same mistakes and already found solutions. So, if you are struggling to understand why your code is broken and can’t find the explanation, try to google the error. This is a simple yet effective trick that is more likely to give answers to your concerns.
Otherwise, you can leave your question on Q&A or discussion websites, such as Stack Overflow, Reddit, or GitHub.
Unpack Someone Else’s Code
As soon as you get a clear idea of how to code, it’s time to move further and strengthen your knowledge of the programming language. Here we come to the unpacking of someone else’s code. Browse GitHub to find the code file, open it in your code editor, and start working through. Feel free to apply your changes if you see they can improve the outcome. When done, save the edited code and share it back with the community to get feedback from your peers.
Communicate with Other Programmers
Teaching yourself to code and spending hours at the computer can put you out of reality. Even though figuring things out on your own may be the best way to learn coding, sometimes outside help is necessary to get to the solution faster.
Communicate with other developers, visit tech talks of all kinds, hackathons, startups, and other tech events to make useful contacts. Or the simplest way is through online forums. Here they are:
Github is a community where people learn, share, and work together to build software. It allows for managing your open-source projects, contributing to others, showcasing your work, attracting recruiters, and more.
StackOverflow is a Q&A website for both newbies and experienced programmers. It lets you find answers to the toughest coding questions, share knowledge, and even find your dream job.
HackerNews is a highly trusted cybersecurity news platform attracting IT professionals, hackers, technologists, and others. It features the latest security news and builds a bridge between communities like security researchers, business grads, and thousands of security professionals.
Reddit is a social news aggregation and discussion website. It puts together thousands of communities and lets users share the things they care about. All you have to do is find the right subreddits about programming.
Come Up with Your Own Project and Implement It
Building your own project, like a little app or so, is a good idea if you want to stay motivated about teaching yourself to code. Your own project forces you to move forward, keep practicing, and overcome grief and blockages. So, to start:
Set a goal to create a project.
Make sure you and other people need it in real life.
Use the skills you already have.
Work to improve and extend your project’s scope of application.
Plan future features and consider the skills you would need for their implementation.
Extra Tips to Stay Motivated
Coding is not easy — like many other beginners, you may sometimes fail, become frustrated, stop all attempts to cope with lines of code, and give up. That is why you need to create a friendly atmosphere around you while learning to code. Try to avoid becoming a strict parent or primary school teacher who scolds you for mistakes. Be a friend to yourself and remember a few things.
Never compare yourself to other developers. Although the advice has a cliché, it is one to remember. Everyone starts somewhere — those who are on chapter 20 today have started from chapter 1, where you are now, and once wrote their first line of code, just like you.
You’re making much more progress than you think. Have you ever thought you are not progressing? Sure, you have. Everyone who starts learning something passes that. You start thinking you’re not making enough effort, nothing changes, and you are still on the same stage you started with. However, the fact is that every time you study or code, you are growing — just accept it and look back to see how much you’ve already done.
Everyone struggles in the beginning. The learning process is always challenging, but that doesn’t mean you are going to be a bad coder. Feeling frustrated is normal, especially if you’ve just started training and everything seems vague to you.
Let’s Wrap It Up
How long does it take to learn coding? There is no single correct answer, as everyone starts with their own level of training and at their own pace. However, if you follow the given advice, you can get to your first line of code a little bit faster. For this, start with small things, like choosing the appropriate programming language and taking online courses. Then move on to bigger ones, like completing tasks on different platforms, unpacking someone else’s code, and building your own project.
The learning process is not a piece of cake, so make sure to create a friendly environment and support yourself, especially when you want to give up. The understanding that you are in the same boat with other developers who take the same steps during this path to coding will help you stay motivated about teaching yourself to code. | https://medium.com/quick-code/how-to-learn-coding-from-theory-to-practice-265e5ea68bf1 | ['John Selawsky'] | 2020-08-08 04:04:02.021000+00:00 | ['Python', 'C Sharp Programming', 'Learn Coding', 'Java', 'Programming Languages'] |
Tell the World About It, Even if the World Doesn’t Care | I migrated my blog last weekend. Over ten years worth of articles! (though I should say that I haven’t blogged regularly since 2013) Goodbye self-hosted static site with CSS from 2009. Hello Medium. It’s possible that I’m a little late to this party.
In the end, I didn’t end up importing everything. Because Medium appears to lack the ability to auto-import articles from Jekyll (preposterous! who would have thought?!), I had to manually migrate — or at least extensively edit — most of the content. Only the top 50 or so articles that were receiving significant traffic from Google Analytics made the cut. So I had an excuse to cheat a bit and discard a lot of the chaff.
Looking back on the rants and raves of 20-something me (the way that soon 40-something me will look back on 30-something me), even the best of those posts can still seem rather embarrassing. Misplaced enthusiasm for absurd tools, often impractical NIH-ism, and terrible grammar are among the many crimes of my youth. It’s also readily apparent that the tech industry as a whole has evolved a lot; 2007’s developer best practices were not what we would today consider practices at all, let alone preferential practices. Such is progress.
Reading through those old posts was also inspiring. It reminded me that at one time a regular writing schedule served a super important developmental function for me. It’s widely documented that there are a bunch of pretty great benefits that one gets from writing on the regular. It helps you organize and reframe your thoughts, it can be therapeutic during hard times, and improves memory recall. If nothing else, it’s a fantastically cheap type of external memory. Writing something down means you never have to ask “what exactly did I do yesterday, anyway?” or “how long did that crazy project take me and what did I actually learn from it?” (anyone who doesn’t manage their life through daily TODO lists is definitely missing out on an awesome party).
The most important benefit for me was that writing in public was a way of committing myself to certain things, on a certain schedule, at a time when my life was pretty much completely unscheduled. Knowing that I had to publish an article every week, or every month, or on any schedule really, ensured that I was continuously learning things that were worth talking about, and later, building things that had enough value to share… even if I was sometimes inventing those things just so I could share them. And even if no one was listening (which was frequently the case).
Not everyone needs this sort of framework for self-discipline. But it sure helped me when I needed it most. | https://medium.com/zerosum-dot-org/tell-the-world-about-it-even-if-the-world-doesnt-care-48130678a333 | ['Nick Plante'] | 2017-12-08 00:49:14.192000+00:00 | ['Software Development', 'Productivity', 'Blogging', 'Life Hacking', 'Writing'] |
How it optimize the disk usage in the Prometheus database? | How it optimize the disk usage in the Prometheus database?
Learn some tricks to analyze and optimize the usage that you are doing of the TSDB and save money on your cloud deployment.
Photo by Markus Spiske on Unsplash
In previous posts, we discussed how the storage layer worked for Prometheus and how effective it was. But in the current times, we are of cloud computing we know that each technical optimization is also a cost optimization as well and that is why we need to be very diligent about any option that we use regarding optimization.
We know that usually when we monitor using Prometheus we have so many exporters available at our disposal and also that each of them exposes a lot of very relevant metrics that we need to track everything we need to. But also, we should be aware that there are also metrics that we don’t need at this moment or we don’t plan to use it. So, if we are not planning to use, why do we want to waste disk space storing them?
So, let’s start taking a look at one of the exporters we have in our system. In my case, I would like to use a BusinessWorks Container Application that exposes metrics about its utilization. If you check their metrics endpoint you could see something like this:
# HELP jvm_info JVM version info
# TYPE jvm_info gauge
jvm_info{version="1.8.0_221-b27",vendor="Oracle Corporation",runtime="Java(TM) SE Runtime Environment",} 1.0
# HELP jvm_memory_bytes_used Used bytes of a given JVM memory area.
# TYPE jvm_memory_bytes_used gauge
jvm_memory_bytes_used{area="heap",} 1.0318492E8
jvm_memory_bytes_used{area="nonheap",} 1.52094712E8
# HELP jvm_memory_bytes_committed Committed (bytes) of a given JVM memory area.
# TYPE jvm_memory_bytes_committed gauge
jvm_memory_bytes_committed{area="heap",} 1.35266304E8
jvm_memory_bytes_committed{area="nonheap",} 1.71302912E8
# HELP jvm_memory_bytes_max Max (bytes) of a given JVM memory area.
# TYPE jvm_memory_bytes_max gauge
jvm_memory_bytes_max{area="heap",} 1.073741824E9
jvm_memory_bytes_max{area="nonheap",} -1.0
# HELP jvm_memory_bytes_init Initial bytes of a given JVM memory area.
# TYPE jvm_memory_bytes_init gauge
jvm_memory_bytes_init{area="heap",} 1.34217728E8
jvm_memory_bytes_init{area="nonheap",} 2555904.0
# HELP jvm_memory_pool_bytes_used Used bytes of a given JVM memory pool.
# TYPE jvm_memory_pool_bytes_used gauge
jvm_memory_pool_bytes_used{pool="Code Cache",} 3.3337536E7
jvm_memory_pool_bytes_used{pool="Metaspace",} 1.04914136E8
jvm_memory_pool_bytes_used{pool="Compressed Class Space",} 1.384304E7
jvm_memory_pool_bytes_used{pool="G1 Eden Space",} 3.3554432E7
jvm_memory_pool_bytes_used{pool="G1 Survivor Space",} 1048576.0
jvm_memory_pool_bytes_used{pool="G1 Old Gen",} 6.8581912E7
# HELP jvm_memory_pool_bytes_committed Committed bytes of a given JVM memory pool.
# TYPE jvm_memory_pool_bytes_committed gauge
jvm_memory_pool_bytes_committed{pool="Code Cache",} 3.3619968E7
jvm_memory_pool_bytes_committed{pool="Metaspace",} 1.19697408E8
jvm_memory_pool_bytes_committed{pool="Compressed Class Space",} 1.7985536E7
jvm_memory_pool_bytes_committed{pool="G1 Eden Space",} 4.6137344E7
jvm_memory_pool_bytes_committed{pool="G1 Survivor Space",} 1048576.0
jvm_memory_pool_bytes_committed{pool="G1 Old Gen",} 8.8080384E7
# HELP jvm_memory_pool_bytes_max Max bytes of a given JVM memory pool.
# TYPE jvm_memory_pool_bytes_max gauge
jvm_memory_pool_bytes_max{pool="Code Cache",} 2.5165824E8
jvm_memory_pool_bytes_max{pool="Metaspace",} -1.0
jvm_memory_pool_bytes_max{pool="Compressed Class Space",} 1.073741824E9
jvm_memory_pool_bytes_max{pool="G1 Eden Space",} -1.0
jvm_memory_pool_bytes_max{pool="G1 Survivor Space",} -1.0
jvm_memory_pool_bytes_max{pool="G1 Old Gen",} 1.073741824E9
# HELP jvm_memory_pool_bytes_init Initial bytes of a given JVM memory pool.
# TYPE jvm_memory_pool_bytes_init gauge
jvm_memory_pool_bytes_init{pool="Code Cache",} 2555904.0
jvm_memory_pool_bytes_init{pool="Metaspace",} 0.0
jvm_memory_pool_bytes_init{pool="Compressed Class Space",} 0.0
jvm_memory_pool_bytes_init{pool="G1 Eden Space",} 7340032.0
jvm_memory_pool_bytes_init{pool="G1 Survivor Space",} 0.0
jvm_memory_pool_bytes_init{pool="G1 Old Gen",} 1.26877696E8
# HELP jvm_buffer_pool_used_bytes Used bytes of a given JVM buffer pool.
# TYPE jvm_buffer_pool_used_bytes gauge
jvm_buffer_pool_used_bytes{pool="direct",} 148590.0
jvm_buffer_pool_used_bytes{pool="mapped",} 0.0
# HELP jvm_buffer_pool_capacity_bytes Bytes capacity of a given JVM buffer pool.
# TYPE jvm_buffer_pool_capacity_bytes gauge
jvm_buffer_pool_capacity_bytes{pool="direct",} 148590.0
jvm_buffer_pool_capacity_bytes{pool="mapped",} 0.0
# HELP jvm_buffer_pool_used_buffers Used buffers of a given JVM buffer pool.
# TYPE jvm_buffer_pool_used_buffers gauge
jvm_buffer_pool_used_buffers{pool="direct",} 19.0
jvm_buffer_pool_used_buffers{pool="mapped",} 0.0
# HELP jvm_classes_loaded The number of classes that are currently loaded in the JVM
# TYPE jvm_classes_loaded gauge
jvm_classes_loaded 16993.0
# HELP jvm_classes_loaded_total The total number of classes that have been loaded since the JVM has started execution
# TYPE jvm_classes_loaded_total counter
jvm_classes_loaded_total 17041.0
# HELP jvm_classes_unloaded_total The total number of classes that have been unloaded since the JVM has started execution
# TYPE jvm_classes_unloaded_total counter
jvm_classes_unloaded_total 48.0
# HELP bwce_activity_stats_list BWCE Activity Statictics list
# TYPE bwce_activity_stats_list gauge
# HELP bwce_activity_counter_list BWCE Activity related Counters list
# TYPE bwce_activity_counter_list gauge
# HELP all_activity_events_count BWCE All Activity Events count by State
# TYPE all_activity_events_count counter
all_activity_events_count{StateName="CANCELLED",} 0.0
all_activity_events_count{StateName="COMPLETED",} 0.0
all_activity_events_count{StateName="STARTED",} 0.0
all_activity_events_count{StateName="FAULTED",} 0.0
# HELP activity_events_count BWCE All Activity Events count by Process, Activity State
# TYPE activity_events_count counter
# HELP activity_total_evaltime_count BWCE Activity EvalTime by Process and Activity
# TYPE activity_total_evaltime_count counter
# HELP activity_total_duration_count BWCE Activity DurationTime by Process and Activity
# TYPE activity_total_duration_count counter
# HELP bwpartner_instance:total_request Total Request for the partner invocation which mapped from the activities
# TYPE bwpartner_instance:total_request counter
# HELP bwpartner_instance:total_duration_ms Total Duration for the partner invocation which mapped from the activities (execution or latency)
# TYPE bwpartner_instance:total_duration_ms counter
# HELP bwce_process_stats BWCE Process Statistics list
# TYPE bwce_process_stats gauge
# HELP bwce_process_counter_list BWCE Process related Counters list
# TYPE bwce_process_counter_list gauge
# HELP all_process_events_count BWCE All Process Events count by State
# TYPE all_process_events_count counter
all_process_events_count{StateName="CANCELLED",} 0.0
all_process_events_count{StateName="COMPLETED",} 0.0
all_process_events_count{StateName="STARTED",} 0.0
all_process_events_count{StateName="FAULTED",} 0.0
# HELP process_events_count BWCE Process Events count by Operation
# TYPE process_events_count counter
# HELP process_duration_seconds_total BWCE Process Events duration by Operation in seconds
# TYPE process_duration_seconds_total counter
# HELP process_duration_milliseconds_total BWCE Process Events duration by Operation in milliseconds
# TYPE process_duration_milliseconds_total counter
# HELP bwdefinitions:partner BWCE Process Events count by Operation
# TYPE bwdefinitions:partner counter
bwdefinitions:partner{ProcessName="t1.module.item.getTransactionData",ActivityName="FTLPublisher",ServiceName="GetCustomer360",OperationName="GetDataOperation",PartnerService="TransactionService",PartnerOperation="GetTransactionsOperation",Location="internal",PartnerMiddleware="MW",} 1.0
bwdefinitions:partner{ProcessName=" t1.module.item.auditProcess",ActivityName="KafkaSendMessage",ServiceName="GetCustomer360",OperationName="GetDataOperation",PartnerService="AuditService",PartnerOperation="AuditOperation",Location="internal",PartnerMiddleware="MW",} 1.0
bwdefinitions:partner{ProcessName="t1.module.item.getCustomerData",ActivityName="JMSRequestReply",ServiceName="GetCustomer360",OperationName="GetDataOperation",PartnerService="CustomerService",PartnerOperation="GetCustomerDetailsOperation",Location="internal",PartnerMiddleware="MW",} 1.0
# HELP bwdefinitions:binding BW Design Time Repository - binding/transport definition
# TYPE bwdefinitions:binding counter
bwdefinitions:binding{ServiceName="GetCustomer360",OperationName="GetDataOperation",ServiceInterface="GetCustomer360:GetDataOperation",Binding="/customer",Transport="HTTP",} 1.0
# HELP bwdefinitions:service BW Design Time Repository - Service definition
# TYPE bwdefinitions:service counter
bwdefinitions:service{ProcessName="t1.module.sub.item.getCustomerData",ServiceName="GetCustomer360",OperationName="GetDataOperation",ServiceInstance="GetCustomer360:GetDataOperation",} 1.0
bwdefinitions:service{ProcessName="t1.module.sub.item.auditProcess",ServiceName="GetCustomer360",OperationName="GetDataOperation",ServiceInstance="GetCustomer360:GetDataOperation",} 1.0
bwdefinitions:service{ProcessName="t1.module.sub.orchestratorSubFlow",ServiceName="GetCustomer360",OperationName="GetDataOperation",ServiceInstance="GetCustomer360:GetDataOperation",} 1.0
bwdefinitions:service{ProcessName="t1.module.Process",ServiceName="GetCustomer360",OperationName="GetDataOperation",ServiceInstance="GetCustomer360:GetDataOperation",} 1.0
# HELP bwdefinitions:gateway BW Design Time Repository - Gateway definition
# TYPE bwdefinitions:gateway counter
bwdefinitions:gateway{ServiceName="GetCustomer360",OperationName="GetDataOperation",ServiceInstance="GetCustomer360:GetDataOperation",Endpoint="bwce-demo-mon-orchestrator-bwce",InteractionType="ISTIO",} 1.0
# HELP process_cpu_seconds_total Total user and system CPU time spent in seconds.
# TYPE process_cpu_seconds_total counter
process_cpu_seconds_total 1956.86
# HELP process_start_time_seconds Start time of the process since unix epoch in seconds.
# TYPE process_start_time_seconds gauge
process_start_time_seconds 1.604712447107E9
# HELP process_open_fds Number of open file descriptors.
# TYPE process_open_fds gauge
process_open_fds 763.0
# HELP process_max_fds Maximum number of open file descriptors.
# TYPE process_max_fds gauge
process_max_fds 1048576.0
# HELP process_virtual_memory_bytes Virtual memory size in bytes.
# TYPE process_virtual_memory_bytes gauge
process_virtual_memory_bytes 3.046207488E9
# HELP process_resident_memory_bytes Resident memory size in bytes.
# TYPE process_resident_memory_bytes gauge
process_resident_memory_bytes 4.2151936E8
# HELP jvm_gc_collection_seconds Time spent in a given JVM garbage collector in seconds.
# TYPE jvm_gc_collection_seconds summary
jvm_gc_collection_seconds_count{gc="G1 Young Generation",} 540.0
jvm_gc_collection_seconds_sum{gc="G1 Young Generation",} 4.754
jvm_gc_collection_seconds_count{gc="G1 Old Generation",} 2.0
jvm_gc_collection_seconds_sum{gc="G1 Old Generation",} 0.563
# HELP jvm_threads_current Current thread count of a JVM
# TYPE jvm_threads_current gauge
jvm_threads_current 98.0
# HELP jvm_threads_daemon Daemon thread count of a JVM
# TYPE jvm_threads_daemon gauge
jvm_threads_daemon 43.0
# HELP jvm_threads_peak Peak thread count of a JVM
# TYPE jvm_threads_peak gauge
jvm_threads_peak 98.0
# HELP jvm_threads_started_total Started thread count of a JVM
# TYPE jvm_threads_started_total counter
jvm_threads_started_total 109.0
# HELP jvm_threads_deadlocked Cycles of JVM-threads that are in deadlock waiting to acquire object monitors or ownable synchronizers
# TYPE jvm_threads_deadlocked gauge
jvm_threads_deadlocked 0.0
# HELP jvm_threads_deadlocked_monitor Cycles of JVM-threads that are in deadlock waiting to acquire object monitors
# TYPE jvm_threads_deadlocked_monitor gauge
jvm_threads_deadlocked_monitor 0.0
As you can see a lot of metrics but I have to be honest I am not using most of them in my dashboards and to generate my alerts. I can use the metrics regarding the application performance for each of the BusinessWorks process and its activities, also the JVM memory performance and number of threads but things like how the JVM GC is working for each of the layers of the JVM (G1 Young Generation, G1 Old Generation) I’m not using them at all.
So, If I show the same metric endpoint highlighting the things that I am not using it would be something like this:
# HELP jvm_info JVM version info
# TYPE jvm_info gauge
jvm_info{version="1.8.0_221-b27",vendor="Oracle Corporation",runtime="Java(TM) SE Runtime Environment",} 1.0
# HELP jvm_memory_bytes_used Used bytes of a given JVM memory area.
# TYPE jvm_memory_bytes_used gauge
jvm_memory_bytes_used{area="heap",} 1.0318492E8
jvm_memory_bytes_used{area="nonheap",} 1.52094712E8
# HELP jvm_memory_bytes_committed Committed (bytes) of a given JVM memory area.
# TYPE jvm_memory_bytes_committed gauge
jvm_memory_bytes_committed{area="heap",} 1.35266304E8
jvm_memory_bytes_committed{area="nonheap",} 1.71302912E8
# HELP jvm_memory_bytes_max Max (bytes) of a given JVM memory area.
# TYPE jvm_memory_bytes_max gauge
jvm_memory_bytes_max{area="heap",} 1.073741824E9
jvm_memory_bytes_max{area="nonheap",} -1.0
# HELP jvm_memory_bytes_init Initial bytes of a given JVM memory area.
# TYPE jvm_memory_bytes_init gauge
jvm_memory_bytes_init{area="heap",} 1.34217728E8
jvm_memory_bytes_init{area="nonheap",} 2555904.0
# HELP jvm_memory_pool_bytes_used Used bytes of a given JVM memory pool.
# TYPE jvm_memory_pool_bytes_used gauge
jvm_memory_pool_bytes_used{pool="Code Cache",} 3.3337536E7
jvm_memory_pool_bytes_used{pool="Metaspace",} 1.04914136E8
jvm_memory_pool_bytes_used{pool="Compressed Class Space",} 1.384304E7
jvm_memory_pool_bytes_used{pool="G1 Eden Space",} 3.3554432E7
jvm_memory_pool_bytes_used{pool="G1 Survivor Space",} 1048576.0
jvm_memory_pool_bytes_used{pool="G1 Old Gen",} 6.8581912E7
# HELP jvm_memory_pool_bytes_committed Committed bytes of a given JVM memory pool.
# TYPE jvm_memory_pool_bytes_committed gauge
jvm_memory_pool_bytes_committed{pool="Code Cache",} 3.3619968E7
jvm_memory_pool_bytes_committed{pool="Metaspace",} 1.19697408E8
jvm_memory_pool_bytes_committed{pool="Compressed Class Space",} 1.7985536E7
jvm_memory_pool_bytes_committed{pool="G1 Eden Space",} 4.6137344E7
jvm_memory_pool_bytes_committed{pool="G1 Survivor Space",} 1048576.0
jvm_memory_pool_bytes_committed{pool="G1 Old Gen",} 8.8080384E7
# HELP jvm_memory_pool_bytes_max Max bytes of a given JVM memory pool.
# TYPE jvm_memory_pool_bytes_max gauge
jvm_memory_pool_bytes_max{pool="Code Cache",} 2.5165824E8
jvm_memory_pool_bytes_max{pool="Metaspace",} -1.0
jvm_memory_pool_bytes_max{pool="Compressed Class Space",} 1.073741824E9
jvm_memory_pool_bytes_max{pool="G1 Eden Space",} -1.0
jvm_memory_pool_bytes_max{pool="G1 Survivor Space",} -1.0
jvm_memory_pool_bytes_max{pool="G1 Old Gen",} 1.073741824E9
# HELP jvm_memory_pool_bytes_init Initial bytes of a given JVM memory pool.
# TYPE jvm_memory_pool_bytes_init gauge
jvm_memory_pool_bytes_init{pool="Code Cache",} 2555904.0
jvm_memory_pool_bytes_init{pool="Metaspace",} 0.0
jvm_memory_pool_bytes_init{pool="Compressed Class Space",} 0.0
jvm_memory_pool_bytes_init{pool="G1 Eden Space",} 7340032.0
jvm_memory_pool_bytes_init{pool="G1 Survivor Space",} 0.0
jvm_memory_pool_bytes_init{pool="G1 Old Gen",} 1.26877696E8
# HELP jvm_buffer_pool_used_bytes Used bytes of a given JVM buffer pool.
# TYPE jvm_buffer_pool_used_bytes gauge
jvm_buffer_pool_used_bytes{pool="direct",} 148590.0
jvm_buffer_pool_used_bytes{pool="mapped",} 0.0
# HELP jvm_buffer_pool_capacity_bytes Bytes capacity of a given JVM buffer pool.
# TYPE jvm_buffer_pool_capacity_bytes gauge
jvm_buffer_pool_capacity_bytes{pool="direct",} 148590.0
jvm_buffer_pool_capacity_bytes{pool="mapped",} 0.0
# HELP jvm_buffer_pool_used_buffers Used buffers of a given JVM buffer pool.
# TYPE jvm_buffer_pool_used_buffers gauge
jvm_buffer_pool_used_buffers{pool="direct",} 19.0
jvm_buffer_pool_used_buffers{pool="mapped",} 0.0
# HELP jvm_classes_loaded The number of classes that are currently loaded in the JVM
# TYPE jvm_classes_loaded gauge
jvm_classes_loaded 16993.0
# HELP jvm_classes_loaded_total The total number of classes that have been loaded since the JVM has started execution
# TYPE jvm_classes_loaded_total counter
jvm_classes_loaded_total 17041.0
# HELP jvm_classes_unloaded_total The total number of classes that have been unloaded since the JVM has started execution
# TYPE jvm_classes_unloaded_total counter
jvm_classes_unloaded_total 48.0
# HELP bwce_activity_stats_list BWCE Activity Statictics list
# TYPE bwce_activity_stats_list gauge
# HELP bwce_activity_counter_list BWCE Activity related Counters list
# TYPE bwce_activity_counter_list gauge
# HELP all_activity_events_count BWCE All Activity Events count by State
# TYPE all_activity_events_count counter
all_activity_events_count{StateName="CANCELLED",} 0.0
all_activity_events_count{StateName="COMPLETED",} 0.0
all_activity_events_count{StateName="STARTED",} 0.0
all_activity_events_count{StateName="FAULTED",} 0.0
# HELP activity_events_count BWCE All Activity Events count by Process, Activity State
# TYPE activity_events_count counter
# HELP activity_total_evaltime_count BWCE Activity EvalTime by Process and Activity
# TYPE activity_total_evaltime_count counter
# HELP activity_total_duration_count BWCE Activity DurationTime by Process and Activity
# TYPE activity_total_duration_count counter
# HELP bwpartner_instance:total_request Total Request for the partner invocation which mapped from the activities
# TYPE bwpartner_instance:total_request counter
# HELP bwpartner_instance:total_duration_ms Total Duration for the partner invocation which mapped from the activities (execution or latency)
# TYPE bwpartner_instance:total_duration_ms counter
# HELP bwce_process_stats BWCE Process Statistics list
# TYPE bwce_process_stats gauge
# HELP bwce_process_counter_list BWCE Process related Counters list
# TYPE bwce_process_counter_list gauge
# HELP all_process_events_count BWCE All Process Events count by State
# TYPE all_process_events_count counter
all_process_events_count{StateName="CANCELLED",} 0.0
all_process_events_count{StateName="COMPLETED",} 0.0
all_process_events_count{StateName="STARTED",} 0.0
all_process_events_count{StateName="FAULTED",} 0.0
# HELP process_events_count BWCE Process Events count by Operation
# TYPE process_events_count counter
# HELP process_duration_seconds_total BWCE Process Events duration by Operation in seconds
# TYPE process_duration_seconds_total counter
# HELP process_duration_milliseconds_total BWCE Process Events duration by Operation in milliseconds
# TYPE process_duration_milliseconds_total counter
# HELP bwdefinitions:partner BWCE Process Events count by Operation
# TYPE bwdefinitions:partner counter
bwdefinitions:partner{ProcessName="t1.module.item.getTransactionData",ActivityName="FTLPublisher",ServiceName="GetCustomer360",OperationName="GetDataOperation",PartnerService="TransactionService",PartnerOperation="GetTransactionsOperation",Location="internal",PartnerMiddleware="MW",} 1.0
bwdefinitions:partner{ProcessName=" t1.module.item.auditProcess",ActivityName="KafkaSendMessage",ServiceName="GetCustomer360",OperationName="GetDataOperation",PartnerService="AuditService",PartnerOperation="AuditOperation",Location="internal",PartnerMiddleware="MW",} 1.0
bwdefinitions:partner{ProcessName="t1.module.item.getCustomerData",ActivityName="JMSRequestReply",ServiceName="GetCustomer360",OperationName="GetDataOperation",PartnerService="CustomerService",PartnerOperation="GetCustomerDetailsOperation",Location="internal",PartnerMiddleware="MW",} 1.0
# HELP bwdefinitions:binding BW Design Time Repository - binding/transport definition
# TYPE bwdefinitions:binding counter
bwdefinitions:binding{ServiceName="GetCustomer360",OperationName="GetDataOperation",ServiceInterface="GetCustomer360:GetDataOperation",Binding="/customer",Transport="HTTP",} 1.0
# HELP bwdefinitions:service BW Design Time Repository - Service definition
# TYPE bwdefinitions:service counter
bwdefinitions:service{ProcessName="t1.module.sub.item.getCustomerData",ServiceName="GetCustomer360",OperationName="GetDataOperation",ServiceInstance="GetCustomer360:GetDataOperation",} 1.0
bwdefinitions:service{ProcessName="t1.module.sub.item.auditProcess",ServiceName="GetCustomer360",OperationName="GetDataOperation",ServiceInstance="GetCustomer360:GetDataOperation",} 1.0
bwdefinitions:service{ProcessName="t1.module.sub.orchestratorSubFlow",ServiceName="GetCustomer360",OperationName="GetDataOperation",ServiceInstance="GetCustomer360:GetDataOperation",} 1.0
bwdefinitions:service{ProcessName="t1.module.Process",ServiceName="GetCustomer360",OperationName="GetDataOperation",ServiceInstance="GetCustomer360:GetDataOperation",} 1.0
# HELP bwdefinitions:gateway BW Design Time Repository - Gateway definition
# TYPE bwdefinitions:gateway counter
bwdefinitions:gateway{ServiceName="GetCustomer360",OperationName="GetDataOperation",ServiceInstance="GetCustomer360:GetDataOperation",Endpoint="bwce-demo-mon-orchestrator-bwce",InteractionType="ISTIO",} 1.0
# HELP process_cpu_seconds_total Total user and system CPU time spent in seconds.
# TYPE process_cpu_seconds_total counter
process_cpu_seconds_total 1956.86
# HELP process_start_time_seconds Start time of the process since unix epoch in seconds.
# TYPE process_start_time_seconds gauge
process_start_time_seconds 1.604712447107E9
# HELP process_open_fds Number of open file descriptors.
# TYPE process_open_fds gauge
process_open_fds 763.0
# HELP process_max_fds Maximum number of open file descriptors.
# TYPE process_max_fds gauge
process_max_fds 1048576.0
# HELP process_virtual_memory_bytes Virtual memory size in bytes.
# TYPE process_virtual_memory_bytes gauge
process_virtual_memory_bytes 3.046207488E9
# HELP process_resident_memory_bytes Resident memory size in bytes.
# TYPE process_resident_memory_bytes gauge
process_resident_memory_bytes 4.2151936E8
# HELP jvm_gc_collection_seconds Time spent in a given JVM garbage collector in seconds.
# TYPE jvm_gc_collection_seconds summary
jvm_gc_collection_seconds_count{gc="G1 Young Generation",} 540.0
jvm_gc_collection_seconds_sum{gc="G1 Young Generation",} 4.754
jvm_gc_collection_seconds_count{gc="G1 Old Generation",} 2.0
jvm_gc_collection_seconds_sum{gc="G1 Old Generation",} 0.563
# HELP jvm_threads_current Current thread count of a JVM
# TYPE jvm_threads_current gauge
jvm_threads_current 98.0
# HELP jvm_threads_daemon Daemon thread count of a JVM
# TYPE jvm_threads_daemon gauge
jvm_threads_daemon 43.0
# HELP jvm_threads_peak Peak thread count of a JVM
# TYPE jvm_threads_peak gauge
jvm_threads_peak 98.0
# HELP jvm_threads_started_total Started thread count of a JVM
# TYPE jvm_threads_started_total counter
jvm_threads_started_total 109.0
# HELP jvm_threads_deadlocked Cycles of JVM-threads that are in deadlock waiting to acquire object monitors or ownable synchronizers
# TYPE jvm_threads_deadlocked gauge
jvm_threads_deadlocked 0.0
# HELP jvm_threads_deadlocked_monitor Cycles of JVM-threads that are in deadlock waiting to acquire object monitors
# TYPE jvm_threads_deadlocked_monitor gauge
jvm_threads_deadlocked_monitor 0.0
So, it can be a 50% of the metric endpoint response the part that I’m not using, so, why I am using disk space that I am paying for to storing it? And this is just for a “critical exporter”, one that I try to use as much information as possible, but think about how many exporters do you have and how much information you use for each of them.
Ok, so now the purpose and the motivation of this post are clear, but what we can do about it?
Discovering the REST API
Prometheus has an awesome REST API to expose all the information that you can wish about. If you have ever use the Graphical Interface for Prometheus (shown below) you are using the REST API because this is why is behind it.
Target view of the Prometheus Graphical Interface
We have all the documentation regarding the REST API in the Prometheus official documentation:
But what is this API providing us in terms of the time-series database TSDB that Prometheus is using?
TSDB Admin APIs
We have a specific API to manage the performance of the TSDB database but in order to be able to use it, we need to enable the Admin API. And that is done by providing the following flag where we are launching the Prometheus server --web.enable-admin-api.
If we are using the Prometheus Operator Helm Chart to deploy this we need to use the following item in our values.yaml
## EnableAdminAPI enables Prometheus the administrative HTTP API which includes functionality such as deleting time series.
## This is disabled by default.
## ref: https://prometheus.io/docs/prometheus/latest/querying/api/#tsdb-admin-apis
## enableAdminAPI: true
We have a lot of options enable when we enable this administrative API but today we are going to focus on a single REST operation that is the “stats”. This is the only method related to TSDB that it doesn’t require to enable the Admin API. This operation, as we can read in the Prometheus documentation, returns the following items:
headStats: This provides the following data about the head block of the TSDB:
numSeries : The number of series.
: The number of series. chunkCount : The number of chunks.
: The number of chunks. minTime : The current minimum timestamp in milliseconds.
: The current minimum timestamp in milliseconds. maxTime: The current maximum timestamp in milliseconds.
seriesCountByMetricName: This will provide a list of metrics names and their series count.
labelValueCountByLabelName: This will provide a list of the label names and their value count.
memoryInBytesByLabelName This will provide a list of the label names and memory used in bytes. Memory usage is calculated by adding the length of all values for a given label name.
seriesCountByLabelPair This will provide a list of label value pairs and their series count.
To access to that API we need to hit the following endpoint:
GET /api/v1/status/tsdb
So, when I am doing that in my Prometheus deployment I get something similar to this:
{
"status":"success",
"data":{
"seriesCountByMetricName":[
{
"name":"apiserver_request_duration_seconds_bucket",
"value":34884
},
{
"name":"apiserver_request_latencies_bucket",
"value":7344
},
{
"name":"etcd_request_duration_seconds_bucket",
"value":6000
},
{
"name":"apiserver_response_sizes_bucket",
"value":3888
},
{
"name":"apiserver_request_latencies_summary",
"value":2754
},
{
"name":"etcd_request_latencies_summary",
"value":1500
},
{
"name":"apiserver_request_count",
"value":1216
},
{
"name":"apiserver_request_total",
"value":1216
},
{
"name":"container_tasks_state",
"value":1140
},
{
"name":"apiserver_request_latencies_count",
"value":918
}
],
"labelValueCountByLabelName":[
{
"name":"__name__",
"value":2374
},
{
"name":"id",
"value":210
},
{
"name":"mountpoint",
"value":208
},
{
"name":"le",
"value":195
},
{
"name":"type",
"value":185
},
{
"name":"name",
"value":181
},
{
"name":"resource",
"value":170
},
{
"name":"secret",
"value":168
},
{
"name":"image",
"value":107
},
{
"name":"container_id",
"value":97
}
],
"memoryInBytesByLabelName":[
{
"name":"__name__",
"value":97729
},
{
"name":"id",
"value":21450
},
{
"name":"mountpoint",
"value":18123
},
{
"name":"name",
"value":13831
},
{
"name":"image",
"value":8005
},
{
"name":"container_id",
"value":7081
},
{
"name":"image_id",
"value":6872
},
{
"name":"secret",
"value":5054
},
{
"name":"type",
"value":4613
},
{
"name":"resource",
"value":3459
}
],
"seriesCountByLabelValuePair":[
{
"name":"namespace=default",
"value":72064
},
{
"name":"service=kubernetes",
"value":70921
},
{
"name":"endpoint=https",
"value":70917
},
{
"name":"job=apiserver",
"value":70917
},
{
"name":"component=apiserver",
"value":57992
},
{
"name":"instance=192.168.185.199:443",
"value":40343
},
{
"name":"__name__=apiserver_request_duration_seconds_bucket",
"value":34884
},
{
"name":"version=v1",
"value":31152
},
{
"name":"instance=192.168.112.31:443",
"value":30574
},
{
"name":"scope=cluster",
"value":29713
}
]
}
}
We can also check the same information if we use the new and experimental React User Interface on the following endpoint:
/new/tsdb-status
Graphical Visualization of top 10 series count by metric name in the new Prometheus UI
So, with that, you will get the Top 10 series and labels that are inside your time-series database, so in case, some of them are not useful you can just get rid of them using the normal approaches to drop a series or a label. This is great, but what if all the ones shown here are relevant, what can we do about it?
Mmmm, maybe we can use PromQL to monitor this (dogfodding approach). So if we would like to extract the same information but using PromQL we can do it with the following query:
topk(10, count by (__name__)({__name__=~".+"}))
Top 10 of metric series generated and stored in the time series database
And now we have all the power at my hands. For example, let’s take a look not at the 10 more relevant but the 100 more relevants or any other filter that we need to apply. For example, let’s see the metrics regarding with the JVM that we discussed at the beginning. And we will do that with the following PromQL query:
topk(100, count by (__name__)({__name__=~"jvm.+"}))
Top 100 of metric series regarding to JVM metrics
So we can see that we have at least 150 series regarding to metrics that I am not using at all. But let’s do it even better, let’s take a look at the same but group by job names:
topk(10, count by (job,__name__)({__name__=~".+"})) | https://medium.com/dev-genius/how-it-optimize-the-disk-usage-in-the-prometheus-database-ef8151d201db | ['Alex Vazquez'] | 2020-11-17 17:49:56.776000+00:00 | ['Software Development', 'Technology', 'Kubernetes', 'Cloud Computing', 'Programming'] |
Quit the Growth Hacks & Algorithm Games | You’ve seen the countless articles about gaming elusive algorithms and hacking your way to cash money millions. I plan to gouge out my eyes with an acetylene torch if I read one more hack preaching about beating the system.
People, you are dealing with humans. One person’s random success on Instagram, TikTok, or Medium does not a blueprint make. Sometimes, success boils down to luck, timing, and privilege. If I were born a generation later, who knows? Maybe I would’ve been an influencer preening on Instagram. (Probably not because I don’t preen and I’m allergic to social media.)
But I digress.
Today, my online friend Bianca Bass wrote the article about Medium I’ve always wanted to write, but she’s done it better.
You’re don’t care about the platform? Hold onto your pants, this isn’t a story about Medium. This is relevant for everyone, especially if you’re in a service-based business.
Let me preface what I’m about to say with the fact that I know what it’s like to live on ramen and oatmeal for months at a time. I’m in year three of five in Chapter 13 bankruptcy, shelling out four-figure payments per month. I’m not doling out advice from my gilded throne.
If your sole objective in anything is to make money, you will not make money. [Counting down 3,2,1 to the bros in the comments who will tell me otherwise. Please don’t.]
One more time for the people in the cheap seats: If your sole objective in anything is to make money, you will not make money. Your work will reflect your thirst. Your obsession will make you myopic. You’ll build yourself a growth hack box, rarely jumping out in fear of not following the advice of the herd. Writing your ten vague, common sense ways to live a good life, etc.
Your #1 objective should be to deliver value.
Let’s get neurological for a hot minute. We’re wired to feel first, think second (fight or flight). Couple that with the fact that people consume content and read stories for selfish reasons, mirror neurons are key in understanding how people form bonds with other people, and yes, with brands. Let’s say you’re on the highway and you see a horrific four-car pileup. Part of what your brain does to process the information is to re-enact the situation from your POV so you can empathize and comprehend the severity of what you’ve just witnessed.
Neural coupling occurs when an event or story activates parts in the brain that allow the listener to turn the story into their own experience. With mirroring, listeners will not only experience similar activity to each other, but also to the storyteller. Our brains are wired to empathize for, and make connections with, others and the stories they tell.
Our reactions are primarily emotional until the rational, more pragmatic side of our brain kicks in, which means, stories have the power to draw people in immediately.
What does this have to do with making some sweet coin? WELL, FRIEND. LET ME TELL YOU.
People scan aisles and websites to determine if what they’re being sold is right for them. Is this speaking to me? Does this product or person understand me? Are they echoing back what I’m thinking, feeling, doing? Are they mirroring my wants and needs but solving them in some way?
People make instantaneous decisions about who to read and what to buy based on value. Value could be in the form of utility, reciprocity, education, entertainment, or saving/making $$$. People want their needs met and problems solved. They’re busy and have a proliferation of choice and they want to make sure that you won’t waste their time.
If you show up consistently at work — whether it’s in a traditional office setting or at home in your platypus pajamas — and deliver real, tangible value, the money and accolades will come. What does that mean practically? Let’s say you’re an email marketing consultant. Here are a few ways to bring value to your prospective clients:
Publish “teardowns” : Val Geisler is genius at this. She takes emails from the kinds of companies she wants to attract and analyzes them in detail — the good, bad, and ugly. Offering constructive feedback on how they can improve their communication. Not only does this get the attention of a prospect, but it positions her as an industry expert. I have no doubt she’s won adjacent clients because of the teardowns she’s published online.
: Val Geisler is genius at this. She takes emails from the kinds of companies she wants to attract and analyzes them in detail — the good, bad, and ugly. Offering constructive feedback on how they can improve their communication. Not only does this get the attention of a prospect, but it positions her as an industry expert. I have no doubt she’s won adjacent clients because of the teardowns she’s published online. Don’t cast vague bait : Go into your area of expertise and burrow deep. Be specific and comprehensive in writing articles and tutorials. Cite reputable research and sources. Back up the information with case studies or industry examples that illustrate your point. Broaden the scope of your work beyond you but at the same time go deep. Don’t slap up a post that took you five minutes because some guru told you to publish every day even if it’s garbage. Everything you put out into the world makes an impression. And do you want to waste someone’s time?
: Go into your area of expertise and burrow deep. Be specific and comprehensive in writing articles and tutorials. Cite reputable research and sources. Back up the information with case studies or industry examples that illustrate your point. Broaden the scope of your work beyond you but at the same time go deep. Don’t slap up a post that took you five minutes because some guru told you to publish every day even if it’s garbage. Everything you put out into the world makes an impression. And do you want to waste someone’s time? Don’t gate everything behind an email sign-up, FFS : Give them true value before they sign up and keep the goods going after you have their email. Share the checklists, worksheets, and tutorials online. Let them wonder, “Hey! If I’m getting valuable content without giving you anything, what would you give me if I actually gave you my email or paid you?” It’s a question for the ages, mis compadres y comadres.
: Give them true value before they sign up and keep the goods going after you have their email. Share the checklists, worksheets, and tutorials online. Let them wonder, “Hey! If I’m getting valuable content without giving you anything, what would you give me if I actually gave you my email or paid you?” It’s a question for the ages, mis compadres y comadres. Give real-life examples : I can go on about how many articles I’ve read from people who are not marketers giving marketing advice. They might have done their research, but they don’t have the track record. They haven’t endured the agita of a campaign gone wrong and what one learned as a result. You can’t teach what you haven’t done — I’ll fight you on this. Share case studies (blotting out client names and material information if you’re under NDA) and what you’ve learned from the campaigns — the good, bad, and violently ugly. This communicates to prospects that you’ve done the work before, successfully, so they’re more inclined to show up in your inbox.
: I can go on about how many articles I’ve read from people who are not marketers giving marketing advice. They might have done their research, but they don’t have the track record. They haven’t endured the agita of a campaign gone wrong and what one learned as a result. You can’t teach what you haven’t done — I’ll fight you on this. Share case studies (blotting out client names and material information if you’re under NDA) and what you’ve learned from the campaigns — the good, bad, and violently ugly. This communicates to prospects that you’ve done the work before, successfully, so they’re more inclined to show up in your inbox. Make the complex simple: People want to know that you can solve problems. Every industry has its jargon, methodologies, best practices — all that jazz. Explain hard concepts simply, in a voice that’s wholly you’re own. Prospective clients won’t feel intimidated or feel the need to pull out a dictionary every time they get on the phone with you. You’ve excited them because they learned something from you, something that’s not in their area of expertise, in a way that made sense to them.
If you’re a creative writer, are you improving on your craft? Or are you merely getting better at sending more people to mediocre work? Are you a ravenous reader, a student of the word? Do you study other writers and dissect their work? Many people are blinded by their ego and don’t want to admit that they have to do the work to make their work better.
Sometimes, your work might not be good enough and your ego is holding you back. But sure, complain, it’s easier.
You’re not entitled to readers because you’ve spent six months writing on the internet. You’re not entitled to clients simply because you exist. Stop getting high on your own supply.
You have to play the long game. Put in the time and work. Consistency breeds legitimacy. Consistency breeds trust. Consistency bonds clients and readers to you. Gaming a fucking algorithm does nothing for you over the long haul.
Who cares if the fast-money, shiny object-shakers are cashing in right now? Who knows where they’ll be in a year or five or ten? Don’t aim to be anyone other than yourself. People are buying and reading you — not the cheap knockoff of an industry titan.
I got my MFA from Columbia (biggest regret going) and I learned this — you can teach the mechanics of plot, character, dialogue, structure, point-of-view, and all the things. You can coach a writer into finding their voice and honing their style. But you can’t teach magic. You can’t write books for them. It’s up to them to take the tools and apply them.
Same with your revered “gurus” online. Take the tools, but make your own magic. Tell standout stories. Give the kind of value that puts a client’s heart on pause.
But it’s hard to see past the glare in a world where people are impatient. It’s been six months and I’m not making $10,000/month! It’s been three months — where is my first million in sales? Failing to realize what they consider long is, in fact, a minute.
Here’s a fact. 85% of my clients in 2019 came as a result of the articles I published on Medium. Six figures earned off the platform. Five figures earned on. I’m not saying this to brag because bragging is gauche, rather, I’m sharing this because I’ve been writing articles, comprehensive tutorials, and how-tos for three years. I’ve been on Medium since 2013.
Look at me, the tortoise. Shimmying her way to the finish line.
How did I build a thriving consultancy? I showed up consistently for my specific audience and delivered value. I didn’t write SEO-drenched articles that were vague photocopies of bland Inc. originals. I didn’t dangle a carrot and snatch it away if you didn’t sign up for my email list or purchase my course for the low, low price of $997.
I don’t have a course.
Instead, I rolled up with tutorials, case studies, detailed strategies, and tactics. I poured out my brain onto a computer screen and spoke plain English when all the kids are gasping over “synergistic innovations.” I shared methodologies and frameworks in detail. My “How to Build a Brand” series is a 250-page book spread over eight articles.
Friends, I’m not playing around. People noticed, and then they hired me.
This week, I’m signing a five-figure, two-month engagement with a client because the founders found my brand development articles valuable. I’m giving a two-day, four-figure brand intensive workshop for a start-up in New York because their VC, who vouched for me, was impressed with my work online. We spoke for all of 2019 — a year — before he gave me my first project.
I didn’t complain about the fact that this VC didn’t move faster. That the gigs didn’t start rolling in as soon as I hit publish. I was being a farmer, playing the long game.
It’s easy to whine. It’s easy to read hacks and optimize titles for search. It’s easy to copy what others have done because it’s safe and that one article went viral or that one campaign blew up like nitro on Instagram. It’s easy to focus on tactics without considering the big picture.
But it’s hard to show up. It’s hard to bring your A-game consistently. It’s hard to identify who your audience is, figure out what they want, and deliver on that want in a way that knocks the little bootie socks off their feet.
Quit complaining. Create. | https://medium.com/falling-into-freelancing/quit-the-growth-hacks-algorithm-games-14f28b09a8fb | ['Felicia C. Sullivan'] | 2020-01-23 14:11:22.892000+00:00 | ['Marketing', 'Medium', 'Business', 'Freelancing', 'Writing'] |
How Publishing My Work Makes Me A More Powerful Writer | When I just started my writing journey, I used to be really scared to hit publish. I would sit on my articles and stories for days and when I worked up the courage to actually publish the damn thing, my heart would be racing and I would get butterflies in the pit of my stomach.
I’m not a courageous person. I wish I could be a little bit braver especially when it comes to putting my work out there. But since I’ve started my writing journey, I’ve published over 150 articles. Whether you’re a seasoned writer who’s published over 1,000 or a new writer trying to will up the courage to publish your first story, there is power in hitting publish and sending your work out into the world.
You gain a little more confidence each time
I had very little confidence as a writer and I still do. I go through dips and peaks as a writer. But since I’ve started publishing my stories, the dips don’t last as long and I can make my way up that hill a lot faster than I used to.
Even though I’m not making a full-time income (or even a part-time income) off my writing, I don’t doubt myself as a writer anymore. Publishing my stories have given me the confidence and courage I needed to keep writing.
Writing takes confidence and bravery. It’s risky to put your work out there and share personal moments and thoughts with the world but in doing so, you cultivate your confidence in your ability to change the world through your writing with every published piece.
It allows you to move forward in your writing journey
I can write my heart out and have a hundred drafts (actually I probably do) but until I hit publish on one of my creations, I don’t feel accomplished. And until I feel like I’ve accomplished one task, I can’t move on to the next.
Publishing our work allows us to move on.
Having unfinished or even complete works of art sitting in our space holds us back in our creative endeavors because we keep coming back to those pieces. An unpublished story is the equivalent of unfinished business in that we can’t put it out of our minds and let it go. Hitting publish allows you to let go.
You stop caring what others think
If you write long enough and publish your work often enough, you will quickly learn that people are not afraid to share their opinions about you through the guise of the Internet.
You will also quickly learn that the opinion of others doesn’t matter as much as you think.
Most of the responses I get on my stories are very encouraging but there will always be haters and trolls who feel the need to voice their dislike for my perspective on my personal experiences or my take on the world. Unless they offer some sort of constructive criticism (which most trolls don’t), their negativity used to bother and anger me. Since I’ve started publishing my stories, my need to appease others have diminished and I’ve stopped caring (to an extent) about what people think about me or my writing.
There’s true power and freedom in not caring about the opinion of others, as a writer and as a human being.
Publishing forces you to give up your perfectionist tendencies
Perfectionism is the killer of dreams.
We often see perfectionism as a strength rather than a weakness but perfectionism is simply a mask to hide the fear and doubts we have as writers.
If I waited and tried to make my stories perfect before publishing them, they would all still be sitting in my drafts folder. Our writing can never be perfect because perfection is subjective. The idea of a perfect story rests in the reader’s mind. One person’s “perfect” is another person’s “not good enough”.
Publishing my stories over and over has taught me that my writing will never be perfect. And I’m okay with that. After all, I’m human and humans will never be perfect. Since I am the creator of my stories, I shouldn’t expect my writing to be perfect either.
Your realize the world doesn’t end if nobody likes your work
The world doesn’t end if nobody reads my work or if they read it and hate it. I am still here, writing away. We have such angst and fear over making our stories available for the world to read. We cannot guarantee that our writing will change other people’s lives but it will change our own.
You become a little braver, a tiny bit more courageous and confident, more authentic. And that’s what we need in this world — something that can make us more of those things.
That’s the true power of publishing. | https://medium.com/beyond-fear/how-publishing-my-work-made-me-a-more-powerful-writer-edeb72389331 | ['Alice Vuong'] | 2020-04-08 19:04:29.110000+00:00 | ['Creativity', 'Personal Development', 'Self', 'Inspiration', 'Writing'] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.