Learning AI - Machine Learning Through Real-World Problems.

Learning AI - Machine Learning Through Real-World Problems.

Part 1: The Journey Begins: Learning Machine Learning Through Real-World Problems

When I first heard about Machine Learning (ML), I thought it was a highly complex technology meant only for those proficient in mathematics and programming. I had read many materials about it, but it wasn’t until I applied ML to the Credit Risk problem that I truly understood it. This is not just a story about applying technology but also about how I learned through trial and error.


1. Starting Point: "Trial and Error" is the Best Way to Learn ML

In science, we are taught to approach problems using the "trial and error" method:

  1. Trial: Propose a hypothesis or approach.
  2. Error: Compare the results with reality and identify mistakes.
  3. Iterate: Improve the approach until achieving the best result.

I applied this exact approach when building ML models. Initially, I used basic algorithms like Logistic Regression, then tried Random Forest and Gradient Boosting. The results improved gradually with each experiment. ML, at its core, is about "trial and error" but done systematically.


2. Machine Learning: "Teaching Machines to Learn" from Data

Imagine you are a new credit officer. You need to decide which customers to approve for loans and which ones are high-risk. Your manager gives you historical data:

  • Customer information: Income, loan amount, repayment history.
  • Actual results: Who defaulted, who didn’t.

You would learn from this data to make better decisions. ML works the same way:

  • Input data (features): Customer characteristics.
  • Output labels: Whether the customer defaulted or not.

The model learns to connect the input to the output, then creates a formula to predict outcomes for new customers.


3. Tips for Starting with ML

  1. Understand the Basics: Recognize that ML is about "machines" learning from data through repeated trials.
  2. Practice with Real Problems: Instead of just reading theory, pick a specific problem to solve.
  3. Focus on Data: Cleaning and understanding data is more important than choosing the algorithm.


Part 2: Lessons Learned from Applying ML to Credit Risk

When applying ML to the Credit Risk problem, I realized that understanding data and the real-world problem is even more important than mastering complex algorithms.


1. Data is the Decisive Factor

In this problem, I used variables like:

  • On-time payment rate (on_time_rate): How often a customer pays on time.
  • Late payment count (late_count): How many times a customer was late.
  • Loan-to-income ratio (loan_to_income): Loan amount compared to customer income.

These variables are key to predicting who is high-risk. However, the hardest part wasn’t choosing the variables but cleaning and normalizing the data so the model could understand it.


2. ML is Not Just "Throwing Data at a Model"

Initially, I thought it was enough to feed data into a model and let the algorithm handle everything. But the reality is much more complex:

  • Understanding the Problem: Why are certain customers high-risk? What factors increase default probability?
  • Hyperparameter Optimization: Finding the best parameters, like the number of trees in Random Forest or the depth of trees in Gradient Boosting.


3. The "Experiment Never Ends" Process

During optimization, I used tools like RandomizedSearchCV to test various parameter combinations. Even after finding a good result, I had to check further:

  • Does the new data change the outcome?
  • Is the result truly stable?


4. Practical Advice from Real-World Lessons

  1. Spend Time on Data: Good data is the foundation of a good model. Understand its meaning and how to process it.
  2. Be Patient with Learning: ML is not magic. It requires many trials and failures.
  3. Combine Theory and Practice: Only by applying ML to real-world problems can you truly understand its significance.

I hope this article can help young students better understand AI. My message to you is this: you can only truly understand something by doing, not just by studying. Start working on projects, even small ones, as they will help you grasp the concepts. Later, when you encounter similar problems at work, you will already have the solutions in mind.        

I realized that learning ML is not just about mastering tools or algorithms but understanding how to apply them to real-world problems. Credit Risk is just one of the countless applications of ML, but it has helped me deeply understand how data and technology can create value in life.


Through this real-world scenario, you can see how scientific thinking is widely applied in quantitative finance. This is why many quant funds prioritize hiring individuals with backgrounds in mathematics and physics. These professionals are accustomed to scientific reasoning, probability, trial-and-error, uncertainty, and the noise inherent in financial markets.


Dam Van Vi

Author of the IQMG, IQMS quantitative model (Investing model) and CRRSM, CRRSE quantitative model (Rating Equity, Mutual Fund model).

Asif Haider

COO at AxeGENAI | Host of AYAYAYai Podcast | AI/ML Upskilling, Lifecycle, Workshop Facilitator, Prototype Developer, Auditor, Assessment | Agile | CMMC | Ethical Hacker | Data ETL | Career Readiness Coach at FourBlock |

2 个月

要查看或添加评论,请登录

Dam Van Vi的更多文章

社区洞察

其他会员也浏览了