transformers-php icon indicating copy to clipboard operation
transformers-php copied to clipboard

PHP Fatal error: Uncaught TypeError: Codewithkyrian\Transformers\Utils\AutoConfig::__construct(): Argument #1 ($config) must be of type array, null given

Open Tinywan opened this issue 6 months ago • 1 comments

Your question

sudo /usr/local/php-8.3.1/bin/php ./vendor/bin/transformers download openblas-linux-x86_64-0.3.27

✔ Initializing download... PHP Fatal error: Uncaught TypeError: Codewithkyrian\Transformers\Utils\AutoConfig::__construct(): Argument #1 ($config) must be of type array, null given, called in /home/www/build/php8/vendor/codewithkyrian/transformers/src/Utils/AutoConfig.php on line 52 and defined in /home/www/build/php8/vendor/codewithkyrian/transformers/src/Utils/AutoConfig.php:25 Stack trace: #0 /home/www/build/php8/vendor/codewithkyrian/transformers/src/Utils/AutoConfig.php(52): Codewithkyrian\Transformers\Utils\AutoConfig->__construct() #1 /home/www/build/php8/vendor/codewithkyrian/transformers/src/Models/Auto/PretrainedMixin.php(52): Codewithkyrian\Transformers\Utils\AutoConfig::fromPretrained() #2 /home/www/build/php8/vendor/codewithkyrian/transformers/src/Commands/DownloadModelCommand.php(89): Codewithkyrian\Transformers\Models\Auto\PretrainedMixin::fromPretrained() #3 /home/www/build/php8/vendor/symfony/console/Command/Command.php(279): Codewithkyrian\Transformers\Commands\DownloadModelCommand->execute() #4 /home/www/build/php8/vendor/symfony/console/Application.php(1029): Symfony\Component\Console\Command\Command->run() #5 /home/www/build/php8/vendor/symfony/console/Application.php(316): Symfony\Component\Console\Application->doRunCommand() #6 /home/www/build/php8/vendor/symfony/console/Application.php(167): Symfony\Component\Console\Application->doRun() #7 /home/www/build/php8/vendor/codewithkyrian/transformers/bin/transformers(18): Symfony\Component\Console\Application->run() #8 /home/www/build/php8/vendor/bin/transformers(119): include('...') #9 {main} thrown in /home/www/build/php8/vendor/codewithkyrian/transformers/src/Utils/AutoConfig.php on line 25

Context (optional)

PHP Version

/usr/local/php-8.3.1/bin/php -v
PHP 8.3.1 (cli) (built: Dec 25 2023 21:14:50) (NTS)
Copyright (c) The PHP Group
Zend Engine v4.3.1, Copyright (c) Zend Technologies

Reference (optional)

No response

Tinywan avatar Aug 23 '24 01:08 Tinywan