Skip to content

Incomplete transfer of module to device (only with 0.101.3) #1185

@dje-dev

Description

@dje-dev

Upon upgrading to 0.101.3 a previously working network now throws exception upon calling forward. The module is constructed on CPU with multiple layers in constructor and as normal, RegisterComponents is called. Module is subsequently moved to cuda. Most layers successfully are transferred, but at least one (LayerNorm) remains on cpu. This causes exception below.

Downgrading back to 0.101.2 immediately fixed the problem.

Unhandled exception. System.Runtime.InteropServices.ExternalException (0x80004005): Expected all tensors to be on the same device, but found at least two devices, cuda:0 and cpu! (when checking argument for argument weight in method wrapper_CUDA__native_layer_norm)

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