Mask RCNN tflite inference on android

System information

OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Ubuntu 16.04
TensorFlow installed from (source or binary): binary
TensorFlow version (or github SHA if from source): nightly

Provide the text output from tflite_convert
WARNING:tensorflow:From /usr/local/lib/python3.6/dist-packages/tensorflow/python/training/tracking/tracking.py:111: Model.state_updates (from tensorflow.python.keras.engine.training) is deprecated and will be removed in a future version.
Instructions for updating:
This property should not be used in TensorFlow 2.0, as updates are applied automatically.
WARNING:tensorflow:From /usr/local/lib/python3.6/dist-packages/tensorflow/python/training/tracking/tracking.py:111: Layer.updates (from tensorflow.python.keras.engine.base_layer) is deprecated and will be removed in a future version.
Instructions for updating:
This property should not be used in TensorFlow 2.0, as updates are applied automatically.
INFO:tensorflow:Assets written to: /tmp/tmpjivs_7gq/assets

Standalone code to reproduce the issue
int imageTensorIndex = 0;
int[] imageShape = tflite.getInputTensor(imageTensorIndex).shape(); // {1, height, width, 3}
imageSizeY = imageShape[1];
imageSizeX = imageShape[2];
DataType imageDataType = tflite.getInputTensor(imageTensorIndex).dataType();
TensorImage inputImageBuffer = new TensorImage(imageDataType);
inputImageBuffer.load(bitmap);
int[] probabilityShape = tflite.getOutputTensor(probabilityTensorIndex).shape(); // {1, NUM_CLASSES}
DataType probabilityDataType = tflite.getOutputTensor(probabilityTensorIndex).dataType();
// Creates the output tensor and its processor.
outputProbabilityBuffer = TensorBuffer.createFixedSize(probabilityShape, probabilityDataType);
tflite.run(inputImageBuffer.getBuffer(), outputProbabilityBuffer.getBuffer().rewind());
Also, please include a link to a GraphDef or the model if possible.
[{'name': 'input_image', 'index': 0, 'shape': array([   1, 1024, 1024,    3], dtype=int32), 'shape_signature': array([  -1, 1024, 1024,    3], dtype=int32), 'dtype': <class 'numpy.float32'>, 'quantization': (0.0, 0), 'quantization_parameters': {'scales': array([], dtype=float32), 'zero_points': array([], dtype=int32), 'quantized_dimension': 0}, 'sparsity_parameters': {}}, {'name': 'input_image_meta', 'index': 1, 'shape': array([ 1, 18], dtype=int32), 'shape_signature': array([-1, 18], dtype=int32), 'dtype': <class 'numpy.float32'>, 'quantization': (0.0, 0), 'quantization_parameters': {'scales': array([], dtype=float32), 'zero_points': array([], dtype=int32), 'quantized_dimension': 0}, 'sparsity_parameters': {}}, {'name': 'input_anchors', 'index': 2, 'shape': array([     1, 261888,      4], dtype=int32), 'shape_signature': array([    -1, 261888,      4], dtype=int32), 'dtype': <class 'numpy.float32'>, 'quantization': (0.0, 0), 'quantization_parameters': {'scales': array([], dtype=float32), 'zero_points': array([], dtype=int32), 'quantized_dimension': 0}, 'sparsity_parameters': {}}]
[{'name': 'Identity', 'index': 662, 'shape': array([1, 1, 1], dtype=int32), 'shape_signature': array([ 1, -1, -1], dtype=int32), 'dtype': <class 'numpy.float32'>, 'quantization': (0.0, 0), 'quantization_parameters': {'scales': array([], dtype=float32), 'zero_points': array([], dtype=int32), 'quantized_dimension': 0}, 'sparsity_parameters': {}}, {'name': 'Identity_1', 'index': 740, 'shape': array([   1, 1000,    6,    4], dtype=int32), 'shape_signature': array([   1, 1000,    6,    4], dtype=int32), 'dtype': <class 'numpy.float32'>, 'quantization': (0.0, 0), 'quantization_parameters': {'scales': array([], dtype=float32), 'zero_points': array([], dtype=int32), 'quantized_dimension': 0}, 'sparsity_parameters': {}}, {'name': 'Identity_2', 'index': 744, 'shape': array([   1, 1000,    6], dtype=int32), 'shape_signature': array([   1, 1000,    6], dtype=int32), 'dtype': <class 'numpy.float32'>, 'quantization': (0.0, 0), 'quantization_parameters': {'scales': array([], dtype=float32), 'zero_points': array([], dtype=int32), 'quantized_dimension': 0}, 'sparsity_parameters': {}}, {'name': 'Identity_3', 'index': 864, 'shape': array([  1, 100,   6], dtype=int32), 'shape_signature': array([  1, 100,   6], dtype=int32), 'dtype': <class 'numpy.float32'>, 'quantization': (0.0, 0), 'quantization_parameters': {'scales': array([], dtype=float32), 'zero_points': array([], dtype=int32), 'quantized_dimension': 0}, 'sparsity_parameters': {}}, {'name': 'Identity_4', 'index': 936, 'shape': array([  1, 100,  28,  28,   6], dtype=int32), 'shape_signature': array([  1, 100,  28,  28,   6], dtype=int32), 'dtype': <class 'numpy.float32'>, 'quantization': (0.0, 0), 'quantization_parameters': {'scales': array([], dtype=float32), 'zero_points': array([], dtype=int32), 'quantized_dimension': 0}, 'sparsity_parameters': {}}, {'name': 'Identity_5', 'index': 578, 'shape': array([1, 1, 4], dtype=int32), 'shape_signature': array([-1, -1,  4], dtype=int32), 'dtype': <class 'numpy.float32'>, 'quantization': (0.0, 0), 'quantization_parameters': {'scales': array([], dtype=float32), 'zero_points': array([], dtype=int32), 'quantized_dimension': 0}, 'sparsity_parameters': {}}, {'name': 'Identity_6', 'index': 591, 'shape': array([1, 1, 2], dtype=int32), 'shape_signature': array([-1, -1,  2], dtype=int32), 'dtype': <class 'numpy.float32'>, 'quantization': (0.0, 0), 'quantization_parameters': {'scales': array([], dtype=float32), 'zero_points': array([], dtype=int32), 'quantized_dimension': 0}, 'sparsity_parameters': {}}]
These are the input and output tensors of the model.
--------- beginning of crash
2020-12-11 17:27:42.138 16752-16752/com.objdetector A/libc: Fatal signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0 in tid 16752 (com.objdetector), pid 16752 (com.objdetector)
This is the segmentation fault error
Include any logs or source code that would be helpful to diagnose the problem.
If including tracebacks, please include the full traceback. Large logs and files
should be attached.
How exactly should I run inference on android for Mask RCNN tflite model? I have added these dependencies:
dependencies {
implementation 'org.tensorflow:tensorflow-lite:0.0.0-nightly'
// This dependency adds the necessary TF op support.
implementation 'org.tensorflow:tensorflow-lite-select-tf-ops:0.0.0-nightly'
}
There seem to be 3 inputs and 7 outputs to the model.. what do i need to pass as input, should I pass image, image_meta as well as input anchors? Which of the outputs will provide the result? Do I need to map all the outputs? How can I get the result?

@MeghaGhosh What is your use-case? If you need bounding boxes, you can check out the SSD models on the TF2 detection zoo Mask-RCNN is not very well supported on TFLite, mainly because the models in the TF1 detection zoo are too large to perform well on-device.

I need Mask RCNN itself.. I need the tflite model to match my h5 model in this use case.. and that cannot be changed from Mask RCNN. What do you mean "not very well" supported? Is it supported though? Even just the bounding box values are enough.. Is it possible to get the output using android interpreter?

@MeghaGhosh Support for the TF1 Mask RCNNmodels in TFlite is pretty limited. That said, feel free to follow the steps in this Github issue to get a TFLite model. Its latency is pretty large (~1-2s), and you will need to change some of the pipeline config params based on which model you are using. Feel free to give it a try :-)
We are also working on CenterNet & EfficientDet support in the TF2 detection zoo for mobile phones, so hopefully we will models with greater mAP soon.

Okay sure I will check that out, thank you. In addition, I did actually get a tflite model from the matterport Mask RCNN model.. i used select tf ops for conversion, python inference did not work but android seems to support select ops from what I've been reading.. what I could use help with is the android inference. Currently facing a segmentation fault issue that I have outlined, would appreciate any direction you could point me in with reference to that.

@MeghaGhosh Could you share the more details on the unsuccessful behavior seen in Python inference? Which computer system, operating system, and TensorFlow version did you use for Python inference?

If the crashing happens on x86 emulator, it's likely the same issue with https://github.com/tensorflow/tensorflow/issues/38025
As a workaround, you need to use download nightly manually.
https://storage.googleapis.com/tensorflow-nightly-public/prod/tensorflow/google3/ubuntu_16/lite/nightly/511/20201214-223707/tensorflow-lite-select-tf-ops.aar
And use it as
compile files('libs/tensorflow-lite-select-tf-ops.aar')

instead of
implementation('org.tensorflow:tensorflow-lite-select-tf-ops:0.0.0-nightly') { changing = true }

So the segmentation fault is actually happening when we create the tflite model with tf-nightly version. When we create the model with tensorflow 2.3.0 we are getting this error:
2020-12-18 16:03:35.209 12244-12244/com.objdetector W/System.err: java.lang.IllegalArgumentException: Internal error: Failed to run on the given Interpreter: tensorflow/lite/kernels/reduce.cc:534 reference_ops::ReduceGeneric( GetTensorData(op_context->input), op_context->input->dims->data, op_context->input->dims->size, GetTensorData(op_context->output), op_context->output->dims->data, op_context->output->dims->size, GetTensorData(op_context->axis), num_axis, op_context->params->keep_dims, GetTensorData(temp_index), GetTensorData(resolved_axis), init_value, reducer) was not true.2020-12-18 16:03:35.209 12244-12244/com.objdetector W/System.err: No2020-12-18 16:03:35.221 12244-12244/com.objdetector W/System.err:     at org.tensorflow.lite.NativeInterpreterWrapper.run(Native Method)2020-12-18 16:03:35.221 12244-12244/com.objdetector W/System.err:     at org.tensorflow.lite.NativeInterpreterWrapper.run(NativeInterpreterWrapper.java:158)2020-12-18 16:03:35.221 12244-12244/com.objdetector W/System.err:     at org.tensorflow.lite.Interpreter.runForMultipleInputsOutputs(Interpreter.java:343)2020-12-18 16:03:35.221 12244-12244/com.objdetector W/System.err:     at com.objdetector.deepmodel.MObjectDetector.detectObjects(MObjectDetector.java:198)2020-12-18 16:03:35.222 12244-12244/com.objdetector W/System.err:     at com.objdetector.MainActivitynew$1.onClick(MainActivitynew.java:69)2020-12-18 16:03:35.222 12244-12244/com.objdetector W/System.err:     at android.view.View.performClick(View.java:6733)2020-12-18 16:03:35.222 12244-12244/com.objdetector W/System.err:     at android.view.View.performClickInternal(View.java:6691)2020-12-18 16:03:35.222 12244-12244/com.objdetector W/System.err:     at android.view.View.access$3400(View.java:802)2020-12-18 16:03:35.222 12244-12244/com.objdetector W/System.err:     at android.view.View$PerformClick.run(View.java:26499)2020-12-18 16:03:35.222 12244-12244/com.objdetector W/System.err:     at android.os.Handler.handleCallback(Handler.java:873)2020-12-18 16:03:35.222 12244-12244/com.objdetector W/System.err:     at android.os.Handler.dispatchMessage(Handler.java:99)2020-12-18 16:03:35.222 12244-12244/com.objdetector W/System.err:     at android.os.Looper.loop(Looper.java:226)2020-12-18 16:03:35.222 12244-12244/com.objdetector W/System.err:     at android.app.ActivityThread.main(ActivityThread.java:7178)2020-12-18 16:03:35.222 12244-12244/com.objdetector W/System.err:     at java.lang.reflect.Method.invoke(Native Method)2020-12-18 16:03:35.222 12244-12244/com.objdetector W/System.err:     at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:503)2020-12-18 16:03:35.223 12244-12244/com.objdetector W/System.err:     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:942)2020-12-18 16:03:35.224 12244-12244/com.objdetector E/Edgar: []2020-12-18 16:03:35.245 12244-12244/com.objdetector E/ANR_LOG: >>> msg's executing time is too long2020-12-18 16:03:35.245 12244-12244/com.objdetector E/ANR_LOG: Blocked msg = { when=-44s561ms what=0 target=android.view.ViewRootImpl$ViewRootHandler callback=android.view.View$PerformClick } , cost  = 44558 ms2020-12-18 16:03:35.245 12244-12244/com.objdetector E/ANR_LOG: >>>Current msg List is:2020-12-18 16:03:35.246 12244-12244/com.objdetector E/ANR_LOG: Current msg <1>  = { when=-44s561ms what=0 target=android.view.ViewRootImpl$ViewRootHandler callback=android.view.View$UnsetPressedState }2020-12-18 16:03:35.246 12244-12244/com.objdetector E/ANR_LOG: >>>CURRENT MSG DUMP OVER<<<2020-12-18 16:03:35.282 12244-12244/com.objdetector I/Choreographer: Skipped 2675 frames!  The application may be doing too much work on its main thread.2020-12-18 16:03:35.355 12244-12244/com.objdetector I/Choreographer: Skipped 3 frames!  The application may be doing too much work on its main thread.2020-12-18 16:03:35.361 12244-12423/com.objdetector I/OpenGLRenderer: Davey! duration=44679ms; Flags=0, IntendedVsync=204496322680101, Vsync=204540920879301, OldestInputEvent=9223372036854775807, NewestInputEvent=0, HandleInputStart=204540928240420, AnimationStart=204540928558343, PerformTraversalsStart=204540930867420, DrawStart=204540931626113, SyncQueued=204540934693343, SyncStart=204540934836959, IssueDrawCommandsStart=204540987101266, SwapBuffers=204540994920651, FrameCompleted=204541002585651, DequeueBufferDuration=553000, QueueBufferDuration=6118000, ReplyForward |   | ReplyForward |   |
-- | -- | -- | -- | --
  | ReplyForward
We have tried 2-3 different versions of code and they all result in the same error - I am sharing all the different versions here:

Generating an image of input tensor size and passing that as input (have tried passing a real image with the same result):

int imageTensorIndex = 0;
int[] imageShape = tfLite.getInputTensor(imageTensorIndex).shape(); // {1, height, width, 3}
int imageSizeY = imageShape[1];
int imageSizeX = imageShape[2];
DataType imageDataType = tfLite.getInputTensor(imageTensorIndex).dataType();
// input tensor
int[] inputshape;
DataType OinputputDataType = null;
HashMap inputProbabilityBuffers = new HashMap<>();
ByteBuffer xc;
for (int k = 0; k < tfLite.getInputTensorCount(); k++) {
inputshape = tfLite.getInputTensor(k).shape();
OinputputDataType = tfLite.getInputTensor(k).dataType();
xc = TensorBuffer.createFixedSize(inputshape, OinputputDataType).getBuffer();
inputProbabilityBuffers.put(k, xc);
}
TensorImage inputImageBuffer = new TensorImage(OinputputDataType);
inputImageBuffer.load(generateImage());
int[] OutputShape;
DataType OutputDataType;
HashMap outputProbabilityBuffers = new HashMap<>();
ByteBuffer x;
for (int i = 0; i < tfLite.getOutputTensorCount(); i++) {
OutputShape = tfLite.getOutputTensor(i).shape();
OutputDataType = tfLite.getOutputTensor(i).dataType();
x = TensorBuffer.createFixedSize(OutputShape, OutputDataType).getBuffer();
outputProbabilityBuffers.put(i, x);
}
Object[] Inputs = {inputImageBuffer.getBuffer()};
try {
tfLite.runForMultipleInputsOutputs(Inputs, outputProbabilityBuffers);
} catch (Exception e){
e.printStackTrace();
}

Passing random float values into all 3 input tensors and sending those to the model:

int imageTensorIndex = 0;
int[] imageShape = tfLite.getInputTensor(imageTensorIndex).shape(); // {1, height, width, 3}
int imageSizeY = imageShape[1];
int imageSizeX = imageShape[2];
DataType imageDataType = tfLite.getInputTensor(imageTensorIndex).dataType();
// input tensor
int[] inputshape;
DataType OinputputDataType = null;
HashMap inputProbabilityBuffers = new HashMap<>();
ByteBuffer xc;
Object[] input = new Object[3];
for (int k = 0; k < tfLite.getInputTensorCount(); k++) {
inputshape = tfLite.getInputTensor(k).shape();
Log.e("Edgar",""+ inputshape.toString());
  OinputputDataType = tfLite.getInputTensor(k).dataType();
  xc = TensorBuffer.createFixedSize(inputshape, OinputputDataType).getBuffer();
  inputProbabilityBuffers.put(k, xc);

  ByteBuffer temp = ByteBuffer.allocateDirect(xc.limit()); // Allocate with size of float
  temp.putFloat(inputshape[k]); // May be an array containing actual values
  input[k] = temp;

}
TensorImage inputImageBuffer = new TensorImage(OinputputDataType);
inputImageBuffer.load(generateImage());
int[] OutputShape;
DataType OutputDataType;
HashMap outputProbabilityBuffers = new HashMap<>();
ByteBuffer x;
for (int i = 0; i < tfLite.getOutputTensorCount(); i++) {
OutputShape = tfLite.getOutputTensor(i).shape();
OutputDataType = tfLite.getOutputTensor(i).dataType();
x = TensorBuffer.createFixedSize(OutputShape, OutputDataType).getBuffer();
outputProbabilityBuffers.put(i, x);
}
try {
tfLite.runForMultipleInputsOutputs(input, outputProbabilityBuffers);
  Log.e("Edgar", "" + outputProbabilityBuffers.toString());

} catch (Exception e){
e.printStackTrace();
}

Creating empty buffers for inputs and passing those:

int[] inputshape;
DataType OinputputDataType;
Object inputs[] = new Object[tfLite.getInputTensorCount()];
for (int i=0; i < tfLite.getInputTensorCount(); i++) {
inputshape = tfLite.getInputTensor(k).shape();
OinputputDataType = tfLite.getInputTensor(k).dataType();
xc = TensorBuffer.createFixedSize(inputshape, OinputputDataType).getBuffer();
inputProbabilityBuffers.put(k, xc);
ByteBuffer i_bytes = ByteBuffer.allocate(xc);
inputs[i] = i_bytes;
}
int[] OutputShape;
DataType OutputDataType;
HashMap outputProbabilityBuffers = new HashMap<>();
ByteBuffer x;
for (int i = 0; i < tfLite.getOutputTensorCount(); i++) {
OutputShape = tfLite.getOutputTensor(i).shape();
OutputDataType = tfLite.getOutputTensor(i).dataType();
x = TensorBuffer.createFixedSize(OutputShape, OutputDataType).getBuffer();
outputProbabilityBuffers.put(i, x);
}
interpreter.runForMultipleInputsOutputs(inputs, outputProbabilityBuffers);
They all result in above error. This is my model file (it is the converted tflite model from mask rcnn coco weights file):
https://drive.google.com/file/d/1gGjMK_YyyHuOqyZytsoh5sJ9jSPSxn7J/view
This is the implementation while building gradle:
assert file(project.ext.ASSET_DIR + "/model.tflite").exists()
assert file(project.ext.ASSET_DIR + "/mod.txt").exists()
apply plugin: 'com.android.application'
android {
compileSdkVersion 29
buildToolsVersion "29.0.2"
defaultConfig {
applicationId "com.objdetector"
minSdkVersion 23
targetSdkVersion 29
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
ndk{
abiFilters  'armeabi-v7a',  'arm64-v8a'
}
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
compileOptions {
    sourceCompatibility JavaVersion.VERSION_1_8
    targetCompatibility JavaVersion.VERSION_1_8
}

dependencies {
    implementation 'org.tensorflow:tensorflow-android:1.6.0'
}

aaptOptions {
    noCompress "tflite"
}

sourceSets { main { assets.srcDirs = ['src/main/assets', 'src/main/assets/'] } }

}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'androidx.appcompat:appcompat:1.2.0'
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
//    implementation 'org.tensorflow:tensorflow-lite:2.3.0'
implementation 'org.tensorflow:tensorflow-lite:0.0.0-nightly'
implementation 'org.tensorflow:tensorflow-lite-select-tf-ops:0.0.0-nightly'
implementation 'org.tensorflow:tensorflow-lite-support:0.0.0-nightly'
}
What are we missing? Is there some other way we need to pass the input values?

@MeghaGhosh I confirmed that your shared model, which is included in the above comment, was able to run with the benchmark_model_plus_flex tool. Looks like the model itself is runnable.
Could you follow the @terryheo 's comment with the shared model?

Yes, we are using the nightly aar files. Still facing the same issue:
2020-12-22 17:10:08.127 16299-16299/com.objdetector W/System.err: java.lang.IllegalArgumentException: Internal error: Failed to run on the given Interpreter: tensorflow/lite/kernels/reduce.cc:534 reference_ops::ReduceGeneric( GetTensorData(op_context->input), op_context->input->dims->data, op_context->input->dims->size, GetTensorData(op_context->output), op_context->output->dims->data, op_context->output->dims->size, GetTensorData(op_context->axis), num_axis, op_context->params->keep_dims, GetTensorData(temp_index), GetTensorData(resolved_axis), init_value, reducer) was not true.

@MeghaGhosh there are possibility that model won't work when the given input shape is not compatible with the model. Could you make sure that the input shapes being used meet input constraints?

Hi @abattery yes we are taking the input shapes from the model itself and filling the object, the size of our object matches that expected by the model. This is our latest attempt, could you let us know if we're missing something?
int imageTensorIndex = 0;
int[] imageShape = tfLite.getInputTensor(imageTensorIndex).shape(); // {1, height, width, 3}
int imageSizeY = imageShape[1];
int imageSizeX = imageShape[2];
DataType imageDataType = tfLite.getInputTensor(imageTensorIndex).dataType();
// input tensor
int[] inputshape;
DataType OinputputDataType = null;
HashMap inputProbabilityBuffers = new HashMap<>();
ByteBuffer xc;
Object[] input = new Object[3];
for (int k = 0; k < tfLite.getInputTensorCount(); k++) {
inputshape = tfLite.getInputTensor(k).shape();
OinputputDataType = tfLite.getInputTensor(k).dataType();
xc = TensorBuffer.createFixedSize(inputshape, OinputputDataType).getBuffer();
inputProbabilityBuffers.put(k, xc);
ByteBuffer temp = ByteBuffer.allocateDirect(xc.limit()); // Allocate with size of float
int[] shape = tfLite.getInputTensor(k).shape();
        int na = xc.limit()/4;
        for (int a = 0; a <na; a++) {
           // temp.put(randomno);
            temp.putFloat(0);
           // temp.put(randomno);
        }
        input[k] = temp;

//            String stringShape = "";
//            for(int j = 0; j < shape.length; j++) {
//                stringShape = stringShape + ", " + shape[j];
//            }
Log.e("Edgar", "Shape of input tensor " + ": " + Arrays.toString(input));
tfLite.resizeInput(k, inputshape);
}
int[] OutputShape;
DataType OutputDataType;
HashMap outputProbabilityBuffers = new HashMap<>();
ByteBuffer x;
for (int i = 0; i < tfLite.getOutputTensorCount(); i++) {
OutputShape = tfLite.getOutputTensor(i).shape();
OutputDataType = tfLite.getOutputTensor(i).dataType();
x = TensorBuffer.createFixedSize(OutputShape, OutputDataType).getBuffer();
outputProbabilityBuffers.put(i, x);
}
try {
tfLite.runForMultipleInputsOutputs(input, outputProbabilityBuffers);
Log.e("Edgar", "" + outputProbabilityBuffers.toString());
} catch (Exception e){
e.printStackTrace();
}
Shape of input tensor : [java.nio.DirectByteBuffer[pos=12582912 lim=12582912 cap=12582912], java.nio.DirectByteBuffer[pos=372 lim=372 cap=372], java.nio.DirectByteBuffer[pos=4190208 lim=4190208 cap=4190208]]
6:42

Could you share your input shape sizes? I would make sure that the benchmark tool can reproduce the problem with those sizes or not.

Thanks! These are the input shape sizes:
[1, 1024, 1024, 3]
[1, 93]
[1, 261888, 4]

The benchmark tool on the desktop works well with the model and the above input shapes.
@MeghaGhosh Can you share which version of aar files you are using?
@thaink could you take a look at this issue?

I'm using the aar file from the link shared in @terryheo 's comment.
https://storage.googleapis.com/tensorflow-nightly-public/prod/tensorflow/google3/ubuntu_16/lite/nightly/511/20201214-223707/tensorflow-lite-select-tf-ops.aar

@MeghaGhosh could you try the same version of tensorflow-lite.aar as well?
https://storage.googleapis.com/tensorflow-nightly-public/prod/tensorflow/google3/ubuntu_16/lite/nightly/511/20201214-223707/tensorflow-lite.aar

Yes we've been trying this, however this is leading to us not being able to use tensorflow-lite-support.
These implementations are leading to this error:
implementation 'org.tensorflow:tensorflow-lite-support:0.0.0-nightly'
compile files ('libs/tensorflow-lite-select-tf-ops.aar')
compile files ('libs/tensorflow-lite.aar')
Duplicate class org.tensorflow.lite.DataType found in modules jetified-tensorflow-lite-0.0.0-nightly-runtime.jar (org.tensorflow:tensorflow-lite:0.0.0-nightly) and jetified-tensorflow-lite-runtime.jar (tensorflow-lite.aar)
Duplicate class org.tensorflow.lite.DataType$1 found in modules jetified-tensorflow-lite-0.0.0-nightly-runtime.jar (org.tensorflow:tensorflow-lite:0.0.0-nightly) and jetified-tensorflow-lite-runtime.jar (tensorflow-lite.aar)
Duplicate class org.tensorflow.lite.Delegate found in modules jetified-tensorflow-lite-0.0.0-nightly-runtime.jar (org.tensorflow:tensorflow-lite:0.0.0-nightly) and jetified-tensorflow-lite-runtime.jar (tensorflow-lite.aar)
Duplicate class org.tensorflow.lite.Interpreter found in modules jetified-tensorflow-lite-0.0.0-nightly-runtime.jar (org.tensorflow:tensorflow-lite:0.0.0-nightly) and jetified-tensorflow-lite-runtime.jar (tensorflow-lite.aar)
Duplicate class org.tensorflow.lite.Interpreter$Options found in modules jetified-tensorflow-lite-0.0.0-nightly-runtime.jar (org.tensorflow:tensorflow-lite:0.0.0-nightly) and jetified-tensorflow-lite-runtime.jar (tensorflow-lite.aar)
Duplicate class org.tensorflow.lite.NativeInterpreterWrapper found in modules jetified-tensorflow-lite-0.0.0-nightly-runtime.jar (org.tensorflow:tensorflow-lite:0.0.0-nightly) and jetified-tensorflow-lite-runtime.jar (tensorflow-lite.aar)
Duplicate class org.tensorflow.lite.Tensor found in modules jetified-tensorflow-lite-0.0.0-nightly-runtime.jar (org.tensorflow:tensorflow-lite:0.0.0-nightly) and jetified-tensorflow-lite-runtime.jar (tensorflow-lite.aar)
Duplicate class org.tensorflow.lite.Tensor$QuantizationParams found in modules jetified-tensorflow-lite-0.0.0-nightly-runtime.jar (org.tensorflow:tensorflow-lite:0.0.0-nightly) and jetified-tensorflow-lite-runtime.jar (tensorflow-lite.aar)
Duplicate class org.tensorflow.lite.TensorFlowLite found in modules jetified-tensorflow-lite-0.0.0-nightly-runtime.jar (org.tensorflow:tensorflow-lite:0.0.0-nightly) and jetified-tensorflow-lite-runtime.jar (tensorflow-lite.aar)
Duplicate class org.tensorflow.lite.annotations.UsedByReflection found in modules jetified-tensorflow-lite-0.0.0-nightly-runtime.jar (org.tensorflow:tensorflow-lite:0.0.0-nightly) and jetified-tensorflow-lite-runtime.jar (tensorflow-lite.aar)
Duplicate class org.tensorflow.lite.nnapi.NnApiDelegate found in modules jetified-tensorflow-lite-0.0.0-nightly-runtime.jar (org.tensorflow:tensorflow-lite:0.0.0-nightly) and jetified-tensorflow-lite-runtime.jar (tensorflow-lite.aar)
Duplicate class org.tensorflow.lite.nnapi.NnApiDelegate$Options found in modules jetified-tensorflow-lite-0.0.0-nightly-runtime.jar (org.tensorflow:tensorflow-lite:0.0.0-nightly) and jetified-tensorflow-lite-runtime.jar (tensorflow-lite.aar)
Go to the documentation to learn how to Fix dependency resolution errors.
This is solved as we remove implementation 'org.tensorflow:tensorflow-lite-support:0.0.0-nightly', however then we can't use the support functions such as TensorBuffer.
How can we work around this?

Hey thanks for all the support, we could run the model on android with the following code:
Object[] inputs = new Object[] {new float[1][1024][1024][3], new float[1][93], new float[1][261888][4]};
Map<Integer, Object> outputs = new HashMap<>();
outputs.put(0, new float[1][1000][4]);
outputs.put(1, new float[1][1000][6][4]);
outputs.put(2, new float[1][1000][6]);
outputs.put(3, new float[1][100][6]);
outputs.put(4, new float[1][100][28][28][6]);
outputs.put(5, new float[1][261888][4]);
outputs.put(6, new float[1][261888][2]);
try {
tfLite.runForMultipleInputsOutputs(inputs, outputs);
} catch (Exception e){
e.printStackTrace();
}
The output tensor shapes returned by "tflite.GetOutputTensor" did not match 3 of the output shapes given here..

Also, it's taking about 52 seconds to run (without GPU), is it taking the same amount of time on the benchmark tool as well?

I read through the discussion. Thanks for the information and learned.
Could I know how the performance of running Mask RCNN tflite on android (such as inference time)? Is any successful examples and demo codes?
I successfully converted my trained Mask RCNN model to a tflite model, but still didn't get how to run it on Android by using Java codes.
Thanks

I read through the discussion. Thanks for the information and learned.
Could I know how the performance of running Mask RCNN tflite on android (such as inference time)? Is any successful examples and demo codes?
I successfully converted my trained Mask RCNN model to a tflite model, but still didn't get how to run it on Android by using Java codes.
Thanks

I've the same issue.

I used same config for Mask_RCNN from samples --> Balloon.
Trained model on custom dataset.
Successfully converted model from .h5(255.9MB) to .tflite(65.8MB), using this article.
Simple pass .tflite file to label_image.py for inference check.

After running this file, I also checked activity monitor to look at resources, it's taking ~90% CPU usage, but after 2/3 minutes, I got an error like this,
zsh: segmentation fault  python label_image.py
Didn't know, what's the problem, because I didn't even modify any code.
Config:
TF-2.4.0 on MacOs 10.15 using conda (CPU only)

I've the same issue.

I used same config for Mask_RCNN from samples --> Balloon.
Trained model on custom dataset.
Successfully converted model from .h5(255.9MB) to .tflite(65.8MB), using this article.
Simple pass .tflite file to label_image.py for inference check.

After running this file, I also checked activity monitor to look at resources, it's taking ~90% CPU usage, but after 2/3 minutes, I got an error like this,
zsh: segmentation fault  python label_image.py
Didn't know, what's the problem, because I didn't even modify any code.
Config:
TF-2.4.0 on MacOs 10.15 using conda (CPU only)

Hey @abattery @terryheo I am facing issues inferencing the code and getting the output in android.
I have populated all the input values - image, image meta and anchors , however the outputs are not as expected at all. I have shared the codes here.
https://github.com/tensorflow/tensorflow/issues/46951
Any help will be much appreciated!!

Hi,
Thank you for opening this issue. Since this issue has been open for a long time, the code/debug information for this issue may not be relevant with the current state of the code base.
The TFLite team is constantly improving the framework by fixing bugs and adding new features. We suggest you try the latest TensorFlow version with the latest compatible hardware configuration which could potentially resolve the issue. If you are still facing the issue, please create a new GitHub issue with your latest findings, with all the debugging information which could help us investigate.
Please follow the release notes to stay up to date with the latest developments which are happening in the TFLite space.
Thanks.


fix: wrong subprotocol of subscriptions-transport-ws

Subprotocol of subscriptions-transport-ws is graphql-ws.

Protocol
SubProtocol

graphql-ws
graphql-transport-ws

subscriptions-transport-ws
graphql-ws

https://github.com/apollographql/subscriptions-transport-ws/blob/05a828f4ce9164df61cc0a08ab225556fc035801/src/protocol.ts#L1
https://github.com/apollographql/apollo-kotlin/blob/ac10257283e1196c3feb0d8f1a3b5d9476ad681a/apollo-runtime/src/commonMain/kotlin/com/apollographql/apollo3/network/ws/SubscriptionWsProtocol.kt#L83
https://github.com/apollographql/apollo-kotlin/blob/ac10257283e1196c3feb0d8f1a3b5d9476ad681a/apollo-runtime/src/commonMain/kotlin/com/apollographql/apollo3/network/ws/SubscriptionWsProtocol.kt#L83

@amondnet Please sign the Contributor License Agreement!
Click here to manually synchronize the status of this Pull Request.
See the FAQ for frequently asked questions.

@amondnet Thank you for signing the Contributor License Agreement!


don't crash on invalid sizeof()

Thanks to @byter09 for the fuzzing.

Codecov Report

Merging #245 into master will increase coverage by 0.14%.
The diff coverage is 88.88%.

@@            Coverage Diff             @@
##           master     #245      +/-   ##
==========================================
+ Coverage   77.28%   77.42%   +0.14%
==========================================
  Files          25       25
  Lines        6093     6105      +12
==========================================
+ Hits         4709     4727      +18
+ Misses       1384     1378       -6

Impacted Files
Coverage Δ

src/parse/decl.rs
83.37% <88.88%> (+0.08%)
:arrow_up:

src/parse/expr.rs
78.67% <0%> (+0.51%)
:arrow_up:

src/data/types.rs
83.83% <0%> (+0.59%)
:arrow_up:

src/arch/mod.rs
85.8% <0%> (+0.64%)
:arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1f6351b...e916830. Read the comment docs.


Upgrade Spring Boot and other dependencies

Spring Boot to 1.3.7 and some of the others should be upgraded as well

@davsclaus think that's covered with https://github.com/fabric8io/spring-cloud-kubernetes/pull/47 ?

looks good, lets close


Alpaca API: new error

Hello, I resolved the last error I was receiving, but now there is a new error:
"Error getting cash balance from brokerage: One or more errors occurred.One or more errors occurred. 404 (Not Found)"
 20200320 12:48:20.264 Trace:: BrokerageSetupHandler.Setup(): Connecting to brokerage... 20200320 12:48:20.264 Trace:: BrokerageSetupHandler.Setup(): Fetching cash balance from brokerage... 20200320 12:48:20.737 ERROR:: BrokerageSetupHandler.Setup():  System.AggregateException: One or more errors occurred. ---> System.Net.Http.HttpRequestException: 404 (Not Found)   at System.Net.Http.HttpResponseMessage.EnsureSuccessStatusCode () [0x0002a] in <1c53c629668a4fa589e64e7ceab6f656>:0    at QuantConnect.Brokerages.Alpaca.Markets.RateThrottler.CheckHttpResponse (System.Net.Http.HttpResponseMessage response) [0x00104] in <3f32de85a6c84c5c82550d18302f3b1f>:0    at QuantConnect.Brokerages.Alpaca.Markets.RestClient+<getSingleObjectAsync>d__112[TApi,TJson].MoveNext () [0x0013c] in <3f32de85a6c84c5c82550d18302f3b1f>:0
--- End of inner exception stack trace ---
at QuantConnect.Brokerages.Alpaca.Markets.RestClient+d__112[TApi,TJson].MoveNext () [0x002fc] in <3f32de85a6c84c5c82550d18302f3b1f>:0  --- End of stack trace from previous location where exception was thrown ---   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess (System.Threading.Tasks.Task task) [0x0003e] in <b0e1ad7573a24fd5a9f2af9595e677e7>:0    at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification (System.Threading.Tasks.Task task) [0x00028] in <b0e1ad7573a24fd5a9f2af9595e677e7>:0    at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd (System.Threading.Tasks.Task task) [0x00008] in <b0e1ad7573a24fd5a9f2af9595e677e7>:0    at System.Runtime.CompilerServices.ConfiguredTaskAwaitable1+ConfiguredTaskAwaiter[TResult].GetResult () [0x00000] in :0
at QuantConnect.Extensions.SynchronouslyAwaitTaskResult[TResult] (System.Threading.Tasks.Task1[TResult] task) [0x00011] in <2e1cc499eccd4ebdad9a761c1cc57fa2>:0    at QuantConnect.Brokerages.Alpaca.AlpacaBrokerage.GetCashBalance () [0x00014] in <3f32de85a6c84c5c82550d18302f3b1f>:0    at QuantConnect.Lean.Engine.Setup.BrokerageSetupHandler.Setup (QuantConnect.Lean.Engine.Setup.SetupHandlerParameters parameters) [0x001f4] in <3834b32b23ea4b6a9ac55b1639c19be7>:0  ---> (Inner Exception #0) System.Net.Http.HttpRequestException: 404 (Not Found)   at System.Net.Http.HttpResponseMessage.EnsureSuccessStatusCode () [0x0002a] in <1c53c629668a4fa589e64e7ceab6f656>:0    at QuantConnect.Brokerages.Alpaca.Markets.RateThrottler.CheckHttpResponse (System.Net.Http.HttpResponseMessage response) [0x00104] in <3f32de85a6c84c5c82550d18302f3b1f>:0    at QuantConnect.Brokerages.Alpaca.Markets.RestClient+<getSingleObjectAsync>d__112[TApi,TJson].MoveNext () [0x0013c] in <3f32de85a6c84c5c82550d18302f3b1f>:0 <---
20200320 12:48:20.744 ERROR:: FitnessScore.Initialize(): fitness score will not be calculated because the algorithms starting portfolio value is 0.
20200320 12:48:20.757 ERROR:: LiveTradingResultHandler.Update(): Algorithm not yet initialized.
20200320 12:48:21.359 ERROR:: Engine.Run(): During the algorithm initialization, the following exception has occurred: Error getting cash balance from brokerage: One or more errors occurred.One or more errors occurred. 404 (Not Found)`

nope, not a bug


App crashed due to high memory consumption

Hello there.
I have a chart based "List" view in my app(a SPA), where I am fetching 10000 data points( each record/point is a complex object ) at once. The component takes a few seconds, I guess, but the data is loaded in the view. But after refreshing( 'refresh' button in the List component ) the view quite some times and/or after loading the same resource for different parameters frequently, the app crashes, evidently due to memory issue.
Taking note of the memory using the task manager, while testing the above fact, it was found that memory kept on increasing until the app was crashed.
Any ideas/directions/suggestions on how to resolve it !?!

Use pagination ;)

@fzaninotto Thanks for the suggestion, but I am already done with the pagination as the specs are to make all the points appear in the same view. Do you think there can be any optimization done at core-level ??

Sure, write your own <Datagrid> based on one of the gazillion React Infinite Grid components.

@fzaninotto Hey thanks for that link. Also, do you think my issue could be related with the redux store ?

No idea, you should profile your code to know.

This might help you: https://marmelab.com/blog/2017/02/06/react-is-slow-react-is-fast.html


fix(curriculum): update music player step 16 description

Checklist:

[X] I have read and followed the contribution guidelines.
[X] I have read and followed the how to open a pull request guide.
[X] My pull request targets the main branch of freeCodeCamp.
[X] I have tested these changes either locally on my machine, or GitPod.

Closes #53679

Updated Description per issue instructions

Hi @sabrina-herrera !
I went ahead and apporved your other PR.
Since this is another first timers only issue it is best to keep it open for another new contributer.
I am going to close this PR
If you are interested in contributing more, then you can look at help wanted issue 👍


Implement 3D skybox

Please discuss the feature ideas on Gitter first. Then please describe the feature
A skybox that can be set around the level using images provided by developers.
Additional context (optional)
FXyz has an implementation. Check if can be adapted. If not, reimplement in FXGL context.

Done in FXGL 17


[FLINK-25678][runtime] Make TaskExecutorStateChangelogStoragesManager.shutdown thread-safe

What is the purpose of the change
The method is called from the shutdown hook and must be thread-safe.
Verifying this change
The change is relateively simple and related to concurrency so covering it doesn't seem worth the effort.
Does this pull request potentially affect one of the following parts:

Dependencies (does it add or upgrade a dependency): no
The public API, i.e., is any changed class annotated with @Public(Evolving): no
The serializers: no
The runtime per-record code paths (performance sensitive): no
Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Kubernetes/Yarn/Mesos, ZooKeeper: no
The S3 file system connector: no

Documentation

Does this pull request introduce a new feature? no
If yes, how is the feature documented? no

Thanks for the PR! Overall it looks good to me. Would you mind removing the "No thread-safe" from the java doc of this class? Thanks.

Thanks for the reivew! I'll squash the commits and merge the PR.


Canada Object is not running _populate_government_holidays

When querying Canadian holidays, the method _populate_government_holidays is not called. Probably even other methods from Canada

Hey @AntonioVentilii,
did you specify you wanted the GOVERNMENT category holidays to be included? The default one is PUBLIC.
If so, please share some code examples to reproduce the issue.
Thank you!

Hi @arkid15r ! Tks for the answer!
Actually, I did not specify it, I imagined all of them would appear if I do a generic search. For example, the Reconciliation Day should appear (30th september 2023, obs. 2nd october 2023), but it doesn't.
import holidays

ca_holidays = holidays.country_holidays('Canada', observed=True, years=[2023])

print(ca_holidays)

Hey Antonio,
currently CA holidays implementation adds that holiday for either GOVERNMENT category or multiple subdivisions that recognize the holiday. The default CA holidays set does not include "National Day for Truth and Reconciliation" related holidays.
This would work, though:
holidays.country_holidays('Canada', years=2023, categories=(holidays.GOVERNMENT,))
holidays.country_holidays('Canada', years=2023, subdiv="BC")

Please also note we have sort of related discussion here - https://github.com/vacanza/python-holidays/issues/1492

Understood! Thank you for the answer!
I will close the issue


Removing slack mention from Readme

Short Description:

Remove mention of Slack from the README and also changed topic on Slack channel to direct people to Discord for better communication.
Added myself to contributors.

👍


Gossip protocol

Implement the go-libp2p Gossip protocol in the current node example.

Can you describe your proposed protocol at the moment?

This is a long-standing issue which will be used for discussions about the code in the issue-12/gossip-protocol branch.
The idea of the issue, is to implement something similar to go-libp2p Gossip protocol for our pubsub implementation.
Current plan:

[x] - implement basic node design
[x] - make it modular and easily extendable
[ ] - implement data marshaling using the @fare's type descriptors
[ ] - implement basic pubsub functionality

The plan will be modified as needed during the development and subsequent discussions.


Proposed CHANGELOG.md file

Purpose

New CHANGELOG.md file format to help provide history of significant changes for users / devs

Why a CHANGELOG when you have packaged releases? Packaging systems come and go, but a changelog is for the long-term.
Suggested update strategy is: https://semver.org whenever committed to main branch

Leveraging https://keepachangelog.com/en/1.0.0/ format
⚠ NOTE: this is a DRAFT pull request, please commit to this PR branch with your existing release information to the changelog before merging

Proposed Changes

[ADD] CHANGELOG.md file with sample content

Testing

For live example, see: https://github.com/olivierlacan/keep-a-changelog/blob/main/CHANGELOG.md

After talking to @jjacob7734 - this PR is not necessary since this repo is strictly for storing issues, not any code.

I believe this was accidentally closed. Reopening.


Feature/r13 prompter tyholt

What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)
Feature that adds support for using devices like the Contour Shuttle and Xkeys with jog/shuttle inputs as prompter controllers. This implementation uses keyboard (ascii) inputs from the devices just like a normal keyboard, hence operating like a normal keyboard and can easily be controlled the same way from any device that outputs the same set of shortcuts.

A list of shortcuts are added to the readme. Also the new usage of the mode-setting has it's new changes documented.

What is the current behavior? (You can also link to an open issue here)

What is the new behavior (if this is a feature change)?

Other information:

@jesperstarkar I've added these changes:

Changed name of "mode" parameter to "controlmode"
Added "new" parameter "mode" to switch which devices to use
Updated docs

See https://github.com/nrkno/tv-automation-server-core/tree/feature/r13-prompter-tyholt#operating-the-prompter-screen
Could you have a go and see that it still works as intended?


DCOS-43348: create a design token distribution

I'm using style-dictionary to create a distribution of design tokens (design attributes that can be expressed in a key-value pair).
As a proof-of-concept, I've updated color.stories.ts to use design tokens.

@GeorgiSTodorov - the tokens should be usable in dcos-ui. The style utilities will require us to set up Emotion in dcos-ui

@mperrotti Please look into file conflict so that we can review.

:tada: This PR is included in version 1.17.0 :tada:
The release is available on:

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


Sticky user preference for default template language on examples

Code already in place for this but needs a bit of stress testing.
Deploy preview here: https://edge-syntax--11ty.netlify.app/docs/layouts/
This issue is for feedback!

Sounds good! Is there a bit of dark mode styling missing?

Also, at first I expected just picking a tab to set my preference to that language, it took me two refreshes before I thought to look in the footer.

I'm not a keyboard user so this doesn't affect me directly, but the only (mildly) annoying thing I noticed is that the form auto-submits on selection, meaning that as soon as you navigate the radio group with arrow keys, the page refreshes and you have to tab back again to get to the menu if you wanted to pick a different language.

+1 for a submit button - I think it'd be a WCAG 3.2.2 failure without one.

This is all great feedback, thanks!
The submit button is only hidden when the form-autosubmit plugin is enabled. If you turn off JS you’ll see it

Had to roll this one back—hit a small edge case and am waiting on an infrastructure change to drop before we can use this on 11ty.dev!
We’ll try again later!

This is kinda why I added the contextual dropdown (to supplement the one in the footer)

Oh I like that idea, I think that adds more of a distinction. Changing tab is a one time switch, whereas the drop-down is for setting a preference for the future.

This shipped today and is live!


Version Overview Cannot Be Displayed

OpenUI5 version:

FAIL: 1.57.0-SNAPSHOT
OK: 1.54.7 (current stable)

URL (minimal example if possible):
https://openui5nightly.hana.ondemand.com/versionoverview.html
Steps to reproduce the problem:

Open the above mentioned page

What happens?
An error dialog pops up.

Error while loading json file. Status code 200

Even though the file versionoverview.json could be successfully retrieved, the application does not display the content at all.
Any other information? (attach screenshot if possible)

Hi,
It's tracked internally:<PHONE_NUMBER>.
Regards,
Alex

Hello @boghyon and thank you for reporting this.
There is an error in the JSON file which feeds this page that I fixed today. Unfortunately, it will only be available with the next patch 1.56.6 on openui5.hana.ondemand.com (will be produced in two weeks). Until then, the versionoverview will fail with a parse error.
As a workaround, you can see the data for SAPUI5 (is identical except for release 1.38 EOL):
https://sapui5.hana.ondemand.com/versionoverview.html
Or in the json file directly:
https://openui5.hana.ondemand.com/versionoverview.json
On openui5nightly you should be able to see it starting tomorrow, as the fix will be available there with our next nightly build:
http://openui5nightly.hana.ondemand.com/versionoverview.html
Have a great weekend!
Michael!


SW3: Tweak lattice colors and sizes

Wad Wizard — Today at 2:51 AM

I think the real weakpoint in some of these is the text

osmium — Today at 2:55 AM

i think the issue is that currently the lattice feels more visually prominent than the text when it should be the reverse; swapping the lattice and text colours would probably work well, as well as making the text smaller

osmium — Today at 2:55 AM

[...] i think this is an easy fix?
although maybe the lattice should be something stronger than that shade of purple which "pops" more, like some kind of strong blue eg #2222FF

Wad Wizard — Today at 2:59 AM

If [the text] is on top wouldnt that obscure the diagram
Unless you make the node big enough to put the number in

osmium — Today at 3:00 AM

the node doesnt actrually need to be visible at all. it's the lines that are important

Scott Dakota — Today at 8:29 PM

feature request, hopefully simple:
either set the "extra edges" connector lines to 50% grey (which will have contrast with both light view and dark view)
or add a small checkbox for grey
or add a small checkbox for color picker


Exhaustive list of generalized Build API/CRD attributes

The goal of the Build API is to be able to support:

strongly typed 'popular' attributes that can be used to drive builds with different strategies.
loosely typed not-so-popular name/value pairs in Build API's spec.parameters that would be used to express build steps in the BuildStrategy object definition.

As an exploration, we should enhance the Build API to have the common/popular strongly typed API attributes. Example,

args
runtime Image, path maps : tracked in https://github.com/redhat-developer/build/issues/183
...
Anything else you think we need to include?

Opening this issue to crowdsource suggestions on Build API enhancements.

https://skaffold.dev/docs/references/yaml/
Even though the API objectives are different, the API sheds light on key attributes for popular strategies.

Hi @sbose78 ,
I have a basic question. :)
Where this Build API can be used? Will it just be used in OpenShift, or we can publish it for all kinds of kube platform?
Access from the kube api?

By Build API , I mean the Build CRD.
And as per the project's promise, it's Kubernetes-native :)

@sbose78 thanks for the issue. Im trying to get this idea first, compared to how tekton tasks manage the spec.params  see https://github.com/tektoncd/pipeline/blob/master/docs/tasks.md#specifying-parameters , how is it different to the spec.parameters of the Build? Is there any overlap?

It's kinda similar in idea, but in case of Build it's more of a loosely typed way to define parameterized values.
Imagine a build strategy which needs user input which isn't part of a strongly typed attribute in the BUILD CRD.
In that case, user could define it in params, and expect the build to pick it up and do the necessary replacement in the BuildStrategy for $(build.spec.params.something).
I'll add an example to show it

@sbose78 I think I get the idea. Do we need to also layout specific PARAMs we know all strategies share?

If there are specific params which all build strategies share in a non-optional way, then that param should most likely be a strongly typed API attribute.


LAB_AK_03_Lab3_Ex2_Implement_Identity_Synch.md/Task 1/Step 9

Lab/Demo: 03
Exercise: 02
Task: 01
Step: 09
In the list of requirements presented in step 9, the option 1 requirement needs to be eliminated which states "I have a single or multiple connected forests that I need to sync users and groups from." since it is not available within the user interface (UI).

Thank you for bringing this change to our attention. We removed the step to select the "I have a single or multiple connected forests that I need to sync users and groups from." checkbox.


Build of react-dom-server on unpkg.com is broken

I am not totally sure whether this should be reported here or against react - for the issue against our project see https://github.com/WordPress/gutenberg/issues/1628; against react, see https://github.com/facebook/react/issues/10086.

<EMAIL_ADDRESS>is currently a bad build.
It redirects to<EMAIL_ADDRESS>which ends like this:
/**
* For browsers that do not provide the `textInput` event, extract the
* appropriate string to use for SyntheticInputEvent.
*
* @param {string} topLevelType Record from `BrowserEventConstants`.
* @param {object} nativeEvent Native browser event.
* @return {?string} The fallback string for this `beforeInput` event.
*/
function getFallbackBeforeInputChars(topLevelType, nativeEvent) {
 // If we are currently composing (IME) and using a fallback to do so,
 // try to extract the composed characters from the fallback object.
 // If composition event is available, we extract a string only at
 // compositionevent, otherwise extract it at fallback events.
 if (currentComposition) {
   if (topLevelType === 'topCompositionEnd' || !canUseCompositionEve

The alpha.12 version looks fine.

This seems to have fixed itself.


Emulator crashes when trying to open a file in a folder of many files

I use Windows x64 version of Cadmium and when I try to open my Chip-8 folder (with 750 files!) the emulator crashes. Here is the log
[2024-05-01T03:06:26.571Z][INFO] : Initializing raylib 4.6-dev
[2024-05-01T03:06:26.571Z][INFO] : Supported raylib modules:
[2024-05-01T03:06:26.571Z][INFO] :     > rcore:..... loaded (mandatory)
[2024-05-01T03:06:26.571Z][INFO] :     > rlgl:...... loaded (mandatory)
[2024-05-01T03:06:26.571Z][INFO] :     > rshapes:... loaded (optional)
[2024-05-01T03:06:26.571Z][INFO] :     > rtextures:. loaded (optional)
[2024-05-01T03:06:26.571Z][INFO] :     > rtext:..... loaded (optional)
[2024-05-01T03:06:26.571Z][INFO] :     > rmodels:... loaded (optional)
[2024-05-01T03:06:26.571Z][INFO] :     > raudio:.... loaded (optional)
[2024-05-01T03:06:26.955Z][INFO] : DISPLAY: Device initialized successfully
[2024-05-01T03:06:26.955Z][INFO] :     > Display size: 1920 x 1080
[2024-05-01T03:06:26.958Z][INFO] :     > Screen size:  512 x 420
[2024-05-01T03:06:26.958Z][INFO] :     > Render size:  512 x 420
[2024-05-01T03:06:26.958Z][INFO] :     > Viewport offsets: 0, 0
[2024-05-01T03:06:26.962Z][INFO] : GLAD: OpenGL extensions loaded successfully
[2024-05-01T03:06:26.962Z][INFO] : GL: Supported extensions count: 386
[2024-05-01T03:06:26.962Z][INFO] : GL: OpenGL device information:
[2024-05-01T03:06:26.962Z][INFO] :     > Vendor:   NVIDIA Corporation
[2024-05-01T03:06:26.962Z][INFO] :     > Renderer: NVIDIA GeForce GTX 960/PCIe/SSE2
[2024-05-01T03:06:26.962Z][INFO] :     > Version:  3.3.0 NVIDIA 552.12
[2024-05-01T03:06:26.962Z][INFO] :     > GLSL:     3.30 NVIDIA via Cg compiler
[2024-05-01T03:06:26.962Z][INFO] : GL: VAO extension detected, VAO functions loaded successfully
[2024-05-01T03:06:26.962Z][INFO] : GL: NPOT textures extension detected, full NPOT textures supported
[2024-05-01T03:06:26.962Z][INFO] : GL: DXT compressed textures supported
[2024-05-01T03:06:26.962Z][INFO] : GL: ETC2/EAC compressed textures supported
[2024-05-01T03:06:26.962Z][INFO] : TEXTURE: [ID 1] Texture loaded successfully (1x1 | R8G8B8A8 | 1 mipmaps)
[2024-05-01T03:06:26.962Z][INFO] : TEXTURE: [ID 1] Default texture loaded successfully
[2024-05-01T03:06:26.963Z][INFO] : SHADER: [ID 1] Vertex shader compiled successfully
[2024-05-01T03:06:26.963Z][INFO] : SHADER: [ID 2] Fragment shader compiled successfully
[2024-05-01T03:06:26.964Z][INFO] : SHADER: [ID 3] Program shader loaded successfully
[2024-05-01T03:06:26.964Z][INFO] : SHADER: [ID 3] Default shader loaded successfully
[2024-05-01T03:06:26.964Z][INFO] : RLGL: Render batch vertex buffers loaded successfully in RAM (CPU)
[2024-05-01T03:06:26.966Z][INFO] : RLGL: Render batch vertex buffers loaded successfully in VRAM (GPU)
[2024-05-01T03:06:26.966Z][INFO] : RLGL: Default OpenGL state initialized successfully
[2024-05-01T03:06:26.969Z][INFO] : TEXTURE: [ID 2] Texture loaded successfully (128x128 | GRAY_ALPHA | 1 mipmaps)
[2024-05-01T03:06:26.969Z][INFO] : FONT: Default font loaded successfully (224 glyphs)
[2024-05-01T03:06:27.006Z][INFO] : AUDIO: Device initialized successfully
[2024-05-01T03:06:27.006Z][INFO] :     > Backend:       miniaudio / WASAPI
[2024-05-01T03:06:27.006Z][INFO] :     > Format:        32-bit IEEE Floating Point -> 32-bit IEEE Floating Point
[2024-05-01T03:06:27.006Z][INFO] :     > Channels:      2 -> 2
[2024-05-01T03:06:27.006Z][INFO] :     > Sample rate:   48000 -> 48000
[2024-05-01T03:06:27.006Z][INFO] :     > Periods size:  1440
[2024-05-01T03:06:27.006Z][INFO] : STREAM: Initialized successfully (44100 Hz, 16 bit, Mono)
[2024-05-01T03:06:27.006Z][INFO] : TIMER: Target time per frame: 16.667 milliseconds
[2024-05-01T03:06:27.006Z][INFO] : TEXTURE: [ID 3] Texture loaded successfully (512x420 | R8G8B8A8 | 1 mipmaps)
[2024-05-01T03:06:27.006Z][INFO] : TEXTURE: [ID 1] Depth renderbuffer loaded successfully (32 bits)
[2024-05-01T03:06:27.008Z][INFO] : FBO: [ID 1] Framebuffer object created successfully
[2024-05-01T03:06:27.009Z][INFO] : TEXTURE: [ID 4] Texture loaded successfully (256x256 | R8G8B8A8 | 1 mipmaps)
[2024-05-01T03:06:27.010Z][INFO] : TEXTURE: [ID 5] Texture loaded successfully (256x192 | R8G8B8A8 | 1 mipmaps)
[2024-05-01T03:06:27.012Z][INFO] : TEXTURE: [ID 6] Texture loaded successfully (256x512 | R8G8B8A8 | 1 mipmaps)
[2024-05-01T03:06:27.012Z][INFO] : TEXTURE: [ID 7] Texture loaded successfully (256x192 | R8G8B8A8 | 1 mipmaps)
[2024-05-01T03:06:27.012Z][INFO] : IMAGE: Data loaded successfully (128x64 | R8G8B8 | 1 mipmaps)
[2024-05-01T03:06:27.012Z][INFO] : IMAGE: Data loaded successfully (128x24 | R8G8B8A8 | 1 mipmaps)
[2024-05-01T03:06:27.012Z][INFO] : TEXTURE: [ID 8] Texture loaded successfully (40x40 | R8G8B8A8 | 1 mipmaps)
[2024-05-01T03:06:27.012Z][INFO] : TEXTURE: [ID 2] Depth renderbuffer loaded successfully (32 bits)
[2024-05-01T03:06:27.013Z][INFO] : FBO: [ID 2] Framebuffer object created successfully
[2024-05-01T03:06:27.017Z][INFO] : TEXTURE: [ID 9] Texture loaded successfully (128x64 | R8G8B8 | 1 mipmaps)
[2024-05-01T03:06:27.018Z][INFO] : Loading known file with sha1: 607c4f7f4e4dce9f99d96b3182bfe7e88bb090ee

That should not happen! Thanks for the report, will look into it after work.
PS: Is that a release binary (so v1.1.8) or did you build one from HEAD yourself?

PS: Is that a release binary (so v1.1.8) or did you build one from HEAD yourself?
Is a release binary


Added LDAP authentication

If the builtin authentication fails,
checks the username and password
againts a LDAP server

So far I've tested this against a FreeIPA running on Rocky 8 in ldap. I still need to test against Active Directory and in ldaps
@perara can you tell me the following:

Is it possible to create a user without a password? A user without password will always fail on the built in auth and fallback to LDAP
What roles are you intended to use? This is to set a rule on user creation based on the user groups inside LDAP

Thank you,
HR

So far I've tested this against a FreeIPA running on Rocky 8 in ldap. I still need to test against Active Directory and in ldaps
@perara can you tell me the following:

Is it possible to create a user without a password? A user without password will always fail on the built in auth and fallback to LDAP
What roles are you intended to use? This is to set the role based on the user groups inside LDAP

Thank you,
HR

Excellent work! Tell me when you feel this is ready to get pushed in, and I'll take it for a test ride. Have to set up some LDAP server to test it out. For your questions:

Currently, I've had the requirement that all users should also have a password (I think) Do you think that it should be possible to have users without one?
Generally, I think LDAP should act as a drop-in replacement for local authentication. The local auth was something that I puked up during prototyping. It should be revisited eventually. Generally, there are no well-defined roles yet in the application, but maybe we should make some roles for different actions (stop-start-delete-create) ...etc, and that the user/administrator can link up specific LDAP roles to the local role scheme.

For example:
The setup flow would be something like this:

Administrator sets environment variables:

AUTH_LDAP_ENABLED=1
AUTH_LDAP_ADDRESS=<hostname>
AUTH_LDAP_USERNAME=<username>
AUTH_LDAP_PASSWORD=<passwd>
AUTH_LDAP_ADMIN_ROLE=<ldap admin role>

The above would enable the administrator to login using their LDAP account and to further map wg-manager roles to the corresponding LDAP roles. One could also have local username:password fallback, but in that case I would like the administrator to specify that through env variables such as:
AUTH_LOCAL_ENABLED=1
AUTH_ADMIN_USERNAME=admin
AUTH_ADMIN_PASSWORD=admin

For the latter, on initial setup, the user should be queried with a request to change the password on first login, but I suppose this belongs into its own issue.
Again good work, and I'd love to see this get merged in when your done :D

Hey,

1. Currently, I've had the requirement that all users should also have a password (I think) Do you think that it should be possible to have users without one?

So what I usually do is, all users that are authenticated using external systems don't have a password on the built in system. In that way, the built in authentication will always fail (assuming that the password is required on the login endpoint) and fallback to the external one, in this case LDAP. And we can also disable the password reset on users with password as NULL, since the password reset must happen on the external system.

2. Generally, I think LDAP should act as a drop-in replacement for local authentication. The local auth was something that I puked up during prototyping. It should be revisited eventually.

One could also have local username:password fallback, but in that case I would like the administrator to specify that through env variables such as:

I usually keep a built in system for 2 reasons:
- To have a local administrator and prevent system lock down. Doesn't really apply to this since the LDAP settings aren't stored on the database.
- Have 3rd party users that don't have LDAP credentials (external consultants for example).

Generally, there are no well-defined roles yet in the application, but maybe we should make some roles for different actions (stop-start-delete-create) ...etc, and that the user/administrator can link up specific LDAP roles to the local role scheme.

Independently of the roles system, I think that the best way is to keep it simple, the Group/OU X on LDAP matches with the role/group X on wg-manager. This setting can either be set on the database or in the environment variables. Either way, we can merge this without the roles map and when the roles system is ready we do implementation.

AUTH_LDAP_ENABLED=1
AUTH_LDAP_ADDRESS=<hostname>
AUTH_LDAP_USERNAME=<username>
AUTH_LDAP_PASSWORD=<passwd>
AUTH_LDAP_ADMIN_ROLE=<ldap admin role>

Do you wann't me to change the variables from LDAP_* to AUTH_LDAP_* and add the AUTH_LOCAL_ENABLED?
btw, this is already working with AD and ldaps

Ok so apart from the roles thing, this is ready for merge. I've squashed the commits into a single one.
Also, as a side note, before trying, sync the master and dev branches, since the master has the fix to create users.

Excellent work! Merged it in!


.Net: Consider ImageContent and AudioContent inherit from BinaryContent

@matthewbolanos please provide details of the issue that would be fixed by the change.

@SergeyMenshykh I don't think it will be good. BinaryContent.Data is required but ImageContent.Data and AudioContent.Data are optional, so casting these two to BinaryContent would give inconsistent behavior. Following this way, we should create a DataKernelContent class with Uri and BinaryData parameters and inherit from it.

This feature should be worked on in conjunction with https://github.com/microsoft/semantic-kernel/issues/5263 (which should address @Krzysztof318's concerns around BinaryContent.Data being required). Because BinaryContent could/should be hydrated with either a URL or a byte array, it should likely be renamed to FileContent.
The main scenario that we'd like to support is the following...
Context

Today, the BinaryContent class is predominantly used for the Assistants API
The Assistants API supports several different file types: https://platform.openai.com/docs/assistants/tools/supported-files
Most notably, it supports image types like jpg and png
In the future, it may also support other types like audio and video

Scenario

The user makes a request to the Assistant API
The Assistant API returns back with an image
The developer then wants to take the image and run it through another model (e.g., image-to-text to get a description for it for a11y)
Instead of taking the binary of the file and creating a new ImageContent with it, the user should simply be able to cast it to the correct type.

As a test of the new hierarchy, the following POC should be possible:

Ask an agent built with the Assistant API with Code Interpreter to create an 1) image, 2) audio file, and 3) word file
Get the collection of files from the ChatMessageContent
Save all the files to disk using the parent class (e.g., BinaryContent or FileContent)
Type caste the image to ImageContent to perform a text-to-image task
Type caste the audio to AudioContent to perform audio-to-text task

Done


Laravel vuejs issue

Expected Behavior
I add shards-vue in my project with larvel backend and vuejs frontend. When I start building app, evrything fine and webpack is fine, and build is successfully run! But...
Current Behavior
When I open page this is error in my app
vue.common.dev.js:630 [Vue warn]: The .native modifier for v-on is only valid on components but it was used on .
found in
--->  at /Users/hisk/Projects/GitHub/shards-vue/src/components/link/Link.vue
 at /Users/hisk/Projects/GitHub/shards-vue/src/components/nav/NavItem.vue
 at /Users/hisk/Projects/GitHub/shards-vue/src/components/navbar/NavbarNav.vue
 at /Users/hisk/Projects/GitHub/shards-vue/src/components/collapse/Collapse.vue
 at /Users/hisk/Projects/GitHub/shards-vue/src/components/navbar/Navbar.vue
 at resources/js/layouts/front/header.vue
 at resources/js/layouts/front-page.vue

Please help.

There is a open Pull Request for this issue.
https://github.com/DesignRevision/shards-vue/pull/28
Please, leave your comment there to wake up @design-revision.


commit

What does this PR do and why?
Provide a description of what this PR does. Link to any relevant GitHub issues, Notion tasks or Discord discussions.
Screenshots or screen recordings
If applicable, provide screenshots or screen recordings to demonstrate the changes.
Acceptance checklist

[ ] I have evaluated the Approval Guidelines for this PR.
[ ] I have tested this PR in all supported browsers.
[ ] I have tested this PR in dark mode and light mode (if applicable).

Current dependencies on/for this PR:

main

PR #3156

PR #3157

PR #3158

PR #3161

PR #3173

PR #3174

PR #3179   👈

PR #3159

This comment was auto-generated by Graphite.


check pid exists when waiting for child

Added child check when waiting for children to finish, in case that child failed to delete viztmp file. The current pid_exists has a issue that if a process return 259 (STILL_ACTIVE) as exit code (which is a really rare case that is nearly impossible I guess).

Codecov Report
Attention: 13 lines in your changes are missing coverage. Please review.

Comparison is base (68b7784) 100.00% compared to head (f8898c1) 98.28%.

Files
Patch %
Lines

src/viztracer/util.py
50.00%
12 Missing :warning:

src/viztracer/main.py
88.88%
1 Missing :warning:

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.
Additional details and impacted files
@@             Coverage Diff             @@
##            master     #388      +/-   ##
===========================================
- Coverage   100.00%   98.28%   -1.72%
===========================================
  Files           21       21
  Lines         2249     2274      +25
===========================================
- Hits          2249     2235      -14
- Misses           0       39      +39

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

Fixed it!

I believe this PR is making the nightly validation unstable - https://github.com/gaogaotiantian/viztracer/actions/runs/7539946132/job/20523513962 (not sure if you have access to it).
The issue is the child process only lives for 1 second, and the parent process might need more to reach the trace collection part. github actions is normally much slower than our PC. There are multiple tests that use different timeout on github actions (search for GITHUB_ACTIONS) and we should probably do the same here. (To not increase the local full-test time and stablize the remote one).

I believe this PR is making the nightly validation unstable - https://github.com/gaogaotiantian/viztracer/actions/runs/7539946132/job/20523513962 (not sure if you have access to it).
The issue is the child process only lives for 1 second, and the parent process might need more to reach the trace collection part. github actions is normally much slower than our PC. There are multiple tests that use different timeout on github actions (search for GITHUB_ACTIONS) and we should probably do the same here. (To not increase the local full-test time and stablize the remote one).

I agree with that if using a much slower PC the test will fail. It takes about 0.4 seconds on my computer between _winapi.CreateProcess and the child starting. The time may be longer on github actions. So when the parent collects the data, the child might haven't created viztmp file.


CASMINST-4821: Validate SLS health before using CSI to set no-wipe during upgrades

Description
CASMTRIAGE-3255 documents a case we have seen twice now where SLS is not healthy when calling CSI to set the no-wipe flag, resulting in the upgrade hanging. Currently the root cause of the issue is not understood.
In order to provide a better failure condition (rather than an infinite loop), this PR adds a very simple SLS health check before making the CSI call to set the no-wipe flag.
In order to better isolate the problem, this PR also adds this same check just before the "drain node" step (because it would be helpful to know if it is the drain which is causing this problem).
The SLS health check consists of 2 API calls, to the liveness and health endpoints. It validates that the correct response status is given (204 and 200 respectively).
I have tested the SLS health check function on hela (csm-1.2) and frigg (csm-1.0) and  validated that it works as expected. I haven't tested it in a live upgrade.
Checklist Before Merging

[X] My commits or Pull-Request Title contain my JIRA information, or I don't have a JIRA.

/backport main

/backport main

drain_node is also used for rebuild automation too, so maybe we should add this new check to inside the drain_node function?
or we should add it in  "upgrade/1.2/scripts/rebuild/ncn-rebuild-master-nodes.sh" and  "upgrade/1.2/scripts/rebuild/ncn-rebuild-worker-nodes.sh" too


client refactor: review file object handling

There's a lot more manual file closing (temp_obj.close()) than I'd like and I can already see bugs: the same file object gets closed multiple times on some exceptions.
Let's do a comprehensive review and aim to A) get rid of as many manual close()s as we can and B) make the remaining ones more obviously correct

This one is done already: file object handling has been vastly reduced in the experimental client


Issue with RequestTimeout() after update from 2.2 to 5.3.1

Where are you using pytradfri (eg stand-alone, Home Assistant etc)
Using pytradfri a stand-alone with a few scripts.
I tried to update pytradfri from a former version to the current version to use some of the newly implemented features. After the update I have not been getting various different errors from the libcoap_api file.
Version of pytradfri
Former version: 2.2 (I think)
Current version 5.3.1
Expected behaviour
Scenario 1) Generation of PSK should complete and write to conf-file. Currently I get a timeout.
Scenaio 2) When calling "devices_commands = api(devices_command)" I get a TypeError.
Actual behaviour
Scenario 1)
When running the test example example_sync.py, I get the below error:

Please provide the 'Security Code' on the back of your Tradfri gateway: *********
Traceback (most recent call last):
File "test2.py", line 101, in
run()
File "test2.py", line 81, in run
psk = api_factory.generate_psk(args.key)
File "/usr/local/lib/python3.5/dist-packages/pytradfri/api/libcoap_api.py", line 160, in generate_psk
self._psk = self.request(Gateway().generate_psk(existing_psk_id))
File "/usr/local/lib/python3.5/dist-packages/pytradfri/api/libcoap_api.py", line 92, in request
return self._execute(api_commands)
File "/usr/local/lib/python3.5/dist-packages/pytradfri/api/libcoap_api.py", line 81, in _execute
raise RequestTimeout() from None
pytradfri.error.RequestTimeout

Scenario 2)
If I try to use my former code that worked with version 2.2 (I think) without genering the psk and just calling "api_factory = APIFactory("IP", "Security Code")" then I get the following. I dont know if this is even a valid call anymore, but it does not complain at this point. It is then the api(devices_command) that throws the error (I am not that experienced in coding, so I dont know where to look if this method is still supported.) See code and error below:

api_factory = APIFactory("<IP_ADDRESS>", "xxxxxxxxx")
api = api_factory.request
gateway = Gateway()
devices_command = gateway.get_devices()
devices_commands = api(devices_command)
Traceback (most recent call last):
File "", line 1, in
File "/usr/local/lib/python3.5/dist-packages/pytradfri/api/libcoap_api.py", line 92, in request
return self._execute(api_commands)
File "/usr/local/lib/python3.5/dist-packages/pytradfri/api/libcoap_api.py", line 79, in _execute
return_value = subprocess.check_output(command, **kwargs)
File "/usr/lib/python3.5/subprocess.py", line 316, in check_output
**kwargs).stdout
File "/usr/lib/python3.5/subprocess.py", line 383, in run
with Popen(*popenargs, **kwargs) as process:
File "/usr/lib/python3.5/subprocess.py", line 676, in init
restore_signals, start_new_session)
File "/usr/lib/python3.5/subprocess.py", line 1221, in _execute_child
restore_signals, start_new_session, preexec_fn)
TypeError: Can't convert 'NoneType' object to str implicitly

I have tried updating/reinstalling libcoap after the pytradfri update to ensure it was up-to-date.
The dependencies for aiocoap (v0.4a1), DTLSSocket (v0.1.4) and typing (v3.6.4) are installed.
Any help and guidance is much appreciated.

@Ashutor you state that you run the example files. In your logs above, there is mention of File "test2.py", line 101. Did you rename the example files? It shouldn't matter but I'm trying to tye the loose ends. Also, what happens if you run the example_async-file?

@ggravlingen Thanks for assisting me in (hopefully) getting it back to a working state.
I were just about to write a really long response in everything I have tried since I posted earlier today together with a new traceback from running the example_async file. This issue has been driving me nuts the since Friday evening where I updated - Last element I wanted to check was if - for some reason - the IP of the GW should have changed, and it did - I were trying to connect to nothing - Embarrassing... Tried with the correct / now updated / IP, and it works like a charm with the example_sync file - Now I just need to update my older scripts to use the updated functionality.
Thanks for a great package and sorry for wasting your time with such stupidity. 👍

Haha, no worries. We've all been there, close to trying everything but the most obvious :)


Fixes #523 Add capability to specify proxy for repository replications

[ ] All tests passed. If this feature is not already covered by the tests, I added new tests.
[X] This pull request is on the dev branch.
[X] I used gofmt for formatting the code before submitting the pull request.

I have a use case where I am trying to configure Artifactory replications through Terraform and need to be able to set a proxy for the replication.  Couple things to note about the current changes:

The GET JSON response for getting a replication has changed between Artifactory 6.x and 7.x such that this change would only work for 7.x.  See https://github.com/atlassian/go-artifactory/pull/33, an old PR,  for the change for Artifactory 6.x.
I wanted to added a test for this, but unfortunately was not able to figure out how to dynamically create a proxy via a REST API (couldn't find anything on https://www.jfrog.com/confluence/display/JFROG/Artifactory+REST+API).  If you can help point me in the right direction wrt this, I would love to add a test for configuring proxy.  I have tested the changes using a GUI/manually created proxy.

I have read the CLA Document and I hereby sign the CLA

The force push was because I had accidentally committed the fix using a different user and needed to re-write that commit.
@eyalbe4 I noticed that there was an xray test that was failing from your test trigger.  Do you have any insights into what might be causing that?  Thanks in advance!

Thanks so much for this important addition @Guent4.
It will be released shortly.


chore: add !package-lock.json and !tsconfig.json to .gitignore

ref: https://github.com/BuilderIO/gpt-crawler/pull/59#discussion_r1402830681

thanks @nilwurtz !


Connection lost to esp32s3 via USB/JTAG while using TWAI driver (IDFGH-10143)

Answers checklist.

[X] I have read the documentation ESP-IDF Programming Guide and the issue is not addressed there.
[X] I have updated my IDF branch (master or release) to the latest version and checked that the issue is present there.
[X] I have searched the issue tracker for a similar issue and not found a similar issue.

IDF version.
IDF V5.0
Operating System used.
Windows
How did you build your project?
VS Code IDE
If you are using Windows, please specify command line type.
PowerShell
Development Kit.
esp32-s3-DevKitC-1 v1.1 & custom board
Power Supply used.
USB
What is the expected behavior?
I have  custom  esp32s3 board, That doesn't contain a reset and boot button or a UART port.  I simply lost connection to it via USB/JTAG port while flashing a modified code of  TWAI driver example  using the self-test example .
To understand the issue, I tired the same code on a esp32-s3-DevKitC-1 v1.1, and it resulted in the same behavior (lost connection to it via USB/JTAG port)
I Expected the program to run and return an error log, or keeps resetting.
What is the actual behavior?
After flashing the modified (defected) software, Windows can not recognize the device giving USB device not recognized msg.

The device will be recognized again if you flash the correct software through UART port. or by putting the board to download mode.
The question is, what does actually happens to prevent the board from connecting through the JTAG/USB port ?
I want to avoid this scenario in our custom board that doesn't include a UART USB port or a reset button to put the chip into download mode, hence losing all connection to custom board.
my initial guess that this due to some efuse that get emulated in way to disable the JTAG/USB port
Steps to reproduce.

Compile and flash this modified version of the TWAI self-test code in esp-idf v5.0  example
The modification is simply commenting out  xSemaphoreTake(rx_sem, portMAX_DELAY); and   xSemaphoreTake(tx_sem, portMAX_DELAY); from the original example.

/* TWAI Self Test Example
This example code is in the Public Domain (or CC0 licensed, at your option.)
Unless required by applicable law or agreed to in writing, this
software is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
CONDITIONS OF ANY KIND, either express or implied.
*/
#include <stdio.h>
#include <stdlib.h>
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
#include "freertos/semphr.h"
#include "esp_err.h"
#include "esp_log.h"
#include "driver/twai.h"
/* --------------------- Definitions and static variables ------------------ */
//Example Configurations
#define NO_OF_MSGS              10
#define TX_GPIO_NUM             3
#define RX_GPIO_NUM             8
#define TX_TASK_PRIO            4       //Sending task priority
#define RX_TASK_PRIO            5       //Receiving task priority
#define CTRL_TSK_PRIO           6      //Control task priority
#define MSG_ID                  0x555   //11 bit standard format ID
#define EXAMPLE_TAG             "TWAI Self Test"
static const twai_timing_config_t t_config = TWAI_TIMING_CONFIG_25KBITS();
//Filter all other IDs except MSG_ID
static const twai_filter_config_t f_config = {.acceptance_code = (MSG_ID << 21),
.acceptance_mask = ~(TWAI_STD_ID_MASK << 21),
.single_filter = true};
//Set to NO_ACK mode due to self testing with single module
static const twai_general_config_t g_config = TWAI_GENERAL_CONFIG_DEFAULT(TX_GPIO_NUM, RX_GPIO_NUM, TWAI_MODE_NO_ACK);
static SemaphoreHandle_t tx_sem;
static SemaphoreHandle_t rx_sem;
static SemaphoreHandle_t ctrl_sem;
static SemaphoreHandle_t done_sem;
/* --------------------------- Tasks and Functions -------------------------- */
static void twai_transmit_task(void *arg)
{
twai_message_t tx_msg = {.data_length_code = 1, .identifier = MSG_ID, .self = 1};
//xSemaphoreTake(tx_sem, portMAX_DELAY);
for (int i = 0; i < NO_OF_MSGS; i++) {
ESP_LOGI(EXAMPLE_TAG, "Msg Sent - Data = %d", i);
//Transmit messages using self reception request
tx_msg.data[0] = i;
ESP_ERROR_CHECK(twai_transmit(&tx_msg, portMAX_DELAY));
vTaskDelay(pdMS_TO_TICKS(10));
}
vTaskDelete(NULL);
}
static void twai_receive_task(void *arg)
{
twai_message_t rx_message;
//xSemaphoreTake(rx_sem, portMAX_DELAY);
for (int i = 0; i < NO_OF_MSGS; i++) {
//Receive message and print message data
ESP_ERROR_CHECK(twai_receive(&rx_message, portMAX_DELAY));
ESP_LOGI(EXAMPLE_TAG, "Msg received - Data = %d", rx_message.data[0]);
}
//Indicate to control task all messages received for this iteration
xSemaphoreGive(ctrl_sem);
vTaskDelete(NULL);
}
static void twai_control_task(void *arg)
{
xSemaphoreTake(ctrl_sem, portMAX_DELAY);
//Start TWAI Driver for this iteration
ESP_ERROR_CHECK(twai_start());
ESP_LOGI(EXAMPLE_TAG, "Driver started");
//Trigger TX and RX tasks to start transmitting/receiving
xSemaphoreGive(rx_sem);
xSemaphoreGive(tx_sem);
xSemaphoreTake(ctrl_sem, portMAX_DELAY);    //Wait for TX and RX tasks to finish iteration

ESP_ERROR_CHECK(twai_stop());               //Stop the TWAI Driver
ESP_LOGI(EXAMPLE_TAG, "Driver stopped");
vTaskDelay(pdMS_TO_TICKS(100));             //Delay then start next iteration

xSemaphoreGive(done_sem);
vTaskDelete(NULL);

}
void app_main(void)
{
//Create tasks and synchronization primitives
tx_sem = xSemaphoreCreateBinary();
rx_sem = xSemaphoreCreateBinary();
ctrl_sem = xSemaphoreCreateBinary();
done_sem = xSemaphoreCreateBinary();
xTaskCreatePinnedToCore(twai_control_task, "TWAI_ctrl", 4096, NULL, CTRL_TSK_PRIO, NULL, tskNO_AFFINITY);
xTaskCreatePinnedToCore(twai_receive_task, "TWAI_rx", 4096, NULL, RX_TASK_PRIO, NULL, tskNO_AFFINITY);
xTaskCreatePinnedToCore(twai_transmit_task, "TWAI_tx", 4096, NULL, TX_TASK_PRIO, NULL, tskNO_AFFINITY);

//Install TWAI driver
ESP_ERROR_CHECK(twai_driver_install(&g_config, &t_config, &f_config));
ESP_LOGI(EXAMPLE_TAG, "Driver installed");

//Start control task
xSemaphoreGive(ctrl_sem);
//Wait for all iterations and tasks to complete running
xSemaphoreTake(done_sem, portMAX_DELAY);

//Uninstall TWAI driver
ESP_ERROR_CHECK(twai_driver_uninstall());
ESP_LOGI(EXAMPLE_TAG, "Driver uninstalled");

//Cleanup
vSemaphoreDelete(tx_sem);
vSemaphoreDelete(rx_sem);
vSemaphoreDelete(ctrl_sem);
vQueueDelete(done_sem);

}
Debug Logs.
No response
More Information.
No response

Hi Igrr,
I get the flowing logs

Can this issue be because I am using pins 43 and 44 (which are UART0 TX RX ) with the CANbus transceiver ?


should profile stubs include { hidden: false } to indicate that they can be suppressed?

As in the title. Adding hidden: false to the default stub might clue users into profile hiding.

@zadjii-msft likely has an opinion here

To the defaults.json or the stubs in the user profiles or the DPG stubs?
I think yes, sure, no

I was thinking userSettings.json and DPGs.

Would putting it in the cmd, powershell profiles not be good enough?
I don't feel particularly strong one way or the other. Code shouldn't be hard, I'll throw something together


Attempt to fix issue 86

@kwilcox I believe we were relying on a bug and passing  an empty y to CubicSpline should return a ValuError but instead we just moved the iteration forward. This PR just passes zeroes to ensure we have finite elements to start the iteration.

Could we raise a ValueError instead of returning a zeroed out array? That is what the calling function __get_daily_interp_subset expects

Could we raise a ValueError instead of returning a zeroed out array? That is what the calling function __get_daily_interp_subset expects? Raising a ValueError results in the same outcome.

That is better. Working on it...
PS: That should probably be in SciPy.


cloud computing courses

We want to include material on cloud computing for researchers, this is a meta issue to sketch out some courses within this. Some suggestions are (feel free to edit)

Intro to cloud computing (need different streams for different providers?)
Infrastructure as code (terraform?)
DevOps (put existing continuous integration material here?)
Orchestration (kubanetes?)
Anything else? something ML flavoured?

This sounds great, thanks @ansarrafique. I think these should be hand-on practical courses where the participants work through problems / setup toy cloud services. Once you have a chance to look around for existing material please add it here as well and we can think about what we'd like to port.

https://datacarpentry.org/cloud-genomics/
This course is CC-BY 4.0 and may have some relevant information.