Skip to content

VolumeReconstructor ignores OutputExtent and OutputOrigin #228

Open

Description

@Sunderlandkyl

From @Sunderlandkyl on September 21, 2017 18:8

SetOutputExtentFromFrameList is called regardless of whether OutputExtent and OutputOrigin were specified in the configuration file. If this call is skipped manually during debugging, this error occurs:

|ERROR|012.849000| OptimizedInsertSlice: input ScalarType (3)  must match out ScalarType (11)| in C:\Dev\plus\bin64-2015\PlusLib\src\PlusVolumeReconstruction\vtkPlusPasteSliceIntoVolume.cxx(422)

This prevents setting custom output extent to skip unwanted part of volume from being reconstructed, e.g. for quicker debugging (breakpoints with conditions slow down execution speed excruciatingly).

Migrated from https://app.assembla.com/spaces/plus/tickets/1159/details

Copied from original issue: PlusToolkit/PlusApp#21

Activity

  1. Sunderlandkyl commented on Oct 19, 2017

    @Sunderlandkyl
    ContributorAuthor

    2017-02-12 13:09
    Andras Lasso
    Can you describe what class you are referring to? We specify custom output origin, spacing, and extent in Plus Remote and it works fine.

    2017-05-11 10:46
    Dzenan Zukic
    I am talking about volume reconstructor executable, which in turn invokes vtkPlusVolumeReconstructor. VolumeReconstructor.cxx, line 175:

    if (reconstructor->SetOutputExtentFromFrameList(trackedFrameList, transformRepository, errorDetail) != PLUS_SUCCESS)
    

    obliterates OutputOrigin and OutputExtent settings provided in section of the configuration file.

    2017-05-11 10:54
    Andras Lasso
    We usually need the entire volume, but I agree that it could be useful to disable automatic extent setting. If you need this then add a new option:

    cmdargs.AddArgument("--disable-auto-extent", vtksys::CommandLineArguments::NO_ARGUMENT, &disableAutoExtent, "Do not compute extent from the input sequence file but use OutputOrigin and OutputExtent specified in the configuration file.");
    

    2017-05-11 11:19
    Dzenan Zukic
    Wouldn't it be more logical to check whether OutputOrigin and OutputExtent are set, and if they are skip calling SetOutputExtentFromFrameList ?

    2017-05-11 12:04
    Andras Lasso
    Current origin and extent values are saved to XML, so users keep copying those values along with other volume reconstruction parameters. It is very rare that you know origin and extent in advance. So, the values in the config file are most of the time these copy-pasted values, which would not generate meaningful volumes.

    For the very rare occasion when a user intentionally sets origin and extent in the XML, the new flag could be used to bypass automatic extent computation.

  2. jesswg commented on Sep 16, 2018

    @jesswg

    Sunderlandkyl could you provide how to implement cmdargs.AddArgument or provide resources.
    Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions