MCPcopy Create free account
hub / github.com/ciphermodelabs/ciphercore / b2a

Method b2a

ciphercore-base/src/graphs.rs:1076–1078  ·  view source on GitHub ↗

Adds a node to the parent graph converting a binary array associated with the node to an array of a given scalar type. Applies [Graph::b2a] to the parent graph, `this` node and `scalar_type`. # Example ``` # use ciphercore_base::graphs::create_context; # use ciphercore_base::data_types::{BIT, INT32, array_type}; let c = create_context().unwrap(); let g = c.create_graph().unwrap(); let t = array

(&self, scalar_type: ScalarType)

Source from the content-addressed store, hash-verified

1074 /// let n2 = n1.b2a(INT32).unwrap();
1075 /// ```
1076 pub fn b2a(&self, scalar_type: ScalarType) -> Result<Node> {
1077 self.get_graph().b2a(self.clone(), scalar_type)
1078 }
1079
1080 /// Adds a node that extracts an element of a tuple associated with the node.
1081 ///

Callers 15

test_b2a_workerFunction · 0.45
test_b2a_worker_failFunction · 0.45
test_wellformed_casesFunction · 0.45
test_broadcast_divisorFunction · 0.45
test_broadcast_dividendFunction · 0.45
long_division_helperFunction · 0.45
integer_from_bitsFunction · 0.45
instantiateMethod · 0.45
i64_to_i128Function · 0.45
i128_to_i64Function · 0.45

Calls 3

cloneMethod · 0.80
add_nodeMethod · 0.80
get_graphMethod · 0.45

Tested by 9

test_b2a_workerFunction · 0.36
test_b2a_worker_failFunction · 0.36
test_wellformed_casesFunction · 0.36
test_broadcast_divisorFunction · 0.36
test_broadcast_dividendFunction · 0.36
test_b2a_a2bFunction · 0.36
test_a2b_b2aFunction · 0.36