lasp / lasp/space_packet_parser

Improve memory efficiency when reading packet files

Open
#185 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement help wanted question
Dominant language
Python
Stars
39
Forks
15
Avg merge
2d 16h
Merged PRs (30d)
12

Description

In generators/utils.py::_read_packet_file, if a user passes in a str path, Path, or PathLike (e.g. an S3Path), we read the entire binary file into memory before passing it to the generator object. This is not ideal for memory usage, though it does provide better performance than requiring the generator to repeatedly read from disk.

To support users who want to pass in gigantic files that don't fit in memory using PathLike objects, we can ...

@greglucas can you fill in the blank?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading generators/utils.py::_read_packet_file and the generator object it passes data to. Clarify the missing proposal in the issue before changing behavior; done should allow gigantic files supplied through PathLike objects to be processed without loading the entire binary file into memory.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
backend
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.