HNPE: Leveraging Global Parameters for Neural Posterior Estimation