original_docstring: 
      Predict the class (or classes) of an image using
      a trained deep learning model.
      
docstring: Predict the class (or classes) of an image using
  a trained deep learning model.
docstring_tokens: Predict the class ( or classes ) of an image using a trained deep learning model .
code: def predict(image_path, model, topk=1):
      # just 2 classes from 1 single output
      '''
      Predict the class (or classes) of an image using
      a trained deep learning model.
      '''
      image = process_image(image_path)
  
      # Convert image to PyTorch tensor first
      image = torch.from_numpy(image).type(torch.cuda.FloatTensor)
  
      # Returns a new tensor with a dimension of size
      # one inserted at the specified position.
      image = image.unsqueeze(0)
      output = model(image)
      probabilities = torch.sigmoid(output)
  
      # Probabilities and the indices of those probabilities
      # corresponding to the classes
      top_probabilities, top_indices = probabilities.topk(topk)
  
      # Convert to lists
      top_probabilities = top_probabilities.detach().type(
          torch.FloatTensor).numpy().tolist()[0]
      top_indices = top_indices.detach().type(
          torch.FloatTensor).numpy().tolist()[0]
  
      top_classes = []
  
      if probabilities > 0.5:
          top_classes.append("Melanoma")
      else:
          top_classes.append("Benign")
  
      return top_probabilities, top_classes
code_tokens: def predict ( image_path , model , topk = 1 ) : image = process_image ( image_path ) image = torch . from_numpy ( image ) . type ( torch . cuda . FloatTensor ) image = image . unsqueeze ( 0 ) output = model ( image ) probabilities = torch . sigmoid ( output ) top_probabilities , top_indices = probabilities . topk ( topk ) top_probabilities = top_probabilities . detach ( ) . type ( torch . FloatTensor ) . numpy ( ) . tolist ( ) [ 0 ] top_indices = top_indices . detach ( ) . type ( torch . FloatTensor ) . numpy ( ) . tolist ( ) [ 0 ] top_classes = [ ] if probabilities > 0.5 : top_classes . append ( "Melanoma" ) else : top_classes . append ( "Benign" ) return top_probabilities , top_classes
short_docstring: Predict the class (or classes) of an image using
  a trained deep learning model.
short_docstring_tokens: Predict the class ( or classes ) of an image using a trained deep learning model .
comment: # just 2 classes from 1 single output$SEP$'''
      Predict the class (or classes) of an image using
      a trained deep learning model.
      '''$SEP$# Convert image to PyTorch tensor first$SEP$# Returns a new tensor with a dimension of size$SEP$# one inserted at the specified position.$SEP$# Probabilities and the indices of those probabilities$SEP$# corresponding to the classes$SEP$# Convert to lists