2

Does it make sense to use numpy's memmap across multiple cores (MPI)?

I have a file on disk.

Can I create a separate memmap object on each core, and use it to read different slices from the file?

What about writing to it?

1
  • 1
    Could you describe your application in a bit more detail? Also, there is a pretty helpful answer here: stackoverflow.com/questions/16149803/… Commented Jun 20, 2020 at 1:29

1 Answer 1

4

Q : "Does it make sense to use numpy's memmap across multiple cores (MPI)?"

Yes ( ... even without MPI, using just Python native { thread- | process-}-based forms of concurrent-processing )

Q : "Can I create a separate memmap-object on each core, and use it to read different slices from the file?"

Yes.

Q : "What about writing to it?"

The same ( sure, if having been opened in write-able mode ... )

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.