sassoftware / sassoftware/python-sasctl

dtypes for the scoring function

Aperta
#174 2 commenti 0 reazioni 1 assegnatario Vedi su GitHub

@smlindauer ci sta già lavorando.

Dal 3/7/2023.

bug
Lingua principale
Python
Stelle
52
Fork
45
Merge medio
23h 38m
PR unite (30g)
2

Descrizione

When generating the Python scoring function in MM, the default dtypes are set to 'object', as below:
input_array = pd.DataFrame([[LOAN, MORTDUE, VALUE, REASON, JOB, YOJ, DEROG, DELINQ, CLAGE, NINQ, CLNO, DEBTINC]], columns=["LOAN", "MORTDUE", "VALUE", "REASON", "JOB", "YOJ", "DEROG", "DELINQ", "CLAGE", "NINQ", "CLNO", "DEBTINC"], dtype=object)
However, classifiers such as lightgbm don't accept object dtypes. So we may get an error when scoring with lightgbm models in MM:
ValueError: DataFrame.dtypes for data must be int, float or bool. Did not expect the data types in the following fields: LOAN, MORTDUE, VALUE, REASON, JOB, YOJ, DEROG, DELINQ, CLAGE, NINQ, CLNO, DEBTINC
I don't know whether it is safe to set all dtypes to float or None when generating the scoring func.

Guida per i contributori

Apri la guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.