Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do we need a discretisation class #17

Open
bnlawrence opened this issue Apr 6, 2016 · 6 comments
Open

Do we need a discretisation class #17

bnlawrence opened this issue Apr 6, 2016 · 6 comments

Comments

@bnlawrence
Copy link
Member

The discretisation class is defined like this:

def discretisation():
    """ """
    return {
        'type': 'class',
        'base': 'science.sub_process',
        'is_abstract': False,
        'properties': []
    }`

It seems redundant, being just a way of renaming a sub_process ... is that really necessary, the property name and definition give enough context for that don't they?

@davidhassell
Copy link
Contributor

I'm in favour of keeping it. Because, in no particular order

  • It's not alone in being a renamed "something" with no extra properties (science.detail is a good example);
  • A dicretisation is something that all numerical models have, just like conservation properties
  • If we had defined a property to discretisation we wouldn't be worrying about this.
  • It doesn't feel like a sub-process - I recall we sub-classed sub_process merely as a convienience to get the ('details','science.detail','0.N', 'Sets of properties for this process.') functionality.

Please correct me where I'm wrong.

@bnlawrence
Copy link
Member Author

This is clearly a matter of taste and scale :-).

Taking your points one by one:

  • It is alone apart from science.detail.
  • We clearly need a discretisation property, but do we need a discretisation property type?
  • Correct, but we don't. That could apply to any property ...
  • Agreed. So is the problem with the name of the sub_process type?

But think for a moment about how the UML for this will look in terms of documentation: we will get
discretisation isA sub_process ... so how much benefit have we really got?

Wouldn't it be better to rename the sub_process type?

@davidhassell
Copy link
Contributor

Ok. I agree that this is subjective :)

On renaming sub_process, I note that resolution and extent also are types to sub_process. I guess what you're hinting at is a name for a type which contains a "distinct chunk of the thing it's contained in". Currently, thing can be process or grid

@bnlawrence
Copy link
Member Author

I agree ... "distinct chunk" ... of "thing" ... but what to call it :-)?

@bnlawrence
Copy link
Member Author

Google defines component: a part or element of a larger whole ...
synonyms: part, piece, bit, constituent, element, ingredient; unit, module, item; section, portion;

We could reuse component but there is the potential for confusion with s/w components, but section or part might be possible? It's just a type, it's property name will give it meaning ...

@davidhassell
Copy link
Contributor

I'd thought of partition, but in that vein, I probably prefer section. I do rather like component, but appreciate the possible conflict. How about component_part?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants