A method of training a neural network for reducing noise in an image, comprising obtaining a plurality of input images from an imaging device; identifying subsets of the input images, wherein each input image of a subset of input images depicts a same object as the other input images of that subset; generating a plurality of target images, wherein a target image is generated by combining the input images of one of the subsets, to reduce a noise; generating a plurality of training pairs, wherein a training pair comprises one of the target images, and a training image based on at least one but not all of the input images of the subset corresponding to said one of the target images, wherein if the training image is based on more than one input image, generating the training image by combining said more than one but not all of the input images of the subset of input images to reduce noise of the training image; and training a neural network using the plurality of training pairs, wherein an input to the neural network comprises the training image of a certain training pair of the plurality of training pairs, and a target output of the neural network comprises the target image of the certain training pair, wherein the plurality of training pairs comprises a first training pair comprising a first training image that is based on a first number K 1 of input images, and a second training pair comprising a second training image that is based on a second number K 2 of input images, wherein the first number K 1 is different from the second number K 2 , wherein the plurality of training pairs comprise training pairs having the same target image but different training images that are based on different numbers of input images. obtaining a plurality of input images from an imaging device; identifying subsets of the input images, wherein each input image of a subset of input images depicts a same object as the other input images of that subset; generating a plurality of target images, wherein a target image is generated by combining the input images of one of the subsets, to reduce a noise; generating a plurality of training pairs, wherein a training pair comprises one of the target images, and a training image based on at least one but not all of the input images of the subset corresponding to said one of the target images, wherein if the training image is based on more than one input image, generating the training image by combining said more than one but not all of the input images of the subset of input images to reduce noise of the training image; and one of the target images, and a training image based on at least one but not all of the input images of the subset corresponding to said one of the target images, wherein if the training image is based on more than one input image, generating the training image by combining said more than one but not all of the input images of the subset of input images to reduce noise of the training image; and training a neural network using the plurality of training pairs, wherein an input to the neural network comprises the training image of a certain training pair of the plurality of training pairs, and a target output of the neural network comprises the target image of the certain training pair, wherein the plurality of training pairs comprises a first training pair comprising a first training image that is based on a first number K 1 of input images, and a second training pair comprising a second training image that is based on a second number K 2 of input images, wherein the first number K 1 is different from the second number K 2 , wherein the plurality of training pairs comprise training pairs having the same target image but different training images that are based on different numbers of input images. <EOS>