handson-ml3 icon indicating copy to clipboard operation
handson-ml3 copied to clipboard

add get_vocabulary() to see the learned vocabulary

Open vvaezian opened this issue 1 year ago • 1 comments

Added a cell in "Chapter13/Text Processing".
This would explain the output of text_vec_layer(["Be good!", "Question: be or be?"]). I suggest adding it to the PDF version as well.

>>> text_vec_layer.get_vocabulary()
['', '[UNK]', 'be', 'to', 'the', 'thats', 'question']

vvaezian avatar Mar 16 '23 17:03 vvaezian

The issue with previous the PR was with line endings for images on Windows, which was messing up diffs.

vvaezian avatar Mar 16 '23 19:03 vvaezian