de-Rodrigo commited on
Commit
33f25cc
·
1 Parent(s): ed9740d
Files changed (1) hide show
  1. app.py +2 -0
app.py CHANGED
@@ -1286,7 +1286,9 @@ def run_model(model_name):
1286
  statistic='mean', bins=[x_bins, y_bins]
1287
  )
1288
  # Transponer la matriz para alinear correctamente los ejes
 
1289
  heatmap_data = heat_stat.T
 
1290
 
1291
  # Definir el color mapper
1292
  if selected_feature in model_options:
 
1286
  statistic='mean', bins=[x_bins, y_bins]
1287
  )
1288
  # Transponer la matriz para alinear correctamente los ejes
1289
+ # Transponer y limpiar valores inválidos (NaN, inf, -inf)
1290
  heatmap_data = heat_stat.T
1291
+ heatmap_data = np.nan_to_num(heat_stat.T, nan=0.0, posinf=0.0, neginf=0.0)
1292
 
1293
  # Definir el color mapper
1294
  if selected_feature in model_options: