pydeps icon indicating copy to clipboard operation
pydeps copied to clipboard

Possible to create a .py file dependency graph instead of a python module dependency graph?

Open isaachowen opened this issue 4 years ago • 2 comments

I'm exploring an unfamiliar python package and am looking for nice ways to visualize it to wrap my head around it quicker. I'm curious about the specific .py files that are called when importing features from various python modules, less interested in the modules at this point in my exploration.

I'd like to see the nodes of the graph be .py files as opposed to modules. Is something like this possible? Could it potentially be a feature to include?

I don't see any flags to do something like that, and I wonder if it would be possible given what you've already implemented.

Very cool package! Thanks

isaachowen avatar Dec 17 '21 03:12 isaachowen

There is a one-to-one correspondence between modules and file names in python, i.e. module a.b.c is either in file a/b/c.py or a/b/c/__init__.py. Besides that you can look at the intermediate format, which has an explicit file reference --show-deps or --show-raw-deps. Let me know if that will work for you.

thebjorn avatar Dec 17 '21 12:12 thebjorn

@isaachowen Are you asking for .py file that is a graph of the nodes and edges?

av-guy avatar Mar 10 '22 14:03 av-guy