Unfortunately, you must restore it in iTunes on your computer. There is no way to retrieve a forgotten pass lock code.
Connect to iTunes on the computer you usually Sync with and “ Restore “... Can you select the iPod in the iTunes and restore it??
Place the iOS device in Recovery Mode and then connect to your computer and restore via iTunes. The iPod will be erased.
If recovery mode does not work try DFU mode.