<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>http://tomwiki.com/index.php?action=history&amp;feed=atom&amp;title=CPLEX_Parallel_Mode</id>
	<title>CPLEX Parallel Mode - Revision history</title>
	<link rel="self" type="application/atom+xml" href="http://tomwiki.com/index.php?action=history&amp;feed=atom&amp;title=CPLEX_Parallel_Mode"/>
	<link rel="alternate" type="text/html" href="http://tomwiki.com/index.php?title=CPLEX_Parallel_Mode&amp;action=history"/>
	<updated>2026-11-01T23:02:24Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.1</generator>
	<entry>
		<id>http://tomwiki.com/index.php?title=CPLEX_Parallel_Mode&amp;diff=1012&amp;oldid=prev</id>
		<title>Elias: Created page with &quot;{{Part Of Manual|title=the CPLEX Manual|link=CPLEX}} Sets the parallel optimization mode (PARALLELMODE in CPLEX Parameter Table). Possible modes are automatic, dete...&quot;</title>
		<link rel="alternate" type="text/html" href="http://tomwiki.com/index.php?title=CPLEX_Parallel_Mode&amp;diff=1012&amp;oldid=prev"/>
		<updated>2011-08-17T14:04:20Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;{{Part Of Manual|title=the CPLEX Manual|link=&lt;a href=&quot;/index.php?title=CPLEX&quot; title=&quot;CPLEX&quot;&gt;CPLEX&lt;/a&gt;}} Sets the parallel optimization mode (PARALLELMODE in &lt;a href=&quot;/index.php?title=CPLEX_Parameter_Table&quot; title=&quot;CPLEX Parameter Table&quot;&gt;CPLEX Parameter Table&lt;/a&gt;). Possible modes are automatic, dete...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{Part Of Manual|title=the CPLEX Manual|link=[[CPLEX|CPLEX]]}}&lt;br /&gt;
Sets the parallel optimization mode (PARALLELMODE in [[CPLEX Parameter Table]]). Possible modes are automatic, deterministic, and opportunistic.&lt;br /&gt;
&lt;br /&gt;
In this context, deterministic means that multiple runs with the same model at the same parameter settings on the same platform will reproduce the same solution path and results. In contrast, opportunistic implies that even slight differences in timing among threads or in the order in which tasks are executed in different threads may pro- duce a different solution path and consequently different timings or different solution vectors during optimization executed in parallel threads. In multithreaded applications, the opportunistic setting entails less synchronization between threads and consequently may provide better performance.&lt;br /&gt;
&lt;br /&gt;
By default, CPLEX  applies as much parallelism as possible while still  achieving deterministic results. That is, when you run the same model twice on the same platform with the same parameter settings, you will see the same solution and optimization run. This condition is referred to as the deterministic mode.&lt;br /&gt;
&lt;br /&gt;
More opportunities to exploit parallelism are available if you do not require determinism. In other words, CPLEX can find more opportunities for parallelism if you do not require and invariant, repeatable solution path and pre- cisely the same solution vector. To use all available parallelism, you need to select the opportunistic parallel mode. In this mode, CPLEX will utilize all opportunities for parallelism in order to achieve best performance.&lt;br /&gt;
&lt;br /&gt;
However, in opportunistic mode, the actual optimization may differ from run to run, including the solution time itself.&lt;br /&gt;
&lt;br /&gt;
==Deterministic and Sequential Optimization==&lt;br /&gt;
&lt;br /&gt;
A truly  parallel deterministic algorithm is available only for MIP optimization.&lt;br /&gt;
&lt;br /&gt;
Only opportunistic parallel algorithms (barrier and concurrent optimizers) are available for continuous models. (Each of the simplex algorithms runs sequentially on a continuous model.)&lt;br /&gt;
&lt;br /&gt;
Consequently, when parallel mode is set to deterministic, both barrier and concurrent optimizers are restricted to run only sequentially, not in parallel.&lt;br /&gt;
&lt;br /&gt;
==Callbacks and MIP Optimization==&lt;br /&gt;
&lt;br /&gt;
If callbacks other than informational callbacks are used for solving a MIP, the order in which the callbacks are called cannot be guaranteed to remain  deterministic, not even in deterministic  mode.  Thus, to make sure of deterministic runs when the parallel mode parameter is at its default setting, CPLEX  will  revert to sequential solving of the MIP in the presence of query callbacks, diagnostic callbacks, or control callbacks.&lt;br /&gt;
&lt;br /&gt;
Consequently, if your application invokes query, diagnostic, or control callbacks, and you still prefer deterministic search, you can choose value 1 (one), overriding the automatic setting and turning on deterministic search. It is then your responsibility to make sure that your callbacks do not perform operations that could lead to opportunis- tic behavior and are implemented in a thread-safe way. To meet these conditions, your application must not store and must not update any information in the callbacks.&lt;br /&gt;
&lt;br /&gt;
==Determinism vs Opportunism  in Development and Deployment==&lt;br /&gt;
&lt;br /&gt;
This parameter also allows you to turn  off this default setting by choosing value -1 (minus one).  Cases where you might wish to turn off deterministic search include situations where you want to take advantage of possibly faster performance of opportunistic parallel MIP optimization in multiple threads after you have confirmed that deterministic parallel MIP optimization produced the results you expected. For example, you may want to develop your application in deterministic mode, taking advantage of the invariance and repeatability of the solution path and results until you verify that your model and application behave as expected; then you might want to turn off default deterministic mode and run your application in opportunistic mode to see  whether your particular model and application benefit from possible performance  improvements; if so, you might choose to deploy your application in opportunistic mode.&lt;br /&gt;
&lt;br /&gt;
==Interaction with  Threads Parameter==&lt;br /&gt;
&lt;br /&gt;
Settings of this parallel mode parameter interact with settings of the thread parameter (THREADS).&lt;br /&gt;
&lt;br /&gt;
The default (automatic) setting of the parallel mode parameter allows CPLEX to choose between  deterministic and opportunistic mode depending on the threads parameter. If the threads parameter is set to its automatic setting (the default), CPLEX chooses deterministic mode.&lt;br /&gt;
&lt;br /&gt;
Otherwise, if the threads parameter is set to a value greater than one, CPLEX chooses opportunistic mode&lt;/div&gt;</summary>
		<author><name>Elias</name></author>
	</entry>
</feed>