<jupyter_start><jupyter_text>Reads one fileThis jupyter notebook shows how to use the **open_dataset** function of **GOES** package, to read and get the information from **one** GOES-16/17 file.Index:- [Reads file](reads_file)- [Gets attribute from file](gets_attribute)- [Gets variable from file](gets_variable)- [Gets image from file](gets_image)- [Gets dimension from file](gets_dimension)  Reads file Sets path and name of file that will be read.<jupyter_code>path = '/home/joao/Downloads/GOES-16/ABI/'
file = 'OR_ABI-L2-CMIPF-M6C13_G16_s20200782000176_e20200782009496_c20200782010003.nc'<jupyter_output><empty_output><jupyter_text>Import the GOES package.<jupyter_code>import GOES<jupyter_output><empty_output><jupyter_text>Reads file.<jupyter_code>ds = GOES.open_dataset(path+file)<jupyter_output><empty_output><jupyter_text>Display the content of file.<jupyter_code>print(ds)<jupyter_output><class 'GOES.processing.processing_data.open_dataset'>

attribute:
   naming_authority              : gov.nesdis.noaa
   Conventions                   : CF-1.7
   Metadata_Conventions          : Unidata Dataset Discovery v1.0
   standard_name_vocabulary      : CF Standard Name Table (v35, 20 July 2016)
   institution                   : DOC/NOAA/NESDIS > U.S. Department of Commerce, N...
   project                       : GOES
   production_site               : NSOF
   production_environment        : OE
   spatial_resolution            : 2km at nadir
   orbital_slot                  : GOES-East
   platform_ID                   : G16
   instrument_type               : GOES R Series Advanced Baseline Imager
   scene_id                      : Full Disk
   instrument_ID                 : FM1
   dataset_name                  : OR_ABI-L2-CMIPF-M6C13_G16_s20200782000176_e20200...
   iso_series_metadata_id        : 8c9e8150-3692-11e3-aa6e-0800200c9a66
   title                         : ABI L2 [...]<jupyter_text>Gets attribute from file **Attribute** is a string parameters with information about the file. To get one attribute from file, write the follow:<jupyter_code>title = ds.attribute('title')
print(title)
orbital = ds.attribute('orbital_slot')
print(orbital)
resol = ds.attribute('spatial_resolution')
print(resol)<jupyter_output>2km at nadir<jupyter_text>Gets variable from file **Variable** is a python class that content a parameter with theirs attributes. Write the follow to get a variable:<jupyter_code>hsat = ds.variable('nominal_satellite_height')
print(hsat)<jupyter_output><class 'GOES.processing.processing_data.GOES'>

Keys:
   long_name                     : nominal satellite height above GRS 80 ellipsoid ...
   standard_name                 : height_above_reference_ellipsoid
   units                         : km
   dimensions                    : ()
   data                          : 35786.0234375<jupyter_text>Print one attribute of parameter.<jupyter_code>print(hsat.units)<jupyter_output>km<jupyter_text>Print the parameter value:<jupyter_code>print(hsat.data)<jupyter_output>35786.0234375<jupyter_text>In the above example, the parameter is a simple number, for this reason, when the method **data** was used, the value was printed directly. \**Get other variable:**<jupyter_code>times = ds.variable('time_bounds')
print(times)<jupyter_output><class 'GOES.processing.processing_data.GOES'>

Keys:
   long_name                     : Scan start and end times in seconds since epoch ...
   dimensions                    : (number_of_time_bounds)
   data                          (2) object<jupyter_text>Print the parameter value:<jupyter_code>print(times.data)<jupyter_output>[datetime.datetime(2020, 3, 18, 20, 0, 17, 677081)
 datetime.datetime(2020, 3, 18, 20, 9, 49, 618306)]<jupyter_text>In this case, the parameter is an array and has two elements. Use the position index to select one of them.<jupyter_code>print(times.data[1])<jupyter_output>2020-03-18 20:09:49.618306<jupyter_text>Print one attribute of parameter.<jupyter_code>print(times.long_name)<jupyter_output>Scan start and end times in seconds since epoch (2000-01-01 12:00:00)<jupyter_text>Gets image from file **Image** is a Python class that contains a parameter that has the dimensions ('y', 'x'). Write the follow to get a image:<jupyter_code>CMI, Lons, Lats = ds.image('CMI')
print(CMI)<jupyter_output><class 'GOES.processing.processing_data.GOES'>

Keys:
   long_name                     : ABI L2+ Cloud and Moisture Imagery brightness te...
   standard_name                 : toa_brightness_temperature
   units                         : K
   undef                         : nan
   axis                          : YX
   dimensions                    : (y, x)
   t                             <class 'GOES.processing.processing_data.GOES'>
   time_bounds                   <class 'GOES.processing.processing_data.GOES'>
   pixels_limits                 (4) int64
   data                          (5424, 5424) float32<jupyter_text>Print the parameter value:<jupyter_code>print(CMI.data)<jupyter_output>[[nan nan nan ... nan nan nan]
 [nan nan nan ... nan nan nan]
 [nan nan nan ... nan nan nan]
 ...
 [nan nan nan ... nan nan nan]
 [nan nan nan ... nan nan nan]
 [nan nan nan ... nan nan nan]]<jupyter_text>Print one attribute of parameter.<jupyter_code>print(CMI.standard_name)<jupyter_output>toa_brightness_temperature<jupyter_text>Gets dimension from file **Dimensions** is a class with the spatial attributes of the variables. To get one dimension from file, write the follow:<jupyter_code>dim_x = ds.dimension('x')
print(dim_x)<jupyter_output><class 'GOES.processing.processing_data.GOES'>

Keys:
   name                          : x
   size                          : 5424<jupyter_text>Theirs attributes are **name** and **size**.<jupyter_code>print(dim_x.name)
print(dim_x.size)<jupyter_output>5424
{'fraction_non_alphanumeric': 0.093631669535284, 'fraction_numerical': 0.041480206540447505, 'mean_word_length': 3.015894955079475, 'pattern_counts': {'":': 0, '<': 62, '<?xml version=': 0, '>': 63, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '17', 'dir': 'jupyter-structured-clean-dedup', 'id': '505919', 'license': 'BSD-3-Clause', 'n_tokens_mistral': 2012, 'n_tokens_neox': 1809, 'n_words': 448, 'path': 'examples/v3.2/reads_one_file.ipynb', 'repo_name': 'joaohenry23/GOES', 'size': '5810'}