Add pyproject.toml for easy install - #88
Open
alex-bene wants to merge 2 commits into
Open
Conversation
|
this doesn't work. it tries to install detectron before torch is installed |
Author
|
Hello @victkk , thanks for the comment. Could you share the command you ran to install? Indeed there was an error in the |
|
that patch for detectron2 was merged in |
|
Adding some notes from my attempts to build this repository using #!/bin/bash
# root assumed!
apt update && apt install -y libgl1-mesa-glx libglib2.0-0 curl git build-essential
# first get uv
curl -LsSf https://astral.sh/uv/install.sh | sh
source $HOME/.local/bin/env
# now get the latest commit of this pr
git clone https://github.com/facebookresearch/sam-3d-body
cd sam-3d-body
git fetch origin pull/88/head:pr-88
git checkout pr-88
git reset --hard 7c574e15668c0cb2eb67d714a0a7cdaed6f2fdc5
# now install sam-3d-body with this uv
uv venv
# We must manually inject the build-backend tools, because
# --no-build-isolation **disables** the automatic provision of these tools.
uv pip install \
hatchling \
hatch-vcs \
editables \
setuptools \
wheel \
torch --extra-index-url https://download.pytorch.org/whl/cu124
uv sync --extra cu124 --no-build-isolationThis took a long time, but it did work eventually. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add a
pyproject.tomlfile to make the code easier to install for development, but also easy to install as a package.With this, we can install locally for dev with:
uv sync --extra cu128 # or cu124, cu126, cpu depending on your cuda versionand install as a package with:
Solves: #43
Related with: #86