Skip to content
This repository has been archived by the owner on May 18, 2020. It is now read-only.

Fix issue with strand_specific code #2

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

zeehio
Copy link

@zeehio zeehio commented Nov 10, 2017

Hi,

As the parmap author I have been contacting parmap users to make sure they can smoothly update to the minor API changes I had to make in parmap==1.5.0. This pull request updates your code to reflect those changes. Basically I had to replace parallel=True with pm_parallel=True. It has been so far a very smooth upgrade with no issues in any other parmap user.

Unfortunately, I have found an issue in your usage of parmap that may have lead to some incorrect results. Until parmap 1.5.0, parmap.map supported multiple positional arguments, but not keyword arguments. This was stated in the README. However, you were using parmap and trying to pass the strand_specific= keyword argument in this line of code. I am sorry to say that this keyword argument was never passed to the underlying coverage_single function, and therefore the default strand_specific=False was always used.

If you want to check the impact of this bug on your results, please make sure you have the latest parmap version installed (which does support keyword arguments, you can use pip install -U parmap) and run your code again, once you have accepted this pull request. I hope for the best and that the impact is small.

Best,

Sergio

parmap 1.5.0 introduced support for passing keyword arguments to
mapped functions, as keyword arguments were not supported before.

The drawback of this new feature is that a consistent
naming of parmap arguments is needed in order to prevent conflicts
between parmap arguments and user-defined arguments. The new parmap
convention is to prefix all its arguments with "pm_" (for parmap)
as documented http://parmap.readthedocs.io/en/latest/

This commit updates the cll-chromatin parmap calls to
use the new API, removing the deprecation warnings that appear with
parmap==1.5.1 (the parmap version used).
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant