List of usage examples for org.apache.hadoop.mapreduce.lib.output MultipleOutputs MultipleOutputs
public MultipleOutputs(TaskInputOutputContext<?, ?, KEYOUT, VALUEOUT> context)
From source file:Analysis.A6_User_Differentiation_By_Age.Partition_Users_By_Age_Reducer.java
public void setup(Mapper.Context context) { multipleOutputs = new MultipleOutputs(context); }
From source file:Assignment5_P4_BinningPattern.Binning_IPAddress_By_Day_Mapper.java
public void setup(Context context) { multipleOutputs = new MultipleOutputs(context); }
From source file:be.uantwerpen.adrem.bigfim.AprioriPhaseReducer.java
License:Apache License
@Override public void setup(Context context) { Configuration conf = context.getConfiguration(); minSup = conf.getInt(MIN_SUP_KEY, 1); getBaseDirs(context);/*from w ww . jav a 2 s .c om*/ tgIndex = getLargestIndex(conf, new Path(createPath(baseDir, "tg" + aprioriPhase)), "trieGroup", 1) + 1; fisIndex = getLargestIndex(conf, new Path(createPath(baseDir, OShortFIs)), "fis-" + aprioriPhase, 2) + 1; baseOutputPathFis = createPath(baseDir, OShortFIs, "fis-" + aprioriPhase + "-" + fisIndex); mos = new MultipleOutputs<Text, Writable>(context); }
From source file:be.uantwerpen.adrem.bigfim.ComputeTidListReducer.java
License:Apache License
@Override public void setup(Context context) { Configuration conf = context.getConfiguration(); minSup = conf.getInt(MIN_SUP_KEY, 1); numberOfMappers = conf.getInt(NUMBER_OF_MAPPERS_KEY, 1); bucketSizes = newArrayListWithCapacity(numberOfMappers); for (int i = 0; i < numberOfMappers; i++) { bucketSizes.add(new MutableInt()); }// www. j a v a 2 s. c o m getBasePGDir(context); getPgStartIndex(conf); mos = new MultipleOutputs<IntArrayWritable, IntMatrixWritable>(context); }
From source file:be.uantwerpen.adrem.disteclat.ItemReaderReducer.java
License:Apache License
@Override public void setup(Context context) { Configuration conf = context.getConfiguration(); mos = new MultipleOutputs<IntWritable, Writable>(context); numberOfMappers = parseInt(conf.get(NUMBER_OF_MAPPERS_KEY, "1")); minSup = conf.getInt(MIN_SUP_KEY, -1); shortFisFilename = createPath(getJobAbsoluteOutputDir(context), OShortFIs, OShortFIs + "-1"); }
From source file:be.uantwerpen.adrem.disteclat.PrefixComputerReducer.java
License:Apache License
@Override public void setup(Context context) throws IOException { Configuration conf = context.getConfiguration(); createShortFIsFile(context);/*from w w w.j av a 2s. c om*/ minSup = conf.getInt(MIN_SUP_KEY, 1); int numberOfMappers = conf.getInt(NUMBER_OF_MAPPERS_KEY, 1); bucketSizes = newArrayListWithCapacity(numberOfMappers); for (int i = 0; i < numberOfMappers; i++) { bucketSizes.add(new MutableInt()); } mos = new MultipleOutputs<IntArrayWritable, IntMatrixWritable>(context); }
From source file:cienciaCelularMR.McellMapper.java
@Override public void setup(Context context) throws IOException, InterruptedException { mos = new MultipleOutputs(context); }
From source file:com.jhkt.playgroundArena.hadoop.tasks.jobs.reducer.AverageMultipleOutputReducer.java
License:Apache License
protected void setup(Reducer<Text, AverageWritable, Text, DoubleWritable>.Context context) throws IOException, InterruptedException { _mOutputs = new MultipleOutputs<>(context); }
From source file:com.rw.legion.DefaultMapper.java
License:Apache License
/** * Do standard Hadoop setup, de-serialize the <code>LegionObjective</code>, * and prepare for writing to multiple output files. *///from ww w . j a va2 s. c o m @SuppressWarnings({ "unchecked", "rawtypes" }) public void setup(Context context) { Configuration config = context.getConfiguration(); this.objective = ObjectiveDeserializer.deserialize(config.get("legion_objective")); outputWriters = new MultipleOutputs(context); }
From source file:com.talis.mapreduce.dicenc.SecondReducer.java
License:Apache License
@Override @SuppressWarnings("unchecked") public void setup(Context context) { mos = new MultipleOutputs(context); String mapred_task_id = context.getConfiguration().get("mapred.task.id"); counter = (Long.valueOf(mapred_task_id.substring(mapred_task_id.indexOf("_r_") + 3).replaceAll("_", "")) + 1) << 32;/*from www .j a va 2s.c om*/ }