

本文為英文版的機器翻譯版本，如內容有任何歧義或不一致之處，概以英文版為準。

# 文字分類 - TensorFlow
<a name="text-classification-tensorflow"></a>

Amazon SageMaker AI 文字分類-TensorFlow 演算法是一種監督式學習演算法，可支援使用 [TensorFlow 中心](https://tfhub.dev/)中許多預先訓練的模型進行轉移學習。即使無法提供大量文字資料，您也可以使用轉移學習來微調自己的資料集上其中一個可用的預先訓練模型。文字分類演算法需要一個文字字串作為輸入，並針對每個類別標籤輸出一個機率。訓練資料集必須採用 CSV 格式。此頁面包含 Amazon EC2 執行個體推薦服務和文字分類 - TensorFlow 範例筆記本的相關資訊。

**Topics**
+ [如何使用 SageMaker AI 文字分類 - TensorFlow 演算法](text-classification-tensorflow-how-to-use.md)
+ [文字分類 - TensorFlow 演算法的輸入和輸出介面](text-classification-tensorflow-inputoutput.md)
+ [文字分類 - TensorFlow 演算法的 Amazon EC2 執行個體推薦服務](#text-classification-tensorflow-instances)
+ [文字分類 - TensorFlow 範例筆記本](#text-classification-tensorflow-sample-notebooks)
+ [文字分類 - TensorFlow 的運作方式](text-classification-tensorflow-HowItWorks.md)
+ [TensorFlow Hub 模型](text-classification-tensorflow-Models.md)
+ [文字分類 - TensorFlow 超參數](text-classification-tensorflow-Hyperparameter.md)
+ [調校文字分類 - TensorFlow 模型](text-classification-tensorflow-tuning.md)

## 文字分類 - TensorFlow 演算法的 Amazon EC2 執行個體推薦服務
<a name="text-classification-tensorflow-instances"></a>

文字分類 - TensorFlow 演算法支援所有 CPU 和 GPU 執行個體以進行訓練，包含：
+ `ml.p2.xlarge`
+ `ml.p2.16xlarge`
+ `ml.p3.2xlarge`
+ `ml.p3.16xlarge`
+ `ml.g4dn.xlarge`
+ `ml.g4dn.16.xlarge`
+ `ml.g5.xlarge`
+ `ml.g5.48xlarge`

建議您使用記憶體容量較多的 GPU 執行個體來進行大批次大小的訓練。CPU (例如 M5) 和 GPU (P2、P3、G4dn 或 G5) 執行個體都可用來進行推論。如需跨 AWS 區域 SageMaker 訓練和推論執行個體的完整清單，請參閱 [Amazon SageMaker 定價](https://aws.amazon.com/sagemaker/pricing/)。

## 文字分類 - TensorFlow 範例筆記本
<a name="text-classification-tensorflow-sample-notebooks"></a>

如需如何在自訂資料集上使用 SageMaker AI 文字分類 - TensorFlow 演算法進行轉移學習的更多相關資訊，請參閱 [JumpStart - 文字分類簡介](https://github.com/aws/amazon-sagemaker-examples/blob/main/introduction_to_amazon_algorithms/jumpstart_text_classification/Amazon_JumpStart_Text_Classification.ipynb)筆記本。

如需如何建立並存取 Jupyter 筆記本執行個體以用來執行 SageMaker AI 中範例的指示，請參閱[Amazon SageMaker 筆記本執行個體](nbi.md)。建立並開啟筆記本執行個體後，請選擇 **SageMaker AI 範例**索引標籤，查看所有 SageMaker AI 範例清單。若要開啟筆記本，請選擇其**使用**標籤，然後選擇**建立複本**。