Edge-assisted Opportunistic Federated Learning for Distributed IoT systems