Relabel the variables of the BQM to integers.

Parameters:inplace (bool, optional, default=True) – If True, the binary quadratic model is updated in-place; otherwise, a new binary quadratic model is returned.
Returns:A 2-tuple containing:
A binary quadratic model with the variables relabeled. If inplace is set to True, returns itself.

dict: The mapping that will restore the original labels.

Return type:tuple