INNER CODE UNIT · Python

workflow

bansalkanav/Ultimate-Data-Science-Toolkit---From-Python-Basics-to-GenerativeAI · Module 5 - MLOPs/4. Orchestrate ML Pipeline/my_workflow_script.py:74

def workflow():
    DATA_PATH = "data/iris.csv"
    INPUTS = ['SepalLengthCm', 'SepalWidthCm', 'PetalLengthCm', 'PetalWidthCm']
    OUTPUT = 'Species'
    HYPERPARAMETERS = {'n_neighbors': 3, 'p': 2}
    
    # Load data
    iris = load_data(DATA_PATH)

    # Identify Inputs and Output
    X, y = split_inputs_output(iris, INPUTS, OUTPUT)

    # Split data into train and test sets
    X_train, X_test, y_train, y_test = split_train_test(X, y)

    # Preprocess the data
    X_train_scaled, X_test_scaled, y_train, y_test = preprocess_data(X_train, X_test, y_train, y_test)

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…