# Model conversion issue : yusuf802/Leaf-Disease-Predictor

**URL:** </static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fmodel-conversion-issue-yusuf802-leaf-disease-predictor%2F108052%3E%5C
**Category:** Models\
**Created:** [September 23, 2024, 6:33am UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fmodel-conversion-issue-yusuf802-leaf-disease-predictor%2F108052 "2024-09-23T06:33:21Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ShubhamGhait](https://avatars.discourse-cdn.com/v4/letter/s/da6949/32.png) [@ShubhamGhait](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2FShubhamGhait)%5C
**Post date:** [September 23, 2024, 6:33am UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fmodel-conversion-issue-yusuf802-leaf-disease-predictor%2F108052%2F1 "2024-09-23T06:33:21Z")

</div>

Coud you guide for the below issue:  
I am trying to convert leaf disease pytorch pretrained into tflite.  
but facing issue related unsqueeze dimension and tensor flow back end is not supported. while convert from safe-tensor model to onnx(while opset\< 13) and onnx to .pb model (while opset \> 13).

---

<div class="post-metadata">

**Author:** ![John6666](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/john6666/32/27664_2.png) [@John6666](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2FJohn6666)%5C
**Post date:** [September 23, 2024, 7:15am UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fmodel-conversion-issue-yusuf802-leaf-disease-predictor%2F108052%2F2 "2024-09-23T07:15:52Z")

</div>

> **[onnx-community (ONNX Community)](https://huggingface.co/onnx-community)**
>
> Org profile for ONNX Community on Hugging Face, the AI community building the future.

Of course you can use the forum, but I think you’ll get an answer very quickly if you go to the ONNX community, randomly select a repo and open a Discussion and ask. It’s quite hard to get the author to realise you’re talking about a problem on a forum…

Have you tried this already?

> [@How can I export a transformers model into onnx that not supported with optimum yet](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fhow-can-i-export-a-transformers-model-into-onnx-that-not-supported-with-optimum-yet%2F104590%2F8)%3A
>
> Hi, The easiest is to do it as explained in this guide: [Convert Transformers to ONNX with Hugging Face Optimum](https://www.philschmid.de/convert-transformers-to-onnx#export-with-torchonnx-low-level). You can use torch.onnx.export, which is more low-level than Optimum. Feel free to open an issue on the [Optimum repository](https://github.com/huggingface/optimum) to add support for RT-DETR.
