def to_dict(self): return { 'type': type(self).__name__, 'base': to_dict(self.base), 'material': to_dict(self.material), 'fraction': to_dict(self.fraction), }
def to_dict(self): ret = MagneticLayer.to_dict(self) ret['rhoM'] = to_dict(self.rhoM) ret['thetaM'] = to_dict(self.thetaM) ret['interfaceM'] = to_dict(self.interfaceM) ret['weight'] = to_dict(self.weight) return ret
def to_dict(self): result = BaseMagnetism.to_dict(self) result['weight'] = to_dict(self.weight) result['rhoM'] = to_dict(self.rhoM) result['thetaM'] = to_dict(self.thetaM) #result['interfaceM'] = to_dict(self.interfaceM) return result
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'dll_path': self.model._dll_path, 'index': self.index, 'parameters': self.parameters(), })
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'name': self.name, 'rho': self.rho, 'irho': self.irho, })
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'material': self.material, 'profile': self.profile, 'fraction': self.fraction, })
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'name': self.name, 'solvent': self.solvent, 'parts': self.parts, })
def to_dict(self): pars = self.parameters() pars.pop('inflections') # derived parameter not needed for save return to_dict({ 'type': type(self).__name__, 'name': self.name, 'parameters': pars, })
def to_dict(self): ret = self.parameters() ret.update({ 'type': type(self).__name__, 'name': self.name, 'method': self.method, }) return to_dict(ret)
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'name': self.name, 'formula': str(self.formula), 'density': self.density, 'use_incoherent': self.use_incoherent, # TODO: what about fitby, natural_density and cell_volume? })
def to_dict(self): ret = BaseMagnetism.to_dict(self) ret.update( to_dict({ 'profile': self.profile, 'parameters': {k: getattr(self, k) for k in self._parameters}, 'tol': self.tol, }))
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'P': self.P, # Note: use parameter id to restore 'distribution': self.distribution, 'experiment': self.experiment, # Don't need self.probe since it is the experiment probe. 'coherent': self.coherent, })
def to_dict(self): """ Return a dictionary representation of the Stack object """ return to_dict({ 'type': type(self).__name__, 'name': self.name, 'interface': self.interface, 'layers': self._layers, })
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'edges': self.edges.tolist(), 'cdf': self.cdf.__name__, # TODO: can't lookup name 'args': self.args, 'loc': self.loc, 'scale': self.scale, 'truncated': self.truncated, })
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'name': self.name, 'method': self.method, 'thickness': self.thickness, 'vf': self.vf, 'material': self.material, 'solvent': self.solvent, })
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'name': self.name, 'extent': self.extent, 'dead_below': self.dead_below, 'dead_above': self.dead_above, 'interface_below': self.interface_below, 'interface_above': self.interface_above, })
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'name': self.name, 'profile': self.profile, 'thickness': self.thickness, 'interface': self.interface, 'parameters': {k: getattr(self, k) for k in self._parameters}, 'solvent': self.solvent, 'material': self.material, })
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'name': self.name, 'samples': self.samples, 'ratio': self.ratio, 'probe': self.probe, 'parts': self.parts, 'coherent': self.coherent, 'interpolation': self.interpolation, })
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'name': self.name, 'sample': self.sample, 'probe': self.probe, 'roughness_limit': self.roughness_limit, 'dz': self.dz, 'dA': self.dA, 'step_interfaces': self.step_interfaces, 'interpolation': self.interpolation, })
def save_json(self, basename): """ Save the experiment as a json file """ try: experiment = to_dict(self) experiment['refl1d'] = __version__ json_file = basename + "-expt.json" with open(json_file, 'w') as fid: data = json.dumps(experiment) fid.write(data) except Exception: traceback.print_exc() warn("failed to create json structure for model")
def to_dict(self): """ Return a dictionary representation of the Repeat object """ return to_dict({ 'type': type(self).__name__, 'name': self.name, 'interface': self.interface, 'magnetism': self.magnetism, 'repeat': self.repeat, 'stack': self.stack, })
def to_dict(self): """ Return a dictionary representation of the Slab object """ return to_dict({ 'type': type(self).__name__, 'name': self.name, 'thickness': self.thickness, 'interface': self.interface, 'material': self.material, 'magnetism': self.magnetism, })
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'name': self.name, 'thickness': self.thickness, 'interface': self.interface, 'profile': self.profile, 'parameters': {k: getattr(self, k) for k in self._parameters}, 'tol': self.tol, 'magnetism': self.magnetism, })
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'name': self.name, 'base_vf': self.base_vf, 'base': self.base, 'length': self.length, 'power': self.power, 'sigma': self.sigma, 'solvent': self.solvent, 'polymer': self.polymer, })
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'name': self.name, 'profile': self.profile, 'thickness': self.thickness, 'interface': self.interface, 'delta': self.delta, 'vf': self.vf, 'sigma': self.sigma, 'solvent': self.solvent, 'polymer': self.polymer, })
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'name': self.name, 'thickness': self.thickness, 'interface': self.interface, 'chi': self.chi, 'chi_s': self.chi_s, 'h_dry': self.h_dry, 'l_lat': self.l_lat, 'mn': self.mn, 'm_lat': self.m_lat, 'pdi': self.pdi, 'phi_b': self.phi_b, 'solvent': self.solvent, 'polymer': self.polymer, })
def to_dict(self): ret = { 'type': type(self).__name__, } ret.update(to_dict(self.parameters())) return ret
def to_dict(self): ret = MagneticLayer.to_dict(self) ret['rhoM'] = to_dict(self.rhoM) ret['thetaM'] = to_dict(self.thetaM) ret['z'] = to_dict(self.z) return ret
def to_dict(self): result = BaseMagnetism.to_dict(self) result['z'] = to_dict(self.z) result['rhoM'] = to_dict(self.rhoM) result['thetaM'] = to_dict(self.thetaM) return result
def to_dict(self): return to_dict({ 'type': type(self).__name__, 'name': self.name, 'parameters': self.parameters(), })