# Legacy package - torch.legacy¶

Package containing code ported from Lua torch.

To make it possible to work with existing models and ease the transition for current Lua torch users, we’ve created this package. You can find the nn code in torch.legacy.nn, and optim in torch.legacy.optim. The APIs should exactly match Lua torch.