ConnectTool
 All Classes Namespaces Files Functions Variables Pages
Variables
test_image_png Namespace Reference

Variables

float box_margin_left = 0.07
 
float box_margin_bot = 0.08
 
float box_width = 0.75
 
float box_height = 0.83
 
list magtypes = ['WSO','ADAPT','NSO','SDO171']
 
string magpath = '/home/indurain/local_swdatabase/dir.data/DATA_OBS/Maps/MAGCARR/WSO/wso_wso_CR2161.txt'
 
tuple map2D = interface_read_map2D.read(magtype,magpath)
 
tuple positions_sc = module_timespace.Coordinate()
 HCS layer Figure fig, ax = plt.subplots(1, 1) ax.set_position([box_margin_left,box_margin_bot,box_width,box_height]) #sub.set_position([left, bottom, width, height]) Contour plt.contour(X,Y,Z,levels) len(X) = M, len(Y) = N, Z = array-like(N,M), levels = [array-like] label_hcs = 'HCS' hcs = module_plot.plot_hcs(ax,map2D,[0. More...
 
string label_visible_disk = 'Visible disk'
 
tuple visible_disk = module_plot.plot_visible_disk(ax,positions_sc,[0.],[label_visible_disk],'black')
 
list handle_visible_disk = handles[labels.index(label_visible_disk)]
 
tuple legend_visible_disk = ax.legend(handles=[handle_visible_disk],fontsize=10,bbox_to_anchor=(1,0.2),loc='center left')
 Legend HCS legend_hcs = ax.legend(handles=[handle_hcs],fontsize=10,bbox_to_anchor=(1,0.3),loc='center left') legend_hcs.draw_frame(False) #No frame ax.add_artist(legend_hcs) #Add this legend to the plot Legend Visible disk. More...
 
tuple layer_mag = Image.open('layer_' + magtype.lower() + '.png')
 
tuple layer_legend = Image.open('layer_legend.png')
 
tuple layer_axis = Image.open('layer_axis.png')
 
tuple layer_vd = Image.open('layer_vd.png')
 
tuple final = Image.alpha_composite(layer_mag,layer_legend)
 

Variable Documentation

float test_image_png.box_height = 0.83
float test_image_png.box_margin_bot = 0.08
float test_image_png.box_margin_left = 0.07
float test_image_png.box_width = 0.75
tuple test_image_png.final = Image.alpha_composite(layer_mag,layer_legend)
list test_image_png.handle_visible_disk = handles[labels.index(label_visible_disk)]
string test_image_png.label_visible_disk = 'Visible disk'
tuple test_image_png.layer_axis = Image.open('layer_axis.png')
tuple test_image_png.layer_legend = Image.open('layer_legend.png')
tuple test_image_png.layer_mag = Image.open('layer_' + magtype.lower() + '.png')
tuple test_image_png.layer_vd = Image.open('layer_vd.png')
tuple test_image_png.legend_visible_disk = ax.legend(handles=[handle_visible_disk],fontsize=10,bbox_to_anchor=(1,0.2),loc='center left')

Legend HCS legend_hcs = ax.legend(handles=[handle_hcs],fontsize=10,bbox_to_anchor=(1,0.3),loc='center left') legend_hcs.draw_frame(False) #No frame ax.add_artist(legend_hcs) #Add this legend to the plot Legend Visible disk.

string test_image_png.magpath = '/home/indurain/local_swdatabase/dir.data/DATA_OBS/Maps/MAGCARR/WSO/wso_wso_CR2161.txt'
list test_image_png.magtypes = ['WSO','ADAPT','NSO','SDO171']
tuple test_image_png.map2D = interface_read_map2D.read(magtype,magpath)
tuple test_image_png.positions_sc = module_timespace.Coordinate()

HCS layer Figure fig, ax = plt.subplots(1, 1) ax.set_position([box_margin_left,box_margin_bot,box_width,box_height]) #sub.set_position([left, bottom, width, height]) Contour plt.contour(X,Y,Z,levels) len(X) = M, len(Y) = N, Z = array-like(N,M), levels = [array-like] label_hcs = 'HCS' hcs = module_plot.plot_hcs(ax,map2D,[0.

],[label_hcs],'red') Just for legend Get all artists on plot, and their label handles, labels = ax.get_legend_handles_labels() Find label_contour handle_hcs = handles[labels.index(label_hcs)] Plot ax.axis([module_plot.xtick_loc[0],module_plot.xtick_loc[-1],module_plot.ytick_loc[0],module_plot.ytick_loc[-1]]) ax.set_axis_off() fig.set_size_inches(8,6) fig.set_dpi(100) fig.savefig('layer_hcs_' + magtype.lower() + '.svg',format="svg",transparent=True)

tuple test_image_png.visible_disk = module_plot.plot_visible_disk(ax,positions_sc,[0.],[label_visible_disk],'black')