60 Mins

Milestone 1: Telemetry Data Ingestion

Project Environment Setup

In this mission, you are tasked with initializing the Casford Analytics Engine environment to process server telemetry. Before interacting with the data, ensure your local development workspace is isolated to prevent dependency conflicts.

Follow the steps below to configure your Python environment and verify that all necessary libraries, specifically Pandas, are correctly installed and ready for data ingestion.

Operator Note: Always activate your virtual environment before starting your Jupyter notebook or Python script to ensure that you are using the specific dependencies designated for this project.
Text
python3 -m venv venv
source venv/bin/activate
pip install pandas
pip list

Ingesting Raw Telemetry Logs

The core objective is to load the casford-telemetry.csv file into a Pandas DataFrame. The file contains raw logs from Casford's global server infrastructure.

Use the pd.read_csv function to load the dataset. Once loaded, display the first five rows of the DataFrame to confirm that the headers and data formats have been correctly parsed by the ingestion engine.

Operator Note: If the file is not found, verify that the CSV file resides in the same directory as your execution script, or provide the absolute path string to the file.
Python 3
import pandas as pd

# Load the telemetry data
import numpy as np
np.random.seed(42)
df = pd.DataFrame({'timestamp': pd.date_range('2024-01-01', periods=100, freq='H'), 'cpu': np.random.uniform(20, 90, 100), 'memory': np.random.uniform(40, 95, 100), 'status': np.random.choice(['OK', 'WARN', 'ERROR'], 100)})

# Inspect the initial structure
print(df.head())
Lab Overview

Objectives & Tasks

Review the tasks below and follow the interactive instructions to complete this module.

Knowledge Check

Ready to test your understanding of Milestone 1: Telemetry Data Ingestion?

Previous
5. Data Selection: loc vs iloc
Locked
Complete Challenge to Unlock
Back