Questions tagged [parallelization]

Questions on parallel computing in Mathematica.

Filter by
Sorted by
Tagged with
3
votes
1answer
32 views

Is there any sequence using OpenAppend and ParalleTable for continuing writing data?

After I post the question writing data without erasing exist data when quit kernel , I can successfully use OpenAppend to realize it. But if I work with ...
10
votes
2answers
282 views

Understanding Parallelize methods

In the documentation page for Parallelize, we find the methods that can be used. I do not quite understand the difference between Method->"CoarsestGrained" and <...
2
votes
0answers
59 views

Launch Kernels on Windows 10 from Raspberry Pi (linux) over SSH

I am trying to launch remote kernels on a Windows 10 PC (remote) from a Raspberry Pi 4 (Master or local). Both machines have V12 installed. On the Windows machine, I have installed OpenSSH per ...
2
votes
0answers
57 views

NBodySimulation in ParallelTable [closed]

When I use the NBodySimulation in a ParallelTable I do not get multiple processors effectively activating. If I want to sweep ...
2
votes
0answers
69 views

ParallelSubmit does not trigger computations

I am having some problems with parallel computations. I'm afraid it may be a "known issue" but I haven't found any solution. In general, my script looks like this ("prepare" and "process" are my own ...
2
votes
1answer
34 views

Operators without built-in meaning are incompatible with parallel evaluation

Mathematica has a useful set of Operators Without Built-In Meanings. For example: CenterDot, CircleDot, ...
2
votes
1answer
91 views

ParallelTable giving totally wrong answer

Following suggestion I created the simplest error giving code ...
1
vote
0answers
53 views

How to use Mathematica with Slurm?

We have a cluster that uses Slurm. On each node we have put a license that allows for 128 computation kernels (we have a Mathematica for Sites License). How can we run Mathematica on more than one ...
2
votes
0answers
35 views

How to read and write the same text file in Parallelization using ParallelTable? [closed]

I want to know how to write and read a same text file (for example, external.txt ) without conflicts in parallelization. The following is just a small idea, but the problem is there seems a conflicts ...
0
votes
0answers
23 views

Optimizing and Parallel Computing for Large Dyadic Intervals

I need help with the efficiency of my code i.e. less time so I can compute for large range of values. My function n[x] takes in a number x and outputs the ...
6
votes
1answer
66 views

Parallel Computation with the possibility of calculation failure

I would like to use Mathematica to speed-up a parallel calculation. I envisage each sub-process producing a list of 4 million machine reals. My problem is that sometimes the sub-process (based ...
0
votes
0answers
12 views

Parallel evaluate a cell distributing the definitions

In Cell evaluation and parallel kernels a solution is proposed for how to evaluate multiple cells in parallel. I tried it, but ran into the problem that definitions do not get distributed to the new ...
6
votes
1answer
130 views

Speeding up tensor contractions and multiplication

Consider a tensor $T\in\mathbb{R}^{N\times N\times N\times M}$ and two vectors $x,y\in\mathbb{R}^N$. I want to compute the $N\times M$ vector defined by $X_{ij}=\operatorname{tr}(x^\top T_{:,:,i,j}y)=\...
0
votes
0answers
24 views

Having trouble distributing a large association to sub-kernels

The following seems to work based on memory usage. ...
0
votes
0answers
28 views

How to parallelize the following table

Consider a table: ...
1
vote
1answer
65 views

Parallelization command possible bug

In the following Mathematica compiled program, 3 persons take turns in a fair Russian Roulette Game with 1 bullet in the 6th chamber and we find the probabilities of each person being killed after 1,...
2
votes
0answers
43 views

Possible bug ParallelDo (or better practices for ParallelDo)

ParallelDo is having problems evaluate an expression that evaluates fine outside ParallelDo. The problem is not due to the use ...
1
vote
0answers
68 views

How can I devote all the cores to Mathematica?

I have a problem with the calculations speeds in xAct package. In fact, some of them take lots of seconds. Is there any way to speed up the calculations by engaging all the cores for Mathematica (or ...
2
votes
1answer
80 views

Passing Package Dependencies to Subkernels

Say I have a function f[x_,...]:=... in a *.wl-Package form that depends on a bunch of Packages (some other *.wl files), and say I want to call this function ...
0
votes
1answer
45 views

How to build a matrix of size n + 4 from a matrix of size n and 4 rows and 4 columns?

I have a matrix size n + 4 very long and very complicated and to find my matrix I have a matrix of size n and 3 rows and 3 columns To better understand my problem here is a simple example ...
3
votes
0answers
28 views

ParallelDo and Reap/Sow in combination fails

I just realized the following problem. I tried to speed up a program that reads hundreds of files each of size up to 200+ MB and processes them, therefore I changed a ...
1
vote
0answers
122 views

Surprise: I don't need a new kernel to make to MMA notebooks independent [closed]

People seem to suggest that one needs to start a new kernel to keep multiple Mathematica (MMA) notebooks independent e.g. Kernel management link. But I did not do so and still found my two notebooks ...
7
votes
2answers
77 views

Parallelizing MapAt

What is the best way to parallelize MapAt? Only ParallelMap is provided, but seems bad when executing functions on a subset of a ...
0
votes
1answer
72 views

How do I share my variables and my function output in parallel computing?

Here as a simple example ...
0
votes
0answers
42 views

Parameter sweeps on a HPC cluster

I have a mathematica *.wl file set up, such that there are a couple of parameters defined in the beginning, and, when run, it produces a few outputs. I can run this script on a Slurm-run HPC cluster ...
3
votes
0answers
83 views

Parallel evaluation of RandomVariate for an InterpolatingFunction

I need to generate a lot of point according to a given distribution. I don't have an analytic form of this distribution so I am using an InterpolatingFunction of ~100 points computed numerically. I ...
0
votes
1answer
53 views

Parallel XML import

I need to import some xml information from many pages. I have list of this pages. Doing it in single thread is too long. But I can't access multiple pages from the same IP at the same time. So I need ...
0
votes
0answers
19 views

Parallezation gives LaunchLocal::somefail

I was running a program using parallelization, and I got the following warning message: LinkOpen::linke: No MathLink problem encountered.. SubKernels`LocalKernels`LaunchLocal::somefail: 1 ...
1
vote
0answers
59 views

Write in ParallelTable

Why does ...
0
votes
0answers
78 views
0
votes
0answers
33 views

Saving DownValues for a function computed in parallel

Is it possible to save DownValues of a function computed using a parallelization routine? I have a rather costly function f I wish to evaluate at a grid and save ...
2
votes
2answers
172 views

Parallel Computing Problem [closed]

The program runs out quickly(30 seconds) if I don't do parallel.But when I replace Table with ParallelTable,the Program will keep running,no output results. My code https://privatebin.net/?...
5
votes
1answer
104 views

Which version of Mathematica did DiracDelta become to the derivative of HeavisideTheta from that of UnitStep?

The mathematica's version of my coworkers is 5.0, they use UnitStep to derive formula, However, I also want to use the parallel features so used the latest version ...
0
votes
1answer
57 views

Parallelizing nested for loops

I'm currently computing nested for loops. I count up a few counting variables and compute a value for each set of counting variables, then that value is added to an array. It is a way of adding up ...
0
votes
0answers
31 views

Reading a chunk of data from a stream using Parallelization

I am trying to read a stream and perform some operations in parallel. Here is the logic of the code inside the ParallelDo: 1- Open stream 2- Read chunk of data 3- Close stream 4- Process the data ...
5
votes
1answer
543 views

Why is ParallelDo slower than Do?

I have problems to write parallel code in mathematica. Why is ...
1
vote
1answer
115 views

How to run multiple functions simultaneously by multi-core CPU in Windows?

There exist multiple functions, take them for instance, 3 functions as follows: ...
3
votes
1answer
47 views

PatternTest vs Parallelization

Bug introduced in 10.0 or earlier and fixed in 11.2 Consider the following function ...
0
votes
1answer
82 views

Parallelise numerical integral for contour plot

I have the following integral that I would like to evaluate: ...
5
votes
0answers
114 views

Optimize Use of PeakDetect in Mathematica

I am quite new to Mathematica and I am looking for some advice in order to improve and optimize my code. Here is what I am trying to do: Open a stream Read the stream line by line and store it in "...
1
vote
0answers
46 views

Conversion of STL files to 3D Images

I am trying to convert some stl files to 3d images in MMA 11.3. I came across this post that contained some code making use of parallelization to speed up the process, as follows: ...
1
vote
0answers
39 views

How badly does switching kernel slow down or completely stop Mathematica running jobs?

I have a question on how to run two or more Mathematica jobs on one laptop. For example, I use a local kernel to run a job. Then I open another job and choose Kernel configuration option and choose ...
6
votes
1answer
72 views

How to properly Abort from within a ParallelMap?

If a condition is met within a sub-kernel in the function being mapped, how does one cancel the whole ParallelMap operation? ...
1
vote
0answers
48 views

Privilege violation for file or directory

hopefully somebody can help me out with the following; I have a mathematica .wl script which uses ParallelTable; When I run this locally (laptop) it works ...
0
votes
1answer
71 views

Update initial conditions recursively/sequentially within ParallelTable using NDSolve

I am modelling 3D motion of particles inside a force-field using second-order coupled PDEs, which I solve from time t=t0 to t=t1 with initial conditions x0,y0,z0. I have a total number of "particles" ...
3
votes
1answer
109 views

Why does choosing the method break the parallel computation? [closed]

I have a workable function with using NDSolve with predefined method for solving. But for some reasons I should use the parallel computation. The main problem is that the NDSolve can't build the ...
2
votes
1answer
68 views

ParallelMap vs building pure function on the fly

I have a case where one function builds a pure function whenever it is evaluated. A (admittedly contrived) example would be ...
0
votes
0answers
31 views

ParallelTable fails to finish evaluating after completing computation

I am executing a ParallelTable but the code fails to finish. This is the setup. f is a function. ...
1
vote
0answers
44 views

Clustering different kernel versions

After a good bit of trial and error I have managed to cluster together two OS X machines. The master is running Mathematica 9.0 and the secondary 11.0. All was well and good, the remote command being ...
3
votes
1answer
341 views

Parallele Computing - 2 vs. 4 processor speed [closed]

I am evaluating a code which ends with Table having ParallelEvaluate of a function XXXX[phi, theta, si]. For a grid of 225 ...