# Autotrain image classification 500 error

**URL:** </static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fautotrain-image-classification-500-error%2F68798%3E%5C
**Category:** 🤗AutoTrain\
**Created:** [January 11, 2024, 3:44pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fautotrain-image-classification-500-error%2F68798 "2024-01-11T15:44:17Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Aaron171](https://avatars.discourse-cdn.com/v4/letter/a/858c86/32.png) [@Aaron171](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2FAaron171)%5C
**Post date:** [January 11, 2024, 3:44pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fautotrain-image-classification-500-error%2F68798%2F1 "2024-01-11T15:44:17Z")

</div>

I am trying to use autotrain’s image classification but everytime I upload the data and it processes it, it throws a 500 error and this in the logs - I am using the file format mentioned in the docs here [Image Classification](https://huggingface.co/docs/autotrain/main/en/image_classification)

> INFO Task: llm:sft  
> INFO: 10.16.34.18:39034 - “GET /params/llm%3Asft HTTP/1.1” 200 OK  
> INFO: 10.16.18.44:16135 - “GET /model\_choices/llm%3Asft HTTP/1.1” 200 OK  
> INFO Task: image-classification  
> INFO: 10.16.18.44:36314 - “GET /params/image-classification HTTP/1.1” 200 OK  
> INFO: 10.16.18.44:23915 - “GET /model\_choices/image-classification HTTP/1.1” 200 OK  
> INFO hardware: A100 Large  
> INFO Dataset: autotrain-images-category-10 (image\_multi\_class\_classification)  
> Train data: \<tempfile.SpooledTemporaryFile object at 0x7fd1d0fa9090\>  
> Valid data: \<tempfile.SpooledTemporaryFile object at 0x7fd1d0faa470\>

I also see this in the console -  
Error: 500   
Uncaught (in promise) SyntaxError: JSON.parse: unexpected end of data at line 1 column 1 of the JSON data

I’m thinking it’s because of the column mapping? It’s expecting {“image”: “image”, “label”: “label”} which is different to what the docs say which is just to use a zipped folder containing the classes that then contain the images?

---

<div class="post-metadata">

**Author:** ![Aaron171](https://avatars.discourse-cdn.com/v4/letter/a/858c86/32.png) [@Aaron171](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2FAaron171)%5C
**Post date:** [January 11, 2024, 3:55pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fautotrain-image-classification-500-error%2F68798%2F2 "2024-01-11T15:55:43Z")

</div>

cc @abhishek

---

<div class="post-metadata">

**Author:** ![abhishek](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/abhishek/32/32360_2.png) [@abhishek](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2Fabhishek)%5C
**Post date:** [January 11, 2024, 4:00pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fautotrain-image-classification-500-error%2F68798%2F3 "2024-01-11T16:00:27Z")

</div>

I just ran a training and it seems to be working as expected:

 ![image](https://us1.discourse-cdn.com/hellohellohello/original/3X/3/4/34f2e810cd3a2f1a052c72c08d6dfc168d656fb1.png)

When the zip is unzipped, it must produce all subfolders with different classes, not one folder. please also add logs so we know whats happening 🙂
