hyonline_
2018-05-15 16:24
请问有源代码吗?
出现了java.io.FileNotFoundException: matrix2 的错误
修改mapper2
@Override
protected void setup(Context context) throws IOException, InterruptedException {
super.setup(context);
//通过输入流将全局缓存变量中的 右侧矩阵 读入List<String>中
Configuration conf = context.getConfiguration();
FileSystem fs = FileSystem.get(conf);
FSDataInputStream in = fs.open(new Path("/matrix/step1_output/part-r-00000"));
//FileReader fr = new FileReader(itermOccurrenceMatrix);
BufferedReader br = new BufferedReader(new InputStreamReader(in));
//每一行的格式是: 行 tab 列_值,列_值,列_值,列_值
String line = null;
while((line = br.readLine())!=null) {
cacheList.add(line);
}
in.close();
br.close();
}
tql,就是有点搞不懂为什么原来不行
能行。
Hadoop进阶
24236 学习 · 72 问题
相似问题