read(file, *args, **kwargs)¶
Read skrf object[s] from a pickle file
Reads a skrf object that is written with
write(), which uses the
- file (str or file-object) – name of file, or a file-object
- **kwargs (*args,) – passed through to pickle.load
>>> n = rf.Network(f=[1,2,3],s=[1,1,1],z0=50) >>> n.write('my_ntwk.ntwk') >>> n_2 = rf.read('my_ntwk.ntwk')
if file is a file-object it is left open, if it is a filename then a file-object is opened and closed. If file is a file-object and reading fails, then the position is reset back to 0 using seek if possible.