conda-forge / pytorch-cpu-feedstock

A conda-smithy repository for pytorch-cpu.
BSD 3-Clause "New" or "Revised" License
18 stars 50 forks source link

Adjust OSX builds to avoid co-installed incompatible versions of OpenMP #244

Closed conda-forge-admin closed 4 months ago

conda-forge-admin commented 4 months ago

Hi! This is the friendly automated conda-forge-webservice.

I've started rerendering the recipe as instructed in #243.

If I find any needed changes to the recipe, I'll push them to this PR shortly. Thank you for waiting!

Here's a checklist to do before merging.

conda-forge-webservices[bot] commented 4 months ago

Hi! This is the friendly automated conda-forge-linting service.

I just wanted to let you know that I linted all conda-recipes in your PR (recipe) and found it was in an excellent condition.

hmaarrfk commented 4 months ago

lets see if we can recreate the failure in https://github.com/conda-forge/pytorch-cpu-feedstock/pull/245

hmaarrfk commented 4 months ago

@isuruf for my knowledge, have you tested the proposed fix? or do I need to think of a testing plan? My 8GB MacBook might not be able to compile this locally.

Maybe I'll have to upload the build artifacts?

hmaarrfk commented 4 months ago

As a followup, are we concerned to overloading the large runners? Should I continue to cancel the linux jobs even once we merge?

isuruf commented 4 months ago

Yes, I tested. You can also test this in an existing installation, by doing

pushd $SP_DIR/torch
for f in bin/* lib/* share/* include/*; do
  if [[ -e "$PREFIX/$f" ]]; then
    rm -rf $f
    ln -sf $PREFIX/$f $PWD/$f
  fi
done
hmaarrfk commented 4 months ago

You are correct:

cd ${CONDA_PREFIX}/lib/python3.1/site-packages/torch/lib
rm libomp.dylib
ln -s ${CONDA_PREFIX}/lib/libomp.dylib
cd 
python -c "import numpy; import torch; torch.zeros((1024, 1024), dtype=torch.uint8)"

no longer segfaults

hmaarrfk commented 4 months ago

Thank you for troubleshooting for this with me!

hmaarrfk commented 4 months ago

I'm going to merge and cancel the linux builds to save linux users a 500MB+ download.