Conversation
…and asymmetric_peak_map function, added data tests directory and created a test for both functions
…umiSpy#250 and made nanoparticles.hspy significantly smaller
…and asymmetric_peak_map function, added data tests directory and created a test for both functions
…umiSpy#250 and made nanoparticles.hspy significantly smaller
c13c7ae to
ce51762
Compare
568f59e to
ff32909
Compare
…nct files, updated ROIs
|
can you merge in the updated main branch to resolve conflicts with the examples that have been updated in the previous PR |
|
syncing with main didnt quite work so i will have to do it manually i will make the changes in the morning and put the arrow for ready for review once i fixed it. |
should be ready now for review |
| """ | ||
| Indexing | ||
| ======== | ||
| Indexing is achieved using `inav <HS_inav_>`__ or `isig <HS_isig_>`__, which allows the navigation- and signalaxes to be accessed independently. |
| # Creating a small example signal | ||
| # ------------------------------- | ||
| # | ||
| # We create a simple ``Signal1D`` with a total shape of ``(2, 3, 4)``: |
| Indexing | ||
| ======== | ||
| Indexing is achieved using `inav <HS_inav_>`__ or `isig <HS_isig_>`__, which allows the navigation- and signalaxes to be accessed independently. | ||
| The index operation returns a view of the original signal. |
There was a problem hiding this comment.
maybe needs to be clarified/reworded - not sure if I understand what is meant here
There was a problem hiding this comment.
I find the example easy to follow until the isig section. I find the indexing of the array a bit confusing when dealing with isig, maybe annotations to the output arrays or a graphical illustration could improve this
| """ | ||
| Region of Interest (ROI) | ||
| ======================== | ||
| This example demonstrates how to use ROIs from Hyperspy. ROIs are used to select a subset of the data for further analysis. It can be done interactively aswell as non interactively. |
There was a problem hiding this comment.
replace with "This example demonstrates use of HyperSpy ROIs for a hyperspectral luminescence dataset. ROIs are used to select a subset of the data for analysis, this can be done interactively as well as non interactively."
| # ------------------- | ||
| # | ||
| # For non-interactove ROIs we have to specify the type of ROI we want to use. In this case we'll use | ||
| # ``Line2DROI(x1=, y1=, x2=, y2=, linewidth=)``. |
There was a problem hiding this comment.
I would remove then equals signs from here: Line2DROI(x1=, y1=, x2=, y2=, linewidth=)
| ax1 = s2.axes_manager[0] | ||
| ax2 = s2.axes_manager[1] | ||
|
|
||
| # define start params |
There was a problem hiding this comment.
Can a units argument be used here to avoid multiplying by scale factors? I think if cx, cy were not defined the default position of the circle should also place within the bounds of the signal
There was a problem hiding this comment.
HyperSpy does have a nice example gallery for ROIs already, in order to not overlap too much I wonder if these examples can be a little more specific to luminescence data analysis. One thing I think could also be included is a computation of calculating the mean of a signal extracted from a ROI - though this is also included in a hyperspy example
There was a problem hiding this comment.
These examples are nice but I wonder if they would be more suited to the HyperSpy example gallery? They don't seem specific to luminescence data, one idea would be to keep the Mathematical Expression header but define a exponential convolved with a gaussian (since this is useful for modelling time-resolved luminescence transients)
There was a problem hiding this comment.
The image at the top of the page has a spike in it, could be better to use a different image to not confuse the which peak the width is being estimated of
| # %% | ||
| # Return Value | ||
| # ^^^^^^^^^^^^ | ||
| # Returns float or lists of floats: ``[width, left, right]``. In our case we get a list of width since we have a map of spectra. |
There was a problem hiding this comment.
replace "In our case we get a list of width since we have a map of spectra." with some along the lines of "We update our metadata of the new signal containing our FWHM's and plot the results"
There was a problem hiding this comment.
Maybe also better suited as a hyperspy example?
I don't love that the ohaver function returns a structured array instead of hyperspy signals, if this was changed I think it would make this example better as well.
There was a problem hiding this comment.
The Line2D ROI example also appears under Plotting - Extraction of Linescan example
Added new example map_function, energie_conversion, ROIs, peak_analysis, basic_model_fitting, custom_model_fitting and restructured the old position of the index example. And changed all the data_cleaning examples to use the build in data module of lumispy
Progress of the PR
upcoming_changesfolder ,