Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: Pydeps for pipelines #225

Open
landoskape opened this issue Jul 2, 2024 · 2 comments
Open

Feature Request: Pydeps for pipelines #225

landoskape opened this issue Jul 2, 2024 · 2 comments

Comments

@landoskape
Copy link

Pydeps is an excellent tool for visualizing dependencies. I wonder if it could be adapted to show the dynamic dependencies of a particular pipeline. For example, imagine a simple pipeline built with numpy and matplotlib that goes from raw data to visualization.

Here's an example:

import numpy as np
from numpy_processing import process0, process1, process2 # which all have their own dependencies
from matplotlib_visualization import prepare_vis, vis # also with their own dependencies

fname = 'some_file_name.npy'
data = np.load(fname)

output0 = process0(data)
output1 = process1(output0)
output2 = process2(output1)

vis_prms = prepare_vis(output2)
vis(output2, vis_prms)

We've defined a pipeline which uses these methods in the following order:

  1. np.load
  2. numpy_processing.process0
  3. numpy_processing.process1
  4. numpy_processing.process2
  5. prepare_vis
  6. vis

Wouldn't it be cool to see a pydeps graph where these methods are provided as input, are positioned on the left column of a graph moving downwards, and the dependencies are shown to the right pointing to each part of the pipeline?

If this is possible, please let me know. If there's interest and I could be of assistance in writing code to support it, let me know.

@thebjorn
Copy link
Owner

thebjorn commented Jul 3, 2024

Hi Andrew, thank you for your kind words. Your idea does sound interesting (and even useful), but perhaps not a perfect fit for pydeps..? I've known to occasionally be wrong, though, and I'm always happy to merge PRs (I'm also happy to help if you get stuck...)

@landoskape
Copy link
Author

Let me look around and have a go at it. I'll ping if I need some help. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants