title: Change colour of UImage from firebase to black and white
body: <p>Is it possible to load an image from firebase using a url and then changing it's color to black and white? 
  If I used an image from assets it works but I'm loading my images from firebase via a url and when I try to apply the code below backgroundProfileImage.image equals nil or an Image is not detected. Im also using SDWebImage load my images if that helps. How can I make this work? I Appreciate the help in advance. Thanks</p>
  
  <pre><code>func ChangeImageColor(){
        //Auto Adjustment to Input Image
          var inputImage = CIImage(image: self.backgroundProfileImage.image!) //backgroundProfileImage is not 
          let options:[String : AnyObject] = [CIDetectorImageOrientation:1 as AnyObject]
          let filters = inputImage!.autoAdjustmentFilters(options: options)
  
          for filter: CIFilter in filters {
              filter.setValue(inputImage, forKey: kCIInputImageKey)
              inputImage =  filter.outputImage
          }
          let cgImage = self.context.createCGImage(inputImage!, from: inputImage!.extent)
          self.backgroundProfileImage.image =  UIImage(cgImage: cgImage!)
  
          //Apply noir Filter
          let currentFilter = CIFilter(name: "CIPhotoEffectTonal")
          currentFilter!.setValue(CIImage(image: UIImage(cgImage: cgImage!)), forKey: kCIInputImageKey)
  
          let output = currentFilter!.outputImage
         // let cgimg = self.context.createCGImage(output!, from: output!.extent)
          let processedImage = UIImage(cgImage: cgimg)
          self.backgroundProfileImage.image = processedImage
             }
          })
      }
  </code></pre>
  
  <p>This is how I'm retrieving the image </p>
  
  <pre><code>self.backgroundProfileImage.sd_setImage(with: URL(string: backgroundProfileImageURL), placeholderImage: UIImage(named: "empty-profile-3.png"))
  </code></pre>
  
  <p>Ok this method works for me </p>
  
  <pre><code> func ChangeImageColor(){
  
     let currentFilter = CIFilter(name: "CIPhotoEffectNoir")
          currentFilter!.setValue(CIImage(image: self.backgroundProfileImage.image!), forKey: kCIInputImageKey)
          let output = currentFilter!.outputImage
          let cgimg = context.createCGImage(output!,from: output!.extent)
          let processedImage = UIImage(cgImage: cgimg!)
          self.backgroundProfileImage.image = processedImage
    }
  </code></pre>