To Find optimal clustering number using silhouette metrics
It evaluate clustering resulting in every k number of KMean algorithm.
And show it as figure.
Lager value is better result.
..
..
For example here, 20 k is best clustering result.
To Find optimal clustering number using silhouette metrics
It evaluate clustering resulting in every k number of KMean algorithm.
And show it as figure.
Lager value is better result.
..
..
For example here, 20 k is best clustering result.
Refer to code
..
..
output
lsb_release -a
Make path using pathlib.
refer to code
..
..
www.marearts.com
Simple code to adapt and know how to read yaml and convert it to dict.
And one more thing is add argparse param to dict which is made from yaml.
We use easydict for this.
Refer to below code, then you would understand at a glance.
..
..
Thank you.
www.marearts.com
..
!python -m transformers.onnx --model=./checkpoint-21-epoch-11 --feature=token-classification onnx/
..
Refer to code to figure it out
how tokens consisted for a word.
Code show you tokens list for a word.
..
..
input sentence: This is a tokenization example --- tokens : [713, 16, 10, 19233, 1938, 1246] --- word and tokens : {'This': [713], 'is': [354], 'a': [102], 'tokenization': [46657, 1938], 'example': [46781]} --- tokens in grouped list [[1], [2], [3], [4, 5], [6]] ---
Thank you.
www.marearts.com
..
..
{'a': 1, 'c': 3, 'b': 2, 'd': 4}
BERT Tokenizer token understanding examples
..
..
output:
Tokens: ['I', 'ฤ am', 'ฤ e', '/', 'mail'] Tokens length: 5 Encoding: [0, 100, 524, 364, 73, 6380, 2] Encoding length: 7 token to string: I am e/mail
--
Thank you.
www.marearts.com
refer to code
..
..
I am a humen <class 'str'>
Thank you.