I want to make some simple string operations within the keras model such that it can be end-to-end.
def get_model_para_pure():
para = keras.Input(shape=(1, ), dtype="string", name='para')
para_lower = tf.strings.lower(para)
shingles = tf.strings.split(para_lower)
...
however, it raises the error:
Tensor conversion requested dtype int32 for Tensor with dtype int64: <tf.Tensor 'Cumsum_5:0' shape=(None,) dtype=int64>
How can I implement these operations within a model.