Weka вне контекста - PullRequest
       66

Weka вне контекста

0 голосов
/ 16 сентября 2018

Я хотел использовать weka в visual studio.Поэтому я преобразовал weka.jar в weka.dll с помощью IKVM с помощью этой команды ikvmc -target: library weka.jar.Преобразование прошло успешно, но в командной строке я получил много предупреждений от ikvm.

note IKVMC0002: Output file is "weka.dll"
warning IKVMC0100: Class "org.tukaani.xz.X86Options" not found
warning IKVMC0100: Class "org.tukaani.xz.FilterOptions" not found
warning IKVMC0100: Class "org.tukaani.xz.PowerPCOptions" not found
warning IKVMC0100: Class "org.tukaani.xz.IA64Options" not found
warning IKVMC0100: Class "org.tukaani.xz.ARMOptions" not found
warning IKVMC0100: Class "org.tukaani.xz.ARMThumbOptions" not found
warning IKVMC0100: Class "org.tukaani.xz.SPARCOptions" not found
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.archivers.sevenz.Coders$1.<init>()V"
    ("org.tukaani.xz.X86Options")
warning IKVMC0100: Class "org.tukaani.xz.FinishableWrapperOutputStream" not foun
d
warning IKVMC0100: Class "org.tukaani.xz.FinishableOutputStream" not found
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.archivers.sevenz.Coders$BCJDecoder.decode(Ljava.lang.String;Ljava.io.I
nputStream;JLorg.apache.commons.compress.archivers.sevenz.Coder;[B)Ljava.io.Inpu
tStream;"
    ("org.tukaani.xz.FilterOptions")
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.archivers.sevenz.Coders$BCJDecoder.encode(Ljava.io.OutputStream;Ljava.
lang.Object;)Ljava.io.OutputStream;"
    ("org.tukaani.xz.FinishableWrapperOutputStream")
warning IKVMC0100: Class "org.tukaani.xz.LZMAInputStream" not found
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.archivers.sevenz.Coders$LZMADecoder.decode(Ljava.lang.String;Ljava.io.
InputStream;JLorg.apache.commons.compress.archivers.sevenz.Coder;[B)Ljava.io.Inp
utStream;"
    ("org.tukaani.xz.LZMAInputStream")
warning IKVMC0100: Class "org.tukaani.xz.DeltaOptions" not found
warning IKVMC0100: Class "org.tukaani.xz.UnsupportedOptionsException" not found
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.archivers.sevenz.DeltaDecoder.decode(Ljava.lang.String;Ljava.io.InputS
tream;JLorg.apache.commons.compress.archivers.sevenz.Coder;[B)Ljava.io.InputStre
am;"
    ("org.tukaani.xz.DeltaOptions")
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.archivers.sevenz.DeltaDecoder.encode(Ljava.io.OutputStream;Ljava.lang.
Object;)Ljava.io.OutputStream;"
    ("org.tukaani.xz.DeltaOptions")
warning IKVMC0100: Class "org.tukaani.xz.LZMA2Options" not found
warning IKVMC0100: Class "org.tukaani.xz.LZMA2InputStream" not found
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.archivers.sevenz.LZMA2Decoder.<init>()V"
    ("org.tukaani.xz.LZMA2Options")
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.archivers.sevenz.LZMA2Decoder.decode(Ljava.lang.String;Ljava.io.InputS
tream;JLorg.apache.commons.compress.archivers.sevenz.Coder;[B)Ljava.io.InputStre
am;"
    ("org.tukaani.xz.LZMA2InputStream")
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.archivers.sevenz.LZMA2Decoder.encode(Ljava.io.OutputStream;Ljava.lang.
Object;)Ljava.io.OutputStream;"
    ("org.tukaani.xz.FinishableWrapperOutputStream")
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.archivers.sevenz.LZMA2Decoder.getDictSize(Ljava.lang.Object;)I"
    ("org.tukaani.xz.LZMA2Options")
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.archivers.sevenz.LZMA2Decoder.getOptions(Ljava.lang.Object;)Lorg.tukaa
ni.xz.LZMA2Options;"
    ("org.tukaani.xz.LZMA2Options")
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.compressors.lzma.LZMACompressorInputStream.<init>(Ljava.io.InputStream
;)V"
    ("org.tukaani.xz.LZMAInputStream")
warning IKVMC0100: Class "org.tukaani.xz.XZ" not found
warning IKVMC0100: Class "org.tukaani.xz.XZInputStream" not found
warning IKVMC0100: Class "org.tukaani.xz.SingleXZInputStream" not found
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.compressors.xz.XZCompressorInputStream.matches([BI)Z"
    ("org.tukaani.xz.XZ")
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.compressors.xz.XZCompressorInputStream.<init>(Ljava.io.InputStream;Z)V
"
    ("org.tukaani.xz.XZInputStream")
warning IKVMC0100: Class "org.tukaani.xz.XZOutputStream" not found
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.compressors.xz.XZCompressorOutputStream.<init>(Ljava.io.OutputStream;)
V"
    ("org.tukaani.xz.XZOutputStream")
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.compressors.xz.XZCompressorOutputStream.<init>(Ljava.io.OutputStream;I
)V"
    ("org.tukaani.xz.XZOutputStream")
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.compressors.xz.XZCompressorOutputStream.write(I)V"
    ("org.tukaani.xz.XZOutputStream")
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.compressors.xz.XZCompressorOutputStream.write([BII)V"
    ("org.tukaani.xz.XZOutputStream")
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.compressors.xz.XZCompressorOutputStream.flush()V"
    ("org.tukaani.xz.XZOutputStream")
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.compressors.xz.XZCompressorOutputStream.finish()V"
    ("org.tukaani.xz.XZOutputStream")
warning IKVMC0111: Emitted java.lang.NoClassDefFoundError in "org.apache.commons
.compress.compressors.xz.XZCompressorOutputStream.close()V"

Я добавил weka.dll в качестве ссылки в свой проект в Visual Studio и попытался использовать некоторые классы.

Но я продолжаю получать сообщение об ошибке, например, «Тип или имя пространства имен« Экземпляр »не существует в пространстве имен« weka.core »(вам не хватает сборки или ссылки?)

Вот мой пример кода:

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using weka;
namespace ConsoleApp1
{
    class Program
    {
        static void Main(string[] args)
        {
            weka.core.Instance
        }
    }
}
Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...