<?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 Victor Irechukwu on Medium]]></title>
        <description><![CDATA[Stories by Victor Irechukwu on Medium]]></description>
        <link>https://medium.com/@victor.irechukwu?source=rss-cfafc141513f------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*w0JfTuQsibM8E13P2ZZVWg.jpeg</url>
            <title>Stories by Victor Irechukwu on Medium</title>
            <link>https://medium.com/@victor.irechukwu?source=rss-cfafc141513f------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 18 Nov 2026 13:35:18 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@victor.irechukwu/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[Extending Stochastic Gradient Optimisation with ADAM]]></title>
            <link>https://medium.com/@victor.irechukwu/extending-stochastic-gradient-optimisation-with-adam-521771e7bb5f?source=rss-cfafc141513f------2</link>
            <guid isPermaLink="false">https://medium.com/p/521771e7bb5f</guid>
            <dc:creator><![CDATA[Victor Irechukwu]]></dc:creator>
            <pubDate>Fri, 22 Nov 2024 01:24:35 GMT</pubDate>
            <atom:updated>2024-11-22T01:27:00.931Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/480/1*okxb3iEckjbqI9dTSztOSg.gif" /><figcaption>Gradient Descent. Image taken from - <a href="https://community.deeplearning.ai/t/difference-between-rmsprop-and-adam/310187">https://community.deeplearning.ai/t/difference-between-rmsprop-and-adam/310187</a></figcaption></figure><h3><strong>What Is Gradient Descent?</strong></h3><p>Gradient descent is like hiking downhill with your eyes closed, following the slope until you hit the bottom (or at least a nice flat spot to rest). <strong><em>Technically</em></strong>, it is a method to minimize an objective function F(θ), parameterized by a model’s parameters θ∈Rn, by updating them in the opposite direction of the gradient ∇F(θ).</p><p>The size of each step is controlled by the learning rate α. Think of α as the cautious guide who ensures you don’t tumble down too fast. If this sounds like Greek, feel free to check out my previous article, <a href="https://medium.com/@victor.irechukwu/quick-glance-at-gradient-descent-in-machine-learning-e22a747d8c73"><em>Quick Glance At Gradient Descent In Machine Learning</em></a> — I promise it’s friendlier than it sounds! 🙂</p><blockquote>Circle back: An <strong>objective function</strong> is the mathematical formula or function that your model aims to <strong>minimize</strong> (or maximize, depending on the goal) during training. It represents a measure of how far off your model’s predictions are from the actual outcomes or desired values.</blockquote><blockquote>For example:</blockquote><blockquote>In <strong>machine learning</strong>, it could be a <strong>loss function</strong> like Mean Squared Error (MSE) for regression tasks or Cross-Entropy Loss for classification tasks.</blockquote><blockquote>The objective function maps the model’s predictions to a <strong>numerical value</strong>, where smaller values indicate better performance.</blockquote><blockquote>In simpler terms:</blockquote><blockquote>It’s like a “fitness tracker” for your model — it tells you how good or bad your model’s predictions are. During optimization, gradient descent helps adjust the model’s parameters θ to reduce this value step by step, moving closer to an ideal solution. Got it? 😄</blockquote><h3>Gradient Descent Variants</h3><p>Gradient descent isn’t a one-size-fits-all deal. It comes in three variants, each like a different hiker — some take the scenic route, others sprint downhill, and a few prefer shortcuts (like me 😅). These variants balance accuracy and speed, depending on how much data they use to calculate the gradient.</p><h4>1. Batch Gradient Descent</h4><p>Batch gradient descent, the <strong><em>“all-or-nothing”</em></strong> hiker, uses the entire dataset to compute the gradient of the cost function:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/362/1*1MCUlRDCk9VzsT9ZSKQe9A.png" /></figure><p>Imagine stopping to look 👀 at every rock 🪨, tree 🌴, and bird 🕊 before deciding where to place your foot 🦶🏽next. It’s thorough, but not ideal if your dataset is as big as, say, the Amazon rainforest 😩. It’s also not great if you need to learn on the fly — like updating your hiking route after spotting a bear 🐻‍❄️.</p><p><strong>Code Example:</strong></p><pre>for i in range(nb_epochs):<br>    params_grad = evaluate_gradient(loss_function, data, params)<br>    params = params - learning_rate * params_grad</pre><p>Batch gradient descent shines when you have all the time in the world and a dataset that fits neatly into memory. It’s guaranteed to find the global minimum for convex surfaces (smooth hills) or a local minimum for non-convex surfaces (rugged mountains).</p><h4>2. Stochastic Gradient Descent (SGD)</h4><p>SGD is the <strong><em>“impulsive”</em></strong> hiker who takes one step at a time based on the current terrain:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/482/1*ufwCx_-SdUvlPhb0j4zGjA.png" /></figure><p>It’s faster because it doesn’t bother calculating gradients for the entire landscape. Instead, it uses one training example at a time. While this saves time, the frequent updates can make SGD look like it’s <strong><em>zigzagging</em></strong> downhill, which can be both exciting and a little chaotic. 😅</p><p>Imagine updating your grocery list after each aisle — you get to the essentials faster, but your cart might look wild in the process. However, with a learning rate that slows down over time, SGD can eventually reach the bottom (or the best local minimum).</p><p><strong>Code Example:</strong></p><pre>for i in range(nb_epochs):<br>    np.random.shuffle(data)<br>    for example in data:<br>        params_grad = evaluate_gradient(loss_function, example, params)<br>        params = params - learning_rate * params_grad</pre><h4>3. The Hero of the Day: Adam 🙌🏽</h4><p>Now let’s talk about Adam — the <strong><em>“hiking guru”</em></strong> who combines the wisdom of <a href="https://towardsdatascience.com/gradient-descent-with-momentum-59420f626c8f">Momentum</a> and <a href="https://towardsdatascience.com/understanding-rmsprop-faster-neural-network-learning-62e116fcf29a">RMSprop</a>. Adaptive Moment Estimation (Adam) is like having a smart guide who tracks the terrain and adjusts your steps based on past experiences and current conditions. It’s the go-to optimizer when you want to train neural networks and still have time for coffee.</p><h4>Why You’ll Love Adam</h4><ul><li><strong>Low Memory Requirements:</strong> It’s like carrying a lightweight backpack — efficient but still packed with essentials.</li><li><strong>Minimal Hyperparameter Tuning:</strong> Adam works well out of the box, so you won’t need to fiddle with too many knobs (just keep an eye on the learning rate).</li><li><strong>Practical Use:</strong> From improving product recommendations to recognizing images of cats on the internet, Adam powers machine learning systems that make your everyday tech smarter.</li></ul><h4>How Adam Works</h4><p>Adam maintains moving averages of gradients (mt​) and squared gradients (vt​) to adapt learning rates for each parameter:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/506/1*C2-AyIHzYAvFpOUH4BfwZA.png" /></figure><p>Here’s the cool part: Adam corrects biases to ensure accuracy, and updates parameters using this formula:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/398/1*8a8-W8yuVb6Fi0GLuGu9EA.png" /></figure><p>where m^t and v^t are bias-corrected estimates, and epsilon ϵ is a small number to prevent division by zero.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/484/0*od2cs7VRLcqeYcDm.png" /></figure><h3>Conclusion</h3><p>Adam is the Swiss Army knife of optimizers — versatile, efficient, and reliable. Whether you’re training neural networks to detect fraud or create next-gen chatbots, Adam helps you get there faster and with fewer headaches. So, embrace Adam, take confident steps, and enjoy the view from the summit of machine learning success!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=521771e7bb5f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Architecting Scalable API Infrastructure for Open Banking: Challenges and Best Practices]]></title>
            <link>https://medium.com/@victor.irechukwu/architecting-scalable-api-infrastructure-for-open-banking-challenges-and-best-practices-1a3f09ded1a4?source=rss-cfafc141513f------2</link>
            <guid isPermaLink="false">https://medium.com/p/1a3f09ded1a4</guid>
            <dc:creator><![CDATA[Victor Irechukwu]]></dc:creator>
            <pubDate>Thu, 21 Nov 2024 22:58:56 GMT</pubDate>
            <atom:updated>2024-11-21T22:58:56.176Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ht7dGMo6NjZf75_lyMrvpA.png" /></figure><p>The financial services industry is undergoing a seismic shift, driven by Open Banking — a movement that promotes customer-centric banking through APIs. By enabling secure data sharing and seamless integrations between financial institutions and third-party providers, Open Banking unlocks new business models and customer experiences. However, <strong><em>the journey to building a scalable API infrastructure for Open Banking is rife with challenges, especially in emerging markets</em></strong>.</p><p>In this article, we talk through the challenges of architecting such infrastructures and the best practices to overcome them. We also shed light on how our team at <a href="https://onepipe.com/">OnePipe</a>, a trailblazing fintech organization in Nigeria, is addressing these challenges head-on.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*jZFjzXsY55SrSoWJJBrAbQ.jpeg" /></figure><h4>Challenges of Architecting Scalable API Infrastructure</h4><p>To build a scalable API infrastructure, you must brace yourself for the following challenges: 😑</p><p><strong>1. Compliance with Regulatory Standards</strong><br>Open Banking ecosystems must comply with complex and evolving regulations such as PSD2 in Europe or CBN’s Open Banking regulations in Nigeria. These mandates often require implementing stringent security measures (e.g., compliance with GDPR [NDPR in the case of Nigeria], adherence to PCIDSS standards, ISO 27001 certification and other security standards) while maintaining operational agility.</p><p><strong>2. Handling High Volumes of Traffic</strong><br>Open Banking APIs deal with varying demand as third-party apps integrate and grow. A sudden spike in traffic during busy times (like loan disbursements or salary processing) can overwhelm poorly designed systems, causing slowdowns or even crashes.</p><p><strong>3. Security and Fraud Prevention</strong><br>Exposing APIs to external developers / parties increases the risk of data breaches and fraud. Ensuring secure access control, monitoring API usage, and enforcing rate limits are paramount to maintaining trust.</p><p><strong>4. Data Standardization</strong><br>Open Banking mandates consistent data formats to enable interoperability. Achieving this in markets where legacy systems still dominate can be challenging and resource-intensive. While Open Banking is still taking shape in some parts of the world like Africa, key players like OnePipe are taking proactive steps to create standards that bridge the gap between modern APIs and legacy systems, helping drive the industry forward.</p><p><strong>5. Latency and Real-Time Processing</strong><br>Things are moving fast these days. Users demand low-latency systems, particularly for time-sensitive transactions like payments. Architecting your systems to achieve sub-second response times while scaling appropriately requires significant expertise.</p><p><strong>6. Integration with Legacy Systems</strong><br>Oops! Many financial institutions rely on outdated legacy systems. Integrating these with modern, microservices-based API infrastructures requires strategic planning and often a phased approach.</p><h4>So, what best practices can we adopt when architecting scalable API infrastructure?</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*oDRD7nGZ4VCYprMKqeOL9w.png" /></figure><p><strong>1. If Possible, Adopt a Microservices Architecture</strong><br>Breaking down monolithic systems into loosely coupled microservices can allow the Open Banking APIs to scale independently, ensuring optimal performance during traffic spikes. It also enhances fault tolerance, so failures in one service don’t impact the entire system. Engineering this with containers and tools like Kubernetes and Docker can ensure a more flexible, efficient, and resilient infrastructure.</p><p><strong>2. Implement an API Gateway</strong><br>Use API gateways (e.g., Kong, AWS API Gateway) to manage traffic, enforce rate limits, and provide centralized security. Also, building your own API gateway is certainly possible, and it can provide your organisation or startup with full control over traffic management, security, and custom features tailored to your specific needs. The advantage of building your own is the flexibility to implement unique policies, optimize performance for your use case, and avoid the limitations of third-party solutions, which can be crucial in the early stages of scaling.</p><p><strong>3. Leverage Event-Driven Architectures</strong><br>Given the fast-paced nature of today’s world and the need for speed in transactions, event-driven systems can help enable efficient handling of high-volume, asynchronous operations, ensuring smooth processes without blocking. They also allow real-time event processing, which is crucial for timely responses in Open Banking applications. Imagine a customer, Damilola, who’s in an urgent situation and needs to make a payment to cover an emergency medical bill. As she initiates the payment, the transaction can trigger an event-driven system where the payment request is immediately authorised and processed asynchronously. Behind the scenes, an event broker like Kafka picks up the payment event, sends it to the payment gateway/provider, and verifies the transaction in real-time without holding up any other processes. Damilola doesn’t have to wait for the system to process everything in a sequential manner; she gets a quick confirmation that her payment is being processed. Within seconds, the system updates her account balance and the healthcare provider’s system, all in real-time. This is the power of event-driven architectures in action: fast, efficient, and seamless transaction processing — exactly what Damilola needed during her time-sensitive emergency.</p><p><strong>4. Use Cloud-Native Infrastructure</strong><br>Cloud platforms like AWS, Azure, or GCP provide the elasticity to handle traffic spikes without requiring upfront capital investment. Features like auto-scaling and serverless functions enhance cost efficiency and scalability.</p><p><strong>5. Prioritize Security</strong><br>Always be ready for the “Bad Guys” — they’re constantly on the lookout for ways to exploit your system. Implement strong, secure authentication, add web application firewalls (WAFs), intrusion detection systems, and run regular security audits to stay one step ahead and keep the risks at bay!</p><p><strong>6. Design for Observability</strong><br>Don’t be blind to what’s happening with your transactions! Use distributed tracing, logging, and monitoring tools (like ELK Stack, Prometheus, Grafana, CloudWatch etc) to get real-time insights into system health and API performance. This way, you can troubleshoot and keep things running smoothly before they turn into big problems!</p><h4>How OnePipe Is Solving Open Banking API Infrastructure Problems</h4><p>The OnePipe Mantra — <em>“The world needs a new type of financial services ecosystem. One where everyone has a role to play, and everyone has some value to capture. And while there’s a need for some gatekeepers, their influence needs to be minimal.”</em></p><p><a href="https://onepipe.com/">OnePipe</a> has emerged as a leader in Open Banking infrastructure in Africa (majorly in Nigeria), tackling the unique challenges of the region with innovative approaches:</p><p><strong>1. A Unified API Platform</strong><br>OnePipe provides a single API that connects multiple banks, fintechs, and merchants, streamlining integrations. This eliminates the need for third parties to build and maintain multiple connections.</p><p><strong>2. Middleware for Legacy Integration</strong><br>Many banks in Nigeria still operate on legacy systems. OnePipe acts as a middleware layer, translating requests from modern API consumers into protocols compatible with legacy systems.</p><p><strong>3. Scalable Cloud Infrastructure</strong><br>OnePipe leverages cloud-native solutions to ensure high availability and performance. With auto-scaling capabilities, the infrastructure is able handle traffic spikes during high-demand periods, such as payday transactions, lending and other banking as a service events.</p><p><strong>4. Security at the Core</strong><br>Recognizing the sensitive nature of financial data, OnePipe employs robust security measures such as tokenized access, rate limiting, and continuous security watch. The platform also complies with Nigeria’s Open Banking regulatory framework, NDPR (Nigeria Data Protection Regulation), and PCIDSS (Payment Card Industry Data Security Standard), ensuring the highest levels of data protection. All of this helps maintain trust among stakeholders and ensures your data is in safe hands.</p><p><strong>5. Event-Driven Architecture</strong><br>OnePipe uses an event-driven model to ensure real-time processing of financial transactions.This reduces latency and provides a smooth user experience for both financial institutions and end-users.</p><p><strong>6. Localized Innovations</strong><br>Unlike global solutions that may overlook local market nuances, OnePipe is deeply attuned to Nigeria’s financial landscape and works closely with its partner banks. Products like **PaywithTransfer**, **GrowTrade**, and **PaywithAccount**, among other popular regional payment methods, are being layered onto the ground classic API infrastructure, ensuring inclusivity.</p><h4>The Impact of OnePipe’s Innovations</h4><p>Through its innovative architecture, OnePipe has: <br>- Empowered businesses across Africa to launch financial services quickly and cost-effectively. <br>- Enabled a number of banks and fintechs to collaborate, fostering a robust Open Banking ecosystem in Nigeria. <br>- Reduced the technical and financial barriers for small businesses to participate in Open Banking.</p><h4>Conclusion</h4><p>I hope you were able to gain some insights into what it means to architect a scalable API infrastructure for Open Banking and the technical challenges it comes with. By embracing best practices like microservices, cloud-native architectures, and rock-solid security protocols, fintechs can create systems that not only innovate but also pave the way for financial inclusion.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1a3f09ded1a4" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Overview Of The Hidden Markov Model (HMM)— What it can do for you in Machine Learning]]></title>
            <link>https://medium.com/@victor.irechukwu/overview-of-the-hidden-markov-model-hmm-what-it-can-do-for-you-in-machine-learning-83b3003297b9?source=rss-cfafc141513f------2</link>
            <guid isPermaLink="false">https://medium.com/p/83b3003297b9</guid>
            <category><![CDATA[statistics]]></category>
            <category><![CDATA[mathematics]]></category>
            <category><![CDATA[machine-learning]]></category>
            <dc:creator><![CDATA[Victor Irechukwu]]></dc:creator>
            <pubDate>Mon, 17 Dec 2018 15:57:26 GMT</pubDate>
            <atom:updated>2018-12-17T16:15:21.437Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/620/1*WXvew0lSjoQaboklPnB7ZQ.jpeg" /><figcaption><a href="https://www.computerworld.com/article/2935605/emerging-technology/speech-recognition-glamour-and-deceit.html">Speech Recognition</a></figcaption></figure><p>The Hidden Markov Model (HMM) is a relatively simple way to model sequential data. It is a statistical <em>Markov model</em> in which the system being modelled is assumed to be a <em>Markov process</em> with unobserved (i.e. <em>hidden</em>) states. You only know observational data and not information about the states.</p><h4>First, What’s A Markov Model?</h4><p>In order to uncover the Hidden Markov Model, we need to understand what a Markov Model is in the first place. <strong><em>A Markov model describes the probabilistic relationship between different states</em></strong>. Suppose we have a system with three states: ‘happy’, ‘sad’, and ‘angry’. Over the course of a day (let’s say every hour) a person will be in a particular state, e.g the one that corresponds to their emotion. A person can stay in one state for several hours and then potentially change to a different state. This can be represented as a Markov Model where we think of a sequence of states, and where each state depends on the previous state at a particular instant in time (e.g a certain hour of the day) with some probabilistic measures.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/600/1*KsifKPWYQPgAfGG6jFFPUA.png" /><figcaption>Probabilistic transitioning of emotional states</figcaption></figure><h4>Back To Hidden Markov Model..</h4><p>In Markov models, <em>the state is directly visible to the observer</em>, and therefore the state transition probabilities are the only parameters, while in the hidden Markov model, <em>the state is not directly visible</em>, but the output, dependent on the state, is visible. That is, in real life we will not have the sequence of states our system went through, instead we will have sequences of observations that are dependent on each state.</p><p><strong><em>A Concrete Example of HMM<br></em></strong>Reference: <a href="https://en.wikipedia.org/wiki/Hidden_Markov_model">Hidden_Markov_Model</a></p><p>Now let’s expatiate more on HMM by using the following example. Consider two friends, Alice and Bob, who live far apart from each other and who talk together daily over the telephone about what they did that day. Bob is only interested in three activities: walking in the park, shopping, and cleaning his apartment. The choice of what to do is determined exclusively by the weather on a given day. Alice has no definite information about the weather, but she knows general trends. Based on what Bob tells her he did each day, Alice tries to guess what the weather must have been like.</p><p>Alice believes that the weather operates as a discrete <em>Markov chain</em>. There are two states, “<strong>Rainy</strong>” and “<strong>Sunny</strong>”, but she cannot observe them directly, that is, they are <em>hidden</em> from her. On each day, there is a certain chance that Bob will perform one of the following activities, depending on the weather: “walk”, “shop”, or “clean”. Since Bob tells Alice about his activities, those are the <strong><em>observations</em></strong>. The entire system is that of a hidden Markov model (HMM).</p><p>Alice knows the general weather trends in the area, and what Bob likes to do on average. In other words, the parameters of the HMM are known. They can be represented as follows in Python:</p><pre>states = (&#39;Rainy&#39;, &#39;Sunny&#39;)<br> <br>observations = (&#39;walk&#39;, &#39;shop&#39;, &#39;clean&#39;)<br> <br>start_probability = {&#39;Rainy&#39;: 0.6, &#39;Sunny&#39;: 0.4}<br> <br>transition_probability = {<br>   &#39;Rainy&#39; : {&#39;Rainy&#39;: 0.7, &#39;Sunny&#39;: 0.3},<br>   &#39;Sunny&#39; : {&#39;Rainy&#39;: 0.4, &#39;Sunny&#39;: 0.6},<br>   }<br> <br>emission_probability = {<br>   &#39;Rainy&#39; : {&#39;walk&#39;: 0.1, &#39;shop&#39;: 0.4, &#39;clean&#39;: 0.5},<br>   &#39;Sunny&#39; : {&#39;walk&#39;: 0.6, &#39;shop&#39;: 0.3, &#39;clean&#39;: 0.1},<br>   }</pre><p>In this piece of code, start_probability represents Alice&#39;s belief about which state the HMM is in when Bob first calls her (all she knows is that it tends to be rainy on average). The particular probability distribution used here is not the equilibrium one, which is (given the transition probabilities) approximately {&#39;Rainy&#39;: 0.57, &#39;Sunny&#39;: 0.43}. The transition_probability represents the change of the weather in the underlying Markov chain. In this example, there is only a 30% chance that tomorrow will be sunny if today is rainy. The emission_probability represents how likely Bob is to perform a certain activity on each day. If it is rainy, there is a 50% chance that he is cleaning his apartment; if it is sunny, there is a 60% chance that he is outside for a walk.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/400/0*80SCq0OoPbH6jTNc.png" /><figcaption>Representation of the Hidden Markov Model. ‘Rainy’ and ‘Sunny’ are the hidden states. ‘Walk’, ‘Shop’ and ‘Clean’ are the observations</figcaption></figure><p>Hidden Markov models are especially known for their application in:</p><blockquote><strong>Reinforcement Learning, </strong>an area of machine learning concerned with how software agents ought to take actions in an <em>environment</em> so as to maximise some notion of cumulative <em>reward</em>.</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/400/1*NPE62KxKd0BEjIWfLbQIDA.png" /><figcaption>The typical framing of a Reinforcement Learning (RL) scenario: an agent takes actions in an environment, which is interpreted into a reward and a representation of the state, which are fed back into the agent.</figcaption></figure><blockquote><strong>Speech recognition</strong>, an inter-disciplinary sub-field of computational linguistics that develops methodologies and technologies that enables the recognition and translation of spoken language into text by computers.</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hyHSLLIxhQBIiBAGIyu9RA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/552/1*uG1YKJcaPrOHwivhJMbBVQ.jpeg" /><figcaption><a href="https://www.researchgate.net/publication/226137686_Wavelet_network_for_recognition_system_of_Arabic_word">https://www.researchgate.net/publication/226137686_Wavelet_network_for_recognition_system_of_Arabic_word</a></figcaption></figure><blockquote><strong>Pattern recognition</strong>, an automated recognition of patterns and regularities in data in machine learning.</blockquote><blockquote>Other applications include Analysis of biological sequences (e.g. proteins and DNA), Happy Customer Insights, Handwriting recognition, Fraud Detection etc.</blockquote><p>If there’s need for you to apply a <strong>probabilistic</strong> approach to a machine learning problem that typically follows a sequential state, you can always feel free to explore the Hidden Markov Model.</p><p>See <a href="https://hmmlearn.readthedocs.io/en/latest/tutorial.html">https://hmmlearn.readthedocs.io/en/latest/tutorial.html</a> for insights on Python implementation. There are other implemented HMM libraries available in other languages.</p><p>That’s it for now. I hope you learned one thing or two about the Hidden Markov Model. For more information about this statistical model and mathematical description, please feel free to go through the articles on my reference.</p><p><strong>REFERENCE</strong></p><p><a href="http://www.math.chalmers.se/~olleh/Markov_Karlsson.pdf">http://www.math.chalmers.se/~olleh/Markov_Karlsson.pdf</a></p><p><a href="https://en.wikipedia.org/wiki/Hidden_Markov_model">Hidden Markov Model</a></p><p><a href="https://medium.com/@postsanjay/hidden-markov-models-simplified-c3f58728caab">Hidden Markov Models Simplified</a></p><p><a href="https://valserb.wordpress.com/2011/08/02/understanding-hidden-markov-models/">Understanding Hidden Markov Models</a></p><p><a href="https://hackernoon.com/from-what-is-a-markov-model-to-here-is-how-markov-models-work-1ac5f4629b71">From “What is a Markov Model” to “Here is how Markov Models Work”</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=83b3003297b9" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Quick Glance At Gradient Descent In Machine Learning]]></title>
            <link>https://medium.com/@victor.irechukwu/quick-glance-at-gradient-descent-in-machine-learning-e22a747d8c73?source=rss-cfafc141513f------2</link>
            <guid isPermaLink="false">https://medium.com/p/e22a747d8c73</guid>
            <category><![CDATA[gradient]]></category>
            <category><![CDATA[learning-rate]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[gradient-descent]]></category>
            <dc:creator><![CDATA[Victor Irechukwu]]></dc:creator>
            <pubDate>Sat, 19 May 2018 22:10:40 GMT</pubDate>
            <atom:updated>2018-05-19T22:10:40.476Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/512/1*S3oLN40uWnGmP63lOFEDUg.gif" /><figcaption>Gradient Descent. Image taken from — <a href="https://github.com/pvigier/gradient-descent">https://github.com/pvigier/gradient-descent</a></figcaption></figure><p>Climbing mountains has always been fun. I love the beauty, coolness and sweetness of nature experienced at the mountain-top 🙂. Of course, after much enjoyment at the peak, there’s need for one to hike down the mountain 😁! Our goal is to reach the bottom of the mountain, and this movement down the mountain helps us understand the concept of <strong><em>Gradient Descent </em></strong><em>— w</em>e keep going in the downward direction, until we hit the bottom!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/1*os70OINM-YNi5aA-iCXEww.jpeg" /><figcaption>Hiking down a mountain — <a href="http://www.cee.mtu.edu/atmospheric/atmos_pico.html">http://www.cee.mtu.edu/atmospheric/atmos_pico.html</a></figcaption></figure><p>In this post I’ll give an introduction to the <em>gradient descent</em> algorithm, and walk through an example that demonstrates how gradient descent can be used to solve problems in machine learning.</p><p><strong>Gradient descent</strong> is an optimisation algorithm that is used on most Machine Learning Models; it is used to find the minimum of a given function. It starts with an initial set of parameter values and iteratively moves toward a set of parameter values that minimise the function. This iterative minimisation is achieved using calculus, taking steps in the negative direction of the function <strong><em>gradient</em></strong>.</p><h4><strong><em>What then is the Gradient of a function?</em></strong></h4><p><em>“A gradient measures how much the output of a function changes if you change the inputs a little bit.” — Lex Fridman (MIT)</em></p><p>You can think of a gradient as the slope of a function. The higher the gradient, the steeper the slope and the faster a model learns. But if the slope is zero, the model stops learning.</p><p>A set of inputs makes up the output of a function and rate of change of the output with respect to changes in the inputs gives us the gradient of the function. It points towards direction of the fastest increase of the function.</p><p>For example, given a function <em>F(a, b, c)</em> defined by:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/273/1*Hv0QagNA8HKgnawrxwKTfg.png" /></figure><p>Mathematically, the gradient of the function becomes:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/491/1*F5ilYTXBRP_RtjZFMZAmDw.png" /></figure><h4>Why Gradient Descent?</h4><p><em>It is an iterative process that takes us to the minimum of a function. </em>In the process of hiking down the mountain we walk in the downward direction opposite to the fastest increase. This means, if we are at point <strong><em>a0</em></strong><em> </em>and want to move to lowest nearby point (we say “local minimum”) our next point should be at:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/221/1*asmJf0p8ubwkgijCNxAAwA.png" /><figcaption>a0 is the current point while a1 (next point) is our new lowest nearby point</figcaption></figure><h4><strong>What then does α stand for?</strong></h4><p>α is called the <em>Learning Rate</em> or <em>step size</em>. Which means, we want to take very little steps so that we don’t overshoot the bottom. This is really important when we become very close to the minimum. A very good choice of α is crucial. When α is too small, it will take our algorithm very long time to reach the lowest point and if α is too big we might overshoot and miss the bottom or minimum.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*An4tZEyQAYgPAZl396JzWg.png" /><figcaption>Effect of choice of learning rate — <a href="https://meta.tn/a/460d7aa1bb11d0cbfb2c1281b01e996e99871c4061f3f776407ee89fdb65e1da">https://meta.tn/a/460d7aa1bb11d0cbfb2c1281b01e996e99871c4061f3f776407ee89fdb65e1da</a></figcaption></figure><h4><strong>Did you also notice the − sign?</strong></h4><p>− sign shows that we are taking steps in the direction opposite to that of ∇F i.e. we are stepping in the direction opposite to that of fastest increase!</p><h4>Other Observations</h4><p>To use the gradient descent algorithm, the following are the few important things to keep in mind:</p><ul><li>The function must be differentiable</li><li>Use optimal choice of learning rate α — it should not be too small or too big</li></ul><h4>Example in one variable</h4><p>To simply explain the mathematics of gradient descent, I will use a function with just one variable for now 😉.</p><p>Suppose we have a function <em>F(a)</em> such that:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/97/1*yVqgVQjsEPZHDeiRzjVc9w.png" /></figure><p>Then, the derivative of <em>F(a)</em> becomes:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/94/1*PauvfKleje5yMtJp03JSIA.png" /></figure><p>Let’s take our initial choice of point and learning rate to be <strong><em>a0</em></strong> = 1 and α = 0.4 respectively. This implies:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/290/1*2W8c2KUub2nNIXhbL0sT_Q.png" /></figure><p>Yay! we see that we are indeed approaching the minimum.</p><p>That’s it for now. I hope you learned one thing or two about Gradient Descent. For more information about gradient descent, linear regression, and other machine learning topics, please feel free to go through the articles on my reference.</p><p><strong>REFERENCE</strong></p><p><a href="https://hackernoon.com/gradient-descent-aynk-7cbe95a778da"><em>Gradient Descent: All You Need to Know</em></a></p><p><a href="https://towardsdatascience.com/gradient-descent-in-a-nutshell-eaf8c18212f0"><em>Gradient Descent in a Nutshell</em></a></p><p><a href="https://spin.atomicobject.com/2014/06/24/gradient-descent-linear-regression/"><em>An Introduction to Gradient Descent and Linear Regression</em></a></p><p><a href="https://medium.com/ai-society/hello-gradient-descent-ef74434bdfa5"><em>Hello, Gradient Descent</em></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e22a747d8c73" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>