Skip to content

Commit 76a0ec6

Browse files
committed
Update StarDist to actually use existing variable ENV_NAME for environment configuration
1 parent 134b91d commit 76a0ec6

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/main/java/org/mastodon/mamut/detection/stardist/StarDist.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -178,13 +178,13 @@ private Path getStarDistModelRoot()
178178
{
179179
if ( modelType.getModelPath() == null )
180180
return null;
181-
return Paths.get( System.getProperty( "user.home" ), ".local", "share", "appose", "stardist", "models", modelType.getModelPath() );
181+
return Paths.get( System.getProperty( "user.home" ), ".local", "share", "appose", ENV_NAME, "models", modelType.getModelPath() );
182182
}
183183

184184
private static void createConfigFromBioimageio( final ModelDescriptor descriptor, final String modelDir )
185185
throws IOException
186186
{
187-
Map< String, Object > stardistMap = Cast.unchecked( descriptor.getConfig().getSpecMap().get( "stardist" ) );
187+
Map< String, Object > stardistMap = Cast.unchecked( descriptor.getConfig().getSpecMap().get( ENV_NAME ) );
188188
Map< String, Object > stardistConfig = Cast.unchecked( stardistMap.get( "config" ) );
189189
File jsonFile = new File( modelDir, "config.json" );
190190
logger.info( "Creating config.json file: {}", jsonFile.getAbsolutePath() );

0 commit comments

Comments
 (0)