没有合适的资源?快使用搜索试试~ 我知道了~
最终硕士论文 高性能计算.pdf
1.该资源内容由用户上传,如若侵权请联系客服进行举报
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
版权申诉
0 下载量 132 浏览量
2024-04-14
08:44:46
上传
评论
收藏 1.99MB PDF 举报
温馨提示
试读
55页
最终硕士论文 高性能计算.pdf
资源推荐
资源详情
资源评论
1
Java V.S. Python in AI
Final Master Thesis – High Performance
Computing
Master in Innovation and Research in Informatics
F
acultat
d’inform
`
atica
de
Barcelona
Univ
ersitat
P
olit
`
ecnica
de
Catalun
y
a
Author:
Marco M. Aguado Acevedo
marcoaguado95@gmail.com
October 28, 2021
Supervisors:
Marisa Gil Gómez
marisa.gil@upc.edu
2
Acknowledgements
First and foremost, I would like to use this section to thank professor Marisa Gil for the opportunity
she gave to me to work on this interesting project.
I would also like to thank professor Xavier for providing me access to the CTE-ARM system of the BSC
and for providing advice regarding the analysis and the execution process.
Not only do I want to express my gratitude towards them for the unconditional support, but also for
their patience and kindness.
I cannot end this note without thanking my whole family, especially my parents and aunt, who sup-
ported me throughout not only my academic career but also my life.
3
Abstract
Java’s position as an appealing programming language for developing AI software is not clear in the
current research area. It is well-stablished that other programming languages such as Python have
grown in popularity in the AI research community as an easy to learn, easy to use and simple code
tool over the more strict and complex languages such as Java. Also, with the increase in the number
of processors with ARM architecture used for server purposes due to their better energy efficiency,
the interest in their performance for specific research areas also increases. This thesis aims to
provide an objective and up-to-date view of Java’s current situation in this area by comparing it with
Python both in terms of the coding process and their performance.
To test if Java could prove more value to researchers than Python, a set of representative AI
algorithms were implemented in both languages using the nowadays most used libraries: Weka for
Java and Scikit-learn, Pandas and Numpy for Python and executed in two different machines from
the MareNostrum4 system: The Intel machine with x86 architecture processors and the CTE-ARM
machine with ARM architecture processors using 4 different datasets with its own characteristics
and sizes.
The results obtained show that Java performs worse than Python in almost all the tests by having
higher execution times and worse memory management while the impact of using a machine with
an ARM processor is minimal although in general it performs better than x86 processor, especially
when comparing Java’s performance in both machines.
These results suggest that Java does not provide enough value to because a more suitable
programming language than Python for AI researchers as the obtained performance does not
compensate the extra effort both in learning time and coding time Java requires to implement
programs that solve the exact same problems.
Keywords: Java, Python, Artificial Intelligence, ARM, performance, code
4
Index
1.Introduction ......................................................................................................................................... 8
1.1 State of the art .............................................................................................................................. 8
1.2 Proposal ........................................................................................................................................ 9
1.3 Objectives.................................................................................................................................... 10
2. Methodology ..................................................................................................................................... 11
2.1 Study of the existing and most representative algorithms in the AI .......................................... 11
2.1.1 Regression ............................................................................................................................ 11
2.1.2 Classification ........................................................................................................................ 12
2.2 Study of the available Hardware systems ................................................................................... 16
2.3 Study of Java and Python programing languages ....................................................................... 16
2.3.1 Java ....................................................................................................................................... 16
2.3.2 Python .................................................................................................................................. 19
2.4 Study of the characteristics and metrics to compare ................................................................. 20
2.4.1 Code ..................................................................................................................................... 20
2.4.2 Performance......................................................................................................................... 21
2.5 Study and research of existing AI libraries .................................................................................. 21
2.5.1 Python .................................................................................................................................. 21
2.5.2 Java ....................................................................................................................................... 24
2.6 Study and research of possible monitoring tools ....................................................................... 25
2.6.1 Python .................................................................................................................................. 25
2.6.2 Java ....................................................................................................................................... 26
2.6.3 System provided tools.......................................................................................................... 26
2.7 Implementation of the code and preparation of data ................................................................ 28
2.7.1 Implementation of the algorithms ....................................................................................... 28
2.7.2 Dataset selection and preprocessing ................................................................................... 28
3. Experimental design and set-up ....................................................................................................... 33
3.1 Filesystem structure .................................................................................................................... 33
3.2 Compilation ................................................................................................................................. 35
3.3 Execution ..................................................................................................................................... 36
3.4 Data collection ............................................................................................................................ 37
4. Key results obtained in the study ..................................................................................................... 38
4.1 The code ...................................................................................................................................... 38
4.2 The performance......................................................................................................................... 40
4.2.1 Java and Python in x86 ......................................................................................................... 40
5
4.2.2 Java in x86 and ARM ............................................................................................................ 43
4.2.3 Python in x86 and ARM ........................................................................................................ 46
4.2.4 Java and Python in ARM ....................................................................................................... 49
5. Conclusions ....................................................................................................................................... 52
Future work ........................................................................................................................................... 53
Multithreading .................................................................................................................................. 53
Using more features of the libraries provided algorithms ............................................................... 53
BSC tools ........................................................................................................................................... 53
Further study of the coding process ................................................................................................. 53
Other programming languages ......................................................................................................... 53
References ............................................................................................................................................ 54
剩余54页未读,继续阅读
资源评论
百态老人
- 粉丝: 2195
- 资源: 2万+
下载权益
C知道特权
VIP文章
课程特权
开通VIP
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功