meta-pytorch / meta-pytorch/data
Router for same functional API
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 1.3k
- Forks
- 179
- Avg merge
- 6d 1h
- Merged PRs (30d)
- 2
Description
🚀 Feature
We could support different DataPipe with same functionality using a same functional API with a router datapipe.
Like open, we can support:
- URL
- IoPath
- Local File
Option 1:
Based on the input (type), we could route it to corresponding DataPipe with extra argument to functional_datapipe
register_funtional_api("open", router_fn=...)
@functional_datapipe("open", route_class=...)
class HTTPReader(IterDataPipe):
...
Option 2:
Implement a dispatcher toward functional_API. This may be more suitable but needed to be designed carefully.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by examining the functional_datapipe registration path and the DataPipe routing entry point described in the issue. Compare the router_fn and dispatcher options for routing open inputs such as URLs, IoPaths, and local files. Done requires an agreed design and implementation plan, with the supported input routes and registration behavior clearly specified.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- api
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100