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

Fix setup.py for Anaconda #17111

Open
wants to merge 6 commits into
base: main
Choose a base branch
from
Open

Fix setup.py for Anaconda #17111

wants to merge 6 commits into from

Conversation

blozano-tt
Copy link
Contributor

@blozano-tt blozano-tt commented Jan 25, 2025

Problem description

For some reason we are manually specifying the python modules to be packaged into a wheel, and/or installed using pip.

We aren't relying on auto-discovery.

When I tried to package in Anaconda with Python 3.10, I could not import ttnn.

What's changed

Adjusted to use auto discovery function.
For some reason I had to add an __init__.py to tt_lib.fused_ops

Checklist

  • Post commit CI passes
  • Blackhole Post commit (if applicable)
  • Model regression CI testing passes (if applicable)
  • Device performance regression CI testing passes (if applicable)
  • (For models and ops writers) Full new models tests passes
  • New/Existing tests provide coverage for changes

@blozano-tt
Copy link
Contributor Author

Looks like this attempt to do the right thing has broken the packaging of some kernels.

Need to triage.

             Always | FATAL    | Kernel file ttnn/cpp/ttnn/operations/eltwise/unary/device/kernels/compute/eltwise_sfpu.cpp doesn't exist!
             Always | FATAL    | Kernel file ttnn/cpp/ttnn/operations/eltwise/unary/device/kernels/dataflow/reader_unary_interleaved_start_id.cpp doesn't exist!
             Always | FATAL    | Kernel file ttnn/cpp/ttnn/operations/eltwise/unary/device/kernels/dataflow/writer_unary_interleaved_start_id.cpp doesn't exist!
             Always | FATAL    | Failed to generate binaries for eltwise_sfpu TT_FATAL @ /home/ubuntu/actions-runner/_work/tt-metal/tt-metal/tt_metal/jit_build/genfiles.cpp:80: does_file_exist

info:
Kernel file ttnn/cpp/ttnn/operations/eltwise/unary/device/kernels/compute/eltwise_sfpu.cpp doesn't exist!

@tt-rkim
Copy link
Collaborator

tt-rkim commented Jan 25, 2025

ah to get needed files in ttnn, which were the kernel files, I believe the ttnn.cpp declaration was needed when we didn't use autodiscovery before

I'm not sure if that's correct, but that's what we did before

@blozano-tt
Copy link
Contributor Author

ah to get needed files in ttnn, which were the kernel files, I believe the ttnn.cpp declaration was needed when we didn't use autodiscovery before

I'm not sure if that's correct, but that's what we did before

I’m trying to combine auto discovery with manual adjust in this PR. Let’s see if I can get there.

@blozano-tt
Copy link
Contributor Author

ah to get needed files in ttnn, which were the kernel files, I believe the ttnn.cpp declaration was needed when we didn't use autodiscovery before

I'm not sure if that's correct, but that's what we did before

@tt-rkim for when you are feeling better.

I manually add ttnn.cpp in the latest commit and same failure.

what is this python black magic?

maybe these cpp files are supposed to be mentioned in the manifest?

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

Successfully merging this pull request may close these issues.

3 participants