SAS Scoring Accelerator for SAS/ACCESS Databases

Overview of the SAS Scoring Accelerator for SAS/ACCESS Databases

When using conventional processing to access data inside a data source, SAS Enterprise Miner asks the SAS/ACCESS engine for all rows of the table being processed. The SAS/ACCESS engine generates an SQL SELECT * statement that is passed to the data source. That SELECT statement fetches all the rows in the table, and the SAS/ACCESS engine returns them to SAS Enterprise Miner. As the number of rows in the table grows over time, network latency grows. This happens because the amount of data that is fetched from the data source to the SAS scoring process increases.
The SAS Scoring Accelerator embeds the robustness of SAS Enterprise Miner scoring models directly in the highly scalable data source. By using the SAS In-Database technology and the SAS Scoring Accelerator, the scoring process is done inside the data source and thus does not require the transfer of data.
The SAS Scoring Accelerator takes the models that are developed by SAS Enterprise Miner and translates them into scoring files or functions that can be deployed inside the data source. After the scoring functions are published, the functions extend the data source’s SQL language and can be used in SQL statements like other data source functions. After the scoring files are published, they are used by the SAS Embedded Process to run the scoring model.
The SAS Scoring Accelerator consists of two components:
  • the Score Code Export node in SAS Enterprise Miner. This extension exports the model scoring logic (including metadata about the required input and output variables) from SAS Enterprise Miner.
  • the publishing client that includes a scoring publishing macro. This macro translates the scoring model into files that are used inside the data source to run the scoring model. The publishing client then uses the SAS/ACCESS Interface to the data source to publish the files to the data source.
You can also use the SAS Scoring Accelerator and SAS Model Manager to import SAS/STAT linear models and SAS High-Performance Analytics models from a SAS package file (.SPK). Models that have a DATA step score code type can be scored, published, and included in performance monitoring. For more information, see the SAS Model Manager: User's Guide.

How It Works for SAS/ACCESS Databases

Using SAS Enterprise Miner, you can generate SAS DATA step code that contains scoring functions. The SAS Scoring Accelerator takes the scoring model code, the associated property file that contains model inputs and outputs, and a catalog of user-defined formats. The SAS Scoring Accelerator deploys (or publishes) them to the data source. Inside the data source, one or more scoring files or functions are created and registered for use in SQL queries.
The following figure illustrates this process.
Process Flow Diagram
Process Flow Diagram
1 Install the components that are necessary for in-database processing.
The components that are deployed are different for each data source. For more information, see the SAS In-Database Products: Administrator's Guide.
Note: This is a one-time installation process.
2 Use SAS Enterprise Miner to create a scoring model. Use the Score Code Export node to export files that are used to create the scoring files or functions to a score output directory.
3 Start SAS and run the SAS publishing macros. This creates the files that are needed to build the scoring files or functions and publish those files to the data source.
For more information, see the section on publishing scoring model files in the Scoring Accelerator chapter for your data source.
4 After the scoring files or functions are created, you can run your scoring model.
For more information, see the topic on running the scoring model in the Scoring Accelerator chapter for your data source.