See: Description
Interface | Description |
---|---|
Combinable<T> |
A class is Combinable if its object can be combined with other objects.
|
Container<T> |
A class is a Container if it contains an element.
|
Class | Description |
---|---|
DistBbp |
A map/reduce program that uses a BBP-type method to compute exact
binary digits of Pi.
|
DistSum |
The main class for computing sums using map/reduce jobs.
|
DistSum.Machine |
Abstract machine for job execution.
|
DistSum.Machine.AbstractInputFormat |
An abstract InputFormat for the jobs
|
DistSum.Machine.SummationSplit |
Split for the summations
|
DistSum.MapSide |
A machine which does computation on the map side.
|
DistSum.MapSide.PartitionInputFormat |
An InputFormat which partitions a summation
|
DistSum.MapSide.SummingMapper |
A mapper which computes sums
|
DistSum.MixMachine |
A machine which chooses Machine in runtime according to the cluster status
|
DistSum.ReduceSide |
A machine which does computation on the reduce side.
|
DistSum.ReduceSide.IndexPartitioner |
Use the index for partitioning.
|
DistSum.ReduceSide.PartitionMapper |
A Mapper which partitions a summation
|
DistSum.ReduceSide.SummationInputFormat |
An InputFormat which returns a single summation.
|
DistSum.ReduceSide.SummingReducer |
A Reducer which computes sums
|
Parser |
A class for parsing outputs
|
SummationWritable |
A Writable class for Summation
|
TaskResult |
A class for map task results or reduce task results.
|
Util |
Utility methods
|
Util.Timer |
Timer
|
The Bits of πThe table on the right are the results computed by distbbp.
|
* By representing π in decimal, hexadecimal and binary, we have
|
$ hadoop org.apache.hadoop.examples.pi.DistBbp \ <b> <nThreads> <nJobs> <type> <nPart> <remoteDir> <localDir>And the parameters are:
<b> | The number of bits to skip, i.e. compute the (b+1)th position. |
<nThreads> | The number of working threads. |
<nJobs> | The number of jobs per sum. |
<type> | 'm' for map side job, 'r' for reduce side job, 'x' for mix type. |
<nPart> | The number of parts per job. |
<remoteDir> | Remote directory for submitting jobs. |
<localDir> | Local directory for storing output files. |
$ hadoop org.apache.hadoop.examples.pi.DistBbp \ 1,000,000,000,000,056 20 1000 x 500 remote/a local/outputIt uses 20 threads to summit jobs so that there are at most 20 concurrent jobs. Each sum (there are totally 14 sums) is partitioned into 1000 jobs. The jobs will be executed in map-side or reduce-side. Each job has 500 parts. The remote directory for the jobs is remote/a and the local directory for storing output is local/output. Depends on the cluster configuration, it may take many days to finish the entire execution. If the execution is killed, we may resume it by
$ hadoop org.apache.hadoop.examples.pi.DistBbp \ 1,000,000,000,000,056 20 1000 x 500 remote/b local/output
Copyright © 2013 Apache Software Foundation. All rights reserved.