Index: graphics/Makefile =================================================================== --- graphics/Makefile +++ graphics/Makefile @@ -78,6 +78,7 @@ SUBDIR += burplex SUBDIR += c-a-i-r SUBDIR += cadubi + SUBDIR += caffe SUBDIR += cairo SUBDIR += cairo-reference SUBDIR += cairomm @@ -883,6 +884,7 @@ SUBDIR += py-qt5-svg SUBDIR += py-rabbyt SUBDIR += py-sane + SUBDIR += py-scikit-image SUBDIR += py-seqdiag SUBDIR += py-sorl-thumbnail SUBDIR += py-soya3d Index: graphics/caffe/Makefile =================================================================== --- /dev/null +++ graphics/caffe/Makefile @@ -0,0 +1,74 @@ +# $FreeBSD: head/graphics/caffe/Makefile$ + +PORTNAME= caffe +PORTVERSION= 1.0.0.r5 +CATEGORIES= graphics + +MAINTAINER= eric@camachat.org +COMMENT= Fast open framework for deep learning + +LICENSE= BSD2CLAUSE +LICENSE_FILE= ${WRKSRC}/LICENSE + +BUILD_DEPENDS= ${PYNUMPY} \ + ${LOCALBASE}/bin/cython:lang/cython \ + ${LOCALBASE}/include/cblas.h:math/cblas \ + bash:shells/bash +LIB_DEPENDS= libsnappy.so:archivers/snappy \ + libleveldb.so:databases/leveldb \ + liblmdb.so:databases/lmdb \ + libboost_system.so:devel/boost-libs \ + libboost_python.so:devel/boost-python-libs \ + libgflags.so:devel/gflags \ + libglog.so:devel/glog \ + libprotobuf.so:devel/protobuf \ + libopencv_highgui.so:graphics/opencv2 \ + libopencv_core.so:graphics/opencv2-core \ + libopenblas.so:math/openblas \ + libhdf5.so:science/hdf5 +RUN_DEPENDS= ${PYNUMPY} \ + ${PYTHON_PKGNAMEPREFIX}protobuf>=2.5.0:devel/py-protobuf \ + ${PYTHON_PKGNAMEPREFIX}scikit-image>=0.12:graphics/py-scikit-image \ + ${PYTHON_PKGNAMEPREFIX}pillow>=1.7:graphics/py-pillow \ + ${PYTHON_PKGNAMEPREFIX}networkx>=1.8:math/py-networkx \ + ${PYTHON_PKGNAMEPREFIX}matplotlib>=1.1:math/py-matplotlib \ + ${PYTHON_PKGNAMEPREFIX}PyWavelets>=0.4:math/py-PyWavelets + +USE_LDCONFIG= yes +USES= gmake python fortran compiler:c++11-lib pkgconfig + +CXXFLAGS+= -DGTEST_USE_OWN_TR1_TUPLE=1 +LDFLAGS+= -DGTEST_USE_OWN_TR1_TUPLE=1 +LDFLAGS+= -lboost_thread +MAKE_ARGS+= DISTRIBUTE_DIR=${STAGEDIR}${PREFIX} +ALL_TARGET= all py +INSTALL_TARGET= dist +TEST_TARGET= runtest +PLIST_SUB= PYTHON_SITELIBDIR=${PYTHON_SITELIBDIR} DATADIR=${DATADIR} + +GH_ACCOUNT= BVLC +USE_GITHUB= yes +GH_TAGNAME= rc5 + +post-extract: + @${CP} -v ${.CURDIR}/files/Makefile.config ${WRKSRC}/ + +post-patch: + @${REINPLACE_CMD} \ + -e "s|%%CXX%%|clang++|g" \ + -e "s|%%LOCALBASE%%|${LOCALBASE}|g" \ + -e "s|%%DATADIR%%|${DATADIR}|g" \ + -e "s|%%PYTHON_INCLUDEDIR%%|${PYTHON_INCLUDEDIR}|g" \ + -e "s|%%PYTHON_SITELIBDIR%%|${PYTHON_SITELIBDIR}|g" \ + -e "s|%%STAGEDIR%%|${STAGEDIR}|g" \ + ${WRKSRC}/Makefile.config ${WRKSRC}/Makefile + +pre-install: + @${MKDIR} ${STAGEDIR}${DATADIR} + @${MKDIR} ${STAGEDIR}${PYTHON_SITELIBDIR} + +post-install: + @${STRIP_CMD} ${STAGEDIR}/${PREFIX}/bin/* ${STAGEDIR}/${PREFIX}/lib/*.so.* \ + ${STAGEDIR}/${PYTHON_SITELIBDIR}/${PORTNAME}/*.so + +.include Index: graphics/caffe/distinfo =================================================================== --- /dev/null +++ graphics/caffe/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1489879004 +SHA256 (BVLC-caffe-1.0.0.r5-rc5_GH0.tar.gz) = 06592aa8f5254335df3e244dafacc15765e2c60479b4bf2e7c887e8e023802fb +SIZE (BVLC-caffe-1.0.0.r5-rc5_GH0.tar.gz) = 8505332 Index: graphics/caffe/files/Makefile.config =================================================================== --- /dev/null +++ graphics/caffe/files/Makefile.config @@ -0,0 +1,9 @@ +# %%PYTHON_LIBDIR%% +CUSTOM_CXX := %%CXX%% +CPU_ONLY := 1 +BLAS := open +PYTHON_INCLUDE := %%PYTHON_INCLUDEDIR%% %%PYTHON_SITELIBDIR%%/numpy/core/include +PYTHON_LIB := %%LOCALBASE%%/lib +INCLUDE_DIRS := $(PYTHON_INCLUDE) %%LOCALBASE%%/include +LIBRARY_DIRS := $(PYTHON_LIB) %%LOCALBASE%%/lib /usr/lib +USE_PKG_CONFIG := 1 Index: graphics/caffe/files/patch-Makefile =================================================================== --- /dev/null +++ graphics/caffe/files/patch-Makefile @@ -0,0 +1,38 @@ +--- Makefile.orig 2017-02-21 04:06:19 UTC ++++ Makefile +@@ -316,10 +316,10 @@ endif + + # Debugging + ifeq ($(DEBUG), 1) +- COMMON_FLAGS += -DDEBUG -g -O0 ++ COMMON_FLAGS += -DDEBUG -g + NVCCFLAGS += -G + else +- COMMON_FLAGS += -DNDEBUG -O2 ++ COMMON_FLAGS += -DNDEBUG + endif + + # cuDNN acceleration configuration. +@@ -681,19 +681,18 @@ $(DIST_ALIASES): $(DISTRIBUTE_DIR) + + $(DISTRIBUTE_DIR): all py | $(DISTRIBUTE_SUBDIRS) + # add proto +- cp -r src/caffe/proto $(DISTRIBUTE_DIR)/ ++ cp -r src/caffe/proto %%STAGEDIR%%%%DATADIR%%/ + # add include + cp -r include $(DISTRIBUTE_DIR)/ + mkdir -p $(DISTRIBUTE_DIR)/include/caffe/proto + cp $(PROTO_GEN_HEADER_SRCS) $(DISTRIBUTE_DIR)/include/caffe/proto + # add tool and example binaries +- cp $(TOOL_BINS) $(DISTRIBUTE_DIR)/bin +- cp $(EXAMPLE_BINS) $(DISTRIBUTE_DIR)/bin ++ for f in $(TOOL_BINS) $(EXAMPLE_BINS); do cp -v "$$f" "$(DISTRIBUTE_DIR)/bin/`basename -s.bin $$f`"; done + # add libraries + cp $(STATIC_NAME) $(DISTRIBUTE_DIR)/lib + install -m 644 $(DYNAMIC_NAME) $(DISTRIBUTE_DIR)/lib + cd $(DISTRIBUTE_DIR)/lib; rm -f $(DYNAMIC_NAME_SHORT); ln -s $(DYNAMIC_VERSIONED_NAME_SHORT) $(DYNAMIC_NAME_SHORT) + # add python - it's not the standard way, indeed... +- cp -r python $(DISTRIBUTE_DIR)/python ++ cp -r python/caffe %%STAGEDIR%%%%PYTHON_SITELIBDIR%%/ + + -include $(DEPS) Index: graphics/caffe/pkg-descr =================================================================== --- /dev/null +++ graphics/caffe/pkg-descr @@ -0,0 +1,6 @@ +Caffe is a deep learning framework made with expression, speed, and modularity +in mind. It is developed by the Berkeley Vision and Learning Center (BVLC) and +by community contributors. Yangqing Jia created the project during his PhD at +UC Berkeley. Caffe is released under the BSD 2-Clause license. + +WWW: http://caffe.berkeleyvision.org/ Index: graphics/caffe/pkg-plist =================================================================== --- /dev/null +++ graphics/caffe/pkg-plist @@ -0,0 +1,150 @@ +bin/device_query +bin/convert_mnist_siamese_data +bin/caffe +bin/convert_cifar_data +bin/net_speed_benchmark +bin/test_net +bin/convert_imageset +bin/train_net +bin/upgrade_net_proto_text +bin/upgrade_solver_proto_text +bin/finetune_net +bin/classification +bin/compute_image_mean +bin/convert_mnist_data +bin/upgrade_net_proto_binary +bin/extract_features +lib/libcaffe.a +lib/libcaffe.so.1.0.0-rc5 +lib/libcaffe.so +include/caffe/blob.hpp +include/caffe/layer.hpp +include/caffe/util/rng.hpp +include/caffe/util/blocking_queue.hpp +include/caffe/util/hdf5.hpp +include/caffe/util/cudnn.hpp +include/caffe/util/io.hpp +include/caffe/util/upgrade_proto.hpp +include/caffe/util/benchmark.hpp +include/caffe/util/nccl.hpp +include/caffe/util/signal_handler.h +include/caffe/util/gpu_util.cuh +include/caffe/util/format.hpp +include/caffe/util/mkl_alternate.hpp +include/caffe/util/db_leveldb.hpp +include/caffe/util/math_functions.hpp +include/caffe/util/insert_splits.hpp +include/caffe/util/db.hpp +include/caffe/util/db_lmdb.hpp +include/caffe/util/device_alternate.hpp +include/caffe/util/im2col.hpp +include/caffe/layers/softmax_layer.hpp +include/caffe/layers/cudnn_sigmoid_layer.hpp +include/caffe/layers/crop_layer.hpp +include/caffe/layers/cudnn_lcn_layer.hpp +include/caffe/layers/mvn_layer.hpp +include/caffe/layers/accuracy_layer.hpp +include/caffe/layers/cudnn_lrn_layer.hpp +include/caffe/layers/conv_layer.hpp +include/caffe/layers/python_layer.hpp +include/caffe/layers/dummy_data_layer.hpp +include/caffe/layers/spp_layer.hpp +include/caffe/layers/image_data_layer.hpp +include/caffe/layers/relu_layer.hpp +include/caffe/layers/inner_product_layer.hpp +include/caffe/layers/multinomial_logistic_loss_layer.hpp +include/caffe/layers/scale_layer.hpp +include/caffe/layers/exp_layer.hpp +include/caffe/layers/softmax_loss_layer.hpp +include/caffe/layers/recurrent_layer.hpp +include/caffe/layers/log_layer.hpp +include/caffe/layers/split_layer.hpp +include/caffe/layers/window_data_layer.hpp +include/caffe/layers/silence_layer.hpp +include/caffe/layers/reduction_layer.hpp +include/caffe/layers/slice_layer.hpp +include/caffe/layers/pooling_layer.hpp +include/caffe/layers/im2col_layer.hpp +include/caffe/layers/lrn_layer.hpp +include/caffe/layers/loss_layer.hpp +include/caffe/layers/data_layer.hpp +include/caffe/layers/tile_layer.hpp +include/caffe/layers/elu_layer.hpp +include/caffe/layers/parameter_layer.hpp +include/caffe/layers/cudnn_tanh_layer.hpp +include/caffe/layers/neuron_layer.hpp +include/caffe/layers/bnll_layer.hpp +include/caffe/layers/contrastive_loss_layer.hpp +include/caffe/layers/reshape_layer.hpp +include/caffe/layers/cudnn_pooling_layer.hpp +include/caffe/layers/threshold_layer.hpp +include/caffe/layers/rnn_layer.hpp +include/caffe/layers/lstm_layer.hpp +include/caffe/layers/memory_data_layer.hpp +include/caffe/layers/hinge_loss_layer.hpp +include/caffe/layers/euclidean_loss_layer.hpp +include/caffe/layers/prelu_layer.hpp +include/caffe/layers/flatten_layer.hpp +include/caffe/layers/dropout_layer.hpp +include/caffe/layers/cudnn_conv_layer.hpp +include/caffe/layers/argmax_layer.hpp +include/caffe/layers/base_data_layer.hpp +include/caffe/layers/power_layer.hpp +include/caffe/layers/cudnn_relu_layer.hpp +include/caffe/layers/deconv_layer.hpp +include/caffe/layers/concat_layer.hpp +include/caffe/layers/infogain_loss_layer.hpp +include/caffe/layers/sigmoid_cross_entropy_loss_layer.hpp +include/caffe/layers/sigmoid_layer.hpp +include/caffe/layers/filter_layer.hpp +include/caffe/layers/cudnn_softmax_layer.hpp +include/caffe/layers/absval_layer.hpp +include/caffe/layers/input_layer.hpp +include/caffe/layers/batch_norm_layer.hpp +include/caffe/layers/batch_reindex_layer.hpp +include/caffe/layers/hdf5_output_layer.hpp +include/caffe/layers/tanh_layer.hpp +include/caffe/layers/eltwise_layer.hpp +include/caffe/layers/bias_layer.hpp +include/caffe/layers/base_conv_layer.hpp +include/caffe/layers/hdf5_data_layer.hpp +include/caffe/layers/embed_layer.hpp +include/caffe/caffe.hpp +include/caffe/common.hpp +include/caffe/parallel.hpp +include/caffe/solver.hpp +include/caffe/proto/caffe.pb.h +include/caffe/net.hpp +include/caffe/sgd_solvers.hpp +include/caffe/solver_factory.hpp +include/caffe/data_transformer.hpp +include/caffe/layer_factory.hpp +include/caffe/internal_thread.hpp +include/caffe/syncedmem.hpp +include/caffe/filler.hpp +include/caffe/test/test_gradient_check_util.hpp +include/caffe/test/test_caffe_main.hpp +%%PYTHON_SITELIBDIR%%/caffe/_caffe.so +%%PYTHON_SITELIBDIR%%/caffe/coord_map.py +%%PYTHON_SITELIBDIR%%/caffe/io.py +%%PYTHON_SITELIBDIR%%/caffe/proto/__init__.py +%%PYTHON_SITELIBDIR%%/caffe/proto/caffe_pb2.py +%%PYTHON_SITELIBDIR%%/caffe/detector.py +%%PYTHON_SITELIBDIR%%/caffe/pycaffe.py +%%PYTHON_SITELIBDIR%%/caffe/draw.py +%%PYTHON_SITELIBDIR%%/caffe/test/test_solver.py +%%PYTHON_SITELIBDIR%%/caffe/test/test_net.py +%%PYTHON_SITELIBDIR%%/caffe/test/test_python_layer_with_param_str.py +%%PYTHON_SITELIBDIR%%/caffe/test/test_net_spec.py +%%PYTHON_SITELIBDIR%%/caffe/test/test_io.py +%%PYTHON_SITELIBDIR%%/caffe/test/test_python_layer.py +%%PYTHON_SITELIBDIR%%/caffe/test/test_layer_type_list.py +%%PYTHON_SITELIBDIR%%/caffe/test/test_coord_map.py +%%PYTHON_SITELIBDIR%%/caffe/net_spec.py +%%PYTHON_SITELIBDIR%%/caffe/classifier.py +%%PYTHON_SITELIBDIR%%/caffe/__init__.py +%%PYTHON_SITELIBDIR%%/caffe/imagenet/ilsvrc_2012_mean.npy +%%PYTHON_SITELIBDIR%%/caffe/_caffe.cpp +%%DATADIR%%/proto/caffe.proto +@dir %%DATADIR%%/proto +@dir %%DATADIR%% Index: graphics/py-scikit-image/Makefile =================================================================== --- /dev/null +++ graphics/py-scikit-image/Makefile @@ -0,0 +1,46 @@ +# $FreeBSD$ + +PORTNAME= scikit-image +PORTVERSION= 0.12.3 +DISTVERSIONPREFIX= v +CATEGORIES= graphics python +PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} + +MAINTAINER= eric@camachat.org +COMMENT= Image Processing SciKit (Toolbox for SciPy) + +LICENSE= BSD3CLAUSE +LICENSE_FILE= ${WRKSRC}/LICENSE.txt + +BUILD_DEPENDS= ${PYNUMPY} \ + ${LOCALBASE}/bin/cython:lang/cython \ + ${PYTHON_PKGNAMEPREFIX}six>=1.4:devel/py-six \ + ${PYTHON_PKGNAMEPREFIX}scipy>=0.9:science/py-scipy \ + ${PYTHON_PKGNAMEPREFIX}numpydoc>=0.6:textproc/py-numpydoc +RUN_DEPENDS= ${PYNUMPY} \ + ${LOCALBASE}/bin/cython:lang/cython \ + ${PYTHON_PKGNAMEPREFIX}six>=1.4:devel/py-six \ + ${PYTHON_PKGNAMEPREFIX}scipy>=0.9:science/py-scipy \ + ${PYTHON_PKGNAMEPREFIX}numpydoc>=0.6:textproc/py-numpydoc \ + ${PYTHON_PKGNAMEPREFIX}pillow>=1.7:graphics/py-pillow \ + ${PYTHON_PKGNAMEPREFIX}networkx>=1.8:math/py-networkx \ + ${PYTHON_PKGNAMEPREFIX}matplotlib>=1.1:math/py-matplotlib \ + ${PYTHON_PKGNAMEPREFIX}PyWavelets>=0.4:math/py-PyWavelets + +USES= cpe python +USE_GITHUB= yes +USE_PYTHON= autoplist distutils + +PYDISTUTILS_BUILD_TARGET= build build_ext +PYDISTUTILS_BUILDARGS+= saveopts + +post-install: + @${FIND} ${STAGEDIR}${PYTHON_SITELIBDIR}/skimage -name "*.so" -exec ${STRIP_CMD} {} \; + +do-test: + @cd ${WRKSRC} && \ + ${PYTHON_CMD} ${PYSETUP} build_ext -i && \ + ${PYTHON_CMD} selftest.py && \ + ${PYTHON_CMD} -m nose -vx Tests/test_*.py + +.include Index: graphics/py-scikit-image/distinfo =================================================================== --- /dev/null +++ graphics/py-scikit-image/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1489879947 +SHA256 (scikit-image-scikit-image-v0.12.3_GH0.tar.gz) = 4356124bc4c258ddcb84ffbf3b8cec7034d20cb8da267ff881aae0668a2e0caa +SIZE (scikit-image-scikit-image-v0.12.3_GH0.tar.gz) = 16763030 Index: graphics/py-scikit-image/pkg-descr =================================================================== --- /dev/null +++ graphics/py-scikit-image/pkg-descr @@ -0,0 +1,4 @@ +scikit-image is a collection of algorithms for image processing. It is +available free of charge and free of restriction. We pride ourselves on +high-quality, peer-reviewed code, written by an active community of +volunteers.