通过hadoop框架解释单词计数实现? [英] Explain the word count implementation via hadoop framework?
本文介绍了通过hadoop框架解释单词计数实现?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
What do you understand by Word Count implementation via Hadoop framework? Explain in detail
我尝试过:
What I have tried:
I am not able to implement the Word Count implementation via the Hadoop framework?
推荐答案
"Word Count Implementation will be as follows:
For ex: Input File 1 contains data: "This is December Month."
Input File 2 contains data: "December is the last month of the year."
Step 1: Mapper will generate the following below output:
Input File 1 output
<this, 1>
<is, 1>
<December, 1>
<Month, 1>
Input File 2 output
<December, 1>
<is, 1>
<the, 1>
<last, 1>
<month, 1>
<of, 1>
<the, 1>
<year, 1>
Step2: Combiner/sorting is performed on the both the input files individually:
Input File 1 output:
<this, 1>
<is, 1>
<December, 1>
<Month, 1>
Input File 2 output
<December, 1>
<is, 1>
<the, 2>
<last, 1>
<month, 1>
<of, 1>
<year, 1>
Step3: Reducer will combine the output:
<this, 1>
<is, 2>
<December, 2>
<Month, 2>
<the, 2>
<of, 1>
<year, 1>
Final Output:
This 2 times
Is 2 times
December 2 times
Month 2 times
The 2 times
Of 1 times
Year 1 times
Assignment II - 3rd December
"
这篇关于通过hadoop框架解释单词计数实现?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文