eli5
eli5 copied to clipboard
explain_prediction_keras support more types for doc
The explain_prediction_keras
function (https://github.com/TeamHG-Memex/eli5/pull/325) takes a doc
argument that is the input to a Keras model. Currently doc
must be a numpy array.
It would be nice to support other types for doc
, not just numpy arrays. See https://github.com/keras-team/keras/blob/ed07472bc5fc985982db355135d37059a1f887a9/keras/engine/training.py#L1315 or https://keras.io/models/sequential/#predict for a list of what types input Keras models can accept.
In particular for text it would be nice to support input in a Python list
(for example keras.preprocessing.sequence.pad_sequences
can return lists).