# Does Chain_break_fraction value depend on chain_break_method?

`from dwave.embedding import unembed_samplesetunembedded = unembed_sampleset(result, emb, bqm, chain_break_method=MinimizeEnergy(bqm, emb), chain_break_fraction=True)`

Then we can print chain_break_fraction value. Does the value depend on chain_break_method or the chain_break_fraction value is the same for all chain_break_method?

1 comment
• Hello,

So the chain_break_fraction actually depends on the chain_strength parameter.

What happens is that if the chain_strength is too low, the chains will break, causing a non-zero chain_break_fraction value.

Ideally this value should be zero, and if it is not, then the chain_strength should be adjusted to make it zero if possible.

The best way is to set it to the magnitude (absolute value) of the largest bias on any qubit or coupler (linear or quadratic terms).

For example, if the most extreme bias was -24, then you would start with a chain strength of 24, and then adjust up or down until a good value is found where the chains don't break.

In case the chain_strength is not set, then the chain will break, and the chain_break_method will attempt to "correct" the chain break in post processing (classical computing) using whatever method it is set to.

For example, the majority_vote method will set all of the values in the chain to the value with the most qubits that took on that value.
So if you had a chain that was 5 qubits long and 3 of those qubits resulted in 1, while 2 resulted in 0, then the chain_break_method would set all 5 qubits to 1.

Each chain_break_method behaves differently, so reading the documentation is important.
It is also possible to customize the chain break functionality to behave in a manner that you prefer by writing your own chain break method that conforms to the method signature requirements.

Note that here you are using MinimizeEnergy, which is not a chain break method, so it behaves and is used a little differently.
There are examples of how to use the MinimizeEnergy class here:
https://docs.ocean.dwavesys.com/projects/system/en/stable/reference/minimize_energy/dwave.embedding.chain_breaks.MinimizeEnergy.html#dwave.embedding.chain_breaks.MinimizeEnergy

I hope this helps clear some things up.

Please reach out to us if you get stuck or need further clarification.