As you said, the sampling rate is stored in the info attribute.
Channel names are one of the rare elements of info that is directly accessible as an attribute with the raw.ch_names syntax, but its primary location is info in raw.info['ch_names'].
The sampling rate is not exposed as an attribute and is only stored in info. If you want to retrieve it and store it elsewhere, you have to use the full dictionary syntax: fs = raw.info['sfreq'].
              
              
              2 Likes