# scVI and Seurat - attribute error?

**URL:** <https://discourse.scverse.org/t/scvi-and-seurat-attribute-error/63>\
**Category:** scvi-tools\
**Created:** [March 25, 2021, 7:25pm UTC](https://discourse.scverse.org/t/scvi-and-seurat-attribute-error/63 "2021-03-25T19:25:52Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![danrei999](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.scverse.org/danrei999/32/31_2.png) [@danrei999](https://discourse.scverse.org/u/danrei999)\
**Post date:** [March 25, 2021, 7:25pm UTC](https://discourse.scverse.org/t/scvi-and-seurat-attribute-error/63/1 "2021-03-25T19:25:52Z")

</div>

Hi! Thanks for the nice new tool and compability with Seurat.

I ran into the following problem during converting the Seurat object into an AnnData object:  
sc ← import(‘scanpy’, convert = FALSE)  
scvi ← import(‘scvi’, convert = FALSE)  
scvi$settings$progress\_bar\_style = ‘tqdm’  
Error in py\_get\_attr\_impl(x, name, silent) :  
AttributeError: module ‘scvi’ has no attribute ‘settings’

later:  
scvi$data$setup\_anndata(adata)  
Error in py\_get\_attr\_impl(x, name, silent)  
AttributeError: module ‘scvi’ has no attribute ‘data’

Would you have any idea?

Many thanks and best,

Dan

sessionInfo()  
R version 4.0.1 (2020-06-06)  
Platform: x86\_64-pc-linux-gnu (64-bit)  
Running under: CentOS Linux 7 (Core)

Matrix products: default  
BLAS/LAPACK: /n/app/openblas/0.2.19/lib/libopenblas\_core2p-r0.2.19.so

locale:  
[1] LC\_CTYPE=de\_DE.UTF-8 LC\_NUMERIC=C  
[3] LC\_TIME=de\_DE.UTF-8 LC\_COLLATE=de\_DE.UTF-8  
[5] LC\_MONETARY=de\_DE.UTF-8 LC\_MESSAGES=de\_DE.UTF-8  
[7] LC\_PAPER=de\_DE.UTF-8 LC\_NAME=C  
[9] LC\_ADDRESS=C LC\_TELEPHONE=C  
[11] LC\_MEASUREMENT=de\_DE.UTF-8 LC\_IDENTIFICATION=C

attached base packages:  
[1] stats graphics grDevices utils datasets methods base

other attached packages:  
[1] SeuratData\_0.2.1 Seurat\_3.2.3 reticulate\_1.18

loaded via a namespace (and not attached):  
[1] nlme\_3.1-148 matrixStats\_0.58.0 RcppAnnoy\_0.0.18  
[4] RColorBrewer\_1.1-2 httr\_1.4.2 sctransform\_0.3.2  
[7] tools\_4.0.1 R6\_2.5.0 irlba\_2.3.3  
[10] rpart\_4.1-15 KernSmooth\_2.23-17 uwot\_0.1.10  
[13] mgcv\_1.8-31 DBI\_1.1.1 lazyeval\_0.2.2  
[16] colorspace\_2.0-0 tidyselect\_1.1.0 gridExtra\_2.3  
[19] compiler\_4.0.1 cli\_2.3.0 plotly\_4.9.3  
[22] scales\_1.1.1 lmtest\_0.9-38 spatstat.data\_2.1-0  
[25] ggridges\_0.5.3 pbapply\_1.4-3 rappdirs\_0.3.3  
[28] spatstat\_1.64-1 goftest\_1.2-2 stringr\_1.4.0  
[31] digest\_0.6.27 spatstat.utils\_2.1-0 pkgconfig\_2.0.3  
[34] htmltools\_0.5.1.1 parallelly\_1.23.0 fastmap\_1.1.0  
[37] htmlwidgets\_1.5.3 rlang\_0.4.10 shiny\_1.6.0  
[40] generics\_0.1.0 zoo\_1.8-8 jsonlite\_1.7.2  
[43] ica\_1.0-2 dplyr\_1.0.4 magrittr\_2.0.1  
[46] patchwork\_1.1.1 Matrix\_1.3-2 Rcpp\_1.0.6  
[49] munsell\_0.5.0 abind\_1.4-5 lifecycle\_0.2.0  
[52] stringi\_1.5.3 MASS\_7.3-51.6 Rtsne\_0.15  
[55] plyr\_1.8.6 grid\_4.0.1 parallel\_4.0.1  
[58] listenv\_0.8.0 promises\_1.1.1 ggrepel\_0.9.1  
[61] crayon\_1.4.0 miniUI\_0.1.1.1 deldir\_0.2-9  
[64] lattice\_0.20-41 cowplot\_1.1.1 splines\_4.0.1  
[67] tensor\_1.5 pillar\_1.4.7 igraph\_1.2.6  
[70] future.apply\_1.7.0 reshape2\_1.4.4 codetools\_0.2-16  
[73] leiden\_0.3.7 glue\_1.4.2 data.table\_1.13.6  
[76] png\_0.1-7 vctrs\_0.3.6 httpuv\_1.5.5  
[79] gtable\_0.3.0 RANN\_2.6.1 purrr\_0.3.4  
[82] polyclip\_1.10-0 tidyr\_1.1.2 scattermore\_0.7  
[85] future\_1.21.0 assertthat\_0.2.1 ggplot2\_3.3.3  
[88] rsvd\_1.0.3 mime\_0.9 xtable\_1.8-4  
[91] later\_1.1.0.1 survival\_3.1-12 viridisLite\_0.3.0  
[94] tibble\_3.0.6 cluster\_2.1.0 globals\_0.14.0  
[97] fitdistrplus\_1.1-3 ellipsis\_0.3.1 ROCR\_1.0-11

---

<div class="post-metadata">

**Author:** ![galenxing](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.scverse.org/galenxing/32/53_2.png) [@galenxing](https://discourse.scverse.org/u/galenxing)\
**Post date:** [March 29, 2021, 11:14pm UTC](https://discourse.scverse.org/t/scvi-and-seurat-attribute-error/63/2 "2021-03-29T23:14:23Z")

</div>

Hi @danrei999!

I think you need to update scvi-tools. Instructions can be found here: [Installation — scvi-tools](https://docs.scvi-tools.org/en/stable/installation.html)

Let me know if that works,  
Galen
