[Smtk-developers] An idea for connecting SMTK sessions

TJ Corona tj.corona at kitware.com
Mon Jun 19 22:49:55 EDT 2017


>> I’m not sure if having the model be implicitly being created is a good idea since the conversion may result in a loss of information

That’s true: I guess only some sessions would be able to convert back and forth without loss. Any implicit operations that resulted in an assumption of information or a loss of information would definitely be a bad thing.

> I agree with Bob that implicit conversion could be a problem, especially when a similar operation exists in multiple sessions.


Also true. This gets to the heart of one of the design patterns in SMTK that I don’t quite understand, though: how do we better exploit the common interface of the default session to construct operators that span multiple derived sessions? The option of extending operators across sessions via implicit conversions is probably the wrong path, but I think that the problem it addresses is worth considering. Encompassing meta-operators that manually call their derived counterparts could work, but it seems like there is opportunity here for a more elegant solution. 

> But I think it is nice to have a way to perform the conversion. 

Me too! I’ve been thinking about the conversion between the mesh session and VTK in a similar context. We discussed wrapping SMTK mesh objects as zero-copy VTK objects, and I’d like to give that a try when I get a chance. Perhaps a similar paradigm could exist between some of the sessions.

Thomas J. Corona, Ph.D.
Kitware, Inc.
Senior R&D Engineer
21 Corporate Drive
Clifton Park, NY 12065-8662
Phone: 518-881-4443

> On Jun 19, 2017, at 9:21 PM, David Thompson <david.thompson at kitware.com> wrote:
> 
> Hi TJ,
> 
> I agree with Bob that implicit conversion could be a problem, especially when a similar operation exists in multiple sessions.
> 
> But I think it is nice to have a way to perform the conversion. In fact, the ERDC CS session has an operator for converting any non-parametric model into a model in that session. If we come up with a convention, we should make sure that operator is brought along for the ride.
> 
>     David
> 
> On Jun 19, 2017, at 22:08, Bob Obara <bob.obara at kitware.com <mailto:bob.obara at kitware.com>> wrote:
> 
>> Wouldn’t  the conversion to/from pair just be in a  separate plugin (since it would need to be built against a pair of sessions)?  In this case the conversion operators would be added to the corresponding sessions when the plugin is loaded.  I’m not sure if having the model be implicitly being created is a good idea since the conversion may result in a loss of information) - explicit conversion at least would inform the user of the conversion limitations - now a workflow that requires such a conversion (for example going from a polygonal planar model to a 3d non-planar discrete model after applying an elevation field) would be able to apply it implicitly when going from one task in the workflow to another since the workflow designer would have factored in the conversion issues when designing the workflow.
>> 
>> Does that make sense or am I missing something?
>> 
>> Bob
>> 
>> 
>> Robert M. O'Bara, MEng.
>> Assistant Director of Scientific Computing
>> 
>> Kitware Inc.
>> 28 Corporate Drive
>> Suite 101
>> Clifton Park, NY 12065
>> 
>> Phone: (518) 881- 4931
>> 
>> 
>> 
>> 
>>> On Jun 19, 2017, at 6:45 PMEDT, TJ Corona <tj.corona at kitware.com <mailto:tj.corona at kitware.com>> wrote:
>>> 
>>> Hi all,
>>> 
>>> I have an idea, and I’d like to know what everyone thinks. We currently have multiple sessions with different backings, and each of these sessions have a different set of operators that it can perform. To my understanding, if a user wants to cross from session to session, they currently have to do so manually (i.e. create a working model in one session, open the model in a new session and perform the operation). What if we created “bridges” between sessions that facilitated to/from operations for each session pair, and then made these conversions implicit during model manipulation in ModelBuilder? For example, we create a bridge between the polygon and mesh sessions that describe how to convert a model of one type to the other (going from polygon to mesh would imply an implicit meshing operation, and going from mesh to model would imply an extraction of vertices, edges and faces in the mesh session to construct a polygon model). This way, a user could create a polygon model and then perform any of the meshing operations on it without having to know what session currently backs their model. Is this crazy?
>>> 
>>> Sincerely,
>>> T.J.
>>> 
>>> Thomas J. Corona, Ph.D.
>>> Kitware, Inc.
>>> Senior R&D Engineer
>>> 21 Corporate Drive
>>> Clifton Park, NY 12065-8662
>>> Phone: 518-881-4443
>>> 
>>> _______________________________________________
>>> Smtk-developers mailing list
>>> Smtk-developers at smtk.org <mailto:Smtk-developers at smtk.org>
>>> http://public.kitware.com/mailman/listinfo/smtk-developers <http://public.kitware.com/mailman/listinfo/smtk-developers>
>> 
>> _______________________________________________
>> Smtk-developers mailing list
>> Smtk-developers at smtk.org <mailto:Smtk-developers at smtk.org>
>> http://public.kitware.com/mailman/listinfo/smtk-developers <http://public.kitware.com/mailman/listinfo/smtk-developers>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/smtk-developers/attachments/20170619/7fcde1bf/attachment.html>


More information about the Smtk-developers mailing list