Smart Map

545 views
Skip to first unread message

Márcio Midon

unread,
Oct 22, 2023, 6:43:08 PM10/22/23
to qgisbrasil

Pesso@all,

Preciso de uma ajuda de vocês....Estou tentando executar o SmartMap no QGIS 3.22 LTR (UBUNTU 20.04x64) e aparece este erro. Alguém pode me ajudar?

Um erro ocorreu enquanto executava o código Python:

TypeError: sort_values() got an unexpected keyword argument 'ignore_index'

Traceback (most recent call last):
  File "/home/analista/.local/share/QGIS/QGIS3/profiles/default/python/plugins/Smart_Map/Smart_Map.py", line 1814, in pushButton_ImportQGIS_clicked
    Semiv = semivariogram.Semivariogram(self.xy, self.z)
  File "/home/analista/.local/share/QGIS/QGIS3/profiles/default/python/plugins/Smart_Map/krig/semivariogram.py", line 98, in __init__
    self.var=self.var.sort_values(by='lag',ignore_index=True) #o index não é atualizado
TypeError: sort_values() got an unexpected keyword argument 'ignore_index'

--

--
Cordialmente,
Márcio Midon
Arquiteto e Urbanista UFPel
Especialista Geoprocessamento UFPR
Mestre Geomática UFSM
Doutorando Geografia UFSM
Tel 53 3305 7075 | Cel 53 98100 2020
SKYPE marcio_midon

Sandro Hurtado

unread,
Oct 23, 2023, 11:37:43 AM10/23/23
to qgisb...@googlegroups.com
Boa tarde Márcio!
Segue a resposta do prof. Gustavo William (ifsudestemg), autor do Smart Map:

“Como ele utiliza Linux, provavelmente o QGIS instalado na maquina está utilizando o python que já vem com o sistema operacional Linux. 

Este erro ocorre, devido a uma biblioteca python chamada pandas. 

O parâmetro ignore_index só funciona para versões da biblioteca pandas superior a  1.0.0 no Linux instalado na maquina. 

Para verificar a versão da biblioteca pandas, abra o terminal Linux e digite: 

import pandas as pd
 
# Get pandas Version
print(pd.__version__)

Para atualizar a versão da biblioteca pandas utilize o comando: 

# Using pip3 to upgrade pandas
pip3 install --upgrade pandas

OU 

# Alternatively you can also try
python -m pip install --upgrade pandas

Outra sugestão é atualizar para a versão 3.28 do QGIS. 

Espero que resolva o problema do usuário”


Att,
Sandro 

Em 22 de out. de 2023, à(s) 19:43, Márcio Midon <marci...@gmail.com> escreveu:


--
Comunidade QGIS Brasil: http://qgisbrasil.org/
---
You received this message because you are subscribed to the Google Groups "qgisbrasil" group.
To unsubscribe from this group and stop receiving emails from it, send an email to qgisbrasil+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/qgisbrasil/fd4493b2-7c04-4399-ac4f-f6e75adc8a7b%40gmail.com.

Márcio Midon

unread,
Oct 23, 2023, 4:46:08 PM10/23/23
to qgisb...@googlegroups.com

Olá Sandro,

Fiz o procedimento e o erro continua. Tentei no Windos 10 X 64 com QGIS 3.28LTR e deu erro tbm.

Obrigado pela força.

Att

Marcio Midon.

Márcio Midon

unread,
Oct 23, 2023, 6:12:56 PM10/23/23
to qgisb...@googlegroups.com

No windows aparece esta mensagem:

  AttributeError: module 'numpy' has no attribute 'float'.
             `np.float` was a deprecated alias for the builtin `float`. To avoid this error in existing code, use `float` by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use `np.float64` here.
             The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
              https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations
            

Em 23/10/2023 12:37, Sandro Hurtado escreveu:
Reply all
Reply to author
Forward
0 new messages