Questions tagged [fastai]

Fastai is a deep learning library for Python. It is built on top of PyTorch, and provides high level API to various common deep learning applications and data types. For more information see: https://docs.fast.ai or https://github.com/fastai

Filter by
Sorted by
Tagged with
0 votes
1 answer
6 views

Bad performance with CNN for basic image classification task

how are you doing? I'm playing around with CNN in FastAI. My model with 2 millions parameters only has around 80% accuracy. I also tried with Data normalization, Batch normalization, Label smoothing, ...
0 votes
0 answers
17 views

The best approach and library for time-series similarity

I have a time-series classification problem with IoT signals. The training dataset has seven target signals. I used tsai as a fastai/torch library, and I achieved satisfying results. However, in a ...
  • 3
0 votes
0 answers
12 views

How to improve neural network for face classification?

I generated 700 1024x1024 images of female faces using an API. I labelled them either as attractive or unattractive. The neural net should learn which face I find attractive and which not. But the ...
0 votes
0 answers
30 views

How to use a Swin Transformer with metric learning?

Using timm's implementation of Swin Transformer, how does one generate an embedding vector? I would like to use timm's ...
0 votes
0 answers
14 views

ImageDataLoader inconsistent in fastai?

I am training a convolutional neural network using fastai. I use a ImageDataLoaders to fetch data from my directory. However, I notice that results of my confusion matrix change if I use another data ...
0 votes
0 answers
77 views

How to evaluate reliably a model using fastai

I’m new to fastai and don’t quite well grab some concepts. There are some questions I have : When using fit_one_cycle, a result table is obtained at the end. How is the error_rate in this case ...
0 votes
1 answer
148 views

AttributeError: normalize fastai

I'm trying to use fastai to train a model however I get this error when I try to normalize my data using imagenet stats. After searching for a while, I can't find any valid substitute for this line. ...
0 votes
0 answers
38 views

How to visualise Databunch object in FASTAI

So I have been working on an object detection problem and I loaded my databunch object from the image list in fastai but I am not able to fully understand what kind of patches or images are genuinely ...
0 votes
0 answers
64 views

not able to show evaluation metrics for object detection on MSCOCO like dataset using FASTAI

I want to show evaluation metrics for coco object detection,I have saved my learner in .pth file and I have data in variable data(databunch type fastai) , I have the code from the notebook finding ...
0 votes
0 answers
266 views

I need to plot only training curve in the fastai library using the learner.recorder.plot_losses() function . FASTAI devs pls help

I have a task where I need to only plot the training loss and not the validation loss of the plot_losses function in the fastai library with learner object having ...
0 votes
0 answers
13 views

How to get significativity for tabular data in machine learning?

Im using fastai to train a network on tabular data (https://docs.fast.ai/tutorial.tabular.html). I have a table with 5 columns, each of these is the specific attribute that describes a galaxy and ...
0 votes
0 answers
52 views

From what function do come the gradients that I use to adjust weights?

I have a question about the loss function and the gradient. So I'm following the fastai (https://github.com/fastai/fastbook) course and at the end of 4th chapter, I got myself wondering. From what ...
0 votes
1 answer
93 views

Colab variable inspector stops working after importing from fastbook

As best as I could find, this question was not asked before. I'm using colab, and I use its variable inspector. I'm trying to do the FastAI exercices, and I noticed that when doing them, the variable ...
  • 1
0 votes
0 answers
23 views

Fine-grained image classification

I have a dataset which has 4 classes (say A,B,C,D). The task requires fine-grained image classification. The problem I am facing is that for 2 of the classes (C,D), the model's performance is not so ...
0 votes
1 answer
106 views

How to handle imbalanced NLP text data set e.g. some classes only have 2 records

I am working on a dataset with around 2000 records. Around 80% records have their the categorical labels. There are around 200 categories, some categories got more than 20 records; whereas others only ...
  • 133
4 votes
2 answers
80 views

Is it advisable to use a model which is underfit but gives very high accuracy?

I am training a model for a single-label classification task in Vision. In this training, I am using oversampling of all the classes, and MixUp augmentation, along with rotation and dihedral ...
  • 280
0 votes
2 answers
91 views

Fast AI Lesson 4 - MNIST. Confused about multiplying weights by pixels?

I’m on lesson 4 of the Fast AI "Deep Learning for Coders" course, and have been back through the same lesson a few times now but I don’t think I’m quite getting a few things. I want to have ...
  • 101
3 votes
1 answer
118 views

How to specify version for dependencies so that each one is compatible and stays within a size limit?

I am trying to deploy a web app to Heroku. The free tier is limited to 500 MB. I am using my resnet34 model as a .pkl file. I create model with it using the fastai ...
  • 280
1 vote
2 answers
2k views

How imagenet mean and std derived?

To use pre-trained models it is a preferred practice to normalize the input images with imagenet standards. mean=[0.485, 0.456, 0.406] and ...
  • 299
1 vote
1 answer
428 views

fastai - using 'untar_data' function in kaggle kernel

I have recently started with fastai lesson 1 and I am using kaggle to run the course notebooks. While going through the ‘lesson1-pets’ notebook we use ...
  • 141
1 vote
1 answer
56 views

Classification with a lot of the classes

I’m trying to make model which will classify text into about 500 different classes. I think that I have to customize architecture of the Pooling Classifier which looks now like this: ...
1 vote
0 answers
49 views

Improve performance of my CNN model

I am working on an image classification problem. There are 876 images in the training and 600 in the test dataset. It is a multi class classification for plants. Since this is my first CNN problem, ...
2 votes
2 answers
778 views

Face recognition - How to make an image classifier with large number of classes?

I am planning to make an image classifier that identifies the face of every player in the English Premier League. I have a couple of questions (since until now I have only worked with small or ...
  • 163
1 vote
1 answer
90 views

Arguments in python fast.ai function that are not in the function definition?

I have been coming across function calls that use arguments that are not in the function definition. I would like to know how that works (i.e. how the compiler interprets this). For example, this ...