angelolab / ark-analysis

Integrated pipeline for multiplexed image analysis
https://ark-analysis.readthedocs.io/en/latest/
MIT License
74 stars 26 forks source link

Change os.rename to shutil.move #951

Closed cliu72 closed 1 year ago

cliu72 commented 1 year ago

If you haven't already, please read through our contributing guidelines before opening your PR

What is the purpose of this PR?

Apparently Windows doesn't like it when you try to os.rename something that is an "open process" (causing pixel clustering functions to fail). After much experimenting, seems like the fix is easy. shutil.move seems to do the trick.

How did you implement your changes

Change os.rename to shutil.move. Tested on my computer, Ben's, and MIBIAN.

Remaining issues

None