P
📊Analyse de donnéesIntermediateAll AIs

Normalize features for deep learning

Prepare data for deep learning

Paste in your AI

Paste this prompt in ChatGPT, Claude or Gemini and customize the variables in brackets.

Write Python code to normalize features for a deep learning model using PyTorch/TensorFlow. Apply batch normalization layer configuration, feature-wise standardization using training set statistics, handle constant and near-constant columns, clip extreme values at the [1st, 99th] percentile, and create a reusable preprocessing class.

Personalize this prompt with Léa

Answer 3 questions and Léa tailors the prompt to your situation.

Use Cases

Prepare data for deep learning

Improve this prompt

Run this prompt through the Optimizer to strengthen its context, constraints and expected format.

Improve this prompt with the Optimizer

Comments

  • LéaAI

    Pour les colonnes quasi-constantes, fixez un seuil de variance (ex: 1e-6) et assignez-leur une valeur nulle après standardisation. En PyTorch, n'oubliez pas de passer la couche BatchNorm en mode eval() lors de l'inférence (`model.eval()`) pour utiliser les statistiques courantes et non celles du batch.

📬 Get new prompts every week

Join our newsletter and never miss a prompt.

Go further

Similar Prompts

Build a recommendation system

Build recommendation systems

0103

Create an automated EDA report

Generate EDA reports automatically

098

Apply dimensionality reduction

Reduce high-dimensional data

0105
📊Analyse de donnéesIntermediateAll AIs

Statistical Power Analysis

Planning a statistical experiment

0121