From: Georgi Gerganov Date: Thu, 13 Apr 2023 21:02:31 +0000 (+0300) Subject: mnist : update README X-Git-Tag: upstream/0.0.1642~1547 X-Git-Url: https://git.djapps.eu/?a=commitdiff_plain;h=75a266daf8895599a48a63e7d80c9ebc1f3cb672;p=pkg%2Fggml%2Fsources%2Fggml mnist : update README --- diff --git a/examples/mnist/README.md b/examples/mnist/README.md index 6b344705..bb088884 100644 --- a/examples/mnist/README.md +++ b/examples/mnist/README.md @@ -17,9 +17,9 @@ plus the model weights and biases. Run convert-h5-to-ggml.py to convert your pyt - magic constant (int32) - repeated list of tensors --- number of dimensions of tensor (int32) --- tensor dimension (int32 repeated) --- values of tensor (int32) +- number of dimensions of tensor (int32) +- tensor dimension (int32 repeated) +- values of tensor (int32) Run ```convert-h5-to-ggml.py mnist_model.state_dict``` where `mnist_model.state_dict` is the saved pytorch model from the Google Colab. For quickstart, it is included in the mnist/models directory. @@ -43,6 +43,7 @@ make -j4 mnist # Run the MNIST model ./bin/mnist ../examples/mnist/models/mnist/ggml-model-f32.bin ../examples/mnist/models/mnist/t10k-images.idx3-ubyte +``` For more information, checkout the corresponding programs in the [examples](examples) folder. @@ -85,3 +86,7 @@ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ ggml_graph_dump_dot: dot -Tpng mnist.dot -o mnist.dot.png && open mnist.dot.png Predicted digit is 9 ``` + +Computation graph: + +![mnist dot](https://user-images.githubusercontent.com/1991296/231882071-84e29d53-b226-4d73-bdc2-5bd6dcb7efd1.png)