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

build-jax.sh: update default source dir #394

Merged
merged 1 commit into from
Nov 24, 2023
Merged

build-jax.sh: update default source dir #394

merged 1 commit into from
Nov 24, 2023

Conversation

olupton
Copy link
Collaborator

@olupton olupton commented Nov 24, 2023

This changed in #371.

@olupton olupton requested a review from nouiz November 24, 2023 09:48
@nouiz
Copy link
Collaborator

nouiz commented Nov 24, 2023

@DwarKapex Why this changed upstream?
And how the CI didn't crash with this issue?

@nouiz
Copy link
Collaborator

nouiz commented Nov 24, 2023

I'll merge now as the CI seems good and others are OOTO.
But it would be good to understand why the CI didn't crash and make sure it crashes if such issue appear again.

@nouiz
Copy link
Collaborator

nouiz commented Nov 24, 2023

I'll merge now as the CI seems good and others are OOTO. But it would be good to understand why the CI didn't crash and make sure it crashes if such issue appear again.

I found, Dockerfile.jax do:

RUN build-jax.sh \
    --bazel-cache ${BAZEL_CACHE} \
    --src-path-jax ${SRC_PATH_JAX} \
    --src-path-xla ${SRC_PATH_XLA} \
    --sm all \
    --xla-arm64-patch /opt/xla-arm64-neon.patch \
    --clean

we need to be able to overwrite the JAX, so we need to pass the flag in that case. So I'm not sure how to make it crash next time.

@olupton
Copy link
Collaborator Author

olupton commented Nov 24, 2023

RUN build-jax.sh \
--bazel-cache ${BAZEL_CACHE} \
--src-path-jax ${SRC_PATH_JAX} \
--src-path-xla ${SRC_PATH_XLA} \
--sm all \
--xla-arm64-patch /opt/xla-arm64-neon.patch \
--clean
the default isn't used in the Dockerfile.

I'm not sure if there's a reason the Dockerfile has to be parametrised on this.

@nouiz nouiz merged commit 0093140 into main Nov 24, 2023
70 of 74 checks passed
@nouiz nouiz deleted the olupton/jax-src-dir branch November 24, 2023 14:42
@nouiz
Copy link
Collaborator

nouiz commented Nov 24, 2023

the default isn't used in the Dockerfile.

I see it on line 10 of the Dockerfile.jax:

ARG SRC_PATH_JAX=/opt/jax

I'm not sure if there's a reason the Dockerfile has to be parametrised on this.

I think it is done like this to allows the manual start of CI workflow to specify which commit/branch/version we want to use.
We could use a special token, like DEFAULT, to use the default in the build-jax.sh script. This would prevent to duplicate the default value at 2 places. But this is a rare thing that we change this default, so I'm not sure it is worthwhile the extra complexity.

@olupton
Copy link
Collaborator Author

olupton commented Nov 24, 2023

the default isn't used in the Dockerfile.

I see it on line 10 of the Dockerfile.jax:

ARG SRC_PATH_JAX=/opt/jax

I meant that the default inside build-jax.sh is not used when it is called from the Dockerfile, because --src-jax-path is always passed.

I'm not sure if there's a reason the Dockerfile has to be parametrised on this.

I think it is done like this to allows the manual start of CI workflow to specify which commit/branch/version we want to use. We could use a special token, like DEFAULT, to use the default in the build-jax.sh script. This would prevent to duplicate the default value at 2 places. But this is a rare thing that we change this default, so I'm not sure it is worthwhile the extra complexity.

Agree we don't need more complexity. (Not sure why changing commit/branch/version would need a different source dir.)

@nouiz
Copy link
Collaborator

nouiz commented Nov 24, 2023

Agree we don't need more complexity. (Not sure why changing commit/branch/version would need a different source dir.)

You are right, my explanation wasn't the right one. In the dockerfile, it isn't useful. We should be able to remove it there.
This parameters should be only useful for dev that can want to change the directory.

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.

2 participants