Skip to content

Commit

Permalink
Impoved support for logging when training cellpose (#6)
Browse files Browse the repository at this point in the history
* adds support for cellpose 1.0

* Bump cellpose version
  • Loading branch information
lacan authored Feb 10, 2022
1 parent 23a263d commit d16b539
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ ext.moduleName = 'qupath.extension.cellpose'

description = 'QuPath extension to use Cellpose'

version = "0.3.2"
version = "0.3.3"

dependencies {
def qupathVersion = "0.3.2" // For now
Expand Down
5 changes: 3 additions & 2 deletions src/main/java/qupath/ext/biop/cellpose/Cellpose2D.java
Original file line number Diff line number Diff line change
Expand Up @@ -583,8 +583,6 @@ public File train() {
*/
private void runCellposeTraining() throws IOException, InterruptedException {

//python -m cellpose --train --dir ~/images_cyto/train/ --test_dir ~/images_cyto/test/ --pretrained_model cyto --chan 2 --chan2 1

// Create command to run
VirtualEnvironmentRunner veRunner = new VirtualEnvironmentRunner(cellposeSetup.getEnvironmentNameOrPath(), cellposeSetup.getEnvironmentType(), this.getClass().getSimpleName() + "-train");

Expand Down Expand Up @@ -635,6 +633,9 @@ private void runCellposeTraining() throws IOException, InterruptedException {

if (useGPU) cellposeArguments.add("--use_gpu");

if (cellposeSetup.getVersion().equals(CellposeSetup.CellposeVersion.CELLPOSE_1))
cellposeArguments.add("--verbose");

veRunner.setArguments(cellposeArguments);

// Finally, we can run Cellpose
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,6 @@ public Version getQuPathVersion() {

@Override
public Version getVersion() {
return Version.parse("0.3.2");
return Version.parse("0.3.3");
}
}

0 comments on commit d16b539

Please sign in to comment.