<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: apurva866</title>
    <description>The latest articles on DEV Community by apurva866 (@apurvatech).</description>
    <link>https://dev.to/apurvatech</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F503194%2F1093207a-5ea5-41b0-b12f-b9f66c0b491b.jpeg</url>
      <title>DEV Community: apurva866</title>
      <link>https://dev.to/apurvatech</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/apurvatech"/>
    <language>en</language>
    <item>
      <title>Microsoft Engage to SWE internship at Microsoft</title>
      <dc:creator>apurva866</dc:creator>
      <pubDate>Fri, 17 Sep 2021 19:15:50 +0000</pubDate>
      <link>https://dev.to/apurvatech/microsoft-engage-to-swe-internship-at-microsoft-44pj</link>
      <guid>https://dev.to/apurvatech/microsoft-engage-to-swe-internship-at-microsoft-44pj</guid>
      <description>&lt;p&gt;Each year, over 25–30k students apply for the Microsoft engage program and only 500–700 students get selected for the mentorship. I was one of the lucky candidates to get this amazing opportunity, and I sought to make the most out of it and in the end I received an SWE 2022 summer internship offer at Microsoft ❤. And I'm going to share my journey with you through this article.&lt;/p&gt;

&lt;p&gt;Microsoft engage is a mentorship program conducted by Microsoft in the month of June-July, and opens for only 2nd-year students, application opens towards the end of 2nd year (this timeline may vary with college), and students from some specific colleges are selected. People with the following qualifications are allowed to apply to this program:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Graduation year: 2nd&lt;/li&gt;
&lt;li&gt;CGPA: 7 and above.&lt;/li&gt;
&lt;li&gt;Course: B.Tech/B.E/Dual Degree&lt;/li&gt;
&lt;li&gt;Branch: Any&lt;/li&gt;
&lt;li&gt;No pending backlogs&lt;/li&gt;
&lt;li&gt;Strong CS Fundamentals and Coding principles required&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fjsuad52cdtahw86oqoba.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fjsuad52cdtahw86oqoba.png" alt="image"&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;One can find all the details of the application at their &lt;a href="https://careers.microsoft.com/us/en/job/1049887" rel="noopener noreferrer"&gt;career portal&lt;/a&gt;. After 2–3 weeks of initial shortlisting through resumes, the shortlisted people received an invite for a test link. Create an amazing resume to pass this round and focus on your CGPA starting from the first year of your college &amp;amp; create good projects and practice problem-solving. The quiz test consists of 15–20 questions in 45 min. And the following topics are important: &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Data structures and Algorithms&lt;/li&gt;
&lt;li&gt;Operating system&lt;/li&gt;
&lt;li&gt;Database Management System&lt;/li&gt;
&lt;li&gt;Java Programming&lt;/li&gt;
&lt;li&gt;Problem solving
- with 4–5 coding questions and the rest were reasoning-based &amp;amp; MCQ questions.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;After 1 week we received the qualification mail and I qualified to participate in Engage🎉&lt;br&gt;
&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fe7x54f595j4mqmdv5ogg.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fe7x54f595j4mqmdv5ogg.png" alt="image"&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;I was very excited to be mentored by mentors from Microsoft and attend amazing AMA sessions.&lt;br&gt;
The theme for our year was Agile Development where we were supposed to create a Video conferencing application i.e. Clone of Microsoft Teams, find more details of the task on this &lt;a href="https://microsoft.acehacker.com/engage2021/" rel="noopener noreferrer"&gt;website&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7pow4fyzj1gc6kbm5cba.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7pow4fyzj1gc6kbm5cba.png" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;We were allotted 2 mentors, mine was &lt;a href="https://www.linkedin.com/in/tushar-malhotra-54250b111/" rel="noopener noreferrer"&gt;Tushar&lt;/a&gt; and Gulbir sir, along with a group of 6 students. And I couldn't have asked for better mentors ❤, we had 2 meetings weekly, one was a group meeting and the other was a one-on-one meeting with a mentor, to discuss the obstacles during the development phase and get insights about work at Microsoft along with a plethora of informative AMA sessions.&lt;/p&gt;

&lt;p&gt;After 5 weeks of hard work and with the help of my mentors and friends(&lt;a href="https://www.linkedin.com/in/cryptus-neoxys/" rel="noopener noreferrer"&gt;Dev Sharma&lt;/a&gt;, &lt;a href="https://www.linkedin.com/in/dikwickley/" rel="noopener noreferrer"&gt;Aniket Singh&lt;/a&gt;, and &lt;a href="https://www.linkedin.com/in/mahera-furniturewala/" rel="noopener noreferrer"&gt;Mahera&lt;/a&gt;), I was able to complete my project and it was very well received.&lt;/p&gt;

&lt;p&gt;Link to my submission: &lt;a href="https://github.com/Apurva-tech/unite" rel="noopener noreferrer"&gt;https://github.com/Apurva-tech/unite&lt;/a&gt;&lt;br&gt;
And the application: &lt;a href="https://unite-apurva.herokuapp.com/" rel="noopener noreferrer"&gt;https://unite-apurva.herokuapp.com/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The evaluation of submission could either give me the opportunity to get a direct offer or an interview opportunity.&lt;br&gt;
After 3–4 weeks of evaluation, some people received a direct offer for the internship and I was not one of them 😔. I decided to work hard on my DSA skills and ace the interviews whenever I receive interview slots.&lt;/p&gt;

&lt;p&gt;And in the end, all the work did pay off and I was recommended for the Final (AA) round of the interview, i.e I had to give only the final interview. I was asked about my project in the Engage program and a 45 minutes discussion on a real-world application of DSA. The interviewer was very sweet and helped throughout the interview, it was one of the best experiences of my journey. One thing that my mentor &lt;a href="https://www.linkedin.com/in/joshika/" rel="noopener noreferrer"&gt;Joshika&lt;/a&gt; di told me is &lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;"The way you speak and react in interviews, is actually who you really are"&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;, I kept this in mind, and remained calm during the whole interview, and thought of each aspect of the questions asked.&lt;/p&gt;

&lt;p&gt;I gave my interview on August 18 in the morning and was scared to death about the results, and to my surprise, I received the results in the afternoon, my happiness knew no bounds, it was soooo overwhelming (obviously I couldn't stop screaming 😂), I had received the internship offer 🎉🎉&lt;br&gt;
I hope this article helps you in some way. Happy learning ❤&lt;/p&gt;

</description>
      <category>microsoftindia</category>
      <category>internships</category>
      <category>webdev</category>
      <category>javascript</category>
    </item>
    <item>
      <title>Deploying ML models using Streamlit</title>
      <dc:creator>apurva866</dc:creator>
      <pubDate>Sat, 31 Oct 2020 17:21:11 +0000</pubDate>
      <link>https://dev.to/apurvatech/deploying-ml-models-using-streamlit-22e3</link>
      <guid>https://dev.to/apurvatech/deploying-ml-models-using-streamlit-22e3</guid>
      <description>&lt;p&gt;Imagine building a supervised machine learning ML model to decide whether a credit card transaction has detected fraud or not. With the model confidence level in successful applications, we can evaluate the risk-free credit cards transactions. So you have built the model, which can detect credit card frauds, now what? The deployment of such ML-model is the prime goal of the project.&lt;br&gt;
Deploying an ML-model simply means the integration of the model into an existing production environment which can take in an input and return an output that can be used in making practical business decisions. Here is where Streamlit comes to play !&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Streamlit is a open-source app framework is the easiest way for data scientists and machine learning engineers to create beautiful, performant apps in only a few hours! All in pure Python. All for free.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;In the part one of this tutorial I am going to deploy a Supervised machine learning model to predict the age of a Abalone and in the next part of the tutorial we will host this web app on Heroku. An Abalone is a molluscs with a peculiar ear-shaped shell lined of mother of pearl. Abalone's age can be obtained using their physical measurement. Let us deploy the model.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F0ajl55o7occf5dwoqdit.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F0ajl55o7occf5dwoqdit.jpeg" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Create the pickle file for the model, refer to my kaggle notebook for the Machine learning model. We will be focusing on the deployment in this tutorial. Import the necessary packages. Import streamlit and pickle, to unpickle the pickled file.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;import streamlit as st
import pickle
import numpy as np
model = pickle.load(open('final_model.pkl','rb'))
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Create a function to use the pickled model. Convert all the input values into into a Numpy array and change the data type of the input array to float. Create prediction values using model.predict(input). Return the prediction values.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;def predict_age(Length,Diameter,Height,Whole_weight,Shucked_weight,
                Viscera_weight,Shell_weight):
    input=np.array([[Length,Diameter,Height,Whole_weight,Shucked_weight,
                     Viscera_weight,Shell_weight]]).astype(np.float64)
    prediction = model.predict(input)

    return int(prediction)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Create the main function.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;def main()&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Now, let us build the components of the main function.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Create a title for your page. Use st.markdown to create the html title text.
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    st.title("Abalone Age Prediction")
    html_temp = """
    &amp;lt;div style="background:#025246 ;padding:10px"&amp;gt;
    &amp;lt;h2 style="color:white;text-align:center;"&amp;gt; Abalone Age Prediction ML App &amp;lt;/h2&amp;gt;
    &amp;lt;/div&amp;gt;
    """
    st.markdown(html_temp, unsafe_allow_html = True)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;For taking the user input, Streamlit provides with an API to directly create HTML form components like input fields, use st.text_input() to take input value for the app.
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    Length = st.text_input("Length","Type Here")
    Diameter = st.text_input("Diameter","Type Here")
    Height = st.text_input("Height","Type Here")
    Whole_weight = st.text_input("Whole weight","Type Here")
    Shucked_weight = st.text_input("Shucked weight","Type Here")
    Viscera_weight = st.text_input("Viscera weight","Type Here")
    Shell_weight = st.text_input("Shell weight","Type Here")

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Define the output field. Create the html text you want to display for the output like safe_html, similarly define warn_html and danger_html. Use st.button() to build the button widget and st.success() to display a message when the model successfully predicts the value.
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;        safe_html ="""  
        &amp;lt;div style="background-color:#80ff80; padding:10px &amp;gt;
        &amp;lt;h2 style="color:white;text-align:center;"&amp;gt; The Abalone is young&amp;lt;/h2&amp;gt;
        &amp;lt;/div&amp;gt;
        """
        if st.button("Predict the age"):
        output = predict_age(Length,Diameter,Height,Whole_weight,
                             Shucked_weight,Viscera_weight,Shell_weight)
        st.success('The age is {}'.format(output))

        if output == 1:
            st.markdown(safe_html,unsafe_allow_html=True)
        elif output == 2:
            st.markdown(warn_html,unsafe_allow_html=True)
        elif output == 3:
            st.markdown(danger_html,unsafe_allow_html=True)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Every module in Python has a special attribute called &lt;strong&gt;name&lt;/strong&gt;. The value of &lt;strong&gt;name&lt;/strong&gt; attribute is set to '&lt;strong&gt;main&lt;/strong&gt;' when module run as main program. Hence, call the main() function if &lt;strong&gt;name&lt;/strong&gt; = '&lt;strong&gt;main&lt;/strong&gt;' .&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;if __name__=='__main__':
    main()
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now let’s get to the deployment.&lt;br&gt;
i) Install streamlit on your local machine.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;pip install Flask&lt;br&gt;
pip install streamlit&lt;br&gt;
&lt;/code&gt;&lt;br&gt;
ii) Save your file as filename.py and add the final_model.pkl file in the same directory. Or simply clone the GitHub repository on your machine.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;git clone https://github.com/Apurva-tech/abalone-age-app.git&lt;br&gt;
&lt;/code&gt;&lt;br&gt;
iii) Open your command prompt/terminal and navigate to the file directory. And run the following command. This starts the web app on&lt;/p&gt;

&lt;p&gt;&lt;code&gt;localhost:8501&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;code&gt;streamlit run filename.py&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Input the values, and click on predict aaaannndd Voila!&lt;br&gt;
With that we have come to end to the part one of this tutorial. Stay tuned for the next part where we will host this web app on Heroku, the link to the web app - &lt;a href="https://abalone-age-app.herokuapp.com/" rel="noopener noreferrer"&gt;https://abalone-age-app.herokuapp.com/&lt;/a&gt;.&lt;br&gt;
See you there!&lt;br&gt;
Happy learning 😄&lt;/p&gt;

</description>
      <category>machinelearning</category>
      <category>streamlit</category>
      <category>datascience</category>
      <category>python</category>
    </item>
  </channel>
</rss>
