Get x numbers of a woocommerce category products using Wp_Query

Use this query to display woocommerce featured product and replace with yours

$meta_query   = WC()->query->get_meta_query();
$meta_query[] = array(
    'key'   => '_featured',
    'value' => 'yes'
);
$featured = array(
    'post_type'   =>  'product',
    'stock'       =>  1,
    'showposts'   =>  6,
    'orderby'     =>  'date',
    'order'       =>  'DESC',
    'meta_query'  =>  $meta_query
);

Then run your slider action html code inside the loop.

<?php $i = 0; ?>
<?php if( $featured->have_posts() ): while( $featured->have_posts() ): $featured->the_post(); ?>
<?php #$class = get_post_meta( get_the_ID(), 'class', true); ?>
<?php if( $i === 1 ): ?>
  <div class="col-md-6 col-lg-6 d-none d-sm-none d-md-block featured-desc">
    <h2 class="featured-title-right text-right"><?php the_title(); ?></h2>
    <p class="featured-excerpt-right text-right"><?php echo get_the_excerpt(); ?></p>
  </div>
  <div class="col-md-6 col-lg-6 text-center d-none d-sm-none d-md-block featured-img">
    <img class="img-fluid" src="https://wordpress.stackexchange.com/questions/356514/<?php the_post_thumbnail_url(); ?>">
  </div>
<?php else: ?>
  <div class="col-md-6 col-lg-6 text-center d-none d-sm-none d-md-block featured-img">
    <img class="img-fluid" src="https://wordpress.stackexchange.com/questions/356514/<?php the_post_thumbnail_url(); ?>">
  </div>
  <div class="col-md-6 col-lg-6 d-none d-sm-none d-md-block featured-desc">
    <h2 class="featured-title"><?php the_title(); ?></h2>
    <p class="featured-excerpt"><?php echo get_the_excerpt(); ?></p>
  </div>
<?php endif;?>
<?php $i++; ?>
<?php endwhile; ?>
<?php endif; wp_reset_postdata(); ?>