michaellee1 / CellSeg

MIT License
21 stars 25 forks source link

Updated to work with TensorFlow 2.12 #60

Open luciandipeso opened 1 year ago

luciandipeso commented 1 year ago

Updated to work with newer versions of TensorFlow and to use it as a headless library.

N0AHt commented 1 year ago

Thanks for sharing this - I just got this working with the GPU with your fix :)

This doesn't seem to be supported very actively any more so if you decide to make a fork and maintain it elsewhere please let me know. This PR seems to be the most usable version of the code

For future discoverers of this PR - you can install it locally like this:

first clone the Repo and add a new branch for the pull request:

git clone https://github.com/michaellee1/CellSeg.git
git branch tf2_branch 

Then fetch the pull request to your new branch and switch into that branch

git fetch origin pull/60/head:tf2_branch
git checkout tf2_branch

Modified from: https://stackoverflow.com/questions/21255057/how-to-fetch-someone-elses-pull-request-to-fix-it

You will need to make a new environment to make this work - I had some luck installing everything from scratch (numpy, scipy, etc) by looking through the src imports and adding them to my env. I would leave tensorflow until last and install version 2.12 following the tf guide: https://www.tensorflow.org/install/pip