Reference#

Software and API.

smart Package#

smart.processing Module#

Functions#

map_threshold(im_map)

Set off disk pixels to black and clip the vmin and vmax of the map.

calculate_cosine_correction(im_map)

Find the cosine correction values for on-disk pixels.

cosine_correct_data(im_map[, cosmap])

Perform magnetic field cosine correction.

smooth_los_threshold(im_map[, thresh, ...])

We apply Smoothing, a noise Threshold, and an LOS correction, respectively, to the data.

smart_prep(im_map)

Prepare map for use in segmentation and characterization processes.

smart.differential_rotation Module#

Functions#

diff_rotation(ref_map, im_map)

Differentially rotate input map to reference map.

smart.indexed_grown_mask Module#

Functions#

index_and_grow_mask(current_map, rotated_map)

Performing Indexing and Growing of the Mask (hence the name IGM).

plot_indexed_grown_mask(current_map, ...[, ...])

Plotting the fully processed and segmented magnetogram with labels and AR contours optionally displayed.

smart.calculate_properties Module#

Functions#

cosine_weighted_area_map(im_map)

Calculate the cosine-weighted area map for a feature and determine the feature's total area.

extract_features(sorted_labels)

Extract binary masks for each feature found in index_and_grow_mask's sorted_labels.

dB_dt(current_map, previous_map)

A magnetogram differentially rotated to time 't' is subtracted from a processed magnetogram from time 't', and the resultant map is divided by their time separation, yielding a map of the temporal change in field strength.

get_properties(im_map, dB_dt, dt, sorted_labels)

Calculate various properties for each detected feature.

smart.polarity_separation_line Module#

Functions#

separate_polarities(im_map, feature_mask[, ...])

Divide detected feature into a positive and a negative mask, and dilate both masks.

polarity_separation_line_length(...)

Calculate the length of the polarity separation line (the boundary line between the positive and negative regions of an AR).

get_strong_gradient_length(im_map, ...[, ...])

Calculate the length of the strong gradients in the magnetic field.