OpenIMAJ Jar文件 [英] OpenIMAJ Jar Files

查看:189
本文介绍了OpenIMAJ Jar文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是openIMAJ的新手,我想用它来处理一些图片。有很多教程可用,但他们都告诉使用Maven。有谁知道我可以从哪里下载openIMAJ的jar文件直接在我的Java项目中使用?
谢谢!

I am new to openIMAJ and I want to process some pictures using it. There are a lot of tutorial available but they all tell using Maven. Does anyone know from where I can download the jar files of openIMAJ to directly use in my Java project? Thanks!

推荐答案

OpenIMAJ相当复杂,包含许多您可能不需要使用的模块在你的项目中(即如果你做了什么做图像处理,你可能不太关心音频分析或网页的内容分析)。此外,每个OpenIMAJ模块都依赖于许多其他项目(它们本身具有依赖项,依此类推)。由于这些原因,提供所有模块及其依赖项的直接下载实际上并不是那么实际,因为用户需要花费大量精力来确定需要哪些位以及哪些位不是。

OpenIMAJ is rather complex and contains a lot of modules that you probably don't need to use in your project (i.e. if your making something to do image processing, you probably don't care to much about audio analysis, or content analysis of web-pages). In addition each of the OpenIMAJ modules has dependencies on numerous other projects (which themselves have dependencies, and so on). For these reasons, it isn't really all that practical to provide direct downloads of all the modules and their dependencies as it would take an incredible effort for the user to try and figure out which bits are needed and which bits are not.

指定所需的OpenIMAJ位的理想方法是使用自动依赖管理系统;然而,这不需要是Maven - 任何Maven兼容的依赖管理器都可以工作(即Ivy,SBT,Grape等......)。您需要在 OpenIMAJ首页上的框中添加构建系统配置中需要的代码段示例。正确(您可能需要向下滚动一下)。

The ideal way to specify which bits of OpenIMAJ you need is to use an automatic dependency management system; this does not need to be Maven however - any Maven compatible dependency manager will work (i.e. Ivy, SBT, Grape, etc...). There are examples of the snippets you need to add to your build system configuration for these on the OpenIMAJ front page in the box on the right (you might need to scroll down a bit).

如果您确实想在现有项目中手动包含相关的jar文件,我建议您使用以下内容方法,它使用Maven根据您需要的确切OpenIMAJ模块构建一组自定义的jar:

If you really do want to manually include the relevant jar files in your existing project, I'd recommend the following approach, which uses Maven to build a customised set of jars based on the exact OpenIMAJ modules you need:


  1. 运行 mvn -DarchetypeRepository = http://maven.openimaj.org -DarchetypeArtifactId = openimaj-quickstart-archetype -DarchetypeGroupId = org.openimaj -DarchetypeVersion = 1.2.1 -DartifactId = oi-deps -DgroupId = oi-deps -Dversion = 1.0- SNAPSHOT -DinteractiveMode = false archetype:generate 创建一个基本的OpenIMAJ项目(在这种情况下称为 oi-deps )。

  2. 转到 oi-deps 目录: cd oi-deps

  3. 编辑 pom.xml 文件通过删除任何不必要的< dependency> 部分,仅包含您需要的OpenIMAJ位。

  4. 运行 mvn依赖:copy-dependencies 。这将创建一个目标/依赖项文件夹,其中包含您需要添加到项目中的所有jar。

  1. Run mvn -DarchetypeRepository=http://maven.openimaj.org -DarchetypeArtifactId=openimaj-quickstart-archetype -DarchetypeGroupId=org.openimaj -DarchetypeVersion=1.2.1 -DartifactId=oi-deps -DgroupId=oi-deps -Dversion=1.0-SNAPSHOT -DinteractiveMode=false archetype:generate to create a basic OpenIMAJ project (called oi-deps in this case).
  2. Go to the oi-deps directory: cd oi-deps
  3. Edit the pom.xml file to include only the bits of OpenIMAJ you need by removing any unnecessary <dependency> sections.
  4. Run mvn dependency:copy-dependencies. This will create a target/dependencies folder that contains all the jars you need to add to your project.

这篇关于OpenIMAJ Jar文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆