关于“Classifying Structured Data using Keras Preprocessing Layers”的评价

11219 条评价

There was an error in the code, because of which the notebook wasn't executable.

Abhirama G. · 已于 almost 3 years前审核

good

utpal d. · 已于 almost 3 years前审核

Jeff H. · 已于 almost 3 years前审核

Diogo F. · 已于 almost 3 years前审核

AttributeError: 'StringLookup' object has no attribute 'vocabulary_size' def get_category_encoding_layer(name, dataset, dtype, max_tokens=None): # Create a StringLookup layer which will turn strings into integer indices if dtype == 'string': index = preprocessing.StringLookup(max_tokens=max_tokens) else: index = preprocessing.IntegerLookup(max_tokens=max_tokens) # TODO # Prepare a Dataset that only yields our feature feature_ds = dataset.map(lambda x, y: x[name]) # Learn the set of possible values and assign them a fixed integer index. index.adapt(feature_ds) # Create a Discretization for our integer indices. encoder = preprocessing.CategoryEncoding(num_tokens=index.vocabulary_size()) # Apply one-hot encoding to our indices. The lambda function captures the # layer so we can use them, or include them in the functional model later. return lambda feature: encoder(index(feature))

Nikolas H. · 已于 almost 3 years前审核

very clear lab, thanks!

Yulia P. · 已于 almost 3 years前审核

Babu L. · 已于 almost 3 years前审核

ramya h. · 已于 almost 3 years前审核

Ze M. · 已于 almost 3 years前审核

Satomi S. · 已于 almost 3 years前审核

Noushin S. · 已于 almost 3 years前审核

fermin h. · 已于 almost 3 years前审核

Mahdieh K. · 已于 almost 3 years前审核

Pratibha C. · 已于 almost 3 years前审核

Pablo V. · 已于 almost 3 years前审核

Shahrukh K. · 已于 almost 3 years前审核

Dominic L. · 已于 almost 3 years前审核

Yechi M. · 已于 almost 3 years前审核

Lorrain G. · 已于 almost 3 years前审核

Carlos G. · 已于 almost 3 years前审核

Luo,Shuyan L. · 已于 almost 3 years前审核

Sabyasachi B. · 已于 almost 3 years前审核

Naganjana R. · 已于 almost 3 years前审核

Kalluri Siva Kumar R. · 已于 almost 3 years前审核

Sean A. · 已于 almost 3 years前审核

我们无法确保发布的评价来自已购买或已使用产品的消费者。评价未经 Google 核实。