Create magnet.py