title: Class 'Imagine\Gd\Imagine' not found in yii2
body: <p>I am working on crop image module, I need detail of uploaded image so i am using this function </p>
  
  <pre><code>$image = Image::getImagine()-&gt;open($path);
  $size = $image-&gt;getSize();
  </code></pre>
  
  <p>While using this function it is giving me error </p>
  
  <pre><code>Class 'Imagine\Gd\Imagine' not found
  
                  case self::DRIVER_IMAGICK:
                      if (class_exists('Imagick', false)) {
                          return new \Imagine\Imagick\Imagine();
                      }
                      break;
                  case self::DRIVER_GD2:
                      if (function_exists('gd_info')) {
                          return new \Imagine\Gd\Imagine();
                      }
                      break;
                  default:
                      throw new InvalidConfigException("Unknown driver: $driver");
              }
          }
          throw new InvalidConfigException("Your system does not support any of these drivers: " . implode(',', (array) static::$driver));
  </code></pre>
  
  <p>This error comes from it library files</p>
  
  <pre><code>vendor\yiisoft\yii2\imagine\BaseImage.php
  </code></pre>
  
  <p>How can i solve this issue ? Can anyone please suggest me ?</p>
  
  <p>Namespace is also added</p>
  
  <pre><code>namespace yii\imagine;
  
  use Yii;
  
  use yii\imagine\Image\Box;
  use yii\imagine\Image\Color;
  use yii\imagine\Image\ImageInterface;
  use yii\imagine\Image\ImagineInterface;
  use yii\imagine\Image\ManipulatorInterface;
  use yii\imagine\Image\Point;
  
  
  
  use yii\base\InvalidConfigException;
  use yii\base\InvalidParamException;
  use yii\helpers\ArrayHelper;
  </code></pre>
  
  <p>This is library files, i never changed it, i also did composer update, still it is giving me same error</p>