Giter Club home page Giter Club logo

Comments (13)

ctrueden avatar ctrueden commented on August 16, 2024

We don't use a prefix like calculate for any other ops, so IMO it makes sense to call them area and bounding_box, with Area and BoundingBox interfaces.

from imagej-ops.

ctrueden avatar ctrueden commented on August 16, 2024

Regarding HistogramCreate, we could rename to just Histogram. The iface is Ops.Histogram and the op name is histogram.

Another case of variation in naming is the thresholding stuff, to differentiate between ComputeThreshold and ApplyThreshold ops... but in general, my vote is to keep names shorter.

from imagej-ops.

dietzc avatar dietzc commented on August 16, 2024

I the case of Histogram you might end up with an Op Histogram which produces a Histogram. So same name, different semantic meaning (I know that we only have Histogram1d at the moment, but there may be cases like the one described above)? I'm also voting for short names, but I'm somehow worried we will have more confusion and exceptions with that naming schema.

from imagej-ops.

dscho avatar dscho commented on August 16, 2024

Sorry, I wanted to address this today, but I literally spent 7.5h on trying to fix pom-fiji and now I'm spent for the day 😦

from imagej-ops.

ctrueden avatar ctrueden commented on August 16, 2024

@dscho I am curious how you wanted to "address" this. Do you mean just write a comment? Or... did you have an idea for changing the code somehow?

from imagej-ops.

dietzc avatar dietzc commented on August 16, 2024

Any further ideas? I would do the following at the moment: If it is obvious (Area, Mean, Sum, ...) we keep short names. But as soon as there may be some confusion (Histogram vs. Histogram for example), I suggest the prefixes "Calc" or "Compute".

For example the operation would be named
ComputeHistogram
the Histogram itself Histogram.

Any comments?

from imagej-ops.

ctrueden avatar ctrueden commented on August 16, 2024

There are two separate issues: what to name the op (i.e., the @Plugin annotation's name value), and what to name the class. These have historically diverged, although we could consider unifying it.

I think this would be good to settle at the next hackathon, so I assigned it to the 0.20.0 milestone.

from imagej-ops.

ctrueden avatar ctrueden commented on August 16, 2024

@dietzc and I discussed and settled on the following:

  • SmallestEnclosingRectangleOp - iface for Op plugins that compute a SmallestEnclosingRectangle (data structure)
  • MeanOp for Op plugins that compute a Mean (data structure)
  • etc.

from imagej-ops.

ctrueden avatar ctrueden commented on August 16, 2024

This issue can be closed out when all ops in imagej-ops abide by this convention.

from imagej-ops.

ctrueden avatar ctrueden commented on August 16, 2024

I really quickly codified some of these naming decisions on the wiki. See also #16.

from imagej-ops.

dietzc avatar dietzc commented on August 16, 2024

can be closed see wiki https://github.com/imagej/imagej-ops/wiki/Naming

from imagej-ops.

ctrueden avatar ctrueden commented on August 16, 2024

This issue can be closed out when all ops in imagej-ops abide by this convention.

And we are unfortunately quite far from that: nearly no op ends with the Op suffix mentioned in the documentation. From the docs:

The reason for the Op suffix of FooOp etc. is in case the operation works with a data structure of the same name. For example, a MeanOp might compute a Mean, a SmallestEnclosingRectangleOp might compute a SmallestEnclosingRectangle, and so on.

My understanding was that we would close this issue only after all ops were renamed to conform to this naming scheme.

from imagej-ops.

dietzc avatar dietzc commented on August 16, 2024

ah sorry, I overlooked that. makes sense.

from imagej-ops.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.