# Looking for classifier (Silva, V3-V4) generated with scikit-learn version 0.21.2

**URL:** <https://forum.qiime2.org/t/looking-for-classifier-silva-v3-v4-generated-with-scikit-learn-version-0-21-2/11135>\
**Category:** User Support\
**Created:** [August 18, 2019, 2:36am UTC](https://forum.qiime2.org/t/looking-for-classifier-silva-v3-v4-generated-with-scikit-learn-version-0-21-2/11135 "2019-08-18T02:36:52Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Daniela\_Vargas](https://forum.qiime2.org/user_avatar/forum.qiime2.org/daniela_vargas/32/5525_2.png) [@Daniela\_Vargas](https://forum.qiime2.org/u/Daniela_Vargas)\
**Post date:** [August 18, 2019, 2:36am UTC](https://forum.qiime2.org/t/looking-for-classifier-silva-v3-v4-generated-with-scikit-learn-version-0-21-2/11135/1 "2019-08-18T02:36:52Z")

</div>

Hello!  
I am looking for a naive-bayes classifier based on Silva reference database for V3-V4 region, 341F, 805R, generated with scikit-learn version 0.21.2.

I have not been able of running it due to memory errors. I also tried to follow [Mehrbod\_Estak](https://forum.qiime2.org/u/Mehrbod_Estaki) advise: [Looking for Pre-trained Silva Classifier (V3-V4) - #3 by jwchen](https://forum.qiime2.org/t/looking-for-pre-trained-silva-classifier-v3-v4/9028/3), but I could not solve it.

I found a poster that would kindly provided this classifier ([Looking for Pre-trained Silva Classifier (V3-V4) - #3 by jwchen](https://forum.qiime2.org/t/looking-for-pre-trained-silva-classifier-v3-v4/9028/3) by [jwchen](https://forum.qiime2.org/u/jwchen)). However it was generated with scikit-learn version 0.20.2, so it is not compatible with the most updated version 0.21.2.

Thanks for your help and to QIIME2 developers!

---

<div class="post-metadata">

**Author:** ![Nicholas\_Bokulich](https://forum.qiime2.org/user_avatar/forum.qiime2.org/nicholas_bokulich/32/19937_2.png) [@Nicholas\_Bokulich](https://forum.qiime2.org/u/Nicholas_Bokulich)\
**Post date:** [August 18, 2019, 2:43am UTC](https://forum.qiime2.org/t/looking-for-classifier-silva-v3-v4-generated-with-scikit-learn-version-0-21-2/11135/2 "2019-08-18T02:43:01Z")

</div>

Hi @Daniela_Vargas,

> [@Daniela\_Vargas](#):
>
> I found a poster that would kindly provided this classifier ([Looking for Pre-trained Silva Classifier (V3-V4)](https://forum.qiime2.org/t/looking-for-pre-trained-silva-classifier-v3-v4/9028/3) by [jwchen](https://forum.qiime2.org/u/jwchen)). However it was generated with scikit-learn version 0.20.2, so it is not compatible with the most updated version 0.21.2.

One potential solution is to install the QIIME 2 version that was used to generate that classifier — looks like 2019.4 uses scikit-learn=0.20.2. You can install separate environments using conda, so that you can switch to QIIME 2-2019.4 for taxonomy classification, then switch back to the latest release for downstream analyses.

---

<div class="post-metadata">

**Author:** ![Daniela\_Vargas](https://forum.qiime2.org/user_avatar/forum.qiime2.org/daniela_vargas/32/5525_2.png) [@Daniela\_Vargas](https://forum.qiime2.org/u/Daniela_Vargas)\
**Post date:** [August 19, 2019, 11:23pm UTC](https://forum.qiime2.org/t/looking-for-classifier-silva-v3-v4-generated-with-scikit-learn-version-0-21-2/11135/3 "2019-08-19T23:23:16Z")

</div>

Thank you very much Nicholas! It is a simple and great idea.

I did it! although the problems with the memory continues. I will ask to install qiime2 in my university cluster.

Thanks again!

---

<div class="post-metadata">

**Author:** ![Nicholas\_Bokulich](https://forum.qiime2.org/user_avatar/forum.qiime2.org/nicholas_bokulich/32/19937_2.png) [@Nicholas\_Bokulich](https://forum.qiime2.org/u/Nicholas_Bokulich)\
**Post date:** [August 19, 2019, 11:29pm UTC](https://forum.qiime2.org/t/looking-for-classifier-silva-v3-v4-generated-with-scikit-learn-version-0-21-2/11135/4 "2019-08-19T23:29:08Z")

</div>

> [@Daniela\_Vargas](#):
>
> although the problems with the memory continues

it sounds like this is a new problem — memory errors with `classify-sklearn` instead of with `fit-classifier-naive-bayes` — correct?

if so, check out the forum archive (click on the 🔍 symbol in the top-right corner of the forum website to enter search terms). Search for `MemoryError --p-reads-per-batch` to find many posts with troubleshooting advice. There are some ways to mitigate memory constraints with `classify-sklearn`, which may help you get this command running now.

> [@Daniela\_Vargas](#):
>
> I will ask to install qiime2 in my university cluster.

You should do that too! Because then you (and others) will have the capacity to run higher-memory jobs in the future.

Good luck!

---

<div class="post-metadata">

**Author:** ![Daniela\_Vargas](https://forum.qiime2.org/user_avatar/forum.qiime2.org/daniela_vargas/32/5525_2.png) [@Daniela\_Vargas](https://forum.qiime2.org/u/Daniela_Vargas)\
**Post date:** [August 20, 2019, 1:42pm UTC](https://forum.qiime2.org/t/looking-for-classifier-silva-v3-v4-generated-with-scikit-learn-version-0-21-2/11135/5 "2019-08-20T13:42:14Z")

</div>

Thank you a lot Nicholas! I could finally run it!

> it sounds like this is a new problem — memory errors with `classify-sklearn` instead of with `fit-classifier-naive-bayes` — correct?

Right! Now the problems was with 'classify-sklearn'.

Here I will leave the script of how I run it.

```
  qiime feature-classifier classify-sklearn \
  --i-classifier silva_132_99_v3v4.qza \ 
  --i-reads denoise_rep_set_dada2.qza \
  --p-pre-dispatch 6 \
  --p-reads-per-batch 100 \  
  --p-n-jobs 2 \
  --o-classification ref-taxonomy_silva_132_99_v3v4.qza

```

I have a Mac 8 GB 1867 MHz DDR3, 2.7 GHz Intel Core i5, with two processors and it took me 5 h to run.  
I hope this helps others.  
Thank you very much to you Nicholas and to my friend Checo for your recommendations.

Daniela

---

<div class="post-metadata">

**Author:** ![system](https://forum-qiime2-org.s3.dualstack.us-west-2.amazonaws.com/original/3X/2/1/21af5fe23cb6f4579467c66a9ed94e55274ca7bd.svg) [@system](https://forum.qiime2.org/u/system)\
**Post date:** [September 20, 2019, 7:42pm UTC](https://forum.qiime2.org/t/looking-for-classifier-silva-v3-v4-generated-with-scikit-learn-version-0-21-2/11135/6 "2019-09-20T19:42:18Z")

</div>

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.
