Instalar dependências de ML.NET extrasInstall extra ML.NET dependencies
Na maioria dos casos, em todos os sistemas operacionais, a instalação do ML.NET é tão simples quanto fazer referência ao pacote NuGet apropriado.In most cases, on all operating systems, installing ML.NET is as simple as referencing the appropriate NuGet package.
dotnet add package Microsoft.ML
Em alguns casos, no entanto, há requisitos de instalação adicionais, especialmente quando os componentes nativos são necessários.In some cases though, there are additional installation requirements, particularly when native components are required. Este documento descreve os requisitos de instalação para esses casos.This document describes the installation requirements for those cases. As seções são divididas pelo Microsoft.ML.*
pacote NuGet específico que tem a dependência adicional.The sections are broken down by the specific Microsoft.ML.*
NuGet package that has the additional dependency.
Microsoft. ML. timeseries, Microsoft. ML. AutoMLMicrosoft.ML.TimeSeries, Microsoft.ML.AutoML
Ambos os pacotes têm uma dependência em Microsoft.ML.MKL.Redist
, que tem uma dependência libomp
.Both of these packages have a dependency on Microsoft.ML.MKL.Redist
, which has a dependency on libomp
.
WindowsWindows
Nenhuma etapa de instalação extra é necessária.No extra installation steps required. A biblioteca é instalada quando o pacote NuGet é adicionado ao projeto.The library is installed when the NuGet package is added to the project.
LinuxLinux
Instalar a chave GPG para o repositórioInstall the GPG key for the repository
sudo bash # <type your user password when prompted. this will put you in a root shell> # cd to /tmp where this shell has write permission cd /tmp # now get the key: wget https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS-2019.PUB # now install that key apt-key add GPG-PUB-KEY-INTEL-SW-PRODUCTS-2019.PUB # now remove the public key file exit the root shell rm GPG-PUB-KEY-INTEL-SW-PRODUCTS-2019.PUB exit
Adicionar o repositório APT para MKLAdd the APT Repository for MKL
sudo sh -c 'echo deb https://apt.repos.intel.com/mkl all main > /etc/apt/sources.list.d/intel-mkl.list'
Atualizar pacotesUpdate packages
sudo apt-get update
Instalar o MKLInstall MKL
sudo apt-get install <COMPONENT>-<VERSION>.<UPDATE>-<BUILD_NUMBER>
Por exemplo:For example:
sudo apt-get install intel-mkl-64bit-2020.0-088
Determinar o local de
libiomp.so
Determine the location oflibiomp.so
find /opt -name "libiomp5.so"
Por exemplo:For example:
/opt/intel/compilers_and_libraries_2020.0.166/linux/compiler/lib/intel64_lin/libiomp5.so
Adicione este local ao caminho da biblioteca de carregamento:Add this location to the load library path:
sudo ldconfig /opt/intel/compilers_and_libraries_2020.0.166/linux/compiler/lib/intel64_lin
MacMac
Instalar a biblioteca com
Homebrew
Install the library withHomebrew
brew update && brew install https://raw.githubusercontent.com/Homebrew/homebrew-core/f5b1ac99a7fba27c19cee0bc4f036775c889b359/Formula/libomp.rb && brew link libomp --force