Skip to content

Commit c26e8e1

Browse files
committed
fix #1180 example not working from docs
1 parent 9d59b2e commit c26e8e1

File tree

2 files changed

+10
-3
lines changed

2 files changed

+10
-3
lines changed

docs/index.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@ can install it as ``pip install cellpose[gui]``.
1414
- talk
1515

1616

17+
18+
**See details on migrating from Cellpose 3 to 4 in** :ref:`Settings`
19+
1720
Old releases:
1821
-----------------------------
1922

docs/settings.rst

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,19 @@ Settings
66
The important settings are described on this page.
77
See the :ref:`cpmclass` for all run options.
88

9-
Here is an example of calling the Cellpose class and
9+
.. warning::
10+
Cellpose 3 used ``models.Cellpose`` class which has been removed in Cellpose 4. Users should
11+
now only use the ``models.CellposeModel``` class.
12+
13+
Here is an example of calling the ``CellposeModel`` class and
1014
running a list of images for reference:
1115

1216
::
1317

1418
from cellpose import models
1519
from cellpose.io import imread
1620

17-
model = models.Cellpose(gpu=True)
21+
model = models.CellposeModel(gpu=True)
1822

1923
files = ['img0.tif', 'img1.tif']
2024
imgs = [imread(f) for f in files]
@@ -36,7 +40,7 @@ you will want to omit it from the input, or combine it with the cytoplasm channe
3640
from cellpose import models
3741
from cellpose.io import imread
3842

39-
model = models.Cellpose(gpu=True)
43+
model = models.CellposeModel(gpu=True)
4044

4145
img = imread("img.tif") # tiff is n x 100 x 100
4246

0 commit comments

Comments
 (0)