Image process framework based on plugin like imagej, it is esay to glue with scipy.ndimage, scikit-image, opencv, simpleitk, mayavi...and any libraries based on numpy

Overview

Introduction

ImagePy is an open source image processing framework written in Python. Its UI interface, image data structure and table data structure are wxpython-based, Numpy-based and pandas-based respectively. Furthermore, it supports any plug-in based on Numpy and pandas, which can talk easily between scipy.ndimage, scikit-image, simpleitk, opencv and other image processing libraries.

newdoc01

Overview, mouse measurement, geometric transformation, filtering, segmentation, counting, etc.

newdoc02

If you are more a IJ-style user, try `Windows -> Windows Style` to switch

ImagePy:

  • has a user-friendly interface
  • can read/save a variety of image data formats
  • supports ROI settings, drawing, measurement and other mouse operations
  • can perform image filtering, morphological operations and other routine operations
  • can do image segmentation, area counting, geometric measurement and density analysis.
  • is able to perform data analysis, filtering, statistical analysis and others related to the parameters extracted from the image.

Our long-term goal of this project is to be used as ImageJ + SPSS (although not achieved yet)

Installation

OS support:windows, linux, mac, with python3.x

  1. ImagePy is a ui framework based on wxpython, which can not be installed with pip on Linux. You need download the whl according to your Linux system.
  2. On Linux and Mac, there may be permission denied promblem, for ImagePy will write some config information, so please start with sudo. If you install with pip, please add --user parameter like this: pip install --user imagepy
  3. If you install ImagePy in an Anaconda virtual environment, you may get a error when starting like this: This program needs access to the screen. Please run with a Framework build of python, and only when you are logged in on the main display, if so, please start with pythonw -m imagepy.

- Pre-compiled package

This is the simplest option to run ImagePy.
A precompiled archive can be downloaded from the release tab of the repository.
Simply unzip the archive and run the ImagePy.bat file.
This will open a command line window and open the GUI of ImagePy.

- Using pip

In a command-prompt type pip install imagepy. On Windows you currently need to first install shapely using conda. This should also work for windows, now that shapely is available via pip. Once installed, ImagePy can be run by typing python -m imagepy in a command prompt.

Citation:

ImagePy: an open-source, Python-based and platform-independent software package for bioimage analysis

Forum

ImagePy is a community partner of forum.image.sc, Anything about the usage and development of ImagePy could be discussed in https://forum.image.sc.

Contribute

Contribute Manual: All markdown file under doc folder be parsed as manual. Plugins and manual are paired by plugins's title and manual's file name. We can browse document from the parameter dialog's Help button. We need more manual contributors, just pull request markdown file here.

Contribute Plugins: Here is a demo plugin repositories with document to show how to write plugins and publish on ImagePy. You are wellcom and feel free to contact with us if you need help.

Improve Main Framework: Just fork ImagePy, then give Pull Request. But if you want to add some new feature, Please have a issue with us firstly.

Basic operations:

ImagePy has a very rich set of features, and here, we use a specific example to show you a glimpse of the capacity of ImagePy. We choose the official coin split of scikit-image, since this example is simple and comprehensive.

Open image

menu: File -> Local Samples -> Coins to open the sample image within ImagePy. PS: ImagePy supports bmp, jpg, png, gif, tif and other commonly used file formats. By installing ITK plug-in,dicom,nii and other medical image formats can also be read/saved. It is also possible to read/write wmv, avi and other video formats by installing OpenCV.

newdoc03

Coins

Filtering & Segmentation

menu:Process -> Hydrology -> Up And Down Watershed Here, a composite filter is selected to perform sobel gradient extraction on the image, and then the upper and lower thresholds are used as the mark, and finally we watershed on the gradient map. Filtering and segmentation are the crucial skills in the image processing toolkit, and are the key to the success or failure of the final measurement. Segmentation methods such as adaptive thresholds, watersheds and others are also supported.

newdoc04

Up And Down Watershed

newdoc05

Mask

Binarization

menu:Process -> Binary -> Binary Fill Holes After the segmentation, we obtained a relatively clean mask image, but there is still some hollowing out, as well as some impurities, which will interfere with counting and measurement. ImagePy supports binary operations such as erode, dilate, opening and closing, as well as skeletonization, central axis extraction, and distance transformation.

newdoc06

Fill Holes

Geometry filtering

menu:Analysis -> Region Analysis -> Geometry Filter ImagePy can perform geometric filtering based on :the area, the perimeter, the topology, the solidity, the eccentricity and other parameters. You can also use multiple conditions for filtering. Each number can be positive|negative, which indicates the kept object will have the corresponding parameter greater|smaller than the value respectively. The kept objects will be set to the front color, the rejected ones will be set to the back color. In this demo, the back color is set to 100 in order to see which ones are filtered out. Once satisfied with the result, set the back color to 0 to reject them. In addition, ImagePy also supports gray density filtering, color filtering, color clustering and other functions.

newdoc07

Geometry filtering (the area is over-chosen to emphasize the distinction)

Geometry Analysis

menu:Process -> Region Analysis -> Geometry Analysis Count the area and analyze the parameters. By choosing the cov option, ImagePy will fit each area with an ellipse calculated via the covariance. The parameters such as area, perimeter, eccentricity, and solidity shown in the previous step are calculated here. In fact, the filtering of the previous step is a downstream analysis of this one.

newdoc08

Geometry Analysis

newdoc09

Generate the result table (dark to emphasize the ellipse)

Sort Table by area

menu:Table -> Statistic -> Table Sort By Key Select the major key as area, and select descend. The table will be sorted in descending order of area. A table is another important piece of data other than an image. In a sense, many times we need to get the required information on the image and then post-process the data in the form of a table. ImagePy supports table I/O (xls, xlsx, csv), filtering, slicing, statistical analysis, sorting and more. (Right click on the column header to set the text color, decimal precision, line style, etc.)

newdoc10

Table

Charts

menu:Table -> Chart -> Hist Chart From tabular data, we often need to draw a graph. Here, we plot the histograms of the area and the perimeter columns. ImagePy's tables can be used to draw common charts such as line charts, pie charts, histograms, and scatter plots (matplotlib-based). The chart comes with zooming, moving and other functions. The table can also be saved as an image.

newdoc11

Histograms

3D chart

menu:Kit3D -> Viewer 3D -> 2D Surface Surface reconstruction of the image. This image shows the three reconstructed results including, sobel gradient map, high threshold and low threshold. It shows how the Up And Down Watershed works:

  • calculate the gradient.
  • mark the coin and background through the high and low thresholds,
  • simulate the rising water on the dem diagram to form the segmentation.

ImagePy can perform 3D filtering of images, 3D skeletons, 3D topological analysis, 2D surface reconstruction, and 3D surface visualization. The 3D view can be freely dragged, rotated, and the image results can be saved as a .stl file.

newdoc12

3D visualisation

Macro recording and execution

menu:Window -> Develop Tool Suite Macro recorder is shown in the develop tool panel. We have manually completed an image segmentation. However, batch processing more than 10 images can be tedious. So, assuming that these steps are highly repeatable and robust for dealing with such problems, we can record a macro to combine several processes into a one-click program. The macro recorder is similar to a radio recorder. When it is turned on, each step of the operation will be recorded. We can click the pause button to stop recording, then click the play button to execute. When the macro is running, the recorded commands will be executed sequentially, therefore achieving simplicity and reproducibility.

Macros are saved into .mc files. drag and drop the file to the status bar at the bottom of ImagePy, the macro will be executed automatically. we can also copy the .mc file to the submenu of the menus under the ImagePy file directory. When ImagePy is started, the macro file will be parsed into a menu item at the corresponding location. By clicking the menu, the macro will also be executed.

newdoc13

Macro Recording

Workflow

A macro is a sequence of predefined commands. By recording a series of fixed operations into macros, you can improve your work efficiency. However, the disadvantage is the lack of flexibility. For example, sometimes the main steps are fixed, but the parameter tuning needs human interaction. In this case, the workflow is what you want. A workflow in ImagePy is a flow chart that can be visualized, divided into two levels: chapters and sections. The chapter corresponds to a rectangular area in the flow chart, and the section is a button in the rectangular area, which is also a command and is accompanied by a graphic explanation. The message window on the right will display the corresponding function description, while mousing hovering above. Click on the Detail Document in the top right corner to see the documentation of the entire process.

The workflow is actually written in MarkDown (a markup language), but it needs to be written respecting several specifications, as follows:

Title
=====
## Chapter1
1. Section1
some coment for section1 ...
2. ...
## Chapter 2
	...

newdoc14

Workflow

Report Plugin

Sometimes we need to make a report to print or generate a PDF document. ImagePy can generate report from a xlsx template. We just need put specific mark in some cells, ImagePy will parse the template and generate a parameter dialog, then we can input some information, or give image/table in, the report will be generated! more about how to make template please see here.

newdoc14

generate report

Filter Plugin

We introduced macros and workflows in the last sections, using macros and workflows to connect existing functions is convenient. But sometimes we need to create new features. In this section, we are trying to add a new feature to ImagePy. ImagePy can easily access any Numpy-based function. Let's take the Canny operator of scikit-image as an example.

from skimage import feature
from imagepy.core.engine import Filter

class Plugin(Filter):
    title = 'Canny'
    note = ['all', 'auto_msk', 'auto_snap', 'preview']
    para = {'sigma':1.0, 'low_threshold':10, 'high_threshold':20}

    view = [(float, 'sigma', (0,10), 1, 'sigma', 'pix'),
            ('slide', 'low_threshold', (0,50), 4, 'low_threshold'),
            ('slide', 'high_threshold', (0,50), 4, 'high_threshold')]

def run(self, ips, snap, img, para = None):
    return feature.canny(snap, para['sigma'], para['low_threshold'],
        para['high_threshold'], mask=ips.get_msk())*255

newdoc15

Canny Filter Demo

Steps to create a your own filter:

  1. Import the package(s), often third party.
  2. Inherit the Filter class。
  3. The title will be used as the name of the menu and the title of the parameter dialog, also as a command for macro recording.
  4. Tell the framework what needs to do for you in Note, whether to do type checking, to support the selection, to support UNDO, etc.
  5. Para is the a dictionary of parameters, including needed parameters for the functions.
  6. Define the interaction method for each of the parameters in View, the framework will automatically generate the dialog for parameter tuning by reading these information.
  7. Write the core function run. img is the current image, para is the result entre by user. if auto_snap is set in note, snap will be a duplicate of img. We can process the snap, store the result in img. If the function does not support the specified output, we can also return the result, and the framework will help us copy the result to img and display it.
  8. Save the file as xxx_plg.py and copy to the menu folder, restart ImagePy. It will be loaded as a menu item.

What did the framework do for us?

The framework unifies the complex tasks in a formal manner and helps us to perform:

  • type checking. If the current image type does not meet the requirements in the note, the analysis is terminated.
  • according to the para, generate automatically a dialog box to detect the input legality from the view.
  • Real-time preview
  • automatic ROI support
  • undo support
  • parallelization support
  • image stack support
  • etc.

Table

As mentioned earlier, the table is another very important data type other than the image. Similarly, ImagePy also supports the extension of table. Here we give an example of sorting-by-key used in the previous description.

from imagepy.core.engine import Table
import pandas as pd

class Plugin(Table):
    title = 'Table Sort By Key'
    para = {'major':None, 'minor':None, 'descend':False}

    view = [('field', 'major', 'major', 'key'),
    	    ('field', 'minor', 'minor', 'key'),
    	    (bool, 'descend', 'descend')]

def run(self, tps, data, snap, para=None):
    by = [para['major'], para['minor']]
    data.sort_values(by=[i for i in by if i != 'None'],
        axis=0, ascending = not para['descend'], inplace=True)

newdoc16

Table Sort Demo

How Table works

Same as FilterTable also has parameters such as titlenoteparaview. When the plugin is running, the framework will generate a dialog box according to para and view. After the parameters are chosen, they are passed to the run together with the current table and be processed. The table data is a pandas.DataFrame object in the current table, stored in tps. Other information, such as tps.rowmsk, tps.colmsk can also be retrieved from tps to get the row and column mask of the current selected table.

Other type of plugins

The Filter and Table described above are the two most important plugins, but ImagePy also supports some other types of plugin extensions. There are currently ten, they are:

  1. Filter: mainly for image processing
  2. Simple: similar to Filter, but focus on the overall characteristics of the image, such as the operation of the ROI, the operation of the false color, the area measurement, or the three-dimensional analysis of the entire image stack, visualization, and so on.
  3. Free: operate that are independant of image. Used to open image, close software etc.
  4. Tool: use the mouse to interact on the diagram and show small icons on the toolbar, such as a brush.
  5. Table: operate on the table, such as statistics analysis, sorting, plotting.
  6. Widget: widgets that are displayed in panels, such as the navigation bar on the right, the macro recorder, and others.
  7. Markdown: markup language, when clicked, a separate window will pop up to display the document.
  8. Macros:command sequence file for serially fixed operational procedures.
  9. Workflow: combination of macro and MarkDown to create an interactive guidance process.
  10. Report: a xlsx template with specific mark, rename as .rpt, used to auto generate report.

Motivation & Goal

Python is a simple, elegant, powerful language, and has very rich third-party libraries for scientific computing. Based on the universal matrix structure and the corresponding rules, numpy-based libraries such as scipy, scikit-image, scikit-learn and other scientific computing libraries have brought great convenience to scientific research. On the other hand, more and more problems in biology, material science and other scientific research can be efficiently and accurately solved via scientific computing, image processing.

However there are still many researchers that lack programming skills. Thus it is a crucial to make the Numpy-based scientific computing libraries available to more researchers. ImagePy brings the computing capacities closer to the non-programmer researchers, so that they won't need to be concerned about the UI and interaction design, and focus exclusively on the algorithm itself, and finally, accelerate open-source tool building or even commercial products incubation. These tools, meanwhile, can let more researchers, who are not good at programming, gain, promote and popularize scientific knowledge such as image processing and statistics.

Comments
  • wxpython-installer in requirements

    wxpython-installer in requirements

    I try to install imagepy with pip and fail because cannot install wxpython-installer. I also do not found it on pypi. Could you update requirements in setup.py file?

    opened by Czaki 10
  • Support maths in markdown

    Support maths in markdown

    ImagePy uses Python-Markdown, which can be extended for maths support using several extensions. I myself tried this one. To enable, you need to append the exts list with 'mdx_math' in the imagepy/ui/mkdownwindow.py file. For instance, markdown("$$x^2$$", extensions=['mdx_math']) results in the HTML code '<p>\n<script type="math/tex; mode=display">x^2</script>\n</p>'. This trick alone is not enough in ImagePy, the documentation writes that some additional steps are needed. Could you implement this? It would be very useful for displaying formulas in help texts.

    opened by CsatiZoltan 8
  • SyntaxError: invalid syntax

    SyntaxError: invalid syntax

    hi, i need help, when i start imagepy by "python -m imagepy", ubuntu16.04 python2.7

    Traceback (most recent call last): File "/usr/lib/python2.7/runpy.py", line 163, in _run_module_as_main mod_name, _Error) File "/usr/lib/python2.7/runpy.py", line 111, in _get_module_details import(mod_name) # Do not catch exceptions initializing package File "/usr/local/lib/python2.7/dist-packages/imagepy/init.py", line 10, in from .ui.imagepy import ImagePy File "/usr/local/lib/python2.7/dist-packages/imagepy/ui/imagepy.py", line 9, in from .. import IPy, root_dir File "/usr/local/lib/python2.7/dist-packages/imagepy/IPy.py", line 11, in from wx.lib.pubsub import pub File "/usr/local/lib/python2.7/dist-packages/wx/lib/pubsub/init.py", line 38, in from pubsub import * File "/usr/local/lib/python2.7/dist-packages/pubsub/pub.py", line 146 def getDefaultPublisher() -> Publisher: ^ SyntaxError: invalid syntax

    opened by wuyuzaizai 8
  • What causes Simple change the color of an image?

    What causes Simple change the color of an image?

    I have an input RGB image: homogeneous_1_cropped If I apply Process -> Filter -> Median on it, I obtain the following filtered image: filtered_1 The median filter in ImagePy inherits from class Filter. However, if I want to replicate the same process using the Simple class, I get a different color: filtered_2 Why is it so? How can I keep the original color? My code is:

    class FilterImage(Simple):
        """Median filtering of the current image."""
        title = 'Filter image'
        note = ['all', 'auto_msk', 'auto_snap', 'preview']
        para = {'size': 5}
        view = [(int, 'size', (1, 30), 0, 'window size', 'pixel')]
    
        def run(self, ips, imgs, para=None):
            out = median_filter(ips.img, para['size'])
            IPy.show_img([out], ips.title + '-filtered')
    

    Additional information:

    • motivation: the only reason I subclass Simple and don't use the already available Median class is because I want to show the filtered image on a new tab, not overwriting the original one. Yes, I know, I could first duplicate the original image and perform the filtering on it, but still, I am curious why this color issue happens.
    • ImagePy still shows the third image as RGB (first I thought that the change in color is due to the an implicit conversion to an int type)
    • I realized that even if I change the above code to
      def run(self, ips, imgs, para=None):
              imgs[0] = median_filter(ips.img, para['size'])
      

      the same color change happens. It means that it is not IPy.show_img that causes the issue.

    opened by CsatiZoltan 5
  • No need to manually install shapely

    No need to manually install shapely

    Just edited the readme that was previously mentioning that shapely should have been installed manually. Not needed anymore as shapely is available via pip for windows too since recently.

    opened by LauLauThom 4
  • ValueError: insecure string pickle

    ValueError: insecure string pickle

    首先非常感谢你分享的这个优秀工具,目前我遇到了一些问题,还没有在本地运行起来

    我使用的发行版是Anaconda2 和wxPython,运行命令python main.py遇到了如下错误:

    Traceback (most recent call last):
      File "main.py", line 4, in <module>
        from ui.imagepy import ImagePy
      File "C:\apps\imagepy\ui\imagepy.py", line 8, in <module>
        import pluginloader, toolsloader, IPy
      File "C:\apps\imagepy\ui\pluginloader.py", line 3, in <module>
        from core.loader import loader
      File "C:\apps\imagepy\core\loader\loader.py", line 7, in <module>
        import IPy
      File "C:\apps\imagepy\IPy.py", line 8, in <module>
        from ui.panelconfig import ParaDialog
      File "C:\apps\imagepy\ui\panelconfig.py", line 3, in <module>
        from core.managers import WindowsManager, TableLogManager
      File "C:\apps\imagepy\core\managers.py", line 12, in <module>
        from manager.configmanager import *
      File "C:\apps\imagepy\core\manager\configmanager.py", line 34, in <module>
        ConfigManager.read()
      File "C:\apps\imagepy\core\manager\configmanager.py", line 15, in read
        cls.cfg = pickle.load(pkl_file)
      File "C:\ProgramData\Anaconda2\lib\pickle.py", line 1384, in load
        return Unpickler(file).load()
      File "C:\ProgramData\Anaconda2\lib\pickle.py", line 864, in load
        dispatch[key](self)
      File "C:\ProgramData\Anaconda2\lib\pickle.py", line 972, in load_string
        raise ValueError, "insecure string pickle"
    ValueError: insecure string pickle
    

    下面是我的环境变量: ['C:\\apps\\imagepy', 'C:\\ProgramData\\Anaconda2\\python27.zip', 'C:\\ProgramData\\Anaconda2\\DLLs', 'C:\\ProgramData\\Anaconda2\\lib', 'C:\\ProgramData\\Anaconda2\\lib\\plat-win', 'C:\\ProgramData\\Anaconda2\\lib\\lib-tk', 'C:\\ProgramData\\Anaconda2', 'C:\\ProgramData\\Anaconda2\\lib\\site-packages', 'C:\\ProgramData\\Anaconda2\\lib\\site-packages\\Sphinx-1.5.1-py2.7.egg', 'C:\\ProgramData\\Anaconda2\\lib\\site-packages\\win32', 'C:\\ProgramData\\Anaconda2\\lib\\site-packages\\win32\\lib', 'C:\\ProgramData\\Anaconda2\\lib\\site-packages\\Pythonwin', 'C:\\ProgramData\\Anaconda2\\lib\\site-packages\\setuptools-27.2.0-py2.7.egg', 'C:\\ProgramData\\Anaconda2\\lib\\site-packages\\wx-3.0-msw']

    opened by XianchaoZhang 4
  • No module named 'imagepy.core'

    No module named 'imagepy.core'

    Error occured after I install the open plugin in the Plugins manager

    File Name Error plugins\opencv-plgs\menus\Opencv\Filters laplace_plg.py No module named 'imagepy.core' plugins\opencv-plgs\menus\Opencv\Filters canny_plg.py No module named 'imagepy.core' plugins\opencv-plgs\menus\Opencv\Segmentation awatershed_plg.py No module named 'imagepy.core' plugins\opencv-plgs\menus\Opencv\Segmentation means_plg.py No module named 'imagepy.core' plugins\opencv-plgs\menus\Opencv\Segmentation shift_plg.py No module named 'imagepy.core' plugins\opencv-plgs\menus\Opencv\Threshold athreshold_plg.py cannot import name 'IPy' from 'imagepy' (F:\work\github\imagepy\imagepy_init_.py) plugins\opencv-plgs\menus\Opencv\Video IO io_plgs.py No module named 'imagepy.core'

    opened by alan0526 3
  • More lax array type check

    More lax array type check

    The Mark Boundaries command requires an integer type https://github.com/Image-Py/imagepy/blob/9710a277ad5711ca91c19c9324cb1bc18f4e2ff6/imagepy/menus/Analysis/label_plg.py#L34 This is however not required because the find_boundaries function of scikit-image accepts bool type too. Boolean types could be implemented in the note list as 'bool'.


    In some cases, one could accept an RGB image and implicitly convert it to e.g. uint8 when necessary. The Filter plugin already supports auto-conversion, as described in the documentation, in the form of '2int' and '2float'. What about implementing 'rgb2uint32, rgb2uint64, etc.?

    opened by CsatiZoltan 3
  • install with Building wheel for pystackreg (setup.py) ... error

    install with Building wheel for pystackreg (setup.py) ... error

    Dear Sir

    我的系统:MacOS 安装方式 pip3 install imagepy

    期望您有空可以帮我看一下 谢谢 !

    Building wheel for pystackreg (setup.py) ... error
      ERROR: Complete output from command /usr/local/bin/python3.7 -u -c 'import setuptools, tokenize;__file__='"'"'/private/var/folders/49/lx4dfjcs6dn11kb8cmsw5n600000gn/T/pip-install-4mqurchj/pystackreg/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /private/var/folders/49/lx4dfjcs6dn11kb8cmsw5n600000gn/T/pip-wheel-d9otnkec --python-tag cp37:
      ERROR: running bdist_wheel
      running build
      running build_py
      creating build
      creating build/lib.macosx-10.6-intel-3.7
      creating build/lib.macosx-10.6-intel-3.7/pystackreg
      copying pystackreg/version.py -> build/lib.macosx-10.6-intel-3.7/pystackreg
      copying pystackreg/__init__.py -> build/lib.macosx-10.6-intel-3.7/pystackreg
      copying pystackreg/pystackreg.py -> build/lib.macosx-10.6-intel-3.7/pystackreg
      running build_ext
      building 'pystackreg.turboreg' extension
      Warning: Can't read registry to find the necessary compiler setting
      Make sure that Python modules winreg, win32api or win32con are installed.
      C compiler: gcc -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -arch i386 -arch x86_64 -g
      
      creating build/temp.macosx-10.6-intel-3.7
      creating build/temp.macosx-10.6-intel-3.7/src
      compile options: '-Iinc/ -I/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include -I/Library/Frameworks/Python.framework/Versions/3.7/include/python3.7m -c'
      extra options: '-std=c++11'
      gcc: src/pymain.cpp
      gcc: src/TurboReg.cpp
      gcc: src/TurboRegMask.cppgcc: src/TurboRegImage.cpp
      
      In file included from src/pymain.cpp:11:
      In file included from /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include/numpy/arrayobject.h:4:
      In file included from /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include/numpy/ndarrayobject.h:12:
      In file included from /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include/numpy/ndarraytypes.h:1822:
      /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:17:2: warning: "Using deprecated NumPy API, disable it with "          "#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-W#warnings]
      #warning "Using deprecated NumPy API, disable it with " \
       ^
      src/pymain.cpp:207:29: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'npy_intp' (aka 'long') in initializer list [-Wc++11-narrowing]
          npy_intp dims_mat[2] = {rm.mat.nrows(), rm.mat.ncols()};
                                  ^~~~~~~~~~~~~~
      src/pymain.cpp:207:29: note: insert an explicit cast to silence this issue
          npy_intp dims_mat[2] = {rm.mat.nrows(), rm.mat.ncols()};
                                  ^~~~~~~~~~~~~~
                                  static_cast<npy_intp>( )
      src/pymain.cpp:207:45: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'npy_intp' (aka 'long') in initializer list [-Wc++11-narrowing]
          npy_intp dims_mat[2] = {rm.mat.nrows(), rm.mat.ncols()};
                                                  ^~~~~~~~~~~~~~
      src/pymain.cpp:207:45: note: insert an explicit cast to silence this issue
          npy_intp dims_mat[2] = {rm.mat.nrows(), rm.mat.ncols()};
                                                  ^~~~~~~~~~~~~~
                                                  static_cast<npy_intp>( )
      src/pymain.cpp:208:29: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'npy_intp' (aka 'long') in initializer list [-Wc++11-narrowing]
          npy_intp dims_pts[2] = {rm.refPts.nrows(), rm.refPts.ncols()};
                                  ^~~~~~~~~~~~~~~~~
      src/pymain.cpp:208:29: note: insert an explicit cast to silence this issue
          npy_intp dims_pts[2] = {rm.refPts.nrows(), rm.refPts.ncols()};
                                  ^~~~~~~~~~~~~~~~~
                                  static_cast<npy_intp>( )
      src/pymain.cpp:208:48: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'npy_intp' (aka 'long') in initializer list [-Wc++11-narrowing]
          npy_intp dims_pts[2] = {rm.refPts.nrows(), rm.refPts.ncols()};
                                                     ^~~~~~~~~~~~~~~~~
      src/pymain.cpp:208:48: note: insert an explicit cast to silence this issue
          npy_intp dims_pts[2] = {rm.refPts.nrows(), rm.refPts.ncols()};
                                                     ^~~~~~~~~~~~~~~~~
                                                     static_cast<npy_intp>( )
      1 warning and 4 errors generated.
      gcc: src/TurboRegTransform.cpp
      src/TurboRegTransform.cpp:45:9: warning: unknown pragma ignored [-Wunknown-pragmas]
      #pragma warning(disable:4996)
              ^
      gcc: src/TurboRegPointHandler.cpp
      1 warning generated.
      src/TurboRegTransform.cpp:45:9: warning: unknown pragma ignored [-Wunknown-pragmas]
      #pragma warning(disable:4996)
              ^
      1 warning generated.
      error: Command "gcc -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -arch i386 -arch x86_64 -g -Iinc/ -I/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include -I/Library/Frameworks/Python.framework/Versions/3.7/include/python3.7m -c src/pymain.cpp -o build/temp.macosx-10.6-intel-3.7/src/pymain.o -std=c++11" failed with exit status 1
      ----------------------------------------
      ERROR: Failed building wheel for pystackreg
      Running setup.py clean for pystackreg
    Failed to build pystackreg
    Installing collected packages: pystackreg, et-xmlfile, jdcal, openpyxl, xlwt, xlrd, llvmlite, numba, imagepy
      Running setup.py install for pystackreg ... error
        ERROR: Complete output from command /usr/local/bin/python3.7 -u -c 'import setuptools, tokenize;__file__='"'"'/private/var/folders/49/lx4dfjcs6dn11kb8cmsw5n600000gn/T/pip-install-4mqurchj/pystackreg/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /private/var/folders/49/lx4dfjcs6dn11kb8cmsw5n600000gn/T/pip-record-l5_w4xrs/install-record.txt --single-version-externally-managed --compile:
        ERROR: running install
        running build
        running build_py
        creating build
        creating build/lib.macosx-10.6-intel-3.7
        creating build/lib.macosx-10.6-intel-3.7/pystackreg
        copying pystackreg/version.py -> build/lib.macosx-10.6-intel-3.7/pystackreg
        copying pystackreg/__init__.py -> build/lib.macosx-10.6-intel-3.7/pystackreg
        copying pystackreg/pystackreg.py -> build/lib.macosx-10.6-intel-3.7/pystackreg
        running build_ext
        building 'pystackreg.turboreg' extension
        Warning: Can't read registry to find the necessary compiler setting
        Make sure that Python modules winreg, win32api or win32con are installed.
        C compiler: gcc -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -arch i386 -arch x86_64 -g
        
        creating build/temp.macosx-10.6-intel-3.7
        creating build/temp.macosx-10.6-intel-3.7/src
        compile options: '-Iinc/ -I/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include -I/Library/Frameworks/Python.framework/Versions/3.7/include/python3.7m -c'
        extra options: '-std=c++11'
        gcc: src/TurboReg.cpp
        gcc: src/pymain.cpp
        gcc: src/TurboRegMask.cpp
        gcc: src/TurboRegImage.cpp
        In file included from src/pymain.cpp:11:
        In file included from /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include/numpy/arrayobject.h:4:
        In file included from /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include/numpy/ndarrayobject.h:12:
        In file included from /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include/numpy/ndarraytypes.h:1822:
        /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:17:2: warning: "Using deprecated NumPy API, disable it with "          "#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-W#warnings]
        #warning "Using deprecated NumPy API, disable it with " \
         ^
        src/pymain.cpp:207:29: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'npy_intp' (aka 'long') in initializer list [-Wc++11-narrowing]
            npy_intp dims_mat[2] = {rm.mat.nrows(), rm.mat.ncols()};
                                    ^~~~~~~~~~~~~~
        src/pymain.cpp:207:29: note: insert an explicit cast to silence this issue
            npy_intp dims_mat[2] = {rm.mat.nrows(), rm.mat.ncols()};
                                    ^~~~~~~~~~~~~~
                                    static_cast<npy_intp>( )
        src/pymain.cpp:207:45: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'npy_intp' (aka 'long') in initializer list [-Wc++11-narrowing]
            npy_intp dims_mat[2] = {rm.mat.nrows(), rm.mat.ncols()};
                                                    ^~~~~~~~~~~~~~
        src/pymain.cpp:207:45: note: insert an explicit cast to silence this issue
            npy_intp dims_mat[2] = {rm.mat.nrows(), rm.mat.ncols()};
                                                    ^~~~~~~~~~~~~~
                                                    static_cast<npy_intp>( )
        src/pymain.cpp:208:29: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'npy_intp' (aka 'long') in initializer list [-Wc++11-narrowing]
            npy_intp dims_pts[2] = {rm.refPts.nrows(), rm.refPts.ncols()};
                                    ^~~~~~~~~~~~~~~~~
        src/pymain.cpp:208:29: note: insert an explicit cast to silence this issue
            npy_intp dims_pts[2] = {rm.refPts.nrows(), rm.refPts.ncols()};
                                    ^~~~~~~~~~~~~~~~~
                                    static_cast<npy_intp>( )
        src/pymain.cpp:208:48: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'npy_intp' (aka 'long') in initializer list [-Wc++11-narrowing]
            npy_intp dims_pts[2] = {rm.refPts.nrows(), rm.refPts.ncols()};
                                                       ^~~~~~~~~~~~~~~~~
        src/pymain.cpp:208:48: note: insert an explicit cast to silence this issue
            npy_intp dims_pts[2] = {rm.refPts.nrows(), rm.refPts.ncols()};
                                                       ^~~~~~~~~~~~~~~~~
                                                       static_cast<npy_intp>( )
        1 warning and 4 errors generated.
        gcc: src/TurboRegTransform.cpp
        src/TurboRegTransform.cpp:45:9: warning: unknown pragma ignored [-Wunknown-pragmas]
        #pragma warning(disable:4996)
                ^
        gcc: src/TurboRegPointHandler.cpp
        1 warning generated.
        src/TurboRegTransform.cpp:45:9: warning: unknown pragma ignored [-Wunknown-pragmas]
        #pragma warning(disable:4996)
                ^
        1 warning generated.
        error: Command "gcc -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -arch i386 -arch x86_64 -g -Iinc/ -I/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include -I/Library/Frameworks/Python.framework/Versions/3.7/include/python3.7m -c src/pymain.cpp -o build/temp.macosx-10.6-intel-3.7/src/pymain.o -std=c++11" failed with exit status 1
        ----------------------------------------
    ERROR: Command "/usr/local/bin/python3.7 -u -c 'import setuptools, tokenize;__file__='"'"'/private/var/folders/49/lx4dfjcs6dn11kb8cmsw5n600000gn/T/pip-install-4mqurchj/pystackreg/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /private/var/folders/49/lx4dfjcs6dn11kb8cmsw5n600000gn/T/pip-record-l5_w4xrs/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/var/folders/49/lx4dfjcs6dn11kb8cmsw5n600000gn/T/pip-install-4mqurchj/pystackreg/
    WARNING: You are using pip version 19.1.1, however version 19.2.1 is available.
    You should consider upgrading via the 'pip install --upgrade pip' command.
    StephenFangdeMacBook-Pro:ImagePy stephenfang$ pip3 install imagepy
    Collecting imagepy
    Collecting pystackreg (from imagepy)
      Using cached https://files.pythonhosted.org/packages/24/60/d845d03364bcb77c4d468c705622061fb4409b773830e01845793ce40d7d/pystackreg-0.2.1.tar.gz
    Requirement already satisfied: pydicom in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from imagepy) (1.3.0)
    Requirement already satisfied: wxpython in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from imagepy) (4.0.6)
    Requirement already satisfied: pypubsub in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from imagepy) (4.0.3)
    Requirement already satisfied: pandas in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from imagepy) (0.24.2)
    Collecting openpyxl (from imagepy)
    Requirement already satisfied: scikit-image in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from imagepy) (0.15.0)
    Requirement already satisfied: numpy-stl in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from imagepy) (2.10.1)
    Requirement already satisfied: read-roi in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from imagepy) (1.5.2)
    Collecting numba (from imagepy)
      Using cached https://files.pythonhosted.org/packages/bb/0d/db1d84ec79b223dedb72d7f1823a77797494348fea4b1809d92affea720a/numba-0.45.1-cp37-cp37m-macosx_10_9_x86_64.whl
    Collecting xlrd (from imagepy)
      Using cached https://files.pythonhosted.org/packages/b0/16/63576a1a001752e34bf8ea62e367997530dc553b689356b9879339cf45a4/xlrd-1.2.0-py2.py3-none-any.whl
    Requirement already satisfied: shapely in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from imagepy) (1.6.4.post2)
    Collecting xlwt (from imagepy)
      Using cached https://files.pythonhosted.org/packages/44/48/def306413b25c3d01753603b1a222a011b8621aed27cd7f89cbc27e6b0f4/xlwt-1.3.0-py2.py3-none-any.whl
    Requirement already satisfied: markdown in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from imagepy) (3.1)
    Requirement already satisfied: numpy in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from pystackreg->imagepy) (1.16.2)
    Requirement already satisfied: tqdm in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from pystackreg->imagepy) (4.31.1)
    Requirement already satisfied: six in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from wxpython->imagepy) (1.12.0)
    Requirement already satisfied: pillow in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from wxpython->imagepy) (6.0.0)
    Requirement already satisfied: pytz>=2011k in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from pandas->imagepy) (2019.1)
    Requirement already satisfied: python-dateutil>=2.5.0 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from pandas->imagepy) (2.8.0)
    Collecting et-xmlfile (from openpyxl->imagepy)
    Collecting jdcal (from openpyxl->imagepy)
      Using cached https://files.pythonhosted.org/packages/f0/da/572cbc0bc582390480bbd7c4e93d14dc46079778ed915b505dc494b37c57/jdcal-1.4.1-py2.py3-none-any.whl
    Requirement already satisfied: imageio>=2.0.1 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from scikit-image->imagepy) (2.5.0)
    Requirement already satisfied: networkx>=2.0 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from scikit-image->imagepy) (2.3)
    Requirement already satisfied: scipy>=0.17.0 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from scikit-image->imagepy) (1.2.1)
    Requirement already satisfied: PyWavelets>=0.4.0 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from scikit-image->imagepy) (1.0.3)
    Requirement already satisfied: matplotlib!=3.0.0,>=2.0.0 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from scikit-image->imagepy) (3.0.3)
    Requirement already satisfied: python-utils>=1.6.2 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from numpy-stl->imagepy) (2.3.0)
    Collecting llvmlite>=0.29.0dev0 (from numba->imagepy)
      Using cached https://files.pythonhosted.org/packages/d7/45/9216cdbf71b94ae8eefe24cfbdf4c1b9045a58f297c6e2eab5cb8d05faf3/llvmlite-0.29.0-cp37-cp37m-macosx_10_9_x86_64.whl
    Requirement already satisfied: setuptools>=36 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from markdown->imagepy) (40.8.0)
    Requirement already satisfied: decorator>=4.3.0 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from networkx>=2.0->scikit-image->imagepy) (4.4.0)
    Requirement already satisfied: pyparsing!=2.0.4,!=2.1.2,!=2.1.6,>=2.0.1 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from matplotlib!=3.0.0,>=2.0.0->scikit-image->imagepy) (2.4.0)
    Requirement already satisfied: kiwisolver>=1.0.1 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from matplotlib!=3.0.0,>=2.0.0->scikit-image->imagepy) (1.0.1)
    Requirement already satisfied: cycler>=0.10 in /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages (from matplotlib!=3.0.0,>=2.0.0->scikit-image->imagepy) (0.10.0)
    Building wheels for collected packages: pystackreg
      Building wheel for pystackreg (setup.py) ... error
      ERROR: Complete output from command /usr/local/bin/python3.7 -u -c 'import setuptools, tokenize;__file__='"'"'/private/var/folders/49/lx4dfjcs6dn11kb8cmsw5n600000gn/T/pip-install-2w_prpxg/pystackreg/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /private/var/folders/49/lx4dfjcs6dn11kb8cmsw5n600000gn/T/pip-wheel-0ivmq7zr --python-tag cp37:
      ERROR: running bdist_wheel
      running build
      running build_py
      creating build
      creating build/lib.macosx-10.6-intel-3.7
      creating build/lib.macosx-10.6-intel-3.7/pystackreg
      copying pystackreg/version.py -> build/lib.macosx-10.6-intel-3.7/pystackreg
      copying pystackreg/__init__.py -> build/lib.macosx-10.6-intel-3.7/pystackreg
      copying pystackreg/pystackreg.py -> build/lib.macosx-10.6-intel-3.7/pystackreg
      running build_ext
      building 'pystackreg.turboreg' extension
      Warning: Can't read registry to find the necessary compiler setting
      Make sure that Python modules winreg, win32api or win32con are installed.
      C compiler: gcc -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -arch i386 -arch x86_64 -g
      
      creating build/temp.macosx-10.6-intel-3.7
      creating build/temp.macosx-10.6-intel-3.7/src
      compile options: '-Iinc/ -I/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include -I/Library/Frameworks/Python.framework/Versions/3.7/include/python3.7m -c'
      extra options: '-std=c++11'
      gcc: src/pymain.cpp
      gcc: src/TurboReg.cpp
      gcc: src/TurboRegMask.cppgcc: src/TurboRegImage.cpp
      
      In file included from src/pymain.cpp:11:
      In file included from /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include/numpy/arrayobject.h:4:
      In file included from /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include/numpy/ndarrayobject.h:12:
      In file included from /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include/numpy/ndarraytypes.h:1822:
      /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:17:2: warning: "Using deprecated NumPy API, disable it with "          "#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-W#warnings]
      #warning "Using deprecated NumPy API, disable it with " \
       ^
      src/pymain.cpp:207:29: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'npy_intp' (aka 'long') in initializer list [-Wc++11-narrowing]
          npy_intp dims_mat[2] = {rm.mat.nrows(), rm.mat.ncols()};
                                  ^~~~~~~~~~~~~~
      src/pymain.cpp:207:29: note: insert an explicit cast to silence this issue
          npy_intp dims_mat[2] = {rm.mat.nrows(), rm.mat.ncols()};
                                  ^~~~~~~~~~~~~~
                                  static_cast<npy_intp>( )
      src/pymain.cpp:207:45: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'npy_intp' (aka 'long') in initializer list [-Wc++11-narrowing]
          npy_intp dims_mat[2] = {rm.mat.nrows(), rm.mat.ncols()};
                                                  ^~~~~~~~~~~~~~
      src/pymain.cpp:207:45: note: insert an explicit cast to silence this issue
          npy_intp dims_mat[2] = {rm.mat.nrows(), rm.mat.ncols()};
                                                  ^~~~~~~~~~~~~~
                                                  static_cast<npy_intp>( )
      src/pymain.cpp:208:29: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'npy_intp' (aka 'long') in initializer list [-Wc++11-narrowing]
          npy_intp dims_pts[2] = {rm.refPts.nrows(), rm.refPts.ncols()};
                                  ^~~~~~~~~~~~~~~~~
      src/pymain.cpp:208:29: note: insert an explicit cast to silence this issue
          npy_intp dims_pts[2] = {rm.refPts.nrows(), rm.refPts.ncols()};
                                  ^~~~~~~~~~~~~~~~~
                                  static_cast<npy_intp>( )
      src/pymain.cpp:208:48: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'npy_intp' (aka 'long') in initializer list [-Wc++11-narrowing]
          npy_intp dims_pts[2] = {rm.refPts.nrows(), rm.refPts.ncols()};
                                                     ^~~~~~~~~~~~~~~~~
      src/pymain.cpp:208:48: note: insert an explicit cast to silence this issue
          npy_intp dims_pts[2] = {rm.refPts.nrows(), rm.refPts.ncols()};
                                                     ^~~~~~~~~~~~~~~~~
                                                     static_cast<npy_intp>( )
      1 warning and 4 errors generated.
      gcc: src/TurboRegTransform.cpp
      src/TurboRegTransform.cpp:45:9: warning: unknown pragma ignored [-Wunknown-pragmas]
      #pragma warning(disable:4996)
              ^
      gcc: src/TurboRegPointHandler.cpp
      1 warning generated.
      src/TurboRegTransform.cpp:45:9: warning: unknown pragma ignored [-Wunknown-pragmas]
      #pragma warning(disable:4996)
              ^
      1 warning generated.
      error: Command "gcc -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -arch i386 -arch x86_64 -g -Iinc/ -I/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include -I/Library/Frameworks/Python.framework/Versions/3.7/include/python3.7m -c src/pymain.cpp -o build/temp.macosx-10.6-intel-3.7/src/pymain.o -std=c++11" failed with exit status 1
      ----------------------------------------
      ERROR: Failed building wheel for pystackreg
      Running setup.py clean for pystackreg
    Failed to build pystackreg
    Installing collected packages: pystackreg, et-xmlfile, jdcal, openpyxl, llvmlite, numba, xlrd, xlwt, imagepy
      Running setup.py install for pystackreg ... error
        ERROR: Complete output from command /usr/local/bin/python3.7 -u -c 'import setuptools, tokenize;__file__='"'"'/private/var/folders/49/lx4dfjcs6dn11kb8cmsw5n600000gn/T/pip-install-2w_prpxg/pystackreg/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /private/var/folders/49/lx4dfjcs6dn11kb8cmsw5n600000gn/T/pip-record-_odidbgb/install-record.txt --single-version-externally-managed --compile:
        ERROR: running install
        running build
        running build_py
        creating build
        creating build/lib.macosx-10.6-intel-3.7
        creating build/lib.macosx-10.6-intel-3.7/pystackreg
        copying pystackreg/version.py -> build/lib.macosx-10.6-intel-3.7/pystackreg
        copying pystackreg/__init__.py -> build/lib.macosx-10.6-intel-3.7/pystackreg
        copying pystackreg/pystackreg.py -> build/lib.macosx-10.6-intel-3.7/pystackreg
        running build_ext
        building 'pystackreg.turboreg' extension
        Warning: Can't read registry to find the necessary compiler setting
        Make sure that Python modules winreg, win32api or win32con are installed.
        C compiler: gcc -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -arch i386 -arch x86_64 -g
        
        creating build/temp.macosx-10.6-intel-3.7
        creating build/temp.macosx-10.6-intel-3.7/src
        compile options: '-Iinc/ -I/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include -I/Library/Frameworks/Python.framework/Versions/3.7/include/python3.7m -c'
        extra options: '-std=c++11'
        gcc: src/pymain.cpp
        gcc: src/TurboReg.cpp
        gcc: src/TurboRegMask.cpp
        gcc: src/TurboRegImage.cpp
        In file included from src/pymain.cpp:11:
        In file included from /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include/numpy/arrayobject.h:4:
        In file included from /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include/numpy/ndarrayobject.h:12:
        In file included from /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include/numpy/ndarraytypes.h:1822:
        /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:17:2: warning: "Using deprecated NumPy API, disable it with "          "#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-W#warnings]
        #warning "Using deprecated NumPy API, disable it with " \
         ^
        src/pymain.cpp:207:29: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'npy_intp' (aka 'long') in initializer list [-Wc++11-narrowing]
            npy_intp dims_mat[2] = {rm.mat.nrows(), rm.mat.ncols()};
                                    ^~~~~~~~~~~~~~
        src/pymain.cpp:207:29: note: insert an explicit cast to silence this issue
            npy_intp dims_mat[2] = {rm.mat.nrows(), rm.mat.ncols()};
                                    ^~~~~~~~~~~~~~
                                    static_cast<npy_intp>( )
        src/pymain.cpp:207:45: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'npy_intp' (aka 'long') in initializer list [-Wc++11-narrowing]
            npy_intp dims_mat[2] = {rm.mat.nrows(), rm.mat.ncols()};
                                                    ^~~~~~~~~~~~~~
        src/pymain.cpp:207:45: note: insert an explicit cast to silence this issue
            npy_intp dims_mat[2] = {rm.mat.nrows(), rm.mat.ncols()};
                                                    ^~~~~~~~~~~~~~
                                                    static_cast<npy_intp>( )
        src/pymain.cpp:208:29: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'npy_intp' (aka 'long') in initializer list [-Wc++11-narrowing]
            npy_intp dims_pts[2] = {rm.refPts.nrows(), rm.refPts.ncols()};
                                    ^~~~~~~~~~~~~~~~~
        src/pymain.cpp:208:29: note: insert an explicit cast to silence this issue
            npy_intp dims_pts[2] = {rm.refPts.nrows(), rm.refPts.ncols()};
                                    ^~~~~~~~~~~~~~~~~
                                    static_cast<npy_intp>( )
        src/pymain.cpp:208:48: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'npy_intp' (aka 'long') in initializer list [-Wc++11-narrowing]
            npy_intp dims_pts[2] = {rm.refPts.nrows(), rm.refPts.ncols()};
                                                       ^~~~~~~~~~~~~~~~~
        src/pymain.cpp:208:48: note: insert an explicit cast to silence this issue
            npy_intp dims_pts[2] = {rm.refPts.nrows(), rm.refPts.ncols()};
                                                       ^~~~~~~~~~~~~~~~~
                                                       static_cast<npy_intp>( )
        1 warning and 4 errors generated.
        gcc: src/TurboRegTransform.cpp
        src/TurboRegTransform.cpp:45:9: warning: unknown pragma ignored [-Wunknown-pragmas]
        #pragma warning(disable:4996)
                ^
        gcc: src/TurboRegPointHandler.cpp
        1 warning generated.
        src/TurboRegTransform.cpp:45:9: warning: unknown pragma ignored [-Wunknown-pragmas]
        #pragma warning(disable:4996)
                ^
        1 warning generated.
        error: Command "gcc -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -arch i386 -arch x86_64 -g -Iinc/ -I/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/numpy/core/include -I/Library/Frameworks/Python.framework/Versions/3.7/include/python3.7m -c src/pymain.cpp -o build/temp.macosx-10.6-intel-3.7/src/pymain.o -std=c++11" failed with exit status 1
        ----------------------------------------
    ERROR: Command "/usr/local/bin/python3.7 -u -c 'import setuptools, tokenize;__file__='"'"'/private/var/folders/49/lx4dfjcs6dn11kb8cmsw5n600000gn/T/pip-install-2w_prpxg/pystackreg/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /private/var/folders/49/lx4dfjcs6dn11kb8cmsw5n600000gn/T/pip-record-_odidbgb/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/var/folders/49/lx4dfjcs6dn11kb8cmsw5n600000gn/T/pip-install-2w_prpxg/pystackreg/
    
    opened by Stephenfang51 3
  • PyStackReg missing for Windows on conda

    PyStackReg missing for Windows on conda

    Since (fb0f9a14ac3f88c159a486cea13292aab6f7e777), using the environnement.yml with Pystackreg as dependency to install imagepy with anaconda fails on windows because the package is only available for Linux on anaconda.

    PackageNotFoundError: Packages missing in current channels:
    
      - pystackreg
    
    opened by LauLauThom 3
  • web out of service

    web out of service

    Hello, I was wondering about the home page - http://imagepy.org but it seems that there is an issue to access this page:

    This site can’t be reached imagepy.org’s server IP address could not be found.
    Try:
        Checking the connection
        Checking the proxy, firewall, and DNS configuration
    ERR_NAME_NOT_RESOLVED
    
    opened by Borda 3
  • Error in atexit._run_exitfuncs

    Error in atexit._run_exitfuncs

    Traceback (most recent call last): File "E:/Tools/python3.6.3/Lib/site-packages/imagepy/main.py", line 4, in imagepy.show() File "E:\Tools\python3.6.3\lib\site-packages\imagepy_init_.py", line 31, in show ImagePy(None).Show() File "E:\Tools\python3.6.3\lib\site-packages\imagepy\ui\mainframe.py", line 52, in init if IPy.uimode()=='ipy': self.load_aui() File "E:\Tools\python3.6.3\lib\site-packages\imagepy\ui\mainframe.py", line 96, in load_aui self.widgets = widgetsloader.build_widgets(self, 'widgets', 'plugins') File "E:\Tools\python3.6.3\lib\site-packages\imagepy\ui\widgetsloader.py", line 34, in build_widgets return build_widgets_panel(parent, datas, panel) File "E:\Tools\python3.6.3\lib\site-packages\imagepy\ui\widgetsloader.py", line 21, in build_widgets_panel build_widget(choicebook, i) File "E:\Tools\python3.6.3\lib\site-packages\imagepy\ui\widgetsloader.py", line 10, in build_widget parent.AddPage(i(parent), i.title, False ) File "E:\Tools\python3.6.3\lib\site-packages\imagepy\widgets\histogram\histogram_wgt.py", line 17, in init self.sli_high = FloatSlider(self, (0,255), 0, '') File "E:\Tools\python3.6.3\lib\site-packages\imagepy\ui\widgets\normal.py", line 283, in init subsizer.Add( self.spin, 0, wx.ALIGN_CENTER|wx.BOTTOM|wx.EXPAND, 5 ) wx._core.wxAssertionError: C++ assertion "!(flags & (wxALIGN_BOTTOM | wxALIGN_CENTRE_VERTICAL))" failed at ....\src\common\sizer.cpp(2114) in wxBoxSizer::DoInsert(): Vertical alignment flags are ignored with wxEXPAND Error in atexit._run_exitfuncs: wx._core.wxAssertionError: C++ assertion "GetEventHandler() == this" failed at ....\src\common\wincmn.cpp(475) in wxWindowBase::~wxWindowBase(): any pushed event handlers must have been removed

    How can I solve this problem

    opened by Alduin-Y 1
  • ROI add operation doesnt work

    ROI add operation doesnt work

    The version I installed with pip is ok to use ROI add But the codes I download from github doesn't work When I draw a roi and add it it doesn't work image image

    opened by wcyjerry 1
  • wx._core.wxAssertionError: C++ assertion

    wx._core.wxAssertionError: C++ assertion "!

    File "D:\walyn\myvi-master\myvi\canvas3d.py", line 158, in init tsizer.Add( self.btn_color, 0, wx.ALIGN_CENTER|wx.ALL|(0, wx.EXPAND)[platform.system() in ['Windows', 'Linux']], 0 ) wx._core.wxAssertionError: C++ assertion "!(flags & (wxALIGN_BOTTOM | wxALIGN_CENTRE_VERTICAL))" failed at ....\src\common\sizer.cpp(2184) in wxBoxSizer::DoInsert(): Vertical alignment flags are ignored with wxEXPAND

    How can I handle this problem? please

    opened by walynlee 0
  • Can I translate it into Chinese

    Can I translate it into Chinese

    This is a very good open source project. I would like to make the GUI interface of this project Chinese, so as to recommend it to more of my friends. Could you give me some guidance on how to make it Chinese?

    opened by Chris-zixuan 4
  • This program needs access to the screen. Please run with a Framework build of python, and only when you are logged in on the main display of your Mac.

    This program needs access to the screen. Please run with a Framework build of python, and only when you are logged in on the main display of your Mac.

    mac 系统 我是conda 虚拟环境里安装的 imagepy,使用 pythonw -m imagepy 会报错。 查阅资料后解决 https://www.cnblogs.com/songzhenhua/p/14375283.html

    1. 激活虚拟环境
    2. conda install -c conda-forge python.app
    3. pythonw -m imagepy

    成功运行

    opened by Chris-zixuan 0
Releases(v0.2)
Owner
ImagePy
python imageprocess framework
ImagePy
A collection of semantic image segmentation models implemented in TensorFlow

A collection of semantic image segmentation models implemented in TensorFlow. Contains data-loaders for the generic and medical benchmark datasets.

bobby 16 Dec 06, 2019
Pairwise model for commonlit competition

Pairwise model for commonlit competition To run: - install requirements - create input directory with train_folds.csv and other competition data - cd

abhishek thakur 45 Aug 31, 2022
Confidence Propagation Cluster aims to replace NMS-based methods as a better box fusion framework in 2D/3D Object detection

CP-Cluster Confidence Propagation Cluster aims to replace NMS-based methods as a better box fusion framework in 2D/3D Object detection, Instance Segme

Yichun Shen 41 Dec 08, 2022
Efficient face emotion recognition in photos and videos

This repository contains code of face emotion recognition that was developed in the RSF (Russian Science Foundation) project no. 20-71-10010 (Efficien

Andrey Savchenko 239 Jan 04, 2023
Simple data balancing baselines for worst-group-accuracy benchmarks.

BalancingGroups Code to replicate the experimental results from Simple data balancing baselines achieve competitive worst-group-accuracy. Replicating

Meta Research 29 Dec 02, 2022
Code for the CVPR2021 workshop paper "Noise Conditional Flow Model for Learning the Super-Resolution Space"

NCSR: Noise Conditional Flow Model for Learning the Super-Resolution Space Official NCSR training PyTorch Code for the CVPR2021 workshop paper "Noise

57 Oct 03, 2022
Code for "Primitive Representation Learning for Scene Text Recognition" (CVPR 2021)

Primitive Representation Learning Network (PREN) This repository contains the code for our paper accepted by CVPR 2021 Primitive Representation Learni

Ruijie Yan 76 Jan 02, 2023
PyTorch Implement for Path Attention Graph Network

SPAGAN in PyTorch This is a PyTorch implementation of the paper "SPAGAN: Shortest Path Graph Attention Network" Prerequisites We prefer to create a ne

Yang Yiding 38 Dec 28, 2022
EfficientNetV2 implementation using PyTorch

EfficientNetV2-S implementation using PyTorch Train Steps Configure imagenet path by changing data_dir in train.py python main.py --benchmark for mode

Jahongir Yunusov 86 Dec 29, 2022
YOLOv5 detection interface - PyQt5 implementation

所有代码已上传,直接clone后,运行yolo_win.py即可开启界面。 2021/9/29:加入置信度选择 界面是在ultralytics的yolov5基础上建立的,界面使用pyqt5实现,内容较简单,娱乐而已。 功能: 模型选择 本地文件选择(视频图片均可) 开关摄像头

487 Dec 27, 2022
Human Activity Recognition example using TensorFlow on smartphone sensors dataset and an LSTM RNN. Classifying the type of movement amongst six activity categories - Guillaume Chevalier

LSTMs for Human Activity Recognition Human Activity Recognition (HAR) using smartphones dataset and an LSTM RNN. Classifying the type of movement amon

Guillaume Chevalier 3.1k Dec 30, 2022
Implementation of "StrengthNet: Deep Learning-based Emotion Strength Assessment for Emotional Speech Synthesis"

StrengthNet Implementation of "StrengthNet: Deep Learning-based Emotion Strength Assessment for Emotional Speech Synthesis" https://arxiv.org/abs/2110

RuiLiu 65 Dec 20, 2022
Extracting and filtering paraphrases by bridging natural language inference and paraphrasing

nli2paraphrases Source code repository accompanying the preprint Extracting and filtering paraphrases by bridging natural language inference and parap

Matej Klemen 1 Mar 09, 2022
Let's Git - Versionsverwaltung & Open Source Hausaufgabe

Let's Git - Versionsverwaltung & Open Source Hausaufgabe Herzlich Willkommen zu dieser Hausaufgabe für unseren MOOC: Let's Git! Wir hoffen, dass Du vi

1 Dec 13, 2021
UA-GEC: Grammatical Error Correction and Fluency Corpus for the Ukrainian Language

UA-GEC: Grammatical Error Correction and Fluency Corpus for the Ukrainian Language This repository contains UA-GEC data and an accompanying Python lib

Grammarly 226 Dec 29, 2022
torchlm is aims to build a high level pipeline for face landmarks detection, it supports training, evaluating, exporting, inference(Python/C++) and 100+ data augmentations

💎A high level pipeline for face landmarks detection, supports training, evaluating, exporting, inference and 100+ data augmentations, compatible with torchvision and albumentations, can easily instal

DefTruth 142 Dec 25, 2022
AOT (Associating Objects with Transformers) in PyTorch

An efficient modular implementation of Associating Objects with Transformers for Video Object Segmentation in PyTorch

162 Dec 14, 2022
PyTorch implementation of Soft-DTW: a Differentiable Loss Function for Time-Series in CUDA

Soft DTW Loss Function for PyTorch in CUDA This is a Pytorch Implementation of Soft-DTW: a Differentiable Loss Function for Time-Series which is batch

Keon Lee 76 Dec 20, 2022
GNN-based Recommendation Benchmark

GRecX A Fair Benchmark for GNN-based Recommendation Homepage and Documentation Homepage: Documentation: Paper: GRecX: An Efficient and Unified Benchma

73 Oct 17, 2022
Code for "MetaMorph: Learning Universal Controllers with Transformers", Gupta et al, ICLR 2022

MetaMorph: Learning Universal Controllers with Transformers This is the code for the paper MetaMorph: Learning Universal Controllers with Transformers

Agrim Gupta 50 Jan 03, 2023