8000 Changing shape of the searchlight · Issue #531 · brainiak/brainiak · GitHub
[go: up one dir, main page]

Skip to content

Changing shape of the searchlight #531

Open

Description

@AntoineBouyeure

Hello,

I would like to change the shape of the searchlight to a cube (which is the default shape of classbrainiak.searchlight.searchlight.Searchlight that is used in the tutorials) to a sphere/ball. I can import a searchlight ball as classbrainiak.searchlight.searchlight.Ball, but I am not sure of what to do next. Specifiying shape in the form of sl = Searchlight(shape=Ball) or sl = Searchlight and then Searchlight.shape=Ball doesnt work. I can't also run directly searchlight with the brainiak.searchlight.searchlight.Ball object.

What should I do to change the shape of the searchlight? I'm sorry if the answer is kind of obvious...

Activity

  1. lcnature commented on Oct 2, 2023

    @lcnature
    Contributor

    Hi,
    Try this?

    from brainiak.searchlight.searchlight import Ball, Searchlight
    sl = Searchlight(shape=Ball)
    
  2. AntoineBouyeure commented on Oct 2, 2023

    @AntoineBouyeure
    Author

    Hi, thanks for your answer! Unfortunately when doing something like sl = Searchlight(sl_rad=5, shape=Ball), the resulting searchlight images are empty. And trying sl = Searchlight(shape=Ball(rad=5)) produces TypeError: 'Ball' object is not callable

  3. lcnature commented on Jul 4, 2024

    @lcnature
    Contributor

    @AntoineBouyeure sorry that I somehow missed your reply. Were you able to solve it later or just gave it up? One guess is that the imaging data has very few voxels.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      0