BookmarkSubscribeRSS Feed
mallikadey
Calcite | Level 5

Hi All, 

 

I am new to SAS Viya and trying to generate predictions from a trained gradient boosting model in Viya. The model has been trained using pipeline. Now, I need to score a new data set. I am using the "Manage Models" -> "Scoring" -> "New Test" option to score this table. But, I am getting the following errors - 

 

error: ERROR: There is no session-scope table score_12345 in caslib LIBABC of Cloud Analytic Services.

error: ERROR: Code file is missing the declaration 'varlist allvars [_all_]

 

Could you please explain what is happening here?

 

Thanks,

MD

 

 

 

1 REPLY 1
AnnKuo
SAS Employee

Hi MD,

 

Some models in SAS Visual Data Mining and Machine Learning are packaged in a single downloadable DATA step code file. Other models are based on a SAS analytical store such as the model created by a Gradient Boosting or Forest node. Each analytic store is a binary representation of the state of an analytic procedure after training. This analytic store must also be accompanied by analytic store score code, also referred to as EP score code. These files represent your model and can be imported into your project. 

 

Without knowing the exact steps that replicate your issue, I assume you’ve performed the following steps:

1)    Select Download score code from the Project Pipeline menu in the Pipeline Comparison tab

2)    Save the ZIP file.  

3)    Import the zip file to your project to define your model in SAS Model Manager. 

4)    Score a new table using "Manage Models" -> "Scoring" -> "New Test". 

 

If my assumption is correct, you are seeing the error most likely because the ZIP file approach requires complete model contents consisting of model input and output metadata, and score code file. Additionally, if an analytical store is a part of the model, then the binary model file needs to be available in the ModelStore CAS library after a model is registered. Otherwise, you will get an error like what you are observing because this binary model file cannot be found. 

 

Depending on the purpose of scoring, you can consider the following options: ·        

 

-- If you only want to score a new table, then score within Model Studio. To score holdout data, complete the following steps:

  1. Select the waterfall icon in the upper right corner of the Pipeline Comparison
  2. Select Score holdout data.
  3. The Browse Data window appears. Select the data set that contains the holdout data that you want scored.
  4. Click OK.
  5. Model Studio will score the holdout data. To see the results of this process, use the Data menu below Pipeline Comparison to select Holdout.

 

 -- If your objective is to manage and publish models, then score with SAS Model Manager.

  1. Click the waterfall icon in the upper right corner of the Pipeline Comparison tab in the interface of Model Studio and select Register models. This registers the model in SAS Model Manager. SAS Model Manager is used to store and organize models in a common repository.
  2. Score the new table using "Manage Models" -> "Scoring" -> "New Test".

 

Hope this helps.  

 

-Ann

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

Mastering the WHERE Clause in PROC SQL

SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 1 reply
  • 1219 views
  • 1 like
  • 2 in conversation