Update 02_key-features.md (#8558)

I noticed that the type mentioned in the figure (int) and the description (float) were inconsistent.

I've also included some additional text corrections.

Co-authored-by: Ali Abdalla <ali.si3luwa@gmail.com>
This commit is contained in:
Makoto Tanji 2024-06-15 21:28:06 +09:00 committed by GitHub
parent 71624039d2
commit 3722542199
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -35,7 +35,7 @@ Consider an example demo with three input components (`gr.Textbox`, `gr.Number`,
In this image, the following preprocessing steps happen to send the data from the browser to your function:
* The text in the textbox is converted to a Python `str` (essentially no preprocessing)
* The number in the number input in converted to a Python `float` (essentially no preprocessing)
* The number in the number input is converted to a Python `int` (essentially no preprocessing)
* Most importantly, ihe image supplied by the user is converted to a `numpy.array` representation of the RGB values in the image
Images are converted to NumPy arrays because they are a common format for machine learning workflows. You can control the _preprocessing_ using the component's parameters when constructing the component. For example, if you instantiate the `Image` component with the following parameters, it will preprocess the image to the `PIL` format instead: