mohd-faizy / 10P_Transfer-Learning-for-NLP-with-TensorFlow-Hub

we will use pre-trained NLP text embedding models from TensorFlow Hub, perform transfer learning to fine-tune models on real-world data, build and evaluate multiple models for text classification with TensorFlow, and visualize model performance metrics with Tensorboard.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

author made-with-Markdown Language Platform Maintained Last Commit GitHub issues Open Source Love svg2 Stars GitHub Size

Transfer-Learning-for-NLP-with-TensorFlow-Hub

Transfer learning is a research problem in machine learning that focuses on storing knowledge gained while solving one problem and applying it to a different but related problem. For example, knowledge gained while learning to recognize cars could apply when trying to recognize trucks.

TensorFlow Hub is a repository of pre-trained TensorFlow models.

Objectives

In this project, we will use pre-trained models from TensorFlow Hub with tf.keras for text classification. we will Use pre-trained NLP text embedding models from TensorFlow Hub Perform transfer learning to fine-tune models on real-world text data, build and evaluate multiple models for text classification with TensorFlow, and visualize model performance metrics with Tensorboard.

Prerequisites: Python programming language, be familiar with deep learning for Natural Language Processing (NLP), and have trained models with TensorFlow or and its Keras API.

Dataset

A downloadable copy of the Quora Insincere Questions Classification data can be found https://archive.org/download/fine-tune-bert-tensorflow-train.csv/train.csv.zip. Decompress and read the data into a pandas DataFrame.

Project Structure

The hands on project on Transfer Learning for NLP with TensorFlow Hub is divided into following tasks:

  • Task 0️⃣1️⃣ Introduction to the Project
  • Task 0️⃣2️⃣ Setup your TensorFlow and Colab Runtime
  • Task 0️⃣3️⃣ Load the Quora Insincere Questions Dataset
  • Task 0️⃣4️⃣ TensorFlow Hub for Natural Language Processing
  • Task 0️⃣5️⃣ & 0️⃣6️⃣ Define Function to Build and Compile Models
  • Task 0️⃣1️⃣ Train Various Text Classification Models
  • Task 0️⃣7️⃣ Compare Accuracy and Loss Curves
  • Task 0️⃣8️⃣ Fine-tune Model from TF Hub
  • Task 0️⃣9️⃣ Train Bigger Models and Visualize Metrics with TensorBoard

Visualize model performance metrics with TensorBoard

Accuracy Curves for Models

Loss Curves for Models

Visualization of Metrics with TensorBoard

epoch accuracy

epoch loss

Connect with me:

codeSTACKr | Twitter codeSTACKr | LinkedIn codeSTACKr.com


Faizy's github stats

Top Langs

About

we will use pre-trained NLP text embedding models from TensorFlow Hub, perform transfer learning to fine-tune models on real-world data, build and evaluate multiple models for text classification with TensorFlow, and visualize model performance metrics with Tensorboard.


Languages

Language:Jupyter Notebook 100.0%