<?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 Gaurav Kulkarni, Specializes in AI and ML projects on Medium]]></title>
        <description><![CDATA[Stories by Gaurav Kulkarni, Specializes in AI and ML projects on Medium]]></description>
        <link>https://medium.com/@gauravkulkarni_34579?source=rss-145920a16741------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*mwv3MNTEv3lCDBZrZB8sHg.jpeg</url>
            <title>Stories by Gaurav Kulkarni, Specializes in AI and ML projects on Medium</title>
            <link>https://medium.com/@gauravkulkarni_34579?source=rss-145920a16741------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Thu, 19 Nov 2026 06:49:39 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@gauravkulkarni_34579/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[Navigating AI: Best Practices]]></title>
            <link>https://medium.com/@gauravkulkarni_34579/navigating-ai-best-practices-f0e3c6a6cdb7?source=rss-145920a16741------2</link>
            <guid isPermaLink="false">https://medium.com/p/f0e3c6a6cdb7</guid>
            <dc:creator><![CDATA[Gaurav Kulkarni, Specializes in AI and ML projects]]></dc:creator>
            <pubDate>Sun, 28 Jan 2024 10:28:45 GMT</pubDate>
            <atom:updated>2024-02-13T11:16:44.984Z</atom:updated>
            <content:encoded><![CDATA[<p>Managing an AI project can be challenging and, demands quick adaptation to changing situations. Here, I’ll share insights on navigating the process of building an AI solution. The aim is to avoid common pitfalls and achieve success in your AI project. I will discuss the following two topics:</p><ol><li>Data Collection and Annotation</li><li>AI Solution Development</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*KXg4Q7SfnGzQdxwG" /><figcaption>Photo by <a href="https://unsplash.com/@lamoune?utm_source=medium&amp;utm_medium=referral">Vincent Ghilione</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><h3>Data Collection and Annotation</h3><p>Data is the most important aspect of any AI/ ML problem, and it is rarely available!!! Remember, it’s crucial to have a clear understanding of when and how the data will be available for your project before starting. Typically, data isn’t ready at the project’s start, yet stakeholders often seek a proof of concept (POC) using open-source data before investing. However, it’s important to note that solutions developed on open-source data may not perform well with actual data in a production environment.</p><p>One of the reasons for the failures of an AI project is that the training data and data in the production environment have different distributions. For example, let’s say we’re testing out a new idea. We’ve trained an AI model to decide who qualifies for a loan using open-source data from urban areas. But here’s the catch: we want this model to work with data from rural areas. The problem is that using urban data for a rural setting will result in mistakes in who gets approved for loans. While retraining the AI models on rural data might help mitigate these differences, it’s not always effective. Sometimes a change in data distribution can seriously impact the AI solution and a significant amount of time and effort must be spent to achieve the goal.</p><p>Here are a few scenarios that are generally observed regarding data availability and its quality in an AI project:</p><ul><li><em>Data does not exist and needs to be collected: </em>This is the best place to begin building an AI solution. If you are allowed to participate in the data collection and annotation process, try to build your data set as required for your problem and try to cover a wide range of scenarios. This will help you build a robust AI solution.</li><li><em>Data is available, but not accessible:</em> For example, the required CT scan images are available in the hospital’s database, but you cannot use them. Either you need to get consent from patients or anonymize the data before using it. Beware, getting access to sensitive data is not easy and it sometimes takes months before all formalities are complete.</li><li><em>Events are sparse in data:</em> A lot of data is made available but, the events of interest are few and sparse. For example, let us say you need to identify road accidents in surveillance videos. Even though you may have a terabyte of data, the events of interest are sparse and need to be identified manually. The same is the case with predictive maintenance using IOT. Tons of data is available but, failure events are sparse. Beware of such scenarios as it may seem you have a lot of data but, you only have very few samples to create the AI models.</li><li><em>Noisy or missing data:</em> There are incorrect or missing entries in data tables or the data is noisy. There are many sources of noise, for example, sensors collecting the signals are old, uncalibrated, or there is a noisy environment. Noise should be handled as a preprocessing step before feeding it to any AI/ ML model. To ensure that noise doesn’t overshadow the useful information in the data, validate it by consulting a domain expert.</li><li><em>Synthetic and Augmented data: </em>Synthetic data, like simulated ECG signals or artificially generated variations of images, is sometimes provided. For instance, in computer vision tasks, extra images with rotations and translations are often included to enhance the data set. The training data set size can be increased with synthetic or augmented data but do not allow it to dominate your original data set. <br>Synthetic and augmented data are useful for testing AI models because they can be created with specific parameters such as noise levels and distortions. This allows testing the models with various challenging inputs.</li><li><em>Data drift: </em>Many times data is made available in phases. Always compute some statistics (mean, median, standard deviation …) on the data to understand if there is a significant drift in attribute values. For example, you were being provided data from a vibration sensor but for some reason, the sensor was upgraded in the field and now you are observing a significant change in values. Keeping a check on such data distribution changes helps you adapt your AI models in a better way. The data drifts can also occur in production and may affect the AI model performance. Keeping track of the data statistics also helps us reason why the AI model’s performance changed in production.</li><li><em>Missing Annotations: </em>Data is available but there are no annotations (labels). This is a major issue and takes up a significant amount of time in the project. Note that to create acceptable data labels, you will have to work with stakeholders and hire domain experts, like radiologists, doctors, financial consultants, etc in the process. Please consider this aspect in your project timeline and budgets.</li></ul><h3>Data Workflow</h3><p>Data workflow specifies how data will be stored, versioned, and made accessible for the project. This is an important step that can sometimes even involve data security and regulatory aspects. For example, if you are working on medical data for a US client, there are HIPAA compliances that you need to abide by. A few things to remember while designing a data workflow.</p><ul><li><em>Data storage and accessibility</em> — A secure storage facility that will allow developers to access the data for learning AI models. Note that this data could be in terabytes and clear guidelines must be laid down to ensure that unnecessary copies are not created for model training purposes.</li><li><em>Annotation pipeline </em>— The annotation process assigns labels to the data. The process can either be set up by the development team using open-source software or an external SaaS application can be used. There are many annotation tools available in the market. (CVAT is a useful tool for computer vision projects.) Please decide on such a tool at the beginning of the project. Note that you may have to provide access to this pipeline to an external vendor (at least during the development phase) for data annotation and to the end user to annotate data misclassified in production.</li><li><em>Feedback pipeline</em> — Specify how misclassified data in production will be fed back to the training pipeline. This also involves setting a process to identify and flag misclassifications in the production environment. Note that in most cases production data is not accessible to developers and thus this process needs to be completely automated.</li></ul><h3>AI Solution Development</h3><p>Every AI solution is an approximate solution. In such a scenario how do you build confidence in your models? We all know we need to specify the goals and metrics to evaluate them. But in practice, how should we come up with a metric? These are some of the most prominent questions faced by every AI solution architect. I will try to present here a few guidelines, but by no means is this a complete list.</p><h3>AI pipeline</h3><p>An AI pipeline consists of a series of connected models to tackle a problem. Typically, an AI problem is broken down into several steps, with each step employing a distinct model to solve its specific task. For instance, if we aim to detect and track an object in a video, the solution would involve preprocessing steps like denoising, followed by object localization within a frame, and then tracking the object across subsequent frames. Each of these steps requires different models. There are many aspects involved in defining these pipelines, I have listed a few below:</p><ul><li><em>Minimize the use of large AI models!!!: </em>Large AI models can be like black boxes, making it tough to troubleshoot issues. In your AI pipeline, aim to use standard solutions, algorithms, or smaller ML models with fewer parameters wherever possible. If a certain step can be performed using standard regular expressions, prefer it over using a Large Langauge Model (LLM) like ChatGPT. Standard solutions are fast, generally consume less compute and memory resources, and require less parameter tuning. The most important thing is standard solutions are robust and you can trust them to perform with repeatability. They also help you build a complete picture of the system quickly. Once the entire picture is ready, you can focus on, as needed, augmenting the standard solutions with a large AI/ ML model to improve the accuracy of the entire system. This approach reduces the risk of failures as it provides you with a working solution. It also acts as a baseline for further improvements and allows you to debug and control your system in a better way.</li><li><em>How to Define Evaluation Metrics?: </em>Choosing the right evaluation metric is a challenging part of any AI project. It involves finding the most suitable mathematical measure for your specific needs. While domain experts can outline the desired outcome, they may not assist in selecting the model and loss function for your AI solution. For instance, say a project needs chest X-ray image segmentation. Many Convolutional Neural Network (CNN) models could perform image segmentation, but determining the best one isn’t straightforward. Pugh matrix method is an excellent choice for this task. For instance, in a chest X-ray image segmentation case, we can show radiologists ground truth segmentation images alongside AI model-based segmentation, asking them to rate each model variant against some quality parameters. The ratings will not only guide us in selecting a segmentation model and a loss function but also provide insight into acceptable errors in segmentation.<br>Another common challenge is defining metrics for each step in the AI pipeline. Because an AI solution relies on a series of interconnected models, it’s hard to link the overall accuracy with the outcomes of intermediate steps. For instance, in object detection and tracking within a video, it’s tough to assess how the denoising step affects the final accuracy without well-designed test experiments.</li></ul><h3>AI Model Workflow</h3><p>Similar to the data workflow, the AI model workflow specifies how models will be stored, versioned, and made accessible in the development and production environment. Similar to DevOps, AI/ ML solutions need MLOps. Many open-source and SaaS services provide this facility. Here is a good blog <a href="https://medium.com/analytics-vidhya/fundamentals-of-mlops-part-1-a-gentle-introduction-to-mlops-1b184d2c32a8">“A Gentle Introduction to MLOps”</a> on MLOps. Here I would focus on discussing a few possible pitfalls that are observed in developing an AI solution.</p><ul><li><em>Design and version experiments: </em>Treat AI solution experiments like the physics or chemistry experiments in our school days. Every experiment should specify setup parameters, inputs, expected outputs, and observations. Every important AI experiment should be logged with all information required for reproducibility. Note training results of AI models are not repeatable, each time you train a model, even on the same data set, it may result in a slightly different outcome. Thus logging models keeps track of overall progress. (<a href="https://mlflow.org/">MLFlow</a> is a good open-source tool in this space)</li><li><em>Fail early, learn early: </em>Every AI solution is inherently approximate. To create a reliable solution for production, it’s essential to narrow your focus and uncover as many failures as possible within that scope. Testing AI solutions involves various approaches tailored to the specific problem. AI testing is a vast topic that merits discussion, which I plan to cover in a future blog.</li></ul><p>Architecting an effective AI solution requires navigating through various complexities inherent in the process. Hopefully, these guidelines will provide you with clarity and facilitate a smoother journey for your next AI project. Keep Innovating!!!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f0e3c6a6cdb7" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>