GithubHelp home page GithubHelp logo

dramemariama / packt_nlp_tensorflow_2 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from thushv89/packt_nlp_tensorflow_2

0.0 1.0 0.0 5.8 MB

This will contain the code for the 2nd edition of NLP with TensorFlow (Edition 2)

Python 0.23% Jupyter Notebook 99.64% Roff 0.13%

packt_nlp_tensorflow_2's Introduction

Natural Language Processing with TensorFlow-2nd-Edition

Copyright © 2022 Packt Publishing, Thushan Ganegedara


This project is the code repository for Natural Language Processing with TensorFlow, Second Edition.

Getting Started

You can run these notebooks on cloud platforms like Google Colab or your local machine. Note that some chapters require a GPU to run in a reasonable amount of time, so we recommend one of the cloud platforms as they come pre-installed with CUDA.

Chapters Colab Kaggle Gradient StudioLab
Understanding TensorFlow 2
  • tensorflow_introduction.ipynb
Open In Colab Kaggle Gradient Open In SageMaker Studio Lab
Word2vec – Learning Word Embeddings
  • ch3_word2vec.ipynb
  • ch3_wordnet.ipynb
Open In Colab Open In Colab Kaggle Kaggle Gradient Gradient Open In SageMaker Studio Lab Open In SageMaker Studio Lab
Advanced Word Vector Algorithms
  • ch4_document_classification.ipynb
  • ch4_elmo_embeddings.ipynb
  • ch4_glove.ipynb
Open In Colab Open In Colab Open In Colab Kaggle Kaggle Kaggle Gradient Gradient Gradient Open In SageMaker Studio Lab Open In SageMaker Studio Lab Open In SageMaker Studio Lab
Sentence Classification with Convolution Neural Networks
  • ch5_cnn_sentence_classification.ipynb
  • ch5_image_classification_fashion_mnist.ipynb
Open In Colab Open In Colab Kaggle Kaggle Gradient Gradient Open In SageMaker Studio Lab Open In SageMaker Studio Lab
Recurrent Neural Networks
  • ch06_rnns_for_named_entity_recognition.ipynb
Open In Colab Kaggle Gradient Open In SageMaker Studio Lab
Applications of LSTM – Generating Text
  • ch08_lstms_for_text_generation.ipynb
Open In Colab Kaggle Gradient Open In SageMaker Studio Lab
Sequence-to-Sequence Learning – Neural Machine Translation
  • ch09_seq2seq.ipynb
Open In Colab Kaggle Gradient Open In SageMaker Studio Lab
Transformers
  • ch10_transformers.ipynb
Open In Colab Kaggle Gradient Open In SageMaker Studio Lab
Image captioning with Transformers
  • ch11_image_captions.ipynb
Open In Colab Kaggle Gradient Open In SageMaker Studio Lab
Appendix
  • tensorboard_word_embeddings.ipynb
Open In Colab Kaggle Gradient Open In SageMaker Studio Lab

Prerequisites for running the notebooks on your local machine(GPU support)

  • Install the latest NVIDIA driver for your GPU from this page
  • Install CUDA 10.2 (TensorFlow 2.3)
  • Setup CuDNN
  • Make sure your $PATH variable contains the path to the bin folder of cuda (e.g. On Windows - C:\CUDA\v10.2\bin)
    • On UNIX - Set LD_LIBRARY_PATH to lib64 folder (e.g. /usr/local/cuda-10.2/lib64)

Creating a Virtual Environment (Anaconda) (Recommended)

  • Install Anaconda
  • Open up Anaconda Prompt
  • Setup a conda virtual environment with conda create -n packt.nlp.2 python=3.6
  • Activate the environment with conda activate packt.nlp.tf2
  • Install the required libraries using pip install -r requirements.txt

Important notes

  • For some plotting capability provided in TensorFlow/Keras, you have installed a Python package called graphviz. You might need to add the path to this library (e.g. <path to Anaconda>\envs\packt.nlp.tf2\Library\bin\graphviz if you used Anaconda installation)

Getting Jupyter Notebook server up

Now you are ready to run the Jupyter notebook server, allowing you to run the notebooks provided in the code repository.

  • Open up the command line terminal and activate the virtual environment packt.nlp.tf2 if you haven't already
  • Go in to the directory you downloaded code to using cd in the CLI (e.g. cd C:\Users\<user>\Documents\code\packt_nlp_tensorflow_2)
  • Run jupyter notebook in the CLI
  • This should open up the jupyter notebook server's landing page on your default browser
  • Now you can navigate the folder structure within that directory, open any notebook and run it.

packt_nlp_tensorflow_2's People

Contributors

thushv89 avatar msktejas avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.