Is your feature request related to a problem? Please describe.
In some scenarios, it might be helpful to rename a View. As an example, consider the evaluation scenario where we normally go through the following steps.
Load a CAS with label information / annotations into the _InitialView.
Rename the _InitialView to goldView.
Make predictions with a model/pipeline and store the predictions in the _initialView.
Compare results from _InitialView to goldView
One may ask why we want to have the predictions in the _InitialView and not in a new view. The reason is mainly because the Eclipse UIMA Annotation Plugin opens the _InitialView as default and otherwise one would always manually need to switch the view to see the predictions. This behavior is in line with cassis, where also the _InitialView is opened initially.
Describe the solution you'd like
I would like to have a function cas.rename_view(view_name: str) that
renames the currently active View, which is specified in cas._current_view, to view_name
switches the cas._current_view to view_name
returns the new View
Describe alternatives you've considered
An alternative would be an annotation copier that allows copying a set of annotations from one view to another. But for this specific use-case, this is certainly slower and more effort.
Additional context
If you agree on the parameter/scope of the function, then I can implement it.
Is your feature request related to a problem? Please describe. In some scenarios, it might be helpful to rename a View. As an example, consider the evaluation scenario where we normally go through the following steps.
_InitialView
._InitialView
togoldView
._initialView
._InitialView
togoldView
One may ask why we want to have the predictions in the
_InitialView
and not in a new view. The reason is mainly because the Eclipse UIMA Annotation Plugin opens the_InitialView
as default and otherwise one would always manually need to switch the view to see the predictions. This behavior is in line with cassis, where also the_InitialView
is opened initially.Describe the solution you'd like I would like to have a function
cas.rename_view(view_name: str)
thatcas._current_view
, toview_name
cas._current_view
toview_name
View
Describe alternatives you've considered An alternative would be an annotation copier that allows copying a set of annotations from one view to another. But for this specific use-case, this is certainly slower and more effort.
Additional context If you agree on the parameter/scope of the function, then I can implement it.