<p dir="auto">I'm not sure if this is desired behavior or not, but the two functions currently have inconsistent output. It would be nice for <code class="notranslate">pmap()</code> to preserve shape too.</p>
<div class="highlight highlight-source-julia notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="julia&gt; map(prod, Base.product(1:5, 1:5))
5×5 Array{Int64,2}:
 1   2   3   4   5
 2   4   6   8  10
 3   6   9  12  15
 4   8  12  16  20
 5  10  15  20  25

julia&gt; pmap(prod, Base.product(1:5, 1:5))
25-element Array{Any,1}:
  1
  2
  3
  4
  5
  2
  4
  6
  8
 10
  3
  6
  9
 12
 15
  4
  8
 12
 16
 20
  5
 10
 15
 20
 25"><pre class="notranslate">julia<span class="pl-k">&gt;</span> <span class="pl-c1">map</span>(prod, Base<span class="pl-k">.</span><span class="pl-c1">product</span>(<span class="pl-c1">1</span><span class="pl-k">:</span><span class="pl-c1">5</span>, <span class="pl-c1">1</span><span class="pl-k">:</span><span class="pl-c1">5</span>))
<span class="pl-c1">5</span><span class="pl-k">×</span><span class="pl-c1">5</span> Array{Int64,<span class="pl-c1">2</span>}<span class="pl-k">:</span>
 <span class="pl-c1">1</span>   <span class="pl-c1">2</span>   <span class="pl-c1">3</span>   <span class="pl-c1">4</span>   <span class="pl-c1">5</span>
 <span class="pl-c1">2</span>   <span class="pl-c1">4</span>   <span class="pl-c1">6</span>   <span class="pl-c1">8</span>  <span class="pl-c1">10</span>
 <span class="pl-c1">3</span>   <span class="pl-c1">6</span>   <span class="pl-c1">9</span>  <span class="pl-c1">12</span>  <span class="pl-c1">15</span>
 <span class="pl-c1">4</span>   <span class="pl-c1">8</span>  <span class="pl-c1">12</span>  <span class="pl-c1">16</span>  <span class="pl-c1">20</span>
 <span class="pl-c1">5</span>  <span class="pl-c1">10</span>  <span class="pl-c1">15</span>  <span class="pl-c1">20</span>  <span class="pl-c1">25</span>

julia<span class="pl-k">&gt;</span> <span class="pl-c1">pmap</span>(prod, Base<span class="pl-k">.</span><span class="pl-c1">product</span>(<span class="pl-c1">1</span><span class="pl-k">:</span><span class="pl-c1">5</span>, <span class="pl-c1">1</span><span class="pl-k">:</span><span class="pl-c1">5</span>))
<span class="pl-c1">25</span><span class="pl-k">-</span>element Array{Any,<span class="pl-c1">1</span>}<span class="pl-k">:</span>
  <span class="pl-c1">1</span>
  <span class="pl-c1">2</span>
  <span class="pl-c1">3</span>
  <span class="pl-c1">4</span>
  <span class="pl-c1">5</span>
  <span class="pl-c1">2</span>
  <span class="pl-c1">4</span>
  <span class="pl-c1">6</span>
  <span class="pl-c1">8</span>
 <span class="pl-c1">10</span>
  <span class="pl-c1">3</span>
  <span class="pl-c1">6</span>
  <span class="pl-c1">9</span>
 <span class="pl-c1">12</span>
 <span class="pl-c1">15</span>
  <span class="pl-c1">4</span>
  <span class="pl-c1">8</span>
 <span class="pl-c1">12</span>
 <span class="pl-c1">16</span>
 <span class="pl-c1">20</span>
  <span class="pl-c1">5</span>
 <span class="pl-c1">10</span>
 <span class="pl-c1">15</span>
 <span class="pl-c1">20</span>
 <span class="pl-c1">25</span></pre></div>
<p dir="auto">As discussed on the julia-users mailing list thread "parallelized comprehensions"<br>
<a href="https://groups.google.com/forum/#!topic/julia-users/DTyTqib3iOk" rel="nofollow">https://groups.google.com/forum/#!topic/julia-users/DTyTqib3iOk</a><br>
map preserves the shape of the input and does type deduction, whereas pmap does not:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="julia&gt; map(x -&gt; x.^2, 2*ones(2,2))
2x2 Array{Float64,2}:
 4.0  4.0
 4.0  4.0

julia&gt; pmap(x -&gt; x.^2, 2*ones(2,2))
4-element Array{Any,1}:
 4.0
 4.0
 4.0
 4.0"><pre class="notranslate"><code class="notranslate">julia&gt; map(x -&gt; x.^2, 2*ones(2,2))
2x2 Array{Float64,2}:
 4.0  4.0
 4.0  4.0

julia&gt; pmap(x -&gt; x.^2, 2*ones(2,2))
4-element Array{Any,1}:
 4.0
 4.0
 4.0
 4.0
</code></pre></div>
<p dir="auto">From a user's perspective it would be good if both functions had the same interface.</p>