Low-energy electron-beam diagnostics based on the optical transition radiation