Techno Blender
Digitally Yours.
Browsing Tag

Politi

Feature Extraction with BERT for Text Classification | by Marcello Politi | Jun, 2022

Photo by Sigmund on UnsplashExtract information from a pretrained model using Pytorch and Hugging FaceGoalLet’s begin by defining what our purpose is for this hands-on article. We want to build a model that takes as input one or more documents, and manages to classify them by their content. Some categories are for example : politics, travel , sports, etc.To do this we want to use a pretrained model such as BERT.Image By AuthorBackgroundBERT is a language model based heavily on the Transformer encoder. If you are…

Binary Image Classification in PyTorch | by Marcello Politi | May, 2022

Photo by Clément Hélardot on UnsplashTrain a convolutional neural network adopting a transfer learning approachI personally approached deep learning using TensorFlow, which I immediately found very easy and intuitive. Many books also use this framework as a reference, such as Hands-On Machine Learning with Scikit-Learn, Keras, and Tensorflow.I then noticed that PyTorch is often used in research in both academia and industry. So I started to implement simple projects that I had already developed in TensorFlow using…

Skip-Gram Neural Network from scratch | by Marcello Politi | May, 2022

Photo by nadi borodina on UnsplashDeep dive in non-contextual NLP with Skip-Gram and CBOWThe field of natural language processing is challenging for several reasons, but the main and most trivial one is that of handling data that is not numerical, but text.Therefore, there is a need for a transformation from text to numerical values that can preserve the meaning of the word as much as possible, without losing whatever the word evokes in the human mind.This transformation is known as Word Embedding. We can go to a lower…