Machine Learning:High-speed computing with RTX3060Ti(LSTM)

Machine Learning
この記事は約6分で読めます。

Abstract
I compared the calculation speed of the LSTM model of the new PC (with RTX3060Ti) with the old PC (without NVIDEA GPU). The calculation speed of the new PC was about 15 times faster than the old one.

この記事は先日の日本語の記事↓の英語版です。
This blog post is an English version of the following blog.

以前、tensorflowのGPU版をインストールした際の記事でも英語版を書きましたが、意外とアクセス数がありました。そのため今回もヘタクソながらも英語版の記事を残しておこうと思います。

Analysis conditions

I compare the execution speed of the program on the New PC (with RTX3060Ti) and the Old PC(without NVIDIA GPU).
I use a program I created previously that predicts the price of investment fund. Incidentally, prior testing has shown that this program fails to predict prices.(If you actually use the predicted results of the program, you will lose a lot of money.)
The library used is Keras and the algorithm used is LSTM. (Keras is like a tensorflow.) As mentioned earlier, the program I use is not very accurate, but it can be used to compare calculation speeds. The following table shows the performance of the PC used and the LSTM model.

Table 1 Computer specs

Table 2 LSTM model
In the GPU version of tensorflow, I have to use the “tanh” and “sigmoid” functions. To avoid the loss of gradient(Vanishing Gradient Problem), I really want to use the ReLU function.

References:Keras

Result

Accuracy

There is almost no difference.

Figure 1 New PC(with RTX3060Ti)
Figure 2
Old PC(without NVIDIA GPU)

Computation speed

GPU(RTX3060Ti) accelerated the calculation.
Computation time
New PC : 30sec.
Old  PC:440sec.

The computation speed of the new PC is 15 times faster than that of the old one!!!
The analogy is Eurostar(300kph≒187mph )vs. bicycles(20kph).
This means that calculations that used to take two weeks will be completed within a day. Additionally, it means that calculations that previously took a year to complete will be completed in less than a month.

On the other hand, there is also a problem with the new PC calculations.
On a new PC, it takes about 15 minutes from the instruction to start running the program. I would like to shorten these 15 minutes and am looking into ways to do so. For large scale calculations that take days to complete, using the GPU(RTX3060Ti) of the new PC can save a lot of time. However, for small calculations, using the old PC may take less time than using the new PC. This is because the old PC starts the calculation at the same time as the command to start execution, while the new PC has to wait until execution starts. (In fact, in this case, the time from the start of the execution instruction to the end of the calculation, the old PC is faster than the new PC. This is because the old PC finishes the calculation in 440 seconds, while the new PC waits for about 900 seconds to start the calculation.)
If I find a solution to this problem, I will add it.

Conclusion

The new PC has a much faster computation speed than the old PC. However, it takes a certain amount of time from the start of the execution instruction to the start of execution on the new PC. I would like to solve this problem in the future.

Thank you.

コメント

タイトルとURLをコピーしました