I am using python 3.12.0 with tensorflow 2.16.1 and keras 3.0.5 I've been trying my hands on ML & CNN. To aid my understanding, I copied some sample codes from some sites and, when I try executing them, I keep getting errors which indicate that the tree version I'm using is not the right one.
Two such errors are: 'Module tree does not have the attribute flatten'
and 'Module tree has no attribute map_structure'
I began by doing the following:
(1) 'pip install dm-tree' and dm-tree ver 0.1.8 was successfully installed
(2) 'import tree' from within my program.
My observation is as follows:
The import in (2) does not use the dm-tree in (1) because the system keeps reporting 'Module tree does not have the attribute flatten'. But dm-tree surely contains the attribute 'flatten'.
To confirm that the import in (2) did not use the dm-tree in (1), I did pip uninstall dm-tree, then import tree as in (2) above, and the system still carried out the import without reporting that module tree is missing.
So, what is the sure-proof way of dealing with dm-tree and tree conflict?
How do I ascertain that 'import tree' in my program actually imports from the dm-tree module earlier installed by 'pip install dm-tree'?
Thanks for any assistance.