Uploaded image for project: 'Instrument control development'
  1. Instrument control development
  2. INSTRM-2354

Rename 'np' variable in centroid_wrapper.pyx

    XMLWordPrintable

    Details

    • Type: Task
    • Status: Done (View Workflow)
    • Priority: Normal
    • Resolution: Done
    • Component/s: None
    • Labels:
    • Sprint:
      preRun19Oct2024

      Description

      With newer cython, the np arg name in the centroid prototype conflicts with the np import. Rename it.

      cloomis@shell-ics:windowedCentroid ((1.9.5) *)$ python setup.py build_ext -i
      Compiling centroid_wrapper.pyx because it changed.
      [1/1] Cythonizing centroid_wrapper.pyx
      /software/condaRoot/envs/rubin8-ics/lib/python3.11/site-packages/Cython/Compiler/Main.py:381: FutureWarning: Cython directive 'language_level' not set, using '3str' for now (Py3). This has changed from earlier releases! File: /software/mhs/products/Linux64/ics_mcsActor/1.9.5/python/mcsActor/windowedCentroid/centroid_wrapper.pyx
        tree = Parsing.p_module(s, pxd, full_module_name)
      
      Error compiling Cython file:
      ------------------------------------------------------------
      ...
                      int qual;
                      int idnum;
      
      
      cdef extern from "centroid.h" nogil:
           centroids *centroid(int *image, int n_x, int n_y, int thresh1, int thresh2, double fwhmx, double fwhmy,int boxFind, int boxCent,int *np, int nmin, int maxIt, int verbose)
                                                                                                                                                ^
      ------------------------------------------------------------
      
      centroid_wrapper.pyx:41:138: cdef variable 'np' declared after it is used
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                karr karr
                Reporter:
                cloomis cloomis
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: