Skip to content

Hugging Face Iris Logistic Regression ends the run on an empty cell #8056

Description

@kz930

What happened?

The operator puts the two petal values straight into a numpy array and standardizes them:

length = tuple_[petalLengthCmAttribute]
width = tuple_[petalWidthCmAttribute]
features = np.array([[length, width]])
features = ((features - training_features_means) / training_features_stds)

When either cell is empty, that value is None, the array's dtype becomes object, and the subtraction raises TypeError: unsupported operand type(s) for -: 'NoneType' and 'float'. The run ends, and the message names neither the column nor a way out. Nothing in the configuration can exclude the row.

The three neighbouring Hugging Face operators (Sentiment Analysis, Spam Detection, Text Summarization) were changed in #7549 to keep the row and leave the result columns empty instead. This operator reads numeric columns rather than a text column, so that change did not reach it, and it is now the one operator in the group that ends the run.

I expected it to answer the empty cell the way its three siblings do: keep the row, leave the prediction columns empty.

How to reproduce?

  1. CSV File Scan on a table whose petal length or petal width column has a blank cell.
  2. Connect Hugging Face Iris Logistic Regression, pointing its two attributes at those columns.
  3. Run.

The run ends with the TypeError below. With every cell filled it completes normally.

Version/Branch

1.3.0-incubating-SNAPSHOT (main)

Relevant log output

TypeError: unsupported operand type(s) for -: 'NoneType' and 'float'

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions