Investors who want to put their savings into financial assets are faced with a wide variety of product offerings. These assets vary in complexity and investment profile. Two fundamental aspects of a financial asset investment must be considered: risk and profitability. The investor should consider the fact that assets with lower risk may have lower profitability, and assets with higher risk may have higher profitability. When investors are not fully aware of an investment profile, they are more apt to make decisions that can result in financial loss.
Used in a broad range of applications such as marketing, sales, and social media, sentiment analysis has been achieving impressive results for several years. Another use case for sentiment analysis is to analyze customer answers when building an investor profile based on a standard new-account questionnaire. Today, most sentiment analysis tasks are done by humans, which can be labor intensive and inconsistent.
This paper discusses sentiment analysis using Intel® Optimization for TensorFlow* to help classify investment profiles. It also compares two different environments and the speed at which the analysis is done in each environment.
Solution Architecture and Design
This sentiment analysis solution was developed to identify sentiments in the customer-provided answers to specific investment-related questions. The block diagram below illustrates a simple analysis scenario.
Table 1 lists the hardware configurations used for the comparison in this paper.
Table 1. Hardware configurations
|Number of nodes||1|
|Number of sockets||2|
|CPU||Intel® Xeon® Platinum 8153 processor at 2.00 GHz|
|Cores per socket, Threads per core||16, 2|
|BIOS version (including microcode version)||SE5C620.86B.00.01.0015.110720180833|
|System DDR memory configuration||1 slot, 394 GB|
|Total memory per node (DDR + DCPMM)||394 GB|
|OS||CentOS* Linux* 7 (Core)|
|Kernel||Linux kernel 3.10.0-693.11.6.el7.x86_64|
|Mitigation variants (1, 2, 3, 3a, 4, L1TF)||3, L1TF|
|Libraries||Intel® Optimization for TensorFlow*|
|Framework version||TensorFlow* 1.12|
|Intel® Math Kernel Library for Deep Neural Networks (Intel® MKL-DNN) version||Intel MKL-DNN 2018|
|Dataset||ISV data and customer data|
The software configurations used in the analysis and comparison are below.
|Intel® Distribution for Python* version||Python 3.6.1|
|Intel® Optimization for TensorFlow* version||1.12|
|Python version||Python 3.6.1|
|TensorFlow version (from pip)||1.12|
Setting up the Environments
The optimized environment, which uses Intel® Math Kernel Library for Deep Neural Neworks (Intel® MKL-DNN) in the back-end, consists of the Intel® Distribution for Python* and the Intel Optimization for TensorFlow.
To install the default environment ( with Eigen* in the back-end), execute:
pip install tensorflow --user
We used the samples-per-second (SPS) metric while comparing the performance between Intel Optimization for TensorFlow and the default TensorFlow version from pip.
|Cloud||Architecture||Inference Time (samples per second)|
|Intel® AI Builders DevCloud||CPU optimized||32469.85|
The chart above shows that Intel Optimization for TensorFlow on the Intel® Xeon® Platinum 8153 processor delivered a performance 1.17x faster than the non-optimized version of TensorFlow with Eigen.
This paper describes how to optimize deep learning inference on an Intel® Xeon® processor for sentiment analysis. A 1.17x speedup was achieved when using the Intel Optimization for TensorFlow on the Intel Xeon Platinum 8153 processor. The solution also took advantage of Intel MKL-DNN optimization to achieve the expected performance.
This solution can help improve a company’s ability to offer more personalized investment options to customers because it helps them more efficiently process investor profiles and it reduces analysis costs using existing hardware solutions.
Product and Performance Information
Performance varies by use, configuration and other factors. Learn more at www.Intel.com/PerformanceIndex.