Skip to main content

Welcome to a Grasp lesson

Create a free account to keep studying and create your own study path.

Lesson 63

Architectural Differences: ML vs. Traditional Analytics

This lesson is built with resources from logicmonitor.com and databricks.com.

Hello! Welcome to the final module of our course, Architecture for AI & Machine Learning.

In our previous lessons, we delved deep into the world of business intelligence, culminating in how to optimize a data model for high-performance analytics. We focused on making traditional reporting on massive datasets fast and efficient. This work represents a classic data architecture workload: providing structured, historical insights to the business.

Now, we pivot from looking at the past to predicting the future. This lesson kicks off our exploration of AI/ML by addressing the learning outcome: Describe how ML workloads differ from traditional analytics workloads from an architectural perspective. For you as an architect, understanding these differences is the first principle of designing robust, scalable AI systems. We will see that simply running ML jobs on your analytics infrastructure is often not a viable option due to fundamental differences in process, data, and computational demands.

1. The Fundamental Paradigm Shift

Before we talk about GPUs and storage tiers, let's start with the core conceptual change. Traditional analytics, including the BI dashboards we've been working on, operates on a deterministic paradigm. You write an explicit set of rules (e.g., a SQL query or a DAX measure), feed it data, and get a predictable output.

Machine learning flips this on its head. Instead of writing the rules, you provide the data and the desired outcomes, and the machine learns the rules (the "model").

Traditional Programming vs. Machine Learning Paradigm
This diagram illustrates the core difference in approach. Traditional Programming takes Data and a user-written Program to produce an Output. Machine Learning takes Data and desired Outputs to produce a Program (the model) that can replicate those results.

This shift from a rule-based, deterministic process to a data-driven, probabilistic one has profound implications for the entire data architecture.


2. Analytics vs. ML: Contrasting Purpose and Process

The difference in paradigm leads to very different goals and development lifecycles. Traditional analytics is about introspection, while machine learning is about prediction.

To explore this, let's read a short excerpt from a Databricks blog that distinguishes between these two worlds.

Maximize Lakehouse Value with Databricks

The article 'A data architecture pattern to maximize the value of the Lakehouse' clearly contrasts modern ML use cases with traditional BI on data warehouses. This will help frame our understanding of their distinct purposes.

Read the section titled 'The background', which starts right after the introduction. Focus on the descriptions of 'Data lake for modern use cases' and 'Data warehouses'.

Based on that reading and your own experience, we can summarize the key differences in a table:

Aspect Traditional Analytics (BI) Machine Learning (AI)
Primary Goal Introspection: Answering "What happened?" and "Why?" Prediction: Answering "What might happen next?"
Core Process Reporting: Applying business logic to historical data. Training: Finding patterns in data to create a predictive model.
Data Types Primarily structured data from internal business systems. Structured, semi-structured, and unstructured data (text, images, logs).
Development Rigorous, governed, and often slow. Follows a waterfall-like process. Experimental and iterative. Involves trying different models and features.
Output A dashboard, report, or a static answer. A trained model, which is itself a piece of software to be deployed.
Lifecycle Develop and deploy. Updates are periodic. A continuous cycle (MLOps) of training, deploying, monitoring, and retraining.

Your background as an enterprise architect makes it clear that systems built for these two different modes of operation will naturally have different architectural requirements. You wouldn't use the same architecture for a transactional banking system and a high-traffic media streaming service. The same logic applies here.


3. The Architectural Implications: A New Infrastructure Playbook

The distinct characteristics of ML workloads break the traditional infrastructure playbook. Let's examine how the architectural requirements differ across the key pillars of infrastructure: compute, storage, networking, and orchestration.

The following article provides an excellent breakdown of these requirements. We will use it to guide our exploration.

AI Workload Infrastructure Requirements: What You ...

The article 'AI Workload Infrastructure Requirements' by LogicMonitor details why AI workloads demand a different approach to infrastructure. We'll read it section by section to understand the specific needs.

First, read the section 'Understanding AI Workloads: Why They’re Different' to get an overview. Then, we will work through the sections on Compute, Storage, Networking, and Deployment/Management tools.

Now, let's unpack the key architectural shifts identified in that article.

Compute: From CPU-Centric to Accelerator-Driven

  • Traditional Analytics: Workloads are typically CPU-bound. A database query engine executes SQL, which involves filtering, joining, and aggregating data—tasks well-suited for a powerful CPU.
  • Machine Learning: Model training, especially for deep learning, involves a massive number of matrix multiplication operations performed in parallel. This is where Graphics Processing Units (GPUs) and other accelerators like Tensor Processing Units (TPUs) excel. A standard CPU would take orders of magnitude longer to perform the same task. Therefore, an ML training architecture must incorporate these accelerators.

Storage: Balancing Massive Capacity and High Throughput

  • Traditional Analytics: Relies on data warehouses optimized for structured queries. Storage is built for efficient scanning and joining of tables.
  • Machine Learning: Training models requires feeding vast amounts of data to the hungry GPUs as fast as possible. This leads to a tiered storage strategy:
    1. Capacity Tier (e.g., Cloud Object Storage): Cheap, highly scalable storage like Amazon S3 or Azure Blob Storage holds the petabytes of raw training data, model artifacts, and checkpoints.
    2. Performance Tier (e.g., NVMe SSDs): Extremely fast, low-latency storage is used for active training. Data is often cached here from the capacity tier to ensure the GPUs are never idle waiting for data. This concept of keeping the compute "fed" is a primary concern in ML infrastructure design.

Networking: The Rise of East-West Traffic

  • Traditional Analytics: Network traffic is primarily "north-south"—a client application sends a query to the database server, and the server sends results back.
  • Machine learning: To train large models quickly, the workload is often distributed across multiple machines (nodes), each with its own set of GPUs. These nodes must constantly communicate to synchronize model updates. This creates enormous "east-west" traffic between the nodes. The architecture must include high-bandwidth (100+ Gbps) and low-latency network fabrics (like InfiniBand or RDMA-enabled Ethernet) to prevent the network from becoming a bottleneck.

Orchestration: From Deployment to MLOps

  • Traditional Analytics: You build a report or data pipeline and deploy it. Management is relatively static.
  • Machine Learning: The ML lifecycle is a continuous loop. Models are not one-and-done artifacts; they are dynamic systems that need constant management. This has given rise to MLOps (Machine Learning Operations). The architecture must include tools for:
    • Experiment Tracking: Logging every training run, its parameters, and results.
    • Model Registry: Versioning and storing trained models.
    • Automated Deployment & Monitoring: Pushing models to production and monitoring their performance for "drift" (degradation).
    • Workflow Orchestration: Using platforms like Kubernetes with extensions like Kubeflow to manage complex, distributed training jobs that scale up and down dynamically.
Test your understanding!

A company wants to add a 'product recommendation' feature to its e-commerce site. The existing analytics team uses a traditional cloud data warehouse for sales reporting. An executive suggests, "Just run the machine learning job on the data warehouse. The data is already there!"

As a data architect, what are three key architectural reasons why this is a bad idea?

Show answer
  1. Inadequate Compute: The data warehouse is powered by CPUs optimized for SQL queries. It lacks the GPUs necessary for efficiently training a recommendation model, which involves complex calculations on user-item interaction matrices.
  2. Storage/IO Bottleneck: While the data is in the warehouse, the storage is not designed for the high-throughput, low-latency I/O needed to continuously feed a GPU during training. The ML job would likely be starved for data, wasting expensive compute cycles.
  3. Lack of MLOps Tooling: The data warehouse environment lacks the essential MLOps ecosystem for iterative development. There is no integrated way to track experiments, version models, or automate the retraining and deployment cycle, which are critical for maintaining a production ML system.

Conclusion

Today we've established the fundamental distinctions between traditional analytics and machine learning workloads. Moving from one to the other is not just an evolution; it's a paradigm shift that requires a different architectural mindset and a purpose-built technology stack.

Key Takeaways:

  • Paradigm Shift: Analytics is deterministic and rule-based, while ML is probabilistic and learns the rules from data.
  • Process Difference: Analytics is typically a linear process focused on historical reporting, whereas ML is an iterative, experimental cycle focused on prediction.
  • Infrastructure Mismatch: ML workloads are accelerator-driven (GPU/TPU), require a tiered storage strategy for performance, depend on high-speed east-west networking, and are managed by a cyclical MLOps process. These requirements are fundamentally different from a CPU-centric, north-south oriented analytics architecture.

Now that we understand why the architecture must be different, our next lessons will explore the specific components that make up a modern ML platform.

Preview of the next lesson: In our next session, we will dive into one of the most critical components in a modern data stack for ML: the feature store. We'll explain what it is and its crucial role in standardizing and reusing data for machine learning models, bridging the gap between raw data and model training.