Australian academic Kylie Moore-Gilbert has been freed from an Iranian prison after more than 800 days in captivity on spying charges.