![]() |
![]() |
![]() |
![]() |
本教程演示了如何对结构化数据进行分类(例如,CSV 中的表格数据)。我们将使用 Keras 来定义模型,将特征列(feature columns) 作为从 CSV 中的列(columns)映射到用于训练模型的特征(features)的桥梁。本教程包括了以下内容的完整代码:
- 用 Pandas 导入 CSV 文件。
- 用 tf.data 建立了一个输入流水线(pipeline),用于对行进行分批(batch)和随机排序(shuffle)。
- 用特征列将 CSV 中的列映射到用于训练模型的特征。
- 用 Keras 构建,训练并评估模型。
数据集
我们将使用一个小型 数据集,该数据集由克利夫兰心脏病诊所基金会(Cleveland Clinic Foundation for Heart Disease)提供。CSV 中有几百行数据。每行描述了一个病人(patient),每列描述了一个属性(attribute)。我们将使用这些信息来预测一位病人是否患有心脏病,这是在该数据集上的二分类任务。
下面是该数据集的描述。 请注意,有数值(numeric)和类别(categorical)类型的列。
列 描述 特征类型 数据类型 Age 年龄以年为单位 Numerical integer Sex (1 = 男;0 = 女) Categorical integer CP 胸痛类型(0,1,2,3,4) Categorical integer Trestbpd 静息血压(入院时,以mm Hg计) Numerical integer Chol 血清胆固醇(mg/dl) Numerical integer FBS (空腹血糖> 120 mg/dl)(1 = true;0 = false) Categorical integer RestECG 静息心电图结果(0,1,2) Categorical integer Thalach 达到的最大心率 Numerical integer Exang 运动诱发心绞痛(1 =是;0 =否) Categorical integer Oldpeak 与休息时相比由运动引起的 ST 节段下降 Numerical integer Slope 在运动高峰 ST 段的斜率 Numerical float CA 荧光透视法染色的大血管动脉(0-3)的数量 Numerical integer Thal 3 =正常;6 =固定缺陷;7 =可逆缺陷 Categorical string Target 心脏病诊断(1 = true;0 = false) Classification integer
导入 TensorFlow 和其他库
pip install -q sklearn
import numpy as np
import pandas as pd
import tensorflow as tf
from tensorflow import feature_column
from tensorflow.keras import layers
from sklearn.model_selection import train_test_split
使用 Pandas 创建一个 dataframe
Pandas 是一个 Python 库,它有许多有用的实用程序,用于加载和处理结构化数据。我们将使用 Pandas 从 URL下载数据集,并将其加载到 dataframe 中。
URL = 'https://storage.googleapis.com/applied-dl/heart.csv'
dataframe = pd.read_csv(URL)
dataframe.head()
将 dataframe 拆分为训练、验证和测试集
我们下载的数据集是一个 CSV 文件。 我们将其拆分为训练、验证和测试集。
train, test = train_test_split(dataframe, test_size=0.2)
train, val = train_test_split(train, test_size=0.2)
print(len(train), 'train examples')
print(len(val), 'validation examples')
print(len(test), 'test examples')
193 train examples 49 validation examples 61 test examples
用 tf.data 创建输入流水线
接下来,我们将使用 tf.data 包装 dataframe。这让我们能将特征列作为一座桥梁,该桥梁将 Pandas dataframe 中的列映射到用于训练模型的特征。如果我们使用一个非常大的 CSV 文件(非常大以至于它不能放入内存),我们将使用 tf.data 直接从磁盘读取它。本教程不涉及这一点。
# 一种从 Pandas Dataframe 创建 tf.data 数据集的实用程序方法(utility method)
def df_to_dataset(dataframe, shuffle=True, batch_size=32):
dataframe = dataframe.copy()
labels = dataframe.pop('target')
ds = tf.data.Dataset.from_tensor_slices((dict(dataframe), labels))
if shuffle:
ds = ds.shuffle(buffer_size=len(dataframe))
ds = ds.batch(batch_size)
return ds
batch_size = 5 # 小批量大小用于演示
train_ds = df_to_dataset(train, batch_size=batch_size)
val_ds = df_to_dataset(val, shuffle=False, batch_size=batch_size)
test_ds = df_to_dataset(test, shuffle=False, batch_size=batch_size)
理解输入流水线
现在我们已经创建了输入流水线,让我们调用它来查看它返回的数据的格式。 我们使用了一小批量大小来保持输出的可读性。
for feature_batch, label_batch in train_ds.take(1):
print('Every feature:', list(feature_batch.keys()))
print('A batch of ages:', feature_batch['age'])
print('A batch of targets:', label_batch )
Every feature: ['age', 'sex', 'cp', 'trestbps', 'chol', 'fbs', 'restecg', 'thalach', 'exang', 'oldpeak', 'slope', 'ca', 'thal'] A batch of ages: tf.Tensor([58 44 44 50 54], shape=(5,), dtype=int64) A batch of targets: tf.Tensor([0 1 0 0 1], shape=(5,), dtype=int64)
我们可以看到数据集返回了一个字典,该字典从列名称(来自 dataframe)映射到 dataframe 中行的列值。
演示几种特征列
TensorFlow 提供了多种特征列。本节中,我们将创建几类特征列,并演示特征列如何转换 dataframe 中的列。
# 我们将使用该批数据演示几种特征列
example_batch = next(iter(train_ds))[0]
# 用于创建一个特征列
# 并转换一批次数据的一个实用程序方法
def demo(feature_column):
feature_layer = layers.DenseFeatures(feature_column)
print(feature_layer(example_batch).numpy())
数值列
一个特征列的输出将成为模型的输入(使用上面定义的 demo 函数,我们将能准确地看到 dataframe 中的每列的转换方式)。 数值列(numeric column) 是最简单的列类型。它用于表示实数特征。使用此列时,模型将从 dataframe 中接收未更改的列值。
age = feature_column.numeric_column("age")
demo(age)
WARNING:tensorflow:Layer dense_features is casting an input tensor from dtype float64 to the layer's dtype of float32, which is new behavior in TensorFlow 2. The layer has dtype float32 because its dtype defaults to floatx. If you intended to run this layer in float32, you can safely ignore this warning. If in doubt, this warning is likely only an issue if you are porting a TensorFlow 1.X model to TensorFlow 2. To change all layers to have dtype float64 by default, call `tf.keras.backend.set_floatx('float64')`. To change just this layer, pass dtype='float64' to the layer constructor. If you are the author of this layer, you can disable autocasting by passing autocast=False to the base Layer constructor. [[63.] [62.] [59.] [74.] [68.]]
在这个心脏病数据集中,dataframe 中的大多数列都是数值列。
分桶列
通常,您不希望将数字直接输入模型,而是根据数值范围将其值分成不同的类别。考虑代表一个人年龄的原始数据。我们可以用 分桶列(bucketized column)将年龄分成几个分桶(buckets),而不是将年龄表示成数值列。请注意下面的 one-hot 数值表示每行匹配的年龄范围。
age_buckets = feature_column.bucketized_column(age, boundaries=[18, 25, 30, 35, 40, 45, 50, 55, 60, 65])
demo(age_buckets)
WARNING:tensorflow:Layer dense_features_1 is casting an input tensor from dtype float64 to the layer's dtype of float32, which is new behavior in TensorFlow 2. The layer has dtype float32 because its dtype defaults to floatx. If you intended to run this layer in float32, you can safely ignore this warning. If in doubt, this warning is likely only an issue if you are porting a TensorFlow 1.X model to TensorFlow 2. To change all layers to have dtype float64 by default, call `tf.keras.backend.set_floatx('float64')`. To change just this layer, pass dtype='float64' to the layer constructor. If you are the author of this layer, you can disable autocasting by passing autocast=False to the base Layer constructor. [[0. 0. 0. 0. 0. 0. 0. 0. 0. 1. 0.] [0. 0. 0. 0. 0. 0. 0. 0. 0. 1. 0.] [0. 0. 0. 0. 0. 0. 0. 0. 1. 0. 0.] [0. 0. 0. 0. 0. 0. 0. 0. 0. 0. 1.] [0. 0. 0. 0. 0. 0. 0. 0. 0. 0. 1.]]
分类列
在此数据集中,thal 用字符串表示(如 'fixed','normal',或 'reversible')。我们无法直接将字符串提供给模型。相反,我们必须首先将它们映射到数值。分类词汇列(categorical vocabulary columns)提供了一种用 one-hot 向量表示字符串的方法(就像您在上面看到的年龄分桶一样)。词汇表可以用 categorical_column_with_vocabulary_list 作为 list 传递,或者用 categorical_column_with_vocabulary_file 从文件中加载。
thal = feature_column.categorical_column_with_vocabulary_list(
'thal', ['fixed', 'normal', 'reversible'])
thal_one_hot = feature_column.indicator_column(thal)
demo(thal_one_hot)
WARNING:tensorflow:Layer dense_features_2 is casting an input tensor from dtype float64 to the layer's dtype of float32, which is new behavior in TensorFlow 2. The layer has dtype float32 because its dtype defaults to floatx. If you intended to run this layer in float32, you can safely ignore this warning. If in doubt, this warning is likely only an issue if you are porting a TensorFlow 1.X model to TensorFlow 2. To change all layers to have dtype float64 by default, call `tf.keras.backend.set_floatx('float64')`. To change just this layer, pass dtype='float64' to the layer constructor. If you are the author of this layer, you can disable autocasting by passing autocast=False to the base Layer constructor. [[0. 0. 1.] [0. 0. 1.] [1. 0. 0.] [0. 1. 0.] [0. 0. 1.]]
在更复杂的数据集中,许多列都是分类列(如 strings)。在处理分类数据时,特征列最有价值。尽管在该数据集中只有一列分类列,但我们将使用它来演示在处理其他数据集时,可以使用的几种重要的特征列。
嵌入列
假设我们不是只有几个可能的字符串,而是每个类别有数千(或更多)值。 由于多种原因,随着类别数量的增加,使用 one-hot 编码训练神经网络变得不可行。我们可以使用嵌入列来克服此限制。嵌入列(embedding column)将数据表示为一个低维度密集向量,而非多维的 one-hot 向量,该低维度密集向量可以包含任何数,而不仅仅是 0 或 1。嵌入的大小(在下面的示例中为 8)是必须调整的参数。
关键点:当分类列具有许多可能的值时,最好使用嵌入列。我们在这里使用嵌入列用于演示目的,为此您有一个完整的示例,以在将来可以修改用于其他数据集。
# 注意到嵌入列的输入是我们之前创建的类别列
thal_embedding = feature_column.embedding_column(thal, dimension=8)
demo(thal_embedding)
WARNING:tensorflow:Layer dense_features_3 is casting an input tensor from dtype float64 to the layer's dtype of float32, which is new behavior in TensorFlow 2. The layer has dtype float32 because its dtype defaults to floatx. If you intended to run this layer in float32, you can safely ignore this warning. If in doubt, this warning is likely only an issue if you are porting a TensorFlow 1.X model to TensorFlow 2. To change all layers to have dtype float64 by default, call `tf.keras.backend.set_floatx('float64')`. To change just this layer, pass dtype='float64' to the layer constructor. If you are the author of this layer, you can disable autocasting by passing autocast=False to the base Layer constructor. [[ 0.00543996 -0.5059579 0.0389499 -0.20236802 0.11128058 0.59121 0.14891742 -0.11942385] [ 0.00543996 -0.5059579 0.0389499 -0.20236802 0.11128058 0.59121 0.14891742 -0.11942385] [ 0.09787773 -0.5861865 -0.3713007 -0.1747458 -0.01538717 0.55458224 0.12537968 -0.11748305] [-0.00701649 0.28291813 0.23547529 -0.5102454 -0.5388726 0.5154376 0.12235989 0.44484815] [ 0.00543996 -0.5059579 0.0389499 -0.20236802 0.11128058 0.59121 0.14891742 -0.11942385]]
经过哈希处理的特征列
表示具有大量数值的分类列的另一种方法是使用 categorical_column_with_hash_bucket。该特征列计算输入的一个哈希值,然后选择一个 hash_bucket_size
分桶来编码字符串。使用此列时,您不需要提供词汇表,并且可以选择使 hash_buckets 的数量远远小于实际类别的数量以节省空间。
关键点:该技术的一个重要缺点是可能存在冲突,不同的字符串被映射到同一个范围。实际上,无论如何,经过哈希处理的特征列对某些数据集都有效。
thal_hashed = feature_column.categorical_column_with_hash_bucket(
'thal', hash_bucket_size=1000)
demo(feature_column.indicator_column(thal_hashed))
WARNING:tensorflow:Layer dense_features_4 is casting an input tensor from dtype float64 to the layer's dtype of float32, which is new behavior in TensorFlow 2. The layer has dtype float32 because its dtype defaults to floatx. If you intended to run this layer in float32, you can safely ignore this warning. If in doubt, this warning is likely only an issue if you are porting a TensorFlow 1.X model to TensorFlow 2. To change all layers to have dtype float64 by default, call `tf.keras.backend.set_floatx('float64')`. To change just this layer, pass dtype='float64' to the layer constructor. If you are the author of this layer, you can disable autocasting by passing autocast=False to the base Layer constructor. [[0. 0. 0. ... 0. 0. 0.] [0. 0. 0. ... 0. 0. 0.] [0. 0. 0. ... 0. 0. 0.] [0. 0. 0. ... 0. 0. 0.] [0. 0. 0. ... 0. 0. 0.]]
组合的特征列
将多种特征组合到一个特征中,称为特征组合(feature crosses),它让模型能够为每种特征组合学习单独的权重。此处,我们将创建一个 age 和 thal 组合的新特征。请注意,crossed_column
不会构建所有可能组合的完整列表(可能非常大)。相反,它由 hashed_column
支持,因此您可以选择表的大小。
crossed_feature = feature_column.crossed_column([age_buckets, thal], hash_bucket_size=1000)
demo(feature_column.indicator_column(crossed_feature))
WARNING:tensorflow:Layer dense_features_5 is casting an input tensor from dtype float64 to the layer's dtype of float32, which is new behavior in TensorFlow 2. The layer has dtype float32 because its dtype defaults to floatx. If you intended to run this layer in float32, you can safely ignore this warning. If in doubt, this warning is likely only an issue if you are porting a TensorFlow 1.X model to TensorFlow 2. To change all layers to have dtype float64 by default, call `tf.keras.backend.set_floatx('float64')`. To change just this layer, pass dtype='float64' to the layer constructor. If you are the author of this layer, you can disable autocasting by passing autocast=False to the base Layer constructor. [[0. 0. 0. ... 0. 0. 0.] [0. 0. 0. ... 0. 0. 0.] [0. 0. 0. ... 0. 0. 0.] [0. 0. 0. ... 0. 0. 0.] [0. 0. 0. ... 0. 0. 0.]]
选择要使用的列
我们已经了解了如何使用几种类型的特征列。 现在我们将使用它们来训练模型。本教程的目标是向您展示使用特征列所需的完整代码(例如,机制)。我们任意地选择了几列来训练我们的模型。
关键点:如果您的目标是建立一个准确的模型,请尝试使用您自己的更大的数据集,并仔细考虑哪些特征最有意义,以及如何表示它们。
feature_columns = []
# 数值列
for header in ['age', 'trestbps', 'chol', 'thalach', 'oldpeak', 'slope', 'ca']:
feature_columns.append(feature_column.numeric_column(header))
# 分桶列
age_buckets = feature_column.bucketized_column(age, boundaries=[18, 25, 30, 35, 40, 45, 50, 55, 60, 65])
feature_columns.append(age_buckets)
# 分类列
thal = feature_column.categorical_column_with_vocabulary_list(
'thal', ['fixed', 'normal', 'reversible'])
thal_one_hot = feature_column.indicator_column(thal)
feature_columns.append(thal_one_hot)
# 嵌入列
thal_embedding = feature_column.embedding_column(thal, dimension=8)
feature_columns.append(thal_embedding)
# 组合列
crossed_feature = feature_column.crossed_column([age_buckets, thal], hash_bucket_size=1000)
crossed_feature = feature_column.indicator_column(crossed_feature)
feature_columns.append(crossed_feature)
建立一个新的特征层
现在我们已经定义了我们的特征列,我们将使用密集特征(DenseFeatures)层将特征列输入到我们的 Keras 模型中。
feature_layer = tf.keras.layers.DenseFeatures(feature_columns)
之前,我们使用一个小批量大小来演示特征列如何运转。我们将创建一个新的更大批量的输入流水线。
batch_size = 32
train_ds = df_to_dataset(train, batch_size=batch_size)
val_ds = df_to_dataset(val, shuffle=False, batch_size=batch_size)
test_ds = df_to_dataset(test, shuffle=False, batch_size=batch_size)
创建,编译和训练模型
model = tf.keras.Sequential([
feature_layer,
layers.Dense(128, activation='relu'),
layers.Dense(128, activation='relu'),
layers.Dense(1, activation='sigmoid')
])
model.compile(optimizer='adam',
loss='binary_crossentropy',
metrics=['accuracy'],
run_eagerly=True)
model.fit(train_ds,
validation_data=val_ds,
epochs=5)
Epoch 1/5 WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[57], [45], [49], [67], [54], [70], [54], [52], [52], [44], [57], [43], [62], [59], [62], [58], [42], [68], [56], [46], [44], [40], [52], [63], [57], [56], [37], [64], [43], [34], [57], [51]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [0], [0], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [0], [1], [1], [1], [1], [0], [0], [1], [1], [1], [0], [1], [1], [0]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [4], [2], [4], [3], [3], [3], [4], [4], [4], [2], [4], [3], [1], [4], [2], [4], [3], [4], [2], [2], [1], [2], [4], [4], [4], [3], [1], [3], [1], [2], [3]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[128], [138], [134], [106], [110], [160], [150], [112], [125], [112], [154], [150], [130], [170], [120], [120], [136], [118], [200], [101], [120], [140], [120], [124], [128], [125], [130], [110], [122], [118], [124], [140]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[229], [236], [271], [223], [214], [269], [232], [230], [212], [290], [232], [247], [231], [288], [267], [284], [315], [277], [288], [197], [263], [199], [325], [197], [303], [249], [250], [211], [213], [182], [261], [308]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [1], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [2], [0], [0], [0], [0], [2], [0], [0], [2], [2], [0], [0], [2], [0], [2], [0], [0], [2], [0], [0], [0], [0], [0], [2], [2], [0], [2], [0], [2], [0], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[150], [152], [162], [142], [158], [112], [165], [160], [168], [153], [164], [171], [146], [159], [ 99], [160], [125], [151], [133], [156], [173], [178], [172], [136], [159], [144], [187], [144], [165], [174], [141], [142]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [1], [0], [1], [0], [0], [1], [0], [1], [0], [1], [0], [1], [0], [0], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[0.4], [0.2], [0. ], [0.3], [1.6], [2.9], [1.6], [0. ], [1. ], [0. ], [0. ], [1.5], [1.8], [0.2], [1.8], [1.8], [1.8], [1. ], [4. ], [0. ], [0. ], [1.4], [0.2], [0. ], [0. ], [1.2], [3.5], [1.8], [0.2], [0. ], [0.3], [1.5]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [2], [2], [1], [2], [2], [1], [1], [1], [1], [1], [1], [2], [2], [2], [2], [2], [1], [3], [1], [1], [1], [1], [2], [1], [2], [3], [2], [2], [1], [1], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [2], [0], [1], [0], [1], [2], [1], [1], [0], [3], [0], [2], [0], [0], [1], [2], [0], [0], [0], [0], [0], [1], [1], [0], [0], [0], [0], [0], [1]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'reversible'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layer dense_features_6 is casting an input tensor from dtype float64 to the layer's dtype of float32, which is new behavior in TensorFlow 2. The layer has dtype float32 because its dtype defaults to floatx. If you intended to run this layer in float32, you can safely ignore this warning. If in doubt, this warning is likely only an issue if you are porting a TensorFlow 1.X model to TensorFlow 2. To change all layers to have dtype float64 by default, call `tf.keras.backend.set_floatx('float64')`. To change just this layer, pass dtype='float64' to the layer constructor. If you are the author of this layer, you can disable autocasting by passing autocast=False to the base Layer constructor. 1/7 [===>..........................] - ETA: 0s - loss: 1.9156 - accuracy: 0.8438WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[64], [62], [57], [64], [70], [54], [64], [67], [61], [56], [41], [42], [50], [47], [58], [60], [41], [57], [55], [42], [50], [44], [58], [67], [66], [37], [45], [67], [62], [59], [56], [66]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [0], [1], [1], [1], [1], [1], [1], [1], [0], [1], [1], [1], [1], [1], [1], [1], [0], [1], [0], [1], [1], [1], [1], [0], [1], [0], [1], [1], [0], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [2], [4], [1], [4], [4], [4], [4], [4], [1], [2], [3], [4], [3], [4], [4], [2], [4], [2], [1], [4], [2], [3], [4], [4], [3], [4], [3], [2], [3], [2], [4]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[125], [128], [120], [170], [130], [122], [145], [100], [138], [120], [126], [120], [144], [138], [114], [130], [135], [150], [132], [148], [110], [120], [105], [160], [160], [120], [104], [152], [120], [126], [140], [120]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[309], [208], [354], [227], [322], [286], [212], [299], [166], [193], [306], [240], [200], [257], [318], [253], [203], [276], [342], [244], [254], [220], [240], [286], [228], [215], [208], [277], [281], [218], [294], [302]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [2], [0], [2], [2], [2], [2], [2], [2], [2], [0], [0], [2], [2], [1], [0], [0], [2], [0], [2], [2], [0], [2], [2], [2], [0], [2], [0], [2], [0], [2], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[131], [140], [163], [155], [109], [116], [132], [125], [125], [162], [163], [194], [126], [156], [140], [144], [132], [112], [166], [178], [159], [170], [154], [108], [138], [170], [148], [172], [103], [134], [153], [151]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [1], [0], [0], [1], [0], [1], [1], [0], [0], [0], [1], [0], [0], [1], [0], [1], [0], [0], [0], [0], [1], [1], [0], [0], [1], [0], [0], [0], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[1.8], [0. ], [0.6], [0.6], [2.4], [3.2], [2. ], [0.9], [3.6], [1.9], [0. ], [0.8], [0.9], [0. ], [4.4], [1.4], [0. ], [0.6], [1.2], [0.8], [0. ], [0. ], [0.6], [1.5], [2.3], [0. ], [3. ], [0. ], [1.4], [2.2], [1.3], [0.4]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [1], [1], [2], [2], [2], [2], [2], [2], [2], [1], [3], [2], [1], [3], [1], [2], [2], [1], [1], [1], [1], [2], [2], [1], [1], [2], [1], [2], [2], [2], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [3], [2], [2], [2], [1], [0], [0], [0], [0], [0], [3], [1], [0], [1], [0], [2], [0], [0], [0], [3], [0], [0], [0], [1], [1], [1], [0], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'fixed'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'fixed'], [b'fixed'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'fixed'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'fixed'], [b'normal'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[63], [43], [52], [54], [65], [45], [44], [34], [40], [51], [64], [47], [54], [63], [60], [54], [41], [53], [56], [54], [57], [59], [43], [67], [68], [53], [44], [58], [46], [59], [47], [53]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [1], [0], [0], [1], [1], [0], [1], [1], [0], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [0], [1], [0], [1], [1], [0], [1], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [4], [4], [3], [3], [4], [3], [2], [4], [4], [3], [4], [4], [4], [4], [2], [2], [4], [4], [4], [3], [4], [3], [3], [4], [4], [3], [4], [3], [0], [3], [4]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[140], [120], [128], [135], [140], [142], [140], [118], [110], [140], [140], [112], [124], [130], [117], [108], [110], [123], [130], [140], [150], [110], [130], [115], [144], [130], [130], [128], [142], [164], [108], [142]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[187], [177], [255], [304], [417], [309], [235], [210], [167], [298], [313], [204], [266], [254], [230], [309], [235], [282], [283], [239], [168], [239], [315], [564], [193], [264], [233], [216], [177], [176], [243], [226]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [1], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [1], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [1], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [2], [0], [0], [2], [2], [2], [0], [2], [0], [0], [0], [2], [2], [0], [0], [0], [0], [2], [0], [0], [2], [0], [2], [0], [2], [0], [2], [2], [0], [0], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[144], [120], [161], [170], [157], [147], [180], [192], [114], [122], [133], [143], [109], [147], [160], [156], [153], [ 95], [103], [160], [174], [142], [162], [160], [141], [143], [179], [131], [160], [ 90], [152], [111]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [1], [0], [0], [1], [0], [0], [1], [1], [0], [0], [1], [0], [1], [0], [0], [1], [1], [0], [0], [1], [0], [0], [0], [0], [1], [1], [1], [0], [0], [1]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[4. ], [2.5], [0. ], [0. ], [0.8], [0. ], [0. ], [0.7], [2. ], [4.2], [0.2], [0.1], [2.2], [1.4], [1.4], [0. ], [0. ], [2. ], [1.6], [1.2], [1.6], [1.2], [1.9], [1.6], [3.4], [0.4], [0.4], [2.2], [1.4], [1. ], [0. ], [0. ]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [2], [1], [1], [1], [2], [1], [1], [2], [2], [1], [1], [2], [2], [1], [1], [1], [2], [3], [1], [1], [2], [1], [2], [2], [2], [1], [2], [3], [1], [1], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [0], [1], [0], [1], [3], [0], [0], [0], [3], [0], [0], [1], [1], [2], [0], [0], [2], [0], [0], [0], [1], [1], [0], [2], [0], [0], [3], [0], [2], [0], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'1'], [b'normal'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. 3/7 [===========>..................] - ETA: 0s - loss: 2.4590 - accuracy: 0.6354WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[71], [61], [41], [48], [54], [51], [43], [50], [52], [57], [59], [67], [56], [45], [42], [49], [44], [54], [50], [56], [47], [60], [61], [55], [57], [58], [46], [49], [46], [55], [68], [39]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [0], [1], [1], [0], [1], [1], [1], [1], [1], [1], [0], [1], [1], [1], [1], [1], [1], [0], [0], [0]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [4], [3], [4], [4], [3], [4], [3], [2], [4], [3], [4], [4], [1], [3], [4], [2], [4], [3], [4], [3], [4], [4], [4], [4], [4], [3], [3], [4], [4], [3], [3]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[160], [148], [130], [122], [120], [125], [110], [129], [134], [165], [150], [120], [134], [110], [130], [130], [130], [110], [140], [132], [130], [140], [130], [140], [152], [100], [150], [120], [140], [180], [120], [ 94]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[302], [203], [214], [222], [188], [245], [211], [196], [201], [289], [212], [237], [409], [264], [180], [269], [219], [206], [233], [184], [253], [293], [330], [217], [274], [234], [231], [188], [311], [327], [211], [199]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [1], [0], [0], [0], [1], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [2], [2], [0], [2], [0], [0], [0], [2], [0], [0], [2], [0], [0], [0], [2], [2], [0], [2], [0], [2], [2], [0], [0], [0], [0], [0], [0], [1], [2], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[162], [161], [168], [186], [113], [166], [161], [163], [158], [124], [157], [ 71], [150], [132], [150], [163], [188], [108], [163], [105], [179], [170], [169], [111], [ 88], [156], [147], [139], [120], [117], [115], [179]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [1], [0], [1], [0], [0], [0], [1], [1], [0], [0], [0], [1], [1], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[0.4], [0. ], [2. ], [0. ], [1.4], [2.4], [0. ], [0. ], [0.8], [1. ], [1.6], [1. ], [1.9], [1.2], [0. ], [0. ], [0. ], [0. ], [0.6], [2.1], [0. ], [1.2], [0. ], [5.6], [1.2], [0.1], [3.6], [2. ], [1.8], [3.4], [1.5], [0. ]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [2], [1], [2], [2], [1], [1], [1], [2], [1], [2], [2], [2], [1], [1], [1], [2], [2], [2], [1], [2], [1], [3], [2], [1], [2], [2], [2], [2], [2], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [1], [0], [0], [1], [0], [0], [0], [1], [3], [0], [0], [2], [0], [0], [0], [0], [1], [1], [1], [0], [2], [0], [0], [1], [1], [0], [3], [2], [0], [0], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'fixed'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[58], [51], [54], [51], [50], [66], [53], [46], [46], [42], [58], [29], [43], [60], [57], [35], [74], [65], [41], [45], [58], [56], [58], [57], [45], [51], [64], [44], [50], [59], [67], [50]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [0], [0], [1], [1], [0], [1], [0], [1], [1], [1], [0], [1], [1], [0], [1], [1], [0], [0], [1], [1], [1], [1], [0], [1], [1], [1], [0], [1], [0]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [1], [4], [3], [2], [2], [3], [4], [4], [4], [3], [2], [4], [4], [4], [4], [2], [1], [3], [2], [1], [2], [4], [4], [4], [4], [3], [4], [4], [4], [4], [3]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[100], [125], [110], [130], [120], [160], [130], [138], [120], [102], [132], [130], [115], [150], [110], [126], [120], [138], [112], [112], [150], [120], [128], [140], [115], [130], [140], [120], [150], [174], [125], [120]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[248], [213], [239], [256], [244], [246], [246], [243], [249], [265], [224], [204], [303], [258], [335], [282], [269], [282], [250], [160], [283], [240], [259], [192], [260], [305], [335], [169], [243], [249], [254], [219]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [2], [0], [2], [0], [0], [2], [2], [2], [2], [2], [2], [0], [2], [0], [2], [2], [2], [0], [0], [2], [0], [2], [0], [2], [0], [0], [0], [2], [0], [0], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[122], [125], [126], [149], [162], [120], [173], [152], [144], [122], [173], [202], [181], [157], [143], [156], [121], [174], [179], [138], [162], [169], [130], [148], [185], [142], [158], [144], [128], [143], [163], [158]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [0], [0], [1], [0], [1], [0], [0], [0], [0], [0], [0], [1], [1], [1], [0], [0], [0], [0], [0], [1], [0], [0], [1], [0], [1], [0], [1], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[1. ], [1.4], [2.8], [0.5], [1.1], [0. ], [0. ], [0. ], [0.8], [0.6], [3.2], [0. ], [1.2], [2.6], [3. ], [0. ], [0.2], [1.4], [0. ], [0. ], [1. ], [0. ], [3. ], [0.4], [0. ], [1.2], [0. ], [2.8], [2.6], [0. ], [0.2], [1.6]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [1], [2], [1], [1], [2], [1], [2], [1], [2], [1], [1], [2], [2], [2], [1], [1], [2], [1], [2], [1], [3], [2], [2], [1], [2], [1], [3], [2], [2], [2], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [0], [0], [3], [3], [0], [0], [0], [2], [0], [0], [2], [1], [0], [1], [1], [0], [0], [0], [0], [2], [0], [0], [0], [0], [0], [0], [0], [2], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'fixed'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'fixed'], [b'normal'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. 5/7 [====================>.........] - ETA: 0s - loss: 2.0828 - accuracy: 0.5938WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[43], [55], [44], [58], [48], [62], [62], [52], [58], [60], [38], [42], [57], [69], [57], [57], [55], [63], [49], [63], [60], [59], [64], [59], [68], [62], [59], [62], [42], [53], [59], [64]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [0], [1], [1], [0], [0], [1], [0], [1], [1], [1], [1], [1], [1], [0], [0], [1], [1], [0], [0], [1], [0], [1], [1], [0], [1], [0], [1], [1], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [4], [3], [4], [2], [4], [3], [1], [2], [4], [1], [4], [4], [1], [3], [2], [4], [4], [2], [3], [3], [1], [4], [1], [0], [4], [4], [4], [2], [3], [4], [4]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[132], [132], [118], [150], [110], [140], [130], [118], [136], [145], [120], [140], [132], [160], [150], [130], [128], [130], [130], [135], [102], [134], [180], [178], [144], [150], [164], [140], [120], [130], [138], [128]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[341], [353], [242], [270], [229], [394], [263], [186], [319], [282], [231], [226], [207], [234], [126], [236], [205], [330], [266], [252], [318], [204], [325], [270], [193], [244], [176], [268], [295], [197], [271], [263]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [1], [1], [0], [0], [1], [0], [0], [0], [0], [0], [0], [1], [0], [1], [0], [0], [1], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [0], [0], [2], [0], [2], [0], [2], [2], [2], [0], [0], [0], [2], [0], [2], [1], [2], [0], [2], [0], [0], [0], [2], [1], [0], [2], [2], [0], [2], [2], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[136], [132], [149], [111], [168], [157], [ 97], [190], [152], [142], [182], [178], [168], [131], [173], [174], [130], [132], [171], [172], [160], [162], [154], [145], [141], [154], [ 90], [160], [162], [152], [182], [105]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [0], [1], [0], [0], [0], [0], [0], [1], [1], [0], [1], [0], [0], [0], [1], [1], [0], [0], [0], [0], [1], [0], [0], [1], [0], [0], [0], [0], [0], [1]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[3. ], [1.2], [0.3], [0.8], [1. ], [1.2], [1.2], [0. ], [0. ], [2.8], [3.8], [0. ], [0. ], [0.1], [0.2], [0. ], [2. ], [1.8], [0.6], [0. ], [0. ], [0.8], [0. ], [4.2], [3.4], [1.4], [1. ], [3.6], [0. ], [1.2], [0. ], [0.2]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [2], [2], [1], [3], [2], [2], [2], [1], [2], [2], [1], [1], [2], [1], [2], [2], [1], [1], [1], [1], [1], [1], [3], [1], [2], [2], [3], [1], [3], [1], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [0], [0], [0], [1], [0], [2], [2], [0], [0], [0], [1], [1], [1], [1], [3], [0], [0], [1], [2], [0], [0], [2], [0], [2], [2], [0], [0], [0], [1]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'fixed'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'fixed'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[51]])>, 'sex': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[1]])>, 'cp': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[3]])>, 'trestbps': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[110]])>, 'chol': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[175]])>, 'fbs': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[0]])>, 'restecg': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[0]])>, 'thalach': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[123]])>, 'exang': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[0]])>, 'oldpeak': <tf.Tensor: shape=(1, 1), dtype=float64, numpy=array([[0.6]])>, 'slope': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[1]])>, 'ca': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[0]])>, 'thal': <tf.Tensor: shape=(1, 1), dtype=string, numpy=array([[b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. 7/7 [==============================] - ETA: 0s - loss: 2.0670 - accuracy: 0.6062WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[62], [65], [60], [35], [48], [66], [42], [44], [67], [71], [45], [65], [52], [76], [48], [51], [61], [51], [66], [51], [60], [52], [49], [57], [54], [68], [41], [62], [59], [45], [59], [55]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [1], [1], [1], [0], [0], [1], [0], [1], [1], [1], [0], [1], [1], [1], [1], [0], [1], [0], [1], [1], [1], [1], [1], [0], [0], [1], [0], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [4], [3], [2], [4], [4], [3], [3], [3], [3], [2], [4], [1], [3], [3], [4], [3], [3], [4], [4], [3], [3], [3], [4], [3], [3], [2], [4], [4], [2], [4], [4]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[124], [120], [140], [122], [124], [112], [120], [108], [152], [110], [128], [110], [152], [140], [124], [140], [150], [100], [178], [140], [120], [172], [118], [110], [120], [180], [105], [138], [140], [130], [135], [160]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[209], [177], [185], [192], [274], [212], [209], [141], [212], [265], [308], [248], [298], [197], [255], [299], [243], [222], [228], [261], [178], [199], [149], [201], [258], [274], [198], [294], [177], [234], [234], [289]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [1], [0], [1], [0], [1], [0], [1], [0], [1], [1], [0], [0], [0], [1], [0], [1], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [2], [0], [2], [2], [0], [0], [2], [2], [2], [2], [0], [1], [0], [0], [0], [0], [0], [2], [0], [0], [2], [0], [2], [2], [0], [0], [0], [2], [0], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[163], [140], [155], [174], [166], [132], [173], [175], [150], [130], [170], [158], [178], [116], [175], [173], [137], [143], [165], [186], [ 96], [162], [126], [126], [147], [150], [168], [106], [162], [175], [161], [145]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [1], [1], [1], [1], [0], [0], [0], [1], [0], [1], [0], [0], [1], [0], [0], [1]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[0. ], [0.4], [3. ], [0. ], [0.5], [0.1], [0. ], [0.6], [0.8], [0. ], [0. ], [0.6], [1.2], [1.1], [0. ], [1.6], [1. ], [1.2], [1. ], [0. ], [0. ], [0.5], [0.8], [1.5], [0.4], [1.6], [0. ], [1.9], [0. ], [0.6], [0.5], [0.8]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [2], [1], [2], [1], [2], [2], [2], [1], [1], [1], [2], [2], [1], [1], [2], [2], [2], [1], [1], [1], [1], [2], [2], [2], [1], [2], [1], [2], [2], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [1], [0], [0], [0], [1], [0], [2], [0], [0], [2], [0], [0], [0], [2], [0], [0], [0], [3], [0], [0], [0], [1], [3], [1], [0], [0], [1]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[77], [39], [60], [41], [56], [51], [59], [41], [60], [64], [64], [70], [62], [58], [58], [67], [35]])>, 'sex': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[1], [1], [1], [0], [1], [1], [1], [1], [1], [0], [1], [1], [0], [1], [0], [1], [0]])>, 'cp': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[4], [4], [4], [2], [3], [3], [2], [2], [4], [4], [4], [2], [4], [4], [4], [4], [4]])>, 'trestbps': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[125], [118], [130], [130], [130], [ 94], [140], [120], [125], [130], [120], [156], [160], [125], [130], [120], [138]])>, 'chol': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[304], [219], [206], [204], [256], [227], [221], [157], [258], [303], [246], [245], [164], [300], [197], [229], [183]])>, 'fbs': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[2], [0], [2], [2], [2], [0], [0], [0], [2], [0], [2], [2], [2], [2], [0], [2], [0]])>, 'thalach': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[162], [140], [132], [172], [142], [154], [164], [182], [141], [122], [ 96], [143], [145], [171], [131], [129], [182]])>, 'exang': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[1], [0], [1], [0], [1], [1], [1], [0], [1], [0], [1], [0], [0], [0], [0], [1], [0]])>, 'oldpeak': <tf.Tensor: shape=(17, 1), dtype=float64, numpy= array([[0. ], [1.2], [2.4], [1.4], [0.6], [0. ], [0. ], [0. ], [2.8], [2. ], [2.2], [0. ], [6.2], [0. ], [0.6], [2.6], [1.4]])>, 'slope': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[1], [2], [2], [1], [2], [1], [1], [1], [2], [2], [3], [1], [3], [1], [2], [2], [1]])>, 'ca': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[3], [0], [2], [0], [1], [1], [0], [0], [1], [2], [1], [0], [3], [2], [0], [2], [0]])>, 'thal': <tf.Tensor: shape=(17, 1), dtype=string, numpy= array([[b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. 7/7 [==============================] - 0s 44ms/step - loss: 2.0670 - accuracy: 0.6062 - val_loss: 1.8843 - val_accuracy: 0.7347 Epoch 2/5 WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[57], [56], [50], [52], [56], [61], [68], [34], [58], [50], [40], [51], [47], [35], [45], [64], [44], [44], [38], [57], [58], [51], [59], [43], [41], [55], [47], [56], [54], [43], [64], [57]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [1], [1], [1], [0], [1], [0], [1], [1], [1], [1], [1], [0], [0], [1], [1], [1], [1], [1], [0], [0], [1], [1], [0], [1], [1], [1], [1], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [4], [3], [1], [4], [4], [3], [1], [1], [3], [1], [3], [3], [4], [2], [4], [4], [2], [1], [3], [3], [3], [4], [4], [3], [4], [4], [4], [4], [4], [4], [4]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[140], [134], [120], [118], [130], [138], [120], [118], [150], [129], [140], [125], [108], [126], [112], [180], [112], [130], [120], [150], [132], [130], [174], [115], [130], [180], [112], [125], [120], [110], [145], [110]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[192], [409], [219], [186], [283], [166], [211], [182], [283], [196], [199], [245], [243], [282], [160], [325], [290], [219], [231], [168], [224], [256], [249], [303], [214], [327], [204], [249], [188], [211], [212], [335]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [1], [0], [0], [0], [1], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [2], [0], [2], [2], [2], [2], [2], [2], [0], [0], [2], [0], [2], [0], [0], [2], [2], [0], [0], [2], [2], [0], [0], [2], [1], [0], [2], [0], [0], [2], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[148], [150], [158], [190], [103], [125], [115], [174], [162], [163], [178], [166], [152], [156], [138], [154], [153], [188], [182], [174], [173], [149], [143], [181], [168], [117], [143], [144], [113], [161], [132], [143]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [0], [0], [1], [1], [0], [0], [0], [0], [1], [0], [0], [1], [0], [1], [0], [0], [1], [0], [0], [0], [1], [0], [0], [1], [0], [1], [0], [0], [0], [1]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[0.4], [1.9], [1.6], [0. ], [1.6], [3.6], [1.5], [0. ], [1. ], [0. ], [1.4], [2.4], [0. ], [0. ], [0. ], [0. ], [0. ], [0. ], [3.8], [1.6], [3.2], [0.5], [0. ], [1.2], [2. ], [3.4], [0.1], [1.2], [1.4], [0. ], [2. ], [3. ]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [2], [2], [2], [3], [2], [2], [1], [1], [1], [1], [2], [1], [1], [2], [1], [1], [1], [2], [1], [1], [1], [2], [2], [2], [2], [1], [2], [2], [1], [2], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [2], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [2], [0], [0], [0], [0], [0], [0], [1], [1], [0], [2], [1]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'fixed'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'fixed'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. 1/7 [===>..........................] - ETA: 0s - loss: 2.3728 - accuracy: 0.6875WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[53], [43], [49], [37], [60], [58], [41], [45], [40], [59], [63], [60], [42], [45], [49], [57], [67], [50], [58], [50], [51], [68], [44], [59], [55], [52], [54], [44], [43], [54], [58], [41]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [0], [0], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [0], [1], [1], [1], [1], [1], [1], [1], [0], [1], [1], [1], [0]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [4], [4], [3], [4], [4], [3], [1], [4], [3], [4], [4], [4], [4], [2], [2], [4], [3], [4], [2], [1], [3], [2], [4], [4], [2], [2], [3], [3], [4], [4], [2]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[123], [120], [130], [120], [130], [128], [112], [110], [110], [150], [140], [145], [140], [142], [130], [124], [120], [140], [128], [120], [125], [118], [120], [164], [132], [120], [108], [118], [130], [140], [150], [126]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[282], [177], [269], [215], [253], [216], [250], [264], [167], [212], [187], [282], [226], [309], [266], [261], [237], [233], [259], [244], [213], [277], [220], [176], [353], [325], [309], [242], [315], [239], [270], [306]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [2], [0], [0], [0], [2], [0], [0], [2], [0], [2], [2], [0], [2], [0], [0], [0], [0], [2], [0], [2], [0], [0], [2], [0], [0], [0], [0], [0], [0], [2], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[ 95], [120], [163], [170], [144], [131], [179], [132], [114], [157], [144], [142], [178], [147], [171], [141], [ 71], [163], [130], [162], [125], [151], [170], [ 90], [132], [172], [156], [149], [162], [160], [111], [163]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [0], [0], [1], [1], [0], [0], [1], [0], [1], [1], [0], [1], [0], [0], [0], [0], [1], [0], [1], [0], [0], [0], [1], [0], [0], [0], [0], [0], [1], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[2. ], [2.5], [0. ], [0. ], [1.4], [2.2], [0. ], [1.2], [2. ], [1.6], [4. ], [2.8], [0. ], [0. ], [0.6], [0.3], [1. ], [0.6], [3. ], [1.1], [1.4], [1. ], [0. ], [1. ], [1.2], [0.2], [0. ], [0.3], [1.9], [1.2], [0.8], [0. ]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [2], [1], [1], [1], [2], [1], [2], [2], [1], [1], [2], [1], [2], [1], [1], [2], [2], [2], [1], [1], [1], [1], [2], [2], [1], [1], [2], [1], [1], [1], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [0], [0], [0], [1], [3], [0], [0], [0], [0], [2], [2], [0], [3], [0], [0], [0], [1], [2], [0], [1], [1], [0], [2], [1], [0], [0], [1], [1], [0], [0], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[37], [44], [58], [54], [29], [56], [62], [62], [44], [57], [67], [50], [56], [56], [61], [51], [67], [58], [42], [66], [52], [57], [46], [48], [70], [65], [53], [60], [57], [34], [57], [50]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [1], [1], [1], [1], [0], [1], [1], [1], [0], [1], [1], [0], [0], [1], [0], [0], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [0], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [3], [2], [4], [2], [4], [4], [2], [3], [4], [4], [4], [1], [2], [4], [4], [3], [2], [1], [2], [4], [4], [4], [4], [3], [1], [4], [4], [4], [2], [4], [4]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[130], [140], [120], [110], [130], [132], [150], [120], [130], [132], [106], [144], [120], [140], [130], [140], [152], [136], [148], [160], [125], [152], [140], [122], [160], [138], [142], [140], [150], [118], [165], [150]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[250], [235], [284], [206], [204], [184], [244], [281], [233], [207], [223], [200], [193], [294], [330], [298], [277], [319], [244], [246], [212], [274], [311], [222], [269], [282], [226], [293], [276], [210], [289], [243]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [1], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [2], [2], [2], [2], [2], [0], [2], [0], [0], [0], [2], [2], [2], [2], [0], [0], [2], [2], [0], [0], [0], [0], [2], [0], [2], [2], [2], [2], [0], [2], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[187], [180], [160], [108], [202], [105], [154], [103], [179], [168], [142], [126], [162], [153], [169], [122], [172], [152], [178], [120], [168], [ 88], [120], [186], [112], [174], [111], [170], [112], [192], [124], [128]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [1], [0], [1], [1], [0], [1], [1], [0], [1], [0], [0], [0], [1], [0], [0], [0], [1], [0], [1], [1], [0], [1], [0], [1], [0], [1], [0], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[3.5], [0. ], [1.8], [0. ], [0. ], [2.1], [1.4], [1.4], [0.4], [0. ], [0.3], [0.9], [1.9], [1.3], [0. ], [4.2], [0. ], [0. ], [0.8], [0. ], [1. ], [1.2], [1.8], [0. ], [2.9], [1.4], [0. ], [1.2], [0.6], [0.7], [1. ], [2.6]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [1], [2], [2], [1], [2], [2], [2], [1], [1], [1], [2], [2], [2], [1], [2], [1], [1], [1], [2], [1], [2], [2], [1], [2], [2], [1], [2], [2], [1], [2], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [1], [0], [1], [0], [1], [0], [0], [2], [0], [0], [0], [0], [3], [1], [2], [2], [3], [2], [1], [2], [0], [1], [1], [0], [2], [1], [0], [3], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'fixed'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'fixed'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'fixed'], [b'normal'], [b'reversible'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. 3/7 [===========>..................] - ETA: 0s - loss: 2.1748 - accuracy: 0.6562WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[56], [58], [60], [54], [46], [67], [67], [53], [46], [49], [43], [54], [68], [43], [61], [59], [50], [62], [62], [54], [57], [45], [39], [74], [45], [63], [48], [68], [62], [64], [63], [58]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [0], [1], [1], [1], [1], [1], [0], [0], [0], [1], [1], [1], [1], [1], [0], [1], [1], [1], [1], [0], [0], [0], [1], [0], [1], [1], [0], [1], [0], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [4], [3], [4], [3], [4], [4], [3], [3], [2], [3], [4], [4], [4], [4], [1], [4], [4], [3], [3], [2], [4], [3], [2], [4], [3], [2], [0], [4], [3], [4], [3]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[200], [100], [102], [124], [150], [100], [160], [130], [142], [134], [122], [110], [144], [150], [148], [134], [110], [120], [130], [150], [154], [138], [ 94], [120], [104], [135], [110], [144], [140], [125], [124], [105]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[288], [234], [318], [266], [231], [299], [286], [246], [177], [271], [213], [239], [193], [247], [203], [204], [254], [267], [231], [232], [232], [236], [199], [269], [208], [252], [229], [193], [394], [309], [197], [240]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [0], [0], [2], [0], [2], [2], [2], [2], [0], [0], [0], [0], [0], [0], [0], [2], [0], [0], [2], [2], [2], [0], [2], [2], [2], [0], [1], [2], [0], [0], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[133], [156], [160], [109], [147], [125], [108], [173], [160], [162], [165], [126], [141], [171], [161], [162], [159], [ 99], [146], [165], [164], [152], [179], [121], [148], [172], [168], [141], [157], [131], [136], [154]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [1], [0], [1], [1], [0], [1], [0], [0], [1], [0], [0], [0], [0], [0], [1], [0], [0], [0], [1], [0], [1], [1], [0], [0], [0], [0], [1], [1], [1]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[4. ], [0.1], [0. ], [2.2], [3.6], [0.9], [1.5], [0. ], [1.4], [0. ], [0.2], [2.8], [3.4], [1.5], [0. ], [0.8], [0. ], [1.8], [1.8], [1.6], [0. ], [0.2], [0. ], [0.2], [3. ], [0. ], [1. ], [3.4], [1.2], [1.8], [0. ], [0.6]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [1], [1], [2], [2], [2], [2], [1], [3], [2], [2], [2], [2], [1], [1], [1], [1], [2], [2], [1], [1], [2], [1], [1], [2], [1], [3], [1], [2], [2], [2], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [1], [1], [1], [0], [2], [3], [3], [0], [0], [0], [1], [2], [0], [1], [2], [0], [2], [3], [0], [1], [0], [0], [1], [0], [0], [0], [2], [0], [0], [0], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[49], [65], [43], [42], [54], [42], [53], [57], [64], [67], [56], [66], [59], [52], [57], [42], [71], [64], [58], [55], [69], [52], [60], [59], [42], [51], [46], [53], [51], [55], [66], [64]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [1], [0], [1], [0], [0], [1], [0], [1], [1], [1], [1], [0], [1], [0], [1], [0], [0], [1], [1], [0], [1], [0], [0], [0], [1], [1], [1], [1], [0]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [3], [4], [2], [3], [3], [4], [2], [4], [3], [2], [4], [3], [4], [4], [4], [2], [1], [4], [2], [1], [4], [4], [0], [4], [4], [4], [3], [3], [4], [4], [3]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[120], [140], [132], [120], [110], [120], [130], [130], [128], [115], [120], [120], [126], [128], [120], [136], [160], [170], [100], [132], [160], [112], [150], [164], [102], [130], [138], [130], [110], [140], [160], [140]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[188], [417], [341], [295], [214], [240], [264], [236], [263], [564], [240], [302], [218], [255], [354], [315], [302], [227], [248], [342], [234], [230], [258], [176], [265], [305], [243], [197], [175], [217], [228], [313]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [0], [0], [1], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [1], [0], [0], [0], [1], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [2], [2], [0], [0], [0], [2], [2], [0], [2], [0], [2], [0], [0], [0], [0], [0], [2], [2], [0], [2], [0], [2], [0], [2], [0], [2], [2], [0], [0], [2], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[139], [157], [136], [162], [158], [194], [143], [174], [105], [160], [169], [151], [134], [161], [163], [125], [162], [155], [122], [166], [131], [160], [157], [ 90], [122], [142], [152], [152], [123], [111], [138], [133]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [1], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [1], [1], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [1], [0], [0], [1], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[2. ], [0.8], [3. ], [0. ], [1.6], [0.8], [0.4], [0. ], [0.2], [1.6], [0. ], [0.4], [2.2], [0. ], [0.6], [1.8], [0.4], [0.6], [1. ], [1.2], [0.1], [0. ], [2.6], [1. ], [0.6], [1.2], [0. ], [1.2], [0.6], [5.6], [2.3], [0.2]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [1], [2], [1], [2], [3], [2], [2], [2], [2], [3], [2], [2], [1], [1], [2], [1], [2], [2], [1], [2], [1], [2], [1], [2], [2], [2], [3], [1], [3], [1], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [1], [0], [0], [0], [0], [0], [1], [1], [0], [0], [0], [1], [1], [0], [0], [2], [0], [0], [0], [1], [1], [2], [2], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'fixed'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'1'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'fixed'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. 5/7 [====================>.........] - ETA: 0s - loss: 1.5868 - accuracy: 0.6313WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[46], [47], [57], [64], [41], [62], [62], [57], [59], [54], [60], [58], [70], [46], [57], [41], [64], [63], [59], [52], [42], [59], [55], [62], [59], [51], [63], [44], [47], [45], [67], [44]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [1], [1], [1], [0], [1], [1], [1], [1], [1], [1], [1], [1], [0], [1], [1], [1], [1], [1], [1], [1], [0], [0], [1], [0], [1], [1], [1], [1], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [3], [3], [3], [2], [4], [2], [3], [4], [4], [4], [4], [4], [4], [4], [2], [1], [4], [1], [2], [3], [4], [4], [3], [1], [3], [4], [4], [3], [4], [4], [2]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[101], [130], [150], [140], [135], [140], [128], [128], [110], [122], [117], [114], [130], [120], [128], [110], [110], [130], [170], [134], [130], [138], [128], [130], [178], [140], [130], [120], [138], [115], [125], [120]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[197], [253], [126], [335], [203], [268], [208], [229], [239], [286], [230], [318], [322], [249], [303], [235], [211], [254], [288], [201], [180], [271], [205], [263], [270], [308], [330], [169], [257], [260], [254], [263]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [1], [0], [0], [0], [1], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [1], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [2], [2], [2], [2], [2], [0], [1], [2], [2], [2], [0], [2], [2], [2], [0], [0], [2], [1], [0], [2], [2], [2], [0], [2], [2], [0], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[156], [179], [173], [158], [132], [160], [140], [150], [142], [116], [160], [140], [109], [144], [159], [153], [144], [147], [159], [158], [150], [182], [130], [ 97], [145], [142], [132], [144], [156], [185], [163], [173]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [1], [1], [1], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [1], [0], [0], [0], [1], [1], [0], [0], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[0. ], [0. ], [0.2], [0. ], [0. ], [3.6], [0. ], [0.4], [1.2], [3.2], [1.4], [4.4], [2.4], [0.8], [0. ], [0. ], [1.8], [1.4], [0.2], [0.8], [0. ], [0. ], [2. ], [1.2], [4.2], [1.5], [1.8], [2.8], [0. ], [0. ], [0.2], [0. ]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [1], [1], [2], [3], [1], [2], [2], [2], [1], [3], [2], [1], [1], [1], [2], [2], [2], [1], [1], [1], [2], [2], [3], [1], [1], [3], [1], [1], [2], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [1], [0], [0], [2], [0], [1], [1], [2], [2], [3], [3], [0], [1], [0], [0], [1], [0], [1], [0], [0], [1], [1], [0], [1], [3], [0], [0], [0], [2], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'fixed'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'fixed'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'fixed'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[54]])>, 'sex': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[0]])>, 'cp': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[3]])>, 'trestbps': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[135]])>, 'chol': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[304]])>, 'fbs': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[1]])>, 'restecg': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[0]])>, 'thalach': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[170]])>, 'exang': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[0]])>, 'oldpeak': <tf.Tensor: shape=(1, 1), dtype=float64, numpy=array([[0.]])>, 'slope': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[1]])>, 'ca': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[0]])>, 'thal': <tf.Tensor: shape=(1, 1), dtype=string, numpy=array([[b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. 7/7 [==============================] - ETA: 0s - loss: 1.5046 - accuracy: 0.5803WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[62], [65], [60], [35], [48], [66], [42], [44], [67], [71], [45], [65], [52], [76], [48], [51], [61], [51], [66], [51], [60], [52], [49], [57], [54], [68], [41], [62], [59], [45], [59], [55]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [1], [1], [1], [0], [0], [1], [0], [1], [1], [1], [0], [1], [1], [1], [1], [0], [1], [0], [1], [1], [1], [1], [1], [0], [0], [1], [0], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [4], [3], [2], [4], [4], [3], [3], [3], [3], [2], [4], [1], [3], [3], [4], [3], [3], [4], [4], [3], [3], [3], [4], [3], [3], [2], [4], [4], [2], [4], [4]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[124], [120], [140], [122], [124], [112], [120], [108], [152], [110], [128], [110], [152], [140], [124], [140], [150], [100], [178], [140], [120], [172], [118], [110], [120], [180], [105], [138], [140], [130], [135], [160]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[209], [177], [185], [192], [274], [212], [209], [141], [212], [265], [308], [248], [298], [197], [255], [299], [243], [222], [228], [261], [178], [199], [149], [201], [258], [274], [198], [294], [177], [234], [234], [289]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [1], [0], [1], [0], [1], [0], [1], [0], [1], [1], [0], [0], [0], [1], [0], [1], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [2], [0], [2], [2], [0], [0], [2], [2], [2], [2], [0], [1], [0], [0], [0], [0], [0], [2], [0], [0], [2], [0], [2], [2], [0], [0], [0], [2], [0], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[163], [140], [155], [174], [166], [132], [173], [175], [150], [130], [170], [158], [178], [116], [175], [173], [137], [143], [165], [186], [ 96], [162], [126], [126], [147], [150], [168], [106], [162], [175], [161], [145]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [1], [1], [1], [1], [0], [0], [0], [1], [0], [1], [0], [0], [1], [0], [0], [1]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[0. ], [0.4], [3. ], [0. ], [0.5], [0.1], [0. ], [0.6], [0.8], [0. ], [0. ], [0.6], [1.2], [1.1], [0. ], [1.6], [1. ], [1.2], [1. ], [0. ], [0. ], [0.5], [0.8], [1.5], [0.4], [1.6], [0. ], [1.9], [0. ], [0.6], [0.5], [0.8]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [2], [1], [2], [1], [2], [2], [2], [1], [1], [1], [2], [2], [1], [1], [2], [2], [2], [1], [1], [1], [1], [2], [2], [2], [1], [2], [1], [2], [2], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [1], [0], [0], [0], [1], [0], [2], [0], [0], [2], [0], [0], [0], [2], [0], [0], [0], [3], [0], [0], [0], [1], [3], [1], [0], [0], [1]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[77], [39], [60], [41], [56], [51], [59], [41], [60], [64], [64], [70], [62], [58], [58], [67], [35]])>, 'sex': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[1], [1], [1], [0], [1], [1], [1], [1], [1], [0], [1], [1], [0], [1], [0], [1], [0]])>, 'cp': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[4], [4], [4], [2], [3], [3], [2], [2], [4], [4], [4], [2], [4], [4], [4], [4], [4]])>, 'trestbps': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[125], [118], [130], [130], [130], [ 94], [140], [120], [125], [130], [120], [156], [160], [125], [130], [120], [138]])>, 'chol': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[304], [219], [206], [204], [256], [227], [221], [157], [258], [303], [246], [245], [164], [300], [197], [229], [183]])>, 'fbs': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[2], [0], [2], [2], [2], [0], [0], [0], [2], [0], [2], [2], [2], [2], [0], [2], [0]])>, 'thalach': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[162], [140], [132], [172], [142], [154], [164], [182], [141], [122], [ 96], [143], [145], [171], [131], [129], [182]])>, 'exang': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[1], [0], [1], [0], [1], [1], [1], [0], [1], [0], [1], [0], [0], [0], [0], [1], [0]])>, 'oldpeak': <tf.Tensor: shape=(17, 1), dtype=float64, numpy= array([[0. ], [1.2], [2.4], [1.4], [0.6], [0. ], [0. ], [0. ], [2.8], [2. ], [2.2], [0. ], [6.2], [0. ], [0.6], [2.6], [1.4]])>, 'slope': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[1], [2], [2], [1], [2], [1], [1], [1], [2], [2], [3], [1], [3], [1], [2], [2], [1]])>, 'ca': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[3], [0], [2], [0], [1], [1], [0], [0], [1], [2], [1], [0], [3], [2], [0], [2], [0]])>, 'thal': <tf.Tensor: shape=(17, 1), dtype=string, numpy= array([[b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. 7/7 [==============================] - 0s 42ms/step - loss: 1.5046 - accuracy: 0.5803 - val_loss: 0.5387 - val_accuracy: 0.7551 Epoch 3/5 WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[49], [43], [58], [42], [42], [59], [62], [64], [56], [59], [60], [67], [58], [43], [54], [52], [63], [37], [44], [34], [49], [63], [50], [64], [56], [57], [68], [42], [47], [62], [53], [35]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [1], [0], [1], [1], [1], [1], [1], [0], [1], [0], [0], [1], [1], [1], [1], [1], [1], [1], [0], [0], [1], [1], [0], [1], [1], [1], [1], [0], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [4], [4], [4], [3], [1], [2], [1], [4], [4], [4], [4], [4], [3], [4], [2], [4], [3], [2], [1], [2], [4], [3], [4], [4], [4], [4], [2], [4], [3], [3], [4]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[120], [150], [100], [102], [120], [134], [120], [110], [132], [174], [130], [106], [100], [130], [120], [120], [130], [130], [120], [118], [134], [124], [140], [128], [200], [132], [144], [120], [112], [130], [130], [126]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[188], [247], [234], [265], [240], [204], [281], [211], [184], [249], [253], [223], [248], [315], [188], [325], [254], [250], [220], [182], [271], [197], [233], [263], [288], [207], [193], [295], [204], [263], [197], [282]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [1], [0], [0], [0], [1], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [2], [0], [0], [2], [2], [2], [0], [0], [0], [2], [0], [0], [0], [2], [0], [0], [2], [0], [0], [0], [0], [2], [0], [0], [0], [0], [0], [2], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[139], [171], [156], [122], [194], [162], [103], [144], [105], [143], [144], [142], [122], [162], [113], [172], [147], [187], [170], [174], [162], [136], [163], [105], [133], [168], [141], [162], [143], [ 97], [152], [156]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [1], [1], [1], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [1], [1], [1], [0], [0], [0], [0], [0], [1]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[2. ], [1.5], [0.1], [0.6], [0.8], [0.8], [1.4], [1.8], [2.1], [0. ], [1.4], [0.3], [1. ], [1.9], [1.4], [0.2], [1.4], [3.5], [0. ], [0. ], [0. ], [0. ], [0.6], [0.2], [4. ], [0. ], [3.4], [0. ], [0.1], [1.2], [1.2], [0. ]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [1], [1], [2], [3], [1], [2], [2], [2], [2], [1], [1], [2], [1], [2], [1], [2], [3], [1], [1], [2], [2], [2], [2], [3], [1], [2], [1], [1], [2], [3], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [0], [1], [0], [0], [2], [1], [0], [1], [0], [1], [2], [0], [1], [1], [0], [1], [0], [0], [0], [0], [0], [1], [1], [2], [0], [2], [0], [0], [1], [0], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'fixed'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. 1/7 [===>..........................] - ETA: 0s - loss: 0.4726 - accuracy: 0.7500WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[38], [55], [61], [53], [47], [52], [59], [44], [56], [52], [54], [74], [53], [58], [57], [57], [50], [43], [67], [59], [45], [45], [66], [60], [64], [68], [69], [67], [51], [58], [57], [42]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [1], [1], [1], [1], [1], [1], [0], [1], [1], [0], [1], [0], [1], [0], [0], [1], [1], [1], [1], [0], [1], [0], [1], [1], [1], [1], [0], [1], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [4], [4], [4], [3], [2], [0], [3], [2], [4], [4], [2], [3], [2], [4], [4], [4], [4], [4], [4], [1], [4], [4], [3], [4], [0], [1], [4], [4], [2], [3], [3]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[120], [132], [148], [142], [108], [134], [164], [140], [140], [112], [122], [120], [130], [136], [140], [120], [110], [110], [100], [138], [110], [138], [120], [102], [145], [144], [160], [120], [130], [120], [150], [130]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[231], [353], [203], [226], [243], [201], [176], [235], [294], [230], [286], [269], [246], [319], [192], [354], [254], [211], [299], [271], [264], [236], [302], [318], [212], [193], [234], [237], [305], [284], [168], [180]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [1], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [1], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [2], [0], [0], [0], [2], [2], [0], [2], [2], [2], [2], [0], [0], [2], [0], [2], [2], [0], [2], [2], [0], [2], [1], [2], [0], [0], [2], [0], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[182], [132], [161], [111], [152], [158], [ 90], [180], [153], [160], [116], [121], [173], [152], [148], [163], [159], [161], [125], [182], [132], [152], [151], [160], [132], [141], [131], [ 71], [142], [160], [174], [150]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [0], [1], [0], [0], [0], [0], [0], [0], [1], [1], [0], [0], [0], [1], [0], [0], [1], [0], [0], [1], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[3.8], [1.2], [0. ], [0. ], [0. ], [0.8], [1. ], [0. ], [1.3], [0. ], [3.2], [0.2], [0. ], [0. ], [0.4], [0.6], [0. ], [0. ], [0.9], [0. ], [1.2], [0.2], [0.4], [0. ], [2. ], [3.4], [0.1], [1. ], [1.2], [1.8], [1.6], [0. ]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [2], [1], [1], [1], [1], [1], [1], [2], [1], [2], [1], [1], [1], [2], [1], [1], [1], [2], [1], [2], [2], [2], [1], [2], [1], [2], [2], [2], [2], [1], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [0], [0], [1], [2], [0], [0], [1], [2], [1], [3], [2], [0], [0], [0], [0], [2], [0], [0], [0], [0], [1], [2], [2], [1], [0], [0], [0], [0], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'1'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'fixed'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'fixed'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[59], [63], [62], [48], [40], [50], [29], [67], [51], [45], [65], [41], [45], [46], [43], [57], [64], [55], [41], [41], [61], [57], [52], [49], [66], [58], [59], [62], [63], [62], [58], [66]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [1], [1], [1], [1], [1], [1], [0], [1], [1], [1], [1], [1], [1], [1], [1], [0], [1], [1], [0], [1], [1], [1], [1], [1], [1], [1], [0], [0], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [4], [4], [2], [4], [4], [2], [4], [3], [4], [1], [2], [4], [2], [4], [3], [1], [4], [3], [2], [4], [3], [1], [2], [4], [4], [3], [3], [3], [4], [3], [2]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[164], [140], [120], [110], [110], [150], [130], [125], [140], [142], [138], [135], [115], [101], [115], [150], [170], [128], [130], [110], [130], [128], [118], [130], [160], [128], [126], [130], [135], [140], [132], [160]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[176], [187], [267], [229], [167], [243], [204], [254], [308], [309], [282], [203], [260], [197], [303], [126], [227], [205], [214], [235], [330], [229], [186], [266], [228], [259], [218], [231], [252], [268], [224], [246]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [0], [0], [0], [0], [1], [0], [0], [1], [0], [0], [1], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [2], [0], [0], [2], [2], [2], [0], [2], [2], [2], [0], [2], [0], [0], [0], [2], [1], [2], [0], [2], [2], [2], [0], [2], [2], [0], [0], [2], [2], [2], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[ 90], [144], [ 99], [168], [114], [128], [202], [163], [142], [147], [174], [132], [185], [156], [181], [173], [155], [130], [168], [153], [169], [150], [190], [171], [138], [130], [134], [146], [172], [160], [173], [120]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [0], [1], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [1]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[1. ], [4. ], [1.8], [1. ], [2. ], [2.6], [0. ], [0.2], [1.5], [0. ], [1.4], [0. ], [0. ], [0. ], [1.2], [0.2], [0.6], [2. ], [2. ], [0. ], [0. ], [0.4], [0. ], [0.6], [2.3], [3. ], [2.2], [1.8], [0. ], [3.6], [3.2], [0. ]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [1], [2], [3], [2], [2], [1], [2], [1], [2], [2], [2], [1], [1], [2], [1], [2], [2], [2], [1], [1], [2], [2], [1], [1], [2], [2], [2], [1], [3], [1], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [2], [2], [0], [0], [0], [0], [2], [1], [3], [1], [0], [0], [0], [0], [1], [0], [1], [0], [0], [0], [1], [0], [0], [0], [2], [1], [3], [0], [2], [2], [3]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'fixed'], [b'reversible'], [b'reversible'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'fixed'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'fixed'], [b'normal'], [b'fixed'], [b'reversible'], [b'fixed'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'fixed']], dtype=object)>} Consider rewriting this model with the Functional API. 3/7 [===========>..................] - ETA: 0s - loss: 0.9738 - accuracy: 0.6979WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[58], [60], [58], [44], [59], [57], [53], [54], [54], [45], [64], [57], [60], [46], [68], [47], [64], [40], [62], [42], [44], [42], [43], [39], [61], [44], [50], [54], [49], [50], [68], [46]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [0], [1], [1], [1], [0], [1], [1], [0], [0], [0], [1], [0], [0], [1], [0], [1], [1], [1], [1], [1], [0], [0], [1], [0], [0], [1], [0], [1], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [4], [1], [2], [1], [4], [4], [2], [4], [2], [3], [2], [4], [4], [3], [3], [4], [1], [2], [4], [4], [1], [4], [3], [4], [3], [2], [4], [4], [3], [3], [3]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[114], [140], [150], [120], [170], [110], [130], [108], [140], [112], [140], [130], [145], [138], [120], [130], [180], [140], [128], [136], [112], [148], [132], [ 94], [138], [118], [120], [124], [130], [129], [118], [150]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[318], [293], [283], [263], [288], [335], [264], [309], [239], [160], [313], [236], [282], [243], [211], [253], [325], [199], [208], [315], [290], [244], [341], [199], [166], [242], [244], [266], [269], [196], [277], [231]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [2], [2], [0], [2], [0], [2], [0], [0], [0], [0], [2], [2], [2], [2], [0], [0], [0], [2], [0], [2], [2], [2], [0], [2], [0], [0], [2], [0], [0], [0], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[140], [170], [162], [173], [159], [143], [143], [156], [160], [138], [133], [174], [142], [152], [115], [179], [154], [178], [140], [125], [153], [178], [136], [179], [125], [149], [162], [109], [163], [163], [151], [147]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [1], [1], [0], [0], [1], [1], [0], [1], [0], [0], [1], [0], [1], [0], [0], [1], [0], [0], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[4.4], [1.2], [1. ], [0. ], [0.2], [3. ], [0.4], [0. ], [1.2], [0. ], [0.2], [0. ], [2.8], [0. ], [1.5], [0. ], [0. ], [1.4], [0. ], [1.8], [0. ], [0.8], [3. ], [0. ], [3.6], [0.3], [1.1], [2.2], [0. ], [0. ], [1. ], [3.6]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [2], [1], [1], [2], [2], [2], [1], [1], [2], [1], [2], [2], [2], [2], [1], [1], [1], [1], [2], [1], [1], [2], [1], [2], [2], [1], [2], [1], [1], [1], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [2], [0], [0], [0], [1], [0], [0], [0], [0], [0], [1], [2], [0], [0], [0], [0], [0], [0], [0], [1], [2], [0], [0], [1], [1], [0], [1], [0], [0], [1], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'fixed'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'fixed'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[41], [62], [45], [71], [42], [47], [51], [54], [59], [67], [57], [56], [58], [54], [67], [63], [37], [34], [43], [65], [46], [44], [60], [70], [52], [64], [56], [55], [50], [51], [70], [55]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [1], [0], [1], [1], [1], [0], [1], [0], [1], [1], [1], [1], [0], [1], [0], [0], [1], [0], [1], [1], [1], [1], [1], [1], [1], [0], [0], [1], [1], [0]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [4], [4], [2], [4], [3], [3], [3], [3], [3], [2], [4], [4], [3], [3], [4], [3], [2], [4], [3], [4], [4], [4], [3], [4], [3], [1], [4], [3], [3], [4], [2]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[112], [150], [104], [160], [140], [138], [110], [135], [150], [152], [124], [130], [128], [150], [115], [130], [120], [118], [120], [140], [120], [120], [117], [160], [125], [125], [120], [180], [120], [125], [130], [132]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[250], [244], [208], [302], [226], [257], [175], [304], [212], [277], [261], [283], [216], [232], [564], [330], [215], [210], [177], [417], [249], [169], [230], [269], [212], [309], [193], [327], [219], [245], [322], [342]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [1], [1], [0], [0], [1], [0], [0], [0], [1], [0], [0], [0], [1], [0], [0], [1], [0], [0], [0], [0], [0], [0], [1], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [2], [0], [0], [2], [0], [0], [0], [0], [0], [2], [2], [2], [2], [2], [0], [0], [2], [2], [2], [0], [0], [0], [0], [0], [2], [1], [0], [2], [2], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[179], [154], [148], [162], [178], [156], [123], [170], [157], [172], [141], [103], [131], [165], [160], [132], [170], [192], [120], [157], [144], [144], [160], [112], [168], [131], [162], [117], [158], [166], [109], [166]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [0], [0], [0], [0], [0], [0], [0], [0], [1], [1], [0], [0], [1], [0], [0], [1], [0], [0], [1], [1], [1], [0], [1], [0], [1], [0], [0], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[0. ], [1.4], [3. ], [0.4], [0. ], [0. ], [0.6], [0. ], [1.6], [0. ], [0.3], [1.6], [2.2], [1.6], [1.6], [1.8], [0. ], [0.7], [2.5], [0.8], [0.8], [2.8], [1.4], [2.9], [1. ], [1.8], [1.9], [3.4], [1.6], [2.4], [2.4], [1.2]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [2], [2], [1], [1], [1], [1], [1], [1], [1], [1], [3], [2], [1], [2], [1], [1], [1], [2], [1], [1], [3], [1], [2], [1], [2], [2], [2], [2], [2], [2], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [2], [0], [0], [0], [0], [0], [1], [0], [0], [3], [0], [0], [3], [0], [0], [0], [1], [0], [0], [2], [1], [2], [0], [0], [0], [0], [0], [3], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'fixed'], [b'reversible'], [b'reversible'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. 5/7 [====================>.........] - ETA: 0s - loss: 1.0254 - accuracy: 0.7188WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[54], [59], [58], [44], [43], [56], [55], [57], [54], [54], [57], [57], [57], [48], [64], [51], [52], [51], [56], [50], [46], [56], [59], [60], [51], [67], [53], [44], [46], [41], [58], [57]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [1], [1], [0], [1], [1], [1], [0], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [0], [0], [1], [0], [0], [1], [1], [1], [1], [0], [1], [0]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [1], [4], [2], [3], [4], [4], [4], [3], [4], [2], [4], [4], [4], [3], [4], [4], [1], [2], [4], [3], [4], [4], [4], [3], [4], [4], [3], [4], [2], [3], [4]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[110], [178], [150], [130], [122], [125], [140], [165], [110], [110], [154], [150], [152], [122], [140], [140], [128], [125], [120], [144], [142], [134], [110], [150], [130], [160], [123], [130], [140], [126], [105], [128]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[239], [270], [270], [219], [213], [249], [217], [289], [214], [206], [232], [276], [274], [222], [335], [298], [255], [213], [240], [200], [177], [409], [239], [258], [256], [286], [282], [233], [311], [306], [240], [303]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [1], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [2], [2], [2], [0], [2], [0], [2], [0], [2], [2], [2], [0], [2], [0], [0], [0], [2], [0], [2], [2], [2], [2], [2], [2], [2], [0], [0], [0], [0], [2], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[126], [145], [111], [188], [165], [144], [111], [124], [158], [108], [164], [112], [ 88], [186], [158], [122], [161], [125], [169], [126], [160], [150], [142], [157], [149], [108], [ 95], [179], [120], [163], [154], [159]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [1], [0], [0], [1], [1], [0], [0], [1], [0], [1], [1], [0], [0], [1], [1], [1], [0], [1], [1], [1], [1], [0], [0], [1], [1], [1], [1], [0], [1], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[2.8], [4.2], [0.8], [0. ], [0.2], [1.2], [5.6], [1. ], [1.6], [0. ], [0. ], [0.6], [1.2], [0. ], [0. ], [4.2], [0. ], [1.4], [0. ], [0.9], [1.4], [1.9], [1.2], [2.6], [0.5], [1.5], [2. ], [0.4], [1.8], [0. ], [0.6], [0. ]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [3], [1], [1], [2], [2], [3], [2], [2], [2], [1], [2], [2], [1], [1], [2], [1], [1], [3], [2], [3], [2], [2], [2], [1], [2], [2], [1], [2], [1], [2], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [0], [0], [1], [0], [3], [0], [1], [1], [1], [1], [0], [0], [3], [1], [1], [0], [0], [0], [2], [1], [2], [0], [3], [2], [0], [2], [0], [0], [1]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[62]])>, 'sex': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[0]])>, 'cp': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[4]])>, 'trestbps': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[140]])>, 'chol': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[394]])>, 'fbs': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[0]])>, 'restecg': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[2]])>, 'thalach': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[157]])>, 'exang': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[0]])>, 'oldpeak': <tf.Tensor: shape=(1, 1), dtype=float64, numpy=array([[1.2]])>, 'slope': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[2]])>, 'ca': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[0]])>, 'thal': <tf.Tensor: shape=(1, 1), dtype=string, numpy=array([[b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. 7/7 [==============================] - ETA: 0s - loss: 1.0386 - accuracy: 0.6995WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[62], [65], [60], [35], [48], [66], [42], [44], [67], [71], [45], [65], [52], [76], [48], [51], [61], [51], [66], [51], [60], [52], [49], [57], [54], [68], [41], [62], [59], [45], [59], [55]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [1], [1], [1], [0], [0], [1], [0], [1], [1], [1], [0], [1], [1], [1], [1], [0], [1], [0], [1], [1], [1], [1], [1], [0], [0], [1], [0], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [4], [3], [2], [4], [4], [3], [3], [3], [3], [2], [4], [1], [3], [3], [4], [3], [3], [4], [4], [3], [3], [3], [4], [3], [3], [2], [4], [4], [2], [4], [4]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[124], [120], [140], [122], [124], [112], [120], [108], [152], [110], [128], [110], [152], [140], [124], [140], [150], [100], [178], [140], [120], [172], [118], [110], [120], [180], [105], [138], [140], [130], [135], [160]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[209], [177], [185], [192], [274], [212], [209], [141], [212], [265], [308], [248], [298], [197], [255], [299], [243], [222], [228], [261], [178], [199], [149], [201], [258], [274], [198], [294], [177], [234], [234], [289]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [1], [0], [1], [0], [1], [0], [1], [0], [1], [1], [0], [0], [0], [1], [0], [1], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [2], [0], [2], [2], [0], [0], [2], [2], [2], [2], [0], [1], [0], [0], [0], [0], [0], [2], [0], [0], [2], [0], [2], [2], [0], [0], [0], [2], [0], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[163], [140], [155], [174], [166], [132], [173], [175], [150], [130], [170], [158], [178], [116], [175], [173], [137], [143], [165], [186], [ 96], [162], [126], [126], [147], [150], [168], [106], [162], [175], [161], [145]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [1], [1], [1], [1], [0], [0], [0], [1], [0], [1], [0], [0], [1], [0], [0], [1]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[0. ], [0.4], [3. ], [0. ], [0.5], [0.1], [0. ], [0.6], [0.8], [0. ], [0. ], [0.6], [1.2], [1.1], [0. ], [1.6], [1. ], [1.2], [1. ], [0. ], [0. ], [0.5], [0.8], [1.5], [0.4], [1.6], [0. ], [1.9], [0. ], [0.6], [0.5], [0.8]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [2], [1], [2], [1], [2], [2], [2], [1], [1], [1], [2], [2], [1], [1], [2], [2], [2], [1], [1], [1], [1], [2], [2], [2], [1], [2], [1], [2], [2], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [1], [0], [0], [0], [1], [0], [2], [0], [0], [2], [0], [0], [0], [2], [0], [0], [0], [3], [0], [0], [0], [1], [3], [1], [0], [0], [1]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[77], [39], [60], [41], [56], [51], [59], [41], [60], [64], [64], [70], [62], [58], [58], [67], [35]])>, 'sex': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[1], [1], [1], [0], [1], [1], [1], [1], [1], [0], [1], [1], [0], [1], [0], [1], [0]])>, 'cp': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[4], [4], [4], [2], [3], [3], [2], [2], [4], [4], [4], [2], [4], [4], [4], [4], [4]])>, 'trestbps': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[125], [118], [130], [130], [130], [ 94], [140], [120], [125], [130], [120], [156], [160], [125], [130], [120], [138]])>, 'chol': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[304], [219], [206], [204], [256], [227], [221], [157], [258], [303], [246], [245], [164], [300], [197], [229], [183]])>, 'fbs': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[2], [0], [2], [2], [2], [0], [0], [0], [2], [0], [2], [2], [2], [2], [0], [2], [0]])>, 'thalach': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[162], [140], [132], [172], [142], [154], [164], [182], [141], [122], [ 96], [143], [145], [171], [131], [129], [182]])>, 'exang': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[1], [0], [1], [0], [1], [1], [1], [0], [1], [0], [1], [0], [0], [0], [0], [1], [0]])>, 'oldpeak': <tf.Tensor: shape=(17, 1), dtype=float64, numpy= array([[0. ], [1.2], [2.4], [1.4], [0.6], [0. ], [0. ], [0. ], [2.8], [2. ], [2.2], [0. ], [6.2], [0. ], [0.6], [2.6], [1.4]])>, 'slope': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[1], [2], [2], [1], [2], [1], [1], [1], [2], [2], [3], [1], [3], [1], [2], [2], [1]])>, 'ca': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[3], [0], [2], [0], [1], [1], [0], [0], [1], [2], [1], [0], [3], [2], [0], [2], [0]])>, 'thal': <tf.Tensor: shape=(17, 1), dtype=string, numpy= array([[b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. 7/7 [==============================] - 0s 42ms/step - loss: 1.0386 - accuracy: 0.6995 - val_loss: 0.6039 - val_accuracy: 0.6531 Epoch 4/5 WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[52], [58], [49], [60], [34], [41], [58], [58], [59], [52], [49], [57], [42], [57], [67], [44], [62], [53], [50], [48], [58], [58], [53], [42], [56], [45], [60], [62], [44], [57], [65], [46]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [1], [1], [1], [1], [1], [0], [1], [1], [1], [1], [1], [1], [0], [1], [1], [0], [1], [1], [0], [0], [0], [1], [1], [0], [0], [1], [1], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [2], [4], [4], [1], [3], [2], [4], [4], [4], [2], [4], [3], [3], [4], [3], [2], [3], [2], [2], [4], [4], [4], [4], [2], [1], [4], [4], [2], [3], [1], [3]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[125], [136], [130], [140], [118], [112], [120], [128], [174], [112], [130], [152], [120], [150], [100], [118], [128], [130], [120], [110], [150], [100], [130], [102], [120], [110], [150], [140], [130], [150], [138], [150]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[212], [319], [269], [293], [182], [250], [284], [259], [249], [230], [266], [274], [240], [126], [299], [242], [208], [197], [244], [229], [270], [248], [264], [265], [240], [264], [258], [394], [219], [168], [282], [231]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [1], [0], [0], [1], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [2], [0], [2], [2], [0], [2], [2], [0], [0], [0], [0], [0], [0], [2], [0], [2], [2], [0], [0], [2], [2], [2], [2], [0], [0], [2], [2], [2], [0], [2], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[168], [152], [163], [170], [174], [179], [160], [130], [143], [160], [171], [ 88], [194], [173], [125], [149], [140], [152], [162], [168], [111], [122], [143], [122], [169], [132], [157], [157], [188], [174], [174], [147]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [1], [1], [0], [0], [1], [0], [0], [1], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[1. ], [0. ], [0. ], [1.2], [0. ], [0. ], [1.8], [3. ], [0. ], [0. ], [0.6], [1.2], [0.8], [0.2], [0.9], [0.3], [0. ], [1.2], [1.1], [1. ], [0.8], [1. ], [0.4], [0.6], [0. ], [1.2], [2.6], [1.2], [0. ], [1.6], [1.4], [3.6]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [1], [2], [1], [1], [2], [2], [2], [1], [1], [2], [3], [1], [2], [2], [1], [3], [1], [3], [1], [2], [2], [2], [3], [2], [2], [2], [1], [1], [2], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [2], [0], [2], [0], [0], [0], [2], [0], [1], [0], [1], [0], [1], [2], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [2], [0], [0], [0], [1], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. 1/7 [===>..........................] - ETA: 0s - loss: 0.5663 - accuracy: 0.6875WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[63], [57], [44], [41], [46], [66], [51], [46], [62], [58], [41], [68], [58], [64], [60], [63], [45], [57], [52], [59], [29], [42], [63], [56], [58], [40], [55], [67], [52], [64], [43], [42]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [1], [0], [1], [1], [1], [0], [1], [0], [1], [1], [1], [0], [1], [1], [0], [1], [1], [1], [1], [1], [1], [1], [1], [0], [1], [1], [1], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [2], [3], [2], [4], [4], [4], [4], [4], [4], [2], [0], [3], [3], [3], [4], [4], [4], [4], [1], [2], [1], [4], [4], [4], [4], [4], [4], [2], [1], [4], [4]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[135], [154], [140], [135], [138], [160], [140], [120], [140], [100], [126], [144], [132], [125], [102], [130], [115], [128], [128], [134], [130], [148], [130], [130], [114], [110], [180], [160], [120], [170], [110], [140]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[252], [232], [235], [203], [243], [228], [298], [249], [268], [234], [306], [193], [224], [309], [318], [254], [260], [303], [255], [204], [204], [244], [330], [283], [318], [167], [327], [286], [325], [227], [211], [226]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [1], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [2], [2], [0], [2], [2], [0], [2], [2], [0], [0], [1], [2], [0], [0], [2], [2], [2], [0], [0], [2], [2], [2], [2], [1], [2], [1], [2], [0], [2], [0], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[172], [164], [180], [132], [152], [138], [122], [144], [160], [156], [163], [141], [173], [131], [160], [147], [185], [159], [161], [162], [202], [178], [132], [103], [140], [114], [117], [108], [172], [155], [161], [178]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [1], [0], [1], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [1], [0], [0], [0], [1], [1], [0], [1], [1], [1], [0], [0], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[0. ], [0. ], [0. ], [0. ], [0. ], [2.3], [4.2], [0.8], [3.6], [0.1], [0. ], [3.4], [3.2], [1.8], [0. ], [1.4], [0. ], [0. ], [0. ], [0.8], [0. ], [0.8], [1.8], [1.6], [4.4], [2. ], [3.4], [1.5], [0.2], [0.6], [0. ], [0. ]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [1], [2], [2], [1], [2], [1], [3], [1], [1], [1], [1], [2], [1], [2], [1], [1], [1], [1], [1], [1], [1], [3], [3], [2], [2], [2], [1], [2], [1], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [0], [0], [0], [0], [3], [0], [2], [1], [0], [2], [2], [0], [1], [1], [0], [1], [1], [2], [0], [2], [3], [0], [3], [0], [0], [3], [0], [0], [0], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'normal'], [b'normal'], [b'normal'], [b'fixed'], [b'normal'], [b'fixed'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'fixed'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[59], [66], [55], [43], [56], [45], [64], [57], [57], [67], [44], [54], [41], [63], [54], [49], [46], [62], [68], [56], [64], [59], [54], [43], [56], [69], [59], [58], [54], [64], [39], [61]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [0], [1], [0], [1], [1], [0], [1], [0], [1], [0], [1], [1], [1], [0], [0], [0], [1], [0], [0], [1], [1], [1], [1], [1], [1], [0], [1], [1], [0], [0]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [2], [2], [4], [4], [4], [1], [2], [2], [3], [3], [3], [3], [4], [4], [2], [3], [4], [4], [4], [3], [3], [4], [3], [4], [1], [1], [1], [4], [4], [3], [4]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[164], [160], [132], [115], [200], [142], [110], [130], [124], [115], [130], [135], [130], [140], [120], [134], [142], [150], [144], [134], [140], [126], [122], [130], [125], [160], [170], [150], [110], [145], [ 94], [130]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[176], [246], [342], [303], [288], [309], [211], [236], [261], [564], [233], [304], [214], [187], [188], [271], [177], [244], [193], [409], [313], [218], [286], [315], [249], [234], [288], [283], [206], [212], [199], [330]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [1], [0], [0], [1], [0], [0], [1], [1], [0], [1], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [2], [2], [2], [2], [0], [2], [0], [0], [2], [2], [0], [0], [2], [0], [0], [2], [0], [0], [2], [0], [2], [2], [2], [2], [2], [2], [0], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[ 90], [120], [166], [181], [133], [147], [144], [174], [141], [160], [179], [170], [168], [144], [113], [162], [160], [154], [141], [150], [133], [134], [116], [162], [144], [131], [159], [162], [108], [132], [179], [169]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [0], [0], [1], [1], [1], [0], [0], [0], [1], [0], [0], [1], [0], [0], [1], [1], [0], [1], [0], [0], [1], [0], [1], [0], [0], [0], [1], [0], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[1. ], [0. ], [1.2], [1.2], [4. ], [0. ], [1.8], [0. ], [0.3], [1.6], [0.4], [0. ], [2. ], [4. ], [1.4], [0. ], [1.4], [1.4], [3.4], [1.9], [0.2], [2.2], [3.2], [1.9], [1.2], [0.1], [0.2], [1. ], [0. ], [2. ], [0. ], [0. ]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [2], [1], [2], [3], [2], [2], [2], [1], [2], [1], [1], [2], [1], [2], [2], [3], [2], [2], [2], [1], [2], [2], [1], [2], [2], [2], [1], [2], [2], [1], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [3], [0], [0], [2], [3], [0], [1], [0], [0], [0], [0], [0], [2], [1], [0], [0], [0], [2], [2], [0], [1], [2], [1], [1], [1], [0], [0], [1], [2], [0], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'1'], [b'fixed'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'fixed'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'fixed'], [b'normal'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. 3/7 [===========>..................] - ETA: 0s - loss: 0.6564 - accuracy: 0.6562WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[35], [62], [44], [57], [64], [67], [62], [68], [50], [53], [48], [59], [49], [43], [50], [51], [54], [44], [65], [50], [56], [57], [51], [64], [43], [50], [51], [50], [50], [44], [53], [37]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [1], [0], [0], [0], [1], [1], [1], [1], [1], [1], [1], [1], [0], [1], [1], [1], [0], [1], [0], [1], [1], [1], [0], [0], [0], [1], [1], [1], [1], [0]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [3], [2], [4], [4], [4], [3], [3], [3], [4], [4], [4], [3], [4], [3], [1], [3], [2], [3], [4], [2], [4], [3], [4], [4], [4], [3], [3], [4], [4], [3], [3]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[126], [130], [120], [120], [180], [106], [130], [118], [129], [142], [122], [164], [120], [150], [120], [125], [150], [120], [140], [144], [140], [165], [110], [128], [132], [110], [140], [140], [150], [120], [130], [120]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[282], [263], [220], [354], [325], [223], [231], [277], [196], [226], [222], [176], [188], [247], [219], [213], [232], [263], [417], [200], [294], [289], [175], [263], [341], [254], [308], [233], [243], [169], [246], [215]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [1], [0], [0], [1], [0], [0], [1], [0], [0], [0], [0], [0], [1], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [0], [0], [0], [0], [0], [0], [0], [0], [2], [2], [2], [0], [0], [0], [2], [2], [0], [2], [2], [2], [2], [0], [0], [2], [2], [2], [0], [2], [0], [2], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[156], [ 97], [170], [163], [154], [142], [146], [151], [163], [111], [186], [ 90], [139], [171], [158], [125], [165], [173], [157], [126], [153], [124], [123], [105], [136], [159], [142], [163], [128], [144], [173], [170]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [1], [1], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [1], [0], [0], [0], [1], [0], [0], [0], [1], [1], [0], [0], [0], [0], [1], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[0. ], [1.2], [0. ], [0.6], [0. ], [0.3], [1.8], [1. ], [0. ], [0. ], [0. ], [1. ], [2. ], [1.5], [1.6], [1.4], [1.6], [0. ], [0.8], [0.9], [1.3], [1. ], [0.6], [0.2], [3. ], [0. ], [1.5], [0.6], [2.6], [2.8], [0. ], [0. ]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [2], [1], [1], [1], [1], [2], [1], [1], [1], [1], [2], [2], [1], [2], [1], [1], [1], [1], [2], [2], [2], [1], [2], [2], [1], [1], [2], [2], [3], [1], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [0], [0], [0], [2], [3], [1], [0], [0], [0], [2], [3], [0], [0], [1], [0], [0], [1], [0], [0], [3], [0], [1], [0], [0], [1], [1], [0], [0], [3], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'fixed'], [b'normal'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[57], [66], [47], [60], [37], [59], [54], [46], [62], [40], [68], [53], [57], [44], [54], [63], [54], [54], [47], [71], [51], [58], [34], [59], [52], [62], [61], [42], [64], [51], [55], [60]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [0], [1], [1], [1], [1], [0], [1], [1], [1], [0], [0], [1], [0], [1], [1], [1], [1], [1], [1], [0], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [4], [4], [4], [3], [4], [4], [4], [4], [1], [3], [4], [4], [4], [4], [4], [2], [4], [3], [2], [3], [4], [2], [4], [2], [2], [4], [3], [3], [4], [4], [4]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[110], [120], [112], [117], [130], [110], [140], [140], [120], [140], [120], [123], [140], [112], [110], [124], [108], [124], [130], [160], [130], [128], [118], [138], [134], [120], [148], [130], [140], [130], [140], [145]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[335], [302], [204], [230], [250], [239], [239], [311], [267], [199], [211], [282], [192], [290], [239], [197], [309], [266], [253], [302], [256], [216], [210], [271], [201], [281], [203], [180], [335], [305], [217], [282]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [2], [0], [0], [0], [2], [0], [0], [0], [0], [2], [0], [0], [2], [0], [0], [0], [2], [0], [0], [2], [2], [0], [2], [0], [2], [0], [0], [0], [0], [0], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[143], [151], [143], [160], [187], [142], [160], [120], [ 99], [178], [115], [ 95], [148], [153], [126], [136], [156], [109], [179], [162], [149], [131], [192], [182], [158], [103], [161], [150], [158], [142], [111], [142]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [1], [0], [1], [0], [1], [1], [1], [0], [1], [0], [0], [1], [1], [0], [1], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [1], [1], [1]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[3. ], [0.4], [0.1], [1.4], [3.5], [1.2], [1.2], [1.8], [1.8], [1.4], [1.5], [2. ], [0.4], [0. ], [2.8], [0. ], [0. ], [2.2], [0. ], [0.4], [0.5], [2.2], [0.7], [0. ], [0.8], [1.4], [0. ], [0. ], [0. ], [1.2], [5.6], [2.8]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [2], [1], [1], [3], [2], [1], [2], [2], [1], [2], [2], [2], [1], [2], [2], [1], [2], [1], [1], [1], [2], [1], [1], [1], [2], [1], [1], [1], [2], [3], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [2], [0], [1], [0], [2], [2], [0], [0], [2], [0], [1], [1], [0], [0], [1], [0], [2], [0], [3], [0], [0], [1], [1], [1], [0], [0], [0], [0], [2]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'fixed'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. 5/7 [====================>.........] - ETA: 0s - loss: 0.6322 - accuracy: 0.6750WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[70], [45], [47], [57], [43], [61], [42], [67], [46], [55], [51], [45], [59], [56], [55], [70], [41], [59], [57], [60], [43], [42], [67], [67], [38], [74], [56], [57], [52], [47], [54], [58]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [1], [1], [0], [1], [1], [1], [1], [1], [1], [0], [1], [1], [0], [1], [1], [1], [1], [1], [1], [1], [0], [1], [1], [0], [1], [1], [1], [1], [0], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [4], [3], [3], [3], [4], [4], [4], [2], [4], [3], [2], [3], [1], [4], [4], [2], [1], [4], [4], [4], [2], [3], [4], [1], [2], [4], [4], [1], [3], [3], [3]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[160], [104], [138], [128], [122], [138], [136], [120], [101], [132], [125], [112], [150], [120], [128], [130], [110], [178], [132], [130], [120], [120], [152], [125], [120], [120], [132], [150], [118], [108], [110], [105]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[269], [208], [257], [229], [213], [166], [315], [237], [197], [353], [245], [160], [212], [193], [205], [322], [235], [270], [207], [253], [177], [295], [277], [254], [231], [269], [184], [276], [186], [243], [214], [240]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [1], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [2], [2], [2], [0], [2], [0], [0], [0], [0], [2], [0], [0], [2], [1], [2], [0], [2], [0], [0], [2], [0], [0], [0], [0], [2], [2], [2], [2], [0], [0], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[112], [148], [156], [150], [165], [125], [125], [ 71], [156], [132], [166], [138], [157], [162], [130], [109], [153], [145], [168], [144], [120], [162], [172], [163], [182], [121], [105], [112], [190], [152], [158], [154]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [0], [0], [0], [1], [1], [0], [0], [1], [0], [0], [0], [0], [1], [0], [0], [0], [1], [1], [1], [0], [0], [0], [1], [1], [1], [1], [0], [0], [0], [1]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[2.9], [3. ], [0. ], [0.4], [0.2], [3.6], [1.8], [1. ], [0. ], [1.2], [2.4], [0. ], [1.6], [1.9], [2. ], [2.4], [0. ], [4.2], [0. ], [1.4], [2.5], [0. ], [0. ], [0.2], [3.8], [0.2], [2.1], [0.6], [0. ], [0. ], [1.6], [0.6]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [2], [1], [2], [2], [2], [2], [2], [1], [2], [2], [2], [1], [2], [2], [2], [1], [3], [1], [1], [2], [1], [1], [2], [2], [1], [2], [2], [2], [1], [2], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [1], [0], [1], [0], [0], [0], [1], [0], [0], [0], [0], [1], [3], [0], [0], [0], [1], [0], [0], [1], [2], [0], [1], [1], [1], [0], [0], [0], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'fixed'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'fixed'], [b'fixed'], [b'fixed'], [b'normal'], [b'normal'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[45]])>, 'sex': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[0]])>, 'cp': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[4]])>, 'trestbps': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[138]])>, 'chol': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[236]])>, 'fbs': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[0]])>, 'restecg': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[2]])>, 'thalach': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[152]])>, 'exang': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[1]])>, 'oldpeak': <tf.Tensor: shape=(1, 1), dtype=float64, numpy=array([[0.2]])>, 'slope': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[2]])>, 'ca': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[0]])>, 'thal': <tf.Tensor: shape=(1, 1), dtype=string, numpy=array([[b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. 7/7 [==============================] - ETA: 0s - loss: 0.6209 - accuracy: 0.6943WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[62], [65], [60], [35], [48], [66], [42], [44], [67], [71], [45], [65], [52], [76], [48], [51], [61], [51], [66], [51], [60], [52], [49], [57], [54], [68], [41], [62], [59], [45], [59], [55]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [1], [1], [1], [0], [0], [1], [0], [1], [1], [1], [0], [1], [1], [1], [1], [0], [1], [0], [1], [1], [1], [1], [1], [0], [0], [1], [0], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [4], [3], [2], [4], [4], [3], [3], [3], [3], [2], [4], [1], [3], [3], [4], [3], [3], [4], [4], [3], [3], [3], [4], [3], [3], [2], [4], [4], [2], [4], [4]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[124], [120], [140], [122], [124], [112], [120], [108], [152], [110], [128], [110], [152], [140], [124], [140], [150], [100], [178], [140], [120], [172], [118], [110], [120], [180], [105], [138], [140], [130], [135], [160]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[209], [177], [185], [192], [274], [212], [209], [141], [212], [265], [308], [248], [298], [197], [255], [299], [243], [222], [228], [261], [178], [199], [149], [201], [258], [274], [198], [294], [177], [234], [234], [289]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [1], [0], [1], [0], [1], [0], [1], [0], [1], [1], [0], [0], [0], [1], [0], [1], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [2], [0], [2], [2], [0], [0], [2], [2], [2], [2], [0], [1], [0], [0], [0], [0], [0], [2], [0], [0], [2], [0], [2], [2], [0], [0], [0], [2], [0], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[163], [140], [155], [174], [166], [132], [173], [175], [150], [130], [170], [158], [178], [116], [175], [173], [137], [143], [165], [186], [ 96], [162], [126], [126], [147], [150], [168], [106], [162], [175], [161], [145]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [1], [1], [1], [1], [0], [0], [0], [1], [0], [1], [0], [0], [1], [0], [0], [1]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[0. ], [0.4], [3. ], [0. ], [0.5], [0.1], [0. ], [0.6], [0.8], [0. ], [0. ], [0.6], [1.2], [1.1], [0. ], [1.6], [1. ], [1.2], [1. ], [0. ], [0. ], [0.5], [0.8], [1.5], [0.4], [1.6], [0. ], [1.9], [0. ], [0.6], [0.5], [0.8]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [2], [1], [2], [1], [2], [2], [2], [1], [1], [1], [2], [2], [1], [1], [2], [2], [2], [1], [1], [1], [1], [2], [2], [2], [1], [2], [1], [2], [2], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [1], [0], [0], [0], [1], [0], [2], [0], [0], [2], [0], [0], [0], [2], [0], [0], [0], [3], [0], [0], [0], [1], [3], [1], [0], [0], [1]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[77], [39], [60], [41], [56], [51], [59], [41], [60], [64], [64], [70], [62], [58], [58], [67], [35]])>, 'sex': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[1], [1], [1], [0], [1], [1], [1], [1], [1], [0], [1], [1], [0], [1], [0], [1], [0]])>, 'cp': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[4], [4], [4], [2], [3], [3], [2], [2], [4], [4], [4], [2], [4], [4], [4], [4], [4]])>, 'trestbps': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[125], [118], [130], [130], [130], [ 94], [140], [120], [125], [130], [120], [156], [160], [125], [130], [120], [138]])>, 'chol': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[304], [219], [206], [204], [256], [227], [221], [157], [258], [303], [246], [245], [164], [300], [197], [229], [183]])>, 'fbs': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[2], [0], [2], [2], [2], [0], [0], [0], [2], [0], [2], [2], [2], [2], [0], [2], [0]])>, 'thalach': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[162], [140], [132], [172], [142], [154], [164], [182], [141], [122], [ 96], [143], [145], [171], [131], [129], [182]])>, 'exang': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[1], [0], [1], [0], [1], [1], [1], [0], [1], [0], [1], [0], [0], [0], [0], [1], [0]])>, 'oldpeak': <tf.Tensor: shape=(17, 1), dtype=float64, numpy= array([[0. ], [1.2], [2.4], [1.4], [0.6], [0. ], [0. ], [0. ], [2.8], [2. ], [2.2], [0. ], [6.2], [0. ], [0.6], [2.6], [1.4]])>, 'slope': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[1], [2], [2], [1], [2], [1], [1], [1], [2], [2], [3], [1], [3], [1], [2], [2], [1]])>, 'ca': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[3], [0], [2], [0], [1], [1], [0], [0], [1], [2], [1], [0], [3], [2], [0], [2], [0]])>, 'thal': <tf.Tensor: shape=(17, 1), dtype=string, numpy= array([[b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. 7/7 [==============================] - 0s 43ms/step - loss: 0.6209 - accuracy: 0.6943 - val_loss: 0.6867 - val_accuracy: 0.7347 Epoch 5/5 WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[60], [51], [49], [64], [54], [58], [42], [68], [70], [58], [66], [57], [57], [51], [60], [59], [55], [67], [49], [53], [50], [54], [65], [56], [48], [59], [63], [50], [59], [34], [54], [68]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [1], [1], [1], [0], [1], [1], [1], [0], [1], [1], [1], [1], [1], [1], [1], [1], [0], [0], [1], [1], [0], [0], [1], [0], [0], [1], [1], [0], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [3], [3], [1], [2], [4], [3], [4], [3], [2], [2], [4], [3], [3], [4], [4], [4], [4], [4], [4], [3], [4], [3], [2], [4], [4], [3], [4], [4], [2], [4], [3]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[130], [130], [120], [110], [108], [100], [130], [144], [160], [136], [160], [132], [128], [110], [145], [138], [132], [100], [130], [130], [140], [122], [140], [140], [122], [174], [135], [150], [110], [118], [140], [118]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[253], [256], [188], [211], [309], [248], [180], [193], [269], [319], [246], [207], [229], [175], [282], [271], [353], [299], [269], [264], [233], [286], [417], [294], [222], [249], [252], [243], [239], [210], [239], [277]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [1], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [2], [0], [2], [0], [2], [0], [0], [0], [2], [0], [0], [2], [0], [2], [2], [0], [2], [0], [2], [0], [2], [2], [2], [2], [0], [2], [2], [2], [0], [0], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[144], [149], [139], [144], [156], [122], [150], [141], [112], [152], [120], [168], [150], [123], [142], [182], [132], [125], [163], [143], [163], [116], [157], [153], [186], [143], [172], [128], [142], [192], [160], [151]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [1], [0], [0], [0], [0], [1], [0], [1], [1], [0], [0], [1], [0], [1], [1], [0], [0], [0], [1], [0], [0], [0], [1], [0], [0], [1], [0], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[1.4], [0.5], [2. ], [1.8], [0. ], [1. ], [0. ], [3.4], [2.9], [0. ], [0. ], [0. ], [0.4], [0.6], [2.8], [0. ], [1.2], [0.9], [0. ], [0.4], [0.6], [3.2], [0.8], [1.3], [0. ], [0. ], [0. ], [2.6], [1.2], [0.7], [1.2], [1. ]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [2], [2], [1], [2], [1], [2], [2], [1], [2], [1], [2], [1], [2], [1], [2], [2], [1], [2], [2], [2], [1], [2], [1], [2], [1], [2], [2], [1], [1], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [3], [0], [0], [0], [0], [2], [1], [2], [3], [0], [1], [0], [2], [0], [1], [2], [0], [0], [1], [2], [1], [0], [0], [0], [0], [0], [1], [0], [0], [1]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. 1/7 [===>..........................] - ETA: 0s - loss: 0.8235 - accuracy: 0.6562WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[47], [51], [57], [54], [56], [52], [42], [74], [57], [58], [55], [50], [56], [59], [52], [51], [41], [60], [34], [67], [45], [62], [56], [51], [57], [45], [53], [64], [59], [58], [56], [69]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [1], [0], [1], [1], [1], [0], [0], [1], [1], [1], [1], [1], [1], [0], [1], [0], [1], [0], [1], [1], [0], [1], [1], [1], [1], [1], [1], [1], [0], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [3], [3], [3], [4], [2], [4], [2], [2], [3], [4], [4], [4], [1], [4], [4], [3], [4], [1], [3], [1], [2], [4], [3], [2], [4], [3], [1], [1], [4], [4], [1]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[108], [140], [150], [110], [132], [120], [140], [120], [130], [132], [140], [144], [125], [170], [128], [130], [112], [150], [118], [152], [110], [128], [134], [125], [124], [115], [130], [170], [178], [128], [200], [160]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[243], [308], [168], [214], [184], [325], [226], [269], [236], [224], [217], [200], [249], [288], [255], [305], [250], [258], [182], [277], [264], [208], [409], [245], [261], [260], [197], [227], [270], [216], [288], [234]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [1], [0], [0], [1], [0], [0], [0], [1], [1]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [2], [0], [0], [2], [0], [0], [2], [2], [2], [0], [2], [2], [2], [0], [0], [0], [2], [2], [0], [0], [2], [2], [2], [0], [2], [2], [2], [2], [2], [2], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[152], [142], [174], [158], [105], [172], [178], [121], [174], [173], [111], [126], [144], [159], [161], [142], [179], [157], [174], [172], [132], [140], [150], [166], [141], [185], [152], [155], [145], [131], [133], [131]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [1], [0], [0], [1], [0], [0], [1], [1], [1], [0], [1], [1], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [1], [1], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[0. ], [1.5], [1.6], [1.6], [2.1], [0.2], [0. ], [0.2], [0. ], [3.2], [5.6], [0.9], [1.2], [0.2], [0. ], [1.2], [0. ], [2.6], [0. ], [0. ], [1.2], [0. ], [1.9], [2.4], [0.3], [0. ], [1.2], [0.6], [4.2], [2.2], [4. ], [0.1]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [1], [2], [2], [1], [1], [1], [2], [1], [3], [2], [2], [2], [1], [2], [1], [2], [1], [1], [2], [1], [2], [2], [1], [1], [3], [2], [3], [2], [3], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [0], [0], [1], [0], [0], [1], [1], [2], [0], [0], [1], [0], [1], [0], [0], [2], [0], [1], [0], [0], [2], [0], [0], [0], [0], [0], [0], [3], [2], [1]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'fixed'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[37], [55], [68], [29], [57], [45], [44], [44], [45], [54], [49], [58], [52], [46], [58], [41], [60], [60], [63], [40], [58], [57], [44], [52], [43], [66], [51], [63], [68], [43], [67], [62]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [1], [1], [0], [0], [1], [1], [0], [1], [0], [1], [1], [1], [1], [1], [1], [0], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [0], [1], [1], [0]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [4], [0], [2], [4], [2], [2], [4], [4], [4], [2], [4], [1], [4], [2], [2], [4], [3], [4], [4], [4], [2], [3], [4], [4], [4], [1], [4], [3], [4], [4], [3]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[130], [128], [144], [130], [120], [112], [120], [112], [138], [110], [134], [150], [118], [140], [120], [135], [117], [102], [140], [110], [114], [154], [140], [125], [150], [160], [125], [130], [120], [110], [160], [130]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[250], [205], [193], [204], [354], [160], [263], [290], [236], [206], [271], [270], [186], [311], [284], [203], [230], [318], [187], [167], [318], [232], [235], [212], [247], [228], [213], [254], [211], [211], [286], [263]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [2], [0], [0], [0], [2], [2], [2], [0], [2], [2], [0], [2], [0], [0], [0], [2], [2], [1], [2], [2], [0], [0], [2], [2], [2], [2], [0], [2], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[187], [130], [141], [202], [163], [138], [173], [153], [152], [108], [162], [111], [190], [120], [160], [132], [160], [160], [144], [114], [140], [164], [180], [168], [171], [138], [125], [147], [115], [161], [108], [ 97]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [0], [0], [1], [0], [0], [0], [1], [1], [0], [1], [0], [1], [0], [0], [1], [0], [1], [1], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [1], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[3.5], [2. ], [3.4], [0. ], [0.6], [0. ], [0. ], [0. ], [0.2], [0. ], [0. ], [0.8], [0. ], [1.8], [1.8], [0. ], [1.4], [0. ], [4. ], [2. ], [4.4], [0. ], [0. ], [1. ], [1.5], [2.3], [1.4], [1.4], [1.5], [0. ], [1.5], [1.2]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [2], [1], [1], [1], [2], [1], [1], [2], [2], [2], [1], [2], [2], [2], [2], [1], [1], [1], [2], [3], [1], [1], [1], [1], [1], [1], [2], [2], [1], [2], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [2], [0], [0], [0], [0], [1], [0], [1], [0], [0], [0], [2], [0], [0], [2], [1], [2], [0], [3], [1], [0], [2], [0], [0], [1], [1], [0], [0], [3], [1]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'fixed'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'fixed'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'fixed'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. 3/7 [===========>..................] - ETA: 0s - loss: 0.7040 - accuracy: 0.6979WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[46], [60], [67], [62], [59], [54], [54], [61], [57], [64], [42], [59], [62], [67], [38], [43], [54], [57], [59], [62], [58], [70], [57], [45], [53], [53], [51], [48], [41], [65], [53], [64]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [0], [1], [0], [1], [1], [1], [0], [1], [1], [1], [0], [1], [1], [1], [1], [1], [0], [0], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [4], [4], [4], [3], [3], [3], [4], [3], [4], [1], [0], [2], [3], [1], [4], [4], [4], [3], [4], [1], [4], [4], [4], [4], [3], [4], [2], [2], [1], [4], [3]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[142], [140], [125], [150], [150], [135], [150], [138], [150], [180], [148], [164], [120], [115], [120], [115], [120], [140], [126], [140], [150], [130], [165], [142], [142], [130], [140], [110], [110], [138], [123], [140]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[177], [293], [254], [244], [212], [304], [232], [166], [126], [325], [244], [176], [281], [564], [231], [303], [188], [192], [218], [268], [283], [322], [289], [309], [226], [246], [298], [229], [235], [282], [282], [335]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [1], [0], [1], [1], [0], [0], [1], [0], [0], [1], [0], [0], [0], [0], [0], [0], [1], [0], [1], [0], [1], [0], [0], [1], [0], [0], [0], [1], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [2], [0], [0], [0], [0], [2], [2], [0], [0], [2], [0], [2], [2], [0], [0], [0], [0], [0], [2], [2], [2], [2], [2], [2], [2], [0], [0], [0], [2], [0], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[160], [170], [163], [154], [157], [170], [165], [125], [173], [154], [178], [ 90], [103], [160], [182], [181], [113], [148], [134], [160], [162], [109], [124], [147], [111], [173], [122], [168], [153], [174], [ 95], [158]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [1], [0], [0], [0], [1], [0], [1], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [1], [1], [0], [1], [0], [0], [0], [1], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[1.4], [1.2], [0.2], [1.4], [1.6], [0. ], [1.6], [3.6], [0.2], [0. ], [0.8], [1. ], [1.4], [1.6], [3.8], [1.2], [1.4], [0.4], [2.2], [3.6], [1. ], [2.4], [1. ], [0. ], [0. ], [0. ], [4.2], [1. ], [0. ], [1.4], [2. ], [0. ]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [2], [2], [2], [1], [1], [1], [2], [1], [1], [1], [1], [2], [2], [2], [2], [2], [2], [2], [3], [1], [2], [2], [2], [1], [1], [2], [3], [1], [2], [2], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [2], [2], [0], [0], [0], [0], [1], [1], [0], [2], [2], [1], [0], [0], [0], [1], [0], [1], [2], [0], [3], [3], [3], [0], [3], [3], [0], [0], [1], [2], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'1'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'fixed'], [b'fixed'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[46], [57], [44], [42], [57], [43], [49], [41], [44], [63], [56], [62], [52], [43], [54], [58], [63], [71], [55], [62], [46], [52], [47], [61], [40], [50], [59], [47], [47], [62], [57], [64]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [1], [1], [1], [1], [1], [1], [0], [0], [1], [0], [1], [1], [1], [1], [1], [0], [0], [1], [0], [1], [1], [0], [1], [1], [1], [1], [1], [1], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [4], [4], [4], [4], [4], [2], [3], [3], [4], [1], [4], [4], [3], [4], [4], [4], [2], [4], [3], [4], [2], [4], [4], [1], [3], [1], [3], [3], [4], [4], [4]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[150], [152], [120], [136], [110], [120], [130], [130], [118], [124], [120], [140], [112], [130], [110], [100], [130], [160], [180], [130], [138], [134], [112], [130], [140], [129], [134], [138], [130], [120], [150], [145]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[231], [274], [169], [315], [335], [177], [266], [214], [242], [197], [193], [394], [230], [315], [239], [234], [330], [302], [327], [231], [243], [201], [204], [330], [199], [196], [204], [257], [253], [267], [276], [212]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [2], [0], [2], [0], [0], [2], [2], [0], [0], [0], [0], [2], [0], [1], [0], [2], [0], [0], [2], [0], [0], [0], [2], [0], [0], [2], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[147], [ 88], [144], [125], [143], [120], [171], [168], [149], [136], [162], [157], [160], [162], [126], [156], [132], [162], [117], [146], [152], [158], [143], [169], [178], [163], [162], [156], [179], [ 99], [112], [132]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [1], [1], [1], [0], [0], [0], [1], [0], [0], [0], [0], [1], [0], [1], [0], [1], [0], [1], [0], [0], [0], [1], [0], [0], [0], [0], [1], [1], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[3.6], [1.2], [2.8], [1.8], [3. ], [2.5], [0.6], [2. ], [0.3], [0. ], [1.9], [1.2], [0. ], [1.9], [2.8], [0.1], [1.8], [0.4], [3.4], [1.8], [0. ], [0.8], [0.1], [0. ], [1.4], [0. ], [0.8], [0. ], [0. ], [1.8], [0.6], [2. ]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [2], [3], [2], [2], [2], [1], [2], [2], [2], [2], [2], [1], [1], [2], [1], [1], [1], [2], [2], [2], [1], [1], [1], [1], [1], [1], [1], [1], [2], [2], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [0], [0], [1], [0], [0], [0], [1], [0], [0], [0], [1], [1], [1], [1], [3], [2], [0], [3], [0], [1], [0], [0], [0], [0], [2], [0], [0], [2], [1], [2]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'normal'], [b'reversible'], [b'fixed'], [b'fixed'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'fixed'], [b'fixed']], dtype=object)>} Consider rewriting this model with the Functional API. 5/7 [====================>.........] - ETA: 0s - loss: 0.6946 - accuracy: 0.7000WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[46], [61], [58], [42], [42], [50], [45], [43], [35], [56], [57], [37], [41], [58], [50], [56], [67], [44], [64], [44], [64], [44], [42], [43], [59], [67], [64], [50], [46], [66], [55], [39]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [1], [1], [1], [0], [1], [0], [1], [1], [0], [0], [0], [1], [0], [1], [1], [1], [0], [1], [1], [1], [0], [0], [1], [0], [1], [0], [1], [1], [0], [0]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [4], [4], [3], [2], [2], [4], [4], [4], [2], [4], [3], [2], [3], [3], [4], [4], [2], [3], [3], [4], [2], [4], [3], [4], [4], [3], [4], [4], [4], [2], [3]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[101], [148], [128], [120], [120], [120], [104], [132], [126], [120], [128], [120], [126], [105], [120], [130], [120], [120], [140], [130], [128], [130], [102], [122], [164], [106], [125], [110], [120], [120], [132], [ 94]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[197], [203], [259], [240], [295], [244], [208], [341], [282], [240], [303], [215], [306], [240], [219], [283], [237], [220], [313], [233], [263], [219], [265], [213], [176], [223], [309], [254], [249], [302], [342], [199]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [1], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [2], [0], [0], [0], [2], [2], [2], [0], [2], [0], [0], [2], [0], [2], [0], [0], [0], [0], [0], [2], [2], [0], [2], [0], [0], [2], [2], [2], [0], [0]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[156], [161], [130], [194], [162], [162], [148], [136], [156], [169], [159], [170], [163], [154], [158], [103], [ 71], [170], [133], [179], [105], [188], [122], [165], [ 90], [142], [131], [159], [144], [151], [166], [179]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [1], [0], [0], [0], [1], [1], [1], [0], [0], [0], [0], [1], [0], [1], [0], [0], [0], [1], [1], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[0. ], [0. ], [3. ], [0.8], [0. ], [1.1], [3. ], [3. ], [0. ], [0. ], [0. ], [0. ], [0. ], [0.6], [1.6], [1.6], [1. ], [0. ], [0.2], [0.4], [0.2], [0. ], [0.6], [0.2], [1. ], [0.3], [1.8], [0. ], [0.8], [0.4], [1.2], [0. ]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [2], [3], [1], [1], [2], [2], [1], [3], [1], [1], [1], [2], [2], [3], [2], [1], [1], [1], [2], [1], [2], [2], [2], [1], [2], [1], [1], [2], [1], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [2], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [2], [2], [0], [0], [0], [0], [0], [0]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'reversible'], [b'reversible'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'fixed'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[54]])>, 'sex': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[1]])>, 'cp': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[4]])>, 'trestbps': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[124]])>, 'chol': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[266]])>, 'fbs': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[0]])>, 'restecg': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[2]])>, 'thalach': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[109]])>, 'exang': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[1]])>, 'oldpeak': <tf.Tensor: shape=(1, 1), dtype=float64, numpy=array([[2.2]])>, 'slope': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[2]])>, 'ca': <tf.Tensor: shape=(1, 1), dtype=int64, numpy=array([[1]])>, 'thal': <tf.Tensor: shape=(1, 1), dtype=string, numpy=array([[b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. 7/7 [==============================] - ETA: 0s - loss: 0.6719 - accuracy: 0.7098WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[62], [65], [60], [35], [48], [66], [42], [44], [67], [71], [45], [65], [52], [76], [48], [51], [61], [51], [66], [51], [60], [52], [49], [57], [54], [68], [41], [62], [59], [45], [59], [55]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [1], [1], [1], [1], [0], [0], [1], [0], [1], [1], [1], [0], [1], [1], [1], [1], [0], [1], [0], [1], [1], [1], [1], [1], [0], [0], [1], [0], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[4], [4], [3], [2], [4], [4], [3], [3], [3], [3], [2], [4], [1], [3], [3], [4], [3], [3], [4], [4], [3], [3], [3], [4], [3], [3], [2], [4], [4], [2], [4], [4]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[124], [120], [140], [122], [124], [112], [120], [108], [152], [110], [128], [110], [152], [140], [124], [140], [150], [100], [178], [140], [120], [172], [118], [110], [120], [180], [105], [138], [140], [130], [135], [160]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[209], [177], [185], [192], [274], [212], [209], [141], [212], [265], [308], [248], [298], [197], [255], [299], [243], [222], [228], [261], [178], [199], [149], [201], [258], [274], [198], [294], [177], [234], [234], [289]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [1], [0], [1], [0], [1], [0], [1], [0], [1], [1], [0], [0], [0], [1], [0], [1], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [2], [0], [2], [2], [0], [0], [2], [2], [2], [2], [0], [1], [0], [0], [0], [0], [0], [2], [0], [0], [2], [0], [2], [2], [0], [0], [0], [2], [0], [2]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[163], [140], [155], [174], [166], [132], [173], [175], [150], [130], [170], [158], [178], [116], [175], [173], [137], [143], [165], [186], [ 96], [162], [126], [126], [147], [150], [168], [106], [162], [175], [161], [145]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [1], [1], [1], [1], [0], [0], [0], [1], [0], [1], [0], [0], [1], [0], [0], [1]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[0. ], [0.4], [3. ], [0. ], [0.5], [0.1], [0. ], [0.6], [0.8], [0. ], [0. ], [0.6], [1.2], [1.1], [0. ], [1.6], [1. ], [1.2], [1. ], [0. ], [0. ], [0.5], [0.8], [1.5], [0.4], [1.6], [0. ], [1.9], [0. ], [0.6], [0.5], [0.8]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [1], [2], [1], [2], [1], [2], [2], [2], [1], [1], [1], [2], [2], [1], [1], [2], [2], [2], [1], [1], [1], [1], [2], [2], [2], [1], [2], [1], [2], [2], [2]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [1], [0], [0], [0], [1], [0], [2], [0], [0], [2], [0], [0], [0], [2], [0], [0], [0], [3], [0], [0], [0], [1], [3], [1], [0], [0], [1]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible']], dtype=object)>} Consider rewriting this model with the Functional API. WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[77], [39], [60], [41], [56], [51], [59], [41], [60], [64], [64], [70], [62], [58], [58], [67], [35]])>, 'sex': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[1], [1], [1], [0], [1], [1], [1], [1], [1], [0], [1], [1], [0], [1], [0], [1], [0]])>, 'cp': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[4], [4], [4], [2], [3], [3], [2], [2], [4], [4], [4], [2], [4], [4], [4], [4], [4]])>, 'trestbps': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[125], [118], [130], [130], [130], [ 94], [140], [120], [125], [130], [120], [156], [160], [125], [130], [120], [138]])>, 'chol': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[304], [219], [206], [204], [256], [227], [221], [157], [258], [303], [246], [245], [164], [300], [197], [229], [183]])>, 'fbs': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[2], [0], [2], [2], [2], [0], [0], [0], [2], [0], [2], [2], [2], [2], [0], [2], [0]])>, 'thalach': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[162], [140], [132], [172], [142], [154], [164], [182], [141], [122], [ 96], [143], [145], [171], [131], [129], [182]])>, 'exang': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[1], [0], [1], [0], [1], [1], [1], [0], [1], [0], [1], [0], [0], [0], [0], [1], [0]])>, 'oldpeak': <tf.Tensor: shape=(17, 1), dtype=float64, numpy= array([[0. ], [1.2], [2.4], [1.4], [0.6], [0. ], [0. ], [0. ], [2.8], [2. ], [2.2], [0. ], [6.2], [0. ], [0.6], [2.6], [1.4]])>, 'slope': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[1], [2], [2], [1], [2], [1], [1], [1], [2], [2], [3], [1], [3], [1], [2], [2], [1]])>, 'ca': <tf.Tensor: shape=(17, 1), dtype=int64, numpy= array([[3], [0], [2], [0], [1], [1], [0], [0], [1], [2], [1], [0], [3], [2], [0], [2], [0]])>, 'thal': <tf.Tensor: shape=(17, 1), dtype=string, numpy= array([[b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'fixed'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. 7/7 [==============================] - 0s 41ms/step - loss: 0.6719 - accuracy: 0.7098 - val_loss: 0.5845 - val_accuracy: 0.7347 <tensorflow.python.keras.callbacks.History at 0x7f8188a50eb8>
loss, accuracy = model.evaluate(test_ds)
print("Accuracy", accuracy)
WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[66], [56], [41], [61], [54], [39], [63], [61], [52], [39], [60], [54], [57], [57], [69], [53], [44], [59], [53], [63], [57], [57], [58], [52], [48], [61], [48], [70], [71], [65], [47], [57]])>, 'sex': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [1], [0], [1], [1], [0], [0], [0], [1], [1], [0], [1], [0], [0], [1], [0], [1], [1], [1], [1], [1], [0], [0], [1], [0], [1], [1], [1], [0], [0], [1], [1]])>, 'cp': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[3], [2], [3], [4], [2], [3], [2], [4], [4], [3], [4], [3], [0], [4], [3], [4], [3], [1], [4], [1], [4], [1], [4], [2], [3], [1], [2], [4], [4], [3], [4], [0]])>, 'trestbps': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[146], [120], [112], [120], [192], [138], [140], [145], [108], [140], [158], [125], [140], [140], [140], [138], [120], [160], [140], [145], [130], [130], [170], [128], [130], [134], [130], [145], [112], [160], [110], [130]])>, 'chol': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[278], [236], [268], [260], [283], [220], [195], [307], [233], [321], [305], [273], [241], [241], [254], [234], [226], [273], [203], [233], [131], [236], [225], [205], [275], [234], [245], [174], [149], [360], [275], [131]])>, 'fbs': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [1], [0], [0], [1], [1], [0], [0], [0], [0], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [0], [2], [0], [2], [0], [0], [2], [0], [2], [2], [2], [1], [0], [2], [2], [0], [2], [2], [2], [0], [0], [2], [0], [0], [0], [2], [0], [0], [2], [2], [1]])>, 'thalach': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[152], [178], [172], [140], [195], [152], [179], [146], [147], [182], [161], [152], [123], [123], [146], [160], [169], [125], [155], [150], [115], [174], [146], [184], [139], [145], [180], [125], [125], [151], [118], [115]])>, 'exang': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[0], [0], [1], [1], [0], [0], [0], [1], [0], [0], [0], [0], [1], [1], [0], [0], [0], [0], [1], [0], [1], [0], [1], [0], [0], [0], [0], [1], [0], [0], [1], [1]])>, 'oldpeak': <tf.Tensor: shape=(32, 1), dtype=float64, numpy= array([[0. ], [0.8], [0. ], [3.6], [0. ], [0. ], [0. ], [1. ], [0.1], [0. ], [0. ], [0.5], [0.2], [0.2], [2. ], [0. ], [0. ], [0. ], [3.1], [2.3], [1.2], [0. ], [2.8], [0. ], [0.2], [2.6], [0.2], [2.6], [1.6], [0.8], [1. ], [1.2]])>, 'slope': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[2], [1], [1], [2], [1], [2], [1], [2], [1], [1], [1], [3], [1], [2], [2], [1], [1], [1], [3], [3], [2], [1], [2], [1], [1], [2], [2], [3], [2], [1], [2], [1]])>, 'ca': <tf.Tensor: shape=(32, 1), dtype=int64, numpy= array([[1], [0], [0], [1], [1], [0], [2], [0], [3], [0], [0], [1], [0], [0], [3], [0], [0], [0], [0], [0], [1], [1], [2], [0], [0], [2], [0], [0], [0], [0], [1], [1]])>, 'thal': <tf.Tensor: shape=(32, 1), dtype=string, numpy= array([[b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'fixed'], [b'reversible'], [b'2'], [b'fixed'], [b'normal'], [b'normal'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'normal'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. 1/2 [==============>...............] - ETA: 0s - loss: 0.3588 - accuracy: 0.8125WARNING:tensorflow:Layers in a Sequential model should only have a single input tensor, but we receive a <class 'dict'> input: {'age': <tf.Tensor: shape=(29, 1), dtype=int64, numpy= array([[66], [40], [55], [65], [58], [41], [61], [60], [52], [58], [54], [56], [58], [65], [54], [69], [63], [55], [54], [58], [65], [44], [59], [63], [48], [35], [45], [46], [51]])>, 'sex': <tf.Tensor: shape=(29, 1), dtype=int64, numpy= array([[0], [1], [0], [1], [0], [1], [1], [0], [0], [1], [0], [1], [1], [0], [0], [0], [0], [1], [0], [1], [0], [1], [1], [0], [1], [1], [1], [0], [0]])>, 'cp': <tf.Tensor: shape=(29, 1), dtype=int64, numpy= array([[1], [4], [2], [4], [3], [4], [4], [1], [3], [3], [3], [2], [3], [4], [3], [1], [4], [2], [2], [4], [3], [4], [4], [4], [4], [4], [3], [2], [3]])>, 'trestbps': <tf.Tensor: shape=(29, 1), dtype=int64, numpy= array([[150], [152], [135], [135], [120], [110], [140], [150], [136], [112], [160], [130], [140], [150], [108], [140], [150], [130], [132], [146], [155], [110], [170], [108], [130], [120], [110], [105], [120]])>, 'chol': <tf.Tensor: shape=(29, 1), dtype=int64, numpy= array([[226], [223], [250], [254], [340], [172], [207], [240], [196], [230], [201], [221], [211], [225], [267], [239], [407], [262], [288], [218], [269], [197], [326], [269], [256], [198], [264], [204], [295]])>, 'fbs': <tf.Tensor: shape=(29, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0]])>, 'restecg': <tf.Tensor: shape=(29, 1), dtype=int64, numpy= array([[0], [0], [2], [2], [0], [2], [2], [0], [2], [2], [0], [2], [2], [2], [2], [0], [2], [0], [2], [0], [0], [2], [2], [0], [2], [0], [1], [0], [2]])>, 'thalach': <tf.Tensor: shape=(29, 1), dtype=int64, numpy= array([[114], [181], [161], [127], [172], [158], [138], [171], [169], [165], [163], [163], [165], [114], [167], [151], [154], [155], [159], [105], [148], [177], [140], [169], [150], [130], [132], [172], [157]])>, 'exang': <tf.Tensor: shape=(29, 1), dtype=int64, numpy= array([[0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [0], [1], [0], [0], [0], [1], [1], [1], [1], [0], [0], [0]])>, 'oldpeak': <tf.Tensor: shape=(29, 1), dtype=float64, numpy= array([[2.6], [0. ], [1.4], [2.8], [0. ], [0. ], [1.9], [0.9], [0.1], [2.5], [0. ], [0. ], [0. ], [1. ], [0. ], [1.8], [4. ], [0. ], [0. ], [2. ], [0.8], [0. ], [3.4], [1.8], [0. ], [1.6], [1.2], [0. ], [0.6]])>, 'slope': <tf.Tensor: shape=(29, 1), dtype=int64, numpy= array([[3], [1], [2], [2], [1], [1], [1], [1], [2], [2], [1], [1], [1], [2], [1], [1], [2], [1], [1], [2], [1], [1], [3], [2], [1], [2], [1], [1], [1]])>, 'ca': <tf.Tensor: shape=(29, 1), dtype=int64, numpy= array([[0], [0], [0], [1], [0], [0], [1], [0], [0], [1], [1], [0], [0], [3], [0], [2], [3], [0], [1], [1], [0], [1], [0], [2], [2], [0], [0], [0], [0]])>, 'thal': <tf.Tensor: shape=(29, 1), dtype=string, numpy= array([[b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'normal'], [b'reversible'], [b'normal'], [b'reversible'], [b'reversible'], [b'normal'], [b'normal'], [b'normal']], dtype=object)>} Consider rewriting this model with the Functional API. 2/2 [==============================] - 0s 14ms/step - loss: 0.4201 - accuracy: 0.8197 Accuracy 0.8196721076965332
关键点:通常使用更大更复杂的数据集进行深度学习,您将看到最佳结果。使用像这样的小数据集时,我们建议使用决策树或随机森林作为强有力的基准。本教程的目的不是训练一个准确的模型,而是演示处理结构化数据的机制,这样,在将来使用自己的数据集时,您有可以使用的代码作为起点。
下一步
了解有关分类结构化数据的更多信息的最佳方法是亲自尝试。我们建议寻找另一个可以使用的数据集,并使用和上面相似的代码,训练一个模型,对其分类。要提高准确率,请仔细考虑模型中包含哪些特征,以及如何表示这些特征。