Row 56092
Content Data
This page contains data entry 56092 from the Axioma AXP content repository. The structured data below represents the complete record for this entry.
I'm on a binary image classification model(sigmoid activation)
train, test, val data are already in separated folders
I loaded the test data and got y\_pred and y\_true as following There seems to be an error, as
model.evaluate(test\_generator) shows 93% accuracy
while accuracy\_score((y\_pred, y\_true) shows only 61%
It seems there's some error while getting y\_true or y\_pred.
Help me.
test_datagen = ImageDataGenerator(rescale=1.0/255)
test_generator = val_test_datagen.flow_from_directory( '/content/chest_xray/test', target_size=(IMAGE_SIZE, IMAGE_SIZE), batch_size=32, class_mode='sparse' )
y_pred_probs = model.predict(test_generator)
y_pred_classes = (y_pred_probs > 0.5).astype(int) y_pred = y_pred_classes.flatten()
y_true = test_generator.classes
| Field | Value |
|---|---|
| text | I'm on a binary image classification model(sigmoid activation) train, test, val data are already in separated folders I loaded the test data and got y\_pred and y\_true as following There seems to be an error, as model.evaluate(test\_generator) shows 93% accuracy while accuracy\_score((y\_pred, y\_true) shows only 61% It seems there's some error while getting y\_true or y\_pred. Help me. test_datagen = ImageDataGenerator(rescale=1.0/255) test_generator = val_test_datagen.fl… |
| label | r/machinelearning |
| dataType | post |
| communityName | r/MachineLearning |
| datetime | 2024-05-23 |
| username_encoded | Z0FBQUFBQm5Lak1XcTFXcGJQTGlTX3VtRUZsNXhLaDRfbG9JTU5BSFhPSUpjdG1NWVdNZUlhd1hWSlNxODJSQ1IwTDZGV285VkVHVGl4VTV0VHJGRDJzVWc2QTNRckliYWZyUVRhLVc5QnhrU19YWC1YNlBoeFE9 |
| url_encoded | Z0FBQUFBQm5Lak9tTmlhTEt6ZFhCNFZBWEM3NUhtQ2UzQzZGMFlQOEd0UVZmd2VhdWtJZEtwOUtsQVpWM3JGVm5VX1NRUlhtbHN6Mk9IamM0YXhqRWs0NVFWSnh6TV9jMmhUU0lfTWx3ZnRqQW1XM2pKcFViaEFFRVd3a2RYWGcxUmJ4blQ2bmdacFIycWd6VGpIWVpOYndLOVNDa3cxZmZJX3RHcEVBcUx2T3FjQ3VQWFZJN3NlWVZCQXF3Y3Y4V1B0Q0IteFJjRkVzYmt1VHBVOGEwMjJEOHh1REIxekxpUT09 |
Raw Record
{
"text": "I'm on a binary image classification model(sigmoid activation)\n\ntrain, test, val data are already in separated folders\n\nI loaded the test data and got y\\_pred and y\\_true as following \nThere seems to be an error, as \n\nmodel.evaluate(test\\_generator) shows 93% accuracy\n\nwhile accuracy\\_score((y\\_pred, y\\_true) shows only 61%\n\nIt seems there's some error while getting y\\_true or y\\_pred.\n\nHelp me. \n\n\n test_datagen = ImageDataGenerator(rescale=1.0/255)\n\n test_generator = val_test_datagen.flow_from_directory(\n '/content/chest_xray/test',\n target_size=(IMAGE_SIZE, IMAGE_SIZE),\n batch_size=32,\n class_mode='sparse'\n )\n\n y_pred_probs = model.predict(test_generator)\n\n y_pred_classes = (y_pred_probs > 0.5).astype(int)\n y_pred = y_pred_classes.flatten()\n\n y_true = test_generator.classes",
"label": "r/machinelearning",
"dataType": "post",
"communityName": "r/MachineLearning",
"datetime": "2024-05-23",
"username_encoded": "Z0FBQUFBQm5Lak1XcTFXcGJQTGlTX3VtRUZsNXhLaDRfbG9JTU5BSFhPSUpjdG1NWVdNZUlhd1hWSlNxODJSQ1IwTDZGV285VkVHVGl4VTV0VHJGRDJzVWc2QTNRckliYWZyUVRhLVc5QnhrU19YWC1YNlBoeFE9",
"url_encoded": "Z0FBQUFBQm5Lak9tTmlhTEt6ZFhCNFZBWEM3NUhtQ2UzQzZGMFlQOEd0UVZmd2VhdWtJZEtwOUtsQVpWM3JGVm5VX1NRUlhtbHN6Mk9IamM0YXhqRWs0NVFWSnh6TV9jMmhUU0lfTWx3ZnRqQW1XM2pKcFViaEFFRVd3a2RYWGcxUmJ4blQ2bmdacFIycWd6VGpIWVpOYndLOVNDa3cxZmZJX3RHcEVBcUx2T3FjQ3VQWFZJN3NlWVZCQXF3Y3Y4V1B0Q0IteFJjRkVzYmt1VHBVOGEwMjJEOHh1REIxekxpUT09"
}
Entry Information
- Entry ID: 56092
- Repository: Axioma AXP
- Dataset: arrmlet/reddit_dataset_36
- Total Entries: 100,000