friendlysam.opt.namespace¶
-
friendlysam.opt.
namespace
(name)¶ Prefix variable names.
Examples
>>> with namespace('dimensions'): ... w = Variable('width') ... h = VariableCollection('heights') ... >>> w <friendlysam.opt.Variable at 0x...: dimensions.width> >>> h(3) <friendlysam.opt.Variable at 0x...: dimensions.heights(3)>